layouts(fix): replace deprecated site.Social with site.params.Social

This commit is contained in:
Szilárd Pfeiffer 2024-10-16 20:13:53 +02:00
parent 33178c0d49
commit b0afd012c3

View File

@ -3,7 +3,7 @@
{{ $facebook_href := printf "https://www.facebook.com/sharer.php?u=%s" $url }} {{ $facebook_href := printf "https://www.facebook.com/sharer.php?u=%s" $url }}
{{ $twitter_href := printf "https://twitter.com/intent/tweet?url=%s&text=%s" $url $title }} {{ $twitter_href := printf "https://twitter.com/intent/tweet?url=%s&text=%s" $url $title }}
{{ with site.Social.twitter }} {{ with site.params.Social.twitter }}
{{ $twitter_href = printf "%s&via=%s" $twitter_href . }} {{ $twitter_href = printf "%s&via=%s" $twitter_href . }}
{{ end }} {{ end }}
{{ $linkedin_href := printf "https://www.linkedin.com/shareArticle?mini=true&url=%s&title=%s" $url $title }} {{ $linkedin_href := printf "https://www.linkedin.com/shareArticle?mini=true&url=%s&title=%s" $url $title }}