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

Tree auto center after focus and first click #241

Closed
ftirej opened this issue Sep 19, 2019 · 1 comment
Closed

Tree auto center after focus and first click #241

ftirej opened this issue Sep 19, 2019 · 1 comment

Comments

@ftirej
Copy link

ftirej commented Sep 19, 2019

Thank you for taking the time to report an issue with react-d3-tree!

Feel free to delete any questions that do not apply.

Are you reporting a bug, or opening a feature request?

[Replace with your answer]
Open Bug

What is the actual behavior/output?

[Replace with your answer if relevant]
You can see this on the demo app. After first data load, the tree is not centered, and will auto center after first click con the canvas.

What is the behavior/output you expect?

[Replace with your answer if relevant]
The tree must be centered after setting translateX and translateY.

Can you consistently reproduce the issue/create a reproduction case (e.g. on https://codesandbox.io)?

[Replace with your answer if relevant]
Yes on https://bkrem.github.io/react-d3-tree-demo/

What version of react-d3-tree are you using?

[Replace with your answer]
"react-d3-tree": "^1.15.1"

If react-d3-tree crashed with a traceback, please paste the full traceback below.

[Replace with your traceback]

@bkrem
Copy link
Owner

bkrem commented Sep 19, 2019

Thanks for reporting @ftirej, this duplicates #240 and was an unintended consequence of having to migrate some code in Tree to fix broken compat with React 15.

If you're not using React 15 I'd recommend using v1.15.0 until I've had a chance to patch this issue. I'll try to allocate some time this evening to get that annoying issue resolved for the latest version.

Closing, let's keep the discussion for this in #240

@bkrem bkrem closed this as completed Sep 19, 2019
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

2 participants