Components
- Accordion
- Action BarUpdated
- Alert Dialog
- Alert
- Announcement
- Aspect Ratio
- Autocomplete
- Avatar
- BadgeUpdated
- Bottom Navigation
- Breadcrumb
- Button Group
- Button
- CalendarUpdated
- CardUpdated
- Carousel
- Chart
- Checkbox
- Circular Progress
- Circular Slider
- Clipboard
- Collapsible
- Color Picker
- Combobox
- Command
- Context MenuUpdated
- Data List
- Date Picker
- DialogUpdated
- DrawerUpdated
- Editable
- FieldUpdated
- File Upload
- Float
- Floating Panel
- Frame
- Hint
- Hover Card
- Image Cropper
- Input Group
- Input OTP
- Input
- Item
- Kbd
- Link Overlay
- Listbox
- MarqueeUpdated
- Menu
- Native Select
- Number InputUpdated
- Pagination
- Popover
- Progress
- Prose
- QR Code
- Radio Group
- Rating
- Resizable
- Scroll Area
- Segment Group
- Select
- Separator
- Sheet
- Sidebar
- Signature Pad
- Skeleton
- Skip Nav
- Slider
- Spinner
- Status
- Steps
- Switch
- TableUpdated
- Tabs
- Textarea
- TimerUpdated
- ToastUpdated
- Toggle Group
- Toggle Tooltip
- Toggle
- Tooltip
- Tour
- Tree View
Hooks
Installation#
pnpm dlx shadcn@latest add @shark/textarea
Usage#
import { Textarea } from "@/components/ui/textarea";
<Textarea />
Controlled#
Control the value with value and onChange.
Character count: 0
States#
Disabled#
Disable the textarea with the disabled prop. Use Field with disabled to disable the whole field (label + textarea).
Invalid#
Use the invalid prop on Field or Textarea to show invalid state.
Please provide at least 20 characters.
Examples#
Autoresize#
Use autoresize to make the textarea grow with content.
With Field#
Wrap the textarea in a Field and add FieldLabel and FieldDescription.
Add a short message to include with your submission.
With Input Group#
Use FieldGroup to group multiple Field blocks. Combine textarea with other inputs and action buttons.
script.js
Form Integration#
API Reference#
Textarea#
Multi-line text input. Accepts all native textarea attributes.
| Prop | Type | Default |
|---|---|---|
autoresize | boolean | true |
className | string | - |
For a complete list of props, see the Ark UI documentation.