forked from hlxsites/bitdefender
-
Notifications
You must be signed in to change notification settings - Fork 0
/
404.html
154 lines (132 loc) · 3.58 KB
/
404.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
<!DOCTYPE html>
<html>
<head>
<title>Page not found</title>
<script type="text/javascript">
window.isErrorPage = true;
window.errorCode = '404';
</script>
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta property="og:title" content="Page not found">
<script src="/scripts/scripts.js" type="module" crossorigin="use-credentials"></script>
<script type="module">
import { decorateButtons, sampleRUM } from '/scripts/lib-franklin.js';
window.addEventListener('load', async () => {
const response = await fetch('/404.plain.html');
if (response.ok) {
const htmlContent = await response.text();
const specialSection = document.querySelector('.link-section');
specialSection.innerHTML = htmlContent;
decorateButtons(specialSection);
}
sampleRUM('404', { source: document.referrer, target: window.location.href });
});
</script>
<link rel="stylesheet" href="/styles/styles.css">
<style>
:root {
--fourofour-background-color: #f4f4f4;
}
main.error {
min-height: calc(100vh - var(--nav-height));
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
}
.error .section .default-content-wrapper {
display: flex;
flex-direction: column;
align-items: center;
text-align: center;
}
.error-number {
width: 20vw;
}
.error .default-content-wrapper {
width: fit-content;
margin: 0 auto;
width: 50vw;
}
.default-content-wrapper p {
font-size: var(--body-font-size-l);
text-align: center;
}
main.error .error-number text {
font-size: var(--heading-font-size-m);
font-family: var(--fixed-font-family);
font-weight: var(--font-weight-bold);
}
/* Default styles (mobile-first) */
main .link-section {
display: flex;
flex-direction: column;
align-items: center;
width: 90%; /* Adjusted to fit smaller screens */
padding: 30px;
margin: 0 auto;
border-radius: 12px;
background-color: var(--fourofour-background-color);
}
.link-section > div:first-child > p {
font-size: var(--body-font-size-xs);
font-weight: var(--font-weight-bold);
color: var(--color-dark-gray);
text-align: center;
text-decoration: none;
}
.link-section > div:last-child {
margin-top: 1rem;
column-count: 1;
width: 100%;
display: flex;
flex-direction: column;
align-items: center;
}
.link-section > div:last-child .button-container {
margin-bottom: 1rem;
margin-top: 0;
}
.link-section > div:last-child .button-container a {
background-color: transparent;
border: none;
color: var(--link-color);
padding: 0;
padding-left: 10px;
text-align: center;
}
.link-section > div:last-child .button-container a::after {
background-color: var(--link-color);
opacity: 1;
margin: 0;
}
@media (min-width: 992px) {
main .link-section {
width: 50vw;
max-width: 650px;
}
.link-section > div:last-child {
column-count: 2;
display: block;
align-items: initial;
}
}
</style>
<link rel="stylesheet" href="/styles/lazy-styles.css">
</head>
<body>
<header></header>
<main class="error">
<div class="section">
<svg viewBox="1 0 38 18" class="error-number">
<text x="0" y="17">404</text>
</svg>
<h2 class="error-message">Page Not Found</h2>
<p>The page you are looking for might have been removed, had its name changed, or is temporarily unavailable.</p>
</div>
<div class="link-section">
</div>
</main>
<footer></footer>
</body>
</html>