export const __rspack_esm_id=18469;export const __rspack_esm_ids=[18469];export const __webpack_modules__={19106(o,t,e){e(74423);const a=window.externalAppV2||window.externalApp||window.webkit?.messageHandlers?.getExternalAuth||location.search.includes("external_auth=1"),r=window.externalApp||window.externalAppV2;e.d(t,{},{B:r,g:a})},22756(o,t,e){e.a(o,async function(o,a){try{e.r(t);var r=e(15697),i=e(57527),d=e(79224),n=e(148),s=e(88457),l=e(98747),c=(e(90507),e(80494),e(73651)),p=e(54939),h=e(15466),g=e(24396),b=e(36158),u=o([s,l,c,p,h]);[s,l,c,p,h]=u.then?(await u)():u;class w extends i.WF{showDialog(){this._open=!0,this._loadSupportPackage()}_dialogClosed(){this._open=!1,this._supportPackage=void 0,(0,n.r)(this,"dialog-closed",{dialog:this.localName})}closeDialog(){return this._open=!1,!0}render(){return i.qy` <ha-dialog .open=${this._open} width="full" header-title="Download support package" @closed=${this._dialogClosed}> ${this._supportPackage?i.qy`<ha-markdown-element .content=${this._supportPackage} breaks></ha-markdown-element>`:i.qy` <div class="progress-container"> <ha-spinner></ha-spinner> Generating preview... </div> `} <div slot="footer" class="footer"> <ha-alert> This file may contain personal data about your home. Avoid sharing them with unverified or untrusted parties. </ha-alert> <hr/> <ha-dialog-footer> <ha-button slot="secondaryAction" appearance="plain" @click=${this.closeDialog}> Close </ha-button> <ha-button slot="primaryAction" @click=${this._download}> Download </ha-button> </ha-dialog-footer> </div> </ha-dialog> `}async _loadSupportPackage(){this._supportPackage=await(0,g.qF)(this.hass)}async _download(){(0,b.R)("data:text/plain;charset=utf-8,"+encodeURIComponent(this._supportPackage||""),"support-package.md")}constructor(...o){super(...o),this._open=!1}}w.styles=i.AH`.progress-container{flex-direction:column;justify-content:center;align-items:center;width:100%;height:calc(90vh - 260px);display:flex}.footer{justify-content:flex-start;align-items:stretch;gap:var(--ha-space-3);flex-direction:column;width:100%;display:flex}ha-dialog-footer{width:100%;display:block}hr{border:none;border-top:1px solid var(--divider-color);width:100%;margin:0}table,th,td{border:none}table{border-collapse:collapse;border-spacing:0;width:100%;display:table}table tr{border-bottom:none}table>tbody>tr:nth-child(odd){background-color:rgba(var(--rgb-primary-text-color), .04)}table>tbody>tr>td{border-radius:var(--ha-border-radius-square)}table>tbody>tr{-webkit-transition:background-color .25s;transition:background-color .25s}table>tbody>tr:hover{background-color:rgba(var(--rgb-primary-text-color), .08)}tr{border-bottom:1px solid var(--divider-color)}td,th{text-align:left;vertical-align:middle;border-radius:var(--ha-border-radius-sm);padding:15px 5px;display:table-cell}details{background-color:var(--secondary-background-color);border:1px solid var(--divider-color);border-radius:var(--ha-border-radius-xl);margin:8px 0;padding:16px 24px}summary{font-weight:var(--ha-font-weight-bold);cursor:pointer}`,(0,r.Cg)([(0,d.MZ)({attribute:!1})],w.prototype,"hass",void 0),(0,r.Cg)([(0,d.wk)()],w.prototype,"_open",void 0),(0,r.Cg)([(0,d.wk)()],w.prototype,"_supportPackage",void 0),w=(0,r.Cg)([(0,d.EM)("dialog-cloud-support-package")],w),e.d(t,{DialogSupportPackage:()=>w}),a()}catch(o){a(o)}})},36158(o,t,e){e(14603),e(47566),e(98721);var a=e(19106);e.d(t,{},{R:(o,t="")=>{const e=document.createElement("a");e.target="_blank",e.href=o,e.download=t,e.style.display="none",document.body.appendChild(e),e.dispatchEvent(new MouseEvent("click")),document.body.removeChild(e),o.startsWith("blob:")&&(a.B?setTimeout(()=>URL.revokeObjectURL(o),1e4):URL.revokeObjectURL(o))}})}};
//# sourceMappingURL=18469.992190c9cd27f972.js.map