import styled from "styled-components"; 
import { Success } from "../Components/Top-level/Response/Success/Success";
import { logout } from "../auth/authService";
import { AiOutlineLogout } from "react-icons/ai"; 

const Container = styled.div`
  position: relative;
`;

const LogoutButton = styled.div`
  display: flex;
  justify-content: flex-end;
  position: relative;
  top:3rem;
  right: 1.5rem;
  color: white;
  font-size: 1.8rem;
  z-index: 1001;
  cursor: pointer;
`;

export const SuccessPage = () => {
  const onLogout = () => {
    logout();
  };

  return (
    <Container>
      <LogoutButton>
        <AiOutlineLogout onClick={onLogout} />
      </LogoutButton>
      <Success />
    </Container>
  );
};
