mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-10-15 17:59:43 +00:00
18 lines
875 B
Twig
18 lines
875 B
Twig
{% if chill_main_config.top_banner is defined and chill_main_config.top_banner.text is defined %}
|
|
{% set banner_text = '' %}
|
|
{% set current_locale = app.request.locale %}
|
|
|
|
{% if chill_main_config.top_banner.text[current_locale] is defined %}
|
|
{% set banner_text = chill_main_config.top_banner.text[current_locale] %}
|
|
{% else %}
|
|
{% set banner_text = chill_main_config.top_banner.text|first %}
|
|
{% endif %}
|
|
|
|
{% if banner_text %}
|
|
<div class="top-banner w-100 text-center py-2"
|
|
style="{% if chill_main_config.top_banner.color is defined %}color: {{ chill_main_config.top_banner.color }};{% endif %}{% if chill_main_config.top_banner.background_color is defined %}background-color: {{ chill_main_config.top_banner.background_color }};{% endif %}">
|
|
{{ banner_text }}
|
|
</div>
|
|
{% endif %}
|
|
{% endif %}
|