Changeset View
Changeset View
Standalone View
Standalone View
swh/web/templates/includes/breadcrumbs.html
{% comment %} | {% comment %} | ||||
Copyright (C) 2017-2018 The Software Heritage developers | Copyright (C) 2017-2021 The Software Heritage developers | ||||
See the AUTHORS file at the top-level directory of this distribution | See the AUTHORS file at the top-level directory of this distribution | ||||
License: GNU Affero General Public License version 3, or any later version | License: GNU Affero General Public License version 3, or any later version | ||||
See top-level LICENSE file for more information | See top-level LICENSE file for more information | ||||
{% endcomment %} | {% endcomment %} | ||||
{% if breadcrumbs %} | {% if breadcrumbs %} | ||||
{% if breadcrumbs|length > 1 or breadcrumbs.0.url %} | {% if iframe_mode or breadcrumbs|length > 1 or breadcrumbs.0.url %} | ||||
<nav class="bread-crumbs swh-browse-bread-crumbs"> | <nav class="bread-crumbs swh-browse-bread-crumbs"> | ||||
<ul> | <ul> | ||||
{% for bc in breadcrumbs %} | {% for bc in breadcrumbs %} | ||||
{% if bc.url %} | {% if bc.url %} | ||||
<li class="swh-path"><a href="{{ bc.url | safe }}">{{ bc.name }}</a></li> | <li class="swh-path"><a href="{{ bc.url | safe }}">{{ bc.name }}</a></li> | ||||
<li>/</li> | <li>/</li> | ||||
{% else %} | {% else %} | ||||
<li>{{ bc.name }}</li> | <li>{{ bc.name }}</li> | ||||
{% endif %} | {% endif %} | ||||
{% endfor %} | {% endfor %} | ||||
</ul> | </ul> | ||||
</nav> | </nav> | ||||
{% endif %} | {% endif %} | ||||
{% endif %} | {% endif %} | ||||