This commit is contained in:
ShrlAlgo
2025-07-11 09:20:23 +08:00
parent c7b104f44f
commit 4d35cadb56
840 changed files with 102347 additions and 11595 deletions

View File

@@ -1,25 +1,15 @@
<!--
This Source Code Form is subject to the terms of the MIT License.
If a copy of the MIT was not distributed with this file, You can obtain one at https://opensource.org/licenses/MIT.
Copyright (C) Leszek Pomianowski and WPF UI Contributors.
All Rights Reserved.
Based on Microsoft XAML for Win UI
Copyright (c) Microsoft Corporation. All Rights Reserved.
-->
<ResourceDictionary
<ResourceDictionary
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:controls="clr-namespace:WPFluent.Controls">
xmlns:controls="clr-namespace:WPFluent.Controls"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
<Thickness x:Key="CardPadding">14,16,14,16</Thickness>
<Thickness x:Key="CardBorderThemeThickness">1</Thickness>
<Style TargetType="{x:Type controls:Card}">
<Setter Property="Background" Value="{DynamicResource CardBackground}" />
<Setter Property="Foreground" Value="{DynamicResource CardForeground}" />
<Setter Property="BorderBrush" Value="{DynamicResource CardBorderBrush}" />
<Setter Property="Background" Value="{DynamicResource CardBackgroundFillColorDefaultBrush}" />
<Setter Property="Foreground" Value="{DynamicResource TextFillColorPrimaryBrush}" />
<Setter Property="BorderBrush" Value="{DynamicResource CardStrokeColorDefaultBrush}" />
<Setter Property="BorderThickness" Value="{StaticResource CardBorderThemeThickness}" />
<Setter Property="Padding" Value="{StaticResource CardPadding}" />
<Setter Property="HorizontalAlignment" Value="Stretch" />
@@ -43,38 +33,38 @@
</Grid.RowDefinitions>
<Border
x:Name="ContentBorder"
Padding="{TemplateBinding Padding}"
HorizontalAlignment="{TemplateBinding HorizontalAlignment}"
VerticalAlignment="{TemplateBinding VerticalAlignment}"
Background="{TemplateBinding Background}"
BorderBrush="{TemplateBinding BorderBrush}"
BorderThickness="{TemplateBinding BorderThickness}"
CornerRadius="{TemplateBinding Border.CornerRadius}">
CornerRadius="{TemplateBinding Border.CornerRadius}"
HorizontalAlignment="{TemplateBinding HorizontalAlignment}"
Padding="{TemplateBinding Padding}"
VerticalAlignment="{TemplateBinding VerticalAlignment}"
x:Name="ContentBorder">
<ContentPresenter
x:Name="ContentPresenter"
HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
VerticalAlignment="{TemplateBinding VerticalContentAlignment}" />
VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
x:Name="ContentPresenter" />
</Border>
<Border
x:Name="FooterBorder"
Grid.Row="1"
Padding="{TemplateBinding Padding}"
Background="{DynamicResource CardFooterBackground}"
Background="{DynamicResource CardBackgroundFillColorSecondaryBrush}"
BorderBrush="{TemplateBinding BorderBrush}"
BorderThickness="1"
CornerRadius="0,0,4,4"
Visibility="Collapsed">
<ContentPresenter x:Name="FooterContentPresenter" Content="{TemplateBinding Footer}" />
Grid.Row="1"
Padding="{TemplateBinding Padding}"
Visibility="Collapsed"
x:Name="FooterBorder">
<ContentPresenter Content="{TemplateBinding Footer}" x:Name="FooterContentPresenter" />
</Border>
</Grid>
<ControlTemplate.Triggers>
<Trigger Property="HasFooter" Value="True">
<Setter TargetName="FooterBorder" Property="Visibility" Value="Visible" />
<Setter TargetName="ContentBorder" Property="CornerRadius" Value="4,4,0,0" />
<Setter TargetName="ContentBorder" Property="BorderThickness" Value="1,1,1,0" />
<Setter Property="Visibility" TargetName="FooterBorder" Value="Visible" />
<Setter Property="CornerRadius" TargetName="ContentBorder" Value="4,4,0,0" />
<Setter Property="BorderThickness" TargetName="ContentBorder" Value="1,1,1,0" />
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>