@devries-cameron20 / t3code-1 / commits / 9a648d44db
Fork 0

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

fix(android): space the New thread FAB 16dp from the edge and tab bar (#18578)

Co-authored-by: Julius Marminge <julius0216@outlook.com> Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>

Alex committed Oct 19, 2026 at 14:10 UTC 9a648d44db22f6c7e87fc4b7bea5d57a09a80a82
3 files changed +22 -14
apps/mobile/src/features/home/AndroidHomeFab.android.tsx
+6 -7
@@ -7,7 +7,10 @@ import {
7 } from "react-native";
8 import { useSafeAreaInsets } from "react-native-safe-area-context";
9 import { NewThreadButton } from "../../components/NewThreadButton";
10 -import type { AndroidHomeFabLayout as SharedAndroidHomeFabLayout } from "./AndroidHomeFab.shared";
10 +import {
11 + androidHomeFabPosition,
12 + type AndroidHomeFabLayout as SharedAndroidHomeFabLayout,
13 +} from "./AndroidHomeFab.shared";
14 import { useWorkspaceState } from "../../state/workspace";
15 import { FabScrollContext } from "./FabScrollContext";
16 import { updateFabScroll } from "./fab-scroll";
@@ -42,12 +45,8 @@ export function AndroidHomeFabLayout(props: ComponentProps<typeof SharedAndroidH
45 extended
46 expanded={expanded}
47 onPress={props.onStartNewTask}
45 - className="absolute right-5"
46 - style={{
47 - bottom: props.sidebar
48 - ? Math.max(insets.bottom, 12) + 6
49 - : Math.max(insets.bottom, 16) + 16,
50 - }}
48 + className="absolute"
49 + style={androidHomeFabPosition(insets.bottom, props.sidebar)}
50 />
51 ) : null}
52 </View>
apps/mobile/src/features/home/AndroidHomeFab.shared.tsx
+12
@@ -8,3 +8,15 @@ export function AndroidHomeFabLayout(props: {
8 }) {
9 return <>{props.children}</>;
10 }
11 +
12 +/**
13 + * The filter button stacks on the New thread FAB from this same origin so the two
14 + * cannot drift apart. In dp rather than a rem class so Material's 16dp margin does
15 + * not grow with the app's text size.
16 + */
17 +export function androidHomeFabPosition(safeAreaBottom: number, sidebar: boolean | undefined) {
18 + return {
19 + right: 16,
20 + bottom: sidebar ? Math.max(safeAreaBottom, 12) + 6 : safeAreaBottom + 16,
21 + };
22 +}
apps/mobile/src/features/home/ThreadListToolbar.tsx
+4 -7
@@ -24,6 +24,7 @@ import { useWorkspaceState } from "../../state/workspace";
24 import { useAndroidControlSizing } from "../../components/ui/useAndroidControlSizing";
25 import { useToolbarLayout } from "../../components/ui/useToolbarLayout";
26 import { PullRequestGlyph } from "../pull-requests/pullRequestGlyphs";
27 +import { androidHomeFabPosition } from "./AndroidHomeFab.shared";
28
29 /** One toolbar height for the compact list and expanded sidebar, including search. */
30 export function ThreadListToolbar(props: {
@@ -46,6 +47,7 @@ export function ThreadListToolbar(props: {
47 const listFocused =
48 homeFocused && (workspace === null || workspace.state.selectedTab === "threads");
49 const { fabSize } = useAndroidControlSizing();
50 + const fab = androidHomeFabPosition(insets.bottom, props.sidebar);
51 const { height: toolbarHeight, ...headerPadding } = useToolbarLayout();
52 const { state } = useWorkspaceState();
53 const { onRequestVisibility, onSearchQueryChange } = props;
@@ -150,13 +152,8 @@ export function ThreadListToolbar(props: {
152 </View>
153 {state.hasConnections ? (
154 <View
153 - className="absolute right-5 z-[5]"
154 - style={{
155 - bottom:
156 - (props.sidebar ? Math.max(insets.bottom, 12) + 6 : Math.max(insets.bottom, 16) + 16) +
157 - fabSize +
158 - 8,
159 - }}
155 + className="absolute z-[5]"
156 + style={{ right: fab.right, bottom: fab.bottom + fabSize + 8 }}
157 >
158 <AndroidAnchoredMenu actions={props.filterActions} onPressAction={props.onFilterAction}>
159 {(open) => (