-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy patherror.vue
27 lines (23 loc) · 1.57 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
<template>
<div class="flex h-[calc(100vh-80px)] items-center justify-center p-5 w-full bg-white">
<div class="text-center">
<div class="inline-flex rounded-full bg-red-100 p-4">
<div class="rounded-full stroke-red-600 bg-red-200 p-4">
<svg class="w-16 h-16" viewBox="0 0 28 28" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M6 8H6.01M6 16H6.01M6 12H18C20.2091 12 22 10.2091 22 8C22 5.79086 20.2091 4 18 4H6C3.79086 4 2 5.79086 2 8C2 10.2091 3.79086 12 6 12ZM6 12C3.79086 12 2 13.7909 2 16C2 18.2091 3.79086 20 6 20H14" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path><path d="M17 16L22 21M22 16L17 21" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path></svg>
</div>
</div>
<h1 class="mt-5 text-[36px] font-bold text-slate-800 lg:text-[50px]">Oops! {{ error.statusCode }}</h1>
<p class="text-slate-600 mt-5 lg:text-lg">{{ error.message }}</p>
<br>
<button type="button" @click="handleError" class="inline-block px-6 py-2.5 bg-purple-600 text-white font-medium text-xs leading-tight uppercase rounded shadow-md hover:bg-purple-700 hover:shadow-lg focus:bg-purple-700 focus:shadow-lg focus:outline-none focus:ring-0 active:bg-purple-800 active:shadow-lg transition duration-150 ease-in-out">
Back to Home
</button>
</div>
</div>
</template>
<script setup>
defineProps(['error'])
const handleError = () => clearError({redirect: '/'})
</script>
<style scoped>
</style>