Use text color to paint SVGs

This commit is contained in:
Antonio Scandurra 2023-10-18 09:39:20 +02:00
parent e031718747
commit 597a9f9548
5 changed files with 22 additions and 20 deletions

View file

@ -121,7 +121,7 @@ impl<S: 'static + Send + Sync + Clone> CollabPanel<S> {
})
.w_3p5()
.h_3p5()
.fill(theme.middle.variant.default.foreground),
.text_color(theme.middle.variant.default.foreground),
),
)
}

View file

@ -183,7 +183,10 @@ impl<S: 'static + Send + Sync> IconElement<S> {
IconSize::Large => svg().size_4(),
};
sized_svg.flex_none().path(self.icon.path()).fill(fill)
sized_svg
.flex_none()
.path(self.icon.path())
.text_color(fill)
}
}