Skip to content

v3.0.0: Improved drag'n'drop!

Latest
Compare
Choose a tag to compare
@elisee elisee released this 21 Jan 04:53
· 22 commits to master since this release

This release adds support for handling external stuff (links, files, etc.) being dropped into the tree view through dropCallback and setting metadata when dragging starts from inside the tree view via dragStartCallback.

The text/plain data of the drag operation is not longer set from the dndText dataset property. Instead, you can use event.dataTransfer.setData("text/plain", ...) yourself in dragStartCallback to setup whatever drag metadata you want. See the live demo for an example, along with its source code.

Finally, when dropping a series of nodes onto a group, they will now be added at the end of its children rather than at the beginning.