From 6eb405abe25234682a174cfe024ef8627d21720a Mon Sep 17 00:00:00 2001 From: rabbitism Date: Mon, 8 May 2023 22:15:17 +0800 Subject: [PATCH] feat: add textbox internal style, fix various internal textbox styles. --- .../Pages/DataValidationErrorsDemo.axaml | 106 +++++++++-------- .../Controls/AutoCompleteBox.axaml | 61 +++++----- .../Controls/CalendarDatePicker.axaml | 18 ++- src/Semi.Avalonia/Controls/TextBox.axaml | 108 +++++++++++++++++- 4 files changed, 201 insertions(+), 92 deletions(-) diff --git a/demo/Semi.Avalonia.Demo/Pages/DataValidationErrorsDemo.axaml b/demo/Semi.Avalonia.Demo/Pages/DataValidationErrorsDemo.axaml index a5fc5be..1592d38 100644 --- a/demo/Semi.Avalonia.Demo/Pages/DataValidationErrorsDemo.axaml +++ b/demo/Semi.Avalonia.Demo/Pages/DataValidationErrorsDemo.axaml @@ -8,51 +8,63 @@ d:DesignHeight="450" d:DesignWidth="800" mc:Ignorable="d"> - - - - - - - - - - - - - AAA - BBB - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + AAA + BBB + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/Semi.Avalonia/Controls/AutoCompleteBox.axaml b/src/Semi.Avalonia/Controls/AutoCompleteBox.axaml index 93f6747..18110f5 100644 --- a/src/Semi.Avalonia/Controls/AutoCompleteBox.axaml +++ b/src/Semi.Avalonia/Controls/AutoCompleteBox.axaml @@ -12,35 +12,38 @@ - - - - - - - - + + + + + + + + + + diff --git a/src/Semi.Avalonia/Controls/CalendarDatePicker.axaml b/src/Semi.Avalonia/Controls/CalendarDatePicker.axaml index abbd36e..566d2ab 100644 --- a/src/Semi.Avalonia/Controls/CalendarDatePicker.axaml +++ b/src/Semi.Avalonia/Controls/CalendarDatePicker.axaml @@ -65,18 +65,17 @@ BorderThickness="0" CornerRadius="{TemplateBinding CornerRadius}" Foreground="{TemplateBinding Foreground}" + Theme="{DynamicResource NonErrorTextBox}" UseFloatingWatermark="{TemplateBinding UseFloatingWatermark}" Watermark="{TemplateBinding Watermark}"> - - @@ -182,7 +180,7 @@ - @@ -224,7 +222,7 @@ - diff --git a/src/Semi.Avalonia/Controls/TextBox.axaml b/src/Semi.Avalonia/Controls/TextBox.axaml index 823e869..4d107a7 100644 --- a/src/Semi.Avalonia/Controls/TextBox.axaml +++ b/src/Semi.Avalonia/Controls/TextBox.axaml @@ -275,12 +275,108 @@ - - + + + + + + + + +