For sighted users to preview content available behind a link or element on hover. Unlike popovers, hover cards are triggered by mouse hover and are ideal for supplemental information.
Hover over the link below to see a preview:
Installation
CLI
Install the component using the StarUI CLI:
star add hover-cardExamples
User Profile Hover Card
Rich profile card with avatar, bio, stats, and action buttons
Hover over the user avatar to see their profile:
Repository Hover Card
GitHub repository preview with stats and language info
Hover over the repository link:
Product Preview Hover Card
E-commerce product preview with pricing, features, and call-to-action
Hover over the product name to see details:
Positioning Options
Hover cards can be positioned on any side with flexible alignment
Hover over the buttons to see different positioning options:
Link Preview Hover Card
Rich documentation previews with features, links, and detailed content
Rich content hover cards for documentation links:
Learn more about
and its component system.Interactive Form Hover Card
Hover card with interactive form fields and validation
Hover over the contact button to see an interactive form:
API Reference
| Component | Description |
|---|---|
HoverCard |
Container that manages open state for trigger and content on hover |
HoverCardTrigger |
Element that opens/closes the hover card based on mouse enter/leave, with delays |
HoverCardContent |
The floating content positioned relative to its trigger with side and alignment controls |