From 48f0b015694c17767180eb2f75e9eb12c3f2a358 Mon Sep 17 00:00:00 2001 From: CHOYSEN Date: Fri, 20 Jan 2023 13:37:40 +0800 Subject: [PATCH] fix(theme): adjust the position of the curtain to avoid block sidebar (#1816) --- src/client/theme-default/components/VPNavBar.vue | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/client/theme-default/components/VPNavBar.vue b/src/client/theme-default/components/VPNavBar.vue index bf8c653f..6189e4df 100644 --- a/src/client/theme-default/components/VPNavBar.vue +++ b/src/client/theme-default/components/VPNavBar.vue @@ -166,8 +166,7 @@ const { hasSidebar } = useSidebar() position: absolute; right: 0; bottom: -32px; - padding-left: var(--vp-sidebar-width); - width: 100%; + width: calc(100% - var(--vp-sidebar-width)); height: 32px; } @@ -182,7 +181,7 @@ const { hasSidebar } = useSidebar() @media (min-width: 1440px) { .VPNavBar.has-sidebar .curtain { - padding-left: calc((100vw - var(--vp-layout-max-width)) / 2 + var(--vp-sidebar-width)); + width: calc(100% - ((100vw - var(--vp-layout-max-width)) / 2 + var(--vp-sidebar-width))); } }