github.com/choria-io/go-choria@v0.28.1-0.20240416190746-b3bf9c7d5a45/docs/themes/hugo-theme-relearn/layouts/partials/shortcodes/icon.html (about)

     1  {{- $page := .page }}
     2  {{- if and (not $page) .context }}
     3    {{- $page = .context }}
     4    {{- warnf "%q: DEPRECATED parameter 'context' for shortcode 'icon' found, use 'page' instead; see https://mcshelby.github.io/hugo-theme-relearn/basics/migration#5180" $page.File.Filename }}
     5  {{- end }}
     6  {{- $icon := .icon | default "" }}
     7  {{- $icon = trim $icon " " }}
     8  {{- if and $icon (not (findRE ".*?\\bfa-\\w.*?" $icon)) }}
     9    {{- $icon = printf "fa-fw fas fa-%s" $icon }}
    10  {{- end }}
    11  {{- with $page }}
    12    {{- if $icon -}}
    13  <i class="{{ $icon }}"></i>
    14    {{- end }}
    15  {{- end }}