Module
React.DndKit.Types
- Package
- purescript-react-dnd-kit
- Repository
- i-am-the-slime/purescript-react-dnd-kit
#Coordinates Source
type Coordinates = { x :: Number, y :: Number }2D coordinates
#CallbackRef Source
data CallbackRefCallback ref passed to DOM elements for dnd-kit to track them.
Pass this as the ref prop on your DOM element.
#DraggableId Source
#DroppableId Source
#FeedbackType Source
#move Source
move :: FeedbackType#Source Source
type Source = { element :: Maybe Element, id :: DraggableId }Source entity in a drag operation
#Target Source
type Target = { element :: Maybe Element, id :: DroppableId }Target entity in a drag operation
#DragOperationSnapshot Source
type DragOperationSnapshot = { activatorEvent :: Maybe Event, canceled :: Boolean, position :: { current :: Coordinates, initial :: Coordinates }, source :: Maybe Source, target :: Maybe Target, transform :: Coordinates }Snapshot of the current drag operation, available on all events
#DragStartEvent Source
type DragStartEvent = { operation :: DragOperationSnapshot }#DragMoveEvent Source
type DragMoveEvent = { by :: Maybe Coordinates, operation :: DragOperationSnapshot, to :: Maybe Coordinates }#DragOverEvent Source
type DragOverEvent = { operation :: DragOperationSnapshot }#DragEndEvent Source
type DragEndEvent = { canceled :: Boolean, operation :: DragOperationSnapshot }#CollisionEvent Source
type CollisionEvent = { collisions :: Array Collision }#DragDropManager Source
data DragDropManagerThe central drag-drop manager (opaque)
#CollisionDetector Source
data CollisionDetectorA collision detector function (opaque)
#DraggableInstance Source
data DraggableInstanceDraggable instance (opaque)
#DroppableInstance Source
data DroppableInstanceDroppable instance (opaque)
#SortableInstance Source
data SortableInstanceSortable instance (opaque)
#callbackRef Source
callbackRef :: forall a. CallbackRef -> aConvert a CallbackRef to any ref type expected by DOM elements.