From ab609394e41b47ac147e49ea2da61423593e99ed Mon Sep 17 00:00:00 2001 From: WenJY Date: Thu, 11 Jun 2026 16:45:16 +0800 Subject: [PATCH] =?UTF-8?q?change=20-=20=E4=BF=AE=E6=94=B9=E7=95=8C?= =?UTF-8?q?=E9=9D=A2=E6=98=BE=E7=A4=BA=E6=95=88=E6=9E=9C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .claude/settings.local.json | 4 +- Sln.Wcs.UI/Views/Base/EntityEditWindow.axaml | 75 ++++++-- .../Views/Base/EntityEditWindow.axaml.cs | 28 +-- .../Views/Base/LocationInfoListView.axaml | 10 +- .../Views/Base/MaterialInfoListView.axaml | 10 +- Sln.Wcs.UI/Views/Base/StoreInfoListView.axaml | 10 +- .../Views/Device/DeviceHostListView.axaml | 10 +- .../Views/Device/DeviceInfoListView.axaml | 10 +- .../Views/Device/DeviceParamListView.axaml | 10 +- Sln.Wcs.UI/Views/HomePageView.axaml | 179 ++++++++---------- Sln.Wcs.UI/Views/MainWindow.axaml | 53 ++++-- Sln.Wcs.UI/Views/MainWindow.axaml.cs | 11 ++ .../Views/Path/PathDetailsListView.axaml | 10 +- Sln.Wcs.UI/Views/Path/PathInfoListView.axaml | 10 +- .../Views/Task/TaskDetailListView.axaml | 10 +- Sln.Wcs.UI/Views/Task/TaskQueueListView.axaml | 10 +- 16 files changed, 254 insertions(+), 196 deletions(-) diff --git a/.claude/settings.local.json b/.claude/settings.local.json index ec2d8c5..36e6ad9 100644 --- a/.claude/settings.local.json +++ b/.claude/settings.local.json @@ -8,7 +8,9 @@ "Bash(dotnet --version)", "Bash(dotnet sln *)", "Bash(dotnet clean *)", - "Bash(cat)" + "Bash(cat)", + "Bash(sed -i '' 's|Background=\"#0F1620\" CornerRadius=\"8\" Padding=\"22\" BorderBrush=\"#1A2F4A\"|CornerRadius=\"8\" Padding=\"22\" BorderBrush=\"#1E3550\"|g' HomePageView.axaml)", + "Bash(sed -i '' 's|||g' HomePageView.axaml)" ] } } diff --git a/Sln.Wcs.UI/Views/Base/EntityEditWindow.axaml b/Sln.Wcs.UI/Views/Base/EntityEditWindow.axaml index dff2e85..958dca6 100644 --- a/Sln.Wcs.UI/Views/Base/EntityEditWindow.axaml +++ b/Sln.Wcs.UI/Views/Base/EntityEditWindow.axaml @@ -3,26 +3,67 @@ x:Class="Sln.Wcs.UI.Views.Base.EntityEditWindow" x:CompileBindings="False" SizeToContent="WidthAndHeight" - MaxWidth="750" MaxHeight="700" + MaxWidth="780" MaxHeight="700" WindowStartupLocation="CenterOwner" Title="编辑" - Background="#0F1620" - Foreground="#BCC8D6" + Background="Transparent" + TransparencyLevelHint="AcrylicBlur" + ExtendClientAreaToDecorationsHint="True" + ExtendClientAreaChromeHints="PreferSystemChrome" + SystemDecorations="Full" CanResize="False"> - - - - + + + + + + + - - + + + + diff --git a/Sln.Wcs.UI/Views/Base/EntityEditWindow.axaml.cs b/Sln.Wcs.UI/Views/Base/EntityEditWindow.axaml.cs index 316870b..c023b6c 100644 --- a/Sln.Wcs.UI/Views/Base/EntityEditWindow.axaml.cs +++ b/Sln.Wcs.UI/Views/Base/EntityEditWindow.axaml.cs @@ -24,7 +24,7 @@ public partial class EntityEditWindow : Window public Task ShowDialog(object entity, List fields, bool isEdit, Window owner) { _entity = entity; - Title = isEdit ? "编辑" : "新增"; + TitleText.Text = isEdit ? "编辑" : "新增"; BuildForm(fields); _tcs = new TaskCompletionSource(); ShowDialog(owner); @@ -43,27 +43,27 @@ public partial class EntityEditWindow : Window if (prop is null) continue; var value = prop.GetValue(_entity); - // 每行一个字段容器: 标题 + 输入框 + // 字段卡片 var cell = new Border { - Width = 340, - Padding = new Thickness(0, 4, 10, 4), + Width = 345, + Padding = new Thickness(12, 6), + Margin = new Thickness(0, 3), }; - var row = new Grid - { - ColumnDefinitions = new ColumnDefinitions("100,*"), - }; + var row = new Grid { ColumnDefinitions = new ColumnDefinitions("90,*") }; + // 标签 var label = new TextBlock { - Text = field.DisplayName + ":", + Text = field.DisplayName, FontSize = 12, - Foreground = Brush.Parse("#8B9BB5"), + Foreground = Brush.Parse("#7B8FA8"), VerticalAlignment = VerticalAlignment.Center, }; row.Children.Add(label); + // 输入框 Control input; if (field.FieldType == FieldType.CheckBox) { @@ -71,7 +71,7 @@ public partial class EntityEditWindow : Window { IsChecked = value is int iv ? iv == 1 : (value as bool? ?? false), IsEnabled = !field.IsReadOnly, - Foreground = Brush.Parse("#DDE4F0"), + Foreground = Brush.Parse("#BCC8D6"), VerticalAlignment = VerticalAlignment.Center, }; cb.IsCheckedChanged += (_, _) => @@ -85,9 +85,13 @@ public partial class EntityEditWindow : Window Text = value?.ToString() ?? "", IsReadOnly = field.IsReadOnly, Watermark = field.DisplayName, - Background = Brush.Parse("#0C1622"), + Background = Brush.Parse("#0A0E14"), Foreground = Brush.Parse("#DDE4F0"), BorderBrush = Brush.Parse("#1A2F4A"), + BorderThickness = new Thickness(1), + CornerRadius = new CornerRadius(3), + Padding = new Thickness(8, 5), + FontSize = 12, }; if (field.FieldType == FieldType.Number) { diff --git a/Sln.Wcs.UI/Views/Base/LocationInfoListView.axaml b/Sln.Wcs.UI/Views/Base/LocationInfoListView.axaml index c8e0a49..ba10bed 100644 --- a/Sln.Wcs.UI/Views/Base/LocationInfoListView.axaml +++ b/Sln.Wcs.UI/Views/Base/LocationInfoListView.axaml @@ -1,11 +1,11 @@ - - - -