Skip to content
Back

Hover cardPro

Preview a person, agent or source on hover or focus: a short delay, a grace period while you travel into it, and a fast warm re-open.

oxyn add hover-card

Reviewed by

before the agent merged the fix.

The code is part of Oxyn Pro

The preview stays free for everyone. Pro opens the code of every Pro component, screen, agent-app template, block and kit, plus the Pro CLI.

Get Pro

Rendered from Rust at build time · goes live when visible

When to use

  • Preview a teammate, an agent or a cited source without leaving the transcript.

When not to use

  • A small label for one control: use Tooltip instead.
  • Cited sources under an answer: use Source cards instead.
  • An app sidebar: use Sidebar instead.

Installation

Hover card is part of Oxyn Pro; the preview is free. Pro items install with the oxyn CLI once your licence is signed in; until then Pro members copy the code from this page.

Terminal
oxyn add hover-card

Usage

Dioxus · rust
The code is part of Oxyn Pro

The preview is free. Pro opens the code of every Pro component, screen and template.

Get Pro

Examples

Person

A person preview.

Reviewed by

before the agent merged the fix.

Code Pro
The code is part of Oxyn Pro

The preview is free. Pro opens the code of every Pro component, screen and template.

Get Pro

Agent

An agent with its identity ring (Oxyn plus).

Reviewed by

before the agent merged the fix.

Code Pro
The code is part of Oxyn Pro

The preview is free. Pro opens the code of every Pro component, screen and template.

Get Pro

Source

A citation source preview (Oxyn plus).

Reviewed by

before the agent merged the fix.

Code Pro
The code is part of Oxyn Pro

The preview is free. Pro opens the code of every Pro component, screen and template.

Get Pro

API reference

HoverCard

PropTypeDefaultDescription
triggerrequiredString—Trigger text.
profileOption<Profile>Default::default()Person preview.
sourceOption<(String, String, String)>Default::default()Oxyn plus: a source preview (title, domain, snippet).
sideString"bottom"`top` · `bottom` · `left` · `right`.
alignString"start"`start` · `center` · `end`.
open_delayu64500Open delay ms.
close_delayu64140Close grace ms.
openboolDefault::default()Start open (no focus moves; nothing covers the page).

Read from the Rust signature and doc comments.

Keyboard interactions

KeyAction
TabFocus opens the card at once
EnterOpen without the delay
EscapeClose and stay closed while hovering

Accessibility

  • role=tooltip; the trigger gets aria-describedby while open.
  • Focus never moves into the card.
From the spec

Focus never moves into the card (read-only content). aria-describedby only while open.

Motion & interaction

Grows from the trigger edge (0.96 → 1, 4 px) with a separate fade; warm opens fade only. Bio and stats settle in with a small stagger.

Timing
TransitionDurationEasingReduced motion
Open delay500 ms (80 warm)—same
Close grace140 ms—same
Grow220 msease.outfade 120 ms

Responsive behaviour

  • 18.5rem wide, capped to the viewport; taps toggle on touch.
Edge cases (spec)

Touch taps toggle. Long names ellipsize; stats wrap. Card width caps to the viewport minus 24 px.

Notes for AI

  • Import HoverCard, Profile from oxyn_dioxus and include PRIMITIVES_CSS plus the token stylesheet once.
  • A GPUI version exists: HoverCardEl in oxyn_gpui.
  • Props to set first: trigger.
  • Keep its states and timings as they ship; restyle it through the CSS variables rather than by hand.

Guides

Oxyn · 74 free components · 264 Pro components · 96 screens · 20 blocks · Dioxus and GPUI