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 22, 09:30 UTC
fix(mobile): Android floating tab bar fills the row when compose is hidden (#26939)
Co-authored-by: Claude Sonnet 5.5 <noreply@anthropic.com>
voida6 committed
Oct 31, 2026 at 19:35 UTC
5882ccd7f7dd58af962b78dc48699639ea5a7782
2 files changed
+20
-9
apps/mobile/src/features/workspace/AndroidWorkspaceNavigation.android.tsx
+18
-7
@@ -86,13 +86,6 @@ export function AndroidWorkspaceNavigation(props: {
86
const rail = Boolean(props.rail);
87
const floating = !rail && Boolean(props.floating);
88
const tabs = [...visibleNavigationTabs(order, hidden, rail ? 5 : 4), "settings"];
89
- const metrics = floatingTabsMetrics(
90
- tabs.length,
91
- scale,
92
- fabSize,
93
- props.paneWidth ?? window.width,
94
- props.fillWidth,
95
- );
89
const { containerColor, indicatorColor, selectedColor, unselectedColor } =
90
androidWorkspaceNavigationColors(colors, rail, floating);
91
const selectedTab = selectedNavigationTab(
@@ -102,6 +95,24 @@ export function AndroidWorkspaceNavigation(props: {
95
hidden,
96
rail ? 5 : 4,
97
);
98
+ // FloatingWorkspaceTabs starts the bar at the left inset, so a cutout narrows the room.
99
+ const barWidth =
100
+ props.paneWidth ??
101
+ window.width - (Math.max(insets.left, FLOATING_TABS.edge) - FLOATING_TABS.edge);
102
+ // A phone draws compose on the Chats list only; the split sidebar draws it on every tab
103
+ // except the Settings and Usage pages.
104
+ const composeBesideBar =
105
+ props.paneWidth === undefined
106
+ ? selectedTab === "threads"
107
+ : selectedTab !== "settings" && selectedTab !== "usage";
108
+ const metrics = floatingTabsMetrics(
109
+ tabs.length,
110
+ scale,
111
+ fabSize,
112
+ barWidth,
113
+ props.fillWidth,
114
+ composeBesideBar && connectionState.hasConnections,
115
+ );
116
if (!rail && keyboardVisible) return null;
117
118
return (
apps/mobile/src/features/workspace/floating-workspace-tabs.ts
+2
-2
@@ -7,6 +7,7 @@ export function floatingTabsMetrics(
7
fabSize: number,
8
paneWidth?: number,
9
fillWidth = false,
10
+ composeVisible = true,
11
) {
12
const unit = Math.max(1, scale);
13
const height = fabSize;
@@ -16,11 +17,10 @@ export function floatingTabsMetrics(
17
const room =
18
paneWidth === undefined
19
? count * 60 * unit
19
- : sharesRow
20
+ : sharesRow && composeVisible
21
? paneWidth - beside
22
: paneWidth - 2 * FLOATING_TABS.edge;
23
return {
23
- // Reserve the compose slot even while its button is hidden.
24
pill: Math.max(0, fillWidth ? room : Math.min(count * 72 * unit, room)),
25
height,
26
row,