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

Straight edge labels incorrectly drawn at origin when angle is 0 #2044

Open
TedDriggs opened this issue Oct 31, 2023 · 0 comments
Open

Straight edge labels incorrectly drawn at origin when angle is 0 #2044

TedDriggs opened this issue Oct 31, 2023 · 0 comments

Comments

@TedDriggs
Copy link

Please make sure to read the following list before creating a new issue:

vis-network 9.1.2, when using an edge with "top" for its label alignment, the label jumps to the origin if the two endpoints have the same y coordinate and from.x > to.x. This is because drawLabel doesn't call translate if the rotation angle is zero here, but Label._setAlignment zeroes out the x and y values here seemingly under the belief that the context has already been translated.

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

No branches or pull requests

1 participant