createKanban API
transfer primitive.Related
Explore these related pages for additional context and usage patterns.
| Page | Category |
|---|---|
| createKanban | Data |
| createSortable | Data |
| useDragDrop | System |
| createRegistry | Registration |
Functions
createKanban
(_options?: KanbanOptions) => KanbanContext<ItemZ, ColZ>Create a headless two-level sortable orchestrator.
Options
disabled
MaybeRefOrGetter<boolean> | undefinedDisabled state for the entire model instance
Default: false
multiple
MaybeRefOrGetter<boolean> | undefinedAllow multiple tickets to be selected simultaneously
Default: false
Properties
columns
SortableContext<ColZ, KanbanColumnTicket<ItemZ, ColZ>>Column registry. Use this for column register / unregister / move / swap / reorder.
on
KanbanEventListener<ItemZ>Subscribe to the kanban-level transfer:ticket event, fired after each
successful cross-column move. Registry events (register:ticket,
unregister:ticket, move:ticket) live on the columns registry — use
kanban.columns.on(...) for those, or column.items.on(...) for
per-column intra-column reorder events.
off
KanbanEventListener<ItemZ>Unsubscribe from the transfer:ticket event. Must be called with the same
callback reference used to subscribe.
Methods
transfer
(id: ID, toColumnId: ID, toIndex: number) => SortableTicket<ItemZ> | undefinedMove an item across columns. Same-column transfer (where toColumnId
matches the item's current column) collapses to column.items.move and
does not emit transfer:ticket.
Returns the moved ticket, or undefined when gated (kanban / source / destination /
item disabled, destination.accept rejected, unknown id, duplicate destination id).