整理代码

This commit is contained in:
GG Z
2026-02-20 15:31:44 +08:00
parent 94cf3f3266
commit 9f121cfc7f
149 changed files with 4063 additions and 6964 deletions

View File

@@ -1,11 +1,11 @@
<ResourceDictionary
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:controls="clr-namespace:Melskin.Controls"
xmlns:decorations="clr-namespace:Melskin.Controls.Decorations"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
xmlns:decorations="clr-namespace:Melskin.Controls.Decorations">
<Style TargetType="{x:Type controls:Chip}" x:Key="EmbossChipStyle">
<Style x:Key="EmbossChipStyle" TargetType="{x:Type controls:Chip}">
<Setter Property="Background" Value="{DynamicResource PrimaryVariantBrush}" />
<Setter Property="BorderBrush" Value="Transparent" />
<Setter Property="Cursor" Value="Hand" />
@@ -20,43 +20,43 @@
<Setter.Value>
<ControlTemplate TargetType="{x:Type controls:Chip}">
<decorations:EmbossBorder
CornerRadius="3"
x:Name="rootBorder"
Margin="-4"
Padding="0"
ToolTip="{TemplateBinding Url}"
x:Name="rootBorder">
CornerRadius="3"
ToolTip="{TemplateBinding Url}">
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto" />
<ColumnDefinition Width="Auto" />
</Grid.ColumnDefinitions>
<Border
x:Name="headBorder"
Padding="{TemplateBinding Padding}"
Background="{TemplateBinding HeadBackground}"
CornerRadius="3,0,0,3"
Padding="{TemplateBinding Padding}"
TextBlock.FontWeight="Bold"
TextBlock.Foreground="{TemplateBinding HeadForeground}"
x:Name="headBorder">
TextBlock.Foreground="{TemplateBinding HeadForeground}">
<ContentPresenter
VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
ContentSource="Header"
Focusable="False"
RecognizesAccessKey="True"
SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"
VerticalAlignment="{TemplateBinding VerticalContentAlignment}" />
SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" />
</Border>
<Border
Background="{TemplateBinding Background}"
CornerRadius="0,3,3,0"
x:Name="contentBorder"
Grid.Column="1"
Padding="{TemplateBinding Padding}"
Background="{TemplateBinding Background}"
CornerRadius="0,3,3,0"
TextBlock.FontWeight="Bold"
TextBlock.Foreground="{TemplateBinding Foreground}"
x:Name="contentBorder">
TextBlock.Foreground="{TemplateBinding Foreground}">
<ContentPresenter
VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
Focusable="False"
RecognizesAccessKey="True"
SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"
VerticalAlignment="{TemplateBinding VerticalContentAlignment}" />
SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" />
</Border>
</Grid>
</decorations:EmbossBorder>
@@ -65,8 +65,8 @@
<Setter Property="Cursor" Value="Arrow" />
</Trigger>
<Trigger Property="Header" Value="{x:Null}">
<Setter Property="CornerRadius" TargetName="contentBorder" Value="3" />
<Setter Property="Padding" TargetName="headBorder" Value="0" />
<Setter TargetName="contentBorder" Property="CornerRadius" Value="3" />
<Setter TargetName="headBorder" Property="Padding" Value="0" />
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
@@ -90,42 +90,42 @@
<Setter.Value>
<ControlTemplate TargetType="{x:Type controls:Chip}">
<Border
CornerRadius="3"
x:Name="rootBorder"
Padding="0"
ToolTip="{TemplateBinding Url}"
x:Name="rootBorder">
CornerRadius="3"
ToolTip="{TemplateBinding Url}">
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto" />
<ColumnDefinition Width="Auto" />
</Grid.ColumnDefinitions>
<Border
x:Name="headBorder"
Padding="{TemplateBinding Padding}"
Background="{TemplateBinding HeadBackground}"
CornerRadius="3,0,0,3"
Padding="{TemplateBinding Padding}"
TextBlock.FontWeight="Bold"
TextBlock.Foreground="{TemplateBinding HeadForeground}"
x:Name="headBorder">
TextBlock.Foreground="{TemplateBinding HeadForeground}">
<ContentPresenter
VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
ContentSource="Header"
Focusable="False"
RecognizesAccessKey="True"
SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"
VerticalAlignment="{TemplateBinding VerticalContentAlignment}" />
SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" />
</Border>
<Border
Background="{TemplateBinding Background}"
CornerRadius="0,3,3,0"
x:Name="contentBorder"
Grid.Column="1"
Padding="{TemplateBinding Padding}"
Background="{TemplateBinding Background}"
CornerRadius="0,3,3,0"
TextBlock.FontWeight="Bold"
TextBlock.Foreground="{TemplateBinding Foreground}"
x:Name="contentBorder">
TextBlock.Foreground="{TemplateBinding Foreground}">
<ContentPresenter
VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
Focusable="False"
RecognizesAccessKey="True"
SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"
VerticalAlignment="{TemplateBinding VerticalContentAlignment}" />
SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" />
</Border>
</Grid>
</Border>
@@ -134,8 +134,8 @@
<Setter Property="Cursor" Value="Arrow" />
</Trigger>
<Trigger Property="Header" Value="{x:Null}">
<Setter Property="CornerRadius" TargetName="contentBorder" Value="3" />
<Setter Property="Padding" TargetName="headBorder" Value="0" />
<Setter TargetName="contentBorder" Property="CornerRadius" Value="3" />
<Setter TargetName="headBorder" Property="Padding" Value="0" />
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>