vue-slicksort
vue-slicksort copied to clipboard
[Bug] List with group + press-delay will remove item on click
Description
Example link: https://stackblitz.com/edit/vitejs-vite-n4debu?file=src%2FApp.vue&terminal=dev
Please see the video
https://user-images.githubusercontent.com/5575082/157005129-ed65728e-0170-4667-85f3-9a1153f63955.mp4
I think that we need to set the sortableGhost
to null
here:
https://github.com/Jexordexan/vue-slicksort/blob/dev/src/ContainerMixin.ts#L655
Or it will be removed here: https://github.com/Jexordexan/vue-slicksort/blob/dev/src/ContainerMixin.ts#L515
Reproduce steps:
- click and hold on any item until its background color changed
- click on the same item again
I've tested the solution, but the bug still exists.
Found that if rerender the list, everything is as expected:
<SlickList v-model:list="..." group="..." :pressDelay="500" :key="componentKey" @sort-end="componentKey++" @contextmenu="$event.preventDefault()" "