1
goldsmith-samples/bootstrap/content/layouts/breadcrumbs.gohtml

17 lines
548 B
Plaintext
Raw Normal View History

2017-10-15 16:44:36 +00:00
{{define "breadcrumbs"}}
2022-01-09 02:33:05 +00:00
{{if and .Props.CrumbParent .Props.Crumbs}}
2017-10-15 16:44:36 +00:00
<div>
<nav class="breadcrumb">
2022-01-09 02:33:05 +00:00
{{range .Props.Crumbs.Ancestors}}
<a href="/{{.File.Path}}" class="breadcrumb-item">{{.File.Props.Title}}</a>
2017-10-15 16:44:36 +00:00
{{end}}
2022-01-09 02:33:05 +00:00
{{if .Props.Title}}
<span class="breadcrumb-item active">{{.Props.Title}}</span>
{{else if eq .Props.Layout "tag"}}
<span class="breadcrumb-item active">Tagged &ldquo;{{.Props.TagState.CurrentTag.RawName}}&rdquo;</span>
2017-10-15 16:44:36 +00:00
{{end}}
</nav>
</div>
{{end}}
{{end}}