TextAreaField

A multi-line text input field for collecting longer content such as descriptions, comments, or notes. The visible height is controlled by the Rows parameter.

Basic Usage

<ArcadiaForm Model="model">
    <TextAreaField Field="@nameof(Model.Description)" Label="Description" />
</ArcadiaForm>

Larger Text Area

<TextAreaField Field="@nameof(Model.Notes)" Label="Notes" Rows="8" Placeholder="Enter your notes here..." />

Parameters

ParameterTypeDefaultDescription
Valuestring?nullThe current multi-line text content. Supports two-way binding.
ValueChangedEventCallback<string?>Callback invoked whenever the user modifies the textarea content.
Rowsint4The visible number of text rows in the textarea.

Inherited from FieldBase

ParameterTypeDefaultDescription
Labelstring?nullVisible label displayed above the field.
Placeholderstring?nullPlaceholder text shown when the field is empty.
HelperTextstring?nullHelper text displayed below the field.
RequiredboolfalseWhether the field is required.
DisabledboolfalseWhether the field is disabled.
ReadOnlyboolfalseWhether the field is read-only.
ErrorsIReadOnlyList<string>?nullValidation errors to display.
SchemaFieldSchema?nullField schema definition for dynamic form generation.

Validation

public class FeedbackModel
{
    [Required]
    [StringLength(2000, ErrorMessage = "Description cannot exceed 2000 characters.")]
    public string Description { get; set; } = "";
}

Accessibility

  • Label is linked to the textarea via for/id attributes.
  • Required fields set aria-required="true" and display a visual * indicator.
  • Validation errors are linked via aria-describedby and announced with role="alert".