Pagination V02

Template Details
Author: Colorlib
Released: September 2026
License: CC BY 3.0
Description
A pill-shaped pager for a job board with 120 listings across 20 pages. The script always shows the first and last page, the pages either side of the current one, and an ellipsis for the gaps, such as 1 … 4 5 6 … 20. Clicking a page re-renders the job list and announces the new range in a status line.
It is plain HTML and CSS plus a few lines of vanilla JavaScript: no jQuery, no Bootstrap files, no plugins, and the download is 61 KB. Use it on its own, or drop it into a Bootstrap 4, 5 or 6 project and it looks the same.
- Page window computed in JavaScript with first, last and neighbours
- Gradient current page marked with aria-current
- Previous and Next disabled at the ends
- Focus stays on the current page after re-rendering
- Live status line with the visible range

