fix: 修复 Drawer 和 Modal 组件的 isClosed 状态初始化逻辑

This commit is contained in:
Hooray
2026-05-28 13:27:43 +08:00
parent eb4538c753
commit 2646930feb
2 changed files with 2 additions and 2 deletions
@@ -63,7 +63,7 @@ watch(() => props.modelValue, (newValue) => {
}) })
const hasOpened = ref(false) const hasOpened = ref(false)
const isClosed = ref(true) const isClosed = ref(!props.modelValue)
watch(isOpen, (val) => { watch(isOpen, (val) => {
emits('update:modelValue', val) emits('update:modelValue', val)
@@ -71,7 +71,7 @@ watch(() => props.modelValue, (newValue) => {
}) })
const hasOpened = ref(false) const hasOpened = ref(false)
const isClosed = ref(true) const isClosed = ref(!props.modelValue)
watch(isOpen, (val) => { watch(isOpen, (val) => {
emits('update:modelValue', val) emits('update:modelValue', val)