Set sidebar icon heights via theme

Co-Authored-By: Max Brunsfeld <maxbrunsfeld@gmail.com>
This commit is contained in:
Nathan Sobo
2021-09-07 12:45:48 -06:00
co-authored by Max Brunsfeld
parent e2b30ad031
commit b29e673c43
3 changed files with 13 additions and 7 deletions
+3 -3
View File
@@ -71,9 +71,9 @@ impl Sidebar {
Flex::column()
.with_children(self.items.iter().enumerate().map(|(item_index, item)| {
let theme = if Some(item_index) == self.active_item_ix {
&settings.theme.workspace.active_sidebar_icon
&settings.theme.workspace.sidebar.active_icon
} else {
&settings.theme.workspace.sidebar_icon
&settings.theme.workspace.sidebar.icon
};
enum SidebarButton {}
MouseEventHandler::new::<SidebarButton, _, _, _>(item.view.id(), cx, |_, _| {
@@ -82,7 +82,7 @@ impl Sidebar {
ConstrainedBox::new(
Svg::new(item.icon_path).with_color(theme.color).boxed(),
)
.with_height(line_height)
.with_height(theme.height)
.boxed(),
)
.boxed(),