2018-05-05 16:00:51 +00:00
|
|
|
{{ define "content" }}
|
2019-04-09 01:19:05 +00:00
|
|
|
{{ $hasContent := false }}
|
|
|
|
{{ with .File }}
|
|
|
|
{{ if ne .Filename "" }}
|
|
|
|
{{ $hasContent = (ge (len $.RawContent) 100) }}
|
|
|
|
{{ end }}
|
|
|
|
{{ end }}
|
|
|
|
{{ if $hasContent }}
|
2018-11-24 16:03:52 +00:00
|
|
|
{{ partial "docs/content-page" (dict "ctx" $ "page" $ ) }}
|
2018-05-05 16:00:51 +00:00
|
|
|
{{ else }}
|
|
|
|
{{ if ge (len .Pages) 1 }}
|
|
|
|
{{ $page := index .Pages 0 }}
|
2018-11-24 16:03:52 +00:00
|
|
|
{{ partial "docs/content-page" (dict "ctx" $ "page" $page) }}
|
2018-05-05 16:00:51 +00:00
|
|
|
{{ end }}
|
|
|
|
{{ end }}
|
|
|
|
{{ end }}
|
|
|
|
{{ define "side-menu" }}
|
|
|
|
{{ partial "docs/side-menu.html" . }}
|
|
|
|
{{ end }}
|