templates/areas/bild-text/image.html.twig line 1

Open in your IDE?
  1. <div class="image-container {{ imageOrder }}">
  2.     {# image #}
  3.     {# {% if editmode %}
  4.         <div class="image-editmode">
  5.             {{ image|raw }}
  6.         </div>
  7.     {% elseif image.src %}
  8.         <div class="image">
  9.             {{ image.thumbnail('bildText').html({
  10.                 'alt': image.alt,
  11.                 'disableWidthHeightAttributes': true,
  12.                 'imgAttributes': {
  13.                     'width': 480,
  14.                     'height': 300,
  15.                     'loading': 'lazy'
  16.                 }
  17.             })|raw }}
  18.         </div>
  19.     {% endif %} #}
  20.     {% if image.src %}
  21.         {% if keepAspectRatio.checked %}
  22.             <div class="image-keep-aspect-ratio">
  23.                 {{ image.thumbnail('bildTextKeepAspectRatio').html({
  24.                     'alt': image.alt,
  25.                     'disableWidthHeightAttributes': true,
  26.                     'imgAttributes': {
  27.                         'width': 480,
  28.                         'height': 300,
  29.                         'loading': 'lazy'
  30.                     }
  31.                 })|raw }}
  32.             </div>
  33.         {% else %}
  34.             <div class="image">
  35.                 {{ image.thumbnail('bildText').html({
  36.                     'alt': image.alt,
  37.                     'disableWidthHeightAttributes': true,
  38.                     'imgAttributes': {
  39.                         'width': 480,
  40.                         'height': 300,
  41.                         'loading': 'lazy'
  42.                     }
  43.                 })|raw }}
  44.             </div>
  45.         {% endif %}
  46.     {% endif %}
  47. </div>