Shadcn-style Kanban Board
LayoutShadcn-style kanban board for React. Drag-and-drop kanban board for task management with multi-column layout controls.
KanbanLayout · Web
Loading Storybook preview…
Installation
bun add @otfdashkit/ui
Usage
Import Kanban from @otfdashkit/ui.
Code
import { Kanban } from '@otfdashkit/ui'
const columns = [
{ id: 'todo', title: 'To Do', cards: [{ id: '1', title: 'Design login page', badge: 'UI' }] },
{ id: 'progress', title: 'In Progress', cards: [{ id: '2', title: 'Auth flow', description: 'OAuth + JWT' }] },
{ id: 'done', title: 'Done', cards: [{ id: '3', title: 'CI/CD setup', badge: 'DevOps' }] },
]
export function ProjectBoard() {
const [cols, setCols] = useState(columns)
return (
<Kanban
columns={cols}
onMoveCard={(cardId, fromCol, toCol) => {
// update cols state
}}
/>
)
}Props
Props declared in the Kanban source. Inherited HTML attributes are not listed.
| Prop | Type | Default | Description |
|---|---|---|---|
| columnsrequired | KanbanColumnDef[] | ||
| className | string | ||
| onMoveCard | (cardId: string, fromCol: string, toCol: string) => void |