# Kanban board

A controlled multi-column board with typed consumer-owned cards, responsive horizontal navigation and native adjacent-move controls.

Access: pro. Category: Blocks. Kind: composite.

## When to use

- Use it when a page needs a controlled multi-column board with typed consumer-owned cards, responsive horizontal navigation and native adjacent-move controls.
- Choose it inside an authenticated product surface when the host application owns routing, persistence, and service calls.

## Alternatives

- Choose empty-state instead when empty collections, search results and errors with a clear next action is the actual interface need, rather than kanban board.

## Setup for agents

Use React 19 and TypeScript. Initialize shadcn for your framework, then merge this exact entry into components.json:

```json
{
  "registries": {
    "@tidal-pro": {
      "url": "https://tidalui.com/r/pro/{name}.json",
      "headers": {
        "Authorization": "Bearer ${TIDALUI_TOKEN}"
      }
    }
  }
}
```

The namespace must be named **@tidal-pro** because transitive Pro dependencies use that namespace. Obtain an agent key from your active Pro account at https://tidalui.com/account. Keep TIDALUI_TOKEN in your local environment, never in components.json, client code, Git or logs.

```sh
export TIDALUI_TOKEN='your-private-agent-key'
npx shadcn@latest add @tidal-pro/waitlist-form
npx shadcn@latest add https://tidalui.com/r/tidal-button.json
```

Free command: `npx shadcn@latest add https://tidalui.com/r/<name>.json`.
Pro command: `npx shadcn@latest add @tidal-pro/<name>`.

Import the base stylesheet and every stylesheet listed on the installed item's metadata. For example:

```tsx
import "./components/ui/tidal.css";
import "./components/ui/hero-section.css";
// Place installed components inside this wrapper:
<div className="tidal-scope" data-theme="dark">...</div>
```

Omit data-theme for the default light theme. Put the attribute on the same tidal-scope element for dark mode. Every component installs the shared free tidal-base dependency. After upgrading, run `npx shadcn@latest add https://tidalui.com/r/tidal-base.json --overwrite` to receive current tokens. Review local modifications before overwriting.

