@aquera/nile-elements 0.0.14 → 0.0.16

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 (67) hide show
  1. package/.rollup.cache/opt/atlassian/pipelines/agent/build/packages/nile-elements/dist/src/index.d.ts +1 -0
  2. package/.rollup.cache/opt/atlassian/pipelines/agent/build/packages/nile-elements/dist/src/index.js +1 -0
  3. package/.rollup.cache/opt/atlassian/pipelines/agent/build/packages/nile-elements/dist/src/index.js.map +1 -1
  4. package/.rollup.cache/opt/atlassian/pipelines/agent/build/packages/nile-elements/dist/src/nile-calendar/nile-calendar.css.js +12 -10
  5. package/.rollup.cache/opt/atlassian/pipelines/agent/build/packages/nile-elements/dist/src/nile-calendar/nile-calendar.css.js.map +1 -1
  6. package/.rollup.cache/opt/atlassian/pipelines/agent/build/packages/nile-elements/dist/src/nile-calendar/nile-calendar.js +3 -3
  7. package/.rollup.cache/opt/atlassian/pipelines/agent/build/packages/nile-elements/dist/src/nile-calendar/nile-calendar.js.map +1 -1
  8. package/.rollup.cache/opt/atlassian/pipelines/agent/build/packages/nile-elements/dist/src/nile-error-notification/index.d.ts +1 -0
  9. package/.rollup.cache/opt/atlassian/pipelines/agent/build/packages/nile-elements/dist/src/nile-error-notification/index.js +2 -0
  10. package/.rollup.cache/opt/atlassian/pipelines/agent/build/packages/nile-elements/dist/src/nile-error-notification/index.js.map +1 -0
  11. package/.rollup.cache/opt/atlassian/pipelines/agent/build/packages/nile-elements/dist/src/nile-error-notification/nile-error-notification.css.d.ts +12 -0
  12. package/.rollup.cache/opt/atlassian/pipelines/agent/build/packages/nile-elements/dist/src/nile-error-notification/nile-error-notification.css.js +37 -0
  13. package/.rollup.cache/opt/atlassian/pipelines/agent/build/packages/nile-elements/dist/src/nile-error-notification/nile-error-notification.css.js.map +1 -0
  14. package/.rollup.cache/opt/atlassian/pipelines/agent/build/packages/nile-elements/dist/src/nile-error-notification/nile-error-notification.d.ts +32 -0
  15. package/.rollup.cache/opt/atlassian/pipelines/agent/build/packages/nile-elements/dist/src/nile-error-notification/nile-error-notification.js +60 -0
  16. package/.rollup.cache/opt/atlassian/pipelines/agent/build/packages/nile-elements/dist/src/nile-error-notification/nile-error-notification.js.map +1 -0
  17. package/.rollup.cache/opt/atlassian/pipelines/agent/build/packages/nile-elements/dist/src/nile-select/nile-select.js +2 -3
  18. package/.rollup.cache/opt/atlassian/pipelines/agent/build/packages/nile-elements/dist/src/nile-select/nile-select.js.map +1 -1
  19. package/.rollup.cache/opt/atlassian/pipelines/agent/build/packages/nile-elements/dist/tsconfig.tsbuildinfo +1 -1
  20. package/dist/index.cjs.js +1 -1
  21. package/dist/index.esm.js +1 -1
  22. package/dist/index.iife.js +62 -26
  23. package/dist/nile-calendar/nile-calendar.cjs.js +1 -1
  24. package/dist/nile-calendar/nile-calendar.cjs.js.map +1 -1
  25. package/dist/nile-calendar/nile-calendar.css.cjs.js +1 -1
  26. package/dist/nile-calendar/nile-calendar.css.cjs.js.map +1 -1
  27. package/dist/nile-calendar/nile-calendar.css.esm.js +14 -12
  28. package/dist/nile-calendar/nile-calendar.esm.js +3 -3
  29. package/dist/nile-error-notification/index.cjs.js +2 -0
  30. package/dist/nile-error-notification/index.cjs.js.map +1 -0
  31. package/dist/nile-error-notification/index.esm.js +1 -0
  32. package/dist/nile-error-notification/nile-error-notification.cjs.js +2 -0
  33. package/dist/nile-error-notification/nile-error-notification.cjs.js.map +1 -0
  34. package/dist/nile-error-notification/nile-error-notification.css.cjs.js +2 -0
  35. package/dist/nile-error-notification/nile-error-notification.css.cjs.js.map +1 -0
  36. package/dist/nile-error-notification/nile-error-notification.css.esm.js +25 -0
  37. package/dist/nile-error-notification/nile-error-notification.esm.js +12 -0
  38. package/dist/nile-select/nile-select.cjs.js +1 -1
  39. package/dist/nile-select/nile-select.cjs.js.map +1 -1
  40. package/dist/nile-select/nile-select.esm.js +1 -2
  41. package/dist/src/index.d.ts +1 -0
  42. package/dist/src/index.js +1 -0
  43. package/dist/src/index.js.map +1 -1
  44. package/dist/src/nile-calendar/nile-calendar.css.js +12 -10
  45. package/dist/src/nile-calendar/nile-calendar.css.js.map +1 -1
  46. package/dist/src/nile-calendar/nile-calendar.js +3 -3
  47. package/dist/src/nile-calendar/nile-calendar.js.map +1 -1
  48. package/dist/src/nile-error-notification/index.d.ts +1 -0
  49. package/dist/src/nile-error-notification/index.js +2 -0
  50. package/dist/src/nile-error-notification/index.js.map +1 -0
  51. package/dist/src/nile-error-notification/nile-error-notification.css.d.ts +12 -0
  52. package/dist/src/nile-error-notification/nile-error-notification.css.js +37 -0
  53. package/dist/src/nile-error-notification/nile-error-notification.css.js.map +1 -0
  54. package/dist/src/nile-error-notification/nile-error-notification.d.ts +32 -0
  55. package/dist/src/nile-error-notification/nile-error-notification.js +60 -0
  56. package/dist/src/nile-error-notification/nile-error-notification.js.map +1 -0
  57. package/dist/src/nile-select/nile-select.js +2 -3
  58. package/dist/src/nile-select/nile-select.js.map +1 -1
  59. package/dist/tsconfig.tsbuildinfo +1 -1
  60. package/package.json +1 -1
  61. package/src/index.ts +1 -0
  62. package/src/nile-calendar/nile-calendar.css.ts +12 -10
  63. package/src/nile-calendar/nile-calendar.ts +3 -3
  64. package/src/nile-error-notification/index.ts +1 -0
  65. package/src/nile-error-notification/nile-error-notification.css.ts +39 -0
  66. package/src/nile-error-notification/nile-error-notification.ts +70 -0
  67. package/src/nile-select/nile-select.ts +2 -3
@@ -9,13 +9,13 @@ const D=window,i=D.ShadowRoot&&(void 0===D.ShadyCSS||D.ShadyCSS.nativeShadow)&&"
9
9
  * @license
10
10
  * Copyright 2017 Google LLC
11
11
  * SPDX-License-Identifier: BSD-3-Clause
12
- */;var T;const z=window,t=z.trustedTypes,A=t?t.emptyScript:"",y=z.reactiveElementPolyfillSupport,c={toAttribute(M,N){switch(N){case Boolean:M=M?A:null;break;case Object:case Array:M=null==M?M:JSON.stringify(M)}return M},fromAttribute(M,N){let D=M;switch(N){case Boolean:D=null!==M;break;case Number:D=null===M?null:Number(M);break;case Object:case Array:try{D=JSON.parse(M)}catch(M){D=null}}return D}},x=(M,N)=>N!==M&&(N==N||M==M),s={attribute:!0,type:String,converter:c,reflect:!1,hasChanged:x},e="finalized";let l=class extends HTMLElement{constructor(){super(),this._$Ei=new Map,this.isUpdatePending=!1,this.hasUpdated=!1,this._$El=null,this._$Eu()}static addInitializer(M){var N;this.finalize(),(null!==(N=this.h)&&void 0!==N?N:this.h=[]).push(M)}static get observedAttributes(){this.finalize();const M=[];return this.elementProperties.forEach(((N,D)=>{const i=this._$Ep(D,N);void 0!==i&&(this._$Ev.set(i,D),M.push(i))})),M}static createProperty(M,N=s){if(N.state&&(N.attribute=!1),this.finalize(),this.elementProperties.set(M,N),!N.noAccessor&&!this.prototype.hasOwnProperty(M)){const D="symbol"==typeof M?Symbol():"__"+M,i=this.getPropertyDescriptor(M,D,N);void 0!==i&&Object.defineProperty(this.prototype,M,i)}}static getPropertyDescriptor(M,N,D){return{get(){return this[N]},set(i){const j=this[M];this[N]=i,this.requestUpdate(M,j,D)},configurable:!0,enumerable:!0}}static getPropertyOptions(M){return this.elementProperties.get(M)||s}static finalize(){if(this.hasOwnProperty(e))return!1;this[e]=!0;const M=Object.getPrototypeOf(this);if(M.finalize(),void 0!==M.h&&(this.h=[...M.h]),this.elementProperties=new Map(M.elementProperties),this._$Ev=new Map,this.hasOwnProperty("properties")){const M=this.properties,N=[...Object.getOwnPropertyNames(M),...Object.getOwnPropertySymbols(M)];for(const D of N)this.createProperty(D,M[D])}return this.elementStyles=this.finalizeStyles(this.styles),!0}static finalizeStyles(M){const N=[];if(Array.isArray(M)){const D=new Set(M.flat(1/0).reverse());for(const M of D)N.unshift(L(M))}else void 0!==M&&N.push(L(M));return N}static _$Ep(M,N){const D=N.attribute;return!1===D?void 0:"string"==typeof D?D:"string"==typeof M?M.toLowerCase():void 0}_$Eu(){var M;this._$E_=new Promise((M=>this.enableUpdating=M)),this._$AL=new Map,this._$Eg(),this.requestUpdate(),null===(M=this.constructor.h)||void 0===M||M.forEach((M=>M(this)))}addController(M){var N,D;(null!==(N=this._$ES)&&void 0!==N?N:this._$ES=[]).push(M),void 0!==this.renderRoot&&this.isConnected&&(null===(D=M.hostConnected)||void 0===D||D.call(M))}removeController(M){var N;null===(N=this._$ES)||void 0===N||N.splice(this._$ES.indexOf(M)>>>0,1)}_$Eg(){this.constructor.elementProperties.forEach(((M,N)=>{this.hasOwnProperty(N)&&(this._$Ei.set(N,this[N]),delete this[N])}))}createRenderRoot(){var M;const N=null!==(M=this.shadowRoot)&&void 0!==M?M:this.attachShadow(this.constructor.shadowRootOptions);return((M,N)=>{i?M.adoptedStyleSheets=N.map((M=>M instanceof CSSStyleSheet?M:M.styleSheet)):N.forEach((N=>{const i=document.createElement("style"),j=D.litNonce;void 0!==j&&i.setAttribute("nonce",j),i.textContent=N.cssText,M.appendChild(i)}))})(N,this.constructor.elementStyles),N}connectedCallback(){var M;void 0===this.renderRoot&&(this.renderRoot=this.createRenderRoot()),this.enableUpdating(!0),null===(M=this._$ES)||void 0===M||M.forEach((M=>{var N;return null===(N=M.hostConnected)||void 0===N?void 0:N.call(M)}))}enableUpdating(M){}disconnectedCallback(){var M;null===(M=this._$ES)||void 0===M||M.forEach((M=>{var N;return null===(N=M.hostDisconnected)||void 0===N?void 0:N.call(M)}))}attributeChangedCallback(M,N,D){this._$AK(M,D)}_$EO(M,N,D=s){var i;const j=this.constructor._$Ep(M,D);if(void 0!==j&&!0===D.reflect){const I=(void 0!==(null===(i=D.converter)||void 0===i?void 0:i.toAttribute)?D.converter:c).toAttribute(N,D.type);this._$El=M,null==I?this.removeAttribute(j):this.setAttribute(j,I),this._$El=null}}_$AK(M,N){var D;const i=this.constructor,j=i._$Ev.get(M);if(void 0!==j&&this._$El!==j){const M=i.getPropertyOptions(j),I="function"==typeof M.converter?{fromAttribute:M.converter}:void 0!==(null===(D=M.converter)||void 0===D?void 0:D.fromAttribute)?M.converter:c;this._$El=j,this[j]=I.fromAttribute(N,M.type),this._$El=null}}requestUpdate(M,N,D){let i=!0;void 0!==M&&(((D=D||this.constructor.getPropertyOptions(M)).hasChanged||x)(this[M],N)?(this._$AL.has(M)||this._$AL.set(M,N),!0===D.reflect&&this._$El!==M&&(void 0===this._$EC&&(this._$EC=new Map),this._$EC.set(M,D))):i=!1),!this.isUpdatePending&&i&&(this._$E_=this._$Ej())}async _$Ej(){this.isUpdatePending=!0;try{await this._$E_}catch(M){Promise.reject(M)}const M=this.scheduleUpdate();return null!=M&&await M,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){var M;if(!this.isUpdatePending)return;this.hasUpdated,this._$Ei&&(this._$Ei.forEach(((M,N)=>this[N]=M)),this._$Ei=void 0);let N=!1;const D=this._$AL;try{N=this.shouldUpdate(D),N?(this.willUpdate(D),null===(M=this._$ES)||void 0===M||M.forEach((M=>{var N;return null===(N=M.hostUpdate)||void 0===N?void 0:N.call(M)})),this.update(D)):this._$Ek()}catch(M){throw N=!1,this._$Ek(),M}N&&this._$AE(D)}willUpdate(M){}_$AE(M){var N;null===(N=this._$ES)||void 0===N||N.forEach((M=>{var N;return null===(N=M.hostUpdated)||void 0===N?void 0:N.call(M)})),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(M)),this.updated(M)}_$Ek(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$E_}shouldUpdate(M){return!0}update(M){void 0!==this._$EC&&(this._$EC.forEach(((M,N)=>this._$EO(N,this[N],M))),this._$EC=void 0),this._$Ek()}updated(M){}firstUpdated(M){}};
12
+ */;var T;const z=window,t=z.trustedTypes,A=t?t.emptyScript:"",y=z.reactiveElementPolyfillSupport,c={toAttribute(M,N){switch(N){case Boolean:M=M?A:null;break;case Object:case Array:M=null==M?M:JSON.stringify(M)}return M},fromAttribute(M,N){let D=M;switch(N){case Boolean:D=null!==M;break;case Number:D=null===M?null:Number(M);break;case Object:case Array:try{D=JSON.parse(M)}catch(M){D=null}}return D}},x=(M,N)=>N!==M&&(N==N||M==M),e={attribute:!0,type:String,converter:c,reflect:!1,hasChanged:x},s="finalized";let l=class extends HTMLElement{constructor(){super(),this._$Ei=new Map,this.isUpdatePending=!1,this.hasUpdated=!1,this._$El=null,this._$Eu()}static addInitializer(M){var N;this.finalize(),(null!==(N=this.h)&&void 0!==N?N:this.h=[]).push(M)}static get observedAttributes(){this.finalize();const M=[];return this.elementProperties.forEach(((N,D)=>{const i=this._$Ep(D,N);void 0!==i&&(this._$Ev.set(i,D),M.push(i))})),M}static createProperty(M,N=e){if(N.state&&(N.attribute=!1),this.finalize(),this.elementProperties.set(M,N),!N.noAccessor&&!this.prototype.hasOwnProperty(M)){const D="symbol"==typeof M?Symbol():"__"+M,i=this.getPropertyDescriptor(M,D,N);void 0!==i&&Object.defineProperty(this.prototype,M,i)}}static getPropertyDescriptor(M,N,D){return{get(){return this[N]},set(i){const j=this[M];this[N]=i,this.requestUpdate(M,j,D)},configurable:!0,enumerable:!0}}static getPropertyOptions(M){return this.elementProperties.get(M)||e}static finalize(){if(this.hasOwnProperty(s))return!1;this[s]=!0;const M=Object.getPrototypeOf(this);if(M.finalize(),void 0!==M.h&&(this.h=[...M.h]),this.elementProperties=new Map(M.elementProperties),this._$Ev=new Map,this.hasOwnProperty("properties")){const M=this.properties,N=[...Object.getOwnPropertyNames(M),...Object.getOwnPropertySymbols(M)];for(const D of N)this.createProperty(D,M[D])}return this.elementStyles=this.finalizeStyles(this.styles),!0}static finalizeStyles(M){const N=[];if(Array.isArray(M)){const D=new Set(M.flat(1/0).reverse());for(const M of D)N.unshift(L(M))}else void 0!==M&&N.push(L(M));return N}static _$Ep(M,N){const D=N.attribute;return!1===D?void 0:"string"==typeof D?D:"string"==typeof M?M.toLowerCase():void 0}_$Eu(){var M;this._$E_=new Promise((M=>this.enableUpdating=M)),this._$AL=new Map,this._$Eg(),this.requestUpdate(),null===(M=this.constructor.h)||void 0===M||M.forEach((M=>M(this)))}addController(M){var N,D;(null!==(N=this._$ES)&&void 0!==N?N:this._$ES=[]).push(M),void 0!==this.renderRoot&&this.isConnected&&(null===(D=M.hostConnected)||void 0===D||D.call(M))}removeController(M){var N;null===(N=this._$ES)||void 0===N||N.splice(this._$ES.indexOf(M)>>>0,1)}_$Eg(){this.constructor.elementProperties.forEach(((M,N)=>{this.hasOwnProperty(N)&&(this._$Ei.set(N,this[N]),delete this[N])}))}createRenderRoot(){var M;const N=null!==(M=this.shadowRoot)&&void 0!==M?M:this.attachShadow(this.constructor.shadowRootOptions);return((M,N)=>{i?M.adoptedStyleSheets=N.map((M=>M instanceof CSSStyleSheet?M:M.styleSheet)):N.forEach((N=>{const i=document.createElement("style"),j=D.litNonce;void 0!==j&&i.setAttribute("nonce",j),i.textContent=N.cssText,M.appendChild(i)}))})(N,this.constructor.elementStyles),N}connectedCallback(){var M;void 0===this.renderRoot&&(this.renderRoot=this.createRenderRoot()),this.enableUpdating(!0),null===(M=this._$ES)||void 0===M||M.forEach((M=>{var N;return null===(N=M.hostConnected)||void 0===N?void 0:N.call(M)}))}enableUpdating(M){}disconnectedCallback(){var M;null===(M=this._$ES)||void 0===M||M.forEach((M=>{var N;return null===(N=M.hostDisconnected)||void 0===N?void 0:N.call(M)}))}attributeChangedCallback(M,N,D){this._$AK(M,D)}_$EO(M,N,D=e){var i;const j=this.constructor._$Ep(M,D);if(void 0!==j&&!0===D.reflect){const I=(void 0!==(null===(i=D.converter)||void 0===i?void 0:i.toAttribute)?D.converter:c).toAttribute(N,D.type);this._$El=M,null==I?this.removeAttribute(j):this.setAttribute(j,I),this._$El=null}}_$AK(M,N){var D;const i=this.constructor,j=i._$Ev.get(M);if(void 0!==j&&this._$El!==j){const M=i.getPropertyOptions(j),I="function"==typeof M.converter?{fromAttribute:M.converter}:void 0!==(null===(D=M.converter)||void 0===D?void 0:D.fromAttribute)?M.converter:c;this._$El=j,this[j]=I.fromAttribute(N,M.type),this._$El=null}}requestUpdate(M,N,D){let i=!0;void 0!==M&&(((D=D||this.constructor.getPropertyOptions(M)).hasChanged||x)(this[M],N)?(this._$AL.has(M)||this._$AL.set(M,N),!0===D.reflect&&this._$El!==M&&(void 0===this._$EC&&(this._$EC=new Map),this._$EC.set(M,D))):i=!1),!this.isUpdatePending&&i&&(this._$E_=this._$Ej())}async _$Ej(){this.isUpdatePending=!0;try{await this._$E_}catch(M){Promise.reject(M)}const M=this.scheduleUpdate();return null!=M&&await M,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){var M;if(!this.isUpdatePending)return;this.hasUpdated,this._$Ei&&(this._$Ei.forEach(((M,N)=>this[N]=M)),this._$Ei=void 0);let N=!1;const D=this._$AL;try{N=this.shouldUpdate(D),N?(this.willUpdate(D),null===(M=this._$ES)||void 0===M||M.forEach((M=>{var N;return null===(N=M.hostUpdate)||void 0===N?void 0:N.call(M)})),this.update(D)):this._$Ek()}catch(M){throw N=!1,this._$Ek(),M}N&&this._$AE(D)}willUpdate(M){}_$AE(M){var N;null===(N=this._$ES)||void 0===N||N.forEach((M=>{var N;return null===(N=M.hostUpdated)||void 0===N?void 0:N.call(M)})),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(M)),this.updated(M)}_$Ek(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$E_}shouldUpdate(M){return!0}update(M){void 0!==this._$EC&&(this._$EC.forEach(((M,N)=>this._$EO(N,this[N],M))),this._$EC=void 0),this._$Ek()}updated(M){}firstUpdated(M){}};
13
13
  /**
14
14
  * @license
15
15
  * Copyright 2017 Google LLC
16
16
  * SPDX-License-Identifier: BSD-3-Clause
17
17
  */
