posts: add space bewteen posts (thanks @igufi for patch)

This commit is contained in:
Marcin Mierzejewski 2020-09-29 09:32:46 +02:00
parent 36d4597a80
commit 37763868ca
2 changed files with 10 additions and 6 deletions

View file

@ -7,9 +7,11 @@
{{ range sort .Data.Pages "Date" "desc" }} {{ range sort .Data.Pages "Date" "desc" }}
{{ if not .Params.private }} {{ if not .Params.private }}
<div class="post"> <div class="post">
<p>
<div class="date">{{ .PublishDate.Format "Jan. 2, 2006" }}</div> <div class="date">{{ .PublishDate.Format "Jan. 2, 2006" }}</div>
<h1><a href="{{ .Permalink }}" title="{{ .Title }}">{{ .Title }}</a></h1> <h1><a href="{{ .Permalink }}" title="{{ .Title }}">{{ .Title }}</a></h1>
{{ .Summary }} {{ .Summary }}
</p>
</div> </div>
{{ end }} {{ end }}
{{ end }} {{ end }}

View file

@ -13,9 +13,11 @@ Console is a minimal, responsive and light theme for Hugo inspired by Linux cons
{{ with .Site.GetPage "/posts" }} {{ with .Site.GetPage "/posts" }}
{{ range first 3 (sort .Data.Pages "Date" "desc" (where .Pages ".Params.private" "!=" true))}} {{ range first 3 (sort .Data.Pages "Date" "desc" (where .Pages ".Params.private" "!=" true))}}
<div class="post"> <div class="post">
<p>
<div class="date">{{ .PublishDate.Format "Jan. 2, 2006" }}</div> <div class="date">{{ .PublishDate.Format "Jan. 2, 2006" }}</div>
<h1><a href="{{ .Permalink }}" title="{{ .Title }}">{{ .Title }}</a></h1> <h1><a href="{{ .Permalink }}" title="{{ .Title }}">{{ .Title }}</a></h1>
{{ .Summary }} {{ .Summary }}
</p>
</div> </div>
{{ end }} {{ end }}
{{ end }} {{ end }}