Tooltip
Floating macOS 27 Liquid Glass tooltip pill with keyboard shortcut badge support, four-side anchoring, touch long-press adaptation, and glass={false} opaque mode.
Built on @base-ui/react/tooltip, presenting macOS 27's minimal floating Liquid Glass capsule (arrowless by default, with optional showArrow) powered by <LiquidSurfaceBackdrop tone="menu" /> synced to global --liquid-glass-tint.
Toolbar Shortcut Tooltip
Hover or focus toolbar buttons on desktop (long-press on touch devices) to reveal the Liquid Glass tooltip with built-in <Kbd> spacing:
Installation (Shadcn Registry)
# Install via the configured @apple-liquid namespace (includes liquid-surface and liquid-glass)
npx shadcn@latest add @apple-liquid/tooltipPlacements
Supports side="top" | "bottom" | "left" | "right" and align, flipping automatically near viewport edges:
Directional Arrow
Arrowless by default to match macOS 27; enable showArrow when pointing to a specific anchor:
Pointer vs. Touch Interaction
Because touch devices have no hover state, TooltipTrigger adapts by pointer type (finger/stylus, regardless of viewport width):
| Input Type | Show | Hide |
|---|---|---|
| Mouse / Trackpad (macOS 27) | Hover or keyboard focus after a short delay | Move pointer away or press Esc |
| Touch / Stylus (iOS 27) | Long-press (~0.45s) | Auto-hides ~1.5s after release, or tap elsewhere |
- Tapping on touch devices invokes the button's primary action immediately without flashing a tooltip, matching iOS toolbar conventions.
- Long-pressing suppresses the trailing click and native callout menu.
- Always provide an
aria-labelon icon-only buttons since tooltips are supplementary.
Props API
TooltipContent
| Prop | Type | Default | Description |
|---|---|---|---|
side | 'top' | 'bottom' | 'left' | 'right' | 'top' | Tooltip placement relative to trigger |
sideOffset | number | 7 | Distance in px from trigger |
glass | boolean | true | Liquid Glass material reacting to glass tint; false renders a 100% opaque surface |
showArrow | boolean | false | Show directional arrow |
ToggleGroup
Combines into an Apple 27 Segmented Control at spacing={0} and a macOS 27 toolbar Liquid Glass segmented bar with glass, supporting single/multiple selection, vertical orientation, and automatic Over-Glass switching.
Trace
AI and task execution step list featuring running shimmer, destructive red error state, translucent pending state, and collapsible step details.