import { Stack, Typography } from "@mui/material"; import { useTheme } from "@emotion/react"; import IconBox from "../../IconBox"; import PropTypes from "prop-types"; const ChartBox = ({ children, icon, header, height = "300px", justifyContent = "space-between", Legend, borderRadiusRight = 4, sx, }) => { const theme = useTheme(); return ( span": { color: theme.palette.primary.contrastText, fontSize: 20, "& span": { opacity: 0.8, marginLeft: 2, fontSize: 15, }, }, "& tspan, & text": { fill: theme.palette.primary.contrastTextTertiary, }, "& path": { transition: "fill 300ms ease, stroke-width 400ms ease", }, }} > {icon && {icon}} {header && {header}} {children} {Legend && Legend} ); }; export default ChartBox; ChartBox.propTypes = { children: PropTypes.node, icon: PropTypes.node, header: PropTypes.string, height: PropTypes.string, };