score:1

Accepted answer

The problem is that you're selecting rect elements, but appending a elements. Your transition is selecting only the rect elements and not the a elements and operating on them.

To fix, select and append the same thing. You probably want the highest-level element in this case (i.e. the a).


Related Query

More Query from same tag