Dashral Pro is on the wayGet 30% off at launch

Dashral

Kanban boardPro

Drag cards between columns with a line where they land, work-in-progress limits, a filter by person and quick add.

When to use

  • Cards in columns you drag between, with work-in-progress limits, a filter by person and quick add.
  • Task boards, sales pipelines, hiring and content calendars.

When not to use

  • Long lists people sort and filter more than they move: Orders table or a Data Table.
  • Work with more than six or so stages: the columns stop fitting; a table with a status filter.

Usage

Kanban board with your own data: every prop has the sample as its default, so pass only what you have.

example.tsx
import { KanbanBoard } from "@/components/dashral/blocks/kanban-board"

<KanbanBoard
  title="Sprint 14"
  people={team}
  columns={columns}
  tasks={tasks}
  onMove={(id, column, before) => api.tasks.move(id, column, before)}
  onAdd={(column, title) => api.tasks.create({ column, title })}
  onDelete={(id) => api.tasks.delete(id)}
/>

API reference

KanbanBoard

A project board: four columns with counts and work-in-progress limits that warn when crossed. Drag a card to move or reorder it, with a line where it will land; every card's menu moves it too, for the keyboard and touch. Filter by person, and add a task at the bottom of any column. Your board comes from props (a new task list replaces what's shown), and every change goes to your handlers; one that throws is undone, with its message.

PropTypeDefault
titleReact.ReactNode"Website relaunch"
notestring

After the count of tasks done.

"launch on Nov 4"
peopleKanbanPerson[]sample
columnsKanbanColumn[]sample
labelsRecord<string, LabelColor>

Each label's badge color.

sample
tasksKanbanTask[]sample
todayDate

For due dates: overdue before it, soon within two days.

sample
onMove(id: string, column: string, before: string | null) => Promise<void> | void

A card moved: to this column, before this task (or at the end).

—
onAdd(column: string, title: string) => Promise<KanbanTask | void> | KanbanTask | void

A task added at the bottom of a column; return it as stored to show it so.

—
onDelete(id: string) => Promise<void> | void—

type KanbanPerson

PropTypeDefault
idstring—
namestring—
srcstring—

type KanbanColumn

A column: its title, a work-in-progress limit that warns when crossed, and its dot's color class. The last is "done".

PropTypeDefault
idstring—
titlestring—
limitnumber—
dotstring—

type KanbanTask

PropTypeDefault
idstring—
titlestring—
columnColumnId—
labelLabel—
assigneestring—
duestring—
commentsnumber—
subtasks[done: number, total: number]—