(()=>{"use strict";var e={348:(e,r,n)=>{Object.defineProperty(r,"__esModule",{value:!0}),r.register=void 0;const o=n(840),i=new Map,s={init(){window.postMessage("init","*",[])},loadPrefs:e=>o.ipcRenderer.invoke("loadPrefs",e),savePrefs:(e,r)=>o.ipcRenderer.invoke("savePrefs",e,r),chooseFiles:()=>o.ipcRenderer.invoke("chooseFiles"),saveFile:e=>o.ipcRenderer.invoke("saveFile",e),getArgs:()=>o.ipcRenderer.invoke("getArgs"),getAppVersion:()=>o.ipcRenderer.invoke("getAppVersion"),getPlatform:()=>o.ipcRenderer.invoke("getPlatform"),getTmpDir:()=>o.ipcRenderer.invoke("getTmpDir"),getArchives:()=>o.ipcRenderer.invoke("getArchives"),addArchive:e=>o.ipcRenderer.invoke("addArchive",e),removeArchive:e=>o.ipcRenderer.invoke("removeArchive",e),updateArchive:e=>o.ipcRenderer.invoke("updateArchive",e),close:()=>o.ipcRenderer.invoke("close"),focus:()=>o.ipcRenderer.invoke("focus"),toggleMaximized:()=>o.ipcRenderer.invoke("toggleMaximized"),setWindowState:e=>o.ipcRenderer.invoke("setWindowState",e),download:(e,r,n)=>o.ipcRenderer.invoke("download",e,r,n),open:e=>o.ipcRenderer.invoke("open",e),launch:(e,r)=>o.ipcRenderer.invoke("launch",e,r),alert:e=>o.ipcRenderer.invoke("alert",e),notifyUpdate:e=>o.ipcRenderer.invoke("notifyUpdate",e),requestInspector:()=>o.ipcRenderer.invoke("requestInspector"),registerInspector:()=>o.ipcRenderer.invoke("registerInspector"),render:(e,r,n)=>o.ipcRenderer.invoke("render",e,r,n),getPathForFile:e=>e&&o.webUtils.getPathForFile(e)||void 0,resolve:e=>o.ipcRenderer.invoke("resolve",e),upload:(e,r,n)=>new Promise(((s,t)=>{const p={id:e,file:r,onProgress:n,onComplete:s};i.set(e,p),o.ipcRenderer.send("uploadRequest",e,r)}))};r.register=function(e={}){o.ipcRenderer.on("focus",(()=>window.postMessage("focus","*",[]))),o.ipcRenderer.on("blur",(()=>window.postMessage("blur","*",[]))),o.ipcRenderer.on("uploadProgress",((e,r,n,o)=>{const s=i.get(r);s&&s.onProgress&&s.onProgress(n,o)})),o.ipcRenderer.on("uploadComplete",((e,r,n)=>{const o=i.get(r);o&&o.onComplete&&o.onComplete(n),i.delete(r)})),o.contextBridge.exposeInMainWorld("ipc",Object.assign(s,e))}},840:e=>{e.exports=require("electron")}},r={};function n(o){var i=r[o];if(void 0!==i)return i.exports;var s=r[o]={exports:{}};return e[o](s,s.exports,n),s.exports}(()=>{const e=n(840);(0,n(348).register)({init(){const r=new MessageChannel;e.ipcRenderer.postMessage("subscribe",null,[r.port1]);const n=new MessageChannel;e.ipcRenderer.postMessage("request inspector",null,[n.port1]),window.postMessage("init","*",[r.port2,n.port2])}})})()})();