mirror of
https://github.com/qdrant/landing_page.git
synced 2026-10-05 19:08:32 +02:00
Side menu progress bar: also include isLesson leaf pages in progress calculation
This commit is contained in:
@@ -40,7 +40,19 @@
|
|||||||
{{ end }}
|
{{ end }}
|
||||||
|
|
||||||
{{ if or (eq $currentNode.Params.isLesson true) (eq $currentNode.Parent.Params.isLesson true) }}
|
{{ if or (eq $currentNode.Params.isLesson true) (eq $currentNode.Parent.Params.isLesson true) }}
|
||||||
{{ $allLessons := where $subject.Pages ".Params.isLesson" true }}
|
{{ $allLessons := slice }}
|
||||||
|
{{ range $subject.Pages }}
|
||||||
|
{{ if .Params.isLesson }}
|
||||||
|
{{ $allLessons = $allLessons | append . }}
|
||||||
|
{{ end }}
|
||||||
|
{{ if .IsSection }}
|
||||||
|
{{ range .Pages }}
|
||||||
|
{{ if .Params.isLesson }}
|
||||||
|
{{ $allLessons = $allLessons | append . }}
|
||||||
|
{{ end }}
|
||||||
|
{{ end }}
|
||||||
|
{{ end }}
|
||||||
|
{{ end }}
|
||||||
{{ $total := len $allLessons }}
|
{{ $total := len $allLessons }}
|
||||||
|
|
||||||
{{ if $total }}
|
{{ if $total }}
|
||||||
|
|||||||
Reference in New Issue
Block a user