-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Graph2d: select Event #311
Comments
Hi, This was indeed a poorly copied over example. There is no select in graph2d as it is now. Problem with graph2d selection, is that there is nothing to select at the moment. What would you think is a good thing to select? Curves? Datapoints? I'm not sure yet what a useful select would be. Regards, Alex |
Data points definitely, being able to get the currently selected Item would be very useful for doing something like displaying a popover/tooltip/whatever containing the current x/y values plus any custom metadata. Being able to select the curve would be useful as well, something like highlighting the currently selected curve and displaying the x/y values at the point the cursor is at is a thing I've seen on other graphs, but I think that's probably less important than being able to select the data points themselves. |
Hi, Problem is that the datapoints are not necessarily objects that are drawn. Yes you can choose to show them on the graph, but for a tooltip we'd need a more in depth solution. I still have tooltips on my todo list and once those are in place, it would be easy to get events like hover etc. I'll implement these features when I'll need them but I'm not sure when this will be. Curve highlighting events would be cool as well, accompanied by legend highlighting and an event if the user has custom legends. I'm not sure when these will be implemented though. Feel free to do a pull request if you find the time :). Regards, Alex |
If the data points are shown, then a select event for just that would be fine, not having it when they aren't rendered would be acceptable since you can't have an event for invisible things. I think having that would be more useful than a vis provided tooltip. I usually embed additional information into the Item DataSets which is something I can then use inside a custom event instead of relying on built in tooltips or providing each node with a fixed prepopulated HTML tooltip. |
What I had in mind for the tooltip was in fact to "click" on invisible Since this is drawn with svg, there are no direct bindings to dom Hence I think the select event is a consequence of the tooltips, not a Regards Alex |
Hi, Over the last year a lot of feature requests have been made. We have just introduced our new website which has a list of the requested features. We have placed this request on that list. The list can be found here: An explaination of the new system can be found here: I would like to stress that this does not mean we abandon this request. Discussion here will continue if needed on this feature but we will close it to keep our Github issue page more of a bug-todo list. Future feature requests will still be made here and then added to the website by us. Regards, Alex |
Reopening as Feature-Request issue (see #2114). |
A select event on the graph2d version of timeline would be very useful, the docs page, http://visjs.org/docs/graph2d.html#Events, actually has a sample 'select' event but I think it was just left over from a copy/paste of the timeline docs.
The text was updated successfully, but these errors were encountered: