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 in/out re-write #1652

Merged
merged 1 commit into from
Mar 8, 2021
Merged

drag in/out re-write #1652

merged 1 commit into from
Mar 8, 2021

Conversation

adumesny
Copy link
Member

@adumesny adumesny commented Mar 8, 2021

Description

  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.

Checklist

  • Created tests which fail without the change (if possible)
  • All tests passing (yarn test)
  • Extended the README / documentation, if necessary

- 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.
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 this pull request may close these issues.

2 drop shadows when drag large widget between grids
1 participant