Card
StableA 16px surface that holds one piece of the shop together: a summary, a list of things to act on, a way into a section. Reach for it only when the grouping cannot be read from space and a hairline alone.
Variants
Three materials, and each has its place. A card carries a hairline or a shadow, never both, and every variant keeps a 1px border (transparent unless outlined), so switching variant never moves the content.
On the canvas: outline and sunken
outline is the default: the canvas colour with a hairline. sunken is set into the page, for secondary panels, tips and summaries.
Orders to fulfil
Paid and waiting to ship.
Delivery tip
Shoppers in Northern Ireland see no delivery options yet. Add a rule for BT postcodes.
On the ground: raised
raised trades the hairline for a soft shadow. It is for cards that sit on the porcelain ground beside the canvas, never on the canvas itself.
Next payout
Friday 2 October, to your account ending 4417.
Header, body and footer
CardHeader takes an optional icon in a 32px tile, a title, a one-line description and actions on the right. CardBody holds the content. CardFooter right-aligns its actions under a hairline that runs edge to edge. All three follow the card's padding.
Low stock
Three products sell out this week.
- Header actions are
smcontrols: they centre on the title line without stretching the header. - Inside a card, rows are divided by a Separator, not by more cards.
- The footer holds the card's own actions. Keep the page's one primary button out of it.
Padding
md (20px) is the default. The gap between header, body and footer follows the padding, so a denser card is dense all the way through. none is for tables and media, whose rows bring their own spacing.
Small
16px, with 12px between parts. Side panels and dense grids.
Medium
20px, with 16px between parts. The default.
Large
24px, with 20px between parts. A card that is a page's main content.
Interactive
When the whole card is one way in, set interactive and render the link itself with asChild. Hover firms the hairline (a sunken card darkens, a raised card lifts to the floating shadow), a press dips it to 99.5%, and keyboard focus draws the teal ring. Point at them, or tab to them.
In both themes
All three variants, light and dark side by side. In dark the canvas is near black, so outline and sunken cards read by their hairline and their tone, and the raised card sits on the ground.
Low stock
Three products sell out this week.
Delivery tip
Shoppers in Northern Ireland see no delivery options yet. Add a rule for BT postcodes.
Next payout
Friday 2 October, to your account ending 4417.
Low stock
Three products sell out this week.
Delivery tip
Shoppers in Northern Ireland see no delivery options yet. Add a rule for BT postcodes.
Next payout
Friday 2 October, to your account ending 4417.
Guidelines
The kit groups with space, weight and hairlines before boxes. The page canvas is the one raised surface and the main container, and the home dashboard uses no cards at all. A card earns its border only when the grouping cannot be read without one.
Recent orders
Recent orders
Next payout
Friday 2 October
Next payout
Friday 2 October
- Headline figures sit on a hairline strip, not in a row of cards. See Figure tabs.
- A card holds one idea: a summary, a list to act on, or a way into a section. Two ideas are two cards, or none.
- Name the card by what it is ("Low stock"), and let the description say why it matters now.
Accessibility
- The header title is an
h3by default. SettitleAsso headings follow the page outline, or topwhen the title is not a heading, such as inside a link card. - The icon tile is decorative and hidden from assistive tech.
interactiveadds hover, press and focus styles only. Pair it withasChildon a link (or a button) so the card can be reached by keyboard and is announced for what it does.- Prefer a link. A button flattens everything inside it, so a heading inside is no longer a heading.
- Keyboard focus draws a 2px teal ring 2px outside the card. The press dip is dropped under reduced motion.
Props
Card
| Prop | Type | Default | Description |
|---|---|---|---|
variant | 'outline' | 'raised' | 'sunken' | 'outline' | A hairline on the canvas colour; a soft shadow, for the ground; or set into the page. |
padding | 'none' | 'sm' | 'md' | 'lg' | 'md' | Inner spacing: 0, 16, 20 or 24px. The gap between parts follows: 0, 12, 16 or 20px. |
interactive | boolean | false | Hover, press and focus states for a card that is one target. Pair with asChild. |
asChild | boolean | false | Render the child element (a link or button) as the card. |
Card also accepts every native div attribute.
CardHeader
| Prop | Type | Default | Description |
|---|---|---|---|
titleRequired | ReactNode | None | The card's name, in 15px semibold. |
description | ReactNode | None | One line under the title, in 13px secondary text. |
actions | ReactNode | None | Controls on the right. Small controls centre on the title line. |
icon | ReactNode | None | An icon in a 32px tile before the title. Decorative. |
titleAs | 'h2' | 'h3' | 'h4' | 'p' | 'div' | 'h3' | Element for the title. |
children | ReactNode | None | Extra content under the description, inside the heading block. |
CardBody and CardFooter
| Prop | Type | Default | Description |
|---|---|---|---|
children | ReactNode | None | The content. Both accept every native div attribute; the footer right-aligns and wraps its actions. |