aboutsummaryrefslogtreecommitdiffstats
path: root/layouts/partials
diff options
context:
space:
mode:
authorÓscar Nájera <hello@oscarnajera.com>2018-07-15 14:14:06 +0200
committerÓscar Nájera <hello@oscarnajera.com>2018-07-15 14:14:06 +0200
commitf797661650869f7639b6c60ef9a0703e0f3c3769 (patch)
tree47990711fc609ac2d9a9a3051fd87c86477e0a5e /layouts/partials
parentf32442d10052821726204ad95585882aa1807d77 (diff)
downloadhugo-minimalist-theme-f797661650869f7639b6c60ef9a0703e0f3c3769.tar.gz
hugo-minimalist-theme-f797661650869f7639b6c60ef9a0703e0f3c3769.tar.bz2
hugo-minimalist-theme-f797661650869f7639b6c60ef9a0703e0f3c3769.zip
including pagination
Diffstat (limited to 'layouts/partials')
-rw-r--r--layouts/partials/header.html2
-rw-r--r--layouts/partials/pagination.html15
2 files changed, 16 insertions, 1 deletions
diff --git a/layouts/partials/header.html b/layouts/partials/header.html
index a3df9c6..2a64490 100644
--- a/layouts/partials/header.html
+++ b/layouts/partials/header.html
@@ -40,7 +40,7 @@
<nav class="dt w-100 border-box pa2">
<a class="dtc dib v-mid dim " onclick="w3_open()">
- <i class="fa fa-lg fa-bars"></i>
+ <i class="fa fa-lg fa-bars black"></i>
</a>
<a href="{{ "/" | relLangURL }}" class="dtc v-mid link dim tc">
diff --git a/layouts/partials/pagination.html b/layouts/partials/pagination.html
new file mode 100644
index 0000000..16ad74e
--- /dev/null
+++ b/layouts/partials/pagination.html
@@ -0,0 +1,15 @@
+{{ $pag := $.Paginator }}
+{{ if gt $pag.TotalPages 1 }}
+<div class="center db tc ma4 f6">
+ {{ if $pag.HasPrev }}
+ <a href="{{ $pag.Prev.URL }}" aria-label="Previous" class="dib link dim ph3 pv2 ba br1 ttu">Newer Posts</a>
+ {{ end }}
+
+ {{ range $pag.Pagers }}
+ <a href="{{ .URL }}" class="dib link dim ph3 pv2 b ba br1 {{ if eq . $pag }}bg-blue white{{ end }}">{{ .PageNumber }}</a>
+ {{ end }}
+{{ if $pag.HasNext }}
+ <a href="{{ $pag.Next.URL }}" aria-label="Next" class="dib link dim ph3 pv2 ba br1 ttu">Older posts</a>
+{{ end }}
+</div>
+{{ end }}