-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCustomLayout.tsx
More file actions
29 lines (25 loc) · 1.15 KB
/
CustomLayout.tsx
File metadata and controls
29 lines (25 loc) · 1.15 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
import React from 'react';
import MenuMobile from '@/components/Menu/MenuMobile';
import Menu from '@/components/Menu/Menu';
type Props = {
children: React.ReactNode;
withMenu?: boolean;
};
const CustomLayout = ({ children, withMenu }: Props) => {
return (
<>
<div className='fixed top-0 left-0 bottom-0 right-0 bg-[url("/grid-dark.svg")] visible dark:hidden opacity-30 dark:z-0 '></div>
<div className='fixed top-0 left-0 bottom-0 right-0 bg-[url("/grid.svg")] hidden dark:visible opacity-30 z-0'></div>
<div className='w-full text-black dark:text-white m-auto min-h-screen flex flex-col bg-white dark:bg-[radial-gradient(ellipse_at_center,_var(--tw-gradient-stops))] dark:from-gray-700 dark:via-gray-900 dark:to-black'>
<div className='relative'>
<div className='md:hidden'><MenuMobile /></div>
<div className='hidden md:block'><Menu /></div>
</div>
<div className='w-5/6 md:w-2/3 m-auto relative h-full '>
{children}
</div>
</div>
</>
);
};
export default CustomLayout;