main
|
Last change
on this file since 82aa6ae was 40ac7a9, checked in by Mihail <mihail2.naumov@…>, 7 months ago |
|
Added frontend elements
|
-
Property mode
set to
100644
|
|
File size:
1.1 KB
|
| Rev | Line | |
|---|
| [40ac7a9] | 1 | import React from 'react';
|
|---|
| 2 | import Navbar from '../components/Navbar';
|
|---|
| 3 | import Footer from '../components/Footer';
|
|---|
| 4 | import Box from '@mui/material/Box';
|
|---|
| 5 | import { ThemeProvider, createTheme } from '@mui/material/styles';
|
|---|
| 6 | import CssBaseline from '@mui/material/CssBaseline';
|
|---|
| [8ee4553] | 7 |
|
|---|
| [40ac7a9] | 8 | const theme = createTheme({
|
|---|
| 9 | palette: {
|
|---|
| 10 | mode: 'dark',
|
|---|
| 11 | primary: { main: '#ff8201' },
|
|---|
| 12 | background: { default: '#121212', paper: '#1e1e1e' },
|
|---|
| 13 | },
|
|---|
| 14 | });
|
|---|
| [8ee4553] | 15 |
|
|---|
| 16 | export default function Layout({ children }: { children: React.ReactNode }) {
|
|---|
| [40ac7a9] | 17 | return (
|
|---|
| 18 | <ThemeProvider theme={theme}>
|
|---|
| 19 | <CssBaseline />
|
|---|
| 20 | <Box
|
|---|
| 21 | sx={{
|
|---|
| 22 | display: 'flex',
|
|---|
| 23 | flexDirection: 'column',
|
|---|
| 24 | minHeight: '100vh',
|
|---|
| 25 | bgcolor: 'background.default',
|
|---|
| 26 | color: 'text.primary',
|
|---|
| 27 | }}
|
|---|
| 28 | >
|
|---|
| 29 | <Navbar />
|
|---|
| 30 | <Box component="main" sx={{ flexGrow: 1, py: 3 }}>
|
|---|
| 31 | {children}
|
|---|
| 32 | </Box>
|
|---|
| 33 | <Footer />
|
|---|
| 34 | </Box>
|
|---|
| 35 | </ThemeProvider>
|
|---|
| 36 | );
|
|---|
| [8ee4553] | 37 | }
|
|---|
Note:
See
TracBrowser
for help on using the repository browser.