Card
Displays a card with header, content, and footer sections.
Installation
The Card component is part of Slate UI Kit and is available by default.
Usage
Simple Card
A card without header or footer.
Card with Header Only
Card with Footer Only
Card Variants
Cards can be styled with different variants using the variant prop.
API Reference
Card Component
| Prop | Type | Default | Description |
|---|---|---|---|
variant |
string |
"default" |
Card variant. Options: default, outlined |
color |
string |
null |
Card color variant |
Card Header
Container for card title and description.
Card Title
| Prop | Type | Default | Description |
|---|---|---|---|
as |
string |
"h3" |
HTML element to render. Options: h1, h2, h3, h4, h5, h6 |
Card Description
| Prop | Type | Default | Description |
|---|---|---|---|
as |
string |
"p" |
HTML element to render. Options: p, span, div |
Card Content
Main content area of the card.
Card Footer
Footer section of the card, typically used for actions.
Accessibility
The Card component includes:
- Proper semantic HTML structure
- ARIA attributes where appropriate
- Keyboard navigation support