{% extends "@Contao/content_element/text.html.twig" %} {% block wrapper %} {# Wrapper element around headline and content #} {% set myFigure = figure(data.backgroundimage,['proportional']) %}
<{% block wrapper_tag %}div{% endblock %}{% block attributes %}{{ attributes }}{% endblock %} style="background-image: url('{{myFigure.image.getImageSrc()}}')"> {%- block inner %} {% if headline.text %} {{ block('headline_component') }} {% endif %} {% block content %} {% set text_attributes = attrs() .addClass('rte') .mergeWith(text_attributes|default) %} {{text|csp_inline_styles|insert_tag_raw|encode_email|raw }} {% set currentPath = insert_tag('link_url::' ~data.jumpto) %} {{data.jumptotext}}
{% if image %} {% with {figure: image} %}{{ block('figure_component') }}{% endwith %} {% endif %} {% endblock %} {% endblock -%} {% endblock %}