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

Component | Graph: Fixing pointer-events issues; Configurable link highlight on hover #14

Draft
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

rokotyan
Copy link

Previously, the Graph component had frequent pointer-events related issues when hovering over nodes or clicking on them. This PR should fix this problem.

Also, adding a config option linkHighlightOnHover allowing to disable link highlighting on hover (defaults to true to avoid breaking changes)

388450083-20d4ca2d-92ba-4a74-b962-fe48e9aeeb80.mp4

…lector

This commits aims to solve frequent problems with node mouseover / click events not being triggered (link events were triggered instead).

- Adds a new `linkLabel` selector to the Graph component to target the link label group
- Removes the `pointer-events: all` style from the `linkLabelGroup` to prevent link hover highlight from interfering with link label interactions
- Adds a new `linkHighlightOnHover` config option to the Graph component to enable/disable link hover highlight
- Updates the `_onLinkMouseOver` method to only set the `hovered` state if `linkHighlightOnHover` is true
@rokotyan rokotyan self-assigned this Dec 13, 2024
@rokotyan rokotyan marked this pull request as ready for review January 13, 2025 20:56
@rokotyan rokotyan requested review from ankursingla and a team and removed request for a team and ankursingla January 13, 2025 20:56
@rokotyan rokotyan marked this pull request as draft January 13, 2025 20:57
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