Skip to content

Commit

Permalink
ux improvements
Browse files Browse the repository at this point in the history
  • Loading branch information
adamperkowski committed Dec 4, 2024
1 parent dff4b76 commit 49a702c
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/tui.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@ use ratatui::{
};
use tachyonfx::{fx, Duration as FxDuration, Effect, EffectRenderer, Shader};

const KEYBINDS: &str = " [q] quit [s] sync [f] filter updated [/] search ";
const KEYBINDS: &str = " [q]uit [s]ync [f]ilter updated [/] search ";
const KEYBINDS_SELECTED: &str = " [q]uit [s]ync [enter] take [n]uke [f]ilter updated [/] search ";
const KEYBINDS_SEARCH: &str = " [esc] cancel [enter] search ";

const PACKAGE_ICON: &str = " ";
Expand Down Expand Up @@ -147,6 +148,10 @@ impl AppState {
fn draw_searchbar(&self, frame: &mut Frame, area: Rect) {
let title = if self.is_syncing {
" synchronizing... "
} else if !self.search_input.is_empty() {
" search "
} else if self.filter_updated {
" filtered "
} else {
" nvrs "
};
Expand Down

0 comments on commit 49a702c

Please sign in to comment.