add: some util to dashboard

This commit is contained in:
Johannes Kirschbauer
2023-08-12 17:11:41 +02:00
parent 9a40891f7c
commit cdef88e55e
17 changed files with 582 additions and 116 deletions

View File

@@ -1,5 +1,22 @@
import { Card } from "@mui/material";
import { Typography } from "@mui/material";
import { ReactNode } from "react";
const DashboardCard = Card;
interface DashboardCardProps {
title: string;
children?: ReactNode;
}
const DashboardCard = (props: DashboardCardProps) => {
const { children, title } = props;
return (
<div className="h-full w-full bg-slate-50 shadow-sm shadow-slate-500">
<div className="h-full w-full px-3 py-2">
<Typography variant="h6" color={"secondary"}>
{title}
</Typography>
{children}
</div>
</div>
);
};
export { DashboardCard };