iobroker.lovelace
Version:
With this adapter you can build visualization for ioBroker with Home Assistant Lovelace UI
5 lines • 37 kB
JavaScript
/*! For license information please see 8011.3c8b7e72c242560e.js.LICENSE.txt */
;(self.rspackChunkhome_assistant_frontend=self.rspackChunkhome_assistant_frontend||[]).push([[8011],{34271:function(t,e,o){o.d(e,{A:function(){return i}});o(18111),o(7588),o(61701);function i(t){if(!t||"object"!=typeof t)return t;if("[object Date]"==Object.prototype.toString.call(t))return new Date(t.getTime());if(Array.isArray(t))return t.map(i);var e={};return Object.keys(t).forEach(function(o){e[o]=i(t[o])}),e}},35370:function(t,e,o){var i=o(26198);t.exports=function(t,e,o){for(var r=0,n=arguments.length>2?o:i(e),a=new t(n);n>r;)a[r]=e[r++];return a}},77957:function(t,e,o){var i=o(76080),r=o(79504),n=o(47055),a=o(48981),s=o(56969),l=o(26198),h=o(2360),c=o(35370),u=Array,d=r([].push);t.exports=function(t,e,o,r){for(var p,f,b,v=a(t),w=n(v),m=i(e,o),g=h(null),y=l(w),k=0;y>k;k++)b=w[k],(f=s(m(b,k,v)))in g?d(g[f],b):g[f]=[b];if(r&&(p=r(v))!==u)for(f in g)g[f]=c(p,g[f]);return g}},46058:function(t,e,o){var i=o(46518),r=o(77957),n=o(6469);i({target:"Array",proto:!0},{group:function(t){return r(this,t,arguments.length>1?arguments[1]:void 0)}}),n("group")},97577:function(t,e,o){o.d(e,{A:function(){return E}});o(27495),o(62953);var i=o(5124),r=o(67576),n=o(6412),a=o(63672),s=o(34514),l=o(40991),h=o(92070),c=o(49546),u=o(9395),d=o(62676),p=o(15477),f=o(31896);o(38625);let b;var v=(0,i.AH)(b||(b=(t=>t)`:host{--checked-icon-color:var(--wa-color-brand-on-loud);--checked-icon-scale:0.8;display:inline-flex;color:var(--wa-form-control-value-color);font-family:inherit;font-weight:var(--wa-form-control-value-font-weight);line-height:var(--wa-form-control-value-line-height);user-select:none;-webkit-user-select:none}[part~=control]{display:inline-flex;flex:0 0 auto;position:relative;align-items:center;justify-content:center;width:var(--wa-form-control-toggle-size);height:var(--wa-form-control-toggle-size);border-color:var(--wa-form-control-border-color);border-radius:min(calc(var(--wa-form-control-toggle-size) * .375),var(--wa-border-radius-s));border-style:var(--wa-border-style);border-width:var(--wa-form-control-border-width);background-color:var(--wa-form-control-background-color);transition:background var(--wa-transition-normal),border-color var(--wa-transition-fast),box-shadow var(--wa-transition-fast),color var(--wa-transition-fast);transition-timing-function:var(--wa-transition-easing);margin-inline-end:.5em}[part~=base]{display:flex;align-items:flex-start;position:relative;color:currentColor;vertical-align:middle;cursor:pointer}[part~=label]{display:inline}[part~=control]:has(:checked,:indeterminate){color:var(--checked-icon-color);border-color:var(--wa-form-control-activated-color);background-color:var(--wa-form-control-activated-color)}[part~=control]:has(> input:focus-visible:not(:disabled)){outline:var(--wa-focus-ring);outline-offset:var(--wa-focus-ring-offset)}:host [part~=base]:has(input:disabled){opacity:.5;cursor:not-allowed}input{position:absolute;padding:0;margin:0;height:100%;width:100%;opacity:0;pointer-events:none}[part~=icon]{display:flex;scale:var(--checked-icon-scale)}[part~=icon]::part(svg){translate:0.0009765625em}input:not(:checked,:indeterminate)+[part~=icon]{visibility:hidden}:host([required]) [part~=label]::after{content:var(--wa-form-control-required-content);color:var(--wa-form-control-required-content-color);margin-inline-start:var(--wa-form-control-required-content-offset)}`));let w,m,g,y=t=>t;var k=Object.defineProperty,C=Object.getOwnPropertyDescriptor,x=(t,e,o,i)=>{for(var r,n=i>1?void 0:i?C(e,o):e,a=t.length-1;a>=0;a--)(r=t[a])&&(n=(i?r(e,o,n):r(n))||n);return i&&n&&k(e,o,n),n};let E=class extends d.q{static get validators(){const t=i.S$?[]:[(0,c.Y)({validationProperty:"checked",validationElement:Object.assign(document.createElement("input"),{type:"checkbox",required:!0})})];return[...super.validators,...t]}get value(){var t;return null!==(t=this._value)&&void 0!==t?t:"on"}set value(t){this._value=t}handleSizeChange(){(0,l.b)(this.localName,this.size)}get checked(){var t;return this.valueHasChanged?Boolean(this._checked):null!==(t=this._checked)&&void 0!==t?t:this.defaultChecked}set checked(t){this._checked=Boolean(t),this.valueHasChanged=!0}handleClick(){this.hasInteracted=!0,this.checked=!this.checked,this.indeterminate=!1,this.updateComplete.then(()=>{this.dispatchEvent(new Event("change",{bubbles:!0,composed:!0}))})}connectedCallback(){super.connectedCallback(),this.handleDefaultCheckedChange()}handleDefaultCheckedChange(){this.handleValueOrCheckedChange()}handleValueOrCheckedChange(){this.setValue(this.checked?this.value:null,this._value),this.updateValidity()}handleStateChange(){this.hasUpdated&&(this.input.checked=this.checked,this.input.indeterminate=this.indeterminate),this.customStates.set("checked",this.checked),this.customStates.set("indeterminate",this.indeterminate),this.updateValidity()}handleDisabledChange(){this.customStates.set("disabled",this.disabled)}willUpdate(t){super.willUpdate(t),(t.has("value")||t.has("checked")||t.has("defaultChecked"))&&this.handleValueOrCheckedChange()}formResetCallback(){this._checked=null,super.formResetCallback(),this.handleValueOrCheckedChange()}click(){this.input.click()}focus(t){this.input.focus(t)}blur(){this.input.blur()}render(){const t=!!i.S$||this.hasSlotController.test("hint"),e=!!this.hint||!!t,o=!this.checked&&this.indeterminate,r=o?"indeterminate":"check",l=o?"indeterminate":"check";return(0,i.qy)(w||(w=y` <label part="base"> <span part="control"> <input class="input" type="checkbox" title="${0}" name="${0}" value="${0}" .indeterminate="${0}" .checked="${0}" .disabled="${0}" .required="${0}" aria-checked="${0}" aria-describedby="hint" @click="${0}"> <wa-icon part="${0}-icon icon" library="system" name="${0}"></wa-icon> </span> <slot part="label"></slot> </label> <slot id="hint" part="hint" name="hint" aria-hidden="${0}" class="${0}"> ${0} </slot> `),this.title,(0,a.J)(this.name),(0,a.J)(this._value),(0,s.V)(this.indeterminate),(0,s.V)(this.checked),this.disabled,this.required,this.indeterminate?"mixed":this.checked?"true":"false",this.handleClick,l,r,e?"false":"true",(0,n.H)({"has-slotted":e}),this.hint)}constructor(){var t;super(...arguments),this.hasSlotController=new h.X(this,"hint"),this.title="",this.name=null,this._value=null!==(t=this.getAttribute("value"))&&void 0!==t?t:null,this.size="m",this.disabled=!1,this.indeterminate=!1,this._checked=null,this.defaultChecked=this.hasAttribute("checked"),this.required=!1,this.hint=""}};E.css=[p.A,f.A,v],E.shadowRootOptions=Object.assign(Object.assign({},d.q.shadowRootOptions),{},{delegatesFocus:!0}),x([(0,r.P)('input[type="checkbox"]')],E.prototype,"input",2),x([(0,r.MZ)()],E.prototype,"title",2),x([(0,r.MZ)({reflect:!0})],E.prototype,"name",2),x([(0,r.MZ)({reflect:!0})],E.prototype,"value",1),x([(0,r.MZ)({reflect:!0})],E.prototype,"size",2),x([(0,u.w)("size")],E.prototype,"handleSizeChange",1),x([(0,r.MZ)({type:Boolean})],E.prototype,"disabled",2),x([(0,r.MZ)({type:Boolean,reflect:!0})],E.prototype,"indeterminate",2),x([(0,r.MZ)({type:Boolean,attribute:!1})],E.prototype,"checked",1),x([(0,r.MZ)({type:Boolean,reflect:!0,attribute:"checked"})],E.prototype,"defaultChecked",2),x([(0,r.MZ)({type:Boolean,reflect:!0})],E.prototype,"required",2),x([(0,r.MZ)()],E.prototype,"hint",2),x([(0,u.w)(["checked","defaultChecked"])],E.prototype,"handleDefaultCheckedChange",1),x([(0,u.w)(["checked","indeterminate"])],E.prototype,"handleStateChange",1),x([(0,u.w)("disabled")],E.prototype,"handleDisabledChange",1),E=x([(0,r.EM)("wa-checkbox")],E),null===(m=(g=E).disableWarning)||void 0===m||m.call(g,"change-in-update")},30006:function(t,e,o){o.a(t,async function(t,e){try{o(74423),o(27495),o(62953);var i=o(5124),r=o(67576),n=o(6412),a=o(63672),s=o(34514),l=o(37541),h=o(40991),c=o(92070),u=o(28225),d=o(41268),p=o(9395),f=o(62676),b=o(15477),v=o(31896),w=o(17060),m=(o(38625),o(96272)),g=t([w]);w=(g.then?(await g)():g)[0];let x,E,A,M,$,O,T,Z=t=>t;var y=Object.defineProperty,k=Object.getOwnPropertyDescriptor,C=(t,e,o,i)=>{for(var r,n=i>1?void 0:i?k(e,o):e,a=t.length-1;a>=0;a--)(r=t[a])&&(n=(i?r(e,o,n):r(n))||n);return i&&n&&y(e,o,n),n};let S=class extends f.q{static get validators(){return[...super.validators,(0,d.i)()]}get value(){var t;return this.valueHasChanged?this._value:null!==(t=this._value)&&void 0!==t?t:this.defaultValue}set value(t){this._value!==t&&(this.valueHasChanged=!0,this._value=t)}handleSizeChange(){(0,h.b)(this.localName,this.size)}handleChange(t){this.value=this.input.value,this.relayNativeEvent(t,{bubbles:!0,composed:!0})}clear(){""!==this.value&&(this.value="",this.updateComplete.then(()=>{this.dispatchEvent(new l.I),this.dispatchEvent(new InputEvent("input",{bubbles:!0,composed:!0})),this.dispatchEvent(new Event("change",{bubbles:!0,composed:!0}))})),this.input.focus()}handleClearClick(t){t.preventDefault(),this.clear()}handleInput(){this.value=this.input.value}handleKeyDown(t){(0,u.U)(t,this)}handlePasswordToggle(){this.passwordVisible=!this.passwordVisible}updated(t){if(super.updated(t),t.has("value")||t.has("defaultValue")||t.has("type")){const t=["number","date","time","datetime-local"];this.input&&t.includes(this.type)&&this.value&&this.input.value!==this.value&&(this._value=this.input.value),this.customStates.set("blank",!this.value),this.updateValidity()}}handleStepChange(){this.input.step=String(this.step),this.updateValidity()}focus(t){this.input.focus(t)}blur(){this.input.blur()}select(){this.input.select()}setSelectionRange(t,e,o="none"){this.input.setSelectionRange(t,e,o)}setRangeText(t,e,o,i="preserve"){const r=null!=e?e:this.input.selectionStart,n=null!=o?o:this.input.selectionEnd;this.input.setRangeText(t,r,n,i),this.value!==this.input.value&&(this.value=this.input.value)}showPicker(){"showPicker"in HTMLInputElement.prototype&&this.input.showPicker()}stepUp(){this.input.stepUp(),this.value!==this.input.value&&(this.value=this.input.value)}stepDown(){this.input.stepDown(),this.value!==this.input.value&&(this.value=this.input.value)}formResetCallback(){this.value=null,this.input&&(this.input.value=this.value),super.formResetCallback()}render(){var t;const e=this.hasUpdated?this.hasSlotController.test("label"):this.withLabel,o=this.hasUpdated?this.hasSlotController.test("hint"):this.withHint,r=!!this.label||!!e,l=!!this.hint||!!o,h=this.withClear&&!this.disabled&&!this.readonly,c=(i.S$||this.hasUpdated)&&h&&("number"==typeof this.value||this.value&&this.value.length>0);return(0,i.qy)(x||(x=Z` <label part="form-control-label label" class="${0}" for="input" aria-hidden="${0}"> <slot name="label">${0}</slot> </label> <div part="base" class="text-field"> <slot name="start" part="start" class="start"></slot> <input part="input" id="input" class="control" type="${0}" title="${0}" name="${0}" ?disabled="${0}" ?readonly="${0}" ?required="${0}" placeholder="${0}" minlength="${0}" maxlength="${0}" min="${0}" max="${0}" step="${0}" .value="${0}" autocapitalize="${0}" autocomplete="${0}" autocorrect="${0}" ?autofocus="${0}" spellcheck="${0}" pattern="${0}" enterkeyhint="${0}" inputmode="${0}" aria-describedby="hint" @change="${0}" @input="${0}" @keydown="${0}"> ${0} ${0} <slot name="end" part="end" class="end"></slot> </div> <slot id="hint" part="hint" name="hint" class="${0}" aria-hidden="${0}">${0}</slot> `),(0,n.H)({label:!0,"has-label":r}),r?"false":"true",this.label,"password"===this.type&&this.passwordVisible?"text":this.type,this.title,(0,a.J)(this.name),this.disabled,this.readonly,this.required,(0,a.J)(this.placeholder),(0,a.J)(this.minlength),(0,a.J)(this.maxlength),(0,a.J)(this.min),(0,a.J)(this.max),(0,a.J)(this.step),(0,s.V)(null!==(t=this.value)&&void 0!==t?t:""),(0,a.J)(this.autocapitalize),(0,a.J)(this.autocomplete),this.autocorrect?"on":"off",this.autofocus,this.spellcheck,(0,a.J)(this.pattern),(0,a.J)(this.enterkeyhint),(0,a.J)(this.inputmode),this.handleChange,this.handleInput,this.handleKeyDown,c?(0,i.qy)(E||(E=Z` <slot name="clear-button"> <button part="clear-button" class="clear" type="button" aria-label="${0}" @click="${0}" tabindex="-1"> <slot name="clear-icon"> <wa-icon name="circle-xmark" library="system" variant="regular"></wa-icon> </slot> </button> </slot> `),this.localize.term("clearEntry"),this.handleClearClick):"",this.passwordToggle&&!this.disabled?(0,i.qy)(A||(A=Z` <slot name="password-toggle-button"> <button part="password-toggle-button" class="password-toggle" type="button" aria-label="${0}" @click="${0}" tabindex="-1"> ${0} </button> </slot> `),this.localize.term(this.passwordVisible?"hidePassword":"showPassword"),this.handlePasswordToggle,this.passwordVisible?(0,i.qy)($||($=Z` <slot name="hide-password-icon"> <wa-icon name="eye-slash" library="system" variant="regular"></wa-icon> </slot> `)):(0,i.qy)(M||(M=Z` <slot name="show-password-icon"> <wa-icon name="eye" library="system" variant="regular"></wa-icon> </slot> `))):"",(0,n.H)({"has-slotted":l}),l?"false":"true",this.hint)}constructor(){super(...arguments),this.assumeInteractionOn=["blur","input"],this.hasSlotController=new c.X(this,"hint","label"),this.localize=new w.c(this),this.title="",this.type="text",this._value=null,this.defaultValue=this.getAttribute("value")||null,this.size="m",this.appearance="outlined",this.pill=!1,this.label="",this.hint="",this.withClear=!1,this.placeholder="",this.readonly=!1,this.passwordToggle=!1,this.passwordVisible=!1,this.withoutSpinButtons=!1,this.required=!1,this.spellcheck=!0,this.withLabel=!1,this.withHint=!1}};S.css=[v.A,b.A,m.A],S.shadowRootOptions=Object.assign(Object.assign({},f.q.shadowRootOptions),{},{delegatesFocus:!0}),C([(0,r.P)("input")],S.prototype,"input",2),C([(0,r.MZ)()],S.prototype,"title",2),C([(0,r.MZ)({reflect:!0})],S.prototype,"type",2),C([(0,r.wk)()],S.prototype,"value",1),C([(0,r.MZ)({attribute:"value",reflect:!0})],S.prototype,"defaultValue",2),C([(0,r.MZ)({reflect:!0})],S.prototype,"size",2),C([(0,p.w)("size")],S.prototype,"handleSizeChange",1),C([(0,r.MZ)({reflect:!0})],S.prototype,"appearance",2),C([(0,r.MZ)({type:Boolean,reflect:!0})],S.prototype,"pill",2),C([(0,r.MZ)()],S.prototype,"label",2),C([(0,r.MZ)({attribute:"hint"})],S.prototype,"hint",2),C([(0,r.MZ)({attribute:"with-clear",type:Boolean})],S.prototype,"withClear",2),C([(0,r.MZ)()],S.prototype,"placeholder",2),C([(0,r.MZ)({type:Boolean,reflect:!0})],S.prototype,"readonly",2),C([(0,r.MZ)({attribute:"password-toggle",type:Boolean})],S.prototype,"passwordToggle",2),C([(0,r.MZ)({attribute:"password-visible",type:Boolean})],S.prototype,"passwordVisible",2),C([(0,r.MZ)({attribute:"without-spin-buttons",type:Boolean,reflect:!0})],S.prototype,"withoutSpinButtons",2),C([(0,r.MZ)({type:Boolean,reflect:!0})],S.prototype,"required",2),C([(0,r.MZ)()],S.prototype,"pattern",2),C([(0,r.MZ)({type:Number})],S.prototype,"minlength",2),C([(0,r.MZ)({type:Number})],S.prototype,"maxlength",2),C([(0,r.MZ)()],S.prototype,"min",2),C([(0,r.MZ)()],S.prototype,"max",2),C([(0,r.MZ)()],S.prototype,"step",2),C([(0,r.MZ)()],S.prototype,"autocapitalize",2),C([(0,r.MZ)({type:Boolean,converter:{fromAttribute:t=>!(!t||"off"===t),toAttribute:t=>t?"on":"off"}})],S.prototype,"autocorrect",2),C([(0,r.MZ)()],S.prototype,"autocomplete",2),C([(0,r.MZ)({type:Boolean})],S.prototype,"autofocus",2),C([(0,r.MZ)()],S.prototype,"enterkeyhint",2),C([(0,r.MZ)({type:Boolean,converter:{fromAttribute:t=>!(!t||"false"===t),toAttribute:t=>t?"true":"false"}})],S.prototype,"spellcheck",2),C([(0,r.MZ)()],S.prototype,"inputmode",2),C([(0,r.MZ)({attribute:"with-label",type:Boolean})],S.prototype,"withLabel",2),C([(0,r.MZ)({attribute:"with-hint",type:Boolean})],S.prototype,"withHint",2),C([(0,p.w)("step",{waitUntilFirstUpdate:!0})],S.prototype,"handleStepChange",1),S=C([(0,r.EM)("wa-input")],S),null===(O=(T=S).disableWarning)||void 0===O||O.call(T,"change-in-update"),e()}catch(x){e(x)}})},96272:function(t,e,o){o.d(e,{A:function(){return r}});let i;var r=(0,o(5124).AH)(i||(i=(t=>t)`:host{border-width:0}:host(:focus){outline:0}.text-field{display:flex;align-items:stretch;justify-content:start;position:relative;transition:inherit;height:var(--wa-form-control-height);border-color:var(--wa-form-control-border-color);border-radius:var(--wa-form-control-border-radius);border-style:var(--wa-form-control-border-style);border-width:var(--wa-form-control-border-width);cursor:text;color:var(--wa-form-control-value-color);font-size:var(--wa-form-control-value-font-size);font-family:inherit;font-weight:var(--wa-form-control-value-font-weight);line-height:var(--wa-form-control-value-line-height);vertical-align:middle;width:100%;transition:background-color var(--wa-transition-normal),border-color var(--wa-transition-normal),outline-color var(--wa-transition-fast);transition-timing-function:var(--wa-transition-easing);background-color:var(--wa-form-control-background-color);box-shadow:var(--box-shadow);padding:0 var(--wa-form-control-padding-inline);outline:var(--wa-focus-ring-style) var(--wa-focus-ring-width) transparent;outline-offset:var(--wa-focus-ring-offset)}.text-field:focus-within{outline-color:var(--wa-color-focus)}.text-field:has(:disabled){cursor:not-allowed;opacity:.5}:host([appearance=outlined]) .text-field{background-color:var(--wa-form-control-background-color);border-color:var(--wa-form-control-border-color)}:host([appearance=filled]) .text-field{background-color:var(--wa-color-neutral-fill-quiet);border-color:var(--wa-color-neutral-fill-quiet)}:host([appearance=filled-outlined]) .text-field{background-color:var(--wa-color-neutral-fill-quiet);border-color:var(--wa-form-control-border-color)}:host([pill]) .text-field{border-radius:var(--wa-border-radius-pill)!important}.text-field:has(:-webkit-autofill),.text-field:has(:autofill){background-color:var(--wa-color-brand-fill-quiet)!important}.text-field input,.text-field textarea{height:100%;padding:0;border:none;outline:0;box-shadow:none;margin:0;cursor:inherit;-webkit-appearance:none;font:inherit}:is(.text-field input,.text-field textarea):-webkit-autofill,:is(.text-field input,.text-field textarea):-webkit-autofill:active,:is(.text-field input,.text-field textarea):-webkit-autofill:focus,:is(.text-field input,.text-field textarea):-webkit-autofill:hover{-webkit-background-clip:text;background-color:transparent;-webkit-text-fill-color:inherit}input{flex:1 1 auto;min-width:0;height:100%;transition:inherit;background-color:rgb(118 118 118 / 0);height:calc(var(--wa-form-control-height) - var(--border-width) * 2);padding-block:0;color:inherit}input:autofill,input:autofill:active,input:autofill:focus,input:autofill:hover{box-shadow:none;caret-color:var(--wa-form-control-value-color)}input::placeholder{color:var(--wa-form-control-placeholder-color);user-select:none;-webkit-user-select:none}input::-webkit-search-cancel-button,input::-webkit-search-decoration,input::-webkit-search-results-button,input::-webkit-search-results-decoration{-webkit-appearance:none}input:focus{outline:0}textarea:autofill,textarea:autofill:active,textarea:autofill:focus,textarea:autofill:hover{box-shadow:none;caret-color:var(--wa-form-control-value-color)}textarea::placeholder{color:var(--wa-form-control-placeholder-color);user-select:none;-webkit-user-select:none}.end,.start{display:inline-flex;flex:0 0 auto;align-items:center;cursor:default}:is(.start,.end)::slotted(wa-icon){color:var(--wa-color-neutral-on-quiet)}.start::slotted(*){margin-inline-end:var(--wa-form-control-padding-inline)}.end::slotted(*){margin-inline-start:var(--wa-form-control-padding-inline)}.clear,.password-toggle{display:inline-flex;align-items:center;justify-content:center;font-size:inherit;color:var(--wa-color-neutral-on-quiet);border:none;background:0 0;padding:0;transition:var(--wa-transition-normal) color;cursor:pointer;margin-inline-start:var(--wa-form-control-padding-inline)}@media (hover:hover){:is(.clear,.password-toggle):hover{color:color-mix(in oklab,currentColor,var(--wa-color-mix-hover))}}:is(.clear,.password-toggle):active{color:color-mix(in oklab,currentColor,var(--wa-color-mix-active))}:is(.clear,.password-toggle):focus{outline:0}::-ms-reveal{display:none}:host([without-spin-buttons]) input[type=number]{-moz-appearance:textfield}:host([without-spin-buttons]) input[type=number]::-webkit-inner-spin-button,:host([without-spin-buttons]) input[type=number]::-webkit-outer-spin-button{-webkit-appearance:none;display:none}`))},52630:function(t,e,o){o.a(t,async function(t,i){try{o.d(e,{A:function(){return A}});o(74423),o(44114),o(18111),o(22489),o(3362),o(27495),o(62953);var r=o(5124),n=o(67576),a=o(6412),s=o(17051),l=o(42462),h=o(28438),c=o(98779),u=o(27259),d=o(25877),p=o(984),f=o(95010),b=o(9395),v=o(717),w=o(40158),m=o(51920),g=t([w]);w=(g.then?(await g)():g)[0];let x,E=t=>t;var y=Object.defineProperty,k=Object.getOwnPropertyDescriptor,C=(t,e,o,i)=>{for(var r,n=i>1?void 0:i?k(e,o):e,a=t.length-1;a>=0;a--)(r=t[a])&&(n=(i?r(e,o,n):r(n))||n);return i&&n&&y(e,o,n),n};let A=class extends v.A{connectedCallback(){super.connectedCallback(),this.eventController.signal.aborted&&(this.eventController=new AbortController),this.addEventListener("mouseout",this.handleMouseOut),this.open&&(this.open=!1,this.updateComplete.then(()=>{this.open=!0})),this.id||(this.id=(0,f.N)("wa-tooltip-")),this.for&&this.anchor?(this.anchor=null,this.handleForChange()):this.for&&this.handleForChange()}disconnectedCallback(){super.disconnectedCallback(),document.removeEventListener("keydown",this.handleDocumentKeyDown),(0,d.Fw)(this),this.eventController.abort(),this.anchor&&this.removeFromAriaLabelledBy(this.anchor,this.id)}firstUpdated(){this.body.hidden=!this.open,this.open&&(this.popup.active=!0,this.popup.reposition())}hasTrigger(t){return this.trigger.split(" ").includes(t)}addToAriaLabelledBy(t,e){const o=(t.getAttribute("aria-labelledby")||"").split(/\s+/).filter(Boolean);o.includes(e)||(o.push(e),t.setAttribute("aria-labelledby",o.join(" ")))}removeFromAriaLabelledBy(t,e){const o=(t.getAttribute("aria-labelledby")||"").split(/\s+/).filter(Boolean).filter(t=>t!==e);o.length>0?t.setAttribute("aria-labelledby",o.join(" ")):t.removeAttribute("aria-labelledby")}async handleOpenChange(){if(this.open){if(this.disabled)return;const t=new c.k;if(this.dispatchEvent(t),t.defaultPrevented)return void(this.open=!1);document.addEventListener("keydown",this.handleDocumentKeyDown,{signal:this.eventController.signal}),(0,d.AZ)(this),this.body.hidden=!1,this.popup.active=!0,await(0,u.Ud)(this.popup.popup,"show-with-scale"),this.popup.reposition(),this.dispatchEvent(new l.q)}else{const t=new h.L;if(this.dispatchEvent(t),t.defaultPrevented)return void(this.open=!1);document.removeEventListener("keydown",this.handleDocumentKeyDown),(0,d.Fw)(this),await(0,u.Ud)(this.popup.popup,"hide-with-scale"),this.popup.active=!1,this.body.hidden=!0,this.dispatchEvent(new s.Z)}}handleForChange(){const t=this.getRootNode();if(!t)return;const e=this.for?t.getElementById(this.for):null,o=this.anchor;if(e===o)return;const{signal:i}=this.eventController;e&&(this.addToAriaLabelledBy(e,this.id),e.addEventListener("blur",this.handleBlur,{capture:!0,signal:i}),e.addEventListener("focus",this.handleFocus,{capture:!0,signal:i}),e.addEventListener("click",this.handleClick,{signal:i}),e.addEventListener("mouseover",this.handleMouseOver,{signal:i}),e.addEventListener("mouseout",this.handleMouseOut,{signal:i})),o&&(this.removeFromAriaLabelledBy(o,this.id),o.removeEventListener("blur",this.handleBlur,{capture:!0}),o.removeEventListener("focus",this.handleFocus,{capture:!0}),o.removeEventListener("click",this.handleClick),o.removeEventListener("mouseover",this.handleMouseOver),o.removeEventListener("mouseout",this.handleMouseOut)),this.anchor=e}async handleOptionsChange(){this.hasUpdated&&(await this.updateComplete,this.popup.reposition())}handleDisabledChange(){this.disabled&&this.open&&this.hide()}async show(){if(!this.open)return this.open=!0,(0,p.l)(this,"wa-after-show")}async hide(){if(this.open)return this.open=!1,(0,p.l)(this,"wa-after-hide")}render(){return(0,r.qy)(x||(x=E` <wa-popup part="base" exportparts="
popup:base__popup,
arrow:base__arrow
" class="${0}" placement="${0}" distance="${0}" skidding="${0}" flip shift ?arrow="${0}" hover-bridge .anchor="${0}"> <div part="body" class="body"> <slot></slot> </div> </wa-popup> `),(0,a.H)({tooltip:!0,"tooltip-open":this.open}),this.placement,this.distance,this.skidding,!this.withoutArrow,this.anchor)}constructor(){super(...arguments),this.placement="top",this.disabled=!1,this.distance=8,this.open=!1,this.skidding=0,this.showDelay=150,this.hideDelay=0,this.trigger="hover focus",this.withoutArrow=!1,this.for=null,this.anchor=null,this.eventController=new AbortController,this.handleBlur=()=>{this.hasTrigger("focus")&&this.hide()},this.handleClick=()=>{this.hasTrigger("click")&&(this.open?this.hide():this.show())},this.handleFocus=()=>{this.hasTrigger("focus")&&this.show()},this.handleDocumentKeyDown=t=>{"Escape"===t.key&&this.open&&(0,d.a0)(this)&&(t.preventDefault(),t.stopPropagation(),this.hide())},this.handleMouseOver=()=>{this.hasTrigger("hover")&&(clearTimeout(this.hoverTimeout),this.hoverTimeout=window.setTimeout(()=>this.show(),this.showDelay))},this.handleMouseOut=()=>{if(this.hasTrigger("hover")){var t;const e=Boolean(null===(t=this.anchor)||void 0===t?void 0:t.matches(":hover")),o=this.matches(":hover");if(e||o)return;clearTimeout(this.hoverTimeout),e||o||(this.hoverTimeout=window.setTimeout(()=>{this.hide()},this.hideDelay))}}}};A.css=m.A,A.dependencies={"wa-popup":w.A},C([(0,n.P)("slot:not([name])")],A.prototype,"defaultSlot",2),C([(0,n.P)(".body")],A.prototype,"body",2),C([(0,n.P)("wa-popup")],A.prototype,"popup",2),C([(0,n.MZ)()],A.prototype,"placement",2),C([(0,n.MZ)({type:Boolean,reflect:!0})],A.prototype,"disabled",2),C([(0,n.MZ)({type:Number})],A.prototype,"distance",2),C([(0,n.MZ)({type:Boolean,reflect:!0})],A.prototype,"open",2),C([(0,n.MZ)({type:Number})],A.prototype,"skidding",2),C([(0,n.MZ)({attribute:"show-delay",type:Number})],A.prototype,"showDelay",2),C([(0,n.MZ)({attribute:"hide-delay",type:Number})],A.prototype,"hideDelay",2),C([(0,n.MZ)()],A.prototype,"trigger",2),C([(0,n.MZ)({attribute:"without-arrow",type:Boolean,reflect:!0})],A.prototype,"withoutArrow",2),C([(0,n.MZ)()],A.prototype,"for",2),C([(0,n.wk)()],A.prototype,"anchor",2),C([(0,b.w)("open",{waitUntilFirstUpdate:!0})],A.prototype,"handleOpenChange",1),C([(0,b.w)("for")],A.prototype,"handleForChange",1),C([(0,b.w)(["distance","placement","skidding"])],A.prototype,"handleOptionsChange",1),C([(0,b.w)("disabled")],A.prototype,"handleDisabledChange",1),A=C([(0,n.EM)("wa-tooltip")],A),i()}catch(x){i(x)}})},51920:function(t,e,o){o.d(e,{A:function(){return r}});let i;var r=(0,o(5124).AH)(i||(i=(t=>t)`:host{--max-width:30ch;display:inline-block;position:absolute;color:var(--wa-tooltip-content-color);font-size:var(--wa-tooltip-font-size);line-height:var(--wa-tooltip-line-height);text-align:start;white-space:normal}.tooltip{--arrow-size:var(--wa-tooltip-arrow-size);--arrow-color:var(--wa-tooltip-background-color)}.tooltip::part(popup){z-index:1000}.tooltip[placement^=top]::part(popup){transform-origin:bottom}.tooltip[placement^=bottom]::part(popup){transform-origin:top}.tooltip[placement^=left]::part(popup){transform-origin:right}.tooltip[placement^=right]::part(popup){transform-origin:left}.body{display:block;width:max-content;max-width:var(--max-width);border-radius:var(--wa-tooltip-border-radius);background-color:var(--wa-tooltip-background-color);border:var(--wa-tooltip-border-width) var(--wa-tooltip-border-style) var(--wa-tooltip-border-color);padding:.25em .5em;user-select:none;-webkit-user-select:none}.tooltip{--popup-border-width:var(--wa-tooltip-border-width)}.tooltip::part(arrow){border-bottom:var(--wa-tooltip-border-width) var(--wa-tooltip-border-style) var(--wa-tooltip-border-color);border-right:var(--wa-tooltip-border-width) var(--wa-tooltip-border-style) var(--wa-tooltip-border-color)}`))},37541:function(t,e,o){o.d(e,{I:function(){return i}});class i extends Event{constructor(){super("wa-clear",{bubbles:!0,cancelable:!1,composed:!0})}}},984:function(t,e,o){o.d(e,{l:function(){return i}});o(3362);function i(t,e){return new Promise(o=>{t.addEventListener(e,function i(r){r.target===t&&(t.removeEventListener(e,i),o())})})}},95010:function(t,e,o){o.d(e,{q:function(){return r},N:function(){return n}});o(54743),o(11745),o(16573),o(78100),o(77936),o(21489),o(48140),o(75044),o(21903),o(91134),o(28845),o(373),o(37467),o(44732),o(79577),o(16632),o(34226),o(9486),o(20456);let i=(t=21)=>{let e="",o=crypto.getRandomValues(new Uint8Array(t|=0));for(;t--;)e+="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict"[63&o[t]];return e};function r(t,e,o){const i=t=>Object.is(t,-0)?0:t;return i(t<e?e:t>o?o:t)}function n(t=""){return`${t}${i()}`}},28225:function(t,e,o){o.d(e,{U:function(){return i}});o(74423),o(62953);function i(t,e){const o=t.metaKey||t.ctrlKey||t.shiftKey||t.altKey;"Enter"!==t.key||o||setTimeout(()=>{t.defaultPrevented||t.isComposing||function(t){let e=null;"form"in t&&(e=t.form);!e&&"getForm"in t&&(e=t.getForm());if(!e)return;const o=[...e.elements];if(1===o.length)return void e.requestSubmit(null);const i=o.find(t=>"submit"===t.type&&!t.matches(":disabled"));if(!i)return;["input","button"].includes(i.localName)?e.requestSubmit(i):i.click()}(e)})}},49546:function(t,e,o){o.d(e,{Y:function(){return i}});o(44114);const i=(t={})=>{let{validationElement:e,validationProperty:o}=t;e||(e=Object.assign(document.createElement("input"),{required:!0})),o||(o="value");const i={observedAttributes:["required"],message:e.validationMessage,checkValidity(t){var e;const r={message:"",isValid:!0,invalidKeys:[]};if(!(null!==(e=t.required)&&void 0!==e?e:t.hasAttribute("required")))return r;return!t[o]&&(r.message="function"==typeof i.message?i.message(t):i.message||"",r.isValid=!1,r.invalidKeys.push("valueMissing")),r}};return i}},15477:function(t,e,o){o.d(e,{A:function(){return r}});let i;var r=(0,o(5124).AH)(i||(i=(t=>t)`:host{display:flex;flex-direction:column}[part~=form-control]{display:contents}:is([part~=form-control-label],[part~=label]).has-label,:is([part~=form-control-label],[part~=label]):has(:not(:empty)){display:inline-flex;color:var(--wa-form-control-label-color);font-weight:var(--wa-form-control-label-font-weight);line-height:var(--wa-form-control-label-line-height);margin-block-end:0.5em}:host([required]) :is([part~=form-control-label],[part~=label])::after{content:var(--wa-form-control-required-content);margin-inline-start:var(--wa-form-control-required-content-offset);color:var(--wa-form-control-required-content-color)}[part~=hint]{display:block;color:var(--wa-form-control-hint-color);font-weight:var(--wa-form-control-hint-font-weight);line-height:var(--wa-form-control-hint-line-height);margin-block-start:0.5em;font-size:var(--wa-font-size-smaller)}[part~=hint]:not(.has-slotted,.has-hint){display:none}`))},2209:function(t,e,o){o.d(e,{LV:function(){return d}});o(89463),o(16280),o(72712),o(55081),o(18111),o(61701),o(18237),o(45367),o(92731),o(3362),o(84864),o(57465),o(27495),o(88454),o(29452),o(62953);const i=Symbol("Comlink.proxy"),r=Symbol("Comlink.endpoint"),n=Symbol("Comlink.releaseProxy"),a=Symbol("Comlink.finalizer"),s=Symbol("Comlink.thrown"),l=t=>"object"==typeof t&&null!==t||"function"==typeof t,h=new Map([["proxy",{canHandle:t=>l(t)&&t[i],serialize(t){const{port1:e,port2:o}=new MessageChannel;return c(t,e),[o,[o]]},deserialize(t){return t.start(),d(t)}}],["throw",{canHandle:t=>l(t)&&s in t,serialize({value:t}){let e;return e=t instanceof Error?{isError:!0,value:{message:t.message,name:t.name,stack:t.stack}}:{isError:!1,value:t},[e,[]]},deserialize(t){if(t.isError)throw Object.assign(new Error(t.value.message),t.value);throw t.value}}]]);function c(t,e=globalThis,o=["*"]){e.addEventListener("message",function r(n){if(!n||!n.data)return;if(!function(t,e){for(const o of t){if(e===o||"*"===o)return!0;if(o instanceof RegExp&&o.test(e))return!0}return!1}(o,n.origin))return void console.warn(`Invalid origin '${n.origin}' for comlink proxy`);const{id:l,type:h,path:d}=Object.assign({path:[]},n.data),p=(n.data.argumentList||[]).map(k);let f;try{const e=d.slice(0,-1).reduce((t,e)=>t[e],t),o=d.reduce((t,e)=>t[e],t);switch(h){case"GET":f=o;break;case"SET":e[d.slice(-1)[0]]=k(n.data.value),f=!0;break;case"APPLY":f=o.apply(e,p);break;case"CONSTRUCT":f=function(t){return Object.assign(t,{[i]:!0})}(new o(...p));break;case"ENDPOINT":{const{port1:e,port2:o}=new MessageChannel;c(t,o),f=function(t,e){return g.set(t,e),t}(e,[e])}break;case"RELEASE":f=void 0;break;default:return}}catch(b){f={value:b,[s]:0}}Promise.resolve(f).catch(t=>({value:t,[s]:0})).then(o=>{const[i,n]=y(o);e.postMessage(Object.assign(Object.assign({},i),{id:l}),n),"RELEASE"===h&&(e.removeEventListener("message",r),u(e),a in t&&"function"==typeof t[a]&&t[a]())}).catch(t=>{const[o,i]=y({value:new TypeError("Unserializable return value"),[s]:0});e.postMessage(Object.assign(Object.assign({},o),{id:l}),i)})}),e.start&&e.start()}function u(t){(function(t){return"MessagePort"===t.constructor.name})(t)&&t.close()}function d(t,e){const o=new Map;return t.addEventListener("message",function(t){const{data:e}=t;if(!e||!e.id)return;const i=o.get(e.id);if(i)try{i(e)}finally{o.delete(e.id)}}),w(t,o,[],e)}function p(t){if(t)throw new Error("Proxy has been released and is not useable")}function f(t){return C(t,new Map,{type:"RELEASE"}).then(()=>{u(t)})}const b=new WeakMap,v="FinalizationRegistry"in globalThis&&new FinalizationRegistry(t=>{const e=(b.get(t)||0)-1;b.set(t,e),0===e&&f(t)});function w(t,e,o=[],i=function(){}){let a=!1;const s=new Proxy(i,{get(i,r){if(p(a),r===n)return()=>{!function(t){v&&v.unregister(t)}(s),f(t),e.clear(),a=!0};if("then"===r){if(0===o.length)return{then:()=>s};const i=C(t,e,{type:"GET",path:o.map(t=>t.toString())}).then(k);return i.then.bind(i)}return w(t,e,[...o,r])},set(i,r,n){p(a);const[s,l]=y(n);return C(t,e,{type:"SET",path:[...o,r].map(t=>t.toString()),value:s},l).then(k)},apply(i,n,s){p(a);const l=o[o.length-1];if(l===r)return C(t,e,{type:"ENDPOINT"}).then(k);if("bind"===l)return w(t,e,o.slice(0,-1));const[h,c]=m(s);return C(t,e,{type:"APPLY",path:o.map(t=>t.toString()),argumentList:h},c).then(k)},construct(i,r){p(a);const[n,s]=m(r);return C(t,e,{type:"CONSTRUCT",path:o.map(t=>t.toString()),argumentList:n},s).then(k)}});return function(t,e){const o=(b.get(e)||0)+1;b.set(e,o),v&&v.register(t,e,t)}(s,t),s}function m(t){const e=t.map(y);return[e.map(t=>t[0]),(o=e.map(t=>t[1]),Array.prototype.concat.apply([],o))];var o}const g=new WeakMap;function y(t){for(const[e,o]of h)if(o.canHandle(t)){const[i,r]=o.serialize(t);return[{type:"HANDLER",name:e,value:i},r]}return[{type:"RAW",value:t},g.get(t)||[]]}function k(t){switch(t.type){case"HANDLER":return h.get(t.name).deserialize(t.value);case"RAW":return t.value}}function C(t,e,o,i){return new Promise(r=>{const n=new Array(4).fill(0).map(()=>Math.floor(Math.random()*Number.MAX_SAFE_INTEGER).toString(16)).join("-");e.set(n,r),t.start&&t.start(),t.postMessage(Object.assign({id:n},o),i)})}},34514:function(t,e,o){o.d(e,{V:function(){return a}});o(16280),o(62953);var i=o(5055),r=o(42017),n=o(63937);const a=(0,r.u$)(class extends r.WL{render(t){return t}update(t,[e]){if(e===i.c0||e===i.s6)return e;const o=t.element,a=t.name;if(t.type===r.OA.PROPERTY){if(e===o[a])return i.c0}else if(t.type===r.OA.BOOLEAN_ATTRIBUTE){if(!!e===o.hasAttribute(a))return i.c0}else if(t.type===r.OA.ATTRIBUTE&&o.getAttribute(a)===e+"")return i.c0;return(0,n.mY)(t),e}constructor(t){if(super(t),t.type!==r.OA.PROPERTY&&t.type!==r.OA.ATTRIBUTE&&t.type!==r.OA.BOOLEAN_ATTRIBUTE)throw Error("The `live` directive is not allowed on child or event bindings");if(!(0,n.Rt)(t))throw Error("`live` bindings can only contain a single expression")}})},89784:function(t,e,o){o.d(e,{W:function(){return s}});o(16280),o(74423),o(72712),o(18111),o(18237),o(27495),o(17642),o(58004),o(33853),o(45876),o(32475),o(15024),o(31698),o(25440),o(62953);var i=o(5055),r=o(42017);const n="important",a=" !"+n,s=(0,r.u$)(class extends r.WL{render(t){return Object.keys(t).reduce((e,o)=>{const i=t[o];return null==i?e:e+`${o=o.includes("-")?o:o.replace(/(?:^(webkit|moz|ms|o)|)(?=[A-Z])/g,"-$&").toLowerCase()}:${i};`},"")}update(t,[e]){const{style:o}=t.element;if(void 0===this.ft)return this.ft=new Set(Object.keys(e)),this.render(e);for(const i of this.ft)null==e[i]&&(this.ft.delete(i),i.includes("-")?o.removeProperty(i):o[i]=null);for(const i in e){const t=e[i];if(null!=t){this.ft.add(i);const e="string"==typeof t&&t.endsWith(a);i.includes("-")||e?o.setProperty(i,e?t.slice(0,-11):t,e?n:""):o[i]=t}}return i.c0}constructor(t){var e;if(super(t),t.type!==r.OA.ATTRIBUTE||"style"!==t.name||(null===(e=t.strings)||void 0===e?void 0:e.length)>2)throw Error("The `styleMap` directive must be used in the `style` attribute and must be the only part in the attribute.")}})}}]);