znalazłem obu z nich działa w moim teście:Jaka jest różnica między selection.style a selection.attr w D3.js?
.on("mouseover",
function() {
d3.select(this)
.select("text")
.style("fill","red");
})
lub
.on("mouseover",
function() {
d3.select(this)
.select("text")
.attr("fill","red");
})
CSS przesłania 'attr', ale nie zastępuje' stylu'. To mnie poturbowało. – hobbes3