[PATCH] tpl/tplimpl: Trim descriptions rather than just chomp

from https://github.com/gohugoio/hugo/commit/039845804fd545de18a3c4f17f8f7b3ad3bf615b
This commit is contained in:
Patrice Chalin
2024-10-12 16:41:42 -04:00
committed by Aditya Telange
parent 3f20d3cd77
commit a2f09c8c0d
2 changed files with 4 additions and 4 deletions
+2 -2
View File
@@ -8,8 +8,8 @@
<meta property="og:title" content="{{ . }}"> <meta property="og:title" content="{{ . }}">
{{- end }} {{- end }}
{{- with or .Description .Summary site.Params.description | plainify | htmlUnescape | chomp }} {{- with or .Description .Summary site.Params.description | plainify | htmlUnescape }}
<meta property="og:description" content="{{ . }}"> <meta property="og:description" content="{{ trim . "\n\r\t " }}">
{{- end }} {{- end }}
{{- with or .Params.locale site.Language.LanguageCode }} {{- with or .Params.locale site.Language.LanguageCode }}
@@ -19,8 +19,8 @@
<meta name="twitter:title" content="{{ . }}"> <meta name="twitter:title" content="{{ . }}">
{{- end }} {{- end }}
{{- with or .Description .Summary site.Params.description | plainify | htmlUnescape | chomp }} {{- with or .Description .Summary site.Params.description | plainify | htmlUnescape }}
<meta name="twitter:description" content="{{ . }}"> <meta name="twitter:description" content="{{ trim . "\n\r\t " }}">
{{- end }} {{- end }}
{{- $twitterSite := "" }} {{- $twitterSite := "" }}