diff options
Diffstat (limited to 'themes/default/layouts/_default/summary.html')
-rw-r--r-- | themes/default/layouts/_default/summary.html | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/themes/default/layouts/_default/summary.html b/themes/default/layouts/_default/summary.html index e5b1154..e1e6f73 100644 --- a/themes/default/layouts/_default/summary.html +++ b/themes/default/layouts/_default/summary.html @@ -1,5 +1,9 @@ {{- $limit := gt .WordCount 75 -}} -{{- if $limit -}}<input hidden type="checkbox" id="expand-{{ partial "card-id.html" . }}" />{{- end -}} +{{- $content := partial "function-content.html" .Content | safeHTML -}} + +{{- if $limit -}} + <input hidden type="checkbox" id="expand-{{ partial "card-id.html" . }}" /> +{{- end -}} <micro-card id="{{ partial "card-id.html" . }}" @@ -23,9 +27,13 @@ <micro-metadata> {{ partial "card-meta-header.html" . }} </micro-metadata> - {{ if .Params.unsafe }}{{ partial "card-unsafe.html" "begin" }}{{ end }} - {{- partial "function-content.html" .Content | safeHTML -}} - {{ if .Params.unsafe }}{{ partial "card-unsafe.html" "end" }}{{ end }} + {{ if .Params.unsafe }} + {{ partial "card-unsafe.html" "begin" }} + {{- $content -}} + {{ partial "card-unsafe.html" "end" }} + {{ else }} + {{- $content -}} + {{ end }} <micro-tags>{{ partial "meta-tags.html" . }}</micro-tags> </micro-content> </micro-summary> |