feat(mobile): the folded Duo opens search from a search tab below the tab bar#24360

merged1
t3code/settings-split-tab
t3code/duo-search-tab
opened24d agobyJJulius Marminge
View on GitHubTwo-way sync enabledPR last imported 23d ago

Stacked on #24524.

On the folded Duo, search was a button at the top of the vertical bar, next to compose. Photos puts it in a search tab that UIKit sets apart below the tab bar, which is easier to reach and keeps the top of the bar for actions.

The workspace tab bar gets a native UISearchTab (role: "search" with automaticallyActivatesSearch, which iOS 27 needs to set it apart). It never becomes selected: pressing it returns to the current list (Chats from Usage or Settings, popping an open chat) and starts its search. Search closes from the field's own cancel button.

Starting a search is list state with a focus-request counter. The header focuses the field once per request as soon as the field attaches. This replaces the effect that focused it one frame later and missed fields that mount with the request, so there is no frame waiting anywhere in the flow.

Search tab from Chats, again after closing, from a chat, and from Usage, each with the keyboard up

Verified on the folded Duo simulator with the software keyboard: from the Chats list, a second search after closing, from inside a chat, from Usage and from Settings; submitting a query and tapping the tab again refocuses with the query kept. Not verified: a physical Duo, and folding or unfolding while the search tab is shown.

Model: Claude Opus 5.5 | Harness: Claude Code in T3 Code

🤖 Generated with Claude Code

Checks

1 pending · 21 successful · 16 skipped
Checks in progress

In progress1

4e4ece0
apps/mobile/src/features/workspace/WorkspaceNativeTabs.ios.tsxlines 88–88Outdated · ea0773dOpen thread
……@@ -76,6 +78,15 @@ export function WorkspaceNativeTabs(props: {
85+ props.onSelect();
86+ workspace.dispatch({ type: "select", tab: "threads" });
87+ requestAnimationFrame(() => dispatchHardwareKeyboardCommand("focusSearch"));
88+ } else dispatchHardwareKeyboardCommand("focusSearch");
MmacroscopeappBoton lines 88–8824d ago

🟠 High workspace/WorkspaceNativeTabs.ios.tsx:88

On the folded Duo, pressing Search from a thread or pull-request detail focuses the hidden primary list instead of returning to a usable search view. This branch only dispatches focusSearch; call props.onSelect() before focusing to pop the detail route to the workspace root.

No longer relevant as of 311d446ec675de2c6ef6fef6eb3d3530119a9a07

Synced from GitHub

Approvability

Verdict: Needs Human Approval

Macroscope's review found this PR requires human approval — This adds a native search tab for folded Duo devices, replacing the existing folded-Duo toolbar search control and adding cross-layer focus behavior in shared iOS navigation code. The user-facing navigation change spans several runtime layers and merits human review.

No code changes detected at 92b8326. Prior analysis still applies.

You can add or adjust custom eligibility rules. Learn more.

Synced from GitHub

Review in Change Stack →

No actionable comments were generated in the recent review.

External image Recent review info
External image Run configuration
External image Commits

Reviewing files that changed from the base of the PR and between ea0773d3782deaaf67e48cadfcfc9ddcac3bea88 and 7894c992ff546a4f1f8d764b3690791e7c397928.

External image Files selected for processing: 1
  • apps/mobile/src/features/workspace/WorkspaceToolbar.ios.tsx
External image Files with no reviewable changes: 1
  • apps/mobile/src/features/workspace/WorkspaceToolbar.ios.tsx

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 7 remain after this review.

Walkthrough

On folded Duo devices, iOS adds a native search tab that routes selection to search focus. The iOS toolbar removes its folded-Duo search button and related spacing and cancel-button configuration.

Changes: Folded Duo iOS search

Layer / File(s)Summary
Native search tab and activation
apps/mobile/src/features/workspace/WorkspaceNativeTabs.ios.tsx, apps/mobile/src/features/workspace/WorkspaceToolbar.ios.tsx
Adds a native search item for folded Duo devices. Search selection selects the threads tab when settings are open or the selected tab does not use columns, then schedules search focus; otherwise it dispatches search focus directly. Removes the folded-Duo toolbar search button, its spacer, and the conditional cancelButtonHidden option.

Priority: External image Low

Estimated code review effort: 2 (Simple) | ~10 minutes

Change: Feature

Sequence Diagram(s)

mermaid
1sequenceDiagram
2 participant NativeSearchItem
3 participant WorkspaceNativeTabs
4 participant SelectionCallback as props.onSelect
5 participant HardwareSearchFocusCommand
6 NativeSearchItem->>WorkspaceNativeTabs: report search selection
7 alt settings are open or selected tab does not use columns
8 WorkspaceNativeTabs->>SelectionCallback: select threads
9 WorkspaceNativeTabs->>HardwareSearchFocusCommand: schedule search focus
10 else
11 WorkspaceNativeTabs->>HardwareSearchFocusCommand: dispatch search focus
12 end

Possibly related PRs

  • pingdotgg/t3code#24206: Both PRs change folded Duo native search behavior; #24206 addresses search focus and keyboard ownership.
  • pingdotgg/t3code#23841: This PR extends the native workspace tab structure introduced by #23841 with a search slot.
  • pingdotgg/t3code#18158: Both PRs change Duo search presentation while retaining the workspace search behavior.

Suggested reviewers: pixpmusic

Merge Risk: External image Minimal · up to 7894c

No confirmed issue blocks merging. Search activation after switching from Usage or Settings remains worth checking on a folded Duo.

Pre-merge checks: Passed 3 · Failed 1

Failed Failed checks: 1 warning

Check nameStatusExplanationResolution
Description checkWarningThe description is mostly complete, but it does not follow the required template. It has no Problem, Change, Scope and approval, or Verification headings. The content covers the problem, the change, a…Restructure the description under the template headings: Problem, Change, Scope and approval, and Verification. Under Scope and approval, link the triaged bug issue or the maintainer discussion with explicit approval of the search-tab direc…
Passed Passed checks: 3 passed
Check nameStatusExplanation
Title checkPassedThe title clearly describes the main change: moving folded Duo search to a search tab below the tab bar.
Linked Issues checkPassedCheck skipped because no linked issues were found for this pull request.
Out of Scope Changes checkPassedCheck skipped because no linked issues were found for this pull request.
Full details: Description check

Explanation

The description is mostly complete, but it does not follow the required template. It has no Problem, Change, Scope and approval, or Verification headings. The content covers the problem, the change, and verification in prose, so it is substantive. Scope and approval is the main gap. The description says it is stacked on #24524 and gives no linked triaged issue or maintainer approval for the direction and scope of this search-tab change. Some verification detail is present (simulator checks, what was not verified), but the template asks for focused tests or checks. A before/after screenshot is included, but the template requires clear before/after images for UI changes, and the PR shows only after-state screenshots of the search tab.

Resolution

Restructure the description under the template headings: Problem, Change, Scope and approval, and Verification. Under Scope and approval, link the triaged bug issue or the maintainer discussion with explicit approval of the search-tab direction, and link the parent PR #24524 for the stacked dependency. Under Verification, list the focused checks and their observed results, keep the list of unverified items, and add before/after screenshots for the folded Duo search button versus the new search tab. Keep the model and harness line at the end.

Finishing Touches
📝 Generate docstrings
  • Commit to this branch
  • Create a new PR
🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Comment @coderabbitai help to get the list of available commands.

Added 1 commit

  • feat(mobile): the folded Duo opens search from a search tab below the tab bar4e4ece0