Another batch of important updates and fixes
This commit is contained in:
@@ -677,11 +677,21 @@ function initPagination(paginationRootElIds, onPageChange, currentPage = 1) {
|
||||
|
||||
function initControls(paginationRootElId) {
|
||||
const rootEl = document.getElementById(paginationRootElId)
|
||||
|
||||
if (!rootEl) {
|
||||
return
|
||||
}
|
||||
|
||||
const btnFirstPage = rootEl.querySelector('.first-page')
|
||||
const btnPreviousPage = rootEl.querySelector('.previous-page')
|
||||
const btnNextPage = rootEl.querySelector('.next-page')
|
||||
const btnLastPage = rootEl.querySelector('.last-page')
|
||||
const formEl = rootEl.querySelector('form')
|
||||
|
||||
if (!formEl) {
|
||||
return
|
||||
}
|
||||
|
||||
const pageInputEl = formEl.querySelector('input')
|
||||
const pagesCountDisplayEl = formEl.querySelector('.pages-total')
|
||||
|
||||
|
||||
Reference in New Issue
Block a user