iobroker.lovelace
Version:
With this adapter you can build visualization for ioBroker with Home Assistant Lovelace UI
3 lines • 20.8 kB
JavaScript
/*! For license information please see 37008.0ef74c9f2bd02055.js.LICENSE.txt */
"use strict";(self.webpackChunkhome_assistant_frontend=self.webpackChunkhome_assistant_frontend||[]).push([["37008"],{12582:function(e,t,i){i.d(t,{Z:()=>n});i(9359),i(31526),i(70104),i(11740);function n(e){if(!e||"object"!=typeof e)return e;if("[object Date]"==Object.prototype.toString.call(e))return new Date(e.getTime());if(Array.isArray(e))return e.map(n);var t={};return Object.keys(e).forEach((function(i){t[i]=n(e[i])})),t}},92824:function(e,t,i){var n=i(61701),o=i(72621),s=(i(71695),i(40251),i(47021),i(60930)),a=i(9714),l=i(57243),r=i(50778),d=i(22381),c=i(76320);i(23334);let h,u,m,f,v=e=>e;(0,n.Z)([(0,r.Mo)("ha-select")],(function(e,t){class i extends t{constructor(...t){super(...t),e(this)}}return{F:i,d:[{kind:"field",decorators:[(0,r.Cb)({type:Boolean})],key:"icon",value(){return!1}},{kind:"field",decorators:[(0,r.Cb)({type:Boolean,reflect:!0})],key:"clearable",value(){return!1}},{kind:"field",decorators:[(0,r.Cb)({attribute:"inline-arrow",type:Boolean})],key:"inlineArrow",value(){return!1}},{kind:"field",decorators:[(0,r.Cb)()],key:"options",value:void 0},{kind:"method",key:"render",value:function(){return(0,l.dy)(h||(h=v` ${0} ${0} `),(0,o.Z)(i,"render",this,3)([]),this.clearable&&!this.required&&!this.disabled&&this.value?(0,l.dy)(u||(u=v`<ha-icon-button label="clear" ="${0}" .path="${0}"></ha-icon-button>`),this._clearValue,"M19,6.41L17.59,5L12,10.59L6.41,5L5,6.41L10.59,12L5,17.59L6.41,19L12,13.41L17.59,19L19,17.59L13.41,12L19,6.41Z"):l.Ld)}},{kind:"method",key:"renderLeadingIcon",value:function(){return this.icon?(0,l.dy)(m||(m=v`<span class="mdc-select__icon"><slot name="icon"></slot></span>`)):l.Ld}},{kind:"method",key:"connectedCallback",value:function(){(0,o.Z)(i,"connectedCallback",this,3)([]),window.addEventListener("translations-updated",this._translationsUpdated)}},{kind:"method",key:"firstUpdated",value:async function(){var e;((0,o.Z)(i,"firstUpdated",this,3)([]),this.inlineArrow)&&(null===(e=this.shadowRoot)||void 0===e||null===(e=e.querySelector(".mdc-select__selected-text-container"))||void 0===e||e.classList.add("inline-arrow"))}},{kind:"method",key:"updated",value:function(e){if((0,o.Z)(i,"updated",this,3)([e]),e.has("inlineArrow")){var t;const e=null===(t=this.shadowRoot)||void 0===t?void 0:t.querySelector(".mdc-select__selected-text-container");this.inlineArrow?null==e||e.classList.add("inline-arrow"):null==e||e.classList.remove("inline-arrow")}e.get("options")&&(this.layoutOptions(),this.selectByValue(this.value))}},{kind:"method",key:"disconnectedCallback",value:function(){(0,o.Z)(i,"disconnectedCallback",this,3)([]),window.removeEventListener("translations-updated",this._translationsUpdated)}},{kind:"method",key:"_clearValue",value:function(){!this.disabled&&this.value&&(this.valueSetDirectly=!0,this.select(-1),this.mdcFoundation.handleChange())}},{kind:"field",key:"_translationsUpdated",value(){return(0,d.D)((async()=>{await(0,c.y)(),this.layoutOptions()}),500)}},{kind:"field",static:!0,key:"styles",value(){return[a.W,(0,l.iv)(f||(f=v`:host([clearable]){position:relative}.mdc-select:not(.mdc-select--disabled) .mdc-select__icon{color:var(--secondary-text-color)}.mdc-select__anchor{width:var(--ha-select-min-width,200px)}.mdc-select--filled .mdc-select__anchor{height:var(--ha-select-height,56px)}.mdc-select--filled .mdc-floating-label{inset-inline-start:12px;inset-inline-end:initial;direction:var(--direction)}.mdc-select--filled.mdc-select--with-leading-icon .mdc-floating-label{inset-inline-start:48px;inset-inline-end:initial;direction:var(--direction)}.mdc-select .mdc-select__anchor{padding-inline-start:12px;padding-inline-end:0px;direction:var(--direction)}.mdc-select__anchor .mdc-floating-label--float-above{transform-origin:var(--float-start)}.mdc-select__selected-text-container{padding-inline-end:var(--select-selected-text-padding-end,0px)}:host([clearable]) .mdc-select__selected-text-container{padding-inline-end:var(--select-selected-text-padding-end,12px)}ha-icon-button{position:absolute;top:10px;right:28px;--mdc-icon-button-size:36px;--mdc-icon-size:20px;color:var(--secondary-text-color);inset-inline-start:initial;inset-inline-end:28px;direction:var(--direction)}.inline-arrow{flex-grow:0}`))]}}]}}),s.K)},75625:function(e,t,i){i.a(e,(async function(e,n){try{i.d(t,{L:()=>a});i(19423),i(40251);var o=i(25508),s=e([o]);o=(s.then?(await s)():s)[0];const a=async(e,t,i,n)=>{let s={type:t};"conditional"!==t&&(s.style={left:"50%",top:"50%"});const a=await(0,o.Q)(t);if(a&&a.getStubConfig){const t=await a.getStubConfig(e,i,n);s=Object.assign(Object.assign({},s),t)}return s};n()}catch(a){n(a)}}))},32012:function(e,t,i){i.d(t,{e:()=>n});i(52247);class n extends Error{constructor(e,t,i){super(e),this.warnings=void 0,this.errors=void 0,this.name="GUISupportError",this.warnings=t,this.errors=i}}},43299:function(e,t,i){i.a(e,(async function(e,n){try{i.d(t,{O:()=>B});var o=i(61701),s=i(72621),a=(i(71695),i(9359),i(31526),i(70104),i(19423),i(40251),i(47021),i(57243)),l=i(50778),r=i(67064),d=i(36522),c=i(22381),h=i(41680),u=i(48045),m=(i(99426),i(17170)),f=(i(64889),i(32012)),v=e([m]);m=(v.then?(await v)():v)[0];let g,p,y,_,k,b,E,w,C,x,$,L,S=e=>e,B=(0,o.Z)(null,(function(e,t){class n extends t{constructor(...t){super(...t),e(this)}}return{F:n,d:[{kind:"field",decorators:[(0,l.Cb)({attribute:!1})],key:"hass",value:void 0},{kind:"field",decorators:[(0,l.Cb)({attribute:!1})],key:"lovelace",value:void 0},{kind:"field",decorators:[(0,l.Cb)({attribute:!1})],key:"context",value:void 0},{kind:"field",decorators:[(0,l.SB)()],key:"_config",value:void 0},{kind:"field",decorators:[(0,l.SB)()],key:"_configElement",value:void 0},{kind:"field",decorators:[(0,l.SB)()],key:"_subElementEditorConfig",value:void 0},{kind:"field",decorators:[(0,l.SB)()],key:"_guiMode",value(){return!0}},{kind:"field",decorators:[(0,l.SB)()],key:"_errors",value:void 0},{kind:"field",decorators:[(0,l.SB)()],key:"_pendingYamlError",value:void 0},{kind:"field",decorators:[(0,l.SB)()],key:"_yamlError",value(){return!1}},{kind:"field",decorators:[(0,l.SB)()],key:"_warnings",value:void 0},{kind:"field",decorators:[(0,l.SB)()],key:"_guiSupported",value:void 0},{kind:"field",decorators:[(0,l.SB)()],key:"_loading",value(){return!1}},{kind:"field",decorators:[(0,l.IO)("ha-yaml-editor")],key:"_yamlEditor",value:void 0},{kind:"get",key:"value",value:function(){return this._config}},{kind:"set",key:"value",value:function(e){this._config&&(0,u.v)(e,this._config)||(this._config=e,this._errors=void 0,this._setConfig())}},{kind:"method",key:"_setConfig",value:function(){if(!this._errors)try{this._updateConfigElement()}catch(e){this._errors=[e.message]}this.updateComplete.then((()=>{var e;(0,d.B)(this,"config-changed",{config:this.value,error:null===(e=this._errors)||void 0===e?void 0:e.join(", "),guiModeAvailable:!(this.hasWarning||this.hasError||!1===this._guiSupported)})}))}},{kind:"get",key:"hasWarning",value:function(){return void 0!==this._warnings&&this._warnings.length>0}},{kind:"get",key:"hasError",value:function(){return void 0!==this._errors&&this._errors.length>0}},{kind:"get",key:"GUImode",value:function(){return this._guiMode}},{kind:"set",key:"GUImode",value:function(e){this._guiMode=e,this.updateComplete.then((()=>{(0,d.B)(this,"GUImode-changed",{guiMode:e,guiModeAvailable:!(this.hasWarning||this.hasError||!1===this._guiSupported)})}))}},{kind:"method",key:"toggleMode",value:function(){this.GUImode=!this.GUImode}},{kind:"method",key:"focusYamlEditor",value:function(){var e;null!==(e=this._configElement)&&void 0!==e&&e.focusYamlEditor&&this._configElement.focusYamlEditor(),this._yamlEditor&&this._yamlEditor.focus()}},{kind:"method",key:"getConfigElement",value:async function(){}},{kind:"method",key:"getConfigForm",value:async function(){}},{kind:"method",key:"renderConfigElement",value:function(){return(0,a.dy)(g||(g=S`${0}`),this._configElement)}},{kind:"method",key:"_renderSubElement",value:function(){return(0,a.dy)(p||(p=S` <hui-sub-element-editor .hass="${0}" .config="${0}" -back="${0}" -changed="${0}"> </hui-sub-element-editor> `),this.hass,this._subElementEditorConfig,this._goBack,this._subElementChanged)}},{kind:"method",key:"_subElementChanged",value:function(e){var t,i;e.stopPropagation();const n=e.detail.config;this._subElementEditorConfig=Object.assign(Object.assign({},this._subElementEditorConfig),{},{elementConfig:n}),null===(t=(i=this._subElementEditorConfig).saveElementConfig)||void 0===t||t.call(i,n)}},{kind:"method",key:"_goBack",value:function(e){e.stopPropagation(),this._subElementEditorConfig=void 0}},{kind:"method",key:"_editSubElement",value:async function(e){e.stopPropagation(),await Promise.all([i.e("91552"),i.e("78456"),i.e("56898"),i.e("35671"),i.e("92139"),i.e("32146"),i.e("47399"),i.e("51717"),i.e("18865"),i.e("44959"),i.e("79931"),i.e("44251"),i.e("65005"),i.e("60487"),i.e("3371"),i.e("38326"),i.e("10745"),i.e("80809"),i.e("92368"),i.e("37457"),i.e("95444"),i.e("29477"),i.e("8136")]).then(i.bind(i,50357)),this._subElementEditorConfig={type:e.detail.type,elementConfig:e.detail.config,context:e.detail.context,saveElementConfig:e.detail.saveConfig}}},{kind:"method",key:"render",value:function(){return(0,a.dy)(y||(y=S` <div class="wrapper"> ${0} ${0} ${0} ${0} </div> `),this.GUImode?(0,a.dy)(_||(_=S` <div class="gui-editor" -sub-element="${0}"> ${0} </div> `),this._editSubElement,this._loading?(0,a.dy)(k||(k=S` <ha-spinner class="center margin-bot"></ha-spinner> `)):(0,r.F)(this._subElementEditorConfig?this._renderSubElement():this.renderConfigElement())):(0,a.dy)(b||(b=S` <div class="yaml-editor"> <ha-yaml-editor .defaultValue="${0}" autofocus .hass="${0}" -changed="${0}" ="${0}" ="${0}" dir="ltr"></ha-yaml-editor> </div> `),this._config,this.hass,this._handleYAMLChanged,this._onBlurYaml,this._ignoreKeydown),!1===this._guiSupported&&!1===this._loading?(0,a.dy)(E||(E=S` <ha-alert alert-type="info" .title="${0}"> ${0} <br> ${0} </ha-alert> `),this.hass.localize("ui.errors.config.visual_editor_not_supported"),this.hass.localize("ui.errors.config.visual_editor_not_supported_reason_type"),this.hass.localize("ui.errors.config.edit_in_yaml_supported")):a.Ld,this.hasError?(0,a.dy)(w||(w=S` <ha-alert alert-type="error" .title="${0}"> <ul> ${0} </ul> </ha-alert> `),this.hass.localize("ui.errors.config.configuration_error"),this._errors.map((e=>(0,a.dy)(C||(C=S`<li>${0}</li>`),e)))):a.Ld,this.hasWarning?(0,a.dy)(x||(x=S` <ha-alert alert-type="warning" .title="${0}"> <ul> ${0} </ul> ${0} </ha-alert> `),this.hass.localize("ui.errors.config.visual_editor_not_supported"),this._warnings.map((e=>(0,a.dy)($||($=S`<li>${0}</li>`),e))),this.hass.localize("ui.errors.config.edit_in_yaml_supported")):a.Ld)}},{kind:"method",key:"updated",value:function(e){(0,s.Z)(n,"updated",this,3)([e]),this._configElement&&e.has("hass")&&(this._configElement.hass=this.hass),this._configElement&&"lovelace"in this._configElement&&e.has("lovelace")&&(this._configElement.lovelace=this.lovelace),this._configElement&&e.has("context")&&(this._configElement.context=this.context)}},{kind:"method",key:"_handleUIConfigChanged",value:function(e){if(e.stopPropagation(),!this.GUImode)return;const t=e.detail.config;Object.keys(t).forEach((e=>{void 0===t[e]&&delete t[e]})),this.value=t}},{kind:"method",key:"_handleYAMLChanged",value:function(e){e.stopPropagation();const t=e.detail.value;e.detail.isValid?(this._config=t,this._errors=void 0,this._pendingYamlError=void 0,this._yamlError=!1,this._debounceYamlError.cancel(),this._setConfig()):this._yamlError?this._errors=[e.detail.errorMsg]:(this._pendingYamlError=e.detail.errorMsg,this._debounceYamlError())}},{kind:"field",key:"_debounceYamlError",value(){return(0,c.D)((()=>{this._pendingYamlError&&(this._yamlError=!0,this._errors=[this._pendingYamlError],this._pendingYamlError=void 0,this._setConfig())}),2e3)}},{kind:"method",key:"_onBlurYaml",value:function(){this._debounceYamlError.cancel(),this._pendingYamlError&&(this._yamlError=!0,this._errors=[this._pendingYamlError],this._pendingYamlError=void 0,this._setConfig())}},{kind:"method",key:"unloadConfigElement",value:async function(){this._configElement=void 0,this._guiSupported=void 0}},{kind:"method",key:"loadConfigElement",value:async function(){if(this._configElement)return;let e=await this.getConfigElement();if(!e){const t=await this.getConfigForm();if(t){await i.e("10106").then(i.bind(i,66374)),e=document.createElement("hui-form-editor");const{schema:n,assertConfig:o,computeLabel:s,computeHelper:a}=t;e.schema=n,s&&(e.computeLabel=s),a&&(e.computeHelper=a),o&&(e.assertConfig=o)}}e?(e.hass=this.hass,"lovelace"in e&&(e.lovelace=this.lovelace),e.context=this.context,e.addEventListener("config-changed",(e=>this._handleUIConfigChanged(e))),this._guiSupported=!0):this._guiSupported=!1,this._configElement=e}},{kind:"method",key:"_updateConfigElement",value:async function(){if(this.value)try{if(this._errors=void 0,this._warnings=void 0,await this.loadConfigElement(),this._configElement)try{this._configElement.setConfig(this.value)}catch(t){const e=(0,h.p)(this.hass,t);throw new f.e("Config is not supported",e.warnings,e.errors)}else this._guiSupported=!1,this.GUImode=!1}catch(t){var e;if(t instanceof f.e)this._warnings=null!==(e=t.warnings)&&void 0!==e?e:[t.message],this._errors=t.errors||void 0;else this._errors=[t.message];this.GUImode=!1}finally{this._loading=!1}}},{kind:"method",key:"_ignoreKeydown",value:function(e){e.stopPropagation()}},{kind:"field",static:!0,key:"styles",value(){return(0,a.iv)(L||(L=S`:host{display:flex}.wrapper{width:100%}.gui-editor,.yaml-editor{padding:8px 0px}ha-code-editor{--code-mirror-max-height:calc(100vh - 245px)}ha-spinner{display:block;margin:auto}`))}}]}}),a.oi);n()}catch(g){n(g)}}))},13420:function(e,t,i){i.a(e,(async function(e,t){try{var n=i(61701),o=(i(71695),i(9359),i(70104),i(40251),i(11740),i(47021),i(12582)),s=i(57243),a=i(50778),l=i(36522),r=i(49976),d=(i(23334),i(37583),i(92824),i(76131)),c=i(75625),h=e([c]);c=(h.then?(await h)():h)[0];let u,m,f,v,g,p=e=>e;const y="M19,6.41L17.59,5L12,10.59L6.41,5L5,6.41L10.59,12L5,17.59L6.41,19L12,13.41L17.59,19L19,17.59L13.41,12L19,6.41Z",_="M20.71,7.04C21.1,6.65 21.1,6 20.71,5.63L18.37,3.29C18,2.9 17.35,2.9 16.96,3.29L15.12,5.12L18.87,8.87M3,17.25V21H6.75L17.81,9.93L14.06,6.18L3,17.25Z",k="M11,17H4A2,2 0 0,1 2,15V3A2,2 0 0,1 4,1H16V3H4V15H11V13L15,16L11,19V17M19,21V7H8V13H6V7A2,2 0 0,1 8,5H19A2,2 0 0,1 21,7V21A2,2 0 0,1 19,23H8A2,2 0 0,1 6,21V19H8V21H19Z",b=["state-badge","state-icon","state-label","action-button","icon","image","conditional"];(0,n.Z)([(0,a.Mo)("hui-picture-elements-card-row-editor")],(function(e,t){return{F:class extends t{constructor(...t){super(...t),e(this)}},d:[{kind:"field",decorators:[(0,a.Cb)({attribute:!1})],key:"hass",value:void 0},{kind:"field",decorators:[(0,a.Cb)({attribute:!1})],key:"elements",value:void 0},{kind:"field",decorators:[(0,a.IO)("ha-select")],key:"_select",value:void 0},{kind:"method",key:"render",value:function(){return this.elements&&this.hass?(0,s.dy)(u||(u=p` <h3> ${0} </h3> <div class="elements"> ${0} <ha-select fixedMenuPosition naturalMenuWidth .label="${0}" .value="${0}" ="${0}" ="${0}"> ${0} </ha-select> </div> `),this.hass.localize("ui.panel.lovelace.editor.card.picture-elements.elements"),this.elements.map(((e,t)=>{var i;return(0,s.dy)(m||(m=p` <div class="element"> ${0} <ha-icon-button .label="${0}" .path="${0}" class="remove-icon" .index="${0}" ="${0}"></ha-icon-button> <ha-icon-button .label="${0}" .path="${0}" class="edit-icon" .index="${0}" ="${0}"></ha-icon-button> <ha-icon-button .label="${0}" .path="${0}" class="duplicate-icon" .index="${0}" ="${0}"></ha-icon-button> </div> `),e.type?(0,s.dy)(f||(f=p` <div class="element-row"> <div> <span> ${0} </span> <span class="secondary">${0}</span> </div> </div> `),(null===(i=this.hass)||void 0===i?void 0:i.localize(`ui.panel.lovelace.editor.card.picture-elements.element_types.${e.type}`))||e.type,this._getSecondaryDescription(e)):s.Ld,this.hass.localize("ui.common.delete"),y,t,this._removeRow,this.hass.localize("ui.common.edit"),_,t,this._editRow,this.hass.localize("ui.common.duplicate"),k,t,this._duplicateRow)})),this.hass.localize("ui.panel.lovelace.editor.card.picture-elements.new_element"),"",r.U,this._addElement,b.map((e=>{var t;return(0,s.dy)(v||(v=p` <mwc-list-item .value="${0}">${0}</mwc-list-item> `),e,null===(t=this.hass)||void 0===t?void 0:t.localize(`ui.panel.lovelace.editor.card.picture-elements.element_types.${e}`))}))):s.Ld}},{kind:"method",key:"_getSecondaryDescription",value:function(e){var t,i,n,o,s,a,l,r,d,c,h,u,m;switch(e.type){case"icon":return null!==(t=null!==(i=e.title)&&void 0!==i?i:e.icon)&&void 0!==t?t:"";case"state-badge":case"state-icon":case"state-label":return null!==(n=null!==(o=e.title)&&void 0!==o?o:e.entity)&&void 0!==n?n:"";case"action-button":case"service-button":return null!==(s=null!==(a=null!==(l=e.title)&&void 0!==l?l:e.action)&&void 0!==a?a:e.service)&&void 0!==s?s:"";case"image":return null!==(r=null!==(d=null!==(c=e.title)&&void 0!==c?c:e.image)&&void 0!==d?d:e.camera_image)&&void 0!==r?r:"";case"conditional":return null!==(h=e.title)&&void 0!==h?h:`${(e.elements||[]).length.toString()} ${null===(u=this.hass)||void 0===u?void 0:u.localize("ui.panel.lovelace.editor.card.picture-elements.elements")}`}return null!==(m=e.title)&&void 0!==m?m:"Unknown type"}},{kind:"method",key:"_addElement",value:async function(e){const t=e.target.value;if(""===t)return;const i=this.elements.concat(await(0,c.L)(this.hass,t,Object.keys(this.hass.entities),[]));(0,l.B)(this,"elements-changed",{elements:i}),this._select.select(-1)}},{kind:"method",key:"_removeRow",value:function(e){var t;const i=e.currentTarget.index,n=null===(t=this.elements)||void 0===t?void 0:t[i];n&&(0,d.showConfirmationDialog)(this,{text:this.hass.localize("ui.panel.lovelace.editor.card.picture-elements.confirm_delete_element",{type:this.hass.localize(`ui.panel.lovelace.editor.card.picture-elements.element_types.${n.type}`)||n.type}),confirmText:this.hass.localize("ui.common.delete"),destructive:!0,confirm:()=>{const e=this.elements.concat();e.splice(i,1),(0,l.B)(this,"elements-changed",{elements:e})}})}},{kind:"method",key:"_editRow",value:function(e){const t=e.currentTarget.index;(0,l.B)(this,"edit-detail-element",{subElementConfig:{index:t,type:"element",elementConfig:this.elements[t]}})}},{kind:"method",key:"_duplicateRow",value:function(e){const t=e.currentTarget.index,i=[...this.elements,(0,o.Z)(this.elements[t])];(0,l.B)(this,"elements-changed",{elements:i})}},{kind:"field",static:!0,key:"styles",value(){return(0,s.iv)(g||(g=p`.element{display:flex;align-items:center}.element-row{height:60px;font-size:16px;display:flex;align-items:center;justify-content:space-between;flex-grow:1}.element-row div{display:flex;flex-direction:column}.duplicate-icon,.edit-icon,.remove-icon{--mdc-icon-button-size:36px;color:var(--secondary-text-color)}.secondary{font-size:12px;color:var(--secondary-text-color)}ha-select{width:100%}`))}}]}}),s.oi);t()}catch(u){t(u)}}))},6973:function(e,t,i){i.a(e,(async function(e,n){try{i.d(t,{k:()=>d});var o=i(61701),s=i(72621),a=(i(52247),i(71695),i(40251),i(47021),i(50778)),l=i(43299),r=e([l]);l=(r.then?(await r)():r)[0];let d=(0,o.Z)(null,(function(e,t){class i extends t{constructor(...t){super(...t),e(this)}}return{F:i,d:[{kind:"field",decorators:[(0,a.SB)()],key:"_configElementType",value:void 0},{kind:"get",key:"configElementType",value:function(){return this.value?this.value.type:void 0}},{kind:"method",key:"loadConfigElement",value:async function(){if(this._configElementType!==this.configElementType){if(this.unloadConfigElement(),!this.configElementType)throw new Error(this.hass.localize("ui.errors.config.no_type_provided"));this._configElementType=this.configElementType}return(0,s.Z)(i,"loadConfigElement",this,3)([])}}]}}),l.O);n()}catch(d){n(d)}}))},67064:function(e,t,i){i.d(t,{F:()=>l});i(71695),i(46692),i(47021);var n=i(2841),o=i(45779),s=i(53232);const a=e=>(0,s.dZ)(e)?e._$litType$.h:e.strings,l=(0,o.XM)(class extends o.Xe{constructor(e){super(e),this.tt=new WeakMap}render(e){return[e]}update(e,[t]){const i=(0,s.hN)(this.et)?a(this.et):null,o=(0,s.hN)(t)?a(t):null;if(null!==i&&(null===o||i!==o)){const t=(0,s.i9)(e).pop();let o=this.tt.get(i);if(void 0===o){const e=document.createDocumentFragment();o=(0,n.sY)(n.Ld,e),o.setConnected(!1),this.tt.set(i,o)}(0,s.hl)(o,[t]),(0,s._Y)(o,void 0,t)}if(null!==o){if(null===i||i!==o){const t=this.tt.get(o);if(void 0!==t){const i=(0,s.i9)(t).pop();(0,s.E_)(e),(0,s._Y)(e,void 0,i),(0,s.hl)(e,[i])}}this.et=t}else this.et=void 0;return this.render(t)}})}}]);
//# sourceMappingURL=37008.0ef74c9f2bd02055.js.map