templates/hc/dropdown-menu-nav-item.html.twig line 1

Open in your IDE?
  1. {% set link = _args.link|default('#') %}
  2. {% set icon = _args.icon|default(null) %}
  3. {% set color = _args.color|default(null) %}
  4. {% set active = _args.active|default(null) %}
  5. {% set title = _args.title %}
  6. {% set indicator = _args.indicator|default(null) %}
  7. {% if item %}
  8.     <a
  9.         href="{{ link|e('html_attr') }}"
  10.         title="{{ title }}"
  11.         class="
  12.         hc-header-nav-item--link
  13.         hc-header-nav-item--with-icon
  14.         hc-whitespace-nowrap
  15.         {% if active %}hc-active{% endif %}
  16. "
  17.     >
  18.             <span class="hc-header-nav-item-inner">
  19.                 {% if icon %}
  20.                     {% include 'hc/icon.html.twig' with (icon is iterable ? icon : {
  21.                         glyph: icon,
  22.                         color: color,
  23.                         size: 20,
  24.                     }) %}
  25.                 {% endif %}
  26.                 <span class="hc-flex-grow{% if color %} hc-text--{{ color }}{% endif %}">{{ title }}</span>
  27.             </span>
  28.     </a>
  29. {% endif %}