md/src/components/RunLoading.vue

60 lines
929 B
Vue
Raw Normal View History

2024-09-17 08:26:52 +08:00
<script setup lang="ts">
2024-08-18 19:49:16 +08:00
const loading = ref(true)
onMounted(() => {
setTimeout(() => {
loading.value = false
}, 100)
})
</script>
2020-02-11 17:51:04 +08:00
<template>
2024-08-18 19:49:16 +08:00
<transition name="fade">
<div
2024-08-18 19:49:16 +08:00
v-if="loading"
class="loading"
>
<strong>致力于让 Markdown 编辑更简单</strong>
2020-02-11 17:51:04 +08:00
</div>
</transition>
2020-02-11 17:51:04 +08:00
</template>
2020-07-13 21:13:46 +08:00
<style lang="less" scoped>
2020-07-04 00:48:27 +08:00
.loading {
position: fixed;
2024-08-18 19:49:16 +08:00
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;
2024-12-15 20:15:06 +08:00
background-color: hsl(var(--background));
2020-07-04 00:48:27 +08:00
&::before {
content: url('../assets/images/favicon.png');
width: 100px;
height: 100px;
margin-bottom: 26px;
}
2020-07-04 00:48:27 +08:00
}
.fade-enter,
.fade-leave-to {
opacity: 0;
}
.fade-enter-to,
.fade-leave {
opacity: 1;
}
.fade-enter-active,
.fade-leave-active {
transition: opacity 1s;
}
2020-02-11 17:51:04 +08:00
</style>