Add 404 page

This commit is contained in:
Marcus Blättermann 2022-12-20 22:06:08 +01:00
parent eafb8511b6
commit df6c4416f8
No known key found for this signature in database
GPG Key ID: A1E1F04008AC450D

View File

@ -1,15 +1,16 @@
import React from 'react'
import { window } from 'browser-monads'
import classNames from 'classnames'
import Template from '../templates/index'
import { LandingHeader, LandingTitle } from '../components/landing'
import Button from '../components/button'
import { nightly, legacy } from '../../meta/dynamicMeta'
import Template from '../src/templates/index'
import { LandingHeader, LandingTitle } from '../src/components/landing'
import { nightly, legacy } from '../meta/dynamicMeta'
import classes from '../src/styles/button.module.sass'
const page404 = ({ location }) => {
const page404 = () => {
const pageContext = { title: '404 Error', searchExclude: true, isIndex: false }
return (
<Template pageContext={pageContext} location={location}>
<Template {...pageContext}>
<LandingHeader style={{ minHeight: 400 }} nightly={nightly} legacy={legacy}>
<LandingTitle>
Ooops, this page
@ -17,9 +18,12 @@ const page404 = ({ location }) => {
does not exist!
</LandingTitle>
<br />
<Button onClick={() => window.history.go(-1)} variant="tertiary">
<button
onClick={() => window.history.go(-1)}
className={classNames(classes.root, classes.tertiary)}
>
Click here to go back
</Button>
</button>
</LandingHeader>
</Template>
)