homebridge-config-ui-x 5.11.2-alpha.0 → 5.11.2-alpha.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/public/{chunk-SOEFKTV3.js → chunk-3ND4FTJL.js} +1 -1
- package/public/{chunk-UR7BEPD4.js → chunk-4HRXISNZ.js} +1 -1
- package/public/{chunk-HGB7JMQB.js → chunk-4KYVPUTG.js} +1 -1
- package/public/{chunk-FXM34P2Q.js → chunk-6G6325AZ.js} +1 -1
- package/public/{chunk-W6MP663P.js → chunk-6IPZ57S4.js} +1 -1
- package/public/{chunk-63DEF4BP.js → chunk-74KAKFTX.js} +1 -1
- package/public/{chunk-G4TMATE3.js → chunk-77KQMZKD.js} +1 -1
- package/public/{chunk-P3D45344.js → chunk-7IMDRRHF.js} +1 -1
- package/public/{chunk-NF7H6G7M.js → chunk-7MHPXFPT.js} +1 -1
- package/public/{chunk-M5KMDWMD.js → chunk-A2VBYQGU.js} +1 -1
- package/public/{chunk-M5U3WH6U.js → chunk-AM2AGROH.js} +1 -1
- package/public/{chunk-22B4UCUR.js → chunk-BCAWAC5S.js} +1 -1
- package/public/{chunk-4X67MV5P.js → chunk-BRUFPV4S.js} +1 -1
- package/public/{chunk-PXNJ4PSF.js → chunk-CAB2VD3D.js} +1 -1
- package/public/{chunk-FIF6GB4H.js → chunk-CQHE4TU3.js} +1 -1
- package/public/{chunk-GARJCQR2.js → chunk-CZBBUBTH.js} +1 -1
- package/public/{chunk-S52YHDRI.js → chunk-F344NE7H.js} +1 -1
- package/public/{chunk-ZI6P36I2.js → chunk-FDD3SM5M.js} +1 -1
- package/public/{chunk-4KBAYZP7.js → chunk-FJCRSYAB.js} +1 -1
- package/public/{chunk-M72FKTRG.js → chunk-FL4D5IR7.js} +1 -1
- package/public/{chunk-4G547VQH.js → chunk-FOAHTHQO.js} +1 -1
- package/public/{chunk-LT4LVLTJ.js → chunk-GAI5J4YQ.js} +1 -1
- package/public/{chunk-P7RLJ6EQ.js → chunk-GV5JF2YJ.js} +1 -1
- package/public/{chunk-QOXXKL5T.js → chunk-GWQFQK2F.js} +1 -1
- package/public/{chunk-T5WI6HLG.js → chunk-IIAESTI5.js} +1 -1
- package/public/{chunk-CR6W3PUA.js → chunk-KTLG6VZT.js} +1 -1
- package/public/{chunk-YZZ7SAON.js → chunk-MW6H5Z5G.js} +1 -1
- package/public/{chunk-N2IMTG2V.js → chunk-O6MJC7P2.js} +1 -1
- package/public/{chunk-4O7BLLBH.js → chunk-OWEBBEZA.js} +1 -1
- package/public/{chunk-5QXXJI43.js → chunk-QPYSLZDC.js} +1 -1
- package/public/{chunk-S6JEMYUK.js → chunk-R24RQS2V.js} +3 -3
- package/public/{chunk-LPZZFOKR.js → chunk-R3PJ6UT3.js} +1 -1
- package/public/{chunk-JC74NWLG.js → chunk-RRYSODYJ.js} +1 -1
- package/public/{chunk-WYJ4N4TV.js → chunk-SIIM6WZ6.js} +3 -3
- package/public/{chunk-5YRG477U.js → chunk-TWVOLPMB.js} +1 -1
- package/public/{chunk-UQGRSMY3.js → chunk-UTCW7GEG.js} +1 -1
- package/public/{chunk-7D5NLF5A.js → chunk-VNSIIEIM.js} +1 -1
- package/public/{chunk-EVNAB6KB.js → chunk-VTSSBPGB.js} +1 -1
- package/public/{chunk-M4OD2EYP.js → chunk-W2OS6MJH.js} +1 -1
- package/public/{chunk-DGBI427A.js → chunk-ZAKTSIL5.js} +1 -1
- package/public/index.html +1 -1
- package/public/{main-QSNNOJ3S.js → main-HATN2V6Z.js} +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
import{b as pe}from"./chunk-CR6W3PUA.js";import{J as le}from"./chunk-YZZ7SAON.js";import{X as fe,aa as ue,c as he,d as X}from"./chunk-ZPXACREZ.js";import{f as We}from"./chunk-B4AJQJMI.js";var d=Object.create(null);d.open="0";d.close="1";d.ping="2";d.pong="3";d.message="4";d.upgrade="5";d.noop="6";var S=Object.create(null);Object.keys(d).forEach(r=>{S[d[r]]=r});var O={type:"error",data:"parser error"};var ye=typeof Blob=="function"||typeof Blob<"u"&&Object.prototype.toString.call(Blob)==="[object BlobConstructor]",ge=typeof ArrayBuffer=="function",_e=r=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(r):r&&r.buffer instanceof ArrayBuffer,B=({type:r,data:e},t,s)=>ye&&e instanceof Blob?t?s(e):de(e,s):ge&&(e instanceof ArrayBuffer||_e(e))?t?s(e):de(new Blob([e]),s):s(d[r]+(e||"")),de=(r,e)=>{let t=new FileReader;return t.onload=function(){let s=t.result.split(",")[1];e("b"+(s||""))},t.readAsDataURL(r)};function me(r){return r instanceof Uint8Array?r:r instanceof ArrayBuffer?new Uint8Array(r):new Uint8Array(r.buffer,r.byteOffset,r.byteLength)}var $;function be(r,e){if(ye&&r.data instanceof Blob)return r.data.arrayBuffer().then(me).then(e);if(ge&&(r.data instanceof ArrayBuffer||_e(r.data)))return e(me(r.data));B(r,!1,t=>{$||($=new TextEncoder),e($.encode(t))})}var we="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",N=typeof Uint8Array>"u"?[]:new Uint8Array(256);for(let r=0;r<we.length;r++)N[we.charCodeAt(r)]=r;var ke=r=>{let e=r.length*.75,t=r.length,s,i=0,n,o,c,a;r[r.length-1]==="="&&(e--,r[r.length-2]==="="&&e--);let m=new ArrayBuffer(e),p=new Uint8Array(m);for(s=0;s<t;s+=4)n=N[r.charCodeAt(s)],o=N[r.charCodeAt(s+1)],c=N[r.charCodeAt(s+2)],a=N[r.charCodeAt(s+3)],p[i++]=n<<2|o>>4,p[i++]=(o&15)<<4|c>>2,p[i++]=(c&3)<<6|a&63;return m};var Ke=typeof ArrayBuffer=="function",L=(r,e)=>{if(typeof r!="string")return{type:"message",data:Ee(r,e)};let t=r.charAt(0);return t==="b"?{type:"message",data:Ye(r.substring(1),e)}:S[t]?r.length>1?{type:S[t],data:r.substring(1)}:{type:S[t]}:O},Ye=(r,e)=>{if(Ke){let t=ke(r);return Ee(t,e)}else return{base64:!0,data:r}},Ee=(r,e)=>{switch(e){case"blob":return r instanceof Blob?r:new Blob([r]);case"arraybuffer":default:return r instanceof ArrayBuffer?r:r.buffer}};var ve="",xe=(r,e)=>{let t=r.length,s=new Array(t),i=0;r.forEach((n,o)=>{B(n,!1,c=>{s[o]=c,++i===t&&e(s.join(ve))})})},Te=(r,e)=>{let t=r.split(ve),s=[];for(let i=0;i<t.length;i++){let n=L(t[i],e);if(s.push(n),n.type==="error")break}return s};function Ae(){return new TransformStream({transform(r,e){be(r,t=>{let s=t.length,i;if(s<126)i=new Uint8Array(1),new DataView(i.buffer).setUint8(0,s);else if(s<65536){i=new Uint8Array(3);let n=new DataView(i.buffer);n.setUint8(0,126),n.setUint16(1,s)}else{i=new Uint8Array(9);let n=new DataView(i.buffer);n.setUint8(0,127),n.setBigUint64(1,BigInt(s))}r.data&&typeof r.data!="string"&&(i[0]|=128),e.enqueue(i),e.enqueue(t)})}})}var Q;function U(r){return r.reduce((e,t)=>e+t.length,0)}function V(r,e){if(r[0].length===e)return r.shift();let t=new Uint8Array(e),s=0;for(let i=0;i<e;i++)t[i]=r[0][s++],s===r[0].length&&(r.shift(),s=0);return r.length&&s<r[0].length&&(r[0]=r[0].slice(s)),t}function Re(r,e){Q||(Q=new TextDecoder);let t=[],s=0,i=-1,n=!1;return new TransformStream({transform(o,c){for(t.push(o);;){if(s===0){if(U(t)<1)break;let a=V(t,1);n=(a[0]&128)===128,i=a[0]&127,i<126?s=3:i===126?s=1:s=2}else if(s===1){if(U(t)<2)break;let a=V(t,2);i=new DataView(a.buffer,a.byteOffset,a.length).getUint16(0),s=3}else if(s===2){if(U(t)<8)break;let a=V(t,8),m=new DataView(a.buffer,a.byteOffset,a.length),p=m.getUint32(0);if(p>Math.pow(2,21)-1){c.enqueue(O);break}i=p*Math.pow(2,32)+m.getUint32(4),s=3}else{if(U(t)<i)break;let a=V(t,i);c.enqueue(L(n?a:Q.decode(a),e)),s=0}if(i===0||i>r){c.enqueue(O);break}}}})}var j=4;function f(r){if(r)return Je(r)}function Je(r){for(var e in f.prototype)r[e]=f.prototype[e];return r}f.prototype.on=f.prototype.addEventListener=function(r,e){return this._callbacks=this._callbacks||{},(this._callbacks["$"+r]=this._callbacks["$"+r]||[]).push(e),this};f.prototype.once=function(r,e){function t(){this.off(r,t),e.apply(this,arguments)}return t.fn=e,this.on(r,t),this};f.prototype.off=f.prototype.removeListener=f.prototype.removeAllListeners=f.prototype.removeEventListener=function(r,e){if(this._callbacks=this._callbacks||{},arguments.length==0)return this._callbacks={},this;var t=this._callbacks["$"+r];if(!t)return this;if(arguments.length==1)return delete this._callbacks["$"+r],this;for(var s,i=0;i<t.length;i++)if(s=t[i],s===e||s.fn===e){t.splice(i,1);break}return t.length===0&&delete this._callbacks["$"+r],this};f.prototype.emit=function(r){this._callbacks=this._callbacks||{};for(var e=new Array(arguments.length-1),t=this._callbacks["$"+r],s=1;s<arguments.length;s++)e[s-1]=arguments[s];if(t){t=t.slice(0);for(var s=0,i=t.length;s<i;++s)t[s].apply(this,e)}return this};f.prototype.emitReserved=f.prototype.emit;f.prototype.listeners=function(r){return this._callbacks=this._callbacks||{},this._callbacks["$"+r]||[]};f.prototype.hasListeners=function(r){return!!this.listeners(r).length};var y=typeof Promise=="function"&&typeof Promise.resolve=="function"?e=>Promise.resolve().then(e):(e,t)=>t(e,0),u=typeof self<"u"?self:typeof window<"u"?window:Function("return this")(),Ce="arraybuffer";function M(r,...e){return e.reduce((t,s)=>(r.hasOwnProperty(s)&&(t[s]=r[s]),t),{})}var ze=u.setTimeout,Xe=u.clearTimeout;function g(r,e){e.useNativeTimers?(r.setTimeoutFn=ze.bind(u),r.clearTimeoutFn=Xe.bind(u)):(r.setTimeoutFn=u.setTimeout.bind(u),r.clearTimeoutFn=u.clearTimeout.bind(u))}var $e=1.33;function Se(r){return typeof r=="string"?Qe(r):Math.ceil((r.byteLength||r.size)*$e)}function Qe(r){let e=0,t=0;for(let s=0,i=r.length;s<i;s++)e=r.charCodeAt(s),e<128?t+=1:e<2048?t+=2:e<55296||e>=57344?t+=3:(s++,t+=4);return t}function H(){return Date.now().toString(36).substring(3)+Math.random().toString(36).substring(2,5)}function Oe(r){let e="";for(let t in r)r.hasOwnProperty(t)&&(e.length&&(e+="&"),e+=encodeURIComponent(t)+"="+encodeURIComponent(r[t]));return e}function Be(r){let e={},t=r.split("&");for(let s=0,i=t.length;s<i;s++){let n=t[s].split("=");e[decodeURIComponent(n[0])]=decodeURIComponent(n[1])}return e}var W=class extends Error{constructor(e,t,s){super(e),this.description=t,this.context=s,this.type="TransportError"}},_=class extends f{constructor(e){super(),this.writable=!1,g(this,e),this.opts=e,this.query=e.query,this.socket=e.socket,this.supportsBinary=!e.forceBase64}onError(e,t,s){return super.emitReserved("error",new W(e,t,s)),this}open(){return this.readyState="opening",this.doOpen(),this}close(){return(this.readyState==="opening"||this.readyState==="open")&&(this.doClose(),this.onClose()),this}send(e){this.readyState==="open"&&this.write(e)}onOpen(){this.readyState="open",this.writable=!0,super.emitReserved("open")}onData(e){let t=L(e,this.socket.binaryType);this.onPacket(t)}onPacket(e){super.emitReserved("packet",e)}onClose(e){this.readyState="closed",super.emitReserved("close",e)}pause(e){}createUri(e,t={}){return e+"://"+this._hostname()+this._port()+this.opts.path+this._query(t)}_hostname(){let e=this.opts.hostname;return e.indexOf(":")===-1?e:"["+e+"]"}_port(){return this.opts.port&&(this.opts.secure&&+(this.opts.port!==443)||!this.opts.secure&&Number(this.opts.port)!==80)?":"+this.opts.port:""}_query(e){let t=Oe(e);return t.length?"?"+t:""}};var P=class extends _{constructor(){super(...arguments),this._polling=!1}get name(){return"polling"}doOpen(){this._poll()}pause(e){this.readyState="pausing";let t=()=>{this.readyState="paused",e()};if(this._polling||!this.writable){let s=0;this._polling&&(s++,this.once("pollComplete",function(){--s||t()})),this.writable||(s++,this.once("drain",function(){--s||t()}))}else t()}_poll(){this._polling=!0,this.doPoll(),this.emitReserved("poll")}onData(e){let t=s=>{if(this.readyState==="opening"&&s.type==="open"&&this.onOpen(),s.type==="close")return this.onClose({description:"transport closed by the server"}),!1;this.onPacket(s)};Te(e,this.socket.binaryType).forEach(t),this.readyState!=="closed"&&(this._polling=!1,this.emitReserved("pollComplete"),this.readyState==="open"&&this._poll())}doClose(){let e=()=>{this.write([{type:"close"}])};this.readyState==="open"?e():this.once("open",e)}write(e){this.writable=!1,xe(e,t=>{this.doWrite(t,()=>{this.writable=!0,this.emitReserved("drain")})})}uri(){let e=this.opts.secure?"https":"http",t=this.query||{};return this.opts.timestampRequests!==!1&&(t[this.opts.timestampParam]=H()),!this.supportsBinary&&!t.sid&&(t.b64=1),this.createUri(e,t)}};var Ne=!1;try{Ne=typeof XMLHttpRequest<"u"&&"withCredentials"in new XMLHttpRequest}catch{}var Le=Ne;function je(){}var G=class extends P{constructor(e){if(super(e),typeof location<"u"){let t=location.protocol==="https:",s=location.port;s||(s=t?"443":"80"),this.xd=typeof location<"u"&&e.hostname!==location.hostname||s!==e.port}}doWrite(e,t){let s=this.request({method:"POST",data:e});s.on("success",t),s.on("error",(i,n)=>{this.onError("xhr post error",i,n)})}doPoll(){let e=this.request();e.on("data",this.onData.bind(this)),e.on("error",(t,s)=>{this.onError("xhr poll error",t,s)}),this.pollXhr=e}},K=(()=>{class r extends f{constructor(t,s,i){super(),this.createRequest=t,g(this,i),this._opts=i,this._method=i.method||"GET",this._uri=s,this._data=i.data!==void 0?i.data:null,this._create()}_create(){var t;let s=M(this._opts,"agent","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","autoUnref");s.xdomain=!!this._opts.xd;let i=this._xhr=this.createRequest(s);try{i.open(this._method,this._uri,!0);try{if(this._opts.extraHeaders){i.setDisableHeaderCheck&&i.setDisableHeaderCheck(!0);for(let n in this._opts.extraHeaders)this._opts.extraHeaders.hasOwnProperty(n)&&i.setRequestHeader(n,this._opts.extraHeaders[n])}}catch{}if(this._method==="POST")try{i.setRequestHeader("Content-type","text/plain;charset=UTF-8")}catch{}try{i.setRequestHeader("Accept","*/*")}catch{}(t=this._opts.cookieJar)===null||t===void 0||t.addCookies(i),"withCredentials"in i&&(i.withCredentials=this._opts.withCredentials),this._opts.requestTimeout&&(i.timeout=this._opts.requestTimeout),i.onreadystatechange=()=>{var n;i.readyState===3&&((n=this._opts.cookieJar)===null||n===void 0||n.parseCookies(i.getResponseHeader("set-cookie"))),i.readyState===4&&(i.status===200||i.status===1223?this._onLoad():this.setTimeoutFn(()=>{this._onError(typeof i.status=="number"?i.status:0)},0))},i.send(this._data)}catch(n){this.setTimeoutFn(()=>{this._onError(n)},0);return}typeof document<"u"&&(this._index=r.requestsCount++,r.requests[this._index]=this)}_onError(t){this.emitReserved("error",t,this._xhr),this._cleanup(!0)}_cleanup(t){if(!(typeof this._xhr>"u"||this._xhr===null)){if(this._xhr.onreadystatechange=je,t)try{this._xhr.abort()}catch{}typeof document<"u"&&delete r.requests[this._index],this._xhr=null}}_onLoad(){let t=this._xhr.responseText;t!==null&&(this.emitReserved("data",t),this.emitReserved("success"),this._cleanup())}abort(){this._cleanup()}}return r.requestsCount=0,r.requests={},r})();if(typeof document<"u"){if(typeof attachEvent=="function")attachEvent("onunload",Pe);else if(typeof addEventListener=="function"){let r="onpagehide"in u?"pagehide":"unload";addEventListener(r,Pe,!1)}}function Pe(){for(let r in K.requests)K.requests.hasOwnProperty(r)&&K.requests[r].abort()}var Ge=(function(){let r=qe({xdomain:!1});return r&&r.responseType!==null})(),w=class extends G{constructor(e){super(e);let t=e&&e.forceBase64;this.supportsBinary=Ge&&!t}request(e={}){return Object.assign(e,{xd:this.xd},this.opts),new K(qe,this.uri(),e)}};function qe(r){let e=r.xdomain;try{if(typeof XMLHttpRequest<"u"&&(!e||Le))return new XMLHttpRequest}catch{}if(!e)try{return new u[["Active"].concat("Object").join("X")]("Microsoft.XMLHTTP")}catch{}}var De=typeof navigator<"u"&&typeof navigator.product=="string"&&navigator.product.toLowerCase()==="reactnative",ee=class extends _{get name(){return"websocket"}doOpen(){let e=this.uri(),t=this.opts.protocols,s=De?{}:M(this.opts,"agent","perMessageDeflate","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","localAddress","protocolVersion","origin","maxPayload","family","checkServerIdentity");this.opts.extraHeaders&&(s.headers=this.opts.extraHeaders);try{this.ws=this.createSocket(e,t,s)}catch(i){return this.emitReserved("error",i)}this.ws.binaryType=this.socket.binaryType,this.addEventListeners()}addEventListeners(){this.ws.onopen=()=>{this.opts.autoUnref&&this.ws._socket.unref(),this.onOpen()},this.ws.onclose=e=>this.onClose({description:"websocket connection closed",context:e}),this.ws.onmessage=e=>this.onData(e.data),this.ws.onerror=e=>this.onError("websocket error",e)}write(e){this.writable=!1;for(let t=0;t<e.length;t++){let s=e[t],i=t===e.length-1;B(s,this.supportsBinary,n=>{try{this.doWrite(s,n)}catch{}i&&y(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){typeof this.ws<"u"&&(this.ws.onerror=()=>{},this.ws.close(),this.ws=null)}uri(){let e=this.opts.secure?"wss":"ws",t=this.query||{};return this.opts.timestampRequests&&(t[this.opts.timestampParam]=H()),this.supportsBinary||(t.b64=1),this.createUri(e,t)}},Z=u.WebSocket||u.MozWebSocket,k=class extends ee{createSocket(e,t,s){return De?new Z(e,t,s):t?new Z(e,t):new Z(e)}doWrite(e,t){this.ws.send(t)}};var v=class extends _{get name(){return"webtransport"}doOpen(){try{this._transport=new WebTransport(this.createUri("https"),this.opts.transportOptions[this.name])}catch(e){return this.emitReserved("error",e)}this._transport.closed.then(()=>{this.onClose()}).catch(e=>{this.onError("webtransport error",e)}),this._transport.ready.then(()=>{this._transport.createBidirectionalStream().then(e=>{let t=Re(Number.MAX_SAFE_INTEGER,this.socket.binaryType),s=e.readable.pipeThrough(t).getReader(),i=Ae();i.readable.pipeTo(e.writable),this._writer=i.writable.getWriter();let n=()=>{s.read().then(({done:c,value:a})=>{c||(this.onPacket(a),n())}).catch(c=>{})};n();let o={type:"open"};this.query.sid&&(o.data=`{"sid":"${this.query.sid}"}`),this._writer.write(o).then(()=>this.onOpen())})})}write(e){this.writable=!1;for(let t=0;t<e.length;t++){let s=e[t],i=t===e.length-1;this._writer.write(s).then(()=>{i&&y(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){var e;(e=this._transport)===null||e===void 0||e.close()}};var te={websocket:k,webtransport:v,polling:w};var Ze=/^(?:(?![^:@\/?#]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@\/?#]*)(?::([^:@\/?#]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,et=["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"];function x(r){if(r.length>8e3)throw"URI too long";let e=r,t=r.indexOf("["),s=r.indexOf("]");t!=-1&&s!=-1&&(r=r.substring(0,t)+r.substring(t,s).replace(/:/g,";")+r.substring(s,r.length));let i=Ze.exec(r||""),n={},o=14;for(;o--;)n[et[o]]=i[o]||"";return t!=-1&&s!=-1&&(n.source=e,n.host=n.host.substring(1,n.host.length-1).replace(/;/g,":"),n.authority=n.authority.replace("[","").replace("]","").replace(/;/g,":"),n.ipv6uri=!0),n.pathNames=tt(n,n.path),n.queryKey=st(n,n.query),n}function tt(r,e){let t=/\/{2,9}/g,s=e.replace(t,"/").split("/");return(e.slice(0,1)=="/"||e.length===0)&&s.splice(0,1),e.slice(-1)=="/"&&s.splice(s.length-1,1),s}function st(r,e){let t={};return e.replace(/(?:^|&)([^&=]*)=?([^&]*)/g,function(s,i,n){i&&(t[i]=n)}),t}var se=typeof addEventListener=="function"&&typeof removeEventListener=="function",Y=[];se&&addEventListener("offline",()=>{Y.forEach(r=>r())},!1);var J=(()=>{class r extends f{constructor(t,s){if(super(),this.binaryType=Ce,this.writeBuffer=[],this._prevBufferLen=0,this._pingInterval=-1,this._pingTimeout=-1,this._maxPayload=-1,this._pingTimeoutTime=1/0,t&&typeof t=="object"&&(s=t,t=null),t){let i=x(t);s.hostname=i.host,s.secure=i.protocol==="https"||i.protocol==="wss",s.port=i.port,i.query&&(s.query=i.query)}else s.host&&(s.hostname=x(s.host).host);g(this,s),this.secure=s.secure!=null?s.secure:typeof location<"u"&&location.protocol==="https:",s.hostname&&!s.port&&(s.port=this.secure?"443":"80"),this.hostname=s.hostname||(typeof location<"u"?location.hostname:"localhost"),this.port=s.port||(typeof location<"u"&&location.port?location.port:this.secure?"443":"80"),this.transports=[],this._transportsByName={},s.transports.forEach(i=>{let n=i.prototype.name;this.transports.push(n),this._transportsByName[n]=i}),this.opts=Object.assign({path:"/engine.io",agent:!1,withCredentials:!1,upgrade:!0,timestampParam:"t",rememberUpgrade:!1,addTrailingSlash:!0,rejectUnauthorized:!0,perMessageDeflate:{threshold:1024},transportOptions:{},closeOnBeforeunload:!1},s),this.opts.path=this.opts.path.replace(/\/$/,"")+(this.opts.addTrailingSlash?"/":""),typeof this.opts.query=="string"&&(this.opts.query=Be(this.opts.query)),se&&(this.opts.closeOnBeforeunload&&(this._beforeunloadEventListener=()=>{this.transport&&(this.transport.removeAllListeners(),this.transport.close())},addEventListener("beforeunload",this._beforeunloadEventListener,!1)),this.hostname!=="localhost"&&(this._offlineEventListener=()=>{this._onClose("transport close",{description:"network connection lost"})},Y.push(this._offlineEventListener))),this.opts.withCredentials&&(this._cookieJar=void 0),this._open()}createTransport(t){let s=Object.assign({},this.opts.query);s.EIO=j,s.transport=t,this.id&&(s.sid=this.id);let i=Object.assign({},this.opts,{query:s,socket:this,hostname:this.hostname,secure:this.secure,port:this.port},this.opts.transportOptions[t]);return new this._transportsByName[t](i)}_open(){if(this.transports.length===0){this.setTimeoutFn(()=>{this.emitReserved("error","No transports available")},0);return}let t=this.opts.rememberUpgrade&&r.priorWebsocketSuccess&&this.transports.indexOf("websocket")!==-1?"websocket":this.transports[0];this.readyState="opening";let s=this.createTransport(t);s.open(),this.setTransport(s)}setTransport(t){this.transport&&this.transport.removeAllListeners(),this.transport=t,t.on("drain",this._onDrain.bind(this)).on("packet",this._onPacket.bind(this)).on("error",this._onError.bind(this)).on("close",s=>this._onClose("transport close",s))}onOpen(){this.readyState="open",r.priorWebsocketSuccess=this.transport.name==="websocket",this.emitReserved("open"),this.flush()}_onPacket(t){if(this.readyState==="opening"||this.readyState==="open"||this.readyState==="closing")switch(this.emitReserved("packet",t),this.emitReserved("heartbeat"),t.type){case"open":this.onHandshake(JSON.parse(t.data));break;case"ping":this._sendPacket("pong"),this.emitReserved("ping"),this.emitReserved("pong"),this._resetPingTimeout();break;case"error":let s=new Error("server error");s.code=t.data,this._onError(s);break;case"message":this.emitReserved("data",t.data),this.emitReserved("message",t.data);break}}onHandshake(t){this.emitReserved("handshake",t),this.id=t.sid,this.transport.query.sid=t.sid,this._pingInterval=t.pingInterval,this._pingTimeout=t.pingTimeout,this._maxPayload=t.maxPayload,this.onOpen(),this.readyState!=="closed"&&this._resetPingTimeout()}_resetPingTimeout(){this.clearTimeoutFn(this._pingTimeoutTimer);let t=this._pingInterval+this._pingTimeout;this._pingTimeoutTime=Date.now()+t,this._pingTimeoutTimer=this.setTimeoutFn(()=>{this._onClose("ping timeout")},t),this.opts.autoUnref&&this._pingTimeoutTimer.unref()}_onDrain(){this.writeBuffer.splice(0,this._prevBufferLen),this._prevBufferLen=0,this.writeBuffer.length===0?this.emitReserved("drain"):this.flush()}flush(){if(this.readyState!=="closed"&&this.transport.writable&&!this.upgrading&&this.writeBuffer.length){let t=this._getWritablePackets();this.transport.send(t),this._prevBufferLen=t.length,this.emitReserved("flush")}}_getWritablePackets(){if(!(this._maxPayload&&this.transport.name==="polling"&&this.writeBuffer.length>1))return this.writeBuffer;let s=1;for(let i=0;i<this.writeBuffer.length;i++){let n=this.writeBuffer[i].data;if(n&&(s+=Se(n)),i>0&&s>this._maxPayload)return this.writeBuffer.slice(0,i);s+=2}return this.writeBuffer}_hasPingExpired(){if(!this._pingTimeoutTime)return!0;let t=Date.now()>this._pingTimeoutTime;return t&&(this._pingTimeoutTime=0,y(()=>{this._onClose("ping timeout")},this.setTimeoutFn)),t}write(t,s,i){return this._sendPacket("message",t,s,i),this}send(t,s,i){return this._sendPacket("message",t,s,i),this}_sendPacket(t,s,i,n){if(typeof s=="function"&&(n=s,s=void 0),typeof i=="function"&&(n=i,i=null),this.readyState==="closing"||this.readyState==="closed")return;i=i||{},i.compress=i.compress!==!1;let o={type:t,data:s,options:i};this.emitReserved("packetCreate",o),this.writeBuffer.push(o),n&&this.once("flush",n),this.flush()}close(){let t=()=>{this._onClose("forced close"),this.transport.close()},s=()=>{this.off("upgrade",s),this.off("upgradeError",s),t()},i=()=>{this.once("upgrade",s),this.once("upgradeError",s)};return(this.readyState==="opening"||this.readyState==="open")&&(this.readyState="closing",this.writeBuffer.length?this.once("drain",()=>{this.upgrading?i():t()}):this.upgrading?i():t()),this}_onError(t){if(r.priorWebsocketSuccess=!1,this.opts.tryAllTransports&&this.transports.length>1&&this.readyState==="opening")return this.transports.shift(),this._open();this.emitReserved("error",t),this._onClose("transport error",t)}_onClose(t,s){if(this.readyState==="opening"||this.readyState==="open"||this.readyState==="closing"){if(this.clearTimeoutFn(this._pingTimeoutTimer),this.transport.removeAllListeners("close"),this.transport.close(),this.transport.removeAllListeners(),se&&(this._beforeunloadEventListener&&removeEventListener("beforeunload",this._beforeunloadEventListener,!1),this._offlineEventListener)){let i=Y.indexOf(this._offlineEventListener);i!==-1&&Y.splice(i,1)}this.readyState="closed",this.id=null,this.emitReserved("close",t,s),this.writeBuffer=[],this._prevBufferLen=0}}}return r.protocol=j,r})(),z=class extends J{constructor(){super(...arguments),this._upgrades=[]}onOpen(){if(super.onOpen(),this.readyState==="open"&&this.opts.upgrade)for(let e=0;e<this._upgrades.length;e++)this._probe(this._upgrades[e])}_probe(e){let t=this.createTransport(e),s=!1;J.priorWebsocketSuccess=!1;let i=()=>{s||(t.send([{type:"ping",data:"probe"}]),t.once("packet",b=>{if(!s)if(b.type==="pong"&&b.data==="probe"){if(this.upgrading=!0,this.emitReserved("upgrading",t),!t)return;J.priorWebsocketSuccess=t.name==="websocket",this.transport.pause(()=>{s||this.readyState!=="closed"&&(p(),this.setTransport(t),t.send([{type:"upgrade"}]),this.emitReserved("upgrade",t),t=null,this.upgrading=!1,this.flush())})}else{let C=new Error("probe error");C.transport=t.name,this.emitReserved("upgradeError",C)}}))};function n(){s||(s=!0,p(),t.close(),t=null)}let o=b=>{let C=new Error("probe error: "+b);C.transport=t.name,n(),this.emitReserved("upgradeError",C)};function c(){o("transport closed")}function a(){o("socket closed")}function m(b){t&&b.name!==t.name&&n()}let p=()=>{t.removeListener("open",i),t.removeListener("error",o),t.removeListener("close",c),this.off("close",a),this.off("upgrading",m)};t.once("open",i),t.once("error",o),t.once("close",c),this.once("close",a),this.once("upgrading",m),this._upgrades.indexOf("webtransport")!==-1&&e!=="webtransport"?this.setTimeoutFn(()=>{s||t.open()},200):t.open()}onHandshake(e){this._upgrades=this._filterUpgrades(e.upgrades),super.onHandshake(e)}_filterUpgrades(e){let t=[];for(let s=0;s<e.length;s++)~this.transports.indexOf(e[s])&&t.push(e[s]);return t}},T=class extends z{constructor(e,t={}){let s=typeof e=="object"?e:t;(!s.transports||s.transports&&typeof s.transports[0]=="string")&&(s.transports=(s.transports||["polling","websocket","webtransport"]).map(i=>te[i]).filter(i=>!!i)),super(e,s)}};var ds=T.protocol;function Fe(r,e="",t){let s=r;t=t||typeof location<"u"&&location,r==null&&(r=t.protocol+"//"+t.host),typeof r=="string"&&(r.charAt(0)==="/"&&(r.charAt(1)==="/"?r=t.protocol+r:r=t.host+r),/^(https?|wss?):\/\//.test(r)||(typeof t<"u"?r=t.protocol+"//"+r:r="https://"+r),s=x(r)),s.port||(/^(http|ws)$/.test(s.protocol)?s.port="80":/^(http|ws)s$/.test(s.protocol)&&(s.port="443")),s.path=s.path||"/";let n=s.host.indexOf(":")!==-1?"["+s.host+"]":s.host;return s.id=s.protocol+"://"+n+":"+s.port+e,s.href=s.protocol+"://"+n+(t&&t.port===s.port?"":":"+s.port),s}var ae={};We(ae,{Decoder:()=>oe,Encoder:()=>ne,PacketType:()=>h,protocol:()=>He});var it=typeof ArrayBuffer=="function",nt=r=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(r):r.buffer instanceof ArrayBuffer,Ie=Object.prototype.toString,ot=typeof Blob=="function"||typeof Blob<"u"&&Ie.call(Blob)==="[object BlobConstructor]",ct=typeof File=="function"||typeof File<"u"&&Ie.call(File)==="[object FileConstructor]";function D(r){return it&&(r instanceof ArrayBuffer||nt(r))||ot&&r instanceof Blob||ct&&r instanceof File}function q(r,e){if(!r||typeof r!="object")return!1;if(Array.isArray(r)){for(let t=0,s=r.length;t<s;t++)if(q(r[t]))return!0;return!1}if(D(r))return!0;if(r.toJSON&&typeof r.toJSON=="function"&&arguments.length===1)return q(r.toJSON(),!0);for(let t in r)if(Object.prototype.hasOwnProperty.call(r,t)&&q(r[t]))return!0;return!1}function Ue(r){let e=[],t=r.data,s=r;return s.data=re(t,e),s.attachments=e.length,{packet:s,buffers:e}}function re(r,e){if(!r)return r;if(D(r)){let t={_placeholder:!0,num:e.length};return e.push(r),t}else if(Array.isArray(r)){let t=new Array(r.length);for(let s=0;s<r.length;s++)t[s]=re(r[s],e);return t}else if(typeof r=="object"&&!(r instanceof Date)){let t={};for(let s in r)Object.prototype.hasOwnProperty.call(r,s)&&(t[s]=re(r[s],e));return t}return r}function Ve(r,e){return r.data=ie(r.data,e),delete r.attachments,r}function ie(r,e){if(!r)return r;if(r&&r._placeholder===!0){if(typeof r.num=="number"&&r.num>=0&&r.num<e.length)return e[r.num];throw new Error("illegal attachments")}else if(Array.isArray(r))for(let t=0;t<r.length;t++)r[t]=ie(r[t],e);else if(typeof r=="object")for(let t in r)Object.prototype.hasOwnProperty.call(r,t)&&(r[t]=ie(r[t],e));return r}var at=["connect","connect_error","disconnect","disconnecting","newListener","removeListener"],He=5,h=(function(r){return r[r.CONNECT=0]="CONNECT",r[r.DISCONNECT=1]="DISCONNECT",r[r.EVENT=2]="EVENT",r[r.ACK=3]="ACK",r[r.CONNECT_ERROR=4]="CONNECT_ERROR",r[r.BINARY_EVENT=5]="BINARY_EVENT",r[r.BINARY_ACK=6]="BINARY_ACK",r})(h||{}),ne=class{constructor(e){this.replacer=e}encode(e){return(e.type===h.EVENT||e.type===h.ACK)&&q(e)?this.encodeAsBinary({type:e.type===h.EVENT?h.BINARY_EVENT:h.BINARY_ACK,nsp:e.nsp,data:e.data,id:e.id}):[this.encodeAsString(e)]}encodeAsString(e){let t=""+e.type;return(e.type===h.BINARY_EVENT||e.type===h.BINARY_ACK)&&(t+=e.attachments+"-"),e.nsp&&e.nsp!=="/"&&(t+=e.nsp+","),e.id!=null&&(t+=e.id),e.data!=null&&(t+=JSON.stringify(e.data,this.replacer)),t}encodeAsBinary(e){let t=Ue(e),s=this.encodeAsString(t.packet),i=t.buffers;return i.unshift(s),i}};function Me(r){return Object.prototype.toString.call(r)==="[object Object]"}var oe=class r extends f{constructor(e){super(),this.reviver=e}add(e){let t;if(typeof e=="string"){if(this.reconstructor)throw new Error("got plaintext data when reconstructing a packet");t=this.decodeString(e);let s=t.type===h.BINARY_EVENT;s||t.type===h.BINARY_ACK?(t.type=s?h.EVENT:h.ACK,this.reconstructor=new ce(t),t.attachments===0&&super.emitReserved("decoded",t)):super.emitReserved("decoded",t)}else if(D(e)||e.base64)if(this.reconstructor)t=this.reconstructor.takeBinaryData(e),t&&(this.reconstructor=null,super.emitReserved("decoded",t));else throw new Error("got binary data when not reconstructing a packet");else throw new Error("Unknown type: "+e)}decodeString(e){let t=0,s={type:Number(e.charAt(0))};if(h[s.type]===void 0)throw new Error("unknown packet type "+s.type);if(s.type===h.BINARY_EVENT||s.type===h.BINARY_ACK){let n=t+1;for(;e.charAt(++t)!=="-"&&t!=e.length;);let o=e.substring(n,t);if(o!=Number(o)||e.charAt(t)!=="-")throw new Error("Illegal attachments");s.attachments=Number(o)}if(e.charAt(t+1)==="/"){let n=t+1;for(;++t&&!(e.charAt(t)===","||t===e.length););s.nsp=e.substring(n,t)}else s.nsp="/";let i=e.charAt(t+1);if(i!==""&&Number(i)==i){let n=t+1;for(;++t;){let o=e.charAt(t);if(o==null||Number(o)!=o){--t;break}if(t===e.length)break}s.id=Number(e.substring(n,t+1))}if(e.charAt(++t)){let n=this.tryParse(e.substr(t));if(r.isPayloadValid(s.type,n))s.data=n;else throw new Error("invalid payload")}return s}tryParse(e){try{return JSON.parse(e,this.reviver)}catch{return!1}}static isPayloadValid(e,t){switch(e){case h.CONNECT:return Me(t);case h.DISCONNECT:return t===void 0;case h.CONNECT_ERROR:return typeof t=="string"||Me(t);case h.EVENT:case h.BINARY_EVENT:return Array.isArray(t)&&(typeof t[0]=="number"||typeof t[0]=="string"&&at.indexOf(t[0])===-1);case h.ACK:case h.BINARY_ACK:return Array.isArray(t)}}destroy(){this.reconstructor&&(this.reconstructor.finishedReconstruction(),this.reconstructor=null)}},ce=class{constructor(e){this.packet=e,this.buffers=[],this.reconPack=e}takeBinaryData(e){if(this.buffers.push(e),this.buffers.length===this.reconPack.attachments){let t=Ve(this.reconPack,this.buffers);return this.finishedReconstruction(),t}return null}finishedReconstruction(){this.reconPack=null,this.buffers=[]}};function l(r,e,t){return r.on(e,t),function(){r.off(e,t)}}var ht=Object.freeze({connect:1,connect_error:1,disconnect:1,disconnecting:1,newListener:1,removeListener:1}),A=class extends f{constructor(e,t,s){super(),this.connected=!1,this.recovered=!1,this.receiveBuffer=[],this.sendBuffer=[],this._queue=[],this._queueSeq=0,this.ids=0,this.acks={},this.flags={},this.io=e,this.nsp=t,s&&s.auth&&(this.auth=s.auth),this._opts=Object.assign({},s),this.io._autoConnect&&this.open()}get disconnected(){return!this.connected}subEvents(){if(this.subs)return;let e=this.io;this.subs=[l(e,"open",this.onopen.bind(this)),l(e,"packet",this.onpacket.bind(this)),l(e,"error",this.onerror.bind(this)),l(e,"close",this.onclose.bind(this))]}get active(){return!!this.subs}connect(){return this.connected?this:(this.subEvents(),this.io._reconnecting||this.io.open(),this.io._readyState==="open"&&this.onopen(),this)}open(){return this.connect()}send(...e){return e.unshift("message"),this.emit.apply(this,e),this}emit(e,...t){var s,i,n;if(ht.hasOwnProperty(e))throw new Error('"'+e.toString()+'" is a reserved event name');if(t.unshift(e),this._opts.retries&&!this.flags.fromQueue&&!this.flags.volatile)return this._addToQueue(t),this;let o={type:h.EVENT,data:t};if(o.options={},o.options.compress=this.flags.compress!==!1,typeof t[t.length-1]=="function"){let p=this.ids++,b=t.pop();this._registerAckCallback(p,b),o.id=p}let c=(i=(s=this.io.engine)===null||s===void 0?void 0:s.transport)===null||i===void 0?void 0:i.writable,a=this.connected&&!(!((n=this.io.engine)===null||n===void 0)&&n._hasPingExpired());return this.flags.volatile&&!c||(a?(this.notifyOutgoingListeners(o),this.packet(o)):this.sendBuffer.push(o)),this.flags={},this}_registerAckCallback(e,t){var s;let i=(s=this.flags.timeout)!==null&&s!==void 0?s:this._opts.ackTimeout;if(i===void 0){this.acks[e]=t;return}let n=this.io.setTimeoutFn(()=>{delete this.acks[e];for(let c=0;c<this.sendBuffer.length;c++)this.sendBuffer[c].id===e&&this.sendBuffer.splice(c,1);t.call(this,new Error("operation has timed out"))},i),o=(...c)=>{this.io.clearTimeoutFn(n),t.apply(this,c)};o.withError=!0,this.acks[e]=o}emitWithAck(e,...t){return new Promise((s,i)=>{let n=(o,c)=>o?i(o):s(c);n.withError=!0,t.push(n),this.emit(e,...t)})}_addToQueue(e){let t;typeof e[e.length-1]=="function"&&(t=e.pop());let s={id:this._queueSeq++,tryCount:0,pending:!1,args:e,flags:Object.assign({fromQueue:!0},this.flags)};e.push((i,...n)=>s!==this._queue[0]?void 0:(i!==null?s.tryCount>this._opts.retries&&(this._queue.shift(),t&&t(i)):(this._queue.shift(),t&&t(null,...n)),s.pending=!1,this._drainQueue())),this._queue.push(s),this._drainQueue()}_drainQueue(e=!1){if(!this.connected||this._queue.length===0)return;let t=this._queue[0];t.pending&&!e||(t.pending=!0,t.tryCount++,this.flags=t.flags,this.emit.apply(this,t.args))}packet(e){e.nsp=this.nsp,this.io._packet(e)}onopen(){typeof this.auth=="function"?this.auth(e=>{this._sendConnectPacket(e)}):this._sendConnectPacket(this.auth)}_sendConnectPacket(e){this.packet({type:h.CONNECT,data:this._pid?Object.assign({pid:this._pid,offset:this._lastOffset},e):e})}onerror(e){this.connected||this.emitReserved("connect_error",e)}onclose(e,t){this.connected=!1,delete this.id,this.emitReserved("disconnect",e,t),this._clearAcks()}_clearAcks(){Object.keys(this.acks).forEach(e=>{if(!this.sendBuffer.some(s=>String(s.id)===e)){let s=this.acks[e];delete this.acks[e],s.withError&&s.call(this,new Error("socket has been disconnected"))}})}onpacket(e){if(e.nsp===this.nsp)switch(e.type){case h.CONNECT:e.data&&e.data.sid?this.onconnect(e.data.sid,e.data.pid):this.emitReserved("connect_error",new Error("It seems you are trying to reach a Socket.IO server in v2.x with a v3.x client, but they are not compatible (more information here: https://socket.io/docs/v3/migrating-from-2-x-to-3-0/)"));break;case h.EVENT:case h.BINARY_EVENT:this.onevent(e);break;case h.ACK:case h.BINARY_ACK:this.onack(e);break;case h.DISCONNECT:this.ondisconnect();break;case h.CONNECT_ERROR:this.destroy();let s=new Error(e.data.message);s.data=e.data.data,this.emitReserved("connect_error",s);break}}onevent(e){let t=e.data||[];e.id!=null&&t.push(this.ack(e.id)),this.connected?this.emitEvent(t):this.receiveBuffer.push(Object.freeze(t))}emitEvent(e){if(this._anyListeners&&this._anyListeners.length){let t=this._anyListeners.slice();for(let s of t)s.apply(this,e)}super.emit.apply(this,e),this._pid&&e.length&&typeof e[e.length-1]=="string"&&(this._lastOffset=e[e.length-1])}ack(e){let t=this,s=!1;return function(...i){s||(s=!0,t.packet({type:h.ACK,id:e,data:i}))}}onack(e){let t=this.acks[e.id];typeof t=="function"&&(delete this.acks[e.id],t.withError&&e.data.unshift(null),t.apply(this,e.data))}onconnect(e,t){this.id=e,this.recovered=t&&this._pid===t,this._pid=t,this.connected=!0,this.emitBuffered(),this.emitReserved("connect"),this._drainQueue(!0)}emitBuffered(){this.receiveBuffer.forEach(e=>this.emitEvent(e)),this.receiveBuffer=[],this.sendBuffer.forEach(e=>{this.notifyOutgoingListeners(e),this.packet(e)}),this.sendBuffer=[]}ondisconnect(){this.destroy(),this.onclose("io server disconnect")}destroy(){this.subs&&(this.subs.forEach(e=>e()),this.subs=void 0),this.io._destroy(this)}disconnect(){return this.connected&&this.packet({type:h.DISCONNECT}),this.destroy(),this.connected&&this.onclose("io client disconnect"),this}close(){return this.disconnect()}compress(e){return this.flags.compress=e,this}get volatile(){return this.flags.volatile=!0,this}timeout(e){return this.flags.timeout=e,this}onAny(e){return this._anyListeners=this._anyListeners||[],this._anyListeners.push(e),this}prependAny(e){return this._anyListeners=this._anyListeners||[],this._anyListeners.unshift(e),this}offAny(e){if(!this._anyListeners)return this;if(e){let t=this._anyListeners;for(let s=0;s<t.length;s++)if(e===t[s])return t.splice(s,1),this}else this._anyListeners=[];return this}listenersAny(){return this._anyListeners||[]}onAnyOutgoing(e){return this._anyOutgoingListeners=this._anyOutgoingListeners||[],this._anyOutgoingListeners.push(e),this}prependAnyOutgoing(e){return this._anyOutgoingListeners=this._anyOutgoingListeners||[],this._anyOutgoingListeners.unshift(e),this}offAnyOutgoing(e){if(!this._anyOutgoingListeners)return this;if(e){let t=this._anyOutgoingListeners;for(let s=0;s<t.length;s++)if(e===t[s])return t.splice(s,1),this}else this._anyOutgoingListeners=[];return this}listenersAnyOutgoing(){return this._anyOutgoingListeners||[]}notifyOutgoingListeners(e){if(this._anyOutgoingListeners&&this._anyOutgoingListeners.length){let t=this._anyOutgoingListeners.slice();for(let s of t)s.apply(this,e.data)}}};function E(r){r=r||{},this.ms=r.min||100,this.max=r.max||1e4,this.factor=r.factor||2,this.jitter=r.jitter>0&&r.jitter<=1?r.jitter:0,this.attempts=0}E.prototype.duration=function(){var r=this.ms*Math.pow(this.factor,this.attempts++);if(this.jitter){var e=Math.random(),t=Math.floor(e*this.jitter*r);r=(Math.floor(e*10)&1)==0?r-t:r+t}return Math.min(r,this.max)|0};E.prototype.reset=function(){this.attempts=0};E.prototype.setMin=function(r){this.ms=r};E.prototype.setMax=function(r){this.max=r};E.prototype.setJitter=function(r){this.jitter=r};var R=class extends f{constructor(e,t){var s;super(),this.nsps={},this.subs=[],e&&typeof e=="object"&&(t=e,e=void 0),t=t||{},t.path=t.path||"/socket.io",this.opts=t,g(this,t),this.reconnection(t.reconnection!==!1),this.reconnectionAttempts(t.reconnectionAttempts||1/0),this.reconnectionDelay(t.reconnectionDelay||1e3),this.reconnectionDelayMax(t.reconnectionDelayMax||5e3),this.randomizationFactor((s=t.randomizationFactor)!==null&&s!==void 0?s:.5),this.backoff=new E({min:this.reconnectionDelay(),max:this.reconnectionDelayMax(),jitter:this.randomizationFactor()}),this.timeout(t.timeout==null?2e4:t.timeout),this._readyState="closed",this.uri=e;let i=t.parser||ae;this.encoder=new i.Encoder,this.decoder=new i.Decoder,this._autoConnect=t.autoConnect!==!1,this._autoConnect&&this.open()}reconnection(e){return arguments.length?(this._reconnection=!!e,e||(this.skipReconnect=!0),this):this._reconnection}reconnectionAttempts(e){return e===void 0?this._reconnectionAttempts:(this._reconnectionAttempts=e,this)}reconnectionDelay(e){var t;return e===void 0?this._reconnectionDelay:(this._reconnectionDelay=e,(t=this.backoff)===null||t===void 0||t.setMin(e),this)}randomizationFactor(e){var t;return e===void 0?this._randomizationFactor:(this._randomizationFactor=e,(t=this.backoff)===null||t===void 0||t.setJitter(e),this)}reconnectionDelayMax(e){var t;return e===void 0?this._reconnectionDelayMax:(this._reconnectionDelayMax=e,(t=this.backoff)===null||t===void 0||t.setMax(e),this)}timeout(e){return arguments.length?(this._timeout=e,this):this._timeout}maybeReconnectOnOpen(){!this._reconnecting&&this._reconnection&&this.backoff.attempts===0&&this.reconnect()}open(e){if(~this._readyState.indexOf("open"))return this;this.engine=new T(this.uri,this.opts);let t=this.engine,s=this;this._readyState="opening",this.skipReconnect=!1;let i=l(t,"open",function(){s.onopen(),e&&e()}),n=c=>{this.cleanup(),this._readyState="closed",this.emitReserved("error",c),e?e(c):this.maybeReconnectOnOpen()},o=l(t,"error",n);if(this._timeout!==!1){let c=this._timeout,a=this.setTimeoutFn(()=>{i(),n(new Error("timeout")),t.close()},c);this.opts.autoUnref&&a.unref(),this.subs.push(()=>{this.clearTimeoutFn(a)})}return this.subs.push(i),this.subs.push(o),this}connect(e){return this.open(e)}onopen(){this.cleanup(),this._readyState="open",this.emitReserved("open");let e=this.engine;this.subs.push(l(e,"ping",this.onping.bind(this)),l(e,"data",this.ondata.bind(this)),l(e,"error",this.onerror.bind(this)),l(e,"close",this.onclose.bind(this)),l(this.decoder,"decoded",this.ondecoded.bind(this)))}onping(){this.emitReserved("ping")}ondata(e){try{this.decoder.add(e)}catch(t){this.onclose("parse error",t)}}ondecoded(e){y(()=>{this.emitReserved("packet",e)},this.setTimeoutFn)}onerror(e){this.emitReserved("error",e)}socket(e,t){let s=this.nsps[e];return s?this._autoConnect&&!s.active&&s.connect():(s=new A(this,e,t),this.nsps[e]=s),s}_destroy(e){let t=Object.keys(this.nsps);for(let s of t)if(this.nsps[s].active)return;this._close()}_packet(e){let t=this.encoder.encode(e);for(let s=0;s<t.length;s++)this.engine.write(t[s],e.options)}cleanup(){this.subs.forEach(e=>e()),this.subs.length=0,this.decoder.destroy()}_close(){this.skipReconnect=!0,this._reconnecting=!1,this.onclose("forced close")}disconnect(){return this._close()}onclose(e,t){var s;this.cleanup(),(s=this.engine)===null||s===void 0||s.close(),this.backoff.reset(),this._readyState="closed",this.emitReserved("close",e,t),this._reconnection&&!this.skipReconnect&&this.reconnect()}reconnect(){if(this._reconnecting||this.skipReconnect)return this;let e=this;if(this.backoff.attempts>=this._reconnectionAttempts)this.backoff.reset(),this.emitReserved("reconnect_failed"),this._reconnecting=!1;else{let t=this.backoff.duration();this._reconnecting=!0;let s=this.setTimeoutFn(()=>{e.skipReconnect||(this.emitReserved("reconnect_attempt",e.backoff.attempts),!e.skipReconnect&&e.open(i=>{i?(e._reconnecting=!1,e.reconnect(),this.emitReserved("reconnect_error",i)):e.onreconnect()}))},t);this.opts.autoUnref&&s.unref(),this.subs.push(()=>{this.clearTimeoutFn(s)})}}onreconnect(){let e=this.backoff.attempts;this._reconnecting=!1,this.backoff.reset(),this.emitReserved("reconnect",e)}};var F={};function I(r,e){typeof r=="object"&&(e=r,r=void 0),e=e||{};let t=Fe(r,e.path||"/socket.io"),s=t.source,i=t.id,n=t.path,o=F[i]&&n in F[i].nsps,c=e.forceNew||e["force new connection"]||e.multiplex===!1||o,a;return c?a=new R(s,e):(F[i]||(F[i]=new R(s,e)),a=F[i]),t.query&&!e.query&&(e.query=t.queryKey),a.socket(t.path,e)}Object.assign(I,{Manager:R,Socket:A,io:I,connect:I});var cr=(()=>{class r{$auth=ue(pe);namespaceConnectionCache={};connectToNamespace(t){if(this.namespaceConnectionCache[t]){let s=this.namespaceConnectionCache[t];return s.connected=new X,s.socket.connected&&s.connected.next(void 0),s.socket.on("connect",()=>{s.connected.next(void 0)}),s.end=()=>{s.socket.emit("end"),s.socket.removeAllListeners(),s.connected.complete()},this.namespaceConnectionCache[t]}else{let s=this.establishConnectionToNamespace(t);return s.connected=new X,s.socket.on("connect",()=>{s.connected.next(void 0)}),s.end=()=>{s.socket.emit("end"),s.socket.removeAllListeners(),s.connected.complete()},this.namespaceConnectionCache[t]=s,s}}getExistingNamespace(t){return this.namespaceConnectionCache[t]}establishConnectionToNamespace(t){let s=I(`${le.api.socket}/${t}`,{query:{token:this.$auth.token}});return{socket:s,request:(n,o)=>new he(c=>{s.emit(n,o,a=>{typeof a=="object"&&a.error?c.error(a):c.next(a),c.complete()})})}}static \u0275fac=function(s){return new(s||r)};static \u0275prov=fe({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();export{cr as a};
|
|
1
|
+
import{b as pe}from"./chunk-KTLG6VZT.js";import{J as le}from"./chunk-MW6H5Z5G.js";import{X as fe,aa as ue,c as he,d as X}from"./chunk-ZPXACREZ.js";import{f as We}from"./chunk-B4AJQJMI.js";var d=Object.create(null);d.open="0";d.close="1";d.ping="2";d.pong="3";d.message="4";d.upgrade="5";d.noop="6";var S=Object.create(null);Object.keys(d).forEach(r=>{S[d[r]]=r});var O={type:"error",data:"parser error"};var ye=typeof Blob=="function"||typeof Blob<"u"&&Object.prototype.toString.call(Blob)==="[object BlobConstructor]",ge=typeof ArrayBuffer=="function",_e=r=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(r):r&&r.buffer instanceof ArrayBuffer,B=({type:r,data:e},t,s)=>ye&&e instanceof Blob?t?s(e):de(e,s):ge&&(e instanceof ArrayBuffer||_e(e))?t?s(e):de(new Blob([e]),s):s(d[r]+(e||"")),de=(r,e)=>{let t=new FileReader;return t.onload=function(){let s=t.result.split(",")[1];e("b"+(s||""))},t.readAsDataURL(r)};function me(r){return r instanceof Uint8Array?r:r instanceof ArrayBuffer?new Uint8Array(r):new Uint8Array(r.buffer,r.byteOffset,r.byteLength)}var $;function be(r,e){if(ye&&r.data instanceof Blob)return r.data.arrayBuffer().then(me).then(e);if(ge&&(r.data instanceof ArrayBuffer||_e(r.data)))return e(me(r.data));B(r,!1,t=>{$||($=new TextEncoder),e($.encode(t))})}var we="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",N=typeof Uint8Array>"u"?[]:new Uint8Array(256);for(let r=0;r<we.length;r++)N[we.charCodeAt(r)]=r;var ke=r=>{let e=r.length*.75,t=r.length,s,i=0,n,o,c,a;r[r.length-1]==="="&&(e--,r[r.length-2]==="="&&e--);let m=new ArrayBuffer(e),p=new Uint8Array(m);for(s=0;s<t;s+=4)n=N[r.charCodeAt(s)],o=N[r.charCodeAt(s+1)],c=N[r.charCodeAt(s+2)],a=N[r.charCodeAt(s+3)],p[i++]=n<<2|o>>4,p[i++]=(o&15)<<4|c>>2,p[i++]=(c&3)<<6|a&63;return m};var Ke=typeof ArrayBuffer=="function",L=(r,e)=>{if(typeof r!="string")return{type:"message",data:Ee(r,e)};let t=r.charAt(0);return t==="b"?{type:"message",data:Ye(r.substring(1),e)}:S[t]?r.length>1?{type:S[t],data:r.substring(1)}:{type:S[t]}:O},Ye=(r,e)=>{if(Ke){let t=ke(r);return Ee(t,e)}else return{base64:!0,data:r}},Ee=(r,e)=>{switch(e){case"blob":return r instanceof Blob?r:new Blob([r]);case"arraybuffer":default:return r instanceof ArrayBuffer?r:r.buffer}};var ve="",xe=(r,e)=>{let t=r.length,s=new Array(t),i=0;r.forEach((n,o)=>{B(n,!1,c=>{s[o]=c,++i===t&&e(s.join(ve))})})},Te=(r,e)=>{let t=r.split(ve),s=[];for(let i=0;i<t.length;i++){let n=L(t[i],e);if(s.push(n),n.type==="error")break}return s};function Ae(){return new TransformStream({transform(r,e){be(r,t=>{let s=t.length,i;if(s<126)i=new Uint8Array(1),new DataView(i.buffer).setUint8(0,s);else if(s<65536){i=new Uint8Array(3);let n=new DataView(i.buffer);n.setUint8(0,126),n.setUint16(1,s)}else{i=new Uint8Array(9);let n=new DataView(i.buffer);n.setUint8(0,127),n.setBigUint64(1,BigInt(s))}r.data&&typeof r.data!="string"&&(i[0]|=128),e.enqueue(i),e.enqueue(t)})}})}var Q;function U(r){return r.reduce((e,t)=>e+t.length,0)}function V(r,e){if(r[0].length===e)return r.shift();let t=new Uint8Array(e),s=0;for(let i=0;i<e;i++)t[i]=r[0][s++],s===r[0].length&&(r.shift(),s=0);return r.length&&s<r[0].length&&(r[0]=r[0].slice(s)),t}function Re(r,e){Q||(Q=new TextDecoder);let t=[],s=0,i=-1,n=!1;return new TransformStream({transform(o,c){for(t.push(o);;){if(s===0){if(U(t)<1)break;let a=V(t,1);n=(a[0]&128)===128,i=a[0]&127,i<126?s=3:i===126?s=1:s=2}else if(s===1){if(U(t)<2)break;let a=V(t,2);i=new DataView(a.buffer,a.byteOffset,a.length).getUint16(0),s=3}else if(s===2){if(U(t)<8)break;let a=V(t,8),m=new DataView(a.buffer,a.byteOffset,a.length),p=m.getUint32(0);if(p>Math.pow(2,21)-1){c.enqueue(O);break}i=p*Math.pow(2,32)+m.getUint32(4),s=3}else{if(U(t)<i)break;let a=V(t,i);c.enqueue(L(n?a:Q.decode(a),e)),s=0}if(i===0||i>r){c.enqueue(O);break}}}})}var j=4;function f(r){if(r)return Je(r)}function Je(r){for(var e in f.prototype)r[e]=f.prototype[e];return r}f.prototype.on=f.prototype.addEventListener=function(r,e){return this._callbacks=this._callbacks||{},(this._callbacks["$"+r]=this._callbacks["$"+r]||[]).push(e),this};f.prototype.once=function(r,e){function t(){this.off(r,t),e.apply(this,arguments)}return t.fn=e,this.on(r,t),this};f.prototype.off=f.prototype.removeListener=f.prototype.removeAllListeners=f.prototype.removeEventListener=function(r,e){if(this._callbacks=this._callbacks||{},arguments.length==0)return this._callbacks={},this;var t=this._callbacks["$"+r];if(!t)return this;if(arguments.length==1)return delete this._callbacks["$"+r],this;for(var s,i=0;i<t.length;i++)if(s=t[i],s===e||s.fn===e){t.splice(i,1);break}return t.length===0&&delete this._callbacks["$"+r],this};f.prototype.emit=function(r){this._callbacks=this._callbacks||{};for(var e=new Array(arguments.length-1),t=this._callbacks["$"+r],s=1;s<arguments.length;s++)e[s-1]=arguments[s];if(t){t=t.slice(0);for(var s=0,i=t.length;s<i;++s)t[s].apply(this,e)}return this};f.prototype.emitReserved=f.prototype.emit;f.prototype.listeners=function(r){return this._callbacks=this._callbacks||{},this._callbacks["$"+r]||[]};f.prototype.hasListeners=function(r){return!!this.listeners(r).length};var y=typeof Promise=="function"&&typeof Promise.resolve=="function"?e=>Promise.resolve().then(e):(e,t)=>t(e,0),u=typeof self<"u"?self:typeof window<"u"?window:Function("return this")(),Ce="arraybuffer";function M(r,...e){return e.reduce((t,s)=>(r.hasOwnProperty(s)&&(t[s]=r[s]),t),{})}var ze=u.setTimeout,Xe=u.clearTimeout;function g(r,e){e.useNativeTimers?(r.setTimeoutFn=ze.bind(u),r.clearTimeoutFn=Xe.bind(u)):(r.setTimeoutFn=u.setTimeout.bind(u),r.clearTimeoutFn=u.clearTimeout.bind(u))}var $e=1.33;function Se(r){return typeof r=="string"?Qe(r):Math.ceil((r.byteLength||r.size)*$e)}function Qe(r){let e=0,t=0;for(let s=0,i=r.length;s<i;s++)e=r.charCodeAt(s),e<128?t+=1:e<2048?t+=2:e<55296||e>=57344?t+=3:(s++,t+=4);return t}function H(){return Date.now().toString(36).substring(3)+Math.random().toString(36).substring(2,5)}function Oe(r){let e="";for(let t in r)r.hasOwnProperty(t)&&(e.length&&(e+="&"),e+=encodeURIComponent(t)+"="+encodeURIComponent(r[t]));return e}function Be(r){let e={},t=r.split("&");for(let s=0,i=t.length;s<i;s++){let n=t[s].split("=");e[decodeURIComponent(n[0])]=decodeURIComponent(n[1])}return e}var W=class extends Error{constructor(e,t,s){super(e),this.description=t,this.context=s,this.type="TransportError"}},_=class extends f{constructor(e){super(),this.writable=!1,g(this,e),this.opts=e,this.query=e.query,this.socket=e.socket,this.supportsBinary=!e.forceBase64}onError(e,t,s){return super.emitReserved("error",new W(e,t,s)),this}open(){return this.readyState="opening",this.doOpen(),this}close(){return(this.readyState==="opening"||this.readyState==="open")&&(this.doClose(),this.onClose()),this}send(e){this.readyState==="open"&&this.write(e)}onOpen(){this.readyState="open",this.writable=!0,super.emitReserved("open")}onData(e){let t=L(e,this.socket.binaryType);this.onPacket(t)}onPacket(e){super.emitReserved("packet",e)}onClose(e){this.readyState="closed",super.emitReserved("close",e)}pause(e){}createUri(e,t={}){return e+"://"+this._hostname()+this._port()+this.opts.path+this._query(t)}_hostname(){let e=this.opts.hostname;return e.indexOf(":")===-1?e:"["+e+"]"}_port(){return this.opts.port&&(this.opts.secure&&+(this.opts.port!==443)||!this.opts.secure&&Number(this.opts.port)!==80)?":"+this.opts.port:""}_query(e){let t=Oe(e);return t.length?"?"+t:""}};var P=class extends _{constructor(){super(...arguments),this._polling=!1}get name(){return"polling"}doOpen(){this._poll()}pause(e){this.readyState="pausing";let t=()=>{this.readyState="paused",e()};if(this._polling||!this.writable){let s=0;this._polling&&(s++,this.once("pollComplete",function(){--s||t()})),this.writable||(s++,this.once("drain",function(){--s||t()}))}else t()}_poll(){this._polling=!0,this.doPoll(),this.emitReserved("poll")}onData(e){let t=s=>{if(this.readyState==="opening"&&s.type==="open"&&this.onOpen(),s.type==="close")return this.onClose({description:"transport closed by the server"}),!1;this.onPacket(s)};Te(e,this.socket.binaryType).forEach(t),this.readyState!=="closed"&&(this._polling=!1,this.emitReserved("pollComplete"),this.readyState==="open"&&this._poll())}doClose(){let e=()=>{this.write([{type:"close"}])};this.readyState==="open"?e():this.once("open",e)}write(e){this.writable=!1,xe(e,t=>{this.doWrite(t,()=>{this.writable=!0,this.emitReserved("drain")})})}uri(){let e=this.opts.secure?"https":"http",t=this.query||{};return this.opts.timestampRequests!==!1&&(t[this.opts.timestampParam]=H()),!this.supportsBinary&&!t.sid&&(t.b64=1),this.createUri(e,t)}};var Ne=!1;try{Ne=typeof XMLHttpRequest<"u"&&"withCredentials"in new XMLHttpRequest}catch{}var Le=Ne;function je(){}var G=class extends P{constructor(e){if(super(e),typeof location<"u"){let t=location.protocol==="https:",s=location.port;s||(s=t?"443":"80"),this.xd=typeof location<"u"&&e.hostname!==location.hostname||s!==e.port}}doWrite(e,t){let s=this.request({method:"POST",data:e});s.on("success",t),s.on("error",(i,n)=>{this.onError("xhr post error",i,n)})}doPoll(){let e=this.request();e.on("data",this.onData.bind(this)),e.on("error",(t,s)=>{this.onError("xhr poll error",t,s)}),this.pollXhr=e}},K=(()=>{class r extends f{constructor(t,s,i){super(),this.createRequest=t,g(this,i),this._opts=i,this._method=i.method||"GET",this._uri=s,this._data=i.data!==void 0?i.data:null,this._create()}_create(){var t;let s=M(this._opts,"agent","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","autoUnref");s.xdomain=!!this._opts.xd;let i=this._xhr=this.createRequest(s);try{i.open(this._method,this._uri,!0);try{if(this._opts.extraHeaders){i.setDisableHeaderCheck&&i.setDisableHeaderCheck(!0);for(let n in this._opts.extraHeaders)this._opts.extraHeaders.hasOwnProperty(n)&&i.setRequestHeader(n,this._opts.extraHeaders[n])}}catch{}if(this._method==="POST")try{i.setRequestHeader("Content-type","text/plain;charset=UTF-8")}catch{}try{i.setRequestHeader("Accept","*/*")}catch{}(t=this._opts.cookieJar)===null||t===void 0||t.addCookies(i),"withCredentials"in i&&(i.withCredentials=this._opts.withCredentials),this._opts.requestTimeout&&(i.timeout=this._opts.requestTimeout),i.onreadystatechange=()=>{var n;i.readyState===3&&((n=this._opts.cookieJar)===null||n===void 0||n.parseCookies(i.getResponseHeader("set-cookie"))),i.readyState===4&&(i.status===200||i.status===1223?this._onLoad():this.setTimeoutFn(()=>{this._onError(typeof i.status=="number"?i.status:0)},0))},i.send(this._data)}catch(n){this.setTimeoutFn(()=>{this._onError(n)},0);return}typeof document<"u"&&(this._index=r.requestsCount++,r.requests[this._index]=this)}_onError(t){this.emitReserved("error",t,this._xhr),this._cleanup(!0)}_cleanup(t){if(!(typeof this._xhr>"u"||this._xhr===null)){if(this._xhr.onreadystatechange=je,t)try{this._xhr.abort()}catch{}typeof document<"u"&&delete r.requests[this._index],this._xhr=null}}_onLoad(){let t=this._xhr.responseText;t!==null&&(this.emitReserved("data",t),this.emitReserved("success"),this._cleanup())}abort(){this._cleanup()}}return r.requestsCount=0,r.requests={},r})();if(typeof document<"u"){if(typeof attachEvent=="function")attachEvent("onunload",Pe);else if(typeof addEventListener=="function"){let r="onpagehide"in u?"pagehide":"unload";addEventListener(r,Pe,!1)}}function Pe(){for(let r in K.requests)K.requests.hasOwnProperty(r)&&K.requests[r].abort()}var Ge=(function(){let r=qe({xdomain:!1});return r&&r.responseType!==null})(),w=class extends G{constructor(e){super(e);let t=e&&e.forceBase64;this.supportsBinary=Ge&&!t}request(e={}){return Object.assign(e,{xd:this.xd},this.opts),new K(qe,this.uri(),e)}};function qe(r){let e=r.xdomain;try{if(typeof XMLHttpRequest<"u"&&(!e||Le))return new XMLHttpRequest}catch{}if(!e)try{return new u[["Active"].concat("Object").join("X")]("Microsoft.XMLHTTP")}catch{}}var De=typeof navigator<"u"&&typeof navigator.product=="string"&&navigator.product.toLowerCase()==="reactnative",ee=class extends _{get name(){return"websocket"}doOpen(){let e=this.uri(),t=this.opts.protocols,s=De?{}:M(this.opts,"agent","perMessageDeflate","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","localAddress","protocolVersion","origin","maxPayload","family","checkServerIdentity");this.opts.extraHeaders&&(s.headers=this.opts.extraHeaders);try{this.ws=this.createSocket(e,t,s)}catch(i){return this.emitReserved("error",i)}this.ws.binaryType=this.socket.binaryType,this.addEventListeners()}addEventListeners(){this.ws.onopen=()=>{this.opts.autoUnref&&this.ws._socket.unref(),this.onOpen()},this.ws.onclose=e=>this.onClose({description:"websocket connection closed",context:e}),this.ws.onmessage=e=>this.onData(e.data),this.ws.onerror=e=>this.onError("websocket error",e)}write(e){this.writable=!1;for(let t=0;t<e.length;t++){let s=e[t],i=t===e.length-1;B(s,this.supportsBinary,n=>{try{this.doWrite(s,n)}catch{}i&&y(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){typeof this.ws<"u"&&(this.ws.onerror=()=>{},this.ws.close(),this.ws=null)}uri(){let e=this.opts.secure?"wss":"ws",t=this.query||{};return this.opts.timestampRequests&&(t[this.opts.timestampParam]=H()),this.supportsBinary||(t.b64=1),this.createUri(e,t)}},Z=u.WebSocket||u.MozWebSocket,k=class extends ee{createSocket(e,t,s){return De?new Z(e,t,s):t?new Z(e,t):new Z(e)}doWrite(e,t){this.ws.send(t)}};var v=class extends _{get name(){return"webtransport"}doOpen(){try{this._transport=new WebTransport(this.createUri("https"),this.opts.transportOptions[this.name])}catch(e){return this.emitReserved("error",e)}this._transport.closed.then(()=>{this.onClose()}).catch(e=>{this.onError("webtransport error",e)}),this._transport.ready.then(()=>{this._transport.createBidirectionalStream().then(e=>{let t=Re(Number.MAX_SAFE_INTEGER,this.socket.binaryType),s=e.readable.pipeThrough(t).getReader(),i=Ae();i.readable.pipeTo(e.writable),this._writer=i.writable.getWriter();let n=()=>{s.read().then(({done:c,value:a})=>{c||(this.onPacket(a),n())}).catch(c=>{})};n();let o={type:"open"};this.query.sid&&(o.data=`{"sid":"${this.query.sid}"}`),this._writer.write(o).then(()=>this.onOpen())})})}write(e){this.writable=!1;for(let t=0;t<e.length;t++){let s=e[t],i=t===e.length-1;this._writer.write(s).then(()=>{i&&y(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){var e;(e=this._transport)===null||e===void 0||e.close()}};var te={websocket:k,webtransport:v,polling:w};var Ze=/^(?:(?![^:@\/?#]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@\/?#]*)(?::([^:@\/?#]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,et=["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"];function x(r){if(r.length>8e3)throw"URI too long";let e=r,t=r.indexOf("["),s=r.indexOf("]");t!=-1&&s!=-1&&(r=r.substring(0,t)+r.substring(t,s).replace(/:/g,";")+r.substring(s,r.length));let i=Ze.exec(r||""),n={},o=14;for(;o--;)n[et[o]]=i[o]||"";return t!=-1&&s!=-1&&(n.source=e,n.host=n.host.substring(1,n.host.length-1).replace(/;/g,":"),n.authority=n.authority.replace("[","").replace("]","").replace(/;/g,":"),n.ipv6uri=!0),n.pathNames=tt(n,n.path),n.queryKey=st(n,n.query),n}function tt(r,e){let t=/\/{2,9}/g,s=e.replace(t,"/").split("/");return(e.slice(0,1)=="/"||e.length===0)&&s.splice(0,1),e.slice(-1)=="/"&&s.splice(s.length-1,1),s}function st(r,e){let t={};return e.replace(/(?:^|&)([^&=]*)=?([^&]*)/g,function(s,i,n){i&&(t[i]=n)}),t}var se=typeof addEventListener=="function"&&typeof removeEventListener=="function",Y=[];se&&addEventListener("offline",()=>{Y.forEach(r=>r())},!1);var J=(()=>{class r extends f{constructor(t,s){if(super(),this.binaryType=Ce,this.writeBuffer=[],this._prevBufferLen=0,this._pingInterval=-1,this._pingTimeout=-1,this._maxPayload=-1,this._pingTimeoutTime=1/0,t&&typeof t=="object"&&(s=t,t=null),t){let i=x(t);s.hostname=i.host,s.secure=i.protocol==="https"||i.protocol==="wss",s.port=i.port,i.query&&(s.query=i.query)}else s.host&&(s.hostname=x(s.host).host);g(this,s),this.secure=s.secure!=null?s.secure:typeof location<"u"&&location.protocol==="https:",s.hostname&&!s.port&&(s.port=this.secure?"443":"80"),this.hostname=s.hostname||(typeof location<"u"?location.hostname:"localhost"),this.port=s.port||(typeof location<"u"&&location.port?location.port:this.secure?"443":"80"),this.transports=[],this._transportsByName={},s.transports.forEach(i=>{let n=i.prototype.name;this.transports.push(n),this._transportsByName[n]=i}),this.opts=Object.assign({path:"/engine.io",agent:!1,withCredentials:!1,upgrade:!0,timestampParam:"t",rememberUpgrade:!1,addTrailingSlash:!0,rejectUnauthorized:!0,perMessageDeflate:{threshold:1024},transportOptions:{},closeOnBeforeunload:!1},s),this.opts.path=this.opts.path.replace(/\/$/,"")+(this.opts.addTrailingSlash?"/":""),typeof this.opts.query=="string"&&(this.opts.query=Be(this.opts.query)),se&&(this.opts.closeOnBeforeunload&&(this._beforeunloadEventListener=()=>{this.transport&&(this.transport.removeAllListeners(),this.transport.close())},addEventListener("beforeunload",this._beforeunloadEventListener,!1)),this.hostname!=="localhost"&&(this._offlineEventListener=()=>{this._onClose("transport close",{description:"network connection lost"})},Y.push(this._offlineEventListener))),this.opts.withCredentials&&(this._cookieJar=void 0),this._open()}createTransport(t){let s=Object.assign({},this.opts.query);s.EIO=j,s.transport=t,this.id&&(s.sid=this.id);let i=Object.assign({},this.opts,{query:s,socket:this,hostname:this.hostname,secure:this.secure,port:this.port},this.opts.transportOptions[t]);return new this._transportsByName[t](i)}_open(){if(this.transports.length===0){this.setTimeoutFn(()=>{this.emitReserved("error","No transports available")},0);return}let t=this.opts.rememberUpgrade&&r.priorWebsocketSuccess&&this.transports.indexOf("websocket")!==-1?"websocket":this.transports[0];this.readyState="opening";let s=this.createTransport(t);s.open(),this.setTransport(s)}setTransport(t){this.transport&&this.transport.removeAllListeners(),this.transport=t,t.on("drain",this._onDrain.bind(this)).on("packet",this._onPacket.bind(this)).on("error",this._onError.bind(this)).on("close",s=>this._onClose("transport close",s))}onOpen(){this.readyState="open",r.priorWebsocketSuccess=this.transport.name==="websocket",this.emitReserved("open"),this.flush()}_onPacket(t){if(this.readyState==="opening"||this.readyState==="open"||this.readyState==="closing")switch(this.emitReserved("packet",t),this.emitReserved("heartbeat"),t.type){case"open":this.onHandshake(JSON.parse(t.data));break;case"ping":this._sendPacket("pong"),this.emitReserved("ping"),this.emitReserved("pong"),this._resetPingTimeout();break;case"error":let s=new Error("server error");s.code=t.data,this._onError(s);break;case"message":this.emitReserved("data",t.data),this.emitReserved("message",t.data);break}}onHandshake(t){this.emitReserved("handshake",t),this.id=t.sid,this.transport.query.sid=t.sid,this._pingInterval=t.pingInterval,this._pingTimeout=t.pingTimeout,this._maxPayload=t.maxPayload,this.onOpen(),this.readyState!=="closed"&&this._resetPingTimeout()}_resetPingTimeout(){this.clearTimeoutFn(this._pingTimeoutTimer);let t=this._pingInterval+this._pingTimeout;this._pingTimeoutTime=Date.now()+t,this._pingTimeoutTimer=this.setTimeoutFn(()=>{this._onClose("ping timeout")},t),this.opts.autoUnref&&this._pingTimeoutTimer.unref()}_onDrain(){this.writeBuffer.splice(0,this._prevBufferLen),this._prevBufferLen=0,this.writeBuffer.length===0?this.emitReserved("drain"):this.flush()}flush(){if(this.readyState!=="closed"&&this.transport.writable&&!this.upgrading&&this.writeBuffer.length){let t=this._getWritablePackets();this.transport.send(t),this._prevBufferLen=t.length,this.emitReserved("flush")}}_getWritablePackets(){if(!(this._maxPayload&&this.transport.name==="polling"&&this.writeBuffer.length>1))return this.writeBuffer;let s=1;for(let i=0;i<this.writeBuffer.length;i++){let n=this.writeBuffer[i].data;if(n&&(s+=Se(n)),i>0&&s>this._maxPayload)return this.writeBuffer.slice(0,i);s+=2}return this.writeBuffer}_hasPingExpired(){if(!this._pingTimeoutTime)return!0;let t=Date.now()>this._pingTimeoutTime;return t&&(this._pingTimeoutTime=0,y(()=>{this._onClose("ping timeout")},this.setTimeoutFn)),t}write(t,s,i){return this._sendPacket("message",t,s,i),this}send(t,s,i){return this._sendPacket("message",t,s,i),this}_sendPacket(t,s,i,n){if(typeof s=="function"&&(n=s,s=void 0),typeof i=="function"&&(n=i,i=null),this.readyState==="closing"||this.readyState==="closed")return;i=i||{},i.compress=i.compress!==!1;let o={type:t,data:s,options:i};this.emitReserved("packetCreate",o),this.writeBuffer.push(o),n&&this.once("flush",n),this.flush()}close(){let t=()=>{this._onClose("forced close"),this.transport.close()},s=()=>{this.off("upgrade",s),this.off("upgradeError",s),t()},i=()=>{this.once("upgrade",s),this.once("upgradeError",s)};return(this.readyState==="opening"||this.readyState==="open")&&(this.readyState="closing",this.writeBuffer.length?this.once("drain",()=>{this.upgrading?i():t()}):this.upgrading?i():t()),this}_onError(t){if(r.priorWebsocketSuccess=!1,this.opts.tryAllTransports&&this.transports.length>1&&this.readyState==="opening")return this.transports.shift(),this._open();this.emitReserved("error",t),this._onClose("transport error",t)}_onClose(t,s){if(this.readyState==="opening"||this.readyState==="open"||this.readyState==="closing"){if(this.clearTimeoutFn(this._pingTimeoutTimer),this.transport.removeAllListeners("close"),this.transport.close(),this.transport.removeAllListeners(),se&&(this._beforeunloadEventListener&&removeEventListener("beforeunload",this._beforeunloadEventListener,!1),this._offlineEventListener)){let i=Y.indexOf(this._offlineEventListener);i!==-1&&Y.splice(i,1)}this.readyState="closed",this.id=null,this.emitReserved("close",t,s),this.writeBuffer=[],this._prevBufferLen=0}}}return r.protocol=j,r})(),z=class extends J{constructor(){super(...arguments),this._upgrades=[]}onOpen(){if(super.onOpen(),this.readyState==="open"&&this.opts.upgrade)for(let e=0;e<this._upgrades.length;e++)this._probe(this._upgrades[e])}_probe(e){let t=this.createTransport(e),s=!1;J.priorWebsocketSuccess=!1;let i=()=>{s||(t.send([{type:"ping",data:"probe"}]),t.once("packet",b=>{if(!s)if(b.type==="pong"&&b.data==="probe"){if(this.upgrading=!0,this.emitReserved("upgrading",t),!t)return;J.priorWebsocketSuccess=t.name==="websocket",this.transport.pause(()=>{s||this.readyState!=="closed"&&(p(),this.setTransport(t),t.send([{type:"upgrade"}]),this.emitReserved("upgrade",t),t=null,this.upgrading=!1,this.flush())})}else{let C=new Error("probe error");C.transport=t.name,this.emitReserved("upgradeError",C)}}))};function n(){s||(s=!0,p(),t.close(),t=null)}let o=b=>{let C=new Error("probe error: "+b);C.transport=t.name,n(),this.emitReserved("upgradeError",C)};function c(){o("transport closed")}function a(){o("socket closed")}function m(b){t&&b.name!==t.name&&n()}let p=()=>{t.removeListener("open",i),t.removeListener("error",o),t.removeListener("close",c),this.off("close",a),this.off("upgrading",m)};t.once("open",i),t.once("error",o),t.once("close",c),this.once("close",a),this.once("upgrading",m),this._upgrades.indexOf("webtransport")!==-1&&e!=="webtransport"?this.setTimeoutFn(()=>{s||t.open()},200):t.open()}onHandshake(e){this._upgrades=this._filterUpgrades(e.upgrades),super.onHandshake(e)}_filterUpgrades(e){let t=[];for(let s=0;s<e.length;s++)~this.transports.indexOf(e[s])&&t.push(e[s]);return t}},T=class extends z{constructor(e,t={}){let s=typeof e=="object"?e:t;(!s.transports||s.transports&&typeof s.transports[0]=="string")&&(s.transports=(s.transports||["polling","websocket","webtransport"]).map(i=>te[i]).filter(i=>!!i)),super(e,s)}};var ds=T.protocol;function Fe(r,e="",t){let s=r;t=t||typeof location<"u"&&location,r==null&&(r=t.protocol+"//"+t.host),typeof r=="string"&&(r.charAt(0)==="/"&&(r.charAt(1)==="/"?r=t.protocol+r:r=t.host+r),/^(https?|wss?):\/\//.test(r)||(typeof t<"u"?r=t.protocol+"//"+r:r="https://"+r),s=x(r)),s.port||(/^(http|ws)$/.test(s.protocol)?s.port="80":/^(http|ws)s$/.test(s.protocol)&&(s.port="443")),s.path=s.path||"/";let n=s.host.indexOf(":")!==-1?"["+s.host+"]":s.host;return s.id=s.protocol+"://"+n+":"+s.port+e,s.href=s.protocol+"://"+n+(t&&t.port===s.port?"":":"+s.port),s}var ae={};We(ae,{Decoder:()=>oe,Encoder:()=>ne,PacketType:()=>h,protocol:()=>He});var it=typeof ArrayBuffer=="function",nt=r=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(r):r.buffer instanceof ArrayBuffer,Ie=Object.prototype.toString,ot=typeof Blob=="function"||typeof Blob<"u"&&Ie.call(Blob)==="[object BlobConstructor]",ct=typeof File=="function"||typeof File<"u"&&Ie.call(File)==="[object FileConstructor]";function D(r){return it&&(r instanceof ArrayBuffer||nt(r))||ot&&r instanceof Blob||ct&&r instanceof File}function q(r,e){if(!r||typeof r!="object")return!1;if(Array.isArray(r)){for(let t=0,s=r.length;t<s;t++)if(q(r[t]))return!0;return!1}if(D(r))return!0;if(r.toJSON&&typeof r.toJSON=="function"&&arguments.length===1)return q(r.toJSON(),!0);for(let t in r)if(Object.prototype.hasOwnProperty.call(r,t)&&q(r[t]))return!0;return!1}function Ue(r){let e=[],t=r.data,s=r;return s.data=re(t,e),s.attachments=e.length,{packet:s,buffers:e}}function re(r,e){if(!r)return r;if(D(r)){let t={_placeholder:!0,num:e.length};return e.push(r),t}else if(Array.isArray(r)){let t=new Array(r.length);for(let s=0;s<r.length;s++)t[s]=re(r[s],e);return t}else if(typeof r=="object"&&!(r instanceof Date)){let t={};for(let s in r)Object.prototype.hasOwnProperty.call(r,s)&&(t[s]=re(r[s],e));return t}return r}function Ve(r,e){return r.data=ie(r.data,e),delete r.attachments,r}function ie(r,e){if(!r)return r;if(r&&r._placeholder===!0){if(typeof r.num=="number"&&r.num>=0&&r.num<e.length)return e[r.num];throw new Error("illegal attachments")}else if(Array.isArray(r))for(let t=0;t<r.length;t++)r[t]=ie(r[t],e);else if(typeof r=="object")for(let t in r)Object.prototype.hasOwnProperty.call(r,t)&&(r[t]=ie(r[t],e));return r}var at=["connect","connect_error","disconnect","disconnecting","newListener","removeListener"],He=5,h=(function(r){return r[r.CONNECT=0]="CONNECT",r[r.DISCONNECT=1]="DISCONNECT",r[r.EVENT=2]="EVENT",r[r.ACK=3]="ACK",r[r.CONNECT_ERROR=4]="CONNECT_ERROR",r[r.BINARY_EVENT=5]="BINARY_EVENT",r[r.BINARY_ACK=6]="BINARY_ACK",r})(h||{}),ne=class{constructor(e){this.replacer=e}encode(e){return(e.type===h.EVENT||e.type===h.ACK)&&q(e)?this.encodeAsBinary({type:e.type===h.EVENT?h.BINARY_EVENT:h.BINARY_ACK,nsp:e.nsp,data:e.data,id:e.id}):[this.encodeAsString(e)]}encodeAsString(e){let t=""+e.type;return(e.type===h.BINARY_EVENT||e.type===h.BINARY_ACK)&&(t+=e.attachments+"-"),e.nsp&&e.nsp!=="/"&&(t+=e.nsp+","),e.id!=null&&(t+=e.id),e.data!=null&&(t+=JSON.stringify(e.data,this.replacer)),t}encodeAsBinary(e){let t=Ue(e),s=this.encodeAsString(t.packet),i=t.buffers;return i.unshift(s),i}};function Me(r){return Object.prototype.toString.call(r)==="[object Object]"}var oe=class r extends f{constructor(e){super(),this.reviver=e}add(e){let t;if(typeof e=="string"){if(this.reconstructor)throw new Error("got plaintext data when reconstructing a packet");t=this.decodeString(e);let s=t.type===h.BINARY_EVENT;s||t.type===h.BINARY_ACK?(t.type=s?h.EVENT:h.ACK,this.reconstructor=new ce(t),t.attachments===0&&super.emitReserved("decoded",t)):super.emitReserved("decoded",t)}else if(D(e)||e.base64)if(this.reconstructor)t=this.reconstructor.takeBinaryData(e),t&&(this.reconstructor=null,super.emitReserved("decoded",t));else throw new Error("got binary data when not reconstructing a packet");else throw new Error("Unknown type: "+e)}decodeString(e){let t=0,s={type:Number(e.charAt(0))};if(h[s.type]===void 0)throw new Error("unknown packet type "+s.type);if(s.type===h.BINARY_EVENT||s.type===h.BINARY_ACK){let n=t+1;for(;e.charAt(++t)!=="-"&&t!=e.length;);let o=e.substring(n,t);if(o!=Number(o)||e.charAt(t)!=="-")throw new Error("Illegal attachments");s.attachments=Number(o)}if(e.charAt(t+1)==="/"){let n=t+1;for(;++t&&!(e.charAt(t)===","||t===e.length););s.nsp=e.substring(n,t)}else s.nsp="/";let i=e.charAt(t+1);if(i!==""&&Number(i)==i){let n=t+1;for(;++t;){let o=e.charAt(t);if(o==null||Number(o)!=o){--t;break}if(t===e.length)break}s.id=Number(e.substring(n,t+1))}if(e.charAt(++t)){let n=this.tryParse(e.substr(t));if(r.isPayloadValid(s.type,n))s.data=n;else throw new Error("invalid payload")}return s}tryParse(e){try{return JSON.parse(e,this.reviver)}catch{return!1}}static isPayloadValid(e,t){switch(e){case h.CONNECT:return Me(t);case h.DISCONNECT:return t===void 0;case h.CONNECT_ERROR:return typeof t=="string"||Me(t);case h.EVENT:case h.BINARY_EVENT:return Array.isArray(t)&&(typeof t[0]=="number"||typeof t[0]=="string"&&at.indexOf(t[0])===-1);case h.ACK:case h.BINARY_ACK:return Array.isArray(t)}}destroy(){this.reconstructor&&(this.reconstructor.finishedReconstruction(),this.reconstructor=null)}},ce=class{constructor(e){this.packet=e,this.buffers=[],this.reconPack=e}takeBinaryData(e){if(this.buffers.push(e),this.buffers.length===this.reconPack.attachments){let t=Ve(this.reconPack,this.buffers);return this.finishedReconstruction(),t}return null}finishedReconstruction(){this.reconPack=null,this.buffers=[]}};function l(r,e,t){return r.on(e,t),function(){r.off(e,t)}}var ht=Object.freeze({connect:1,connect_error:1,disconnect:1,disconnecting:1,newListener:1,removeListener:1}),A=class extends f{constructor(e,t,s){super(),this.connected=!1,this.recovered=!1,this.receiveBuffer=[],this.sendBuffer=[],this._queue=[],this._queueSeq=0,this.ids=0,this.acks={},this.flags={},this.io=e,this.nsp=t,s&&s.auth&&(this.auth=s.auth),this._opts=Object.assign({},s),this.io._autoConnect&&this.open()}get disconnected(){return!this.connected}subEvents(){if(this.subs)return;let e=this.io;this.subs=[l(e,"open",this.onopen.bind(this)),l(e,"packet",this.onpacket.bind(this)),l(e,"error",this.onerror.bind(this)),l(e,"close",this.onclose.bind(this))]}get active(){return!!this.subs}connect(){return this.connected?this:(this.subEvents(),this.io._reconnecting||this.io.open(),this.io._readyState==="open"&&this.onopen(),this)}open(){return this.connect()}send(...e){return e.unshift("message"),this.emit.apply(this,e),this}emit(e,...t){var s,i,n;if(ht.hasOwnProperty(e))throw new Error('"'+e.toString()+'" is a reserved event name');if(t.unshift(e),this._opts.retries&&!this.flags.fromQueue&&!this.flags.volatile)return this._addToQueue(t),this;let o={type:h.EVENT,data:t};if(o.options={},o.options.compress=this.flags.compress!==!1,typeof t[t.length-1]=="function"){let p=this.ids++,b=t.pop();this._registerAckCallback(p,b),o.id=p}let c=(i=(s=this.io.engine)===null||s===void 0?void 0:s.transport)===null||i===void 0?void 0:i.writable,a=this.connected&&!(!((n=this.io.engine)===null||n===void 0)&&n._hasPingExpired());return this.flags.volatile&&!c||(a?(this.notifyOutgoingListeners(o),this.packet(o)):this.sendBuffer.push(o)),this.flags={},this}_registerAckCallback(e,t){var s;let i=(s=this.flags.timeout)!==null&&s!==void 0?s:this._opts.ackTimeout;if(i===void 0){this.acks[e]=t;return}let n=this.io.setTimeoutFn(()=>{delete this.acks[e];for(let c=0;c<this.sendBuffer.length;c++)this.sendBuffer[c].id===e&&this.sendBuffer.splice(c,1);t.call(this,new Error("operation has timed out"))},i),o=(...c)=>{this.io.clearTimeoutFn(n),t.apply(this,c)};o.withError=!0,this.acks[e]=o}emitWithAck(e,...t){return new Promise((s,i)=>{let n=(o,c)=>o?i(o):s(c);n.withError=!0,t.push(n),this.emit(e,...t)})}_addToQueue(e){let t;typeof e[e.length-1]=="function"&&(t=e.pop());let s={id:this._queueSeq++,tryCount:0,pending:!1,args:e,flags:Object.assign({fromQueue:!0},this.flags)};e.push((i,...n)=>s!==this._queue[0]?void 0:(i!==null?s.tryCount>this._opts.retries&&(this._queue.shift(),t&&t(i)):(this._queue.shift(),t&&t(null,...n)),s.pending=!1,this._drainQueue())),this._queue.push(s),this._drainQueue()}_drainQueue(e=!1){if(!this.connected||this._queue.length===0)return;let t=this._queue[0];t.pending&&!e||(t.pending=!0,t.tryCount++,this.flags=t.flags,this.emit.apply(this,t.args))}packet(e){e.nsp=this.nsp,this.io._packet(e)}onopen(){typeof this.auth=="function"?this.auth(e=>{this._sendConnectPacket(e)}):this._sendConnectPacket(this.auth)}_sendConnectPacket(e){this.packet({type:h.CONNECT,data:this._pid?Object.assign({pid:this._pid,offset:this._lastOffset},e):e})}onerror(e){this.connected||this.emitReserved("connect_error",e)}onclose(e,t){this.connected=!1,delete this.id,this.emitReserved("disconnect",e,t),this._clearAcks()}_clearAcks(){Object.keys(this.acks).forEach(e=>{if(!this.sendBuffer.some(s=>String(s.id)===e)){let s=this.acks[e];delete this.acks[e],s.withError&&s.call(this,new Error("socket has been disconnected"))}})}onpacket(e){if(e.nsp===this.nsp)switch(e.type){case h.CONNECT:e.data&&e.data.sid?this.onconnect(e.data.sid,e.data.pid):this.emitReserved("connect_error",new Error("It seems you are trying to reach a Socket.IO server in v2.x with a v3.x client, but they are not compatible (more information here: https://socket.io/docs/v3/migrating-from-2-x-to-3-0/)"));break;case h.EVENT:case h.BINARY_EVENT:this.onevent(e);break;case h.ACK:case h.BINARY_ACK:this.onack(e);break;case h.DISCONNECT:this.ondisconnect();break;case h.CONNECT_ERROR:this.destroy();let s=new Error(e.data.message);s.data=e.data.data,this.emitReserved("connect_error",s);break}}onevent(e){let t=e.data||[];e.id!=null&&t.push(this.ack(e.id)),this.connected?this.emitEvent(t):this.receiveBuffer.push(Object.freeze(t))}emitEvent(e){if(this._anyListeners&&this._anyListeners.length){let t=this._anyListeners.slice();for(let s of t)s.apply(this,e)}super.emit.apply(this,e),this._pid&&e.length&&typeof e[e.length-1]=="string"&&(this._lastOffset=e[e.length-1])}ack(e){let t=this,s=!1;return function(...i){s||(s=!0,t.packet({type:h.ACK,id:e,data:i}))}}onack(e){let t=this.acks[e.id];typeof t=="function"&&(delete this.acks[e.id],t.withError&&e.data.unshift(null),t.apply(this,e.data))}onconnect(e,t){this.id=e,this.recovered=t&&this._pid===t,this._pid=t,this.connected=!0,this.emitBuffered(),this.emitReserved("connect"),this._drainQueue(!0)}emitBuffered(){this.receiveBuffer.forEach(e=>this.emitEvent(e)),this.receiveBuffer=[],this.sendBuffer.forEach(e=>{this.notifyOutgoingListeners(e),this.packet(e)}),this.sendBuffer=[]}ondisconnect(){this.destroy(),this.onclose("io server disconnect")}destroy(){this.subs&&(this.subs.forEach(e=>e()),this.subs=void 0),this.io._destroy(this)}disconnect(){return this.connected&&this.packet({type:h.DISCONNECT}),this.destroy(),this.connected&&this.onclose("io client disconnect"),this}close(){return this.disconnect()}compress(e){return this.flags.compress=e,this}get volatile(){return this.flags.volatile=!0,this}timeout(e){return this.flags.timeout=e,this}onAny(e){return this._anyListeners=this._anyListeners||[],this._anyListeners.push(e),this}prependAny(e){return this._anyListeners=this._anyListeners||[],this._anyListeners.unshift(e),this}offAny(e){if(!this._anyListeners)return this;if(e){let t=this._anyListeners;for(let s=0;s<t.length;s++)if(e===t[s])return t.splice(s,1),this}else this._anyListeners=[];return this}listenersAny(){return this._anyListeners||[]}onAnyOutgoing(e){return this._anyOutgoingListeners=this._anyOutgoingListeners||[],this._anyOutgoingListeners.push(e),this}prependAnyOutgoing(e){return this._anyOutgoingListeners=this._anyOutgoingListeners||[],this._anyOutgoingListeners.unshift(e),this}offAnyOutgoing(e){if(!this._anyOutgoingListeners)return this;if(e){let t=this._anyOutgoingListeners;for(let s=0;s<t.length;s++)if(e===t[s])return t.splice(s,1),this}else this._anyOutgoingListeners=[];return this}listenersAnyOutgoing(){return this._anyOutgoingListeners||[]}notifyOutgoingListeners(e){if(this._anyOutgoingListeners&&this._anyOutgoingListeners.length){let t=this._anyOutgoingListeners.slice();for(let s of t)s.apply(this,e.data)}}};function E(r){r=r||{},this.ms=r.min||100,this.max=r.max||1e4,this.factor=r.factor||2,this.jitter=r.jitter>0&&r.jitter<=1?r.jitter:0,this.attempts=0}E.prototype.duration=function(){var r=this.ms*Math.pow(this.factor,this.attempts++);if(this.jitter){var e=Math.random(),t=Math.floor(e*this.jitter*r);r=(Math.floor(e*10)&1)==0?r-t:r+t}return Math.min(r,this.max)|0};E.prototype.reset=function(){this.attempts=0};E.prototype.setMin=function(r){this.ms=r};E.prototype.setMax=function(r){this.max=r};E.prototype.setJitter=function(r){this.jitter=r};var R=class extends f{constructor(e,t){var s;super(),this.nsps={},this.subs=[],e&&typeof e=="object"&&(t=e,e=void 0),t=t||{},t.path=t.path||"/socket.io",this.opts=t,g(this,t),this.reconnection(t.reconnection!==!1),this.reconnectionAttempts(t.reconnectionAttempts||1/0),this.reconnectionDelay(t.reconnectionDelay||1e3),this.reconnectionDelayMax(t.reconnectionDelayMax||5e3),this.randomizationFactor((s=t.randomizationFactor)!==null&&s!==void 0?s:.5),this.backoff=new E({min:this.reconnectionDelay(),max:this.reconnectionDelayMax(),jitter:this.randomizationFactor()}),this.timeout(t.timeout==null?2e4:t.timeout),this._readyState="closed",this.uri=e;let i=t.parser||ae;this.encoder=new i.Encoder,this.decoder=new i.Decoder,this._autoConnect=t.autoConnect!==!1,this._autoConnect&&this.open()}reconnection(e){return arguments.length?(this._reconnection=!!e,e||(this.skipReconnect=!0),this):this._reconnection}reconnectionAttempts(e){return e===void 0?this._reconnectionAttempts:(this._reconnectionAttempts=e,this)}reconnectionDelay(e){var t;return e===void 0?this._reconnectionDelay:(this._reconnectionDelay=e,(t=this.backoff)===null||t===void 0||t.setMin(e),this)}randomizationFactor(e){var t;return e===void 0?this._randomizationFactor:(this._randomizationFactor=e,(t=this.backoff)===null||t===void 0||t.setJitter(e),this)}reconnectionDelayMax(e){var t;return e===void 0?this._reconnectionDelayMax:(this._reconnectionDelayMax=e,(t=this.backoff)===null||t===void 0||t.setMax(e),this)}timeout(e){return arguments.length?(this._timeout=e,this):this._timeout}maybeReconnectOnOpen(){!this._reconnecting&&this._reconnection&&this.backoff.attempts===0&&this.reconnect()}open(e){if(~this._readyState.indexOf("open"))return this;this.engine=new T(this.uri,this.opts);let t=this.engine,s=this;this._readyState="opening",this.skipReconnect=!1;let i=l(t,"open",function(){s.onopen(),e&&e()}),n=c=>{this.cleanup(),this._readyState="closed",this.emitReserved("error",c),e?e(c):this.maybeReconnectOnOpen()},o=l(t,"error",n);if(this._timeout!==!1){let c=this._timeout,a=this.setTimeoutFn(()=>{i(),n(new Error("timeout")),t.close()},c);this.opts.autoUnref&&a.unref(),this.subs.push(()=>{this.clearTimeoutFn(a)})}return this.subs.push(i),this.subs.push(o),this}connect(e){return this.open(e)}onopen(){this.cleanup(),this._readyState="open",this.emitReserved("open");let e=this.engine;this.subs.push(l(e,"ping",this.onping.bind(this)),l(e,"data",this.ondata.bind(this)),l(e,"error",this.onerror.bind(this)),l(e,"close",this.onclose.bind(this)),l(this.decoder,"decoded",this.ondecoded.bind(this)))}onping(){this.emitReserved("ping")}ondata(e){try{this.decoder.add(e)}catch(t){this.onclose("parse error",t)}}ondecoded(e){y(()=>{this.emitReserved("packet",e)},this.setTimeoutFn)}onerror(e){this.emitReserved("error",e)}socket(e,t){let s=this.nsps[e];return s?this._autoConnect&&!s.active&&s.connect():(s=new A(this,e,t),this.nsps[e]=s),s}_destroy(e){let t=Object.keys(this.nsps);for(let s of t)if(this.nsps[s].active)return;this._close()}_packet(e){let t=this.encoder.encode(e);for(let s=0;s<t.length;s++)this.engine.write(t[s],e.options)}cleanup(){this.subs.forEach(e=>e()),this.subs.length=0,this.decoder.destroy()}_close(){this.skipReconnect=!0,this._reconnecting=!1,this.onclose("forced close")}disconnect(){return this._close()}onclose(e,t){var s;this.cleanup(),(s=this.engine)===null||s===void 0||s.close(),this.backoff.reset(),this._readyState="closed",this.emitReserved("close",e,t),this._reconnection&&!this.skipReconnect&&this.reconnect()}reconnect(){if(this._reconnecting||this.skipReconnect)return this;let e=this;if(this.backoff.attempts>=this._reconnectionAttempts)this.backoff.reset(),this.emitReserved("reconnect_failed"),this._reconnecting=!1;else{let t=this.backoff.duration();this._reconnecting=!0;let s=this.setTimeoutFn(()=>{e.skipReconnect||(this.emitReserved("reconnect_attempt",e.backoff.attempts),!e.skipReconnect&&e.open(i=>{i?(e._reconnecting=!1,e.reconnect(),this.emitReserved("reconnect_error",i)):e.onreconnect()}))},t);this.opts.autoUnref&&s.unref(),this.subs.push(()=>{this.clearTimeoutFn(s)})}}onreconnect(){let e=this.backoff.attempts;this._reconnecting=!1,this.backoff.reset(),this.emitReserved("reconnect",e)}};var F={};function I(r,e){typeof r=="object"&&(e=r,r=void 0),e=e||{};let t=Fe(r,e.path||"/socket.io"),s=t.source,i=t.id,n=t.path,o=F[i]&&n in F[i].nsps,c=e.forceNew||e["force new connection"]||e.multiplex===!1||o,a;return c?a=new R(s,e):(F[i]||(F[i]=new R(s,e)),a=F[i]),t.query&&!e.query&&(e.query=t.queryKey),a.socket(t.path,e)}Object.assign(I,{Manager:R,Socket:A,io:I,connect:I});var cr=(()=>{class r{$auth=ue(pe);namespaceConnectionCache={};connectToNamespace(t){if(this.namespaceConnectionCache[t]){let s=this.namespaceConnectionCache[t];return s.connected=new X,s.socket.connected&&s.connected.next(void 0),s.socket.on("connect",()=>{s.connected.next(void 0)}),s.end=()=>{s.socket.emit("end"),s.socket.removeAllListeners(),s.connected.complete()},this.namespaceConnectionCache[t]}else{let s=this.establishConnectionToNamespace(t);return s.connected=new X,s.socket.on("connect",()=>{s.connected.next(void 0)}),s.end=()=>{s.socket.emit("end"),s.socket.removeAllListeners(),s.connected.complete()},this.namespaceConnectionCache[t]=s,s}}getExistingNamespace(t){return this.namespaceConnectionCache[t]}establishConnectionToNamespace(t){let s=I(`${le.api.socket}/${t}`,{query:{token:this.$auth.token}});return{socket:s,request:(n,o)=>new he(c=>{s.emit(n,o,a=>{typeof a=="object"&&a.error?c.error(a):c.next(a),c.complete()})})}}static \u0275fac=function(s){return new(s||r)};static \u0275prov=fe({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();export{cr as a};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{b as me,c as _e}from"./chunk-M5U3WH6U.js";import"./chunk-FXM34P2Q.js";import{a as le}from"./chunk-FARCNAHH.js";import{a as ue}from"./chunk-QRWK7JO5.js";import{a as ge}from"./chunk-4O7BLLBH.js";import"./chunk-63DEF4BP.js";import{a as ce,b as de,c as pe}from"./chunk-3SLVSNU6.js";import{m as D,n as re,t as se}from"./chunk-LT4LVLTJ.js";import"./chunk-DGBI427A.js";import{a as J}from"./chunk-JLNKCN3A.js";import{b as Y}from"./chunk-CR6W3PUA.js";import{C as ae,c as Z,e as ee,f as te,i as ie,l as ne,m as oe}from"./chunk-N2IMTG2V.js";import{b as X}from"./chunk-PXNJ4PSF.js";import{E as K,F as S,K as Q}from"./chunk-YZZ7SAON.js";import{Ab as y,Cb as W,Db as I,Eb as $,Ec as s,Fb as f,Fc as l,Gb as a,Gc as U,Hb as r,Ib as p,Jb as V,Kb as O,Lb as R,Rb as k,Ua as H,Xb as g,Za as n,Zb as d,aa as b,ga as C,ha as x,ic as F,jc as j,kc as c,lc as m,mc as w,nb as M,rc as A,sa as B,sc as T,tc as E,xc as z,yb as v,yc as q,zb as h,zc as G}from"./chunk-ZPXACREZ.js";import{h as L}from"./chunk-B4AJQJMI.js";var be=(()=>{class t{$activeModal=b(D);dismissModal(){this.$activeModal.dismiss("Dismiss")}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=M({type:t,selectors:[["ng-component"]],decls:42,vars:30,consts:[[1,"modal-content"],[1,"modal-header"],[1,"modal-title"],["type","button","data-bs-dismiss","modal",1,"btn-close",3,"click"],[1,"modal-body"],[1,"text-center","mb-3"],[1,"fa","fa-question-circle-o","primary-text",2,"font-size","75px"],[1,"ms-2"],[1,"mb-0"],[1,"ms-2","mt-2"],[1,"modal-footer","justify-content-between"],[1,"text-start"],[1,"text-center"],["type","button","data-bs-dismiss","modal",1,"btn","btn-elegant",3,"click"],[1,"text-end"]],template:function(i,o){i&1&&(a(0,"div",0)(1,"form")(2,"div",1)(3,"h5",2),c(4),s(5,"translate"),r(),a(6,"button",3),s(7,"translate"),g("click",function(){return o.dismissModal()}),r()(),a(8,"div",4)(9,"div",5),p(10,"i",6),r(),a(11,"h5",7),c(12),s(13,"translate"),r(),a(14,"ul",8)(15,"li"),c(16),s(17,"translate"),r(),a(18,"li"),c(19),s(20,"translate"),r()(),a(21,"h5",9),c(22),s(23,"translate"),r(),a(24,"ul",8)(25,"li"),c(26),s(27,"translate"),r(),a(28,"li"),c(29),s(30,"translate"),r(),a(31,"li"),c(32),s(33,"translate"),r()(),p(34,"app-support-banner"),r(),a(35,"div",10),p(36,"div",11),a(37,"div",12)(38,"button",13),g("click",function(){return o.dismissModal()}),c(39),s(40,"translate"),r()(),p(41,"div",14),r()()()),i&2&&(n(4),m(l(5,10,"support.title")),n(2),v("aria-label",l(7,12,"form.button_close")),n(6),m(l(13,14,"menu.label_accessories")),n(4),m(l(17,16,"accessories.support.acc_1")),n(3),m(l(20,18,"accessories.support.acc_2")),n(3),m(l(23,20,"accessories.title_rooms")),n(4),m(l(27,22,"accessories.support.rooms_1")),n(3),m(l(30,24,"accessories.support.rooms_2")),n(3),m(l(33,26,"accessories.support.rooms_3")),n(7),w(" ",l(40,28,"form.button_close")," "))},dependencies:[ge,S],encapsulation:2})}return t})();var Ce=()=>({standalone:!0}),fe=(()=>{class t{$activeModal=b(D);roomName="";dismissModal(){this.$activeModal.dismiss("Dismiss")}closeModal(e){this.$activeModal.close(e)}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=M({type:t,selectors:[["ng-component"]],decls:28,vars:19,consts:[[1,"modal-content"],[1,"modal-header"],[1,"modal-title"],["type","button","data-bs-dismiss","modal",1,"btn-close",3,"click"],[1,"modal-body"],[1,"text-center","mb-3"],[1,"fas","fa-folder-plus","primary-text",2,"font-size","75px"],[1,"list-group","list-group-box","mb-0"],[1,"list-group-item","d-flex","flex-column","flex-md-row","align-items-center"],["for","form-name",1,"mb-2","mb-md-0","w-100","w-md-50"],[1,"text-start","text-md-end","w-100","w-md-50"],["autocomplete","off","type","text","id","form-name","autofocus","",1,"form-control","custom-input",3,"ngModelChange","keyup.enter","ngModel","ngModelOptions"],[1,"modal-footer","justify-content-between"],[1,"text-start"],["type","button","data-bs-dismiss","modal",1,"btn","btn-elegant",3,"click"],[1,"text-center"],[1,"text-end"],["type","button","data-bs-dismiss","modal",1,"btn","btn-primary",3,"click","disabled"]],template:function(i,o){i&1&&(a(0,"div",0)(1,"form")(2,"div",1)(3,"h5",2),c(4),s(5,"translate"),r(),a(6,"button",3),s(7,"translate"),g("click",function(){return o.dismissModal()}),r()(),a(8,"div",4)(9,"div",5),p(10,"i",6),r(),a(11,"ul",7)(12,"li",8)(13,"label",9),c(14),s(15,"translate"),r(),a(16,"div",10)(17,"input",11),E("ngModelChange",function(P){return T(o.roomName,P)||(o.roomName=P),P}),g("keyup.enter",function(){return o.closeModal(o.roomName)}),r()()()()(),a(18,"div",12)(19,"div",13)(20,"button",14),g("click",function(){return o.dismissModal()}),c(21),s(22,"translate"),r()(),p(23,"div",15),a(24,"div",16)(25,"button",17),g("click",function(){return o.closeModal(o.roomName)}),c(26),s(27,"translate"),r()()()()()),i&2&&(n(4),m(l(5,8,"accessories.button_add_room")),n(2),v("aria-label",l(7,10,"form.button_close")),n(8),m(l(15,12,"accessories.room_name")),n(3),A("ngModel",o.roomName),f("ngModelOptions",z(18,Ce)),n(4),w(" ",l(22,14,"form.button_close")," "),n(4),f("disabled",!o.roomName),n(),w(" ",l(27,16,"form.button_save")," "))},dependencies:[ae,oe,Z,ee,te,ne,ie,S],encapsulation:2})}return t})();var ve=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275cmp=M({type:t,selectors:[["app-drag-here-placeholder"]],decls:5,vars:3,consts:[[1,"accessory-box"],[1,"fas","fa-arrow-alt-circle-down","accessory-icon"],[1,"accessory-label"]],template:function(i,o){i&1&&(V(0,"div",0),R(1,"i",1),V(2,"div",2),c(3),s(4,"translate"),O()()),i&2&&(n(3),m(l(4,1,"accessories.control.drag_here")))},dependencies:[S],styles:[".accessory-box[_ngcontent-%COMP%]{opacity:.2}"]})}return t})();var xe=(t,u)=>({"fa-eye":t,"fa-eye-slash":u}),he=t=>({link:t}),ye=(t,u)=>u.name;function Me(t,u){if(t&1){let e=k();a(0,"button",8),s(1,"translate"),s(2,"translate"),g("click",function(){C(e);let o=d(2);return x(o.addRoom())}),p(3,"i",9),r(),a(4,"button",8),s(5,"translate"),s(6,"translate"),s(7,"translate"),s(8,"translate"),g("click",function(){C(e);let o=d(2);return x(o.hideHidden.set(!o.hideHidden()()))}),p(9,"i",10),r(),a(10,"div",11)(11,"button",12),s(12,"translate"),s(13,"translate"),g("click",function(){C(e);let o=d(2);return x(o.toggleLayoutLock())}),p(14,"i",13),r(),a(15,"button",12),s(16,"translate"),s(17,"translate"),g("click",function(){C(e);let o=d(2);return x(o.toggleLayoutLock())}),p(18,"i",14),r()()}if(t&2){let e=d(2);f("hidden",e.isMobile())("openDelay",150)("ngbTooltip",l(1,18,"accessories.button_add_room")),v("aria-label",l(2,20,"accessories.button_add_room")),n(4),f("hidden",e.isMobile())("openDelay",150)("ngbTooltip",e.hideHidden()?l(5,22,"accessories.button_hidden_show"):l(6,24,"accessories.button_hidden_hide")),v("aria-label",e.hideHidden()?l(7,26,"accessories.button_hidden_show"):l(8,28,"accessories.button_hidden_hide")),n(5),j(G(38,xe,!e.hideHidden(),e.hideHidden)),n(2),f("disabled",!e.isMobile())("openDelay",150)("ngbTooltip",l(12,30,"form.button_unlock")),v("aria-label",l(13,32,"form.button_unlock")),n(4),f("disabled",e.isMobile())("openDelay",150)("ngbTooltip",l(16,34,"form.button_lock")),v("aria-label",l(17,36,"form.button_lock"))}}function Se(t,u){t&1&&p(0,"app-spinner")}function we(t,u){if(t&1&&(a(0,"div",0)(1,"div",21)(2,"h5",22),c(3),s(4,"translate"),r()()()),t&2){let e=d().$implicit,i=d(4);n(2),F("cursor-move",!i.isMobile()),n(),w(" ",e.name==="Default Room"?l(4,3,"accessories.control.default_room"):e.name," ")}}function ke(t,u){if(t&1&&(a(0,"div",25),p(1,"app-accessory-tile",26),r()),t&2){let e=d().$implicit;n(),f("service",e)}}function Ae(t,u){if(t&1&&h(0,ke,2,1,"div",25),t&2){let e=u.$implicit,i=d(6);y(!i.hideHidden()||!e.hidden?0:-1)}}function Te(t,u){if(t&1){let e=k();a(0,"div",23),E("dragulaModelChange",function(o){C(e);let _=d().$implicit;return T(_.services,o)||(_.services=o),x(o)}),I(1,Ae,1,1,null,null,W),p(3,"div",24)(4,"div",24)(5,"div",24)(6,"div",24)(7,"div",24)(8,"div",24)(9,"div",24)(10,"div",24)(11,"div",24)(12,"div",24),r()}if(t&2){let e=d().$implicit,i=d(4);F("justify-content-between",i.isMobile()),f("dragula","services-bag"),A("dragulaModel",e.services),n(),$(e.services)}}function Ee(t,u){if(t&1){let e=k();a(0,"div",27),E("dragulaModelChange",function(o){C(e);let _=d().$implicit;return T(_.services,o)||(_.services=o),x(o)}),p(1,"app-drag-here-placeholder",28),r()}if(t&2){let e=d().$implicit;f("dragula","services-bag"),A("dragulaModel",e.services)}}function Be(t,u){if(t&1&&(a(0,"div"),h(1,we,5,5,"div",0),a(2,"div",18),h(3,Te,13,4,"div",19),h(4,Ee,2,2,"div",20),r()()),t&2){let e=u.$implicit,i=d(4);n(),y(!i.isMobile()||e.services.length?1:-1),n(2),y(e.services.length?3:-1),n(),y(!e.services.length&&!i.isMobile?4:-1)}}function De(t,u){if(t&1){let e=k();a(0,"div",17),E("dragulaModelChange",function(o){C(e);let _=d(3);return T(_.rooms,o)||(_.rooms=o),x(o)}),I(1,Be,5,3,"div",null,ye),r()}if(t&2){let e=d(3);f("dragula","rooms-bag"),A("dragulaModel",e.rooms),n(),$(e.rooms)}}function Pe(t,u){t&1&&(a(0,"div",16)(1,"div",29)(2,"div",30),p(3,"i",31),r(),a(4,"h5",32),c(5),s(6,"translate"),r(),a(7,"p",33),c(8),s(9,"translate"),r(),a(10,"p",34),c(11),s(12,"translate"),r()()()),t&2&&(n(5),m(l(6,3,"accessories.no_plugins.title")),n(3),m(l(9,5,"accessories.no_plugins.message_1")),n(3),m(l(12,7,"accessories.no_plugins.message_2")))}function Ie(t,u){if(t&1&&h(0,De,3,2,"div",15)(1,Pe,13,9,"div",16),t&2){let e=d(2);y(e.hasPlugins()?0:1)}}function $e(t,u){if(t&1){let e=k();a(0,"div",1)(1,"div",2)(2,"h3",3),c(3),s(4,"translate"),r()(),a(5,"div",4)(6,"button",5),s(7,"translate"),g("click",function(){C(e);let o=d();return x(o.openSupport())}),p(8,"i",6),r()(),a(9,"div",7),h(10,Me,19,41),a(11,"button",5),s(12,"translate"),g("click",function(){C(e);let o=d();return x(o.openSupport())}),p(13,"i",6),r()()(),h(14,Se,1,0,"app-spinner")(15,Ie,2,1)}if(t&2){let e=d();n(3),m(l(4,5,"menu.label_accessories")),n(3),v("aria-label",l(7,7,"support.title")),n(4),y(e.hasPlugins()?10:-1),n(),v("aria-label",l(12,9,"support.title")),n(3),y(e.loading()?14:15)}}function Ve(t,u){t&1&&(a(0,"p",40),c(1),s(2,"translate"),r()),t&2&&(n(),m(l(2,1,"accessories.settings_link")))}function Fe(t,u){if(t&1&&(a(0,"div",0)(1,"div",35)(2,"h3",36),c(3),s(4,"translate"),r()(),a(5,"div",16)(6,"div",37)(7,"div",30),p(8,"i",38),r(),a(9,"h5",32),c(10),s(11,"translate"),r(),p(12,"p",39),s(13,"translate"),h(14,Ve,3,3,"p",40),r()()()),t&2){let e=d();n(3),m(l(4,4,"menu.label_accessories")),n(7),m(l(11,6,"accessories.control_disabled")),n(2),f("innerHTML",U(13,8,"accessories.message_must_use_insecure_mode",q(11,he,e.linkInsecure)),H),n(2),y(e.isAdmin?14:-1)}}var gt=(()=>{class t{$accessories=b(me);$api=b(Q);$auth=b(Y);dragulaService=b(ce);$modal=b(re);$settings=b(X);$md=b(ue);$translate=b(K);isAdmin=this.$auth.user.admin;enableAccessories=this.$settings.env.enableAccessories;isMobile=B(!1,{});hideHidden=B(!0,{});linkInsecure='<a href="https://github.com/homebridge/homebridge-config-ui-x/wiki/Enabling-Accessory-Control" target="_blank"><i class="fa fa-external-link-alt primary-text"></i></a>';hasPlugins=B(!1,{});loading=B(!0,{});get rooms(){return this.$accessories.rooms()}set rooms(e){this.$accessories.rooms.set(e)}constructor(){let e=this.dragulaService;this.isMobile.set(this.$md.detect.mobile()),e.createGroup("rooms-bag",{moves:(i,o,_)=>!this.isMobile()&&_.classList.contains("drag-handle")}),e.createGroup("services-bag",{moves:i=>!this.isMobile()&&!i.classList.contains("no-drag")}),e.drop().pipe(J()).subscribe(()=>{setTimeout(()=>{this.$accessories.saveLayout()})}),this.isMobile.set(!0)}ngOnInit(){let e=this.$translate.instant("menu.label_accessories");this.$settings.setPageTitle(e),this.$accessories.start(),this.checkForPlugins()}addRoom(){this.$modal.open(fe,{size:"lg",backdrop:"static"}).result.then(e=>{!e||!e.length||this.$accessories.rooms().find(i=>i.name===e)||(this.$accessories.rooms.update(i=>[...i,{name:e,services:[]}]),this.isMobile()&&this.toggleLayoutLock())}).catch(()=>{})}toggleLayoutLock(){this.isMobile.set(!this.isMobile()),this.isMobile()?document.querySelectorAll(".services-bag").forEach(i=>{for(let o=0;o<10;o+=1){let _=document.createElement("div");_.className="accessory-box invisible py-0 my-0",_.style.height="0",i.appendChild(_)}}):document.querySelectorAll(".invisible").forEach(i=>i.remove())}openSupport(){this.$modal.open(be,{size:"lg",backdrop:"static"})}ngOnDestroy(){this.$accessories.stop(),this.dragulaService.destroy("rooms-bag"),this.dragulaService.destroy("services-bag")}checkForPlugins(){return L(this,null,function*(){try{let e=yield this.$api.get("/plugins");this.hasPlugins.set(e.length>1)}catch(e){console.error(e),this.hasPlugins.set(!0)}finally{this.loading.set(!1)}})}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=M({type:t,selectors:[["app-accessories"]],decls:2,vars:1,consts:[[1,"row"],[1,"row","mb-3"],[1,"col-9","col-sm-6"],[1,"primary-text","m-0"],[1,"col-3","col-sm-6","text-end","d-inline-block","d-sm-none"],["type","button",1,"btn","btn-elegant","my-0","me-0",3,"click"],[1,"fa","fa-question-circle-o"],[1,"col-3","col-sm-6","text-end","d-none","d-sm-inline-block"],["type","button","container","body","placement","bottom","triggers","hover",1,"btn","btn-elegant","my-0","me-2",3,"click","hidden","openDelay","ngbTooltip"],[1,"fas","fa-folder-plus"],[1,"fas"],["role","group",1,"btn-group","me-2"],["type","button","container","body","placement","bottom","triggers","hover",1,"btn","btn-elegant","my-0",3,"click","disabled","openDelay","ngbTooltip"],[1,"fas","fa-unlock"],[1,"fas","fa-lock"],[3,"dragula","dragulaModel"],[1,"col-12","text-center"],[3,"dragulaModelChange","dragula","dragulaModel"],[1,"row","mb-4"],[1,"col-md-12","d-flex","flex-wrap","noselect","services-bag",3,"justify-content-between","dragula","dragulaModel"],[1,"col-md-12","d-flex","flex-wrap","noselect",3,"dragula","dragulaModel"],[1,"col-md-12"],[1,"primary-text","drag-handle","room-title","m-0","mb-1","mb-sm-0"],[1,"col-md-12","d-flex","flex-wrap","noselect","services-bag",3,"dragulaModelChange","dragula","dragulaModel"],[1,"accessory-box","invisible","py-0","my-0",2,"height","0"],[1,"accessory-item","accessory-tab"],[3,"service"],[1,"col-md-12","d-flex","flex-wrap","noselect",3,"dragulaModelChange","dragula","dragulaModel"],[1,"no-drag"],["role","alert",1,"alert","alert-warning","p-5"],[1,"text-center","mb-3"],[1,"fas","fa-plug","primary-text",2,"font-size","75px"],[1,"mb-3","mt-0"],[1,"mb-0","small"],[1,"mb-0","small","mt-2"],[1,"col-12"],[1,"primary-text","m-0","mb-3"],["role","alert",1,"alert","alert-warning","p-4"],[1,"fas","fa-lightbulb","primary-text",2,"font-size","75px"],[1,"mb-0","small",3,"innerHTML"],[1,"mt-2","mb-0","small"]],template:function(i,o){i&1&&h(0,$e,16,11)(1,Fe,15,13,"div",0),i&2&&y(o.enableAccessories?0:1)},dependencies:[se,pe,de,_e,ve,le,S],styles:[".room-title[_ngcontent-%COMP%]{margin-left:10px}@media(max-width:575px){.room-title[_ngcontent-%COMP%]{margin-left:7px}}.services-bag[_ngcontent-%COMP%]{min-height:170px}@media(max-width:575px){.services-bag[_ngcontent-%COMP%]{min-height:initial}}.cursor-move[_ngcontent-%COMP%]{cursor:move}a[_ngcontent-%COMP%]:hover{text-decoration:none!important}"]})}return t})();export{gt as AccessoriesComponent};
|
|
1
|
+
import{b as me,c as _e}from"./chunk-AM2AGROH.js";import"./chunk-6G6325AZ.js";import{a as le}from"./chunk-FARCNAHH.js";import{a as ue}from"./chunk-QRWK7JO5.js";import{a as ge}from"./chunk-OWEBBEZA.js";import"./chunk-74KAKFTX.js";import{a as ce,b as de,c as pe}from"./chunk-3SLVSNU6.js";import{m as D,n as re,t as se}from"./chunk-GAI5J4YQ.js";import"./chunk-ZAKTSIL5.js";import{a as J}from"./chunk-JLNKCN3A.js";import{b as Y}from"./chunk-KTLG6VZT.js";import{C as ae,c as Z,e as ee,f as te,i as ie,l as ne,m as oe}from"./chunk-O6MJC7P2.js";import{b as X}from"./chunk-CAB2VD3D.js";import{E as K,F as S,K as Q}from"./chunk-MW6H5Z5G.js";import{Ab as y,Cb as W,Db as I,Eb as $,Ec as s,Fb as f,Fc as l,Gb as a,Gc as U,Hb as r,Ib as p,Jb as V,Kb as O,Lb as R,Rb as k,Ua as H,Xb as g,Za as n,Zb as d,aa as b,ga as C,ha as x,ic as F,jc as j,kc as c,lc as m,mc as w,nb as M,rc as A,sa as B,sc as T,tc as E,xc as z,yb as v,yc as q,zb as h,zc as G}from"./chunk-ZPXACREZ.js";import{h as L}from"./chunk-B4AJQJMI.js";var be=(()=>{class t{$activeModal=b(D);dismissModal(){this.$activeModal.dismiss("Dismiss")}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=M({type:t,selectors:[["ng-component"]],decls:42,vars:30,consts:[[1,"modal-content"],[1,"modal-header"],[1,"modal-title"],["type","button","data-bs-dismiss","modal",1,"btn-close",3,"click"],[1,"modal-body"],[1,"text-center","mb-3"],[1,"fa","fa-question-circle-o","primary-text",2,"font-size","75px"],[1,"ms-2"],[1,"mb-0"],[1,"ms-2","mt-2"],[1,"modal-footer","justify-content-between"],[1,"text-start"],[1,"text-center"],["type","button","data-bs-dismiss","modal",1,"btn","btn-elegant",3,"click"],[1,"text-end"]],template:function(i,o){i&1&&(a(0,"div",0)(1,"form")(2,"div",1)(3,"h5",2),c(4),s(5,"translate"),r(),a(6,"button",3),s(7,"translate"),g("click",function(){return o.dismissModal()}),r()(),a(8,"div",4)(9,"div",5),p(10,"i",6),r(),a(11,"h5",7),c(12),s(13,"translate"),r(),a(14,"ul",8)(15,"li"),c(16),s(17,"translate"),r(),a(18,"li"),c(19),s(20,"translate"),r()(),a(21,"h5",9),c(22),s(23,"translate"),r(),a(24,"ul",8)(25,"li"),c(26),s(27,"translate"),r(),a(28,"li"),c(29),s(30,"translate"),r(),a(31,"li"),c(32),s(33,"translate"),r()(),p(34,"app-support-banner"),r(),a(35,"div",10),p(36,"div",11),a(37,"div",12)(38,"button",13),g("click",function(){return o.dismissModal()}),c(39),s(40,"translate"),r()(),p(41,"div",14),r()()()),i&2&&(n(4),m(l(5,10,"support.title")),n(2),v("aria-label",l(7,12,"form.button_close")),n(6),m(l(13,14,"menu.label_accessories")),n(4),m(l(17,16,"accessories.support.acc_1")),n(3),m(l(20,18,"accessories.support.acc_2")),n(3),m(l(23,20,"accessories.title_rooms")),n(4),m(l(27,22,"accessories.support.rooms_1")),n(3),m(l(30,24,"accessories.support.rooms_2")),n(3),m(l(33,26,"accessories.support.rooms_3")),n(7),w(" ",l(40,28,"form.button_close")," "))},dependencies:[ge,S],encapsulation:2})}return t})();var Ce=()=>({standalone:!0}),fe=(()=>{class t{$activeModal=b(D);roomName="";dismissModal(){this.$activeModal.dismiss("Dismiss")}closeModal(e){this.$activeModal.close(e)}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=M({type:t,selectors:[["ng-component"]],decls:28,vars:19,consts:[[1,"modal-content"],[1,"modal-header"],[1,"modal-title"],["type","button","data-bs-dismiss","modal",1,"btn-close",3,"click"],[1,"modal-body"],[1,"text-center","mb-3"],[1,"fas","fa-folder-plus","primary-text",2,"font-size","75px"],[1,"list-group","list-group-box","mb-0"],[1,"list-group-item","d-flex","flex-column","flex-md-row","align-items-center"],["for","form-name",1,"mb-2","mb-md-0","w-100","w-md-50"],[1,"text-start","text-md-end","w-100","w-md-50"],["autocomplete","off","type","text","id","form-name","autofocus","",1,"form-control","custom-input",3,"ngModelChange","keyup.enter","ngModel","ngModelOptions"],[1,"modal-footer","justify-content-between"],[1,"text-start"],["type","button","data-bs-dismiss","modal",1,"btn","btn-elegant",3,"click"],[1,"text-center"],[1,"text-end"],["type","button","data-bs-dismiss","modal",1,"btn","btn-primary",3,"click","disabled"]],template:function(i,o){i&1&&(a(0,"div",0)(1,"form")(2,"div",1)(3,"h5",2),c(4),s(5,"translate"),r(),a(6,"button",3),s(7,"translate"),g("click",function(){return o.dismissModal()}),r()(),a(8,"div",4)(9,"div",5),p(10,"i",6),r(),a(11,"ul",7)(12,"li",8)(13,"label",9),c(14),s(15,"translate"),r(),a(16,"div",10)(17,"input",11),E("ngModelChange",function(P){return T(o.roomName,P)||(o.roomName=P),P}),g("keyup.enter",function(){return o.closeModal(o.roomName)}),r()()()()(),a(18,"div",12)(19,"div",13)(20,"button",14),g("click",function(){return o.dismissModal()}),c(21),s(22,"translate"),r()(),p(23,"div",15),a(24,"div",16)(25,"button",17),g("click",function(){return o.closeModal(o.roomName)}),c(26),s(27,"translate"),r()()()()()),i&2&&(n(4),m(l(5,8,"accessories.button_add_room")),n(2),v("aria-label",l(7,10,"form.button_close")),n(8),m(l(15,12,"accessories.room_name")),n(3),A("ngModel",o.roomName),f("ngModelOptions",z(18,Ce)),n(4),w(" ",l(22,14,"form.button_close")," "),n(4),f("disabled",!o.roomName),n(),w(" ",l(27,16,"form.button_save")," "))},dependencies:[ae,oe,Z,ee,te,ne,ie,S],encapsulation:2})}return t})();var ve=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275cmp=M({type:t,selectors:[["app-drag-here-placeholder"]],decls:5,vars:3,consts:[[1,"accessory-box"],[1,"fas","fa-arrow-alt-circle-down","accessory-icon"],[1,"accessory-label"]],template:function(i,o){i&1&&(V(0,"div",0),R(1,"i",1),V(2,"div",2),c(3),s(4,"translate"),O()()),i&2&&(n(3),m(l(4,1,"accessories.control.drag_here")))},dependencies:[S],styles:[".accessory-box[_ngcontent-%COMP%]{opacity:.2}"]})}return t})();var xe=(t,u)=>({"fa-eye":t,"fa-eye-slash":u}),he=t=>({link:t}),ye=(t,u)=>u.name;function Me(t,u){if(t&1){let e=k();a(0,"button",8),s(1,"translate"),s(2,"translate"),g("click",function(){C(e);let o=d(2);return x(o.addRoom())}),p(3,"i",9),r(),a(4,"button",8),s(5,"translate"),s(6,"translate"),s(7,"translate"),s(8,"translate"),g("click",function(){C(e);let o=d(2);return x(o.hideHidden.set(!o.hideHidden()()))}),p(9,"i",10),r(),a(10,"div",11)(11,"button",12),s(12,"translate"),s(13,"translate"),g("click",function(){C(e);let o=d(2);return x(o.toggleLayoutLock())}),p(14,"i",13),r(),a(15,"button",12),s(16,"translate"),s(17,"translate"),g("click",function(){C(e);let o=d(2);return x(o.toggleLayoutLock())}),p(18,"i",14),r()()}if(t&2){let e=d(2);f("hidden",e.isMobile())("openDelay",150)("ngbTooltip",l(1,18,"accessories.button_add_room")),v("aria-label",l(2,20,"accessories.button_add_room")),n(4),f("hidden",e.isMobile())("openDelay",150)("ngbTooltip",e.hideHidden()?l(5,22,"accessories.button_hidden_show"):l(6,24,"accessories.button_hidden_hide")),v("aria-label",e.hideHidden()?l(7,26,"accessories.button_hidden_show"):l(8,28,"accessories.button_hidden_hide")),n(5),j(G(38,xe,!e.hideHidden(),e.hideHidden)),n(2),f("disabled",!e.isMobile())("openDelay",150)("ngbTooltip",l(12,30,"form.button_unlock")),v("aria-label",l(13,32,"form.button_unlock")),n(4),f("disabled",e.isMobile())("openDelay",150)("ngbTooltip",l(16,34,"form.button_lock")),v("aria-label",l(17,36,"form.button_lock"))}}function Se(t,u){t&1&&p(0,"app-spinner")}function we(t,u){if(t&1&&(a(0,"div",0)(1,"div",21)(2,"h5",22),c(3),s(4,"translate"),r()()()),t&2){let e=d().$implicit,i=d(4);n(2),F("cursor-move",!i.isMobile()),n(),w(" ",e.name==="Default Room"?l(4,3,"accessories.control.default_room"):e.name," ")}}function ke(t,u){if(t&1&&(a(0,"div",25),p(1,"app-accessory-tile",26),r()),t&2){let e=d().$implicit;n(),f("service",e)}}function Ae(t,u){if(t&1&&h(0,ke,2,1,"div",25),t&2){let e=u.$implicit,i=d(6);y(!i.hideHidden()||!e.hidden?0:-1)}}function Te(t,u){if(t&1){let e=k();a(0,"div",23),E("dragulaModelChange",function(o){C(e);let _=d().$implicit;return T(_.services,o)||(_.services=o),x(o)}),I(1,Ae,1,1,null,null,W),p(3,"div",24)(4,"div",24)(5,"div",24)(6,"div",24)(7,"div",24)(8,"div",24)(9,"div",24)(10,"div",24)(11,"div",24)(12,"div",24),r()}if(t&2){let e=d().$implicit,i=d(4);F("justify-content-between",i.isMobile()),f("dragula","services-bag"),A("dragulaModel",e.services),n(),$(e.services)}}function Ee(t,u){if(t&1){let e=k();a(0,"div",27),E("dragulaModelChange",function(o){C(e);let _=d().$implicit;return T(_.services,o)||(_.services=o),x(o)}),p(1,"app-drag-here-placeholder",28),r()}if(t&2){let e=d().$implicit;f("dragula","services-bag"),A("dragulaModel",e.services)}}function Be(t,u){if(t&1&&(a(0,"div"),h(1,we,5,5,"div",0),a(2,"div",18),h(3,Te,13,4,"div",19),h(4,Ee,2,2,"div",20),r()()),t&2){let e=u.$implicit,i=d(4);n(),y(!i.isMobile()||e.services.length?1:-1),n(2),y(e.services.length?3:-1),n(),y(!e.services.length&&!i.isMobile?4:-1)}}function De(t,u){if(t&1){let e=k();a(0,"div",17),E("dragulaModelChange",function(o){C(e);let _=d(3);return T(_.rooms,o)||(_.rooms=o),x(o)}),I(1,Be,5,3,"div",null,ye),r()}if(t&2){let e=d(3);f("dragula","rooms-bag"),A("dragulaModel",e.rooms),n(),$(e.rooms)}}function Pe(t,u){t&1&&(a(0,"div",16)(1,"div",29)(2,"div",30),p(3,"i",31),r(),a(4,"h5",32),c(5),s(6,"translate"),r(),a(7,"p",33),c(8),s(9,"translate"),r(),a(10,"p",34),c(11),s(12,"translate"),r()()()),t&2&&(n(5),m(l(6,3,"accessories.no_plugins.title")),n(3),m(l(9,5,"accessories.no_plugins.message_1")),n(3),m(l(12,7,"accessories.no_plugins.message_2")))}function Ie(t,u){if(t&1&&h(0,De,3,2,"div",15)(1,Pe,13,9,"div",16),t&2){let e=d(2);y(e.hasPlugins()?0:1)}}function $e(t,u){if(t&1){let e=k();a(0,"div",1)(1,"div",2)(2,"h3",3),c(3),s(4,"translate"),r()(),a(5,"div",4)(6,"button",5),s(7,"translate"),g("click",function(){C(e);let o=d();return x(o.openSupport())}),p(8,"i",6),r()(),a(9,"div",7),h(10,Me,19,41),a(11,"button",5),s(12,"translate"),g("click",function(){C(e);let o=d();return x(o.openSupport())}),p(13,"i",6),r()()(),h(14,Se,1,0,"app-spinner")(15,Ie,2,1)}if(t&2){let e=d();n(3),m(l(4,5,"menu.label_accessories")),n(3),v("aria-label",l(7,7,"support.title")),n(4),y(e.hasPlugins()?10:-1),n(),v("aria-label",l(12,9,"support.title")),n(3),y(e.loading()?14:15)}}function Ve(t,u){t&1&&(a(0,"p",40),c(1),s(2,"translate"),r()),t&2&&(n(),m(l(2,1,"accessories.settings_link")))}function Fe(t,u){if(t&1&&(a(0,"div",0)(1,"div",35)(2,"h3",36),c(3),s(4,"translate"),r()(),a(5,"div",16)(6,"div",37)(7,"div",30),p(8,"i",38),r(),a(9,"h5",32),c(10),s(11,"translate"),r(),p(12,"p",39),s(13,"translate"),h(14,Ve,3,3,"p",40),r()()()),t&2){let e=d();n(3),m(l(4,4,"menu.label_accessories")),n(7),m(l(11,6,"accessories.control_disabled")),n(2),f("innerHTML",U(13,8,"accessories.message_must_use_insecure_mode",q(11,he,e.linkInsecure)),H),n(2),y(e.isAdmin?14:-1)}}var gt=(()=>{class t{$accessories=b(me);$api=b(Q);$auth=b(Y);dragulaService=b(ce);$modal=b(re);$settings=b(X);$md=b(ue);$translate=b(K);isAdmin=this.$auth.user.admin;enableAccessories=this.$settings.env.enableAccessories;isMobile=B(!1,{});hideHidden=B(!0,{});linkInsecure='<a href="https://github.com/homebridge/homebridge-config-ui-x/wiki/Enabling-Accessory-Control" target="_blank"><i class="fa fa-external-link-alt primary-text"></i></a>';hasPlugins=B(!1,{});loading=B(!0,{});get rooms(){return this.$accessories.rooms()}set rooms(e){this.$accessories.rooms.set(e)}constructor(){let e=this.dragulaService;this.isMobile.set(this.$md.detect.mobile()),e.createGroup("rooms-bag",{moves:(i,o,_)=>!this.isMobile()&&_.classList.contains("drag-handle")}),e.createGroup("services-bag",{moves:i=>!this.isMobile()&&!i.classList.contains("no-drag")}),e.drop().pipe(J()).subscribe(()=>{setTimeout(()=>{this.$accessories.saveLayout()})}),this.isMobile.set(!0)}ngOnInit(){let e=this.$translate.instant("menu.label_accessories");this.$settings.setPageTitle(e),this.$accessories.start(),this.checkForPlugins()}addRoom(){this.$modal.open(fe,{size:"lg",backdrop:"static"}).result.then(e=>{!e||!e.length||this.$accessories.rooms().find(i=>i.name===e)||(this.$accessories.rooms.update(i=>[...i,{name:e,services:[]}]),this.isMobile()&&this.toggleLayoutLock())}).catch(()=>{})}toggleLayoutLock(){this.isMobile.set(!this.isMobile()),this.isMobile()?document.querySelectorAll(".services-bag").forEach(i=>{for(let o=0;o<10;o+=1){let _=document.createElement("div");_.className="accessory-box invisible py-0 my-0",_.style.height="0",i.appendChild(_)}}):document.querySelectorAll(".invisible").forEach(i=>i.remove())}openSupport(){this.$modal.open(be,{size:"lg",backdrop:"static"})}ngOnDestroy(){this.$accessories.stop(),this.dragulaService.destroy("rooms-bag"),this.dragulaService.destroy("services-bag")}checkForPlugins(){return L(this,null,function*(){try{let e=yield this.$api.get("/plugins");this.hasPlugins.set(e.length>1)}catch(e){console.error(e),this.hasPlugins.set(!0)}finally{this.loading.set(!1)}})}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=M({type:t,selectors:[["app-accessories"]],decls:2,vars:1,consts:[[1,"row"],[1,"row","mb-3"],[1,"col-9","col-sm-6"],[1,"primary-text","m-0"],[1,"col-3","col-sm-6","text-end","d-inline-block","d-sm-none"],["type","button",1,"btn","btn-elegant","my-0","me-0",3,"click"],[1,"fa","fa-question-circle-o"],[1,"col-3","col-sm-6","text-end","d-none","d-sm-inline-block"],["type","button","container","body","placement","bottom","triggers","hover",1,"btn","btn-elegant","my-0","me-2",3,"click","hidden","openDelay","ngbTooltip"],[1,"fas","fa-folder-plus"],[1,"fas"],["role","group",1,"btn-group","me-2"],["type","button","container","body","placement","bottom","triggers","hover",1,"btn","btn-elegant","my-0",3,"click","disabled","openDelay","ngbTooltip"],[1,"fas","fa-unlock"],[1,"fas","fa-lock"],[3,"dragula","dragulaModel"],[1,"col-12","text-center"],[3,"dragulaModelChange","dragula","dragulaModel"],[1,"row","mb-4"],[1,"col-md-12","d-flex","flex-wrap","noselect","services-bag",3,"justify-content-between","dragula","dragulaModel"],[1,"col-md-12","d-flex","flex-wrap","noselect",3,"dragula","dragulaModel"],[1,"col-md-12"],[1,"primary-text","drag-handle","room-title","m-0","mb-1","mb-sm-0"],[1,"col-md-12","d-flex","flex-wrap","noselect","services-bag",3,"dragulaModelChange","dragula","dragulaModel"],[1,"accessory-box","invisible","py-0","my-0",2,"height","0"],[1,"accessory-item","accessory-tab"],[3,"service"],[1,"col-md-12","d-flex","flex-wrap","noselect",3,"dragulaModelChange","dragula","dragulaModel"],[1,"no-drag"],["role","alert",1,"alert","alert-warning","p-5"],[1,"text-center","mb-3"],[1,"fas","fa-plug","primary-text",2,"font-size","75px"],[1,"mb-3","mt-0"],[1,"mb-0","small"],[1,"mb-0","small","mt-2"],[1,"col-12"],[1,"primary-text","m-0","mb-3"],["role","alert",1,"alert","alert-warning","p-4"],[1,"fas","fa-lightbulb","primary-text",2,"font-size","75px"],[1,"mb-0","small",3,"innerHTML"],[1,"mt-2","mb-0","small"]],template:function(i,o){i&1&&h(0,$e,16,11)(1,Fe,15,13,"div",0),i&2&&y(o.enableAccessories?0:1)},dependencies:[se,pe,de,_e,ve,le,S],styles:[".room-title[_ngcontent-%COMP%]{margin-left:10px}@media(max-width:575px){.room-title[_ngcontent-%COMP%]{margin-left:7px}}.services-bag[_ngcontent-%COMP%]{min-height:170px}@media(max-width:575px){.services-bag[_ngcontent-%COMP%]{min-height:initial}}.cursor-move[_ngcontent-%COMP%]{cursor:move}a[_ngcontent-%COMP%]:hover{text-decoration:none!important}"]})}return t})();export{gt as AccessoriesComponent};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{a as Mv}from"./chunk-FIF6GB4H.js";import{a as Uu,b as Ko,c as Jo,d as Zo}from"./chunk-M72FKTRG.js";import{a as Xi,b as Dv,c as nV,d as Xp}from"./chunk-P7RLJ6EQ.js";import{a as wv}from"./chunk-QRWK7JO5.js";import{a as Pv}from"./chunk-WYJ4N4TV.js";import{a as bv,b as Cv,c as xv}from"./chunk-BMOLDRJ3.js";import{a as vv}from"./chunk-SOEFKTV3.js";import{a as da}from"./chunk-H7F7H5MW.js";import{a as Ev}from"./chunk-2W47TKRP.js";import{a as ZF}from"./chunk-JH5W4II7.js";import{a as YF}from"./chunk-XM3BXRQJ.js";import{a as QF}from"./chunk-GQMGUEFI.js";import{a as XF}from"./chunk-5INR7MRZ.js";import{a as eV}from"./chunk-XEOYEVJE.js";import{a as tV}from"./chunk-TXOHSX6R.js";import{a as Or}from"./chunk-63DEF4BP.js";import{a as jF}from"./chunk-YJWJIJMQ.js";import{a as zF}from"./chunk-CB6OGKHG.js";import{a as UF}from"./chunk-NPWYNB2M.js";import{a as HF}from"./chunk-W546I2QX.js";import{a as WF}from"./chunk-TCWZ7ASJ.js";import{a as GF}from"./chunk-NDBIOJ3K.js";import{a as KF}from"./chunk-NMM246IB.js";import{a as JF}from"./chunk-AU6YJ4VB.js";import{a as NF}from"./chunk-2AZ4IAJX.js";import{a as RF}from"./chunk-B2R3BKIF.js";import{a as AF}from"./chunk-IUXXJEPG.js";import{a as FF}from"./chunk-C2W3HONU.js";import{a as VF}from"./chunk-OB3JM574.js";import{a as BF}from"./chunk-HRBBCSGX.js";import{a as qF}from"./chunk-AASDOQGB.js";import{a as LF}from"./chunk-MKCBNPFH.js";import{a as Qp,c as Sv,d as Iv}from"./chunk-ZCGZM7LU.js";import{a as Tv}from"./chunk-QOXXKL5T.js";import{a as Vu,b as Bu,c as qu,d as Lu,e as ju,f as zu,g as Go,m as Et,n as Pn,o as mv,p as hv,q as gv,r as _v,s as yv,t as Nr}from"./chunk-LT4LVLTJ.js";import{e as ki}from"./chunk-DGBI427A.js";import{C as gi,D as ca,a as nv,b as Mr,c as uo,e as an,f as iv,h as rv,i as ov,j as sv,k as av,l as ti,m as lv,n as uv,o as cv,p as dv,q as Tr,t as Wo,u as $r,v as Yp,w as kr,x as pv,y as fv}from"./chunk-N2IMTG2V.js";import{b as mt}from"./chunk-PXNJ4PSF.js";import{E as rt,F as It,H as ot,J as Dr,K as Xe,d as Pr,e as sn,m as Fu,o as Qy,q as Xy,w as ev,y as tv}from"./chunk-YZZ7SAON.js";import{$ as Ly,Aa as Ti,Ab as q,Ac as gn,Bc as Ho,C as Hp,Ca as Uy,Cb as tn,Db as nn,Ea as Hy,Eb as rn,Ec as O,F as jo,Fb as P,Fc as F,G as By,Gb as v,Gc as St,Hb as y,Ib as L,Jb as Te,Kb as $e,Lb as Tt,Mb as la,Nb as ua,Nc as _n,O as Wp,Oc as X,P as Tu,Pc as Er,Q as Gp,R as hi,Rb as oe,Rc as Qi,S as qy,Sb as En,Ua as je,Va as Wy,Vc as lo,W as Kp,Wc as Zy,X as dt,Xb as te,Xc as Yy,Y as br,Ya as Gy,Yb as on,Za as m,Zb as w,_ as Zi,a as ro,aa as k,bc as ku,c as oo,cc as Ou,d as Be,db as Jp,dc as Nu,e as Pu,ea as jy,ec as wr,f as Up,fc as Sr,ga as Z,gb as zo,gc as Ru,h as Oy,ha as Y,hb as $u,hc as Kt,i as Ny,ib as aa,ic as Wt,jc as le,ka as sa,kb as $i,kc as T,la as so,lc as se,m as Ry,mc as re,nb as Ce,nc as Ir,o as Du,oa as qn,ob as xr,oc as Au,pa as Cr,pb as Yi,qb as Ky,rc as Nt,sa as U,sc as Rt,tb as Me,tc as At,u as Ay,vc as Jy,wc as Uo,x as Fy,xa as Mi,xb as Zp,xc as it,y as Mu,ya as zy,yb as ge,yc as ei,z as Vy,zb as B,zc as ao}from"./chunk-ZPXACREZ.js";import{a as DF}from"./chunk-KTE7SASZ.js";import{a as MF}from"./chunk-MKFXR7SP.js";import{a as TF}from"./chunk-32NSGOWJ.js";import{a as $F}from"./chunk-5N6BZ66K.js";import{a as kF}from"./chunk-JEWURKW3.js";import{a as OF}from"./chunk-56AT4EBV.js";import{a as pe,b as xe,c as ky,e as x,g as at,h as ue}from"./chunk-B4AJQJMI.js";var Vv=x(Ni=>{"use strict";Object.defineProperty(Ni,"__esModule",{value:!0});Ni.formatNames=Ni.fastFormats=Ni.fullFormats=void 0;function Oi(t,n){return{validate:t,compare:n}}Ni.fullFormats={date:Oi(Nv,rf),time:Oi(tf(!0),of),"date-time":Oi($v(!0),Av),"iso-time":Oi(tf(),Rv),"iso-date-time":Oi($v(),Fv),duration:/^P(?!$)((\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+S)?)?|(\d+W)?)$/,uri:lV,"uri-reference":/^(?:[a-z][a-z0-9+\-.]*:)?(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'"()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?(?:\?(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i,"uri-template":/^(?:(?:[^\x00-\x20"'<>%\\^`{|}]|%[0-9a-f]{2})|\{[+#./;?&=,!@|]?(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?(?:,(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?)*\})*$/i,url:/^(?:https?|ftp):\/\/(?:\S+(?::\S*)?@)?(?:(?!(?:10|127)(?:\.\d{1,3}){3})(?!(?:169\.254|192\.168)(?:\.\d{1,3}){2})(?!172\.(?:1[6-9]|2\d|3[0-1])(?:\.\d{1,3}){2})(?:[1-9]\d?|1\d\d|2[01]\d|22[0-3])(?:\.(?:1?\d{1,2}|2[0-4]\d|25[0-5])){2}(?:\.(?:[1-9]\d?|1\d\d|2[0-4]\d|25[0-4]))|(?:(?:[a-z0-9\u{00a1}-\u{ffff}]+-)*[a-z0-9\u{00a1}-\u{ffff}]+)(?:\.(?:[a-z0-9\u{00a1}-\u{ffff}]+-)*[a-z0-9\u{00a1}-\u{ffff}]+)*(?:\.(?:[a-z\u{00a1}-\u{ffff}]{2,})))(?::\d{2,5})?(?:\/[^\s]*)?$/iu,email:/^[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*@(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?$/i,hostname:/^(?=.{1,253}\.?$)[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[-0-9a-z]{0,61}[0-9a-z])?)*\.?$/i,ipv4:/^(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)\.){3}(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)$/,ipv6:/^((([0-9a-f]{1,4}:){7}([0-9a-f]{1,4}|:))|(([0-9a-f]{1,4}:){6}(:[0-9a-f]{1,4}|((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9a-f]{1,4}:){5}(((:[0-9a-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9a-f]{1,4}:){4}(((:[0-9a-f]{1,4}){1,3})|((:[0-9a-f]{1,4})?:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){3}(((:[0-9a-f]{1,4}){1,4})|((:[0-9a-f]{1,4}){0,2}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){2}(((:[0-9a-f]{1,4}){1,5})|((:[0-9a-f]{1,4}){0,3}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){1}(((:[0-9a-f]{1,4}){1,6})|((:[0-9a-f]{1,4}){0,4}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(:(((:[0-9a-f]{1,4}){1,7})|((:[0-9a-f]{1,4}){0,5}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))$/i,regex:hV,uuid:/^(?:urn:uuid:)?[0-9a-f]{8}-(?:[0-9a-f]{4}-){3}[0-9a-f]{12}$/i,"json-pointer":/^(?:\/(?:[^~/]|~0|~1)*)*$/,"json-pointer-uri-fragment":/^#(?:\/(?:[a-z0-9_\-.!$&'()*+,;:=@]|%[0-9a-f]{2}|~0|~1)*)*$/i,"relative-json-pointer":/^(?:0|[1-9][0-9]*)(?:#|(?:\/(?:[^~/]|~0|~1)*)*)$/,byte:uV,int32:{type:"number",validate:pV},int64:{type:"number",validate:fV},float:{type:"number",validate:Ov},double:{type:"number",validate:Ov},password:!0,binary:!0};Ni.fastFormats=xe(pe({},Ni.fullFormats),{date:Oi(/^\d\d\d\d-[0-1]\d-[0-3]\d$/,rf),time:Oi(/^(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)$/i,of),"date-time":Oi(/^\d\d\d\d-[0-1]\d-[0-3]\dt(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)$/i,Av),"iso-time":Oi(/^(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)?$/i,Rv),"iso-date-time":Oi(/^\d\d\d\d-[0-1]\d-[0-3]\d[t\s](?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)?$/i,Fv),uri:/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/)?[^\s]*$/i,"uri-reference":/^(?:(?:[a-z][a-z0-9+\-.]*:)?\/?\/)?(?:[^\\\s#][^\s#]*)?(?:#[^\\\s]*)?$/i,email:/^[a-z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)*$/i});Ni.formatNames=Object.keys(Ni.fullFormats);function iV(t){return t%4===0&&(t%100!==0||t%400===0)}var rV=/^(\d\d\d\d)-(\d\d)-(\d\d)$/,oV=[0,31,28,31,30,31,30,31,31,30,31,30,31];function Nv(t){let n=rV.exec(t);if(!n)return!1;let e=+n[1],i=+n[2],r=+n[3];return i>=1&&i<=12&&r>=1&&r<=(i===2&&iV(e)?29:oV[i])}function rf(t,n){if(t&&n)return t>n?1:t<n?-1:0}var ef=/^(\d\d):(\d\d):(\d\d(?:\.\d+)?)(z|([+-])(\d\d)(?::?(\d\d))?)?$/i;function tf(t){return function(e){let i=ef.exec(e);if(!i)return!1;let r=+i[1],s=+i[2],l=+i[3],u=i[4],d=i[5]==="-"?-1:1,f=+(i[6]||0),g=+(i[7]||0);if(f>23||g>59||t&&!u)return!1;if(r<=23&&s<=59&&l<60)return!0;let b=s-g*d,S=r-f*d-(b<0?1:0);return(S===23||S===-1)&&(b===59||b===-1)&&l<61}}function of(t,n){if(!(t&&n))return;let e=new Date("2020-01-01T"+t).valueOf(),i=new Date("2020-01-01T"+n).valueOf();if(e&&i)return e-i}function Rv(t,n){if(!(t&&n))return;let e=ef.exec(t),i=ef.exec(n);if(e&&i)return t=e[1]+e[2]+e[3],n=i[1]+i[2]+i[3],t>n?1:t<n?-1:0}var nf=/t|\s/i;function $v(t){let n=tf(t);return function(i){let r=i.split(nf);return r.length===2&&Nv(r[0])&&n(r[1])}}function Av(t,n){if(!(t&&n))return;let e=new Date(t).valueOf(),i=new Date(n).valueOf();if(e&&i)return e-i}function Fv(t,n){if(!(t&&n))return;let[e,i]=t.split(nf),[r,s]=n.split(nf),l=rf(e,r);if(l!==void 0)return l||of(i,s)}var sV=/\/|:/,aV=/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)(?:\?(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i;function lV(t){return sV.test(t)&&aV.test(t)}var kv=/^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/gm;function uV(t){return kv.lastIndex=0,kv.test(t)}var cV=-(2**31),dV=2**31-1;function pV(t){return Number.isInteger(t)&&t<=dV&&t>=cV}function fV(t){return Number.isInteger(t)}function Ov(){return!0}var mV=/[^\\]\\Z/;function hV(t){if(mV.test(t))return!1;try{return new RegExp(t),!0}catch{return!1}}});var ma=x(Ye=>{"use strict";Object.defineProperty(Ye,"__esModule",{value:!0});Ye.regexpCode=Ye.getEsmExportName=Ye.getProperty=Ye.safeStringify=Ye.stringify=Ye.strConcat=Ye.addCodeArg=Ye.str=Ye._=Ye.nil=Ye._Code=Ye.Name=Ye.IDENTIFIER=Ye._CodeOrName=void 0;var pa=class{};Ye._CodeOrName=pa;Ye.IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;var co=class extends pa{constructor(n){if(super(),!Ye.IDENTIFIER.test(n))throw new Error("CodeGen: name must be a valid identifier");this.str=n}toString(){return this.str}emptyStr(){return!1}get names(){return{[this.str]:1}}};Ye.Name=co;var ni=class extends pa{constructor(n){super(),this._items=typeof n=="string"?[n]:n}toString(){return this.str}emptyStr(){if(this._items.length>1)return!1;let n=this._items[0];return n===""||n==='""'}get str(){var n;return(n=this._str)!==null&&n!==void 0?n:this._str=this._items.reduce((e,i)=>`${e}${i}`,"")}get names(){var n;return(n=this._names)!==null&&n!==void 0?n:this._names=this._items.reduce((e,i)=>(i instanceof co&&(e[i.str]=(e[i.str]||0)+1),e),{})}};Ye._Code=ni;Ye.nil=new ni("");function Bv(t,...n){let e=[t[0]],i=0;for(;i<n.length;)af(e,n[i]),e.push(t[++i]);return new ni(e)}Ye._=Bv;var sf=new ni("+");function qv(t,...n){let e=[fa(t[0])],i=0;for(;i<n.length;)e.push(sf),af(e,n[i]),e.push(sf,fa(t[++i]));return gV(e),new ni(e)}Ye.str=qv;function af(t,n){n instanceof ni?t.push(...n._items):n instanceof co?t.push(n):t.push(vV(n))}Ye.addCodeArg=af;function gV(t){let n=1;for(;n<t.length-1;){if(t[n]===sf){let e=_V(t[n-1],t[n+1]);if(e!==void 0){t.splice(n-1,3,e);continue}t[n++]="+"}n++}}function _V(t,n){if(n==='""')return t;if(t==='""')return n;if(typeof t=="string")return n instanceof co||t[t.length-1]!=='"'?void 0:typeof n!="string"?`${t.slice(0,-1)}${n}"`:n[0]==='"'?t.slice(0,-1)+n.slice(1):void 0;if(typeof n=="string"&&n[0]==='"'&&!(t instanceof co))return`"${t}${n.slice(1)}`}function yV(t,n){return n.emptyStr()?t:t.emptyStr()?n:qv`${t}${n}`}Ye.strConcat=yV;function vV(t){return typeof t=="number"||typeof t=="boolean"||t===null?t:fa(Array.isArray(t)?t.join(","):t)}function bV(t){return new ni(fa(t))}Ye.stringify=bV;function fa(t){return JSON.stringify(t).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}Ye.safeStringify=fa;function CV(t){return typeof t=="string"&&Ye.IDENTIFIER.test(t)?new ni(`.${t}`):Bv`[${t}]`}Ye.getProperty=CV;function xV(t){if(typeof t=="string"&&Ye.IDENTIFIER.test(t))return new ni(`${t}`);throw new Error(`CodeGen: invalid export name: ${t}, use explicit $id name mapping`)}Ye.getEsmExportName=xV;function wV(t){return new ni(t.toString())}Ye.regexpCode=wV});var cf=x(Mn=>{"use strict";Object.defineProperty(Mn,"__esModule",{value:!0});Mn.ValueScope=Mn.ValueScopeName=Mn.Scope=Mn.varKinds=Mn.UsedValueState=void 0;var Dn=ma(),lf=class extends Error{constructor(n){super(`CodeGen: "code" for ${n} not defined`),this.value=n.value}},Hu=(function(t){return t[t.Started=0]="Started",t[t.Completed=1]="Completed",t})(Hu||(Mn.UsedValueState=Hu={}));Mn.varKinds={const:new Dn.Name("const"),let:new Dn.Name("let"),var:new Dn.Name("var")};var Wu=class{constructor({prefixes:n,parent:e}={}){this._names={},this._prefixes=n,this._parent=e}toName(n){return n instanceof Dn.Name?n:this.name(n)}name(n){return new Dn.Name(this._newName(n))}_newName(n){let e=this._names[n]||this._nameGroup(n);return`${n}${e.index++}`}_nameGroup(n){var e,i;if(!((i=(e=this._parent)===null||e===void 0?void 0:e._prefixes)===null||i===void 0)&&i.has(n)||this._prefixes&&!this._prefixes.has(n))throw new Error(`CodeGen: prefix "${n}" is not allowed in this scope`);return this._names[n]={prefix:n,index:0}}};Mn.Scope=Wu;var Gu=class extends Dn.Name{constructor(n,e){super(e),this.prefix=n}setValue(n,{property:e,itemIndex:i}){this.value=n,this.scopePath=(0,Dn._)`.${new Dn.Name(e)}[${i}]`}};Mn.ValueScopeName=Gu;var SV=(0,Dn._)`\n`,uf=class extends Wu{constructor(n){super(n),this._values={},this._scope=n.scope,this.opts=xe(pe({},n),{_n:n.lines?SV:Dn.nil})}get(){return this._scope}name(n){return new Gu(n,this._newName(n))}value(n,e){var i;if(e.ref===void 0)throw new Error("CodeGen: ref must be passed in value");let r=this.toName(n),{prefix:s}=r,l=(i=e.key)!==null&&i!==void 0?i:e.ref,u=this._values[s];if(u){let g=u.get(l);if(g)return g}else u=this._values[s]=new Map;u.set(l,r);let d=this._scope[s]||(this._scope[s]=[]),f=d.length;return d[f]=e.ref,r.setValue(e,{property:s,itemIndex:f}),r}getValue(n,e){let i=this._values[n];if(i)return i.get(e)}scopeRefs(n,e=this._values){return this._reduceValues(e,i=>{if(i.scopePath===void 0)throw new Error(`CodeGen: name "${i}" has no value`);return(0,Dn._)`${n}${i.scopePath}`})}scopeCode(n=this._values,e,i){return this._reduceValues(n,r=>{if(r.value===void 0)throw new Error(`CodeGen: name "${r}" has no value`);return r.value.code},e,i)}_reduceValues(n,e,i={},r){let s=Dn.nil;for(let l in n){let u=n[l];if(!u)continue;let d=i[l]=i[l]||new Map;u.forEach(f=>{if(d.has(f))return;d.set(f,Hu.Started);let g=e(f);if(g){let b=this.opts.es5?Mn.varKinds.var:Mn.varKinds.const;s=(0,Dn._)`${s}${b} ${f} = ${g};${this.opts._n}`}else if(g=r?.(f))s=(0,Dn._)`${s}${g}${this.opts._n}`;else throw new lf(f);d.set(f,Hu.Completed)})}return s}};Mn.ValueScope=uf});var we=x(ze=>{"use strict";Object.defineProperty(ze,"__esModule",{value:!0});ze.or=ze.and=ze.not=ze.CodeGen=ze.operators=ze.varKinds=ze.ValueScopeName=ze.ValueScope=ze.Scope=ze.Name=ze.regexpCode=ze.stringify=ze.getProperty=ze.nil=ze.strConcat=ze.str=ze._=void 0;var Je=ma(),_i=cf(),Rr=ma();Object.defineProperty(ze,"_",{enumerable:!0,get:function(){return Rr._}});Object.defineProperty(ze,"str",{enumerable:!0,get:function(){return Rr.str}});Object.defineProperty(ze,"strConcat",{enumerable:!0,get:function(){return Rr.strConcat}});Object.defineProperty(ze,"nil",{enumerable:!0,get:function(){return Rr.nil}});Object.defineProperty(ze,"getProperty",{enumerable:!0,get:function(){return Rr.getProperty}});Object.defineProperty(ze,"stringify",{enumerable:!0,get:function(){return Rr.stringify}});Object.defineProperty(ze,"regexpCode",{enumerable:!0,get:function(){return Rr.regexpCode}});Object.defineProperty(ze,"Name",{enumerable:!0,get:function(){return Rr.Name}});var Qu=cf();Object.defineProperty(ze,"Scope",{enumerable:!0,get:function(){return Qu.Scope}});Object.defineProperty(ze,"ValueScope",{enumerable:!0,get:function(){return Qu.ValueScope}});Object.defineProperty(ze,"ValueScopeName",{enumerable:!0,get:function(){return Qu.ValueScopeName}});Object.defineProperty(ze,"varKinds",{enumerable:!0,get:function(){return Qu.varKinds}});ze.operators={GT:new Je._Code(">"),GTE:new Je._Code(">="),LT:new Je._Code("<"),LTE:new Je._Code("<="),EQ:new Je._Code("==="),NEQ:new Je._Code("!=="),NOT:new Je._Code("!"),OR:new Je._Code("||"),AND:new Je._Code("&&"),ADD:new Je._Code("+")};var er=class{optimizeNodes(){return this}optimizeNames(n,e){return this}},df=class extends er{constructor(n,e,i){super(),this.varKind=n,this.name=e,this.rhs=i}render({es5:n,_n:e}){let i=n?_i.varKinds.var:this.varKind,r=this.rhs===void 0?"":` = ${this.rhs}`;return`${i} ${this.name}${r};`+e}optimizeNames(n,e){if(n[this.name.str])return this.rhs&&(this.rhs=Yo(this.rhs,n,e)),this}get names(){return this.rhs instanceof Je._CodeOrName?this.rhs.names:{}}},Ju=class extends er{constructor(n,e,i){super(),this.lhs=n,this.rhs=e,this.sideEffects=i}render({_n:n}){return`${this.lhs} = ${this.rhs};`+n}optimizeNames(n,e){if(!(this.lhs instanceof Je.Name&&!n[this.lhs.str]&&!this.sideEffects))return this.rhs=Yo(this.rhs,n,e),this}get names(){let n=this.lhs instanceof Je.Name?{}:pe({},this.lhs.names);return Yu(n,this.rhs)}},pf=class extends Ju{constructor(n,e,i,r){super(n,i,r),this.op=e}render({_n:n}){return`${this.lhs} ${this.op}= ${this.rhs};`+n}},ff=class extends er{constructor(n){super(),this.label=n,this.names={}}render({_n:n}){return`${this.label}:`+n}},mf=class extends er{constructor(n){super(),this.label=n,this.names={}}render({_n:n}){return`break${this.label?` ${this.label}`:""};`+n}},hf=class extends er{constructor(n){super(),this.error=n}render({_n:n}){return`throw ${this.error};`+n}get names(){return this.error.names}},gf=class extends er{constructor(n){super(),this.code=n}render({_n:n}){return`${this.code};`+n}optimizeNodes(){return`${this.code}`?this:void 0}optimizeNames(n,e){return this.code=Yo(this.code,n,e),this}get names(){return this.code instanceof Je._CodeOrName?this.code.names:{}}},ha=class extends er{constructor(n=[]){super(),this.nodes=n}render(n){return this.nodes.reduce((e,i)=>e+i.render(n),"")}optimizeNodes(){let{nodes:n}=this,e=n.length;for(;e--;){let i=n[e].optimizeNodes();Array.isArray(i)?n.splice(e,1,...i):i?n[e]=i:n.splice(e,1)}return n.length>0?this:void 0}optimizeNames(n,e){let{nodes:i}=this,r=i.length;for(;r--;){let s=i[r];s.optimizeNames(n,e)||(IV(n,s.names),i.splice(r,1))}return i.length>0?this:void 0}get names(){return this.nodes.reduce((n,e)=>po(n,e.names),{})}},tr=class extends ha{render(n){return"{"+n._n+super.render(n)+"}"+n._n}},_f=class extends ha{},yf=(()=>{class t extends tr{}return t.kind="else",t})(),Ku=(()=>{class t extends tr{constructor(e,i){super(i),this.condition=e}render(e){let i=`if(${this.condition})`+super.render(e);return this.else&&(i+="else "+this.else.render(e)),i}optimizeNodes(){super.optimizeNodes();let e=this.condition;if(e===!0)return this.nodes;let i=this.else;if(i){let r=i.optimizeNodes();i=this.else=Array.isArray(r)?new yf(r):r}if(i)return e===!1?i instanceof t?i:i.nodes:this.nodes.length?this:new t(Hv(e),i instanceof t?[i]:i.nodes);if(!(e===!1||!this.nodes.length))return this}optimizeNames(e,i){var r;if(this.else=(r=this.else)===null||r===void 0?void 0:r.optimizeNames(e,i),!!(super.optimizeNames(e,i)||this.else))return this.condition=Yo(this.condition,e,i),this}get names(){let e=super.names;return Yu(e,this.condition),this.else&&po(e,this.else.names),e}}return t.kind="if",t})(),Xu=(()=>{class t extends tr{}return t.kind="for",t})(),vf=class extends Xu{constructor(n){super(),this.iteration=n}render(n){return`for(${this.iteration})`+super.render(n)}optimizeNames(n,e){if(super.optimizeNames(n,e))return this.iteration=Yo(this.iteration,n,e),this}get names(){return po(super.names,this.iteration.names)}},bf=class extends Xu{constructor(n,e,i,r){super(),this.varKind=n,this.name=e,this.from=i,this.to=r}render(n){let e=n.es5?_i.varKinds.var:this.varKind,{name:i,from:r,to:s}=this;return`for(${e} ${i}=${r}; ${i}<${s}; ${i}++)`+super.render(n)}get names(){let n=Yu(super.names,this.from);return Yu(n,this.to)}},Zu=class extends Xu{constructor(n,e,i,r){super(),this.loop=n,this.varKind=e,this.name=i,this.iterable=r}render(n){return`for(${this.varKind} ${this.name} ${this.loop} ${this.iterable})`+super.render(n)}optimizeNames(n,e){if(super.optimizeNames(n,e))return this.iterable=Yo(this.iterable,n,e),this}get names(){return po(super.names,this.iterable.names)}},Lv=(()=>{class t extends tr{constructor(e,i,r){super(),this.name=e,this.args=i,this.async=r}render(e){return`${this.async?"async ":""}function ${this.name}(${this.args})`+super.render(e)}}return t.kind="func",t})(),jv=(()=>{class t extends ha{render(e){return"return "+super.render(e)}}return t.kind="return",t})(),Cf=class extends tr{render(n){let e="try"+super.render(n);return this.catch&&(e+=this.catch.render(n)),this.finally&&(e+=this.finally.render(n)),e}optimizeNodes(){var n,e;return super.optimizeNodes(),(n=this.catch)===null||n===void 0||n.optimizeNodes(),(e=this.finally)===null||e===void 0||e.optimizeNodes(),this}optimizeNames(n,e){var i,r;return super.optimizeNames(n,e),(i=this.catch)===null||i===void 0||i.optimizeNames(n,e),(r=this.finally)===null||r===void 0||r.optimizeNames(n,e),this}get names(){let n=super.names;return this.catch&&po(n,this.catch.names),this.finally&&po(n,this.finally.names),n}},zv=(()=>{class t extends tr{constructor(e){super(),this.error=e}render(e){return`catch(${this.error})`+super.render(e)}}return t.kind="catch",t})(),Uv=(()=>{class t extends tr{render(e){return"finally"+super.render(e)}}return t.kind="finally",t})(),xf=class{constructor(n,e={}){this._values={},this._blockStarts=[],this._constants={},this.opts=xe(pe({},e),{_n:e.lines?`
|
|
1
|
+
import{a as Mv}from"./chunk-CQHE4TU3.js";import{a as Uu,b as Ko,c as Jo,d as Zo}from"./chunk-FL4D5IR7.js";import{a as Xi,b as Dv,c as nV,d as Xp}from"./chunk-GV5JF2YJ.js";import{a as wv}from"./chunk-QRWK7JO5.js";import{a as Pv}from"./chunk-SIIM6WZ6.js";import{a as bv,b as Cv,c as xv}from"./chunk-BMOLDRJ3.js";import{a as vv}from"./chunk-3ND4FTJL.js";import{a as da}from"./chunk-H7F7H5MW.js";import{a as Ev}from"./chunk-2W47TKRP.js";import{a as ZF}from"./chunk-JH5W4II7.js";import{a as YF}from"./chunk-XM3BXRQJ.js";import{a as QF}from"./chunk-GQMGUEFI.js";import{a as XF}from"./chunk-5INR7MRZ.js";import{a as eV}from"./chunk-XEOYEVJE.js";import{a as tV}from"./chunk-TXOHSX6R.js";import{a as Or}from"./chunk-74KAKFTX.js";import{a as jF}from"./chunk-YJWJIJMQ.js";import{a as zF}from"./chunk-CB6OGKHG.js";import{a as UF}from"./chunk-NPWYNB2M.js";import{a as HF}from"./chunk-W546I2QX.js";import{a as WF}from"./chunk-TCWZ7ASJ.js";import{a as GF}from"./chunk-NDBIOJ3K.js";import{a as KF}from"./chunk-NMM246IB.js";import{a as JF}from"./chunk-AU6YJ4VB.js";import{a as NF}from"./chunk-2AZ4IAJX.js";import{a as RF}from"./chunk-B2R3BKIF.js";import{a as AF}from"./chunk-IUXXJEPG.js";import{a as FF}from"./chunk-C2W3HONU.js";import{a as VF}from"./chunk-OB3JM574.js";import{a as BF}from"./chunk-HRBBCSGX.js";import{a as qF}from"./chunk-AASDOQGB.js";import{a as LF}from"./chunk-MKCBNPFH.js";import{a as Qp,c as Sv,d as Iv}from"./chunk-ZCGZM7LU.js";import{a as Tv}from"./chunk-GWQFQK2F.js";import{a as Vu,b as Bu,c as qu,d as Lu,e as ju,f as zu,g as Go,m as Et,n as Pn,o as mv,p as hv,q as gv,r as _v,s as yv,t as Nr}from"./chunk-GAI5J4YQ.js";import{e as ki}from"./chunk-ZAKTSIL5.js";import{C as gi,D as ca,a as nv,b as Mr,c as uo,e as an,f as iv,h as rv,i as ov,j as sv,k as av,l as ti,m as lv,n as uv,o as cv,p as dv,q as Tr,t as Wo,u as $r,v as Yp,w as kr,x as pv,y as fv}from"./chunk-O6MJC7P2.js";import{b as mt}from"./chunk-CAB2VD3D.js";import{E as rt,F as It,H as ot,J as Dr,K as Xe,d as Pr,e as sn,m as Fu,o as Qy,q as Xy,w as ev,y as tv}from"./chunk-MW6H5Z5G.js";import{$ as Ly,Aa as Ti,Ab as q,Ac as gn,Bc as Ho,C as Hp,Ca as Uy,Cb as tn,Db as nn,Ea as Hy,Eb as rn,Ec as O,F as jo,Fb as P,Fc as F,G as By,Gb as v,Gc as St,Hb as y,Ib as L,Jb as Te,Kb as $e,Lb as Tt,Mb as la,Nb as ua,Nc as _n,O as Wp,Oc as X,P as Tu,Pc as Er,Q as Gp,R as hi,Rb as oe,Rc as Qi,S as qy,Sb as En,Ua as je,Va as Wy,Vc as lo,W as Kp,Wc as Zy,X as dt,Xb as te,Xc as Yy,Y as br,Ya as Gy,Yb as on,Za as m,Zb as w,_ as Zi,a as ro,aa as k,bc as ku,c as oo,cc as Ou,d as Be,db as Jp,dc as Nu,e as Pu,ea as jy,ec as wr,f as Up,fc as Sr,ga as Z,gb as zo,gc as Ru,h as Oy,ha as Y,hb as $u,hc as Kt,i as Ny,ib as aa,ic as Wt,jc as le,ka as sa,kb as $i,kc as T,la as so,lc as se,m as Ry,mc as re,nb as Ce,nc as Ir,o as Du,oa as qn,ob as xr,oc as Au,pa as Cr,pb as Yi,qb as Ky,rc as Nt,sa as U,sc as Rt,tb as Me,tc as At,u as Ay,vc as Jy,wc as Uo,x as Fy,xa as Mi,xb as Zp,xc as it,y as Mu,ya as zy,yb as ge,yc as ei,z as Vy,zb as B,zc as ao}from"./chunk-ZPXACREZ.js";import{a as DF}from"./chunk-KTE7SASZ.js";import{a as MF}from"./chunk-MKFXR7SP.js";import{a as TF}from"./chunk-32NSGOWJ.js";import{a as $F}from"./chunk-5N6BZ66K.js";import{a as kF}from"./chunk-JEWURKW3.js";import{a as OF}from"./chunk-56AT4EBV.js";import{a as pe,b as xe,c as ky,e as x,g as at,h as ue}from"./chunk-B4AJQJMI.js";var Vv=x(Ni=>{"use strict";Object.defineProperty(Ni,"__esModule",{value:!0});Ni.formatNames=Ni.fastFormats=Ni.fullFormats=void 0;function Oi(t,n){return{validate:t,compare:n}}Ni.fullFormats={date:Oi(Nv,rf),time:Oi(tf(!0),of),"date-time":Oi($v(!0),Av),"iso-time":Oi(tf(),Rv),"iso-date-time":Oi($v(),Fv),duration:/^P(?!$)((\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+S)?)?|(\d+W)?)$/,uri:lV,"uri-reference":/^(?:[a-z][a-z0-9+\-.]*:)?(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'"()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?(?:\?(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i,"uri-template":/^(?:(?:[^\x00-\x20"'<>%\\^`{|}]|%[0-9a-f]{2})|\{[+#./;?&=,!@|]?(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?(?:,(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?)*\})*$/i,url:/^(?:https?|ftp):\/\/(?:\S+(?::\S*)?@)?(?:(?!(?:10|127)(?:\.\d{1,3}){3})(?!(?:169\.254|192\.168)(?:\.\d{1,3}){2})(?!172\.(?:1[6-9]|2\d|3[0-1])(?:\.\d{1,3}){2})(?:[1-9]\d?|1\d\d|2[01]\d|22[0-3])(?:\.(?:1?\d{1,2}|2[0-4]\d|25[0-5])){2}(?:\.(?:[1-9]\d?|1\d\d|2[0-4]\d|25[0-4]))|(?:(?:[a-z0-9\u{00a1}-\u{ffff}]+-)*[a-z0-9\u{00a1}-\u{ffff}]+)(?:\.(?:[a-z0-9\u{00a1}-\u{ffff}]+-)*[a-z0-9\u{00a1}-\u{ffff}]+)*(?:\.(?:[a-z\u{00a1}-\u{ffff}]{2,})))(?::\d{2,5})?(?:\/[^\s]*)?$/iu,email:/^[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*@(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?$/i,hostname:/^(?=.{1,253}\.?$)[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[-0-9a-z]{0,61}[0-9a-z])?)*\.?$/i,ipv4:/^(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)\.){3}(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)$/,ipv6:/^((([0-9a-f]{1,4}:){7}([0-9a-f]{1,4}|:))|(([0-9a-f]{1,4}:){6}(:[0-9a-f]{1,4}|((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9a-f]{1,4}:){5}(((:[0-9a-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9a-f]{1,4}:){4}(((:[0-9a-f]{1,4}){1,3})|((:[0-9a-f]{1,4})?:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){3}(((:[0-9a-f]{1,4}){1,4})|((:[0-9a-f]{1,4}){0,2}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){2}(((:[0-9a-f]{1,4}){1,5})|((:[0-9a-f]{1,4}){0,3}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){1}(((:[0-9a-f]{1,4}){1,6})|((:[0-9a-f]{1,4}){0,4}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(:(((:[0-9a-f]{1,4}){1,7})|((:[0-9a-f]{1,4}){0,5}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))$/i,regex:hV,uuid:/^(?:urn:uuid:)?[0-9a-f]{8}-(?:[0-9a-f]{4}-){3}[0-9a-f]{12}$/i,"json-pointer":/^(?:\/(?:[^~/]|~0|~1)*)*$/,"json-pointer-uri-fragment":/^#(?:\/(?:[a-z0-9_\-.!$&'()*+,;:=@]|%[0-9a-f]{2}|~0|~1)*)*$/i,"relative-json-pointer":/^(?:0|[1-9][0-9]*)(?:#|(?:\/(?:[^~/]|~0|~1)*)*)$/,byte:uV,int32:{type:"number",validate:pV},int64:{type:"number",validate:fV},float:{type:"number",validate:Ov},double:{type:"number",validate:Ov},password:!0,binary:!0};Ni.fastFormats=xe(pe({},Ni.fullFormats),{date:Oi(/^\d\d\d\d-[0-1]\d-[0-3]\d$/,rf),time:Oi(/^(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)$/i,of),"date-time":Oi(/^\d\d\d\d-[0-1]\d-[0-3]\dt(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)$/i,Av),"iso-time":Oi(/^(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)?$/i,Rv),"iso-date-time":Oi(/^\d\d\d\d-[0-1]\d-[0-3]\d[t\s](?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)?$/i,Fv),uri:/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/)?[^\s]*$/i,"uri-reference":/^(?:(?:[a-z][a-z0-9+\-.]*:)?\/?\/)?(?:[^\\\s#][^\s#]*)?(?:#[^\\\s]*)?$/i,email:/^[a-z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)*$/i});Ni.formatNames=Object.keys(Ni.fullFormats);function iV(t){return t%4===0&&(t%100!==0||t%400===0)}var rV=/^(\d\d\d\d)-(\d\d)-(\d\d)$/,oV=[0,31,28,31,30,31,30,31,31,30,31,30,31];function Nv(t){let n=rV.exec(t);if(!n)return!1;let e=+n[1],i=+n[2],r=+n[3];return i>=1&&i<=12&&r>=1&&r<=(i===2&&iV(e)?29:oV[i])}function rf(t,n){if(t&&n)return t>n?1:t<n?-1:0}var ef=/^(\d\d):(\d\d):(\d\d(?:\.\d+)?)(z|([+-])(\d\d)(?::?(\d\d))?)?$/i;function tf(t){return function(e){let i=ef.exec(e);if(!i)return!1;let r=+i[1],s=+i[2],l=+i[3],u=i[4],d=i[5]==="-"?-1:1,f=+(i[6]||0),g=+(i[7]||0);if(f>23||g>59||t&&!u)return!1;if(r<=23&&s<=59&&l<60)return!0;let b=s-g*d,S=r-f*d-(b<0?1:0);return(S===23||S===-1)&&(b===59||b===-1)&&l<61}}function of(t,n){if(!(t&&n))return;let e=new Date("2020-01-01T"+t).valueOf(),i=new Date("2020-01-01T"+n).valueOf();if(e&&i)return e-i}function Rv(t,n){if(!(t&&n))return;let e=ef.exec(t),i=ef.exec(n);if(e&&i)return t=e[1]+e[2]+e[3],n=i[1]+i[2]+i[3],t>n?1:t<n?-1:0}var nf=/t|\s/i;function $v(t){let n=tf(t);return function(i){let r=i.split(nf);return r.length===2&&Nv(r[0])&&n(r[1])}}function Av(t,n){if(!(t&&n))return;let e=new Date(t).valueOf(),i=new Date(n).valueOf();if(e&&i)return e-i}function Fv(t,n){if(!(t&&n))return;let[e,i]=t.split(nf),[r,s]=n.split(nf),l=rf(e,r);if(l!==void 0)return l||of(i,s)}var sV=/\/|:/,aV=/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)(?:\?(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i;function lV(t){return sV.test(t)&&aV.test(t)}var kv=/^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/gm;function uV(t){return kv.lastIndex=0,kv.test(t)}var cV=-(2**31),dV=2**31-1;function pV(t){return Number.isInteger(t)&&t<=dV&&t>=cV}function fV(t){return Number.isInteger(t)}function Ov(){return!0}var mV=/[^\\]\\Z/;function hV(t){if(mV.test(t))return!1;try{return new RegExp(t),!0}catch{return!1}}});var ma=x(Ye=>{"use strict";Object.defineProperty(Ye,"__esModule",{value:!0});Ye.regexpCode=Ye.getEsmExportName=Ye.getProperty=Ye.safeStringify=Ye.stringify=Ye.strConcat=Ye.addCodeArg=Ye.str=Ye._=Ye.nil=Ye._Code=Ye.Name=Ye.IDENTIFIER=Ye._CodeOrName=void 0;var pa=class{};Ye._CodeOrName=pa;Ye.IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;var co=class extends pa{constructor(n){if(super(),!Ye.IDENTIFIER.test(n))throw new Error("CodeGen: name must be a valid identifier");this.str=n}toString(){return this.str}emptyStr(){return!1}get names(){return{[this.str]:1}}};Ye.Name=co;var ni=class extends pa{constructor(n){super(),this._items=typeof n=="string"?[n]:n}toString(){return this.str}emptyStr(){if(this._items.length>1)return!1;let n=this._items[0];return n===""||n==='""'}get str(){var n;return(n=this._str)!==null&&n!==void 0?n:this._str=this._items.reduce((e,i)=>`${e}${i}`,"")}get names(){var n;return(n=this._names)!==null&&n!==void 0?n:this._names=this._items.reduce((e,i)=>(i instanceof co&&(e[i.str]=(e[i.str]||0)+1),e),{})}};Ye._Code=ni;Ye.nil=new ni("");function Bv(t,...n){let e=[t[0]],i=0;for(;i<n.length;)af(e,n[i]),e.push(t[++i]);return new ni(e)}Ye._=Bv;var sf=new ni("+");function qv(t,...n){let e=[fa(t[0])],i=0;for(;i<n.length;)e.push(sf),af(e,n[i]),e.push(sf,fa(t[++i]));return gV(e),new ni(e)}Ye.str=qv;function af(t,n){n instanceof ni?t.push(...n._items):n instanceof co?t.push(n):t.push(vV(n))}Ye.addCodeArg=af;function gV(t){let n=1;for(;n<t.length-1;){if(t[n]===sf){let e=_V(t[n-1],t[n+1]);if(e!==void 0){t.splice(n-1,3,e);continue}t[n++]="+"}n++}}function _V(t,n){if(n==='""')return t;if(t==='""')return n;if(typeof t=="string")return n instanceof co||t[t.length-1]!=='"'?void 0:typeof n!="string"?`${t.slice(0,-1)}${n}"`:n[0]==='"'?t.slice(0,-1)+n.slice(1):void 0;if(typeof n=="string"&&n[0]==='"'&&!(t instanceof co))return`"${t}${n.slice(1)}`}function yV(t,n){return n.emptyStr()?t:t.emptyStr()?n:qv`${t}${n}`}Ye.strConcat=yV;function vV(t){return typeof t=="number"||typeof t=="boolean"||t===null?t:fa(Array.isArray(t)?t.join(","):t)}function bV(t){return new ni(fa(t))}Ye.stringify=bV;function fa(t){return JSON.stringify(t).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}Ye.safeStringify=fa;function CV(t){return typeof t=="string"&&Ye.IDENTIFIER.test(t)?new ni(`.${t}`):Bv`[${t}]`}Ye.getProperty=CV;function xV(t){if(typeof t=="string"&&Ye.IDENTIFIER.test(t))return new ni(`${t}`);throw new Error(`CodeGen: invalid export name: ${t}, use explicit $id name mapping`)}Ye.getEsmExportName=xV;function wV(t){return new ni(t.toString())}Ye.regexpCode=wV});var cf=x(Mn=>{"use strict";Object.defineProperty(Mn,"__esModule",{value:!0});Mn.ValueScope=Mn.ValueScopeName=Mn.Scope=Mn.varKinds=Mn.UsedValueState=void 0;var Dn=ma(),lf=class extends Error{constructor(n){super(`CodeGen: "code" for ${n} not defined`),this.value=n.value}},Hu=(function(t){return t[t.Started=0]="Started",t[t.Completed=1]="Completed",t})(Hu||(Mn.UsedValueState=Hu={}));Mn.varKinds={const:new Dn.Name("const"),let:new Dn.Name("let"),var:new Dn.Name("var")};var Wu=class{constructor({prefixes:n,parent:e}={}){this._names={},this._prefixes=n,this._parent=e}toName(n){return n instanceof Dn.Name?n:this.name(n)}name(n){return new Dn.Name(this._newName(n))}_newName(n){let e=this._names[n]||this._nameGroup(n);return`${n}${e.index++}`}_nameGroup(n){var e,i;if(!((i=(e=this._parent)===null||e===void 0?void 0:e._prefixes)===null||i===void 0)&&i.has(n)||this._prefixes&&!this._prefixes.has(n))throw new Error(`CodeGen: prefix "${n}" is not allowed in this scope`);return this._names[n]={prefix:n,index:0}}};Mn.Scope=Wu;var Gu=class extends Dn.Name{constructor(n,e){super(e),this.prefix=n}setValue(n,{property:e,itemIndex:i}){this.value=n,this.scopePath=(0,Dn._)`.${new Dn.Name(e)}[${i}]`}};Mn.ValueScopeName=Gu;var SV=(0,Dn._)`\n`,uf=class extends Wu{constructor(n){super(n),this._values={},this._scope=n.scope,this.opts=xe(pe({},n),{_n:n.lines?SV:Dn.nil})}get(){return this._scope}name(n){return new Gu(n,this._newName(n))}value(n,e){var i;if(e.ref===void 0)throw new Error("CodeGen: ref must be passed in value");let r=this.toName(n),{prefix:s}=r,l=(i=e.key)!==null&&i!==void 0?i:e.ref,u=this._values[s];if(u){let g=u.get(l);if(g)return g}else u=this._values[s]=new Map;u.set(l,r);let d=this._scope[s]||(this._scope[s]=[]),f=d.length;return d[f]=e.ref,r.setValue(e,{property:s,itemIndex:f}),r}getValue(n,e){let i=this._values[n];if(i)return i.get(e)}scopeRefs(n,e=this._values){return this._reduceValues(e,i=>{if(i.scopePath===void 0)throw new Error(`CodeGen: name "${i}" has no value`);return(0,Dn._)`${n}${i.scopePath}`})}scopeCode(n=this._values,e,i){return this._reduceValues(n,r=>{if(r.value===void 0)throw new Error(`CodeGen: name "${r}" has no value`);return r.value.code},e,i)}_reduceValues(n,e,i={},r){let s=Dn.nil;for(let l in n){let u=n[l];if(!u)continue;let d=i[l]=i[l]||new Map;u.forEach(f=>{if(d.has(f))return;d.set(f,Hu.Started);let g=e(f);if(g){let b=this.opts.es5?Mn.varKinds.var:Mn.varKinds.const;s=(0,Dn._)`${s}${b} ${f} = ${g};${this.opts._n}`}else if(g=r?.(f))s=(0,Dn._)`${s}${g}${this.opts._n}`;else throw new lf(f);d.set(f,Hu.Completed)})}return s}};Mn.ValueScope=uf});var we=x(ze=>{"use strict";Object.defineProperty(ze,"__esModule",{value:!0});ze.or=ze.and=ze.not=ze.CodeGen=ze.operators=ze.varKinds=ze.ValueScopeName=ze.ValueScope=ze.Scope=ze.Name=ze.regexpCode=ze.stringify=ze.getProperty=ze.nil=ze.strConcat=ze.str=ze._=void 0;var Je=ma(),_i=cf(),Rr=ma();Object.defineProperty(ze,"_",{enumerable:!0,get:function(){return Rr._}});Object.defineProperty(ze,"str",{enumerable:!0,get:function(){return Rr.str}});Object.defineProperty(ze,"strConcat",{enumerable:!0,get:function(){return Rr.strConcat}});Object.defineProperty(ze,"nil",{enumerable:!0,get:function(){return Rr.nil}});Object.defineProperty(ze,"getProperty",{enumerable:!0,get:function(){return Rr.getProperty}});Object.defineProperty(ze,"stringify",{enumerable:!0,get:function(){return Rr.stringify}});Object.defineProperty(ze,"regexpCode",{enumerable:!0,get:function(){return Rr.regexpCode}});Object.defineProperty(ze,"Name",{enumerable:!0,get:function(){return Rr.Name}});var Qu=cf();Object.defineProperty(ze,"Scope",{enumerable:!0,get:function(){return Qu.Scope}});Object.defineProperty(ze,"ValueScope",{enumerable:!0,get:function(){return Qu.ValueScope}});Object.defineProperty(ze,"ValueScopeName",{enumerable:!0,get:function(){return Qu.ValueScopeName}});Object.defineProperty(ze,"varKinds",{enumerable:!0,get:function(){return Qu.varKinds}});ze.operators={GT:new Je._Code(">"),GTE:new Je._Code(">="),LT:new Je._Code("<"),LTE:new Je._Code("<="),EQ:new Je._Code("==="),NEQ:new Je._Code("!=="),NOT:new Je._Code("!"),OR:new Je._Code("||"),AND:new Je._Code("&&"),ADD:new Je._Code("+")};var er=class{optimizeNodes(){return this}optimizeNames(n,e){return this}},df=class extends er{constructor(n,e,i){super(),this.varKind=n,this.name=e,this.rhs=i}render({es5:n,_n:e}){let i=n?_i.varKinds.var:this.varKind,r=this.rhs===void 0?"":` = ${this.rhs}`;return`${i} ${this.name}${r};`+e}optimizeNames(n,e){if(n[this.name.str])return this.rhs&&(this.rhs=Yo(this.rhs,n,e)),this}get names(){return this.rhs instanceof Je._CodeOrName?this.rhs.names:{}}},Ju=class extends er{constructor(n,e,i){super(),this.lhs=n,this.rhs=e,this.sideEffects=i}render({_n:n}){return`${this.lhs} = ${this.rhs};`+n}optimizeNames(n,e){if(!(this.lhs instanceof Je.Name&&!n[this.lhs.str]&&!this.sideEffects))return this.rhs=Yo(this.rhs,n,e),this}get names(){let n=this.lhs instanceof Je.Name?{}:pe({},this.lhs.names);return Yu(n,this.rhs)}},pf=class extends Ju{constructor(n,e,i,r){super(n,i,r),this.op=e}render({_n:n}){return`${this.lhs} ${this.op}= ${this.rhs};`+n}},ff=class extends er{constructor(n){super(),this.label=n,this.names={}}render({_n:n}){return`${this.label}:`+n}},mf=class extends er{constructor(n){super(),this.label=n,this.names={}}render({_n:n}){return`break${this.label?` ${this.label}`:""};`+n}},hf=class extends er{constructor(n){super(),this.error=n}render({_n:n}){return`throw ${this.error};`+n}get names(){return this.error.names}},gf=class extends er{constructor(n){super(),this.code=n}render({_n:n}){return`${this.code};`+n}optimizeNodes(){return`${this.code}`?this:void 0}optimizeNames(n,e){return this.code=Yo(this.code,n,e),this}get names(){return this.code instanceof Je._CodeOrName?this.code.names:{}}},ha=class extends er{constructor(n=[]){super(),this.nodes=n}render(n){return this.nodes.reduce((e,i)=>e+i.render(n),"")}optimizeNodes(){let{nodes:n}=this,e=n.length;for(;e--;){let i=n[e].optimizeNodes();Array.isArray(i)?n.splice(e,1,...i):i?n[e]=i:n.splice(e,1)}return n.length>0?this:void 0}optimizeNames(n,e){let{nodes:i}=this,r=i.length;for(;r--;){let s=i[r];s.optimizeNames(n,e)||(IV(n,s.names),i.splice(r,1))}return i.length>0?this:void 0}get names(){return this.nodes.reduce((n,e)=>po(n,e.names),{})}},tr=class extends ha{render(n){return"{"+n._n+super.render(n)+"}"+n._n}},_f=class extends ha{},yf=(()=>{class t extends tr{}return t.kind="else",t})(),Ku=(()=>{class t extends tr{constructor(e,i){super(i),this.condition=e}render(e){let i=`if(${this.condition})`+super.render(e);return this.else&&(i+="else "+this.else.render(e)),i}optimizeNodes(){super.optimizeNodes();let e=this.condition;if(e===!0)return this.nodes;let i=this.else;if(i){let r=i.optimizeNodes();i=this.else=Array.isArray(r)?new yf(r):r}if(i)return e===!1?i instanceof t?i:i.nodes:this.nodes.length?this:new t(Hv(e),i instanceof t?[i]:i.nodes);if(!(e===!1||!this.nodes.length))return this}optimizeNames(e,i){var r;if(this.else=(r=this.else)===null||r===void 0?void 0:r.optimizeNames(e,i),!!(super.optimizeNames(e,i)||this.else))return this.condition=Yo(this.condition,e,i),this}get names(){let e=super.names;return Yu(e,this.condition),this.else&&po(e,this.else.names),e}}return t.kind="if",t})(),Xu=(()=>{class t extends tr{}return t.kind="for",t})(),vf=class extends Xu{constructor(n){super(),this.iteration=n}render(n){return`for(${this.iteration})`+super.render(n)}optimizeNames(n,e){if(super.optimizeNames(n,e))return this.iteration=Yo(this.iteration,n,e),this}get names(){return po(super.names,this.iteration.names)}},bf=class extends Xu{constructor(n,e,i,r){super(),this.varKind=n,this.name=e,this.from=i,this.to=r}render(n){let e=n.es5?_i.varKinds.var:this.varKind,{name:i,from:r,to:s}=this;return`for(${e} ${i}=${r}; ${i}<${s}; ${i}++)`+super.render(n)}get names(){let n=Yu(super.names,this.from);return Yu(n,this.to)}},Zu=class extends Xu{constructor(n,e,i,r){super(),this.loop=n,this.varKind=e,this.name=i,this.iterable=r}render(n){return`for(${this.varKind} ${this.name} ${this.loop} ${this.iterable})`+super.render(n)}optimizeNames(n,e){if(super.optimizeNames(n,e))return this.iterable=Yo(this.iterable,n,e),this}get names(){return po(super.names,this.iterable.names)}},Lv=(()=>{class t extends tr{constructor(e,i,r){super(),this.name=e,this.args=i,this.async=r}render(e){return`${this.async?"async ":""}function ${this.name}(${this.args})`+super.render(e)}}return t.kind="func",t})(),jv=(()=>{class t extends ha{render(e){return"return "+super.render(e)}}return t.kind="return",t})(),Cf=class extends tr{render(n){let e="try"+super.render(n);return this.catch&&(e+=this.catch.render(n)),this.finally&&(e+=this.finally.render(n)),e}optimizeNodes(){var n,e;return super.optimizeNodes(),(n=this.catch)===null||n===void 0||n.optimizeNodes(),(e=this.finally)===null||e===void 0||e.optimizeNodes(),this}optimizeNames(n,e){var i,r;return super.optimizeNames(n,e),(i=this.catch)===null||i===void 0||i.optimizeNames(n,e),(r=this.finally)===null||r===void 0||r.optimizeNames(n,e),this}get names(){let n=super.names;return this.catch&&po(n,this.catch.names),this.finally&&po(n,this.finally.names),n}},zv=(()=>{class t extends tr{constructor(e){super(),this.error=e}render(e){return`catch(${this.error})`+super.render(e)}}return t.kind="catch",t})(),Uv=(()=>{class t extends tr{render(e){return"finally"+super.render(e)}}return t.kind="finally",t})(),xf=class{constructor(n,e={}){this._values={},this._blockStarts=[],this._constants={},this.opts=xe(pe({},e),{_n:e.lines?`
|
|
2
2
|
`:""}),this._extScope=n,this._scope=new _i.Scope({parent:n}),this._nodes=[new _f]}toString(){return this._root.render(this.opts)}name(n){return this._scope.name(n)}scopeName(n){return this._extScope.name(n)}scopeValue(n,e){let i=this._extScope.value(n,e);return(this._values[i.prefix]||(this._values[i.prefix]=new Set)).add(i),i}getScopeValue(n,e){return this._extScope.getValue(n,e)}scopeRefs(n){return this._extScope.scopeRefs(n,this._values)}scopeCode(){return this._extScope.scopeCode(this._values)}_def(n,e,i,r){let s=this._scope.toName(e);return i!==void 0&&r&&(this._constants[s.str]=i),this._leafNode(new df(n,s,i)),s}const(n,e,i){return this._def(_i.varKinds.const,n,e,i)}let(n,e,i){return this._def(_i.varKinds.let,n,e,i)}var(n,e,i){return this._def(_i.varKinds.var,n,e,i)}assign(n,e,i){return this._leafNode(new Ju(n,e,i))}add(n,e){return this._leafNode(new pf(n,ze.operators.ADD,e))}code(n){return typeof n=="function"?n():n!==Je.nil&&this._leafNode(new gf(n)),this}object(...n){let e=["{"];for(let[i,r]of n)e.length>1&&e.push(","),e.push(i),(i!==r||this.opts.es5)&&(e.push(":"),(0,Je.addCodeArg)(e,r));return e.push("}"),new Je._Code(e)}if(n,e,i){if(this._blockNode(new Ku(n)),e&&i)this.code(e).else().code(i).endIf();else if(e)this.code(e).endIf();else if(i)throw new Error('CodeGen: "else" body without "then" body');return this}elseIf(n){return this._elseNode(new Ku(n))}else(){return this._elseNode(new yf)}endIf(){return this._endBlockNode(Ku,yf)}_for(n,e){return this._blockNode(n),e&&this.code(e).endFor(),this}for(n,e){return this._for(new vf(n),e)}forRange(n,e,i,r,s=this.opts.es5?_i.varKinds.var:_i.varKinds.let){let l=this._scope.toName(n);return this._for(new bf(s,l,e,i),()=>r(l))}forOf(n,e,i,r=_i.varKinds.const){let s=this._scope.toName(n);if(this.opts.es5){let l=e instanceof Je.Name?e:this.var("_arr",e);return this.forRange("_i",0,(0,Je._)`${l}.length`,u=>{this.var(s,(0,Je._)`${l}[${u}]`),i(s)})}return this._for(new Zu("of",r,s,e),()=>i(s))}forIn(n,e,i,r=this.opts.es5?_i.varKinds.var:_i.varKinds.const){if(this.opts.ownProperties)return this.forOf(n,(0,Je._)`Object.keys(${e})`,i);let s=this._scope.toName(n);return this._for(new Zu("in",r,s,e),()=>i(s))}endFor(){return this._endBlockNode(Xu)}label(n){return this._leafNode(new ff(n))}break(n){return this._leafNode(new mf(n))}return(n){let e=new jv;if(this._blockNode(e),this.code(n),e.nodes.length!==1)throw new Error('CodeGen: "return" should have one node');return this._endBlockNode(jv)}try(n,e,i){if(!e&&!i)throw new Error('CodeGen: "try" without "catch" and "finally"');let r=new Cf;if(this._blockNode(r),this.code(n),e){let s=this.name("e");this._currNode=r.catch=new zv(s),e(s)}return i&&(this._currNode=r.finally=new Uv,this.code(i)),this._endBlockNode(zv,Uv)}throw(n){return this._leafNode(new hf(n))}block(n,e){return this._blockStarts.push(this._nodes.length),n&&this.code(n).endBlock(e),this}endBlock(n){let e=this._blockStarts.pop();if(e===void 0)throw new Error("CodeGen: not in self-balancing block");let i=this._nodes.length-e;if(i<0||n!==void 0&&i!==n)throw new Error(`CodeGen: wrong number of nodes: ${i} vs ${n} expected`);return this._nodes.length=e,this}func(n,e=Je.nil,i,r){return this._blockNode(new Lv(n,e,i)),r&&this.code(r).endFunc(),this}endFunc(){return this._endBlockNode(Lv)}optimize(n=1){for(;n-- >0;)this._root.optimizeNodes(),this._root.optimizeNames(this._root.names,this._constants)}_leafNode(n){return this._currNode.nodes.push(n),this}_blockNode(n){this._currNode.nodes.push(n),this._nodes.push(n)}_endBlockNode(n,e){let i=this._currNode;if(i instanceof n||e&&i instanceof e)return this._nodes.pop(),this;throw new Error(`CodeGen: not in block "${e?`${n.kind}/${e.kind}`:n.kind}"`)}_elseNode(n){let e=this._currNode;if(!(e instanceof Ku))throw new Error('CodeGen: "else" without "if"');return this._currNode=e.else=n,this}get _root(){return this._nodes[0]}get _currNode(){let n=this._nodes;return n[n.length-1]}set _currNode(n){let e=this._nodes;e[e.length-1]=n}};ze.CodeGen=xf;function po(t,n){for(let e in n)t[e]=(t[e]||0)+(n[e]||0);return t}function Yu(t,n){return n instanceof Je._CodeOrName?po(t,n.names):t}function Yo(t,n,e){if(t instanceof Je.Name)return i(t);if(!r(t))return t;return new Je._Code(t._items.reduce((s,l)=>(l instanceof Je.Name&&(l=i(l)),l instanceof Je._Code?s.push(...l._items):s.push(l),s),[]));function i(s){let l=e[s.str];return l===void 0||n[s.str]!==1?s:(delete n[s.str],l)}function r(s){return s instanceof Je._Code&&s._items.some(l=>l instanceof Je.Name&&n[l.str]===1&&e[l.str]!==void 0)}}function IV(t,n){for(let e in n)t[e]=(t[e]||0)-(n[e]||0)}function Hv(t){return typeof t=="boolean"||typeof t=="number"||t===null?!t:(0,Je._)`!${wf(t)}`}ze.not=Hv;var EV=Wv(ze.operators.AND);function PV(...t){return t.reduce(EV)}ze.and=PV;var DV=Wv(ze.operators.OR);function MV(...t){return t.reduce(DV)}ze.or=MV;function Wv(t){return(n,e)=>n===Je.nil?e:e===Je.nil?n:(0,Je._)`${wf(n)} ${t} ${wf(e)}`}function wf(t){return t instanceof Je.Name?t:(0,Je._)`(${t})`}});var We=x(Ue=>{"use strict";Object.defineProperty(Ue,"__esModule",{value:!0});Ue.checkStrictMode=Ue.getErrorPath=Ue.Type=Ue.useFunc=Ue.setEvaluated=Ue.evaluatedPropsToName=Ue.mergeEvaluated=Ue.eachItem=Ue.unescapeJsonPointer=Ue.escapeJsonPointer=Ue.escapeFragment=Ue.unescapeFragment=Ue.schemaRefOrVal=Ue.schemaHasRulesButRef=Ue.schemaHasRules=Ue.checkUnknownRules=Ue.alwaysValidSchema=Ue.toHash=void 0;var pt=we(),TV=ma();function $V(t){let n={};for(let e of t)n[e]=!0;return n}Ue.toHash=$V;function kV(t,n){return typeof n=="boolean"?n:Object.keys(n).length===0?!0:(Jv(t,n),!Zv(n,t.self.RULES.all))}Ue.alwaysValidSchema=kV;function Jv(t,n=t.schema){let{opts:e,self:i}=t;if(!e.strictSchema||typeof n=="boolean")return;let r=i.RULES.keywords;for(let s in n)r[s]||Xv(t,`unknown keyword: "${s}"`)}Ue.checkUnknownRules=Jv;function Zv(t,n){if(typeof t=="boolean")return!t;for(let e in t)if(n[e])return!0;return!1}Ue.schemaHasRules=Zv;function OV(t,n){if(typeof t=="boolean")return!t;for(let e in t)if(e!=="$ref"&&n.all[e])return!0;return!1}Ue.schemaHasRulesButRef=OV;function NV({topSchemaRef:t,schemaPath:n},e,i,r){if(!r){if(typeof e=="number"||typeof e=="boolean")return e;if(typeof e=="string")return(0,pt._)`${e}`}return(0,pt._)`${t}${n}${(0,pt.getProperty)(i)}`}Ue.schemaRefOrVal=NV;function RV(t){return Yv(decodeURIComponent(t))}Ue.unescapeFragment=RV;function AV(t){return encodeURIComponent(If(t))}Ue.escapeFragment=AV;function If(t){return typeof t=="number"?`${t}`:t.replace(/~/g,"~0").replace(/\//g,"~1")}Ue.escapeJsonPointer=If;function Yv(t){return t.replace(/~1/g,"/").replace(/~0/g,"~")}Ue.unescapeJsonPointer=Yv;function FV(t,n){if(Array.isArray(t))for(let e of t)n(e);else n(t)}Ue.eachItem=FV;function Gv({mergeNames:t,mergeToName:n,mergeValues:e,resultToName:i}){return(r,s,l,u)=>{let d=l===void 0?s:l instanceof pt.Name?(s instanceof pt.Name?t(r,s,l):n(r,s,l),l):s instanceof pt.Name?(n(r,l,s),s):e(s,l);return u===pt.Name&&!(d instanceof pt.Name)?i(r,d):d}}Ue.mergeEvaluated={props:Gv({mergeNames:(t,n,e)=>t.if((0,pt._)`${e} !== true && ${n} !== undefined`,()=>{t.if((0,pt._)`${n} === true`,()=>t.assign(e,!0),()=>t.assign(e,(0,pt._)`${e} || {}`).code((0,pt._)`Object.assign(${e}, ${n})`))}),mergeToName:(t,n,e)=>t.if((0,pt._)`${e} !== true`,()=>{n===!0?t.assign(e,!0):(t.assign(e,(0,pt._)`${e} || {}`),Ef(t,e,n))}),mergeValues:(t,n)=>t===!0?!0:pe(pe({},t),n),resultToName:Qv}),items:Gv({mergeNames:(t,n,e)=>t.if((0,pt._)`${e} !== true && ${n} !== undefined`,()=>t.assign(e,(0,pt._)`${n} === true ? true : ${e} > ${n} ? ${e} : ${n}`)),mergeToName:(t,n,e)=>t.if((0,pt._)`${e} !== true`,()=>t.assign(e,n===!0?!0:(0,pt._)`${e} > ${n} ? ${e} : ${n}`)),mergeValues:(t,n)=>t===!0?!0:Math.max(t,n),resultToName:(t,n)=>t.var("items",n)})};function Qv(t,n){if(n===!0)return t.var("props",!0);let e=t.var("props",(0,pt._)`{}`);return n!==void 0&&Ef(t,e,n),e}Ue.evaluatedPropsToName=Qv;function Ef(t,n,e){Object.keys(e).forEach(i=>t.assign((0,pt._)`${n}${(0,pt.getProperty)(i)}`,!0))}Ue.setEvaluated=Ef;var Kv={};function VV(t,n){return t.scopeValue("func",{ref:n,code:Kv[n.code]||(Kv[n.code]=new TV._Code(n.code))})}Ue.useFunc=VV;var Sf=(function(t){return t[t.Num=0]="Num",t[t.Str=1]="Str",t})(Sf||(Ue.Type=Sf={}));function BV(t,n,e){if(t instanceof pt.Name){let i=n===Sf.Num;return e?i?(0,pt._)`"[" + ${t} + "]"`:(0,pt._)`"['" + ${t} + "']"`:i?(0,pt._)`"/" + ${t}`:(0,pt._)`"/" + ${t}.replace(/~/g, "~0").replace(/\\//g, "~1")`}return e?(0,pt.getProperty)(t).toString():"/"+If(t)}Ue.getErrorPath=BV;function Xv(t,n,e=t.opts.strictSchema){if(e){if(n=`strict mode: ${n}`,e===!0)throw new Error(n);t.self.logger.warn(n)}}Ue.checkStrictMode=Xv});var ii=x(Pf=>{"use strict";Object.defineProperty(Pf,"__esModule",{value:!0});var ln=we(),qV={data:new ln.Name("data"),valCxt:new ln.Name("valCxt"),instancePath:new ln.Name("instancePath"),parentData:new ln.Name("parentData"),parentDataProperty:new ln.Name("parentDataProperty"),rootData:new ln.Name("rootData"),dynamicAnchors:new ln.Name("dynamicAnchors"),vErrors:new ln.Name("vErrors"),errors:new ln.Name("errors"),this:new ln.Name("this"),self:new ln.Name("self"),scope:new ln.Name("scope"),json:new ln.Name("json"),jsonPos:new ln.Name("jsonPos"),jsonLen:new ln.Name("jsonLen"),jsonPart:new ln.Name("jsonPart")};Pf.default=qV});var ga=x(un=>{"use strict";Object.defineProperty(un,"__esModule",{value:!0});un.extendErrors=un.resetErrorsCount=un.reportExtraError=un.reportError=un.keyword$DataError=un.keywordError=void 0;var Ze=we(),ec=We(),yn=ii();un.keywordError={message:({keyword:t})=>(0,Ze.str)`must pass "${t}" keyword validation`};un.keyword$DataError={message:({keyword:t,schemaType:n})=>n?(0,Ze.str)`"${t}" keyword must be ${n} ($data)`:(0,Ze.str)`"${t}" keyword is invalid ($data)`};function LV(t,n=un.keywordError,e,i){let{it:r}=t,{gen:s,compositeRule:l,allErrors:u}=r,d=nb(t,n,e);i??(l||u)?eb(s,d):tb(r,(0,Ze._)`[${d}]`)}un.reportError=LV;function jV(t,n=un.keywordError,e){let{it:i}=t,{gen:r,compositeRule:s,allErrors:l}=i,u=nb(t,n,e);eb(r,u),s||l||tb(i,yn.default.vErrors)}un.reportExtraError=jV;function zV(t,n){t.assign(yn.default.errors,n),t.if((0,Ze._)`${yn.default.vErrors} !== null`,()=>t.if(n,()=>t.assign((0,Ze._)`${yn.default.vErrors}.length`,n),()=>t.assign(yn.default.vErrors,null)))}un.resetErrorsCount=zV;function UV({gen:t,keyword:n,schemaValue:e,data:i,errsCount:r,it:s}){if(r===void 0)throw new Error("ajv implementation error");let l=t.name("err");t.forRange("i",r,yn.default.errors,u=>{t.const(l,(0,Ze._)`${yn.default.vErrors}[${u}]`),t.if((0,Ze._)`${l}.instancePath === undefined`,()=>t.assign((0,Ze._)`${l}.instancePath`,(0,Ze.strConcat)(yn.default.instancePath,s.errorPath))),t.assign((0,Ze._)`${l}.schemaPath`,(0,Ze.str)`${s.errSchemaPath}/${n}`),s.opts.verbose&&(t.assign((0,Ze._)`${l}.schema`,e),t.assign((0,Ze._)`${l}.data`,i))})}un.extendErrors=UV;function eb(t,n){let e=t.const("err",n);t.if((0,Ze._)`${yn.default.vErrors} === null`,()=>t.assign(yn.default.vErrors,(0,Ze._)`[${e}]`),(0,Ze._)`${yn.default.vErrors}.push(${e})`),t.code((0,Ze._)`${yn.default.errors}++`)}function tb(t,n){let{gen:e,validateName:i,schemaEnv:r}=t;r.$async?e.throw((0,Ze._)`new ${t.ValidationError}(${n})`):(e.assign((0,Ze._)`${i}.errors`,n),e.return(!1))}var fo={keyword:new Ze.Name("keyword"),schemaPath:new Ze.Name("schemaPath"),params:new Ze.Name("params"),propertyName:new Ze.Name("propertyName"),message:new Ze.Name("message"),schema:new Ze.Name("schema"),parentSchema:new Ze.Name("parentSchema")};function nb(t,n,e){let{createErrors:i}=t.it;return i===!1?(0,Ze._)`{}`:HV(t,n,e)}function HV(t,n,e={}){let{gen:i,it:r}=t,s=[WV(r,e),GV(t,e)];return KV(t,n,s),i.object(...s)}function WV({errorPath:t},{instancePath:n}){let e=n?(0,Ze.str)`${t}${(0,ec.getErrorPath)(n,ec.Type.Str)}`:t;return[yn.default.instancePath,(0,Ze.strConcat)(yn.default.instancePath,e)]}function GV({keyword:t,it:{errSchemaPath:n}},{schemaPath:e,parentSchema:i}){let r=i?n:(0,Ze.str)`${n}/${t}`;return e&&(r=(0,Ze.str)`${r}${(0,ec.getErrorPath)(e,ec.Type.Str)}`),[fo.schemaPath,r]}function KV(t,{params:n,message:e},i){let{keyword:r,data:s,schemaValue:l,it:u}=t,{opts:d,propertyName:f,topSchemaRef:g,schemaPath:b}=u;i.push([fo.keyword,r],[fo.params,typeof n=="function"?n(t):n||(0,Ze._)`{}`]),d.messages&&i.push([fo.message,typeof e=="function"?e(t):e]),d.verbose&&i.push([fo.schema,l],[fo.parentSchema,(0,Ze._)`${g}${b}`],[yn.default.data,s]),f&&i.push([fo.propertyName,f])}});var rb=x(Qo=>{"use strict";Object.defineProperty(Qo,"__esModule",{value:!0});Qo.boolOrEmptySchema=Qo.topBoolOrEmptySchema=void 0;var JV=ga(),ZV=we(),YV=ii(),QV={message:"boolean schema is false"};function XV(t){let{gen:n,schema:e,validateName:i}=t;e===!1?ib(t,!1):typeof e=="object"&&e.$async===!0?n.return(YV.default.data):(n.assign((0,ZV._)`${i}.errors`,null),n.return(!0))}Qo.topBoolOrEmptySchema=XV;function eB(t,n){let{gen:e,schema:i}=t;i===!1?(e.var(n,!1),ib(t)):e.var(n,!0)}Qo.boolOrEmptySchema=eB;function ib(t,n){let{gen:e,data:i}=t,r={gen:e,keyword:"false schema",data:i,schema:!1,schemaCode:!1,schemaValue:!1,params:{},it:t};(0,JV.reportError)(r,QV,void 0,n)}});var Df=x(Xo=>{"use strict";Object.defineProperty(Xo,"__esModule",{value:!0});Xo.getRules=Xo.isJSONType=void 0;var tB=["string","number","integer","boolean","null","object","array"],nB=new Set(tB);function iB(t){return typeof t=="string"&&nB.has(t)}Xo.isJSONType=iB;function rB(){let t={number:{type:"number",rules:[]},string:{type:"string",rules:[]},array:{type:"array",rules:[]},object:{type:"object",rules:[]}};return{types:xe(pe({},t),{integer:!0,boolean:!0,null:!0}),rules:[{rules:[]},t.number,t.string,t.array,t.object],post:{rules:[]},all:{},keywords:{}}}Xo.getRules=rB});var Mf=x(Ar=>{"use strict";Object.defineProperty(Ar,"__esModule",{value:!0});Ar.shouldUseRule=Ar.shouldUseGroup=Ar.schemaHasRulesForType=void 0;function oB({schema:t,self:n},e){let i=n.RULES.types[e];return i&&i!==!0&&ob(t,i)}Ar.schemaHasRulesForType=oB;function ob(t,n){return n.rules.some(e=>sb(t,e))}Ar.shouldUseGroup=ob;function sb(t,n){var e;return t[n.keyword]!==void 0||((e=n.definition.implements)===null||e===void 0?void 0:e.some(i=>t[i]!==void 0))}Ar.shouldUseRule=sb});var _a=x(cn=>{"use strict";Object.defineProperty(cn,"__esModule",{value:!0});cn.reportTypeError=cn.checkDataTypes=cn.checkDataType=cn.coerceAndCheckDataType=cn.getJSONTypes=cn.getSchemaTypes=cn.DataType=void 0;var sB=Df(),aB=Mf(),lB=ga(),Fe=we(),ab=We(),es=(function(t){return t[t.Correct=0]="Correct",t[t.Wrong=1]="Wrong",t})(es||(cn.DataType=es={}));function uB(t){let n=lb(t.type);if(n.includes("null")){if(t.nullable===!1)throw new Error("type: null contradicts nullable: false")}else{if(!n.length&&t.nullable!==void 0)throw new Error('"nullable" cannot be used without "type"');t.nullable===!0&&n.push("null")}return n}cn.getSchemaTypes=uB;function lb(t){let n=Array.isArray(t)?t:t?[t]:[];if(n.every(sB.isJSONType))return n;throw new Error("type must be JSONType or JSONType[]: "+n.join(","))}cn.getJSONTypes=lb;function cB(t,n){let{gen:e,data:i,opts:r}=t,s=dB(n,r.coerceTypes),l=n.length>0&&!(s.length===0&&n.length===1&&(0,aB.schemaHasRulesForType)(t,n[0]));if(l){let u=$f(n,i,r.strictNumbers,es.Wrong);e.if(u,()=>{s.length?pB(t,n,s):kf(t)})}return l}cn.coerceAndCheckDataType=cB;var ub=new Set(["string","number","integer","boolean","null"]);function dB(t,n){return n?t.filter(e=>ub.has(e)||n==="array"&&e==="array"):[]}function pB(t,n,e){let{gen:i,data:r,opts:s}=t,l=i.let("dataType",(0,Fe._)`typeof ${r}`),u=i.let("coerced",(0,Fe._)`undefined`);s.coerceTypes==="array"&&i.if((0,Fe._)`${l} == 'object' && Array.isArray(${r}) && ${r}.length == 1`,()=>i.assign(r,(0,Fe._)`${r}[0]`).assign(l,(0,Fe._)`typeof ${r}`).if($f(n,r,s.strictNumbers),()=>i.assign(u,r))),i.if((0,Fe._)`${u} !== undefined`);for(let f of e)(ub.has(f)||f==="array"&&s.coerceTypes==="array")&&d(f);i.else(),kf(t),i.endIf(),i.if((0,Fe._)`${u} !== undefined`,()=>{i.assign(r,u),fB(t,u)});function d(f){switch(f){case"string":i.elseIf((0,Fe._)`${l} == "number" || ${l} == "boolean"`).assign(u,(0,Fe._)`"" + ${r}`).elseIf((0,Fe._)`${r} === null`).assign(u,(0,Fe._)`""`);return;case"number":i.elseIf((0,Fe._)`${l} == "boolean" || ${r} === null
|
|
3
3
|
|| (${l} == "string" && ${r} && ${r} == +${r})`).assign(u,(0,Fe._)`+${r}`);return;case"integer":i.elseIf((0,Fe._)`${l} === "boolean" || ${r} === null
|
|
4
4
|
|| (${l} === "string" && ${r} && ${r} == +${r} && !(${r} % 1))`).assign(u,(0,Fe._)`+${r}`);return;case"boolean":i.elseIf((0,Fe._)`${r} === "false" || ${r} === 0 || ${r} === null`).assign(u,!1).elseIf((0,Fe._)`${r} === "true" || ${r} === 1`).assign(u,!0);return;case"null":i.elseIf((0,Fe._)`${r} === "" || ${r} === 0 || ${r} === false`),i.assign(u,null);return;case"array":i.elseIf((0,Fe._)`${l} === "string" || ${l} === "number"
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as l}from"./chunk-
|
|
1
|
+
import{a as l}from"./chunk-QPYSLZDC.js";import{a as m}from"./chunk-3ND4FTJL.js";import{n as o}from"./chunk-GAI5J4YQ.js";import{b as i}from"./chunk-CAB2VD3D.js";import{E as s}from"./chunk-MW6H5Z5G.js";import{X as r,aa as n}from"./chunk-ZPXACREZ.js";var I=(()=>{class e{$terminal=n(l);$settings=n(i);$modal=n(o);$translate=n(s);handleBeforeUnload(t){if(!this.$settings.env.terminal?.persistence&&!this.$settings.env.terminal?.hideWarning&&this.$terminal.hasActiveSession()&&this.$terminal.hasUserTypedInSession()){let a=this.$translate.instant("platform.terminal.terminate_unload");return t.preventDefault(),t.returnValue=a,a}}canDeactivate(){if(this.$settings.env.terminal?.persistence||this.$settings.env.terminal?.hideWarning||!this.$terminal.hasActiveSession()||!this.$terminal.hasUserTypedInSession())return!0;let t=this.$modal.open(m,{size:"lg",backdrop:"static"});return t.componentInstance.title=this.$translate.instant("platform.terminal.terminate_title"),t.componentInstance.message=this.$translate.instant("platform.terminal.terminate_message_1"),t.componentInstance.message2=this.$translate.instant("platform.terminal.terminate_message_2"),t.componentInstance.message3=this.$translate.instant("common.phrases.are_you_sure"),t.componentInstance.confirmButtonLabel=this.$translate.instant("form.button_continue"),t.componentInstance.confirmButtonClass="btn-primary",t.componentInstance.faIconClass="fas fa-exclamation-triangle text-warning",t.result.then(()=>!0).catch(()=>!1)}static \u0275fac=function(a){return new(a||e)};static \u0275prov=r({token:e,factory:e.\u0275fac,providedIn:"root"})}return e})();export{I as a};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{e as a}from"./chunk-
|
|
1
|
+
import{e as a}from"./chunk-ZAKTSIL5.js";import{E as n,H as p,K as i}from"./chunk-MW6H5Z5G.js";import{aa as r}from"./chunk-ZPXACREZ.js";import{h as o}from"./chunk-B4AJQJMI.js";var c=()=>o(null,null,function*(){let t=r(i),s=r(a),m=r(p),h=r(n);try{return yield t.get("/platform-tools/docker/startup-script")}catch(e){console.error(e),m.error(e.message,h.instant("toast.title_error")),s.navigate(["/"]);return}});var R=[{path:"",redirectTo:"/",pathMatch:"full"},{path:"docker",children:[{path:"",redirectTo:"/",pathMatch:"full"},{path:"startup-script",loadComponent:()=>import("./chunk-VTSSBPGB.js").then(t=>t.StartupScriptComponent),resolve:{startupScript:c}},{path:"restart-container",loadComponent:()=>import("./chunk-FOAHTHQO.js").then(t=>t.ContainerRestartComponent)}]},{path:"linux",children:[{path:"",redirectTo:"/",pathMatch:"full"},{path:"restart-server",loadComponent:()=>import("./chunk-FDD3SM5M.js").then(t=>t.RestartLinuxComponent)},{path:"shutdown-server",loadComponent:()=>import("./chunk-4KYVPUTG.js").then(t=>t.ShutdownLinuxComponent)}]},{path:"terminal",loadComponent:()=>import("./chunk-BRUFPV4S.js").then(t=>t.TerminalComponent),canDeactivate:[t=>t.canDeactivate?t.canDeactivate():!0]}];export{R as PLATFORM_TOOLS_ROUTES};
|