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

Drag and drop ordering not working properly in LayerControl. #455

Closed
viktoraronfarkas opened this issue Nov 23, 2023 · 2 comments · Fixed by #344
Closed

Drag and drop ordering not working properly in LayerControl. #455

viktoraronfarkas opened this issue Nov 23, 2023 · 2 comments · Fixed by #344
Labels
bug Something isn't working layercontrol

Comments

@viktoraronfarkas
Copy link
Collaborator

Screen.Recording.2023-11-23.at.11.53.50.mov

The dragged item always jumps up to top, no matter what position I am trying to move it to.

@viktoraronfarkas viktoraronfarkas added bug Something isn't working layercontrol labels Nov 23, 2023
@silvester-pari
Copy link
Collaborator

silvester-pari commented Nov 23, 2023

It's hard to tell why the error appears in some cases, in others not, since in the storybook and also in the tests it works fine: https://eox-a.github.io/EOxElements/?path=/story/elements-eox-layercontrol--primary

It might be that inside the app, something is hooking into e.g. change:length, and updating the layers there as well in parallel to the layercontrol.

There seems to be some general issue with the sorting, we have a PR that tries to cover this as well: #344. It originally started with #302, but more and more issues with the sorting were found :-(

@silvester-pari
Copy link
Collaborator

Turns out this erratic jumping behavior is because of a hidden layer that messes up the index.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working layercontrol
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants