Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement 404 page as in the API docs #1391

Merged
merged 2 commits into from
Jul 24, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 30 additions & 0 deletions app/styles/app.scss
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,36 @@ table {
padding: 2rem;
}

// 404 styling
.whoops {
display: flex;
justify-content: center;
align-items: center;
padding: var(--spacing-6)
}

.whoops img {
width: 240px;
margin: var(--spacing-2);
}

@media (max-width: 450px) {
.whoops {
flex-direction: column;
padding: var(--spacing-3);
}

.whoops img {
width: 80%;
margin: var(--spacing-4);
}

.whoops__message {
margin: var(--spacing-2);
text-align: center;
}
}

// override ember-styleguide. Needed to contain code blocks.
.main {
grid-area: main;
Expand Down
9 changes: 9 additions & 0 deletions app/templates/error.hbs
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{{page-title "Page Not Found"}}

<article class="whoops">
<img src="/images/stinky-fish.png" alt="tomster stinky fish"/>
<div class="whoops__message">
<h2>Ack! 404 friend, you're in the wrong place</h2>
<LinkTo @route='index'>Click here to go home</LinkTo>
</div>
</article>
1 change: 1 addition & 0 deletions public/_redirects
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
/* /index.html 200
Binary file added public/images/stinky-fish.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.