# Rax: calm React components for data-heavy apps
Rax is a small React 19 system with flat surfaces, strong contrast and one accent you choose, in light and dark.
## Install
```sh
pnpm add @a31labs/rax react react-dom lucide-react
```
```css
@import "@a31labs/rax/styles.css";
```
Each component has its own entry, such as `@a31labs/rax/button`. The full rules are at https://rax.a31.at/foundations/rules.md.
---
# All components
Every component with a live preview, by group.
## Actions
- [Button](https://rax.a31.at/components/button.md): Starts an action. One primary per view region.
- [Icon button](https://rax.a31.at/components/icon-button.md): A button with only an icon, for universally known actions. The label is required.
- [Theme toggle](https://rax.a31.at/components/theme-toggle.md): Switches the page between light, dark and system.
## Forms
- [Field](https://rax.a31.at/components/field.md): Label on top, control, hint below. Validates on blur, then live.
- [Input](https://rax.a31.at/components/input.md): Single-line text entry.
- [Textarea](https://rax.a31.at/components/textarea.md): Multi-line text entry.
- [Select](https://rax.a31.at/components/select.md): One value from a short list. Same shape as Input.
- [Checkbox](https://rax.a31.at/components/checkbox.md): Choices in a form that submits.
- [Radio](https://rax.a31.at/components/radio.md): One choice out of a few, all visible at once.
- [Switch](https://rax.a31.at/components/switch.md): An on/off setting that applies immediately.
- [Copy field](https://rax.a31.at/components/copy-field.md): A read-only value with a copy button that confirms inline.
- [Search input](https://rax.a31.at/components/search-input.md): Text entry for filtering a list. Escape clears.
- [Date picker](https://rax.a31.at/components/date-picker.md): One calendar day as a plain YYYY-MM-DD string.
- [Date range picker](https://rax.a31.at/components/date-range-picker.md): A period of days, with presets beside two months.
- [Time input](https://rax.a31.at/components/time-input.md): A time of day as HH:mm.
- [Date time picker](https://rax.a31.at/components/date-time-picker.md): An instant, picked as wall-clock time in a chosen zone.
- [Combobox](https://rax.a31.at/components/combobox.md): Type to find one or several values in a longer list.
- [Tag input](https://rax.a31.at/components/tag-input.md): Free-form values entered as removable tags.
- [Color input](https://rax.a31.at/components/color-input.md): A hex colour with a swatch.
- [File drop](https://rax.a31.at/components/file-drop.md): Drop or choose files, with type and size limits.
- [Tile group](https://rax.a31.at/components/tile-group.md): One choice from a few options that need a description.
- [Chip group](https://rax.a31.at/components/chip-group.md): Pick several topics or filters, optionally ranked.
- [Number input](https://rax.a31.at/components/number-input.md): Numeric entry with min, max, step, locale formatting and optional step buttons.
- [Password input](https://rax.a31.at/components/password-input.md): Password field with a show/hide toggle.
- [Slider](https://rax.a31.at/components/slider.md): Pick a value or a range by dragging or with the arrow keys.
- [OTP input](https://rax.a31.at/components/otp-input.md): One-time code entry with one cell per character, auto-advance and paste.
## Display
- [Badge](https://rax.a31.at/components/badge.md): Status and counts. Status always pairs a glyph with a word.
- [Alert](https://rax.a31.at/components/alert.md): An inline message with a status.
- [Avatar](https://rax.a31.at/components/avatar.md): Initials for a person.
- [Kbd](https://rax.a31.at/components/kbd.md): A key or shortcut.
- [Skeleton](https://rax.a31.at/components/skeleton.md): A placeholder while content loads.
- [Spinner](https://rax.a31.at/components/spinner.md): Work in progress. Appears only after 100 ms.
- [Stat](https://rax.a31.at/components/stat.md): Key figures in a divided grid.
- [Key-value list](https://rax.a31.at/components/key-value-list.md): Labelled values, such as the details of a record.
- [Empty state](https://rax.a31.at/components/empty-state.md): What to do when there is nothing to show yet.
- [Timeline](https://rax.a31.at/components/timeline.md): Activity over time, newest first.
- [Progress](https://rax.a31.at/components/progress.md): How far a task has come, or that it is running.
- [Sparkline](https://rax.a31.at/components/sparkline.md): A tiny trend line beside a figure.
- [Bar list](https://rax.a31.at/components/bar-list.md): Ranked values with proportional bars.
- [Code block](https://rax.a31.at/components/code-block.md): A snippet with a copy button.
- [Relative time](https://rax.a31.at/components/relative-time.md): A time such as 5 minutes ago, with the exact date on hover.
- [Indicator](https://rax.a31.at/components/indicator.md): A dot or count bubble on a corner of an avatar, icon button or any other element.
- [Highlight](https://rax.a31.at/components/highlight.md): Marks every match of a search query inside text.
- [Aura](https://rax.a31.at/components/aura.md): A calm light travelling along the border of any component, to draw the eye to one recommended item.
## Navigation
- [Tabs](https://rax.a31.at/components/tabs.md): Switches between views of the same content.
- [Segmented control](https://rax.a31.at/components/segmented-control.md): Switches a mode or filter. One item is always pressed.
- [Breadcrumbs](https://rax.a31.at/components/breadcrumbs.md): Where the page sits in the hierarchy.
- [Steps](https://rax.a31.at/components/steps.md): Progress through a fixed sequence.
## Layout
- [App shell](https://rax.a31.at/components/app-shell.md): Top bar with brand, navigation and actions.
- [Sidebar shell](https://rax.a31.at/components/sidebar-shell.md): A wide sidebar with icon navigation, sections and the user at the bottom.
- [Rail shell](https://rax.a31.at/components/rail-shell.md): A top bar with context pickers, an icon rail and an optional page column.
- [Page header](https://rax.a31.at/components/page-header.md): Title, breadcrumbs and the page's actions.
- [Panel](https://rax.a31.at/components/panel.md): Groups content on a surface. Never a panel inside a panel.
- [Separator](https://rax.a31.at/components/separator.md): A 1px divider.
- [Accordion](https://rax.a31.at/components/accordion.md): Show and hide sections of content.
- [Card](https://rax.a31.at/components/card.md): A linked or static summary of one item, in a grid.
## Overlays
- [Dialog](https://rax.a31.at/components/dialog.md): For blocking decisions only. Focus is trapped and Escape closes.
- [Confirm dialog](https://rax.a31.at/components/confirm-dialog.md): Confirms an irreversible action. Focus starts on Cancel.
- [Popover](https://rax.a31.at/components/popover.md): Extra detail anchored to a trigger.
- [Menu](https://rax.a31.at/components/menu.md): A short list of actions behind a trigger.
- [Tooltip](https://rax.a31.at/components/tooltip.md): A hint on hover and focus. Never the only place for information.
- [Toast](https://rax.a31.at/components/toast.md): Feedback after an action. Stays until dismissed.
- [Drawer](https://rax.a31.at/components/drawer.md): A sheet from the left or right edge. Focus is trapped.
## Data
- [Data table](https://rax.a31.at/components/data-table.md): Sorting, filtering, selection and paging, on the client or the server.
- [Filter bar](https://rax.a31.at/components/filter-bar.md): One row of filters above a table.
- [Pagination](https://rax.a31.at/components/pagination.md): Moves through pages of results.
- [Selection bar](https://rax.a31.at/components/selection-bar.md): Bulk actions for the current selection.
- [Sortable list](https://rax.a31.at/components/sortable-list.md): Reorder rows by drag or keyboard.
## Charts
- [Area chart](https://rax.a31.at/components/area-chart.md): One or more measures over time, on one axis.
- [Bar chart](https://rax.a31.at/components/bar-chart.md): Compares values across categories: grouped, stacked or horizontal.
- [Line chart](https://rax.a31.at/components/line-chart.md): Several series over time where fills would overlap.
- [Pie and donut chart](https://rax.a31.at/components/pie-chart.md): Parts of a whole, up to five slices.
- [Radial chart](https://rax.a31.at/components/radial-chart.md): One value against a target.
- [Chart tooltip](https://rax.a31.at/components/chart-tooltip.md): Tooltip and legend content shared by every chart.
Page: https://rax.a31.at/components/all
---
# Button
Starts an action. One primary per view region.
Import from `@a31labs/rax/button`.
## Usage
```tsx
```
## Rules
Props: `variant` (`primary` | `secondary` default | `outline` | `ghost` | `danger`), `tone` (`accent` default | `ok` | `warn` | `danger`; colours primary and outline buttons), `size` (`default` | `sm`), `loading`, plus native button props (`type` defaults to `button`). Primary is accent fill; secondary is surface with an `edge` outline; ghost has no fill and ink-2 text; danger is danger-soft with a danger outline, solid on hover. Outline is transparent with a 1px edge in the tone and its label in the tone's text colour (`--rax-accent-text`, or the status ink), the soft fill on hover. `tone` adds colour to a decision row: Approve is `primary` + `ok` (ok-ink fill), Request changes `outline` + `warn` (or `primary` + `warn`: warn fill with `--rax-warn-on` text), Decline `outline` + `danger`. Labels always name the action; colour never carries it alone. Weight 600, active state moves 1px down, disabled at 50% opacity. `loading` shows a spinner after 100ms, keeps the width, ignores clicks and sets `aria-busy`. A button with `aria-disabled="true"` looks disabled and also ignores clicks (and form submit) while staying focusable. One primary per view region.
`ButtonLink` (same import) is navigation that looks like a button: a real `` with `href`, `variant`, `tone` and `size`. Never put a link inside a Button or call navigate from a Button's onClick.
Page: https://rax.a31.at/components/button
---
# Icon button
A button with only an icon, for universally known actions. The label is required.
Import from `@a31labs/rax/icon-button`.
## Usage
```tsx
} variant="ghost" />
```
## Rules
Props: `label` (required: the aria-label and the native `title` tooltip), `icon`, plus Button props except `children`. Icons without words only for universally known actions (close, more, copy, delete with confirm); everything else gets icon plus text.
Page: https://rax.a31.at/components/icon-button
---
# Field
Label on top, control, hint below. Validates on blur, then live.
Import from `@a31labs/rax/field`.
## Usage
```tsx
const { error, onBlur } = useBlurValidation(url, validate);
setUrl(e.target.value)} onBlur={onBlur} />
```
## Rules
Props: `label`, `hint`, `error`, `className`, `ref` (root element), one control as the child (Input, Textarea, Select, ...). Label on top (500), hint below in ink-2 at 14px. With `error` the control gets a danger outline and the hint is replaced by the error text in danger-ink, weight 500, with the danger glyph in front. In a grid the field keeps label and control at the top when its row is taller (a neighbour with a hint), so controls in one row line up. The hook `useBlurValidation(value, validate)` returns `{ error, onBlur }`: no error until the first blur, then live while the user fixes it.
Page: https://rax.a31.at/components/field
---
# Input
Single-line text entry.
Import from `@a31labs/rax/input`.
## Usage
```tsx
setName(e.target.value)} />
```
## Rules
Native input props plus `mono`. Surface fill, `edge` outline, hover outline `ink-3`, focus ring. Placeholder only shows a format example and never replaces the label. Read-only: surface-2 fill. Disabled: 55% opacity.
Page: https://rax.a31.at/components/input
---
# Textarea
Multi-line text entry.
Import from `@a31labs/rax/textarea`.
## Usage
```tsx
```
## Rules
Native textarea props, styled like Input.
Page: https://rax.a31.at/components/textarea
---
# Select
One value from a short list. Same shape as Input.
Import from `@a31labs/rax/select`.
## Usage
```tsx
```
## Rules
Props: `value`, `onValueChange`, `items` (`{ value, label }`), `placeholder`, `disabled`, `readOnly`, `name`, `required`, `form`, `container`. `ref`, `id`, `onBlur`, `aria-*` and other native button props go to the trigger, so it works inside Field and with `useBlurValidation`; with `name` the value posts in a native form through a hidden input. Same shape as Input; the popup is a floating layer and opens above dialogs.
`MultiSelect` (same subpath) takes the same props with `value: T[]` and `onValueChange(v: T[])`: the popup stays open while items toggle, every chosen item shows a check, and the trigger lists the chosen labels comma-separated, cut with an ellipsis (the placeholder when none). For filters over a short fixed list ("Open and Acknowledged"); use Combobox `multiple` once people need to search.
Page: https://rax.a31.at/components/select
---
# Checkbox
Choices in a form that submits.
Import from `@a31labs/rax/checkbox`.
## Usage
```tsx
```
## Rules
Props: `label` plus the Base UI root props; Radio comes with `RadioGroup`. 18px, `edge` outline, accent fill when checked, the label is part of the hit area.
Page: https://rax.a31.at/components/checkbox
---
# Radio
One choice out of a few, all visible at once.
Import from `@a31labs/rax/radio`.
## Usage
```tsx
```
## Rules
Props: `label` plus the Base UI root props; Radio comes with `RadioGroup`. 18px, `edge` outline, accent fill when checked, the label is part of the hit area.
Page: https://rax.a31.at/components/radio
---
# Switch
An on/off setting that applies immediately.
Import from `@a31labs/rax/switch`.
## Usage
```tsx
```
## Rules
Props: `label` plus Base UI switch props. For immediate on/off settings only; forms that submit use Checkbox.
Page: https://rax.a31.at/components/switch
---
# Copy field
A read-only value with a copy button that confirms inline.
Import from `@a31labs/rax/copy-field`.
## Usage
```tsx
```
## Rules
Props: `value`, `label`, plus native div props. Read-only mono input with a Copy button that confirms inline. When the clipboard is blocked it selects the text and shows "Press Ctrl+C or ⌘C to copy".
Page: https://rax.a31.at/components/copy-field
---
# Badge
Status and counts. Status always pairs a glyph with a word.
Import from `@a31labs/rax/badge`.
## Usage
```tsx
Healthy
4 new
```
## Rules
Prop `tone`: `neutral` | `accent` | `accent-2` | `ok` | `warn` | `danger` | `info` | `idle`. 22px high, 14px, weight 600, radius 4px. Neutral has a `line-strong` outline. Status tones always show their glyph (filled circle with a check, triangle with an exclamation mark, octagon with a bar, filled circle with an i, empty ring) before the word. Severity scales map onto the status tones, never onto neutral or accent: for log levels fatal and error are `danger`, warning `warn`, info `info`, debug and trace `idle`. `accent` is for counts and "new"; `accent-2` marks a second category.
Page: https://rax.a31.at/components/badge
---
# Alert
An inline message with a status.
Import from `@a31labs/rax/alert`.
## Usage
```tsx
Health check timed out.
```
## Rules
Props: `tone` (`info` default | `ok` | `warn` | `danger`), `title`, children, plus native div props. Status soft fill, glyph in the status ink, text in ink. The role is `alert` for danger and `status` otherwise; pass `role` to override it.
Page: https://rax.a31.at/components/alert
---
# Avatar
Initials for a person.
Import from `@a31labs/rax/avatar`.
## Usage
```tsx
```
## Rules
Prop `name` (initials, fully round).
Page: https://rax.a31.at/components/avatar
---
# Kbd
A key or shortcut.
Import from `@a31labs/rax/kbd`.
## Usage
```tsx
⌘K
```
## Rules
A `kbd` element in the mono font.
Page: https://rax.a31.at/components/kbd
---
# Skeleton
A placeholder while content loads.
Import from `@a31labs/rax/skeleton`.
## Usage
```tsx
```
## Rules
Prop `width`. Placeholder bar; static under reduced motion.
Page: https://rax.a31.at/components/skeleton
---
# Spinner
Work in progress. Appears only after 100 ms.
Import from `@a31labs/rax/spinner`.
## Usage
```tsx
{/* hidden for the first 100 ms */}
```
## Rules
Prop `delay` (ms, default 100). Hidden until the delay passes; static under reduced motion.
Page: https://rax.a31.at/components/spinner
---
# Stat
Key figures in a divided grid.
Import from `@a31labs/rax/stat`.
## Usage
```tsx
```
## Rules
`Stat` takes `label`, `value`, `hint` (a short note beside the value in ink-2) and `icon` with `iconTone` (`accent` default | `accent-2` | `ok` | `warn` | `danger` | `info` | `neutral`): a 36px tile in the tone's soft fill, top right, and the label turns into a 600 title. `StatGrid` lays cells in a panel divided by `line`; with `separate` each stat is its own card with a 16px gap. Label 14px ink-2, value 24px 700 tabular.
Page: https://rax.a31.at/components/stat
---
# Key-value list
Labelled values, such as the details of a record.
Import from `@a31labs/rax/key-value-list`.
## Usage
```tsx
```
## Rules
Prop `items` (`{ key, value, mono }`). Keys in ink-2, values in ink; `mono` for code values.
Page: https://rax.a31.at/components/key-value-list
---
# Empty state
What to do when there is nothing to show yet.
Import from `@a31labs/rax/empty-state`.
## Usage
```tsx
New service} />
```
## Rules
Props: `title`, `description`, `action`. Title 700, one sentence in ink-2, optional primary action.
Page: https://rax.a31.at/components/empty-state
---
# Tabs
Switches between views of the same content.
Import from `@a31labs/rax/tabs`.
## Usage
```tsx
…
…
```
## Rules
Props: `value`, `onValueChange`, `items` (`{ value, label, attrs }`), children (`TabPanel value=...`). For switching views of content. Underline style: items `h-ctl` high, hover surface-2, selected item ink text, weight 600 and a 3px bar in `--rax-focus` on the 1px `line` baseline.
Page: https://rax.a31.at/components/tabs
---
# Segmented control
Switches a mode or filter. One item is always pressed.
Import from `@a31labs/rax/segmented-control`.
## Usage
```tsx
, ariaLabel: "List view" }]} />
```
## Rules
Props: `value`, `onValueChange`, `items` (`{ value, label, ariaLabel, attrs }`), `label`. For switching a mode or filter (preview width, table state, list or grid). Joined buttons in one `line-strong` outline, selected item surface-3. Never used for navigation.
Page: https://rax.a31.at/components/segmented-control
---
# Breadcrumbs
Where the page sits in the hierarchy.
Import from `@a31labs/rax/breadcrumbs`.
## Usage
```tsx
```
## Rules
Prop `items` (`{ label, href, attrs }`; the last has no `href`). Separators are a slash.
Page: https://rax.a31.at/components/breadcrumbs
---
# App shell
Top bar with brand, navigation and actions.
Import from `@a31labs/rax/app-shell`.
## Usage
```tsx
}
renderLink={(p) => }
>
{children}
```
## Rules
Props: `brand`, `nav` (`{ label, href, current, attrs }`), `actions`, children, `renderLink` (plug in a router link). 56px bar on surface with a bottom `line`; nav items look like Tabs, with a 3px bar on the current page.
Page: https://rax.a31.at/components/app-shell
---
# Sidebar shell
A wide sidebar with icon navigation, sections and the user at the bottom.
Import from `@a31labs/rax/sidebar-shell`.
## Usage
```tsx
} items={[{ label: "Operations", description: "Routes, vehicles and drivers", icon: , current: true, onSelect }]} />}
brandMark={}
subtitle="Operations"
collapsible
nav={[
{ items: [
{ label: "Overview", href: "/", icon: , current: true },
{ label: "Routes", href: "/routes", icon: , children: [{ label: "Planned", href: "/routes/planned" }] },
] },
{ label: "Reports", items: [{ label: "Notifications", href: "/notifications", icon: , badge: "5" }] },
]}
footer={}
collapsedFooter={}
renderLink={(p) => }
>
{children}
```
## Rules
Props: `brand`, `subtitle` (the current area under the brand), `switcher` (beside the brand, e.g. a Menu that switches areas), `nav` (groups of `{ label, href, icon, current, badge, attrs, children }`, a group may have a `label`), `footer` (pinned to the bottom: the signed-in user, sign out), `actions` (right side of the mobile bar), children, `renderLink`, `collapsible` with `collapsed`, `defaultCollapsed`, `onCollapsedChange`, `brandMark` and `collapsedFooter`, `topbar` (a 56px bar across the page above the sidebar for context pickers, a page path and actions; `brand` is then optional) and `navStart` (above the groups, e.g. a link back to the parent level). A group with `collapsible` turns its label into a toggle (`aria-expanded`) with a chevron. A 260px sidebar on surface with a `line` edge, sticky at full height; the main area gets 32px 40px padding. Items are `h-ctl` high with a 20px icon, 12px gap, ink-2 text; hover surface-2. The current page has a surface-2 fill, weight 600, a 3px accent bar on the left edge and its icon in the accent. Items with `children` get a chevron toggle (`aria-expanded`) and open by themselves when one of their pages is current; sub-pages are indented and smaller. With `collapsible`, a "Collapse sidebar" row above the footer narrows the sidebar to 72px of icons: labels and badges stay in the accessible name and show as a title on hover, group labels become a divider, sub-pages hide, and `brandMark` and `collapsedFooter` replace the brand and footer. Below 1024px the sidebar becomes a 56px top bar with a menu button that opens the same navigation in a left Drawer; following a link closes it. Set `--rax-shell-top` when something sticky sits above the shell.
Page: https://rax.a31.at/components/sidebar-shell
---
# Rail shell
A top bar with context pickers, an icon rail and an optional page column.
Import from `@a31labs/rax/rail-shell`.
## Usage
```tsx
}
context={<> / >}
actions={}
rail={[
{ label: "Home", href: "/", icon: },
{ label: "Bookings", href: "/bookings", icon: , current: true },
]}
railEnd={[{ label: "Settings", href: "/settings", icon: }]}
subnav={{ title: "Bookings", items: [{ label: "Today", href: "/bookings", current: true }, { label: "Waitlist", href: "/bookings/waitlist" }] }}
renderLink={(p) => }
>
{children}
```
## Rules
Props: `brand`, `context` (beside the brand, e.g. company and site pickers), `actions` (right side of the bar), `rail` (`{ label, href, icon, current, attrs }`), `railEnd` (pinned to the bottom of the rail), `subnav` (`{ title, items: { label, href, current } }`, a second column with the section's pages), children, `renderLink`. A 56px top bar across the page; below it an 88px rail of icons (20px) with their label under them at 14px, the current section on accent-soft with its icon in the accent. The subnav column is 220px with plain links, the current one on surface-2. Below 1024px the subnav becomes a scrolling row above the content; below 640px the rail becomes a tab bar fixed to the bottom. Set `--rax-shell-top` when something sticky sits above the shell.
Page: https://rax.a31.at/components/rail-shell
---
# Page header
Title, breadcrumbs and the page's actions.
Import from `@a31labs/rax/page-header`.
## Usage
```tsx
} title="worker" breadcrumbs={[{ label: "Services", href: "/services" }, { label: "worker" }]} actions={} />
```
## Rules
Props: `title`, `icon` (optional; a lucide icon 24px in the accent colour, 12px before the title), `breadcrumbs`, `actions`. Title 24px weight 700, actions aligned to the title baseline on the right.
Page: https://rax.a31.at/components/page-header
---
# Panel
Groups content on a surface. Never a panel inside a panel.
Import from `@a31labs/rax/panel`.
## Usage
```tsx
Edit} footer={}>…
```
## Rules
Props: `title`, `description`, `actions`, `footer`, `flush`, `icon` (a lucide icon before the title) and `iconTone` (`accent` default | `accent-2` | `ok` | `warn` | `danger` | `info` | `neutral`). The icon is optional, plain, 20px, in `--rax-accent-icon` or the status tone mixed with a little ink, on the title line 10px before the title; the description lines up under the title text. Surface fill, 1px `line` border, radius 10px, no shadow. Head and footer on surface-2; footer actions right-aligned, a destructive action left. Never a panel inside a panel.
Page: https://rax.a31.at/components/panel
---
# Separator
A 1px divider.
Import from `@a31labs/rax/separator`.
## Usage
```tsx
```
## Rules
A 1px `line` divider, horizontal or vertical.
Page: https://rax.a31.at/components/separator
---
# Dialog
For blocking decisions only. Focus is trapped and Escape closes.
Import from `@a31labs/rax/dialog`.
## Usage
```tsx
```
## Rules
Props: `open`, `onOpenChange`, `title`, `description`, children, `footer`, `modal` (default true), `container`; `className` and `ref` go to the dialog box. Only for irreversible or blocking decisions. Floating shadow, scrim, focus trapped, Escape closes. The dialog never grows taller than the viewport minus 32px; the body scrolls instead.
Page: https://rax.a31.at/components/dialog
---
# Confirm dialog
Confirms an irreversible action. Focus starts on Cancel.
Import from `@a31labs/rax/confirm-dialog`.
## Usage
```tsx
```
## Rules
Props: `open`, `onOpenChange`, `title`, `description`, `confirmLabel`, `onConfirm` (may be async), `container`. Initial focus is on Cancel, the least destructive action. While `onConfirm` runs the danger button shows loading; a rejection keeps the dialog open and shows the error. Name the object, explain the consequence, label the danger button with the verb ("Delete service").
Page: https://rax.a31.at/components/confirm-dialog
---
# Popover
Extra detail anchored to a trigger.
Import from `@a31labs/rax/popover`.
## Usage
```tsx
Details}>Last deployed 4 minutes ago.
```
## Rules
Popover: `trigger`, children, `side`, controlled or default open. Menu: `trigger`, `items` (`{ label, onSelect, href, danger, icon, description, current }`; an item with `href` is a real link, so switchers between pages open in a new tab on middle click; `renderLink` plugs in the router's link); with an icon or description an item becomes a richer row (a 32px icon tile, the label in 600 and the description in ink-2 under it), for app or area switchers, and `current` adds a check. Tooltip: `content`, one child. All three take `container`, and `className` and `ref` for the floating popup. Tooltips never hold information that is not available elsewhere.
Page: https://rax.a31.at/components/popover
---
# Menu
A short list of actions behind a trigger.
Import from `@a31labs/rax/menu`.
## Usage
```tsx