refactoring
This commit is contained in:
@ -9,7 +9,7 @@ import { ServiceCode } from "@/enums/ServiceCode";
|
|||||||
import { RootState } from "@/lib/store";
|
import { RootState } from "@/lib/store";
|
||||||
import ServiceData from "@/types/ServiceData";
|
import ServiceData from "@/types/ServiceData";
|
||||||
|
|
||||||
const ConfirmAccessButton: FC = () => {
|
const ConsentButton: FC = () => {
|
||||||
const serviceCode = useSelector(
|
const serviceCode = useSelector(
|
||||||
(state: RootState) => state.targetService.serviceCode
|
(state: RootState) => state.targetService.serviceCode
|
||||||
);
|
);
|
||||||
@ -41,4 +41,4 @@ const ConfirmAccessButton: FC = () => {
|
|||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
export default ConfirmAccessButton;
|
export default ConsentButton;
|
||||||
@ -1,9 +1,9 @@
|
|||||||
import { FC } from "react";
|
import { FC } from "react";
|
||||||
import { Stack, Text } from "@mantine/core";
|
import { Stack, Text } from "@mantine/core";
|
||||||
import ConfirmAccessButton from "@/components/ConfirmAccessForm/ConfirmAccessButton";
|
import ConfirmAccessButton from "@/app/consent/components/ConsentButton/ConsentButton";
|
||||||
import styles from "./ConfirmAccessForm.module.css";
|
import styles from "./ConsentForm.module.css";
|
||||||
|
|
||||||
const ConfirmAccessForm: FC = () => {
|
const ConsentForm: FC = () => {
|
||||||
return (
|
return (
|
||||||
<Stack
|
<Stack
|
||||||
align={"center"}
|
align={"center"}
|
||||||
@ -19,4 +19,4 @@ const ConfirmAccessForm: FC = () => {
|
|||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
export default ConfirmAccessForm;
|
export default ConsentForm;
|
||||||
@ -1,7 +1,7 @@
|
|||||||
import PageContainer from "@/components/PageContainer/PageContainer";
|
import PageContainer from "@/components/PageContainer/PageContainer";
|
||||||
import PageItem from "@/components/PageBlock/PageItem";
|
import PageItem from "@/components/PageBlock/PageItem";
|
||||||
import Logo from "@/components/Logo/Logo";
|
import Logo from "@/components/Logo/Logo";
|
||||||
import ConfirmAccessForm from "@/components/ConfirmAccessForm/ConfirmAccessForm";
|
import ConsentForm from "@/app/consent/components/ConsentForm/ConsentForm";
|
||||||
|
|
||||||
|
|
||||||
export default function ConfirmAccessPage() {
|
export default function ConfirmAccessPage() {
|
||||||
@ -9,7 +9,7 @@ export default function ConfirmAccessPage() {
|
|||||||
<PageContainer center>
|
<PageContainer center>
|
||||||
<PageItem fullScreenMobile>
|
<PageItem fullScreenMobile>
|
||||||
<Logo title={"Вход с помощью LogiDex ID"} />
|
<Logo title={"Вход с помощью LogiDex ID"} />
|
||||||
<ConfirmAccessForm />
|
<ConsentForm />
|
||||||
</PageItem>
|
</PageItem>
|
||||||
</PageContainer>
|
</PageContainer>
|
||||||
)
|
)
|
||||||
@ -3,7 +3,7 @@
|
|||||||
import { useMemo } from "react";
|
import { useMemo } from "react";
|
||||||
import { redirect } from "next/navigation";
|
import { redirect } from "next/navigation";
|
||||||
import { Button, Stack, Title } from "@mantine/core";
|
import { Button, Stack, Title } from "@mantine/core";
|
||||||
import styles from "@/components/ServicesList/ServicesList.module.css";
|
import styles from "@/app/services/components/ServicesList/ServicesList.module.css";
|
||||||
import TitleWithLines from "@/components/TitleWithLines/TitleWithLines";
|
import TitleWithLines from "@/components/TitleWithLines/TitleWithLines";
|
||||||
import SERVICES from "@/constants/services";
|
import SERVICES from "@/constants/services";
|
||||||
import { ServiceCode } from "@/enums/ServiceCode";
|
import { ServiceCode } from "@/enums/ServiceCode";
|
||||||
@ -23,7 +23,7 @@ const ServicesList = () => {
|
|||||||
|
|
||||||
const onServiceClick = (service: ServiceData) => {
|
const onServiceClick = (service: ServiceData) => {
|
||||||
dispatch(setTargetService(service.code));
|
dispatch(setTargetService(service.code));
|
||||||
redirect("confirm-access");
|
redirect("consent");
|
||||||
};
|
};
|
||||||
|
|
||||||
const getServiceButton = (service: ServiceData, key: number) => {
|
const getServiceButton = (service: ServiceData, key: number) => {
|
||||||
@ -1,7 +1,7 @@
|
|||||||
import Logo from "@/components/Logo/Logo";
|
import Logo from "@/components/Logo/Logo";
|
||||||
import PageItem from "@/components/PageBlock/PageItem";
|
import PageItem from "@/components/PageBlock/PageItem";
|
||||||
import PageContainer from "@/components/PageContainer/PageContainer";
|
import PageContainer from "@/components/PageContainer/PageContainer";
|
||||||
import ServicesList from "@/components/ServicesList/ServicesList";
|
import ServicesList from "@/app/services/components/ServicesList/ServicesList";
|
||||||
|
|
||||||
export default function ServicesPage() {
|
export default function ServicesPage() {
|
||||||
return (
|
return (
|
||||||
@ -4,8 +4,8 @@ import { FC } from "react";
|
|||||||
import { redirect } from "next/navigation";
|
import { redirect } from "next/navigation";
|
||||||
import { Button, PinInput, Stack } from "@mantine/core";
|
import { Button, PinInput, Stack } from "@mantine/core";
|
||||||
import { useForm } from "@mantine/form";
|
import { useForm } from "@mantine/form";
|
||||||
import ResendVerificationCode from "@/components/ResendVerificationCode/ResendVerificationCode";
|
import ResendVerificationCode from "@/app/verify-phone/components/ResendVerificationCode/ResendVerificationCode";
|
||||||
import style from "@/components/VerifyPhoneForm/VerifyPhone.module.css";
|
import style from "@/app/verify-phone/components/VerifyPhoneForm/VerifyPhone.module.css";
|
||||||
|
|
||||||
type VerifyNumberForm = {
|
type VerifyNumberForm = {
|
||||||
code: string;
|
code: string;
|
||||||
@ -1,7 +1,7 @@
|
|||||||
import Logo from "@/components/Logo/Logo";
|
import Logo from "@/components/Logo/Logo";
|
||||||
import PageItem from "@/components/PageBlock/PageItem";
|
import PageItem from "@/components/PageBlock/PageItem";
|
||||||
import PageContainer from "@/components/PageContainer/PageContainer";
|
import PageContainer from "@/components/PageContainer/PageContainer";
|
||||||
import VerifyPhoneForm from "@/components/VerifyPhoneForm/VerifyPhoneForm";
|
import VerifyPhoneForm from "@/app/verify-phone/components/VerifyPhoneForm/VerifyPhoneForm";
|
||||||
|
|
||||||
export default function CreateIdPage() {
|
export default function CreateIdPage() {
|
||||||
return (
|
return (
|
||||||
@ -8,7 +8,6 @@
|
|||||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.16),
|
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.16),
|
||||||
0 4px 24px rgba(0, 0, 0, 0.16);
|
0 4px 24px rgba(0, 0, 0, 0.16);
|
||||||
}
|
}
|
||||||
padding: rem(25);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.icon {
|
.icon {
|
||||||
@ -7,7 +7,7 @@ import {
|
|||||||
useComputedColorScheme,
|
useComputedColorScheme,
|
||||||
useMantineColorScheme,
|
useMantineColorScheme,
|
||||||
} from "@mantine/core";
|
} from "@mantine/core";
|
||||||
import style from "./ActionToggle.module.css";
|
import style from "@/components/ColorSchemeToggle/ColorSchemeToggle.module.css";
|
||||||
|
|
||||||
export function ColorSchemeToggle() {
|
export function ColorSchemeToggle() {
|
||||||
const { setColorScheme } = useMantineColorScheme();
|
const { setColorScheme } = useMantineColorScheme();
|
||||||
@ -16,7 +16,7 @@
|
|||||||
"jsx": "preserve",
|
"jsx": "preserve",
|
||||||
"incremental": true,
|
"incremental": true,
|
||||||
"paths": {
|
"paths": {
|
||||||
"@/*": ["./*"]
|
"@/*": ["./src/*"]
|
||||||
},
|
},
|
||||||
"plugins": [{ "name": "next" }]
|
"plugins": [{ "name": "next" }]
|
||||||
},
|
},
|
||||||
|
|||||||
Reference in New Issue
Block a user