diff --git a/src/pages/home/wgts/content-partition/index.jsx b/src/pages/home/wgts/content-partition/index.jsx index 7b014d09e..69c100571 100644 --- a/src/pages/home/wgts/content-partition/index.jsx +++ b/src/pages/home/wgts/content-partition/index.jsx @@ -129,9 +129,9 @@ export default function WgtContentPartition(props) { return { ...getGlobalBaseStyle(base.outerMargin), position: base.navSticky ? 'sticky' : 'relative', - top: immersive ? `${navBarHeight}px` : 0 + top: base.navSticky ? `${navBarHeight}px` : 0 } - }, [base.outerMargin, base.navSticky, immersive, navBarHeight]) + }, [base.outerMargin, base.navSticky, navBarHeight]) // 获取导航项区域样式(navitemarea) const navItemAreaStyle = useMemo(() => { diff --git a/src/pages/home/wgts/location-module/index.jsx b/src/pages/home/wgts/location-module/index.jsx index 7bbb86872..de8e488d0 100644 --- a/src/pages/home/wgts/location-module/index.jsx +++ b/src/pages/home/wgts/location-module/index.jsx @@ -51,13 +51,12 @@ export default function WgtLocationModule(props) { // 获取导航栏样式 const navStyle = useMemo(() => { - console.log(immersive, navBarHeight, 'immersive,navBarHeight') return { ...getGlobalBaseStyle(base.outerMargin), position: base.navSticky ? 'sticky' : 'relative', - top: immersive ? `${navBarHeight}px` : 0 + top: base.navSticky ? `${navBarHeight}px` : 0 } - }, [base.outerMargin, base.navSticky, immersive, navBarHeight]) + }, [base.outerMargin, base.navSticky, navBarHeight]) // 获取导航项区域样式(navitemarea) const navItemAreaStyle = useMemo(() => {