-
-
Notifications
You must be signed in to change notification settings - Fork 659
Correct way to pull draggable item from the outside and converting it to a moveable on the fly? #920
Description
Environments
- Moveable Component version: 0.47.9
- Selecto: 1.22.1
Description
I want to have this: On my left panel are items (placeholders) that are draggable in the classic way. When those are pulled into my drag area, the classic drag image will be hidden and at the same location, I create a new html element that is already in the state of dragging, so we have a seamless transition. When the left mouse button is released, that dragged element is finally placed AND the placeholder still resides in the left panel, so he can be placed many times.
Problem is: whenever the dragEnter is triggered, the new element is placed and it is selected, but it doesn't move with the mouse. Only when I lift the left mouse button, the element will snap to the mouse cursor and will move with it (even though no button is pressed anymore).
I have the feeling, that my way of approaching this problem is fundamentally wrong. What would be the correct way?
Thanks!
