fix(cli): dismiss '?' shortcuts help on hotkeys and active states (#18583)

Co-authored-by: jacob314 <jacob314@gmail.com>
This commit is contained in:
Dmitry Lyalin
2026-02-12 11:35:40 -05:00
committed by GitHub
parent 2ca183ffc9
commit f603f4a12b
8 changed files with 280 additions and 15 deletions
@@ -0,0 +1,12 @@
/**
* @license
* Copyright 2025 Google LLC
* SPDX-License-Identifier: Apache-2.0
*/
import { Command, keyMatchers } from '../keyMatchers.js';
import type { Key } from '../hooks/useKeypress.js';
export function shouldDismissShortcutsHelpOnHotkey(key: Key): boolean {
return Object.values(Command).some((command) => keyMatchers[command](key));
}