/*! For license information please see 20295.d890ccd95b42f27b.js.LICENSE.txt */
"use strict";(self.webpackChunkhome_assistant_frontend=self.webpackChunkhome_assistant_frontend||[]).push([["20295"],{47351:function(e,s,t){t.d(s,{PS:function(){return r},Tv:function(){return i},VR:function(){return n},lE:function(){return c}});t(74423),t(3362),t(17642),t(58004),t(33853),t(45876),t(32475),t(15024),t(31698),t(62953);var o=t(62384);const r=e=>e.data,n=e=>"object"==typeof e?"object"==typeof e.body?e.body.message||"Unknown error, see supervisor logs":e.body||e.message||"Unknown error, see supervisor logs":e,a=new Set([502,503,504]),i=e=>!!(e&&e.status_code&&a.has(e.status_code))||!(!e||!e.message||!e.message.includes("ERR_CONNECTION_CLOSED")&&!e.message.includes("ERR_CONNECTION_RESET")),c=async(e,s)=>(0,o.v)(e.config.version,2021,2,4)?e.callWS({type:"supervisor/api",endpoint:`/${s}/stats`,method:"get"}):r(await e.callApi("GET",`hassio/${s}/stats`))},93132:function(e,s,t){t.a(e,async function(e,o){try{t.r(s),t.d(s,{HuiRecoveryModeCard:function(){return u}});var r=t(40445),n=t(96196),a=t(77845),i=(t(76776),t(22828)),c=e([i]);i=(c.then?(await c)():c)[0];let d,h,l=e=>e;class u extends n.WF{getCardSize(){return 3}setConfig(e){}render(){return(0,n.qy)(d||(d=l` <ha-card .header="${0}"> <div class="card-content"> ${0} </div> <error-log-card .hass="${0}" provider="core"></error-log-card> </ha-card> `),this.hass.localize("ui.panel.lovelace.cards.recovery-mode.header"),this.hass.localize("ui.panel.lovelace.cards.recovery-mode.description"),this.hass)}}u.styles=(0,n.AH)(h||(h=l`ha-card{--ha-card-header-color:var(--primary-color)}error-log-card{display:block;padding-bottom:16px}`)),(0,r.Cg)([(0,a.MZ)({attribute:!1})],u.prototype,"hass",void 0),u=(0,r.Cg)([(0,a.EM)("hui-recovery-mode-card")],u),o()}catch(d){o(d)}})},35463:function(e,s,t){t.d(s,{Q:function(){return o}});t(3362),t(17642),t(58004),t(33853),t(45876),t(32475),t(15024),t(31698),t(62953);class o{handleChanges(e){var s;this.value=null===(s=this.callback)||void 0===s?void 0:s.call(this,e,this.u)}hostConnected(){for(const e of this.t)this.observe(e)}hostDisconnected(){this.disconnect()}async hostUpdated(){const e=this.u.takeRecords();e.length&&this.handleChanges(e)}observe(e){this.t.add(e),this.u.observe(e),this.i=!0}unobserve(e){this.t.delete(e),this.u.unobserve(e)}disconnect(){this.u.disconnect()}constructor(e,{target:s,config:t,callback:o,skipInitial:r}){this.t=new Set,this.o=!1,this.i=!1,this.h=e,null!==s&&this.t.add(null!=s?s:e),this.o=null!=r?r:this.o,this.callback=o,window.IntersectionObserver?(this.u=new IntersectionObserver(e=>{const s=this.i;this.i=!1,this.o&&s||(this.handleChanges(e),this.h.requestUpdate())},t),e.addController(this)):console.warn("IntersectionController error: browser does not support IntersectionObserver.")}}}}]);
//# sourceMappingURL=20295.d890ccd95b42f27b.js.map