react-force-graph
react-force-graph copied to clipboard
Add a minimap to visualize one's locatin in huge graphs
Is your feature request related to a problem? Please describe. When a graph is huge, and we zoom in, it's hard to understand “where” are we located in the graph.
Describe the solution you'd like It would be a very nice option to show a mini-map so users can see there location in the global graph (and not only the zoom part).
Describe alternatives you've considered Found none.
Additional context Here is a screenshot of a zoom graph, with a minimap
@chabotsi thanks for reaching out.
You could just overlay a small div on top of the graph canvas with your designed minimap. You can get the nodes coordinates by looking into the { x, y, z }
attributes on the data. And for zoom changes you can tap into the onZoom callback prop, which gives you the latest position of the zoomed viewport.
@chabotsi Hey! Was you succeed? Also how did you create your minimap that it shows all the objects after zoom on canvas?