Skip to content

Commit

Permalink
Display mod descriptions, switch to material.avalonia
Browse files Browse the repository at this point in the history
  • Loading branch information
geefr committed Jul 3, 2021
1 parent bc18baf commit 3ed971a
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 7 deletions.
2 changes: 1 addition & 1 deletion Beataroni/Beataroni.Tests/Beataroni.Tests.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
<PrivateAssets>all</PrivateAssets>
</PackageReference>
<PackageReference Include="coverlet.collector" Version="1.3.0">
<PackageReference Include="coverlet.collector" Version="3.0.3">
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
<PrivateAssets>all</PrivateAssets>
</PackageReference>
Expand Down
5 changes: 5 additions & 0 deletions Beataroni/Beataroni/App.xaml
Original file line number Diff line number Diff line change
@@ -1,13 +1,18 @@
<Application xmlns="https://github.com/avaloniaui"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="clr-namespace:Beataroni"
xmlns:themes="clr-namespace:Material.Styles.Themes;assembly=Material.Styles"
x:Class="Beataroni.App">
<Application.DataTemplates>
<local:ViewLocator/>
</Application.DataTemplates>

<Application.Resources>
<themes:BundledTheme BaseTheme="Dark" PrimaryColor="Teal" SecondaryColor="Amber"/>
</Application.Resources>
<Application.Styles>
<StyleInclude Source="avares://Avalonia.Themes.Default/DefaultTheme.xaml"/>
<StyleInclude Source="avares://Avalonia.Themes.Default/Accents/BaseDark.xaml"/>
<StyleInclude Source="avares://Material.Avalonia/Material.Avalonia.Templates.xaml" />
</Application.Styles>
</Application>
1 change: 1 addition & 0 deletions Beataroni/Beataroni/Beataroni.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@
<PackageReference Include="Avalonia" Version="0.10.0" />
<PackageReference Include="Avalonia.Desktop" Version="0.10.0" />
<PackageReference Include="Avalonia.ReactiveUI" Version="0.10.0" />
<PackageReference Include="Material.Avalonia" Version="2.2.0" />
</ItemGroup>
<ItemGroup>
<Compile Update="Views\ModInstallView.xaml.cs">
Expand Down
21 changes: 15 additions & 6 deletions Beataroni/Beataroni/Views/ModsView.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,21 @@
<ItemsControl Items="{Binding Mods}">
<ItemsControl.ItemTemplate>
<DataTemplate>
<CheckBox
IsChecked="{Binding selected}"
Content="{Binding mod.name}"
Command="{Binding $parent[UserControl].DataContext.ModChecked}"
CommandParameter="{Binding .}"
/>
<Border Background="Black"
BorderBrush="Gray"
BorderThickness="2"
Padding="15">
<StackPanel Orientation="Vertical">
<CheckBox
IsChecked="{Binding selected}"
Content="{Binding mod.name}"
Command="{Binding $parent[UserControl].DataContext.ModChecked}"
CommandParameter="{Binding .}"
Background="White"
/>
<TextBlock Text="{Binding mod.description}" TextWrapping="Wrap" Width="300" HorizontalAlignment="Center"/>
</StackPanel>
</Border>
</DataTemplate>
</ItemsControl.ItemTemplate>
</ItemsControl>
Expand Down

0 comments on commit 3ed971a

Please sign in to comment.