diff --git a/src/components/Drawer/src/BasicDrawer.vue b/src/components/Drawer/src/BasicDrawer.vue index fe658ef4b0a378b718c7a2c77b634590b18487e8..980a8cb3f0b7ceb22ffd8cc2abdd4bcb487ab15a 100644 --- a/src/components/Drawer/src/BasicDrawer.vue +++ b/src/components/Drawer/src/BasicDrawer.vue @@ -37,7 +37,6 @@ defineComponent, ref, computed, - watchEffect, watch, unref, nextTick, @@ -135,9 +134,13 @@ return !!unref(getProps)?.loading; }); - watchEffect(() => { - visibleRef.value = props.visible; - }); + watch( + () => props.visible, + (newVal, oldVal) => { + if (newVal != oldVal) visibleRef.value = newVal; + }, + { deep: true } + ); watch( () => visibleRef.value,