You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
82 lines
3.6 KiB
82 lines
3.6 KiB
<Window xmlns="https://github.com/avaloniaui"
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
|
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
|
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
|
xmlns:vm="using:AuroraDesk.Presentation.ViewModels"
|
|
xmlns:heroicons="clr-namespace:HeroIconsAvalonia.Controls;assembly=HeroIconsAvalonia"
|
|
mc:Ignorable="d" d:DesignWidth="380" d:DesignHeight="200"
|
|
x:Class="AuroraDesk.Presentation.Views.Dialogs.CloseConfirmDialog"
|
|
x:DataType="vm:CloseConfirmViewModel"
|
|
Title="确认关闭"
|
|
Width="380"
|
|
SizeToContent="Height"
|
|
WindowStartupLocation="CenterOwner"
|
|
ShowInTaskbar="False"
|
|
CanResize="False"
|
|
SystemDecorations="None"
|
|
Background="{StaticResource BackgroundWhite}">
|
|
|
|
<Design.DataContext>
|
|
<vm:CloseConfirmViewModel />
|
|
</Design.DataContext>
|
|
|
|
<Border Background="{StaticResource BackgroundWhite}"
|
|
BorderBrush="{StaticResource BorderLight}"
|
|
BorderThickness="2"
|
|
CornerRadius="16"
|
|
Padding="24"
|
|
Width="380">
|
|
<Border.Effect>
|
|
<DropShadowEffect Color="{StaticResource ShadowBlack}"
|
|
Opacity="0.25"
|
|
BlurRadius="20"
|
|
OffsetX="0"
|
|
OffsetY="4"/>
|
|
</Border.Effect>
|
|
<StackPanel Spacing="18">
|
|
<Grid ColumnDefinitions="Auto,*" ColumnSpacing="12">
|
|
<Border Grid.Column="0"
|
|
Width="40"
|
|
Height="40"
|
|
CornerRadius="20"
|
|
Background="{Binding AccentBrush}"
|
|
VerticalAlignment="Center">
|
|
<heroicons:HeroIcon Type="{Binding Icon}"
|
|
Width="22"
|
|
Height="22"
|
|
Foreground="White"
|
|
HorizontalAlignment="Center"
|
|
VerticalAlignment="Center"/>
|
|
</Border>
|
|
<StackPanel Grid.Column="1" Spacing="6">
|
|
<TextBlock Text="{Binding Title}"
|
|
FontSize="18"
|
|
FontWeight="SemiBold"
|
|
Foreground="{StaticResource TextPrimary}"/>
|
|
<TextBlock Text="{Binding Message}"
|
|
TextWrapping="Wrap"
|
|
FontSize="14"
|
|
Foreground="{StaticResource SecondaryGrayDark}"
|
|
MaxWidth="260"/>
|
|
</StackPanel>
|
|
</Grid>
|
|
|
|
<StackPanel Orientation="Horizontal"
|
|
HorizontalAlignment="Right"
|
|
Spacing="10">
|
|
<Button Content="{Binding SecondaryButtonText}"
|
|
MinWidth="96"
|
|
Name="CancelButton"
|
|
IsVisible="{Binding HasSecondaryButton}"/>
|
|
<Button Content="{Binding PrimaryButtonText}"
|
|
MinWidth="96"
|
|
Name="ConfirmButton"
|
|
Background="{Binding AccentBrush}"
|
|
Foreground="White"
|
|
BorderThickness="0"
|
|
CornerRadius="8"/>
|
|
</StackPanel>
|
|
</StackPanel>
|
|
</Border>
|
|
</Window>
|
|
|
|
|