From 35d0723436a0e9a1e2c7f53ca97d2a2322e4f444 Mon Sep 17 00:00:00 2001 From: ZiuChen <457353192@qq.com> Date: Tue, 16 Aug 2022 12:23:41 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20Tab=E5=88=87=E6=8D=A2=E5=AF=BC=E8=88=AA?= =?UTF-8?q?=E5=A4=B1=E6=95=88?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/Main.vue | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/views/Main.vue b/src/views/Main.vue index a64df65..b2f4243 100644 --- a/src/views/Main.vue +++ b/src/views/Main.vue @@ -88,6 +88,7 @@ const ClipSwitchRef = ref() onMounted(() => { // 获取挂载的导航组件 Ref const activeTab = computed(() => ClipSwitchRef.value.activeTab) + const toggleNav = ClipSwitchRef.value.toggleNav // 初始化数据 list.value = window.db.dataBase.data @@ -141,7 +142,8 @@ onMounted(() => { const list = ['all', 'text', 'image', 'file'] const index = list.indexOf(activeTab.value) const target = index === list.length - 1 ? list[0] : list[index + 1] - updateShowList(target) + toggleNav(target) + updateShowList(activeTab.value) } else if (isSearch) { window.focus() } else if (isExit) {