{{- $showvisitedlinks := .Site.Params.showVisitedLinks }} {{- define "partials/inline/page-tree" }} {{- $currentNode := .currentnode }} {{- $config := .config }} {{- $showvisitedlinks := .showvisitedlinks }}
{{- end }} {{- end }} {{- define "partials/inline/page-walker" }} {{- $currentNode := .currentnode }} {{- $showvisitedlinks := .showvisitedlinks }} {{- $alwaysopen := .alwaysopen }} {{- $isSelf := .isSelf }} {{- $isAncestor := .isAncestor }} {{- $isHidden := .isHidden }} {{- with .sect }} {{- $isActive := $isSelf }} {{- $entry := . }} {{- $entries := partialCached "_relearn/pages.gotmpl" (dict "page" .) .Path }} {{- $hasVisibleChildren := false }} {{- range $entries }} {{- $isSubSelf := eq . $currentNode }} {{- $isSubAncestor := and (not $isSubSelf) (.IsAncestor $currentNode) }} {{- $isSubHidden := or (.Params.hidden) (eq .Title "") }} {{- if or $isSubAncestor $isSubSelf (not $isSubHidden) }} {{- $hasVisibleChildren = true }} {{- break }} {{- end }} {{- end }} {{- $title := partial "title.gotmpl" (dict "page" . "linkTitle" true) }} {{- $url := partial "permalink.gotmpl" (dict "to" .) }} {{- $isCrosslink := false }} {{- if .Params.menuPageRef }} {{- $isCrosslink = true }} {{- $url = .Params.menuPageRef }} {{- $linkObject := partial "_relearn/refObject.gotmpl" (dict "page" . "objectRef" .Params.menuPageRef) }} {{- if $linkObject }} {{- $url = partial "_relearn/decoratedLink.gotmpl" (dict "url" .Params.menuPageRef "page" . "linkObject" $linkObject "param" "link" "silent" true) }} {{- end }} {{- else if .Params.menuUrl }} {{- $isCrosslink = true }} {{- $url = .Params.menuUrl | relLangURL }} {{- end }} {{- $pre := partial "menu-pre.html" . }} {{- $post := partial "menu-post.html" . }} {{- if and $hasVisibleChildren (not $isCrosslink) }} {{- $isCollapsible := .Params.collapsibleMenu | default site.Params.collapsibleMenu }} {{- $currentAlwaysopen := .Params.alwaysopen | default $alwaysopen }} {{- if and (not $url) (not $isCollapsible) }} {{- $currentAlwaysopen = true }} {{- end }} {{- $entryId := md5 .Path }} {{- $isOpen := or $currentAlwaysopen $isSelf $isAncestor }}