-
Notifications
You must be signed in to change notification settings - Fork 2.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
BUG move the sort When there is only one component in the container #167
Comments
jsfidle? scenario? |
BUG Bescription : There are two containers A and B, there is a content in B, no in B, drag the contents from A to B when the mouse button does not release and move in the B container, this will trigger the method : |
Hello @shenzhirong , please provide a jsfiddle. Thanks |
example path: https://github.com/David-Desmaisons/draggable-example |
yes, i found this limitation too in my project. i think that until b lie in the box that has a bigger size than b itselft in a, b can drop in a correctly, or error will be trriggled!!!! |
I use the version is also 2.13.1 。 You need to set the css first : Then you only need to drag the contents of container A to container B, dragged into the container B up and down the mouse |
OK. got it. It is linked to the use of the move prop in this demo application. |
thanks . If you fix this bug please tell me |
@shenzhirong I will provide a corrected version probably with week-end |
@shenzhirong It is fixed in version v2.14.0 |
I have a related issue I think. I can drop elements on the draggable container just fine. However, if there is one element in the container when the component loads, for example, one item in the cart, if I try to drag another one, the element gets pushed to the first index. Then as soon as I try to drag either of the two elements, I get a Cannot read property 'element' of null error. To summarize.... Draggable works as expected unless it is loaded with one item. If there are multiple items, draggable works fine. If there is one component in the container when the component is loaded, and I remove it, then try to drag a new item onto it, I get the same error. So you can narrow it down to "Draggable acts funny when loaded with one item." I'll try to create a repo to reproduce soon. |
Uncaught TypeError: Cannot read property 'map' of undefined
method:function computeVmIndex(vnodes, element) {
return vnodes.map(elt => elt.elm).indexOf(element)
}
The text was updated successfully, but these errors were encountered: