HoverCard
Hover-triggered popover card. Web only — on native the content is omitted since hover events don't exist.
At a glance
- Opens after
openDelay(default 300 ms) onmouseEnter; closes aftercloseDelay(default 200 ms) onmouseLeave. - Stays open while the mouse is over the content itself.
- Reuses
Popoverfor positioning — inheritsside+alignplacement props. - Compound API:
HoverCard.Trigger+HoverCard.Content. - Web only. On native,
HoverCard.Contentrendersnull— only the trigger renders. UsePopoverdirectly if you need a long-press-triggered panel on native.
Preview
Usage
Delays
Placement
Pass side and align to HoverCard.Content to control positioning:
Native behavior
HoverCard is web-only. On native, HoverCard.Content renders nothing and HoverCard.Trigger renders its children as-is. There is no long-press fallback — use Popover directly if you need hover-card-style content on touch devices.
Props
HoverCard
Controls open state via open (controlled) and onOpenChange (callback). Use
defaultOpen={true} for uncontrolled mode starting visible. openDelay and
closeDelay (both in ms) tune the hover timing.
| Prop | Type | Default | Description |
|---|---|---|---|
closeDelay | number | 200 | Milliseconds before the card closes after hover-out. @defaultValue 200 |
defaultOpen | boolean | false | Uncontrolled initial open state. @defaultValue false |
onOpenChange | (open: boolean) => void | — | Fires with the new open state. |
open | boolean | — | Controlled open state. |
openDelay | number | 300 | Milliseconds before the card opens after hover-in. @defaultValue 300 |
HoverCard.Trigger
Wraps the element that the user hovers to open the card. Accepts children
(any hoverable element — typically an avatar, link, or username chip) and an
optional asChild to render a custom root element instead of the default
span wrapper.
HoverCard.Content
The card surface revealed on hover. Accepts children (any card body content),
plus placement props side ("top" | "right" | "bottom" | "left",
default "bottom") and align ("start" | "center" | "end", default
"center") forwarded to the underlying Popover positioner. On native this
component renders null.