Skip to content

feat(search): canvas-wide multi-source search (Cmd+Shift+F)#3

Merged
PaulHorn merged 5 commits into
mainfrom
feat/canvas-wide-search
Apr 20, 2026
Merged

feat(search): canvas-wide multi-source search (Cmd+Shift+F)#3
PaulHorn merged 5 commits into
mainfrom
feat/canvas-wide-search

Conversation

@PaulHorn
Copy link
Copy Markdown
Contributor

Summary

  • Rewrite Global Search from "find in open editor files" to a unified lookup across workspace files, live terminal scrollback, and open panel titles/paths. Rebinds to Cmd+Shift+F (moved toggleFileExplorer off that slot to Cmd+Shift+X to avoid the collision that silently shadowed the search).
  • Results are grouped by source and ranked with recent-focus first — the currently-focused panel always wins, then creation order, then match quality. File content hits come from the existing fsSearch main handler; terminal scrollback hits read the live xterm buffer for every terminal panel.
  • Visual pass to match the Spotlight look the user asked for: rounded-3xl, brighter white/20 outline, backdrop blur, offset from the top, bolder input text, bolder magnifying-glass icon, type-colored circular icon tiles on each row, inset selection highlight, section dividers inset with mx-5 (not full width).

Test plan

  • Cmd+Shift+F opens the search overlay (was being eaten by toggleFileExplorer; collision is fixed).
  • Typing 2+ chars returns hits from files, terminal scrollback, and open panels.
  • Enter on a file hit reuses an existing editor panel if one already targets that path, otherwise creates one and focuses it.
  • Enter on a canvas panel centers it; Enter on a dock panel (git / file explorer) reveals that zone and activates the tab.
  • Cmd+Shift+X now toggles the file explorer.
  • Escape closes the overlay; Cmd+F inside an editor still invokes Monaco's find-in-file (shortcut is intercepted in capture phase only for Cmd+Shift+F).

🤖 Generated with Claude Code

Paul Horn added 5 commits April 20, 2026 15:40
Rewrite Global Search from "find in open editor files" to a unified
lookup across workspace files, live terminal scrollback, and open
panel titles/paths. Rebind to Cmd+Shift+F (was Cmd+Shift+H) so the
gesture matches muscle memory from other editors; capture-phase
dispatch keeps the shortcut working even when Monaco or xterm has
focus.

Results are scored with open panels and focused nodes ranked first,
then terminals, then fsSearch file hits. Grouped sections render
in-place, Enter opens the relevant file/panel and (for file hits)
reuses an existing editor panel when one already targets that file.
…ision

`globalSearch` was bound to Cmd+Shift+F in this branch to match the
find-in-files standard, but `toggleFileExplorer` has held that binding
historically. The shortcut matcher iterates SHORTCUT_ACTIONS in order
and returned `toggleFileExplorer` first, so pressing Cmd+Shift+F only
toggled the explorer and the search overlay never opened.

Rebind `toggleFileExplorer` to Cmd+Shift+X. No persistence means
existing users pick up the new default on next launch.
The previous layout wrapped a bordered input inside a bordered modal,
which produced a visible "box in box" outline (see user report). Merge
the input into the modal surface itself: one rounded-2xl pill with a
leading magnifying-glass icon, transparent input, and a subtle
backdrop blur. Matches the macOS Spotlight gesture the user was going
for and drops noise at the same time.
…, inset dividers

Visual pass after user feedback on the first cut:

- Outer container: rounded-3xl, brighter border (white/20) and a
  heavier shadow so the overlay reads clearly against any background,
  matching the Apple Spotlight look the user referenced.
- Input: taller row (h-14), bolder text weight (font-medium), bolder
  magnifying-glass icon.
- Results: type-aware colored icon tiles on the left (file / terminal /
  per-panel-type), bolder primary line, secondary line kept muted.
- Rows: 2px inset from the container edges with rounded highlight so
  the selection pill no longer bleeds to the walls.
- Dividers: between sections only, inset with mx-5 instead of full
  width, so the result list doesn't feel segmented.
…ay down

Section headers ("TERMINAL OUTPUT" etc) became redundant once each row
had a type-colored icon tile — removed them along with the now-unused
sectionLabel map. Kept the inset divider between sections so the eye
still gets a beat between result groups.

Icon tiles: rounded-md → rounded-full for a softer, badge-like shape
that matches the overall pill aesthetic.

Overlay position: pt-20 → pt-40 so it opens lower on the screen
instead of hugging the top bar.
@PaulHorn PaulHorn force-pushed the feat/canvas-wide-search branch from e0a4e8a to c90c678 Compare April 20, 2026 21:39
@PaulHorn PaulHorn merged commit 2574da0 into main Apr 20, 2026
3 checks passed
@PaulHorn PaulHorn deleted the feat/canvas-wide-search branch April 20, 2026 21:43
@PaulHorn PaulHorn mentioned this pull request Apr 21, 2026
3 tasks
PaulHorn added a commit that referenced this pull request Apr 21, 2026
First minor release since the open-source drop. See CHANGELOG.md for
the full narrative.

Headline themes:
 - Unified Spotlight-style overlays (command palette, canvas search,
   panel switcher, saved layouts, MCP editor) with one visual language.
 - Startup resilience — shell fallback with on-PTY banner, git-monitor
   no longer crashes main on unregistered roots, crash-report dialog
   can't re-show itself on every launch.
 - Papercuts — scratch-editor buffer persistence, tab-bar icon cues,
   editor path breadcrumb, stale git branch list refresh, panel
   switcher masonry grid.

13 PRs between v0.2.18 and this tag (#3#5, #7#15). CI green on
ubuntu / macos / windows for every merged PR.

Co-authored-by: Paul Horn <paul.p.w.horn@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant