# Issue list

Triage consumer-supplied issues with controlled filters, sorting, selection and native destinations.

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

## When to use

- Use it when a page needs triage consumer-supplied issues with controlled filters, sorting, selection and native destinations.
- 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 issue list.

## 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 Issue list

```sh
npx shadcn@latest add @tidal-pro/issue-list
```

Stylesheets: `components/ui/tidal.css`, `components/ui/issue-list.css`.

## Minimal example

```tsx
import"./components/ui/tidal.css";
import"./components/ui/issue-list.css";
import{TidalIssueList}from"./components/ui/issue-list";
export default(p:Parameters<typeof TidalIssueList>[0])=><div className="tidal-scope"><TidalIssueList {...p}/></div>;
```

## Structured props

- `TidalIssueList.issues: ReadonlyArray<TidalIssue>`: Required issues value accepted by this exported component.
- `TidalIssueList.onSelectionChange: (issue: TidalIssue, selected: boolean, event: ChangeEvent<HTMLInputElement>) => void`: Callback invoked when the selection change interaction is proposed.
- `TidalIssueList.summary: ReactNode`: Required summary value accepted by this exported component.
- `TidalIssueList.title: ReactNode`: Required title value accepted by this exported component.
- `TidalIssueList.bulkActions?: ReadonlyArray<TidalIssueBulkAction> | undefined` (default []): Optional bulk actions value accepted by this exported component.
- `TidalIssueList.description?: ReactNode`: Optional description value accepted by this exported component.
- `TidalIssueList.disabled?: boolean | undefined` (default false): Optional disabled value accepted by this exported component.
- `TidalIssueList.emptyAction?: TidalIssueEmptyAction | undefined`: Optional empty action value accepted by this exported component.
- `TidalIssueList.emptyContent?: ReactNode`: Optional empty content value accepted by this exported component.
- `TidalIssueList.error?: ReactNode`: Optional error value accepted by this exported component.
- `TidalIssueList.filters?: ReadonlyArray<TidalIssueFilter> | undefined` (default []): Optional filters value accepted by this exported component.
- `TidalIssueList.footer?: ReactNode`: Optional footer value accepted by this exported component.
- `TidalIssueList.headingLevel?: "h2" | "h3" | "h4" | undefined` (default "h2"): Optional heading level value accepted by this exported component.
- `TidalIssueList.labels?: Partial<TidalIssueListLabels> | undefined`: Optional labels value accepted by this exported component.
- `TidalIssueList.listProps?: Omit<HTMLAttributes<HTMLUListElement>, "aria-disabled" | "children" | "dangerouslySetInnerHTML"> | undefined` (default {}): Optional list props value accepted by this exported component.
- `TidalIssueList.listRef?: Ref<HTMLUListElement> | undefined`: Optional list ref value accepted by this exported component.
- `TidalIssueList.loading?: boolean | undefined` (default false): Optional loading value accepted by this exported component.
- `TidalIssueList.sort?: TidalIssueSort | undefined`: Optional sort value accepted by this exported component.

## Complete usage example

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

```tsx
"use client";

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

import { useEffect, useLayoutEffect, useMemo, useRef, useState, type MouseEvent } from "react";

import { TidalIssueList, type TidalIssue, type TidalIssueFilter } from "./components/ui/issue-list";

import "./components/ui/issue-list.css";

function tidalExampleAvatarDataUri(seed: unknown) {
  const text = String(seed).replace(/[^a-z0-9]/gi, "").slice(-2) || "UI";
  const palette = ["#333333", "#555555", "#777777", "#999999", "#bbbbbb"];
  const color = palette[Array.from(text).reduce((sum, character) => sum + character.charCodeAt(0), 0) % palette.length];
  const svg = `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 96 96"><rect width="96" height="96" rx="48" fill="${color}"/><circle cx="48" cy="38" r="17" fill="white" fill-opacity=".92"/><path d="M18 92c3-22 15-34 30-34s27 12 30 34" fill="white" fill-opacity=".92"/></svg>`;
  return `data:image/svg+xml,${encodeURIComponent(svg)}`;
}

