HoverCard
Card popup on hover with delay-based open/close
Start Here
Start from the smallest working snippet, then move to interactive examples and the full API contract below.
Styled quick start
Copy this entrypoint first. It includes the imports required to get the component on screen.
<script lang="ts">
import '@dryui/ui/themes/default.css';
import '@dryui/ui/themes/dark.css';
import { HoverCard } from '@dryui/ui';
</script>
<HoverCard.Root>
<HoverCard.Trigger>...</HoverCard.Trigger>
<HoverCard.Content>...</HoverCard.Content>
</HoverCard.Root>Import options
Root package
import { HoverCard } from '@dryui/ui'Per-component subpath
import { HoverCard } from '@dryui/ui/hover-card'Customize
Use the interactive examples to see common variants, states, and composition patterns before building your own.
Default
Svelte
Cybernetically enhanced web apps. A compiler that turns your declarative components into efficient JavaScript.
<HoverCard.Root>
<HoverCard.Trigger href="https://svelte.dev">
@svelte
</HoverCard.Trigger>
<HoverCard.Content>
<p><strong>Svelte</strong></p>
<p>Cybernetically enhanced web apps. A compiler that turns your declarative components into efficient JavaScript.</p>
</HoverCard.Content>
</HoverCard.Root>Structure
Compound components always start with HoverCard.Root. Use this structure block to understand required wrappers before you wire state or styling.
HoverCard.Root HoverCard.Trigger HoverCard.Content
Compose
The full API contract lives here: props, CSS variables, and the public data attributes you can target when styling.
Compound component. Start with HoverCard.Root, then add only the parts you need.
HoverCard.Root
| Prop | Type | Default | Required | Bindable |
|---|---|---|---|---|
openDelay | number | — | — | — |
closeDelay | number | — | — | — |
children | Snippet | — | ✓ | — |
Also accepts standard HTML attributes (class, style, id, etc.)
HoverCard.Trigger
| Prop | Type | Default | Required | Bindable |
|---|---|---|---|---|
href | string | — | — | — |
children | Snippet | — | ✓ | — |
Forwards native HTML attributes via rest props.
HoverCard.Content
| Prop | Type | Default | Required | Bindable |
|---|---|---|---|---|
offset | number | — | — | — |
children | Snippet | — | ✓ | — |
Forwards <div> attributes via rest props. Common examples: id, style, role.