mirror of
https://github.com/gcushen/hugo-academic.git
synced 2025-07-23 18:10:52 +02:00
feat: allow hiding breadcrumb on docs pages
By adding following to Hugo config or page frontmatter: `show_breadcrumb: false` Close #3178
This commit is contained in:
parent
4fab7b1fc8
commit
5c58e935f1
2 changed files with 3 additions and 1 deletions
|
@ -1,6 +1,6 @@
|
|||
{{- /* Hugo 0.126+ requires a `home` layout file even if it's empty, otherwise shows warning */ -}}
|
||||
{{- if (eq (getenv "HUGO_BLOX_DEBUG") "true") -}}
|
||||
{{- range site.Pages -}}{{- $_ := .WordCount -}}{{- end -}}
|
||||
{{- if (eq (getenv "HUGO_BLOX_DEBUG") "true") -}}
|
||||
{{- $backlinks := (.Store.Get "backlinks" | uniq) | default dict -}}
|
||||
{{- jsonify (dict "indent" " ") $backlinks -}}
|
||||
{{- else -}}
|
||||
|
|
|
@ -3,9 +3,11 @@
|
|||
{{ partial "components/toc.html" . }}
|
||||
<article class="flex w-full min-w-0 min-h-[calc(100vh-var(--navbar-height))] justify-center break-words pb-8 pr-[calc(env(safe-area-inset-right)-1.5rem)]">
|
||||
<main class="prose prose-slate lg:prose-xl dark:prose-invert w-full min-w-0 max-w-6xl px-6 pt-4 md:px-12">
|
||||
{{ if (.Params.show_breadcrumb | default true) }}
|
||||
<div class="mb-1">
|
||||
{{ partial "components/breadcrumb.html" . }}
|
||||
</div>
|
||||
{{ end }}
|
||||
|
||||
<div class="content text-base">
|
||||
<h1>{{ .Title }}</h1>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue