diff --git a/layouts/_default/term.html b/layouts/_default/term.html index 32d7ad81..7d3c0d8e 100644 --- a/layouts/_default/term.html +++ b/layouts/_default/term.html @@ -13,16 +13,31 @@ {{ end }} - {{ range (.Paginate (.Pages.GroupByDate "2006")).PageGroups }} - {{ if $.Params.groupByYear | default ($.Site.Params.list.groupByYear | default true) }} - - {{ .Key }} - - - {{ end }} - {{ range .Pages }} - {{ partial "article-link.html" . }} - {{ end }} + {{ if .Data.Pages }} + + {{ if $.Params.groupByYear | default ($.Site.Params.list.groupByYear | default true) }} + {{ range (.Paginate (.Pages.GroupByDate "2006")).PageGroups }} + + {{ .Key }} + + + {{ range .Pages }} + {{ partial "article-link.html" . }} + {{ end }} + {{ end }} + {{ else }} + {{ range .Paginator.Pages }} + {{ partial "article-link.html" . }} + {{ end }} + {{ end }} + + {{ partial "pagination.html" . }} + {{ else }} + + + {{ i18n "list.no_articles" | emojify }} + + {{ end }} {{ partial "pagination.html" . }}
+ {{ i18n "list.no_articles" | emojify }} +