Opened 8 years ago
Last modified 8 years ago
#40791 new enhancement
paginate_links outputs unnecessary dots
Reported by: |
|
Owned by: | |
---|---|---|---|
Milestone: | Awaiting Review | Priority: | normal |
Severity: | normal | Version: | 4.7.5 |
Component: | General | Keywords: | |
Focuses: | ui | Cc: |
Description
Steps to reproduce:
A) Call paginate_links with current=2, total=6
B) Call paginate_links with current=5, total=6
(assume defaults for everything else: mid_size=2, end_size=1, show_all=false)
Actual results:
A) [1] ... [3] [4] [5] [6]
B) [1] [2] [3] [4] ... [6]
The output includes dots that are unnecessary because they are taking up space that an actual page link could occupy.
Expected results:
A) [1] [2] [3] [4] [5] [6]
B) [1] [2] [3] [4] [5] [6]
When total <= mid_size + end_size * 2 + 2
, no dots should be included in the pagination output.
Change History (2)
Note: See
TracTickets for help on using
tickets.
Removing the accessibility focus, as per today's accessibility bug scrub. While this could be certainly improved, the dots don't introduce specific accessibility issues. While
paginate_links()
doesn't output fully accessible HTML by default, it can be used in an accessible way using for exampleprev_text
andnext_text
, which is already done in some places in core.