Card
atomsThe elevated surface: padding, surface and border presets, semantic tones, tappable or keyboard-interactive, stacked piles, header and footer slots.
Service tile with header, body and footer
title, subtitle and actions render a SectionHeader; the footer snippet sits behind a divider; gap stacks the body.
api-gateway
gateway · eu-west-1worker-02
worker · eu-west-1cache-01
cache · us-east-1Padding, surface, border and tone
padding none, sm, md, lg; surface base, raised, sunken; border solid, dashed, none; tone tints the frame for inline banners, attention adds a left bar.
Tappable, interactive, link and empty slot
tap on a native button or anchor adds the press affordance; interactive makes a div keyboard-operable while nested buttons stay independent; a dashed card marks an empty drop slot.
Anchor card
The whole surface is a link.Interactive card
Enter or Space activates; the nested button does not bubble.Stacked piles and clipped media
stacked draws two back layers, stackTone tints them, stackY and stackX set the peek; overflow="hidden" with padding="none" clips an image to the corners; maxWidth caps a row card.
3 queued jobs
Back layers on the border colour.Info pile, wider peek
Offsets are per layer.Dashed pile
Back layers inherit the dash.Micro-interactions
data-fx-card on any ancestor lights tappable cards: "spotlight" (default) follows the pointer, "orbit" runs one comet round the edge on hover, "none" keeps the plain lift.
List rows
row makes flush rows for a rounded, clipped list: square corners and no shadow; hover keeps the wash but drops the edge ring, lift and press scale.
Props
| Prop | Type | Default | Description |
|---|---|---|---|
tap | boolean | false | |
interactive | boolean | false | |
row | boolean | false | Flush list row: square corners, no shadow; hover is a wash with no edge ring, lift or press scale. |
as | 'div' | 'button' | 'a' | 'li' | 'section' | 'form' | 'div' | |
type | 'button' | 'submit' | 'reset' | 'button' | |
padding | 'none' | 'sm' | 'md' | 'lg' | 'md' | |
surface | 'base' | 'raised' | 'sunken' | 'base' | |
border | 'solid' | 'dashed' | 'none' | — | Frame border style; applies to the stacked layers too. Unset, a neutral card has no visible frame (shade only, the edge stays transparent) and a toned card is `solid`. `none` drops the frame box entirely. |
tone | Tone | 'neutral' | |
stacked | boolean | false | |
stackTone | Tone | 'neutral' | |
stackY | number | 8 | |
stackX | number | 2 | |
title | string | — | |
subtitle | string | — | |
gap | string | — | |
overflow | 'visible' | 'hidden' | — | `hidden` clips children to the rounded box. |
maxWidth | string | — | |
onclick | (e: MouseEvent | KeyboardEvent) => void | — | |
class | string | '' | |
style | string | '' | |
header | Snippet | — | |
footer | Snippet | — | |
actions | Snippet | — | |
children | Snippet | — | |
href | string | — | Polymorphic attributes for `as="a"` / `as="button"`. |
target | string | — | |
rel | string | — |