"use strict";(self.rspackChunkhome_assistant_frontend=self.rspackChunkhome_assistant_frontend||[]).push([[70473],{58672:function(e,r,n){n.a(e,async function(e,t){try{n.r(r);var i,o,a,c=n(28430),s=n(57567),g=n(25979),h=n(12463),f=n(16472),u=n(15697),l=n(41324),d=n(57527),p=n(51209),v=(n(53384),n(41247),n(77280)),_=e([v]);v=(_.then?(await _)():_)[0];var y=function(e){var r=document.createElement("hui-error-heading-badge");return r.setConfig(e),r},A=function(e){return{type:"error",error:e}},w=function(e){function r(){return(0,s.A)(this,r),(0,f.A)(this,r,arguments)}return(0,h.A)(r,e),(0,g.A)(r,[{key:"setConfig",value:function(e){this._config=e}},{key:"_viewDetail",value:function(){var e,r;if(this._config.origConfig)try{r=(0,l.dump)(this._config.origConfig)}catch(n){r="[Error dumping ".concat(this._config.origConfig,"]")}(0,v.showAlertDialog)(this,{title:null===(e=this._config)||void 0===e?void 0:e.error,warning:!0,text:r?(0,d.qy)(i||(i=(0,c.A)(["<pre>","</pre>"])),r):""})}},{key:"render",value:function(){return this._config?(0,d.qy)(o||(o=(0,c.A)([' <ha-heading-badge class="error" @click=',' type="button" .title=','> <ha-svg-icon slot="icon" .path=','></ha-svg-icon> <span class="content">',"</span> </ha-heading-badge> "])),this._viewDetail,this._config.error,"M13,13H11V7H13M13,17H11V15H13M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2Z",this._config.error):d.s6}}])}(d.WF);w.styles=(0,d.AH)(a||(a=(0,c.A)(["ha-heading-badge{--icon-color:var(--error-color);color:var(--error-color)}.content{text-overflow:ellipsis;white-space:nowrap;max-width:70px;overflow:hidden}pre{font-family:var(--ha-font-family-code);white-space:break-spaces;user-select:text}"]))),(0,u.Cg)([(0,p.wk)()],w.prototype,"_config",void 0),w=(0,u.Cg)([(0,p.EM)("hui-error-heading-badge")],w),n.d(r,{HuiErrorHeadingBadge:function(){return w},createErrorHeadingBadgeConfig:function(){return A},createErrorHeadingBadgeElement:function(){return y}}),t()}catch(k){t(k)}})}}]);
//# sourceMappingURL=70473.476cd4aa966c3bff.js.map