Skip to content

Commit ecf2a2b

Browse files
authored
Remove hardcoded root breadcrumb (#1390)
It's not needed anymore since the navigation refactoring
1 parent c7be45e commit ecf2a2b

File tree

1 file changed

+2
-14
lines changed

1 file changed

+2
-14
lines changed

src/Elastic.Markdown/Slices/Layout/_Breadcrumbs.cshtml

Lines changed: 2 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -12,29 +12,17 @@
1212
}
1313

1414
<ol id="breadcrumbs" class="block items-center w-full py-6" itemscope="" itemtype="https://schema.org/BreadcrumbList">
15-
<li class="inline text-ink-light text-sm leading-[1.2em]" itemprop="itemListElement" itemscope="" itemtype="https://schema.org/ListItem">
16-
<a
17-
itemprop="item"
18-
href="@Model.Link("/")"
19-
>
20-
<span itemprop="name" class="hover:text-black">
21-
Docs
22-
</span>
23-
</a>
24-
<meta itemprop="position" content="1">
25-
</li>
2615
@if (firstCrumb != null)
2716
{
2817
<li class="inline text-ink-light text-sm leading-[1.2em]" itemprop="itemListElement" itemscope="" itemtype="https://schema.org/ListItem">
29-
<span class="px-1">/</span>
3018
<a
3119
itemprop="item"
3220
href="@firstCrumb.Url"
3321
@Htmx.GetHxAttributes(firstCrumb.Url, Model.CurrentNavigationItem?.NavigationRoot.Id == firstCrumb.NavigationRoot.Id)
3422
>
3523
<span itemprop="name" class="hover:text-black">@firstCrumb.NavigationTitle</span>
3624
</a>
37-
<meta itemprop="position" content="2">
25+
<meta itemprop="position" content="1">
3826
</li>
3927
}
4028
@if (crumbs.Count > 0 && parents.Count > 3)
@@ -57,7 +45,7 @@
5745
>
5846
<span itemprop="name" class="hover:text-black">@item.NavigationTitle</span>
5947
</a>
60-
<meta itemprop="position" content="@(i+3)">
48+
<meta itemprop="position" content="@(i+2)">
6149
</li>
6250
}
6351
<li class="inline text-ink-light text-sm leading-[1.2em]" itemprop="itemListElement" itemscope="" itemtype="https://schema.org/ListItem">

0 commit comments

Comments
 (0)