@everymatrix/general-input 1.75.1 → 1.76.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/checkbox-group-input_13.cjs.entry.js +13 -4
- package/dist/cjs/general-input.cjs.js +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/components/general-input/general-input.js +21 -2
- package/dist/collection/components/password-input/password-input.js +28 -2
- package/dist/esm/checkbox-group-input_13.entry.js +13 -4
- package/dist/esm/general-input.js +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/general-input/checkbox-group-input_13.entry.js +27 -27
- package/dist/general-input/general-input.esm.js +1 -1
- package/dist/types/components/general-input/general-input.d.ts +4 -0
- package/dist/types/components/password-input/password-input.d.ts +4 -0
- package/dist/types/components.d.ts +16 -0
- package/package.json +1 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{r as t,c as e,h as i,g as s,H as o}from"./index-ed8fc8f4.js";const r={en:{dateError:"The selected date should be between {min} and {max}",dateError2:"The selected date is not within the accepted range",dateFormatError:"The selected date has a different format then the one required.",numberLengthError:"The number should be between {min} and {max}",lengthError:"The length should be between {minLength} and {maxLength}",requiredError:"This input is required.",invalidOriginalPasswordError:"Initial password field does not validate all criteria.",invalidPassword:"Password does not meet all criteria",passwordStrength:"Password strength",passwordStrengthWeak:"is not adequate",passwordStrengthStrong:"is adequate",SpecialCharactersNotAllowed:"Should not contain special characters",InvalidEmailFormat:"Invalid email format.",EmailNotMatching:"Emails not matching!",PasswordNotMatching:"Passwords not matching",MustIncludeNumber:"Password must include a number",MustContainCapital:"Password must include a capital letter",MustIncludePunctation:"Password must include punctuation",OnlyNumbers:"The input should contain only digits.",InvalidFieldSize:"The length must be exactly 11 digits.",InvalidDocumentNumber:"Only numerical characters are allowed.",twofaDescription:"<p> We have sent the verification code to <p> {destination}. </p> </p> <p> Please insert the PIN below. </p>",twofaResendMessage:"Didn't receive the verification code?",twofaResendButton:"Resend"},hu:{dateError:"A választott dátumnak {min} és {max} között kell lennie",dateError2:"A kiválasztott dátum nincs az elfogadott tartományon belül",dateFormatError:"A kiválasztott dátum formátuma eltér a szükségestől.",numberLengthError:"A számnak {min} és {max} között kell lennie",lengthError:"A hossznak {minLength} és {maxLength} között kell lennie",requiredError:"Ez a beviteli mező kötelező.",invalidOriginalPasswordError:"Initial password field does not validate all criteria.",invalidPassword:"A jelszó nem felel meg minden kritériumnak",passwordStrength:"Jelszó erőssége",passwordStrengthWeak:"nem megfelelő",passwordStrengthStrong:"megfelelő",SpecialCharactersNotAllowed:"Nem tartalmazhat speciális karaktereket",InvalidEmailFormat:"Érvénytelen e-mail formátum.",EmailNotMatching:"Az e-mailek nem egyeznek!",PasswordNotMatching:"A jelszavak nem egyeznek",MustIncludeNumber:"A jelszónak tartalmaznia kell egy számot",MustContainCapital:"A jelszónak tartalmaznia kell egy nagybetűt",MustIncludePunctation:"A jelszónak tartalmaznia kell írásjelet",OnlyNumbers:"Csak számjegyeket tartalmazhat.",InvalidFieldSize:"A hosszúságnak pontosan 11 számjegynek kell lennie.",InvalidDocumentNumber:"Csak számjegyek engedélyezettek.",twofaDescription:"<p> A megerősítő kódot elküldtük a következő címre: <p> {destination}. </p> </p> <p> Kérjük, írja be az alábbi PIN-kódot. </p>",twofaResendMessage:"Nem kapta meg a megerősítő kódot?",twofaResendButton:"Újraküldés"},hr:{dateError:"Odabrani datum treba biti između {min} i {max}",dateError2:"Odabrani datum nije unutar prihvaćenog raspona",dateFormatError:"Odabrani datum je u drugačijem formatu od potrebnog.",numberLengthError:"Broj bi trebao biti između {min} i {max}",lengthError:"Duljina bi trebala biti između {minLength} i {maxLength}",requiredError:"Ovaj unos je obavezan.",invalidOriginalPasswordError:"Lozinke se ne podudaraju",invalidPassword:"Lozinka ne zadovoljava sve kriterije",passwordStrength:"Lozinka",passwordStrengthWeak:"nije dovoljno jaka",passwordStrengthStrong:"je dovoljno jaka",SpecialCharactersNotAllowed:"Ne smije sadržavati posebne znakove",InvalidEmailFormat:"Nevažeći format e-maila",EmailNotMatching:"E-mailovi se ne podudaraju!",PasswordNotMatching:"Lozinke se ne podudaraju",MustIncludeNumber:"Lozinka mora sadržavati broj",MustContainCapital:"Lozinka mora sadržavati veliko slovo",MustIncludePunctation:"Lozinka mora sadržavati barem jedan znak",OnlyNumbers:"Smije sadržavati samo znamenke.",InvalidFieldSize:"Dužina mora biti točno 11 znamenki.",InvalidDocumentNumber:"Dopušteni su samo numerički znakovi.",twofaDescription:"<p> Poslali smo verifikacijski kod na: <p> {destination}. </p> </p> <p> Molimo unesite PIN ispod. </p>",twofaResendMessage:"Niste primili verifikacijski kod?",twofaResendButton:"Ponovno pošalji"},tr:{dateError:"Seçilen tarih {min} ve {max} arasında olmalıdır",dateError2:"Seçilen tarih kabul edilen aralıkta değil",dateFormatError:"Seçilen tarihin formatı, gereken formattan farklı.",numberLengthError:"Sayı {min} ve {max} arasında olmalıdır",lengthError:"Uzunluk {minLength} ve {maxLength} arasında olmalıdır",requiredError:"Bu alan zorunludur.",invalidOriginalPasswordError:"İlk şifre alanı tüm kriterleri karşılamıyor.",invalidPassword:"Şifre tüm kriterleri karşılamıyor",passwordStrength:"Şifre gücü",passwordStrengthWeak:"yetersiz",passwordStrengthStrong:"yeterli",SpecialCharactersNotAllowed:"Özel karakter içermemelidir",InvalidEmailFormat:"Geçersiz e-posta formatı.",EmailNotMatching:"E-postalar uyuşmuyor!",PasswordNotMatching:"Şifreler uyuşmuyor",MustIncludeNumber:"bir sayı içermelidir",MustContainCapital:"büyük harf içermelidir",MustIncludePunctation:"noktalama işareti içermelidir",OnlyNumbers:"Yalnızca rakamlar içermelidir.",InvalidFieldSize:"Uzunluk tam olarak 11 rakam olmalıdır.",InvalidDocumentNumber:"Sadece sayısal karakterlere izin verilir.",twofaDescription:"<p> Doğrulama kodunu şu adrese gönderdik: <p> {destination}. </p> </p> <p> Lütfen aşağıya PIN kodunu girin. </p>",twofaResendMessage:"Doğrulama kodunu almadınız mı?",twofaResendButton:"Yeniden gönder"},"pt-br":{dateError:"A data selecionada deve estar entre {min} e {max}",dateError2:"A data selecionada não está dentro de um intervalo válido",dateFormatError:"A data selecionada está em um formato diferente do exigido.",numberLengthError:"O número deve estar entre {min} e {max}",lengthError:"O comprimento deve estar entre {minLength} e {maxLength}",requiredError:"Este campo é obrigatório",invalidOriginalPasswordError:"O campo de senha inicial não faz parte dos critérios válidos",invalidPassword:"A senha não atende a todos os critérios",PasswordStrength:"Força da senha",PasswordStrengthWeak:"Não é adequado",PasswordStrengthStrong:"é apropriado",SpecialCharactersNotAllowed:"Não deve conter caracteres especiais",InvalidEmailFormat:"Formato de email inválido",EmailNotMatching:"E-mail não corresponde",PasswordNotMatching:"Senha não corresponde",MustIncludeNumber:"A senha deve incluir um número",MustContainCapital:"A senha deve incluir uma letra maiúscula",MustIncludePunctation:"A senha deve incluir um sinal de pontuação",OnlyNumbers:"Deve conter apenas dígitos.",InvalidFieldSize:"O comprimento deve ser exatamente 11 dígitos.",InvalidDocumentNumber:"Apenas caracteres numéricos são permitidos.",twofaDescription:"<p> Enviamos o código de verificação para: <p> {destination}. </p> </p> <p> Por favor, insira o PIN abaixo. </p>",twofaResendMessage:"Não recebeu o código de verificação?",twofaResendButton:"Reenviar"},"es-mx":{dateError:"La fecha seleccionada debe ser entre {min} y {max}",dateError2:"La fecha seleccionada no está dentro de un rango válido",dateFormatError:"La fecha seleccionada tiene un formato diferente al requerido.",numberLengthError:"El número debe ser entre {min} y {max}",lengthError:"La longitud deber ser entre {minLength} y {maxLength}",requiredError:"Este campo es requerido",invalidOriginalPasswordError:"El campo de contraseña inicial no es parte del criterio válido",invalidPassword:"La contraseña no cumple con todos los criterios",PasswordStrength:"La fortaleza de la contraseña",PasswordStrengthWeak:"no es adecuada",PasswordStrengthStrong:"es adecuada",SpecialCharactersNotAllowed:"No debe contener caracteres especiales",InvalidEmailFormat:"Formato inválido de correo",EmailNotMatching:"El correo electrónico no coincide",PasswordNotMatching:"La contraseña no coincide",MustIncludeNumber:"La contraseña debe incluir un número",MustContainCapital:"La contraseña debe incluir una letra mayúscula",MustIncludePunctation:"La contraseña debe incluir un signo de puntuación",OnlyNumbers:"Debe contener solo dígitos.",InvalidFieldSize:"La longitud debe ser exactamente de 11 dígitos.",InvalidDocumentNumber:"Solo se permiten caracteres numéricos.",twofaDescription:"<p> Hemos enviado el código de verificación a: <p> {destination}. </p> </p> <p> Por favor, ingrese el PIN a continuación. </p>",twofaResendMessage:"¿No recibiste el código de verificación?",twofaResendButton:"Reenviar"}},n=(t,e,i)=>{let s=r[void 0!==e?e:"en"][t];if(void 0!==i)for(const[t,e]of Object.entries(i.values)){const i=new RegExp(`{${t}}`,"g");s=s.replace(i,e)}return s},a="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTIiIGhlaWdodD0iMTIiIHZpZXdCb3g9IjAgMCAxMiAxMiIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPGNpcmNsZSBjeD0iNiIgY3k9IjYiIHI9IjUuNSIgc3Ryb2tlPSIjOTc5Nzk3Ii8+CjxyZWN0IHg9IjUiIHk9IjUiIHdpZHRoPSIyIiBoZWlnaHQ9IjUiIGZpbGw9IiM5Nzk3OTciLz4KPGNpcmNsZSBjeD0iNiIgY3k9IjMiIHI9IjEiIGZpbGw9IiM5Nzk3OTciLz4KPC9zdmc+Cg==",l=class{constructor(i){t(this,i),this.sendValidityState=e(this,"sendValidityState",7),this.sendInputValue=e(this,"sendInputValue",7),this.value=null,this.setClientStyling=()=>{let t=document.createElement("style");t.innerHTML=this.clientStyling,this.stylingContainer.prepend(t)},this.name=void 0,this.displayName=void 0,this.defaultValue="",this.autofilled=void 0,this.tooltip=void 0,this.options=void 0,this.validation=void 0,this.language=void 0,this.emitValue=void 0,this.clientStyling="",this.errorMessage=void 0,this.isValid=void 0,this.limitStylingAppends=!1,this.showTooltip=!1,this.selectedValues=[],this.showCheckboxes=!1}handleStylingChange(t,e){t!==e&&this.setClientStyling()}validityChanged(){this.validityStateHandler({valid:this.isValid,name:this.name}),1==this.emitValue&&this.valueHandler({name:this.name,value:this.value,type:"checkboxgroup"})}setValue(){this.value=this.options.reduce(((t,e)=>(t[e.name]=this.selectedValues.includes(e.name),t)),{}),this.emitValueHandler(!0)}validityStateHandler(t){this.sendValidityState.emit(t)}emitValueHandler(t){1==t&&this.isValid&&this.valueHandler({name:this.name,value:this.value,type:"checkboxgroup"})}valueHandler(t){this.sendInputValue.emit(t)}handleClickOutside(t){t.composedPath()[0]!==this.tooltipIconReference&&t.composedPath()[0]!==this.tooltipReference&&(this.showTooltip=!1)}componentDidRender(){!this.limitStylingAppends&&this.stylingContainer&&(this.clientStyling&&this.setClientStyling(),this.limitStylingAppends=!0)}componentDidLoad(){this.inputReference=this.element.shadowRoot.querySelector("input"),this.isValid=this.setValidity(),this.defaultValue&&(this.showCheckboxes=!0,this.selectedValues=this.options.map((t=>t.name)),this.value=this.defaultValue,this.valueHandler({name:this.name,value:this.value}))}setValidity(){return this.inputReference.validity.valid}setErrorMessage(){if(this.inputReference.validity.valueMissing)return n("requiredError",this.language)}renderTooltip(){return this.showTooltip?i("div",{class:"checkboxgroup__tooltip "+(this.showTooltip?"visible":""),ref:t=>this.tooltipReference=t,innerHTML:this.tooltip}):null}handleParentCheckbox(t){const e=t.target.checked;this.showCheckboxes=e,this.selectedValues=e?this.options.map((t=>t.name)):[]}renderLabel(){return i("label",{class:"checkbox__label",htmlFor:`${this.name}__input`,slot:"label"},i("div",{class:"checkbox__label-text",innerHTML:`${this.displayName} ${this.validation.mandatory?"*":""}`}))}render(){return i("div",{key:"2eab716c27576d42a67d791b546022d58e89e21d",class:`checkboxgroup__wrapper ${this.name}__input`,ref:t=>this.stylingContainer=t},i("div",{key:"9e246685583dd06a156d6b11308b2cb355d37d01",class:"checkboxgroup__wrapper--flex"},i("vaadin-checkbox",{key:"ba6a64bdd1d1141407ed65213684d3b4d643effc",class:"checkbox__input",checked:this.selectedValues.length===this.options.length||"true"===this.defaultValue,indeterminate:this.selectedValues.length>0&&this.selectedValues.length<this.options.length,onChange:t=>this.handleParentCheckbox(t)},this.renderLabel()),this.tooltip&&i("img",{key:"2c23ca2dfe4213d9287958b5e6f09f76e9e3b031",class:"checkboxgroup__tooltip-icon",src:a,alt:"",ref:t=>this.tooltipIconReference=t,onClick:()=>this.showTooltip=!this.showTooltip}),this.renderTooltip()),i("small",{key:"3180a35a47e4b57d8634da2f516d0c5c71ee0e9f",class:"checkboxgroup__error-message"},this.errorMessage),this.showCheckboxes&&i("vaadin-checkbox-group",{key:"b28fee432aa7bffe6aedf708f1ce9603a52833de",theme:"vertical",value:this.selectedValues,"on-value-changed":t=>{this.selectedValues=t.detail.value}},this.options.map((t=>i("vaadin-checkbox",{class:"checkbox__input",name:t.name,value:t.name,label:t.displayName})))))}get element(){return s(this)}static get watchers(){return{clientStyling:["handleStylingChange"],isValid:["validityChanged"],selectedValues:["setValue"],emitValue:["emitValueHandler"]}}};l.style='*,*::before,*::after{padding:0;margin:0;box-sizing:border-box}vaadin-checkbox-group{margin-top:5px;margin-left:40px}.checkboxgroup{font-family:"Roboto";font-style:normal;font-size:15px}.checkboxgroup__wrapper{position:relative}.checkboxgroup__wrapper--flex{display:flex;gap:5px;align-content:flex-start}.checkboxgroup__wrapper--relative{position:relative;display:inline}.checkboxgroup__input{vertical-align:baseline}.checkboxgroup__input[indeterminate]::part(checkbox)::after,.checkboxgroup__input[indeterminate]::part(checkbox),.checkboxgroup__input[checked]::part(checkbox){background-color:var(--emw--login-color-primary, var(--emw--color-primary, #22B04E))}.checkboxgroup__label{font-style:inherit;font-family:inherit;font-weight:400;font-size:16px;color:var(--emw--registration-typography, var(--emw--color-black, #000000));line-height:1.5;padding-left:10px;vertical-align:baseline}.checkboxgroup__label-text{font-size:16px}.checkboxgroup__label a{color:var(--emw--login-color-primary, var(--emw--color-primary, #22B04E))}.checkboxgroup__error-message{position:absolute;top:calc(100% + 5px);left:0;color:var(--emw--color-error, var(--emw--color-red, #ed0909))}.checkboxgroup__tooltip-icon{width:16px;height:auto}.checkboxgroup__tooltip{position:absolute;top:0;right:0;background-color:var(--emw--color-white, #FFFFFF);border:1px solid var(--emw--color-gray-100, #E6E6E6);color:var(--emw--registration-typography, var(--emw--color-black, #000000));padding:10px;border-radius:5px;opacity:0;transition:opacity 0.3s ease-in-out;z-index:10}.checkboxgroup__tooltip.visible{opacity:1}.checkbox__input::part(checkbox){background-color:var(--emw--color-white, #FFFFFF);transform:scale(0.8, 0.8);border-radius:var(--emw--border-radius-small, 2px);box-shadow:0 0px 0px 2px var(--emw--color-gray, #7a7a7a)}.checkbox__input[indeterminate]::part(checkbox),.checkbox__input[checked]::part(checkbox){background-color:var(--emw--login-color-primary, var(--emw--color-primary, #22B04E));box-shadow:none}';const h=class{constructor(i){t(this,i),this.sendValidityState=e(this,"sendValidityState",7),this.sendInputValue=e(this,"sendInputValue",7),this.value="",this.setClientStyling=()=>{let t=document.createElement("style");t.innerHTML=this.clientStyling,this.stylingContainer.prepend(t)},this.name=void 0,this.displayName=void 0,this.defaultValue="",this.autofilled=void 0,this.tooltip=void 0,this.validation=void 0,this.language=void 0,this.emitValue=void 0,this.clientStyling="",this.errorMessage=void 0,this.isValid=void 0,this.limitStylingAppends=!1,this.showTooltip=!1}handleStylingChange(t,e){t!==e&&this.setClientStyling()}validityChanged(){this.validityStateHandler({valid:this.isValid,name:this.name}),1==this.emitValue&&this.valueHandler({name:this.name,value:this.value})}validityStateHandler(t){this.sendValidityState.emit(t)}emitValueHandler(t){1==t&&this.isValid&&this.valueHandler({name:this.name,value:this.value})}valueHandler(t){this.sendInputValue.emit(t)}handleClickOutside(t){t.composedPath()[0]!==this.tooltipIconReference&&t.composedPath()[0]!==this.tooltipReference&&(this.showTooltip=!1)}componentDidRender(){!this.limitStylingAppends&&this.stylingContainer&&(this.clientStyling&&this.setClientStyling(),this.limitStylingAppends=!0)}componentDidLoad(){this.inputReference=this.vaadinCheckbox.querySelector("input"),this.defaultValue&&(this.value=this.defaultValue,this.valueHandler({name:this.name,value:this.value}))}handleCheckbox(t){this.value=t.target.checked.toString(),this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage(),this.emitValueHandler(!0)}setValidity(){return this.inputReference.validity.valid}setErrorMessage(){if(this.inputReference.validity.valueMissing)return n("requiredError",this.language)}renderLabel(){return i("label",{class:"checkbox__label",htmlFor:`${this.name}__input`,slot:"label"},i("div",{class:"checkbox__label-text",innerHTML:`${this.displayName} ${this.validation.mandatory?"*":""}`}))}renderTooltip(){return this.showTooltip?i("div",{class:"checkbox__tooltip "+(this.showTooltip?"visible":""),ref:t=>this.tooltipReference=t,innerHTML:this.tooltip}):null}render(){return i("div",{key:"e9dfb4e2a6b99d740eaa7d94d1ff3aea9587bcc9",class:`checkbox__wrapper ${this.name}__input`,ref:t=>this.stylingContainer=t},i("vaadin-checkbox",{key:"cc2a8d1c131bd04febf221538f01d7334169d92a",class:"checkbox__input",required:this.validation.mandatory,checked:"true"===this.defaultValue,onChange:t=>this.handleCheckbox(t),"error-message":!this.isValid&&this.errorMessage,ref:t=>this.vaadinCheckbox=t},this.renderLabel()),this.tooltip&&i("img",{key:"a94be7eefe15593f0cfa90d89bed1f536bd51103",class:"checkboxgroup__tooltip-icon",src:a,alt:"",ref:t=>this.tooltipIconReference=t,onClick:()=>this.showTooltip=!this.showTooltip}),this.renderTooltip())}static get watchers(){return{clientStyling:["handleStylingChange"],isValid:["validityChanged"],emitValue:["emitValueHandler"]}}};function d(t){return d="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},d(t)}function c(t,e){if(e.length<t)throw new TypeError(t+" argument"+(t>1?"s":"")+" required, but only "+e.length+" present")}function u(t){c(1,arguments);var e=Object.prototype.toString.call(t);return t instanceof Date||"object"===d(t)&&"[object Date]"===e?new Date(t.getTime()):"number"==typeof t||"[object Number]"===e?new Date(t):("string"!=typeof t&&"[object String]"!==e||"undefined"==typeof console||(console.warn("Starting with v2.0.0-beta.1 date-fns doesn't accept strings as date arguments. Please use `parseISO` to parse strings. See: https://github.com/date-fns/date-fns/blob/master/docs/upgradeGuide.md#string-arguments"),console.warn((new Error).stack)),new Date(NaN))}function p(t){if(c(1,arguments),!function(t){return c(1,arguments),t instanceof Date||"object"===d(t)&&"[object Date]"===Object.prototype.toString.call(t)}(t)&&"number"!=typeof t)return!1;var e=u(t);return!isNaN(Number(e))}function m(t){if(null===t||!0===t||!1===t)return NaN;var e=Number(t);return isNaN(e)?e:e<0?Math.ceil(e):Math.floor(e)}function v(t,e){return c(2,arguments),function(t,e){c(2,arguments);var i=u(t).getTime(),s=m(e);return new Date(i+s)}(t,-m(e))}function f(t){c(1,arguments);var e=u(t),i=e.getUTCDay(),s=(i<1?7:0)+i-1;return e.setUTCDate(e.getUTCDate()-s),e.setUTCHours(0,0,0,0),e}function b(t){c(1,arguments);var e=u(t),i=e.getUTCFullYear(),s=new Date(0);s.setUTCFullYear(i+1,0,4),s.setUTCHours(0,0,0,0);var o=f(s),r=new Date(0);r.setUTCFullYear(i,0,4),r.setUTCHours(0,0,0,0);var n=f(r);return e.getTime()>=o.getTime()?i+1:e.getTime()>=n.getTime()?i:i-1}h.style='*,*::before,*::after{padding:0;margin:0;box-sizing:border-box}.checkbox{font-family:"Roboto";font-style:normal;font-size:15px}.checkbox__wrapper{display:flex;gap:10px;position:relative;align-items:baseline}.checkbox__wrapper--relative{position:relative}.checkbox__input[indeterminate]::part(checkbox)::after,.checkbox__input[indeterminate]::part(checkbox),.checkbox__input[checked]::part(checkbox){background-color:var(--emw--login-color-primary, var(--emw--color-primary, #22B04E))}.checkbox__label{font-style:inherit;font-family:inherit;font-weight:400;font-size:16px;color:var(--emw--registration-typography, var(--emw--color-black, #000000));line-height:1.5;padding:0px;vertical-align:baseline}.checkbox__label a{color:var(--emw--login-color-primary, var(--emw--color-primary, #22B04E))}.checkbox__error-message{position:absolute;top:calc(100% + 5px);left:0;color:var(--emw--color-error, var(--emw--color-red, #ed0909))}.checkbox__tooltip-icon{width:16px;height:auto}.checkbox__tooltip{position:absolute;top:0;right:20px;background-color:var(--emw--color-white, #FFFFFF);border:1px solid var(--emw--color-gray-100, #E6E6E6);color:var(--emw--registration-typography, var(--emw--color-black, #000000));padding:10px;border-radius:5px;opacity:0;transition:opacity 0.3s ease-in-out;z-index:10}.checkbox__tooltip.visible{opacity:1}.checkbox__input::part(checkbox){background-color:var(--emw--color-white, #FFFFFF);transform:scale(0.8, 0.8);border-radius:var(--emw--border-radius-small, 2px);box-shadow:0 0px 0px 2px var(--emw--color-gray, #7a7a7a)}.checkbox__input::part(required-indicator)::after{content:"*"}.checkbox__input[indeterminate]::part(checkbox),.checkbox__input[checked]::part(checkbox){background-color:var(--emw--login-color-primary, var(--emw--color-primary, #22B04E));box-shadow:none}';function g(t){c(1,arguments);var e=u(t),i=f(e).getTime()-function(t){c(1,arguments);var e=b(t),i=new Date(0);return i.setUTCFullYear(e,0,4),i.setUTCHours(0,0,0,0),f(i)}(e).getTime();return Math.round(i/6048e5)+1}var y={};function w(){return y}function _(t,e){var i,s,o,r,n,a,l,h;c(1,arguments);var d=w(),p=m(null!==(i=null!==(s=null!==(o=null!==(r=null==e?void 0:e.weekStartsOn)&&void 0!==r?r:null==e||null===(n=e.locale)||void 0===n||null===(a=n.options)||void 0===a?void 0:a.weekStartsOn)&&void 0!==o?o:d.weekStartsOn)&&void 0!==s?s:null===(l=d.locale)||void 0===l||null===(h=l.options)||void 0===h?void 0:h.weekStartsOn)&&void 0!==i?i:0);if(!(p>=0&&p<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var v=u(t),f=v.getUTCDay(),b=(f<p?7:0)+f-p;return v.setUTCDate(v.getUTCDate()-b),v.setUTCHours(0,0,0,0),v}function x(t,e){var i,s,o,r,n,a,l,h;c(1,arguments);var d=u(t),p=d.getUTCFullYear(),v=w(),f=m(null!==(i=null!==(s=null!==(o=null!==(r=null==e?void 0:e.firstWeekContainsDate)&&void 0!==r?r:null==e||null===(n=e.locale)||void 0===n||null===(a=n.options)||void 0===a?void 0:a.firstWeekContainsDate)&&void 0!==o?o:v.firstWeekContainsDate)&&void 0!==s?s:null===(l=v.locale)||void 0===l||null===(h=l.options)||void 0===h?void 0:h.firstWeekContainsDate)&&void 0!==i?i:1);if(!(f>=1&&f<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var b=new Date(0);b.setUTCFullYear(p+1,0,f),b.setUTCHours(0,0,0,0);var g=_(b,e),y=new Date(0);y.setUTCFullYear(p,0,f),y.setUTCHours(0,0,0,0);var x=_(y,e);return d.getTime()>=g.getTime()?p+1:d.getTime()>=x.getTime()?p:p-1}function k(t,e){c(1,arguments);var i=u(t),s=_(i,e).getTime()-function(t,e){var i,s,o,r,n,a,l,h;c(1,arguments);var d=w(),u=m(null!==(i=null!==(s=null!==(o=null!==(r=null==e?void 0:e.firstWeekContainsDate)&&void 0!==r?r:null==e||null===(n=e.locale)||void 0===n||null===(a=n.options)||void 0===a?void 0:a.firstWeekContainsDate)&&void 0!==o?o:d.firstWeekContainsDate)&&void 0!==s?s:null===(l=d.locale)||void 0===l||null===(h=l.options)||void 0===h?void 0:h.firstWeekContainsDate)&&void 0!==i?i:1),p=x(t,e),v=new Date(0);return v.setUTCFullYear(p,0,u),v.setUTCHours(0,0,0,0),_(v,e)}(i,e).getTime();return Math.round(s/6048e5)+1}function C(t,e){for(var i=t<0?"-":"",s=Math.abs(t).toString();s.length<e;)s="0"+s;return i+s}const A=function(t,e){var i=t.getUTCFullYear(),s=i>0?i:1-i;return C("yy"===e?s%100:s,e.length)},S=function(t,e){var i=t.getUTCMonth();return"M"===e?String(i+1):C(i+1,2)},z=function(t,e){return C(t.getUTCDate(),e.length)},I=function(t,e){return C(t.getUTCHours()%12||12,e.length)},E=function(t,e){return C(t.getUTCHours(),e.length)},T=function(t,e){return C(t.getUTCMinutes(),e.length)},M=function(t,e){return C(t.getUTCSeconds(),e.length)},D=function(t,e){var i=e.length,s=t.getUTCMilliseconds();return C(Math.floor(s*Math.pow(10,i-3)),e.length)};function O(t,e){var i=t>0?"-":"+",s=Math.abs(t),o=Math.floor(s/60),r=s%60;if(0===r)return i+String(o);var n=e||"";return i+String(o)+n+C(r,2)}function P(t,e){return t%60==0?(t>0?"-":"+")+C(Math.abs(t)/60,2):F(t,e)}function F(t,e){var i=e||"",s=t>0?"-":"+",o=Math.abs(t);return s+C(Math.floor(o/60),2)+i+C(o%60,2)}const N={G:function(t,e,i){var s=t.getUTCFullYear()>0?1:0;switch(e){case"G":case"GG":case"GGG":return i.era(s,{width:"abbreviated"});case"GGGGG":return i.era(s,{width:"narrow"});default:return i.era(s,{width:"wide"})}},y:function(t,e,i){if("yo"===e){var s=t.getUTCFullYear();return i.ordinalNumber(s>0?s:1-s,{unit:"year"})}return A(t,e)},Y:function(t,e,i,s){var o=x(t,s),r=o>0?o:1-o;return"YY"===e?C(r%100,2):"Yo"===e?i.ordinalNumber(r,{unit:"year"}):C(r,e.length)},R:function(t,e){return C(b(t),e.length)},u:function(t,e){return C(t.getUTCFullYear(),e.length)},Q:function(t,e,i){var s=Math.ceil((t.getUTCMonth()+1)/3);switch(e){case"Q":return String(s);case"QQ":return C(s,2);case"Qo":return i.ordinalNumber(s,{unit:"quarter"});case"QQQ":return i.quarter(s,{width:"abbreviated",context:"formatting"});case"QQQQQ":return i.quarter(s,{width:"narrow",context:"formatting"});default:return i.quarter(s,{width:"wide",context:"formatting"})}},q:function(t,e,i){var s=Math.ceil((t.getUTCMonth()+1)/3);switch(e){case"q":return String(s);case"qq":return C(s,2);case"qo":return i.ordinalNumber(s,{unit:"quarter"});case"qqq":return i.quarter(s,{width:"abbreviated",context:"standalone"});case"qqqqq":return i.quarter(s,{width:"narrow",context:"standalone"});default:return i.quarter(s,{width:"wide",context:"standalone"})}},M:function(t,e,i){var s=t.getUTCMonth();switch(e){case"M":case"MM":return S(t,e);case"Mo":return i.ordinalNumber(s+1,{unit:"month"});case"MMM":return i.month(s,{width:"abbreviated",context:"formatting"});case"MMMMM":return i.month(s,{width:"narrow",context:"formatting"});default:return i.month(s,{width:"wide",context:"formatting"})}},L:function(t,e,i){var s=t.getUTCMonth();switch(e){case"L":return String(s+1);case"LL":return C(s+1,2);case"Lo":return i.ordinalNumber(s+1,{unit:"month"});case"LLL":return i.month(s,{width:"abbreviated",context:"standalone"});case"LLLLL":return i.month(s,{width:"narrow",context:"standalone"});default:return i.month(s,{width:"wide",context:"standalone"})}},w:function(t,e,i,s){var o=k(t,s);return"wo"===e?i.ordinalNumber(o,{unit:"week"}):C(o,e.length)},I:function(t,e,i){var s=g(t);return"Io"===e?i.ordinalNumber(s,{unit:"week"}):C(s,e.length)},d:function(t,e,i){return"do"===e?i.ordinalNumber(t.getUTCDate(),{unit:"date"}):z(t,e)},D:function(t,e,i){var s=function(t){c(1,arguments);var e=u(t),i=e.getTime();e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0);var s=e.getTime();return Math.floor((i-s)/864e5)+1}(t);return"Do"===e?i.ordinalNumber(s,{unit:"dayOfYear"}):C(s,e.length)},E:function(t,e,i){var s=t.getUTCDay();switch(e){case"E":case"EE":case"EEE":return i.day(s,{width:"abbreviated",context:"formatting"});case"EEEEE":return i.day(s,{width:"narrow",context:"formatting"});case"EEEEEE":return i.day(s,{width:"short",context:"formatting"});default:return i.day(s,{width:"wide",context:"formatting"})}},e:function(t,e,i,s){var o=t.getUTCDay(),r=(o-s.weekStartsOn+8)%7||7;switch(e){case"e":return String(r);case"ee":return C(r,2);case"eo":return i.ordinalNumber(r,{unit:"day"});case"eee":return i.day(o,{width:"abbreviated",context:"formatting"});case"eeeee":return i.day(o,{width:"narrow",context:"formatting"});case"eeeeee":return i.day(o,{width:"short",context:"formatting"});default:return i.day(o,{width:"wide",context:"formatting"})}},c:function(t,e,i,s){var o=t.getUTCDay(),r=(o-s.weekStartsOn+8)%7||7;switch(e){case"c":return String(r);case"cc":return C(r,e.length);case"co":return i.ordinalNumber(r,{unit:"day"});case"ccc":return i.day(o,{width:"abbreviated",context:"standalone"});case"ccccc":return i.day(o,{width:"narrow",context:"standalone"});case"cccccc":return i.day(o,{width:"short",context:"standalone"});default:return i.day(o,{width:"wide",context:"standalone"})}},i:function(t,e,i){var s=t.getUTCDay(),o=0===s?7:s;switch(e){case"i":return String(o);case"ii":return C(o,e.length);case"io":return i.ordinalNumber(o,{unit:"day"});case"iii":return i.day(s,{width:"abbreviated",context:"formatting"});case"iiiii":return i.day(s,{width:"narrow",context:"formatting"});case"iiiiii":return i.day(s,{width:"short",context:"formatting"});default:return i.day(s,{width:"wide",context:"formatting"})}},a:function(t,e,i){var s=t.getUTCHours()/12>=1?"pm":"am";switch(e){case"a":case"aa":return i.dayPeriod(s,{width:"abbreviated",context:"formatting"});case"aaa":return i.dayPeriod(s,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return i.dayPeriod(s,{width:"narrow",context:"formatting"});default:return i.dayPeriod(s,{width:"wide",context:"formatting"})}},b:function(t,e,i){var s,o=t.getUTCHours();switch(s=12===o?"noon":0===o?"midnight":o/12>=1?"pm":"am",e){case"b":case"bb":return i.dayPeriod(s,{width:"abbreviated",context:"formatting"});case"bbb":return i.dayPeriod(s,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return i.dayPeriod(s,{width:"narrow",context:"formatting"});default:return i.dayPeriod(s,{width:"wide",context:"formatting"})}},B:function(t,e,i){var s,o=t.getUTCHours();switch(s=o>=17?"evening":o>=12?"afternoon":o>=4?"morning":"night",e){case"B":case"BB":case"BBB":return i.dayPeriod(s,{width:"abbreviated",context:"formatting"});case"BBBBB":return i.dayPeriod(s,{width:"narrow",context:"formatting"});default:return i.dayPeriod(s,{width:"wide",context:"formatting"})}},h:function(t,e,i){if("ho"===e){var s=t.getUTCHours()%12;return 0===s&&(s=12),i.ordinalNumber(s,{unit:"hour"})}return I(t,e)},H:function(t,e,i){return"Ho"===e?i.ordinalNumber(t.getUTCHours(),{unit:"hour"}):E(t,e)},K:function(t,e,i){var s=t.getUTCHours()%12;return"Ko"===e?i.ordinalNumber(s,{unit:"hour"}):C(s,e.length)},k:function(t,e,i){var s=t.getUTCHours();return 0===s&&(s=24),"ko"===e?i.ordinalNumber(s,{unit:"hour"}):C(s,e.length)},m:function(t,e,i){return"mo"===e?i.ordinalNumber(t.getUTCMinutes(),{unit:"minute"}):T(t,e)},s:function(t,e,i){return"so"===e?i.ordinalNumber(t.getUTCSeconds(),{unit:"second"}):M(t,e)},S:function(t,e){return D(t,e)},X:function(t,e,i,s){var o=(s._originalDate||t).getTimezoneOffset();if(0===o)return"Z";switch(e){case"X":return P(o);case"XXXX":case"XX":return F(o);default:return F(o,":")}},x:function(t,e,i,s){var o=(s._originalDate||t).getTimezoneOffset();switch(e){case"x":return P(o);case"xxxx":case"xx":return F(o);default:return F(o,":")}},O:function(t,e,i,s){var o=(s._originalDate||t).getTimezoneOffset();switch(e){case"O":case"OO":case"OOO":return"GMT"+O(o,":");default:return"GMT"+F(o,":")}},z:function(t,e,i,s){var o=(s._originalDate||t).getTimezoneOffset();switch(e){case"z":case"zz":case"zzz":return"GMT"+O(o,":");default:return"GMT"+F(o,":")}},t:function(t,e,i,s){return C(Math.floor((s._originalDate||t).getTime()/1e3),e.length)},T:function(t,e,i,s){return C((s._originalDate||t).getTime(),e.length)}};var B=function(t,e){switch(t){case"P":return e.date({width:"short"});case"PP":return e.date({width:"medium"});case"PPP":return e.date({width:"long"});default:return e.date({width:"full"})}},j=function(t,e){switch(t){case"p":return e.time({width:"short"});case"pp":return e.time({width:"medium"});case"ppp":return e.time({width:"long"});default:return e.time({width:"full"})}},V={p:j,P:function(t,e){var i,s=t.match(/(P+)(p+)?/)||[],o=s[1],r=s[2];if(!r)return B(t,e);switch(o){case"P":i=e.dateTime({width:"short"});break;case"PP":i=e.dateTime({width:"medium"});break;case"PPP":i=e.dateTime({width:"long"});break;default:i=e.dateTime({width:"full"})}return i.replace("{{date}}",B(o,e)).replace("{{time}}",j(r,e))}};const L=V;function R(t){var e=new Date(Date.UTC(t.getFullYear(),t.getMonth(),t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()));return e.setUTCFullYear(t.getFullYear()),t.getTime()-e.getTime()}var q=["D","DD"],$=["YY","YYYY"];function H(t){return-1!==q.indexOf(t)}function W(t){return-1!==$.indexOf(t)}function G(t,e,i){if("YYYY"===t)throw new RangeError("Use `yyyy` instead of `YYYY` (in `".concat(e,"`) for formatting years to the input `").concat(i,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if("YY"===t)throw new RangeError("Use `yy` instead of `YY` (in `".concat(e,"`) for formatting years to the input `").concat(i,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if("D"===t)throw new RangeError("Use `d` instead of `D` (in `".concat(e,"`) for formatting days of the month to the input `").concat(i,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if("DD"===t)throw new RangeError("Use `dd` instead of `DD` (in `".concat(e,"`) for formatting days of the month to the input `").concat(i,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"))}var Y={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}};function U(t){return function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},i=e.width?String(e.width):t.defaultWidth;return t.formats[i]||t.formats[t.defaultWidth]}}var K,Q={date:U({formats:{full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},defaultWidth:"full"}),time:U({formats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},defaultWidth:"full"}),dateTime:U({formats:{full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},defaultWidth:"full"})},J={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"};function X(t){return function(e,i){var s;if("formatting"===(null!=i&&i.context?String(i.context):"standalone")&&t.formattingValues){var o=t.defaultFormattingWidth||t.defaultWidth,r=null!=i&&i.width?String(i.width):o;s=t.formattingValues[r]||t.formattingValues[o]}else{var n=t.defaultWidth,a=null!=i&&i.width?String(i.width):t.defaultWidth;s=t.values[a]||t.values[n]}return s[t.argumentCallback?t.argumentCallback(e):e]}}function Z(t){return function(e){var i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},s=i.width,o=e.match(s&&t.matchPatterns[s]||t.matchPatterns[t.defaultMatchWidth]);if(!o)return null;var r,n=o[0],a=s&&t.parsePatterns[s]||t.parsePatterns[t.defaultParseWidth],l=Array.isArray(a)?function(t){for(var e=0;e<t.length;e++)if(t[e].test(n))return e}(a):function(t){for(var e in t)if(t.hasOwnProperty(e)&&t[e].test(n))return e}(a);return r=t.valueCallback?t.valueCallback(l):l,{value:r=i.valueCallback?i.valueCallback(r):r,rest:e.slice(n.length)}}}const tt={code:"en-US",formatDistance:function(t,e,i){var s,o=Y[t];return s="string"==typeof o?o:1===e?o.one:o.other.replace("{{count}}",e.toString()),null!=i&&i.addSuffix?i.comparison&&i.comparison>0?"in "+s:s+" ago":s},formatLong:Q,formatRelative:function(t){return J[t]},localize:{ordinalNumber:function(t){var e=Number(t),i=e%100;if(i>20||i<10)switch(i%10){case 1:return e+"st";case 2:return e+"nd";case 3:return e+"rd"}return e+"th"},era:X({values:{narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},defaultWidth:"wide"}),quarter:X({values:{narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},defaultWidth:"wide",argumentCallback:function(t){return t-1}}),month:X({values:{narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},defaultWidth:"wide"}),day:X({values:{narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},defaultWidth:"wide"}),dayPeriod:X({values:{narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},defaultWidth:"wide",formattingValues:{narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},defaultFormattingWidth:"wide"})},match:{ordinalNumber:(K={matchPattern:/^(\d+)(th|st|nd|rd)?/i,parsePattern:/\d+/i,valueCallback:function(t){return parseInt(t,10)}},function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=t.match(K.matchPattern);if(!i)return null;var s=i[0],o=t.match(K.parsePattern);if(!o)return null;var r=K.valueCallback?K.valueCallback(o[0]):o[0];return{value:r=e.valueCallback?e.valueCallback(r):r,rest:t.slice(s.length)}}),era:Z({matchPatterns:{narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},defaultMatchWidth:"wide",parsePatterns:{any:[/^b/i,/^(a|c)/i]},defaultParseWidth:"any"}),quarter:Z({matchPatterns:{narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},defaultMatchWidth:"wide",parsePatterns:{any:[/1/i,/2/i,/3/i,/4/i]},defaultParseWidth:"any",valueCallback:function(t){return t+1}}),month:Z({matchPatterns:{narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},defaultParseWidth:"any"}),day:Z({matchPatterns:{narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},defaultParseWidth:"any"}),dayPeriod:Z({matchPatterns:{narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},defaultMatchWidth:"any",parsePatterns:{any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},defaultParseWidth:"any"})},options:{weekStartsOn:0,firstWeekContainsDate:1}};var et=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,it=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,st=/^'([^]*?)'?$/,ot=/''/g,rt=/[a-zA-Z]/;function nt(t,e,i){var s,o,r,n,a,l,h,d,f,b,g,y,_,x,k,C,A,S;c(2,arguments);var z=String(e),I=w(),E=null!==(s=null!==(o=null==i?void 0:i.locale)&&void 0!==o?o:I.locale)&&void 0!==s?s:tt,T=m(null!==(r=null!==(n=null!==(a=null!==(l=null==i?void 0:i.firstWeekContainsDate)&&void 0!==l?l:null==i||null===(h=i.locale)||void 0===h||null===(d=h.options)||void 0===d?void 0:d.firstWeekContainsDate)&&void 0!==a?a:I.firstWeekContainsDate)&&void 0!==n?n:null===(f=I.locale)||void 0===f||null===(b=f.options)||void 0===b?void 0:b.firstWeekContainsDate)&&void 0!==r?r:1);if(!(T>=1&&T<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var M=m(null!==(g=null!==(y=null!==(_=null!==(x=null==i?void 0:i.weekStartsOn)&&void 0!==x?x:null==i||null===(k=i.locale)||void 0===k||null===(C=k.options)||void 0===C?void 0:C.weekStartsOn)&&void 0!==_?_:I.weekStartsOn)&&void 0!==y?y:null===(A=I.locale)||void 0===A||null===(S=A.options)||void 0===S?void 0:S.weekStartsOn)&&void 0!==g?g:0);if(!(M>=0&&M<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(!E.localize)throw new RangeError("locale must contain localize property");if(!E.formatLong)throw new RangeError("locale must contain formatLong property");var D=u(t);if(!p(D))throw new RangeError("Invalid time value");var O=v(D,R(D)),P={firstWeekContainsDate:T,weekStartsOn:M,locale:E,_originalDate:D};return z.match(it).map((function(t){var e=t[0];return"p"===e||"P"===e?(0,L[e])(t,E.formatLong):t})).join("").match(et).map((function(s){if("''"===s)return"'";var o,r,n=s[0];if("'"===n)return(r=(o=s).match(st))?r[1].replace(ot,"'"):o;var a=N[n];if(a)return null!=i&&i.useAdditionalWeekYearTokens||!W(s)||G(s,e,String(t)),null!=i&&i.useAdditionalDayOfYearTokens||!H(s)||G(s,e,String(t)),a(O,s,E.localize,P);if(n.match(rt))throw new RangeError("Format string contains an unescaped latin alphabet character `"+n+"`");return s})).join("")}function at(t,e){(null==e||e>t.length)&&(e=t.length);for(var i=0,s=Array(e);i<e;i++)s[i]=t[i];return s}function lt(t,e){var i="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!i){if(Array.isArray(t)||(i=function(t,e){if(t){if("string"==typeof t)return at(t,e);var i={}.toString.call(t).slice(8,-1);return"Object"===i&&t.constructor&&(i=t.constructor.name),"Map"===i||"Set"===i?Array.from(t):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?at(t,e):void 0}}(t))||e&&t&&"number"==typeof t.length){i&&(t=i);var s=0,o=function(){};return{s:o,n:function(){return s>=t.length?{done:!0}:{done:!1,value:t[s++]}},e:function(t){throw t},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var r,n=!0,a=!1;return{s:function(){i=i.call(t)},n:function(){var t=i.next();return n=t.done,t},e:function(t){a=!0,r=t},f:function(){try{n||null==i.return||i.return()}finally{if(a)throw r}}}}function ht(t,e){if(null==t)throw new TypeError("assign requires that input parameter not be null or undefined");for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&(t[i]=e[i]);return t}function dt(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function ct(t,e){return ct=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},ct(t,e)}function ut(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&ct(t,e)}function pt(t){return pt=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},pt(t)}function mt(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(mt=function(){return!!t})()}function vt(t){var e=mt();return function(){var i,s=pt(t);if(e){var o=pt(this).constructor;i=Reflect.construct(s,arguments,o)}else i=s.apply(this,arguments);return function(t,e){if(e&&("object"==d(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return dt(t)}(this,i)}}function ft(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function bt(t){var e=function(t){if("object"!=d(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var i=e.call(t,"string");if("object"!=d(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==d(e)?e:e+""}function gt(t,e){for(var i=0;i<e.length;i++){var s=e[i];s.enumerable=s.enumerable||!1,s.configurable=!0,"value"in s&&(s.writable=!0),Object.defineProperty(t,bt(s.key),s)}}function yt(t,e,i){return e&>(t.prototype,e),i&>(t,i),Object.defineProperty(t,"prototype",{writable:!1}),t}function wt(t,e,i){return(e=bt(e))in t?Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[e]=i,t}var _t=function(){function t(){ft(this,t),wt(this,"priority",void 0),wt(this,"subPriority",0)}return yt(t,[{key:"validate",value:function(){return!0}}]),t}(),xt=function(){ut(e,_t);var t=vt(e);function e(i,s,o,r,n){var a;return ft(this,e),(a=t.call(this)).value=i,a.validateValue=s,a.setValue=o,a.priority=r,n&&(a.subPriority=n),a}return yt(e,[{key:"validate",value:function(t,e){return this.validateValue(t,this.value,e)}},{key:"set",value:function(t,e,i){return this.setValue(t,e,this.value,i)}}]),e}(),kt=function(){ut(e,_t);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",10),wt(dt(i),"subPriority",-1),i}return yt(e,[{key:"set",value:function(t,e){if(e.timestampIsSet)return t;var i=new Date(0);return i.setFullYear(t.getUTCFullYear(),t.getUTCMonth(),t.getUTCDate()),i.setHours(t.getUTCHours(),t.getUTCMinutes(),t.getUTCSeconds(),t.getUTCMilliseconds()),i}}]),e}(),Ct=function(){function t(){ft(this,t),wt(this,"incompatibleTokens",void 0),wt(this,"priority",void 0),wt(this,"subPriority",void 0)}return yt(t,[{key:"run",value:function(t,e,i,s){var o=this.parse(t,e,i,s);return o?{setter:new xt(o.value,this.validate,this.set,this.priority,this.subPriority),rest:o.rest}:null}},{key:"validate",value:function(){return!0}}]),t}(),At=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",140),wt(dt(i),"incompatibleTokens",["R","u","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){switch(e){case"G":case"GG":case"GGG":return i.era(t,{width:"abbreviated"})||i.era(t,{width:"narrow"});case"GGGGG":return i.era(t,{width:"narrow"});default:return i.era(t,{width:"wide"})||i.era(t,{width:"abbreviated"})||i.era(t,{width:"narrow"})}}},{key:"set",value:function(t,e,i){return e.era=i,t.setUTCFullYear(i,0,1),t.setUTCHours(0,0,0,0),t}}]),e}(),St=/^(1[0-2]|0?\d)/,zt=/^(3[0-1]|[0-2]?\d)/,It=/^(36[0-6]|3[0-5]\d|[0-2]?\d?\d)/,Et=/^(5[0-3]|[0-4]?\d)/,Tt=/^(2[0-3]|[0-1]?\d)/,Mt=/^(2[0-4]|[0-1]?\d)/,Dt=/^(1[0-1]|0?\d)/,Ot=/^(1[0-2]|0?\d)/,Pt=/^[0-5]?\d/,Ft=/^[0-5]?\d/,Nt=/^\d/,Bt=/^\d{1,2}/,jt=/^\d{1,3}/,Vt=/^\d{1,4}/,Lt=/^-?\d+/,Rt=/^-?\d/,qt=/^-?\d{1,2}/,$t=/^-?\d{1,3}/,Ht=/^-?\d{1,4}/,Wt=/^([+-])(\d{2})(\d{2})?|Z/,Gt=/^([+-])(\d{2})(\d{2})|Z/,Yt=/^([+-])(\d{2})(\d{2})((\d{2}))?|Z/,Ut=/^([+-])(\d{2}):(\d{2})|Z/,Kt=/^([+-])(\d{2}):(\d{2})(:(\d{2}))?|Z/;function Qt(t,e){return t?{value:e(t.value),rest:t.rest}:t}function Jt(t,e){var i=e.match(t);return i?{value:parseInt(i[0],10),rest:e.slice(i[0].length)}:null}function Xt(t,e){var i=e.match(t);return i?"Z"===i[0]?{value:0,rest:e.slice(1)}:{value:("+"===i[1]?1:-1)*(36e5*(i[2]?parseInt(i[2],10):0)+6e4*(i[3]?parseInt(i[3],10):0)+1e3*(i[5]?parseInt(i[5],10):0)),rest:e.slice(i[0].length)}:null}function Zt(t){return Jt(Lt,t)}function te(t,e){switch(t){case 1:return Jt(Nt,e);case 2:return Jt(Bt,e);case 3:return Jt(jt,e);case 4:return Jt(Vt,e);default:return Jt(new RegExp("^\\d{1,"+t+"}"),e)}}function ee(t,e){switch(t){case 1:return Jt(Rt,e);case 2:return Jt(qt,e);case 3:return Jt($t,e);case 4:return Jt(Ht,e);default:return Jt(new RegExp("^-?\\d{1,"+t+"}"),e)}}function ie(t){switch(t){case"morning":return 4;case"evening":return 17;case"pm":case"noon":case"afternoon":return 12;default:return 0}}function se(t,e){var i,s=e>0,o=s?e:1-e;if(o<=50)i=t||100;else{var r=o+50;i=t+100*Math.floor(r/100)-(t>=r%100?100:0)}return s?i:1-i}function oe(t){return t%400==0||t%4==0&&t%100!=0}var re=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",130),wt(dt(i),"incompatibleTokens",["Y","R","u","w","I","i","e","c","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){var s=function(t){return{year:t,isTwoDigitYear:"yy"===e}};switch(e){case"y":return Qt(te(4,t),s);case"yo":return Qt(i.ordinalNumber(t,{unit:"year"}),s);default:return Qt(te(e.length,t),s)}}},{key:"validate",value:function(t,e){return e.isTwoDigitYear||e.year>0}},{key:"set",value:function(t,e,i){var s=t.getUTCFullYear();if(i.isTwoDigitYear){var o=se(i.year,s);return t.setUTCFullYear(o,0,1),t.setUTCHours(0,0,0,0),t}return t.setUTCFullYear("era"in e&&1!==e.era?1-i.year:i.year,0,1),t.setUTCHours(0,0,0,0),t}}]),e}(),ne=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",130),wt(dt(i),"incompatibleTokens",["y","R","u","Q","q","M","L","I","d","D","i","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){var s=function(t){return{year:t,isTwoDigitYear:"YY"===e}};switch(e){case"Y":return Qt(te(4,t),s);case"Yo":return Qt(i.ordinalNumber(t,{unit:"year"}),s);default:return Qt(te(e.length,t),s)}}},{key:"validate",value:function(t,e){return e.isTwoDigitYear||e.year>0}},{key:"set",value:function(t,e,i,s){var o=x(t,s);if(i.isTwoDigitYear){var r=se(i.year,o);return t.setUTCFullYear(r,0,s.firstWeekContainsDate),t.setUTCHours(0,0,0,0),_(t,s)}return t.setUTCFullYear("era"in e&&1!==e.era?1-i.year:i.year,0,s.firstWeekContainsDate),t.setUTCHours(0,0,0,0),_(t,s)}}]),e}(),ae=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",130),wt(dt(i),"incompatibleTokens",["G","y","Y","u","Q","q","M","L","w","d","D","e","c","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e){return ee("R"===e?4:e.length,t)}},{key:"set",value:function(t,e,i){var s=new Date(0);return s.setUTCFullYear(i,0,4),s.setUTCHours(0,0,0,0),f(s)}}]),e}(),le=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",130),wt(dt(i),"incompatibleTokens",["G","y","Y","R","w","I","i","e","c","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e){return ee("u"===e?4:e.length,t)}},{key:"set",value:function(t,e,i){return t.setUTCFullYear(i,0,1),t.setUTCHours(0,0,0,0),t}}]),e}(),he=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",120),wt(dt(i),"incompatibleTokens",["Y","R","q","M","L","w","I","d","D","i","e","c","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){switch(e){case"Q":case"QQ":return te(e.length,t);case"Qo":return i.ordinalNumber(t,{unit:"quarter"});case"QQQ":return i.quarter(t,{width:"abbreviated",context:"formatting"})||i.quarter(t,{width:"narrow",context:"formatting"});case"QQQQQ":return i.quarter(t,{width:"narrow",context:"formatting"});default:return i.quarter(t,{width:"wide",context:"formatting"})||i.quarter(t,{width:"abbreviated",context:"formatting"})||i.quarter(t,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(t,e){return e>=1&&e<=4}},{key:"set",value:function(t,e,i){return t.setUTCMonth(3*(i-1),1),t.setUTCHours(0,0,0,0),t}}]),e}(),de=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",120),wt(dt(i),"incompatibleTokens",["Y","R","Q","M","L","w","I","d","D","i","e","c","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){switch(e){case"q":case"qq":return te(e.length,t);case"qo":return i.ordinalNumber(t,{unit:"quarter"});case"qqq":return i.quarter(t,{width:"abbreviated",context:"standalone"})||i.quarter(t,{width:"narrow",context:"standalone"});case"qqqqq":return i.quarter(t,{width:"narrow",context:"standalone"});default:return i.quarter(t,{width:"wide",context:"standalone"})||i.quarter(t,{width:"abbreviated",context:"standalone"})||i.quarter(t,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(t,e){return e>=1&&e<=4}},{key:"set",value:function(t,e,i){return t.setUTCMonth(3*(i-1),1),t.setUTCHours(0,0,0,0),t}}]),e}(),ce=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"incompatibleTokens",["Y","R","q","Q","L","w","I","D","i","e","c","t","T"]),wt(dt(i),"priority",110),i}return yt(e,[{key:"parse",value:function(t,e,i){var s=function(t){return t-1};switch(e){case"M":return Qt(Jt(St,t),s);case"MM":return Qt(te(2,t),s);case"Mo":return Qt(i.ordinalNumber(t,{unit:"month"}),s);case"MMM":return i.month(t,{width:"abbreviated",context:"formatting"})||i.month(t,{width:"narrow",context:"formatting"});case"MMMMM":return i.month(t,{width:"narrow",context:"formatting"});default:return i.month(t,{width:"wide",context:"formatting"})||i.month(t,{width:"abbreviated",context:"formatting"})||i.month(t,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(t,e){return e>=0&&e<=11}},{key:"set",value:function(t,e,i){return t.setUTCMonth(i,1),t.setUTCHours(0,0,0,0),t}}]),e}(),ue=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",110),wt(dt(i),"incompatibleTokens",["Y","R","q","Q","M","w","I","D","i","e","c","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){var s=function(t){return t-1};switch(e){case"L":return Qt(Jt(St,t),s);case"LL":return Qt(te(2,t),s);case"Lo":return Qt(i.ordinalNumber(t,{unit:"month"}),s);case"LLL":return i.month(t,{width:"abbreviated",context:"standalone"})||i.month(t,{width:"narrow",context:"standalone"});case"LLLLL":return i.month(t,{width:"narrow",context:"standalone"});default:return i.month(t,{width:"wide",context:"standalone"})||i.month(t,{width:"abbreviated",context:"standalone"})||i.month(t,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(t,e){return e>=0&&e<=11}},{key:"set",value:function(t,e,i){return t.setUTCMonth(i,1),t.setUTCHours(0,0,0,0),t}}]),e}(),pe=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",100),wt(dt(i),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","i","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){switch(e){case"w":return Jt(Et,t);case"wo":return i.ordinalNumber(t,{unit:"week"});default:return te(e.length,t)}}},{key:"validate",value:function(t,e){return e>=1&&e<=53}},{key:"set",value:function(t,e,i,s){return _(function(t,e,i){c(2,arguments);var s=u(t),o=m(e),r=k(s,i)-o;return s.setUTCDate(s.getUTCDate()-7*r),s}(t,i,s),s)}}]),e}(),me=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",100),wt(dt(i),"incompatibleTokens",["y","Y","u","q","Q","M","L","w","d","D","e","c","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){switch(e){case"I":return Jt(Et,t);case"Io":return i.ordinalNumber(t,{unit:"week"});default:return te(e.length,t)}}},{key:"validate",value:function(t,e){return e>=1&&e<=53}},{key:"set",value:function(t,e,i){return f(function(t,e){c(2,arguments);var i=u(t),s=m(e),o=g(i)-s;return i.setUTCDate(i.getUTCDate()-7*o),i}(t,i))}}]),e}(),ve=[31,28,31,30,31,30,31,31,30,31,30,31],fe=[31,29,31,30,31,30,31,31,30,31,30,31],be=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",90),wt(dt(i),"subPriority",1),wt(dt(i),"incompatibleTokens",["Y","R","q","Q","w","I","D","i","e","c","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){switch(e){case"d":return Jt(zt,t);case"do":return i.ordinalNumber(t,{unit:"date"});default:return te(e.length,t)}}},{key:"validate",value:function(t,e){var i=oe(t.getUTCFullYear()),s=t.getUTCMonth();return i?e>=1&&e<=fe[s]:e>=1&&e<=ve[s]}},{key:"set",value:function(t,e,i){return t.setUTCDate(i),t.setUTCHours(0,0,0,0),t}}]),e}(),ge=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",90),wt(dt(i),"subpriority",1),wt(dt(i),"incompatibleTokens",["Y","R","q","Q","M","L","w","I","d","E","i","e","c","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){switch(e){case"D":case"DD":return Jt(It,t);case"Do":return i.ordinalNumber(t,{unit:"date"});default:return te(e.length,t)}}},{key:"validate",value:function(t,e){return oe(t.getUTCFullYear())?e>=1&&e<=366:e>=1&&e<=365}},{key:"set",value:function(t,e,i){return t.setUTCMonth(0,i),t.setUTCHours(0,0,0,0),t}}]),e}();function ye(t,e,i){var s,o,r,n,a,l,h,d;c(2,arguments);var p=w(),v=m(null!==(s=null!==(o=null!==(r=null!==(n=null==i?void 0:i.weekStartsOn)&&void 0!==n?n:null==i||null===(a=i.locale)||void 0===a||null===(l=a.options)||void 0===l?void 0:l.weekStartsOn)&&void 0!==r?r:p.weekStartsOn)&&void 0!==o?o:null===(h=p.locale)||void 0===h||null===(d=h.options)||void 0===d?void 0:d.weekStartsOn)&&void 0!==s?s:0);if(!(v>=0&&v<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var f=u(t),b=m(e),g=((b%7+7)%7<v?7:0)+b-f.getUTCDay();return f.setUTCDate(f.getUTCDate()+g),f}var we=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",90),wt(dt(i),"incompatibleTokens",["D","i","e","c","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){switch(e){case"E":case"EE":case"EEE":return i.day(t,{width:"abbreviated",context:"formatting"})||i.day(t,{width:"short",context:"formatting"})||i.day(t,{width:"narrow",context:"formatting"});case"EEEEE":return i.day(t,{width:"narrow",context:"formatting"});case"EEEEEE":return i.day(t,{width:"short",context:"formatting"})||i.day(t,{width:"narrow",context:"formatting"});default:return i.day(t,{width:"wide",context:"formatting"})||i.day(t,{width:"abbreviated",context:"formatting"})||i.day(t,{width:"short",context:"formatting"})||i.day(t,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(t,e){return e>=0&&e<=6}},{key:"set",value:function(t,e,i,s){return(t=ye(t,i,s)).setUTCHours(0,0,0,0),t}}]),e}(),_e=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",90),wt(dt(i),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","E","i","c","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i,s){var o=function(t){var e=7*Math.floor((t-1)/7);return(t+s.weekStartsOn+6)%7+e};switch(e){case"e":case"ee":return Qt(te(e.length,t),o);case"eo":return Qt(i.ordinalNumber(t,{unit:"day"}),o);case"eee":return i.day(t,{width:"abbreviated",context:"formatting"})||i.day(t,{width:"short",context:"formatting"})||i.day(t,{width:"narrow",context:"formatting"});case"eeeee":return i.day(t,{width:"narrow",context:"formatting"});case"eeeeee":return i.day(t,{width:"short",context:"formatting"})||i.day(t,{width:"narrow",context:"formatting"});default:return i.day(t,{width:"wide",context:"formatting"})||i.day(t,{width:"abbreviated",context:"formatting"})||i.day(t,{width:"short",context:"formatting"})||i.day(t,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(t,e){return e>=0&&e<=6}},{key:"set",value:function(t,e,i,s){return(t=ye(t,i,s)).setUTCHours(0,0,0,0),t}}]),e}(),xe=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",90),wt(dt(i),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","E","i","e","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i,s){var o=function(t){var e=7*Math.floor((t-1)/7);return(t+s.weekStartsOn+6)%7+e};switch(e){case"c":case"cc":return Qt(te(e.length,t),o);case"co":return Qt(i.ordinalNumber(t,{unit:"day"}),o);case"ccc":return i.day(t,{width:"abbreviated",context:"standalone"})||i.day(t,{width:"short",context:"standalone"})||i.day(t,{width:"narrow",context:"standalone"});case"ccccc":return i.day(t,{width:"narrow",context:"standalone"});case"cccccc":return i.day(t,{width:"short",context:"standalone"})||i.day(t,{width:"narrow",context:"standalone"});default:return i.day(t,{width:"wide",context:"standalone"})||i.day(t,{width:"abbreviated",context:"standalone"})||i.day(t,{width:"short",context:"standalone"})||i.day(t,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(t,e){return e>=0&&e<=6}},{key:"set",value:function(t,e,i,s){return(t=ye(t,i,s)).setUTCHours(0,0,0,0),t}}]),e}(),ke=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",90),wt(dt(i),"incompatibleTokens",["y","Y","u","q","Q","M","L","w","d","D","E","e","c","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){var s=function(t){return 0===t?7:t};switch(e){case"i":case"ii":return te(e.length,t);case"io":return i.ordinalNumber(t,{unit:"day"});case"iii":return Qt(i.day(t,{width:"abbreviated",context:"formatting"})||i.day(t,{width:"short",context:"formatting"})||i.day(t,{width:"narrow",context:"formatting"}),s);case"iiiii":return Qt(i.day(t,{width:"narrow",context:"formatting"}),s);case"iiiiii":return Qt(i.day(t,{width:"short",context:"formatting"})||i.day(t,{width:"narrow",context:"formatting"}),s);default:return Qt(i.day(t,{width:"wide",context:"formatting"})||i.day(t,{width:"abbreviated",context:"formatting"})||i.day(t,{width:"short",context:"formatting"})||i.day(t,{width:"narrow",context:"formatting"}),s)}}},{key:"validate",value:function(t,e){return e>=1&&e<=7}},{key:"set",value:function(t,e,i){return t=function(t,e){c(2,arguments);var i=m(e);i%7==0&&(i-=7);var s=u(t),o=((i%7+7)%7<1?7:0)+i-s.getUTCDay();return s.setUTCDate(s.getUTCDate()+o),s}(t,i),t.setUTCHours(0,0,0,0),t}}]),e}(),Ce=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",80),wt(dt(i),"incompatibleTokens",["b","B","H","k","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){switch(e){case"a":case"aa":case"aaa":return i.dayPeriod(t,{width:"abbreviated",context:"formatting"})||i.dayPeriod(t,{width:"narrow",context:"formatting"});case"aaaaa":return i.dayPeriod(t,{width:"narrow",context:"formatting"});default:return i.dayPeriod(t,{width:"wide",context:"formatting"})||i.dayPeriod(t,{width:"abbreviated",context:"formatting"})||i.dayPeriod(t,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(t,e,i){return t.setUTCHours(ie(i),0,0,0),t}}]),e}(),Ae=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",80),wt(dt(i),"incompatibleTokens",["a","B","H","k","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){switch(e){case"b":case"bb":case"bbb":return i.dayPeriod(t,{width:"abbreviated",context:"formatting"})||i.dayPeriod(t,{width:"narrow",context:"formatting"});case"bbbbb":return i.dayPeriod(t,{width:"narrow",context:"formatting"});default:return i.dayPeriod(t,{width:"wide",context:"formatting"})||i.dayPeriod(t,{width:"abbreviated",context:"formatting"})||i.dayPeriod(t,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(t,e,i){return t.setUTCHours(ie(i),0,0,0),t}}]),e}(),Se=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",80),wt(dt(i),"incompatibleTokens",["a","b","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){switch(e){case"B":case"BB":case"BBB":return i.dayPeriod(t,{width:"abbreviated",context:"formatting"})||i.dayPeriod(t,{width:"narrow",context:"formatting"});case"BBBBB":return i.dayPeriod(t,{width:"narrow",context:"formatting"});default:return i.dayPeriod(t,{width:"wide",context:"formatting"})||i.dayPeriod(t,{width:"abbreviated",context:"formatting"})||i.dayPeriod(t,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(t,e,i){return t.setUTCHours(ie(i),0,0,0),t}}]),e}(),ze=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",70),wt(dt(i),"incompatibleTokens",["H","K","k","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){switch(e){case"h":return Jt(Ot,t);case"ho":return i.ordinalNumber(t,{unit:"hour"});default:return te(e.length,t)}}},{key:"validate",value:function(t,e){return e>=1&&e<=12}},{key:"set",value:function(t,e,i){var s=t.getUTCHours()>=12;return t.setUTCHours(s&&i<12?i+12:s||12!==i?i:0,0,0,0),t}}]),e}(),Ie=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",70),wt(dt(i),"incompatibleTokens",["a","b","h","K","k","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){switch(e){case"H":return Jt(Tt,t);case"Ho":return i.ordinalNumber(t,{unit:"hour"});default:return te(e.length,t)}}},{key:"validate",value:function(t,e){return e>=0&&e<=23}},{key:"set",value:function(t,e,i){return t.setUTCHours(i,0,0,0),t}}]),e}(),Ee=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",70),wt(dt(i),"incompatibleTokens",["h","H","k","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){switch(e){case"K":return Jt(Dt,t);case"Ko":return i.ordinalNumber(t,{unit:"hour"});default:return te(e.length,t)}}},{key:"validate",value:function(t,e){return e>=0&&e<=11}},{key:"set",value:function(t,e,i){var s=t.getUTCHours()>=12;return t.setUTCHours(s&&i<12?i+12:i,0,0,0),t}}]),e}(),Te=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",70),wt(dt(i),"incompatibleTokens",["a","b","h","H","K","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){switch(e){case"k":return Jt(Mt,t);case"ko":return i.ordinalNumber(t,{unit:"hour"});default:return te(e.length,t)}}},{key:"validate",value:function(t,e){return e>=1&&e<=24}},{key:"set",value:function(t,e,i){return t.setUTCHours(i<=24?i%24:i,0,0,0),t}}]),e}(),Me=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",60),wt(dt(i),"incompatibleTokens",["t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){switch(e){case"m":return Jt(Pt,t);case"mo":return i.ordinalNumber(t,{unit:"minute"});default:return te(e.length,t)}}},{key:"validate",value:function(t,e){return e>=0&&e<=59}},{key:"set",value:function(t,e,i){return t.setUTCMinutes(i,0,0),t}}]),e}(),De=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",50),wt(dt(i),"incompatibleTokens",["t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){switch(e){case"s":return Jt(Ft,t);case"so":return i.ordinalNumber(t,{unit:"second"});default:return te(e.length,t)}}},{key:"validate",value:function(t,e){return e>=0&&e<=59}},{key:"set",value:function(t,e,i){return t.setUTCSeconds(i,0),t}}]),e}(),Oe=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",30),wt(dt(i),"incompatibleTokens",["t","T"]),i}return yt(e,[{key:"parse",value:function(t,e){return Qt(te(e.length,t),(function(t){return Math.floor(t*Math.pow(10,3-e.length))}))}},{key:"set",value:function(t,e,i){return t.setUTCMilliseconds(i),t}}]),e}(),Pe=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",10),wt(dt(i),"incompatibleTokens",["t","T","x"]),i}return yt(e,[{key:"parse",value:function(t,e){switch(e){case"X":return Xt(Wt,t);case"XX":return Xt(Gt,t);case"XXXX":return Xt(Yt,t);case"XXXXX":return Xt(Kt,t);default:return Xt(Ut,t)}}},{key:"set",value:function(t,e,i){return e.timestampIsSet?t:new Date(t.getTime()-i)}}]),e}(),Fe=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",10),wt(dt(i),"incompatibleTokens",["t","T","X"]),i}return yt(e,[{key:"parse",value:function(t,e){switch(e){case"x":return Xt(Wt,t);case"xx":return Xt(Gt,t);case"xxxx":return Xt(Yt,t);case"xxxxx":return Xt(Kt,t);default:return Xt(Ut,t)}}},{key:"set",value:function(t,e,i){return e.timestampIsSet?t:new Date(t.getTime()-i)}}]),e}(),Ne=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",40),wt(dt(i),"incompatibleTokens","*"),i}return yt(e,[{key:"parse",value:function(t){return Zt(t)}},{key:"set",value:function(t,e,i){return[new Date(1e3*i),{timestampIsSet:!0}]}}]),e}(),Be=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",20),wt(dt(i),"incompatibleTokens","*"),i}return yt(e,[{key:"parse",value:function(t){return Zt(t)}},{key:"set",value:function(t,e,i){return[new Date(i),{timestampIsSet:!0}]}}]),e}(),je={G:new At,y:new re,Y:new ne,R:new ae,u:new le,Q:new he,q:new de,M:new ce,L:new ue,w:new pe,I:new me,d:new be,D:new ge,E:new we,e:new _e,c:new xe,i:new ke,a:new Ce,b:new Ae,B:new Se,h:new ze,H:new Ie,K:new Ee,k:new Te,m:new Me,s:new De,S:new Oe,X:new Pe,x:new Fe,t:new Ne,T:new Be},Ve=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,Le=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,Re=/^'([^]*?)'?$/,qe=/''/g,$e=/\S/,He=/[a-zA-Z]/;function We(t,e,i,s){var o,r,n,a,l,h,p,f,b,g,y,_,x,k,C,A,S,z;c(3,arguments);var I=String(t),E=String(e),T=w(),M=null!==(o=null!==(r=null==s?void 0:s.locale)&&void 0!==r?r:T.locale)&&void 0!==o?o:tt;if(!M.match)throw new RangeError("locale must contain match property");var D=m(null!==(n=null!==(a=null!==(l=null!==(h=null==s?void 0:s.firstWeekContainsDate)&&void 0!==h?h:null==s||null===(p=s.locale)||void 0===p||null===(f=p.options)||void 0===f?void 0:f.firstWeekContainsDate)&&void 0!==l?l:T.firstWeekContainsDate)&&void 0!==a?a:null===(b=T.locale)||void 0===b||null===(g=b.options)||void 0===g?void 0:g.firstWeekContainsDate)&&void 0!==n?n:1);if(!(D>=1&&D<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var O=m(null!==(y=null!==(_=null!==(x=null!==(k=null==s?void 0:s.weekStartsOn)&&void 0!==k?k:null==s||null===(C=s.locale)||void 0===C||null===(A=C.options)||void 0===A?void 0:A.weekStartsOn)&&void 0!==x?x:T.weekStartsOn)&&void 0!==_?_:null===(S=T.locale)||void 0===S||null===(z=S.options)||void 0===z?void 0:z.weekStartsOn)&&void 0!==y?y:0);if(!(O>=0&&O<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(""===E)return""===I?u(i):new Date(NaN);var P,F={firstWeekContainsDate:D,weekStartsOn:O,locale:M},N=[new kt],B=E.match(Le).map((function(t){var e=t[0];return e in L?(0,L[e])(t,M.formatLong):t})).join("").match(Ve),j=[],V=lt(B);try{var q=function(){var e=P.value;null!=s&&s.useAdditionalWeekYearTokens||!W(e)||G(e,E,t),null!=s&&s.useAdditionalDayOfYearTokens||!H(e)||G(e,E,t);var i=e[0],o=je[i];if(o){var r=o.incompatibleTokens;if(Array.isArray(r)){var n=j.find((function(t){return r.includes(t.token)||t.token===i}));if(n)throw new RangeError("The format string mustn't contain `".concat(n.fullToken,"` and `").concat(e,"` at the same time"))}else if("*"===o.incompatibleTokens&&j.length>0)throw new RangeError("The format string mustn't contain `".concat(e,"` and any other token at the same time"));j.push({token:i,fullToken:e});var a=o.run(I,e,M.match,F);if(!a)return{v:new Date(NaN)};N.push(a.setter),I=a.rest}else{if(i.match(He))throw new RangeError("Format string contains an unescaped latin alphabet character `"+i+"`");if("''"===e?e="'":"'"===i&&(e=e.match(Re)[1].replace(qe,"'")),0!==I.indexOf(e))return{v:new Date(NaN)};I=I.slice(e.length)}};for(V.s();!(P=V.n()).done;){var $=q();if("object"===d($))return $.v}}catch(t){V.e(t)}finally{V.f()}if(I.length>0&&$e.test(I))return new Date(NaN);var Y=N.map((function(t){return t.priority})).sort((function(t,e){return e-t})).filter((function(t,e,i){return i.indexOf(t)===e})).map((function(t){return N.filter((function(e){return e.priority===t})).sort((function(t,e){return e.subPriority-t.subPriority}))})).map((function(t){return t[0]})),U=u(i);if(isNaN(U.getTime()))return new Date(NaN);var K,Q=v(U,R(U)),J={},X=lt(Y);try{for(X.s();!(K=X.n()).done;){var Z=K.value;if(!Z.validate(Q,F))return new Date(NaN);var et=Z.set(Q,J,F);Array.isArray(et)?(Q=et[0],ht(J,et[1])):Q=et}}catch(t){X.e(t)}finally{X.f()}return Q}function Ge(t,e){c(2,arguments);var i=u(t),s=u(e);return i.getTime()>s.getTime()}function Ye(t,e){c(2,arguments);var i=u(t),s=u(e);return i.getTime()<s.getTime()}function Ue(t,e,i){return c(2,arguments),p(We(t,e,new Date,i))}const Ke=class{constructor(i){t(this,i),this.sendValidityState=e(this,"sendValidityState",7),this.sendInputValue=e(this,"sendInputValue",7),this.touched=!1,this.formatDate=t=>{const{year:e,month:i,day:s}=t;return nt(new Date(e,i,s),this.dateFormat)},this.parseDate=t=>{const e=We(t,this.dateFormat,new Date);return{year:e.getFullYear(),month:e.getMonth(),day:e.getDate()}},this.setClientStyling=()=>{let t=document.createElement("style");t.innerHTML=this.clientStyling,this.stylingContainer.prepend(t)},this.name=void 0,this.displayName=void 0,this.placeholder=void 0,this.validation=void 0,this.defaultValue=void 0,this.autofilled=void 0,this.tooltip=void 0,this.language=void 0,this.emitValue=void 0,this.clientStyling="",this.dateFormat="yyyy-MM-dd",this.emitOnClick=!1,this.errorMessage=void 0,this.isValid=void 0,this.limitStylingAppends=!1,this.showTooltip=!1}get formattedValue(){return this.value?nt(We(this.value,"yyyy-MM-dd",new Date),this.dateFormat):""}handleStylingChange(t,e){t!==e&&this.setClientStyling()}validityChanged(){this.validityStateHandler({valid:this.isValid,name:this.name}),1==this.emitValue&&this.valueHandler({name:this.name,value:this.value})}validityStateHandler(t){this.sendValidityState.emit(t)}emitValueHandler(t){1==t&&this.isValid&&this.valueHandler({name:this.name,value:this.value})}valueHandler(t){this.sendInputValue.emit(t)}handleClickOutside(t){t.composedPath()[0]!==this.tooltipIconReference&&t.composedPath()[0]!==this.tooltipReference&&(this.showTooltip=!1)}connectedCallback(){var t,e;this.minDate=We((null===(t=this.validation.min)||void 0===t?void 0:t.toString())||"","yyyy-MM-dd",new Date),this.maxDate=We((null===(e=this.validation.max)||void 0===e?void 0:e.toString())||"","yyyy-MM-dd",new Date)}componentDidRender(){!this.limitStylingAppends&&this.stylingContainer&&(this.clientStyling&&this.setClientStyling(),this.limitStylingAppends=!0)}componentDidLoad(){if(this.datePicker=this.element.shadowRoot.querySelector("vaadin-date-picker"),this.inputReference=this.element.shadowRoot.querySelector("input"),this.datePicker){const t=this.datePicker.shadowRoot.querySelector('[part="toggle-button"]');t&&t.addEventListener("click",(()=>this.handleCalendarIconClick())),this.datePicker.addEventListener("opened-changed",(t=>{!0===t.detail.value?this.errorMessage="":(this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage(),this.touched=!0)}))}this.datePicker.i18n=Object.assign(Object.assign({},this.datePicker.i18n),{formatDate:this.formatDate,parseDate:this.parseDate}),this.isValid=this.setValidity(),this.defaultValue&&(this.value=this.defaultValue,this.valueHandler({name:this.name,value:this.value}))}handleCalendarIconClick(){this.datePicker.opened&&this.emitOnClick&&window.postMessage({type:`registration${this.name}Clicked`},window.location.href)}handleInput(t){this.value=t.target.value,this.touched=!0,this.valueAsDate=We(this.value||"","yyyy-MM-dd",new Date),this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage(),this.emitValueHandler(!0)}setValidity(){return!(Ye(this.valueAsDate,this.minDate)||Ge(this.valueAsDate,this.maxDate)||!Ue(this.formattedValue,this.dateFormat))&&this.inputReference.validity.valid}setErrorMessage(){return this.inputReference.validity.valueMissing?n("requiredError",this.language):this.inputReference.validity.rangeUnderflow||this.inputReference.validity.rangeOverflow?n("dateError",this.language,{values:{min:this.validation.min,max:this.validation.max}}):Ye(this.valueAsDate,this.minDate)||Ge(this.valueAsDate,this.maxDate)?n("dateError2",this.language):Ue(this.formattedValue,this.dateFormat)?void 0:n("dateFormatError",this.language)}renderTooltip(){return this.showTooltip?i("div",{class:"date__tooltip "+(this.showTooltip?"visible":""),ref:t=>this.tooltipReference=t,innerHTML:this.tooltip}):null}render(){let t="";return this.touched&&(t=1==this.isValid||null==this.isValid?"":"text__input--invalid"),i("div",{key:"ccbdcfd1e145373d0fb24f7c1e6e5ae1184a80f2",class:`date__wrapper ${this.autofilled?"date__wrapper--autofilled":""} ${this.name}__input`,ref:t=>this.stylingContainer=t},i("label",{key:"960db248a2f7418ed87b25de57b58cc8a4902a25",class:`date__label ${this.validation.mandatory?"date__label--required":""}}`,htmlFor:`${this.name}__input`},this.displayName," ",this.validation.mandatory?"*":""),i("vaadin-date-picker",{key:"660961b240cc0cff03d8d4bf3687b398cd07befd",id:`${this.name}__input`,type:"date",class:`date__input ${t}`,value:this.defaultValue,readOnly:this.autofilled,placeholder:`${this.placeholder}`,required:this.validation.mandatory,max:this.validation.max,min:this.validation.min,onChange:t=>this.handleInput(t)}),i("small",{key:"ba06bb3d85bb4441ae92a642464a47b798b287eb",class:"date__error-message"},this.errorMessage),this.tooltip&&i("img",{key:"7ccb422e319e2a08963e99b242495ba9115517bd",class:"date__tooltip-icon",src:a,alt:"",ref:t=>this.tooltipIconReference=t,onClick:()=>this.showTooltip=!this.showTooltip}),this.renderTooltip())}get element(){return s(this)}static get watchers(){return{clientStyling:["handleStylingChange"],isValid:["validityChanged"],emitValue:["emitValueHandler"]}}};Ke.style='*,*::before,*::after{padding:0;margin:0;box-sizing:border-box}.date{font-family:"Roboto";font-style:normal}.date__wrapper{position:relative;width:100%;display:flex;flex-direction:column;gap:5px;height:100%}.date__wrapper--autofilled{pointer-events:none}.date__wrapper--autofilled .date__label{color:var(--emw--registration-typography, var(--emw--color-black, #000000))}.date__wrapper--autofilled .date__input::part(input-field){color:var(--emw--registration-typography, var(--emw--color-black, #000000))}.date__label{font-family:inherit;font-style:normal;font-weight:500;font-size:16px;line-height:20px;color:var(--emw--registration-typography, var(--emw--color-black, #000000))}.date__label--required::after{content:"*";font-family:inherit;color:var(--emw--login-color-primary, var(--emw--color-primary, #22B04E));margin-left:2px}.date__input{border:none;width:inherit;position:relative}.date__input[focused]::part(input-field){border-color:var(--emw--login-color-primary, var(--emw--color-primary, #22B04E))}.date__input[invalid]::part(input-field){border:1px solid var(--emw--color-error, var(--emw--color-red, #ed0909))}.date__input::part(input-field){border-radius:4px;background-color:var(--emw--color-white, #FFFFFF);border:1px solid var(--emw--color-gray-100, #E6E6E6);color:var(--emw--registration-typography, var(--emw--color-black, #000000));font-family:inherit;font-style:normal;font-size:16px;font-weight:300;line-height:1.5;padding:0;height:44px}.date__input>input{padding:5px 15px}.date__input::part(toggle-button){position:relative;right:10px}.date__error-message{position:absolute;top:calc(100% + 5px);left:0;color:var(--emw--color-error, var(--emw--color-red, #ed0909))}.date__tooltip-icon{position:absolute;right:0;bottom:10px}.date__tooltip{position:absolute;bottom:35px;right:10px;background-color:var(--emw--color-white, #FFFFFF);border:1px solid var(--emw--color-gray-100, #E6E6E6);color:var(--emw--registration-typography, var(--emw--color-black, #000000));padding:10px;border-radius:5px;opacity:0;transition:opacity 0.3s ease-in-out;z-index:10}.date__tooltip.visible{opacity:1}';const Qe=class{constructor(i){t(this,i),this.sendValidityState=e(this,"sendValidityState",7),this.sendInputValue=e(this,"sendInputValue",7),this.validationPattern="",this.touched=!1,this.handleInput=t=>{this.value=t.target.value,this.touched=!0,this.debounceTime&&clearTimeout(this.debounceTime),this.debounceTime=setTimeout((()=>{this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage(),this.emitValueHandler(!0)}),500)},this.handleBlur=()=>{this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage(),this.touched=!0},this.setClientStyling=()=>{let t=document.createElement("style");t.innerHTML=this.clientStyling,this.stylingContainer.prepend(t)},this.name=void 0,this.displayName=void 0,this.placeholder=void 0,this.validation=void 0,this.defaultValue=void 0,this.autofilled=void 0,this.tooltip=void 0,this.language=void 0,this.emitValue=void 0,this.isDuplicateInput=void 0,this.clientStyling="",this.errorMessage=void 0,this.isValid=void 0,this.limitStylingAppends=!1,this.showTooltip=!1}handleStylingChange(t,e){t!==e&&this.setClientStyling()}validityChanged(){this.validityStateHandler({valid:this.isValid,name:this.name}),1==this.emitValue&&this.valueHandler({name:this.name,value:this.value})}emitValueHandler(t){1==t&&this.isValid&&this.valueHandler({name:this.name,value:this.value})}validityStateHandler(t){this.sendValidityState.emit(t)}valueHandler(t){this.sendInputValue.emit(t)}handleClickOutside(t){t.composedPath()[0]!==this.tooltipIconReference&&t.composedPath()[0]!==this.tooltipReference&&(this.showTooltip=!1)}valueChangedHandler(t){this.isDuplicateInput&&this.name===t.detail.name+"Duplicate"&&(this.duplicateInputValue=t.detail.value)}connectedCallback(){this.validationPattern=this.setPattern()}componentDidRender(){!this.limitStylingAppends&&this.stylingContainer&&(this.clientStyling&&this.setClientStyling(),this.limitStylingAppends=!0)}componentDidLoad(){this.isValid=this.setValidity(),this.defaultValue&&(this.value=this.defaultValue,this.valueHandler({name:this.name,value:this.value}))}setValidity(){return this.inputReference.validity.valid}setPattern(){var t,e;if((null===(t=this.validation.custom)||void 0===t?void 0:t.length)>0)return null===(e=this.validation.custom.find((t=>"regex"===t.rule)))||void 0===e?void 0:e.pattern}setErrorMessage(){var t,e,i,s;if(this.inputReference.validity.valueMissing)return n("requiredError",this.language);if(this.inputReference.validity.tooShort||this.inputReference.validity.tooLong)return n("lengthError",this.language,{values:{minLength:this.validation.minLength,maxLength:this.validation.maxLength}});if(this.inputReference.validity.patternMismatch){const i=null===(t=this.validation.custom.find((t=>"regex"===t.rule)))||void 0===t?void 0:t.errorKey,s=null===(e=this.validation.custom.find((t=>"regex"===t.rule)))||void 0===e?void 0:e.errorMessage;return n(`${i}`,this.language)?n(`${i}`,this.language):s}if(this.isDuplicateInput&&this.duplicateInputValue!==this.value){const t=null===(i=this.validation.custom.find((t=>"duplicate-input"===t.rule)))||void 0===i?void 0:i.errorKey,e=null===(s=this.validation.custom.find((t=>"duplicate-input"===t.rule)))||void 0===s?void 0:s.errorMessage;return n(`${t}`,this.language)?n(`${t}`,this.language):e}}renderTooltip(){return this.showTooltip?i("div",{class:"email__tooltip "+(this.showTooltip?"visible":""),ref:t=>this.tooltipReference=t,innerHTML:this.tooltip}):null}render(){let t="";return this.touched&&(t=1==this.isValid||null==this.isValid?"":"text__input--invalid"),i("div",{key:"532d12855e6014b6c5a81cd11f4c7d83596361c3",class:`email__wrapper ${this.autofilled?"number__wrapper--autofilled":""} ${this.name}__input`,ref:t=>this.stylingContainer=t},i("div",{key:"80f2e930c6360e1e4e27f29b1de3d3c49a3bb47f",class:"email__wrapper--flex"},i("label",{key:"68189c133403e6dada30c376bd84b60b35ca56e4",class:"email__label "+(this.validation.mandatory?"email__label--required":""),htmlFor:`${this.name}__input`},this.displayName),i("div",{key:"b62dd9a877825d51f6735e9b3ca6b3bb3fc21c28",class:"email__wrapper--relative"},this.tooltip&&i("img",{key:"ff76c31db244e06af60db2855b907c90ecde2fe2",class:"email__tooltip-icon",src:a,alt:"",ref:t=>this.tooltipIconReference=t,onClick:()=>this.showTooltip=!this.showTooltip}),this.renderTooltip())),i("input",{key:"137af683d11c63b2bd881fa3110dd1522ead8774",id:`${this.name}__input`,type:"email",class:`email__input ${t}`,value:this.defaultValue,readOnly:this.autofilled,placeholder:`${this.placeholder}`,ref:t=>this.inputReference=t,pattern:this.validationPattern,required:this.validation.mandatory,minlength:this.validation.minLength,maxlength:this.validation.maxLength,onInput:this.handleInput,onBlur:this.handleBlur}),i("small",{key:"573a357c4e8464f20d9e60a5fd3a2d0c4ae69e3c",class:"email__error-message"},this.errorMessage))}static get watchers(){return{clientStyling:["handleStylingChange"],isValid:["validityChanged"],emitValue:["emitValueHandler"]}}};Qe.style='*,*::before,*::after{padding:0;margin:0;box-sizing:border-box}.email{font-family:"Roboto";font-style:normal}.email__wrapper{position:relative;width:100%}.email__wrapper--autofilled{pointer-events:none}.email__wrapper--autofilled .email__label{color:var(--emw--registration-typography, var(--emw--color-black, #000000))}.email__wrapper--autofilled .email__input{color:var(--emw--color-black, #000000)}.email__wrapper--flex{display:flex;gap:5px}.email__wrapper--relative{position:relative}.email__label{font-family:inherit;font-style:normal;font-weight:500;font-size:16px;line-height:20px;color:var(--emw--registration-typography, var(--emw--color-black, #000000))}.email__label--required::after{content:"*";font-family:inherit;color:var(--emw--login-color-primary, var(--emw--color-primary, #22B04E));margin-left:2px}.email__input{font-family:inherit;border-radius:4px;width:100%;height:40px;border:2px solid var(--emw--color-gray-100, #E6E6E6);color:var(--emw--color-black, #000000);border-radius:5px;box-sizing:border-box;font-size:16px;font-weight:300;line-height:1.5;padding:10px}.email__input:focus{outline-color:var(--emw--login-color-primary, var(--emw--color-primary, #22B04E))}.email__input--invalid{border:1px solid var(--emw--color-error, var(--emw--color-red, #ed0909))}.email__input::placeholder{color:var(--emw--color-gray-150, #828282)}.email__error-message{position:absolute;top:calc(100% + 5px);left:0;color:var(--emw--color-error, var(--emw--color-red, #ed0909))}.email__tooltip-icon{width:16px;height:auto}.email__tooltip{position:absolute;top:0;left:20px;background-color:var(--emw--color-white, #FFFFFF);border:1px solid var(--emw--color-gray-100, #E6E6E6);color:var(--emw--registration-typography, var(--emw--color-black, #000000));padding:10px;border-radius:5px;opacity:0;transition:opacity 0.3s ease-in-out;z-index:10}.email__tooltip.visible{opacity:1}';var Je=Object.defineProperty,Xe=Object.defineProperties,Ze=Object.getOwnPropertyDescriptors,ti=Object.getOwnPropertySymbols,ei=Object.prototype.hasOwnProperty,ii=Object.prototype.propertyIsEnumerable,si=(t,e,i)=>e in t?Je(t,e,{enumerable:!0,configurable:!0,writable:!0,value:i}):t[e]=i,oi=(t,e)=>{for(var i in e||(e={}))ei.call(e,i)&&si(t,i,e[i]);if(ti)for(var i of ti(e))ii.call(e,i)&&si(t,i,e[i]);return t},ri=(t,e)=>Xe(t,Ze(e)),ni=(t,e,i)=>(si(t,"symbol"!=typeof e?e+"":e,i),i),ai=(t,e,i)=>new Promise(((s,o)=>{var r=t=>{try{a(i.next(t))}catch(t){o(t)}},n=t=>{try{a(i.throw(t))}catch(t){o(t)}},a=t=>t.done?s(t.value):Promise.resolve(t.value).then(r,n);a((i=i.apply(t,e)).next())}))
|
|
1
|
+
import{r as t,c as e,h as i,g as s,H as o}from"./index-ed8fc8f4.js";const r={en:{dateError:"The selected date should be between {min} and {max}",dateError2:"The selected date is not within the accepted range",dateFormatError:"The selected date has a different format then the one required.",numberLengthError:"The number should be between {min} and {max}",lengthError:"The length should be between {minLength} and {maxLength}",requiredError:"This input is required.",invalidOriginalPasswordError:"Initial password field does not validate all criteria.",invalidPassword:"Password does not meet all criteria",passwordStrength:"Password strength",passwordStrengthWeak:"is not adequate",passwordStrengthStrong:"is adequate",SpecialCharactersNotAllowed:"Should not contain special characters",InvalidEmailFormat:"Invalid email format.",EmailNotMatching:"Emails not matching!",PasswordNotMatching:"Passwords not matching",MustIncludeNumber:"Password must include a number",MustContainCapital:"Password must include a capital letter",MustIncludePunctation:"Password must include punctuation",OnlyNumbers:"The input should contain only digits.",InvalidFieldSize:"The length must be exactly 11 digits.",InvalidDocumentNumber:"Only numerical characters are allowed.",twofaDescription:"<p> We have sent the verification code to <p> {destination}. </p> </p> <p> Please insert the PIN below. </p>",twofaResendMessage:"Didn't receive the verification code?",twofaResendButton:"Resend"},hu:{dateError:"A választott dátumnak {min} és {max} között kell lennie",dateError2:"A kiválasztott dátum nincs az elfogadott tartományon belül",dateFormatError:"A kiválasztott dátum formátuma eltér a szükségestől.",numberLengthError:"A számnak {min} és {max} között kell lennie",lengthError:"A hossznak {minLength} és {maxLength} között kell lennie",requiredError:"Ez a beviteli mező kötelező.",invalidOriginalPasswordError:"Initial password field does not validate all criteria.",invalidPassword:"A jelszó nem felel meg minden kritériumnak",passwordStrength:"Jelszó erőssége",passwordStrengthWeak:"nem megfelelő",passwordStrengthStrong:"megfelelő",SpecialCharactersNotAllowed:"Nem tartalmazhat speciális karaktereket",InvalidEmailFormat:"Érvénytelen e-mail formátum.",EmailNotMatching:"Az e-mailek nem egyeznek!",PasswordNotMatching:"A jelszavak nem egyeznek",MustIncludeNumber:"A jelszónak tartalmaznia kell egy számot",MustContainCapital:"A jelszónak tartalmaznia kell egy nagybetűt",MustIncludePunctation:"A jelszónak tartalmaznia kell írásjelet",OnlyNumbers:"Csak számjegyeket tartalmazhat.",InvalidFieldSize:"A hosszúságnak pontosan 11 számjegynek kell lennie.",InvalidDocumentNumber:"Csak számjegyek engedélyezettek.",twofaDescription:"<p> A megerősítő kódot elküldtük a következő címre: <p> {destination}. </p> </p> <p> Kérjük, írja be az alábbi PIN-kódot. </p>",twofaResendMessage:"Nem kapta meg a megerősítő kódot?",twofaResendButton:"Újraküldés"},hr:{dateError:"Odabrani datum treba biti između {min} i {max}",dateError2:"Odabrani datum nije unutar prihvaćenog raspona",dateFormatError:"Odabrani datum je u drugačijem formatu od potrebnog.",numberLengthError:"Broj bi trebao biti između {min} i {max}",lengthError:"Duljina bi trebala biti između {minLength} i {maxLength}",requiredError:"Ovaj unos je obavezan.",invalidOriginalPasswordError:"Lozinke se ne podudaraju",invalidPassword:"Lozinka ne zadovoljava sve kriterije",passwordStrength:"Lozinka",passwordStrengthWeak:"nije dovoljno jaka",passwordStrengthStrong:"je dovoljno jaka",SpecialCharactersNotAllowed:"Ne smije sadržavati posebne znakove",InvalidEmailFormat:"Nevažeći format e-maila",EmailNotMatching:"E-mailovi se ne podudaraju!",PasswordNotMatching:"Lozinke se ne podudaraju",MustIncludeNumber:"Lozinka mora sadržavati broj",MustContainCapital:"Lozinka mora sadržavati veliko slovo",MustIncludePunctation:"Lozinka mora sadržavati barem jedan znak",OnlyNumbers:"Smije sadržavati samo znamenke.",InvalidFieldSize:"Dužina mora biti točno 11 znamenki.",InvalidDocumentNumber:"Dopušteni su samo numerički znakovi.",twofaDescription:"<p> Poslali smo verifikacijski kod na: <p> {destination}. </p> </p> <p> Molimo unesite PIN ispod. </p>",twofaResendMessage:"Niste primili verifikacijski kod?",twofaResendButton:"Ponovno pošalji"},tr:{dateError:"Seçilen tarih {min} ve {max} arasında olmalıdır",dateError2:"Seçilen tarih kabul edilen aralıkta değil",dateFormatError:"Seçilen tarihin formatı, gereken formattan farklı.",numberLengthError:"Sayı {min} ve {max} arasında olmalıdır",lengthError:"Uzunluk {minLength} ve {maxLength} arasında olmalıdır",requiredError:"Bu alan zorunludur.",invalidOriginalPasswordError:"İlk şifre alanı tüm kriterleri karşılamıyor.",invalidPassword:"Şifre tüm kriterleri karşılamıyor",passwordStrength:"Şifre gücü",passwordStrengthWeak:"yetersiz",passwordStrengthStrong:"yeterli",SpecialCharactersNotAllowed:"Özel karakter içermemelidir",InvalidEmailFormat:"Geçersiz e-posta formatı.",EmailNotMatching:"E-postalar uyuşmuyor!",PasswordNotMatching:"Şifreler uyuşmuyor",MustIncludeNumber:"bir sayı içermelidir",MustContainCapital:"büyük harf içermelidir",MustIncludePunctation:"noktalama işareti içermelidir",OnlyNumbers:"Yalnızca rakamlar içermelidir.",InvalidFieldSize:"Uzunluk tam olarak 11 rakam olmalıdır.",InvalidDocumentNumber:"Sadece sayısal karakterlere izin verilir.",twofaDescription:"<p> Doğrulama kodunu şu adrese gönderdik: <p> {destination}. </p> </p> <p> Lütfen aşağıya PIN kodunu girin. </p>",twofaResendMessage:"Doğrulama kodunu almadınız mı?",twofaResendButton:"Yeniden gönder"},"pt-br":{dateError:"A data selecionada deve estar entre {min} e {max}",dateError2:"A data selecionada não está dentro de um intervalo válido",dateFormatError:"A data selecionada está em um formato diferente do exigido.",numberLengthError:"O número deve estar entre {min} e {max}",lengthError:"O comprimento deve estar entre {minLength} e {maxLength}",requiredError:"Este campo é obrigatório",invalidOriginalPasswordError:"O campo de senha inicial não faz parte dos critérios válidos",invalidPassword:"A senha não atende a todos os critérios",PasswordStrength:"Força da senha",PasswordStrengthWeak:"Não é adequado",PasswordStrengthStrong:"é apropriado",SpecialCharactersNotAllowed:"Não deve conter caracteres especiais",InvalidEmailFormat:"Formato de email inválido",EmailNotMatching:"E-mail não corresponde",PasswordNotMatching:"Senha não corresponde",MustIncludeNumber:"A senha deve incluir um número",MustContainCapital:"A senha deve incluir uma letra maiúscula",MustIncludePunctation:"A senha deve incluir um sinal de pontuação",OnlyNumbers:"Deve conter apenas dígitos.",InvalidFieldSize:"O comprimento deve ser exatamente 11 dígitos.",InvalidDocumentNumber:"Apenas caracteres numéricos são permitidos.",twofaDescription:"<p> Enviamos o código de verificação para: <p> {destination}. </p> </p> <p> Por favor, insira o PIN abaixo. </p>",twofaResendMessage:"Não recebeu o código de verificação?",twofaResendButton:"Reenviar"},"es-mx":{dateError:"La fecha seleccionada debe ser entre {min} y {max}",dateError2:"La fecha seleccionada no está dentro de un rango válido",dateFormatError:"La fecha seleccionada tiene un formato diferente al requerido.",numberLengthError:"El número debe ser entre {min} y {max}",lengthError:"La longitud deber ser entre {minLength} y {maxLength}",requiredError:"Este campo es requerido",invalidOriginalPasswordError:"El campo de contraseña inicial no es parte del criterio válido",invalidPassword:"La contraseña no cumple con todos los criterios",PasswordStrength:"La fortaleza de la contraseña",PasswordStrengthWeak:"no es adecuada",PasswordStrengthStrong:"es adecuada",SpecialCharactersNotAllowed:"No debe contener caracteres especiales",InvalidEmailFormat:"Formato inválido de correo",EmailNotMatching:"El correo electrónico no coincide",PasswordNotMatching:"La contraseña no coincide",MustIncludeNumber:"La contraseña debe incluir un número",MustContainCapital:"La contraseña debe incluir una letra mayúscula",MustIncludePunctation:"La contraseña debe incluir un signo de puntuación",OnlyNumbers:"Debe contener solo dígitos.",InvalidFieldSize:"La longitud debe ser exactamente de 11 dígitos.",InvalidDocumentNumber:"Solo se permiten caracteres numéricos.",twofaDescription:"<p> Hemos enviado el código de verificación a: <p> {destination}. </p> </p> <p> Por favor, ingrese el PIN a continuación. </p>",twofaResendMessage:"¿No recibiste el código de verificación?",twofaResendButton:"Reenviar"}},n=(t,e,i)=>{let s=r[void 0!==e?e:"en"][t];if(void 0!==i)for(const[t,e]of Object.entries(i.values)){const i=new RegExp(`{${t}}`,"g");s=s.replace(i,e)}return s},a="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTIiIGhlaWdodD0iMTIiIHZpZXdCb3g9IjAgMCAxMiAxMiIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPGNpcmNsZSBjeD0iNiIgY3k9IjYiIHI9IjUuNSIgc3Ryb2tlPSIjOTc5Nzk3Ii8+CjxyZWN0IHg9IjUiIHk9IjUiIHdpZHRoPSIyIiBoZWlnaHQ9IjUiIGZpbGw9IiM5Nzk3OTciLz4KPGNpcmNsZSBjeD0iNiIgY3k9IjMiIHI9IjEiIGZpbGw9IiM5Nzk3OTciLz4KPC9zdmc+Cg==",l=class{constructor(i){t(this,i),this.sendValidityState=e(this,"sendValidityState",7),this.sendInputValue=e(this,"sendInputValue",7),this.value=null,this.setClientStyling=()=>{let t=document.createElement("style");t.innerHTML=this.clientStyling,this.stylingContainer.prepend(t)},this.name=void 0,this.displayName=void 0,this.defaultValue="",this.autofilled=void 0,this.tooltip=void 0,this.options=void 0,this.validation=void 0,this.language=void 0,this.emitValue=void 0,this.clientStyling="",this.errorMessage=void 0,this.isValid=void 0,this.limitStylingAppends=!1,this.showTooltip=!1,this.selectedValues=[],this.showCheckboxes=!1}handleStylingChange(t,e){t!==e&&this.setClientStyling()}validityChanged(){this.validityStateHandler({valid:this.isValid,name:this.name}),1==this.emitValue&&this.valueHandler({name:this.name,value:this.value,type:"checkboxgroup"})}setValue(){this.value=this.options.reduce(((t,e)=>(t[e.name]=this.selectedValues.includes(e.name),t)),{}),this.emitValueHandler(!0)}validityStateHandler(t){this.sendValidityState.emit(t)}emitValueHandler(t){1==t&&this.isValid&&this.valueHandler({name:this.name,value:this.value,type:"checkboxgroup"})}valueHandler(t){this.sendInputValue.emit(t)}handleClickOutside(t){t.composedPath()[0]!==this.tooltipIconReference&&t.composedPath()[0]!==this.tooltipReference&&(this.showTooltip=!1)}componentDidRender(){!this.limitStylingAppends&&this.stylingContainer&&(this.clientStyling&&this.setClientStyling(),this.limitStylingAppends=!0)}componentDidLoad(){this.inputReference=this.element.shadowRoot.querySelector("input"),this.isValid=this.setValidity(),this.defaultValue&&(this.showCheckboxes=!0,this.selectedValues=this.options.map((t=>t.name)),this.value=this.defaultValue,this.valueHandler({name:this.name,value:this.value}))}setValidity(){return this.inputReference.validity.valid}setErrorMessage(){if(this.inputReference.validity.valueMissing)return n("requiredError",this.language)}renderTooltip(){return this.showTooltip?i("div",{class:"checkboxgroup__tooltip "+(this.showTooltip?"visible":""),ref:t=>this.tooltipReference=t,innerHTML:this.tooltip}):null}handleParentCheckbox(t){const e=t.target.checked;this.showCheckboxes=e,this.selectedValues=e?this.options.map((t=>t.name)):[]}renderLabel(){return i("label",{class:"checkbox__label",htmlFor:`${this.name}__input`,slot:"label"},i("div",{class:"checkbox__label-text",innerHTML:`${this.displayName} ${this.validation.mandatory?"*":""}`}))}render(){return i("div",{key:"2eab716c27576d42a67d791b546022d58e89e21d",class:`checkboxgroup__wrapper ${this.name}__input`,ref:t=>this.stylingContainer=t},i("div",{key:"9e246685583dd06a156d6b11308b2cb355d37d01",class:"checkboxgroup__wrapper--flex"},i("vaadin-checkbox",{key:"ba6a64bdd1d1141407ed65213684d3b4d643effc",class:"checkbox__input",checked:this.selectedValues.length===this.options.length||"true"===this.defaultValue,indeterminate:this.selectedValues.length>0&&this.selectedValues.length<this.options.length,onChange:t=>this.handleParentCheckbox(t)},this.renderLabel()),this.tooltip&&i("img",{key:"2c23ca2dfe4213d9287958b5e6f09f76e9e3b031",class:"checkboxgroup__tooltip-icon",src:a,alt:"",ref:t=>this.tooltipIconReference=t,onClick:()=>this.showTooltip=!this.showTooltip}),this.renderTooltip()),i("small",{key:"3180a35a47e4b57d8634da2f516d0c5c71ee0e9f",class:"checkboxgroup__error-message"},this.errorMessage),this.showCheckboxes&&i("vaadin-checkbox-group",{key:"b28fee432aa7bffe6aedf708f1ce9603a52833de",theme:"vertical",value:this.selectedValues,"on-value-changed":t=>{this.selectedValues=t.detail.value}},this.options.map((t=>i("vaadin-checkbox",{class:"checkbox__input",name:t.name,value:t.name,label:t.displayName})))))}get element(){return s(this)}static get watchers(){return{clientStyling:["handleStylingChange"],isValid:["validityChanged"],selectedValues:["setValue"],emitValue:["emitValueHandler"]}}};l.style='*,*::before,*::after{padding:0;margin:0;box-sizing:border-box}vaadin-checkbox-group{margin-top:5px;margin-left:40px}.checkboxgroup{font-family:"Roboto";font-style:normal;font-size:15px}.checkboxgroup__wrapper{position:relative}.checkboxgroup__wrapper--flex{display:flex;gap:5px;align-content:flex-start}.checkboxgroup__wrapper--relative{position:relative;display:inline}.checkboxgroup__input{vertical-align:baseline}.checkboxgroup__input[indeterminate]::part(checkbox)::after,.checkboxgroup__input[indeterminate]::part(checkbox),.checkboxgroup__input[checked]::part(checkbox){background-color:var(--emw--login-color-primary, var(--emw--color-primary, #22B04E))}.checkboxgroup__label{font-style:inherit;font-family:inherit;font-weight:400;font-size:16px;color:var(--emw--registration-typography, var(--emw--color-black, #000000));line-height:1.5;padding-left:10px;vertical-align:baseline}.checkboxgroup__label-text{font-size:16px}.checkboxgroup__label a{color:var(--emw--login-color-primary, var(--emw--color-primary, #22B04E))}.checkboxgroup__error-message{position:absolute;top:calc(100% + 5px);left:0;color:var(--emw--color-error, var(--emw--color-red, #ed0909))}.checkboxgroup__tooltip-icon{width:16px;height:auto}.checkboxgroup__tooltip{position:absolute;top:0;right:0;background-color:var(--emw--color-white, #FFFFFF);border:1px solid var(--emw--color-gray-100, #E6E6E6);color:var(--emw--registration-typography, var(--emw--color-black, #000000));padding:10px;border-radius:5px;opacity:0;transition:opacity 0.3s ease-in-out;z-index:10}.checkboxgroup__tooltip.visible{opacity:1}.checkbox__input::part(checkbox){background-color:var(--emw--color-white, #FFFFFF);transform:scale(0.8, 0.8);border-radius:var(--emw--border-radius-small, 2px);box-shadow:0 0px 0px 2px var(--emw--color-gray, #7a7a7a)}.checkbox__input[indeterminate]::part(checkbox),.checkbox__input[checked]::part(checkbox){background-color:var(--emw--login-color-primary, var(--emw--color-primary, #22B04E));box-shadow:none}';const h=class{constructor(i){t(this,i),this.sendValidityState=e(this,"sendValidityState",7),this.sendInputValue=e(this,"sendInputValue",7),this.value="",this.setClientStyling=()=>{let t=document.createElement("style");t.innerHTML=this.clientStyling,this.stylingContainer.prepend(t)},this.name=void 0,this.displayName=void 0,this.defaultValue="",this.autofilled=void 0,this.tooltip=void 0,this.validation=void 0,this.language=void 0,this.emitValue=void 0,this.clientStyling="",this.errorMessage=void 0,this.isValid=void 0,this.limitStylingAppends=!1,this.showTooltip=!1}handleStylingChange(t,e){t!==e&&this.setClientStyling()}validityChanged(){this.validityStateHandler({valid:this.isValid,name:this.name}),1==this.emitValue&&this.valueHandler({name:this.name,value:this.value})}validityStateHandler(t){this.sendValidityState.emit(t)}emitValueHandler(t){1==t&&this.isValid&&this.valueHandler({name:this.name,value:this.value})}valueHandler(t){this.sendInputValue.emit(t)}handleClickOutside(t){t.composedPath()[0]!==this.tooltipIconReference&&t.composedPath()[0]!==this.tooltipReference&&(this.showTooltip=!1)}componentDidRender(){!this.limitStylingAppends&&this.stylingContainer&&(this.clientStyling&&this.setClientStyling(),this.limitStylingAppends=!0)}componentDidLoad(){this.inputReference=this.vaadinCheckbox.querySelector("input"),this.defaultValue&&(this.value=this.defaultValue,this.valueHandler({name:this.name,value:this.value}))}handleCheckbox(t){this.value=t.target.checked.toString(),this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage(),this.emitValueHandler(!0)}setValidity(){return this.inputReference.validity.valid}setErrorMessage(){if(this.inputReference.validity.valueMissing)return n("requiredError",this.language)}renderLabel(){return i("label",{class:"checkbox__label",htmlFor:`${this.name}__input`,slot:"label"},i("div",{class:"checkbox__label-text",innerHTML:`${this.displayName} ${this.validation.mandatory?"*":""}`}))}renderTooltip(){return this.showTooltip?i("div",{class:"checkbox__tooltip "+(this.showTooltip?"visible":""),ref:t=>this.tooltipReference=t,innerHTML:this.tooltip}):null}render(){return i("div",{key:"e9dfb4e2a6b99d740eaa7d94d1ff3aea9587bcc9",class:`checkbox__wrapper ${this.name}__input`,ref:t=>this.stylingContainer=t},i("vaadin-checkbox",{key:"cc2a8d1c131bd04febf221538f01d7334169d92a",class:"checkbox__input",required:this.validation.mandatory,checked:"true"===this.defaultValue,onChange:t=>this.handleCheckbox(t),"error-message":!this.isValid&&this.errorMessage,ref:t=>this.vaadinCheckbox=t},this.renderLabel()),this.tooltip&&i("img",{key:"a94be7eefe15593f0cfa90d89bed1f536bd51103",class:"checkboxgroup__tooltip-icon",src:a,alt:"",ref:t=>this.tooltipIconReference=t,onClick:()=>this.showTooltip=!this.showTooltip}),this.renderTooltip())}static get watchers(){return{clientStyling:["handleStylingChange"],isValid:["validityChanged"],emitValue:["emitValueHandler"]}}};function d(t){return d="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},d(t)}function c(t,e){if(e.length<t)throw new TypeError(t+" argument"+(t>1?"s":"")+" required, but only "+e.length+" present")}function u(t){c(1,arguments);var e=Object.prototype.toString.call(t);return t instanceof Date||"object"===d(t)&&"[object Date]"===e?new Date(t.getTime()):"number"==typeof t||"[object Number]"===e?new Date(t):("string"!=typeof t&&"[object String]"!==e||"undefined"==typeof console||(console.warn("Starting with v2.0.0-beta.1 date-fns doesn't accept strings as date arguments. Please use `parseISO` to parse strings. See: https://github.com/date-fns/date-fns/blob/master/docs/upgradeGuide.md#string-arguments"),console.warn((new Error).stack)),new Date(NaN))}function p(t){if(c(1,arguments),!function(t){return c(1,arguments),t instanceof Date||"object"===d(t)&&"[object Date]"===Object.prototype.toString.call(t)}(t)&&"number"!=typeof t)return!1;var e=u(t);return!isNaN(Number(e))}function m(t){if(null===t||!0===t||!1===t)return NaN;var e=Number(t);return isNaN(e)?e:e<0?Math.ceil(e):Math.floor(e)}function v(t,e){return c(2,arguments),function(t,e){c(2,arguments);var i=u(t).getTime(),s=m(e);return new Date(i+s)}(t,-m(e))}function f(t){c(1,arguments);var e=u(t),i=e.getUTCDay(),s=(i<1?7:0)+i-1;return e.setUTCDate(e.getUTCDate()-s),e.setUTCHours(0,0,0,0),e}function g(t){c(1,arguments);var e=u(t),i=e.getUTCFullYear(),s=new Date(0);s.setUTCFullYear(i+1,0,4),s.setUTCHours(0,0,0,0);var o=f(s),r=new Date(0);r.setUTCFullYear(i,0,4),r.setUTCHours(0,0,0,0);var n=f(r);return e.getTime()>=o.getTime()?i+1:e.getTime()>=n.getTime()?i:i-1}h.style='*,*::before,*::after{padding:0;margin:0;box-sizing:border-box}.checkbox{font-family:"Roboto";font-style:normal;font-size:15px}.checkbox__wrapper{display:flex;gap:10px;position:relative;align-items:baseline}.checkbox__wrapper--relative{position:relative}.checkbox__input[indeterminate]::part(checkbox)::after,.checkbox__input[indeterminate]::part(checkbox),.checkbox__input[checked]::part(checkbox){background-color:var(--emw--login-color-primary, var(--emw--color-primary, #22B04E))}.checkbox__label{font-style:inherit;font-family:inherit;font-weight:400;font-size:16px;color:var(--emw--registration-typography, var(--emw--color-black, #000000));line-height:1.5;padding:0px;vertical-align:baseline}.checkbox__label a{color:var(--emw--login-color-primary, var(--emw--color-primary, #22B04E))}.checkbox__error-message{position:absolute;top:calc(100% + 5px);left:0;color:var(--emw--color-error, var(--emw--color-red, #ed0909))}.checkbox__tooltip-icon{width:16px;height:auto}.checkbox__tooltip{position:absolute;top:0;right:20px;background-color:var(--emw--color-white, #FFFFFF);border:1px solid var(--emw--color-gray-100, #E6E6E6);color:var(--emw--registration-typography, var(--emw--color-black, #000000));padding:10px;border-radius:5px;opacity:0;transition:opacity 0.3s ease-in-out;z-index:10}.checkbox__tooltip.visible{opacity:1}.checkbox__input::part(checkbox){background-color:var(--emw--color-white, #FFFFFF);transform:scale(0.8, 0.8);border-radius:var(--emw--border-radius-small, 2px);box-shadow:0 0px 0px 2px var(--emw--color-gray, #7a7a7a)}.checkbox__input::part(required-indicator)::after{content:"*"}.checkbox__input[indeterminate]::part(checkbox),.checkbox__input[checked]::part(checkbox){background-color:var(--emw--login-color-primary, var(--emw--color-primary, #22B04E));box-shadow:none}';function b(t){c(1,arguments);var e=u(t),i=f(e).getTime()-function(t){c(1,arguments);var e=g(t),i=new Date(0);return i.setUTCFullYear(e,0,4),i.setUTCHours(0,0,0,0),f(i)}(e).getTime();return Math.round(i/6048e5)+1}var y={};function w(){return y}function _(t,e){var i,s,o,r,n,a,l,h;c(1,arguments);var d=w(),p=m(null!==(i=null!==(s=null!==(o=null!==(r=null==e?void 0:e.weekStartsOn)&&void 0!==r?r:null==e||null===(n=e.locale)||void 0===n||null===(a=n.options)||void 0===a?void 0:a.weekStartsOn)&&void 0!==o?o:d.weekStartsOn)&&void 0!==s?s:null===(l=d.locale)||void 0===l||null===(h=l.options)||void 0===h?void 0:h.weekStartsOn)&&void 0!==i?i:0);if(!(p>=0&&p<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var v=u(t),f=v.getUTCDay(),g=(f<p?7:0)+f-p;return v.setUTCDate(v.getUTCDate()-g),v.setUTCHours(0,0,0,0),v}function x(t,e){var i,s,o,r,n,a,l,h;c(1,arguments);var d=u(t),p=d.getUTCFullYear(),v=w(),f=m(null!==(i=null!==(s=null!==(o=null!==(r=null==e?void 0:e.firstWeekContainsDate)&&void 0!==r?r:null==e||null===(n=e.locale)||void 0===n||null===(a=n.options)||void 0===a?void 0:a.firstWeekContainsDate)&&void 0!==o?o:v.firstWeekContainsDate)&&void 0!==s?s:null===(l=v.locale)||void 0===l||null===(h=l.options)||void 0===h?void 0:h.firstWeekContainsDate)&&void 0!==i?i:1);if(!(f>=1&&f<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var g=new Date(0);g.setUTCFullYear(p+1,0,f),g.setUTCHours(0,0,0,0);var b=_(g,e),y=new Date(0);y.setUTCFullYear(p,0,f),y.setUTCHours(0,0,0,0);var x=_(y,e);return d.getTime()>=b.getTime()?p+1:d.getTime()>=x.getTime()?p:p-1}function k(t,e){c(1,arguments);var i=u(t),s=_(i,e).getTime()-function(t,e){var i,s,o,r,n,a,l,h;c(1,arguments);var d=w(),u=m(null!==(i=null!==(s=null!==(o=null!==(r=null==e?void 0:e.firstWeekContainsDate)&&void 0!==r?r:null==e||null===(n=e.locale)||void 0===n||null===(a=n.options)||void 0===a?void 0:a.firstWeekContainsDate)&&void 0!==o?o:d.firstWeekContainsDate)&&void 0!==s?s:null===(l=d.locale)||void 0===l||null===(h=l.options)||void 0===h?void 0:h.firstWeekContainsDate)&&void 0!==i?i:1),p=x(t,e),v=new Date(0);return v.setUTCFullYear(p,0,u),v.setUTCHours(0,0,0,0),_(v,e)}(i,e).getTime();return Math.round(s/6048e5)+1}function C(t,e){for(var i=t<0?"-":"",s=Math.abs(t).toString();s.length<e;)s="0"+s;return i+s}const A=function(t,e){var i=t.getUTCFullYear(),s=i>0?i:1-i;return C("yy"===e?s%100:s,e.length)},S=function(t,e){var i=t.getUTCMonth();return"M"===e?String(i+1):C(i+1,2)},z=function(t,e){return C(t.getUTCDate(),e.length)},I=function(t,e){return C(t.getUTCHours()%12||12,e.length)},E=function(t,e){return C(t.getUTCHours(),e.length)},T=function(t,e){return C(t.getUTCMinutes(),e.length)},M=function(t,e){return C(t.getUTCSeconds(),e.length)},D=function(t,e){var i=e.length,s=t.getUTCMilliseconds();return C(Math.floor(s*Math.pow(10,i-3)),e.length)};function O(t,e){var i=t>0?"-":"+",s=Math.abs(t),o=Math.floor(s/60),r=s%60;if(0===r)return i+String(o);var n=e||"";return i+String(o)+n+C(r,2)}function P(t,e){return t%60==0?(t>0?"-":"+")+C(Math.abs(t)/60,2):F(t,e)}function F(t,e){var i=e||"",s=t>0?"-":"+",o=Math.abs(t);return s+C(Math.floor(o/60),2)+i+C(o%60,2)}const N={G:function(t,e,i){var s=t.getUTCFullYear()>0?1:0;switch(e){case"G":case"GG":case"GGG":return i.era(s,{width:"abbreviated"});case"GGGGG":return i.era(s,{width:"narrow"});default:return i.era(s,{width:"wide"})}},y:function(t,e,i){if("yo"===e){var s=t.getUTCFullYear();return i.ordinalNumber(s>0?s:1-s,{unit:"year"})}return A(t,e)},Y:function(t,e,i,s){var o=x(t,s),r=o>0?o:1-o;return"YY"===e?C(r%100,2):"Yo"===e?i.ordinalNumber(r,{unit:"year"}):C(r,e.length)},R:function(t,e){return C(g(t),e.length)},u:function(t,e){return C(t.getUTCFullYear(),e.length)},Q:function(t,e,i){var s=Math.ceil((t.getUTCMonth()+1)/3);switch(e){case"Q":return String(s);case"QQ":return C(s,2);case"Qo":return i.ordinalNumber(s,{unit:"quarter"});case"QQQ":return i.quarter(s,{width:"abbreviated",context:"formatting"});case"QQQQQ":return i.quarter(s,{width:"narrow",context:"formatting"});default:return i.quarter(s,{width:"wide",context:"formatting"})}},q:function(t,e,i){var s=Math.ceil((t.getUTCMonth()+1)/3);switch(e){case"q":return String(s);case"qq":return C(s,2);case"qo":return i.ordinalNumber(s,{unit:"quarter"});case"qqq":return i.quarter(s,{width:"abbreviated",context:"standalone"});case"qqqqq":return i.quarter(s,{width:"narrow",context:"standalone"});default:return i.quarter(s,{width:"wide",context:"standalone"})}},M:function(t,e,i){var s=t.getUTCMonth();switch(e){case"M":case"MM":return S(t,e);case"Mo":return i.ordinalNumber(s+1,{unit:"month"});case"MMM":return i.month(s,{width:"abbreviated",context:"formatting"});case"MMMMM":return i.month(s,{width:"narrow",context:"formatting"});default:return i.month(s,{width:"wide",context:"formatting"})}},L:function(t,e,i){var s=t.getUTCMonth();switch(e){case"L":return String(s+1);case"LL":return C(s+1,2);case"Lo":return i.ordinalNumber(s+1,{unit:"month"});case"LLL":return i.month(s,{width:"abbreviated",context:"standalone"});case"LLLLL":return i.month(s,{width:"narrow",context:"standalone"});default:return i.month(s,{width:"wide",context:"standalone"})}},w:function(t,e,i,s){var o=k(t,s);return"wo"===e?i.ordinalNumber(o,{unit:"week"}):C(o,e.length)},I:function(t,e,i){var s=b(t);return"Io"===e?i.ordinalNumber(s,{unit:"week"}):C(s,e.length)},d:function(t,e,i){return"do"===e?i.ordinalNumber(t.getUTCDate(),{unit:"date"}):z(t,e)},D:function(t,e,i){var s=function(t){c(1,arguments);var e=u(t),i=e.getTime();e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0);var s=e.getTime();return Math.floor((i-s)/864e5)+1}(t);return"Do"===e?i.ordinalNumber(s,{unit:"dayOfYear"}):C(s,e.length)},E:function(t,e,i){var s=t.getUTCDay();switch(e){case"E":case"EE":case"EEE":return i.day(s,{width:"abbreviated",context:"formatting"});case"EEEEE":return i.day(s,{width:"narrow",context:"formatting"});case"EEEEEE":return i.day(s,{width:"short",context:"formatting"});default:return i.day(s,{width:"wide",context:"formatting"})}},e:function(t,e,i,s){var o=t.getUTCDay(),r=(o-s.weekStartsOn+8)%7||7;switch(e){case"e":return String(r);case"ee":return C(r,2);case"eo":return i.ordinalNumber(r,{unit:"day"});case"eee":return i.day(o,{width:"abbreviated",context:"formatting"});case"eeeee":return i.day(o,{width:"narrow",context:"formatting"});case"eeeeee":return i.day(o,{width:"short",context:"formatting"});default:return i.day(o,{width:"wide",context:"formatting"})}},c:function(t,e,i,s){var o=t.getUTCDay(),r=(o-s.weekStartsOn+8)%7||7;switch(e){case"c":return String(r);case"cc":return C(r,e.length);case"co":return i.ordinalNumber(r,{unit:"day"});case"ccc":return i.day(o,{width:"abbreviated",context:"standalone"});case"ccccc":return i.day(o,{width:"narrow",context:"standalone"});case"cccccc":return i.day(o,{width:"short",context:"standalone"});default:return i.day(o,{width:"wide",context:"standalone"})}},i:function(t,e,i){var s=t.getUTCDay(),o=0===s?7:s;switch(e){case"i":return String(o);case"ii":return C(o,e.length);case"io":return i.ordinalNumber(o,{unit:"day"});case"iii":return i.day(s,{width:"abbreviated",context:"formatting"});case"iiiii":return i.day(s,{width:"narrow",context:"formatting"});case"iiiiii":return i.day(s,{width:"short",context:"formatting"});default:return i.day(s,{width:"wide",context:"formatting"})}},a:function(t,e,i){var s=t.getUTCHours()/12>=1?"pm":"am";switch(e){case"a":case"aa":return i.dayPeriod(s,{width:"abbreviated",context:"formatting"});case"aaa":return i.dayPeriod(s,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return i.dayPeriod(s,{width:"narrow",context:"formatting"});default:return i.dayPeriod(s,{width:"wide",context:"formatting"})}},b:function(t,e,i){var s,o=t.getUTCHours();switch(s=12===o?"noon":0===o?"midnight":o/12>=1?"pm":"am",e){case"b":case"bb":return i.dayPeriod(s,{width:"abbreviated",context:"formatting"});case"bbb":return i.dayPeriod(s,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return i.dayPeriod(s,{width:"narrow",context:"formatting"});default:return i.dayPeriod(s,{width:"wide",context:"formatting"})}},B:function(t,e,i){var s,o=t.getUTCHours();switch(s=o>=17?"evening":o>=12?"afternoon":o>=4?"morning":"night",e){case"B":case"BB":case"BBB":return i.dayPeriod(s,{width:"abbreviated",context:"formatting"});case"BBBBB":return i.dayPeriod(s,{width:"narrow",context:"formatting"});default:return i.dayPeriod(s,{width:"wide",context:"formatting"})}},h:function(t,e,i){if("ho"===e){var s=t.getUTCHours()%12;return 0===s&&(s=12),i.ordinalNumber(s,{unit:"hour"})}return I(t,e)},H:function(t,e,i){return"Ho"===e?i.ordinalNumber(t.getUTCHours(),{unit:"hour"}):E(t,e)},K:function(t,e,i){var s=t.getUTCHours()%12;return"Ko"===e?i.ordinalNumber(s,{unit:"hour"}):C(s,e.length)},k:function(t,e,i){var s=t.getUTCHours();return 0===s&&(s=24),"ko"===e?i.ordinalNumber(s,{unit:"hour"}):C(s,e.length)},m:function(t,e,i){return"mo"===e?i.ordinalNumber(t.getUTCMinutes(),{unit:"minute"}):T(t,e)},s:function(t,e,i){return"so"===e?i.ordinalNumber(t.getUTCSeconds(),{unit:"second"}):M(t,e)},S:function(t,e){return D(t,e)},X:function(t,e,i,s){var o=(s._originalDate||t).getTimezoneOffset();if(0===o)return"Z";switch(e){case"X":return P(o);case"XXXX":case"XX":return F(o);default:return F(o,":")}},x:function(t,e,i,s){var o=(s._originalDate||t).getTimezoneOffset();switch(e){case"x":return P(o);case"xxxx":case"xx":return F(o);default:return F(o,":")}},O:function(t,e,i,s){var o=(s._originalDate||t).getTimezoneOffset();switch(e){case"O":case"OO":case"OOO":return"GMT"+O(o,":");default:return"GMT"+F(o,":")}},z:function(t,e,i,s){var o=(s._originalDate||t).getTimezoneOffset();switch(e){case"z":case"zz":case"zzz":return"GMT"+O(o,":");default:return"GMT"+F(o,":")}},t:function(t,e,i,s){return C(Math.floor((s._originalDate||t).getTime()/1e3),e.length)},T:function(t,e,i,s){return C((s._originalDate||t).getTime(),e.length)}};var B=function(t,e){switch(t){case"P":return e.date({width:"short"});case"PP":return e.date({width:"medium"});case"PPP":return e.date({width:"long"});default:return e.date({width:"full"})}},j=function(t,e){switch(t){case"p":return e.time({width:"short"});case"pp":return e.time({width:"medium"});case"ppp":return e.time({width:"long"});default:return e.time({width:"full"})}},V={p:j,P:function(t,e){var i,s=t.match(/(P+)(p+)?/)||[],o=s[1],r=s[2];if(!r)return B(t,e);switch(o){case"P":i=e.dateTime({width:"short"});break;case"PP":i=e.dateTime({width:"medium"});break;case"PPP":i=e.dateTime({width:"long"});break;default:i=e.dateTime({width:"full"})}return i.replace("{{date}}",B(o,e)).replace("{{time}}",j(r,e))}};const L=V;function R(t){var e=new Date(Date.UTC(t.getFullYear(),t.getMonth(),t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()));return e.setUTCFullYear(t.getFullYear()),t.getTime()-e.getTime()}var q=["D","DD"],$=["YY","YYYY"];function H(t){return-1!==q.indexOf(t)}function W(t){return-1!==$.indexOf(t)}function G(t,e,i){if("YYYY"===t)throw new RangeError("Use `yyyy` instead of `YYYY` (in `".concat(e,"`) for formatting years to the input `").concat(i,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if("YY"===t)throw new RangeError("Use `yy` instead of `YY` (in `".concat(e,"`) for formatting years to the input `").concat(i,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if("D"===t)throw new RangeError("Use `d` instead of `D` (in `".concat(e,"`) for formatting days of the month to the input `").concat(i,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if("DD"===t)throw new RangeError("Use `dd` instead of `DD` (in `".concat(e,"`) for formatting days of the month to the input `").concat(i,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"))}var Y={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}};function U(t){return function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},i=e.width?String(e.width):t.defaultWidth;return t.formats[i]||t.formats[t.defaultWidth]}}var K,Q={date:U({formats:{full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},defaultWidth:"full"}),time:U({formats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},defaultWidth:"full"}),dateTime:U({formats:{full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},defaultWidth:"full"})},J={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"};function X(t){return function(e,i){var s;if("formatting"===(null!=i&&i.context?String(i.context):"standalone")&&t.formattingValues){var o=t.defaultFormattingWidth||t.defaultWidth,r=null!=i&&i.width?String(i.width):o;s=t.formattingValues[r]||t.formattingValues[o]}else{var n=t.defaultWidth,a=null!=i&&i.width?String(i.width):t.defaultWidth;s=t.values[a]||t.values[n]}return s[t.argumentCallback?t.argumentCallback(e):e]}}function Z(t){return function(e){var i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},s=i.width,o=e.match(s&&t.matchPatterns[s]||t.matchPatterns[t.defaultMatchWidth]);if(!o)return null;var r,n=o[0],a=s&&t.parsePatterns[s]||t.parsePatterns[t.defaultParseWidth],l=Array.isArray(a)?function(t){for(var e=0;e<t.length;e++)if(t[e].test(n))return e}(a):function(t){for(var e in t)if(t.hasOwnProperty(e)&&t[e].test(n))return e}(a);return r=t.valueCallback?t.valueCallback(l):l,{value:r=i.valueCallback?i.valueCallback(r):r,rest:e.slice(n.length)}}}const tt={code:"en-US",formatDistance:function(t,e,i){var s,o=Y[t];return s="string"==typeof o?o:1===e?o.one:o.other.replace("{{count}}",e.toString()),null!=i&&i.addSuffix?i.comparison&&i.comparison>0?"in "+s:s+" ago":s},formatLong:Q,formatRelative:function(t){return J[t]},localize:{ordinalNumber:function(t){var e=Number(t),i=e%100;if(i>20||i<10)switch(i%10){case 1:return e+"st";case 2:return e+"nd";case 3:return e+"rd"}return e+"th"},era:X({values:{narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},defaultWidth:"wide"}),quarter:X({values:{narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},defaultWidth:"wide",argumentCallback:function(t){return t-1}}),month:X({values:{narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},defaultWidth:"wide"}),day:X({values:{narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},defaultWidth:"wide"}),dayPeriod:X({values:{narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},defaultWidth:"wide",formattingValues:{narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},defaultFormattingWidth:"wide"})},match:{ordinalNumber:(K={matchPattern:/^(\d+)(th|st|nd|rd)?/i,parsePattern:/\d+/i,valueCallback:function(t){return parseInt(t,10)}},function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=t.match(K.matchPattern);if(!i)return null;var s=i[0],o=t.match(K.parsePattern);if(!o)return null;var r=K.valueCallback?K.valueCallback(o[0]):o[0];return{value:r=e.valueCallback?e.valueCallback(r):r,rest:t.slice(s.length)}}),era:Z({matchPatterns:{narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},defaultMatchWidth:"wide",parsePatterns:{any:[/^b/i,/^(a|c)/i]},defaultParseWidth:"any"}),quarter:Z({matchPatterns:{narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},defaultMatchWidth:"wide",parsePatterns:{any:[/1/i,/2/i,/3/i,/4/i]},defaultParseWidth:"any",valueCallback:function(t){return t+1}}),month:Z({matchPatterns:{narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},defaultParseWidth:"any"}),day:Z({matchPatterns:{narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},defaultParseWidth:"any"}),dayPeriod:Z({matchPatterns:{narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},defaultMatchWidth:"any",parsePatterns:{any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},defaultParseWidth:"any"})},options:{weekStartsOn:0,firstWeekContainsDate:1}};var et=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,it=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,st=/^'([^]*?)'?$/,ot=/''/g,rt=/[a-zA-Z]/;function nt(t,e,i){var s,o,r,n,a,l,h,d,f,g,b,y,_,x,k,C,A,S;c(2,arguments);var z=String(e),I=w(),E=null!==(s=null!==(o=null==i?void 0:i.locale)&&void 0!==o?o:I.locale)&&void 0!==s?s:tt,T=m(null!==(r=null!==(n=null!==(a=null!==(l=null==i?void 0:i.firstWeekContainsDate)&&void 0!==l?l:null==i||null===(h=i.locale)||void 0===h||null===(d=h.options)||void 0===d?void 0:d.firstWeekContainsDate)&&void 0!==a?a:I.firstWeekContainsDate)&&void 0!==n?n:null===(f=I.locale)||void 0===f||null===(g=f.options)||void 0===g?void 0:g.firstWeekContainsDate)&&void 0!==r?r:1);if(!(T>=1&&T<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var M=m(null!==(b=null!==(y=null!==(_=null!==(x=null==i?void 0:i.weekStartsOn)&&void 0!==x?x:null==i||null===(k=i.locale)||void 0===k||null===(C=k.options)||void 0===C?void 0:C.weekStartsOn)&&void 0!==_?_:I.weekStartsOn)&&void 0!==y?y:null===(A=I.locale)||void 0===A||null===(S=A.options)||void 0===S?void 0:S.weekStartsOn)&&void 0!==b?b:0);if(!(M>=0&&M<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(!E.localize)throw new RangeError("locale must contain localize property");if(!E.formatLong)throw new RangeError("locale must contain formatLong property");var D=u(t);if(!p(D))throw new RangeError("Invalid time value");var O=v(D,R(D)),P={firstWeekContainsDate:T,weekStartsOn:M,locale:E,_originalDate:D};return z.match(it).map((function(t){var e=t[0];return"p"===e||"P"===e?(0,L[e])(t,E.formatLong):t})).join("").match(et).map((function(s){if("''"===s)return"'";var o,r,n=s[0];if("'"===n)return(r=(o=s).match(st))?r[1].replace(ot,"'"):o;var a=N[n];if(a)return null!=i&&i.useAdditionalWeekYearTokens||!W(s)||G(s,e,String(t)),null!=i&&i.useAdditionalDayOfYearTokens||!H(s)||G(s,e,String(t)),a(O,s,E.localize,P);if(n.match(rt))throw new RangeError("Format string contains an unescaped latin alphabet character `"+n+"`");return s})).join("")}function at(t,e){(null==e||e>t.length)&&(e=t.length);for(var i=0,s=Array(e);i<e;i++)s[i]=t[i];return s}function lt(t,e){var i="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!i){if(Array.isArray(t)||(i=function(t,e){if(t){if("string"==typeof t)return at(t,e);var i={}.toString.call(t).slice(8,-1);return"Object"===i&&t.constructor&&(i=t.constructor.name),"Map"===i||"Set"===i?Array.from(t):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?at(t,e):void 0}}(t))||e&&t&&"number"==typeof t.length){i&&(t=i);var s=0,o=function(){};return{s:o,n:function(){return s>=t.length?{done:!0}:{done:!1,value:t[s++]}},e:function(t){throw t},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var r,n=!0,a=!1;return{s:function(){i=i.call(t)},n:function(){var t=i.next();return n=t.done,t},e:function(t){a=!0,r=t},f:function(){try{n||null==i.return||i.return()}finally{if(a)throw r}}}}function ht(t,e){if(null==t)throw new TypeError("assign requires that input parameter not be null or undefined");for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&(t[i]=e[i]);return t}function dt(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function ct(t,e){return ct=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},ct(t,e)}function ut(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&ct(t,e)}function pt(t){return pt=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},pt(t)}function mt(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(mt=function(){return!!t})()}function vt(t){var e=mt();return function(){var i,s=pt(t);if(e){var o=pt(this).constructor;i=Reflect.construct(s,arguments,o)}else i=s.apply(this,arguments);return function(t,e){if(e&&("object"==d(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return dt(t)}(this,i)}}function ft(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function gt(t){var e=function(t){if("object"!=d(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var i=e.call(t,"string");if("object"!=d(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==d(e)?e:e+""}function bt(t,e){for(var i=0;i<e.length;i++){var s=e[i];s.enumerable=s.enumerable||!1,s.configurable=!0,"value"in s&&(s.writable=!0),Object.defineProperty(t,gt(s.key),s)}}function yt(t,e,i){return e&&bt(t.prototype,e),i&&bt(t,i),Object.defineProperty(t,"prototype",{writable:!1}),t}function wt(t,e,i){return(e=gt(e))in t?Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[e]=i,t}var _t=function(){function t(){ft(this,t),wt(this,"priority",void 0),wt(this,"subPriority",0)}return yt(t,[{key:"validate",value:function(){return!0}}]),t}(),xt=function(){ut(e,_t);var t=vt(e);function e(i,s,o,r,n){var a;return ft(this,e),(a=t.call(this)).value=i,a.validateValue=s,a.setValue=o,a.priority=r,n&&(a.subPriority=n),a}return yt(e,[{key:"validate",value:function(t,e){return this.validateValue(t,this.value,e)}},{key:"set",value:function(t,e,i){return this.setValue(t,e,this.value,i)}}]),e}(),kt=function(){ut(e,_t);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",10),wt(dt(i),"subPriority",-1),i}return yt(e,[{key:"set",value:function(t,e){if(e.timestampIsSet)return t;var i=new Date(0);return i.setFullYear(t.getUTCFullYear(),t.getUTCMonth(),t.getUTCDate()),i.setHours(t.getUTCHours(),t.getUTCMinutes(),t.getUTCSeconds(),t.getUTCMilliseconds()),i}}]),e}(),Ct=function(){function t(){ft(this,t),wt(this,"incompatibleTokens",void 0),wt(this,"priority",void 0),wt(this,"subPriority",void 0)}return yt(t,[{key:"run",value:function(t,e,i,s){var o=this.parse(t,e,i,s);return o?{setter:new xt(o.value,this.validate,this.set,this.priority,this.subPriority),rest:o.rest}:null}},{key:"validate",value:function(){return!0}}]),t}(),At=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",140),wt(dt(i),"incompatibleTokens",["R","u","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){switch(e){case"G":case"GG":case"GGG":return i.era(t,{width:"abbreviated"})||i.era(t,{width:"narrow"});case"GGGGG":return i.era(t,{width:"narrow"});default:return i.era(t,{width:"wide"})||i.era(t,{width:"abbreviated"})||i.era(t,{width:"narrow"})}}},{key:"set",value:function(t,e,i){return e.era=i,t.setUTCFullYear(i,0,1),t.setUTCHours(0,0,0,0),t}}]),e}(),St=/^(1[0-2]|0?\d)/,zt=/^(3[0-1]|[0-2]?\d)/,It=/^(36[0-6]|3[0-5]\d|[0-2]?\d?\d)/,Et=/^(5[0-3]|[0-4]?\d)/,Tt=/^(2[0-3]|[0-1]?\d)/,Mt=/^(2[0-4]|[0-1]?\d)/,Dt=/^(1[0-1]|0?\d)/,Ot=/^(1[0-2]|0?\d)/,Pt=/^[0-5]?\d/,Ft=/^[0-5]?\d/,Nt=/^\d/,Bt=/^\d{1,2}/,jt=/^\d{1,3}/,Vt=/^\d{1,4}/,Lt=/^-?\d+/,Rt=/^-?\d/,qt=/^-?\d{1,2}/,$t=/^-?\d{1,3}/,Ht=/^-?\d{1,4}/,Wt=/^([+-])(\d{2})(\d{2})?|Z/,Gt=/^([+-])(\d{2})(\d{2})|Z/,Yt=/^([+-])(\d{2})(\d{2})((\d{2}))?|Z/,Ut=/^([+-])(\d{2}):(\d{2})|Z/,Kt=/^([+-])(\d{2}):(\d{2})(:(\d{2}))?|Z/;function Qt(t,e){return t?{value:e(t.value),rest:t.rest}:t}function Jt(t,e){var i=e.match(t);return i?{value:parseInt(i[0],10),rest:e.slice(i[0].length)}:null}function Xt(t,e){var i=e.match(t);return i?"Z"===i[0]?{value:0,rest:e.slice(1)}:{value:("+"===i[1]?1:-1)*(36e5*(i[2]?parseInt(i[2],10):0)+6e4*(i[3]?parseInt(i[3],10):0)+1e3*(i[5]?parseInt(i[5],10):0)),rest:e.slice(i[0].length)}:null}function Zt(t){return Jt(Lt,t)}function te(t,e){switch(t){case 1:return Jt(Nt,e);case 2:return Jt(Bt,e);case 3:return Jt(jt,e);case 4:return Jt(Vt,e);default:return Jt(new RegExp("^\\d{1,"+t+"}"),e)}}function ee(t,e){switch(t){case 1:return Jt(Rt,e);case 2:return Jt(qt,e);case 3:return Jt($t,e);case 4:return Jt(Ht,e);default:return Jt(new RegExp("^-?\\d{1,"+t+"}"),e)}}function ie(t){switch(t){case"morning":return 4;case"evening":return 17;case"pm":case"noon":case"afternoon":return 12;default:return 0}}function se(t,e){var i,s=e>0,o=s?e:1-e;if(o<=50)i=t||100;else{var r=o+50;i=t+100*Math.floor(r/100)-(t>=r%100?100:0)}return s?i:1-i}function oe(t){return t%400==0||t%4==0&&t%100!=0}var re=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",130),wt(dt(i),"incompatibleTokens",["Y","R","u","w","I","i","e","c","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){var s=function(t){return{year:t,isTwoDigitYear:"yy"===e}};switch(e){case"y":return Qt(te(4,t),s);case"yo":return Qt(i.ordinalNumber(t,{unit:"year"}),s);default:return Qt(te(e.length,t),s)}}},{key:"validate",value:function(t,e){return e.isTwoDigitYear||e.year>0}},{key:"set",value:function(t,e,i){var s=t.getUTCFullYear();if(i.isTwoDigitYear){var o=se(i.year,s);return t.setUTCFullYear(o,0,1),t.setUTCHours(0,0,0,0),t}return t.setUTCFullYear("era"in e&&1!==e.era?1-i.year:i.year,0,1),t.setUTCHours(0,0,0,0),t}}]),e}(),ne=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",130),wt(dt(i),"incompatibleTokens",["y","R","u","Q","q","M","L","I","d","D","i","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){var s=function(t){return{year:t,isTwoDigitYear:"YY"===e}};switch(e){case"Y":return Qt(te(4,t),s);case"Yo":return Qt(i.ordinalNumber(t,{unit:"year"}),s);default:return Qt(te(e.length,t),s)}}},{key:"validate",value:function(t,e){return e.isTwoDigitYear||e.year>0}},{key:"set",value:function(t,e,i,s){var o=x(t,s);if(i.isTwoDigitYear){var r=se(i.year,o);return t.setUTCFullYear(r,0,s.firstWeekContainsDate),t.setUTCHours(0,0,0,0),_(t,s)}return t.setUTCFullYear("era"in e&&1!==e.era?1-i.year:i.year,0,s.firstWeekContainsDate),t.setUTCHours(0,0,0,0),_(t,s)}}]),e}(),ae=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",130),wt(dt(i),"incompatibleTokens",["G","y","Y","u","Q","q","M","L","w","d","D","e","c","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e){return ee("R"===e?4:e.length,t)}},{key:"set",value:function(t,e,i){var s=new Date(0);return s.setUTCFullYear(i,0,4),s.setUTCHours(0,0,0,0),f(s)}}]),e}(),le=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",130),wt(dt(i),"incompatibleTokens",["G","y","Y","R","w","I","i","e","c","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e){return ee("u"===e?4:e.length,t)}},{key:"set",value:function(t,e,i){return t.setUTCFullYear(i,0,1),t.setUTCHours(0,0,0,0),t}}]),e}(),he=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",120),wt(dt(i),"incompatibleTokens",["Y","R","q","M","L","w","I","d","D","i","e","c","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){switch(e){case"Q":case"QQ":return te(e.length,t);case"Qo":return i.ordinalNumber(t,{unit:"quarter"});case"QQQ":return i.quarter(t,{width:"abbreviated",context:"formatting"})||i.quarter(t,{width:"narrow",context:"formatting"});case"QQQQQ":return i.quarter(t,{width:"narrow",context:"formatting"});default:return i.quarter(t,{width:"wide",context:"formatting"})||i.quarter(t,{width:"abbreviated",context:"formatting"})||i.quarter(t,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(t,e){return e>=1&&e<=4}},{key:"set",value:function(t,e,i){return t.setUTCMonth(3*(i-1),1),t.setUTCHours(0,0,0,0),t}}]),e}(),de=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",120),wt(dt(i),"incompatibleTokens",["Y","R","Q","M","L","w","I","d","D","i","e","c","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){switch(e){case"q":case"qq":return te(e.length,t);case"qo":return i.ordinalNumber(t,{unit:"quarter"});case"qqq":return i.quarter(t,{width:"abbreviated",context:"standalone"})||i.quarter(t,{width:"narrow",context:"standalone"});case"qqqqq":return i.quarter(t,{width:"narrow",context:"standalone"});default:return i.quarter(t,{width:"wide",context:"standalone"})||i.quarter(t,{width:"abbreviated",context:"standalone"})||i.quarter(t,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(t,e){return e>=1&&e<=4}},{key:"set",value:function(t,e,i){return t.setUTCMonth(3*(i-1),1),t.setUTCHours(0,0,0,0),t}}]),e}(),ce=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"incompatibleTokens",["Y","R","q","Q","L","w","I","D","i","e","c","t","T"]),wt(dt(i),"priority",110),i}return yt(e,[{key:"parse",value:function(t,e,i){var s=function(t){return t-1};switch(e){case"M":return Qt(Jt(St,t),s);case"MM":return Qt(te(2,t),s);case"Mo":return Qt(i.ordinalNumber(t,{unit:"month"}),s);case"MMM":return i.month(t,{width:"abbreviated",context:"formatting"})||i.month(t,{width:"narrow",context:"formatting"});case"MMMMM":return i.month(t,{width:"narrow",context:"formatting"});default:return i.month(t,{width:"wide",context:"formatting"})||i.month(t,{width:"abbreviated",context:"formatting"})||i.month(t,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(t,e){return e>=0&&e<=11}},{key:"set",value:function(t,e,i){return t.setUTCMonth(i,1),t.setUTCHours(0,0,0,0),t}}]),e}(),ue=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",110),wt(dt(i),"incompatibleTokens",["Y","R","q","Q","M","w","I","D","i","e","c","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){var s=function(t){return t-1};switch(e){case"L":return Qt(Jt(St,t),s);case"LL":return Qt(te(2,t),s);case"Lo":return Qt(i.ordinalNumber(t,{unit:"month"}),s);case"LLL":return i.month(t,{width:"abbreviated",context:"standalone"})||i.month(t,{width:"narrow",context:"standalone"});case"LLLLL":return i.month(t,{width:"narrow",context:"standalone"});default:return i.month(t,{width:"wide",context:"standalone"})||i.month(t,{width:"abbreviated",context:"standalone"})||i.month(t,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(t,e){return e>=0&&e<=11}},{key:"set",value:function(t,e,i){return t.setUTCMonth(i,1),t.setUTCHours(0,0,0,0),t}}]),e}(),pe=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",100),wt(dt(i),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","i","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){switch(e){case"w":return Jt(Et,t);case"wo":return i.ordinalNumber(t,{unit:"week"});default:return te(e.length,t)}}},{key:"validate",value:function(t,e){return e>=1&&e<=53}},{key:"set",value:function(t,e,i,s){return _(function(t,e,i){c(2,arguments);var s=u(t),o=m(e),r=k(s,i)-o;return s.setUTCDate(s.getUTCDate()-7*r),s}(t,i,s),s)}}]),e}(),me=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",100),wt(dt(i),"incompatibleTokens",["y","Y","u","q","Q","M","L","w","d","D","e","c","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){switch(e){case"I":return Jt(Et,t);case"Io":return i.ordinalNumber(t,{unit:"week"});default:return te(e.length,t)}}},{key:"validate",value:function(t,e){return e>=1&&e<=53}},{key:"set",value:function(t,e,i){return f(function(t,e){c(2,arguments);var i=u(t),s=m(e),o=b(i)-s;return i.setUTCDate(i.getUTCDate()-7*o),i}(t,i))}}]),e}(),ve=[31,28,31,30,31,30,31,31,30,31,30,31],fe=[31,29,31,30,31,30,31,31,30,31,30,31],ge=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",90),wt(dt(i),"subPriority",1),wt(dt(i),"incompatibleTokens",["Y","R","q","Q","w","I","D","i","e","c","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){switch(e){case"d":return Jt(zt,t);case"do":return i.ordinalNumber(t,{unit:"date"});default:return te(e.length,t)}}},{key:"validate",value:function(t,e){var i=oe(t.getUTCFullYear()),s=t.getUTCMonth();return i?e>=1&&e<=fe[s]:e>=1&&e<=ve[s]}},{key:"set",value:function(t,e,i){return t.setUTCDate(i),t.setUTCHours(0,0,0,0),t}}]),e}(),be=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",90),wt(dt(i),"subpriority",1),wt(dt(i),"incompatibleTokens",["Y","R","q","Q","M","L","w","I","d","E","i","e","c","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){switch(e){case"D":case"DD":return Jt(It,t);case"Do":return i.ordinalNumber(t,{unit:"date"});default:return te(e.length,t)}}},{key:"validate",value:function(t,e){return oe(t.getUTCFullYear())?e>=1&&e<=366:e>=1&&e<=365}},{key:"set",value:function(t,e,i){return t.setUTCMonth(0,i),t.setUTCHours(0,0,0,0),t}}]),e}();function ye(t,e,i){var s,o,r,n,a,l,h,d;c(2,arguments);var p=w(),v=m(null!==(s=null!==(o=null!==(r=null!==(n=null==i?void 0:i.weekStartsOn)&&void 0!==n?n:null==i||null===(a=i.locale)||void 0===a||null===(l=a.options)||void 0===l?void 0:l.weekStartsOn)&&void 0!==r?r:p.weekStartsOn)&&void 0!==o?o:null===(h=p.locale)||void 0===h||null===(d=h.options)||void 0===d?void 0:d.weekStartsOn)&&void 0!==s?s:0);if(!(v>=0&&v<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var f=u(t),g=m(e),b=((g%7+7)%7<v?7:0)+g-f.getUTCDay();return f.setUTCDate(f.getUTCDate()+b),f}var we=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",90),wt(dt(i),"incompatibleTokens",["D","i","e","c","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){switch(e){case"E":case"EE":case"EEE":return i.day(t,{width:"abbreviated",context:"formatting"})||i.day(t,{width:"short",context:"formatting"})||i.day(t,{width:"narrow",context:"formatting"});case"EEEEE":return i.day(t,{width:"narrow",context:"formatting"});case"EEEEEE":return i.day(t,{width:"short",context:"formatting"})||i.day(t,{width:"narrow",context:"formatting"});default:return i.day(t,{width:"wide",context:"formatting"})||i.day(t,{width:"abbreviated",context:"formatting"})||i.day(t,{width:"short",context:"formatting"})||i.day(t,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(t,e){return e>=0&&e<=6}},{key:"set",value:function(t,e,i,s){return(t=ye(t,i,s)).setUTCHours(0,0,0,0),t}}]),e}(),_e=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",90),wt(dt(i),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","E","i","c","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i,s){var o=function(t){var e=7*Math.floor((t-1)/7);return(t+s.weekStartsOn+6)%7+e};switch(e){case"e":case"ee":return Qt(te(e.length,t),o);case"eo":return Qt(i.ordinalNumber(t,{unit:"day"}),o);case"eee":return i.day(t,{width:"abbreviated",context:"formatting"})||i.day(t,{width:"short",context:"formatting"})||i.day(t,{width:"narrow",context:"formatting"});case"eeeee":return i.day(t,{width:"narrow",context:"formatting"});case"eeeeee":return i.day(t,{width:"short",context:"formatting"})||i.day(t,{width:"narrow",context:"formatting"});default:return i.day(t,{width:"wide",context:"formatting"})||i.day(t,{width:"abbreviated",context:"formatting"})||i.day(t,{width:"short",context:"formatting"})||i.day(t,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(t,e){return e>=0&&e<=6}},{key:"set",value:function(t,e,i,s){return(t=ye(t,i,s)).setUTCHours(0,0,0,0),t}}]),e}(),xe=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",90),wt(dt(i),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","E","i","e","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i,s){var o=function(t){var e=7*Math.floor((t-1)/7);return(t+s.weekStartsOn+6)%7+e};switch(e){case"c":case"cc":return Qt(te(e.length,t),o);case"co":return Qt(i.ordinalNumber(t,{unit:"day"}),o);case"ccc":return i.day(t,{width:"abbreviated",context:"standalone"})||i.day(t,{width:"short",context:"standalone"})||i.day(t,{width:"narrow",context:"standalone"});case"ccccc":return i.day(t,{width:"narrow",context:"standalone"});case"cccccc":return i.day(t,{width:"short",context:"standalone"})||i.day(t,{width:"narrow",context:"standalone"});default:return i.day(t,{width:"wide",context:"standalone"})||i.day(t,{width:"abbreviated",context:"standalone"})||i.day(t,{width:"short",context:"standalone"})||i.day(t,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(t,e){return e>=0&&e<=6}},{key:"set",value:function(t,e,i,s){return(t=ye(t,i,s)).setUTCHours(0,0,0,0),t}}]),e}(),ke=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",90),wt(dt(i),"incompatibleTokens",["y","Y","u","q","Q","M","L","w","d","D","E","e","c","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){var s=function(t){return 0===t?7:t};switch(e){case"i":case"ii":return te(e.length,t);case"io":return i.ordinalNumber(t,{unit:"day"});case"iii":return Qt(i.day(t,{width:"abbreviated",context:"formatting"})||i.day(t,{width:"short",context:"formatting"})||i.day(t,{width:"narrow",context:"formatting"}),s);case"iiiii":return Qt(i.day(t,{width:"narrow",context:"formatting"}),s);case"iiiiii":return Qt(i.day(t,{width:"short",context:"formatting"})||i.day(t,{width:"narrow",context:"formatting"}),s);default:return Qt(i.day(t,{width:"wide",context:"formatting"})||i.day(t,{width:"abbreviated",context:"formatting"})||i.day(t,{width:"short",context:"formatting"})||i.day(t,{width:"narrow",context:"formatting"}),s)}}},{key:"validate",value:function(t,e){return e>=1&&e<=7}},{key:"set",value:function(t,e,i){return t=function(t,e){c(2,arguments);var i=m(e);i%7==0&&(i-=7);var s=u(t),o=((i%7+7)%7<1?7:0)+i-s.getUTCDay();return s.setUTCDate(s.getUTCDate()+o),s}(t,i),t.setUTCHours(0,0,0,0),t}}]),e}(),Ce=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",80),wt(dt(i),"incompatibleTokens",["b","B","H","k","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){switch(e){case"a":case"aa":case"aaa":return i.dayPeriod(t,{width:"abbreviated",context:"formatting"})||i.dayPeriod(t,{width:"narrow",context:"formatting"});case"aaaaa":return i.dayPeriod(t,{width:"narrow",context:"formatting"});default:return i.dayPeriod(t,{width:"wide",context:"formatting"})||i.dayPeriod(t,{width:"abbreviated",context:"formatting"})||i.dayPeriod(t,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(t,e,i){return t.setUTCHours(ie(i),0,0,0),t}}]),e}(),Ae=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",80),wt(dt(i),"incompatibleTokens",["a","B","H","k","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){switch(e){case"b":case"bb":case"bbb":return i.dayPeriod(t,{width:"abbreviated",context:"formatting"})||i.dayPeriod(t,{width:"narrow",context:"formatting"});case"bbbbb":return i.dayPeriod(t,{width:"narrow",context:"formatting"});default:return i.dayPeriod(t,{width:"wide",context:"formatting"})||i.dayPeriod(t,{width:"abbreviated",context:"formatting"})||i.dayPeriod(t,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(t,e,i){return t.setUTCHours(ie(i),0,0,0),t}}]),e}(),Se=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",80),wt(dt(i),"incompatibleTokens",["a","b","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){switch(e){case"B":case"BB":case"BBB":return i.dayPeriod(t,{width:"abbreviated",context:"formatting"})||i.dayPeriod(t,{width:"narrow",context:"formatting"});case"BBBBB":return i.dayPeriod(t,{width:"narrow",context:"formatting"});default:return i.dayPeriod(t,{width:"wide",context:"formatting"})||i.dayPeriod(t,{width:"abbreviated",context:"formatting"})||i.dayPeriod(t,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(t,e,i){return t.setUTCHours(ie(i),0,0,0),t}}]),e}(),ze=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",70),wt(dt(i),"incompatibleTokens",["H","K","k","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){switch(e){case"h":return Jt(Ot,t);case"ho":return i.ordinalNumber(t,{unit:"hour"});default:return te(e.length,t)}}},{key:"validate",value:function(t,e){return e>=1&&e<=12}},{key:"set",value:function(t,e,i){var s=t.getUTCHours()>=12;return t.setUTCHours(s&&i<12?i+12:s||12!==i?i:0,0,0,0),t}}]),e}(),Ie=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",70),wt(dt(i),"incompatibleTokens",["a","b","h","K","k","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){switch(e){case"H":return Jt(Tt,t);case"Ho":return i.ordinalNumber(t,{unit:"hour"});default:return te(e.length,t)}}},{key:"validate",value:function(t,e){return e>=0&&e<=23}},{key:"set",value:function(t,e,i){return t.setUTCHours(i,0,0,0),t}}]),e}(),Ee=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",70),wt(dt(i),"incompatibleTokens",["h","H","k","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){switch(e){case"K":return Jt(Dt,t);case"Ko":return i.ordinalNumber(t,{unit:"hour"});default:return te(e.length,t)}}},{key:"validate",value:function(t,e){return e>=0&&e<=11}},{key:"set",value:function(t,e,i){var s=t.getUTCHours()>=12;return t.setUTCHours(s&&i<12?i+12:i,0,0,0),t}}]),e}(),Te=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",70),wt(dt(i),"incompatibleTokens",["a","b","h","H","K","t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){switch(e){case"k":return Jt(Mt,t);case"ko":return i.ordinalNumber(t,{unit:"hour"});default:return te(e.length,t)}}},{key:"validate",value:function(t,e){return e>=1&&e<=24}},{key:"set",value:function(t,e,i){return t.setUTCHours(i<=24?i%24:i,0,0,0),t}}]),e}(),Me=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",60),wt(dt(i),"incompatibleTokens",["t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){switch(e){case"m":return Jt(Pt,t);case"mo":return i.ordinalNumber(t,{unit:"minute"});default:return te(e.length,t)}}},{key:"validate",value:function(t,e){return e>=0&&e<=59}},{key:"set",value:function(t,e,i){return t.setUTCMinutes(i,0,0),t}}]),e}(),De=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",50),wt(dt(i),"incompatibleTokens",["t","T"]),i}return yt(e,[{key:"parse",value:function(t,e,i){switch(e){case"s":return Jt(Ft,t);case"so":return i.ordinalNumber(t,{unit:"second"});default:return te(e.length,t)}}},{key:"validate",value:function(t,e){return e>=0&&e<=59}},{key:"set",value:function(t,e,i){return t.setUTCSeconds(i,0),t}}]),e}(),Oe=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",30),wt(dt(i),"incompatibleTokens",["t","T"]),i}return yt(e,[{key:"parse",value:function(t,e){return Qt(te(e.length,t),(function(t){return Math.floor(t*Math.pow(10,3-e.length))}))}},{key:"set",value:function(t,e,i){return t.setUTCMilliseconds(i),t}}]),e}(),Pe=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",10),wt(dt(i),"incompatibleTokens",["t","T","x"]),i}return yt(e,[{key:"parse",value:function(t,e){switch(e){case"X":return Xt(Wt,t);case"XX":return Xt(Gt,t);case"XXXX":return Xt(Yt,t);case"XXXXX":return Xt(Kt,t);default:return Xt(Ut,t)}}},{key:"set",value:function(t,e,i){return e.timestampIsSet?t:new Date(t.getTime()-i)}}]),e}(),Fe=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",10),wt(dt(i),"incompatibleTokens",["t","T","X"]),i}return yt(e,[{key:"parse",value:function(t,e){switch(e){case"x":return Xt(Wt,t);case"xx":return Xt(Gt,t);case"xxxx":return Xt(Yt,t);case"xxxxx":return Xt(Kt,t);default:return Xt(Ut,t)}}},{key:"set",value:function(t,e,i){return e.timestampIsSet?t:new Date(t.getTime()-i)}}]),e}(),Ne=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",40),wt(dt(i),"incompatibleTokens","*"),i}return yt(e,[{key:"parse",value:function(t){return Zt(t)}},{key:"set",value:function(t,e,i){return[new Date(1e3*i),{timestampIsSet:!0}]}}]),e}(),Be=function(){ut(e,Ct);var t=vt(e);function e(){var i;ft(this,e);for(var s=arguments.length,o=new Array(s),r=0;r<s;r++)o[r]=arguments[r];return wt(dt(i=t.call.apply(t,[this].concat(o))),"priority",20),wt(dt(i),"incompatibleTokens","*"),i}return yt(e,[{key:"parse",value:function(t){return Zt(t)}},{key:"set",value:function(t,e,i){return[new Date(i),{timestampIsSet:!0}]}}]),e}(),je={G:new At,y:new re,Y:new ne,R:new ae,u:new le,Q:new he,q:new de,M:new ce,L:new ue,w:new pe,I:new me,d:new ge,D:new be,E:new we,e:new _e,c:new xe,i:new ke,a:new Ce,b:new Ae,B:new Se,h:new ze,H:new Ie,K:new Ee,k:new Te,m:new Me,s:new De,S:new Oe,X:new Pe,x:new Fe,t:new Ne,T:new Be},Ve=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,Le=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,Re=/^'([^]*?)'?$/,qe=/''/g,$e=/\S/,He=/[a-zA-Z]/;function We(t,e,i,s){var o,r,n,a,l,h,p,f,g,b,y,_,x,k,C,A,S,z;c(3,arguments);var I=String(t),E=String(e),T=w(),M=null!==(o=null!==(r=null==s?void 0:s.locale)&&void 0!==r?r:T.locale)&&void 0!==o?o:tt;if(!M.match)throw new RangeError("locale must contain match property");var D=m(null!==(n=null!==(a=null!==(l=null!==(h=null==s?void 0:s.firstWeekContainsDate)&&void 0!==h?h:null==s||null===(p=s.locale)||void 0===p||null===(f=p.options)||void 0===f?void 0:f.firstWeekContainsDate)&&void 0!==l?l:T.firstWeekContainsDate)&&void 0!==a?a:null===(g=T.locale)||void 0===g||null===(b=g.options)||void 0===b?void 0:b.firstWeekContainsDate)&&void 0!==n?n:1);if(!(D>=1&&D<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var O=m(null!==(y=null!==(_=null!==(x=null!==(k=null==s?void 0:s.weekStartsOn)&&void 0!==k?k:null==s||null===(C=s.locale)||void 0===C||null===(A=C.options)||void 0===A?void 0:A.weekStartsOn)&&void 0!==x?x:T.weekStartsOn)&&void 0!==_?_:null===(S=T.locale)||void 0===S||null===(z=S.options)||void 0===z?void 0:z.weekStartsOn)&&void 0!==y?y:0);if(!(O>=0&&O<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(""===E)return""===I?u(i):new Date(NaN);var P,F={firstWeekContainsDate:D,weekStartsOn:O,locale:M},N=[new kt],B=E.match(Le).map((function(t){var e=t[0];return e in L?(0,L[e])(t,M.formatLong):t})).join("").match(Ve),j=[],V=lt(B);try{var q=function(){var e=P.value;null!=s&&s.useAdditionalWeekYearTokens||!W(e)||G(e,E,t),null!=s&&s.useAdditionalDayOfYearTokens||!H(e)||G(e,E,t);var i=e[0],o=je[i];if(o){var r=o.incompatibleTokens;if(Array.isArray(r)){var n=j.find((function(t){return r.includes(t.token)||t.token===i}));if(n)throw new RangeError("The format string mustn't contain `".concat(n.fullToken,"` and `").concat(e,"` at the same time"))}else if("*"===o.incompatibleTokens&&j.length>0)throw new RangeError("The format string mustn't contain `".concat(e,"` and any other token at the same time"));j.push({token:i,fullToken:e});var a=o.run(I,e,M.match,F);if(!a)return{v:new Date(NaN)};N.push(a.setter),I=a.rest}else{if(i.match(He))throw new RangeError("Format string contains an unescaped latin alphabet character `"+i+"`");if("''"===e?e="'":"'"===i&&(e=e.match(Re)[1].replace(qe,"'")),0!==I.indexOf(e))return{v:new Date(NaN)};I=I.slice(e.length)}};for(V.s();!(P=V.n()).done;){var $=q();if("object"===d($))return $.v}}catch(t){V.e(t)}finally{V.f()}if(I.length>0&&$e.test(I))return new Date(NaN);var Y=N.map((function(t){return t.priority})).sort((function(t,e){return e-t})).filter((function(t,e,i){return i.indexOf(t)===e})).map((function(t){return N.filter((function(e){return e.priority===t})).sort((function(t,e){return e.subPriority-t.subPriority}))})).map((function(t){return t[0]})),U=u(i);if(isNaN(U.getTime()))return new Date(NaN);var K,Q=v(U,R(U)),J={},X=lt(Y);try{for(X.s();!(K=X.n()).done;){var Z=K.value;if(!Z.validate(Q,F))return new Date(NaN);var et=Z.set(Q,J,F);Array.isArray(et)?(Q=et[0],ht(J,et[1])):Q=et}}catch(t){X.e(t)}finally{X.f()}return Q}function Ge(t,e){c(2,arguments);var i=u(t),s=u(e);return i.getTime()>s.getTime()}function Ye(t,e){c(2,arguments);var i=u(t),s=u(e);return i.getTime()<s.getTime()}function Ue(t,e,i){return c(2,arguments),p(We(t,e,new Date,i))}const Ke=class{constructor(i){t(this,i),this.sendValidityState=e(this,"sendValidityState",7),this.sendInputValue=e(this,"sendInputValue",7),this.touched=!1,this.formatDate=t=>{const{year:e,month:i,day:s}=t;return nt(new Date(e,i,s),this.dateFormat)},this.parseDate=t=>{const e=We(t,this.dateFormat,new Date);return{year:e.getFullYear(),month:e.getMonth(),day:e.getDate()}},this.setClientStyling=()=>{let t=document.createElement("style");t.innerHTML=this.clientStyling,this.stylingContainer.prepend(t)},this.name=void 0,this.displayName=void 0,this.placeholder=void 0,this.validation=void 0,this.defaultValue=void 0,this.autofilled=void 0,this.tooltip=void 0,this.language=void 0,this.emitValue=void 0,this.clientStyling="",this.dateFormat="yyyy-MM-dd",this.emitOnClick=!1,this.errorMessage=void 0,this.isValid=void 0,this.limitStylingAppends=!1,this.showTooltip=!1}get formattedValue(){return this.value?nt(We(this.value,"yyyy-MM-dd",new Date),this.dateFormat):""}handleStylingChange(t,e){t!==e&&this.setClientStyling()}validityChanged(){this.validityStateHandler({valid:this.isValid,name:this.name}),1==this.emitValue&&this.valueHandler({name:this.name,value:this.value})}validityStateHandler(t){this.sendValidityState.emit(t)}emitValueHandler(t){1==t&&this.isValid&&this.valueHandler({name:this.name,value:this.value})}valueHandler(t){this.sendInputValue.emit(t)}handleClickOutside(t){t.composedPath()[0]!==this.tooltipIconReference&&t.composedPath()[0]!==this.tooltipReference&&(this.showTooltip=!1)}connectedCallback(){var t,e;this.minDate=We((null===(t=this.validation.min)||void 0===t?void 0:t.toString())||"","yyyy-MM-dd",new Date),this.maxDate=We((null===(e=this.validation.max)||void 0===e?void 0:e.toString())||"","yyyy-MM-dd",new Date)}componentDidRender(){!this.limitStylingAppends&&this.stylingContainer&&(this.clientStyling&&this.setClientStyling(),this.limitStylingAppends=!0)}componentDidLoad(){if(this.datePicker=this.element.shadowRoot.querySelector("vaadin-date-picker"),this.inputReference=this.element.shadowRoot.querySelector("input"),this.datePicker){const t=this.datePicker.shadowRoot.querySelector('[part="toggle-button"]');t&&t.addEventListener("click",(()=>this.handleCalendarIconClick())),this.datePicker.addEventListener("opened-changed",(t=>{!0===t.detail.value?this.errorMessage="":(this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage(),this.touched=!0)}))}this.datePicker.i18n=Object.assign(Object.assign({},this.datePicker.i18n),{formatDate:this.formatDate,parseDate:this.parseDate}),this.isValid=this.setValidity(),this.defaultValue&&(this.value=this.defaultValue,this.valueHandler({name:this.name,value:this.value}))}handleCalendarIconClick(){this.datePicker.opened&&this.emitOnClick&&window.postMessage({type:`registration${this.name}Clicked`},window.location.href)}handleInput(t){this.value=t.target.value,this.touched=!0,this.valueAsDate=We(this.value||"","yyyy-MM-dd",new Date),this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage(),this.emitValueHandler(!0)}setValidity(){return!(Ye(this.valueAsDate,this.minDate)||Ge(this.valueAsDate,this.maxDate)||!Ue(this.formattedValue,this.dateFormat))&&this.inputReference.validity.valid}setErrorMessage(){return this.inputReference.validity.valueMissing?n("requiredError",this.language):this.inputReference.validity.rangeUnderflow||this.inputReference.validity.rangeOverflow?n("dateError",this.language,{values:{min:this.validation.min,max:this.validation.max}}):Ye(this.valueAsDate,this.minDate)||Ge(this.valueAsDate,this.maxDate)?n("dateError2",this.language):Ue(this.formattedValue,this.dateFormat)?void 0:n("dateFormatError",this.language)}renderTooltip(){return this.showTooltip?i("div",{class:"date__tooltip "+(this.showTooltip?"visible":""),ref:t=>this.tooltipReference=t,innerHTML:this.tooltip}):null}render(){let t="";return this.touched&&(t=1==this.isValid||null==this.isValid?"":"text__input--invalid"),i("div",{key:"ccbdcfd1e145373d0fb24f7c1e6e5ae1184a80f2",class:`date__wrapper ${this.autofilled?"date__wrapper--autofilled":""} ${this.name}__input`,ref:t=>this.stylingContainer=t},i("label",{key:"960db248a2f7418ed87b25de57b58cc8a4902a25",class:`date__label ${this.validation.mandatory?"date__label--required":""}}`,htmlFor:`${this.name}__input`},this.displayName," ",this.validation.mandatory?"*":""),i("vaadin-date-picker",{key:"660961b240cc0cff03d8d4bf3687b398cd07befd",id:`${this.name}__input`,type:"date",class:`date__input ${t}`,value:this.defaultValue,readOnly:this.autofilled,placeholder:`${this.placeholder}`,required:this.validation.mandatory,max:this.validation.max,min:this.validation.min,onChange:t=>this.handleInput(t)}),i("small",{key:"ba06bb3d85bb4441ae92a642464a47b798b287eb",class:"date__error-message"},this.errorMessage),this.tooltip&&i("img",{key:"7ccb422e319e2a08963e99b242495ba9115517bd",class:"date__tooltip-icon",src:a,alt:"",ref:t=>this.tooltipIconReference=t,onClick:()=>this.showTooltip=!this.showTooltip}),this.renderTooltip())}get element(){return s(this)}static get watchers(){return{clientStyling:["handleStylingChange"],isValid:["validityChanged"],emitValue:["emitValueHandler"]}}};Ke.style='*,*::before,*::after{padding:0;margin:0;box-sizing:border-box}.date{font-family:"Roboto";font-style:normal}.date__wrapper{position:relative;width:100%;display:flex;flex-direction:column;gap:5px;height:100%}.date__wrapper--autofilled{pointer-events:none}.date__wrapper--autofilled .date__label{color:var(--emw--registration-typography, var(--emw--color-black, #000000))}.date__wrapper--autofilled .date__input::part(input-field){color:var(--emw--registration-typography, var(--emw--color-black, #000000))}.date__label{font-family:inherit;font-style:normal;font-weight:500;font-size:16px;line-height:20px;color:var(--emw--registration-typography, var(--emw--color-black, #000000))}.date__label--required::after{content:"*";font-family:inherit;color:var(--emw--login-color-primary, var(--emw--color-primary, #22B04E));margin-left:2px}.date__input{border:none;width:inherit;position:relative}.date__input[focused]::part(input-field){border-color:var(--emw--login-color-primary, var(--emw--color-primary, #22B04E))}.date__input[invalid]::part(input-field){border:1px solid var(--emw--color-error, var(--emw--color-red, #ed0909))}.date__input::part(input-field){border-radius:4px;background-color:var(--emw--color-white, #FFFFFF);border:1px solid var(--emw--color-gray-100, #E6E6E6);color:var(--emw--registration-typography, var(--emw--color-black, #000000));font-family:inherit;font-style:normal;font-size:16px;font-weight:300;line-height:1.5;padding:0;height:44px}.date__input>input{padding:5px 15px}.date__input::part(toggle-button){position:relative;right:10px}.date__error-message{position:absolute;top:calc(100% + 5px);left:0;color:var(--emw--color-error, var(--emw--color-red, #ed0909))}.date__tooltip-icon{position:absolute;right:0;bottom:10px}.date__tooltip{position:absolute;bottom:35px;right:10px;background-color:var(--emw--color-white, #FFFFFF);border:1px solid var(--emw--color-gray-100, #E6E6E6);color:var(--emw--registration-typography, var(--emw--color-black, #000000));padding:10px;border-radius:5px;opacity:0;transition:opacity 0.3s ease-in-out;z-index:10}.date__tooltip.visible{opacity:1}';const Qe=class{constructor(i){t(this,i),this.sendValidityState=e(this,"sendValidityState",7),this.sendInputValue=e(this,"sendInputValue",7),this.validationPattern="",this.touched=!1,this.handleInput=t=>{this.value=t.target.value,this.touched=!0,this.debounceTime&&clearTimeout(this.debounceTime),this.debounceTime=setTimeout((()=>{this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage(),this.emitValueHandler(!0)}),500)},this.handleBlur=()=>{this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage(),this.touched=!0},this.setClientStyling=()=>{let t=document.createElement("style");t.innerHTML=this.clientStyling,this.stylingContainer.prepend(t)},this.name=void 0,this.displayName=void 0,this.placeholder=void 0,this.validation=void 0,this.defaultValue=void 0,this.autofilled=void 0,this.tooltip=void 0,this.language=void 0,this.emitValue=void 0,this.isDuplicateInput=void 0,this.clientStyling="",this.errorMessage=void 0,this.isValid=void 0,this.limitStylingAppends=!1,this.showTooltip=!1}handleStylingChange(t,e){t!==e&&this.setClientStyling()}validityChanged(){this.validityStateHandler({valid:this.isValid,name:this.name}),1==this.emitValue&&this.valueHandler({name:this.name,value:this.value})}emitValueHandler(t){1==t&&this.isValid&&this.valueHandler({name:this.name,value:this.value})}validityStateHandler(t){this.sendValidityState.emit(t)}valueHandler(t){this.sendInputValue.emit(t)}handleClickOutside(t){t.composedPath()[0]!==this.tooltipIconReference&&t.composedPath()[0]!==this.tooltipReference&&(this.showTooltip=!1)}valueChangedHandler(t){this.isDuplicateInput&&this.name===t.detail.name+"Duplicate"&&(this.duplicateInputValue=t.detail.value)}connectedCallback(){this.validationPattern=this.setPattern()}componentDidRender(){!this.limitStylingAppends&&this.stylingContainer&&(this.clientStyling&&this.setClientStyling(),this.limitStylingAppends=!0)}componentDidLoad(){this.isValid=this.setValidity(),this.defaultValue&&(this.value=this.defaultValue,this.valueHandler({name:this.name,value:this.value}))}setValidity(){return this.inputReference.validity.valid}setPattern(){var t,e;if((null===(t=this.validation.custom)||void 0===t?void 0:t.length)>0)return null===(e=this.validation.custom.find((t=>"regex"===t.rule)))||void 0===e?void 0:e.pattern}setErrorMessage(){var t,e,i,s;if(this.inputReference.validity.valueMissing)return n("requiredError",this.language);if(this.inputReference.validity.tooShort||this.inputReference.validity.tooLong)return n("lengthError",this.language,{values:{minLength:this.validation.minLength,maxLength:this.validation.maxLength}});if(this.inputReference.validity.patternMismatch){const i=null===(t=this.validation.custom.find((t=>"regex"===t.rule)))||void 0===t?void 0:t.errorKey,s=null===(e=this.validation.custom.find((t=>"regex"===t.rule)))||void 0===e?void 0:e.errorMessage;return n(`${i}`,this.language)?n(`${i}`,this.language):s}if(this.isDuplicateInput&&this.duplicateInputValue!==this.value){const t=null===(i=this.validation.custom.find((t=>"duplicate-input"===t.rule)))||void 0===i?void 0:i.errorKey,e=null===(s=this.validation.custom.find((t=>"duplicate-input"===t.rule)))||void 0===s?void 0:s.errorMessage;return n(`${t}`,this.language)?n(`${t}`,this.language):e}}renderTooltip(){return this.showTooltip?i("div",{class:"email__tooltip "+(this.showTooltip?"visible":""),ref:t=>this.tooltipReference=t,innerHTML:this.tooltip}):null}render(){let t="";return this.touched&&(t=1==this.isValid||null==this.isValid?"":"text__input--invalid"),i("div",{key:"532d12855e6014b6c5a81cd11f4c7d83596361c3",class:`email__wrapper ${this.autofilled?"number__wrapper--autofilled":""} ${this.name}__input`,ref:t=>this.stylingContainer=t},i("div",{key:"80f2e930c6360e1e4e27f29b1de3d3c49a3bb47f",class:"email__wrapper--flex"},i("label",{key:"68189c133403e6dada30c376bd84b60b35ca56e4",class:"email__label "+(this.validation.mandatory?"email__label--required":""),htmlFor:`${this.name}__input`},this.displayName),i("div",{key:"b62dd9a877825d51f6735e9b3ca6b3bb3fc21c28",class:"email__wrapper--relative"},this.tooltip&&i("img",{key:"ff76c31db244e06af60db2855b907c90ecde2fe2",class:"email__tooltip-icon",src:a,alt:"",ref:t=>this.tooltipIconReference=t,onClick:()=>this.showTooltip=!this.showTooltip}),this.renderTooltip())),i("input",{key:"137af683d11c63b2bd881fa3110dd1522ead8774",id:`${this.name}__input`,type:"email",class:`email__input ${t}`,value:this.defaultValue,readOnly:this.autofilled,placeholder:`${this.placeholder}`,ref:t=>this.inputReference=t,pattern:this.validationPattern,required:this.validation.mandatory,minlength:this.validation.minLength,maxlength:this.validation.maxLength,onInput:this.handleInput,onBlur:this.handleBlur}),i("small",{key:"573a357c4e8464f20d9e60a5fd3a2d0c4ae69e3c",class:"email__error-message"},this.errorMessage))}static get watchers(){return{clientStyling:["handleStylingChange"],isValid:["validityChanged"],emitValue:["emitValueHandler"]}}};Qe.style='*,*::before,*::after{padding:0;margin:0;box-sizing:border-box}.email{font-family:"Roboto";font-style:normal}.email__wrapper{position:relative;width:100%}.email__wrapper--autofilled{pointer-events:none}.email__wrapper--autofilled .email__label{color:var(--emw--registration-typography, var(--emw--color-black, #000000))}.email__wrapper--autofilled .email__input{color:var(--emw--color-black, #000000)}.email__wrapper--flex{display:flex;gap:5px}.email__wrapper--relative{position:relative}.email__label{font-family:inherit;font-style:normal;font-weight:500;font-size:16px;line-height:20px;color:var(--emw--registration-typography, var(--emw--color-black, #000000))}.email__label--required::after{content:"*";font-family:inherit;color:var(--emw--login-color-primary, var(--emw--color-primary, #22B04E));margin-left:2px}.email__input{font-family:inherit;border-radius:4px;width:100%;height:40px;border:2px solid var(--emw--color-gray-100, #E6E6E6);color:var(--emw--color-black, #000000);border-radius:5px;box-sizing:border-box;font-size:16px;font-weight:300;line-height:1.5;padding:10px}.email__input:focus{outline-color:var(--emw--login-color-primary, var(--emw--color-primary, #22B04E))}.email__input--invalid{border:1px solid var(--emw--color-error, var(--emw--color-red, #ed0909))}.email__input::placeholder{color:var(--emw--color-gray-150, #828282)}.email__error-message{position:absolute;top:calc(100% + 5px);left:0;color:var(--emw--color-error, var(--emw--color-red, #ed0909))}.email__tooltip-icon{width:16px;height:auto}.email__tooltip{position:absolute;top:0;left:20px;background-color:var(--emw--color-white, #FFFFFF);border:1px solid var(--emw--color-gray-100, #E6E6E6);color:var(--emw--registration-typography, var(--emw--color-black, #000000));padding:10px;border-radius:5px;opacity:0;transition:opacity 0.3s ease-in-out;z-index:10}.email__tooltip.visible{opacity:1}';var Je=Object.defineProperty,Xe=Object.defineProperties,Ze=Object.getOwnPropertyDescriptors,ti=Object.getOwnPropertySymbols,ei=Object.prototype.hasOwnProperty,ii=Object.prototype.propertyIsEnumerable,si=(t,e,i)=>e in t?Je(t,e,{enumerable:!0,configurable:!0,writable:!0,value:i}):t[e]=i,oi=(t,e)=>{for(var i in e||(e={}))ei.call(e,i)&&si(t,i,e[i]);if(ti)for(var i of ti(e))ii.call(e,i)&&si(t,i,e[i]);return t},ri=(t,e)=>Xe(t,Ze(e)),ni=(t,e,i)=>(si(t,"symbol"!=typeof e?e+"":e,i),i),ai=(t,e,i)=>new Promise(((s,o)=>{var r=t=>{try{a(i.next(t))}catch(t){o(t)}},n=t=>{try{a(i.throw(t))}catch(t){o(t)}},a=t=>t.done?s(t.value):Promise.resolve(t.value).then(r,n);a((i=i.apply(t,e)).next())}))
|
|
2
2
|
/**
|
|
3
3
|
* @license
|
|
4
4
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
@@ -19,7 +19,7 @@ const hi=globalThis,di=hi.ShadowRoot&&(void 0===hi.ShadyCSS||hi.ShadyCSS.nativeS
|
|
|
19
19
|
* @license
|
|
20
20
|
* Copyright 2017 Google LLC
|
|
21
21
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
22
|
-
*/,{is:
|
|
22
|
+
*/,{is:gi,defineProperty:bi,getOwnPropertyDescriptor:yi,getOwnPropertyNames:wi,getOwnPropertySymbols:_i,getPrototypeOf:xi}=Object,ki=globalThis,Ci=ki.trustedTypes,Ai=Ci?Ci.emptyScript:"",Si=ki.reactiveElementPolyfillSupport,zi={toAttribute(t,e){switch(e){case Boolean:t=t?Ai:null;break;case Object:case Array:t=null==t?t:JSON.stringify(t)}return t},fromAttribute(t,e){let i=t;switch(e){case Boolean:i=null!==t;break;case Number:i=null===t?null:Number(t);break;case Object:case Array:try{i=JSON.parse(t)}catch(t){i=null}}return i}},Ii=(t,e)=>!gi(t,e),Ei={attribute:!0,type:String,converter:zi,reflect:!1,useDefault:!1,hasChanged:Ii};null!=Symbol.metadata||(Symbol.metadata=Symbol("metadata")),null!=ki.litPropertyMetadata||(ki.litPropertyMetadata=new WeakMap);class Ti extends HTMLElement{static addInitializer(t){var e;this._$Ei(),(null!=(e=this.l)?e:this.l=[]).push(t)}static get observedAttributes(){return this.finalize(),this._$Eh&&[...this._$Eh.keys()]}static createProperty(t,e=Ei){if(e.state&&(e.attribute=!1),this._$Ei(),this.prototype.hasOwnProperty(t)&&((e=Object.create(e)).wrapped=!0),this.elementProperties.set(t,e),!e.noAccessor){const i=Symbol(),s=this.getPropertyDescriptor(t,i,e);void 0!==s&&bi(this.prototype,t,s)}}static getPropertyDescriptor(t,e,i){var s;const{get:o,set:r}=null!=(s=yi(this.prototype,t))?s:{get(){return this[e]},set(t){this[e]=t}};return{get:o,set(e){const s=null==o?void 0:o.call(this);null==r||r.call(this,e),this.requestUpdate(t,s,i)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){var e;return null!=(e=this.elementProperties.get(t))?e:Ei}static _$Ei(){if(this.hasOwnProperty("elementProperties"))return;const t=xi(this);t.finalize(),void 0!==t.l&&(this.l=[...t.l]),this.elementProperties=new Map(t.elementProperties)}static finalize(){if(this.hasOwnProperty("finalized"))return;if(this.finalized=!0,this._$Ei(),this.hasOwnProperty("properties")){const t=this.properties,e=[...wi(t),..._i(t)];for(const i of e)this.createProperty(i,t[i])}const t=this[Symbol.metadata];if(null!==t){const e=litPropertyMetadata.get(t);if(void 0!==e)for(const[t,i]of e)this.elementProperties.set(t,i)}this._$Eh=new Map;for(const[t,e]of this.elementProperties){const i=this._$Eu(t,e);void 0!==i&&this._$Eh.set(i,t)}this.elementStyles=this.finalizeStyles(this.styles)}static finalizeStyles(t){const e=[];if(Array.isArray(t)){const i=new Set(t.flat(1/0).reverse());for(const t of i)e.unshift(fi(t))}else void 0!==t&&e.push(fi(t));return e}static _$Eu(t,e){const i=e.attribute;return!1===i?void 0:"string"==typeof i?i:"string"==typeof t?t.toLowerCase():void 0}constructor(){super(),this._$Ep=void 0,this.isUpdatePending=!1,this.hasUpdated=!1,this._$Em=null,this._$Ev()}_$Ev(){var t;this._$ES=new Promise((t=>this.enableUpdating=t)),this._$AL=new Map,this._$E_(),this.requestUpdate(),null==(t=this.constructor.l)||t.forEach((t=>t(this)))}addController(t){var e,i;(null!=(e=this._$EO)?e:this._$EO=new Set).add(t),void 0!==this.renderRoot&&this.isConnected&&(null==(i=t.hostConnected)||i.call(t))}removeController(t){var e;null==(e=this._$EO)||e.delete(t)}_$E_(){const t=new Map,e=this.constructor.elementProperties;for(const i of e.keys())this.hasOwnProperty(i)&&(t.set(i,this[i]),delete this[i]);t.size>0&&(this._$Ep=t)}createRenderRoot(){var t;const e=null!=(t=this.shadowRoot)?t:this.attachShadow(this.constructor.shadowRootOptions);return vi(e,this.constructor.elementStyles),e}connectedCallback(){var t;null!=this.renderRoot||(this.renderRoot=this.createRenderRoot()),this.enableUpdating(!0),null==(t=this._$EO)||t.forEach((t=>{var e;return null==(e=t.hostConnected)?void 0:e.call(t)}))}enableUpdating(t){}disconnectedCallback(){var t;null==(t=this._$EO)||t.forEach((t=>{var e;return null==(e=t.hostDisconnected)?void 0:e.call(t)}))}attributeChangedCallback(t,e,i){this._$AK(t,i)}_$ET(t,e){var i;const s=this.constructor.elementProperties.get(t),o=this.constructor._$Eu(t,s);if(void 0!==o&&!0===s.reflect){const r=(void 0!==(null==(i=s.converter)?void 0:i.toAttribute)?s.converter:zi).toAttribute(e,s.type);this._$Em=t,null==r?this.removeAttribute(o):this.setAttribute(o,r),this._$Em=null}}_$AK(t,e){var i,s,o,r;const n=this.constructor,a=n._$Eh.get(t);if(void 0!==a&&this._$Em!==a){const t=n.getPropertyOptions(a),l="function"==typeof t.converter?{fromAttribute:t.converter}:void 0!==(null==(i=t.converter)?void 0:i.fromAttribute)?t.converter:zi;this._$Em=a,this[a]=null!=(r=null!=(o=l.fromAttribute(e,t.type))?o:null==(s=this._$Ej)?void 0:s.get(a))?r:null,this._$Em=null}}requestUpdate(t,e,i){var s,o;if(void 0!==t){const r=this.constructor,n=this[t];if(null!=i||(i=r.getPropertyOptions(t)),!((null!=(s=i.hasChanged)?s:Ii)(n,e)||i.useDefault&&i.reflect&&n===(null==(o=this._$Ej)?void 0:o.get(t))&&!this.hasAttribute(r._$Eu(t,i))))return;this.C(t,e,i)}!1===this.isUpdatePending&&(this._$ES=this._$EP())}C(t,e,{useDefault:i,reflect:s,wrapped:o},r){var n,a,l;i&&!(null!=(n=this._$Ej)?n:this._$Ej=new Map).has(t)&&(this._$Ej.set(t,null!=(a=null!=r?r:e)?a:this[t]),!0!==o||void 0!==r)||(this._$AL.has(t)||(this.hasUpdated||i||(e=void 0),this._$AL.set(t,e)),!0===s&&this._$Em!==t&&(null!=(l=this._$Eq)?l:this._$Eq=new Set).add(t))}_$EP(){return ai(this,null,(function*(){this.isUpdatePending=!0;try{yield this._$ES}catch(t){Promise.reject(t)}const t=this.scheduleUpdate();return null!=t&&(yield t),!this.isUpdatePending}))}scheduleUpdate(){return this.performUpdate()}performUpdate(){var t;if(!this.isUpdatePending)return;if(!this.hasUpdated){if(null!=this.renderRoot||(this.renderRoot=this.createRenderRoot()),this._$Ep){for(const[t,e]of this._$Ep)this[t]=e;this._$Ep=void 0}const t=this.constructor.elementProperties;if(t.size>0)for(const[e,i]of t){const{wrapped:t}=i,s=this[e];!0!==t||this._$AL.has(e)||void 0===s||this.C(e,void 0,i,s)}}let e=!1;const i=this._$AL;try{e=this.shouldUpdate(i),e?(this.willUpdate(i),null==(t=this._$EO)||t.forEach((t=>{var e;return null==(e=t.hostUpdate)?void 0:e.call(t)})),this.update(i)):this._$EM()}catch(t){throw e=!1,this._$EM(),t}e&&this._$AE(i)}willUpdate(t){}_$AE(t){var e;null==(e=this._$EO)||e.forEach((t=>{var e;return null==(e=t.hostUpdated)?void 0:e.call(t)})),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(t)),this.updated(t)}_$EM(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$ES}shouldUpdate(t){return!0}update(t){this._$Eq&&(this._$Eq=this._$Eq.forEach((t=>this._$ET(t,this[t])))),this._$EM()}updated(t){}firstUpdated(t){}}var Mi;Ti.elementStyles=[],Ti.shadowRootOptions={mode:"open"},Ti.elementProperties=new Map,Ti.finalized=new Map,null==Si||Si({ReactiveElement:Ti}),(null!=(Mi=ki.reactiveElementVersions)?Mi:ki.reactiveElementVersions=[]).push("2.1.0");
|
|
23
23
|
/**
|
|
24
24
|
* @license
|
|
25
25
|
* Copyright 2017 Google LLC
|
|
@@ -30,7 +30,7 @@ const Di=globalThis,Oi=Di.trustedTypes,Pi=Oi?Oi.createPolicy("lit-html",{createH
|
|
|
30
30
|
* @license
|
|
31
31
|
* Copyright 2017 Google LLC
|
|
32
32
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
33
|
-
*/},ms=globalThis;class vs extends Ti{constructor(){super(...arguments),this.renderOptions={host:this},this._$Do=void 0}createRenderRoot(){var t;const e=super.createRenderRoot();return null!=(t=this.renderOptions).renderBefore||(t.renderBefore=e.firstChild),e}update(t){const e=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(t),this._$Do=ps(e,this.renderRoot,this.renderOptions)}connectedCallback(){var t;super.connectedCallback(),null==(t=this._$Do)||t.setConnected(!0)}disconnectedCallback(){var t;super.disconnectedCallback(),null==(t=this._$Do)||t.setConnected(!1)}render(){return Ji}}var fs;vs._$litElement$=!0,vs.finalized=!0,null==(fs=ms.litElementHydrateSupport)||fs.call(ms,{LitElement:vs});const
|
|
33
|
+
*/},ms=globalThis;class vs extends Ti{constructor(){super(...arguments),this.renderOptions={host:this},this._$Do=void 0}createRenderRoot(){var t;const e=super.createRenderRoot();return null!=(t=this.renderOptions).renderBefore||(t.renderBefore=e.firstChild),e}update(t){const e=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(t),this._$Do=ps(e,this.renderRoot,this.renderOptions)}connectedCallback(){var t;super.connectedCallback(),null==(t=this._$Do)||t.setConnected(!0)}disconnectedCallback(){var t;super.disconnectedCallback(),null==(t=this._$Do)||t.setConnected(!1)}render(){return Ji}}var fs;vs._$litElement$=!0,vs.finalized=!0,null==(fs=ms.litElementHydrateSupport)||fs.call(ms,{LitElement:vs});const gs=ms.litElementPolyfillSupport;var bs;null==gs||gs({LitElement:vs}),(null!=(bs=ms.litElementVersions)?bs:ms.litElementVersions=[]).push("4.2.0");
|
|
34
34
|
/**
|
|
35
35
|
* @license
|
|
36
36
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
@@ -910,7 +910,7 @@ The complete set of contributors may be found at http://polymer.github.io/CONTRI
|
|
|
910
910
|
Code distributed by Google as part of the polymer project is also
|
|
911
911
|
subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
|
|
912
912
|
*/
|
|
913
|
-
const uo="link[rel=import][type~=css]",po="include",mo="shady-unscoped";function vo(t){return co.import(t)}function fo(t){const e=Rs((t.body?t.body:t).textContent,t.baseURI),i=document.createElement("style");return i.textContent=e,i}function
|
|
913
|
+
const uo="link[rel=import][type~=css]",po="include",mo="shady-unscoped";function vo(t){return co.import(t)}function fo(t){const e=Rs((t.body?t.body:t).textContent,t.baseURI),i=document.createElement("style");return i.textContent=e,i}function go(t){const e=t.trim().split(/\s+/),i=[];for(let t=0;t<e.length;t++)i.push(...bo(e[t]));return i}function bo(t){const e=vo(t);if(!e)return console.warn("Could not find style data in module named",t),[];if(void 0===e._styles){const t=[];t.push(...wo(e));const i=e.querySelector("template");i&&t.push(...yo(i,e.assetpath)),e._styles=t}return e._styles}function yo(t,e){if(!t._styles){const i=[],s=t.content.querySelectorAll("style");for(let t=0;t<s.length;t++){let o=s[t],r=o.getAttribute(po);r&&i.push(...go(r).filter((function(t,e,i){return i.indexOf(t)===e}))),e&&(o.textContent=Rs(o.textContent,e)),i.push(o)}t._styles=i}return t._styles}function wo(t){const e=[],i=t.querySelectorAll(uo);for(let t=0;t<i.length;t++){let s=i[t];if(s.import){const t=s.import,i=s.hasAttribute(mo);if(i&&!t._unscopedStyle){const e=fo(t);e.setAttribute(mo,""),t._unscopedStyle=e}else t._style||(t._style=fo(t));e.push(i?t._unscopedStyle:t._style)}}return e}
|
|
914
914
|
/**
|
|
915
915
|
@license
|
|
916
916
|
Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
|
|
@@ -966,7 +966,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
966
966
|
* be found at http://polymer.github.io/CONTRIBUTORS.txt Code distributed by
|
|
967
967
|
* Google as part of the polymer project is also subject to an additional IP
|
|
968
968
|
* rights grant found at http://polymer.github.io/PATENTS.txt
|
|
969
|
-
*/let nr=0;const ar=[],lr={COMPUTE:"__computeEffects",REFLECT:"__reflectEffects",NOTIFY:"__notifyEffects",PROPAGATE:"__propagateEffects",OBSERVE:"__observeEffects",READ_ONLY:"__readOnly"},hr="__computeInfo",dr=/[A-Z]/;function cr(t,e,i){let s=t[e];if(s){if(!t.hasOwnProperty(e)&&(s=t[e]=Object.create(t[e]),i))for(let t in s){let e=s[t],i=s[t]=Array(e.length);for(let t=0;t<e.length;t++)i[t]=e[t]}}else s=t[e]={};return s}function ur(t,e,i,s,o,r){if(e){let n=!1;const a=nr++;for(let l in i){let h=e[o?ko(l):l];if(h)for(let e,d=0,c=h.length;d<c&&(e=h[d]);d++)(!e.info||e.info.lastRun!==a)&&(!o||mr(l,e.trigger))&&(e.info&&(e.info.lastRun=a),e.fn(t,l,i,s,e.info,o,r),n=!0)}return n}return!1}function pr(t,e,i,s,o,r,n,a){let l=!1,h=e[n?ko(s):s];if(h)for(let e,d=0,c=h.length;d<c&&(e=h[d]);d++)(!e.info||e.info.lastRun!==i)&&(!n||mr(s,e.trigger))&&(e.info&&(e.info.lastRun=i),e.fn(t,s,o,r,e.info,n,a),l=!0);return l}function mr(t,e){if(e){let i=e.name;return i==t||!(!e.structured||!Co(i,t))||!(!e.wildcard||!Ao(i,t))}return!0}function vr(t,e,i,s,o){let r="string"==typeof o.method?t[o.method]:o.method,n=o.property;r?r.call(t,t.__data[n],s[n]):o.dynamicFn||console.warn("observer method `"+o.method+"` not defined")}function fr(t,e,i){let s=ko(e);return s!==e&&(br(t,Fo(s)+"-changed",i[e],e),!0)}function br(t,e,i,s){let o={value:i,queueProperty:!0};s&&(o.path=s),_o(t).dispatchEvent(new CustomEvent(e,{detail:o}))}function gr(t,e,i,s,o,r){let n=(r?ko(e):e)!=e?e:null,a=n?Eo(t,n):t.__data[e];n&&void 0===a&&(a=i[e]),br(t,o.eventName,a,n)}function yr(t,e,i,s,o){let r=t.__data[e];Gs&&(r=Gs(r,o.attrName,"attribute",t)),t._propertyToAttribute(e,o.attrName,r)}const wr=(t,e,i)=>{let s=0,o=e.length-1,r=-1;for(;s<=o;){const n=s+o>>1,a=i.get(e[n].methodInfo)-i.get(t.methodInfo);if(a<0)s=n+1;else{if(!(a>0)){r=n;break}o=n-1}}r<0&&(r=o+1),e.splice(r,0,t)},_r=(t,e,i,s,o)=>{const r=e[o?ko(t):t];if(r)for(let e=0;e<r.length;e++){const n=r[e];n.info.lastRun!==nr&&(!o||mr(t,n.trigger))&&(n.info.lastRun=nr,wr(n.info,i,s))}};function xr(t,e,i,s,o){let r=Er(t,e,i,0,o);if(r===ar)return!1;let n=o.methodInfo;return t.__dataHasAccessor&&t.__dataHasAccessor[n]?t._setPendingProperty(n,r,!0):(t[n]=r,!1)}function kr(t,e,i,s,o,r,n){i.bindings=i.bindings||[];let a={kind:s,target:o,parts:r,literal:n,isCompound:1!==r.length};if(i.bindings.push(a),function(t){return!!t.target&&"attribute"!=t.kind&&"text"!=t.kind&&!t.isCompound&&"{"===t.parts[0].mode}(a)){let{event:t,negate:e}=a.parts[0];a.listenerEvent=t||Fo(o)+"-changed",a.listenerNegate=e}let l=e.nodeInfoList.length;for(let i=0;i<a.parts.length;i++){let s=a.parts[i];s.compoundIndex=i,Cr(t,e,a,s,l)}}function Cr(t,e,i,s,o){if(!s.literal)if("attribute"===i.kind&&"-"===i.target[0])console.warn("Cannot set attribute "+i.target+' because "-" is not a valid attribute starting character');else{let r=s.dependencies,n={index:o,binding:i,part:s,evaluator:t};for(let i=0;i<r.length;i++){let s=r[i];"string"==typeof s&&(s=Nr(s),s.wildcard=!0),t._addTemplatePropertyEffect(e,s.rootProperty,{fn:Ar,info:n,trigger:s})}}}function Ar(t,e,i,s,o,r,n){let a=n[o.index],l=o.binding,h=o.part;if(r&&h.source&&e.length>h.source.length&&"property"==l.kind&&!l.isCompound&&a.__isPropertyEffectsClient&&a.__dataHasAccessor&&a.__dataHasAccessor[l.target]){let s=i[e];e=So(h.source,l.target,e),a._setPendingPropertyOrPath(e,s,!1,!0)&&t._enqueueClient(a)}else{let n=o.evaluator._evaluateBinding(t,h,e,i,s,r);n!==ar&&function(t,e,i,s,o){if(o=function(t,e,i,s){if(i.isCompound){let o=t.__dataCompoundStorage[i.target];o[s.compoundIndex]=e,e=o.join("")}return"attribute"!==i.kind&&("textContent"===i.target||"value"===i.target&&("input"===t.localName||"textarea"===t.localName))&&(e=null==e?"":e),e}(e,o,i,s),Gs&&(o=Gs(o,i.target,i.kind,e)),"attribute"==i.kind)t._valueToNodeAttribute(e,o,i.target);else{let s=i.target;e.__isPropertyEffectsClient&&e.__dataHasAccessor&&e.__dataHasAccessor[s]?(!e[lr.READ_ONLY]||!e[lr.READ_ONLY][s])&&e._setPendingProperty(s,o)&&t._enqueueClient(e):t._setUnmanagedPropertyToNode(e,s,o)}}(t,a,l,h,n)}}function Sr(t,e){if(e.isCompound){let i=t.__dataCompoundStorage||(t.__dataCompoundStorage={}),s=e.parts,o=new Array(s.length);for(let t=0;t<s.length;t++)o[t]=s[t].literal;let r=e.target;i[r]=o,e.literal&&"property"==e.kind&&("className"===r&&(t=_o(t)),t[r]=e.literal)}}function zr(t,e,i){if(i.listenerEvent){let s=i.parts[0];t.addEventListener(i.listenerEvent,(function(t){!function(t,e,i,s,o){let r,n=t.detail,a=n&&n.path;a?(s=So(i,s,a),r=n&&n.value):r=t.currentTarget[i],r=o?!r:r,(!e[lr.READ_ONLY]||!e[lr.READ_ONLY][s])&&e._setPendingPropertyOrPath(s,r,!0,!!a)&&(!n||!n.queueProperty)&&e._invalidateProperties()}(t,e,i.target,s.source,s.negate)}))}}function Ir(t,e,i,s,o,r){let n={methodName:e.methodName,args:e.args,methodInfo:o,dynamicFn:r=e.static||r&&("object"!=typeof r||r[e.methodName])};for(let o,r=0;r<e.args.length&&(o=e.args[r]);r++)o.literal||t._addPropertyEffect(o.rootProperty,i,{fn:s,info:n,trigger:o});return r&&t._addPropertyEffect(e.methodName,i,{fn:s,info:n}),n}function Er(t,e,i,s,o){let r=t._methodHost||t,n=r[o.methodName];if(n){let s=t._marshalArgs(o.args,e,i);return s===ar?ar:n.apply(r,s)}o.dynamicFn||console.warn("method `"+o.methodName+"` not defined")}const Tr=[],Mr="(?:[a-zA-Z_$][\\w.:$\\-*]*)",Dr="(?:("+Mr+"|(?:[-+]?[0-9]*\\.?[0-9]+(?:[eE][-+]?[0-9]+)?)|(?:(?:'(?:[^'\\\\]|\\\\.)*')|(?:\"(?:[^\"\\\\]|\\\\.)*\")))\\s*)",Or=new RegExp("(\\[\\[|{{)\\s*(?:(!)\\s*)?("+Mr+"\\s*(?:\\(\\s*(?:(?:"+Dr+"(?:,\\s*"+Dr+")*)?)\\)\\s*)?)(?:]]|}})","g");function Pr(t){let e="";for(let i=0;i<t.length;i++)e+=t[i].literal||"";return e}function Fr(t){let e=t.match(/([^\s]+?)\(([\s\S]*)\)/);if(e){let t={methodName:e[1],static:!0,args:Tr};return e[2].trim()?function(t,e){return e.args=t.map((function(t){let i=Nr(t);return i.literal||(e.static=!1),i}),this),e}(e[2].replace(/\\,/g,",").split(","),t):t}return null}function Nr(t){let e=t.trim().replace(/,/g,",").replace(/\\(.)/g,"$1"),i={name:e,value:"",literal:!1},s=e[0];switch("-"===s&&(s=e[1]),s>="0"&&s<="9"&&(s="#"),s){case"'":case'"':i.value=e.slice(1,-1),i.literal=!0;break;case"#":i.value=Number(e),i.literal=!0}return i.literal||(i.rootProperty=ko(e),i.structured=xo(e),i.structured&&(i.wildcard=".*"==e.slice(-2),i.wildcard&&(i.name=e.slice(0,-2)))),i}function Br(t,e,i){let s=Eo(t,i);return void 0===s&&(s=e[i]),s}function jr(t,e,i,s){const o={indexSplices:s};Xs&&!t._overrideLegacyUndefined&&(e.splices=o),t.notifyPath(i+".splices",o),t.notifyPath(i+".length",e.length),Xs&&!t._overrideLegacyUndefined&&(o.indexSplices=[])}function Vr(t,e,i,s,o,r){jr(t,e,i,[{index:s,addedCount:o,removed:r,object:e,type:"splice"}])}const Lr=ro((t=>{const e=rr(Ko(t));return class extends e{constructor(){super(),this.__isPropertyEffectsClient=!0}get PROPERTY_EFFECT_TYPES(){return lr}_initializeProperties(){super._initializeProperties(),this._registerHost(),this.__dataClientsReady=!1,this.__dataPendingClients=null,this.__dataToNotify=null,this.__dataLinkedPaths=null,this.__dataHasPaths=!1,this.__dataCompoundStorage=this.__dataCompoundStorage||null,this.__dataHost=this.__dataHost||null,this.__dataTemp={},this.__dataClientsInitialized=!1}_registerHost(){if(Rr.length){let t=Rr[Rr.length-1];t._enqueueClient(this),this.__dataHost=t}}_initializeProtoProperties(t){this.__data=Object.create(t),this.__dataPending=Object.create(t),this.__dataOld={}}_initializeInstanceProperties(t){let e=this[lr.READ_ONLY];for(let i in t)(!e||!e[i])&&(this.__dataPending=this.__dataPending||{},this.__dataOld=this.__dataOld||{},this.__data[i]=this.__dataPending[i]=t[i])}_addPropertyEffect(t,e,i){this._createPropertyAccessor(t,e==lr.READ_ONLY);let s=cr(this,e,!0)[t];s||(s=this[e][t]=[]),s.push(i)}_removePropertyEffect(t,e,i){let s=cr(this,e,!0)[t],o=s.indexOf(i);o>=0&&s.splice(o,1)}_hasPropertyEffect(t,e){let i=this[e];return!(!i||!i[t])}_hasReadOnlyEffect(t){return this._hasPropertyEffect(t,lr.READ_ONLY)}_hasNotifyEffect(t){return this._hasPropertyEffect(t,lr.NOTIFY)}_hasReflectEffect(t){return this._hasPropertyEffect(t,lr.REFLECT)}_hasComputedEffect(t){return this._hasPropertyEffect(t,lr.COMPUTE)}_setPendingPropertyOrPath(t,e,i,s){if(s||ko(Array.isArray(t)?t[0]:t)!==t){if(!s){let i=Eo(this,t);if(!(t=To(this,t,e))||!super._shouldPropertyChange(t,e,i))return!1}if(this.__dataHasPaths=!0,this._setPendingProperty(t,e,i))return function(t,e,i){let s=t.__dataLinkedPaths;if(s){let o;for(let r in s){let n=s[r];Ao(r,e)?(o=So(r,n,e),t._setPendingPropertyOrPath(o,i,!0,!0)):Ao(n,e)&&(o=So(n,r,e),t._setPendingPropertyOrPath(o,i,!0,!0))}}}(this,t,e),!0}else{if(this.__dataHasAccessor&&this.__dataHasAccessor[t])return this._setPendingProperty(t,e,i);this[t]=e}return!1}_setUnmanagedPropertyToNode(t,e,i){(i!==t[e]||"object"==typeof i)&&("className"===e&&(t=_o(t)),t[e]=i)}_setPendingProperty(t,e,i){let s=this.__dataHasPaths&&xo(t);return!!this._shouldPropertyChange(t,e,(s?this.__dataTemp:this.__data)[t])&&(this.__dataPending||(this.__dataPending={},this.__dataOld={}),t in this.__dataOld||(this.__dataOld[t]=this.__data[t]),s?this.__dataTemp[t]=e:this.__data[t]=e,this.__dataPending[t]=e,(s||this[lr.NOTIFY]&&this[lr.NOTIFY][t])&&(this.__dataToNotify=this.__dataToNotify||{},this.__dataToNotify[t]=i),!0)}_setProperty(t,e){this._setPendingProperty(t,e,!0)&&this._invalidateProperties()}_invalidateProperties(){this.__dataReady&&this._flushProperties()}_enqueueClient(t){this.__dataPendingClients=this.__dataPendingClients||[],t!==this&&this.__dataPendingClients.push(t)}_flushClients(){this.__dataClientsReady?this.__enableOrFlushClients():(this.__dataClientsReady=!0,this._readyClients(),this.__dataReady=!0)}__enableOrFlushClients(){let t=this.__dataPendingClients;if(t){this.__dataPendingClients=null;for(let e=0;e<t.length;e++){let i=t[e];i.__dataEnabled?i.__dataPending&&i._flushProperties():i._enableProperties()}}}_readyClients(){this.__enableOrFlushClients()}setProperties(t,e){for(let i in t)(e||!this[lr.READ_ONLY]||!this[lr.READ_ONLY][i])&&this._setPendingPropertyOrPath(i,t[i],!0);this._invalidateProperties()}ready(){this._flushProperties(),this.__dataClientsReady||this._flushClients(),this.__dataPending&&this._flushProperties()}_propertiesChanged(t,e,i){let s,o=this.__dataHasPaths;this.__dataHasPaths=!1,function(t,e,i,s){let o=t[lr.COMPUTE];if(o)if(Zs){nr++;const r=function(t){let e=t.constructor.__orderedComputedDeps;if(!e){e=new Map;const i=t[lr.COMPUTE];let s,{counts:o,ready:r,total:n}=function(t){const e=t[hr],i={},s=t[lr.COMPUTE],o=[];let r=0;for(let t in e){const s=e[t];r+=i[t]=s.args.filter((t=>!t.literal)).length+(s.dynamicFn?1:0)}for(let t in s)e[t]||o.push(t);return{counts:i,ready:o,total:r}}(t);for(;s=r.shift();){e.set(s,e.size);const t=i[s];t&&t.forEach((t=>{const e=t.info.methodInfo;--n,0==--o[e]&&r.push(e)}))}0!==n&&console.warn(`Computed graph for ${t.localName} incomplete; circular?`),t.constructor.__orderedComputedDeps=e}return e}(t),n=[];for(let t in e)_r(t,o,n,r,s);let a;for(;a=n.shift();)xr(t,"",e,0,a)&&_r(a.methodInfo,o,n,r,s);Object.assign(i,t.__dataOld),Object.assign(e,t.__dataPending),t.__dataPending=null}else{let r=e;for(;ur(t,o,r,i,s);)Object.assign(i,t.__dataOld),Object.assign(e,t.__dataPending),r=t.__dataPending,t.__dataPending=null}}(this,e,i,o),s=this.__dataToNotify,this.__dataToNotify=null,this._propagatePropertyChanges(e,i,o),this._flushClients(),ur(this,this[lr.REFLECT],e,i,o),ur(this,this[lr.OBSERVE],e,i,o),s&&function(t,e,i,s,o){let r,n,a=t[lr.NOTIFY],l=nr++;for(let n in e)e[n]&&(a&&pr(t,a,l,n,i,s,o)||o&&fr(t,n,i))&&(r=!0);r&&(n=t.__dataHost)&&n._invalidateProperties&&n._invalidateProperties()}(this,s,e,i,o),1==this.__dataCounter&&(this.__dataTemp={})}_propagatePropertyChanges(t,e,i){this[lr.PROPAGATE]&&ur(this,this[lr.PROPAGATE],t,e,i),this.__templateInfo&&this._runEffectsForTemplate(this.__templateInfo,t,e,i)}_runEffectsForTemplate(t,e,i,s){const o=(e,s)=>{ur(this,t.propertyEffects,e,i,s,t.nodeList);for(let o=t.firstChild;o;o=o.nextSibling)this._runEffectsForTemplate(o,e,i,s)};t.runEffects?t.runEffects(o,e,s):o(e,s)}linkPaths(t,e){t=zo(t),e=zo(e),this.__dataLinkedPaths=this.__dataLinkedPaths||{},this.__dataLinkedPaths[t]=e}unlinkPaths(t){t=zo(t),this.__dataLinkedPaths&&delete this.__dataLinkedPaths[t]}notifySplices(t,e){let i={path:""};jr(this,Eo(this,t,i),i.path,e)}get(t,e){return Eo(e||this,t)}set(t,e,i){i?To(i,t,e):(!this[lr.READ_ONLY]||!this[lr.READ_ONLY][t])&&this._setPendingPropertyOrPath(t,e,!0)&&this._invalidateProperties()}push(t,...e){let i={path:""},s=Eo(this,t,i),o=s.length,r=s.push(...e);return e.length&&Vr(this,s,i.path,o,e.length,[]),r}pop(t){let e={path:""},i=Eo(this,t,e),s=!!i.length,o=i.pop();return s&&Vr(this,i,e.path,i.length,0,[o]),o}splice(t,e,i,...s){let o,r={path:""},n=Eo(this,t,r);return e<0?e=n.length-Math.floor(-e):e&&(e=Math.floor(e)),o=2===arguments.length?n.splice(e):n.splice(e,i,...s),(s.length||o.length)&&Vr(this,n,r.path,e,s.length,o),o}shift(t){let e={path:""},i=Eo(this,t,e),s=!!i.length,o=i.shift();return s&&Vr(this,i,e.path,0,0,[o]),o}unshift(t,...e){let i={path:""},s=Eo(this,t,i),o=s.unshift(...e);return e.length&&Vr(this,s,i.path,0,e.length,[]),o}notifyPath(t,e){let i;if(1==arguments.length){let s={path:""};e=Eo(this,t,s),i=s.path}else i=Array.isArray(t)?zo(t):t;this._setPendingPropertyOrPath(i,e,!0,!0)&&this._invalidateProperties()}_createReadOnlyProperty(t,e){this._addPropertyEffect(t,lr.READ_ONLY),e&&(this["_set"+function(t){return t[0].toUpperCase()+t.substring(1)}(t)]=function(e){this._setProperty(t,e)})}_createPropertyObserver(t,e,i){let s={property:t,method:e,dynamicFn:!!i};this._addPropertyEffect(t,lr.OBSERVE,{fn:vr,info:s,trigger:{name:t}}),i&&this._addPropertyEffect(e,lr.OBSERVE,{fn:vr,info:s,trigger:{name:e}})}_createMethodObserver(t,e){let i=Fr(t);if(!i)throw new Error("Malformed observer expression '"+t+"'");Ir(this,i,lr.OBSERVE,Er,null,e)}_createNotifyingProperty(t){this._addPropertyEffect(t,lr.NOTIFY,{fn:gr,info:{eventName:Fo(t)+"-changed",property:t}})}_createReflectedProperty(t){let e=this.constructor.attributeNameForProperty(t);"-"===e[0]?console.warn("Property "+t+" cannot be reflected to attribute "+e+' because "-" is not a valid starting attribute name. Use a lowercase first letter for the property instead.'):this._addPropertyEffect(t,lr.REFLECT,{fn:yr,info:{attrName:e}})}_createComputedProperty(t,e,i){let s=Fr(e);if(!s)throw new Error("Malformed computed expression '"+e+"'");const o=Ir(this,s,lr.COMPUTE,xr,t,i);cr(this,hr)[t]=o}_marshalArgs(t,e,i){const s=this.__data,o=[];for(let r=0,n=t.length;r<n;r++){let{name:n,structured:a,wildcard:l,value:h,literal:d}=t[r];if(!d)if(l){const t=Ao(n,e),o=Br(s,i,t?e:n);h={path:t?e:n,value:o,base:t?Eo(s,n):o}}else h=a?Br(s,i,n):s[n];if(Xs&&!this._overrideLegacyUndefined&&void 0===h&&t.length>1)return ar;o[r]=h}return o}static addPropertyEffect(t,e,i){this.prototype._addPropertyEffect(t,e,i)}static createPropertyObserver(t,e,i){this.prototype._createPropertyObserver(t,e,i)}static createMethodObserver(t,e){this.prototype._createMethodObserver(t,e)}static createNotifyingProperty(t){this.prototype._createNotifyingProperty(t)}static createReadOnlyProperty(t,e){this.prototype._createReadOnlyProperty(t,e)}static createReflectedProperty(t){this.prototype._createReflectedProperty(t)}static createComputedProperty(t,e,i){this.prototype._createComputedProperty(t,e,i)}static bindTemplate(t){return this.prototype._bindTemplate(t)}_bindTemplate(t,e){let i=this.constructor._parseTemplate(t),s=this.__preBoundTemplateInfo==i;if(!s)for(let t in i.propertyEffects)this._createPropertyAccessor(t);if(e)if(i=Object.create(i),i.wasPreBound=s,this.__templateInfo){const e=t._parentTemplateInfo||this.__templateInfo,s=e.lastChild;i.parent=e,e.lastChild=i,i.previousSibling=s,s?s.nextSibling=i:e.firstChild=i}else this.__templateInfo=i;else this.__preBoundTemplateInfo=i;return i}static _addTemplatePropertyEffect(t,e,i){(t.hostProps=t.hostProps||{})[e]=!0;let s=t.propertyEffects=t.propertyEffects||{};(s[e]=s[e]||[]).push(i)}_stampTemplate(t,e){e=e||this._bindTemplate(t,!0),Rr.push(this);let i=super._stampTemplate(t,e);if(Rr.pop(),e.nodeList=i.nodeList,!e.wasPreBound){let t=e.childNodes=[];for(let e=i.firstChild;e;e=e.nextSibling)t.push(e)}return i.templateInfo=e,function(t,e){let{nodeList:i,nodeInfoList:s}=e;if(s.length)for(let e=0;e<s.length;e++){let o=i[e],r=s[e].bindings;if(r)for(let e=0;e<r.length;e++){let i=r[e];Sr(o,i),zr(o,t,i)}o.__dataHost=t}}(this,e),this.__dataClientsReady&&(this._runEffectsForTemplate(e,this.__data,null,!1),this._flushClients()),i}_removeBoundDom(t){const e=t.templateInfo,{previousSibling:i,nextSibling:s,parent:o}=e;i?i.nextSibling=s:o&&(o.firstChild=s),s?s.previousSibling=i:o&&(o.lastChild=i),e.nextSibling=e.previousSibling=null;let r=e.childNodes;for(let t=0;t<r.length;t++){let e=r[t];_o(_o(e).parentNode).removeChild(e)}}static _parseTemplateNode(t,i,s){let o=e._parseTemplateNode.call(this,t,i,s);if(t.nodeType===Node.TEXT_NODE){let e=this._parseBindings(t.textContent,i);e&&(t.textContent=Pr(e)||" ",kr(this,i,s,"text","textContent",e),o=!0)}return o}static _parseTemplateNodeAttribute(t,i,s,o,r){let n=this._parseBindings(r,i);if(n){let e=o,r="property";dr.test(o)?r="attribute":"$"==o[o.length-1]&&(o=o.slice(0,-1),r="attribute");let a=Pr(n);return a&&"attribute"==r&&("class"==o&&t.hasAttribute("class")&&(a+=" "+t.getAttribute(o)),t.setAttribute(o,a)),"attribute"==r&&"disable-upgrade$"==e&&t.setAttribute(o,""),"input"===t.localName&&"value"===e&&t.setAttribute(e,""),t.removeAttribute(e),"property"===r&&(o=Po(o)),kr(this,i,s,r,o,n,a),!0}return e._parseTemplateNodeAttribute.call(this,t,i,s,o,r)}static _parseTemplateNestedTemplate(t,i,s){let o=e._parseTemplateNestedTemplate.call(this,t,i,s);const r=t.parentNode,n=s.templateInfo,a="dom-if"===r.localName;to&&(a||"dom-repeat"===r.localName)&&(r.removeChild(t),(s=s.parentInfo).templateInfo=n,s.noted=!0,o=!1);let l=n.hostProps;if(eo&&a)l&&(i.hostProps=Object.assign(i.hostProps||{},l),to||(s.parentInfo.noted=!0));else{let t="{";for(let e in l)kr(this,i,s,"property","_host_"+e,[{mode:t,source:e,dependencies:[e],hostProp:!0}])}return o}static _parseBindings(t,e){let i,s=[],o=0;for(;null!==(i=Or.exec(t));){i.index>o&&s.push({literal:t.slice(o,i.index)});let r=i[1][0],n=!!i[2],a=i[3].trim(),l=!1,h="",d=-1;"{"==r&&(d=a.indexOf("::"))>0&&(h=a.substring(d+2),a=a.substring(0,d),l=!0);let c=Fr(a),u=[];if(c){let{args:t,methodName:i}=c;for(let e=0;e<t.length;e++){let i=t[e];i.literal||u.push(i)}let s=e.dynamicFns;(s&&s[i]||c.static)&&(u.push(i),c.dynamicFn=!0)}else u.push(a);s.push({source:a,mode:r,negate:n,customEvent:l,signature:c,dependencies:u,event:h}),o=Or.lastIndex}if(o&&o<t.length){let e=t.substring(o);e&&s.push({literal:e})}return s.length?s:null}static _evaluateBinding(t,e,i,s,o,r){let n;return n=e.signature?Er(t,i,s,0,e.signature):i!=e.source?Eo(t,e.source):r&&xo(i)?Eo(t,i):t.__data[i],e.negate&&(n=!n),n}}})),Rr=[],qr=ro((t=>{const e=Wo(t);function i(t){const e=Object.getPrototypeOf(t);return e.prototype instanceof o?e:null}function s(t){if(!t.hasOwnProperty(JSCompiler_renameProperty("__ownProperties",t))){let e=null;if(t.hasOwnProperty(JSCompiler_renameProperty("properties",t))){const i=t.properties;i&&(e=
|
|
969
|
+
*/let nr=0;const ar=[],lr={COMPUTE:"__computeEffects",REFLECT:"__reflectEffects",NOTIFY:"__notifyEffects",PROPAGATE:"__propagateEffects",OBSERVE:"__observeEffects",READ_ONLY:"__readOnly"},hr="__computeInfo",dr=/[A-Z]/;function cr(t,e,i){let s=t[e];if(s){if(!t.hasOwnProperty(e)&&(s=t[e]=Object.create(t[e]),i))for(let t in s){let e=s[t],i=s[t]=Array(e.length);for(let t=0;t<e.length;t++)i[t]=e[t]}}else s=t[e]={};return s}function ur(t,e,i,s,o,r){if(e){let n=!1;const a=nr++;for(let l in i){let h=e[o?ko(l):l];if(h)for(let e,d=0,c=h.length;d<c&&(e=h[d]);d++)(!e.info||e.info.lastRun!==a)&&(!o||mr(l,e.trigger))&&(e.info&&(e.info.lastRun=a),e.fn(t,l,i,s,e.info,o,r),n=!0)}return n}return!1}function pr(t,e,i,s,o,r,n,a){let l=!1,h=e[n?ko(s):s];if(h)for(let e,d=0,c=h.length;d<c&&(e=h[d]);d++)(!e.info||e.info.lastRun!==i)&&(!n||mr(s,e.trigger))&&(e.info&&(e.info.lastRun=i),e.fn(t,s,o,r,e.info,n,a),l=!0);return l}function mr(t,e){if(e){let i=e.name;return i==t||!(!e.structured||!Co(i,t))||!(!e.wildcard||!Ao(i,t))}return!0}function vr(t,e,i,s,o){let r="string"==typeof o.method?t[o.method]:o.method,n=o.property;r?r.call(t,t.__data[n],s[n]):o.dynamicFn||console.warn("observer method `"+o.method+"` not defined")}function fr(t,e,i){let s=ko(e);return s!==e&&(gr(t,Fo(s)+"-changed",i[e],e),!0)}function gr(t,e,i,s){let o={value:i,queueProperty:!0};s&&(o.path=s),_o(t).dispatchEvent(new CustomEvent(e,{detail:o}))}function br(t,e,i,s,o,r){let n=(r?ko(e):e)!=e?e:null,a=n?Eo(t,n):t.__data[e];n&&void 0===a&&(a=i[e]),gr(t,o.eventName,a,n)}function yr(t,e,i,s,o){let r=t.__data[e];Gs&&(r=Gs(r,o.attrName,"attribute",t)),t._propertyToAttribute(e,o.attrName,r)}const wr=(t,e,i)=>{let s=0,o=e.length-1,r=-1;for(;s<=o;){const n=s+o>>1,a=i.get(e[n].methodInfo)-i.get(t.methodInfo);if(a<0)s=n+1;else{if(!(a>0)){r=n;break}o=n-1}}r<0&&(r=o+1),e.splice(r,0,t)},_r=(t,e,i,s,o)=>{const r=e[o?ko(t):t];if(r)for(let e=0;e<r.length;e++){const n=r[e];n.info.lastRun!==nr&&(!o||mr(t,n.trigger))&&(n.info.lastRun=nr,wr(n.info,i,s))}};function xr(t,e,i,s,o){let r=Er(t,e,i,0,o);if(r===ar)return!1;let n=o.methodInfo;return t.__dataHasAccessor&&t.__dataHasAccessor[n]?t._setPendingProperty(n,r,!0):(t[n]=r,!1)}function kr(t,e,i,s,o,r,n){i.bindings=i.bindings||[];let a={kind:s,target:o,parts:r,literal:n,isCompound:1!==r.length};if(i.bindings.push(a),function(t){return!!t.target&&"attribute"!=t.kind&&"text"!=t.kind&&!t.isCompound&&"{"===t.parts[0].mode}(a)){let{event:t,negate:e}=a.parts[0];a.listenerEvent=t||Fo(o)+"-changed",a.listenerNegate=e}let l=e.nodeInfoList.length;for(let i=0;i<a.parts.length;i++){let s=a.parts[i];s.compoundIndex=i,Cr(t,e,a,s,l)}}function Cr(t,e,i,s,o){if(!s.literal)if("attribute"===i.kind&&"-"===i.target[0])console.warn("Cannot set attribute "+i.target+' because "-" is not a valid attribute starting character');else{let r=s.dependencies,n={index:o,binding:i,part:s,evaluator:t};for(let i=0;i<r.length;i++){let s=r[i];"string"==typeof s&&(s=Nr(s),s.wildcard=!0),t._addTemplatePropertyEffect(e,s.rootProperty,{fn:Ar,info:n,trigger:s})}}}function Ar(t,e,i,s,o,r,n){let a=n[o.index],l=o.binding,h=o.part;if(r&&h.source&&e.length>h.source.length&&"property"==l.kind&&!l.isCompound&&a.__isPropertyEffectsClient&&a.__dataHasAccessor&&a.__dataHasAccessor[l.target]){let s=i[e];e=So(h.source,l.target,e),a._setPendingPropertyOrPath(e,s,!1,!0)&&t._enqueueClient(a)}else{let n=o.evaluator._evaluateBinding(t,h,e,i,s,r);n!==ar&&function(t,e,i,s,o){if(o=function(t,e,i,s){if(i.isCompound){let o=t.__dataCompoundStorage[i.target];o[s.compoundIndex]=e,e=o.join("")}return"attribute"!==i.kind&&("textContent"===i.target||"value"===i.target&&("input"===t.localName||"textarea"===t.localName))&&(e=null==e?"":e),e}(e,o,i,s),Gs&&(o=Gs(o,i.target,i.kind,e)),"attribute"==i.kind)t._valueToNodeAttribute(e,o,i.target);else{let s=i.target;e.__isPropertyEffectsClient&&e.__dataHasAccessor&&e.__dataHasAccessor[s]?(!e[lr.READ_ONLY]||!e[lr.READ_ONLY][s])&&e._setPendingProperty(s,o)&&t._enqueueClient(e):t._setUnmanagedPropertyToNode(e,s,o)}}(t,a,l,h,n)}}function Sr(t,e){if(e.isCompound){let i=t.__dataCompoundStorage||(t.__dataCompoundStorage={}),s=e.parts,o=new Array(s.length);for(let t=0;t<s.length;t++)o[t]=s[t].literal;let r=e.target;i[r]=o,e.literal&&"property"==e.kind&&("className"===r&&(t=_o(t)),t[r]=e.literal)}}function zr(t,e,i){if(i.listenerEvent){let s=i.parts[0];t.addEventListener(i.listenerEvent,(function(t){!function(t,e,i,s,o){let r,n=t.detail,a=n&&n.path;a?(s=So(i,s,a),r=n&&n.value):r=t.currentTarget[i],r=o?!r:r,(!e[lr.READ_ONLY]||!e[lr.READ_ONLY][s])&&e._setPendingPropertyOrPath(s,r,!0,!!a)&&(!n||!n.queueProperty)&&e._invalidateProperties()}(t,e,i.target,s.source,s.negate)}))}}function Ir(t,e,i,s,o,r){let n={methodName:e.methodName,args:e.args,methodInfo:o,dynamicFn:r=e.static||r&&("object"!=typeof r||r[e.methodName])};for(let o,r=0;r<e.args.length&&(o=e.args[r]);r++)o.literal||t._addPropertyEffect(o.rootProperty,i,{fn:s,info:n,trigger:o});return r&&t._addPropertyEffect(e.methodName,i,{fn:s,info:n}),n}function Er(t,e,i,s,o){let r=t._methodHost||t,n=r[o.methodName];if(n){let s=t._marshalArgs(o.args,e,i);return s===ar?ar:n.apply(r,s)}o.dynamicFn||console.warn("method `"+o.methodName+"` not defined")}const Tr=[],Mr="(?:[a-zA-Z_$][\\w.:$\\-*]*)",Dr="(?:("+Mr+"|(?:[-+]?[0-9]*\\.?[0-9]+(?:[eE][-+]?[0-9]+)?)|(?:(?:'(?:[^'\\\\]|\\\\.)*')|(?:\"(?:[^\"\\\\]|\\\\.)*\")))\\s*)",Or=new RegExp("(\\[\\[|{{)\\s*(?:(!)\\s*)?("+Mr+"\\s*(?:\\(\\s*(?:(?:"+Dr+"(?:,\\s*"+Dr+")*)?)\\)\\s*)?)(?:]]|}})","g");function Pr(t){let e="";for(let i=0;i<t.length;i++)e+=t[i].literal||"";return e}function Fr(t){let e=t.match(/([^\s]+?)\(([\s\S]*)\)/);if(e){let t={methodName:e[1],static:!0,args:Tr};return e[2].trim()?function(t,e){return e.args=t.map((function(t){let i=Nr(t);return i.literal||(e.static=!1),i}),this),e}(e[2].replace(/\\,/g,",").split(","),t):t}return null}function Nr(t){let e=t.trim().replace(/,/g,",").replace(/\\(.)/g,"$1"),i={name:e,value:"",literal:!1},s=e[0];switch("-"===s&&(s=e[1]),s>="0"&&s<="9"&&(s="#"),s){case"'":case'"':i.value=e.slice(1,-1),i.literal=!0;break;case"#":i.value=Number(e),i.literal=!0}return i.literal||(i.rootProperty=ko(e),i.structured=xo(e),i.structured&&(i.wildcard=".*"==e.slice(-2),i.wildcard&&(i.name=e.slice(0,-2)))),i}function Br(t,e,i){let s=Eo(t,i);return void 0===s&&(s=e[i]),s}function jr(t,e,i,s){const o={indexSplices:s};Xs&&!t._overrideLegacyUndefined&&(e.splices=o),t.notifyPath(i+".splices",o),t.notifyPath(i+".length",e.length),Xs&&!t._overrideLegacyUndefined&&(o.indexSplices=[])}function Vr(t,e,i,s,o,r){jr(t,e,i,[{index:s,addedCount:o,removed:r,object:e,type:"splice"}])}const Lr=ro((t=>{const e=rr(Ko(t));return class extends e{constructor(){super(),this.__isPropertyEffectsClient=!0}get PROPERTY_EFFECT_TYPES(){return lr}_initializeProperties(){super._initializeProperties(),this._registerHost(),this.__dataClientsReady=!1,this.__dataPendingClients=null,this.__dataToNotify=null,this.__dataLinkedPaths=null,this.__dataHasPaths=!1,this.__dataCompoundStorage=this.__dataCompoundStorage||null,this.__dataHost=this.__dataHost||null,this.__dataTemp={},this.__dataClientsInitialized=!1}_registerHost(){if(Rr.length){let t=Rr[Rr.length-1];t._enqueueClient(this),this.__dataHost=t}}_initializeProtoProperties(t){this.__data=Object.create(t),this.__dataPending=Object.create(t),this.__dataOld={}}_initializeInstanceProperties(t){let e=this[lr.READ_ONLY];for(let i in t)(!e||!e[i])&&(this.__dataPending=this.__dataPending||{},this.__dataOld=this.__dataOld||{},this.__data[i]=this.__dataPending[i]=t[i])}_addPropertyEffect(t,e,i){this._createPropertyAccessor(t,e==lr.READ_ONLY);let s=cr(this,e,!0)[t];s||(s=this[e][t]=[]),s.push(i)}_removePropertyEffect(t,e,i){let s=cr(this,e,!0)[t],o=s.indexOf(i);o>=0&&s.splice(o,1)}_hasPropertyEffect(t,e){let i=this[e];return!(!i||!i[t])}_hasReadOnlyEffect(t){return this._hasPropertyEffect(t,lr.READ_ONLY)}_hasNotifyEffect(t){return this._hasPropertyEffect(t,lr.NOTIFY)}_hasReflectEffect(t){return this._hasPropertyEffect(t,lr.REFLECT)}_hasComputedEffect(t){return this._hasPropertyEffect(t,lr.COMPUTE)}_setPendingPropertyOrPath(t,e,i,s){if(s||ko(Array.isArray(t)?t[0]:t)!==t){if(!s){let i=Eo(this,t);if(!(t=To(this,t,e))||!super._shouldPropertyChange(t,e,i))return!1}if(this.__dataHasPaths=!0,this._setPendingProperty(t,e,i))return function(t,e,i){let s=t.__dataLinkedPaths;if(s){let o;for(let r in s){let n=s[r];Ao(r,e)?(o=So(r,n,e),t._setPendingPropertyOrPath(o,i,!0,!0)):Ao(n,e)&&(o=So(n,r,e),t._setPendingPropertyOrPath(o,i,!0,!0))}}}(this,t,e),!0}else{if(this.__dataHasAccessor&&this.__dataHasAccessor[t])return this._setPendingProperty(t,e,i);this[t]=e}return!1}_setUnmanagedPropertyToNode(t,e,i){(i!==t[e]||"object"==typeof i)&&("className"===e&&(t=_o(t)),t[e]=i)}_setPendingProperty(t,e,i){let s=this.__dataHasPaths&&xo(t);return!!this._shouldPropertyChange(t,e,(s?this.__dataTemp:this.__data)[t])&&(this.__dataPending||(this.__dataPending={},this.__dataOld={}),t in this.__dataOld||(this.__dataOld[t]=this.__data[t]),s?this.__dataTemp[t]=e:this.__data[t]=e,this.__dataPending[t]=e,(s||this[lr.NOTIFY]&&this[lr.NOTIFY][t])&&(this.__dataToNotify=this.__dataToNotify||{},this.__dataToNotify[t]=i),!0)}_setProperty(t,e){this._setPendingProperty(t,e,!0)&&this._invalidateProperties()}_invalidateProperties(){this.__dataReady&&this._flushProperties()}_enqueueClient(t){this.__dataPendingClients=this.__dataPendingClients||[],t!==this&&this.__dataPendingClients.push(t)}_flushClients(){this.__dataClientsReady?this.__enableOrFlushClients():(this.__dataClientsReady=!0,this._readyClients(),this.__dataReady=!0)}__enableOrFlushClients(){let t=this.__dataPendingClients;if(t){this.__dataPendingClients=null;for(let e=0;e<t.length;e++){let i=t[e];i.__dataEnabled?i.__dataPending&&i._flushProperties():i._enableProperties()}}}_readyClients(){this.__enableOrFlushClients()}setProperties(t,e){for(let i in t)(e||!this[lr.READ_ONLY]||!this[lr.READ_ONLY][i])&&this._setPendingPropertyOrPath(i,t[i],!0);this._invalidateProperties()}ready(){this._flushProperties(),this.__dataClientsReady||this._flushClients(),this.__dataPending&&this._flushProperties()}_propertiesChanged(t,e,i){let s,o=this.__dataHasPaths;this.__dataHasPaths=!1,function(t,e,i,s){let o=t[lr.COMPUTE];if(o)if(Zs){nr++;const r=function(t){let e=t.constructor.__orderedComputedDeps;if(!e){e=new Map;const i=t[lr.COMPUTE];let s,{counts:o,ready:r,total:n}=function(t){const e=t[hr],i={},s=t[lr.COMPUTE],o=[];let r=0;for(let t in e){const s=e[t];r+=i[t]=s.args.filter((t=>!t.literal)).length+(s.dynamicFn?1:0)}for(let t in s)e[t]||o.push(t);return{counts:i,ready:o,total:r}}(t);for(;s=r.shift();){e.set(s,e.size);const t=i[s];t&&t.forEach((t=>{const e=t.info.methodInfo;--n,0==--o[e]&&r.push(e)}))}0!==n&&console.warn(`Computed graph for ${t.localName} incomplete; circular?`),t.constructor.__orderedComputedDeps=e}return e}(t),n=[];for(let t in e)_r(t,o,n,r,s);let a;for(;a=n.shift();)xr(t,"",e,0,a)&&_r(a.methodInfo,o,n,r,s);Object.assign(i,t.__dataOld),Object.assign(e,t.__dataPending),t.__dataPending=null}else{let r=e;for(;ur(t,o,r,i,s);)Object.assign(i,t.__dataOld),Object.assign(e,t.__dataPending),r=t.__dataPending,t.__dataPending=null}}(this,e,i,o),s=this.__dataToNotify,this.__dataToNotify=null,this._propagatePropertyChanges(e,i,o),this._flushClients(),ur(this,this[lr.REFLECT],e,i,o),ur(this,this[lr.OBSERVE],e,i,o),s&&function(t,e,i,s,o){let r,n,a=t[lr.NOTIFY],l=nr++;for(let n in e)e[n]&&(a&&pr(t,a,l,n,i,s,o)||o&&fr(t,n,i))&&(r=!0);r&&(n=t.__dataHost)&&n._invalidateProperties&&n._invalidateProperties()}(this,s,e,i,o),1==this.__dataCounter&&(this.__dataTemp={})}_propagatePropertyChanges(t,e,i){this[lr.PROPAGATE]&&ur(this,this[lr.PROPAGATE],t,e,i),this.__templateInfo&&this._runEffectsForTemplate(this.__templateInfo,t,e,i)}_runEffectsForTemplate(t,e,i,s){const o=(e,s)=>{ur(this,t.propertyEffects,e,i,s,t.nodeList);for(let o=t.firstChild;o;o=o.nextSibling)this._runEffectsForTemplate(o,e,i,s)};t.runEffects?t.runEffects(o,e,s):o(e,s)}linkPaths(t,e){t=zo(t),e=zo(e),this.__dataLinkedPaths=this.__dataLinkedPaths||{},this.__dataLinkedPaths[t]=e}unlinkPaths(t){t=zo(t),this.__dataLinkedPaths&&delete this.__dataLinkedPaths[t]}notifySplices(t,e){let i={path:""};jr(this,Eo(this,t,i),i.path,e)}get(t,e){return Eo(e||this,t)}set(t,e,i){i?To(i,t,e):(!this[lr.READ_ONLY]||!this[lr.READ_ONLY][t])&&this._setPendingPropertyOrPath(t,e,!0)&&this._invalidateProperties()}push(t,...e){let i={path:""},s=Eo(this,t,i),o=s.length,r=s.push(...e);return e.length&&Vr(this,s,i.path,o,e.length,[]),r}pop(t){let e={path:""},i=Eo(this,t,e),s=!!i.length,o=i.pop();return s&&Vr(this,i,e.path,i.length,0,[o]),o}splice(t,e,i,...s){let o,r={path:""},n=Eo(this,t,r);return e<0?e=n.length-Math.floor(-e):e&&(e=Math.floor(e)),o=2===arguments.length?n.splice(e):n.splice(e,i,...s),(s.length||o.length)&&Vr(this,n,r.path,e,s.length,o),o}shift(t){let e={path:""},i=Eo(this,t,e),s=!!i.length,o=i.shift();return s&&Vr(this,i,e.path,0,0,[o]),o}unshift(t,...e){let i={path:""},s=Eo(this,t,i),o=s.unshift(...e);return e.length&&Vr(this,s,i.path,0,e.length,[]),o}notifyPath(t,e){let i;if(1==arguments.length){let s={path:""};e=Eo(this,t,s),i=s.path}else i=Array.isArray(t)?zo(t):t;this._setPendingPropertyOrPath(i,e,!0,!0)&&this._invalidateProperties()}_createReadOnlyProperty(t,e){this._addPropertyEffect(t,lr.READ_ONLY),e&&(this["_set"+function(t){return t[0].toUpperCase()+t.substring(1)}(t)]=function(e){this._setProperty(t,e)})}_createPropertyObserver(t,e,i){let s={property:t,method:e,dynamicFn:!!i};this._addPropertyEffect(t,lr.OBSERVE,{fn:vr,info:s,trigger:{name:t}}),i&&this._addPropertyEffect(e,lr.OBSERVE,{fn:vr,info:s,trigger:{name:e}})}_createMethodObserver(t,e){let i=Fr(t);if(!i)throw new Error("Malformed observer expression '"+t+"'");Ir(this,i,lr.OBSERVE,Er,null,e)}_createNotifyingProperty(t){this._addPropertyEffect(t,lr.NOTIFY,{fn:br,info:{eventName:Fo(t)+"-changed",property:t}})}_createReflectedProperty(t){let e=this.constructor.attributeNameForProperty(t);"-"===e[0]?console.warn("Property "+t+" cannot be reflected to attribute "+e+' because "-" is not a valid starting attribute name. Use a lowercase first letter for the property instead.'):this._addPropertyEffect(t,lr.REFLECT,{fn:yr,info:{attrName:e}})}_createComputedProperty(t,e,i){let s=Fr(e);if(!s)throw new Error("Malformed computed expression '"+e+"'");const o=Ir(this,s,lr.COMPUTE,xr,t,i);cr(this,hr)[t]=o}_marshalArgs(t,e,i){const s=this.__data,o=[];for(let r=0,n=t.length;r<n;r++){let{name:n,structured:a,wildcard:l,value:h,literal:d}=t[r];if(!d)if(l){const t=Ao(n,e),o=Br(s,i,t?e:n);h={path:t?e:n,value:o,base:t?Eo(s,n):o}}else h=a?Br(s,i,n):s[n];if(Xs&&!this._overrideLegacyUndefined&&void 0===h&&t.length>1)return ar;o[r]=h}return o}static addPropertyEffect(t,e,i){this.prototype._addPropertyEffect(t,e,i)}static createPropertyObserver(t,e,i){this.prototype._createPropertyObserver(t,e,i)}static createMethodObserver(t,e){this.prototype._createMethodObserver(t,e)}static createNotifyingProperty(t){this.prototype._createNotifyingProperty(t)}static createReadOnlyProperty(t,e){this.prototype._createReadOnlyProperty(t,e)}static createReflectedProperty(t){this.prototype._createReflectedProperty(t)}static createComputedProperty(t,e,i){this.prototype._createComputedProperty(t,e,i)}static bindTemplate(t){return this.prototype._bindTemplate(t)}_bindTemplate(t,e){let i=this.constructor._parseTemplate(t),s=this.__preBoundTemplateInfo==i;if(!s)for(let t in i.propertyEffects)this._createPropertyAccessor(t);if(e)if(i=Object.create(i),i.wasPreBound=s,this.__templateInfo){const e=t._parentTemplateInfo||this.__templateInfo,s=e.lastChild;i.parent=e,e.lastChild=i,i.previousSibling=s,s?s.nextSibling=i:e.firstChild=i}else this.__templateInfo=i;else this.__preBoundTemplateInfo=i;return i}static _addTemplatePropertyEffect(t,e,i){(t.hostProps=t.hostProps||{})[e]=!0;let s=t.propertyEffects=t.propertyEffects||{};(s[e]=s[e]||[]).push(i)}_stampTemplate(t,e){e=e||this._bindTemplate(t,!0),Rr.push(this);let i=super._stampTemplate(t,e);if(Rr.pop(),e.nodeList=i.nodeList,!e.wasPreBound){let t=e.childNodes=[];for(let e=i.firstChild;e;e=e.nextSibling)t.push(e)}return i.templateInfo=e,function(t,e){let{nodeList:i,nodeInfoList:s}=e;if(s.length)for(let e=0;e<s.length;e++){let o=i[e],r=s[e].bindings;if(r)for(let e=0;e<r.length;e++){let i=r[e];Sr(o,i),zr(o,t,i)}o.__dataHost=t}}(this,e),this.__dataClientsReady&&(this._runEffectsForTemplate(e,this.__data,null,!1),this._flushClients()),i}_removeBoundDom(t){const e=t.templateInfo,{previousSibling:i,nextSibling:s,parent:o}=e;i?i.nextSibling=s:o&&(o.firstChild=s),s?s.previousSibling=i:o&&(o.lastChild=i),e.nextSibling=e.previousSibling=null;let r=e.childNodes;for(let t=0;t<r.length;t++){let e=r[t];_o(_o(e).parentNode).removeChild(e)}}static _parseTemplateNode(t,i,s){let o=e._parseTemplateNode.call(this,t,i,s);if(t.nodeType===Node.TEXT_NODE){let e=this._parseBindings(t.textContent,i);e&&(t.textContent=Pr(e)||" ",kr(this,i,s,"text","textContent",e),o=!0)}return o}static _parseTemplateNodeAttribute(t,i,s,o,r){let n=this._parseBindings(r,i);if(n){let e=o,r="property";dr.test(o)?r="attribute":"$"==o[o.length-1]&&(o=o.slice(0,-1),r="attribute");let a=Pr(n);return a&&"attribute"==r&&("class"==o&&t.hasAttribute("class")&&(a+=" "+t.getAttribute(o)),t.setAttribute(o,a)),"attribute"==r&&"disable-upgrade$"==e&&t.setAttribute(o,""),"input"===t.localName&&"value"===e&&t.setAttribute(e,""),t.removeAttribute(e),"property"===r&&(o=Po(o)),kr(this,i,s,r,o,n,a),!0}return e._parseTemplateNodeAttribute.call(this,t,i,s,o,r)}static _parseTemplateNestedTemplate(t,i,s){let o=e._parseTemplateNestedTemplate.call(this,t,i,s);const r=t.parentNode,n=s.templateInfo,a="dom-if"===r.localName;to&&(a||"dom-repeat"===r.localName)&&(r.removeChild(t),(s=s.parentInfo).templateInfo=n,s.noted=!0,o=!1);let l=n.hostProps;if(eo&&a)l&&(i.hostProps=Object.assign(i.hostProps||{},l),to||(s.parentInfo.noted=!0));else{let t="{";for(let e in l)kr(this,i,s,"property","_host_"+e,[{mode:t,source:e,dependencies:[e],hostProp:!0}])}return o}static _parseBindings(t,e){let i,s=[],o=0;for(;null!==(i=Or.exec(t));){i.index>o&&s.push({literal:t.slice(o,i.index)});let r=i[1][0],n=!!i[2],a=i[3].trim(),l=!1,h="",d=-1;"{"==r&&(d=a.indexOf("::"))>0&&(h=a.substring(d+2),a=a.substring(0,d),l=!0);let c=Fr(a),u=[];if(c){let{args:t,methodName:i}=c;for(let e=0;e<t.length;e++){let i=t[e];i.literal||u.push(i)}let s=e.dynamicFns;(s&&s[i]||c.static)&&(u.push(i),c.dynamicFn=!0)}else u.push(a);s.push({source:a,mode:r,negate:n,customEvent:l,signature:c,dependencies:u,event:h}),o=Or.lastIndex}if(o&&o<t.length){let e=t.substring(o);e&&s.push({literal:e})}return s.length?s:null}static _evaluateBinding(t,e,i,s,o,r){let n;return n=e.signature?Er(t,i,s,0,e.signature):i!=e.source?Eo(t,e.source):r&&xo(i)?Eo(t,i):t.__data[i],e.negate&&(n=!n),n}}})),Rr=[],qr=ro((t=>{const e=Wo(t);function i(t){const e=Object.getPrototypeOf(t);return e.prototype instanceof o?e:null}function s(t){if(!t.hasOwnProperty(JSCompiler_renameProperty("__ownProperties",t))){let e=null;if(t.hasOwnProperty(JSCompiler_renameProperty("properties",t))){const i=t.properties;i&&(e=
|
|
970
970
|
/**
|
|
971
971
|
@license
|
|
972
972
|
Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
|
|
@@ -1496,7 +1496,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
1496
1496
|
* @license
|
|
1497
1497
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
1498
1498
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
1499
|
-
*/function
|
|
1499
|
+
*/function gn(t,e,i=t.getAttribute("dir")){e?t.setAttribute("dir",e):null!=i&&t.removeAttribute("dir")}function bn(){return document.documentElement.getAttribute("dir")}new MutationObserver((function(){const t=bn();fn.forEach((e=>{gn(e,t)}))})).observe(document.documentElement,{attributes:!0,attributeFilter:["dir"]});const yn=t=>class extends t{static get properties(){return{dir:{type:String,value:"",reflectToAttribute:!0,converter:{fromAttribute:t=>t||"",toAttribute:t=>""===t?null:t}}}}get __isRTL(){return"rtl"===this.getAttribute("dir")}connectedCallback(){super.connectedCallback(),(!this.hasAttribute("dir")||this.__restoreSubscription)&&(this.__subscribe(),gn(this,bn(),null))}attributeChangedCallback(t,e,i){if(super.attributeChangedCallback(t,e,i),"dir"!==t)return;const s=bn(),o=i===s&&-1===fn.indexOf(this),r=!i&&e&&-1===fn.indexOf(this);o||r?(this.__subscribe(),gn(this,s,i)):i!==s&&e===s&&this.__unsubscribe()}disconnectedCallback(){super.disconnectedCallback(),this.__restoreSubscription=fn.includes(this),this.__unsubscribe()}_valueToNodeAttribute(t,e,i){"dir"===i&&""===e&&!t.hasAttribute("dir")||super._valueToNodeAttribute(t,e,i)}_attributeToProperty(t,e,i){"dir"!==t||e?super._attributeToProperty(t,e,i):this.dir=""}__subscribe(){fn.includes(this)||fn.push(this)}__unsubscribe(){fn.includes(this)&&fn.splice(fn.indexOf(this),1)}}
|
|
1500
1500
|
/**
|
|
1501
1501
|
* @license
|
|
1502
1502
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
@@ -1552,7 +1552,7 @@ const Dn=t=>t,On="string"==typeof document.head.style.touchAction,Pn="__polymerG
|
|
|
1552
1552
|
* @license
|
|
1553
1553
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
1554
1554
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
1555
|
-
*/let da=!1;function ca(){let t=document.activeElement||document.body;for(;t.shadowRoot&&t.shadowRoot.activeElement;)t=t.shadowRoot.activeElement;return t}function ua(){return da}function pa(t){const e=t.style;if("hidden"===e.visibility||"none"===e.display)return!0;const i=window.getComputedStyle(t);return"hidden"===i.visibility||"none"===i.display}function ma(t,e){const i=Math.max(t.tabIndex,0),s=Math.max(e.tabIndex,0);return 0===i||0===s?s>i:i>s}function va(t){const e=t.length;if(e<2)return t;const i=Math.ceil(e/2);return function(t,e){const i=[];for(;t.length>0&&e.length>0;)ma(t[0],e[0])?i.push(e.shift()):i.push(t.shift());return i.concat(t,e)}(va(t.slice(0,i)),va(t.slice(i)))}function fa(t){return null===t.offsetParent&&0===t.clientWidth&&0===t.clientHeight||pa(t)}function
|
|
1555
|
+
*/let da=!1;function ca(){let t=document.activeElement||document.body;for(;t.shadowRoot&&t.shadowRoot.activeElement;)t=t.shadowRoot.activeElement;return t}function ua(){return da}function pa(t){const e=t.style;if("hidden"===e.visibility||"none"===e.display)return!0;const i=window.getComputedStyle(t);return"hidden"===i.visibility||"none"===i.display}function ma(t,e){const i=Math.max(t.tabIndex,0),s=Math.max(e.tabIndex,0);return 0===i||0===s?s>i:i>s}function va(t){const e=t.length;if(e<2)return t;const i=Math.ceil(e/2);return function(t,e){const i=[];for(;t.length>0&&e.length>0;)ma(t[0],e[0])?i.push(e.shift()):i.push(t.shift());return i.concat(t,e)}(va(t.slice(0,i)),va(t.slice(i)))}function fa(t){return null===t.offsetParent&&0===t.clientWidth&&0===t.clientHeight||pa(t)}function ga(t){return!t.matches('[tabindex="-1"]')&&(t.matches("input, select, textarea, button, object")?t.matches(":not([disabled])"):t.matches("a[href], area[href], iframe, [tabindex], [contentEditable]"))}function ba(t){return t.getRootNode().activeElement===t}function ya(t,e){if(t.nodeType!==Node.ELEMENT_NODE||pa(t))return!1;const i=t,s=function(t){if(!ga(t))return-1;const e=t.getAttribute("tabindex")||0;return Number(e)}(i);let o=s>0;s>=0&&e.push(i);let r=[];return r="slot"===i.localName?i.assignedNodes({flatten:!0}):(i.shadowRoot||i).children,[...r].forEach((t=>{o=ya(t,e)||o})),o}window.addEventListener("keydown",(()=>{da=!0}),{capture:!0}),window.addEventListener("mousedown",(()=>{da=!1}),{capture:!0});
|
|
1556
1556
|
/**
|
|
1557
1557
|
* @license
|
|
1558
1558
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
@@ -3377,7 +3377,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
3377
3377
|
* @license
|
|
3378
3378
|
* Copyright (c) 2017 Anton Korzunov
|
|
3379
3379
|
* SPDX-License-Identifier: MIT
|
|
3380
|
-
*/let vl=new WeakMap,fl=new WeakMap,
|
|
3380
|
+
*/let vl=new WeakMap,fl=new WeakMap,gl={},bl=0;const yl=t=>t&&t.nodeType===Node.ELEMENT_NODE,wl=(...t)=>{console.error(`Error: ${t.join(" ")}. Skip setting aria-hidden.`)},_l=(t,e=document.body,i="data-aria-hidden")=>{const s=Array.from(Array.isArray(t)?t:[t]);return e&&s.push(...Array.from(e.querySelectorAll("[aria-live]"))),((t,e,i,s)=>{const o=((t,e)=>yl(t)?e.map((e=>{if(!yl(e))return wl(e,"is not a valid element"),null;let i=e;for(;i&&i!==t;){if(t.contains(i))return e;i=i.getRootNode().host}return wl(e,"is not contained inside",t),null})).filter((t=>!!t)):(wl(t,"is not a valid element"),[]))(e,Array.isArray(t)?t:[t]);gl[i]||(gl[i]=new WeakMap);const r=gl[i],n=[],a=new Set,l=new Set(o),h=t=>{if(!t||a.has(t))return;a.add(t);const e=t.assignedSlot;e&&h(e),h(t.parentNode||t.host)};o.forEach(h);const d=t=>{if(!t||l.has(t))return;const e=t.shadowRoot;(e?[...t.children,...e.children]:[...t.children]).forEach((t=>{if(!["template","script","style"].includes(t.localName))if(a.has(t))d(t);else{const e=t.getAttribute(s),o=null!==e&&"false"!==e,a=(vl.get(t)||0)+1,l=(r.get(t)||0)+1;vl.set(t,a),r.set(t,l),n.push(t),1===a&&o&&fl.set(t,!0),1===l&&t.setAttribute(i,"true"),o||t.setAttribute(s,"true")}}))};return d(e),a.clear(),bl+=1,()=>{n.forEach((t=>{const e=vl.get(t)-1,o=r.get(t)-1;vl.set(t,e),r.set(t,o),e||(fl.has(t)?fl.delete(t):t.removeAttribute(s)),o||t.removeAttribute(i)})),bl-=1,bl||(vl=new WeakMap,vl=new WeakMap,fl=new WeakMap,gl={})}})(s,e,i,"aria-hidden")
|
|
3381
3381
|
/**
|
|
3382
3382
|
* @license
|
|
3383
3383
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
@@ -3393,7 +3393,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
3393
3393
|
* Copyright (c) 2021 - 2024 Vaadin Ltd.
|
|
3394
3394
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
3395
3395
|
*/
|
|
3396
|
-
const Cl=[];let Al=class{constructor(t){this.host=t,this.__trapNode=null,this.__onKeyDown=this.__onKeyDown.bind(this)}get __focusableElements(){return function(t){const e=[];return ya(t,e)?va(e):e}(this.__trapNode)}get __focusedElementIndex(){const t=this.__focusableElements;return t.indexOf(t.filter(
|
|
3396
|
+
const Cl=[];let Al=class{constructor(t){this.host=t,this.__trapNode=null,this.__onKeyDown=this.__onKeyDown.bind(this)}get __focusableElements(){return function(t){const e=[];return ya(t,e)?va(e):e}(this.__trapNode)}get __focusedElementIndex(){const t=this.__focusableElements;return t.indexOf(t.filter(ba).pop())}hostConnected(){document.addEventListener("keydown",this.__onKeyDown)}hostDisconnected(){document.removeEventListener("keydown",this.__onKeyDown)}trapFocus(t){if(this.__trapNode=t,0===this.__focusableElements.length)throw this.__trapNode=null,new Error("The trap node should have at least one focusable descendant or be focusable itself.");Cl.push(this),-1===this.__focusedElementIndex&&this.__focusableElements[0].focus()}releaseFocus(){this.__trapNode=null,Cl.pop()}__onKeyDown(t){this.__trapNode&&this===Array.from(Cl).pop()&&"Tab"===t.key&&(t.preventDefault(),this.__focusNextElement(t.shiftKey))}__focusNextElement(t=!1){const e=this.__focusableElements,i=e[(e.length+this.__focusedElementIndex+(t?-1:1))%e.length];i.focus(),"input"===i.localName&&i.select()}};
|
|
3397
3397
|
/**
|
|
3398
3398
|
* @license
|
|
3399
3399
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
@@ -3423,7 +3423,7 @@ const Cl=[];let Al=class{constructor(t){this.host=t,this.__trapNode=null,this.__
|
|
|
3423
3423
|
* @license
|
|
3424
3424
|
* Copyright (c) 2015 - 2024 Vaadin Ltd.
|
|
3425
3425
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
3426
|
-
*/,Fl=t=>class extends(Pl(Tl(t))){_shouldCloseOnOutsideClick(t){return!t.composedPath().includes(this.positionTarget)}_mouseDownListener(t){super._mouseDownListener(t),this._shouldCloseOnOutsideClick(t)&&!
|
|
3426
|
+
*/,Fl=t=>class extends(Pl(Tl(t))){_shouldCloseOnOutsideClick(t){return!t.composedPath().includes(this.positionTarget)}_mouseDownListener(t){super._mouseDownListener(t),this._shouldCloseOnOutsideClick(t)&&!ga(t.composedPath()[0])&&t.preventDefault()}}
|
|
3427
3427
|
/**
|
|
3428
3428
|
* @license
|
|
3429
3429
|
* Copyright (c) 2016 - 2024 Vaadin Ltd.
|
|
@@ -3625,7 +3625,7 @@ The complete set of contributors may be found at http://polymer.github.io/CONTRI
|
|
|
3625
3625
|
Code distributed by Google as part of the polymer project is also
|
|
3626
3626
|
subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
|
|
3627
3627
|
*/
|
|
3628
|
-
let
|
|
3628
|
+
let gh=!1;
|
|
3629
3629
|
/**
|
|
3630
3630
|
@license
|
|
3631
3631
|
Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
|
|
@@ -3635,7 +3635,7 @@ The complete set of contributors may be found at http://polymer.github.io/CONTRI
|
|
|
3635
3635
|
Code distributed by Google as part of the polymer project is also
|
|
3636
3636
|
subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
|
|
3637
3637
|
*/
|
|
3638
|
-
const
|
|
3638
|
+
const bh=rh(Qr);class yh extends bh{static get is(){return"dom-repeat"}static get template(){return null}static get properties(){return{items:{type:Array},as:{type:String,value:"item"},indexAs:{type:String,value:"index"},itemsIndexAs:{type:String,value:"itemsIndex"},sort:{type:Function,observer:"__sortChanged"},filter:{type:Function,observer:"__filterChanged"},observe:{type:String,observer:"__observeChanged"},delay:Number,renderedItemCount:{type:Number,notify:!io,readOnly:!0},initialCount:{type:Number},targetFramerate:{type:Number,value:20},_targetFrameTime:{type:Number,computed:"__computeFrameTime(targetFramerate)"},notifyDomChange:{type:Boolean},reuseChunkedInstances:{type:Boolean}}}static get observers(){return["__itemsChanged(items.*)"]}constructor(){super(),this.__instances=[],this.__renderDebouncer=null,this.__itemsIdxToInstIdx={},this.__chunkCount=null,this.__renderStartTime=null,this.__itemsArrayChanged=!1,this.__shouldMeasureChunk=!1,this.__shouldContinueChunking=!1,this.__chunkingId=0,this.__sortFn=null,this.__filterFn=null,this.__observePaths=null,this.__ctor=null,this.__isDetached=!0,this.template=null}disconnectedCallback(){super.disconnectedCallback(),this.__isDetached=!0;for(let t=0;t<this.__instances.length;t++)this.__detachInstance(t);this.__chunkingId&&cancelAnimationFrame(this.__chunkingId)}connectedCallback(){if(super.connectedCallback(),function(){if(Ks&&!$s){if(!gh){gh=!0;const t=document.createElement("style");t.textContent="dom-bind,dom-if,dom-repeat{display:none;}",document.head.appendChild(t)}return!0}return!1}()||(this.style.display="none"),this.__isDetached){this.__isDetached=!1;let t=_o(_o(this).parentNode);for(let e=0;e<this.__instances.length;e++)this.__attachInstance(e,t);this.__chunkingId&&this.__render()}}__ensureTemplatized(){if(!this.__ctor){const t=this;let e=this.template=t._templateInfo?t:this.querySelector("template");if(!e){let t=new MutationObserver((()=>{if(!this.querySelector("template"))throw new Error("dom-repeat requires a <template> child");t.disconnect(),this.__render()}));return t.observe(this,{childList:!0}),!1}let i={};i[this.as]=!0,i[this.indexAs]=!0,i[this.itemsIndexAs]=!0,this.__ctor=fh(e,this,{mutableData:this.mutableData,parentModel:!0,instanceProps:i,forwardHostProp:function(t,e){let i=this.__instances;for(let s,o=0;o<i.length&&(s=i[o]);o++)s.forwardHostProp(t,e)},notifyInstanceProp:function(t,e,i){if(function(t,e){return t===e||Co(t,e)||Ao(t,e)}(this.as,e)){let s=t[this.itemsIndexAs];e==this.as&&(this.items[s]=i);let o=So(this.as,`${JSCompiler_renameProperty("items",this)}.${s}`,e);this.notifyPath(o,i)}}})}return!0}__getMethodHost(){return this.__dataHost._methodHost||this.__dataHost}__functionFromPropertyValue(t){if("string"==typeof t){let e=t,i=this.__getMethodHost();return function(){return i[e].apply(i,arguments)}}return t}__sortChanged(t){this.__sortFn=this.__functionFromPropertyValue(t),this.items&&this.__debounceRender(this.__render)}__filterChanged(t){this.__filterFn=this.__functionFromPropertyValue(t),this.items&&this.__debounceRender(this.__render)}__computeFrameTime(t){return Math.ceil(1e3/t)}__observeChanged(){this.__observePaths=this.observe&&this.observe.replace(".*",".").split(" ")}__handleObservedPaths(t){if(this.__sortFn||this.__filterFn)if(t){if(this.__observePaths){let e=this.__observePaths;for(let i=0;i<e.length;i++)0===t.indexOf(e[i])&&this.__debounceRender(this.__render,this.delay)}}else this.__debounceRender(this.__render,this.delay)}__itemsChanged(t){this.items&&!Array.isArray(this.items)&&console.warn("dom-repeat expected array for `items`, found",this.items),this.__handleItemPath(t.path,t.value)||("items"===t.path&&(this.__itemsArrayChanged=!0),this.__debounceRender(this.__render))}__debounceRender(t,e=0){this.__renderDebouncer=Yl.debounce(this.__renderDebouncer,e>0?qo.after(e):$o,t.bind(this)),Ul.add(this.__renderDebouncer)}render(){this.__debounceRender(this.__render),Ql()}__render(){if(!this.__ensureTemplatized())return;let t=this.items||[];const e=this.__sortAndFilterItems(t),i=this.__calculateLimit(e.length);this.__updateInstances(t,i,e),this.initialCount&&(this.__shouldMeasureChunk||this.__shouldContinueChunking)&&(cancelAnimationFrame(this.__chunkingId),this.__chunkingId=requestAnimationFrame((()=>{this.__chunkingId=null,this.__continueChunking()}))),this._setRenderedItemCount(this.__instances.length),(!io||this.notifyDomChange)&&this.dispatchEvent(new CustomEvent("dom-change",{bubbles:!0,composed:!0}))}__sortAndFilterItems(t){let e=new Array(t.length);for(let i=0;i<t.length;i++)e[i]=i;return this.__filterFn&&(e=e.filter(((e,i,s)=>this.__filterFn(t[e],i,s)))),this.__sortFn&&e.sort(((e,i)=>this.__sortFn(t[e],t[i]))),e}__calculateLimit(t){let e=t;const i=this.__instances.length;if(this.initialCount){let s;!this.__chunkCount||this.__itemsArrayChanged&&!this.reuseChunkedInstances?(e=Math.min(t,this.initialCount),s=Math.max(e-i,0),this.__chunkCount=s||1):(s=Math.min(Math.max(t-i,0),this.__chunkCount),e=Math.min(i+s,t)),this.__shouldMeasureChunk=s===this.__chunkCount,this.__shouldContinueChunking=e<t,this.__renderStartTime=performance.now()}return this.__itemsArrayChanged=!1,e}__continueChunking(){if(this.__shouldMeasureChunk){const t=performance.now()-this.__renderStartTime;this.__chunkCount=Math.round(this.__chunkCount*(this._targetFrameTime/t))||1}this.__shouldContinueChunking&&this.__debounceRender(this.__render)}__updateInstances(t,e,i){const s=this.__itemsIdxToInstIdx={};let o;for(o=0;o<e;o++){let e=this.__instances[o],r=i[o],n=t[r];s[r]=o,e?(e._setPendingProperty(this.as,n),e._setPendingProperty(this.indexAs,o),e._setPendingProperty(this.itemsIndexAs,r),e._flushProperties()):this.__insertInstance(n,o,r)}for(let t=this.__instances.length-1;t>=o;t--)this.__detachAndRemoveInstance(t)}__detachInstance(t){let e=this.__instances[t];const i=_o(e.root);for(let t=0;t<e.children.length;t++)i.appendChild(e.children[t]);return e}__attachInstance(t,e){e.insertBefore(this.__instances[t].root,this)}__detachAndRemoveInstance(t){this.__detachInstance(t),this.__instances.splice(t,1)}__stampInstance(t,e,i){let s={};return s[this.as]=t,s[this.indexAs]=e,s[this.itemsIndexAs]=i,new this.__ctor(s)}__insertInstance(t,e,i){const s=this.__stampInstance(t,e,i);let o=this.__instances[e+1],r=o?o.children[0]:this;return _o(_o(this).parentNode).insertBefore(s.root,r),this.__instances[e]=s,s}_showHideChildren(t){for(let e=0;e<this.__instances.length;e++)this.__instances[e]._showHideChildren(t)}__handleItemPath(t,e){let i=t.slice(6),s=i.indexOf("."),o=s<0?i:i.substring(0,s);if(o==parseInt(o,10)){let t=s<0?"":i.substring(s+1);this.__handleObservedPaths(t);let r=this.__instances[this.__itemsIdxToInstIdx[o]];return r&&(r._setPendingPropertyOrPath(this.as+(t?"."+t:""),e,!1,!0),r._flushProperties()),!0}}itemForElement(t){let e=this.modelForElement(t);return e&&e[this.as]}indexForElement(t){let e=this.modelForElement(t);return e&&e[this.indexAs]}modelForElement(t){return function(t,e){let i;for(;e;)if(i=e.__dataHost?e:e.__templatizeInstance){if(i.__dataHost==t)return i;e=i.__dataHost}else e=_o(e).parentNode;return null}(this.template,t)}}customElements.define(yh.is,yh);
|
|
3639
3639
|
/**
|
|
3640
3640
|
* @license
|
|
3641
3641
|
* Copyright (c) 2016 - 2024 Vaadin Ltd.
|
|
@@ -4329,7 +4329,7 @@ const Gh=t=>class extends t{static get properties(){return{index:{type:Number},i
|
|
|
4329
4329
|
* Copyright (c) 2015 - 2024 Vaadin Ltd.
|
|
4330
4330
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4331
4331
|
*/
|
|
4332
|
-
const Uh=t=>class extends(Pl(t)){static get observers(){return["_setOverlayWidth(positionTarget, opened)"]}constructor(){super(),this.requiredVerticalSpace=200}connectedCallback(){super.connectedCallback();const t=this._comboBox,e=t&&t.getAttribute("dir");e&&this.setAttribute("dir",e)}_shouldCloseOnOutsideClick(t){const e=t.composedPath();return!e.includes(this.positionTarget)&&!e.includes(this)}_mouseDownListener(t){super._mouseDownListener(t),this._shouldCloseOnOutsideClick(t)&&!
|
|
4332
|
+
const Uh=t=>class extends(Pl(t)){static get observers(){return["_setOverlayWidth(positionTarget, opened)"]}constructor(){super(),this.requiredVerticalSpace=200}connectedCallback(){super.connectedCallback();const t=this._comboBox,e=t&&t.getAttribute("dir");e&&this.setAttribute("dir",e)}_shouldCloseOnOutsideClick(t){const e=t.composedPath();return!e.includes(this.positionTarget)&&!e.includes(this)}_mouseDownListener(t){super._mouseDownListener(t),this._shouldCloseOnOutsideClick(t)&&!ga(t.composedPath()[0])&&t.preventDefault()}_updateOverlayWidth(){const t=this.localName;this.style.setProperty(`--_${t}-default-width`,`${this.positionTarget.clientWidth}px`);const e=getComputedStyle(this._comboBox).getPropertyValue(`--${t}-width`);""===e?this.style.removeProperty(`--${t}-width`):this.style.setProperty(`--${t}-width`,e)}_setOverlayWidth(t,e){t&&e&&(this._updateOverlayWidth(),this._updatePosition())}}
|
|
4333
4333
|
/**
|
|
4334
4334
|
* @license
|
|
4335
4335
|
* Copyright (c) 2015 - 2024 Vaadin Ltd.
|
|
@@ -4449,12 +4449,12 @@ const ud=t=>class extends t{static get properties(){return{pageSize:{type:Number
|
|
|
4449
4449
|
* @license
|
|
4450
4450
|
* Copyright (c) 2015 - 2024 Vaadin Ltd.
|
|
4451
4451
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4452
|
-
*/function md(t){return null!=t}function vd(t,e){return t.findIndex((t=>!(t instanceof sd)&&e(t)))}const fd=t=>class extends(Oh(Da(La(wa(la(Ca(aa(t)))))))){static get properties(){return{opened:{type:Boolean,notify:!0,value:!1,reflectToAttribute:!0,sync:!0,observer:"_openedChanged"},autoOpenDisabled:{type:Boolean,sync:!0},readonly:{type:Boolean,value:!1,reflectToAttribute:!0},renderer:{type:Object,sync:!0},items:{type:Array,sync:!0,observer:"_itemsChanged"},allowCustomValue:{type:Boolean,value:!1},filteredItems:{type:Array,observer:"_filteredItemsChanged",sync:!0},_lastCommittedValue:String,loading:{type:Boolean,value:!1,reflectToAttribute:!0,sync:!0},_focusedIndex:{type:Number,observer:"_focusedIndexChanged",value:-1,sync:!0},filter:{type:String,value:"",notify:!0,sync:!0},selectedItem:{type:Object,notify:!0,sync:!0},itemClassNameGenerator:{type:Object},itemLabelPath:{type:String,value:"label",observer:"_itemLabelPathChanged",sync:!0},itemValuePath:{type:String,value:"value",sync:!0},itemIdPath:{type:String,sync:!0},_toggleElement:{type:Object,observer:"_toggleElementChanged"},_dropdownItems:{type:Array,sync:!0},_closeOnBlurIsPrevented:Boolean,_scroller:{type:Object,sync:!0},_overlayOpened:{type:Boolean,sync:!0,observer:"_overlayOpenedChanged"},__keepOverlayOpened:{type:Boolean,sync:!0}}}static get observers(){return["_selectedItemChanged(selectedItem, itemValuePath, itemLabelPath)","_openedOrItemsChanged(opened, _dropdownItems, loading, __keepOverlayOpened)","_updateScroller(_scroller, _dropdownItems, opened, loading, selectedItem, itemIdPath, _focusedIndex, renderer, _theme, itemClassNameGenerator)"]}constructor(){super(),this._boundOverlaySelectedItemChanged=this._overlaySelectedItemChanged.bind(this),this._boundOnClearButtonMouseDown=this.__onClearButtonMouseDown.bind(this),this._boundOnClick=this._onClick.bind(this),this._boundOnOverlayTouchAction=this._onOverlayTouchAction.bind(this),this._boundOnTouchend=this._onTouchend.bind(this)}get _tagNamePrefix(){return"vaadin-combo-box"}get _nativeInput(){return this.inputElement}_inputElementChanged(t){super._inputElementChanged(t);const e=this._nativeInput;e&&(e.autocomplete="off",e.autocapitalize="off",e.setAttribute("role","combobox"),e.setAttribute("aria-autocomplete","list"),e.setAttribute("aria-expanded",!!this.opened),e.setAttribute("spellcheck","false"),e.setAttribute("autocorrect","off"),this._revertInputValueToValue(),this.clearElement&&this.clearElement.addEventListener("mousedown",this._boundOnClearButtonMouseDown))}ready(){super.ready(),this._initOverlay(),this._initScroller(),this._lastCommittedValue=this.value,this.addEventListener("click",this._boundOnClick),this.addEventListener("touchend",this._boundOnTouchend);const t=()=>{requestAnimationFrame((()=>{this._overlayElement.bringToFront()}))};this.addEventListener("mousedown",t),this.addEventListener("touchstart",t),pd(this),this.addController(new Ph(this))}disconnectedCallback(){super.disconnectedCallback(),this.close()}requestContentUpdate(){this._scroller&&(this._scroller.requestContentUpdate(),this._getItemElements().forEach((t=>{t.requestContentUpdate()})))}open(){!this.disabled&&!this.readonly&&(this.opened=!0)}close(){this.opened=!1}_propertiesChanged(t,e,i){super._propertiesChanged(t,e,i),void 0!==e.filter&&this._filterChanged(e.filter)}updated(t){super.updated(t),t.has("filter")&&this._filterChanged(this.filter)}_initOverlay(){const t=this.$.overlay;t._comboBox=this,t.addEventListener("touchend",this._boundOnOverlayTouchAction),t.addEventListener("touchmove",this._boundOnOverlayTouchAction),t.addEventListener("mousedown",(t=>t.preventDefault())),t.addEventListener("opened-changed",(t=>{this._overlayOpened=t.detail.value})),this._overlayElement=t}_initScroller(t){const e=document.createElement(`${this._tagNamePrefix}-scroller`);e.owner=t||this,e.getItemLabel=this._getItemLabel.bind(this),e.addEventListener("selection-changed",this._boundOverlaySelectedItemChanged);const i=this._overlayElement;i.renderer=t=>{t.innerHTML||t.appendChild(e)},i.requestContentUpdate(),this._scroller=e}_updateScroller(t,e,i,s,o,r,n,a,l,h){if(t&&(i&&(t.style.maxHeight=getComputedStyle(this).getPropertyValue(`--${this._tagNamePrefix}-overlay-max-height`)||"65vh"),t.setProperties({items:i?e:[],opened:i,loading:s,selectedItem:o,itemIdPath:r,focusedIndex:n,renderer:a,theme:l,itemClassNameGenerator:h}),t.performUpdate&&!t.hasUpdated))try{t.performUpdate()}catch(t){}}_openedOrItemsChanged(t,e,i,s){this._overlayOpened=t&&(s||i||!(!e||!e.length))}_overlayOpenedChanged(t,e){t?(this.dispatchEvent(new CustomEvent("vaadin-combo-box-dropdown-opened",{bubbles:!0,composed:!0})),this._onOpened()):e&&this._dropdownItems&&this._dropdownItems.length&&(this.close(),this.dispatchEvent(new CustomEvent("vaadin-combo-box-dropdown-closed",{bubbles:!0,composed:!0})))}_focusedIndexChanged(t,e){void 0!==e&&this._updateActiveDescendant(t)}_isInputFocused(){return this.inputElement&&ga(this.inputElement)}_updateActiveDescendant(t){const e=this._nativeInput;if(!e)return;const i=this._getItemElements().find((e=>e.index===t));i?e.setAttribute("aria-activedescendant",i.id):e.removeAttribute("aria-activedescendant")}_openedChanged(t,e){if(void 0===e)return;t?!this._isInputFocused()&&!ml&&this.inputElement&&this.inputElement.focus():this._onClosed();const i=this._nativeInput;i&&(i.setAttribute("aria-expanded",!!t),t?i.setAttribute("aria-controls",this._scroller.id):i.removeAttribute("aria-controls"))}_onOverlayTouchAction(){this._closeOnBlurIsPrevented=!0,this.inputElement.blur(),this._closeOnBlurIsPrevented=!1}_isClearButton(t){return t.composedPath()[0]===this.clearElement}__onClearButtonMouseDown(t){t.preventDefault(),this.inputElement.focus()}_onClearButtonClick(t){t.preventDefault(),this._onClearAction(),this.opened&&this.requestContentUpdate()}_onToggleButtonClick(t){t.preventDefault(),this.opened?this.close():this.open()}_onHostClick(t){this.autoOpenDisabled||(t.preventDefault(),this.open())}_onClick(t){this._isClearButton(t)?this._onClearButtonClick(t):t.composedPath().includes(this._toggleElement)?this._onToggleButtonClick(t):this._onHostClick(t)}_onKeyDown(t){super._onKeyDown(t),"ArrowDown"===t.key?(this._onArrowDown(),t.preventDefault()):"ArrowUp"===t.key&&(this._onArrowUp(),t.preventDefault())}_getItemLabel(t){let e=t&&this.itemLabelPath?Qh(this.itemLabelPath,t):void 0;return null==e&&(e=t?t.toString():""),e}_getItemValue(t){let e=t&&this.itemValuePath?Qh(this.itemValuePath,t):void 0;return void 0===e&&(e=t?t.toString():""),e}_onArrowDown(){if(this.opened){const t=this._dropdownItems;t&&(this._focusedIndex=Math.min(t.length-1,this._focusedIndex+1),this._prefillFocusedItemLabel())}else this.open()}_onArrowUp(){if(this.opened){if(this._focusedIndex>-1)this._focusedIndex=Math.max(0,this._focusedIndex-1);else{const t=this._dropdownItems;t&&(this._focusedIndex=t.length-1)}this._prefillFocusedItemLabel()}else this.open()}_prefillFocusedItemLabel(){this._focusedIndex>-1&&(this._inputElementValue=this._getItemLabel(this._dropdownItems[this._focusedIndex]),this._markAllSelectionRange())}_setSelectionRange(t,e){this._isInputFocused()&&this.inputElement.setSelectionRange&&this.inputElement.setSelectionRange(t,e)}_markAllSelectionRange(){void 0!==this._inputElementValue&&this._setSelectionRange(0,this._inputElementValue.length)}_clearSelectionRange(){if(void 0!==this._inputElementValue){const t=this._inputElementValue?this._inputElementValue.length:0;this._setSelectionRange(t,t)}}_closeOrCommit(){this.opened||this.loading?this.close():this._commitValue()}_onEnter(t){if(!this._hasValidInputValue())return t.preventDefault(),void t.stopPropagation();this.opened&&(t.preventDefault(),t.stopPropagation()),this._closeOrCommit()}_hasValidInputValue(){const t=this._focusedIndex<0&&""!==this._inputElementValue&&this._getItemLabel(this.selectedItem)!==this._inputElementValue;return this.allowCustomValue||!t}_onEscape(t){this.autoOpenDisabled&&(this.opened||this.value!==this._inputElementValue&&this._inputElementValue.length>0)?(t.stopPropagation(),this._focusedIndex=-1,this.cancel()):this.opened?(t.stopPropagation(),this._focusedIndex>-1?(this._focusedIndex=-1,this._revertInputValue()):this.cancel()):this.clearButtonVisible&&this.value&&!this.readonly&&(t.stopPropagation(),this._onClearAction())}_toggleElementChanged(t){t&&(t.addEventListener("mousedown",(t=>t.preventDefault())),t.addEventListener("click",(()=>{ml&&!this._isInputFocused()&&document.activeElement.blur()})))}_onClearAction(){this.selectedItem=null,this.allowCustomValue&&(this.value=""),this._detectAndDispatchChange()}_clearFilter(){this.filter=""}cancel(){this._revertInputValueToValue(),this._lastCommittedValue=this.value,this._closeOrCommit()}_onOpened(){this._lastCommittedValue=this.value}_onClosed(){(!this.loading||this.allowCustomValue)&&this._commitValue()}_commitValue(){if(this._focusedIndex>-1){const t=this._dropdownItems[this._focusedIndex];this.selectedItem!==t&&(this.selectedItem=t),this._inputElementValue=this._getItemLabel(this.selectedItem),this._focusedIndex=-1}else if(""===this._inputElementValue||void 0===this._inputElementValue)this.selectedItem=null,this.allowCustomValue&&(this.value="");else{const t=[this.selectedItem,...this._dropdownItems||[]],e=t[this.__getItemIndexByLabel(t,this._inputElementValue)];if(this.allowCustomValue&&!e){const t=this._inputElementValue;this._lastCustomValue=t;const e=new CustomEvent("custom-value-set",{detail:t,composed:!0,cancelable:!0,bubbles:!0});this.dispatchEvent(e),e.defaultPrevented||(this.value=t)}else this.allowCustomValue||this.opened||!e?this._revertInputValueToValue():this.value=this._getItemValue(e)}this._detectAndDispatchChange(),this._clearSelectionRange(),this._clearFilter()}_onInput(t){const e=this._inputElementValue,i={};this.filter===e?this._filterChanged(this.filter):i.filter=e,!this.opened&&!this._isClearButton(t)&&!this.autoOpenDisabled&&(i.opened=!0),this.setProperties(i)}_onChange(t){t.stopPropagation()}_itemLabelPathChanged(t){"string"!=typeof t&&console.error("You should set itemLabelPath to a valid string")}_filterChanged(t){this._scrollIntoView(0),this._focusedIndex=-1,this.items?this.filteredItems=this._filterItems(this.items,t):this._filteredItemsChanged(this.filteredItems)}_revertInputValue(){""!==this.filter?this._inputElementValue=this.filter:this._revertInputValueToValue(),this._clearSelectionRange()}_revertInputValueToValue(){this._inputElementValue=this.allowCustomValue&&!this.selectedItem?this.value:this._getItemLabel(this.selectedItem)}_selectedItemChanged(t){if(null==t)this.filteredItems&&(this.allowCustomValue||(this.value=""),this._toggleHasValue(this._hasValue),this._inputElementValue=this.value);else{const e=this._getItemValue(t);if(this.value!==e&&(this.value=e,this.value!==e))return;this._toggleHasValue(!0),this._inputElementValue=this._getItemLabel(t)}}_valueChanged(t,e){""===t&&void 0===e||(md(t)?(this._getItemValue(this.selectedItem)!==t&&this._selectItemForValue(t),!this.selectedItem&&this.allowCustomValue&&(this._inputElementValue=t),this._toggleHasValue(this._hasValue)):this.selectedItem=null,this._clearFilter(),this._lastCommittedValue=void 0)}_detectAndDispatchChange(){document.hasFocus()&&this.validate(),this.value!==this._lastCommittedValue&&(this.dispatchEvent(new CustomEvent("change",{bubbles:!0})),this._lastCommittedValue=this.value)}_itemsChanged(t,e){this._ensureItemsOrDataProvider((()=>{this.items=e})),t?this.filteredItems=t.slice(0):e&&(this.filteredItems=null)}_filteredItemsChanged(t){this._setDropdownItems(t)}_filterItems(t,e){return t&&t.filter((t=>(e=e?e.toString().toLowerCase():"",this._getItemLabel(t).toString().toLowerCase().indexOf(e)>-1)))}_selectItemForValue(t){const e=this.__getItemIndexByValue(this.filteredItems,t),i=this.selectedItem;this.selectedItem=e>=0?this.filteredItems[e]:this.dataProvider&&void 0===this.selectedItem?void 0:null,null===this.selectedItem&&null===i&&this._selectedItemChanged(this.selectedItem)}_setDropdownItems(t){const e=this._dropdownItems;this._dropdownItems=t;const i=e?e[this._focusedIndex]:null,s=this.__getItemIndexByValue(t,this.value);null==this.selectedItem&&s>=0&&(this.selectedItem=t[s]);const o=this.__getItemIndexByValue(t,this._getItemValue(i));this._focusedIndex=o>-1?o:this.__getItemIndexByLabel(t,this.filter)}_getItemElements(){return Array.from(this._scroller.querySelectorAll(`${this._tagNamePrefix}-item`))}_scrollIntoView(t){this._scroller&&this._scroller.scrollIntoView(t)}__getItemIndexByValue(t,e){return t&&md(e)?vd(t,(t=>this._getItemValue(t)===e)):-1}__getItemIndexByLabel(t,e){return t&&e?vd(t,(t=>this._getItemLabel(t).toString().toLowerCase()===e.toString().toLowerCase())):-1}_overlaySelectedItemChanged(t){t.stopPropagation(),!(t.detail.item instanceof sd)&&this.opened&&(this._focusedIndex=this.filteredItems.indexOf(t.detail.item),this.close())}_setFocused(t){if(super._setFocused(t),!t&&!this.readonly&&!this._closeOnBlurIsPrevented){if(!this.opened&&this.allowCustomValue&&this._inputElementValue===this._lastCustomValue)return void delete this._lastCustomValue;if(ua())return void this._closeOrCommit();this.opened?this._overlayOpened||this.close():this._commitValue()}}_shouldRemoveFocus(t){return!(t.relatedTarget&&t.relatedTarget.localName===`${this._tagNamePrefix}-item`||t.relatedTarget===this._overlayElement&&(t.composedPath()[0].focus(),1))}_onTouchend(t){!this.clearElement||t.composedPath()[0]!==this.clearElement||(t.preventDefault(),this._onClearAction())}}
|
|
4452
|
+
*/function md(t){return null!=t}function vd(t,e){return t.findIndex((t=>!(t instanceof sd)&&e(t)))}const fd=t=>class extends(Oh(Da(La(wa(la(Ca(aa(t)))))))){static get properties(){return{opened:{type:Boolean,notify:!0,value:!1,reflectToAttribute:!0,sync:!0,observer:"_openedChanged"},autoOpenDisabled:{type:Boolean,sync:!0},readonly:{type:Boolean,value:!1,reflectToAttribute:!0},renderer:{type:Object,sync:!0},items:{type:Array,sync:!0,observer:"_itemsChanged"},allowCustomValue:{type:Boolean,value:!1},filteredItems:{type:Array,observer:"_filteredItemsChanged",sync:!0},_lastCommittedValue:String,loading:{type:Boolean,value:!1,reflectToAttribute:!0,sync:!0},_focusedIndex:{type:Number,observer:"_focusedIndexChanged",value:-1,sync:!0},filter:{type:String,value:"",notify:!0,sync:!0},selectedItem:{type:Object,notify:!0,sync:!0},itemClassNameGenerator:{type:Object},itemLabelPath:{type:String,value:"label",observer:"_itemLabelPathChanged",sync:!0},itemValuePath:{type:String,value:"value",sync:!0},itemIdPath:{type:String,sync:!0},_toggleElement:{type:Object,observer:"_toggleElementChanged"},_dropdownItems:{type:Array,sync:!0},_closeOnBlurIsPrevented:Boolean,_scroller:{type:Object,sync:!0},_overlayOpened:{type:Boolean,sync:!0,observer:"_overlayOpenedChanged"},__keepOverlayOpened:{type:Boolean,sync:!0}}}static get observers(){return["_selectedItemChanged(selectedItem, itemValuePath, itemLabelPath)","_openedOrItemsChanged(opened, _dropdownItems, loading, __keepOverlayOpened)","_updateScroller(_scroller, _dropdownItems, opened, loading, selectedItem, itemIdPath, _focusedIndex, renderer, _theme, itemClassNameGenerator)"]}constructor(){super(),this._boundOverlaySelectedItemChanged=this._overlaySelectedItemChanged.bind(this),this._boundOnClearButtonMouseDown=this.__onClearButtonMouseDown.bind(this),this._boundOnClick=this._onClick.bind(this),this._boundOnOverlayTouchAction=this._onOverlayTouchAction.bind(this),this._boundOnTouchend=this._onTouchend.bind(this)}get _tagNamePrefix(){return"vaadin-combo-box"}get _nativeInput(){return this.inputElement}_inputElementChanged(t){super._inputElementChanged(t);const e=this._nativeInput;e&&(e.autocomplete="off",e.autocapitalize="off",e.setAttribute("role","combobox"),e.setAttribute("aria-autocomplete","list"),e.setAttribute("aria-expanded",!!this.opened),e.setAttribute("spellcheck","false"),e.setAttribute("autocorrect","off"),this._revertInputValueToValue(),this.clearElement&&this.clearElement.addEventListener("mousedown",this._boundOnClearButtonMouseDown))}ready(){super.ready(),this._initOverlay(),this._initScroller(),this._lastCommittedValue=this.value,this.addEventListener("click",this._boundOnClick),this.addEventListener("touchend",this._boundOnTouchend);const t=()=>{requestAnimationFrame((()=>{this._overlayElement.bringToFront()}))};this.addEventListener("mousedown",t),this.addEventListener("touchstart",t),pd(this),this.addController(new Ph(this))}disconnectedCallback(){super.disconnectedCallback(),this.close()}requestContentUpdate(){this._scroller&&(this._scroller.requestContentUpdate(),this._getItemElements().forEach((t=>{t.requestContentUpdate()})))}open(){!this.disabled&&!this.readonly&&(this.opened=!0)}close(){this.opened=!1}_propertiesChanged(t,e,i){super._propertiesChanged(t,e,i),void 0!==e.filter&&this._filterChanged(e.filter)}updated(t){super.updated(t),t.has("filter")&&this._filterChanged(this.filter)}_initOverlay(){const t=this.$.overlay;t._comboBox=this,t.addEventListener("touchend",this._boundOnOverlayTouchAction),t.addEventListener("touchmove",this._boundOnOverlayTouchAction),t.addEventListener("mousedown",(t=>t.preventDefault())),t.addEventListener("opened-changed",(t=>{this._overlayOpened=t.detail.value})),this._overlayElement=t}_initScroller(t){const e=document.createElement(`${this._tagNamePrefix}-scroller`);e.owner=t||this,e.getItemLabel=this._getItemLabel.bind(this),e.addEventListener("selection-changed",this._boundOverlaySelectedItemChanged);const i=this._overlayElement;i.renderer=t=>{t.innerHTML||t.appendChild(e)},i.requestContentUpdate(),this._scroller=e}_updateScroller(t,e,i,s,o,r,n,a,l,h){if(t&&(i&&(t.style.maxHeight=getComputedStyle(this).getPropertyValue(`--${this._tagNamePrefix}-overlay-max-height`)||"65vh"),t.setProperties({items:i?e:[],opened:i,loading:s,selectedItem:o,itemIdPath:r,focusedIndex:n,renderer:a,theme:l,itemClassNameGenerator:h}),t.performUpdate&&!t.hasUpdated))try{t.performUpdate()}catch(t){}}_openedOrItemsChanged(t,e,i,s){this._overlayOpened=t&&(s||i||!(!e||!e.length))}_overlayOpenedChanged(t,e){t?(this.dispatchEvent(new CustomEvent("vaadin-combo-box-dropdown-opened",{bubbles:!0,composed:!0})),this._onOpened()):e&&this._dropdownItems&&this._dropdownItems.length&&(this.close(),this.dispatchEvent(new CustomEvent("vaadin-combo-box-dropdown-closed",{bubbles:!0,composed:!0})))}_focusedIndexChanged(t,e){void 0!==e&&this._updateActiveDescendant(t)}_isInputFocused(){return this.inputElement&&ba(this.inputElement)}_updateActiveDescendant(t){const e=this._nativeInput;if(!e)return;const i=this._getItemElements().find((e=>e.index===t));i?e.setAttribute("aria-activedescendant",i.id):e.removeAttribute("aria-activedescendant")}_openedChanged(t,e){if(void 0===e)return;t?!this._isInputFocused()&&!ml&&this.inputElement&&this.inputElement.focus():this._onClosed();const i=this._nativeInput;i&&(i.setAttribute("aria-expanded",!!t),t?i.setAttribute("aria-controls",this._scroller.id):i.removeAttribute("aria-controls"))}_onOverlayTouchAction(){this._closeOnBlurIsPrevented=!0,this.inputElement.blur(),this._closeOnBlurIsPrevented=!1}_isClearButton(t){return t.composedPath()[0]===this.clearElement}__onClearButtonMouseDown(t){t.preventDefault(),this.inputElement.focus()}_onClearButtonClick(t){t.preventDefault(),this._onClearAction(),this.opened&&this.requestContentUpdate()}_onToggleButtonClick(t){t.preventDefault(),this.opened?this.close():this.open()}_onHostClick(t){this.autoOpenDisabled||(t.preventDefault(),this.open())}_onClick(t){this._isClearButton(t)?this._onClearButtonClick(t):t.composedPath().includes(this._toggleElement)?this._onToggleButtonClick(t):this._onHostClick(t)}_onKeyDown(t){super._onKeyDown(t),"ArrowDown"===t.key?(this._onArrowDown(),t.preventDefault()):"ArrowUp"===t.key&&(this._onArrowUp(),t.preventDefault())}_getItemLabel(t){let e=t&&this.itemLabelPath?Qh(this.itemLabelPath,t):void 0;return null==e&&(e=t?t.toString():""),e}_getItemValue(t){let e=t&&this.itemValuePath?Qh(this.itemValuePath,t):void 0;return void 0===e&&(e=t?t.toString():""),e}_onArrowDown(){if(this.opened){const t=this._dropdownItems;t&&(this._focusedIndex=Math.min(t.length-1,this._focusedIndex+1),this._prefillFocusedItemLabel())}else this.open()}_onArrowUp(){if(this.opened){if(this._focusedIndex>-1)this._focusedIndex=Math.max(0,this._focusedIndex-1);else{const t=this._dropdownItems;t&&(this._focusedIndex=t.length-1)}this._prefillFocusedItemLabel()}else this.open()}_prefillFocusedItemLabel(){this._focusedIndex>-1&&(this._inputElementValue=this._getItemLabel(this._dropdownItems[this._focusedIndex]),this._markAllSelectionRange())}_setSelectionRange(t,e){this._isInputFocused()&&this.inputElement.setSelectionRange&&this.inputElement.setSelectionRange(t,e)}_markAllSelectionRange(){void 0!==this._inputElementValue&&this._setSelectionRange(0,this._inputElementValue.length)}_clearSelectionRange(){if(void 0!==this._inputElementValue){const t=this._inputElementValue?this._inputElementValue.length:0;this._setSelectionRange(t,t)}}_closeOrCommit(){this.opened||this.loading?this.close():this._commitValue()}_onEnter(t){if(!this._hasValidInputValue())return t.preventDefault(),void t.stopPropagation();this.opened&&(t.preventDefault(),t.stopPropagation()),this._closeOrCommit()}_hasValidInputValue(){const t=this._focusedIndex<0&&""!==this._inputElementValue&&this._getItemLabel(this.selectedItem)!==this._inputElementValue;return this.allowCustomValue||!t}_onEscape(t){this.autoOpenDisabled&&(this.opened||this.value!==this._inputElementValue&&this._inputElementValue.length>0)?(t.stopPropagation(),this._focusedIndex=-1,this.cancel()):this.opened?(t.stopPropagation(),this._focusedIndex>-1?(this._focusedIndex=-1,this._revertInputValue()):this.cancel()):this.clearButtonVisible&&this.value&&!this.readonly&&(t.stopPropagation(),this._onClearAction())}_toggleElementChanged(t){t&&(t.addEventListener("mousedown",(t=>t.preventDefault())),t.addEventListener("click",(()=>{ml&&!this._isInputFocused()&&document.activeElement.blur()})))}_onClearAction(){this.selectedItem=null,this.allowCustomValue&&(this.value=""),this._detectAndDispatchChange()}_clearFilter(){this.filter=""}cancel(){this._revertInputValueToValue(),this._lastCommittedValue=this.value,this._closeOrCommit()}_onOpened(){this._lastCommittedValue=this.value}_onClosed(){(!this.loading||this.allowCustomValue)&&this._commitValue()}_commitValue(){if(this._focusedIndex>-1){const t=this._dropdownItems[this._focusedIndex];this.selectedItem!==t&&(this.selectedItem=t),this._inputElementValue=this._getItemLabel(this.selectedItem),this._focusedIndex=-1}else if(""===this._inputElementValue||void 0===this._inputElementValue)this.selectedItem=null,this.allowCustomValue&&(this.value="");else{const t=[this.selectedItem,...this._dropdownItems||[]],e=t[this.__getItemIndexByLabel(t,this._inputElementValue)];if(this.allowCustomValue&&!e){const t=this._inputElementValue;this._lastCustomValue=t;const e=new CustomEvent("custom-value-set",{detail:t,composed:!0,cancelable:!0,bubbles:!0});this.dispatchEvent(e),e.defaultPrevented||(this.value=t)}else this.allowCustomValue||this.opened||!e?this._revertInputValueToValue():this.value=this._getItemValue(e)}this._detectAndDispatchChange(),this._clearSelectionRange(),this._clearFilter()}_onInput(t){const e=this._inputElementValue,i={};this.filter===e?this._filterChanged(this.filter):i.filter=e,!this.opened&&!this._isClearButton(t)&&!this.autoOpenDisabled&&(i.opened=!0),this.setProperties(i)}_onChange(t){t.stopPropagation()}_itemLabelPathChanged(t){"string"!=typeof t&&console.error("You should set itemLabelPath to a valid string")}_filterChanged(t){this._scrollIntoView(0),this._focusedIndex=-1,this.items?this.filteredItems=this._filterItems(this.items,t):this._filteredItemsChanged(this.filteredItems)}_revertInputValue(){""!==this.filter?this._inputElementValue=this.filter:this._revertInputValueToValue(),this._clearSelectionRange()}_revertInputValueToValue(){this._inputElementValue=this.allowCustomValue&&!this.selectedItem?this.value:this._getItemLabel(this.selectedItem)}_selectedItemChanged(t){if(null==t)this.filteredItems&&(this.allowCustomValue||(this.value=""),this._toggleHasValue(this._hasValue),this._inputElementValue=this.value);else{const e=this._getItemValue(t);if(this.value!==e&&(this.value=e,this.value!==e))return;this._toggleHasValue(!0),this._inputElementValue=this._getItemLabel(t)}}_valueChanged(t,e){""===t&&void 0===e||(md(t)?(this._getItemValue(this.selectedItem)!==t&&this._selectItemForValue(t),!this.selectedItem&&this.allowCustomValue&&(this._inputElementValue=t),this._toggleHasValue(this._hasValue)):this.selectedItem=null,this._clearFilter(),this._lastCommittedValue=void 0)}_detectAndDispatchChange(){document.hasFocus()&&this.validate(),this.value!==this._lastCommittedValue&&(this.dispatchEvent(new CustomEvent("change",{bubbles:!0})),this._lastCommittedValue=this.value)}_itemsChanged(t,e){this._ensureItemsOrDataProvider((()=>{this.items=e})),t?this.filteredItems=t.slice(0):e&&(this.filteredItems=null)}_filteredItemsChanged(t){this._setDropdownItems(t)}_filterItems(t,e){return t&&t.filter((t=>(e=e?e.toString().toLowerCase():"",this._getItemLabel(t).toString().toLowerCase().indexOf(e)>-1)))}_selectItemForValue(t){const e=this.__getItemIndexByValue(this.filteredItems,t),i=this.selectedItem;this.selectedItem=e>=0?this.filteredItems[e]:this.dataProvider&&void 0===this.selectedItem?void 0:null,null===this.selectedItem&&null===i&&this._selectedItemChanged(this.selectedItem)}_setDropdownItems(t){const e=this._dropdownItems;this._dropdownItems=t;const i=e?e[this._focusedIndex]:null,s=this.__getItemIndexByValue(t,this.value);null==this.selectedItem&&s>=0&&(this.selectedItem=t[s]);const o=this.__getItemIndexByValue(t,this._getItemValue(i));this._focusedIndex=o>-1?o:this.__getItemIndexByLabel(t,this.filter)}_getItemElements(){return Array.from(this._scroller.querySelectorAll(`${this._tagNamePrefix}-item`))}_scrollIntoView(t){this._scroller&&this._scroller.scrollIntoView(t)}__getItemIndexByValue(t,e){return t&&md(e)?vd(t,(t=>this._getItemValue(t)===e)):-1}__getItemIndexByLabel(t,e){return t&&e?vd(t,(t=>this._getItemLabel(t).toString().toLowerCase()===e.toString().toLowerCase())):-1}_overlaySelectedItemChanged(t){t.stopPropagation(),!(t.detail.item instanceof sd)&&this.opened&&(this._focusedIndex=this.filteredItems.indexOf(t.detail.item),this.close())}_setFocused(t){if(super._setFocused(t),!t&&!this.readonly&&!this._closeOnBlurIsPrevented){if(!this.opened&&this.allowCustomValue&&this._inputElementValue===this._lastCustomValue)return void delete this._lastCustomValue;if(ua())return void this._closeOrCommit();this.opened?this._overlayOpened||this.close():this._commitValue()}}_shouldRemoveFocus(t){return!(t.relatedTarget&&t.relatedTarget.localName===`${this._tagNamePrefix}-item`||t.relatedTarget===this._overlayElement&&(t.composedPath()[0].focus(),1))}_onTouchend(t){!this.clearElement||t.composedPath()[0]!==this.clearElement||(t.preventDefault(),this._onClearAction())}}
|
|
4453
4453
|
/**
|
|
4454
4454
|
* @license
|
|
4455
4455
|
* Copyright (c) 2015 - 2024 Vaadin Ltd.
|
|
4456
4456
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4457
|
-
*/;Is("vaadin-combo-box",Dh,{moduleId:"vaadin-combo-box-styles"});class
|
|
4457
|
+
*/;Is("vaadin-combo-box",Dh,{moduleId:"vaadin-combo-box-styles"});class gd extends(ud(fd(nd(Eh(Os(xn(Qr))))))){static get is(){return"vaadin-combo-box"}static get template(){return Ur`
|
|
4458
4458
|
<style>
|
|
4459
4459
|
:host([opened]) {
|
|
4460
4460
|
pointer-events: auto;
|
|
@@ -4499,13 +4499,13 @@ const ud=t=>class extends t{static get properties(){return{pageSize:{type:Number
|
|
|
4499
4499
|
></vaadin-combo-box-overlay>
|
|
4500
4500
|
|
|
4501
4501
|
<slot name="tooltip"></slot>
|
|
4502
|
-
`}static get properties(){return{_positionTarget:{type:Object}}}get clearElement(){return this.$.clearButton}ready(){super.ready(),this.addController(new qa(this,(t=>{this._setInputElement(t),this._setFocusElement(t),this.stateTarget=t,this.ariaTarget=t}))),this.addController(new $a(this.inputElement,this._labelController)),this._tooltipController=new Mn(this),this.addController(this._tooltipController),this._tooltipController.setPosition("top"),this._tooltipController.setAriaTarget(this.inputElement),this._tooltipController.setShouldShow((t=>!t.opened)),this._positionTarget=this.shadowRoot.querySelector('[part="input-field"]'),this._toggleElement=this.$.toggleButton}_onClearButtonClick(t){t.stopPropagation(),super._onClearButtonClick(t)}_onHostClick(t){const e=t.composedPath();(e.includes(this._labelNode)||e.includes(this._positionTarget))&&super._onHostClick(t)}}var
|
|
4502
|
+
`}static get properties(){return{_positionTarget:{type:Object}}}get clearElement(){return this.$.clearButton}ready(){super.ready(),this.addController(new qa(this,(t=>{this._setInputElement(t),this._setFocusElement(t),this.stateTarget=t,this.ariaTarget=t}))),this.addController(new $a(this.inputElement,this._labelController)),this._tooltipController=new Mn(this),this.addController(this._tooltipController),this._tooltipController.setPosition("top"),this._tooltipController.setAriaTarget(this.inputElement),this._tooltipController.setShouldShow((t=>!t.opened)),this._positionTarget=this.shadowRoot.querySelector('[part="input-field"]'),this._toggleElement=this.$.toggleButton}_onClearButtonClick(t){t.stopPropagation(),super._onClearButtonClick(t)}_onHostClick(t){const e=t.composedPath();(e.includes(this._labelNode)||e.includes(this._positionTarget))&&super._onHostClick(t)}}var bd;li(gd),
|
|
4503
4503
|
/**
|
|
4504
4504
|
* @license
|
|
4505
4505
|
* Copyright (c) 2021 - 2025 Vaadin Ltd.
|
|
4506
4506
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
4507
4507
|
*/
|
|
4508
|
-
window.Vaadin||(window.Vaadin={}),(
|
|
4508
|
+
window.Vaadin||(window.Vaadin={}),(bd=window.Vaadin).featureFlags||(bd.featureFlags={});const yd={};function wd(t,e="24.8.0"){if(Object.defineProperty(t,"version",{get:()=>e}),t.experimental){const e="string"==typeof t.experimental?t.experimental:`${function(t){return t.replace(/-[a-z]/gu,(t=>t[1].toUpperCase()))}(t.is.split("-").slice(1).join("-"))}Component`;if(!window.Vaadin.featureFlags[e]&&!yd[e])return yd[e]=new Set,yd[e].add(t),void Object.defineProperty(window.Vaadin.featureFlags,e,{get:()=>0===yd[e].size,set(t){t&&yd[e].size>0&&(yd[e].forEach((t=>{customElements.define(t.is,t)})),yd[e].clear())}});if(yd[e])return void yd[e].add(t)}const i=customElements.get(t.is);if(i){const e=i.version;e&&t.version&&e===t.version?console.warn(`The component ${t.is} has been loaded twice`):console.error(`Tried to define ${t.is} version ${t.version} when version ${i.version} is already in use. Something will probably break.`)}else customElements.define(t.is,t)}
|
|
4509
4509
|
/**
|
|
4510
4510
|
* @license
|
|
4511
4511
|
* Copyright (c) 2017 - 2025 Vaadin Ltd.
|
|
@@ -6300,7 +6300,7 @@ const nc=t=>class extends t{static get properties(){return{index:{type:Number},i
|
|
|
6300
6300
|
* Copyright (c) 2021 - 2025 Vaadin Ltd.
|
|
6301
6301
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
6302
6302
|
*/
|
|
6303
|
-
let lc=!1;function hc(){let t=document.activeElement||document.body;for(;t.shadowRoot&&t.shadowRoot.activeElement;)t=t.shadowRoot.activeElement;return t}function dc(){return lc}function cc(t,e){const i=Math.max(t.tabIndex,0),s=Math.max(e.tabIndex,0);return 0===i||0===s?s>i:i>s}function uc(t){const e=t.length;if(e<2)return t;const i=Math.ceil(e/2);return function(t,e){const i=[];for(;t.length>0&&e.length>0;)cc(t[0],e[0])?i.push(e.shift()):i.push(t.shift());return i.concat(t,e)}(uc(t.slice(0,i)),uc(t.slice(i)))}function pc(t){return!t.matches('[tabindex="-1"]')&&(t.matches("input, select, textarea, button, object")?t.matches(":not([disabled])"):t.matches("a[href], area[href], iframe, [tabindex], [contentEditable]"))}function mc(t){return t.getRootNode().activeElement===t}function vc(t,e){if(t.nodeType!==Node.ELEMENT_NODE||function(t){const e=t.style;if("hidden"===e.visibility||"none"===e.display)return!0;const i=window.getComputedStyle(t);return"hidden"===i.visibility||"none"===i.display}(t))return!1;const i=t,s=function(t){if(!pc(t))return-1;const e=t.getAttribute("tabindex")||0;return Number(e)}(i);let o=s>0;s>=0&&e.push(i);let r=[];return r="slot"===i.localName?i.assignedNodes({flatten:!0}):(i.shadowRoot||i).children,[...r].forEach((t=>{o=vc(t,e)||o})),o}function fc(t){return t?new Set(t.split(" ")):new Set}function
|
|
6303
|
+
let lc=!1;function hc(){let t=document.activeElement||document.body;for(;t.shadowRoot&&t.shadowRoot.activeElement;)t=t.shadowRoot.activeElement;return t}function dc(){return lc}function cc(t,e){const i=Math.max(t.tabIndex,0),s=Math.max(e.tabIndex,0);return 0===i||0===s?s>i:i>s}function uc(t){const e=t.length;if(e<2)return t;const i=Math.ceil(e/2);return function(t,e){const i=[];for(;t.length>0&&e.length>0;)cc(t[0],e[0])?i.push(e.shift()):i.push(t.shift());return i.concat(t,e)}(uc(t.slice(0,i)),uc(t.slice(i)))}function pc(t){return!t.matches('[tabindex="-1"]')&&(t.matches("input, select, textarea, button, object")?t.matches(":not([disabled])"):t.matches("a[href], area[href], iframe, [tabindex], [contentEditable]"))}function mc(t){return t.getRootNode().activeElement===t}function vc(t,e){if(t.nodeType!==Node.ELEMENT_NODE||function(t){const e=t.style;if("hidden"===e.visibility||"none"===e.display)return!0;const i=window.getComputedStyle(t);return"hidden"===i.visibility||"none"===i.display}(t))return!1;const i=t,s=function(t){if(!pc(t))return-1;const e=t.getAttribute("tabindex")||0;return Number(e)}(i);let o=s>0;s>=0&&e.push(i);let r=[];return r="slot"===i.localName?i.assignedNodes({flatten:!0}):(i.shadowRoot||i).children,[...r].forEach((t=>{o=vc(t,e)||o})),o}function fc(t){return t?new Set(t.split(" ")):new Set}function gc(t){return t?[...t].join(" "):""}function bc(t,e,i){const s=fc(t.getAttribute(e));s.add(i),t.setAttribute(e,gc(s))}window.addEventListener("keydown",(()=>{lc=!0}),{capture:!0}),window.addEventListener("mousedown",(()=>{lc=!1}),{capture:!0});
|
|
6304
6304
|
/**
|
|
6305
6305
|
* @license
|
|
6306
6306
|
* Copyright (c) 2017 - 2025 Vaadin Ltd.
|
|
@@ -6499,12 +6499,12 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
|
|
6499
6499
|
* The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
|
|
6500
6500
|
* Code distributed by Google as part of the polymer project is also
|
|
6501
6501
|
* subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
|
|
6502
|
-
*/class bu{constructor({createElements:t,updateElement:e,scrollTarget:i,scrollContainer:s,elementsContainer:o,reorderElements:r}){this.isAttached=!0,this._vidxOffset=0,this.createElements=t,this.updateElement=e,this.scrollTarget=i,this.scrollContainer=s,this.elementsContainer=o||s,this.reorderElements=r,this._maxPages=1.3,this.__placeholderHeight=200,this.__elementHeightQueue=Array(10),this.timeouts={SCROLL_REORDER:500,IGNORE_WHEEL:500,FIX_INVALID_ITEM_POSITIONING:100},this.__resizeObserver=new ResizeObserver((()=>this._resizeHandler())),"visible"===getComputedStyle(this.scrollTarget).overflow&&(this.scrollTarget.style.overflow="auto"),"static"===getComputedStyle(this.scrollContainer).position&&(this.scrollContainer.style.position="relative"),this.__resizeObserver.observe(this.scrollTarget),this.scrollTarget.addEventListener("scroll",(()=>this._scrollHandler())),new ResizeObserver((([{contentRect:t}])=>{const e=0===t.width&&0===t.height;!e&&this.__scrollTargetHidden&&this.scrollTarget.scrollTop!==this._scrollPosition&&(this.scrollTarget.scrollTop=this._scrollPosition),this.__scrollTargetHidden=e})).observe(this.scrollTarget),this._scrollLineHeight=this._getScrollLineHeight(),this.scrollTarget.addEventListener("wheel",(t=>this.__onWheel(t))),this.scrollTarget.addEventListener("virtualizer-element-focused",(t=>this.__onElementFocused(t))),this.elementsContainer.addEventListener("focusin",(()=>{this.scrollTarget.dispatchEvent(new CustomEvent("virtualizer-element-focused",{detail:{element:this.__getFocusedElement()}}))})),this.reorderElements&&(this.scrollTarget.addEventListener("mousedown",(()=>{this.__mouseDown=!0})),this.scrollTarget.addEventListener("mouseup",(()=>{this.__mouseDown=!1,this.__pendingReorder&&this.__reorderElements()})))}get scrollOffset(){return 0}get adjustedFirstVisibleIndex(){return this.firstVisibleIndex+this._vidxOffset}get adjustedLastVisibleIndex(){return this.lastVisibleIndex+this._vidxOffset}get _maxVirtualIndexOffset(){return this.size-this._virtualCount}__hasPlaceholders(){return this.__getVisibleElements().some((t=>t.__virtualizerPlaceholder))}scrollToIndex(t){if("number"!=typeof t||isNaN(t)||0===this.size||!this.scrollTarget.offsetHeight)return;delete this.__pendingScrollToIndex,this._physicalCount<=3&&this.flush(),t=this._clamp(t,0,this.size-1);const e=this.__getVisibleElements().length;let i=Math.floor(t/this.size*this._virtualCount);this._virtualCount-i<e?(i=this._virtualCount-(this.size-t),this._vidxOffset=this._maxVirtualIndexOffset):i<e?t<fu?(i=t,this._vidxOffset=0):(i=fu,this._vidxOffset=t-i):this._vidxOffset=t-i,this.__skipNextVirtualIndexAdjust=!0,super.scrollToIndex(i),this.adjustedFirstVisibleIndex!==t&&this._scrollTop<this._maxScrollTop&&!this.grid&&(this._scrollTop-=this.__getIndexScrollOffset(t)||0),this._scrollHandler(),this.__hasPlaceholders()&&(this.__pendingScrollToIndex=t)}flush(){0!==this.scrollTarget.offsetHeight&&(this._resizeHandler(),uu(),this._scrollHandler(),this.__fixInvalidItemPositioningDebouncer&&this.__fixInvalidItemPositioningDebouncer.flush(),this.__scrollReorderDebouncer&&this.__scrollReorderDebouncer.flush(),this.__debouncerWheelAnimationFrame&&this.__debouncerWheelAnimationFrame.flush())}hostConnected(){this.scrollTarget.offsetParent&&this.scrollTarget.scrollTop!==this._scrollPosition&&(this.scrollTarget.scrollTop=this._scrollPosition)}update(t=0,e=this.size-1){const i=[];this.__getVisibleElements().forEach((s=>{s.__virtualIndex>=t&&s.__virtualIndex<=e&&(this.__updateElement(s,s.__virtualIndex,!0),i.push(s))})),this.__afterElementsUpdated(i)}_updateMetrics(t){uu();let e=0,i=0;const s=this._physicalAverageCount,o=this._physicalAverage;this._iterateItems((t=>{i+=this._physicalSizes[t],this._physicalSizes[t]=Math.ceil(this.__getBorderBoxHeight(this._physicalItems[t])),e+=this._physicalSizes[t],this._physicalAverageCount+=this._physicalSizes[t]?1:0}),t),this._physicalSize=this._physicalSize+e-i,this._physicalAverageCount!==s&&(this._physicalAverage=Math.round((o*s+e)/this._physicalAverageCount))}__getBorderBoxHeight(t){const e=getComputedStyle(t),i=parseFloat(e.height)||0;return"border-box"===e.boxSizing?i:i+(parseFloat(e.paddingBottom)||0)+(parseFloat(e.paddingTop)||0)+(parseFloat(e.borderBottomWidth)||0)+(parseFloat(e.borderTopWidth)||0)}__updateElement(t,e,i){t.__virtualizerPlaceholder&&(t.style.paddingTop="",t.style.opacity="",t.__virtualizerPlaceholder=!1),!this.__preventElementUpdates&&(t.__lastUpdatedIndex!==e||i)&&(this.updateElement(t,e),t.__lastUpdatedIndex=e)}__afterElementsUpdated(t){t.forEach((t=>{const e=t.offsetHeight;if(0===e)t.style.paddingTop=`${this.__placeholderHeight}px`,t.style.opacity="0",t.__virtualizerPlaceholder=!0,this.__placeholderClearDebouncer=hu.debounce(this.__placeholderClearDebouncer,ru,(()=>this._resizeHandler()));else{this.__elementHeightQueue.push(e),this.__elementHeightQueue.shift();const t=this.__elementHeightQueue.filter((t=>void 0!==t));this.__placeholderHeight=Math.round(t.reduce(((t,e)=>t+e),0)/t.length)}})),void 0!==this.__pendingScrollToIndex&&!this.__hasPlaceholders()&&this.scrollToIndex(this.__pendingScrollToIndex)}__getIndexScrollOffset(t){const e=this.__getVisibleElements().find((e=>e.__virtualIndex===t));return e?this.scrollTarget.getBoundingClientRect().top-e.getBoundingClientRect().top:void 0}get size(){return this.__size}set size(t){if(t===this.size)return;let e,i;if(this.__fixInvalidItemPositioningDebouncer&&this.__fixInvalidItemPositioningDebouncer.cancel(),this._debouncers&&this._debouncers._increasePoolIfNeeded&&this._debouncers._increasePoolIfNeeded.cancel(),this.__preventElementUpdates=!0,t>0&&(e=this.adjustedFirstVisibleIndex,i=this.__getIndexScrollOffset(e)),this.__size=t,this._itemsChanged({path:"items"}),uu(),t>0){e=Math.min(e,t-1),this.scrollToIndex(e);const s=this.__getIndexScrollOffset(e);void 0!==i&&void 0!==s&&(this._scrollTop+=i-s)}this.__preventElementUpdates=!1,this._isVisible||this._assignModels(),this.elementsContainer.children.length||requestAnimationFrame((()=>this._resizeHandler())),this._resizeHandler(),uu(),this._debounce("_update",this._update,au)}get _scrollTop(){return this.scrollTarget.scrollTop}set _scrollTop(t){this.scrollTarget.scrollTop=t}get items(){return{length:Math.min(this.size,1e5)}}get offsetHeight(){return this.scrollTarget.offsetHeight}get $(){return{items:this.scrollContainer}}updateViewportBoundaries(){const t=window.getComputedStyle(this.scrollTarget);this._scrollerPaddingTop=this.scrollTarget===this?0:parseInt(t["padding-top"],10),this._isRTL="rtl"===t.direction,this._viewportWidth=this.elementsContainer.offsetWidth,this._viewportHeight=this.scrollTarget.offsetHeight,this._scrollPageHeight=this._viewportHeight-this._scrollLineHeight,this.grid&&this._updateGridMetrics()}setAttribute(){}_createPool(t){const e=this.createElements(t),i=document.createDocumentFragment();return e.forEach((t=>{t.style.position="absolute",i.appendChild(t),this.__resizeObserver.observe(t)})),this.elementsContainer.appendChild(i),e}_assignModels(t){const e=[];this._iterateItems(((t,i)=>{const s=this._physicalItems[t];s.hidden=i>=this.size,s.hidden?delete s.__lastUpdatedIndex:(s.__virtualIndex=i+(this._vidxOffset||0),this.__updateElement(s,s.__virtualIndex),e.push(s))}),t),this.__afterElementsUpdated(e)}_isClientFull(){return setTimeout((()=>{this.__clientFull=!0})),this.__clientFull||super._isClientFull()}translate3d(t,e,i,s){s.style.transform=`translateY(${e})`}toggleScrollListener(){}__getFocusedElement(t=this.__getVisibleElements()){return t.find((t=>t.contains(this.elementsContainer.getRootNode().activeElement)||t.contains(this.scrollTarget.getRootNode().activeElement)))}__nextFocusableSiblingMissing(t,e){return e.indexOf(t)===e.length-1&&this.size>t.__virtualIndex+1}__previousFocusableSiblingMissing(t,e){return 0===e.indexOf(t)&&t.__virtualIndex>0}__onElementFocused(t){if(!this.reorderElements)return;const e=t.detail.element;if(!e)return;const i=this.__getVisibleElements();(this.__previousFocusableSiblingMissing(e,i)||this.__nextFocusableSiblingMissing(e,i))&&this.flush();const s=this.__getVisibleElements();this.__nextFocusableSiblingMissing(e,s)?(this._scrollTop+=Math.ceil(e.getBoundingClientRect().bottom)-Math.floor(this.scrollTarget.getBoundingClientRect().bottom-1),this.flush()):this.__previousFocusableSiblingMissing(e,s)&&(this._scrollTop-=Math.ceil(this.scrollTarget.getBoundingClientRect().top+1)-Math.floor(e.getBoundingClientRect().top),this.flush())}_scrollHandler(){if(0===this.scrollTarget.offsetHeight)return;this._adjustVirtualIndexOffset(this._scrollTop-(this.__previousScrollTop||0));const t=this.scrollTarget.scrollTop-this._scrollPosition;if(super._scrollHandler(),0!==this._physicalCount){const e=t>=0,i=this._getReusables(!e);i.indexes.length&&(this._physicalTop=i.physicalTop,e?(this._virtualStart-=i.indexes.length,this._physicalStart-=i.indexes.length):(this._virtualStart+=i.indexes.length,this._physicalStart+=i.indexes.length),this._resizeHandler())}t&&(this.__fixInvalidItemPositioningDebouncer=hu.debounce(this.__fixInvalidItemPositioningDebouncer,ou.after(this.timeouts.FIX_INVALID_ITEM_POSITIONING),(()=>this.__fixInvalidItemPositioning()))),this.reorderElements&&(this.__scrollReorderDebouncer=hu.debounce(this.__scrollReorderDebouncer,ou.after(this.timeouts.SCROLL_REORDER),(()=>this.__reorderElements()))),this.__previousScrollTop=this._scrollTop,0===this._scrollTop&&0!==this.firstVisibleIndex&&Math.abs(t)>0&&this.scrollToIndex(0)}__fixInvalidItemPositioning(){if(!this.scrollTarget.isConnected)return;const t=this._physicalBottom<this._scrollBottom;if(this._physicalTop>this._scrollTop&&0!==this.adjustedFirstVisibleIndex||t&&this.adjustedLastVisibleIndex!==this.size-1){const e=t,i=this._ratio;this._ratio=0,this._scrollPosition=this._scrollTop+(e?-1:1),this._scrollHandler(),this._ratio=i}}__onWheel(t){if(t.ctrlKey||this._hasScrolledAncestor(t.target,t.deltaX,t.deltaY))return;let e=t.deltaY;if(t.deltaMode===WheelEvent.DOM_DELTA_LINE?e*=this._scrollLineHeight:t.deltaMode===WheelEvent.DOM_DELTA_PAGE&&(e*=this._scrollPageHeight),this._deltaYAcc||(this._deltaYAcc=0),this._wheelAnimationFrame)return this._deltaYAcc+=e,void t.preventDefault();e+=this._deltaYAcc,this._deltaYAcc=0,this._wheelAnimationFrame=!0,this.__debouncerWheelAnimationFrame=hu.debounce(this.__debouncerWheelAnimationFrame,ru,(()=>{this._wheelAnimationFrame=!1}));const i=Math.abs(t.deltaX)+Math.abs(e);this._canScroll(this.scrollTarget,t.deltaX,e)?(t.preventDefault(),this.scrollTarget.scrollTop+=e,this.scrollTarget.scrollLeft+=t.deltaX,this._hasResidualMomentum=!0,this._ignoreNewWheel=!0,this._debouncerIgnoreNewWheel=hu.debounce(this._debouncerIgnoreNewWheel,ou.after(this.timeouts.IGNORE_WHEEL),(()=>{this._ignoreNewWheel=!1}))):this._hasResidualMomentum&&i<=this._previousMomentum||this._ignoreNewWheel?t.preventDefault():i>this._previousMomentum&&(this._hasResidualMomentum=!1),this._previousMomentum=i}_hasScrolledAncestor(t,e,i){return t!==this.scrollTarget&&t!==this.scrollTarget.getRootNode().host&&(!(!this._canScroll(t,e,i)||-1===["auto","scroll"].indexOf(getComputedStyle(t).overflow))||(t!==this&&t.parentElement?this._hasScrolledAncestor(t.parentElement,e,i):void 0))}_canScroll(t,e,i){return i>0&&t.scrollTop<t.scrollHeight-t.offsetHeight||i<0&&t.scrollTop>0||e>0&&t.scrollLeft<t.scrollWidth-t.offsetWidth||e<0&&t.scrollLeft>0}_increasePoolIfNeeded(t){if(this._physicalCount>2&&t){const e=Math.ceil(this._optPhysicalSize/this._physicalAverage)-this._physicalCount;super._increasePoolIfNeeded(Math.max(t,Math.min(100,e)))}else super._increasePoolIfNeeded(t)}get _optPhysicalSize(){const t=super._optPhysicalSize;return t<=0||this.__hasPlaceholders()?t:t+this.__getItemHeightBuffer()}__getItemHeightBuffer(){if(0===this._physicalCount)return 0;const t=Math.ceil(this._viewportHeight*(this._maxPages-1)/2),e=Math.max(...this._physicalSizes);return e>Math.min(...this._physicalSizes)?Math.max(0,e-t):0}_getScrollLineHeight(){const t=document.createElement("div");t.style.fontSize="initial",t.style.display="none",document.body.appendChild(t);const e=window.getComputedStyle(t).fontSize;return document.body.removeChild(t),e?window.parseInt(e):void 0}__getVisibleElements(){return Array.from(this.elementsContainer.children).filter((t=>!t.hidden))}__reorderElements(){if(this.__mouseDown)return void(this.__pendingReorder=!0);this.__pendingReorder=!1;const t=this._virtualStart+(this._vidxOffset||0),e=this.__getVisibleElements(),i=this.__getFocusedElement(e)||e[0];if(!i)return;const s=i.__virtualIndex-t,o=e.indexOf(i)-s;if(o>0)for(let t=0;t<o;t++)this.elementsContainer.appendChild(e[t]);else if(o<0)for(let t=e.length+o;t<e.length;t++)this.elementsContainer.insertBefore(e[t],e[0]);if(Ic){const{transform:t}=this.scrollTarget.style;this.scrollTarget.style.transform="translateZ(0)",setTimeout((()=>{this.scrollTarget.style.transform=t}))}}_adjustVirtualIndexOffset(t){const e=this._maxVirtualIndexOffset;if(this._virtualCount>=this.size)this._vidxOffset=0;else if(this.__skipNextVirtualIndexAdjust)this.__skipNextVirtualIndexAdjust=!1;else if(Math.abs(t)>1e4)this._vidxOffset=Math.round(this._scrollTop/(this.scrollTarget.scrollHeight-this.scrollTarget.clientHeight)*e);else{const t=this._vidxOffset,i=fu,s=100;0===this._scrollTop?(this._vidxOffset=0,t!==this._vidxOffset&&super.scrollToIndex(0)):this.firstVisibleIndex<i&&this._vidxOffset>0&&(this._vidxOffset-=Math.min(this._vidxOffset,s),super.scrollToIndex(this.firstVisibleIndex+(t-this._vidxOffset))),this._scrollTop>=this._maxScrollTop&&this._maxScrollTop>0?(this._vidxOffset=e,t!==this._vidxOffset&&super.scrollToIndex(this._virtualCount-1)):this.firstVisibleIndex>this._virtualCount-i&&this._vidxOffset<e&&(this._vidxOffset+=Math.min(e-this._vidxOffset,s),super.scrollToIndex(this.firstVisibleIndex-(this._vidxOffset-t)))}}}Object.setPrototypeOf(bu.prototype,vu);class gu{constructor(t){this.__adapter=new bu(t)}get firstVisibleIndex(){return this.__adapter.adjustedFirstVisibleIndex}get lastVisibleIndex(){return this.__adapter.adjustedLastVisibleIndex}get size(){return this.__adapter.size}set size(t){this.__adapter.size=t}scrollToIndex(t){this.__adapter.scrollToIndex(t)}update(t=0,e=this.size-1){this.__adapter.update(t,e)}flush(){this.__adapter.flush()}hostConnected(){this.__adapter.hostConnected()}}
|
|
6502
|
+
*/class gu{constructor({createElements:t,updateElement:e,scrollTarget:i,scrollContainer:s,elementsContainer:o,reorderElements:r}){this.isAttached=!0,this._vidxOffset=0,this.createElements=t,this.updateElement=e,this.scrollTarget=i,this.scrollContainer=s,this.elementsContainer=o||s,this.reorderElements=r,this._maxPages=1.3,this.__placeholderHeight=200,this.__elementHeightQueue=Array(10),this.timeouts={SCROLL_REORDER:500,IGNORE_WHEEL:500,FIX_INVALID_ITEM_POSITIONING:100},this.__resizeObserver=new ResizeObserver((()=>this._resizeHandler())),"visible"===getComputedStyle(this.scrollTarget).overflow&&(this.scrollTarget.style.overflow="auto"),"static"===getComputedStyle(this.scrollContainer).position&&(this.scrollContainer.style.position="relative"),this.__resizeObserver.observe(this.scrollTarget),this.scrollTarget.addEventListener("scroll",(()=>this._scrollHandler())),new ResizeObserver((([{contentRect:t}])=>{const e=0===t.width&&0===t.height;!e&&this.__scrollTargetHidden&&this.scrollTarget.scrollTop!==this._scrollPosition&&(this.scrollTarget.scrollTop=this._scrollPosition),this.__scrollTargetHidden=e})).observe(this.scrollTarget),this._scrollLineHeight=this._getScrollLineHeight(),this.scrollTarget.addEventListener("wheel",(t=>this.__onWheel(t))),this.scrollTarget.addEventListener("virtualizer-element-focused",(t=>this.__onElementFocused(t))),this.elementsContainer.addEventListener("focusin",(()=>{this.scrollTarget.dispatchEvent(new CustomEvent("virtualizer-element-focused",{detail:{element:this.__getFocusedElement()}}))})),this.reorderElements&&(this.scrollTarget.addEventListener("mousedown",(()=>{this.__mouseDown=!0})),this.scrollTarget.addEventListener("mouseup",(()=>{this.__mouseDown=!1,this.__pendingReorder&&this.__reorderElements()})))}get scrollOffset(){return 0}get adjustedFirstVisibleIndex(){return this.firstVisibleIndex+this._vidxOffset}get adjustedLastVisibleIndex(){return this.lastVisibleIndex+this._vidxOffset}get _maxVirtualIndexOffset(){return this.size-this._virtualCount}__hasPlaceholders(){return this.__getVisibleElements().some((t=>t.__virtualizerPlaceholder))}scrollToIndex(t){if("number"!=typeof t||isNaN(t)||0===this.size||!this.scrollTarget.offsetHeight)return;delete this.__pendingScrollToIndex,this._physicalCount<=3&&this.flush(),t=this._clamp(t,0,this.size-1);const e=this.__getVisibleElements().length;let i=Math.floor(t/this.size*this._virtualCount);this._virtualCount-i<e?(i=this._virtualCount-(this.size-t),this._vidxOffset=this._maxVirtualIndexOffset):i<e?t<fu?(i=t,this._vidxOffset=0):(i=fu,this._vidxOffset=t-i):this._vidxOffset=t-i,this.__skipNextVirtualIndexAdjust=!0,super.scrollToIndex(i),this.adjustedFirstVisibleIndex!==t&&this._scrollTop<this._maxScrollTop&&!this.grid&&(this._scrollTop-=this.__getIndexScrollOffset(t)||0),this._scrollHandler(),this.__hasPlaceholders()&&(this.__pendingScrollToIndex=t)}flush(){0!==this.scrollTarget.offsetHeight&&(this._resizeHandler(),uu(),this._scrollHandler(),this.__fixInvalidItemPositioningDebouncer&&this.__fixInvalidItemPositioningDebouncer.flush(),this.__scrollReorderDebouncer&&this.__scrollReorderDebouncer.flush(),this.__debouncerWheelAnimationFrame&&this.__debouncerWheelAnimationFrame.flush())}hostConnected(){this.scrollTarget.offsetParent&&this.scrollTarget.scrollTop!==this._scrollPosition&&(this.scrollTarget.scrollTop=this._scrollPosition)}update(t=0,e=this.size-1){const i=[];this.__getVisibleElements().forEach((s=>{s.__virtualIndex>=t&&s.__virtualIndex<=e&&(this.__updateElement(s,s.__virtualIndex,!0),i.push(s))})),this.__afterElementsUpdated(i)}_updateMetrics(t){uu();let e=0,i=0;const s=this._physicalAverageCount,o=this._physicalAverage;this._iterateItems((t=>{i+=this._physicalSizes[t],this._physicalSizes[t]=Math.ceil(this.__getBorderBoxHeight(this._physicalItems[t])),e+=this._physicalSizes[t],this._physicalAverageCount+=this._physicalSizes[t]?1:0}),t),this._physicalSize=this._physicalSize+e-i,this._physicalAverageCount!==s&&(this._physicalAverage=Math.round((o*s+e)/this._physicalAverageCount))}__getBorderBoxHeight(t){const e=getComputedStyle(t),i=parseFloat(e.height)||0;return"border-box"===e.boxSizing?i:i+(parseFloat(e.paddingBottom)||0)+(parseFloat(e.paddingTop)||0)+(parseFloat(e.borderBottomWidth)||0)+(parseFloat(e.borderTopWidth)||0)}__updateElement(t,e,i){t.__virtualizerPlaceholder&&(t.style.paddingTop="",t.style.opacity="",t.__virtualizerPlaceholder=!1),!this.__preventElementUpdates&&(t.__lastUpdatedIndex!==e||i)&&(this.updateElement(t,e),t.__lastUpdatedIndex=e)}__afterElementsUpdated(t){t.forEach((t=>{const e=t.offsetHeight;if(0===e)t.style.paddingTop=`${this.__placeholderHeight}px`,t.style.opacity="0",t.__virtualizerPlaceholder=!0,this.__placeholderClearDebouncer=hu.debounce(this.__placeholderClearDebouncer,ru,(()=>this._resizeHandler()));else{this.__elementHeightQueue.push(e),this.__elementHeightQueue.shift();const t=this.__elementHeightQueue.filter((t=>void 0!==t));this.__placeholderHeight=Math.round(t.reduce(((t,e)=>t+e),0)/t.length)}})),void 0!==this.__pendingScrollToIndex&&!this.__hasPlaceholders()&&this.scrollToIndex(this.__pendingScrollToIndex)}__getIndexScrollOffset(t){const e=this.__getVisibleElements().find((e=>e.__virtualIndex===t));return e?this.scrollTarget.getBoundingClientRect().top-e.getBoundingClientRect().top:void 0}get size(){return this.__size}set size(t){if(t===this.size)return;let e,i;if(this.__fixInvalidItemPositioningDebouncer&&this.__fixInvalidItemPositioningDebouncer.cancel(),this._debouncers&&this._debouncers._increasePoolIfNeeded&&this._debouncers._increasePoolIfNeeded.cancel(),this.__preventElementUpdates=!0,t>0&&(e=this.adjustedFirstVisibleIndex,i=this.__getIndexScrollOffset(e)),this.__size=t,this._itemsChanged({path:"items"}),uu(),t>0){e=Math.min(e,t-1),this.scrollToIndex(e);const s=this.__getIndexScrollOffset(e);void 0!==i&&void 0!==s&&(this._scrollTop+=i-s)}this.__preventElementUpdates=!1,this._isVisible||this._assignModels(),this.elementsContainer.children.length||requestAnimationFrame((()=>this._resizeHandler())),this._resizeHandler(),uu(),this._debounce("_update",this._update,au)}get _scrollTop(){return this.scrollTarget.scrollTop}set _scrollTop(t){this.scrollTarget.scrollTop=t}get items(){return{length:Math.min(this.size,1e5)}}get offsetHeight(){return this.scrollTarget.offsetHeight}get $(){return{items:this.scrollContainer}}updateViewportBoundaries(){const t=window.getComputedStyle(this.scrollTarget);this._scrollerPaddingTop=this.scrollTarget===this?0:parseInt(t["padding-top"],10),this._isRTL="rtl"===t.direction,this._viewportWidth=this.elementsContainer.offsetWidth,this._viewportHeight=this.scrollTarget.offsetHeight,this._scrollPageHeight=this._viewportHeight-this._scrollLineHeight,this.grid&&this._updateGridMetrics()}setAttribute(){}_createPool(t){const e=this.createElements(t),i=document.createDocumentFragment();return e.forEach((t=>{t.style.position="absolute",i.appendChild(t),this.__resizeObserver.observe(t)})),this.elementsContainer.appendChild(i),e}_assignModels(t){const e=[];this._iterateItems(((t,i)=>{const s=this._physicalItems[t];s.hidden=i>=this.size,s.hidden?delete s.__lastUpdatedIndex:(s.__virtualIndex=i+(this._vidxOffset||0),this.__updateElement(s,s.__virtualIndex),e.push(s))}),t),this.__afterElementsUpdated(e)}_isClientFull(){return setTimeout((()=>{this.__clientFull=!0})),this.__clientFull||super._isClientFull()}translate3d(t,e,i,s){s.style.transform=`translateY(${e})`}toggleScrollListener(){}__getFocusedElement(t=this.__getVisibleElements()){return t.find((t=>t.contains(this.elementsContainer.getRootNode().activeElement)||t.contains(this.scrollTarget.getRootNode().activeElement)))}__nextFocusableSiblingMissing(t,e){return e.indexOf(t)===e.length-1&&this.size>t.__virtualIndex+1}__previousFocusableSiblingMissing(t,e){return 0===e.indexOf(t)&&t.__virtualIndex>0}__onElementFocused(t){if(!this.reorderElements)return;const e=t.detail.element;if(!e)return;const i=this.__getVisibleElements();(this.__previousFocusableSiblingMissing(e,i)||this.__nextFocusableSiblingMissing(e,i))&&this.flush();const s=this.__getVisibleElements();this.__nextFocusableSiblingMissing(e,s)?(this._scrollTop+=Math.ceil(e.getBoundingClientRect().bottom)-Math.floor(this.scrollTarget.getBoundingClientRect().bottom-1),this.flush()):this.__previousFocusableSiblingMissing(e,s)&&(this._scrollTop-=Math.ceil(this.scrollTarget.getBoundingClientRect().top+1)-Math.floor(e.getBoundingClientRect().top),this.flush())}_scrollHandler(){if(0===this.scrollTarget.offsetHeight)return;this._adjustVirtualIndexOffset(this._scrollTop-(this.__previousScrollTop||0));const t=this.scrollTarget.scrollTop-this._scrollPosition;if(super._scrollHandler(),0!==this._physicalCount){const e=t>=0,i=this._getReusables(!e);i.indexes.length&&(this._physicalTop=i.physicalTop,e?(this._virtualStart-=i.indexes.length,this._physicalStart-=i.indexes.length):(this._virtualStart+=i.indexes.length,this._physicalStart+=i.indexes.length),this._resizeHandler())}t&&(this.__fixInvalidItemPositioningDebouncer=hu.debounce(this.__fixInvalidItemPositioningDebouncer,ou.after(this.timeouts.FIX_INVALID_ITEM_POSITIONING),(()=>this.__fixInvalidItemPositioning()))),this.reorderElements&&(this.__scrollReorderDebouncer=hu.debounce(this.__scrollReorderDebouncer,ou.after(this.timeouts.SCROLL_REORDER),(()=>this.__reorderElements()))),this.__previousScrollTop=this._scrollTop,0===this._scrollTop&&0!==this.firstVisibleIndex&&Math.abs(t)>0&&this.scrollToIndex(0)}__fixInvalidItemPositioning(){if(!this.scrollTarget.isConnected)return;const t=this._physicalBottom<this._scrollBottom;if(this._physicalTop>this._scrollTop&&0!==this.adjustedFirstVisibleIndex||t&&this.adjustedLastVisibleIndex!==this.size-1){const e=t,i=this._ratio;this._ratio=0,this._scrollPosition=this._scrollTop+(e?-1:1),this._scrollHandler(),this._ratio=i}}__onWheel(t){if(t.ctrlKey||this._hasScrolledAncestor(t.target,t.deltaX,t.deltaY))return;let e=t.deltaY;if(t.deltaMode===WheelEvent.DOM_DELTA_LINE?e*=this._scrollLineHeight:t.deltaMode===WheelEvent.DOM_DELTA_PAGE&&(e*=this._scrollPageHeight),this._deltaYAcc||(this._deltaYAcc=0),this._wheelAnimationFrame)return this._deltaYAcc+=e,void t.preventDefault();e+=this._deltaYAcc,this._deltaYAcc=0,this._wheelAnimationFrame=!0,this.__debouncerWheelAnimationFrame=hu.debounce(this.__debouncerWheelAnimationFrame,ru,(()=>{this._wheelAnimationFrame=!1}));const i=Math.abs(t.deltaX)+Math.abs(e);this._canScroll(this.scrollTarget,t.deltaX,e)?(t.preventDefault(),this.scrollTarget.scrollTop+=e,this.scrollTarget.scrollLeft+=t.deltaX,this._hasResidualMomentum=!0,this._ignoreNewWheel=!0,this._debouncerIgnoreNewWheel=hu.debounce(this._debouncerIgnoreNewWheel,ou.after(this.timeouts.IGNORE_WHEEL),(()=>{this._ignoreNewWheel=!1}))):this._hasResidualMomentum&&i<=this._previousMomentum||this._ignoreNewWheel?t.preventDefault():i>this._previousMomentum&&(this._hasResidualMomentum=!1),this._previousMomentum=i}_hasScrolledAncestor(t,e,i){return t!==this.scrollTarget&&t!==this.scrollTarget.getRootNode().host&&(!(!this._canScroll(t,e,i)||-1===["auto","scroll"].indexOf(getComputedStyle(t).overflow))||(t!==this&&t.parentElement?this._hasScrolledAncestor(t.parentElement,e,i):void 0))}_canScroll(t,e,i){return i>0&&t.scrollTop<t.scrollHeight-t.offsetHeight||i<0&&t.scrollTop>0||e>0&&t.scrollLeft<t.scrollWidth-t.offsetWidth||e<0&&t.scrollLeft>0}_increasePoolIfNeeded(t){if(this._physicalCount>2&&t){const e=Math.ceil(this._optPhysicalSize/this._physicalAverage)-this._physicalCount;super._increasePoolIfNeeded(Math.max(t,Math.min(100,e)))}else super._increasePoolIfNeeded(t)}get _optPhysicalSize(){const t=super._optPhysicalSize;return t<=0||this.__hasPlaceholders()?t:t+this.__getItemHeightBuffer()}__getItemHeightBuffer(){if(0===this._physicalCount)return 0;const t=Math.ceil(this._viewportHeight*(this._maxPages-1)/2),e=Math.max(...this._physicalSizes);return e>Math.min(...this._physicalSizes)?Math.max(0,e-t):0}_getScrollLineHeight(){const t=document.createElement("div");t.style.fontSize="initial",t.style.display="none",document.body.appendChild(t);const e=window.getComputedStyle(t).fontSize;return document.body.removeChild(t),e?window.parseInt(e):void 0}__getVisibleElements(){return Array.from(this.elementsContainer.children).filter((t=>!t.hidden))}__reorderElements(){if(this.__mouseDown)return void(this.__pendingReorder=!0);this.__pendingReorder=!1;const t=this._virtualStart+(this._vidxOffset||0),e=this.__getVisibleElements(),i=this.__getFocusedElement(e)||e[0];if(!i)return;const s=i.__virtualIndex-t,o=e.indexOf(i)-s;if(o>0)for(let t=0;t<o;t++)this.elementsContainer.appendChild(e[t]);else if(o<0)for(let t=e.length+o;t<e.length;t++)this.elementsContainer.insertBefore(e[t],e[0]);if(Ic){const{transform:t}=this.scrollTarget.style;this.scrollTarget.style.transform="translateZ(0)",setTimeout((()=>{this.scrollTarget.style.transform=t}))}}_adjustVirtualIndexOffset(t){const e=this._maxVirtualIndexOffset;if(this._virtualCount>=this.size)this._vidxOffset=0;else if(this.__skipNextVirtualIndexAdjust)this.__skipNextVirtualIndexAdjust=!1;else if(Math.abs(t)>1e4)this._vidxOffset=Math.round(this._scrollTop/(this.scrollTarget.scrollHeight-this.scrollTarget.clientHeight)*e);else{const t=this._vidxOffset,i=fu,s=100;0===this._scrollTop?(this._vidxOffset=0,t!==this._vidxOffset&&super.scrollToIndex(0)):this.firstVisibleIndex<i&&this._vidxOffset>0&&(this._vidxOffset-=Math.min(this._vidxOffset,s),super.scrollToIndex(this.firstVisibleIndex+(t-this._vidxOffset))),this._scrollTop>=this._maxScrollTop&&this._maxScrollTop>0?(this._vidxOffset=e,t!==this._vidxOffset&&super.scrollToIndex(this._virtualCount-1)):this.firstVisibleIndex>this._virtualCount-i&&this._vidxOffset<e&&(this._vidxOffset+=Math.min(e-this._vidxOffset,s),super.scrollToIndex(this.firstVisibleIndex-(this._vidxOffset-t)))}}}Object.setPrototypeOf(gu.prototype,vu);class bu{constructor(t){this.__adapter=new gu(t)}get firstVisibleIndex(){return this.__adapter.adjustedFirstVisibleIndex}get lastVisibleIndex(){return this.__adapter.adjustedLastVisibleIndex}get size(){return this.__adapter.size}set size(t){this.__adapter.size=t}scrollToIndex(t){this.__adapter.scrollToIndex(t)}update(t=0,e=this.size-1){this.__adapter.update(t,e)}flush(){this.__adapter.flush()}hostConnected(){this.__adapter.hostConnected()}}
|
|
6503
6503
|
/**
|
|
6504
6504
|
* @license
|
|
6505
6505
|
* Copyright (c) 2015 - 2025 Vaadin Ltd.
|
|
6506
6506
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
6507
|
-
*/const yu=t=>class extends t{static get properties(){return{items:{type:Array,sync:!0,observer:"__itemsChanged"},focusedIndex:{type:Number,sync:!0,observer:"__focusedIndexChanged"},loading:{type:Boolean,sync:!0,observer:"__loadingChanged"},opened:{type:Boolean,sync:!0,observer:"__openedChanged"},selectedItem:{type:Object,sync:!0,observer:"__selectedItemChanged"},itemClassNameGenerator:{type:Object,observer:"__itemClassNameGeneratorChanged"},itemIdPath:{type:String},owner:{type:Object},getItemLabel:{type:Object},renderer:{type:Object,sync:!0,observer:"__rendererChanged"},theme:{type:String}}}constructor(){super(),this.__boundOnItemClick=this.__onItemClick.bind(this)}get _viewportTotalPaddingBottom(){if(void 0===this._cachedViewportTotalPaddingBottom){const t=window.getComputedStyle(this.$.selector);this._cachedViewportTotalPaddingBottom=[t.paddingBottom,t.borderBottomWidth].map((t=>parseInt(t,10))).reduce(((t,e)=>t+e))}return this._cachedViewportTotalPaddingBottom}ready(){super.ready(),this.setAttribute("role","listbox"),this.id=`${this.localName}-${Zc()}`,this.__hostTagName=this.constructor.is.replace("-scroller",""),this.addEventListener("click",(t=>t.stopPropagation())),this.__patchWheelOverScrolling()}requestContentUpdate(){this.__virtualizer&&(this.items&&(this.__virtualizer.size=this.items.length),this.opened&&this.__virtualizer.update())}scrollIntoView(t){if(!this.__virtualizer||!(this.opened&&t>=0))return;const e=this._visibleItemsCount();let i=t;t>this.__virtualizer.lastVisibleIndex-1?(this.__virtualizer.scrollToIndex(t),i=t-e+1):t>this.__virtualizer.firstVisibleIndex&&(i=this.__virtualizer.firstVisibleIndex),this.__virtualizer.scrollToIndex(Math.max(0,i));const s=[...this.children].find((t=>!t.hidden&&t.index===this.__virtualizer.lastVisibleIndex));if(!s||t!==s.index)return;const o=s.getBoundingClientRect(),r=this.getBoundingClientRect(),n=o.bottom-r.bottom+this._viewportTotalPaddingBottom;n>0&&(this.scrollTop+=n)}_isItemSelected(t,e,i){return!(t instanceof Qc)&&(i&&void 0!==t&&void 0!==e?Jc(i,t)===Jc(i,e):t===e)}__initVirtualizer(){this.__virtualizer=new
|
|
6507
|
+
*/const yu=t=>class extends t{static get properties(){return{items:{type:Array,sync:!0,observer:"__itemsChanged"},focusedIndex:{type:Number,sync:!0,observer:"__focusedIndexChanged"},loading:{type:Boolean,sync:!0,observer:"__loadingChanged"},opened:{type:Boolean,sync:!0,observer:"__openedChanged"},selectedItem:{type:Object,sync:!0,observer:"__selectedItemChanged"},itemClassNameGenerator:{type:Object,observer:"__itemClassNameGeneratorChanged"},itemIdPath:{type:String},owner:{type:Object},getItemLabel:{type:Object},renderer:{type:Object,sync:!0,observer:"__rendererChanged"},theme:{type:String}}}constructor(){super(),this.__boundOnItemClick=this.__onItemClick.bind(this)}get _viewportTotalPaddingBottom(){if(void 0===this._cachedViewportTotalPaddingBottom){const t=window.getComputedStyle(this.$.selector);this._cachedViewportTotalPaddingBottom=[t.paddingBottom,t.borderBottomWidth].map((t=>parseInt(t,10))).reduce(((t,e)=>t+e))}return this._cachedViewportTotalPaddingBottom}ready(){super.ready(),this.setAttribute("role","listbox"),this.id=`${this.localName}-${Zc()}`,this.__hostTagName=this.constructor.is.replace("-scroller",""),this.addEventListener("click",(t=>t.stopPropagation())),this.__patchWheelOverScrolling()}requestContentUpdate(){this.__virtualizer&&(this.items&&(this.__virtualizer.size=this.items.length),this.opened&&this.__virtualizer.update())}scrollIntoView(t){if(!this.__virtualizer||!(this.opened&&t>=0))return;const e=this._visibleItemsCount();let i=t;t>this.__virtualizer.lastVisibleIndex-1?(this.__virtualizer.scrollToIndex(t),i=t-e+1):t>this.__virtualizer.firstVisibleIndex&&(i=this.__virtualizer.firstVisibleIndex),this.__virtualizer.scrollToIndex(Math.max(0,i));const s=[...this.children].find((t=>!t.hidden&&t.index===this.__virtualizer.lastVisibleIndex));if(!s||t!==s.index)return;const o=s.getBoundingClientRect(),r=this.getBoundingClientRect(),n=o.bottom-r.bottom+this._viewportTotalPaddingBottom;n>0&&(this.scrollTop+=n)}_isItemSelected(t,e,i){return!(t instanceof Qc)&&(i&&void 0!==t&&void 0!==e?Jc(i,t)===Jc(i,e):t===e)}__initVirtualizer(){this.__virtualizer=new bu({createElements:this.__createElements.bind(this),updateElement:this._updateElement.bind(this),elementsContainer:this,scrollTarget:this,scrollContainer:this.$.selector,reorderElements:!0})}__itemsChanged(t){t&&this.__virtualizer&&this.requestContentUpdate()}__loadingChanged(){this.requestContentUpdate()}__openedChanged(t){t&&(this.__virtualizer||this.__initVirtualizer(),this.requestContentUpdate())}__selectedItemChanged(){this.requestContentUpdate()}__itemClassNameGeneratorChanged(t,e){(t||e)&&this.requestContentUpdate()}__focusedIndexChanged(t,e){t!==e&&this.requestContentUpdate(),t>=0&&!this.loading&&this.scrollIntoView(t)}__rendererChanged(t,e){(t||e)&&this.requestContentUpdate()}__createElements(t){return[...Array(t)].map((()=>{const t=document.createElement(`${this.__hostTagName}-item`);return t.addEventListener("click",this.__boundOnItemClick),t.tabIndex="-1",t.style.width="100%",t}))}_updateElement(t,e){const i=this.items[e],s=this.focusedIndex,o=this._isItemSelected(i,this.selectedItem,this.itemIdPath);t.setProperties({item:i,index:e,label:this.getItemLabel(i),selected:o,renderer:this.renderer,focused:!this.loading&&s===e}),"function"==typeof this.itemClassNameGenerator?t.className=this.itemClassNameGenerator(i):""!==t.className&&(t.className=""),t.id=`${this.__hostTagName}-item-${e}`,t.setAttribute("role",void 0!==e&&"option"),t.setAttribute("aria-selected",o.toString()),t.setAttribute("aria-posinset",e+1),t.setAttribute("aria-setsize",this.items.length),this.theme?t.setAttribute("theme",this.theme):t.removeAttribute("theme"),i instanceof Qc&&this.__requestItemByIndex(e)}__onItemClick(t){this.dispatchEvent(new CustomEvent("selection-changed",{detail:{item:t.currentTarget.item}}))}__patchWheelOverScrolling(){this.$.selector.addEventListener("wheel",(t=>{(0===this.scrollTop&&t.deltaY<0||this.scrollHeight-this.scrollTop-this.clientHeight<=1&&t.deltaY>0)&&t.preventDefault()}))}__requestItemByIndex(t){requestAnimationFrame((()=>{this.dispatchEvent(new CustomEvent("index-requested",{detail:{index:t}}))}))}_visibleItemsCount(){return this.__virtualizer.scrollToIndex(this.__virtualizer.firstVisibleIndex),this.__virtualizer.size>0?this.__virtualizer.lastVisibleIndex-this.__virtualizer.firstVisibleIndex+1:0}}
|
|
6508
6508
|
/**
|
|
6509
6509
|
* @license
|
|
6510
6510
|
* Copyright (c) 2021 - 2025 Vaadin Ltd.
|
|
@@ -6732,13 +6732,13 @@ window.Vaadin||(window.Vaadin={}),window.Vaadin.registrations||(window.Vaadin.re
|
|
|
6732
6732
|
* @license
|
|
6733
6733
|
* Copyright (c) 2023 - 2025 Vaadin Ltd.
|
|
6734
6734
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
6735
|
-
*/,sp=new Map;function op(t){return sp.has(t)||sp.set(t,new WeakMap),sp.get(t)}function rp(t,e){t&&t.removeAttribute(e)}function np(t,e){if(!t||!e)return;const i=op(e);if(i.has(t))return;const s=fc(t.getAttribute(e));i.set(t,new Set(s))}function ap(t,e,i={newId:null,oldId:null,fromUser:!1}){if(!t||!e)return;const{newId:s,oldId:o,fromUser:r}=i,n=op(e),a=n.get(t);if(!r&&a)return o&&a.delete(o),void(s&&a.add(s));r&&(a?s||n.delete(t):np(t,e),rp(t,e)),function(t,e,i){const s=fc(t.getAttribute(e));s.delete(i),0!==s.size?t.setAttribute(e,
|
|
6735
|
+
*/,sp=new Map;function op(t){return sp.has(t)||sp.set(t,new WeakMap),sp.get(t)}function rp(t,e){t&&t.removeAttribute(e)}function np(t,e){if(!t||!e)return;const i=op(e);if(i.has(t))return;const s=fc(t.getAttribute(e));i.set(t,new Set(s))}function ap(t,e,i={newId:null,oldId:null,fromUser:!1}){if(!t||!e)return;const{newId:s,oldId:o,fromUser:r}=i,n=op(e),a=n.get(t);if(!r&&a)return o&&a.delete(o),void(s&&a.add(s));r&&(a?s||n.delete(t):np(t,e),rp(t,e)),function(t,e,i){const s=fc(t.getAttribute(e));s.delete(i),0!==s.size?t.setAttribute(e,gc(s)):t.removeAttribute(e)}(t,e,o);const l=s||gc(a);l&&bc(t,e,l)}
|
|
6736
6736
|
/**
|
|
6737
6737
|
* @license
|
|
6738
6738
|
* Copyright (c) 2021 - 2025 Vaadin Ltd.
|
|
6739
6739
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
6740
6740
|
*/
|
|
6741
|
-
class lp{constructor(t){this.host=t,this.__required=!1}setTarget(t){this.__target=t,this.__setAriaRequiredAttribute(this.__required),this.__setLabelIdToAriaAttribute(this.__labelId,this.__labelId),null!=this.__labelIdFromUser&&this.__setLabelIdToAriaAttribute(this.__labelIdFromUser,this.__labelIdFromUser,!0),this.__setErrorIdToAriaAttribute(this.__errorId),this.__setHelperIdToAriaAttribute(this.__helperId),this.setAriaLabel(this.__label)}setRequired(t){this.__setAriaRequiredAttribute(t),this.__required=t}setAriaLabel(t){this.__setAriaLabelToAttribute(t),this.__label=t}setLabelId(t,e=!1){this.__setLabelIdToAriaAttribute(t,e?this.__labelIdFromUser:this.__labelId,e),e?this.__labelIdFromUser=t:this.__labelId=t}setErrorId(t){this.__setErrorIdToAriaAttribute(t,this.__errorId),this.__errorId=t}setHelperId(t){this.__setHelperIdToAriaAttribute(t,this.__helperId),this.__helperId=t}__setAriaLabelToAttribute(t){this.__target&&(t?(function(t,e){np(t,e),rp(t,e)}(this.__target,"aria-labelledby"),this.__target.setAttribute("aria-label",t)):this.__label&&(function(t,e){if(!t)return;const i=op(e),s=i.get(t);s&&0!==s.size?
|
|
6741
|
+
class lp{constructor(t){this.host=t,this.__required=!1}setTarget(t){this.__target=t,this.__setAriaRequiredAttribute(this.__required),this.__setLabelIdToAriaAttribute(this.__labelId,this.__labelId),null!=this.__labelIdFromUser&&this.__setLabelIdToAriaAttribute(this.__labelIdFromUser,this.__labelIdFromUser,!0),this.__setErrorIdToAriaAttribute(this.__errorId),this.__setHelperIdToAriaAttribute(this.__helperId),this.setAriaLabel(this.__label)}setRequired(t){this.__setAriaRequiredAttribute(t),this.__required=t}setAriaLabel(t){this.__setAriaLabelToAttribute(t),this.__label=t}setLabelId(t,e=!1){this.__setLabelIdToAriaAttribute(t,e?this.__labelIdFromUser:this.__labelId,e),e?this.__labelIdFromUser=t:this.__labelId=t}setErrorId(t){this.__setErrorIdToAriaAttribute(t,this.__errorId),this.__errorId=t}setHelperId(t){this.__setHelperIdToAriaAttribute(t,this.__helperId),this.__helperId=t}__setAriaLabelToAttribute(t){this.__target&&(t?(function(t,e){np(t,e),rp(t,e)}(this.__target,"aria-labelledby"),this.__target.setAttribute("aria-label",t)):this.__label&&(function(t,e){if(!t)return;const i=op(e),s=i.get(t);s&&0!==s.size?bc(t,e,gc(s)):t.removeAttribute(e),i.delete(t)}(this.__target,"aria-labelledby"),this.__target.removeAttribute("aria-label")))}__setLabelIdToAriaAttribute(t,e,i){ap(this.__target,"aria-labelledby",{newId:t,oldId:e,fromUser:i})}__setErrorIdToAriaAttribute(t,e){ap(this.__target,"aria-describedby",{newId:t,oldId:e,fromUser:!1})}__setHelperIdToAriaAttribute(t,e){ap(this.__target,"aria-describedby",{newId:t,oldId:e,fromUser:!1})}__setAriaRequiredAttribute(t){this.__target&&(["input","textarea"].includes(this.__target.localName)||(t?this.__target.setAttribute("aria-required","true"):this.__target.removeAttribute("aria-required")))}}
|
|
6742
6742
|
/**
|
|
6743
6743
|
* @license
|
|
6744
6744
|
* Copyright (c) 2022 - 2025 Vaadin Ltd.
|
|
@@ -6768,7 +6768,7 @@ class lp{constructor(t){this.host=t,this.__required=!1}setTarget(t){this.__targe
|
|
|
6768
6768
|
* @license
|
|
6769
6769
|
* Copyright (c) 2021 - 2025 Vaadin Ltd.
|
|
6770
6770
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
6771
|
-
*/,vp=Rc((t=>class extends t{static get properties(){return{stateTarget:{type:Object,observer:"_stateTargetChanged"}}}static get delegateAttrs(){return[]}static get delegateProps(){return[]}ready(){super.ready(),this._createDelegateAttrsObserver(),this._createDelegatePropsObserver()}_stateTargetChanged(t){t&&(this._ensureAttrsDelegated(),this._ensurePropsDelegated())}_createDelegateAttrsObserver(){this._createMethodObserver(`_delegateAttrsChanged(${this.constructor.delegateAttrs.join(", ")})`)}_createDelegatePropsObserver(){this._createMethodObserver(`_delegatePropsChanged(${this.constructor.delegateProps.join(", ")})`)}_ensureAttrsDelegated(){this.constructor.delegateAttrs.forEach((t=>{this._delegateAttribute(t,this[t])}))}_ensurePropsDelegated(){this.constructor.delegateProps.forEach((t=>{this._delegateProperty(t,this[t])}))}_delegateAttrsChanged(...t){this.constructor.delegateAttrs.forEach(((e,i)=>{this._delegateAttribute(e,t[i])}))}_delegatePropsChanged(...t){this.constructor.delegateProps.forEach(((e,i)=>{this._delegateProperty(e,t[i])}))}_delegateAttribute(t,e){this.stateTarget&&("invalid"===t&&this._delegateAttribute("aria-invalid",!!e&&"true"),"boolean"==typeof e?this.stateTarget.toggleAttribute(t,e):e?this.stateTarget.setAttribute(t,e):this.stateTarget.removeAttribute(t))}_delegateProperty(t,e){this.stateTarget&&(this.stateTarget[t]=e)}})),fp=Rc((t=>class extends(vp(Ou(Du(t)))){static get constraints(){return["required"]}static get delegateAttrs(){return[...super.delegateAttrs,"required"]}ready(){super.ready(),this._createConstraintsObserver()}checkValidity(){return this.inputElement&&this._hasValidConstraints(this.constructor.constraints.map((t=>this[t])))?this.inputElement.checkValidity():!this.invalid}_hasValidConstraints(t){return t.some((t=>this.__isValidConstraint(t)))}_createConstraintsObserver(){this._createMethodObserver(`_constraintsChanged(stateTarget, ${this.constructor.constraints.join(", ")})`)}_constraintsChanged(t,...e){if(!t)return;const i=this._hasValidConstraints(e),s=this.__previousHasConstraints&&!i;(this._hasValue||this.invalid)&&i?this._requestValidation():s&&!this.manualValidation&&this._setInvalid(!1),this.__previousHasConstraints=i}_onChange(t){t.stopPropagation(),this._requestValidation(),this.dispatchEvent(new CustomEvent("change",{detail:{sourceEvent:t},bubbles:t.bubbles,cancelable:t.cancelable}))}__isValidConstraint(t){return!!t||0===t}})),
|
|
6771
|
+
*/,vp=Rc((t=>class extends t{static get properties(){return{stateTarget:{type:Object,observer:"_stateTargetChanged"}}}static get delegateAttrs(){return[]}static get delegateProps(){return[]}ready(){super.ready(),this._createDelegateAttrsObserver(),this._createDelegatePropsObserver()}_stateTargetChanged(t){t&&(this._ensureAttrsDelegated(),this._ensurePropsDelegated())}_createDelegateAttrsObserver(){this._createMethodObserver(`_delegateAttrsChanged(${this.constructor.delegateAttrs.join(", ")})`)}_createDelegatePropsObserver(){this._createMethodObserver(`_delegatePropsChanged(${this.constructor.delegateProps.join(", ")})`)}_ensureAttrsDelegated(){this.constructor.delegateAttrs.forEach((t=>{this._delegateAttribute(t,this[t])}))}_ensurePropsDelegated(){this.constructor.delegateProps.forEach((t=>{this._delegateProperty(t,this[t])}))}_delegateAttrsChanged(...t){this.constructor.delegateAttrs.forEach(((e,i)=>{this._delegateAttribute(e,t[i])}))}_delegatePropsChanged(...t){this.constructor.delegateProps.forEach(((e,i)=>{this._delegateProperty(e,t[i])}))}_delegateAttribute(t,e){this.stateTarget&&("invalid"===t&&this._delegateAttribute("aria-invalid",!!e&&"true"),"boolean"==typeof e?this.stateTarget.toggleAttribute(t,e):e?this.stateTarget.setAttribute(t,e):this.stateTarget.removeAttribute(t))}_delegateProperty(t,e){this.stateTarget&&(this.stateTarget[t]=e)}})),fp=Rc((t=>class extends(vp(Ou(Du(t)))){static get constraints(){return["required"]}static get delegateAttrs(){return[...super.delegateAttrs,"required"]}ready(){super.ready(),this._createConstraintsObserver()}checkValidity(){return this.inputElement&&this._hasValidConstraints(this.constructor.constraints.map((t=>this[t])))?this.inputElement.checkValidity():!this.invalid}_hasValidConstraints(t){return t.some((t=>this.__isValidConstraint(t)))}_createConstraintsObserver(){this._createMethodObserver(`_constraintsChanged(stateTarget, ${this.constructor.constraints.join(", ")})`)}_constraintsChanged(t,...e){if(!t)return;const i=this._hasValidConstraints(e),s=this.__previousHasConstraints&&!i;(this._hasValue||this.invalid)&&i?this._requestValidation():s&&!this.manualValidation&&this._setInvalid(!1),this.__previousHasConstraints=i}_onChange(t){t.stopPropagation(),this._requestValidation(),this.dispatchEvent(new CustomEvent("change",{detail:{sourceEvent:t},bubbles:t.bubbles,cancelable:t.cancelable}))}__isValidConstraint(t){return!!t||0===t}})),gp=t=>class extends(ep(Zu(fp(mp(ip(Eu(t))))))){static get properties(){return{allowedCharPattern:{type:String,observer:"_allowedCharPatternChanged"},autoselect:{type:Boolean,value:!1},name:{type:String,reflectToAttribute:!0},placeholder:{type:String,reflectToAttribute:!0},readonly:{type:Boolean,value:!1,reflectToAttribute:!0},title:{type:String,reflectToAttribute:!0}}}static get delegateAttrs(){return[...super.delegateAttrs,"name","type","placeholder","readonly","invalid","title"]}constructor(){super(),this._boundOnPaste=this._onPaste.bind(this),this._boundOnDrop=this._onDrop.bind(this),this._boundOnBeforeInput=this._onBeforeInput.bind(this)}get slotStyles(){return["\n :is(input[slot='input'], textarea[slot='textarea'])::placeholder {\n font: inherit;\n color: inherit;\n }\n "]}_onFocus(t){super._onFocus(t),this.autoselect&&this.inputElement&&this.inputElement.select()}_addInputListeners(t){super._addInputListeners(t),t.addEventListener("paste",this._boundOnPaste),t.addEventListener("drop",this._boundOnDrop),t.addEventListener("beforeinput",this._boundOnBeforeInput)}_removeInputListeners(t){super._removeInputListeners(t),t.removeEventListener("paste",this._boundOnPaste),t.removeEventListener("drop",this._boundOnDrop),t.removeEventListener("beforeinput",this._boundOnBeforeInput)}_onKeyDown(t){super._onKeyDown(t),this.allowedCharPattern&&!this.__shouldAcceptKey(t)&&t.target===this.inputElement&&(t.preventDefault(),this._markInputPrevented())}_markInputPrevented(){this.setAttribute("input-prevented",""),this._preventInputDebouncer=hu.debounce(this._preventInputDebouncer,ou.after(200),(()=>{this.removeAttribute("input-prevented")}))}__shouldAcceptKey(t){return t.metaKey||t.ctrlKey||!t.key||1!==t.key.length||this.__allowedCharRegExp.test(t.key)}_onPaste(t){if(this.allowedCharPattern){const e=t.clipboardData.getData("text");this.__allowedTextRegExp.test(e)||(t.preventDefault(),this._markInputPrevented())}}_onDrop(t){if(this.allowedCharPattern){const e=t.dataTransfer.getData("text");this.__allowedTextRegExp.test(e)||(t.preventDefault(),this._markInputPrevented())}}_onBeforeInput(t){this.allowedCharPattern&&t.data&&!this.__allowedTextRegExp.test(t.data)&&(t.preventDefault(),this._markInputPrevented())}_allowedCharPatternChanged(t){if(t)try{this.__allowedCharRegExp=new RegExp(`^${t}$`,"u"),this.__allowedTextRegExp=new RegExp(`^${t}*$`,"u")}catch(t){console.error(t)}}}
|
|
6772
6772
|
/**
|
|
6773
6773
|
* @license
|
|
6774
6774
|
* Copyright (c) 2021 - 2025 Vaadin Ltd.
|
|
@@ -6778,7 +6778,7 @@ class lp{constructor(t){this.host=t,this.__required=!1}setTarget(t){this.__targe
|
|
|
6778
6778
|
* @license
|
|
6779
6779
|
* Copyright (c) 2021 - 2025 Vaadin Ltd.
|
|
6780
6780
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
6781
|
-
*/class
|
|
6781
|
+
*/class bp extends Qu{constructor(t,e,i={}){const{uniqueIdPrefix:s}=i;super(t,"input","input",{initializer:(t,i)=>{i.value&&(t.value=i.value),i.type&&t.setAttribute("type",i.type),t.id=this.defaultId,"function"==typeof e&&e(t)},useUniqueId:!0,uniqueIdPrefix:s})}}
|
|
6782
6782
|
/**
|
|
6783
6783
|
* @license
|
|
6784
6784
|
* Copyright (c) 2021 - 2025 Vaadin Ltd.
|
|
@@ -6788,7 +6788,7 @@ class lp{constructor(t){this.host=t,this.__required=!1}setTarget(t){this.__targe
|
|
|
6788
6788
|
* @license
|
|
6789
6789
|
* Copyright (c) 2021 - 2025 Vaadin Ltd.
|
|
6790
6790
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
6791
|
-
*/const wp=t=>class extends(bp(Uu(t))){static get properties(){return{autoExpandHorizontally:{type:Boolean,value:!1,reflectToAttribute:!0,observer:"_autoExpandHorizontallyChanged",sync:!0},autoExpandVertically:{type:Boolean,value:!1,reflectToAttribute:!0,observer:"_autoExpandVerticallyChanged",sync:!0},autoOpenDisabled:{type:Boolean,sync:!0},clearButtonVisible:{type:Boolean,reflectToAttribute:!0,observer:"_clearButtonVisibleChanged",value:!1,sync:!0},items:{type:Array,sync:!0},itemClassNameGenerator:{type:Object,observer:"__itemClassNameGeneratorChanged",sync:!0},itemLabelPath:{type:String,value:"label",sync:!0},itemValuePath:{type:String,value:"value",sync:!0},itemIdPath:{type:String,sync:!0},i18n:{type:Object,value:()=>({cleared:"Selection cleared",focused:"focused. Press Backspace to remove",selected:"added to selection",deselected:"removed from selection",total:"{count} items selected"})},keepFilter:{type:Boolean,value:!1},loading:{type:Boolean,value:!1,reflectToAttribute:!0,sync:!0},overlayClass:{type:String,sync:!0},readonly:{type:Boolean,value:!1,observer:"_readonlyChanged",reflectToAttribute:!0,sync:!0},selectedItems:{type:Array,value:()=>[],notify:!0,sync:!0},opened:{type:Boolean,notify:!0,value:!1,reflectToAttribute:!0,sync:!0},size:{type:Number,sync:!0},pageSize:{type:Number,value:50,observer:"_pageSizeChanged",sync:!0},dataProvider:{type:Object,sync:!0},allowCustomValue:{type:Boolean,value:!1},placeholder:{type:String,observer:"_placeholderChanged",sync:!0},renderer:{type:Function,sync:!0},filter:{type:String,value:"",notify:!0,sync:!0},filteredItems:{type:Array,sync:!0},selectedItemsOnTop:{type:Boolean,value:!1,sync:!0},value:{type:String},_overflowItems:{type:Array,value:()=>[],sync:!0},_focusedChipIndex:{type:Number,value:-1,observer:"_focusedChipIndexChanged"},_lastFilter:{type:String,sync:!0},_topGroup:{type:Array}}}static get observers(){return["_selectedItemsChanged(selectedItems)","__updateOverflowChip(_overflow, _overflowItems, disabled, readonly)","__updateTopGroup(selectedItemsOnTop, selectedItems, opened)"]}get slotStyles(){return[...super.slotStyles,`\n ${this.localName}[has-value] input::placeholder {\n color: transparent !important;\n forced-color-adjust: none;\n }\n `]}get clearElement(){return this.$.clearButton}get _chips(){return[...this.querySelectorAll('[slot="chip"]')]}get _hasValue(){return this.selectedItems&&this.selectedItems.length>0}ready(){super.ready(),this.addController(new gp(this,(t=>{this._setInputElement(t),this._setFocusElement(t),this.stateTarget=t,this.ariaTarget=t}))),this.addController(new yp(this.inputElement,this._labelController)),this._tooltipController=new Ju(this),this.addController(this._tooltipController),this._tooltipController.setPosition("top"),this._tooltipController.setAriaTarget(this.inputElement),this._tooltipController.setShouldShow((t=>!t.opened)),this._inputField=this.shadowRoot.querySelector('[part="input-field"]'),this._overflowController=new Qu(this,"overflow","vaadin-multi-select-combo-box-chip",{initializer:t=>{t.addEventListener("mousedown",(t=>this._preventBlur(t))),this._overflow=t}}),this.addController(this._overflowController),this.__updateChips(),Mu(this)}checkValidity(){return!(this.required&&!this.readonly)||this._hasValue}clear(){this.__updateSelection([]),Gu(this.i18n.cleared)}clearCache(){this.$&&this.$.comboBox&&this.$.comboBox.clearCache()}requestContentUpdate(){this.$&&this.$.comboBox&&this.$.comboBox.requestContentUpdate()}_disabledChanged(t,e){super._disabledChanged(t,e),(t||e)&&this.__updateChips()}_inputElementChanged(t){super._inputElementChanged(t),t&&this.$.comboBox._setInputElement(t)}_setFocused(t){super._setFocused(t),!t&&document.hasFocus()&&(this._focusedChipIndex=-1,this._requestValidation())}_onResize(){this.__updateChips()}_delegateAttribute(t,e){if(this.stateTarget){if("required"===t)return void this._delegateAttribute("aria-required",!!e&&"true");super._delegateAttribute(t,e)}}_autoExpandHorizontallyChanged(t,e){(t||e)&&this.__updateChips()}_autoExpandVerticallyChanged(t,e){(t||e)&&this.__updateChips()}_clearButtonVisibleChanged(t,e){(t||e)&&this.__updateChips()}_onFilteredItemsChanged(t){const{value:e}=t.detail;(Array.isArray(e)||null==e)&&(this.filteredItems=e)}_readonlyChanged(t,e){(t||e)&&this.__updateChips(),this.dataProvider&&this.clearCache()}__itemClassNameGeneratorChanged(t,e){(t||e)&&this.__updateChips()}_pageSizeChanged(t,e){(Math.floor(t)!==t||t<=0)&&(this.pageSize=e,console.error('"pageSize" value must be an integer > 0')),this.$.comboBox.pageSize=this.pageSize}_placeholderChanged(t){const e=this.__tmpA11yPlaceholder;e!==t&&(this.__savedPlaceholder=t,e&&(this.placeholder=e))}_selectedItemsChanged(t){if(this._toggleHasValue(this._hasValue),this._hasValue){const e=this._mergeItemLabels(t);void 0===this.__tmpA11yPlaceholder&&(this.__savedPlaceholder=this.placeholder),this.__tmpA11yPlaceholder=e,this.placeholder=e}else void 0!==this.__tmpA11yPlaceholder&&(delete this.__tmpA11yPlaceholder,this.placeholder=this.__savedPlaceholder);this.__updateChips(),this.requestContentUpdate(),this.opened&&this.$.comboBox._updateOverlayWidth()}_getItemLabel(t){return this.$.comboBox._getItemLabel(t)}_mergeItemLabels(t){return t.map((t=>this._getItemLabel(t))).join(", ")}_findIndex(t,e,i){if(i&&t){for(let s=0;s<e.length;s++)if(e[s]&&e[s][i]===t[i])return s;return-1}return e.indexOf(t)}__clearInternalValue(t=!1){!this.keepFilter||t?(this.filter="",this.$.comboBox.clear()):(this.$.comboBox.clear(),this._inputElementValue=this.filter)}__announceItem(t,e,i){const s=e?"selected":"deselected",o=this.i18n.total.replace("{count}",i||0);Gu(`${t} ${this.i18n[s]} ${o}`)}__removeItem(t){const e=[...this.selectedItems];e.splice(e.indexOf(t),1),this.__updateSelection(e);const i=this._getItemLabel(t);this.__announceItem(i,!1,e.length)}__selectItem(t){const e=[...this.selectedItems],i=this._findIndex(t,e,this.itemIdPath),s=this._getItemLabel(t);let o=!1;if(-1!==i){const t=this._lastFilter;if(t&&t.toLowerCase()===s.toLowerCase())return void this.__clearInternalValue();e.splice(i,1)}else e.push(t),o=!0;this.__updateSelection(e),this.__clearInternalValue(),this.__announceItem(s,o,e.length)}__updateSelection(t){this.selectedItems=t,this._requestValidation(),this.dispatchEvent(new CustomEvent("change",{bubbles:!0}))}__updateTopGroup(t,e,i){t?(!i||this.__needToSyncTopGroup())&&(this._topGroup=[...e]):this._topGroup=[]}__needToSyncTopGroup(){return!!this.itemIdPath&&this._topGroup&&this._topGroup.some((t=>{const e=this.selectedItems[this._findIndex(t,this.selectedItems,this.itemIdPath)];return e&&t!==e}))}__createChip(t){const e=document.createElement("vaadin-multi-select-combo-box-chip");e.setAttribute("slot","chip"),e.item=t,e.disabled=this.disabled,e.readonly=this.readonly;const i=this._getItemLabel(t);return e.label=i,e.setAttribute("title",i),"function"==typeof this.itemClassNameGenerator&&(e.className=this.itemClassNameGenerator(t)),e.addEventListener("item-removed",(t=>this._onItemRemoved(t))),e.addEventListener("mousedown",(t=>this._preventBlur(t))),e}__getOverflowWidth(){const t=this._overflow;t.style.visibility="hidden",t.removeAttribute("hidden");const e=t.getAttribute("count");t.setAttribute("count","99");const i=getComputedStyle(t),s=t.clientWidth+parseInt(i.marginInlineStart);return t.setAttribute("count",e),t.setAttribute("hidden",""),t.style.visibility="",s}__updateChips(){if(!this._inputField||!this.inputElement)return;this._chips.forEach((t=>{t.remove()}));const t=[...this.selectedItems],e=this._inputField.$.wrapper.clientWidth,i=parseInt(getComputedStyle(this.inputElement).flexBasis);let s=e-i;t.length>1&&(s-=this.__getOverflowWidth());const o=parseInt(getComputedStyle(this).getPropertyValue("--_chip-min-width"));if(this.autoExpandHorizontally){const e=[];for(let i=t.length-1,s=null;i>=0;i--){const o=this.__createChip(t[i]);this.insertBefore(o,s),s=o,e.unshift(o)}const r=[];if(!this.autoExpandVertically&&this._inputField.$.wrapper.clientWidth-this.$.chips.clientWidth<i){for(;e.length>1;){e.pop().remove(),r.unshift(t.pop());const s=r.length>0?i+this.__getOverflowWidth():i;if(this._inputField.$.wrapper.clientWidth-this.$.chips.clientWidth>=s)break}1===e.length&&(e[0].style.maxWidth=`${Math.max(o,s)}px`)}this._overflowItems=r}else{for(let e=t.length-1,i=null;e>=0;e--){const r=this.__createChip(t[e]);if(this.insertBefore(r,i),!this.autoExpandVertically){if(this.$.chips.clientWidth>s&&(s<o||null!==i)){r.remove();break}r.style.maxWidth=`${s}px`}t.pop(),i=r}this._overflowItems=t}}__updateOverflowChip(t,e,i,s){if(t){const o=e.length;t.label=`${o}`,t.setAttribute("count",`${o}`),t.setAttribute("title",this._mergeItemLabels(e)),t.toggleAttribute("hidden",0===o),t.disabled=i,t.readonly=s}}_onClearButtonTouchend(t){t.preventDefault(),t.stopPropagation(),this.clear()}_onClearButtonClick(t){t.stopPropagation(),this.clear()}_onChange(t){t.stopPropagation()}_onEscape(t){this.clearButtonVisible&&this.selectedItems&&this.selectedItems.length&&(t.stopPropagation(),this.selectedItems=[])}_onKeyDown(t){super._onKeyDown(t);const e=this._chips;if(!this.readonly&&e.length>0)switch(t.key){case"Backspace":this._onBackSpace(e);break;case"ArrowLeft":this._onArrowLeft(e,t);break;case"ArrowRight":this._onArrowRight(e,t);break;default:this._focusedChipIndex=-1}}_onArrowLeft(t,e){if(0!==this.inputElement.selectionStart)return;const i=this._focusedChipIndex;let s;-1!==i&&e.preventDefault(),this.__isRTL?i===t.length-1?s=-1:i>-1&&(s=i+1):-1===i?s=t.length-1:i>0&&(s=i-1),void 0!==s&&(this._focusedChipIndex=s)}_onArrowRight(t,e){if(0!==this.inputElement.selectionStart)return;const i=this._focusedChipIndex;let s;-1!==i&&e.preventDefault(),this.__isRTL?-1===i?s=t.length-1:i>0&&(s=i-1):i===t.length-1?s=-1:i>-1&&(s=i+1),void 0!==s&&(this._focusedChipIndex=s)}_onBackSpace(t){if(0!==this.inputElement.selectionStart)return;const e=this._focusedChipIndex;-1===e?this._focusedChipIndex=t.length-1:(this.__removeItem(t[e].item),this._focusedChipIndex=-1)}_focusedChipIndexChanged(t,e){if(t>-1||e>-1){const e=this._chips;e.forEach(((e,i)=>{e.toggleAttribute("focused",i===t)})),t>-1&&Gu(`${this._getItemLabel(e[t].item)} ${this.i18n.focused}`)}}_onComboBoxChange(){const t=this.$.comboBox.selectedItem;t&&this.__selectItem(t)}_onComboBoxItemSelected(t){this.__selectItem(t.detail.item)}_onCustomValueSet(t){t.preventDefault(),t.stopPropagation(),this.__clearInternalValue(!0),this.dispatchEvent(new CustomEvent("custom-value-set",{detail:t.detail,composed:!0,bubbles:!0}))}_onItemRemoved(t){this.__removeItem(t.detail.item)}_preventBlur(t){t.preventDefault()}}
|
|
6791
|
+
*/const wp=t=>class extends(gp(Uu(t))){static get properties(){return{autoExpandHorizontally:{type:Boolean,value:!1,reflectToAttribute:!0,observer:"_autoExpandHorizontallyChanged",sync:!0},autoExpandVertically:{type:Boolean,value:!1,reflectToAttribute:!0,observer:"_autoExpandVerticallyChanged",sync:!0},autoOpenDisabled:{type:Boolean,sync:!0},clearButtonVisible:{type:Boolean,reflectToAttribute:!0,observer:"_clearButtonVisibleChanged",value:!1,sync:!0},items:{type:Array,sync:!0},itemClassNameGenerator:{type:Object,observer:"__itemClassNameGeneratorChanged",sync:!0},itemLabelPath:{type:String,value:"label",sync:!0},itemValuePath:{type:String,value:"value",sync:!0},itemIdPath:{type:String,sync:!0},i18n:{type:Object,value:()=>({cleared:"Selection cleared",focused:"focused. Press Backspace to remove",selected:"added to selection",deselected:"removed from selection",total:"{count} items selected"})},keepFilter:{type:Boolean,value:!1},loading:{type:Boolean,value:!1,reflectToAttribute:!0,sync:!0},overlayClass:{type:String,sync:!0},readonly:{type:Boolean,value:!1,observer:"_readonlyChanged",reflectToAttribute:!0,sync:!0},selectedItems:{type:Array,value:()=>[],notify:!0,sync:!0},opened:{type:Boolean,notify:!0,value:!1,reflectToAttribute:!0,sync:!0},size:{type:Number,sync:!0},pageSize:{type:Number,value:50,observer:"_pageSizeChanged",sync:!0},dataProvider:{type:Object,sync:!0},allowCustomValue:{type:Boolean,value:!1},placeholder:{type:String,observer:"_placeholderChanged",sync:!0},renderer:{type:Function,sync:!0},filter:{type:String,value:"",notify:!0,sync:!0},filteredItems:{type:Array,sync:!0},selectedItemsOnTop:{type:Boolean,value:!1,sync:!0},value:{type:String},_overflowItems:{type:Array,value:()=>[],sync:!0},_focusedChipIndex:{type:Number,value:-1,observer:"_focusedChipIndexChanged"},_lastFilter:{type:String,sync:!0},_topGroup:{type:Array}}}static get observers(){return["_selectedItemsChanged(selectedItems)","__updateOverflowChip(_overflow, _overflowItems, disabled, readonly)","__updateTopGroup(selectedItemsOnTop, selectedItems, opened)"]}get slotStyles(){return[...super.slotStyles,`\n ${this.localName}[has-value] input::placeholder {\n color: transparent !important;\n forced-color-adjust: none;\n }\n `]}get clearElement(){return this.$.clearButton}get _chips(){return[...this.querySelectorAll('[slot="chip"]')]}get _hasValue(){return this.selectedItems&&this.selectedItems.length>0}ready(){super.ready(),this.addController(new bp(this,(t=>{this._setInputElement(t),this._setFocusElement(t),this.stateTarget=t,this.ariaTarget=t}))),this.addController(new yp(this.inputElement,this._labelController)),this._tooltipController=new Ju(this),this.addController(this._tooltipController),this._tooltipController.setPosition("top"),this._tooltipController.setAriaTarget(this.inputElement),this._tooltipController.setShouldShow((t=>!t.opened)),this._inputField=this.shadowRoot.querySelector('[part="input-field"]'),this._overflowController=new Qu(this,"overflow","vaadin-multi-select-combo-box-chip",{initializer:t=>{t.addEventListener("mousedown",(t=>this._preventBlur(t))),this._overflow=t}}),this.addController(this._overflowController),this.__updateChips(),Mu(this)}checkValidity(){return!(this.required&&!this.readonly)||this._hasValue}clear(){this.__updateSelection([]),Gu(this.i18n.cleared)}clearCache(){this.$&&this.$.comboBox&&this.$.comboBox.clearCache()}requestContentUpdate(){this.$&&this.$.comboBox&&this.$.comboBox.requestContentUpdate()}_disabledChanged(t,e){super._disabledChanged(t,e),(t||e)&&this.__updateChips()}_inputElementChanged(t){super._inputElementChanged(t),t&&this.$.comboBox._setInputElement(t)}_setFocused(t){super._setFocused(t),!t&&document.hasFocus()&&(this._focusedChipIndex=-1,this._requestValidation())}_onResize(){this.__updateChips()}_delegateAttribute(t,e){if(this.stateTarget){if("required"===t)return void this._delegateAttribute("aria-required",!!e&&"true");super._delegateAttribute(t,e)}}_autoExpandHorizontallyChanged(t,e){(t||e)&&this.__updateChips()}_autoExpandVerticallyChanged(t,e){(t||e)&&this.__updateChips()}_clearButtonVisibleChanged(t,e){(t||e)&&this.__updateChips()}_onFilteredItemsChanged(t){const{value:e}=t.detail;(Array.isArray(e)||null==e)&&(this.filteredItems=e)}_readonlyChanged(t,e){(t||e)&&this.__updateChips(),this.dataProvider&&this.clearCache()}__itemClassNameGeneratorChanged(t,e){(t||e)&&this.__updateChips()}_pageSizeChanged(t,e){(Math.floor(t)!==t||t<=0)&&(this.pageSize=e,console.error('"pageSize" value must be an integer > 0')),this.$.comboBox.pageSize=this.pageSize}_placeholderChanged(t){const e=this.__tmpA11yPlaceholder;e!==t&&(this.__savedPlaceholder=t,e&&(this.placeholder=e))}_selectedItemsChanged(t){if(this._toggleHasValue(this._hasValue),this._hasValue){const e=this._mergeItemLabels(t);void 0===this.__tmpA11yPlaceholder&&(this.__savedPlaceholder=this.placeholder),this.__tmpA11yPlaceholder=e,this.placeholder=e}else void 0!==this.__tmpA11yPlaceholder&&(delete this.__tmpA11yPlaceholder,this.placeholder=this.__savedPlaceholder);this.__updateChips(),this.requestContentUpdate(),this.opened&&this.$.comboBox._updateOverlayWidth()}_getItemLabel(t){return this.$.comboBox._getItemLabel(t)}_mergeItemLabels(t){return t.map((t=>this._getItemLabel(t))).join(", ")}_findIndex(t,e,i){if(i&&t){for(let s=0;s<e.length;s++)if(e[s]&&e[s][i]===t[i])return s;return-1}return e.indexOf(t)}__clearInternalValue(t=!1){!this.keepFilter||t?(this.filter="",this.$.comboBox.clear()):(this.$.comboBox.clear(),this._inputElementValue=this.filter)}__announceItem(t,e,i){const s=e?"selected":"deselected",o=this.i18n.total.replace("{count}",i||0);Gu(`${t} ${this.i18n[s]} ${o}`)}__removeItem(t){const e=[...this.selectedItems];e.splice(e.indexOf(t),1),this.__updateSelection(e);const i=this._getItemLabel(t);this.__announceItem(i,!1,e.length)}__selectItem(t){const e=[...this.selectedItems],i=this._findIndex(t,e,this.itemIdPath),s=this._getItemLabel(t);let o=!1;if(-1!==i){const t=this._lastFilter;if(t&&t.toLowerCase()===s.toLowerCase())return void this.__clearInternalValue();e.splice(i,1)}else e.push(t),o=!0;this.__updateSelection(e),this.__clearInternalValue(),this.__announceItem(s,o,e.length)}__updateSelection(t){this.selectedItems=t,this._requestValidation(),this.dispatchEvent(new CustomEvent("change",{bubbles:!0}))}__updateTopGroup(t,e,i){t?(!i||this.__needToSyncTopGroup())&&(this._topGroup=[...e]):this._topGroup=[]}__needToSyncTopGroup(){return!!this.itemIdPath&&this._topGroup&&this._topGroup.some((t=>{const e=this.selectedItems[this._findIndex(t,this.selectedItems,this.itemIdPath)];return e&&t!==e}))}__createChip(t){const e=document.createElement("vaadin-multi-select-combo-box-chip");e.setAttribute("slot","chip"),e.item=t,e.disabled=this.disabled,e.readonly=this.readonly;const i=this._getItemLabel(t);return e.label=i,e.setAttribute("title",i),"function"==typeof this.itemClassNameGenerator&&(e.className=this.itemClassNameGenerator(t)),e.addEventListener("item-removed",(t=>this._onItemRemoved(t))),e.addEventListener("mousedown",(t=>this._preventBlur(t))),e}__getOverflowWidth(){const t=this._overflow;t.style.visibility="hidden",t.removeAttribute("hidden");const e=t.getAttribute("count");t.setAttribute("count","99");const i=getComputedStyle(t),s=t.clientWidth+parseInt(i.marginInlineStart);return t.setAttribute("count",e),t.setAttribute("hidden",""),t.style.visibility="",s}__updateChips(){if(!this._inputField||!this.inputElement)return;this._chips.forEach((t=>{t.remove()}));const t=[...this.selectedItems],e=this._inputField.$.wrapper.clientWidth,i=parseInt(getComputedStyle(this.inputElement).flexBasis);let s=e-i;t.length>1&&(s-=this.__getOverflowWidth());const o=parseInt(getComputedStyle(this).getPropertyValue("--_chip-min-width"));if(this.autoExpandHorizontally){const e=[];for(let i=t.length-1,s=null;i>=0;i--){const o=this.__createChip(t[i]);this.insertBefore(o,s),s=o,e.unshift(o)}const r=[];if(!this.autoExpandVertically&&this._inputField.$.wrapper.clientWidth-this.$.chips.clientWidth<i){for(;e.length>1;){e.pop().remove(),r.unshift(t.pop());const s=r.length>0?i+this.__getOverflowWidth():i;if(this._inputField.$.wrapper.clientWidth-this.$.chips.clientWidth>=s)break}1===e.length&&(e[0].style.maxWidth=`${Math.max(o,s)}px`)}this._overflowItems=r}else{for(let e=t.length-1,i=null;e>=0;e--){const r=this.__createChip(t[e]);if(this.insertBefore(r,i),!this.autoExpandVertically){if(this.$.chips.clientWidth>s&&(s<o||null!==i)){r.remove();break}r.style.maxWidth=`${s}px`}t.pop(),i=r}this._overflowItems=t}}__updateOverflowChip(t,e,i,s){if(t){const o=e.length;t.label=`${o}`,t.setAttribute("count",`${o}`),t.setAttribute("title",this._mergeItemLabels(e)),t.toggleAttribute("hidden",0===o),t.disabled=i,t.readonly=s}}_onClearButtonTouchend(t){t.preventDefault(),t.stopPropagation(),this.clear()}_onClearButtonClick(t){t.stopPropagation(),this.clear()}_onChange(t){t.stopPropagation()}_onEscape(t){this.clearButtonVisible&&this.selectedItems&&this.selectedItems.length&&(t.stopPropagation(),this.selectedItems=[])}_onKeyDown(t){super._onKeyDown(t);const e=this._chips;if(!this.readonly&&e.length>0)switch(t.key){case"Backspace":this._onBackSpace(e);break;case"ArrowLeft":this._onArrowLeft(e,t);break;case"ArrowRight":this._onArrowRight(e,t);break;default:this._focusedChipIndex=-1}}_onArrowLeft(t,e){if(0!==this.inputElement.selectionStart)return;const i=this._focusedChipIndex;let s;-1!==i&&e.preventDefault(),this.__isRTL?i===t.length-1?s=-1:i>-1&&(s=i+1):-1===i?s=t.length-1:i>0&&(s=i-1),void 0!==s&&(this._focusedChipIndex=s)}_onArrowRight(t,e){if(0!==this.inputElement.selectionStart)return;const i=this._focusedChipIndex;let s;-1!==i&&e.preventDefault(),this.__isRTL?-1===i?s=t.length-1:i>0&&(s=i-1):i===t.length-1?s=-1:i>-1&&(s=i+1),void 0!==s&&(this._focusedChipIndex=s)}_onBackSpace(t){if(0!==this.inputElement.selectionStart)return;const e=this._focusedChipIndex;-1===e?this._focusedChipIndex=t.length-1:(this.__removeItem(t[e].item),this._focusedChipIndex=-1)}_focusedChipIndexChanged(t,e){if(t>-1||e>-1){const e=this._chips;e.forEach(((e,i)=>{e.toggleAttribute("focused",i===t)})),t>-1&&Gu(`${this._getItemLabel(e[t].item)} ${this.i18n.focused}`)}}_onComboBoxChange(){const t=this.$.comboBox.selectedItem;t&&this.__selectItem(t)}_onComboBoxItemSelected(t){this.__selectItem(t.detail.item)}_onCustomValueSet(t){t.preventDefault(),t.stopPropagation(),this.__clearInternalValue(!0),this.dispatchEvent(new CustomEvent("custom-value-set",{detail:t.detail,composed:!0,bubbles:!0}))}_onItemRemoved(t){this.__removeItem(t.detail.item)}_preventBlur(t){t.preventDefault()}}
|
|
6792
6792
|
/**
|
|
6793
6793
|
* @license
|
|
6794
6794
|
* Copyright (c) 2021 - 2025 Vaadin Ltd.
|
|
@@ -7329,7 +7329,7 @@ const Sp=t=>class extends(ha(wa(t))){static get properties(){return{_hasVaadinIt
|
|
|
7329
7329
|
* Copyright (c) 2022 - 2024 Vaadin Ltd.
|
|
7330
7330
|
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
|
|
7331
7331
|
*/
|
|
7332
|
-
const Ip=t=>class extends(la(t)){get focused(){return(this._getItems()||[]).find(
|
|
7332
|
+
const Ip=t=>class extends(la(t)){get focused(){return(this._getItems()||[]).find(ba)}get _vertical(){return!0}focus(){const t=this._getItems();if(Array.isArray(t)){const e=this._getAvailableIndex(t,0,null,(t=>!fa(t)));e>=0&&this._focus(e)}}_getItems(){return Array.from(this.children)}_onKeyDown(t){if(super._onKeyDown(t),t.metaKey||t.ctrlKey)return;const{key:e}=t,i=this._getItems()||[],s=i.indexOf(this.focused);let o,r;const n=this._vertical||"rtl"!==this.getAttribute("dir")?1:-1;this.__isPrevKey(e)?(r=-n,o=s-n):this.__isNextKey(e)?(r=n,o=s+n):"Home"===e?(r=1,o=0):"End"===e&&(r=-1,o=i.length-1),o=this._getAvailableIndex(i,o,r,(t=>!fa(t))),o>=0&&(t.preventDefault(),this._focus(o,!0))}__isPrevKey(t){return this._vertical?"ArrowUp"===t:"ArrowLeft"===t}__isNextKey(t){return this._vertical?"ArrowDown"===t:"ArrowRight"===t}_focus(t,e=!1){const i=this._getItems();this._focusItem(i[t],e)}_focusItem(t){t&&(t.focus(),t.setAttribute("focus-ring",""))}_getAvailableIndex(t,e,i,s){const o=t.length;let r=e;for(let e=0;"number"==typeof r&&e<o;e+=1,r+=i||1){r<0?r=o-1:r>=o&&(r=0);const e=t[r];if(!e.hasAttribute("disabled")&&this.__isMatchingItem(e,s))return r}return-1}__isMatchingItem(t,e){return"function"!=typeof e||e(t)}}
|
|
7333
7333
|
/**
|
|
7334
7334
|
* @license
|
|
7335
7335
|
* Copyright (c) 2017 - 2024 Vaadin Ltd.
|
|
@@ -7972,4 +7972,4 @@ const Hp=t=>class extends t{static get properties(){return{accessibleDescription
|
|
|
7972
7972
|
<slot name="reject-button"></slot>
|
|
7973
7973
|
<slot name="confirm-button"></slot>
|
|
7974
7974
|
</div>
|
|
7975
|
-
`}static get is(){return"vaadin-confirm-dialog"}ready(){super.ready(),this._overlayElement=this.$.dialog.$.overlay,this._initOverlay(this._overlayElement)}}li(Wp);const Gp=class{constructor(e){t(this,e),this.handleClick=t=>{this.emitOnClick&&(t.stopPropagation(),window.postMessage({type:`registration${this.name}Clicked`},window.location.href))},this.type="text",this.name=void 0,this.displayName=void 0,this.placeholder=void 0,this.action=void 0,this.validation=void 0,this.options=void 0,this.language=void 0,this.autofilled=void 0,this.tooltip=void 0,this.defaultValue=void 0,this.emitValue=void 0,this.isDuplicateInput=void 0,this.hidePasswordComplexity=!1,this.clientStyling="",this.dateFormat=void 0,this.translationUrl="",this.emitOnClick=!1,this.twofaDestination=void 0,this.twofaResendIntervalSeconds=60}connectedCallback(){var t;this.translationUrl&&(t=this.translationUrl,new Promise((e=>{fetch(t).then((t=>t.json())).then((t=>{Object.keys(t).forEach((e=>{for(let i in t[e])r[e][i]=t[e][i]})),e(!0)}))})))}renderInput(){var t;switch(null===(t=this.type)||void 0===t?void 0:t.toLowerCase()){case"text":return i("text-input",{name:this.name,displayName:this.displayName,validation:this.validation,defaultValue:this.defaultValue,autofilled:this.autofilled,emitValue:this.emitValue,language:this.language,isDuplicateInput:this.isDuplicateInput,"client-styling":this.clientStyling,tooltip:this.tooltip,placeholder:this.placeholder});case"email":return i("email-input",{name:this.name,displayName:this.displayName,validation:this.validation,defaultValue:this.defaultValue,autofilled:this.autofilled,emitValue:this.emitValue,language:this.language,isDuplicateInput:this.isDuplicateInput,"client-styling":this.clientStyling,tooltip:this.tooltip,placeholder:this.placeholder});case"number":return i("number-input",{name:this.name,displayName:this.displayName,validation:this.validation,defaultValue:this.defaultValue,autofilled:this.autofilled,emitValue:this.emitValue,language:this.language,"client-styling":this.clientStyling,tooltip:this.tooltip,placeholder:this.placeholder});case"checkbox":return i("checkbox-input",{name:this.name,displayName:this.displayName,validation:this.validation,emitValue:this.emitValue,defaultValue:this.defaultValue,autofilled:this.autofilled,language:this.language,"client-styling":this.clientStyling,tooltip:this.tooltip});case"checkboxgroup":return i("checkbox-group-input",{name:this.name,displayName:this.displayName,validation:this.validation,defaultValue:this.defaultValue,autofilled:this.autofilled,emitValue:this.emitValue,language:this.language,"client-styling":this.clientStyling,tooltip:this.tooltip,options:this.options});case"togglecheckbox":return i("toggle-checkbox-input",{name:this.name,displayName:this.displayName,validation:this.validation,defaultValue:this.defaultValue,autofilled:this.autofilled,emitValue:this.emitValue,language:this.language,"client-styling":this.clientStyling,tooltip:this.tooltip,options:this.options,"emit-on-click":this.emitOnClick});case"datetime":return i("date-input",{name:this.name,displayName:this.displayName,validation:this.validation,defaultValue:this.defaultValue,autofilled:this.autofilled,emitValue:this.emitValue,language:this.language,"client-styling":this.clientStyling,tooltip:this.tooltip,placeholder:this.placeholder,dateFormat:this.dateFormat,"emit-on-click":this.emitOnClick});case"password":return i("password-input",{name:this.name,displayName:this.displayName,validation:this.validation,defaultValue:this.defaultValue,autofilled:this.autofilled,emitValue:this.emitValue,language:this.language,isDuplicateInput:this.isDuplicateInput,hidePasswordComplexity:this.hidePasswordComplexity,"client-styling":this.clientStyling,tooltip:this.tooltip,placeholder:this.placeholder});case"radio":return i("radio-input",{name:this.name,displayName:this.displayName,optionsGroup:this.options,validation:this.validation,emitValue:this.emitValue,language:this.language,"client-styling":this.clientStyling});case"tel":return i("tel-input",{name:this.name,action:this.action,displayName:this.displayName,validation:this.validation,defaultValue:this.defaultValue,emitValue:this.emitValue,language:this.language,autofilled:this.autofilled,"client-styling":this.clientStyling,tooltip:this.tooltip,placeholder:this.placeholder});case"dropdown":return i("select-input",{name:this.name,action:this.action,defaultValue:this.defaultValue,displayName:this.displayName,options:this.options,validation:this.validation,emitValue:this.emitValue,autofilled:this.autofilled,language:this.language,"client-styling":this.clientStyling,tooltip:this.tooltip,placeholder:this.placeholder});case"twofa":return i("twofa-input",{name:this.name,displayName:this.displayName,validation:this.validation,emitValue:this.emitValue,language:this.language,"client-styling":this.clientStyling,tooltip:this.tooltip,destination:this.twofaDestination,"resend-interval-seconds":this.twofaResendIntervalSeconds});default:return i("p",null,"The ",this.type," input type is not valid")}}render(){return i(o,{key:"575526a74f8739d530e0094238357e2a744cc463",class:`general-input--${this.name}`,onClick:this.handleClick},this.renderInput())}};Gp.style=":host{display:block;height:100%}";const Yp=class{constructor(i){t(this,i),this.sendValidityState=e(this,"sendValidityState",7),this.sendInputValue=e(this,"sendInputValue",7),this.validationPattern="",this.touched=!1,this.handleInput=t=>{this.value=t.target.value,this.touched=!0,this.debounceTime&&clearTimeout(this.debounceTime),this.debounceTime=setTimeout((()=>{this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage(),this.emitValueHandler(!0)}),500)},this.handleBlur=()=>{this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage(),this.touched=!0},this.setClientStyling=()=>{let t=document.createElement("style");t.innerHTML=this.clientStyling,this.stylingContainer.prepend(t)},this.name=void 0,this.displayName=void 0,this.placeholder=void 0,this.validation=void 0,this.defaultValue=void 0,this.autofilled=void 0,this.tooltip=void 0,this.language=void 0,this.emitValue=void 0,this.clientStyling="",this.errorMessage=void 0,this.isValid=void 0,this.limitStylingAppends=!1,this.showTooltip=!1}handleStylingChange(t,e){t!==e&&this.setClientStyling()}validityChanged(){this.validityStateHandler({valid:this.isValid,name:this.name}),1==this.emitValue&&this.valueHandler({name:this.name,value:this.value})}validityStateHandler(t){this.sendValidityState.emit(t)}emitValueHandler(t){1==t&&this.isValid&&this.valueHandler({name:this.name,value:this.value})}valueHandler(t){this.sendInputValue.emit(t)}handleClickOutside(t){t.composedPath()[0]!==this.tooltipIconReference&&t.composedPath()[0]!==this.tooltipReference&&(this.showTooltip=!1)}connectedCallback(){this.validationPattern=this.setPattern()}componentDidRender(){!this.limitStylingAppends&&this.stylingContainer&&(this.clientStyling&&this.setClientStyling(),this.limitStylingAppends=!0)}componentDidLoad(){this.isValid=this.setValidity(),this.defaultValue&&(this.value=this.defaultValue,this.valueHandler({name:this.name,value:this.value}))}setValidity(){return this.inputReference.validity.valid}setPattern(){var t,e;if((null===(t=this.validation.custom)||void 0===t?void 0:t.length)>0)return null===(e=this.validation.custom.find((t=>"regex"===t.rule)))||void 0===e?void 0:e.pattern}setErrorMessage(){var t,e;if(this.inputReference.validity.valueMissing)return n("requiredError",this.language);if(this.inputReference.validity.rangeUnderflow||this.inputReference.validity.rangeOverflow)return n("numberLengthError",this.language,{values:{min:this.validation.min,max:this.validation.max}});if(this.inputReference.validity.patternMismatch){const i=null===(t=this.validation.custom.find((t=>"regex"===t.rule)))||void 0===t?void 0:t.errorKey,s=null===(e=this.validation.custom.find((t=>"regex"===t.rule)))||void 0===e?void 0:e.errorMessage;return n(`${i}`,this.language)?n(`${i}`,this.language):s}}renderTooltip(){return this.showTooltip?i("div",{class:"number__tooltip "+(this.showTooltip?"visible":""),ref:t=>this.tooltipReference=t,innerHTML:this.tooltip}):null}render(){let t="";return this.touched&&(t=1==this.isValid||null==this.isValid?"":"text__input--invalid"),i("div",{key:"a6e6a37c0b82e75bc66e26b104f343178deb8b81",class:`number__wrapper ${this.autofilled?"number__wrapper--autofilled":""} ${this.name}__input`,ref:t=>this.stylingContainer=t},i("div",{key:"41d8e03f598ccab9d175dacc27ede808ec017717",class:"number__wrapper--flex"},i("label",{key:"e2eb89c31bdc2c7e7e80546ea5844bb13d34c759",class:"number__label "+(this.validation.mandatory?"number__label--required":""),htmlFor:`${this.name}__input`},this.displayName),i("div",{key:"91de685f2da7b9ba3ddaf48a978f5e95a40594be",class:"number__wrapper--relative"},this.tooltip&&i("img",{key:"737d9ad4e1c74a03b140d48988e688a1898f9e57",class:"number__tooltip-icon",src:a,alt:"",ref:t=>this.tooltipIconReference=t,onClick:()=>this.showTooltip=!this.showTooltip}),this.renderTooltip())),i("input",{key:"58d140746eaaf09aca69c5c4d698983c853e5b5f",ref:t=>this.inputReference=t,type:"number",value:this.defaultValue,readOnly:this.autofilled,id:`${this.name}__input`,class:`number__input ${t}`,pattern:this.validationPattern,placeholder:`${this.placeholder}`,required:this.validation.mandatory,max:this.validation.max,min:this.validation.min,onInput:this.handleInput,onBlur:this.handleBlur}),i("small",{key:"74bda2b23c57d2ca88613c00e4d6ed63ea86daad",class:"number__error-message"},this.errorMessage))}static get watchers(){return{clientStyling:["handleStylingChange"],isValid:["validityChanged"],emitValue:["emitValueHandler"]}}};Yp.style='*,*::before,*::after{padding:0;margin:0;box-sizing:border-box}.number{font-family:"Roboto";font-style:normal}.number__wrapper{position:relative;width:100%}.number__wrapper--autofilled{pointer-events:none}.number__wrapper--autofilled .number__label{color:var(--emw--registration-typography, var(--emw--color-black, #000000))}.number__wrapper--autofilled .number__input{color:var(--emw--color-black, #000000)}.number__wrapper--flex{display:flex;gap:5px}.number__wrapper--relative{position:relative}.number__label{font-family:inherit;font-style:normal;font-weight:500;font-size:16px;line-height:20px;color:var(--emw--registration-typography, var(--emw--color-black, #000000))}.number__label--required::after{content:"*";font-family:inherit;color:var(--emw--login-color-primary, var(--emw--color-primary, #22B04E));margin-left:2px}.number__input{font-family:inherit;border-radius:5px;width:100%;height:44px;border:1px solid var(--emw--color-gray-100, #E6E6E6);color:var(--emw--color-black, #000000);border-radius:5px;box-sizing:border-box;padding:5px 15px;font-size:16px;line-height:18px;position:relative;-moz-appearance:textfield;}.number__input:focus{outline-color:#3E3E3E}.number__input::-webkit-outer-spin-button,.number__input::-webkit-inner-spin-button{-webkit-appearance:none;margin:0}.number__input--invalid{border:1px solid var(--emw--color-error, var(--emw--color-red, #ed0909))}.number__input::placeholder{color:#979797}.number__error-message{position:absolute;top:calc(100% + 5px);left:0;color:var(--emw--color-error, var(--emw--color-red, #ed0909))}.number__tooltip-icon{width:16px;height:auto}.number__tooltip{position:absolute;top:0;left:20px;background-color:var(--emw--color-white, #FFFFFF);border:1px solid var(--emw--color-gray-100, #E6E6E6);color:var(--emw--registration-typography, var(--emw--color-black, #000000));padding:10px;border-radius:5px;opacity:0;transition:opacity 0.3s ease-in-out;z-index:10}.number__tooltip.visible{opacity:1}';const Up=class{constructor(i){t(this,i),this.sendOriginalValidityState=e(this,"sendOriginalValidityState",7),this.sendValidityState=e(this,"sendValidityState",7),this.sendInputValue=e(this,"sendInputValue",7),this.touched=!1,this.originalValid=!1,this.validationPattern="",this.duplicateInputValue=null,this.handleInput=t=>{this.value=t.target.value,this.calculateComplexity(this.value),this.showPopup=!0,this.touched=!0,this.debounceTime&&clearTimeout(this.debounceTime),this.debounceTime=setTimeout((()=>{this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage(),this.emitValueHandler(!0)}),500)},this.handleRevealField=t=>{t.stopPropagation(),window.postMessage({type:`registrationShow${this.name}`},window.location.href)},this.handleBlur=t=>{this.value=t.target.value,this.showPopup=!1,this.touched=!0,this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage()},this.handleFocus=()=>{this.showPopup=!0,this.calculateComplexity(this.value)},this.setClientStyling=()=>{let t=document.createElement("style");t.innerHTML=this.clientStyling,this.stylingContainer.prepend(t)},this.name=void 0,this.displayName=void 0,this.placeholder=void 0,this.defaultValue="",this.autofilled=void 0,this.tooltip=void 0,this.validation=void 0,this.language=void 0,this.emitValue=void 0,this.isDuplicateInput=void 0,this.hidePasswordComplexity=!1,this.clientStyling="",this.isValid=void 0,this.errorMessage=void 0,this.limitStylingAppends=!1,this.showTooltip=!1,this.passwordComplexity=void 0,this.showPopup=void 0,this.value=""}handleStylingChange(t,e){t!==e&&this.setClientStyling()}validityChanged(){this.validityStateHandler({valid:this.isValid,name:this.name}),1==this.emitValue&&this.valueHandler({name:this.name,value:this.value})}valueChanged(){this.isDuplicateInput||(this.calculateComplexity(this.value),this.sendOriginalValidityState.emit({name:this.name,valid:this.setValidity()}))}emitValueHandler(t){1==t&&this.isValid&&this.valueHandler({name:this.name,value:this.value,type:"duplicate"})}validityStateHandler(t){this.sendValidityState.emit(t)}valueHandler(t){this.sendInputValue.emit(t)}originalValidityChangedHandler(t){this.isDuplicateInput&&(t.detail.valid?(this.originalValid=!0,this.isValid=this.setValidity()):(this.originalValid=!1,this.isValid=!1,""!==this.value&&(this.errorMessage=this.setErrorMessage())))}valueChangedHandler(t){this.isDuplicateInput&&this.name===t.detail.name+"Duplicate"&&(this.duplicateInputValue=t.detail.value,this.touched&&(this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage())),this.name===t.detail.name+"Duplicate"&&this.name.replace("Duplicate","")===t.detail.name&&!0===this.touched&&(this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage())}handleClickOutside(t){t.composedPath()[0]!==this.tooltipIconReference&&t.composedPath()[0]!==this.tooltipReference&&(this.showTooltip=!1)}componentDidRender(){!this.limitStylingAppends&&this.stylingContainer&&(this.clientStyling&&this.setClientStyling(),this.limitStylingAppends=!0)}componentDidLoad(){this.inputReference=this.element.shadowRoot.querySelector("input"),this.passwordButton=this.element.shadowRoot.querySelector("vaadin-password-field-button"),this.passwordButton.tabIndex=-1,this.passwordButton.addEventListener("click",(t=>{this.handleRevealField(t)})),this.defaultValue&&(this.value=this.defaultValue,this.calculateComplexity(this.value),this.valueHandler({name:this.name,value:this.value}),this.isDuplicateInput&&(this.duplicateInputValue=this.defaultValue,this.touched=!0)),this.isValid=this.setValidity()}disconnectedCallback(){this.passwordButton.removeEventListener("click",this.handleRevealField)}calculateComplexity(t){this.passwordComplexity=this.validation.custom.filter((t=>"regex"===t.rule)).map((e=>{const i=new RegExp(e.pattern).test(t);return{rule:e.displayName,ruleKey:e.errorKey,passed:i}}))}setValidity(){var t,e;return(!this.isDuplicateInput||this.duplicateInputValue===this.value)&&!!(null===(t=this.passwordComplexity)||void 0===t?void 0:t.every((t=>t.passed)))&&(null===(e=this.inputReference)||void 0===e?void 0:e.validity.valid)}setPattern(){var t,e;if((null===(t=this.validation.custom)||void 0===t?void 0:t.length)>0)return null===(e=this.validation.custom.find((t=>"regex"===t.rule)))||void 0===e?void 0:e.pattern}setErrorMessage(){var t,e,i,s,o;if(this.inputReference.validity.tooShort||this.inputReference.validity.tooLong)return n("lengthError",this.language,{values:{minLength:this.validation.minLength,maxLength:this.validation.maxLength}});if(this.inputReference.validity.valueMissing)return n("requiredError",this.language);if(this.isDuplicateInput&&!this.originalValid)return n("invalidOriginalPasswordError",this.language);if(this.inputReference.validity.patternMismatch){const i=null===(t=this.validation.custom.find((t=>"regex"===t.rule)))||void 0===t?void 0:t.errorKey,s=null===(e=this.validation.custom.find((t=>"regex"===t.rule)))||void 0===e?void 0:e.errorMessage;return n(`${i}`,this.language)?n(`${i}`,this.language):s}if(this.isDuplicateInput&&this.duplicateInputValue!==this.value){const t=null===(i=this.validation.custom.find((t=>"duplicate-input"===t.rule)))||void 0===i?void 0:i.errorKey,e=null===(s=this.validation.custom.find((t=>"duplicate-input"===t.rule)))||void 0===s?void 0:s.errorMessage;return n(`${t}`,this.language)?n(`${t}`,this.language):e}return(null===(o=this.passwordComplexity)||void 0===o?void 0:o.every((t=>t.passed)))||this.showPopup?void 0:n("invalidPassword",this.language)}renderTooltip(){return this.showTooltip?i("div",{class:"password__tooltip "+(this.showTooltip?"visible":""),ref:t=>this.tooltipReference=t,innerHTML:this.tooltip}):null}renderComplexityPopup(){const t=this.passwordComplexity.length,e=this.passwordComplexity.filter((t=>t.passed)).length/t,s=this.passwordComplexity.every((t=>t.passed));return i("div",{class:"password__complexity "+(this.showPopup?"":"password__complexity--hidden")},i("div",{class:"password__complexity--strength"},i("p",{class:"password__complexity--text"},n("passwordStrength",this.language)," ",i("span",{class:"password__complexity--text-bold"},n(s?"passwordStrengthStrong":"passwordStrengthWeak",this.language))),i("meter",{value:e,min:"0",max:"1"})),i("div",null,this.passwordComplexity.map(((t,e)=>i("div",{key:e},i("input",{class:"password__complexity--checkbox",type:"checkbox",checked:t.passed,disabled:!0}),i("span",null,n(`${t.ruleKey}`,this.language)?n(`${t.ruleKey}`,this.language):t.rule))))))}render(){let t="";return this.touched&&(t=1==this.isValid||null==this.isValid?"":"text__input--invalid"),i("div",{key:"c6a672c226569d500598f34c6155279e75fdc79c",class:`password__wrapper ${this.autofilled?"password__wrapper--autofilled":""} ${this.name}__input`,ref:t=>this.stylingContainer=t},i("div",{key:"44b8bee769b7b6ce86797f0f62b6af033bf2d0cd",class:"password__wrapper--flex"},i("label",{key:"b6d573c6a70f26471cea2e576c8286719f58b47f",class:"password__label "+(this.validation.mandatory?"password__label--required":""),htmlFor:`${this.name}__input`},this.displayName),i("div",{key:"76698abedf907fa52940bc8e278fff4aeda1912f",class:"password__wrapper--relative"},this.tooltip&&i("img",{key:"7116b9ed6eb06b6b03c336b6d216d40571b54f55",class:"password__tooltip-icon",src:a,alt:"",ref:t=>this.tooltipIconReference=t,onClick:()=>this.showTooltip=!this.showTooltip}),this.renderTooltip())),i("vaadin-password-field",{key:"b85d0ba5396b3ab6fcf21d1053dba22fdb94c7f9",type:"password",id:`${this.name}__input`,class:`password__input ${t}`,name:this.name,readOnly:this.autofilled,value:this.defaultValue,required:this.validation.mandatory,maxlength:this.validation.maxLength,minlength:this.validation.minLength,pattern:this.validationPattern,placeholder:`${this.placeholder}`,onInput:this.handleInput,onBlur:this.handleBlur,onFocus:this.handleFocus}),i("small",{key:"c30bbcb8e49fcdb1dd8cb41bafd56d64b609be86",class:"password__error-message"},this.errorMessage),this.passwordComplexity&&this.showPopup&&!this.hidePasswordComplexity&&!this.isDuplicateInput&&this.renderComplexityPopup())}get element(){return s(this)}static get watchers(){return{clientStyling:["handleStylingChange"],isValid:["validityChanged"],value:["valueChanged"],emitValue:["emitValueHandler"]}}};Up.style='*,\n*::before,\n*::after {\n padding: 0;\n margin: 0;\n box-sizing: border-box;\n}\n\n.password {\n font-family: "Roboto";\n font-style: normal;\n}\n.password__wrapper {\n position: relative;\n width: 100%;\n display: flex;\n flex-direction: column;\n gap: 5px;\n container-type: inline-size;\n}\n.password__wrapper--autofilled {\n pointer-events: none;\n}\n.password__wrapper--autofilled .password__label {\n color: var(--emw--registration-typography, var(--emw--color-black, #000000));\n}\n.password__wrapper--autofilled .password__input::part(input-field) {\n color: var(--emw--color-black, #000000);\n}\n.password__wrapper--flex {\n display: flex;\n gap: 5px;\n}\n.password__wrapper--relative {\n position: relative;\n}\n.password__label {\n font-family: inherit;\n font-style: normal;\n font-weight: 500;\n font-size: 16px;\n line-height: 20px;\n color: var(--emw--registration-typography, var(--emw--color-black, #000000));\n}\n.password__label--required::after {\n content: "*";\n font-family: inherit;\n color: var(--emw--login-color-primary, var(--emw--color-primary, #22B04E));\n margin-left: 2px;\n}\n.password__input {\n width: inherit;\n border: none;\n}\n.password__input[focused]::part(input-field) {\n border-color: var(--emw--login-color-primary, var(--emw--color-primary, #22B04E));\n}\n.password__input[invalid]::part(input-field) {\n border: 1px solid var(--emw--color-error, var(--emw--color-red, #ed0909));\n}\n.password__input::part(input-field) {\n border-radius: 4px;\n background-color: var(--emw--color-white, #FFFFFF);\n border: 1px solid var(--emw--color-gray-100, #E6E6E6);\n color: var(--emw--color-black, #000000);\n background-color: var(--emw--color-white, #FFFFFF);\n font-family: inherit;\n font-style: normal;\n font-weight: 300;\n font-size: 16px;\n line-height: 1.5;\n position: relative;\n margin-bottom: unset;\n height: 44px;\n padding: 0;\n width: 100%;\n}\n.password__input::part(reveal-button) {\n position: relative;\n right: 10px;\n}\n.password__input::part(reveal-button)::before {\n color: var(--emw--registration-typography, var(--emw--color-black, #000000));\n}\n.password__input > input {\n padding: 5px 15px;\n}\n.password__input > input:placeholder-shown {\n color: var(--emw--color-gray-150, #828282);\n}\n.password__error-message {\n position: absolute;\n top: calc(100% + 5px);\n left: 0;\n color: var(--emw--color-error, var(--emw--color-red, #ed0909));\n}\n.password__complexity {\n height: 150px;\n position: relative;\n padding: 10px;\n display: flex;\n flex-direction: column;\n gap: 20px;\n justify-content: center;\n margin-top: 20px;\n font-weight: 300;\n background: var(--emw--color-white, #FFFFFF);\n -webkit-border-radius: 5px;\n -moz-border-radius: 5px;\n border-radius: 5px;\n border: 1px solid #B0B0B0;\n box-sizing: content-box;\n /* works only in this order */\n}\n.password__complexity meter {\n border-color: transparent; /* Needed for Safari */\n}\n.password__complexity meter[value="1"]::-moz-meter-bar {\n background-color: var(--emw--color-valid, #48952a);\n}\n.password__complexity meter[value="1"]::-webkit-meter-optimum-value {\n background-color: var(--emw--color-valid, #48952a);\n}\n.password__complexity meter:not([value="1"])::-moz-meter-bar {\n background-color: var(--emw--color-error, #FD2839);\n}\n.password__complexity meter:not([value="1"])::-webkit-meter-optimum-value {\n background-color: var(--emw--color-error, #FD2839);\n}\n.password__complexity--strength {\n display: flex;\n justify-content: space-evenly;\n align-items: center;\n}\n.password__complexity--strength meter::-moz-meter-bar { /* Firefox Pseudo Class */\n background: #B0B0B0;\n}\n.password__complexity--hidden {\n display: none;\n}\n.password__complexity--text-bold {\n font-weight: 500;\n}\n.password__complexity--checkbox {\n margin-right: 5px;\n}\n.password__complexity:after {\n content: "";\n position: absolute;\n width: 25px;\n height: 25px;\n border-top: 1px solid var(--emw--color-gray-150, #828282);\n border-right: 0 solid var(--emw--color-gray-150, #828282);\n border-left: 1px solid var(--emw--color-gray-150, #828282);\n border-bottom: 0 solid var(--emw--color-gray-150, #828282);\n bottom: 92%;\n left: 50%;\n margin-left: -25px;\n transform: rotate(45deg);\n margin-top: -25px;\n background-color: var(--emw--color-white, #FFFFFF);\n}\n@container (max-width: 300px) {\n .password__complexity {\n height: 190px;\n }\n .password__complexity:after {\n width: 14px;\n height: 14px;\n bottom: 96%;\n left: 57%;\n }\n}\n.password__tooltip-icon {\n width: 16px;\n height: auto;\n}\n.password__tooltip {\n position: absolute;\n top: 0;\n left: 20px;\n background-color: var(--emw--color-white, #FFFFFF);\n border: 1px solid var(--emw--color-gray-150, #828282);\n color: #2B2D3F;\n padding: 10px;\n border-radius: 5px;\n opacity: 0;\n transition: opacity 0.3s ease-in-out;\n z-index: 10;\n}\n.password__tooltip.visible {\n opacity: 1;\n}';const Kp=class{constructor(i){t(this,i),this.sendInputValue=e(this,"sendInputValue",7),this.sendValidityState=e(this,"sendValidityState",7),this.setClientStyling=()=>{let t=document.createElement("style");t.innerHTML=this.clientStyling,this.stylingContainer.prepend(t)},this.name=void 0,this.displayName=void 0,this.optionsGroup=void 0,this.validation=void 0,this.tooltip=void 0,this.language=void 0,this.emitValue=void 0,this.clientStyling="",this.errorMessage=void 0,this.isValid=void 0,this.limitStylingAppends=!1,this.showTooltip=!1}handleStylingChange(t,e){t!==e&&this.setClientStyling()}validityChanged(){this.validityStateHandler({valid:this.isValid,name:this.name}),1==this.emitValue&&this.valueHandler({name:this.name,value:this.value})}emitValueHandler(t){1==t&&this.isValid&&this.valueHandler({name:this.name,value:this.value})}valueHandler(t){this.sendInputValue.emit(t)}validityStateHandler(t){this.sendValidityState.emit(t)}handleClickOutside(t){t.composedPath()[0]!==this.tooltipIconReference&&t.composedPath()[0]!==this.tooltipReference&&(this.showTooltip=!1)}componentDidRender(){!this.limitStylingAppends&&this.stylingContainer&&(this.clientStyling&&this.setClientStyling(),this.limitStylingAppends=!0)}handleClick(t){this.value=t.target.value,this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage(),this.emitValueHandler(!0)}setValidity(){return this.inputReference.validity.valid}setErrorMessage(){if(this.inputReference.validity.valueMissing)return n("requiredError",this.language)}renderTooltip(){return this.showTooltip?i("div",{class:"radio__tooltip "+(this.showTooltip?"visible":""),ref:t=>this.tooltipReference=t,innerHTML:this.tooltip}):null}render(){return i("fieldset",{key:"7dd3f10103c696ef18202154d5ede9cc10b32d0c",class:`radio__fieldset ${this.name}__input`,ref:t=>this.stylingContainer=t},i("legend",{key:"304af4ecd36e8831c1fc76abfaae1767a1005ae5",class:"radio__legend"},this.displayName,":"),this.optionsGroup.map((t=>i("div",{class:"radio__wrapper"},i("input",{type:"radio",class:"radio__input",id:`${t.label}__input`,ref:t=>this.inputReference=t,value:t.value,name:this.name,required:this.validation.mandatory,onClick:t=>this.handleClick(t)}),i("label",{htmlFor:`${t.label}__input`},t.label)))),i("small",{key:"55bb2cc7060fda4774d337c8a570c78d90912da7",class:"radio__error-message"},this.errorMessage),this.tooltip&&i("img",{key:"b3b7093e2c4b5d6f727f5346562ed3fe274bd431",class:"radio__tooltip-icon",src:a,alt:"",ref:t=>this.tooltipIconReference=t,onClick:()=>this.showTooltip=!this.showTooltip}),this.renderTooltip())}static get watchers(){return{clientStyling:["handleStylingChange"],isValid:["validityChanged"],emitValue:["emitValueHandler"]}}};Kp.style="*,*::before,*::after{padding:0;margin:0;box-sizing:border-box}.radio__fieldset{border:none;position:relative}.radio__wrapper{display:flex;gap:5px}.radio__error-message{position:absolute;top:calc(100% + 5px);left:0;color:var(--emw--color-error, var(--emw--color-red, #ed0909))}.radio__tooltip-icon{position:absolute;right:0;bottom:10px}.radio__tooltip{position:absolute;bottom:35px;right:10px;background-color:var(--emw--color-white, #FFFFFF);border:1px solid var(--emw--color-gray-100, #E6E6E6);color:var(--emw--registration-typography, var(--emw--color-black, #000000));padding:10px;border-radius:5px;opacity:0;transition:opacity 0.3s ease-in-out;z-index:10}.radio__tooltip.visible{opacity:1}";const Qp=class{constructor(i){t(this,i),this.sendValidityState=e(this,"sendValidityState",7),this.sendInputValue=e(this,"sendInputValue",7),this.touched=!1,this.handleComboChange=t=>{this.touched=!0;const e=t.target.value,i=this.options.find((t=>t.value.toLowerCase()===e.toLowerCase()));this.value=i?i.value:e,this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage(),this.emitValueHandler(!0)},this.handleBlur=t=>{const e=t.currentTarget;e.opened||(this.touched=!0,this.value=e.value,this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage(),this.validityStateHandler({valid:this.isValid,name:this.name}))},this.handleSelectChange=t=>{this.touched=!0,this.value=t.target.value,this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage(),this.validityStateHandler({valid:this.isValid,name:this.name}),this.emitValueHandler(!0)},this.setClientStyling=()=>{let t=document.createElement("style");t.innerHTML=this.clientStyling,this.stylingContainer.prepend(t)},this.name=void 0,this.displayName=void 0,this.placeholder=void 0,this.action=void 0,this.defaultValue="",this.autofilled=void 0,this.tooltip=void 0,this.options=[],this.validation=void 0,this.language=void 0,this.emitValue=void 0,this.clientStyling="",this.errorMessage=void 0,this.isValid=void 0,this.limitStylingAppends=!1,this.showTooltip=!1}handleStylingChange(t,e){t!==e&&this.setClientStyling()}validityChanged(){this.validityStateHandler({valid:this.isValid,name:this.name}),1==this.emitValue&&this.valueHandler({name:this.name,value:this.value})}validityStateHandler(t){this.sendValidityState.emit(t)}emitValueHandler(t){1==t&&this.isValid&&this.valueHandler({name:this.name,value:this.value})}valueHandler(t){this.sendInputValue.emit(t)}handleClickOutside(t){t.composedPath()[0]!==this.tooltipIconReference&&t.composedPath()[0]!==this.tooltipReference&&(this.showTooltip=!1)}connectedCallback(){var t;this.displayedOptions=this.options.map((t=>({label:t.label,value:t.value}))),this.isComboBox=(null===(t=this.displayedOptions)||void 0===t?void 0:t.length)>6}componentWillLoad(){if(this.action&&!this.options.length&&"GET"==this.action.split(" ")[0]){const t=this.action.split(" ")[1];return this.getOptions(t).then((t=>{var e;const i=Object.keys(t)[0];this.displayedOptions=t[i].map((t=>({label:t.Name,value:t.Alpha2Code}))),this.isComboBox=(null===(e=this.displayedOptions)||void 0===e?void 0:e.length)>6}))}}componentDidRender(){!this.limitStylingAppends&&this.stylingContainer&&(this.clientStyling&&this.setClientStyling(),this.limitStylingAppends=!0)}componentDidLoad(){if(this.inputReference=this.vaadinCombo.querySelector("input"),this.defaultValue){const t=this.displayedOptions.find((t=>t.value.toUpperCase()===this.defaultValue.toUpperCase()));this.value=t.value,this.valueHandler({name:this.name,value:this.value}),this.inputReference.value=this.value}this.isValid=this.setValidity(),!this.isComboBox&&this.vaadinCombo&&this.vaadinCombo.addEventListener("opened-changed",(t=>{if(!0===t.detail.value)this.errorMessage="";else{const e=t.currentTarget;this.touched=!0,this.value=e.value,this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage(),this.validityStateHandler({valid:this.isValid,name:this.name})}}))}getOptions(t){const e=new URL(t);return new Promise(((t,i)=>{fetch(e.href).then((t=>t.json())).then((e=>{t(e)})).catch((t=>{console.error(t),i(t)}))}))}setValidity(){var t;return!(null===(t=this.validation)||void 0===t?void 0:t.mandatory)||!!this.value}setErrorMessage(){var t,e,i;if((null===(e=null===(t=this.inputReference)||void 0===t?void 0:t.validity)||void 0===e?void 0:e.valueMissing)||(null===(i=this.vaadinCombo)||void 0===i?void 0:i.invalid))return n("requiredError",this.language)}renderTooltip(){return this.showTooltip?i("div",{class:"select__tooltip "+(this.showTooltip?"visible":""),ref:t=>this.tooltipReference=t,innerHTML:this.tooltip}):null}render(){var t,e;let s="";return this.touched&&(s=1==this.isValid||null==this.isValid?"":"text__input--invalid"),i("div",{key:"7e90e23b53a72cda885485ccf4110631cede2b8f",class:`select__wrapper ${this.autofilled?"select__wrapper--autofilled":""} ${this.name}__input`,ref:t=>this.stylingContainer=t},i("div",{key:"9a841ccebeb828fc75ed1f708a4a43d4fc7a193f",class:"select__wrapper--flex"},i("label",{key:"92c70fa56518d6d015d756b693306dab80ab0f57",class:"select__label",htmlFor:`${this.name}__input`},`${this.displayName} ${this.validation.mandatory?"*":""}`),i("div",{key:"cfbeb4b4969adc1f9944eb60291d8f586dcc29db",class:"select__wrapper--relative"},this.tooltip&&i("img",{key:"13a340313095bc653a1741115bae128d538dcf30",class:"select__tooltip-icon",src:a,alt:"",ref:t=>this.tooltipIconReference=t,onClick:()=>this.showTooltip=!this.showTooltip}),this.renderTooltip())),this.isComboBox?i("vaadin-combo-box",{name:this.name,id:`${this.name}__input`,class:`select__input ${s} ${this.autofilled?"select__input--autofilled":""}`,"item-label-path":"label","item-value-path":"value",ref:t=>this.vaadinCombo=t,readOnly:this.autofilled,required:null===(t=this.validation)||void 0===t?void 0:t.mandatory,value:this.value,placeholder:`${this.placeholder}`,items:this.displayedOptions,onChange:this.handleComboChange,onBlur:this.handleBlur}):i("vaadin-select",{name:this.name,popover:!1,id:`${this.name}__input`,class:`select__input ${s} ${this.autofilled?"select__input--autofilled":""}`,"item-label-path":"label","item-value-path":"value",ref:t=>this.vaadinCombo=t,readOnly:this.autofilled,required:null===(e=this.validation)||void 0===e?void 0:e.mandatory,value:this.value,placeholder:`${this.placeholder}`,items:this.displayedOptions,onChange:this.handleSelectChange,"no-vertical-overlap":!0,noVerticalOverlap:!0}),i("small",{key:"6ffb5459f648208106c6bfc8a78f5cf379f7f11b",class:"select__error-message"},this.errorMessage))}static get watchers(){return{clientStyling:["handleStylingChange"],isValid:["validityChanged"],emitValue:["emitValueHandler"]}}};Qp.style='*,*::before,*::after{padding:0;margin:0;box-sizing:border-box}:host{height:100%;--_invalid-hover-highlight:transparent;--vaadin-input-field-invalid-hover-highlight:transparent}vaadin-combo-box>input{background-color:var(--emw--color-white, #FFFFFF);color:var(--emw--registration-typography, var(--emw--color-black, #000000));font-weight:300;font-size:16px;-webkit-font-smoothing:initial;}.select{font-family:"Roboto";font-style:normal}.select__wrapper{position:relative;width:100%;display:flex;flex-direction:column;gap:5px}.select__wrapper--autofilled{pointer-events:none}.select__wrapper--autofilled .select__label{color:var(--emw--registration-typography, var(--emw--color-black, #000000))}.select__wrapper--autofilled .select__input::part(input-field){color:var(--emw--color-black, #000000)}.select__wrapper--flex{display:flex;gap:5px}.select__wrapper--relative{position:relative}.select__label{font-family:inherit;font-style:normal;font-weight:500;font-size:16px;line-height:20px;color:var(--emw--registration-typography, var(--emw--color-black, #000000))}.select__label--required::after{content:"*";font-family:inherit;color:var(--emw--login-color-primary, var(--emw--color-primary, #22B04E));margin-left:2px}.select__input{border:none;width:inherit;position:relative}.select__input[focused]:not(.text__input--invalid)::part(input-field){border-color:var(--emw--login-color-primary, var(--emw--color-primary, #22B04E))}.select__input[invalid]::part(input-field){border:1px solid var(--emw--color-error, var(--emw--color-red, #ed0909))}.select__input vaadin-date-picker-overlay-content>vaadin-button{color:var(--emw--color-black, #000000)}.select__input::part(input-field){border-radius:4px;background-color:var(--emw--color-white, #FFFFFF);border:1px solid var(--emw--color-gray-100, #E6E6E6);color:var(--emw--color-black, #000000);font-family:inherit;font-style:normal;font-size:16px;font-weight:300;line-height:1.5;padding:5px 15px;height:44px}.select__input::part(toggle-button){position:relative;right:10px}.select__error-message{position:absolute;top:calc(100% + 5px);left:0;color:var(--emw--color-error, var(--emw--color-red, #ed0909))}.select__tooltip-icon{width:16px;height:auto}.select__tooltip{position:absolute;top:0;left:20px;background-color:var(--emw--color-white, #FFFFFF);border:1px solid var(--emw--color-gray-100, #E6E6E6);color:var(--emw--registration-typography, var(--emw--color-black, #000000));padding:10px;border-radius:5px;opacity:0;transition:opacity 0.3s ease-in-out;z-index:10}.select__tooltip.visible{opacity:1}';const Jp=class{constructor(i){t(this,i),this.sendValidityState=e(this,"sendValidityState",7),this.sendInputValue=e(this,"sendInputValue",7),this.validationPattern="",this.touched=!1,this.handleInput=t=>{this.phoneValue=t.target.value,this.value={prefix:this.prefixValue,phone:this.phoneValue},this.touched=!0,this.debounceTime&&clearTimeout(this.debounceTime),this.debounceTime=setTimeout((()=>{this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage(),this.emitValueHandler(!0)}),500)},this.handleBlur=()=>{this.touched||(this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage(),this.touched=!0)},this.setClientStyling=()=>{let t=document.createElement("style");t.innerHTML=this.clientStyling,this.stylingContainer.prepend(t)},this.name=void 0,this.displayName=void 0,this.placeholder=void 0,this.showLabels=void 0,this.action=void 0,this.validation=void 0,this.defaultValue=void 0,this.autofilled=void 0,this.tooltip=void 0,this.language=void 0,this.emitValue=void 0,this.clientStyling="",this.isValid=void 0,this.errorMessage=void 0,this.limitStylingAppends=!1,this.showTooltip=!1}handleStylingChange(t,e){t!==e&&this.setClientStyling()}validityChanged(){this.validityStateHandler({valid:this.isValid,name:this.name}),1==this.emitValue&&this.valueHandler({name:this.name,value:this.value,type:"tel"})}validityStateHandler(t){this.sendValidityState.emit(t)}emitValueHandler(t){1==t&&this.isValid&&this.valueHandler({name:this.name,value:this.value,type:"tel"})}valueHandler(t){this.sendInputValue.emit(t)}handleClickOutside(t){t.composedPath()[0]!==this.tooltipIconReference&&t.composedPath()[0]!==this.tooltipReference&&(this.showTooltip=!1)}connectedCallback(){this.validationPattern=this.setPattern(),this.defaultValue&&(this.prefixValue=this.defaultValue.prefix?this.defaultValue.prefix:this.defaultValue,this.phoneValue=this.defaultValue.phone||null)}componentWillLoad(){if(this.action&&"GET"==this.action.split(" ")[0]){const t=this.action.split(" ")[1];return this.getPhoneCodes(t).then((t=>{this.phoneCodesOptions=t.phoneCodes.map((t=>"object"==typeof t&&t.Prefix?{label:t.Prefix,value:t.Prefix}:{label:t,value:t}))}))}}componentDidRender(){!this.limitStylingAppends&&this.stylingContainer&&(this.clientStyling&&this.setClientStyling(),this.limitStylingAppends=!0)}componentDidLoad(){this.isValid=this.setValidity(),this.defaultValue&&(this.value=this.defaultValue,this.valueHandler({name:this.name,value:this.value,type:"tel"}))}getPhoneCodes(t){const e=new URL(t);return new Promise(((t,i)=>{fetch(e.href).then((t=>t.json())).then((e=>{t(e)})).catch((t=>{console.error(t),i(t)}))}))}handlePrefixInput(t){this.prefixValue=t.target.value,this.value={prefix:this.prefixValue,phone:this.phoneValue},this.emitValueHandler(!0)}setValidity(){return this.inputReference.validity.valid}setPattern(){var t,e;if((null===(t=this.validation.custom)||void 0===t?void 0:t.length)>0)return null===(e=this.validation.custom.find((t=>"regex"===t.rule)))||void 0===e?void 0:e.pattern}setErrorMessage(){var t,e;if(this.inputReference.validity.patternMismatch){const i=null===(t=this.validation.custom.find((t=>"regex"===t.rule)))||void 0===t?void 0:t.errorKey,s=null===(e=this.validation.custom.find((t=>"regex"===t.rule)))||void 0===e?void 0:e.errorMessage;return n(`${i}`,this.language)?n(`${i}`,this.language):s}return this.inputReference.validity.tooShort||this.inputReference.validity.tooLong?n("lengthError",this.language,{values:{minLength:this.validation.minLength,maxLength:this.validation.maxLength}}):this.inputReference.validity.valueMissing?n("requiredError",this.language):void 0}renderTooltip(){return this.showTooltip?i("div",{class:"tel__tooltip "+(this.showTooltip?"visible":""),ref:t=>this.tooltipReference=t,innerHTML:this.tooltip}):null}render(){let t="";return this.touched&&(t=1==this.isValid||null==this.isValid?"":"text__input--invalid"),i("div",{key:"07279e9146394ad96ca0ce1b3e059f09fce2937a",class:`tel__wrapper ${this.autofilled?"tel__wrapper--autofilled":""} ${this.name}__input`,ref:t=>this.stylingContainer=t},i("div",{key:"c4eedb1dba6a3fabd4dcc95e767813f95b83346a",class:"tel__wrapper--flex-label"},i("label",{key:"093a445bc6a9144673386abf92263faa2f33a62a",class:"tel__label "+(this.validation.mandatory?"tel__label--required":""),htmlFor:`${this.name}__input`},this.displayName),i("div",{key:"76abd68488a0f78e3fbd46328fa338d8c05b9601",class:"tel__wrapper--relative"},this.tooltip&&i("img",{key:"8238860af5dbc417c2cd853b55fd79f67f51649d",class:"tel__tooltip-icon",src:a,alt:"",ref:t=>this.tooltipIconReference=t,onClick:()=>this.showTooltip=!this.showTooltip}),this.renderTooltip())),i("div",{key:"235b2146fc4c70107d5c077071e1fa52ac1c56d3",class:`tel__wrapper--flex ${t}`},i("vaadin-combo-box",{key:"73e51576aad82c2bc6895a62b0c19351a1eb917b",class:"tel__prefix",items:this.phoneCodesOptions,value:this.prefixValue,readOnly:this.autofilled,onChange:t=>this.handlePrefixInput(t)}),i("input",{key:"d714d757cd08e3d700cec86f9d6ce4ff680dd2e9",type:"tel",ref:t=>this.inputReference=t,id:`${this.name}__input`,readOnly:this.autofilled,class:"tel__input",value:this.phoneValue,placeholder:`${this.placeholder}`,required:this.validation.mandatory,minlength:this.validation.minLength,maxlength:this.validation.maxLength,pattern:this.validationPattern,onInput:this.handleInput,onBlur:this.handleBlur})),i("small",{key:"f6ced1b252990cd3ecc18c9c5ad3546654006dcc",class:"tel__error-message"},this.errorMessage))}static get watchers(){return{clientStyling:["handleStylingChange"],isValid:["validityChanged"],emitValue:["emitValueHandler"]}}};Jp.style='*,*::before,*::after{padding:0;margin:0;box-sizing:border-box}.tel{font-family:"Roboto";font-style:normal}.tel__wrapper{position:relative;width:100%;display:flex;flex-direction:column;gap:5px}.tel__wrapper--autofilled{pointer-events:none}.tel__wrapper--autofilled .tel__label{color:var(--emw--registration-typography, var(--emw--color-black, #000000))}.tel__wrapper--autofilled .tel__input::part(input-field){color:var(--emw--color-black, #000000)}.tel__wrapper--flex{width:inherit;display:flex;align-items:center;border-radius:4px;border:1px solid var(--emw--color-gray-100, #E6E6E6);background-color:var(--emw--color-white, #FFFFFF);overflow:hidden}.tel__wrapper--flex:focus-within{border-color:var(--emw--login-color-primary, var(--emw--color-primary, #22B04E))}.tel__wrapper--flex-label{display:flex;gap:5px}.tel__wrapper--flex--relative{position:relative}.tel__wrapper .text__input--invalid{border:1px solid var(--emw--color-error, var(--emw--color-red, #ed0909))}.tel__label{font-family:inherit;font-style:normal;font-weight:500;font-size:16px;line-height:20px;color:var(--emw--registration-typography, var(--emw--color-black, #000000))}.tel__label--required::after{content:"*";font-family:inherit;color:var(--emw--login-color-primary, var(--emw--color-primary, #22B04E));margin-left:2px}.tel__prefix{--vaadin-field-default-width:90px}.tel__prefix[focus]{outline:none}.tel__prefix::part(input-field){border-radius:0 5px 5px 0;background-color:var(--emw--color-white, #FFFFFF);color:var(--emw--color-black, #000000);font-family:inherit;font-style:normal;font-weight:300;font-size:16px;line-height:1.5;border:none;border-right:2px solid #DDE0EE;border-image-source:linear-gradient(to bottom, rgba(221, 224, 238, 0) 25%, rgb(221, 224, 238) 25%, rgb(221, 224, 238) 75%, rgba(221, 224, 238, 0) 75%);border-image-slice:1;border-image-repeat:round}.tel__prefix::part(input-field):hover{background-color:var(--emw--color-white, #FFFFFF)}.tel__prefix::part(toggle-button){color:var(--emw--registration-typography, var(--emw--color-black, #000000))}.tel__input{font-family:inherit;border-radius:5px;width:100%;color:var(--emw--registration-typography, var(--emw--color-black, #000000));background-color:var(--emw--color-white, #FFFFFF);border:none;width:inherit;position:relative;font-size:16px;font-weight:300;line-height:1.5;padding:5px 15px;height:42px;-moz-appearance:textfield;}.tel__input:focus{outline:none}.tel__input::-webkit-outer-spin-button,.tel__input::-webkit-inner-spin-button{-webkit-appearance:none;margin:0}.tel__input::placeholder{color:var(--emw--color-gray-150, #979797)}.tel__error-message{position:absolute;top:calc(100% + 5px);left:0;color:var(--emw--color-error, var(--emw--color-red, #ed0909))}.tel__tooltip-icon{width:16px;height:auto}.tel__tooltip{position:absolute;top:0;left:20px;background-color:var(--emw--color-white, #FFFFFF);border:1px solid var(--emw--color-gray-100, #E6E6E6);color:var(--emw--registration-typography, var(--emw--color-black, #000000));padding:10px;border-radius:5px;opacity:0;transition:opacity 0.3s ease-in-out;z-index:10}.tel__tooltip.visible{opacity:1}';const Xp=class{constructor(i){t(this,i),this.sendValidityState=e(this,"sendValidityState",7),this.sendInputValue=e(this,"sendInputValue",7),this.value="",this.validationPattern="",this.duplicateInputValue=null,this.touched=!1,this.handleInput=t=>{this.value=t.target.value,this.touched=!0,this.debounceTime&&clearTimeout(this.debounceTime),this.debounceTime=setTimeout((()=>{this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage(),this.validityStateHandler({valid:this.isValid,name:this.name}),this.emitValueHandler(!0)}),500)},this.handleBlur=t=>{this.value=t.target.value,this.touched=!0,this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage(),this.validityStateHandler({valid:this.isValid,name:this.name})},this.setClientStyling=()=>{let t=document.createElement("style");t.innerHTML=this.clientStyling,this.stylingContainer.prepend(t)},this.name=void 0,this.displayName=void 0,this.placeholder=void 0,this.validation=void 0,this.defaultValue="",this.autofilled=void 0,this.tooltip=void 0,this.language=void 0,this.checkValidity=void 0,this.emitValue=void 0,this.isDuplicateInput=void 0,this.clientStyling="",this.isValid=void 0,this.errorMessage="",this.limitStylingAppends=!1,this.showTooltip=!1}handleStylingChange(t,e){t!==e&&this.setClientStyling()}validityChanged(){this.validityStateHandler({valid:this.isValid,name:this.name}),1==this.emitValue&&this.valueHandler({name:this.name,value:this.value})}emitValueHandler(t){1==t&&this.isValid&&this.valueHandler({name:this.name,value:this.value})}validityStateHandler(t){this.sendValidityState.emit(t)}valueHandler(t){this.sendInputValue.emit(t)}handleClickOutside(t){t.composedPath()[0]!==this.tooltipIconReference&&t.composedPath()[0]!==this.tooltipReference&&(this.showTooltip=!1)}valueChangedHandler(t){this.isDuplicateInput&&this.name===t.detail.name+"Duplicate"&&(this.duplicateInputValue=t.detail.value,this.touched&&(this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage())),this.name===t.detail.name+"Duplicate"&&this.name.replace("Duplicate","")===t.detail.name&&!0===this.touched&&(this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage())}handleValidationChange(t){t.detail.field===this.name&&(this.validation=t.detail.validation,this.validationPattern=this.setPattern(),this.touched&&(this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage()))}connectedCallback(){this.validationPattern=this.setPattern()}componentDidRender(){!this.limitStylingAppends&&this.stylingContainer&&(this.clientStyling&&this.setClientStyling(),this.limitStylingAppends=!0)}componentDidLoad(){this.defaultValue&&(this.value=this.defaultValue,this.valueHandler({name:this.name,value:this.value}),this.isDuplicateInput&&(this.touched=!0)),this.isValid=this.setValidity()}setValidity(){if(this.isDuplicateInput&&this.duplicateInputValue!==this.value)return!1;if(!this.inputReference)return!1;const t=this.inputReference.validity.valid,e=!this.inputReference.value||null!==this.inputReference.value.match(this.validationPattern);return t&&e}setPattern(){var t,e;if((null===(t=this.validation.custom)||void 0===t?void 0:t.length)>0)return null===(e=this.validation.custom.find((t=>"regex"===t.rule)))||void 0===e?void 0:e.pattern}setErrorMessage(){var t,e,i,s;if(this.inputReference.validity.valueMissing)return n("requiredError",this.language);if(this.inputReference.validity.tooShort||this.inputReference.validity.tooLong)return n("lengthError",this.language,{values:{minLength:this.validation.minLength,maxLength:this.validation.maxLength}});if(null==this.inputReference.value.match(this.validationPattern)){const i=null===(t=this.validation.custom.find((t=>"regex"===t.rule)))||void 0===t?void 0:t.errorKey,s=null===(e=this.validation.custom.find((t=>"regex"===t.rule)))||void 0===e?void 0:e.errorMessage;return n(`${i}`,this.language)||s}if(this.isDuplicateInput&&this.duplicateInputValue!==this.value){const t=null===(i=this.validation.custom.find((t=>"duplicate-input"===t.rule)))||void 0===i?void 0:i.errorKey,e=null===(s=this.validation.custom.find((t=>"duplicate-input"===t.rule)))||void 0===s?void 0:s.errorMessage;return n(`${t}`,this.language)?n(`${t}`,this.language):e}}renderTooltip(){return this.showTooltip?i("div",{class:"text__tooltip "+(this.showTooltip?"visible":""),ref:t=>this.tooltipReference=t,innerHTML:this.tooltip}):null}render(){let t="";return this.touched&&(t=1==this.isValid||null==this.isValid?"":"text__input--invalid"),i("div",{key:"37c7509b46ab92149c3c11365cf5061bb1bbb01a",class:`text__wrapper ${this.name}__input ${this.autofilled?"text__wrapper--autofilled":""}`,ref:t=>this.stylingContainer=t},i("div",{key:"737873a059749dc050a8efa6ffb09a1b2ee9f95c",class:"text__wrapper--flex"},i("label",{key:"1d921faece6c293c7e3c95d34bedd0d399c7be9e",class:"text__label "+(this.validation.mandatory?"text__label--required":""),htmlFor:`${this.name}__input`},this.displayName),i("div",{key:"e1e59c85912cf7c3dbd1e61bba829ae2b0192a18",class:"text__wrapper--relative"},this.tooltip&&i("img",{key:"73513026eebcc809edef481d5cd7b885e5f20f03",class:"text__tooltip-icon",src:a,alt:"",ref:t=>this.tooltipIconReference=t,onClick:()=>this.showTooltip=!this.showTooltip}),this.renderTooltip())),i("input",{key:"a73e2c2430e6fbc778e1fd6b5fcfb298cf01b5c5",name:this.name,id:`${this.name}__input`,value:this.defaultValue,type:"text",class:`text__input ${t}`,placeholder:`${this.placeholder}`,ref:t=>this.inputReference=t,readOnly:this.autofilled,required:this.validation.mandatory,minlength:this.validation.minLength,maxlength:this.validation.maxLength,onInput:this.handleInput,onBlur:this.handleBlur}),i("small",{key:"11cb376081cb05651c60c3e1ac8a41f9751ca16c",class:"text__error-message"},this.errorMessage))}static get watchers(){return{clientStyling:["handleStylingChange"],isValid:["validityChanged"],emitValue:["emitValueHandler"]}}};Xp.style='*,*::before,*::after{padding:0;margin:0;box-sizing:border-box}.text{font-family:"Roboto";font-style:normal}.text__wrapper{position:relative;width:100%;display:flex;flex-direction:column;gap:5px}.text__wrapper--autofilled{pointer-events:none}.text__wrapper--autofilled .text__label{color:var(--emw--registration-typography, var(--emw--color-black, #000000))}.text__wrapper--autofilled .text__input::part(input-field){color:var(--emw--color-black, #000000)}.text__wrapper--flex{display:flex;gap:5px}.text__wrapper--relative{position:relative}.text__label{font-family:inherit;font-style:normal;font-weight:500;font-size:16px;line-height:20px;color:var(--emw--registration-typography, var(--emw--color-black, #000000))}.text__label--required::after{content:"*";font-family:inherit;color:var(--emw--login-color-primary, var(--emw--color-primary, #22B04E));margin-left:2px}.text__input{font-family:inherit;width:100%;height:44px;border:1px solid var(--emw--color-gray-100, #E6E6E6);background-color:var(--emw--color-white, #FFFFFF);color:var(--emw--color-black, #000000);border-radius:5px;font-size:16px;font-weight:300;line-height:1.5;padding:5px 15px}.text__input:focus{border:1px solid var(--emw--login-color-primary, var(--emw--color-primary, #22B04E))}.text__input--invalid{border:1px solid var(--emw--color-error, var(--emw--color-red, #ed0909))}.text__input::placeholder{color:var(--emw--color-gray-150, #828282)}.text__error-message{position:absolute;top:calc(100% + 5px);left:0;color:var(--emw--color-error, var(--emw--color-red, #ed0909))}.text__tooltip-icon{width:16px;height:auto}.text__tooltip{position:absolute;top:0;left:20px;background-color:var(--emw--color-white, #FFFFFF);border:1px solid var(--emw--color-gray-100, #E6E6E6);color:var(--emw--registration-typography, var(--emw--color-black, #000000));padding:10px;border-radius:5px;opacity:0;transition:opacity 0.3s ease-in-out;z-index:10}.text__tooltip.visible{opacity:1}';const Zp=class{constructor(i){t(this,i),this.sendValidityState=e(this,"sendValidityState",7),this.sendInputValue=e(this,"sendInputValue",7),this.callBackObject={},this.subFieldsObject={},this.value="",this.handleRevealField=(t,e)=>{t.stopPropagation(),window.postMessage({type:`registration${e}Clicked`},window.location.href)},this.setClientStyling=()=>{let t=document.createElement("style");t.innerHTML=this.clientStyling,this.stylingContainer.prepend(t)},this.name=void 0,this.displayName=void 0,this.defaultValue="",this.options=void 0,this.autofilled=void 0,this.tooltip=void 0,this.validation=void 0,this.language=void 0,this.emitValue=void 0,this.clientStyling="",this.errorMessage=void 0,this.isValid=void 0,this.limitStylingAppends=!1,this.showTooltip=!1,this.showFields="true"===this.defaultValue}handleStylingChange(t,e){t!==e&&this.setClientStyling()}validityStateHandler(t){this.sendValidityState.emit(t)}valueHandler(t){this.sendInputValue.emit(t)}handleClickOutside(t){t.composedPath()[0]!==this.tooltipIconReference&&t.composedPath()[0]!==this.tooltipReference&&(this.showTooltip=!1)}componentDidRender(){!this.limitStylingAppends&&this.stylingContainer&&(this.clientStyling&&this.setClientStyling(),this.limitStylingAppends=!0)}componentDidLoad(){0!==this.options.length&&this.options.forEach((t=>{this.callBackObject[t.name]=e=>{this.handleRevealField(e,t.name)},this.subFieldsObject[t.name].addEventListener("click",this.callBackObject[t.name])}))}handleClick(){this.showFields=this.checkboxReference.checked,this.errorMessage=this.setErrorMessage(),this.isValid=this.setValidity(),this.valueHandler({name:this.name,value:this.checkboxReference.checked?"true":"false",type:"toggle"})}setValidity(){return this.checkboxReference.validity.valid}setErrorMessage(){if(this.checkboxReference.validity.valueMissing)return n("requiredError",this.language)}disconnectedCallback(){this.options.forEach((t=>{this.subFieldsObject[t.name].removeEventListener("click",this.callBackObject[t.name])}))}renderLabel(){return i("label",{class:"togglecheckbox__label",htmlFor:`${this.name}__input`},i("div",{class:"togglecheckbox__label-text",innerHTML:`${this.displayName} ${this.validation.mandatory?"*":""}`}))}renderTooltip(){return this.showTooltip?i("div",{class:"togglecheckbox__tooltip "+(this.showTooltip?"visible":""),ref:t=>this.tooltipReference=t,innerHTML:this.tooltip}):null}render(){return i("div",{key:"6315588766319c4ac7a88646b01bc577858ad718",class:`togglecheckbox__wrapper ${this.name}__input`,ref:t=>this.stylingContainer=t},i("div",{key:"20d6999aaf0499b8b840a28dab89242953b4610d",class:"togglecheckbox__wrapper--flex"},i("input",{key:"73b699abf4904e4f2133e30d8dea250c9fe13ac3",class:"togglecheckbox__input",type:"checkbox",id:`${this.name}__input`,ref:t=>this.checkboxReference=t,name:this.name,checked:"true"===this.defaultValue,readOnly:this.autofilled,required:this.validation.mandatory,value:this.value,onClick:()=>this.handleClick()}),this.renderLabel()),i("small",{key:"4d10247f1dae300d0f5133accdd544a90fa4d5a7",class:"togglecheckbox__error-message"},this.errorMessage),i("div",{key:"9c95cef35e58875b96710d3b64b9af1be27204c5",class:"togglecheckbox__wrapper--relative"},this.tooltip&&i("img",{key:"9774edae6bad4715fd20798a7be25eb71c3c4cf0",class:"togglecheckbox__tooltip-icon",src:a,alt:"",ref:t=>this.tooltipIconReference=t,onClick:()=>this.showTooltip=!this.showTooltip}),this.renderTooltip()),i("div",{key:"70ad3ec894a32439e2dcea617e2a5b773c5456b1",class:"togglecheckbox__fields-wrapper "+(this.showFields?"":"hidden")},this.options.map((t=>i("general-input",{type:t.inputType,name:t.name,displayName:t.displayName,validation:t.validate,action:t.action||null,defaultValue:t.defaultValue,autofilled:t.autofill,emitValue:this.emitValue,language:this.language,"client-styling":this.clientStyling,tooltip:t.tooltip,placeholder:null==t.placeholder?"":t.placeholder,ref:e=>this.subFieldsObject[t.name]=e})))))}static get watchers(){return{clientStyling:["handleStylingChange"]}}};Zp.style='*,*::before,*::after{padding:0;margin:0;box-sizing:border-box}.togglecheckbox{font-family:"Roboto";font-style:normal;font-size:15px}.togglecheckbox__wrapper{position:relative}.togglecheckbox__wrapper--flex{display:flex;gap:10px;align-items:baseline}.togglecheckbox__wrapper--relative{position:relative;display:inline}.togglecheckbox__input{transform:scale(1.307, 1.307);margin-left:2px;accent-color:var(--emw--login-color-primary, var(--emw--color-primary, #22B04E))}.togglecheckbox__label{font-style:inherit;font-family:inherit;font-weight:400;font-size:16px;color:var(--emw--registration-typography, var(--emw--color-black, #000000));line-height:1.5;cursor:pointer;padding:0}.togglecheckbox__label-text{font-size:16px}.togglecheckbox__label a{color:var(--emw--login-color-primary, var(--emw--color-primary, #22B04E))}.togglecheckbox__error-message{position:absolute;top:calc(100% + 5px);left:0;color:var(--emw--color-error, var(--emw--color-red, #ed0909))}.togglecheckbox__tooltip-icon{width:16px;height:auto}.togglecheckbox__tooltip{position:absolute;top:0;right:0;background-color:var(--emw--color-white, #FFFFFF);border:1px solid var(--emw--color-gray-100, #E6E6E6);color:var(--emw--registration-typography, var(--emw--color-black, #000000));padding:10px;border-radius:5px;opacity:0;transition:opacity 0.3s ease-in-out;z-index:10}.togglecheckbox__tooltip.visible{opacity:1}.togglecheckbox__fields-wrapper{margin-top:40px;display:flex;flex-direction:column;gap:40px}.hidden{display:none}';const tm=class{constructor(i){t(this,i),this.sendValidityState=e(this,"sendValidityState",7),this.sendInputValue=e(this,"sendInputValue",7),this.resendCode=e(this,"resendCode",7),this.validationPattern="",this.stylingContainer=null,this.tooltipReference=null,this.tooltipIconReference=null,this.inputRefs=[],this.containerRef=null,this.resendInterval=null,this.resendCodeHandler=()=>{this.triggerResendInterval(),this.resendCode.emit()},this.setInputRef=(t,e)=>{t&&(this.inputRefs[e]=t)},this.setContainerRef=t=>{t&&(this.containerRef=t)},this.triggerResendInterval=()=>{this.isResendButtonAvailable=!1,this.resendInterval&&clearInterval(this.resendInterval),this.resendInterval=setInterval((()=>{--this.resendIntervalSecondsLeft<=0&&(clearInterval(this.resendInterval),this.resendIntervalSecondsLeft=this.resendIntervalSeconds,this.isResendButtonAvailable=!0)}),1e3)},this.formatTime=()=>{const t=String(Math.floor(this.resendIntervalSecondsLeft/60));let e=String(this.resendIntervalSecondsLeft%60);return 1===e.length&&(e="0"+e),`${t}:${e}`},this.handleInput=(t,e)=>{const i=t.target,s=i.value;if(i.value=s.charAt(s.length>1?1:0),!s)return;this.code[e]=i.value;const o=this.inputRefs[e+1];o&&o.focus(),this.setValidity(),this.setErrorMessage()},this.setClientStyling=()=>{let t=document.createElement("style");t.innerHTML=this.clientStyling,this.stylingContainer.prepend(t)},this.name="",this.displayName="",this.placeholder="",this.validation=void 0,this.tooltip="",this.language="en",this.emitValue=!0,this.destination="",this.resendIntervalSeconds=60,this.clientStyling="",this.limitStylingAppends=!1,this.isValid=!1,this.isResendButtonAvailable=!0,this.showTooltip=!1,this.errorMessage="",this.code=[],this.resendIntervalSecondsLeft=this.resendIntervalSeconds}handleStylingChange(t,e){t!==e&&this.setClientStyling()}validityChanged(){this.validityStateHandler({valid:this.isValid,name:this.name}),1==this.emitValue&&this.valueHandler({name:this.name,value:this.code.join("")})}emitValueHandler(t){1==t&&this.isValid&&this.valueHandler({name:this.name,value:this.code.join("")})}validityStateHandler(t){this.sendValidityState.emit(t)}valueHandler(t){this.sendInputValue.emit(t)}handleClickOutside(t){t.composedPath()[0]!==this.tooltipIconReference&&t.composedPath()[0]!==this.tooltipReference&&(this.showTooltip=!1)}connectedCallback(){this.validationPattern=this.setPattern(),this.code=new Array(this.validation.maxLength).fill("")}componentDidRender(){!this.limitStylingAppends&&this.stylingContainer&&(this.clientStyling&&this.setClientStyling(),this.limitStylingAppends=!0)}componentDidLoad(){this.setValidity()}handleKeyDown(t,e){if("Backspace"===t.key){this.code[e]="",this.inputRefs[e]&&(this.inputRefs[e].value="");const t=this.inputRefs[e-1];t&&(null==t||t.focus())}this.setValidity(),this.setErrorMessage()}handlePaste(t){var e;t.preventDefault();const i=null===(e=t.clipboardData)||void 0===e?void 0:e.getData("text").trim();if(!i)return;const s=i.slice(0,this.validation.maxLength).split("");this.code=[...s,...new Array(this.validation.maxLength-s.length).fill("")],s.forEach(((t,e)=>{this.inputRefs[e].value=t}));const o=this.inputRefs[Math.min(s.length,this.inputRefs.length-1)];o&&o.focus(),this.setValidity(),this.setErrorMessage()}setValidity(){const t=this.code.join(""),e=t.length===this.validation.maxLength,i=null!==t.match(this.validationPattern);this.isValid=e&&i}setPattern(){var t,e;if((null===(t=this.validation.custom)||void 0===t?void 0:t.length)>0)return null===(e=this.validation.custom.find((t=>"regex"===t.rule)))||void 0===e?void 0:e.pattern}setErrorMessage(){var t;if(null!==this.code.join("").match(this.validationPattern))this.errorMessage="";else{const e=null===(t=this.validation.custom.find((t=>"regex"===t.rule)))||void 0===t?void 0:t.errorKey;e&&(this.errorMessage=n(e,this.language))}}renderTooltip(){return this.showTooltip?i("div",{class:"text__tooltip "+(this.showTooltip?"visible":""),ref:t=>this.tooltipReference=t,innerHTML:this.tooltip}):null}render(){return i("div",{key:"97c1955fececc6f3998375f4c8176ceaed66856a",class:"twofa"},i("div",{key:"ee2243931d8e5c6a5aadf1e78d1851449806d2b2",class:"twofa__error-message"},i("p",{key:"20a8ccad2e6501c73e3672f6ae325f8539e2d21a"},this.errorMessage)),i("div",{key:"bb33610a8be04b86378026c02099620749b81a4b",class:"twofa__description",innerHTML:n("twofaDescription",this.language,{values:{destination:this.destination}})}),i("div",{key:"af3ea38ed6468eb2de66aed810ba50a850bf21a9",class:"twofa__input-wrapper",ref:this.setContainerRef},this.code.map(((t,e)=>i("input",{key:e,ref:t=>this.setInputRef(t,e),id:`otp-input-${e}`,type:"text",maxLength:2,value:t,onInput:t=>this.handleInput(t,e),onKeyDown:t=>this.handleKeyDown(t,e),onPaste:t=>this.handlePaste(t)})))),i("div",{key:"f385bd6dc93896d918a5cc1365b59bedd47d5bb0",class:"twofa__button-wrapper"},i("p",{key:"3623f0391e0e5923cd6b3bfd74d203905486209f",class:"twofa__resend-message"},n("twofaResendMessage",this.language)),i("button",{key:"497660604f87dbf4ce1ce51ecd041e82ab5dd33a",class:"twofa__resend-button",onClick:this.resendCodeHandler,disabled:!this.isResendButtonAvailable},this.isResendButtonAvailable?n("twofaResendButton",this.language):this.formatTime())))}static get watchers(){return{clientStyling:["handleStylingChange"],isValid:["validityChanged"],emitValue:["emitValueHandler"]}}};tm.style="*,*::before,*::after{padding:0;margin:0;box-sizing:border-box}.twofa{display:flex;flex-direction:column;gap:10px}.twofa__description{display:flex;flex-direction:column;gap:10px;align-items:center;justify-content:center}.twofa__error-message{text-align:center;color:var(--emw--color-error, var(--emw--color-red, #ed0909))}.twofa__input-wrapper{display:flex;justify-content:center}.twofa__input-wrapper input{width:35px;height:35px;padding:10px;text-align:center;border-radius:var(--emw--border-radius-small, 5px);margin-left:5px;margin-right:5px;border:2px solid var(--emw--otp-border-color, #55525c);font-weight:var(--emw-font-weight-bold, 800);outline:none;transition:all 0.1s}.twofa__input-wrapper input:focus{border:2px solid var(--emw--color-primary, #22B04E);box-shadow:0 0 2px 2px var(--emw--color-primary, #22B04E)}.twofa__button-wrapper{justify-content:center;text-align:center}.twofa__button-wrapper button{border:none;background:none;font-weight:var(--emw-font-weight-bold, 800);color:var(--emw--color-primary, #22B04E);cursor:pointer}";export{l as checkbox_group_input,h as checkbox_input,Ke as date_input,Qe as email_input,Gp as general_input,Yp as number_input,Up as password_input,Kp as radio_input,Qp as select_input,Jp as tel_input,Xp as text_input,Zp as toggle_checkbox_input,tm as twofa_input}
|
|
7975
|
+
`}static get is(){return"vaadin-confirm-dialog"}ready(){super.ready(),this._overlayElement=this.$.dialog.$.overlay,this._initOverlay(this._overlayElement)}}li(Wp);const Gp=class{constructor(e){t(this,e),this.handleClick=t=>{this.emitOnClick&&(t.stopPropagation(),window.postMessage({type:`registration${this.name}Clicked`},window.location.href))},this.type="text",this.name=void 0,this.displayName=void 0,this.placeholder=void 0,this.action=void 0,this.validation=void 0,this.options=void 0,this.language=void 0,this.autofilled=void 0,this.tooltip=void 0,this.defaultValue=void 0,this.emitValue=void 0,this.isDuplicateInput=void 0,this.hidePasswordComplexity=!1,this.noValidation=!1,this.clientStyling="",this.dateFormat=void 0,this.translationUrl="",this.emitOnClick=!1,this.twofaDestination=void 0,this.twofaResendIntervalSeconds=60}connectedCallback(){var t;this.translationUrl&&(t=this.translationUrl,new Promise((e=>{fetch(t).then((t=>t.json())).then((t=>{Object.keys(t).forEach((e=>{for(let i in t[e])r[e][i]=t[e][i]})),e(!0)}))})))}renderInput(){var t;switch(null===(t=this.type)||void 0===t?void 0:t.toLowerCase()){case"text":return i("text-input",{name:this.name,displayName:this.displayName,validation:this.validation,defaultValue:this.defaultValue,autofilled:this.autofilled,emitValue:this.emitValue,language:this.language,isDuplicateInput:this.isDuplicateInput,"client-styling":this.clientStyling,tooltip:this.tooltip,placeholder:this.placeholder});case"email":return i("email-input",{name:this.name,displayName:this.displayName,validation:this.validation,defaultValue:this.defaultValue,autofilled:this.autofilled,emitValue:this.emitValue,language:this.language,isDuplicateInput:this.isDuplicateInput,"client-styling":this.clientStyling,tooltip:this.tooltip,placeholder:this.placeholder});case"number":return i("number-input",{name:this.name,displayName:this.displayName,validation:this.validation,defaultValue:this.defaultValue,autofilled:this.autofilled,emitValue:this.emitValue,language:this.language,"client-styling":this.clientStyling,tooltip:this.tooltip,placeholder:this.placeholder});case"checkbox":return i("checkbox-input",{name:this.name,displayName:this.displayName,validation:this.validation,emitValue:this.emitValue,defaultValue:this.defaultValue,autofilled:this.autofilled,language:this.language,"client-styling":this.clientStyling,tooltip:this.tooltip});case"checkboxgroup":return i("checkbox-group-input",{name:this.name,displayName:this.displayName,validation:this.validation,defaultValue:this.defaultValue,autofilled:this.autofilled,emitValue:this.emitValue,language:this.language,"client-styling":this.clientStyling,tooltip:this.tooltip,options:this.options});case"togglecheckbox":return i("toggle-checkbox-input",{name:this.name,displayName:this.displayName,validation:this.validation,defaultValue:this.defaultValue,autofilled:this.autofilled,emitValue:this.emitValue,language:this.language,"client-styling":this.clientStyling,tooltip:this.tooltip,options:this.options,"emit-on-click":this.emitOnClick});case"datetime":return i("date-input",{name:this.name,displayName:this.displayName,validation:this.validation,defaultValue:this.defaultValue,autofilled:this.autofilled,emitValue:this.emitValue,language:this.language,"client-styling":this.clientStyling,tooltip:this.tooltip,placeholder:this.placeholder,dateFormat:this.dateFormat,"emit-on-click":this.emitOnClick});case"password":return i("password-input",{name:this.name,displayName:this.displayName,validation:this.validation,defaultValue:this.defaultValue,autofilled:this.autofilled,emitValue:this.emitValue,language:this.language,isDuplicateInput:this.isDuplicateInput,hidePasswordComplexity:this.hidePasswordComplexity,"no-validation":this.noValidation,"client-styling":this.clientStyling,tooltip:this.tooltip,placeholder:this.placeholder});case"radio":return i("radio-input",{name:this.name,displayName:this.displayName,optionsGroup:this.options,validation:this.validation,emitValue:this.emitValue,language:this.language,"client-styling":this.clientStyling});case"tel":return i("tel-input",{name:this.name,action:this.action,displayName:this.displayName,validation:this.validation,defaultValue:this.defaultValue,emitValue:this.emitValue,language:this.language,autofilled:this.autofilled,"client-styling":this.clientStyling,tooltip:this.tooltip,placeholder:this.placeholder});case"dropdown":return i("select-input",{name:this.name,action:this.action,defaultValue:this.defaultValue,displayName:this.displayName,options:this.options,validation:this.validation,emitValue:this.emitValue,autofilled:this.autofilled,language:this.language,"client-styling":this.clientStyling,tooltip:this.tooltip,placeholder:this.placeholder});case"twofa":return i("twofa-input",{name:this.name,displayName:this.displayName,validation:this.validation,emitValue:this.emitValue,language:this.language,"client-styling":this.clientStyling,tooltip:this.tooltip,destination:this.twofaDestination,"resend-interval-seconds":this.twofaResendIntervalSeconds});default:return i("p",null,"The ",this.type," input type is not valid")}}render(){return i(o,{key:"a90dc97926e4f89518fc8520505cf59281840e20",class:`general-input--${this.name}`,onClick:this.handleClick},this.renderInput())}};Gp.style=":host{display:block;height:100%}";const Yp=class{constructor(i){t(this,i),this.sendValidityState=e(this,"sendValidityState",7),this.sendInputValue=e(this,"sendInputValue",7),this.validationPattern="",this.touched=!1,this.handleInput=t=>{this.value=t.target.value,this.touched=!0,this.debounceTime&&clearTimeout(this.debounceTime),this.debounceTime=setTimeout((()=>{this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage(),this.emitValueHandler(!0)}),500)},this.handleBlur=()=>{this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage(),this.touched=!0},this.setClientStyling=()=>{let t=document.createElement("style");t.innerHTML=this.clientStyling,this.stylingContainer.prepend(t)},this.name=void 0,this.displayName=void 0,this.placeholder=void 0,this.validation=void 0,this.defaultValue=void 0,this.autofilled=void 0,this.tooltip=void 0,this.language=void 0,this.emitValue=void 0,this.clientStyling="",this.errorMessage=void 0,this.isValid=void 0,this.limitStylingAppends=!1,this.showTooltip=!1}handleStylingChange(t,e){t!==e&&this.setClientStyling()}validityChanged(){this.validityStateHandler({valid:this.isValid,name:this.name}),1==this.emitValue&&this.valueHandler({name:this.name,value:this.value})}validityStateHandler(t){this.sendValidityState.emit(t)}emitValueHandler(t){1==t&&this.isValid&&this.valueHandler({name:this.name,value:this.value})}valueHandler(t){this.sendInputValue.emit(t)}handleClickOutside(t){t.composedPath()[0]!==this.tooltipIconReference&&t.composedPath()[0]!==this.tooltipReference&&(this.showTooltip=!1)}connectedCallback(){this.validationPattern=this.setPattern()}componentDidRender(){!this.limitStylingAppends&&this.stylingContainer&&(this.clientStyling&&this.setClientStyling(),this.limitStylingAppends=!0)}componentDidLoad(){this.isValid=this.setValidity(),this.defaultValue&&(this.value=this.defaultValue,this.valueHandler({name:this.name,value:this.value}))}setValidity(){return this.inputReference.validity.valid}setPattern(){var t,e;if((null===(t=this.validation.custom)||void 0===t?void 0:t.length)>0)return null===(e=this.validation.custom.find((t=>"regex"===t.rule)))||void 0===e?void 0:e.pattern}setErrorMessage(){var t,e;if(this.inputReference.validity.valueMissing)return n("requiredError",this.language);if(this.inputReference.validity.rangeUnderflow||this.inputReference.validity.rangeOverflow)return n("numberLengthError",this.language,{values:{min:this.validation.min,max:this.validation.max}});if(this.inputReference.validity.patternMismatch){const i=null===(t=this.validation.custom.find((t=>"regex"===t.rule)))||void 0===t?void 0:t.errorKey,s=null===(e=this.validation.custom.find((t=>"regex"===t.rule)))||void 0===e?void 0:e.errorMessage;return n(`${i}`,this.language)?n(`${i}`,this.language):s}}renderTooltip(){return this.showTooltip?i("div",{class:"number__tooltip "+(this.showTooltip?"visible":""),ref:t=>this.tooltipReference=t,innerHTML:this.tooltip}):null}render(){let t="";return this.touched&&(t=1==this.isValid||null==this.isValid?"":"text__input--invalid"),i("div",{key:"a6e6a37c0b82e75bc66e26b104f343178deb8b81",class:`number__wrapper ${this.autofilled?"number__wrapper--autofilled":""} ${this.name}__input`,ref:t=>this.stylingContainer=t},i("div",{key:"41d8e03f598ccab9d175dacc27ede808ec017717",class:"number__wrapper--flex"},i("label",{key:"e2eb89c31bdc2c7e7e80546ea5844bb13d34c759",class:"number__label "+(this.validation.mandatory?"number__label--required":""),htmlFor:`${this.name}__input`},this.displayName),i("div",{key:"91de685f2da7b9ba3ddaf48a978f5e95a40594be",class:"number__wrapper--relative"},this.tooltip&&i("img",{key:"737d9ad4e1c74a03b140d48988e688a1898f9e57",class:"number__tooltip-icon",src:a,alt:"",ref:t=>this.tooltipIconReference=t,onClick:()=>this.showTooltip=!this.showTooltip}),this.renderTooltip())),i("input",{key:"58d140746eaaf09aca69c5c4d698983c853e5b5f",ref:t=>this.inputReference=t,type:"number",value:this.defaultValue,readOnly:this.autofilled,id:`${this.name}__input`,class:`number__input ${t}`,pattern:this.validationPattern,placeholder:`${this.placeholder}`,required:this.validation.mandatory,max:this.validation.max,min:this.validation.min,onInput:this.handleInput,onBlur:this.handleBlur}),i("small",{key:"74bda2b23c57d2ca88613c00e4d6ed63ea86daad",class:"number__error-message"},this.errorMessage))}static get watchers(){return{clientStyling:["handleStylingChange"],isValid:["validityChanged"],emitValue:["emitValueHandler"]}}};Yp.style='*,*::before,*::after{padding:0;margin:0;box-sizing:border-box}.number{font-family:"Roboto";font-style:normal}.number__wrapper{position:relative;width:100%}.number__wrapper--autofilled{pointer-events:none}.number__wrapper--autofilled .number__label{color:var(--emw--registration-typography, var(--emw--color-black, #000000))}.number__wrapper--autofilled .number__input{color:var(--emw--color-black, #000000)}.number__wrapper--flex{display:flex;gap:5px}.number__wrapper--relative{position:relative}.number__label{font-family:inherit;font-style:normal;font-weight:500;font-size:16px;line-height:20px;color:var(--emw--registration-typography, var(--emw--color-black, #000000))}.number__label--required::after{content:"*";font-family:inherit;color:var(--emw--login-color-primary, var(--emw--color-primary, #22B04E));margin-left:2px}.number__input{font-family:inherit;border-radius:5px;width:100%;height:44px;border:1px solid var(--emw--color-gray-100, #E6E6E6);color:var(--emw--color-black, #000000);border-radius:5px;box-sizing:border-box;padding:5px 15px;font-size:16px;line-height:18px;position:relative;-moz-appearance:textfield;}.number__input:focus{outline-color:#3E3E3E}.number__input::-webkit-outer-spin-button,.number__input::-webkit-inner-spin-button{-webkit-appearance:none;margin:0}.number__input--invalid{border:1px solid var(--emw--color-error, var(--emw--color-red, #ed0909))}.number__input::placeholder{color:#979797}.number__error-message{position:absolute;top:calc(100% + 5px);left:0;color:var(--emw--color-error, var(--emw--color-red, #ed0909))}.number__tooltip-icon{width:16px;height:auto}.number__tooltip{position:absolute;top:0;left:20px;background-color:var(--emw--color-white, #FFFFFF);border:1px solid var(--emw--color-gray-100, #E6E6E6);color:var(--emw--registration-typography, var(--emw--color-black, #000000));padding:10px;border-radius:5px;opacity:0;transition:opacity 0.3s ease-in-out;z-index:10}.number__tooltip.visible{opacity:1}';const Up=class{constructor(i){t(this,i),this.sendOriginalValidityState=e(this,"sendOriginalValidityState",7),this.sendValidityState=e(this,"sendValidityState",7),this.sendInputValue=e(this,"sendInputValue",7),this.touched=!1,this.originalValid=!1,this.validationPattern="",this.duplicateInputValue=null,this.handleInput=t=>{this.value=t.target.value,this.calculateComplexity(this.value),this.showPopup=!0,this.touched=!0,this.debounceTime&&clearTimeout(this.debounceTime),this.debounceTime=setTimeout((()=>{this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage(),this.emitValueHandler(!0)}),500)},this.handleRevealField=t=>{t.stopPropagation(),window.postMessage({type:`registrationShow${this.name}`},window.location.href)},this.handleBlur=t=>{this.value=t.target.value,this.showPopup=!1,this.touched=!0,this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage()},this.handleFocus=()=>{this.showPopup=!0,this.calculateComplexity(this.value)},this.setClientStyling=()=>{let t=document.createElement("style");t.innerHTML=this.clientStyling,this.stylingContainer.prepend(t)},this.name=void 0,this.displayName=void 0,this.placeholder=void 0,this.defaultValue="",this.autofilled=void 0,this.tooltip=void 0,this.validation=void 0,this.noValidation=!1,this.language=void 0,this.emitValue=void 0,this.isDuplicateInput=void 0,this.hidePasswordComplexity=!1,this.clientStyling="",this.isValid=void 0,this.errorMessage=void 0,this.limitStylingAppends=!1,this.showTooltip=!1,this.passwordComplexity=void 0,this.showPopup=void 0,this.value=""}handleStylingChange(t,e){t!==e&&this.setClientStyling()}validityChanged(){this.validityStateHandler({valid:this.isValid,name:this.name}),1==this.emitValue&&this.valueHandler({name:this.name,value:this.value})}valueChanged(){this.isDuplicateInput||(this.calculateComplexity(this.value),this.sendOriginalValidityState.emit({name:this.name,valid:this.setValidity()}))}emitValueHandler(t){1==t&&this.isValid&&this.valueHandler({name:this.name,value:this.value,type:"duplicate"})}validityStateHandler(t){this.sendValidityState.emit(t)}valueHandler(t){this.sendInputValue.emit(t)}originalValidityChangedHandler(t){this.isDuplicateInput&&(t.detail.valid?(this.originalValid=!0,this.isValid=this.setValidity()):(this.originalValid=!1,this.isValid=!1,""!==this.value&&(this.errorMessage=this.setErrorMessage())))}valueChangedHandler(t){this.isDuplicateInput&&this.name===t.detail.name+"Duplicate"&&(this.duplicateInputValue=t.detail.value,this.touched&&(this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage())),this.name===t.detail.name+"Duplicate"&&this.name.replace("Duplicate","")===t.detail.name&&!0===this.touched&&(this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage())}handleClickOutside(t){t.composedPath()[0]!==this.tooltipIconReference&&t.composedPath()[0]!==this.tooltipReference&&(this.showTooltip=!1)}componentDidRender(){!this.limitStylingAppends&&this.stylingContainer&&(this.clientStyling&&this.setClientStyling(),this.limitStylingAppends=!0)}componentDidLoad(){this.inputReference=this.element.shadowRoot.querySelector("input"),this.passwordButton=this.element.shadowRoot.querySelector("vaadin-password-field-button"),this.passwordButton.tabIndex=-1,this.passwordButton.addEventListener("click",(t=>{this.handleRevealField(t)})),this.defaultValue&&(this.value=this.defaultValue,this.calculateComplexity(this.value),this.valueHandler({name:this.name,value:this.value}),this.isDuplicateInput&&(this.duplicateInputValue=this.defaultValue,this.touched=!0)),this.isValid=this.setValidity()}disconnectedCallback(){this.passwordButton.removeEventListener("click",this.handleRevealField)}calculateComplexity(t){this.passwordComplexity=this.noValidation?[]:this.validation.custom.filter((t=>"regex"===t.rule)).map((e=>{const i=new RegExp(e.pattern).test(t);return{rule:e.displayName,ruleKey:e.errorKey,passed:i}}))}setValidity(){var t,e;return!!this.noValidation||(!this.isDuplicateInput||this.duplicateInputValue===this.value)&&!!(null===(t=this.passwordComplexity)||void 0===t?void 0:t.every((t=>t.passed)))&&(null===(e=this.inputReference)||void 0===e?void 0:e.validity.valid)}setPattern(){var t,e;if((null===(t=this.validation.custom)||void 0===t?void 0:t.length)>0)return null===(e=this.validation.custom.find((t=>"regex"===t.rule)))||void 0===e?void 0:e.pattern}setErrorMessage(){var t,e,i,s,o;if(this.inputReference.validity.tooShort||this.inputReference.validity.tooLong)return n("lengthError",this.language,{values:{minLength:this.validation.minLength,maxLength:this.validation.maxLength}});if(this.inputReference.validity.valueMissing)return n("requiredError",this.language);if(this.isDuplicateInput&&!this.originalValid)return n("invalidOriginalPasswordError",this.language);if(this.inputReference.validity.patternMismatch){const i=null===(t=this.validation.custom.find((t=>"regex"===t.rule)))||void 0===t?void 0:t.errorKey,s=null===(e=this.validation.custom.find((t=>"regex"===t.rule)))||void 0===e?void 0:e.errorMessage;return n(`${i}`,this.language)?n(`${i}`,this.language):s}if(this.isDuplicateInput&&this.duplicateInputValue!==this.value){const t=null===(i=this.validation.custom.find((t=>"duplicate-input"===t.rule)))||void 0===i?void 0:i.errorKey,e=null===(s=this.validation.custom.find((t=>"duplicate-input"===t.rule)))||void 0===s?void 0:s.errorMessage;return n(`${t}`,this.language)?n(`${t}`,this.language):e}return(null===(o=this.passwordComplexity)||void 0===o?void 0:o.every((t=>t.passed)))||this.showPopup?void 0:n("invalidPassword",this.language)}renderTooltip(){return this.showTooltip?i("div",{class:"password__tooltip "+(this.showTooltip?"visible":""),ref:t=>this.tooltipReference=t,innerHTML:this.tooltip}):null}renderComplexityPopup(){const t=this.passwordComplexity.length,e=this.passwordComplexity.filter((t=>t.passed)).length/t,s=this.passwordComplexity.every((t=>t.passed));return i("div",{class:"password__complexity "+(this.showPopup?"":"password__complexity--hidden")},i("div",{class:"password__complexity--strength"},i("p",{class:"password__complexity--text"},n("passwordStrength",this.language)," ",i("span",{class:"password__complexity--text-bold"},n(s?"passwordStrengthStrong":"passwordStrengthWeak",this.language))),i("meter",{value:e,min:"0",max:"1"})),i("div",null,this.passwordComplexity.map(((t,e)=>i("div",{key:e},i("input",{class:"password__complexity--checkbox",type:"checkbox",checked:t.passed,disabled:!0}),i("span",null,n(`${t.ruleKey}`,this.language)?n(`${t.ruleKey}`,this.language):t.rule))))))}render(){let t="";return this.touched&&(t=1==this.isValid||null==this.isValid?"":"text__input--invalid"),i("div",{key:"813a2ed7f6c68126f985b28912df7c7e21d4557c",class:`password__wrapper ${this.autofilled?"password__wrapper--autofilled":""} ${this.name}__input`,ref:t=>this.stylingContainer=t},i("div",{key:"cf70f74c31ba3e4db31cd618a4a0e4ab11f1bf6e",class:"password__wrapper--flex"},i("label",{key:"73e5c30906f99b796185c77374b35c603723ae35",class:"password__label "+(this.validation.mandatory?"password__label--required":""),htmlFor:`${this.name}__input`},this.displayName),i("div",{key:"3e7f8e757026d350a23198d4e9af516208fde108",class:"password__wrapper--relative"},this.tooltip&&i("img",{key:"58c6c99a779996132eb753db32cafbd2fa1aba8b",class:"password__tooltip-icon",src:a,alt:"",ref:t=>this.tooltipIconReference=t,onClick:()=>this.showTooltip=!this.showTooltip}),this.renderTooltip())),i("vaadin-password-field",{key:"607c8085f8cd2348e7051b8c520bbb3891c555a5",type:"password",id:`${this.name}__input`,class:`password__input ${t}`,name:this.name,readOnly:this.autofilled,value:this.defaultValue,required:this.validation.mandatory,maxlength:this.validation.maxLength,minlength:this.validation.minLength,pattern:this.validationPattern,placeholder:`${this.placeholder}`,onInput:this.handleInput,onBlur:this.handleBlur,onFocus:this.handleFocus}),!this.noValidation&&i("small",{key:"aab21703f01c07eeee72218b6c29604a7d61ea51",class:"password__error-message"},this.errorMessage),this.passwordComplexity&&this.showPopup&&!this.hidePasswordComplexity&&!this.isDuplicateInput&&this.renderComplexityPopup())}get element(){return s(this)}static get watchers(){return{clientStyling:["handleStylingChange"],isValid:["validityChanged"],value:["valueChanged"],emitValue:["emitValueHandler"]}}};Up.style='*,\n*::before,\n*::after {\n padding: 0;\n margin: 0;\n box-sizing: border-box;\n}\n\n.password {\n font-family: "Roboto";\n font-style: normal;\n}\n.password__wrapper {\n position: relative;\n width: 100%;\n display: flex;\n flex-direction: column;\n gap: 5px;\n container-type: inline-size;\n}\n.password__wrapper--autofilled {\n pointer-events: none;\n}\n.password__wrapper--autofilled .password__label {\n color: var(--emw--registration-typography, var(--emw--color-black, #000000));\n}\n.password__wrapper--autofilled .password__input::part(input-field) {\n color: var(--emw--color-black, #000000);\n}\n.password__wrapper--flex {\n display: flex;\n gap: 5px;\n}\n.password__wrapper--relative {\n position: relative;\n}\n.password__label {\n font-family: inherit;\n font-style: normal;\n font-weight: 500;\n font-size: 16px;\n line-height: 20px;\n color: var(--emw--registration-typography, var(--emw--color-black, #000000));\n}\n.password__label--required::after {\n content: "*";\n font-family: inherit;\n color: var(--emw--login-color-primary, var(--emw--color-primary, #22B04E));\n margin-left: 2px;\n}\n.password__input {\n width: inherit;\n border: none;\n}\n.password__input[focused]::part(input-field) {\n border-color: var(--emw--login-color-primary, var(--emw--color-primary, #22B04E));\n}\n.password__input[invalid]::part(input-field) {\n border: 1px solid var(--emw--color-error, var(--emw--color-red, #ed0909));\n}\n.password__input::part(input-field) {\n border-radius: 4px;\n background-color: var(--emw--color-white, #FFFFFF);\n border: 1px solid var(--emw--color-gray-100, #E6E6E6);\n color: var(--emw--color-black, #000000);\n background-color: var(--emw--color-white, #FFFFFF);\n font-family: inherit;\n font-style: normal;\n font-weight: 300;\n font-size: 16px;\n line-height: 1.5;\n position: relative;\n margin-bottom: unset;\n height: 44px;\n padding: 0;\n width: 100%;\n}\n.password__input::part(reveal-button) {\n position: relative;\n right: 10px;\n}\n.password__input::part(reveal-button)::before {\n color: var(--emw--registration-typography, var(--emw--color-black, #000000));\n}\n.password__input > input {\n padding: 5px 15px;\n}\n.password__input > input:placeholder-shown {\n color: var(--emw--color-gray-150, #828282);\n}\n.password__error-message {\n position: absolute;\n top: calc(100% + 5px);\n left: 0;\n color: var(--emw--color-error, var(--emw--color-red, #ed0909));\n}\n.password__complexity {\n height: 150px;\n position: relative;\n padding: 10px;\n display: flex;\n flex-direction: column;\n gap: 20px;\n justify-content: center;\n margin-top: 20px;\n font-weight: 300;\n background: var(--emw--color-white, #FFFFFF);\n -webkit-border-radius: 5px;\n -moz-border-radius: 5px;\n border-radius: 5px;\n border: 1px solid #B0B0B0;\n box-sizing: content-box;\n /* works only in this order */\n}\n.password__complexity meter {\n border-color: transparent; /* Needed for Safari */\n}\n.password__complexity meter[value="1"]::-moz-meter-bar {\n background-color: var(--emw--color-valid, #48952a);\n}\n.password__complexity meter[value="1"]::-webkit-meter-optimum-value {\n background-color: var(--emw--color-valid, #48952a);\n}\n.password__complexity meter:not([value="1"])::-moz-meter-bar {\n background-color: var(--emw--color-error, #FD2839);\n}\n.password__complexity meter:not([value="1"])::-webkit-meter-optimum-value {\n background-color: var(--emw--color-error, #FD2839);\n}\n.password__complexity--strength {\n display: flex;\n justify-content: space-evenly;\n align-items: center;\n}\n.password__complexity--strength meter::-moz-meter-bar { /* Firefox Pseudo Class */\n background: #B0B0B0;\n}\n.password__complexity--hidden {\n display: none;\n}\n.password__complexity--text-bold {\n font-weight: 500;\n}\n.password__complexity--checkbox {\n margin-right: 5px;\n}\n.password__complexity:after {\n content: "";\n position: absolute;\n width: 25px;\n height: 25px;\n border-top: 1px solid var(--emw--color-gray-150, #828282);\n border-right: 0 solid var(--emw--color-gray-150, #828282);\n border-left: 1px solid var(--emw--color-gray-150, #828282);\n border-bottom: 0 solid var(--emw--color-gray-150, #828282);\n bottom: 92%;\n left: 50%;\n margin-left: -25px;\n transform: rotate(45deg);\n margin-top: -25px;\n background-color: var(--emw--color-white, #FFFFFF);\n}\n@container (max-width: 300px) {\n .password__complexity {\n height: 190px;\n }\n .password__complexity:after {\n width: 14px;\n height: 14px;\n bottom: 96%;\n left: 57%;\n }\n}\n.password__tooltip-icon {\n width: 16px;\n height: auto;\n}\n.password__tooltip {\n position: absolute;\n top: 0;\n left: 20px;\n background-color: var(--emw--color-white, #FFFFFF);\n border: 1px solid var(--emw--color-gray-150, #828282);\n color: #2B2D3F;\n padding: 10px;\n border-radius: 5px;\n opacity: 0;\n transition: opacity 0.3s ease-in-out;\n z-index: 10;\n}\n.password__tooltip.visible {\n opacity: 1;\n}';const Kp=class{constructor(i){t(this,i),this.sendInputValue=e(this,"sendInputValue",7),this.sendValidityState=e(this,"sendValidityState",7),this.setClientStyling=()=>{let t=document.createElement("style");t.innerHTML=this.clientStyling,this.stylingContainer.prepend(t)},this.name=void 0,this.displayName=void 0,this.optionsGroup=void 0,this.validation=void 0,this.tooltip=void 0,this.language=void 0,this.emitValue=void 0,this.clientStyling="",this.errorMessage=void 0,this.isValid=void 0,this.limitStylingAppends=!1,this.showTooltip=!1}handleStylingChange(t,e){t!==e&&this.setClientStyling()}validityChanged(){this.validityStateHandler({valid:this.isValid,name:this.name}),1==this.emitValue&&this.valueHandler({name:this.name,value:this.value})}emitValueHandler(t){1==t&&this.isValid&&this.valueHandler({name:this.name,value:this.value})}valueHandler(t){this.sendInputValue.emit(t)}validityStateHandler(t){this.sendValidityState.emit(t)}handleClickOutside(t){t.composedPath()[0]!==this.tooltipIconReference&&t.composedPath()[0]!==this.tooltipReference&&(this.showTooltip=!1)}componentDidRender(){!this.limitStylingAppends&&this.stylingContainer&&(this.clientStyling&&this.setClientStyling(),this.limitStylingAppends=!0)}handleClick(t){this.value=t.target.value,this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage(),this.emitValueHandler(!0)}setValidity(){return this.inputReference.validity.valid}setErrorMessage(){if(this.inputReference.validity.valueMissing)return n("requiredError",this.language)}renderTooltip(){return this.showTooltip?i("div",{class:"radio__tooltip "+(this.showTooltip?"visible":""),ref:t=>this.tooltipReference=t,innerHTML:this.tooltip}):null}render(){return i("fieldset",{key:"7dd3f10103c696ef18202154d5ede9cc10b32d0c",class:`radio__fieldset ${this.name}__input`,ref:t=>this.stylingContainer=t},i("legend",{key:"304af4ecd36e8831c1fc76abfaae1767a1005ae5",class:"radio__legend"},this.displayName,":"),this.optionsGroup.map((t=>i("div",{class:"radio__wrapper"},i("input",{type:"radio",class:"radio__input",id:`${t.label}__input`,ref:t=>this.inputReference=t,value:t.value,name:this.name,required:this.validation.mandatory,onClick:t=>this.handleClick(t)}),i("label",{htmlFor:`${t.label}__input`},t.label)))),i("small",{key:"55bb2cc7060fda4774d337c8a570c78d90912da7",class:"radio__error-message"},this.errorMessage),this.tooltip&&i("img",{key:"b3b7093e2c4b5d6f727f5346562ed3fe274bd431",class:"radio__tooltip-icon",src:a,alt:"",ref:t=>this.tooltipIconReference=t,onClick:()=>this.showTooltip=!this.showTooltip}),this.renderTooltip())}static get watchers(){return{clientStyling:["handleStylingChange"],isValid:["validityChanged"],emitValue:["emitValueHandler"]}}};Kp.style="*,*::before,*::after{padding:0;margin:0;box-sizing:border-box}.radio__fieldset{border:none;position:relative}.radio__wrapper{display:flex;gap:5px}.radio__error-message{position:absolute;top:calc(100% + 5px);left:0;color:var(--emw--color-error, var(--emw--color-red, #ed0909))}.radio__tooltip-icon{position:absolute;right:0;bottom:10px}.radio__tooltip{position:absolute;bottom:35px;right:10px;background-color:var(--emw--color-white, #FFFFFF);border:1px solid var(--emw--color-gray-100, #E6E6E6);color:var(--emw--registration-typography, var(--emw--color-black, #000000));padding:10px;border-radius:5px;opacity:0;transition:opacity 0.3s ease-in-out;z-index:10}.radio__tooltip.visible{opacity:1}";const Qp=class{constructor(i){t(this,i),this.sendValidityState=e(this,"sendValidityState",7),this.sendInputValue=e(this,"sendInputValue",7),this.touched=!1,this.handleComboChange=t=>{this.touched=!0;const e=t.target.value,i=this.options.find((t=>t.value.toLowerCase()===e.toLowerCase()));this.value=i?i.value:e,this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage(),this.emitValueHandler(!0)},this.handleBlur=t=>{const e=t.currentTarget;e.opened||(this.touched=!0,this.value=e.value,this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage(),this.validityStateHandler({valid:this.isValid,name:this.name}))},this.handleSelectChange=t=>{this.touched=!0,this.value=t.target.value,this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage(),this.validityStateHandler({valid:this.isValid,name:this.name}),this.emitValueHandler(!0)},this.setClientStyling=()=>{let t=document.createElement("style");t.innerHTML=this.clientStyling,this.stylingContainer.prepend(t)},this.name=void 0,this.displayName=void 0,this.placeholder=void 0,this.action=void 0,this.defaultValue="",this.autofilled=void 0,this.tooltip=void 0,this.options=[],this.validation=void 0,this.language=void 0,this.emitValue=void 0,this.clientStyling="",this.errorMessage=void 0,this.isValid=void 0,this.limitStylingAppends=!1,this.showTooltip=!1}handleStylingChange(t,e){t!==e&&this.setClientStyling()}validityChanged(){this.validityStateHandler({valid:this.isValid,name:this.name}),1==this.emitValue&&this.valueHandler({name:this.name,value:this.value})}validityStateHandler(t){this.sendValidityState.emit(t)}emitValueHandler(t){1==t&&this.isValid&&this.valueHandler({name:this.name,value:this.value})}valueHandler(t){this.sendInputValue.emit(t)}handleClickOutside(t){t.composedPath()[0]!==this.tooltipIconReference&&t.composedPath()[0]!==this.tooltipReference&&(this.showTooltip=!1)}connectedCallback(){var t;this.displayedOptions=this.options.map((t=>({label:t.label,value:t.value}))),this.isComboBox=(null===(t=this.displayedOptions)||void 0===t?void 0:t.length)>6}componentWillLoad(){if(this.action&&!this.options.length&&"GET"==this.action.split(" ")[0]){const t=this.action.split(" ")[1];return this.getOptions(t).then((t=>{var e;const i=Object.keys(t)[0];this.displayedOptions=t[i].map((t=>({label:t.Name,value:t.Alpha2Code}))),this.isComboBox=(null===(e=this.displayedOptions)||void 0===e?void 0:e.length)>6}))}}componentDidRender(){!this.limitStylingAppends&&this.stylingContainer&&(this.clientStyling&&this.setClientStyling(),this.limitStylingAppends=!0)}componentDidLoad(){if(this.inputReference=this.vaadinCombo.querySelector("input"),this.defaultValue){const t=this.displayedOptions.find((t=>t.value.toUpperCase()===this.defaultValue.toUpperCase()));this.value=t.value,this.valueHandler({name:this.name,value:this.value}),this.inputReference.value=this.value}this.isValid=this.setValidity(),!this.isComboBox&&this.vaadinCombo&&this.vaadinCombo.addEventListener("opened-changed",(t=>{if(!0===t.detail.value)this.errorMessage="";else{const e=t.currentTarget;this.touched=!0,this.value=e.value,this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage(),this.validityStateHandler({valid:this.isValid,name:this.name})}}))}getOptions(t){const e=new URL(t);return new Promise(((t,i)=>{fetch(e.href).then((t=>t.json())).then((e=>{t(e)})).catch((t=>{console.error(t),i(t)}))}))}setValidity(){var t;return!(null===(t=this.validation)||void 0===t?void 0:t.mandatory)||!!this.value}setErrorMessage(){var t,e,i;if((null===(e=null===(t=this.inputReference)||void 0===t?void 0:t.validity)||void 0===e?void 0:e.valueMissing)||(null===(i=this.vaadinCombo)||void 0===i?void 0:i.invalid))return n("requiredError",this.language)}renderTooltip(){return this.showTooltip?i("div",{class:"select__tooltip "+(this.showTooltip?"visible":""),ref:t=>this.tooltipReference=t,innerHTML:this.tooltip}):null}render(){var t,e;let s="";return this.touched&&(s=1==this.isValid||null==this.isValid?"":"text__input--invalid"),i("div",{key:"7e90e23b53a72cda885485ccf4110631cede2b8f",class:`select__wrapper ${this.autofilled?"select__wrapper--autofilled":""} ${this.name}__input`,ref:t=>this.stylingContainer=t},i("div",{key:"9a841ccebeb828fc75ed1f708a4a43d4fc7a193f",class:"select__wrapper--flex"},i("label",{key:"92c70fa56518d6d015d756b693306dab80ab0f57",class:"select__label",htmlFor:`${this.name}__input`},`${this.displayName} ${this.validation.mandatory?"*":""}`),i("div",{key:"cfbeb4b4969adc1f9944eb60291d8f586dcc29db",class:"select__wrapper--relative"},this.tooltip&&i("img",{key:"13a340313095bc653a1741115bae128d538dcf30",class:"select__tooltip-icon",src:a,alt:"",ref:t=>this.tooltipIconReference=t,onClick:()=>this.showTooltip=!this.showTooltip}),this.renderTooltip())),this.isComboBox?i("vaadin-combo-box",{name:this.name,id:`${this.name}__input`,class:`select__input ${s} ${this.autofilled?"select__input--autofilled":""}`,"item-label-path":"label","item-value-path":"value",ref:t=>this.vaadinCombo=t,readOnly:this.autofilled,required:null===(t=this.validation)||void 0===t?void 0:t.mandatory,value:this.value,placeholder:`${this.placeholder}`,items:this.displayedOptions,onChange:this.handleComboChange,onBlur:this.handleBlur}):i("vaadin-select",{name:this.name,popover:!1,id:`${this.name}__input`,class:`select__input ${s} ${this.autofilled?"select__input--autofilled":""}`,"item-label-path":"label","item-value-path":"value",ref:t=>this.vaadinCombo=t,readOnly:this.autofilled,required:null===(e=this.validation)||void 0===e?void 0:e.mandatory,value:this.value,placeholder:`${this.placeholder}`,items:this.displayedOptions,onChange:this.handleSelectChange,"no-vertical-overlap":!0,noVerticalOverlap:!0}),i("small",{key:"6ffb5459f648208106c6bfc8a78f5cf379f7f11b",class:"select__error-message"},this.errorMessage))}static get watchers(){return{clientStyling:["handleStylingChange"],isValid:["validityChanged"],emitValue:["emitValueHandler"]}}};Qp.style='*,*::before,*::after{padding:0;margin:0;box-sizing:border-box}:host{height:100%;--_invalid-hover-highlight:transparent;--vaadin-input-field-invalid-hover-highlight:transparent}vaadin-combo-box>input{background-color:var(--emw--color-white, #FFFFFF);color:var(--emw--registration-typography, var(--emw--color-black, #000000));font-weight:300;font-size:16px;-webkit-font-smoothing:initial;}.select{font-family:"Roboto";font-style:normal}.select__wrapper{position:relative;width:100%;display:flex;flex-direction:column;gap:5px}.select__wrapper--autofilled{pointer-events:none}.select__wrapper--autofilled .select__label{color:var(--emw--registration-typography, var(--emw--color-black, #000000))}.select__wrapper--autofilled .select__input::part(input-field){color:var(--emw--color-black, #000000)}.select__wrapper--flex{display:flex;gap:5px}.select__wrapper--relative{position:relative}.select__label{font-family:inherit;font-style:normal;font-weight:500;font-size:16px;line-height:20px;color:var(--emw--registration-typography, var(--emw--color-black, #000000))}.select__label--required::after{content:"*";font-family:inherit;color:var(--emw--login-color-primary, var(--emw--color-primary, #22B04E));margin-left:2px}.select__input{border:none;width:inherit;position:relative}.select__input[focused]:not(.text__input--invalid)::part(input-field){border-color:var(--emw--login-color-primary, var(--emw--color-primary, #22B04E))}.select__input[invalid]::part(input-field){border:1px solid var(--emw--color-error, var(--emw--color-red, #ed0909))}.select__input vaadin-date-picker-overlay-content>vaadin-button{color:var(--emw--color-black, #000000)}.select__input::part(input-field){border-radius:4px;background-color:var(--emw--color-white, #FFFFFF);border:1px solid var(--emw--color-gray-100, #E6E6E6);color:var(--emw--color-black, #000000);font-family:inherit;font-style:normal;font-size:16px;font-weight:300;line-height:1.5;padding:5px 15px;height:44px}.select__input::part(toggle-button){position:relative;right:10px}.select__error-message{position:absolute;top:calc(100% + 5px);left:0;color:var(--emw--color-error, var(--emw--color-red, #ed0909))}.select__tooltip-icon{width:16px;height:auto}.select__tooltip{position:absolute;top:0;left:20px;background-color:var(--emw--color-white, #FFFFFF);border:1px solid var(--emw--color-gray-100, #E6E6E6);color:var(--emw--registration-typography, var(--emw--color-black, #000000));padding:10px;border-radius:5px;opacity:0;transition:opacity 0.3s ease-in-out;z-index:10}.select__tooltip.visible{opacity:1}';const Jp=class{constructor(i){t(this,i),this.sendValidityState=e(this,"sendValidityState",7),this.sendInputValue=e(this,"sendInputValue",7),this.validationPattern="",this.touched=!1,this.handleInput=t=>{this.phoneValue=t.target.value,this.value={prefix:this.prefixValue,phone:this.phoneValue},this.touched=!0,this.debounceTime&&clearTimeout(this.debounceTime),this.debounceTime=setTimeout((()=>{this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage(),this.emitValueHandler(!0)}),500)},this.handleBlur=()=>{this.touched||(this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage(),this.touched=!0)},this.setClientStyling=()=>{let t=document.createElement("style");t.innerHTML=this.clientStyling,this.stylingContainer.prepend(t)},this.name=void 0,this.displayName=void 0,this.placeholder=void 0,this.showLabels=void 0,this.action=void 0,this.validation=void 0,this.defaultValue=void 0,this.autofilled=void 0,this.tooltip=void 0,this.language=void 0,this.emitValue=void 0,this.clientStyling="",this.isValid=void 0,this.errorMessage=void 0,this.limitStylingAppends=!1,this.showTooltip=!1}handleStylingChange(t,e){t!==e&&this.setClientStyling()}validityChanged(){this.validityStateHandler({valid:this.isValid,name:this.name}),1==this.emitValue&&this.valueHandler({name:this.name,value:this.value,type:"tel"})}validityStateHandler(t){this.sendValidityState.emit(t)}emitValueHandler(t){1==t&&this.isValid&&this.valueHandler({name:this.name,value:this.value,type:"tel"})}valueHandler(t){this.sendInputValue.emit(t)}handleClickOutside(t){t.composedPath()[0]!==this.tooltipIconReference&&t.composedPath()[0]!==this.tooltipReference&&(this.showTooltip=!1)}connectedCallback(){this.validationPattern=this.setPattern(),this.defaultValue&&(this.prefixValue=this.defaultValue.prefix?this.defaultValue.prefix:this.defaultValue,this.phoneValue=this.defaultValue.phone||null)}componentWillLoad(){if(this.action&&"GET"==this.action.split(" ")[0]){const t=this.action.split(" ")[1];return this.getPhoneCodes(t).then((t=>{this.phoneCodesOptions=t.phoneCodes.map((t=>"object"==typeof t&&t.Prefix?{label:t.Prefix,value:t.Prefix}:{label:t,value:t}))}))}}componentDidRender(){!this.limitStylingAppends&&this.stylingContainer&&(this.clientStyling&&this.setClientStyling(),this.limitStylingAppends=!0)}componentDidLoad(){this.isValid=this.setValidity(),this.defaultValue&&(this.value=this.defaultValue,this.valueHandler({name:this.name,value:this.value,type:"tel"}))}getPhoneCodes(t){const e=new URL(t);return new Promise(((t,i)=>{fetch(e.href).then((t=>t.json())).then((e=>{t(e)})).catch((t=>{console.error(t),i(t)}))}))}handlePrefixInput(t){this.prefixValue=t.target.value,this.value={prefix:this.prefixValue,phone:this.phoneValue},this.emitValueHandler(!0)}setValidity(){return this.inputReference.validity.valid}setPattern(){var t,e;if((null===(t=this.validation.custom)||void 0===t?void 0:t.length)>0)return null===(e=this.validation.custom.find((t=>"regex"===t.rule)))||void 0===e?void 0:e.pattern}setErrorMessage(){var t,e;if(this.inputReference.validity.patternMismatch){const i=null===(t=this.validation.custom.find((t=>"regex"===t.rule)))||void 0===t?void 0:t.errorKey,s=null===(e=this.validation.custom.find((t=>"regex"===t.rule)))||void 0===e?void 0:e.errorMessage;return n(`${i}`,this.language)?n(`${i}`,this.language):s}return this.inputReference.validity.tooShort||this.inputReference.validity.tooLong?n("lengthError",this.language,{values:{minLength:this.validation.minLength,maxLength:this.validation.maxLength}}):this.inputReference.validity.valueMissing?n("requiredError",this.language):void 0}renderTooltip(){return this.showTooltip?i("div",{class:"tel__tooltip "+(this.showTooltip?"visible":""),ref:t=>this.tooltipReference=t,innerHTML:this.tooltip}):null}render(){let t="";return this.touched&&(t=1==this.isValid||null==this.isValid?"":"text__input--invalid"),i("div",{key:"07279e9146394ad96ca0ce1b3e059f09fce2937a",class:`tel__wrapper ${this.autofilled?"tel__wrapper--autofilled":""} ${this.name}__input`,ref:t=>this.stylingContainer=t},i("div",{key:"c4eedb1dba6a3fabd4dcc95e767813f95b83346a",class:"tel__wrapper--flex-label"},i("label",{key:"093a445bc6a9144673386abf92263faa2f33a62a",class:"tel__label "+(this.validation.mandatory?"tel__label--required":""),htmlFor:`${this.name}__input`},this.displayName),i("div",{key:"76abd68488a0f78e3fbd46328fa338d8c05b9601",class:"tel__wrapper--relative"},this.tooltip&&i("img",{key:"8238860af5dbc417c2cd853b55fd79f67f51649d",class:"tel__tooltip-icon",src:a,alt:"",ref:t=>this.tooltipIconReference=t,onClick:()=>this.showTooltip=!this.showTooltip}),this.renderTooltip())),i("div",{key:"235b2146fc4c70107d5c077071e1fa52ac1c56d3",class:`tel__wrapper--flex ${t}`},i("vaadin-combo-box",{key:"73e51576aad82c2bc6895a62b0c19351a1eb917b",class:"tel__prefix",items:this.phoneCodesOptions,value:this.prefixValue,readOnly:this.autofilled,onChange:t=>this.handlePrefixInput(t)}),i("input",{key:"d714d757cd08e3d700cec86f9d6ce4ff680dd2e9",type:"tel",ref:t=>this.inputReference=t,id:`${this.name}__input`,readOnly:this.autofilled,class:"tel__input",value:this.phoneValue,placeholder:`${this.placeholder}`,required:this.validation.mandatory,minlength:this.validation.minLength,maxlength:this.validation.maxLength,pattern:this.validationPattern,onInput:this.handleInput,onBlur:this.handleBlur})),i("small",{key:"f6ced1b252990cd3ecc18c9c5ad3546654006dcc",class:"tel__error-message"},this.errorMessage))}static get watchers(){return{clientStyling:["handleStylingChange"],isValid:["validityChanged"],emitValue:["emitValueHandler"]}}};Jp.style='*,*::before,*::after{padding:0;margin:0;box-sizing:border-box}.tel{font-family:"Roboto";font-style:normal}.tel__wrapper{position:relative;width:100%;display:flex;flex-direction:column;gap:5px}.tel__wrapper--autofilled{pointer-events:none}.tel__wrapper--autofilled .tel__label{color:var(--emw--registration-typography, var(--emw--color-black, #000000))}.tel__wrapper--autofilled .tel__input::part(input-field){color:var(--emw--color-black, #000000)}.tel__wrapper--flex{width:inherit;display:flex;align-items:center;border-radius:4px;border:1px solid var(--emw--color-gray-100, #E6E6E6);background-color:var(--emw--color-white, #FFFFFF);overflow:hidden}.tel__wrapper--flex:focus-within{border-color:var(--emw--login-color-primary, var(--emw--color-primary, #22B04E))}.tel__wrapper--flex-label{display:flex;gap:5px}.tel__wrapper--flex--relative{position:relative}.tel__wrapper .text__input--invalid{border:1px solid var(--emw--color-error, var(--emw--color-red, #ed0909))}.tel__label{font-family:inherit;font-style:normal;font-weight:500;font-size:16px;line-height:20px;color:var(--emw--registration-typography, var(--emw--color-black, #000000))}.tel__label--required::after{content:"*";font-family:inherit;color:var(--emw--login-color-primary, var(--emw--color-primary, #22B04E));margin-left:2px}.tel__prefix{--vaadin-field-default-width:90px}.tel__prefix[focus]{outline:none}.tel__prefix::part(input-field){border-radius:0 5px 5px 0;background-color:var(--emw--color-white, #FFFFFF);color:var(--emw--color-black, #000000);font-family:inherit;font-style:normal;font-weight:300;font-size:16px;line-height:1.5;border:none;border-right:2px solid #DDE0EE;border-image-source:linear-gradient(to bottom, rgba(221, 224, 238, 0) 25%, rgb(221, 224, 238) 25%, rgb(221, 224, 238) 75%, rgba(221, 224, 238, 0) 75%);border-image-slice:1;border-image-repeat:round}.tel__prefix::part(input-field):hover{background-color:var(--emw--color-white, #FFFFFF)}.tel__prefix::part(toggle-button){color:var(--emw--registration-typography, var(--emw--color-black, #000000))}.tel__input{font-family:inherit;border-radius:5px;width:100%;color:var(--emw--registration-typography, var(--emw--color-black, #000000));background-color:var(--emw--color-white, #FFFFFF);border:none;width:inherit;position:relative;font-size:16px;font-weight:300;line-height:1.5;padding:5px 15px;height:42px;-moz-appearance:textfield;}.tel__input:focus{outline:none}.tel__input::-webkit-outer-spin-button,.tel__input::-webkit-inner-spin-button{-webkit-appearance:none;margin:0}.tel__input::placeholder{color:var(--emw--color-gray-150, #979797)}.tel__error-message{position:absolute;top:calc(100% + 5px);left:0;color:var(--emw--color-error, var(--emw--color-red, #ed0909))}.tel__tooltip-icon{width:16px;height:auto}.tel__tooltip{position:absolute;top:0;left:20px;background-color:var(--emw--color-white, #FFFFFF);border:1px solid var(--emw--color-gray-100, #E6E6E6);color:var(--emw--registration-typography, var(--emw--color-black, #000000));padding:10px;border-radius:5px;opacity:0;transition:opacity 0.3s ease-in-out;z-index:10}.tel__tooltip.visible{opacity:1}';const Xp=class{constructor(i){t(this,i),this.sendValidityState=e(this,"sendValidityState",7),this.sendInputValue=e(this,"sendInputValue",7),this.value="",this.validationPattern="",this.duplicateInputValue=null,this.touched=!1,this.handleInput=t=>{this.value=t.target.value,this.touched=!0,this.debounceTime&&clearTimeout(this.debounceTime),this.debounceTime=setTimeout((()=>{this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage(),this.validityStateHandler({valid:this.isValid,name:this.name}),this.emitValueHandler(!0)}),500)},this.handleBlur=t=>{this.value=t.target.value,this.touched=!0,this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage(),this.validityStateHandler({valid:this.isValid,name:this.name})},this.setClientStyling=()=>{let t=document.createElement("style");t.innerHTML=this.clientStyling,this.stylingContainer.prepend(t)},this.name=void 0,this.displayName=void 0,this.placeholder=void 0,this.validation=void 0,this.defaultValue="",this.autofilled=void 0,this.tooltip=void 0,this.language=void 0,this.checkValidity=void 0,this.emitValue=void 0,this.isDuplicateInput=void 0,this.clientStyling="",this.isValid=void 0,this.errorMessage="",this.limitStylingAppends=!1,this.showTooltip=!1}handleStylingChange(t,e){t!==e&&this.setClientStyling()}validityChanged(){this.validityStateHandler({valid:this.isValid,name:this.name}),1==this.emitValue&&this.valueHandler({name:this.name,value:this.value})}emitValueHandler(t){1==t&&this.isValid&&this.valueHandler({name:this.name,value:this.value})}validityStateHandler(t){this.sendValidityState.emit(t)}valueHandler(t){this.sendInputValue.emit(t)}handleClickOutside(t){t.composedPath()[0]!==this.tooltipIconReference&&t.composedPath()[0]!==this.tooltipReference&&(this.showTooltip=!1)}valueChangedHandler(t){this.isDuplicateInput&&this.name===t.detail.name+"Duplicate"&&(this.duplicateInputValue=t.detail.value,this.touched&&(this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage())),this.name===t.detail.name+"Duplicate"&&this.name.replace("Duplicate","")===t.detail.name&&!0===this.touched&&(this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage())}handleValidationChange(t){t.detail.field===this.name&&(this.validation=t.detail.validation,this.validationPattern=this.setPattern(),this.touched&&(this.isValid=this.setValidity(),this.errorMessage=this.setErrorMessage()))}connectedCallback(){this.validationPattern=this.setPattern()}componentDidRender(){!this.limitStylingAppends&&this.stylingContainer&&(this.clientStyling&&this.setClientStyling(),this.limitStylingAppends=!0)}componentDidLoad(){this.defaultValue&&(this.value=this.defaultValue,this.valueHandler({name:this.name,value:this.value}),this.isDuplicateInput&&(this.touched=!0)),this.isValid=this.setValidity()}setValidity(){if(this.isDuplicateInput&&this.duplicateInputValue!==this.value)return!1;if(!this.inputReference)return!1;const t=this.inputReference.validity.valid,e=!this.inputReference.value||null!==this.inputReference.value.match(this.validationPattern);return t&&e}setPattern(){var t,e;if((null===(t=this.validation.custom)||void 0===t?void 0:t.length)>0)return null===(e=this.validation.custom.find((t=>"regex"===t.rule)))||void 0===e?void 0:e.pattern}setErrorMessage(){var t,e,i,s;if(this.inputReference.validity.valueMissing)return n("requiredError",this.language);if(this.inputReference.validity.tooShort||this.inputReference.validity.tooLong)return n("lengthError",this.language,{values:{minLength:this.validation.minLength,maxLength:this.validation.maxLength}});if(null==this.inputReference.value.match(this.validationPattern)){const i=null===(t=this.validation.custom.find((t=>"regex"===t.rule)))||void 0===t?void 0:t.errorKey,s=null===(e=this.validation.custom.find((t=>"regex"===t.rule)))||void 0===e?void 0:e.errorMessage;return n(`${i}`,this.language)||s}if(this.isDuplicateInput&&this.duplicateInputValue!==this.value){const t=null===(i=this.validation.custom.find((t=>"duplicate-input"===t.rule)))||void 0===i?void 0:i.errorKey,e=null===(s=this.validation.custom.find((t=>"duplicate-input"===t.rule)))||void 0===s?void 0:s.errorMessage;return n(`${t}`,this.language)?n(`${t}`,this.language):e}}renderTooltip(){return this.showTooltip?i("div",{class:"text__tooltip "+(this.showTooltip?"visible":""),ref:t=>this.tooltipReference=t,innerHTML:this.tooltip}):null}render(){let t="";return this.touched&&(t=1==this.isValid||null==this.isValid?"":"text__input--invalid"),i("div",{key:"37c7509b46ab92149c3c11365cf5061bb1bbb01a",class:`text__wrapper ${this.name}__input ${this.autofilled?"text__wrapper--autofilled":""}`,ref:t=>this.stylingContainer=t},i("div",{key:"737873a059749dc050a8efa6ffb09a1b2ee9f95c",class:"text__wrapper--flex"},i("label",{key:"1d921faece6c293c7e3c95d34bedd0d399c7be9e",class:"text__label "+(this.validation.mandatory?"text__label--required":""),htmlFor:`${this.name}__input`},this.displayName),i("div",{key:"e1e59c85912cf7c3dbd1e61bba829ae2b0192a18",class:"text__wrapper--relative"},this.tooltip&&i("img",{key:"73513026eebcc809edef481d5cd7b885e5f20f03",class:"text__tooltip-icon",src:a,alt:"",ref:t=>this.tooltipIconReference=t,onClick:()=>this.showTooltip=!this.showTooltip}),this.renderTooltip())),i("input",{key:"a73e2c2430e6fbc778e1fd6b5fcfb298cf01b5c5",name:this.name,id:`${this.name}__input`,value:this.defaultValue,type:"text",class:`text__input ${t}`,placeholder:`${this.placeholder}`,ref:t=>this.inputReference=t,readOnly:this.autofilled,required:this.validation.mandatory,minlength:this.validation.minLength,maxlength:this.validation.maxLength,onInput:this.handleInput,onBlur:this.handleBlur}),i("small",{key:"11cb376081cb05651c60c3e1ac8a41f9751ca16c",class:"text__error-message"},this.errorMessage))}static get watchers(){return{clientStyling:["handleStylingChange"],isValid:["validityChanged"],emitValue:["emitValueHandler"]}}};Xp.style='*,*::before,*::after{padding:0;margin:0;box-sizing:border-box}.text{font-family:"Roboto";font-style:normal}.text__wrapper{position:relative;width:100%;display:flex;flex-direction:column;gap:5px}.text__wrapper--autofilled{pointer-events:none}.text__wrapper--autofilled .text__label{color:var(--emw--registration-typography, var(--emw--color-black, #000000))}.text__wrapper--autofilled .text__input::part(input-field){color:var(--emw--color-black, #000000)}.text__wrapper--flex{display:flex;gap:5px}.text__wrapper--relative{position:relative}.text__label{font-family:inherit;font-style:normal;font-weight:500;font-size:16px;line-height:20px;color:var(--emw--registration-typography, var(--emw--color-black, #000000))}.text__label--required::after{content:"*";font-family:inherit;color:var(--emw--login-color-primary, var(--emw--color-primary, #22B04E));margin-left:2px}.text__input{font-family:inherit;width:100%;height:44px;border:1px solid var(--emw--color-gray-100, #E6E6E6);background-color:var(--emw--color-white, #FFFFFF);color:var(--emw--color-black, #000000);border-radius:5px;font-size:16px;font-weight:300;line-height:1.5;padding:5px 15px}.text__input:focus{border:1px solid var(--emw--login-color-primary, var(--emw--color-primary, #22B04E))}.text__input--invalid{border:1px solid var(--emw--color-error, var(--emw--color-red, #ed0909))}.text__input::placeholder{color:var(--emw--color-gray-150, #828282)}.text__error-message{position:absolute;top:calc(100% + 5px);left:0;color:var(--emw--color-error, var(--emw--color-red, #ed0909))}.text__tooltip-icon{width:16px;height:auto}.text__tooltip{position:absolute;top:0;left:20px;background-color:var(--emw--color-white, #FFFFFF);border:1px solid var(--emw--color-gray-100, #E6E6E6);color:var(--emw--registration-typography, var(--emw--color-black, #000000));padding:10px;border-radius:5px;opacity:0;transition:opacity 0.3s ease-in-out;z-index:10}.text__tooltip.visible{opacity:1}';const Zp=class{constructor(i){t(this,i),this.sendValidityState=e(this,"sendValidityState",7),this.sendInputValue=e(this,"sendInputValue",7),this.callBackObject={},this.subFieldsObject={},this.value="",this.handleRevealField=(t,e)=>{t.stopPropagation(),window.postMessage({type:`registration${e}Clicked`},window.location.href)},this.setClientStyling=()=>{let t=document.createElement("style");t.innerHTML=this.clientStyling,this.stylingContainer.prepend(t)},this.name=void 0,this.displayName=void 0,this.defaultValue="",this.options=void 0,this.autofilled=void 0,this.tooltip=void 0,this.validation=void 0,this.language=void 0,this.emitValue=void 0,this.clientStyling="",this.errorMessage=void 0,this.isValid=void 0,this.limitStylingAppends=!1,this.showTooltip=!1,this.showFields="true"===this.defaultValue}handleStylingChange(t,e){t!==e&&this.setClientStyling()}validityStateHandler(t){this.sendValidityState.emit(t)}valueHandler(t){this.sendInputValue.emit(t)}handleClickOutside(t){t.composedPath()[0]!==this.tooltipIconReference&&t.composedPath()[0]!==this.tooltipReference&&(this.showTooltip=!1)}componentDidRender(){!this.limitStylingAppends&&this.stylingContainer&&(this.clientStyling&&this.setClientStyling(),this.limitStylingAppends=!0)}componentDidLoad(){0!==this.options.length&&this.options.forEach((t=>{this.callBackObject[t.name]=e=>{this.handleRevealField(e,t.name)},this.subFieldsObject[t.name].addEventListener("click",this.callBackObject[t.name])}))}handleClick(){this.showFields=this.checkboxReference.checked,this.errorMessage=this.setErrorMessage(),this.isValid=this.setValidity(),this.valueHandler({name:this.name,value:this.checkboxReference.checked?"true":"false",type:"toggle"})}setValidity(){return this.checkboxReference.validity.valid}setErrorMessage(){if(this.checkboxReference.validity.valueMissing)return n("requiredError",this.language)}disconnectedCallback(){this.options.forEach((t=>{this.subFieldsObject[t.name].removeEventListener("click",this.callBackObject[t.name])}))}renderLabel(){return i("label",{class:"togglecheckbox__label",htmlFor:`${this.name}__input`},i("div",{class:"togglecheckbox__label-text",innerHTML:`${this.displayName} ${this.validation.mandatory?"*":""}`}))}renderTooltip(){return this.showTooltip?i("div",{class:"togglecheckbox__tooltip "+(this.showTooltip?"visible":""),ref:t=>this.tooltipReference=t,innerHTML:this.tooltip}):null}render(){return i("div",{key:"6315588766319c4ac7a88646b01bc577858ad718",class:`togglecheckbox__wrapper ${this.name}__input`,ref:t=>this.stylingContainer=t},i("div",{key:"20d6999aaf0499b8b840a28dab89242953b4610d",class:"togglecheckbox__wrapper--flex"},i("input",{key:"73b699abf4904e4f2133e30d8dea250c9fe13ac3",class:"togglecheckbox__input",type:"checkbox",id:`${this.name}__input`,ref:t=>this.checkboxReference=t,name:this.name,checked:"true"===this.defaultValue,readOnly:this.autofilled,required:this.validation.mandatory,value:this.value,onClick:()=>this.handleClick()}),this.renderLabel()),i("small",{key:"4d10247f1dae300d0f5133accdd544a90fa4d5a7",class:"togglecheckbox__error-message"},this.errorMessage),i("div",{key:"9c95cef35e58875b96710d3b64b9af1be27204c5",class:"togglecheckbox__wrapper--relative"},this.tooltip&&i("img",{key:"9774edae6bad4715fd20798a7be25eb71c3c4cf0",class:"togglecheckbox__tooltip-icon",src:a,alt:"",ref:t=>this.tooltipIconReference=t,onClick:()=>this.showTooltip=!this.showTooltip}),this.renderTooltip()),i("div",{key:"70ad3ec894a32439e2dcea617e2a5b773c5456b1",class:"togglecheckbox__fields-wrapper "+(this.showFields?"":"hidden")},this.options.map((t=>i("general-input",{type:t.inputType,name:t.name,displayName:t.displayName,validation:t.validate,action:t.action||null,defaultValue:t.defaultValue,autofilled:t.autofill,emitValue:this.emitValue,language:this.language,"client-styling":this.clientStyling,tooltip:t.tooltip,placeholder:null==t.placeholder?"":t.placeholder,ref:e=>this.subFieldsObject[t.name]=e})))))}static get watchers(){return{clientStyling:["handleStylingChange"]}}};Zp.style='*,*::before,*::after{padding:0;margin:0;box-sizing:border-box}.togglecheckbox{font-family:"Roboto";font-style:normal;font-size:15px}.togglecheckbox__wrapper{position:relative}.togglecheckbox__wrapper--flex{display:flex;gap:10px;align-items:baseline}.togglecheckbox__wrapper--relative{position:relative;display:inline}.togglecheckbox__input{transform:scale(1.307, 1.307);margin-left:2px;accent-color:var(--emw--login-color-primary, var(--emw--color-primary, #22B04E))}.togglecheckbox__label{font-style:inherit;font-family:inherit;font-weight:400;font-size:16px;color:var(--emw--registration-typography, var(--emw--color-black, #000000));line-height:1.5;cursor:pointer;padding:0}.togglecheckbox__label-text{font-size:16px}.togglecheckbox__label a{color:var(--emw--login-color-primary, var(--emw--color-primary, #22B04E))}.togglecheckbox__error-message{position:absolute;top:calc(100% + 5px);left:0;color:var(--emw--color-error, var(--emw--color-red, #ed0909))}.togglecheckbox__tooltip-icon{width:16px;height:auto}.togglecheckbox__tooltip{position:absolute;top:0;right:0;background-color:var(--emw--color-white, #FFFFFF);border:1px solid var(--emw--color-gray-100, #E6E6E6);color:var(--emw--registration-typography, var(--emw--color-black, #000000));padding:10px;border-radius:5px;opacity:0;transition:opacity 0.3s ease-in-out;z-index:10}.togglecheckbox__tooltip.visible{opacity:1}.togglecheckbox__fields-wrapper{margin-top:40px;display:flex;flex-direction:column;gap:40px}.hidden{display:none}';const tm=class{constructor(i){t(this,i),this.sendValidityState=e(this,"sendValidityState",7),this.sendInputValue=e(this,"sendInputValue",7),this.resendCode=e(this,"resendCode",7),this.validationPattern="",this.stylingContainer=null,this.tooltipReference=null,this.tooltipIconReference=null,this.inputRefs=[],this.containerRef=null,this.resendInterval=null,this.resendCodeHandler=()=>{this.triggerResendInterval(),this.resendCode.emit()},this.setInputRef=(t,e)=>{t&&(this.inputRefs[e]=t)},this.setContainerRef=t=>{t&&(this.containerRef=t)},this.triggerResendInterval=()=>{this.isResendButtonAvailable=!1,this.resendInterval&&clearInterval(this.resendInterval),this.resendInterval=setInterval((()=>{--this.resendIntervalSecondsLeft<=0&&(clearInterval(this.resendInterval),this.resendIntervalSecondsLeft=this.resendIntervalSeconds,this.isResendButtonAvailable=!0)}),1e3)},this.formatTime=()=>{const t=String(Math.floor(this.resendIntervalSecondsLeft/60));let e=String(this.resendIntervalSecondsLeft%60);return 1===e.length&&(e="0"+e),`${t}:${e}`},this.handleInput=(t,e)=>{const i=t.target,s=i.value;if(i.value=s.charAt(s.length>1?1:0),!s)return;this.code[e]=i.value;const o=this.inputRefs[e+1];o&&o.focus(),this.setValidity(),this.setErrorMessage()},this.setClientStyling=()=>{let t=document.createElement("style");t.innerHTML=this.clientStyling,this.stylingContainer.prepend(t)},this.name="",this.displayName="",this.placeholder="",this.validation=void 0,this.tooltip="",this.language="en",this.emitValue=!0,this.destination="",this.resendIntervalSeconds=60,this.clientStyling="",this.limitStylingAppends=!1,this.isValid=!1,this.isResendButtonAvailable=!0,this.showTooltip=!1,this.errorMessage="",this.code=[],this.resendIntervalSecondsLeft=this.resendIntervalSeconds}handleStylingChange(t,e){t!==e&&this.setClientStyling()}validityChanged(){this.validityStateHandler({valid:this.isValid,name:this.name}),1==this.emitValue&&this.valueHandler({name:this.name,value:this.code.join("")})}emitValueHandler(t){1==t&&this.isValid&&this.valueHandler({name:this.name,value:this.code.join("")})}validityStateHandler(t){this.sendValidityState.emit(t)}valueHandler(t){this.sendInputValue.emit(t)}handleClickOutside(t){t.composedPath()[0]!==this.tooltipIconReference&&t.composedPath()[0]!==this.tooltipReference&&(this.showTooltip=!1)}connectedCallback(){this.validationPattern=this.setPattern(),this.code=new Array(this.validation.maxLength).fill("")}componentDidRender(){!this.limitStylingAppends&&this.stylingContainer&&(this.clientStyling&&this.setClientStyling(),this.limitStylingAppends=!0)}componentDidLoad(){this.setValidity()}handleKeyDown(t,e){if("Backspace"===t.key){this.code[e]="",this.inputRefs[e]&&(this.inputRefs[e].value="");const t=this.inputRefs[e-1];t&&(null==t||t.focus())}this.setValidity(),this.setErrorMessage()}handlePaste(t){var e;t.preventDefault();const i=null===(e=t.clipboardData)||void 0===e?void 0:e.getData("text").trim();if(!i)return;const s=i.slice(0,this.validation.maxLength).split("");this.code=[...s,...new Array(this.validation.maxLength-s.length).fill("")],s.forEach(((t,e)=>{this.inputRefs[e].value=t}));const o=this.inputRefs[Math.min(s.length,this.inputRefs.length-1)];o&&o.focus(),this.setValidity(),this.setErrorMessage()}setValidity(){const t=this.code.join(""),e=t.length===this.validation.maxLength,i=null!==t.match(this.validationPattern);this.isValid=e&&i}setPattern(){var t,e;if((null===(t=this.validation.custom)||void 0===t?void 0:t.length)>0)return null===(e=this.validation.custom.find((t=>"regex"===t.rule)))||void 0===e?void 0:e.pattern}setErrorMessage(){var t;if(null!==this.code.join("").match(this.validationPattern))this.errorMessage="";else{const e=null===(t=this.validation.custom.find((t=>"regex"===t.rule)))||void 0===t?void 0:t.errorKey;e&&(this.errorMessage=n(e,this.language))}}renderTooltip(){return this.showTooltip?i("div",{class:"text__tooltip "+(this.showTooltip?"visible":""),ref:t=>this.tooltipReference=t,innerHTML:this.tooltip}):null}render(){return i("div",{key:"97c1955fececc6f3998375f4c8176ceaed66856a",class:"twofa"},i("div",{key:"ee2243931d8e5c6a5aadf1e78d1851449806d2b2",class:"twofa__error-message"},i("p",{key:"20a8ccad2e6501c73e3672f6ae325f8539e2d21a"},this.errorMessage)),i("div",{key:"bb33610a8be04b86378026c02099620749b81a4b",class:"twofa__description",innerHTML:n("twofaDescription",this.language,{values:{destination:this.destination}})}),i("div",{key:"af3ea38ed6468eb2de66aed810ba50a850bf21a9",class:"twofa__input-wrapper",ref:this.setContainerRef},this.code.map(((t,e)=>i("input",{key:e,ref:t=>this.setInputRef(t,e),id:`otp-input-${e}`,type:"text",maxLength:2,value:t,onInput:t=>this.handleInput(t,e),onKeyDown:t=>this.handleKeyDown(t,e),onPaste:t=>this.handlePaste(t)})))),i("div",{key:"f385bd6dc93896d918a5cc1365b59bedd47d5bb0",class:"twofa__button-wrapper"},i("p",{key:"3623f0391e0e5923cd6b3bfd74d203905486209f",class:"twofa__resend-message"},n("twofaResendMessage",this.language)),i("button",{key:"497660604f87dbf4ce1ce51ecd041e82ab5dd33a",class:"twofa__resend-button",onClick:this.resendCodeHandler,disabled:!this.isResendButtonAvailable},this.isResendButtonAvailable?n("twofaResendButton",this.language):this.formatTime())))}static get watchers(){return{clientStyling:["handleStylingChange"],isValid:["validityChanged"],emitValue:["emitValueHandler"]}}};tm.style="*,*::before,*::after{padding:0;margin:0;box-sizing:border-box}.twofa{display:flex;flex-direction:column;gap:10px}.twofa__description{display:flex;flex-direction:column;gap:10px;align-items:center;justify-content:center}.twofa__error-message{text-align:center;color:var(--emw--color-error, var(--emw--color-red, #ed0909))}.twofa__input-wrapper{display:flex;justify-content:center}.twofa__input-wrapper input{width:35px;height:35px;padding:10px;text-align:center;border-radius:var(--emw--border-radius-small, 5px);margin-left:5px;margin-right:5px;border:2px solid var(--emw--otp-border-color, #55525c);font-weight:var(--emw-font-weight-bold, 800);outline:none;transition:all 0.1s}.twofa__input-wrapper input:focus{border:2px solid var(--emw--color-primary, #22B04E);box-shadow:0 0 2px 2px var(--emw--color-primary, #22B04E)}.twofa__button-wrapper{justify-content:center;text-align:center}.twofa__button-wrapper button{border:none;background:none;font-weight:var(--emw-font-weight-bold, 800);color:var(--emw--color-primary, #22B04E);cursor:pointer}";export{l as checkbox_group_input,h as checkbox_input,Ke as date_input,Qe as email_input,Gp as general_input,Yp as number_input,Up as password_input,Kp as radio_input,Qp as select_input,Jp as tel_input,Xp as text_input,Zp as toggle_checkbox_input,tm as twofa_input}
|