Open chasedeanda opened 4 years ago
Hi! Thank you! I appreciate your feedback.
No, the move
event doesn't provide a way to cancel a drop that happened. But the canDrop
prop allows to prevent the dragOver
event on some items:
const canDrop = (targetId, draggedId) => {
// Return false if the dragged item cannot be dropped on the target item
};
Great work on this component it is very clean and user friendly! I need to write some validation for handling drag and drop events.
Is there a way to reject a drop that would put the dragged element back in its original place?