31 lines
715 B
Vue
31 lines
715 B
Vue
<script setup lang="ts">
|
||
import {
|
||
CheckboxContent,
|
||
CheckboxControl,
|
||
CheckboxIndicator,
|
||
Checkbox,
|
||
} from "@heroui-vue/components";
|
||
import { ref } from "vue";
|
||
const isSelected = ref(true);
|
||
</script>
|
||
<template>
|
||
<div class="flex flex-col gap-3">
|
||
<Checkbox
|
||
id="email-notifications"
|
||
:is-selected="isSelected"
|
||
@update:checked="isSelected = $event"
|
||
>
|
||
<CheckboxContent>
|
||
<CheckboxControl>
|
||
<CheckboxIndicator />
|
||
</CheckboxControl>
|
||
邮件通知
|
||
</CheckboxContent>
|
||
</Checkbox>
|
||
<p class="text-sm text-muted">
|
||
状态:
|
||
<span class="font-medium">{{ isSelected ? "已勾选" : "未勾选" }}</span>
|
||
</p>
|
||
</div>
|
||
</template>
|