blog/layouts/posts/single.html

41 lines
1.1 KiB
HTML

{{- define "headExtra" -}}
<meta name="description" content="{{ .Summary }}" />
<meta property="og:title" content="{{ .Site.Title }}: {{ .Title }}" />
<meta property="og:url" content="{{ .Permalink }}" />
<meta property="og:description" content="{{ .Summary }}" />
<meta property="og:type" content="article" />
<meta property="article:published_time" content="{{ .Date.Format "2006-01-02T15:04:05Z07:00" }}" />
{{- end -}}
{{- define "content" -}}
<a href="../">&laquo; back</a>
<h1 style="margin: 0;">{{ .Title }}</h1>
<small style="display: block; margin-bottom: 20px;">
Posted
on {{ .Date.Format "Mon Jan 02, 2006" }}
- {{ .ReadingTime }} min read
</small>
{{ if .Params.toc }}
<div class="toc">
<details>
<summary>Table of Contents</summary>
{{ .TableOfContents }}
</details>
</div>
{{ end }}
<div id="content" class="post-content">{{ .Content }}</div>
<hr />
<small>
Thanks for reading!
{{ if .Params.mastodon }}
Have comments? Discuss this post on <a href="{{ .Params.mastodon }}" target="_blank">Mastodon</a>.
{{ end }}
</small>
{{- end -}}