mirror of
https://github.com/McShelby/hugo-theme-relearn.git
synced 2024-11-27 01:33:04 +00:00
Remove indentation in "children" shortcode
- Fixes a bug where the list items appear in a code block instead of as HTML
This commit is contained in:
parent
8cd64b1bc9
commit
3d854fe9d4
1 changed files with 10 additions and 10 deletions
|
@ -45,28 +45,28 @@
|
||||||
{{$num := sub ( int (trim $.style "h") ) 1 }}
|
{{$num := sub ( int (trim $.style "h") ) 1 }}
|
||||||
{{$numn := add $num $.count }}
|
{{$numn := add $num $.count }}
|
||||||
|
|
||||||
{{(printf "<h%d>" $numn)|safeHTML}}
|
{{(printf "<h%d>" $numn)|safeHTML}}
|
||||||
<a href="{{.URL}}" >{{ .Title }}</a>
|
<a href="{{.URL}}" >{{ .Title }}</a>
|
||||||
{{(printf "</h%d>" $numn)|safeHTML}}
|
{{(printf "</h%d>" $numn)|safeHTML}}
|
||||||
|
|
||||||
{{else}}
|
{{else}}
|
||||||
{{(printf "<%s>" $.style)|safeHTML}}
|
{{(printf "<%s>" $.style)|safeHTML}}
|
||||||
<a href="{{.URL}}" >{{ .Title }}</a>
|
<a href="{{.URL}}" >{{ .Title }}</a>
|
||||||
{{(printf "</%s>" $.style)|safeHTML}}
|
{{(printf "</%s>" $.style)|safeHTML}}
|
||||||
{{end}}
|
{{end}}
|
||||||
|
|
||||||
{{if $.description}}
|
{{if $.description}}
|
||||||
{{if .Description}}
|
{{if .Description}}
|
||||||
<p>{{.Description}}</p>
|
<p>{{.Description}}</p>
|
||||||
{{else}}
|
{{else}}
|
||||||
<p>{{.Summary}}</p>
|
<p>{{.Summary}}</p>
|
||||||
{{end}}
|
{{end}}
|
||||||
{{end}}
|
{{end}}
|
||||||
{{end}}
|
{{end}}
|
||||||
{{ if lt $.count $.depth}}
|
{{ if lt $.count $.depth}}
|
||||||
|
|
||||||
{{if eq $.style "li"}}
|
{{if eq $.style "li"}}
|
||||||
<ul>
|
<ul>
|
||||||
{{end}}
|
{{end}}
|
||||||
|
|
||||||
{{ if .Sections}}
|
{{ if .Sections}}
|
||||||
|
@ -92,7 +92,7 @@
|
||||||
{{end}}
|
{{end}}
|
||||||
|
|
||||||
{{if eq $.style "li"}}
|
{{if eq $.style "li"}}
|
||||||
</ul>
|
</ul>
|
||||||
{{end}}
|
{{end}}
|
||||||
{{end}}
|
{{end}}
|
||||||
{{end}}
|
{{end}}
|
||||||
|
|
Loading…
Reference in a new issue