custom/plugins/EWHeaderFooter/src/Resources/views/storefront/base.html.twig line 1

Open in your IDE?
  1. {% sw_extends '@Storefront/storefront/base.html.twig' %}
  2. {% block base_header %}
  3.     {% set currentCategory = page.header.navigation.active %}
  4.     {% set hideHeader = false %}
  5.     {% for k,v in currentCategory.customFields %}
  6.         {% if (k === "ew-hide-header") %}
  7.             {% set hideHeader = v %}
  8.         {% endif %}
  9.     {% endfor %}
  10.     {%  if hideHeader === true %}
  11.         {# hide navigation #}
  12.     {% else %}
  13.         {{ parent() }}
  14.     {% endif %}
  15. {% endblock %}
  16. {% block base_navigation %}
  17.     <div class="nav-main">
  18.         {% set currentCategory = page.header.navigation.active %}
  19.         {% set hideHeader = false %}
  20.         {% for k,v in currentCategory.customFields %}
  21.             {% if (k === "ew-hide-header") %}
  22.                 {% set hideHeader = v %}
  23.             {% endif %}
  24.         {% endfor %}
  25.         {%  if hideHeader === true %}
  26.             {# hide navigation #}
  27.         {% else %}
  28.             {{ parent() }}
  29.         {% endif %}
  30.     </div>
  31. {% endblock %}
  32. {% block base_footer %}
  33.     {% set currentCategory = page.header.navigation.active %}
  34.     {% set minimalFooter = false %}
  35.     {% for k,v in currentCategory.customFields %}
  36.         {% if (k === "ew-minimal-footer") %}
  37.             {% set minimalFooter = v %}
  38.         {% endif %}
  39.     {% endfor %}
  40.     {%  if minimalFooter === true %}
  41.          <footer class="footer-main">
  42.             {% block base_footer_inner %}
  43.                 {% sw_include '@Storefront/storefront/layout/footer/footer.html.twig' %}
  44.             {% endblock %}
  45.         </footer>
  46.     {% else %}        
  47.         {# Default block #}
  48.         {{ parent() }}
  49.         {# ThemeWare: "Slideout-Communities" zum Footer hinzufügen. #}
  50.         {# TODO: Add configuration #}
  51.         {% if twtSlideoutCommunitiesShow == 2 %}
  52.             {% sw_include '@Storefront/storefront/themeware/extensions/twt-slideout-communities.html.twig' ignore missing %}
  53.         {% endif %}
  54.         {# ThemeWare: "Floating-Widget" zum Footer hinzufügen. #}
  55.         {% if twtFloatingWidgetShow == 2 %}
  56.             {% sw_include '@Storefront/storefront/themeware/extensions/twt-floating-widget.html.twig' ignore missing with {
  57.                 open: twtFloatingWidgetShowOpened,
  58.                 animation: twtFloatingWidgetAnimation,
  59.                 backdrop: twtFloatingWidgetBackdrop
  60.             } %}
  61.         {% endif %}
  62.     {% endif %}
  63. {% endblock %}