Add page-size dropdown to pagination controls
This commit is contained in:
@@ -306,6 +306,14 @@
|
||||
<span id="page-info" style="color:var(--text-muted);font-size:0.9rem;"></span>
|
||||
<button id="next-page" class="btn btn-sm btn-secondary" type="button"
|
||||
onclick="currentPage++; applyPagination();" disabled>Next →</button>
|
||||
<select id="page-size-select" onchange="PAGE_SIZE=+this.value||Infinity;currentPage=1;applyPagination();"
|
||||
style="padding:0.2rem 0.4rem;font-size:0.85rem;border:1px solid #cbd5e1;border-radius:4px;">
|
||||
<option value="10">10 / page</option>
|
||||
<option value="25" selected>25 / page</option>
|
||||
<option value="50">50 / page</option>
|
||||
<option value="100">100 / page</option>
|
||||
<option value="">All</option>
|
||||
</select>
|
||||
</div>
|
||||
|
||||
</form>
|
||||
@@ -316,7 +324,7 @@ var selectAll = document.getElementById('select-all');
|
||||
var toolbar = document.getElementById('bulk-toolbar');
|
||||
var countEl = document.getElementById('selected-count');
|
||||
var selectAllBtn = document.getElementById('select-all-btn');
|
||||
var PAGE_SIZE = 50;
|
||||
var PAGE_SIZE = 25;
|
||||
var currentPage = 1;
|
||||
|
||||
function visibleCbs() {
|
||||
|
||||
Reference in New Issue
Block a user