Vite: Use React + TypeScript. Map @/* to ./src/* in paths and Vite resolve.alias. Import tidal.css and each component stylesheet in your application entry.

Next.js 15 App Router: Next.js App Router: import tidal.css and component CSS in app/layout.tsx. Interactive examples belong in a client component with "use client". Map @/* to ./* or ./src/* to match your project.

TypeScript 6: use paths without baseUrl:

```json
{
  "compilerOptions": {
    "paths": {
      "@/*": [
        "./src/*"
      ]
    }
  }
}
```

Pro registry requests are server/CLI-only. Use the same-origin account interface in a browser; cross-origin Authorization preflights are intentionally unsupported.


## Install Kanban board

```sh
npx shadcn@latest add @tidal-pro/kanban-board
```

Stylesheets: `components/ui/tidal.css`, `components/ui/kanban-board.css`.

## Minimal example

```tsx
import"./components/ui/tidal.css";
import"./components/ui/kanban-board.css";
import{TidalKanbanBoard}from"./components/ui/kanban-board";
export default()=><div className="tidal-scope"><TidalKanbanBoard columns={[{id:"example",title:"Demo",accessibleName:"Demo",cards:[{id:"example",title:"Demo",accessibleName:"Demo"}]}]} title={"Demo"}/></div>;
```

## Structured props

- `TidalKanbanBoard.columns: ReadonlyArray<TidalKanbanColumn>`: Required columns value accepted by this exported component.
- `TidalKanbanBoard.title: ReactNode`: Required title value accepted by this exported component.
- `TidalKanbanBoard.cardHeadingLevel?: "div" | "h4" | "h5" | "h6" | undefined`: Optional card heading level value accepted by this exported component.
- `TidalKanbanBoard.cardTagsLabel?: ((card: TidalKanbanCard) => string) | undefined` (default (card) => `${card.accessibleName} tags`): Optional card tags label value accepted by this exported component.
- `TidalKanbanBoard.columnHeadingLevel?: "h3" | "h4" | "h5" | undefined`: Optional column heading level value accepted by this exported component.
- `TidalKanbanBoard.columnsLabel?: string | undefined` (default "Kanban columns"): Optional columns label value accepted by this exported component.
- `TidalKanbanBoard.countLabel?: ((count: number, column: TidalKanbanColumn) => ReactNode) | undefined` (default (count) => `${count} ${count === 1 ? "card" : "cards"}`): Optional count label value accepted by this exported component.
- `TidalKanbanBoard.description?: ReactNode`: Optional description value accepted by this exported component.
- `TidalKanbanBoard.emptyMessage?: ReactNode` (default "No columns are available."): Optional empty message value accepted by this exported component.
- `TidalKanbanBoard.eyebrow?: ReactNode` (default "Kanban board"): Optional eyebrow value accepted by this exported component.
- `TidalKanbanBoard.footer?: ReactNode`: Optional footer value accepted by this exported component.
- `TidalKanbanBoard.headingLevel?: "h2" | "h3" | "h4" | undefined` (default "h2"): Optional heading level value accepted by this exported component.
- `TidalKanbanBoard.nextMoveLabel?: ((request: TidalKanbanMoveRequest) => string) | undefined` (default (request) =>
        `Move ${request.card.accessibleName} to ${request.toColumn.accessibleName}`): Optional next move label value accepted by this exported component.
- `TidalKanbanBoard.onMoveCard?: ((request: TidalKanbanMoveRequest, event: ReactMouseEvent<HTMLButtonElement>) => void) | undefined`: Callback invoked when the move card interaction is proposed.
- `TidalKanbanBoard.previousMoveLabel?: ((request: TidalKanbanMoveRequest) => string) | undefined` (default (request) =>
        `Move ${request.card.accessibleName} to ${request.toColumn.accessibleName}`): Optional previous move label value accepted by this exported component.

## Complete usage example

[Source](https://tidalui.com/examples/kanban-board.tsx) | [Manifest](https://tidalui.com/examples/kanban-board.json). Install the listed additional dependencies. Consumer fixture: TypeScript pass; Vite pass. This fixture check is distinct from the actual shadcn install receipt.

```tsx
import "./components/ui/tidal.css";

import { useId, useLayoutEffect, useMemo, useRef, useState } from "react";

import { Columns3, RotateCcw } from "lucide-react";

import { TidalKanbanBoard, type TidalKanbanCard, type TidalKanbanColumn, type TidalKanbanMoveRequest } from "./components/ui/kanban-board";

import "./components/ui/kanban-board.css";



const tidalExampleStyles = ".tidal-scope .kanban-demo,\n.tidal-scope .kanban-demo * {\n  box-sizing: border-box;\n}\n\n.tidal-scope .kanban-demo {\n  width: 100%;\n  max-width: 1220px;\n  min-width: 0;\n  overflow: hidden;\n  border: 1px solid var(--t-border);\n  border-radius: 22px;\n  background: var(--t-surface);\n  color: var(--t-ink);\n  box-shadow: 0 34px 72px -56px #0000008f;\n  container: kanban-demo / inline-size;\n}\n\n.tidal-scope .kanban-demo-toolbar {\n  display: flex;\n  min-width: 0;\n  align-items: center;\n  justify-content: space-between;\n  gap: 22px;\n  padding: 17px 20px;\n  border-bottom: 1px solid var(--t-border);\n  background: var(--t-ink);\n  color: var(--t-surface);\n}\n\n\n.tidal-scope .kanban-demo-summary,\n.tidal-scope .kanban-demo-summary > span {\n  display: flex;\n  align-items: center;\n}\n\n.tidal-scope .kanban-demo-kicker {\n  display: block;\n  color: var(--t-muted);\n  font-size: 11px;\n  font-weight: 690;\n  letter-spacing: 0.11em;\n  line-height: 1.4;\n  text-transform: uppercase;\n}\n\n.tidal-scope .kanban-demo-toolbar .kanban-demo-kicker {\n  color: color-mix(in srgb, var(--t-surface) 66%, var(--t-ink));\n}\n\n.tidal-scope .kanban-demo-summary {\n  flex: none;\n  gap: 7px;\n}\n\n.tidal-scope .kanban-demo-summary > span {\n  min-height: 32px;\n  gap: 5px;\n  padding: 6px 9px;\n  border: 1px solid color-mix(in srgb, var(--t-surface) 22%, transparent);\n  border-radius: 10px;\n  color: color-mix(in srgb, var(--t-surface) 70%, var(--t-ink));\n  font-size: 11px;\n  line-height: 1.2;\n}\n\n.tidal-scope .kanban-demo-summary strong {\n  color: var(--t-surface);\n  font-weight: 700;\n  font-variant-numeric: tabular-nums;\n}\n\n.tidal-scope .kanban-demo-summary button {\n  display: inline-flex;\n  min-width: 44px;\n  min-height: 44px;\n  align-items: center;\n  justify-content: center;\n  gap: 7px;\n  padding: 8px 11px;\n  border: 1px solid color-mix(in srgb, var(--t-surface) 28%, transparent);\n  border-radius: 10px;\n  background: var(--t-surface);\n  color: var(--t-ink);\n  font: inherit;\n  font-size: 11px;\n  font-weight: 650;\n  cursor: pointer;\n  transition: transform 140ms var(--t-ease-out);\n}\n\n.tidal-scope .kanban-demo-summary button:active {\n  transform: scale(0.96);\n}\n\n.tidal-scope .kanban-demo-summary button:focus-visible {\n  outline: 2px solid var(--t-surface);\n  outline-offset: 3px;\n}\n\n.tidal-scope .kanban-demo-stage {\n  display: grid;\n  gap: 13px;\n  min-width: 0;\n  padding: 18px;\n  background:\n    linear-gradient(var(--t-border) 1px, transparent 1px),\n    linear-gradient(90deg, var(--t-border) 1px, transparent 1px),\n    var(--t-subtle);\n  background-size: 22px 22px;\n}\n\n.tidal-scope .kanban-demo-detail {\n  display: grid;\n  min-width: 0;\n  grid-template-columns: 46px minmax(0, 1fr) auto;\n  align-items: center;\n  gap: 13px;\n  padding: 14px;\n  border: 1px solid var(--t-border);\n  border-radius: 18px;\n  background: var(--t-surface);\n}\n\n.tidal-scope .kanban-demo-detail-icon {\n  display: grid;\n  width: 46px;\n  height: 46px;\n  place-items: center;\n  border-radius: 10px;\n  background: var(--t-ink);\n  color: var(--t-surface);\n}\n\n.tidal-scope .kanban-demo-detail > div:nth-child(2) {\n  min-width: 0;\n}\n\n.tidal-scope .kanban-demo-detail h3 {\n  margin: 5px 0 0;\n  font-size: 14px;\n  font-weight: 650;\n  letter-spacing: -0.025em;\n  line-height: 1.3;\n  overflow-wrap: anywhere;\n}\n\n.tidal-scope .kanban-demo-detail p {\n  margin: 4px 0 0;\n  color: var(--t-muted);\n  font-size: 11px;\n  line-height: 1.5;\n  overflow-wrap: anywhere;\n}\n\n.tidal-scope .kanban-demo-detail dl {\n  display: flex;\n  gap: 8px;\n  margin: 0;\n}\n\n.tidal-scope .kanban-demo-detail dl > div {\n  min-width: 92px;\n  padding: 8px 10px;\n  border: 1px solid var(--t-border);\n  border-radius: 10px;\n  background: var(--t-subtle);\n}\n\n.tidal-scope .kanban-demo-detail dt,\n.tidal-scope .kanban-demo-detail dd {\n  margin: 0;\n  font-size: 11px;\n  line-height: 1.35;\n  overflow-wrap: anywhere;\n}\n\n.tidal-scope .kanban-demo-detail dt {\n  color: var(--t-muted);\n}\n\n.tidal-scope .kanban-demo-detail dd {\n  margin-top: 3px;\n  color: var(--t-ink);\n  font-weight: 650;\n}\n\n.tidal-scope .kanban-demo-status {\n  min-height: 34px;\n  margin: 0;\n  padding: 9px 12px;\n  border-inline-start: 2px solid var(--t-ink);\n  background: var(--t-surface);\n  color: var(--t-muted);\n  font-size: 11px;\n  line-height: 1.55;\n  overflow-wrap: anywhere;\n}\n\n@container kanban-demo (max-width: 720px) {\n  .tidal-scope .kanban-demo-toolbar {\n    align-items: flex-start;\n    padding: 14px;\n  }\n\n  .tidal-scope .kanban-demo-summary > span {\n    display: none;\n  }\n\n  .tidal-scope .kanban-demo-stage {\n    padding: 12px;\n  }\n\n  .tidal-scope .kanban-demo-detail {\n    grid-template-columns: 46px minmax(0, 1fr);\n  }\n\n  .tidal-scope .kanban-demo-detail dl {\n    grid-column: 1 / -1;\n  }\n}\n\n@container kanban-demo (max-width: 390px) {\n\n  .tidal-scope .kanban-demo-summary button {\n    width: 44px;\n    padding: 0;\n    font-size: 0;\n  }\n\n  .tidal-scope .kanban-demo-detail {\n    grid-template-columns: 1fr;\n  }\n\n  .tidal-scope .kanban-demo-detail-icon {\n    display: none;\n  }\n\n  .tidal-scope .kanban-demo-detail dl {\n    display: grid;\n    grid-template-columns: repeat(2, minmax(0, 1fr));\n  }\n\n  .tidal-scope .kanban-demo-detail dl > div {\n    min-width: 0;\n  }\n}\n\n@media (prefers-reduced-motion: reduce) {\n  .tidal-scope .kanban-demo-summary button {\n    transition-duration: 0.01ms;\n  }\n}";

type ColumnId = "backlog" | "progress" | "review";

type CardId = "brief" | "empty" | "navigation" | "tokens" | "qa";

const COLUMN_DEFINITIONS: readonly {
  id: ColumnId;
  title: string;
  description: string;
}[] = [
  { id: "backlog", title: "Backlog", description: "Ready to start" },
  { id: "progress", title: "In progress", description: "Active local work" },
  { id: "review", title: "Review", description: "Waiting for a read" },
];

const CARD_LIBRARY: Record<CardId, Omit<TidalKanbanCard, "footer">> = {
  brief: {
    id: "brief",
    title: "Confirm the page brief",
    accessibleName: "Confirm the page brief",
    eyebrow: "PLAN-12",
    description: "Resolve the final section order before implementation.",
    tags: ["Brief", "Structure"],
    meta: "Owner: Rowan · Sample priority: standard",
  },
  empty: {
    id: "empty",
    title: "Write the empty state",
    accessibleName: "Write the empty state",
    eyebrow: "COPY-08",
    description: "Draft concise local copy for the zero-item view.",
    tags: ["Copy"],
    meta: "Owner: Mina · One sample note",
  },
  navigation: {
    id: "navigation",
    title: "Build mobile navigation",
    accessibleName: "Build mobile navigation",
    eyebrow: "BUILD-24",
    description: "Keep every destination available at compact widths.",
    tags: ["Mobile", "Navigation"],
    meta: "Owner: Jules · Sample viewport: 390px",
  },
  tokens: {
    id: "tokens",
    title: "Reconcile spacing tokens",
    accessibleName: "Reconcile spacing tokens",
    eyebrow: "SYSTEM-06",
    description: "Compare component spacing with the neutral token scale.",
    tags: ["System"],
    meta: "Owner: Rowan · Local reference only",
  },
  qa: {
    id: "qa",
    title: "Review keyboard movement",
    accessibleName: "Review keyboard movement",
    eyebrow: "QA-19",
    description: "Exercise both native move buttons and the status update.",
    tags: ["Keyboard", "Review"],
    meta: "Owner: Mina · No device claim",
  },
};

const INITIAL_BOARD: Record<ColumnId, readonly CardId[]> = {
  backlog: ["brief", "empty"],
  progress: ["navigation", "tokens"],
  review: ["qa"],
};

export function KanbanBoardDemo() {
  const generatedId = useId().replace(/:/g, "");
  const detailTitleId = `kanban-demo-${generatedId}-detail-title`;
  const [board, setBoard] = useState(INITIAL_BOARD);
  const [selectedId, setSelectedId] = useState<CardId>("navigation");
  const [message, setMessage] = useState(
    "Use a card's arrow buttons to move it between adjacent columns.",
  );
  const resetRef = useRef<HTMLButtonElement>(null);
  const cardNodes = useRef(new Map<CardId, HTMLElement>());
  const moveFocus = useRef<{
    id: CardId;
    direction: "previous" | "next";
  } | null>(null);

  useLayoutEffect(() => {
    const intent = moveFocus.current;
    if (!intent) return;
    moveFocus.current = null;
    const card = cardNodes.current.get(intent.id);
    const target =
      card?.querySelector<HTMLButtonElement>(
        `button[data-direction="${intent.direction}"]:not(:disabled)`,
      ) ?? card?.querySelector<HTMLButtonElement>("button:not(:disabled)");
    target?.focus({ preventScroll: true });
  }, [board]);

  const columns = useMemo<readonly TidalKanbanColumn[]>(
    () =>
      COLUMN_DEFINITIONS.map((definition) => ({
        ...definition,
        accessibleName: definition.title,
        cards: board[definition.id].map((cardId) => {
          const card = CARD_LIBRARY[cardId];
          return {
            ...card,
            cardRef: (node) => {
              if (node) cardNodes.current.set(cardId, node);
              else cardNodes.current.delete(cardId);
            },
            footer: (
              <button
                type="button"
                aria-pressed={selectedId === cardId}
                onClick={() => {
                  setSelectedId(cardId);
                  setMessage(`${card.accessibleName} details selected.`);
                }}
              >
                Details
              </button>
            ),
          };
        }),
      })),
    [board, selectedId],
  );

  function moveCard(request: TidalKanbanMoveRequest) {
    const fromId = request.fromColumn.id as ColumnId;
    const toId = request.toColumn.id as ColumnId;
    const cardId = request.card.id as CardId;
    moveFocus.current = { id: cardId, direction: request.direction };
    setBoard((current) => ({
      ...current,
      [fromId]: current[fromId].filter((id) => id !== cardId),
      [toId]: [...current[toId], cardId],
    }));
    setSelectedId(cardId);
    setMessage(
      `${request.card.accessibleName} moved to ${request.toColumn.accessibleName} in this local preview.`,
    );
  }

  function resetBoard() {
    moveFocus.current = null;
    setBoard(INITIAL_BOARD);
    setSelectedId("navigation");
    setMessage("The local sample board was reset.");
    resetRef.current?.focus({ preventScroll: true });
  }

  const selectedCard = CARD_LIBRARY[selectedId];
  const selectedColumn = COLUMN_DEFINITIONS.find((column) =>
    board[column.id].includes(selectedId),
  );
  const totalCards = Object.values(board).reduce(
    (count, cardIds) => count + cardIds.length,
    0,
  );

  return (
    <section className="kanban-demo" aria-label="Kanban board preview">
      <header className="kanban-demo-toolbar">
        <div className="kanban-demo-summary" aria-label="Sample board totals">
          <span>
            <strong>{totalCards}</strong> cards
          </span>
          <span>
            <strong>{columns.length}</strong> columns
          </span>
          <button ref={resetRef} type="button" onClick={resetBoard}>
            <RotateCcw size={15} aria-hidden="true" />
            Reset
          </button>
        </div>
      </header>

      <div className="kanban-demo-stage">
        <TidalKanbanBoard
          title="Product delivery"
          eyebrow={null}
          description="Move cards between the three delivery stages."
          columns={columns}
          onMoveCard={moveCard}
          footer={
            <span>
              Fictional local data. Moving a card changes only this rendered
              React state.
            </span>
          }
        />

        <aside className="kanban-demo-detail" aria-labelledby={detailTitleId}>
          <div className="kanban-demo-detail-icon" aria-hidden="true">
            <Columns3 size={18} />
          </div>
          <div>
            <span className="kanban-demo-kicker">SELECTED CARD</span>
            <h3 id={detailTitleId}>{selectedCard.title}</h3>
            <p>{selectedCard.description}</p>
          </div>
          <dl>
            <div>
              <dt>Column</dt>
              <dd>{selectedColumn?.title}</dd>
            </div>
            <div>
              <dt>Reference</dt>
              <dd>{selectedCard.eyebrow}</dd>
            </div>
          </dl>
        </aside>

        <p className="kanban-demo-status" role="status" aria-live="polite">
          {message}
        </p>
      </div>
    </section>
  );
}

export default function AgentExample() {
  return (
    <div className="tidal-scope" data-theme="light" dir="ltr">
      <style>{tidalExampleStyles}</style>
      <KanbanBoardDemo />
    </div>
  );
}

```

## Gotchas

- The host application owns data, validation, persistence, navigation, and service side effects described by this API.

## Theme and accessibility

{"tokens":["--t-accent","--t-border","--t-border-strong","--t-canvas","--t-danger","--t-display","--t-ease-out","--t-ease-spring","--t-faint","--t-font","--t-ink","--t-line","--t-muted","--t-primary","--t-primary-contrast","--t-radius-card","--t-radius-control","--t-radius-overlay","--t-radius-panel","--t-ring","--t-shadow-lg","--t-shadow-soft","--t-soft","--t-subtle","--t-surface","--t-wash"],"darkMode":true}

{"keyboard":["Tab and Shift+Tab follow the component's native focus order.","Arrow-key behavior follows the exported composite-control implementation."],"aria":"The component wires labels and relationships from consumer-provided visible text or ARIA props; preserve those labels in production.","notes":"Verify focus visibility, text alternatives, contrast, and reduced motion in the final composition."}

title, typed columns and each column/card accessibleName are required. Consumers own column arrays and card positions. onMoveCard receives the card, source/destination columns and indexes after each native move button's onClick unless prevented. Card move buttons expose native props, type and refs; board, column and card attributes/refs pass through, including optional native drag events with no built-in drag behavior. Optional description, eyebrow, footer, empty messages, heading levels, countLabel, cardTagsLabel and move-label formatters are consumer-owned. Disabled cards/columns block component move controls. The component performs no reordering, drag orchestration, request, storage, persistence or backend work.
