templates/blocks/previews-from-controller/preview-article-logic.html.twig line 1

Open in your IDE?
  1. <div class="preview-container {{ type }} br8 dflex fdc{% if i == 0 %} first-preview{% endif %}{% if i == 1 %} second-preview{% endif %}">
  2.     <div class="preview-header">
  3.         {% if img is defined and img is not empty %}
  4.             {% include "blocks/previews/img/image.html.twig" %}
  5.         {% else %}
  6.             {% include "blocks/previews/img/default-image.html.twig" %}
  7.         {% endif %}
  8.         {% if type == "analyses" %}
  9.             <div class="background-color-blue"></div>
  10.         {% elseif type == "guides_outils" %}
  11.             <div class="background-color-blue"></div>
  12.         {% endif %}
  13.         <p class="fs14 lh20 dflex aic">
  14.             {% if type == "analyses" %}
  15.                 Analyse
  16.             {% elseif type == "guides_outils" %}
  17.                 Guide / Outil
  18.             {% else %}
  19.                 Article
  20.             {% endif %}
  21.         </p>
  22.         {% if i == 0 %}
  23.             {% include "blocks/previews-from-controller/blocks/categories.html.twig" %}
  24.         {% endif %}
  25.     </div>
  26.     <div class="preview-content{% if type != "articles" %} dflex fdc{% endif %}{% if i == 0 %} pt-0p5em{% endif %}">
  27.         {% if i > 1 or i == 1 %}
  28.             {% include "blocks/previews-from-controller/blocks/categories.html.twig" %}
  29.         {% endif %}
  30.         <a href="{{ url }}" class="cblue nodeco {{ title_lines }} {% if i == 1 %} mt1p5em{% endif %}{% if type != "articles" %} reverse{% endif %}">
  31.             <div class="fw500 fs20 preview-h3 {{ title_lines }} lh28">{{ title }}</div>
  32.         </a>
  33.     </div>
  34.     <div class="mta">
  35.         <div class="mt-12px">
  36.             <div class="dflex jcsb mt-8px">
  37.                 <div class="preview-contributors">
  38.                     {% include "users/contributorAlaune.html.twig" with {contributors: hitContributors} %}
  39.                 </div>
  40.                 {% if readtime is defined and readtime is not empty %}
  41.                     <div class="cgrey fs14 lh20">{{ readtime }}
  42.                         min de lecture
  43.                     </div>
  44.                 {% endif %}
  45.             </div>
  46.         </div>
  47.         <span class="cgrey fs14 lh20">PubliĆ© le
  48.             {% if authored is defined and authored is not empty %}
  49.                 {{ authored|format_datetime('short', 'none', locale='fr') }}
  50.             {% endif %}
  51.         </span>
  52.     </div>
  53. </div>