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

Wrong order when saving targetNodes #30

Open
misha-erm opened this issue Sep 26, 2019 · 3 comments
Open

Wrong order when saving targetNodes #30

misha-erm opened this issue Sep 26, 2019 · 3 comments

Comments

@misha-erm
Copy link

Hello,

As I can see drop targets are saved in a wrong order. This affects cases when you have nested drop targets as children are being connected earlier than parents. It leads to the wrong behavior of isOver({shallow}) and wrong order of calling drop handlers.

As You can see in HTML5Backend https://github.com/react-dnd/react-dnd/blob/ddfb0204676a39c8a57dc56a7263cd8f23e265c7/packages/core/html5-backend/src/HTML5Backend.ts#L494 the target ids are unshifted to the array to keep the right order.

Thanks in advance!

@misha-erm
Copy link
Author

@zyzo

@airhorns
Copy link

@MikeYermolayev did you ever figure out a fix for this issue?

@misha-erm
Copy link
Author

@airhorns I switched to react-dnd-touch-backend

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