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

Is there event like "dragOver" or "dragLeave" ? #2075

Closed
GuzlejM opened this issue Sep 3, 2021 · 2 comments · May be fixed by #2198
Closed

Is there event like "dragOver" or "dragLeave" ? #2075

GuzlejM opened this issue Sep 3, 2021 · 2 comments · May be fixed by #2198

Comments

@GuzlejM
Copy link

GuzlejM commented Sep 3, 2021

I have project where are columns toggling open/close whenever I drag over column dragged element(card in this case).

Problem is when ever i drag over columns, they will stay open and not close back because onMove events has only from/to handler.

@ataft
Copy link

ataft commented Sep 21, 2021

These would be useful, and it looks like the stale leave-enter branch attempted to solve this (see issue #979), but was never merged.

There is a Stack Overflow solution posted by @owen-m1, but I cannot find an explanation for why this is not in the library. From my perspective, on 'dragleave', the sortable item should be removed from the destination. Currently, it is only removed on 'drop' when using the RevertOnSpill Plugin.

@owen-m1
Copy link
Member

owen-m1 commented Oct 11, 2021

As @ataft said, you can use the code i wrote in my Stack Overflow answer. I think its unnecessary for this to be in Sortable natively since you can just write custom events to handle it.

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 a pull request may close this issue.

3 participants