Skip to content

Commit b147dc9

Browse files
authored
fix(mobile): preserve iPad search chrome across layout changes (pingdotgg#13667)
1 parent 74f9df3 commit b147dc9

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
@@ -150,7 +150,15 @@ export function HomeRouteScreen() {
150150
options={
151151
Platform.OS === "android"
152152
? { headerShown: false }
153-
: { title: "", headerTitle: "", unstable_headerLeftItems: () => [] }
153+
: {
154+
title: "",
155+
headerTitle: "",
156+
unstable_headerLeftItems: () => [],
157+
// Options survive layout changes; search and settings now belong to the sidebar.
158+
headerSearchBarOptions: undefined,
159+
unstable_headerRightItems: () => [],
160+
unstable_headerToolbarItems: () => [],
161+
}
154162
}
155163
/>
156164
{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)