- Implementation
- Dnd.Zone Props
- Dnd.Handle Props
- Dnd.SortLine Props
Bring your own drag-and-drop interactions.While these components are intended to help you create drag and drop experiences that align with our designs, they do not provide the actual drag-and-drop interactions. You should evaluate external libraries make the best choice for your needs.
Common Examples
Zone
TheDnd.Zone can be used to style an element as a drop zone.Handle
TheDnd.Handle is an icon which helps users understand that something is draggable.Handle Button
TheDnd.HandleButton is a button-wrapped icon which helps users understand that something is draggable. Use this if your draggable item contains other interactive elements.Sort Line
TheDnd.SortLine indicates where an item will be dropped in a sortable list.The width of the line is based upon its nearest relatively positioned ancestor.This component should be used when you’re building an experience that is sortable in one dimension (i.e. vertical or horizontal lists). It is not suitable for sorting two-dimensional sorting (e.g. grids).DndSort
If you’re not looking to create your own entire drag and drop solution, check to see ifDndSort is capable of supporting your needs. It’s a pre-built composition that uses all of these Dnd components to cover many basic cases including: sorting a list, arranging items into groups, or both. Read more about that component here.Best Practices
Draggables with interactivity
Do
Don’t





