svelte-common 6.17.1 → 6.17.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/pagination.mjs +3 -1
package/package.json
CHANGED
package/src/pagination.mjs
CHANGED
|
@@ -123,6 +123,8 @@ export class Pagination {
|
|
|
123
123
|
set page(n) {
|
|
124
124
|
const numberOfPages = this.numberOfPages;
|
|
125
125
|
|
|
126
|
+
n = Math.floor(n);
|
|
127
|
+
|
|
126
128
|
if (n < 0) {
|
|
127
129
|
n = numberOfPages + n + 1;
|
|
128
130
|
} else {
|
|
@@ -224,7 +226,7 @@ export class Pagination {
|
|
|
224
226
|
nav.setAttribute("tabindex", "0");
|
|
225
227
|
nav.setAttribute("aria-label", "pagination");
|
|
226
228
|
|
|
227
|
-
nav.
|
|
229
|
+
nav.onkeydown = event => {
|
|
228
230
|
const step = event.altKey ? 10 : 1;
|
|
229
231
|
|
|
230
232
|
switch (event.key) {
|