18
- var o;l[e]=!0,l.elementProperties=new Map,l.elementStyles=[],l.shadowRootOptions={mode:"open"},null==y||y({ReactiveElement:l}),(null!==(T=z.reactiveElementVersions)&&void 0!==T?T:z.reactiveElementVersions=[]).push("1.6.3");const a=window,w=a.trustedTypes,O=w?w.createPolicy("lit-html",{createHTML:M=>M}):void 0,E="$lit$",S=`lit$${(Math.random()+"").slice(9)}$`,n="?"+S,d=`<${n}>`,C=document,r=()=>C.createComment(""),U=M=>null===M||"object"!=typeof M&&"function"!=typeof M,k=Array.isArray,Q="[ \t\n\f\r]",h=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,Y=/-->/g,b=/>/g,Z=RegExp(`>|${Q}(?:([^\\s"'>=/]+)(${Q}*=${Q}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`,"g"),m=/'/g,p=/"/g,W=/^(?:script|style|textarea|title)$/i,V=(M=>(N,...D)=>({_$litType$:M,strings:N,values:D}))(1),v=Symbol.for("lit-noChange"),G=Symbol.for("lit-nothing"),B=new WeakMap,P=C.createTreeWalker(C,129,null,!1);function R(M,N){if(!Array.isArray(M)||!M.hasOwnProperty("raw"))throw Error("invalid template strings array");return void 0!==O?O.createHTML(N):N}const H=(M,N)=>{const D=M.length-1,i=[];let j,I=2===N?"<svg>":"",g=h;for(let N=0;N<D;N++){const D=M[N];let u,L,T=-1,z=0;for(;z<D.length&&(g.lastIndex=z,L=g.exec(D),null!==L);)z=g.lastIndex,g===h?"!--"===L[1]?g=Y:void 0!==L[1]?g=b:void 0!==L[2]?(W.test(L[2])&&(j=RegExp("</"+L[2],"g")),g=Z):void 0!==L[3]&&(g=Z):g===Z?">"===L[0]?(g=null!=j?j:h,T=-1):void 0===L[1]?T=-2:(T=g.lastIndex-L[2].length,u=L[1],g=void 0===L[3]?Z:'"'===L[3]?p:m):g===p||g===m?g=Z:g===Y||g===b?g=h:(g=Z,j=void 0);const t=g===Z&&M[N+1].startsWith("/>")?" ":"";I+=g===h?D+d:T>=0?(i.push(u),D.slice(0,T)+E+D.slice(T)+S+t):D+S+(-2===T?(i.push(void 0),N):t)}return[R(M,I+(M[D]||"<?>")+(2===N?"</svg>":"")),i]};class F{constructor({strings:M,_$litType$:N},D){let i;this.parts=[];let j=0,I=0;const g=M.length-1,u=this.parts,[L,T]=H(M,N);if(this.el=F.createElement(L,D),P.currentNode=this.el.content,2===N){const M=this.el.content,N=M.firstChild;N.remove(),M.append(...N.childNodes)}for(;null!==(i=P.nextNode())&&u.length<g;){if(1===i.nodeType){if(i.hasAttributes()){const M=[];for(const N of i.getAttributeNames())if(N.endsWith(E)||N.startsWith(S)){const D=T[I++];if(M.push(N),void 0!==D){const M=i.getAttribute(D.toLowerCase()+E).split(S),N=/([.?@])?(.*)/.exec(D);u.push({type:1,index:j,name:N[2],strings:M,ctor:"."===N[1]?$:"?"===N[1]?q:"@"===N[1]?MM:_})}else u.push({type:6,index:j})}for(const N of M)i.removeAttribute(N)}if(W.test(i.tagName)){const M=i.textContent.split(S),N=M.length-1;if(N>0){i.textContent=w?w.emptyScript:"";for(let D=0;D<N;D++)i.append(M[D],r()),P.nextNode(),u.push({type:2,index:++j});i.append(M[N],r())}}}else if(8===i.nodeType)if(i.data===n)u.push({type:2,index:j});else{let M=-1;for(;-1!==(M=i.data.indexOf(S,M+1));)u.push({type:7,index:j}),M+=S.length-1}j++}}static createElement(M,N){const D=C.createElement("template");return D.innerHTML=M,D}}function J(M,N,D=M,i){var j,I,g,u;if(N===v)return N;let L=void 0!==i?null===(j=D._$Co)||void 0===j?void 0:j[i]:D._$Cl;const T=U(N)?void 0:N._$litDirective$;return(null==L?void 0:L.constructor)!==T&&(null===(I=null==L?void 0:L._$AO)||void 0===I||I.call(L,!1),void 0===T?L=void 0:(L=new T(M),L._$AT(M,D,i)),void 0!==i?(null!==(g=(u=D)._$Co)&&void 0!==g?g:u._$Co=[])[i]=L:D._$Cl=L),void 0!==L&&(N=J(M,L._$AS(M,N.values),L,i)),N}class f{constructor(M,N){this._$AV=[],this._$AN=void 0,this._$AD=M,this._$AM=N}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(M){var N;const{el:{content:D},parts:i}=this._$AD,j=(null!==(N=null==M?void 0:M.creationScope)&&void 0!==N?N:C).importNode(D,!0);P.currentNode=j;let I=P.nextNode(),g=0,u=0,L=i[0];for(;void 0!==L;){if(g===L.index){let N;2===L.type?N=new X(I,I.nextSibling,this,M):1===L.type?N=new L.ctor(I,L.name,L.strings,this,M):6===L.type&&(N=new NM(I,this,M)),this._$AV.push(N),L=i[++u]}g!==(null==L?void 0:L.index)&&(I=P.nextNode(),g++)}return P.currentNode=C,j}v(M){let N=0;for(const D of this._$AV)void 0!==D&&(void 0!==D.strings?(D._$AI(M,D,N),N+=D.strings.length-2):D._$AI(M[N])),N++}}class X{constructor(M,N,D,i){var j;this.type=2,this._$AH=G,this._$AN=void 0,this._$AA=M,this._$AB=N,this._$AM=D,this.options=i,this._$Cp=null===(j=null==i?void 0:i.isConnected)||void 0===j||j}get _$AU(){var M,N;return null!==(N=null===(M=this._$AM)||void 0===M?void 0:M._$AU)&&void 0!==N?N:this._$Cp}get parentNode(){let M=this._$AA.parentNode;const N=this._$AM;return void 0!==N&&11===(null==M?void 0:M.nodeType)&&(M=N.parentNode),M}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(M,N=this){M=J(this,M,N),U(M)?M===G||null==M||""===M?(this._$AH!==G&&this._$AR(),this._$AH=G):M!==this._$AH&&M!==v&&this._(M):void 0!==M._$litType$?this.g(M):void 0!==M.nodeType?this.$(M):(M=>k(M)||"function"==typeof(null==M?void 0:M[Symbol.iterator]))(M)?this.T(M):this._(M)}k(M){return this._$AA.parentNode.insertBefore(M,this._$AB)}$(M){this._$AH!==M&&(this._$AR(),this._$AH=this.k(M))}_(M){this._$AH!==G&&U(this._$AH)?this._$AA.nextSibling.data=M:this.$(C.createTextNode(M)),this._$AH=M}g(M){var N;const{values:D,_$litType$:i}=M,j="number"==typeof i?this._$AC(M):(void 0===i.el&&(i.el=F.createElement(R(i.h,i.h[0]),this.options)),i);if((null===(N=this._$AH)||void 0===N?void 0:N._$AD)===j)this._$AH.v(D);else{const M=new f(j,this),N=M.u(this.options);M.v(D),this.$(N),this._$AH=M}}_$AC(M){let N=B.get(M.strings);return void 0===N&&B.set(M.strings,N=new F(M)),N}T(M){k(this._$AH)||(this._$AH=[],this._$AR());const N=this._$AH;let D,i=0;for(const j of M)i===N.length?N.push(D=new X(this.k(r()),this.k(r()),this,this.options)):D=N[i],D._$AI(j),i++;i<N.length&&(this._$AR(D&&D._$AB.nextSibling,i),N.length=i)}_$AR(M=this._$AA.nextSibling,N){var D;for(null===(D=this._$AP)||void 0===D||D.call(this,!1,!0,N);M&&M!==this._$AB;){const N=M.nextSibling;M.remove(),M=N}}setConnected(M){var N;void 0===this._$AM&&(this._$Cp=M,null===(N=this._$AP)||void 0===N||N.call(this,M))}}class _{constructor(M,N,D,i,j){this.type=1,this._$AH=G,this._$AN=void 0,this.element=M,this.name=N,this._$AM=i,this.options=j,D.length>2||""!==D[0]||""!==D[1]?(this._$AH=Array(D.length-1).fill(new String),this.strings=D):this._$AH=G}get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}_$AI(M,N=this,D,i){const j=this.strings;let I=!1;if(void 0===j)M=J(this,M,N,0),I=!U(M)||M!==this._$AH&&M!==v,I&&(this._$AH=M);else{const i=M;let g,u;for(M=j[0],g=0;g<j.length-1;g++)u=J(this,i[D+g],N,g),u===v&&(u=this._$AH[g]),I||(I=!U(u)||u!==this._$AH[g]),u===G?M=G:M!==G&&(M+=(null!=u?u:"")+j[g+1]),this._$AH[g]=u}I&&!i&&this.j(M)}j(M){M===G?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,null!=M?M:"")}}class $ extends _{constructor(){super(...arguments),this.type=3}j(M){this.element[this.name]=M===G?void 0:M}}const K=w?w.emptyScript:"";class q extends _{constructor(){super(...arguments),this.type=4}j(M){M&&M!==G?this.element.setAttribute(this.name,K):this.element.removeAttribute(this.name)}}class MM extends _{constructor(M,N,D,i,j){super(M,N,D,i,j),this.type=5}_$AI(M,N=this){var D;if((M=null!==(D=J(this,M,N,0))&&void 0!==D?D:G)===v)return;const i=this._$AH,j=M===G&&i!==G||M.capture!==i.capture||M.once!==i.once||M.passive!==i.passive,I=M!==G&&(i===G||j);j&&this.element.removeEventListener(this.name,this,i),I&&this.element.addEventListener(this.name,this,M),this._$AH=M}handleEvent(M){var N,D;"function"==typeof this._$AH?this._$AH.call(null!==(D=null===(N=this.options)||void 0===N?void 0:N.host)&&void 0!==D?D:this.element,M):this._$AH.handleEvent(M)}}class NM{constructor(M,N,D){this.element=M,this.type=6,this._$AN=void 0,this._$AM=N,this.options=D}get _$AU(){return this._$AM._$AU}_$AI(M){J(this,M)}}const DM=a.litHtmlPolyfillSupport;null==DM||DM(F,X),(null!==(o=a.litHtmlVersions)&&void 0!==o?o:a.litHtmlVersions=[]).push("2.8.0");
18
+ var o;l[s]=!0,l.elementProperties=new Map,l.elementStyles=[],l.shadowRootOptions={mode:"open"},null==y||y({ReactiveElement:l}),(null!==(T=z.reactiveElementVersions)&&void 0!==T?T:z.reactiveElementVersions=[]).push("1.6.3");const a=window,w=a.trustedTypes,O=w?w.createPolicy("lit-html",{createHTML:M=>M}):void 0,E="$lit$",S=`lit$${(Math.random()+"").slice(9)}$`,n="?"+S,d=`<${n}>`,C=document,r=()=>C.createComment(""),U=M=>null===M||"object"!=typeof M&&"function"!=typeof M,k=Array.isArray,Q="[ \t\n\f\r]",h=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,Y=/-->/g,b=/>/g,Z=RegExp(`>|${Q}(?:([^\\s"'>=/]+)(${Q}*=${Q}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`,"g"),m=/'/g,p=/"/g,W=/^(?:script|style|textarea|title)$/i,V=(M=>(N,...D)=>({_$litType$:M,strings:N,values:D}))(1),v=Symbol.for("lit-noChange"),G=Symbol.for("lit-nothing"),B=new WeakMap,P=C.createTreeWalker(C,129,null,!1);function R(M,N){if(!Array.isArray(M)||!M.hasOwnProperty("raw"))throw Error("invalid template strings array");return void 0!==O?O.createHTML(N):N}const H=(M,N)=>{const D=M.length-1,i=[];let j,I=2===N?"<svg>":"",g=h;for(let N=0;N<D;N++){const D=M[N];let u,L,T=-1,z=0;for(;z<D.length&&(g.lastIndex=z,L=g.exec(D),null!==L);)z=g.lastIndex,g===h?"!--"===L[1]?g=Y:void 0!==L[1]?g=b:void 0!==L[2]?(W.test(L[2])&&(j=RegExp("</"+L[2],"g")),g=Z):void 0!==L[3]&&(g=Z):g===Z?">"===L[0]?(g=null!=j?j:h,T=-1):void 0===L[1]?T=-2:(T=g.lastIndex-L[2].length,u=L[1],g=void 0===L[3]?Z:'"'===L[3]?p:m):g===p||g===m?g=Z:g===Y||g===b?g=h:(g=Z,j=void 0);const t=g===Z&&M[N+1].startsWith("/>")?" ":"";I+=g===h?D+d:T>=0?(i.push(u),D.slice(0,T)+E+D.slice(T)+S+t):D+S+(-2===T?(i.push(void 0),N):t)}return[R(M,I+(M[D]||"<?>")+(2===N?"</svg>":"")),i]};class F{constructor({strings:M,_$litType$:N},D){let i;this.parts=[];let j=0,I=0;const g=M.length-1,u=this.parts,[L,T]=H(M,N);if(this.el=F.createElement(L,D),P.currentNode=this.el.content,2===N){const M=this.el.content,N=M.firstChild;N.remove(),M.append(...N.childNodes)}for(;null!==(i=P.nextNode())&&u.length<g;){if(1===i.nodeType){if(i.hasAttributes()){const M=[];for(const N of i.getAttributeNames())if(N.endsWith(E)||N.startsWith(S)){const D=T[I++];if(M.push(N),void 0!==D){const M=i.getAttribute(D.toLowerCase()+E).split(S),N=/([.?@])?(.*)/.exec(D);u.push({type:1,index:j,name:N[2],strings:M,ctor:"."===N[1]?$:"?"===N[1]?q:"@"===N[1]?MM:_})}else u.push({type:6,index:j})}for(const N of M)i.removeAttribute(N)}if(W.test(i.tagName)){const M=i.textContent.split(S),N=M.length-1;if(N>0){i.textContent=w?w.emptyScript:"";for(let D=0;D<N;D++)i.append(M[D],r()),P.nextNode(),u.push({type:2,index:++j});i.append(M[N],r())}}}else if(8===i.nodeType)if(i.data===n)u.push({type:2,index:j});else{let M=-1;for(;-1!==(M=i.data.indexOf(S,M+1));)u.push({type:7,index:j}),M+=S.length-1}j++}}static createElement(M,N){const D=C.createElement("template");return D.innerHTML=M,D}}function J(M,N,D=M,i){var j,I,g,u;if(N===v)return N;let L=void 0!==i?null===(j=D._$Co)||void 0===j?void 0:j[i]:D._$Cl;const T=U(N)?void 0:N._$litDirective$;return(null==L?void 0:L.constructor)!==T&&(null===(I=null==L?void 0:L._$AO)||void 0===I||I.call(L,!1),void 0===T?L=void 0:(L=new T(M),L._$AT(M,D,i)),void 0!==i?(null!==(g=(u=D)._$Co)&&void 0!==g?g:u._$Co=[])[i]=L:D._$Cl=L),void 0!==L&&(N=J(M,L._$AS(M,N.values),L,i)),N}class f{constructor(M,N){this._$AV=[],this._$AN=void 0,this._$AD=M,this._$AM=N}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(M){var N;const{el:{content:D},parts:i}=this._$AD,j=(null!==(N=null==M?void 0:M.creationScope)&&void 0!==N?N:C).importNode(D,!0);P.currentNode=j;let I=P.nextNode(),g=0,u=0,L=i[0];for(;void 0!==L;){if(g===L.index){let N;2===L.type?N=new X(I,I.nextSibling,this,M):1===L.type?N=new L.ctor(I,L.name,L.strings,this,M):6===L.type&&(N=new NM(I,this,M)),this._$AV.push(N),L=i[++u]}g!==(null==L?void 0:L.index)&&(I=P.nextNode(),g++)}return P.currentNode=C,j}v(M){let N=0;for(const D of this._$AV)void 0!==D&&(void 0!==D.strings?(D._$AI(M,D,N),N+=D.strings.length-2):D._$AI(M[N])),N++}}class X{constructor(M,N,D,i){var j;this.type=2,this._$AH=G,this._$AN=void 0,this._$AA=M,this._$AB=N,this._$AM=D,this.options=i,this._$Cp=null===(j=null==i?void 0:i.isConnected)||void 0===j||j}get _$AU(){var M,N;return null!==(N=null===(M=this._$AM)||void 0===M?void 0:M._$AU)&&void 0!==N?N:this._$Cp}get parentNode(){let M=this._$AA.parentNode;const N=this._$AM;return void 0!==N&&11===(null==M?void 0:M.nodeType)&&(M=N.parentNode),M}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(M,N=this){M=J(this,M,N),U(M)?M===G||null==M||""===M?(this._$AH!==G&&this._$AR(),this._$AH=G):M!==this._$AH&&M!==v&&this._(M):void 0!==M._$litType$?this.g(M):void 0!==M.nodeType?this.$(M):(M=>k(M)||"function"==typeof(null==M?void 0:M[Symbol.iterator]))(M)?this.T(M):this._(M)}k(M){return this._$AA.parentNode.insertBefore(M,this._$AB)}$(M){this._$AH!==M&&(this._$AR(),this._$AH=this.k(M))}_(M){this._$AH!==G&&U(this._$AH)?this._$AA.nextSibling.data=M:this.$(C.createTextNode(M)),this._$AH=M}g(M){var N;const{values:D,_$litType$:i}=M,j="number"==typeof i?this._$AC(M):(void 0===i.el&&(i.el=F.createElement(R(i.h,i.h[0]),this.options)),i);if((null===(N=this._$AH)||void 0===N?void 0:N._$AD)===j)this._$AH.v(D);else{const M=new f(j,this),N=M.u(this.options);M.v(D),this.$(N),this._$AH=M}}_$AC(M){let N=B.get(M.strings);return void 0===N&&B.set(M.strings,N=new F(M)),N}T(M){k(this._$AH)||(this._$AH=[],this._$AR());const N=this._$AH;let D,i=0;for(const j of M)i===N.length?N.push(D=new X(this.k(r()),this.k(r()),this,this.options)):D=N[i],D._$AI(j),i++;i<N.length&&(this._$AR(D&&D._$AB.nextSibling,i),N.length=i)}_$AR(M=this._$AA.nextSibling,N){var D;for(null===(D=this._$AP)||void 0===D||D.call(this,!1,!0,N);M&&M!==this._$AB;){const N=M.nextSibling;M.remove(),M=N}}setConnected(M){var N;void 0===this._$AM&&(this._$Cp=M,null===(N=this._$AP)||void 0===N||N.call(this,M))}}class _{constructor(M,N,D,i,j){this.type=1,this._$AH=G,this._$AN=void 0,this.element=M,this.name=N,this._$AM=i,this.options=j,D.length>2||""!==D[0]||""!==D[1]?(this._$AH=Array(D.length-1).fill(new String),this.strings=D):this._$AH=G}get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}_$AI(M,N=this,D,i){const j=this.strings;let I=!1;if(void 0===j)M=J(this,M,N,0),I=!U(M)||M!==this._$AH&&M!==v,I&&(this._$AH=M);else{const i=M;let g,u;for(M=j[0],g=0;g<j.length-1;g++)u=J(this,i[D+g],N,g),u===v&&(u=this._$AH[g]),I||(I=!U(u)||u!==this._$AH[g]),u===G?M=G:M!==G&&(M+=(null!=u?u:"")+j[g+1]),this._$AH[g]=u}I&&!i&&this.j(M)}j(M){M===G?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,null!=M?M:"")}}class $ extends _{constructor(){super(...arguments),this.type=3}j(M){this.element[this.name]=M===G?void 0:M}}const K=w?w.emptyScript:"";class q extends _{constructor(){super(...arguments),this.type=4}j(M){M&&M!==G?this.element.setAttribute(this.name,K):this.element.removeAttribute(this.name)}}class MM extends _{constructor(M,N,D,i,j){super(M,N,D,i,j),this.type=5}_$AI(M,N=this){var D;if((M=null!==(D=J(this,M,N,0))&&void 0!==D?D:G)===v)return;const i=this._$AH,j=M===G&&i!==G||M.capture!==i.capture||M.once!==i.once||M.passive!==i.passive,I=M!==G&&(i===G||j);j&&this.element.removeEventListener(this.name,this,i),I&&this.element.addEventListener(this.name,this,M),this._$AH=M}handleEvent(M){var N,D;"function"==typeof this._$AH?this._$AH.call(null!==(D=null===(N=this.options)||void 0===N?void 0:N.host)&&void 0!==D?D:this.element,M):this._$AH.handleEvent(M)}}class NM{constructor(M,N,D){this.element=M,this.type=6,this._$AN=void 0,this._$AM=N,this.options=D}get _$AU(){return this._$AM._$AU}_$AI(M){J(this,M)}}const DM=a.litHtmlPolyfillSupport;null==DM||DM(F,X),(null!==(o=a.litHtmlVersions)&&void 0!==o?o:a.litHtmlVersions=[]).push("2.8.0");
19
19
  /**
20
20
  * @license
21
21
  * Copyright 2017 Google LLC
@@ -64,7 +64,7 @@ var cM;null===(cM=window.HTMLSlotElement)||void 0===cM||cM.prototype.assignedEle
64
64
  * Copyright 2017 Google LLC
65
65
  * SPDX-License-Identifier: BSD-3-Clause
66
66
  */
