feat: use vim mode in select

This commit is contained in:
iff 2024-12-07 02:13:35 +01:00
parent 0ef6ea1ff9
commit 29c79a5638
2 changed files with 3 additions and 1 deletions

View file

@ -121,6 +121,7 @@ pub fn cnf(data: &mut Data) {
eprintln!("{}", msg);
eprintln!("{}", hint);
let package = Select::new("\n", packages)
.with_vim_mode(true)
.without_help_message()
.with_render_config(render_config)
.without_filtering()

View file

@ -100,7 +100,7 @@ pub fn select_candidate(data: &mut Data) {
let confirm = format!("[{}]", t!("confirm-yes")).green();
let hint = format!(
"{} {} {}",
"[↑/↓]".blue(),
"[/↑] / [j/k]".blue(),
confirm,
"[Ctrl+C]".red()
);
@ -109,6 +109,7 @@ pub fn select_candidate(data: &mut Data) {
let ans = Select::new("\n", highlight_candidates.clone())
.with_page_size(1)
.with_vim_mode(true)
.without_filtering()
.without_help_message()
.with_render_config(render_config)