Preview

Installation

<> import.ts
import { TextArea } from "@/components/ui/textarea"

Code

<> component.tsx
import { Textarea } from "@/components/ui/textarea"

<Textarea />

API Reference

TextArea

Textarea with optional label and submit button.

<> import.ts
import { TextArea } from "@/components/ui/textarea"

Props

PropTypeDefaultDescription
label
string—Field label when isLabel is true
placeholder
string"Enter your message..."Placeholder text
isLabel
booleanfalseShow label
isWithButton
booleanfalseShow submit button below
className
string""Additional CSS classes
value
string—Controlled value
onChange
(e: React.ChangeEvent<HTMLTextAreaElement>) => void—Change handler
onButtonClick
() => void—Button click handler
buttonText
string"Submit"Button label
disabled
booleanfalseDisable input
rows
number4Number of rows
maxLength
number—Max character length