diff --git a/crates/data/src/tabs.rs b/crates/data/src/tabs.rs index 565626c..b48c6f4 100644 --- a/crates/data/src/tabs.rs +++ b/crates/data/src/tabs.rs @@ -629,11 +629,7 @@ impl Tab { .px(metrics.dense_padding_x) .pr(metrics.plate_inset) .rounded(theme.radius.control) - .when(selected, |strip_tab| { - strip_tab - .bg(theme.colors.muted) - .hover(|strip_tab| strip_tab.bg(theme.colors.muted_hover)) - }), + .when(selected, |strip_tab| strip_tab.bg(theme.colors.muted_hover)), }) .when_some(self.lead.take(), |strip_tab, lead| strip_tab.child(lead)) .child(self.label.clone()) diff --git a/crates/layout/src/panel.rs b/crates/layout/src/panel.rs index afc38fa..c4898a7 100644 --- a/crates/layout/src/panel.rs +++ b/crates/layout/src/panel.rs @@ -109,7 +109,10 @@ impl RenderOnce for Panel { .flex_1() .min_w_0() .h_full() + // the titlebar's centered tabs leave slack above the strip's + // bottom edge, so the top gutter is narrower to even out. .p_2() + .pt_1() .bg(app_background) .child(row) } diff --git a/crates/layout/src/titlebar.rs b/crates/layout/src/titlebar.rs index 8b45c42..458bcac 100644 --- a/crates/layout/src/titlebar.rs +++ b/crates/layout/src/titlebar.rs @@ -7,7 +7,7 @@ use gpui::prelude::FluentBuilder as _; use gpui::{ AnyElement, App, ElementId, InteractiveElement as _, IntoElement, ParentElement, RenderOnce, - SharedString, Styled as _, Window, div, + SharedString, Styled as _, Window, }; use gpui_native_theme::{ActiveTheme as _, Size, TRAFFIC_LIGHT_PAD}; use gpui_native_utils::h_flex; @@ -80,6 +80,7 @@ impl RenderOnce for Titlebar { .flex_none() .w_full() .h(height) + .gap_2() .bg(app_background) .px(padding_x) .when(cfg!(target_os = "macos"), |bar| bar.pl(TRAFFIC_LIGHT_PAD)) @@ -96,12 +97,10 @@ impl RenderOnce for Titlebar { }) .when_some(self.tab_bar, |bar, tab_bar| { bar.child( - div() - .flex() + h_flex() .flex_1() .min_w_0() .h_full() - .items_center() .overflow_hidden() .when(cfg!(target_os = "windows"), |slot| slot.occlude()) .child(tab_bar),