fix: prevent flicker of top tabs on back navigation

This commit is contained in:
codytseng
2025-08-07 09:46:17 +08:00
parent 2f4f4fffcf
commit 3b3a3f41c3
2 changed files with 5 additions and 11 deletions

View File

@@ -60,7 +60,7 @@ const PrimaryPageLayout = forwardRef(
if (isSmallScreen) {
return (
<DeepBrowsingProvider active={current === pageName}>
<DeepBrowsingProvider active={current === pageName && display}>
<div
ref={smallScreenScrollAreaRef}
style={{
@@ -77,7 +77,7 @@ const PrimaryPageLayout = forwardRef(
}
return (
<DeepBrowsingProvider active={current === pageName} scrollAreaRef={scrollAreaRef}>
<DeepBrowsingProvider active={current === pageName && display} scrollAreaRef={scrollAreaRef}>
<ScrollArea
className="h-screen overflow-auto"
scrollBarClassName="z-50 pt-12"