Closed gusye1234 closed 10 months ago
Drag and drop is not an inherently accessible behavior since many users have no ability to use a mouse. So in order to keep this library minimal in scope and to design it inclusively, we will not be able to support this.
You are welcome to use the customization features that we provide to add in whatever you’d like, but I would encourage you to avoid drag and drop if you want accessibility. Maybe a library with a different ethical purpose will support what you’re looking for.
Microsoft's Fluent Design System has a tree component and it supports keyboard interactions: https://master--628d031b55e942004ac95df1.chromatic.com/?path=/docs/components-tree--default&globals=storybook_fluentui-react-addon_theme:web-light#drag-and-drop
The link you sent says the opposite:
The tree component does not offer built-in drag-and-drop functionality. Yet, it's been designed with adaptability in mind, allowing for easy integration with third-party libraries to fulfill this need.
I imagine you could do the same with our library, but then you’d have to make sure you also provide an accessible way to provide manual reordering for users who are unable to use a mouse. It’s for that reason that drag n drop is outside of the scope of this library.
Lastly, no shade on fluent, but the accessibility issues in Microsoft’s library are what caused us to take over this library from the original maintainer.
Describe the solution you'd like Hello, thank you for your work. I am using your library for prototyping our product. I hope this library can support drag and drop operations because when it comes to rearranging documents or directories, dragging and dropping feels like a natural way to do it.
What value does this proposed solution bring to users? Users can intuitively interact with the treeview.
Describe alternatives you've considered Actually I can't remeber any alternative to replace the drag&drop operation.