Generic node working, passed object with types

This commit is contained in:
Lucas Oliveira 2023-02-14 19:00:20 -03:00
commit fc3fe6a85d
14 changed files with 551 additions and 240 deletions

View file

@ -0,0 +1,17 @@
import { styled } from '@mui/material/styles';
import Tooltip, { TooltipProps, tooltipClasses } from '@mui/material/Tooltip';
export const LightTooltip = styled(({ className, ...props }: TooltipProps) => (
<Tooltip {...props} classes={{ popper: className }} />
))(({ theme }) => ({
[`& .${tooltipClasses.tooltip}`]: {
backgroundColor: theme.palette.common.white,
color: 'rgba(0, 0, 0, 0.87)',
boxShadow: theme.shadows[2],
fontSize: 14,
},
[`& .${tooltipClasses.arrow}:before`]: {
color: theme.palette.common.white,
boxShadow: theme.shadows[1],
},
}));

View file

@ -0,0 +1,5 @@
import { LightTooltip } from "../LightTooltipComponent";
export default function Tooltip({ children, title }) {
return <LightTooltip title={title} arrow>{children}</LightTooltip>;
}