Textarea
A multi-line text input for longer form content.
A textarea component for multi-line text input.
Default
Default
With Value
States
Disabled
Read Only
With Label
Message
Usage
import { Textarea, Label } from "@delphi/ui";
export function Example() {
return (
<div className="space-y-2">
<Label htmlFor="bio">Bio</Label>
<Textarea id="bio" placeholder="Tell us about yourself" />
</div>
);
}API Reference
| Prop | Type | Default | Description |
|---|---|---|---|
placeholder | string | - | Placeholder text |
disabled | boolean | false | Disables the textarea |
readOnly | boolean | false | Makes the textarea read-only |
rows | number | - | Number of visible rows |
maxLength | number | - | Maximum character limit |
Use textareas for multi-line input (bios, descriptions, messages)
Always associate with a Label using
htmlFor and idShow character count when there's a
maxLengthProvide helpful placeholder text that describes expected input
Allow vertical resizing for user comfort
Use textareas for single-line input — use Input instead
Set a tiny height that requires constant scrolling
Disable horizontal resizing without good reason
Use placeholder as a substitute for labels