templates/includes/blocks/story-hero.html.twig line 1
<div class="story-hero pt-hero {% if content.inverted %} story-hero--inverted {% endif %}" x-data="storyhero">
<div class="story-hero__background"></div>
<div class="story-hero__container">
{% if content.storyHeroPagina %}
{% if content.storyHeroSeoHeadlinePagina %}<{{ content.storyHeroSeoHeadlinePagina }}>{% endif %}
<div {% if content.inverted %} style="color: #fff;" {% endif %}
class="pagina">
{{ content.storyHeroPagina }}
</div>
{% if content.storyHeroSeoHeadlinePagina %}</{{ content.storyHeroSeoHeadlinePagina }}>{% endif %}
{% endif %}
{% if content.title %}
<{{ content.storyHeroSeoHeadlineTitle ? content.storyHeroSeoHeadlineTitle : 'h1' }} class="story-hero__title {% if content.storyHeroTitleMobile %}desktop-only {% endif %}" x-ref="title">
{{ content.title|raw }}
</{{ content.storyHeroSeoHeadlineTitle ? content.storyHeroSeoHeadlineTitle : 'h1' }}>
{% if content.storyHeroTitleMobile %}
<{{ content.storyHeroSeoHeadlineTitle ? content.storyHeroSeoHeadlineTitle : 'h1' }} class="story-hero__title mobile-only" x-ref="mobiletitle">
{{ content.storyHeroTitleMobile|raw }}
</{{ content.storyHeroSeoHeadlineTitle ? content.storyHeroSeoHeadlineTitle : 'h1' }}>
{% endif %}
{% endif %}
{% if content.text %}
<{{ content.storyHeroSeoHeadlineText ? content.storyHeroSeoHeadlineText : 'div' }} class="story-hero__text" x-ref="text">
{{ content.text|raw }}
</{{ content.storyHeroSeoHeadlineText ? content.storyHeroSeoHeadlineText : 'div' }}>
{% endif %}
{% if content.date %}
<div class="story-hero__date" x-ref="date">
{{ content.date|date("d. F Y") }}
</div>
{% endif %}
</div>
{% if content.storyHeroAuthor %}
<div class="story-hero__author" x-ref="author">
<div class="story-hero-author">
{% if content.storyHeroAuthor.avatar %}
{% set storyHeroAuthorImage = sulu_resolve_media(content.storyHeroAuthor.avatar, app.request.locale) %}
<div class="story-hero-author__media">
<img src ="{{ storyHeroAuthorImage|thumbnailUrl('320x') }}"
alt="{{ storyHeroAuthorImage.description|striptags }}" class="story-hero-author__image">
</div>
{% endif %}
<div class="story-hero-author__name">
{{ content.storyHeroAuthor.firstName }} {{ content.storyHeroAuthor.lastName }}
</div>
{% if content.storyHeroAuthor.title %}
<div class="story-hero-author__title">
{{ content.storyHeroAuthor.title }}
</div>
{% endif %}
</div>
</div>
{% endif %}
{% if content.image %}
<div class="story-hero__media">
<img class="story-hero__image" src ="{{ content.image|thumbnailUrl('2880x') }}"
srcset ="{{ content.image|thumbnailUrl('320x') }} 320w, {{ content.image|thumbnailUrl('640x') }} 640w, {{ content.image|thumbnailUrl('720x') }} 720w, {{ content.image|thumbnailUrl('1280x') }} 1280w, {{ content.image|thumbnailUrl('1440x') }} 1440w, {{ content.image|thumbnailUrl('2048x') }} 2048w"
alt="{{ content.storyHeroImageALT|default(content.image.description|striptags) }}" x-ref="image">
</div>
{% endif %}
</div>