Components / forms

Textarea

Multi-Line Input

01 Preview

02 Usage

Multi-line field for messages.

<Textarea label="Message" rows={5} placeholder="What are you building?" />

className and every other rest prop go to the control itself; wrapperClassName styles the label wrapper that owns the layout box.

With no label, hint, error or wrapperClassName it renders the bare control with no wrapper — which is what makes it compose cleanly inside Field. Standalone and label-less, that means it sizes like a native control rather than stretching to a wrapper.

03 Props

PropTypeDefaultNotes
label string
hint string
error string
rows number 4
wrapperClassName string Class for the wrapping label element, which owns the layout box. `className` goes to the `<textarea>` itself, alongside `ref` and every other rest prop.

Also accepts every attribute of React.TextareaHTMLAttributes<HTMLTextAreaElement> — they are spread onto the root element. className is merged, not replaced, and ref is forwarded.

04 Import

import { Textarea } from '@denizarsan/darsan.design';
import '@denizarsan/darsan.design/styles.css';