Some checks failed
Deploy / deploy (push) Failing after 5s
The upstream anubis2 theme references hugo.Data.social.social_icons,
but `hugo` is a build-info namespace (hugo.Version, etc.) and has no
.Data field — Hugo errors with "can't evaluate field Data in type
interface {}". Theme data files live under site.Data, so this override
swaps the access path. Submodule left untouched.
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
42 lines
1.5 KiB
HTML
42 lines
1.5 KiB
HTML
<ul class="social-icons noselect">
|
|
|
|
{{ $params := partial "params-helper.html" . }}
|
|
|
|
|
|
{{ $socialData := site.Data.social.social_icons }}
|
|
{{ range $params.socialIcons }}
|
|
{{ if and (isset $socialData .id) (isset . "url") }}
|
|
<li>
|
|
<a {{ printf "href=%q" .url | safeHTMLAttr }} title="{{ humanize .id }}" aria-label="{{ humanize .id }}" rel="me">
|
|
{{ partial "features/font-awesome.html" (dict "iconName" .id "custom" false) }}
|
|
</a>
|
|
</li>
|
|
{{ else if and (isset $socialData .id) (isset . "name") }}
|
|
{{ $url := index $socialData .id }}
|
|
{{ $ref := printf $url .name }}
|
|
<li>
|
|
<a {{ printf "href=%q" $ref | safeHTMLAttr }} title="{{ humanize .id }}" aria-label="{{ humanize .id }}" rel="me">
|
|
{{ partial "features/font-awesome.html" (dict "iconName" .id "custom" false) }}
|
|
</a>
|
|
</li>
|
|
{{ else if (isset . "url") }}
|
|
<li>
|
|
<a href="{{ printf .url }}" title="{{ humanize .id }}" aria-label="{{ humanize .id }}" rel="me">
|
|
{{ partial "features/font-awesome.html" (dict "iconName" .id "custom" true) }}
|
|
</a>
|
|
</li>
|
|
{{ end }}
|
|
{{ end }}
|
|
|
|
{{ if $params.enableRssIcon }}
|
|
{{ with site.Home.OutputFormats.Get "rss" -}}
|
|
<li>
|
|
<a {{ printf "href=%q" .RelPermalink | safeHTMLAttr }} title="RSS" aria-label="RSS" rel="me">
|
|
{{ partial "features/font-awesome.html" (dict "iconName" "rss" "custom" false) }}
|
|
</a>
|
|
</li>
|
|
{{ end -}}
|
|
{{ end }}
|
|
|
|
</ul>
|