mirror of
https://github.com/Mottie/tablesorter.git
synced 2024-11-15 23:54:22 +00:00
Pager: prev & next buttons now disable with 0 filtered pages. Fixes #649
This commit is contained in:
parent
d6666e4999
commit
b1b09f1bb8
@ -121,7 +121,7 @@
|
||||
dis = !!disable,
|
||||
first = ( dis || p.page === 0 ),
|
||||
tp = Math.min( p.totalPages, p.filteredPages ),
|
||||
last = ( dis || (p.page === tp - 1) || p.totalPages === 0 );
|
||||
last = ( dis || (p.page === tp - 1) || tp === 0 );
|
||||
if ( p.updateArrows ) {
|
||||
p.$container.find(p.cssFirst + ',' + p.cssPrev)[ first ? a : r ](d).attr('aria-disabled', first);
|
||||
p.$container.find(p.cssNext + ',' + p.cssLast)[ last ? a : r ](d).attr('aria-disabled', last);
|
||||
|
@ -322,7 +322,7 @@ tsp = ts.pager = {
|
||||
dis = !!disable,
|
||||
first = dis || p.page === 0,
|
||||
tp = Math.min( p.totalPages, p.filteredPages ),
|
||||
last = dis || p.page === tp - 1 || p.totalPages === 0,
|
||||
last = dis || p.page === tp - 1 || tp === 0,
|
||||
wo = c.widgetOptions,
|
||||
s = wo.pager_selectors;
|
||||
if ( wo.pager_updateArrows ) {
|
||||
|
Loading…
Reference in New Issue
Block a user