fixed theme and svgs

This commit is contained in:
Amirhossein Mahmoodi
2023-08-07 15:00:30 +03:30
parent 35ad9463e4
commit 65b13d3448
35 changed files with 879 additions and 631 deletions

View File

@@ -1,10 +1,10 @@
import CenterLayout from "@/layouts/CenterLayout";
import FullPageLayout from "@/layouts/FullPageLayout";
import {Box, Button, Container, Stack, Typography} from "@mui/material";
import {Button, Typography} from "@mui/material";
import {NextLinkComposed} from "@/core/components/LinkRouting";
import {useTranslations} from "next-intl";
import Image from "next/image";
import TitlePage from "@/core/components/TitlePage";
import Svg403 from "@/core/components/svgs/Svg403";
const UnAuthorizedComponent = () => {
const t = useTranslations();
@@ -13,32 +13,21 @@ const UnAuthorizedComponent = () => {
<>
<TitlePage text="Titles.title_custom_403"/>
<FullPageLayout sx={{p: 1}}>
<CenterLayout>
<Container maxWidth="sm">
<Stack spacing={4} sx={{p: 4}}>
<Box sx={{position: "relative", width: "100%", height: 200}}>
<Image
fill
src="/images/403.svg"
alt={t("app_name")}
priority
/>
</Box>
<Typography margin={2} variant="h6" textAlign="center">
{t("ErrorPage.custom_403")}
</Typography>
<Button
variant="contained"
component={NextLinkComposed}
to={{
pathname: "/",
}}
>
{t("ErrorPage.link_routing_back_to")}{" "}
{t("ErrorPage.link_routing_main_page")}
</Button>
</Stack>
</Container>
<CenterLayout spacing={3}>
<Svg403 width={300} height={200}/>
<Typography margin={2} variant="h6" textAlign="center">
{t("ErrorPage.custom_403")}
</Typography>
<Button
variant="contained"
component={NextLinkComposed}
to={{
pathname: "/",
}}
>
{t("ErrorPage.link_routing_back_to")}{" "}
{t("ErrorPage.link_routing_main_page")}
</Button>
</CenterLayout>
</FullPageLayout>
</>

View File

@@ -1,10 +1,10 @@
import CenterLayout from "@/layouts/CenterLayout";
import FullPageLayout from "@/layouts/FullPageLayout";
import {Box, Button, Container, Stack, Typography} from "@mui/material";
import {Button, Typography} from "@mui/material";
import {NextLinkComposed} from "@/core/components/LinkRouting";
import {useTranslations} from "next-intl";
import Image from "next/image";
import TitlePage from "@/core/components/TitlePage";
import Svg404 from "@/core/components/svgs/Svg404";
const NotFoundComponent = () => {
const t = useTranslations();
@@ -13,32 +13,21 @@ const NotFoundComponent = () => {
<>
<TitlePage text="Titles.title_custom_404"/>
<FullPageLayout sx={{p: 1}}>
<CenterLayout>
<Container maxWidth="sm">
<Stack spacing={4} sx={{p: 4}}>
<Box sx={{position: "relative", width: "100%", height: 200}}>
<Image
fill
src="/images/404.svg"
alt={t("app_name")}
priority
/>
</Box>
<Typography margin={2} variant="h6" textAlign="center">
{t("ErrorPage.custom_404")}
</Typography>
<Button
variant="contained"
component={NextLinkComposed}
to={{
pathname: "/",
}}
>
{t("ErrorPage.link_routing_back_to")}{" "}
{t("ErrorPage.link_routing_main_page")}
</Button>
</Stack>
</Container>
<CenterLayout spacing={3}>
<Svg404 width={300} height={200}/>
<Typography margin={2} variant="h6" textAlign="center">
{t("ErrorPage.custom_404")}
</Typography>
<Button
variant="contained"
component={NextLinkComposed}
to={{
pathname: "/",
}}
>
{t("ErrorPage.link_routing_back_to")}{" "}
{t("ErrorPage.link_routing_main_page")}
</Button>
</CenterLayout>
</FullPageLayout>
</>

View File

@@ -1,10 +1,10 @@
import CenterLayout from "@/layouts/CenterLayout";
import FullPageLayout from "@/layouts/FullPageLayout";
import {Box, Button, Container, Stack, Typography} from "@mui/material";
import {Button, Typography} from "@mui/material";
import {NextLinkComposed} from "@/core/components/LinkRouting";
import {useTranslations} from "next-intl";
import Image from "next/image";
import TitlePage from "@/core/components/TitlePage";
import Svg500 from "@/core/components/svgs/Svg500";
const ServerErrorComponent = () => {
const t = useTranslations();
@@ -13,32 +13,21 @@ const ServerErrorComponent = () => {
<>
<TitlePage text="Titles.title_custom_500"/>
<FullPageLayout sx={{p: 1}}>
<CenterLayout>
<Container maxWidth="sm">
<Stack spacing={4} sx={{p: 4}}>
<Box sx={{position: "relative", width: "100%", height: 200}}>
<Image
fill
src="/images/500.svg"
alt={t("app_name")}
priority
/>
</Box>
<Typography margin={2} variant="h6" textAlign="center">
{t("ErrorPage.custom_500")}
</Typography>
<Button
variant="contained"
component={NextLinkComposed}
to={{
pathname: "/",
}}
>
{t("ErrorPage.link_routing_back_to")}{" "}
{t("ErrorPage.link_routing_main_page")}
</Button>
</Stack>
</Container>
<CenterLayout spacing={3}>
<Svg500 width={300} height={200}/>
<Typography margin={2} variant="h6" textAlign="center">
{t("ErrorPage.custom_500")}
</Typography>
<Button
variant="contained"
component={NextLinkComposed}
to={{
pathname: "/",
}}
>
{t("ErrorPage.link_routing_back_to")}{" "}
{t("ErrorPage.link_routing_main_page")}
</Button>
</CenterLayout>
</FullPageLayout>
</>

View File

@@ -1,11 +1,10 @@
import dashboardImage from "&/images/dashboard.svg";
import {NextLinkComposed} from "@/core/components/LinkRouting";
import StyledImage from "@/core/components/StyledImage";
import CenterLayout from "@/layouts/CenterLayout";
import FullPageLayout from "@/layouts/FullPageLayout";
import useUser from "@/lib/app/hooks/useUser";
import {Button, Typography} from "@mui/material";
import {useTranslations} from "next-intl";
import SvgDashboard from "@/core/components/svgs/SvgDashboard";
const FirstComponent = () => {
const t = useTranslations();
@@ -14,13 +13,7 @@ const FirstComponent = () => {
return (
<FullPageLayout sx={{p: 1}}>
<CenterLayout spacing={3}>
<StyledImage
src={dashboardImage}
alt={t("app_name")}
width={300}
height={200}
priority
/>
<SvgDashboard width={300} height={200}/>
<Typography variant="h5" sx={{textAlign: "center"}}>
{t("app_name")}
</Typography>

View File

@@ -12,8 +12,8 @@ import {Box, Button, Container, Grid, Paper, Stack, TextField, Typography,} from
import axios from "axios";
import {Field, Formik} from "formik";
import {useTranslations} from "next-intl";
import Image from "next/image";
import * as Yup from "yup";
import SvgLogin from "@/core/components/svgs/SvgLogin";
const SendTokenComponent = ({
PhoneNumber,
@@ -65,16 +65,12 @@ const SendTokenComponent = ({
>
{(props) => (
<Stack spacing={2} sx={{p: 2}}>
<Box
sx={{position: "relative", width: "100%", height: 200}}
<Stack
sx={{width: "100%"}}
alignItems='center'
>
<Image
fill
src="/images/login.svg"
priority
alt={t("app_name")}
/>
</Box>
<SvgLogin width={300} height={200}/>
</Stack>
<Typography margin={2} variant="h4" textAlign="center">
{t("login")}
</Typography>

View File

@@ -7,13 +7,13 @@ import FullPageLayout from "@/layouts/FullPageLayout";
import useDirection from "@/lib/app/hooks/useDirection";
import FingerprintIcon from "@mui/icons-material/Fingerprint";
import PersonAddIcon from "@mui/icons-material/PersonAdd";
import {Box, Button, Container, Grid, Paper, Stack, TextField, Typography,} from "@mui/material";
import {Button, Container, Grid, Paper, Stack, TextField, Typography,} from "@mui/material";
import axios from "axios";
import {Field, Formik} from "formik";
import {useTranslations} from "next-intl";
import Image from "next/image";
import {useSearchParams} from "next/navigation";
import * as Yup from "yup";
import SvgLogin from "@/core/components/svgs/SvgLogin";
const SendUserDataComponent = ({
setOtpToken,
@@ -65,16 +65,12 @@ const SendUserDataComponent = ({
>
{(props) => (
<Stack spacing={2} sx={{p: 2}}>
<Box
sx={{position: "relative", width: "100%", height: 200}}
<Stack
sx={{width: "100%"}}
alignItems='center'
>
<Image
fill
src="/images/login.svg"
priority
alt={t("app_name")}
/>
</Box>
<SvgLogin width={300} height={200}/>
</Stack>
<Typography margin={2} variant="h4" textAlign="center">
{t("Titles.title_login_page")}
</Typography>

View File

@@ -6,13 +6,13 @@ import CenterLayout from "@/layouts/CenterLayout";
import FullPageLayout from "@/layouts/FullPageLayout";
import useDirection from "@/lib/app/hooks/useDirection";
import FingerprintIcon from "@mui/icons-material/Fingerprint";
import {Box, Button, Container, Paper, Stack, TextField, Typography,} from "@mui/material";
import {Button, Container, Paper, Stack, TextField, Typography,} from "@mui/material";
import axios from "axios";
import {Field, Formik} from "formik";
import {useTranslations} from "next-intl";
import Image from "next/image";
import {useSearchParams} from "next/navigation";
import * as Yup from "yup";
import SvgLogin from "@/core/components/svgs/SvgLogin";
const RequestOtpComponent = ({
setOtpToken,
@@ -66,16 +66,12 @@ const RequestOtpComponent = ({
>
{(props) => (
<Stack spacing={2} sx={{p: 2}}>
<Box
sx={{position: "relative", width: "100%", height: 200}}
<Stack
sx={{width: "100%"}}
alignItems='center'
>
<Image
fill
src="/images/login.svg"
priority
alt={t("app_name")}
/>
</Box>
<SvgLogin width={300} height={200}/>
</Stack>
<Typography margin={2} variant="h4" textAlign="center">
{t("Titles.title_register_page")}
</Typography>

View File

@@ -1,12 +1,11 @@
import dahsboardImage from "&/images/dashboard.svg";
import LinkRouting, {NextLinkComposed} from "@/core/components/LinkRouting";
import StyledImage from "@/core/components/StyledImage";
import CenterLayout from "@/layouts/CenterLayout";
import FullPageLayout from "@/layouts/FullPageLayout";
import useUser from "@/lib/app/hooks/useUser";
import {Box, Button, Grid, Stack} from "@mui/material";
import {useTranslations} from "next-intl";
import {useSearchParams} from "next/navigation";
import SvgDashboard from "@/core/components/svgs/SvgDashboard";
const RegisterComponent = () => {
const t = useTranslations();
@@ -18,13 +17,7 @@ const RegisterComponent = () => {
return (
<FullPageLayout sx={{p: 1}}>
<CenterLayout spacing={3}>
<StyledImage
src={dahsboardImage}
alt={t("app_name")}
width={300}
height={200}
priority
/>
<SvgDashboard width={300} height={200}/>
{isAuth ? (
<Button
variant="contained"

View File

@@ -10,10 +10,10 @@ import {Box, Button, Chip, Container, Divider, Paper, Stack, TextField, Typograp
import axios from "axios";
import {Field, Formik} from "formik";
import {useTranslations} from "next-intl";
import Image from "next/image";
import * as Yup from "yup";
import ResendToken from "@/core/components/ResendToken";
import useUser from "@/lib/app/hooks/useUser";
import SvgRegister from "@/core/components/svgs/SvgRegister";
const UserRegisterComponent = ({
PhoneNumber,
@@ -78,16 +78,12 @@ const UserRegisterComponent = ({
>
{(props) => (
<Stack spacing={2} sx={{p: 2}}>
<Box
sx={{position: "relative", width: "100%", height: 200}}
<Stack
sx={{width: "100%"}}
alignItems='center'
>
<Image
fill
src="/images/register.svg"
alt={t("app_name")}
priority
/>
</Box>
<SvgRegister width={300} height={200}/>
</Stack>
<Typography margin={2} variant="h4" textAlign="center">
{t("register_navy")}
</Typography>

View File

@@ -10,10 +10,10 @@ import {Box, Button, Chip, Container, Divider, Paper, Stack, TextField, Typograp
import axios from "axios";
import {Field, Formik} from "formik";
import {useTranslations} from "next-intl";
import Image from "next/image";
import * as Yup from "yup";
import ResendToken from "@/core/components/ResendToken";
import useUser from "@/lib/app/hooks/useUser";
import SvgRegister from "@/core/components/svgs/SvgRegister";
const UserRegisterComponent = ({
PhoneNumber,
@@ -75,16 +75,12 @@ const UserRegisterComponent = ({
>
{(props) => (
<Stack spacing={2} sx={{p: 2}}>
<Box
sx={{position: "relative", width: "100%", height: 200}}
<Stack
sx={{width: "100%"}}
alignItems='center'
>
<Image
fill
src="/images/register.svg"
alt={t("app_name")}
priority
/>
</Box>
<SvgRegister width={300} height={200}/>
</Stack>
<Typography margin={2} variant="h4" textAlign="center">
{t("register_welfare_services")}
</Typography>