ReorderTarget beta
Interface of @v12-engine/client/kit
ts
export interface ReorderTargetWhat a row is dropped on (Reorder.target): with where the line is shown (data-reorder-over)
Members
"data-reorder-over"
ts
'data-reorder-over'?: 'before' | 'after';Which side of the row the dragged one would go, shown as a line; nothing when it is not over the row
"data-reorder-row"
ts
'data-reorder-row': number;The row's index in the list, which the drop finds the row by
onDragLeave
ts
onDragLeave: () => void;Clears the line when the pointer leaves the row
onDragOver
ts
onDragOver: (event: DragEvent) => void;Moves the line to the side of the row the pointer is on, while a row of this list is dragged over it
onDrop
ts
onDrop: (event: DragEvent) => void;Drops the dragged row here, telling onReorder the index it came from and where it goes