Skip to content

Commit e7a456e

Browse files
committed
feat(frontend): redesign 404 page
1 parent 3e3cc52 commit e7a456e

File tree

5 files changed

+50
-13
lines changed

5 files changed

+50
-13
lines changed

frontend/package.json

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -22,46 +22,47 @@
2222
"format": "prettier --write src/"
2323
},
2424
"dependencies": {
25-
"vue": "^3.5.13",
26-
"vue-router": "^4.5.0",
27-
"pinia": "^2.2.6",
2825
"@iconify/vue": "^4.1.2",
26+
"@untitledui-icons/vue": "^1.0.3",
2927
"@vueuse/core": "^10.11.1",
3028
"copy-to-clipboard": "^3.3.3",
3129
"normalize.css": "^8.0.1",
30+
"pinia": "^2.2.6",
3231
"postcss-uncss": "^0.17.0",
3332
"query-string": "^8.2.0",
3433
"set-interval-async": "^3.0.3",
3534
"uncss": "^0.17.3",
3635
"unplugin-vue-router": "^0.10.9",
3736
"v-click-outside": "^3.2.0",
37+
"vue": "^3.5.13",
3838
"vue-i18n": "^9.14.2",
39+
"vue-router": "^4.5.0",
3940
"vue-template-compiler": "^2.7.16"
4041
},
4142
"devDependencies": {
42-
"@tsconfig/node22": "^22.0.0",
43-
"@types/node": "^22.9.3",
44-
"@vitejs/plugin-vue": "^5.2.1",
45-
"@vitejs/plugin-vue-jsx": "^4.1.1",
46-
"@vue/tsconfig": "^0.7.0",
4743
"@intlify/unplugin-vue-i18n": "^1.6.0",
4844
"@plugin-web-update-notification/vite": "^1.7.1",
4945
"@rushstack/eslint-patch": "^1.10.4",
5046
"@trivago/prettier-plugin-sort-imports": "^4.3.0",
47+
"@tsconfig/node22": "^22.0.0",
48+
"@types/node": "^22.9.3",
49+
"@vitejs/plugin-vue": "^5.2.1",
50+
"@vitejs/plugin-vue-jsx": "^4.1.1",
5151
"@vue/eslint-config-prettier": "^10.1.0",
5252
"@vue/eslint-config-typescript": "^14.1.3",
5353
"@vue/runtime-dom": "^3.5.13",
54+
"@vue/tsconfig": "^0.7.0",
5455
"autoprefixer": "^10.4.20",
5556
"eslint": "^9.16.0",
5657
"eslint-config-prettier": "^9.1.0",
5758
"eslint-plugin-vue": "^9.32.0",
5859
"naive-ui": "^2.40.3",
60+
"npm-run-all2": "^7.0.1",
5961
"postcss": "^8.4.49",
6062
"prettier": "^3.4.2",
6163
"sass": "^1.82.0",
6264
"typescript": "~5.6.3",
6365
"unplugin-vue-components": "^0.25.2",
64-
"npm-run-all2": "^7.0.1",
6566
"vite": "^6.0.1",
6667
"vite-plugin-vue-devtools": "^7.6.5",
6768
"vue-tsc": "^2.1.10"

frontend/public/404.png

5.42 KB
Loading

frontend/src/App.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ router.isReady().finally(() => {
1414
</script>
1515

1616
<template>
17-
<Highlights />
17+
<Highlights v-if="!$route.meta.hideHighlight" />
1818
<div v-if="!isRouterReady" class="app-loader">
1919
<IconLoading />
2020
</div>

frontend/src/router/index.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ const router = createRouter({
2727
{
2828
path: '/:pathMatch(.*)*',
2929
component: () => import('@/views/PageNotFoundView.vue'),
30+
meta: { hideHighlight: true },
3031
},
3132
],
3233
})
Lines changed: 38 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,48 @@
1-
<script setup lang="ts"></script>
1+
<script setup lang="ts">
2+
import UiButton from "@/components/ui/uiButton.vue";
3+
import { ArrowLeftIcon } from '@untitledui-icons/vue/solid'
4+
</script>
25

36
<template>
47
<main>
58
<div class="main__body">
69
<div class="main__container">
7-
<h1>Page not found :(</h1>
10+
<img class="s404" src="/404.png" alt="">
11+
<h1 class="title">Whooops, this page is gone</h1>
12+
<p class="subtitle">This page is missing or you wrote the link incorrectly.</p>
813
</div>
14+
<ui-button @click="$router.push('/')"><ArrowLeftIcon class="arrow-icon"/>Back to home</ui-button>
915
</div>
1016
</main>
1117
</template>
1218

13-
<style scoped></style>
19+
<style lang="scss" scoped>
20+
.s404 {
21+
filter: drop-shadow(0 0 100px #FF0016);
22+
width: 100%;
23+
margin-bottom: 20px;
24+
}
25+
26+
.title {
27+
margin: 0;
28+
font-weight: bold;
29+
font-size: 34px;
30+
}
31+
32+
.subtitle {
33+
margin: 0;
34+
font-weight: 300;
35+
font-size: 15px;
36+
color: #9F9F9F;
37+
position: relative;
38+
top: -20px;
39+
}
40+
41+
svg {
42+
width: 15px;
43+
}
44+
45+
button {
46+
margin-top: 15%;
47+
}
48+
</style>

0 commit comments

Comments
 (0)