Skip to content

Commit 0ad3d90

Browse files
authored
Merge pull request #4602 from syncfusion-content/890708-hotfix2
890708: Textarea component documentation corrections in Blazor
2 parents 806fa14 + 9912973 commit 0ad3d90

File tree

2 files changed

+42
-41
lines changed

2 files changed

+42
-41
lines changed

blazor/textarea/events.md

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -31,33 +31,33 @@ The TextArea component triggers the [Created](https://help.syncfusion.com/cr/bla
3131
## Input event
3232

3333
The TextArea component triggers the [Input](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Inputs.SfTextArea.html#Syncfusion_Blazor_Inputs_SfTextArea_Input) each time when the value of TextArea has changed. This event provides users with an opportunity to perform actions in response to real-time changes in the TextArea's content.
34-
The [InputEventArgs](../api/textbox/InputEventArgs/) passed as an event argument provides the details about the input event in the TextArea.
34+
The [TextAreaInputEventArgs](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Inputs.TextAreaInputEventArgs.html) passed as an event argument provides the details about the input event in the TextArea.
3535

3636
```cshtml
3737
@using Syncfusion.Blazor.Inputs
3838
3939
<SfTextArea Input="@InputHandler"></SfTextArea>
4040
4141
@code {
42-
private void InputHandler(InputEventArgs args)
42+
private void InputHandler(TextAreaInputEventArgs args)
4343
{
4444
// Here you can customize your code
4545
}
4646
}
4747
```
4848

49-
## Change event
49+
## ValueChange event
5050

51-
The TextArea component triggers the [Change](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Inputs.SfTextArea.html#Syncfusion_Blazor_Inputs_SfTextArea_Change) event when the content of TextArea has changed and gets focus-out. This event provides users with an opportunity to execute specific actions in response to changes made by the user.
52-
The [ChangedEventArgs](../api/textbox/ChangedEventArgs/) passed as an event argument provides the details about the changes in the TextArea's value.
51+
The TextArea component triggers the [ValueChange](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Inputs.SfTextArea.html#Syncfusion_Blazor_Inputs_SfTextArea_ValueChange) event when the content of TextArea has changed and gets focus-out. This event provides users with an opportunity to execute specific actions in response to changes made by the user.
52+
The [TextAreaValueChangeEventArgs](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Inputs.TextAreaValueChangeEventArgs.html) passed as an event argument provides the details about the changes in the TextArea's value.
5353

5454
```cshtml
5555
@using Syncfusion.Blazor.Inputs
5656
57-
<SfTextArea Change="@ChangeHandler"></SfTextArea>
57+
<SfTextArea ValueChange="@ChangeHandler"></SfTextArea>
5858
5959
@code {
60-
private void ChangeHandler(ChangedEventArgs args)
60+
private void ChangeHandler(TextAreaValueChangeEventArgs args)
6161
{
6262
// Here you can customize your code
6363
}
@@ -67,15 +67,15 @@ The [ChangedEventArgs](../api/textbox/ChangedEventArgs/) passed as an event argu
6767
## Focus event
6868

6969
The TextArea component triggers the [Focus](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Inputs.SfTextArea.html#Syncfusion_Blazor_Inputs_SfTextArea_Focus ) when the TextArea gains focus. This event allows developers to execute specific actions when the user interacts with the TextArea by focusing on it.
70-
The [FocusInEventArgs](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Inputs.SfTextArea.html#Syncfusion_Blazor_Inputs_SfTextArea_FocusInEventArgs/) passed as an argument provides details about the focus event in the TextArea.
70+
The [TextAreaFocusInEventArgs](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Inputs.TextAreaFocusInEventArgs.html) passed as an argument provides details about the focus event in the TextArea.
7171

7272
```cshtml
7373
@using Syncfusion.Blazor.Inputs
7474
7575
<SfTextArea Focus="@FocusHandler"></SfTextArea>
7676
7777
@code {
78-
private void FocusHandler(FocusInEventArgs args)
78+
private void FocusHandler(TextAreaFocusInEventArgs args)
7979
{
8080
// Here you can customize your code
8181
}
@@ -85,15 +85,15 @@ The [FocusInEventArgs](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.I
8585
## Blur event
8686

8787
The TextArea component triggers the [Blur](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Inputs.SfTextArea.html#Syncfusion_Blazor_Inputs_SfTextArea_Blur) when the TextArea loses focus. This event allows users to execute specific actions when the user interacts with the TextArea by moving focus away from it.
88-
The [FocusOutEventArgs](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Inputs.SfTextArea.html#Syncfusion_Blazor_Inputs_SfTextArea_FocusOutEventArgs/) passed as an argument provides details about the blur event in the TextArea.
88+
The [TextAreaFocusInEventArgs](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Inputs.TextAreaFocusOutEventArgs.html) passed as an argument provides details about the blur event in the TextArea.
8989

9090
```cshtml
9191
@using Syncfusion.Blazor.Inputs
9292
9393
<SfTextArea Blur="@BlurHandler"></SfTextArea>
9494
9595
@code {
96-
private void BlurHandler(FocusOutEventArgs args)
96+
private void BlurHandler(TextAreaFocusInEventArgs args)
9797
{
9898
// Here you can customize your code
9999
}

blazor/textarea/styles-appearance.md

Lines changed: 31 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ By adding these classes, users can choose between a filled or outline appearance
8989
{% endhighlight %}
9090
{% endtabs %}
9191

92-
>Note: Filled and Outline theme customization are available only with Material themes.
92+
>Note: Filled and Outline theme customization are available only with Material and Material3 themes.
9393
9494
## Custom styling with CssClass property
9595

@@ -108,12 +108,12 @@ By utilizing the `CssClass` API, users can apply custom CSS classes to the TextA
108108

109109
## Setting the disabled state
110110

111-
To disable the TextArea, you can utilize the [Enabled](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Inputs.SfTextArea.html#Syncfusion_Blazor_Inputs_SfTextArea_Enabled) property. When set to `false`, the TextArea becomes disabled, preventing user interaction. Please find the demo link [here](https://blazor.syncfusion.com/demos/textarea/api?theme=fluent).
111+
To disable the TextArea, you can utilize the [Disabled](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Inputs.SfTextArea.html#Syncfusion_Blazor_Inputs_SfTextArea_Disabled) property. When set to `true`, the TextArea becomes disabled, preventing user interaction. Please find the demo link [here](https://blazor.syncfusion.com/demos/textarea/api?theme=fluent).
112112

113113
{% tabs %}
114114
{% highlight razor %}
115115

116-
<SfTextArea Placeholder='Enter your comments' Enabled="false" ></SfTextArea>
116+
<SfTextArea Placeholder='Enter your comments' Disabled="true" ></SfTextArea>
117117

118118
{% endhighlight %}
119119
{% endtabs %}
@@ -141,9 +141,17 @@ Render the TextArea with `rounded corner` by adding the `e-corner` class to the
141141
{% tabs %}
142142
{% highlight razor %}
143143

144-
<div class="e-corner">
145-
<SfTextArea Placeholder='Enter your comments'></SfTextArea>
146-
</div>
144+
<SfTextArea Placeholder='Enter your comments' CssClass="e-corner"></SfTextArea>
145+
146+
{% endhighlight %}
147+
{% endtabs %}
148+
149+
{% endhighlight %}
150+
{% highlight cshtml tabtitle="Css" %}
151+
152+
.e-input-group.e-corner {
153+
border-radius: 4px;
154+
}
147155

148156
{% endhighlight %}
149157
{% endtabs %}
@@ -200,8 +208,7 @@ You can customize the TextArea styles such as background-color, text-color and b
200208

201209
/* To change the background-color and text-color for textarea */
202210
.e-input-group,
203-
.e-float-input,
204-
.e-float-input.e-input-group { /* csslint allow: adjoining-classes */
211+
.e-input-group.e-multi-line-input { /* csslint allow: adjoining-classes */
205212
background : lightgray;
206213
color: green;
207214
}
@@ -222,16 +229,16 @@ You can change the floating label color of the TextArea for both `success` and `
222229
```css
223230

224231
/* For Success state */
225-
.e-float-input.e-success label.e-float-text,
226-
.e-float-input.e-success input:focus ~ label.e-float-text,
227-
.e-float-input.e-success input:valid ~ label.e-float-text {
232+
.e-float-input.e-success textarea ~ label.e-float-text,
233+
.e-float-input.e-success textarea:focus ~ label.e-float-text,
234+
.e-float-input.e-success textarea:valid ~ label.e-float-text {
228235
color: #22b24b;
229236
}
230237

231238
/* For Warning state */
232-
.e-float-input.e-warning label.e-float-text,
233-
.e-float-input.e-warning input:focus ~ label.e-float-text,
234-
.e-float-input.e-warning input:valid ~ label.e-float-text {
239+
.e-float-input.e-warning textarea ~ label.e-float-text,
240+
.e-float-input.e-warning textarea:focus ~ label.e-float-text,
241+
.e-float-input.e-warning textarea:valid ~ label.e-float-text {
235242
color: #ffca1c;
236243
}
237244

@@ -273,24 +280,18 @@ You can change the floating label color of the TextArea for both `success` and `
273280
width: 340px;
274281
}
275282

276-
.e-float-input.e-success label.e-float-text{ /* csslint allow: adjoining-classes */
277-
color: #22b24b;
278-
}
279-
.e-float-input.e-success input:focus ~ label.e-float-text{ /* csslint allow: adjoining-classes */
280-
color: #22b24b;
281-
}
282-
.e-float-input.e-success input:valid ~ label.e-float-text { /* csslint allow: adjoining-classes */
283-
color: #22b24b;
283+
/* For Success state */
284+
#input-container .e-float-input.e-success textarea ~ label.e-float-text,
285+
#input-container .e-float-input.e-success textarea:focus ~ label.e-float-text,
286+
#input-container .e-float-input.e-success textarea:valid ~ label.e-float-text {
287+
color: #22b24b;
284288
}
285289

286-
.e-float-input.e-warning label.e-float-text{ /* csslint allow: adjoining-classes */
287-
color: #ffca1c;
288-
}
289-
.e-float-input.e-warning input:focus ~ label.e-float-text{ /* csslint allow: adjoining-classes */
290-
color: #ffca1c;
291-
}
292-
.e-float-input.e-warning input:valid ~ label.e-float-text { /* csslint allow: adjoining-classes */
293-
color: #ffca1c;
290+
/* For Warning state */
291+
#input-container .e-float-input.e-warning textarea ~ label.e-float-text,
292+
#input-container .e-float-input.e-warning textarea:focus ~ label.e-float-text,
293+
#input-container .e-float-input.e-warning textarea:valid ~ label.e-float-text {
294+
color: red;
294295
}
295296

296297
{% endhighlight %}

0 commit comments

Comments
 (0)