We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 52f0bcf + 23cc131 commit 4744a7bCopy full SHA for 4744a7b
src/utils/dnd-manager.js
@@ -235,9 +235,14 @@ export default class DndManager {
235
// throttle `dragHover` work to available animation frames
236
cancelAnimationFrame(this.rafId);
237
this.rafId = requestAnimationFrame(() => {
238
+ const item = monitor.getItem();
239
+ // skip if drag already ended before the animation frame
240
+ if (!item || !monitor.isOver()) {
241
+ return;
242
+ }
243
this.dragHover({
244
node: draggedNode,
- path: monitor.getItem().path,
245
+ path: item.path,
246
minimumTreeIndex: dropTargetProps.listIndex,
247
depth: targetDepth,
248
});
0 commit comments