@visulima/pagination 3.0.17 → 3.0.19
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 +25 -0
- package/LICENSE.md +10 -10
- package/dist/index.cjs +1 -1
- package/dist/index.mjs +1 -1
- package/dist/shared/Paginator-C0enktNL.cjs +1 -0
- package/dist/shared/Paginator-C6gi23wH.mjs +1 -0
- package/dist/shared/createPaginationMetaSchemaObject-CgcOmsL3.mjs +1 -0
- package/dist/shared/createPaginationMetaSchemaObject-D-0GFE4M.cjs +1 -0
- package/package.json +20 -8
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,28 @@
|
|
|
1
|
+
## @visulima/pagination [3.0.19](https://github.com/visulima/visulima/compare/@visulima/pagination@3.0.18...@visulima/pagination@3.0.19) (2024-09-07)
|
|
2
|
+
|
|
3
|
+
### Bug Fixes
|
|
4
|
+
|
|
5
|
+
* added types support for node10 ([604583f](https://github.com/visulima/visulima/commit/604583fa3c24b950fafad45d17e7a1333040fd76))
|
|
6
|
+
|
|
7
|
+
### Styles
|
|
8
|
+
|
|
9
|
+
* cs fixes ([f5c4af7](https://github.com/visulima/visulima/commit/f5c4af7cfa9fc79b6d3fa60c1e48d88bffab5a08))
|
|
10
|
+
|
|
11
|
+
### Miscellaneous Chores
|
|
12
|
+
|
|
13
|
+
* update dev dependencies ([0738f98](https://github.com/visulima/visulima/commit/0738f9810478bb215ce4b2571dc8874c4c503089))
|
|
14
|
+
* updated dev dependencies ([45c2a76](https://github.com/visulima/visulima/commit/45c2a76bc974ecb2c6b172c3af03373d4cc6a5ce))
|
|
15
|
+
|
|
16
|
+
## @visulima/pagination [3.0.18](https://github.com/visulima/visulima/compare/@visulima/pagination@3.0.17...@visulima/pagination@3.0.18) (2024-08-01)
|
|
17
|
+
|
|
18
|
+
### Bug Fixes
|
|
19
|
+
|
|
20
|
+
* upgraded @visulima/packem ([dc0cb57](https://github.com/visulima/visulima/commit/dc0cb5701b30f3f81404346c909fd4daf891b894))
|
|
21
|
+
|
|
22
|
+
### Miscellaneous Chores
|
|
23
|
+
|
|
24
|
+
* updated dev dependencies ([ac67ec1](https://github.com/visulima/visulima/commit/ac67ec1bcba16175d225958e318199f60b10d179))
|
|
25
|
+
|
|
1
26
|
## @visulima/pagination [3.0.17](https://github.com/visulima/visulima/compare/@visulima/pagination@3.0.16...@visulima/pagination@3.0.17) (2024-07-16)
|
|
2
27
|
|
|
3
28
|
### Bug Fixes
|
package/LICENSE.md
CHANGED
|
@@ -33,24 +33,24 @@ By: Jordan Harband
|
|
|
33
33
|
Repository: https://github.com/payloadcms/qs-esm.git
|
|
34
34
|
|
|
35
35
|
> BSD 3-Clause License
|
|
36
|
-
>
|
|
36
|
+
>
|
|
37
37
|
> Copyright (c) 2014, Nathan LaFreniere and other [contributors](https://github.com/ljharb/qs/graphs/contributors)
|
|
38
38
|
> All rights reserved.
|
|
39
|
-
>
|
|
39
|
+
>
|
|
40
40
|
> Redistribution and use in source and binary forms, with or without
|
|
41
41
|
> modification, are permitted provided that the following conditions are met:
|
|
42
|
-
>
|
|
42
|
+
>
|
|
43
43
|
> 1. Redistributions of source code must retain the above copyright notice, this
|
|
44
44
|
> list of conditions and the following disclaimer.
|
|
45
|
-
>
|
|
45
|
+
>
|
|
46
46
|
> 2. Redistributions in binary form must reproduce the above copyright notice,
|
|
47
47
|
> this list of conditions and the following disclaimer in the documentation
|
|
48
48
|
> and/or other materials provided with the distribution.
|
|
49
|
-
>
|
|
49
|
+
>
|
|
50
50
|
> 3. Neither the name of the copyright holder nor the names of its
|
|
51
51
|
> contributors may be used to endorse or promote products derived from
|
|
52
52
|
> this software without specific prior written permission.
|
|
53
|
-
>
|
|
53
|
+
>
|
|
54
54
|
> THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
|
55
55
|
> AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
56
56
|
> IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
|
@@ -77,19 +77,19 @@ By: Joseph Spencer
|
|
|
77
77
|
Repository: https://github.com/kogosoftwarellc/open-api/tree/master/packages/openapi-types
|
|
78
78
|
|
|
79
79
|
> The MIT License (MIT)
|
|
80
|
-
>
|
|
80
|
+
>
|
|
81
81
|
> Copyright (c) 2018 Kogo Softare LLC
|
|
82
|
-
>
|
|
82
|
+
>
|
|
83
83
|
> Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
84
84
|
> of this software and associated documentation files (the "Software"), to deal
|
|
85
85
|
> in the Software without restriction, including without limitation the rights
|
|
86
86
|
> to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
87
87
|
> copies of the Software, and to permit persons to whom the Software is
|
|
88
88
|
> furnished to do so, subject to the following conditions:
|
|
89
|
-
>
|
|
89
|
+
>
|
|
90
90
|
> The above copyright notice and this permission notice shall be included in
|
|
91
91
|
> all copies or substantial portions of the Software.
|
|
92
|
-
>
|
|
92
|
+
>
|
|
93
93
|
> THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
94
94
|
> IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
95
95
|
> FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
package/dist/index.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var
|
|
1
|
+
"use strict";var o=Object.defineProperty;var t=(e,a)=>o(e,"name",{value:a,configurable:!0});Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("./shared/Paginator-C0enktNL.cjs"),c=require("./shared/createPaginationMetaSchemaObject-D-0GFE4M.cjs");var g=Object.defineProperty,b=t((e,a)=>g(e,"name",{value:a,configurable:!0}),"e");const m=b((e,a,i,r)=>new n.g(i,Number(a),Number(e),...r),"paginate");exports.Paginator=n.g;exports.createPaginationMetaSchemaObject=c.createPaginationMetaSchemaObject;exports.createPaginationSchemaObject=c.createPaginationSchemaObject;exports.paginate=m;
|
package/dist/index.mjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
var
|
|
1
|
+
var o=Object.defineProperty;var t=(a,e)=>o(a,"name",{value:e,configurable:!0});import{g as c}from"./shared/Paginator-C6gi23wH.mjs";import{c as u,a as P}from"./shared/createPaginationMetaSchemaObject-CgcOmsL3.mjs";var i=Object.defineProperty,m=t((a,e)=>i(a,"name",{value:e,configurable:!0}),"e");const p=m((a,e,r,n)=>new c(r,Number(e),Number(a),...n),"paginate");export{c as Paginator,u as createPaginationMetaSchemaObject,P as createPaginationSchemaObject,p as paginate};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";var W=Object.defineProperty;var a=(i,t)=>W(i,"name",{value:t,configurable:!0});Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const G=String.prototype.replace,H=/%20/g,I={RFC1738:"RFC1738",RFC3986:"RFC3986"},J={RFC1738:a(function(i){return G.call(i,H,"+")},"RFC1738"),RFC3986:a(function(i){return String(i)},"RFC3986")},_=I.RFC1738,L=I.RFC3986,X=Array.isArray,p=function(){const i=[];for(let t=0;t<256;++t)i.push("%"+((t<16?"0":"")+t.toString(16)).toUpperCase());return i}(),A=1024,Y=a(function(t,r,e,o,y){if(t.length===0)return t;let g=t;if(typeof t=="symbol"?g=Symbol.prototype.toString.call(t):typeof t!="string"&&(g=String(t)),e==="iso-8859-1")return escape(g).replace(/%u[0-9a-f]{4}/gi,function(h){return"%26%23"+parseInt(h.slice(2),16)+"%3B"});let m="";for(let h=0;h<g.length;h+=A){const u=g.length>=A?g.slice(h,h+A):g,l=[];for(let f=0;f<u.length;++f){let n=u.charCodeAt(f);if(n===45||n===46||n===95||n===126||n>=48&&n<=57||n>=65&&n<=90||n>=97&&n<=122||y===_&&(n===40||n===41)){l[l.length]=u.charAt(f);continue}if(n<128){l[l.length]=p[n];continue}if(n<2048){l[l.length]=p[192|n>>6]+p[128|n&63];continue}if(n<55296||n>=57344){l[l.length]=p[224|n>>12]+p[128|n>>6&63]+p[128|n&63];continue}f+=1,n=65536+((n&1023)<<10|u.charCodeAt(f)&1023),l[l.length]=p[240|n>>18]+p[128|n>>12&63]+p[128|n>>6&63]+p[128|n&63]}m+=l.join("")}return m},"encode"),Z=a(function(t){return!t||typeof t!="object"?!1:!!(t.constructor&&t.constructor.isBuffer&&t.constructor.isBuffer(t))},"isBuffer"),D=a(function(t,r){if(X(t)){const e=[];for(let o=0;o<t.length;o+=1)e.push(r(t[o]));return e}return r(t)},"maybeMap"),V={brackets:a(function(t){return t+"[]"},"brackets"),comma:"comma",indices:a(function(t,r){return t+"["+r+"]"},"indices"),repeat:a(function(t){return t},"repeat")},d=Array.isArray,tt=Array.prototype.push,K=a(function(i,t){tt.apply(i,d(t)?t:[t])},"pushToArray"),et=Date.prototype.toISOString,z=L,R={addQueryPrefix:!1,allowDots:!1,allowEmptyArrays:!1,arrayFormat:"indices",charset:"utf-8",charsetSentinel:!1,delimiter:"&",encode:!0,encodeDotInKeys:!1,encoder:Y,encodeValuesOnly:!1,format:z,formatter:J[z],indices:!1,serializeDate:a(function(t){return et.call(t)},"serializeDate"),skipNulls:!1,strictNullHandling:!1},nt=a(function(t){return typeof t=="string"||typeof t=="number"||typeof t=="boolean"||typeof t=="symbol"||typeof t=="bigint"},"isNonNullishPrimitive"),E={},$=a(function(t,r,e,o,y,g,m,h,u,l,f,n,P,U,b,S,F,w){let s=t,N=w,C=0,B=!1;for(;(N=N.get(E))!==void 0&&!B;){const c=N.get(t);if(C+=1,typeof c<"u"){if(c===C)throw new RangeError("Cyclic object value");B=!0}typeof N.get(E)>"u"&&(C=0)}if(typeof l=="function"?s=l(r,s):s instanceof Date?s=P(s):e==="comma"&&d(s)&&(s=D(s,function(c){return c instanceof Date?P(c):c})),s===null){if(g)return u&&!S?u(r,R.encoder,F,"key",U):r;s=""}if(nt(s)||Z(s)){if(u){const c=S?r:u(r,R.encoder,F,"key",U);return[b(c)+"="+b(u(s,R.encoder,F,"value",U))]}return[b(r)+"="+b(String(s))]}const M=[];if(typeof s>"u")return M;let k;if(e==="comma"&&d(s))S&&u&&(s=D(s,u)),k=[{value:s.length>0?s.join(",")||null:void 0}];else if(d(l))k=l;else{const c=Object.keys(s);k=f?c.sort(f):c}const T=h?r.replace(/\./g,"%2E"):r,j=o&&d(s)&&s.length===1?T+"[]":T;if(y&&d(s)&&s.length===0)return j+"[]";for(let c=0;c<k.length;++c){const x=k[c],O=typeof x=="object"&&typeof x.value<"u"?x.value:s[x];if(m&&O===null)continue;const v=n&&h?x.replace(/\./g,"%2E"):x,Q=d(s)?typeof e=="function"?e(j,v):j:j+(n?"."+v:"["+v+"]");w.set(t,C);const q=new WeakMap;q.set(E,w),K(M,$(O,Q,e,o,y,g,m,h,e==="comma"&&S&&d(s)?null:u,l,f,n,P,U,b,S,F,q))}return M},"stringify"),rt=a(function(t){return R},"normalizeStringifyOptions");function st(i,t){let r=i;const e=rt();let o,y;typeof e.filter=="function"?(y=e.filter,r=y("",r)):d(e.filter)&&(y=e.filter,o=y);const g=[];if(typeof r!="object"||r===null)return"";const m=V[e.arrayFormat],h=m==="comma"&&e.commaRoundTrip;o||(o=Object.keys(r)),e.sort&&o.sort(e.sort);const u=new WeakMap;for(let n=0;n<o.length;++n){const P=o[n];e.skipNulls&&r[P]===null||K(g,$(r[P],P,m,h,e.allowEmptyArrays,e.strictNullHandling,e.skipNulls,e.encodeDotInKeys,e.encode?e.encoder:null,e.filter,e.sort,e.allowDots,e.serializeDate,e.format,e.formatter,e.encodeValuesOnly,e.charset,u))}const l=g.join(e.delimiter);let f=e.addQueryPrefix===!0?"?":"";return e.charsetSentinel&&(e.charset==="iso-8859-1"?f+="utf8=%26%2310003%3B&":f+="utf8=%E2%9C%93&"),l.length>0?f+l:""}a(st,"stringify");var it=Object.defineProperty,ot=a((i,t)=>it(i,"name",{value:t,configurable:!0}),"n");class lt extends Array{static{a(this,"g")}constructor(t,r,e,...o){super(...o),this.totalNumber=t,this.perPage=r,this.currentPage=e,this.totalNumber=Number(t),this.rows=o,this.isEmpty=this.rows.length===0}static{ot(this,"Paginator")}firstPage=1;isEmpty;qs={};rows;url="/";all(){return this.rows}baseUrl(t){return this.url=t,this}getMeta(){return{firstPage:this.firstPage,firstPageUrl:this.getUrl(1),lastPage:this.lastPage,lastPageUrl:this.getUrl(this.lastPage),nextPageUrl:this.getNextPageUrl(),page:this.currentPage,perPage:this.perPage,previousPageUrl:this.getPreviousPageUrl(),total:this.total}}getNextPageUrl(){return this.hasMorePages?this.getUrl(this.currentPage+1):null}getPreviousPageUrl(){return this.currentPage>1?this.getUrl(this.currentPage-1):null}getUrl(t){const r=st({...this.qs,page:t<1?1:t});return`${this.url}?${r}`}getUrlsForRange(t,r){const e=[];for(let o=t;o<=r;o++)e.push({isActive:o===this.currentPage,page:o,url:this.getUrl(o)});return e}queryString(t){return this.qs=t,this}toJSON(){return{data:this.all(),meta:this.getMeta()}}get hasMorePages(){return this.lastPage>this.currentPage}get hasPages(){return this.lastPage!==1}get hasTotal(){return this.total>0}get lastPage(){return Math.max(Math.ceil(this.total/this.perPage),1)}get total(){return Number(this.totalNumber)}}exports.g=lt;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
var W=Object.defineProperty;var a=(i,t)=>W(i,"name",{value:t,configurable:!0});const G=String.prototype.replace,H=/%20/g,I={RFC1738:"RFC1738",RFC3986:"RFC3986"},J={RFC1738:a(function(i){return G.call(i,H,"+")},"RFC1738"),RFC3986:a(function(i){return String(i)},"RFC3986")},_=I.RFC1738,L=I.RFC3986,X=Array.isArray,p=function(){const i=[];for(let t=0;t<256;++t)i.push("%"+((t<16?"0":"")+t.toString(16)).toUpperCase());return i}(),A=1024,Y=a(function(t,r,e,o,y){if(t.length===0)return t;let g=t;if(typeof t=="symbol"?g=Symbol.prototype.toString.call(t):typeof t!="string"&&(g=String(t)),e==="iso-8859-1")return escape(g).replace(/%u[0-9a-f]{4}/gi,function(h){return"%26%23"+parseInt(h.slice(2),16)+"%3B"});let m="";for(let h=0;h<g.length;h+=A){const u=g.length>=A?g.slice(h,h+A):g,l=[];for(let f=0;f<u.length;++f){let n=u.charCodeAt(f);if(n===45||n===46||n===95||n===126||n>=48&&n<=57||n>=65&&n<=90||n>=97&&n<=122||y===_&&(n===40||n===41)){l[l.length]=u.charAt(f);continue}if(n<128){l[l.length]=p[n];continue}if(n<2048){l[l.length]=p[192|n>>6]+p[128|n&63];continue}if(n<55296||n>=57344){l[l.length]=p[224|n>>12]+p[128|n>>6&63]+p[128|n&63];continue}f+=1,n=65536+((n&1023)<<10|u.charCodeAt(f)&1023),l[l.length]=p[240|n>>18]+p[128|n>>12&63]+p[128|n>>6&63]+p[128|n&63]}m+=l.join("")}return m},"encode"),Z=a(function(t){return!t||typeof t!="object"?!1:!!(t.constructor&&t.constructor.isBuffer&&t.constructor.isBuffer(t))},"isBuffer"),O=a(function(t,r){if(X(t)){const e=[];for(let o=0;o<t.length;o+=1)e.push(r(t[o]));return e}return r(t)},"maybeMap"),V={brackets:a(function(t){return t+"[]"},"brackets"),comma:"comma",indices:a(function(t,r){return t+"["+r+"]"},"indices"),repeat:a(function(t){return t},"repeat")},d=Array.isArray,tt=Array.prototype.push,K=a(function(i,t){tt.apply(i,d(t)?t:[t])},"pushToArray"),et=Date.prototype.toISOString,z=L,j={addQueryPrefix:!1,allowDots:!1,allowEmptyArrays:!1,arrayFormat:"indices",charset:"utf-8",charsetSentinel:!1,delimiter:"&",encode:!0,encodeDotInKeys:!1,encoder:Y,encodeValuesOnly:!1,format:z,formatter:J[z],indices:!1,serializeDate:a(function(t){return et.call(t)},"serializeDate"),skipNulls:!1,strictNullHandling:!1},nt=a(function(t){return typeof t=="string"||typeof t=="number"||typeof t=="boolean"||typeof t=="symbol"||typeof t=="bigint"},"isNonNullishPrimitive"),E={},$=a(function(t,r,e,o,y,g,m,h,u,l,f,n,P,U,b,S,F,w){let s=t,N=w,C=0,B=!1;for(;(N=N.get(E))!==void 0&&!B;){const c=N.get(t);if(C+=1,typeof c<"u"){if(c===C)throw new RangeError("Cyclic object value");B=!0}typeof N.get(E)>"u"&&(C=0)}if(typeof l=="function"?s=l(r,s):s instanceof Date?s=P(s):e==="comma"&&d(s)&&(s=O(s,function(c){return c instanceof Date?P(c):c})),s===null){if(g)return u&&!S?u(r,j.encoder,F,"key",U):r;s=""}if(nt(s)||Z(s)){if(u){const c=S?r:u(r,j.encoder,F,"key",U);return[b(c)+"="+b(u(s,j.encoder,F,"value",U))]}return[b(r)+"="+b(String(s))]}const M=[];if(typeof s>"u")return M;let k;if(e==="comma"&&d(s))S&&u&&(s=O(s,u)),k=[{value:s.length>0?s.join(",")||null:void 0}];else if(d(l))k=l;else{const c=Object.keys(s);k=f?c.sort(f):c}const T=h?r.replace(/\./g,"%2E"):r,R=o&&d(s)&&s.length===1?T+"[]":T;if(y&&d(s)&&s.length===0)return R+"[]";for(let c=0;c<k.length;++c){const x=k[c],q=typeof x=="object"&&typeof x.value<"u"?x.value:s[x];if(m&&q===null)continue;const v=n&&h?x.replace(/\./g,"%2E"):x,Q=d(s)?typeof e=="function"?e(R,v):R:R+(n?"."+v:"["+v+"]");w.set(t,C);const D=new WeakMap;D.set(E,w),K(M,$(q,Q,e,o,y,g,m,h,e==="comma"&&S&&d(s)?null:u,l,f,n,P,U,b,S,F,D))}return M},"stringify"),rt=a(function(t){return j},"normalizeStringifyOptions");function st(i,t){let r=i;const e=rt();let o,y;typeof e.filter=="function"?(y=e.filter,r=y("",r)):d(e.filter)&&(y=e.filter,o=y);const g=[];if(typeof r!="object"||r===null)return"";const m=V[e.arrayFormat],h=m==="comma"&&e.commaRoundTrip;o||(o=Object.keys(r)),e.sort&&o.sort(e.sort);const u=new WeakMap;for(let n=0;n<o.length;++n){const P=o[n];e.skipNulls&&r[P]===null||K(g,$(r[P],P,m,h,e.allowEmptyArrays,e.strictNullHandling,e.skipNulls,e.encodeDotInKeys,e.encode?e.encoder:null,e.filter,e.sort,e.allowDots,e.serializeDate,e.format,e.formatter,e.encodeValuesOnly,e.charset,u))}const l=g.join(e.delimiter);let f=e.addQueryPrefix===!0?"?":"";return e.charsetSentinel&&(e.charset==="iso-8859-1"?f+="utf8=%26%2310003%3B&":f+="utf8=%E2%9C%93&"),l.length>0?f+l:""}a(st,"stringify");var it=Object.defineProperty,ot=a((i,t)=>it(i,"name",{value:t,configurable:!0}),"n");class at extends Array{static{a(this,"g")}constructor(t,r,e,...o){super(...o),this.totalNumber=t,this.perPage=r,this.currentPage=e,this.totalNumber=Number(t),this.rows=o,this.isEmpty=this.rows.length===0}static{ot(this,"Paginator")}firstPage=1;isEmpty;qs={};rows;url="/";all(){return this.rows}baseUrl(t){return this.url=t,this}getMeta(){return{firstPage:this.firstPage,firstPageUrl:this.getUrl(1),lastPage:this.lastPage,lastPageUrl:this.getUrl(this.lastPage),nextPageUrl:this.getNextPageUrl(),page:this.currentPage,perPage:this.perPage,previousPageUrl:this.getPreviousPageUrl(),total:this.total}}getNextPageUrl(){return this.hasMorePages?this.getUrl(this.currentPage+1):null}getPreviousPageUrl(){return this.currentPage>1?this.getUrl(this.currentPage-1):null}getUrl(t){const r=st({...this.qs,page:t<1?1:t});return`${this.url}?${r}`}getUrlsForRange(t,r){const e=[];for(let o=t;o<=r;o++)e.push({isActive:o===this.currentPage,page:o,url:this.getUrl(o)});return e}queryString(t){return this.qs=t,this}toJSON(){return{data:this.all(),meta:this.getMeta()}}get hasMorePages(){return this.lastPage>this.currentPage}get hasPages(){return this.lastPage!==1}get hasTotal(){return this.total>0}get lastPage(){return Math.max(Math.ceil(this.total/this.perPage),1)}get total(){return Number(this.totalNumber)}}export{at as g};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
var n=Object.defineProperty;var a=(e,t)=>n(e,"name",{value:t,configurable:!0});var o=Object.defineProperty,i=a((e,t)=>o(e,"name",{value:t,configurable:!0}),"r");const s=i((e="PaginationData")=>({[e]:{properties:{firstPage:{description:"Returns the number for the first page. It is always 1",minimum:0,type:"integer"},firstPageUrl:{description:"The URL for the first page",type:"string"},lastPage:{description:"Returns the value for the last page by taking the total of rows into account",minimum:0,type:"integer"},lastPageUrl:{description:"The URL for the last page",type:"string"},nextPageUrl:{description:"The URL for the next page",type:"string"},page:{description:"Current page number",minimum:1,type:"integer"},perPage:{description:"Returns the value for the limit passed to the paginate method",minimum:0,type:"integer"},previousPageUrl:{description:"The URL for the previous page",type:"string"},total:{description:"Holds the value for the total number of rows in the database",minimum:0,type:"integer"}},type:"object",xml:{name:e}}}),"createPaginationMetaSchemaObject"),m=i((e,t,r="#/components/schemas/PaginationData")=>({[e]:{properties:{data:{items:t,type:"array",xml:{name:"data",wrapped:!0}},meta:{$ref:r}},type:"object",xml:{name:e}}}),"createPaginationSchemaObject");export{m as a,s as c};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";var n=Object.defineProperty;var a=(e,t)=>n(e,"name",{value:t,configurable:!0});Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});var o=Object.defineProperty,i=a((e,t)=>o(e,"name",{value:t,configurable:!0}),"r");const p=i((e="PaginationData")=>({[e]:{properties:{firstPage:{description:"Returns the number for the first page. It is always 1",minimum:0,type:"integer"},firstPageUrl:{description:"The URL for the first page",type:"string"},lastPage:{description:"Returns the value for the last page by taking the total of rows into account",minimum:0,type:"integer"},lastPageUrl:{description:"The URL for the last page",type:"string"},nextPageUrl:{description:"The URL for the next page",type:"string"},page:{description:"Current page number",minimum:1,type:"integer"},perPage:{description:"Returns the value for the limit passed to the paginate method",minimum:0,type:"integer"},previousPageUrl:{description:"The URL for the previous page",type:"string"},total:{description:"Holds the value for the total number of rows in the database",minimum:0,type:"integer"}},type:"object",xml:{name:e}}}),"createPaginationMetaSchemaObject"),s=i((e,t,r="#/components/schemas/PaginationData")=>({[e]:{properties:{data:{items:t,type:"array",xml:{name:"data",wrapped:!0}},meta:{$ref:r}},type:"object",xml:{name:e}}}),"createPaginationSchemaObject");exports.createPaginationMetaSchemaObject=p;exports.createPaginationSchemaObject=s;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@visulima/pagination",
|
|
3
|
-
"version": "3.0.
|
|
3
|
+
"version": "3.0.19",
|
|
4
4
|
"description": "Simple Pagination for Node.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"anolilab",
|
|
@@ -9,9 +9,12 @@
|
|
|
9
9
|
"offset"
|
|
10
10
|
],
|
|
11
11
|
"homepage": "https://www.visulima.com/docs/package/pagination",
|
|
12
|
+
"bugs": {
|
|
13
|
+
"url": "https://github.com/visulima/visulima/issues"
|
|
14
|
+
},
|
|
12
15
|
"repository": {
|
|
13
16
|
"type": "git",
|
|
14
|
-
"url": "https://github.com/visulima/visulima.git",
|
|
17
|
+
"url": "git+https://github.com/visulima/visulima.git",
|
|
15
18
|
"directory": "packages/pagination"
|
|
16
19
|
},
|
|
17
20
|
"funding": [
|
|
@@ -46,6 +49,13 @@
|
|
|
46
49
|
"main": "dist/index.cjs",
|
|
47
50
|
"module": "dist/index.mjs",
|
|
48
51
|
"types": "dist/index.d.ts",
|
|
52
|
+
"typesVersions": {
|
|
53
|
+
"*": {
|
|
54
|
+
"*": [
|
|
55
|
+
"./dist/index.d.ts"
|
|
56
|
+
]
|
|
57
|
+
}
|
|
58
|
+
},
|
|
49
59
|
"files": [
|
|
50
60
|
"dist/**",
|
|
51
61
|
"README.md",
|
|
@@ -57,12 +67,13 @@
|
|
|
57
67
|
"@anolilab/prettier-config": "^5.0.14",
|
|
58
68
|
"@anolilab/semantic-release-pnpm": "^1.1.3",
|
|
59
69
|
"@anolilab/semantic-release-preset": "^9.0.0",
|
|
60
|
-
"@
|
|
61
|
-
"@
|
|
70
|
+
"@arethetypeswrong/cli": "^0.15.4",
|
|
71
|
+
"@babel/core": "^7.25.2",
|
|
72
|
+
"@rushstack/eslint-plugin-security": "^0.8.2",
|
|
62
73
|
"@types/node": "18.19.15",
|
|
63
|
-
"@visulima/packem": "^1.0.0-alpha.
|
|
64
|
-
"@vitest/coverage-v8": "^2.0.
|
|
65
|
-
"@vitest/ui": "^2.0.
|
|
74
|
+
"@visulima/packem": "^1.0.0-alpha.93",
|
|
75
|
+
"@vitest/coverage-v8": "^2.0.5",
|
|
76
|
+
"@vitest/ui": "^2.0.5",
|
|
66
77
|
"conventional-changelog-conventionalcommits": "8.0.0",
|
|
67
78
|
"cross-env": "^7.0.3",
|
|
68
79
|
"esbuild": "0.23.0",
|
|
@@ -79,7 +90,7 @@
|
|
|
79
90
|
"rimraf": "5.0.9",
|
|
80
91
|
"semantic-release": "24.0.0",
|
|
81
92
|
"typescript": "5.4.5",
|
|
82
|
-
"vitest": "^2.0.
|
|
93
|
+
"vitest": "^2.0.5"
|
|
83
94
|
},
|
|
84
95
|
"engines": {
|
|
85
96
|
"node": ">=18.* <=22.*"
|
|
@@ -110,6 +121,7 @@
|
|
|
110
121
|
"build:prod": "cross-env NODE_ENV=production packem build",
|
|
111
122
|
"clean": "rimraf node_modules dist .eslintcache",
|
|
112
123
|
"dev": "pnpm run build --watch",
|
|
124
|
+
"lint:attw": "attw --pack",
|
|
113
125
|
"lint:eslint": "eslint . --ext js,cjs,mjs,jsx,ts,tsx,json,yaml,yml,md,mdx --max-warnings=0 --config .eslintrc.js",
|
|
114
126
|
"lint:eslint:fix": "eslint . --ext js,cjs,mjs,jsx,ts,tsx,json,yaml,yml,md,mdx --max-warnings=0 --config .eslintrc.js --fix",
|
|
115
127
|
"lint:package-json": "publint --strict",
|