The best way to control Claude Code, Codex and more from any computer or phone
Mirrored from https://github.com/Camo67/t3code.git
Synced Nov 21, 08:30 UTC
fix(mobile): widen the Duo portrait sidebar (#26608)
Co-authored-by: maria-rcks <maria@kuuro.net> Co-authored-by: Julius Marminge <julius0216@outlook.com> Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Jake Leventhal committed
Nov 17, 2026 at 01:54 UTC
0ff1495c05301c1f32503d7861bf9a917e521b40
4 files changed
+14
-3
apps/mobile/src/features/layout/createWorkspaceStackNavigator.ios.tsx
+3
-2
@@ -414,8 +414,9 @@ function WorkspaceColumns(
414
showInspector={inspector.visible}
415
onInspectorHide={hideInspector}
416
columnMetrics={{
417
- minimumPrimaryColumnWidth: 280,
418
- maximumPrimaryColumnWidth: Math.max(380, primaryColumnWidth),
417
+ minimumPrimaryColumnWidth: layout.variant === "medium" ? primaryColumnWidth : 280,
418
+ maximumPrimaryColumnWidth:
419
+ layout.variant === "medium" ? primaryColumnWidth : Math.max(380, primaryColumnWidth),
420
preferredPrimaryColumnWidthOrFraction: primaryColumnWidth,
421
minimumSecondaryColumnWidth: NATIVE_INSPECTOR_MIN_MAIN_WIDTH,
422
// UIKit can retain its automatic width despite a new preference; constrain both edges.
apps/mobile/src/features/layout/workspace/WorkspaceSidebarTabs.ios.tsx
+3
@@ -5,6 +5,7 @@ import { useControlTheme } from "../../../components/ui/useControlTheme";
5
import { useNavigationTabOrder, useHiddenNavigationTabs } from "./navigation-tabs";
6
import { useWorkspaceTabs } from "./WorkspaceTabsContext";
7
import { useSelectWorkspaceTab } from "./useSelectWorkspaceTab";
8
+import { useAdaptiveWorkspaceLayout } from "../adaptive-workspace-context";
9
10
const NativeSidebarTabBar = requireNativeView<
11
ViewProps & {
@@ -25,6 +26,7 @@ export function WorkspaceSidebarTabs(props: {
26
readonly reserveComposeSpace?: boolean;
27
}) {
28
const workspace = useWorkspaceTabs()!;
29
+ const { layout } = useAdaptiveWorkspaceLayout();
30
const order = useNavigationTabOrder();
31
const hidden = useHiddenNavigationTabs();
32
const tabs = [...visibleNavigationTabs(order, hidden), "settings" as const];
@@ -57,6 +59,7 @@ export function WorkspaceSidebarTabs(props: {
59
position: "absolute",
60
bottom: 0,
61
left: props.compact ? 8 : 0,
62
+ maxWidth: layout.variant === "medium" ? 280 : undefined,
63
// Keep the tab icons in place when Compose disappears on other destinations.
64
right:
65
(props.compact ? 12 : 0) +
apps/mobile/src/lib/layout.test.ts
+1
@@ -67,6 +67,7 @@ describe("native workspace sizing", () => {
67
};
68
const layout = deriveLayout({ ...size, nativeMetrics, nativeWorkspace });
69
expect(layout.variant === "medium").toBe(overlay);
70
+ expect(layout.listPaneWidth).toBe(overlay ? 350 : size.width === 951 ? 304 : 280);
71
for (const primarySidebarPreferredVisible of [true, false]) {
72
expect(
73
deriveWorkspacePaneLayout({
apps/mobile/src/lib/layout.ts
+7
-1
@@ -151,7 +151,13 @@ export function deriveLayout(input: {
151
usesSplitView: true,
152
listPaneWidth:
153
division?.x ??
154
- clamp(Math.round(width * 0.32), SPLIT_SIDEBAR_MIN_WIDTH, SPLIT_SIDEBAR_DEFAULT_MAX_WIDTH),
154
+ (input.nativeWorkspace === true && variant === "medium"
155
+ ? 350
156
+ : clamp(
157
+ Math.round(width * 0.32),
158
+ SPLIT_SIDEBAR_MIN_WIDTH,
159
+ SPLIT_SIDEBAR_DEFAULT_MAX_WIDTH,
160
+ )),
161
...(division ? { listPaneGap: division.width } : {}),
162
shellPadding: 0,
163
};