N00ts / vue3-treeview

a simple treeview in vue js 3
MIT License
71 stars 61 forks source link

We should not be able to drag a leaf or a root into a leaf #51

Open SteamWind opened 4 months ago

SteamWind commented 4 months ago

Current behaviour

It is possible to drag anything into a leaf. When we do so, the element is put in the children of the leaf. But the leaf doesn't look like it can be opened (although it is possible to do so).

Repro

Drag anything into the 2 leaves available: Edit Events (forked)

Expected behaviour

One of the 2 solutions:

  1. Add a parameter that let the node or leaf have or have no children
  2. Don't let the leaves have children