add ModalAuth
This commit is contained in:
@ -4,6 +4,7 @@ import { Link, NavLink } from "react-router-dom";
|
||||
|
||||
import { BurgerButton } from "@components/BurgerMenu/burgerButton";
|
||||
import { BurgerMenu } from "@components/BurgerMenu/burgerMenu";
|
||||
import ModalAuth from "@components/Modal/ModalAuth/ModalAuth";
|
||||
import ModalRegistration from "@components/Modal/ModalRegistration/ModalRegistration";
|
||||
|
||||
import authIcon from "assets/icons/authIcon.svg";
|
||||
@ -13,11 +14,13 @@ import "./authHeader.scss";
|
||||
export const AuthHeader = () => {
|
||||
const [actionMenu, setActionMenu] = useState(false);
|
||||
const [modalReg, setModalReg] = useState(false);
|
||||
const [modalAuth, setModalAuth] = useState(false);
|
||||
|
||||
return (
|
||||
<div className="auth-header">
|
||||
<BurgerMenu active={actionMenu} />
|
||||
<ModalRegistration active={modalReg} setActive={setModalReg} />
|
||||
<ModalAuth active={modalAuth} setActive={setModalAuth} />
|
||||
<div className="auth-header__navigation">
|
||||
<div className="auth__logo">
|
||||
<div>
|
||||
@ -47,8 +50,14 @@ export const AuthHeader = () => {
|
||||
</ul>
|
||||
</div>
|
||||
<div className="auth__buttons">
|
||||
<button className="signIn">
|
||||
<Link to="/auth">войти</Link>
|
||||
<button
|
||||
className="signIn"
|
||||
onClick={(e) => {
|
||||
e.preventDefault();
|
||||
setModalAuth(true);
|
||||
}}
|
||||
>
|
||||
войти
|
||||
</button>
|
||||
<button
|
||||
className="signUp"
|
||||
|
Reference in New Issue
Block a user