Closed timelyportfolio closed 8 years ago
not at all! Can you describe the problem a bit more? You're suggesting limiting the options.class option to the containing element?
I was just adding a screenshot when I saw your reply. Hope it helps illustrate the issue.
I thought the selectAll statements were scoped to the enclosing element... checking now
Since you do d3.selectAll
, it will select everything in document
. To work as I am suggesting (again maybe not a good idea), you could do something like:
chart_node.selectAll(...)
ah, it's in the areaMouseover and areaMouseout where I do the d3.selectAll Will fix that!
Let me know if uploading a bl.ock will help. Thanks.
no, I've got it.
I think it is also in the legendMouseover
.
yes
I think that's fixed it.
I also played a bit with another niggly bit... have you noticed that you can toggle areas on and off by clicking on the Legend? Was hoping that I could .attr('display','none') the toggled areas so that hover events would work for lower areas, but alas.
let me know if the fix is really a fix and I will close this issue. thanks.
That does fix. Yes, I noticed the legend, but that will raise another issue.
Sorry to be a pest, but in lines results in problems when more than one exists on a page. In some cases this might be a "feature", but I think in general users might think of it as a bug. Of course, you provide the ability to override this, so maybe you can leave as is.
Perhaps could you limit this to the containing element?
Probably should have used an animated GIF, but in the screenshot, you can see how hovering in the top chart (green in this case) causes the bottom chart areas to go transparent.