Add headers to card component

This commit is contained in:
2025-08-30 22:04:30 +02:00
parent 9dbb0d6b4d
commit 0347ead200
4 changed files with 37 additions and 25 deletions

View File

@@ -1,11 +1,26 @@
import CardHeader from "@/components/CardHeader/CardHeader";
import style from "./style.module.css";
export default function Card({
active,
icon,
name,
children,
active = false,
header = true,
}: {
icon: string;
name: string;
active?: boolean;
header?: boolean;
children: React.ReactNode;
}) {
return <div className={style.card}>{children}</div>;
return (
<div className={style.card}>
{header && (
<CardHeader icon={icon} content={name} isActive={active} />
)}
{children}
</div>
);
}