filebrowser/templates/frontmatter.tmpl

12 lines
414 B
Cheetah

{{ define "frontmatter" }}
{{ range $key, $value := . }}
{{ if $value.SubContent }}
<h2>{{ splitCapitalize $value.Name }}</h2>
{{ template "frontmatter" $value.Content }}
{{ else}}
<label for="{{ $value.Tag }}">{{ splitCapitalize $value.Name }}</label>
<input name="{{ $value.Tag }}" id="{{ $value.Tag }}" value="{{ $value.Content }}"></input><br>
{{ end }}
{{ end }}
{{ end }}