Skip to content

Commit

Permalink
Refactor UI and add experimental features indication.
Browse files Browse the repository at this point in the history
Removed unused drop shadow effects, enhanced settings presentation with "NEW" and "Experimental" labels, and expanded details for dynamic scaling options. Updated the default scaling mode to "Simple" for better consistency.
  • Loading branch information
HakuSystems committed Dec 27, 2024
1 parent a01118c commit 47a1411
Show file tree
Hide file tree
Showing 4 changed files with 97 additions and 20 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -86,8 +86,13 @@
<ColumnDefinition Width="*" />
<ColumnDefinition Width="Auto" />
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="Auto" />
<RowDefinition Height="Auto" />
</Grid.RowDefinitions>

<ui:Card
Grid.Column="0"
HorizontalAlignment="Left"
Margin="5"
VerticalAlignment="Center">
Expand All @@ -99,14 +104,31 @@
</ui:Card>

<StackPanel Grid.Column="1" VerticalAlignment="Center">
<ui:TextBlock
FontTypography="BodyStrong"
Text="Dynamic Scaling"
TextWrapping="WrapWithOverflow" />
<StackPanel Margin="6" Orientation="Horizontal">
<ui:TextBlock
FontTypography="BodyStrong"
Text="Dynamic Scaling"
TextWrapping="WrapWithOverflow" />

<Border
Background="#FF3B30"
CornerRadius="8"
Margin="6,0,0,0"
Padding="6,2"
VerticalAlignment="Center">
<TextBlock
FontSize="10"
FontWeight="Bold"
Foreground="White"
Text="Experimental New Feature"
VerticalAlignment="Center" />
</Border>
</StackPanel>

<ui:TextBlock
Appearance="Secondary"
Opacity="0.5"
Text="Toggle dynamic scaling on/off, and choose the scaling mode."
Text="Enable or disable dynamic scaling, and select the preferred scaling mode."
TextWrapping="WrapWithOverflow" />
</StackPanel>

Expand All @@ -116,6 +138,7 @@
VerticalAlignment="Center">
<ui:TextBlock
FontTypography="Caption"
Foreground="#FF3B30"
Margin="0,0,5,0"
Text="(Applies at restart)"
VerticalAlignment="Center" />
Expand All @@ -131,6 +154,40 @@
IsDesignTimeCreatable=True}"
x:Name="DynamicScalingComboBox" />
</StackPanel>
<Grid
Grid.Column="0"
Grid.ColumnSpan="3"
Grid.Row="1">
<ui:CardExpander
Header="What Does Each Scaling Mode Do?"
Margin="5,5,5,5"
Padding="5">
<StackPanel>
<ui:TextBlock
Appearance="Secondary"
FontTypography="BodyStrong"
Text="Scaling modes determine how the application adapts to different DPI settings."
TextWrapping="WrapWithOverflow" />
<ui:TextBlock
Appearance="Secondary"
Opacity="0.5"
Text="In 'Simple' mode, only the main dashboard is scaled dynamically."
TextWrapping="WrapWithOverflow" />
<ui:TextBlock
Appearance="Secondary"
Opacity="0.5"
Text="In 'Experimental' mode, both the main dashboard and all its content are fully scaled dynamically. it may sometimes look unusual or inconsistent."
TextWrapping="WrapWithOverflow" />
<ui:InfoBar
IsClosable="False"
IsOpen="True"
Message="We recommend using 'Simple' mode as it is less likely to cause issues."
Padding="5"
Severity="Success"
Title="Recommendation" />
</StackPanel>
</ui:CardExpander>
</Grid>
</Grid>
</ui:Card>

Expand Down Expand Up @@ -209,8 +266,11 @@
<ui:TextBlock
Appearance="Secondary"
Opacity="0.5"
Text="When enabled, borders will appear (applies only to this Settings page)."
TextWrapping="Wrap" />
TextWrapping="WrapWithOverflow">
<Run Text="When enabled, borders will appear " />
<Run FontWeight="Bold" Text="(applies only to this Settings page)" />
<Run Text="." />
</ui:TextBlock>
</StackPanel>

<ui:ToggleSwitch
Expand Down Expand Up @@ -315,6 +375,7 @@
VerticalAlignment="Center">
<ui:TextBlock
FontTypography="Caption"
Foreground="#FF3B30"
Margin="0,0,5,0"
Text="(Applies at restart)"
VerticalAlignment="Center" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@
ShadowDepth="6" />
</Border.Effect>

<Grid AutomationProperties.Name="FeedbackGrid" Background="{DynamicResource ApplicationBackgroundBrush}">
<Grid AutomationProperties.Name="FeedbackGrid">

<Grid
HorizontalAlignment="Center"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ namespace EasyExtract.Models;

public class ConfigModel
{
public DynamicScalingModes DynamicScalingMode { get; set; } = DynamicScalingModes.Off;
public DynamicScalingModes DynamicScalingMode { get; set; } = DynamicScalingModes.Simple;
public string AppTitle { get; set; } = "EasyExtractUnitypackage";
public AvailableThemes ApplicationTheme { get; set; } = AvailableThemes.System;
public bool EasterEggHeader { get; set; } = true;
Expand Down
38 changes: 27 additions & 11 deletions EasyExtractUnitypackageRework/EasyExtract/Views/Dashboard.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -62,15 +62,6 @@
Margin="12"
VerticalAlignment="Stretch"
x:Name="MainContentBorder">
<Border.Effect>
<DropShadowEffect
BlurRadius="10"
Color="#40000000"
Direction="320"
ShadowDepth="6" />
</Border.Effect>


<Grid
HorizontalAlignment="Stretch"
VerticalAlignment="Stretch"
Expand Down Expand Up @@ -217,15 +208,40 @@

<ui:NavigationView.FooterMenuItems>
<ui:NavigationViewItem
Content="Settings"
Foreground="{DynamicResource TextFillColorPrimaryBrush}"
Icon="{ui:SymbolIcon Settings24}"
TargetPageType="{x:Type extraction:BetterSettings}" />
TargetPageType="{x:Type extraction:BetterSettings}">
<StackPanel
Margin="6"
Orientation="Horizontal"
VerticalAlignment="Center">
<TextBlock
FontSize="14"
Text="Settings"
VerticalAlignment="Center" />

<Border
Background="#FF3B30"
CornerRadius="8"
Margin="6,0,0,0"
Padding="6,2"
VerticalAlignment="Center">
<TextBlock
FontSize="10"
FontWeight="Bold"
Foreground="White"
Text="NEW"
VerticalAlignment="Center" />
</Border>
</StackPanel>
</ui:NavigationViewItem>

<ui:NavigationViewItem
Foreground="{DynamicResource TextFillColorPrimaryBrush}"
IsEnabled="False"
x:Name="VersionTxt" />
</ui:NavigationView.FooterMenuItems>

</ui:NavigationView>
</Grid>
</Border>
Expand Down

0 comments on commit 47a1411

Please sign in to comment.