Table
Columnar data that shares the same row shape as Lists.
Default
Headers sit in the neutral-100 well and rows in a white panel with a 1px neutral-200 stroke. Rows are 44px with a neutral-50 hover.
Pinned columns
Set pin="start" or pin="end" on a column's head and cells to keep it in place while the middle scrolls. When the middle overflows, scroll buttons and edge fades appear in the header.
| Call ID |
|---|
| CALL-4506 |
| CALL-4507 |
| CALL-4508 |
| CALL-4509 |
Column dividers
lines="all" divides every column, lines="start" only the first, and lines="end" only the last. Dividers are body-only, so the header stays clean.
Entity cells
Put an Entity in a cell with variant="agent" when a row needs identity and supporting context. The cell wraps instead of truncating.
Interactive cells
Compact controls such as Switch size="sm" fit the standard row height without adding vertical space.
Best practices
When to use
- Use for records compared across named columns: call logs, phone numbers, usage.
- Use List or Entity when rows are mostly descriptive or have varied structure.
Behavior
- Pin only the identifier (pin="start") and the row actions (pin="end"). The middle scrolls, and scroll buttons and edge fades appear when it overflows.
- Set pin on both the TableHead and every TableCell in that column.
- Give columns fixed widths (w-32, w-44) and let one column flex, so pinned panes and headers stay aligned.
- Use lines="all" for dense numeric data, lines="start" or lines="end" to separate an identifier or action column. Dividers are body-only.
- Use variant="agent" on cells that hold a two-line Entity, so they wrap instead of truncating.
- Use Switch size="sm" and xs/sm icon buttons in cells so rows stay 44px.
- Put totals in TableFooter. Provide empty, loading (Skeleton rows) and narrow-width states.
Content
- Header labels are sentence case nouns: "Call ID", "Agent linked". Use tabular-nums for durations, counts and money.
- Colour status text with positive, warning and danger tokens only when the label says the same thing.
Accessibility
- Name row action menus with the row identifier: "More actions for CALL-4506".
- Make sort state visible and announced when a column sorts.