Textarea
Basic
<Textarea></Textarea>
Controlled
<Textarea value={value} onInput={onInput}></Textarea>
Rounded
Set
rounded
to "square"
, "sm"
or "lg"
. Defaults to the value of the CSS variable --default-roundedness
. See "Default roundedness".<Stack class="gap-5">
<Textarea rounded="square"></Textarea>
<Textarea rounded="sm"></Textarea>
<Textarea rounded="lg"></Textarea>
</Stack>
Disabled
Set
disabled
to either true
or false
. Defaults to false
.<Textarea disabled></Textarea>
Readonly
Set
readonly
to either true
or false
. Defaults to false
.<Textarea readonly>Example</Textarea>
Invalid
Set
invalid
to either true
or false
. Defaults to false
.<Textarea invalid>Example</Textarea>
Props
Prop | Required | Default | Type and notes |
---|---|---|---|
rounded | - | - |
Defaults to the value of the CSS variable --default-roundedness . See "Default roundedness". |
invalid | - | false |
|
children | ✔ | - |
|
...rest | - | - |
See the docs for rest parameters. For Textarea , you could pass anything you normally would pass to <textarea> because the return value looks something like this:
|