I’m trying to link a given line to other data on a chart, so want to link line_ids, whatever they might be, to other data. Is there a way to get the curveNumber when creating the line?
I noticed the customdata parameter, but ran into some fun roadblocks when trying to use it. Namely that customdata is being treated as an array from which each item is assigned to a given point on the line. I’ve figured out a workaround to assign the same id to any point on a given line, but was wondering if there was something more streamlined.
I would also like to raise an appeal for maps of lines being treated as actual lines rather than collections of points. It seems like the callbacks are only firing above the component points, rather than over the line itself, which is confusing to an end user.
I am working on an app about aviation traffic flows that renders many lines, but unfortunately the user cannot get information for a specific line easily.
An idea I had as a workaround was to compute and draw some invisible markers behind the lines (which are shortest paths on Earth) and link custom data to these markers, so that it appears for the user to just hover a line.
Still, the performance is not so good and hovering when zooming on the lines becomes impossible again (as the number of invisible markers is not infinite).
Thanks @Emil, dash-leaflet seems to be a must-have for map plots
After some research it seems that Leaflet.Geodesic plugin for Leaflet suits perfectly my needs for plotting the world flows : is there any plan to include this plug-in into dash-leaflet any time soon ?
Thanks! I haven’t thought about adding this functionality before, but it might be an option. But i guess you could achieve the same thing simply by calculating the geodesic curves in python from your points, and then plot the curves using the PolyLine or GeoJSON components?
If I wanted to reproduce geodesic curves with PolyLine or GeoJSON components, I would have to compute many components to get a smooth line which would appear as a true geodesic (for example from New York to Sidney, which is a very long geodesic).
I will try that and post here an update if that works well, or if computing many PolyLine or GeoJSON components will come with degraded perfs and/or problems with hovering infos management.