single: Add post description (#165)

usage =>
in post params add : 
    description: "Desc Text."
This commit is contained in:
Weichen Liu 2021-01-02 09:00:20 -08:00 committed by GitHub
parent 5d6de5ecb1
commit 946cc1ffe3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 8 additions and 0 deletions

View File

@ -8,6 +8,11 @@
transform: translateX(-2px) transform: translateX(-2px)
} }
.post-description {
margin-top: 10px;
margin-bottom: 5px;
}
.post-meta { .post-meta {
color: var(--secondary); color: var(--secondary);
font-size: 14px; font-size: 14px;

View File

@ -6,6 +6,9 @@
{{ .Title }} {{ .Title }}
{{- if .Draft }}<div class="entry-isdraft"><sup>&nbsp;&nbsp;[draft]</sup></div>{{- end }} {{- if .Draft }}<div class="entry-isdraft"><sup>&nbsp;&nbsp;[draft]</sup></div>{{- end }}
</h1> </h1>
<div class="post-description">
{{ .Description }}
</div>
{{- if .Params.hideMeta }}{{ else }} {{- if .Params.hideMeta }}{{ else }}
<div class="post-meta"> <div class="post-meta">
{{- partial "post_meta.html" . -}} {{- partial "post_meta.html" . -}}