Skip to content

Commit

Permalink
Added missing closing tag
Browse files Browse the repository at this point in the history
  • Loading branch information
shkolin committed Mar 5, 2021
1 parent e002020 commit ab923ca
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/Breadcrumbs.php
Expand Up @@ -33,7 +33,7 @@ class Breadcrumbs extends Widget
private array $homeItem = [];
private bool $withoutHomeItem = false;
private string $itemTemplate = "<li>{icon}{link}</li>\n";
private string $activeItemTemplate = "<li class=\"is-active\"><a aria-current=\"page\">{icon}{label}</li>\n";
private string $activeItemTemplate = "<li class=\"is-active\"><a aria-current=\"page\">{icon}{label}</a></li>\n";
private array $items = [];
private array $options = [];
private array $itemsOptions = [];
Expand Down
4 changes: 2 additions & 2 deletions tests/BreadcrumbsTest.php
Expand Up @@ -128,7 +128,7 @@ public function testBreadcrumbsItemTemplateActive(): void

$html = Breadcrumbs::widget()
->homeItem(['label' => 'Index', 'url' => '/index'])
->activeItemTemplate("<li class=\"active\"><a aria-current=\"page\">{label}</li>\n")
->activeItemTemplate("<li class=\"active\"><a aria-current=\"page\">{label}</a></li>\n")
->items([['label' => 'About', 'url' => '/about']])
->render();
$expected = <<<'HTML'
Expand Down Expand Up @@ -157,7 +157,7 @@ public function testBreadcrumbsLinksEmptyUrl(): void
<nav id="w1-breadcrumbs" class="breadcrumb" aria-label="breadcrumbs">
<ul>
<li><a href="/">Home</a></li>
<li class="is-active"><a aria-current="page">about</li>
<li class="is-active"><a aria-current="page">about</a></li>
</ul>
</nav>
HTML;
Expand Down

0 comments on commit ab923ca

Please sign in to comment.