@ganpatiinfo/gids-core-web 2.1.0 → 3.0.0

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 (40) hide show
  1. package/dist/css/elements.css.map +1 -0
  2. package/dist/{index.css → css/index.css} +402 -4
  3. package/dist/css/index.css.map +1 -0
  4. package/dist/custom-elements.json +143 -4
  5. package/dist/gids-icon.d.ts +11 -0
  6. package/dist/gids-icon.js +1 -0
  7. package/dist/gids-toggle-button.d.ts +1 -1
  8. package/dist/gids-toggle-button.js +1 -130
  9. package/dist/index.d.ts +2 -1
  10. package/dist/index.js +1 -5
  11. package/dist/p-CgujYzVX.js +1 -0
  12. package/dist/types/components/html/GidsBaseCard/GidsBaseCard.d.ts +6 -0
  13. package/dist/types/components/html/GidsCard/GidsCard.d.ts +5 -0
  14. package/dist/types/components/html/GidsPagination/GidsPagination.d.ts +7 -0
  15. package/dist/types/components/html/_GidsPaginationItem/GidsPaginationItem.d.ts +7 -0
  16. package/dist/types/components/webComponents/GidsIcon/GidsIcon.d.ts +12 -0
  17. package/dist/types/components.d.ts +48 -2
  18. package/dist/types/index.d.ts +1 -10
  19. package/dist/types/stencil-public-runtime.d.ts +170 -12
  20. package/dist/types/utils/assets.d.ts +6 -0
  21. package/dist-bundled/es/assets-Drv1fXkA.js +73 -0
  22. package/dist-bundled/es/clsx-OuTLNxxd.js +16 -0
  23. package/dist-bundled/es/gids-icon.js +216 -0
  24. package/dist-bundled/es/gids-toggle-button.js +87 -0
  25. package/dist-bundled/es/index.js +22 -0
  26. package/dist-bundled/es/p-CgujYzVX-xo1axnk6.js +465 -0
  27. package/dist-bundled/umd/gids-icon.umd.js +1 -0
  28. package/dist-bundled/umd/gids-toggle-button.umd.js +3 -0
  29. package/dist-bundled/umd/index.umd.js +1 -0
  30. package/dist-bundled/umd-complete/gids-core-web.umd.js +3 -0
  31. package/distPaths.js +34 -0
  32. package/package.json +191 -158
  33. package/scriptUtils.js +6 -0
  34. package/dist/elements.css.map +0 -1
  35. package/dist/gids-toggle-button.js.map +0 -1
  36. package/dist/index.css.map +0 -1
  37. package/dist/index.js.map +0 -1
  38. package/dist/p-C0FfV2mK.js +0 -1134
  39. package/dist/p-C0FfV2mK.js.map +0 -1
  40. /package/dist/{elements.css → css/elements.css} +0 -0
