Merge branch 'master' into 2021-10-19_meta-description

This commit is contained in:
Maksim Iakunin 2021-10-20 16:43:34 +03:00 committed by GitHub
commit 4001d5e92f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 3 additions and 6 deletions

View File

@ -4,7 +4,7 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="referrer" content="no-referrer-when-downgrade">
<title>{{ if and (.Title) (not .IsHome) }}{{ .Title }} - {{ end }}{{ .Site.Title }}</title>
{{ partial "title.html" }}
<meta name="description" content="{{ with .Description }}{{ . }}{{ else }}{{if .IsPage}}{{ .Summary }}{{ else }}{{ with .Site.Params.description }}{{ . }}{{ end }}{{ end }}{{ end -}}">
{{ with .OutputFormats.Get "rss" -}}

View File

@ -6,11 +6,7 @@
{{ if not .Site.Params.disableSummary }}
<div class="content post-summary p-summary">
{{ if isset .Params "description" }}
{{ .Description | safeHTML }}
{{ else }}
{{ .Summary | safeHTML }}&hellip;
{{ end }}
{{ .Summary | safeHTML }}
</div>
{{ end }}
{{ if and (.Truncated) (.Site.Params.readMore) }}

View File

@ -0,0 +1 @@
<title>{{ if and (.Title) (not .IsHome) }}{{ .Title }} - {{ end }}{{ .Site.Title }}</title>