Merge pull request 'RC-12-registration-popup' (#7) from RC-12-registration-popup into dev
Reviewed-on: #7
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
import i18next from 'i18next';
|
||||
|
||||
import ForgotPasswordPage from './ForgotPasswordPage';
|
||||
import authRoles from '../../../configs/consts';
|
||||
import { authRoles } from '../../../configs/consts';
|
||||
import en from './i18n/en';
|
||||
|
||||
i18next.addResourceBundle('en', 'forgotPasswordPage', en);
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import i18next from 'i18next';
|
||||
|
||||
import SignInPage from './SignInPage';
|
||||
import authRoles from '../../../configs/consts';
|
||||
import { authRoles } from '../../../configs/consts';
|
||||
import en from './i18n/en';
|
||||
|
||||
i18next.addResourceBundle('en', 'signInPage', en);
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import i18next from 'i18next';
|
||||
|
||||
import SignUpPage from './SignUpPage';
|
||||
import authRoles from '../../../configs/consts';
|
||||
import { authRoles } from '../../../configs/consts';
|
||||
import en from './i18n/en';
|
||||
|
||||
i18next.addResourceBundle('en', 'signUpPage', en);
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import i18next from 'i18next';
|
||||
|
||||
import authRoles from '../../../configs/consts';
|
||||
import { authRoles } from '../../../configs/consts';
|
||||
import Dashboard from './Dashboard';
|
||||
import en from './i18n/en';
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { lazy } from 'react';
|
||||
import i18next from 'i18next';
|
||||
|
||||
import authRoles from '../../../configs/consts';
|
||||
import { authRoles } from '../../../configs/consts';
|
||||
import en from './i18n/en';
|
||||
|
||||
i18next.addResourceBundle('en', 'favoritesPage', en);
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { lazy } from 'react';
|
||||
import i18next from 'i18next';
|
||||
|
||||
import authRoles from '../../../configs/consts';
|
||||
import { authRoles } from '../../../configs/consts';
|
||||
import en from './i18n/en';
|
||||
|
||||
i18next.addResourceBundle('en', 'historyPage', en);
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { lazy } from 'react';
|
||||
import i18next from 'i18next';
|
||||
|
||||
import authRoles from '../../../configs/consts';
|
||||
import { authRoles } from '../../../configs/consts';
|
||||
import en from './i18n/en';
|
||||
|
||||
i18next.addResourceBundle('en', 'profilePage', en);
|
||||
|
||||
44
src/app/main/shared-components/popups/BasicPopup.js
Normal file
44
src/app/main/shared-components/popups/BasicPopup.js
Normal file
@@ -0,0 +1,44 @@
|
||||
import Backdrop from '@mui/material/Backdrop';
|
||||
import Box from '@mui/material/Box';
|
||||
import Fade from '@mui/material/Fade';
|
||||
import Modal from '@mui/material/Modal';
|
||||
import { memo } from 'react';
|
||||
|
||||
const style = {
|
||||
position: 'absolute',
|
||||
top: '50%',
|
||||
left: '50%',
|
||||
transform: 'translate(-50%, -50%)',
|
||||
width: 400,
|
||||
bgcolor: 'inherit',
|
||||
boxShadow: 24,
|
||||
overflow: 'hidden',
|
||||
};
|
||||
|
||||
function BasicPopup({ children, className, open, onClose }) {
|
||||
return (
|
||||
<div>
|
||||
<Modal
|
||||
aria-labelledby="transition-modal-title"
|
||||
aria-describedby="transition-modal-description"
|
||||
open={open}
|
||||
onClose={onClose}
|
||||
closeAfterTransition
|
||||
slots={{ backdrop: Backdrop }}
|
||||
slotProps={{
|
||||
backdrop: {
|
||||
timeout: 500,
|
||||
},
|
||||
}}
|
||||
>
|
||||
<Fade in={open}>
|
||||
<Box sx={style} className={className}>
|
||||
{children}
|
||||
</Box>
|
||||
</Fade>
|
||||
</Modal>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
export default memo(BasicPopup);
|
||||
72
src/app/main/shared-components/popups/RegistrationPopup.js
Normal file
72
src/app/main/shared-components/popups/RegistrationPopup.js
Normal file
@@ -0,0 +1,72 @@
|
||||
import Box from '@mui/material/Box';
|
||||
import Typography from '@mui/material/Typography';
|
||||
import { memo } from 'react';
|
||||
import { Link } from 'react-router-dom';
|
||||
import BasicPopup from './BasicPopup';
|
||||
|
||||
const bullets = [
|
||||
'Lorem ipsum rci egestas. Tortor nulla ac est nulla nisl ut.',
|
||||
'Lorem ipsum dolor sit amet consectetur.',
|
||||
'Lorem ipsum rci egestas. Tortor nulla ac est nulla nisl ut.',
|
||||
'Lorem ipsum dolor sit amet consectetur.',
|
||||
'Lorem ipsum dolor sit amet consectetur.',
|
||||
'Lorem ipsum dt amet consectetur. Duis massa vel estas. Tortor nulla ac est nulla nisl ut.',
|
||||
'Lorem ipsum dolor sit amet consectetur.',
|
||||
];
|
||||
|
||||
function RegistrationPopup({ open, onClose }) {
|
||||
return (
|
||||
<BasicPopup
|
||||
className="flex max-w-[76vw] w-full h-[66vh] min-h-[600px] rounded-20"
|
||||
open={open}
|
||||
onClose={onClose}
|
||||
>
|
||||
<Box
|
||||
className="relative hidden md:flex flex-auto items-center justify-center h-full p-64 lg:px-112 overflow-hidden max-w-[45vw] w-full"
|
||||
sx={{ backgroundColor: 'common.layout' }}
|
||||
>
|
||||
<svg
|
||||
className="absolute inset-0 pointer-events-none"
|
||||
viewBox="0 0 960 540"
|
||||
width="100%"
|
||||
height="100%"
|
||||
preserveAspectRatio="xMidYMax slice"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
>
|
||||
<Box
|
||||
component="g"
|
||||
sx={{ color: 'primary.light' }}
|
||||
className="opacity-20"
|
||||
fill="none"
|
||||
stroke="currentColor"
|
||||
strokeWidth="100"
|
||||
>
|
||||
<circle r="234" cx="266" cy="23" />
|
||||
<circle r="234" cx="790" cy="551" />
|
||||
</Box>
|
||||
</svg>
|
||||
</Box>
|
||||
<Box
|
||||
className="flex flex-col items-center px-60 pt-56"
|
||||
sx={{ backgroundColor: 'background.paper' }}
|
||||
>
|
||||
<Typography variant="h4" className="mb-52 text-4xl font-semibold">
|
||||
Lorem ipsum dolor sit amet consetur
|
||||
</Typography>
|
||||
<ul className="flex flex-col gap-10 mb-68">
|
||||
{bullets.map((bullet) => (
|
||||
<li className="bullet">{bullet}</li>
|
||||
))}
|
||||
</ul>
|
||||
<Link
|
||||
className="w-full py-20 text-center text-xl text-primary-light font-semibold tracking-widest rounded-2xl bg-secondary-main shadow hover:shadow-hover hover:shadow-secondary-main ease-in-out duration-300"
|
||||
to="/sign-up"
|
||||
>
|
||||
Try for free
|
||||
</Link>
|
||||
</Box>
|
||||
</BasicPopup>
|
||||
);
|
||||
}
|
||||
|
||||
export default memo(RegistrationPopup);
|
||||
@@ -7,7 +7,7 @@ function FooterLayout2() {
|
||||
const { t } = useTranslation('layout2');
|
||||
|
||||
return (
|
||||
<footer className="flex items-center justify-center w-full bg-common-layout">
|
||||
<footer className="z-[10000] flex items-center justify-center w-full bg-common-layout">
|
||||
<div className="flex gap-96 w-full max-w-screen-xl px-10 py-52">
|
||||
<ul className="flex flex-col gap-16 mr-96">
|
||||
<li>
|
||||
|
||||
@@ -8,7 +8,7 @@ function HeaderLayout2(props) {
|
||||
const { t } = useTranslation('layout2');
|
||||
|
||||
return (
|
||||
<header className="fixed z-50 flex items-center justify-center w-full h-72 px-10 bg-primary-light">
|
||||
<header className="fixed z-[10000] flex items-center justify-center w-full h-72 px-10 bg-primary-light">
|
||||
<div className="flex justify-between max-w-screen-xl w-full">
|
||||
<Link to="/">
|
||||
<img
|
||||
|
||||
Reference in New Issue
Block a user