templates/Form/Includes/text-area.html.twig line 1

Open in your IDE?
  1. {% set errors = errors | default([]) %}
  2. <div class="text-area form-group {{ (errors | length > 0) ? 'has-error': '' }} {{ styleModifier|default('') }}">
  3.     <div class="{{ inputWrapperModifier|default('') }}">
  4.         {{ include('Form/Includes/form-control-label.html.twig', _context) }}
  5.         <textarea
  6.             name="{{ name }}"
  7.             id="{{ id }}"
  8.             class="form-control {{ (errors | length > 0 )? 'is-invalid': '' }} {{ inputModifier|default('') }}"
  9.             rows="{{ rows|default(0) ? rows : '8' }}"
  10.             placeholder="{{ placeholder|default('') }}"
  11.         {{ required|default(false) ? 'required' : '' }}
  12.         {{ disabled|default(false) ? 'disabled' : '' }}
  13.         {{ readonly|default(false) ? 'readonly' : '' }}
  14.         {{ helpText | default(null) ? 'aria-describedby="' ~ id ~'-help-block"' : '' }}
  15.         {% for key, value in inputAttributes | default([]) %}
  16.             {{key}}="{{value}}"
  17.         {% endfor %}
  18.         >{{ value|default('') }}</textarea>
  19.     </div>
  20.     {{ include('Form/Includes/form-errors.html.twig', _context) }}
  21.     {{ include('Form/Includes/form-control-help-text.html.twig', _context) }}
  22. </div>