feat(coding-agent): add named-only filter toggle to /resume picker (#1128)
Adds Ctrl+N toggle to filter sessions by named-only vs all in the /resume picker. - Add NameFilter type and filtering logic to session-selector-search.ts - Add toggleSessionNamedFilter app keybinding (default: ctrl+n) - Show Name: All/Named state in header - Empty state mentions toggle keybinding as escape hatch - Export hasSessionName() to avoid duplication Co-authored-by: warren <warren.winter@gmail.com>
This commit is contained in:
@@ -3,6 +3,7 @@
|
||||
*/
|
||||
|
||||
import { ProcessTerminal, TUI } from "@mariozechner/pi-tui";
|
||||
import { KeybindingsManager } from "../core/keybindings.js";
|
||||
import type { SessionInfo, SessionListProgress } from "../core/session-manager.js";
|
||||
import { SessionSelectorComponent } from "../modes/interactive/components/session-selector.js";
|
||||
|
||||
@@ -15,6 +16,7 @@ export async function selectSession(
|
||||
): Promise<string | null> {
|
||||
return new Promise((resolve) => {
|
||||
const ui = new TUI(new ProcessTerminal());
|
||||
const keybindings = KeybindingsManager.create();
|
||||
let resolved = false;
|
||||
|
||||
const selector = new SessionSelectorComponent(
|
||||
@@ -39,7 +41,7 @@ export async function selectSession(
|
||||
process.exit(0);
|
||||
},
|
||||
() => ui.requestRender(),
|
||||
{ showRenameHint: false },
|
||||
{ showRenameHint: false, keybindings },
|
||||
);
|
||||
|
||||
ui.addChild(selector);
|
||||
|
||||
Reference in New Issue
Block a user