Open kristian-puccio opened 1 year ago
Hello! Are there any updates on this issue? I am trying to implement dragging and dropping multiple components at once (using the shift key to select components) and I would also need to access destinationIndex
in canDrop
so unselected components aren't able to be dropped in the middle of selected components.
+1 on this. I need the destinationIndex
or relativeIndex
in canDrop
because I'm trying to implement manual sorting where folders are always placed on top of files. I need to prevent the placeholder from showing up when you are trying to move a file on top of a folder and vice versa
Is your feature request related to a problem? Please describe. I want to re-enact a feature like
insertDroppableFirst
but rather than forcing the order post drop not allowing dropping a non droppable item before the list of droppables (ie folders).Describe the solution you'd like If the
canDrop
function included all the data thatonDrop
hasrelativeIndex
anddestinationIndex
then I would have all the data required to enforce the ordering.Describe alternatives you've considered
insertDroppableFirst
but that allows the drop and then re-orders.Additional context I believe according to the docs
canDrop
should have the same parameters asonDrop
.Oh I'll have a go at making a PR for you.
Thanks!