-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathRunLoading.vue
59 lines (52 loc) · 929 Bytes
/
RunLoading.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
<script setup lang="ts">
const loading = ref(true)
onMounted(() => {
setTimeout(() => {
loading.value = false
}, 100)
})
</script>
<template>
<transition name="fade">
<div
v-if="loading"
class="loading"
>
<strong>致力于让 Markdown 编辑更简单</strong>
</div>
</transition>
</template>
<style lang="less" scoped>
.loading {
position: fixed;
top: 0;
left: 0;
z-index: 99999;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
width: 100vw;
height: 100vh;
font-size: 18px;
background-color: hsl(var(--background));
&::before {
content: url('../assets/images/favicon.png');
width: 100px;
height: 100px;
margin-bottom: 26px;
}
}
.fade-enter,
.fade-leave-to {
opacity: 0;
}
.fade-enter-to,
.fade-leave {
opacity: 1;
}
.fade-enter-active,
.fade-leave-active {
transition: opacity 1s;
}
</style>