Add Cmd+P all-surface search option

LA
9mo ago
+798-14

Summary

  • add a Settings toggle for letting Cmd+P search all surfaces instead of only workspace rows
  • keep the empty switcher list workspace-first, but include matching surface rows once a query is typed
  • cover the switcher fingerprint change and add a UI test for cross-workspace surface search

Testing

  • ./scripts/setup.sh
  • ./scripts/reload.sh --tag task-cmd-p-search-all-surfaces
  • gh workflow run test-e2e.yml --repo manaflow-ai/cmux -f ref=task-cmd-p-search-all-surfaces -f test_filter="CommandPaletteAllSurfacesUITests" -f record_video=true

Task

  • cmd p add option in settings to search through not just workspaces, but all surfaces.

Summary by cubic

Adds a Settings toggle to let Cmd+P search all surfaces across workspaces, not just workspace rows. The switcher now includes Terminal, Browser, and Markdown surfaces when you type, with clear labels and updated placeholder/empty text.

  • New Features
    • Settings: new “Command Palette Searches All Surfaces” toggle (default off) with on/off subtitles; stored via @AppStorage("commandPalette.switcherSearchAllSurfaces").
    • Search behavior: empty list stays workspace-first; once a query is typed and the toggle is on, includes matching surfaces across workspaces with kind labels; surface commands use switcher.surface.<id> and focus the target surface.
    • Localization: added kind labels and new placeholder/empty strings for both English and Japanese.
    • Fingerprint and indexing: switcher fingerprint now includes surface ids, names, kind labels, and metadata; surfaces index directories, branches, and ports; stable panel ordering helper added.
    • Tests: new UI test for cross-workspace surface search via Cmd+P; fingerprint unit tests expanded.