mirror of
https://github.com/fantastic-admin/basic.git
synced 2026-10-06 12:03:02 +08:00
fix: 修复 Drawer 和 Modal 组件的 isClosed 状态初始化逻辑
This commit is contained in:
@@ -63,7 +63,7 @@ watch(() => props.modelValue, (newValue) => {
|
||||
})
|
||||
|
||||
const hasOpened = ref(false)
|
||||
const isClosed = ref(true)
|
||||
const isClosed = ref(!props.modelValue)
|
||||
|
||||
watch(isOpen, (val) => {
|
||||
emits('update:modelValue', val)
|
||||
|
||||
@@ -71,7 +71,7 @@ watch(() => props.modelValue, (newValue) => {
|
||||
})
|
||||
|
||||
const hasOpened = ref(false)
|
||||
const isClosed = ref(true)
|
||||
const isClosed = ref(!props.modelValue)
|
||||
|
||||
watch(isOpen, (val) => {
|
||||
emits('update:modelValue', val)
|
||||
|
||||
Reference in New Issue
Block a user