mirror of
https://github.com/hugo-fixit/FixIt.git
synced 2026-08-24 15:28:57 +00:00
5b43c2b6a3
* fix(tabs): improve tab shortcode rendering and trim whitespace * fix(tabs): restore sticky code header for left/right placement
13 lines
570 B
HTML
13 lines
570 B
HTML
{{- $password := cond .IsNamedParams (.Get "password") (.Get 0) | default "" -}}
|
|
{{- $message := cond .IsNamedParams (.Get "message") (.Get 1) | default (T "single.encryptedMessage") -}}
|
|
|
|
{{- if $password -}}
|
|
{{- /* Content */ -}}
|
|
{{- $content := .Inner | strings.TrimSpace | .Page.RenderString -}}
|
|
{{- /* Content Encryption */ -}}
|
|
{{- dict "Content" $content "Password" $password "Message" $message "IsPartial" true "Page" .Page | partial "plugin/fixit-encryptor.html" -}}
|
|
{{- .Page.Store.Set "hasEncryptor" true -}}
|
|
{{- else -}}
|
|
{{- .Inner -}}
|
|
{{- end -}}
|