Create a workspace
Invite your team after it's set up.
Installation
$ pnpm dlx shadcn@latest add @synccn/cardFirst time in this project? Connect synccn with one command.
Usage
import { Card, CardHeader, CardTitle, CardDescription, CardContent, CardFooter } from "@/components/ui/card";<Card> <CardHeader><CardTitle>Title</CardTitle></CardHeader> <CardContent>…</CardContent></Card>API reference
Generated from the component's TypeScript types, so it always matches the code.
Card
- className
stringExtra classes for the root element.
Also accepts every standard <div> attribute, and forwards its ref.
CardHeader
- className
stringExtra classes for the root element.
Also accepts every standard <div> attribute, and forwards its ref.
CardTitle
- className
stringExtra classes for the root element.
Also accepts every standard <heading> attribute, and forwards its ref.
CardDescription
- className
stringExtra classes for the root element.
Also accepts every standard <paragraph> attribute, and forwards its ref.
CardContent
- className
stringExtra classes for the root element.
Also accepts every standard <div> attribute, and forwards its ref.
CardFooter
- className
stringExtra classes for the root element.
Also accepts every standard <div> attribute, and forwards its ref.
Dependencies
Read from the component's imports when the site builds. The CLI installs all of these for you.
Helpers
- lib/utilscn (merges class names)
npm packages
- clsx for cn()
- tailwind-merge for cn()
Accessibility
From the source
Read from this component's code when the site builds, so it can't drift.
No ARIA roles, key handling or motion settings in its source. It renders plain elements, so its accessibility comes from the content and labels you give it.