UNPKG

iobroker.lovelace

Version:

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

29 lines 42.9 kB
/*! For license information please see 4440.9a59f046a69a001c.js.LICENSE.txt */ export const __rspack_esm_id=4440;export const __rspack_esm_ids=[4440];export const __webpack_modules__={51324(e,t,a){a.d(t,{ZS:()=>c,is:()=>l.i});var r,i,o=a(62826),n=a(22441),l=a(12451);const s=null!==(i=null===(r=window.ShadyDOM)||void 0===r?void 0:r.inUse)&&void 0!==i&&i;class c extends l.O{findFormElement(){if(!this.shadowRoot||s)return null;const e=this.getRootNode().querySelectorAll("form");for(const t of Array.from(e))if(t.contains(this))return t;return null}connectedCallback(){var e;super.connectedCallback(),this.containingForm=this.findFormElement(),null===(e=this.containingForm)||void 0===e||e.addEventListener("formdata",this.formDataListener)}disconnectedCallback(){var e;super.disconnectedCallback(),null===(e=this.containingForm)||void 0===e||e.removeEventListener("formdata",this.formDataListener),this.containingForm=null}click(){this.formElement&&!this.disabled&&(this.formElement.focus(),this.formElement.click())}firstUpdated(){super.firstUpdated(),this.shadowRoot&&this.mdcRoot.addEventListener("change",e=>{this.dispatchEvent(new Event("change",e))})}constructor(){super(...arguments),this.disabled=!1,this.containingForm=null,this.formDataListener=e=>{this.disabled||this.setFormData(e.formData)}}}c.shadowRootOptions={mode:"open",delegatesFocus:!0},(0,o.Cg)([(0,n.MZ)({type:Boolean})],c.prototype,"disabled",void 0)},68462(e,t,a){a.d(t,{M:()=>u});var r=a(62826),i=a(7658),o={ROOT:"mdc-form-field"},n={LABEL_SELECTOR:".mdc-form-field > label"};const l=function(e){function t(a){var i=e.call(this,(0,r.Cl)((0,r.Cl)({},t.defaultAdapter),a))||this;return i.click=function(){i.handleClick()},i}return(0,r.C6)(t,e),Object.defineProperty(t,"cssClasses",{get:function(){return o},enumerable:!1,configurable:!0}),Object.defineProperty(t,"strings",{get:function(){return n},enumerable:!1,configurable:!0}),Object.defineProperty(t,"defaultAdapter",{get:function(){return{activateInputRipple:function(){},deactivateInputRipple:function(){},deregisterInteractionHandler:function(){},registerInteractionHandler:function(){}}},enumerable:!1,configurable:!0}),t.prototype.init=function(){this.adapter.registerInteractionHandler("click",this.click)},t.prototype.destroy=function(){this.adapter.deregisterInteractionHandler("click",this.click)},t.prototype.handleClick=function(){var e=this;this.adapter.activateInputRipple(),requestAnimationFrame(function(){e.adapter.deactivateInputRipple()})},t}(i.I);var s=a(12451),c=a(51324),d=a(56161),h=a(5124),p=a(22441),m=a(6412);class u extends s.O{createAdapter(){return{registerInteractionHandler:(e,t)=>{this.labelEl.addEventListener(e,t)},deregisterInteractionHandler:(e,t)=>{this.labelEl.removeEventListener(e,t)},activateInputRipple:async()=>{const e=this.input;if(e instanceof c.ZS){const t=await e.ripple;t&&t.startPress()}},deactivateInputRipple:async()=>{const e=this.input;if(e instanceof c.ZS){const t=await e.ripple;t&&t.endPress()}}}}get input(){var e,t;return null!==(t=null===(e=this.slottedInputs)||void 0===e?void 0:e[0])&&void 0!==t?t:null}render(){const e={"mdc-form-field--align-end":this.alignEnd,"mdc-form-field--space-between":this.spaceBetween,"mdc-form-field--nowrap":this.nowrap};return h.qy` <div class="mdc-form-field ${(0,m.H)(e)}"> <slot></slot> <label class="mdc-label" @click="${this._labelClick}">${this.label}</label> </div>`}click(){this._labelClick()}_labelClick(){const e=this.input;e&&(e.focus(),e.click())}constructor(){super(...arguments),this.alignEnd=!1,this.spaceBetween=!1,this.nowrap=!1,this.label="",this.mdcFoundationClass=l}}(0,r.Cg)([(0,p.MZ)({type:Boolean})],u.prototype,"alignEnd",void 0),(0,r.Cg)([(0,p.MZ)({type:Boolean})],u.prototype,"spaceBetween",void 0),(0,r.Cg)([(0,p.MZ)({type:Boolean})],u.prototype,"nowrap",void 0),(0,r.Cg)([(0,p.MZ)({type:String}),(0,d.P)(async function(e){var t;null===(t=this.input)||void 0===t||t.setAttribute("aria-label",e)})],u.prototype,"label",void 0),(0,r.Cg)([(0,p.P)(".mdc-form-field")],u.prototype,"mdcRoot",void 0),(0,r.Cg)([(0,p.KN)({slot:"",flatten:!0,selector:"*"})],u.prototype,"slottedInputs",void 0),(0,r.Cg)([(0,p.P)("label")],u.prototype,"labelEl",void 0)},38627(e,t,a){a.d(t,{R:()=>r});const r=a(5124).AH`.mdc-form-field{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:Roboto,sans-serif;font-family:var(--mdc-typography-body2-font-family, var(--mdc-typography-font-family, Roboto, sans-serif));font-size:.875rem;font-size:var(--mdc-typography-body2-font-size, .875rem);line-height:1.25rem;line-height:var(--mdc-typography-body2-line-height, 1.25rem);font-weight:400;font-weight:var(--mdc-typography-body2-font-weight,400);letter-spacing:.0178571429em;letter-spacing:var(--mdc-typography-body2-letter-spacing, .0178571429em);text-decoration:inherit;text-decoration:var(--mdc-typography-body2-text-decoration,inherit);text-transform:inherit;text-transform:var(--mdc-typography-body2-text-transform,inherit);color:rgba(0,0,0,.87);color:var(--mdc-theme-text-primary-on-background,rgba(0,0,0,.87));display:inline-flex;align-items:center;vertical-align:middle}.mdc-form-field>label{margin-left:0;margin-right:auto;padding-left:4px;padding-right:0;order:0}.mdc-form-field>label[dir=rtl],[dir=rtl] .mdc-form-field>label{margin-left:auto;margin-right:0}.mdc-form-field>label[dir=rtl],[dir=rtl] .mdc-form-field>label{padding-left:0;padding-right:4px}.mdc-form-field--nowrap>label{text-overflow:ellipsis;overflow:hidden;white-space:nowrap}.mdc-form-field--align-end>label{margin-left:auto;margin-right:0;padding-left:0;padding-right:4px;order:-1}.mdc-form-field--align-end>label[dir=rtl],[dir=rtl] .mdc-form-field--align-end>label{margin-left:0;margin-right:auto}.mdc-form-field--align-end>label[dir=rtl],[dir=rtl] .mdc-form-field--align-end>label{padding-left:4px;padding-right:0}.mdc-form-field--space-between{justify-content:space-between}.mdc-form-field--space-between>label{margin:0}.mdc-form-field--space-between>label[dir=rtl],[dir=rtl] .mdc-form-field--space-between>label{margin:0}:host{display:inline-flex}.mdc-form-field{width:100%}::slotted(*){-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:Roboto,sans-serif;font-family:var(--mdc-typography-body2-font-family, var(--mdc-typography-font-family, Roboto, sans-serif));font-size:.875rem;font-size:var(--mdc-typography-body2-font-size, .875rem);line-height:1.25rem;line-height:var(--mdc-typography-body2-line-height, 1.25rem);font-weight:400;font-weight:var(--mdc-typography-body2-font-weight,400);letter-spacing:.0178571429em;letter-spacing:var(--mdc-typography-body2-letter-spacing, .0178571429em);text-decoration:inherit;text-decoration:var(--mdc-typography-body2-text-decoration,inherit);text-transform:inherit;text-transform:var(--mdc-typography-body2-text-transform,inherit);color:rgba(0,0,0,.87);color:var(--mdc-theme-text-primary-on-background,rgba(0,0,0,.87))}::slotted(mwc-switch){margin-right:10px}::slotted(mwc-switch[dir=rtl]),[dir=rtl] ::slotted(mwc-switch){margin-left:10px}`},13467(e,t,a){var r=a(62826),i=a(41216),o=a(78960),n=a(75640),l=a(91735),s=a(43826),c=a(5124),d=a(22441);class h extends i.R{}h.styles=[l.R,s.R,n.R,o.R,c.AH`:host{--md-sys-color-primary:var(--primary-text-color);--md-sys-color-on-surface:var(--primary-text-color);--md-sys-color-on-surface-variant:var(--primary-text-color);--md-sys-color-on-secondary-container:var(--primary-text-color);--md-input-chip-container-shape:16px;--md-input-chip-outline-color:var(--outline-color);--md-input-chip-selected-container-color:rgba( var(--rgb-primary-text-color), 0.15 );--ha-input-chip-selected-container-opacity:1;--md-input-chip-label-text-font:Roboto,sans-serif}::slotted([slot=icon]){display:flex;--mdc-icon-size:var(--md-input-chip-icon-size, 18px)}.selected::before{opacity:var(--ha-input-chip-selected-container-opacity)}`],h=(0,r.Cg)([(0,d.EM)("ha-input-chip")],h)},9503(e,t,a){var r=a(62826),i=a(97577),o=a(5124),n=a(22441);class l extends i.A{get value(){return this._value??null}set value(e){this._value=e}static get styles(){return[i.A.styles,o.AH`:host{--wa-form-control-toggle-size:var(--ha-checkbox-size, 20px);--wa-form-control-border-color:var( --ha-checkbox-border-color, var(--ha-color-border-neutral-normal) );--wa-form-control-background-color:var( --ha-checkbox-background-color, var(--wa-form-control-background-color) );--checked-icon-color:var( --ha-checkbox-checked-icon-color, var(--wa-color-brand-on-loud) );--wa-form-control-activated-color:var( --ha-checkbox-checked-background-color, var(--ha-color-fill-primary-loud-resting) );-webkit-tap-highlight-color:transparent;--checked-icon-scale:var(--ha-checkbox-checked-icon-scale, 0.9);--wa-form-control-required-content:var( --ha-checkbox-required-marker, var(--ha-input-required-marker, "*") );--wa-form-control-required-content-offset:var( --ha-checkbox-required-marker-offset, 0.1rem )}[part~=base]{align-items:center;gap:var(--ha-space-2)}[part~=control]{border-radius:var(--ha-checkbox-border-radius,var(--ha-border-radius-sm));border-width:var(--ha-checkbox-border-width,var(--ha-border-width-md));margin-inline-end:0}[part~=label]{line-height:1}#hint{font-size:var(--ha-font-size-xs);color:var(--ha-color-text-secondary)}label:has(input:not(:disabled)):hover{--wa-form-control-border-color:var( --ha-checkbox-border-color-hover, var(--ha-checkbox-border-color, var(--ha-color-border-neutral-loud)) )}label:has(input:not(:disabled)):hover [part~=control]{background-color:var(--ha-checkbox-background-color-hover,var(--ha-color-form-background-hover))}label:has(input:checked:not(:disabled)):hover [part~=control],label:has(input:indeterminate:not(:disabled)):hover [part~=control]{background-color:var(--ha-checkbox-checked-background-color-hover,var(--ha-color-fill-primary-loud-hover));border-color:var(--ha-checkbox-checked-background-color-hover,var(--ha-color-fill-primary-loud-hover))}`]}}l=(0,r.Cg)([(0,n.EM)("ha-checkbox")],l)},70947(e,t,a){var r=a(62826),i=a(50759),o=(a(38625),a(5124)),n=a(22441);a(67094);class l extends i.A{renderCheckboxIcon(){return o.qy` <ha-svg-icon id="check" part="checkmark" .path="${this.checked?"M10,17L5,12L6.41,10.58L10,14.17L17.59,6.58L19,8M19,3H5C3.89,3 3,3.89 3,5V19A2,2 0 0,0 5,21H19A2,2 0 0,0 21,19V5C21,3.89 20.1,3 19,3Z":"M19,3H5C3.89,3 3,3.89 3,5V19A2,2 0 0,0 5,21H19A2,2 0 0,0 21,19V5C21,3.89 20.1,3 19,3M19,5V19H5V5H19Z"}"></ha-svg-icon> `}static get styles(){return[i.A.styles,o.AH`:host{min-height:var(--ha-space-10)}#check{visibility:visible;flex-shrink:0}#icon ::slotted(*){color:var(--ha-color-on-neutral-normal)}:host([variant=danger]) #icon ::slotted(*){color:var(--ha-color-on-danger-quiet)}:host([selected]){font-weight:var(--ha-font-weight-medium);color:var(--primary-color);background-color:var(--ha-color-fill-primary-quiet-resting);--icon-primary-color:var(--primary-color)}:host([selected]:hover){background-color:var(--ha-color-fill-primary-quiet-hover)}`]}constructor(...e){super(...e),this.selected=!1}}(0,r.Cg)([(0,n.MZ)({type:Boolean,reflect:!0})],l.prototype,"selected",void 0),l=(0,r.Cg)([(0,n.EM)("ha-dropdown-item")],l)},29823(e,t,a){a.a(e,async function(e,t){try{var r=a(62826),i=a(52254),o=a(5124),n=a(22441),l=e([i]);i=(l.then?(await l)():l)[0];class s extends i.A{get anchorElement(){return this.popup?.anchor}set anchorElement(e){this.popup&&(this.popup.anchor&&"ha-icon-button"===this.popup.anchor.localName&&(this.popup.anchor.selected=!1),this.popup.anchor=e)}getTrigger(){return this.anchorElement?this.anchorElement:super.getTrigger()}async showMenu(){await super.showMenu();const e=this.getTrigger();e&&"ha-icon-button"===e.localName&&(e.selected=!0)}async hideMenu(){const e=this.getTrigger();e&&"ha-icon-button"===e.localName&&(e.selected=!1),await super.hideMenu()}static get styles(){return[i.A.styles,o.AH`:host{font-size:var(--ha-dropdown-font-size, var(--ha-font-size-m));--wa-color-surface-raised:var( --card-background-color, var(--ha-dialog-surface-background, var(--mdc-theme-surface, #fff)), )}#menu{padding:var(--ha-space-1)}wa-popup::part(popup){z-index:200}`]}constructor(...e){super(...e),this.dropdownTag="ha-dropdown",this.dropdownItemTag="ha-dropdown-item"}}(0,r.Cg)([(0,n.MZ)({attribute:!1})],s.prototype,"dropdownTag",void 0),(0,r.Cg)([(0,n.MZ)({attribute:!1})],s.prototype,"dropdownItemTag",void 0),s=(0,r.Cg)([(0,n.EM)("ha-dropdown")],s),t()}catch(e){t(e)}})},6(e,t,a){var r=a(62826),i=a(68462),o=a(38627),n=a(5124),l=a(22441),s=a(6412),c=a(1087);class d extends i.M{render(){const e={"mdc-form-field--align-end":this.alignEnd,"mdc-form-field--space-between":this.spaceBetween,"mdc-form-field--nowrap":this.nowrap};return n.qy` <div class="mdc-form-field ${(0,s.H)(e)}"> <slot></slot> <label class="mdc-label" @click="${this._labelClick}"> <slot name="label">${this.label}</slot> </label> </div>`}_labelClick(){const e=this.input;if(e&&(e.focus(),!e.disabled))if("HA-CHECKBOX"===e.tagName)e.checked=!e.checked,(0,c.r)(e,"change");else e.click()}constructor(...e){super(...e),this.disabled=!1}}d.styles=[o.R,n.AH`:host(:not([alignEnd])) ::slotted(ha-switch){margin-right:10px;margin-inline-end:10px;margin-inline-start:initial}.mdc-form-field{align-items:var(--ha-formfield-align-items,center);gap:var(--ha-space-1)}.mdc-form-field>label{direction:var(--direction);margin-inline-start:0;margin-inline-end:auto;padding:0}:host([disabled]) label{color:var(--disabled-text-color)}`],(0,r.Cg)([(0,l.MZ)({type:Boolean,reflect:!0})],d.prototype,"disabled",void 0),d=(0,r.Cg)([(0,l.EM)("ha-formfield")],d)},64138(e,t,a){a.a(e,async function(e,r){try{a.r(t),a.d(t,{HaIconPicker:()=>y});a(74423),a(44114),a(18111),a(22489),a(7588),a(61701),a(13579);var i=a(62826),o=a(5124),n=a(22441),l=a(22786),s=a(1087),c=a(700),d=(a(75064),a(38508)),h=(a(47680),e([d]));d=(h.then?(await h)():h)[0];let p=[],m=!1;const u=(e,t)=>{const a=`${t}:${e.name}`,r=e.name,i=r.split("-"),o=e.keywords??[],n={iconName:r};return i.forEach((e,t)=>{n[`part${t}`]=e}),o.forEach((e,t)=>{n[`keyword${t}`]=e}),{id:a,primary:a,icon:a,search_labels:n,sorting_label:a}},v=async()=>{m=!0;const e=await a.e(81340).then(a.t.bind(a,25143,19));p=e.default.map(e=>u(e,"mdi"));const t=[];Object.keys(c.y).forEach(e=>{t.push(g(e))}),(await Promise.all(t)).forEach(e=>{p.push(...e)})},g=async e=>{try{const t=c.y[e].getIconList;if("function"!=typeof t)return[];return(await t()).map(t=>u(t,e))}catch(t){return console.warn(`Unable to load icon list for ${e} iconset`),[]}},b=e=>o.qy` <ha-combo-box-item type="button"> <ha-icon .icon="${e.id}" slot="start"></ha-icon> ${e.id} </ha-combo-box-item> `;class y extends o.WF{render(){return o.qy` <ha-generic-picker allow-custom-value .getItems="${this._getIconPickerItems}" .helper="${this.helper}" .disabled="${this.disabled}" .required="${this.required}" .errorMessage="${this.errorMessage}" .invalid="${this.invalid}" .rowRenderer="${b}" .icon="${this._icon}" .label="${this.label}" .value="${this._value}" .searchFn="${this._filterIcons}" @value-changed="${this._valueChanged}"> <slot name="start"></slot> </ha-generic-picker> `}firstUpdated(){m||v().then(()=>{this._getIconPickerItems=()=>p,this.requestUpdate()})}_valueChanged(e){e.stopPropagation(),this._setValue(e.detail.value)}_setValue(e){this.value=e,(0,s.r)(this,"value-changed",{value:this._value},{bubbles:!1,composed:!1})}get _icon(){return this.value?.length?this.value:this.placeholder}get _value(){return this.value||""}constructor(...e){super(...e),this.disabled=!1,this.required=!1,this.invalid=!1,this._getIconPickerItems=()=>p,this._filterIcons=(0,l.A)((e,t,a)=>{const r=e.toLowerCase().replace(/\s+/g,"-"),i=a?.length?a:t;if(!r.length)return i;const o=[];for(const e of i){const t=(e.id.split(":")[1]||e.id).toLowerCase().split("-"),a=e.search_labels?Object.values(e.search_labels).filter(e=>null!==e).map(e=>e.toLowerCase()):[],i=e.id.toLowerCase();t.includes(r)?o.push({item:e,rank:1}):a.includes(r)?o.push({item:e,rank:2}):i.includes(r)?o.push({item:e,rank:3}):a.some(e=>e.includes(r))&&o.push({item:e,rank:4})}return o.sort((e,t)=>e.rank-t.rank).map(e=>e.item)})}}y.styles=o.AH`ha-generic-picker{width:100%;display:block}`,(0,i.Cg)([(0,n.MZ)()],y.prototype,"value",void 0),(0,i.Cg)([(0,n.MZ)()],y.prototype,"label",void 0),(0,i.Cg)([(0,n.MZ)()],y.prototype,"helper",void 0),(0,i.Cg)([(0,n.MZ)()],y.prototype,"placeholder",void 0),(0,i.Cg)([(0,n.MZ)({attribute:"error-message"})],y.prototype,"errorMessage",void 0),(0,i.Cg)([(0,n.MZ)({type:Boolean})],y.prototype,"disabled",void 0),(0,i.Cg)([(0,n.MZ)({type:Boolean})],y.prototype,"required",void 0),(0,i.Cg)([(0,n.MZ)({type:Boolean})],y.prototype,"invalid",void 0),y=(0,i.Cg)([(0,n.EM)("ha-icon-picker")],y),r()}catch(e){r(e)}})},606(e,t,a){a.a(e,async function(e,t){try{a(74423),a(18111),a(61701);var r=a(62826),i=a(5124),o=a(22441),n=a(63672),l=a(22786),s=a(1087),c=a(29823),d=(a(70947),a(3449),a(88285)),h=(a(67094),e([c,d]));[c,d]=h.then?(await h)():h;class p extends i.WF{render(){return this.disabled?i.qy`${this._renderField()}${this._renderHelper()}`:i.qy` <ha-dropdown placement="bottom" @wa-select="${this._handleSelect}" @wa-show="${this._handleShow}" @wa-hide="${this._handleHide}"> ${this._renderField()} ${this.options?this.options.map(e=>{const t=["string","number"].includes(typeof e);return i.qy` <ha-dropdown-item .value="${t?e:e.value}" .disabled="${!t&&(e.disabled??!1)}" .selected="${this.value===(t?e:e.value)}"> ${e.iconPath?i.qy`<ha-svg-icon slot="icon" .path="${e.iconPath}"></ha-svg-icon>`:i.s6} <div class="content"> ${t?e:e.label||e.value} ${e.secondary?i.qy`<div class="secondary">${e.secondary}</div>`:i.s6} </div> </ha-dropdown-item> `}):i.qy`<slot></slot>`} </ha-dropdown> ${this._renderHelper()} `}_renderField(){const e=this._getValueLabel(this.options,this.value);return i.qy` <ha-picker-field slot="trigger" type="button" class="${this._opened?"opened":""}" compact="compact" aria-label="${(0,n.J)(this.label)}" @clear="${this._clearValue}" .label="${this.label}" .value="${e}" .required="${this.required}" .disabled="${this.disabled}" .hideClearIcon="${!this.clearable||this.required||this.disabled||!String(this.value)}"> </ha-picker-field> `}_renderHelper(){return this.helper?i.qy`<ha-input-helper-text .disabled="${this.disabled}">${this.helper}</ha-input-helper-text>`:i.s6}_handleSelect(e){e.stopPropagation();const t=e.detail.item.value;t!==this.value&&(0,s.r)(this,"selected",{value:t})}_clearValue(){!this.disabled&&this.value&&(0,s.r)(this,"selected",{value:void 0})}_handleShow(){this.style.setProperty("--select-menu-width",`${this._triggerField.offsetWidth}px`),this._opened=!0}_handleHide(){this._opened=!1}constructor(...e){super(...e),this.clearable=!1,this.required=!1,this.disabled=!1,this._opened=!1,this._getValueLabel=(0,l.A)((e,t)=>{const a=void 0!==t?String(t):void 0;if(!e||!a)return a;for(const t of e){const e=["string","number"].includes(typeof t);if(e&&t===a||!e&&String(t.value)===a)return e?t:t.label||t.value}return a})}}p.styles=i.AH`:host{position:relative}ha-picker-field.opened{--mdc-text-field-idle-line-color:var(--primary-color)}ha-dropdown-item .content{display:flex;gap:var(--ha-space-1);flex-direction:column}ha-dropdown-item .secondary{font-size:var(--ha-font-size-s);color:var(--ha-color-text-secondary)}ha-dropdown::part(menu){min-width:var(--select-menu-width)}ha-input-helper-text{display:block;margin:var(--ha-space-2) 0 0}`,(0,r.Cg)([(0,o.MZ)({type:Boolean})],p.prototype,"clearable",void 0),(0,r.Cg)([(0,o.MZ)({attribute:!1})],p.prototype,"options",void 0),(0,r.Cg)([(0,o.MZ)()],p.prototype,"label",void 0),(0,r.Cg)([(0,o.MZ)()],p.prototype,"helper",void 0),(0,r.Cg)([(0,o.MZ)()],p.prototype,"value",void 0),(0,r.Cg)([(0,o.MZ)({type:Boolean})],p.prototype,"required",void 0),(0,r.Cg)([(0,o.MZ)({type:Boolean})],p.prototype,"disabled",void 0),(0,r.Cg)([(0,o.wk)()],p.prototype,"_opened",void 0),(0,r.Cg)([(0,o.P)("ha-picker-field")],p.prototype,"_triggerField",void 0),p=(0,r.Cg)([(0,o.EM)("ha-select")],p),t()}catch(e){t(e)}})},85938(e,t,a){a(18111),a(22489),a(46058);var r=a(62826),i=a(5124),o=a(22441),n=a(1087);class l extends i.WF{updated(e){e.has("disabled")&&(this.disabled?this._destroySortable():this._createSortable())}disconnectedCallback(){super.disconnectedCallback(),this._shouldBeDestroy=!0,setTimeout(()=>{this._shouldBeDestroy&&(this._destroySortable(),this._shouldBeDestroy=!1)},1)}connectedCallback(){super.connectedCallback(),this._shouldBeDestroy=!1,this.hasUpdated&&!this.disabled&&this._createSortable()}createRenderRoot(){return this}render(){return this.noStyle?i.s6:i.qy` <style>.sortable-fallback{display:none!important}.sortable-ghost{box-shadow:0 0 0 2px var(--primary-color);background:rgba(var(--rgb-primary-color),.25);border-radius:var(--ha-border-radius-sm);opacity:.4}.sortable-drag{border-radius:var(--ha-border-radius-sm);opacity:1;background:var(--card-background-color);box-shadow:0px 4px 8px 3px #00000026;cursor:grabbing}</style> `}async _createSortable(){if(this._sortable)return;const e=this.children[0];if(!e)return;const t=(await Promise.all([a.e(85283),a.e(70322)]).then(a.bind(a,80745))).default,r={scroll:!0,forceAutoScrollFallback:!0,scrollSpeed:20,animation:150,...this.options,onChoose:this._handleChoose,onStart:this._handleStart,onEnd:this._handleEnd,onUpdate:this._handleUpdate,onAdd:this._handleAdd,onRemove:this._handleRemove};this.draggableSelector&&(r.draggable=this.draggableSelector),this.handleSelector&&(r.handle=this.handleSelector),void 0!==this.invertSwap&&(r.invertSwap=this.invertSwap),this.group&&(r.group=this.group),this.filter&&(r.filter=this.filter),this._sortable=new t(e,r)}_destroySortable(){this._sortable&&(this._sortable.destroy(),this._sortable=void 0)}constructor(...e){super(...e),this.disabled=!1,this.noStyle=!1,this.invertSwap=!1,this.rollback=!0,this._shouldBeDestroy=!1,this._handleUpdate=e=>{(0,n.r)(this,"item-moved",{newIndex:e.newIndex,oldIndex:e.oldIndex})},this._handleAdd=e=>{(0,n.r)(this,"item-added",{index:e.newIndex,data:e.item.sortableData,item:e.item})},this._handleRemove=e=>{(0,n.r)(this,"item-removed",{index:e.oldIndex})},this._handleEnd=async e=>{(0,n.r)(this,"drag-end"),this.rollback&&e.item.placeholder&&(e.item.placeholder.replaceWith(e.item),delete e.item.placeholder)},this._handleStart=()=>{(0,n.r)(this,"drag-start")},this._handleChoose=e=>{this.rollback&&(e.item.placeholder=document.createComment("sort-placeholder"),e.item.after(e.item.placeholder))}}}(0,r.Cg)([(0,o.MZ)({type:Boolean})],l.prototype,"disabled",void 0),(0,r.Cg)([(0,o.MZ)({type:Boolean,attribute:"no-style"})],l.prototype,"noStyle",void 0),(0,r.Cg)([(0,o.MZ)({type:String,attribute:"draggable-selector"})],l.prototype,"draggableSelector",void 0),(0,r.Cg)([(0,o.MZ)({type:String,attribute:"handle-selector"})],l.prototype,"handleSelector",void 0),(0,r.Cg)([(0,o.MZ)({type:String,attribute:"filter"})],l.prototype,"filter",void 0),(0,r.Cg)([(0,o.MZ)({type:String})],l.prototype,"group",void 0),(0,r.Cg)([(0,o.MZ)({type:Boolean,attribute:"invert-swap"})],l.prototype,"invertSwap",void 0),(0,r.Cg)([(0,o.MZ)({attribute:!1})],l.prototype,"options",void 0),(0,r.Cg)([(0,o.MZ)({type:Boolean})],l.prototype,"rollback",void 0),l=(0,r.Cg)([(0,o.EM)("ha-sortable")],l)},70407(e,t,a){a.d(t,{Y:()=>r,e:()=>i});const r=(e,t)=>e.callWS({type:"number/device_class_convertible_units",device_class:t}),i=["%","A","B","B/s","BTU/(h⋅ft²)","Beaufort","CCF","EB","EiB","GB","GB/s","GHz","GJ","GW","GWh","Gbit","Gbit/s","Gcal","GiB","GiB/s","Hz","J","K","KiB","KiB/s","L","L/h","L/min","L/s","MB","MB/s","MCF","MHz","MJ","MV","MW","MWh","Mbit","Mbit/s","Mcal","MiB","MiB/s","PB","Pa","PiB","S/cm","TB","TW","TWh","TiB","V","VA","W","W/m²","Wh","Wh/km","YB","YiB","ZB","ZiB","ac","bar","bit","bit/s","cal","cbar","cm","cm²","d","dB","dBA","dBm","fl. oz.","ft","ft/s","ft²","ft³","ft³/min","g","g/m³","gal","gal/d","gal/h","gal/min","h","hPa","ha","in","in/d","in/h","in/s","inHg","inH₂O","in²","kB","kB/s","kHz","kJ","kPa","kV","kVA","kW","kWh","kWh/100km","kbit","kbit/s","kcal","kg","km","km/h","km/kWh","km²","kn","kvar","kvarh","lb","lx","m","m/min","m/s","mA","mHz","mL","mL/s","mPa","mS/cm","mV","mVA","mW","mWh","mbar","mg","mg/dL","mg/m³","mi","mi/kWh","min","mi²","mm","mm/d","mm/h","mm/s","mmHg","mmol/L","mm²","mph","ms","mvar","m²","m³","m³/h","m³/min","m³/s","nmi","oz","ppb","ppm","psi","s","st","var","varh","yd","yd²","°","°C","°F","μA","μS/cm","μV","μg","μg/m³","μs"]},97577(e,t,a){a.d(t,{A:()=>f});var r=a(5124),i=a(22441),o=a(6412),n=a(63672),l=a(34514),s=a(40991),c=a(92070),d=a(49546),h=a(9395),p=a(62676),m=a(15477),u=a(31896),v=(a(38625),r.AH`: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)}`),g=Object.defineProperty,b=Object.getOwnPropertyDescriptor,y=(e,t,a,r)=>{for(var i,o=r>1?void 0:r?b(t,a):t,n=e.length-1;n>=0;n--)(i=e[n])&&(o=(r?i(t,a,o):i(o))||o);return r&&o&&g(t,a,o),o};let f=class extends p.q{static get validators(){const e=r.S$?[]:[(0,d.Y)({validationProperty:"checked",validationElement:Object.assign(document.createElement("input"),{type:"checkbox",required:!0})})];return[...super.validators,...e]}get value(){return this._value??"on"}set value(e){this._value=e}handleSizeChange(){(0,s.b)(this.localName,this.size)}get checked(){return this.valueHasChanged?Boolean(this._checked):this._checked??this.defaultChecked}set checked(e){this._checked=Boolean(e),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(e){super.willUpdate(e),(e.has("value")||e.has("checked")||e.has("defaultChecked"))&&this.handleValueOrCheckedChange()}formResetCallback(){this._checked=null,super.formResetCallback(),this.handleValueOrCheckedChange()}click(){this.input.click()}focus(e){this.input.focus(e)}blur(){this.input.blur()}render(){const e=!!r.S$||this.hasSlotController.test("hint"),t=!!this.hint||!!e,a=!this.checked&&this.indeterminate,i=a?"indeterminate":"check",s=a?"indeterminate":"check";return r.qy` <label part="base"> <span part="control"> <input class="input" type="checkbox" title="${this.title}" name="${(0,n.J)(this.name)}" value="${(0,n.J)(this._value)}" .indeterminate="${(0,l.V)(this.indeterminate)}" .checked="${(0,l.V)(this.checked)}" .disabled="${this.disabled}" .required="${this.required}" aria-checked="${this.indeterminate?"mixed":this.checked?"true":"false"}" aria-describedby="hint" @click="${this.handleClick}"> <wa-icon part="${s}-icon icon" library="system" name="${i}"></wa-icon> </span> <slot part="label"></slot> </label> <slot id="hint" part="hint" name="hint" aria-hidden="${t?"false":"true"}" class="${(0,o.H)({"has-slotted":t})}"> ${this.hint} </slot> `}constructor(){super(...arguments),this.hasSlotController=new c.X(this,"hint"),this.title="",this.name=null,this._value=this.getAttribute("value")??null,this.size="m",this.disabled=!1,this.indeterminate=!1,this._checked=null,this.defaultChecked=this.hasAttribute("checked"),this.required=!1,this.hint=""}};f.css=[m.A,u.A,v],f.shadowRootOptions={...p.q.shadowRootOptions,delegatesFocus:!0},y([(0,i.P)('input[type="checkbox"]')],f.prototype,"input",2),y([(0,i.MZ)()],f.prototype,"title",2),y([(0,i.MZ)({reflect:!0})],f.prototype,"name",2),y([(0,i.MZ)({reflect:!0})],f.prototype,"value",1),y([(0,i.MZ)({reflect:!0})],f.prototype,"size",2),y([(0,h.w)("size")],f.prototype,"handleSizeChange",1),y([(0,i.MZ)({type:Boolean})],f.prototype,"disabled",2),y([(0,i.MZ)({type:Boolean,reflect:!0})],f.prototype,"indeterminate",2),y([(0,i.MZ)({type:Boolean,attribute:!1})],f.prototype,"checked",1),y([(0,i.MZ)({type:Boolean,reflect:!0,attribute:"checked"})],f.prototype,"defaultChecked",2),y([(0,i.MZ)({type:Boolean,reflect:!0})],f.prototype,"required",2),y([(0,i.MZ)()],f.prototype,"hint",2),y([(0,h.w)(["checked","defaultChecked"])],f.prototype,"handleDefaultCheckedChange",1),y([(0,h.w)(["checked","indeterminate"])],f.prototype,"handleStateChange",1),y([(0,h.w)("disabled")],f.prototype,"handleDisabledChange",1),f=y([(0,i.EM)("wa-checkbox")],f),f.disableWarning?.("change-in-update")},49546(e,t,a){a.d(t,{Y:()=>r});a(44114);const r=(e={})=>{let{validationElement:t,validationProperty:a}=e;t||(t=Object.assign(document.createElement("input"),{required:!0})),a||(a="value");const r={observedAttributes:["required"],message:t.validationMessage,checkValidity(e){const t={message:"",isValid:!0,invalidKeys:[]};if(!(e.required??e.hasAttribute("required")))return t;return!e[a]&&(t.message="function"==typeof r.message?r.message(e):r.message||"",t.isValid=!1,t.invalidKeys.push("valueMissing")),t}};return r}},41216(e,t,a){a.d(t,{R:()=>s});var r=a(62826),i=a(5124),o=a(22441),n=a(64918),l=a(84842);class s extends n.M{get primaryId(){return this.href?"link":this.removeOnly?"":"button"}get rippleDisabled(){return!this.href&&(this.disabled||this.softDisabled)}get primaryAction(){return this.removeOnly?null:this.renderRoot.querySelector(".primary.action")}getContainerClasses(){return{...super.getContainerClasses(),avatar:this.avatar,disabled:!this.href&&(this.disabled||this.softDisabled),link:!!this.href,selected:this.selected,"has-trailing":!0}}renderPrimaryAction(e){const{ariaLabel:t}=this;return this.href?i.qy` <a class="primary action" id="link" aria-label="${t||i.s6}" href="${this.href}" target="${this.target||i.s6}">${e}</a> `:this.removeOnly?i.qy` <span class="primary action" aria-label="${t||i.s6}"> ${e} </span> `:i.qy` <button class="primary action" id="button" aria-label="${t||i.s6}" aria-disabled="${this.softDisabled||i.s6}" ?disabled="${this.disabled&&!this.alwaysFocusable}" type="button">${e}</button> `}renderTrailingAction(e){return(0,l.h)({focusListener:e,ariaLabel:this.ariaLabelRemove,disabled:!this.href&&(this.disabled||this.softDisabled),tabbable:this.removeOnly})}constructor(){super(...arguments),this.avatar=!1,this.href="",this.target="",this.removeOnly=!1,this.selected=!1}}(0,r.Cg)([(0,o.MZ)({type:Boolean})],s.prototype,"avatar",void 0),(0,r.Cg)([(0,o.MZ)()],s.prototype,"href",void 0),(0,r.Cg)([(0,o.MZ)()],s.prototype,"target",void 0),(0,r.Cg)([(0,o.MZ)({type:Boolean,attribute:"remove-only"})],s.prototype,"removeOnly",void 0),(0,r.Cg)([(0,o.MZ)({type:Boolean,reflect:!0})],s.prototype,"selected",void 0),(0,r.Cg)([(0,o.P)(".trailing.action")],s.prototype,"trailingAction",void 0)},78960(e,t,a){a.d(t,{R:()=>r});const r=a(5124).AH`:host{--_container-height:var(--md-input-chip-container-height, 32px);--_disabled-label-text-color:var(--md-input-chip-disabled-label-text-color, var(--md-sys-color-on-surface, #1d1b20));--_disabled-label-text-opacity:var(--md-input-chip-disabled-label-text-opacity, 0.38);--_disabled-selected-container-color:var(--md-input-chip-disabled-selected-container-color, var(--md-sys-color-on-surface, #1d1b20));--_disabled-selected-container-opacity:var(--md-input-chip-disabled-selected-container-opacity, 0.12);--_label-text-font:var(--md-input-chip-label-text-font, var(--md-sys-typescale-label-large-font, var(--md-ref-typeface-plain, Roboto)));--_label-text-line-height:var(--md-input-chip-label-text-line-height, var(--md-sys-typescale-label-large-line-height, 1.25rem));--_label-text-size:var(--md-input-chip-label-text-size, var(--md-sys-typescale-label-large-size, 0.875rem));--_label-text-weight:var(--md-input-chip-label-text-weight, var(--md-sys-typescale-label-large-weight, var(--md-ref-typeface-weight-medium, 500)));--_selected-container-color:var(--md-input-chip-selected-container-color, var(--md-sys-color-secondary-container, #e8def8));--_selected-focus-label-text-color:var(--md-input-chip-selected-focus-label-text-color, var(--md-sys-color-on-secondary-container, #1d192b));--_selected-hover-label-text-color:var(--md-input-chip-selected-hover-label-text-color, var(--md-sys-color-on-secondary-container, #1d192b));--_selected-hover-state-layer-color:var(--md-input-chip-selected-hover-state-layer-color, var(--md-sys-color-on-secondary-container, #1d192b));--_selected-hover-state-layer-opacity:var(--md-input-chip-selected-hover-state-layer-opacity, 0.08);--_selected-label-text-color:var(--md-input-chip-selected-label-text-color, var(--md-sys-color-on-secondary-container, #1d192b));--_selected-outline-width:var(--md-input-chip-selected-outline-width, 0px);--_selected-pressed-label-text-color:var(--md-input-chip-selected-pressed-label-text-color, var(--md-sys-color-on-secondary-container, #1d192b));--_selected-pressed-state-layer-color:var(--md-input-chip-selected-pressed-state-layer-color, var(--md-sys-color-on-secondary-container, #1d192b));--_selected-pressed-state-layer-opacity:var(--md-input-chip-selected-pressed-state-layer-opacity, 0.12);--_disabled-outline-color:var(--md-input-chip-disabled-outline-color, var(--md-sys-color-on-surface, #1d1b20));--_disabled-outline-opacity:var(--md-input-chip-disabled-outline-opacity, 0.12);--_focus-label-text-color:var(--md-input-chip-focus-label-text-color, var(--md-sys-color-on-surface-variant, #49454f));--_focus-outline-color:var(--md-input-chip-focus-outline-color, var(--md-sys-color-on-surface-variant, #49454f));--_hover-label-text-color:var(--md-input-chip-hover-label-text-color, var(--md-sys-color-on-surface-variant, #49454f));--_hover-state-layer-color:var(--md-input-chip-hover-state-layer-color, var(--md-sys-color-on-surface-variant, #49454f));--_hover-state-layer-opacity:var(--md-input-chip-hover-state-layer-opacity, 0.08);--_label-text-color:var(--md-input-chip-label-text-color, var(--md-sys-color-on-surface-variant, #49454f));--_outline-color:var(--md-input-chip-outline-color, var(--md-sys-color-outline, #79747e));--_outline-width:var(--md-input-chip-outline-width, 1px);--_pressed-label-text-color:var(--md-input-chip-pressed-label-text-color, var(--md-sys-color-on-surface-variant, #49454f));--_pressed-state-layer-color:var(--md-input-chip-pressed-state-layer-color, var(--md-sys-color-on-surface-variant, #49454f));--_pressed-state-layer-opacity:var(--md-input-chip-pressed-state-layer-opacity, 0.12);--_avatar-shape:var(--md-input-chip-avatar-shape, var(--md-sys-shape-corner-full, 9999px));--_avatar-size:var(--md-input-chip-avatar-size, 24px);--_disabled-avatar-opacity:var(--md-input-chip-disabled-avatar-opacity, 0.38);--_disabled-leading-icon-color:var(--md-input-chip-disabled-leading-icon-color, var(--md-sys-color-on-surface, #1d1b20));--_disabled-leading-icon-opacity:var(--md-input-chip-disabled-leading-icon-opacity, 0.38);--_icon-size:var(--md-input-chip-icon-size, 18px);--_selected-focus-leading-icon-color:var(--md-input-chip-selected-focus-leading-icon-color, var(--md-sys-color-primary, #6750a4));--_selected-hover-leading-icon-color:var(--md-input-chip-selected-hover-leading-icon-color, var(--md-sys-color-primary, #6750a4));--_selected-leading-icon-color:var(--md-input-chip-selected-leading-icon-color, var(--md-sys-color-primary, #6750a4));--_selected-pressed-leading-icon-color:var(--md-input-chip-selected-pressed-leading-icon-color, var(--md-sys-color-primary, #6750a4));--_focus-leading-icon-color:var(--md-input-chip-focus-leading-icon-color, var(--md-sys-color-primary, #6750a4));--_hover-leading-icon-color:var(--md-input-chip-hover-leading-icon-color, var(--md-sys-color-primary, #6750a4));--_leading-icon-color:var(--md-input-chip-leading-icon-color, var(--md-sys-color-primary, #6750a4));--_pressed-leading-icon-color:var(--md-input-chip-pressed-leading-icon-color, var(--md-sys-color-primary, #6750a4));--_disabled-trailing-icon-color:var(--md-input-chip-disabled-trailing-icon-color, var(--md-sys-color-on-surface, #1d1b20));--_disabled-trailing-icon-opacity:var(--md-input-chip-disabled-trailing-icon-opacity, 0.38);--_selected-focus-trailing-icon-color:var(--md-input-chip-selected-focus-trailing-icon-color, var(--md-sys-color-on-secondary-container, #1d192b));--_selected-hover-trailing-icon-color:var(--md-input-chip-selected-hover-trailing-icon-color, var(--md-sys-color-on-secondary-container, #1d192b));--_selected-pressed-trailing-icon-color:var(--md-input-chip-selected-pressed-trailing-icon-color, var(--md-sys-color-on-secondary-container, #1d192b));--_selected-trailing-icon-color:var(--md-input-chip-selected-trailing-icon-color, var(--md-sys-color-on-secondary-container, #1d192b));--_focus-trailing-icon-color:var(--md-input-chip-focus-trailing-icon-color, var(--md-sys-color-on-surface-variant, #49454f));--_hover-trailing-icon-color:var(--md-input-chip-hover-trailing-icon-color, var(--md-sys-color-on-surface-variant, #49454f));--_pressed-trailing-icon-color:var(--md-input-chip-pressed-trailing-icon-color, var(--md-sys-color-on-surface-variant, #49454f));--_trailing-icon-color:var(--md-input-chip-trailing-icon-color, var(--md-sys-color-on-surface-variant, #49454f));--_container-shape-start-start:var(--md-input-chip-container-shape-start-start, var(--md-input-chip-container-shape, var(--md-sys-shape-corner-small, 8px)));--_container-shape-start-end:var(--md-input-chip-container-shape-start-end, var(--md-input-chip-container-shape, var(--md-sys-shape-corner-small, 8px)));--_container-shape-end-end:var(--md-input-chip-container-shape-end-end, var(--md-input-chip-container-shape, var(--md-sys-shape-corner-small, 8px)));--_container-shape-end-start:var(--md-input-chip-container-shape-end-start, var(--md-input-chip-container-shape, var(--md-sys-shape-corner-small, 8px)));--_leading-space:var(--md-input-chip-leading-space, 16px);--_trailing-space:var(--md-input-chip-trailing-space, 16px);--_icon-label-space:var(--md-input-chip-icon-label-space, 8px);--_with-leading-icon-leading-space:var(--md-input-chip-with-leading-icon-leading-space, 8px);--_with-trailing-icon-trailing-space:var(--md-input-chip-with-trailing-icon-trailing-space, 8px)}:host([avatar]){--_container-shape-start-start:var( --md-input-chip-container-shape-start-start, var(--md-input-chip-container-shape, calc(var(--_container-height) / 2)) );--_container-shape-start-end:var( --md-input-chip-container-shape-start-end, var(--md-input-chip-container-shape, calc(var(--_container-height) / 2)) );--_container-shape-end-end:var( --md-input-chip-container-shape-end-end, var(--md-input-chip-container-shape, calc(var(--_container-height) / 2)) );--_container-shape-end-start:var( --md-input-chip-container-shape-end-start, var(--md-input-chip-container-shape, calc(var(--_container-height) / 2)) )}.avatar .primary.action{padding-inline-start:4px}.avatar .leading.icon ::slotted(:first-child){border-radius:var(--_avatar-shape);height:var(--_avatar-size);width:var(--_avatar-size)}.disabled.avatar .leading.icon{opacity:var(--_disabled-avatar-opacity)}@media(forced-colors:active){.link .outline{border-color:ActiveText}.disabled.avatar .leading.icon{opacity:1}}`},75751(e,t,a){a.d(t,{u:()=>l});a(45367),a(92731);var r=a(5055),i=a(42017),o=a(63937);const n=(e,t,a)=>{const r=new Map;for(let i=t;i<=a;i++)r.set(e[i],i);return r},l=(0,i.u$)(class extends i.WL{dt(e,t,a){let r;void 0===a?a=t:void 0!==t&&(r=t);const i=[],o=[];let n=0;for(const t of e)i[n]=r?r(t,n):n,o[n]=a(t,n),n++;return{values:o,keys:i}}render(e,t,a){return this.dt(e,t,a).values}update(e,[t,a,i]){const l=(0,o.cN)(e),{values:s,keys:c}=this.dt(t,a,i);if(!Array.isArray(l))return this.ut=c,s;const d=this.ut??=[],h=[];let p,m,u=0,v=l.length-1,g=0,b=s.length-1;for(;u<=v&&g<=b;)if(null===l[u])u++;else if(null===l[v])v--;else if(d[u]===c[g])h[g]=(0,o.lx)(l[u],s[g]),u++,g++;else if(d[v]===c[b])h[b]=(0,o.lx)(l[v],s[b]),v--,b--;else if(d[u]===c[b])h[b]=(0,o.lx)(l[u],s[b]),(0,o.Dx)(e,h[b+1],l[u]),u++,b--;else if(d[v]===c[g])h[g]=(0,o.lx)(l[v],s[g]),(0,o.Dx)(e,l[u],l[v]),v--,g++;else if(void 0===p&&(p=n(c,g,b),m=n(d,u,v)),p.has(d[u]))if(p.has(d[v])){const t=m.get(c[g]),a=void 0!==t?l[t]:null;if(null===a){const t=(0,o.Dx)(e,l[u]);(0,o.lx)(t,s[g]),h[g]=t}else h[g]=(0,o.lx)(a,s[g]),(0,o.Dx)(e,l[u],a),l[t]=null;g++}else(0,o.KO)(l[v]),v--;else(0,o.KO)(l[u]),u++;for(;g<=b;){const t=(0,o.Dx)(e,h[b+1]);(0,o.lx)(t,s[g]),h[g++]=t}for(;u<=v;){const e=l[u++];null!==e&&(0,o.KO)(e)}return this.ut=c,(0,o.mY)(e,h),r.c0}constructor(e){if(super(e),e.type!==i.OA.CHILD)throw Error("repeat() can only be used in text expressions")}})}};