I think my approach here is off.
I had code that worked:
$('.rectangle').mouseenter(function () {
var rect = d3.select("#"+this.id)
rect.transition()
.duration(500)
.attr("width", 40)
.attr("height", 400);
});
Then, I added a second id to each element, and the functionality broke. I've tried various ways of selecting an element that has multiple ids, since that seems to be the problem; none of them worked. This post has suggestions that seem to work for multiple classnames, but these approaches don't work for multiple ids.
I'd thought that adding the second id was cleaner code, but and then I had to add a second id to each d3 element so that each one could be selected by either unique property - word or element number.
Is there a way in d3 to select an element that has multiple ids?