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. import { Col } from "./Layout";
  8. const Wrapper = styled(Flex).attrs({
  9. width: 1200,
  10. maxWidth: "98%",
  11. alignItems: "center",
  12. margin: "150px 0 0",
  13. flexDirection: ["column", "column", "row"]
  14. })`
  15. animation: ${fadeIn} 0.8s ease-out;
  16. box-sizing: border-box;
  17. a {
  18. text-decoration: none;
  19. }
  20. `;
  21. const Title = styled.h2`
  22. font-size: 28px;
  23. font-weight: 300;
  24. padding-right: 32px;
  25. margin-bottom: 48px;
  26. @media only screen and (max-width: 768px) {
  27. font-size: 22px;
  28. text-align: center;
  29. padding-right: 0;
  30. margin-bottom: 32px;
  31. padding: 0 40px;
  32. }
  33. @media only screen and (max-width: 448px) {
  34. font-size: 18px;
  35. text-align: center;
  36. margin-bottom: 24px;
  37. }
  38. `;
  39. const Image = styled.img`
  40. flex: 0 0 60%;
  41. width: 60%;
  42. max-width: 100%;
  43. height: auto;
  44. @media only screen and (max-width: 768px) {
  45. flex-basis: 100%;
  46. width: 100%;
  47. }
  48. `;
  49. const NeedToLogin = () => (
  50. <Wrapper>
  51. <Col
  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. </Col>
  65. <Image src="/images/callout.png" />
  66. </Wrapper>
  67. );
  68. export default NeedToLogin;