Documentation Index
Fetch the complete documentation index at: https://mintlify.com/rijvi-mahmud/shaddy/llms.txt
Use this file to discover all available pages before exploring further.
TextAreaField wraps shadcn/ui’s Textarea (or an auto-resizing variant) inside ShaddyForm’s form context, providing a fully integrated multiline text input. It supports the same icon, action-button, and loading-spinner patterns as TextField, plus two textarea-specific options: resizable to control manual resizing and autoResize to make the textarea grow with its content.
Installation
Install all ShaddyForm fields at once with theshaddy-form registry item:
Usage
Props
The field name. Must match a key in your Zod schema passed to
ShaddyForm.Label text rendered above the textarea. Omit to hide the label.
Placeholder text shown inside the textarea when it is empty.
When
true, appends a red asterisk to the label as a visual indicator.When
true, the user can manually resize the textarea by dragging its bottom-right corner. Defaults to false (resize is disabled via resize-none).When
true, switches to the AutosizeTextarea component which automatically expands the textarea height as the user types. Use minHeight and maxHeight to constrain the range.Minimum height in pixels for the auto-resizing textarea. Only applies when
autoResize is true.Maximum height in pixels for the auto-resizing textarea. Once reached, the textarea becomes scrollable. Only applies when
autoResize is true.Callback fired when the action button on the right is clicked. When provided, a ghost button appears in the top-right corner of the textarea using the
Icon prop (or a default ✕ icon).An icon node used as the content of the action button (when
action is set) or rendered as a static overlay icon otherwise.When
true, shows an animated LoadingSpinner on the right side of the textarea.Additional CSS classes applied to the outermost
FormItem wrapper.Additional CSS classes applied directly to the
<Textarea> element.Additional CSS classes applied to the icon container or action button.
Notes
TextAreaFieldmust be rendered inside a<ShaddyForm>— it readscontrolfromuseFormContextinternally.autoResizeandresizablecan be combined butautoResizetakes precedence over the textarea component used.- Validation messages are rendered automatically below the textarea via shadcn/ui’s
<FormMessage>.