Textarea input
The o-textarea-input component is used in forms for getting or displaying text input submitted by the user.
The textarea input is automatically registered on its parent o-form, which provides the value for the input programatically. Its value can be also set manually via the data parameter. This and other attributes are explained on the API section of this page.
Basic example

<o-textarea-input attr="longtext" label="Long text" [data]="getData()" required="yes"></o-textarea-input>
You can see this and more examples of this component in the OntimizeWeb playground.
Validation
The o-textarea-input shows automatically an error message when the required attribute is set to “yes” and there is no value on the input.
Directive: o-textarea-input
Inherited inputs
-
from FormDataComponent:
- attr
- automatic-binding
- automatic-registering
- clear-button
- data
- enabled
- label
- read-only
- required
- sql-type
- tooltip
- tooltip-position
- tooltip-show-delay
- validators
- width
-
from o-text-input:
- max-length
- min-length
Inputs
| Name | Description | Default |
|---|---|---|
|
columns number |
Specifies the width of the text area (in average character width). HTML5 cols attribute |
20 |
|
rows number |
Specifies the height of the text area (in lines). HTML5 rows attribute |
2 |
Inherited outputs
-
from FormDataComponent:
- onChange
- onValueChange
-
from o-text-input:
- onBlur
- onFocus