commit 352c132a1db08070f3d0f9f300a10e4ba890c9ee
parent c41969fee705c796ff68bec9bb20f5af5ee444cb
Author: Shimmy Xu <shimmy.xu@shimmy1996.com>
Date: Sun, 12 Apr 2020 21:42:22 -0500
Only show ellipsis if truncated
Diffstat:
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/layouts/partials/head.html b/layouts/partials/head.html
@@ -29,5 +29,9 @@
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
{{ partial "head_custom.html" . }}
- <title>{{ with .Title }}{{ . }}{{ else }}{{ .Summary }}…{{ end }} | {{ .Site.Title }}</title>
+ <title>
+ {{- with .Title }}{{ . }}{{ else -}}
+ {{- .Summary }}{{ if .Truncated }}…{{ end -}}
+ {{- end -}} | {{ .Site.Title -}}
+ </title>
</head>