This commit is contained in:
Darren Clarke 2024-03-16 19:39:20 +01:00
parent 43bfdaa1e3
commit fe6c9419dd
87 changed files with 16739 additions and 2526 deletions

View file

@ -3,19 +3,36 @@
import { FC, PropsWithChildren, useState } from "react";
import { Grid } from "@mui/material";
import { Sidebar } from "./Sidebar";
import { CssBaseline } from "@mui/material";
import { css, Global } from "@emotion/react";
import { fonts } from "@/app/_styles/theme";
type LayoutProps = PropsWithChildren<{
docs?: any;
}>;
export const InternalLayout: FC<PropsWithChildren> = ({ children }) => {
const [open, setOpen] = useState(true);
const { roboto } = fonts;
const globalCSS = css`
* {
font-family: ${roboto.style.fontFamily};
}
`;
return (
<Grid container direction="row">
<Sidebar open={open} setOpen={setOpen} />
<Grid
item
sx={{ ml: open ? "270px" : "100px", width: "100%", height: "100vh" }}
>
{children as any}
<>
<Global styles={globalCSS} />
<CssBaseline />
<Grid container direction="row">
<Sidebar open={open} setOpen={setOpen} />
<Grid
item
sx={{ ml: open ? "270px" : "100px", width: "100%", height: "100vh" }}
>
{children as any}
</Grid>
</Grid>
</Grid>
</>
);
};