{% sw_extends '@Storefront/storefront/layout/breadcrumb.html.twig' %}
{% set homeName = 'general.homeLink'|trans|sw_sanitize %}
{% block layout_breadcrumb_list_item %}
{% if loop.index == 1 %}
<a href="{{ path('frontend.home.page') }}"
class="breadcrumb-link"
title="{{ homeName }}"
itemprop="item">
<link itemprop="url"
href="{{ path('frontend.home.page') }}"/>
<span class="breadcrumb-title" itemprop="name">{{ homeName }}</span>
</a>
<div class="breadcrumb-placeholder">
{% sw_icon 'arrow-medium-right' style { 'size': 'fluid', 'pack': 'solid'} %}
</div>
{% endif %}
<li class="breadcrumb-item"
{% if key is same as(categoryId) %}aria-current="page"{% endif %}
itemprop="itemListElement"
itemscope
itemtype="https://schema.org/ListItem">
{% if breadcrumbCategory.type == 'folder' or key == breadcrumbKeys|last %}
<div itemprop="item{% if key is same as(categoryId) %} is-active{% endif %}">
<div itemprop="name">{{ name }}</div>
</div>
{% else %}
<a href="{{ category_url(breadcrumbCategory) }}"
class="breadcrumb-link {% if key is same as(categoryId) %} is-active{% endif %}"
title="{{ name }}"
{% if category_linknewtab(breadcrumbCategory) %}target="_blank"{% endif %}
itemprop="item">
<link itemprop="url"
href="{{ category_url(breadcrumbCategory) }}"/>
<span class="breadcrumb-title" itemprop="name">{{ name }}</span>
</a>
{% endif %}
<meta itemprop="position" content="{{ loop.index }}"/>
</li>
{% endblock %}