vendor/shopware/storefront/Resources/views/storefront/component/listing/filter/filter-multi-select.html.twig line 1

Open in your IDE?
  1. {% set filterItemId = 'filter-' ~ name ~ '-' ~ random() %}
  2. {% if pluginSelector is not defined %}
  3.     {% set pluginSelector = 'filter-multi-select' %}
  4. {% endif %}
  5. {% if dataPluginSelectorOptions is not defined %}
  6.     {% set dataPluginSelectorOptions = {
  7.         name: name,
  8.         snippets: {
  9.             disabledFilterText: 'listing.disabledFilterTooltip'|trans|sw_sanitize
  10.         }
  11.     } %}
  12. {% endif %}
  13. {% block component_filter_multi_select %}
  14.     <div class="filter-multi-select filter-multi-select-{{ name }} filter-panel-item{% if not sidebar %} dropdown{% endif %}"
  15.          data-{{ pluginSelector }}="true"
  16.          data-{{ pluginSelector }}-options='{{ dataPluginSelectorOptions|json_encode }}'>
  17.         {% block component_filter_multi_select_toggle %}
  18.             <button class="filter-panel-item-toggle btn{% if sidebar %} btn-block{% endif %}"
  19.                     aria-expanded="false"
  20.                     {% if sidebar %}
  21.                     data-toggle="collapse"
  22.                     data-target="#{{ filterItemId }}"
  23.                     {% else %}
  24.                     data-toggle="dropdown"
  25.                     data-boundary="viewport"
  26.                     data-offset="0,8"
  27.                     aria-haspopup="true"
  28.                     {% endif %}>
  29.                 {% block component_filter_multi_select_display_name %}
  30.                     {{ displayName }}
  31.                 {% endblock %}
  32.                 {% block component_filter_multi_select_count %}
  33.                     <span class="filter-multi-select-count"></span>
  34.                 {% endblock %}
  35.                 {% block component_filter_multi_select_toggle_icon %}
  36.                     {% sw_icon 'arrow-medium-down' style {
  37.                         'pack': 'solid', 'size': 'xs', 'class': 'filter-panel-item-toggle'
  38.                     } %}
  39.                 {% endblock %}
  40.             </button>
  41.         {% endblock %}
  42.         {% block component_filter_multi_select_dropdown %}
  43.             <div class="filter-multi-select-dropdown filter-panel-item-dropdown{% if sidebar %} collapse{% else %} dropdown-menu{% endif %}"
  44.                  id="{{ filterItemId }}">
  45.                 {% block component_filter_multi_select_list %}
  46.                     <ul class="filter-multi-select-list">
  47.                         {% for element in elements %}
  48.                             {% block component_filter_multi_select_list_item %}
  49.                                 <li class="filter-multi-select-list-item">
  50.                                     {% block component_filter_multi_select_list_item_inner %}
  51.                                         {% sw_include '@Storefront/storefront/component/listing/filter/filter-multi-select-list-item.html.twig' %}
  52.                                     {% endblock %}
  53.                                 </li>
  54.                             {% endblock %}
  55.                         {% endfor %}
  56.                     </ul>
  57.                 {% endblock %}
  58.             </div>
  59.         {% endblock %}
  60.     </div>
  61. {% endblock %}