I am trying to understand a proof but I am stuck on this technical bit:

Apart from the small typo highlighted, I don't really see how to get the big formula for the partial derivative of $v_i$
What I keep getting is the following:
$$\partial_i v_i(x)=\displaystyle \sum_{j,k=1}^{n} d_{i,j}(x) \partial_k (w_j(f(x))\partial_i( f_k) +\sum_{j=1}^n w_j(f(x)\partial_i d_{i,j} $$
where $\partial_k (w_j(f(x))=\displaystyle \frac{\partial w_j(f(x))}{\partial f_k}$
Later in the book an expression very similar to the one I get appears...are they the same thing? Is there a huge typo?
EDIT: I am thinking it could be that $W\not = w$ for some reason, is it a standard notation for something I don't know? I don't really see why they would have changed to capital letters otherwise...
Thank you very much!!