{# Der Titel fuer die Suche, sonst der Titel der Seite. #} {% set seoTitle = page.seo_title|default('') ?: page.document.title %} {{ seoTitle }} {% if page.robots|default('index') != 'index' %}{% endif %} {# In der Vorschau des Editors gibt es den Websitenamen nicht - dort fehlt das Feld einfach. #} {% if page.website_name|default('') %}{% endif %} {% if socialImage|default(null) %} {% if socialImage.alt %}{% endif %} {% else %} {# Ohne Bild ist die große Karte eine leere Fläche; die kleine zeigt Titel und Text. #} {% endif %} {% include 'favicon.html.twig' %} {# Ein Bündel statt vier Dateien: jede einzelne hält das Zeichnen der Seite auf. Fehlt es (kein Schreibrecht im Ordner), werden die Quellen einzeln geladen - langsamer, aber heil. #} {# Das grosse Bild ueber der Falz, wenn es der Hintergrund des ersten Abschnitts ist: Es steht sonst nur im Stylesheet und wird erst gefunden, wenn das geparst ist. Genau eine der drei Abfragen trifft zu - und zwar auf dieselbe Variante, die auch die Regel nimmt. #} {% for bild in heroBackground|default([]) %} {% endfor %} {% if styleBundle|default(null) %} {% else %} {% if localFonts|default([]) %}{% endif %} {% if page.document.schemaVersion >= 2 %}{% endif %} {% if page.document.schemaVersion >= 3 %}{% endif %} {% endif %} {% if localFonts|default([]) %} {# Die wichtigsten Schnitte vorab, damit die erste Zeile in der richtigen Schrift steht. #} {% for font in localFonts %}{% endfor %} {% elseif googleFonts|default(null) %}{% endif %} {% if hasPosts|default(false) %} {% endif %} {% if needsTabs|default(false) %}{% endif %} {% if needsSlider|default(false) %}{% endif %} {% if needsMotion|default(false) %}{% endif %} {% if needsZoom|default(false) %}{% endif %} {# Own scripts of this page, as a file. Never rendered in the editor preview: the preview must show the layout, not run code that could change the page under the editor's hands. #} {% if pageScript|default(null) and not editing|default(false) %}{% endif %} {# A data block, not a script: CSP script-src does not apply to application/ld+json. #} {% for block in structuredData|default([]) %} {% endfor %} {% if pageStyles|default('') %} {# In the editor the preview inherits the administration's policy, which forbids inline styles. The stylesheet therefore travels as inert template text and the editor applies it as a constructed stylesheet – same result, no policy violation and a clean console. #} {% if editing|default(false) %} {% else %}{% endif %} {% endif %} {% set consentOpen = not editing|default(false) and consentGate.needsBanner(app.request) %} {# Header and footer are block documents like any page, so they are built from elements instead of being written into this template. #} {% if areas.header|default(null) %}
{% for block in areas.header.blocks %}{% include 'blocks/block.html.twig' with {block: block, editing: editing|default(false), postLists: {}, forms: {}, breadcrumbs: [], navigation: navigation|default({}), sections: sections|default({}), richText: areas.header.schemaVersion|default(1) >= 12, richHeadings: areas.header.schemaVersion|default(1) >= 17, eagerImage: eagerImage|default(null), inHeader: true} only %}{% endfor %}
{% endif %}
{% if postMeta is defined and postMeta is not null and siteSettings.load().postMetaHeader %}

{% if page.published_at %}{% endif %} {% if page.author %}von {{ page.author }}{% endif %} {% for term in postMeta.category %}{{ term.name }}{% endfor %} {% for term in postMeta.tag %}{% endfor %}

{% endif %} {% for block in page.document.blocks %}{% include 'blocks/block.html.twig' with {block: block, editing: editing|default(false), postLists: postLists|default({}), forms: forms|default({}), breadcrumbs: breadcrumbs|default([]), navigation: navigation|default({}), sections: sections|default({}), richText: page.document.schemaVersion|default(1) >= 12, richHeadings: page.document.schemaVersion|default(1) >= 17, neighbours: neighbours|default({}), eagerImage: eagerImage|default(null)} only %}{% endfor %}
{% if areas.footer|default(null) %} {% endif %} {# Privacy statement, imprint and the way back to the consent decision. All three have to be reachable from every page, so they are part of the template and not of the footer area, which someone could delete. One labelled landmark, so they are not loose text either. #} {% set legal = consentGate.legalLinks() %} {% set revocable = not editing|default(false) and consentGate.askedGroups is not empty and not consentGate.needsBanner(app.request) %} {# Nur, wenn die Seite die Zeile nicht selbst enthaelt: sonst stuende sie zweimal da. #} {% if (legal is not empty or revocable) and not hasLegalBlock|default(false) %} {% endif %} {% set oben = siteSettings.load() %} {% if oben.scrollTop|default(false) and not editing|default(false) %} {# Ein Anker, kein Skript. Er springt an den Anfang - das kann ein Browser allein. #} {% endif %} {% if not editing|default(false) and consentGate.needsBanner(app.request) %} {% include 'consent-banner.html.twig' with {consent: consentGate.state(app.request), back: app.request.pathInfo} only %} {% endif %}