Xinxin
Xinxin
like 'max level': https://github.com/phphe/vue-draggable-nested-tree/blob/master/src/examples/MaxLevel.vue change method ondrag: ```js ondrag(node) { th.depthFirstSearch(this.store.rootData.children, (childNode) => { this.$set(childNode, 'droppable', childNode.open) }) }, ```
```js ondragend: {type: Function}, // hook. return false to prevent drop. arguments(node, draggableHelperInfo) node._vm.store.dplh // placeholder node._vm.store.dplh.parent node._vm.store.dplh.parent.text node.text ````
the placeholder will be replaced after drop, so think placeholder(dplh) as target node.
```js // previousSibling index = dplh.parent.children.indexOf(dplh) dplh.parent.children[index-1] ```
I am developing a new version. It is not in latest plan.
Ignore it if it does not affect the result. I am reconstructing this repo so I will not solve the issue.
> Sorry, I made a mistake. > > The `targetPath` still point to the original node. I think you want to get the node after the moved node. Check follow...
It is difficult to use sticky on native table. You may need use div instead of it.