{# This component outputs a semantic headline.

headline

Mandatory variables: @var string text Optional variables: @var string tag_name @var \Contao\CoreBundle\String\HtmlAttributes attributes Note: You can either group all variables in an object named "headline" or all directly in the context. Grouping under an object has precedence. #} {% block headline_component %} {% set headline = headline|default(_context) %} {% set tag_name = headline.tag_name|default('h1') %} <{{ tag_name }}{% block headline_attributes %}{{ headline.attributes|default }}{% endblock %}> {%- block headline_inner -%} {%- if as_editor_view -%} {{ headline.text }} {%- else -%} {%- if (data.subline) and (data.subheadline is not same as('1')) -%} {{ data.subline }} {%- if data.headline_inline is same as('1') -%}{{ ' ' }}{%- endif -%} {%- endif -%} {%- if data.subline -%}{%- endif -%} {{ headline.text|insert_tag_raw }} {%- if data.subline -%}{%- endif -%} {%- if data.subheadline -%} {{ data.subline }} {%- endif -%} {%- endif -%} {%- endblock -%} {% endblock %}