Maui svg icons with light and dark theme styles

1k Views Asked by At

Is it possible to set the style of the svg icon based on if the Maui app is in light/dark theme? I know that Microsoft suggests creating two separate files, one for light and one for dark themes: https://learn.microsoft.com/en-us/dotnet/maui/user-interface/system-theme-changes

But it would be much more useful to have a single svg file and set the styling within the file: Creating SVG that appears black in light mode and light in dark mode

Can an svg <style> setter be conditional to the AppTheme in Maui apps?

0

There are 0 best solutions below