From 2a59dbfbb37f87757d4179c405f47380d97d0781 Mon Sep 17 00:00:00 2001
From: RuoYi <yzz_ivy@163.com>
Date: 星期二, 05 十一月 2024 12:50:44 +0800
Subject: [PATCH] 校检文件名是否包含特殊字符

---
 src/layout/index.vue |    7 +++++--
 1 files changed, 5 insertions(+), 2 deletions(-)

diff --git a/src/layout/index.vue b/src/layout/index.vue
index 4d04ea0..04c7ef2 100644
--- a/src/layout/index.vue
+++ b/src/layout/index.vue
@@ -9,7 +9,7 @@
       </div>
       <app-main />
       <settings ref="settingRef" />
-    </div> 
+    </div>
   </div>
 </template>
 
@@ -40,10 +40,13 @@
 const { width, height } = useWindowSize();
 const WIDTH = 992; // refer to Bootstrap's responsive design
 
-watchEffect(() => {
+watch(() => device.value, () => {
   if (device.value === 'mobile' && sidebar.value.opened) {
     useAppStore().closeSideBar({ withoutAnimation: false })
   }
+})
+
+watchEffect(() => {
   if (width.value - 1 < WIDTH) {
     useAppStore().toggleDevice('mobile')
     useAppStore().closeSideBar({ withoutAnimation: true })

--
Gitblit v1.9.3