handleDrag on drop instead of while dragging
This commit is contained in:
@@ -13,7 +13,7 @@ const Draggable = ({
|
||||
// accept receives a definition of what must be the type of the dragged item to be droppable
|
||||
accept: type,
|
||||
// This method is called when we hover over an element while dragging
|
||||
hover(item: { index: number }) { // item is the dragged element
|
||||
drop(item: { index: number }) { // item is the dragged element
|
||||
if (!ref.current) {
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user