City of Ghent Style Guide

Textarea

When to use this component

Use the textarea component to let users enter text that is longer than a single line.

When not to use this component

Do not use the textarea component to let users enter:

  • Text or a value that is not longer than a single line
  • A date
  • A time
  • A number
  • A password
  • An email
  • A telephone number

In these cases, use input component instead.

Usage, behavior, layout and validation

The textarea component is a form element that should always be used in a form. For a description of the usage, the behavior, the layout and validation of form elements, see the form component documentation.

{% include '@form-item' with _context %}
<div class="form-item ">
    <label for="textarea--disabled">Textarea
    </label>

    <div class="form-columns">
        <div class="form-item-column">
            <textarea name="textarea--disabled" id="textarea--disabled" disabled="disabled">
</textarea>
        </div>
        <div class="form-item-column"></div>
    </div>
</div>
{
  "id": "textarea--disabled",
  "input_component": "input-textarea",
  "label": "Textarea",
  "disabled": true
}