Files
2026-10-07 22:01:17 +08:00

21 lines
484 B
Vue
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
<script setup lang="ts">
import { ref } from 'vue'
import { G3Button } from '@g3soft/ui'
const loading = ref(false)
function handleAsync() {
if (loading.value) return
loading.value = true
setTimeout(() => {
loading.value = false
}, 1500)
}
</script>
<template>
<G3Button type="primary" :loading="loading" @click="handleAsync">点击加载</G3Button>
<G3Button disabled>禁用</G3Button>
<G3Button type="primary" disabled>禁用(主要)</G3Button>
</template>