Search tab (#5754)

* Add a developer flag for the search tab
Introduces a globalSearchEnabled user preference (off by default) with a toggle in Developer Options, used to gate the new search experience.

* Support search role tabs in the tab coordinator
Migrates the NavigationTabCoordinator to SwiftUI's value-based Tab API and adds an isSearch option so a tab can adopt the iOS 26 .search role, which detaches it into the trailing search button in the tab bar.

* Moves room search to a new screen
Adds a new screen that filters the alternate room summary provider as you type, shows an empty state, and lists matching rooms with their matrix identifier. Supports hardware keyboard selection (arrow keys to move through results, return to open) by reaching into the system search field.

* Present search in a dedicated tab
Adds the search tab to the chats flow on iOS 26 when the flag is enabled, rendered as the detached .search role button. The Cmd+K shortcut now selects this tab, and the home screen's inline search is hidden while the tab is available.

* Remove the old global search screen
The dedicated search tab replaces the Cmd+K floating window, so the GlobalSearchScreen, its window plumbing in the WindowManager, and its presentation in the chats flow are all removed.
This commit is contained in:
Stefan Ceriu
2026-06-19 13:50:17 +03:00
committed by GitHub
parent 9a6f7595e5
commit 7f1b6086ae
58 changed files with 731 additions and 780 deletions
@@ -312,20 +312,6 @@ extension PreviewTests {
}
}
@Test
func globalSearchScreenListRow() async throws {
for (index, preview) in GlobalSearchScreenListRow_Previews._allPreviews.enumerated() {
try await assertSnapshots(matching: preview, step: index)
}
}
@Test
func globalSearchScreen() async throws {
for (index, preview) in GlobalSearchScreen_Previews._allPreviews.enumerated() {
try await assertSnapshots(matching: preview, step: index)
}
}
@Test
func highlightedTimelineItemModifier() async throws {
for (index, preview) in HighlightedTimelineItemModifier_Previews._allPreviews.enumerated() {
@@ -1068,6 +1054,13 @@ extension PreviewTests {
}
}
@Test
func searchScreen() async throws {
for (index, preview) in SearchScreen_Previews._allPreviews.enumerated() {
try await assertSnapshots(matching: preview, step: index)
}
}
@Test
func secureBackupKeyBackupScreen() async throws {
for (index, preview) in SecureBackupKeyBackupScreen_Previews._allPreviews.enumerated() {
@@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:2e96b757eacb7be702a40a8f9494f8900e2ada38838c78a38190a3837d56a2ec
size 171848
@@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:456fe50194ca5e15d431437a6342bc0664266cdc54d8084dd18639980cf0eb60
size 172156
@@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:611812894a3f67b80d5f32a9192eb787262c4c05fb869a79ceb561ac88865047
size 106611
@@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:80c1dffec6a31d5383f694ad063dbb1f6614f4c8da21b94e8d4b587fa355b706
size 106942
@@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:5b9d73c339d27730080a8620d3c3dfee9e8bb05f22a911d30a57bcab71fb18a1
size 98755
@@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:5b9d73c339d27730080a8620d3c3dfee9e8bb05f22a911d30a57bcab71fb18a1
size 98755
@@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:b47056a891a64a3c4a5ead1161a98ca8e16319727cb8962f95f8a8ddc47e2a45
size 50155
@@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:b47056a891a64a3c4a5ead1161a98ca8e16319727cb8962f95f8a8ddc47e2a45
size 50155
@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:0a93a6802d8a053abd390e9311921294dfbab18844eb17a63eaf4b8c623173a9
size 85119
@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:72835c30b6f459759cbbae44aaba4aed0c39674c49879602c7a8a319323b9db1
size 88205
@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:25f1c159081bfcf7e1fb181bb6f1ee2f614a1ae3759052cc5dac3f7266b271ba
size 42662
@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:513a8d3815582253be1eecf22a7726c7917c9e83e7465aa5e7b90ef2d7944c1e
size 49713
@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:69ddd3c435d8c50a231bdc128c059127219d35624a16912579ce0f878830a274
size 148724
@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:680e82d9b7877d868e734783ac7d9dc9c615d7c53a80b816e7529cbda6e3be0d
size 149586
@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:1a419004009267be00c3bb862408e82639e2fb45f6951e77da9309b1245f046d
size 103648
@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:5a6a0b062ae788f675ada0f9011ff70dea366bf36c6b5d5a13a5bd909a03bc6c
size 104605
@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:3d6cd51861f45a9e393eb3194ee7224a094646ce4385f2aa8ecb1be404bbaa6d
size 87898
@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:c96db7daacd17e38fb6d0d74cc9de51f52b0c17fb2c02c2c162d8384ca1ab6d2
size 94243
@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:31369bff674e454cb3cacdcb7a33efe035c838e4d09b549ba07979597d74a744
size 49368
@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:7cc94abaa65358e0cf82a0635b0aaa5f7858f0a765b3ddf0f8b647cba493cfe6
size 58249