@@ -0,0 +1,3 @@
1
+ (function(E,A){typeof exports=="object"&&typeof module<"u"?A(exports):typeof define=="function"&&define.amd?define(["exports"],A):(E=typeof globalThis<"u"?globalThis:E||self,A(E.gidsCoreWebGidsToggleButton={}))})(this,(function(E){"use strict";function A(e,t,o){const n=typeof HTMLElement<"u"?HTMLElement.prototype:null;for(;e&&e!==n;){const l=Object.getOwnPropertyDescriptor(e,t);if(l&&(!o||l.get))return l;e=Object.getPrototypeOf(e)}}var L,Ne=(e,t)=>{var o;Object.entries((o=t.l.t)!=null?o:{}).map((([n,[l]])=>{if(31&l||32&l){const a=e[n],s=A(Object.getPrototypeOf(e),n,!0)||Object.getOwnPropertyDescriptor(e,n);s&&Object.defineProperty(e,n,{get(){return s.get.call(this)},set(i){s.set.call(this,i)},configurable:!0,enumerable:!0}),t.o.has(n)?e[n]=t.o.get(n):a!==void 0&&(e[n]=a)}}))},x=e=>{if(e.__stencil__getHostRef)return e.__stencil__getHostRef()},ee=(e,t)=>t in e,M=(e,t)=>(0,console.error)(e,t),T=new Map,$=typeof window<"u"?window:{},Le=$.HTMLElement||class{},C={i:0,u:"",jmp:e=>e(),raf:e=>requestAnimationFrame(e),ael:(e,t,o,n)=>e.addEventListener(t,o,n),rel:(e,t,o,n)=>e.removeEventListener(t,o,n),ce:(e,t)=>new CustomEvent(e,t)},z=(()=>{try{return!!$.document.adoptedStyleSheets&&(new CSSStyleSheet,typeof new CSSStyleSheet().replaceSync=="function")}catch{}return!1})(),V=!!z&&!!$.document&&Object.getOwnPropertyDescriptor($.document.adoptedStyleSheets,"length").writable,F=!1,te=[],ne=[],Me=(e,t)=>o=>{e.push(o),F||(F=!0,4&C.i?Y(U):C.raf(U))},oe=e=>{for(let t=0;t<e.length;t++)try{e[t](performance.now())}catch(o){M(o)}e.length=0},U=()=>{oe(te),oe(ne),(F=te.length>0)&&C.raf(U)},Y=e=>Promise.resolve(void 0).then(e),Pe=Me(ne);function De(){const e=this.attachShadow({mode:"open"});L===void 0&&(L=null),L&&(V?e.adoptedStyleSheets.push(L):e.adoptedStyleSheets=[...e.adoptedStyleSheets,L])}var H,j=new WeakMap,se=e=>"sc-"+e.h,Z=e=>(e=typeof e)=="object"||e==="function",O=(e,t,...o)=>{let n=null,l=null,a=!1,s=!1;const i=[],r=u=>{for(let c=0;c<u.length;c++)n=u[c],Array.isArray(n)?r(n):n!=null&&typeof n!="boolean"&&((a=typeof e!="function"&&!Z(n))&&(n=String(n)),a&&s?i[i.length-1].p+=n:i.push(a?I(null,n):n),s=a)};if(r(o),t&&t.key&&(l=t.key),typeof e=="function")return e(t===null?{}:t,i,Te);const d=I(e,null);return d.m=t,i.length>0&&(d.v=i),d.$=l,d},I=(e,t)=>({i:0,S:e,p:t??null,O:null,v:null,m:null,$:null}),le={},Te={forEach:(e,t)=>e.map(re).forEach(t),map:(e,t)=>e.map(re).map(t).map(He)},re=e=>({vattrs:e.m,vchildren:e.v,vkey:e.$,vname:e.j,vtag:e.S,vtext:e.p}),He=e=>{if(typeof e.vtag=="function"){const o={...e.vattrs};return e.vkey&&(o.key=e.vkey),e.vname&&(o.name=e.vname),O(e.vtag,o,...e.vchildren||[])}const t=I(e.vtag,e.vtext);return t.m=e.vattrs,t.v=e.vchildren,t.$=e.vkey,t.j=e.vname,t},ie=(e,t)=>e==null||Z(e)?e:4&t?e!=="false"&&(e===""||!!e):1&t?String(e):e,Ie=(e,t)=>{const o=e;return{emit:n=>ce(o,t,{bubbles:!0,composed:!0,cancelable:!0,detail:n})}},ce=(e,t,o)=>{const n=C.ce(t,o);return e.dispatchEvent(n),n},ae=(e,t,o,n,l,a)=>{if(o===n)return;let s=ee(e,t),i=t.toLowerCase();if(t!=="key"){if(e.__lookupSetter__(t)||t[0]!=="o"||t[1]!=="n"){if(t[0]==="a"&&t.startsWith("attr:")){const r=t.slice(5);let d;{const u=x(e);if(u&&u.l&&u.l.t){const c=u.l.t[r];c&&c[1]&&(d=c[1])}}return d||(d=r.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase()),void(n==null||n===!1?n===!1&&e.getAttribute(d)!==""||e.removeAttribute(d):e.setAttribute(d,n===!0?"":n))}if(t[0]==="p"&&t.startsWith("prop:")){const r=t.slice(5);try{e[r]=n}catch{}return}{const r=Z(n);if((s||r&&n!==null)&&!l)try{if(e.tagName.includes("-"))e[t]!==n&&(e[t]=n);else{const d=n??"";t==="list"?s=!1:o!=null&&e[t]===d||(typeof e.__lookupSetter__(t)=="function"?e[t]=d:e.setAttribute(t,d))}}catch{}n==null||n===!1?n===!1&&e.getAttribute(t)!==""||e.removeAttribute(t):(!s||4&a||l)&&!r&&e.nodeType===1&&e.setAttribute(t,n=n===!0?"":n)}}else if(t=t[2]==="-"?t.slice(3):ee($,i)?i.slice(2):i[2]+t.slice(3),o||n){const r=t.endsWith(de);t=t.replace(Be,""),o&&C.rel(e,t,o,r),n&&C.ael(e,t,n,r)}}},de="Capture",Be=new RegExp(de+"$"),ue=(e,t,o)=>{const n=t.O.nodeType===11&&t.O.host?t.O.host:t.O,l=e&&e.m||{},a=t.m||{};for(const s of fe(Object.keys(l)))s in a||ae(n,s,l[s],void 0,o,t.i);for(const s of fe(Object.keys(a)))ae(n,s,l[s],a[s],o,t.i)};function fe(e){return e.includes("ref")?[...e.filter((t=>t!=="ref")),"ref"]:e}var he=!1,pe=!1,B=(e,t,o)=>{const n=t.v[o];let l,a,s=0;if(n.p!=null)l=n.O=$.document.createTextNode(n.p);else{if(!$.document)throw new Error("You are trying to render a Stencil component in an environment that doesn't support the DOM.");if(l=n.O=$.document.createElement(n.S),ue(null,n,pe),n.v){const i=n.S==="template"?l.content:l;for(s=0;s<n.v.length;++s)a=B(e,n,s),a&&i.appendChild(a)}}return l["s-hn"]=H,l},me=(e,t,o,n,l,a)=>{let s,i=e;for(i.shadowRoot&&i.tagName===H&&(i=i.shadowRoot),o.S==="template"&&(i=i.content);l<=a;++l)n[l]&&(s=B(null,o,l),s&&(n[l].O=s,P(i,s,t)))},ge=(e,t,o)=>{for(let n=t;n<=o;++n){const l=e[n];if(l){const a=l.O;a&&a.remove()}}},G=(e,t,o=!1)=>e.S===t.S&&(o?(o&&!e.$&&t.$&&(e.$=t.$),!0):e.$===t.$),R=(e,t,o=!1)=>{const n=t.O=e.O,l=e.v,a=t.v,s=t.p;s==null?(t.S!=="slot"||he||e.j!==t.j&&(t.O["s-sn"]=t.j||"",(i=>{C.i|=1;const r=i.closest(H.toLowerCase());if(r!=null){const d=Array.from(r.__childNodes||r.childNodes).find((c=>c["s-cr"])),u=Array.from(i.__childNodes||i.childNodes);for(const c of d?u.reverse():u)c["s-sh"]!=null&&(P(r,c,d??null),c["s-sh"]=void 0)}C.i&=-2})(t.O.parentElement)),ue(e,t,pe),l!==null&&a!==null?((i,r,d,u,c=!1)=>{let g,_,w=0,v=0,S=0,m=0,p=r.length-1,f=r[0],b=r[p],h=u.length-1,y=u[0],k=u[h];const Re=d.S==="template"?i.content:i;for(;w<=p&&v<=h;)if(f==null)f=r[++w];else if(b==null)b=r[--p];else if(y==null)y=u[++v];else if(k==null)k=u[--h];else if(G(f,y,c))R(f,y,c),f=r[++w],y=u[++v];else if(G(b,k,c))R(b,k,c),b=r[--p],k=u[--h];else if(G(f,k,c))R(f,k,c),P(Re,f.O,b.O.nextSibling),f=r[++w],k=u[--h];else if(G(b,y,c))R(b,y,c),P(Re,b.O,f.O),b=r[--p],y=u[++v];else{for(S=-1,m=w;m<=p;++m)if(r[m]&&r[m].$!==null&&r[m].$===y.$){S=m;break}S>=0?(_=r[S],_.S!==y.S?g=B(r&&r[v],d,S):(R(_,y,c),r[S]=void 0,g=_.O),y=u[++v]):(g=B(r&&r[v],d,v),y=u[++v]),g&&P(f.O.parentNode,g,f.O)}w>p?me(i,u[h+1]==null?null:u[h+1].O,d,u,v,h):v>h&&ge(r,w,p)})(n,l,t,a,o):a!==null?(e.p!==null&&(n.textContent=""),me(n,null,t,a,0,a.length-1)):!o&&l!==null&&ge(l,0,l.length-1)):e.p!==s&&(n.data=s)},P=(e,t,o)=>e.__insertBefore?e.__insertBefore(t,o):e?.insertBefore(t,o),Ge=(e,t,o=!1)=>{const n=e.$hostElement$,l=e.l,a=e.M||I(null,null);var s;const i=(s=t)&&s.S===le?t:O(null,null,t);if(H=n.tagName,l.k&&(i.m=i.m||{},l.k.forEach((([r,d])=>{i.m[d]=n[r]}))),o&&i.m)for(const r of Object.keys(i.m))n.hasAttribute(r)&&!["key","ref","style","class"].includes(r)&&(i.m[r]=n[r]);i.S=null,i.i|=4,e.M=i,i.O=a.O=n.shadowRoot||n,he=!(!(1&l.i)||128&l.i),R(a,i,o)},ye=(e,t)=>{if(t&&!e.C&&t["s-p"]){const o=t["s-p"].push(new Promise((n=>e.C=()=>{t["s-p"].splice(o-1,1),n()})))}},J=(e,t)=>{if(e.i|=16,4&e.i)return void(e.i|=512);ye(e,e.A);const o=()=>We(e,t);if(!t)return Pe(o);queueMicrotask((()=>{o()}))},We=(e,t)=>{const o=e.$hostElement$,n=o;if(!n)throw new Error(`Can't render component <${o.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 l;return l=D(n,t?"componentWillLoad":"componentWillUpdate",void 0,o),l=be(l,(()=>D(n,"componentWillRender",void 0,o))),be(l,(()=>ze(e,n,t)))},be=(e,t)=>qe(e)?e.then(t).catch((o=>{console.error(o),t()})):t(),qe=e=>e instanceof Promise||e&&e.then&&typeof e.then=="function",ze=async(e,t,o)=>{var n;const l=e.$hostElement$,a=l["s-rc"];o&&(s=>{const i=s.l,r=s.$hostElement$,d=i.i,u=((c,g)=>{var _,w,v;const S=se(g),m=T.get(S);if(!$.document)return S;if(c=c.nodeType===11?c:$.document,m)if(typeof m=="string"){let p,f=j.get(c=c.head||c);if(f||j.set(c,f=new Set),!f.has(S)){p=$.document.createElement("style"),p.textContent=m;const b=(_=C.D)!=null?_:(function(){var h,y,k;return(k=(y=(h=$.document.head)==null?void 0:h.querySelector('meta[name="csp-nonce"]'))==null?void 0:y.getAttribute("content"))!=null?k:void 0})();if(b!=null&&p.setAttribute("nonce",b),!(1&g.i))if(c.nodeName==="HEAD"){const h=c.querySelectorAll("link[rel=preconnect]"),y=h.length>0?h[h.length-1].nextSibling:c.querySelector("style");c.insertBefore(p,y?.parentNode===c?y:null)}else if("host"in c)if(z){const h=new((w=c.defaultView)!=null?w:c.ownerDocument.defaultView).CSSStyleSheet;h.replaceSync(m),V?c.adoptedStyleSheets.unshift(h):c.adoptedStyleSheets=[h,...c.adoptedStyleSheets]}else{const h=c.querySelector("style");h?h.textContent=m+h.textContent:c.prepend(p)}else c.append(p);1&g.i&&c.insertBefore(p,null),4&g.i&&(p.textContent+="slot-fb{display:contents}slot-fb[hidden]{display:none}"),f&&f.add(S)}}else{let p=j.get(c);if(p||j.set(c,p=new Set),!p.has(S)){const f=(v=c.defaultView)!=null?v:c.ownerDocument.defaultView;let b;if(m.constructor===f.CSSStyleSheet)b=m;else{b=new f.CSSStyleSheet;for(let h=0;h<m.cssRules.length;h++)b.insertRule(m.cssRules[h].cssText,h)}V?c.adoptedStyleSheets.push(b):c.adoptedStyleSheets=[...c.adoptedStyleSheets,b],p.add(S)}}return S})(r.shadowRoot?r.shadowRoot:r.getRootNode(),i);10&d&&(r["s-sc"]=u,r.classList.add(u+"-h"))})(e),Ve(e,t,l,o),a&&(a.map((s=>s())),l["s-rc"]=void 0);{const s=(n=l["s-p"])!=null?n:[],i=()=>Fe(e);s.length===0?i():(Promise.all(s).then(i).catch(i),e.i|=4,s.length=0)}},Ve=(e,t,o,n)=>{try{t=t.render(),e.i&=-17,e.i|=2,Ge(e,t,n)}catch(l){M(l,e.$hostElement$)}return null},Fe=e=>{const t=e.$hostElement$,o=t,n=e.A;D(o,"componentDidRender",void 0,t),64&e.i?D(o,"componentDidUpdate",void 0,t):(e.i|=64,Ye(t),D(o,"componentDidLoad",void 0,t),e.L(t),n||Ue()),e.C&&(e.C(),e.C=void 0),512&e.i&&Y((()=>J(e,!1))),e.i&=-517},Ue=()=>{Y((()=>ce($,"appload",{detail:{namespace:"gids-core-web"}})))},D=(e,t,o,n)=>{if(e&&e[t])try{return e[t](o)}catch(l){M(l,n)}},Ye=e=>e.classList.add("hydrated"),Se=(e,t,o,n)=>{const l=x(e);if(!l)return;const a=e,s=l.o.get(t),i=l.i,r=a;o=ie(o,n.t[t][0]);const d=Number.isNaN(s)&&Number.isNaN(o);if(o!==s&&!d&&(l.o.set(t,o),2&i)){if(r.componentShouldUpdate&&r.componentShouldUpdate(o,s,t)===!1&&!(16&i))return;16&i||J(l,!1)}},Ze=(e,t)=>{var o,n;const l=e.prototype;if(t.t){const a=Object.entries((o=t.t)!=null?o:{});a.map((([s,[i]])=>{if(31&i||32&i){const{get:r,set:d}=A(l,s)||{};r&&(t.t[s][0]|=2048),d&&(t.t[s][0]|=4096),Object.defineProperty(l,s,{get(){return r?r.apply(this):(u=s,x(this).o.get(u));var u},configurable:!0,enumerable:!0}),Object.defineProperty(l,s,{set(u){const c=x(this);if(c){if(d)return(32&i?this[s]:c.$hostElement$[s])===void 0&&c.o.get(s)&&(u=c.o.get(s)),d.apply(this,[ie(u,i)]),void Se(this,s,u=32&i?this[s]:c.$hostElement$[s],t);Se(this,s,u,t)}}})}}));{const s=new Map;l.attributeChangedCallback=function(i,r,d){C.jmp((()=>{var u;const c=s.get(i),g=x(this);if(this.hasOwnProperty(c),l.hasOwnProperty(c)&&typeof this[c]=="number"&&this[c]==d)return;if(c==null){const m=g?.i;if(g&&m&&!(8&m)&&d!==r){const p=this,f=(u=t.R)==null?void 0:u[i];f?.forEach((b=>{const[[h,y]]=Object.entries(b);p[h]!=null&&(128&m||1&y)&&p[h].call(p,d,r,i)}))}return}const _=a.find((([m])=>m===c)),w=_&&4&_[1][0],v=w&&d===null&&this[c]===void 0;w&&(d=d!==null&&d!=="false");const S=Object.getOwnPropertyDescriptor(l,c);v||d==this[c]||S.get&&!S.set||(this[c]=d)}))},e.observedAttributes=Array.from(new Set([...Object.keys((n=t.R)!=null?n:{}),...a.filter((([i,r])=>31&r[0])).map((([i,r])=>{var d;const u=r[1]||i;return s.set(u,i),512&r[0]&&((d=t.k)==null||d.push([i,u])),u}))]))}}return e},Je=(e,t)=>{const o={i:t[0],h:t[1]};try{o.t=t[2],o.k=[];const n=e.prototype.connectedCallback,l=e.prototype.disconnectedCallback;return Object.assign(e.prototype,{__hasHostListenerAttached:!1,__registerHost(){((a,s)=>{const i={i:0,$hostElement$:a,l:s,o:new Map,_:new Map};i.H=new Promise((d=>i.L=d)),a["s-p"]=[],a["s-rc"]=[];const r=i;a.__stencil__getHostRef=()=>r,512&s.i&&Ne(a,i)})(this,o)},connectedCallback(){if(!this.__hasHostListenerAttached){if(!x(this))return;this.__hasHostListenerAttached=!0}(a=>{if(!(1&C.i)){const s=x(a);if(!s)return;const i=s.l;if(1&s.i)s?.P||s?.H&&s.H.then((()=>{}));else{s.i|=1;{let r=a;for(;r=r.parentNode||r.host;)if(r["s-p"]){ye(s,s.A=r);break}}i.t&&Object.entries(i.t).map((([r,[d]])=>{if(31&d&&Object.prototype.hasOwnProperty.call(a,r)){const u=a[r];delete a[r],a[r]=u}})),(async(r,d,u)=>{let c;try{if(!(32&d.i)&&(d.i|=32,c=r.constructor,customElements.whenDefined(r.localName).then((()=>d.i|=128)),c&&c.style)){let w;typeof c.style=="string"&&(w=c.style);const v=se(u);T.has(v)||((S,m,p)=>{let f=T.get(S);z&&p?(f=f||new CSSStyleSheet,typeof f=="string"?f=m:f.replaceSync(m)):f=m,T.set(S,f)})(v,w,!!(1&u.i))}const g=d.A,_=()=>J(d,!0);g&&g["s-rc"]?g["s-rc"].push(_):_()}catch(g){M(g,r),d.C&&(d.C(),d.C=void 0),d.L&&d.L(r)}})(a,s,i)}}})(this),n&&n.call(this)},disconnectedCallback(){(async a=>{1&C.i||x(a),j.has(a)&&j.delete(a),a.shadowRoot&&j.has(a.shadowRoot)&&j.delete(a.shadowRoot)})(this),l&&l.call(this)},__attachShadow(){if(this.shadowRoot){if(this.shadowRoot.mode!=="open")throw new Error(`Unable to re-use existing shadow root for ${o.h}! Mode is set to ${this.shadowRoot.mode} but Stencil only supports open shadow roots.`)}else De.call(this,o)}}),Object.defineProperty(e,"is",{value:o.h,configurable:!0}),Ze(e,o)}catch(n){return M(n),e}};function ut(e){return e}const N=globalThis.CSSStyleSheet!==void 0?new CSSStyleSheet:void 0;let ve=!1;N&&document.adoptedStyleSheets?document.adoptedStyleSheets.push(N):console.warn("CSSStyleSheet is not defined. Omitting constructed stylesheet behaviour.");let K=null;const Q=globalThis.MutationObserver!==void 0?new MutationObserver((()=>{we()})):void 0,we=()=>{if(N===void 0)return!1;const e=(()=>{if(N===void 0)return;const t=[];for(let o=0;o<document.styleSheets.length;o++){const n=document.styleSheets.item(o);if(n)try{let l=-1,a=0;for(let s=0;s<n.cssRules.length;s++){const i=n.cssRules.item(s);if(i?.cssText.startsWith("gids-global-styles-start"))l=s;else if(l>-1){if(i?.cssText.startsWith("gids-global-styles-end")){a=s-l+1;break}t.push(i)}}if(l>-1)return{rulesStartIndex:l,originalRulesCount:a,rules:t,styleSheet:n}}catch(l){if(!(l instanceof DOMException))throw l}}})();if(e!==void 0){const t=e.styleSheet.ownerNode;return Q!==void 0&&t!==K&&(K&&Q.disconnect(),t instanceof Element&&Q.observe(t,{childList:!0,characterData:!0,subtree:!0}),K=t),N.replaceSync((o=>o.rules.map((n=>n.cssText)).join(""))(e)),(o=>{const{rulesStartIndex:n,originalRulesCount:l,styleSheet:a}=o;for(let s=0;s<l;s++)a.deleteRule(n)})(e),!0}return console.warn("refreshConstructedGidsStylesheet: Gids stylesheet is not found in document."),!1},Ke=()=>(ve||(ve=we()),N);function _e(e){var t,o,n="";if(typeof e=="string"||typeof e=="number")n+=e;else if(typeof e=="object")if(Array.isArray(e)){var l=e.length;for(t=0;t<l;t++)e[t]&&(o=_e(e[t]))&&(n&&(n+=" "),n+=o)}else for(o in e)e[o]&&(n&&(n+=" "),n+=o);return n}function Oe(){for(var e,t,o=0,n="",l=arguments.length;o<l;o++)(e=arguments[o])&&(t=_e(e))&&(n&&(n+=" "),n+=t);return n}const Qe=Object.freeze(Object.defineProperty({__proto__:null,getGidsSpinnerControlClassNames:({size:e,indeterminate:t,value:o},n)=>Oe("gids-spinner-control",{"gids-spinner-control--xs":e==="xs","gids-spinner-control--sm":e==="sm","gids-spinner-control--lg":e==="lg","gids-spinner-control--xl":e==="xl","gids-spinner-control--2xl":e==="2xl","gids-spinner-control--determinate":t===!1},o,n)},Symbol.toStringTag,{value:"Module"})),Xe=Object.freeze(Object.defineProperty({__proto__:null,getGidsButtonClassNames:({appearance:e,size:t,width:o,destructive:n,loading:l},a,s)=>Oe("gids-button",{"gids-button--primary":e==="primary","gids-button--subtle":e==="subtle","gids-button--xs":t==="xs","gids-button--sm":t==="sm","gids-button--lg":t==="lg","gids-button--full-width":o==="full","gids-button--destructive":n,"gids-button--icon-only":a,"gids-button--loading":l},s)},Symbol.toStringTag,{value:"Module"})),W=64,$e=10,Ce=W/2-$e/2,et=W/2,X=2*Math.PI*Ce,tt=`0 0 ${W} ${W}`,nt=Object.freeze(Object.defineProperty({__proto__:null,calculateStrokeDasharray:(e=0,t)=>{const o=typeof t=="number"&&t>0?t:1,l=Math.max(0,Math.min(o,e))/o*100,a=(X*l/100).toFixed(2),s=(X-parseFloat(a)).toFixed(2);return`${a} ${s}`},centerPosition:et,circumference:X,radius:Ce,thickness:$e,viewBox:tt},Symbol.toStringTag,{value:"Module"})),ke=e=>e!==void 0&&(!Array.isArray(e)||e.length>0),{getGidsSpinnerControlClassNames:ot}=Qe,{calculateStrokeDasharray:st,thickness:xe,radius:je,centerPosition:q,viewBox:lt}=nt,rt=({size:e,indeterminate:t,value:o,max:n,...l})=>{let a;return t||(a={strokeDashArray:st(o,n||0),strokeDashoffset:"0"}),O("svg",{class:ot({size:e,indeterminate:t,value:o}),viewBox:lt,...l},O("circle",{class:"gids-spinner-control__track",cx:q,cy:q,r:je,"stroke-width":xe}),O("circle",{style:a,class:"gids-spinner-control__progress",cx:q,cy:q,r:je,"stroke-width":xe}))},{getGidsButtonClassNames:it}=Xe,ct=({appearance:e,size:t,destructive:o,loading:n,width:l,leadingIcon:a,trailingIcon:s,as:i,disabled:r,class:d,forceIconOnly:u=!1,...c},g)=>{const _=i||"button",w=t==="lg"||t===void 0?"md":t;return _!=="button"||"type"in c||(c.type="button"),O(_,{class:it({appearance:e,size:t,destructive:o,loading:n,width:l},u||g.length===0&&ke(a)&&!ke(s),d),disabled:_==="button"?r:void 0,...c},O("span",{class:"gids-button__content"},a,g),n&&O(rt,{size:w,indeterminate:!0}),s)},Ee=Je(class extends Le{get selected(){return this.#e??this.defaultSelected}set selected(e){this.#e=e===void 0?void 0:!!e}constructor(e){super(),e!==!1&&this.__registerHost(),this.__attachShadow(),this.select=Ie(this,"select"),this._toggle=this._toggle.bind(this)}#e;connectedCallback(){const e=Ke();e!==void 0&&this._el.shadowRoot?.adoptedStyleSheets.push(e)}_toggle(){const e=!this.selected;this._el.selected=e,this.select?.emit(e)}render(){return O(le,{key:"222a7976cfa0daa12d2db51e405d8f3e894209d9"},O("style",{key:"04b1d2f9a184e830b949691e789deaaaea987303"},`:host {
2
+ display: ${this.width==="full"?"block":"inline-block"}
3
+ }`),O(ct,{key:"18ef39dcc5b3a532a347e530784ec4915719f914",appearance:this.appearance,size:this.size,width:this.width,disabled:this.disabled,onClick:this._toggle,"aria-pressed":this.selected?"true":"false",leadingIcon:O("slot",{name:"leadingIcon"}),trailingIcon:O("slot",{name:"trailingIcon"}),forceIconOnly:this._onlyHasLeadingIcon()},O("slot",{key:"f82ab35082be6b10d0fb76b11c8250cd6ab374a4"})))}_onlyHasLeadingIcon(){const e=this._el.childNodes;return e.length===1&&e[0]instanceof window.Element&&e[0].slot==="leadingIcon"}get _el(){return this}},[257,"gids-toggle-button",{disabled:[516],appearance:[513],size:[513],width:[513],defaultSelected:[516,"default-selected"],selected:[6660]}]);function Ae(){typeof customElements<"u"&&["gids-toggle-button"].forEach((e=>{e==="gids-toggle-button"&&(customElements.get(e)||customElements.define(e,Ee))}))}Ae();const at=Ee,dt=Ae;E.GidsToggleButton=at,E.defineCustomElement=dt,Object.defineProperty(E,Symbol.toStringTag,{value:"Module"})}));
@@ -0,0 +1 @@
1
+ (function(h,C){typeof exports=="object"&&typeof module<"u"?C(exports):typeof define=="function"&&define.amd?define(["exports"],C):(h=typeof globalThis<"u"?globalThis:h||self,C(h.gidsCoreWebIndex={}))})(this,(function(h){"use strict";var C=t=>{if(t.__stencil__getHostRef)return t.__stencil__getHostRef()},K=(t,e)=>e in t,w=typeof window<"u"?window:{},v={i:0,u:"",jmp:t=>t(),raf:t=>requestAnimationFrame(t),ael:(t,e,n,s)=>t.addEventListener(e,n,s),rel:(t,e,n,s)=>t.removeEventListener(e,n,s),ce:(t,e)=>new CustomEvent(t,e)};(()=>{try{return!!w.document.adoptedStyleSheets&&(new CSSStyleSheet,typeof new CSSStyleSheet().replaceSync=="function")}catch{}return!1})();var se=t=>{const e=new URL(t,v.u);return e.origin!==w.location.origin?e.href:e.pathname},ne=t=>v.u=t,G,q=t=>(t=typeof t)=="object"||t==="function",le=(t,e,...n)=>{let s=null,l=null,u=!1,r=!1;const i=[],o=c=>{for(let f=0;f<c.length;f++)s=c[f],Array.isArray(s)?o(s):s!=null&&typeof s!="boolean"&&((u=!q(s))&&(s=String(s)),u&&r?i[i.length-1].p+=s:i.push(u?k(null,s):s),r=u)};o(n);const a=k(t,null);return a.m=e,i.length>0&&(a.v=i),a.$=l,a},k=(t,e)=>({i:0,S:t,p:e??null,O:null,v:null,m:null,$:null}),oe={},z=(t,e,n,s,l,u)=>{if(n===s)return;let r=K(t,e),i=e.toLowerCase();if(e!=="key"){if(t.__lookupSetter__(e)||e[0]!=="o"||e[1]!=="n"){if(e[0]==="a"&&e.startsWith("attr:")){const o=e.slice(5);let a;{const c=C(t);if(c&&c.l&&c.l.t){const f=c.l.t[o];f&&f[1]&&(a=f[1])}}return a||(a=o.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase()),void(s==null||s===!1?s===!1&&t.getAttribute(a)!==""||t.removeAttribute(a):t.setAttribute(a,s===!0?"":s))}if(e[0]==="p"&&e.startsWith("prop:")){const o=e.slice(5);try{t[o]=s}catch{}return}{const o=q(s);if((r||o&&s!==null)&&!l)try{if(t.tagName.includes("-"))t[e]!==s&&(t[e]=s);else{const a=s??"";e==="list"?r=!1:n!=null&&t[e]===a||(typeof t.__lookupSetter__(e)=="function"?t[e]=a:t.setAttribute(e,a))}}catch{}s==null||s===!1?s===!1&&t.getAttribute(e)!==""||t.removeAttribute(e):(!r||4&u||l)&&!o&&t.nodeType===1&&t.setAttribute(e,s=s===!0?"":s)}}else if(e=e[2]==="-"?e.slice(3):K(w,i)?i.slice(2):i[2]+e.slice(3),n||s){const o=e.endsWith(H);e=e.replace(ie,""),n&&v.rel(t,e,n,o),s&&v.ael(t,e,s,o)}}},H="Capture",ie=new RegExp(H+"$"),U=(t,e,n)=>{const s=e.O.nodeType===11&&e.O.host?e.O.host:e.O,l=t&&t.m||{},u=e.m||{};for(const r of Y(Object.keys(l)))r in u||z(s,r,l[r],void 0,n,e.i);for(const r of Y(Object.keys(u)))z(s,r,l[r],u[r],n,e.i)};function Y(t){return t.includes("ref")?[...t.filter((e=>e!=="ref")),"ref"]:t}var Z=!1,F=!1,j=(t,e,n)=>{const s=e.v[n];let l,u,r=0;if(s.p!=null)l=s.O=w.document.createTextNode(s.p);else{if(!w.document)throw new Error("You are trying to render a Stencil component in an environment that doesn't support the DOM.");if(l=s.O=w.document.createElement(s.S),U(null,s,F),s.v){const i=s.S==="template"?l.content:l;for(r=0;r<s.v.length;++r)u=j(t,s,r),u&&i.appendChild(u)}}return l["s-hn"]=G,l},V=(t,e,n,s,l,u)=>{let r,i=t;for(i.shadowRoot&&i.tagName===G&&(i=i.shadowRoot),n.S==="template"&&(i=i.content);l<=u;++l)s[l]&&(r=j(null,n,l),r&&(s[l].O=r,E(i,r,e)))},J=(t,e,n)=>{for(let s=e;s<=n;++s){const l=t[s];if(l){const u=l.O;u&&u.remove()}}},N=(t,e,n=!1)=>t.S===e.S&&(n?(n&&!t.$&&e.$&&(t.$=e.$),!0):t.$===e.$),P=(t,e,n=!1)=>{const s=e.O=t.O,l=t.v,u=e.v,r=e.p;r==null?(e.S!=="slot"||Z||t.j!==e.j&&(e.O["s-sn"]=e.j||"",(i=>{v.i|=1;const o=i.closest(G.toLowerCase());if(o!=null){const a=Array.from(o.__childNodes||o.childNodes).find((f=>f["s-cr"])),c=Array.from(i.__childNodes||i.childNodes);for(const f of a?c.reverse():c)f["s-sh"]!=null&&(E(o,f,a??null),f["s-sh"]=void 0)}v.i&=-2})(e.O.parentElement)),U(t,e,F),l!==null&&u!==null?((i,o,a,c,f=!1)=>{let T,R,A=0,m=0,$=0,O=0,p=o.length-1,S=o[0],y=o[p],g=c.length-1,d=c[0],b=c[g];const te=a.S==="template"?i.content:i;for(;A<=p&&m<=g;)if(S==null)S=o[++A];else if(y==null)y=o[--p];else if(d==null)d=c[++m];else if(b==null)b=c[--g];else if(N(S,d,f))P(S,d,f),S=o[++A],d=c[++m];else if(N(y,b,f))P(y,b,f),y=o[--p],b=c[--g];else if(N(S,b,f))P(S,b,f),E(te,S.O,y.O.nextSibling),S=o[++A],b=c[--g];else if(N(y,d,f))P(y,d,f),E(te,y.O,S.O),y=o[--p],d=c[++m];else{for($=-1,O=A;O<=p;++O)if(o[O]&&o[O].$!==null&&o[O].$===d.$){$=O;break}$>=0?(R=o[$],R.S!==d.S?T=j(o&&o[m],a,$):(P(R,d,f),o[$]=void 0,T=R.O),d=c[++m]):(T=j(o&&o[m],a,m),d=c[++m]),T&&E(S.O.parentNode,T,S.O)}A>p?V(i,c[g+1]==null?null:c[g+1].O,a,c,m,g):m>g&&J(o,A,p)})(s,l,e,u,n):u!==null?(t.p!==null&&(s.textContent=""),V(s,null,e,u,0,u.length-1)):!n&&l!==null&&J(l,0,l.length-1)):t.p!==r&&(s.data=r)},E=(t,e,n)=>t.__insertBefore?t.__insertBefore(e,n):t?.insertBefore(e,n),re=(t,e,n=!1)=>{const s=t.$hostElement$,l=t.l,u=t.M||k(null,null);var r;const i=(r=e)&&r.S===oe?e:le(null,null,e);if(G=s.tagName,l.k&&(i.m=i.m||{},l.k.forEach((([o,a])=>{i.m[a]=s[o]}))),n&&i.m)for(const o of Object.keys(i.m))s.hasAttribute(o)&&!["key","ref","style","class"].includes(o)&&(i.m[o]=s[o]);i.S=null,i.i|=4,t.M=i,i.O=u.O=s.shadowRoot||s,Z=!(!(1&l.i)||128&l.i),P(u,i,n)},ue=t=>v.D=t,ae=t=>Object.assign(v,t),Q=new WeakMap;function ce(t,e){let n=Q.get(e);n||(n={i:0,l:{i:0,h:e.tagName},$hostElement$:e},Q.set(e,n)),re(n,t)}const _=globalThis.CSSStyleSheet!==void 0?new CSSStyleSheet:void 0;let X=!1;_&&document.adoptedStyleSheets?document.adoptedStyleSheets.push(_):console.warn("CSSStyleSheet is not defined. Omitting constructed stylesheet behaviour.");let W=null;const L=globalThis.MutationObserver!==void 0?new MutationObserver((()=>{M()})):void 0,M=()=>{if(_===void 0)return!1;const t=(()=>{if(_===void 0)return;const e=[];for(let n=0;n<document.styleSheets.length;n++){const s=document.styleSheets.item(n);if(s)try{let l=-1,u=0;for(let r=0;r<s.cssRules.length;r++){const i=s.cssRules.item(r);if(i?.cssText.startsWith("gids-global-styles-start"))l=r;else if(l>-1){if(i?.cssText.startsWith("gids-global-styles-end")){u=r-l+1;break}e.push(i)}}if(l>-1)return{rulesStartIndex:l,originalRulesCount:u,rules:e,styleSheet:s}}catch(l){if(!(l instanceof DOMException))throw l}}})();if(t!==void 0){const e=t.styleSheet.ownerNode;return L!==void 0&&e!==W&&(W&&L.disconnect(),e instanceof Element&&L.observe(e,{childList:!0,characterData:!0,subtree:!0}),W=e),_.replaceSync((n=>n.rules.map((s=>s.cssText)).join(""))(t)),(n=>{const{rulesStartIndex:s,originalRulesCount:l,styleSheet:u}=n;for(let r=0;r<l;r++)u.deleteRule(s)})(t),!0}return console.warn("refreshConstructedGidsStylesheet: Gids stylesheet is not found in document."),!1},fe=()=>(X||(X=M()),_),B=Symbol("defaultPath"),ee=Symbol("pathSet"),D="gids-asset-paths-set";class he extends EventTarget{#s=new Map;constructor(){super()}#e(e,n){this.#s.set(e,n)}#t(e){return this.#s.get(e)??null}#n=()=>{this.dispatchEvent(new Event(D))};haveAssetPathsBeenSet(){return this.#t(ee)!==null}setAssetPaths(e,n){if(!this.haveAssetPathsBeenSet()){if(typeof e=="string")this.#e(B,e);else{for(const s in e)this.#e(s,e[s]);n&&this.#e(B,n)}this.#e(ee,"true"),setTimeout(this.#n,0)}}getAssetFilePath(e){const n=this.#t(e);if(n===null){const s=this.#t(B);if(s!==null)return`${s}${s.endsWith("/")?"":"/"}${e}`}return n}onAssetPathsSet(e){if(!this.haveAssetPathsBeenSet())return this.addEventListener(D,e,{once:!0}),()=>{this.removeEventListener(D,e)}}}const I=Symbol.for("GIDS"),de=()=>(globalThis[I]===void 0&&(globalThis[I]={assetPaths:{}}),globalThis[I]),Se=t=>{const e=de().assetPaths;return e[t]===void 0&&(e[t]=new he),e[t]};function me(){return Se("@ganpatiinfo/gids-web-shared")}function ye(t,e){me().setAssetPaths(t,e)}function x(t,e){ye(t,e)}const ge=t=>{x(t)},ve=t=>{x(t)};h.getAssetPath=se,h.getConstructedGidsStylesheet=fe,h.refreshConstructedGidsStylesheet=M,h.render=ce,h.setAssetPath=ne,h.setGidsAssetFilePaths=ge,h.setGidsAssetPaths=x,h.setGidsDefaultAssetDirPath=ve,h.setNonce=ue,h.setPlatformOptions=ae,Object.defineProperty(h,Symbol.toStringTag,{value:"Module"})}));
@@ -0,0 +1,3 @@
1
+ (function(O,j){typeof exports=="object"&&typeof module<"u"?j(exports):typeof define=="function"&&define.amd?define(["exports"],j):(O=typeof globalThis<"u"?globalThis:O||self,j(O.gidsCoreWeb={}))})(this,(function(O){"use strict";function j(e,t,s){const n=typeof HTMLElement<"u"?HTMLElement.prototype:null;for(;e&&e!==n;){const o=Object.getOwnPropertyDescriptor(e,t);if(o&&(!s||o.get))return o;e=Object.getPrototypeOf(e)}}var N,Ve=(e,t)=>{var s;Object.entries((s=t.l.t)!=null?s:{}).map((([n,[o]])=>{if(31&o||32&o){const c=e[n],i=j(Object.getPrototypeOf(e),n,!0)||Object.getOwnPropertyDescriptor(e,n);i&&Object.defineProperty(e,n,{get(){return i.get.call(this)},set(r){i.set.call(this,r)},configurable:!0,enumerable:!0}),t.o.has(n)?e[n]=t.o.get(n):c!==void 0&&(e[n]=c)}}))},P=e=>{if(e.__stencil__getHostRef)return e.__stencil__getHostRef()},ae=(e,t)=>t in e,R=(e,t)=>(0,console.error)(e,t),L=new Map,A=typeof window<"u"?window:{},ce=A.HTMLElement||class{},k={i:0,u:"",jmp:e=>e(),raf:e=>requestAnimationFrame(e),ael:(e,t,s,n)=>e.addEventListener(t,s,n),rel:(e,t,s,n)=>e.removeEventListener(t,s,n),ce:(e,t)=>new CustomEvent(e,t)},F=(()=>{try{return!!A.document.adoptedStyleSheets&&(new CSSStyleSheet,typeof new CSSStyleSheet().replaceSync=="function")}catch{}return!1})(),U=!!F&&!!A.document&&Object.getOwnPropertyDescriptor(A.document.adoptedStyleSheets,"length").writable,V=!1,de=[],ue=[],Ke=(e,t)=>s=>{e.push(s),V||(V=!0,4&k.i?Y(K):k.raf(K))},he=e=>{for(let t=0;t<e.length;t++)try{e[t](performance.now())}catch(s){R(s)}e.length=0},K=()=>{he(de),he(ue),(V=de.length>0)&&k.raf(K)},Y=e=>Promise.resolve(void 0).then(e),Ye=Ke(ue),Ze=e=>{const t=new URL(e,k.u);return t.origin!==A.location.origin?t.href:t.pathname},Je=e=>k.u=e;function Qe(){const e=this.attachShadow({mode:"open"});N===void 0&&(N=null),N&&(U?e.adoptedStyleSheets.push(N):e.adoptedStyleSheets=[...e.adoptedStyleSheets,N])}var T,E=new WeakMap,fe=e=>"sc-"+e.h,Z=e=>(e=typeof e)=="object"||e==="function",$=(e,t,...s)=>{let n=null,o=null,c=!1,i=!1;const r=[],l=u=>{for(let a=0;a<u.length;a++)n=u[a],Array.isArray(n)?l(n):n!=null&&typeof n!="boolean"&&((c=typeof e!="function"&&!Z(n))&&(n=String(n)),c&&i?r[r.length-1].p+=n:r.push(c?D(null,n):n),i=c)};if(l(s),t&&t.key&&(o=t.key),typeof e=="function")return e(t===null?{}:t,r,Xe);const d=D(e,null);return d.m=t,r.length>0&&(d.v=r),d.$=o,d},D=(e,t)=>({i:0,S:e,p:t??null,O:null,v:null,m:null,$:null}),pe={},Xe={forEach:(e,t)=>e.map(ge).forEach(t),map:(e,t)=>e.map(ge).map(t).map(et)},ge=e=>({vattrs:e.m,vchildren:e.v,vkey:e.$,vname:e.j,vtag:e.S,vtext:e.p}),et=e=>{if(typeof e.vtag=="function"){const s={...e.vattrs};return e.vkey&&(s.key=e.vkey),e.vname&&(s.name=e.vname),$(e.vtag,s,...e.vchildren||[])}const t=D(e.vtag,e.vtext);return t.m=e.vattrs,t.v=e.vchildren,t.$=e.vkey,t.j=e.vname,t},me=(e,t)=>e==null||Z(e)?e:4&t?e!=="false"&&(e===""||!!e):1&t?String(e):e,tt=(e,t)=>{const s=e;return{emit:n=>ye(s,t,{bubbles:!0,composed:!0,cancelable:!0,detail:n})}},ye=(e,t,s)=>{const n=k.ce(t,s);return e.dispatchEvent(n),n},ve=(e,t,s,n,o,c)=>{if(s===n)return;let i=ae(e,t),r=t.toLowerCase();if(t!=="key"){if(e.__lookupSetter__(t)||t[0]!=="o"||t[1]!=="n"){if(t[0]==="a"&&t.startsWith("attr:")){const l=t.slice(5);let d;{const u=P(e);if(u&&u.l&&u.l.t){const a=u.l.t[l];a&&a[1]&&(d=a[1])}}return d||(d=l.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase()),void(n==null||n===!1?n===!1&&e.getAttribute(d)!==""||e.removeAttribute(d):e.setAttribute(d,n===!0?"":n))}if(t[0]==="p"&&t.startsWith("prop:")){const l=t.slice(5);try{e[l]=n}catch{}return}{const l=Z(n);if((i||l&&n!==null)&&!o)try{if(e.tagName.includes("-"))e[t]!==n&&(e[t]=n);else{const d=n??"";t==="list"?i=!1:s!=null&&e[t]===d||(typeof e.__lookupSetter__(t)=="function"?e[t]=d:e.setAttribute(t,d))}}catch{}n==null||n===!1?n===!1&&e.getAttribute(t)!==""||e.removeAttribute(t):(!i||4&c||o)&&!l&&e.nodeType===1&&e.setAttribute(t,n=n===!0?"":n)}}else if(t=t[2]==="-"?t.slice(3):ae(A,r)?r.slice(2):r[2]+t.slice(3),s||n){const l=t.endsWith(be);t=t.replace(nt,""),s&&k.rel(e,t,s,l),n&&k.ael(e,t,n,l)}}},be="Capture",nt=new RegExp(be+"$"),Se=(e,t,s)=>{const n=t.O.nodeType===11&&t.O.host?t.O.host:t.O,o=e&&e.m||{},c=t.m||{};for(const i of we(Object.keys(o)))i in c||ve(n,i,o[i],void 0,s,t.i);for(const i of we(Object.keys(c)))ve(n,i,o[i],c[i],s,t.i)};function we(e){return e.includes("ref")?[...e.filter((t=>t!=="ref")),"ref"]:e}var _e=!1,$e=!1,H=(e,t,s)=>{const n=t.v[s];let o,c,i=0;if(n.p!=null)o=n.O=A.document.createTextNode(n.p);else{if(!A.document)throw new Error("You are trying to render a Stencil component in an environment that doesn't support the DOM.");if(o=n.O=A.document.createElement(n.S),Se(null,n,$e),n.v){const r=n.S==="template"?o.content:o;for(i=0;i<n.v.length;++i)c=H(e,n,i),c&&r.appendChild(c)}}return o["s-hn"]=T,o},Oe=(e,t,s,n,o,c)=>{let i,r=e;for(r.shadowRoot&&r.tagName===T&&(r=r.shadowRoot),s.S==="template"&&(r=r.content);o<=c;++o)n[o]&&(i=H(null,s,o),i&&(n[o].O=i,M(r,i,t)))},ke=(e,t,s)=>{for(let n=t;n<=s;++n){const o=e[n];if(o){const c=o.O;c&&c.remove()}}},B=(e,t,s=!1)=>e.S===t.S&&(s?(s&&!e.$&&t.$&&(e.$=t.$),!0):e.$===t.$),x=(e,t,s=!1)=>{const n=t.O=e.O,o=e.v,c=t.v,i=t.p;i==null?(t.S!=="slot"||_e||e.j!==t.j&&(t.O["s-sn"]=t.j||"",(r=>{k.i|=1;const l=r.closest(T.toLowerCase());if(l!=null){const d=Array.from(l.__childNodes||l.childNodes).find((a=>a["s-cr"])),u=Array.from(r.__childNodes||r.childNodes);for(const a of d?u.reverse():u)a["s-sh"]!=null&&(M(l,a,d??null),a["s-sh"]=void 0)}k.i&=-2})(t.O.parentElement)),Se(e,t,$e),o!==null&&c!==null?((r,l,d,u,a=!1)=>{let m,w,v=0,_=0,S=0,g=0,p=l.length-1,h=l[0],b=l[p],f=u.length-1,y=u[0],C=u[f];const Ue=d.S==="template"?r.content:r;for(;v<=p&&_<=f;)if(h==null)h=l[++v];else if(b==null)b=l[--p];else if(y==null)y=u[++_];else if(C==null)C=u[--f];else if(B(h,y,a))x(h,y,a),h=l[++v],y=u[++_];else if(B(b,C,a))x(b,C,a),b=l[--p],C=u[--f];else if(B(h,C,a))x(h,C,a),M(Ue,h.O,b.O.nextSibling),h=l[++v],C=u[--f];else if(B(b,y,a))x(b,y,a),M(Ue,b.O,h.O),b=l[--p],y=u[++_];else{for(S=-1,g=v;g<=p;++g)if(l[g]&&l[g].$!==null&&l[g].$===y.$){S=g;break}S>=0?(w=l[S],w.S!==y.S?m=H(l&&l[_],d,S):(x(w,y,a),l[S]=void 0,m=w.O),y=u[++_]):(m=H(l&&l[_],d,_),y=u[++_]),m&&M(h.O.parentNode,m,h.O)}v>p?Oe(r,u[f+1]==null?null:u[f+1].O,d,u,_,f):_>f&&ke(l,v,p)})(n,o,t,c,s):c!==null?(e.p!==null&&(n.textContent=""),Oe(n,null,t,c,0,c.length-1)):!s&&o!==null&&ke(o,0,o.length-1)):e.p!==i&&(n.data=i)},M=(e,t,s)=>e.__insertBefore?e.__insertBefore(t,s):e?.insertBefore(t,s),Ae=(e,t,s=!1)=>{const n=e.$hostElement$,o=e.l,c=e.M||D(null,null);var i;const r=(i=t)&&i.S===pe?t:$(null,null,t);if(T=n.tagName,o.k&&(r.m=r.m||{},o.k.forEach((([l,d])=>{r.m[d]=n[l]}))),s&&r.m)for(const l of Object.keys(r.m))n.hasAttribute(l)&&!["key","ref","style","class"].includes(l)&&(r.m[l]=n[l]);r.S=null,r.i|=4,e.M=r,r.O=c.O=n.shadowRoot||n,_e=!(!(1&o.i)||128&o.i),x(c,r,s)},Ce=(e,t)=>{if(t&&!e.C&&t["s-p"]){const s=t["s-p"].push(new Promise((n=>e.C=()=>{t["s-p"].splice(s-1,1),n()})))}},J=(e,t)=>{if(e.i|=16,4&e.i)return void(e.i|=512);Ce(e,e.A);const s=()=>st(e,t);if(!t)return Ye(s);queueMicrotask((()=>{s()}))},st=(e,t)=>{const s=e.$hostElement$,n=s;if(!n)throw new Error(`Can't render component <${s.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=G(n,t?"componentWillLoad":"componentWillUpdate",void 0,s),o=Pe(o,(()=>G(n,"componentWillRender",void 0,s))),Pe(o,(()=>it(e,n,t)))},Pe=(e,t)=>ot(e)?e.then(t).catch((s=>{console.error(s),t()})):t(),ot=e=>e instanceof Promise||e&&e.then&&typeof e.then=="function",it=async(e,t,s)=>{var n;const o=e.$hostElement$,c=o["s-rc"];s&&(i=>{const r=i.l,l=i.$hostElement$,d=r.i,u=((a,m)=>{var w,v,_;const S=fe(m),g=L.get(S);if(!A.document)return S;if(a=a.nodeType===11?a:A.document,g)if(typeof g=="string"){let p,h=E.get(a=a.head||a);if(h||E.set(a,h=new Set),!h.has(S)){p=A.document.createElement("style"),p.textContent=g;const b=(w=k.D)!=null?w:(function(){var f,y,C;return(C=(y=(f=A.document.head)==null?void 0:f.querySelector('meta[name="csp-nonce"]'))==null?void 0:y.getAttribute("content"))!=null?C:void 0})();if(b!=null&&p.setAttribute("nonce",b),!(1&m.i))if(a.nodeName==="HEAD"){const f=a.querySelectorAll("link[rel=preconnect]"),y=f.length>0?f[f.length-1].nextSibling:a.querySelector("style");a.insertBefore(p,y?.parentNode===a?y:null)}else if("host"in a)if(F){const f=new((v=a.defaultView)!=null?v:a.ownerDocument.defaultView).CSSStyleSheet;f.replaceSync(g),U?a.adoptedStyleSheets.unshift(f):a.adoptedStyleSheets=[f,...a.adoptedStyleSheets]}else{const f=a.querySelector("style");f?f.textContent=g+f.textContent:a.prepend(p)}else a.append(p);1&m.i&&a.insertBefore(p,null),4&m.i&&(p.textContent+="slot-fb{display:contents}slot-fb[hidden]{display:none}"),h&&h.add(S)}}else{let p=E.get(a);if(p||E.set(a,p=new Set),!p.has(S)){const h=(_=a.defaultView)!=null?_:a.ownerDocument.defaultView;let b;if(g.constructor===h.CSSStyleSheet)b=g;else{b=new h.CSSStyleSheet;for(let f=0;f<g.cssRules.length;f++)b.insertRule(g.cssRules[f].cssText,f)}U?a.adoptedStyleSheets.push(b):a.adoptedStyleSheets=[...a.adoptedStyleSheets,b],p.add(S)}}return S})(l.shadowRoot?l.shadowRoot:l.getRootNode(),r);10&d&&(l["s-sc"]=u,l.classList.add(u+"-h"))})(e),lt(e,t,o,s),c&&(c.map((i=>i())),o["s-rc"]=void 0);{const i=(n=o["s-p"])!=null?n:[],r=()=>rt(e);i.length===0?r():(Promise.all(i).then(r).catch(r),e.i|=4,i.length=0)}},lt=(e,t,s,n)=>{try{t=t.render(),e.i&=-17,e.i|=2,Ae(e,t,n)}catch(o){R(o,e.$hostElement$)}return null},rt=e=>{const t=e.$hostElement$,s=t,n=e.A;G(s,"componentDidRender",void 0,t),64&e.i?G(s,"componentDidUpdate",void 0,t):(e.i|=64,ct(t),G(s,"componentDidLoad",void 0,t),e.L(t),n||at()),e.C&&(e.C(),e.C=void 0),512&e.i&&Y((()=>J(e,!1))),e.i&=-517},at=()=>{Y((()=>ye(A,"appload",{detail:{namespace:"gids-core-web"}})))},G=(e,t,s,n)=>{if(e&&e[t])try{return e[t](s)}catch(o){R(o,n)}},ct=e=>e.classList.add("hydrated"),Ee=(e,t,s,n)=>{const o=P(e);if(!o)return;const c=e,i=o.o.get(t),r=o.i,l=c;s=me(s,n.t[t][0]);const d=Number.isNaN(i)&&Number.isNaN(s);if(s!==i&&!d&&(o.o.set(t,s),2&r)){if(l.componentShouldUpdate&&l.componentShouldUpdate(s,i,t)===!1&&!(16&r))return;16&r||J(o,!1)}},dt=(e,t)=>{var s,n;const o=e.prototype;if(t.t){const c=Object.entries((s=t.t)!=null?s:{});c.map((([i,[r]])=>{if(31&r||32&r){const{get:l,set:d}=j(o,i)||{};l&&(t.t[i][0]|=2048),d&&(t.t[i][0]|=4096),Object.defineProperty(o,i,{get(){return l?l.apply(this):(u=i,P(this).o.get(u));var u},configurable:!0,enumerable:!0}),Object.defineProperty(o,i,{set(u){const a=P(this);if(a){if(d)return(32&r?this[i]:a.$hostElement$[i])===void 0&&a.o.get(i)&&(u=a.o.get(i)),d.apply(this,[me(u,r)]),void Ee(this,i,u=32&r?this[i]:a.$hostElement$[i],t);Ee(this,i,u,t)}}})}}));{const i=new Map;o.attributeChangedCallback=function(r,l,d){k.jmp((()=>{var u;const a=i.get(r),m=P(this);if(this.hasOwnProperty(a),o.hasOwnProperty(a)&&typeof this[a]=="number"&&this[a]==d)return;if(a==null){const g=m?.i;if(m&&g&&!(8&g)&&d!==l){const p=this,h=(u=t.R)==null?void 0:u[r];h?.forEach((b=>{const[[f,y]]=Object.entries(b);p[f]!=null&&(128&g||1&y)&&p[f].call(p,d,l,r)}))}return}const w=c.find((([g])=>g===a)),v=w&&4&w[1][0],_=v&&d===null&&this[a]===void 0;v&&(d=d!==null&&d!=="false");const S=Object.getOwnPropertyDescriptor(o,a);_||d==this[a]||S.get&&!S.set||(this[a]=d)}))},e.observedAttributes=Array.from(new Set([...Object.keys((n=t.R)!=null?n:{}),...c.filter((([r,l])=>31&l[0])).map((([r,l])=>{var d;const u=l[1]||r;return i.set(u,r),512&l[0]&&((d=t.k)==null||d.push([r,u])),u}))]))}}return e},je=(e,t)=>{const s={i:t[0],h:t[1]};try{s.t=t[2],s.k=[];const n=e.prototype.connectedCallback,o=e.prototype.disconnectedCallback;return Object.assign(e.prototype,{__hasHostListenerAttached:!1,__registerHost(){((c,i)=>{const r={i:0,$hostElement$:c,l:i,o:new Map,_:new Map};r.H=new Promise((d=>r.L=d)),c["s-p"]=[],c["s-rc"]=[];const l=r;c.__stencil__getHostRef=()=>l,512&i.i&&Ve(c,r)})(this,s)},connectedCallback(){if(!this.__hasHostListenerAttached){if(!P(this))return;this.__hasHostListenerAttached=!0}(c=>{if(!(1&k.i)){const i=P(c);if(!i)return;const r=i.l;if(1&i.i)i?.P||i?.H&&i.H.then((()=>{}));else{i.i|=1;{let l=c;for(;l=l.parentNode||l.host;)if(l["s-p"]){Ce(i,i.A=l);break}}r.t&&Object.entries(r.t).map((([l,[d]])=>{if(31&d&&Object.prototype.hasOwnProperty.call(c,l)){const u=c[l];delete c[l],c[l]=u}})),(async(l,d,u)=>{let a;try{if(!(32&d.i)&&(d.i|=32,a=l.constructor,customElements.whenDefined(l.localName).then((()=>d.i|=128)),a&&a.style)){let v;typeof a.style=="string"&&(v=a.style);const _=fe(u);L.has(_)||((S,g,p)=>{let h=L.get(S);F&&p?(h=h||new CSSStyleSheet,typeof h=="string"?h=g:h.replaceSync(g)):h=g,L.set(S,h)})(_,v,!!(1&u.i))}const m=d.A,w=()=>J(d,!0);m&&m["s-rc"]?m["s-rc"].push(w):w()}catch(m){R(m,l),d.C&&(d.C(),d.C=void 0),d.L&&d.L(l)}})(c,i,r)}}})(this),n&&n.call(this)},disconnectedCallback(){(async c=>{1&k.i||P(c),E.has(c)&&E.delete(c),c.shadowRoot&&E.has(c.shadowRoot)&&E.delete(c.shadowRoot)})(this),o&&o.call(this)},__attachShadow(){if(this.shadowRoot){if(this.shadowRoot.mode!=="open")throw new Error(`Unable to re-use existing shadow root for ${s.h}! Mode is set to ${this.shadowRoot.mode} but Stencil only supports open shadow roots.`)}else Qe.call(this,s)}}),Object.defineProperty(e,"is",{value:s.h,configurable:!0}),dt(e,s)}catch(n){return R(n),e}},ut=e=>k.D=e,ht=e=>Object.assign(k,e),xe=new WeakMap;function ft(e,t){let s=xe.get(t);s||(s={i:0,l:{i:0,h:t.tagName},$hostElement$:t},xe.set(t,s)),Ae(s,e)}function Wt(e){return e}const I=globalThis.CSSStyleSheet!==void 0?new CSSStyleSheet:void 0;let Ie=!1;I&&document.adoptedStyleSheets?document.adoptedStyleSheets.push(I):console.warn("CSSStyleSheet is not defined. Omitting constructed stylesheet behaviour.");let Q=null;const X=globalThis.MutationObserver!==void 0?new MutationObserver((()=>{ee()})):void 0,ee=()=>{if(I===void 0)return!1;const e=(()=>{if(I===void 0)return;const t=[];for(let s=0;s<document.styleSheets.length;s++){const n=document.styleSheets.item(s);if(n)try{let o=-1,c=0;for(let i=0;i<n.cssRules.length;i++){const r=n.cssRules.item(i);if(r?.cssText.startsWith("gids-global-styles-start"))o=i;else if(o>-1){if(r?.cssText.startsWith("gids-global-styles-end")){c=i-o+1;break}t.push(r)}}if(o>-1)return{rulesStartIndex:o,originalRulesCount:c,rules:t,styleSheet:n}}catch(o){if(!(o instanceof DOMException))throw o}}})();if(e!==void 0){const t=e.styleSheet.ownerNode;return X!==void 0&&t!==Q&&(Q&&X.disconnect(),t instanceof Element&&X.observe(t,{childList:!0,characterData:!0,subtree:!0}),Q=t),I.replaceSync((s=>s.rules.map((n=>n.cssText)).join(""))(e)),(s=>{const{rulesStartIndex:n,originalRulesCount:o,styleSheet:c}=s;for(let i=0;i<o;i++)c.deleteRule(n)})(e),!0}return console.warn("refreshConstructedGidsStylesheet: Gids stylesheet is not found in document."),!1},te=()=>(Ie||(Ie=ee()),I),Ne={"icons-other.svg":["accessibility","announcement","approval","archive","audio","backward","banking","battery","bluetooth","bookmark","bulb","calendar","camera","card","cart","chart","chat","cloud","code","compass","desktop","email","emergency","exchange","finance","fingerprint","flag","folder","forward","gift","globe","goals","happy","hashtag","headphones","history","image","insurance","investment","key","link","list","location","lock","map","maximise","microphone","minimise","mobile","moon","network","neutral","new","new-chat","pause","percent","placeholder","play","power","rain","refresh","repeat","sad","save","savings","shield","shuffle","side-navigation","snow","speaker","stop","sun","tablet","temperature","thumbs-down","thumbs-up","travel","trend-down","trend-up","unlock","upset","verified","very-happy","video","volume-down","volume-max","volume-min","volume-mute","volume-up","wallet","wealth","wi-fi","wind"],"icons-core.svg":["arrow-down","arrow-left","arrow-right","arrow-up","attachment","checkmark","chevron-down","chevron-horizontal","chevron-left","chevron-right","chevron-up","chevron-vertical","copy","cross","danger","dashboard","delete","document","download","drag","edit","external","eye","filter","grid","hide","home","information","log-in","log-out","menu","minus","more","notifications","options","phone","plus","positive","printer","question","search","select","select-all","send","settings","share","star","time","upload","user","users","warning"]},Re=new Map;for(const e in Ne)for(const t of Ne[e])Re.set(t,e);function pt(e){return Re.get(e)}function Me(e,t="regular",s){const n=pt(e);let o=n??"";return s&&n&&(o=s(n)??n),`${o}#${e}${t==="filled"?"--filled":""}`}function Ge(e){var t,s,n="";if(typeof e=="string"||typeof e=="number")n+=e;else if(typeof e=="object")if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(s=Ge(e[t]))&&(n&&(n+=" "),n+=s)}else for(s in e)e[s]&&(n&&(n+=" "),n+=s);return n}function ne(){for(var e,t,s=0,n="",o=arguments.length;s<o;s++)(e=arguments[s])&&(t=Ge(e))&&(n&&(n+=" "),n+=t);return n}const gt=Object.freeze(Object.defineProperty({__proto__:null,getGidsSpinnerControlClassNames:({size:e,indeterminate:t,value:s},n)=>ne("gids-spinner-control",{"gids-spinner-control--xs":e==="xs","gids-spinner-control--sm":e==="sm","gids-spinner-control--lg":e==="lg","gids-spinner-control--xl":e==="xl","gids-spinner-control--2xl":e==="2xl","gids-spinner-control--determinate":t===!1},s,n)},Symbol.toStringTag,{value:"Module"})),mt=Object.freeze(Object.defineProperty({__proto__:null,getGidsIconClassNames:({size:e},t)=>ne("gids-icon",{"gids-icon--xs":e==="xs","gids-icon--sm":e==="sm","gids-icon--md":e==="md","gids-icon--lg":e==="lg"},t)},Symbol.toStringTag,{value:"Module"})),yt=Object.freeze(Object.defineProperty({__proto__:null,getGidsButtonClassNames:({appearance:e,size:t,width:s,destructive:n,loading:o},c,i)=>ne("gids-button",{"gids-button--primary":e==="primary","gids-button--subtle":e==="subtle","gids-button--xs":t==="xs","gids-button--sm":t==="sm","gids-button--lg":t==="lg","gids-button--full-width":s==="full","gids-button--destructive":n,"gids-button--icon-only":c,"gids-button--loading":o},i)},Symbol.toStringTag,{value:"Module"})),z=64,Le=10,Te=z/2-Le/2,vt=z/2,se=2*Math.PI*Te,bt=`0 0 ${z} ${z}`,St=Object.freeze(Object.defineProperty({__proto__:null,calculateStrokeDasharray:(e=0,t)=>{const s=typeof t=="number"&&t>0?t:1,o=Math.max(0,Math.min(s,e))/s*100,c=(se*o/100).toFixed(2),i=(se-parseFloat(c)).toFixed(2);return`${c} ${i}`},centerPosition:vt,circumference:se,radius:Te,thickness:Le,viewBox:bt},Symbol.toStringTag,{value:"Module"})),oe=Symbol("defaultPath"),De=Symbol("pathSet"),ie="gids-asset-paths-set";class wt extends EventTarget{#e=new Map;constructor(){super()}#t(t,s){this.#e.set(t,s)}#n(t){return this.#e.get(t)??null}#s=()=>{this.dispatchEvent(new Event(ie))};haveAssetPathsBeenSet(){return this.#n(De)!==null}setAssetPaths(t,s){if(!this.haveAssetPathsBeenSet()){if(typeof t=="string")this.#t(oe,t);else{for(const n in t)this.#t(n,t[n]);s&&this.#t(oe,s)}this.#t(De,"true"),setTimeout(this.#s,0)}}getAssetFilePath(t){const s=this.#n(t);if(s===null){const n=this.#n(oe);if(n!==null)return`${n}${n.endsWith("/")?"":"/"}${t}`}return s}onAssetPathsSet(t){if(!this.haveAssetPathsBeenSet())return this.addEventListener(ie,t,{once:!0}),()=>{this.removeEventListener(ie,t)}}}const le=Symbol.for("GIDS"),_t=()=>(globalThis[le]===void 0&&(globalThis[le]={assetPaths:{}}),globalThis[le]),$t=e=>{const t=_t().assetPaths;return t[e]===void 0&&(t[e]=new wt),t[e]};function W(){return $t("@ganpatiinfo/gids-web-shared")}function Ot(){return W().haveAssetPathsBeenSet()}function kt(e,t){W().setAssetPaths(e,t)}function He(e){return W().getAssetFilePath(e)}function At(e){return W().onAssetPathsSet(e)}let Ct=0;const Pt=(e,t="gids")=>e||`${t}-${Ct++}`,Be=e=>e!==void 0&&(!Array.isArray(e)||e.length>0),{getGidsIconClassNames:Et}=mt,jt=({name:e,size:t,appearance:s,alt:n,class:o,titleId:c,src:i,...r})=>{const l=Pt(c);let d=i;return d===void 0&&Ot()&&(d=Me(e,s,He)),$("svg",{ref:u=>{d===void 0&&At((()=>{(function(a,m,w){if(!a)return;const v=document.createElementNS("http://www.w3.org/2000/svg","use");v.setAttribute("href",Me(m,w,He)),a.appendChild(v)})(u,e,s)}))},width:"16",height:"16",class:Et({size:t},o),role:"img","aria-hidden":n===""?"true":void 0,"aria-labelledby":n===""?void 0:l,...r},n!==""&&$("title",{id:l},n||e),d!==void 0?$("use",{href:d}):null)},ze=je(class extends ce{constructor(e){super(),e!==!1&&this.__registerHost(),this.__attachShadow()}connectedCallback(){const e=te();e!==void 0&&this._el.shadowRoot?.adoptedStyleSheets.push(e)}render(){return $(jt,{key:"2459cf3111612150342d5a57574fd61157a9c591",name:this.name,size:this.size,appearance:this.appearance,alt:this.alt,titleId:this.titleId})}get _el(){return this}static get style(){return".gids-icon{fill:var(--gidsIcon-color, var(--gids-color-icon-default));width:auto;height:var(--gidsIcon-height, 100%)}.gids-icon--xs{--gidsIcon-height:var(--gids-size-120)}.gids-icon--sm{--gidsIcon-height:var(--gids-size-160)}.gids-icon--md{--gidsIcon-height:var(--gids-size-240)}.gids-icon--lg{--gidsIcon-height:var(--gids-size-320)}"}},[1,"gids-icon",{name:[1],size:[1],appearance:[1],alt:[1],titleId:[1,"title-id"]}]);function xt(){typeof customElements<"u"&&["gids-icon"].forEach((e=>{e==="gids-icon"&&(customElements.get(e)||customElements.define(e,ze))}))}xt();const It=ze,{getGidsSpinnerControlClassNames:Nt}=gt,{calculateStrokeDasharray:Rt,thickness:We,radius:qe,centerPosition:q,viewBox:Mt}=St,Gt=({size:e,indeterminate:t,value:s,max:n,...o})=>{let c;return t||(c={strokeDashArray:Rt(s,n||0),strokeDashoffset:"0"}),$("svg",{class:Nt({size:e,indeterminate:t,value:s}),viewBox:Mt,...o},$("circle",{class:"gids-spinner-control__track",cx:q,cy:q,r:qe,"stroke-width":We}),$("circle",{style:c,class:"gids-spinner-control__progress",cx:q,cy:q,r:qe,"stroke-width":We}))},{getGidsButtonClassNames:Lt}=yt,Tt=({appearance:e,size:t,destructive:s,loading:n,width:o,leadingIcon:c,trailingIcon:i,as:r,disabled:l,class:d,forceIconOnly:u=!1,...a},m)=>{const w=r||"button",v=t==="lg"||t===void 0?"md":t;return w!=="button"||"type"in a||(a.type="button"),$(w,{class:Lt({appearance:e,size:t,destructive:s,loading:n,width:o},u||m.length===0&&Be(c)&&!Be(i),d),disabled:w==="button"?l:void 0,...a},$("span",{class:"gids-button__content"},c,m),n&&$(Gt,{size:v,indeterminate:!0}),i)},Fe=je(class extends ce{get selected(){return this.#e??this.defaultSelected}set selected(e){this.#e=e===void 0?void 0:!!e}constructor(e){super(),e!==!1&&this.__registerHost(),this.__attachShadow(),this.select=tt(this,"select"),this._toggle=this._toggle.bind(this)}#e;connectedCallback(){const e=te();e!==void 0&&this._el.shadowRoot?.adoptedStyleSheets.push(e)}_toggle(){const e=!this.selected;this._el.selected=e,this.select?.emit(e)}render(){return $(pe,{key:"222a7976cfa0daa12d2db51e405d8f3e894209d9"},$("style",{key:"04b1d2f9a184e830b949691e789deaaaea987303"},`:host {
2
+ display: ${this.width==="full"?"block":"inline-block"}
3
+ }`),$(Tt,{key:"18ef39dcc5b3a532a347e530784ec4915719f914",appearance:this.appearance,size:this.size,width:this.width,disabled:this.disabled,onClick:this._toggle,"aria-pressed":this.selected?"true":"false",leadingIcon:$("slot",{name:"leadingIcon"}),trailingIcon:$("slot",{name:"trailingIcon"}),forceIconOnly:this._onlyHasLeadingIcon()},$("slot",{key:"f82ab35082be6b10d0fb76b11c8250cd6ab374a4"})))}_onlyHasLeadingIcon(){const e=this._el.childNodes;return e.length===1&&e[0]instanceof window.Element&&e[0].slot==="leadingIcon"}get _el(){return this}},[257,"gids-toggle-button",{disabled:[516],appearance:[513],size:[513],width:[513],defaultSelected:[516,"default-selected"],selected:[6660]}]);function Dt(){typeof customElements<"u"&&["gids-toggle-button"].forEach((e=>{e==="gids-toggle-button"&&(customElements.get(e)||customElements.define(e,Fe))}))}Dt();const Ht=Fe;function re(e,t){kt(e,t)}const Bt=e=>{re(e)},zt=e=>{re(e)};O.GidsIcon=It,O.GidsToggleButton=Ht,O.getAssetPath=Ze,O.getConstructedGidsStylesheet=te,O.refreshConstructedGidsStylesheet=ee,O.render=ft,O.setAssetPath=Je,O.setGidsAssetFilePaths=Bt,O.setGidsAssetPaths=re,O.setGidsDefaultAssetDirPath=zt,O.setNonce=ut,O.setPlatformOptions=ht,Object.defineProperty(O,Symbol.toStringTag,{value:"Module"})}));
package/distPaths.js ADDED
@@ -0,0 +1,34 @@
1
+ import { fileURLToPath, URL } from 'node:url';
2
+ import { join } from 'node:path';
3
+
4
+ const packageRoot = fileURLToPath(new URL(`./`, import.meta.url));
5
+
6
+ export const distDirName = 'dist';
7
+
8
+ export const esBundlesDirName = join('dist-bundled', 'es');
9
+
10
+ export const umdBundlesDirName = join('dist-bundled', 'umd');
11
+
12
+ export const umdCompleteBundleDirName = join('dist-bundled', 'umd-complete');
13
+
14
+ export const umdCompleteBundleFileName = 'gids-core-web.umd.js';
15
+
16
+ export function distPath(...segments) {
17
+ return join(packageRoot, distDirName, ...segments);
18
+ }
19
+
20
+ export function cssPath(...segments) {
21
+ return join(packageRoot, distDirName, 'css', ...segments);
22
+ }
23
+
24
+ export function esBundlesPath(...segments) {
25
+ return join(packageRoot, esBundlesDirName, ...segments);
26
+ }
27
+
28
+ export function umdBundlesPath(...segments) {
29
+ return join(packageRoot, umdBundlesDirName, ...segments);
30
+ }
31
+
32
+ export function umdCompleteBundlePath(...segments) {
33
+ return join(packageRoot, umdCompleteBundleDirName, ...segments);
34
+ }
package/package.json CHANGED
@@ -1,160 +1,193 @@
1
1
  {
2
- "name": "@ganpatiinfo/gids-core-web",
3
- "version": "2.1.0",
4
- "private": false,
5
- "description": "This is a core web package contains html components",
6
- "homepage": "https://ganpatiinfosystem.vercel.app/",
7
- "files": [
8
- "dist/"
9
- ],
10
- "scripts": {
11
- "clean:legacy": "del-cli src/components/functional/Icon/IconUtils.ts src/components/Icon/IconUtils.ts src/styles/Typography.stories.ts src/types/asset-types.ts",
12
- "clean:current": "del-cli dist/** dist-dev/** src/components.d.ts src/stories/Typography.stories.ts src/styles/6-utilities/typography.scss src/types/assetTypes.ts",
13
- "clean:stencil-generated": "del-cli --force ../react-web/src/components/stencil-generated ../../angular/projects/angular-web/src/lib/stencil-generated",
14
- "clean": "npm-run-all --parallel clean:**",
15
- "prebuild": "node ./scripts/generateCode.js",
16
- "build:js": "stencil build",
17
- "build:css": "sass src/index.scss:dist/index.css src/elements.scss:dist/elements.css",
18
- "build:ce-manifest": "cem analyze",
19
- "build": "npm-run-all --parallel build:**",
20
- "postbuild": "node scripts/fixupBuild.js",
21
- "watch:js": "stencil build --watch",
22
- "watch:css": "sass --watch src/index.scss dist/index.css",
23
- "watch": "npm-run-all build --parallel watch:**",
24
- "start": "npm-run-all build --parallel watch:js storybook",
25
- "test": "stencil test --config stencil.test-config.ts --spec --e2e --coverage",
26
- "test:local": "stencil test --config stencil.test-config.ts --spec --e2e --watchAll",
27
- "generate": "stencil generate",
28
- "storybook": "storybook dev --config-dir .storybook-dev -p 6006",
29
- "build-site": "storybook build -o ../../site/public/workshop/gids-core-web/",
30
- "size": "size-limit",
31
- "release:manually": "npm run build && npm publish --access public"
32
- },
33
- "keywords": [
34
- "core",
35
- "web",
36
- "html",
37
- "components",
38
- "gids-core-web"
39
- ],
40
- "author": {
41
- "name": "Ganpatiinfo Design System",
42
- "email": "ganpatiinfosysystem0@gmail.com",
43
- "url": "https://ganpatiinfosystem.vercel.app/"
44
- },
45
- "license": "MIT",
46
- "repository": {
47
- "type": "git",
48
- "url": "https://github.com/ganpatiinfosystem/ganpatiinfo-design-system",
49
- "directory": "packages/gids-core-web"
50
- },
51
- "customElements": "dist/custom-elements.json",
52
- "style": "dist/index.css",
53
- "type": "module",
54
- "main": "dist/index.js",
55
- "types": "dist/index.d.ts",
56
- "exports": {
57
- "./index.css": {
58
- "style": "./dist/index.css",
59
- "default": "./dist/index.css"
60
- },
61
- "./elements.css": {
62
- "style": "./dist/elements.css",
63
- "default": "./dist/elements.css"
64
- },
65
- ".": {
66
- "types": "./dist/index.d.ts",
67
- "default": "./dist/index.js"
68
- },
69
- "./gids-toggle-button.js": {
70
- "types": "./dist/gids-toggle-button.d.ts",
71
- "default": "./dist/gids-toggle-button.js"
72
- },
73
- "./dist/gids-toggle-button.js": {
74
- "types": "./dist/gids-toggle-button.d.ts",
75
- "default": "./dist/gids-toggle-button.js"
76
- },
77
- "./customElements": {
78
- "default": "./dist/custom-elements.json"
79
- }
80
- },
81
- "peerDependencies": {
82
- "@ganpatiinfo/gids-web-theme-interface": "^2.0.7",
83
- "clsx": "^2.1.1"
84
- },
85
- "dependencies": {
86
- "clsx": "^2.1.1",
87
- "@ganpatiinfo/gids-core-shared": "^2.1.0",
88
- "@ganpatiinfo/gids-web-shared": "^2.1.0"
89
- },
90
- "devDependencies": {
91
- "@babel/preset-env": "^7.27.2",
92
- "@babel/preset-typescript": "^7.27.1",
93
- "@custom-elements-manifest/analyzer": "^0.10.4",
94
- "@fontsource/inter": "^5.2.5",
95
- "@fontsource/libre-caslon-text": "^5.2.5",
96
- "@ganpatiinfo/gids-liquid-renderer": "^2.0.6",
97
- "@ganpatiinfo/gids-storybook-theme": "^2.0.7",
98
- "@ganpatiinfo/gids-storybook-utilities": "^2.0.6",
99
- "@ganpatiinfo/gids-web-dom-reference": "^2.1.0",
100
- "@ganpatiinfo/gids-web-theme-ganpatiinfo": "^2.0.7",
101
- "@jest/globals": "^29.7.0",
102
- "@stencil/angular-output-target": "^0.10.2",
103
- "@stencil/core": "^4.30.0",
104
- "@stencil/react-output-target": "^0.8.2",
105
- "@storybook/addon-a11y": "^8.6.12",
106
- "@storybook/addon-essentials": "^8.6.12",
107
- "@storybook/addon-links": "^8.6.12",
108
- "@storybook/blocks": "^8.6.12",
109
- "@storybook/manager-api": "^8.6.12",
110
- "@storybook/test": "^8.6.12",
111
- "@storybook/web-components": "^8.6.13",
112
- "@storybook/web-components-vite": "^8.6.13",
113
- "@types/jest": "^29.5.14",
114
- "jest": "^29.7.0",
115
- "jest-cli": "^29.7.0",
116
- "puppeteer": "^24.8.2",
117
- "saas": "^1.0.0",
118
- "storybook": "^8.6.13",
119
- "storybook-addon-tag-badges": "^1.4.0",
120
- "ts-jest": "^29.3.3"
121
- },
122
- "nx": {
123
- "target": {
124
- "build": {
125
- "outputs": [
126
- "{projectRoot}/dist",
127
- "{projectRoot}/dist-dev",
128
- "{projectRoot}/src",
129
- "{workspaceRoot}/packages/react-web/src/components/stencil-generated",
130
- "{workspaceRoot}/angular/projects/angular-web/src/lib/stencil-generated"
131
- ]
132
- },
133
- "build-site": {
134
- "outputs": [
135
- "{workspaceRoot}/site/dist/workshop/gids-core-web/"
136
- ]
137
- }
138
- }
139
- },
140
- "size-limit": [
141
- {
142
- "name": "JavaScript (exclusive GIDS dependencies package)",
143
- "path": [
144
- "dist/index.js"
145
- ],
146
- "import": {
147
- "dist/index.js": "*"
148
- },
149
- "ignore": []
150
- },
151
- {
152
- "name": "CSS core",
153
- "path": "dist/index.css"
154
- },
155
- {
156
- "name": "CSS (optional)",
157
- "path": "dist/elements.css"
158
- }
159
- ]
2
+ "name": "@ganpatiinfo/gids-core-web",
3
+ "version": "3.0.0",
4
+ "private": false,
5
+ "description": "This is a core web package contains html components",
6
+ "homepage": "https://ganpatiinfosystem.vercel.app/",
7
+ "files": [
8
+ "distPaths.js",
9
+ "scriptUtils.js",
10
+ "dist/",
11
+ "dist-bundled/"
12
+ ],
13
+ "scripts": {
14
+ "clean:legacy": "del-cli src/components/functional/Icon/IconUtils.ts src/components/Icon/IconUtils.ts src/styles/Typography.stories.ts src/types/asset-types.ts",
15
+ "clean:current": "del-cli dist/** dist-dev/** src/components.d.ts src/stories/Typography.stories.ts src/styles/6-utilities/typography.scss src/types/assetTypes.ts",
16
+ "clean:stencil-generated": "del-cli --force ../react-web/src/components/stencil-generated ../../angular/projects/angular-web/src/lib/stencil-generated",
17
+ "clean:bundle": "del-cli dist-bundled/**",
18
+ "clean": "npm-run-all --parallel clean:**",
19
+ "prebuild": "node ./scripts/generateCode.js",
20
+ "build:js": "stencil build",
21
+ "build:js:bundle:es": "vite -c vite-bundle-es.config.js build",
22
+ "build:js:bundle:umd-complete": "vite -c vite-bundle-umd-complete.config.js build",
23
+ "build:js:bundle:umd": "node ./scripts/buildIndividualUmdBundles.js",
24
+ "build:css": "sass src/index.scss:dist/css/index.css src/elements.scss:dist/css/elements.css",
25
+ "build:ce-manifest": "cem analyze",
26
+ "build": "npm-run-all --parallel build:* --parallel build:js:bundle:*",
27
+ "postbuild": "node scripts/fixupBuild.js",
28
+ "watch:js": "stencil build --watch",
29
+ "watch:css": "sass --watch src/index.scss dist/index.css",
30
+ "watch": "npm-run-all build --parallel watch:**",
31
+ "start": "npm-run-all build --parallel watch:js storybook",
32
+ "test": "jest",
33
+ "test:local": "jest --watch",
34
+ "generate": "stencil generate",
35
+ "storybook": "storybook dev --config-dir .storybook-dev -p 6006",
36
+ "build-site": "storybook build -o ../../site/public/workshop/gids-core-web/",
37
+ "size": "size-limit",
38
+ "release:manually": "npm run build && npm publish --access public"
39
+ },
40
+ "keywords": [
41
+ "core",
42
+ "web",
43
+ "html",
44
+ "components",
45
+ "gids-core-web"
46
+ ],
47
+ "author": {
48
+ "name": "Ganpatiinfo Design System",
49
+ "email": "ganpatiinfosysystem0@gmail.com",
50
+ "url": "https://ganpatiinfosystem.vercel.app/"
51
+ },
52
+ "license": "MIT",
53
+ "repository": {
54
+ "type": "git",
55
+ "url": "https://github.com/ganpatiinfosystem/ganpatiinfo-design-system",
56
+ "directory": "packages/gids-core-web"
57
+ },
58
+ "customElements": "dist/custom-elements.json",
59
+ "style": "dist/css/index.css",
60
+ "type": "module",
61
+ "main": "dist/index.js",
62
+ "types": "dist/index.d.ts",
63
+ "exports": {
64
+ "./index.css": {
65
+ "style": "./dist/css/index.css",
66
+ "default": "./dist/css/index.css"
67
+ },
68
+ "./elements.css": {
69
+ "style": "./dist/css/elements.css",
70
+ "default": "./dist/css/elements.css"
71
+ },
72
+ ".": {
73
+ "types": "./dist/index.d.ts",
74
+ "default": "./dist/index.js"
75
+ },
76
+ "./gids-toggle-button.js": {
77
+ "types": "./dist/gids-toggle-button.d.ts",
78
+ "default": "./dist/gids-toggle-button.js"
79
+ },
80
+ "./dist/gids-toggle-button.js": {
81
+ "types": "./dist/gids-toggle-button.d.ts",
82
+ "default": "./dist/gids-toggle-button.js"
83
+ },
84
+ "./gids-icon.js": {
85
+ "types": "./dist/gids-icon.d.ts",
86
+ "default": "./dist/gids-icon.d.ts"
87
+ },
88
+ "./dist/gids-icon.js": {
89
+ "types": "./dist/gids-icon.d.ts",
90
+ "default": "./dist/gids-icon.d.ts"
91
+ },
92
+ "./customElements": {
93
+ "default": "./dist/custom-elements.json"
94
+ },
95
+ "./distPaths.js": {
96
+ "types": "./distPaths.js",
97
+ "node": "./distPaths.js"
98
+ },
99
+ "./scriptUtils.js": {
100
+ "types": "./scriptUtils.js",
101
+ "node": "./scriptUtils.js"
102
+ }
103
+ },
104
+ "peerDependencies": {
105
+ "@ganpatiinfo/gids-web-theme-interface": "^3.0.0"
106
+ },
107
+ "dependencies": {
108
+ "@floating-ui/dom": "1.7.6",
109
+ "clsx": "^2.1.1",
110
+ "@ganpatiinfo/gids-core-shared": "^3.0.0",
111
+ "@ganpatiinfo/gids-web-shared": "^3.0.0",
112
+ "composed-offset-position": "^0.0.6"
113
+ },
114
+ "devDependencies": {
115
+ "@custom-elements-manifest/analyzer": "^0.11.0",
116
+ "@fontsource/inter": "^5.2.8",
117
+ "@fontsource/libre-caslon-text": "^5.2.7",
118
+ "@ganpatiinfo/gids-liquid-renderer": "^3.0.0",
119
+ "@ganpatiinfo/gids-storybook-theme": "^3.0.0",
120
+ "@ganpatiinfo/gids-storybook-utilities": "^3.0.0",
121
+ "@ganpatiinfo/gids-web-dom-reference": "^3.0.0",
122
+ "@ganpatiinfo/gids-web-theme-ganpatiinfo": "^3.0.0",
123
+ "@jest/globals": "^30.2.0",
124
+ "@stencil/angular-output-target": "^1.3.0",
125
+ "@stencil/core": "^4.43.2",
126
+ "@stencil/react-output-target": "^1.4.2",
127
+ "@storybook/addon-a11y": "^10.2.17",
128
+ "@storybook/addon-docs": "^10.2.17",
129
+ "@storybook/addon-links": "^10.2.17",
130
+ "@storybook/web-components-vite": "^10.2.17",
131
+ "@types/jest": "^30.0.0",
132
+ "jest": "^30.3.0",
133
+ "jest-stencil-runner": "^0.0.19",
134
+ "puppeteer": "^24.39.0",
135
+ "sass": "^1.94.0",
136
+ "storybook": "^10.2.17",
137
+ "storybook-addon-tag-badges": "^3.0.6",
138
+ "vite": "^7.3.1",
139
+ "@stencil/sass": "^3.2.3"
140
+ },
141
+ "nx": {
142
+ "target": {
143
+ "build": {
144
+ "outputs": [
145
+ "{projectRoot}/dist",
146
+ "{projectRoot}/dist-dev",
147
+ "{projectRoot}/dist-bundled",
148
+ "{projectRoot}/src",
149
+ "{workspaceRoot}/packages/react-web/src/components/stencil-generated",
150
+ "{workspaceRoot}/angular/projects/angular-web/src/lib/stencil-generated"
151
+ ]
152
+ },
153
+ "build-site": {
154
+ "dependsOn": [
155
+ {
156
+ "target": "build-site",
157
+ "projects": [
158
+ "@ganpatiinfo/gids-website"
159
+ ]
160
+ }
161
+ ],
162
+ "outputs": [
163
+ "{workspaceRoot}/site/dist/workshop/gids-core-web/"
164
+ ]
165
+ }
166
+ }
167
+ },
168
+ "size-limit": [
169
+ {
170
+ "name": "JavaScript (exclusive GIDS dependencies package)",
171
+ "path": [
172
+ "dist/index.js",
173
+ "dist/gids-toggle-button.js"
174
+ ],
175
+ "import": {
176
+ "dist/index.js": "*",
177
+ "dist/gids-toggle-button.js": "{ GidsToggleButton }"
178
+ },
179
+ "ignore": [
180
+ "@ganpatiinfo/gids-core-shared",
181
+ "@ganpatiinfo/gids-web-shared"
182
+ ]
183
+ },
184
+ {
185
+ "name": "CSS core",
186
+ "path": "dist/index.css"
187
+ },
188
+ {
189
+ "name": "CSS (optional)",
190
+ "path": "dist/elements.css"
191
+ }
192
+ ]
160
193
  }
package/scriptUtils.js ADDED
@@ -0,0 +1,6 @@
1
+ import { createOrUpdateSymlinkDir } from '@ganpatiinfo/gids-web-shared/scriptUtils';
2
+ import { cssPath } from './distPaths.js';
3
+
4
+ export async function createCoreWebCssSymlink(symlinkPath) {
5
+ createOrUpdateSymlinkDir(cssPath(), symlinkPath, false);
6
+ }
@@ -1 +0,0 @@
1
- {"version":3,"sourceRoot":"","sources":["../src/styles/4-elements/body.scss","../src/styles/2-tools/typography.scss","../src/styles/4-elements/headings.scss","../src/styles/2-tools/links.scss","../src/styles/2-tools/card.scss"],"names":[],"mappings":"AAEA;EACC;EACA;EACA;ECFA;EACA;EACA;EACA;EACA;EAGC;EAGD;;;ACbD;EACC;;;ACCD;EAEC;EAEA;EACA;EACA;EAEA;;AAEA;EACC;;ACmKC;ED1JD;;;AAWD;EACC;EACA;EAWA;EACA;EACA","file":"elements.css"}
@@ -1 +0,0 @@
1
- {"file":"gids-toggle-button.js","mappings":"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","names":["GidsToggleButton","__stencil_proxyCustomElement","HTMLElement"],"sources":["src/components/html/_GidsSpinnerControl/GidsSpinnerControl.tsx","src/components/html/GidsButton/GidsButton.tsx","src/components/webComponents/GidsToggleButton/GidsToggleButton.tsx"],"sourcesContent":["import { h } from '@stencil/core';\nimport type { FunctionalComponent, JSXBase } from '@stencil/core/internal';\nimport { GidsSpinnerControlWebUtils } from '@ganpatiinfo/gids-web-shared';\nimport {\n\tGidsSpinnerControlCommonProps,\n\tGidsSpinnerControlCommonUtils,\n} from '@ganpatiinfo/gids-core-shared';\n\nconst { getGidsSpinnerControlClassNames } = GidsSpinnerControlWebUtils;\nconst { calculateStrokeDasharray, thickness, radius, centerPosition, viewBox } =\n\tGidsSpinnerControlCommonUtils;\n\nexport type GidsSpinnerControlProps = GidsSpinnerControlCommonProps &\n\tJSXBase.IntrinsicElements['svg'] & {\n\t\tclass?: string;\n\t};\n\nexport const GidsSpinnerControl: FunctionalComponent<\n\tGidsSpinnerControlCommonProps\n> = ({ size, indeterminate, value, max, ...rest }) => {\n\tlet style: Record<string, string> | undefined = undefined;\n\n\tif (!indeterminate) {\n\t\tconst dashArray = calculateStrokeDasharray(value, max ? max : 0);\n\t\tstyle = { strokeDashArray: dashArray, strokeDashoffset: '0' };\n\t}\n\n\treturn (\n\t\t<svg\n\t\t\tclass={getGidsSpinnerControlClassNames({ size, indeterminate, value })}\n\t\t\tviewBox={viewBox}\n\t\t\t{...rest}\n\t\t>\n\t\t\t<circle\n\t\t\t\tclass=\"gids-spinner-control__track\"\n\t\t\t\tcx={centerPosition}\n\t\t\t\tcy={centerPosition}\n\t\t\t\tr={radius}\n\t\t\t\tstroke-width={thickness}\n\t\t\t/>\n\t\t\t<circle\n\t\t\t\tstyle={style}\n\t\t\t\tclass=\"gids-spinner-control__progress\"\n\t\t\t\tcx={centerPosition}\n\t\t\t\tcy={centerPosition}\n\t\t\t\tr={radius}\n\t\t\t\tstroke-width={thickness}\n\t\t\t/>\n\t\t</svg>\n\t);\n};\n","import { h } from '@stencil/core';\nimport type { JSXBase, VNode } from '@stencil/core/internal';\nimport {\n\ttype PermittedGidsButtonElements,\n\ttype GidsButtonWebProps,\n\tGidsButtonWebUtils,\n\tnonEmpty,\n} from '@ganpatiinfo/gids-web-shared';\nimport { GidsSpinnerControl } from '../_GidsSpinnerControl/GidsSpinnerControl.js';\n\nconst { getGidsButtonClassNames } = GidsButtonWebUtils;\n\n/**\n * Props for the Stencil Functional Component implementation of GIDS Button.\n */\nexport type GidsButtonProps<E extends PermittedGidsButtonElements> =\n\tGidsButtonWebProps<VNode | VNode[], VNode | VNode[], E> &\n\t\tJSXBase.IntrinsicElements[E] & {\n\t\t\t/**\n\t\t\t * Whether to force the button to icon-only styling.\n\t\t\t */\n\t\t\tforceIconOnly?: boolean;\n\t\t};\n\n/**\n * Stencil functional component implementation of GIDS Button component.\n *\n * Only used internally by Stencil web components that need to render Buttons within their\n * JSX templates.\n *\n * @internal\n *\n * @param props\n * @param children\n * @returns\n */\nexport const GidsButton = <E extends PermittedGidsButtonElements = 'button'>(\n\t{\n\t\tappearance,\n\t\tsize,\n\t\tdestructive,\n\t\tloading,\n\t\twidth,\n\t\tleadingIcon,\n\t\ttrailingIcon,\n\t\tas,\n\t\tdisabled,\n\t\tclass: className,\n\t\tforceIconOnly = false,\n\t\t...rest\n\t}: GidsButtonProps<E>,\n\tchildren: VNode[],\n): VNode | VNode[] => {\n\tconst Element = as || 'button';\n\tconst spinnerSize = size === 'lg' || size === undefined ? 'md' : size;\n\n\t// Default to type=\"button\" if not provided, since HTML's default is \"submit\"\n\tif (Element === 'button' && !('type' in rest)) {\n\t\t(rest as JSXBase.IntrinsicElements['button']).type = 'button';\n\t}\n\n\treturn (\n\t\t// @ts-expect-error: TODO This used to work in TypeScript 4.x but not anymore\n\t\t<Element\n\t\t\tclass={getGidsButtonClassNames(\n\t\t\t\t{ appearance, size, destructive, loading, width },\n\t\t\t\tforceIconOnly ||\n\t\t\t\t\t(children.length === 0 &&\n\t\t\t\t\t\tnonEmpty(leadingIcon) &&\n\t\t\t\t\t\t!nonEmpty(trailingIcon)),\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\tdisabled={Element === 'button' ? disabled : undefined}\n\t\t\t{...rest}\n\t\t>\n\t\t\t<span class=\"gids-button__content\">\n\t\t\t\t{leadingIcon}\n\t\t\t\t{children}\n\t\t\t</span>\n\t\t\t{loading && (\n\t\t\t\t<GidsSpinnerControl\n\t\t\t\t\tsize={spinnerSize}\n\t\t\t\t\tindeterminate\n\t\t\t\t></GidsSpinnerControl>\n\t\t\t)}\n\t\t\t{trailingIcon}\n\t\t</Element>\n\t);\n};\n","import {\n\th,\n\tComponent,\n\tProp,\n\tElement,\n\tHost,\n\tEvent,\n\tEventEmitter,\n} from '@stencil/core';\nimport { GidsButton } from '../../html/GidsButton/GidsButton.js';\nimport { getConstructedGidsStylesheet } from '../../../utils/constructedGidsStylesheet.js';\nimport {\n\ttype GidsButtonSize,\n\ttype GidsToggleButtonAppearance,\n\ttype GidsButtonWidth,\n} from '@ganpatiinfo/gids-core-shared';\nimport { type GidsToggleButtonWebProps } from '@ganpatiinfo/gids-web-shared';\n\n@Component({\n\ttag: 'gids-toggle-button',\n\tshadow: true,\n})\nexport class GidsToggleButton\n\timplements Omit<GidsToggleButtonWebProps, 'children'>\n{\n\t/**\n\t * @internal\n\t */\n\t@Element() private _el: HTMLGidsToggleButtonElement;\n\n\t@Event()\n\tprivate select?: EventEmitter<boolean>;\n\n\t/**\n\t *\n\t * Reflected by `disabled` property\n\t *\n\t * @inheritdoc\n\t */\n\t@Prop({\n\t\treflect: true,\n\t})\n\tdisabled?: boolean;\n\n\t/**\n\t *\n\t * Reflected by `appearance` property\n\t *\n\t * @inheritdoc\n\t */\n\t@Prop({\n\t\treflect: true,\n\t})\n\tappearance?: GidsToggleButtonAppearance;\n\n\t/**\n\t *\n\t * Reflected by `size` property\n\t *\n\t * @inheritdoc\n\t */\n\t@Prop({\n\t\treflect: true,\n\t})\n\tsize?: GidsButtonSize;\n\n\t/**\n\t *\n\t * Reflected by `width` property\n\t *\n\t * @inheritdoc\n\t */\n\t@Prop({\n\t\treflect: true,\n\t})\n\twidth?: GidsButtonWidth;\n\n\t/**\n\t *\n\t * Reflected by `defaultSelected` property\n\t *\n\t * @inheritdoc\n\t */\n\t@Prop({\n\t\treflect: true,\n\t})\n\tdefaultSelected?: boolean;\n\n\t/**\n\t *\n\t * Only available as a property. There is no `selected` attribute\n\t *\n\t * @inheritdoc\n\t */\n\t@Prop({\n\t\treflect: true,\n\t\tattribute: null,\n\t})\n\tget selected(): boolean | undefined {\n\t\treturn this.#selected ?? this.defaultSelected;\n\t}\n\tset selected(value: unknown) {\n\t\tthis.#selected = value === undefined ? undefined : Boolean(value);\n\t}\n\n\tconstructor() {\n\t\tthis._toggle = this._toggle.bind(this);\n\t}\n\n\t/**\n\t * @internal\n\t */\n\t#selected?: boolean;\n\n\tconnectedCallback() {\n\t\tconst constructedGidsStylesheet = getConstructedGidsStylesheet();\n\t\tif (constructedGidsStylesheet !== undefined) {\n\t\t\tthis._el.shadowRoot?.adoptedStyleSheets.push(constructedGidsStylesheet);\n\t\t}\n\t}\n\n\tprivate _toggle() {\n\t\tconst toggledValue = !this.selected;\n\t\tthis._el.selected = toggledValue;\n\t\tthis.select?.emit(toggledValue);\n\t}\n\n\trender() {\n\t\treturn (\n\t\t\t<Host>\n\t\t\t\t<style>{`:host {\n display: ${this.width === 'full' ? 'block' : 'inline-block'}\n }`}</style>\n\t\t\t\t<GidsButton\n\t\t\t\t\tappearance={this.appearance}\n\t\t\t\t\tsize={this.size}\n\t\t\t\t\twidth={this.width}\n\t\t\t\t\tdisabled={this.disabled}\n\t\t\t\t\tonClick={this._toggle}\n\t\t\t\t\taria-pressed={this.selected ? 'true' : 'false'}\n\t\t\t\t\tleadingIcon={<slot name=\"leadingIcon\" />}\n\t\t\t\t\ttrailingIcon={<slot name=\"trailingIcon\" />}\n\t\t\t\t\tforceIconOnly={this._onlyHasLeadingIcon()}\n\t\t\t\t>\n\t\t\t\t\t<slot />\n\t\t\t\t</GidsButton>\n\t\t\t</Host>\n\t\t);\n\t}\n\n\tprivate _onlyHasLeadingIcon(): boolean {\n\t\tconst childNodes = this._el.childNodes;\n\t\tif (\n\t\t\tchildNodes.length === 1 &&\n\t\t\tchildNodes[0] instanceof window.Element &&\n\t\t\tchildNodes[0].slot === 'leadingIcon'\n\t\t) {\n\t\t\treturn true;\n\t\t}\n\t\treturn false;\n\t}\n}\n"],"version":3}