-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Mouse hover events for tooltips in graph2d #2126
Comments
@2dvisio Is this issue still relevant or can we close it? |
Well. As I mentioned, I have found an hack to do this. The hack is really ugly as I have to compute the distance of each click on the plot with the points and get the closest point. Having the possibility of adding attributes to the SVG single elements would be amazing as it will allow to leverage the HTML innate mechanisms to handle situations like mine. Keep up the good work! |
@2dvisio So, adding the UUID from the DataSet as an attribute to the svg elements would help? I don't think that this would be difficult. I'm going to clean up this issue and change it to a feature-request... |
Mouseover and mouseout would make it easier I guess to manage the mouse events. |
Is this embedded in 4.17 (and thus it has been removed)? |
For potential solution-seekers, if your groups are defined in-order (and you know what that order is), you could attach a listener using the following:
In place of the <INSERT_HERE_YOUR_ID>, you can enter the id as a numeral (starting form 0). |
To extend on this, It would be nice to have events available for hovering on the closest axis, not just available for tooltips. |
is there a tooltip on graph 2D now if not,Is there any solution? |
I've got into the problem of adding tooltip to a complex Graph2d element (many many groups, because some items got to be connected by lines while others don't).
Solved it in two different ways. The less ugly one at the moment is using the click listener to get the closest point so as to display an HTML div with the tooltip text inside.
However, a much less ugly way of doing it (IMHO) could be one of these:
Let me know in any of this makes sense.
The text was updated successfully, but these errors were encountered: