NeedToLogin.tsx 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778
  1. import React from "react";
  2. import Link from "next/link";
  3. import styled from "styled-components";
  4. import { Flex } from "reflexbox/styled-components";
  5. import { Button } from "./Button";
  6. import { fadeIn } from "../helpers/animations";
  7. const Wrapper = styled(Flex).attrs({
  8. width: 1200,
  9. maxWidth: "98%",
  10. alignItems: "center",
  11. margin: "16px 0 0",
  12. flexDirection: ["column", "column", "row"]
  13. })`
  14. animation: ${fadeIn} 0.8s ease-out;
  15. box-sizing: border-box;
  16. a {
  17. text-decoration: none;
  18. }
  19. `;
  20. const Title = styled.h2`
  21. font-size: 28px;
  22. font-weight: 300;
  23. padding-right: 32px;
  24. margin-bottom: 48px;
  25. @media only screen and (max-width: 768px) {
  26. font-size: 22px;
  27. text-align: center;
  28. padding-right: 0;
  29. margin-bottom: 32px;
  30. padding: 0 40px;
  31. }
  32. @media only screen and (max-width: 448px) {
  33. font-size: 18px;
  34. text-align: center;
  35. margin-bottom: 24px;
  36. }
  37. `;
  38. const Image = styled.img`
  39. flex: 0 0 60%;
  40. width: 60%;
  41. max-width: 100%;
  42. height: auto;
  43. @media only screen and (max-width: 768px) {
  44. flex-basis: 100%;
  45. width: 100%;
  46. }
  47. `;
  48. const NeedToLogin = () => (
  49. <Wrapper>
  50. <Flex
  51. flexDirection="column"
  52. alignItems={["center", "center", "flex-start"]}
  53. mt={-32}
  54. mb={[32, 32, 0]}
  55. >
  56. <Title>
  57. Manage links, set custom <b>domains</b> and view <b>stats</b>.
  58. </Title>
  59. <Link href="/login">
  60. <a href="/login" title="login / signup">
  61. <Button>Login / Signup</Button>
  62. </a>
  63. </Link>
  64. </Flex>
  65. <Image src="/images/callout.png" />
  66. </Wrapper>
  67. );
  68. export default NeedToLogin;