Layout UI

Table

Presentational data table family with hover rows and caption support.

Preview

Recent invoices
InvoiceDateDescriptionAmountStatus
INV-2025-0011 May 2025Starter plan£9.00Paid
INV-2025-0021 Jun 2025Pro plan£29.00Paid
INV-2025-0031 Jul 2025Pro plan£29.00Due
Total£67.00

Installation

bash
npx shadcn@latest add @layout/table

Usage

tsx
import {
  Table,
  TableHeader,
  TableBody,
  TableFooter,
  TableRow,
  TableHead,
  TableCell,
  TableCaption,
} from "@/components/ui/table"

Examples

Team members table

NameEmailRoleJoined
Alice Chenalice@example.comOwnerJan 2025
Ben Wrightben@example.comAdminFeb 2025
Cara Oseicara@example.comMemberMar 2025

Guidelines for AI agents

Static tabular data. TableHead cells are muted-foreground; numeric columns align right via className. For sorting/filtering/virtualisation compose with TanStack Table.

Never

  • Neveruse tables for page layout
  • Neverput interactive rows without hover and focus states

Tokens consumed

--layout-border--layout-muted--layout-muted-fg