Skip to content
Patternfly Logo

Drag and drop

Info alert:Beta feature

This Beta component is currently under review and is still open for further evolution. It is available for use in product. Beta components are considered for promotion on a quarterly basis. Please join in and give us your feedback or submit any questions on the PatternFly forum or via Slack. To learn more go to our Beta components page on GitHub.

Examples

Basic

Item
Item
Item
Item
Item
Item
Item
Item

Dragging

Item
Item
Item
Item
Item
Item
Item
Item

Drag outside

Item
Item
Item
Item
Item
Item
Item
Item

Documentation

Usage

Class
Applied to
Outcome
.pf-c-draggable
*
Initiates a draggable element.
.pf-c-droppable
*
Initiates a droppable element.
.pf-m-dragging
.pf-c-draggable, .pf-c-droppable
Indicates a draggable and droppable element are in the dragging state.
.pf-m-drag-outside
.pf-c-draggable, .pf-c-droppable
Indicates a draggable element is dragged outside of a droppable element.

CSS variables

.pf-c-draggable--pf-c-draggable--Cursor
auto
.pf-c-draggable--pf-c-draggable--m-dragging--Cursor
grabbing
.pf-c-draggable--pf-c-draggable--m-dragging--BoxShadow
0 0.25rem 0.5rem 0rem rgba(3, 3, 3, 0.12), 0 0 0.25rem 0 rgba(3, 3, 3, 0.06)
.pf-c-draggable--pf-c-draggable--m-dragging--after--BorderWidth
1px
.pf-c-draggable--pf-c-draggable--m-dragging--after--BorderColor
#06c
.pf-c-draggable--pf-c-draggable--m-drag-outside--Cursor
not-allowed
.pf-c-draggable--pf-c-draggable--m-drag-outside--after--BorderColor
#c9190b
.pf-c-draggable.pf-m-dragging--pf-c-draggable--Cursor
grabbing
.pf-c-draggable.pf-m-drag-outside--pf-c-draggable--m-dragging--Cursor
not-allowed
.pf-c-draggable.pf-m-drag-outside--pf-c-draggable--m-dragging--after--BorderColor
#c9190b
.pf-c-droppable--pf-c-droppable--m-dragging--after--BackgroundColor
rgba(255, 255, 255, 0.6)
.pf-c-droppable--pf-c-droppable--m-dragging--after--BorderWidth
1px
.pf-c-droppable--pf-c-droppable--m-dragging--after--BorderColor
#06c
.pf-c-droppable--pf-c-droppable--m-drag-outside--after--BorderColor
#c9190b
.pf-c-droppable.pf-m-drag-outside--pf-c-droppable--m-dragging--after--BorderColor
#c9190b

View source on GitHub