Hover Card
The Hover Card component is a user-friendly, interactive tool designed to display information when a user hovers over a specific trigger element. It offers a variety of features, such as controlled state, customizable positioning, and the use of render props for a more dynamic and flexible experience.
API reference docs for the component. Learn about the props, CSS, and other APIs of this
exported module.
HoverCardProps
The duration from when the mouse leaves the trigger or content until the hover card closes.
The document's text/writing direction.
getRootNode
() => ShadowRoot | Node | Document
A root node to correctly resolve document in custom environments. E.x.: Iframes, Electron.
The unique identifier of the machine.
ids
Partial<{
trigger: string
content: string
positioner: string
arrow: string
}>
The ids of the elements in the popover. Useful for composition.
onOpenChange
(details: OpenChangeDetails) => void
Function called when the hover card opens or closes.
Whether the hover card is open
The duration from when the mouse enters the trigger until the hover card opens.
positioning
PositioningOptions
The user provided options used to position the popover content
HoverCardContext
Function to close the hover card
Whether the hover card is open
Function to open the hover card
setPositioning
(options?: Partial<PositioningOptions> | undefined) => void
Function to reposition the popover
HoverCardContentProps
Whether to enable lazy mounting. Defaults to `false`.
Whether to unmount on exit. Defaults to `false`.