mirror of
https://github.com/gcushen/hugo-academic.git
synced 2025-07-26 19:15:16 +02:00
post archive: display listings consistent with posts widget (Close #262)
This commit is contained in:
parent
b031608ee4
commit
f42cfe7d1a
3 changed files with 4 additions and 21 deletions
|
@ -1,5 +1,4 @@
|
|||
{{ $post := .post }}
|
||||
{{ $page := .page }}
|
||||
|
||||
<div class="article-list-item" itemscope itemprop="blogPost">
|
||||
{{ $preview := $post.Params.header.preview | default true }}
|
||||
|
|
|
@ -44,7 +44,7 @@
|
|||
|
||||
{{ $show_post := $.Scratch.Get "show_post" }}
|
||||
{{ if ne $show_post "0" }}
|
||||
{{ $params := dict "post" . "page" $page }}
|
||||
{{ $params := dict "post" . }}
|
||||
{{ partial "post_li" $params }}
|
||||
{{end}}
|
||||
|
||||
|
@ -71,7 +71,7 @@
|
|||
|
||||
{{ $show_post := $.Scratch.Get "show_post" }}
|
||||
{{ if ne $show_post "0" }}
|
||||
{{ $params := dict "post" . "page" $page }}
|
||||
{{ $params := dict "post" . }}
|
||||
{{ partial "post_li" $params }}
|
||||
{{end}}
|
||||
|
||||
|
|
|
@ -13,24 +13,8 @@
|
|||
|
||||
{{ $paginator := .Paginate .Data.Pages }}
|
||||
{{ range $paginator.Pages }}
|
||||
<div>
|
||||
{{ if .Params.image }}
|
||||
<a href="{{ .Permalink }}">
|
||||
<img src="{{ $.Site.BaseURL }}img/{{ .Params.image }}" class="article-banner">
|
||||
</a>
|
||||
{{end}}
|
||||
<h2><a href="{{ .Permalink }}">{{ .Title }}</a></h2>
|
||||
{{ partial "article_metadata" (dict "content" . "is_list" 1) }}
|
||||
<div class="article-style"><p>
|
||||
{{ if .Params.summary }}
|
||||
{{ printf "%s" .Params.summary | markdownify }}
|
||||
{{ else if .Truncated }}
|
||||
{{ printf "%s" .Summary | markdownify }}
|
||||
{{ else }}
|
||||
{{ .Content }}
|
||||
{{ end }}
|
||||
</p></div>
|
||||
</div>
|
||||
{{ $params := dict "post" . }}
|
||||
{{ partial "post_li" $params }}
|
||||
{{ end }}
|
||||
|
||||
{{ partial "pagination" . }}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue