Press n or j to go to the next uncovered block, b, p or k for the previous block.
| 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 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 | 4x 157x 157x 157x 4x | import React from "react";
import Logo from "@assets/icons/RebrandedIcons/LogoBlueAccent";
import { MainLogo } from "@hooks/common/useEnterpriseLogo";
import { Box, Stack } from "@mui/material";
import { styled } from "@theme/v2/Provider";
import GivePageFooter from "./GivePageFooter";
import { BACKGROUND_VIDEO_PRIMARY } from "@constants/constants";
type Props = {
children: React.ReactNode;
hideFooterLogo?: boolean;
stripLoginContainer?: boolean;
isOTPStep?: boolean;
};
const LoginMainContainer = ({ children }: Props) => {
return (
<Box sx={bgContainerStye}>
<video autoPlay muted loop playsInline preload="auto">
<source src={BACKGROUND_VIDEO_PRIMARY} type="video/mp4" />
</video>
<StyledRoot>
<MainLogo position="center" defaultLogo={<Logo />} isAuthPage />
<Container>{children}</Container>
<GivePageFooter hidePoweredBy />
</StyledRoot>
</Box>
);
};
const StyledRoot = styled(Box)(({ theme }) => ({
position: "relative",
zIndex: 1,
height: "100%",
display: "flex",
flexDirection: "column",
alignItems: "center",
justifyContent: "space-between",
overflow: "hidden",
padding: "32px 32px 48px 32px",
[theme.breakpoints.down("sm")]: {
padding: "20px 20px 48px 20px",
},
}));
const Container = styled(Stack)(({ theme }) => ({
display: "flex",
flexDirection: "column",
padding: "40px",
width: "480px",
borderRadius: theme.customs?.radius.medium,
backgroundColor:
theme.palette.surface?.["primary-transparent"] ??
theme.palette.surface?.primary,
backdropFilter: "blur(8px)",
boxShadow: `
1px 2px 2px 0px ${
theme.palette.surface?.primary ?? theme.palette.primitive?.neutral?.["0"]
} inset,
-1px -2px 0.5px 0px ${
theme.palette.primitive?.transparent?.["darken-10"]
} inset
`,
[theme.breakpoints.down("sm")]: {
padding: "40px 20px",
width: "100%",
},
}));
export const bgContainerStye = {
position: "relative",
height: "100vh",
width: "100%",
overflow: "hidden",
"@supports (height: 100dvh)": {
height: "100dvh",
},
"& div": {
zIndex: 1,
},
"& video": {
overflow: "hidden",
position: "absolute",
width: "100%",
height: "100%",
objectFit: "cover",
top: 0,
left: 0,
zIndex: -1,
},
// Gradient overlay
"&::before": {
content: '""',
position: "absolute",
inset: 0,
zIndex: 0,
background: `
linear-gradient(0deg, rgba(255, 255, 255, 0.3), rgba(255, 255, 255, 0.3)),
linear-gradient(180deg, rgba(255, 255, 255, 0) 76.99%, #FFFFFF 100%),
linear-gradient(0deg, rgba(255, 255, 255, 0) 77.22%, rgba(255, 255, 255, 0.6) 100%)
`,
},
};
export default LoginMainContainer;
|