templates/new/Element/video_card.html.twig line 1

Open in your IDE?
  1. {% if publication.videoLink %}
  2.     <div class="card-new mt50 mob-mt-15" itemscope itemtype="https://schema.org/Article" >
  3.         {% if publication.created  | date('Ymd')  <= 20221101 %}
  4.             <a data-fancybox
  5.                data-type="video"
  6.                href="{{  publication.videoLink | raw }}"><img itemprop="image" src="{{ publication.image }}" style="max-width: 100%" alt="{{ publication.imageAlt | raw }}"></a>
  7.         {% else %}
  8.             <a data-fancybox
  9.                data-type="video"
  10.                href="{{  publication.videoLink | raw }}"><img itemprop="image" src="{{ vich_uploader_asset(publication, 'imageFile') }}" style="max-width: 100%" alt="{{ publication.imageAlt | raw }}"></a>
  11.         {% endif %}
  12. {#        <div class="new-date">{{ publication.created | date('d.m.Y') }}</div>#}
  13.         <div class="new-title mt15 card-content"  itemprop="name">
  14.             {{ publication.title }}
  15.         </div>
  16.     </div>
  17. {% else %}
  18.     <div class="card-new mt50 mob-mt-15" onclick="window.location.href='{{ publication.link }}'">
  19.         {% if publication.created  | date('Ymd')  <= 20221101 %}
  20.             <a itemprop="url" href="{{ publication.link }}" target="_blank"><img itemprop="image" src="{{ publication.image }}" alt="{{ publication.imageAlt | raw }}" style="max-width: 100%"></a>
  21.         {% else %}
  22.             <a itemprop="url" href="{{ publication.link }}" target="_blank"><img itemprop="image" src="{{ vich_uploader_asset(publication, 'imageFile') }}" alt="{{ publication.imageAlt | raw }}" style="max-width: 100%"></a>
  23.         {% endif %}
  24. {#        <div class="new-date">{{ publication.created | date('d.m.Y') }}</div>#}
  25.         <div class="new-title mt15 card-content" itemprop="name" >
  26.             {{ publication.title }}
  27.         </div>
  28.     </div>
  29. {% endif %}