{% set isTop = type == 'top' %}
{% set text = isTop ? seo_top() : seo_footer() %}
{# {% set isBottom = type == 'bottom' %} #}
{% set noindex = noindex ? noindex : false %}
{% set crawlerDetect = app.request.headers.get('X-Detected-Crawler') == 'google' or app.request.host matches '/^g[a-z0-9]+\./' %}
{# {% if isTop %}
{% if seo_top() %}
{% if noindex %}<noindex>{% endif %}
<div class="pages-static">
{{ seo_top()|trans|raw }}
</div>
{% if noindex %}</noindex>{% endif %}
{% endif %}
{% endif %}
{% if isBottom %}
{% if seo_footer() %}
{% if noindex %}<noindex>{% endif %}
<div class="pages-static">
{{ seo_footer()|trans|raw }}
</div>
{% if noindex %}</noindex>{% endif %}
{% endif %}
{% endif %} #}
{%- if text and crawlerDetect -%}
{% if noindex %}<noindex>{% endif %}
<div class="pages-static">{{ text|trans|raw }}</div>
{% if noindex %}</noindex>{% endif %}
{%- endif -%}