diff --git a/.gitignore b/.gitignore index f0401dffe..0eea1a1ec 100644 --- a/.gitignore +++ b/.gitignore @@ -9,3 +9,6 @@ Thumbs.db # Hugo public/ + +# Web Storm +/.idea/ diff --git a/exampleSite/config.toml b/exampleSite/config.toml index c9df3661d..fa3ab9fc5 100644 --- a/exampleSite/config.toml +++ b/exampleSite/config.toml @@ -61,6 +61,3 @@ copyright = "© {year}" name = "blog" title = "Blog" url = "/blog" - - - diff --git a/layouts/_default/list.html b/layouts/_default/list.html index d8d52b68e..3df3ebe78 100644 --- a/layouts/_default/list.html +++ b/layouts/_default/list.html @@ -3,12 +3,12 @@ {{ end }} {{ define "main" }} - -{{ $dateFormat := .Site.Params.dateFormat | default "Jan 2 2006" }} + +{{ $dateFormat := .Site.Params.dateFormat | default "Jan 2 2006" }}
+{{ partial "pagination.html" . }} + {{ end }} diff --git a/layouts/partials/pagination.html b/layouts/partials/pagination.html index 5b1d5d9b5..ed09fb33e 100644 --- a/layouts/partials/pagination.html +++ b/layouts/partials/pagination.html @@ -1,7 +1,14 @@ -
- {{ if .Paginator.HasPrev }} - - {{ end }} {{ if .Paginator.HasNext }} - - {{ end }} -
+{{ if gt .Paginator.TotalPages 1}} + + +{{ end }} +