UNPKG

iobroker.lovelace

Version:

With this adapter you can build visualization for ioBroker with Home Assistant Lovelace UI

5 lines 41 kB
/*! For license information please see 10653.fb63d928cdd4b735.js.LICENSE.txt */ "use strict";(self.rspackChunkhome_assistant_frontend=self.rspackChunkhome_assistant_frontend||[]).push([[10653],{12451:function(t,e,i){i.d(e,{O:function(){return s},i:function(){return n.is}});var o=i(5124),n=i(12130);class s extends o.WF{click(){if(this.mdcRoot)return this.mdcRoot.focus(),void this.mdcRoot.click();super.click()}createFoundation(){void 0!==this.mdcFoundation&&this.mdcFoundation.destroy(),this.mdcFoundationClass&&(this.mdcFoundation=new this.mdcFoundationClass(this.createAdapter()),this.mdcFoundation.init())}firstUpdated(){this.createFoundation()}}},12130:function(t,e,i){i.d(e,{SE:function(){return c},U9:function(){return l},hP:function(){return o},is:function(){return n}});i(44114);const o=t=>t.nodeType===Node.ELEMENT_NODE;function n(t){return{addClass:e=>{t.classList.add(e)},removeClass:e=>{t.classList.remove(e)},hasClass:e=>t.classList.contains(e)}}let s=!1;const r=()=>{},a={get passive(){return s=!0,!1}};document.addEventListener("x",r,a),document.removeEventListener("x",r);const l=(t=window.document)=>{let e=t.activeElement;const i=[];if(!e)return i;for(;e&&(i.push(e),e.shadowRoot);)e=e.shadowRoot.activeElement;return i},c=t=>{const e=l();if(!e.length)return!1;const i=e[e.length-1],o=new Event("check-if-focused",{bubbles:!0,composed:!0});let n=[];const s=t=>{n=t.composedPath()};return document.body.addEventListener("check-if-focused",s),i.dispatchEvent(o),document.body.removeEventListener("check-if-focused",s),-1!==n.indexOf(t)}},77957:function(t,e,i){var o=i(76080),n=i(79504),s=i(47055),r=i(48981),a=i(56969),l=i(26198),c=i(2360),h=i(35370),d=Array,u=n([].push);t.exports=function(t,e,i,n){for(var p,f,v,b=r(t),w=s(b),g=o(e,i),m=c(null),y=l(w),k=0;y>k;k++)v=w[k],(f=a(g(v,k,b)))in m?u(m[f],v):m[f]=[v];if(n&&(p=n(b))!==d)for(f in m)m[f]=h(p,m[f]);return m}},46058:function(t,e,i){var o=i(46518),n=i(77957),s=i(6469);o({target:"Array",proto:!0},{group:function(t){return n(this,t,arguments.length>1?arguments[1]:void 0)}}),s("group")},65722:function(t,e,i){i.d(e,{A:function(){return o}});i(89463),i(66412),i(16280),i(3362),i(62953);function o(t){var e,i,o,s=2;for("undefined"!=typeof Symbol&&(i=Symbol.asyncIterator,o=Symbol.iterator);s--;){if(i&&null!=(e=t[i]))return e.call(t);if(o&&null!=(e=t[o]))return new n(e.call(t));i="@@asyncIterator",o="@@iterator"}throw new TypeError("Object is not async iterable")}function n(t){function e(t){if(Object(t)!==t)return Promise.reject(new TypeError(t+" is not an object."));var e=t.done;return Promise.resolve(t.value).then(function(t){return{value:t,done:e}})}return n=function(t){this.s=t,this.n=t.next},n.prototype={s:null,n:null,next:function(){return e(this.n.apply(this.s,arguments))},return:function(t){var i=this.s.return;return void 0===i?Promise.resolve({value:t,done:!0}):e(i.apply(this.s,arguments))},throw:function(t){var i=this.s.return;return void 0===i?Promise.reject(t):e(i.apply(this.s,arguments))}},new n(t)}},93900:function(t,e,i){i.a(t,async function(t,e){try{i(3362),i(27495),i(62953);var o=i(5124),n=i(67576),s=i(6412),r=i(63672),a=i(17051),l=i(42462),c=i(28438),h=i(98779),d=i(27259),u=i(25877),p=i(31247),f=i(4444),v=i(92070),b=i(9395),w=i(717),g=i(17060),m=i(88496),y=i(91470),k=t([m,g]);[m,g]=k.then?(await k)():k;let $,E,I,D=t=>t;var C=Object.defineProperty,x=Object.getOwnPropertyDescriptor,A=(t,e,i,o)=>{for(var n,s=o>1?void 0:o?x(e,i):e,r=t.length-1;r>=0;r--)(n=t[r])&&(s=(o?n(e,i,s):n(s))||s);return o&&s&&C(e,i,s),s};let _=class extends w.A{firstUpdated(){this.open&&(this.addOpenListeners(),this.dialog.showModal(),(0,f.JG)(this))}disconnectedCallback(){super.disconnectedCallback(),(0,f.I7)(this),this.removeOpenListeners()}async requestClose(t){const e=new c.L({source:t});if(this.dispatchEvent(e),e.defaultPrevented)return this.open=!0,void(0,d.Ud)(this.dialog,"pulse");this.removeOpenListeners(),await(0,d.Ud)(this.dialog,"hide"),this.open=!1,this.dialog.close(),(0,f.I7)(this);const i=this.originalTrigger;"function"==typeof(null==i?void 0:i.focus)&&setTimeout(()=>i.focus()),this.dispatchEvent(new a.Z)}addOpenListeners(){document.addEventListener("keydown",this.handleDocumentKeyDown),(0,u.AZ)(this)}removeOpenListeners(){document.removeEventListener("keydown",this.handleDocumentKeyDown),(0,u.Fw)(this)}handleDialogCancel(t){t.preventDefault(),!this.dialog.classList.contains("hide")&&t.target===this.dialog&&(0,u.a0)(this)&&this.requestClose(this.dialog)}handleDialogClick(t){const e=t.target.closest('[data-dialog="close"]');e&&(t.stopPropagation(),this.requestClose(e))}async handleDialogPointerDown(t){t.target===this.dialog&&(this.lightDismiss?this.requestClose(this.dialog):await(0,d.Ud)(this.dialog,"pulse"))}handleOpenChange(){this.open&&!this.dialog.open?this.show():!this.open&&this.dialog.open&&(this.open=!0,this.requestClose(this.dialog))}async show(){const t=new h.k;this.dispatchEvent(t),t.defaultPrevented?this.open=!1:(this.addOpenListeners(),this.originalTrigger=document.activeElement,this.open=!0,this.dialog.showModal(),(0,f.JG)(this),requestAnimationFrame(()=>{const t=this.querySelector("[autofocus]");t&&"function"==typeof t.focus?t.focus():this.dialog.focus()}),await(0,d.Ud)(this.dialog,"show"),this.dispatchEvent(new l.q))}render(){var t;const e=!this.withoutHeader,i=this.hasUpdated?this.hasSlotController.test("footer"):this.withFooter;return(0,o.qy)($||($=D` <dialog aria-labelledby="${0}" aria-describedby="${0}" part="dialog" class="${0}" @cancel="${0}" @click="${0}" @pointerdown="${0}"> ${0} <div part="body" class="body"><slot></slot></div> ${0} </dialog> `),null!==(t=this.ariaLabelledby)&&void 0!==t?t:"title",(0,r.J)(this.ariaDescribedby),(0,s.H)({dialog:!0,open:this.open}),this.handleDialogCancel,this.handleDialogClick,this.handleDialogPointerDown,e?(0,o.qy)(E||(E=D` <header part="header" class="header"> <h2 part="title" class="title" id="title"> <slot name="label"> ${0} </slot> </h2> <div part="header-actions" class="header-actions"> <slot name="header-actions"></slot> <wa-button part="close-button" exportparts="base:close-button__base" class="close" appearance="plain" @click="${0}"> <wa-icon name="xmark" label="${0}" library="system" variant="solid"></wa-icon> </wa-button> </div> </header> `),this.label.length>0?this.label:String.fromCharCode(8203),t=>this.requestClose(t.target),this.localize.term("close")):"",i?(0,o.qy)(I||(I=D` <footer part="footer" class="footer"> <slot name="footer"></slot> </footer> `)):"")}constructor(){super(...arguments),this.localize=new g.c(this),this.hasSlotController=new v.X(this,"footer","header-actions","label"),this.open=!1,this.label="",this.withoutHeader=!1,this.lightDismiss=!1,this.withFooter=!1,this.handleDocumentKeyDown=t=>{"Escape"===t.key&&this.open&&(0,u.a0)(this)&&(t.preventDefault(),t.stopPropagation(),this.requestClose(this.dialog))}}};_.css=y.A,A([(0,n.P)(".dialog")],_.prototype,"dialog",2),A([(0,n.MZ)({type:Boolean,reflect:!0})],_.prototype,"open",2),A([(0,n.MZ)({reflect:!0})],_.prototype,"label",2),A([(0,n.MZ)({attribute:"without-header",type:Boolean,reflect:!0})],_.prototype,"withoutHeader",2),A([(0,n.MZ)({attribute:"light-dismiss",type:Boolean})],_.prototype,"lightDismiss",2),A([(0,n.MZ)({attribute:"aria-labelledby"})],_.prototype,"ariaLabelledby",2),A([(0,n.MZ)({attribute:"aria-describedby"})],_.prototype,"ariaDescribedby",2),A([(0,n.MZ)({attribute:"with-footer",type:Boolean})],_.prototype,"withFooter",2),A([(0,b.w)("open",{waitUntilFirstUpdate:!0})],_.prototype,"handleOpenChange",1),_=A([(0,n.EM)("wa-dialog")],_),o.S$||(document.addEventListener("click",t=>{const e=t.target.closest("[data-dialog]");if(e instanceof Element){const[t,i]=(0,p.v)(e.getAttribute("data-dialog")||"");if("open"===t&&null!=i&&i.length){const t=e.getRootNode().getElementById(i);"wa-dialog"===(null==t?void 0:t.localName)?t.open=!0:console.warn(`A dialog with an ID of "${i}" could not be found in this document.`)}}}),document.addEventListener("pointerdown",()=>{})),e()}catch($){e($)}})},91470:function(t,e,i){i.d(e,{A:function(){return n}});let o;var n=(0,i(5124).AH)(o||(o=(t=>t)`:host{--width:31rem;--spacing:var(--wa-space-l);--backdrop-filter:none;--show-duration:200ms;--hide-duration:200ms;display:none}:host([open]){display:block}.dialog{display:flex;flex-direction:column;top:0;right:0;bottom:0;left:0;width:var(--width);max-width:calc(100% - var(--wa-space-2xl));max-height:calc(100% - var(--wa-space-2xl));color:inherit;background-color:var(--wa-color-surface-raised);border-radius:var(--wa-panel-border-radius);border:none;box-shadow:var(--wa-shadow-l);padding:0;margin:auto}.dialog.show{animation:show-dialog var(--show-duration) ease}.dialog.show::backdrop{animation:show-backdrop var(--show-duration,200ms) ease}.dialog.hide{animation:show-dialog var(--hide-duration) ease reverse}.dialog.hide::backdrop{animation:show-backdrop var(--hide-duration,200ms) ease reverse}.dialog.pulse{animation:pulse 250ms ease}.dialog:focus{outline:0}@media screen and (max-width:420px){.dialog{max-height:80vh}}.open{display:flex;opacity:1}.header{flex:0 0 auto;display:flex;flex-wrap:nowrap;padding-inline-start:var(--spacing);padding-block-end:0;padding-inline-end:calc(var(--spacing) - var(--wa-form-control-padding-block));padding-block-start:calc(var(--spacing) - var(--wa-form-control-padding-block))}.title{align-self:center;flex:1 1 auto;font-family:inherit;font-size:var(--wa-font-size-l);font-weight:var(--wa-font-weight-heading);line-height:var(--wa-line-height-condensed);margin:0}.header-actions{align-self:start;display:flex;flex-shrink:0;flex-wrap:wrap;justify-content:end;gap:var(--wa-space-2xs);padding-inline-start:var(--spacing)}.header-actions ::slotted(wa-button),.header-actions wa-button{flex:0 0 auto;display:flex;align-items:center}.body{flex:1 1 auto;display:block;padding:var(--spacing);overflow:auto;-webkit-overflow-scrolling:touch}.body:focus{outline:0}.body:focus-visible{outline:var(--wa-focus-ring);outline-offset:var(--wa-focus-ring-offset)}.footer{flex:0 0 auto;display:flex;flex-wrap:wrap;gap:var(--wa-space-xs);justify-content:end;padding:var(--spacing);padding-block-start:0}.footer ::slotted(wa-button:not(:first-of-type)){margin-inline-start:var(--wa-spacing-xs)}.dialog::backdrop{background-color:var(--wa-color-overlay-modal,rgb(0 0 0 / .25));-webkit-backdrop-filter:var(--backdrop-filter);backdrop-filter:var(--backdrop-filter)}@keyframes pulse{0%{scale:1}50%{scale:1.02}100%{scale:1}}@keyframes show-dialog{from{opacity:0;scale:0.8}to{opacity:1;scale:1}}@keyframes show-backdrop{from{opacity:0}to{opacity:1}}@media (forced-colors:active){.dialog{border:solid 1px #fff}}`))},68825:function(t,e,i){i(62953);var o=i(67576),n=i(9395),s=i(717);let r;var a=(0,i(5124).AH)(r||(r=(t=>t)`:host{--color:var(--wa-color-surface-border);--width:var(--wa-border-width-s);--spacing:var(--wa-space-m)}:host(:not([orientation=vertical])){display:block;border-top:solid var(--width) var(--color);margin:var(--spacing) 0}:host([orientation=vertical]){display:inline-block;height:100%;border-inline-start:solid var(--width) var(--color);margin:0 var(--spacing);min-block-size:1lh}`)),l=Object.defineProperty,c=Object.getOwnPropertyDescriptor,h=(t,e,i,o)=>{for(var n,s=o>1?void 0:o?c(e,i):e,r=t.length-1;r>=0;r--)(n=t[r])&&(s=(o?n(e,i,s):n(s))||s);return o&&s&&l(e,i,s),s};let d=class extends s.A{connectedCallback(){super.connectedCallback(),this.setAttribute("role","separator")}handleVerticalChange(){this.setAttribute("aria-orientation",this.orientation)}constructor(){super(...arguments),this.orientation="horizontal"}};d.css=a,h([(0,o.MZ)({reflect:!0})],d.prototype,"orientation",2),h([(0,n.w)("orientation")],d.prototype,"handleVerticalChange",1),d=h([(0,o.EM)("wa-divider")],d)},61366:function(t,e,i){i.a(t,async function(t,e){try{i(74423),i(3362),i(17642),i(58004),i(33853),i(45876),i(32475),i(15024),i(31698),i(62953);var o=i(5124),n=i(67576),s=i(6412),r=i(63672),a=i(17051),l=i(42462),c=i(28438),h=i(98779),d=i(27259),u=i(25877),p=i(984),f=i(95010),v=i(9395),b=i(717),w=i(40158),g=i(10416),m=t([w]);w=(m.then?(await m)():m)[0];let x,A=t=>t;var y=Object.defineProperty,k=Object.getOwnPropertyDescriptor,C=(t,e,i,o)=>{for(var n,s=o>1?void 0:o?k(e,i):e,r=t.length-1;r>=0;r--)(n=t[r])&&(s=(o?n(e,i,s):n(s))||s);return o&&s&&y(e,i,s),s};const $=new Set;let E=class extends b.A{connectedCallback(){super.connectedCallback(),this.id||(this.id=(0,f.N)("wa-popover-")),this.eventController.signal.aborted&&(this.eventController=new AbortController),this.for&&this.anchor&&(this.anchor=null,this.handleForChange())}disconnectedCallback(){super.disconnectedCallback(),document.removeEventListener("keydown",this.handleDocumentKeyDown),(0,u.Fw)(this),this.eventController.abort()}firstUpdated(){this.open&&this.handleOpenChange()}updated(t){t.has("open")&&this.customStates.set("open",this.open)}async handleOpenChange(){if(this.open){const t=new h.k;if(this.dispatchEvent(t),t.defaultPrevented)return void(this.open=!1);$.forEach(t=>t.open=!1),document.addEventListener("keydown",this.handleDocumentKeyDown,{signal:this.eventController.signal}),document.addEventListener("click",this.handleDocumentClick,{signal:this.eventController.signal}),this.trapFocus?this.dialog.showModal():this.dialog.show(),this.popup.active=!0,$.add(this),(0,u.AZ)(this),requestAnimationFrame(()=>{const t=this.querySelector("[autofocus]");t&&"function"==typeof t.focus?t.focus():this.dialog.focus()}),this.popup.popup||await this.popup.updateComplete,await(0,d.Ud)(this.popup.popup,"show-with-scale"),this.popup.reposition(),this.dispatchEvent(new l.q)}else{const t=new c.L;if(this.dispatchEvent(t),t.defaultPrevented)return void(this.open=!0);document.removeEventListener("keydown",this.handleDocumentKeyDown),document.removeEventListener("click",this.handleDocumentClick),$.delete(this),(0,u.Fw)(this),await(0,d.Ud)(this.popup.popup,"hide-with-scale"),this.popup.active=!1,this.dialog.close(),this.dispatchEvent(new a.Z)}}handleForChange(){const t=this.getRootNode();if(!t)return;const e=this.for?t.getElementById(this.for):null,i=this.anchor;if(e===i)return;const{signal:o}=this.eventController;e&&e.addEventListener("click",this.handleAnchorClick,{signal:o}),i&&i.removeEventListener("click",this.handleAnchorClick),this.anchor=e,this.for&&!e&&console.warn(`A popover was assigned to an element with an ID of "${this.for}" but the element could not be found.`,this)}async handleOptionsChange(){this.hasUpdated&&(await this.updateComplete,this.popup.reposition())}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")}handleDialogCancel(t){t.preventDefault(),this.dialog.classList.contains("hide")||(this.open=!1)}render(){return(0,o.qy)(x||(x=A` <dialog aria-labelledby="${0}" aria-describedby="${0}" part="dialog" class="dialog" @cancel="${0}"> <wa-popup part="popup" exportparts=" popup:popup__popup, arrow:popup__arrow " class="${0}" placement="${0}" distance="${0}" skidding="${0}" flip shift ?arrow="${0}" .anchor="${0}" .autoSize="${0}" .autoSizePadding="${0}"> <div part="body" class="body" @click="${0}"> <slot></slot> </div> </wa-popup> </dialog> `),(0,r.J)(this.ariaLabelledby),(0,r.J)(this.ariaDescribedby),this.handleDialogCancel,(0,s.H)({popover:!0,"popover-open":this.open}),this.placement,this.distance,this.skidding,!this.withoutArrow,this.anchor,this.autoSize,this.autoSizePadding,this.handleBodyClick)}constructor(){super(...arguments),this.anchor=null,this.placement="top",this.open=!1,this.distance=8,this.skidding=0,this.for=null,this.withoutArrow=!1,this.autoSizePadding=0,this.trapFocus=!1,this.eventController=new AbortController,this.handleAnchorClick=()=>{this.open=!this.open},this.handleBodyClick=t=>{t.stopPropagation();t.target.closest('[data-popover="close"]')&&(this.open=!1)},this.handleDocumentKeyDown=t=>{"Escape"===t.key&&this.open&&(0,u.a0)(this)&&(t.preventDefault(),t.stopPropagation(),this.open=!1,this.anchor&&"function"==typeof this.anchor.focus&&this.anchor.focus())},this.handleDocumentClick=t=>{this.anchor&&t.composedPath().includes(this.anchor)||t.composedPath().includes(this)||(this.open=!1)}}};E.css=g.A,E.dependencies={"wa-popup":w.A},C([(0,n.P)("dialog")],E.prototype,"dialog",2),C([(0,n.P)(".body")],E.prototype,"body",2),C([(0,n.P)("wa-popup")],E.prototype,"popup",2),C([(0,n.wk)()],E.prototype,"anchor",2),C([(0,n.MZ)()],E.prototype,"placement",2),C([(0,n.MZ)({type:Boolean,reflect:!0})],E.prototype,"open",2),C([(0,n.MZ)({type:Number})],E.prototype,"distance",2),C([(0,n.MZ)({type:Number})],E.prototype,"skidding",2),C([(0,n.MZ)()],E.prototype,"for",2),C([(0,n.MZ)({attribute:"without-arrow",type:Boolean,reflect:!0})],E.prototype,"withoutArrow",2),C([(0,n.MZ)({attribute:"auto-size"})],E.prototype,"autoSize",2),C([(0,n.MZ)({attribute:"auto-size-padding",type:Number})],E.prototype,"autoSizePadding",2),C([(0,n.MZ)({attribute:"trap-focus",type:Boolean})],E.prototype,"trapFocus",2),C([(0,n.MZ)({attribute:"aria-labelledby"})],E.prototype,"ariaLabelledby",2),C([(0,n.MZ)({attribute:"aria-describedby"})],E.prototype,"ariaDescribedby",2),C([(0,v.w)("open",{waitUntilFirstUpdate:!0})],E.prototype,"handleOpenChange",1),C([(0,v.w)("for")],E.prototype,"handleForChange",1),C([(0,v.w)(["distance","placement","skidding"])],E.prototype,"handleOptionsChange",1),E=C([(0,n.EM)("wa-popover")],E),e()}catch(x){e(x)}})},10416:function(t,e,i){i.d(e,{A:function(){return n}});let o;var n=(0,i(5124).AH)(o||(o=(t=>t)`:host{--arrow-size:0.375rem;--max-width:25rem;--show-duration:100ms;--hide-duration:100ms;display:contents;font-size:var(--wa-font-size-m);line-height:var(--wa-line-height-normal);text-align:start;white-space:normal}.dialog{display:none;position:fixed;inset:0;width:100%;height:100%;margin:0;padding:0;border:none;background:0 0;overflow:visible;pointer-events:none}.dialog:focus{outline:0}.dialog[open]{display:block}.popover{--arrow-size:inherit;--popup-border-width:var(--wa-panel-border-width);--show-duration:inherit;--hide-duration:inherit;pointer-events:auto}.popover::part(arrow){background-color:var(--wa-color-surface-default);border-top:none;border-left:none;border-bottom:solid var(--wa-panel-border-width) var(--wa-color-surface-border);border-right:solid var(--wa-panel-border-width) var(--wa-color-surface-border);box-shadow:none}.popover[placement^=top]::part(popup){transform-origin:bottom}.popover[placement^=bottom]::part(popup){transform-origin:top}.popover[placement^=left]::part(popup){transform-origin:right}.popover[placement^=right]::part(popup){transform-origin:left}.body{display:flex;flex-direction:column;width:auto;max-width:min(var(--max-width),100vw);padding:var(--wa-space-l);background-color:var(--wa-color-surface-default);border:var(--wa-panel-border-width) solid var(--wa-color-surface-border);border-radius:var(--wa-panel-border-radius);border-style:var(--wa-panel-border-style);box-shadow:var(--wa-shadow-l);color:var(--wa-color-text-normal);user-select:none;-webkit-user-select:none}.popover[data-current-placement^=bottom] .body,.popover[data-current-placement^=top] .body{max-width:min(var(--max-width),100vw - (var(--wa-space-m) * 2));margin-inline:var(--wa-space-m)}.popover[data-current-placement^=left] .body,.popover[data-current-placement^=right] .body{max-height:calc(100vh - (var(--wa-space-m) * 2));margin-block:var(--wa-space-m)}`))},29344:function(t,e,i){i.a(t,async function(t,o){try{i.d(e,{A:function(){return E}});i(27495),i(62953);var n=i(5124),s=i(67576),r=i(6412),a=i(63672),l=i(34514),c=i(40991),h=i(92070),d=i(41268),u=i(9395),p=i(62676),f=i(15477),v=i(31896),b=i(17060),w=i(19978),g=t([b]);b=(g.then?(await g)():g)[0];let C,x,A,$=t=>t;var m=Object.defineProperty,y=Object.getOwnPropertyDescriptor,k=(t,e,i,o)=>{for(var n,s=o>1?void 0:o?y(e,i):e,r=t.length-1;r>=0;r--)(n=t[r])&&(s=(o?n(e,i,s):n(s))||s);return o&&s&&m(e,i,s),s};let E=class extends p.q{static get validators(){return[...super.validators,(0,d.i)()]}get value(){var t;return null!==(t=this._value)&&void 0!==t?t:"on"}set value(t){this._value=t}handleSizeChange(){(0,c.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.updateComplete.then(()=>{this.dispatchEvent(new Event("change",{bubbles:!0,composed:!0}))})}handleKeyDown(t){const e="rtl"===this.localize.dir();"ArrowLeft"===t.key&&(t.preventDefault(),this.checked=e,this.updateComplete.then(()=>{this.dispatchEvent(new Event("change",{bubbles:!0,composed:!0})),this.dispatchEvent(new InputEvent("input",{bubbles:!0,composed:!0}))})),"ArrowRight"===t.key&&(t.preventDefault(),this.checked=!e,this.updateComplete.then(()=>{this.dispatchEvent(new Event("change",{bubbles:!0,composed:!0})),this.dispatchEvent(new InputEvent("input",{bubbles:!0,composed:!0}))}))}willUpdate(t){super.willUpdate(t),(t.has("value")||t.has("checked")||t.has("defaultChecked"))&&this.handleValueOrCheckedChange()}handleValueOrCheckedChange(){this.setValue(this.checked?this.value:null,this._value),this.updateValidity()}handleStateChange(){this.hasUpdated&&(this.input.checked=this.checked),this.customStates.set("checked",this.checked),this.updateValidity()}handleDisabledChange(){this.updateValidity()}click(){this.input.click()}focus(t){this.input.focus(t)}blur(){this.input.blur()}setValue(t,e){this.checked?this.internals.setFormValue(null!=t?t:"on",e):this.internals.setFormValue(null,null)}formResetCallback(){this._checked=null,super.formResetCallback(),this.handleValueOrCheckedChange()}render(){const t=this.hasUpdated?this.hasSlotController.test("hint"):this.withHint,e=!!this.hint||!!t;return(0,n.qy)(C||(C=$` <label part="base" class="${0}"> <input class="input" type="checkbox" title="${0}" name="${0}" value="${0}" .checked="${0}" .disabled="${0}" .required="${0}" role="switch" aria-checked="${0}" aria-describedby="hint" @click="${0}" @keydown="${0}"> <span part="control" class="switch"> <span part="thumb" class="thumb"></span> </span> <slot part="label" class="label"></slot> </label> <slot id="hint" name="hint" part="hint" class="${0}" aria-hidden="${0}">${0}</slot> `),(0,r.H)({checked:this.checked,disabled:this.disabled}),this.title,(0,a.J)(this.name),(0,a.J)(this.value),(0,l.V)(this.checked),this.disabled,this.required,this.checked?"true":"false",this.handleClick,this.handleKeyDown,(0,r.H)({"has-slotted":e}),e?"false":"true",this.hint)}constructor(){var t;super(...arguments),this.hasSlotController=new h.X(this,"hint"),this.localize=new b.c(this),this.title="",this.name=null,this._value=null!==(t=this.getAttribute("value"))&&void 0!==t?t:null,this.size="m",this.disabled=!1,this._checked=null,this.defaultChecked=this.hasAttribute("checked"),this.required=!1,this.hint="",this.withHint=!1}};E.shadowRootOptions=Object.assign(Object.assign({},p.q.shadowRootOptions),{},{delegatesFocus:!0}),E.css=[f.A,v.A,w.A],k([(0,s.P)('input[type="checkbox"]')],E.prototype,"input",2),k([(0,s.MZ)()],E.prototype,"title",2),k([(0,s.MZ)({reflect:!0})],E.prototype,"name",2),k([(0,s.MZ)({reflect:!0})],E.prototype,"value",1),k([(0,s.MZ)({reflect:!0})],E.prototype,"size",2),k([(0,u.w)("size")],E.prototype,"handleSizeChange",1),k([(0,s.MZ)({type:Boolean})],E.prototype,"disabled",2),k([(0,s.MZ)({type:Boolean,attribute:!1})],E.prototype,"checked",1),k([(0,s.MZ)({type:Boolean,attribute:"checked",reflect:!0})],E.prototype,"defaultChecked",2),k([(0,s.MZ)({type:Boolean,reflect:!0})],E.prototype,"required",2),k([(0,s.MZ)({attribute:"hint"})],E.prototype,"hint",2),k([(0,s.MZ)({attribute:"with-hint",type:Boolean})],E.prototype,"withHint",2),k([(0,u.w)(["checked","defaultChecked"])],E.prototype,"handleStateChange",1),k([(0,u.w)("disabled",{waitUntilFirstUpdate:!0})],E.prototype,"handleDisabledChange",1),E=k([(0,s.EM)("wa-switch")],E),null===(x=(A=E).disableWarning)||void 0===x||x.call(A,"change-in-update"),o()}catch(C){o(C)}})},19978:function(t,e,i){i.d(e,{A:function(){return n}});let o;var n=(0,i(5124).AH)(o||(o=(t=>t)`:host{--height:var(--wa-form-control-toggle-size);--width:calc(var(--height) * 1.75);--thumb-size:0.75em;display:inline-flex;line-height:var(--wa-form-control-value-line-height)}label{position:relative;display:flex;align-items:center;font:inherit;color:var(--wa-form-control-value-color);vertical-align:middle;cursor:pointer}.switch{flex:0 0 auto;position:relative;display:flex;align-items:center;justify-content:center;width:var(--width);height:var(--height);background-color:var(--wa-form-control-background-color);border-color:var(--wa-form-control-border-color);border-radius:var(--height);border-style:var(--wa-form-control-border-style);border-width:var(--wa-form-control-border-width);transition-property:translate,background,border-color,box-shadow;transition-duration:var(--wa-transition-normal);transition-timing-function:var(--wa-transition-easing)}.switch .thumb{aspect-ratio:1/1;width:var(--thumb-size);height:var(--thumb-size);background-color:var(--wa-form-control-border-color);border-radius:50%;translate:calc((var(--width) - var(--height))/ -2);transition:inherit}.switch .thumb:dir(rtl){translate:calc((var(--width) - var(--height))/ 2)}.input{position:absolute;opacity:0;padding:0;margin:0;pointer-events:none}label:not(.disabled) .input:focus-visible~.switch .thumb{outline:var(--wa-focus-ring);outline-offset:var(--wa-focus-ring-offset)}.checked .switch{background-color:var(--wa-form-control-activated-color);border-color:var(--wa-form-control-activated-color)}.checked .switch .thumb{background-color:var(--wa-color-surface-default);translate:calc((var(--width) - var(--height))/ 2)}.checked .switch .thumb:dir(rtl){translate:calc((var(--width) - var(--height))/ -2)}label:has(> :disabled){opacity:.5;cursor:not-allowed}[part~=label]{display:inline-block;line-height:var(--height);margin-inline-start:.5em;user-select:none;-webkit-user-select:none}: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)}@media (forced-colors:active){:checked+.switch .thumb,:checked:enabled+.switch:hover .thumb{background-color:ButtonText}}`))},88696:function(t,e,i){i.a(t,async function(t,o){try{i.d(e,{P:function(){return l}});var n=i(69235),s=(i(3362),i(17642),i(58004),i(33853),i(45876),i(32475),i(15024),i(31698),i(62953),i(37540)),r=i(42017),a=t([n]);n=(a.then?(await a)():a)[0];class l{handleChanges(t){var e;this.value=null===(e=this.callback)||void 0===e?void 0:e.call(this,t,this.u)}hostConnected(){for(const t of this.t)this.observe(t)}hostDisconnected(){this.disconnect()}async hostUpdated(){!this.o&&this.i&&this.handleChanges([]),this.i=!1}observe(t){this.t.add(t),this.u.observe(t,this.l),this.i=!0,this.h.requestUpdate()}unobserve(t){this.t.delete(t),this.u.unobserve(t)}disconnect(){this.u.disconnect()}target(t){return c(this,t)}constructor(t,{target:e,config:i,callback:o,skipInitial:n}){this.t=new Set,this.o=!1,this.i=!1,this.h=t,null!==e&&this.t.add(null!=e?e:t),this.l=i,this.o=null!=n?n:this.o,this.callback=o,window.ResizeObserver?(this.u=new ResizeObserver(t=>{this.handleChanges(t),this.h.requestUpdate()}),t.addController(this)):console.warn("ResizeController error: browser does not support ResizeObserver.")}}const c=(0,r.u$)(class extends s.Kq{render(t,e){}update(t,[e,i]){this.controller=e,this.part=t,this.observe=i,!1===i?(e.unobserve(t.element),this.observing=!1):!1===this.observing&&(e.observe(t.element),this.observing=!0)}disconnected(){var t;null!==(t=this.controller)&&void 0!==t&&t.unobserve(this.part.element),this.observing=!1}reconnected(){var t;!1!==this.observe&&!1===this.observing&&(null!==(t=this.controller)&&void 0!==t&&t.observe(this.part.element),this.observing=!0)}constructor(){super(...arguments),this.observing=!1}});o()}catch(l){o(l)}})},99731:function(t,e,i){i.d(e,{Y:function(){return u}});var o=i(40445),n=i(67576),s=(i(93775),i(18111),i(22489),i(20116),i(62953),i(5124)),r=i(99591);let a,l=t=>t;class c extends s.WF{get chips(){return this.childElements.filter(t=>t instanceof r.v)}render(){return(0,s.qy)(a||(a=l`<slot @slotchange="${0}"></slot>`),this.updateTabIndices)}handleKeyDown(t){const e="ArrowLeft"===t.key,i="ArrowRight"===t.key,o="Home"===t.key,n="End"===t.key;if(!(e||i||o||n))return;const{chips:s}=this;if(s.length<2)return;if(t.preventDefault(),o||n){return s[o?0:s.length-1].focus({trailing:n}),void this.updateTabIndices()}const r="rtl"===getComputedStyle(this).direction?e:i,a=s.find(t=>t.matches(":focus-within"));if(!a){return(r?s[0]:s[s.length-1]).focus({trailing:!r}),void this.updateTabIndices()}const l=s.indexOf(a);let c=r?l+1:l-1;for(;c!==l;){c>=s.length?c=0:c<0&&(c=s.length-1);const t=s[c];if(!t.disabled||t.alwaysFocusable){t.focus({trailing:!r}),this.updateTabIndices();break}r?c++:c--}}updateTabIndices(){const{chips:t}=this;let e;for(const i of t){const t=i.alwaysFocusable||!i.disabled;i.matches(":focus-within")&&t?e=i:(t&&!e&&(e=i),i.tabIndex=-1)}e&&(e.tabIndex=0)}constructor(){super(),this.internals=this.attachInternals(),s.S$||(this.addEventListener("focusin",this.updateTabIndices.bind(this)),this.addEventListener("update-focus",this.updateTabIndices.bind(this)),this.addEventListener("keydown",this.handleKeyDown.bind(this)),this.internals.role="toolbar")}}(0,o.Cg)([(0,n.KN)()],c.prototype,"childElements",void 0);let h;const d=(0,s.AH)(h||(h=(t=>t)`:host{display:flex;flex-wrap:wrap;gap:8px}`));let u=class extends c{};u.styles=[d],u=(0,o.Cg)([(0,n.EM)("md-chip-set")],u)},25423:function(t,e,i){i.d(e,{U:function(){return n},Z:function(){return s}});i(44114),i(62953);var o=i(27525);const n={ArrowDown:"ArrowDown",ArrowLeft:"ArrowLeft",ArrowUp:"ArrowUp",ArrowRight:"ArrowRight",Home:"Home",End:"End"};class s{get items(){const t=this.getPossibleItems(),e=[];for(const i of t){if(this.isItem(i)){e.push(i);continue}const t=i.item;t&&this.isItem(t)&&e.push(t)}return e}activateNextItem(){const t=this.items,e=(0,o.A6)(t,this.isActivatable);return e&&(e.item.tabIndex=-1),(0,o.wm)(t,e,this.isActivatable,this.wrapNavigation())}activatePreviousItem(){const t=this.items,e=(0,o.A6)(t,this.isActivatable);return e&&(e.item.tabIndex=-1),(0,o.u9)(t,e,this.isActivatable,this.wrapNavigation())}constructor(t){this.handleKeydown=t=>{const e=t.key;if(t.defaultPrevented||!this.isNavigableKey(e))return;const i=this.items;if(!i.length)return;const s=(0,o.A6)(i,this.isActivatable);t.preventDefault();const r=this.isRtl(),a=r?n.ArrowRight:n.ArrowLeft,l=r?n.ArrowLeft:n.ArrowRight;let c=null;switch(e){case n.ArrowDown:case l:c=(0,o.wm)(i,s,this.isActivatable,this.wrapNavigation());break;case n.ArrowUp:case a:c=(0,o.u9)(i,s,this.isActivatable,this.wrapNavigation());break;case n.Home:c=(0,o.zT)(i,this.isActivatable);break;case n.End:c=(0,o.RZ)(i,this.isActivatable)}c&&s&&s.item!==c&&(s.item.tabIndex=-1)},this.onDeactivateItems=()=>{const t=this.items;for(const e of t)this.deactivateItem(e)},this.onRequestActivation=t=>{this.onDeactivateItems();const e=t.target;this.activateItem(e),e.focus()},this.onSlotchange=()=>{const t=this.items;let e=!1;for(const o of t){!(!o.disabled&&o.tabIndex>-1)||e?o.tabIndex=-1:(e=!0,o.tabIndex=0)}if(e)return;const i=(0,o.c7)(t,this.isActivatable);i&&(i.tabIndex=0)};const{isItem:e,getPossibleItems:i,isRtl:s,deactivateItem:r,activateItem:a,isNavigableKey:l,isActivatable:c,wrapNavigation:h}=t;this.isItem=e,this.getPossibleItems=i,this.isRtl=s,this.deactivateItem=r,this.activateItem=a,this.isNavigableKey=l,this.isActivatable=c,this.wrapNavigation=null!=h?h:()=>!0}}},27525:function(t,e,i){i.d(e,{A6:function(){return r},Ex:function(){return l},RN:function(){return d},RZ:function(){return n},c7:function(){return a},cG:function(){return u},u9:function(){return h},ub:function(){return s},wm:function(){return c},zT:function(){return o}});i(62953);function o(t,e=p){const i=a(t,e);return i&&(i.tabIndex=0,i.focus()),i}function n(t,e=p){const i=l(t,e);return i&&(i.tabIndex=0,i.focus()),i}function s(t,e=p){const i=r(t,e);return i&&(i.item.tabIndex=-1),i}function r(t,e=p){for(let i=0;i<t.length;i++){const o=t[i];if(0===o.tabIndex&&e(o))return{item:o,index:i}}return null}function a(t,e=p){for(const i of t)if(e(i))return i;return null}function l(t,e=p){for(let i=t.length-1;i>=0;i--){const o=t[i];if(e(o))return o}return null}function c(t,e,i=p,n=!0){if(e){const o=function(t,e,i=p,o=!0){for(let n=1;n<t.length;n++){const s=(n+e)%t.length;if(s<e&&!o)return null;const r=t[s];if(i(r))return r}return t[e]?t[e]:null}(t,e.index,i,n);return o&&(o.tabIndex=0,o.focus()),o}return o(t,i)}function h(t,e,i=p,o=!0){if(e){const n=function(t,e,i=p,o=!0){for(let n=1;n<t.length;n++){const s=(e-n+t.length)%t.length;if(s>e&&!o)return null;const r=t[s];if(i(r))return r}return t[e]?t[e]:null}(t,e.index,i,o);return n&&(n.tabIndex=0,n.focus()),n}return n(t,i)}function d(){return new Event("deactivate-items",{bubbles:!0,composed:!0})}function u(){return new Event("request-activation",{bubbles:!0,composed:!0})}function p(t){return!t.disabled}},11245:function(t,e,i){i.d(e,{R:function(){return n}});let o;const n=(0,i(5124).AH)(o||(o=(t=>t)`:host{background:var(--md-list-container-color,var(--md-sys-color-surface,#fef7ff));color:unset;display:flex;flex-direction:column;outline:0;padding:8px 0;position:relative}`))},49838:function(t,e,i){i.d(e,{B:function(){return h}});i(93775),i(17642),i(58004),i(33853),i(45876),i(32475),i(15024),i(31698),i(62953);var o=i(40445),n=i(5124),s=i(67576),r=i(25423);let a,l=t=>t;const c=new Set(Object.values(r.U));class h extends n.WF{get items(){return this.listController.items}render(){return(0,n.qy)(a||(a=l` <slot @deactivate-items="${0}" @request-activation="${0}" @slotchange="${0}"> </slot> `),this.listController.onDeactivateItems,this.listController.onRequestActivation,this.listController.onSlotchange)}activateNextItem(){return this.listController.activateNextItem()}activatePreviousItem(){return this.listController.activatePreviousItem()}constructor(){super(),this.listController=new r.Z({isItem:t=>t.hasAttribute("md-list-item"),getPossibleItems:()=>this.slotItems,isRtl:()=>"rtl"===getComputedStyle(this).direction,deactivateItem:t=>{t.tabIndex=-1},activateItem:t=>{t.tabIndex=0},isNavigableKey:t=>c.has(t),isActivatable:t=>!t.disabled&&"text"!==t.type}),this.internals=this.attachInternals(),n.S$||(this.internals.role="list",this.addEventListener("keydown",this.listController.handleKeydown))}}(0,o.Cg)([(0,s.KN)({flatten:!0})],h.prototype,"slotItems",void 0)},95192:function(t,e,i){i.d(e,{IU:function(){return c},Jt:function(){return a},Yd:function(){return o},hZ:function(){return l},y$:function(){return n}});i(44114),i(18111),i(7588),i(61701),i(3362),i(62953);function o(t){return new Promise((e,i)=>{t.oncomplete=t.onsuccess=()=>e(t.result),t.onabort=t.onerror=()=>i(t.error)})}function n(t,e){let i;return(n,s)=>(()=>{if(i)return i;const n=indexedDB.open(t);return n.onupgradeneeded=()=>n.result.createObjectStore(e),i=o(n),i.then(t=>{t.onclose=()=>i=void 0},()=>{}),i})().then(t=>s(t.transaction(e,n).objectStore(e)))}let s;function r(){return s||(s=n("keyval-store","keyval")),s}function a(t,e=r()){return e("readonly",e=>o(e.get(t)))}function l(t,e,i=r()){return i("readwrite",i=>(i.put(e,t),o(i.transaction)))}function c(t=r()){return t("readwrite",t=>(t.clear(),o(t.transaction)))}},37540:function(t,e,i){i.d(e,{Kq:function(){return d}});i(17642),i(58004),i(33853),i(45876),i(32475),i(15024),i(31698),i(62953);var o=i(63937),n=i(42017);const s=(t,e)=>{const i=t._$AN;if(void 0===i)return!1;for(const n of i){var o;null!==(o=n._$AO)&&void 0!==o&&o.call(n,e,!1),s(n,e)}return!0},r=t=>{let e,i;do{var o;if(void 0===(e=t._$AM))break;i=e._$AN,i.delete(t),t=e}while(0===(null===(o=i)||void 0===o?void 0:o.size))},a=t=>{for(let e;e=t._$AM;t=e){let i=e._$AN;if(void 0===i)e._$AN=i=new Set;else if(i.has(t))break;i.add(t),h(e)}};function l(t){void 0!==this._$AN?(r(this),this._$AM=t,a(this)):this._$AM=t}function c(t,e=!1,i=0){const o=this._$AH,n=this._$AN;if(void 0!==n&&0!==n.size)if(e)if(Array.isArray(o))for(let a=i;a<o.length;a++)s(o[a],!1),r(o[a]);else null!=o&&(s(o,!1),r(o));else s(this,t)}const h=t=>{var e,i;t.type==n.OA.CHILD&&(null!==(e=t._$AP)&&void 0!==e||(t._$AP=c),null!==(i=t._$AQ)&&void 0!==i||(t._$AQ=l))};class d extends n.WL{_$AT(t,e,i){super._$AT(t,e,i),a(this),this.isConnected=t._$AU}_$AO(t,e=!0){var i,o;t!==this.isConnected&&(this.isConnected=t,t?null===(i=this.reconnected)||void 0===i||i.call(this):null===(o=this.disconnected)||void 0===o||o.call(this)),e&&(s(this,t),r(this))}setValue(t){if((0,o.Rt)(this._$Ct))this._$Ct._$AI(t,this);else{const e=[...this._$Ct._$AH];e[this._$Ci]=t,this._$Ct._$AI(e,this,0)}}disconnected(){}reconnected(){}constructor(){super(...arguments),this._$AN=void 0}}},54495:function(t,e,i){i.d(e,{OA:function(){return o.OA},WL:function(){return o.WL},u$:function(){return o.u$}});var o=i(42017)},75751:function(t,e,i){i.d(e,{u:function(){return a}});i(16280),i(45367),i(92731),i(62953);var o=i(5055),n=i(42017),s=i(63937);const r=(t,e,i)=>{const o=new Map;for(let n=e;n<=i;n++)o.set(t[n],n);return o},a=(0,n.u$)(class extends n.WL{dt(t,e,i){let o;void 0===i?i=e:void 0!==e&&(o=e);const n=[],s=[];let r=0;for(const a of t)n[r]=o?o(a,r):r,s[r]=i(a,r),r++;return{values:s,keys:n}}render(t,e,i){return this.dt(t,e,i).values}update(t,[e,i,n]){var a;const l=(0,s.cN)(t),{values:c,keys:h}=this.dt(e,i,n);if(!Array.isArray(l))return this.ut=h,c;const d=null!==(a=this.ut)&&void 0!==a?a:this.ut=[],u=[];let p,f,v=0,b=l.length-1,w=0,g=c.length-1;for(;v<=b&&w<=g;)if(null===l[v])v++;else if(null===l[b])b--;else if(d[v]===h[w])u[w]=(0,s.lx)(l[v],c[w]),v++,w++;else if(d[b]===h[g])u[g]=(0,s.lx)(l[b],c[g]),b--,g--;else if(d[v]===h[g])u[g]=(0,s.lx)(l[v],c[g]),(0,s.Dx)(t,u[g+1],l[v]),v++,g--;else if(d[b]===h[w])u[w]=(0,s.lx)(l[b],c[w]),(0,s.Dx)(t,l[v],l[b]),b--,w++;else if(void 0===p&&(p=r(h,w,g),f=r(d,v,b)),p.has(d[v]))if(p.has(d[b])){const e=f.get(h[w]),i=void 0!==e?l[e]:null;if(null===i){const e=(0,s.Dx)(t,l[v]);(0,s.lx)(e,c[w]),u[w]=e}else u[w]=(0,s.lx)(i,c[w]),(0,s.Dx)(t,l[v],i),l[e]=null;w++}else(0,s.KO)(l[b]),b--;else(0,s.KO)(l[v]),v++;for(;w<=g;){const e=(0,s.Dx)(t,u[g+1]);(0,s.lx)(e,c[w]),u[w++]=e}for(;v<=b;){const t=l[v++];null!==t&&(0,s.KO)(t)}return this.ut=h,(0,s.mY)(t,u),o.c0}constructor(t){if(super(t),t.type!==n.OA.CHILD)throw Error("repeat() can only be used in text expressions")}})},89784:function(t,e,i){i.d(e,{W:function(){return a}});i(16280),i(74423),i(72712),i(18111),i(18237),i(27495),i(17642),i(58004),i(33853),i(45876),i(32475),i(15024),i(31698),i(25440),i(62953);var o=i(5055),n=i(42017);const s="important",r=" !"+s,a=(0,n.u$)(class extends n.WL{render(t){return Object.keys(t).reduce((e,i)=>{const o=t[i];return null==o?e:e+`${i=i.includes("-")?i:i.replace(/(?:^(webkit|moz|ms|o)|)(?=[A-Z])/g,"-$&").toLowerCase()}:${o};`},"")}update(t,[e]){const{style:i}=t.element;if(void 0===this.ft)return this.ft=new Set(Object.keys(e)),this.render(e);for(const o of this.ft)null==e[o]&&(this.ft.delete(o),o.includes("-")?i.removeProperty(o):i[o]=null);for(const o in e){const t=e[o];if(null!=t){this.ft.add(o);const e="string"==typeof t&&t.endsWith(r);o.includes("-")||e?i.setProperty(o,e?t.slice(0,-11):t,e?s:""):i[o]=t}}return o.c0}constructor(t){var e;if(super(t),t.type!==n.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.")}})},91450:function(t,e,i){i.d(e,{T:function(){return u}});i(18111),i(20116),i(3362),i(62953);var o=i(5055),n=i(63937),s=i(37540);i(65722);class r{disconnect(){this.G=void 0}reconnect(t){this.G=t}deref(){return this.G}constructor(t){this.G=t}}class a{get(){return this.Y}pause(){var t;null!==(t=this.Y)&&void 0!==t||(this.Y=new Promise(t=>this.Z=t))}resume(){var t;null!==(t=this.Z)&&void 0!==t&&t.call(this),this.Y=this.Z=void 0}constructor(){this.Y=void 0,this.Z=void 0}}var l=i(42017);const c=t=>!(0,n.sO)(t)&&"function"==typeof t.then,h=1073741823;class d extends s.Kq{render(...t){var e;return null!==(e=t.find(t=>!c(t)))&&void 0!==e?e:o.c0}update(t,e){const i=this._$Cbt;let n=i.length;this._$Cbt=e;const s=this._$CK,r=this._$CX;this.isConnected||this.disconnected();for(let o=0;o<e.length&&!(o>this._$Cwt);o++){const t=e[o];if(!c(t))return this._$Cwt=o,t;o<n&&t===i[o]||(this._$Cwt=h,n=0,Promise.resolve(t).then(async e=>{for(;r.get();)await r.get();const i=s.deref();if(void 0!==i){const o=i._$Cbt.indexOf(t);o>-1&&o<i._$Cwt&&(i._$Cwt=o,i.setValue(e))}}))}return o.c0}disconnected(){this._$CK.disconnect(),this._$CX.pause()}reconnected(){this._$CK.reconnect(this),this._$CX.resume()}constructor(){super(...arguments),this._$Cwt=h,this._$Cbt=[],this._$CK=new r(this),this._$CX=new a}}const u=(0,l.u$)(d)}}]);