summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorextrawurst <mail@rusticorn.com>2024-02-18 12:58:54 +0100
committerextrawurst <776816+extrawurst@users.noreply.github.com>2024-02-18 13:54:55 +0100
commitf4a7034a9a98a0c2f3592913689a303f823c8118 (patch)
treee12c0a41a3136009af339a3428e633178bcf38fa /src
parente1f243d8fbe50f327895fb14dfb310a24dae1c83 (diff)
allow customizing color of focused title bar
Diffstat (limited to 'src')
-rw-r--r--src/app.rs2
-rw-r--r--src/ui/style.rs6
2 files changed, 6 insertions, 2 deletions
diff --git a/src/app.rs b/src/app.rs
index 6fdfc424..76c5b3c2 100644
--- a/src/app.rs
+++ b/src/app.rs
@@ -1132,7 +1132,7 @@ impl App {
&self.repo_path_text,
text_area.width as usize,
),
- self.theme.title(true),
+ self.theme.title(false),
)]))
.alignment(Alignment::Right),
text_area,
diff --git a/src/ui/style.rs b/src/ui/style.rs
index c54350d7..7310721f 100644
--- a/src/ui/style.rs
+++ b/src/ui/style.rs
@@ -33,6 +33,7 @@ pub struct Theme {
tag_fg: Color,
branch_fg: Color,
line_break: String,
+ block_title_focused: Color,
}
impl Theme {
@@ -50,7 +51,9 @@ impl Theme {
pub fn title(&self, focused: bool) -> Style {
if focused {
- Style::default().add_modifier(Modifier::BOLD)
+ Style::default()
+ .fg(self.block_title_focused)
+ .add_modifier(Modifier::BOLD)
} else {
Style::default().fg(self.disabled_fg)
}
@@ -342,6 +345,7 @@ impl Default for Theme {
tag_fg: Color::LightMagenta,
branch_fg: Color::LightYellow,
line_break: "ΒΆ".to_string(),
+ block_title_focused: Color::Reset,
}
}
}