prevent page gaps from appearing where they are not supposed to, fixes #98

This commit is contained in:
byte[] 2020-04-29 23:49:19 -04:00
parent 1e794b11d8
commit 4abd5acd53

View file

@ -19,7 +19,7 @@ defmodule PhilomenaWeb.PaginationView do
def last_page_path(page, route, params), do: page_path(route, params, page.total_pages)
def left_gap?(page) do
page.page_number >= 5
page.page_number >= 7
end
def left_page_numbers(page) do
@ -32,7 +32,7 @@ defmodule PhilomenaWeb.PaginationView do
end
def right_gap?(page) do
page.total_pages - page.page_number >= 5
page.total_pages - page.page_number >= 6
end
def right_page_numbers(page) do