index.tsx 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. import React from "react";
  2. import { useRouter } from "next/router";
  3. import styled from "styled-components";
  4. import { Button } from "src/components/Button";
  5. import { Image } from "src/components/Image";
  6. const StyledNotFound = styled.div`
  7. display: flex;
  8. justify-content: center;
  9. align-items: center;
  10. flex-direction: column;
  11. margin-top: 0 40px;
  12. text-align: center;
  13. `;
  14. const StyledMessage = styled.h4`
  15. color: ${({ theme }) => theme.FULL_WHITE};
  16. font-size: 25px;
  17. font-weight: 700;
  18. margin: 10px 0;
  19. `;
  20. const StyledSubMessage = styled.div`
  21. width: 50%;
  22. color: ${({ theme }) => theme.SILVER};
  23. margin-bottom: 25px;
  24. `;
  25. const StyledImageWrapper = styled.div`
  26. width: 300px;
  27. `;
  28. const NotFound: React.FC = () => {
  29. const router = useRouter();
  30. return (
  31. <StyledNotFound>
  32. <StyledImageWrapper>
  33. <Image src="/404.svg" alt="404" width={300} height={400} />
  34. </StyledImageWrapper>
  35. <StyledMessage>WIZARDS BEHIND CURTAINS?</StyledMessage>
  36. <StyledSubMessage>
  37. Looks like you&apos;re lost, let&apos;s head back to the home!
  38. </StyledSubMessage>
  39. <Button type="button" onClick={() => router.push("/")}>
  40. Go Home
  41. </Button>
  42. </StyledNotFound>
  43. );
  44. };
  45. export default NotFound;