-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy patherror.vue
More file actions
26 lines (24 loc) · 806 Bytes
/
error.vue
File metadata and controls
26 lines (24 loc) · 806 Bytes
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
<script setup>
const props = defineProps({
error: Object
})
const handleError = () => {
clearError({ redirect: '/' })
}
</script>
<template>
<div class="min-h-screen flex items-center justify-center">
<div class="text-center px-4">
<h1 class="text-9xl font-bold text-primary-500 mb-4">{{ error?.statusCode || '404' }}</h1>
<h2 class="text-3xl font-bold font-display mb-6">
{{ error?.statusCode === 404 ? 'Page Not Found' : 'Something went wrong' }}
</h2>
<p class="text-white/80 max-w-md mx-auto mb-8">
{{ error?.statusMessage || 'The page you\'re looking for doesn\'t exist or has been moved to another URL.' }}
</p>
<button @click="handleError" class="btn btn-primary">
Return to Home
</button>
</div>
</div>
</template>