react-component / react-component/tree
Cannot drag a node into an empty folder
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 1.3k
- Forks
- 490
- Avg merge
- 3d 17h
- Merged PRs (30d)
- 5
Description
In the demos, if you drag all the nodes out of a folder, you cannot drag anything back into the folder anymore (since the folder turns to a leaf node).
In other words, it seems the dropPosition is never 0 for leaf nodes? How can I drag a node into an empy folder?
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the demos' drag-and-drop handling and trace how dropPosition is calculated for leaf nodes. Reproduce the case where all nodes are dragged out of a folder, then make an empty folder accept a dragged node and verify that the behavior works in the demos.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- react, typescript
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100