Improve description for twitter cards and posts
This commit is contained in:
parent
a46b6f6032
commit
e3808bce7d
3 changed files with 15 additions and 5 deletions
|
@ -52,6 +52,11 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
&-excerpt {
|
||||||
|
color: grey;
|
||||||
|
font-style: italic;
|
||||||
|
}
|
||||||
|
|
||||||
&-info {
|
&-info {
|
||||||
margin-top: 30px;
|
margin-top: 30px;
|
||||||
font-size: 0.8rem;
|
font-size: 0.8rem;
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
<meta http-equiv="X-UA-Compatible" content="ie=edge">
|
<meta http-equiv="X-UA-Compatible" content="ie=edge">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
||||||
<meta name="author" content="{{ if .Params.author }}{{ .Params.author }}{{ else }}{{ range .Site.Author }}{{ . }} {{ end }}{{ end }}">
|
<meta name="author" content="{{ if .Params.author }}{{ .Params.author }}{{ else }}{{ range .Site.Author }}{{ . }} {{ end }}{{ end }}">
|
||||||
<meta name="description" content="{{ if .IsHome }}{{ .Site.Params.homeSubtitle }}{{ else }}{{ .Summary | plainify }}{{ end }}" />
|
<meta name="description" content="{{ if .IsHome }}{{ .Site.Params.homeSubtitle }}{{ else }}{{ if .Params.Description }}{{ .Params.Description }}{{ else }}{{ .Summary | plainify }}{{ end }}{{ end }}" />
|
||||||
<meta name="keywords" content="{{ .Site.Params.keywords }}{{ if .Params.tags }}{{ range .Params.tags }}, {{ . }}{{ end }}{{ end }}" />
|
<meta name="keywords" content="{{ .Site.Params.keywords }}{{ if .Params.tags }}{{ range .Params.tags }}, {{ . }}{{ end }}{{ end }}" />
|
||||||
<meta name="robots" content="noodp" />
|
<meta name="robots" content="noodp" />
|
||||||
<meta name="theme-color" content="{{ .Site.Params.themeColor }}" />
|
<meta name="theme-color" content="{{ .Site.Params.themeColor }}" />
|
||||||
|
@ -37,6 +37,7 @@
|
||||||
|
|
||||||
{{ template "_internal/schema.html" . }}
|
{{ template "_internal/schema.html" . }}
|
||||||
{{ template "_internal/twitter_cards.html" . }}
|
{{ template "_internal/twitter_cards.html" . }}
|
||||||
|
{{ template "_internal/google_news.html" . }}
|
||||||
|
|
||||||
{{ if isset .Site.Taxonomies "series" }}
|
{{ if isset .Site.Taxonomies "series" }}
|
||||||
{{ template "_internal/opengraph.html" . }}
|
{{ template "_internal/opengraph.html" . }}
|
||||||
|
|
|
@ -22,6 +22,14 @@
|
||||||
<a href="{{ .Permalink }}">{{ .Title | markdownify }}</a>
|
<a href="{{ .Permalink }}">{{ .Title | markdownify }}</a>
|
||||||
</h1>
|
</h1>
|
||||||
|
|
||||||
|
{{ with .Params.Description }}
|
||||||
|
<div class="post-excerpt">{{ . }}</div>
|
||||||
|
{{ end }}
|
||||||
|
|
||||||
|
{{ with .Params.Cover }}
|
||||||
|
<img src="/{{ . }}" class="post-cover" />
|
||||||
|
{{ end }}
|
||||||
|
|
||||||
{{- if .Params.toc }}
|
{{- if .Params.toc }}
|
||||||
<hr />
|
<hr />
|
||||||
<aside id="toc">
|
<aside id="toc">
|
||||||
|
@ -31,10 +39,6 @@
|
||||||
<hr />
|
<hr />
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
|
||||||
{{ with .Params.Cover }}
|
|
||||||
<img src="/{{ . }}" class="post-cover" />
|
|
||||||
{{ end }}
|
|
||||||
|
|
||||||
<div class="post-content">
|
<div class="post-content">
|
||||||
{{ .Content }}
|
{{ .Content }}
|
||||||
</div>
|
</div>
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue