highlight borders of focused components

This commit is contained in:
🪞👃🪞 2024-10-10 08:51:28 +03:00
parent 3bf475d15e
commit 47b10d2275
2 changed files with 15 additions and 3 deletions

View file

@ -210,7 +210,11 @@ impl<'a> Content for VerticalArranger<'a, Tui> {
.bg(Color::Rgb(28, 35, 25))
.border(Lozenge(Style::default()
.bg(Color::Rgb(40, 50, 30))
.fg(Color::Rgb(70, 80, 50))))
.fg(if self.0.focused {
Color::Rgb(100, 110, 40)
} else {
Color::Rgb(70, 80, 50)
})))
}
}
impl<'a> Widget for VerticalArrangerGrid<'a> {

View file

@ -52,7 +52,11 @@ impl Content for PhrasePool<Tui> {
.bg(Color::Rgb(28, 35, 25))
.border(Lozenge(Style::default()
.bg(Color::Rgb(40, 50, 30))
.fg(Color::Rgb(70, 80, 50))))
.fg(if self.focused {
Color::Rgb(100, 110, 40)
} else {
Color::Rgb(70, 80, 50)
})))
}
}
impl Handle<Tui> for PhrasePool<Tui> {
@ -159,7 +163,11 @@ impl Content for PhraseEditor<Tui> {
.bg(Color::Rgb(40, 50, 30))
.border(Lozenge(Style::default()
.bg(Color::Rgb(40, 50, 30))
.fg(Color::Rgb(70, 80, 50))))
.fg(if self.focused {
Color::Rgb(100, 110, 40)
} else {
Color::Rgb(70, 80, 50)
})))
}
}
impl Handle<Tui> for PhraseEditor<Tui> {