Textarea

A label, a multi-line input, and an optional hint and error — the same `field-*` shell as the text field, so a long-form field is the same control with a different box.

Examples

Label and control

The name is given once; the id, the label's `for` and the error region's id are derived from it.

Where the data came from, or how it was produced.

Height

`rows` sets the visible height. The control is vertically resizable and does not grow as the text does — a field that grows while someone types moves everything below it.

Holding a value

A textarea's value is element content, not a `value` attribute — a `value="…"` here is silently ignored and the field renders empty. Line breaks and leading blank lines survive the round trip.

Rejected, with the reason

`error` sets `aria-invalid` and the description together, and keeps the hint rather than replacing it.

At least one language.

Enter a description before submitting.

Capped length

`maxlength` is an affordance: browsers enforce it on typing but not on every paste, and never on a request that did not come from the form, so the server still checks.

One line for cards and listings. Up to 200 characters.