import Tooltip from "@mui/material/Tooltip"; import ListItemButton from "@mui/material/ListItemButton"; import ListItemIcon from "@mui/material/ListItemIcon"; import Box from "@mui/material/Box"; import Typography from "@mui/material/Typography"; import { useTheme } from "@mui/material/styles"; export interface NavData { name: string; icon: JSX.Element; } export const NavItem = ({ item, collapsed, selected, onClick, }: { item: NavData; collapsed: boolean; selected: boolean; onClick: (event: React.MouseEvent) => void; }) => { const theme = useTheme(); const iconStroke = selected ? theme.palette.primary.contrastText : theme.palette.primary.contrastTextTertiary; const buttonBgColor = selected ? theme.palette.secondary.main : "transparent"; const buttonBgHoverColor = selected ? theme.palette.secondary.main : theme.palette.tertiary.main; const fontWeight = selected ? 600 : 400; return ( {item.icon} {item.name} ); };