From a4ee27778ec777c4c592eb951482b1a227218349 Mon Sep 17 00:00:00 2001 From: Zhang Dian <54255897+zdpcdt@users.noreply.github.com> Date: Sat, 9 Nov 2024 05:29:31 +0800 Subject: [PATCH 1/6] feat: add basic BoxShadows. --- src/Semi.Avalonia/Themes/Dark/Palette.axaml | 4 ++++ src/Semi.Avalonia/Themes/Light/Palette.axaml | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/src/Semi.Avalonia/Themes/Dark/Palette.axaml b/src/Semi.Avalonia/Themes/Dark/Palette.axaml index e69e146..9fa8732 100644 --- a/src/Semi.Avalonia/Themes/Dark/Palette.axaml +++ b/src/Semi.Avalonia/Themes/Dark/Palette.axaml @@ -421,4 +421,8 @@ + + + 0 0 0 0 #0A000000 + inset 0 0 0 1 #1AFFFFFF, 0 4 14 0 #40000000 \ No newline at end of file diff --git a/src/Semi.Avalonia/Themes/Light/Palette.axaml b/src/Semi.Avalonia/Themes/Light/Palette.axaml index 9e006f9..9be8e8f 100644 --- a/src/Semi.Avalonia/Themes/Light/Palette.axaml +++ b/src/Semi.Avalonia/Themes/Light/Palette.axaml @@ -421,4 +421,8 @@ + + + 0 0 0 0 #0A000000 + 0 0 1 0 #4A000000, 0 4 14 0 #1A000000 \ No newline at end of file From 46b1c5d1cc8f741c36955edb1da2dd4036521916 Mon Sep 17 00:00:00 2001 From: Zhang Dian <54255897+zdpcdt@users.noreply.github.com> Date: Wed, 13 Nov 2024 16:42:25 +0800 Subject: [PATCH 2/6] fix: fix BoxShadows. --- src/Semi.Avalonia/Controls/ToggleSwitch.axaml | 4 ++-- src/Semi.Avalonia/Themes/Dark/AutoCompleteBox.axaml | 2 +- src/Semi.Avalonia/Themes/Dark/Border.axaml | 2 +- src/Semi.Avalonia/Themes/Dark/CalendarDatePicker.axaml | 2 +- src/Semi.Avalonia/Themes/Dark/ComboBox.axaml | 2 +- src/Semi.Avalonia/Themes/Dark/DateTimePickerShared.axaml | 2 +- src/Semi.Avalonia/Themes/Dark/Flyout.axaml | 2 +- src/Semi.Avalonia/Themes/Dark/Menu.axaml | 2 +- src/Semi.Avalonia/Themes/Dark/ToggleSwitch.axaml | 2 ++ src/Semi.Avalonia/Themes/Light/AutoCompleteBox.axaml | 2 +- src/Semi.Avalonia/Themes/Light/Border.axaml | 2 +- src/Semi.Avalonia/Themes/Light/CalendarDatePicker.axaml | 2 +- src/Semi.Avalonia/Themes/Light/ComboBox.axaml | 2 +- src/Semi.Avalonia/Themes/Light/DateTimePickerShared.axaml | 2 +- src/Semi.Avalonia/Themes/Light/Flyout.axaml | 2 +- src/Semi.Avalonia/Themes/Light/Menu.axaml | 2 +- src/Semi.Avalonia/Themes/Light/ToggleSwitch.axaml | 2 ++ 17 files changed, 20 insertions(+), 16 deletions(-) diff --git a/src/Semi.Avalonia/Controls/ToggleSwitch.axaml b/src/Semi.Avalonia/Controls/ToggleSwitch.axaml index 65255d5..96a3da4 100644 --- a/src/Semi.Avalonia/Controls/ToggleSwitch.axaml +++ b/src/Semi.Avalonia/Controls/ToggleSwitch.axaml @@ -74,7 +74,7 @@ - 0 0 8 0 #1AFFFFFF + inset 0 0 0 1 #1AFFFFFF, 0 4 14 0 #40000000 \ No newline at end of file diff --git a/src/Semi.Avalonia/Themes/Dark/Border.axaml b/src/Semi.Avalonia/Themes/Dark/Border.axaml index 4d61729..d36d0ac 100644 --- a/src/Semi.Avalonia/Themes/Dark/Border.axaml +++ b/src/Semi.Avalonia/Themes/Dark/Border.axaml @@ -1,5 +1,5 @@ - 0 0 14 0 #1AFFFFFF + inset 0 0 0 1 #1AFFFFFF, 0 4 14 0 #40000000 \ No newline at end of file diff --git a/src/Semi.Avalonia/Themes/Dark/CalendarDatePicker.axaml b/src/Semi.Avalonia/Themes/Dark/CalendarDatePicker.axaml index ef751e8..9900582 100644 --- a/src/Semi.Avalonia/Themes/Dark/CalendarDatePicker.axaml +++ b/src/Semi.Avalonia/Themes/Dark/CalendarDatePicker.axaml @@ -9,7 +9,7 @@ - 0 0 8 0 #1AFFFFFF + inset 0 0 0 1 #1AFFFFFF, 0 4 14 0 #40000000 diff --git a/src/Semi.Avalonia/Themes/Dark/ComboBox.axaml b/src/Semi.Avalonia/Themes/Dark/ComboBox.axaml index 02a1b71..a77883a 100644 --- a/src/Semi.Avalonia/Themes/Dark/ComboBox.axaml +++ b/src/Semi.Avalonia/Themes/Dark/ComboBox.axaml @@ -18,7 +18,7 @@ - 0 0 8 0 #1AFFFFFF + inset 0 0 0 1 #1AFFFFFF, 0 4 14 0 #40000000 diff --git a/src/Semi.Avalonia/Themes/Dark/DateTimePickerShared.axaml b/src/Semi.Avalonia/Themes/Dark/DateTimePickerShared.axaml index 2b873a6..949ca97 100644 --- a/src/Semi.Avalonia/Themes/Dark/DateTimePickerShared.axaml +++ b/src/Semi.Avalonia/Themes/Dark/DateTimePickerShared.axaml @@ -26,5 +26,5 @@ - 0 0 8 0 #1AFFFFFF + inset 0 0 0 1 #1AFFFFFF, 0 4 14 0 #40000000 \ No newline at end of file diff --git a/src/Semi.Avalonia/Themes/Dark/Flyout.axaml b/src/Semi.Avalonia/Themes/Dark/Flyout.axaml index 6e2a1fb..0d865df 100644 --- a/src/Semi.Avalonia/Themes/Dark/Flyout.axaml +++ b/src/Semi.Avalonia/Themes/Dark/Flyout.axaml @@ -2,5 +2,5 @@ - 0 0 8 0 #1AFFFFFF + inset 0 0 0 1 #1AFFFFFF, 0 4 14 0 #40000000 \ No newline at end of file diff --git a/src/Semi.Avalonia/Themes/Dark/Menu.axaml b/src/Semi.Avalonia/Themes/Dark/Menu.axaml index 80ae504..d72520d 100644 --- a/src/Semi.Avalonia/Themes/Dark/Menu.axaml +++ b/src/Semi.Avalonia/Themes/Dark/Menu.axaml @@ -5,7 +5,7 @@ - 0 0 8 0 #1AFFFFFF + inset 0 0 0 1 #1AFFFFFF, 0 4 14 0 #40000000 diff --git a/src/Semi.Avalonia/Themes/Dark/ToggleSwitch.axaml b/src/Semi.Avalonia/Themes/Dark/ToggleSwitch.axaml index 9e098a1..e5d733b 100644 --- a/src/Semi.Avalonia/Themes/Dark/ToggleSwitch.axaml +++ b/src/Semi.Avalonia/Themes/Dark/ToggleSwitch.axaml @@ -15,4 +15,6 @@ + + 0 4 6 0 #1A000000, 0 0 1 0 #4D000000 \ No newline at end of file diff --git a/src/Semi.Avalonia/Themes/Light/AutoCompleteBox.axaml b/src/Semi.Avalonia/Themes/Light/AutoCompleteBox.axaml index 7fb1210..520f9b5 100644 --- a/src/Semi.Avalonia/Themes/Light/AutoCompleteBox.axaml +++ b/src/Semi.Avalonia/Themes/Light/AutoCompleteBox.axaml @@ -1,5 +1,5 @@ - 0 0 8 0 #1A000000 + 0 0 1 0 #4A000000, 0 4 14 0 #1A000000 \ No newline at end of file diff --git a/src/Semi.Avalonia/Themes/Light/Border.axaml b/src/Semi.Avalonia/Themes/Light/Border.axaml index eb19ed2..be23f5c 100644 --- a/src/Semi.Avalonia/Themes/Light/Border.axaml +++ b/src/Semi.Avalonia/Themes/Light/Border.axaml @@ -1,5 +1,5 @@ - 0 0 14 0 #1A000000 + 0 0 1 0 #4A000000, 0 4 14 0 #1A000000 \ No newline at end of file diff --git a/src/Semi.Avalonia/Themes/Light/CalendarDatePicker.axaml b/src/Semi.Avalonia/Themes/Light/CalendarDatePicker.axaml index d1fbd4a..a4f69b5 100644 --- a/src/Semi.Avalonia/Themes/Light/CalendarDatePicker.axaml +++ b/src/Semi.Avalonia/Themes/Light/CalendarDatePicker.axaml @@ -9,7 +9,7 @@ - 0 0 8 0 #1A000000 + 0 0 1 0 #4A000000, 0 4 14 0 #1A000000 diff --git a/src/Semi.Avalonia/Themes/Light/ComboBox.axaml b/src/Semi.Avalonia/Themes/Light/ComboBox.axaml index 2225e15..71dbbc4 100644 --- a/src/Semi.Avalonia/Themes/Light/ComboBox.axaml +++ b/src/Semi.Avalonia/Themes/Light/ComboBox.axaml @@ -17,7 +17,7 @@ - 0 0 8 0 #1A000000 + 0 0 1 0 #4A000000, 0 4 14 0 #1A000000 diff --git a/src/Semi.Avalonia/Themes/Light/DateTimePickerShared.axaml b/src/Semi.Avalonia/Themes/Light/DateTimePickerShared.axaml index b0aa476..ab864ed 100644 --- a/src/Semi.Avalonia/Themes/Light/DateTimePickerShared.axaml +++ b/src/Semi.Avalonia/Themes/Light/DateTimePickerShared.axaml @@ -28,5 +28,5 @@ - 0 0 8 0 #1A000000 + 0 0 1 0 #4A000000, 0 4 14 0 #1A000000 \ No newline at end of file diff --git a/src/Semi.Avalonia/Themes/Light/Flyout.axaml b/src/Semi.Avalonia/Themes/Light/Flyout.axaml index 7e7d9fd..aac33f5 100644 --- a/src/Semi.Avalonia/Themes/Light/Flyout.axaml +++ b/src/Semi.Avalonia/Themes/Light/Flyout.axaml @@ -2,5 +2,5 @@ - 0 0 8 0 #1A000000 + 0 0 1 0 #4A000000, 0 4 14 0 #1A000000 \ No newline at end of file diff --git a/src/Semi.Avalonia/Themes/Light/Menu.axaml b/src/Semi.Avalonia/Themes/Light/Menu.axaml index 4c4b620..8b73bb2 100644 --- a/src/Semi.Avalonia/Themes/Light/Menu.axaml +++ b/src/Semi.Avalonia/Themes/Light/Menu.axaml @@ -5,7 +5,7 @@ - 0 0 8 0 #1A000000 + 0 0 1 0 #4A000000, 0 4 14 0 #1A000000 diff --git a/src/Semi.Avalonia/Themes/Light/ToggleSwitch.axaml b/src/Semi.Avalonia/Themes/Light/ToggleSwitch.axaml index 727a02f..3a00f8c 100644 --- a/src/Semi.Avalonia/Themes/Light/ToggleSwitch.axaml +++ b/src/Semi.Avalonia/Themes/Light/ToggleSwitch.axaml @@ -15,4 +15,6 @@ + + 0 4 6 0 #1A000000, 0 0 1 0 #4D000000 \ No newline at end of file From 3a31924c6b454ae59571690259f00a6586420b29 Mon Sep 17 00:00:00 2001 From: Zhang Dian <54255897+zdpcdt@users.noreply.github.com> Date: Thu, 14 Nov 2024 18:07:34 +0800 Subject: [PATCH 3/6] fix: fix popup BoxShadow and unclosed corner issues. --- src/Semi.Avalonia.ColorPicker/Dark.axaml | 2 +- src/Semi.Avalonia.ColorPicker/Light.axaml | 2 +- .../Controls/AutoCompleteBox.axaml | 32 ++- src/Semi.Avalonia/Controls/ComboBox.axaml | 23 +- src/Semi.Avalonia/Controls/DatePicker.axaml | 191 ++++++++------- .../Controls/MenuFlyoutPresenter.axaml | 1 - src/Semi.Avalonia/Controls/TimePicker.axaml | 231 +++++++++--------- .../Themes/Shared/ComboBox.axaml | 2 +- 8 files changed, 254 insertions(+), 230 deletions(-) diff --git a/src/Semi.Avalonia.ColorPicker/Dark.axaml b/src/Semi.Avalonia.ColorPicker/Dark.axaml index e96849e..7ba3a79 100644 --- a/src/Semi.Avalonia.ColorPicker/Dark.axaml +++ b/src/Semi.Avalonia.ColorPicker/Dark.axaml @@ -17,5 +17,5 @@ - 0 0 14 0 #1AFFFFFF + inset 0 0 0 1 #1AFFFFFF, 0 4 14 0 #40000000 \ No newline at end of file diff --git a/src/Semi.Avalonia.ColorPicker/Light.axaml b/src/Semi.Avalonia.ColorPicker/Light.axaml index 6148e2f..946f707 100644 --- a/src/Semi.Avalonia.ColorPicker/Light.axaml +++ b/src/Semi.Avalonia.ColorPicker/Light.axaml @@ -17,5 +17,5 @@ - 0 0 14 0 #1A000000 + 0 0 1 0 #4A000000, 0 4 14 0 #1A000000 \ No newline at end of file diff --git a/src/Semi.Avalonia/Controls/AutoCompleteBox.axaml b/src/Semi.Avalonia/Controls/AutoCompleteBox.axaml index 8aa84a6..ebd07ce 100644 --- a/src/Semi.Avalonia/Controls/AutoCompleteBox.axaml +++ b/src/Semi.Avalonia/Controls/AutoCompleteBox.axaml @@ -39,12 +39,16 @@ BorderThickness="{DynamicResource AutoCompleteBoxPopupBorderThickness}" BoxShadow="{DynamicResource AutoCompleteBoxPopupBoxShadow}" CornerRadius="{DynamicResource AutoCompleteBoxPopupCornerRadius}"> - + + + @@ -77,12 +81,16 @@ BorderThickness="{DynamicResource AutoCompleteBoxPopupBorderThickness}" BoxShadow="{DynamicResource AutoCompleteBoxPopupBoxShadow}" CornerRadius="{DynamicResource AutoCompleteBoxPopupCornerRadius}"> - + + + diff --git a/src/Semi.Avalonia/Controls/ComboBox.axaml b/src/Semi.Avalonia/Controls/ComboBox.axaml index 760380a..59dcdc2 100644 --- a/src/Semi.Avalonia/Controls/ComboBox.axaml +++ b/src/Semi.Avalonia/Controls/ComboBox.axaml @@ -117,16 +117,19 @@ BorderBrush="{DynamicResource ComboBoxPopupBorderBrush}" BorderThickness="{DynamicResource ComboBoxPopupBorderThickness}" BoxShadow="{DynamicResource ComboBoxPopupBoxShadow}" - CornerRadius="{DynamicResource ComboBoxPopupBoxCornerRadius}" - ClipToBounds="True"> - - - + CornerRadius="{DynamicResource ComboBoxPopupBoxCornerRadius}"> + + + + + diff --git a/src/Semi.Avalonia/Controls/DatePicker.axaml b/src/Semi.Avalonia/Controls/DatePicker.axaml index ec4716c..79d35a9 100644 --- a/src/Semi.Avalonia/Controls/DatePicker.axaml +++ b/src/Semi.Avalonia/Controls/DatePicker.axaml @@ -22,100 +22,107 @@ BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" BoxShadow="{DynamicResource DateTimePickerFlyoutBoxShadow}" - CornerRadius="{TemplateBinding CornerRadius}" - ClipToBounds="True"> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + CornerRadius="{TemplateBinding CornerRadius}"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - + + + + + + - + diff --git a/src/Semi.Avalonia/Controls/MenuFlyoutPresenter.axaml b/src/Semi.Avalonia/Controls/MenuFlyoutPresenter.axaml index 91f9651..a51e3c6 100644 --- a/src/Semi.Avalonia/Controls/MenuFlyoutPresenter.axaml +++ b/src/Semi.Avalonia/Controls/MenuFlyoutPresenter.axaml @@ -37,7 +37,6 @@ BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" BoxShadow="{DynamicResource MenuFlyoutBorderBoxShadow}" - ClipToBounds="True" CornerRadius="{TemplateBinding CornerRadius}" UseLayoutRounding="False"> - - - - - - - - - - - - - + CornerRadius="{TemplateBinding CornerRadius}"> + + + + + + + + + + + + + + - - - - - - - - - - - - - - - + + + + + + + - - - - - - - + + + + + + + - - - + + + + + + + + + + + + + + + + + + + - - - - - - - + diff --git a/src/Semi.Avalonia/Themes/Shared/ComboBox.axaml b/src/Semi.Avalonia/Themes/Shared/ComboBox.axaml index 2930b5f..512f24a 100644 --- a/src/Semi.Avalonia/Themes/Shared/ComboBox.axaml +++ b/src/Semi.Avalonia/Themes/Shared/ComboBox.axaml @@ -16,7 +16,7 @@ M4.08045 7.59809C4.66624 7.01231 5.61599 7.01231 6.20177 7.59809L11.8586 13.2549L17.5155 7.59809C18.1013 7.01231 19.051 7.01231 19.6368 7.59809C20.2226 8.18388 20.2226 9.13363 19.6368 9.71941L12.9193 16.4369C12.3335 17.0227 11.3838 17.0227 10.798 16.4369L4.08045 9.71941C3.49467 9.13363 3.49467 8.18388 4.08045 7.59809Z - 0 4 + 4 32 24 From d1d235a1200b589b3dec7e1cf2c7adbf465adc85 Mon Sep 17 00:00:00 2001 From: Zhang Dian <54255897+zdpcdt@users.noreply.github.com> Date: Fri, 15 Nov 2024 01:00:59 +0800 Subject: [PATCH 4/6] misc: format codes. --- .../Controls/FunctionalColorGroupControl.cs | 27 ++- .../ViewModels/PaletteDemoViewModel.cs | 218 +++++++++--------- 2 files changed, 129 insertions(+), 116 deletions(-) diff --git a/demo/Semi.Avalonia.Demo/Controls/FunctionalColorGroupControl.cs b/demo/Semi.Avalonia.Demo/Controls/FunctionalColorGroupControl.cs index 7a17dee..57b3587 100644 --- a/demo/Semi.Avalonia.Demo/Controls/FunctionalColorGroupControl.cs +++ b/demo/Semi.Avalonia.Demo/Controls/FunctionalColorGroupControl.cs @@ -4,33 +4,38 @@ using Avalonia.Controls.Primitives; namespace Semi.Avalonia.Demo.Controls; -public class FunctionalColorGroupControl: TemplatedControl +public class FunctionalColorGroupControl : TemplatedControl { - public static readonly StyledProperty TitleProperty = AvaloniaProperty.Register( - nameof(Title)); + public static readonly StyledProperty TitleProperty = + AvaloniaProperty.Register(nameof(Title)); + public string? Title { get => GetValue(TitleProperty); set => SetValue(TitleProperty, value); } - - public static readonly DirectProperty LightColorsProperty = AvaloniaProperty.RegisterDirect( - nameof(LightColors), o => o.LightColors, (o, v) => o.LightColors = v); + + public static readonly DirectProperty LightColorsProperty = + AvaloniaProperty.RegisterDirect(nameof(LightColors), + o => o.LightColors, (o, v) => o.LightColors = v); + private IEnumerable? _lightColors; + public IEnumerable? LightColors { get => _lightColors; set => SetAndRaise(LightColorsProperty, ref _lightColors, value); } - - public static readonly DirectProperty DarkColorsProperty = AvaloniaProperty.RegisterDirect( - nameof(DarkColors), o => o.DarkColors, (o, v) => o.DarkColors = v); + + public static readonly DirectProperty DarkColorsProperty = + AvaloniaProperty.RegisterDirect(nameof(DarkColors), + o => o.DarkColors, (o, v) => o.DarkColors = v); + private IEnumerable? _darkColors; + public IEnumerable? DarkColors { get => _darkColors; set => SetAndRaise(DarkColorsProperty, ref _darkColors, value); } - - } \ No newline at end of file diff --git a/demo/Semi.Avalonia.Demo/ViewModels/PaletteDemoViewModel.cs b/demo/Semi.Avalonia.Demo/ViewModels/PaletteDemoViewModel.cs index 1646be8..4a53cb7 100644 --- a/demo/Semi.Avalonia.Demo/ViewModels/PaletteDemoViewModel.cs +++ b/demo/Semi.Avalonia.Demo/ViewModels/PaletteDemoViewModel.cs @@ -2,25 +2,25 @@ using System; using System.Collections.Generic; using System.Collections.ObjectModel; using Avalonia.Controls; -using Avalonia.Markup.Xaml; using Avalonia.Media; using CommunityToolkit.Mvvm.ComponentModel; using CommunityToolkit.Mvvm.Messaging; namespace Semi.Avalonia.Demo.ViewModels; -public class PaletteDemoViewModel: ObservableObject +public class PaletteDemoViewModel : ObservableObject { private readonly string[] _predefinedColorNames = - { + [ "Red", "Pink", "Purple", "Violet", "Indigo", "Blue", "LightBlue", "Cyan", "Teal", "Green", "LightGreen", "Lime", "Yellow", "Amber", "Orange", "Grey" - }; + ]; + private readonly IResourceDictionary? _lightResourceDictionary; private readonly IResourceDictionary? _darkResourceDictionary; - + private ColorItemViewModel _selectedColor = null!; public ColorItemViewModel SelectedColor @@ -28,26 +28,29 @@ public class PaletteDemoViewModel: ObservableObject get => _selectedColor; set => SetProperty(ref _selectedColor, value); } - - + + private ObservableCollection? _lightLists; + public ObservableCollection? LightLists { get => _lightLists; set => SetProperty(ref _lightLists, value); } + private ObservableCollection? _darkLists; + public ObservableCollection? DarkLists { get => _darkLists; set => SetProperty(ref _darkLists, value); } - public ObservableCollection FunctionalColors { get; set; } = new(); + public ObservableCollection FunctionalColors { get; set; } = []; public PaletteDemoViewModel() { - _lightResourceDictionary = new Light.Palette(); + _lightResourceDictionary = new Light.Palette(); _darkResourceDictionary = new Dark.Palette(); WeakReferenceMessenger.Default.Register(this, OnClickColorItem); } @@ -60,14 +63,15 @@ public class PaletteDemoViewModel: ObservableObject private void InitializePalette() { - LightLists = new ObservableCollection(); + LightLists = []; foreach (var color in _predefinedColorNames) { ColorListViewModel s = new ColorListViewModel(); s.Initialize(_lightResourceDictionary, color, true); LightLists.Add(s); } - DarkLists = new ObservableCollection(); + + DarkLists = []; foreach (var color in _predefinedColorNames) { ColorListViewModel s = new ColorListViewModel(); @@ -92,13 +96,14 @@ public class PaletteDemoViewModel: ObservableObject FunctionalColors.Add(new FunctionalColorGroupViewModel("Border", _lightResourceDictionary, _darkResourceDictionary, ColorTokens.BorderTokens)); FunctionalColors.Add(new FunctionalColorGroupViewModel("Disabled", _lightResourceDictionary, _darkResourceDictionary, ColorTokens.DisabledTokens)); } + private void OnClickColorItem(PaletteDemoViewModel vm, ColorItemViewModel item) { SelectedColor = item; } } -public class ColorListViewModel: ObservableObject +public class ColorListViewModel : ObservableObject { private ObservableCollection? _colors; @@ -115,17 +120,18 @@ public class ColorListViewModel: ObservableObject get => _seriesName; set => SetProperty(ref _seriesName, value); } - + internal void Initialize(IResourceDictionary? resourceDictionary, string color, bool light) { if (resourceDictionary is null) { return; } + SeriesName = color; - Color = new ObservableCollection(); - - for (int i = 0; i < 10; i++) + Color = []; + + for (var i = 0; i < 10; i++) { var key = "Semi" + color + i; if (resourceDictionary.TryGetValue(key, out var value)) @@ -136,7 +142,7 @@ public class ColorListViewModel: ObservableObject var item = new ColorItemViewModel(name, brush, key, light, i); item.ColorResourceKey = item.ResourceKey + "Color"; Color.Add(item); - } + } } } } @@ -144,15 +150,16 @@ public class ColorListViewModel: ObservableObject public class ColorItemViewModel : ObservableObject { - private IBrush _brush = null!; + public IBrush Brush { get => _brush; set => SetProperty(ref _brush, value); } - + private IBrush _textBrush = null!; + public IBrush TextBrush { get => _textBrush; @@ -160,6 +167,7 @@ public class ColorItemViewModel : ObservableObject } private string _colorDisplayName = null!; + public string ColorDisplayName { get => _colorDisplayName; @@ -189,8 +197,9 @@ public class ColorItemViewModel : ObservableObject get => _hex; set => SetProperty(ref _hex, value); } - - public ColorItemViewModel(string colorDisplayName, ISolidColorBrush brush, string resourceKey, bool light, int index) + + public ColorItemViewModel(string colorDisplayName, ISolidColorBrush brush, string resourceKey, bool light, + int index) { ColorDisplayName = colorDisplayName; Brush = brush; @@ -210,22 +219,22 @@ public class ColorItemViewModel : ObservableObject public class FunctionalColorGroupViewModel : ObservableObject { private string _title = null!; + public string Title { get => _title; set => SetProperty(ref _title, value); } - public ObservableCollection LightColors { get; set; } = new(); - public ObservableCollection DarkColors { get; set; } = new(); + public ObservableCollection LightColors { get; set; } = []; + public ObservableCollection DarkColors { get; set; } = []; - public FunctionalColorGroupViewModel(string title, IResourceDictionary? lightDictionary, IResourceDictionary? darkDictionary, IReadOnlyList> tokens) + public FunctionalColorGroupViewModel(string title, IResourceDictionary? lightDictionary, + IResourceDictionary? darkDictionary, IReadOnlyList> tokens) { Title = title; - foreach (var token in tokens) + foreach (var (key, name) in tokens) { - string key = token.Item1; - string name = token.Item2; if (lightDictionary?.TryGetValue(key, out var lightValue) ?? false) { if (lightValue is ISolidColorBrush lightBrush) @@ -249,121 +258,120 @@ public static class ColorTokens { public static IReadOnlyList> PrimaryTokens { get; } = new List> { - new ("SemiColorPrimary", "Primary"), - new ("SemiColorPrimaryPointerover", "Primary Pointerover"), - new ("SemiColorPrimaryActive", "Primary Active"), - new ("SemiColorPrimaryDisabled", "Primary Disabled"), - new ("SemiColorPrimaryLight", "Primary Light"), - new ("SemiColorPrimaryLightPointerover", "Primary Light Pointerover"), - new ("SemiColorPrimaryLightActive", "Primary Light Active"), + new("SemiColorPrimary", "Primary"), + new("SemiColorPrimaryPointerover", "Primary Pointerover"), + new("SemiColorPrimaryActive", "Primary Active"), + new("SemiColorPrimaryDisabled", "Primary Disabled"), + new("SemiColorPrimaryLight", "Primary Light"), + new("SemiColorPrimaryLightPointerover", "Primary Light Pointerover"), + new("SemiColorPrimaryLightActive", "Primary Light Active"), }; public static IReadOnlyList> SecondaryTokens { get; } = new List> { - new ("SemiColorSecondary", "Secondary"), - new ("SemiColorSecondaryPointerover", "Secondary Pointerover"), - new ("SemiColorSecondaryActive", "Secondary Active"), - new ("SemiColorSecondaryDisabled", "Secondary Disabled"), - new ("SemiColorSecondaryLight", "Secondary Light"), - new ("SemiColorSecondaryLightPointerover", "Secondary Light Pointerover"), - new ("SemiColorSecondaryLightActive", "Secondary Light Active"), + new("SemiColorSecondary", "Secondary"), + new("SemiColorSecondaryPointerover", "Secondary Pointerover"), + new("SemiColorSecondaryActive", "Secondary Active"), + new("SemiColorSecondaryDisabled", "Secondary Disabled"), + new("SemiColorSecondaryLight", "Secondary Light"), + new("SemiColorSecondaryLightPointerover", "Secondary Light Pointerover"), + new("SemiColorSecondaryLightActive", "Secondary Light Active"), }; - + public static IReadOnlyList> TertiaryTokens { get; } = new List> { - new ("SemiColorTertiary", "Tertiary"), - new ("SemiColorTertiaryPointerover", "Tertiary Pointerover"), - new ("SemiColorTertiaryActive", "Tertiary Active"), - new ("SemiColorTertiaryLight", "Tertiary Light"), - new ("SemiColorTertiaryLightPointerover", "Tertiary Light Pointerover"), - new ("SemiColorTertiaryLightActive", "Tertiary Light Active"), + new("SemiColorTertiary", "Tertiary"), + new("SemiColorTertiaryPointerover", "Tertiary Pointerover"), + new("SemiColorTertiaryActive", "Tertiary Active"), + new("SemiColorTertiaryLight", "Tertiary Light"), + new("SemiColorTertiaryLightPointerover", "Tertiary Light Pointerover"), + new("SemiColorTertiaryLightActive", "Tertiary Light Active"), }; - + public static IReadOnlyList> InformationTokens { get; } = new List> { - new ("SemiColorInformation", "Information"), - new ("SemiColorInformationPointerover", "Information Pointerover"), - new ("SemiColorInformationActive", "Information Active"), - new ("SemiColorInformationDisabled", "Information Disabled"), - new ("SemiColorInformationLight", "Information Light"), - new ("SemiColorInformationLightPointerover", "Information Light Pointerover"), - new ("SemiColorInformationLightActive", "Information Light Active"), + new("SemiColorInformation", "Information"), + new("SemiColorInformationPointerover", "Information Pointerover"), + new("SemiColorInformationActive", "Information Active"), + new("SemiColorInformationDisabled", "Information Disabled"), + new("SemiColorInformationLight", "Information Light"), + new("SemiColorInformationLightPointerover", "Information Light Pointerover"), + new("SemiColorInformationLightActive", "Information Light Active"), }; - + public static IReadOnlyList> SuccessTokens { get; } = new List> { - new ("SemiColorSuccess", "Success"), - new ("SemiColorSuccessPointerover", "Success Pointerover"), - new ("SemiColorSuccessActive", "Success Active"), - new ("SemiColorSuccessDisabled", "Success Disabled"), - new ("SemiColorSuccessLight", "Success Light"), - new ("SemiColorSuccessLightPointerover", "Success Light Pointerover"), - new ("SemiColorSuccessLightActive", "Success Light Active"), + new("SemiColorSuccess", "Success"), + new("SemiColorSuccessPointerover", "Success Pointerover"), + new("SemiColorSuccessActive", "Success Active"), + new("SemiColorSuccessDisabled", "Success Disabled"), + new("SemiColorSuccessLight", "Success Light"), + new("SemiColorSuccessLightPointerover", "Success Light Pointerover"), + new("SemiColorSuccessLightActive", "Success Light Active"), }; - + public static IReadOnlyList> WarningTokens { get; } = new List> { - new ("SemiColorWarning", "Warning"), - new ("SemiColorWarningPointerover", "Warning Pointerover"), - new ("SemiColorWarningActive", "Warning Active"), - new ("SemiColorWarningLight", "Warning Light"), - new ("SemiColorWarningLightPointerover", "Warning Light Pointerover"), - new ("SemiColorWarningLightActive", "Warning Light Active"), + new("SemiColorWarning", "Warning"), + new("SemiColorWarningPointerover", "Warning Pointerover"), + new("SemiColorWarningActive", "Warning Active"), + new("SemiColorWarningLight", "Warning Light"), + new("SemiColorWarningLightPointerover", "Warning Light Pointerover"), + new("SemiColorWarningLightActive", "Warning Light Active"), }; - + public static IReadOnlyList> DangerTokens { get; } = new List> { - new ("SemiColorDanger", "Danger"), - new ("SemiColorDangerPointerover", "Danger Pointerover"), - new ("SemiColorDangerActive", "Danger Active"), - new ("SemiColorDangerLight", "Danger Light"), - new ("SemiColorDangerLightPointerover", "Danger Light Pointerover"), - new ("SemiColorDangerLightActive", "Danger Light Active"), + new("SemiColorDanger", "Danger"), + new("SemiColorDangerPointerover", "Danger Pointerover"), + new("SemiColorDangerActive", "Danger Active"), + new("SemiColorDangerLight", "Danger Light"), + new("SemiColorDangerLightPointerover", "Danger Light Pointerover"), + new("SemiColorDangerLightActive", "Danger Light Active"), }; public static IReadOnlyList> TextTokens { get; } = new List> { - new ("SemiColorText0", "Text 0"), - new ("SemiColorText1", "Text 1"), - new ("SemiColorText2", "Text 2"), - new ("SemiColorText3", "Text 3"), + new("SemiColorText0", "Text 0"), + new("SemiColorText1", "Text 1"), + new("SemiColorText2", "Text 2"), + new("SemiColorText3", "Text 3"), }; - + public static IReadOnlyList> LinkTokens { get; } = new List> { - new ("SemiColorLink", "Link"), - new ("SemiColorLinkPointerover", "Link Pointerover"), - new ("SemiColorLinkActive", "Link Active"), - new ("SemiColorLinkVisited", "Link Visited"), + new("SemiColorLink", "Link"), + new("SemiColorLinkPointerover", "Link Pointerover"), + new("SemiColorLinkActive", "Link Active"), + new("SemiColorLinkVisited", "Link Visited"), }; - + public static IReadOnlyList> BackgroundTokens { get; } = new List> { - new ("SemiColorBackground0", "Background 0"), - new ("SemiColorBackground1", "Background 1"), - new ("SemiColorBackground2", "Background 2"), - new ("SemiColorBackground3", "Background 3"), - new ("SemiColorBackground4", "Background 4"), + new("SemiColorBackground0", "Background 0"), + new("SemiColorBackground1", "Background 1"), + new("SemiColorBackground2", "Background 2"), + new("SemiColorBackground3", "Background 3"), + new("SemiColorBackground4", "Background 4"), }; - + public static IReadOnlyList> FillTokens { get; } = new List> { - new ("SemiColorFill0", "Fill 0"), - new ("SemiColorFill1", "Fill 1"), - new ("SemiColorFill2", "Fill 2"), + new("SemiColorFill0", "Fill 0"), + new("SemiColorFill1", "Fill 1"), + new("SemiColorFill2", "Fill 2"), }; - + public static IReadOnlyList> BorderTokens { get; } = new List> { - new ("SemiColorBorder", "Border"), + new("SemiColorBorder", "Border"), }; - + public static IReadOnlyList> DisabledTokens { get; } = new List> { - new ("SemiColorDisabledText", "Disabled Text"), - new ("SemiColorDisabledBorder", "Disabled Border"), - new ("SemiColorDisabledBackground", "Disabled Background"), - new ("SemiColorDisabledFill", "Disabled Fill"), + new("SemiColorDisabledText", "Disabled Text"), + new("SemiColorDisabledBorder", "Disabled Border"), + new("SemiColorDisabledBackground", "Disabled Background"), + new("SemiColorDisabledFill", "Disabled Fill"), }; - } \ No newline at end of file From 8484d6ad868fd3a23cb695675e1c1da890a9d44f Mon Sep 17 00:00:00 2001 From: Zhang Dian <54255897+zdpcdt@users.noreply.github.com> Date: Fri, 15 Nov 2024 02:20:32 +0800 Subject: [PATCH 5/6] feat: add Shadow part to PaletteDemo. --- .../FunctionalColorGroupControl.axaml | 10 +-- .../Controls/ShadowGroupControl.axaml | 88 +++++++++++++++++++ .../Controls/ShadowGroupControl.cs | 41 +++++++++ .../Pages/PaletteDemo.axaml | 16 +++- .../ViewModels/PaletteDemoViewModel.cs | 86 ++++++++++++++++++ 5 files changed, 234 insertions(+), 7 deletions(-) create mode 100644 demo/Semi.Avalonia.Demo/Controls/ShadowGroupControl.axaml create mode 100644 demo/Semi.Avalonia.Demo/Controls/ShadowGroupControl.cs diff --git a/demo/Semi.Avalonia.Demo/Controls/FunctionalColorGroupControl.axaml b/demo/Semi.Avalonia.Demo/Controls/FunctionalColorGroupControl.axaml index b3d46be..2c74653 100644 --- a/demo/Semi.Avalonia.Demo/Controls/FunctionalColorGroupControl.axaml +++ b/demo/Semi.Avalonia.Demo/Controls/FunctionalColorGroupControl.axaml @@ -6,15 +6,15 @@ x:CompileBindings="True" x:DataType="viewModels:FunctionalColorGroupViewModel"> - - + + - + Theme="{DynamicResource TitleSelectableTextBlock}" /> @@ -129,4 +129,4 @@ - + \ No newline at end of file diff --git a/demo/Semi.Avalonia.Demo/Controls/ShadowGroupControl.axaml b/demo/Semi.Avalonia.Demo/Controls/ShadowGroupControl.axaml new file mode 100644 index 0000000..d06aea4 --- /dev/null +++ b/demo/Semi.Avalonia.Demo/Controls/ShadowGroupControl.axaml @@ -0,0 +1,88 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/demo/Semi.Avalonia.Demo/Controls/ShadowGroupControl.cs b/demo/Semi.Avalonia.Demo/Controls/ShadowGroupControl.cs new file mode 100644 index 0000000..bb59ab1 --- /dev/null +++ b/demo/Semi.Avalonia.Demo/Controls/ShadowGroupControl.cs @@ -0,0 +1,41 @@ +using System.Collections; +using Avalonia; +using Avalonia.Controls.Primitives; + +namespace Semi.Avalonia.Demo.Controls; + +public class ShadowGroupControl : TemplatedControl +{ + public static readonly StyledProperty TitleProperty = + AvaloniaProperty.Register(nameof(Title)); + + public string? Title + { + get => GetValue(TitleProperty); + set => SetValue(TitleProperty, value); + } + + private IEnumerable? _lightShadows; + + public static readonly DirectProperty LightShadowsProperty = + AvaloniaProperty.RegisterDirect(nameof(LightShadows), + o => o.LightShadows, (o, v) => o.LightShadows = v); + + public IEnumerable? LightShadows + { + get => _lightShadows; + set => SetAndRaise(LightShadowsProperty, ref _lightShadows, value); + } + + private IEnumerable? _darkShadows; + + public static readonly DirectProperty DarkShadowsProperty = + AvaloniaProperty.RegisterDirect(nameof(DarkShadows), + o => o.DarkShadows, (o, v) => o.DarkShadows = v); + + public IEnumerable? DarkShadows + { + get => _darkShadows; + set => SetAndRaise(DarkShadowsProperty, ref _darkShadows, value); + } +} \ No newline at end of file diff --git a/demo/Semi.Avalonia.Demo/Pages/PaletteDemo.axaml b/demo/Semi.Avalonia.Demo/Pages/PaletteDemo.axaml index 8293c53..64fdd52 100644 --- a/demo/Semi.Avalonia.Demo/Pages/PaletteDemo.axaml +++ b/demo/Semi.Avalonia.Demo/Pages/PaletteDemo.axaml @@ -21,6 +21,7 @@ + @@ -115,7 +116,6 @@ - + + + + + + + + + - + \ No newline at end of file diff --git a/demo/Semi.Avalonia.Demo/ViewModels/PaletteDemoViewModel.cs b/demo/Semi.Avalonia.Demo/ViewModels/PaletteDemoViewModel.cs index 4a53cb7..cf23454 100644 --- a/demo/Semi.Avalonia.Demo/ViewModels/PaletteDemoViewModel.cs +++ b/demo/Semi.Avalonia.Demo/ViewModels/PaletteDemoViewModel.cs @@ -47,6 +47,7 @@ public class PaletteDemoViewModel : ObservableObject } public ObservableCollection FunctionalColors { get; set; } = []; + public ObservableCollection Shadows { get; set; } = []; public PaletteDemoViewModel() { @@ -59,6 +60,7 @@ public class PaletteDemoViewModel : ObservableObject { InitializePalette(); InitializeFunctionalColors(); + InitializeShadows(); } private void InitializePalette() @@ -97,6 +99,11 @@ public class PaletteDemoViewModel : ObservableObject FunctionalColors.Add(new FunctionalColorGroupViewModel("Disabled", _lightResourceDictionary, _darkResourceDictionary, ColorTokens.DisabledTokens)); } + private void InitializeShadows() + { + Shadows.Add(new ShadowGroupViewModel("Shadow", _lightResourceDictionary, _darkResourceDictionary, ColorTokens.ShadowTokens)); + } + private void OnClickColorItem(PaletteDemoViewModel vm, ColorItemViewModel item) { SelectedColor = item; @@ -254,6 +261,79 @@ public class FunctionalColorGroupViewModel : ObservableObject } } +public class ShadowItemViewModel : ObservableObject +{ + private string _shadowDisplayName = null!; + + public string ShadowDisplayName + { + get => _shadowDisplayName; + set => SetProperty(ref _shadowDisplayName, value); + } + + private string _resourceKey = null!; + + public string ResourceKey + { + get => _resourceKey; + set => SetProperty(ref _resourceKey, value); + } + + private string _boxShadowValue = null!; + + public string BoxShadowValue + { + get => _boxShadowValue; + set => SetProperty(ref _boxShadowValue, value); + } + + public ShadowItemViewModel(string shadowDisplayName, BoxShadows boxShadows, string resourceKey) + { + ShadowDisplayName = shadowDisplayName; + ResourceKey = resourceKey; + BoxShadowValue = boxShadows.ToString(); + } +} + +public class ShadowGroupViewModel : ObservableObject +{ + private string _title = null!; + + public string Title + { + get => _title; + set => SetProperty(ref _title, value); + } + + public ObservableCollection LightShadows { get; set; } = []; + public ObservableCollection DarkShadows { get; set; } = []; + + + public ShadowGroupViewModel(string title, IResourceDictionary? lightDictionary, + IResourceDictionary? darkDictionary, IReadOnlyList> tokens) + { + Title = title; + foreach (var (key, name) in tokens) + { + if (lightDictionary?.TryGetValue(key, out var lightValue) ?? false) + { + if (lightValue is BoxShadows lightShadow) + { + LightShadows.Add(new ShadowItemViewModel(name, lightShadow, key)); + } + } + + if (darkDictionary?.TryGetValue(key, out var darkValue) ?? false) + { + if (darkValue is BoxShadows darkShadow) + { + DarkShadows.Add(new ShadowItemViewModel(name, darkShadow, key)); + } + } + } + } +} + public static class ColorTokens { public static IReadOnlyList> PrimaryTokens { get; } = new List> @@ -374,4 +454,10 @@ public static class ColorTokens new("SemiColorDisabledBackground", "Disabled Background"), new("SemiColorDisabledFill", "Disabled Fill"), }; + + public static IReadOnlyList> ShadowTokens { get; } = new List> + { + new("SemiColorShadow", "Shadow"), + new("SemiShadowElevated", "Shadow Elevated"), + }; } \ No newline at end of file From 8cdac330a4143fcb0ee2d95f29d10e5cce08f0ff Mon Sep 17 00:00:00 2001 From: Zhang Dian <54255897+zdpcdt@users.noreply.github.com> Date: Fri, 15 Nov 2024 02:22:03 +0800 Subject: [PATCH 6/6] misc: unify BoxShadows resources. --- src/Semi.Avalonia.ColorPicker/Dark.axaml | 2 +- src/Semi.Avalonia.ColorPicker/Light.axaml | 2 +- src/Semi.Avalonia/Themes/Dark/AutoCompleteBox.axaml | 2 +- src/Semi.Avalonia/Themes/Dark/Border.axaml | 2 +- src/Semi.Avalonia/Themes/Dark/CalendarDatePicker.axaml | 2 +- src/Semi.Avalonia/Themes/Dark/ComboBox.axaml | 2 +- src/Semi.Avalonia/Themes/Dark/DateTimePickerShared.axaml | 2 +- src/Semi.Avalonia/Themes/Dark/Flyout.axaml | 2 +- src/Semi.Avalonia/Themes/Dark/Menu.axaml | 2 +- src/Semi.Avalonia/Themes/Dark/NotificationCard.axaml | 2 +- src/Semi.Avalonia/Themes/Dark/Palette.axaml | 4 ++-- src/Semi.Avalonia/Themes/Light/AutoCompleteBox.axaml | 2 +- src/Semi.Avalonia/Themes/Light/Border.axaml | 2 +- src/Semi.Avalonia/Themes/Light/CalendarDatePicker.axaml | 2 +- src/Semi.Avalonia/Themes/Light/ComboBox.axaml | 2 +- src/Semi.Avalonia/Themes/Light/DateTimePickerShared.axaml | 2 +- src/Semi.Avalonia/Themes/Light/Flyout.axaml | 2 +- src/Semi.Avalonia/Themes/Light/Menu.axaml | 2 +- src/Semi.Avalonia/Themes/Light/NotificationCard.axaml | 2 +- src/Semi.Avalonia/Themes/Light/Palette.axaml | 4 ++-- 20 files changed, 22 insertions(+), 22 deletions(-) diff --git a/src/Semi.Avalonia.ColorPicker/Dark.axaml b/src/Semi.Avalonia.ColorPicker/Dark.axaml index 7ba3a79..f514861 100644 --- a/src/Semi.Avalonia.ColorPicker/Dark.axaml +++ b/src/Semi.Avalonia.ColorPicker/Dark.axaml @@ -17,5 +17,5 @@ - inset 0 0 0 1 #1AFFFFFF, 0 4 14 0 #40000000 + inset 0 0 0 1 #1AFFFFFF, 0 4 14 #40000000 \ No newline at end of file diff --git a/src/Semi.Avalonia.ColorPicker/Light.axaml b/src/Semi.Avalonia.ColorPicker/Light.axaml index 946f707..514b984 100644 --- a/src/Semi.Avalonia.ColorPicker/Light.axaml +++ b/src/Semi.Avalonia.ColorPicker/Light.axaml @@ -17,5 +17,5 @@ - 0 0 1 0 #4A000000, 0 4 14 0 #1A000000 + 0 0 1 #4A000000, 0 4 14 #1A000000 \ No newline at end of file diff --git a/src/Semi.Avalonia/Themes/Dark/AutoCompleteBox.axaml b/src/Semi.Avalonia/Themes/Dark/AutoCompleteBox.axaml index 575d378..032758e 100644 --- a/src/Semi.Avalonia/Themes/Dark/AutoCompleteBox.axaml +++ b/src/Semi.Avalonia/Themes/Dark/AutoCompleteBox.axaml @@ -1,5 +1,5 @@ - inset 0 0 0 1 #1AFFFFFF, 0 4 14 0 #40000000 + inset 0 0 0 1 #1AFFFFFF, 0 4 14 #40000000 \ No newline at end of file diff --git a/src/Semi.Avalonia/Themes/Dark/Border.axaml b/src/Semi.Avalonia/Themes/Dark/Border.axaml index d36d0ac..8593cc1 100644 --- a/src/Semi.Avalonia/Themes/Dark/Border.axaml +++ b/src/Semi.Avalonia/Themes/Dark/Border.axaml @@ -1,5 +1,5 @@ - inset 0 0 0 1 #1AFFFFFF, 0 4 14 0 #40000000 + inset 0 0 0 1 #1AFFFFFF, 0 4 14 #40000000 \ No newline at end of file diff --git a/src/Semi.Avalonia/Themes/Dark/CalendarDatePicker.axaml b/src/Semi.Avalonia/Themes/Dark/CalendarDatePicker.axaml index 9900582..6be4aac 100644 --- a/src/Semi.Avalonia/Themes/Dark/CalendarDatePicker.axaml +++ b/src/Semi.Avalonia/Themes/Dark/CalendarDatePicker.axaml @@ -9,7 +9,7 @@ - inset 0 0 0 1 #1AFFFFFF, 0 4 14 0 #40000000 + inset 0 0 0 1 #1AFFFFFF, 0 4 14 #40000000 diff --git a/src/Semi.Avalonia/Themes/Dark/ComboBox.axaml b/src/Semi.Avalonia/Themes/Dark/ComboBox.axaml index a77883a..08b1b1e 100644 --- a/src/Semi.Avalonia/Themes/Dark/ComboBox.axaml +++ b/src/Semi.Avalonia/Themes/Dark/ComboBox.axaml @@ -18,7 +18,7 @@ - inset 0 0 0 1 #1AFFFFFF, 0 4 14 0 #40000000 + inset 0 0 0 1 #1AFFFFFF, 0 4 14 #40000000 diff --git a/src/Semi.Avalonia/Themes/Dark/DateTimePickerShared.axaml b/src/Semi.Avalonia/Themes/Dark/DateTimePickerShared.axaml index 949ca97..2a19de4 100644 --- a/src/Semi.Avalonia/Themes/Dark/DateTimePickerShared.axaml +++ b/src/Semi.Avalonia/Themes/Dark/DateTimePickerShared.axaml @@ -26,5 +26,5 @@ - inset 0 0 0 1 #1AFFFFFF, 0 4 14 0 #40000000 + inset 0 0 0 1 #1AFFFFFF, 0 4 14 #40000000 \ No newline at end of file diff --git a/src/Semi.Avalonia/Themes/Dark/Flyout.axaml b/src/Semi.Avalonia/Themes/Dark/Flyout.axaml index 0d865df..463e7fa 100644 --- a/src/Semi.Avalonia/Themes/Dark/Flyout.axaml +++ b/src/Semi.Avalonia/Themes/Dark/Flyout.axaml @@ -2,5 +2,5 @@ - inset 0 0 0 1 #1AFFFFFF, 0 4 14 0 #40000000 + inset 0 0 0 1 #1AFFFFFF, 0 4 14 #40000000 \ No newline at end of file diff --git a/src/Semi.Avalonia/Themes/Dark/Menu.axaml b/src/Semi.Avalonia/Themes/Dark/Menu.axaml index d72520d..d3a9ef1 100644 --- a/src/Semi.Avalonia/Themes/Dark/Menu.axaml +++ b/src/Semi.Avalonia/Themes/Dark/Menu.axaml @@ -5,7 +5,7 @@ - inset 0 0 0 1 #1AFFFFFF, 0 4 14 0 #40000000 + inset 0 0 0 1 #1AFFFFFF, 0 4 14 #40000000 diff --git a/src/Semi.Avalonia/Themes/Dark/NotificationCard.axaml b/src/Semi.Avalonia/Themes/Dark/NotificationCard.axaml index 56a1d39..b7d7d0c 100644 --- a/src/Semi.Avalonia/Themes/Dark/NotificationCard.axaml +++ b/src/Semi.Avalonia/Themes/Dark/NotificationCard.axaml @@ -5,7 +5,7 @@ - inset 0 0 0 1 #1AFFFFFF, 0 4 14 0 #40000000 + inset 0 0 0 1 #1AFFFFFF, 0 4 14 #40000000 diff --git a/src/Semi.Avalonia/Themes/Dark/Palette.axaml b/src/Semi.Avalonia/Themes/Dark/Palette.axaml index 9fa8732..9d52d2e 100644 --- a/src/Semi.Avalonia/Themes/Dark/Palette.axaml +++ b/src/Semi.Avalonia/Themes/Dark/Palette.axaml @@ -423,6 +423,6 @@ - 0 0 0 0 #0A000000 - inset 0 0 0 1 #1AFFFFFF, 0 4 14 0 #40000000 + 0 0 #0A000000 + inset 0 0 0 1 #1AFFFFFF, 0 4 14 #40000000 \ No newline at end of file diff --git a/src/Semi.Avalonia/Themes/Light/AutoCompleteBox.axaml b/src/Semi.Avalonia/Themes/Light/AutoCompleteBox.axaml index 520f9b5..24d2c0e 100644 --- a/src/Semi.Avalonia/Themes/Light/AutoCompleteBox.axaml +++ b/src/Semi.Avalonia/Themes/Light/AutoCompleteBox.axaml @@ -1,5 +1,5 @@ - 0 0 1 0 #4A000000, 0 4 14 0 #1A000000 + 0 0 1 #4A000000, 0 4 14 #1A000000 \ No newline at end of file diff --git a/src/Semi.Avalonia/Themes/Light/Border.axaml b/src/Semi.Avalonia/Themes/Light/Border.axaml index be23f5c..9a473d0 100644 --- a/src/Semi.Avalonia/Themes/Light/Border.axaml +++ b/src/Semi.Avalonia/Themes/Light/Border.axaml @@ -1,5 +1,5 @@ - 0 0 1 0 #4A000000, 0 4 14 0 #1A000000 + 0 0 1 #4A000000, 0 4 14 #1A000000 \ No newline at end of file diff --git a/src/Semi.Avalonia/Themes/Light/CalendarDatePicker.axaml b/src/Semi.Avalonia/Themes/Light/CalendarDatePicker.axaml index a4f69b5..293451b 100644 --- a/src/Semi.Avalonia/Themes/Light/CalendarDatePicker.axaml +++ b/src/Semi.Avalonia/Themes/Light/CalendarDatePicker.axaml @@ -9,7 +9,7 @@ - 0 0 1 0 #4A000000, 0 4 14 0 #1A000000 + 0 0 1 #4A000000, 0 4 14 #1A000000 diff --git a/src/Semi.Avalonia/Themes/Light/ComboBox.axaml b/src/Semi.Avalonia/Themes/Light/ComboBox.axaml index 71dbbc4..5dd62ad 100644 --- a/src/Semi.Avalonia/Themes/Light/ComboBox.axaml +++ b/src/Semi.Avalonia/Themes/Light/ComboBox.axaml @@ -17,7 +17,7 @@ - 0 0 1 0 #4A000000, 0 4 14 0 #1A000000 + 0 0 1 #4A000000, 0 4 14 #1A000000 diff --git a/src/Semi.Avalonia/Themes/Light/DateTimePickerShared.axaml b/src/Semi.Avalonia/Themes/Light/DateTimePickerShared.axaml index ab864ed..24d691b 100644 --- a/src/Semi.Avalonia/Themes/Light/DateTimePickerShared.axaml +++ b/src/Semi.Avalonia/Themes/Light/DateTimePickerShared.axaml @@ -28,5 +28,5 @@ - 0 0 1 0 #4A000000, 0 4 14 0 #1A000000 + 0 0 1 #4A000000, 0 4 14 #1A000000 \ No newline at end of file diff --git a/src/Semi.Avalonia/Themes/Light/Flyout.axaml b/src/Semi.Avalonia/Themes/Light/Flyout.axaml index aac33f5..85ef491 100644 --- a/src/Semi.Avalonia/Themes/Light/Flyout.axaml +++ b/src/Semi.Avalonia/Themes/Light/Flyout.axaml @@ -2,5 +2,5 @@ - 0 0 1 0 #4A000000, 0 4 14 0 #1A000000 + 0 0 1 #4A000000, 0 4 14 #1A000000 \ No newline at end of file diff --git a/src/Semi.Avalonia/Themes/Light/Menu.axaml b/src/Semi.Avalonia/Themes/Light/Menu.axaml index 8b73bb2..254beca 100644 --- a/src/Semi.Avalonia/Themes/Light/Menu.axaml +++ b/src/Semi.Avalonia/Themes/Light/Menu.axaml @@ -5,7 +5,7 @@ - 0 0 1 0 #4A000000, 0 4 14 0 #1A000000 + 0 0 1 #4A000000, 0 4 14 #1A000000 diff --git a/src/Semi.Avalonia/Themes/Light/NotificationCard.axaml b/src/Semi.Avalonia/Themes/Light/NotificationCard.axaml index a25270d..e1c5732 100644 --- a/src/Semi.Avalonia/Themes/Light/NotificationCard.axaml +++ b/src/Semi.Avalonia/Themes/Light/NotificationCard.axaml @@ -5,7 +5,7 @@ - 0 0 1 0 #4A000000, 0 4 14 0 #1A000000 + 0 0 1 #4A000000, 0 4 14 #1A000000 diff --git a/src/Semi.Avalonia/Themes/Light/Palette.axaml b/src/Semi.Avalonia/Themes/Light/Palette.axaml index 9be8e8f..af79721 100644 --- a/src/Semi.Avalonia/Themes/Light/Palette.axaml +++ b/src/Semi.Avalonia/Themes/Light/Palette.axaml @@ -423,6 +423,6 @@ - 0 0 0 0 #0A000000 - 0 0 1 0 #4A000000, 0 4 14 0 #1A000000 + 0 0 #0A000000 + 0 0 1 #4A000000, 0 4 14 #1A000000 \ No newline at end of file