diff --git a/doc/material-migration.md b/doc/material-migration.md index c5abfcc22..63285b5a2 100644 --- a/doc/material-migration.md +++ b/doc/material-migration.md @@ -17,7 +17,7 @@ Previously, the `PlaceholderText` property acted as a header, displaying in the ##### New Behavior - **PlaceholderText**: Displays inside the TextBox when it's empty. Disappears when text is entered. -- **Header**: Acts as a label. Animates upwards when the TextBox is focused. +- **Header**: Acts as a label. Animates upwards when text is entered. ##### Example diff --git a/src/library/Uno.Material/Styles/Controls/v2/TextBox.xaml b/src/library/Uno.Material/Styles/Controls/v2/TextBox.xaml index 866326aa6..7ac1c84bb 100644 --- a/src/library/Uno.Material/Styles/Controls/v2/TextBox.xaml +++ b/src/library/Uno.Material/Styles/Controls/v2/TextBox.xaml @@ -16,11 +16,11 @@ - Without Header/Placeholder: Simple TextBox - - With placeholder but no header: The placeholder will be displayed where the text is supposed to be until text is inputed + - With placeholder but no header: The placeholder will be displayed where the text is supposed to be until the text is inputted - - With header but no placeholder: The header will be displayed where the text is supposed to be and will move up when focused + - With header but no placeholder: The header will be displayed where the text is supposed to be and will move up when text is inputted - - Whith header and placeholder: The header will be displayed at the top and the placeholder will be displayed where the text is supposed to be until text is inputed + - With header and placeholder: The header will be displayed at the top, and the placeholder will be displayed where the text is supposed to be until the text is inputted --> @@ -356,15 +356,7 @@ - - - - - - - - - + @@ -375,13 +367,6 @@ - - - - - - - @@ -398,6 +383,7 @@ + @@ -412,28 +398,97 @@ - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - + + + - - - - + - + + + + + + + + - - @@ -615,17 +675,7 @@ - - - - - - - - - - - + @@ -634,11 +684,6 @@ - - - - - @@ -665,25 +710,90 @@ + + - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - + + + - - - - + - + + + + + + + + - diff --git a/src/samples/UWP/Uno.Themes.Samples.Shared/Content/Controls/TextBoxSamplePage.xaml b/src/samples/UWP/Uno.Themes.Samples.Shared/Content/Controls/TextBoxSamplePage.xaml index a6659e121..169d23c68 100644 --- a/src/samples/UWP/Uno.Themes.Samples.Shared/Content/Controls/TextBoxSamplePage.xaml +++ b/src/samples/UWP/Uno.Themes.Samples.Shared/Content/Controls/TextBoxSamplePage.xaml @@ -116,6 +116,15 @@ + + + + + + + + + + + + + + + + + + - - + + @@ -157,6 +186,15 @@ + + + + + + + + + + + + + + + + + + - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -201,6 +384,17 @@ AcceptsReturn="True" /> + + + + + @@ -211,6 +405,17 @@ AcceptsReturn="True" /> + + + + + @@ -238,28 +443,6 @@ - - - - - - - - - - - - - - - - - - diff --git a/src/samples/UWP/Uno.Themes.Samples.Shared/Content/Controls/TextBoxSamplePage.xaml.cs b/src/samples/UWP/Uno.Themes.Samples.Shared/Content/Controls/TextBoxSamplePage.xaml.cs index 5edca7fae..7558616e5 100644 --- a/src/samples/UWP/Uno.Themes.Samples.Shared/Content/Controls/TextBoxSamplePage.xaml.cs +++ b/src/samples/UWP/Uno.Themes.Samples.Shared/Content/Controls/TextBoxSamplePage.xaml.cs @@ -1,4 +1,4 @@ -namespace Uno.Themes.Samples.Content.Controls; +namespace Uno.Themes.Samples.Content.Controls; [SamplePage(SampleCategory.Controls, "TextBox", Description = "This control allows users to input a textual value.", DocumentationLink = "https://docs.microsoft.com/en-us/uwp/api/windows.ui.xaml.controls.textbox")] public sealed partial class TextBoxSamplePage : Page