Tooltip
A hint on hover and focus, never a label and never interactive.
import { Tooltip, TooltipProvider } from "@arcadia/ui"A hint, never a label and never interactive: icon-only controls carry their own aria-label. It opens after 350ms and closes after 100ms; once one has shown, its neighbours open instantly for 200ms, so reading along a toolbar doesn't wait at every button. Mount TooltipProvider once for that grouping. IconButton draws its own tooltip from label and shortcut.
Which overlay? A Tooltip names a control in a few words. A Hover Card previews what a link points to, a Popover holds content you act on, and a Menu lists actions or choices.
Examples
rootStyle takes where the tooltip's popup sits and its widest width.
| Knob | Takes | Default | Sets |
|---|---|---|---|
TokenRef<Measure> | 280px | Widest width (280); longer titles wrap. |
It shows on keyboard focus as well as hover and describes its trigger; the trigger's own name stays its label. It holds no focusable content, so anything a person must read at leisure or click belongs in a Popover.
- Esc
- Hides the tooltip
Tooltip
contentrequired- ReactNode
- The title line.
null/falserenders the trigger alone (no tooltip). shortcut- ShortcutSpec
- Right-aligned shortcut: glyph shortcuts (⌘⇧⌥⌃) render as boxed keys, words as text-3.
subtitle- ReactNode
- A second line, 12/16 text-2.
side- "top" | "bottom" | "left" | "right" | "inline-start" | "inline-end"Default"top"
align- "start" | "center" | "end"Default"center"
sideOffset- numberDefault6
delay- number
- Open delay in ms. Default: the provider's, or 350 without one.
closeDelay- number
disabled- boolean
open- boolean
defaultOpen- boolean
onOpenChange- (open: boolean) => void
rootStyle- RootStyle<TooltipKnobs>
- Typed StyleX override for the popup: layout and
--tooltip-max-w. className- string
- A product's hook class for the popup (being retired: new code sets
rootStyle). childrenrequired- ReactElement
- The trigger: one element that accepts props and a ref (a Button, an IconButton, a row).
delay- numberDefault350
closeDelay- numberDefault100
timeout- numberDefault200