From 0b4dadfe93a511cb689c1030af181f31dd5dff90 Mon Sep 17 00:00:00 2001 From: Jan Florian Dietrich Date: Thu, 14 Feb 2019 13:52:12 +0100 Subject: [PATCH] feat(#10): give minimal styling to 404 page --- src/components/Layout/index.js | 5 +++ src/components/Menu/index.js | 2 +- src/pages/404.js | 58 +++++++++++++++++++++++++++++++--- 3 files changed, 59 insertions(+), 6 deletions(-) diff --git a/src/components/Layout/index.js b/src/components/Layout/index.js index c98b4b0..952567c 100644 --- a/src/components/Layout/index.js +++ b/src/components/Layout/index.js @@ -45,6 +45,11 @@ export const LayoutComponent = ({ children, albums, location }) => ( name: 'description', content: 'Photography by Jan Florian Dietrich from Berlin, Germany', }, + { + name: 'viewport', + content: + 'width=device-width, initial-scale=1, shrink-to-fit=no,maximum-scale=1', + }, ]} link={[ { diff --git a/src/components/Menu/index.js b/src/components/Menu/index.js index d3bc326..0a1e3ec 100644 --- a/src/components/Menu/index.js +++ b/src/components/Menu/index.js @@ -6,9 +6,9 @@ import styled, { css } from 'styled-components'; import { themeGet } from 'styled-system'; import { albumInfoType } from 'utils/types'; +import { StyledLink } from 'components/'; import { mediaInput, mediaScreen } from '../../theme'; -import { StyledLink } from '../'; const Nav = styled.a` color: ${themeGet('colors.black')}; diff --git a/src/pages/404.js b/src/pages/404.js index 25b9656..3b0c041 100644 --- a/src/pages/404.js +++ b/src/pages/404.js @@ -1,10 +1,58 @@ import React from 'react'; +import styled from 'styled-components'; +import { themeGet } from 'styled-system'; -const NotFoundPage = () => ( -
-

NOT FOUND

-

You just hit a route that doesn't exist... the sadness.

-
+import { Layout, ContentContainer, StyledLink } from 'components/'; +import { locationType } from 'utils/types'; + +import { mediaScreen } from '../theme'; + +const TextContainer = styled(ContentContainer)` + padding: ${themeGet('space.4')}; + padding-top: ${themeGet('space.6')}; + + ${mediaScreen.md` + padding: ${themeGet('space.3')}; + padding-top: ${themeGet('space.6')}; + will-change: scroll-position; + min-height: calc(100vh - 2*${themeGet('space.containerBorderMobile')}); + `}; +`; + +const Headline = styled.h1` + color: ${themeGet('colors.black')}; + font-family: ${themeGet('fonts.headline')}; + font-size: ${themeGet('fontSizes.xl')}; + font-weight: bold + text-transform: uppercase; + margin-bottom: ${themeGet('space.3')}; +`; + +const Text = styled.p` + color: ${themeGet('colors.black')}; + font-family: ${themeGet('fonts.body')}; + font-size: ${themeGet('fontSizes.m')}; +`; + +const NotFoundPage = ({ location }) => ( + + + Not Found + You just hit a route that doesn't exist... the sadness. + + Find some images here + + + ); +NotFoundPage.propTypes = { + location: locationType.isRequired, +}; + export default NotFoundPage;