Skip to content

Latest commit

 

History

History
39 lines (29 loc) · 1.24 KB

File metadata and controls

39 lines (29 loc) · 1.24 KB

Textarea

This component extends the base input with textarea-specific behavior.

Usage

<rl-textarea maxlength="" rows="" ng-disabled="" ng-model="" validator="" label="" name=""> ... </rl-textarea>

Options

maxlength

Sets the maxlength of the textbox.

rows

Sets the height of the textarea in rows.

This option will set disabled on the textarea if the expression inside it is truthy.

Example: ng-disabled="true" will output <textarea disabled> ... </textarea>

See input for detail on the base options.

Full example

A textarea with maxlength, rows, ng-disabled, and label.

<rl-textarea maxlength="20" rows="3" ng-disabled="true" label="Test" ng-model="test.text"></rl-textarea>

Output (if test.text is empty):

<textarea class="form-control" maxlength="20" rows="3" disabled ng-model="test.text" placeholder="Test"></textarea>

Output (if test.text has a value):

<label class="show-hide">Test</label>
<textarea class="form-control" maxlength="20" rows="3" disabled ng-model="test.text" placeholder="Test"></textarea>