@everymatrix/helper-pagination 0.1.24 → 1.0.69

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.
Files changed (50) hide show
  1. package/dist/cjs/app-globals-3a1e7e63.js +5 -0
  2. package/dist/cjs/helper-pagination.cjs.entry.js +197 -201
  3. package/dist/cjs/helper-pagination.cjs.js +17 -11
  4. package/dist/cjs/index-015efb63.js +1169 -0
  5. package/dist/cjs/loader.cjs.js +7 -13
  6. package/dist/collection/collection-manifest.json +3 -3
  7. package/dist/collection/components/helper-pagination/helper-pagination.css +4 -7
  8. package/dist/collection/components/helper-pagination/helper-pagination.js +386 -352
  9. package/dist/collection/components/helper-pagination/index.js +1 -0
  10. package/dist/collection/utils/locale.utils.js +39 -27
  11. package/dist/collection/utils/utils.js +5 -5
  12. package/dist/esm/app-globals-0f993ce5.js +3 -0
  13. package/dist/esm/helper-pagination.entry.js +197 -201
  14. package/dist/esm/helper-pagination.js +14 -11
  15. package/dist/esm/index-3d52300b.js +1142 -0
  16. package/dist/esm/loader.js +7 -13
  17. package/dist/helper-pagination/helper-pagination.esm.js +1 -1
  18. package/dist/helper-pagination/p-083e9b0c.entry.js +1 -0
  19. package/dist/helper-pagination/p-7b10b966.js +2 -0
  20. package/dist/helper-pagination/p-e1255160.js +1 -0
  21. package/dist/stencil.config.dev.js +17 -0
  22. package/dist/stencil.config.js +14 -19
  23. package/dist/types/Users/raul.vasile/workspace/everymatrix/widgets-monorepo/packages/stencil/helper-pagination/.stencil/packages/stencil/helper-pagination/stencil.config.d.ts +2 -0
  24. package/dist/types/Users/raul.vasile/workspace/everymatrix/widgets-monorepo/packages/stencil/helper-pagination/.stencil/packages/stencil/helper-pagination/stencil.config.dev.d.ts +2 -0
  25. package/dist/types/components/helper-pagination/helper-pagination.d.ts +93 -77
  26. package/dist/types/components/helper-pagination/index.d.ts +1 -0
  27. package/dist/types/components.d.ts +52 -13
  28. package/dist/types/stencil-public-runtime.d.ts +142 -33
  29. package/loader/cdn.js +1 -3
  30. package/loader/index.cjs.js +1 -3
  31. package/loader/index.d.ts +13 -1
  32. package/loader/index.es2017.js +1 -3
  33. package/loader/index.js +1 -3
  34. package/loader/package.json +1 -0
  35. package/package.json +9 -2
  36. package/dist/cjs/index-4f0b2d1c.js +0 -1172
  37. package/dist/components/helper-pagination.d.ts +0 -11
  38. package/dist/components/helper-pagination.js +0 -262
  39. package/dist/components/index.d.ts +0 -26
  40. package/dist/components/index.js +0 -1
  41. package/dist/esm/index-fe031733.js +0 -1146
  42. package/dist/esm/polyfills/core-js.js +0 -11
  43. package/dist/esm/polyfills/css-shim.js +0 -1
  44. package/dist/esm/polyfills/dom.js +0 -79
  45. package/dist/esm/polyfills/es5-html-element.js +0 -1
  46. package/dist/esm/polyfills/index.js +0 -34
  47. package/dist/esm/polyfills/system.js +0 -6
  48. package/dist/helper-pagination/p-68c68be2.js +0 -1
  49. package/dist/helper-pagination/p-8258fc5c.entry.js +0 -1
  50. package/dist/types/Users/dragos.bodea/Documents/everymatrix-prjs/stencil/widgets-stencil/packages/helper-pagination/.stencil/packages/helper-pagination/stencil.config.d.ts +0 -2
@@ -1,17 +1,11 @@
1
- import { p as promiseResolve, b as bootstrapLazy } from './index-fe031733.js';
1
+ import { b as bootstrapLazy } from './index-3d52300b.js';
2
+ export { s as setNonce } from './index-3d52300b.js';
3
+ import { g as globalScripts } from './app-globals-0f993ce5.js';
2
4
 
