ui/twig/common/dashboard/sidebar/submenuitem.html.twig line 1

Open in your IDE?
  1. {% set text = _args.text %}
  2. {% set htmlId = _args.htmlId|default(null) %}
  3. {% set link = _args.path is defined ? (_args.path is not iterable ? path(_args.path) : path(_args.path[0])) : _args.link|default('#') %}
  4. {% set path = _args.path|default('') %}
  5. {% set target = _args.target|default(null) %}
  6. {% set active = (_args.active is defined) ? (_args.active is same as(true)) : (classify('active', path) is same as('active')) %}
  7. <li class="{% if active is same as(true) %}active{% endif %}">
  8.     <a
  9.         href="{{ link }}"
  10.         {% if htmlId is not null %}id="{{ htmlId }}"{% endif %}
  11.         {% if target is not null %}target="{{ target }}"{% endif %}
  12.     >{{ text }}</a>
  13. </li>