mirror of
https://github.com/un-pany/v3-admin-vite.git
synced 2025-04-20 19:09:21 +08:00
fix: 修复 release v4.5.5 版本引起的 mobile + 非左侧布局模式时左侧导航菜单背景色异常的问题
This commit is contained in:
parent
2d840ea675
commit
d3fc20a53a
@ -5,8 +5,10 @@ import { useAppStore } from "@/store/modules/app"
|
||||
import { useSettingsStore } from "@/store/modules/settings"
|
||||
import { AppMain, NavigationBar, Sidebar, TagsView } from "./components"
|
||||
import { useDevice } from "@/hooks/useDevice"
|
||||
import { useLayoutMode } from "@/hooks/useLayoutMode"
|
||||
|
||||
const { isMobile } = useDevice()
|
||||
const { isLeft } = useLayoutMode()
|
||||
const appStore = useAppStore()
|
||||
const settingsStore = useSettingsStore()
|
||||
const { showTagsView, fixedHeader } = storeToRefs(settingsStore)
|
||||
@ -17,7 +19,8 @@ const layoutClasses = computed(() => {
|
||||
hideSidebar: !appStore.sidebar.opened,
|
||||
openSidebar: appStore.sidebar.opened,
|
||||
withoutAnimation: appStore.sidebar.withoutAnimation,
|
||||
mobile: isMobile.value
|
||||
mobile: isMobile.value,
|
||||
noLeft: !isLeft.value
|
||||
}
|
||||
})
|
||||
|
||||
@ -159,6 +162,12 @@ $transition-time: 0.35s;
|
||||
transform: translate3d(calc(0px - var(--v3-sidebar-width)), 0, 0);
|
||||
}
|
||||
}
|
||||
// 既是 mobile 又是顶部或混合布局模式
|
||||
&.noLeft {
|
||||
.sidebar-container {
|
||||
background-color: var(--el-bg-color);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.withoutAnimation {
|
||||
|
Loading…
x
Reference in New Issue
Block a user