{{ attach_library('ui_patterns/libraries.bs_breadcrumb') }}
{{ attach_library('ui_patterns/th_things_breadcrumb.th_things_breadcrumb_lib') }}

<nav aria-label="breadcrumb" id="th-things-breadcrumb" class="{{ utility_classes|join(' ') }} brd-crm">
  <ol class="breadcrumb mb-1">
    {% if home %}
      <li class="breadcrumb-item">
        {{ home }}
        <i class='fas fa-chevron-right'></i>
      </li>
    {% endif %}
    {% if landing_page %}
      <li class="breadcrumb-item">
        {{ landing_page }}
        <i class='fas fa-chevron-right'></i>
      </li>
    {% endif %}
    {% if category %}
      <li class="breadcrumb-item">
        {{ category }}
        {% if regions %}
          <span class="cat-reg-separator-wrapper">
            <i class='fas fa-slash cat-reg-separator'></i>
          </span>
        {% endif %}
      </li>
    {% endif %}
    {% if regions %}
      {% set region_links = [] %}
      {% for region_link in regions %}
        {% set region_link_array %}
          {{ region_link }}
        {% endset %}
        {% set region_links = region_links|merge([region_link_array]) %}
      {% endfor %}
      <li class="breadcrumb-item">
        {{ region_links|join('<i class="fas fa-circle region-separator"></i>')|raw }}
      </li>
    {% endif %}
  </ol>
</nav>
