Kanban Component
Basic Board (uncontrolled — the « Done » column starts empty)
Backlog4
Design the landing pagemedium
Write the documentationlow
Fix the login bughigh
Update dependencieslow
To do2
Refactor the theme layermedium
Add keyboard shortcutslow
Doing1
Kanban componenthigh
Done0
<Kanban defaultColumns={ [ { id , title , items : [...] } , ... ] } renderCard={ card => <KanbanCard title={ card.title } /> }/>// cards reorder within a column and move across columns, even empty onesReorderable Columns (drag a column by its header)
Backlog4
Design the landing pagemedium
Write the documentationlow
Fix the login bughigh
Update dependencieslow
To do2
Refactor the theme layermedium
Add keyboard shortcutslow
Doing1
Kanban componenthigh
Done0
<Kanban reorderableColumns defaultColumns={ columns } onChange={ ( next , change ) => ... }/>// change.type : 'card' | 'column' — column moves carry { column , fromIndex , toIndex }Project Board (rich cards : assignee, due date, tags)
To do2
Refonte de la page d'accueil
12 Jul
uiurgent
Migration de la base
18 Jul
infra
Doing1
Composant Kanban
5 Jul
dndui
Review1
Pickers dans les modales
4 Jul
fix
// renderCard composes freely with the library componentsrenderCard={ card => ( <KanbanCard><Avatar ... /><Badge ... /></KanbanCard>)}Editable Board (add / remove cards — the board lives in your state)
Backlog4
Design the landing page
Write the documentation
Fix the login bug
Update dependencies
To do2
Refactor the theme layer
Add keyboard shortcuts
Doing1
Kanban component
Done0
<Kanban columns={ board } onChange={ next => setBoard( next ) } renderFooter={ column => <Button onClick={ () => addCard( column.id ) }>Add</Button> }/>// adding / removing cards is plain setState — the board is your dataControlled Board (live column counts)
Board :Backlog : 4To do : 2Doing : 1Done : 0
Backlog4
Design the landing pagemedium
Write the documentationlow
Fix the login bughigh
Update dependencieslow
To do2
Refactor the theme layermedium
Add keyboard shortcutslow
Doing1
Kanban componenthigh
Done0
<Kanban columns={ board } onChange={ ( next , change ) => setBoard( next ) } renderCard={ card => <KanbanCard ... /> }/>// change = { item , fromColumn , toColumn , fromIndex , toIndex }Async Change with API Call (optimistic revert on failure)
Backlog4
Design the landing pagemedium
Write the documentationlow
Fix the login bughigh
Update dependencieslow
To do2
Refactor the theme layermedium
Add keyboard shortcutslow
Doing1
Kanban componenthigh
Done0
<Kanban defaultColumns={ columns } onChange={ ( next , change ) => api.moveCard( change ) }/>// onChange may return a promise : a rejection restores the previous boardProps Reference
| Prop | Type | Description |
|---|---|---|
columns / defaultColumns | Array | Controlled / uncontrolled columns : [ { id , title , items : [...] } ] (stable ids) |
onChange | function | (columns, { item, fromColumn, toColumn, fromIndex, toIndex }) => void | Promise — a rejected promise reverts the board (uncontrolled) |
renderCard | function | (item, column, index) => KanbanCard element |
renderHeader / renderFooter | function | (column) => custom column header / footer |
getColumnId / getItemId | function | Custom accessors for identity (default to column.id / item.id) |
reorderableColumns | boolean | Allow reordering the columns themselves by dragging their headers (change.type = 'column') |
disabled | boolean | Disable dragging for all cards |