guild_front/src/pages/AuthForCandidate/AuthForCandidate.jsx

154 lines
5.4 KiB
React
Raw Normal View History

2024-01-16 21:29:24 +03:00
import React, { useEffect, useState } from "react";
import { useSelector } from "react-redux";
2023-05-25 10:57:57 +03:00
import { useNavigate } from "react-router-dom";
2024-01-16 21:29:24 +03:00
import { selectAuth } from "@redux/outstaffingSlice";
2023-05-31 08:36:15 +03:00
2023-07-07 01:21:07 +03:00
import AuthBlock from "@components/AuthBlock/AuthBlock";
2023-05-31 08:36:15 +03:00
import CategoriesItem from "@components/CategoriesItem/CategoriesItem";
2023-05-30 10:54:47 +03:00
import AuthHeader from "@components/Common/AuthHeader/AuthHeader";
2023-05-31 08:36:15 +03:00
import { Footer } from "@components/Common/Footer/Footer";
2024-01-16 21:29:41 +03:00
import ModalResetPassword from "@components/Modal/ModalResetPassword/ModalResetPassword";
2023-05-30 10:54:47 +03:00
import SideBar from "@components/SideBar/SideBar";
import StepsForCandidate from "@components/StepsForCandidate/StepsForCandidate";
2023-04-04 19:07:19 +03:00
2023-05-31 08:36:15 +03:00
import arrowBtn from "assets/icons/arrows/arrowRight.svg";
import AdminImg from "assets/images/partnerProfile/PersonalAdmin.svg";
2023-05-30 10:54:47 +03:00
import ArchitectureImg from "assets/images/partnerProfile/PersonalArchitecture.svg";
2023-05-31 08:36:15 +03:00
import CopyImg from "assets/images/partnerProfile/PersonalCopy.svg";
2023-05-30 10:54:47 +03:00
import DesignImg from "assets/images/partnerProfile/PersonalDesign.svg";
2023-05-31 08:36:15 +03:00
import FrontendImg from "assets/images/partnerProfile/PersonalFrontend.svg";
2023-05-30 10:54:47 +03:00
import ManageImg from "assets/images/partnerProfile/PersonalMng.svg";
import SmmImg from "assets/images/partnerProfile/PersonalSMM.svg";
2023-05-31 08:36:15 +03:00
import TestImg from "assets/images/partnerProfile/PersonalTesters.svg";
import BackEndImg from "assets/images/partnerProfile/personalBackEnd.svg";
2023-04-04 19:07:19 +03:00
2023-05-24 13:49:09 +03:00
import "./authForCandidate.scss";
2023-04-04 19:07:19 +03:00
export const AuthForCandidate = () => {
2023-05-24 13:49:09 +03:00
const isAuth = useSelector(selectAuth);
let navigate = useNavigate();
2024-01-16 21:29:24 +03:00
const [modalResetOpen, setModalReset] = useState(false);
2023-05-24 13:49:09 +03:00
const getToken = localStorage.getItem("auth_token");
2023-04-04 19:07:19 +03:00
2023-05-24 13:49:09 +03:00
const [personalInfoItems] = useState([
{
title: "Backend разработчики",
link: "/registration-candidate",
description:
"Java PHP Python C# React Vue.js NodeJs Golang Ruby JavaScript",
available: true,
2023-12-19 17:36:30 +03:00
img: BackEndImg
2023-05-24 13:49:09 +03:00
},
{
title: "Frontend разработчики",
link: "/registration-candidate",
description:
"Java PHP Python C# React Vue.js NodeJs Golang Ruby JavaScript",
available: true,
2023-12-19 17:36:30 +03:00
img: FrontendImg
2023-05-24 13:49:09 +03:00
},
{
title: "Архитектура проектов",
link: "/registration-candidate",
description: "Потоки данных ER ERP CRM CQRS UML BPMN",
available: true,
2023-12-19 17:36:30 +03:00
img: ArchitectureImg
2023-05-24 13:49:09 +03:00
},
{
title: "Дизайн проектов",
link: "/registration-candidate",
description:
"Java PHP Python C# React Vue.js NodeJs Golang Ruby JavaScript",
available: true,
2023-12-19 17:36:30 +03:00
img: DesignImg
2023-05-24 13:49:09 +03:00
},
{
title: "Тестирование проектов",
link: "/registration-candidate",
description: "SQL Postman TestRail Kibana Ручное тестирование",
available: false,
2023-12-19 17:36:30 +03:00
img: TestImg
2023-05-24 13:49:09 +03:00
},
{
title: "Администрирование проектов",
link: "/registration-candidate",
description: "DevOps ELK Kubernetes Docker Bash Apache Oracle Git",
available: false,
2023-12-19 17:36:30 +03:00
img: AdminImg
2023-05-24 13:49:09 +03:00
},
{
title: "Управление проектом",
link: "/registration-candidate",
description: "Scrum Kanban Agile Miro CustDev",
available: false,
2023-12-19 17:36:30 +03:00
img: ManageImg
2023-05-24 13:49:09 +03:00
},
{
title: "Копирайтинг проектов",
link: "/registration-candidate",
description: "Теги Заголовок H1 Дескриптор Абзац Сценарий",
available: false,
2023-12-19 17:36:30 +03:00
img: CopyImg
2023-05-24 13:49:09 +03:00
},
{
title: "Реклама и SMM",
link: "/registration-candidate",
description:
"Java PHP Python C# React Vue.js NodeJs Golang Ruby JavaScript",
available: false,
2023-12-19 17:36:30 +03:00
img: SmmImg
}
2023-05-24 13:49:09 +03:00
]);
2023-04-04 19:07:19 +03:00
2023-05-24 13:49:09 +03:00
useEffect(() => {
if (isAuth || getToken) {
navigate("/profile");
}
}, [getToken]);
2023-04-04 19:07:19 +03:00
2023-05-24 13:49:09 +03:00
return (
<div className="auth-candidate">
<AuthHeader />
<div className="container">
2023-07-07 01:21:07 +03:00
<AuthBlock
2024-01-16 21:29:24 +03:00
resetModal={setModalReset}
2023-12-05 14:50:15 +03:00
title="Войти, если есть доступ"
description="Если вы получили доступ, пройдя
2024-02-14 19:32:13 +03:00
2 шага для входа, или хотите узнать
2023-07-07 01:21:07 +03:00
свои результаты в кабинете"
/>
2023-05-24 13:49:09 +03:00
<div className="auth-candidate__start">
<h2 className="auth-candidate__start__title">
2023-12-04 18:00:12 +03:00
Хочу в команду <span>IT-специалистов</span>
2023-05-24 13:49:09 +03:00
</h2>
<div className="change-mode__arrow">
<img src={arrowBtn} alt="#"></img>
</div>
<p className="auth-candidate__start__description">
Для нас не имеет значение Ваша локация.
</p>
<div className="auth-candidate__start__categories-wrapper">
2023-12-04 18:00:12 +03:00
<StepsForCandidate step="шаг 1 - выберите специализацию" />
2023-05-24 13:49:09 +03:00
{personalInfoItems.map((item, index) => {
return (
<CategoriesItem
link={item.link}
key={index}
title={item.title}
img={item.img}
skills={item.description}
available={item.available}
/>
);
})}
</div>
2023-04-04 19:07:19 +03:00
</div>
2023-05-24 13:49:09 +03:00
</div>
2024-01-16 21:29:24 +03:00
<ModalResetPassword active={modalResetOpen} setActive={setModalReset} />
2023-05-24 13:49:09 +03:00
<SideBar />
<Footer />
</div>
);
2023-04-04 19:07:19 +03:00
};