Extensions.js 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147
  1. import React from 'react';
  2. import styled from 'styled-components';
  3. import SVG from 'react-inlinesvg';
  4. const Section = styled.div`
  5. position: relative;
  6. width: 100%;
  7. flex: 0 0 auto;
  8. display: flex;
  9. flex-direction: column;
  10. align-items: center;
  11. margin: 0;
  12. padding: 90px 0 100px;
  13. background-color: #282828;
  14. @media only screen and (max-width: 768px) {
  15. margin: 0;
  16. padding: 48px 0 16px;
  17. flex-wrap: wrap;
  18. }
  19. `;
  20. const Wrapper = styled.div`
  21. width: 1200px;
  22. max-width: 100%;
  23. flex: 1 1 auto;
  24. display: flex;
  25. justify-content: center;
  26. @media only screen and (max-width: 1200px) {
  27. flex-wrap: wrap;
  28. }
  29. `;
  30. const Title = styled.h3`
  31. font-size: 28px;
  32. font-weight: 300;
  33. margin: 0 0 60px;
  34. color: #f5f5f5;
  35. @media only screen and (max-width: 768px) {
  36. font-size: 24px;
  37. margin-bottom: 56px;
  38. }
  39. @media only screen and (max-width: 448px) {
  40. font-size: 20px;
  41. margin-bottom: 40px;
  42. }
  43. `;
  44. const Button = styled.button`
  45. display: flex;
  46. align-items: center;
  47. justify-content: center;
  48. margin: 0 16px;
  49. padding: 12px 28px;
  50. font-family: 'Nunito', sans-serif;
  51. background-color: #eee;
  52. border: 1px solid #aaa;
  53. font-size: 14px;
  54. font-weight: bold;
  55. text-decoration: none;
  56. border-radius: 4px;
  57. outline: none;
  58. box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
  59. transition: transform 0.3s ease-out;
  60. cursor: pointer;
  61. @media only screen and (max-width: 768px) {
  62. margin-bottom: 16px;
  63. padding: 8px 16px;
  64. font-size: 12px;
  65. }
  66. > * {
  67. text-decoration: none;
  68. }
  69. :hover {
  70. transform: translateY(-2px);
  71. }
  72. `;
  73. const FirefoxButton = styled(Button)`
  74. color: #e0890f;
  75. `;
  76. const ChromeButton = styled(Button)`
  77. color: #4285f4;
  78. `;
  79. const Link = styled.a`
  80. text-decoration: none;
  81. :visited,
  82. :hover,
  83. :active,
  84. :focus {
  85. text-decoration: none;
  86. }
  87. `;
  88. const Icon = styled(SVG)`
  89. svg {
  90. width: 18px;
  91. height: 18px;
  92. margin-right: 16px;
  93. fill: ${props => props.color || '#333'};
  94. @media only screen and (max-width: 768px) {
  95. width: 13px;
  96. height: 13px;
  97. margin-right: 10px;
  98. }
  99. }
  100. `;
  101. const Extensions = () => (
  102. <Section>
  103. <Title>Browser extensions.</Title>
  104. <Wrapper>
  105. <Link
  106. href="https://chrome.google.com/webstore/detail/kutt/pklakpjfiegjacoppcodencchehlfnpd"
  107. target="_blank"
  108. rel="noopener noreferrer"
  109. >
  110. <ChromeButton>
  111. <Icon src="/images/googlechrome.svg" color="#4285f4" />
  112. <span>Download for Chrome</span>
  113. </ChromeButton>
  114. </Link>
  115. <Link
  116. href="https://addons.mozilla.org/en-US/firefox/addon/kutt/"
  117. target="_blank"
  118. rel="noopener noreferrer"
  119. >
  120. <FirefoxButton>
  121. <Icon src="/images/mozillafirefox.svg" color="#e0890f" />
  122. <span>Download for Firefox</span>
  123. </FirefoxButton>
  124. </Link>
  125. </Wrapper>
  126. </Section>
  127. );
  128. export default Extensions;