templates/front/widgets/instagram.html.twig line 1

Open in your IDE?
  1. {% if instagram|length > 0  %}
  2.     <section class="instagram">
  3.         <div class="instagram__title">
  4.             <h2 class="text text--divider text--divider--center text--h1">{{ '#jihoceskejerky'|trans }}</h2>
  5.         </div>
  6.         <div class="instagram__content">
  7.             <div class="container">
  8.                 <div class="instagram__row">
  9.                     {% for tag in instagram %}
  10.                         {% if tag['link'] is not empty %}
  11.                             <a href="{{ tag['link']|default }}" class="instagram__item" target="_blank"
  12.                                style="background-image: url({{ tag['type']=='VIDEO'?tag['thumb']:tag['url'] }})">
  13.                                 <img src="{{ tag['type']=='VIDEO'?tag['thumb']:tag['url'] }}" alt="{{ tag['type'] }}">
  14.                                 <p class="instagram__text">{{ tag['text']|default }}</p>
  15.                             </a>
  16.                         {% endif %}
  17.                     {% endfor %}
  18.                 </div>
  19.             </div>
  20.         </div>
  21.     </section>
  22. {% endif %}