This commit is contained in:
2024-07-21 10:58:51 +03:00
parent 54c9ca8908
commit af05b51d1c
188 changed files with 1155 additions and 555 deletions

View File

@@ -1,9 +1,9 @@
import {FC, ReactNode} from "react";
import {AppShell} from "@mantine/core";
import {Navbar} from "../../components/Navbar/Navbar.tsx";
import {AppShell, Flex, rem} from "@mantine/core";
import {useSelector} from "react-redux";
import {RootState} from "../../redux/store.ts";
import styles from './PageWrapper.module.css';
import { Navbar } from "../../components/Navbar/Navbar.tsx";
export type Props = {
children: ReactNode;
@@ -13,15 +13,22 @@ const PageWrapper: FC<Props> = ({children}) => {
return (
<AppShell
layout={"alt"}
withBorder={false}
navbar={authState.isAuthorized ? {
width: '5%',
width: "130px",
breakpoint: "sm"
} : undefined}
>
<AppShell.Navbar>
{authState.isAuthorized &&
<Navbar/>
<Flex className={styles['main-container']} h={"100%"} w={"100%"}
pl={rem(20)}
py={rem(20)}
>
<Navbar/>
</Flex>
}
</AppShell.Navbar>
<AppShell.Main className={styles['main-container']}>