TextArea
TextArea is the multi-line counterpart to Input. It shares the same Field-context wiring and adds
a rows prop plus a vertical resize handle.
What it is
A bordered <textarea> that forwards its ref. The Field-context behaviour matches Input — field
id, aria-describedby, invalid and disabled state, all read from context. TextArea is resizable
vertically by default; the rows prop sets the initial height.
Install
TextArea is exported from usemotif. No separate install.
API
TextArea
stableconst TextArea: ForwardRefExoticComponent<TextAreaProps & RefAttributes<HTMLTextAreaElement>>
Initial visible row count. The control stays resizable vertically past this height.
Marks the control invalid. Falls back to the Field context value when omitted.
Inline style merged on top of the bordered-surface defaults.
Every standard textarea attribute except `size`. `placeholder`, `value`, `onChange`, `maxLength`, and the rest pass through.
Accessibility
TextArea's accessibility contract is Input's: inside a Field it claims the field id, names its
help and error text, and mirrors the invalid and required state. The same standalone caveat
applies — outside a Field, wire id and aria-describedby yourself.
Examples
Inside a Field:
Controlled standalone: