Skip to content

Commit 7f9cf63

Browse files
authored
Merge pull request #495 from GSA-TTS/np/LG-11971/404-page
Add 404 page borrowed from brochure site
2 parents 497aad7 + c513f1a commit 7f9cf63

File tree

4 files changed

+146
-0
lines changed

4 files changed

+146
-0
lines changed

_layouts/not_found.html

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
<!DOCTYPE html>
2+
3+
<html lang="en" class="not-found">
4+
<head>
5+
{% include google_analytics.html %}
6+
{% include osc_analytics.html %}
7+
{% include dap.html %}
8+
<meta charset="utf-8">
9+
<meta http-equiv="X-UA-Compatible" content="IE=edge">
10+
11+
<meta name="HandheldFriendly" content="True">
12+
<meta name="MobileOptimized" content="320">
13+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
14+
15+
{% capture title -%}
16+
{% if page.title %}{{ page.title }} | {{ site.title }}{% else %}{{ site.title }}{% endif -%}
17+
{% endcapture -%}
18+
19+
<title>{{ title }}</title>
20+
<meta property="og:title" content="{{ title }}">
21+
22+
{% if page.lead -%}
23+
<meta name="description" content="{{ page.lead | markdownify | strip_html | strip }}">
24+
<meta property="og:description" content="{{ page.lead | markdownify | strip_html | strip }}">
25+
{% endif -%}
26+
27+
<meta name="twitter:card" value="summary">
28+
<meta property="og:type" content="article">
29+
30+
<link rel="shortcut icon" type="image/ico" href="{{ site.baseurl }}/assets/img/favicons/favicon.ico">
31+
<link rel="stylesheet" href="{{ site.baseurl }}/assets/css/main.css">
32+
</head>
33+
34+
<body class="not-found">
35+
{{ content }}
36+
</body>
37+
</html>

_pages/404.md

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
---
2+
layout: not_found
3+
title: This page is no longer available.
4+
permalink: /404.html
5+
sitemap: false
6+
---
7+
8+
<main class="site-wrapper">
9+
<div class="site-wrapper-inner">
10+
<div class="cover-container">
11+
<div class="masthead clearfix">
12+
<div class="inner">
13+
<a href="/"><img src="{{ '/assets/img/logo-white.svg' | prepend: site.baseurl}}" width="150" alt="Login.gov logo" class='masthead-brand'/></a>
14+
</div>
15+
</div>
16+
<div class="inner cover">
17+
<h1>
18+
The page you are looking for may have moved or is no longer available.
19+
</h1>
20+
<p>
21+
Please check the URL.
22+
</p>
23+
<p>
24+
Here are some links that might be helpful:
25+
</p>
26+
</div>
27+
<ul>
28+
<li><a href="{{ site.baseurl }}/">Home</a></li>
29+
<li><a href="{{ site.baseurl }}/support/">Support</a></li>
30+
</ul>
31+
</div>
32+
</div>
33+
</main>

assets/scss/_not_found.scss

Lines changed: 75 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,75 @@
1+
html.not-found {
2+
height: 100%;
3+
}
4+
5+
body.not-found {
6+
color: #fff;
7+
text-align: center;
8+
height: 100%;
9+
10+
main {
11+
background-color: #112e51;
12+
}
13+
14+
a,
15+
a:focus,
16+
a:hover {
17+
color: #fff;
18+
}
19+
20+
.site-wrapper {
21+
height: 100%;
22+
min-height: 100%;
23+
width: 100%;
24+
display: table;
25+
}
26+
27+
.site-wrapper-inner {
28+
display: table-cell;
29+
vertical-align: middle;
30+
}
31+
32+
.cover-container {
33+
margin: auto;
34+
max-width: 600px;
35+
}
36+
37+
.inner {
38+
padding: 0 30px;
39+
}
40+
41+
.cover {
42+
padding: 0 20px;
43+
}
44+
45+
.masthead-brand {
46+
margin-top: 10px;
47+
}
48+
49+
ul {
50+
padding: 0;
51+
}
52+
53+
li {
54+
display: inline;
55+
margin: 20px;
56+
}
57+
58+
h1 {
59+
margin-top: 32px;
60+
margin-bottom: 24px;
61+
}
62+
63+
@media (min-width: 768px) {
64+
.cover-container {
65+
width: 100%;
66+
}
67+
}
68+
69+
@media (min-width: 992px) {
70+
.cover-container {
71+
width: 720px;
72+
}
73+
}
74+
}
75+

assets/scss/main.css.scss

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
);
1515
@forward "uswds";
1616
@forward "footer";
17+
@forward "not_found";
1718

1819
$block-background-color: #fafafa;
1920

0 commit comments

Comments
 (0)