Skip to content

Commit c222247

Browse files
Add colors for nm cmds
1 parent 8edd12f commit c222247

2 files changed

Lines changed: 17 additions & 2 deletions

File tree

tui/src/state.rs

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -332,7 +332,11 @@ impl AppState {
332332
node.name,
333333
indicator
334334
))
335-
.style(self.theme.cmd_color())
335+
.style(if self.multi_select && !node.multi_select {
336+
self.theme.nm_cmd_color()
337+
} else {
338+
self.theme.cmd_color()
339+
})
336340
.patch_style(style)
337341
}
338342
},
@@ -347,7 +351,11 @@ impl AppState {
347351
} else {
348352
Line::from(format!("{} ", node.task_list))
349353
.alignment(Alignment::Right)
350-
.style(self.theme.cmd_color())
354+
.style(if self.multi_select && !node.multi_select {
355+
self.theme.nm_cmd_color()
356+
} else {
357+
self.theme.cmd_color()
358+
})
351359
.bold()
352360
}
353361
},

tui/src/theme.rs

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,13 @@ impl Theme {
2828
}
2929
}
3030

31+
pub fn nm_cmd_color(&self) -> Color {
32+
match self {
33+
Theme::Default => Color::DarkGray,
34+
Theme::Compatible => Color::DarkGray,
35+
}
36+
}
37+
3138
pub fn tab_color(&self) -> Color {
3239
match self {
3340
Theme::Default => Color::Rgb(255, 255, 85),

0 commit comments

Comments
 (0)