요약·상세·상태·액션·카테고리 카드 등 자주 쓰는 카드 조합 5종입니다.
아이콘 + 숫자 + 단위로 핵심 지표를 요약하는 카드입니다.
<Card>
<CardContent className="flex flex-col gap-1 px-3 py-2.5">
<div className="flex items-center justify-between">
<p className="text-[10px] text-muted-foreground">{label}</p>
<Icon size={14} weight="duotone" className={tone} />
</div>
<p>
<span className="text-base font-black">{value.toLocaleString()}</span>
<span className="ml-0.5 text-[10px] text-muted-foreground">{unit}</span>
</p>
</CardContent>
</Card>미니 차트나 진행률 그래픽을 내장한 카드입니다.
<Card>
<CardContent className="px-2 pt-2 pb-1">
<p className="px-1 text-[11px] font-bold">일별 등록 추이</p>
<div className="flex h-[80px] items-end gap-1 px-2 pb-1">
{values.map((h, i) => (
<div key={i} className="flex-1 rounded-t bg-primary/60" style={{ height: `${h}%` }} />
))}
</div>
</CardContent>
</Card>상태 뱃지 + 진행률로 서비스/서버 상태를 보여주는 카드입니다.
<Card>
<CardContent className="flex flex-col gap-2 px-3 py-2.5">
<div className="flex items-center justify-between">
<span className="text-xs font-medium">{name}</span>
<Badge variant={statusVariant}>{status}</Badge>
</div>
<Progress value={percent} />
<span className="text-[10px] tabular-nums">{percent}%</span>
</CardContent>
</Card>버튼/링크로 이어지는 액션을 담은 카드입니다.
<Card>
<CardContent className="flex flex-col gap-2 px-3 py-3">
<Icon size={20} weight="duotone" className={tone} />
<div>
<p className="text-sm font-semibold">{title}</p>
<p className="text-xs text-muted-foreground">{description}</p>
</div>
<Button size="sm" variant="outline" className="w-fit">{actionLabel}</Button>
</CardContent>
</Card>카테고리로 묶은 하위 항목들을 한 카드에 정리해 보여줍니다.
<Card>
<CardContent className="flex flex-col gap-2 px-3 py-2.5">
<div className="flex items-center justify-between">
<div className="flex items-center gap-1.5">
<Icon size={14} weight="duotone" className={tone} />
<span className="text-xs font-semibold">{label}</span>
</div>
<span className="text-[10px] text-muted-foreground">{total.toLocaleString()}</span>
</div>
<div className="flex flex-col gap-1">
{items.map((item) => (
<div key={item.label} className="flex justify-between text-[10px] text-muted-foreground">
<span>{item.label}</span>
<span className="font-medium text-foreground">{item.value}</span>
</div>
))}
</div>
</CardContent>
</Card>