Table
Rows of data, scrolling sideways when wide.
Plain table elements with the system’s spacing and rules. Mark a selected row with
aria-selected.
Dependencies
What it's built from and what's built from it in Base, read from the imports in its source.
| Uses | Scroll AreaprimitiveTextprimitive |
|---|---|
| Used by | Nothing yet. |
| Packages | None. |
Installation
Set the project up for Base once first, as Getting started shows. Then add it with the CLI, or by hand.
With the CLI
Manually
Add the components it uses first, listed under Dependencies.
Then copy the source:
API reference
Generated from Base's types. Props marked ours are added here; the rest come from the ui-sdk part it wraps. Every part also accepts its element's native attributes.
Table
A data table that scrolls sideways when it's wider than its container.
Takes the props of a native div.
TableBody
The body row group.
Takes the props of a native div.
TableCaption
Describes the table, under it.
Takes the props of a native div.
TableCell
A cell.
Takes the props of a native div.
TableFooter
Totals or notes under the body.
Takes the props of a native div.
TableHead
A column heading, or with scope="row", a row's heading, sized like the cells beside it.
Takes the props of a native div.
TableHeader
The header row group.
Takes the props of a native div.
TableRow
A row. Set aria-selected to mark it selected.
Takes the props of a native div.