Repository navigation
feat(terminal): find bar over the scrollback - #843
Open
opticon454 wants to merge 1 commit into
Open
opticon454 wants to merge 1 commit into
opticon454 wants to merge 1 commit into
Conversation
Ctrl/Cmd+Shift+F opens a find bar over the terminal's scrollback, using @xterm/addon-search. On by default (terminalFindEnabled, App Settings > Scrolling & rendering). The chord is the rebindable registry entry find-in-terminal, so it shows in the Ctrl+? overlay. Esc inside the bar closes only the bar. It stays off while the tile grid owns the terminal, whose parked main terminal is not the focused tile.
Owner
|
Thanks for splitting this out of #842 so quickly. The PR adds a I also drove the bar in headless Chromium against a dev server. A few edges need changes before this can merge. Needs a change
Smaller things (fine in this round or at merge time)
Once items 1 to 5 are fixed this is ready to merge, and #842 can rebase onto it. |
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.
What
A find bar over the terminal's scrollback.
Ctrl+Shift+F(Cmd+Shift+Fon a Mac) opens it, type to search,EnterandShift+Enterfor the next and previous match with a count,Escto close. It uses@xterm/addon-search, bundled like the other xterm addons. On by default;terminalFindEnabledin App Settings > Scrolling & rendering (an absent key means on).This is the find bar half of #842, split out as the maintainer asked. It does not depend on the saved history store.
Review items from #842 this covers
find-in-terminalentry inDEFAULT_SHORTCUTS, so it shows in theCtrl+?overlay (zh-CN label added) and in the keyboard-shortcut paragraph ofsrc/web/CLAUDE.md. Like copy-selection it is dispatched byisTerminalFindChord()and absent fromSHORTCUT_ACTIONS, so with the setting off the chord reaches the terminal untouched.#terminalFindBar, so Esc in the bar closes the bar and not App Settings or a side panel behind it.terminalFindEnabled()is false while_tilesOwnTerminal()is true: the chord is not taken and the bar does not open.Known limit
It searches what the browser holds. A CLI that keeps its older text itself (Claude's fullscreen view) has only the screen in the terminal, so only what is on screen is found. The Settings text and
docs/wiki/Settings-Reference.mdsay so.Testing
test/terminal-find.test.ts(new).npm run typecheck, eslint andformat:checkare clean. Fullnpm teston this branch: the zh-CN label test failed on the first run and is fixed here; the only other failure istest/remote-pane-command-shell.test.ts"starts /bin/sh when SHELL is unset", which fails identically on a cleanupstream/master. Driven in headless Chromium against a running server: the chord opens the bar, the count reads1 of 80, Esc in the bar leaves App Settings open, the overlay lists it, and the bar stays closed while the tile grid owns the terminal.No changeset added (generated at release).