Skip to content

Commit eec4f34

Browse files
committed
added custom 404 page
1 parent 9b842c6 commit eec4f34

File tree

3 files changed

+44
-1
lines changed

3 files changed

+44
-1
lines changed
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
import React from 'react';
2+
import ContactStyle from '../styles/Contact';
3+
import HeroText from '../styles/HeroText';
4+
import MainContainer from '../styles/MainContainer';
5+
import { Link } from 'gatsby';
6+
7+
const NotFoundComponent = () => {
8+
return (
9+
<MainContainer>
10+
<ContactStyle>
11+
<div className={'content upper-content-section'}>
12+
<HeroText className={'main-part'}>Not found </HeroText>
13+
<hr className={'contact-page-line'}></hr>
14+
</div>
15+
<div className={'content lower-content-section'}>
16+
<p>No page found at this url.</p>
17+
<p>
18+
{' '}
19+
Please got back to the <Link to="/">homepage.</Link>
20+
</p>
21+
</div>
22+
</ContactStyle>
23+
</MainContainer>
24+
);
25+
};
26+
27+
export default NotFoundComponent;

src/pages/404.js

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
import React from 'react';
2+
import Layout from '../components/Layout/Layout';
3+
import NotFoundComponent from '../components/NotFoundComponent';
4+
import Seo from '../components/Seo/Seo';
5+
6+
const NotFound = () => {
7+
return (
8+
<Layout>
9+
<Seo title="Not found" />
10+
<NotFoundComponent />
11+
</Layout>
12+
);
13+
};
14+
15+
export default NotFound;

src/styles/Contact.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,8 @@ const Contact = styled(StandardGrid)`
137137
138138
@media (min-width: 1440px) {
139139
margin-bottom: 80px;
140-
margin-top: 80px;
140+
margin-top: 100px;
141+
min-height: 38vh;
141142
margin-right: 0px;
142143
143144
.main-part {

0 commit comments

Comments
 (0)