add: guard in router

This commit is contained in:
Alexandro Uc Santos
2023-11-24 21:07:42 -06:00
parent afa8e1983b
commit ec02b98272
18 changed files with 914 additions and 47 deletions

View File

@@ -0,0 +1,50 @@
<script setup>
import { useAuthStore } from '../../stores/auth';
const auth = useAuthStore();
</script>
<template>
<div class="noty-fixed" v-if="auth.checking">
<div class="content-noty">
<div class="body">
<img src="/images/logo.png" alt="logo" class="logo animate__animated animate__rubberBand">
<h2>Cargando...</h2>
</div>
</div>
</div>
</template>
<style scoped>
.noty-fixed {
position: fixed;
right: 0px;
top: 0px;
left: 0px;
bottom: 0px;
}
.content-noty {
width: 100vw;
height: 100vh;
padding: 16px 32px;
background-color: #FFF;
/* opacity: 0.9; */
}
.body {
height: 100%;
display: flex;
flex-direction: column;
align-items: center;
align-content: center;
margin: 0 auto;
gap: 5rem;
/* align-content: center; */
justify-content: center;
}
.logo {
width: 240px;
}
</style>