Maui with Material Design

Viewed 233

I am building a Maui App for the first time and want to employ Material Design. I normally use MahApps or Material design depending on the project. However, when adding the resource dictionary I get a Uri error

 <Application xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
    xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
    xmlns:local="clr-namespace:Presentation"
    x:Class="Presentation.App">
 <Application.Resources>
        <ResourceDictionary>
            <ResourceDictionary.MergedDictionaries>
                <ResourceDictionary Source="Resources/Styles/Colors.xaml" />
                <ResourceDictionary Source="Resources/Styles/Styles.xaml" />
                <ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesignTheme.Defaults.xaml" />
                <ResourceDictionary Source="pack://application:,,,/MaterialDesignExtensions;component/Themes/Generic.xaml" />
                <ResourceDictionary Source="pack://application:,,,/MaterialDesignExtensions;component/Themes/MaterialDesignLightTheme.xaml" />
            </ResourceDictionary.MergedDictionaries>
        </ResourceDictionary>
    </Application.Resources>
</Application>

The code blows up everytime but if I miss out the last 3 resource dictionaries (those referring to Material Design) I get no issues. I've added Material Design as a NuGet package as well as the extensions. Can anyone see anything daft that I have done???

Thanks

0 Answers
Related