-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy patherror.vue
83 lines (73 loc) · 1.87 KB
/
error.vue
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
<script setup lang="ts">
import type { NuxtError } from '#app'
const props = defineProps({
error: Object as () => NuxtError
})
let route = useRoute();
</script>
<template>
<section class="E500" v-if="error?.statusCode === 500">
<div class="container">
<h2>Something went wrong!</h2>
<p>Please take a screenshot of this page and send it to us!</p>
<div v-html="error?.stack" class="stack-trace"></div>
<router-link to="/" class="bank-gothic">Go Home</router-link>
</div>
</section>
<section class="E404" v-else>
<img src="@/assets/images/wrong-side-of-the-tracks.webp" alt="">
<span>All we had to do was follow the damn URL CJ!</span>
<div class="container">
<p>{{route.path}} does not exist!</p>
<router-link to="/" class="bank-gothic">Go Home</router-link>
</div>
</section>
</template>
<style scoped lang="scss">
a {
display: block;
width: fit-content;
font-size: 1.2em;
color: #fff;
}
.E404 {
position: relative;
overflow: hidden;
width: 100%;
height: 100vh;
.container {
padding-top: 530px;
a {
margin: 0 auto;
}
p {
margin: 0 auto 15px;
width: fit-content;
font-size: 1.4em;
}
}
img {
display: block;
width: 1200px;
height: 500px;
object-fit: cover;
border-radius: 5px;
position: absolute;
left: 50%;
transform: translateX(-50%);
user-select: none;
pointer-events: none;
}
span {
position: absolute;
top: 440px;
left: 50%;
font-size: 1.3em;
transform: translateX(-50%);
text-shadow: 2px 2px 0 #000;
width: 100vw;
text-align: center;
user-select: none;
}
}
</style>