Table
A semantic data table with an optional scroll container.
Staticimport { Table } from 'umbra-ui'
Props
Table
interactive | boolean | false | Highlights rows on hover. |
size | "sm" | "md" | md | Row density. |
TableContainer
aria-label required | string | — | Accessible name for the scrollable region. Required so keyboard users know what they are scrolling. |
TableHead
numeric | boolean | false | Right-aligns numeric columns and uses tabular figures. |
TableRow
selected | boolean | — | Marks the row as selected (sets `aria-selected` and a highlight). |
Usage notes
Semantic <table> parts. Wrap in TableContainer for horizontal scrolling on narrow screens.
Accessibility
TableContainer is a focusable, labelled region so keyboard users can scroll it.
TableHead defaults to scope="col"; use scope="row" for row headers.
TableCaption names the table.
Import
import { Table, TableContainer, TableHead, TableRow } from 'umbra-ui';
import 'umbra-ui/styles.css'; // once, at the root of your app