fix: relation name persisting on screen while hovering graph edges #1066 #1124
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Problem
In the current implementation of the Cytoscape graph, we have two issues. First, when users zoom out while hovering over a node relation, the tooltip persists on the screen even after moving the mouse. This behavior can stack and lead to multiple tooltips staying on the screen. Second, when users hover over the tooltip, they are unable to zoom out.
fixes #1066
Solution
To solve these issues, I’ve added checks in the zoom event handler to remove any tooltips when zooming crosses its threshold i.e. zoomLevelBreakpoint. I’ve also disabled pointer events on the tooltip to allow zoom events to pass through.
Changes Made
How to Test
Screenshots
Notes
[Any additional notes or information that you would like to share with the reviewers.]
Checklist
Reviewers
@AllieMendes