diff --git a/site/layouts/partials/tree.html b/site/layouts/partials/tree.html
index 6c00cd7c7..e5a1f5fce 100644
--- a/site/layouts/partials/tree.html
+++ b/site/layouts/partials/tree.html
@@ -1,41 +1,38 @@
+
{{ define "treemenu" }}
{{ $nextDepth := add .depth 1 }}
{{- $activeLink := $.root.Permalink }}
{{- $className := "" }}
{{- $deprecated := true }}
+ {{- $expand := .expand }}
{{- with $.root.Site.GetPage .url }}
{{- if not .Params.deprecated }}
{{- $deprecated = false }}
{{- $branchLink := .Permalink }}
- {{- if in $activeLink $branchLink }}
- {{- $className = "tree-branch-active" -}}
- {{ end }}
- {{- if eq $activeLink $branchLink }}
- {{- $className = "tree-active tree-branch-active" -}}
- {{- end -}}
{{ .Title }}
{{- end }}
{{- end }}
+
{{- if not $deprecated }}
-
+
{{- range (readDir .path) }}
{{- if in .Name "image" | or (eq .Name "_index.md") }}
{{- else }}
@@ -44,11 +41,11 @@
{{- $fullUrl = replace $fullUrl ".md" "" }}
{{- $stat := os.Stat $fullPath }}
{{- if $stat.IsDir }}
- {{- template "treemenu" dict "path" $fullPath "url" $fullUrl "root" $.root "depth" $nextDepth }}
+ {{- template "treemenu" dict "path" $fullPath "url" $fullUrl "root" $.root "depth" $nextDepth "expand" false }}
{{- else }}
{{- with $.root.Site.GetPage $fullUrl }}
- {{- $link := printf "%s" .Permalink }}
- -
+ {{- $link := printf "%s" .Permalink }}
+
-
{{ .Title }}
{{- end }}
@@ -58,4 +55,42 @@
{{- end }}
-{{ end }}
\ No newline at end of file
+{{ end }}
+
+