migrate chat_ui, workspace, and nip29_ui to bezel theme tokens
This commit is contained in:
+46
-50
@@ -904,8 +904,8 @@ impl ChatPanel {
|
|||||||
.h_10()
|
.h_10()
|
||||||
.justify_center()
|
.justify_center()
|
||||||
.text_sm()
|
.text_sm()
|
||||||
.bg(cx.theme().elevated_surface_background)
|
.bg(cx.theme().surface_raised)
|
||||||
.rounded(cx.theme().radius)
|
.rounded(px(theme::panel_radius()))
|
||||||
.child("Message isn't traced yet"),
|
.child("Message isn't traced yet"),
|
||||||
)
|
)
|
||||||
})
|
})
|
||||||
@@ -919,8 +919,8 @@ impl ChatPanel {
|
|||||||
.h_7()
|
.h_7()
|
||||||
.px_2()
|
.px_2()
|
||||||
.gap_2()
|
.gap_2()
|
||||||
.bg(cx.theme().elevated_surface_background)
|
.bg(cx.theme().surface_raised)
|
||||||
.rounded(cx.theme().radius)
|
.rounded(px(theme::control_radius()))
|
||||||
.text_sm()
|
.text_sm()
|
||||||
.child(div().size_1p5().rounded_full().bg(gpui::green()))
|
.child(div().size_1p5().rounded_full().bg(gpui::green()))
|
||||||
.child(SharedString::from(url.to_string())),
|
.child(SharedString::from(url.to_string())),
|
||||||
@@ -951,8 +951,8 @@ impl ChatPanel {
|
|||||||
.h_7()
|
.h_7()
|
||||||
.px_2()
|
.px_2()
|
||||||
.gap_2()
|
.gap_2()
|
||||||
.bg(cx.theme().elevated_surface_background)
|
.bg(cx.theme().surface_raised)
|
||||||
.rounded(cx.theme().radius)
|
.rounded(px(theme::control_radius()))
|
||||||
.text_sm()
|
.text_sm()
|
||||||
.child(div().size_1p5().rounded_full().bg(gpui::green()))
|
.child(div().size_1p5().rounded_full().bg(gpui::green()))
|
||||||
.child(SharedString::from(url.to_string())),
|
.child(SharedString::from(url.to_string())),
|
||||||
@@ -975,7 +975,7 @@ impl ChatPanel {
|
|||||||
svg()
|
svg()
|
||||||
.path("brand/coop.svg")
|
.path("brand/coop.svg")
|
||||||
.size_12()
|
.size_12()
|
||||||
.text_color(cx.theme().ghost_element_background_alt),
|
.text_color(cx.theme().surface_raised),
|
||||||
)
|
)
|
||||||
.message(PRIVATE_NOTICE)
|
.message(PRIVATE_NOTICE)
|
||||||
.into_any_element()
|
.into_any_element()
|
||||||
@@ -991,13 +991,13 @@ impl ChatPanel {
|
|||||||
.justify_center()
|
.justify_center()
|
||||||
.text_center()
|
.text_center()
|
||||||
.text_xs()
|
.text_xs()
|
||||||
.text_color(cx.theme().text_placeholder)
|
.text_color(cx.theme().text_faint)
|
||||||
.line_height(relative(1.3))
|
.line_height(relative(1.3))
|
||||||
.child(
|
.child(
|
||||||
svg()
|
svg()
|
||||||
.path("brand/coop.svg")
|
.path("brand/coop.svg")
|
||||||
.size_12()
|
.size_12()
|
||||||
.text_color(cx.theme().ghost_element_active),
|
.text_color(cx.theme().element_active),
|
||||||
)
|
)
|
||||||
.child(PRIVATE_NOTICE)
|
.child(PRIVATE_NOTICE)
|
||||||
.into_any_element()
|
.into_any_element()
|
||||||
@@ -1020,8 +1020,8 @@ impl ChatPanel {
|
|||||||
.size_8()
|
.size_8()
|
||||||
.justify_center()
|
.justify_center()
|
||||||
.rounded_full()
|
.rounded_full()
|
||||||
.bg(cx.theme().warning_background)
|
.bg(cx.theme().warning_muted)
|
||||||
.text_color(cx.theme().warning_foreground)
|
.text_color(cx.theme().warning)
|
||||||
.child(Icon::new(IconName::Warning).small()),
|
.child(Icon::new(IconName::Warning).small()),
|
||||||
)
|
)
|
||||||
.child(
|
.child(
|
||||||
@@ -1161,7 +1161,7 @@ impl ChatPanel {
|
|||||||
.top_0()
|
.top_0()
|
||||||
.w(px(2.))
|
.w(px(2.))
|
||||||
.h_full()
|
.h_full()
|
||||||
.bg(cx.theme().border_transparent),
|
.bg(gpui::transparent_black()),
|
||||||
)
|
)
|
||||||
.overlay(self.render_actions(&id, &pk, cx))
|
.overlay(self.render_actions(&id, &pk, cx))
|
||||||
.on_mouse_down(
|
.on_mouse_down(
|
||||||
@@ -1187,10 +1187,10 @@ impl ChatPanel {
|
|||||||
return div().child(
|
return div().child(
|
||||||
img(media[0].clone())
|
img(media[0].clone())
|
||||||
.border_1()
|
.border_1()
|
||||||
.border_color(cx.theme().border_variant)
|
.border_color(cx.theme().border_faint)
|
||||||
.h(px(250.))
|
.h(px(250.))
|
||||||
.object_fit(ObjectFit::Cover)
|
.object_fit(ObjectFit::Cover)
|
||||||
.rounded(cx.theme().radius),
|
.rounded(px(theme::bubble_radius())),
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1215,8 +1215,8 @@ impl ChatPanel {
|
|||||||
img(item.clone())
|
img(item.clone())
|
||||||
.h_32()
|
.h_32()
|
||||||
.border_1()
|
.border_1()
|
||||||
.border_color(cx.theme().border_variant)
|
.border_color(cx.theme().border_faint)
|
||||||
.rounded(cx.theme().radius),
|
.rounded(px(theme::bubble_radius())),
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
@@ -1254,7 +1254,7 @@ impl ChatPanel {
|
|||||||
.line_clamp(1)
|
.line_clamp(1)
|
||||||
.child(message.preview()),
|
.child(message.preview()),
|
||||||
)
|
)
|
||||||
.hover(|this| this.bg(cx.theme().elevated_surface_background))
|
.hover(|this| this.bg(cx.theme().surface_raised))
|
||||||
.on_click({
|
.on_click({
|
||||||
let id = *id;
|
let id = *id;
|
||||||
cx.listener(move |this, _event, _window, _cx| {
|
cx.listener(move |this, _event, _window, _cx| {
|
||||||
@@ -1290,13 +1290,13 @@ impl ChatPanel {
|
|||||||
.gap_2()
|
.gap_2()
|
||||||
.py_0p5()
|
.py_0p5()
|
||||||
.px_1()
|
.px_1()
|
||||||
.rounded(cx.theme().radius)
|
.rounded(px(theme::control_radius()))
|
||||||
.text_xs()
|
.text_xs()
|
||||||
.border_1()
|
.border_1()
|
||||||
.when(has_reacted, |this| {
|
.when(has_reacted, |this| {
|
||||||
this.text_color(cx.theme().secondary_foreground)
|
this.text_color(cx.theme().text)
|
||||||
.bg(cx.theme().secondary_background)
|
.bg(cx.theme().surface_raised)
|
||||||
.border_color(cx.theme().secondary_active)
|
.border_color(cx.theme().element_active)
|
||||||
})
|
})
|
||||||
.when(!has_reacted, |this| this.border_color(cx.theme().border))
|
.when(!has_reacted, |this| this.border_color(cx.theme().border))
|
||||||
.child(emoji)
|
.child(emoji)
|
||||||
@@ -1330,7 +1330,7 @@ impl ChatPanel {
|
|||||||
div()
|
div()
|
||||||
.id(SharedString::from(id.to_hex()))
|
.id(SharedString::from(id.to_hex()))
|
||||||
.child(label)
|
.child(label)
|
||||||
.when(failed, |this| this.text_color(cx.theme().text_danger))
|
.when(failed, |this| this.text_color(cx.theme().danger_muted))
|
||||||
.when_some(reports, |this, reports| {
|
.when_some(reports, |this, reports| {
|
||||||
this.when(!pending, |this| {
|
this.when(!pending, |this| {
|
||||||
this.on_click(move |_e, window, cx| {
|
this.on_click(move |_e, window, cx| {
|
||||||
@@ -1385,9 +1385,9 @@ impl ChatPanel {
|
|||||||
.h_16()
|
.h_16()
|
||||||
.w_full()
|
.w_full()
|
||||||
.text_sm()
|
.text_sm()
|
||||||
.rounded(cx.theme().radius)
|
.rounded(px(theme::surface_radius()))
|
||||||
.bg(cx.theme().warning_background)
|
.bg(cx.theme().warning_muted)
|
||||||
.text_color(cx.theme().warning_foreground)
|
.text_color(cx.theme().warning)
|
||||||
.child(div().flex_1().w_full().text_center().child(error)),
|
.child(div().flex_1().w_full().text_center().child(error)),
|
||||||
)
|
)
|
||||||
})
|
})
|
||||||
@@ -1405,8 +1405,8 @@ impl ChatPanel {
|
|||||||
.gap_0p5()
|
.gap_0p5()
|
||||||
.p_1()
|
.p_1()
|
||||||
.w_full()
|
.w_full()
|
||||||
.rounded(cx.theme().radius)
|
.rounded(px(theme::surface_radius()))
|
||||||
.bg(cx.theme().danger_background)
|
.bg(cx.theme().danger.opacity(0.06))
|
||||||
.child(
|
.child(
|
||||||
div()
|
div()
|
||||||
.text_xs()
|
.text_xs()
|
||||||
@@ -1417,7 +1417,7 @@ impl ChatPanel {
|
|||||||
.child(
|
.child(
|
||||||
div()
|
div()
|
||||||
.text_xs()
|
.text_xs()
|
||||||
.text_color(cx.theme().danger_foreground)
|
.text_color(cx.theme().danger_muted.opacity(0.9))
|
||||||
.line_height(relative(1.25))
|
.line_height(relative(1.25))
|
||||||
.child(SharedString::from(msg.to_string())),
|
.child(SharedString::from(msg.to_string())),
|
||||||
),
|
),
|
||||||
@@ -1435,8 +1435,8 @@ impl ChatPanel {
|
|||||||
.gap_0p5()
|
.gap_0p5()
|
||||||
.p_1()
|
.p_1()
|
||||||
.w_full()
|
.w_full()
|
||||||
.rounded(cx.theme().radius)
|
.rounded(px(theme::surface_radius()))
|
||||||
.bg(cx.theme().elevated_surface_background)
|
.bg(cx.theme().surface_card)
|
||||||
.child(
|
.child(
|
||||||
div()
|
div()
|
||||||
.text_xs()
|
.text_xs()
|
||||||
@@ -1473,10 +1473,10 @@ impl ChatPanel {
|
|||||||
.right_4()
|
.right_4()
|
||||||
.top_neg_2()
|
.top_neg_2()
|
||||||
.when(cx.theme().shadow, |this| this.shadow_sm())
|
.when(cx.theme().shadow, |this| this.shadow_sm())
|
||||||
.rounded(cx.theme().radius)
|
.rounded(px(theme::surface_radius()))
|
||||||
.border_1()
|
.border_1()
|
||||||
.border_color(cx.theme().border)
|
.border_color(cx.theme().border)
|
||||||
.bg(cx.theme().background)
|
.bg(cx.theme().bg)
|
||||||
.children({
|
.children({
|
||||||
let mut items = vec![];
|
let mut items = vec![];
|
||||||
|
|
||||||
@@ -1553,7 +1553,7 @@ impl ChatPanel {
|
|||||||
img(url.as_str())
|
img(url.as_str())
|
||||||
.size_16()
|
.size_16()
|
||||||
.when(cx.theme().shadow, |this| this.shadow_lg())
|
.when(cx.theme().shadow, |this| this.shadow_lg())
|
||||||
.rounded(cx.theme().radius)
|
.rounded(px(theme::control_radius()))
|
||||||
.object_fit(ObjectFit::Cover),
|
.object_fit(ObjectFit::Cover),
|
||||||
)
|
)
|
||||||
.child(
|
.child(
|
||||||
@@ -1611,10 +1611,10 @@ impl ChatPanel {
|
|||||||
.child(
|
.child(
|
||||||
img(path.clone())
|
img(path.clone())
|
||||||
.border_1()
|
.border_1()
|
||||||
.border_color(cx.theme().border_variant)
|
.border_color(cx.theme().border_faint)
|
||||||
.h(px(250.))
|
.h(px(250.))
|
||||||
.object_fit(ObjectFit::Cover)
|
.object_fit(ObjectFit::Cover)
|
||||||
.rounded(cx.theme().radius),
|
.rounded(px(theme::bubble_radius())),
|
||||||
)
|
)
|
||||||
.into_any_element();
|
.into_any_element();
|
||||||
}
|
}
|
||||||
@@ -1645,9 +1645,9 @@ impl ChatPanel {
|
|||||||
.gap_2()
|
.gap_2()
|
||||||
.p_2()
|
.p_2()
|
||||||
.border_1()
|
.border_1()
|
||||||
.border_color(cx.theme().border_variant)
|
.border_color(cx.theme().border_faint)
|
||||||
.rounded(cx.theme().radius)
|
.rounded(px(theme::control_radius()))
|
||||||
.child(Icon::new(IconName::Lock).text_color(cx.theme().icon_accent))
|
.child(Icon::new(IconName::Lock).text_color(cx.theme().accent))
|
||||||
.child(
|
.child(
|
||||||
v_flex()
|
v_flex()
|
||||||
.min_w_0()
|
.min_w_0()
|
||||||
@@ -1657,7 +1657,7 @@ impl ChatPanel {
|
|||||||
.child(
|
.child(
|
||||||
div()
|
div()
|
||||||
.text_xs()
|
.text_xs()
|
||||||
.text_color(cx.theme().text_placeholder)
|
.text_color(cx.theme().text_faint)
|
||||||
.child(label),
|
.child(label),
|
||||||
),
|
),
|
||||||
)
|
)
|
||||||
@@ -1688,7 +1688,7 @@ impl ChatPanel {
|
|||||||
img(pending.path.clone())
|
img(pending.path.clone())
|
||||||
.size_16()
|
.size_16()
|
||||||
.when(cx.theme().shadow, |this| this.shadow_sm())
|
.when(cx.theme().shadow, |this| this.shadow_sm())
|
||||||
.rounded(cx.theme().radius)
|
.rounded(px(theme::control_radius()))
|
||||||
.object_fit(ObjectFit::Cover),
|
.object_fit(ObjectFit::Cover),
|
||||||
)
|
)
|
||||||
} else {
|
} else {
|
||||||
@@ -1698,10 +1698,10 @@ impl ChatPanel {
|
|||||||
.flex()
|
.flex()
|
||||||
.items_center()
|
.items_center()
|
||||||
.justify_center()
|
.justify_center()
|
||||||
.rounded(cx.theme().radius)
|
.rounded(px(theme::control_radius()))
|
||||||
.border_1()
|
.border_1()
|
||||||
.border_color(cx.theme().border_variant)
|
.border_color(cx.theme().border_faint)
|
||||||
.bg(cx.theme().surface_background)
|
.bg(cx.theme().surface)
|
||||||
.text_xs()
|
.text_xs()
|
||||||
.text_center()
|
.text_center()
|
||||||
.child("Preview not available"),
|
.child("Preview not available"),
|
||||||
@@ -1718,7 +1718,7 @@ impl ChatPanel {
|
|||||||
.justify_center()
|
.justify_center()
|
||||||
.rounded_full()
|
.rounded_full()
|
||||||
.border_1()
|
.border_1()
|
||||||
.border_color(cx.theme().border_variant)
|
.border_color(cx.theme().border_faint)
|
||||||
.bg(gpui::green())
|
.bg(gpui::green())
|
||||||
.child(Icon::new(IconName::Lock).size_2().text_color(gpui::white())),
|
.child(Icon::new(IconName::Lock).size_2().text_color(gpui::white())),
|
||||||
)
|
)
|
||||||
@@ -1767,11 +1767,7 @@ impl ChatPanel {
|
|||||||
.text_xs()
|
.text_xs()
|
||||||
.text_color(cx.theme().text_muted)
|
.text_color(cx.theme().text_muted)
|
||||||
.child("Replying to:")
|
.child("Replying to:")
|
||||||
.child(
|
.child(div().text_color(cx.theme().accent).child(profile.name())),
|
||||||
div()
|
|
||||||
.text_color(cx.theme().text_accent)
|
|
||||||
.child(profile.name()),
|
|
||||||
),
|
|
||||||
)
|
)
|
||||||
.child(
|
.child(
|
||||||
Button::new("remove-reply")
|
Button::new("remove-reply")
|
||||||
@@ -1994,7 +1990,7 @@ impl Render for ChatPanel {
|
|||||||
div()
|
div()
|
||||||
.px_1()
|
.px_1()
|
||||||
.text_xs()
|
.text_xs()
|
||||||
.text_color(cx.theme().text_warning)
|
.text_color(cx.theme().warning)
|
||||||
.child(WARNING),
|
.child(WARNING),
|
||||||
)
|
)
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -3,7 +3,7 @@ use gpui::{
|
|||||||
relative,
|
relative,
|
||||||
};
|
};
|
||||||
use nip29::{Group, GroupMetadata};
|
use nip29::{Group, GroupMetadata};
|
||||||
use theme::ActiveTheme;
|
use theme::{ActiveTheme, control_radius};
|
||||||
use ui::avatar::Avatar;
|
use ui::avatar::Avatar;
|
||||||
use ui::{Sizable, StyledExt, WindowExtension, h_flex, v_flex};
|
use ui::{Sizable, StyledExt, WindowExtension, h_flex, v_flex};
|
||||||
|
|
||||||
@@ -76,7 +76,7 @@ fn body(group: &WeakEntity<Group>, cx: &App) -> AnyElement {
|
|||||||
"Supported kinds",
|
"Supported kinds",
|
||||||
if items.is_empty() {
|
if items.is_empty() {
|
||||||
div()
|
div()
|
||||||
.text_color(cx.theme().text_placeholder)
|
.text_color(cx.theme().text_faint)
|
||||||
.child("None")
|
.child("None")
|
||||||
.into_any_element()
|
.into_any_element()
|
||||||
} else {
|
} else {
|
||||||
@@ -145,7 +145,7 @@ fn header(group: &Group, cx: &App) -> AnyElement {
|
|||||||
.child(
|
.child(
|
||||||
div()
|
div()
|
||||||
.text_xs()
|
.text_xs()
|
||||||
.text_color(cx.theme().text_placeholder)
|
.text_color(cx.theme().text_faint)
|
||||||
.truncate()
|
.truncate()
|
||||||
.child(SharedString::from(format!(
|
.child(SharedString::from(format!(
|
||||||
"{} · {}",
|
"{} · {}",
|
||||||
@@ -183,9 +183,9 @@ fn chip(label: impl Into<SharedString>, cx: &App) -> AnyElement {
|
|||||||
div()
|
div()
|
||||||
.px_2()
|
.px_2()
|
||||||
.py_1()
|
.py_1()
|
||||||
.rounded(cx.theme().radius)
|
.rounded(px(control_radius()))
|
||||||
.bg(cx.theme().secondary_background)
|
.bg(cx.theme().surface_raised)
|
||||||
.text_color(cx.theme().secondary_foreground)
|
.text_color(cx.theme().text)
|
||||||
.text_xs()
|
.text_xs()
|
||||||
.line_height(relative(1.))
|
.line_height(relative(1.))
|
||||||
.child(label.into())
|
.child(label.into())
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ use serde::Deserialize;
|
|||||||
use settings::AppSettings;
|
use settings::AppSettings;
|
||||||
use smallvec::{SmallVec, smallvec};
|
use smallvec::{SmallVec, smallvec};
|
||||||
use state::{NostrRegistry, upload};
|
use state::{NostrRegistry, upload};
|
||||||
use theme::ActiveTheme;
|
use theme::{ActiveTheme, control_radius};
|
||||||
use ui::avatar::Avatar;
|
use ui::avatar::Avatar;
|
||||||
use ui::button::{Button, ButtonVariant, ButtonVariants};
|
use ui::button::{Button, ButtonVariant, ButtonVariants};
|
||||||
use ui::dialog::DialogButtonProps;
|
use ui::dialog::DialogButtonProps;
|
||||||
@@ -576,7 +576,7 @@ impl GroupPanel {
|
|||||||
.child(
|
.child(
|
||||||
Icon::new(IconName::Info)
|
Icon::new(IconName::Info)
|
||||||
.small()
|
.small()
|
||||||
.text_color(cx.theme().icon_muted),
|
.text_color(cx.theme().text_faint),
|
||||||
)
|
)
|
||||||
.child(div().flex_1().min_w_0().truncate().child(message))
|
.child(div().flex_1().min_w_0().truncate().child(message))
|
||||||
.child(
|
.child(
|
||||||
@@ -615,8 +615,8 @@ impl GroupPanel {
|
|||||||
div()
|
div()
|
||||||
.px_1p5()
|
.px_1p5()
|
||||||
.py_0p5()
|
.py_0p5()
|
||||||
.rounded(cx.theme().radius)
|
.rounded(px(control_radius()))
|
||||||
.bg(cx.theme().element_background)
|
.bg(cx.theme().solid)
|
||||||
.text_xs()
|
.text_xs()
|
||||||
.text_color(cx.theme().text_muted)
|
.text_color(cx.theme().text_muted)
|
||||||
.child(pin_label(group, pin))
|
.child(pin_label(group, pin))
|
||||||
@@ -878,8 +878,8 @@ impl GroupPanel {
|
|||||||
.h_8()
|
.h_8()
|
||||||
.px_2()
|
.px_2()
|
||||||
.border_1()
|
.border_1()
|
||||||
.border_color(cx.theme().border_variant)
|
.border_color(cx.theme().border_faint)
|
||||||
.rounded(cx.theme().radius)
|
.rounded(px(control_radius()))
|
||||||
.text_xs()
|
.text_xs()
|
||||||
.text_color(cx.theme().text_muted)
|
.text_color(cx.theme().text_muted)
|
||||||
.child(Icon::new(IconName::Link).xsmall())
|
.child(Icon::new(IconName::Link).xsmall())
|
||||||
@@ -988,7 +988,7 @@ impl Render for GroupPanel {
|
|||||||
.size_full()
|
.size_full()
|
||||||
.justify_center()
|
.justify_center()
|
||||||
.text_sm()
|
.text_sm()
|
||||||
.text_color(cx.theme().text_placeholder)
|
.text_color(cx.theme().text_faint)
|
||||||
.child("No messages yet")
|
.child("No messages yet")
|
||||||
.into_any_element(),
|
.into_any_element(),
|
||||||
}),
|
}),
|
||||||
|
|||||||
@@ -9,7 +9,7 @@ use nip29::{Activity, Group};
|
|||||||
use nostr_sdk::prelude::{EventId, Kind};
|
use nostr_sdk::prelude::{EventId, Kind};
|
||||||
use person::PersonRegistry;
|
use person::PersonRegistry;
|
||||||
use settings::AppSettings;
|
use settings::AppSettings;
|
||||||
use theme::ActiveTheme;
|
use theme::{ActiveTheme, bubble_radius};
|
||||||
use ui::avatar::Avatar;
|
use ui::avatar::Avatar;
|
||||||
use ui::menu::{ContextMenu, PopupMenu, PopupMenuItem};
|
use ui::menu::{ContextMenu, PopupMenu, PopupMenuItem};
|
||||||
use ui::message::MessageRow;
|
use ui::message::MessageRow;
|
||||||
@@ -141,7 +141,7 @@ pub(crate) fn render_activity(ix: usize, activity: &Activity, cx: &App) -> AnyEl
|
|||||||
.gap_2()
|
.gap_2()
|
||||||
.py_1()
|
.py_1()
|
||||||
.px_3()
|
.px_3()
|
||||||
.hover(|this| this.bg(cx.theme().surface_background))
|
.hover(|this| this.bg(cx.theme().element_hover))
|
||||||
.child(badge(activity, cx))
|
.child(badge(activity, cx))
|
||||||
.when(!hide_avatar, |this| {
|
.when(!hide_avatar, |this| {
|
||||||
this.child(
|
this.child(
|
||||||
@@ -164,7 +164,7 @@ pub(crate) fn render_activity(ix: usize, activity: &Activity, cx: &App) -> AnyEl
|
|||||||
.min_w_0()
|
.min_w_0()
|
||||||
.truncate()
|
.truncate()
|
||||||
.text_sm()
|
.text_sm()
|
||||||
.text_color(cx.theme().text_placeholder)
|
.text_color(cx.theme().text_faint)
|
||||||
.child(SharedString::from(action(activity))),
|
.child(SharedString::from(action(activity))),
|
||||||
)
|
)
|
||||||
.child(
|
.child(
|
||||||
@@ -172,7 +172,7 @@ pub(crate) fn render_activity(ix: usize, activity: &Activity, cx: &App) -> AnyEl
|
|||||||
.flex_shrink_0()
|
.flex_shrink_0()
|
||||||
.ml_1()
|
.ml_1()
|
||||||
.text_xs()
|
.text_xs()
|
||||||
.text_color(cx.theme().text_placeholder)
|
.text_color(cx.theme().text_faint)
|
||||||
.child(activity.created_at.to_ago()),
|
.child(activity.created_at.to_ago()),
|
||||||
)
|
)
|
||||||
.into_any_element()
|
.into_any_element()
|
||||||
@@ -180,11 +180,11 @@ pub(crate) fn render_activity(ix: usize, activity: &Activity, cx: &App) -> AnyEl
|
|||||||
|
|
||||||
fn badge(activity: &Activity, cx: &App) -> AnyElement {
|
fn badge(activity: &Activity, cx: &App) -> AnyElement {
|
||||||
let (icon, color) = match activity.kind {
|
let (icon, color) = match activity.kind {
|
||||||
Kind::GroupJoinRequest => (IconName::Login, cx.theme().icon_accent),
|
Kind::GroupJoinRequest => (IconName::Login, cx.theme().accent),
|
||||||
Kind::GroupPutUser => (IconName::Login, cx.theme().icon_accent),
|
Kind::GroupPutUser => (IconName::Login, cx.theme().accent),
|
||||||
Kind::GroupLeaveRequest => (IconName::Logout, cx.theme().text_danger),
|
Kind::GroupLeaveRequest => (IconName::Logout, cx.theme().danger),
|
||||||
Kind::GroupRemoveUser => (IconName::Ban, cx.theme().text_danger),
|
Kind::GroupRemoveUser => (IconName::Ban, cx.theme().danger),
|
||||||
_ => (IconName::Info, cx.theme().icon_muted),
|
_ => (IconName::Info, cx.theme().text_faint),
|
||||||
};
|
};
|
||||||
|
|
||||||
h_flex()
|
h_flex()
|
||||||
@@ -211,10 +211,10 @@ fn media(media: &[SharedUri], cx: &App) -> AnyElement {
|
|||||||
.child(
|
.child(
|
||||||
img(only.clone())
|
img(only.clone())
|
||||||
.border_1()
|
.border_1()
|
||||||
.border_color(cx.theme().border_variant)
|
.border_color(cx.theme().border_faint)
|
||||||
.h(px(250.))
|
.h(px(250.))
|
||||||
.object_fit(ObjectFit::Cover)
|
.object_fit(ObjectFit::Cover)
|
||||||
.rounded(cx.theme().radius),
|
.rounded(px(bubble_radius())),
|
||||||
)
|
)
|
||||||
.into_any_element();
|
.into_any_element();
|
||||||
}
|
}
|
||||||
@@ -231,8 +231,8 @@ fn media(media: &[SharedUri], cx: &App) -> AnyElement {
|
|||||||
img(item.clone())
|
img(item.clone())
|
||||||
.h_32()
|
.h_32()
|
||||||
.border_1()
|
.border_1()
|
||||||
.border_color(cx.theme().border_variant)
|
.border_color(cx.theme().border_faint)
|
||||||
.rounded(cx.theme().radius),
|
.rounded(px(bubble_radius())),
|
||||||
)
|
)
|
||||||
}))
|
}))
|
||||||
.into_any_element()
|
.into_any_element()
|
||||||
|
|||||||
@@ -8,14 +8,14 @@ use std::sync::atomic::{AtomicBool, Ordering};
|
|||||||
use anyhow::{Context as AnyhowContext, Error, anyhow};
|
use anyhow::{Context as AnyhowContext, Error, anyhow};
|
||||||
use gpui::{
|
use gpui::{
|
||||||
App, AppContext, Context, Entity, EventEmitter, Global, IntoElement, ParentElement,
|
App, AppContext, Context, Entity, EventEmitter, Global, IntoElement, ParentElement,
|
||||||
SharedString, Styled, Subscription, Task, Window, div, relative,
|
SharedString, Styled, Subscription, Task, Window, div, px, relative,
|
||||||
};
|
};
|
||||||
use nostr_sdk::prelude::*;
|
use nostr_sdk::prelude::*;
|
||||||
use person::PersonRegistry;
|
use person::PersonRegistry;
|
||||||
use settings::AppSettings;
|
use settings::AppSettings;
|
||||||
use smallvec::{SmallVec, smallvec};
|
use smallvec::{SmallVec, smallvec};
|
||||||
use state::{Announcement, CLIENT_NAME, NostrRegistry, UniversalSigner};
|
use state::{Announcement, CLIENT_NAME, NostrRegistry, UniversalSigner};
|
||||||
use theme::ActiveTheme;
|
use theme::{ActiveTheme, control_radius};
|
||||||
use ui::avatar::Avatar;
|
use ui::avatar::Avatar;
|
||||||
use ui::button::Button;
|
use ui::button::Button;
|
||||||
use ui::notification::{Notification, NotificationKind};
|
use ui::notification::{Notification, NotificationKind};
|
||||||
@@ -747,8 +747,8 @@ impl DeviceRegistry {
|
|||||||
.h_8()
|
.h_8()
|
||||||
.w_full()
|
.w_full()
|
||||||
.px_2()
|
.px_2()
|
||||||
.rounded(cx.theme().radius)
|
.rounded(px(control_radius()))
|
||||||
.bg(cx.theme().elevated_surface_background)
|
.bg(cx.theme().surface_card)
|
||||||
.child(
|
.child(
|
||||||
h_flex()
|
h_flex()
|
||||||
.gap_2()
|
.gap_2()
|
||||||
@@ -777,8 +777,8 @@ impl DeviceRegistry {
|
|||||||
.h_8()
|
.h_8()
|
||||||
.w_full()
|
.w_full()
|
||||||
.px_2()
|
.px_2()
|
||||||
.rounded(cx.theme().radius)
|
.rounded(px(control_radius()))
|
||||||
.bg(cx.theme().elevated_surface_background)
|
.bg(cx.theme().surface_card)
|
||||||
.child(code_label.clone()),
|
.child(code_label.clone()),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ use gpui::{
|
|||||||
use instant::Duration;
|
use instant::Duration;
|
||||||
use nostr_connect::prelude::*;
|
use nostr_connect::prelude::*;
|
||||||
use state::{CoopAuthUrlHandler, NostrRegistry, USER_KEYRING};
|
use state::{CoopAuthUrlHandler, NostrRegistry, USER_KEYRING};
|
||||||
use theme::ActiveTheme;
|
use theme::{ActiveTheme, surface_radius};
|
||||||
use ui::button::{Button, ButtonVariants};
|
use ui::button::{Button, ButtonVariants};
|
||||||
use ui::input::{Input, InputEvent, InputState};
|
use ui::input::{Input, InputEvent, InputState};
|
||||||
use ui::{Disableable, StyledExt, WindowExtension, v_flex};
|
use ui::{Disableable, StyledExt, WindowExtension, v_flex};
|
||||||
@@ -248,10 +248,10 @@ impl Render for ImportIdentity {
|
|||||||
this.child(
|
this.child(
|
||||||
div()
|
div()
|
||||||
.p_2()
|
.p_2()
|
||||||
.rounded(cx.theme().radius)
|
.rounded(px(surface_radius()))
|
||||||
.bg(cx.theme().warning_background)
|
.bg(cx.theme().warning_muted)
|
||||||
.text_xs()
|
.text_xs()
|
||||||
.text_color(cx.theme().warning_foreground)
|
.text_color(cx.theme().warning)
|
||||||
.line_height(relative(1.2))
|
.line_height(relative(1.2))
|
||||||
.child(div().child(BUNKER_WARN)),
|
.child(div().child(BUNKER_WARN)),
|
||||||
)
|
)
|
||||||
@@ -260,10 +260,10 @@ impl Render for ImportIdentity {
|
|||||||
this.child(
|
this.child(
|
||||||
div()
|
div()
|
||||||
.p_2()
|
.p_2()
|
||||||
.rounded(cx.theme().radius)
|
.rounded(px(surface_radius()))
|
||||||
.bg(cx.theme().warning_background)
|
.bg(cx.theme().warning_muted)
|
||||||
.text_xs()
|
.text_xs()
|
||||||
.text_color(cx.theme().warning_foreground)
|
.text_color(cx.theme().warning)
|
||||||
.line_height(relative(1.2))
|
.line_height(relative(1.2))
|
||||||
.child(div().child(KEY_WARN)),
|
.child(div().child(KEY_WARN)),
|
||||||
)
|
)
|
||||||
@@ -297,7 +297,7 @@ impl Render for ImportIdentity {
|
|||||||
div()
|
div()
|
||||||
.text_xs()
|
.text_xs()
|
||||||
.text_center()
|
.text_center()
|
||||||
.text_color(cx.theme().text_danger)
|
.text_color(cx.theme().danger)
|
||||||
.child(error.clone()),
|
.child(error.clone()),
|
||||||
)
|
)
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -365,9 +365,9 @@ impl NewChat {
|
|||||||
.gap_1()
|
.gap_1()
|
||||||
.p_0p5()
|
.p_0p5()
|
||||||
.rounded_full()
|
.rounded_full()
|
||||||
.bg(cx.theme().ghost_element_background_alt)
|
.bg(cx.theme().surface_raised)
|
||||||
.text_size(px(10.))
|
.text_size(px(10.))
|
||||||
.hover(|this| this.bg(cx.theme().ghost_element_hover))
|
.hover(|this| this.bg(cx.theme().element_hover))
|
||||||
.child(
|
.child(
|
||||||
Avatar::from_source(profile.avatar())
|
Avatar::from_source(profile.avatar())
|
||||||
.seed(profile.avatar_seed())
|
.seed(profile.avatar_seed())
|
||||||
@@ -412,17 +412,12 @@ impl Render for NewChat {
|
|||||||
})
|
})
|
||||||
.map(|this| {
|
.map(|this| {
|
||||||
if let Some(error) = self.error.clone() {
|
if let Some(error) = self.error.clone() {
|
||||||
this.child(
|
this.child(div().text_xs().text_color(cx.theme().danger).child(error))
|
||||||
div()
|
|
||||||
.text_xs()
|
|
||||||
.text_color(cx.theme().text_danger)
|
|
||||||
.child(error),
|
|
||||||
)
|
|
||||||
} else {
|
} else {
|
||||||
this.child(
|
this.child(
|
||||||
div()
|
div()
|
||||||
.text_xs()
|
.text_xs()
|
||||||
.text_color(cx.theme().text_placeholder)
|
.text_color(cx.theme().text_faint)
|
||||||
.child(notice),
|
.child(notice),
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -5,14 +5,14 @@ use chat::{ChatRegistry, Room, RoomKind};
|
|||||||
use gpui::prelude::FluentBuilder;
|
use gpui::prelude::FluentBuilder;
|
||||||
use gpui::{
|
use gpui::{
|
||||||
App, AppContext, ClipboardItem, Context, Div, Entity, IntoElement, ParentElement,
|
App, AppContext, ClipboardItem, Context, Div, Entity, IntoElement, ParentElement,
|
||||||
PathPromptOptions, Render, SharedString, Styled, Task, Window, div, retain_all,
|
PathPromptOptions, Render, SharedString, Styled, Task, Window, div, px, retain_all,
|
||||||
};
|
};
|
||||||
use instant::Duration;
|
use instant::Duration;
|
||||||
use nostr_sdk::prelude::*;
|
use nostr_sdk::prelude::*;
|
||||||
use person::{Person, PersonRegistry, shorten_pubkey};
|
use person::{Person, PersonRegistry, shorten_pubkey};
|
||||||
use settings::AppSettings;
|
use settings::AppSettings;
|
||||||
use state::{NostrRegistry, upload};
|
use state::{NostrRegistry, upload};
|
||||||
use theme::ActiveTheme;
|
use theme::{ActiveTheme, button_radius};
|
||||||
use ui::avatar::Avatar;
|
use ui::avatar::Avatar;
|
||||||
use ui::button::{Button, ButtonVariants};
|
use ui::button::{Button, ButtonVariants};
|
||||||
use ui::dock::DockPlacement;
|
use ui::dock::DockPlacement;
|
||||||
@@ -366,7 +366,7 @@ impl Render for ProfileDialog {
|
|||||||
.w_full()
|
.w_full()
|
||||||
.items_center()
|
.items_center()
|
||||||
.justify_center()
|
.justify_center()
|
||||||
.bg(cx.theme().surface_background)
|
.bg(cx.theme().surface)
|
||||||
.child(Avatar::new(avatar).seed(profile.avatar_seed()).large())
|
.child(Avatar::new(avatar).seed(profile.avatar_seed()).large())
|
||||||
.when(self.editing, |this| {
|
.when(self.editing, |this| {
|
||||||
this.child(
|
this.child(
|
||||||
@@ -391,8 +391,8 @@ impl Render for ProfileDialog {
|
|||||||
.w_full()
|
.w_full()
|
||||||
.justify_center()
|
.justify_center()
|
||||||
.gap_3()
|
.gap_3()
|
||||||
.rounded(cx.theme().radius)
|
.rounded(px(button_radius()))
|
||||||
.bg(cx.theme().surface_background)
|
.bg(cx.theme().surface)
|
||||||
.text_sm()
|
.text_sm()
|
||||||
.child(shorten_pkey)
|
.child(shorten_pkey)
|
||||||
.child(
|
.child(
|
||||||
|
|||||||
@@ -11,7 +11,7 @@ use instant::Duration;
|
|||||||
use nostr_sdk::prelude::*;
|
use nostr_sdk::prelude::*;
|
||||||
use smallvec::{SmallVec, smallvec};
|
use smallvec::{SmallVec, smallvec};
|
||||||
use state::NostrRegistry;
|
use state::NostrRegistry;
|
||||||
use theme::ActiveTheme;
|
use theme::{ActiveTheme, button_radius, panel_radius};
|
||||||
use ui::button::{Button, ButtonVariants};
|
use ui::button::{Button, ButtonVariants};
|
||||||
use ui::input::{Input, InputEvent, InputState};
|
use ui::input::{Input, InputEvent, InputState};
|
||||||
use ui::menu::{DropdownMenu, PopupMenuItem};
|
use ui::menu::{DropdownMenu, PopupMenuItem};
|
||||||
@@ -154,7 +154,7 @@ impl RelayManager {
|
|||||||
div()
|
div()
|
||||||
.italic()
|
.italic()
|
||||||
.text_xs()
|
.text_xs()
|
||||||
.text_color(cx.theme().text_danger)
|
.text_color(cx.theme().danger)
|
||||||
.child(error.clone()),
|
.child(error.clone()),
|
||||||
)
|
)
|
||||||
})
|
})
|
||||||
@@ -225,7 +225,7 @@ impl RelayManager {
|
|||||||
div()
|
div()
|
||||||
.italic()
|
.italic()
|
||||||
.text_xs()
|
.text_xs()
|
||||||
.text_color(cx.theme().text_danger)
|
.text_color(cx.theme().danger)
|
||||||
.child(error.clone()),
|
.child(error.clone()),
|
||||||
)
|
)
|
||||||
})
|
})
|
||||||
@@ -646,8 +646,8 @@ fn relay_row(
|
|||||||
.h_8()
|
.h_8()
|
||||||
.px_2()
|
.px_2()
|
||||||
.justify_between()
|
.justify_between()
|
||||||
.rounded(cx.theme().radius)
|
.rounded(px(button_radius()))
|
||||||
.bg(cx.theme().surface_background)
|
.bg(cx.theme().surface)
|
||||||
.child(
|
.child(
|
||||||
h_flex()
|
h_flex()
|
||||||
.gap_1()
|
.gap_1()
|
||||||
@@ -682,7 +682,7 @@ fn empty_relays(cx: &App) -> impl IntoElement {
|
|||||||
.border_2()
|
.border_2()
|
||||||
.border_dashed()
|
.border_dashed()
|
||||||
.border_color(cx.theme().border)
|
.border_color(cx.theme().border)
|
||||||
.rounded(cx.theme().radius_lg)
|
.rounded(px(panel_radius()))
|
||||||
.text_sm()
|
.text_sm()
|
||||||
.text_align(TextAlign::Center)
|
.text_align(TextAlign::Center)
|
||||||
.child(SharedString::from("Please add some relays."))
|
.child(SharedString::from("Please add some relays."))
|
||||||
|
|||||||
@@ -126,7 +126,7 @@ impl Render for RestoreEncryption {
|
|||||||
div()
|
div()
|
||||||
.text_xs()
|
.text_xs()
|
||||||
.text_center()
|
.text_center()
|
||||||
.text_color(cx.theme().text_danger)
|
.text_color(cx.theme().danger)
|
||||||
.child(error.clone()),
|
.child(error.clone()),
|
||||||
)
|
)
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -12,7 +12,7 @@ use nostr_sdk::prelude::*;
|
|||||||
use person::{Person, PersonRegistry, shorten_pubkey};
|
use person::{Person, PersonRegistry, shorten_pubkey};
|
||||||
use smallvec::{SmallVec, smallvec};
|
use smallvec::{SmallVec, smallvec};
|
||||||
use state::{BOOTSTRAP_RELAYS, NostrAddress, NostrRegistry, TIMEOUT};
|
use state::{BOOTSTRAP_RELAYS, NostrAddress, NostrRegistry, TIMEOUT};
|
||||||
use theme::ActiveTheme;
|
use theme::{ActiveTheme, button_radius};
|
||||||
use ui::avatar::Avatar;
|
use ui::avatar::Avatar;
|
||||||
use ui::button::{Button, ButtonVariants};
|
use ui::button::{Button, ButtonVariants};
|
||||||
use ui::indicator::Indicator;
|
use ui::indicator::Indicator;
|
||||||
@@ -283,9 +283,9 @@ impl Screening {
|
|||||||
.w_full()
|
.w_full()
|
||||||
.px_2()
|
.px_2()
|
||||||
.gap_1p5()
|
.gap_1p5()
|
||||||
.rounded(cx.theme().radius)
|
.rounded(px(button_radius()))
|
||||||
.text_sm()
|
.text_sm()
|
||||||
.hover(|this| this.bg(cx.theme().elevated_surface_background))
|
.hover(|this| this.bg(cx.theme().element_hover))
|
||||||
.child(Avatar::new(profile.avatar()).small())
|
.child(Avatar::new(profile.avatar()).small())
|
||||||
.child(profile.name()),
|
.child(profile.name()),
|
||||||
);
|
);
|
||||||
@@ -344,7 +344,7 @@ impl Render for Screening {
|
|||||||
.h_7()
|
.h_7()
|
||||||
.justify_center()
|
.justify_center()
|
||||||
.rounded_full()
|
.rounded_full()
|
||||||
.bg(cx.theme().elevated_surface_background)
|
.bg(cx.theme().surface_raised)
|
||||||
.text_sm()
|
.text_sm()
|
||||||
.truncate()
|
.truncate()
|
||||||
.text_ellipsis()
|
.text_ellipsis()
|
||||||
@@ -524,9 +524,9 @@ fn status_badge(status: Option<bool>, cx: &App) -> Div {
|
|||||||
if let Some(status) = status {
|
if let Some(status) = status {
|
||||||
this.child(Icon::new(IconName::CheckCircle).small().text_color({
|
this.child(Icon::new(IconName::CheckCircle).small().text_color({
|
||||||
if status {
|
if status {
|
||||||
cx.theme().icon_accent
|
cx.theme().accent
|
||||||
} else {
|
} else {
|
||||||
cx.theme().icon_muted
|
cx.theme().text_faint
|
||||||
}
|
}
|
||||||
}))
|
}))
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
@@ -199,7 +199,7 @@ impl Render for Preferences {
|
|||||||
div()
|
div()
|
||||||
.text_size(px(10.))
|
.text_size(px(10.))
|
||||||
.italic()
|
.italic()
|
||||||
.text_color(cx.theme().text_placeholder)
|
.text_color(cx.theme().text_faint)
|
||||||
.child(SharedString::from("Only support blossom service")),
|
.child(SharedString::from("Only support blossom service")),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|||||||
@@ -15,7 +15,7 @@ use nostr_sdk::prelude::*;
|
|||||||
use serde::Deserialize;
|
use serde::Deserialize;
|
||||||
use smallvec::{SmallVec, smallvec};
|
use smallvec::{SmallVec, smallvec};
|
||||||
use state::{NostrRegistry, StateEvent};
|
use state::{NostrRegistry, StateEvent};
|
||||||
use theme::{ActiveTheme, SIDEBAR_WIDTH, Theme, ThemeRegistry};
|
use theme::{ActiveTheme, SIDEBAR_WIDTH, Theme, ThemeRegistry, button_radius};
|
||||||
use ui::button::{Button, ButtonVariants};
|
use ui::button::{Button, ButtonVariants};
|
||||||
use ui::dock::{self, DockArea, DockLayout, DockPlacement, Panel, PanelHandle};
|
use ui::dock::{self, DockArea, DockLayout, DockPlacement, Panel, PanelHandle};
|
||||||
use ui::notification::{Notification, NotificationKind};
|
use ui::notification::{Notification, NotificationKind};
|
||||||
@@ -425,7 +425,7 @@ impl Workspace {
|
|||||||
.child(
|
.child(
|
||||||
div()
|
div()
|
||||||
.italic()
|
.italic()
|
||||||
.text_color(cx.theme().text_danger)
|
.text_color(cx.theme().danger)
|
||||||
.child(SharedString::from(ENC_WARN)),
|
.child(SharedString::from(ENC_WARN)),
|
||||||
),
|
),
|
||||||
)
|
)
|
||||||
@@ -469,9 +469,8 @@ impl Workspace {
|
|||||||
.h_8()
|
.h_8()
|
||||||
.w_full()
|
.w_full()
|
||||||
.justify_between()
|
.justify_between()
|
||||||
.rounded(cx.theme().radius)
|
.rounded(px(button_radius()))
|
||||||
.bg(cx.theme().ghost_element_background)
|
.hover(|this| this.bg(cx.theme().element_hover))
|
||||||
.hover(|this| this.bg(cx.theme().ghost_element_hover))
|
|
||||||
.child(
|
.child(
|
||||||
h_flex()
|
h_flex()
|
||||||
.gap_1p5()
|
.gap_1p5()
|
||||||
|
|||||||
@@ -6,14 +6,14 @@ use gpui::{
|
|||||||
AnyElement, App, AppContext, Context, Entity, EventEmitter, FocusHandle, Focusable,
|
AnyElement, App, AppContext, Context, Entity, EventEmitter, FocusHandle, Focusable,
|
||||||
InteractiveElement, IntoElement, ParentElement, Render, ScrollStrategy, SharedString,
|
InteractiveElement, IntoElement, ParentElement, Render, ScrollStrategy, SharedString,
|
||||||
StatefulInteractiveElement, Styled, Subscription, Task, WeakEntity, Window, div, px, relative,
|
StatefulInteractiveElement, Styled, Subscription, Task, WeakEntity, Window, div, px, relative,
|
||||||
size,
|
size, transparent_black,
|
||||||
};
|
};
|
||||||
use gpui_base::{VirtualListScrollHandle, v_virtual_list};
|
use gpui_base::{VirtualListScrollHandle, v_virtual_list};
|
||||||
use nip29::{Discovery, GroupCandidate, GroupKey, GroupsEvent, GroupsRegistry, Membership};
|
use nip29::{Discovery, GroupCandidate, GroupKey, GroupsEvent, GroupsRegistry, Membership};
|
||||||
use nostr_sdk::prelude::{RelayUrl, Timestamp};
|
use nostr_sdk::prelude::{RelayUrl, Timestamp};
|
||||||
use settings::AppSettings;
|
use settings::AppSettings;
|
||||||
use smallvec::{SmallVec, smallvec};
|
use smallvec::{SmallVec, smallvec};
|
||||||
use theme::ActiveTheme;
|
use theme::{ActiveTheme, button_radius, panel_radius};
|
||||||
use ui::avatar::Avatar;
|
use ui::avatar::Avatar;
|
||||||
use ui::button::{Button, ButtonVariants};
|
use ui::button::{Button, ButtonVariants};
|
||||||
use ui::dock::{DockArea, DockPlacement, Panel, PanelEvent, PanelHandle};
|
use ui::dock::{DockArea, DockPlacement, Panel, PanelEvent, PanelHandle};
|
||||||
@@ -294,8 +294,8 @@ impl BrowsePanel {
|
|||||||
.w_full()
|
.w_full()
|
||||||
.max_w_64()
|
.max_w_64()
|
||||||
.px_1()
|
.px_1()
|
||||||
.rounded(cx.theme().radius)
|
.rounded(px(button_radius()))
|
||||||
.bg(cx.theme().surface_background)
|
.bg(cx.theme().surface)
|
||||||
.child(
|
.child(
|
||||||
Input::new(&self.input)
|
Input::new(&self.input)
|
||||||
.appearance(false)
|
.appearance(false)
|
||||||
@@ -375,14 +375,14 @@ impl BrowsePanel {
|
|||||||
.min_w_0()
|
.min_w_0()
|
||||||
.h_full()
|
.h_full()
|
||||||
.overflow_hidden()
|
.overflow_hidden()
|
||||||
.rounded(cx.theme().radius)
|
.rounded(px(panel_radius()))
|
||||||
.cursor_pointer()
|
.cursor_pointer()
|
||||||
.border_1()
|
.border_1()
|
||||||
.border_color(cx.theme().border_transparent)
|
.border_color(transparent_black())
|
||||||
.bg(cx.theme().surface_background)
|
.bg(cx.theme().surface)
|
||||||
.hover(|this| {
|
.hover(|this| {
|
||||||
this.bg(cx.theme().elevated_surface_background)
|
this.bg(cx.theme().surface_raised)
|
||||||
.border_color(cx.theme().border_focused)
|
.border_color(cx.theme().border_strong)
|
||||||
})
|
})
|
||||||
.child(
|
.child(
|
||||||
v_flex()
|
v_flex()
|
||||||
@@ -414,7 +414,7 @@ impl BrowsePanel {
|
|||||||
div()
|
div()
|
||||||
.truncate()
|
.truncate()
|
||||||
.text_xs()
|
.text_xs()
|
||||||
.text_color(cx.theme().text_placeholder)
|
.text_color(cx.theme().text_faint)
|
||||||
.child(relay),
|
.child(relay),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
@@ -467,7 +467,7 @@ impl Panel for BrowsePanel {
|
|||||||
.child(
|
.child(
|
||||||
Icon::new(IconName::Compass)
|
Icon::new(IconName::Compass)
|
||||||
.small()
|
.small()
|
||||||
.text_color(cx.theme().icon_muted),
|
.text_color(cx.theme().text_faint),
|
||||||
)
|
)
|
||||||
.child(TITLE)
|
.child(TITLE)
|
||||||
.into_any_element()
|
.into_any_element()
|
||||||
|
|||||||
@@ -5,14 +5,14 @@ use gpui::prelude::FluentBuilder;
|
|||||||
use gpui::{
|
use gpui::{
|
||||||
AnyElement, App, AppContext, Context, Entity, EventEmitter, FocusHandle, Focusable,
|
AnyElement, App, AppContext, Context, Entity, EventEmitter, FocusHandle, Focusable,
|
||||||
InteractiveElement, IntoElement, ParentElement, Render, SharedString, Styled, Subscription,
|
InteractiveElement, IntoElement, ParentElement, Render, SharedString, Styled, Subscription,
|
||||||
Task, TextAlign, Window, div, rems, retain_all,
|
Task, TextAlign, Window, div, px, rems, retain_all,
|
||||||
};
|
};
|
||||||
use instant::Duration;
|
use instant::Duration;
|
||||||
use nostr_sdk::prelude::*;
|
use nostr_sdk::prelude::*;
|
||||||
use person::PersonRegistry;
|
use person::PersonRegistry;
|
||||||
use smallvec::{SmallVec, smallvec};
|
use smallvec::{SmallVec, smallvec};
|
||||||
use state::NostrRegistry;
|
use state::NostrRegistry;
|
||||||
use theme::ActiveTheme;
|
use theme::{ActiveTheme, button_radius, panel_radius};
|
||||||
use ui::avatar::Avatar;
|
use ui::avatar::Avatar;
|
||||||
use ui::button::{Button, ButtonVariants};
|
use ui::button::{Button, ButtonVariants};
|
||||||
use ui::dock::{Panel, PanelEvent};
|
use ui::dock::{Panel, PanelEvent};
|
||||||
@@ -233,8 +233,8 @@ impl ContactListPanel {
|
|||||||
.h_8()
|
.h_8()
|
||||||
.px_2()
|
.px_2()
|
||||||
.justify_between()
|
.justify_between()
|
||||||
.rounded(cx.theme().radius)
|
.rounded(px(button_radius()))
|
||||||
.hover(|this| this.bg(cx.theme().ghost_element_hover))
|
.hover(|this| this.bg(cx.theme().element_hover))
|
||||||
.child(
|
.child(
|
||||||
h_flex()
|
h_flex()
|
||||||
.gap_2()
|
.gap_2()
|
||||||
@@ -273,7 +273,7 @@ impl ContactListPanel {
|
|||||||
.border_2()
|
.border_2()
|
||||||
.border_dashed()
|
.border_dashed()
|
||||||
.border_color(cx.theme().border)
|
.border_color(cx.theme().border)
|
||||||
.rounded(cx.theme().radius_lg)
|
.rounded(px(panel_radius()))
|
||||||
.text_sm()
|
.text_sm()
|
||||||
.text_align(TextAlign::Center)
|
.text_align(TextAlign::Center)
|
||||||
.child(SharedString::from("Please add some relays."))
|
.child(SharedString::from("Please add some relays."))
|
||||||
@@ -343,7 +343,7 @@ impl Render for ContactListPanel {
|
|||||||
div()
|
div()
|
||||||
.italic()
|
.italic()
|
||||||
.text_xs()
|
.text_xs()
|
||||||
.text_color(cx.theme().text_danger)
|
.text_color(cx.theme().danger)
|
||||||
.child(error.clone()),
|
.child(error.clone()),
|
||||||
)
|
)
|
||||||
}),
|
}),
|
||||||
|
|||||||
@@ -91,7 +91,7 @@ impl Render for GreeterPanel {
|
|||||||
svg()
|
svg()
|
||||||
.path("brand/coop.svg")
|
.path("brand/coop.svg")
|
||||||
.size_12()
|
.size_12()
|
||||||
.text_color(cx.theme().icon_muted),
|
.text_color(cx.theme().text_faint),
|
||||||
)
|
)
|
||||||
.child(
|
.child(
|
||||||
v_flex()
|
v_flex()
|
||||||
|
|||||||
@@ -35,7 +35,7 @@ impl Panel for InboxPanel {
|
|||||||
.child(
|
.child(
|
||||||
Icon::new(IconName::Inbox)
|
Icon::new(IconName::Inbox)
|
||||||
.small()
|
.small()
|
||||||
.text_color(cx.theme().icon_muted),
|
.text_color(cx.theme().text_faint),
|
||||||
)
|
)
|
||||||
.child(self.name.clone())
|
.child(self.name.clone())
|
||||||
.into_any_element()
|
.into_any_element()
|
||||||
|
|||||||
@@ -230,10 +230,10 @@ impl Sidebar {
|
|||||||
|
|
||||||
Nav::new(label)
|
Nav::new(label)
|
||||||
.label(label)
|
.label(label)
|
||||||
.suffix(Icon::new(icon).small().text_color(cx.theme().icon_muted))
|
.suffix(Icon::new(icon).small().text_color(cx.theme().text_faint))
|
||||||
.text_xs()
|
.text_xs()
|
||||||
.font_semibold()
|
.font_semibold()
|
||||||
.text_color(cx.theme().text_placeholder)
|
.text_color(cx.theme().text_faint)
|
||||||
.on_click(cx.listener(move |this, _event, _window, cx| {
|
.on_click(cx.listener(move |this, _event, _window, cx| {
|
||||||
match section {
|
match section {
|
||||||
GroupSection::Admins => this.admins_open = !this.admins_open,
|
GroupSection::Admins => this.admins_open = !this.admins_open,
|
||||||
@@ -278,7 +278,7 @@ impl Sidebar {
|
|||||||
div()
|
div()
|
||||||
.truncate()
|
.truncate()
|
||||||
.text_xs()
|
.text_xs()
|
||||||
.text_color(cx.theme().text_placeholder)
|
.text_color(cx.theme().text_faint)
|
||||||
.child(SharedString::from(roles.join(", "))),
|
.child(SharedString::from(roles.join(", "))),
|
||||||
)
|
)
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -192,7 +192,7 @@ impl Sidebar {
|
|||||||
.px_4()
|
.px_4()
|
||||||
.border_t_1()
|
.border_t_1()
|
||||||
.border_color(cx.theme().border)
|
.border_color(cx.theme().border)
|
||||||
.bg(cx.theme().background)
|
.bg(cx.theme().bg)
|
||||||
.child(
|
.child(
|
||||||
Button::new("create-chat")
|
Button::new("create-chat")
|
||||||
.label(if self.selected_contacts.len() > 1 {
|
.label(if self.selected_contacts.len() > 1 {
|
||||||
|
|||||||
@@ -8,7 +8,7 @@ use gpui::{
|
|||||||
};
|
};
|
||||||
use nip29::GroupsRegistry;
|
use nip29::GroupsRegistry;
|
||||||
use settings::AppSettings;
|
use settings::AppSettings;
|
||||||
use theme::ActiveTheme;
|
use theme::{ActiveTheme, control_radius};
|
||||||
use ui::nav_item::NavItem;
|
use ui::nav_item::NavItem;
|
||||||
use ui::scroll::Scrollbar;
|
use ui::scroll::Scrollbar;
|
||||||
use ui::{Icon, IconName, Sizable, StyledExt, h_flex, v_flex};
|
use ui::{Icon, IconName, Sizable, StyledExt, h_flex, v_flex};
|
||||||
@@ -88,31 +88,27 @@ impl Sidebar {
|
|||||||
.text_size(px(10.))
|
.text_size(px(10.))
|
||||||
.text_color(cx.theme().text_muted)
|
.text_color(cx.theme().text_muted)
|
||||||
.text_center()
|
.text_center()
|
||||||
.rounded(cx.theme().radius)
|
.rounded(px(control_radius()))
|
||||||
.bg(cx.theme().elevated_surface_background)
|
.bg(cx.theme().surface_raised)
|
||||||
.child(SharedString::from(
|
.child(SharedString::from(
|
||||||
request_count.to_string(),
|
request_count.to_string(),
|
||||||
)),
|
)),
|
||||||
)
|
)
|
||||||
.when(self.new_requests && !requests_open, |this| {
|
.when(self.new_requests && !requests_open, |this| {
|
||||||
this.child(
|
this.child(
|
||||||
div().size_1().rounded_full().bg(cx.theme().cursor),
|
div().size_1().rounded_full().bg(cx.theme().accent),
|
||||||
)
|
)
|
||||||
}),
|
}),
|
||||||
)
|
)
|
||||||
})
|
})
|
||||||
.when(requests_open, |this| {
|
.when(requests_open, |this| this.bg(cx.theme().element_active))
|
||||||
this.bg(cx.theme().ghost_element_active)
|
|
||||||
})
|
|
||||||
.on_click(cx.listener(|this, _event, _window, cx| {
|
.on_click(cx.listener(|this, _event, _window, cx| {
|
||||||
this.toggle_requests(cx);
|
this.toggle_requests(cx);
|
||||||
})),
|
})),
|
||||||
)
|
)
|
||||||
.child(
|
.child(
|
||||||
NavItem::new("contacts", "Contacts", Icon::new(IconName::Book).small())
|
NavItem::new("contacts", "Contacts", Icon::new(IconName::Book).small())
|
||||||
.when(contacts_open, |this| {
|
.when(contacts_open, |this| this.bg(cx.theme().element_active))
|
||||||
this.bg(cx.theme().ghost_element_active)
|
|
||||||
})
|
|
||||||
.on_click(cx.listener(|this, _event, window, cx| {
|
.on_click(cx.listener(|this, _event, window, cx| {
|
||||||
this.toggle_contacts(window, cx);
|
this.toggle_contacts(window, cx);
|
||||||
})),
|
})),
|
||||||
@@ -124,7 +120,7 @@ impl Sidebar {
|
|||||||
.px_4()
|
.px_4()
|
||||||
.text_xs()
|
.text_xs()
|
||||||
.font_semibold()
|
.font_semibold()
|
||||||
.text_color(cx.theme().text_placeholder)
|
.text_color(cx.theme().text_faint)
|
||||||
.child(list_title),
|
.child(list_title),
|
||||||
)
|
)
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -277,7 +277,7 @@ impl Render for Sidebar {
|
|||||||
.size_full()
|
.size_full()
|
||||||
.relative()
|
.relative()
|
||||||
.gap_2()
|
.gap_2()
|
||||||
.bg(cx.theme().surface_background)
|
.bg(cx.theme().surface)
|
||||||
.when_some(current_user.as_ref(), |this, current_user| {
|
.when_some(current_user.as_ref(), |this, current_user| {
|
||||||
this.child(title_bar_drag_handlers(
|
this.child(title_bar_drag_handlers(
|
||||||
self.render_user(current_user, cx),
|
self.render_user(current_user, cx),
|
||||||
@@ -330,13 +330,13 @@ impl Render for Sidebar {
|
|||||||
.w_full()
|
.w_full()
|
||||||
.h_9()
|
.h_9()
|
||||||
.justify_center()
|
.justify_center()
|
||||||
.bg(cx.theme().background.opacity(0.85))
|
.bg(cx.theme().bg.opacity(0.85))
|
||||||
.when(cx.theme().shadow, |this| this.shadow_md())
|
.when(cx.theme().shadow, |this| this.shadow_md())
|
||||||
.rounded_full()
|
.rounded_full()
|
||||||
.text_xs()
|
.text_xs()
|
||||||
.font_semibold()
|
.font_semibold()
|
||||||
.text_color(cx.theme().text_muted)
|
.text_color(cx.theme().text_muted)
|
||||||
.child(Indicator::new().small().color(cx.theme().icon_accent))
|
.child(Indicator::new().small().color(cx.theme().accent))
|
||||||
.child("Getting messages..."),
|
.child("Getting messages..."),
|
||||||
),
|
),
|
||||||
)
|
)
|
||||||
|
|||||||
@@ -5,13 +5,13 @@ use common::TimestampExt;
|
|||||||
use gpui::prelude::FluentBuilder;
|
use gpui::prelude::FluentBuilder;
|
||||||
use gpui::{
|
use gpui::{
|
||||||
AnyElement, App, Context, Entity, IntoElement, ParentElement, SharedString, Styled, WeakEntity,
|
AnyElement, App, Context, Entity, IntoElement, ParentElement, SharedString, Styled, WeakEntity,
|
||||||
Window, div,
|
Window, div, px,
|
||||||
};
|
};
|
||||||
use nip29::Group;
|
use nip29::Group;
|
||||||
use nostr_sdk::prelude::*;
|
use nostr_sdk::prelude::*;
|
||||||
use person::PersonRegistry;
|
use person::PersonRegistry;
|
||||||
use settings::AppSettings;
|
use settings::AppSettings;
|
||||||
use theme::ActiveTheme;
|
use theme::{ActiveTheme, button_radius};
|
||||||
use ui::avatar::Avatar;
|
use ui::avatar::Avatar;
|
||||||
use ui::dialog::DialogButtonProps;
|
use ui::dialog::DialogButtonProps;
|
||||||
use ui::dock::{ClosePanel, DockArea, DockPlacement, PanelHandle};
|
use ui::dock::{ClosePanel, DockArea, DockPlacement, PanelHandle};
|
||||||
@@ -89,10 +89,10 @@ impl Sidebar {
|
|||||||
|
|
||||||
Nav::new(label)
|
Nav::new(label)
|
||||||
.label(label)
|
.label(label)
|
||||||
.suffix(Icon::new(icon).small().text_color(cx.theme().icon_muted))
|
.suffix(Icon::new(icon).small().text_color(cx.theme().text_faint))
|
||||||
.text_xs()
|
.text_xs()
|
||||||
.font_semibold()
|
.font_semibold()
|
||||||
.text_color(cx.theme().text_placeholder)
|
.text_color(cx.theme().text_faint)
|
||||||
.on_click(cx.listener(move |this, _event, _window, cx| {
|
.on_click(cx.listener(move |this, _event, _window, cx| {
|
||||||
match section {
|
match section {
|
||||||
ListSection::Pins => this.pins_open = !this.pins_open,
|
ListSection::Pins => this.pins_open = !this.pins_open,
|
||||||
@@ -114,7 +114,7 @@ impl Sidebar {
|
|||||||
.label(label)
|
.label(label)
|
||||||
.text_xs()
|
.text_xs()
|
||||||
.font_semibold()
|
.font_semibold()
|
||||||
.text_color(cx.theme().text_placeholder)
|
.text_color(cx.theme().text_faint)
|
||||||
.into_any_element()
|
.into_any_element()
|
||||||
}
|
}
|
||||||
SidebarRow::Empty(text) => v_flex()
|
SidebarRow::Empty(text) => v_flex()
|
||||||
@@ -130,9 +130,9 @@ impl Sidebar {
|
|||||||
.border_1()
|
.border_1()
|
||||||
.border_dashed()
|
.border_dashed()
|
||||||
.border_color(cx.theme().border)
|
.border_color(cx.theme().border)
|
||||||
.rounded(cx.theme().radius)
|
.rounded(px(button_radius()))
|
||||||
.text_xs()
|
.text_xs()
|
||||||
.text_color(cx.theme().text_placeholder)
|
.text_color(cx.theme().text_faint)
|
||||||
.child(*text),
|
.child(*text),
|
||||||
)
|
)
|
||||||
.into_any_element(),
|
.into_any_element(),
|
||||||
@@ -162,7 +162,7 @@ impl Sidebar {
|
|||||||
div()
|
div()
|
||||||
.font_normal()
|
.font_normal()
|
||||||
.text_xs()
|
.text_xs()
|
||||||
.text_color(cx.theme().text_placeholder)
|
.text_color(cx.theme().text_faint)
|
||||||
.child(created_at),
|
.child(created_at),
|
||||||
)
|
)
|
||||||
.on_click(move |_event, window, cx| {
|
.on_click(move |_event, window, cx| {
|
||||||
@@ -279,7 +279,7 @@ impl Sidebar {
|
|||||||
div()
|
div()
|
||||||
.font_normal()
|
.font_normal()
|
||||||
.text_xs()
|
.text_xs()
|
||||||
.text_color(cx.theme().text_placeholder)
|
.text_color(cx.theme().text_faint)
|
||||||
.child(suffix),
|
.child(suffix),
|
||||||
)
|
)
|
||||||
})
|
})
|
||||||
@@ -353,7 +353,7 @@ impl Sidebar {
|
|||||||
div()
|
div()
|
||||||
.font_normal()
|
.font_normal()
|
||||||
.text_xs()
|
.text_xs()
|
||||||
.text_color(cx.theme().text_placeholder)
|
.text_color(cx.theme().text_faint)
|
||||||
.child(detail),
|
.child(detail),
|
||||||
)
|
)
|
||||||
.on_click(move |_event, window, cx| {
|
.on_click(move |_event, window, cx| {
|
||||||
|
|||||||
@@ -4,12 +4,12 @@ use std::rc::Rc;
|
|||||||
use chat::{ChatRegistry, Room};
|
use chat::{ChatRegistry, Room};
|
||||||
use gpui::{
|
use gpui::{
|
||||||
AnyElement, App, Context, Entity, IntoElement, ParentElement, SharedString, Styled, Task,
|
AnyElement, App, Context, Entity, IntoElement, ParentElement, SharedString, Styled, Task,
|
||||||
Window, div, uniform_list,
|
Window, div, px, uniform_list,
|
||||||
};
|
};
|
||||||
use nip29::{Group, GroupsRegistry};
|
use nip29::{Group, GroupsRegistry};
|
||||||
use nostr_sdk::prelude::*;
|
use nostr_sdk::prelude::*;
|
||||||
use state::{FIND_LIMIT, NostrRegistry};
|
use state::{FIND_LIMIT, NostrRegistry};
|
||||||
use theme::ActiveTheme;
|
use theme::{ActiveTheme, button_radius};
|
||||||
use ui::button::{Button, ButtonVariants};
|
use ui::button::{Button, ButtonVariants};
|
||||||
use ui::input::Input;
|
use ui::input::Input;
|
||||||
use ui::scroll::Scrollbar;
|
use ui::scroll::Scrollbar;
|
||||||
@@ -201,8 +201,8 @@ impl Sidebar {
|
|||||||
.px_1p5()
|
.px_1p5()
|
||||||
.gap_1()
|
.gap_1()
|
||||||
.w_full()
|
.w_full()
|
||||||
.rounded(cx.theme().radius)
|
.rounded(px(button_radius()))
|
||||||
.bg(cx.theme().elevated_surface_background)
|
.bg(cx.theme().surface_raised)
|
||||||
.child(
|
.child(
|
||||||
Input::new(&self.find_input)
|
Input::new(&self.find_input)
|
||||||
.appearance(false)
|
.appearance(false)
|
||||||
|
|||||||
@@ -439,20 +439,43 @@ should follow:
|
|||||||
exact semantics (`danger` wash source, `danger_muted` ink, `danger_strong`
|
exact semantics (`danger` wash source, `danger_muted` ink, `danger_strong`
|
||||||
plate).
|
plate).
|
||||||
|
|
||||||
- [ ] `crates/chat_ui` (largest: ~200 sites) — chips and rows on
|
- [x] `crates/chat_ui` — all 20 legacy tokens migrated in `lib.rs` (~46
|
||||||
`elevated_surface_background` review to `surface_raised` vs
|
sites). Radius rulings: message media images → `bubble_radius()`;
|
||||||
`surface_card`; reactions/toggles to `element_*`; report banners to
|
reaction/file chips and composer tiles → `control_radius()`; trace
|
||||||
`warning_muted`/`danger_muted`.
|
callout → `panel_radius()`; warning/danger report strips and the
|
||||||
- [ ] `crates/workspace` — tabs, dock, settings dialog, theme picker.
|
floating hover toolbar → `surface_radius()`. `elevated_surface`
|
||||||
Note: the settings dialog's Light/Dark buttons call `Theme::change`
|
split: relay chips / reply-row hover → `surface_raised`, success
|
||||||
directly; they should move to `AppExt::set_appearance_mode` (and gain a
|
report box → `surface_card`. Warning sites got the bezel strip
|
||||||
System option) in Phase 4.
|
treatment (`warning_muted` wash + `warning` ink); failed-report rows
|
||||||
- [ ] `crates/nip29_ui`, `crates/settings`, `crates/nip4e`, `desktop`, `web`.
|
got the error-strip recipe (`danger` @6% + `danger_muted` @90%).
|
||||||
- [ ] Replace `radius`/`radius_lg` with the ratio function the element is
|
- [x] `crates/workspace` — 58 sites across 18 files. Radius: warning
|
||||||
(control inside control → 0.75x, control → 1x, card → 1.25x, floating →
|
strips → `surface_radius()`; input plates and control rows →
|
||||||
1.5x, bubble → 2x). This is the judgment-heavy step; do it per crate,
|
`button_radius()`; request-count chip → `control_radius()`; browse
|
||||||
not with sed.
|
cards and empty states → `panel_radius()`. `text_danger` → `danger`
|
||||||
- [ ] `cargo check --workspace` clean; `grep -rn "theme().\(element\|secondary\|ghost_element\|tab_\|icon\|warning_\|danger_\|title_bar\|window_border\|panel_background\|surface_background\|elevated\)"` returns nothing.
|
everywhere (each site was its view's only error signal). The "new
|
||||||
|
requests" bead in the sidebar (old `cursor` token, an accent blue)
|
||||||
|
→ `accent`, not `caret` — it is an attention marker, not a text
|
||||||
|
cursor. Settings dialog's `Theme::change` calls left for Phase 4.
|
||||||
|
- [x] `crates/nip29_ui`, `crates/nip4e` — 27 sites. Activity-row hover →
|
||||||
|
`element_hover` (it interleaves with `MessageRow` in one list);
|
||||||
|
message media → `bubble_radius()`; chips/pills → `control_radius()`;
|
||||||
|
nip4e plates → `surface_card`. Flag for the design pass: the pin
|
||||||
|
chip now paints `solid` under a `text_muted` label — that pairing
|
||||||
|
predates the migration (old `element_background` + `text_muted`);
|
||||||
|
if it reads loud, its label should become `on_solid`.
|
||||||
|
- [x] `crates/settings`, `desktop`, `web` — verified zero theme-token
|
||||||
|
reads (their appearance wiring is Phase 4 scope).
|
||||||
|
- [x] Replace `radius`/`radius_lg` with the ratio function the element is
|
||||||
|
— done per crate by the agents above (not sed); rulings recorded
|
||||||
|
per bullet.
|
||||||
|
- [x] `cargo check --workspace` clean; the Phase 3 grep gate (extended
|
||||||
|
with `surface_background`, `background`, `cursor`, `drop_target_background`)
|
||||||
|
returns nothing across crates and `desktop`/`web`.
|
||||||
|
|
||||||
|
Follow-ups noted: chat_ui paints delivery/status marks with hardcoded
|
||||||
|
`gpui::green()`/`red()` — candidates for the `success`/`busy`/`danger`
|
||||||
|
status-dot recipe in a later polish pass; warning strips carry no 20%-alpha
|
||||||
|
ring (no border existed; adding one is a structure change).
|
||||||
|
|
||||||
### Phase 4 — Settings, registry, shipped themes
|
### Phase 4 — Settings, registry, shipped themes
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user