Repository navigation
fix(ios): show a sidebar toggle on the unfolded iPhone Duo in portrait - #20133
Merged
juliusmarminge merged 3 commits intoOct 16, 2026
Merged
Conversation
Unfolded in portrait, the Duo's inner display reports a hinge but no side bar or fold division, so deriveLayout skipped the Duo rule and applied the iPad width floor (720pt) to its 669pt window. The layout went compact while UIKit kept the split expanded: the thread filled the screen with no way back to the list except an edge swipe. Treat any hinged display as Duo geometry, so unfolded portrait takes the split path iPad uses: the list beside the thread, the sidebar toggle in the thread header, and the Threads/Pull requests picker in the sidebar instead of the phone tab bar. Landscape keeps its side rail and the folded screen stays compact.
Contributor
ApprovabilityVerdict: Approved at Macroscope's review found this PR approvable — This is a focused iOS Duo portrait layout fix with localized workspace toolbar changes and regression coverage for the affected device metrics. Existing iPad, folded Duo, Android, and side-rail paths remain accounted for, with no schema, infrastructure, security, or static-analysis changes. You can add or adjust custom eligibility rules. Learn more. |
The previous commit gave the unfolded portrait Duo iPad's segmented picker. Keep tab buttons instead: Threads and Pull requests sit at the leading edge of the thread list's bottom toolbar, with compose at the trailing edge, so they hide with the list. UIKit's own tab bar cannot be leading-aligned, so it stays hidden in this posture. iPad keeps its picker, which now shares the tab selection logic.
macroscopeapp
Bot
dismissed
their stale review
October 16, 2026 03:44
Dismissing prior approval to re-evaluate c8bbdcc
# Conflicts: # apps/mobile/src/features/workspace/WorkspaceRootScreen.tsx # apps/mobile/src/features/workspace/useSystemWorkspaceTabBar.ts
macroscopeapp
Bot
dismissed
their stale review
October 16, 2026 05:59
Dismissing prior approval to re-evaluate 50ae77d
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
On the iPhone Duo unfolded in portrait, an open thread fills the screen and the thread list is hidden. The only way back to the list is an edge swipe, and nothing in the header hints at it. iPad shows a sidebar toggle in the same situation. Julius agreed in Discord that there should be a sidebar button there, top left.
Cause
Unfolded in portrait, the inner display (669×951pt, regular width) reports a hinge but no side bar and no fold
division. The Duo rule inderiveLayoutkeys off those two signals, so this posture fell through to the iPad floor of 720pt and went compact. UIKit still kept the split expanded, so it showed the thread alone. With a compact layout the thread header never got the split view's sidebar toggle.Fix
deriveLayoutalso treats a display with a hinge as Duo geometry. Unfolded portrait now takes the same split path as iPad: the list sits beside the thread, and the thread header gets the sidebar toggle (Maximize content / Show thread sidebar).Unfolded landscape already took the Duo path through its side rail, and the folded front screen reports a compact size class, so neither changes.
Verification
Device metrics from the iOS 27.1 Duo simulator, read from
useNativeLayoutMetrics:vp test run apps/mobile/src/lib/reserved-regions.test.ts apps/mobile/src/lib/layout.test.ts: 49 passed. New cases use the measured unfolded-portrait metrics (split with the hinge, compact without it) and the folded metrics in both orientations.vp run typecheckinapps/mobilepasses.vp lintandvp fmt --checkon the changed files are clean.On the Duo, unfolded in portrait, with a synthetic showcase environment: the toggle hides and shows the list. The toolbar tabs switch between Threads and Pull requests, including from an open thread (which closes it), and the selected tab is highlighted. Collapsing the list hides the tabs, leaving compose only in the thread header. In unfolded landscape, the side rail and the list beside the thread look the same as on main.
On an iPad simulator, the sidebar's segmented picker still switches tabs after the shared selection hook refactor.
Not checked: the folded front screen visually. The simulator stream goes black while folded, so the folded rows above come from the metrics log only.
Before / After
iPhone Duo, unfolded, portrait.
Model: Claude Opus 5.5 | Harness: Claude Code in T3 Code