Skip to content

Commit 37f716c

Browse files
committed
Update 404.html
1 parent 43a2746 commit 37f716c

1 file changed

Lines changed: 95 additions & 57 deletions

File tree

404.html

Lines changed: 95 additions & 57 deletions
Original file line numberDiff line numberDiff line change
@@ -6,32 +6,48 @@
66

77
<style>
88
.error-container {
9-
max-width: 800px;
9+
max-width: 1200px;
1010
margin: 2rem auto;
1111
padding: 2rem;
12-
text-align: center;
1312
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
1413
}
15-
14+
15+
.error-layout {
16+
display: flex;
17+
gap: 2rem;
18+
align-items: start;
19+
}
20+
21+
.error-content {
22+
flex: 2;
23+
text-align: center;
24+
}
25+
26+
.error-image-wrapper {
27+
flex: 1 1 200px;
28+
display: flex;
29+
align-items: center;
30+
justify-content: center;
31+
}
32+
1633
.error-image {
17-
max-width: 300px;
18-
margin: 2rem auto;
19-
display: block;
34+
max-width: 100%;
35+
height: auto;
2036
}
21-
37+
2238
.error-title {
2339
color: #d63031;
2440
font-size: 2rem;
2541
margin-bottom: 1rem;
2642
}
27-
43+
2844
.error-message {
2945
color: #2d3436;
3046
font-size: 1.1rem;
3147
line-height: 1.6;
3248
margin-bottom: 1.5rem;
3349
}
34-
50+
3551
.suggested-link {
3652
background-color: #00b894;
3753
color: white;
@@ -43,102 +59,124 @@
4359
font-weight: bold;
4460
transition: background-color 0.3s;
4561
}
46-
62+
4763
.suggested-link:hover {
4864
background-color: #00a383;
4965
}
50-
66+
5167
.recommendation {
5268
background-color: #fff3cd;
5369
border-left: 4px solid #ffc107;
5470
padding: 1rem;
5571
margin: 2rem 0;
5672
text-align: left;
5773
}
58-
74+
5975
.navigation-section {
60-
margin-top: 3rem;
76+
margin-top: 2rem;
6177
padding: 2rem;
6278
background-color: #f8f9fa;
6379
border-radius: 8px;
6480
}
65-
81+
6682
.navigation-section h2 {
6783
color: #2d3436;
6884
margin-bottom: 1rem;
6985
}
70-
86+
7187
.nav-links {
7288
display: grid;
7389
grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
7490
gap: 0.5rem;
7591
margin-top: 1rem;
7692
}
77-
93+
7894
.nav-link {
7995
color: #0984e3;
8096
text-decoration: none;
8197
padding: 0.5rem;
8298
border-radius: 4px;
8399
transition: background-color 0.3s;
84100
}
85-
101+
86102
.nav-link:hover {
87103
background-color: #dfe6e9;
88104
}
89-
105+
90106
.trailing-slash-notice {
91107
display: none;
92108
margin-bottom: 1rem;
93109
}
94-
110+
95111
.trailing-slash-notice.visible {
96112
display: block;
97113
}
114+
115+
@media (max-width: 640px) {
116+
.error-layout {
117+
flex-direction: column-reverse;
118+
}
119+
120+
.error-image-wrapper {
121+
flex: 0 0 auto;
122+
width: 150px;
123+
margin: 0 auto;
124+
}
125+
126+
.nav-links {
127+
grid-template-columns: 1fr;
128+
}
129+
}
98130
</style>
99131

100132
<div class="error-container">
101-
<div class="trailing-slash-notice" id="trailingSlashNotice">
102-
<h1 class="error-title">Almost There!</h1>
103-
<p class="error-message">
104-
It looks like you almost typed the correct address.
105-
<span id="nearMatchReason"></span>
106-
</p>
107-
<p class="error-message">
108-
<strong>What you tried:</strong> <code id="attemptedUrl"></code><br>
109-
<strong>What you probably want:</strong>
110-
</p>
111-
<a href="" id="suggestedLink" class="suggested-link">Go to the correct page</a>
112-
113-
<div class="recommendation">
114-
<strong>💡 Tip:</strong> If you followed a link from another site or used a bookmark,
115-
you may want to update it to the correct URL shown above. This will ensure it works properly in the future.
133+
<div class="error-layout">
134+
<div class="error-content">
135+
<div class="trailing-slash-notice" id="trailingSlashNotice">
136+
<h1 class="error-title">Almost There!</h1>
137+
<p class="error-message">
138+
It looks like you almost typed the correct address.
139+
<span id="nearMatchReason"></span>
140+
</p>
141+
<p class="error-message">
142+
<strong>What you tried:</strong> <code id="attemptedUrl"></code><br>
143+
<strong>What you probably want:</strong>
144+
<a href="" id="suggestedLink" class="suggested-link">Go to the correct page</a>
145+
</p>
146+
147+
<div class="recommendation">
148+
<strong>💡 Tip:</strong> If you followed a link from another site or used a bookmark,
149+
you may want to update it to the correct URL shown above. This will ensure it works properly in the future.
150+
</div>
151+
</div>
152+
153+
<div class="standard-404" id="standard404">
154+
<h1 class="error-title">Page Not Found</h1>
155+
<p class="error-message">
156+
Sorry, we couldn't find the page you're looking for.
157+
</p>
158+
</div>
159+
160+
<div class="navigation-section">
161+
<h2>Helpful Links</h2>
162+
<p>Maybe one of these pages can help you find what you're looking for:</p>
163+
<div class="nav-links">
164+
<a href="/" class="nav-link">🏠 Home</a>
165+
<a href="/profile" class="nav-link">👤 Profile</a>
166+
<a href="/transcribe" class="nav-link">✍️ Transcribe</a>
167+
<a href="/project" class="nav-link">📁 Projects</a>
168+
<a href="/projects/all" class="nav-link">📋 All Projects</a>
169+
<a href="/project/create" class="nav-link">➕ Create Project</a>
170+
<a href="/project/import" class="nav-link">📥 Import Project</a>
171+
<a href="/manage/quicktype" class="nav-link">⚡ Quick Type</a>
172+
</div>
173+
</div>
116174
</div>
117-
</div>
118-
119-
<img src="/assets/images/hopeful404.png" alt="Friendly 404 Error" class="error-image">
120-
121-
<div class="navigation-section">
122-
<h2>Helpful Links</h2>
123-
<p>Maybe one of these pages can help you find what you're looking for:</p>
124-
<div class="nav-links">
125-
<a href="/" class="nav-link">🏠 Home</a>
126-
<a href="/profile" class="nav-link">👤 Profile</a>
127-
<a href="/transcribe" class="nav-link">✍️ Transcribe</a>
128-
<a href="/project" class="nav-link">📁 Projects</a>
129-
<a href="/projects/all" class="nav-link">📋 All Projects</a>
130-
<a href="/project/create" class="nav-link">➕ Create Project</a>
131-
<a href="/project/import" class="nav-link">📥 Import Project</a>
132-
<a href="/manage/quicktype" class="nav-link">⚡ Quick Type</a>
175+
176+
<div class="error-image-wrapper">
177+
<img src="/assets/images/hopeful404.png" alt="Friendly 404 Error" class="error-image">
133178
</div>
134179
</div>
135-
136-
<div class="standard-404" id="standard404">
137-
<h1 class="error-title">Page Not Found</h1>
138-
<p class="error-message">
139-
Sorry, we couldn't find the page you're looking for.
140-
</p>
141-
</div>
142180
</div>
143181

144182
<script>

0 commit comments

Comments
 (0)