ghost-dao-interface/src/components/PageTitle/PageTitle.jsx
Uncle Fatso f64570eea5
make select network element fit into the screen on mobile devices
Signed-off-by: Uncle Fatso <uncle.fatso@ghostchain.io>
2025-06-30 20:01:07 +03:00

27 lines
925 B
JavaScript

import { Box, Typography, useMediaQuery, useTheme } from "@mui/material";
const PageTitle = ({ name, subtitle, noMargin }) => {
const theme = useTheme();
const mobile = useMediaQuery(theme.breakpoints.down("700"));
return (
<Box
width="100%"
marginLeft={noMargin ? "0px" : mobile ? "9px" : "33px"}
marginTop={mobile ? "50px" : "0px"}
paddingBottom="22.5px"
>
<Box paddingTop="3px" display="flex" flexDirection="row" justifyContent="flex-start" alignContent="center">
<Typography variant="h1">{name}</Typography>
</Box>
{subtitle && (
<Box display="flex" flexDirection="row" justifyContent="flex-start">
<Typography color={theme.colors.gray[40]}>{subtitle}</Typography>
</Box>
)}
</Box>
);
};
export default PageTitle;