Skip to content
1 viewer
View
Component · Layout

Card

cre8.primitive.card

Section-like surface with optional title, badge, and body slots.

Edit live
Category
Layout
Slots
5
States
4
Writer
Shared

Preview

Live renderShared SSR + WASM writers

Standard Surface Card

Structural surface card with borders and background styling.
<Card title="Standard Surface Card">
  <Text
    text="Structural surface card with borders and background styling."
  />
</Card>
Change this declaration and watch it render:open Card in the playground

Variants

States and intents

Standard Surface

Surface container with default background and subtle border.
TELEMETRYHighlighted Asset
Accent-backed card for system status notifications.

Props

The inputs the shared writer reads. `data-*` and `aria-*` attributes pass through and are not listed.

PropTypeRequiredDefaultAlso written
badgescalarOptional——
classtextOptional——
hreftextOptional——
idtextOptional——
statustextOptional——
titletextOptional——
titleClassNametextOptional——
7 rows

Anatomy

The named parts of the rendered markup. Recipes style these hooks, and every renderer keeps them stable.

SlotDOM class
root.primitive-card
header.primitive-card__header
title.primitive-card__title
badge.primitive-card__badge
body.primitive-card__body
5 rows
Modifier
primitive-card--{status}
State attribute
data-statusfrom the status prop

States and platforms

The states the contract publishes, the platforms it declares, and the style recipes that dress it.

States
activemissingerrorloading
Platforms
webnativeruntime-node
Recipes
unstyledruntime-console

Renderers

Shared writer
Card renders through the one writer the server and the WASM DOM share, so both emit the same markup.

Every tag in the example above renders through a shared writer.

Declared adapters. A status is the manifest's declaration, not a measured parity result.

TargetRendererStatus
webreactexperimental
runtime-nodeview-nodeready
ssrhtml-semanticready
terminalterminal-layoutplanned
nativenative-adapterexperimental
5 rows

Accessibility

Named cards expose a labelled region without depending on recipe styling, while empty shells stay inspectable.

  • Cards with a visible title or explicit aria-label expose a stable accessible region name.
  • Title-less cards should use aria-label or aria-labelledby when they need landmark-style navigation.