From c34cbcb03ddeb4dca3b7f7bd6b1da1b08d8d6ecf Mon Sep 17 00:00:00 2001 From: ray <1490493387@qq.com> Date: Tue, 12 Nov 2024 00:17:53 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20:bug:=20=E7=BB=84=E4=BB=B6=E5=91=BD?= =?UTF-8?q?=E5=90=8D=E8=B0=83=E6=95=B4=E5=BC=95=E5=8F=91=E5=AF=BC=E5=85=A5?= =?UTF-8?q?=E9=97=AE=E9=A2=98=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../NavBar/components/NavbarRight.vue | 9 +++------ src/layout/components/Sidebar/index.vue | 2 +- src/layout/index.vue | 18 +++++------------- 3 files changed, 9 insertions(+), 20 deletions(-) diff --git a/src/layout/components/NavBar/components/NavbarRight.vue b/src/layout/components/NavBar/components/NavbarRight.vue index 224d3f82..c4ad28ac 100644 --- a/src/layout/components/NavBar/components/NavbarRight.vue +++ b/src/layout/components/NavBar/components/NavbarRight.vue @@ -22,10 +22,7 @@ -
+
@@ -36,8 +33,8 @@ import { DeviceEnum } from "@/enums/DeviceEnum"; import { useAppStore, useSettingsStore } from "@/store"; -import UserProfile from "@/layout/components/NavBar/components/UserProfile.vue"; -import Notification from "@/layout/components/NavBar/components/Notification.vue"; +import UserProfile from "./UserProfile.vue"; +import Notification from "./Notification.vue"; const appStore = useAppStore(); const settingStore = useSettingsStore(); diff --git a/src/layout/components/Sidebar/index.vue b/src/layout/components/Sidebar/index.vue index 4db8f35a..022c4594 100644 --- a/src/layout/components/Sidebar/index.vue +++ b/src/layout/components/Sidebar/index.vue @@ -24,7 +24,7 @@ import { LayoutEnum } from "@/enums/LayoutEnum"; import { useSettingsStore, usePermissionStore, useAppStore } from "@/store"; -import NavbarRight from "../Navbar/components/NavbarRight.vue"; +import NavbarRight from "../NavBar/components/NavbarRight.vue"; const appStore = useAppStore(); const settingsStore = useSettingsStore(); diff --git a/src/layout/index.vue b/src/layout/index.vue index ea52148c..5fd72995 100644 --- a/src/layout/index.vue +++ b/src/layout/index.vue @@ -14,16 +14,10 @@
- +
@@ -43,7 +37,7 @@
- +
@@ -62,7 +56,7 @@ import defaultSettings from "@/settings"; import { DeviceEnum } from "@/enums/DeviceEnum"; import { LayoutEnum } from "@/enums/LayoutEnum"; -import Navbar from "@/layout/components/NavBar/index.vue"; +import NavBar from "./components/NavBar/index.vue"; const appStore = useAppStore(); const settingsStore = useSettingsStore(); @@ -97,9 +91,7 @@ const classObj = computed(() => ({ })); watchEffect(() => { - appStore.toggleDevice( - width.value < WIDTH_DESKTOP ? DeviceEnum.MOBILE : DeviceEnum.DESKTOP - ); + appStore.toggleDevice(width.value < WIDTH_DESKTOP ? DeviceEnum.MOBILE : DeviceEnum.DESKTOP); if (width.value >= WIDTH_DESKTOP) { appStore.openSideBar(); } else {