Card

Displays a card with header, content, and footer.

buridan add card

Component Guide

Use the following to build the Card component.

from components.ui.card import card

Source Code & Dependencies

For manual installation, copy each of the source codes below in their respective locations.

components/core/core.py

components/ui/card.py

Examples

Size

Use size="sm" for tighter spacing throughout the card.

Props used: size on card.root.

Scheduled reports
Weekly snapshots. No more manual exports.
  • Choose a schedule (daily, or weekly).
  • Send to channels or specific teammates.
  • Include charts, tables, and key metrics.

Spacing

Beyond size, use the --card-spacing CSS variable directly to control section spacing and inset.

Props used: class_name (setting --card-spacing inline) on card.root.

Login to your account
Enter your email below to login to your account

Use negative margins with -mx-(--card-spacing) to let content go edge-to-edge while staying aligned with the card's inset. When edge-to-edge content sits above a footer, add -mb-(--card-spacing) on card.content to remove the section gap.

Terms of Service
Review the terms before accepting the agreement.

These terms govern your use of the workspace, including access to shared documents, project files, and collaboration tools.

You are responsible for the content you upload and for ensuring that your team has the appropriate permissions to view or edit it.

We may update features or limits as the service evolves. When those changes materially affect your workflow, we will notify your workspace administrators.

By continuing, you agree to keep your account credentials secure and to follow your organization's acceptable use policies.

Image

Add an image before card.header to create a card with a cover image — corner radii adjust automatically for first/last-child images.

Props used: none required — place rx.el.img(...) as the first child of card.root.

Event cover
Featured
Design systems meetup
A practical talk on component APIs, accessibility, and shipping faster.

API Reference

card.root

card.root(
    card.header(card.title("Team members")),
    card.content("..."),
    size="sm",
)
Prop Type Default
size Literal["default", "sm"] "default"
class_name str ""

card.header

For a title, description, and optional action.

card.header(
    card.title("Team members"),
    card.description("Manage who has access."),
    card.action(button("Invite", size="sm")),
)
Prop Type Default
class_name str ""

card.title

card.title("Team members")
Prop Type Default
class_name str ""

card.description

card.description("Manage who has access to this project.")
Prop Type Default
class_name str ""

card.action

Places content in the top-right of the header (a button, badge, etc.).

card.action(button("Invite", size="sm"))
Prop Type Default
class_name str ""

card.content

card.content("Main card body content.")
Prop Type Default
class_name str ""

card.footer

card.footer(button("Cancel", variant="ghost"), button("Save"))
Prop Type Default
class_name str ""