Repository navigation
fix(ios): keep split-view search in sidebar so it does not overlap Composer - #1247
Merged
Merged
Conversation
kyya
force-pushed
the
fix/duo-search-send-overlap
branch
from
November 28, 2026 02:06
4d348e5 to
fc9c024
Compare
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 iPhone Duo (unfolded) and large iPhones in landscape (where
horizontalSizeClass == .regularandHostListViewusesNavigationSplitView), the floating circular Search button from the sidebar's bottom bar overflows into the terminal detail column and overlaps the Composer bar / Send button.Cause
In
ios/GoRex/Views/HostListView.swift:413-415,listunconditionally addedDefaultToolbarItem(kind: .search, placement: .bottomBar)and.searchable(text: $query, prompt: "Search tabs")even whenwidth == .regular.On iPad, iPadOS automatically hoists the sidebar's search button into the sidebar's top navigation bar. On iPhone (
userInterfaceIdiom == .phone) in regular-widthNavigationSplitView(iPhone Duo unfolded or large iPhone landscape), iOS honorsplacement: .bottomBarin the split view's root bottom toolbar, so the floating magnifying-glass button spills out of the sidebar over the detail pane'sComposerBar(and its Send button).Fix
DefaultToolbarItem(kind: .search, placement: .bottomBar)to compact width (width != .regular), keepingToolbarSpacer(.flexible, placement: .bottomBar)so Settings and Inbox stay left-aligned in the sidebar bottom bar.placement: width == .regular ? .sidebar : .automaticto.searchable(...)so search stays scoped to the sidebar in regular-width split view while keeping the compact-width bottom-bar search unchanged.Test
SplitViewComposerUITests.testSplitViewSearchDoesNotOverlapComposerinios/GoRexUITests/ComposerUITests.swift, which opens Demo Mode in regular-width landscape with-composerMode YESand asserts no Search button intersectscomposerorSend(both with the sidebar open and after hiding the sidebar).testSplitViewSearchDoesNotOverlapComposerfailed on iPhone Air (iOS 27.2 Simulator) with:XCTAssertFalse failed - Search button (438.0, 356.0, 36.0, 36.0) overlaps composer (398.0, 268.0, 436.0, 112.0) (sidebar open)testSplitViewSearchDoesNotOverlapComposerpasses in both sidebar-open and sidebar-hidden states.ios/scripts/test-notes check origin/main.userInterfaceIdiom == .phone,horizontalSizeClass == .regular) and iPhone Duo outer display; unfolded iPhone Duo inner display cannot be switched headlessly viasimctlalone.Screenshots
Made-up Demo Mode data only:
Verified: go run ./tools/verify: ios xcodebuild NOT VERIFIED; macmini xcodebuild test SplitViewComposerUITests/testSplitViewSearchDoesNotOverlapComposer passed on iPhone Air landscape (failed before fix)