Card
Card parts: a titled card renders as a section labelled by its title, with an eyebrow, a top-end action slot, a heading level on the title and card, dashed or bare surfaces.
Example
Apollo
Last deployed 2 hours ago
Ready
card-demo.tsxCopy code
Installation
Copy code
npm packages
class-variance-authority@0.7.1Usage
ImportCopy code
API reference
Card
| Prop | Type | Default |
|---|---|---|
surface`dashed` is an outlined, unfilled tile, like a "create" placeholder; `none` drops the box and its padding. | "card" | "none" | "dashed" | "card" |
Also takes <section> attributes and render.
CardHeader
Takes <div> attributes and render.
CardTitle
| Prop | Type | Default |
|---|---|---|
headingLevelRenders an `h1`–`h6`. Without it the title is a `div` that still names the card. | HeadingLevel | – |
Also takes <div> attributes and render.
Other exports
CardActionCardContentCardDescriptionCardEyebrowCardFootercardVariantsCardTitleContextuseCardTitleRegistrationtype CardPropstype CardSurfacetype CardTitlePropstype CardHeadingLevelAccessibility
- A titled card is a section labelled by its title; pass render={<li />} to keep list cards out of the landmarks.
Agent actions
Runs agent.snapshot() from @ui-sdk/react/agent on the live preview above.