New to Kendo UI for AngularStart a free 30-day trial

Represents the Kendo UI TextArea component for Angular.

Use this component to let users enter and edit multi-line text.

Definition

Package:@progress/kendo-angular-inputs

Selector:kendo-textarea

Export Name:Accessible in templates as #kendoTextAreaInstance="kendoTextArea"

Syntax:

html
<kendo-textarea [(ngModel)]="value" [rows]="5" [cols]="30"></kendo-textarea>

Inputs

Specifies the orientation of the TextArea adornments. Use this property to set the position of adornments relative to each other.

cols

number

Sets the visible width of the text area in average character width.

disabled

boolean

Sets the disabled state of the TextArea component. To learn how to disable the component in reactive forms, refer to the article on Forms Support.

Default:

false

Sets the background and border styles of the TextArea (see example). The default value is set by the Kendo theme.

Specifies the flow direction of the TextArea sections. Use this property to set the position of adornments relative to the text area.

inputAttributes

{ [key: string]: string }

Sets the HTML attributes of the inner focusable input element. Some attributes are required for component functionality and cannot be changed.

maxlength

number

Sets the maximum number of characters allowed in the text area.

The hint, which is displayed when the Textarea is empty.

readonly

boolean

Sets the read-only state of the TextArea component.

Default:

false

Sets the resize behavior of the TextArea.

Default:

'vertical'

Sets the border radius of the TextArea (see example). The default value is set by the Kendo theme.

rows

number

Sets the visible height of the text area in lines.

Determines whether the whole value will be selected when the TextArea is clicked. Defaults to false.

Default:

false

Shows the prefix separator in the TextArea. The separator is rendered only if a prefix template is declared.

Default:

false

Shows the suffix separator in the TextArea. The separator is rendered only if a suffix template is declared.

Default:

false

Sets the size of the TextArea. Controls the padding of the text area element (see example). The default value is set by the Kendo theme.

tabindex

number

Sets the tabindex of the component.

Default:

0

title

string

Sets the title attribute of the internal textarea input element of the component.

value

string

Provides a value for the TextArea component.

Fields

Represents the visible textarea element of the component.

Events

Fires when the TextArea gets blurred.

Use the onBlur property to subscribe to this event.

Fires when the TextArea is focused.

Use the onFocus property to subscribe to this event.

Fires each time the internal textarea element gets blurred. This event is useful when adornments are used, in order to distinguish between blurring the textarea element and blurring the whole TextArea component.

Fires each time the user focuses the internal textarea element of the component. This event is useful when you need to distinguish between focusing the textarea element and focusing one of its adornments.

Fires when the value changes or the TextArea is blurred (see example).

The event does not fire when the value changes programmatically or through form control binding.

Methods

Blurs the TextArea.

Focuses the TextArea.