@visulima/pagination 5.0.0-alpha.1 → 5.0.0-alpha.11

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/CHANGELOG.md CHANGED
@@ -1,3 +1,106 @@
1
+ ## @visulima/pagination [5.0.0-alpha.11](https://github.com/visulima/visulima/compare/@visulima/pagination@5.0.0-alpha.10...@visulima/pagination@5.0.0-alpha.11) (2026-04-22)
2
+
3
+ ### Bug Fixes
4
+
5
+ * Remove JSR configuration generation script and generated jsr.json files ([#616](https://github.com/visulima/visulima/issues/616)) ([533744b](https://github.com/visulima/visulima/commit/533744b103b74896941db5b727173e617a27a63b))
6
+
7
+ ### Miscellaneous Chores
8
+
9
+ * bump engines.node to ^22.14.0 || >=24.10.0 ([c3d0931](https://github.com/visulima/visulima/commit/c3d0931d1504e4f21ebf50ea680cfa7ce4ba15ce))
10
+ * fixed jsr.json ([5d85e51](https://github.com/visulima/visulima/commit/5d85e5179de38e284ec433b14d77c71a1619c8d6))
11
+
12
+ ## @visulima/pagination [5.0.0-alpha.10](https://github.com/visulima/visulima/compare/@visulima/pagination@5.0.0-alpha.9...@visulima/pagination@5.0.0-alpha.10) (2026-04-15)
13
+
14
+ ### Bug Fixes
15
+
16
+ * **api:** resolve eslint and type-safety issues across api packages ([3601491](https://github.com/visulima/visulima/commit/3601491261de56b5cfad87c97daafd458e4ee3b6))
17
+
18
+ ## @visulima/pagination [5.0.0-alpha.9](https://github.com/visulima/visulima/compare/@visulima/pagination@5.0.0-alpha.8...@visulima/pagination@5.0.0-alpha.9) (2026-04-08)
19
+
20
+ ### Bug Fixes
21
+
22
+ * **pagination:** remove unnecessary Number() type conversions ([1393f87](https://github.com/visulima/visulima/commit/1393f8721e3824af7fdf59361ddd1e445bc2bff5))
23
+
24
+ ### Miscellaneous Chores
25
+
26
+ * **api:** remove empty dependency objects from package.json ([f6bfc85](https://github.com/visulima/visulima/commit/f6bfc85c48c973ff8ea0a7db5951794ae0ea3efb))
27
+ * **pagination:** add tsconfig.eslint.json for type-aware linting ([d66266c](https://github.com/visulima/visulima/commit/d66266cf401e974d7dda3418228daa06d6ec7253))
28
+ * **pagination:** apply auto-fix formatting ([343ccc0](https://github.com/visulima/visulima/commit/343ccc01b8e398f11bd592f865dec6d04b3a8fca))
29
+ * **pagination:** apply prettier formatting ([8e4e960](https://github.com/visulima/visulima/commit/8e4e9609ac04bd3aee32ba8b73af49d995849fe2))
30
+ * **pagination:** migrate .prettierrc.cjs to prettier.config.js ([17c14e6](https://github.com/visulima/visulima/commit/17c14e69da0aa3beee75631cb33266fd41060e86))
31
+
32
+ ## @visulima/pagination [5.0.0-alpha.8](https://github.com/visulima/visulima/compare/@visulima/pagination@5.0.0-alpha.7...@visulima/pagination@5.0.0-alpha.8) (2026-03-26)
33
+
34
+ ### Features
35
+
36
+ * **web:** auto-generate packages page from workspace metadata ([623e520](https://github.com/visulima/visulima/commit/623e5207693a7fe720f5f2f179593a3654c880e3))
37
+
38
+ ### Miscellaneous Chores
39
+
40
+ * update homepage URLs to visulima.com/packages/ format ([be42968](https://github.com/visulima/visulima/commit/be42968129df85fb074224435e33135ff44cab91))
41
+
42
+ ## @visulima/pagination [5.0.0-alpha.7](https://github.com/visulima/visulima/compare/@visulima/pagination@5.0.0-alpha.6...@visulima/pagination@5.0.0-alpha.7) (2026-03-26)
43
+
44
+ ### Bug Fixes
45
+
46
+ * **web:** improve build setup with incremental stats caching and prod install ([fe33e75](https://github.com/visulima/visulima/commit/fe33e75827586779b4b3a0c6d57b39f889ee6207))
47
+
48
+ ### Miscellaneous Chores
49
+
50
+ * **pagination:** migrate deps to pnpm catalogs ([ddb084e](https://github.com/visulima/visulima/commit/ddb084e6376edf13378862ea2d2196edcc24d310))
51
+ * **pagination:** update dependencies ([31339af](https://github.com/visulima/visulima/commit/31339afb17bf8e0c3d0b4a4e9d7ec9645db2dda8))
52
+ * visulima website ([#591](https://github.com/visulima/visulima/issues/591)) ([59ab2e2](https://github.com/visulima/visulima/commit/59ab2e2befb03e51cd2088956f83d9b87de6d033))
53
+
54
+ ## @visulima/pagination [5.0.0-alpha.6](https://github.com/visulima/visulima/compare/@visulima/pagination@5.0.0-alpha.5...@visulima/pagination@5.0.0-alpha.6) (2026-03-06)
55
+
56
+ ### Bug Fixes
57
+
58
+ * **pagination:** update packem to 2.0.0-alpha.54 ([6fd896e](https://github.com/visulima/visulima/commit/6fd896ed94b501df1ec85baff72015e5d8112540))
59
+
60
+ ### Documentation
61
+
62
+ * **crud,health-check,pagination:** add comprehensive Fumadocs documentation ([1fc3748](https://github.com/visulima/visulima/commit/1fc3748b2d9b1ef2332b5d38cb6dd2c7c1f78589))
63
+
64
+ ### Miscellaneous Chores
65
+
66
+ * **api:** update dependencies ([f3b6f7c](https://github.com/visulima/visulima/commit/f3b6f7c956e8ae2c0da67773b3790f159c07de29))
67
+ * **pagination:** update dependencies ([b47aee3](https://github.com/visulima/visulima/commit/b47aee327e28ba302f7c60cfc3cae3db5b2a101f))
68
+ * update lock file maintenance ([d83e716](https://github.com/visulima/visulima/commit/d83e71697b75d24704185b66bb521a934d2db02d))
69
+ * year update ([47f4105](https://github.com/visulima/visulima/commit/47f410596ce7190cfea36a073db32e0cec50bbcd))
70
+
71
+ ## @visulima/pagination [5.0.0-alpha.5](https://github.com/visulima/visulima/compare/@visulima/pagination@5.0.0-alpha.4...@visulima/pagination@5.0.0-alpha.5) (2026-01-17)
72
+
73
+ ### Bug Fixes
74
+
75
+ * **jsdoc-open-api:** combine name and description for path-based YAML parsing ([68e7d23](https://github.com/visulima/visulima/commit/68e7d2395ab97de3221892afe03da27688df7569))
76
+
77
+ ## @visulima/pagination [5.0.0-alpha.4](https://github.com/visulima/visulima/compare/@visulima/pagination@5.0.0-alpha.3...@visulima/pagination@5.0.0-alpha.4) (2025-12-27)
78
+
79
+ ### Bug Fixes
80
+
81
+ * **pagination:** update package files ([008ea06](https://github.com/visulima/visulima/commit/008ea06ff573a61eaabbc913f9dbe436b4943d67))
82
+
83
+ ### Miscellaneous Chores
84
+
85
+ * fixed project.json names and schema path ([964722f](https://github.com/visulima/visulima/commit/964722f691db205c7edb9aa6db29e849a647500b))
86
+
87
+ ## @visulima/pagination [5.0.0-alpha.3](https://github.com/visulima/visulima/compare/@visulima/pagination@5.0.0-alpha.2...@visulima/pagination@5.0.0-alpha.3) (2025-12-11)
88
+
89
+ ### Bug Fixes
90
+
91
+ * update package OG images across multiple packages ([f08e4dd](https://github.com/visulima/visulima/commit/f08e4dd2b105ccb29c8412020a9c2be36d6c1e9e))
92
+
93
+ ## @visulima/pagination [5.0.0-alpha.2](https://github.com/visulima/visulima/compare/@visulima/pagination@5.0.0-alpha.1...@visulima/pagination@5.0.0-alpha.2) (2025-12-06)
94
+
95
+ ### Bug Fixes
96
+
97
+ * add new package image, fixed readme rendering on npm, fixed building of packages ([b790ba2](https://github.com/visulima/visulima/commit/b790ba253ea07fef83528fd822a678facf021b5f))
98
+ * update package.json description and keywords ([#578](https://github.com/visulima/visulima/issues/578)) ([154709c](https://github.com/visulima/visulima/commit/154709c05e71d1ffd3e360b27e12febd817912f0))
99
+
100
+ ### Miscellaneous Chores
101
+
102
+ * update @anolilab/semantic-release-pnpm and @anolilab/semantic-release-preset to versions 3.2.2 and 12.1.2 across multiple package.json files for improved compatibility ([3921626](https://github.com/visulima/visulima/commit/3921626141fe5da398749bf0ba675f1596f18afb))
103
+
1
104
  ## @visulima/pagination [5.0.0-alpha.1](https://github.com/visulima/visulima/compare/@visulima/pagination@4.0.5...@visulima/pagination@5.0.0-alpha.1) (2025-12-04)
2
105
 
3
106
  ### ⚠ BREAKING CHANGES
package/LICENSE.md CHANGED
@@ -1,6 +1,6 @@
1
1
  MIT License
2
2
 
3
- Copyright (c) 2025 visulima
3
+ Copyright (c) 2026 visulima
4
4
 
5
5
  Permission is hereby granted, free of charge, to any person obtaining a copy
6
6
  of this software and associated documentation files (the "Software"), to deal
@@ -29,7 +29,7 @@ BSD-3-Clause
29
29
  # Bundled dependencies:
30
30
  ## qs-esm
31
31
  License: BSD-3-Clause
32
- By: Jordan Harband
32
+ By: Payload, Jordan Harband
33
33
  Repository: https://github.com/payloadcms/qs-esm.git
34
34
 
35
35
  > BSD 3-Clause License
package/README.md CHANGED
@@ -1,16 +1,24 @@
1
- <div align="center">
2
- <h3>Visulima pagination</h3>
3
- <p>
4
- Visulima pagination is a simple pagination for node.
1
+ <!-- START_PACKAGE_OG_IMAGE_PLACEHOLDER -->
5
2
 
6
- </p>
7
- </div>
3
+ <a href="https://www.anolilab.com/open-source" align="center">
4
+
5
+ <img src="__assets__/package-og.svg" alt="pagination" />
6
+
7
+ </a>
8
+
9
+ <h3 align="center">Simple Pagination for Node.</h3>
10
+
11
+ <!-- END_PACKAGE_OG_IMAGE_PLACEHOLDER -->
8
12
 
9
13
  <br />
10
14
 
11
15
  <div align="center">
12
16
 
13
- [![typescript-image]][typescript-url] [![npm-image]][npm-url] [![license-image]][license-url]
17
+ [![typescript-image][typescript-badge]][typescript-url]
18
+ [![mit licence][license-badge]][license]
19
+ [![npm downloads][npm-downloads-badge]][npm-downloads]
20
+ [![Chat][chat-badge]][chat]
21
+ [![PRs Welcome][prs-welcome-badge]][prs-welcome]
14
22
 
15
23
  </div>
16
24
 
@@ -85,14 +93,23 @@ If you would like to help take a look at the [list of issues](https://github.com
85
93
  - [Daniel Bannert](https://github.com/prisis)
86
94
  - [All Contributors](https://github.com/visulima/visulima/graphs/contributors)
87
95
 
96
+ ## Made with ❤️ at Anolilab
97
+
98
+ This is an open source project and will always remain free to use. If you think it's cool, please star it 🌟. [Anolilab](https://www.anolilab.com/open-source) is a Development and AI Studio. Contact us at [hello@anolilab.com](mailto:hello@anolilab.com) if you need any help with these technologies or just want to say hi!
99
+
88
100
  ## License
89
101
 
90
- The visulima pagination is open-sourced software licensed under the [MIT][license-url]
102
+ The visulima pagination is open-sourced software licensed under the [MIT][license]
91
103
 
92
- [typescript-image]: https://img.shields.io/badge/Typescript-294E80.svg?style=for-the-badge&logo=typescript
104
+ <!-- badges -->
93
105
 
94
- [typescript-url]: https://www.typescriptlang.org/ "TypeScript" "typescript"
95
- [license-image]: https://img.shields.io/npm/l/@visulima/pagination?color=blueviolet&style=for-the-badge
96
- [license-url]: LICENSE.md "license"
97
- [npm-image]: https://img.shields.io/npm/v/@visulima/pagination/latest.svg?style=for-the-badge&logo=npm
98
- [npm-url]: https://www.npmjs.com/package/@visulima/pagination/v/latest "npm"
106
+ [license-badge]: https://img.shields.io/npm/l/@visulima/pagination?style=for-the-badge
107
+ [license]: https://github.com/visulima/visulima/blob/main/LICENSE
108
+ [npm-downloads-badge]: https://img.shields.io/npm/dm/@visulima/pagination?style=for-the-badge
109
+ [npm-downloads]: https://www.npmjs.com/package/@visulima/pagination
110
+ [prs-welcome-badge]: https://img.shields.io/badge/PRs-welcome-brightgreen.svg?style=for-the-badge
111
+ [prs-welcome]: https://github.com/visulima/visulima/blob/main/.github/CONTRIBUTING.md
112
+ [chat-badge]: https://img.shields.io/discord/932323359193186354.svg?style=for-the-badge
113
+ [chat]: https://discord.gg/TtFJY8xkFK
114
+ [typescript-badge]: https://img.shields.io/badge/Typescript-294E80.svg?style=for-the-badge&logo=typescript
115
+ [typescript-url]: https://www.typescriptlang.org/
package/dist/index.js CHANGED
@@ -1,6 +1,6 @@
1
- import Paginator from './packem_shared/Paginator-B3QHCcfB.js';
1
+ import Paginator from './packem_shared/Paginator-D40bQfqD.js';
2
2
  export { createPaginationMetaSchemaObject, createPaginationSchemaObject } from './packem_shared/createPaginationMetaSchemaObject-AoC1C8S-.js';
3
3
 
4
- const paginate = (page, perPage, total, rows) => new Paginator(total, Number(perPage), Number(page), ...rows);
4
+ const paginate = (page, perPage, total, rows) => new Paginator(total, perPage, page, ...rows);
5
5
 
6
6
  export { Paginator, paginate };
@@ -24,7 +24,7 @@ const hexTable = (function() {
24
24
  return array;
25
25
  })();
26
26
  const limit = 1024;
27
- const encode = function encode2(str, defaultEncoder, charset, kind, format) {
27
+ const encode = function encode2(str, _defaultEncoder, _kind, format) {
28
28
  if (str.length === 0) {
29
29
  return str;
30
30
  }
@@ -34,11 +34,6 @@ const encode = function encode2(str, defaultEncoder, charset, kind, format) {
34
34
  } else if (typeof str !== "string") {
35
35
  string = String(str);
36
36
  }
37
- if (charset === "iso-8859-1") {
38
- return escape(string).replace(/%u[0-9a-f]{4}/gi, function($0) {
39
- return "%26%23" + parseInt($0.slice(2), 16) + "%3B";
40
- });
41
- }
42
37
  let out = "";
43
38
  for (let j = 0; j < string.length; j += limit) {
44
39
  const segment = string.length >= limit ? string.slice(j, j + limit) : string;
@@ -117,8 +112,6 @@ const defaults = {
117
112
  allowDots: false,
118
113
  allowEmptyArrays: false,
119
114
  arrayFormat: "indices",
120
- charset: "utf-8",
121
- charsetSentinel: false,
122
115
  delimiter: "&",
123
116
  encode: true,
124
117
  encodeDotInKeys: false,
@@ -138,7 +131,7 @@ const isNonNullishPrimitive = function isNonNullishPrimitive2(v) {
138
131
  return typeof v === "string" || typeof v === "number" || typeof v === "boolean" || typeof v === "symbol" || typeof v === "bigint";
139
132
  };
140
133
  const sentinel = {};
141
- const _stringify = function stringify2(object, prefix, generateArrayPrefix, commaRoundTrip, allowEmptyArrays, strictNullHandling, skipNulls, encodeDotInKeys, encoder, filter, sort, allowDots, serializeDate2, format, formatter, encodeValuesOnly, charset, sideChannel) {
134
+ const _stringify = function stringify2(object, prefix, generateArrayPrefix, commaRoundTrip, allowEmptyArrays, strictNullHandling, skipNulls, encodeDotInKeys, encoder, filter, sort, allowDots, serializeDate2, format, formatter, encodeValuesOnly, sideChannel) {
142
135
  let obj = object;
143
136
  let tmpSc = sideChannel;
144
137
  let step = 0;
@@ -171,15 +164,15 @@ const _stringify = function stringify2(object, prefix, generateArrayPrefix, comm
171
164
  }
172
165
  if (obj === null) {
173
166
  if (strictNullHandling) {
174
- return encoder && !encodeValuesOnly ? encoder(prefix, defaults.encoder, charset, "key", format) : prefix;
167
+ return encoder && !encodeValuesOnly ? encoder(prefix, defaults.encoder, "key", format) : prefix;
175
168
  }
176
169
  obj = "";
177
170
  }
178
171
  if (isNonNullishPrimitive(obj) || isBuffer(obj)) {
179
172
  if (encoder) {
180
- const keyValue = encodeValuesOnly ? prefix : encoder(prefix, defaults.encoder, charset, "key", format);
173
+ const keyValue = encodeValuesOnly ? prefix : encoder(prefix, defaults.encoder, "key", format);
181
174
  return [
182
- formatter(keyValue) + "=" + formatter(encoder(obj, defaults.encoder, charset, "value", format))
175
+ formatter(keyValue) + "=" + formatter(encoder(obj, defaults.encoder, "value", format))
183
176
  ];
184
177
  }
185
178
  return [formatter(prefix) + "=" + formatter(String(obj))];
@@ -235,7 +228,6 @@ const _stringify = function stringify2(object, prefix, generateArrayPrefix, comm
235
228
  format,
236
229
  formatter,
237
230
  encodeValuesOnly,
238
- charset,
239
231
  valueSideChannel
240
232
  )
241
233
  );
@@ -296,20 +288,12 @@ function stringify(object, opts) {
296
288
  options.format,
297
289
  options.formatter,
298
290
  options.encodeValuesOnly,
299
- options.charset,
300
291
  sideChannel
301
292
  )
302
293
  );
303
294
  }
304
295
  const joined = keys.join(options.delimiter);
305
- let prefix = options.addQueryPrefix === true ? "?" : "";
306
- if (options.charsetSentinel) {
307
- if (options.charset === "iso-8859-1") {
308
- prefix += "utf8=%26%2310003%3B&";
309
- } else {
310
- prefix += "utf8=%E2%9C%93&";
311
- }
312
- }
296
+ const prefix = options.addQueryPrefix === true ? "?" : "";
313
297
  return joined.length > 0 ? prefix + joined : "";
314
298
  }
315
299
 
@@ -319,10 +303,13 @@ class Paginator extends Array {
319
303
  this.totalNumber = totalNumber;
320
304
  this.perPage = perPage;
321
305
  this.currentPage = currentPage;
322
- this.totalNumber = Number(totalNumber);
306
+ this.totalNumber = totalNumber;
323
307
  this.rows = rows;
324
308
  this.isEmpty = this.rows.length === 0;
325
309
  }
310
+ totalNumber;
311
+ perPage;
312
+ currentPage;
326
313
  /**
327
314
  * The first page is always 1
328
315
  */
@@ -448,7 +435,7 @@ class Paginator extends Array {
448
435
  * to cast it to a bigint.
449
436
  */
450
437
  get total() {
451
- return Number(this.totalNumber);
438
+ return this.totalNumber;
452
439
  }
453
440
  }
454
441
 
package/package.json CHANGED
@@ -1,14 +1,18 @@
1
1
  {
2
2
  "name": "@visulima/pagination",
3
- "version": "5.0.0-alpha.1",
3
+ "version": "5.0.0-alpha.11",
4
4
  "description": "Simple Pagination for Node.",
5
5
  "keywords": [
6
6
  "anolilab",
7
+ "visulima",
7
8
  "pagination",
8
9
  "paginator",
9
- "offset"
10
+ "offset",
11
+ "limit",
12
+ "page",
13
+ "paging"
10
14
  ],
11
- "homepage": "https://www.visulima.com/docs/package/pagination",
15
+ "homepage": "https://visulima.com/packages/pagination/",
12
16
  "bugs": {
13
17
  "url": "https://github.com/visulima/visulima/issues"
14
18
  },
@@ -48,7 +52,7 @@
48
52
  "LICENSE.md"
49
53
  ],
50
54
  "engines": {
51
- "node": ">=22.13 <=25.x"
55
+ "node": "^22.14.0 || >=24.10.0"
52
56
  },
53
57
  "os": [
54
58
  "darwin",