3
- /*
4
- Stencil Client Patch Esm v2.15.2 | MIT Licensed | https://stenciljs.com
5
- */
6
- const patchEsm = () => {
7
- return promiseResolve();
8
- };
9
-
10
- const defineCustomElements = (win, options) => {
11
- if (typeof window === 'undefined') return Promise.resolve();
12
- return patchEsm().then(() => {
13
- return bootstrapLazy([["helper-pagination",[[1,"helper-pagination",{"firstPage":[1540,"first-page"],"previousPage":[1540,"previous-page"],"offset":[1538],"limit":[1538],"total":[1538],"language":[1],"clientStyling":[1,"client-styling"],"clientStylingUrlContent":[1,"client-styling-url-content"],"offsetInt":[32],"lastPage":[32],"limitInt":[32],"totalInt":[32],"pagesArray":[32],"endInt":[32],"limitStylingAppends":[32]}]]]], options);
14
- });
5
+ const defineCustomElements = async (win, options) => {
6
+ if (typeof window === 'undefined') return undefined;
7
+ await globalScripts();
8
+ return bootstrapLazy([["helper-pagination",[[1,"helper-pagination",{"nextPage":[1537,"next-page"],"prevPage":[1537,"prev-page"],"offset":[1538],"limit":[1538],"total":[1538],"language":[1537],"clientStyling":[1537,"client-styling"],"clientStylingUrlContent":[1537,"client-styling-url-content"],"arrowsActive":[1540,"arrows-active"],"secondaryArrowsActive":[1540,"secondary-arrows-active"],"numberedNavActive":[1540,"numbered-nav-active"],"offsetInt":[32],"lastPage":[32],"previousPage":[32],"limitInt":[32],"totalInt":[32],"pagesArray":[32],"endInt":[32],"limitStylingAppends":[32]}]]]], options);
15
9
  };
16
10
 
17
11
  export { defineCustomElements };
@@ -1 +1 @@
1
- import{p as t,b as n}from"./p-68c68be2.js";(()=>{const n=import.meta.url,e={};return""!==n&&(e.resourcesUrl=new URL(".",n).href),t(e)})().then((t=>n([["p-8258fc5c",[[1,"helper-pagination",{firstPage:[1540,"first-page"],previousPage:[1540,"previous-page"],offset:[1538],limit:[1538],total:[1538],language:[1],clientStyling:[1,"client-styling"],clientStylingUrlContent:[1,"client-styling-url-content"],offsetInt:[32],lastPage:[32],limitInt:[32],totalInt:[32],pagesArray:[32],endInt:[32],limitStylingAppends:[32]}]]]],t)));
1
+ import{p as e,b as t}from"./p-7b10b966.js";export{s as setNonce}from"./p-7b10b966.js";import{g as n}from"./p-e1255160.js";(()=>{const t=import.meta.url,n={};return""!==t&&(n.resourcesUrl=new URL(".",t).href),e(n)})().then((async e=>(await n(),t([["p-083e9b0c",[[1,"helper-pagination",{nextPage:[1537,"next-page"],prevPage:[1537,"prev-page"],offset:[1538],limit:[1538],total:[1538],language:[1537],clientStyling:[1537,"client-styling"],clientStylingUrlContent:[1537,"client-styling-url-content"],arrowsActive:[1540,"arrows-active"],secondaryArrowsActive:[1540,"secondary-arrows-active"],numberedNavActive:[1540,"numbered-nav-active"],offsetInt:[32],lastPage:[32],previousPage:[32],limitInt:[32],totalInt:[32],pagesArray:[32],endInt:[32],limitStylingAppends:[32]}]]]],e))));
@@ -0,0 +1 @@
1
+ import{r as t,c as i,h as s}from"./p-7b10b966.js";const e=t=>!!(t.toLowerCase().match(/android/i)||t.toLowerCase().match(/blackberry|bb/i)||t.toLowerCase().match(/iphone|ipad|ipod/i)||t.toLowerCase().match(/windows phone|windows mobile|iemobile|wpdesktop/i)),a=["ro","en","hu","hr"],o={en:{firstPage:"First",previousPage:"Previous",nextPage:"Next",lastPage:"Last"},ro:{firstPage:"Prima",previousPage:"Anterior",nextPage:"Urmatoarea",lastPage:"Ultima"},fr:{firstPage:"First",previousPage:"Previous",nextPage:"Next",lastPage:"Last"},ar:{firstPage:"First",previousPage:"Previous",nextPage:"Next",lastPage:"Last"},hu:{firstPage:"First",previousPage:"Previous",nextPage:"Következő",lastPage:"Last"},hr:{firstPage:"Prva",previousPage:"Prethodna",nextPage:"Slijedeća",lastPage:"Zadnja"}},n=(t,i)=>{const s=i;return o[void 0!==s&&a.includes(s)?s:"en"][t]},h=class{constructor(s){t(this,s),this.hpPageChange=i(this,"hpPageChange",7),this.userAgent=window.navigator.userAgent,this.currentPage=1,this.navigateTo=t=>{switch(t){case"firstPage":this.offsetInt=0;break;case"lastPage":this.offsetInt=this.endInt*this.limitInt;break;case"previousPage":this.offsetInt-=this.limitInt;break;case"nextPage":this.offsetInt+=this.limitInt;break;case"fivePagesBack":this.offsetInt-=5*this.limitInt,this.offsetInt=this.offsetInt<=0?0:this.offsetInt;break;case"fivePagesForward":this.offsetInt+=5*this.limitInt,this.offsetInt=this.offsetInt/this.limitInt>=this.endInt?this.endInt*this.limitInt:this.offsetInt}this.previousPage=!!this.offsetInt,this.hpPageChange.emit({offset:this.offsetInt,limit:this.limitInt,total:this.totalInt})},this.paginationNavigation=(t,i)=>{this.previousPage=!0,isNaN(t)?0===i&&this.currentPage<=4?this.navigateTo("firstPage"):0===i&&this.currentPage>4?this.navigateTo("fivePagesBack"):4===i&&this.endInt-this.currentPage>=2&&this.navigateTo("fivePagesForward"):1===t?(this.offsetInt=t-1,this.previousPage=!1):this.offsetInt=(t-1)*this.limitInt,this.hpPageChange.emit({offset:this.offsetInt,limit:this.limitInt,total:this.totalInt})},this.setClientStyling=()=>{let t=document.createElement("style");t.innerHTML=this.clientStyling,this.stylingContainer.prepend(t)},this.setClientStylingURL=()=>{let t=document.createElement("style");setTimeout((()=>{t.innerHTML=this.clientStylingUrlContent,this.stylingContainer.prepend(t)}),1)},this.nextPage="",this.prevPage="",this.offset=0,this.limit=1,this.total=1,this.language="en",this.clientStyling="",this.clientStylingUrlContent="",this.arrowsActive=void 0,this.secondaryArrowsActive=void 0,this.numberedNavActive=void 0,this.offsetInt=void 0,this.lastPage=!1,this.previousPage=!1,this.limitInt=void 0,this.totalInt=void 0,this.pagesArray=[],this.endInt=0,this.limitStylingAppends=!1}componentWillRender(){this.offsetInt=this.offset,this.limitInt=this.limit,this.currentPage=this.offsetInt/this.limitInt+1,this.limitInt=this.limit,this.totalInt=this.total,this.endInt=Math.ceil(this.totalInt/this.limitInt)-1,this.lastPage=!(this.offsetInt>=this.endInt*this.limitInt),1==this.currentPage||2==this.currentPage?(this.pagesArray=Array.from({length:4},((t,i)=>i+1)),this.pagesArray.push("...")):this.currentPage>=3&&this.endInt-this.currentPage>=2?(this.pagesArray=Array.from({length:3},((t,i)=>this.currentPage+i-1)),this.pagesArray.push("..."),this.pagesArray.unshift("...")):this.endInt-this.currentPage<3&&(this.pagesArray=Array.from({length:4},((t,i)=>this.endInt-2+i)),this.pagesArray.unshift("..."))}componentDidRender(){!this.limitStylingAppends&&this.stylingContainer&&(this.clientStyling&&this.setClientStyling(),this.clientStylingUrlContent&&this.setClientStylingURL(),this.limitStylingAppends=!0)}render(){let t=s("ul",{class:"PaginationArea"},this.pagesArray.map(((t,i)=>s("li",{class:"PaginationItem"+(t===this.currentPage?" ActiveItem":" ")+" "+(e(this.userAgent)?"MobileButtons":"")},s("button",{disabled:t===this.currentPage,onClick:this.paginationNavigation.bind(this,t,i)},s("span",null,t)))))),i=s("button",{disabled:!this.prevPage,onClick:this.navigateTo.bind(this,"firstPage")},s("span",{class:"NavigationButton"},n("firstPage",this.language)),s("span",{class:"NavigationIcon"})),a=s("div",{class:"LeftItems"},this.secondaryArrowsActive&&i,s("button",{disabled:!this.prevPage,onClick:this.navigateTo.bind(this,"previousPage")},s("span",{class:"NavigationButton"},n("previousPage",this.language)),s("span",{class:"NavigationIcon"})));e(this.userAgent)&&(a=s("div",{class:"LeftItems"},s("button",{disabled:!this.prevPage,onClick:this.navigateTo.bind(this,"previousPage")},s("span",{class:"NavigationButton"},n("previousPage",this.language)),s("span",{class:"NavigationIcon"}))));let o=s("button",{disabled:!this.nextPage,onClick:this.navigateTo.bind(this,"lastPage")},s("span",{class:"NavigationButton"},n("lastPage",this.language)),s("span",{class:"NavigationIcon"})),h=s("div",{class:"RightItems"},s("button",{disabled:!this.nextPage,onClick:this.navigateTo.bind(this,"nextPage")},s("span",{class:"NavigationButton"},n("nextPage",this.language)),s("span",{class:"NavigationIcon"})),this.secondaryArrowsActive&&o);return e(this.userAgent)&&(h=s("div",{class:"RightItems"},s("button",{disabled:!this.nextPage,onClick:this.navigateTo.bind(this,"nextPage")},s("span",{class:"NavigationButton"},n("nextPage",this.language)),s("span",{class:"NavigationIcon"})))),s("div",{id:"PaginationContainer",ref:t=>this.stylingContainer=t},this.arrowsActive&&a,this.numberedNavActive&&t,this.arrowsActive&&h)}};h.style='@import url("https://fonts.googleapis.com/css2?family=Roboto:wght@100&display=swap");:host{display:block;font-family:"Roboto", sans-serif}#PaginationContainer{width:100%;margin:20px 0;display:inline-flex;justify-content:space-between;align-items:center}.LeftItems button:not(:first-child),.RightItems button:not(:last-child){margin:0 10px}.LeftItems button,.RightItems button{padding:0;background-color:#009993;border-color:#009993}.PaginationArea{display:inline-flex;gap:10px;list-style:none}.PaginationArea li{margin:0;padding:0}.PaginationArea li button{width:24px;height:24px;display:flex;border:0;padding:0;justify-content:center;align-items:center;background-color:transparent;color:#000;cursor:pointer;pointer-events:all}.PaginationItem.ActiveItem button{background:#009993;border-color:#009993;color:#fff}.PaginationItem.ActiveItem button:disabled{pointer-events:none;cursor:not-allowed}.PaginationItem button:hover,.PaginationItem button:active{background:#009993;border-color:#009993;color:#fff;opacity:0.8}button{width:100px;height:32px;border:1px solid #524e52;border-radius:5px;background:#524e52;color:#fff;font-size:14px;font:inherit;cursor:pointer;transition:all 0.1s linear;text-transform:uppercase;text-align:center;letter-spacing:0}button:hover,button:active{background:#004D4A;border-color:#004D4A}button:disabled{background-color:#ccc;border-color:#ccc;color:#fff;cursor:not-allowed}@media screen and (max-width: 720px){button{width:90px;font-size:14px}}@media screen and (max-width: 480px){button{width:70px;font-size:14px}.paginationArea{padding:5px}}@media screen and (max-width: 320px){button{width:58px;font-size:12px}.paginationArea{padding:5px;gap:5px}}@media (hover: none){.paginationItem button:hover{background:inherit;border-color:inherit;color:inherit;opacity:1}.paginationItem.activeItem button:hover{background:#009993;border-color:#009993;color:#fff}}';export{h as helper_pagination}
@@ -0,0 +1,2 @@
1
+ var e=Object.defineProperty,t=new WeakMap,n=e=>t.get(e),o=(e,n)=>t.set(n.t=e,n),l=(e,t)=>t in e,r=(e,t)=>(0,console.error)(e,t),s=new Map,i=new Map,c="slot-fb{display:contents}slot-fb[hidden]{display:none}",u="undefined"!=typeof window?window:{},a=u.document||{head:{}},f={o:0,l:"",jmp:e=>e(),raf:e=>requestAnimationFrame(e),ael:(e,t,n,o)=>e.addEventListener(t,n,o),rel:(e,t,n,o)=>e.removeEventListener(t,n,o),ce:(e,t)=>new CustomEvent(e,t)},h=e=>Promise.resolve(e),p=(()=>{try{return new CSSStyleSheet,"function"==typeof(new CSSStyleSheet).replaceSync}catch(e){}return!1})(),m=!1,d=[],y=[],$=(e,t)=>n=>{e.push(n),m||(m=!0,t&&4&f.o?v(w):f.raf(w))},b=e=>{for(let t=0;t<e.length;t++)try{e[t](performance.now())}catch(e){r(e)}e.length=0},w=()=>{b(d),b(y),(m=d.length>0)&&f.raf(w)},v=e=>h().then(e),g=$(y,!0),S={},j=e=>"object"==(e=typeof e)||"function"===e;function E(e){var t,n,o;return null!=(o=null==(n=null==(t=e.head)?void 0:t.querySelector('meta[name="csp-nonce"]'))?void 0:n.getAttribute("content"))?o:void 0}((t,n)=>{for(var o in n)e(t,o,{get:n[o],enumerable:!0})})({},{err:()=>k,map:()=>C,ok:()=>O,unwrap:()=>x,unwrapErr:()=>P});var O=e=>({isOk:!0,isErr:!1,value:e}),k=e=>({isOk:!1,isErr:!0,value:e});function C(e,t){if(e.isOk){const n=t(e.value);return n instanceof Promise?n.then((e=>O(e))):O(n)}if(e.isErr)return k(e.value);throw"should never get here"}var M,x=e=>{if(e.isOk)return e.value;throw e.value},P=e=>{if(e.isErr)return e.value;throw e.value},R=(e,t,...n)=>{let o=null,l=!1,r=!1;const s=[],i=t=>{for(let n=0;n<t.length;n++)o=t[n],Array.isArray(o)?i(o):null!=o&&"boolean"!=typeof o&&((l="function"!=typeof e&&!j(o))&&(o+=""),l&&r?s[s.length-1].i+=o:s.push(l?A(null,o):o),r=l)};if(i(n),t){const e=t.className||t.class;e&&(t.class="object"!=typeof e?e:Object.keys(e).filter((t=>e[t])).join(" "))}const c=A(e,null);return c.u=t,s.length>0&&(c.h=s),c},A=(e,t)=>({o:0,p:e,i:t,m:null,h:null,u:null}),T={},D=(e,t,o)=>{const l=(e=>n(e).$hostElement$)(e);return{emit:e=>F(l,t,{bubbles:!!(4&o),composed:!!(2&o),cancelable:!!(1&o),detail:e})}},F=(e,t,n)=>{const o=f.ce(t,n);return e.dispatchEvent(o),o},H=new WeakMap,N=e=>"sc-"+e.$,U=(e,t,n,o,r,s)=>{if(n!==o){let i=l(e,t),c=t.toLowerCase();if("class"===t){const t=e.classList,l=L(n),r=L(o);t.remove(...l.filter((e=>e&&!r.includes(e)))),t.add(...r.filter((e=>e&&!l.includes(e))))}else if("ref"===t)o&&o(e);else if(i||"o"!==t[0]||"n"!==t[1]){const l=j(o);if((i||l&&null!==o)&&!r)try{if(e.tagName.includes("-"))e[t]=o;else{const l=null==o?"":o;"list"===t?i=!1:null!=n&&e[t]==l||(e[t]=l)}}catch(e){}null==o||!1===o?!1===o&&""!==e.getAttribute(t)||e.removeAttribute(t):(!i||4&s||r)&&!l&&e.setAttribute(t,o=!0===o?"":o)}else if(t="-"===t[2]?t.slice(3):l(u,c)?c.slice(2):c[2]+t.slice(3),n||o){const l=t.endsWith(q);t=t.replace(G,""),n&&f.rel(e,t,n,l),o&&f.ael(e,t,o,l)}}},W=/\s/,L=e=>e?e.split(W):[],q="Capture",G=RegExp(q+"$"),V=(e,t,n)=>{const o=11===t.m.nodeType&&t.m.host?t.m.host:t.m,l=e&&e.u||S,r=t.u||S;for(const e of _(Object.keys(l)))e in r||U(o,e,l[e],void 0,n,t.o);for(const e of _(Object.keys(r)))U(o,e,l[e],r[e],n,t.o)};function _(e){return e.includes("ref")?[...e.filter((e=>"ref"!==e)),"ref"]:e}var z=!1,B=(e,t,n)=>{const o=t.h[n];let l,r,s=0;if(null!==o.i)l=o.m=a.createTextNode(o.i);else if(l=o.m=a.createElement(o.p),V(null,o,z),l.getRootNode().querySelector("body"),o.h)for(s=0;s<o.h.length;++s)r=B(e,o,s),r&&l.appendChild(r);return l["s-hn"]=M,l},I=(e,t,n,o,l,r)=>{let s,i=e;for(i.shadowRoot&&i.tagName===M&&(i=i.shadowRoot);l<=r;++l)o[l]&&(s=B(null,n,l),s&&(o[l].m=s,Y(i,s,t)))},J=(e,t,n)=>{for(let o=t;o<=n;++o){const t=e[o];if(t){const e=t.m;X(t),e&&e.remove()}}},K=(e,t)=>e.p===t.p,Q=(e,t,n=!1)=>{const o=t.m=e.m,l=e.h,r=t.h,s=t.i;null===s?(V(e,t,z),null!==l&&null!==r?((e,t,n,o,l=!1)=>{let r,s=0,i=0,c=t.length-1,u=t[0],a=t[c],f=o.length-1,h=o[0],p=o[f];for(;s<=c&&i<=f;)null==u?u=t[++s]:null==a?a=t[--c]:null==h?h=o[++i]:null==p?p=o[--f]:K(u,h)?(Q(u,h,l),u=t[++s],h=o[++i]):K(a,p)?(Q(a,p,l),a=t[--c],p=o[--f]):K(u,p)?(Q(u,p,l),Y(e,u.m,a.m.nextSibling),u=t[++s],p=o[--f]):K(a,h)?(Q(a,h,l),Y(e,a.m,u.m),a=t[--c],h=o[++i]):(r=B(t&&t[i],n,i),h=o[++i],r&&Y(u.m.parentNode,r,u.m));s>c?I(e,null==o[f+1]?null:o[f+1].m,n,o,i,f):i>f&&J(t,s,c)})(o,l,t,r,n):null!==r?(null!==e.i&&(o.textContent=""),I(o,null,t,r,0,r.length-1)):!n&&null!==l&&J(l,0,l.length-1)):e.i!==s&&(o.data=s)},X=e=>{e.u&&e.u.ref&&e.u.ref(null),e.h&&e.h.map(X)},Y=(e,t,n)=>null==e?void 0:e.insertBefore(t,n),Z=(e,t)=>{t&&!e.v&&t["s-p"]&&t["s-p"].push(new Promise((t=>e.v=t)))},ee=(e,t)=>{if(e.o|=16,!(4&e.o))return Z(e,e.S),g((()=>te(e,t)));e.o|=512},te=(e,t)=>{const n=e.t;if(!n)throw Error(`Can't render component <${e.$hostElement$.tagName.toLowerCase()} /> with invalid Stencil runtime! Make sure this imported component is compiled with a \`externalRuntime: true\` flag. For more information, please refer to https://stenciljs.com/docs/custom-elements#externalruntime`);let o;return o=ne(o,(()=>ce(n,"componentWillRender"))),ne(o,(()=>le(e,n,t)))},ne=(e,t)=>oe(e)?e.then(t).catch((e=>{console.error(e),t()})):t(),oe=e=>e instanceof Promise||e&&e.then&&"function"==typeof e.then,le=async(e,t,n)=>{var o;const l=e.$hostElement$,r=l["s-rc"];n&&(e=>{const t=e.j,n=e.$hostElement$,o=t.o,l=((e,t)=>{var n;const o=N(t),l=i.get(o);if(e=11===e.nodeType?e:a,l)if("string"==typeof l){let r,s=H.get(e=e.head||e);if(s||H.set(e,s=new Set),!s.has(o)){{r=a.createElement("style"),r.innerHTML=l;const o=null!=(n=f.O)?n:E(a);null!=o&&r.setAttribute("nonce",o),(!(1&t.o)||1&t.o&&"HEAD"!==e.nodeName)&&e.insertBefore(r,e.querySelector("link"))}4&t.o&&(r.innerHTML+=c),s&&s.add(o)}}else e.adoptedStyleSheets.includes(l)||(e.adoptedStyleSheets=[...e.adoptedStyleSheets,l]);return o})(n.shadowRoot?n.shadowRoot:n.getRootNode(),t);10&o&&2&o&&(n["s-sc"]=l,n.classList.add(l+"-h"))})(e);re(e,t,l,n),r&&(r.map((e=>e())),l["s-rc"]=void 0);{const t=null!=(o=l["s-p"])?o:[],n=()=>se(e);0===t.length?n():(Promise.all(t).then(n),e.o|=4,t.length=0)}},re=(e,t,n,o)=>{try{t=t.render(),e.o&=-17,e.o|=2,((e,t,n=!1)=>{const o=e.$hostElement$,l=e.j,r=e.k||A(null,null),s=(e=>e&&e.p===T)(t)?t:R(null,null,t);if(M=o.tagName,l.C&&(s.u=s.u||{},l.C.map((([e,t])=>s.u[t]=o[e]))),n&&s.u)for(const e of Object.keys(s.u))o.hasAttribute(e)&&!["key","ref","style","class"].includes(e)&&(s.u[e]=o[e]);s.p=null,s.o|=4,e.k=s,s.m=r.m=o.shadowRoot||o,Q(r,s,n)})(e,t,o)}catch(t){r(t,e.$hostElement$)}return null},se=e=>{const t=e.$hostElement$,n=e.S;ce(e.t,"componentDidRender"),64&e.o||(e.o|=64,ue(t),e.M(t),n||ie()),e.v&&(e.v(),e.v=void 0),512&e.o&&v((()=>ee(e,!1))),e.o&=-517},ie=()=>{ue(a.documentElement),v((()=>F(u,"appload",{detail:{namespace:"helper-pagination"}})))},ce=(e,t,n)=>{if(e&&e[t])try{return e[t](n)}catch(e){r(e)}},ue=e=>e.classList.add("hydrated"),ae=(e,t,o)=>{var l,r;const s=e.prototype;if(t.P){const i=Object.entries(null!=(l=t.P)?l:{});if(i.map((([e,[l]])=>{(31&l||2&o&&32&l)&&Object.defineProperty(s,e,{get(){return((e,t)=>n(this).R.get(t))(0,e)},set(o){((e,t,o,l)=>{const r=n(e);if(!r)throw Error(`Couldn't find host element for "${l.$}" as it is unknown to this Stencil runtime. This usually happens when integrating a 3rd party Stencil component with another Stencil component or application. Please reach out to the maintainers of the 3rd party Stencil component or report this on the Stencil Discord server (https://chat.stenciljs.com) or comment on this similar [GitHub issue](https://github.com/ionic-team/stencil/issues/5457).`);const s=r.R.get(t),i=r.o,c=r.t;o=((e,t)=>null==e||j(e)?e:4&t?"false"!==e&&(""===e||!!e):2&t?parseFloat(e):1&t?e+"":e)(o,l.P[t][0]),8&i&&void 0!==s||o===s||Number.isNaN(s)&&Number.isNaN(o)||(r.R.set(t,o),c&&2==(18&i)&&ee(r,!1))})(this,e,o,t)},configurable:!0,enumerable:!0})})),1&o){const o=new Map;s.attributeChangedCallback=function(e,l,r){f.jmp((()=>{var i;const c=o.get(e);if(this.hasOwnProperty(c))r=this[c],delete this[c];else{if(s.hasOwnProperty(c)&&"number"==typeof this[c]&&this[c]==r)return;if(null==c){const o=n(this),s=null==o?void 0:o.o;if(s&&!(8&s)&&128&s&&r!==l){const n=o.t,s=null==(i=t.A)?void 0:i[e];null==s||s.forEach((t=>{null!=n[t]&&n[t].call(n,r,l,e)}))}return}}this[c]=(null!==r||"boolean"!=typeof this[c])&&r}))},e.observedAttributes=Array.from(new Set([...Object.keys(null!=(r=t.A)?r:{}),...i.filter((([e,t])=>15&t[0])).map((([e,n])=>{var l;const r=n[1]||e;return o.set(r,e),512&n[0]&&(null==(l=t.C)||l.push([e,r])),r}))]))}}return e},fe=(e,o={})=>{var l;const h=[],m=o.exclude||[],d=u.customElements,y=a.head,$=y.querySelector("meta[charset]"),b=a.createElement("style"),w=[];let v,g=!0;Object.assign(f,o),f.l=new URL(o.resourcesUrl||"./",a.baseURI).href;let S=!1;if(e.map((e=>{e[1].map((o=>{const l={o:o[0],$:o[1],P:o[2],T:o[3]};4&l.o&&(S=!0),l.P=o[2],l.C=[];const c=l.$,u=class extends HTMLElement{constructor(e){if(super(e),this.hasRegisteredEventListeners=!1,((e,n)=>{const o={o:0,$hostElement$:e,j:n,R:new Map};o.D=new Promise((e=>o.M=e)),e["s-p"]=[],e["s-rc"]=[],t.set(e,o)})(e=this,l),1&l.o)if(e.shadowRoot){if("open"!==e.shadowRoot.mode)throw Error(`Unable to re-use existing shadow root for ${l.$}! Mode is set to ${e.shadowRoot.mode} but Stencil only supports open shadow roots.`)}else e.attachShadow({mode:"open"})}connectedCallback(){this.hasRegisteredEventListeners||(this.hasRegisteredEventListeners=!0),v&&(clearTimeout(v),v=null),g?w.push(this):f.jmp((()=>(e=>{if(!(1&f.o)){const t=n(e),o=t.j,l=()=>{};if(1&t.o)(null==t?void 0:t.t)||(null==t?void 0:t.D)&&t.D.then((()=>{}));else{t.o|=1;{let n=e;for(;n=n.parentNode||n.host;)if(n["s-p"]){Z(t,t.S=n);break}}o.P&&Object.entries(o.P).map((([t,[n]])=>{if(31&n&&e.hasOwnProperty(t)){const n=e[t];delete e[t],e[t]=n}})),(async(e,t,n)=>{let o;if(!(32&t.o)){if(t.o|=32,n.F){const e=(e=>{const t=e.$.replace(/-/g,"_"),n=e.F;if(!n)return;const o=s.get(n);return o?o[t]:import(`./${n}.entry.js`).then((e=>(s.set(n,e),e[t])),r)
2
+ /*!__STENCIL_STATIC_IMPORT_SWITCH__*/})(n);if(e&&"then"in e){const t=()=>{};o=await e,t()}else o=e;if(!o)throw Error(`Constructor for "${n.$}#${t.H}" was not found`);o.isProxied||(ae(o,n,2),o.isProxied=!0);const l=()=>{};t.o|=8;try{new o(t)}catch(e){r(e)}t.o&=-9,l()}else o=e.constructor,customElements.whenDefined(e.localName).then((()=>t.o|=128));if(o&&o.style){let e;"string"==typeof o.style&&(e=o.style);const t=N(n);if(!i.has(t)){const o=()=>{};((e,t,n)=>{let o=i.get(e);p&&n?(o=o||new CSSStyleSheet,"string"==typeof o?o=t:o.replaceSync(t)):o=t,i.set(e,o)})(t,e,!!(1&n.o)),o()}}}const l=t.S,c=()=>ee(t,!0);l&&l["s-rc"]?l["s-rc"].push(c):c()})(e,t,o)}l()}})(this)))}disconnectedCallback(){f.jmp((()=>(async()=>{if(!(1&f.o)){const e=n(this);(null==e?void 0:e.t)||(null==e?void 0:e.D)&&e.D.then((()=>{}))}})()))}componentOnReady(){return n(this).D}};l.F=e[0],m.includes(c)||d.get(c)||(h.push(c),d.define(c,ae(u,l,1)))}))})),h.length>0&&(S&&(b.textContent+=c),b.textContent+=h.sort()+"{visibility:hidden}.hydrated{visibility:inherit}",b.innerHTML.length)){b.setAttribute("data-styles","");const e=null!=(l=f.O)?l:E(a);null!=e&&b.setAttribute("nonce",e),y.insertBefore(b,$?$.nextSibling:y.firstChild)}g=!1,w.length?w.map((e=>e.connectedCallback())):f.jmp((()=>v=setTimeout(ie,30)))},he=e=>f.O=e;export{fe as b,D as c,R as h,h as p,o as r,he as s}
@@ -0,0 +1 @@
1
+ const o=()=>{};export{o as g}
@@ -0,0 +1,17 @@
1
+ import { sass } from "@stencil/sass";
2
+ export const config = {
3
+ namespace: 'helper-pagination',
4
+ taskQueue: 'async',
5
+ sourceMap: true,
6
+ minifyJs: false,
7
+ extras: {
8
+ experimentalImportInjection: true
9
+ },
10
+ plugins: [sass()],
11
+ outputTargets: [
12
+ {
13
+ type: 'www',
14
+ serviceWorker: null // disable service workers
15
+ }
16
+ ]
17
+ };
@@ -1,22 +1,17 @@
1
- import { sass } from '@stencil/sass';
1
+ import { sass } from "@stencil/sass";
2
2
  export const config = {
3
- namespace: 'helper-pagination',
4
- taskQueue: 'async',
5
- plugins: [sass()],
6
- outputTargets: [
7
- {
8
- type: 'dist',
9
- esmLoaderPath: '../loader',
3
+ namespace: 'helper-pagination',
4
+ taskQueue: 'async',
5
+ sourceMap: false,
6
+ minifyJs: true,
7
+ extras: {
8
+ experimentalImportInjection: true
10
9
  },
11
- {
12
- type: 'dist-custom-elements',
13
- },
14
- {
15
- type: 'docs-readme',
16
- },
17
- {
18
- type: 'www',
19
- serviceWorker: null, // disable service workers
20
- },
21
- ],
10
+ plugins: [sass()],
11
+ outputTargets: [
12
+ {
13
+ type: 'dist',
14
+ esmLoaderPath: '../loader'
15
+ }
16
+ ]
22
17
  };
@@ -0,0 +1,2 @@
1
+ import { Config } from '../../../../../../../../../../../../stencil-public-runtime';
2
+ export declare const config: Config;
@@ -0,0 +1,2 @@
1
+ import { Config } from '../../../../../../../../../../../../stencil-public-runtime';
2
+ export declare const config: Config;
@@ -1,80 +1,96 @@
1
1
  import { EventEmitter } from '../../stencil-public-runtime';
2
2
  export declare class HelperPagination {
3
- /**
4
- * First page boolean value - determines if the page is disabled or active
5
- */
6
- firstPage: boolean;
7
- /**
8
- * Previous page boolean value - determines if the page is disabled or active
9
- */
10
- previousPage: boolean;
11
- /**
12
- * The received offset
13
- */
14
- offset: number;
15
- /**
16
- * The received limit for the number of pages
17
- */
18
- limit: number;
19
- /**
20
- * The received total number of pages
21
- */
22
- total: number;
23
- /**
24
- * Language
25
- */
26
- language: string;
27
- /**
28
- * Client custom styling via string
29
- */
30
- clientStyling: string;
31
- /**
32
- * Client custom styling via url content
33
- */
34
- clientStylingUrlContent: string;
35
- /**
36
- * Component working variable for offset
37
- */
38
- private offsetInt;
39
- /**
40
- * Component working variable for last page
41
- */
42
- private lastPage;
43
- /**
44
- * Component working variable for limit
45
- */
46
- private limitInt;
47
- /**
48
- * Component working variable for total
49
- */
50
- private totalInt;
51
- /**
52
- * In component working variable for the array of pages
53
- */
54
- private pagesArray;
55
- /**
56
- * In component working variable for last page
57
- */
58
- private endInt;
59
- private userAgent;
60
- currentPage: number;
61
- /**
62
- * Event that handles the navigation, updating the offset, limit and total values
63
- */
64
- hpPageChange: EventEmitter<any>;
65
- private limitStylingAppends;
66
- private stylingContainer;
67
- /**
68
- * Navigation logic
69
- */
70
- navigateTo: (navigationPage: string) => void;
71
- /**
72
- * Handle navigation from here
73
- */
74
- paginationNavigation: (pageNumber: number, index: any) => void;
75
- componentWillRender(): void;
76
- componentDidRender(): void;
77
- setClientStyling: () => void;
78
- setClientStylingURL: () => void;
79
- render(): any;
3
+ /**
4
+ * Next page string value - determines if the next page is disabled or active
5
+ */
6
+ nextPage: string;
7
+ /**
8
+ * Previous page string value - determines if the previous page is disabled or active
9
+ */
10
+ prevPage: string;
11
+ /**
12
+ * The received offset
13
+ */
14
+ offset: number;
15
+ /**
16
+ * The received limit for the number of pages
17
+ */
18
+ limit: number;
19
+ /**
20
+ * The received total number of pages
21
+ */
22
+ total: number;
23
+ /**
24
+ * Language
25
+ */
26
+ language: string;
27
+ /**
28
+ * Client custom styling via string
29
+ */
30
+ clientStyling: string;
31
+ /**
32
+ * Client custom styling via url content
33
+ */
34
+ clientStylingUrlContent: string;
35
+ /**
36
+ * Customize pagination: Activate pagination arrows
37
+ */
38
+ arrowsActive: boolean;
39
+ /**
40
+ * Customize pagination: Activate pagination secondary arrows
41
+ */
42
+ secondaryArrowsActive: boolean;
43
+ /**
44
+ * Customize pagination: Activate pagination numbered navigation
45
+ */
46
+ numberedNavActive: boolean;
47
+ /**
48
+ * Component working variable for offset
49
+ */
50
+ private offsetInt;
51
+ /**
52
+ * Component working variable for last page
53
+ */
54
+ lastPage: boolean;
55
+ /**
56
+ * Component working variable for prvious page
57
+ */
58
+ previousPage: boolean;
59
+ /**
60
+ * Component working variable for limit
61
+ */
62
+ private limitInt;
63
+ /**
64
+ * Component working variable for total
65
+ */
66
+ private totalInt;
67
+ /**
68
+ * In component working variable for the array of pages
69
+ */
70
+ private pagesArray;
71
+ /**
72
+ * In component working variable for last page
73
+ */
74
+ private endInt;
75
+ private userAgent;
76
+ currentPage: number;
77
+ /**
78
+ * Event that handles the navigation, updating the offset, limit and total values
79
+ */
80
+ hpPageChange: EventEmitter<any>;
81
+ private limitStylingAppends;
82
+ private stylingContainer;
83
+ /**
84
+ * Navigation logic
85
+ */
86
+ navigateTo: (navigationPage: string) => void;
87
+ /**
88
+ * Handle navigation from here
89
+ */
90
+ paginationNavigation: (pageNumber: number, index: any) => void;
91
+ componentWillRender(): void;
92
+ componentDidRender(): void;
93
+ setClientStyling: () => void;
94
+ setClientStylingURL: () => void;
95
+ render(): any;
80
96
  }
@@ -0,0 +1 @@
1
+ export { HelperPagination } from './helper-pagination';
@@ -7,6 +7,10 @@
7
7
  import { HTMLStencilElement, JSXBase } from "./stencil-public-runtime";
8
8
  export namespace Components {
9
9
  interface HelperPagination {
10
+ /**
11
+ * Customize pagination: Activate pagination arrows
12
+ */
13
+ "arrowsActive": boolean;
10
14
  /**
11
15
  * Client custom styling via string
12
16
  */
@@ -15,10 +19,6 @@ export namespace Components {
15
19
  * Client custom styling via url content
16
20
  */
17
21
  "clientStylingUrlContent": string;
18
- /**
19
- * First page boolean value - determines if the page is disabled or active
20
- */
21
- "firstPage": boolean;
22
22
  /**
23
23
  * Language
24
24
  */
@@ -27,22 +27,49 @@ export namespace Components {
27
27
  * The received limit for the number of pages
28
28
  */
29
29
  "limit": number;
30
+ /**
31
+ * Next page string value - determines if the next page is disabled or active
32
+ */
33
+ "nextPage": string;
34
+ /**
35
+ * Customize pagination: Activate pagination numbered navigation
36
+ */
37
+ "numberedNavActive": boolean;
30
38
  /**
31
39
  * The received offset
32
40
  */
33
41
  "offset": number;
34
42
  /**
35
- * Previous page boolean value - determines if the page is disabled or active
43
+ * Previous page string value - determines if the previous page is disabled or active
36
44
  */
37
- "previousPage": boolean;
45
+ "prevPage": string;
46
+ /**
47
+ * Customize pagination: Activate pagination secondary arrows
48
+ */
49
+ "secondaryArrowsActive": boolean;
38
50
  /**
39
51
  * The received total number of pages
40
52
  */
41
53
  "total": number;
42
54
  }
43
55
  }
56
+ export interface HelperPaginationCustomEvent<T> extends CustomEvent<T> {
57
+ detail: T;
58
+ target: HTMLHelperPaginationElement;
59
+ }
44
60
  declare global {
61
+ interface HTMLHelperPaginationElementEventMap {
62
+ "hpPageChange": any;
63
+ }
45
64
  interface HTMLHelperPaginationElement extends Components.HelperPagination, HTMLStencilElement {
65
+ addEventListener<K extends keyof HTMLHelperPaginationElementEventMap>(type: K, listener: (this: HTMLHelperPaginationElement, ev: HelperPaginationCustomEvent<HTMLHelperPaginationElementEventMap[K]>) => any, options?: boolean | AddEventListenerOptions): void;
66
+ addEventListener<K extends keyof DocumentEventMap>(type: K, listener: (this: Document, ev: DocumentEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void;
67
+ addEventListener<K extends keyof HTMLElementEventMap>(type: K, listener: (this: HTMLElement, ev: HTMLElementEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void;
68
+ addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
69
+ removeEventListener<K extends keyof HTMLHelperPaginationElementEventMap>(type: K, listener: (this: HTMLHelperPaginationElement, ev: HelperPaginationCustomEvent<HTMLHelperPaginationElementEventMap[K]>) => any, options?: boolean | EventListenerOptions): void;
70
+ removeEventListener<K extends keyof DocumentEventMap>(type: K, listener: (this: Document, ev: DocumentEventMap[K]) => any, options?: boolean | EventListenerOptions): void;
71
+ removeEventListener<K extends keyof HTMLElementEventMap>(type: K, listener: (this: HTMLElement, ev: HTMLElementEventMap[K]) => any, options?: boolean | EventListenerOptions): void;
72
+ removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
46
73
  }
47
74
  var HTMLHelperPaginationElement: {
48
75
  prototype: HTMLHelperPaginationElement;
@@ -54,6 +81,10 @@ declare global {
54
81
  }
55
82
  declare namespace LocalJSX {
56
83
  interface HelperPagination {
84
+ /**
85
+ * Customize pagination: Activate pagination arrows
86
+ */
87
+ "arrowsActive"?: boolean;
57
88
  /**
58
89
  * Client custom styling via string
59
90
  */
@@ -62,10 +93,6 @@ declare namespace LocalJSX {
62
93
  * Client custom styling via url content
63
94
  */
64
95
  "clientStylingUrlContent"?: string;
65
- /**
66
- * First page boolean value - determines if the page is disabled or active
67
- */
68
- "firstPage"?: boolean;
69
96
  /**
70
97
  * Language
71
98
  */
@@ -74,6 +101,14 @@ declare namespace LocalJSX {
74
101
  * The received limit for the number of pages
75
102
  */
76
103
  "limit"?: number;
104
+ /**
105
+ * Next page string value - determines if the next page is disabled or active
106
+ */
107
+ "nextPage"?: string;
108
+ /**
109
+ * Customize pagination: Activate pagination numbered navigation
110
+ */
111
+ "numberedNavActive"?: boolean;
77
112
  /**
78
113
  * The received offset
79
114
  */
@@ -81,11 +116,15 @@ declare namespace LocalJSX {
81
116
  /**
82
117
  * Event that handles the navigation, updating the offset, limit and total values
83
118
  */
84
- "onHpPageChange"?: (event: CustomEvent<any>) => void;
119
+ "onHpPageChange"?: (event: HelperPaginationCustomEvent<any>) => void;
120
+ /**
121
+ * Previous page string value - determines if the previous page is disabled or active
122
+ */
123
+ "prevPage"?: string;
85
124
  /**
86
- * Previous page boolean value - determines if the page is disabled or active
125
+ * Customize pagination: Activate pagination secondary arrows
87
126
  */
88
- "previousPage"?: boolean;
127
+ "secondaryArrowsActive"?: boolean;
89
128
  /**
90
129
  * The received total number of pages
91
130
  */