Skip to content

Commit 16cae41

Browse files
committed
fix(mobile): preserve iPad search chrome across layout changes
1 parent 29e09df commit 16cae41

2 files changed

Lines changed: 12 additions & 2 deletions

File tree

‎apps/mobile/src/features/home/HomeRouteScreen.tsx‎

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,15 @@ export function HomeRouteScreen() {
141141
options={
142142
Platform.OS === "android"
143143
? { headerShown: false }
144-
: { title: "", headerTitle: "", unstable_headerLeftItems: () => [] }
144+
: {
145+
title: "",
146+
headerTitle: "",
147+
unstable_headerLeftItems: () => [],
148+
// Options survive layout changes; search and settings now belong to the sidebar.
149+
headerSearchBarOptions: undefined,
150+
unstable_headerRightItems: () => [],
151+
unstable_headerToolbarItems: () => [],
152+
}
145153
}
146154
/>
147155
{Platform.OS === "ios" ? (

‎apps/mobile/src/features/layout/AdaptiveWorkspaceLayout.tsx‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -495,7 +495,9 @@ function AdaptiveWorkspaceLayoutContent(
495495
renderedSidebarWidth,
496496
]);
497497
const sidebarAnimatedStyle = useAnimatedStyle(() => ({
498-
opacity: Math.min(1, renderedSidebarWidth.value / 80),
498+
// Fading a UIKit glass ancestor can leave remounted header effects missing.
499+
// The clipped width already reveals and hides the iOS sidebar.
500+
opacity: Platform.OS === "ios" ? 1 : Math.min(1, renderedSidebarWidth.value / 80),
499501
width: renderedSidebarWidth.value,
500502
}));
501503

0 commit comments

Comments
 (0)