{{ $geekdocRepo := default (default false .Site.Params.GeekdocRepo) .Page.Params.GeekdocRepo }} {{ $geekdocEditPath := default (default false .Site.Params.GeekdocEditPath) .Page.Params.GeekdocEditPath }} {{ if .File }} {{ $.Scratch.Set "geekdocFilePath" (default (path.Join .Site.Params.contentDir .File.Path) .Page.Params.GeekdocFilePath) }} {{ else }} {{ $.Scratch.Set "geekdocFilePath" false }} {{ end }} {{ define "breadcrumb" }} {{ $parent := .page.Parent }} {{ if $parent }} {{ $name := (partial "utils/title" $parent) }} {{ $position := (sub .position 1) }} {{ $value := (printf "
  • %s
  • /
  • %s" $parent.RelPermalink $parent.RelPermalink $name $position .value) }} {{ template "breadcrumb" dict "page" $parent "value" $value "position" $position }} {{ else }} {{ .value | safeHTML }} {{ end }} {{ end }} {{ $showBreadcrumb := (and (default true .Page.Params.GeekdocBreadcrumb) (default true .Site.Params.GeekdocBreadcrumb)) }} {{ $showEdit := (and ($.Scratch.Get "geekdocFilePath") $geekdocRepo $geekdocEditPath) }}
    {{ if $showBreadcrumb }}
    {{ end }} {{ if $showEdit }}
    {{ i18n "edit_page" }}
    {{ end }}