You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
41 lines
699 B
41 lines
699 B
<docs>
|
|
---
|
|
order: 6
|
|
title:
|
|
zh-CN: 预加载的卡片
|
|
en-US: Loading card
|
|
---
|
|
|
|
## zh-CN
|
|
|
|
数据读入前会有文本块样式
|
|
|
|
## en-US
|
|
|
|
Shows a loading indirector while the contents of the card is being featched
|
|
|
|
</docs>
|
|
|
|
<template>
|
|
<a-card :loading="loading" title="Card title">whatever content</a-card>
|
|
<a-button style="margin-top: 16px" @click="handleClick">Toggle loading</a-button>
|
|
</template>
|
|
<script lang="ts">
|
|
import { defineComponent, ref } from 'vue';
|
|
|
|
export default defineComponent({
|
|
setup() {
|
|
const loading = ref(true);
|
|
|
|
const handleClick = () => {
|
|
loading.value = !loading.value;
|
|
};
|
|
|
|
return {
|
|
loading,
|
|
handleClick,
|
|
};
|
|
},
|
|
});
|
|
</script>
|