@devries-cameron20 / t3code-1 / commits / 80e62619f5
Fork 0

The best way to control Claude Code, Codex and more from any computer or phone

fix(mobile): iOS 18 iPad sidebar and thread feed start below the header (#32936)

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>

Julius Marminge committed Nov 10, 2026 at 08:00 UTC 80e62619f5c01d84579bcf70ea6d566712007412
5 files changed +13 -16
apps/mobile/src/components/ui/useBarInset.ts
+3 -3
@@ -38,9 +38,9 @@ export function useBarOverlap(): number {
38 }
39
40 /**
41 - * The content's top safe area under the AppBar: a translucent bar's height, zero under a solid
42 - * one or on Android, where the bar sits in flow. For scroll content insets, which must not
43 - * double-count a solid bar.
41 + * The content's top safe area under the AppBar: the height of the iOS bar its column lays content
42 + * under, glass or solid, and zero on Android, where the bar sits in flow. For manual scroll
43 + * content insets.
44 */
45 export function useContentTopInset(): number {
46 const insets = useSafeAreaInsets();
apps/mobile/src/features/layout/workspace/workspace-list-insets.ts
-6
@@ -2,12 +2,6 @@ import { useSafeAreaInsets } from "react-native-safe-area-context";
2
3 import { NATIVE_LIQUID_GLASS_SUPPORTED } from "../../../native/native-glass";
4
5 -/** A workspace list scrolls under its bar where the bar is glass; under a solid bar it starts below. */
6 -export const WORKSPACE_LIST_SCROLL_INSETS = {
7 - automaticallyAdjustsScrollIndicatorInsets: NATIVE_LIQUID_GLASS_SUPPORTED,
8 - contentInsetAdjustmentBehavior: NATIVE_LIQUID_GLASS_SUPPORTED ? "automatic" : "never",
9 -} as const;
10 -
5 /** How far an empty workspace list keeps its message below a glass bar and its search. */
6 export function useWorkspaceListEmptyTopInset(): number {
7 const insets = useSafeAreaInsets();
apps/mobile/src/features/threads/ThreadDetailScreen.tsx
-1
@@ -1496,7 +1496,6 @@ function ThreadDetailBody(
1496 keyboardOffset={composerKeyboardOffset}
1497 sendingWithKeyboard={sendingWithKeyboard}
1498 fitShortFeedToViewport={questionInFlow && !isKeyboardVisible}
1499 - contentTopInset={0}
1499 contentBottomInset={
1500 questionInFlow
1501 ? 0
apps/mobile/src/features/threads/ThreadFeed.tsx
+7 -4
@@ -170,7 +170,7 @@ import { getReviewSectionIdForCheckpoint } from "../review/reviewModel";
170 import { setReviewSelectedSectionId } from "../review/reviewState";
171 import { Menu } from "../../components/ui/Menu";
172 import { useAndroidControlSizing } from "../../components/ui/useAndroidControlSizing";
173 -import { useBarInset } from "../../components/ui/useBarInset";
173 +import { useBarInset, useContentTopInset } from "../../components/ui/useBarInset";
174 import { copyPromptLink } from "../prompt-links/prompt-link-actions";
175 import { parseReviewCommentMessageSegments } from "../review/reviewCommentSelection";
176 import {
@@ -332,7 +332,6 @@ export interface ThreadFeedProps {
332 readonly keyboardOffset: number;
333 readonly sendingWithKeyboard?: boolean;
334 readonly fitShortFeedToViewport?: boolean;
335 - readonly contentTopInset?: number;
335 readonly contentBottomInset?: number;
336 readonly historyControls?: ThreadFeedHistoryControls;
337 readonly contentMaxWidth?: number;
@@ -2772,10 +2771,12 @@ export const ThreadFeed = memo(function ThreadFeed(props: ThreadFeedProps) {
2771 const markdownContentWidth = Math.max(0, contentWidth - ASSISTANT_ROW_HORIZONTAL_PADDING * 2);
2772 const reviewCommentBubbleWidth = Math.min(Math.max(280, contentWidth * 0.85), contentWidth);
2773 const barInset = useBarInset();
2775 - const topContentInset = props.contentTopInset ?? barInset;
2774 + const columnTopInset = useContentTopInset();
2775 const bottomContentInset = props.contentBottomInset ?? 18;
2776 const usesNativeAutomaticInsets =
2777 props.usesAutomaticContentInsets === true && Platform.OS === "ios";
2778 + // Without the native contentInset, a list-header spacer clears the bar the column lays content under.
2779 + const topContentInset = usesNativeAutomaticInsets ? 0 : columnTopInset;
2780 const anchorTopInset = usesNativeAutomaticInsets ? barInset : topContentInset;
2781
2782 const theme = useUniwindTheme();
@@ -3200,7 +3201,9 @@ export const ThreadFeed = memo(function ThreadFeed(props: ThreadFeedProps) {
3201 if (state) onIsAtEndChange?.(state.isAtEnd);
3202 };
3203 const handleScroll = (event: NativeSyntheticEvent<NativeScrollEvent>) => {
3203 - reportHeaderMaterialVisibility(event.nativeEvent.contentOffset.y + anchorTopInset > 6);
3204 + reportHeaderMaterialVisibility(
3205 + event.nativeEvent.contentOffset.y + (usesNativeAutomaticInsets ? barInset : 0) > 6,
3206 + );
3207 handleMetricsChange();
3208 };
3209 // oxlint-disable-next-line t3code/no-unreasoned-state-sync -- subscribes to the list's end state to report it to the parent
apps/mobile/src/features/threads/ThreadNavigationSidebar.tsx
+3 -2
@@ -48,7 +48,6 @@ import { usePendingTaskListActions } from "../home/usePendingTaskListActions";
48 import { useThreadListActions } from "../home/useThreadListActions";
49 import { useFabScroll } from "../home/FabScrollContext";
50 import { WorkspaceListHeader } from "../layout/workspace/WorkspaceListHeader";
51 -import { WORKSPACE_LIST_SCROLL_INSETS } from "../layout/workspace/workspace-list-insets";
51 import { WorkspaceSidebarColumn } from "../layout/workspace/WorkspaceSidebarColumn";
52 import {
53 ThreadListV2PendingRow,
@@ -592,7 +591,9 @@ function ThreadNavigationSidebarPane(props: ThreadNavigationSidebarProps) {
591 itemsAreEqual={sidebarItemsAreEqual}
592 keyExtractor={(item) => item.key}
593 renderItem={renderListItem}
595 - {...WORKSPACE_LIST_SCROLL_INSETS}
594 + automaticallyAdjustsScrollIndicatorInsets
595 + // The column lays the list under its bar, glass or solid; UIKit insets it past both.
596 + contentInsetAdjustmentBehavior="automatic"
597 contentContainerStyle={[
598 styles.threadListContent,
599 {