Usage
TextArea captures multi-line user text: resolution notes, incident summaries, free-text searches that accept line breaks, configuration blobs operators paste, supervisor feedback. It supports labels, helper and error text, optional character counts, and auto-resize within bounds. The mental model is "type freely, but stay within the stated limits". Choose it when line breaks matter or when the expected length can't fit in a single-line field without scrolling.
Shared with the call taker during dispute review.
Input.| Aspect | Purpose | Emphasis |
|---|---|---|
| Auto-resize | Grows with content | Set minRows and maxRows to prevent runaway height |
| Fixed rows | Stable layout | Use when alignment with neighbor fields matters |
| Vertical resize handle | User-controlled height | Only when the layout tolerates variable height |
| Character counter | Enforces limits | Show when the limit is tight or legally required |
formatMessage; some languages need more vertical space—test auto-resize caps with the longest expected translation.Input semantics—explain the disabled state in helper text when it isn't obvious.Do
maxLength with a visible counter when operators commonly hit the cap. Surprise failures on submit feel broken.maxRows so dialogs and drawers still scroll predictably.Don't
CoreText or a code viewer.Label associates with the control's id; aria-describedby references helper and error regions; required and invalid states are exposed; counter updates use polite live regions only when useful. See Accessibility for the full contract.