-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Dragging between two (H5) grids sometimes does not remove underlying node #1612
Labels
Comments
adumesny
added a commit
to adumesny/gridstack.js
that referenced
this issue
Mar 8, 2021
- fix gridstack#393 gridstack#1612 gridstack#1578 - re-write of the **drag in/out code - fixing 5 years old bug** 1. we now remove item when cursor leaves (`acceptWidgets` case using `dropout` event) or shape is outside (re-using same method) and re-insert on cursor enter (since we only get `dropover` event). Should **not be possible to have 2 placeholders** which confuses the grids. 2. major re-write and cleanup of the drag in/out. Vars have been renamed and fully documented as I couldn't understand the legacy buggy code. 3. removed any over trash delay feedback as I don't see the point and could introduce race conditions.
adumesny
added a commit
to adumesny/gridstack.js
that referenced
this issue
Mar 8, 2021
- fix gridstack#393 gridstack#1612 gridstack#1578 - re-write of the **drag in/out code - fixing 5 years old bug** 1. we now remove item when cursor leaves (`acceptWidgets` case using `dropout` event) or shape is outside (re-using same method) and re-insert on cursor enter (since we only get `dropover` event). Should **not be possible to have 2 placeholders** which confuses the grids. 2. major re-write and cleanup of the drag in/out. Vars have been renamed and fully documented as I couldn't understand the legacy buggy code. 3. removed any over trash delay feedback as I don't see the point and could introduce race conditions.
fixed in v4 (complete re-write) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Subject of the issue
Moving an item between two grids is not behaving as expected and leaving behind underlying nodes in the source grids engine. This is possibly related to / could be solved by
containment
being implemented in H5 dd.Your environment
Steps to reproduce
Reproducable on https://gridstackjs.com/demo/two.html# by dragging an item from the left grid to the right grid, with the mouse somewhere on the right side of the item. This seems to occasionally trigger a race condition that causes and a placeholder for the item in both grids simultaneously.
Expected behavior
The underlying node should be correctly removed from the original grid.
Actual behavior
The text was updated successfully, but these errors were encountered: