Skip to content

agent_ui: Match project name in archive-view search - #58214

Merged
danilo-leal merged 2 commits into
zed-industries:mainfrom
KevinLaveto:pr/archive-view-project-match
Jun 13, 2026
Merged

agent_ui: Match project name in archive-view search#58214
danilo-leal merged 2 commits into
zed-industries:mainfrom
KevinLaveto:pr/archive-view-project-match

Conversation

@KevinLaveto

@KevinLaveto KevinLaveto commented Jun 1, 2026

Copy link
Copy Markdown
Contributor

Summary:

When you have a lot of projects open, finding a thread from a specific
project in the archive ("Search all threads") view is slower than it
should be — the filter only matches the thread title, so you have to
remember or scan titles to find what belongs to which project. Folder
names are a quicker mental handle than thread titles, especially across
many projects.

This PR makes the archive filter also try matching the basename of each
of the thread's worktree paths. Title matches still take precedence and
get the highlight positions; project-name matches just include the row.
Same fuzzy_match_positions contiguous substring matcher already used
for titles, so the matching feel is consistent.

Example: typing my-laravel-project now surfaces every thread that lives
under a project named my-laravel-project, regardless of title.

Self-Review Checklist:

  • I've reviewed my own diff for quality, security, and reliability
  • Unsafe blocks (if any) have justifying comments — N/A
  • The content is consistent with the UI/UX checklist
  • Tests cover the new/changed behavior — small extension to an existing filter branch; manually verified.
  • Performance impact has been considered and is acceptable — per-row path-basename check only runs when the title didn't match.

Release Notes:

  • Improved the archive "Search all threads" view so you can filter by project name, not just by thread title — handy when many projects are open.

The archive ("Search all threads") view's filter matched only the
thread title, so typing a project name (e.g. "sync-wave-studio") never
surfaced that project's threads even though the project label is shown
right under each title. The filter now also tries matching the basename
of each of the thread's worktree paths, mirroring the sidebar's
project-name match.
@cla-bot cla-bot Bot added the cla-signed The user has signed the Contributor License Agreement label Jun 1, 2026
@zed-community-bot zed-community-bot Bot added the first contribution the author's first pull request to Zed. NOTE: the label application is automated via github actions label Jun 1, 2026
@dinocosta dinocosta added area:ai Related to Agent Panel, Edit Prediction, Copilot, or other AI features area:ai/multiagent sidebar aka Threads sidebar, aka Parallel Agents and removed area:ai Related to Agent Panel, Edit Prediction, Copilot, or other AI features labels Jun 2, 2026

@danilo-leal danilo-leal left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you so much!

@danilo-leal
danilo-leal enabled auto-merge June 13, 2026 16:28
@danilo-leal
danilo-leal added this pull request to the merge queue Jun 13, 2026
Merged via the queue into zed-industries:main with commit df9c9f0 Jun 13, 2026
32 checks passed
This was referenced Jun 18, 2026
jolutz pushed a commit to jolutz/zed that referenced this pull request Aug 8, 2026
…8214)

Summary:

When you have a lot of projects open, finding a thread from a specific
project in the archive ("Search all threads") view is slower than it
should be — the filter only matches the thread title, so you have to
remember or scan titles to find what belongs to which project. Folder
names are a quicker mental handle than thread titles, especially across
many projects.

This PR makes the archive filter also try matching the basename of each
of the thread's worktree paths. Title matches still take precedence and
get the highlight positions; project-name matches just include the row.
Same `fuzzy_match_positions` contiguous substring matcher already used
for titles, so the matching feel is consistent.

Example: typing `my-laravel-project` now surfaces every thread that
lives
under a project named `my-laravel-project`, regardless of title.

Self-Review Checklist:

- [x] I've reviewed my own diff for quality, security, and reliability
- [x] Unsafe blocks (if any) have justifying comments — N/A
- [x] The content is consistent with the [UI/UX
checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)
- [x] Tests cover the new/changed behavior — small extension to an
existing filter branch; manually verified.
- [x] Performance impact has been considered and is acceptable — per-row
path-basename check only runs when the title didn't match.

Release Notes:

- Improved the archive "Search all threads" view so you can filter by
project name, not just by thread title — handy when many projects are
open.

---------

Co-authored-by: Danilo Leal <daniloleal09@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:ai/multiagent sidebar aka Threads sidebar, aka Parallel Agents cla-signed The user has signed the Contributor License Agreement first contribution the author's first pull request to Zed. NOTE: the label application is automated via github actions

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants