xref: /webtrees/resources/views/components/breadcrumbs.phtml (revision ac71572d8462e396ed5a307f05b29381e49f9e6e)
1<?php
2
3declare(strict_types=1);
4
5/**
6 * @var array<string|int,string> $links
7 */
8
9?>
10<nav class="wt-breadcrumbs" aria-label="breadcrumb" role="navigation">
11    <ol class="breadcrumb small py-2">
12        <?php foreach ($links as $url => $label) : ?>
13            <?php if (is_int($url)) : ?>
14                <li class="breadcrumb-item active">
15                    <?= $label ?>
16                </li>
17            <?php else : ?>
18                <li class="breadcrumb-item">
19                    <a href="<?= e($url) ?>">
20                        <?= $label ?>
21                    </a>
22                </li>
23            <?php endif ?>
24        <?php endforeach ?>
25    </ol>
26</nav>
27