Add vim-style navigation for CLI option selection (#7784)

## Summary

Support "j" and "k" keys as aliases for "down" and "up" so vim users
feel loved. Only support these keys when the selection is not
searchable.

## Testing
- env -u NO_COLOR TERM=xterm-256color cargo test -p codex-tui


------
[Codex
Task](https://chatgpt.com/codex/tasks/task_i_693771b53bc8833088669060dfac2083)
This commit is contained in:
Bryant Rolfe 2025-12-09 14:41:10 -08:00 committed by GitHub
parent 05e546ee1f
commit 225a5f7ffb
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -284,6 +284,11 @@ impl BottomPaneView for ListSelectionView {
modifiers: KeyModifiers::NONE,
..
} /* ^P */ => self.move_up(),
KeyEvent {
code: KeyCode::Char('k'),
modifiers: KeyModifiers::NONE,
..
} if !self.is_searchable => self.move_up(),
KeyEvent {
code: KeyCode::Down,
..
@ -298,6 +303,11 @@ impl BottomPaneView for ListSelectionView {
modifiers: KeyModifiers::NONE,
..
} /* ^N */ => self.move_down(),
KeyEvent {
code: KeyCode::Char('j'),
modifiers: KeyModifiers::NONE,
..
} if !self.is_searchable => self.move_down(),
KeyEvent {
code: KeyCode::Backspace,
..