{{- with .Paginator -}} {{- $firstTitle := "hidden" -}} {{- $prevTitle := "hidden" -}} {{- $nextTitle := "hidden" -}} {{- $lastTitle := "hidden" -}} {{- $firstHref := "/" -}} {{- $prevHref := "/" -}} {{- $nextHref := "/" -}} {{- $lastHref := "/" -}} {{- if and .HasPrev .First -}} {{- $firstHref = .First.URL | absURL -}} {{- $firstTitle = "Newest" -}} {{- end -}} {{- with .Prev -}} {{- $prevHref = .URL | absURL -}} {{- $prevTitle = "Newer" -}} {{- end -}} {{- if .Next -}} {{- $nextHref = .Next.URL | absURL -}} {{- $nextTitle = "Older" -}} {{- end -}} {{- if and .HasNext .Last -}} {{- $lastHref = .Last.URL | absURL -}} {{- $lastTitle = "Oldest" -}} {{- end -}}