Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Render nodes differently when zoomed out #8

Merged
merged 16 commits into from
Jun 19, 2021

Conversation

TranquilMarmot
Copy link
Owner

Summary

This changes it so that, when zoomed out, nodes will not render their bodies and will instead just render their title. Tags are also rendered until you zoom out far enough, then you just get the title.

This also fixes long node titles causing the rename/change color/delete buttons to be cut off.

TODO:

  • Currently, focusing on a node does not properly trigger zoom level; this is a bug in react-d3-graph
  • Right-click on node to focus on it (will also need to fix bugs in react-d3-graph for this)
  • Make zoom levels configurable in VSCode extension settings? (there are other settings I want to add and this will require some re-architecting of the way things are handled so it may be best to do this in another PR)

Screenshots

Not zoomed out

image

Zoomed out

image

Extra zoomed out

image

@TranquilMarmot TranquilMarmot merged commit 03219c5 into main Jun 19, 2021
@TranquilMarmot TranquilMarmot deleted the tranquilmarmot/zoomed-out-node branch June 19, 2021 02:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant