react-beautiful-dnd icon indicating copy to clipboard operation
react-beautiful-dnd copied to clipboard

How to prevent a captured element from being dragged outside its bounds

Open pavelgromyko opened this issue 2 years ago • 4 comments

I can't believe that such a question has not arisen, but nevertheless I could not find a solution to my problem.

The gist of my question: I have a table in which the user can drag rows up and down. I think everything is clear here. But how do you limit the drag zone? After all, the user can move the cursor to another corner of the screen and the captured row will go with the cursor. The question is: how can you prevent a captured row from being moved beyond the boundaries of the table?

I don't provide the code because I don't require a solution. I want to know if it is possible to do this with this library and the principle of the solution

pavelgromyko avatar Nov 01 '23 22:11 pavelgromyko

I'd like to be able to do the same too. Any way to limit the draggable item to the bounds of the container?

dgwyer avatar Nov 15 '23 11:11 dgwyer

@dgwyer Unfortunately, I have not yet found an answer to this question.

pavelgromyko avatar Nov 16 '23 08:11 pavelgromyko

Any solution for this issue?

Edge-Repo avatar Apr 25 '24 08:04 Edge-Repo

+1, would appreciate any suggestions

radzevich avatar Jun 02 '24 20:06 radzevich