-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy patherror.vue
91 lines (83 loc) · 2.69 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
84
85
86
87
88
89
90
91
<template>
<div
class="w-full p-5 flex flex-col min-h-screen justify-between items-center"
>
<CustomNav />
<div class="flex flex-col items-center justify-center gap-5">
<header class="flex flex-col items-center justify-center gap-1">
<UIcon
name="i-heroicons-solid-exclamation-circle"
class="text-slate w-20 h-20"
/>
</header>
<div class="flex flex-col items-center justify-center gap-5">
<p
class="bg-gradient-to-r from-#217BFE via-#ac87eb to-#ee4d5d bg-clip-text text-size-6xl text-transparent font-700 tracking-0.2rem"
>
{{ error?.statusCode }}
</p>
<p class="font-700">
{{ error?.message.split(":")[0] }} !
</p>
<div class="flex items-center justify-center gap-5">
<UButton
type="button"
color="white"
variant="solid"
label="Home"
:ui="{
font: 'font-700',
base: 'min-w-max w-25 h-10 justify-self-center items-center justify-center',
icon: { size: { md: 'w-8 h-8' } },
color: {
white: {
solid:
'dark:focus:outline-0 dark:active:outline-0 dark:bg-transparent transition-property-all transition-delay-50 transition-duration-1000 dark:hover:text-#4859f3 ring-1 ring-#FFFFFF0F dark:hover:bg-#FFFFFF0F',
},
},
}"
@click="navigateTo('/')"
/>
<UButton
type="button"
color="white"
variant="solid"
:label="
error?.message.split(':')[0] === 'Unauthorized'
? 'Sign In'
: 'Back'
"
:ui="{
font: 'font-700',
base: 'min-w-max w-25 h-10 justify-self-center items-center justify-center',
icon: { size: { md: 'w-8 h-8' } },
color: {
white: {
solid:
'dark:focus:outline-0 dark:active:outline-0 dark:bg-transparent transition-property-all transition-delay-50 transition-duration-1000 dark:hover:text-#4859f3 ring-1 ring-#FFFFFF0F dark:hover:bg-#FFFFFF0F',
},
},
}"
@click="
error?.message.split(':')[0] === 'Unauthorized'
? navigateTo('/authentication/signin')
: useRouter().back()
"
/>
</div>
</div>
</div>
<CustomFooter />
</div>
</template>
<script setup lang="ts">
defineProps({
error: {
type: Object,
default: null,
},
})
useHead({
title: 'Brainiac | Error',
})
</script>