function tidalExampleImageDataUri(label: string) {
  const safeLabel = label.replace(/[<>&]/g, "").slice(0, 28) || "Sample image";
  const svg = `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1200 675"><defs><linearGradient id="g" x1="0" x2="1" y1="0" y2="1"><stop stop-color="#171717"/><stop offset="1" stop-color="#555555"/></linearGradient></defs><rect width="1200" height="675" fill="url(#g)"/><circle cx="950" cy="100" r="260" fill="white" fill-opacity=".08"/><text x="80" y="570" fill="white" font-family="system-ui,sans-serif" font-size="64" font-weight="700">${safeLabel}</text></svg>`;
  return `data:image/svg+xml,${encodeURIComponent(svg)}`;
}

const tidalExampleStyles = ".tidal-scope .issue-list-demo {\n  width: 100%;\n  max-width: 820px;\n  min-width: 0;\n}\n.tidal-scope .issue-list-demo > .tidal-issue-list {\n  padding: 26px;\n  border: 1px solid var(--t-border);\n  border-radius: 18px;\n  background: var(--t-surface);\n  box-shadow:\n    0 2px 3px #00000003,\n    0 18px 46px #00000007;\n}\n.tidal-scope .issue-list-demo-detail {\n  margin-top: 14px;\n  padding: 18px;\n  border: 1px solid var(--t-border);\n  border-radius: 14px;\n  background: var(--t-subtle);\n}\n.tidal-scope .issue-list-demo-detail > div {\n  display: flex;\n  justify-content: space-between;\n  gap: 12px;\n  font:\n    11px/1.4 ui-monospace,\n    monospace;\n}\n.tidal-scope .issue-list-demo-detail h3 {\n  margin: 10px 0 5px;\n  font-size: 16px;\n  line-height: 1.35;\n  overflow-wrap: anywhere;\n}\n.tidal-scope .issue-list-demo-detail p {\n  margin: 0;\n  color: var(--t-muted);\n  font-size: 12px;\n  line-height: 1.55;\n  overflow-wrap: anywhere;\n}\n.tidal-scope .issue-list-demo-detail button {\n  min-width: 44px;\n  min-height: 44px;\n  margin-top: 14px;\n  padding: 8px 14px;\n  border: 1px solid var(--t-border);\n  border-radius: 9px;\n  background: var(--t-surface);\n  color: var(--t-ink);\n  font: 600 12px/1.2 inherit;\n  cursor: pointer;\n}\n.tidal-scope .issue-list-demo-detail:focus-visible {\n  outline: 2px solid var(--t-accent);\n  outline-offset: 4px;\n}\n@media (max-width: 500px) {\n  .tidal-scope .issue-list-demo > .tidal-issue-list {\n    padding: 16px;\n  }\n}\n@media (prefers-reduced-motion: reduce) {\n  .tidal-scope .issue-list-demo-detail {\n    scroll-behavior: auto;\n  }\n}";

type DemoIssue = Omit<TidalIssue, "selected">;

const BASE_ISSUES: readonly DemoIssue[] = [
  {
    id: "search-keyboard",
    key: "PRO-128",
    title: "Search focus skips the saved filter",
    accessibleTitle: "Search focus skips the saved filter",
    href: "#issue-list-sample-search-keyboard",
    status: { id: "open", label: "Open" },
    priority: { id: "high", label: "High" },
    assignee: {
      name: "Ava Stone",
      accessibleName: "Ava Stone",
      avatar: {
        src: tidalExampleAvatarDataUri("01"),
        alt: "Ava Stone, fictional teammate",
      },
    },
    updatedDateTime: "2026-10-15T09:20:00-05:00",
    updatedLabel: "Today, 9:20 AM",
    labels: ["Search", "Keyboard"],
  },
  {
    id: "export-copy",
    key: "PRO-121",
    title: "Clarify the export confirmation copy",
    accessibleTitle: "Clarify the export confirmation copy",
    href: "#issue-list-sample-export-copy",
    status: { id: "review", label: "In review" },
    priority: { id: "medium", label: "Medium" },
    assignee: {
      name: "Noah Park",
      accessibleName: "Noah Park",
      avatar: {
        src: tidalExampleAvatarDataUri("02"),
        alt: "Noah Park, fictional teammate",
      },
    },
    updatedDateTime: "2026-10-14T16:45:00-05:00",
    updatedLabel: "Yesterday, 4:45 PM",
    labels: ["Content"],
  },
  {
    id: "mobile-density",
    key: "PRO-116",
    title: "Phone cards need a clearer priority signal",
    accessibleTitle: "Phone cards need a clearer priority signal",
    href: "#issue-list-sample-mobile-density",
    status: { id: "open", label: "Open" },
    priority: { id: "low", label: "Low" },
    updatedDateTime: "2026-10-13T11:05:00-05:00",
    updatedLabel: "Oct 13, 11:05 AM",
    labels: ["Mobile"],
  },
];

