This commit is contained in:
Ls
2026-04-28 15:53:43 +08:00
parent 2ef5b079c9
commit 2996fa712c
8 changed files with 37 additions and 17 deletions

View File

@@ -1,13 +1,13 @@
<template>
<router-link :to="url" :class="_class" >
<slot></slot>
</router-link>
<router-link :to="href" :class="_class">
<slot></slot>
</router-link>
</template>
<script setup>
// 1. 定义接收父组件传来的参数 props
const props = defineProps({
// 字段名、类型、默认值
url: String,
_class:String,
href: String,
_class: String,
})
</script>

View File

@@ -1,13 +1,12 @@
<template>
<Transition name="page-loading-fade">
<div v-if="appStore.isLoading" class="page-loading" role="status" aria-live="polite" aria-busy="true">
<div>
<img src="/images/loading.gif" />
</div>
<div>
加载中...
</div>
<div class="gif">
<!-- <van-image round width="6rem" height="8rem" src="/images/logo.png" /> -->
<div style="width: 200px; height: 200px;">
<img src="/images/loading4.gif" />
</div>
</div>
</div>
</Transition>
</template>
@@ -31,12 +30,21 @@ const handleImageError = (): void => {
inset: 0;
z-index: 9999;
display: flex;
align-items: center;
justify-content: center;
padding: 24px;
background: #ffffff;
}
.gif {
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
}
.page-loading__panel {
width: min(100%, 280px);
text-align: center;

View File

@@ -0,0 +1 @@
<template></template>