angular-ui-tree/angular-ui-tree

Connected trees, unable to drag last node out of a tree and then put it back without 2 drag events

tylerhaugen-stanley opened this issue · 0 comments

Do you want to request a feature or report a bug?
Reporting a bug

Steps to reproduce

  1. Open the connected tree example.
  2. Delete item 2, 3, & 4 from tree 2
  3. Start dragging item 1 from tree 2
  4. Hover over tree 1
  5. Change your mind and decide to put item 1 back into tree 2
  6. You will be unable to drop the node into tree 2 until you release the node into tree 1, and then start dragging again

What is the expected behavior?
Be able to take the last node out of a tree, hover over a different tree, and then place it back into the original tree without dropping the node.

Which versions of Angular, UI Tree and which browser / OS are affected by this issue? Did this work in previous versions of Angular, UI Tree? Please also test with the latest version.
Angular UI: 2.22.5
Chrome OSX: 59.0.3071.104 (Official Build) (64-bit)

Other information (e.g. stacktraces, related issues, suggestions how to fix)
Suggestion to fix:

  • When the last node of a tree is dragged out of the tree, insert a div with the angular-ui-tree-empty class.