Clarify activity bar tooltips

This commit is contained in:
2026-07-19 21:46:19 +02:00
parent 23981ce2ae
commit ca7b864261
3 changed files with 29 additions and 14 deletions

View File

@@ -5,6 +5,7 @@ use iced::{Background, Border, Color, Element, Length, Theme};
use bds_core::i18n::UiLocale;
use crate::app::Message;
use crate::components::inputs;
use crate::i18n::t;
use crate::state::navigation::SidebarView;
@@ -145,6 +146,7 @@ pub fn view(
tooltip::Position::Right,
)
.gap(4)
.style(inputs::tooltip_style)
.into()
};

View File

@@ -7,6 +7,7 @@ use iced::{Background, Border, Color, Element, Font, Length, Theme};
use bds_core::i18n::UiLocale;
use crate::app::Message;
use crate::components::inputs;
use crate::i18n::t;
use crate::state::tabs::Tab;
@@ -79,19 +80,6 @@ fn close_style(_theme: &Theme, status: button::Status) -> button::Style {
}
}
/// Tooltip style.
fn tooltip_style(_theme: &Theme) -> container::Style {
container::Style {
background: Some(Background::Color(Color::from_rgb(0.20, 0.20, 0.24))),
border: Border {
color: Color::from_rgb(0.35, 0.35, 0.40),
width: 1.0,
radius: 6.0.into(),
},
..container::Style::default()
}
}
/// Truncate chat title per tabs.allium: chat_title_max_length = 18.
fn truncate_chat_title(title: &str) -> String {
if title.chars().count() > CHAT_TITLE_MAX_LEN {
@@ -214,7 +202,7 @@ pub fn view(tabs: &[Tab], active_tab: Option<&str>, locale: UiLocale) -> Element
Position::Bottom,
)
.gap(4)
.style(tooltip_style)
.style(inputs::tooltip_style)
.into();
tip