function primary(event: MouseEvent<HTMLAnchorElement>) {
  return (
    event.button === 0 &&
    !event.metaKey &&
    !event.ctrlKey &&
    !event.shiftKey &&
    !event.altKey
  );
}

function revealWithinDocument(node: HTMLElement) {
  const ownerWindow = node.ownerDocument.defaultView;
  if (!ownerWindow) return;
  const rect = node.getBoundingClientRect();
  const visibleTop = 90;
  const visibleBottom = ownerWindow.innerHeight - 16;
  if (rect.top < visibleTop) {
    ownerWindow.scrollBy({ top: rect.top - visibleTop });
  } else if (rect.bottom > visibleBottom) {
    ownerWindow.scrollBy({ top: rect.bottom - visibleBottom });
  }
}

export function IssueListDemo() {
  const [selected, setSelected] = useState<string[]>(["search-keyboard"]);
  const [status, setStatus] = useState("all");
  const [priority, setPriority] = useState("all");
  const [assignee, setAssignee] = useState("all");
  const [sort, setSort] = useState("updated");
  const [detail, setDetail] = useState<DemoIssue | null>(() =>
    typeof window === "undefined"
      ? null
      : (BASE_ISSUES.find((issue) => issue.href === window.location.hash) ??
        null),
  );
  const [outcome, setOutcome] = useState("1 issue selected.");
  const listRef = useRef<HTMLElement>(null);
  const detailRef = useRef<HTMLElement>(null);
  const openerRef = useRef<HTMLAnchorElement | null>(null);
  const focusDetail = useRef(false);
  const restoreFrame = useRef<number | null>(null);

  useLayoutEffect(() => {
    if (!detail || !focusDetail.current) return;
    focusDetail.current = false;
    const node = detailRef.current;
    if (!node) return;
    node.focus({ preventScroll: true });
    revealWithinDocument(node);
  }, [detail]);

  useEffect(
    () => () => {
      if (restoreFrame.current !== null)
        cancelAnimationFrame(restoreFrame.current);
    },
    [],
  );

  const visible = useMemo(() => {
    const filtered = BASE_ISSUES.filter(
      (issue) =>
        (status === "all" || issue.status.id === status) &&
        (priority === "all" || issue.priority.id === priority) &&
        (assignee === "all" ||
          (assignee === "unassigned"
            ? !issue.assignee
            : issue.assignee?.accessibleName === assignee)),
    );
    return [...filtered].sort((a, b) =>
      sort === "priority"
        ? ["high", "medium", "low"].indexOf(a.priority.id) -
          ["high", "medium", "low"].indexOf(b.priority.id)
        : b.updatedDateTime.localeCompare(a.updatedDateTime),
    );
  }, [assignee, priority, sort, status]);

  const filters: TidalIssueFilter[] = [
    {
      id: "status",
      label: "Status",
      value: status,
      options: [
        { value: "all", label: "All statuses" },
        { value: "open", label: "Open" },
        { value: "review", label: "In review" },
      ],
      onValueChange: setStatus,
    },
    {
      id: "priority",
      label: "Priority",
      value: priority,
      options: [
        { value: "all", label: "All priorities" },
        { value: "high", label: "High" },
        { value: "medium", label: "Medium" },
        { value: "low", label: "Low" },
      ],
      onValueChange: setPriority,
    },
    {
      id: "assignee",
      label: "Assignee",
      value: assignee,
      options: [
        { value: "all", label: "Everyone" },
        { value: "Ava Stone", label: "Ava Stone" },
        { value: "Noah Park", label: "Noah Park" },
        { value: "unassigned", label: "Unassigned" },
      ],
      onValueChange: setAssignee,
    },
  ];

  const issues: TidalIssue[] = visible.map((issue) => ({
    ...issue,
    selected: selected.includes(issue.id),
    linkProps: {
      onClick: (event: import("react").MouseEvent<HTMLAnchorElement>) => {
        if (!primary(event)) return;
        event.preventDefault();
        openerRef.current = event.currentTarget;
        focusDetail.current = true;
        setDetail(issue);
        setOutcome(`Opened ${issue.key} locally.`);
      },
    },
  }));

  const resetFilters = () => {
    setStatus("all");
    setPriority("all");
    setAssignee("all");
    setOutcome("Filters reset.");
  };

  return (
    <div className="issue-list-demo">
      <TidalIssueList
        ref={listRef}
        tabIndex={-1}
        title="Product issues"
        summary={`${visible.length} shown`}
        description="Filter the sample queue, select rows, or open an issue."
        issues={issues}
        filters={filters}
        sort={{
          label: "Sort",
          value: sort,
          options: [
            { value: "updated", label: "Recently updated" },
            { value: "priority", label: "Priority" },
          ],
          onValueChange: setSort,
        }}
        onSelectionChange={(issue, checked) => {
          setSelected((current) =>
            checked
              ? [...new Set([...current, issue.id])]
              : current.filter((id) => id !== issue.id),
          );
          setOutcome(`${checked ? "Selected" : "Cleared"} ${issue.key}.`);
        }}
        bulkActions={[
          {
            id: "review",
            label: "Mark for review",
            onAction: (ids) =>
              setOutcome(
                `${ids.length} issue${ids.length === 1 ? "" : "s"} marked for local review.`,
              ),
          },
          {
            id: "clear",
            label: "Clear selection",
            onAction: () => {
              setSelected([]);
              setOutcome("Selection cleared.");
            },
          },
        ]}
        emptyContent={<p>No sample issues match these filters.</p>}
        emptyAction={{ label: "Reset filters", onAction: resetFilters }}
        footer={
          <span>{outcome} Sample data. Changes stay in this preview.</span>
        }
      />
      {detail ? (
        <section
          className="issue-list-demo-detail"
          id={`issue-list-sample-${detail.id}`}
          ref={detailRef}
          tabIndex={-1}
          aria-label={`Issue ${detail.key} details`}
        >
          <div>
            <span>{detail.key}</span>
            <strong>{detail.status.label}</strong>
          </div>
          <h3>{detail.title}</h3>
          <p>
            This local detail confirms the native issue destination without
            connecting to a tracker.
          </p>
          <button
            type="button"
            onClick={() => {
              setDetail(null);
              setOutcome("Issue detail closed.");
              if (restoreFrame.current !== null)
                cancelAnimationFrame(restoreFrame.current);
              restoreFrame.current = requestAnimationFrame(() => {
                restoreFrame.current = null;
                const target = openerRef.current?.isConnected
                  ? openerRef.current
                  : (listRef.current?.querySelector<HTMLAnchorElement>(
                      ".tidal-issue-link[href]",
                    ) ?? listRef.current);
                target?.focus({ preventScroll: true });
                if (target) revealWithinDocument(target);
              });
            }}
          >
            Close details
          </button>
        </section>
      ) : null}
    </div>
  );
}

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

```

## Gotchas

- Install the declared registry dependencies and render inside a tidal-scope with the foundation stylesheet loaded.

## 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."}

Required title, summary, controlled issues and onSelectionChange. Every issue has a unique nonblank id, key, ReactNode title plus accessibleTitle, native href, status, priority, exact dateTime/timeLabel, selected state and optional assignee, avatar, labels, disabled state, native row/link/selection attributes and refs. Disabled links omit href and suppress primary and auxiliary handlers. A disabled issue cannot become selected; an already-selected disabled issue remains removable and blocks bulk actions until corrected. Controlled native status/priority/assignee filters and sort preserve name/form/required attributes, defensively strip runtime overrides of owned single-select state and labelling, run native change handlers first and show unmatched values as repairable configuration errors. Persistent bulk actions receive a copy of selected IDs; native handlers run first and prevention cancels callbacks. Structural duplicate/blank IDs suppress ambiguous controls and rows. Optional loading/error/empty/action/footer content, heading level, labels, root/list attributes and refs are supported. Native controls are at least 44px, phone layouts become cards, and reduced motion is static. Consumers own filtering, sorting, selection acceptance, navigation, authorization, persistence and every tracker action. The component performs no request or storage operation.
