Textarea
The Textarea component allows you to easily create multi-line text inputs.
Imports
- Textarea - main textarea component
Usage
Basic usage
Auto Resize
By setting autoSize prop the textarea will increase it's size according to the content.
Resize direction
resize
prop contarints the resize direction of the textarea, It can accept 3
values both | vertical | horizontal | none
Cols and Rows
The following example show a textarea, with a set numbers of rows and columns and some default content. Notice that even when autoSize is enabled the textarea won't expand more than 5 rows.
Integrations
React Hook Form
This example shows how to integrate renderlesskit Input with react-hook-form
Formik
This example shows how to integrate renderlesskit Input with Formik
API Reference
Input
Input takes all the native HTMLTextareaElement
props plus:
Prop | Type | Default |
---|---|---|
isDisabled | Boolean | - |
isReadOnly | Boolean | - |
isInvalid | Boolean | - |
autoSize | Boolean | - |
rowsMax | number | - |
rowsMin | number | - |
cols | number | - |