Textarea Element
Renders a textarea input.
#Examples
<script>
export default {
mixins: [Laraform],
data: () => ({
schema: {
textarea: {
type: 'textarea'
}
}
})
}
</script>
<script>
export default {
mixins: [Laraform],
data: () => ({
schema: {
textarea: {
type: 'textarea',
autogrow: false,
rows: 5
}
}
})
}
</script>
#Options
Name | Type | Description |
---|---|---|
autogrow | boolean |
Whether the textarea should grow automatically as user inserts new lines. |
rows | number |
Initial number of rows of the textarea. |
default | string |
Value of element when the form is initially loaded or reseted. |
placeholder | string |
The placeholder of the element. |
floating | string |
The floating label of the element. |
disabled | boolean |
Whether the field is disabled. |
readonly | boolean |
Whether the field is readonly. |
#Properties
Name | Type | Default | Description |
---|---|---|---|
disabled | boolean |
false |
Whether the field is disabled. |
autogrow | boolean |
true |
Whether the textarea should grow automatically as user inserts new lines. |
rows | number |
3 |
Initial number of rows of the textarea. |
defaultValue | string |
null |
Value of element when the form is initially loaded or reseted. |
placeholder | string |
null |
The placeholder of the element. |
floating | string |
null |
The floating label of the element. |
readonly | boolean |
false |
Whether the form element is readonly. |
#Methods
# .reset()
Resets the element to it's default state.
# .disable()
Disabled the field.
# .enable()
Enables the field.
# .autosize()
Forces the recalculation of textarea rows.