diff --git a/site/layouts/partials/social.html b/site/layouts/partials/social.html index 2226c386c4..f4f556e5a8 100644 --- a/site/layouts/partials/social.html +++ b/site/layouts/partials/social.html @@ -1,15 +1,27 @@ +{{- $pageTitle := .Title | markdownify -}} +{{- $pageDescription := .Page.Params.description | default .Site.Params.description | markdownify -}} +{{- $socialImagePath := printf "/docs/%s/assets" .Site.Params.docs_version -}} + +{{- if .Page.Params.thumbnail -}} + {{- $socialImagePath = path.Join $socialImagePath "img/" .Page.Params.thumbnail -}} +{{- else -}} + {{- $socialImagePath = path.Join $socialImagePath "brand/bootstrap-social.png" -}} +{{- end -}} + - - - + + + - - + + + - - - +{{ with (imageConfig (path.Join "site/static" $socialImagePath)) -}} + + +{{- end }}