Fix tab text colors
This commit is contained in:
parent
b21c25826d
commit
0edcec7c4e
2 changed files with 12 additions and 3 deletions
|
@ -584,12 +584,18 @@ impl Item for Editor {
|
||||||
.flex()
|
.flex()
|
||||||
.flex_row()
|
.flex_row()
|
||||||
.items_center()
|
.items_center()
|
||||||
.text_color(gpui::white())
|
.gap_2()
|
||||||
.child(self.title(cx).to_string())
|
.child(self.title(cx).to_string())
|
||||||
.children(detail.and_then(|detail| {
|
.children(detail.and_then(|detail| {
|
||||||
let path = path_for_buffer(&self.buffer, detail, false, cx)?;
|
let path = path_for_buffer(&self.buffer, detail, false, cx)?;
|
||||||
let description = path.to_string_lossy();
|
let description = path.to_string_lossy();
|
||||||
Some(util::truncate_and_trailoff(&description, MAX_TAB_TITLE_LEN))
|
|
||||||
|
Some(
|
||||||
|
div()
|
||||||
|
.text_color(theme.colors().text_muted)
|
||||||
|
.text_xs()
|
||||||
|
.child(util::truncate_and_trailoff(&description, MAX_TAB_TITLE_LEN)),
|
||||||
|
)
|
||||||
})),
|
})),
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
|
@ -1361,13 +1361,15 @@ impl Pane {
|
||||||
let label = item.tab_content(Some(detail), cx);
|
let label = item.tab_content(Some(detail), cx);
|
||||||
let close_icon = || IconElement::new(Icon::Close).color(IconColor::Muted);
|
let close_icon = || IconElement::new(Icon::Close).color(IconColor::Muted);
|
||||||
|
|
||||||
let (tab_bg, tab_hover_bg, tab_active_bg) = match ix == self.active_item_index {
|
let (text_color, tab_bg, tab_hover_bg, tab_active_bg) = match ix == self.active_item_index {
|
||||||
false => (
|
false => (
|
||||||
|
cx.theme().colors().text_muted,
|
||||||
cx.theme().colors().tab_inactive,
|
cx.theme().colors().tab_inactive,
|
||||||
cx.theme().colors().ghost_element_hover,
|
cx.theme().colors().ghost_element_hover,
|
||||||
cx.theme().colors().ghost_element_active,
|
cx.theme().colors().ghost_element_active,
|
||||||
),
|
),
|
||||||
true => (
|
true => (
|
||||||
|
cx.theme().colors().text,
|
||||||
cx.theme().colors().tab_active,
|
cx.theme().colors().tab_active,
|
||||||
cx.theme().colors().element_hover,
|
cx.theme().colors().element_hover,
|
||||||
cx.theme().colors().element_active,
|
cx.theme().colors().element_active,
|
||||||
|
@ -1397,6 +1399,7 @@ impl Pane {
|
||||||
.flex()
|
.flex()
|
||||||
.items_center()
|
.items_center()
|
||||||
.gap_1p5()
|
.gap_1p5()
|
||||||
|
.text_color(text_color)
|
||||||
.children(if item.has_conflict(cx) {
|
.children(if item.has_conflict(cx) {
|
||||||
Some(
|
Some(
|
||||||
IconElement::new(Icon::ExclamationTriangle)
|
IconElement::new(Icon::ExclamationTriangle)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue