From d213d1e5a2ad04c29252742e73f5fb9cf9ec200f Mon Sep 17 00:00:00 2001 From: Jinjing <6427696+AmethystLiang@users.noreply.github.com> Date: Fri, 3 Jul 2026 19:23:42 -0700 Subject: [PATCH] Pin the new tab button outside the tab scroll view Move the "New tab" button out of ScrollView so that it remains visible and reachable regardless of how far the tabs have been scrolled. --- .../app/h/[hostId]/session/[worktreeId].tsx | 41 +++++++++---------- 1 file changed, 20 insertions(+), 21 deletions(-) diff --git a/mobile/app/h/[hostId]/session/[worktreeId].tsx b/mobile/app/h/[hostId]/session/[worktreeId].tsx index 3166645727e..923c0a81fb2 100644 --- a/mobile/app/h/[hostId]/session/[worktreeId].tsx +++ b/mobile/app/h/[hostId]/session/[worktreeId].tsx @@ -4642,28 +4642,27 @@ export default function SessionScreen() { ))} - [ - styles.newTerminalButton, - pressed && styles.newTerminalButtonPressed, - (creating || - creatingBrowser || - creatingMarkdown || - connState !== 'connected') && - styles.newTerminalButtonDisabled - ]} - disabled={ - creating || creatingBrowser || creatingMarkdown || connState !== 'connected' - } - onPress={() => { - setCreateError('') - setShowCreateTabDrawer(true) - }} - accessibilityLabel="New tab" - > - - + {/* Why: pinned outside the scroll strip so the new-agent button + stays reachable no matter how far the tabs scroll. */} + [ + styles.newTerminalButton, + pressed && styles.newTerminalButtonPressed, + (creating || creatingBrowser || creatingMarkdown || connState !== 'connected') && + styles.newTerminalButtonDisabled + ]} + disabled={ + creating || creatingBrowser || creatingMarkdown || connState !== 'connected' + } + onPress={() => { + setCreateError('') + setShowCreateTabDrawer(true) + }} + accessibilityLabel="New tab" + > + + )}