import React from "react";
import { PageTitleStyled } from "./PageTitle.style";

import UserBtn from "./UserBtn/UserBtn";

import { AuthContext } from "../../context/Auth/AuthContext";
import logo from "../../assets/images/Logo.png";

const PageTitle = () => {
  const [modal, setModal] = React.useState(false);
  const { user } = React.useContext(AuthContext);

  const handleModal = () => {
    setModal(!modal);
  };
  return (
    <PageTitleStyled>
      <h1>PageTitle</h1>
      <UserBtn user={user} img={logo} modal={modal} modalSet={handleModal} />
    </PageTitleStyled>
  );
};

export default PageTitle;

