help: display all keybinds

This commit is contained in:
🪞👃🪞 2025-04-30 21:50:35 +03:00
parent 9bc4e3fb5f
commit 9f30f77aee
4 changed files with 25 additions and 29 deletions

View file

@ -53,7 +53,7 @@ pub struct Tek {
// Modal overlay
pub modal: Option<Modal>,
// Input keymap
pub keys: InputMap<'static, Self, TekCommand, TuiIn, SourceIter<'static>>
pub keys: InputMap<'static, Self, TekCommand, TuiIn, TokenIter<'static>>
}
impl Tek {

View file

@ -41,8 +41,8 @@ impl Tek {
Bsp::s(Tui::bold(true, "tek!"), Bsp::s("", Map::south(1, options, option)))
}
fn view_modal_help (&self) -> impl Content<TuiOut> {
let bindings = ||TokenIter::new(include_str!("../../../config/keys_groovebox.edn"))
fn view_modal_help (&self) -> impl Content<TuiOut> + use<'_> {
let bindings = ||self.keys.layers.iter().flat_map(|a|a.1)
.filter_map(|x|if let Value::Exp(_, iter)=x.value{
Some(iter)
} else {