Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions src/theme.rs
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,7 @@ pub struct Theme {
pub overlay_highlight_fg: Color,
pub overlay_bg: Color,
pub editing_fg: Color,
pub editing_title: Color,
pub overlay_text: Color,
}

Expand All @@ -121,6 +122,7 @@ impl ThemeName {
overlay_highlight_fg: Color::Black,
overlay_bg: Color::Black,
editing_fg: Color::White,
editing_title: Color::Black,
overlay_text: Color::White,
},
Self::Matrix => Theme {
Expand All @@ -141,6 +143,7 @@ impl ThemeName {
overlay_highlight_fg: Color::Black,
overlay_bg: Color::Black,
editing_fg: Color::LightGreen,
editing_title: Color::Green,
overlay_text: Color::LightGreen,
},
Self::CyanCrush => Theme {
Expand All @@ -161,6 +164,7 @@ impl ThemeName {
overlay_highlight_fg: Color::Cyan,
overlay_bg: Color::Black,
editing_fg: Color::LightMagenta,
editing_title: Color::Cyan,
overlay_text: Color::Cyan,
},
Self::Embercore => Theme {
Expand All @@ -181,6 +185,7 @@ impl ThemeName {
overlay_highlight_fg: Color::Yellow,
overlay_bg: Color::Black,
editing_fg: Color::Yellow,
editing_title: Color::Red,
overlay_text: Color::LightRed,
},
Self::ToxicOrchid => Theme {
Expand All @@ -201,6 +206,7 @@ impl ThemeName {
overlay_highlight_fg: Color::LightMagenta,
overlay_bg: Color::Black,
editing_fg: Color::LightMagenta,
editing_title: Color::LightGreen,
overlay_text: Color::LightGreen,
},
Self::Coldfire => Theme {
Expand All @@ -221,6 +227,7 @@ impl ThemeName {
overlay_highlight_fg: Color::LightBlue,
overlay_bg: Color::Black,
editing_fg: Color::LightBlue,
editing_title: Color::LightRed,
overlay_text: Color::LightRed,
},
}
Expand Down
6 changes: 5 additions & 1 deletion src/ui.rs
Original file line number Diff line number Diff line change
Expand Up @@ -224,7 +224,11 @@ fn draw(f: &mut ratatui::Frame<'_>, app: &App) {
}))
.title(Span::styled(
input_title,
Style::default().fg(theme.input_title),
Style::default().fg(if editing {
theme.editing_title
} else {
theme.input_title
}),
));

let input = Paragraph::new(app.input()).block(input_block);
Expand Down