MenuSectionTitle.tsx 741 B

12345678910111213141516171819202122232425262728
  1. import { VerticallyCenteredFlex } from "@ente/shared/components/Container";
  2. import { Typography } from "@mui/material";
  3. interface Iprops {
  4. title: string;
  5. icon?: JSX.Element;
  6. }
  7. export default function MenuSectionTitle({ title, icon }: Iprops) {
  8. return (
  9. <VerticallyCenteredFlex
  10. px="8px"
  11. py={"6px"}
  12. gap={"8px"}
  13. sx={{
  14. "& > svg": {
  15. fontSize: "17px",
  16. color: (theme) => theme.colors.stroke.muted,
  17. },
  18. }}
  19. >
  20. {icon && icon}
  21. <Typography variant="small" color="text.muted">
  22. {title}
  23. </Typography>
  24. </VerticallyCenteredFlex>
  25. );
  26. }