commit f2deead90580f749f5f5e0026559da92a5ed31c9
parent 7ab5f09a59e52b6b781e99251abdedd38fe16011
Author: triesap <tyson@radroots.org>
Date: Sun, 7 Jun 2026 11:26:38 -0700
ui: round account dropdown trigger
Diffstat:
1 file changed, 4 insertions(+), 14 deletions(-)
diff --git a/crates/ui/src/primitives.rs b/crates/ui/src/primitives.rs
@@ -715,26 +715,16 @@ pub fn app_button_compact(
pub fn app_button_square_dropdown_secondary(
id: &'static str,
menu: impl Fn(PopupMenu, &mut Window, &mut Context<PopupMenu>) -> PopupMenu + 'static,
- cx: &App,
+ _cx: &App,
) -> impl IntoElement {
let sizing = APP_UI_THEME.components.app_button.sizing;
let colors = APP_UI_THEME.components.app_button.secondary_colors;
- let hover_background = if colors.hover_changes_background {
- colors.hover_background
- } else {
- colors.background
- };
- let neutral_variant = ButtonCustomVariant::new(cx)
- .color(rgb(colors.background).into())
- .foreground(rgb(colors.foreground).into())
- .border(transparent_black())
- .hover(rgb(hover_background).into())
- .active(rgb(colors.active_background).into());
div()
.w(px(sizing.square_width_px))
.h(px(sizing.height_px))
.rounded(px(sizing.corner_radius_px))
+ .bg(rgb(colors.background))
.overflow_hidden()
.child(
DropdownButton::new(id)
@@ -743,11 +733,11 @@ pub fn app_button_square_dropdown_secondary(
.tab_stop(false)
.w(px(0.0))
.overflow_hidden()
- .custom(neutral_variant)
+ .ghost()
.with_size(Size::Size(px(sizing.square_width_px))),
)
.dropdown_menu(menu)
- .custom(neutral_variant)
+ .ghost()
.rounded(ButtonRounded::Size(px(sizing.corner_radius_px)))
.with_size(Size::Size(px(sizing.square_width_px))),
)