github.com/choria-io/go-choria@v0.28.1-0.20240416190746-b3bf9c7d5a45/docs/themes/hugo-theme-relearn/layouts/shortcodes/highlight.html (about) 1 {{- $content := "" }} 2 {{- $content = .InnerDeindent }} 3 {{- $attributes := dict }} 4 {{- $options := dict }} 5 {{- $type := "" }} 6 {{- range $k, $v := .Params }} 7 {{- if eq $k 0 }} 8 {{- $type = $v }} 9 {{- else if eq $k 1 }} 10 {{- $options = $v }} 11 {{- else if eq $k "type" }} 12 {{- $type = $v }} 13 {{- else if eq $k "title" }} 14 {{- $attributes = $attributes | merge (dict $k $v) }} 15 {{- else if eq $k "wrap" }} 16 {{- $attributes = $attributes | merge (dict $k $v) }} 17 {{- else }} 18 {{- $options = $options | merge (dict $k $v) }} 19 {{- end }} 20 {{- end }} 21 {{- partial "shortcodes/highlight.html" (dict 22 "page" .Page 23 "attributes" $attributes 24 "content" $content 25 "options" $options 26 "type" $type 27 ) }}