livia-test/Livia/Resources/Themes/LiviaButton.xaml
2025-03-28 14:31:53 +08:00

678 lines
37 KiB
XML

<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:materialDesign="http://materialdesigninxaml.net/winfx/xaml/themes"
xmlns:attachedProperties="clr-namespace:Livia.Views.AttachedProperties">
<Style TargetType="{x:Type ButtonBase}"
x:Key="LiviaTextButtonBase">
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type ButtonBase}">
<Grid>
<Button Style="{StaticResource MaterialDesignRaisedButton}"
Name="Button"
Height="40"
HorizontalAlignment="Center"
VerticalAlignment="Center"
materialDesign:ButtonAssist.CornerRadius="20"
materialDesign:ElevationAssist.Elevation="Dp0"
BorderBrush="{TemplateBinding BorderBrush}"
Background="{TemplateBinding Background}"
Foreground="{TemplateBinding Foreground}">
<TextBlock Style="{StaticResource MaterialDesignButtonTextBlock}"
Margin="20, 0, 20, 1.5"
VerticalAlignment="Center"
Text="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(attachedProperties:StringItemProperties.ItemName)}"
Name="ButtonText" />
</Button>
</Grid>
<ControlTemplate.Triggers>
<Trigger Property="IsMouseOver"
Value="True">
<Setter TargetName="Button"
Property="BorderBrush"
Value="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(attachedProperties:SolidColorBrushProperties.SolidColorBrush1)}" />
<Setter TargetName="Button"
Property="Background"
Value="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(attachedProperties:SolidColorBrushProperties.SolidColorBrush2)}" />
<Setter TargetName="Button"
Property="Foreground"
Value="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(attachedProperties:SolidColorBrushProperties.SolidColorBrush3)}" />
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style TargetType="{x:Type ButtonBase}"
BasedOn="{StaticResource LiviaTextButtonBase}"
x:Key="LiviaPrimaryTextButton">
<Setter Property="BorderBrush"
Value="{StaticResource PrimaryColorHighlightBrush}" />
<Setter Property="Background"
Value="{StaticResource PrimaryColorHighlightBrush}" />
<Setter Property="Foreground"
Value="{StaticResource White1Brush}" />
<Setter Property="attachedProperties:StringItemProperties.ItemName"
Value="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(attachedProperties:StringItemProperties.ItemName)}" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush1"
Value="{StaticResource PrimaryColorAlternativeBrush}" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush2"
Value="{StaticResource PrimaryColorAlternativeBrush}" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush3"
Value="{StaticResource White1Brush}" />
</Style>
<Style TargetType="{x:Type ButtonBase}"
BasedOn="{StaticResource LiviaTextButtonBase}"
x:Key="LiviaDarkTextButton">
<Setter Property="BorderBrush"
Value="{StaticResource PrimaryColorHighlightBrush}" />
<Setter Property="Background"
Value="Transparent" />
<Setter Property="Foreground"
Value="{StaticResource White1Brush}" />
<Setter Property="attachedProperties:StringItemProperties.ItemName"
Value="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(attachedProperties:StringItemProperties.ItemName)}" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush1"
Value="{StaticResource PrimaryColorAlternativeBrush}" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush2"
Value="{StaticResource PrimaryColorAlternativeBrush}" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush3"
Value="{StaticResource White1Brush}" />
</Style>
<Style TargetType="{x:Type ButtonBase}"
BasedOn="{StaticResource LiviaTextButtonBase}"
x:Key="LiviaWhiteTextButton">
<Setter Property="BorderBrush"
Value="{StaticResource PrimaryColorBrush}" />
<Setter Property="Background"
Value="{StaticResource White1Brush}" />
<Setter Property="Foreground"
Value="{StaticResource PrimaryColorBrush}" />
<Setter Property="attachedProperties:StringItemProperties.ItemName"
Value="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(attachedProperties:StringItemProperties.ItemName)}" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush1"
Value="{StaticResource PrimaryColorBrush}" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush2"
Value="{StaticResource PrimaryColorAlternativeBrush}" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush3"
Value="{StaticResource White1Brush}" />
</Style>
<Style TargetType="{x:Type ButtonBase}"
BasedOn="{StaticResource LiviaTextButtonBase}"
x:Key="LiviaLoginTextButton">
<Setter Property="BorderBrush"
Value="{StaticResource LoginColorBrush}" />
<Setter Property="Background"
Value="{StaticResource LoginColorBrush}" />
<Setter Property="Foreground"
Value="{StaticResource White1Brush}" />
<Setter Property="attachedProperties:StringItemProperties.ItemName"
Value="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(attachedProperties:StringItemProperties.ItemName)}" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush1"
Value="{StaticResource LoginColorBrush}" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush2"
Value="{StaticResource LoginAlternativeColorBrush}" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush3"
Value="{StaticResource White1Brush}" />
</Style>
<Style TargetType="{x:Type ButtonBase}"
BasedOn="{StaticResource LiviaTextButtonBase}"
x:Key="LiviaAlertTextButton">
<Setter Property="BorderBrush"
Value="{StaticResource AlertColorBrush}" />
<Setter Property="Background"
Value="{StaticResource White1Brush}" />
<Setter Property="Foreground"
Value="{StaticResource AlertColorBrush}" />
<Setter Property="attachedProperties:StringItemProperties.ItemName"
Value="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(attachedProperties:StringItemProperties.ItemName)}" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush1"
Value="{StaticResource AlertColorBrush}" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush2"
Value="{StaticResource AlertAlternativeColorBrush}" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush3"
Value="{StaticResource White1Brush}" />
</Style>
<Style TargetType="{x:Type ButtonBase}"
x:Key="LiviaTinyIconButtonBase">
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type ButtonBase}">
<Border Name="Border"
Width="20"
Height="20"
BorderThickness="1"
BorderBrush="{TemplateBinding BorderBrush}"
CornerRadius="36"
Background="{TemplateBinding Background}">
<Button Name="Button"
Style="{StaticResource MaterialDesignRaisedButton}"
Padding="0"
HorizontalAlignment="Center"
VerticalAlignment="Center"
Height="20"
Width="20"
materialDesign:ElevationAssist.Elevation="Dp0"
BorderThickness="0"
Command="{TemplateBinding Command}"
CommandParameter="{TemplateBinding CommandParameter}"
Background="Transparent"
Foreground="{TemplateBinding Foreground}">
<materialDesign:PackIcon Kind="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(attachedProperties:IconKindProperties.IconKind)}"
Padding="20"
Margin="0"
Width="16"
Height="16"
Name="ButtonIcon" />
</Button>
</Border>
<ControlTemplate.Triggers>
<Trigger Property="IsMouseOver"
Value="True">
<Setter TargetName="Border"
Property="Background"
Value="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(attachedProperties:SolidColorBrushProperties.SolidColorBrush1)}" />
<Setter TargetName="Border"
Property="BorderBrush"
Value="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(attachedProperties:SolidColorBrushProperties.SolidColorBrush2)}" />
<Setter TargetName="Button"
Property="Foreground"
Value="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(attachedProperties:SolidColorBrushProperties.SolidColorBrush3)}" />
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style TargetType="{x:Type ButtonBase}"
BasedOn="{StaticResource LiviaTinyIconButtonBase}"
x:Key="LiviaPrimaryTinyIconButton">
<Setter Property="ToolTipService.InitialShowDelay"
Value="100" />
<Setter Property="Background"
Value="Transparent" />
<Setter Property="Foreground"
Value="{StaticResource DataGridAlternatingRowBackgroundBrush}" />
<Setter Property="BorderBrush"
Value="Transparent" />
<Setter Property="attachedProperties:IconKindProperties.IconKind"
Value="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(attachedProperties:IconKindProperties.IconKind)}" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush1"
Value="Transparent" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush2"
Value="Transparent" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush3"
Value="{StaticResource PrimaryColorHighlightBrush}" />
</Style>
<Style TargetType="{x:Type ButtonBase}"
x:Key="LiviaIconButtonBase">
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type ButtonBase}">
<Border Name="Border"
Width="36"
Height="36"
BorderThickness="1"
BorderBrush="{TemplateBinding BorderBrush}"
CornerRadius="36"
Background="{TemplateBinding Background}">
<Button Name="Button"
Style="{StaticResource MaterialDesignRaisedButton}"
Padding="0"
HorizontalAlignment="Center"
VerticalAlignment="Center"
Height="36"
Width="36"
materialDesign:ElevationAssist.Elevation="Dp0"
BorderThickness="0"
Command="{TemplateBinding Command}"
CommandParameter="{TemplateBinding CommandParameter}"
Background="Transparent"
Foreground="{TemplateBinding Foreground}">
<materialDesign:PackIcon Kind="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(attachedProperties:IconKindProperties.IconKind)}"
Padding="0"
Margin="0"
Width="16"
Height="16"
Name="ButtonIcon" />
</Button>
</Border>
<ControlTemplate.Triggers>
<Trigger Property="IsMouseOver"
Value="True">
<Setter TargetName="Border"
Property="Background"
Value="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(attachedProperties:SolidColorBrushProperties.SolidColorBrush1)}" />
<Setter TargetName="Border"
Property="BorderBrush"
Value="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(attachedProperties:SolidColorBrushProperties.SolidColorBrush2)}" />
<Setter TargetName="Button"
Property="Foreground"
Value="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(attachedProperties:SolidColorBrushProperties.SolidColorBrush3)}" />
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style TargetType="{x:Type ButtonBase}"
BasedOn="{StaticResource LiviaIconButtonBase}"
x:Key="LiviaAlertIconButton">
<Setter Property="Background"
Value="Transparent" />
<Setter Property="Foreground"
Value="{StaticResource AlertColorBrush}" />
<Setter Property="BorderBrush"
Value="Transparent" />
<Setter Property="attachedProperties:IconKindProperties.IconKind"
Value="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(attachedProperties:IconKindProperties.IconKind)}" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush1"
Value="Transparent" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush2"
Value="Transparent" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush3"
Value="{StaticResource AlertAlternativeColorBrush}" />
</Style>
<Style TargetType="{x:Type ButtonBase}"
BasedOn="{StaticResource LiviaIconButtonBase}"
x:Key="LiviaPrimaryIconButton">
<Setter Property="Background"
Value="Transparent" />
<Setter Property="Foreground"
Value="{StaticResource PrimaryTextColorBrush}" />
<Setter Property="BorderBrush"
Value="Transparent" />
<Setter Property="attachedProperties:IconKindProperties.IconKind"
Value="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(attachedProperties:IconKindProperties.IconKind)}" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush1"
Value="Transparent" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush2"
Value="Transparent" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush3"
Value="{StaticResource White1Brush}" />
</Style>
<Style TargetType="{x:Type ButtonBase}"
x:Key="LiviaTextProcessingButtonBase">
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type ButtonBase}">
<Grid>
<Button Style="{StaticResource MaterialDesignRaisedButton}"
Name="Button"
Height="40"
HorizontalAlignment="Center"
VerticalAlignment="Center"
materialDesign:ButtonAssist.CornerRadius="20"
materialDesign:ElevationAssist.Elevation="Dp0"
BorderBrush="{TemplateBinding BorderBrush}"
Background="{TemplateBinding Background}"
Foreground="{TemplateBinding Foreground}">
<StackPanel Orientation="Horizontal"
Margin="20, 0, 20, 1.5">
<TextBlock Style="{StaticResource MaterialDesignButtonTextBlock}"
Text="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(attachedProperties:StringItemProperties.ItemName)}"
Name="ButtonText" />
<Grid Width="{Binding ActualWidth, ElementName=ButtonText}"
Name="ProgressBar">
<ProgressBar IsIndeterminate="True"
Foreground="{TemplateBinding Foreground}"
Style="{StaticResource MaterialDesignCircularProgressBar}" />
</Grid>
</StackPanel>
</Button>
</Grid>
<ControlTemplate.Triggers>
<Trigger Property="IsMouseOver"
Value="True">
<Setter TargetName="Button"
Property="BorderBrush"
Value="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(attachedProperties:SolidColorBrushProperties.SolidColorBrush1)}" />
<Setter TargetName="Button"
Property="Background"
Value="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(attachedProperties:SolidColorBrushProperties.SolidColorBrush2)}" />
<Setter TargetName="Button"
Property="Foreground"
Value="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(attachedProperties:SolidColorBrushProperties.SolidColorBrush3)}" />
</Trigger>
<Trigger Property="IsEnabled"
Value="True">
<Setter TargetName="ProgressBar"
Property="Visibility"
Value="Collapsed" />
</Trigger>
<Trigger Property="IsEnabled"
Value="False">
<Setter TargetName="ButtonText"
Property="Visibility"
Value="Collapsed" />
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style TargetType="{x:Type ButtonBase}"
BasedOn="{StaticResource LiviaTextProcessingButtonBase}"
x:Key="LiviaPrimaryProcessingTextButton">
<Setter Property="BorderBrush"
Value="{StaticResource PrimaryColorHighlightBrush}" />
<Setter Property="Background"
Value="{StaticResource PrimaryColorHighlightBrush}" />
<Setter Property="Foreground"
Value="{StaticResource White1Brush}" />
<Setter Property="attachedProperties:StringItemProperties.ItemName"
Value="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(attachedProperties:StringItemProperties.ItemName)}" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush1"
Value="{StaticResource PrimaryColorAlternativeBrush}" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush2"
Value="{StaticResource PrimaryColorAlternativeBrush}" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush3"
Value="{StaticResource White1Brush}" />
</Style>
<Style TargetType="{x:Type ButtonBase}"
BasedOn="{StaticResource LiviaTextProcessingButtonBase}"
x:Key="LiviaDarkProcessingTextButton">
<Setter Property="BorderBrush"
Value="{StaticResource PrimaryColorHighlightBrush}" />
<Setter Property="Background"
Value="Transparent" />
<Setter Property="Foreground"
Value="{StaticResource White1Brush}" />
<Setter Property="attachedProperties:StringItemProperties.ItemName"
Value="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(attachedProperties:StringItemProperties.ItemName)}" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush1"
Value="{StaticResource PrimaryColorAlternativeBrush}" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush2"
Value="{StaticResource PrimaryColorAlternativeBrush}" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush3"
Value="{StaticResource White1Brush}" />
</Style>
<Style TargetType="{x:Type ButtonBase}"
BasedOn="{StaticResource LiviaTextProcessingButtonBase}"
x:Key="LiviaAlertProcessingTextButton">
<Setter Property="BorderBrush"
Value="{StaticResource AlertColorBrush}" />
<Setter Property="Background"
Value="{StaticResource White1Brush}" />
<Setter Property="Foreground"
Value="{StaticResource AlertColorBrush}" />
<Setter Property="attachedProperties:StringItemProperties.ItemName"
Value="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(attachedProperties:StringItemProperties.ItemName)}" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush1"
Value="{StaticResource AlertColorBrush}" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush2"
Value="{StaticResource AlertAlternativeColorBrush}" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush3"
Value="{StaticResource White1Brush}" />
</Style>
<Style TargetType="{x:Type ButtonBase}"
x:Key="LiviaProcessingIconButtonBase">
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type ButtonBase}">
<Grid>
<Button Style="{StaticResource MaterialDesignRaisedButton}"
Name="Button"
HorizontalAlignment="Center"
VerticalAlignment="Center"
Height="24"
materialDesign:ElevationAssist.Elevation="Dp0"
BorderThickness="0"
Background="{TemplateBinding Background}"
Foreground="{TemplateBinding Foreground}">
<StackPanel>
<materialDesign:PackIcon Kind="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(attachedProperties:IconKindProperties.IconKind)}"
Width="16"
Height="16"
Name="ButtonIcon" />
<ProgressBar IsIndeterminate="True"
Width="16"
Height="16"
Name="ProgressBar"
Foreground="{TemplateBinding Foreground}"
Style="{StaticResource MaterialDesignCircularProgressBar}" />
</StackPanel>
</Button>
</Grid>
<ControlTemplate.Triggers>
<Trigger Property="IsMouseOver"
Value="True">
<Setter TargetName="Button"
Property="Background"
Value="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(attachedProperties:SolidColorBrushProperties.SolidColorBrush1)}" />
</Trigger>
<Trigger Property="IsEnabled"
Value="True">
<Setter TargetName="ProgressBar"
Property="Visibility"
Value="Collapsed" />
</Trigger>
<Trigger Property="IsEnabled"
Value="False">
<Setter TargetName="ButtonIcon"
Property="Visibility"
Value="Collapsed" />
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style TargetType="{x:Type ButtonBase}"
BasedOn="{StaticResource LiviaProcessingIconButtonBase}"
x:Key="LiviaPrimaryProcessingIconButton">
<Setter Property="Background"
Value="{StaticResource PrimaryColorBrush}" />
<Setter Property="Foreground"
Value="{StaticResource White1Brush}" />
<Setter Property="attachedProperties:IconKindProperties.IconKind"
Value="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(attachedProperties:IconKindProperties.IconKind)}" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush1"
Value="{StaticResource PrimaryColorAlternativeBrush}" />
</Style>
<Style TargetType="{x:Type ButtonBase}"
x:Key="LiviaGridProcessingTextButtonBase">
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type ButtonBase}">
<Grid>
<Button Style="{StaticResource MaterialDesignRaisedButton}"
Name="Button"
HorizontalAlignment="Center"
Padding="0"
Margin="0"
VerticalAlignment="Center"
materialDesign:ElevationAssist.Elevation="Dp0"
BorderThickness="0"
Background="Transparent"
Foreground="{TemplateBinding Foreground}">
<StackPanel>
<TextBlock Style="{StaticResource MaterialDesignButtonTextBlock}"
Text="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(attachedProperties:StringItemProperties.ItemName)}"
VerticalAlignment="Center"
Name="ButtonText" />
<ProgressBar IsIndeterminate="True"
Name="ProgressBar"
VerticalAlignment="Center"
Foreground="{TemplateBinding Foreground}"
Style="{StaticResource MaterialDesignCircularProgressBar}" />
</StackPanel>
</Button>
</Grid>
<ControlTemplate.Triggers>
<Trigger Property="IsMouseOver"
Value="True">
<Setter TargetName="Button"
Property="Foreground"
Value="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(attachedProperties:SolidColorBrushProperties.SolidColorBrush1)}" />
</Trigger>
<Trigger Property="IsEnabled"
Value="True">
<Setter TargetName="ProgressBar"
Property="Visibility"
Value="Collapsed" />
</Trigger>
<Trigger Property="IsEnabled"
Value="False">
<Setter TargetName="ButtonText"
Property="Visibility"
Value="Collapsed" />
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style TargetType="{x:Type ButtonBase}"
BasedOn="{StaticResource LiviaGridProcessingTextButtonBase}"
x:Key="LiviaPrimaryGridProcessingTextButton">
<Setter Property="Foreground"
Value="{StaticResource PrimaryGridTextButtonColorBrush}" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush1"
Value="{StaticResource White1Brush}" />
</Style>
<Style TargetType="{x:Type ButtonBase}"
BasedOn="{StaticResource LiviaGridProcessingTextButtonBase}"
x:Key="LiviaPrimaryGridProcessingAlertTextButton">
<Setter Property="Foreground"
Value="{StaticResource AlertColorBrush}" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush1"
Value="{StaticResource White1Brush}" />
</Style>
<Style TargetType="{x:Type ButtonBase}"
BasedOn="{StaticResource LiviaIconButtonBase}"
x:Key="LiviaStretchIconButton">
<Setter Property="attachedProperties:IconKindProperties.IconKind"
Value="fullscreen" />
<Setter Property="HorizontalAlignment"
Value="Right" />
<Setter Property="VerticalAlignment"
Value="Bottom" />
<Setter Property="Margin"
Value="5" />
<Setter Property="Visibility"
Value="{Binding Path=IsMouseOver, RelativeSource={RelativeSource AncestorType={x:Type Grid}, Mode=FindAncestor}, Converter={StaticResource BooleanToVisibilityConverter}}" />
<Setter Property="Background"
Value="{StaticResource PrimaryColorAlternative2Brush}" />
<Setter Property="Foreground"
Value="{StaticResource White1Brush}" />
<Setter Property="BorderBrush"
Value="{StaticResource Gray4Brush}" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush1"
Value="{StaticResource PrimaryColorAlternative2Brush}" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush2"
Value="{StaticResource PrimaryColorHighlightBrush}" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush3"
Value="{StaticResource PrimaryColorHighlightBrush}" />
<Setter Property="Command"
Value="{x:Static materialDesign:DialogHost.OpenDialogCommand}" />
</Style>
<Style TargetType="{x:Type ButtonBase}"
x:Key="LiviaTextIconButtonBase">
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type ButtonBase}">
<Grid>
<Button Name="Button"
materialDesign:RippleAssist.IsDisabled="True"
BorderThickness="0"
HorizontalAlignment="Center"
VerticalAlignment="Center"
Padding="0"
Margin="0"
BorderBrush="{TemplateBinding BorderBrush}"
Background="{TemplateBinding Background}"
Foreground="{TemplateBinding Foreground}">
<StackPanel Orientation="Horizontal">
<materialDesign:PackIcon Kind="{Binding (attachedProperties:IconKindProperties.IconKind), RelativeSource={RelativeSource TemplatedParent}}"
Name="ButtonIcon"
Margin="0, 2, 5, 0"
VerticalAlignment="Center" />
<TextBlock Style="{StaticResource MaterialDesignButtonTextBlock}"
Text="{Binding (attachedProperties:StringItemProperties.ItemName), RelativeSource={RelativeSource TemplatedParent}}"
Name="ButtonText"
VerticalAlignment="Center" />
</StackPanel>
</Button>
</Grid>
<ControlTemplate.Triggers>
<Trigger Property="IsMouseOver"
Value="True">
<Setter TargetName="Button"
Property="Foreground"
Value="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(attachedProperties:SolidColorBrushProperties.SolidColorBrush1)}" />
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style TargetType="{x:Type ButtonBase}"
BasedOn="{StaticResource LiviaTextIconButtonBase}"
x:Key="LiviaPrimaryTextIconButton">
<Setter Property="Background"
Value="Transparent" />
<Setter Property="Foreground"
Value="{StaticResource PrimaryTextColorBrush}" />
<Setter Property="BorderBrush"
Value="Transparent" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush1"
Value="{StaticResource White1Brush}" />
</Style>
<Style TargetType="{x:Type ButtonBase}"
BasedOn="{StaticResource LiviaTextIconButtonBase}"
x:Key="LiviaAlertTextIconButton">
<Setter Property="Background"
Value="Transparent" />
<Setter Property="Foreground"
Value="{StaticResource AlertColorBrush}" />
<Setter Property="BorderBrush"
Value="Transparent" />
<Setter Property="attachedProperties:SolidColorBrushProperties.SolidColorBrush1"
Value="{StaticResource AlertAlternativeColorBrush}" />
</Style>
</ResourceDictionary>