67
- const xM=1,sM=2,eM=3,lM=4,oM=M=>(...N)=>({_$litDirective$:M,values:N});let aM=class{constructor(M){}get _$AU(){return this._$AM._$AU}_$AT(M,N,D){this._$Ct=M,this._$AM=N,this._$Ci=D}_$AS(M,N){return this.update(M,N)}update(M,N){return this.render(...N)}};
67
+ const xM=1,eM=2,sM=3,lM=4,oM=M=>(...N)=>({_$litDirective$:M,values:N});let aM=class{constructor(M){}get _$AU(){return this._$AM._$AU}_$AT(M,N,D){this._$Ct=M,this._$AM=N,this._$Ci=D}_$AS(M,N){return this.update(M,N)}update(M,N){return this.render(...N)}};
68
68
  /**
69
69
  * @license
70
70
  * Copyright 2018 Google LLC
@@ -74,7 +74,7 @@ const xM=1,sM=2,eM=3,lM=4,oM=M=>(...N)=>({_$litDirective$:M,values:N});let aM=cl
74
74
  * @license
75
75
  * Copyright 2017 Google LLC
76
76
  * SPDX-License-Identifier: BSD-3-Clause
77
- */let OM=class extends aM{constructor(M){if(super(M),this.et=G,M.type!==sM)throw Error(this.constructor.directiveName+"() can only be used in child bindings")}render(M){if(M===G||null==M)return this.ft=void 0,this.et=M;if(M===v)return M;if("string"!=typeof M)throw Error(this.constructor.directiveName+"() called with a non-string value");if(M===this.et)return this.ft;this.et=M;const N=[M];return N.raw=N,this.ft={_$litType$:this.constructor.resultType,strings:N,values:[]}}};OM.directiveName="unsafeHTML",OM.resultType=1;const EM=oM(OM);
77
+ */let OM=class extends aM{constructor(M){if(super(M),this.et=G,M.type!==eM)throw Error(this.constructor.directiveName+"() can only be used in child bindings")}render(M){if(M===G||null==M)return this.ft=void 0,this.et=M;if(M===v)return M;if("string"!=typeof M)throw Error(this.constructor.directiveName+"() called with a non-string value");if(M===this.et)return this.ft;this.et=M;const N=[M];return N.raw=N,this.ft={_$litType$:this.constructor.resultType,strings:N,values:[]}}};OM.directiveName="unsafeHTML",OM.resultType=1;const EM=oM(OM);
78
78
  /**
79
79
  * @license
80
80
  * Copyright 2017 Google LLC
@@ -992,7 +992,7 @@ const bM=Symbol.for(""),ZM=M=>{if((null==M?void 0:M.r)===bM)return null==M?void
992
992
  * @license
993
993
  * Copyright 2020 Google LLC
994
994
  * SPDX-License-Identifier: BSD-3-Clause
995
- */,HM={},FM=oM(class extends aM{constructor(M){if(super(M),M.type!==eM&&M.type!==xM&&M.type!==lM)throw Error("The `live` directive is not allowed on child or event bindings");if(!(M=>void 0===M.strings)(M))throw Error("`live` bindings can only contain a single expression")}render(M){return M}update(M,[N]){if(N===v||N===G)return N;const D=M.element,i=M.name;if(M.type===eM){if(N===D[i])return v}else if(M.type===lM){if(!!N===D.hasAttribute(i))return v}else if(M.type===xM&&D.getAttribute(i)===N+"")return v;return((M,N=HM)=>{M._$AH=N;
995
+ */,HM={},FM=oM(class extends aM{constructor(M){if(super(M),M.type!==sM&&M.type!==xM&&M.type!==lM)throw Error("The `live` directive is not allowed on child or event bindings");if(!(M=>void 0===M.strings)(M))throw Error("`live` bindings can only contain a single expression")}render(M){return M}update(M,[N]){if(N===v||N===G)return N;const D=M.element,i=M.name;if(M.type===sM){if(N===D[i])return v}else if(M.type===lM){if(!!N===D.hasAttribute(i))return v}else if(M.type===xM&&D.getAttribute(i)===N+"")return v;return((M,N=HM)=>{M._$AH=N;
996
996
  /**
997
997
  * @license
998
998
  * Copyright 2020 Google LLC
@@ -1891,7 +1891,7 @@ const bM=Symbol.for(""),ZM=M=>{if((null==M?void 0:M.r)===bM)return null==M?void
1891
1891
  `:""}
1892
1892
 
1893
1893
  </fieldset>
1894
- `}},M.NileRadioGroup.styles=KM,N([yM("slot:not([name])")],M.NileRadioGroup.prototype,"defaultSlot",void 0),N([tM()],M.NileRadioGroup.prototype,"hasButtonGroup",void 0),N([tM()],M.NileRadioGroup.prototype,"defaultValue",void 0),N([zM()],M.NileRadioGroup.prototype,"label",void 0),N([zM()],M.NileRadioGroup.prototype,"name",void 0),N([zM({reflect:!0})],M.NileRadioGroup.prototype,"value",void 0),N([zM({reflect:!0})],M.NileRadioGroup.prototype,"form",void 0),N([zM({type:Boolean,reflect:!0})],M.NileRadioGroup.prototype,"required",void 0),N([zM({type:Boolean,reflect:!0})],M.NileRadioGroup.prototype,"labelInline",void 0),N([zM({type:Boolean,reflect:!0})],M.NileRadioGroup.prototype,"disabled",void 0),N([zM({attribute:"help-text"})],M.NileRadioGroup.prototype,"helpText",void 0),N([zM({attribute:"error-message"})],M.NileRadioGroup.prototype,"errorMessage",void 0),N([vM("disabled",{waitUntilFirstUpdate:!0})],M.NileRadioGroup.prototype,"handleDisabledChange",null),N([vM("value")],M.NileRadioGroup.prototype,"handleValueChange",null),M.NileRadioGroup=N([uM("nile-radio-group")],M.NileRadioGroup);const qM=Math.min,MN=Math.max,NN=Math.round,DN=Math.floor,iN=M=>({x:M,y:M}),jN={left:"right",right:"left",bottom:"top",top:"bottom"},IN={start:"end",end:"start"};function gN(M,N,D){return MN(M,qM(N,D))}function uN(M,N){return"function"==typeof M?M(N):M}function LN(M){return M.split("-")[0]}function TN(M){return M.split("-")[1]}function zN(M){return"x"===M?"y":"x"}function tN(M){return"y"===M?"height":"width"}function AN(M){return["top","bottom"].includes(LN(M))?"y":"x"}function yN(M){return zN(AN(M))}function cN(M){return M.replace(/start|end/g,(M=>IN[M]))}function xN(M){return M.replace(/left|right|bottom|top/g,(M=>jN[M]))}function sN(M){return"number"!=typeof M?function(M){return{top:0,right:0,bottom:0,left:0,...M}}(M):{top:M,right:M,bottom:M,left:M}}function eN(M){return{...M,top:M.y,left:M.x,right:M.x+M.width,bottom:M.y+M.height}}function lN(M,N,D){let{reference:i,floating:j}=M;const I=AN(N),g=yN(N),u=tN(g),L=LN(N),T="y"===I,z=i.x+i.width/2-j.width/2,t=i.y+i.height/2-j.height/2,A=i[u]/2-j[u]/2;let y;switch(L){case"top":y={x:z,y:i.y-j.height};break;case"bottom":y={x:z,y:i.y+i.height};break;case"right":y={x:i.x+i.width,y:t};break;case"left":y={x:i.x-j.width,y:t};break;default:y={x:i.x,y:i.y}}switch(TN(N)){case"start":y[g]-=A*(D&&T?-1:1);break;case"end":y[g]+=A*(D&&T?-1:1)}return y}async function oN(M,N){var D;void 0===N&&(N={});const{x:i,y:j,platform:I,rects:g,elements:u,strategy:L}=M,{boundary:T="clippingAncestors",rootBoundary:z="viewport",elementContext:t="floating",altBoundary:A=!1,padding:y=0}=uN(N,M),c=sN(y),x=u[A?"floating"===t?"reference":"floating":t],s=eN(await I.getClippingRect({element:null==(D=await(null==I.isElement?void 0:I.isElement(x)))||D?x:x.contextElement||await(null==I.getDocumentElement?void 0:I.getDocumentElement(u.floating)),boundary:T,rootBoundary:z,strategy:L})),e="floating"===t?{...g.floating,x:i,y:j}:g.reference,l=await(null==I.getOffsetParent?void 0:I.getOffsetParent(u.floating)),o=await(null==I.isElement?void 0:I.isElement(l))&&await(null==I.getScale?void 0:I.getScale(l))||{x:1,y:1},a=eN(I.convertOffsetParentRelativeRectToViewportRelativeRect?await I.convertOffsetParentRelativeRectToViewportRelativeRect({rect:e,offsetParent:l,strategy:L}):e);return{top:(s.top-a.top+c.top)/o.y,bottom:(a.bottom-s.bottom+c.bottom)/o.y,left:(s.left-a.left+c.left)/o.x,right:(a.right-s.right+c.right)/o.x}}const aN=function(M){return void 0===M&&(M={}),{name:"flip",options:M,async fn(N){var D,i;const{placement:j,middlewareData:I,rects:g,initialPlacement:u,platform:L,elements:T}=N,{mainAxis:z=!0,crossAxis:t=!0,fallbackPlacements:A,fallbackStrategy:y="bestFit",fallbackAxisSideDirection:c="none",flipAlignment:x=!0,...s}=uN(M,N);if(null!=(D=I.arrow)&&D.alignmentOffset)return{};const e=LN(j),l=LN(u)===u,o=await(null==L.isRTL?void 0:L.isRTL(T.floating)),a=A||(l||!x?[xN(u)]:function(M){const N=xN(M);return[cN(M),N,cN(N)]}(u));A||"none"===c||a.push(...function(M,N,D,i){const j=TN(M);let I=function(M,N,D){const i=["left","right"],j=["right","left"],I=["top","bottom"],g=["bottom","top"];switch(M){case"top":case"bottom":return D?N?j:i:N?i:j;case"left":case"right":return N?I:g;default:return[]}}(LN(M),"start"===D,i);return j&&(I=I.map((M=>M+"-"+j)),N&&(I=I.concat(I.map(cN)))),I}(u,x,c,o));const w=[u,...a],O=await oN(N,s),E=[];let S=(null==(i=I.flip)?void 0:i.overflows)||[];if(z&&E.push(O[e]),t){const M=function(M,N,D){void 0===D&&(D=!1);const i=TN(M),j=yN(M),I=tN(j);let g="x"===j?i===(D?"end":"start")?"right":"left":"start"===i?"bottom":"top";return N.reference[I]>N.floating[I]&&(g=xN(g)),[g,xN(g)]}(j,g,o);E.push(O[M[0]],O[M[1]])}if(S=[...S,{placement:j,overflows:E}],!E.every((M=>M<=0))){var n,d;const M=((null==(n=I.flip)?void 0:n.index)||0)+1,N=w[M];if(N)return{data:{index:M,overflows:S},reset:{placement:N}};let D=null==(d=S.filter((M=>M.overflows[0]<=0)).sort(((M,N)=>M.overflows[1]-N.overflows[1]))[0])?void 0:d.placement;if(!D)switch(y){case"bestFit":{var C;const M=null==(C=S.map((M=>[M.placement,M.overflows.filter((M=>M>0)).reduce(((M,N)=>M+N),0)])).sort(((M,N)=>M[1]-N[1]))[0])?void 0:C[0];M&&(D=M);break}case"initialPlacement":D=u}if(j!==D)return{reset:{placement:D}}}return{}}}};const wN=function(M){return void 0===M&&(M=0),{name:"offset",options:M,async fn(N){const{x:D,y:i}=N,j=await async function(M,N){const{placement:D,platform:i,elements:j}=M,I=await(null==i.isRTL?void 0:i.isRTL(j.floating)),g=LN(D),u=TN(D),L="y"===AN(D),T=["left","top"].includes(g)?-1:1,z=I&&L?-1:1,t=uN(N,M);let{mainAxis:A,crossAxis:y,alignmentAxis:c}="number"==typeof t?{mainAxis:t,crossAxis:0,alignmentAxis:null}:{mainAxis:0,crossAxis:0,alignmentAxis:null,...t};return u&&"number"==typeof c&&(y="end"===u?-1*c:c),L?{x:y*z,y:A*T}:{x:A*T,y:y*z}}(N,M);return{x:D+j.x,y:i+j.y,data:j}}}},ON=function(M){return void 0===M&&(M={}),{name:"size",options:M,async fn(N){const{placement:D,rects:i,platform:j,elements:I}=N,{apply:g=(()=>{}),...u}=uN(M,N),L=await oN(N,u),T=LN(D),z=TN(D),t="y"===AN(D),{width:A,height:y}=i.floating;let c,x;"top"===T||"bottom"===T?(c=T,x=z===(await(null==j.isRTL?void 0:j.isRTL(I.floating))?"start":"end")?"left":"right"):(x=T,c="end"===z?"top":"bottom");const s=y-L[c],e=A-L[x],l=!N.middlewareData.shift;let o=s,a=e;if(t){const M=A-L.left-L.right;a=z||l?qM(e,M):M}else{const M=y-L.top-L.bottom;o=z||l?qM(s,M):M}if(l&&!z){const M=MN(L.left,0),N=MN(L.right,0),D=MN(L.top,0),i=MN(L.bottom,0);t?a=A-2*(0!==M||0!==N?M+N:MN(L.left,L.right)):o=y-2*(0!==D||0!==i?D+i:MN(L.top,L.bottom))}await g({...N,availableWidth:a,availableHeight:o});const w=await j.getDimensions(I.floating);return A!==w.width||y!==w.height?{reset:{rects:!0}}:{}}}};function EN(M){return dN(M)?(M.nodeName||"").toLowerCase():"#document"}function SN(M){var N;return(null==M||null==(N=M.ownerDocument)?void 0:N.defaultView)||window}function nN(M){var N;return null==(N=(dN(M)?M.ownerDocument:M.document)||window.document)?void 0:N.documentElement}function dN(M){return M instanceof Node||M instanceof SN(M).Node}function CN(M){return M instanceof Element||M instanceof SN(M).Element}function rN(M){return M instanceof HTMLElement||M instanceof SN(M).HTMLElement}function UN(M){return"undefined"!=typeof ShadowRoot&&(M instanceof ShadowRoot||M instanceof SN(M).ShadowRoot)}function kN(M){const{overflow:N,overflowX:D,overflowY:i,display:j}=ZN(M);return/auto|scroll|overlay|hidden|clip/.test(N+i+D)&&!["inline","contents"].includes(j)}function QN(M){return["table","td","th"].includes(EN(M))}function hN(M){const N=YN(),D=ZN(M);return"none"!==D.transform||"none"!==D.perspective||!!D.containerType&&"normal"!==D.containerType||!N&&!!D.backdropFilter&&"none"!==D.backdropFilter||!N&&!!D.filter&&"none"!==D.filter||["transform","perspective","filter"].some((M=>(D.willChange||"").includes(M)))||["paint","layout","strict","content"].some((M=>(D.contain||"").includes(M)))}function YN(){return!("undefined"==typeof CSS||!CSS.supports)&&CSS.supports("-webkit-backdrop-filter","none")}function bN(M){return["html","body","#document"].includes(EN(M))}function ZN(M){return SN(M).getComputedStyle(M)}function mN(M){return CN(M)?{scrollLeft:M.scrollLeft,scrollTop:M.scrollTop}:{scrollLeft:M.pageXOffset,scrollTop:M.pageYOffset}}function pN(M){if("html"===EN(M))return M;const N=M.assignedSlot||M.parentNode||UN(M)&&M.host||nN(M);return UN(N)?N.host:N}function WN(M){const N=pN(M);return bN(N)?M.ownerDocument?M.ownerDocument.body:M.body:rN(N)&&kN(N)?N:WN(N)}function VN(M,N,D){var i;void 0===N&&(N=[]),void 0===D&&(D=!0);const j=WN(M),I=j===(null==(i=M.ownerDocument)?void 0:i.body),g=SN(j);return I?N.concat(g,g.visualViewport||[],kN(j)?j:[],g.frameElement&&D?VN(g.frameElement):[]):N.concat(j,VN(j,[],D))}function vN(M){const N=ZN(M);let D=parseFloat(N.width)||0,i=parseFloat(N.height)||0;const j=rN(M),I=j?M.offsetWidth:D,g=j?M.offsetHeight:i,u=NN(D)!==I||NN(i)!==g;return u&&(D=I,i=g),{width:D,height:i,$:u}}function GN(M){return CN(M)?M:M.contextElement}function BN(M){const N=GN(M);if(!rN(N))return iN(1);const D=N.getBoundingClientRect(),{width:i,height:j,$:I}=vN(N);let g=(I?NN(D.width):D.width)/i,u=(I?NN(D.height):D.height)/j;return g&&Number.isFinite(g)||(g=1),u&&Number.isFinite(u)||(u=1),{x:g,y:u}}const PN=iN(0);function RN(M){const N=SN(M);return YN()&&N.visualViewport?{x:N.visualViewport.offsetLeft,y:N.visualViewport.offsetTop}:PN}function HN(M,N,D,i){void 0===N&&(N=!1),void 0===D&&(D=!1);const j=M.getBoundingClientRect(),I=GN(M);let g=iN(1);N&&(i?CN(i)&&(g=BN(i)):g=BN(M));const u=function(M,N,D){return void 0===N&&(N=!1),!(!D||N&&D!==SN(M))&&N}(I,D,i)?RN(I):iN(0);let L=(j.left+u.x)/g.x,T=(j.top+u.y)/g.y,z=j.width/g.x,t=j.height/g.y;if(I){const M=SN(I),N=i&&CN(i)?SN(i):i;let D=M.frameElement;for(;D&&i&&N!==M;){const M=BN(D),N=D.getBoundingClientRect(),i=ZN(D),j=N.left+(D.clientLeft+parseFloat(i.paddingLeft))*M.x,I=N.top+(D.clientTop+parseFloat(i.paddingTop))*M.y;L*=M.x,T*=M.y,z*=M.x,t*=M.y,L+=j,T+=I,D=SN(D).frameElement}}return eN({width:z,height:t,x:L,y:T})}function FN(M){return HN(nN(M)).left+mN(M).scrollLeft}function JN(M,N,D){let i;if("viewport"===N)i=function(M,N){const D=SN(M),i=nN(M),j=D.visualViewport;let I=i.clientWidth,g=i.clientHeight,u=0,L=0;if(j){I=j.width,g=j.height;const M=YN();(!M||M&&"fixed"===N)&&(u=j.offsetLeft,L=j.offsetTop)}return{width:I,height:g,x:u,y:L}}(M,D);else if("document"===N)i=function(M){const N=nN(M),D=mN(M),i=M.ownerDocument.body,j=MN(N.scrollWidth,N.clientWidth,i.scrollWidth,i.clientWidth),I=MN(N.scrollHeight,N.clientHeight,i.scrollHeight,i.clientHeight);let g=-D.scrollLeft+FN(M);const u=-D.scrollTop;return"rtl"===ZN(i).direction&&(g+=MN(N.clientWidth,i.clientWidth)-j),{width:j,height:I,x:g,y:u}}(nN(M));else if(CN(N))i=function(M,N){const D=HN(M,!0,"fixed"===N),i=D.top+M.clientTop,j=D.left+M.clientLeft,I=rN(M)?BN(M):iN(1);return{width:M.clientWidth*I.x,height:M.clientHeight*I.y,x:j*I.x,y:i*I.y}}(N,D);else{const D=RN(M);i={...N,x:N.x-D.x,y:N.y-D.y}}return eN(i)}function fN(M,N){const D=pN(M);return!(D===N||!CN(D)||bN(D))&&("fixed"===ZN(D).position||fN(D,N))}function XN(M,N,D){const i=rN(N),j=nN(N),I="fixed"===D,g=HN(M,!0,I,N);let u={scrollLeft:0,scrollTop:0};const L=iN(0);if(i||!i&&!I)if(("body"!==EN(N)||kN(j))&&(u=mN(N)),i){const M=HN(N,!0,I,N);L.x=M.x+N.clientLeft,L.y=M.y+N.clientTop}else j&&(L.x=FN(j));return{x:g.left+u.scrollLeft-L.x,y:g.top+u.scrollTop-L.y,width:g.width,height:g.height}}function _N(M,N){return rN(M)&&"fixed"!==ZN(M).position?N?N(M):M.offsetParent:null}function $N(M,N){const D=SN(M);if(!rN(M))return D;let i=_N(M,N);for(;i&&QN(i)&&"static"===ZN(i).position;)i=_N(i,N);return i&&("html"===EN(i)||"body"===EN(i)&&"static"===ZN(i).position&&!hN(i))?D:i||function(M){let N=pN(M);for(;rN(N)&&!bN(N);){if(hN(N))return N;N=pN(N)}return null}(M)||D}const KN={convertOffsetParentRelativeRectToViewportRelativeRect:function(M){let{rect:N,offsetParent:D,strategy:i}=M;const j=rN(D),I=nN(D);if(D===I)return N;let g={scrollLeft:0,scrollTop:0},u=iN(1);const L=iN(0);if((j||!j&&"fixed"!==i)&&(("body"!==EN(D)||kN(I))&&(g=mN(D)),rN(D))){const M=HN(D);u=BN(D),L.x=M.x+D.clientLeft,L.y=M.y+D.clientTop}return{width:N.width*u.x,height:N.height*u.y,x:N.x*u.x-g.scrollLeft*u.x+L.x,y:N.y*u.y-g.scrollTop*u.y+L.y}},getDocumentElement:nN,getClippingRect:function(M){let{element:N,boundary:D,rootBoundary:i,strategy:j}=M;const I=[..."clippingAncestors"===D?function(M,N){const D=N.get(M);if(D)return D;let i=VN(M,[],!1).filter((M=>CN(M)&&"body"!==EN(M))),j=null;const I="fixed"===ZN(M).position;let g=I?pN(M):M;for(;CN(g)&&!bN(g);){const N=ZN(g),D=hN(g);D||"fixed"!==N.position||(j=null),(I?!D&&!j:!D&&"static"===N.position&&j&&["absolute","fixed"].includes(j.position)||kN(g)&&!D&&fN(M,g))?i=i.filter((M=>M!==g)):j=N,g=pN(g)}return N.set(M,i),i}(N,this._c):[].concat(D),i],g=I[0],u=I.reduce(((M,D)=>{const i=JN(N,D,j);return M.top=MN(i.top,M.top),M.right=qM(i.right,M.right),M.bottom=qM(i.bottom,M.bottom),M.left=MN(i.left,M.left),M}),JN(N,g,j));return{width:u.right-u.left,height:u.bottom-u.top,x:u.left,y:u.top}},getOffsetParent:$N,getElementRects:async function(M){let{reference:N,floating:D,strategy:i}=M;const j=this.getOffsetParent||$N,I=this.getDimensions;return{reference:XN(N,await j(D),i),floating:{x:0,y:0,...await I(D)}}},getClientRects:function(M){return Array.from(M.getClientRects())},getDimensions:function(M){return vN(M)},getScale:BN,isElement:CN,isRTL:function(M){return"rtl"===ZN(M).direction}};function qN(M,N,D,i){void 0===i&&(i={});const{ancestorScroll:j=!0,ancestorResize:I=!0,elementResize:g="function"==typeof ResizeObserver,layoutShift:u="function"==typeof IntersectionObserver,animationFrame:L=!1}=i,T=GN(M),z=j||I?[...T?VN(T):[],...VN(N)]:[];z.forEach((M=>{j&&M.addEventListener("scroll",D,{passive:!0}),I&&M.addEventListener("resize",D)}));const t=T&&u?function(M,N){let D,i=null;const j=nN(M);function I(){clearTimeout(D),i&&i.disconnect(),i=null}return function g(u,L){void 0===u&&(u=!1),void 0===L&&(L=1),I();const{left:T,top:z,width:t,height:A}=M.getBoundingClientRect();if(u||N(),!t||!A)return;const y={rootMargin:-DN(z)+"px "+-DN(j.clientWidth-(T+t))+"px "+-DN(j.clientHeight-(z+A))+"px "+-DN(T)+"px",threshold:MN(0,qM(1,L))||1};let c=!0;function x(M){const N=M[0].intersectionRatio;if(N!==L){if(!c)return g();N?g(!1,N):D=setTimeout((()=>{g(!1,1e-7)}),100)}c=!1}try{i=new IntersectionObserver(x,{...y,root:j.ownerDocument})}catch(M){i=new IntersectionObserver(x,y)}i.observe(M)}(!0),I}(T,D):null;let A,y=-1,c=null;g&&(c=new ResizeObserver((M=>{let[i]=M;i&&i.target===T&&c&&(c.unobserve(N),cancelAnimationFrame(y),y=requestAnimationFrame((()=>{c&&c.observe(N)}))),D()})),T&&!L&&c.observe(T),c.observe(N));let x=L?HN(M):null;return L&&function N(){const i=HN(M);!x||i.x===x.x&&i.y===x.y&&i.width===x.width&&i.height===x.height||D();x=i,A=requestAnimationFrame(N)}(),D(),()=>{z.forEach((M=>{j&&M.removeEventListener("scroll",D),I&&M.removeEventListener("resize",D)})),t&&t(),c&&c.disconnect(),c=null,L&&cancelAnimationFrame(A)}}const MD=(M,N,D)=>{const i=new Map,j={platform:KN,...D},I={...j.platform,_c:i};return(async(M,N,D)=>{const{placement:i="bottom",strategy:j="absolute",middleware:I=[],platform:g}=D,u=I.filter(Boolean),L=await(null==g.isRTL?void 0:g.isRTL(N));let T=await g.getElementRects({reference:M,floating:N,strategy:j}),{x:z,y:t}=lN(T,i,L),A=i,y={},c=0;for(let D=0;D<u.length;D++){const{name:I,fn:x}=u[D],{x:s,y:e,data:l,reset:o}=await x({x:z,y:t,initialPlacement:i,placement:A,strategy:j,middlewareData:y,rects:T,platform:g,elements:{reference:M,floating:N}});z=null!=s?s:z,t=null!=e?e:t,y={...y,[I]:{...y[I],...l}},o&&c<=50&&(c++,"object"==typeof o&&(o.placement&&(A=o.placement),o.rects&&(T=!0===o.rects?await g.getElementRects({reference:M,floating:N,strategy:j}):o.rects),({x:z,y:t}=lN(T,A,L))),D=-1)}return{x:z,y:t,placement:A,strategy:j,middlewareData:y}})(M,N,{...j,platform:I})};function ND(M){return function(M){for(let N=M;N;N=DD(N))if(N instanceof Element&&"none"===getComputedStyle(N).display)return null;for(let N=DD(M);N;N=DD(N)){if(!(N instanceof Element))continue;const M=getComputedStyle(N);if("contents"!==M.display){if("static"!==M.position||"none"!==M.filter)return N;if("BODY"===N.tagName)return N}}return null}(M)}function DD(M){return M.assignedSlot?M.assignedSlot:M.parentNode instanceof ShadowRoot?M.parentNode.host:M.parentNode}const iD=u`
1894
+ `}},M.NileRadioGroup.styles=KM,N([yM("slot:not([name])")],M.NileRadioGroup.prototype,"defaultSlot",void 0),N([tM()],M.NileRadioGroup.prototype,"hasButtonGroup",void 0),N([tM()],M.NileRadioGroup.prototype,"defaultValue",void 0),N([zM()],M.NileRadioGroup.prototype,"label",void 0),N([zM()],M.NileRadioGroup.prototype,"name",void 0),N([zM({reflect:!0})],M.NileRadioGroup.prototype,"value",void 0),N([zM({reflect:!0})],M.NileRadioGroup.prototype,"form",void 0),N([zM({type:Boolean,reflect:!0})],M.NileRadioGroup.prototype,"required",void 0),N([zM({type:Boolean,reflect:!0})],M.NileRadioGroup.prototype,"labelInline",void 0),N([zM({type:Boolean,reflect:!0})],M.NileRadioGroup.prototype,"disabled",void 0),N([zM({attribute:"help-text"})],M.NileRadioGroup.prototype,"helpText",void 0),N([zM({attribute:"error-message"})],M.NileRadioGroup.prototype,"errorMessage",void 0),N([vM("disabled",{waitUntilFirstUpdate:!0})],M.NileRadioGroup.prototype,"handleDisabledChange",null),N([vM("value")],M.NileRadioGroup.prototype,"handleValueChange",null),M.NileRadioGroup=N([uM("nile-radio-group")],M.NileRadioGroup);const qM=Math.min,MN=Math.max,NN=Math.round,DN=Math.floor,iN=M=>({x:M,y:M}),jN={left:"right",right:"left",bottom:"top",top:"bottom"},IN={start:"end",end:"start"};function gN(M,N,D){return MN(M,qM(N,D))}function uN(M,N){return"function"==typeof M?M(N):M}function LN(M){return M.split("-")[0]}function TN(M){return M.split("-")[1]}function zN(M){return"x"===M?"y":"x"}function tN(M){return"y"===M?"height":"width"}function AN(M){return["top","bottom"].includes(LN(M))?"y":"x"}function yN(M){return zN(AN(M))}function cN(M){return M.replace(/start|end/g,(M=>IN[M]))}function xN(M){return M.replace(/left|right|bottom|top/g,(M=>jN[M]))}function eN(M){return"number"!=typeof M?function(M){return{top:0,right:0,bottom:0,left:0,...M}}(M):{top:M,right:M,bottom:M,left:M}}function sN(M){return{...M,top:M.y,left:M.x,right:M.x+M.width,bottom:M.y+M.height}}function lN(M,N,D){let{reference:i,floating:j}=M;const I=AN(N),g=yN(N),u=tN(g),L=LN(N),T="y"===I,z=i.x+i.width/2-j.width/2,t=i.y+i.height/2-j.height/2,A=i[u]/2-j[u]/2;let y;switch(L){case"top":y={x:z,y:i.y-j.height};break;case"bottom":y={x:z,y:i.y+i.height};break;case"right":y={x:i.x+i.width,y:t};break;case"left":y={x:i.x-j.width,y:t};break;default:y={x:i.x,y:i.y}}switch(TN(N)){case"start":y[g]-=A*(D&&T?-1:1);break;case"end":y[g]+=A*(D&&T?-1:1)}return y}async function oN(M,N){var D;void 0===N&&(N={});const{x:i,y:j,platform:I,rects:g,elements:u,strategy:L}=M,{boundary:T="clippingAncestors",rootBoundary:z="viewport",elementContext:t="floating",altBoundary:A=!1,padding:y=0}=uN(N,M),c=eN(y),x=u[A?"floating"===t?"reference":"floating":t],e=sN(await I.getClippingRect({element:null==(D=await(null==I.isElement?void 0:I.isElement(x)))||D?x:x.contextElement||await(null==I.getDocumentElement?void 0:I.getDocumentElement(u.floating)),boundary:T,rootBoundary:z,strategy:L})),s="floating"===t?{...g.floating,x:i,y:j}:g.reference,l=await(null==I.getOffsetParent?void 0:I.getOffsetParent(u.floating)),o=await(null==I.isElement?void 0:I.isElement(l))&&await(null==I.getScale?void 0:I.getScale(l))||{x:1,y:1},a=sN(I.convertOffsetParentRelativeRectToViewportRelativeRect?await I.convertOffsetParentRelativeRectToViewportRelativeRect({rect:s,offsetParent:l,strategy:L}):s);return{top:(e.top-a.top+c.top)/o.y,bottom:(a.bottom-e.bottom+c.bottom)/o.y,left:(e.left-a.left+c.left)/o.x,right:(a.right-e.right+c.right)/o.x}}const aN=function(M){return void 0===M&&(M={}),{name:"flip",options:M,async fn(N){var D,i;const{placement:j,middlewareData:I,rects:g,initialPlacement:u,platform:L,elements:T}=N,{mainAxis:z=!0,crossAxis:t=!0,fallbackPlacements:A,fallbackStrategy:y="bestFit",fallbackAxisSideDirection:c="none",flipAlignment:x=!0,...e}=uN(M,N);if(null!=(D=I.arrow)&&D.alignmentOffset)return{};const s=LN(j),l=LN(u)===u,o=await(null==L.isRTL?void 0:L.isRTL(T.floating)),a=A||(l||!x?[xN(u)]:function(M){const N=xN(M);return[cN(M),N,cN(N)]}(u));A||"none"===c||a.push(...function(M,N,D,i){const j=TN(M);let I=function(M,N,D){const i=["left","right"],j=["right","left"],I=["top","bottom"],g=["bottom","top"];switch(M){case"top":case"bottom":return D?N?j:i:N?i:j;case"left":case"right":return N?I:g;default:return[]}}(LN(M),"start"===D,i);return j&&(I=I.map((M=>M+"-"+j)),N&&(I=I.concat(I.map(cN)))),I}(u,x,c,o));const w=[u,...a],O=await oN(N,e),E=[];let S=(null==(i=I.flip)?void 0:i.overflows)||[];if(z&&E.push(O[s]),t){const M=function(M,N,D){void 0===D&&(D=!1);const i=TN(M),j=yN(M),I=tN(j);let g="x"===j?i===(D?"end":"start")?"right":"left":"start"===i?"bottom":"top";return N.reference[I]>N.floating[I]&&(g=xN(g)),[g,xN(g)]}(j,g,o);E.push(O[M[0]],O[M[1]])}if(S=[...S,{placement:j,overflows:E}],!E.every((M=>M<=0))){var n,d;const M=((null==(n=I.flip)?void 0:n.index)||0)+1,N=w[M];if(N)return{data:{index:M,overflows:S},reset:{placement:N}};let D=null==(d=S.filter((M=>M.overflows[0]<=0)).sort(((M,N)=>M.overflows[1]-N.overflows[1]))[0])?void 0:d.placement;if(!D)switch(y){case"bestFit":{var C;const M=null==(C=S.map((M=>[M.placement,M.overflows.filter((M=>M>0)).reduce(((M,N)=>M+N),0)])).sort(((M,N)=>M[1]-N[1]))[0])?void 0:C[0];M&&(D=M);break}case"initialPlacement":D=u}if(j!==D)return{reset:{placement:D}}}return{}}}};const wN=function(M){return void 0===M&&(M=0),{name:"offset",options:M,async fn(N){const{x:D,y:i}=N,j=await async function(M,N){const{placement:D,platform:i,elements:j}=M,I=await(null==i.isRTL?void 0:i.isRTL(j.floating)),g=LN(D),u=TN(D),L="y"===AN(D),T=["left","top"].includes(g)?-1:1,z=I&&L?-1:1,t=uN(N,M);let{mainAxis:A,crossAxis:y,alignmentAxis:c}="number"==typeof t?{mainAxis:t,crossAxis:0,alignmentAxis:null}:{mainAxis:0,crossAxis:0,alignmentAxis:null,...t};return u&&"number"==typeof c&&(y="end"===u?-1*c:c),L?{x:y*z,y:A*T}:{x:A*T,y:y*z}}(N,M);return{x:D+j.x,y:i+j.y,data:j}}}},ON=function(M){return void 0===M&&(M={}),{name:"size",options:M,async fn(N){const{placement:D,rects:i,platform:j,elements:I}=N,{apply:g=(()=>{}),...u}=uN(M,N),L=await oN(N,u),T=LN(D),z=TN(D),t="y"===AN(D),{width:A,height:y}=i.floating;let c,x;"top"===T||"bottom"===T?(c=T,x=z===(await(null==j.isRTL?void 0:j.isRTL(I.floating))?"start":"end")?"left":"right"):(x=T,c="end"===z?"top":"bottom");const e=y-L[c],s=A-L[x],l=!N.middlewareData.shift;let o=e,a=s;if(t){const M=A-L.left-L.right;a=z||l?qM(s,M):M}else{const M=y-L.top-L.bottom;o=z||l?qM(e,M):M}if(l&&!z){const M=MN(L.left,0),N=MN(L.right,0),D=MN(L.top,0),i=MN(L.bottom,0);t?a=A-2*(0!==M||0!==N?M+N:MN(L.left,L.right)):o=y-2*(0!==D||0!==i?D+i:MN(L.top,L.bottom))}await g({...N,availableWidth:a,availableHeight:o});const w=await j.getDimensions(I.floating);return A!==w.width||y!==w.height?{reset:{rects:!0}}:{}}}};function EN(M){return dN(M)?(M.nodeName||"").toLowerCase():"#document"}function SN(M){var N;return(null==M||null==(N=M.ownerDocument)?void 0:N.defaultView)||window}function nN(M){var N;return null==(N=(dN(M)?M.ownerDocument:M.document)||window.document)?void 0:N.documentElement}function dN(M){return M instanceof Node||M instanceof SN(M).Node}function CN(M){return M instanceof Element||M instanceof SN(M).Element}function rN(M){return M instanceof HTMLElement||M instanceof SN(M).HTMLElement}function UN(M){return"undefined"!=typeof ShadowRoot&&(M instanceof ShadowRoot||M instanceof SN(M).ShadowRoot)}function kN(M){const{overflow:N,overflowX:D,overflowY:i,display:j}=ZN(M);return/auto|scroll|overlay|hidden|clip/.test(N+i+D)&&!["inline","contents"].includes(j)}function QN(M){return["table","td","th"].includes(EN(M))}function hN(M){const N=YN(),D=ZN(M);return"none"!==D.transform||"none"!==D.perspective||!!D.containerType&&"normal"!==D.containerType||!N&&!!D.backdropFilter&&"none"!==D.backdropFilter||!N&&!!D.filter&&"none"!==D.filter||["transform","perspective","filter"].some((M=>(D.willChange||"").includes(M)))||["paint","layout","strict","content"].some((M=>(D.contain||"").includes(M)))}function YN(){return!("undefined"==typeof CSS||!CSS.supports)&&CSS.supports("-webkit-backdrop-filter","none")}function bN(M){return["html","body","#document"].includes(EN(M))}function ZN(M){return SN(M).getComputedStyle(M)}function mN(M){return CN(M)?{scrollLeft:M.scrollLeft,scrollTop:M.scrollTop}:{scrollLeft:M.pageXOffset,scrollTop:M.pageYOffset}}function pN(M){if("html"===EN(M))return M;const N=M.assignedSlot||M.parentNode||UN(M)&&M.host||nN(M);return UN(N)?N.host:N}function WN(M){const N=pN(M);return bN(N)?M.ownerDocument?M.ownerDocument.body:M.body:rN(N)&&kN(N)?N:WN(N)}function VN(M,N,D){var i;void 0===N&&(N=[]),void 0===D&&(D=!0);const j=WN(M),I=j===(null==(i=M.ownerDocument)?void 0:i.body),g=SN(j);return I?N.concat(g,g.visualViewport||[],kN(j)?j:[],g.frameElement&&D?VN(g.frameElement):[]):N.concat(j,VN(j,[],D))}function vN(M){const N=ZN(M);let D=parseFloat(N.width)||0,i=parseFloat(N.height)||0;const j=rN(M),I=j?M.offsetWidth:D,g=j?M.offsetHeight:i,u=NN(D)!==I||NN(i)!==g;return u&&(D=I,i=g),{width:D,height:i,$:u}}function GN(M){return CN(M)?M:M.contextElement}function BN(M){const N=GN(M);if(!rN(N))return iN(1);const D=N.getBoundingClientRect(),{width:i,height:j,$:I}=vN(N);let g=(I?NN(D.width):D.width)/i,u=(I?NN(D.height):D.height)/j;return g&&Number.isFinite(g)||(g=1),u&&Number.isFinite(u)||(u=1),{x:g,y:u}}const PN=iN(0);function RN(M){const N=SN(M);return YN()&&N.visualViewport?{x:N.visualViewport.offsetLeft,y:N.visualViewport.offsetTop}:PN}function HN(M,N,D,i){void 0===N&&(N=!1),void 0===D&&(D=!1);const j=M.getBoundingClientRect(),I=GN(M);let g=iN(1);N&&(i?CN(i)&&(g=BN(i)):g=BN(M));const u=function(M,N,D){return void 0===N&&(N=!1),!(!D||N&&D!==SN(M))&&N}(I,D,i)?RN(I):iN(0);let L=(j.left+u.x)/g.x,T=(j.top+u.y)/g.y,z=j.width/g.x,t=j.height/g.y;if(I){const M=SN(I),N=i&&CN(i)?SN(i):i;let D=M.frameElement;for(;D&&i&&N!==M;){const M=BN(D),N=D.getBoundingClientRect(),i=ZN(D),j=N.left+(D.clientLeft+parseFloat(i.paddingLeft))*M.x,I=N.top+(D.clientTop+parseFloat(i.paddingTop))*M.y;L*=M.x,T*=M.y,z*=M.x,t*=M.y,L+=j,T+=I,D=SN(D).frameElement}}return sN({width:z,height:t,x:L,y:T})}function FN(M){return HN(nN(M)).left+mN(M).scrollLeft}function JN(M,N,D){let i;if("viewport"===N)i=function(M,N){const D=SN(M),i=nN(M),j=D.visualViewport;let I=i.clientWidth,g=i.clientHeight,u=0,L=0;if(j){I=j.width,g=j.height;const M=YN();(!M||M&&"fixed"===N)&&(u=j.offsetLeft,L=j.offsetTop)}return{width:I,height:g,x:u,y:L}}(M,D);else if("document"===N)i=function(M){const N=nN(M),D=mN(M),i=M.ownerDocument.body,j=MN(N.scrollWidth,N.clientWidth,i.scrollWidth,i.clientWidth),I=MN(N.scrollHeight,N.clientHeight,i.scrollHeight,i.clientHeight);let g=-D.scrollLeft+FN(M);const u=-D.scrollTop;return"rtl"===ZN(i).direction&&(g+=MN(N.clientWidth,i.clientWidth)-j),{width:j,height:I,x:g,y:u}}(nN(M));else if(CN(N))i=function(M,N){const D=HN(M,!0,"fixed"===N),i=D.top+M.clientTop,j=D.left+M.clientLeft,I=rN(M)?BN(M):iN(1);return{width:M.clientWidth*I.x,height:M.clientHeight*I.y,x:j*I.x,y:i*I.y}}(N,D);else{const D=RN(M);i={...N,x:N.x-D.x,y:N.y-D.y}}return sN(i)}function fN(M,N){const D=pN(M);return!(D===N||!CN(D)||bN(D))&&("fixed"===ZN(D).position||fN(D,N))}function XN(M,N,D){const i=rN(N),j=nN(N),I="fixed"===D,g=HN(M,!0,I,N);let u={scrollLeft:0,scrollTop:0};const L=iN(0);if(i||!i&&!I)if(("body"!==EN(N)||kN(j))&&(u=mN(N)),i){const M=HN(N,!0,I,N);L.x=M.x+N.clientLeft,L.y=M.y+N.clientTop}else j&&(L.x=FN(j));return{x:g.left+u.scrollLeft-L.x,y:g.top+u.scrollTop-L.y,width:g.width,height:g.height}}function _N(M,N){return rN(M)&&"fixed"!==ZN(M).position?N?N(M):M.offsetParent:null}function $N(M,N){const D=SN(M);if(!rN(M))return D;let i=_N(M,N);for(;i&&QN(i)&&"static"===ZN(i).position;)i=_N(i,N);return i&&("html"===EN(i)||"body"===EN(i)&&"static"===ZN(i).position&&!hN(i))?D:i||function(M){let N=pN(M);for(;rN(N)&&!bN(N);){if(hN(N))return N;N=pN(N)}return null}(M)||D}const KN={convertOffsetParentRelativeRectToViewportRelativeRect:function(M){let{rect:N,offsetParent:D,strategy:i}=M;const j=rN(D),I=nN(D);if(D===I)return N;let g={scrollLeft:0,scrollTop:0},u=iN(1);const L=iN(0);if((j||!j&&"fixed"!==i)&&(("body"!==EN(D)||kN(I))&&(g=mN(D)),rN(D))){const M=HN(D);u=BN(D),L.x=M.x+D.clientLeft,L.y=M.y+D.clientTop}return{width:N.width*u.x,height:N.height*u.y,x:N.x*u.x-g.scrollLeft*u.x+L.x,y:N.y*u.y-g.scrollTop*u.y+L.y}},getDocumentElement:nN,getClippingRect:function(M){let{element:N,boundary:D,rootBoundary:i,strategy:j}=M;const I=[..."clippingAncestors"===D?function(M,N){const D=N.get(M);if(D)return D;let i=VN(M,[],!1).filter((M=>CN(M)&&"body"!==EN(M))),j=null;const I="fixed"===ZN(M).position;let g=I?pN(M):M;for(;CN(g)&&!bN(g);){const N=ZN(g),D=hN(g);D||"fixed"!==N.position||(j=null),(I?!D&&!j:!D&&"static"===N.position&&j&&["absolute","fixed"].includes(j.position)||kN(g)&&!D&&fN(M,g))?i=i.filter((M=>M!==g)):j=N,g=pN(g)}return N.set(M,i),i}(N,this._c):[].concat(D),i],g=I[0],u=I.reduce(((M,D)=>{const i=JN(N,D,j);return M.top=MN(i.top,M.top),M.right=qM(i.right,M.right),M.bottom=qM(i.bottom,M.bottom),M.left=MN(i.left,M.left),M}),JN(N,g,j));return{width:u.right-u.left,height:u.bottom-u.top,x:u.left,y:u.top}},getOffsetParent:$N,getElementRects:async function(M){let{reference:N,floating:D,strategy:i}=M;const j=this.getOffsetParent||$N,I=this.getDimensions;return{reference:XN(N,await j(D),i),floating:{x:0,y:0,...await I(D)}}},getClientRects:function(M){return Array.from(M.getClientRects())},getDimensions:function(M){return vN(M)},getScale:BN,isElement:CN,isRTL:function(M){return"rtl"===ZN(M).direction}};function qN(M,N,D,i){void 0===i&&(i={});const{ancestorScroll:j=!0,ancestorResize:I=!0,elementResize:g="function"==typeof ResizeObserver,layoutShift:u="function"==typeof IntersectionObserver,animationFrame:L=!1}=i,T=GN(M),z=j||I?[...T?VN(T):[],...VN(N)]:[];z.forEach((M=>{j&&M.addEventListener("scroll",D,{passive:!0}),I&&M.addEventListener("resize",D)}));const t=T&&u?function(M,N){let D,i=null;const j=nN(M);function I(){clearTimeout(D),i&&i.disconnect(),i=null}return function g(u,L){void 0===u&&(u=!1),void 0===L&&(L=1),I();const{left:T,top:z,width:t,height:A}=M.getBoundingClientRect();if(u||N(),!t||!A)return;const y={rootMargin:-DN(z)+"px "+-DN(j.clientWidth-(T+t))+"px "+-DN(j.clientHeight-(z+A))+"px "+-DN(T)+"px",threshold:MN(0,qM(1,L))||1};let c=!0;function x(M){const N=M[0].intersectionRatio;if(N!==L){if(!c)return g();N?g(!1,N):D=setTimeout((()=>{g(!1,1e-7)}),100)}c=!1}try{i=new IntersectionObserver(x,{...y,root:j.ownerDocument})}catch(M){i=new IntersectionObserver(x,y)}i.observe(M)}(!0),I}(T,D):null;let A,y=-1,c=null;g&&(c=new ResizeObserver((M=>{let[i]=M;i&&i.target===T&&c&&(c.unobserve(N),cancelAnimationFrame(y),y=requestAnimationFrame((()=>{c&&c.observe(N)}))),D()})),T&&!L&&c.observe(T),c.observe(N));let x=L?HN(M):null;return L&&function N(){const i=HN(M);!x||i.x===x.x&&i.y===x.y&&i.width===x.width&&i.height===x.height||D();x=i,A=requestAnimationFrame(N)}(),D(),()=>{z.forEach((M=>{j&&M.removeEventListener("scroll",D),I&&M.removeEventListener("resize",D)})),t&&t(),c&&c.disconnect(),c=null,L&&cancelAnimationFrame(A)}}const MD=(M,N,D)=>{const i=new Map,j={platform:KN,...D},I={...j.platform,_c:i};return(async(M,N,D)=>{const{placement:i="bottom",strategy:j="absolute",middleware:I=[],platform:g}=D,u=I.filter(Boolean),L=await(null==g.isRTL?void 0:g.isRTL(N));let T=await g.getElementRects({reference:M,floating:N,strategy:j}),{x:z,y:t}=lN(T,i,L),A=i,y={},c=0;for(let D=0;D<u.length;D++){const{name:I,fn:x}=u[D],{x:e,y:s,data:l,reset:o}=await x({x:z,y:t,initialPlacement:i,placement:A,strategy:j,middlewareData:y,rects:T,platform:g,elements:{reference:M,floating:N}});z=null!=e?e:z,t=null!=s?s:t,y={...y,[I]:{...y[I],...l}},o&&c<=50&&(c++,"object"==typeof o&&(o.placement&&(A=o.placement),o.rects&&(T=!0===o.rects?await g.getElementRects({reference:M,floating:N,strategy:j}):o.rects),({x:z,y:t}=lN(T,A,L))),D=-1)}return{x:z,y:t,placement:A,strategy:j,middlewareData:y}})(M,N,{...j,platform:I})};function ND(M){return function(M){for(let N=M;N;N=DD(N))if(N instanceof Element&&"none"===getComputedStyle(N).display)return null;for(let N=DD(M);N;N=DD(N)){if(!(N instanceof Element))continue;const M=getComputedStyle(N);if("contents"!==M.display){if("static"!==M.position||"none"!==M.filter)return N;if("BODY"===N.tagName)return N}}return null}(M)}function DD(M){return M.assignedSlot?M.assignedSlot:M.parentNode instanceof ShadowRoot?M.parentNode.host:M.parentNode}const iD=u`
1895
1895
 
1896
1896
  :host {
1897
1897
  --arrow-color: hsl(240 4.8% 95.9%);
@@ -1931,7 +1931,7 @@ const bM=Symbol.for(""),ZM=M=>{if((null==M?void 0:M.r)===bM)return null==M?void
1931
1931
  background: var(--arrow-color);
1932
1932
  z-index: -1;
1933
1933
  }
1934
- `;M.NilePopup=class extends BM{constructor(){super(...arguments),this.active=!1,this.placement="top",this.strategy="absolute",this.distance=0,this.skidding=0,this.arrow=!1,this.arrowPlacement="anchor",this.arrowPadding=10,this.flip=!1,this.flipFallbackPlacements="",this.flipFallbackStrategy="best-fit",this.flipPadding=0,this.shift=!1,this.shiftPadding=0,this.autoSizePadding=0}async connectedCallback(){super.connectedCallback(),await this.updateComplete,this.start()}disconnectedCallback(){this.stop()}async updated(M){super.updated(M),M.has("active")&&(this.active?this.start():this.stop()),M.has("anchor")&&this.handleAnchorChange(),this.active&&(await this.updateComplete,this.reposition())}async handleAnchorChange(){if(await this.stop(),this.anchor&&"string"==typeof this.anchor){const M=this.getRootNode();this.anchorEl=M.getElementById(this.anchor)}else this.anchor instanceof Element?this.anchorEl=this.anchor:this.anchorEl=this.querySelector('[slot="anchor"]');if(this.anchorEl instanceof HTMLSlotElement&&(this.anchorEl=this.anchorEl.assignedElements({flatten:!0})[0]),!this.anchorEl)throw new Error("Invalid anchor element: no anchor could be found using the anchor slot or the anchor attribute.");this.start()}start(){this.anchorEl&&(this.cleanup=qN(this.anchorEl,this.popup,(()=>{this.reposition()})))}async stop(){return new Promise((M=>{this.cleanup?(this.cleanup(),this.cleanup=void 0,this.removeAttribute("data-current-placement"),this.style.removeProperty("--auto-size-available-width"),this.style.removeProperty("--auto-size-available-height"),requestAnimationFrame((()=>M()))):M()}))}reposition(){if(!this.active||!this.anchorEl)return;const M=[wN({mainAxis:this.distance,crossAxis:this.skidding})];this.sync?M.push(ON({apply:({rects:M})=>{const N="width"===this.sync||"both"===this.sync,D="height"===this.sync||"both"===this.sync;this.popup.style.width=N?`${M.reference.width}px`:"",this.popup.style.height=D?`${M.reference.height}px`:""}})):(this.popup.style.width="",this.popup.style.height=""),this.flip&&M.push(aN({boundary:this.flipBoundary,fallbackPlacements:this.flipFallbackPlacements,fallbackStrategy:"best-fit"===this.flipFallbackStrategy?"bestFit":"initialPlacement",padding:this.flipPadding})),this.shift&&M.push(function(M){return void 0===M&&(M={}),{name:"shift",options:M,async fn(N){const{x:D,y:i,placement:j}=N,{mainAxis:I=!0,crossAxis:g=!1,limiter:u={fn:M=>{let{x:N,y:D}=M;return{x:N,y:D}}},...L}=uN(M,N),T={x:D,y:i},z=await oN(N,L),t=AN(LN(j)),A=zN(t);let y=T[A],c=T[t];if(I){const M="y"===A?"bottom":"right";y=gN(y+z["y"===A?"top":"left"],y,y-z[M])}if(g){const M="y"===t?"bottom":"right";c=gN(c+z["y"===t?"top":"left"],c,c-z[M])}const x=u.fn({...N,[A]:y,[t]:c});return{...x,data:{x:x.x-D,y:x.y-i}}}}}({boundary:this.shiftBoundary,padding:this.shiftPadding})),this.autoSize?M.push(ON({boundary:this.autoSizeBoundary,padding:this.autoSizePadding,apply:({availableWidth:M,availableHeight:N})=>{"vertical"===this.autoSize||"both"===this.autoSize?this.style.setProperty("--auto-size-available-height",`${N}px`):this.style.removeProperty("--auto-size-available-height"),"horizontal"===this.autoSize||"both"===this.autoSize?this.style.setProperty("--auto-size-available-width",`${M}px`):this.style.removeProperty("--auto-size-available-width")}})):(this.style.removeProperty("--auto-size-available-width"),this.style.removeProperty("--auto-size-available-height")),this.arrow&&M.push((M=>({name:"arrow",options:M,async fn(N){const{x:D,y:i,placement:j,rects:I,platform:g,elements:u,middlewareData:L}=N,{element:T,padding:z=0}=uN(M,N)||{};if(null==T)return{};const t=sN(z),A={x:D,y:i},y=yN(j),c=tN(y),x=await g.getDimensions(T),s="y"===y,e=s?"top":"left",l=s?"bottom":"right",o=s?"clientHeight":"clientWidth",a=I.reference[c]+I.reference[y]-A[y]-I.floating[c],w=A[y]-I.reference[y],O=await(null==g.getOffsetParent?void 0:g.getOffsetParent(T));let E=O?O[o]:0;E&&await(null==g.isElement?void 0:g.isElement(O))||(E=u.floating[o]||I.floating[c]);const S=a/2-w/2,n=E/2-x[c]/2-1,d=qM(t[e],n),C=qM(t[l],n),r=d,U=E-x[c]-C,k=E/2-x[c]/2+S,Q=gN(r,k,U),h=!L.arrow&&null!=TN(j)&&k!=Q&&I.reference[c]/2-(k<r?d:C)-x[c]/2<0,Y=h?k<r?k-r:k-U:0;return{[y]:A[y]+Y,data:{[y]:Q,centerOffset:k-Q-Y,...h&&{alignmentOffset:Y}},reset:h}}}))({element:this.arrowEl,padding:this.arrowPadding}));const N="absolute"===this.strategy?M=>KN.getOffsetParent(M,ND):KN.getOffsetParent;MD(this.anchorEl,this.popup,{placement:this.placement,middleware:M,strategy:this.strategy,platform:{...KN,getOffsetParent:N}}).then((({x:M,y:N,middlewareData:D,placement:i})=>{const j="rtl"===getComputedStyle(this).direction,I={top:"bottom",right:"left",bottom:"top",left:"right"}[i.split("-")[0]];if(this.setAttribute("data-current-placement",i),Object.assign(this.popup.style,{left:`${M}px`,top:`${N}px`}),this.arrow){const M=D.arrow.x,N=D.arrow.y;let i="",g="",u="",L="";if("start"===this.arrowPlacement){const D="number"==typeof M?`calc(${this.arrowPadding}px - var(--arrow-padding-offset))`:"";i="number"==typeof N?`calc(${this.arrowPadding}px - var(--arrow-padding-offset))`:"",g=j?D:"",L=j?"":D}else if("end"===this.arrowPlacement){const D="number"==typeof M?`calc(${this.arrowPadding}px - var(--arrow-padding-offset))`:"";g=j?"":D,L=j?D:"",u="number"==typeof N?`calc(${this.arrowPadding}px - var(--arrow-padding-offset))`:""}else"center"===this.arrowPlacement?(L="number"==typeof M?"calc(50% - var(--arrow-size-diagonal))":"",i="number"==typeof N?"calc(50% - var(--arrow-size-diagonal))":""):(L="number"==typeof M?`${M}px`:"",i="number"==typeof N?`${N}px`:"");Object.assign(this.arrowEl.style,{top:i,right:g,bottom:u,left:L,[I]:"calc(var(--arrow-size-diagonal) * -1)"})}})),this.emit("reposition")}render(){return V`
1934
+ `;M.NilePopup=class extends BM{constructor(){super(...arguments),this.active=!1,this.placement="top",this.strategy="absolute",this.distance=0,this.skidding=0,this.arrow=!1,this.arrowPlacement="anchor",this.arrowPadding=10,this.flip=!1,this.flipFallbackPlacements="",this.flipFallbackStrategy="best-fit",this.flipPadding=0,this.shift=!1,this.shiftPadding=0,this.autoSizePadding=0}async connectedCallback(){super.connectedCallback(),await this.updateComplete,this.start()}disconnectedCallback(){this.stop()}async updated(M){super.updated(M),M.has("active")&&(this.active?this.start():this.stop()),M.has("anchor")&&this.handleAnchorChange(),this.active&&(await this.updateComplete,this.reposition())}async handleAnchorChange(){if(await this.stop(),this.anchor&&"string"==typeof this.anchor){const M=this.getRootNode();this.anchorEl=M.getElementById(this.anchor)}else this.anchor instanceof Element?this.anchorEl=this.anchor:this.anchorEl=this.querySelector('[slot="anchor"]');if(this.anchorEl instanceof HTMLSlotElement&&(this.anchorEl=this.anchorEl.assignedElements({flatten:!0})[0]),!this.anchorEl)throw new Error("Invalid anchor element: no anchor could be found using the anchor slot or the anchor attribute.");this.start()}start(){this.anchorEl&&(this.cleanup=qN(this.anchorEl,this.popup,(()=>{this.reposition()})))}async stop(){return new Promise((M=>{this.cleanup?(this.cleanup(),this.cleanup=void 0,this.removeAttribute("data-current-placement"),this.style.removeProperty("--auto-size-available-width"),this.style.removeProperty("--auto-size-available-height"),requestAnimationFrame((()=>M()))):M()}))}reposition(){if(!this.active||!this.anchorEl)return;const M=[wN({mainAxis:this.distance,crossAxis:this.skidding})];this.sync?M.push(ON({apply:({rects:M})=>{const N="width"===this.sync||"both"===this.sync,D="height"===this.sync||"both"===this.sync;this.popup.style.width=N?`${M.reference.width}px`:"",this.popup.style.height=D?`${M.reference.height}px`:""}})):(this.popup.style.width="",this.popup.style.height=""),this.flip&&M.push(aN({boundary:this.flipBoundary,fallbackPlacements:this.flipFallbackPlacements,fallbackStrategy:"best-fit"===this.flipFallbackStrategy?"bestFit":"initialPlacement",padding:this.flipPadding})),this.shift&&M.push(function(M){return void 0===M&&(M={}),{name:"shift",options:M,async fn(N){const{x:D,y:i,placement:j}=N,{mainAxis:I=!0,crossAxis:g=!1,limiter:u={fn:M=>{let{x:N,y:D}=M;return{x:N,y:D}}},...L}=uN(M,N),T={x:D,y:i},z=await oN(N,L),t=AN(LN(j)),A=zN(t);let y=T[A],c=T[t];if(I){const M="y"===A?"bottom":"right";y=gN(y+z["y"===A?"top":"left"],y,y-z[M])}if(g){const M="y"===t?"bottom":"right";c=gN(c+z["y"===t?"top":"left"],c,c-z[M])}const x=u.fn({...N,[A]:y,[t]:c});return{...x,data:{x:x.x-D,y:x.y-i}}}}}({boundary:this.shiftBoundary,padding:this.shiftPadding})),this.autoSize?M.push(ON({boundary:this.autoSizeBoundary,padding:this.autoSizePadding,apply:({availableWidth:M,availableHeight:N})=>{"vertical"===this.autoSize||"both"===this.autoSize?this.style.setProperty("--auto-size-available-height",`${N}px`):this.style.removeProperty("--auto-size-available-height"),"horizontal"===this.autoSize||"both"===this.autoSize?this.style.setProperty("--auto-size-available-width",`${M}px`):this.style.removeProperty("--auto-size-available-width")}})):(this.style.removeProperty("--auto-size-available-width"),this.style.removeProperty("--auto-size-available-height")),this.arrow&&M.push((M=>({name:"arrow",options:M,async fn(N){const{x:D,y:i,placement:j,rects:I,platform:g,elements:u,middlewareData:L}=N,{element:T,padding:z=0}=uN(M,N)||{};if(null==T)return{};const t=eN(z),A={x:D,y:i},y=yN(j),c=tN(y),x=await g.getDimensions(T),e="y"===y,s=e?"top":"left",l=e?"bottom":"right",o=e?"clientHeight":"clientWidth",a=I.reference[c]+I.reference[y]-A[y]-I.floating[c],w=A[y]-I.reference[y],O=await(null==g.getOffsetParent?void 0:g.getOffsetParent(T));let E=O?O[o]:0;E&&await(null==g.isElement?void 0:g.isElement(O))||(E=u.floating[o]||I.floating[c]);const S=a/2-w/2,n=E/2-x[c]/2-1,d=qM(t[s],n),C=qM(t[l],n),r=d,U=E-x[c]-C,k=E/2-x[c]/2+S,Q=gN(r,k,U),h=!L.arrow&&null!=TN(j)&&k!=Q&&I.reference[c]/2-(k<r?d:C)-x[c]/2<0,Y=h?k<r?k-r:k-U:0;return{[y]:A[y]+Y,data:{[y]:Q,centerOffset:k-Q-Y,...h&&{alignmentOffset:Y}},reset:h}}}))({element:this.arrowEl,padding:this.arrowPadding}));const N="absolute"===this.strategy?M=>KN.getOffsetParent(M,ND):KN.getOffsetParent;MD(this.anchorEl,this.popup,{placement:this.placement,middleware:M,strategy:this.strategy,platform:{...KN,getOffsetParent:N}}).then((({x:M,y:N,middlewareData:D,placement:i})=>{const j="rtl"===getComputedStyle(this).direction,I={top:"bottom",right:"left",bottom:"top",left:"right"}[i.split("-")[0]];if(this.setAttribute("data-current-placement",i),Object.assign(this.popup.style,{left:`${M}px`,top:`${N}px`}),this.arrow){const M=D.arrow.x,N=D.arrow.y;let i="",g="",u="",L="";if("start"===this.arrowPlacement){const D="number"==typeof M?`calc(${this.arrowPadding}px - var(--arrow-padding-offset))`:"";i="number"==typeof N?`calc(${this.arrowPadding}px - var(--arrow-padding-offset))`:"",g=j?D:"",L=j?"":D}else if("end"===this.arrowPlacement){const D="number"==typeof M?`calc(${this.arrowPadding}px - var(--arrow-padding-offset))`:"";g=j?"":D,L=j?D:"",u="number"==typeof N?`calc(${this.arrowPadding}px - var(--arrow-padding-offset))`:""}else"center"===this.arrowPlacement?(L="number"==typeof M?"calc(50% - var(--arrow-size-diagonal))":"",i="number"==typeof N?"calc(50% - var(--arrow-size-diagonal))":""):(L="number"==typeof M?`${M}px`:"",i="number"==typeof N?`${N}px`:"");Object.assign(this.arrowEl.style,{top:i,right:g,bottom:u,left:L,[I]:"calc(var(--arrow-size-diagonal) * -1)"})}})),this.emit("reposition")}render(){return V`
1935
1935
  <slot name="anchor" @slotchange=${this.handleAnchorChange}></slot>
1936
1936
 
1937
1937
  <div
@@ -2119,7 +2119,7 @@ const bM=Symbol.for(""),ZM=M=>{if((null==M?void 0:M.r)===bM)return null==M?void
2119
2119
  >${this.errorMessage}</nile-form-error-message
2120
2120
  >
2121
2121
  `:""}
2122
- `}},M.NileSlideToggle.styles=xD,N([zM({type:String})],M.NileSlideToggle.prototype,"label",void 0),N([zM({type:Boolean,reflect:!0})],M.NileSlideToggle.prototype,"isChecked",void 0),N([zM({attribute:"help-text"})],M.NileSlideToggle.prototype,"helpText",void 0),N([zM({attribute:"error-message"})],M.NileSlideToggle.prototype,"errorMessage",void 0),M.NileSlideToggle=N([uM("nile-slide-toggle")],M.NileSlideToggle);var sD=u`
2122
+ `}},M.NileSlideToggle.styles=xD,N([zM({type:String})],M.NileSlideToggle.prototype,"label",void 0),N([zM({type:Boolean,reflect:!0})],M.NileSlideToggle.prototype,"isChecked",void 0),N([zM({attribute:"help-text"})],M.NileSlideToggle.prototype,"helpText",void 0),N([zM({attribute:"error-message"})],M.NileSlideToggle.prototype,"errorMessage",void 0),M.NileSlideToggle=N([uM("nile-slide-toggle")],M.NileSlideToggle);var eD=u`
2123
2123
  .nile-loader {
2124
2124
  border-radius: 50%;
2125
2125
  display: inline-block;
@@ -2143,7 +2143,7 @@ const bM=Symbol.for(""),ZM=M=>{if((null==M?void 0:M.r)===bM)return null==M?void
2143
2143
  style="width: ${this.width}px; height: ${this.height}px; background-size: ${this.width}px; position: ${this.position}; margin: ${this.margin}"
2144
2144
  class="nile-loader"
2145
2145
  ></div>
2146
- `}},M.NileLoader.styles=sD,N([zM({type:String})],M.NileLoader.prototype,"height",void 0),N([zM({type:String})],M.NileLoader.prototype,"width",void 0),N([zM({type:String})],M.NileLoader.prototype,"position",void 0),N([zM({type:String})],M.NileLoader.prototype,"margin",void 0),M.NileLoader=N([uM("nile-loader")],M.NileLoader);var eD=u`
2146
+ `}},M.NileLoader.styles=eD,N([zM({type:String})],M.NileLoader.prototype,"height",void 0),N([zM({type:String})],M.NileLoader.prototype,"width",void 0),N([zM({type:String})],M.NileLoader.prototype,"position",void 0),N([zM({type:String})],M.NileLoader.prototype,"margin",void 0),M.NileLoader=N([uM("nile-loader")],M.NileLoader);var sD=u`
2147
2147
  .nile-progress-bar__container {
2148
2148
  width: 100%;
2149
2149
  margin: 0 auto;
@@ -2191,7 +2191,7 @@ const bM=Symbol.for(""),ZM=M=>{if((null==M?void 0:M.r)===bM)return null==M?void
2191
2191
  <li><span style="width: ${this.value}%"></span></li>
2192
2192
  </ul>
2193
2193
  </div>
2194
- `}},M.NileProgressBar.styles=eD,N([zM({type:Number})],M.NileProgressBar.prototype,"value",void 0),M.NileProgressBar=N([uM("nile-progress-bar")],M.NileProgressBar);const lD=u`
2194
+ `}},M.NileProgressBar.styles=sD,N([zM({type:Number})],M.NileProgressBar.prototype,"value",void 0),M.NileProgressBar=N([uM("nile-progress-bar")],M.NileProgressBar);const lD=u`
2195
2195
  :host {
2196
2196
  --track-width: 2px;
2197
2197
  --track-color: rgb(128 128 128 / 25%);
@@ -2849,7 +2849,7 @@ const bM=Symbol.for(""),ZM=M=>{if((null==M?void 0:M.r)===bM)return null==M?void
2849
2849
  ></nile-icon-button>
2850
2850
  `:""}
2851
2851
  </span>
2852
- `}},M.NileTag.styles=aD,N([zM({reflect:!0})],M.NileTag.prototype,"variant",void 0),N([zM({reflect:!0})],M.NileTag.prototype,"size",void 0),N([zM({type:Boolean,reflect:!0})],M.NileTag.prototype,"pill",void 0),N([zM({type:Boolean})],M.NileTag.prototype,"removable",void 0),M.NileTag=N([uM("nile-tag")],M.NileTag);const wD=new Set;function OD(M){if(wD.add(M),!document.body.classList.contains("nile-scroll-lock")){const M=function(){const M=document.documentElement.clientWidth;return Math.abs(window.innerWidth-M)}();document.body.classList.add("nile-scroll-lock"),document.body.style.setProperty("--nile-scroll-lock-size",`${M}px`)}}function ED(M){wD.delete(M),0===wD.size&&(document.body.classList.remove("nile-scroll-lock"),document.body.style.removeProperty("--nile-scroll-lock-size"))}function SD(M,N,D="vertical",i="smooth"){const j=function(M,N){return{top:Math.round(M.getBoundingClientRect().top-N.getBoundingClientRect().top),left:Math.round(M.getBoundingClientRect().left-N.getBoundingClientRect().left)}}(M,N),I=j.top+N.scrollTop,g=j.left+N.scrollLeft,u=N.scrollLeft,L=N.scrollLeft+N.offsetWidth,T=N.scrollTop,z=N.scrollTop+N.offsetHeight;"horizontal"!==D&&"both"!==D||(g<u?N.scrollTo({left:g,behavior:i}):g+M.clientWidth>L&&N.scrollTo({left:g-N.offsetWidth+M.clientWidth,behavior:i})),"vertical"!==D&&"both"!==D||(I<T?N.scrollTo({top:I,behavior:i}):I+M.clientHeight>z&&N.scrollTo({top:I-N.offsetHeight+M.clientHeight,behavior:i}))}M.NileSelect=class extends BM{constructor(){super(...arguments),this.formControlController=new QM(this,{assumeInteractionOn:["nile-blur","nile-input"]}),this.hasSlotController=new YM(this,"help-text","label"),this.typeToSelectString="",this.hasFocus=!1,this.displayLabel="",this.selectedOptions=[],this.name="",this.value="",this.defaultValue="",this.size="medium",this.placeholder="Select...",this.searchValue="",this.searchEnabled=!1,this.optionsLoading=!1,this.multiple=!1,this.helpText="",this.errorMessage="",this.warning=!1,this.error=!1,this.success=!1,this.maxOptionsVisible=3,this.disabled=!1,this.clearable=!1,this.open=!1,this.hoist=!1,this.filled=!1,this.pill=!1,this.label="",this.placement="bottom",this.form="",this.required=!1,this.showSelected=!1,this.showNoResults=!1,this.noResultsMessage="No results found"}get validity(){return this.valueInput?.validity}get validationMessage(){return this.valueInput?.validationMessage}connectedCallback(){super.connectedCallback(),this.handleDocumentFocusIn=this.handleDocumentFocusIn.bind(this),this.handleDocumentKeyDown=this.handleDocumentKeyDown.bind(this),this.handleDocumentMouseDown=this.handleDocumentMouseDown.bind(this),this.open=!1,this.emit("nile-init")}disconnectedCallback(){super.disconnectedCallback(),this.emit("nile-destroy")}addOpenListeners(){document.addEventListener("focusin",this.handleDocumentFocusIn),document.addEventListener("keydown",this.handleDocumentKeyDown),document.addEventListener("mousedown",this.handleDocumentMouseDown)}removeOpenListeners(){document.removeEventListener("focusin",this.handleDocumentFocusIn),document.removeEventListener("keydown",this.handleDocumentKeyDown),document.removeEventListener("mousedown",this.handleDocumentMouseDown)}handleFocus(){this.hasFocus=!0,this.displayInput.setSelectionRange(0,0),this.emit("nile-focus",{value:this.value,name:this.name})}handleBlur(){this.hasFocus=!1,this.emit("nile-blur",{value:this.value,name:this.name})}handleDocumentFocusIn(M){const N=M.composedPath();this&&!N.includes(this)&&this.hide()}handleFooterClick(M){M.stopPropagation(),M.preventDefault()}toggleShowSelected(M){if(M.stopPropagation(),M.preventDefault(),0===this.selectedOptions?.length)return;this.showSelected=!this.showSelected;this.getAllOptions().forEach((M=>{M.selected||(M.hidden=this.showSelected)})),this.requestUpdate()}unSlectAll(){this.showSelected=!1;this.getAllOptions().forEach((M=>{M.selected=!1,M.hidden=!1})),this.value="",this.selectionChanged(),this.emit("nile-change",{value:this.value,name:this.name})}handleDocumentKeyDown(M){const N=M.target,D=null!==N.closest(".select__clear"),i=null!==N.closest("nile-icon-button");if(!D&&!i){if("Escape"===M.key&&this.open&&(M.preventDefault(),M.stopPropagation(),this.hide(),this.displayInput.focus({preventScroll:!0})),"Enter"===M.key||" "===M.key&&""===this.typeToSelectString)return M.preventDefault(),M.stopImmediatePropagation(),this.open?void(this.currentOption&&!this.currentOption.disabled&&(this.multiple?this.toggleOptionSelection(this.currentOption):this.setSelectedOptions(this.currentOption),this.updateComplete.then((()=>{this.emit("nile-input",{value:this.value,name:this.name}),this.emit("nile-change",{value:this.value,name:this.name})})),this.multiple||(this.hide(),this.displayInput.focus({preventScroll:!0})))):void this.show();if(["ArrowUp","ArrowDown","Home","End"].includes(M.key)){const N=this.getAllOptions(),D=N.indexOf(this.currentOption);let i=Math.max(0,D);if(M.preventDefault(),!this.open&&(this.show(),this.currentOption))return;"ArrowDown"===M.key?(i=D+1,i>N.length-1&&(i=0)):"ArrowUp"===M.key?(i=D-1,i<0&&(i=N.length-1)):"Home"===M.key?i=0:"End"===M.key&&(i=N.length-1),this.setCurrentOption(N[i])}if(1===M.key.length||"Backspace"===M.key){const N=this.getAllOptions();if(M.metaKey||M.ctrlKey||M.altKey)return;if(!this.open){if("Backspace"===M.key)return;this.show()}M.stopPropagation(),M.preventDefault(),clearTimeout(this.typeToSelectTimeout),this.typeToSelectTimeout=window.setTimeout((()=>this.typeToSelectString=""),1e3),"Backspace"===M.key?this.typeToSelectString=this.typeToSelectString.slice(0,-1):this.typeToSelectString+=M.key.toLowerCase();for(const M of N){if(M.getTextLabel().toLowerCase().startsWith(this.typeToSelectString)){this.setCurrentOption(M);break}}}}}handleDocumentMouseDown(M){const N=M.composedPath();this&&!N.includes(this)&&this.hide()}handleLabelClick(){this.displayInput.focus()}handleComboboxMouseDown(M){const N=M.composedPath().some((M=>M instanceof Element&&"nile-icon-button"===M.tagName.toLowerCase()));this.disabled||N||(M.preventDefault(),this.displayInput.focus({preventScroll:!0}),this.open=!this.open)}handleComboboxKeyDown(M){M.stopPropagation(),this.handleDocumentKeyDown(M)}handleClearClick(M){M.stopPropagation(),""!==this.value&&(this.setSelectedOptions([]),this.displayInput.focus({preventScroll:!0}),this.updateComplete.then((()=>{this.emit("nile-clear",{value:this.value,name:this.name}),this.emit("nile-input",{value:this.value,name:this.name}),this.emit("nile-change",{value:this.value,name:this.name})})))}handleClearMouseDown(M){M.stopPropagation(),M.preventDefault()}handleOptionClick(M){const N=M.target.closest("nile-option"),D=this.value;if(N&&!N.disabled&&(this.multiple?this.toggleOptionSelection(N):this.setSelectedOptions(N),this.updateComplete.then((()=>this.displayInput.focus({preventScroll:!0}))),this.value!==D&&this.updateComplete.then((()=>{this.emit("nile-input",{value:this.value,name:this.name}),this.emit("nile-change",{value:this.value,name:this.name})})),this.multiple||(this.hide(),this.displayInput.focus({preventScroll:!0}))),this.showSelected){this.getAllOptions().forEach((M=>{M.selected||(M.hidden=this.showSelected)})),this.requestUpdate()}}handleDefaultSlotChange(){const M=this.getAllOptions(),N=Array.isArray(this.value)?this.value:[this.value],D=[];customElements.get("nile-option")?(M.forEach((M=>D.push(M.value))),this.setSelectedOptions(M.filter((M=>N.includes(M.value))))):customElements.whenDefined("nile-option").then((()=>this.handleDefaultSlotChange()))}handleTagRemove(M,N){M.stopPropagation(),this.disabled||(this.toggleOptionSelection(N,!1),this.updateComplete.then((()=>{this.emit("nile-input",{value:this.value,name:this.name}),this.emit("nile-change",{value:this.value,name:this.name})})))}getAllOptions(){return[...this.querySelectorAll("nile-option")]}getOptionPrefix(M){const N=M.shadowRoot?.querySelector('slot[name="prefix"]');if(!N)return"";const D=N.assignedNodes(),i=[];return D.forEach((M=>{M instanceof HTMLElement?i.push(M.outerHTML):M.nodeType===Node.TEXT_NODE&&i.push(M.textContent||"")})),i.join("")}getFirstOption(){return this.querySelector("nile-option")}setCurrentOption(M){this.getAllOptions().forEach((M=>{M.current=!1,M.tabIndex=-1})),M&&(this.currentOption=M,M.current=!0,M.tabIndex=0,M.focus())}setSelectedOptions(M){const N=this.getAllOptions(),D=Array.isArray(M)?M:[M];N.forEach((M=>M.selected=!1)),D.length&&D.forEach((M=>M.selected=!0)),this.selectionChanged()}toggleOptionSelection(M,N){M.selected=!0===N||!1===N?N:!M.selected,this.selectionChanged()}selectionChanged(){this.selectedOptions=this.getAllOptions().filter((M=>M.selected)),this.multiple?(this.value=this.selectedOptions.map((M=>M.value)),this.placeholder&&0===this.value.length?this.displayLabel="":this.displayLabel=this.selectedOptions.length+" selected"):(this.value=this.selectedOptions[0]?.value??"",this.displayLabel=this.selectedOptions[0]?.getTextLabel()??""),this.updateComplete.then((()=>{this.formControlController.updateValidity()}))}handleSearchFocus(){document.removeEventListener("keydown",this.handleDocumentKeyDown)}handleSearchBlur(){document.addEventListener("keydown",this.handleDocumentKeyDown)}handleSearchChange(M){this.searchValue=M.detail.value,0===this.filterOptions(this.searchValue).length?this.showNoResults=!0:this.showNoResults=!1}filterOptions(M){const N=this.getAllOptions(),D=M.toLowerCase();let i=[];return N.forEach((M=>{const N=M.getTextLabel().toLowerCase(),j=(M.value||"").toLowerCase();N.includes(D)||j.includes(D)?(M.hidden=!1,i.push(M)):M.hidden=!0})),i}handleInvalid(M){this.formControlController.setValidity(!1),this.formControlController.emitInvalidEvent(M)}handleDisabledChange(){this.disabled&&(this.open=!1,this.handleOpenChange())}handleValueChange(){const M=this.getAllOptions(),N=Array.isArray(this.value)?this.value:[this.value];this.setSelectedOptions(M.filter((M=>N.includes(M.value))))}async handleOpenChange(){if(this.open&&!this.disabled){this.setCurrentOption(this.selectedOptions[0]||this.getFirstOption()),this.emit("nile-show",{value:this.value,name:this.name}),this.addOpenListeners(),await LD(this),this.listbox.hidden=!1,this.popup.active=!0,requestAnimationFrame((()=>{this.setCurrentOption(this.currentOption)}));const{keyframes:M,options:N}=yD(this,"select.show",{dir:"ltr"});await ID(this.popup.popup,M,N),this.currentOption&&SD(this.currentOption,this.listbox,"vertical","auto"),this.emit("nile-after-show",{value:this.value,name:this.name})}else{this.emit("nile-hide",{value:this.value,name:this.name}),this.removeOpenListeners(),await LD(this);const{keyframes:M,options:N}=yD(this,"select.hide",{dir:"ltr"});await ID(this.popup.popup,M,N),this.listbox.hidden=!0,this.popup.active=!1,this.emit("nile-after-hide",{value:this.value,name:this.name})}}async show(){if(!this.open&&!this.disabled)return this.open=!0,cD(this,"nile-after-show");this.open=!1}async hide(){if(this.open&&!this.disabled)return this.open=!1,cD(this,"nile-after-hide");this.open=!1}checkValidity(){return this.valueInput.checkValidity()}getForm(){return this.formControlController.getForm()}reportValidity(){return this.valueInput.reportValidity()}setCustomValidity(M){this.valueInput.setCustomValidity(M),this.formControlController.updateValidity()}focus(M){this.displayInput.focus(M)}blur(){this.displayInput.blur()}onInputChange(M){M.stopPropagation()}render(){const M=this.hasSlotController.test("label");this.hasSlotController.test("help-text");const N=this.hasSlotController.test("label-suffix"),D=!!this.label||!!M,i=this.clearable&&!this.disabled&&this.value.length>0,j=this.placeholder&&0===this.value.length,I=this.searchValue||"",g=!!this.helpText,u=!!this.errorMessage;return V`
2852
+ `}},M.NileTag.styles=aD,N([zM({reflect:!0})],M.NileTag.prototype,"variant",void 0),N([zM({reflect:!0})],M.NileTag.prototype,"size",void 0),N([zM({type:Boolean,reflect:!0})],M.NileTag.prototype,"pill",void 0),N([zM({type:Boolean})],M.NileTag.prototype,"removable",void 0),M.NileTag=N([uM("nile-tag")],M.NileTag);const wD=new Set;function OD(M){if(wD.add(M),!document.body.classList.contains("nile-scroll-lock")){const M=function(){const M=document.documentElement.clientWidth;return Math.abs(window.innerWidth-M)}();document.body.classList.add("nile-scroll-lock"),document.body.style.setProperty("--nile-scroll-lock-size",`${M}px`)}}function ED(M){wD.delete(M),0===wD.size&&(document.body.classList.remove("nile-scroll-lock"),document.body.style.removeProperty("--nile-scroll-lock-size"))}function SD(M,N,D="vertical",i="smooth"){const j=function(M,N){return{top:Math.round(M.getBoundingClientRect().top-N.getBoundingClientRect().top),left:Math.round(M.getBoundingClientRect().left-N.getBoundingClientRect().left)}}(M,N),I=j.top+N.scrollTop,g=j.left+N.scrollLeft,u=N.scrollLeft,L=N.scrollLeft+N.offsetWidth,T=N.scrollTop,z=N.scrollTop+N.offsetHeight;"horizontal"!==D&&"both"!==D||(g<u?N.scrollTo({left:g,behavior:i}):g+M.clientWidth>L&&N.scrollTo({left:g-N.offsetWidth+M.clientWidth,behavior:i})),"vertical"!==D&&"both"!==D||(I<T?N.scrollTo({top:I,behavior:i}):I+M.clientHeight>z&&N.scrollTo({top:I-N.offsetHeight+M.clientHeight,behavior:i}))}M.NileSelect=class extends BM{constructor(){super(...arguments),this.formControlController=new QM(this,{assumeInteractionOn:["nile-blur","nile-input"]}),this.hasSlotController=new YM(this,"help-text","label"),this.typeToSelectString="",this.hasFocus=!1,this.displayLabel="",this.selectedOptions=[],this.name="",this.value="",this.defaultValue="",this.size="medium",this.placeholder="Select...",this.searchValue="",this.searchEnabled=!1,this.optionsLoading=!1,this.multiple=!1,this.helpText="",this.errorMessage="",this.warning=!1,this.error=!1,this.success=!1,this.maxOptionsVisible=3,this.disabled=!1,this.clearable=!1,this.open=!1,this.hoist=!1,this.filled=!1,this.pill=!1,this.label="",this.placement="bottom",this.form="",this.required=!1,this.showSelected=!1,this.showNoResults=!1,this.noResultsMessage="No results found"}get validity(){return this.valueInput?.validity}get validationMessage(){return this.valueInput?.validationMessage}connectedCallback(){super.connectedCallback(),this.handleDocumentFocusIn=this.handleDocumentFocusIn.bind(this),this.handleDocumentKeyDown=this.handleDocumentKeyDown.bind(this),this.handleDocumentMouseDown=this.handleDocumentMouseDown.bind(this),this.open=!1,this.emit("nile-init")}disconnectedCallback(){super.disconnectedCallback(),this.emit("nile-destroy")}addOpenListeners(){document.addEventListener("focusin",this.handleDocumentFocusIn),document.addEventListener("keydown",this.handleDocumentKeyDown),document.addEventListener("mousedown",this.handleDocumentMouseDown)}removeOpenListeners(){document.removeEventListener("focusin",this.handleDocumentFocusIn),document.removeEventListener("keydown",this.handleDocumentKeyDown),document.removeEventListener("mousedown",this.handleDocumentMouseDown)}handleFocus(){this.hasFocus=!0,this.displayInput.setSelectionRange(0,0),this.emit("nile-focus",{value:this.value,name:this.name})}handleBlur(){this.hasFocus=!1,this.emit("nile-blur",{value:this.value,name:this.name})}handleDocumentFocusIn(M){const N=M.composedPath();this&&!N.includes(this)&&this.hide()}handleFooterClick(M){M.stopPropagation(),M.preventDefault()}toggleShowSelected(M){if(M.stopPropagation(),M.preventDefault(),0===this.selectedOptions?.length)return;this.showSelected=!this.showSelected;this.getAllOptions().forEach((M=>{M.selected||(M.hidden=this.showSelected)})),this.requestUpdate()}unSlectAll(){this.showSelected=!1;this.getAllOptions().forEach((M=>{M.selected=!1,M.hidden=!1})),this.value="",this.selectionChanged(),this.emit("nile-change",{value:this.value,name:this.name})}handleDocumentKeyDown(M){const N=M.target,D=null!==N.closest(".select__clear"),i=null!==N.closest("nile-icon-button");if(!D&&!i){if("Escape"===M.key&&this.open&&(M.preventDefault(),M.stopPropagation(),this.hide(),this.displayInput.focus({preventScroll:!0})),"Enter"===M.key||" "===M.key&&""===this.typeToSelectString)return M.preventDefault(),M.stopImmediatePropagation(),this.open?void(this.currentOption&&!this.currentOption.disabled&&(this.multiple?this.toggleOptionSelection(this.currentOption):this.setSelectedOptions(this.currentOption),this.updateComplete.then((()=>{this.emit("nile-input",{value:this.value,name:this.name}),this.emit("nile-change",{value:this.value,name:this.name})})),this.multiple||(this.hide(),this.displayInput.focus({preventScroll:!0})))):void this.show();if(["ArrowUp","ArrowDown","Home","End"].includes(M.key)){const N=this.getAllOptions(),D=N.indexOf(this.currentOption);let i=Math.max(0,D);if(M.preventDefault(),!this.open&&(this.show(),this.currentOption))return;"ArrowDown"===M.key?(i=D+1,i>N.length-1&&(i=0)):"ArrowUp"===M.key?(i=D-1,i<0&&(i=N.length-1)):"Home"===M.key?i=0:"End"===M.key&&(i=N.length-1),this.setCurrentOption(N[i])}if(1===M.key.length||"Backspace"===M.key){const N=this.getAllOptions();if(M.metaKey||M.ctrlKey||M.altKey)return;if(!this.open){if("Backspace"===M.key)return;this.show()}M.stopPropagation(),M.preventDefault(),clearTimeout(this.typeToSelectTimeout),this.typeToSelectTimeout=window.setTimeout((()=>this.typeToSelectString=""),1e3),"Backspace"===M.key?this.typeToSelectString=this.typeToSelectString.slice(0,-1):this.typeToSelectString+=M.key.toLowerCase();for(const M of N){if(M.getTextLabel().toLowerCase().startsWith(this.typeToSelectString)){this.setCurrentOption(M);break}}}}}handleDocumentMouseDown(M){const N=M.composedPath();this&&!N.includes(this)&&this.hide()}handleLabelClick(){this.displayInput.focus()}handleComboboxMouseDown(M){const N=M.composedPath().some((M=>M instanceof Element&&"nile-icon-button"===M.tagName.toLowerCase()));this.disabled||N||(M.preventDefault(),this.displayInput.focus({preventScroll:!0}),this.open=!this.open)}handleComboboxKeyDown(M){M.stopPropagation(),this.handleDocumentKeyDown(M)}handleClearClick(M){M.stopPropagation(),""!==this.value&&(this.setSelectedOptions([]),this.displayInput.focus({preventScroll:!0}),this.updateComplete.then((()=>{this.emit("nile-clear",{value:this.value,name:this.name}),this.emit("nile-input",{value:this.value,name:this.name}),this.emit("nile-change",{value:this.value,name:this.name})})))}handleClearMouseDown(M){M.stopPropagation(),M.preventDefault()}handleOptionClick(M){const N=M.target.closest("nile-option"),D=this.value;if(N&&!N.disabled&&(this.multiple?this.toggleOptionSelection(N):this.setSelectedOptions(N),this.updateComplete.then((()=>this.displayInput.focus({preventScroll:!0}))),this.value!==D&&this.updateComplete.then((()=>{this.emit("nile-input",{value:this.value,name:this.name}),this.emit("nile-change",{value:this.value,name:this.name})})),this.multiple||(this.hide(),this.displayInput.focus({preventScroll:!0}))),this.showSelected){this.getAllOptions().forEach((M=>{M.selected||(M.hidden=this.showSelected)})),this.requestUpdate()}}handleDefaultSlotChange(){const M=this.getAllOptions(),N=Array.isArray(this.value)?this.value:[this.value],D=[];customElements.get("nile-option")?(M.forEach((M=>D.push(M.value))),this.setSelectedOptions(M.filter((M=>N.includes(M.value))))):customElements.whenDefined("nile-option").then((()=>this.handleDefaultSlotChange()))}handleTagRemove(M,N){M.stopPropagation(),this.disabled||(this.toggleOptionSelection(N,!1),this.updateComplete.then((()=>{this.emit("nile-input",{value:this.value,name:this.name}),this.emit("nile-change",{value:this.value,name:this.name})})))}getAllOptions(){return[...this.querySelectorAll("nile-option")]}getOptionPrefix(M){const N=M.shadowRoot?.querySelector('slot[name="prefix"]');if(!N)return"";const D=N.assignedNodes(),i=[];return D.forEach((M=>{M instanceof HTMLElement?i.push(M.outerHTML):M.nodeType===Node.TEXT_NODE&&i.push(M.textContent||"")})),i.join("")}getFirstOption(){return this.querySelector("nile-option")}setCurrentOption(M){this.getAllOptions().forEach((M=>{M.current=!1,M.tabIndex=-1})),M&&(this.currentOption=M,M.current=!0,M.tabIndex=0,M.focus())}setSelectedOptions(M){const N=this.getAllOptions(),D=Array.isArray(M)?M:[M];N.forEach((M=>M.selected=!1)),D.length&&D.forEach((M=>M.selected=!0)),this.selectionChanged()}toggleOptionSelection(M,N){M.selected=!0===N||!1===N?N:!M.selected,this.selectionChanged()}selectionChanged(){this.selectedOptions=this.getAllOptions().filter((M=>M.selected)),this.multiple?(this.value=this.selectedOptions.map((M=>M.value)),this.placeholder&&0===this.value.length?this.displayLabel="":this.displayLabel=this.selectedOptions.length+" selected"):(this.value=this.selectedOptions[0]?.value??this.value,this.displayLabel=this.selectedOptions[0]?.getTextLabel()?this.selectedOptions[0].getTextLabel():this.value??""),this.updateComplete.then((()=>{this.formControlController.updateValidity()}))}handleSearchFocus(){document.removeEventListener("keydown",this.handleDocumentKeyDown)}handleSearchBlur(){document.addEventListener("keydown",this.handleDocumentKeyDown)}handleSearchChange(M){this.searchValue=M.detail.value,0===this.filterOptions(this.searchValue).length?this.showNoResults=!0:this.showNoResults=!1}filterOptions(M){const N=this.getAllOptions(),D=M.toLowerCase();let i=[];return N.forEach((M=>{const N=M.getTextLabel().toLowerCase(),j=(M.value||"").toLowerCase();N.includes(D)||j.includes(D)?(M.hidden=!1,i.push(M)):M.hidden=!0})),i}handleInvalid(M){this.formControlController.setValidity(!1),this.formControlController.emitInvalidEvent(M)}handleDisabledChange(){this.disabled&&(this.open=!1,this.handleOpenChange())}handleValueChange(){const M=this.getAllOptions(),N=Array.isArray(this.value)?this.value:[this.value];this.setSelectedOptions(M.filter((M=>N.includes(M.value))))}async handleOpenChange(){if(this.open&&!this.disabled){this.setCurrentOption(this.selectedOptions[0]||this.getFirstOption()),this.emit("nile-show",{value:this.value,name:this.name}),this.addOpenListeners(),await LD(this),this.listbox.hidden=!1,this.popup.active=!0,requestAnimationFrame((()=>{this.setCurrentOption(this.currentOption)}));const{keyframes:M,options:N}=yD(this,"select.show",{dir:"ltr"});await ID(this.popup.popup,M,N),this.currentOption&&SD(this.currentOption,this.listbox,"vertical","auto"),this.emit("nile-after-show",{value:this.value,name:this.name})}else{this.emit("nile-hide",{value:this.value,name:this.name}),this.removeOpenListeners(),await LD(this);const{keyframes:M,options:N}=yD(this,"select.hide",{dir:"ltr"});await ID(this.popup.popup,M,N),this.listbox.hidden=!0,this.popup.active=!1,this.emit("nile-after-hide",{value:this.value,name:this.name})}}async show(){if(!this.open&&!this.disabled)return this.open=!0,cD(this,"nile-after-show");this.open=!1}async hide(){if(this.open&&!this.disabled)return this.open=!1,cD(this,"nile-after-hide");this.open=!1}checkValidity(){return this.valueInput.checkValidity()}getForm(){return this.formControlController.getForm()}reportValidity(){return this.valueInput.reportValidity()}setCustomValidity(M){this.valueInput.setCustomValidity(M),this.formControlController.updateValidity()}focus(M){this.displayInput.focus(M)}blur(){this.displayInput.blur()}onInputChange(M){M.stopPropagation()}render(){const M=this.hasSlotController.test("label");this.hasSlotController.test("help-text");const N=this.hasSlotController.test("label-suffix"),D=!!this.label||!!M,i=this.clearable&&!this.disabled&&this.value.length>0,j=this.placeholder&&0===this.value.length,I=this.searchValue||"",g=!!this.helpText,u=!!this.errorMessage;return V`
2853
2853
  <div
2854
2854
  part="form-control"
2855
2855
  class=${wM({"form-control":!0,"form-control--small":"small"===this.size,"form-control--medium":"medium"===this.size,"form-control--large":"large"===this.size,"form-control--has-label":D,"form-control--has-help-text":g})}
@@ -3014,7 +3014,6 @@ const bM=Symbol.for(""),ZM=M=>{if((null==M?void 0:M.r)===bM)return null==M?void
3014
3014
  placeholder="Search..."
3015
3015
  @nile-input=${this.handleSearchChange}
3016
3016
  @nile-focus=${this.handleSearchFocus}
3017
- @nile-blur=${this.handleSearchBlur}
3018
3017
  @nile-change="${this.onInputChange}"
3019
3018
  >
3020
3019
  <nile-icon name="search" slot="suffix"> </nile-icon>
@@ -4092,7 +4091,6 @@ const bM=Symbol.for(""),ZM=M=>{if((null==M?void 0:M.r)===bM)return null==M?void
4092
4091
  line-height: 14px;
4093
4092
  letter-spacing: 0.2px;
4094
4093
  height: 50px;
4095
- margin-top: 10px;
4096
4094
  }
4097
4095
 
4098
4096
  .day-names,
@@ -4137,7 +4135,8 @@ const bM=Symbol.for(""),ZM=M=>{if((null==M?void 0:M.r)===bM)return null==M?void
4137
4135
  background: white;
4138
4136
  display: flex;
4139
4137
  justify-content: space-between;
4140
- width: auto;
4138
+ width: 365px;
4139
+ box-shadow: 0px 4px 8px 0px rgba(119, 125, 130, 0.15);
4141
4140
  }
4142
4141
 
4143
4142
  .selected-date,
@@ -4186,24 +4185,24 @@ const bM=Symbol.for(""),ZM=M=>{if((null==M?void 0:M.r)===bM)return null==M?void
4186
4185
  .base {
4187
4186
  background-color: white;
4188
4187
  border-radius: 4px;
4189
- padding-bottom: 20px;
4190
4188
  width: 365px;
4191
4189
  }
4192
4190
 
4193
4191
  .base__range {
4194
- width: 730px;
4192
+ padding: 24px;
4195
4193
  }
4196
4194
 
4197
4195
  .calender-input {
4198
- padding: 20px;
4196
+ margin-top: 6px;
4199
4197
  padding-bottom: 0px;
4200
- background: white;
4198
+ width: 365px;
4201
4199
  }
4202
4200
 
4203
4201
  .from {
4204
4202
  display: flex;
4205
4203
  justify-content: space-between;
4206
- gap: 20px;
4204
+ gap: 8px;
4205
+ margin-top: 12px;
4207
4206
  }
4208
4207
 
4209
4208
  .manual-input {
@@ -4211,16 +4210,18 @@ const bM=Symbol.for(""),ZM=M=>{if((null==M?void 0:M.r)===bM)return null==M?void
4211
4210
  }
4212
4211
 
4213
4212
  .manual-input-label {
4213
+ color: #7f7f7f;
4214
+ font-family: Colfax-regular;
4214
4215
  font-size: 12px;
4215
- font-style: normal;
4216
4216
  font-weight: 500;
4217
- margin-bottom: 10px;
4217
+ line-height: 12px;
4218
+ letter-spacing: 0.2px;
4218
4219
  }
4219
4220
 
4220
4221
  .button-contaner {
4221
4222
  width: 100%;
4222
4223
  text-align: right;
4223
- padding: 10px 0;
4224
+ padding: 12px 0 0 0;
4224
4225
  }
4225
4226
  `;M.NileCalendar=class extends BM{constructor(){super(...arguments),this.currentMonth=(new Date).getMonth(),this.currentYear=(new Date).getFullYear(),this.dropDownOpened=!1,this.valueAttribute=null,this.formattedDate=null,this.startDate=null,this.endDate=null,this.isSelectingStart=!0,this.range=!1}static get styles(){return[WD]}valueChanged(){if(this.range&&this.value)return this.rangeValue=this.value,void(this.value=null);if(this.value&&!isNaN(this.value.getTime())){const M=this.value.getTimezoneOffset(),N=new Date(this.value.getTime()-60*M*1e3);isNaN(N.getTime())||(this.valueAttribute=N.toISOString().split("T")[0],this.formattedDate=`${String(N.getDate()).padStart(2,"0")}/${String(N.getMonth()+1).padStart(2,"0")}/${N.getFullYear()}`)}}updated(M){if(super.updated(M),M.has("valueAttribute")){const M=new Date(this.valueAttribute||"");if(!isNaN(M.getTime())){const N=M.getTimezoneOffset();this.value=new Date(M.getTime()-60*N*1e3),this.currentMonth=this.value.getMonth(),this.currentYear=this.value.getFullYear()}}}static get observedAttributes(){return["value","range"]}attributeChangedCallback(M,N,D){"value"===M?(this.valueAttribute=D,this.initializeValue()):"range"===M&&(this.range=null!==D)}initializeValue(){if(this.range)try{const M=JSON.parse(this.valueAttribute||"");this.startDate=new Date(M.startDate),this.endDate=new Date(M.endDate),this.startDate=new Date(this.startDate.getTime()),this.endDate=new Date(this.endDate.getTime()),this.rangeValue={startDate:this.startDate,endDate:this.endDate},this.value=null}catch(M){}else if(this.valueAttribute){let M;M=new Date(this.valueAttribute),M=new Date(M.getTime()-6e4*M.getTimezoneOffset()),isNaN(M.getTime())||(this.value=M,this.currentMonth=this.value.getMonth(),this.currentYear=this.value.getFullYear(),this.rangeValue=null)}this.requestUpdate()}connectedCallback(){if(super.connectedCallback(),this.initializeValue(),this.valueAttribute){const M=new Date(this.valueAttribute);isNaN(M.getTime())||(this.value=M,this.currentMonth=this.value.getMonth(),this.currentYear=this.value.getFullYear())}this.emit("nile-init")}disconnectedCallback(){super.disconnectedCallback(),this.emit("nile-destroy")}getDaysArray(M,N){const D=new Date(M,N+1,0).getDate();return Array.from({length:D},((M,N)=>N+1))}nextMonth(){11===this.currentMonth?(this.currentMonth=0,this.currentYear++):this.currentMonth++,this.requestUpdate()}prevMonth(){0===this.currentMonth?(this.currentMonth=11,this.currentYear--):this.currentMonth--,this.requestUpdate()}selectDate(M,N,D){const i=new Date(D,N,M);this.range?(this.startDate&&this.endDate&&(this.startDate=null,this.endDate=null),this.isSelectingStart?(this.startDate=i,this.endDate&&i>this.endDate&&(this.endDate=null),this.isSelectingStart=!1):(this.isSelectingStart=!0,this.startDate&&i<this.startDate?(this.startDate=i,this.endDate=null,this.isSelectingStart=!1):this.endDate=i)):(this.value=i,this.emit("nile-changed",{value:this.value}),this.dropdown&&this.dropdown.hide()),this.requestUpdate()}confimRange(){this.startDate&&this.endDate&&(this.emit("nile-changed",{startDate:this.startDate,endDate:this.endDate}),this.dropdown&&this.dropdown.hide(),this.rangeValue={startDate:this.startDate,endDate:this.endDate})}renderMonth(M,N,D){const i=new Date(M,N,1).getDay(),j=new Date(M,N+1,0).getDay(),I=this.getDaysArray(0===N?M-1:M,0===N?11:N-1),g=this.getDaysArray(11===N?M+1:M,11===N?0:N+1),u=I.slice(I.length-i),L=g.slice(0,6-j),T=[...u,...D,...L],z=(M,N,D,i)=>{if(!i)return"";if(!this.range&&this.value){if(M===this.value.getDate()&&N===this.value.getMonth()&&D===this.value.getFullYear())return"selected-date"}const j=this.startDate&&M===this.startDate.getDate()&&N===this.startDate.getMonth()&&D===this.startDate.getFullYear(),I=this.endDate&&M===this.endDate.getDate()&&N===this.endDate.getMonth()&&D===this.endDate.getFullYear();return j?"range-start":I?"range-end":""},t=(M,N,D,i)=>{if(!i)return!1;if(this.startDate&&this.endDate){const i=new Date(D,N,M);return i>=this.startDate&&i<=this.endDate}return!1};return V`
4226
4227
  <div class="calendar">
@@ -4254,16 +4255,16 @@ const bM=Symbol.for(""),ZM=M=>{if((null==M?void 0:M.r)===bM)return null==M?void
4254
4255
  </div>
4255
4256
  `}formatDate(M){if(!M)return"";return`${String(M.getDate()).padStart(2,"0")}/${String(M.getMonth()+1).padStart(2,"0")}/${M.getFullYear()}`}formatDateRange(M){return M?M.startDate&&M.endDate?`${this.formatDate(M.startDate)} - ${this.formatDate(M.endDate)}`:"":M}handleStartDateInput(M){const N=this.parseDate(M.detail.value);this.isValidDateInput(N)||(this.startDate=null),N&&(!this.endDate||N<=this.endDate)?this.startDate=N:(this.startDate=null,this.endDate=null),this.requestUpdate()}handleEndDateInput(M){const N=this.parseDate(M.detail.value);this.isValidDateInput(N)||(this.endDate=null),N&&(!this.startDate||N>=this.startDate)?this.endDate=N:this.endDate=null,this.requestUpdate()}parseDate(M){const[N,D,i]=M.split("/").map(Number),j=new Date(i,D-1,N);return isNaN(j.getTime())?null:j}isValidDateInput(M){return/^(0[1-9]|[12][0-9]|3[01])\/(0[1-9]|1[0-2])\/\d{4}$/.test(M)}formatTime(M){if(!M)return"";return`${String(M.getHours()).padStart(2,"0")}:${String(M.getMinutes()).padStart(2,"0")}:${String(M.getSeconds()).padStart(2,"0")}`}isValidTimeInput(M){return/^([0-1]?[0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9]$/.test(M)}parseTime(M,N){if(!this.isValidTimeInput(M))return null;const[D,i,j]=M.split(":").map(Number),I=new Date(N.getTime());return I.setHours(D,i,j),I}handleStartTimeInput(M){if(!this.startDate)return void(this.startDate=null);const N=this.parseTime(M.detail.value,this.startDate);N?this.startDate=N:this.startDate.setHours(0,0,0),this.requestUpdate()}handleEndTimeInput(M){if(!this.endDate)return void(this.endDate=null);const N=this.parseTime(M.detail.value,this.endDate);N?this.endDate=N:this.endDate.setHours(0,0,0),this.requestUpdate()}render(){this.getDaysArray(this.currentYear,this.currentMonth);const M=(this.currentMonth+1)%12,N=11===this.currentMonth?this.currentYear+1:this.currentYear;return this.getDaysArray(N,M),V`
4256
4257
 
4257
- <div class="base${this.range?"__range":""}">
4258
+ <div class="base ${this.range?"base__range":""}">
4258
4259
  <div class="calendar-wrapper" >
4259
4260
  <div class="calendar-container ${this.range?"with-margin":""}">
4260
4261
  ${this.renderMonth(this.currentYear,this.currentMonth,this.getDaysArray(this.currentYear,this.currentMonth))}
4261
4262
  </div>
4262
- ${this.range?V`
4263
+ <!-- ${this.range?V`
4263
4264
  <div class="calendar-container">
4264
4265
  ${this.renderMonth(this.currentYear,(this.currentMonth+1)%12,this.getDaysArray(this.currentYear,(this.currentMonth+1)%12))}
4265
4266
  </div>
4266
- `:""}
4267
+ `:""} -->
4267
4268
 
4268
4269
  </div>
4269
4270
  ${this.range?V`
@@ -4819,4 +4820,39 @@ const bM=Symbol.for(""),ZM=M=>{if((null==M?void 0:M.r)===bM)return null==M?void
4819
4820
  </footer>
4820
4821
  </div>
4821
4822
  </div>
4822
- `}},M.NileDialog.styles=_D,N([yM(".dialog")],M.NileDialog.prototype,"dialog",void 0),N([yM(".dialog__panel")],M.NileDialog.prototype,"panel",void 0),N([yM(".dialog__overlay")],M.NileDialog.prototype,"overlay",void 0),N([zM({type:Boolean,reflect:!0})],M.NileDialog.prototype,"open",void 0),N([zM({reflect:!0})],M.NileDialog.prototype,"label",void 0),N([zM({type:Boolean,reflect:!0})],M.NileDialog.prototype,"noHeader",void 0),N([zM({type:Boolean,reflect:!0})],M.NileDialog.prototype,"preventOverlayClose",void 0),N([vM("open",{waitUntilFirstUpdate:!0})],M.NileDialog.prototype,"handleOpenChange",null),M.NileDialog=N([uM("nile-dialog")],M.NileDialog),AD("dialog.show",{keyframes:[{opacity:0,scale:.8},{opacity:1,scale:1}],options:{duration:250,easing:"ease"}}),AD("dialog.hide",{keyframes:[{opacity:1,scale:1},{opacity:0,scale:.8}],options:{duration:250,easing:"ease"}}),AD("dialog.denyClose",{keyframes:[{scale:1},{scale:1.02},{scale:1}],options:{duration:250}}),AD("dialog.overlay.show",{keyframes:[{opacity:0},{opacity:1}],options:{duration:250}}),AD("dialog.overlay.hide",{keyframes:[{opacity:1},{opacity:0}],options:{duration:250}})}({});
4823
+ `}},M.NileDialog.styles=_D,N([yM(".dialog")],M.NileDialog.prototype,"dialog",void 0),N([yM(".dialog__panel")],M.NileDialog.prototype,"panel",void 0),N([yM(".dialog__overlay")],M.NileDialog.prototype,"overlay",void 0),N([zM({type:Boolean,reflect:!0})],M.NileDialog.prototype,"open",void 0),N([zM({reflect:!0})],M.NileDialog.prototype,"label",void 0),N([zM({type:Boolean,reflect:!0})],M.NileDialog.prototype,"noHeader",void 0),N([zM({type:Boolean,reflect:!0})],M.NileDialog.prototype,"preventOverlayClose",void 0),N([vM("open",{waitUntilFirstUpdate:!0})],M.NileDialog.prototype,"handleOpenChange",null),M.NileDialog=N([uM("nile-dialog")],M.NileDialog),AD("dialog.show",{keyframes:[{opacity:0,scale:.8},{opacity:1,scale:1}],options:{duration:250,easing:"ease"}}),AD("dialog.hide",{keyframes:[{opacity:1,scale:1},{opacity:0,scale:.8}],options:{duration:250,easing:"ease"}}),AD("dialog.denyClose",{keyframes:[{scale:1},{scale:1.02},{scale:1}],options:{duration:250}}),AD("dialog.overlay.show",{keyframes:[{opacity:0},{opacity:1}],options:{duration:250}}),AD("dialog.overlay.hide",{keyframes:[{opacity:1},{opacity:0}],options:{duration:250}});const qD=u`
4824
+ :host {
4825
+ }
4826
+
4827
+ .nile-error-notification {
4828
+ font-family: Colfax-regular;
4829
+ font-size: 12px;
4830
+ font-style: normal;
4831
+ font-weight: 400;
4832
+ line-height: 12px;
4833
+ letter-spacing: 0.2px;
4834
+ border: 1px solid var(--nile-colors-red-500);
4835
+ border-left: 6px solid var(--nile-colors-red-500);
4836
+ border-radius: 4px;
4837
+ padding: 8px;
4838
+ background: var(--nile-colors-neutral-100);
4839
+ color: var(--nile-colors-red-500);
4840
+ box-sizing: border-box;
4841
+ }
4842
+
4843
+ .nile-error-notification__icon {
4844
+ vertical-align: middle;
4845
+ margin-right: 4px;
4846
+ }
4847
+ `;M.NileErrorNotification=class extends IM{constructor(){super(...arguments),this.errorMessage=""}static get styles(){return[qD]}render(){return V`
4848
+ <div class="nile-error-notification">
4849
+ <nile-icon
4850
+ name="info2"
4851
+ size="14"
4852
+ class="nile-error-notification__icon"
4853
+ part="icon"
4854
+ color="#E5434D"
4855
+ ></nile-icon>
4856
+ ${this.errorMessage}
4857
+ </div>
4858
+ `}},N([zM({type:String})],M.NileErrorNotification.prototype,"errorMessage",void 0),M.NileErrorNotification=N([uM("nile-error-notification")],M.NileErrorNotification)}({});
@@ -1,2 +1,2 @@
1
- System.register(["tslib","../index-cd83c5c8.cjs.js","lit/decorators.js","./nile-calendar.css.cjs.js","../internal/watch.cjs.js","../internal/nile-element.cjs.js","../nile-popup/nile-popup.cjs.js","../property-0f6a51ec.cjs.js","lit","lit/directives/class-map.js","../nile-popup/nile-popup.css.cjs.js"],function(_export,_context){"use strict";var t,i,s,e,n,a,h,l,_templateObject,_templateObject2,_templateObject3,_templateObject4,_templateObject5,r;function _slicedToArray(arr,i){return _arrayWithHoles(arr)||_iterableToArrayLimit(arr,i)||_unsupportedIterableToArray(arr,i)||_nonIterableRest();}function _nonIterableRest(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");}function _iterableToArrayLimit(r,l){var t=null==r?null:"undefined"!=typeof Symbol&&r[Symbol.iterator]||r["@@iterator"];if(null!=t){var e,n,i,u,a=[],f=!0,o=!1;try{if(i=(t=t.call(r)).next,0===l){if(Object(t)!==t)return;f=!1;}else for(;!(f=(e=i.call(t)).done)&&(a.push(e.value),a.length!==l);f=!0);}catch(r){o=!0,n=r;}finally{try{if(!f&&null!=t.return&&(u=t.return(),Object(u)!==u))return;}finally{if(o)throw n;}}return a;}}function _arrayWithHoles(arr){if(Array.isArray(arr))return arr;}function _taggedTemplateLiteral(strings,raw){if(!raw){raw=strings.slice(0);}return Object.freeze(Object.defineProperties(strings,{raw:{value:Object.freeze(raw)}}));}function _toConsumableArray(arr){return _arrayWithoutHoles(arr)||_iterableToArray(arr)||_unsupportedIterableToArray(arr)||_nonIterableSpread();}function _nonIterableSpread(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");}function _unsupportedIterableToArray(o,minLen){if(!o)return;if(typeof o==="string")return _arrayLikeToArray(o,minLen);var n=Object.prototype.toString.call(o).slice(8,-1);if(n==="Object"&&o.constructor)n=o.constructor.name;if(n==="Map"||n==="Set")return Array.from(o);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return _arrayLikeToArray(o,minLen);}function _iterableToArray(iter){if(typeof Symbol!=="undefined"&&iter[Symbol.iterator]!=null||iter["@@iterator"]!=null)return Array.from(iter);}function _arrayWithoutHoles(arr){if(Array.isArray(arr))return _arrayLikeToArray(arr);}function _arrayLikeToArray(arr,len){if(len==null||len>arr.length)len=arr.length;for(var i=0,arr2=new Array(len);i<len;i++)arr2[i]=arr[i];return arr2;}function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function");}}function _defineProperties(target,props){for(var i=0;i<props.length;i++){var descriptor=props[i];descriptor.enumerable=descriptor.enumerable||false;descriptor.configurable=true;if("value"in descriptor)descriptor.writable=true;Object.defineProperty(target,_toPropertyKey(descriptor.key),descriptor);}}function _createClass(Constructor,protoProps,staticProps){if(protoProps)_defineProperties(Constructor.prototype,protoProps);if(staticProps)_defineProperties(Constructor,staticProps);Object.defineProperty(Constructor,"prototype",{writable:false});return Constructor;}function _toPropertyKey(arg){var key=_toPrimitive(arg,"string");return typeof key==="symbol"?key:String(key);}function _toPrimitive(input,hint){if(typeof input!=="object"||input===null)return input;var prim=input[Symbol.toPrimitive];if(prim!==undefined){var res=prim.call(input,hint||"default");if(typeof res!=="object")return res;throw new TypeError("@@toPrimitive must return a primitive value.");}return(hint==="string"?String:Number)(input);}function _get(){if(typeof Reflect!=="undefined"&&Reflect.get){_get=Reflect.get.bind();}else{_get=function _get(target,property,receiver){var base=_superPropBase(target,property);if(!base)return;var desc=Object.getOwnPropertyDescriptor(base,property);if(desc.get){return desc.get.call(arguments.length<3?target:receiver);}return desc.value;};}return _get.apply(this,arguments);}function _superPropBase(object,property){while(!Object.prototype.hasOwnProperty.call(object,property)){object=_getPrototypeOf(object);if(object===null)break;}return object;}function _inherits(subClass,superClass){if(typeof superClass!=="function"&&superClass!==null){throw new TypeError("Super expression must either be null or a function");}subClass.prototype=Object.create(superClass&&superClass.prototype,{constructor:{value:subClass,writable:true,configurable:true}});Object.defineProperty(subClass,"prototype",{writable:false});if(superClass)_setPrototypeOf(subClass,superClass);}function _setPrototypeOf(o,p){_setPrototypeOf=Object.setPrototypeOf?Object.setPrototypeOf.bind():function _setPrototypeOf(o,p){o.__proto__=p;return o;};return _setPrototypeOf(o,p);}function _createSuper(Derived){var hasNativeReflectConstruct=_isNativeReflectConstruct();return function _createSuperInternal(){var Super=_getPrototypeOf(Derived),result;if(hasNativeReflectConstruct){var NewTarget=_getPrototypeOf(this).constructor;result=Reflect.construct(Super,arguments,NewTarget);}else{result=Super.apply(this,arguments);}return _possibleConstructorReturn(this,result);};}function _possibleConstructorReturn(self,call){if(call&&(typeof call==="object"||typeof call==="function")){return call;}else if(call!==void 0){throw new TypeError("Derived constructors may only return object or undefined");}return _assertThisInitialized(self);}function _assertThisInitialized(self){if(self===void 0){throw new ReferenceError("this hasn't been initialised - super() hasn't been called");}return self;}function _isNativeReflectConstruct(){if(typeof Reflect==="undefined"||!Reflect.construct)return false;if(Reflect.construct.sham)return false;if(typeof Proxy==="function")return true;try{Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}));return true;}catch(e){return false;}}function _getPrototypeOf(o){_getPrototypeOf=Object.setPrototypeOf?Object.getPrototypeOf.bind():function _getPrototypeOf(o){return o.__proto__||Object.getPrototypeOf(o);};return _getPrototypeOf(o);}return{setters:[function(_tslib){t=_tslib.__decorate;},function(_index001CjsJs){i=_index001CjsJs.x;},function(_litDecoratorsJs){s=_litDecoratorsJs.query;e=_litDecoratorsJs.customElement;},function(_nileCalendarCssCjsJs){n=_nileCalendarCssCjsJs.s;},function(_internalWatchCjsJs){a=_internalWatchCjsJs.w;},function(_internalNileElementCjsJs){h=_internalNileElementCjsJs.N;},function(_nilePopupNilePopupCjsJs){},function(_property002CjsJs){l=_property002CjsJs.n;},function(_lit){},function(_litDirectivesClassMapJs){},function(_nilePopupNilePopupCssCjsJs){}],execute:function(){_export("N",r=/*#__PURE__*/function(_h){_inherits(r,_h);var _super=_createSuper(r);function r(){var _this;_classCallCheck(this,r);_this=_super.apply(this,arguments),_this.currentMonth=new Date().getMonth(),_this.currentYear=new Date().getFullYear(),_this.dropDownOpened=!1,_this.valueAttribute=null,_this.formattedDate=null,_this.startDate=null,_this.endDate=null,_this.isSelectingStart=!0,_this.range=!1;return _this;}_createClass(r,[{key:"valueChanged",value:function valueChanged(){if(this.range&&this.value)return this.rangeValue=this.value,void(this.value=null);if(this.value&&!isNaN(this.value.getTime())){var _t=this.value.getTimezoneOffset(),_i=new Date(this.value.getTime()-60*_t*1e3);isNaN(_i.getTime())||(this.valueAttribute=_i.toISOString().split("T")[0],this.formattedDate="".concat(String(_i.getDate()).padStart(2,"0"),"/").concat(String(_i.getMonth()+1).padStart(2,"0"),"/").concat(_i.getFullYear()));}}},{key:"updated",value:function updated(t){if(_get(_getPrototypeOf(r.prototype),"updated",this).call(this,t),t.has("valueAttribute")){var _t2=new Date(this.valueAttribute||"");if(!isNaN(_t2.getTime())){var _i2=_t2.getTimezoneOffset();this.value=new Date(_t2.getTime()-60*_i2*1e3),this.currentMonth=this.value.getMonth(),this.currentYear=this.value.getFullYear();}}}},{key:"attributeChangedCallback",value:function attributeChangedCallback(t,i,s){"value"===t?(this.valueAttribute=s,this.initializeValue()):"range"===t&&(this.range=null!==s);}},{key:"initializeValue",value:function initializeValue(){if(this.range)try{var _t3=JSON.parse(this.valueAttribute||"");this.startDate=new Date(_t3.startDate),this.endDate=new Date(_t3.endDate),this.startDate=new Date(this.startDate.getTime()),this.endDate=new Date(this.endDate.getTime()),this.rangeValue={startDate:this.startDate,endDate:this.endDate},this.value=null;}catch(t){}else if(this.valueAttribute){var _t4;_t4=new Date(this.valueAttribute),_t4=new Date(_t4.getTime()-6e4*_t4.getTimezoneOffset()),isNaN(_t4.getTime())||(this.value=_t4,this.currentMonth=this.value.getMonth(),this.currentYear=this.value.getFullYear(),this.rangeValue=null);}this.requestUpdate();}},{key:"connectedCallback",value:function connectedCallback(){if(_get(_getPrototypeOf(r.prototype),"connectedCallback",this).call(this),this.initializeValue(),this.valueAttribute){var _t5=new Date(this.valueAttribute);isNaN(_t5.getTime())||(this.value=_t5,this.currentMonth=this.value.getMonth(),this.currentYear=this.value.getFullYear());}this.emit("nile-init");}},{key:"disconnectedCallback",value:function disconnectedCallback(){_get(_getPrototypeOf(r.prototype),"disconnectedCallback",this).call(this),this.emit("nile-destroy");}},{key:"getDaysArray",value:function getDaysArray(t,i){var s=new Date(t,i+1,0).getDate();return Array.from({length:s},function(t,i){return i+1;});}},{key:"nextMonth",value:function nextMonth(){11===this.currentMonth?(this.currentMonth=0,this.currentYear++):this.currentMonth++,this.requestUpdate();}},{key:"prevMonth",value:function prevMonth(){0===this.currentMonth?(this.currentMonth=11,this.currentYear--):this.currentMonth--,this.requestUpdate();}},{key:"selectDate",value:function selectDate(t,i,s){var e=new Date(s,i,t);this.range?(this.startDate&&this.endDate&&(this.startDate=null,this.endDate=null),this.isSelectingStart?(this.startDate=e,this.endDate&&e>this.endDate&&(this.endDate=null),this.isSelectingStart=!1):(this.isSelectingStart=!0,this.startDate&&e<this.startDate?(this.startDate=e,this.endDate=null,this.isSelectingStart=!1):this.endDate=e)):(this.value=e,this.emit("nile-changed",{value:this.value}),this.dropdown&&this.dropdown.hide()),this.requestUpdate();}},{key:"confimRange",value:function confimRange(){this.startDate&&this.endDate&&(this.emit("nile-changed",{startDate:this.startDate,endDate:this.endDate}),this.dropdown&&this.dropdown.hide(),this.rangeValue={startDate:this.startDate,endDate:this.endDate});}},{key:"renderMonth",value:function renderMonth(t,s,e){var _this2=this;var n=new Date(t,s,1).getDay(),a=new Date(t,s+1,0).getDay(),h=this.getDaysArray(0===s?t-1:t,0===s?11:s-1),l=this.getDaysArray(11===s?t+1:t,11===s?0:s+1),_r=h.slice(h.length-n),d=l.slice(0,6-a),c=[].concat(_toConsumableArray(_r),_toConsumableArray(e),_toConsumableArray(d)),u=function u(t,i,s,e){if(!e)return"";if(!_this2.range&&_this2.value){if(t===_this2.value.getDate()&&i===_this2.value.getMonth()&&s===_this2.value.getFullYear())return"selected-date";}var n=_this2.startDate&&t===_this2.startDate.getDate()&&i===_this2.startDate.getMonth()&&s===_this2.startDate.getFullYear(),a=_this2.endDate&&t===_this2.endDate.getDate()&&i===_this2.endDate.getMonth()&&s===_this2.endDate.getFullYear();return n?"range-start":a?"range-end":"";},o=function o(t,i,s,e){if(!e)return!1;if(_this2.startDate&&_this2.endDate){var _e=new Date(s,i,t);return _e>=_this2.startDate&&_e<=_this2.endDate;}return!1;};return i(_templateObject||(_templateObject=_taggedTemplateLiteral(["\n <div class=\"calendar\">\n <div class=\"calendar-header\">\n <nile-icon class=\"calendar-header__month-navigation\" name=\"arrowleft\" color=\"black\" @click=\"","\">\n </nile-icon>\n <span\n >","\n ","</span\n >\n <nile-icon class=\"calendar-header__month-navigation\" name=\"arrowright\" color=\"black\" @click=\"","\">\n </nile-icon>\n </div>\n <div class=\"day-names\">\n <div class=\"day\">Sun</div>\n <div class=\"day\">Mon</div>\n <div class=\"day\">Tue</div>\n <div class=\"day\">Wed</div>\n <div class=\"day\">Thu</div>\n <div class=\"day\">Fri</div>\n <div class=\"day\">Sat</div>\n </div>\n <div class=\"days\">\n ","\n </div>\n </div>\n "])),this.prevMonth,new Date(t,s).toLocaleString("default",{month:"long"}),t,this.nextMonth,c.map(function(n,a){var h=a>=_r.length&&a<_r.length+e.length;return i(_templateObject2||(_templateObject2=_taggedTemplateLiteral([" <div\n class=\"day "," "," ","\"\n @click=\"","\"\n >\n ","\n </div>"])),u(n,s,t,h),o(n,s,t,h)?"in-range":"",h?"":"filler",function(){h&&_this2.selectDate(n,s,t);},n);}));}},{key:"formatDate",value:function formatDate(t){if(!t)return"";return"".concat(String(t.getDate()).padStart(2,"0"),"/").concat(String(t.getMonth()+1).padStart(2,"0"),"/").concat(t.getFullYear());}},{key:"formatDateRange",value:function formatDateRange(t){return t?t.startDate&&t.endDate?"".concat(this.formatDate(t.startDate)," - ").concat(this.formatDate(t.endDate)):"":t;}},{key:"handleStartDateInput",value:function handleStartDateInput(t){var i=this.parseDate(t.detail.value);this.isValidDateInput(i)||(this.startDate=null),i&&(!this.endDate||i<=this.endDate)?this.startDate=i:(this.startDate=null,this.endDate=null),this.requestUpdate();}},{key:"handleEndDateInput",value:function handleEndDateInput(t){var i=this.parseDate(t.detail.value);this.isValidDateInput(i)||(this.endDate=null),i&&(!this.startDate||i>=this.startDate)?this.endDate=i:this.endDate=null,this.requestUpdate();}},{key:"parseDate",value:function parseDate(t){var _t$split$map=t.split("/").map(Number),_t$split$map2=_slicedToArray(_t$split$map,3),i=_t$split$map2[0],s=_t$split$map2[1],e=_t$split$map2[2],n=new Date(e,s-1,i);return isNaN(n.getTime())?null:n;}},{key:"isValidDateInput",value:function isValidDateInput(t){return /^(0[1-9]|[12][0-9]|3[01])\/(0[1-9]|1[0-2])\/\d{4}$/.test(t);}},{key:"formatTime",value:function formatTime(t){if(!t)return"";return"".concat(String(t.getHours()).padStart(2,"0"),":").concat(String(t.getMinutes()).padStart(2,"0"),":").concat(String(t.getSeconds()).padStart(2,"0"));}},{key:"isValidTimeInput",value:function isValidTimeInput(t){return /^([0-1]?[0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9]$/.test(t);}},{key:"parseTime",value:function parseTime(t,i){if(!this.isValidTimeInput(t))return null;var _t$split$map3=t.split(":").map(Number),_t$split$map4=_slicedToArray(_t$split$map3,3),s=_t$split$map4[0],e=_t$split$map4[1],n=_t$split$map4[2],a=new Date(i.getTime());return a.setHours(s,e,n),a;}},{key:"handleStartTimeInput",value:function handleStartTimeInput(t){if(!this.startDate)return void(this.startDate=null);var i=this.parseTime(t.detail.value,this.startDate);i?this.startDate=i:this.startDate.setHours(0,0,0),this.requestUpdate();}},{key:"handleEndTimeInput",value:function handleEndTimeInput(t){if(!this.endDate)return void(this.endDate=null);var i=this.parseTime(t.detail.value,this.endDate);i?this.endDate=i:this.endDate.setHours(0,0,0),this.requestUpdate();}},{key:"render",value:function render(){this.getDaysArray(this.currentYear,this.currentMonth);var t=(this.currentMonth+1)%12,s=11===this.currentMonth?this.currentYear+1:this.currentYear;return this.getDaysArray(s,t),i(_templateObject3||(_templateObject3=_taggedTemplateLiteral(["\n\n <div class=\"base","\">\n <div class=\"calendar-wrapper\" >\n <div class=\"calendar-container ","\">\n ","\n </div>\n ","\n\n </div>\n ","\n </div>\n "])),this.range?"__range":"",this.range?"with-margin":"",this.renderMonth(this.currentYear,this.currentMonth,this.getDaysArray(this.currentYear,this.currentMonth)),this.range?i(_templateObject4||(_templateObject4=_taggedTemplateLiteral(["\n <div class=\"calendar-container\">\n ","\n </div>\n "])),this.renderMonth(this.currentYear,(this.currentMonth+1)%12,this.getDaysArray(this.currentYear,(this.currentMonth+1)%12))):"",this.range?i(_templateObject5||(_templateObject5=_taggedTemplateLiteral(["\n <div class=\"calender-input\">\n <span class=\"manual-input-label\">From </span>\n <div class=\"from\">\n <nile-input class=\"manual-input\" value=\"","\" placeholder=\"DD/MM/YYYY\" @nile-change=\"","\"></nile-input>\n <nile-input class=\"manual-input\" value=\"","\" placeholder=\"HH:MM:SS\" @nile-change=\"","\"> </nile-input>\n\n </div>\n<br>\n <span class=\"manual-input-label\">To </span>\n <div class=\"from\">\n <nile-input class=\"manual-input\" value=\"","\" placeholder=\"DD/MM/YYYY\" @nile-change=\"","\"></nile-input>\n <nile-input class=\"manual-input\" value=\"","\" placeholder=\"HH:MM:SS\" @nile-change=\"","\"> </nile-input>\n </div>\n <div class=\"button-contaner\">\n <nile-button class=\"apply-button\" ?disabled=\"","\" @click=\"","\"> Apply</nile-button>\n </div>\n\n\n </div>\n </div>\n "])),this.formatDate(this.startDate),this.handleStartDateInput,this.formatTime(this.startDate),this.handleStartTimeInput,this.formatDate(this.endDate),this.handleEndDateInput,this.formatTime(this.endDate),this.handleEndTimeInput,!this.startDate||!this.endDate,this.confimRange):"");}}],[{key:"styles",get:function get(){return[n];}},{key:"observedAttributes",get:function get(){return["value","range"];}}]);return r;}(h));t([s("nile-dropdown")],r.prototype,"dropdown",void 0),t([l({type:Boolean,reflect:!0})],r.prototype,"dropDownOpened",void 0),t([l({type:Object})],r.prototype,"value",void 0),t([l({type:Object})],r.prototype,"rangeValue",void 0),t([l({type:String,attribute:"value"})],r.prototype,"valueAttribute",void 0),t([l({type:String,attribute:"value"})],r.prototype,"formattedDate",void 0),t([l({type:Object})],r.prototype,"startDate",void 0),t([l({type:Object})],r.prototype,"endDate",void 0),t([l({type:Boolean})],r.prototype,"isSelectingStart",void 0),t([l({type:Boolean})],r.prototype,"range",void 0),t([a("value")],r.prototype,"valueChanged",null),_export("N",r=t([e("nile-calendar")],r));}};});
1
+ System.register(["tslib","../index-cd83c5c8.cjs.js","lit/decorators.js","./nile-calendar.css.cjs.js","../internal/watch.cjs.js","../internal/nile-element.cjs.js","../nile-popup/nile-popup.cjs.js","../property-0f6a51ec.cjs.js","lit","lit/directives/class-map.js","../nile-popup/nile-popup.css.cjs.js"],function(_export,_context){"use strict";var t,i,s,e,n,a,h,l,_templateObject,_templateObject2,_templateObject3,_templateObject4,_templateObject5,r;function _slicedToArray(arr,i){return _arrayWithHoles(arr)||_iterableToArrayLimit(arr,i)||_unsupportedIterableToArray(arr,i)||_nonIterableRest();}function _nonIterableRest(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");}function _iterableToArrayLimit(r,l){var t=null==r?null:"undefined"!=typeof Symbol&&r[Symbol.iterator]||r["@@iterator"];if(null!=t){var e,n,i,u,a=[],f=!0,o=!1;try{if(i=(t=t.call(r)).next,0===l){if(Object(t)!==t)return;f=!1;}else for(;!(f=(e=i.call(t)).done)&&(a.push(e.value),a.length!==l);f=!0);}catch(r){o=!0,n=r;}finally{try{if(!f&&null!=t.return&&(u=t.return(),Object(u)!==u))return;}finally{if(o)throw n;}}return a;}}function _arrayWithHoles(arr){if(Array.isArray(arr))return arr;}function _taggedTemplateLiteral(strings,raw){if(!raw){raw=strings.slice(0);}return Object.freeze(Object.defineProperties(strings,{raw:{value:Object.freeze(raw)}}));}function _toConsumableArray(arr){return _arrayWithoutHoles(arr)||_iterableToArray(arr)||_unsupportedIterableToArray(arr)||_nonIterableSpread();}function _nonIterableSpread(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");}function _unsupportedIterableToArray(o,minLen){if(!o)return;if(typeof o==="string")return _arrayLikeToArray(o,minLen);var n=Object.prototype.toString.call(o).slice(8,-1);if(n==="Object"&&o.constructor)n=o.constructor.name;if(n==="Map"||n==="Set")return Array.from(o);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return _arrayLikeToArray(o,minLen);}function _iterableToArray(iter){if(typeof Symbol!=="undefined"&&iter[Symbol.iterator]!=null||iter["@@iterator"]!=null)return Array.from(iter);}function _arrayWithoutHoles(arr){if(Array.isArray(arr))return _arrayLikeToArray(arr);}function _arrayLikeToArray(arr,len){if(len==null||len>arr.length)len=arr.length;for(var i=0,arr2=new Array(len);i<len;i++)arr2[i]=arr[i];return arr2;}function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function");}}function _defineProperties(target,props){for(var i=0;i<props.length;i++){var descriptor=props[i];descriptor.enumerable=descriptor.enumerable||false;descriptor.configurable=true;if("value"in descriptor)descriptor.writable=true;Object.defineProperty(target,_toPropertyKey(descriptor.key),descriptor);}}function _createClass(Constructor,protoProps,staticProps){if(protoProps)_defineProperties(Constructor.prototype,protoProps);if(staticProps)_defineProperties(Constructor,staticProps);Object.defineProperty(Constructor,"prototype",{writable:false});return Constructor;}function _toPropertyKey(arg){var key=_toPrimitive(arg,"string");return typeof key==="symbol"?key:String(key);}function _toPrimitive(input,hint){if(typeof input!=="object"||input===null)return input;var prim=input[Symbol.toPrimitive];if(prim!==undefined){var res=prim.call(input,hint||"default");if(typeof res!=="object")return res;throw new TypeError("@@toPrimitive must return a primitive value.");}return(hint==="string"?String:Number)(input);}function _get(){if(typeof Reflect!=="undefined"&&Reflect.get){_get=Reflect.get.bind();}else{_get=function _get(target,property,receiver){var base=_superPropBase(target,property);if(!base)return;var desc=Object.getOwnPropertyDescriptor(base,property);if(desc.get){return desc.get.call(arguments.length<3?target:receiver);}return desc.value;};}return _get.apply(this,arguments);}function _superPropBase(object,property){while(!Object.prototype.hasOwnProperty.call(object,property)){object=_getPrototypeOf(object);if(object===null)break;}return object;}function _inherits(subClass,superClass){if(typeof superClass!=="function"&&superClass!==null){throw new TypeError("Super expression must either be null or a function");}subClass.prototype=Object.create(superClass&&superClass.prototype,{constructor:{value:subClass,writable:true,configurable:true}});Object.defineProperty(subClass,"prototype",{writable:false});if(superClass)_setPrototypeOf(subClass,superClass);}function _setPrototypeOf(o,p){_setPrototypeOf=Object.setPrototypeOf?Object.setPrototypeOf.bind():function _setPrototypeOf(o,p){o.__proto__=p;return o;};return _setPrototypeOf(o,p);}function _createSuper(Derived){var hasNativeReflectConstruct=_isNativeReflectConstruct();return function _createSuperInternal(){var Super=_getPrototypeOf(Derived),result;if(hasNativeReflectConstruct){var NewTarget=_getPrototypeOf(this).constructor;result=Reflect.construct(Super,arguments,NewTarget);}else{result=Super.apply(this,arguments);}return _possibleConstructorReturn(this,result);};}function _possibleConstructorReturn(self,call){if(call&&(typeof call==="object"||typeof call==="function")){return call;}else if(call!==void 0){throw new TypeError("Derived constructors may only return object or undefined");}return _assertThisInitialized(self);}function _assertThisInitialized(self){if(self===void 0){throw new ReferenceError("this hasn't been initialised - super() hasn't been called");}return self;}function _isNativeReflectConstruct(){if(typeof Reflect==="undefined"||!Reflect.construct)return false;if(Reflect.construct.sham)return false;if(typeof Proxy==="function")return true;try{Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}));return true;}catch(e){return false;}}function _getPrototypeOf(o){_getPrototypeOf=Object.setPrototypeOf?Object.getPrototypeOf.bind():function _getPrototypeOf(o){return o.__proto__||Object.getPrototypeOf(o);};return _getPrototypeOf(o);}return{setters:[function(_tslib){t=_tslib.__decorate;},function(_index001CjsJs){i=_index001CjsJs.x;},function(_litDecoratorsJs){s=_litDecoratorsJs.query;e=_litDecoratorsJs.customElement;},function(_nileCalendarCssCjsJs){n=_nileCalendarCssCjsJs.s;},function(_internalWatchCjsJs){a=_internalWatchCjsJs.w;},function(_internalNileElementCjsJs){h=_internalNileElementCjsJs.N;},function(_nilePopupNilePopupCjsJs){},function(_property002CjsJs){l=_property002CjsJs.n;},function(_lit){},function(_litDirectivesClassMapJs){},function(_nilePopupNilePopupCssCjsJs){}],execute:function(){_export("N",r=/*#__PURE__*/function(_h){_inherits(r,_h);var _super=_createSuper(r);function r(){var _this;_classCallCheck(this,r);_this=_super.apply(this,arguments),_this.currentMonth=new Date().getMonth(),_this.currentYear=new Date().getFullYear(),_this.dropDownOpened=!1,_this.valueAttribute=null,_this.formattedDate=null,_this.startDate=null,_this.endDate=null,_this.isSelectingStart=!0,_this.range=!1;return _this;}_createClass(r,[{key:"valueChanged",value:function valueChanged(){if(this.range&&this.value)return this.rangeValue=this.value,void(this.value=null);if(this.value&&!isNaN(this.value.getTime())){var _t=this.value.getTimezoneOffset(),_i=new Date(this.value.getTime()-60*_t*1e3);isNaN(_i.getTime())||(this.valueAttribute=_i.toISOString().split("T")[0],this.formattedDate="".concat(String(_i.getDate()).padStart(2,"0"),"/").concat(String(_i.getMonth()+1).padStart(2,"0"),"/").concat(_i.getFullYear()));}}},{key:"updated",value:function updated(t){if(_get(_getPrototypeOf(r.prototype),"updated",this).call(this,t),t.has("valueAttribute")){var _t2=new Date(this.valueAttribute||"");if(!isNaN(_t2.getTime())){var _i2=_t2.getTimezoneOffset();this.value=new Date(_t2.getTime()-60*_i2*1e3),this.currentMonth=this.value.getMonth(),this.currentYear=this.value.getFullYear();}}}},{key:"attributeChangedCallback",value:function attributeChangedCallback(t,i,s){"value"===t?(this.valueAttribute=s,this.initializeValue()):"range"===t&&(this.range=null!==s);}},{key:"initializeValue",value:function initializeValue(){if(this.range)try{var _t3=JSON.parse(this.valueAttribute||"");this.startDate=new Date(_t3.startDate),this.endDate=new Date(_t3.endDate),this.startDate=new Date(this.startDate.getTime()),this.endDate=new Date(this.endDate.getTime()),this.rangeValue={startDate:this.startDate,endDate:this.endDate},this.value=null;}catch(t){}else if(this.valueAttribute){var _t4;_t4=new Date(this.valueAttribute),_t4=new Date(_t4.getTime()-6e4*_t4.getTimezoneOffset()),isNaN(_t4.getTime())||(this.value=_t4,this.currentMonth=this.value.getMonth(),this.currentYear=this.value.getFullYear(),this.rangeValue=null);}this.requestUpdate();}},{key:"connectedCallback",value:function connectedCallback(){if(_get(_getPrototypeOf(r.prototype),"connectedCallback",this).call(this),this.initializeValue(),this.valueAttribute){var _t5=new Date(this.valueAttribute);isNaN(_t5.getTime())||(this.value=_t5,this.currentMonth=this.value.getMonth(),this.currentYear=this.value.getFullYear());}this.emit("nile-init");}},{key:"disconnectedCallback",value:function disconnectedCallback(){_get(_getPrototypeOf(r.prototype),"disconnectedCallback",this).call(this),this.emit("nile-destroy");}},{key:"getDaysArray",value:function getDaysArray(t,i){var s=new Date(t,i+1,0).getDate();return Array.from({length:s},function(t,i){return i+1;});}},{key:"nextMonth",value:function nextMonth(){11===this.currentMonth?(this.currentMonth=0,this.currentYear++):this.currentMonth++,this.requestUpdate();}},{key:"prevMonth",value:function prevMonth(){0===this.currentMonth?(this.currentMonth=11,this.currentYear--):this.currentMonth--,this.requestUpdate();}},{key:"selectDate",value:function selectDate(t,i,s){var e=new Date(s,i,t);this.range?(this.startDate&&this.endDate&&(this.startDate=null,this.endDate=null),this.isSelectingStart?(this.startDate=e,this.endDate&&e>this.endDate&&(this.endDate=null),this.isSelectingStart=!1):(this.isSelectingStart=!0,this.startDate&&e<this.startDate?(this.startDate=e,this.endDate=null,this.isSelectingStart=!1):this.endDate=e)):(this.value=e,this.emit("nile-changed",{value:this.value}),this.dropdown&&this.dropdown.hide()),this.requestUpdate();}},{key:"confimRange",value:function confimRange(){this.startDate&&this.endDate&&(this.emit("nile-changed",{startDate:this.startDate,endDate:this.endDate}),this.dropdown&&this.dropdown.hide(),this.rangeValue={startDate:this.startDate,endDate:this.endDate});}},{key:"renderMonth",value:function renderMonth(t,s,e){var _this2=this;var n=new Date(t,s,1).getDay(),a=new Date(t,s+1,0).getDay(),h=this.getDaysArray(0===s?t-1:t,0===s?11:s-1),l=this.getDaysArray(11===s?t+1:t,11===s?0:s+1),_r=h.slice(h.length-n),d=l.slice(0,6-a),c=[].concat(_toConsumableArray(_r),_toConsumableArray(e),_toConsumableArray(d)),u=function u(t,i,s,e){if(!e)return"";if(!_this2.range&&_this2.value){if(t===_this2.value.getDate()&&i===_this2.value.getMonth()&&s===_this2.value.getFullYear())return"selected-date";}var n=_this2.startDate&&t===_this2.startDate.getDate()&&i===_this2.startDate.getMonth()&&s===_this2.startDate.getFullYear(),a=_this2.endDate&&t===_this2.endDate.getDate()&&i===_this2.endDate.getMonth()&&s===_this2.endDate.getFullYear();return n?"range-start":a?"range-end":"";},o=function o(t,i,s,e){if(!e)return!1;if(_this2.startDate&&_this2.endDate){var _e=new Date(s,i,t);return _e>=_this2.startDate&&_e<=_this2.endDate;}return!1;};return i(_templateObject||(_templateObject=_taggedTemplateLiteral(["\n <div class=\"calendar\">\n <div class=\"calendar-header\">\n <nile-icon class=\"calendar-header__month-navigation\" name=\"arrowleft\" color=\"black\" @click=\"","\">\n </nile-icon>\n <span\n >","\n ","</span\n >\n <nile-icon class=\"calendar-header__month-navigation\" name=\"arrowright\" color=\"black\" @click=\"","\">\n </nile-icon>\n </div>\n <div class=\"day-names\">\n <div class=\"day\">Sun</div>\n <div class=\"day\">Mon</div>\n <div class=\"day\">Tue</div>\n <div class=\"day\">Wed</div>\n <div class=\"day\">Thu</div>\n <div class=\"day\">Fri</div>\n <div class=\"day\">Sat</div>\n </div>\n <div class=\"days\">\n ","\n </div>\n </div>\n "])),this.prevMonth,new Date(t,s).toLocaleString("default",{month:"long"}),t,this.nextMonth,c.map(function(n,a){var h=a>=_r.length&&a<_r.length+e.length;return i(_templateObject2||(_templateObject2=_taggedTemplateLiteral([" <div\n class=\"day "," "," ","\"\n @click=\"","\"\n >\n ","\n </div>"])),u(n,s,t,h),o(n,s,t,h)?"in-range":"",h?"":"filler",function(){h&&_this2.selectDate(n,s,t);},n);}));}},{key:"formatDate",value:function formatDate(t){if(!t)return"";return"".concat(String(t.getDate()).padStart(2,"0"),"/").concat(String(t.getMonth()+1).padStart(2,"0"),"/").concat(t.getFullYear());}},{key:"formatDateRange",value:function formatDateRange(t){return t?t.startDate&&t.endDate?"".concat(this.formatDate(t.startDate)," - ").concat(this.formatDate(t.endDate)):"":t;}},{key:"handleStartDateInput",value:function handleStartDateInput(t){var i=this.parseDate(t.detail.value);this.isValidDateInput(i)||(this.startDate=null),i&&(!this.endDate||i<=this.endDate)?this.startDate=i:(this.startDate=null,this.endDate=null),this.requestUpdate();}},{key:"handleEndDateInput",value:function handleEndDateInput(t){var i=this.parseDate(t.detail.value);this.isValidDateInput(i)||(this.endDate=null),i&&(!this.startDate||i>=this.startDate)?this.endDate=i:this.endDate=null,this.requestUpdate();}},{key:"parseDate",value:function parseDate(t){var _t$split$map=t.split("/").map(Number),_t$split$map2=_slicedToArray(_t$split$map,3),i=_t$split$map2[0],s=_t$split$map2[1],e=_t$split$map2[2],n=new Date(e,s-1,i);return isNaN(n.getTime())?null:n;}},{key:"isValidDateInput",value:function isValidDateInput(t){return /^(0[1-9]|[12][0-9]|3[01])\/(0[1-9]|1[0-2])\/\d{4}$/.test(t);}},{key:"formatTime",value:function formatTime(t){if(!t)return"";return"".concat(String(t.getHours()).padStart(2,"0"),":").concat(String(t.getMinutes()).padStart(2,"0"),":").concat(String(t.getSeconds()).padStart(2,"0"));}},{key:"isValidTimeInput",value:function isValidTimeInput(t){return /^([0-1]?[0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9]$/.test(t);}},{key:"parseTime",value:function parseTime(t,i){if(!this.isValidTimeInput(t))return null;var _t$split$map3=t.split(":").map(Number),_t$split$map4=_slicedToArray(_t$split$map3,3),s=_t$split$map4[0],e=_t$split$map4[1],n=_t$split$map4[2],a=new Date(i.getTime());return a.setHours(s,e,n),a;}},{key:"handleStartTimeInput",value:function handleStartTimeInput(t){if(!this.startDate)return void(this.startDate=null);var i=this.parseTime(t.detail.value,this.startDate);i?this.startDate=i:this.startDate.setHours(0,0,0),this.requestUpdate();}},{key:"handleEndTimeInput",value:function handleEndTimeInput(t){if(!this.endDate)return void(this.endDate=null);var i=this.parseTime(t.detail.value,this.endDate);i?this.endDate=i:this.endDate.setHours(0,0,0),this.requestUpdate();}},{key:"render",value:function render(){this.getDaysArray(this.currentYear,this.currentMonth);var t=(this.currentMonth+1)%12,s=11===this.currentMonth?this.currentYear+1:this.currentYear;return this.getDaysArray(s,t),i(_templateObject3||(_templateObject3=_taggedTemplateLiteral(["\n\n <div class=\"base ","\">\n <div class=\"calendar-wrapper\" >\n <div class=\"calendar-container ","\">\n ","\n </div>\n <!-- "," -->\n\n </div>\n ","\n </div>\n "])),this.range?"base__range":"",this.range?"with-margin":"",this.renderMonth(this.currentYear,this.currentMonth,this.getDaysArray(this.currentYear,this.currentMonth)),this.range?i(_templateObject4||(_templateObject4=_taggedTemplateLiteral(["\n <div class=\"calendar-container\">\n ","\n </div>\n "])),this.renderMonth(this.currentYear,(this.currentMonth+1)%12,this.getDaysArray(this.currentYear,(this.currentMonth+1)%12))):"",this.range?i(_templateObject5||(_templateObject5=_taggedTemplateLiteral(["\n <div class=\"calender-input\">\n <span class=\"manual-input-label\">From </span>\n <div class=\"from\">\n <nile-input class=\"manual-input\" value=\"","\" placeholder=\"DD/MM/YYYY\" @nile-change=\"","\"></nile-input>\n <nile-input class=\"manual-input\" value=\"","\" placeholder=\"HH:MM:SS\" @nile-change=\"","\"> </nile-input>\n\n </div>\n<br>\n <span class=\"manual-input-label\">To </span>\n <div class=\"from\">\n <nile-input class=\"manual-input\" value=\"","\" placeholder=\"DD/MM/YYYY\" @nile-change=\"","\"></nile-input>\n <nile-input class=\"manual-input\" value=\"","\" placeholder=\"HH:MM:SS\" @nile-change=\"","\"> </nile-input>\n </div>\n <div class=\"button-contaner\">\n <nile-button class=\"apply-button\" ?disabled=\"","\" @click=\"","\"> Apply</nile-button>\n </div>\n\n\n </div>\n </div>\n "])),this.formatDate(this.startDate),this.handleStartDateInput,this.formatTime(this.startDate),this.handleStartTimeInput,this.formatDate(this.endDate),this.handleEndDateInput,this.formatTime(this.endDate),this.handleEndTimeInput,!this.startDate||!this.endDate,this.confimRange):"");}}],[{key:"styles",get:function get(){return[n];}},{key:"observedAttributes",get:function get(){return["value","range"];}}]);return r;}(h));t([s("nile-dropdown")],r.prototype,"dropdown",void 0),t([l({type:Boolean,reflect:!0})],r.prototype,"dropDownOpened",void 0),t([l({type:Object})],r.prototype,"value",void 0),t([l({type:Object})],r.prototype,"rangeValue",void 0),t([l({type:String,attribute:"value"})],r.prototype,"valueAttribute",void 0),t([l({type:String,attribute:"value"})],r.prototype,"formattedDate",void 0),t([l({type:Object})],r.prototype,"startDate",void 0),t([l({type:Object})],r.prototype,"endDate",void 0),t([l({type:Boolean})],r.prototype,"isSelectingStart",void 0),t([l({type:Boolean})],r.prototype,"range",void 0),t([a("value")],r.prototype,"valueChanged",null),_export("N",r=t([e("nile-calendar")],r));}};});
2
2
  //# sourceMappingURL=nile-calendar.cjs.js.map