fix: 完成首页静态展示内容

This commit is contained in:
MTrun
2021-12-19 19:19:46 +08:00
parent c1daa231b6
commit f37ed1f3d3
29 changed files with 565 additions and 138 deletions
+3
View File
@@ -0,0 +1,3 @@
import Skeleton from './index.vue';
export { Skeleton };
+29
View File
@@ -0,0 +1,29 @@
<template>
<div v-show="load">
<div v-show="repeat == 1">
<n-skeleton v-bind="$attrs" />
</div>
<div v-show="repeat == 2">
<n-skeleton v-bind="$attrs" />
<n-skeleton v-bind="$attrs" style="width: 60%;" />
</div>
<div v-show="repeat > 2">
<n-skeleton v-bind="$attrs" :repeat="repeat - 2" />
<n-skeleton v-bind="$attrs" style="width: 60%;" />
<n-skeleton v-bind="$attrs" style="width: 50%;" />
</div>
</div>
</template>
<script lang="ts" setup>
defineProps({
repeat: {
type: Number,
default: 1
},
load: {
type: Boolean,
default: true
}
})
</script>