组件
区块锁定 Block Ui
BlockUI:加载遮罩。遮住需要等待的区域,保持其形状,在半透明磨砂效果下变暗,并用一个低调的加载指示提示等待。状态由调用方管理,遮罩只负责响应。
#基础用法
Invoices settle every quarter. The ledger holds its shape while the curtain is drawn.
<script setup lang="ts">
import { BlockUI, Button } from "@bysages/vue";
import { ref } from "vue";
const blocked = ref(true);
</script>
<template>
<div class="flex w-96 flex-col gap-4">
<Button size="sm" variant="outline" @click="blocked = !blocked">
{{ blocked ? "Lift the curtain" : "Draw the curtain" }}
</Button>
<BlockUI :blocked="blocked">
<div class="rounded-md border border-border p-6 text-sm text-secondary">
Invoices settle every quarter. The ledger holds its shape while the curtain is drawn.
</div>
</BlockUI>
</div>
</template>
#属性
#BlockUI
BlockUI:加载遮罩。遮住需要等待的区域,保持其形状,在半透明磨砂效果下变暗,并用一个低调的加载指示提示等待。状态由调用方管理,遮罩只负责响应。
| 属性 | 类型 | 默认值 | 描述 |
|---|---|---|---|
blocked | Boolean | false | 是否显示阻塞遮罩 |