- 
		Home
	{{- $currentNode := . }}
{{- $showvisitedlinks := .Site.Params.showVisitedLinks -}}
{{- range .Site.Home.Sections.ByWeight}}
{{- template "section-tree-nav" dict "sect" . "currentnode" $currentNode}}
{{- end}}
{{- define "section-tree-nav" }}
{{- $currentNode := .currentnode }}
{{- with .sect}}
{{- if and .IsSection (or (not .Params.hidden) $.showhidden) -}}
    {{- $numberOfPages := (add (len .Pages) (len .Sections)) -}}
    {{- $hasChildren := ne $numberOfPages 0 -}}
    {{- $isAncestor := .IsAncestor $currentNode -}}
    {{- $isCurrent := (eq .RelPermalink $currentNode.RelPermalink) -}}
    {{- safeHTML .Params.head -}}
    {{ if .Params.separator }}
{{ end }}
    
        
          
            {{.Title}}
        
        {{- if $hasChildren }}
        
        
        
        {{ end }}
        
        {{- if $hasChildren }}
        
          {{- .Scratch.Set "pages" .Pages }}
          {{- if .Sections}}
          {{- .Scratch.Set "pages" (.Pages | union .Sections) }}
          {{- end}}
          {{- $pages := (.Scratch.Get "pages") }}
          {{- range $pages.ByWeight }}
            {{- if and .Params.hidden (not $.showhidden) }}
            {{- else}}
            {{- template "section-tree-nav" dict "sect" . "currentnode" $currentNode }}
            {{- end}}
          {{- end}}
        
{{- end}}
    
{{- else}}
    {{- if not .Params.Hidden }}
         
                
                 
                    {{safeHTML .Params.Pre}}{{.LinkTitle}}{{safeHTML .Params.Post}}
                
        
    {{- end}}
{{- end}}
{{- end}}
{{- end}}