Skip to Content

Data display

Card

Groups related content and actions inside a bordered surface.

@dawn/ui/components/card

Preview

Rendered from @dawn/ui
Follow-up consultation
Thursday, 23 July · 10:30
AL

Ada Lovelace

30 minutes · Dr. Meyer

Confirmed

Usage

import { Button } from "@dawn/ui/components/button";
import {
  Card,
  CardAction,
  CardContent,
  CardDescription,
  CardHeader,
  CardTitle,
} from "@dawn/ui/components/card";

export const AppointmentCard = () => (
  <Card>
    <CardHeader>
      <CardTitle>Follow-up</CardTitle>
      <CardDescription>Thursday · 10:30</CardDescription>
      <CardAction>
        <Button size="sm" variant="outline">Open</Button>
      </CardAction>
    </CardHeader>
    <CardContent>30 minutes with Dr. Meyer</CardContent>
  </Card>
);

API

sizedefault | sm
Sets the card spacing and title size.
CardActiondiv props
Occupies the header action column when placed inside CardHeader.
CardFooterdiv props
Adds the separated muted footer treatment.

Exports

CardCardHeaderCardTitleCardDescriptionCardActionCardContentCardFooter
Last updated on