more doc string and reexport fixes

This commit is contained in:
🪞👃🪞 2024-07-12 20:32:11 +03:00
parent 107e38278e
commit dc1f5f4a17
13 changed files with 37 additions and 48 deletions

View file

@ -1,11 +1,11 @@
use crate::{core::*, view::*};
/// Command palette.
pub struct HelpModal {
cursor: usize,
search: Option<String>,
exited: bool,
}
impl HelpModal {
pub fn new () -> Self {
Self { cursor: 0, search: None, exited: false }
@ -52,7 +52,7 @@ render!(HelpModal |self, buf, area|{
format!("{:?}", command.0).blit(buf, x, y, Some(Style::default().white().bold()))?;
command.2.blit(buf, x + 11, y, Some(Style::default().white().bold()))?;
command.3.blit(buf, x + 26, y, Some(Style::default().white().dim()))?;
} else if let Some(command) = crate::control::KEYMAP.get((i as usize) - crate::control::KEYMAP_FOCUS.len()) {
} else if let Some(command) = crate::control::KEYMAP_GLOBAL.get((i as usize) - crate::control::KEYMAP_FOCUS.len()) {
format!("{:?}", command.0).blit(buf, x, y, Some(Style::default().white().bold()))?;
command.2.blit(buf, x + 11, y, Some(Style::default().white().bold()))?;
command.3.blit(buf, x + 26, y, Some(Style::default().white().dim()))?;