This commit is contained in:
chamikaJ
2025-04-17 18:28:54 +05:30
parent f583291d8a
commit 8825b0410a
2837 changed files with 241385 additions and 127578 deletions

View File

@@ -0,0 +1,44 @@
import { ConfigProvider, Flex, Layout } from 'antd';
import React from 'react';
import { Outlet } from 'react-router-dom';
import { useAppSelector } from '../hooks/useAppSelector';
import { colors } from '../styles/colors';
const AuthLayout = () => {
const themeMode = useAppSelector(state => state.themeReducer.mode);
return (
<ConfigProvider
theme={{
components: {
Layout: {
colorBgLayout: themeMode === 'dark' ? colors.darkGray : '#fafafa',
},
},
}}
>
<Layout
style={{
display: 'flex',
alignItems: 'center',
minHeight: '100vh',
width: '100%',
}}
>
<Flex
style={{
marginBlockStart: 96,
marginBlockEnd: 48,
marginInline: 24,
width: '90%',
maxWidth: 440,
}}
>
<Outlet />
</Flex>
</Layout>
</ConfigProvider>
);
};
export default AuthLayout;