src/Package/Openform/Front/Templates/_includes/_header.html.twig line 1

Open in your IDE?
  1. {% from '@openform_front_templates/_includes/_icons.html.twig' import logo, arrowshow, search, share, accessibility, facebooknav, instagramnav, youtubenav, magnification, contrast, reduction %}
  2. <header class="js-header">
  3.     <div class="header">
  4.     {# klasa: variant #}
  5.         <div class="header__wrapper js-menu {{ openform_front_util.Config.menuVariant == 1 ? 'variant' : '' }}" data-height="90"> 
  6.             
  7.             <a class="header__logo-link" href="{{ toolkit_route_localizer.generate('index', {}, app.request.locale) }}">
  8.                 {# {{ logo('MAIN_PAGE_TITLE'|trans({}, 'openform_front', app.request.locale)) }} #}
  9.                 {% if openform_front_util.config.headerLogoPath is defined and openform_front_util.config.headerLogoPath %}
  10.                     <img src="{{openform_front_util.config.headerLogoPath}}" alt="logo" class="js-logo">
  11.                 {% endif %}
  12.                 
  13.             </a>
  14.             {% include '@openform_front_templates/_includes/_main-menu.html.twig' with {class: openform_front_util.Config.menuVariant == 1 ? 'variant' : '', style: style is defined and style ? style : ''}  %}
  15.             
  16.             <div class="header__container">
  17.             {# klasa: variant #}
  18.                 
  19.                 {# <div class="header__language-switcher language-switcher">
  20.                     <button class="language-switcher__button" type="button" data-expanded="js-language-switcher" aria-expanded="false">
  21.                         <span>{{ app.request.locale }}</span>
  22.                         {{ arrowdown('CHANGE_LANGUAGE'|trans({}, 'openform_front', app.request.locale)) }}
  23.                     </button>
  24.                     <div class="language-switcher__list js-language-switcher">
  25.                         {% for lang in translator_locale_list|split('|') %}
  26.                             {% if langLinks is defined and langLinks[lang] is defined %}
  27.                                 {% set href = langLinks[lang] %}
  28.                             {% elseif lang == 'pl' %}
  29.                                 {% set href = toolkit_route_localizer.generate('index',{}, lang) %}
  30.                             {% else %}
  31.                                 {% set href = toolkit_route_localizer.generate('index',{ locale : lang }, lang) %}
  32.                             {% endif %}
  33.                             <a class="language-switcher__item" {% if lang == app.request.locale %}disabled="disabled"{% endif %}href="{{ href }}">
  34.                                 {{ lang }}
  35.                             </a>
  36.                         {% endfor %}
  37.                     </div>
  38.                 </div> #}
  39.                 {# <button 
  40.                     class="header__menu-button" 
  41.                     type="button" 
  42.                     aria-expanded="false" 
  43.                     data-dialog="js-main-menu" 
  44.                     data-dialogtimeout="1500" 
  45.                     aria-label="{{ 'OPEN_MAIN_MENU'|trans({}, 'openform_front', app.request.locale) }}"
  46.                 >
  47.                     <span></span>
  48.                     <span></span>
  49.                     <span></span>
  50.                 </button> #}
  51.                         
  52.                 <div class="header__buttons">
  53.                     <button class="header__buttons__button header__buttons__menu" type="button" data-expanded="js-links" aria-expanded="false">
  54.                         <div class="header__buttons__burger"></div>
  55.                     </button>
  56.                     <button 
  57.                             class="header__buttons__button header__buttons__search" 
  58.                             type="button" 
  59.                             aria-expanded="false" 
  60.                             data-dialog="js-header-search" 
  61.                             data-dialogtimeout="1500" 
  62.                         >
  63.                             {{ search('T_SEARCH_ON_THE_SITE'|trans({}, 'openform_front', app.request.locale)) }}
  64.                     </button>
  65.                     <div class="header__expandable">
  66.                         <button class="header__buttons__button header__buttons__share" type="button" data-expanded="js-share-switcher" aria-expanded="false">
  67.                             {{share()}}
  68.                             {{arrowshow()}}
  69.                         </button>
  70.                         {% set config = openform_front_util.getConfig() %}
  71.                         <div class="header__expandable__list header__expandable--share js-share-switcher">
  72.                             {% if config.linkFacebook %}
  73.                                 <a href="{{ config.linkFacebook }}" class="header__buttons__button header__buttons__share header__expandable__btn">
  74.                                     {{facebooknav()}}
  75.                                 </a>
  76.                             {% endif %}
  77.                             {% if config.linkInstagram %}
  78.                                 <a href="{{ config.linkInstagram }}" class="header__buttons__button header__buttons__share header__expandable__btn">
  79.                                     {{instagramnav()}}
  80.                                 </a>
  81.                             {% endif %}
  82.                             {% if config.linkYoutube %}
  83.                                 <a href="{{ config.linkYoutube }}" class="header__buttons__button header__buttons__share header__expandable__btn">
  84.                                     {{youtubenav()}}
  85.                                 </a>
  86.                             {% endif %}
  87.                         </div>
  88.                     </div>
  89.                     <div class="header__expandable">
  90.                         <button class="header__buttons__button header__buttons__accessibility" type="button" data-expanded="js-accessibility-switcher" aria-expanded="false">
  91.                             {{accessibility()}}
  92.                             {{arrowshow()}}
  93.                         </button>
  94.                         <div class="header__expandable__list header__expandable--accessibility js-accessibility-switcher">
  95.                             <button class="header__buttons__button header__buttons__accessibility header__expandable__btn js-contrast-change" type="button">
  96.                                 {{contrast()}}
  97.                             </button>
  98.                             <button class="header__buttons__button header__buttons__accessibility header__expandable__btn js-font-resize-plus" type="button">
  99.                                 {{magnification()}}
  100.                             </button>
  101.                             <button class="header__buttons__button header__buttons__accessibility header__expandable__btn js-font-resize-minus" type="button">
  102.                                 {{reduction()}}
  103.                             </button>
  104.                         </div>
  105.                     </div>
  106.                 </div>
  107.             </div>
  108.         </div>
  109.     </div>
  110. {% include '@openform_front_templates/_includes/_search.html.twig' %}
  111. </header>