mirror of
https://github.com/wwiinnddyy/LanMountainDesktop.git
synced 2026-06-21 16:14:28 +08:00
328 lines
18 KiB
XML
328 lines
18 KiB
XML
<Window xmlns="https://github.com/avaloniaui"
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
|
xmlns:fi="using:FluentIcons.Avalonia"
|
|
xmlns:ic="using:FluentIcons.Avalonia.Fluent"
|
|
xmlns:pages="using:LanMountainDesktop.Views.SettingsPages"
|
|
xmlns:comp="using:LanMountainDesktop.Views.Components"
|
|
x:Class="LanMountainDesktop.Views.SettingsWindow"
|
|
Title="Settings"
|
|
Icon="/Assets/avalonia-logo.ico"
|
|
Width="1520"
|
|
Height="960"
|
|
MinWidth="1240"
|
|
MinHeight="820"
|
|
ShowInTaskbar="True"
|
|
WindowStartupLocation="CenterScreen"
|
|
Background="{DynamicResource AdaptiveSurfaceBaseBrush}">
|
|
|
|
<Window.Styles>
|
|
<Style Selector="Border.settings-shell-card">
|
|
<Setter Property="Background" Value="{DynamicResource AdaptiveGlassPanelBackgroundBrush}" />
|
|
<Setter Property="BorderBrush" Value="{DynamicResource AdaptiveGlassPanelBorderBrush}" />
|
|
<Setter Property="BorderThickness" Value="1" />
|
|
<Setter Property="CornerRadius" Value="28" />
|
|
<Setter Property="BoxShadow" Value="0 10 28 #12000000" />
|
|
</Style>
|
|
|
|
<Style Selector="TextBlock.settings-shell-eyebrow">
|
|
<Setter Property="FontSize" Value="12" />
|
|
<Setter Property="FontWeight" Value="SemiBold" />
|
|
<Setter Property="Foreground" Value="{DynamicResource AdaptiveTextSecondaryBrush}" />
|
|
</Style>
|
|
|
|
<Style Selector="TextBlock.settings-shell-hint">
|
|
<Setter Property="FontSize" Value="13" />
|
|
<Setter Property="Foreground" Value="{DynamicResource AdaptiveTextSecondaryBrush}" />
|
|
</Style>
|
|
|
|
<Style Selector="StackPanel.settings-sidebar-host Button.settings-sidebar-item">
|
|
<Setter Property="Background" Value="Transparent" />
|
|
<Setter Property="BorderBrush" Value="Transparent" />
|
|
<Setter Property="BorderThickness" Value="1" />
|
|
<Setter Property="CornerRadius" Value="18" />
|
|
<Setter Property="Padding" Value="14,12" />
|
|
<Setter Property="Margin" Value="0,0,0,8" />
|
|
<Setter Property="HorizontalContentAlignment" Value="Stretch" />
|
|
<Setter Property="Transitions">
|
|
<Transitions>
|
|
<BrushTransition Property="Background" Duration="{StaticResource FluttermotionToken.Duration.Fast}" Easing="0.22,1,0.36,1" />
|
|
<BrushTransition Property="BorderBrush" Duration="{StaticResource FluttermotionToken.Duration.Fast}" Easing="0.22,1,0.36,1" />
|
|
<TransformOperationsTransition Property="RenderTransform" Duration="{StaticResource FluttermotionToken.Duration.Fast}" Easing="0.22,1,0.36,1" />
|
|
</Transitions>
|
|
</Setter>
|
|
</Style>
|
|
|
|
<Style Selector="StackPanel.settings-sidebar-host Button.settings-sidebar-item:pointerover">
|
|
<Setter Property="Background" Value="{DynamicResource AdaptiveButtonHoverBackgroundBrush}" />
|
|
<Setter Property="BorderBrush" Value="{DynamicResource AdaptiveButtonBorderBrush}" />
|
|
<Setter Property="RenderTransform" Value="scale(1.01)" />
|
|
</Style>
|
|
|
|
<Style Selector="StackPanel.settings-sidebar-host Button.settings-sidebar-item.nav-selected">
|
|
<Setter Property="Background" Value="{DynamicResource AdaptiveNavItemSelectedBackgroundBrush}" />
|
|
<Setter Property="BorderBrush" Value="{DynamicResource AdaptiveAccentBrush}" />
|
|
</Style>
|
|
|
|
<Style Selector="Border.settings-sidebar-icon-shell">
|
|
<Setter Property="Width" Value="34" />
|
|
<Setter Property="Height" Value="34" />
|
|
<Setter Property="CornerRadius" Value="12" />
|
|
<Setter Property="Background" Value="{DynamicResource AdaptiveButtonBackgroundBrush}" />
|
|
<Setter Property="BorderBrush" Value="{DynamicResource AdaptiveButtonBorderBrush}" />
|
|
<Setter Property="BorderThickness" Value="1" />
|
|
</Style>
|
|
|
|
<Style Selector="Button.settings-sidebar-item.nav-selected Border.settings-sidebar-icon-shell">
|
|
<Setter Property="Background" Value="{DynamicResource AdaptiveAccentBrush}" />
|
|
<Setter Property="BorderBrush" Value="{DynamicResource AdaptiveAccentBrush}" />
|
|
</Style>
|
|
|
|
<Style Selector="TextBlock.settings-nav-label">
|
|
<Setter Property="FontSize" Value="16" />
|
|
<Setter Property="FontWeight" Value="SemiBold" />
|
|
<Setter Property="VerticalAlignment" Value="Center" />
|
|
</Style>
|
|
|
|
<Style Selector="ic|SymbolIcon.settings-nav-icon">
|
|
<Setter Property="Foreground" Value="{DynamicResource AdaptiveTextPrimaryBrush}" />
|
|
<Setter Property="FontSize" Value="18" />
|
|
<Setter Property="HorizontalAlignment" Value="Center" />
|
|
<Setter Property="VerticalAlignment" Value="Center" />
|
|
</Style>
|
|
|
|
<Style Selector="Button.settings-sidebar-item.nav-selected ic|SymbolIcon.settings-nav-icon">
|
|
<Setter Property="Foreground" Value="White" />
|
|
</Style>
|
|
</Window.Styles>
|
|
|
|
<Grid x:Name="DesktopHost">
|
|
<Border x:Name="DesktopWallpaperLayer"
|
|
Background="{DynamicResource AdaptiveSurfaceBaseBrush}" />
|
|
|
|
<Grid x:Name="SettingsPage"
|
|
Classes="settings-scope"
|
|
IsVisible="True"
|
|
Opacity="1"
|
|
Margin="20">
|
|
<Grid x:Name="SettingsContentPanel"
|
|
RowDefinitions="Auto,*"
|
|
RowSpacing="18">
|
|
<Border Grid.Row="0"
|
|
Classes="settings-shell-card"
|
|
Padding="20,18">
|
|
<Grid ColumnDefinitions="Auto,*,Auto"
|
|
ColumnSpacing="18">
|
|
<Border Width="52"
|
|
Height="52"
|
|
CornerRadius="18"
|
|
Background="{DynamicResource AdaptiveAccentBrush}">
|
|
<TextBlock Text="LMD"
|
|
FontSize="16"
|
|
FontWeight="Bold"
|
|
Foreground="White"
|
|
HorizontalAlignment="Center"
|
|
VerticalAlignment="Center" />
|
|
</Border>
|
|
|
|
<StackPanel Grid.Column="1"
|
|
Spacing="3"
|
|
VerticalAlignment="Center">
|
|
<TextBlock x:Name="WindowTitleTextBlock"
|
|
FontSize="28"
|
|
FontWeight="SemiBold"
|
|
Text="Application Settings" />
|
|
<TextBlock x:Name="WindowSubtitleTextBlock"
|
|
Classes="settings-shell-hint"
|
|
Text="LanMountainDesktop" />
|
|
</StackPanel>
|
|
|
|
<StackPanel Grid.Column="2"
|
|
Orientation="Horizontal"
|
|
Spacing="10"
|
|
VerticalAlignment="Center">
|
|
<Border Classes="settings-shell-card"
|
|
Padding="12,8"
|
|
CornerRadius="18">
|
|
<TextBlock x:Name="WindowVersionBadgeTextBlock"
|
|
FontSize="14"
|
|
FontWeight="SemiBold"
|
|
Text="1.0.0" />
|
|
</Border>
|
|
<Border Classes="settings-shell-card"
|
|
Padding="12,8"
|
|
CornerRadius="18">
|
|
<TextBlock x:Name="WindowCodeNameBadgeTextBlock"
|
|
Classes="settings-shell-hint"
|
|
Text="Administrate" />
|
|
</Border>
|
|
</StackPanel>
|
|
</Grid>
|
|
</Border>
|
|
|
|
<Grid Grid.Row="1"
|
|
ColumnDefinitions="300,20,*">
|
|
<Border Grid.Column="0"
|
|
Classes="settings-shell-card"
|
|
Padding="18,18,18,16">
|
|
<Grid RowDefinitions="Auto,*,Auto"
|
|
RowSpacing="18">
|
|
<StackPanel Spacing="6">
|
|
<TextBlock x:Name="SettingsSidebarTitleTextBlock"
|
|
Classes="settings-shell-eyebrow"
|
|
Text="Settings" />
|
|
<TextBlock x:Name="SettingsSidebarHintTextBlock"
|
|
Classes="settings-shell-hint"
|
|
TextWrapping="Wrap"
|
|
Text="Choose a category to adjust application behavior and desktop appearance." />
|
|
</StackPanel>
|
|
|
|
<ScrollViewer Grid.Row="1"
|
|
HorizontalScrollBarVisibility="Disabled"
|
|
VerticalScrollBarVisibility="Auto">
|
|
<StackPanel Spacing="20">
|
|
<StackPanel Spacing="10">
|
|
<TextBlock x:Name="SettingsPrimaryGroupTextBlock"
|
|
Classes="settings-shell-eyebrow"
|
|
Text="Desktop" />
|
|
<StackPanel x:Name="SettingsPrimaryNavHost"
|
|
Classes="settings-sidebar-host"
|
|
Spacing="0" />
|
|
</StackPanel>
|
|
|
|
<Border Background="{DynamicResource SurfaceStrokeColorDefaultBrush}"
|
|
Height="1" />
|
|
|
|
<StackPanel Spacing="10">
|
|
<TextBlock x:Name="SettingsSecondaryGroupTextBlock"
|
|
Classes="settings-shell-eyebrow"
|
|
Text="System" />
|
|
<StackPanel x:Name="SettingsSecondaryNavHost"
|
|
Classes="settings-sidebar-host"
|
|
Spacing="0" />
|
|
</StackPanel>
|
|
|
|
<StackPanel x:Name="SettingsPluginNavSection"
|
|
IsVisible="False"
|
|
Spacing="10">
|
|
<Border Background="{DynamicResource SurfaceStrokeColorDefaultBrush}"
|
|
Height="1" />
|
|
<TextBlock x:Name="SettingsPluginGroupTextBlock"
|
|
Classes="settings-shell-eyebrow"
|
|
Text="Extensions" />
|
|
<StackPanel x:Name="SettingsPluginNavHost"
|
|
Classes="settings-sidebar-host"
|
|
Spacing="0" />
|
|
</StackPanel>
|
|
</StackPanel>
|
|
</ScrollViewer>
|
|
|
|
<Border Grid.Row="2"
|
|
Classes="settings-shell-card"
|
|
Padding="14,12"
|
|
CornerRadius="22">
|
|
<StackPanel Spacing="4">
|
|
<TextBlock Text="LanMountainDesktop"
|
|
FontWeight="SemiBold" />
|
|
<TextBlock x:Name="SettingsSidebarFooterTextBlock"
|
|
Classes="settings-shell-hint"
|
|
TextWrapping="Wrap"
|
|
Text="Tray-opened settings are managed in this standalone window." />
|
|
</StackPanel>
|
|
</Border>
|
|
</Grid>
|
|
</Border>
|
|
|
|
<Grid Grid.Column="2"
|
|
RowDefinitions="*,Auto"
|
|
RowSpacing="14">
|
|
<Border Grid.Row="0"
|
|
Classes="settings-shell-card"
|
|
Padding="0">
|
|
<ScrollViewer x:Name="SettingsContentScrollViewer"
|
|
Padding="30,28,30,30"
|
|
HorizontalScrollBarVisibility="Disabled"
|
|
VerticalScrollBarVisibility="Auto">
|
|
<Grid x:Name="SettingsContentPagesHost">
|
|
<pages:WallpaperSettingsPage x:Name="WallpaperSettingsPanel" IsVisible="True" />
|
|
<pages:GridSettingsPage x:Name="GridSettingsPanel" IsVisible="False" />
|
|
<pages:ColorSettingsPage x:Name="ColorSettingsPanel" IsVisible="False" />
|
|
<pages:StatusBarSettingsPage x:Name="StatusBarSettingsPanel" IsVisible="False" />
|
|
<pages:WeatherSettingsPage x:Name="WeatherSettingsPanel" IsVisible="False" />
|
|
<pages:RegionSettingsPage x:Name="RegionSettingsPanel" IsVisible="False" />
|
|
<pages:UpdateSettingsPage x:Name="UpdateSettingsPanel" IsVisible="False" />
|
|
<pages:LauncherSettingsPage x:Name="LauncherSettingsPanel" IsVisible="False" />
|
|
<pages:AboutSettingsPage x:Name="AboutSettingsPanel" IsVisible="False" />
|
|
<pages:PluginSettingsPage x:Name="PluginSettingsPanel" IsVisible="False" />
|
|
<pages:PluginMarketSettingsPage x:Name="PluginMarketSettingsPanel" IsVisible="False" />
|
|
</Grid>
|
|
</ScrollViewer>
|
|
</Border>
|
|
|
|
<Border x:Name="PendingRestartDock"
|
|
Grid.Row="1"
|
|
IsVisible="False"
|
|
Classes="settings-shell-card"
|
|
Padding="16,14"
|
|
CornerRadius="24">
|
|
<Grid ColumnDefinitions="Auto,*,Auto"
|
|
ColumnSpacing="14">
|
|
<Border Width="38"
|
|
Height="38"
|
|
CornerRadius="14"
|
|
Background="{DynamicResource AdaptiveAccentBrush}">
|
|
<fi:FluentIcon Icon="ArrowSync"
|
|
IconVariant="Regular"
|
|
FontSize="18"
|
|
Foreground="White"
|
|
HorizontalAlignment="Center"
|
|
VerticalAlignment="Center" />
|
|
</Border>
|
|
<StackPanel Grid.Column="1"
|
|
Spacing="2"
|
|
VerticalAlignment="Center">
|
|
<TextBlock x:Name="PendingRestartDockTitleTextBlock"
|
|
FontSize="14"
|
|
FontWeight="SemiBold"
|
|
Text="Restart required" />
|
|
<TextBlock x:Name="PendingRestartDockDescriptionTextBlock"
|
|
TextWrapping="Wrap"
|
|
Foreground="{DynamicResource AdaptiveTextSecondaryBrush}"
|
|
Text="Your changes will apply after restarting the app." />
|
|
</StackPanel>
|
|
<Button x:Name="PendingRestartDockButton"
|
|
Grid.Column="2"
|
|
Padding="16,8"
|
|
Click="OnPendingRestartDockButtonClick">
|
|
<StackPanel Orientation="Horizontal" Spacing="8">
|
|
<fi:FluentIcon Icon="ArrowSync"
|
|
IconVariant="Regular" />
|
|
<TextBlock x:Name="PendingRestartDockButtonTextBlock"
|
|
VerticalAlignment="Center"
|
|
Text="Restart app" />
|
|
</StackPanel>
|
|
</Button>
|
|
</Grid>
|
|
</Border>
|
|
</Grid>
|
|
</Grid>
|
|
</Grid>
|
|
</Grid>
|
|
|
|
<Grid IsVisible="False">
|
|
<Button x:Name="BackToWindowsButton" />
|
|
<Button x:Name="OpenComponentLibraryButton" />
|
|
<Button x:Name="OpenSettingsButton" />
|
|
<TextBlock x:Name="OpenSettingsButtonTextBlock" />
|
|
<Border x:Name="TaskbarFixedActionsHost" />
|
|
<Border x:Name="TaskbarSettingsActionHost" />
|
|
<StackPanel x:Name="TaskbarDynamicActionsHost" />
|
|
<Border x:Name="TopStatusBarHost">
|
|
<StackPanel x:Name="TopStatusComponentsPanel">
|
|
<comp:ClockWidget x:Name="ClockWidget" />
|
|
</StackPanel>
|
|
</Border>
|
|
<Border x:Name="BottomTaskbarContainer" />
|
|
</Grid>
|
|
</Grid>
|
|
</Window>
|