diff options
author | mms <michal@sapka.me> | 2024-06-21 22:32:41 +0200 |
---|---|---|
committer | mms <michal@sapka.me> | 2024-06-21 22:32:41 +0200 |
commit | d2a176ad04578bec30a0dd3dd207da2130dc9ac9 (patch) | |
tree | e35a566c0decdb2b5872684ce5cfc3f43f7df638 | |
parent | 1085493e434c52c551196733a3ae15c3aa830495 (diff) |
fix: show all in blog list:
-rw-r--r-- | content/blog/2022/_index.md | 9 | ||||
-rw-r--r-- | layouts/blog/list.html | 27 | ||||
-rw-r--r-- | themes/sapka-2024/layouts/_default/taxonomy.html | 0 |
3 files changed, 27 insertions, 9 deletions
diff --git a/content/blog/2022/_index.md b/content/blog/2022/_index.md deleted file mode 100644 index e88d651..0000000 --- a/content/blog/2022/_index.md +++ /dev/null @@ -1,9 +0,0 @@ ---- -title: "Michal's Sapka Webpage" -date: 2022-12-28T23:42:51+01:00 -draft: false -tags: [] -category: msw -noback: true ---- - diff --git a/layouts/blog/list.html b/layouts/blog/list.html new file mode 100644 index 0000000..a0d51e2 --- /dev/null +++ b/layouts/blog/list.html @@ -0,0 +1,27 @@ +{{ define "main" }} +{{ $paginator := .Paginator 10 }} + +{{ range (.Paginate (where .Site.Pages.ByDate "Section" .Section )).Pages }} + {{ partial "partials/article_list_full_item.html" . }} +{{ end }} + +<nav class="blog-pages-list"> + Pages: + {{ if $paginator.HasPrev }} + [ <a href="{{ $paginator.Prev.URL}}">previous</a> ] + {{ end }} + + {{ range seq $paginator.TotalPages }} + {{ if eq . $paginator.PageNumber }} + <span class="current"> {{. }} </span> + {{ else }} + <a href="/blog/page/{{ . }}/">{{ . }}</a> + {{ end }} + {{ end }} + + {{ if $paginator.HasNext }} + [ <a href="{{ $paginator.Next.URL}}">Next</a> ] + {{ end }} +</nav> + +{{end}} diff --git a/themes/sapka-2024/layouts/_default/taxonomy.html b/themes/sapka-2024/layouts/_default/taxonomy.html deleted file mode 100644 index e69de29..0000000 --- a/themes/sapka-2024/layouts/_default/taxonomy.html +++ /dev/null |