Umbra UI

Table

A semantic data table with an optional scroll container.

Staticimport { Table } from 'umbra-ui'

Props

Table

PropTypeDefaultDescription
interactive booleanfalseHighlights rows on hover.
size "sm" | "md"mdRow density.

TableContainer

PropTypeDefaultDescription
aria-label requiredstring—Accessible name for the scrollable region. Required so keyboard users know what they are scrolling.

TableHead

PropTypeDefaultDescription
numeric booleanfalseRight-aligns numeric columns and uses tabular figures.

TableRow

PropTypeDefaultDescription
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