Getting Started
The sequence of numbers assigned to pages on a search results page. Part of the Bolt “Components” CSS framework that powers the Bolt Design System.
Install via NPM
npm install @bolt/components-pagination
Usage
Schema
Name | Type | Value(s) | Description | Default |
---|---|---|---|---|
attributes | object
| |
A Drupal-style attributes object with extra attributes to append to this component. |
N/A |
align | string
|
|
Horizontally align the items. |
center
|
total* | number
| |
Total pages Total pages within the pagination |
N/A |
current* | number
| |
Current page Current page selected |
N/A |
pages* |
array OR object |
|
A keyed array of page item objects where the key is the page number |
N/A |
first | object
|
|
A link object for the first page |
N/A |
previous | object
|
|
A link object for the previous page (e.g. if on page 3, this links to page 2) |
N/A |
next | object
|
|
A link object for the next page (e.g. if on page 3, this links to page 4) |
N/A |
last | object
|
|
A link object for the last page |
N/A |
previousText | string
| |
Previous text Text to be displayed for the previous anchor |
Previous
|
nextText | string
| |
Next text Text to be displayed for the next anchor |
Next
|