hugo-theme-minima/layouts/_default/single.html
2021-08-29 23:55:45 +08:00

36 lines
No EOL
793 B
HTML

{{ define "main" }}
<main>
<h1 class="my-6">{{ .Title }}</h1>
<div class="mb-3 text-xs">
Posted at &mdash; {{ dateFormat .Site.Params.timeformat .Date }}
{{ if .Draft }}
<span class="ml-1">
DRAFT
</span>
{{ end }}
</div>
<p>{{ .Description | markdownify | safeHTML }}</p>
{{ if .Params.toc }}
{{ partial "toc.html" . }}
{{ end }}
<article class="md">
{{ .Content }}
</article>
</main>
{{ if or .Params.math .Site.Params.math }}
{{ partial "math.html" . }}
{{ end }}
{{ if or .Params.mermaid .Site.Params.mermaid }}
{{ partial "mermaid.html" . }}
{{ end }}
{{ if and .Params.comment (eq .Site.Params.comment "disqus")}}
{{ partial "disqus.html" . }}
{{ end }}
{{ if and .Params.comment (eq .Site.Params.comment "ovo")}}
{{ partial "ovo.html" . }}
{{ end }}
{{ end }}