Drag and drop does not work correctly when data is changed while dragging
- Dominant language
- TypeScript
- Stars
- 25k
- Forks
- 6.8k
- Avg merge
- 1d 8h
- Merged PRs (30d)
- 91
Description
#### What is the expected behavior?
When change data while dragging, for example when have lazy load of items. D&d should update `siblings` and `draggables`
#### What is the current behavior?
current just ignore, cuz copy data before drag
https://github.com/angular/material2/blob/master/src/cdk/drag-drop/directives/drop-list.ts#L322
https://github.com/angular/material2/blob/master/src/cdk/drag-drop/drop-list-ref.ts#L179
Contributor guide
Research direction
Start with the drag-and-drop registration logic in src/cdk/drag-drop/directives/drop-list.ts around line 322 and DropListRef in src/cdk/drag-drop/drop-list-ref.ts around line 179. Trace how siblings and draggables are copied when dragging begins, then verify that changes to the data during a drag are reflected before drop. Done means lazy-loaded or otherwise changed items are handled instead of being ignored.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- angular, typescript
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100