{{ define "main" }}
{{ $paginator := .Paginate ((where $.Site.RegularPages "Section" .Section ).ByParam "top") }} {{ range $paginator.Pages }} {{ partial "row.html" . }} {{ end }}
{{ end }} {{ define "pagination" }} {{ $paginator := .Paginate ((where $.Site.RegularPages "Section" .Section ).ByParam "top") }} {{ if $paginator.HasPrev }}
  • < Prev
  • {{ else }}
  • < Prev
  • {{ end }} {{ $current_num := $paginator.PageNumber }} {{ range (seq 1 $paginator.TotalPages) }} {{ if (eq $current_num .)}}
  • {{.}}
  • {{ else }}
  • {{.}}
  • {{ end }} {{end}} {{ if $paginator.HasNext }}
  • Next >
  • {{ else }}
  • Next >
  • {{ end }} {{ end }}