@checksum-ai/runtime 1.1.38 → 1.1.39
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/checksumlib.js +9 -1
- package/cli.js +55 -52
- package/index.d.helpers.ts +14 -0
- package/index.d.ts +4 -10
- package/index.js +64 -64
- package/package.json +1 -1
- package/test-run-monitor.js +5 -5
- package/vtg-build/asset-manifest.json +3 -3
- package/vtg-build/index.html +1 -1
- package/vtg-build/static/js/main.834cf05e.js +103 -0
- package/vtg-build/static/js/main.834cf05e.js.LICENSE.txt +118 -0
- package/vtg-build/static/js/main.834cf05e.js.map +1 -0
- package/vtg-build/static/js/main.c055edb4.js +103 -0
- package/vtg-build/static/js/main.c055edb4.js.LICENSE.txt +118 -0
- package/vtg-build/static/js/main.c055edb4.js.map +1 -0
package/test-run-monitor.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";var qb=Object.create;var Mn=Object.defineProperty;var Ub=Object.getOwnPropertyDescriptor;var Mb=Object.getOwnPropertyNames;var Wb=Object.getPrototypeOf,Nb=Object.prototype.hasOwnProperty;var Uf=e=>{throw TypeError(e)};var a=(e,t)=>Mn(e,"name",{value:t,configurable:!0});var Wn=(e,t)=>()=>(e&&(t=e(e=0)),t);var P=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),Mf=(e,t)=>{for(var r in t)Mn(e,r,{get:t[r],enumerable:!0})},Wf=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let o of Mb(t))!Nb.call(e,o)&&o!==r&&Mn(e,o,{get:()=>t[o],enumerable:!(n=Ub(t,o))||n.enumerable});return e};var Fe=(e,t,r)=>(r=e!=null?qb(Wb(e)):{},Wf(t||!e||!e.__esModule?Mn(r,"default",{value:e,enumerable:!0}):r,e)),jb=e=>Wf(Mn({},"__esModule",{value:!0}),e);var Nf=(e,t,r)=>t.has(e)||Uf("Cannot "+r);var te=(e,t,r)=>(Nf(e,t,"read from private field"),r?r.call(e):t.get(e)),Ze=(e,t,r)=>t.has(e)?Uf("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,r),Se=(e,t,r,n)=>(Nf(e,t,"write to private field"),n?n.call(e,r):t.set(e,r),r);var $f=P((sa,Hf)=>{(function(e,t){typeof sa=="object"&&typeof Hf<"u"?t(sa):typeof define=="function"&&define.amd?define(["exports"],t):(e=typeof globalThis<"u"?globalThis:e||self,t(e.WebStreamsPolyfill={}))})(sa,function(e){"use strict";function t(){}a(t,"noop");function r(i){return typeof i=="object"&&i!==null||typeof i=="function"}a(r,"typeIsObject");let n=t;function o(i,s){try{Object.defineProperty(i,"name",{value:s,configurable:!0})}catch{}}a(o,"setFunctionName");let l=Promise,u=Promise.prototype.then,d=Promise.reject.bind(l);function m(i){return new l(i)}a(m,"newPromise");function c(i){return m(s=>s(i))}a(c,"promiseResolvedWith");function h(i){return d(i)}a(h,"promiseRejectedWith");function x(i,s,f){return u.call(i,s,f)}a(x,"PerformPromiseThen");function y(i,s,f){x(x(i,s,f),void 0,n)}a(y,"uponPromise");function w(i,s){y(i,s)}a(w,"uponFulfillment");function v(i,s){y(i,void 0,s)}a(v,"uponRejection");function E(i,s,f){return x(i,s,f)}a(E,"transformPromiseWith");function k(i){x(i,void 0,n)}a(k,"setPromiseIsHandledToTrue");let S=a(i=>{if(typeof queueMicrotask=="function")S=queueMicrotask;else{let s=c(void 0);S=a(f=>x(s,f),"_queueMicrotask")}return S(i)},"_queueMicrotask");function A(i,s,f){if(typeof i!="function")throw new TypeError("Argument is not a function");return Function.prototype.apply.call(i,s,f)}a(A,"reflectCall");function C(i,s,f){try{return c(A(i,s,f))}catch(p){return h(p)}}a(C,"promiseCall");let R=16384,Qo=class Qo{constructor(){this._cursor=0,this._size=0,this._front={_elements:[],_next:void 0},this._back=this._front,this._cursor=0,this._size=0}get length(){return this._size}push(s){let f=this._back,p=f;f._elements.length===R-1&&(p={_elements:[],_next:void 0}),f._elements.push(s),p!==f&&(this._back=p,f._next=p),++this._size}shift(){let s=this._front,f=s,p=this._cursor,g=p+1,b=s._elements,_=b[p];return g===R&&(f=s._next,g=0),--this._size,this._cursor=g,s!==f&&(this._front=f),b[p]=void 0,_}forEach(s){let f=this._cursor,p=this._front,g=p._elements;for(;(f!==g.length||p._next!==void 0)&&!(f===g.length&&(p=p._next,g=p._elements,f=0,g.length===0));)s(g[f]),++f}peek(){let s=this._front,f=this._cursor;return s._elements[f]}};a(Qo,"SimpleQueue");let T=Qo,F=Symbol("[[AbortSteps]]"),z=Symbol("[[ErrorSteps]]"),B=Symbol("[[CancelSteps]]"),M=Symbol("[[PullSteps]]"),V=Symbol("[[ReleaseSteps]]");function O(i,s){i._ownerReadableStream=s,s._reader=i,s._state==="readable"?Or(i):s._state==="closed"?Dr(i):Cn(i,s._storedError)}a(O,"ReadableStreamReaderGenericInitialize");function le(i,s){let f=i._ownerReadableStream;return He(f,s)}a(le,"ReadableStreamReaderGenericCancel");function ce(i){let s=i._ownerReadableStream;s._state==="readable"?Bt(i,new TypeError("Reader was released and can no longer be used to monitor the stream's closedness")):Ym(i,new TypeError("Reader was released and can no longer be used to monitor the stream's closedness")),s._readableStreamController[V](),s._reader=void 0,i._ownerReadableStream=void 0}a(ce,"ReadableStreamReaderGenericRelease");function mt(i){return new TypeError("Cannot "+i+" a stream using a released reader")}a(mt,"readerLockException");function Or(i){i._closedPromise=m((s,f)=>{i._closedPromise_resolve=s,i._closedPromise_reject=f})}a(Or,"defaultReaderClosedPromiseInitialize");function Cn(i,s){Or(i),Bt(i,s)}a(Cn,"defaultReaderClosedPromiseInitializeAsRejected");function Dr(i){Or(i),xu(i)}a(Dr,"defaultReaderClosedPromiseInitializeAsResolved");function Bt(i,s){i._closedPromise_reject!==void 0&&(k(i._closedPromise),i._closedPromise_reject(s),i._closedPromise_resolve=void 0,i._closedPromise_reject=void 0)}a(Bt,"defaultReaderClosedPromiseReject");function Ym(i,s){Cn(i,s)}a(Ym,"defaultReaderClosedPromiseResetToRejected");function xu(i){i._closedPromise_resolve!==void 0&&(i._closedPromise_resolve(void 0),i._closedPromise_resolve=void 0,i._closedPromise_reject=void 0)}a(xu,"defaultReaderClosedPromiseResolve");let Au=Number.isFinite||function(i){return typeof i=="number"&&isFinite(i)},Km=Math.trunc||function(i){return i<0?Math.ceil(i):Math.floor(i)};function Xm(i){return typeof i=="object"||typeof i=="function"}a(Xm,"isDictionary");function et(i,s){if(i!==void 0&&!Xm(i))throw new TypeError(`${s} is not an object.`)}a(et,"assertDictionary");function Ce(i,s){if(typeof i!="function")throw new TypeError(`${s} is not a function.`)}a(Ce,"assertFunction");function Jm(i){return typeof i=="object"&&i!==null||typeof i=="function"}a(Jm,"isObject");function ku(i,s){if(!Jm(i))throw new TypeError(`${s} is not an object.`)}a(ku,"assertObject");function gt(i,s,f){if(i===void 0)throw new TypeError(`Parameter ${s} is required in '${f}'.`)}a(gt,"assertRequiredArgument");function _o(i,s,f){if(i===void 0)throw new TypeError(`${s} is required in '${f}'.`)}a(_o,"assertRequiredField");function vo(i){return Number(i)}a(vo,"convertUnrestrictedDouble");function Eu(i){return i===0?0:i}a(Eu,"censorNegativeZero");function Qm(i){return Eu(Km(i))}a(Qm,"integerPart");function wo(i,s){let p=Number.MAX_SAFE_INTEGER,g=Number(i);if(g=Eu(g),!Au(g))throw new TypeError(`${s} is not a finite number`);if(g=Qm(g),g<0||g>p)throw new TypeError(`${s} is outside the accepted range of 0 to ${p}, inclusive`);return!Au(g)||g===0?0:g}a(wo,"convertUnsignedLongLongWithEnforceRange");function So(i,s){if(!Mt(i))throw new TypeError(`${s} is not a ReadableStream.`)}a(So,"assertReadableStream");function Br(i){return new tt(i)}a(Br,"AcquireReadableStreamDefaultReader");function Cu(i,s){i._reader._readRequests.push(s)}a(Cu,"ReadableStreamAddReadRequest");function Ro(i,s,f){let g=i._reader._readRequests.shift();f?g._closeSteps():g._chunkSteps(s)}a(Ro,"ReadableStreamFulfillReadRequest");function Di(i){return i._reader._readRequests.length}a(Di,"ReadableStreamGetNumReadRequests");function Pu(i){let s=i._reader;return!(s===void 0||!Lt(s))}a(Pu,"ReadableStreamHasDefaultReader");let es=class es{constructor(s){if(gt(s,1,"ReadableStreamDefaultReader"),So(s,"First parameter"),Wt(s))throw new TypeError("This stream has already been locked for exclusive reading by another reader");O(this,s),this._readRequests=new T}get closed(){return Lt(this)?this._closedPromise:h(Bi("closed"))}cancel(s=void 0){return Lt(this)?this._ownerReadableStream===void 0?h(mt("cancel")):le(this,s):h(Bi("cancel"))}read(){if(!Lt(this))return h(Bi("read"));if(this._ownerReadableStream===void 0)return h(mt("read from"));let s,f,p=m((b,_)=>{s=b,f=_});return Pn(this,{_chunkSteps:a(b=>s({value:b,done:!1}),"_chunkSteps"),_closeSteps:a(()=>s({value:void 0,done:!0}),"_closeSteps"),_errorSteps:a(b=>f(b),"_errorSteps")}),p}releaseLock(){if(!Lt(this))throw Bi("releaseLock");this._ownerReadableStream!==void 0&&eg(this)}};a(es,"ReadableStreamDefaultReader");let tt=es;Object.defineProperties(tt.prototype,{cancel:{enumerable:!0},read:{enumerable:!0},releaseLock:{enumerable:!0},closed:{enumerable:!0}}),o(tt.prototype.cancel,"cancel"),o(tt.prototype.read,"read"),o(tt.prototype.releaseLock,"releaseLock"),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(tt.prototype,Symbol.toStringTag,{value:"ReadableStreamDefaultReader",configurable:!0});function Lt(i){return!r(i)||!Object.prototype.hasOwnProperty.call(i,"_readRequests")?!1:i instanceof tt}a(Lt,"IsReadableStreamDefaultReader");function Pn(i,s){let f=i._ownerReadableStream;f._disturbed=!0,f._state==="closed"?s._closeSteps():f._state==="errored"?s._errorSteps(f._storedError):f._readableStreamController[M](s)}a(Pn,"ReadableStreamDefaultReaderRead");function eg(i){ce(i);let s=new TypeError("Reader was released");Iu(i,s)}a(eg,"ReadableStreamDefaultReaderRelease");function Iu(i,s){let f=i._readRequests;i._readRequests=new T,f.forEach(p=>{p._errorSteps(s)})}a(Iu,"ReadableStreamDefaultReaderErrorReadRequests");function Bi(i){return new TypeError(`ReadableStreamDefaultReader.prototype.${i} can only be used on a ReadableStreamDefaultReader`)}a(Bi,"defaultReaderBrandCheckException");let tg=Object.getPrototypeOf(Object.getPrototypeOf(async function*(){}).prototype),ts=class ts{constructor(s,f){this._ongoingPromise=void 0,this._isFinished=!1,this._reader=s,this._preventCancel=f}next(){let s=a(()=>this._nextSteps(),"nextSteps");return this._ongoingPromise=this._ongoingPromise?E(this._ongoingPromise,s,s):s(),this._ongoingPromise}return(s){let f=a(()=>this._returnSteps(s),"returnSteps");return this._ongoingPromise?E(this._ongoingPromise,f,f):f()}_nextSteps(){if(this._isFinished)return Promise.resolve({value:void 0,done:!0});let s=this._reader,f,p,g=m((_,I)=>{f=_,p=I});return Pn(s,{_chunkSteps:a(_=>{this._ongoingPromise=void 0,S(()=>f({value:_,done:!1}))},"_chunkSteps"),_closeSteps:a(()=>{this._ongoingPromise=void 0,this._isFinished=!0,ce(s),f({value:void 0,done:!0})},"_closeSteps"),_errorSteps:a(_=>{this._ongoingPromise=void 0,this._isFinished=!0,ce(s),p(_)},"_errorSteps")}),g}_returnSteps(s){if(this._isFinished)return Promise.resolve({value:s,done:!0});this._isFinished=!0;let f=this._reader;if(!this._preventCancel){let p=le(f,s);return ce(f),E(p,()=>({value:s,done:!0}))}return ce(f),c({value:s,done:!0})}};a(ts,"ReadableStreamAsyncIteratorImpl");let Li=ts,Fu={next(){return Ou(this)?this._asyncIteratorImpl.next():h(Du("next"))},return(i){return Ou(this)?this._asyncIteratorImpl.return(i):h(Du("return"))}};Object.setPrototypeOf(Fu,tg);function rg(i,s){let f=Br(i),p=new Li(f,s),g=Object.create(Fu);return g._asyncIteratorImpl=p,g}a(rg,"AcquireReadableStreamAsyncIterator");function Ou(i){if(!r(i)||!Object.prototype.hasOwnProperty.call(i,"_asyncIteratorImpl"))return!1;try{return i._asyncIteratorImpl instanceof Li}catch{return!1}}a(Ou,"IsReadableStreamAsyncIterator");function Du(i){return new TypeError(`ReadableStreamAsyncIterator.${i} can only be used on a ReadableSteamAsyncIterator`)}a(Du,"streamAsyncIteratorBrandCheckException");let Bu=Number.isNaN||function(i){return i!==i};var To,xo,Ao;function In(i){return i.slice()}a(In,"CreateArrayFromList");function Lu(i,s,f,p,g){new Uint8Array(i).set(new Uint8Array(f,p,g),s)}a(Lu,"CopyDataBlockBytes");let bt=a(i=>(typeof i.transfer=="function"?bt=a(s=>s.transfer(),"TransferArrayBuffer"):typeof structuredClone=="function"?bt=a(s=>structuredClone(s,{transfer:[s]}),"TransferArrayBuffer"):bt=a(s=>s,"TransferArrayBuffer"),bt(i)),"TransferArrayBuffer"),zt=a(i=>(typeof i.detached=="boolean"?zt=a(s=>s.detached,"IsDetachedBuffer"):zt=a(s=>s.byteLength===0,"IsDetachedBuffer"),zt(i)),"IsDetachedBuffer");function zu(i,s,f){if(i.slice)return i.slice(s,f);let p=f-s,g=new ArrayBuffer(p);return Lu(g,0,i,s,p),g}a(zu,"ArrayBufferSlice");function zi(i,s){let f=i[s];if(f!=null){if(typeof f!="function")throw new TypeError(`${String(s)} is not a function`);return f}}a(zi,"GetMethod");function ng(i){let s={[Symbol.iterator]:()=>i.iterator},f=async function*(){return yield*s}(),p=f.next;return{iterator:f,nextMethod:p,done:!1}}a(ng,"CreateAsyncFromSyncIterator");let ko=(Ao=(To=Symbol.asyncIterator)!==null&&To!==void 0?To:(xo=Symbol.for)===null||xo===void 0?void 0:xo.call(Symbol,"Symbol.asyncIterator"))!==null&&Ao!==void 0?Ao:"@@asyncIterator";function qu(i,s="sync",f){if(f===void 0)if(s==="async"){if(f=zi(i,ko),f===void 0){let b=zi(i,Symbol.iterator),_=qu(i,"sync",b);return ng(_)}}else f=zi(i,Symbol.iterator);if(f===void 0)throw new TypeError("The object is not iterable");let p=A(f,i,[]);if(!r(p))throw new TypeError("The iterator method must return an object");let g=p.next;return{iterator:p,nextMethod:g,done:!1}}a(qu,"GetIterator");function ig(i){let s=A(i.nextMethod,i.iterator,[]);if(!r(s))throw new TypeError("The iterator.next() method must return an object");return s}a(ig,"IteratorNext");function ag(i){return!!i.done}a(ag,"IteratorComplete");function og(i){return i.value}a(og,"IteratorValue");function sg(i){return!(typeof i!="number"||Bu(i)||i<0)}a(sg,"IsNonNegativeNumber");function Uu(i){let s=zu(i.buffer,i.byteOffset,i.byteOffset+i.byteLength);return new Uint8Array(s)}a(Uu,"CloneAsUint8Array");function Eo(i){let s=i._queue.shift();return i._queueTotalSize-=s.size,i._queueTotalSize<0&&(i._queueTotalSize=0),s.value}a(Eo,"DequeueValue");function Co(i,s,f){if(!sg(f)||f===1/0)throw new RangeError("Size must be a finite, non-NaN, non-negative number.");i._queue.push({value:s,size:f}),i._queueTotalSize+=f}a(Co,"EnqueueValueWithSize");function lg(i){return i._queue.peek().value}a(lg,"PeekQueueValue");function qt(i){i._queue=new T,i._queueTotalSize=0}a(qt,"ResetQueue");function Mu(i){return i===DataView}a(Mu,"isDataViewConstructor");function ug(i){return Mu(i.constructor)}a(ug,"isDataView");function fg(i){return Mu(i)?1:i.BYTES_PER_ELEMENT}a(fg,"arrayBufferViewElementSize");let rs=class rs{constructor(){throw new TypeError("Illegal constructor")}get view(){if(!Po(this))throw Bo("view");return this._view}respond(s){if(!Po(this))throw Bo("respond");if(gt(s,1,"respond"),s=wo(s,"First parameter"),this._associatedReadableByteStreamController===void 0)throw new TypeError("This BYOB request has been invalidated");if(zt(this._view.buffer))throw new TypeError("The BYOB request's buffer has been detached and so cannot be used as a response");Wi(this._associatedReadableByteStreamController,s)}respondWithNewView(s){if(!Po(this))throw Bo("respondWithNewView");if(gt(s,1,"respondWithNewView"),!ArrayBuffer.isView(s))throw new TypeError("You can only respond with array buffer views");if(this._associatedReadableByteStreamController===void 0)throw new TypeError("This BYOB request has been invalidated");if(zt(s.buffer))throw new TypeError("The given view's buffer has been detached and so cannot be used as a response");Ni(this._associatedReadableByteStreamController,s)}};a(rs,"ReadableStreamBYOBRequest");let yt=rs;Object.defineProperties(yt.prototype,{respond:{enumerable:!0},respondWithNewView:{enumerable:!0},view:{enumerable:!0}}),o(yt.prototype.respond,"respond"),o(yt.prototype.respondWithNewView,"respondWithNewView"),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(yt.prototype,Symbol.toStringTag,{value:"ReadableStreamBYOBRequest",configurable:!0});let ns=class ns{constructor(){throw new TypeError("Illegal constructor")}get byobRequest(){if(!ir(this))throw On("byobRequest");return Do(this)}get desiredSize(){if(!ir(this))throw On("desiredSize");return Ku(this)}close(){if(!ir(this))throw On("close");if(this._closeRequested)throw new TypeError("The stream has already been closed; do not close it again!");let s=this._controlledReadableByteStream._state;if(s!=="readable")throw new TypeError(`The stream (in ${s} state) is not in the readable state and cannot be closed`);Fn(this)}enqueue(s){if(!ir(this))throw On("enqueue");if(gt(s,1,"enqueue"),!ArrayBuffer.isView(s))throw new TypeError("chunk must be an array buffer view");if(s.byteLength===0)throw new TypeError("chunk must have non-zero byteLength");if(s.buffer.byteLength===0)throw new TypeError("chunk's buffer must have non-zero byteLength");if(this._closeRequested)throw new TypeError("stream is closed or draining");let f=this._controlledReadableByteStream._state;if(f!=="readable")throw new TypeError(`The stream (in ${f} state) is not in the readable state and cannot be enqueued to`);Mi(this,s)}error(s=void 0){if(!ir(this))throw On("error");Pe(this,s)}[B](s){Wu(this),qt(this);let f=this._cancelAlgorithm(s);return Ui(this),f}[M](s){let f=this._controlledReadableByteStream;if(this._queueTotalSize>0){Yu(this,s);return}let p=this._autoAllocateChunkSize;if(p!==void 0){let g;try{g=new ArrayBuffer(p)}catch(_){s._errorSteps(_);return}let b={buffer:g,bufferByteLength:p,byteOffset:0,byteLength:p,bytesFilled:0,minimumFill:1,elementSize:1,viewConstructor:Uint8Array,readerType:"default"};this._pendingPullIntos.push(b)}Cu(f,s),ar(this)}[V](){if(this._pendingPullIntos.length>0){let s=this._pendingPullIntos.peek();s.readerType="none",this._pendingPullIntos=new T,this._pendingPullIntos.push(s)}}};a(ns,"ReadableByteStreamController");let Me=ns;Object.defineProperties(Me.prototype,{close:{enumerable:!0},enqueue:{enumerable:!0},error:{enumerable:!0},byobRequest:{enumerable:!0},desiredSize:{enumerable:!0}}),o(Me.prototype.close,"close"),o(Me.prototype.enqueue,"enqueue"),o(Me.prototype.error,"error"),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(Me.prototype,Symbol.toStringTag,{value:"ReadableByteStreamController",configurable:!0});function ir(i){return!r(i)||!Object.prototype.hasOwnProperty.call(i,"_controlledReadableByteStream")?!1:i instanceof Me}a(ir,"IsReadableByteStreamController");function Po(i){return!r(i)||!Object.prototype.hasOwnProperty.call(i,"_associatedReadableByteStreamController")?!1:i instanceof yt}a(Po,"IsReadableStreamBYOBRequest");function ar(i){if(!mg(i))return;if(i._pulling){i._pullAgain=!0;return}i._pulling=!0;let f=i._pullAlgorithm();y(f,()=>(i._pulling=!1,i._pullAgain&&(i._pullAgain=!1,ar(i)),null),p=>(Pe(i,p),null))}a(ar,"ReadableByteStreamControllerCallPullIfNeeded");function Wu(i){Fo(i),i._pendingPullIntos=new T}a(Wu,"ReadableByteStreamControllerClearPendingPullIntos");function Io(i,s){let f=!1;i._state==="closed"&&(f=!0);let p=Nu(s);s.readerType==="default"?Ro(i,p,f):wg(i,p,f)}a(Io,"ReadableByteStreamControllerCommitPullIntoDescriptor");function Nu(i){let s=i.bytesFilled,f=i.elementSize;return new i.viewConstructor(i.buffer,i.byteOffset,s/f)}a(Nu,"ReadableByteStreamControllerConvertPullIntoDescriptor");function qi(i,s,f,p){i._queue.push({buffer:s,byteOffset:f,byteLength:p}),i._queueTotalSize+=p}a(qi,"ReadableByteStreamControllerEnqueueChunkToQueue");function ju(i,s,f,p){let g;try{g=zu(s,f,f+p)}catch(b){throw Pe(i,b),b}qi(i,g,0,p)}a(ju,"ReadableByteStreamControllerEnqueueClonedChunkToQueue");function Hu(i,s){s.bytesFilled>0&&ju(i,s.buffer,s.byteOffset,s.bytesFilled),Lr(i)}a(Hu,"ReadableByteStreamControllerEnqueueDetachedPullIntoToQueue");function $u(i,s){let f=Math.min(i._queueTotalSize,s.byteLength-s.bytesFilled),p=s.bytesFilled+f,g=f,b=!1,_=p%s.elementSize,I=p-_;I>=s.minimumFill&&(g=I-s.bytesFilled,b=!0);let q=i._queue;for(;g>0;){let D=q.peek(),U=Math.min(g,D.byteLength),W=s.byteOffset+s.bytesFilled;Lu(s.buffer,W,D.buffer,D.byteOffset,U),D.byteLength===U?q.shift():(D.byteOffset+=U,D.byteLength-=U),i._queueTotalSize-=U,Zu(i,U,s),g-=U}return b}a($u,"ReadableByteStreamControllerFillPullIntoDescriptorFromQueue");function Zu(i,s,f){f.bytesFilled+=s}a(Zu,"ReadableByteStreamControllerFillHeadPullIntoDescriptor");function Vu(i){i._queueTotalSize===0&&i._closeRequested?(Ui(i),Un(i._controlledReadableByteStream)):ar(i)}a(Vu,"ReadableByteStreamControllerHandleQueueDrain");function Fo(i){i._byobRequest!==null&&(i._byobRequest._associatedReadableByteStreamController=void 0,i._byobRequest._view=null,i._byobRequest=null)}a(Fo,"ReadableByteStreamControllerInvalidateBYOBRequest");function Oo(i){for(;i._pendingPullIntos.length>0;){if(i._queueTotalSize===0)return;let s=i._pendingPullIntos.peek();$u(i,s)&&(Lr(i),Io(i._controlledReadableByteStream,s))}}a(Oo,"ReadableByteStreamControllerProcessPullIntoDescriptorsUsingQueue");function cg(i){let s=i._controlledReadableByteStream._reader;for(;s._readRequests.length>0;){if(i._queueTotalSize===0)return;let f=s._readRequests.shift();Yu(i,f)}}a(cg,"ReadableByteStreamControllerProcessReadRequestsUsingQueue");function dg(i,s,f,p){let g=i._controlledReadableByteStream,b=s.constructor,_=fg(b),{byteOffset:I,byteLength:q}=s,D=f*_,U;try{U=bt(s.buffer)}catch(G){p._errorSteps(G);return}let W={buffer:U,bufferByteLength:U.byteLength,byteOffset:I,byteLength:q,bytesFilled:0,minimumFill:D,elementSize:_,viewConstructor:b,readerType:"byob"};if(i._pendingPullIntos.length>0){i._pendingPullIntos.push(W),Qu(g,p);return}if(g._state==="closed"){let G=new b(W.buffer,W.byteOffset,0);p._closeSteps(G);return}if(i._queueTotalSize>0){if($u(i,W)){let G=Nu(W);Vu(i),p._chunkSteps(G);return}if(i._closeRequested){let G=new TypeError("Insufficient bytes to fill elements in the given buffer");Pe(i,G),p._errorSteps(G);return}}i._pendingPullIntos.push(W),Qu(g,p),ar(i)}a(dg,"ReadableByteStreamControllerPullInto");function hg(i,s){s.readerType==="none"&&Lr(i);let f=i._controlledReadableByteStream;if(Lo(f))for(;ef(f)>0;){let p=Lr(i);Io(f,p)}}a(hg,"ReadableByteStreamControllerRespondInClosedState");function pg(i,s,f){if(Zu(i,s,f),f.readerType==="none"){Hu(i,f),Oo(i);return}if(f.bytesFilled<f.minimumFill)return;Lr(i);let p=f.bytesFilled%f.elementSize;if(p>0){let g=f.byteOffset+f.bytesFilled;ju(i,f.buffer,g-p,p)}f.bytesFilled-=p,Io(i._controlledReadableByteStream,f),Oo(i)}a(pg,"ReadableByteStreamControllerRespondInReadableState");function Gu(i,s){let f=i._pendingPullIntos.peek();Fo(i),i._controlledReadableByteStream._state==="closed"?hg(i,f):pg(i,s,f),ar(i)}a(Gu,"ReadableByteStreamControllerRespondInternal");function Lr(i){return i._pendingPullIntos.shift()}a(Lr,"ReadableByteStreamControllerShiftPendingPullInto");function mg(i){let s=i._controlledReadableByteStream;return s._state!=="readable"||i._closeRequested||!i._started?!1:!!(Pu(s)&&Di(s)>0||Lo(s)&&ef(s)>0||Ku(i)>0)}a(mg,"ReadableByteStreamControllerShouldCallPull");function Ui(i){i._pullAlgorithm=void 0,i._cancelAlgorithm=void 0}a(Ui,"ReadableByteStreamControllerClearAlgorithms");function Fn(i){let s=i._controlledReadableByteStream;if(!(i._closeRequested||s._state!=="readable")){if(i._queueTotalSize>0){i._closeRequested=!0;return}if(i._pendingPullIntos.length>0){let f=i._pendingPullIntos.peek();if(f.bytesFilled%f.elementSize!==0){let p=new TypeError("Insufficient bytes to fill elements in the given buffer");throw Pe(i,p),p}}Ui(i),Un(s)}}a(Fn,"ReadableByteStreamControllerClose");function Mi(i,s){let f=i._controlledReadableByteStream;if(i._closeRequested||f._state!=="readable")return;let{buffer:p,byteOffset:g,byteLength:b}=s;if(zt(p))throw new TypeError("chunk's buffer is detached and so cannot be enqueued");let _=bt(p);if(i._pendingPullIntos.length>0){let I=i._pendingPullIntos.peek();if(zt(I.buffer))throw new TypeError("The BYOB request's buffer has been detached and so cannot be filled with an enqueued chunk");Fo(i),I.buffer=bt(I.buffer),I.readerType==="none"&&Hu(i,I)}if(Pu(f))if(cg(i),Di(f)===0)qi(i,_,g,b);else{i._pendingPullIntos.length>0&&Lr(i);let I=new Uint8Array(_,g,b);Ro(f,I,!1)}else Lo(f)?(qi(i,_,g,b),Oo(i)):qi(i,_,g,b);ar(i)}a(Mi,"ReadableByteStreamControllerEnqueue");function Pe(i,s){let f=i._controlledReadableByteStream;f._state==="readable"&&(Wu(i),qt(i),Ui(i),xf(f,s))}a(Pe,"ReadableByteStreamControllerError");function Yu(i,s){let f=i._queue.shift();i._queueTotalSize-=f.byteLength,Vu(i);let p=new Uint8Array(f.buffer,f.byteOffset,f.byteLength);s._chunkSteps(p)}a(Yu,"ReadableByteStreamControllerFillReadRequestFromQueue");function Do(i){if(i._byobRequest===null&&i._pendingPullIntos.length>0){let s=i._pendingPullIntos.peek(),f=new Uint8Array(s.buffer,s.byteOffset+s.bytesFilled,s.byteLength-s.bytesFilled),p=Object.create(yt.prototype);bg(p,i,f),i._byobRequest=p}return i._byobRequest}a(Do,"ReadableByteStreamControllerGetBYOBRequest");function Ku(i){let s=i._controlledReadableByteStream._state;return s==="errored"?null:s==="closed"?0:i._strategyHWM-i._queueTotalSize}a(Ku,"ReadableByteStreamControllerGetDesiredSize");function Wi(i,s){let f=i._pendingPullIntos.peek();if(i._controlledReadableByteStream._state==="closed"){if(s!==0)throw new TypeError("bytesWritten must be 0 when calling respond() on a closed stream")}else{if(s===0)throw new TypeError("bytesWritten must be greater than 0 when calling respond() on a readable stream");if(f.bytesFilled+s>f.byteLength)throw new RangeError("bytesWritten out of range")}f.buffer=bt(f.buffer),Gu(i,s)}a(Wi,"ReadableByteStreamControllerRespond");function Ni(i,s){let f=i._pendingPullIntos.peek();if(i._controlledReadableByteStream._state==="closed"){if(s.byteLength!==0)throw new TypeError("The view's length must be 0 when calling respondWithNewView() on a closed stream")}else if(s.byteLength===0)throw new TypeError("The view's length must be greater than 0 when calling respondWithNewView() on a readable stream");if(f.byteOffset+f.bytesFilled!==s.byteOffset)throw new RangeError("The region specified by view does not match byobRequest");if(f.bufferByteLength!==s.buffer.byteLength)throw new RangeError("The buffer of view has different capacity than byobRequest");if(f.bytesFilled+s.byteLength>f.byteLength)throw new RangeError("The region specified by view is larger than byobRequest");let g=s.byteLength;f.buffer=bt(s.buffer),Gu(i,g)}a(Ni,"ReadableByteStreamControllerRespondWithNewView");function Xu(i,s,f,p,g,b,_){s._controlledReadableByteStream=i,s._pullAgain=!1,s._pulling=!1,s._byobRequest=null,s._queue=s._queueTotalSize=void 0,qt(s),s._closeRequested=!1,s._started=!1,s._strategyHWM=b,s._pullAlgorithm=p,s._cancelAlgorithm=g,s._autoAllocateChunkSize=_,s._pendingPullIntos=new T,i._readableStreamController=s;let I=f();y(c(I),()=>(s._started=!0,ar(s),null),q=>(Pe(s,q),null))}a(Xu,"SetUpReadableByteStreamController");function gg(i,s,f){let p=Object.create(Me.prototype),g,b,_;s.start!==void 0?g=a(()=>s.start(p),"startAlgorithm"):g=a(()=>{},"startAlgorithm"),s.pull!==void 0?b=a(()=>s.pull(p),"pullAlgorithm"):b=a(()=>c(void 0),"pullAlgorithm"),s.cancel!==void 0?_=a(q=>s.cancel(q),"cancelAlgorithm"):_=a(()=>c(void 0),"cancelAlgorithm");let I=s.autoAllocateChunkSize;if(I===0)throw new TypeError("autoAllocateChunkSize must be greater than 0");Xu(i,p,g,b,_,f,I)}a(gg,"SetUpReadableByteStreamControllerFromUnderlyingSource");function bg(i,s,f){i._associatedReadableByteStreamController=s,i._view=f}a(bg,"SetUpReadableStreamBYOBRequest");function Bo(i){return new TypeError(`ReadableStreamBYOBRequest.prototype.${i} can only be used on a ReadableStreamBYOBRequest`)}a(Bo,"byobRequestBrandCheckException");function On(i){return new TypeError(`ReadableByteStreamController.prototype.${i} can only be used on a ReadableByteStreamController`)}a(On,"byteStreamControllerBrandCheckException");function yg(i,s){et(i,s);let f=i==null?void 0:i.mode;return{mode:f===void 0?void 0:_g(f,`${s} has member 'mode' that`)}}a(yg,"convertReaderOptions");function _g(i,s){if(i=`${i}`,i!=="byob")throw new TypeError(`${s} '${i}' is not a valid enumeration value for ReadableStreamReaderMode`);return i}a(_g,"convertReadableStreamReaderMode");function vg(i,s){var f;et(i,s);let p=(f=i==null?void 0:i.min)!==null&&f!==void 0?f:1;return{min:wo(p,`${s} has member 'min' that`)}}a(vg,"convertByobReadOptions");function Ju(i){return new rt(i)}a(Ju,"AcquireReadableStreamBYOBReader");function Qu(i,s){i._reader._readIntoRequests.push(s)}a(Qu,"ReadableStreamAddReadIntoRequest");function wg(i,s,f){let g=i._reader._readIntoRequests.shift();f?g._closeSteps(s):g._chunkSteps(s)}a(wg,"ReadableStreamFulfillReadIntoRequest");function ef(i){return i._reader._readIntoRequests.length}a(ef,"ReadableStreamGetNumReadIntoRequests");function Lo(i){let s=i._reader;return!(s===void 0||!or(s))}a(Lo,"ReadableStreamHasBYOBReader");let is=class is{constructor(s){if(gt(s,1,"ReadableStreamBYOBReader"),So(s,"First parameter"),Wt(s))throw new TypeError("This stream has already been locked for exclusive reading by another reader");if(!ir(s._readableStreamController))throw new TypeError("Cannot construct a ReadableStreamBYOBReader for a stream not constructed with a byte source");O(this,s),this._readIntoRequests=new T}get closed(){return or(this)?this._closedPromise:h(ji("closed"))}cancel(s=void 0){return or(this)?this._ownerReadableStream===void 0?h(mt("cancel")):le(this,s):h(ji("cancel"))}read(s,f={}){if(!or(this))return h(ji("read"));if(!ArrayBuffer.isView(s))return h(new TypeError("view must be an array buffer view"));if(s.byteLength===0)return h(new TypeError("view must have non-zero byteLength"));if(s.buffer.byteLength===0)return h(new TypeError("view's buffer must have non-zero byteLength"));if(zt(s.buffer))return h(new TypeError("view's buffer has been detached"));let p;try{p=vg(f,"options")}catch(D){return h(D)}let g=p.min;if(g===0)return h(new TypeError("options.min must be greater than 0"));if(ug(s)){if(g>s.byteLength)return h(new RangeError("options.min must be less than or equal to view's byteLength"))}else if(g>s.length)return h(new RangeError("options.min must be less than or equal to view's length"));if(this._ownerReadableStream===void 0)return h(mt("read from"));let b,_,I=m((D,U)=>{b=D,_=U});return tf(this,s,g,{_chunkSteps:a(D=>b({value:D,done:!1}),"_chunkSteps"),_closeSteps:a(D=>b({value:D,done:!0}),"_closeSteps"),_errorSteps:a(D=>_(D),"_errorSteps")}),I}releaseLock(){if(!or(this))throw ji("releaseLock");this._ownerReadableStream!==void 0&&Sg(this)}};a(is,"ReadableStreamBYOBReader");let rt=is;Object.defineProperties(rt.prototype,{cancel:{enumerable:!0},read:{enumerable:!0},releaseLock:{enumerable:!0},closed:{enumerable:!0}}),o(rt.prototype.cancel,"cancel"),o(rt.prototype.read,"read"),o(rt.prototype.releaseLock,"releaseLock"),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(rt.prototype,Symbol.toStringTag,{value:"ReadableStreamBYOBReader",configurable:!0});function or(i){return!r(i)||!Object.prototype.hasOwnProperty.call(i,"_readIntoRequests")?!1:i instanceof rt}a(or,"IsReadableStreamBYOBReader");function tf(i,s,f,p){let g=i._ownerReadableStream;g._disturbed=!0,g._state==="errored"?p._errorSteps(g._storedError):dg(g._readableStreamController,s,f,p)}a(tf,"ReadableStreamBYOBReaderRead");function Sg(i){ce(i);let s=new TypeError("Reader was released");rf(i,s)}a(Sg,"ReadableStreamBYOBReaderRelease");function rf(i,s){let f=i._readIntoRequests;i._readIntoRequests=new T,f.forEach(p=>{p._errorSteps(s)})}a(rf,"ReadableStreamBYOBReaderErrorReadIntoRequests");function ji(i){return new TypeError(`ReadableStreamBYOBReader.prototype.${i} can only be used on a ReadableStreamBYOBReader`)}a(ji,"byobReaderBrandCheckException");function Dn(i,s){let{highWaterMark:f}=i;if(f===void 0)return s;if(Bu(f)||f<0)throw new RangeError("Invalid highWaterMark");return f}a(Dn,"ExtractHighWaterMark");function Hi(i){let{size:s}=i;return s||(()=>1)}a(Hi,"ExtractSizeAlgorithm");function $i(i,s){et(i,s);let f=i==null?void 0:i.highWaterMark,p=i==null?void 0:i.size;return{highWaterMark:f===void 0?void 0:vo(f),size:p===void 0?void 0:Rg(p,`${s} has member 'size' that`)}}a($i,"convertQueuingStrategy");function Rg(i,s){return Ce(i,s),f=>vo(i(f))}a(Rg,"convertQueuingStrategySize");function Tg(i,s){et(i,s);let f=i==null?void 0:i.abort,p=i==null?void 0:i.close,g=i==null?void 0:i.start,b=i==null?void 0:i.type,_=i==null?void 0:i.write;return{abort:f===void 0?void 0:xg(f,i,`${s} has member 'abort' that`),close:p===void 0?void 0:Ag(p,i,`${s} has member 'close' that`),start:g===void 0?void 0:kg(g,i,`${s} has member 'start' that`),write:_===void 0?void 0:Eg(_,i,`${s} has member 'write' that`),type:b}}a(Tg,"convertUnderlyingSink");function xg(i,s,f){return Ce(i,f),p=>C(i,s,[p])}a(xg,"convertUnderlyingSinkAbortCallback");function Ag(i,s,f){return Ce(i,f),()=>C(i,s,[])}a(Ag,"convertUnderlyingSinkCloseCallback");function kg(i,s,f){return Ce(i,f),p=>A(i,s,[p])}a(kg,"convertUnderlyingSinkStartCallback");function Eg(i,s,f){return Ce(i,f),(p,g)=>C(i,s,[p,g])}a(Eg,"convertUnderlyingSinkWriteCallback");function nf(i,s){if(!zr(i))throw new TypeError(`${s} is not a WritableStream.`)}a(nf,"assertWritableStream");function Cg(i){if(typeof i!="object"||i===null)return!1;try{return typeof i.aborted=="boolean"}catch{return!1}}a(Cg,"isAbortSignal");let Pg=typeof AbortController=="function";function Ig(){if(Pg)return new AbortController}a(Ig,"createAbortController");let as=class as{constructor(s={},f={}){s===void 0?s=null:ku(s,"First parameter");let p=$i(f,"Second parameter"),g=Tg(s,"First parameter");if(of(this),g.type!==void 0)throw new RangeError("Invalid type is specified");let _=Hi(p),I=Dn(p,1);$g(this,g,I,_)}get locked(){if(!zr(this))throw Ki("locked");return qr(this)}abort(s=void 0){return zr(this)?qr(this)?h(new TypeError("Cannot abort a stream that already has a writer")):Zi(this,s):h(Ki("abort"))}close(){return zr(this)?qr(this)?h(new TypeError("Cannot close a stream that already has a writer")):it(this)?h(new TypeError("Cannot close an already-closing stream")):sf(this):h(Ki("close"))}getWriter(){if(!zr(this))throw Ki("getWriter");return af(this)}};a(as,"WritableStream");let nt=as;Object.defineProperties(nt.prototype,{abort:{enumerable:!0},close:{enumerable:!0},getWriter:{enumerable:!0},locked:{enumerable:!0}}),o(nt.prototype.abort,"abort"),o(nt.prototype.close,"close"),o(nt.prototype.getWriter,"getWriter"),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(nt.prototype,Symbol.toStringTag,{value:"WritableStream",configurable:!0});function af(i){return new We(i)}a(af,"AcquireWritableStreamDefaultWriter");function Fg(i,s,f,p,g=1,b=()=>1){let _=Object.create(nt.prototype);of(_);let I=Object.create(Ut.prototype);return hf(_,I,i,s,f,p,g,b),_}a(Fg,"CreateWritableStream");function of(i){i._state="writable",i._storedError=void 0,i._writer=void 0,i._writableStreamController=void 0,i._writeRequests=new T,i._inFlightWriteRequest=void 0,i._closeRequest=void 0,i._inFlightCloseRequest=void 0,i._pendingAbortRequest=void 0,i._backpressure=!1}a(of,"InitializeWritableStream");function zr(i){return!r(i)||!Object.prototype.hasOwnProperty.call(i,"_writableStreamController")?!1:i instanceof nt}a(zr,"IsWritableStream");function qr(i){return i._writer!==void 0}a(qr,"IsWritableStreamLocked");function Zi(i,s){var f;if(i._state==="closed"||i._state==="errored")return c(void 0);i._writableStreamController._abortReason=s,(f=i._writableStreamController._abortController)===null||f===void 0||f.abort(s);let p=i._state;if(p==="closed"||p==="errored")return c(void 0);if(i._pendingAbortRequest!==void 0)return i._pendingAbortRequest._promise;let g=!1;p==="erroring"&&(g=!0,s=void 0);let b=m((_,I)=>{i._pendingAbortRequest={_promise:void 0,_resolve:_,_reject:I,_reason:s,_wasAlreadyErroring:g}});return i._pendingAbortRequest._promise=b,g||qo(i,s),b}a(Zi,"WritableStreamAbort");function sf(i){let s=i._state;if(s==="closed"||s==="errored")return h(new TypeError(`The stream (in ${s} state) is not in the writable state and cannot be closed`));let f=m((g,b)=>{let _={_resolve:g,_reject:b};i._closeRequest=_}),p=i._writer;return p!==void 0&&i._backpressure&&s==="writable"&&Zo(p),Zg(i._writableStreamController),f}a(sf,"WritableStreamClose");function Og(i){return m((f,p)=>{let g={_resolve:f,_reject:p};i._writeRequests.push(g)})}a(Og,"WritableStreamAddWriteRequest");function zo(i,s){if(i._state==="writable"){qo(i,s);return}Uo(i)}a(zo,"WritableStreamDealWithRejection");function qo(i,s){let f=i._writableStreamController;i._state="erroring",i._storedError=s;let p=i._writer;p!==void 0&&uf(p,s),!qg(i)&&f._started&&Uo(i)}a(qo,"WritableStreamStartErroring");function Uo(i){i._state="errored",i._writableStreamController[z]();let s=i._storedError;if(i._writeRequests.forEach(g=>{g._reject(s)}),i._writeRequests=new T,i._pendingAbortRequest===void 0){Vi(i);return}let f=i._pendingAbortRequest;if(i._pendingAbortRequest=void 0,f._wasAlreadyErroring){f._reject(s),Vi(i);return}let p=i._writableStreamController[F](f._reason);y(p,()=>(f._resolve(),Vi(i),null),g=>(f._reject(g),Vi(i),null))}a(Uo,"WritableStreamFinishErroring");function Dg(i){i._inFlightWriteRequest._resolve(void 0),i._inFlightWriteRequest=void 0}a(Dg,"WritableStreamFinishInFlightWrite");function Bg(i,s){i._inFlightWriteRequest._reject(s),i._inFlightWriteRequest=void 0,zo(i,s)}a(Bg,"WritableStreamFinishInFlightWriteWithError");function Lg(i){i._inFlightCloseRequest._resolve(void 0),i._inFlightCloseRequest=void 0,i._state==="erroring"&&(i._storedError=void 0,i._pendingAbortRequest!==void 0&&(i._pendingAbortRequest._resolve(),i._pendingAbortRequest=void 0)),i._state="closed";let f=i._writer;f!==void 0&&bf(f)}a(Lg,"WritableStreamFinishInFlightClose");function zg(i,s){i._inFlightCloseRequest._reject(s),i._inFlightCloseRequest=void 0,i._pendingAbortRequest!==void 0&&(i._pendingAbortRequest._reject(s),i._pendingAbortRequest=void 0),zo(i,s)}a(zg,"WritableStreamFinishInFlightCloseWithError");function it(i){return!(i._closeRequest===void 0&&i._inFlightCloseRequest===void 0)}a(it,"WritableStreamCloseQueuedOrInFlight");function qg(i){return!(i._inFlightWriteRequest===void 0&&i._inFlightCloseRequest===void 0)}a(qg,"WritableStreamHasOperationMarkedInFlight");function Ug(i){i._inFlightCloseRequest=i._closeRequest,i._closeRequest=void 0}a(Ug,"WritableStreamMarkCloseRequestInFlight");function Mg(i){i._inFlightWriteRequest=i._writeRequests.shift()}a(Mg,"WritableStreamMarkFirstWriteRequestInFlight");function Vi(i){i._closeRequest!==void 0&&(i._closeRequest._reject(i._storedError),i._closeRequest=void 0);let s=i._writer;s!==void 0&&Ho(s,i._storedError)}a(Vi,"WritableStreamRejectCloseAndClosedPromiseIfNeeded");function Mo(i,s){let f=i._writer;f!==void 0&&s!==i._backpressure&&(s?Qg(f):Zo(f)),i._backpressure=s}a(Mo,"WritableStreamUpdateBackpressure");let os=class os{constructor(s){if(gt(s,1,"WritableStreamDefaultWriter"),nf(s,"First parameter"),qr(s))throw new TypeError("This stream has already been locked for exclusive writing by another writer");this._ownerWritableStream=s,s._writer=this;let f=s._state;if(f==="writable")!it(s)&&s._backpressure?Ji(this):yf(this),Xi(this);else if(f==="erroring")$o(this,s._storedError),Xi(this);else if(f==="closed")yf(this),Xg(this);else{let p=s._storedError;$o(this,p),gf(this,p)}}get closed(){return sr(this)?this._closedPromise:h(lr("closed"))}get desiredSize(){if(!sr(this))throw lr("desiredSize");if(this._ownerWritableStream===void 0)throw Ln("desiredSize");return Hg(this)}get ready(){return sr(this)?this._readyPromise:h(lr("ready"))}abort(s=void 0){return sr(this)?this._ownerWritableStream===void 0?h(Ln("abort")):Wg(this,s):h(lr("abort"))}close(){if(!sr(this))return h(lr("close"));let s=this._ownerWritableStream;return s===void 0?h(Ln("close")):it(s)?h(new TypeError("Cannot close an already-closing stream")):lf(this)}releaseLock(){if(!sr(this))throw lr("releaseLock");this._ownerWritableStream!==void 0&&ff(this)}write(s=void 0){return sr(this)?this._ownerWritableStream===void 0?h(Ln("write to")):cf(this,s):h(lr("write"))}};a(os,"WritableStreamDefaultWriter");let We=os;Object.defineProperties(We.prototype,{abort:{enumerable:!0},close:{enumerable:!0},releaseLock:{enumerable:!0},write:{enumerable:!0},closed:{enumerable:!0},desiredSize:{enumerable:!0},ready:{enumerable:!0}}),o(We.prototype.abort,"abort"),o(We.prototype.close,"close"),o(We.prototype.releaseLock,"releaseLock"),o(We.prototype.write,"write"),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(We.prototype,Symbol.toStringTag,{value:"WritableStreamDefaultWriter",configurable:!0});function sr(i){return!r(i)||!Object.prototype.hasOwnProperty.call(i,"_ownerWritableStream")?!1:i instanceof We}a(sr,"IsWritableStreamDefaultWriter");function Wg(i,s){let f=i._ownerWritableStream;return Zi(f,s)}a(Wg,"WritableStreamDefaultWriterAbort");function lf(i){let s=i._ownerWritableStream;return sf(s)}a(lf,"WritableStreamDefaultWriterClose");function Ng(i){let s=i._ownerWritableStream,f=s._state;return it(s)||f==="closed"?c(void 0):f==="errored"?h(s._storedError):lf(i)}a(Ng,"WritableStreamDefaultWriterCloseWithErrorPropagation");function jg(i,s){i._closedPromiseState==="pending"?Ho(i,s):Jg(i,s)}a(jg,"WritableStreamDefaultWriterEnsureClosedPromiseRejected");function uf(i,s){i._readyPromiseState==="pending"?_f(i,s):eb(i,s)}a(uf,"WritableStreamDefaultWriterEnsureReadyPromiseRejected");function Hg(i){let s=i._ownerWritableStream,f=s._state;return f==="errored"||f==="erroring"?null:f==="closed"?0:pf(s._writableStreamController)}a(Hg,"WritableStreamDefaultWriterGetDesiredSize");function ff(i){let s=i._ownerWritableStream,f=new TypeError("Writer was released and can no longer be used to monitor the stream's closedness");uf(i,f),jg(i,f),s._writer=void 0,i._ownerWritableStream=void 0}a(ff,"WritableStreamDefaultWriterRelease");function cf(i,s){let f=i._ownerWritableStream,p=f._writableStreamController,g=Vg(p,s);if(f!==i._ownerWritableStream)return h(Ln("write to"));let b=f._state;if(b==="errored")return h(f._storedError);if(it(f)||b==="closed")return h(new TypeError("The stream is closing or closed and cannot be written to"));if(b==="erroring")return h(f._storedError);let _=Og(f);return Gg(p,s,g),_}a(cf,"WritableStreamDefaultWriterWrite");let df={},ss=class ss{constructor(){throw new TypeError("Illegal constructor")}get abortReason(){if(!Wo(this))throw jo("abortReason");return this._abortReason}get signal(){if(!Wo(this))throw jo("signal");if(this._abortController===void 0)throw new TypeError("WritableStreamDefaultController.prototype.signal is not supported");return this._abortController.signal}error(s=void 0){if(!Wo(this))throw jo("error");this._controlledWritableStream._state==="writable"&&mf(this,s)}[F](s){let f=this._abortAlgorithm(s);return Gi(this),f}[z](){qt(this)}};a(ss,"WritableStreamDefaultController");let Ut=ss;Object.defineProperties(Ut.prototype,{abortReason:{enumerable:!0},signal:{enumerable:!0},error:{enumerable:!0}}),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(Ut.prototype,Symbol.toStringTag,{value:"WritableStreamDefaultController",configurable:!0});function Wo(i){return!r(i)||!Object.prototype.hasOwnProperty.call(i,"_controlledWritableStream")?!1:i instanceof Ut}a(Wo,"IsWritableStreamDefaultController");function hf(i,s,f,p,g,b,_,I){s._controlledWritableStream=i,i._writableStreamController=s,s._queue=void 0,s._queueTotalSize=void 0,qt(s),s._abortReason=void 0,s._abortController=Ig(),s._started=!1,s._strategySizeAlgorithm=I,s._strategyHWM=_,s._writeAlgorithm=p,s._closeAlgorithm=g,s._abortAlgorithm=b;let q=No(s);Mo(i,q);let D=f(),U=c(D);y(U,()=>(s._started=!0,Yi(s),null),W=>(s._started=!0,zo(i,W),null))}a(hf,"SetUpWritableStreamDefaultController");function $g(i,s,f,p){let g=Object.create(Ut.prototype),b,_,I,q;s.start!==void 0?b=a(()=>s.start(g),"startAlgorithm"):b=a(()=>{},"startAlgorithm"),s.write!==void 0?_=a(D=>s.write(D,g),"writeAlgorithm"):_=a(()=>c(void 0),"writeAlgorithm"),s.close!==void 0?I=a(()=>s.close(),"closeAlgorithm"):I=a(()=>c(void 0),"closeAlgorithm"),s.abort!==void 0?q=a(D=>s.abort(D),"abortAlgorithm"):q=a(()=>c(void 0),"abortAlgorithm"),hf(i,g,b,_,I,q,f,p)}a($g,"SetUpWritableStreamDefaultControllerFromUnderlyingSink");function Gi(i){i._writeAlgorithm=void 0,i._closeAlgorithm=void 0,i._abortAlgorithm=void 0,i._strategySizeAlgorithm=void 0}a(Gi,"WritableStreamDefaultControllerClearAlgorithms");function Zg(i){Co(i,df,0),Yi(i)}a(Zg,"WritableStreamDefaultControllerClose");function Vg(i,s){try{return i._strategySizeAlgorithm(s)}catch(f){return Bn(i,f),1}}a(Vg,"WritableStreamDefaultControllerGetChunkSize");function pf(i){return i._strategyHWM-i._queueTotalSize}a(pf,"WritableStreamDefaultControllerGetDesiredSize");function Gg(i,s,f){try{Co(i,s,f)}catch(g){Bn(i,g);return}let p=i._controlledWritableStream;if(!it(p)&&p._state==="writable"){let g=No(i);Mo(p,g)}Yi(i)}a(Gg,"WritableStreamDefaultControllerWrite");function Yi(i){let s=i._controlledWritableStream;if(!i._started||s._inFlightWriteRequest!==void 0)return;if(s._state==="erroring"){Uo(s);return}if(i._queue.length===0)return;let p=lg(i);p===df?Yg(i):Kg(i,p)}a(Yi,"WritableStreamDefaultControllerAdvanceQueueIfNeeded");function Bn(i,s){i._controlledWritableStream._state==="writable"&&mf(i,s)}a(Bn,"WritableStreamDefaultControllerErrorIfNeeded");function Yg(i){let s=i._controlledWritableStream;Ug(s),Eo(i);let f=i._closeAlgorithm();Gi(i),y(f,()=>(Lg(s),null),p=>(zg(s,p),null))}a(Yg,"WritableStreamDefaultControllerProcessClose");function Kg(i,s){let f=i._controlledWritableStream;Mg(f);let p=i._writeAlgorithm(s);y(p,()=>{Dg(f);let g=f._state;if(Eo(i),!it(f)&&g==="writable"){let b=No(i);Mo(f,b)}return Yi(i),null},g=>(f._state==="writable"&&Gi(i),Bg(f,g),null))}a(Kg,"WritableStreamDefaultControllerProcessWrite");function No(i){return pf(i)<=0}a(No,"WritableStreamDefaultControllerGetBackpressure");function mf(i,s){let f=i._controlledWritableStream;Gi(i),qo(f,s)}a(mf,"WritableStreamDefaultControllerError");function Ki(i){return new TypeError(`WritableStream.prototype.${i} can only be used on a WritableStream`)}a(Ki,"streamBrandCheckException$2");function jo(i){return new TypeError(`WritableStreamDefaultController.prototype.${i} can only be used on a WritableStreamDefaultController`)}a(jo,"defaultControllerBrandCheckException$2");function lr(i){return new TypeError(`WritableStreamDefaultWriter.prototype.${i} can only be used on a WritableStreamDefaultWriter`)}a(lr,"defaultWriterBrandCheckException");function Ln(i){return new TypeError("Cannot "+i+" a stream using a released writer")}a(Ln,"defaultWriterLockException");function Xi(i){i._closedPromise=m((s,f)=>{i._closedPromise_resolve=s,i._closedPromise_reject=f,i._closedPromiseState="pending"})}a(Xi,"defaultWriterClosedPromiseInitialize");function gf(i,s){Xi(i),Ho(i,s)}a(gf,"defaultWriterClosedPromiseInitializeAsRejected");function Xg(i){Xi(i),bf(i)}a(Xg,"defaultWriterClosedPromiseInitializeAsResolved");function Ho(i,s){i._closedPromise_reject!==void 0&&(k(i._closedPromise),i._closedPromise_reject(s),i._closedPromise_resolve=void 0,i._closedPromise_reject=void 0,i._closedPromiseState="rejected")}a(Ho,"defaultWriterClosedPromiseReject");function Jg(i,s){gf(i,s)}a(Jg,"defaultWriterClosedPromiseResetToRejected");function bf(i){i._closedPromise_resolve!==void 0&&(i._closedPromise_resolve(void 0),i._closedPromise_resolve=void 0,i._closedPromise_reject=void 0,i._closedPromiseState="resolved")}a(bf,"defaultWriterClosedPromiseResolve");function Ji(i){i._readyPromise=m((s,f)=>{i._readyPromise_resolve=s,i._readyPromise_reject=f}),i._readyPromiseState="pending"}a(Ji,"defaultWriterReadyPromiseInitialize");function $o(i,s){Ji(i),_f(i,s)}a($o,"defaultWriterReadyPromiseInitializeAsRejected");function yf(i){Ji(i),Zo(i)}a(yf,"defaultWriterReadyPromiseInitializeAsResolved");function _f(i,s){i._readyPromise_reject!==void 0&&(k(i._readyPromise),i._readyPromise_reject(s),i._readyPromise_resolve=void 0,i._readyPromise_reject=void 0,i._readyPromiseState="rejected")}a(_f,"defaultWriterReadyPromiseReject");function Qg(i){Ji(i)}a(Qg,"defaultWriterReadyPromiseReset");function eb(i,s){$o(i,s)}a(eb,"defaultWriterReadyPromiseResetToRejected");function Zo(i){i._readyPromise_resolve!==void 0&&(i._readyPromise_resolve(void 0),i._readyPromise_resolve=void 0,i._readyPromise_reject=void 0,i._readyPromiseState="fulfilled")}a(Zo,"defaultWriterReadyPromiseResolve");function tb(){if(typeof globalThis<"u")return globalThis;if(typeof self<"u")return self;if(typeof global<"u")return global}a(tb,"getGlobals");let Vo=tb();function rb(i){if(!(typeof i=="function"||typeof i=="object")||i.name!=="DOMException")return!1;try{return new i,!0}catch{return!1}}a(rb,"isDOMExceptionConstructor");function nb(){let i=Vo==null?void 0:Vo.DOMException;return rb(i)?i:void 0}a(nb,"getFromGlobal");function ib(){let i=a(function(f,p){this.message=f||"",this.name=p||"Error",Error.captureStackTrace&&Error.captureStackTrace(this,this.constructor)},"DOMException");return o(i,"DOMException"),i.prototype=Object.create(Error.prototype),Object.defineProperty(i.prototype,"constructor",{value:i,writable:!0,configurable:!0}),i}a(ib,"createPolyfill");let ab=nb()||ib();function vf(i,s,f,p,g,b){let _=Br(i),I=af(s);i._disturbed=!0;let q=!1,D=c(void 0);return m((U,W)=>{let G;if(b!==void 0){if(G=a(()=>{let L=b.reason!==void 0?b.reason:new ab("Aborted","AbortError"),N=[];p||N.push(()=>s._state==="writable"?Zi(s,L):c(void 0)),g||N.push(()=>i._state==="readable"?He(i,L):c(void 0)),be(()=>Promise.all(N.map(Y=>Y())),!0,L)},"abortAlgorithm"),b.aborted){G();return}b.addEventListener("abort",G)}function $e(){return m((L,N)=>{function Y(we){we?L():x($r(),Y,N)}a(Y,"next"),Y(!1)})}a($e,"pipeLoop");function $r(){return q?c(!0):x(I._readyPromise,()=>m((L,N)=>{Pn(_,{_chunkSteps:a(Y=>{D=x(cf(I,Y),void 0,t),L(!1)},"_chunkSteps"),_closeSteps:a(()=>L(!0),"_closeSteps"),_errorSteps:N})}))}if(a($r,"pipeStep"),_t(i,_._closedPromise,L=>(p?Ie(!0,L):be(()=>Zi(s,L),!0,L),null)),_t(s,I._closedPromise,L=>(g?Ie(!0,L):be(()=>He(i,L),!0,L),null)),pe(i,_._closedPromise,()=>(f?Ie():be(()=>Ng(I)),null)),it(s)||s._state==="closed"){let L=new TypeError("the destination writable stream closed before all data could be piped to it");g?Ie(!0,L):be(()=>He(i,L),!0,L)}k($e());function Nt(){let L=D;return x(D,()=>L!==D?Nt():void 0)}a(Nt,"waitForWritesToFinish");function _t(L,N,Y){L._state==="errored"?Y(L._storedError):v(N,Y)}a(_t,"isOrBecomesErrored");function pe(L,N,Y){L._state==="closed"?Y():w(N,Y)}a(pe,"isOrBecomesClosed");function be(L,N,Y){if(q)return;q=!0,s._state==="writable"&&!it(s)?w(Nt(),we):we();function we(){return y(L(),()=>vt(N,Y),Zr=>vt(!0,Zr)),null}a(we,"doTheRest")}a(be,"shutdownWithAction");function Ie(L,N){q||(q=!0,s._state==="writable"&&!it(s)?w(Nt(),()=>vt(L,N)):vt(L,N))}a(Ie,"shutdown");function vt(L,N){return ff(I),ce(_),b!==void 0&&b.removeEventListener("abort",G),L?W(N):U(void 0),null}a(vt,"finalize")})}a(vf,"ReadableStreamPipeTo");let ls=class ls{constructor(){throw new TypeError("Illegal constructor")}get desiredSize(){if(!Qi(this))throw ta("desiredSize");return Go(this)}close(){if(!Qi(this))throw ta("close");if(!Mr(this))throw new TypeError("The stream is not in a state that permits close");ur(this)}enqueue(s=void 0){if(!Qi(this))throw ta("enqueue");if(!Mr(this))throw new TypeError("The stream is not in a state that permits enqueue");return Ur(this,s)}error(s=void 0){if(!Qi(this))throw ta("error");je(this,s)}[B](s){qt(this);let f=this._cancelAlgorithm(s);return ea(this),f}[M](s){let f=this._controlledReadableStream;if(this._queue.length>0){let p=Eo(this);this._closeRequested&&this._queue.length===0?(ea(this),Un(f)):zn(this),s._chunkSteps(p)}else Cu(f,s),zn(this)}[V](){}};a(ls,"ReadableStreamDefaultController");let Ne=ls;Object.defineProperties(Ne.prototype,{close:{enumerable:!0},enqueue:{enumerable:!0},error:{enumerable:!0},desiredSize:{enumerable:!0}}),o(Ne.prototype.close,"close"),o(Ne.prototype.enqueue,"enqueue"),o(Ne.prototype.error,"error"),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(Ne.prototype,Symbol.toStringTag,{value:"ReadableStreamDefaultController",configurable:!0});function Qi(i){return!r(i)||!Object.prototype.hasOwnProperty.call(i,"_controlledReadableStream")?!1:i instanceof Ne}a(Qi,"IsReadableStreamDefaultController");function zn(i){if(!wf(i))return;if(i._pulling){i._pullAgain=!0;return}i._pulling=!0;let f=i._pullAlgorithm();y(f,()=>(i._pulling=!1,i._pullAgain&&(i._pullAgain=!1,zn(i)),null),p=>(je(i,p),null))}a(zn,"ReadableStreamDefaultControllerCallPullIfNeeded");function wf(i){let s=i._controlledReadableStream;return!Mr(i)||!i._started?!1:!!(Wt(s)&&Di(s)>0||Go(i)>0)}a(wf,"ReadableStreamDefaultControllerShouldCallPull");function ea(i){i._pullAlgorithm=void 0,i._cancelAlgorithm=void 0,i._strategySizeAlgorithm=void 0}a(ea,"ReadableStreamDefaultControllerClearAlgorithms");function ur(i){if(!Mr(i))return;let s=i._controlledReadableStream;i._closeRequested=!0,i._queue.length===0&&(ea(i),Un(s))}a(ur,"ReadableStreamDefaultControllerClose");function Ur(i,s){if(!Mr(i))return;let f=i._controlledReadableStream;if(Wt(f)&&Di(f)>0)Ro(f,s,!1);else{let p;try{p=i._strategySizeAlgorithm(s)}catch(g){throw je(i,g),g}try{Co(i,s,p)}catch(g){throw je(i,g),g}}zn(i)}a(Ur,"ReadableStreamDefaultControllerEnqueue");function je(i,s){let f=i._controlledReadableStream;f._state==="readable"&&(qt(i),ea(i),xf(f,s))}a(je,"ReadableStreamDefaultControllerError");function Go(i){let s=i._controlledReadableStream._state;return s==="errored"?null:s==="closed"?0:i._strategyHWM-i._queueTotalSize}a(Go,"ReadableStreamDefaultControllerGetDesiredSize");function ob(i){return!wf(i)}a(ob,"ReadableStreamDefaultControllerHasBackpressure");function Mr(i){let s=i._controlledReadableStream._state;return!i._closeRequested&&s==="readable"}a(Mr,"ReadableStreamDefaultControllerCanCloseOrEnqueue");function Sf(i,s,f,p,g,b,_){s._controlledReadableStream=i,s._queue=void 0,s._queueTotalSize=void 0,qt(s),s._started=!1,s._closeRequested=!1,s._pullAgain=!1,s._pulling=!1,s._strategySizeAlgorithm=_,s._strategyHWM=b,s._pullAlgorithm=p,s._cancelAlgorithm=g,i._readableStreamController=s;let I=f();y(c(I),()=>(s._started=!0,zn(s),null),q=>(je(s,q),null))}a(Sf,"SetUpReadableStreamDefaultController");function sb(i,s,f,p){let g=Object.create(Ne.prototype),b,_,I;s.start!==void 0?b=a(()=>s.start(g),"startAlgorithm"):b=a(()=>{},"startAlgorithm"),s.pull!==void 0?_=a(()=>s.pull(g),"pullAlgorithm"):_=a(()=>c(void 0),"pullAlgorithm"),s.cancel!==void 0?I=a(q=>s.cancel(q),"cancelAlgorithm"):I=a(()=>c(void 0),"cancelAlgorithm"),Sf(i,g,b,_,I,f,p)}a(sb,"SetUpReadableStreamDefaultControllerFromUnderlyingSource");function ta(i){return new TypeError(`ReadableStreamDefaultController.prototype.${i} can only be used on a ReadableStreamDefaultController`)}a(ta,"defaultControllerBrandCheckException$1");function lb(i,s){return ir(i._readableStreamController)?fb(i):ub(i)}a(lb,"ReadableStreamTee");function ub(i,s){let f=Br(i),p=!1,g=!1,b=!1,_=!1,I,q,D,U,W,G=m(pe=>{W=pe});function $e(){return p?(g=!0,c(void 0)):(p=!0,Pn(f,{_chunkSteps:a(be=>{S(()=>{g=!1;let Ie=be,vt=be;b||Ur(D._readableStreamController,Ie),_||Ur(U._readableStreamController,vt),p=!1,g&&$e()})},"_chunkSteps"),_closeSteps:a(()=>{p=!1,b||ur(D._readableStreamController),_||ur(U._readableStreamController),(!b||!_)&&W(void 0)},"_closeSteps"),_errorSteps:a(()=>{p=!1},"_errorSteps")}),c(void 0))}a($e,"pullAlgorithm");function $r(pe){if(b=!0,I=pe,_){let be=In([I,q]),Ie=He(i,be);W(Ie)}return G}a($r,"cancel1Algorithm");function Nt(pe){if(_=!0,q=pe,b){let be=In([I,q]),Ie=He(i,be);W(Ie)}return G}a(Nt,"cancel2Algorithm");function _t(){}return a(_t,"startAlgorithm"),D=qn(_t,$e,$r),U=qn(_t,$e,Nt),v(f._closedPromise,pe=>(je(D._readableStreamController,pe),je(U._readableStreamController,pe),(!b||!_)&&W(void 0),null)),[D,U]}a(ub,"ReadableStreamDefaultTee");function fb(i){let s=Br(i),f=!1,p=!1,g=!1,b=!1,_=!1,I,q,D,U,W,G=m(L=>{W=L});function $e(L){v(L._closedPromise,N=>(L!==s||(Pe(D._readableStreamController,N),Pe(U._readableStreamController,N),(!b||!_)&&W(void 0)),null))}a($e,"forwardReaderError");function $r(){or(s)&&(ce(s),s=Br(i),$e(s)),Pn(s,{_chunkSteps:a(N=>{S(()=>{p=!1,g=!1;let Y=N,we=N;if(!b&&!_)try{we=Uu(N)}catch(Zr){Pe(D._readableStreamController,Zr),Pe(U._readableStreamController,Zr),W(He(i,Zr));return}b||Mi(D._readableStreamController,Y),_||Mi(U._readableStreamController,we),f=!1,p?_t():g&&pe()})},"_chunkSteps"),_closeSteps:a(()=>{f=!1,b||Fn(D._readableStreamController),_||Fn(U._readableStreamController),D._readableStreamController._pendingPullIntos.length>0&&Wi(D._readableStreamController,0),U._readableStreamController._pendingPullIntos.length>0&&Wi(U._readableStreamController,0),(!b||!_)&&W(void 0)},"_closeSteps"),_errorSteps:a(()=>{f=!1},"_errorSteps")})}a($r,"pullWithDefaultReader");function Nt(L,N){Lt(s)&&(ce(s),s=Ju(i),$e(s));let Y=N?U:D,we=N?D:U;tf(s,L,1,{_chunkSteps:a(Vr=>{S(()=>{p=!1,g=!1;let Gr=N?_:b;if(N?b:_)Gr||Ni(Y._readableStreamController,Vr);else{let qf;try{qf=Uu(Vr)}catch(ps){Pe(Y._readableStreamController,ps),Pe(we._readableStreamController,ps),W(He(i,ps));return}Gr||Ni(Y._readableStreamController,Vr),Mi(we._readableStreamController,qf)}f=!1,p?_t():g&&pe()})},"_chunkSteps"),_closeSteps:a(Vr=>{f=!1;let Gr=N?_:b,oa=N?b:_;Gr||Fn(Y._readableStreamController),oa||Fn(we._readableStreamController),Vr!==void 0&&(Gr||Ni(Y._readableStreamController,Vr),!oa&&we._readableStreamController._pendingPullIntos.length>0&&Wi(we._readableStreamController,0)),(!Gr||!oa)&&W(void 0)},"_closeSteps"),_errorSteps:a(()=>{f=!1},"_errorSteps")})}a(Nt,"pullWithBYOBReader");function _t(){if(f)return p=!0,c(void 0);f=!0;let L=Do(D._readableStreamController);return L===null?$r():Nt(L._view,!1),c(void 0)}a(_t,"pull1Algorithm");function pe(){if(f)return g=!0,c(void 0);f=!0;let L=Do(U._readableStreamController);return L===null?$r():Nt(L._view,!0),c(void 0)}a(pe,"pull2Algorithm");function be(L){if(b=!0,I=L,_){let N=In([I,q]),Y=He(i,N);W(Y)}return G}a(be,"cancel1Algorithm");function Ie(L){if(_=!0,q=L,b){let N=In([I,q]),Y=He(i,N);W(Y)}return G}a(Ie,"cancel2Algorithm");function vt(){}return a(vt,"startAlgorithm"),D=Tf(vt,_t,be),U=Tf(vt,pe,Ie),$e(s),[D,U]}a(fb,"ReadableByteStreamTee");function cb(i){return r(i)&&typeof i.getReader<"u"}a(cb,"isReadableStreamLike");function db(i){return cb(i)?pb(i.getReader()):hb(i)}a(db,"ReadableStreamFrom");function hb(i){let s,f=qu(i,"async"),p=t;function g(){let _;try{_=ig(f)}catch(q){return h(q)}let I=c(_);return E(I,q=>{if(!r(q))throw new TypeError("The promise returned by the iterator.next() method must fulfill with an object");if(ag(q))ur(s._readableStreamController);else{let U=og(q);Ur(s._readableStreamController,U)}})}a(g,"pullAlgorithm");function b(_){let I=f.iterator,q;try{q=zi(I,"return")}catch(W){return h(W)}if(q===void 0)return c(void 0);let D;try{D=A(q,I,[_])}catch(W){return h(W)}let U=c(D);return E(U,W=>{if(!r(W))throw new TypeError("The promise returned by the iterator.return() method must fulfill with an object")})}return a(b,"cancelAlgorithm"),s=qn(p,g,b,0),s}a(hb,"ReadableStreamFromIterable");function pb(i){let s,f=t;function p(){let b;try{b=i.read()}catch(_){return h(_)}return E(b,_=>{if(!r(_))throw new TypeError("The promise returned by the reader.read() method must fulfill with an object");if(_.done)ur(s._readableStreamController);else{let I=_.value;Ur(s._readableStreamController,I)}})}a(p,"pullAlgorithm");function g(b){try{return c(i.cancel(b))}catch(_){return h(_)}}return a(g,"cancelAlgorithm"),s=qn(f,p,g,0),s}a(pb,"ReadableStreamFromDefaultReader");function mb(i,s){et(i,s);let f=i,p=f==null?void 0:f.autoAllocateChunkSize,g=f==null?void 0:f.cancel,b=f==null?void 0:f.pull,_=f==null?void 0:f.start,I=f==null?void 0:f.type;return{autoAllocateChunkSize:p===void 0?void 0:wo(p,`${s} has member 'autoAllocateChunkSize' that`),cancel:g===void 0?void 0:gb(g,f,`${s} has member 'cancel' that`),pull:b===void 0?void 0:bb(b,f,`${s} has member 'pull' that`),start:_===void 0?void 0:yb(_,f,`${s} has member 'start' that`),type:I===void 0?void 0:_b(I,`${s} has member 'type' that`)}}a(mb,"convertUnderlyingDefaultOrByteSource");function gb(i,s,f){return Ce(i,f),p=>C(i,s,[p])}a(gb,"convertUnderlyingSourceCancelCallback");function bb(i,s,f){return Ce(i,f),p=>C(i,s,[p])}a(bb,"convertUnderlyingSourcePullCallback");function yb(i,s,f){return Ce(i,f),p=>A(i,s,[p])}a(yb,"convertUnderlyingSourceStartCallback");function _b(i,s){if(i=`${i}`,i!=="bytes")throw new TypeError(`${s} '${i}' is not a valid enumeration value for ReadableStreamType`);return i}a(_b,"convertReadableStreamType");function vb(i,s){return et(i,s),{preventCancel:!!(i==null?void 0:i.preventCancel)}}a(vb,"convertIteratorOptions");function Rf(i,s){et(i,s);let f=i==null?void 0:i.preventAbort,p=i==null?void 0:i.preventCancel,g=i==null?void 0:i.preventClose,b=i==null?void 0:i.signal;return b!==void 0&&wb(b,`${s} has member 'signal' that`),{preventAbort:!!f,preventCancel:!!p,preventClose:!!g,signal:b}}a(Rf,"convertPipeOptions");function wb(i,s){if(!Cg(i))throw new TypeError(`${s} is not an AbortSignal.`)}a(wb,"assertAbortSignal");function Sb(i,s){et(i,s);let f=i==null?void 0:i.readable;_o(f,"readable","ReadableWritablePair"),So(f,`${s} has member 'readable' that`);let p=i==null?void 0:i.writable;return _o(p,"writable","ReadableWritablePair"),nf(p,`${s} has member 'writable' that`),{readable:f,writable:p}}a(Sb,"convertReadableWritablePair");let us=class us{constructor(s={},f={}){s===void 0?s=null:ku(s,"First parameter");let p=$i(f,"Second parameter"),g=mb(s,"First parameter");if(Yo(this),g.type==="bytes"){if(p.size!==void 0)throw new RangeError("The strategy for a byte stream cannot have a size function");let b=Dn(p,0);gg(this,g,b)}else{let b=Hi(p),_=Dn(p,1);sb(this,g,_,b)}}get locked(){if(!Mt(this))throw fr("locked");return Wt(this)}cancel(s=void 0){return Mt(this)?Wt(this)?h(new TypeError("Cannot cancel a stream that already has a reader")):He(this,s):h(fr("cancel"))}getReader(s=void 0){if(!Mt(this))throw fr("getReader");return yg(s,"First parameter").mode===void 0?Br(this):Ju(this)}pipeThrough(s,f={}){if(!Mt(this))throw fr("pipeThrough");gt(s,1,"pipeThrough");let p=Sb(s,"First parameter"),g=Rf(f,"Second parameter");if(Wt(this))throw new TypeError("ReadableStream.prototype.pipeThrough cannot be used on a locked ReadableStream");if(qr(p.writable))throw new TypeError("ReadableStream.prototype.pipeThrough cannot be used on a locked WritableStream");let b=vf(this,p.writable,g.preventClose,g.preventAbort,g.preventCancel,g.signal);return k(b),p.readable}pipeTo(s,f={}){if(!Mt(this))return h(fr("pipeTo"));if(s===void 0)return h("Parameter 1 is required in 'pipeTo'.");if(!zr(s))return h(new TypeError("ReadableStream.prototype.pipeTo's first argument must be a WritableStream"));let p;try{p=Rf(f,"Second parameter")}catch(g){return h(g)}return Wt(this)?h(new TypeError("ReadableStream.prototype.pipeTo cannot be used on a locked ReadableStream")):qr(s)?h(new TypeError("ReadableStream.prototype.pipeTo cannot be used on a locked WritableStream")):vf(this,s,p.preventClose,p.preventAbort,p.preventCancel,p.signal)}tee(){if(!Mt(this))throw fr("tee");let s=lb(this);return In(s)}values(s=void 0){if(!Mt(this))throw fr("values");let f=vb(s,"First parameter");return rg(this,f.preventCancel)}[ko](s){return this.values(s)}static from(s){return db(s)}};a(us,"ReadableStream");let oe=us;Object.defineProperties(oe,{from:{enumerable:!0}}),Object.defineProperties(oe.prototype,{cancel:{enumerable:!0},getReader:{enumerable:!0},pipeThrough:{enumerable:!0},pipeTo:{enumerable:!0},tee:{enumerable:!0},values:{enumerable:!0},locked:{enumerable:!0}}),o(oe.from,"from"),o(oe.prototype.cancel,"cancel"),o(oe.prototype.getReader,"getReader"),o(oe.prototype.pipeThrough,"pipeThrough"),o(oe.prototype.pipeTo,"pipeTo"),o(oe.prototype.tee,"tee"),o(oe.prototype.values,"values"),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(oe.prototype,Symbol.toStringTag,{value:"ReadableStream",configurable:!0}),Object.defineProperty(oe.prototype,ko,{value:oe.prototype.values,writable:!0,configurable:!0});function qn(i,s,f,p=1,g=()=>1){let b=Object.create(oe.prototype);Yo(b);let _=Object.create(Ne.prototype);return Sf(b,_,i,s,f,p,g),b}a(qn,"CreateReadableStream");function Tf(i,s,f){let p=Object.create(oe.prototype);Yo(p);let g=Object.create(Me.prototype);return Xu(p,g,i,s,f,0,void 0),p}a(Tf,"CreateReadableByteStream");function Yo(i){i._state="readable",i._reader=void 0,i._storedError=void 0,i._disturbed=!1}a(Yo,"InitializeReadableStream");function Mt(i){return!r(i)||!Object.prototype.hasOwnProperty.call(i,"_readableStreamController")?!1:i instanceof oe}a(Mt,"IsReadableStream");function Wt(i){return i._reader!==void 0}a(Wt,"IsReadableStreamLocked");function He(i,s){if(i._disturbed=!0,i._state==="closed")return c(void 0);if(i._state==="errored")return h(i._storedError);Un(i);let f=i._reader;if(f!==void 0&&or(f)){let g=f._readIntoRequests;f._readIntoRequests=new T,g.forEach(b=>{b._closeSteps(void 0)})}let p=i._readableStreamController[B](s);return E(p,t)}a(He,"ReadableStreamCancel");function Un(i){i._state="closed";let s=i._reader;if(s!==void 0&&(xu(s),Lt(s))){let f=s._readRequests;s._readRequests=new T,f.forEach(p=>{p._closeSteps()})}}a(Un,"ReadableStreamClose");function xf(i,s){i._state="errored",i._storedError=s;let f=i._reader;f!==void 0&&(Bt(f,s),Lt(f)?Iu(f,s):rf(f,s))}a(xf,"ReadableStreamError");function fr(i){return new TypeError(`ReadableStream.prototype.${i} can only be used on a ReadableStream`)}a(fr,"streamBrandCheckException$1");function Af(i,s){et(i,s);let f=i==null?void 0:i.highWaterMark;return _o(f,"highWaterMark","QueuingStrategyInit"),{highWaterMark:vo(f)}}a(Af,"convertQueuingStrategyInit");let kf=a(i=>i.byteLength,"byteLengthSizeFunction");o(kf,"size");let fs=class fs{constructor(s){gt(s,1,"ByteLengthQueuingStrategy"),s=Af(s,"First parameter"),this._byteLengthQueuingStrategyHighWaterMark=s.highWaterMark}get highWaterMark(){if(!Cf(this))throw Ef("highWaterMark");return this._byteLengthQueuingStrategyHighWaterMark}get size(){if(!Cf(this))throw Ef("size");return kf}};a(fs,"ByteLengthQueuingStrategy");let Wr=fs;Object.defineProperties(Wr.prototype,{highWaterMark:{enumerable:!0},size:{enumerable:!0}}),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(Wr.prototype,Symbol.toStringTag,{value:"ByteLengthQueuingStrategy",configurable:!0});function Ef(i){return new TypeError(`ByteLengthQueuingStrategy.prototype.${i} can only be used on a ByteLengthQueuingStrategy`)}a(Ef,"byteLengthBrandCheckException");function Cf(i){return!r(i)||!Object.prototype.hasOwnProperty.call(i,"_byteLengthQueuingStrategyHighWaterMark")?!1:i instanceof Wr}a(Cf,"IsByteLengthQueuingStrategy");let Pf=a(()=>1,"countSizeFunction");o(Pf,"size");let cs=class cs{constructor(s){gt(s,1,"CountQueuingStrategy"),s=Af(s,"First parameter"),this._countQueuingStrategyHighWaterMark=s.highWaterMark}get highWaterMark(){if(!Ff(this))throw If("highWaterMark");return this._countQueuingStrategyHighWaterMark}get size(){if(!Ff(this))throw If("size");return Pf}};a(cs,"CountQueuingStrategy");let Nr=cs;Object.defineProperties(Nr.prototype,{highWaterMark:{enumerable:!0},size:{enumerable:!0}}),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(Nr.prototype,Symbol.toStringTag,{value:"CountQueuingStrategy",configurable:!0});function If(i){return new TypeError(`CountQueuingStrategy.prototype.${i} can only be used on a CountQueuingStrategy`)}a(If,"countBrandCheckException");function Ff(i){return!r(i)||!Object.prototype.hasOwnProperty.call(i,"_countQueuingStrategyHighWaterMark")?!1:i instanceof Nr}a(Ff,"IsCountQueuingStrategy");function Rb(i,s){et(i,s);let f=i==null?void 0:i.cancel,p=i==null?void 0:i.flush,g=i==null?void 0:i.readableType,b=i==null?void 0:i.start,_=i==null?void 0:i.transform,I=i==null?void 0:i.writableType;return{cancel:f===void 0?void 0:kb(f,i,`${s} has member 'cancel' that`),flush:p===void 0?void 0:Tb(p,i,`${s} has member 'flush' that`),readableType:g,start:b===void 0?void 0:xb(b,i,`${s} has member 'start' that`),transform:_===void 0?void 0:Ab(_,i,`${s} has member 'transform' that`),writableType:I}}a(Rb,"convertTransformer");function Tb(i,s,f){return Ce(i,f),p=>C(i,s,[p])}a(Tb,"convertTransformerFlushCallback");function xb(i,s,f){return Ce(i,f),p=>A(i,s,[p])}a(xb,"convertTransformerStartCallback");function Ab(i,s,f){return Ce(i,f),(p,g)=>C(i,s,[p,g])}a(Ab,"convertTransformerTransformCallback");function kb(i,s,f){return Ce(i,f),p=>C(i,s,[p])}a(kb,"convertTransformerCancelCallback");let ds=class ds{constructor(s={},f={},p={}){s===void 0&&(s=null);let g=$i(f,"Second parameter"),b=$i(p,"Third parameter"),_=Rb(s,"First parameter");if(_.readableType!==void 0)throw new RangeError("Invalid readableType specified");if(_.writableType!==void 0)throw new RangeError("Invalid writableType specified");let I=Dn(b,0),q=Hi(b),D=Dn(g,1),U=Hi(g),W,G=m($e=>{W=$e});Eb(this,G,D,U,I,q),Pb(this,_),_.start!==void 0?W(_.start(this._transformStreamController)):W(void 0)}get readable(){if(!Of(this))throw zf("readable");return this._readable}get writable(){if(!Of(this))throw zf("writable");return this._writable}};a(ds,"TransformStream");let jr=ds;Object.defineProperties(jr.prototype,{readable:{enumerable:!0},writable:{enumerable:!0}}),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(jr.prototype,Symbol.toStringTag,{value:"TransformStream",configurable:!0});function Eb(i,s,f,p,g,b){function _(){return s}a(_,"startAlgorithm");function I(G){return Ob(i,G)}a(I,"writeAlgorithm");function q(G){return Db(i,G)}a(q,"abortAlgorithm");function D(){return Bb(i)}a(D,"closeAlgorithm"),i._writable=Fg(_,I,D,q,f,p);function U(){return Lb(i)}a(U,"pullAlgorithm");function W(G){return zb(i,G)}a(W,"cancelAlgorithm"),i._readable=qn(_,U,W,g,b),i._backpressure=void 0,i._backpressureChangePromise=void 0,i._backpressureChangePromise_resolve=void 0,ra(i,!0),i._transformStreamController=void 0}a(Eb,"InitializeTransformStream");function Of(i){return!r(i)||!Object.prototype.hasOwnProperty.call(i,"_transformStreamController")?!1:i instanceof jr}a(Of,"IsTransformStream");function Df(i,s){je(i._readable._readableStreamController,s),Ko(i,s)}a(Df,"TransformStreamError");function Ko(i,s){ia(i._transformStreamController),Bn(i._writable._writableStreamController,s),Xo(i)}a(Ko,"TransformStreamErrorWritableAndUnblockWrite");function Xo(i){i._backpressure&&ra(i,!1)}a(Xo,"TransformStreamUnblockWrite");function ra(i,s){i._backpressureChangePromise!==void 0&&i._backpressureChangePromise_resolve(),i._backpressureChangePromise=m(f=>{i._backpressureChangePromise_resolve=f}),i._backpressure=s}a(ra,"TransformStreamSetBackpressure");let hs=class hs{constructor(){throw new TypeError("Illegal constructor")}get desiredSize(){if(!na(this))throw aa("desiredSize");let s=this._controlledTransformStream._readable._readableStreamController;return Go(s)}enqueue(s=void 0){if(!na(this))throw aa("enqueue");Bf(this,s)}error(s=void 0){if(!na(this))throw aa("error");Ib(this,s)}terminate(){if(!na(this))throw aa("terminate");Fb(this)}};a(hs,"TransformStreamDefaultController");let at=hs;Object.defineProperties(at.prototype,{enqueue:{enumerable:!0},error:{enumerable:!0},terminate:{enumerable:!0},desiredSize:{enumerable:!0}}),o(at.prototype.enqueue,"enqueue"),o(at.prototype.error,"error"),o(at.prototype.terminate,"terminate"),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(at.prototype,Symbol.toStringTag,{value:"TransformStreamDefaultController",configurable:!0});function na(i){return!r(i)||!Object.prototype.hasOwnProperty.call(i,"_controlledTransformStream")?!1:i instanceof at}a(na,"IsTransformStreamDefaultController");function Cb(i,s,f,p,g){s._controlledTransformStream=i,i._transformStreamController=s,s._transformAlgorithm=f,s._flushAlgorithm=p,s._cancelAlgorithm=g,s._finishPromise=void 0,s._finishPromise_resolve=void 0,s._finishPromise_reject=void 0}a(Cb,"SetUpTransformStreamDefaultController");function Pb(i,s){let f=Object.create(at.prototype),p,g,b;s.transform!==void 0?p=a(_=>s.transform(_,f),"transformAlgorithm"):p=a(_=>{try{return Bf(f,_),c(void 0)}catch(I){return h(I)}},"transformAlgorithm"),s.flush!==void 0?g=a(()=>s.flush(f),"flushAlgorithm"):g=a(()=>c(void 0),"flushAlgorithm"),s.cancel!==void 0?b=a(_=>s.cancel(_),"cancelAlgorithm"):b=a(()=>c(void 0),"cancelAlgorithm"),Cb(i,f,p,g,b)}a(Pb,"SetUpTransformStreamDefaultControllerFromTransformer");function ia(i){i._transformAlgorithm=void 0,i._flushAlgorithm=void 0,i._cancelAlgorithm=void 0}a(ia,"TransformStreamDefaultControllerClearAlgorithms");function Bf(i,s){let f=i._controlledTransformStream,p=f._readable._readableStreamController;if(!Mr(p))throw new TypeError("Readable side is not in a state that permits enqueue");try{Ur(p,s)}catch(b){throw Ko(f,b),f._readable._storedError}ob(p)!==f._backpressure&&ra(f,!0)}a(Bf,"TransformStreamDefaultControllerEnqueue");function Ib(i,s){Df(i._controlledTransformStream,s)}a(Ib,"TransformStreamDefaultControllerError");function Lf(i,s){let f=i._transformAlgorithm(s);return E(f,void 0,p=>{throw Df(i._controlledTransformStream,p),p})}a(Lf,"TransformStreamDefaultControllerPerformTransform");function Fb(i){let s=i._controlledTransformStream,f=s._readable._readableStreamController;ur(f);let p=new TypeError("TransformStream terminated");Ko(s,p)}a(Fb,"TransformStreamDefaultControllerTerminate");function Ob(i,s){let f=i._transformStreamController;if(i._backpressure){let p=i._backpressureChangePromise;return E(p,()=>{let g=i._writable;if(g._state==="erroring")throw g._storedError;return Lf(f,s)})}return Lf(f,s)}a(Ob,"TransformStreamDefaultSinkWriteAlgorithm");function Db(i,s){let f=i._transformStreamController;if(f._finishPromise!==void 0)return f._finishPromise;let p=i._readable;f._finishPromise=m((b,_)=>{f._finishPromise_resolve=b,f._finishPromise_reject=_});let g=f._cancelAlgorithm(s);return ia(f),y(g,()=>(p._state==="errored"?Hr(f,p._storedError):(je(p._readableStreamController,s),Jo(f)),null),b=>(je(p._readableStreamController,b),Hr(f,b),null)),f._finishPromise}a(Db,"TransformStreamDefaultSinkAbortAlgorithm");function Bb(i){let s=i._transformStreamController;if(s._finishPromise!==void 0)return s._finishPromise;let f=i._readable;s._finishPromise=m((g,b)=>{s._finishPromise_resolve=g,s._finishPromise_reject=b});let p=s._flushAlgorithm();return ia(s),y(p,()=>(f._state==="errored"?Hr(s,f._storedError):(ur(f._readableStreamController),Jo(s)),null),g=>(je(f._readableStreamController,g),Hr(s,g),null)),s._finishPromise}a(Bb,"TransformStreamDefaultSinkCloseAlgorithm");function Lb(i){return ra(i,!1),i._backpressureChangePromise}a(Lb,"TransformStreamDefaultSourcePullAlgorithm");function zb(i,s){let f=i._transformStreamController;if(f._finishPromise!==void 0)return f._finishPromise;let p=i._writable;f._finishPromise=m((b,_)=>{f._finishPromise_resolve=b,f._finishPromise_reject=_});let g=f._cancelAlgorithm(s);return ia(f),y(g,()=>(p._state==="errored"?Hr(f,p._storedError):(Bn(p._writableStreamController,s),Xo(i),Jo(f)),null),b=>(Bn(p._writableStreamController,b),Xo(i),Hr(f,b),null)),f._finishPromise}a(zb,"TransformStreamDefaultSourceCancelAlgorithm");function aa(i){return new TypeError(`TransformStreamDefaultController.prototype.${i} can only be used on a TransformStreamDefaultController`)}a(aa,"defaultControllerBrandCheckException");function Jo(i){i._finishPromise_resolve!==void 0&&(i._finishPromise_resolve(),i._finishPromise_resolve=void 0,i._finishPromise_reject=void 0)}a(Jo,"defaultControllerFinishPromiseResolve");function Hr(i,s){i._finishPromise_reject!==void 0&&(k(i._finishPromise),i._finishPromise_reject(s),i._finishPromise_resolve=void 0,i._finishPromise_reject=void 0)}a(Hr,"defaultControllerFinishPromiseReject");function zf(i){return new TypeError(`TransformStream.prototype.${i} can only be used on a TransformStream`)}a(zf,"streamBrandCheckException"),e.ByteLengthQueuingStrategy=Wr,e.CountQueuingStrategy=Nr,e.ReadableByteStreamController=Me,e.ReadableStream=oe,e.ReadableStreamBYOBReader=rt,e.ReadableStreamBYOBRequest=yt,e.ReadableStreamDefaultController=Ne,e.ReadableStreamDefaultReader=tt,e.TransformStream=jr,e.TransformStreamDefaultController=at,e.WritableStream=nt,e.WritableStreamDefaultController=Ut,e.WritableStreamDefaultWriter=We})});var Zf=P(()=>{if(!globalThis.ReadableStream)try{let e=require("process"),{emitWarning:t}=e;try{e.emitWarning=()=>{},Object.assign(globalThis,require("stream/web")),e.emitWarning=t}catch(r){throw e.emitWarning=t,r}}catch{Object.assign(globalThis,$f())}try{let{Blob:e}=require("buffer");e&&!e.prototype.stream&&(e.prototype.stream=a(function(r){let n=0,o=this;return new ReadableStream({type:"bytes",async pull(l){let d=await o.slice(n,Math.min(o.size,n+65536)).arrayBuffer();n+=d.byteLength,l.enqueue(new Uint8Array(d)),n===o.size&&l.close()}})},"name"))}catch{}});async function*ms(e,t=!0){for(let r of e)if("stream"in r)yield*r.stream();else if(ArrayBuffer.isView(r))if(t){let n=r.byteOffset,o=r.byteOffset+r.byteLength;for(;n!==o;){let l=Math.min(o-n,Vf),u=r.buffer.slice(n,n+l);n+=u.byteLength,yield new Uint8Array(u)}}else yield r;else{let n=0,o=r;for(;n!==o.size;){let u=await o.slice(n,Math.min(o.size,n+Vf)).arrayBuffer();n+=u.byteLength,yield new Uint8Array(u)}}}var rS,Vf,wt,Nn,Yr,la,jt,Gf,$b,St,jn=Wn(()=>{rS=Fe(Zf(),1);Vf=65536;a(ms,"toIterator");Gf=(jt=class{constructor(t=[],r={}){Ze(this,wt,[]);Ze(this,Nn,"");Ze(this,Yr,0);Ze(this,la,"transparent");if(typeof t!="object"||t===null)throw new TypeError("Failed to construct 'Blob': The provided value cannot be converted to a sequence.");if(typeof t[Symbol.iterator]!="function")throw new TypeError("Failed to construct 'Blob': The object must have a callable @@iterator property.");if(typeof r!="object"&&typeof r!="function")throw new TypeError("Failed to construct 'Blob': parameter 2 cannot convert to dictionary.");r===null&&(r={});let n=new TextEncoder;for(let l of t){let u;ArrayBuffer.isView(l)?u=new Uint8Array(l.buffer.slice(l.byteOffset,l.byteOffset+l.byteLength)):l instanceof ArrayBuffer?u=new Uint8Array(l.slice(0)):l instanceof jt?u=l:u=n.encode(`${l}`),Se(this,Yr,te(this,Yr)+(ArrayBuffer.isView(u)?u.byteLength:u.size)),te(this,wt).push(u)}Se(this,la,`${r.endings===void 0?"transparent":r.endings}`);let o=r.type===void 0?"":String(r.type);Se(this,Nn,/^[\x20-\x7E]*$/.test(o)?o:"")}get size(){return te(this,Yr)}get type(){return te(this,Nn)}async text(){let t=new TextDecoder,r="";for await(let n of ms(te(this,wt),!1))r+=t.decode(n,{stream:!0});return r+=t.decode(),r}async arrayBuffer(){let t=new Uint8Array(this.size),r=0;for await(let n of ms(te(this,wt),!1))t.set(n,r),r+=n.length;return t.buffer}stream(){let t=ms(te(this,wt),!0);return new globalThis.ReadableStream({type:"bytes",async pull(r){let n=await t.next();n.done?r.close():r.enqueue(n.value)},async cancel(){await t.return()}})}slice(t=0,r=this.size,n=""){let{size:o}=this,l=t<0?Math.max(o+t,0):Math.min(t,o),u=r<0?Math.max(o+r,0):Math.min(r,o),d=Math.max(u-l,0),m=te(this,wt),c=[],h=0;for(let y of m){if(h>=d)break;let w=ArrayBuffer.isView(y)?y.byteLength:y.size;if(l&&w<=l)l-=w,u-=w;else{let v;ArrayBuffer.isView(y)?(v=y.subarray(l,Math.min(w,u)),h+=v.byteLength):(v=y.slice(l,Math.min(w,u)),h+=v.size),u-=w,c.push(v),l=0}}let x=new jt([],{type:String(n).toLowerCase()});return Se(x,Yr,d),Se(x,wt,c),x}get[Symbol.toStringTag](){return"Blob"}static[Symbol.hasInstance](t){return t&&typeof t=="object"&&typeof t.constructor=="function"&&(typeof t.stream=="function"||typeof t.arrayBuffer=="function")&&/^(Blob|File)$/.test(t[Symbol.toStringTag])}},wt=new WeakMap,Nn=new WeakMap,Yr=new WeakMap,la=new WeakMap,a(jt,"Blob"),jt);Object.defineProperties(Gf.prototype,{size:{enumerable:!0},type:{enumerable:!0},slice:{enumerable:!0}});$b=Gf,St=$b});var Hn,$n,Kr,Zb,Vb,Xr,gs=Wn(()=>{jn();Zb=(Kr=class extends St{constructor(r,n,o={}){if(arguments.length<2)throw new TypeError(`Failed to construct 'File': 2 arguments required, but only ${arguments.length} present.`);super(r,o);Ze(this,Hn,0);Ze(this,$n,"");o===null&&(o={});let l=o.lastModified===void 0?Date.now():Number(o.lastModified);Number.isNaN(l)||Se(this,Hn,l),Se(this,$n,String(n))}get name(){return te(this,$n)}get lastModified(){return te(this,Hn)}get[Symbol.toStringTag](){return"File"}static[Symbol.hasInstance](r){return!!r&&r instanceof St&&/^(File)$/.test(r[Symbol.toStringTag])}},Hn=new WeakMap,$n=new WeakMap,a(Kr,"File"),Kr),Vb=Zb,Xr=Vb});function Xf(e,t=St){var r=`${Yf()}${Yf()}`.replace(/\./g,"").slice(-28).padStart(32,"-"),n=[],o=`--${r}\r
|
|
1
|
+
"use strict";var qb=Object.create;var Mn=Object.defineProperty;var Ub=Object.getOwnPropertyDescriptor;var Mb=Object.getOwnPropertyNames;var Wb=Object.getPrototypeOf,Nb=Object.prototype.hasOwnProperty;var Uf=e=>{throw TypeError(e)};var a=(e,t)=>Mn(e,"name",{value:t,configurable:!0});var Wn=(e,t)=>()=>(e&&(t=e(e=0)),t);var P=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),Mf=(e,t)=>{for(var r in t)Mn(e,r,{get:t[r],enumerable:!0})},Wf=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let o of Mb(t))!Nb.call(e,o)&&o!==r&&Mn(e,o,{get:()=>t[o],enumerable:!(n=Ub(t,o))||n.enumerable});return e};var Fe=(e,t,r)=>(r=e!=null?qb(Wb(e)):{},Wf(t||!e||!e.__esModule?Mn(r,"default",{value:e,enumerable:!0}):r,e)),jb=e=>Wf(Mn({},"__esModule",{value:!0}),e);var Nf=(e,t,r)=>t.has(e)||Uf("Cannot "+r);var te=(e,t,r)=>(Nf(e,t,"read from private field"),r?r.call(e):t.get(e)),Ze=(e,t,r)=>t.has(e)?Uf("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,r),Se=(e,t,r,n)=>(Nf(e,t,"write to private field"),n?n.call(e,r):t.set(e,r),r);var $f=P((sa,Hf)=>{(function(e,t){typeof sa=="object"&&typeof Hf<"u"?t(sa):typeof define=="function"&&define.amd?define(["exports"],t):(e=typeof globalThis<"u"?globalThis:e||self,t(e.WebStreamsPolyfill={}))})(sa,function(e){"use strict";function t(){}a(t,"noop");function r(i){return typeof i=="object"&&i!==null||typeof i=="function"}a(r,"typeIsObject");let n=t;function o(i,s){try{Object.defineProperty(i,"name",{value:s,configurable:!0})}catch{}}a(o,"setFunctionName");let l=Promise,u=Promise.prototype.then,d=Promise.reject.bind(l);function m(i){return new l(i)}a(m,"newPromise");function c(i){return m(s=>s(i))}a(c,"promiseResolvedWith");function h(i){return d(i)}a(h,"promiseRejectedWith");function x(i,s,f){return u.call(i,s,f)}a(x,"PerformPromiseThen");function y(i,s,f){x(x(i,s,f),void 0,n)}a(y,"uponPromise");function w(i,s){y(i,s)}a(w,"uponFulfillment");function v(i,s){y(i,void 0,s)}a(v,"uponRejection");function E(i,s,f){return x(i,s,f)}a(E,"transformPromiseWith");function k(i){x(i,void 0,n)}a(k,"setPromiseIsHandledToTrue");let S=a(i=>{if(typeof queueMicrotask=="function")S=queueMicrotask;else{let s=c(void 0);S=a(f=>x(s,f),"_queueMicrotask")}return S(i)},"_queueMicrotask");function A(i,s,f){if(typeof i!="function")throw new TypeError("Argument is not a function");return Function.prototype.apply.call(i,s,f)}a(A,"reflectCall");function C(i,s,f){try{return c(A(i,s,f))}catch(p){return h(p)}}a(C,"promiseCall");let T=16384,Qo=class Qo{constructor(){this._cursor=0,this._size=0,this._front={_elements:[],_next:void 0},this._back=this._front,this._cursor=0,this._size=0}get length(){return this._size}push(s){let f=this._back,p=f;f._elements.length===T-1&&(p={_elements:[],_next:void 0}),f._elements.push(s),p!==f&&(this._back=p,f._next=p),++this._size}shift(){let s=this._front,f=s,p=this._cursor,g=p+1,b=s._elements,_=b[p];return g===T&&(f=s._next,g=0),--this._size,this._cursor=g,s!==f&&(this._front=f),b[p]=void 0,_}forEach(s){let f=this._cursor,p=this._front,g=p._elements;for(;(f!==g.length||p._next!==void 0)&&!(f===g.length&&(p=p._next,g=p._elements,f=0,g.length===0));)s(g[f]),++f}peek(){let s=this._front,f=this._cursor;return s._elements[f]}};a(Qo,"SimpleQueue");let R=Qo,F=Symbol("[[AbortSteps]]"),z=Symbol("[[ErrorSteps]]"),B=Symbol("[[CancelSteps]]"),M=Symbol("[[PullSteps]]"),V=Symbol("[[ReleaseSteps]]");function O(i,s){i._ownerReadableStream=s,s._reader=i,s._state==="readable"?Or(i):s._state==="closed"?Dr(i):Cn(i,s._storedError)}a(O,"ReadableStreamReaderGenericInitialize");function le(i,s){let f=i._ownerReadableStream;return He(f,s)}a(le,"ReadableStreamReaderGenericCancel");function ce(i){let s=i._ownerReadableStream;s._state==="readable"?Bt(i,new TypeError("Reader was released and can no longer be used to monitor the stream's closedness")):Ym(i,new TypeError("Reader was released and can no longer be used to monitor the stream's closedness")),s._readableStreamController[V](),s._reader=void 0,i._ownerReadableStream=void 0}a(ce,"ReadableStreamReaderGenericRelease");function mt(i){return new TypeError("Cannot "+i+" a stream using a released reader")}a(mt,"readerLockException");function Or(i){i._closedPromise=m((s,f)=>{i._closedPromise_resolve=s,i._closedPromise_reject=f})}a(Or,"defaultReaderClosedPromiseInitialize");function Cn(i,s){Or(i),Bt(i,s)}a(Cn,"defaultReaderClosedPromiseInitializeAsRejected");function Dr(i){Or(i),xu(i)}a(Dr,"defaultReaderClosedPromiseInitializeAsResolved");function Bt(i,s){i._closedPromise_reject!==void 0&&(k(i._closedPromise),i._closedPromise_reject(s),i._closedPromise_resolve=void 0,i._closedPromise_reject=void 0)}a(Bt,"defaultReaderClosedPromiseReject");function Ym(i,s){Cn(i,s)}a(Ym,"defaultReaderClosedPromiseResetToRejected");function xu(i){i._closedPromise_resolve!==void 0&&(i._closedPromise_resolve(void 0),i._closedPromise_resolve=void 0,i._closedPromise_reject=void 0)}a(xu,"defaultReaderClosedPromiseResolve");let Au=Number.isFinite||function(i){return typeof i=="number"&&isFinite(i)},Km=Math.trunc||function(i){return i<0?Math.ceil(i):Math.floor(i)};function Xm(i){return typeof i=="object"||typeof i=="function"}a(Xm,"isDictionary");function et(i,s){if(i!==void 0&&!Xm(i))throw new TypeError(`${s} is not an object.`)}a(et,"assertDictionary");function Ce(i,s){if(typeof i!="function")throw new TypeError(`${s} is not a function.`)}a(Ce,"assertFunction");function Jm(i){return typeof i=="object"&&i!==null||typeof i=="function"}a(Jm,"isObject");function ku(i,s){if(!Jm(i))throw new TypeError(`${s} is not an object.`)}a(ku,"assertObject");function gt(i,s,f){if(i===void 0)throw new TypeError(`Parameter ${s} is required in '${f}'.`)}a(gt,"assertRequiredArgument");function _o(i,s,f){if(i===void 0)throw new TypeError(`${s} is required in '${f}'.`)}a(_o,"assertRequiredField");function vo(i){return Number(i)}a(vo,"convertUnrestrictedDouble");function Eu(i){return i===0?0:i}a(Eu,"censorNegativeZero");function Qm(i){return Eu(Km(i))}a(Qm,"integerPart");function wo(i,s){let p=Number.MAX_SAFE_INTEGER,g=Number(i);if(g=Eu(g),!Au(g))throw new TypeError(`${s} is not a finite number`);if(g=Qm(g),g<0||g>p)throw new TypeError(`${s} is outside the accepted range of 0 to ${p}, inclusive`);return!Au(g)||g===0?0:g}a(wo,"convertUnsignedLongLongWithEnforceRange");function So(i,s){if(!Mt(i))throw new TypeError(`${s} is not a ReadableStream.`)}a(So,"assertReadableStream");function Br(i){return new tt(i)}a(Br,"AcquireReadableStreamDefaultReader");function Cu(i,s){i._reader._readRequests.push(s)}a(Cu,"ReadableStreamAddReadRequest");function To(i,s,f){let g=i._reader._readRequests.shift();f?g._closeSteps():g._chunkSteps(s)}a(To,"ReadableStreamFulfillReadRequest");function Di(i){return i._reader._readRequests.length}a(Di,"ReadableStreamGetNumReadRequests");function Pu(i){let s=i._reader;return!(s===void 0||!Lt(s))}a(Pu,"ReadableStreamHasDefaultReader");let es=class es{constructor(s){if(gt(s,1,"ReadableStreamDefaultReader"),So(s,"First parameter"),Wt(s))throw new TypeError("This stream has already been locked for exclusive reading by another reader");O(this,s),this._readRequests=new R}get closed(){return Lt(this)?this._closedPromise:h(Bi("closed"))}cancel(s=void 0){return Lt(this)?this._ownerReadableStream===void 0?h(mt("cancel")):le(this,s):h(Bi("cancel"))}read(){if(!Lt(this))return h(Bi("read"));if(this._ownerReadableStream===void 0)return h(mt("read from"));let s,f,p=m((b,_)=>{s=b,f=_});return Pn(this,{_chunkSteps:a(b=>s({value:b,done:!1}),"_chunkSteps"),_closeSteps:a(()=>s({value:void 0,done:!0}),"_closeSteps"),_errorSteps:a(b=>f(b),"_errorSteps")}),p}releaseLock(){if(!Lt(this))throw Bi("releaseLock");this._ownerReadableStream!==void 0&&eg(this)}};a(es,"ReadableStreamDefaultReader");let tt=es;Object.defineProperties(tt.prototype,{cancel:{enumerable:!0},read:{enumerable:!0},releaseLock:{enumerable:!0},closed:{enumerable:!0}}),o(tt.prototype.cancel,"cancel"),o(tt.prototype.read,"read"),o(tt.prototype.releaseLock,"releaseLock"),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(tt.prototype,Symbol.toStringTag,{value:"ReadableStreamDefaultReader",configurable:!0});function Lt(i){return!r(i)||!Object.prototype.hasOwnProperty.call(i,"_readRequests")?!1:i instanceof tt}a(Lt,"IsReadableStreamDefaultReader");function Pn(i,s){let f=i._ownerReadableStream;f._disturbed=!0,f._state==="closed"?s._closeSteps():f._state==="errored"?s._errorSteps(f._storedError):f._readableStreamController[M](s)}a(Pn,"ReadableStreamDefaultReaderRead");function eg(i){ce(i);let s=new TypeError("Reader was released");Iu(i,s)}a(eg,"ReadableStreamDefaultReaderRelease");function Iu(i,s){let f=i._readRequests;i._readRequests=new R,f.forEach(p=>{p._errorSteps(s)})}a(Iu,"ReadableStreamDefaultReaderErrorReadRequests");function Bi(i){return new TypeError(`ReadableStreamDefaultReader.prototype.${i} can only be used on a ReadableStreamDefaultReader`)}a(Bi,"defaultReaderBrandCheckException");let tg=Object.getPrototypeOf(Object.getPrototypeOf(async function*(){}).prototype),ts=class ts{constructor(s,f){this._ongoingPromise=void 0,this._isFinished=!1,this._reader=s,this._preventCancel=f}next(){let s=a(()=>this._nextSteps(),"nextSteps");return this._ongoingPromise=this._ongoingPromise?E(this._ongoingPromise,s,s):s(),this._ongoingPromise}return(s){let f=a(()=>this._returnSteps(s),"returnSteps");return this._ongoingPromise?E(this._ongoingPromise,f,f):f()}_nextSteps(){if(this._isFinished)return Promise.resolve({value:void 0,done:!0});let s=this._reader,f,p,g=m((_,I)=>{f=_,p=I});return Pn(s,{_chunkSteps:a(_=>{this._ongoingPromise=void 0,S(()=>f({value:_,done:!1}))},"_chunkSteps"),_closeSteps:a(()=>{this._ongoingPromise=void 0,this._isFinished=!0,ce(s),f({value:void 0,done:!0})},"_closeSteps"),_errorSteps:a(_=>{this._ongoingPromise=void 0,this._isFinished=!0,ce(s),p(_)},"_errorSteps")}),g}_returnSteps(s){if(this._isFinished)return Promise.resolve({value:s,done:!0});this._isFinished=!0;let f=this._reader;if(!this._preventCancel){let p=le(f,s);return ce(f),E(p,()=>({value:s,done:!0}))}return ce(f),c({value:s,done:!0})}};a(ts,"ReadableStreamAsyncIteratorImpl");let Li=ts,Fu={next(){return Ou(this)?this._asyncIteratorImpl.next():h(Du("next"))},return(i){return Ou(this)?this._asyncIteratorImpl.return(i):h(Du("return"))}};Object.setPrototypeOf(Fu,tg);function rg(i,s){let f=Br(i),p=new Li(f,s),g=Object.create(Fu);return g._asyncIteratorImpl=p,g}a(rg,"AcquireReadableStreamAsyncIterator");function Ou(i){if(!r(i)||!Object.prototype.hasOwnProperty.call(i,"_asyncIteratorImpl"))return!1;try{return i._asyncIteratorImpl instanceof Li}catch{return!1}}a(Ou,"IsReadableStreamAsyncIterator");function Du(i){return new TypeError(`ReadableStreamAsyncIterator.${i} can only be used on a ReadableSteamAsyncIterator`)}a(Du,"streamAsyncIteratorBrandCheckException");let Bu=Number.isNaN||function(i){return i!==i};var Ro,xo,Ao;function In(i){return i.slice()}a(In,"CreateArrayFromList");function Lu(i,s,f,p,g){new Uint8Array(i).set(new Uint8Array(f,p,g),s)}a(Lu,"CopyDataBlockBytes");let bt=a(i=>(typeof i.transfer=="function"?bt=a(s=>s.transfer(),"TransferArrayBuffer"):typeof structuredClone=="function"?bt=a(s=>structuredClone(s,{transfer:[s]}),"TransferArrayBuffer"):bt=a(s=>s,"TransferArrayBuffer"),bt(i)),"TransferArrayBuffer"),zt=a(i=>(typeof i.detached=="boolean"?zt=a(s=>s.detached,"IsDetachedBuffer"):zt=a(s=>s.byteLength===0,"IsDetachedBuffer"),zt(i)),"IsDetachedBuffer");function zu(i,s,f){if(i.slice)return i.slice(s,f);let p=f-s,g=new ArrayBuffer(p);return Lu(g,0,i,s,p),g}a(zu,"ArrayBufferSlice");function zi(i,s){let f=i[s];if(f!=null){if(typeof f!="function")throw new TypeError(`${String(s)} is not a function`);return f}}a(zi,"GetMethod");function ng(i){let s={[Symbol.iterator]:()=>i.iterator},f=async function*(){return yield*s}(),p=f.next;return{iterator:f,nextMethod:p,done:!1}}a(ng,"CreateAsyncFromSyncIterator");let ko=(Ao=(Ro=Symbol.asyncIterator)!==null&&Ro!==void 0?Ro:(xo=Symbol.for)===null||xo===void 0?void 0:xo.call(Symbol,"Symbol.asyncIterator"))!==null&&Ao!==void 0?Ao:"@@asyncIterator";function qu(i,s="sync",f){if(f===void 0)if(s==="async"){if(f=zi(i,ko),f===void 0){let b=zi(i,Symbol.iterator),_=qu(i,"sync",b);return ng(_)}}else f=zi(i,Symbol.iterator);if(f===void 0)throw new TypeError("The object is not iterable");let p=A(f,i,[]);if(!r(p))throw new TypeError("The iterator method must return an object");let g=p.next;return{iterator:p,nextMethod:g,done:!1}}a(qu,"GetIterator");function ig(i){let s=A(i.nextMethod,i.iterator,[]);if(!r(s))throw new TypeError("The iterator.next() method must return an object");return s}a(ig,"IteratorNext");function ag(i){return!!i.done}a(ag,"IteratorComplete");function og(i){return i.value}a(og,"IteratorValue");function sg(i){return!(typeof i!="number"||Bu(i)||i<0)}a(sg,"IsNonNegativeNumber");function Uu(i){let s=zu(i.buffer,i.byteOffset,i.byteOffset+i.byteLength);return new Uint8Array(s)}a(Uu,"CloneAsUint8Array");function Eo(i){let s=i._queue.shift();return i._queueTotalSize-=s.size,i._queueTotalSize<0&&(i._queueTotalSize=0),s.value}a(Eo,"DequeueValue");function Co(i,s,f){if(!sg(f)||f===1/0)throw new RangeError("Size must be a finite, non-NaN, non-negative number.");i._queue.push({value:s,size:f}),i._queueTotalSize+=f}a(Co,"EnqueueValueWithSize");function lg(i){return i._queue.peek().value}a(lg,"PeekQueueValue");function qt(i){i._queue=new R,i._queueTotalSize=0}a(qt,"ResetQueue");function Mu(i){return i===DataView}a(Mu,"isDataViewConstructor");function ug(i){return Mu(i.constructor)}a(ug,"isDataView");function fg(i){return Mu(i)?1:i.BYTES_PER_ELEMENT}a(fg,"arrayBufferViewElementSize");let rs=class rs{constructor(){throw new TypeError("Illegal constructor")}get view(){if(!Po(this))throw Bo("view");return this._view}respond(s){if(!Po(this))throw Bo("respond");if(gt(s,1,"respond"),s=wo(s,"First parameter"),this._associatedReadableByteStreamController===void 0)throw new TypeError("This BYOB request has been invalidated");if(zt(this._view.buffer))throw new TypeError("The BYOB request's buffer has been detached and so cannot be used as a response");Wi(this._associatedReadableByteStreamController,s)}respondWithNewView(s){if(!Po(this))throw Bo("respondWithNewView");if(gt(s,1,"respondWithNewView"),!ArrayBuffer.isView(s))throw new TypeError("You can only respond with array buffer views");if(this._associatedReadableByteStreamController===void 0)throw new TypeError("This BYOB request has been invalidated");if(zt(s.buffer))throw new TypeError("The given view's buffer has been detached and so cannot be used as a response");Ni(this._associatedReadableByteStreamController,s)}};a(rs,"ReadableStreamBYOBRequest");let yt=rs;Object.defineProperties(yt.prototype,{respond:{enumerable:!0},respondWithNewView:{enumerable:!0},view:{enumerable:!0}}),o(yt.prototype.respond,"respond"),o(yt.prototype.respondWithNewView,"respondWithNewView"),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(yt.prototype,Symbol.toStringTag,{value:"ReadableStreamBYOBRequest",configurable:!0});let ns=class ns{constructor(){throw new TypeError("Illegal constructor")}get byobRequest(){if(!ir(this))throw On("byobRequest");return Do(this)}get desiredSize(){if(!ir(this))throw On("desiredSize");return Ku(this)}close(){if(!ir(this))throw On("close");if(this._closeRequested)throw new TypeError("The stream has already been closed; do not close it again!");let s=this._controlledReadableByteStream._state;if(s!=="readable")throw new TypeError(`The stream (in ${s} state) is not in the readable state and cannot be closed`);Fn(this)}enqueue(s){if(!ir(this))throw On("enqueue");if(gt(s,1,"enqueue"),!ArrayBuffer.isView(s))throw new TypeError("chunk must be an array buffer view");if(s.byteLength===0)throw new TypeError("chunk must have non-zero byteLength");if(s.buffer.byteLength===0)throw new TypeError("chunk's buffer must have non-zero byteLength");if(this._closeRequested)throw new TypeError("stream is closed or draining");let f=this._controlledReadableByteStream._state;if(f!=="readable")throw new TypeError(`The stream (in ${f} state) is not in the readable state and cannot be enqueued to`);Mi(this,s)}error(s=void 0){if(!ir(this))throw On("error");Pe(this,s)}[B](s){Wu(this),qt(this);let f=this._cancelAlgorithm(s);return Ui(this),f}[M](s){let f=this._controlledReadableByteStream;if(this._queueTotalSize>0){Yu(this,s);return}let p=this._autoAllocateChunkSize;if(p!==void 0){let g;try{g=new ArrayBuffer(p)}catch(_){s._errorSteps(_);return}let b={buffer:g,bufferByteLength:p,byteOffset:0,byteLength:p,bytesFilled:0,minimumFill:1,elementSize:1,viewConstructor:Uint8Array,readerType:"default"};this._pendingPullIntos.push(b)}Cu(f,s),ar(this)}[V](){if(this._pendingPullIntos.length>0){let s=this._pendingPullIntos.peek();s.readerType="none",this._pendingPullIntos=new R,this._pendingPullIntos.push(s)}}};a(ns,"ReadableByteStreamController");let Me=ns;Object.defineProperties(Me.prototype,{close:{enumerable:!0},enqueue:{enumerable:!0},error:{enumerable:!0},byobRequest:{enumerable:!0},desiredSize:{enumerable:!0}}),o(Me.prototype.close,"close"),o(Me.prototype.enqueue,"enqueue"),o(Me.prototype.error,"error"),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(Me.prototype,Symbol.toStringTag,{value:"ReadableByteStreamController",configurable:!0});function ir(i){return!r(i)||!Object.prototype.hasOwnProperty.call(i,"_controlledReadableByteStream")?!1:i instanceof Me}a(ir,"IsReadableByteStreamController");function Po(i){return!r(i)||!Object.prototype.hasOwnProperty.call(i,"_associatedReadableByteStreamController")?!1:i instanceof yt}a(Po,"IsReadableStreamBYOBRequest");function ar(i){if(!mg(i))return;if(i._pulling){i._pullAgain=!0;return}i._pulling=!0;let f=i._pullAlgorithm();y(f,()=>(i._pulling=!1,i._pullAgain&&(i._pullAgain=!1,ar(i)),null),p=>(Pe(i,p),null))}a(ar,"ReadableByteStreamControllerCallPullIfNeeded");function Wu(i){Fo(i),i._pendingPullIntos=new R}a(Wu,"ReadableByteStreamControllerClearPendingPullIntos");function Io(i,s){let f=!1;i._state==="closed"&&(f=!0);let p=Nu(s);s.readerType==="default"?To(i,p,f):wg(i,p,f)}a(Io,"ReadableByteStreamControllerCommitPullIntoDescriptor");function Nu(i){let s=i.bytesFilled,f=i.elementSize;return new i.viewConstructor(i.buffer,i.byteOffset,s/f)}a(Nu,"ReadableByteStreamControllerConvertPullIntoDescriptor");function qi(i,s,f,p){i._queue.push({buffer:s,byteOffset:f,byteLength:p}),i._queueTotalSize+=p}a(qi,"ReadableByteStreamControllerEnqueueChunkToQueue");function ju(i,s,f,p){let g;try{g=zu(s,f,f+p)}catch(b){throw Pe(i,b),b}qi(i,g,0,p)}a(ju,"ReadableByteStreamControllerEnqueueClonedChunkToQueue");function Hu(i,s){s.bytesFilled>0&&ju(i,s.buffer,s.byteOffset,s.bytesFilled),Lr(i)}a(Hu,"ReadableByteStreamControllerEnqueueDetachedPullIntoToQueue");function $u(i,s){let f=Math.min(i._queueTotalSize,s.byteLength-s.bytesFilled),p=s.bytesFilled+f,g=f,b=!1,_=p%s.elementSize,I=p-_;I>=s.minimumFill&&(g=I-s.bytesFilled,b=!0);let q=i._queue;for(;g>0;){let D=q.peek(),U=Math.min(g,D.byteLength),W=s.byteOffset+s.bytesFilled;Lu(s.buffer,W,D.buffer,D.byteOffset,U),D.byteLength===U?q.shift():(D.byteOffset+=U,D.byteLength-=U),i._queueTotalSize-=U,Zu(i,U,s),g-=U}return b}a($u,"ReadableByteStreamControllerFillPullIntoDescriptorFromQueue");function Zu(i,s,f){f.bytesFilled+=s}a(Zu,"ReadableByteStreamControllerFillHeadPullIntoDescriptor");function Vu(i){i._queueTotalSize===0&&i._closeRequested?(Ui(i),Un(i._controlledReadableByteStream)):ar(i)}a(Vu,"ReadableByteStreamControllerHandleQueueDrain");function Fo(i){i._byobRequest!==null&&(i._byobRequest._associatedReadableByteStreamController=void 0,i._byobRequest._view=null,i._byobRequest=null)}a(Fo,"ReadableByteStreamControllerInvalidateBYOBRequest");function Oo(i){for(;i._pendingPullIntos.length>0;){if(i._queueTotalSize===0)return;let s=i._pendingPullIntos.peek();$u(i,s)&&(Lr(i),Io(i._controlledReadableByteStream,s))}}a(Oo,"ReadableByteStreamControllerProcessPullIntoDescriptorsUsingQueue");function cg(i){let s=i._controlledReadableByteStream._reader;for(;s._readRequests.length>0;){if(i._queueTotalSize===0)return;let f=s._readRequests.shift();Yu(i,f)}}a(cg,"ReadableByteStreamControllerProcessReadRequestsUsingQueue");function dg(i,s,f,p){let g=i._controlledReadableByteStream,b=s.constructor,_=fg(b),{byteOffset:I,byteLength:q}=s,D=f*_,U;try{U=bt(s.buffer)}catch(G){p._errorSteps(G);return}let W={buffer:U,bufferByteLength:U.byteLength,byteOffset:I,byteLength:q,bytesFilled:0,minimumFill:D,elementSize:_,viewConstructor:b,readerType:"byob"};if(i._pendingPullIntos.length>0){i._pendingPullIntos.push(W),Qu(g,p);return}if(g._state==="closed"){let G=new b(W.buffer,W.byteOffset,0);p._closeSteps(G);return}if(i._queueTotalSize>0){if($u(i,W)){let G=Nu(W);Vu(i),p._chunkSteps(G);return}if(i._closeRequested){let G=new TypeError("Insufficient bytes to fill elements in the given buffer");Pe(i,G),p._errorSteps(G);return}}i._pendingPullIntos.push(W),Qu(g,p),ar(i)}a(dg,"ReadableByteStreamControllerPullInto");function hg(i,s){s.readerType==="none"&&Lr(i);let f=i._controlledReadableByteStream;if(Lo(f))for(;ef(f)>0;){let p=Lr(i);Io(f,p)}}a(hg,"ReadableByteStreamControllerRespondInClosedState");function pg(i,s,f){if(Zu(i,s,f),f.readerType==="none"){Hu(i,f),Oo(i);return}if(f.bytesFilled<f.minimumFill)return;Lr(i);let p=f.bytesFilled%f.elementSize;if(p>0){let g=f.byteOffset+f.bytesFilled;ju(i,f.buffer,g-p,p)}f.bytesFilled-=p,Io(i._controlledReadableByteStream,f),Oo(i)}a(pg,"ReadableByteStreamControllerRespondInReadableState");function Gu(i,s){let f=i._pendingPullIntos.peek();Fo(i),i._controlledReadableByteStream._state==="closed"?hg(i,f):pg(i,s,f),ar(i)}a(Gu,"ReadableByteStreamControllerRespondInternal");function Lr(i){return i._pendingPullIntos.shift()}a(Lr,"ReadableByteStreamControllerShiftPendingPullInto");function mg(i){let s=i._controlledReadableByteStream;return s._state!=="readable"||i._closeRequested||!i._started?!1:!!(Pu(s)&&Di(s)>0||Lo(s)&&ef(s)>0||Ku(i)>0)}a(mg,"ReadableByteStreamControllerShouldCallPull");function Ui(i){i._pullAlgorithm=void 0,i._cancelAlgorithm=void 0}a(Ui,"ReadableByteStreamControllerClearAlgorithms");function Fn(i){let s=i._controlledReadableByteStream;if(!(i._closeRequested||s._state!=="readable")){if(i._queueTotalSize>0){i._closeRequested=!0;return}if(i._pendingPullIntos.length>0){let f=i._pendingPullIntos.peek();if(f.bytesFilled%f.elementSize!==0){let p=new TypeError("Insufficient bytes to fill elements in the given buffer");throw Pe(i,p),p}}Ui(i),Un(s)}}a(Fn,"ReadableByteStreamControllerClose");function Mi(i,s){let f=i._controlledReadableByteStream;if(i._closeRequested||f._state!=="readable")return;let{buffer:p,byteOffset:g,byteLength:b}=s;if(zt(p))throw new TypeError("chunk's buffer is detached and so cannot be enqueued");let _=bt(p);if(i._pendingPullIntos.length>0){let I=i._pendingPullIntos.peek();if(zt(I.buffer))throw new TypeError("The BYOB request's buffer has been detached and so cannot be filled with an enqueued chunk");Fo(i),I.buffer=bt(I.buffer),I.readerType==="none"&&Hu(i,I)}if(Pu(f))if(cg(i),Di(f)===0)qi(i,_,g,b);else{i._pendingPullIntos.length>0&&Lr(i);let I=new Uint8Array(_,g,b);To(f,I,!1)}else Lo(f)?(qi(i,_,g,b),Oo(i)):qi(i,_,g,b);ar(i)}a(Mi,"ReadableByteStreamControllerEnqueue");function Pe(i,s){let f=i._controlledReadableByteStream;f._state==="readable"&&(Wu(i),qt(i),Ui(i),xf(f,s))}a(Pe,"ReadableByteStreamControllerError");function Yu(i,s){let f=i._queue.shift();i._queueTotalSize-=f.byteLength,Vu(i);let p=new Uint8Array(f.buffer,f.byteOffset,f.byteLength);s._chunkSteps(p)}a(Yu,"ReadableByteStreamControllerFillReadRequestFromQueue");function Do(i){if(i._byobRequest===null&&i._pendingPullIntos.length>0){let s=i._pendingPullIntos.peek(),f=new Uint8Array(s.buffer,s.byteOffset+s.bytesFilled,s.byteLength-s.bytesFilled),p=Object.create(yt.prototype);bg(p,i,f),i._byobRequest=p}return i._byobRequest}a(Do,"ReadableByteStreamControllerGetBYOBRequest");function Ku(i){let s=i._controlledReadableByteStream._state;return s==="errored"?null:s==="closed"?0:i._strategyHWM-i._queueTotalSize}a(Ku,"ReadableByteStreamControllerGetDesiredSize");function Wi(i,s){let f=i._pendingPullIntos.peek();if(i._controlledReadableByteStream._state==="closed"){if(s!==0)throw new TypeError("bytesWritten must be 0 when calling respond() on a closed stream")}else{if(s===0)throw new TypeError("bytesWritten must be greater than 0 when calling respond() on a readable stream");if(f.bytesFilled+s>f.byteLength)throw new RangeError("bytesWritten out of range")}f.buffer=bt(f.buffer),Gu(i,s)}a(Wi,"ReadableByteStreamControllerRespond");function Ni(i,s){let f=i._pendingPullIntos.peek();if(i._controlledReadableByteStream._state==="closed"){if(s.byteLength!==0)throw new TypeError("The view's length must be 0 when calling respondWithNewView() on a closed stream")}else if(s.byteLength===0)throw new TypeError("The view's length must be greater than 0 when calling respondWithNewView() on a readable stream");if(f.byteOffset+f.bytesFilled!==s.byteOffset)throw new RangeError("The region specified by view does not match byobRequest");if(f.bufferByteLength!==s.buffer.byteLength)throw new RangeError("The buffer of view has different capacity than byobRequest");if(f.bytesFilled+s.byteLength>f.byteLength)throw new RangeError("The region specified by view is larger than byobRequest");let g=s.byteLength;f.buffer=bt(s.buffer),Gu(i,g)}a(Ni,"ReadableByteStreamControllerRespondWithNewView");function Xu(i,s,f,p,g,b,_){s._controlledReadableByteStream=i,s._pullAgain=!1,s._pulling=!1,s._byobRequest=null,s._queue=s._queueTotalSize=void 0,qt(s),s._closeRequested=!1,s._started=!1,s._strategyHWM=b,s._pullAlgorithm=p,s._cancelAlgorithm=g,s._autoAllocateChunkSize=_,s._pendingPullIntos=new R,i._readableStreamController=s;let I=f();y(c(I),()=>(s._started=!0,ar(s),null),q=>(Pe(s,q),null))}a(Xu,"SetUpReadableByteStreamController");function gg(i,s,f){let p=Object.create(Me.prototype),g,b,_;s.start!==void 0?g=a(()=>s.start(p),"startAlgorithm"):g=a(()=>{},"startAlgorithm"),s.pull!==void 0?b=a(()=>s.pull(p),"pullAlgorithm"):b=a(()=>c(void 0),"pullAlgorithm"),s.cancel!==void 0?_=a(q=>s.cancel(q),"cancelAlgorithm"):_=a(()=>c(void 0),"cancelAlgorithm");let I=s.autoAllocateChunkSize;if(I===0)throw new TypeError("autoAllocateChunkSize must be greater than 0");Xu(i,p,g,b,_,f,I)}a(gg,"SetUpReadableByteStreamControllerFromUnderlyingSource");function bg(i,s,f){i._associatedReadableByteStreamController=s,i._view=f}a(bg,"SetUpReadableStreamBYOBRequest");function Bo(i){return new TypeError(`ReadableStreamBYOBRequest.prototype.${i} can only be used on a ReadableStreamBYOBRequest`)}a(Bo,"byobRequestBrandCheckException");function On(i){return new TypeError(`ReadableByteStreamController.prototype.${i} can only be used on a ReadableByteStreamController`)}a(On,"byteStreamControllerBrandCheckException");function yg(i,s){et(i,s);let f=i==null?void 0:i.mode;return{mode:f===void 0?void 0:_g(f,`${s} has member 'mode' that`)}}a(yg,"convertReaderOptions");function _g(i,s){if(i=`${i}`,i!=="byob")throw new TypeError(`${s} '${i}' is not a valid enumeration value for ReadableStreamReaderMode`);return i}a(_g,"convertReadableStreamReaderMode");function vg(i,s){var f;et(i,s);let p=(f=i==null?void 0:i.min)!==null&&f!==void 0?f:1;return{min:wo(p,`${s} has member 'min' that`)}}a(vg,"convertByobReadOptions");function Ju(i){return new rt(i)}a(Ju,"AcquireReadableStreamBYOBReader");function Qu(i,s){i._reader._readIntoRequests.push(s)}a(Qu,"ReadableStreamAddReadIntoRequest");function wg(i,s,f){let g=i._reader._readIntoRequests.shift();f?g._closeSteps(s):g._chunkSteps(s)}a(wg,"ReadableStreamFulfillReadIntoRequest");function ef(i){return i._reader._readIntoRequests.length}a(ef,"ReadableStreamGetNumReadIntoRequests");function Lo(i){let s=i._reader;return!(s===void 0||!or(s))}a(Lo,"ReadableStreamHasBYOBReader");let is=class is{constructor(s){if(gt(s,1,"ReadableStreamBYOBReader"),So(s,"First parameter"),Wt(s))throw new TypeError("This stream has already been locked for exclusive reading by another reader");if(!ir(s._readableStreamController))throw new TypeError("Cannot construct a ReadableStreamBYOBReader for a stream not constructed with a byte source");O(this,s),this._readIntoRequests=new R}get closed(){return or(this)?this._closedPromise:h(ji("closed"))}cancel(s=void 0){return or(this)?this._ownerReadableStream===void 0?h(mt("cancel")):le(this,s):h(ji("cancel"))}read(s,f={}){if(!or(this))return h(ji("read"));if(!ArrayBuffer.isView(s))return h(new TypeError("view must be an array buffer view"));if(s.byteLength===0)return h(new TypeError("view must have non-zero byteLength"));if(s.buffer.byteLength===0)return h(new TypeError("view's buffer must have non-zero byteLength"));if(zt(s.buffer))return h(new TypeError("view's buffer has been detached"));let p;try{p=vg(f,"options")}catch(D){return h(D)}let g=p.min;if(g===0)return h(new TypeError("options.min must be greater than 0"));if(ug(s)){if(g>s.byteLength)return h(new RangeError("options.min must be less than or equal to view's byteLength"))}else if(g>s.length)return h(new RangeError("options.min must be less than or equal to view's length"));if(this._ownerReadableStream===void 0)return h(mt("read from"));let b,_,I=m((D,U)=>{b=D,_=U});return tf(this,s,g,{_chunkSteps:a(D=>b({value:D,done:!1}),"_chunkSteps"),_closeSteps:a(D=>b({value:D,done:!0}),"_closeSteps"),_errorSteps:a(D=>_(D),"_errorSteps")}),I}releaseLock(){if(!or(this))throw ji("releaseLock");this._ownerReadableStream!==void 0&&Sg(this)}};a(is,"ReadableStreamBYOBReader");let rt=is;Object.defineProperties(rt.prototype,{cancel:{enumerable:!0},read:{enumerable:!0},releaseLock:{enumerable:!0},closed:{enumerable:!0}}),o(rt.prototype.cancel,"cancel"),o(rt.prototype.read,"read"),o(rt.prototype.releaseLock,"releaseLock"),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(rt.prototype,Symbol.toStringTag,{value:"ReadableStreamBYOBReader",configurable:!0});function or(i){return!r(i)||!Object.prototype.hasOwnProperty.call(i,"_readIntoRequests")?!1:i instanceof rt}a(or,"IsReadableStreamBYOBReader");function tf(i,s,f,p){let g=i._ownerReadableStream;g._disturbed=!0,g._state==="errored"?p._errorSteps(g._storedError):dg(g._readableStreamController,s,f,p)}a(tf,"ReadableStreamBYOBReaderRead");function Sg(i){ce(i);let s=new TypeError("Reader was released");rf(i,s)}a(Sg,"ReadableStreamBYOBReaderRelease");function rf(i,s){let f=i._readIntoRequests;i._readIntoRequests=new R,f.forEach(p=>{p._errorSteps(s)})}a(rf,"ReadableStreamBYOBReaderErrorReadIntoRequests");function ji(i){return new TypeError(`ReadableStreamBYOBReader.prototype.${i} can only be used on a ReadableStreamBYOBReader`)}a(ji,"byobReaderBrandCheckException");function Dn(i,s){let{highWaterMark:f}=i;if(f===void 0)return s;if(Bu(f)||f<0)throw new RangeError("Invalid highWaterMark");return f}a(Dn,"ExtractHighWaterMark");function Hi(i){let{size:s}=i;return s||(()=>1)}a(Hi,"ExtractSizeAlgorithm");function $i(i,s){et(i,s);let f=i==null?void 0:i.highWaterMark,p=i==null?void 0:i.size;return{highWaterMark:f===void 0?void 0:vo(f),size:p===void 0?void 0:Tg(p,`${s} has member 'size' that`)}}a($i,"convertQueuingStrategy");function Tg(i,s){return Ce(i,s),f=>vo(i(f))}a(Tg,"convertQueuingStrategySize");function Rg(i,s){et(i,s);let f=i==null?void 0:i.abort,p=i==null?void 0:i.close,g=i==null?void 0:i.start,b=i==null?void 0:i.type,_=i==null?void 0:i.write;return{abort:f===void 0?void 0:xg(f,i,`${s} has member 'abort' that`),close:p===void 0?void 0:Ag(p,i,`${s} has member 'close' that`),start:g===void 0?void 0:kg(g,i,`${s} has member 'start' that`),write:_===void 0?void 0:Eg(_,i,`${s} has member 'write' that`),type:b}}a(Rg,"convertUnderlyingSink");function xg(i,s,f){return Ce(i,f),p=>C(i,s,[p])}a(xg,"convertUnderlyingSinkAbortCallback");function Ag(i,s,f){return Ce(i,f),()=>C(i,s,[])}a(Ag,"convertUnderlyingSinkCloseCallback");function kg(i,s,f){return Ce(i,f),p=>A(i,s,[p])}a(kg,"convertUnderlyingSinkStartCallback");function Eg(i,s,f){return Ce(i,f),(p,g)=>C(i,s,[p,g])}a(Eg,"convertUnderlyingSinkWriteCallback");function nf(i,s){if(!zr(i))throw new TypeError(`${s} is not a WritableStream.`)}a(nf,"assertWritableStream");function Cg(i){if(typeof i!="object"||i===null)return!1;try{return typeof i.aborted=="boolean"}catch{return!1}}a(Cg,"isAbortSignal");let Pg=typeof AbortController=="function";function Ig(){if(Pg)return new AbortController}a(Ig,"createAbortController");let as=class as{constructor(s={},f={}){s===void 0?s=null:ku(s,"First parameter");let p=$i(f,"Second parameter"),g=Rg(s,"First parameter");if(of(this),g.type!==void 0)throw new RangeError("Invalid type is specified");let _=Hi(p),I=Dn(p,1);$g(this,g,I,_)}get locked(){if(!zr(this))throw Ki("locked");return qr(this)}abort(s=void 0){return zr(this)?qr(this)?h(new TypeError("Cannot abort a stream that already has a writer")):Zi(this,s):h(Ki("abort"))}close(){return zr(this)?qr(this)?h(new TypeError("Cannot close a stream that already has a writer")):it(this)?h(new TypeError("Cannot close an already-closing stream")):sf(this):h(Ki("close"))}getWriter(){if(!zr(this))throw Ki("getWriter");return af(this)}};a(as,"WritableStream");let nt=as;Object.defineProperties(nt.prototype,{abort:{enumerable:!0},close:{enumerable:!0},getWriter:{enumerable:!0},locked:{enumerable:!0}}),o(nt.prototype.abort,"abort"),o(nt.prototype.close,"close"),o(nt.prototype.getWriter,"getWriter"),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(nt.prototype,Symbol.toStringTag,{value:"WritableStream",configurable:!0});function af(i){return new We(i)}a(af,"AcquireWritableStreamDefaultWriter");function Fg(i,s,f,p,g=1,b=()=>1){let _=Object.create(nt.prototype);of(_);let I=Object.create(Ut.prototype);return hf(_,I,i,s,f,p,g,b),_}a(Fg,"CreateWritableStream");function of(i){i._state="writable",i._storedError=void 0,i._writer=void 0,i._writableStreamController=void 0,i._writeRequests=new R,i._inFlightWriteRequest=void 0,i._closeRequest=void 0,i._inFlightCloseRequest=void 0,i._pendingAbortRequest=void 0,i._backpressure=!1}a(of,"InitializeWritableStream");function zr(i){return!r(i)||!Object.prototype.hasOwnProperty.call(i,"_writableStreamController")?!1:i instanceof nt}a(zr,"IsWritableStream");function qr(i){return i._writer!==void 0}a(qr,"IsWritableStreamLocked");function Zi(i,s){var f;if(i._state==="closed"||i._state==="errored")return c(void 0);i._writableStreamController._abortReason=s,(f=i._writableStreamController._abortController)===null||f===void 0||f.abort(s);let p=i._state;if(p==="closed"||p==="errored")return c(void 0);if(i._pendingAbortRequest!==void 0)return i._pendingAbortRequest._promise;let g=!1;p==="erroring"&&(g=!0,s=void 0);let b=m((_,I)=>{i._pendingAbortRequest={_promise:void 0,_resolve:_,_reject:I,_reason:s,_wasAlreadyErroring:g}});return i._pendingAbortRequest._promise=b,g||qo(i,s),b}a(Zi,"WritableStreamAbort");function sf(i){let s=i._state;if(s==="closed"||s==="errored")return h(new TypeError(`The stream (in ${s} state) is not in the writable state and cannot be closed`));let f=m((g,b)=>{let _={_resolve:g,_reject:b};i._closeRequest=_}),p=i._writer;return p!==void 0&&i._backpressure&&s==="writable"&&Zo(p),Zg(i._writableStreamController),f}a(sf,"WritableStreamClose");function Og(i){return m((f,p)=>{let g={_resolve:f,_reject:p};i._writeRequests.push(g)})}a(Og,"WritableStreamAddWriteRequest");function zo(i,s){if(i._state==="writable"){qo(i,s);return}Uo(i)}a(zo,"WritableStreamDealWithRejection");function qo(i,s){let f=i._writableStreamController;i._state="erroring",i._storedError=s;let p=i._writer;p!==void 0&&uf(p,s),!qg(i)&&f._started&&Uo(i)}a(qo,"WritableStreamStartErroring");function Uo(i){i._state="errored",i._writableStreamController[z]();let s=i._storedError;if(i._writeRequests.forEach(g=>{g._reject(s)}),i._writeRequests=new R,i._pendingAbortRequest===void 0){Vi(i);return}let f=i._pendingAbortRequest;if(i._pendingAbortRequest=void 0,f._wasAlreadyErroring){f._reject(s),Vi(i);return}let p=i._writableStreamController[F](f._reason);y(p,()=>(f._resolve(),Vi(i),null),g=>(f._reject(g),Vi(i),null))}a(Uo,"WritableStreamFinishErroring");function Dg(i){i._inFlightWriteRequest._resolve(void 0),i._inFlightWriteRequest=void 0}a(Dg,"WritableStreamFinishInFlightWrite");function Bg(i,s){i._inFlightWriteRequest._reject(s),i._inFlightWriteRequest=void 0,zo(i,s)}a(Bg,"WritableStreamFinishInFlightWriteWithError");function Lg(i){i._inFlightCloseRequest._resolve(void 0),i._inFlightCloseRequest=void 0,i._state==="erroring"&&(i._storedError=void 0,i._pendingAbortRequest!==void 0&&(i._pendingAbortRequest._resolve(),i._pendingAbortRequest=void 0)),i._state="closed";let f=i._writer;f!==void 0&&bf(f)}a(Lg,"WritableStreamFinishInFlightClose");function zg(i,s){i._inFlightCloseRequest._reject(s),i._inFlightCloseRequest=void 0,i._pendingAbortRequest!==void 0&&(i._pendingAbortRequest._reject(s),i._pendingAbortRequest=void 0),zo(i,s)}a(zg,"WritableStreamFinishInFlightCloseWithError");function it(i){return!(i._closeRequest===void 0&&i._inFlightCloseRequest===void 0)}a(it,"WritableStreamCloseQueuedOrInFlight");function qg(i){return!(i._inFlightWriteRequest===void 0&&i._inFlightCloseRequest===void 0)}a(qg,"WritableStreamHasOperationMarkedInFlight");function Ug(i){i._inFlightCloseRequest=i._closeRequest,i._closeRequest=void 0}a(Ug,"WritableStreamMarkCloseRequestInFlight");function Mg(i){i._inFlightWriteRequest=i._writeRequests.shift()}a(Mg,"WritableStreamMarkFirstWriteRequestInFlight");function Vi(i){i._closeRequest!==void 0&&(i._closeRequest._reject(i._storedError),i._closeRequest=void 0);let s=i._writer;s!==void 0&&Ho(s,i._storedError)}a(Vi,"WritableStreamRejectCloseAndClosedPromiseIfNeeded");function Mo(i,s){let f=i._writer;f!==void 0&&s!==i._backpressure&&(s?Qg(f):Zo(f)),i._backpressure=s}a(Mo,"WritableStreamUpdateBackpressure");let os=class os{constructor(s){if(gt(s,1,"WritableStreamDefaultWriter"),nf(s,"First parameter"),qr(s))throw new TypeError("This stream has already been locked for exclusive writing by another writer");this._ownerWritableStream=s,s._writer=this;let f=s._state;if(f==="writable")!it(s)&&s._backpressure?Ji(this):yf(this),Xi(this);else if(f==="erroring")$o(this,s._storedError),Xi(this);else if(f==="closed")yf(this),Xg(this);else{let p=s._storedError;$o(this,p),gf(this,p)}}get closed(){return sr(this)?this._closedPromise:h(lr("closed"))}get desiredSize(){if(!sr(this))throw lr("desiredSize");if(this._ownerWritableStream===void 0)throw Ln("desiredSize");return Hg(this)}get ready(){return sr(this)?this._readyPromise:h(lr("ready"))}abort(s=void 0){return sr(this)?this._ownerWritableStream===void 0?h(Ln("abort")):Wg(this,s):h(lr("abort"))}close(){if(!sr(this))return h(lr("close"));let s=this._ownerWritableStream;return s===void 0?h(Ln("close")):it(s)?h(new TypeError("Cannot close an already-closing stream")):lf(this)}releaseLock(){if(!sr(this))throw lr("releaseLock");this._ownerWritableStream!==void 0&&ff(this)}write(s=void 0){return sr(this)?this._ownerWritableStream===void 0?h(Ln("write to")):cf(this,s):h(lr("write"))}};a(os,"WritableStreamDefaultWriter");let We=os;Object.defineProperties(We.prototype,{abort:{enumerable:!0},close:{enumerable:!0},releaseLock:{enumerable:!0},write:{enumerable:!0},closed:{enumerable:!0},desiredSize:{enumerable:!0},ready:{enumerable:!0}}),o(We.prototype.abort,"abort"),o(We.prototype.close,"close"),o(We.prototype.releaseLock,"releaseLock"),o(We.prototype.write,"write"),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(We.prototype,Symbol.toStringTag,{value:"WritableStreamDefaultWriter",configurable:!0});function sr(i){return!r(i)||!Object.prototype.hasOwnProperty.call(i,"_ownerWritableStream")?!1:i instanceof We}a(sr,"IsWritableStreamDefaultWriter");function Wg(i,s){let f=i._ownerWritableStream;return Zi(f,s)}a(Wg,"WritableStreamDefaultWriterAbort");function lf(i){let s=i._ownerWritableStream;return sf(s)}a(lf,"WritableStreamDefaultWriterClose");function Ng(i){let s=i._ownerWritableStream,f=s._state;return it(s)||f==="closed"?c(void 0):f==="errored"?h(s._storedError):lf(i)}a(Ng,"WritableStreamDefaultWriterCloseWithErrorPropagation");function jg(i,s){i._closedPromiseState==="pending"?Ho(i,s):Jg(i,s)}a(jg,"WritableStreamDefaultWriterEnsureClosedPromiseRejected");function uf(i,s){i._readyPromiseState==="pending"?_f(i,s):eb(i,s)}a(uf,"WritableStreamDefaultWriterEnsureReadyPromiseRejected");function Hg(i){let s=i._ownerWritableStream,f=s._state;return f==="errored"||f==="erroring"?null:f==="closed"?0:pf(s._writableStreamController)}a(Hg,"WritableStreamDefaultWriterGetDesiredSize");function ff(i){let s=i._ownerWritableStream,f=new TypeError("Writer was released and can no longer be used to monitor the stream's closedness");uf(i,f),jg(i,f),s._writer=void 0,i._ownerWritableStream=void 0}a(ff,"WritableStreamDefaultWriterRelease");function cf(i,s){let f=i._ownerWritableStream,p=f._writableStreamController,g=Vg(p,s);if(f!==i._ownerWritableStream)return h(Ln("write to"));let b=f._state;if(b==="errored")return h(f._storedError);if(it(f)||b==="closed")return h(new TypeError("The stream is closing or closed and cannot be written to"));if(b==="erroring")return h(f._storedError);let _=Og(f);return Gg(p,s,g),_}a(cf,"WritableStreamDefaultWriterWrite");let df={},ss=class ss{constructor(){throw new TypeError("Illegal constructor")}get abortReason(){if(!Wo(this))throw jo("abortReason");return this._abortReason}get signal(){if(!Wo(this))throw jo("signal");if(this._abortController===void 0)throw new TypeError("WritableStreamDefaultController.prototype.signal is not supported");return this._abortController.signal}error(s=void 0){if(!Wo(this))throw jo("error");this._controlledWritableStream._state==="writable"&&mf(this,s)}[F](s){let f=this._abortAlgorithm(s);return Gi(this),f}[z](){qt(this)}};a(ss,"WritableStreamDefaultController");let Ut=ss;Object.defineProperties(Ut.prototype,{abortReason:{enumerable:!0},signal:{enumerable:!0},error:{enumerable:!0}}),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(Ut.prototype,Symbol.toStringTag,{value:"WritableStreamDefaultController",configurable:!0});function Wo(i){return!r(i)||!Object.prototype.hasOwnProperty.call(i,"_controlledWritableStream")?!1:i instanceof Ut}a(Wo,"IsWritableStreamDefaultController");function hf(i,s,f,p,g,b,_,I){s._controlledWritableStream=i,i._writableStreamController=s,s._queue=void 0,s._queueTotalSize=void 0,qt(s),s._abortReason=void 0,s._abortController=Ig(),s._started=!1,s._strategySizeAlgorithm=I,s._strategyHWM=_,s._writeAlgorithm=p,s._closeAlgorithm=g,s._abortAlgorithm=b;let q=No(s);Mo(i,q);let D=f(),U=c(D);y(U,()=>(s._started=!0,Yi(s),null),W=>(s._started=!0,zo(i,W),null))}a(hf,"SetUpWritableStreamDefaultController");function $g(i,s,f,p){let g=Object.create(Ut.prototype),b,_,I,q;s.start!==void 0?b=a(()=>s.start(g),"startAlgorithm"):b=a(()=>{},"startAlgorithm"),s.write!==void 0?_=a(D=>s.write(D,g),"writeAlgorithm"):_=a(()=>c(void 0),"writeAlgorithm"),s.close!==void 0?I=a(()=>s.close(),"closeAlgorithm"):I=a(()=>c(void 0),"closeAlgorithm"),s.abort!==void 0?q=a(D=>s.abort(D),"abortAlgorithm"):q=a(()=>c(void 0),"abortAlgorithm"),hf(i,g,b,_,I,q,f,p)}a($g,"SetUpWritableStreamDefaultControllerFromUnderlyingSink");function Gi(i){i._writeAlgorithm=void 0,i._closeAlgorithm=void 0,i._abortAlgorithm=void 0,i._strategySizeAlgorithm=void 0}a(Gi,"WritableStreamDefaultControllerClearAlgorithms");function Zg(i){Co(i,df,0),Yi(i)}a(Zg,"WritableStreamDefaultControllerClose");function Vg(i,s){try{return i._strategySizeAlgorithm(s)}catch(f){return Bn(i,f),1}}a(Vg,"WritableStreamDefaultControllerGetChunkSize");function pf(i){return i._strategyHWM-i._queueTotalSize}a(pf,"WritableStreamDefaultControllerGetDesiredSize");function Gg(i,s,f){try{Co(i,s,f)}catch(g){Bn(i,g);return}let p=i._controlledWritableStream;if(!it(p)&&p._state==="writable"){let g=No(i);Mo(p,g)}Yi(i)}a(Gg,"WritableStreamDefaultControllerWrite");function Yi(i){let s=i._controlledWritableStream;if(!i._started||s._inFlightWriteRequest!==void 0)return;if(s._state==="erroring"){Uo(s);return}if(i._queue.length===0)return;let p=lg(i);p===df?Yg(i):Kg(i,p)}a(Yi,"WritableStreamDefaultControllerAdvanceQueueIfNeeded");function Bn(i,s){i._controlledWritableStream._state==="writable"&&mf(i,s)}a(Bn,"WritableStreamDefaultControllerErrorIfNeeded");function Yg(i){let s=i._controlledWritableStream;Ug(s),Eo(i);let f=i._closeAlgorithm();Gi(i),y(f,()=>(Lg(s),null),p=>(zg(s,p),null))}a(Yg,"WritableStreamDefaultControllerProcessClose");function Kg(i,s){let f=i._controlledWritableStream;Mg(f);let p=i._writeAlgorithm(s);y(p,()=>{Dg(f);let g=f._state;if(Eo(i),!it(f)&&g==="writable"){let b=No(i);Mo(f,b)}return Yi(i),null},g=>(f._state==="writable"&&Gi(i),Bg(f,g),null))}a(Kg,"WritableStreamDefaultControllerProcessWrite");function No(i){return pf(i)<=0}a(No,"WritableStreamDefaultControllerGetBackpressure");function mf(i,s){let f=i._controlledWritableStream;Gi(i),qo(f,s)}a(mf,"WritableStreamDefaultControllerError");function Ki(i){return new TypeError(`WritableStream.prototype.${i} can only be used on a WritableStream`)}a(Ki,"streamBrandCheckException$2");function jo(i){return new TypeError(`WritableStreamDefaultController.prototype.${i} can only be used on a WritableStreamDefaultController`)}a(jo,"defaultControllerBrandCheckException$2");function lr(i){return new TypeError(`WritableStreamDefaultWriter.prototype.${i} can only be used on a WritableStreamDefaultWriter`)}a(lr,"defaultWriterBrandCheckException");function Ln(i){return new TypeError("Cannot "+i+" a stream using a released writer")}a(Ln,"defaultWriterLockException");function Xi(i){i._closedPromise=m((s,f)=>{i._closedPromise_resolve=s,i._closedPromise_reject=f,i._closedPromiseState="pending"})}a(Xi,"defaultWriterClosedPromiseInitialize");function gf(i,s){Xi(i),Ho(i,s)}a(gf,"defaultWriterClosedPromiseInitializeAsRejected");function Xg(i){Xi(i),bf(i)}a(Xg,"defaultWriterClosedPromiseInitializeAsResolved");function Ho(i,s){i._closedPromise_reject!==void 0&&(k(i._closedPromise),i._closedPromise_reject(s),i._closedPromise_resolve=void 0,i._closedPromise_reject=void 0,i._closedPromiseState="rejected")}a(Ho,"defaultWriterClosedPromiseReject");function Jg(i,s){gf(i,s)}a(Jg,"defaultWriterClosedPromiseResetToRejected");function bf(i){i._closedPromise_resolve!==void 0&&(i._closedPromise_resolve(void 0),i._closedPromise_resolve=void 0,i._closedPromise_reject=void 0,i._closedPromiseState="resolved")}a(bf,"defaultWriterClosedPromiseResolve");function Ji(i){i._readyPromise=m((s,f)=>{i._readyPromise_resolve=s,i._readyPromise_reject=f}),i._readyPromiseState="pending"}a(Ji,"defaultWriterReadyPromiseInitialize");function $o(i,s){Ji(i),_f(i,s)}a($o,"defaultWriterReadyPromiseInitializeAsRejected");function yf(i){Ji(i),Zo(i)}a(yf,"defaultWriterReadyPromiseInitializeAsResolved");function _f(i,s){i._readyPromise_reject!==void 0&&(k(i._readyPromise),i._readyPromise_reject(s),i._readyPromise_resolve=void 0,i._readyPromise_reject=void 0,i._readyPromiseState="rejected")}a(_f,"defaultWriterReadyPromiseReject");function Qg(i){Ji(i)}a(Qg,"defaultWriterReadyPromiseReset");function eb(i,s){$o(i,s)}a(eb,"defaultWriterReadyPromiseResetToRejected");function Zo(i){i._readyPromise_resolve!==void 0&&(i._readyPromise_resolve(void 0),i._readyPromise_resolve=void 0,i._readyPromise_reject=void 0,i._readyPromiseState="fulfilled")}a(Zo,"defaultWriterReadyPromiseResolve");function tb(){if(typeof globalThis<"u")return globalThis;if(typeof self<"u")return self;if(typeof global<"u")return global}a(tb,"getGlobals");let Vo=tb();function rb(i){if(!(typeof i=="function"||typeof i=="object")||i.name!=="DOMException")return!1;try{return new i,!0}catch{return!1}}a(rb,"isDOMExceptionConstructor");function nb(){let i=Vo==null?void 0:Vo.DOMException;return rb(i)?i:void 0}a(nb,"getFromGlobal");function ib(){let i=a(function(f,p){this.message=f||"",this.name=p||"Error",Error.captureStackTrace&&Error.captureStackTrace(this,this.constructor)},"DOMException");return o(i,"DOMException"),i.prototype=Object.create(Error.prototype),Object.defineProperty(i.prototype,"constructor",{value:i,writable:!0,configurable:!0}),i}a(ib,"createPolyfill");let ab=nb()||ib();function vf(i,s,f,p,g,b){let _=Br(i),I=af(s);i._disturbed=!0;let q=!1,D=c(void 0);return m((U,W)=>{let G;if(b!==void 0){if(G=a(()=>{let L=b.reason!==void 0?b.reason:new ab("Aborted","AbortError"),N=[];p||N.push(()=>s._state==="writable"?Zi(s,L):c(void 0)),g||N.push(()=>i._state==="readable"?He(i,L):c(void 0)),be(()=>Promise.all(N.map(Y=>Y())),!0,L)},"abortAlgorithm"),b.aborted){G();return}b.addEventListener("abort",G)}function $e(){return m((L,N)=>{function Y(we){we?L():x($r(),Y,N)}a(Y,"next"),Y(!1)})}a($e,"pipeLoop");function $r(){return q?c(!0):x(I._readyPromise,()=>m((L,N)=>{Pn(_,{_chunkSteps:a(Y=>{D=x(cf(I,Y),void 0,t),L(!1)},"_chunkSteps"),_closeSteps:a(()=>L(!0),"_closeSteps"),_errorSteps:N})}))}if(a($r,"pipeStep"),_t(i,_._closedPromise,L=>(p?Ie(!0,L):be(()=>Zi(s,L),!0,L),null)),_t(s,I._closedPromise,L=>(g?Ie(!0,L):be(()=>He(i,L),!0,L),null)),pe(i,_._closedPromise,()=>(f?Ie():be(()=>Ng(I)),null)),it(s)||s._state==="closed"){let L=new TypeError("the destination writable stream closed before all data could be piped to it");g?Ie(!0,L):be(()=>He(i,L),!0,L)}k($e());function Nt(){let L=D;return x(D,()=>L!==D?Nt():void 0)}a(Nt,"waitForWritesToFinish");function _t(L,N,Y){L._state==="errored"?Y(L._storedError):v(N,Y)}a(_t,"isOrBecomesErrored");function pe(L,N,Y){L._state==="closed"?Y():w(N,Y)}a(pe,"isOrBecomesClosed");function be(L,N,Y){if(q)return;q=!0,s._state==="writable"&&!it(s)?w(Nt(),we):we();function we(){return y(L(),()=>vt(N,Y),Zr=>vt(!0,Zr)),null}a(we,"doTheRest")}a(be,"shutdownWithAction");function Ie(L,N){q||(q=!0,s._state==="writable"&&!it(s)?w(Nt(),()=>vt(L,N)):vt(L,N))}a(Ie,"shutdown");function vt(L,N){return ff(I),ce(_),b!==void 0&&b.removeEventListener("abort",G),L?W(N):U(void 0),null}a(vt,"finalize")})}a(vf,"ReadableStreamPipeTo");let ls=class ls{constructor(){throw new TypeError("Illegal constructor")}get desiredSize(){if(!Qi(this))throw ta("desiredSize");return Go(this)}close(){if(!Qi(this))throw ta("close");if(!Mr(this))throw new TypeError("The stream is not in a state that permits close");ur(this)}enqueue(s=void 0){if(!Qi(this))throw ta("enqueue");if(!Mr(this))throw new TypeError("The stream is not in a state that permits enqueue");return Ur(this,s)}error(s=void 0){if(!Qi(this))throw ta("error");je(this,s)}[B](s){qt(this);let f=this._cancelAlgorithm(s);return ea(this),f}[M](s){let f=this._controlledReadableStream;if(this._queue.length>0){let p=Eo(this);this._closeRequested&&this._queue.length===0?(ea(this),Un(f)):zn(this),s._chunkSteps(p)}else Cu(f,s),zn(this)}[V](){}};a(ls,"ReadableStreamDefaultController");let Ne=ls;Object.defineProperties(Ne.prototype,{close:{enumerable:!0},enqueue:{enumerable:!0},error:{enumerable:!0},desiredSize:{enumerable:!0}}),o(Ne.prototype.close,"close"),o(Ne.prototype.enqueue,"enqueue"),o(Ne.prototype.error,"error"),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(Ne.prototype,Symbol.toStringTag,{value:"ReadableStreamDefaultController",configurable:!0});function Qi(i){return!r(i)||!Object.prototype.hasOwnProperty.call(i,"_controlledReadableStream")?!1:i instanceof Ne}a(Qi,"IsReadableStreamDefaultController");function zn(i){if(!wf(i))return;if(i._pulling){i._pullAgain=!0;return}i._pulling=!0;let f=i._pullAlgorithm();y(f,()=>(i._pulling=!1,i._pullAgain&&(i._pullAgain=!1,zn(i)),null),p=>(je(i,p),null))}a(zn,"ReadableStreamDefaultControllerCallPullIfNeeded");function wf(i){let s=i._controlledReadableStream;return!Mr(i)||!i._started?!1:!!(Wt(s)&&Di(s)>0||Go(i)>0)}a(wf,"ReadableStreamDefaultControllerShouldCallPull");function ea(i){i._pullAlgorithm=void 0,i._cancelAlgorithm=void 0,i._strategySizeAlgorithm=void 0}a(ea,"ReadableStreamDefaultControllerClearAlgorithms");function ur(i){if(!Mr(i))return;let s=i._controlledReadableStream;i._closeRequested=!0,i._queue.length===0&&(ea(i),Un(s))}a(ur,"ReadableStreamDefaultControllerClose");function Ur(i,s){if(!Mr(i))return;let f=i._controlledReadableStream;if(Wt(f)&&Di(f)>0)To(f,s,!1);else{let p;try{p=i._strategySizeAlgorithm(s)}catch(g){throw je(i,g),g}try{Co(i,s,p)}catch(g){throw je(i,g),g}}zn(i)}a(Ur,"ReadableStreamDefaultControllerEnqueue");function je(i,s){let f=i._controlledReadableStream;f._state==="readable"&&(qt(i),ea(i),xf(f,s))}a(je,"ReadableStreamDefaultControllerError");function Go(i){let s=i._controlledReadableStream._state;return s==="errored"?null:s==="closed"?0:i._strategyHWM-i._queueTotalSize}a(Go,"ReadableStreamDefaultControllerGetDesiredSize");function ob(i){return!wf(i)}a(ob,"ReadableStreamDefaultControllerHasBackpressure");function Mr(i){let s=i._controlledReadableStream._state;return!i._closeRequested&&s==="readable"}a(Mr,"ReadableStreamDefaultControllerCanCloseOrEnqueue");function Sf(i,s,f,p,g,b,_){s._controlledReadableStream=i,s._queue=void 0,s._queueTotalSize=void 0,qt(s),s._started=!1,s._closeRequested=!1,s._pullAgain=!1,s._pulling=!1,s._strategySizeAlgorithm=_,s._strategyHWM=b,s._pullAlgorithm=p,s._cancelAlgorithm=g,i._readableStreamController=s;let I=f();y(c(I),()=>(s._started=!0,zn(s),null),q=>(je(s,q),null))}a(Sf,"SetUpReadableStreamDefaultController");function sb(i,s,f,p){let g=Object.create(Ne.prototype),b,_,I;s.start!==void 0?b=a(()=>s.start(g),"startAlgorithm"):b=a(()=>{},"startAlgorithm"),s.pull!==void 0?_=a(()=>s.pull(g),"pullAlgorithm"):_=a(()=>c(void 0),"pullAlgorithm"),s.cancel!==void 0?I=a(q=>s.cancel(q),"cancelAlgorithm"):I=a(()=>c(void 0),"cancelAlgorithm"),Sf(i,g,b,_,I,f,p)}a(sb,"SetUpReadableStreamDefaultControllerFromUnderlyingSource");function ta(i){return new TypeError(`ReadableStreamDefaultController.prototype.${i} can only be used on a ReadableStreamDefaultController`)}a(ta,"defaultControllerBrandCheckException$1");function lb(i,s){return ir(i._readableStreamController)?fb(i):ub(i)}a(lb,"ReadableStreamTee");function ub(i,s){let f=Br(i),p=!1,g=!1,b=!1,_=!1,I,q,D,U,W,G=m(pe=>{W=pe});function $e(){return p?(g=!0,c(void 0)):(p=!0,Pn(f,{_chunkSteps:a(be=>{S(()=>{g=!1;let Ie=be,vt=be;b||Ur(D._readableStreamController,Ie),_||Ur(U._readableStreamController,vt),p=!1,g&&$e()})},"_chunkSteps"),_closeSteps:a(()=>{p=!1,b||ur(D._readableStreamController),_||ur(U._readableStreamController),(!b||!_)&&W(void 0)},"_closeSteps"),_errorSteps:a(()=>{p=!1},"_errorSteps")}),c(void 0))}a($e,"pullAlgorithm");function $r(pe){if(b=!0,I=pe,_){let be=In([I,q]),Ie=He(i,be);W(Ie)}return G}a($r,"cancel1Algorithm");function Nt(pe){if(_=!0,q=pe,b){let be=In([I,q]),Ie=He(i,be);W(Ie)}return G}a(Nt,"cancel2Algorithm");function _t(){}return a(_t,"startAlgorithm"),D=qn(_t,$e,$r),U=qn(_t,$e,Nt),v(f._closedPromise,pe=>(je(D._readableStreamController,pe),je(U._readableStreamController,pe),(!b||!_)&&W(void 0),null)),[D,U]}a(ub,"ReadableStreamDefaultTee");function fb(i){let s=Br(i),f=!1,p=!1,g=!1,b=!1,_=!1,I,q,D,U,W,G=m(L=>{W=L});function $e(L){v(L._closedPromise,N=>(L!==s||(Pe(D._readableStreamController,N),Pe(U._readableStreamController,N),(!b||!_)&&W(void 0)),null))}a($e,"forwardReaderError");function $r(){or(s)&&(ce(s),s=Br(i),$e(s)),Pn(s,{_chunkSteps:a(N=>{S(()=>{p=!1,g=!1;let Y=N,we=N;if(!b&&!_)try{we=Uu(N)}catch(Zr){Pe(D._readableStreamController,Zr),Pe(U._readableStreamController,Zr),W(He(i,Zr));return}b||Mi(D._readableStreamController,Y),_||Mi(U._readableStreamController,we),f=!1,p?_t():g&&pe()})},"_chunkSteps"),_closeSteps:a(()=>{f=!1,b||Fn(D._readableStreamController),_||Fn(U._readableStreamController),D._readableStreamController._pendingPullIntos.length>0&&Wi(D._readableStreamController,0),U._readableStreamController._pendingPullIntos.length>0&&Wi(U._readableStreamController,0),(!b||!_)&&W(void 0)},"_closeSteps"),_errorSteps:a(()=>{f=!1},"_errorSteps")})}a($r,"pullWithDefaultReader");function Nt(L,N){Lt(s)&&(ce(s),s=Ju(i),$e(s));let Y=N?U:D,we=N?D:U;tf(s,L,1,{_chunkSteps:a(Vr=>{S(()=>{p=!1,g=!1;let Gr=N?_:b;if(N?b:_)Gr||Ni(Y._readableStreamController,Vr);else{let qf;try{qf=Uu(Vr)}catch(ps){Pe(Y._readableStreamController,ps),Pe(we._readableStreamController,ps),W(He(i,ps));return}Gr||Ni(Y._readableStreamController,Vr),Mi(we._readableStreamController,qf)}f=!1,p?_t():g&&pe()})},"_chunkSteps"),_closeSteps:a(Vr=>{f=!1;let Gr=N?_:b,oa=N?b:_;Gr||Fn(Y._readableStreamController),oa||Fn(we._readableStreamController),Vr!==void 0&&(Gr||Ni(Y._readableStreamController,Vr),!oa&&we._readableStreamController._pendingPullIntos.length>0&&Wi(we._readableStreamController,0)),(!Gr||!oa)&&W(void 0)},"_closeSteps"),_errorSteps:a(()=>{f=!1},"_errorSteps")})}a(Nt,"pullWithBYOBReader");function _t(){if(f)return p=!0,c(void 0);f=!0;let L=Do(D._readableStreamController);return L===null?$r():Nt(L._view,!1),c(void 0)}a(_t,"pull1Algorithm");function pe(){if(f)return g=!0,c(void 0);f=!0;let L=Do(U._readableStreamController);return L===null?$r():Nt(L._view,!0),c(void 0)}a(pe,"pull2Algorithm");function be(L){if(b=!0,I=L,_){let N=In([I,q]),Y=He(i,N);W(Y)}return G}a(be,"cancel1Algorithm");function Ie(L){if(_=!0,q=L,b){let N=In([I,q]),Y=He(i,N);W(Y)}return G}a(Ie,"cancel2Algorithm");function vt(){}return a(vt,"startAlgorithm"),D=Rf(vt,_t,be),U=Rf(vt,pe,Ie),$e(s),[D,U]}a(fb,"ReadableByteStreamTee");function cb(i){return r(i)&&typeof i.getReader<"u"}a(cb,"isReadableStreamLike");function db(i){return cb(i)?pb(i.getReader()):hb(i)}a(db,"ReadableStreamFrom");function hb(i){let s,f=qu(i,"async"),p=t;function g(){let _;try{_=ig(f)}catch(q){return h(q)}let I=c(_);return E(I,q=>{if(!r(q))throw new TypeError("The promise returned by the iterator.next() method must fulfill with an object");if(ag(q))ur(s._readableStreamController);else{let U=og(q);Ur(s._readableStreamController,U)}})}a(g,"pullAlgorithm");function b(_){let I=f.iterator,q;try{q=zi(I,"return")}catch(W){return h(W)}if(q===void 0)return c(void 0);let D;try{D=A(q,I,[_])}catch(W){return h(W)}let U=c(D);return E(U,W=>{if(!r(W))throw new TypeError("The promise returned by the iterator.return() method must fulfill with an object")})}return a(b,"cancelAlgorithm"),s=qn(p,g,b,0),s}a(hb,"ReadableStreamFromIterable");function pb(i){let s,f=t;function p(){let b;try{b=i.read()}catch(_){return h(_)}return E(b,_=>{if(!r(_))throw new TypeError("The promise returned by the reader.read() method must fulfill with an object");if(_.done)ur(s._readableStreamController);else{let I=_.value;Ur(s._readableStreamController,I)}})}a(p,"pullAlgorithm");function g(b){try{return c(i.cancel(b))}catch(_){return h(_)}}return a(g,"cancelAlgorithm"),s=qn(f,p,g,0),s}a(pb,"ReadableStreamFromDefaultReader");function mb(i,s){et(i,s);let f=i,p=f==null?void 0:f.autoAllocateChunkSize,g=f==null?void 0:f.cancel,b=f==null?void 0:f.pull,_=f==null?void 0:f.start,I=f==null?void 0:f.type;return{autoAllocateChunkSize:p===void 0?void 0:wo(p,`${s} has member 'autoAllocateChunkSize' that`),cancel:g===void 0?void 0:gb(g,f,`${s} has member 'cancel' that`),pull:b===void 0?void 0:bb(b,f,`${s} has member 'pull' that`),start:_===void 0?void 0:yb(_,f,`${s} has member 'start' that`),type:I===void 0?void 0:_b(I,`${s} has member 'type' that`)}}a(mb,"convertUnderlyingDefaultOrByteSource");function gb(i,s,f){return Ce(i,f),p=>C(i,s,[p])}a(gb,"convertUnderlyingSourceCancelCallback");function bb(i,s,f){return Ce(i,f),p=>C(i,s,[p])}a(bb,"convertUnderlyingSourcePullCallback");function yb(i,s,f){return Ce(i,f),p=>A(i,s,[p])}a(yb,"convertUnderlyingSourceStartCallback");function _b(i,s){if(i=`${i}`,i!=="bytes")throw new TypeError(`${s} '${i}' is not a valid enumeration value for ReadableStreamType`);return i}a(_b,"convertReadableStreamType");function vb(i,s){return et(i,s),{preventCancel:!!(i==null?void 0:i.preventCancel)}}a(vb,"convertIteratorOptions");function Tf(i,s){et(i,s);let f=i==null?void 0:i.preventAbort,p=i==null?void 0:i.preventCancel,g=i==null?void 0:i.preventClose,b=i==null?void 0:i.signal;return b!==void 0&&wb(b,`${s} has member 'signal' that`),{preventAbort:!!f,preventCancel:!!p,preventClose:!!g,signal:b}}a(Tf,"convertPipeOptions");function wb(i,s){if(!Cg(i))throw new TypeError(`${s} is not an AbortSignal.`)}a(wb,"assertAbortSignal");function Sb(i,s){et(i,s);let f=i==null?void 0:i.readable;_o(f,"readable","ReadableWritablePair"),So(f,`${s} has member 'readable' that`);let p=i==null?void 0:i.writable;return _o(p,"writable","ReadableWritablePair"),nf(p,`${s} has member 'writable' that`),{readable:f,writable:p}}a(Sb,"convertReadableWritablePair");let us=class us{constructor(s={},f={}){s===void 0?s=null:ku(s,"First parameter");let p=$i(f,"Second parameter"),g=mb(s,"First parameter");if(Yo(this),g.type==="bytes"){if(p.size!==void 0)throw new RangeError("The strategy for a byte stream cannot have a size function");let b=Dn(p,0);gg(this,g,b)}else{let b=Hi(p),_=Dn(p,1);sb(this,g,_,b)}}get locked(){if(!Mt(this))throw fr("locked");return Wt(this)}cancel(s=void 0){return Mt(this)?Wt(this)?h(new TypeError("Cannot cancel a stream that already has a reader")):He(this,s):h(fr("cancel"))}getReader(s=void 0){if(!Mt(this))throw fr("getReader");return yg(s,"First parameter").mode===void 0?Br(this):Ju(this)}pipeThrough(s,f={}){if(!Mt(this))throw fr("pipeThrough");gt(s,1,"pipeThrough");let p=Sb(s,"First parameter"),g=Tf(f,"Second parameter");if(Wt(this))throw new TypeError("ReadableStream.prototype.pipeThrough cannot be used on a locked ReadableStream");if(qr(p.writable))throw new TypeError("ReadableStream.prototype.pipeThrough cannot be used on a locked WritableStream");let b=vf(this,p.writable,g.preventClose,g.preventAbort,g.preventCancel,g.signal);return k(b),p.readable}pipeTo(s,f={}){if(!Mt(this))return h(fr("pipeTo"));if(s===void 0)return h("Parameter 1 is required in 'pipeTo'.");if(!zr(s))return h(new TypeError("ReadableStream.prototype.pipeTo's first argument must be a WritableStream"));let p;try{p=Tf(f,"Second parameter")}catch(g){return h(g)}return Wt(this)?h(new TypeError("ReadableStream.prototype.pipeTo cannot be used on a locked ReadableStream")):qr(s)?h(new TypeError("ReadableStream.prototype.pipeTo cannot be used on a locked WritableStream")):vf(this,s,p.preventClose,p.preventAbort,p.preventCancel,p.signal)}tee(){if(!Mt(this))throw fr("tee");let s=lb(this);return In(s)}values(s=void 0){if(!Mt(this))throw fr("values");let f=vb(s,"First parameter");return rg(this,f.preventCancel)}[ko](s){return this.values(s)}static from(s){return db(s)}};a(us,"ReadableStream");let oe=us;Object.defineProperties(oe,{from:{enumerable:!0}}),Object.defineProperties(oe.prototype,{cancel:{enumerable:!0},getReader:{enumerable:!0},pipeThrough:{enumerable:!0},pipeTo:{enumerable:!0},tee:{enumerable:!0},values:{enumerable:!0},locked:{enumerable:!0}}),o(oe.from,"from"),o(oe.prototype.cancel,"cancel"),o(oe.prototype.getReader,"getReader"),o(oe.prototype.pipeThrough,"pipeThrough"),o(oe.prototype.pipeTo,"pipeTo"),o(oe.prototype.tee,"tee"),o(oe.prototype.values,"values"),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(oe.prototype,Symbol.toStringTag,{value:"ReadableStream",configurable:!0}),Object.defineProperty(oe.prototype,ko,{value:oe.prototype.values,writable:!0,configurable:!0});function qn(i,s,f,p=1,g=()=>1){let b=Object.create(oe.prototype);Yo(b);let _=Object.create(Ne.prototype);return Sf(b,_,i,s,f,p,g),b}a(qn,"CreateReadableStream");function Rf(i,s,f){let p=Object.create(oe.prototype);Yo(p);let g=Object.create(Me.prototype);return Xu(p,g,i,s,f,0,void 0),p}a(Rf,"CreateReadableByteStream");function Yo(i){i._state="readable",i._reader=void 0,i._storedError=void 0,i._disturbed=!1}a(Yo,"InitializeReadableStream");function Mt(i){return!r(i)||!Object.prototype.hasOwnProperty.call(i,"_readableStreamController")?!1:i instanceof oe}a(Mt,"IsReadableStream");function Wt(i){return i._reader!==void 0}a(Wt,"IsReadableStreamLocked");function He(i,s){if(i._disturbed=!0,i._state==="closed")return c(void 0);if(i._state==="errored")return h(i._storedError);Un(i);let f=i._reader;if(f!==void 0&&or(f)){let g=f._readIntoRequests;f._readIntoRequests=new R,g.forEach(b=>{b._closeSteps(void 0)})}let p=i._readableStreamController[B](s);return E(p,t)}a(He,"ReadableStreamCancel");function Un(i){i._state="closed";let s=i._reader;if(s!==void 0&&(xu(s),Lt(s))){let f=s._readRequests;s._readRequests=new R,f.forEach(p=>{p._closeSteps()})}}a(Un,"ReadableStreamClose");function xf(i,s){i._state="errored",i._storedError=s;let f=i._reader;f!==void 0&&(Bt(f,s),Lt(f)?Iu(f,s):rf(f,s))}a(xf,"ReadableStreamError");function fr(i){return new TypeError(`ReadableStream.prototype.${i} can only be used on a ReadableStream`)}a(fr,"streamBrandCheckException$1");function Af(i,s){et(i,s);let f=i==null?void 0:i.highWaterMark;return _o(f,"highWaterMark","QueuingStrategyInit"),{highWaterMark:vo(f)}}a(Af,"convertQueuingStrategyInit");let kf=a(i=>i.byteLength,"byteLengthSizeFunction");o(kf,"size");let fs=class fs{constructor(s){gt(s,1,"ByteLengthQueuingStrategy"),s=Af(s,"First parameter"),this._byteLengthQueuingStrategyHighWaterMark=s.highWaterMark}get highWaterMark(){if(!Cf(this))throw Ef("highWaterMark");return this._byteLengthQueuingStrategyHighWaterMark}get size(){if(!Cf(this))throw Ef("size");return kf}};a(fs,"ByteLengthQueuingStrategy");let Wr=fs;Object.defineProperties(Wr.prototype,{highWaterMark:{enumerable:!0},size:{enumerable:!0}}),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(Wr.prototype,Symbol.toStringTag,{value:"ByteLengthQueuingStrategy",configurable:!0});function Ef(i){return new TypeError(`ByteLengthQueuingStrategy.prototype.${i} can only be used on a ByteLengthQueuingStrategy`)}a(Ef,"byteLengthBrandCheckException");function Cf(i){return!r(i)||!Object.prototype.hasOwnProperty.call(i,"_byteLengthQueuingStrategyHighWaterMark")?!1:i instanceof Wr}a(Cf,"IsByteLengthQueuingStrategy");let Pf=a(()=>1,"countSizeFunction");o(Pf,"size");let cs=class cs{constructor(s){gt(s,1,"CountQueuingStrategy"),s=Af(s,"First parameter"),this._countQueuingStrategyHighWaterMark=s.highWaterMark}get highWaterMark(){if(!Ff(this))throw If("highWaterMark");return this._countQueuingStrategyHighWaterMark}get size(){if(!Ff(this))throw If("size");return Pf}};a(cs,"CountQueuingStrategy");let Nr=cs;Object.defineProperties(Nr.prototype,{highWaterMark:{enumerable:!0},size:{enumerable:!0}}),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(Nr.prototype,Symbol.toStringTag,{value:"CountQueuingStrategy",configurable:!0});function If(i){return new TypeError(`CountQueuingStrategy.prototype.${i} can only be used on a CountQueuingStrategy`)}a(If,"countBrandCheckException");function Ff(i){return!r(i)||!Object.prototype.hasOwnProperty.call(i,"_countQueuingStrategyHighWaterMark")?!1:i instanceof Nr}a(Ff,"IsCountQueuingStrategy");function Tb(i,s){et(i,s);let f=i==null?void 0:i.cancel,p=i==null?void 0:i.flush,g=i==null?void 0:i.readableType,b=i==null?void 0:i.start,_=i==null?void 0:i.transform,I=i==null?void 0:i.writableType;return{cancel:f===void 0?void 0:kb(f,i,`${s} has member 'cancel' that`),flush:p===void 0?void 0:Rb(p,i,`${s} has member 'flush' that`),readableType:g,start:b===void 0?void 0:xb(b,i,`${s} has member 'start' that`),transform:_===void 0?void 0:Ab(_,i,`${s} has member 'transform' that`),writableType:I}}a(Tb,"convertTransformer");function Rb(i,s,f){return Ce(i,f),p=>C(i,s,[p])}a(Rb,"convertTransformerFlushCallback");function xb(i,s,f){return Ce(i,f),p=>A(i,s,[p])}a(xb,"convertTransformerStartCallback");function Ab(i,s,f){return Ce(i,f),(p,g)=>C(i,s,[p,g])}a(Ab,"convertTransformerTransformCallback");function kb(i,s,f){return Ce(i,f),p=>C(i,s,[p])}a(kb,"convertTransformerCancelCallback");let ds=class ds{constructor(s={},f={},p={}){s===void 0&&(s=null);let g=$i(f,"Second parameter"),b=$i(p,"Third parameter"),_=Tb(s,"First parameter");if(_.readableType!==void 0)throw new RangeError("Invalid readableType specified");if(_.writableType!==void 0)throw new RangeError("Invalid writableType specified");let I=Dn(b,0),q=Hi(b),D=Dn(g,1),U=Hi(g),W,G=m($e=>{W=$e});Eb(this,G,D,U,I,q),Pb(this,_),_.start!==void 0?W(_.start(this._transformStreamController)):W(void 0)}get readable(){if(!Of(this))throw zf("readable");return this._readable}get writable(){if(!Of(this))throw zf("writable");return this._writable}};a(ds,"TransformStream");let jr=ds;Object.defineProperties(jr.prototype,{readable:{enumerable:!0},writable:{enumerable:!0}}),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(jr.prototype,Symbol.toStringTag,{value:"TransformStream",configurable:!0});function Eb(i,s,f,p,g,b){function _(){return s}a(_,"startAlgorithm");function I(G){return Ob(i,G)}a(I,"writeAlgorithm");function q(G){return Db(i,G)}a(q,"abortAlgorithm");function D(){return Bb(i)}a(D,"closeAlgorithm"),i._writable=Fg(_,I,D,q,f,p);function U(){return Lb(i)}a(U,"pullAlgorithm");function W(G){return zb(i,G)}a(W,"cancelAlgorithm"),i._readable=qn(_,U,W,g,b),i._backpressure=void 0,i._backpressureChangePromise=void 0,i._backpressureChangePromise_resolve=void 0,ra(i,!0),i._transformStreamController=void 0}a(Eb,"InitializeTransformStream");function Of(i){return!r(i)||!Object.prototype.hasOwnProperty.call(i,"_transformStreamController")?!1:i instanceof jr}a(Of,"IsTransformStream");function Df(i,s){je(i._readable._readableStreamController,s),Ko(i,s)}a(Df,"TransformStreamError");function Ko(i,s){ia(i._transformStreamController),Bn(i._writable._writableStreamController,s),Xo(i)}a(Ko,"TransformStreamErrorWritableAndUnblockWrite");function Xo(i){i._backpressure&&ra(i,!1)}a(Xo,"TransformStreamUnblockWrite");function ra(i,s){i._backpressureChangePromise!==void 0&&i._backpressureChangePromise_resolve(),i._backpressureChangePromise=m(f=>{i._backpressureChangePromise_resolve=f}),i._backpressure=s}a(ra,"TransformStreamSetBackpressure");let hs=class hs{constructor(){throw new TypeError("Illegal constructor")}get desiredSize(){if(!na(this))throw aa("desiredSize");let s=this._controlledTransformStream._readable._readableStreamController;return Go(s)}enqueue(s=void 0){if(!na(this))throw aa("enqueue");Bf(this,s)}error(s=void 0){if(!na(this))throw aa("error");Ib(this,s)}terminate(){if(!na(this))throw aa("terminate");Fb(this)}};a(hs,"TransformStreamDefaultController");let at=hs;Object.defineProperties(at.prototype,{enqueue:{enumerable:!0},error:{enumerable:!0},terminate:{enumerable:!0},desiredSize:{enumerable:!0}}),o(at.prototype.enqueue,"enqueue"),o(at.prototype.error,"error"),o(at.prototype.terminate,"terminate"),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(at.prototype,Symbol.toStringTag,{value:"TransformStreamDefaultController",configurable:!0});function na(i){return!r(i)||!Object.prototype.hasOwnProperty.call(i,"_controlledTransformStream")?!1:i instanceof at}a(na,"IsTransformStreamDefaultController");function Cb(i,s,f,p,g){s._controlledTransformStream=i,i._transformStreamController=s,s._transformAlgorithm=f,s._flushAlgorithm=p,s._cancelAlgorithm=g,s._finishPromise=void 0,s._finishPromise_resolve=void 0,s._finishPromise_reject=void 0}a(Cb,"SetUpTransformStreamDefaultController");function Pb(i,s){let f=Object.create(at.prototype),p,g,b;s.transform!==void 0?p=a(_=>s.transform(_,f),"transformAlgorithm"):p=a(_=>{try{return Bf(f,_),c(void 0)}catch(I){return h(I)}},"transformAlgorithm"),s.flush!==void 0?g=a(()=>s.flush(f),"flushAlgorithm"):g=a(()=>c(void 0),"flushAlgorithm"),s.cancel!==void 0?b=a(_=>s.cancel(_),"cancelAlgorithm"):b=a(()=>c(void 0),"cancelAlgorithm"),Cb(i,f,p,g,b)}a(Pb,"SetUpTransformStreamDefaultControllerFromTransformer");function ia(i){i._transformAlgorithm=void 0,i._flushAlgorithm=void 0,i._cancelAlgorithm=void 0}a(ia,"TransformStreamDefaultControllerClearAlgorithms");function Bf(i,s){let f=i._controlledTransformStream,p=f._readable._readableStreamController;if(!Mr(p))throw new TypeError("Readable side is not in a state that permits enqueue");try{Ur(p,s)}catch(b){throw Ko(f,b),f._readable._storedError}ob(p)!==f._backpressure&&ra(f,!0)}a(Bf,"TransformStreamDefaultControllerEnqueue");function Ib(i,s){Df(i._controlledTransformStream,s)}a(Ib,"TransformStreamDefaultControllerError");function Lf(i,s){let f=i._transformAlgorithm(s);return E(f,void 0,p=>{throw Df(i._controlledTransformStream,p),p})}a(Lf,"TransformStreamDefaultControllerPerformTransform");function Fb(i){let s=i._controlledTransformStream,f=s._readable._readableStreamController;ur(f);let p=new TypeError("TransformStream terminated");Ko(s,p)}a(Fb,"TransformStreamDefaultControllerTerminate");function Ob(i,s){let f=i._transformStreamController;if(i._backpressure){let p=i._backpressureChangePromise;return E(p,()=>{let g=i._writable;if(g._state==="erroring")throw g._storedError;return Lf(f,s)})}return Lf(f,s)}a(Ob,"TransformStreamDefaultSinkWriteAlgorithm");function Db(i,s){let f=i._transformStreamController;if(f._finishPromise!==void 0)return f._finishPromise;let p=i._readable;f._finishPromise=m((b,_)=>{f._finishPromise_resolve=b,f._finishPromise_reject=_});let g=f._cancelAlgorithm(s);return ia(f),y(g,()=>(p._state==="errored"?Hr(f,p._storedError):(je(p._readableStreamController,s),Jo(f)),null),b=>(je(p._readableStreamController,b),Hr(f,b),null)),f._finishPromise}a(Db,"TransformStreamDefaultSinkAbortAlgorithm");function Bb(i){let s=i._transformStreamController;if(s._finishPromise!==void 0)return s._finishPromise;let f=i._readable;s._finishPromise=m((g,b)=>{s._finishPromise_resolve=g,s._finishPromise_reject=b});let p=s._flushAlgorithm();return ia(s),y(p,()=>(f._state==="errored"?Hr(s,f._storedError):(ur(f._readableStreamController),Jo(s)),null),g=>(je(f._readableStreamController,g),Hr(s,g),null)),s._finishPromise}a(Bb,"TransformStreamDefaultSinkCloseAlgorithm");function Lb(i){return ra(i,!1),i._backpressureChangePromise}a(Lb,"TransformStreamDefaultSourcePullAlgorithm");function zb(i,s){let f=i._transformStreamController;if(f._finishPromise!==void 0)return f._finishPromise;let p=i._writable;f._finishPromise=m((b,_)=>{f._finishPromise_resolve=b,f._finishPromise_reject=_});let g=f._cancelAlgorithm(s);return ia(f),y(g,()=>(p._state==="errored"?Hr(f,p._storedError):(Bn(p._writableStreamController,s),Xo(i),Jo(f)),null),b=>(Bn(p._writableStreamController,b),Xo(i),Hr(f,b),null)),f._finishPromise}a(zb,"TransformStreamDefaultSourceCancelAlgorithm");function aa(i){return new TypeError(`TransformStreamDefaultController.prototype.${i} can only be used on a TransformStreamDefaultController`)}a(aa,"defaultControllerBrandCheckException");function Jo(i){i._finishPromise_resolve!==void 0&&(i._finishPromise_resolve(),i._finishPromise_resolve=void 0,i._finishPromise_reject=void 0)}a(Jo,"defaultControllerFinishPromiseResolve");function Hr(i,s){i._finishPromise_reject!==void 0&&(k(i._finishPromise),i._finishPromise_reject(s),i._finishPromise_resolve=void 0,i._finishPromise_reject=void 0)}a(Hr,"defaultControllerFinishPromiseReject");function zf(i){return new TypeError(`TransformStream.prototype.${i} can only be used on a TransformStream`)}a(zf,"streamBrandCheckException"),e.ByteLengthQueuingStrategy=Wr,e.CountQueuingStrategy=Nr,e.ReadableByteStreamController=Me,e.ReadableStream=oe,e.ReadableStreamBYOBReader=rt,e.ReadableStreamBYOBRequest=yt,e.ReadableStreamDefaultController=Ne,e.ReadableStreamDefaultReader=tt,e.TransformStream=jr,e.TransformStreamDefaultController=at,e.WritableStream=nt,e.WritableStreamDefaultController=Ut,e.WritableStreamDefaultWriter=We})});var Zf=P(()=>{if(!globalThis.ReadableStream)try{let e=require("process"),{emitWarning:t}=e;try{e.emitWarning=()=>{},Object.assign(globalThis,require("stream/web")),e.emitWarning=t}catch(r){throw e.emitWarning=t,r}}catch{Object.assign(globalThis,$f())}try{let{Blob:e}=require("buffer");e&&!e.prototype.stream&&(e.prototype.stream=a(function(r){let n=0,o=this;return new ReadableStream({type:"bytes",async pull(l){let d=await o.slice(n,Math.min(o.size,n+65536)).arrayBuffer();n+=d.byteLength,l.enqueue(new Uint8Array(d)),n===o.size&&l.close()}})},"name"))}catch{}});async function*ms(e,t=!0){for(let r of e)if("stream"in r)yield*r.stream();else if(ArrayBuffer.isView(r))if(t){let n=r.byteOffset,o=r.byteOffset+r.byteLength;for(;n!==o;){let l=Math.min(o-n,Vf),u=r.buffer.slice(n,n+l);n+=u.byteLength,yield new Uint8Array(u)}}else yield r;else{let n=0,o=r;for(;n!==o.size;){let u=await o.slice(n,Math.min(o.size,n+Vf)).arrayBuffer();n+=u.byteLength,yield new Uint8Array(u)}}}var rS,Vf,wt,Nn,Yr,la,jt,Gf,$b,St,jn=Wn(()=>{rS=Fe(Zf(),1);Vf=65536;a(ms,"toIterator");Gf=(jt=class{constructor(t=[],r={}){Ze(this,wt,[]);Ze(this,Nn,"");Ze(this,Yr,0);Ze(this,la,"transparent");if(typeof t!="object"||t===null)throw new TypeError("Failed to construct 'Blob': The provided value cannot be converted to a sequence.");if(typeof t[Symbol.iterator]!="function")throw new TypeError("Failed to construct 'Blob': The object must have a callable @@iterator property.");if(typeof r!="object"&&typeof r!="function")throw new TypeError("Failed to construct 'Blob': parameter 2 cannot convert to dictionary.");r===null&&(r={});let n=new TextEncoder;for(let l of t){let u;ArrayBuffer.isView(l)?u=new Uint8Array(l.buffer.slice(l.byteOffset,l.byteOffset+l.byteLength)):l instanceof ArrayBuffer?u=new Uint8Array(l.slice(0)):l instanceof jt?u=l:u=n.encode(`${l}`),Se(this,Yr,te(this,Yr)+(ArrayBuffer.isView(u)?u.byteLength:u.size)),te(this,wt).push(u)}Se(this,la,`${r.endings===void 0?"transparent":r.endings}`);let o=r.type===void 0?"":String(r.type);Se(this,Nn,/^[\x20-\x7E]*$/.test(o)?o:"")}get size(){return te(this,Yr)}get type(){return te(this,Nn)}async text(){let t=new TextDecoder,r="";for await(let n of ms(te(this,wt),!1))r+=t.decode(n,{stream:!0});return r+=t.decode(),r}async arrayBuffer(){let t=new Uint8Array(this.size),r=0;for await(let n of ms(te(this,wt),!1))t.set(n,r),r+=n.length;return t.buffer}stream(){let t=ms(te(this,wt),!0);return new globalThis.ReadableStream({type:"bytes",async pull(r){let n=await t.next();n.done?r.close():r.enqueue(n.value)},async cancel(){await t.return()}})}slice(t=0,r=this.size,n=""){let{size:o}=this,l=t<0?Math.max(o+t,0):Math.min(t,o),u=r<0?Math.max(o+r,0):Math.min(r,o),d=Math.max(u-l,0),m=te(this,wt),c=[],h=0;for(let y of m){if(h>=d)break;let w=ArrayBuffer.isView(y)?y.byteLength:y.size;if(l&&w<=l)l-=w,u-=w;else{let v;ArrayBuffer.isView(y)?(v=y.subarray(l,Math.min(w,u)),h+=v.byteLength):(v=y.slice(l,Math.min(w,u)),h+=v.size),u-=w,c.push(v),l=0}}let x=new jt([],{type:String(n).toLowerCase()});return Se(x,Yr,d),Se(x,wt,c),x}get[Symbol.toStringTag](){return"Blob"}static[Symbol.hasInstance](t){return t&&typeof t=="object"&&typeof t.constructor=="function"&&(typeof t.stream=="function"||typeof t.arrayBuffer=="function")&&/^(Blob|File)$/.test(t[Symbol.toStringTag])}},wt=new WeakMap,Nn=new WeakMap,Yr=new WeakMap,la=new WeakMap,a(jt,"Blob"),jt);Object.defineProperties(Gf.prototype,{size:{enumerable:!0},type:{enumerable:!0},slice:{enumerable:!0}});$b=Gf,St=$b});var Hn,$n,Kr,Zb,Vb,Xr,gs=Wn(()=>{jn();Zb=(Kr=class extends St{constructor(r,n,o={}){if(arguments.length<2)throw new TypeError(`Failed to construct 'File': 2 arguments required, but only ${arguments.length} present.`);super(r,o);Ze(this,Hn,0);Ze(this,$n,"");o===null&&(o={});let l=o.lastModified===void 0?Date.now():Number(o.lastModified);Number.isNaN(l)||Se(this,Hn,l),Se(this,$n,String(n))}get name(){return te(this,$n)}get lastModified(){return te(this,Hn)}get[Symbol.toStringTag](){return"File"}static[Symbol.hasInstance](r){return!!r&&r instanceof St&&/^(File)$/.test(r[Symbol.toStringTag])}},Hn=new WeakMap,$n=new WeakMap,a(Kr,"File"),Kr),Vb=Zb,Xr=Vb});function Xf(e,t=St){var r=`${Yf()}${Yf()}`.replace(/\./g,"").slice(-28).padStart(32,"-"),n=[],o=`--${r}\r
|
|
2
2
|
Content-Disposition: form-data; name="`;return e.forEach((l,u)=>typeof l=="string"?n.push(o+bs(u)+`"\r
|
|
3
3
|
\r
|
|
4
4
|
${l.replace(/\r(?!\n)|(?<!\r)\n/g,`\r
|
|
@@ -8,12 +8,12 @@ Content-Type: ${l.type||"application/octet-stream"}\r
|
|
|
8
8
|
\r
|
|
9
9
|
`,l,`\r
|
|
10
10
|
`)),n.push(`--${r}--`),new t(n,{type:"multipart/form-data; boundary="+r})}var Zn,Gb,Yb,Yf,Kb,Kf,bs,cr,Oe,Jr,dr,ua=Wn(()=>{jn();gs();({toStringTag:Zn,iterator:Gb,hasInstance:Yb}=Symbol),Yf=Math.random,Kb="append,set,get,getAll,delete,keys,values,entries,forEach,constructor".split(","),Kf=a((e,t,r)=>(e+="",/^(Blob|File)$/.test(t&&t[Zn])?[(r=r!==void 0?r+"":t[Zn]=="File"?t.name:"blob",e),t.name!==r||t[Zn]=="blob"?new Xr([t],r,t):t]:[e,t+""]),"f"),bs=a((e,t)=>(t?e:e.replace(/\r?\n|\r/g,`\r
|
|
11
|
-
`)).replace(/\n/g,"%0A").replace(/\r/g,"%0D").replace(/"/g,"%22"),"e"),cr=a((e,t,r)=>{if(t.length<r)throw new TypeError(`Failed to execute '${e}' on 'FormData': ${r} arguments required, but only ${t.length} present.`)},"x"),dr=(Jr=class{constructor(...t){Ze(this,Oe,[]);if(t.length)throw new TypeError("Failed to construct 'FormData': parameter 1 is not of type 'HTMLFormElement'.")}get[Zn](){return"FormData"}[Gb](){return this.entries()}static[Yb](t){return t&&typeof t=="object"&&t[Zn]==="FormData"&&!Kb.some(r=>typeof t[r]!="function")}append(...t){cr("append",arguments,2),te(this,Oe).push(Kf(...t))}delete(t){cr("delete",arguments,1),t+="",Se(this,Oe,te(this,Oe).filter(([r])=>r!==t))}get(t){cr("get",arguments,1),t+="";for(var r=te(this,Oe),n=r.length,o=0;o<n;o++)if(r[o][0]===t)return r[o][1];return null}getAll(t,r){return cr("getAll",arguments,1),r=[],t+="",te(this,Oe).forEach(n=>n[0]===t&&r.push(n[1])),r}has(t){return cr("has",arguments,1),t+="",te(this,Oe).some(r=>r[0]===t)}forEach(t,r){cr("forEach",arguments,1);for(var[n,o]of this)t.call(r,o,n,this)}set(...t){cr("set",arguments,2);var r=[],n=!0;t=Kf(...t),te(this,Oe).forEach(o=>{o[0]===t[0]?n&&(n=!r.push(t)):r.push(o)}),n&&r.push(t),Se(this,Oe,r)}*entries(){yield*te(this,Oe)}*keys(){for(var[t]of this)yield t}*values(){for(var[,t]of this)yield t}},Oe=new WeakMap,a(Jr,"FormData"),Jr);a(Xf,"formDataToBlob")});var rc=P((_S,tc)=>{if(!globalThis.DOMException)try{let{MessageChannel:e}=require("worker_threads"),t=new e().port1,r=new ArrayBuffer;t.postMessage(r,[r,r])}catch(e){e.constructor.name==="DOMException"&&(globalThis.DOMException=e.constructor)}tc.exports=globalThis.DOMException});var ca,Xb,SS,ws=Wn(()=>{ca=require("fs"),Xb=Fe(rc(),1);gs();jn();({stat:SS}=ca.promises)});var ic={};Mf(ic,{toFormData:()=>iy});function ny(e){let t=e.match(/\bfilename=("(.*?)"|([^()<>@,;:\\"/[\]?={}\s\t]+))($|;\s)/i);if(!t)return;let r=t[2]||t[3]||"",n=r.slice(r.lastIndexOf("\\")+1);return n=n.replace(/%22/g,'"'),n=n.replace(/&#(\d{4});/g,(o,l)=>String.fromCharCode(l)),n}async function iy(e,t){if(!/multipart/i.test(t))throw new TypeError("Failed to fetch");let r=t.match(/boundary=(?:"([^"]+)"|([^;]+))/i);if(!r)throw new TypeError("no or bad content-type header, no multipart boundary");let n=new Ss(r[1]||r[2]),o,l,u,d,m,c,h=[],x=new dr,y=a(S=>{u+=k.decode(S,{stream:!0})},"onPartData"),w=a(S=>{h.push(S)},"appendToFile"),v=a(()=>{let S=new Xr(h,c,{type:m});x.append(d,S)},"appendFileToFormData"),E=a(()=>{x.append(d,u)},"appendEntryToFormData"),k=new TextDecoder("utf-8");k.decode(),n.onPartBegin=function(){n.onPartData=y,n.onPartEnd=E,o="",l="",u="",d="",m="",c=null,h.length=0},n.onHeaderField=function(S){o+=k.decode(S,{stream:!0})},n.onHeaderValue=function(S){l+=k.decode(S,{stream:!0})},n.onHeaderEnd=function(){if(l+=k.decode(),o=o.toLowerCase(),o==="content-disposition"){let S=l.match(/\bname=("([^"]*)"|([^()<>@,;:\\"/[\]?={}\s\t]+))/i);S&&(d=S[2]||S[3]||""),c=ny(l),c&&(n.onPartData=w,n.onPartEnd=v)}else o==="content-type"&&(m=l);l="",o=""};for await(let S of e)n.write(S);return n.end(),x}var ot,K,nc,Ht,da,ha,Jb,Gn,Qb,ey,ty,ry,hr,
|
|
12
|
-
--`+t;let r=new Uint8Array(t.length);for(let n=0;n<t.length;n++)r[n]=t.charCodeAt(n),this.boundaryChars[r[n]]=!0;this.boundary=r,this.lookbehind=new Uint8Array(this.boundary.length+8),this.state=K.START_BOUNDARY}write(t){let r=0,n=t.length,o=this.index,{lookbehind:l,boundary:u,boundaryChars:d,index:m,state:c,flags:h}=this,x=this.boundary.length,y=x-1,w=t.length,v,E,k=a(R=>{this[R+"Mark"]=r},"mark"),S=a(R=>{delete this[R+"Mark"]},"clear"),A=a((R,T,F,z)=>{(T===void 0||T!==F)&&this[R](z&&z.subarray(T,F))},"callback"),C=a((R,T)=>{let F=R+"Mark";F in this&&(T?(A(R,this[F],r,t),delete this[F]):(A(R,this[F],t.length,t),this[F]=0))},"dataCallback");for(r=0;r<n;r++)switch(v=t[r],c){case K.START_BOUNDARY:if(m===u.length-2){if(v===Gn)h|=Ht.LAST_BOUNDARY;else if(v!==ha)return;m++;break}else if(m-1===u.length-2){if(h&Ht.LAST_BOUNDARY&&v===Gn)c=K.END,h=0;else if(!(h&Ht.LAST_BOUNDARY)&&v===da)m=0,A("onPartBegin"),c=K.HEADER_FIELD_START;else return;break}v!==u[m+2]&&(m=-2),v===u[m+2]&&m++;break;case K.HEADER_FIELD_START:c=K.HEADER_FIELD,k("onHeaderField"),m=0;case K.HEADER_FIELD:if(v===ha){S("onHeaderField"),c=K.HEADERS_ALMOST_DONE;break}if(m++,v===Gn)break;if(v===Qb){if(m===1)return;C("onHeaderField",!0),c=K.HEADER_VALUE_START;break}if(E=ry(v),E<ey||E>ty)return;break;case K.HEADER_VALUE_START:if(v===Jb)break;k("onHeaderValue"),c=K.HEADER_VALUE;case K.HEADER_VALUE:v===ha&&(C("onHeaderValue",!0),A("onHeaderEnd"),c=K.HEADER_VALUE_ALMOST_DONE);break;case K.HEADER_VALUE_ALMOST_DONE:if(v!==da)return;c=K.HEADER_FIELD_START;break;case K.HEADERS_ALMOST_DONE:if(v!==da)return;A("onHeadersEnd"),c=K.PART_DATA_START;break;case K.PART_DATA_START:c=K.PART_DATA,k("onPartData");case K.PART_DATA:if(o=m,m===0){for(r+=y;r<w&&!(t[r]in d);)r+=x;r-=y,v=t[r]}if(m<u.length)u[m]===v?(m===0&&C("onPartData",!0),m++):m=0;else if(m===u.length)m++,v===ha?h|=Ht.PART_BOUNDARY:v===Gn?h|=Ht.LAST_BOUNDARY:m=0;else if(m-1===u.length)if(h&Ht.PART_BOUNDARY){if(m=0,v===da){h&=~Ht.PART_BOUNDARY,A("onPartEnd"),A("onPartBegin"),c=K.HEADER_FIELD_START;break}}else h&Ht.LAST_BOUNDARY&&v===Gn?(A("onPartEnd"),c=K.END,h=0):m=0;if(m>0)l[m-1]=v;else if(o>0){let R=new Uint8Array(l.buffer,l.byteOffset,l.byteLength);A("onPartData",0,o,R),o=0,k("onPartData"),r--}break;case K.END:break;default:throw new Error(`Unexpected state entered: ${c}`)}C("onHeaderField"),C("onHeaderValue"),C("onPartData"),this.index=m,this.state=c,this.flags=h}end(){if(this.state===K.HEADER_FIELD_START&&this.index===0||this.state===K.PART_DATA&&this.index===this.boundary.length)this.onPartEnd();else if(this.state!==K.END)throw new Error("MultipartParser.end(): stream ended unexpectedly")}};a(Rs,"MultipartParser");Ss=Rs;a(ny,"_fileName");a(iy,"toFormData")});var Jn=P((SR,Cs)=>{"use strict";typeof process>"u"||!process.version||process.version.indexOf("v0.")===0||process.version.indexOf("v1.")===0&&process.version.indexOf("v1.8.")!==0?Cs.exports={nextTick:dy}:Cs.exports=process;function dy(e,t,r,n){if(typeof e!="function")throw new TypeError('"callback" argument must be a function');var o=arguments.length,l,u;switch(o){case 0:case 1:return process.nextTick(e);case 2:return process.nextTick(a(function(){e.call(null,t)},"afterTickOne"));case 3:return process.nextTick(a(function(){e.call(null,t,r)},"afterTickTwo"));case 4:return process.nextTick(a(function(){e.call(null,t,r,n)},"afterTickThree"));default:for(l=new Array(o-1),u=0;u<l.length;)l[u++]=arguments[u];return process.nextTick(a(function(){e.apply(null,l)},"afterTick"))}}a(dy,"nextTick")});var Rc=P((TR,Sc)=>{var hy={}.toString;Sc.exports=Array.isArray||function(e){return hy.call(e)=="[object Array]"}});var Ps=P((xR,Tc)=>{Tc.exports=require("stream")});var Qn=P((Is,Ac)=>{var wa=require("buffer"),xt=wa.Buffer;function xc(e,t){for(var r in e)t[r]=e[r]}a(xc,"copyProps");xt.from&&xt.alloc&&xt.allocUnsafe&&xt.allocUnsafeSlow?Ac.exports=wa:(xc(wa,Is),Is.Buffer=tn);function tn(e,t,r){return xt(e,t,r)}a(tn,"SafeBuffer");xc(xt,tn);tn.from=function(e,t,r){if(typeof e=="number")throw new TypeError("Argument must not be a number");return xt(e,t,r)};tn.alloc=function(e,t,r){if(typeof e!="number")throw new TypeError("Argument must be a number");var n=xt(e);return t!==void 0?typeof r=="string"?n.fill(t,r):n.fill(t):n.fill(0),n};tn.allocUnsafe=function(e){if(typeof e!="number")throw new TypeError("Argument must be a number");return xt(e)};tn.allocUnsafeSlow=function(e){if(typeof e!="number")throw new TypeError("Argument must be a number");return wa.SlowBuffer(e)}});var rn=P(de=>{function py(e){return Array.isArray?Array.isArray(e):Sa(e)==="[object Array]"}a(py,"isArray");de.isArray=py;function my(e){return typeof e=="boolean"}a(my,"isBoolean");de.isBoolean=my;function gy(e){return e===null}a(gy,"isNull");de.isNull=gy;function by(e){return e==null}a(by,"isNullOrUndefined");de.isNullOrUndefined=by;function yy(e){return typeof e=="number"}a(yy,"isNumber");de.isNumber=yy;function _y(e){return typeof e=="string"}a(_y,"isString");de.isString=_y;function vy(e){return typeof e=="symbol"}a(vy,"isSymbol");de.isSymbol=vy;function wy(e){return e===void 0}a(wy,"isUndefined");de.isUndefined=wy;function Sy(e){return Sa(e)==="[object RegExp]"}a(Sy,"isRegExp");de.isRegExp=Sy;function Ry(e){return typeof e=="object"&&e!==null}a(Ry,"isObject");de.isObject=Ry;function Ty(e){return Sa(e)==="[object Date]"}a(Ty,"isDate");de.isDate=Ty;function xy(e){return Sa(e)==="[object Error]"||e instanceof Error}a(xy,"isError");de.isError=xy;function Ay(e){return typeof e=="function"}a(Ay,"isFunction");de.isFunction=Ay;function ky(e){return e===null||typeof e=="boolean"||typeof e=="number"||typeof e=="string"||typeof e=="symbol"||typeof e>"u"}a(ky,"isPrimitive");de.isPrimitive=ky;de.isBuffer=require("buffer").Buffer.isBuffer;function Sa(e){return Object.prototype.toString.call(e)}a(Sa,"objectToString")});var kc=P((CR,Fs)=>{typeof Object.create=="function"?Fs.exports=a(function(t,r){r&&(t.super_=r,t.prototype=Object.create(r.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}))},"inherits"):Fs.exports=a(function(t,r){if(r){t.super_=r;var n=a(function(){},"TempCtor");n.prototype=r.prototype,t.prototype=new n,t.prototype.constructor=t}},"inherits")});var nn=P((IR,Ds)=>{try{if(Os=require("util"),typeof Os.inherits!="function")throw"";Ds.exports=Os.inherits}catch{Ds.exports=kc()}var Os});var Cc=P((FR,Bs)=>{"use strict";function Ey(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}a(Ey,"_classCallCheck");var Ec=Qn().Buffer,ei=require("util");function Cy(e,t,r){e.copy(t,r)}a(Cy,"copyBuffer");Bs.exports=function(){function e(){Ey(this,e),this.head=null,this.tail=null,this.length=0}return a(e,"BufferList"),e.prototype.push=a(function(r){var n={data:r,next:null};this.length>0?this.tail.next=n:this.head=n,this.tail=n,++this.length},"push"),e.prototype.unshift=a(function(r){var n={data:r,next:this.head};this.length===0&&(this.tail=n),this.head=n,++this.length},"unshift"),e.prototype.shift=a(function(){if(this.length!==0){var r=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,r}},"shift"),e.prototype.clear=a(function(){this.head=this.tail=null,this.length=0},"clear"),e.prototype.join=a(function(r){if(this.length===0)return"";for(var n=this.head,o=""+n.data;n=n.next;)o+=r+n.data;return o},"join"),e.prototype.concat=a(function(r){if(this.length===0)return Ec.alloc(0);for(var n=Ec.allocUnsafe(r>>>0),o=this.head,l=0;o;)Cy(o.data,n,l),l+=o.data.length,o=o.next;return n},"concat"),e}();ei&&ei.inspect&&ei.inspect.custom&&(Bs.exports.prototype[ei.inspect.custom]=function(){var e=ei.inspect({length:this.length});return this.constructor.name+" "+e})});var Ls=P((DR,Pc)=>{"use strict";var Ra=Jn();function Py(e,t){var r=this,n=this._readableState&&this._readableState.destroyed,o=this._writableState&&this._writableState.destroyed;return n||o?(t?t(e):e&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,Ra.nextTick(Ta,this,e)):Ra.nextTick(Ta,this,e)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,function(l){!t&&l?r._writableState?r._writableState.errorEmitted||(r._writableState.errorEmitted=!0,Ra.nextTick(Ta,r,l)):Ra.nextTick(Ta,r,l):t&&t(l)}),this)}a(Py,"destroy");function Iy(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}a(Iy,"undestroy");function Ta(e,t){e.emit("error",t)}a(Ta,"emitErrorNT");Pc.exports={destroy:Py,undestroy:Iy}});var Fc=P((LR,Ic)=>{Ic.exports=require("util").deprecate});var qs=P((zR,Mc)=>{"use strict";var br=Jn();Mc.exports=ne;function Dc(e){var t=this;this.next=null,this.entry=null,this.finish=function(){Yy(t,e)}}a(Dc,"CorkedRequest");var Fy=!process.browser&&["v0.10","v0.9."].indexOf(process.version.slice(0,5))>-1?setImmediate:br.nextTick,an;ne.WritableState=ri;var Bc=Object.create(rn());Bc.inherits=nn();var Oy={deprecate:Fc()},Lc=Ps(),Aa=Qn().Buffer,Dy=(typeof global<"u"?global:typeof window<"u"?window:typeof self<"u"?self:{}).Uint8Array||function(){};function By(e){return Aa.from(e)}a(By,"_uint8ArrayToBuffer");function Ly(e){return Aa.isBuffer(e)||e instanceof Dy}a(Ly,"_isUint8Array");var zc=Ls();Bc.inherits(ne,Lc);function zy(){}a(zy,"nop");function ri(e,t){an=an||yr(),e=e||{};var r=t instanceof an;this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.writableObjectMode);var n=e.highWaterMark,o=e.writableHighWaterMark,l=this.objectMode?16:16*1024;n||n===0?this.highWaterMark=n:r&&(o||o===0)?this.highWaterMark=o:this.highWaterMark=l,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var u=e.decodeStrings===!1;this.decodeStrings=!u,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(d){Hy(t,d)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new Dc(this)}a(ri,"WritableState");ri.prototype.getBuffer=a(function(){for(var t=this.bufferedRequest,r=[];t;)r.push(t),t=t.next;return r},"getBuffer");(function(){try{Object.defineProperty(ri.prototype,"buffer",{get:Oy.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch{}})();var xa;typeof Symbol=="function"&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]=="function"?(xa=Function.prototype[Symbol.hasInstance],Object.defineProperty(ne,Symbol.hasInstance,{value:a(function(e){return xa.call(this,e)?!0:this!==ne?!1:e&&e._writableState instanceof ri},"value")})):xa=a(function(e){return e instanceof this},"realHasInstance");function ne(e){if(an=an||yr(),!xa.call(ne,this)&&!(this instanceof an))return new ne(e);this._writableState=new ri(e,this),this.writable=!0,e&&(typeof e.write=="function"&&(this._write=e.write),typeof e.writev=="function"&&(this._writev=e.writev),typeof e.destroy=="function"&&(this._destroy=e.destroy),typeof e.final=="function"&&(this._final=e.final)),Lc.call(this)}a(ne,"Writable");ne.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))};function qy(e,t){var r=new Error("write after end");e.emit("error",r),br.nextTick(t,r)}a(qy,"writeAfterEnd");function Uy(e,t,r,n){var o=!0,l=!1;return r===null?l=new TypeError("May not write null values to stream"):typeof r!="string"&&r!==void 0&&!t.objectMode&&(l=new TypeError("Invalid non-string/buffer chunk")),l&&(e.emit("error",l),br.nextTick(n,l),o=!1),o}a(Uy,"validChunk");ne.prototype.write=function(e,t,r){var n=this._writableState,o=!1,l=!n.objectMode&&Ly(e);return l&&!Aa.isBuffer(e)&&(e=By(e)),typeof t=="function"&&(r=t,t=null),l?t="buffer":t||(t=n.defaultEncoding),typeof r!="function"&&(r=zy),n.ended?qy(this,r):(l||Uy(this,n,e,r))&&(n.pendingcb++,o=Wy(this,n,l,e,t,r)),o};ne.prototype.cork=function(){var e=this._writableState;e.corked++};ne.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,!e.writing&&!e.corked&&!e.bufferProcessing&&e.bufferedRequest&&qc(this,e))};ne.prototype.setDefaultEncoding=a(function(t){if(typeof t=="string"&&(t=t.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((t+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+t);return this._writableState.defaultEncoding=t,this},"setDefaultEncoding");function My(e,t,r){return!e.objectMode&&e.decodeStrings!==!1&&typeof t=="string"&&(t=Aa.from(t,r)),t}a(My,"decodeChunk");Object.defineProperty(ne.prototype,"writableHighWaterMark",{enumerable:!1,get:a(function(){return this._writableState.highWaterMark},"get")});function Wy(e,t,r,n,o,l){if(!r){var u=My(t,n,o);n!==u&&(r=!0,o="buffer",n=u)}var d=t.objectMode?1:n.length;t.length+=d;var m=t.length<t.highWaterMark;if(m||(t.needDrain=!0),t.writing||t.corked){var c=t.lastBufferedRequest;t.lastBufferedRequest={chunk:n,encoding:o,isBuf:r,callback:l,next:null},c?c.next=t.lastBufferedRequest:t.bufferedRequest=t.lastBufferedRequest,t.bufferedRequestCount+=1}else zs(e,t,!1,d,n,o,l);return m}a(Wy,"writeOrBuffer");function zs(e,t,r,n,o,l,u){t.writelen=n,t.writecb=u,t.writing=!0,t.sync=!0,r?e._writev(o,t.onwrite):e._write(o,l,t.onwrite),t.sync=!1}a(zs,"doWrite");function Ny(e,t,r,n,o){--t.pendingcb,r?(br.nextTick(o,n),br.nextTick(ti,e,t),e._writableState.errorEmitted=!0,e.emit("error",n)):(o(n),e._writableState.errorEmitted=!0,e.emit("error",n),ti(e,t))}a(Ny,"onwriteError");function jy(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}a(jy,"onwriteStateUpdate");function Hy(e,t){var r=e._writableState,n=r.sync,o=r.writecb;if(jy(r),t)Ny(e,r,n,t,o);else{var l=Uc(r);!l&&!r.corked&&!r.bufferProcessing&&r.bufferedRequest&&qc(e,r),n?Fy(Oc,e,r,l,o):Oc(e,r,l,o)}}a(Hy,"onwrite");function Oc(e,t,r,n){r||$y(e,t),t.pendingcb--,n(),ti(e,t)}a(Oc,"afterWrite");function $y(e,t){t.length===0&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}a($y,"onwriteDrain");function qc(e,t){t.bufferProcessing=!0;var r=t.bufferedRequest;if(e._writev&&r&&r.next){var n=t.bufferedRequestCount,o=new Array(n),l=t.corkedRequestsFree;l.entry=r;for(var u=0,d=!0;r;)o[u]=r,r.isBuf||(d=!1),r=r.next,u+=1;o.allBuffers=d,zs(e,t,!0,t.length,o,"",l.finish),t.pendingcb++,t.lastBufferedRequest=null,l.next?(t.corkedRequestsFree=l.next,l.next=null):t.corkedRequestsFree=new Dc(t),t.bufferedRequestCount=0}else{for(;r;){var m=r.chunk,c=r.encoding,h=r.callback,x=t.objectMode?1:m.length;if(zs(e,t,!1,x,m,c,h),r=r.next,t.bufferedRequestCount--,t.writing)break}r===null&&(t.lastBufferedRequest=null)}t.bufferedRequest=r,t.bufferProcessing=!1}a(qc,"clearBuffer");ne.prototype._write=function(e,t,r){r(new Error("_write() is not implemented"))};ne.prototype._writev=null;ne.prototype.end=function(e,t,r){var n=this._writableState;typeof e=="function"?(r=e,e=null,t=null):typeof t=="function"&&(r=t,t=null),e!=null&&this.write(e,t),n.corked&&(n.corked=1,this.uncork()),n.ending||Gy(this,n,r)};function Uc(e){return e.ending&&e.length===0&&e.bufferedRequest===null&&!e.finished&&!e.writing}a(Uc,"needFinish");function Zy(e,t){e._final(function(r){t.pendingcb--,r&&e.emit("error",r),t.prefinished=!0,e.emit("prefinish"),ti(e,t)})}a(Zy,"callFinal");function Vy(e,t){!t.prefinished&&!t.finalCalled&&(typeof e._final=="function"?(t.pendingcb++,t.finalCalled=!0,br.nextTick(Zy,e,t)):(t.prefinished=!0,e.emit("prefinish")))}a(Vy,"prefinish");function ti(e,t){var r=Uc(t);return r&&(Vy(e,t),t.pendingcb===0&&(t.finished=!0,e.emit("finish"))),r}a(ti,"finishMaybe");function Gy(e,t,r){t.ending=!0,ti(e,t),r&&(t.finished?br.nextTick(r):e.once("finish",r)),t.ended=!0,e.writable=!1}a(Gy,"endWritable");function Yy(e,t,r){var n=e.entry;for(e.entry=null;n;){var o=n.callback;t.pendingcb--,o(r),n=n.next}t.corkedRequestsFree.next=e}a(Yy,"onCorkedFinish");Object.defineProperty(ne.prototype,"destroyed",{get:a(function(){return this._writableState===void 0?!1:this._writableState.destroyed},"get"),set:a(function(e){this._writableState&&(this._writableState.destroyed=e)},"set")});ne.prototype.destroy=zc.destroy;ne.prototype._undestroy=zc.undestroy;ne.prototype._destroy=function(e,t){this.end(),t(e)}});var yr=P((UR,Hc)=>{"use strict";var Wc=Jn(),Ky=Object.keys||function(e){var t=[];for(var r in e)t.push(r);return t};Hc.exports=At;var Nc=Object.create(rn());Nc.inherits=nn();var jc=Ws(),Ms=qs();Nc.inherits(At,jc);for(Us=Ky(Ms.prototype),ka=0;ka<Us.length;ka++)Ea=Us[ka],At.prototype[Ea]||(At.prototype[Ea]=Ms.prototype[Ea]);var Us,Ea,ka;function At(e){if(!(this instanceof At))return new At(e);jc.call(this,e),Ms.call(this,e),e&&e.readable===!1&&(this.readable=!1),e&&e.writable===!1&&(this.writable=!1),this.allowHalfOpen=!0,e&&e.allowHalfOpen===!1&&(this.allowHalfOpen=!1),this.once("end",Xy)}a(At,"Duplex");Object.defineProperty(At.prototype,"writableHighWaterMark",{enumerable:!1,get:a(function(){return this._writableState.highWaterMark},"get")});function Xy(){this.allowHalfOpen||this._writableState.ended||Wc.nextTick(Jy,this)}a(Xy,"onend");function Jy(e){e.end()}a(Jy,"onEndNT");Object.defineProperty(At.prototype,"destroyed",{get:a(function(){return this._readableState===void 0||this._writableState===void 0?!1:this._readableState.destroyed&&this._writableState.destroyed},"get"),set:a(function(e){this._readableState===void 0||this._writableState===void 0||(this._readableState.destroyed=e,this._writableState.destroyed=e)},"set")});At.prototype._destroy=function(e,t){this.push(null),this.end(),Wc.nextTick(t,e)}});var Hs=P(Zc=>{"use strict";var js=Qn().Buffer,$c=js.isEncoding||function(e){switch(e=""+e,e&&e.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function Qy(e){if(!e)return"utf8";for(var t;;)switch(e){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return e;default:if(t)return;e=(""+e).toLowerCase(),t=!0}}a(Qy,"_normalizeEncoding");function e_(e){var t=Qy(e);if(typeof t!="string"&&(js.isEncoding===$c||!$c(e)))throw new Error("Unknown encoding: "+e);return t||e}a(e_,"normalizeEncoding");Zc.StringDecoder=ni;function ni(e){this.encoding=e_(e);var t;switch(this.encoding){case"utf16le":this.text=o_,this.end=s_,t=4;break;case"utf8":this.fillLast=n_,t=4;break;case"base64":this.text=l_,this.end=u_,t=3;break;default:this.write=f_,this.end=c_;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=js.allocUnsafe(t)}a(ni,"StringDecoder");ni.prototype.write=function(e){if(e.length===0)return"";var t,r;if(this.lastNeed){if(t=this.fillLast(e),t===void 0)return"";r=this.lastNeed,this.lastNeed=0}else r=0;return r<e.length?t?t+this.text(e,r):this.text(e,r):t||""};ni.prototype.end=a_;ni.prototype.text=i_;ni.prototype.fillLast=function(e){if(this.lastNeed<=e.length)return e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,e.length),this.lastNeed-=e.length};function Ns(e){return e<=127?0:e>>5===6?2:e>>4===14?3:e>>3===30?4:e>>6===2?-1:-2}a(Ns,"utf8CheckByte");function t_(e,t,r){var n=t.length-1;if(n<r)return 0;var o=Ns(t[n]);return o>=0?(o>0&&(e.lastNeed=o-1),o):--n<r||o===-2?0:(o=Ns(t[n]),o>=0?(o>0&&(e.lastNeed=o-2),o):--n<r||o===-2?0:(o=Ns(t[n]),o>=0?(o>0&&(o===2?o=0:e.lastNeed=o-3),o):0))}a(t_,"utf8CheckIncomplete");function r_(e,t,r){if((t[0]&192)!==128)return e.lastNeed=0,"\uFFFD";if(e.lastNeed>1&&t.length>1){if((t[1]&192)!==128)return e.lastNeed=1,"\uFFFD";if(e.lastNeed>2&&t.length>2&&(t[2]&192)!==128)return e.lastNeed=2,"\uFFFD"}}a(r_,"utf8CheckExtraBytes");function n_(e){var t=this.lastTotal-this.lastNeed,r=r_(this,e,t);if(r!==void 0)return r;if(this.lastNeed<=e.length)return e.copy(this.lastChar,t,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);e.copy(this.lastChar,t,0,e.length),this.lastNeed-=e.length}a(n_,"utf8FillLast");function i_(e,t){var r=t_(this,e,t);if(!this.lastNeed)return e.toString("utf8",t);this.lastTotal=r;var n=e.length-(r-this.lastNeed);return e.copy(this.lastChar,0,n),e.toString("utf8",t,n)}a(i_,"utf8Text");function a_(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+"\uFFFD":t}a(a_,"utf8End");function o_(e,t){if((e.length-t)%2===0){var r=e.toString("utf16le",t);if(r){var n=r.charCodeAt(r.length-1);if(n>=55296&&n<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1],r.slice(0,-1)}return r}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=e[e.length-1],e.toString("utf16le",t,e.length-1)}a(o_,"utf16Text");function s_(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed){var r=this.lastTotal-this.lastNeed;return t+this.lastChar.toString("utf16le",0,r)}return t}a(s_,"utf16End");function l_(e,t){var r=(e.length-t)%3;return r===0?e.toString("base64",t):(this.lastNeed=3-r,this.lastTotal=3,r===1?this.lastChar[0]=e[e.length-1]:(this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1]),e.toString("base64",t,e.length-r))}a(l_,"base64Text");function u_(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+this.lastChar.toString("base64",0,3-this.lastNeed):t}a(u_,"base64End");function f_(e){return e.toString(this.encoding)}a(f_,"simpleWrite");function c_(e){return e&&e.length?this.write(e):""}a(c_,"simpleEnd")});var Ws=P((HR,id)=>{"use strict";var sn=Jn();id.exports=J;var d_=Rc(),ii;J.ReadableState=Qc;var jR=require("events").EventEmitter,Kc=a(function(e,t){return e.listeners(t).length},"EElistenerCount"),Ys=Ps(),ai=Qn().Buffer,h_=(typeof global<"u"?global:typeof window<"u"?window:typeof self<"u"?self:{}).Uint8Array||function(){};function p_(e){return ai.from(e)}a(p_,"_uint8ArrayToBuffer");function m_(e){return ai.isBuffer(e)||e instanceof h_}a(m_,"_isUint8Array");var Xc=Object.create(rn());Xc.inherits=nn();var $s=require("util"),$=void 0;$s&&$s.debuglog?$=$s.debuglog("stream"):$=a(function(){},"debug");var g_=Cc(),Jc=Ls(),on;Xc.inherits(J,Ys);var Zs=["error","close","destroy","pause","resume"];function b_(e,t,r){if(typeof e.prependListener=="function")return e.prependListener(t,r);!e._events||!e._events[t]?e.on(t,r):d_(e._events[t])?e._events[t].unshift(r):e._events[t]=[r,e._events[t]]}a(b_,"prependListener");function Qc(e,t){ii=ii||yr(),e=e||{};var r=t instanceof ii;this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.readableObjectMode);var n=e.highWaterMark,o=e.readableHighWaterMark,l=this.objectMode?16:16*1024;n||n===0?this.highWaterMark=n:r&&(o||o===0)?this.highWaterMark=o:this.highWaterMark=l,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new g_,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(on||(on=Hs().StringDecoder),this.decoder=new on(e.encoding),this.encoding=e.encoding)}a(Qc,"ReadableState");function J(e){if(ii=ii||yr(),!(this instanceof J))return new J(e);this._readableState=new Qc(e,this),this.readable=!0,e&&(typeof e.read=="function"&&(this._read=e.read),typeof e.destroy=="function"&&(this._destroy=e.destroy)),Ys.call(this)}a(J,"Readable");Object.defineProperty(J.prototype,"destroyed",{get:a(function(){return this._readableState===void 0?!1:this._readableState.destroyed},"get"),set:a(function(e){this._readableState&&(this._readableState.destroyed=e)},"set")});J.prototype.destroy=Jc.destroy;J.prototype._undestroy=Jc.undestroy;J.prototype._destroy=function(e,t){this.push(null),t(e)};J.prototype.push=function(e,t){var r=this._readableState,n;return r.objectMode?n=!0:typeof e=="string"&&(t=t||r.defaultEncoding,t!==r.encoding&&(e=ai.from(e,t),t=""),n=!0),ed(this,e,t,!1,n)};J.prototype.unshift=function(e){return ed(this,e,null,!0,!1)};function ed(e,t,r,n,o){var l=e._readableState;if(t===null)l.reading=!1,w_(e,l);else{var u;o||(u=y_(l,t)),u?e.emit("error",u):l.objectMode||t&&t.length>0?(typeof t!="string"&&!l.objectMode&&Object.getPrototypeOf(t)!==ai.prototype&&(t=p_(t)),n?l.endEmitted?e.emit("error",new Error("stream.unshift() after end event")):Vs(e,l,t,!0):l.ended?e.emit("error",new Error("stream.push() after EOF")):(l.reading=!1,l.decoder&&!r?(t=l.decoder.write(t),l.objectMode||t.length!==0?Vs(e,l,t,!1):td(e,l)):Vs(e,l,t,!1))):n||(l.reading=!1)}return __(l)}a(ed,"readableAddChunk");function Vs(e,t,r,n){t.flowing&&t.length===0&&!t.sync?(e.emit("data",r),e.read(0)):(t.length+=t.objectMode?1:r.length,n?t.buffer.unshift(r):t.buffer.push(r),t.needReadable&&Ca(e)),td(e,t)}a(Vs,"addChunk");function y_(e,t){var r;return!m_(t)&&typeof t!="string"&&t!==void 0&&!e.objectMode&&(r=new TypeError("Invalid non-string/buffer chunk")),r}a(y_,"chunkInvalid");function __(e){return!e.ended&&(e.needReadable||e.length<e.highWaterMark||e.length===0)}a(__,"needMoreData");J.prototype.isPaused=function(){return this._readableState.flowing===!1};J.prototype.setEncoding=function(e){return on||(on=Hs().StringDecoder),this._readableState.decoder=new on(e),this._readableState.encoding=e,this};var Vc=8388608;function v_(e){return e>=Vc?e=Vc:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}a(v_,"computeNewHighWaterMark");function Gc(e,t){return e<=0||t.length===0&&t.ended?0:t.objectMode?1:e!==e?t.flowing&&t.length?t.buffer.head.data.length:t.length:(e>t.highWaterMark&&(t.highWaterMark=v_(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}a(Gc,"howMuchToRead");J.prototype.read=function(e){$("read",e),e=parseInt(e,10);var t=this._readableState,r=e;if(e!==0&&(t.emittedReadable=!1),e===0&&t.needReadable&&(t.length>=t.highWaterMark||t.ended))return $("read: emitReadable",t.length,t.ended),t.length===0&&t.ended?Gs(this):Ca(this),null;if(e=Gc(e,t),e===0&&t.ended)return t.length===0&&Gs(this),null;var n=t.needReadable;$("need readable",n),(t.length===0||t.length-e<t.highWaterMark)&&(n=!0,$("length less than watermark",n)),t.ended||t.reading?(n=!1,$("reading or ended",n)):n&&($("do read"),t.reading=!0,t.sync=!0,t.length===0&&(t.needReadable=!0),this._read(t.highWaterMark),t.sync=!1,t.reading||(e=Gc(r,t)));var o;return e>0?o=rd(e,t):o=null,o===null?(t.needReadable=!0,e=0):t.length-=e,t.length===0&&(t.ended||(t.needReadable=!0),r!==e&&t.ended&&Gs(this)),o!==null&&this.emit("data",o),o};function w_(e,t){if(!t.ended){if(t.decoder){var r=t.decoder.end();r&&r.length&&(t.buffer.push(r),t.length+=t.objectMode?1:r.length)}t.ended=!0,Ca(e)}}a(w_,"onEofChunk");function Ca(e){var t=e._readableState;t.needReadable=!1,t.emittedReadable||($("emitReadable",t.flowing),t.emittedReadable=!0,t.sync?sn.nextTick(Yc,e):Yc(e))}a(Ca,"emitReadable");function Yc(e){$("emit readable"),e.emit("readable"),Ks(e)}a(Yc,"emitReadable_");function td(e,t){t.readingMore||(t.readingMore=!0,sn.nextTick(S_,e,t))}a(td,"maybeReadMore");function S_(e,t){for(var r=t.length;!t.reading&&!t.flowing&&!t.ended&&t.length<t.highWaterMark&&($("maybeReadMore read 0"),e.read(0),r!==t.length);)r=t.length;t.readingMore=!1}a(S_,"maybeReadMore_");J.prototype._read=function(e){this.emit("error",new Error("_read() is not implemented"))};J.prototype.pipe=function(e,t){var r=this,n=this._readableState;switch(n.pipesCount){case 0:n.pipes=e;break;case 1:n.pipes=[n.pipes,e];break;default:n.pipes.push(e);break}n.pipesCount+=1,$("pipe count=%d opts=%j",n.pipesCount,t);var o=(!t||t.end!==!1)&&e!==process.stdout&&e!==process.stderr,l=o?d:k;n.endEmitted?sn.nextTick(l):r.once("end",l),e.on("unpipe",u);function u(S,A){$("onunpipe"),S===r&&A&&A.hasUnpiped===!1&&(A.hasUnpiped=!0,h())}a(u,"onunpipe");function d(){$("onend"),e.end()}a(d,"onend");var m=R_(r);e.on("drain",m);var c=!1;function h(){$("cleanup"),e.removeListener("close",v),e.removeListener("finish",E),e.removeListener("drain",m),e.removeListener("error",w),e.removeListener("unpipe",u),r.removeListener("end",d),r.removeListener("end",k),r.removeListener("data",y),c=!0,n.awaitDrain&&(!e._writableState||e._writableState.needDrain)&&m()}a(h,"cleanup");var x=!1;r.on("data",y);function y(S){$("ondata"),x=!1;var A=e.write(S);A===!1&&!x&&((n.pipesCount===1&&n.pipes===e||n.pipesCount>1&&nd(n.pipes,e)!==-1)&&!c&&($("false write response, pause",n.awaitDrain),n.awaitDrain++,x=!0),r.pause())}a(y,"ondata");function w(S){$("onerror",S),k(),e.removeListener("error",w),Kc(e,"error")===0&&e.emit("error",S)}a(w,"onerror"),b_(e,"error",w);function v(){e.removeListener("finish",E),k()}a(v,"onclose"),e.once("close",v);function E(){$("onfinish"),e.removeListener("close",v),k()}a(E,"onfinish"),e.once("finish",E);function k(){$("unpipe"),r.unpipe(e)}return a(k,"unpipe"),e.emit("pipe",r),n.flowing||($("pipe resume"),r.resume()),e};function R_(e){return function(){var t=e._readableState;$("pipeOnDrain",t.awaitDrain),t.awaitDrain&&t.awaitDrain--,t.awaitDrain===0&&Kc(e,"data")&&(t.flowing=!0,Ks(e))}}a(R_,"pipeOnDrain");J.prototype.unpipe=function(e){var t=this._readableState,r={hasUnpiped:!1};if(t.pipesCount===0)return this;if(t.pipesCount===1)return e&&e!==t.pipes?this:(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,r),this);if(!e){var n=t.pipes,o=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var l=0;l<o;l++)n[l].emit("unpipe",this,{hasUnpiped:!1});return this}var u=nd(t.pipes,e);return u===-1?this:(t.pipes.splice(u,1),t.pipesCount-=1,t.pipesCount===1&&(t.pipes=t.pipes[0]),e.emit("unpipe",this,r),this)};J.prototype.on=function(e,t){var r=Ys.prototype.on.call(this,e,t);if(e==="data")this._readableState.flowing!==!1&&this.resume();else if(e==="readable"){var n=this._readableState;!n.endEmitted&&!n.readableListening&&(n.readableListening=n.needReadable=!0,n.emittedReadable=!1,n.reading?n.length&&Ca(this):sn.nextTick(T_,this))}return r};J.prototype.addListener=J.prototype.on;function T_(e){$("readable nexttick read 0"),e.read(0)}a(T_,"nReadingNextTick");J.prototype.resume=function(){var e=this._readableState;return e.flowing||($("resume"),e.flowing=!0,x_(this,e)),this};function x_(e,t){t.resumeScheduled||(t.resumeScheduled=!0,sn.nextTick(A_,e,t))}a(x_,"resume");function A_(e,t){t.reading||($("resume read 0"),e.read(0)),t.resumeScheduled=!1,t.awaitDrain=0,e.emit("resume"),Ks(e),t.flowing&&!t.reading&&e.read(0)}a(A_,"resume_");J.prototype.pause=function(){return $("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&($("pause"),this._readableState.flowing=!1,this.emit("pause")),this};function Ks(e){var t=e._readableState;for($("flow",t.flowing);t.flowing&&e.read()!==null;);}a(Ks,"flow");J.prototype.wrap=function(e){var t=this,r=this._readableState,n=!1;e.on("end",function(){if($("wrapped end"),r.decoder&&!r.ended){var u=r.decoder.end();u&&u.length&&t.push(u)}t.push(null)}),e.on("data",function(u){if($("wrapped data"),r.decoder&&(u=r.decoder.write(u)),!(r.objectMode&&u==null)&&!(!r.objectMode&&(!u||!u.length))){var d=t.push(u);d||(n=!0,e.pause())}});for(var o in e)this[o]===void 0&&typeof e[o]=="function"&&(this[o]=function(u){return function(){return e[u].apply(e,arguments)}}(o));for(var l=0;l<Zs.length;l++)e.on(Zs[l],this.emit.bind(this,Zs[l]));return this._read=function(u){$("wrapped _read",u),n&&(n=!1,e.resume())},this};Object.defineProperty(J.prototype,"readableHighWaterMark",{enumerable:!1,get:a(function(){return this._readableState.highWaterMark},"get")});J._fromList=rd;function rd(e,t){if(t.length===0)return null;var r;return t.objectMode?r=t.buffer.shift():!e||e>=t.length?(t.decoder?r=t.buffer.join(""):t.buffer.length===1?r=t.buffer.head.data:r=t.buffer.concat(t.length),t.buffer.clear()):r=k_(e,t.buffer,t.decoder),r}a(rd,"fromList");function k_(e,t,r){var n;return e<t.head.data.length?(n=t.head.data.slice(0,e),t.head.data=t.head.data.slice(e)):e===t.head.data.length?n=t.shift():n=r?E_(e,t):C_(e,t),n}a(k_,"fromListPartial");function E_(e,t){var r=t.head,n=1,o=r.data;for(e-=o.length;r=r.next;){var l=r.data,u=e>l.length?l.length:e;if(u===l.length?o+=l:o+=l.slice(0,e),e-=u,e===0){u===l.length?(++n,r.next?t.head=r.next:t.head=t.tail=null):(t.head=r,r.data=l.slice(u));break}++n}return t.length-=n,o}a(E_,"copyFromBufferString");function C_(e,t){var r=ai.allocUnsafe(e),n=t.head,o=1;for(n.data.copy(r),e-=n.data.length;n=n.next;){var l=n.data,u=e>l.length?l.length:e;if(l.copy(r,r.length-e,0,u),e-=u,e===0){u===l.length?(++o,n.next?t.head=n.next:t.head=t.tail=null):(t.head=n,n.data=l.slice(u));break}++o}return t.length-=o,r}a(C_,"copyFromBuffer");function Gs(e){var t=e._readableState;if(t.length>0)throw new Error('"endReadable()" called on non-empty stream');t.endEmitted||(t.ended=!0,sn.nextTick(P_,t,e))}a(Gs,"endReadable");function P_(e,t){!e.endEmitted&&e.length===0&&(e.endEmitted=!0,t.readable=!1,t.emit("end"))}a(P_,"endReadableNT");function nd(e,t){for(var r=0,n=e.length;r<n;r++)if(e[r]===t)return r;return-1}a(nd,"indexOf")});var Xs=P((ZR,sd)=>{"use strict";sd.exports=kt;var Pa=yr(),od=Object.create(rn());od.inherits=nn();od.inherits(kt,Pa);function I_(e,t){var r=this._transformState;r.transforming=!1;var n=r.writecb;if(!n)return this.emit("error",new Error("write callback called multiple times"));r.writechunk=null,r.writecb=null,t!=null&&this.push(t),n(e);var o=this._readableState;o.reading=!1,(o.needReadable||o.length<o.highWaterMark)&&this._read(o.highWaterMark)}a(I_,"afterTransform");function kt(e){if(!(this instanceof kt))return new kt(e);Pa.call(this,e),this._transformState={afterTransform:I_.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,e&&(typeof e.transform=="function"&&(this._transform=e.transform),typeof e.flush=="function"&&(this._flush=e.flush)),this.on("prefinish",F_)}a(kt,"Transform");function F_(){var e=this;typeof this._flush=="function"?this._flush(function(t,r){ad(e,t,r)}):ad(this,null,null)}a(F_,"prefinish");kt.prototype.push=function(e,t){return this._transformState.needTransform=!1,Pa.prototype.push.call(this,e,t)};kt.prototype._transform=function(e,t,r){throw new Error("_transform() is not implemented")};kt.prototype._write=function(e,t,r){var n=this._transformState;if(n.writecb=r,n.writechunk=e,n.writeencoding=t,!n.transforming){var o=this._readableState;(n.needTransform||o.needReadable||o.length<o.highWaterMark)&&this._read(o.highWaterMark)}};kt.prototype._read=function(e){var t=this._transformState;t.writechunk!==null&&t.writecb&&!t.transforming?(t.transforming=!0,this._transform(t.writechunk,t.writeencoding,t.afterTransform)):t.needTransform=!0};kt.prototype._destroy=function(e,t){var r=this;Pa.prototype._destroy.call(this,e,function(n){t(n),r.emit("close")})};function ad(e,t,r){if(t)return e.emit("error",t);if(r!=null&&e.push(r),e._writableState.length)throw new Error("Calling transform done when ws.length != 0");if(e._transformState.transforming)throw new Error("Calling transform done when still transforming");return e.push(null)}a(ad,"done")});var cd=P((GR,fd)=>{"use strict";fd.exports=oi;var ld=Xs(),ud=Object.create(rn());ud.inherits=nn();ud.inherits(oi,ld);function oi(e){if(!(this instanceof oi))return new oi(e);ld.call(this,e)}a(oi,"PassThrough");oi.prototype._transform=function(e,t,r){r(null,e)}});var Js=P((ue,Ia)=>{var lt=require("stream");process.env.READABLE_STREAM==="disable"&<?(Ia.exports=lt,ue=Ia.exports=lt.Readable,ue.Readable=lt.Readable,ue.Writable=lt.Writable,ue.Duplex=lt.Duplex,ue.Transform=lt.Transform,ue.PassThrough=lt.PassThrough,ue.Stream=lt):(ue=Ia.exports=Ws(),ue.Stream=lt||ue,ue.Readable=ue,ue.Writable=qs(),ue.Duplex=yr(),ue.Transform=Xs(),ue.PassThrough=cd())});var Et=P(Ae=>{"use strict";Ae.base64=!0;Ae.array=!0;Ae.string=!0;Ae.arraybuffer=typeof ArrayBuffer<"u"&&typeof Uint8Array<"u";Ae.nodebuffer=typeof Buffer<"u";Ae.uint8array=typeof Uint8Array<"u";if(typeof ArrayBuffer>"u")Ae.blob=!1;else{Qs=new ArrayBuffer(0);try{Ae.blob=new Blob([Qs],{type:"application/zip"}).size===0}catch{try{dd=self.BlobBuilder||self.WebKitBlobBuilder||self.MozBlobBuilder||self.MSBlobBuilder,el=new dd,el.append(Qs),Ae.blob=el.getBlob("application/zip").size===0}catch{Ae.blob=!1}}}var Qs,dd,el;try{Ae.nodestream=!!Js().Readable}catch{Ae.nodestream=!1}});var rl=P(tl=>{"use strict";var O_=ee(),D_=Et(),ut="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";tl.encode=function(e){for(var t=[],r,n,o,l,u,d,m,c=0,h=e.length,x=h,y=O_.getTypeOf(e)!=="string";c<e.length;)x=h-c,y?(r=e[c++],n=c<h?e[c++]:0,o=c<h?e[c++]:0):(r=e.charCodeAt(c++),n=c<h?e.charCodeAt(c++):0,o=c<h?e.charCodeAt(c++):0),l=r>>2,u=(r&3)<<4|n>>4,d=x>1?(n&15)<<2|o>>6:64,m=x>2?o&63:64,t.push(ut.charAt(l)+ut.charAt(u)+ut.charAt(d)+ut.charAt(m));return t.join("")};tl.decode=function(e){var t,r,n,o,l,u,d,m=0,c=0,h="data:";if(e.substr(0,h.length)===h)throw new Error("Invalid base64 input, it looks like a data url.");e=e.replace(/[^A-Za-z0-9+/=]/g,"");var x=e.length*3/4;if(e.charAt(e.length-1)===ut.charAt(64)&&x--,e.charAt(e.length-2)===ut.charAt(64)&&x--,x%1!==0)throw new Error("Invalid base64 input, bad content length.");var y;for(D_.uint8array?y=new Uint8Array(x|0):y=new Array(x|0);m<e.length;)o=ut.indexOf(e.charAt(m++)),l=ut.indexOf(e.charAt(m++)),u=ut.indexOf(e.charAt(m++)),d=ut.indexOf(e.charAt(m++)),t=o<<2|l>>4,r=(l&15)<<4|u>>2,n=(u&3)<<6|d,y[c++]=t,u!==64&&(y[c++]=r),d!==64&&(y[c++]=n);return y}});var si=P((JR,hd)=>{"use strict";hd.exports={isNode:typeof Buffer<"u",newBufferFrom:a(function(e,t){if(Buffer.from&&Buffer.from!==Uint8Array.from)return Buffer.from(e,t);if(typeof e=="number")throw new Error('The "data" argument must not be a number');return new Buffer(e,t)},"newBufferFrom"),allocBuffer:a(function(e){if(Buffer.alloc)return Buffer.alloc(e);var t=new Buffer(e);return t.fill(0),t},"allocBuffer"),isBuffer:a(function(e){return Buffer.isBuffer(e)},"isBuffer"),isStream:a(function(e){return e&&typeof e.on=="function"&&typeof e.pause=="function"&&typeof e.resume=="function"},"isStream")}});var bd=P((eT,gd)=>{"use strict";var pd=global.MutationObserver||global.WebKitMutationObserver,ln;process.browser?pd?(nl=0,md=new pd(li),il=global.document.createTextNode(""),md.observe(il,{characterData:!0}),ln=a(function(){il.data=nl=++nl%2},"scheduleDrain")):!global.setImmediate&&typeof global.MessageChannel<"u"?(al=new global.MessageChannel,al.port1.onmessage=li,ln=a(function(){al.port2.postMessage(0)},"scheduleDrain")):"document"in global&&"onreadystatechange"in global.document.createElement("script")?ln=a(function(){var e=global.document.createElement("script");e.onreadystatechange=function(){li(),e.onreadystatechange=null,e.parentNode.removeChild(e),e=null},global.document.documentElement.appendChild(e)},"scheduleDrain"):ln=a(function(){setTimeout(li,0)},"scheduleDrain"):ln=a(function(){process.nextTick(li)},"scheduleDrain");var nl,md,il,al,ol,ui=[];function li(){ol=!0;for(var e,t,r=ui.length;r;){for(t=ui,ui=[],e=-1;++e<r;)t[e]();r=ui.length}ol=!1}a(li,"nextTick");gd.exports=B_;function B_(e){ui.push(e)===1&&!ol&&ln()}a(B_,"immediate")});var Td=P((rT,Rd)=>{"use strict";var yd=bd();function un(){}a(un,"INTERNAL");var he={},_d=["REJECTED"],sl=["FULFILLED"],vd=["PENDING"];process.browser||(fi=["UNHANDLED"]);var fi;Rd.exports=$t;function $t(e){if(typeof e!="function")throw new TypeError("resolver must be a function");this.state=vd,this.queue=[],this.outcome=void 0,process.browser||(this.handled=fi),e!==un&&wd(this,e)}a($t,"Promise");$t.prototype.finally=function(e){if(typeof e!="function")return this;var t=this.constructor;return this.then(r,n);function r(o){function l(){return o}return a(l,"yes"),t.resolve(e()).then(l)}function n(o){function l(){throw o}return a(l,"no"),t.resolve(e()).then(l)}};$t.prototype.catch=function(e){return this.then(null,e)};$t.prototype.then=function(e,t){if(typeof e!="function"&&this.state===sl||typeof t!="function"&&this.state===_d)return this;var r=new this.constructor(un);if(process.browser||this.handled===fi&&(this.handled=null),this.state!==vd){var n=this.state===sl?e:t;ll(r,n,this.outcome)}else this.queue.push(new ci(r,e,t));return r};function ci(e,t,r){this.promise=e,typeof t=="function"&&(this.onFulfilled=t,this.callFulfilled=this.otherCallFulfilled),typeof r=="function"&&(this.onRejected=r,this.callRejected=this.otherCallRejected)}a(ci,"QueueItem");ci.prototype.callFulfilled=function(e){he.resolve(this.promise,e)};ci.prototype.otherCallFulfilled=function(e){ll(this.promise,this.onFulfilled,e)};ci.prototype.callRejected=function(e){he.reject(this.promise,e)};ci.prototype.otherCallRejected=function(e){ll(this.promise,this.onRejected,e)};function ll(e,t,r){yd(function(){var n;try{n=t(r)}catch(o){return he.reject(e,o)}n===e?he.reject(e,new TypeError("Cannot resolve promise with itself")):he.resolve(e,n)})}a(ll,"unwrap");he.resolve=function(e,t){var r=Sd(L_,t);if(r.status==="error")return he.reject(e,r.value);var n=r.value;if(n)wd(e,n);else{e.state=sl,e.outcome=t;for(var o=-1,l=e.queue.length;++o<l;)e.queue[o].callFulfilled(t)}return e};he.reject=function(e,t){e.state=_d,e.outcome=t,process.browser||e.handled===fi&&yd(function(){e.handled===fi&&process.emit("unhandledRejection",t,e)});for(var r=-1,n=e.queue.length;++r<n;)e.queue[r].callRejected(t);return e};function L_(e){var t=e&&e.then;if(e&&(typeof e=="object"||typeof e=="function")&&typeof t=="function")return a(function(){t.apply(e,arguments)},"appyThen")}a(L_,"getThen");function wd(e,t){var r=!1;function n(d){r||(r=!0,he.reject(e,d))}a(n,"onError");function o(d){r||(r=!0,he.resolve(e,d))}a(o,"onSuccess");function l(){t(o,n)}a(l,"tryToUnwrap");var u=Sd(l);u.status==="error"&&n(u.value)}a(wd,"safelyResolveThenable");function Sd(e,t){var r={};try{r.value=e(t),r.status="success"}catch(n){r.status="error",r.value=n}return r}a(Sd,"tryCatch");$t.resolve=z_;function z_(e){return e instanceof this?e:he.resolve(new this(un),e)}a(z_,"resolve");$t.reject=q_;function q_(e){var t=new this(un);return he.reject(t,e)}a(q_,"reject");$t.all=U_;function U_(e){var t=this;if(Object.prototype.toString.call(e)!=="[object Array]")return this.reject(new TypeError("must be an array"));var r=e.length,n=!1;if(!r)return this.resolve([]);for(var o=new Array(r),l=0,u=-1,d=new this(un);++u<r;)m(e[u],u);return d;function m(c,h){t.resolve(c).then(x,function(y){n||(n=!0,he.reject(d,y))});function x(y){o[h]=y,++l===r&&!n&&(n=!0,he.resolve(d,o))}a(x,"resolveFromAll")}}a(U_,"all");$t.race=M_;function M_(e){var t=this;if(Object.prototype.toString.call(e)!=="[object Array]")return this.reject(new TypeError("must be an array"));var r=e.length,n=!1;if(!r)return this.resolve([]);for(var o=-1,l=new this(un);++o<r;)u(e[o]);return l;function u(d){t.resolve(d).then(function(m){n||(n=!0,he.resolve(l,m))},function(m){n||(n=!0,he.reject(l,m))})}}a(M_,"race")});var fn=P((iT,xd)=>{"use strict";var ul=null;typeof Promise<"u"?ul=Promise:ul=Td();xd.exports={Promise:ul}});var kd=P(Ad=>{(function(e,t){"use strict";if(e.setImmediate)return;var r=1,n={},o=!1,l=e.document,u;function d(A){typeof A!="function"&&(A=new Function(""+A));for(var C=new Array(arguments.length-1),R=0;R<C.length;R++)C[R]=arguments[R+1];var T={callback:A,args:C};return n[r]=T,u(r),r++}a(d,"setImmediate");function m(A){delete n[A]}a(m,"clearImmediate");function c(A){var C=A.callback,R=A.args;switch(R.length){case 0:C();break;case 1:C(R[0]);break;case 2:C(R[0],R[1]);break;case 3:C(R[0],R[1],R[2]);break;default:C.apply(t,R);break}}a(c,"run");function h(A){if(o)setTimeout(h,0,A);else{var C=n[A];if(C){o=!0;try{c(C)}finally{m(A),o=!1}}}}a(h,"runIfPresent");function x(){u=a(function(A){process.nextTick(function(){h(A)})},"registerImmediate")}a(x,"installNextTickImplementation");function y(){if(e.postMessage&&!e.importScripts){var A=!0,C=e.onmessage;return e.onmessage=function(){A=!1},e.postMessage("","*"),e.onmessage=C,A}}a(y,"canUsePostMessage");function w(){var A="setImmediate$"+Math.random()+"$",C=a(function(R){R.source===e&&typeof R.data=="string"&&R.data.indexOf(A)===0&&h(+R.data.slice(A.length))},"onGlobalMessage");e.addEventListener?e.addEventListener("message",C,!1):e.attachEvent("onmessage",C),u=a(function(R){e.postMessage(A+R,"*")},"registerImmediate")}a(w,"installPostMessageImplementation");function v(){var A=new MessageChannel;A.port1.onmessage=function(C){var R=C.data;h(R)},u=a(function(C){A.port2.postMessage(C)},"registerImmediate")}a(v,"installMessageChannelImplementation");function E(){var A=l.documentElement;u=a(function(C){var R=l.createElement("script");R.onreadystatechange=function(){h(C),R.onreadystatechange=null,A.removeChild(R),R=null},A.appendChild(R)},"registerImmediate")}a(E,"installReadyStateChangeImplementation");function k(){u=a(function(A){setTimeout(h,0,A)},"registerImmediate")}a(k,"installSetTimeoutImplementation");var S=Object.getPrototypeOf&&Object.getPrototypeOf(e);S=S&&S.setTimeout?S:e,{}.toString.call(e.process)==="[object process]"?x():y()?w():e.MessageChannel?v():l&&"onreadystatechange"in l.createElement("script")?E():k(),S.setImmediate=d,S.clearImmediate=m})(typeof self>"u"?typeof global>"u"?Ad:global:self)});var ee=P(ie=>{"use strict";var Zt=Et(),W_=rl(),cn=si(),fl=fn();kd();function N_(e){var t=null;return Zt.uint8array?t=new Uint8Array(e.length):t=new Array(e.length),Oa(e,t)}a(N_,"string2binary");ie.newBlob=function(e,t){ie.checkSupport("blob");try{return new Blob([e],{type:t})}catch{try{var r=self.BlobBuilder||self.WebKitBlobBuilder||self.MozBlobBuilder||self.MSBlobBuilder,n=new r;return n.append(e),n.getBlob(t)}catch{throw new Error("Bug : can't construct the Blob.")}}};function di(e){return e}a(di,"identity");function Oa(e,t){for(var r=0;r<e.length;++r)t[r]=e.charCodeAt(r)&255;return t}a(Oa,"stringToArrayLike");var Fa={stringifyByChunk:a(function(e,t,r){var n=[],o=0,l=e.length;if(l<=r)return String.fromCharCode.apply(null,e);for(;o<l;)t==="array"||t==="nodebuffer"?n.push(String.fromCharCode.apply(null,e.slice(o,Math.min(o+r,l)))):n.push(String.fromCharCode.apply(null,e.subarray(o,Math.min(o+r,l)))),o+=r;return n.join("")},"stringifyByChunk"),stringifyByChar:a(function(e){for(var t="",r=0;r<e.length;r++)t+=String.fromCharCode(e[r]);return t},"stringifyByChar"),applyCanBeUsed:{uint8array:function(){try{return Zt.uint8array&&String.fromCharCode.apply(null,new Uint8Array(1)).length===1}catch{return!1}}(),nodebuffer:function(){try{return Zt.nodebuffer&&String.fromCharCode.apply(null,cn.allocBuffer(1)).length===1}catch{return!1}}()}};function hi(e){var t=65536,r=ie.getTypeOf(e),n=!0;if(r==="uint8array"?n=Fa.applyCanBeUsed.uint8array:r==="nodebuffer"&&(n=Fa.applyCanBeUsed.nodebuffer),n)for(;t>1;)try{return Fa.stringifyByChunk(e,r,t)}catch{t=Math.floor(t/2)}return Fa.stringifyByChar(e)}a(hi,"arrayLikeToString");ie.applyFromCharCode=hi;function Da(e,t){for(var r=0;r<e.length;r++)t[r]=e[r];return t}a(Da,"arrayLikeToArrayLike");var Vt={};Vt.string={string:di,array:a(function(e){return Oa(e,new Array(e.length))},"array"),arraybuffer:a(function(e){return Vt.string.uint8array(e).buffer},"arraybuffer"),uint8array:a(function(e){return Oa(e,new Uint8Array(e.length))},"uint8array"),nodebuffer:a(function(e){return Oa(e,cn.allocBuffer(e.length))},"nodebuffer")};Vt.array={string:hi,array:di,arraybuffer:a(function(e){return new Uint8Array(e).buffer},"arraybuffer"),uint8array:a(function(e){return new Uint8Array(e)},"uint8array"),nodebuffer:a(function(e){return cn.newBufferFrom(e)},"nodebuffer")};Vt.arraybuffer={string:a(function(e){return hi(new Uint8Array(e))},"string"),array:a(function(e){return Da(new Uint8Array(e),new Array(e.byteLength))},"array"),arraybuffer:di,uint8array:a(function(e){return new Uint8Array(e)},"uint8array"),nodebuffer:a(function(e){return cn.newBufferFrom(new Uint8Array(e))},"nodebuffer")};Vt.uint8array={string:hi,array:a(function(e){return Da(e,new Array(e.length))},"array"),arraybuffer:a(function(e){return e.buffer},"arraybuffer"),uint8array:di,nodebuffer:a(function(e){return cn.newBufferFrom(e)},"nodebuffer")};Vt.nodebuffer={string:hi,array:a(function(e){return Da(e,new Array(e.length))},"array"),arraybuffer:a(function(e){return Vt.nodebuffer.uint8array(e).buffer},"arraybuffer"),uint8array:a(function(e){return Da(e,new Uint8Array(e.length))},"uint8array"),nodebuffer:di};ie.transformTo=function(e,t){if(t||(t=""),!e)return t;ie.checkSupport(e);var r=ie.getTypeOf(t),n=Vt[r][e](t);return n};ie.resolve=function(e){for(var t=e.split("/"),r=[],n=0;n<t.length;n++){var o=t[n];o==="."||o===""&&n!==0&&n!==t.length-1||(o===".."?r.pop():r.push(o))}return r.join("/")};ie.getTypeOf=function(e){if(typeof e=="string")return"string";if(Object.prototype.toString.call(e)==="[object Array]")return"array";if(Zt.nodebuffer&&cn.isBuffer(e))return"nodebuffer";if(Zt.uint8array&&e instanceof Uint8Array)return"uint8array";if(Zt.arraybuffer&&e instanceof ArrayBuffer)return"arraybuffer"};ie.checkSupport=function(e){var t=Zt[e.toLowerCase()];if(!t)throw new Error(e+" is not supported by this platform")};ie.MAX_VALUE_16BITS=65535;ie.MAX_VALUE_32BITS=-1;ie.pretty=function(e){var t="",r,n;for(n=0;n<(e||"").length;n++)r=e.charCodeAt(n),t+="\\x"+(r<16?"0":"")+r.toString(16).toUpperCase();return t};ie.delay=function(e,t,r){setImmediate(function(){e.apply(r||null,t||[])})};ie.inherits=function(e,t){var r=a(function(){},"Obj");r.prototype=t.prototype,e.prototype=new r};ie.extend=function(){var e={},t,r;for(t=0;t<arguments.length;t++)for(r in arguments[t])Object.prototype.hasOwnProperty.call(arguments[t],r)&&typeof e[r]>"u"&&(e[r]=arguments[t][r]);return e};ie.prepareContent=function(e,t,r,n,o){var l=fl.Promise.resolve(t).then(function(u){var d=Zt.blob&&(u instanceof Blob||["[object File]","[object Blob]"].indexOf(Object.prototype.toString.call(u))!==-1);return d&&typeof FileReader<"u"?new fl.Promise(function(m,c){var h=new FileReader;h.onload=function(x){m(x.target.result)},h.onerror=function(x){c(x.target.error)},h.readAsArrayBuffer(u)}):u});return l.then(function(u){var d=ie.getTypeOf(u);return d?(d==="arraybuffer"?u=ie.transformTo("uint8array",u):d==="string"&&(o?u=W_.decode(u):r&&n!==!0&&(u=N_(u))),u):fl.Promise.reject(new Error("Can't read the data of '"+e+"'. Is it in a supported JavaScript type (String, Blob, ArrayBuffer, etc) ?"))})}});var ke=P((uT,Cd)=>{"use strict";function Ed(e){this.name=e||"default",this.streamInfo={},this.generatedError=null,this.extraStreamInfo={},this.isPaused=!0,this.isFinished=!1,this.isLocked=!1,this._listeners={data:[],end:[],error:[]},this.previous=null}a(Ed,"GenericWorker");Ed.prototype={push:a(function(e){this.emit("data",e)},"push"),end:a(function(){if(this.isFinished)return!1;this.flush();try{this.emit("end"),this.cleanUp(),this.isFinished=!0}catch(e){this.emit("error",e)}return!0},"end"),error:a(function(e){return this.isFinished?!1:(this.isPaused?this.generatedError=e:(this.isFinished=!0,this.emit("error",e),this.previous&&this.previous.error(e),this.cleanUp()),!0)},"error"),on:a(function(e,t){return this._listeners[e].push(t),this},"on"),cleanUp:a(function(){this.streamInfo=this.generatedError=this.extraStreamInfo=null,this._listeners=[]},"cleanUp"),emit:a(function(e,t){if(this._listeners[e])for(var r=0;r<this._listeners[e].length;r++)this._listeners[e][r].call(this,t)},"emit"),pipe:a(function(e){return e.registerPrevious(this)},"pipe"),registerPrevious:a(function(e){if(this.isLocked)throw new Error("The stream '"+this+"' has already been used.");this.streamInfo=e.streamInfo,this.mergeStreamInfo(),this.previous=e;var t=this;return e.on("data",function(r){t.processChunk(r)}),e.on("end",function(){t.end()}),e.on("error",function(r){t.error(r)}),this},"registerPrevious"),pause:a(function(){return this.isPaused||this.isFinished?!1:(this.isPaused=!0,this.previous&&this.previous.pause(),!0)},"pause"),resume:a(function(){if(!this.isPaused||this.isFinished)return!1;this.isPaused=!1;var e=!1;return this.generatedError&&(this.error(this.generatedError),e=!0),this.previous&&this.previous.resume(),!e},"resume"),flush:a(function(){},"flush"),processChunk:a(function(e){this.push(e)},"processChunk"),withStreamInfo:a(function(e,t){return this.extraStreamInfo[e]=t,this.mergeStreamInfo(),this},"withStreamInfo"),mergeStreamInfo:a(function(){for(var e in this.extraStreamInfo)Object.prototype.hasOwnProperty.call(this.extraStreamInfo,e)&&(this.streamInfo[e]=this.extraStreamInfo[e])},"mergeStreamInfo"),lock:a(function(){if(this.isLocked)throw new Error("The stream '"+this+"' has already been used.");this.isLocked=!0,this.previous&&this.previous.lock()},"lock"),toString:a(function(){var e="Worker "+this.name;return this.previous?this.previous+" -> "+e:e},"toString")};Cd.exports=Ed});var hn=P(Gt=>{"use strict";var dn=ee(),_r=Et(),j_=si(),Ba=ke(),pi=new Array(256);for(Ct=0;Ct<256;Ct++)pi[Ct]=Ct>=252?6:Ct>=248?5:Ct>=240?4:Ct>=224?3:Ct>=192?2:1;var Ct;pi[254]=pi[254]=1;var H_=a(function(e){var t,r,n,o,l,u=e.length,d=0;for(o=0;o<u;o++)r=e.charCodeAt(o),(r&64512)===55296&&o+1<u&&(n=e.charCodeAt(o+1),(n&64512)===56320&&(r=65536+(r-55296<<10)+(n-56320),o++)),d+=r<128?1:r<2048?2:r<65536?3:4;for(_r.uint8array?t=new Uint8Array(d):t=new Array(d),l=0,o=0;l<d;o++)r=e.charCodeAt(o),(r&64512)===55296&&o+1<u&&(n=e.charCodeAt(o+1),(n&64512)===56320&&(r=65536+(r-55296<<10)+(n-56320),o++)),r<128?t[l++]=r:r<2048?(t[l++]=192|r>>>6,t[l++]=128|r&63):r<65536?(t[l++]=224|r>>>12,t[l++]=128|r>>>6&63,t[l++]=128|r&63):(t[l++]=240|r>>>18,t[l++]=128|r>>>12&63,t[l++]=128|r>>>6&63,t[l++]=128|r&63);return t},"string2buf"),$_=a(function(e,t){var r;for(t=t||e.length,t>e.length&&(t=e.length),r=t-1;r>=0&&(e[r]&192)===128;)r--;return r<0||r===0?t:r+pi[e[r]]>t?r:t},"utf8border"),Z_=a(function(e){var t,r,n,o,l=e.length,u=new Array(l*2);for(r=0,t=0;t<l;){if(n=e[t++],n<128){u[r++]=n;continue}if(o=pi[n],o>4){u[r++]=65533,t+=o-1;continue}for(n&=o===2?31:o===3?15:7;o>1&&t<l;)n=n<<6|e[t++]&63,o--;if(o>1){u[r++]=65533;continue}n<65536?u[r++]=n:(n-=65536,u[r++]=55296|n>>10&1023,u[r++]=56320|n&1023)}return u.length!==r&&(u.subarray?u=u.subarray(0,r):u.length=r),dn.applyFromCharCode(u)},"buf2string");Gt.utf8encode=a(function(t){return _r.nodebuffer?j_.newBufferFrom(t,"utf-8"):H_(t)},"utf8encode");Gt.utf8decode=a(function(t){return _r.nodebuffer?dn.transformTo("nodebuffer",t).toString("utf-8"):(t=dn.transformTo(_r.uint8array?"uint8array":"array",t),Z_(t))},"utf8decode");function La(){Ba.call(this,"utf-8 decode"),this.leftOver=null}a(La,"Utf8DecodeWorker");dn.inherits(La,Ba);La.prototype.processChunk=function(e){var t=dn.transformTo(_r.uint8array?"uint8array":"array",e.data);if(this.leftOver&&this.leftOver.length){if(_r.uint8array){var r=t;t=new Uint8Array(r.length+this.leftOver.length),t.set(this.leftOver,0),t.set(r,this.leftOver.length)}else t=this.leftOver.concat(t);this.leftOver=null}var n=$_(t),o=t;n!==t.length&&(_r.uint8array?(o=t.subarray(0,n),this.leftOver=t.subarray(n,t.length)):(o=t.slice(0,n),this.leftOver=t.slice(n,t.length))),this.push({data:Gt.utf8decode(o),meta:e.meta})};La.prototype.flush=function(){this.leftOver&&this.leftOver.length&&(this.push({data:Gt.utf8decode(this.leftOver),meta:{}}),this.leftOver=null)};Gt.Utf8DecodeWorker=La;function cl(){Ba.call(this,"utf-8 encode")}a(cl,"Utf8EncodeWorker");dn.inherits(cl,Ba);cl.prototype.processChunk=function(e){this.push({data:Gt.utf8encode(e.data),meta:e.meta})};Gt.Utf8EncodeWorker=cl});var Od=P((hT,Fd)=>{"use strict";var Pd=ke(),Id=ee();function dl(e){Pd.call(this,"ConvertWorker to "+e),this.destType=e}a(dl,"ConvertWorker");Id.inherits(dl,Pd);dl.prototype.processChunk=function(e){this.push({data:Id.transformTo(this.destType,e.data),meta:e.meta})};Fd.exports=dl});var Ld=P((mT,Bd)=>{"use strict";var Dd=Js().Readable,V_=ee();V_.inherits(hl,Dd);function hl(e,t,r){Dd.call(this,t),this._helper=e;var n=this;e.on("data",function(o,l){n.push(o)||n._helper.pause(),r&&r(l)}).on("error",function(o){n.emit("error",o)}).on("end",function(){n.push(null)})}a(hl,"NodejsStreamOutputAdapter");hl.prototype._read=function(){this._helper.resume()};Bd.exports=hl});var pl=P((bT,Ud)=>{"use strict";var vr=ee(),G_=Od(),Y_=ke(),K_=rl(),X_=Et(),J_=fn(),zd=null;if(X_.nodestream)try{zd=Ld()}catch{}function Q_(e,t,r){switch(e){case"blob":return vr.newBlob(vr.transformTo("arraybuffer",t),r);case"base64":return K_.encode(t);default:return vr.transformTo(e,t)}}a(Q_,"transformZipOutput");function ev(e,t){var r,n=0,o=null,l=0;for(r=0;r<t.length;r++)l+=t[r].length;switch(e){case"string":return t.join("");case"array":return Array.prototype.concat.apply([],t);case"uint8array":for(o=new Uint8Array(l),r=0;r<t.length;r++)o.set(t[r],n),n+=t[r].length;return o;case"nodebuffer":return Buffer.concat(t);default:throw new Error("concat : unsupported type '"+e+"'")}}a(ev,"concat");function tv(e,t){return new J_.Promise(function(r,n){var o=[],l=e._internalType,u=e._outputType,d=e._mimeType;e.on("data",function(m,c){o.push(m),t&&t(c)}).on("error",function(m){o=[],n(m)}).on("end",function(){try{var m=Q_(u,ev(l,o),d);r(m)}catch(c){n(c)}o=[]}).resume()})}a(tv,"accumulate");function qd(e,t,r){var n=t;switch(t){case"blob":case"arraybuffer":n="uint8array";break;case"base64":n="string";break}try{this._internalType=n,this._outputType=t,this._mimeType=r,vr.checkSupport(n),this._worker=e.pipe(new G_(n)),e.lock()}catch(o){this._worker=new Y_("error"),this._worker.error(o)}}a(qd,"StreamHelper");qd.prototype={accumulate:a(function(e){return tv(this,e)},"accumulate"),on:a(function(e,t){var r=this;return e==="data"?this._worker.on(e,function(n){t.call(r,n.data,n.meta)}):this._worker.on(e,function(){vr.delay(t,arguments,r)}),this},"on"),resume:a(function(){return vr.delay(this._worker.resume,[],this._worker),this},"resume"),pause:a(function(){return this._worker.pause(),this},"pause"),toNodejsStream:a(function(e){if(vr.checkSupport("nodestream"),this._outputType!=="nodebuffer")throw new Error(this._outputType+" is not supported by this method");return new zd(this,{objectMode:this._outputType!=="nodebuffer"},e)},"toNodejsStream")};Ud.exports=qd});var ml=P(Ge=>{"use strict";Ge.base64=!1;Ge.binary=!1;Ge.dir=!1;Ge.createFolders=!0;Ge.date=null;Ge.compression=null;Ge.compressionOptions=null;Ge.comment=null;Ge.unixPermissions=null;Ge.dosPermissions=null});var gl=P((vT,Md)=>{"use strict";var za=ee(),qa=ke(),rv=16*1024;function pn(e){qa.call(this,"DataWorker");var t=this;this.dataIsReady=!1,this.index=0,this.max=0,this.data=null,this.type="",this._tickScheduled=!1,e.then(function(r){t.dataIsReady=!0,t.data=r,t.max=r&&r.length||0,t.type=za.getTypeOf(r),t.isPaused||t._tickAndRepeat()},function(r){t.error(r)})}a(pn,"DataWorker");za.inherits(pn,qa);pn.prototype.cleanUp=function(){qa.prototype.cleanUp.call(this),this.data=null};pn.prototype.resume=function(){return qa.prototype.resume.call(this)?(!this._tickScheduled&&this.dataIsReady&&(this._tickScheduled=!0,za.delay(this._tickAndRepeat,[],this)),!0):!1};pn.prototype._tickAndRepeat=function(){this._tickScheduled=!1,!(this.isPaused||this.isFinished)&&(this._tick(),this.isFinished||(za.delay(this._tickAndRepeat,[],this),this._tickScheduled=!0))};pn.prototype._tick=function(){if(this.isPaused||this.isFinished)return!1;var e=rv,t=null,r=Math.min(this.max,this.index+e);if(this.index>=this.max)return this.end();switch(this.type){case"string":t=this.data.substring(this.index,r);break;case"uint8array":t=this.data.subarray(this.index,r);break;case"array":case"nodebuffer":t=this.data.slice(this.index,r);break}return this.index=r,this.push({data:t,meta:{percent:this.max?this.index/this.max*100:0}})};Md.exports=pn});var Ua=P((ST,Nd)=>{"use strict";var nv=ee();function iv(){for(var e,t=[],r=0;r<256;r++){e=r;for(var n=0;n<8;n++)e=e&1?3988292384^e>>>1:e>>>1;t[r]=e}return t}a(iv,"makeTable");var Wd=iv();function av(e,t,r,n){var o=Wd,l=n+r;e=e^-1;for(var u=n;u<l;u++)e=e>>>8^o[(e^t[u])&255];return e^-1}a(av,"crc32");function ov(e,t,r,n){var o=Wd,l=n+r;e=e^-1;for(var u=n;u<l;u++)e=e>>>8^o[(e^t.charCodeAt(u))&255];return e^-1}a(ov,"crc32str");Nd.exports=a(function(t,r){if(typeof t>"u"||!t.length)return 0;var n=nv.getTypeOf(t)!=="string";return n?av(r|0,t,t.length,0):ov(r|0,t,t.length,0)},"crc32wrapper")});var yl=P((TT,Hd)=>{"use strict";var jd=ke(),sv=Ua(),lv=ee();function bl(){jd.call(this,"Crc32Probe"),this.withStreamInfo("crc32",0)}a(bl,"Crc32Probe");lv.inherits(bl,jd);bl.prototype.processChunk=function(e){this.streamInfo.crc32=sv(e.data,this.streamInfo.crc32||0),this.push(e)};Hd.exports=bl});var Zd=P((AT,$d)=>{"use strict";var uv=ee(),_l=ke();function vl(e){_l.call(this,"DataLengthProbe for "+e),this.propName=e,this.withStreamInfo(e,0)}a(vl,"DataLengthProbe");uv.inherits(vl,_l);vl.prototype.processChunk=function(e){if(e){var t=this.streamInfo[this.propName]||0;this.streamInfo[this.propName]=t+e.data.length}_l.prototype.processChunk.call(this,e)};$d.exports=vl});var Ma=P((ET,Yd)=>{"use strict";var Vd=fn(),Gd=gl(),fv=yl(),wl=Zd();function Sl(e,t,r,n,o){this.compressedSize=e,this.uncompressedSize=t,this.crc32=r,this.compression=n,this.compressedContent=o}a(Sl,"CompressedObject");Sl.prototype={getContentWorker:a(function(){var e=new Gd(Vd.Promise.resolve(this.compressedContent)).pipe(this.compression.uncompressWorker()).pipe(new wl("data_length")),t=this;return e.on("end",function(){if(this.streamInfo.data_length!==t.uncompressedSize)throw new Error("Bug : uncompressed data size mismatch")}),e},"getContentWorker"),getCompressedWorker:a(function(){return new Gd(Vd.Promise.resolve(this.compressedContent)).withStreamInfo("compressedSize",this.compressedSize).withStreamInfo("uncompressedSize",this.uncompressedSize).withStreamInfo("crc32",this.crc32).withStreamInfo("compression",this.compression)},"getCompressedWorker")};Sl.createWorkerFrom=function(e,t,r){return e.pipe(new fv).pipe(new wl("uncompressedSize")).pipe(t.compressWorker(r)).pipe(new wl("compressedSize")).withStreamInfo("compression",t)};Yd.exports=Sl});var Qd=P((PT,Jd)=>{"use strict";var cv=pl(),dv=gl(),Rl=hn(),Tl=Ma(),Kd=ke(),xl=a(function(e,t,r){this.name=e,this.dir=r.dir,this.date=r.date,this.comment=r.comment,this.unixPermissions=r.unixPermissions,this.dosPermissions=r.dosPermissions,this._data=t,this._dataBinary=r.binary,this.options={compression:r.compression,compressionOptions:r.compressionOptions}},"ZipObject");xl.prototype={internalStream:a(function(e){var t=null,r="string";try{if(!e)throw new Error("No output type specified.");r=e.toLowerCase();var n=r==="string"||r==="text";(r==="binarystring"||r==="text")&&(r="string"),t=this._decompressWorker();var o=!this._dataBinary;o&&!n&&(t=t.pipe(new Rl.Utf8EncodeWorker)),!o&&n&&(t=t.pipe(new Rl.Utf8DecodeWorker))}catch(l){t=new Kd("error"),t.error(l)}return new cv(t,r,"")},"internalStream"),async:a(function(e,t){return this.internalStream(e).accumulate(t)},"async"),nodeStream:a(function(e,t){return this.internalStream(e||"nodebuffer").toNodejsStream(t)},"nodeStream"),_compressWorker:a(function(e,t){if(this._data instanceof Tl&&this._data.compression.magic===e.magic)return this._data.getCompressedWorker();var r=this._decompressWorker();return this._dataBinary||(r=r.pipe(new Rl.Utf8EncodeWorker)),Tl.createWorkerFrom(r,e,t)},"_compressWorker"),_decompressWorker:a(function(){return this._data instanceof Tl?this._data.getContentWorker():this._data instanceof Kd?this._data:new dv(this._data)},"_decompressWorker")};var Xd=["asText","asBinary","asNodeBuffer","asUint8Array","asArrayBuffer"],hv=a(function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},"removedFn");for(Wa=0;Wa<Xd.length;Wa++)xl.prototype[Xd[Wa]]=hv;var Wa;Jd.exports=xl});var Pt=P(me=>{"use strict";var pv=typeof Uint8Array<"u"&&typeof Uint16Array<"u"&&typeof Int32Array<"u";function mv(e,t){return Object.prototype.hasOwnProperty.call(e,t)}a(mv,"_has");me.assign=function(e){for(var t=Array.prototype.slice.call(arguments,1);t.length;){var r=t.shift();if(r){if(typeof r!="object")throw new TypeError(r+"must be non-object");for(var n in r)mv(r,n)&&(e[n]=r[n])}}return e};me.shrinkBuf=function(e,t){return e.length===t?e:e.subarray?e.subarray(0,t):(e.length=t,e)};var gv={arraySet:a(function(e,t,r,n,o){if(t.subarray&&e.subarray){e.set(t.subarray(r,r+n),o);return}for(var l=0;l<n;l++)e[o+l]=t[r+l]},"arraySet"),flattenChunks:a(function(e){var t,r,n,o,l,u;for(n=0,t=0,r=e.length;t<r;t++)n+=e[t].length;for(u=new Uint8Array(n),o=0,t=0,r=e.length;t<r;t++)l=e[t],u.set(l,o),o+=l.length;return u},"flattenChunks")},bv={arraySet:a(function(e,t,r,n,o){for(var l=0;l<n;l++)e[o+l]=t[r+l]},"arraySet"),flattenChunks:a(function(e){return[].concat.apply([],e)},"flattenChunks")};me.setTyped=function(e){e?(me.Buf8=Uint8Array,me.Buf16=Uint16Array,me.Buf32=Int32Array,me.assign(me,gv)):(me.Buf8=Array,me.Buf16=Array,me.Buf32=Array,me.assign(me,bv))};me.setTyped(pv)});var Sh=P(bn=>{"use strict";var yv=Pt(),_v=4,eh=0,th=1,vv=2;function gn(e){for(var t=e.length;--t>=0;)e[t]=0}a(gn,"zero");var wv=0,sh=1,Sv=2,Rv=3,Tv=258,Fl=29,vi=256,gi=vi+1+Fl,mn=30,Ol=19,lh=2*gi+1,wr=15,Al=16,xv=7,Dl=256,uh=16,fh=17,ch=18,Pl=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0],Na=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],Av=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],dh=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],kv=512,It=new Array((gi+2)*2);gn(It);var mi=new Array(mn*2);gn(mi);var bi=new Array(kv);gn(bi);var yi=new Array(Tv-Rv+1);gn(yi);var Bl=new Array(Fl);gn(Bl);var ja=new Array(mn);gn(ja);function kl(e,t,r,n,o){this.static_tree=e,this.extra_bits=t,this.extra_base=r,this.elems=n,this.max_length=o,this.has_stree=e&&e.length}a(kl,"StaticTreeDesc");var hh,ph,mh;function El(e,t){this.dyn_tree=e,this.max_code=0,this.stat_desc=t}a(El,"TreeDesc");function gh(e){return e<256?bi[e]:bi[256+(e>>>7)]}a(gh,"d_code");function _i(e,t){e.pending_buf[e.pending++]=t&255,e.pending_buf[e.pending++]=t>>>8&255}a(_i,"put_short");function ve(e,t,r){e.bi_valid>Al-r?(e.bi_buf|=t<<e.bi_valid&65535,_i(e,e.bi_buf),e.bi_buf=t>>Al-e.bi_valid,e.bi_valid+=r-Al):(e.bi_buf|=t<<e.bi_valid&65535,e.bi_valid+=r)}a(ve,"send_bits");function ft(e,t,r){ve(e,r[t*2],r[t*2+1])}a(ft,"send_code");function bh(e,t){var r=0;do r|=e&1,e>>>=1,r<<=1;while(--t>0);return r>>>1}a(bh,"bi_reverse");function Ev(e){e.bi_valid===16?(_i(e,e.bi_buf),e.bi_buf=0,e.bi_valid=0):e.bi_valid>=8&&(e.pending_buf[e.pending++]=e.bi_buf&255,e.bi_buf>>=8,e.bi_valid-=8)}a(Ev,"bi_flush");function Cv(e,t){var r=t.dyn_tree,n=t.max_code,o=t.stat_desc.static_tree,l=t.stat_desc.has_stree,u=t.stat_desc.extra_bits,d=t.stat_desc.extra_base,m=t.stat_desc.max_length,c,h,x,y,w,v,E=0;for(y=0;y<=wr;y++)e.bl_count[y]=0;for(r[e.heap[e.heap_max]*2+1]=0,c=e.heap_max+1;c<lh;c++)h=e.heap[c],y=r[r[h*2+1]*2+1]+1,y>m&&(y=m,E++),r[h*2+1]=y,!(h>n)&&(e.bl_count[y]++,w=0,h>=d&&(w=u[h-d]),v=r[h*2],e.opt_len+=v*(y+w),l&&(e.static_len+=v*(o[h*2+1]+w)));if(E!==0){do{for(y=m-1;e.bl_count[y]===0;)y--;e.bl_count[y]--,e.bl_count[y+1]+=2,e.bl_count[m]--,E-=2}while(E>0);for(y=m;y!==0;y--)for(h=e.bl_count[y];h!==0;)x=e.heap[--c],!(x>n)&&(r[x*2+1]!==y&&(e.opt_len+=(y-r[x*2+1])*r[x*2],r[x*2+1]=y),h--)}}a(Cv,"gen_bitlen");function yh(e,t,r){var n=new Array(wr+1),o=0,l,u;for(l=1;l<=wr;l++)n[l]=o=o+r[l-1]<<1;for(u=0;u<=t;u++){var d=e[u*2+1];d!==0&&(e[u*2]=bh(n[d]++,d))}}a(yh,"gen_codes");function Pv(){var e,t,r,n,o,l=new Array(wr+1);for(r=0,n=0;n<Fl-1;n++)for(Bl[n]=r,e=0;e<1<<Pl[n];e++)yi[r++]=n;for(yi[r-1]=n,o=0,n=0;n<16;n++)for(ja[n]=o,e=0;e<1<<Na[n];e++)bi[o++]=n;for(o>>=7;n<mn;n++)for(ja[n]=o<<7,e=0;e<1<<Na[n]-7;e++)bi[256+o++]=n;for(t=0;t<=wr;t++)l[t]=0;for(e=0;e<=143;)It[e*2+1]=8,e++,l[8]++;for(;e<=255;)It[e*2+1]=9,e++,l[9]++;for(;e<=279;)It[e*2+1]=7,e++,l[7]++;for(;e<=287;)It[e*2+1]=8,e++,l[8]++;for(yh(It,gi+1,l),e=0;e<mn;e++)mi[e*2+1]=5,mi[e*2]=bh(e,5);hh=new kl(It,Pl,vi+1,gi,wr),ph=new kl(mi,Na,0,mn,wr),mh=new kl(new Array(0),Av,0,Ol,xv)}a(Pv,"tr_static_init");function _h(e){var t;for(t=0;t<gi;t++)e.dyn_ltree[t*2]=0;for(t=0;t<mn;t++)e.dyn_dtree[t*2]=0;for(t=0;t<Ol;t++)e.bl_tree[t*2]=0;e.dyn_ltree[Dl*2]=1,e.opt_len=e.static_len=0,e.last_lit=e.matches=0}a(_h,"init_block");function vh(e){e.bi_valid>8?_i(e,e.bi_buf):e.bi_valid>0&&(e.pending_buf[e.pending++]=e.bi_buf),e.bi_buf=0,e.bi_valid=0}a(vh,"bi_windup");function Iv(e,t,r,n){vh(e),n&&(_i(e,r),_i(e,~r)),yv.arraySet(e.pending_buf,e.window,t,r,e.pending),e.pending+=r}a(Iv,"copy_block");function rh(e,t,r,n){var o=t*2,l=r*2;return e[o]<e[l]||e[o]===e[l]&&n[t]<=n[r]}a(rh,"smaller");function Cl(e,t,r){for(var n=e.heap[r],o=r<<1;o<=e.heap_len&&(o<e.heap_len&&rh(t,e.heap[o+1],e.heap[o],e.depth)&&o++,!rh(t,n,e.heap[o],e.depth));)e.heap[r]=e.heap[o],r=o,o<<=1;e.heap[r]=n}a(Cl,"pqdownheap");function nh(e,t,r){var n,o,l=0,u,d;if(e.last_lit!==0)do n=e.pending_buf[e.d_buf+l*2]<<8|e.pending_buf[e.d_buf+l*2+1],o=e.pending_buf[e.l_buf+l],l++,n===0?ft(e,o,t):(u=yi[o],ft(e,u+vi+1,t),d=Pl[u],d!==0&&(o-=Bl[u],ve(e,o,d)),n--,u=gh(n),ft(e,u,r),d=Na[u],d!==0&&(n-=ja[u],ve(e,n,d)));while(l<e.last_lit);ft(e,Dl,t)}a(nh,"compress_block");function Il(e,t){var r=t.dyn_tree,n=t.stat_desc.static_tree,o=t.stat_desc.has_stree,l=t.stat_desc.elems,u,d,m=-1,c;for(e.heap_len=0,e.heap_max=lh,u=0;u<l;u++)r[u*2]!==0?(e.heap[++e.heap_len]=m=u,e.depth[u]=0):r[u*2+1]=0;for(;e.heap_len<2;)c=e.heap[++e.heap_len]=m<2?++m:0,r[c*2]=1,e.depth[c]=0,e.opt_len--,o&&(e.static_len-=n[c*2+1]);for(t.max_code=m,u=e.heap_len>>1;u>=1;u--)Cl(e,r,u);c=l;do u=e.heap[1],e.heap[1]=e.heap[e.heap_len--],Cl(e,r,1),d=e.heap[1],e.heap[--e.heap_max]=u,e.heap[--e.heap_max]=d,r[c*2]=r[u*2]+r[d*2],e.depth[c]=(e.depth[u]>=e.depth[d]?e.depth[u]:e.depth[d])+1,r[u*2+1]=r[d*2+1]=c,e.heap[1]=c++,Cl(e,r,1);while(e.heap_len>=2);e.heap[--e.heap_max]=e.heap[1],Cv(e,t),yh(r,m,e.bl_count)}a(Il,"build_tree");function ih(e,t,r){var n,o=-1,l,u=t[0*2+1],d=0,m=7,c=4;for(u===0&&(m=138,c=3),t[(r+1)*2+1]=65535,n=0;n<=r;n++)l=u,u=t[(n+1)*2+1],!(++d<m&&l===u)&&(d<c?e.bl_tree[l*2]+=d:l!==0?(l!==o&&e.bl_tree[l*2]++,e.bl_tree[uh*2]++):d<=10?e.bl_tree[fh*2]++:e.bl_tree[ch*2]++,d=0,o=l,u===0?(m=138,c=3):l===u?(m=6,c=3):(m=7,c=4))}a(ih,"scan_tree");function ah(e,t,r){var n,o=-1,l,u=t[0*2+1],d=0,m=7,c=4;for(u===0&&(m=138,c=3),n=0;n<=r;n++)if(l=u,u=t[(n+1)*2+1],!(++d<m&&l===u)){if(d<c)do ft(e,l,e.bl_tree);while(--d!==0);else l!==0?(l!==o&&(ft(e,l,e.bl_tree),d--),ft(e,uh,e.bl_tree),ve(e,d-3,2)):d<=10?(ft(e,fh,e.bl_tree),ve(e,d-3,3)):(ft(e,ch,e.bl_tree),ve(e,d-11,7));d=0,o=l,u===0?(m=138,c=3):l===u?(m=6,c=3):(m=7,c=4)}}a(ah,"send_tree");function Fv(e){var t;for(ih(e,e.dyn_ltree,e.l_desc.max_code),ih(e,e.dyn_dtree,e.d_desc.max_code),Il(e,e.bl_desc),t=Ol-1;t>=3&&e.bl_tree[dh[t]*2+1]===0;t--);return e.opt_len+=3*(t+1)+5+5+4,t}a(Fv,"build_bl_tree");function Ov(e,t,r,n){var o;for(ve(e,t-257,5),ve(e,r-1,5),ve(e,n-4,4),o=0;o<n;o++)ve(e,e.bl_tree[dh[o]*2+1],3);ah(e,e.dyn_ltree,t-1),ah(e,e.dyn_dtree,r-1)}a(Ov,"send_all_trees");function Dv(e){var t=4093624447,r;for(r=0;r<=31;r++,t>>>=1)if(t&1&&e.dyn_ltree[r*2]!==0)return eh;if(e.dyn_ltree[9*2]!==0||e.dyn_ltree[10*2]!==0||e.dyn_ltree[13*2]!==0)return th;for(r=32;r<vi;r++)if(e.dyn_ltree[r*2]!==0)return th;return eh}a(Dv,"detect_data_type");var oh=!1;function Bv(e){oh||(Pv(),oh=!0),e.l_desc=new El(e.dyn_ltree,hh),e.d_desc=new El(e.dyn_dtree,ph),e.bl_desc=new El(e.bl_tree,mh),e.bi_buf=0,e.bi_valid=0,_h(e)}a(Bv,"_tr_init");function wh(e,t,r,n){ve(e,(wv<<1)+(n?1:0),3),Iv(e,t,r,!0)}a(wh,"_tr_stored_block");function Lv(e){ve(e,sh<<1,3),ft(e,Dl,It),Ev(e)}a(Lv,"_tr_align");function zv(e,t,r,n){var o,l,u=0;e.level>0?(e.strm.data_type===vv&&(e.strm.data_type=Dv(e)),Il(e,e.l_desc),Il(e,e.d_desc),u=Fv(e),o=e.opt_len+3+7>>>3,l=e.static_len+3+7>>>3,l<=o&&(o=l)):o=l=r+5,r+4<=o&&t!==-1?wh(e,t,r,n):e.strategy===_v||l===o?(ve(e,(sh<<1)+(n?1:0),3),nh(e,It,mi)):(ve(e,(Sv<<1)+(n?1:0),3),Ov(e,e.l_desc.max_code+1,e.d_desc.max_code+1,u+1),nh(e,e.dyn_ltree,e.dyn_dtree)),_h(e),n&&vh(e)}a(zv,"_tr_flush_block");function qv(e,t,r){return e.pending_buf[e.d_buf+e.last_lit*2]=t>>>8&255,e.pending_buf[e.d_buf+e.last_lit*2+1]=t&255,e.pending_buf[e.l_buf+e.last_lit]=r&255,e.last_lit++,t===0?e.dyn_ltree[r*2]++:(e.matches++,t--,e.dyn_ltree[(yi[r]+vi+1)*2]++,e.dyn_dtree[gh(t)*2]++),e.last_lit===e.lit_bufsize-1}a(qv,"_tr_tally");bn._tr_init=Bv;bn._tr_stored_block=wh;bn._tr_flush_block=zv;bn._tr_tally=qv;bn._tr_align=Lv});var Ll=P((LT,Rh)=>{"use strict";function Uv(e,t,r,n){for(var o=e&65535|0,l=e>>>16&65535|0,u=0;r!==0;){u=r>2e3?2e3:r,r-=u;do o=o+t[n++]|0,l=l+o|0;while(--u);o%=65521,l%=65521}return o|l<<16|0}a(Uv,"adler32");Rh.exports=Uv});var zl=P((qT,Th)=>{"use strict";function Mv(){for(var e,t=[],r=0;r<256;r++){e=r;for(var n=0;n<8;n++)e=e&1?3988292384^e>>>1:e>>>1;t[r]=e}return t}a(Mv,"makeTable");var Wv=Mv();function Nv(e,t,r,n){var o=Wv,l=n+r;e^=-1;for(var u=n;u<l;u++)e=e>>>8^o[(e^t[u])&255];return e^-1}a(Nv,"crc32");Th.exports=Nv});var Ha=P((MT,xh)=>{"use strict";xh.exports={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}});var Dh=P(ht=>{"use strict";var ge=Pt(),Le=Sh(),Ch=Ll(),Yt=zl(),jv=Ha(),xr=0,Hv=1,$v=3,er=4,Ah=5,dt=0,kh=1,ze=-2,Zv=-3,ql=-5,Vv=-1,Gv=1,$a=2,Yv=3,Kv=4,Xv=0,Jv=2,Ya=8,Qv=9,e0=15,t0=8,r0=29,n0=256,Ml=n0+1+r0,i0=30,a0=19,o0=2*Ml+1,s0=15,j=3,Jt=258,Ye=Jt+j+1,l0=32,Ka=42,Wl=69,Za=73,Va=91,Ga=103,Sr=113,Si=666,ae=1,Ri=2,Rr=3,vn=4,u0=3;function Qt(e,t){return e.msg=jv[t],t}a(Qt,"err");function Eh(e){return(e<<1)-(e>4?9:0)}a(Eh,"rank");function Xt(e){for(var t=e.length;--t>=0;)e[t]=0}a(Xt,"zero");function Kt(e){var t=e.state,r=t.pending;r>e.avail_out&&(r=e.avail_out),r!==0&&(ge.arraySet(e.output,t.pending_buf,t.pending_out,r,e.next_out),e.next_out+=r,t.pending_out+=r,e.total_out+=r,e.avail_out-=r,t.pending-=r,t.pending===0&&(t.pending_out=0))}a(Kt,"flush_pending");function fe(e,t){Le._tr_flush_block(e,e.block_start>=0?e.block_start:-1,e.strstart-e.block_start,t),e.block_start=e.strstart,Kt(e.strm)}a(fe,"flush_block_only");function H(e,t){e.pending_buf[e.pending++]=t}a(H,"put_byte");function wi(e,t){e.pending_buf[e.pending++]=t>>>8&255,e.pending_buf[e.pending++]=t&255}a(wi,"putShortMSB");function f0(e,t,r,n){var o=e.avail_in;return o>n&&(o=n),o===0?0:(e.avail_in-=o,ge.arraySet(t,e.input,e.next_in,o,r),e.state.wrap===1?e.adler=Ch(e.adler,t,o,r):e.state.wrap===2&&(e.adler=Yt(e.adler,t,o,r)),e.next_in+=o,e.total_in+=o,o)}a(f0,"read_buf");function Ph(e,t){var r=e.max_chain_length,n=e.strstart,o,l,u=e.prev_length,d=e.nice_match,m=e.strstart>e.w_size-Ye?e.strstart-(e.w_size-Ye):0,c=e.window,h=e.w_mask,x=e.prev,y=e.strstart+Jt,w=c[n+u-1],v=c[n+u];e.prev_length>=e.good_match&&(r>>=2),d>e.lookahead&&(d=e.lookahead);do if(o=t,!(c[o+u]!==v||c[o+u-1]!==w||c[o]!==c[n]||c[++o]!==c[n+1])){n+=2,o++;do;while(c[++n]===c[++o]&&c[++n]===c[++o]&&c[++n]===c[++o]&&c[++n]===c[++o]&&c[++n]===c[++o]&&c[++n]===c[++o]&&c[++n]===c[++o]&&c[++n]===c[++o]&&n<y);if(l=Jt-(y-n),n=y-Jt,l>u){if(e.match_start=t,u=l,l>=d)break;w=c[n+u-1],v=c[n+u]}}while((t=x[t&h])>m&&--r!==0);return u<=e.lookahead?u:e.lookahead}a(Ph,"longest_match");function Tr(e){var t=e.w_size,r,n,o,l,u;do{if(l=e.window_size-e.lookahead-e.strstart,e.strstart>=t+(t-Ye)){ge.arraySet(e.window,e.window,t,t,0),e.match_start-=t,e.strstart-=t,e.block_start-=t,n=e.hash_size,r=n;do o=e.head[--r],e.head[r]=o>=t?o-t:0;while(--n);n=t,r=n;do o=e.prev[--r],e.prev[r]=o>=t?o-t:0;while(--n);l+=t}if(e.strm.avail_in===0)break;if(n=f0(e.strm,e.window,e.strstart+e.lookahead,l),e.lookahead+=n,e.lookahead+e.insert>=j)for(u=e.strstart-e.insert,e.ins_h=e.window[u],e.ins_h=(e.ins_h<<e.hash_shift^e.window[u+1])&e.hash_mask;e.insert&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[u+j-1])&e.hash_mask,e.prev[u&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=u,u++,e.insert--,!(e.lookahead+e.insert<j)););}while(e.lookahead<Ye&&e.strm.avail_in!==0)}a(Tr,"fill_window");function c0(e,t){var r=65535;for(r>e.pending_buf_size-5&&(r=e.pending_buf_size-5);;){if(e.lookahead<=1){if(Tr(e),e.lookahead===0&&t===xr)return ae;if(e.lookahead===0)break}e.strstart+=e.lookahead,e.lookahead=0;var n=e.block_start+r;if((e.strstart===0||e.strstart>=n)&&(e.lookahead=e.strstart-n,e.strstart=n,fe(e,!1),e.strm.avail_out===0)||e.strstart-e.block_start>=e.w_size-Ye&&(fe(e,!1),e.strm.avail_out===0))return ae}return e.insert=0,t===er?(fe(e,!0),e.strm.avail_out===0?Rr:vn):(e.strstart>e.block_start&&(fe(e,!1),e.strm.avail_out===0),ae)}a(c0,"deflate_stored");function Ul(e,t){for(var r,n;;){if(e.lookahead<Ye){if(Tr(e),e.lookahead<Ye&&t===xr)return ae;if(e.lookahead===0)break}if(r=0,e.lookahead>=j&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+j-1])&e.hash_mask,r=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),r!==0&&e.strstart-r<=e.w_size-Ye&&(e.match_length=Ph(e,r)),e.match_length>=j)if(n=Le._tr_tally(e,e.strstart-e.match_start,e.match_length-j),e.lookahead-=e.match_length,e.match_length<=e.max_lazy_match&&e.lookahead>=j){e.match_length--;do e.strstart++,e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+j-1])&e.hash_mask,r=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart;while(--e.match_length!==0);e.strstart++}else e.strstart+=e.match_length,e.match_length=0,e.ins_h=e.window[e.strstart],e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+1])&e.hash_mask;else n=Le._tr_tally(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++;if(n&&(fe(e,!1),e.strm.avail_out===0))return ae}return e.insert=e.strstart<j-1?e.strstart:j-1,t===er?(fe(e,!0),e.strm.avail_out===0?Rr:vn):e.last_lit&&(fe(e,!1),e.strm.avail_out===0)?ae:Ri}a(Ul,"deflate_fast");function yn(e,t){for(var r,n,o;;){if(e.lookahead<Ye){if(Tr(e),e.lookahead<Ye&&t===xr)return ae;if(e.lookahead===0)break}if(r=0,e.lookahead>=j&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+j-1])&e.hash_mask,r=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),e.prev_length=e.match_length,e.prev_match=e.match_start,e.match_length=j-1,r!==0&&e.prev_length<e.max_lazy_match&&e.strstart-r<=e.w_size-Ye&&(e.match_length=Ph(e,r),e.match_length<=5&&(e.strategy===Gv||e.match_length===j&&e.strstart-e.match_start>4096)&&(e.match_length=j-1)),e.prev_length>=j&&e.match_length<=e.prev_length){o=e.strstart+e.lookahead-j,n=Le._tr_tally(e,e.strstart-1-e.prev_match,e.prev_length-j),e.lookahead-=e.prev_length-1,e.prev_length-=2;do++e.strstart<=o&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+j-1])&e.hash_mask,r=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart);while(--e.prev_length!==0);if(e.match_available=0,e.match_length=j-1,e.strstart++,n&&(fe(e,!1),e.strm.avail_out===0))return ae}else if(e.match_available){if(n=Le._tr_tally(e,0,e.window[e.strstart-1]),n&&fe(e,!1),e.strstart++,e.lookahead--,e.strm.avail_out===0)return ae}else e.match_available=1,e.strstart++,e.lookahead--}return e.match_available&&(n=Le._tr_tally(e,0,e.window[e.strstart-1]),e.match_available=0),e.insert=e.strstart<j-1?e.strstart:j-1,t===er?(fe(e,!0),e.strm.avail_out===0?Rr:vn):e.last_lit&&(fe(e,!1),e.strm.avail_out===0)?ae:Ri}a(yn,"deflate_slow");function d0(e,t){for(var r,n,o,l,u=e.window;;){if(e.lookahead<=Jt){if(Tr(e),e.lookahead<=Jt&&t===xr)return ae;if(e.lookahead===0)break}if(e.match_length=0,e.lookahead>=j&&e.strstart>0&&(o=e.strstart-1,n=u[o],n===u[++o]&&n===u[++o]&&n===u[++o])){l=e.strstart+Jt;do;while(n===u[++o]&&n===u[++o]&&n===u[++o]&&n===u[++o]&&n===u[++o]&&n===u[++o]&&n===u[++o]&&n===u[++o]&&o<l);e.match_length=Jt-(l-o),e.match_length>e.lookahead&&(e.match_length=e.lookahead)}if(e.match_length>=j?(r=Le._tr_tally(e,1,e.match_length-j),e.lookahead-=e.match_length,e.strstart+=e.match_length,e.match_length=0):(r=Le._tr_tally(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++),r&&(fe(e,!1),e.strm.avail_out===0))return ae}return e.insert=0,t===er?(fe(e,!0),e.strm.avail_out===0?Rr:vn):e.last_lit&&(fe(e,!1),e.strm.avail_out===0)?ae:Ri}a(d0,"deflate_rle");function h0(e,t){for(var r;;){if(e.lookahead===0&&(Tr(e),e.lookahead===0)){if(t===xr)return ae;break}if(e.match_length=0,r=Le._tr_tally(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++,r&&(fe(e,!1),e.strm.avail_out===0))return ae}return e.insert=0,t===er?(fe(e,!0),e.strm.avail_out===0?Rr:vn):e.last_lit&&(fe(e,!1),e.strm.avail_out===0)?ae:Ri}a(h0,"deflate_huff");function ct(e,t,r,n,o){this.good_length=e,this.max_lazy=t,this.nice_length=r,this.max_chain=n,this.func=o}a(ct,"Config");var _n;_n=[new ct(0,0,0,0,c0),new ct(4,4,8,4,Ul),new ct(4,5,16,8,Ul),new ct(4,6,32,32,Ul),new ct(4,4,16,16,yn),new ct(8,16,32,32,yn),new ct(8,16,128,128,yn),new ct(8,32,128,256,yn),new ct(32,128,258,1024,yn),new ct(32,258,258,4096,yn)];function p0(e){e.window_size=2*e.w_size,Xt(e.head),e.max_lazy_match=_n[e.level].max_lazy,e.good_match=_n[e.level].good_length,e.nice_match=_n[e.level].nice_length,e.max_chain_length=_n[e.level].max_chain,e.strstart=0,e.block_start=0,e.lookahead=0,e.insert=0,e.match_length=e.prev_length=j-1,e.match_available=0,e.ins_h=0}a(p0,"lm_init");function m0(){this.strm=null,this.status=0,this.pending_buf=null,this.pending_buf_size=0,this.pending_out=0,this.pending=0,this.wrap=0,this.gzhead=null,this.gzindex=0,this.method=Ya,this.last_flush=-1,this.w_size=0,this.w_bits=0,this.w_mask=0,this.window=null,this.window_size=0,this.prev=null,this.head=null,this.ins_h=0,this.hash_size=0,this.hash_bits=0,this.hash_mask=0,this.hash_shift=0,this.block_start=0,this.match_length=0,this.prev_match=0,this.match_available=0,this.strstart=0,this.match_start=0,this.lookahead=0,this.prev_length=0,this.max_chain_length=0,this.max_lazy_match=0,this.level=0,this.strategy=0,this.good_match=0,this.nice_match=0,this.dyn_ltree=new ge.Buf16(o0*2),this.dyn_dtree=new ge.Buf16((2*i0+1)*2),this.bl_tree=new ge.Buf16((2*a0+1)*2),Xt(this.dyn_ltree),Xt(this.dyn_dtree),Xt(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new ge.Buf16(s0+1),this.heap=new ge.Buf16(2*Ml+1),Xt(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new ge.Buf16(2*Ml+1),Xt(this.depth),this.l_buf=0,this.lit_bufsize=0,this.last_lit=0,this.d_buf=0,this.opt_len=0,this.static_len=0,this.matches=0,this.insert=0,this.bi_buf=0,this.bi_valid=0}a(m0,"DeflateState");function Ih(e){var t;return!e||!e.state?Qt(e,ze):(e.total_in=e.total_out=0,e.data_type=Jv,t=e.state,t.pending=0,t.pending_out=0,t.wrap<0&&(t.wrap=-t.wrap),t.status=t.wrap?Ka:Sr,e.adler=t.wrap===2?0:1,t.last_flush=xr,Le._tr_init(t),dt)}a(Ih,"deflateResetKeep");function Fh(e){var t=Ih(e);return t===dt&&p0(e.state),t}a(Fh,"deflateReset");function g0(e,t){return!e||!e.state||e.state.wrap!==2?ze:(e.state.gzhead=t,dt)}a(g0,"deflateSetHeader");function Oh(e,t,r,n,o,l){if(!e)return ze;var u=1;if(t===Vv&&(t=6),n<0?(u=0,n=-n):n>15&&(u=2,n-=16),o<1||o>Qv||r!==Ya||n<8||n>15||t<0||t>9||l<0||l>Kv)return Qt(e,ze);n===8&&(n=9);var d=new m0;return e.state=d,d.strm=e,d.wrap=u,d.gzhead=null,d.w_bits=n,d.w_size=1<<d.w_bits,d.w_mask=d.w_size-1,d.hash_bits=o+7,d.hash_size=1<<d.hash_bits,d.hash_mask=d.hash_size-1,d.hash_shift=~~((d.hash_bits+j-1)/j),d.window=new ge.Buf8(d.w_size*2),d.head=new ge.Buf16(d.hash_size),d.prev=new ge.Buf16(d.w_size),d.lit_bufsize=1<<o+6,d.pending_buf_size=d.lit_bufsize*4,d.pending_buf=new ge.Buf8(d.pending_buf_size),d.d_buf=1*d.lit_bufsize,d.l_buf=3*d.lit_bufsize,d.level=t,d.strategy=l,d.method=r,Fh(e)}a(Oh,"deflateInit2");function b0(e,t){return Oh(e,t,Ya,e0,t0,Xv)}a(b0,"deflateInit");function y0(e,t){var r,n,o,l;if(!e||!e.state||t>Ah||t<0)return e?Qt(e,ze):ze;if(n=e.state,!e.output||!e.input&&e.avail_in!==0||n.status===Si&&t!==er)return Qt(e,e.avail_out===0?ql:ze);if(n.strm=e,r=n.last_flush,n.last_flush=t,n.status===Ka)if(n.wrap===2)e.adler=0,H(n,31),H(n,139),H(n,8),n.gzhead?(H(n,(n.gzhead.text?1:0)+(n.gzhead.hcrc?2:0)+(n.gzhead.extra?4:0)+(n.gzhead.name?8:0)+(n.gzhead.comment?16:0)),H(n,n.gzhead.time&255),H(n,n.gzhead.time>>8&255),H(n,n.gzhead.time>>16&255),H(n,n.gzhead.time>>24&255),H(n,n.level===9?2:n.strategy>=$a||n.level<2?4:0),H(n,n.gzhead.os&255),n.gzhead.extra&&n.gzhead.extra.length&&(H(n,n.gzhead.extra.length&255),H(n,n.gzhead.extra.length>>8&255)),n.gzhead.hcrc&&(e.adler=Yt(e.adler,n.pending_buf,n.pending,0)),n.gzindex=0,n.status=Wl):(H(n,0),H(n,0),H(n,0),H(n,0),H(n,0),H(n,n.level===9?2:n.strategy>=$a||n.level<2?4:0),H(n,u0),n.status=Sr);else{var u=Ya+(n.w_bits-8<<4)<<8,d=-1;n.strategy>=$a||n.level<2?d=0:n.level<6?d=1:n.level===6?d=2:d=3,u|=d<<6,n.strstart!==0&&(u|=l0),u+=31-u%31,n.status=Sr,wi(n,u),n.strstart!==0&&(wi(n,e.adler>>>16),wi(n,e.adler&65535)),e.adler=1}if(n.status===Wl)if(n.gzhead.extra){for(o=n.pending;n.gzindex<(n.gzhead.extra.length&65535)&&!(n.pending===n.pending_buf_size&&(n.gzhead.hcrc&&n.pending>o&&(e.adler=Yt(e.adler,n.pending_buf,n.pending-o,o)),Kt(e),o=n.pending,n.pending===n.pending_buf_size));)H(n,n.gzhead.extra[n.gzindex]&255),n.gzindex++;n.gzhead.hcrc&&n.pending>o&&(e.adler=Yt(e.adler,n.pending_buf,n.pending-o,o)),n.gzindex===n.gzhead.extra.length&&(n.gzindex=0,n.status=Za)}else n.status=Za;if(n.status===Za)if(n.gzhead.name){o=n.pending;do{if(n.pending===n.pending_buf_size&&(n.gzhead.hcrc&&n.pending>o&&(e.adler=Yt(e.adler,n.pending_buf,n.pending-o,o)),Kt(e),o=n.pending,n.pending===n.pending_buf_size)){l=1;break}n.gzindex<n.gzhead.name.length?l=n.gzhead.name.charCodeAt(n.gzindex++)&255:l=0,H(n,l)}while(l!==0);n.gzhead.hcrc&&n.pending>o&&(e.adler=Yt(e.adler,n.pending_buf,n.pending-o,o)),l===0&&(n.gzindex=0,n.status=Va)}else n.status=Va;if(n.status===Va)if(n.gzhead.comment){o=n.pending;do{if(n.pending===n.pending_buf_size&&(n.gzhead.hcrc&&n.pending>o&&(e.adler=Yt(e.adler,n.pending_buf,n.pending-o,o)),Kt(e),o=n.pending,n.pending===n.pending_buf_size)){l=1;break}n.gzindex<n.gzhead.comment.length?l=n.gzhead.comment.charCodeAt(n.gzindex++)&255:l=0,H(n,l)}while(l!==0);n.gzhead.hcrc&&n.pending>o&&(e.adler=Yt(e.adler,n.pending_buf,n.pending-o,o)),l===0&&(n.status=Ga)}else n.status=Ga;if(n.status===Ga&&(n.gzhead.hcrc?(n.pending+2>n.pending_buf_size&&Kt(e),n.pending+2<=n.pending_buf_size&&(H(n,e.adler&255),H(n,e.adler>>8&255),e.adler=0,n.status=Sr)):n.status=Sr),n.pending!==0){if(Kt(e),e.avail_out===0)return n.last_flush=-1,dt}else if(e.avail_in===0&&Eh(t)<=Eh(r)&&t!==er)return Qt(e,ql);if(n.status===Si&&e.avail_in!==0)return Qt(e,ql);if(e.avail_in!==0||n.lookahead!==0||t!==xr&&n.status!==Si){var m=n.strategy===$a?h0(n,t):n.strategy===Yv?d0(n,t):_n[n.level].func(n,t);if((m===Rr||m===vn)&&(n.status=Si),m===ae||m===Rr)return e.avail_out===0&&(n.last_flush=-1),dt;if(m===Ri&&(t===Hv?Le._tr_align(n):t!==Ah&&(Le._tr_stored_block(n,0,0,!1),t===$v&&(Xt(n.head),n.lookahead===0&&(n.strstart=0,n.block_start=0,n.insert=0))),Kt(e),e.avail_out===0))return n.last_flush=-1,dt}return t!==er?dt:n.wrap<=0?kh:(n.wrap===2?(H(n,e.adler&255),H(n,e.adler>>8&255),H(n,e.adler>>16&255),H(n,e.adler>>24&255),H(n,e.total_in&255),H(n,e.total_in>>8&255),H(n,e.total_in>>16&255),H(n,e.total_in>>24&255)):(wi(n,e.adler>>>16),wi(n,e.adler&65535)),Kt(e),n.wrap>0&&(n.wrap=-n.wrap),n.pending!==0?dt:kh)}a(y0,"deflate");function _0(e){var t;return!e||!e.state?ze:(t=e.state.status,t!==Ka&&t!==Wl&&t!==Za&&t!==Va&&t!==Ga&&t!==Sr&&t!==Si?Qt(e,ze):(e.state=null,t===Sr?Qt(e,Zv):dt))}a(_0,"deflateEnd");function v0(e,t){var r=t.length,n,o,l,u,d,m,c,h;if(!e||!e.state||(n=e.state,u=n.wrap,u===2||u===1&&n.status!==Ka||n.lookahead))return ze;for(u===1&&(e.adler=Ch(e.adler,t,r,0)),n.wrap=0,r>=n.w_size&&(u===0&&(Xt(n.head),n.strstart=0,n.block_start=0,n.insert=0),h=new ge.Buf8(n.w_size),ge.arraySet(h,t,r-n.w_size,n.w_size,0),t=h,r=n.w_size),d=e.avail_in,m=e.next_in,c=e.input,e.avail_in=r,e.next_in=0,e.input=t,Tr(n);n.lookahead>=j;){o=n.strstart,l=n.lookahead-(j-1);do n.ins_h=(n.ins_h<<n.hash_shift^n.window[o+j-1])&n.hash_mask,n.prev[o&n.w_mask]=n.head[n.ins_h],n.head[n.ins_h]=o,o++;while(--l);n.strstart=o,n.lookahead=j-1,Tr(n)}return n.strstart+=n.lookahead,n.block_start=n.strstart,n.insert=n.lookahead,n.lookahead=0,n.match_length=n.prev_length=j-1,n.match_available=0,e.next_in=m,e.input=c,e.avail_in=d,n.wrap=u,dt}a(v0,"deflateSetDictionary");ht.deflateInit=b0;ht.deflateInit2=Oh;ht.deflateReset=Fh;ht.deflateResetKeep=Ih;ht.deflateSetHeader=g0;ht.deflate=y0;ht.deflateEnd=_0;ht.deflateSetDictionary=v0;ht.deflateInfo="pako deflate (from Nodeca project)"});var Nl=P(wn=>{"use strict";var Xa=Pt(),Bh=!0,Lh=!0;try{String.fromCharCode.apply(null,[0])}catch{Bh=!1}try{String.fromCharCode.apply(null,new Uint8Array(1))}catch{Lh=!1}var Ti=new Xa.Buf8(256);for(Ft=0;Ft<256;Ft++)Ti[Ft]=Ft>=252?6:Ft>=248?5:Ft>=240?4:Ft>=224?3:Ft>=192?2:1;var Ft;Ti[254]=Ti[254]=1;wn.string2buf=function(e){var t,r,n,o,l,u=e.length,d=0;for(o=0;o<u;o++)r=e.charCodeAt(o),(r&64512)===55296&&o+1<u&&(n=e.charCodeAt(o+1),(n&64512)===56320&&(r=65536+(r-55296<<10)+(n-56320),o++)),d+=r<128?1:r<2048?2:r<65536?3:4;for(t=new Xa.Buf8(d),l=0,o=0;l<d;o++)r=e.charCodeAt(o),(r&64512)===55296&&o+1<u&&(n=e.charCodeAt(o+1),(n&64512)===56320&&(r=65536+(r-55296<<10)+(n-56320),o++)),r<128?t[l++]=r:r<2048?(t[l++]=192|r>>>6,t[l++]=128|r&63):r<65536?(t[l++]=224|r>>>12,t[l++]=128|r>>>6&63,t[l++]=128|r&63):(t[l++]=240|r>>>18,t[l++]=128|r>>>12&63,t[l++]=128|r>>>6&63,t[l++]=128|r&63);return t};function zh(e,t){if(t<65534&&(e.subarray&&Lh||!e.subarray&&Bh))return String.fromCharCode.apply(null,Xa.shrinkBuf(e,t));for(var r="",n=0;n<t;n++)r+=String.fromCharCode(e[n]);return r}a(zh,"buf2binstring");wn.buf2binstring=function(e){return zh(e,e.length)};wn.binstring2buf=function(e){for(var t=new Xa.Buf8(e.length),r=0,n=t.length;r<n;r++)t[r]=e.charCodeAt(r);return t};wn.buf2string=function(e,t){var r,n,o,l,u=t||e.length,d=new Array(u*2);for(n=0,r=0;r<u;){if(o=e[r++],o<128){d[n++]=o;continue}if(l=Ti[o],l>4){d[n++]=65533,r+=l-1;continue}for(o&=l===2?31:l===3?15:7;l>1&&r<u;)o=o<<6|e[r++]&63,l--;if(l>1){d[n++]=65533;continue}o<65536?d[n++]=o:(o-=65536,d[n++]=55296|o>>10&1023,d[n++]=56320|o&1023)}return zh(d,n)};wn.utf8border=function(e,t){var r;for(t=t||e.length,t>e.length&&(t=e.length),r=t-1;r>=0&&(e[r]&192)===128;)r--;return r<0||r===0?t:r+Ti[e[r]]>t?r:t}});var jl=P(($T,qh)=>{"use strict";function w0(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}a(w0,"ZStream");qh.exports=w0});var Nh=P(ki=>{"use strict";var xi=Dh(),Ai=Pt(),$l=Nl(),Zl=Ha(),S0=jl(),Wh=Object.prototype.toString,R0=0,Hl=4,Sn=0,Uh=1,Mh=2,T0=-1,x0=0,A0=8;function Ar(e){if(!(this instanceof Ar))return new Ar(e);this.options=Ai.assign({level:T0,method:A0,chunkSize:16384,windowBits:15,memLevel:8,strategy:x0,to:""},e||{});var t=this.options;t.raw&&t.windowBits>0?t.windowBits=-t.windowBits:t.gzip&&t.windowBits>0&&t.windowBits<16&&(t.windowBits+=16),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new S0,this.strm.avail_out=0;var r=xi.deflateInit2(this.strm,t.level,t.method,t.windowBits,t.memLevel,t.strategy);if(r!==Sn)throw new Error(Zl[r]);if(t.header&&xi.deflateSetHeader(this.strm,t.header),t.dictionary){var n;if(typeof t.dictionary=="string"?n=$l.string2buf(t.dictionary):Wh.call(t.dictionary)==="[object ArrayBuffer]"?n=new Uint8Array(t.dictionary):n=t.dictionary,r=xi.deflateSetDictionary(this.strm,n),r!==Sn)throw new Error(Zl[r]);this._dict_set=!0}}a(Ar,"Deflate");Ar.prototype.push=function(e,t){var r=this.strm,n=this.options.chunkSize,o,l;if(this.ended)return!1;l=t===~~t?t:t===!0?Hl:R0,typeof e=="string"?r.input=$l.string2buf(e):Wh.call(e)==="[object ArrayBuffer]"?r.input=new Uint8Array(e):r.input=e,r.next_in=0,r.avail_in=r.input.length;do{if(r.avail_out===0&&(r.output=new Ai.Buf8(n),r.next_out=0,r.avail_out=n),o=xi.deflate(r,l),o!==Uh&&o!==Sn)return this.onEnd(o),this.ended=!0,!1;(r.avail_out===0||r.avail_in===0&&(l===Hl||l===Mh))&&(this.options.to==="string"?this.onData($l.buf2binstring(Ai.shrinkBuf(r.output,r.next_out))):this.onData(Ai.shrinkBuf(r.output,r.next_out)))}while((r.avail_in>0||r.avail_out===0)&&o!==Uh);return l===Hl?(o=xi.deflateEnd(this.strm),this.onEnd(o),this.ended=!0,o===Sn):(l===Mh&&(this.onEnd(Sn),r.avail_out=0),!0)};Ar.prototype.onData=function(e){this.chunks.push(e)};Ar.prototype.onEnd=function(e){e===Sn&&(this.options.to==="string"?this.result=this.chunks.join(""):this.result=Ai.flattenChunks(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg};function Vl(e,t){var r=new Ar(t);if(r.push(e,!0),r.err)throw r.msg||Zl[r.err];return r.result}a(Vl,"deflate");function k0(e,t){return t=t||{},t.raw=!0,Vl(e,t)}a(k0,"deflateRaw");function E0(e,t){return t=t||{},t.gzip=!0,Vl(e,t)}a(E0,"gzip");ki.Deflate=Ar;ki.deflate=Vl;ki.deflateRaw=k0;ki.gzip=E0});var Hh=P((YT,jh)=>{"use strict";var Ja=30,C0=12;jh.exports=a(function(t,r){var n,o,l,u,d,m,c,h,x,y,w,v,E,k,S,A,C,R,T,F,z,B,M,V,O;n=t.state,o=t.next_in,V=t.input,l=o+(t.avail_in-5),u=t.next_out,O=t.output,d=u-(r-t.avail_out),m=u+(t.avail_out-257),c=n.dmax,h=n.wsize,x=n.whave,y=n.wnext,w=n.window,v=n.hold,E=n.bits,k=n.lencode,S=n.distcode,A=(1<<n.lenbits)-1,C=(1<<n.distbits)-1;e:do{E<15&&(v+=V[o++]<<E,E+=8,v+=V[o++]<<E,E+=8),R=k[v&A];t:for(;;){if(T=R>>>24,v>>>=T,E-=T,T=R>>>16&255,T===0)O[u++]=R&65535;else if(T&16){F=R&65535,T&=15,T&&(E<T&&(v+=V[o++]<<E,E+=8),F+=v&(1<<T)-1,v>>>=T,E-=T),E<15&&(v+=V[o++]<<E,E+=8,v+=V[o++]<<E,E+=8),R=S[v&C];r:for(;;){if(T=R>>>24,v>>>=T,E-=T,T=R>>>16&255,T&16){if(z=R&65535,T&=15,E<T&&(v+=V[o++]<<E,E+=8,E<T&&(v+=V[o++]<<E,E+=8)),z+=v&(1<<T)-1,z>c){t.msg="invalid distance too far back",n.mode=Ja;break e}if(v>>>=T,E-=T,T=u-d,z>T){if(T=z-T,T>x&&n.sane){t.msg="invalid distance too far back",n.mode=Ja;break e}if(B=0,M=w,y===0){if(B+=h-T,T<F){F-=T;do O[u++]=w[B++];while(--T);B=u-z,M=O}}else if(y<T){if(B+=h+y-T,T-=y,T<F){F-=T;do O[u++]=w[B++];while(--T);if(B=0,y<F){T=y,F-=T;do O[u++]=w[B++];while(--T);B=u-z,M=O}}}else if(B+=y-T,T<F){F-=T;do O[u++]=w[B++];while(--T);B=u-z,M=O}for(;F>2;)O[u++]=M[B++],O[u++]=M[B++],O[u++]=M[B++],F-=3;F&&(O[u++]=M[B++],F>1&&(O[u++]=M[B++]))}else{B=u-z;do O[u++]=O[B++],O[u++]=O[B++],O[u++]=O[B++],F-=3;while(F>2);F&&(O[u++]=O[B++],F>1&&(O[u++]=O[B++]))}}else if(T&64){t.msg="invalid distance code",n.mode=Ja;break e}else{R=S[(R&65535)+(v&(1<<T)-1)];continue r}break}}else if(T&64)if(T&32){n.mode=C0;break e}else{t.msg="invalid literal/length code",n.mode=Ja;break e}else{R=k[(R&65535)+(v&(1<<T)-1)];continue t}break}}while(o<l&&u<m);F=E>>3,o-=F,E-=F<<3,v&=(1<<E)-1,t.next_in=o,t.next_out=u,t.avail_in=o<l?5+(l-o):5-(o-l),t.avail_out=u<m?257+(m-u):257-(u-m),n.hold=v,n.bits=E},"inflate_fast")});var Xh=P((XT,Kh)=>{"use strict";var $h=Pt(),Rn=15,Zh=852,Vh=592,Gh=0,Gl=1,Yh=2,P0=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0],I0=[16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78],F0=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0],O0=[16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64];Kh.exports=a(function(t,r,n,o,l,u,d,m){var c=m.bits,h=0,x=0,y=0,w=0,v=0,E=0,k=0,S=0,A=0,C=0,R,T,F,z,B,M=null,V=0,O,le=new $h.Buf16(Rn+1),ce=new $h.Buf16(Rn+1),mt=null,Or=0,Cn,Dr,Bt;for(h=0;h<=Rn;h++)le[h]=0;for(x=0;x<o;x++)le[r[n+x]]++;for(v=c,w=Rn;w>=1&&le[w]===0;w--);if(v>w&&(v=w),w===0)return l[u++]=1<<24|64<<16|0,l[u++]=1<<24|64<<16|0,m.bits=1,0;for(y=1;y<w&&le[y]===0;y++);for(v<y&&(v=y),S=1,h=1;h<=Rn;h++)if(S<<=1,S-=le[h],S<0)return-1;if(S>0&&(t===Gh||w!==1))return-1;for(ce[1]=0,h=1;h<Rn;h++)ce[h+1]=ce[h]+le[h];for(x=0;x<o;x++)r[n+x]!==0&&(d[ce[r[n+x]]++]=x);if(t===Gh?(M=mt=d,O=19):t===Gl?(M=P0,V-=257,mt=I0,Or-=257,O=256):(M=F0,mt=O0,O=-1),C=0,x=0,h=y,B=u,E=v,k=0,F=-1,A=1<<v,z=A-1,t===Gl&&A>Zh||t===Yh&&A>Vh)return 1;for(;;){Cn=h-k,d[x]<O?(Dr=0,Bt=d[x]):d[x]>O?(Dr=mt[Or+d[x]],Bt=M[V+d[x]]):(Dr=96,Bt=0),R=1<<h-k,T=1<<E,y=T;do T-=R,l[B+(C>>k)+T]=Cn<<24|Dr<<16|Bt|0;while(T!==0);for(R=1<<h-1;C&R;)R>>=1;if(R!==0?(C&=R-1,C+=R):C=0,x++,--le[h]===0){if(h===w)break;h=r[n+d[x]]}if(h>v&&(C&z)!==F){for(k===0&&(k=v),B+=y,E=h-k,S=1<<E;E+k<w&&(S-=le[E+k],!(S<=0));)E++,S<<=1;if(A+=1<<E,t===Gl&&A>Zh||t===Yh&&A>Vh)return 1;F=C&z,l[F]=v<<24|E<<16|B-u|0}}return C!==0&&(l[B+C]=h-k<<24|64<<16|0),m.bits=v,0},"inflate_table")});var Fp=P(Ke=>{"use strict";var Ee=Pt(),eu=Ll(),pt=zl(),D0=Hh(),Ei=Xh(),B0=0,Rp=1,Tp=2,Jh=4,L0=5,Qa=6,kr=0,z0=1,q0=2,qe=-2,xp=-3,tu=-4,U0=-5,Qh=8,Ap=1,ep=2,tp=3,rp=4,np=5,ip=6,ap=7,op=8,sp=9,lp=10,ro=11,Ot=12,Yl=13,up=14,Kl=15,fp=16,cp=17,dp=18,hp=19,eo=20,to=21,pp=22,mp=23,gp=24,bp=25,yp=26,Xl=27,_p=28,vp=29,Q=30,ru=31,M0=32,W0=852,N0=592,j0=15,H0=j0;function wp(e){return(e>>>24&255)+(e>>>8&65280)+((e&65280)<<8)+((e&255)<<24)}a(wp,"zswap32");function $0(){this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new Ee.Buf16(320),this.work=new Ee.Buf16(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}a($0,"InflateState");function kp(e){var t;return!e||!e.state?qe:(t=e.state,e.total_in=e.total_out=t.total=0,e.msg="",t.wrap&&(e.adler=t.wrap&1),t.mode=Ap,t.last=0,t.havedict=0,t.dmax=32768,t.head=null,t.hold=0,t.bits=0,t.lencode=t.lendyn=new Ee.Buf32(W0),t.distcode=t.distdyn=new Ee.Buf32(N0),t.sane=1,t.back=-1,kr)}a(kp,"inflateResetKeep");function Ep(e){var t;return!e||!e.state?qe:(t=e.state,t.wsize=0,t.whave=0,t.wnext=0,kp(e))}a(Ep,"inflateReset");function Cp(e,t){var r,n;return!e||!e.state||(n=e.state,t<0?(r=0,t=-t):(r=(t>>4)+1,t<48&&(t&=15)),t&&(t<8||t>15))?qe:(n.window!==null&&n.wbits!==t&&(n.window=null),n.wrap=r,n.wbits=t,Ep(e))}a(Cp,"inflateReset2");function Pp(e,t){var r,n;return e?(n=new $0,e.state=n,n.window=null,r=Cp(e,t),r!==kr&&(e.state=null),r):qe}a(Pp,"inflateInit2");function Z0(e){return Pp(e,H0)}a(Z0,"inflateInit");var Sp=!0,Jl,Ql;function V0(e){if(Sp){var t;for(Jl=new Ee.Buf32(512),Ql=new Ee.Buf32(32),t=0;t<144;)e.lens[t++]=8;for(;t<256;)e.lens[t++]=9;for(;t<280;)e.lens[t++]=7;for(;t<288;)e.lens[t++]=8;for(Ei(Rp,e.lens,0,288,Jl,0,e.work,{bits:9}),t=0;t<32;)e.lens[t++]=5;Ei(Tp,e.lens,0,32,Ql,0,e.work,{bits:5}),Sp=!1}e.lencode=Jl,e.lenbits=9,e.distcode=Ql,e.distbits=5}a(V0,"fixedtables");function Ip(e,t,r,n){var o,l=e.state;return l.window===null&&(l.wsize=1<<l.wbits,l.wnext=0,l.whave=0,l.window=new Ee.Buf8(l.wsize)),n>=l.wsize?(Ee.arraySet(l.window,t,r-l.wsize,l.wsize,0),l.wnext=0,l.whave=l.wsize):(o=l.wsize-l.wnext,o>n&&(o=n),Ee.arraySet(l.window,t,r-n,o,l.wnext),n-=o,n?(Ee.arraySet(l.window,t,r-n,n,0),l.wnext=n,l.whave=l.wsize):(l.wnext+=o,l.wnext===l.wsize&&(l.wnext=0),l.whave<l.wsize&&(l.whave+=o))),0}a(Ip,"updatewindow");function G0(e,t){var r,n,o,l,u,d,m,c,h,x,y,w,v,E,k=0,S,A,C,R,T,F,z,B,M=new Ee.Buf8(4),V,O,le=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!e||!e.state||!e.output||!e.input&&e.avail_in!==0)return qe;r=e.state,r.mode===Ot&&(r.mode=Yl),u=e.next_out,o=e.output,m=e.avail_out,l=e.next_in,n=e.input,d=e.avail_in,c=r.hold,h=r.bits,x=d,y=m,B=kr;e:for(;;)switch(r.mode){case Ap:if(r.wrap===0){r.mode=Yl;break}for(;h<16;){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}if(r.wrap&2&&c===35615){r.check=0,M[0]=c&255,M[1]=c>>>8&255,r.check=pt(r.check,M,2,0),c=0,h=0,r.mode=ep;break}if(r.flags=0,r.head&&(r.head.done=!1),!(r.wrap&1)||(((c&255)<<8)+(c>>8))%31){e.msg="incorrect header check",r.mode=Q;break}if((c&15)!==Qh){e.msg="unknown compression method",r.mode=Q;break}if(c>>>=4,h-=4,z=(c&15)+8,r.wbits===0)r.wbits=z;else if(z>r.wbits){e.msg="invalid window size",r.mode=Q;break}r.dmax=1<<z,e.adler=r.check=1,r.mode=c&512?lp:Ot,c=0,h=0;break;case ep:for(;h<16;){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}if(r.flags=c,(r.flags&255)!==Qh){e.msg="unknown compression method",r.mode=Q;break}if(r.flags&57344){e.msg="unknown header flags set",r.mode=Q;break}r.head&&(r.head.text=c>>8&1),r.flags&512&&(M[0]=c&255,M[1]=c>>>8&255,r.check=pt(r.check,M,2,0)),c=0,h=0,r.mode=tp;case tp:for(;h<32;){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}r.head&&(r.head.time=c),r.flags&512&&(M[0]=c&255,M[1]=c>>>8&255,M[2]=c>>>16&255,M[3]=c>>>24&255,r.check=pt(r.check,M,4,0)),c=0,h=0,r.mode=rp;case rp:for(;h<16;){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}r.head&&(r.head.xflags=c&255,r.head.os=c>>8),r.flags&512&&(M[0]=c&255,M[1]=c>>>8&255,r.check=pt(r.check,M,2,0)),c=0,h=0,r.mode=np;case np:if(r.flags&1024){for(;h<16;){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}r.length=c,r.head&&(r.head.extra_len=c),r.flags&512&&(M[0]=c&255,M[1]=c>>>8&255,r.check=pt(r.check,M,2,0)),c=0,h=0}else r.head&&(r.head.extra=null);r.mode=ip;case ip:if(r.flags&1024&&(w=r.length,w>d&&(w=d),w&&(r.head&&(z=r.head.extra_len-r.length,r.head.extra||(r.head.extra=new Array(r.head.extra_len)),Ee.arraySet(r.head.extra,n,l,w,z)),r.flags&512&&(r.check=pt(r.check,n,w,l)),d-=w,l+=w,r.length-=w),r.length))break e;r.length=0,r.mode=ap;case ap:if(r.flags&2048){if(d===0)break e;w=0;do z=n[l+w++],r.head&&z&&r.length<65536&&(r.head.name+=String.fromCharCode(z));while(z&&w<d);if(r.flags&512&&(r.check=pt(r.check,n,w,l)),d-=w,l+=w,z)break e}else r.head&&(r.head.name=null);r.length=0,r.mode=op;case op:if(r.flags&4096){if(d===0)break e;w=0;do z=n[l+w++],r.head&&z&&r.length<65536&&(r.head.comment+=String.fromCharCode(z));while(z&&w<d);if(r.flags&512&&(r.check=pt(r.check,n,w,l)),d-=w,l+=w,z)break e}else r.head&&(r.head.comment=null);r.mode=sp;case sp:if(r.flags&512){for(;h<16;){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}if(c!==(r.check&65535)){e.msg="header crc mismatch",r.mode=Q;break}c=0,h=0}r.head&&(r.head.hcrc=r.flags>>9&1,r.head.done=!0),e.adler=r.check=0,r.mode=Ot;break;case lp:for(;h<32;){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}e.adler=r.check=wp(c),c=0,h=0,r.mode=ro;case ro:if(r.havedict===0)return e.next_out=u,e.avail_out=m,e.next_in=l,e.avail_in=d,r.hold=c,r.bits=h,q0;e.adler=r.check=1,r.mode=Ot;case Ot:if(t===L0||t===Qa)break e;case Yl:if(r.last){c>>>=h&7,h-=h&7,r.mode=Xl;break}for(;h<3;){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}switch(r.last=c&1,c>>>=1,h-=1,c&3){case 0:r.mode=up;break;case 1:if(V0(r),r.mode=eo,t===Qa){c>>>=2,h-=2;break e}break;case 2:r.mode=cp;break;case 3:e.msg="invalid block type",r.mode=Q}c>>>=2,h-=2;break;case up:for(c>>>=h&7,h-=h&7;h<32;){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}if((c&65535)!==(c>>>16^65535)){e.msg="invalid stored block lengths",r.mode=Q;break}if(r.length=c&65535,c=0,h=0,r.mode=Kl,t===Qa)break e;case Kl:r.mode=fp;case fp:if(w=r.length,w){if(w>d&&(w=d),w>m&&(w=m),w===0)break e;Ee.arraySet(o,n,l,w,u),d-=w,l+=w,m-=w,u+=w,r.length-=w;break}r.mode=Ot;break;case cp:for(;h<14;){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}if(r.nlen=(c&31)+257,c>>>=5,h-=5,r.ndist=(c&31)+1,c>>>=5,h-=5,r.ncode=(c&15)+4,c>>>=4,h-=4,r.nlen>286||r.ndist>30){e.msg="too many length or distance symbols",r.mode=Q;break}r.have=0,r.mode=dp;case dp:for(;r.have<r.ncode;){for(;h<3;){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}r.lens[le[r.have++]]=c&7,c>>>=3,h-=3}for(;r.have<19;)r.lens[le[r.have++]]=0;if(r.lencode=r.lendyn,r.lenbits=7,V={bits:r.lenbits},B=Ei(B0,r.lens,0,19,r.lencode,0,r.work,V),r.lenbits=V.bits,B){e.msg="invalid code lengths set",r.mode=Q;break}r.have=0,r.mode=hp;case hp:for(;r.have<r.nlen+r.ndist;){for(;k=r.lencode[c&(1<<r.lenbits)-1],S=k>>>24,A=k>>>16&255,C=k&65535,!(S<=h);){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}if(C<16)c>>>=S,h-=S,r.lens[r.have++]=C;else{if(C===16){for(O=S+2;h<O;){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}if(c>>>=S,h-=S,r.have===0){e.msg="invalid bit length repeat",r.mode=Q;break}z=r.lens[r.have-1],w=3+(c&3),c>>>=2,h-=2}else if(C===17){for(O=S+3;h<O;){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}c>>>=S,h-=S,z=0,w=3+(c&7),c>>>=3,h-=3}else{for(O=S+7;h<O;){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}c>>>=S,h-=S,z=0,w=11+(c&127),c>>>=7,h-=7}if(r.have+w>r.nlen+r.ndist){e.msg="invalid bit length repeat",r.mode=Q;break}for(;w--;)r.lens[r.have++]=z}}if(r.mode===Q)break;if(r.lens[256]===0){e.msg="invalid code -- missing end-of-block",r.mode=Q;break}if(r.lenbits=9,V={bits:r.lenbits},B=Ei(Rp,r.lens,0,r.nlen,r.lencode,0,r.work,V),r.lenbits=V.bits,B){e.msg="invalid literal/lengths set",r.mode=Q;break}if(r.distbits=6,r.distcode=r.distdyn,V={bits:r.distbits},B=Ei(Tp,r.lens,r.nlen,r.ndist,r.distcode,0,r.work,V),r.distbits=V.bits,B){e.msg="invalid distances set",r.mode=Q;break}if(r.mode=eo,t===Qa)break e;case eo:r.mode=to;case to:if(d>=6&&m>=258){e.next_out=u,e.avail_out=m,e.next_in=l,e.avail_in=d,r.hold=c,r.bits=h,D0(e,y),u=e.next_out,o=e.output,m=e.avail_out,l=e.next_in,n=e.input,d=e.avail_in,c=r.hold,h=r.bits,r.mode===Ot&&(r.back=-1);break}for(r.back=0;k=r.lencode[c&(1<<r.lenbits)-1],S=k>>>24,A=k>>>16&255,C=k&65535,!(S<=h);){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}if(A&&!(A&240)){for(R=S,T=A,F=C;k=r.lencode[F+((c&(1<<R+T)-1)>>R)],S=k>>>24,A=k>>>16&255,C=k&65535,!(R+S<=h);){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}c>>>=R,h-=R,r.back+=R}if(c>>>=S,h-=S,r.back+=S,r.length=C,A===0){r.mode=yp;break}if(A&32){r.back=-1,r.mode=Ot;break}if(A&64){e.msg="invalid literal/length code",r.mode=Q;break}r.extra=A&15,r.mode=pp;case pp:if(r.extra){for(O=r.extra;h<O;){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}r.length+=c&(1<<r.extra)-1,c>>>=r.extra,h-=r.extra,r.back+=r.extra}r.was=r.length,r.mode=mp;case mp:for(;k=r.distcode[c&(1<<r.distbits)-1],S=k>>>24,A=k>>>16&255,C=k&65535,!(S<=h);){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}if(!(A&240)){for(R=S,T=A,F=C;k=r.distcode[F+((c&(1<<R+T)-1)>>R)],S=k>>>24,A=k>>>16&255,C=k&65535,!(R+S<=h);){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}c>>>=R,h-=R,r.back+=R}if(c>>>=S,h-=S,r.back+=S,A&64){e.msg="invalid distance code",r.mode=Q;break}r.offset=C,r.extra=A&15,r.mode=gp;case gp:if(r.extra){for(O=r.extra;h<O;){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}r.offset+=c&(1<<r.extra)-1,c>>>=r.extra,h-=r.extra,r.back+=r.extra}if(r.offset>r.dmax){e.msg="invalid distance too far back",r.mode=Q;break}r.mode=bp;case bp:if(m===0)break e;if(w=y-m,r.offset>w){if(w=r.offset-w,w>r.whave&&r.sane){e.msg="invalid distance too far back",r.mode=Q;break}w>r.wnext?(w-=r.wnext,v=r.wsize-w):v=r.wnext-w,w>r.length&&(w=r.length),E=r.window}else E=o,v=u-r.offset,w=r.length;w>m&&(w=m),m-=w,r.length-=w;do o[u++]=E[v++];while(--w);r.length===0&&(r.mode=to);break;case yp:if(m===0)break e;o[u++]=r.length,m--,r.mode=to;break;case Xl:if(r.wrap){for(;h<32;){if(d===0)break e;d--,c|=n[l++]<<h,h+=8}if(y-=m,e.total_out+=y,r.total+=y,y&&(e.adler=r.check=r.flags?pt(r.check,o,y,u-y):eu(r.check,o,y,u-y)),y=m,(r.flags?c:wp(c))!==r.check){e.msg="incorrect data check",r.mode=Q;break}c=0,h=0}r.mode=_p;case _p:if(r.wrap&&r.flags){for(;h<32;){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}if(c!==(r.total&4294967295)){e.msg="incorrect length check",r.mode=Q;break}c=0,h=0}r.mode=vp;case vp:B=z0;break e;case Q:B=xp;break e;case ru:return tu;case M0:default:return qe}return e.next_out=u,e.avail_out=m,e.next_in=l,e.avail_in=d,r.hold=c,r.bits=h,(r.wsize||y!==e.avail_out&&r.mode<Q&&(r.mode<Xl||t!==Jh))&&Ip(e,e.output,e.next_out,y-e.avail_out)?(r.mode=ru,tu):(x-=e.avail_in,y-=e.avail_out,e.total_in+=x,e.total_out+=y,r.total+=y,r.wrap&&y&&(e.adler=r.check=r.flags?pt(r.check,o,y,e.next_out-y):eu(r.check,o,y,e.next_out-y)),e.data_type=r.bits+(r.last?64:0)+(r.mode===Ot?128:0)+(r.mode===eo||r.mode===Kl?256:0),(x===0&&y===0||t===Jh)&&B===kr&&(B=U0),B)}a(G0,"inflate");function Y0(e){if(!e||!e.state)return qe;var t=e.state;return t.window&&(t.window=null),e.state=null,kr}a(Y0,"inflateEnd");function K0(e,t){var r;return!e||!e.state||(r=e.state,!(r.wrap&2))?qe:(r.head=t,t.done=!1,kr)}a(K0,"inflateGetHeader");function X0(e,t){var r=t.length,n,o,l;return!e||!e.state||(n=e.state,n.wrap!==0&&n.mode!==ro)?qe:n.mode===ro&&(o=1,o=eu(o,t,r,0),o!==n.check)?xp:(l=Ip(e,t,r,r),l?(n.mode=ru,tu):(n.havedict=1,kr))}a(X0,"inflateSetDictionary");Ke.inflateReset=Ep;Ke.inflateReset2=Cp;Ke.inflateResetKeep=kp;Ke.inflateInit=Z0;Ke.inflateInit2=Pp;Ke.inflate=G0;Ke.inflateEnd=Y0;Ke.inflateGetHeader=K0;Ke.inflateSetDictionary=X0;Ke.inflateInfo="pako inflate (from Nodeca project)"});var nu=P((tx,Op)=>{"use strict";Op.exports={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8}});var Bp=P((rx,Dp)=>{"use strict";function J0(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1}a(J0,"GZheader");Dp.exports=J0});var zp=P(Pi=>{"use strict";var Tn=Fp(),Ci=Pt(),no=Nl(),re=nu(),iu=Ha(),Q0=jl(),ew=Bp(),Lp=Object.prototype.toString;function Er(e){if(!(this instanceof Er))return new Er(e);this.options=Ci.assign({chunkSize:16384,windowBits:0,to:""},e||{});var t=this.options;t.raw&&t.windowBits>=0&&t.windowBits<16&&(t.windowBits=-t.windowBits,t.windowBits===0&&(t.windowBits=-15)),t.windowBits>=0&&t.windowBits<16&&!(e&&e.windowBits)&&(t.windowBits+=32),t.windowBits>15&&t.windowBits<48&&(t.windowBits&15||(t.windowBits|=15)),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new Q0,this.strm.avail_out=0;var r=Tn.inflateInit2(this.strm,t.windowBits);if(r!==re.Z_OK)throw new Error(iu[r]);if(this.header=new ew,Tn.inflateGetHeader(this.strm,this.header),t.dictionary&&(typeof t.dictionary=="string"?t.dictionary=no.string2buf(t.dictionary):Lp.call(t.dictionary)==="[object ArrayBuffer]"&&(t.dictionary=new Uint8Array(t.dictionary)),t.raw&&(r=Tn.inflateSetDictionary(this.strm,t.dictionary),r!==re.Z_OK)))throw new Error(iu[r])}a(Er,"Inflate");Er.prototype.push=function(e,t){var r=this.strm,n=this.options.chunkSize,o=this.options.dictionary,l,u,d,m,c,h=!1;if(this.ended)return!1;u=t===~~t?t:t===!0?re.Z_FINISH:re.Z_NO_FLUSH,typeof e=="string"?r.input=no.binstring2buf(e):Lp.call(e)==="[object ArrayBuffer]"?r.input=new Uint8Array(e):r.input=e,r.next_in=0,r.avail_in=r.input.length;do{if(r.avail_out===0&&(r.output=new Ci.Buf8(n),r.next_out=0,r.avail_out=n),l=Tn.inflate(r,re.Z_NO_FLUSH),l===re.Z_NEED_DICT&&o&&(l=Tn.inflateSetDictionary(this.strm,o)),l===re.Z_BUF_ERROR&&h===!0&&(l=re.Z_OK,h=!1),l!==re.Z_STREAM_END&&l!==re.Z_OK)return this.onEnd(l),this.ended=!0,!1;r.next_out&&(r.avail_out===0||l===re.Z_STREAM_END||r.avail_in===0&&(u===re.Z_FINISH||u===re.Z_SYNC_FLUSH))&&(this.options.to==="string"?(d=no.utf8border(r.output,r.next_out),m=r.next_out-d,c=no.buf2string(r.output,d),r.next_out=m,r.avail_out=n-m,m&&Ci.arraySet(r.output,r.output,d,m,0),this.onData(c)):this.onData(Ci.shrinkBuf(r.output,r.next_out))),r.avail_in===0&&r.avail_out===0&&(h=!0)}while((r.avail_in>0||r.avail_out===0)&&l!==re.Z_STREAM_END);return l===re.Z_STREAM_END&&(u=re.Z_FINISH),u===re.Z_FINISH?(l=Tn.inflateEnd(this.strm),this.onEnd(l),this.ended=!0,l===re.Z_OK):(u===re.Z_SYNC_FLUSH&&(this.onEnd(re.Z_OK),r.avail_out=0),!0)};Er.prototype.onData=function(e){this.chunks.push(e)};Er.prototype.onEnd=function(e){e===re.Z_OK&&(this.options.to==="string"?this.result=this.chunks.join(""):this.result=Ci.flattenChunks(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg};function au(e,t){var r=new Er(t);if(r.push(e,!0),r.err)throw r.msg||iu[r.err];return r.result}a(au,"inflate");function tw(e,t){return t=t||{},t.raw=!0,au(e,t)}a(tw,"inflateRaw");Pi.Inflate=Er;Pi.inflate=au;Pi.inflateRaw=tw;Pi.ungzip=au});var Mp=P((ox,Up)=>{"use strict";var rw=Pt().assign,nw=Nh(),iw=zp(),aw=nu(),qp={};rw(qp,nw,iw,aw);Up.exports=qp});var Np=P(ao=>{"use strict";var ow=typeof Uint8Array<"u"&&typeof Uint16Array<"u"&&typeof Uint32Array<"u",sw=Mp(),Wp=ee(),io=ke(),lw=ow?"uint8array":"array";ao.magic="\b\0";function Cr(e,t){io.call(this,"FlateWorker/"+e),this._pako=null,this._pakoAction=e,this._pakoOptions=t,this.meta={}}a(Cr,"FlateWorker");Wp.inherits(Cr,io);Cr.prototype.processChunk=function(e){this.meta=e.meta,this._pako===null&&this._createPako(),this._pako.push(Wp.transformTo(lw,e.data),!1)};Cr.prototype.flush=function(){io.prototype.flush.call(this),this._pako===null&&this._createPako(),this._pako.push([],!0)};Cr.prototype.cleanUp=function(){io.prototype.cleanUp.call(this),this._pako=null};Cr.prototype._createPako=function(){this._pako=new sw[this._pakoAction]({raw:!0,level:this._pakoOptions.level||-1});var e=this;this._pako.onData=function(t){e.push({data:t,meta:e.meta})}};ao.compressWorker=function(e){return new Cr("Deflate",e)};ao.uncompressWorker=function(){return new Cr("Inflate",{})}});var su=P(ou=>{"use strict";var jp=ke();ou.STORE={magic:"\0\0",compressWorker:a(function(){return new jp("STORE compression")},"compressWorker"),uncompressWorker:a(function(){return new jp("STORE decompression")},"uncompressWorker")};ou.DEFLATE=Np()});var lu=P(Pr=>{"use strict";Pr.LOCAL_FILE_HEADER="PK";Pr.CENTRAL_FILE_HEADER="PK";Pr.CENTRAL_DIRECTORY_END="PK";Pr.ZIP64_CENTRAL_DIRECTORY_LOCATOR="PK\x07";Pr.ZIP64_CENTRAL_DIRECTORY_END="PK";Pr.DATA_DESCRIPTOR="PK\x07\b"});var Vp=P((dx,Zp)=>{"use strict";var xn=ee(),An=ke(),uu=hn(),Hp=Ua(),oo=lu(),X=a(function(e,t){var r="",n;for(n=0;n<t;n++)r+=String.fromCharCode(e&255),e=e>>>8;return r},"decToHex"),uw=a(function(e,t){var r=e;return e||(r=t?16893:33204),(r&65535)<<16},"generateUnixExternalFileAttr"),fw=a(function(e){return(e||0)&63},"generateDosExternalFileAttr"),$p=a(function(e,t,r,n,o,l){var u=e.file,d=e.compression,m=l!==uu.utf8encode,c=xn.transformTo("string",l(u.name)),h=xn.transformTo("string",uu.utf8encode(u.name)),x=u.comment,y=xn.transformTo("string",l(x)),w=xn.transformTo("string",uu.utf8encode(x)),v=h.length!==u.name.length,E=w.length!==x.length,k,S,A="",C="",R="",T=u.dir,F=u.date,z={crc32:0,compressedSize:0,uncompressedSize:0};(!t||r)&&(z.crc32=e.crc32,z.compressedSize=e.compressedSize,z.uncompressedSize=e.uncompressedSize);var B=0;t&&(B|=8),!m&&(v||E)&&(B|=2048);var M=0,V=0;T&&(M|=16),o==="UNIX"?(V=798,M|=uw(u.unixPermissions,T)):(V=20,M|=fw(u.dosPermissions,T)),k=F.getUTCHours(),k=k<<6,k=k|F.getUTCMinutes(),k=k<<5,k=k|F.getUTCSeconds()/2,S=F.getUTCFullYear()-1980,S=S<<4,S=S|F.getUTCMonth()+1,S=S<<5,S=S|F.getUTCDate(),v&&(C=X(1,1)+X(Hp(c),4)+h,A+="up"+X(C.length,2)+C),E&&(R=X(1,1)+X(Hp(y),4)+w,A+="uc"+X(R.length,2)+R);var O="";O+=`
|
|
13
|
-
\0`,O+=X(B,2),O+=d.magic,O+=X(k,2),O+=X(S,2),O+=X(z.crc32,4),O+=X(z.compressedSize,4),O+=X(z.uncompressedSize,4),O+=X(c.length,2),O+=X(A.length,2);var le=oo.LOCAL_FILE_HEADER+O+c+A,ce=oo.CENTRAL_FILE_HEADER+X(V,2)+O+X(y.length,2)+"\0\0\0\0"+X(M,4)+X(n,4)+c+A+y;return{fileRecord:le,dirRecord:ce}},"generateZipParts"),cw=a(function(e,t,r,n,o){var l="",u=xn.transformTo("string",o(n));return l=oo.CENTRAL_DIRECTORY_END+"\0\0\0\0"+X(e,2)+X(e,2)+X(t,4)+X(r,4)+X(u.length,2)+u,l},"generateCentralDirectoryEnd"),dw=a(function(e){var t="";return t=oo.DATA_DESCRIPTOR+X(e.crc32,4)+X(e.compressedSize,4)+X(e.uncompressedSize,4),t},"generateDataDescriptors");function Xe(e,t,r,n){An.call(this,"ZipFileWorker"),this.bytesWritten=0,this.zipComment=t,this.zipPlatform=r,this.encodeFileName=n,this.streamFiles=e,this.accumulate=!1,this.contentBuffer=[],this.dirRecords=[],this.currentSourceOffset=0,this.entriesCount=0,this.currentFile=null,this._sources=[]}a(Xe,"ZipFileWorker");xn.inherits(Xe,An);Xe.prototype.push=function(e){var t=e.meta.percent||0,r=this.entriesCount,n=this._sources.length;this.accumulate?this.contentBuffer.push(e):(this.bytesWritten+=e.data.length,An.prototype.push.call(this,{data:e.data,meta:{currentFile:this.currentFile,percent:r?(t+100*(r-n-1))/r:100}}))};Xe.prototype.openedSource=function(e){this.currentSourceOffset=this.bytesWritten,this.currentFile=e.file.name;var t=this.streamFiles&&!e.file.dir;if(t){var r=$p(e,t,!1,this.currentSourceOffset,this.zipPlatform,this.encodeFileName);this.push({data:r.fileRecord,meta:{percent:0}})}else this.accumulate=!0};Xe.prototype.closedSource=function(e){this.accumulate=!1;var t=this.streamFiles&&!e.file.dir,r=$p(e,t,!0,this.currentSourceOffset,this.zipPlatform,this.encodeFileName);if(this.dirRecords.push(r.dirRecord),t)this.push({data:dw(e),meta:{percent:100}});else for(this.push({data:r.fileRecord,meta:{percent:0}});this.contentBuffer.length;)this.push(this.contentBuffer.shift());this.currentFile=null};Xe.prototype.flush=function(){for(var e=this.bytesWritten,t=0;t<this.dirRecords.length;t++)this.push({data:this.dirRecords[t],meta:{percent:100}});var r=this.bytesWritten-e,n=cw(this.dirRecords.length,r,e,this.zipComment,this.encodeFileName);this.push({data:n,meta:{percent:100}})};Xe.prototype.prepareNextSource=function(){this.previous=this._sources.shift(),this.openedSource(this.previous.streamInfo),this.isPaused?this.previous.pause():this.previous.resume()};Xe.prototype.registerPrevious=function(e){this._sources.push(e);var t=this;return e.on("data",function(r){t.processChunk(r)}),e.on("end",function(){t.closedSource(t.previous.streamInfo),t._sources.length?t.prepareNextSource():t.end()}),e.on("error",function(r){t.error(r)}),this};Xe.prototype.resume=function(){if(!An.prototype.resume.call(this))return!1;if(!this.previous&&this._sources.length)return this.prepareNextSource(),!0;if(!this.previous&&!this._sources.length&&!this.generatedError)return this.end(),!0};Xe.prototype.error=function(e){var t=this._sources;if(!An.prototype.error.call(this,e))return!1;for(var r=0;r<t.length;r++)try{t[r].error(e)}catch{}return!0};Xe.prototype.lock=function(){An.prototype.lock.call(this);for(var e=this._sources,t=0;t<e.length;t++)e[t].lock()};Zp.exports=Xe});var Yp=P(Gp=>{"use strict";var hw=su(),pw=Vp(),mw=a(function(e,t){var r=e||t,n=hw[r];if(!n)throw new Error(r+" is not a valid compression method !");return n},"getCompression");Gp.generateWorker=function(e,t,r){var n=new pw(t.streamFiles,r,t.platform,t.encodeFileName),o=0;try{e.forEach(function(l,u){o++;var d=mw(u.options.compression,t.compression),m=u.options.compressionOptions||t.compressionOptions||{},c=u.dir,h=u.date;u._compressWorker(d,m).withStreamInfo("file",{name:l,dir:c,date:h,comment:u.comment||"",unixPermissions:u.unixPermissions,dosPermissions:u.dosPermissions}).pipe(n)}),n.entriesCount=o}catch(l){n.error(l)}return n}});var Xp=P((gx,Kp)=>{"use strict";var gw=ee(),so=ke();function Ii(e,t){so.call(this,"Nodejs stream input adapter for "+e),this._upstreamEnded=!1,this._bindStream(t)}a(Ii,"NodejsStreamInputAdapter");gw.inherits(Ii,so);Ii.prototype._bindStream=function(e){var t=this;this._stream=e,e.pause(),e.on("data",function(r){t.push({data:r,meta:{percent:0}})}).on("error",function(r){t.isPaused?this.generatedError=r:t.error(r)}).on("end",function(){t.isPaused?t._upstreamEnded=!0:t.end()})};Ii.prototype.pause=function(){return so.prototype.pause.call(this)?(this._stream.pause(),!0):!1};Ii.prototype.resume=function(){return so.prototype.resume.call(this)?(this._upstreamEnded?this.end():this._stream.resume(),!0):!1};Kp.exports=Ii});var sm=P((yx,om)=>{"use strict";var bw=hn(),Fi=ee(),tm=ke(),yw=pl(),rm=ml(),Jp=Ma(),_w=Qd(),vw=Yp(),Qp=si(),ww=Xp(),nm=a(function(e,t,r){var n=Fi.getTypeOf(t),o,l=Fi.extend(r||{},rm);l.date=l.date||new Date,l.compression!==null&&(l.compression=l.compression.toUpperCase()),typeof l.unixPermissions=="string"&&(l.unixPermissions=parseInt(l.unixPermissions,8)),l.unixPermissions&&l.unixPermissions&16384&&(l.dir=!0),l.dosPermissions&&l.dosPermissions&16&&(l.dir=!0),l.dir&&(e=im(e)),l.createFolders&&(o=Sw(e))&&am.call(this,o,!0);var u=n==="string"&&l.binary===!1&&l.base64===!1;(!r||typeof r.binary>"u")&&(l.binary=!u);var d=t instanceof Jp&&t.uncompressedSize===0;(d||l.dir||!t||t.length===0)&&(l.base64=!1,l.binary=!0,t="",l.compression="STORE",n="string");var m=null;t instanceof Jp||t instanceof tm?m=t:Qp.isNode&&Qp.isStream(t)?m=new ww(e,t):m=Fi.prepareContent(e,t,l.binary,l.optimizedBinaryString,l.base64);var c=new _w(e,m,l);this.files[e]=c},"fileAdd"),Sw=a(function(e){e.slice(-1)==="/"&&(e=e.substring(0,e.length-1));var t=e.lastIndexOf("/");return t>0?e.substring(0,t):""},"parentFolder"),im=a(function(e){return e.slice(-1)!=="/"&&(e+="/"),e},"forceTrailingSlash"),am=a(function(e,t){return t=typeof t<"u"?t:rm.createFolders,e=im(e),this.files[e]||nm.call(this,e,null,{dir:!0,createFolders:t}),this.files[e]},"folderAdd");function em(e){return Object.prototype.toString.call(e)==="[object RegExp]"}a(em,"isRegExp");var Rw={load:a(function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},"load"),forEach:a(function(e){var t,r,n;for(t in this.files)n=this.files[t],r=t.slice(this.root.length,t.length),r&&t.slice(0,this.root.length)===this.root&&e(r,n)},"forEach"),filter:a(function(e){var t=[];return this.forEach(function(r,n){e(r,n)&&t.push(n)}),t},"filter"),file:a(function(e,t,r){if(arguments.length===1)if(em(e)){var n=e;return this.filter(function(l,u){return!u.dir&&n.test(l)})}else{var o=this.files[this.root+e];return o&&!o.dir?o:null}else e=this.root+e,nm.call(this,e,t,r);return this},"file"),folder:a(function(e){if(!e)return this;if(em(e))return this.filter(function(o,l){return l.dir&&e.test(o)});var t=this.root+e,r=am.call(this,t),n=this.clone();return n.root=r.name,n},"folder"),remove:a(function(e){e=this.root+e;var t=this.files[e];if(t||(e.slice(-1)!=="/"&&(e+="/"),t=this.files[e]),t&&!t.dir)delete this.files[e];else for(var r=this.filter(function(o,l){return l.name.slice(0,e.length)===e}),n=0;n<r.length;n++)delete this.files[r[n].name];return this},"remove"),generate:a(function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},"generate"),generateInternalStream:a(function(e){var t,r={};try{if(r=Fi.extend(e||{},{streamFiles:!1,compression:"STORE",compressionOptions:null,type:"",platform:"DOS",comment:null,mimeType:"application/zip",encodeFileName:bw.utf8encode}),r.type=r.type.toLowerCase(),r.compression=r.compression.toUpperCase(),r.type==="binarystring"&&(r.type="string"),!r.type)throw new Error("No output type specified.");Fi.checkSupport(r.type),(r.platform==="darwin"||r.platform==="freebsd"||r.platform==="linux"||r.platform==="sunos")&&(r.platform="UNIX"),r.platform==="win32"&&(r.platform="DOS");var n=r.comment||this.comment||"";t=vw.generateWorker(this,r,n)}catch(o){t=new tm("error"),t.error(o)}return new yw(t,r.type||"string",r.mimeType)},"generateInternalStream"),generateAsync:a(function(e,t){return this.generateInternalStream(e).accumulate(t)},"generateAsync"),generateNodeStream:a(function(e,t){return e=e||{},e.type||(e.type="nodebuffer"),this.generateInternalStream(e).toNodejsStream(t)},"generateNodeStream")};om.exports=Rw});var fu=P((vx,um)=>{"use strict";var Tw=ee();function lm(e){this.data=e,this.length=e.length,this.index=0,this.zero=0}a(lm,"DataReader");lm.prototype={checkOffset:a(function(e){this.checkIndex(this.index+e)},"checkOffset"),checkIndex:a(function(e){if(this.length<this.zero+e||e<0)throw new Error("End of data reached (data length = "+this.length+", asked index = "+e+"). Corrupted zip ?")},"checkIndex"),setIndex:a(function(e){this.checkIndex(e),this.index=e},"setIndex"),skip:a(function(e){this.setIndex(this.index+e)},"skip"),byteAt:a(function(){},"byteAt"),readInt:a(function(e){var t=0,r;for(this.checkOffset(e),r=this.index+e-1;r>=this.index;r--)t=(t<<8)+this.byteAt(r);return this.index+=e,t},"readInt"),readString:a(function(e){return Tw.transformTo("string",this.readData(e))},"readString"),readData:a(function(){},"readData"),lastIndexOfSignature:a(function(){},"lastIndexOfSignature"),readAndCheckSignature:a(function(){},"readAndCheckSignature"),readDate:a(function(){var e=this.readInt(4);return new Date(Date.UTC((e>>25&127)+1980,(e>>21&15)-1,e>>16&31,e>>11&31,e>>5&63,(e&31)<<1))},"readDate")};um.exports=lm});var cu=P((Sx,cm)=>{"use strict";var fm=fu(),xw=ee();function kn(e){fm.call(this,e);for(var t=0;t<this.data.length;t++)e[t]=e[t]&255}a(kn,"ArrayReader");xw.inherits(kn,fm);kn.prototype.byteAt=function(e){return this.data[this.zero+e]};kn.prototype.lastIndexOfSignature=function(e){for(var t=e.charCodeAt(0),r=e.charCodeAt(1),n=e.charCodeAt(2),o=e.charCodeAt(3),l=this.length-4;l>=0;--l)if(this.data[l]===t&&this.data[l+1]===r&&this.data[l+2]===n&&this.data[l+3]===o)return l-this.zero;return-1};kn.prototype.readAndCheckSignature=function(e){var t=e.charCodeAt(0),r=e.charCodeAt(1),n=e.charCodeAt(2),o=e.charCodeAt(3),l=this.readData(4);return t===l[0]&&r===l[1]&&n===l[2]&&o===l[3]};kn.prototype.readData=function(e){if(this.checkOffset(e),e===0)return[];var t=this.data.slice(this.zero+this.index,this.zero+this.index+e);return this.index+=e,t};cm.exports=kn});var pm=P((Tx,hm)=>{"use strict";var dm=fu(),Aw=ee();function En(e){dm.call(this,e)}a(En,"StringReader");Aw.inherits(En,dm);En.prototype.byteAt=function(e){return this.data.charCodeAt(this.zero+e)};En.prototype.lastIndexOfSignature=function(e){return this.data.lastIndexOf(e)-this.zero};En.prototype.readAndCheckSignature=function(e){var t=this.readData(4);return e===t};En.prototype.readData=function(e){this.checkOffset(e);var t=this.data.slice(this.zero+this.index,this.zero+this.index+e);return this.index+=e,t};hm.exports=En});var hu=P((Ax,gm)=>{"use strict";var mm=cu(),kw=ee();function du(e){mm.call(this,e)}a(du,"Uint8ArrayReader");kw.inherits(du,mm);du.prototype.readData=function(e){if(this.checkOffset(e),e===0)return new Uint8Array(0);var t=this.data.subarray(this.zero+this.index,this.zero+this.index+e);return this.index+=e,t};gm.exports=du});var _m=P((Ex,ym)=>{"use strict";var bm=hu(),Ew=ee();function pu(e){bm.call(this,e)}a(pu,"NodeBufferReader");Ew.inherits(pu,bm);pu.prototype.readData=function(e){this.checkOffset(e);var t=this.data.slice(this.zero+this.index,this.zero+this.index+e);return this.index+=e,t};ym.exports=pu});var mu=P((Px,wm)=>{"use strict";var lo=ee(),vm=Et(),Cw=cu(),Pw=pm(),Iw=_m(),Fw=hu();wm.exports=function(e){var t=lo.getTypeOf(e);return lo.checkSupport(t),t==="string"&&!vm.uint8array?new Pw(e):t==="nodebuffer"?new Iw(e):vm.uint8array?new Fw(lo.transformTo("uint8array",e)):new Cw(lo.transformTo("array",e))}});var xm=P((Ix,Tm)=>{"use strict";var gu=mu(),tr=ee(),Ow=Ma(),Sm=Ua(),uo=hn(),fo=su(),Dw=Et(),Bw=0,Lw=3,zw=a(function(e){for(var t in fo)if(Object.prototype.hasOwnProperty.call(fo,t)&&fo[t].magic===e)return fo[t];return null},"findCompression");function Rm(e,t){this.options=e,this.loadOptions=t}a(Rm,"ZipEntry");Rm.prototype={isEncrypted:a(function(){return(this.bitFlag&1)===1},"isEncrypted"),useUTF8:a(function(){return(this.bitFlag&2048)===2048},"useUTF8"),readLocalPart:a(function(e){var t,r;if(e.skip(22),this.fileNameLength=e.readInt(2),r=e.readInt(2),this.fileName=e.readData(this.fileNameLength),e.skip(r),this.compressedSize===-1||this.uncompressedSize===-1)throw new Error("Bug or corrupted zip : didn't get enough information from the central directory (compressedSize === -1 || uncompressedSize === -1)");if(t=zw(this.compressionMethod),t===null)throw new Error("Corrupted zip : compression "+tr.pretty(this.compressionMethod)+" unknown (inner file : "+tr.transformTo("string",this.fileName)+")");this.decompressed=new Ow(this.compressedSize,this.uncompressedSize,this.crc32,t,e.readData(this.compressedSize))},"readLocalPart"),readCentralPart:a(function(e){this.versionMadeBy=e.readInt(2),e.skip(2),this.bitFlag=e.readInt(2),this.compressionMethod=e.readString(2),this.date=e.readDate(),this.crc32=e.readInt(4),this.compressedSize=e.readInt(4),this.uncompressedSize=e.readInt(4);var t=e.readInt(2);if(this.extraFieldsLength=e.readInt(2),this.fileCommentLength=e.readInt(2),this.diskNumberStart=e.readInt(2),this.internalFileAttributes=e.readInt(2),this.externalFileAttributes=e.readInt(4),this.localHeaderOffset=e.readInt(4),this.isEncrypted())throw new Error("Encrypted zip are not supported");e.skip(t),this.readExtraFields(e),this.parseZIP64ExtraField(e),this.fileComment=e.readData(this.fileCommentLength)},"readCentralPart"),processAttributes:a(function(){this.unixPermissions=null,this.dosPermissions=null;var e=this.versionMadeBy>>8;this.dir=!!(this.externalFileAttributes&16),e===Bw&&(this.dosPermissions=this.externalFileAttributes&63),e===Lw&&(this.unixPermissions=this.externalFileAttributes>>16&65535),!this.dir&&this.fileNameStr.slice(-1)==="/"&&(this.dir=!0)},"processAttributes"),parseZIP64ExtraField:a(function(){if(this.extraFields[1]){var e=gu(this.extraFields[1].value);this.uncompressedSize===tr.MAX_VALUE_32BITS&&(this.uncompressedSize=e.readInt(8)),this.compressedSize===tr.MAX_VALUE_32BITS&&(this.compressedSize=e.readInt(8)),this.localHeaderOffset===tr.MAX_VALUE_32BITS&&(this.localHeaderOffset=e.readInt(8)),this.diskNumberStart===tr.MAX_VALUE_32BITS&&(this.diskNumberStart=e.readInt(4))}},"parseZIP64ExtraField"),readExtraFields:a(function(e){var t=e.index+this.extraFieldsLength,r,n,o;for(this.extraFields||(this.extraFields={});e.index+4<t;)r=e.readInt(2),n=e.readInt(2),o=e.readData(n),this.extraFields[r]={id:r,length:n,value:o};e.setIndex(t)},"readExtraFields"),handleUTF8:a(function(){var e=Dw.uint8array?"uint8array":"array";if(this.useUTF8())this.fileNameStr=uo.utf8decode(this.fileName),this.fileCommentStr=uo.utf8decode(this.fileComment);else{var t=this.findExtraFieldUnicodePath();if(t!==null)this.fileNameStr=t;else{var r=tr.transformTo(e,this.fileName);this.fileNameStr=this.loadOptions.decodeFileName(r)}var n=this.findExtraFieldUnicodeComment();if(n!==null)this.fileCommentStr=n;else{var o=tr.transformTo(e,this.fileComment);this.fileCommentStr=this.loadOptions.decodeFileName(o)}}},"handleUTF8"),findExtraFieldUnicodePath:a(function(){var e=this.extraFields[28789];if(e){var t=gu(e.value);return t.readInt(1)!==1||Sm(this.fileName)!==t.readInt(4)?null:uo.utf8decode(t.readData(e.length-5))}return null},"findExtraFieldUnicodePath"),findExtraFieldUnicodeComment:a(function(){var e=this.extraFields[25461];if(e){var t=gu(e.value);return t.readInt(1)!==1||Sm(this.fileComment)!==t.readInt(4)?null:uo.utf8decode(t.readData(e.length-5))}return null},"findExtraFieldUnicodeComment")};Tm.exports=Rm});var Em=P((Ox,km)=>{"use strict";var qw=mu(),Dt=ee(),Je=lu(),Uw=xm(),Mw=Et();function Am(e){this.files=[],this.loadOptions=e}a(Am,"ZipEntries");Am.prototype={checkSignature:a(function(e){if(!this.reader.readAndCheckSignature(e)){this.reader.index-=4;var t=this.reader.readString(4);throw new Error("Corrupted zip or bug: unexpected signature ("+Dt.pretty(t)+", expected "+Dt.pretty(e)+")")}},"checkSignature"),isSignature:a(function(e,t){var r=this.reader.index;this.reader.setIndex(e);var n=this.reader.readString(4),o=n===t;return this.reader.setIndex(r),o},"isSignature"),readBlockEndOfCentral:a(function(){this.diskNumber=this.reader.readInt(2),this.diskWithCentralDirStart=this.reader.readInt(2),this.centralDirRecordsOnThisDisk=this.reader.readInt(2),this.centralDirRecords=this.reader.readInt(2),this.centralDirSize=this.reader.readInt(4),this.centralDirOffset=this.reader.readInt(4),this.zipCommentLength=this.reader.readInt(2);var e=this.reader.readData(this.zipCommentLength),t=Mw.uint8array?"uint8array":"array",r=Dt.transformTo(t,e);this.zipComment=this.loadOptions.decodeFileName(r)},"readBlockEndOfCentral"),readBlockZip64EndOfCentral:a(function(){this.zip64EndOfCentralSize=this.reader.readInt(8),this.reader.skip(4),this.diskNumber=this.reader.readInt(4),this.diskWithCentralDirStart=this.reader.readInt(4),this.centralDirRecordsOnThisDisk=this.reader.readInt(8),this.centralDirRecords=this.reader.readInt(8),this.centralDirSize=this.reader.readInt(8),this.centralDirOffset=this.reader.readInt(8),this.zip64ExtensibleData={};for(var e=this.zip64EndOfCentralSize-44,t=0,r,n,o;t<e;)r=this.reader.readInt(2),n=this.reader.readInt(4),o=this.reader.readData(n),this.zip64ExtensibleData[r]={id:r,length:n,value:o}},"readBlockZip64EndOfCentral"),readBlockZip64EndOfCentralLocator:a(function(){if(this.diskWithZip64CentralDirStart=this.reader.readInt(4),this.relativeOffsetEndOfZip64CentralDir=this.reader.readInt(8),this.disksCount=this.reader.readInt(4),this.disksCount>1)throw new Error("Multi-volumes zip are not supported")},"readBlockZip64EndOfCentralLocator"),readLocalFiles:a(function(){var e,t;for(e=0;e<this.files.length;e++)t=this.files[e],this.reader.setIndex(t.localHeaderOffset),this.checkSignature(Je.LOCAL_FILE_HEADER),t.readLocalPart(this.reader),t.handleUTF8(),t.processAttributes()},"readLocalFiles"),readCentralDir:a(function(){var e;for(this.reader.setIndex(this.centralDirOffset);this.reader.readAndCheckSignature(Je.CENTRAL_FILE_HEADER);)e=new Uw({zip64:this.zip64},this.loadOptions),e.readCentralPart(this.reader),this.files.push(e);if(this.centralDirRecords!==this.files.length&&this.centralDirRecords!==0&&this.files.length===0)throw new Error("Corrupted zip or bug: expected "+this.centralDirRecords+" records in central dir, got "+this.files.length)},"readCentralDir"),readEndOfCentral:a(function(){var e=this.reader.lastIndexOfSignature(Je.CENTRAL_DIRECTORY_END);if(e<0){var t=!this.isSignature(0,Je.LOCAL_FILE_HEADER);throw t?new Error("Can't find end of central directory : is this a zip file ? If it is, see https://stuk.github.io/jszip/documentation/howto/read_zip.html"):new Error("Corrupted zip: can't find end of central directory")}this.reader.setIndex(e);var r=e;if(this.checkSignature(Je.CENTRAL_DIRECTORY_END),this.readBlockEndOfCentral(),this.diskNumber===Dt.MAX_VALUE_16BITS||this.diskWithCentralDirStart===Dt.MAX_VALUE_16BITS||this.centralDirRecordsOnThisDisk===Dt.MAX_VALUE_16BITS||this.centralDirRecords===Dt.MAX_VALUE_16BITS||this.centralDirSize===Dt.MAX_VALUE_32BITS||this.centralDirOffset===Dt.MAX_VALUE_32BITS){if(this.zip64=!0,e=this.reader.lastIndexOfSignature(Je.ZIP64_CENTRAL_DIRECTORY_LOCATOR),e<0)throw new Error("Corrupted zip: can't find the ZIP64 end of central directory locator");if(this.reader.setIndex(e),this.checkSignature(Je.ZIP64_CENTRAL_DIRECTORY_LOCATOR),this.readBlockZip64EndOfCentralLocator(),!this.isSignature(this.relativeOffsetEndOfZip64CentralDir,Je.ZIP64_CENTRAL_DIRECTORY_END)&&(this.relativeOffsetEndOfZip64CentralDir=this.reader.lastIndexOfSignature(Je.ZIP64_CENTRAL_DIRECTORY_END),this.relativeOffsetEndOfZip64CentralDir<0))throw new Error("Corrupted zip: can't find the ZIP64 end of central directory");this.reader.setIndex(this.relativeOffsetEndOfZip64CentralDir),this.checkSignature(Je.ZIP64_CENTRAL_DIRECTORY_END),this.readBlockZip64EndOfCentral()}var n=this.centralDirOffset+this.centralDirSize;this.zip64&&(n+=20,n+=12+this.zip64EndOfCentralSize);var o=r-n;if(o>0)this.isSignature(r,Je.CENTRAL_FILE_HEADER)||(this.reader.zero=o);else if(o<0)throw new Error("Corrupted zip: missing "+Math.abs(o)+" bytes.")},"readEndOfCentral"),prepareReader:a(function(e){this.reader=qw(e)},"prepareReader"),load:a(function(e){this.prepareReader(e),this.readEndOfCentral(),this.readCentralDir(),this.readLocalFiles()},"load")};km.exports=Am});var Im=P((Bx,Pm)=>{"use strict";var bu=ee(),co=fn(),Ww=hn(),Nw=Em(),jw=yl(),Cm=si();function Hw(e){return new co.Promise(function(t,r){var n=e.decompressed.getContentWorker().pipe(new jw);n.on("error",function(o){r(o)}).on("end",function(){n.streamInfo.crc32!==e.decompressed.crc32?r(new Error("Corrupted zip : CRC32 mismatch")):t()}).resume()})}a(Hw,"checkEntryCRC32");Pm.exports=function(e,t){var r=this;return t=bu.extend(t||{},{base64:!1,checkCRC32:!1,optimizedBinaryString:!1,createFolders:!1,decodeFileName:Ww.utf8decode}),Cm.isNode&&Cm.isStream(e)?co.Promise.reject(new Error("JSZip can't accept a stream when loading a zip file.")):bu.prepareContent("the loaded zip file",e,!0,t.optimizedBinaryString,t.base64).then(function(n){var o=new Nw(t);return o.load(n),o}).then(a(function(o){var l=[co.Promise.resolve(o)],u=o.files;if(t.checkCRC32)for(var d=0;d<u.length;d++)l.push(Hw(u[d]));return co.Promise.all(l)},"checkCRC32")).then(a(function(o){for(var l=o.shift(),u=l.files,d=0;d<u.length;d++){var m=u[d],c=m.fileNameStr,h=bu.resolve(m.fileNameStr);r.file(h,m.decompressed,{binary:!0,optimizedBinaryString:!0,date:m.date,dir:m.dir,comment:m.fileCommentStr.length?m.fileCommentStr:null,unixPermissions:m.unixPermissions,dosPermissions:m.dosPermissions,createFolders:t.createFolders}),m.dir||(r.file(h).unsafeOriginalName=c)}return l.zipComment.length&&(r.comment=l.zipComment),r},"addFiles"))}});var ho=P((zx,Fm)=>{"use strict";function Ue(){if(!(this instanceof Ue))return new Ue;if(arguments.length)throw new Error("The constructor with parameters has been removed in JSZip 3.0, please check the upgrade guide.");this.files=Object.create(null),this.comment=null,this.root="",this.clone=function(){var e=new Ue;for(var t in this)typeof this[t]!="function"&&(e[t]=this[t]);return e}}a(Ue,"JSZip");Ue.prototype=sm();Ue.prototype.loadAsync=Im();Ue.support=Et();Ue.defaults=ml();Ue.version="3.10.1";Ue.loadAsync=function(e,t){return new Ue().loadAsync(e,t)};Ue.external=fn();Fm.exports=Ue});var Gw={};Mf(Gw,{TestRunMonitor:()=>yo});module.exports=jb(Gw);var $m=Fe(require("net")),nr=require("fs");var vc=Fe(require("http"),1),wc=Fe(require("https"),1),gr=Fe(require("zlib"),1),xe=Fe(require("stream"),1),Xn=require("buffer");function Hb(e){if(!/^data:/i.test(e))throw new TypeError('`uri` does not appear to be a Data URI (must begin with "data:")');e=e.replace(/\r?\n/g,"");let t=e.indexOf(",");if(t===-1||t<=4)throw new TypeError("malformed data: URI");let r=e.substring(5,t).split(";"),n="",o=!1,l=r[0]||"text/plain",u=l;for(let h=1;h<r.length;h++)r[h]==="base64"?o=!0:r[h]&&(u+=`;${r[h]}`,r[h].indexOf("charset=")===0&&(n=r[h].substring(8)));!r[0]&&!n.length&&(u+=";charset=US-ASCII",n="US-ASCII");let d=o?"base64":"ascii",m=unescape(e.substring(t+1)),c=Buffer.from(m,d);return c.type=l,c.typeFull=u,c.charset=n,c}a(Hb,"dataUriToBuffer");var jf=Hb;var De=Fe(require("stream"),1),Tt=require("util"),Re=require("buffer");jn();ua();var ys=class ys extends Error{constructor(t,r){super(t),Error.captureStackTrace(this,this.constructor),this.type=r}get name(){return this.constructor.name}get[Symbol.toStringTag](){return this.constructor.name}};a(ys,"FetchBaseError");var Rt=ys;var _s=class _s extends Rt{constructor(t,r,n){super(t,r),n&&(this.code=this.errno=n.code,this.erroredSysCall=n.syscall)}};a(_s,"FetchError");var ye=_s;var fa=Symbol.toStringTag,vs=a(e=>typeof e=="object"&&typeof e.append=="function"&&typeof e.delete=="function"&&typeof e.get=="function"&&typeof e.getAll=="function"&&typeof e.has=="function"&&typeof e.set=="function"&&typeof e.sort=="function"&&e[fa]==="URLSearchParams","isURLSearchParameters"),Vn=a(e=>e&&typeof e=="object"&&typeof e.arrayBuffer=="function"&&typeof e.type=="string"&&typeof e.stream=="function"&&typeof e.constructor=="function"&&/^(Blob|File)$/.test(e[fa]),"isBlob"),Jf=a(e=>typeof e=="object"&&(e[fa]==="AbortSignal"||e[fa]==="EventTarget"),"isAbortSignal"),Qf=a((e,t)=>{let r=new URL(t).hostname,n=new URL(e).hostname;return r===n||r.endsWith(`.${n}`)},"isDomainOrSubdomain"),ec=a((e,t)=>{let r=new URL(t).protocol,n=new URL(e).protocol;return r===n},"isSameProtocol");var ay=(0,Tt.promisify)(De.default.pipeline),_e=Symbol("Body internals"),xs=class xs{constructor(t,{size:r=0}={}){let n=null;t===null?t=null:vs(t)?t=Re.Buffer.from(t.toString()):Vn(t)||Re.Buffer.isBuffer(t)||(Tt.types.isAnyArrayBuffer(t)?t=Re.Buffer.from(t):ArrayBuffer.isView(t)?t=Re.Buffer.from(t.buffer,t.byteOffset,t.byteLength):t instanceof De.default||(t instanceof dr?(t=Xf(t),n=t.type.split("=")[1]):t=Re.Buffer.from(String(t))));let o=t;Re.Buffer.isBuffer(t)?o=De.default.Readable.from(t):Vn(t)&&(o=De.default.Readable.from(t.stream())),this[_e]={body:t,stream:o,boundary:n,disturbed:!1,error:null},this.size=r,t instanceof De.default&&t.on("error",l=>{let u=l instanceof Rt?l:new ye(`Invalid response body while trying to fetch ${this.url}: ${l.message}`,"system",l);this[_e].error=u})}get body(){return this[_e].stream}get bodyUsed(){return this[_e].disturbed}async arrayBuffer(){let{buffer:t,byteOffset:r,byteLength:n}=await Ts(this);return t.slice(r,r+n)}async formData(){let t=this.headers.get("content-type");if(t.startsWith("application/x-www-form-urlencoded")){let n=new dr,o=new URLSearchParams(await this.text());for(let[l,u]of o)n.append(l,u);return n}let{toFormData:r}=await Promise.resolve().then(()=>(ac(),ic));return r(this.body,t)}async blob(){let t=this.headers&&this.headers.get("content-type")||this[_e].body&&this[_e].body.type||"",r=await this.arrayBuffer();return new St([r],{type:t})}async json(){let t=await this.text();return JSON.parse(t)}async text(){let t=await Ts(this);return new TextDecoder().decode(t)}buffer(){return Ts(this)}};a(xs,"Body");var st=xs;st.prototype.buffer=(0,Tt.deprecate)(st.prototype.buffer,"Please use 'response.arrayBuffer()' instead of 'response.buffer()'","node-fetch#buffer");Object.defineProperties(st.prototype,{body:{enumerable:!0},bodyUsed:{enumerable:!0},arrayBuffer:{enumerable:!0},blob:{enumerable:!0},json:{enumerable:!0},text:{enumerable:!0},data:{get:(0,Tt.deprecate)(()=>{},"data doesn't exist, use json(), text(), arrayBuffer(), or body instead","https://github.com/node-fetch/node-fetch/issues/1000 (response)")}});async function Ts(e){if(e[_e].disturbed)throw new TypeError(`body used already for: ${e.url}`);if(e[_e].disturbed=!0,e[_e].error)throw e[_e].error;let{body:t}=e;if(t===null)return Re.Buffer.alloc(0);if(!(t instanceof De.default))return Re.Buffer.alloc(0);let r=[],n=0;try{for await(let o of t){if(e.size>0&&n+o.length>e.size){let l=new ye(`content size at ${e.url} over limit: ${e.size}`,"max-size");throw t.destroy(l),l}n+=o.length,r.push(o)}}catch(o){throw o instanceof Rt?o:new ye(`Invalid response body while trying to fetch ${e.url}: ${o.message}`,"system",o)}if(t.readableEnded===!0||t._readableState.ended===!0)try{return r.every(o=>typeof o=="string")?Re.Buffer.from(r.join("")):Re.Buffer.concat(r,n)}catch(o){throw new ye(`Could not create Buffer from response body for ${e.url}: ${o.message}`,"system",o)}else throw new ye(`Premature close of server response while trying to fetch ${e.url}`)}a(Ts,"consumeBody");var Qr=a((e,t)=>{let r,n,{body:o}=e[_e];if(e.bodyUsed)throw new Error("cannot clone body after it is used");return o instanceof De.default&&typeof o.getBoundary!="function"&&(r=new De.PassThrough({highWaterMark:t}),n=new De.PassThrough({highWaterMark:t}),o.pipe(r),o.pipe(n),e[_e].stream=r,o=n),o},"clone"),oy=(0,Tt.deprecate)(e=>e.getBoundary(),"form-data doesn't follow the spec and requires special treatment. Use alternative package","https://github.com/node-fetch/node-fetch/issues/1167"),pa=a((e,t)=>e===null?null:typeof e=="string"?"text/plain;charset=UTF-8":vs(e)?"application/x-www-form-urlencoded;charset=UTF-8":Vn(e)?e.type||null:Re.Buffer.isBuffer(e)||Tt.types.isAnyArrayBuffer(e)||ArrayBuffer.isView(e)?null:e instanceof dr?`multipart/form-data; boundary=${t[_e].boundary}`:e&&typeof e.getBoundary=="function"?`multipart/form-data;boundary=${oy(e)}`:e instanceof De.default?null:"text/plain;charset=UTF-8","extractContentType"),oc=a(e=>{let{body:t}=e[_e];return t===null?0:Vn(t)?t.size:Re.Buffer.isBuffer(t)?t.length:t&&typeof t.getLengthSync=="function"&&t.hasKnownLength&&t.hasKnownLength()?t.getLengthSync():null},"getTotalBytes"),sc=a(async(e,{body:t})=>{t===null?e.end():await ay(t,e)},"writeToStream");var As=require("util"),Yn=Fe(require("http"),1);var ma=typeof Yn.default.validateHeaderName=="function"?Yn.default.validateHeaderName:e=>{if(!/^[\^`\-\w!#$%&'*+.|~]+$/.test(e)){let t=new TypeError(`Header name must be a valid HTTP token [${e}]`);throw Object.defineProperty(t,"code",{value:"ERR_INVALID_HTTP_TOKEN"}),t}},ks=typeof Yn.default.validateHeaderValue=="function"?Yn.default.validateHeaderValue:(e,t)=>{if(/[^\t\u0020-\u007E\u0080-\u00FF]/.test(t)){let r=new TypeError(`Invalid character in header content ["${e}"]`);throw Object.defineProperty(r,"code",{value:"ERR_INVALID_CHAR"}),r}},ga=class ga extends URLSearchParams{constructor(t){let r=[];if(t instanceof ga){let n=t.raw();for(let[o,l]of Object.entries(n))r.push(...l.map(u=>[o,u]))}else if(t!=null)if(typeof t=="object"&&!As.types.isBoxedPrimitive(t)){let n=t[Symbol.iterator];if(n==null)r.push(...Object.entries(t));else{if(typeof n!="function")throw new TypeError("Header pairs must be iterable");r=[...t].map(o=>{if(typeof o!="object"||As.types.isBoxedPrimitive(o))throw new TypeError("Each header pair must be an iterable object");return[...o]}).map(o=>{if(o.length!==2)throw new TypeError("Each header pair must be a name/value tuple");return[...o]})}}else throw new TypeError("Failed to construct 'Headers': The provided value is not of type '(sequence<sequence<ByteString>> or record<ByteString, ByteString>)");return r=r.length>0?r.map(([n,o])=>(ma(n),ks(n,String(o)),[String(n).toLowerCase(),String(o)])):void 0,super(r),new Proxy(this,{get(n,o,l){switch(o){case"append":case"set":return(u,d)=>(ma(u),ks(u,String(d)),URLSearchParams.prototype[o].call(n,String(u).toLowerCase(),String(d)));case"delete":case"has":case"getAll":return u=>(ma(u),URLSearchParams.prototype[o].call(n,String(u).toLowerCase()));case"keys":return()=>(n.sort(),new Set(URLSearchParams.prototype.keys.call(n)).keys());default:return Reflect.get(n,o,l)}}})}get[Symbol.toStringTag](){return this.constructor.name}toString(){return Object.prototype.toString.call(this)}get(t){let r=this.getAll(t);if(r.length===0)return null;let n=r.join(", ");return/^content-encoding$/i.test(t)&&(n=n.toLowerCase()),n}forEach(t,r=void 0){for(let n of this.keys())Reflect.apply(t,r,[this.get(n),n,this])}*values(){for(let t of this.keys())yield this.get(t)}*entries(){for(let t of this.keys())yield[t,this.get(t)]}[Symbol.iterator](){return this.entries()}raw(){return[...this.keys()].reduce((t,r)=>(t[r]=this.getAll(r),t),{})}[Symbol.for("nodejs.util.inspect.custom")](){return[...this.keys()].reduce((t,r)=>{let n=this.getAll(r);return r==="host"?t[r]=n[0]:t[r]=n.length>1?n:n[0],t},{})}};a(ga,"Headers");var Te=ga;Object.defineProperties(Te.prototype,["get","entries","forEach","values"].reduce((e,t)=>(e[t]={enumerable:!0},e),{}));function lc(e=[]){return new Te(e.reduce((t,r,n,o)=>(n%2===0&&t.push(o.slice(n,n+2)),t),[]).filter(([t,r])=>{try{return ma(t),ks(t,String(r)),!0}catch{return!1}}))}a(lc,"fromRawHeaders");var sy=new Set([301,302,303,307,308]),ba=a(e=>sy.has(e),"isRedirect");var Ve=Symbol("Response internals"),pr=class pr extends st{constructor(t=null,r={}){super(t,r);let n=r.status!=null?r.status:200,o=new Te(r.headers);if(t!==null&&!o.has("Content-Type")){let l=pa(t,this);l&&o.append("Content-Type",l)}this[Ve]={type:"default",url:r.url,status:n,statusText:r.statusText||"",headers:o,counter:r.counter,highWaterMark:r.highWaterMark}}get type(){return this[Ve].type}get url(){return this[Ve].url||""}get status(){return this[Ve].status}get ok(){return this[Ve].status>=200&&this[Ve].status<300}get redirected(){return this[Ve].counter>0}get statusText(){return this[Ve].statusText}get headers(){return this[Ve].headers}get highWaterMark(){return this[Ve].highWaterMark}clone(){return new pr(Qr(this,this.highWaterMark),{type:this.type,url:this.url,status:this.status,statusText:this.statusText,headers:this.headers,ok:this.ok,redirected:this.redirected,size:this.size,highWaterMark:this.highWaterMark})}static redirect(t,r=302){if(!ba(r))throw new RangeError('Failed to execute "redirect" on "response": Invalid status code');return new pr(null,{headers:{location:new URL(t).toString()},status:r})}static error(){let t=new pr(null,{status:0,statusText:""});return t[Ve].type="error",t}static json(t=void 0,r={}){let n=JSON.stringify(t);if(n===void 0)throw new TypeError("data is not JSON serializable");let o=new Te(r&&r.headers);return o.has("content-type")||o.set("content-type","application/json"),new pr(n,{...r,headers:o})}get[Symbol.toStringTag](){return"Response"}};a(pr,"Response");var Be=pr;Object.defineProperties(Be.prototype,{type:{enumerable:!0},url:{enumerable:!0},status:{enumerable:!0},ok:{enumerable:!0},redirected:{enumerable:!0},statusText:{enumerable:!0},headers:{enumerable:!0},clone:{enumerable:!0}});var bc=require("url"),yc=require("util");var uc=a(e=>{if(e.search)return e.search;let t=e.href.length-1,r=e.hash||(e.href[t]==="#"?"#":"");return e.href[t-r.length]==="?"?"?":""},"getSearch");var cc=require("net");function fc(e,t=!1){return e==null||(e=new URL(e),/^(about|blob|data):$/.test(e.protocol))?"no-referrer":(e.username="",e.password="",e.hash="",t&&(e.pathname="",e.search=""),e)}a(fc,"stripURLForUseAsAReferrer");var dc=new Set(["","no-referrer","no-referrer-when-downgrade","same-origin","origin","strict-origin","origin-when-cross-origin","strict-origin-when-cross-origin","unsafe-url"]),hc="strict-origin-when-cross-origin";function pc(e){if(!dc.has(e))throw new TypeError(`Invalid referrerPolicy: ${e}`);return e}a(pc,"validateReferrerPolicy");function ly(e){if(/^(http|ws)s:$/.test(e.protocol))return!0;let t=e.host.replace(/(^\[)|(]$)/g,""),r=(0,cc.isIP)(t);return r===4&&/^127\./.test(t)||r===6&&/^(((0+:){7})|(::(0+:){0,6}))0*1$/.test(t)?!0:e.host==="localhost"||e.host.endsWith(".localhost")?!1:e.protocol==="file:"}a(ly,"isOriginPotentiallyTrustworthy");function en(e){return/^about:(blank|srcdoc)$/.test(e)||e.protocol==="data:"||/^(blob|filesystem):$/.test(e.protocol)?!0:ly(e)}a(en,"isUrlPotentiallyTrustworthy");function mc(e,{referrerURLCallback:t,referrerOriginCallback:r}={}){if(e.referrer==="no-referrer"||e.referrerPolicy==="")return null;let n=e.referrerPolicy;if(e.referrer==="about:client")return"no-referrer";let o=e.referrer,l=fc(o),u=fc(o,!0);l.toString().length>4096&&(l=u),t&&(l=t(l)),r&&(u=r(u));let d=new URL(e.url);switch(n){case"no-referrer":return"no-referrer";case"origin":return u;case"unsafe-url":return l;case"strict-origin":return en(l)&&!en(d)?"no-referrer":u.toString();case"strict-origin-when-cross-origin":return l.origin===d.origin?l:en(l)&&!en(d)?"no-referrer":u;case"same-origin":return l.origin===d.origin?l:"no-referrer";case"origin-when-cross-origin":return l.origin===d.origin?l:u;case"no-referrer-when-downgrade":return en(l)&&!en(d)?"no-referrer":l;default:throw new TypeError(`Invalid referrerPolicy: ${n}`)}}a(mc,"determineRequestsReferrer");function gc(e){let t=(e.get("referrer-policy")||"").split(/[,\s]+/),r="";for(let n of t)n&&dc.has(n)&&(r=n);return r}a(gc,"parseReferrerPolicyFromHeader");var se=Symbol("Request internals"),Kn=a(e=>typeof e=="object"&&typeof e[se]=="object","isRequest"),uy=(0,yc.deprecate)(()=>{},".data is not a valid RequestInit property, use .body instead","https://github.com/node-fetch/node-fetch/issues/1000 (request)"),ya=class ya extends st{constructor(t,r={}){let n;if(Kn(t)?n=new URL(t.url):(n=new URL(t),t={}),n.username!==""||n.password!=="")throw new TypeError(`${n} is an url with embedded credentials.`);let o=r.method||t.method||"GET";if(/^(delete|get|head|options|post|put)$/i.test(o)&&(o=o.toUpperCase()),!Kn(r)&&"data"in r&&uy(),(r.body!=null||Kn(t)&&t.body!==null)&&(o==="GET"||o==="HEAD"))throw new TypeError("Request with GET/HEAD method cannot have body");let l=r.body?r.body:Kn(t)&&t.body!==null?Qr(t):null;super(l,{size:r.size||t.size||0});let u=new Te(r.headers||t.headers||{});if(l!==null&&!u.has("Content-Type")){let c=pa(l,this);c&&u.set("Content-Type",c)}let d=Kn(t)?t.signal:null;if("signal"in r&&(d=r.signal),d!=null&&!Jf(d))throw new TypeError("Expected signal to be an instanceof AbortSignal or EventTarget");let m=r.referrer==null?t.referrer:r.referrer;if(m==="")m="no-referrer";else if(m){let c=new URL(m);m=/^about:(\/\/)?client$/.test(c)?"client":c}else m=void 0;this[se]={method:o,redirect:r.redirect||t.redirect||"follow",headers:u,parsedURL:n,signal:d,referrer:m},this.follow=r.follow===void 0?t.follow===void 0?20:t.follow:r.follow,this.compress=r.compress===void 0?t.compress===void 0?!0:t.compress:r.compress,this.counter=r.counter||t.counter||0,this.agent=r.agent||t.agent,this.highWaterMark=r.highWaterMark||t.highWaterMark||16384,this.insecureHTTPParser=r.insecureHTTPParser||t.insecureHTTPParser||!1,this.referrerPolicy=r.referrerPolicy||t.referrerPolicy||""}get method(){return this[se].method}get url(){return(0,bc.format)(this[se].parsedURL)}get headers(){return this[se].headers}get redirect(){return this[se].redirect}get signal(){return this[se].signal}get referrer(){if(this[se].referrer==="no-referrer")return"";if(this[se].referrer==="client")return"about:client";if(this[se].referrer)return this[se].referrer.toString()}get referrerPolicy(){return this[se].referrerPolicy}set referrerPolicy(t){this[se].referrerPolicy=pc(t)}clone(){return new ya(this)}get[Symbol.toStringTag](){return"Request"}};a(ya,"Request");var mr=ya;Object.defineProperties(mr.prototype,{method:{enumerable:!0},url:{enumerable:!0},headers:{enumerable:!0},redirect:{enumerable:!0},clone:{enumerable:!0},signal:{enumerable:!0},referrer:{enumerable:!0},referrerPolicy:{enumerable:!0}});var _c=a(e=>{let{parsedURL:t}=e[se],r=new Te(e[se].headers);r.has("Accept")||r.set("Accept","*/*");let n=null;if(e.body===null&&/^(post|put)$/i.test(e.method)&&(n="0"),e.body!==null){let d=oc(e);typeof d=="number"&&!Number.isNaN(d)&&(n=String(d))}n&&r.set("Content-Length",n),e.referrerPolicy===""&&(e.referrerPolicy=hc),e.referrer&&e.referrer!=="no-referrer"?e[se].referrer=mc(e):e[se].referrer="no-referrer",e[se].referrer instanceof URL&&r.set("Referer",e.referrer),r.has("User-Agent")||r.set("User-Agent","node-fetch"),e.compress&&!r.has("Accept-Encoding")&&r.set("Accept-Encoding","gzip, deflate, br");let{agent:o}=e;typeof o=="function"&&(o=o(t));let l=uc(t),u={path:t.pathname+l,method:e.method,headers:r[Symbol.for("nodejs.util.inspect.custom")](),insecureHTTPParser:e.insecureHTTPParser,agent:o};return{parsedURL:t,options:u}},"getNodeRequestOptions");var Es=class Es extends Rt{constructor(t,r="aborted"){super(t,r)}};a(Es,"AbortError");var _a=Es;ua();ws();var fy=new Set(["data:","http:","https:"]);async function va(e,t){return new Promise((r,n)=>{let o=new mr(e,t),{parsedURL:l,options:u}=_c(o);if(!fy.has(l.protocol))throw new TypeError(`node-fetch cannot load ${e}. URL scheme "${l.protocol.replace(/:$/,"")}" is not supported.`);if(l.protocol==="data:"){let v=jf(o.url),E=new Be(v,{headers:{"Content-Type":v.typeFull}});r(E);return}let d=(l.protocol==="https:"?wc.default:vc.default).request,{signal:m}=o,c=null,h=a(()=>{let v=new _a("The operation was aborted.");n(v),o.body&&o.body instanceof xe.default.Readable&&o.body.destroy(v),!(!c||!c.body)&&c.body.emit("error",v)},"abort");if(m&&m.aborted){h();return}let x=a(()=>{h(),w()},"abortAndFinalize"),y=d(l.toString(),u);m&&m.addEventListener("abort",x);let w=a(()=>{y.abort(),m&&m.removeEventListener("abort",x)},"finalize");y.on("error",v=>{n(new ye(`request to ${o.url} failed, reason: ${v.message}`,"system",v)),w()}),cy(y,v=>{c&&c.body&&c.body.destroy(v)}),process.version<"v14"&&y.on("socket",v=>{let E;v.prependListener("end",()=>{E=v._eventsCount}),v.prependListener("close",k=>{if(c&&E<v._eventsCount&&!k){let S=new Error("Premature close");S.code="ERR_STREAM_PREMATURE_CLOSE",c.body.emit("error",S)}})}),y.on("response",v=>{y.setTimeout(0);let E=lc(v.rawHeaders);if(ba(v.statusCode)){let R=E.get("Location"),T=null;try{T=R===null?null:new URL(R,o.url)}catch{if(o.redirect!=="manual"){n(new ye(`uri requested responds with an invalid redirect URL: ${R}`,"invalid-redirect")),w();return}}switch(o.redirect){case"error":n(new ye(`uri requested responds with a redirect, redirect mode is set to error: ${o.url}`,"no-redirect")),w();return;case"manual":break;case"follow":{if(T===null)break;if(o.counter>=o.follow){n(new ye(`maximum redirect reached at: ${o.url}`,"max-redirect")),w();return}let F={headers:new Te(o.headers),follow:o.follow,counter:o.counter+1,agent:o.agent,compress:o.compress,method:o.method,body:Qr(o),signal:o.signal,size:o.size,referrer:o.referrer,referrerPolicy:o.referrerPolicy};if(!Qf(o.url,T)||!ec(o.url,T))for(let B of["authorization","www-authenticate","cookie","cookie2"])F.headers.delete(B);if(v.statusCode!==303&&o.body&&t.body instanceof xe.default.Readable){n(new ye("Cannot follow redirect with body being a readable stream","unsupported-redirect")),w();return}(v.statusCode===303||(v.statusCode===301||v.statusCode===302)&&o.method==="POST")&&(F.method="GET",F.body=void 0,F.headers.delete("content-length"));let z=gc(E);z&&(F.referrerPolicy=z),r(va(new mr(T,F))),w();return}default:return n(new TypeError(`Redirect option '${o.redirect}' is not a valid value of RequestRedirect`))}}m&&v.once("end",()=>{m.removeEventListener("abort",x)});let k=(0,xe.pipeline)(v,new xe.PassThrough,R=>{R&&n(R)});process.version<"v12.10"&&v.on("aborted",x);let S={url:o.url,status:v.statusCode,statusText:v.statusMessage,headers:E,size:o.size,counter:o.counter,highWaterMark:o.highWaterMark},A=E.get("Content-Encoding");if(!o.compress||o.method==="HEAD"||A===null||v.statusCode===204||v.statusCode===304){c=new Be(k,S),r(c);return}let C={flush:gr.default.Z_SYNC_FLUSH,finishFlush:gr.default.Z_SYNC_FLUSH};if(A==="gzip"||A==="x-gzip"){k=(0,xe.pipeline)(k,gr.default.createGunzip(C),R=>{R&&n(R)}),c=new Be(k,S),r(c);return}if(A==="deflate"||A==="x-deflate"){let R=(0,xe.pipeline)(v,new xe.PassThrough,T=>{T&&n(T)});R.once("data",T=>{(T[0]&15)===8?k=(0,xe.pipeline)(k,gr.default.createInflate(),F=>{F&&n(F)}):k=(0,xe.pipeline)(k,gr.default.createInflateRaw(),F=>{F&&n(F)}),c=new Be(k,S),r(c)}),R.once("end",()=>{c||(c=new Be(k,S),r(c))});return}if(A==="br"){k=(0,xe.pipeline)(k,gr.default.createBrotliDecompress(),R=>{R&&n(R)}),c=new Be(k,S),r(c);return}c=new Be(k,S),r(c)}),sc(y,o).catch(n)})}a(va,"fetch");function cy(e,t){let r=Xn.Buffer.from(`0\r
|
|
11
|
+
`)).replace(/\n/g,"%0A").replace(/\r/g,"%0D").replace(/"/g,"%22"),"e"),cr=a((e,t,r)=>{if(t.length<r)throw new TypeError(`Failed to execute '${e}' on 'FormData': ${r} arguments required, but only ${t.length} present.`)},"x"),dr=(Jr=class{constructor(...t){Ze(this,Oe,[]);if(t.length)throw new TypeError("Failed to construct 'FormData': parameter 1 is not of type 'HTMLFormElement'.")}get[Zn](){return"FormData"}[Gb](){return this.entries()}static[Yb](t){return t&&typeof t=="object"&&t[Zn]==="FormData"&&!Kb.some(r=>typeof t[r]!="function")}append(...t){cr("append",arguments,2),te(this,Oe).push(Kf(...t))}delete(t){cr("delete",arguments,1),t+="",Se(this,Oe,te(this,Oe).filter(([r])=>r!==t))}get(t){cr("get",arguments,1),t+="";for(var r=te(this,Oe),n=r.length,o=0;o<n;o++)if(r[o][0]===t)return r[o][1];return null}getAll(t,r){return cr("getAll",arguments,1),r=[],t+="",te(this,Oe).forEach(n=>n[0]===t&&r.push(n[1])),r}has(t){return cr("has",arguments,1),t+="",te(this,Oe).some(r=>r[0]===t)}forEach(t,r){cr("forEach",arguments,1);for(var[n,o]of this)t.call(r,o,n,this)}set(...t){cr("set",arguments,2);var r=[],n=!0;t=Kf(...t),te(this,Oe).forEach(o=>{o[0]===t[0]?n&&(n=!r.push(t)):r.push(o)}),n&&r.push(t),Se(this,Oe,r)}*entries(){yield*te(this,Oe)}*keys(){for(var[t]of this)yield t}*values(){for(var[,t]of this)yield t}},Oe=new WeakMap,a(Jr,"FormData"),Jr);a(Xf,"formDataToBlob")});var rc=P((_S,tc)=>{if(!globalThis.DOMException)try{let{MessageChannel:e}=require("worker_threads"),t=new e().port1,r=new ArrayBuffer;t.postMessage(r,[r,r])}catch(e){e.constructor.name==="DOMException"&&(globalThis.DOMException=e.constructor)}tc.exports=globalThis.DOMException});var ca,Xb,SS,ws=Wn(()=>{ca=require("fs"),Xb=Fe(rc(),1);gs();jn();({stat:SS}=ca.promises)});var ic={};Mf(ic,{toFormData:()=>iy});function ny(e){let t=e.match(/\bfilename=("(.*?)"|([^()<>@,;:\\"/[\]?={}\s\t]+))($|;\s)/i);if(!t)return;let r=t[2]||t[3]||"",n=r.slice(r.lastIndexOf("\\")+1);return n=n.replace(/%22/g,'"'),n=n.replace(/&#(\d{4});/g,(o,l)=>String.fromCharCode(l)),n}async function iy(e,t){if(!/multipart/i.test(t))throw new TypeError("Failed to fetch");let r=t.match(/boundary=(?:"([^"]+)"|([^;]+))/i);if(!r)throw new TypeError("no or bad content-type header, no multipart boundary");let n=new Ss(r[1]||r[2]),o,l,u,d,m,c,h=[],x=new dr,y=a(S=>{u+=k.decode(S,{stream:!0})},"onPartData"),w=a(S=>{h.push(S)},"appendToFile"),v=a(()=>{let S=new Xr(h,c,{type:m});x.append(d,S)},"appendFileToFormData"),E=a(()=>{x.append(d,u)},"appendEntryToFormData"),k=new TextDecoder("utf-8");k.decode(),n.onPartBegin=function(){n.onPartData=y,n.onPartEnd=E,o="",l="",u="",d="",m="",c=null,h.length=0},n.onHeaderField=function(S){o+=k.decode(S,{stream:!0})},n.onHeaderValue=function(S){l+=k.decode(S,{stream:!0})},n.onHeaderEnd=function(){if(l+=k.decode(),o=o.toLowerCase(),o==="content-disposition"){let S=l.match(/\bname=("([^"]*)"|([^()<>@,;:\\"/[\]?={}\s\t]+))/i);S&&(d=S[2]||S[3]||""),c=ny(l),c&&(n.onPartData=w,n.onPartEnd=v)}else o==="content-type"&&(m=l);l="",o=""};for await(let S of e)n.write(S);return n.end(),x}var ot,K,nc,Ht,da,ha,Jb,Gn,Qb,ey,ty,ry,hr,Ts,Ss,ac=Wn(()=>{ws();ua();ot=0,K={START_BOUNDARY:ot++,HEADER_FIELD_START:ot++,HEADER_FIELD:ot++,HEADER_VALUE_START:ot++,HEADER_VALUE:ot++,HEADER_VALUE_ALMOST_DONE:ot++,HEADERS_ALMOST_DONE:ot++,PART_DATA_START:ot++,PART_DATA:ot++,END:ot++},nc=1,Ht={PART_BOUNDARY:nc,LAST_BOUNDARY:nc*=2},da=10,ha=13,Jb=32,Gn=45,Qb=58,ey=97,ty=122,ry=a(e=>e|32,"lower"),hr=a(()=>{},"noop"),Ts=class Ts{constructor(t){this.index=0,this.flags=0,this.onHeaderEnd=hr,this.onHeaderField=hr,this.onHeadersEnd=hr,this.onHeaderValue=hr,this.onPartBegin=hr,this.onPartData=hr,this.onPartEnd=hr,this.boundaryChars={},t=`\r
|
|
12
|
+
--`+t;let r=new Uint8Array(t.length);for(let n=0;n<t.length;n++)r[n]=t.charCodeAt(n),this.boundaryChars[r[n]]=!0;this.boundary=r,this.lookbehind=new Uint8Array(this.boundary.length+8),this.state=K.START_BOUNDARY}write(t){let r=0,n=t.length,o=this.index,{lookbehind:l,boundary:u,boundaryChars:d,index:m,state:c,flags:h}=this,x=this.boundary.length,y=x-1,w=t.length,v,E,k=a(T=>{this[T+"Mark"]=r},"mark"),S=a(T=>{delete this[T+"Mark"]},"clear"),A=a((T,R,F,z)=>{(R===void 0||R!==F)&&this[T](z&&z.subarray(R,F))},"callback"),C=a((T,R)=>{let F=T+"Mark";F in this&&(R?(A(T,this[F],r,t),delete this[F]):(A(T,this[F],t.length,t),this[F]=0))},"dataCallback");for(r=0;r<n;r++)switch(v=t[r],c){case K.START_BOUNDARY:if(m===u.length-2){if(v===Gn)h|=Ht.LAST_BOUNDARY;else if(v!==ha)return;m++;break}else if(m-1===u.length-2){if(h&Ht.LAST_BOUNDARY&&v===Gn)c=K.END,h=0;else if(!(h&Ht.LAST_BOUNDARY)&&v===da)m=0,A("onPartBegin"),c=K.HEADER_FIELD_START;else return;break}v!==u[m+2]&&(m=-2),v===u[m+2]&&m++;break;case K.HEADER_FIELD_START:c=K.HEADER_FIELD,k("onHeaderField"),m=0;case K.HEADER_FIELD:if(v===ha){S("onHeaderField"),c=K.HEADERS_ALMOST_DONE;break}if(m++,v===Gn)break;if(v===Qb){if(m===1)return;C("onHeaderField",!0),c=K.HEADER_VALUE_START;break}if(E=ry(v),E<ey||E>ty)return;break;case K.HEADER_VALUE_START:if(v===Jb)break;k("onHeaderValue"),c=K.HEADER_VALUE;case K.HEADER_VALUE:v===ha&&(C("onHeaderValue",!0),A("onHeaderEnd"),c=K.HEADER_VALUE_ALMOST_DONE);break;case K.HEADER_VALUE_ALMOST_DONE:if(v!==da)return;c=K.HEADER_FIELD_START;break;case K.HEADERS_ALMOST_DONE:if(v!==da)return;A("onHeadersEnd"),c=K.PART_DATA_START;break;case K.PART_DATA_START:c=K.PART_DATA,k("onPartData");case K.PART_DATA:if(o=m,m===0){for(r+=y;r<w&&!(t[r]in d);)r+=x;r-=y,v=t[r]}if(m<u.length)u[m]===v?(m===0&&C("onPartData",!0),m++):m=0;else if(m===u.length)m++,v===ha?h|=Ht.PART_BOUNDARY:v===Gn?h|=Ht.LAST_BOUNDARY:m=0;else if(m-1===u.length)if(h&Ht.PART_BOUNDARY){if(m=0,v===da){h&=~Ht.PART_BOUNDARY,A("onPartEnd"),A("onPartBegin"),c=K.HEADER_FIELD_START;break}}else h&Ht.LAST_BOUNDARY&&v===Gn?(A("onPartEnd"),c=K.END,h=0):m=0;if(m>0)l[m-1]=v;else if(o>0){let T=new Uint8Array(l.buffer,l.byteOffset,l.byteLength);A("onPartData",0,o,T),o=0,k("onPartData"),r--}break;case K.END:break;default:throw new Error(`Unexpected state entered: ${c}`)}C("onHeaderField"),C("onHeaderValue"),C("onPartData"),this.index=m,this.state=c,this.flags=h}end(){if(this.state===K.HEADER_FIELD_START&&this.index===0||this.state===K.PART_DATA&&this.index===this.boundary.length)this.onPartEnd();else if(this.state!==K.END)throw new Error("MultipartParser.end(): stream ended unexpectedly")}};a(Ts,"MultipartParser");Ss=Ts;a(ny,"_fileName");a(iy,"toFormData")});var Jn=P((ST,Cs)=>{"use strict";typeof process>"u"||!process.version||process.version.indexOf("v0.")===0||process.version.indexOf("v1.")===0&&process.version.indexOf("v1.8.")!==0?Cs.exports={nextTick:dy}:Cs.exports=process;function dy(e,t,r,n){if(typeof e!="function")throw new TypeError('"callback" argument must be a function');var o=arguments.length,l,u;switch(o){case 0:case 1:return process.nextTick(e);case 2:return process.nextTick(a(function(){e.call(null,t)},"afterTickOne"));case 3:return process.nextTick(a(function(){e.call(null,t,r)},"afterTickTwo"));case 4:return process.nextTick(a(function(){e.call(null,t,r,n)},"afterTickThree"));default:for(l=new Array(o-1),u=0;u<l.length;)l[u++]=arguments[u];return process.nextTick(a(function(){e.apply(null,l)},"afterTick"))}}a(dy,"nextTick")});var Tc=P((RT,Sc)=>{var hy={}.toString;Sc.exports=Array.isArray||function(e){return hy.call(e)=="[object Array]"}});var Ps=P((xT,Rc)=>{Rc.exports=require("stream")});var Qn=P((Is,Ac)=>{var wa=require("buffer"),xt=wa.Buffer;function xc(e,t){for(var r in e)t[r]=e[r]}a(xc,"copyProps");xt.from&&xt.alloc&&xt.allocUnsafe&&xt.allocUnsafeSlow?Ac.exports=wa:(xc(wa,Is),Is.Buffer=tn);function tn(e,t,r){return xt(e,t,r)}a(tn,"SafeBuffer");xc(xt,tn);tn.from=function(e,t,r){if(typeof e=="number")throw new TypeError("Argument must not be a number");return xt(e,t,r)};tn.alloc=function(e,t,r){if(typeof e!="number")throw new TypeError("Argument must be a number");var n=xt(e);return t!==void 0?typeof r=="string"?n.fill(t,r):n.fill(t):n.fill(0),n};tn.allocUnsafe=function(e){if(typeof e!="number")throw new TypeError("Argument must be a number");return xt(e)};tn.allocUnsafeSlow=function(e){if(typeof e!="number")throw new TypeError("Argument must be a number");return wa.SlowBuffer(e)}});var rn=P(de=>{function py(e){return Array.isArray?Array.isArray(e):Sa(e)==="[object Array]"}a(py,"isArray");de.isArray=py;function my(e){return typeof e=="boolean"}a(my,"isBoolean");de.isBoolean=my;function gy(e){return e===null}a(gy,"isNull");de.isNull=gy;function by(e){return e==null}a(by,"isNullOrUndefined");de.isNullOrUndefined=by;function yy(e){return typeof e=="number"}a(yy,"isNumber");de.isNumber=yy;function _y(e){return typeof e=="string"}a(_y,"isString");de.isString=_y;function vy(e){return typeof e=="symbol"}a(vy,"isSymbol");de.isSymbol=vy;function wy(e){return e===void 0}a(wy,"isUndefined");de.isUndefined=wy;function Sy(e){return Sa(e)==="[object RegExp]"}a(Sy,"isRegExp");de.isRegExp=Sy;function Ty(e){return typeof e=="object"&&e!==null}a(Ty,"isObject");de.isObject=Ty;function Ry(e){return Sa(e)==="[object Date]"}a(Ry,"isDate");de.isDate=Ry;function xy(e){return Sa(e)==="[object Error]"||e instanceof Error}a(xy,"isError");de.isError=xy;function Ay(e){return typeof e=="function"}a(Ay,"isFunction");de.isFunction=Ay;function ky(e){return e===null||typeof e=="boolean"||typeof e=="number"||typeof e=="string"||typeof e=="symbol"||typeof e>"u"}a(ky,"isPrimitive");de.isPrimitive=ky;de.isBuffer=require("buffer").Buffer.isBuffer;function Sa(e){return Object.prototype.toString.call(e)}a(Sa,"objectToString")});var kc=P((CT,Fs)=>{typeof Object.create=="function"?Fs.exports=a(function(t,r){r&&(t.super_=r,t.prototype=Object.create(r.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}))},"inherits"):Fs.exports=a(function(t,r){if(r){t.super_=r;var n=a(function(){},"TempCtor");n.prototype=r.prototype,t.prototype=new n,t.prototype.constructor=t}},"inherits")});var nn=P((IT,Ds)=>{try{if(Os=require("util"),typeof Os.inherits!="function")throw"";Ds.exports=Os.inherits}catch{Ds.exports=kc()}var Os});var Cc=P((FT,Bs)=>{"use strict";function Ey(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}a(Ey,"_classCallCheck");var Ec=Qn().Buffer,ei=require("util");function Cy(e,t,r){e.copy(t,r)}a(Cy,"copyBuffer");Bs.exports=function(){function e(){Ey(this,e),this.head=null,this.tail=null,this.length=0}return a(e,"BufferList"),e.prototype.push=a(function(r){var n={data:r,next:null};this.length>0?this.tail.next=n:this.head=n,this.tail=n,++this.length},"push"),e.prototype.unshift=a(function(r){var n={data:r,next:this.head};this.length===0&&(this.tail=n),this.head=n,++this.length},"unshift"),e.prototype.shift=a(function(){if(this.length!==0){var r=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,r}},"shift"),e.prototype.clear=a(function(){this.head=this.tail=null,this.length=0},"clear"),e.prototype.join=a(function(r){if(this.length===0)return"";for(var n=this.head,o=""+n.data;n=n.next;)o+=r+n.data;return o},"join"),e.prototype.concat=a(function(r){if(this.length===0)return Ec.alloc(0);for(var n=Ec.allocUnsafe(r>>>0),o=this.head,l=0;o;)Cy(o.data,n,l),l+=o.data.length,o=o.next;return n},"concat"),e}();ei&&ei.inspect&&ei.inspect.custom&&(Bs.exports.prototype[ei.inspect.custom]=function(){var e=ei.inspect({length:this.length});return this.constructor.name+" "+e})});var Ls=P((DT,Pc)=>{"use strict";var Ta=Jn();function Py(e,t){var r=this,n=this._readableState&&this._readableState.destroyed,o=this._writableState&&this._writableState.destroyed;return n||o?(t?t(e):e&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,Ta.nextTick(Ra,this,e)):Ta.nextTick(Ra,this,e)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,function(l){!t&&l?r._writableState?r._writableState.errorEmitted||(r._writableState.errorEmitted=!0,Ta.nextTick(Ra,r,l)):Ta.nextTick(Ra,r,l):t&&t(l)}),this)}a(Py,"destroy");function Iy(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}a(Iy,"undestroy");function Ra(e,t){e.emit("error",t)}a(Ra,"emitErrorNT");Pc.exports={destroy:Py,undestroy:Iy}});var Fc=P((LT,Ic)=>{Ic.exports=require("util").deprecate});var qs=P((zT,Mc)=>{"use strict";var br=Jn();Mc.exports=ne;function Dc(e){var t=this;this.next=null,this.entry=null,this.finish=function(){Yy(t,e)}}a(Dc,"CorkedRequest");var Fy=!process.browser&&["v0.10","v0.9."].indexOf(process.version.slice(0,5))>-1?setImmediate:br.nextTick,an;ne.WritableState=ri;var Bc=Object.create(rn());Bc.inherits=nn();var Oy={deprecate:Fc()},Lc=Ps(),Aa=Qn().Buffer,Dy=(typeof global<"u"?global:typeof window<"u"?window:typeof self<"u"?self:{}).Uint8Array||function(){};function By(e){return Aa.from(e)}a(By,"_uint8ArrayToBuffer");function Ly(e){return Aa.isBuffer(e)||e instanceof Dy}a(Ly,"_isUint8Array");var zc=Ls();Bc.inherits(ne,Lc);function zy(){}a(zy,"nop");function ri(e,t){an=an||yr(),e=e||{};var r=t instanceof an;this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.writableObjectMode);var n=e.highWaterMark,o=e.writableHighWaterMark,l=this.objectMode?16:16*1024;n||n===0?this.highWaterMark=n:r&&(o||o===0)?this.highWaterMark=o:this.highWaterMark=l,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var u=e.decodeStrings===!1;this.decodeStrings=!u,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(d){Hy(t,d)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new Dc(this)}a(ri,"WritableState");ri.prototype.getBuffer=a(function(){for(var t=this.bufferedRequest,r=[];t;)r.push(t),t=t.next;return r},"getBuffer");(function(){try{Object.defineProperty(ri.prototype,"buffer",{get:Oy.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch{}})();var xa;typeof Symbol=="function"&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]=="function"?(xa=Function.prototype[Symbol.hasInstance],Object.defineProperty(ne,Symbol.hasInstance,{value:a(function(e){return xa.call(this,e)?!0:this!==ne?!1:e&&e._writableState instanceof ri},"value")})):xa=a(function(e){return e instanceof this},"realHasInstance");function ne(e){if(an=an||yr(),!xa.call(ne,this)&&!(this instanceof an))return new ne(e);this._writableState=new ri(e,this),this.writable=!0,e&&(typeof e.write=="function"&&(this._write=e.write),typeof e.writev=="function"&&(this._writev=e.writev),typeof e.destroy=="function"&&(this._destroy=e.destroy),typeof e.final=="function"&&(this._final=e.final)),Lc.call(this)}a(ne,"Writable");ne.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))};function qy(e,t){var r=new Error("write after end");e.emit("error",r),br.nextTick(t,r)}a(qy,"writeAfterEnd");function Uy(e,t,r,n){var o=!0,l=!1;return r===null?l=new TypeError("May not write null values to stream"):typeof r!="string"&&r!==void 0&&!t.objectMode&&(l=new TypeError("Invalid non-string/buffer chunk")),l&&(e.emit("error",l),br.nextTick(n,l),o=!1),o}a(Uy,"validChunk");ne.prototype.write=function(e,t,r){var n=this._writableState,o=!1,l=!n.objectMode&&Ly(e);return l&&!Aa.isBuffer(e)&&(e=By(e)),typeof t=="function"&&(r=t,t=null),l?t="buffer":t||(t=n.defaultEncoding),typeof r!="function"&&(r=zy),n.ended?qy(this,r):(l||Uy(this,n,e,r))&&(n.pendingcb++,o=Wy(this,n,l,e,t,r)),o};ne.prototype.cork=function(){var e=this._writableState;e.corked++};ne.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,!e.writing&&!e.corked&&!e.bufferProcessing&&e.bufferedRequest&&qc(this,e))};ne.prototype.setDefaultEncoding=a(function(t){if(typeof t=="string"&&(t=t.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((t+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+t);return this._writableState.defaultEncoding=t,this},"setDefaultEncoding");function My(e,t,r){return!e.objectMode&&e.decodeStrings!==!1&&typeof t=="string"&&(t=Aa.from(t,r)),t}a(My,"decodeChunk");Object.defineProperty(ne.prototype,"writableHighWaterMark",{enumerable:!1,get:a(function(){return this._writableState.highWaterMark},"get")});function Wy(e,t,r,n,o,l){if(!r){var u=My(t,n,o);n!==u&&(r=!0,o="buffer",n=u)}var d=t.objectMode?1:n.length;t.length+=d;var m=t.length<t.highWaterMark;if(m||(t.needDrain=!0),t.writing||t.corked){var c=t.lastBufferedRequest;t.lastBufferedRequest={chunk:n,encoding:o,isBuf:r,callback:l,next:null},c?c.next=t.lastBufferedRequest:t.bufferedRequest=t.lastBufferedRequest,t.bufferedRequestCount+=1}else zs(e,t,!1,d,n,o,l);return m}a(Wy,"writeOrBuffer");function zs(e,t,r,n,o,l,u){t.writelen=n,t.writecb=u,t.writing=!0,t.sync=!0,r?e._writev(o,t.onwrite):e._write(o,l,t.onwrite),t.sync=!1}a(zs,"doWrite");function Ny(e,t,r,n,o){--t.pendingcb,r?(br.nextTick(o,n),br.nextTick(ti,e,t),e._writableState.errorEmitted=!0,e.emit("error",n)):(o(n),e._writableState.errorEmitted=!0,e.emit("error",n),ti(e,t))}a(Ny,"onwriteError");function jy(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}a(jy,"onwriteStateUpdate");function Hy(e,t){var r=e._writableState,n=r.sync,o=r.writecb;if(jy(r),t)Ny(e,r,n,t,o);else{var l=Uc(r);!l&&!r.corked&&!r.bufferProcessing&&r.bufferedRequest&&qc(e,r),n?Fy(Oc,e,r,l,o):Oc(e,r,l,o)}}a(Hy,"onwrite");function Oc(e,t,r,n){r||$y(e,t),t.pendingcb--,n(),ti(e,t)}a(Oc,"afterWrite");function $y(e,t){t.length===0&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}a($y,"onwriteDrain");function qc(e,t){t.bufferProcessing=!0;var r=t.bufferedRequest;if(e._writev&&r&&r.next){var n=t.bufferedRequestCount,o=new Array(n),l=t.corkedRequestsFree;l.entry=r;for(var u=0,d=!0;r;)o[u]=r,r.isBuf||(d=!1),r=r.next,u+=1;o.allBuffers=d,zs(e,t,!0,t.length,o,"",l.finish),t.pendingcb++,t.lastBufferedRequest=null,l.next?(t.corkedRequestsFree=l.next,l.next=null):t.corkedRequestsFree=new Dc(t),t.bufferedRequestCount=0}else{for(;r;){var m=r.chunk,c=r.encoding,h=r.callback,x=t.objectMode?1:m.length;if(zs(e,t,!1,x,m,c,h),r=r.next,t.bufferedRequestCount--,t.writing)break}r===null&&(t.lastBufferedRequest=null)}t.bufferedRequest=r,t.bufferProcessing=!1}a(qc,"clearBuffer");ne.prototype._write=function(e,t,r){r(new Error("_write() is not implemented"))};ne.prototype._writev=null;ne.prototype.end=function(e,t,r){var n=this._writableState;typeof e=="function"?(r=e,e=null,t=null):typeof t=="function"&&(r=t,t=null),e!=null&&this.write(e,t),n.corked&&(n.corked=1,this.uncork()),n.ending||Gy(this,n,r)};function Uc(e){return e.ending&&e.length===0&&e.bufferedRequest===null&&!e.finished&&!e.writing}a(Uc,"needFinish");function Zy(e,t){e._final(function(r){t.pendingcb--,r&&e.emit("error",r),t.prefinished=!0,e.emit("prefinish"),ti(e,t)})}a(Zy,"callFinal");function Vy(e,t){!t.prefinished&&!t.finalCalled&&(typeof e._final=="function"?(t.pendingcb++,t.finalCalled=!0,br.nextTick(Zy,e,t)):(t.prefinished=!0,e.emit("prefinish")))}a(Vy,"prefinish");function ti(e,t){var r=Uc(t);return r&&(Vy(e,t),t.pendingcb===0&&(t.finished=!0,e.emit("finish"))),r}a(ti,"finishMaybe");function Gy(e,t,r){t.ending=!0,ti(e,t),r&&(t.finished?br.nextTick(r):e.once("finish",r)),t.ended=!0,e.writable=!1}a(Gy,"endWritable");function Yy(e,t,r){var n=e.entry;for(e.entry=null;n;){var o=n.callback;t.pendingcb--,o(r),n=n.next}t.corkedRequestsFree.next=e}a(Yy,"onCorkedFinish");Object.defineProperty(ne.prototype,"destroyed",{get:a(function(){return this._writableState===void 0?!1:this._writableState.destroyed},"get"),set:a(function(e){this._writableState&&(this._writableState.destroyed=e)},"set")});ne.prototype.destroy=zc.destroy;ne.prototype._undestroy=zc.undestroy;ne.prototype._destroy=function(e,t){this.end(),t(e)}});var yr=P((UT,Hc)=>{"use strict";var Wc=Jn(),Ky=Object.keys||function(e){var t=[];for(var r in e)t.push(r);return t};Hc.exports=At;var Nc=Object.create(rn());Nc.inherits=nn();var jc=Ws(),Ms=qs();Nc.inherits(At,jc);for(Us=Ky(Ms.prototype),ka=0;ka<Us.length;ka++)Ea=Us[ka],At.prototype[Ea]||(At.prototype[Ea]=Ms.prototype[Ea]);var Us,Ea,ka;function At(e){if(!(this instanceof At))return new At(e);jc.call(this,e),Ms.call(this,e),e&&e.readable===!1&&(this.readable=!1),e&&e.writable===!1&&(this.writable=!1),this.allowHalfOpen=!0,e&&e.allowHalfOpen===!1&&(this.allowHalfOpen=!1),this.once("end",Xy)}a(At,"Duplex");Object.defineProperty(At.prototype,"writableHighWaterMark",{enumerable:!1,get:a(function(){return this._writableState.highWaterMark},"get")});function Xy(){this.allowHalfOpen||this._writableState.ended||Wc.nextTick(Jy,this)}a(Xy,"onend");function Jy(e){e.end()}a(Jy,"onEndNT");Object.defineProperty(At.prototype,"destroyed",{get:a(function(){return this._readableState===void 0||this._writableState===void 0?!1:this._readableState.destroyed&&this._writableState.destroyed},"get"),set:a(function(e){this._readableState===void 0||this._writableState===void 0||(this._readableState.destroyed=e,this._writableState.destroyed=e)},"set")});At.prototype._destroy=function(e,t){this.push(null),this.end(),Wc.nextTick(t,e)}});var Hs=P(Zc=>{"use strict";var js=Qn().Buffer,$c=js.isEncoding||function(e){switch(e=""+e,e&&e.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function Qy(e){if(!e)return"utf8";for(var t;;)switch(e){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return e;default:if(t)return;e=(""+e).toLowerCase(),t=!0}}a(Qy,"_normalizeEncoding");function e_(e){var t=Qy(e);if(typeof t!="string"&&(js.isEncoding===$c||!$c(e)))throw new Error("Unknown encoding: "+e);return t||e}a(e_,"normalizeEncoding");Zc.StringDecoder=ni;function ni(e){this.encoding=e_(e);var t;switch(this.encoding){case"utf16le":this.text=o_,this.end=s_,t=4;break;case"utf8":this.fillLast=n_,t=4;break;case"base64":this.text=l_,this.end=u_,t=3;break;default:this.write=f_,this.end=c_;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=js.allocUnsafe(t)}a(ni,"StringDecoder");ni.prototype.write=function(e){if(e.length===0)return"";var t,r;if(this.lastNeed){if(t=this.fillLast(e),t===void 0)return"";r=this.lastNeed,this.lastNeed=0}else r=0;return r<e.length?t?t+this.text(e,r):this.text(e,r):t||""};ni.prototype.end=a_;ni.prototype.text=i_;ni.prototype.fillLast=function(e){if(this.lastNeed<=e.length)return e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,e.length),this.lastNeed-=e.length};function Ns(e){return e<=127?0:e>>5===6?2:e>>4===14?3:e>>3===30?4:e>>6===2?-1:-2}a(Ns,"utf8CheckByte");function t_(e,t,r){var n=t.length-1;if(n<r)return 0;var o=Ns(t[n]);return o>=0?(o>0&&(e.lastNeed=o-1),o):--n<r||o===-2?0:(o=Ns(t[n]),o>=0?(o>0&&(e.lastNeed=o-2),o):--n<r||o===-2?0:(o=Ns(t[n]),o>=0?(o>0&&(o===2?o=0:e.lastNeed=o-3),o):0))}a(t_,"utf8CheckIncomplete");function r_(e,t,r){if((t[0]&192)!==128)return e.lastNeed=0,"\uFFFD";if(e.lastNeed>1&&t.length>1){if((t[1]&192)!==128)return e.lastNeed=1,"\uFFFD";if(e.lastNeed>2&&t.length>2&&(t[2]&192)!==128)return e.lastNeed=2,"\uFFFD"}}a(r_,"utf8CheckExtraBytes");function n_(e){var t=this.lastTotal-this.lastNeed,r=r_(this,e,t);if(r!==void 0)return r;if(this.lastNeed<=e.length)return e.copy(this.lastChar,t,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);e.copy(this.lastChar,t,0,e.length),this.lastNeed-=e.length}a(n_,"utf8FillLast");function i_(e,t){var r=t_(this,e,t);if(!this.lastNeed)return e.toString("utf8",t);this.lastTotal=r;var n=e.length-(r-this.lastNeed);return e.copy(this.lastChar,0,n),e.toString("utf8",t,n)}a(i_,"utf8Text");function a_(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+"\uFFFD":t}a(a_,"utf8End");function o_(e,t){if((e.length-t)%2===0){var r=e.toString("utf16le",t);if(r){var n=r.charCodeAt(r.length-1);if(n>=55296&&n<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1],r.slice(0,-1)}return r}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=e[e.length-1],e.toString("utf16le",t,e.length-1)}a(o_,"utf16Text");function s_(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed){var r=this.lastTotal-this.lastNeed;return t+this.lastChar.toString("utf16le",0,r)}return t}a(s_,"utf16End");function l_(e,t){var r=(e.length-t)%3;return r===0?e.toString("base64",t):(this.lastNeed=3-r,this.lastTotal=3,r===1?this.lastChar[0]=e[e.length-1]:(this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1]),e.toString("base64",t,e.length-r))}a(l_,"base64Text");function u_(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+this.lastChar.toString("base64",0,3-this.lastNeed):t}a(u_,"base64End");function f_(e){return e.toString(this.encoding)}a(f_,"simpleWrite");function c_(e){return e&&e.length?this.write(e):""}a(c_,"simpleEnd")});var Ws=P((HT,id)=>{"use strict";var sn=Jn();id.exports=J;var d_=Tc(),ii;J.ReadableState=Qc;var jT=require("events").EventEmitter,Kc=a(function(e,t){return e.listeners(t).length},"EElistenerCount"),Ys=Ps(),ai=Qn().Buffer,h_=(typeof global<"u"?global:typeof window<"u"?window:typeof self<"u"?self:{}).Uint8Array||function(){};function p_(e){return ai.from(e)}a(p_,"_uint8ArrayToBuffer");function m_(e){return ai.isBuffer(e)||e instanceof h_}a(m_,"_isUint8Array");var Xc=Object.create(rn());Xc.inherits=nn();var $s=require("util"),$=void 0;$s&&$s.debuglog?$=$s.debuglog("stream"):$=a(function(){},"debug");var g_=Cc(),Jc=Ls(),on;Xc.inherits(J,Ys);var Zs=["error","close","destroy","pause","resume"];function b_(e,t,r){if(typeof e.prependListener=="function")return e.prependListener(t,r);!e._events||!e._events[t]?e.on(t,r):d_(e._events[t])?e._events[t].unshift(r):e._events[t]=[r,e._events[t]]}a(b_,"prependListener");function Qc(e,t){ii=ii||yr(),e=e||{};var r=t instanceof ii;this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.readableObjectMode);var n=e.highWaterMark,o=e.readableHighWaterMark,l=this.objectMode?16:16*1024;n||n===0?this.highWaterMark=n:r&&(o||o===0)?this.highWaterMark=o:this.highWaterMark=l,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new g_,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(on||(on=Hs().StringDecoder),this.decoder=new on(e.encoding),this.encoding=e.encoding)}a(Qc,"ReadableState");function J(e){if(ii=ii||yr(),!(this instanceof J))return new J(e);this._readableState=new Qc(e,this),this.readable=!0,e&&(typeof e.read=="function"&&(this._read=e.read),typeof e.destroy=="function"&&(this._destroy=e.destroy)),Ys.call(this)}a(J,"Readable");Object.defineProperty(J.prototype,"destroyed",{get:a(function(){return this._readableState===void 0?!1:this._readableState.destroyed},"get"),set:a(function(e){this._readableState&&(this._readableState.destroyed=e)},"set")});J.prototype.destroy=Jc.destroy;J.prototype._undestroy=Jc.undestroy;J.prototype._destroy=function(e,t){this.push(null),t(e)};J.prototype.push=function(e,t){var r=this._readableState,n;return r.objectMode?n=!0:typeof e=="string"&&(t=t||r.defaultEncoding,t!==r.encoding&&(e=ai.from(e,t),t=""),n=!0),ed(this,e,t,!1,n)};J.prototype.unshift=function(e){return ed(this,e,null,!0,!1)};function ed(e,t,r,n,o){var l=e._readableState;if(t===null)l.reading=!1,w_(e,l);else{var u;o||(u=y_(l,t)),u?e.emit("error",u):l.objectMode||t&&t.length>0?(typeof t!="string"&&!l.objectMode&&Object.getPrototypeOf(t)!==ai.prototype&&(t=p_(t)),n?l.endEmitted?e.emit("error",new Error("stream.unshift() after end event")):Vs(e,l,t,!0):l.ended?e.emit("error",new Error("stream.push() after EOF")):(l.reading=!1,l.decoder&&!r?(t=l.decoder.write(t),l.objectMode||t.length!==0?Vs(e,l,t,!1):td(e,l)):Vs(e,l,t,!1))):n||(l.reading=!1)}return __(l)}a(ed,"readableAddChunk");function Vs(e,t,r,n){t.flowing&&t.length===0&&!t.sync?(e.emit("data",r),e.read(0)):(t.length+=t.objectMode?1:r.length,n?t.buffer.unshift(r):t.buffer.push(r),t.needReadable&&Ca(e)),td(e,t)}a(Vs,"addChunk");function y_(e,t){var r;return!m_(t)&&typeof t!="string"&&t!==void 0&&!e.objectMode&&(r=new TypeError("Invalid non-string/buffer chunk")),r}a(y_,"chunkInvalid");function __(e){return!e.ended&&(e.needReadable||e.length<e.highWaterMark||e.length===0)}a(__,"needMoreData");J.prototype.isPaused=function(){return this._readableState.flowing===!1};J.prototype.setEncoding=function(e){return on||(on=Hs().StringDecoder),this._readableState.decoder=new on(e),this._readableState.encoding=e,this};var Vc=8388608;function v_(e){return e>=Vc?e=Vc:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}a(v_,"computeNewHighWaterMark");function Gc(e,t){return e<=0||t.length===0&&t.ended?0:t.objectMode?1:e!==e?t.flowing&&t.length?t.buffer.head.data.length:t.length:(e>t.highWaterMark&&(t.highWaterMark=v_(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}a(Gc,"howMuchToRead");J.prototype.read=function(e){$("read",e),e=parseInt(e,10);var t=this._readableState,r=e;if(e!==0&&(t.emittedReadable=!1),e===0&&t.needReadable&&(t.length>=t.highWaterMark||t.ended))return $("read: emitReadable",t.length,t.ended),t.length===0&&t.ended?Gs(this):Ca(this),null;if(e=Gc(e,t),e===0&&t.ended)return t.length===0&&Gs(this),null;var n=t.needReadable;$("need readable",n),(t.length===0||t.length-e<t.highWaterMark)&&(n=!0,$("length less than watermark",n)),t.ended||t.reading?(n=!1,$("reading or ended",n)):n&&($("do read"),t.reading=!0,t.sync=!0,t.length===0&&(t.needReadable=!0),this._read(t.highWaterMark),t.sync=!1,t.reading||(e=Gc(r,t)));var o;return e>0?o=rd(e,t):o=null,o===null?(t.needReadable=!0,e=0):t.length-=e,t.length===0&&(t.ended||(t.needReadable=!0),r!==e&&t.ended&&Gs(this)),o!==null&&this.emit("data",o),o};function w_(e,t){if(!t.ended){if(t.decoder){var r=t.decoder.end();r&&r.length&&(t.buffer.push(r),t.length+=t.objectMode?1:r.length)}t.ended=!0,Ca(e)}}a(w_,"onEofChunk");function Ca(e){var t=e._readableState;t.needReadable=!1,t.emittedReadable||($("emitReadable",t.flowing),t.emittedReadable=!0,t.sync?sn.nextTick(Yc,e):Yc(e))}a(Ca,"emitReadable");function Yc(e){$("emit readable"),e.emit("readable"),Ks(e)}a(Yc,"emitReadable_");function td(e,t){t.readingMore||(t.readingMore=!0,sn.nextTick(S_,e,t))}a(td,"maybeReadMore");function S_(e,t){for(var r=t.length;!t.reading&&!t.flowing&&!t.ended&&t.length<t.highWaterMark&&($("maybeReadMore read 0"),e.read(0),r!==t.length);)r=t.length;t.readingMore=!1}a(S_,"maybeReadMore_");J.prototype._read=function(e){this.emit("error",new Error("_read() is not implemented"))};J.prototype.pipe=function(e,t){var r=this,n=this._readableState;switch(n.pipesCount){case 0:n.pipes=e;break;case 1:n.pipes=[n.pipes,e];break;default:n.pipes.push(e);break}n.pipesCount+=1,$("pipe count=%d opts=%j",n.pipesCount,t);var o=(!t||t.end!==!1)&&e!==process.stdout&&e!==process.stderr,l=o?d:k;n.endEmitted?sn.nextTick(l):r.once("end",l),e.on("unpipe",u);function u(S,A){$("onunpipe"),S===r&&A&&A.hasUnpiped===!1&&(A.hasUnpiped=!0,h())}a(u,"onunpipe");function d(){$("onend"),e.end()}a(d,"onend");var m=T_(r);e.on("drain",m);var c=!1;function h(){$("cleanup"),e.removeListener("close",v),e.removeListener("finish",E),e.removeListener("drain",m),e.removeListener("error",w),e.removeListener("unpipe",u),r.removeListener("end",d),r.removeListener("end",k),r.removeListener("data",y),c=!0,n.awaitDrain&&(!e._writableState||e._writableState.needDrain)&&m()}a(h,"cleanup");var x=!1;r.on("data",y);function y(S){$("ondata"),x=!1;var A=e.write(S);A===!1&&!x&&((n.pipesCount===1&&n.pipes===e||n.pipesCount>1&&nd(n.pipes,e)!==-1)&&!c&&($("false write response, pause",n.awaitDrain),n.awaitDrain++,x=!0),r.pause())}a(y,"ondata");function w(S){$("onerror",S),k(),e.removeListener("error",w),Kc(e,"error")===0&&e.emit("error",S)}a(w,"onerror"),b_(e,"error",w);function v(){e.removeListener("finish",E),k()}a(v,"onclose"),e.once("close",v);function E(){$("onfinish"),e.removeListener("close",v),k()}a(E,"onfinish"),e.once("finish",E);function k(){$("unpipe"),r.unpipe(e)}return a(k,"unpipe"),e.emit("pipe",r),n.flowing||($("pipe resume"),r.resume()),e};function T_(e){return function(){var t=e._readableState;$("pipeOnDrain",t.awaitDrain),t.awaitDrain&&t.awaitDrain--,t.awaitDrain===0&&Kc(e,"data")&&(t.flowing=!0,Ks(e))}}a(T_,"pipeOnDrain");J.prototype.unpipe=function(e){var t=this._readableState,r={hasUnpiped:!1};if(t.pipesCount===0)return this;if(t.pipesCount===1)return e&&e!==t.pipes?this:(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,r),this);if(!e){var n=t.pipes,o=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var l=0;l<o;l++)n[l].emit("unpipe",this,{hasUnpiped:!1});return this}var u=nd(t.pipes,e);return u===-1?this:(t.pipes.splice(u,1),t.pipesCount-=1,t.pipesCount===1&&(t.pipes=t.pipes[0]),e.emit("unpipe",this,r),this)};J.prototype.on=function(e,t){var r=Ys.prototype.on.call(this,e,t);if(e==="data")this._readableState.flowing!==!1&&this.resume();else if(e==="readable"){var n=this._readableState;!n.endEmitted&&!n.readableListening&&(n.readableListening=n.needReadable=!0,n.emittedReadable=!1,n.reading?n.length&&Ca(this):sn.nextTick(R_,this))}return r};J.prototype.addListener=J.prototype.on;function R_(e){$("readable nexttick read 0"),e.read(0)}a(R_,"nReadingNextTick");J.prototype.resume=function(){var e=this._readableState;return e.flowing||($("resume"),e.flowing=!0,x_(this,e)),this};function x_(e,t){t.resumeScheduled||(t.resumeScheduled=!0,sn.nextTick(A_,e,t))}a(x_,"resume");function A_(e,t){t.reading||($("resume read 0"),e.read(0)),t.resumeScheduled=!1,t.awaitDrain=0,e.emit("resume"),Ks(e),t.flowing&&!t.reading&&e.read(0)}a(A_,"resume_");J.prototype.pause=function(){return $("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&($("pause"),this._readableState.flowing=!1,this.emit("pause")),this};function Ks(e){var t=e._readableState;for($("flow",t.flowing);t.flowing&&e.read()!==null;);}a(Ks,"flow");J.prototype.wrap=function(e){var t=this,r=this._readableState,n=!1;e.on("end",function(){if($("wrapped end"),r.decoder&&!r.ended){var u=r.decoder.end();u&&u.length&&t.push(u)}t.push(null)}),e.on("data",function(u){if($("wrapped data"),r.decoder&&(u=r.decoder.write(u)),!(r.objectMode&&u==null)&&!(!r.objectMode&&(!u||!u.length))){var d=t.push(u);d||(n=!0,e.pause())}});for(var o in e)this[o]===void 0&&typeof e[o]=="function"&&(this[o]=function(u){return function(){return e[u].apply(e,arguments)}}(o));for(var l=0;l<Zs.length;l++)e.on(Zs[l],this.emit.bind(this,Zs[l]));return this._read=function(u){$("wrapped _read",u),n&&(n=!1,e.resume())},this};Object.defineProperty(J.prototype,"readableHighWaterMark",{enumerable:!1,get:a(function(){return this._readableState.highWaterMark},"get")});J._fromList=rd;function rd(e,t){if(t.length===0)return null;var r;return t.objectMode?r=t.buffer.shift():!e||e>=t.length?(t.decoder?r=t.buffer.join(""):t.buffer.length===1?r=t.buffer.head.data:r=t.buffer.concat(t.length),t.buffer.clear()):r=k_(e,t.buffer,t.decoder),r}a(rd,"fromList");function k_(e,t,r){var n;return e<t.head.data.length?(n=t.head.data.slice(0,e),t.head.data=t.head.data.slice(e)):e===t.head.data.length?n=t.shift():n=r?E_(e,t):C_(e,t),n}a(k_,"fromListPartial");function E_(e,t){var r=t.head,n=1,o=r.data;for(e-=o.length;r=r.next;){var l=r.data,u=e>l.length?l.length:e;if(u===l.length?o+=l:o+=l.slice(0,e),e-=u,e===0){u===l.length?(++n,r.next?t.head=r.next:t.head=t.tail=null):(t.head=r,r.data=l.slice(u));break}++n}return t.length-=n,o}a(E_,"copyFromBufferString");function C_(e,t){var r=ai.allocUnsafe(e),n=t.head,o=1;for(n.data.copy(r),e-=n.data.length;n=n.next;){var l=n.data,u=e>l.length?l.length:e;if(l.copy(r,r.length-e,0,u),e-=u,e===0){u===l.length?(++o,n.next?t.head=n.next:t.head=t.tail=null):(t.head=n,n.data=l.slice(u));break}++o}return t.length-=o,r}a(C_,"copyFromBuffer");function Gs(e){var t=e._readableState;if(t.length>0)throw new Error('"endReadable()" called on non-empty stream');t.endEmitted||(t.ended=!0,sn.nextTick(P_,t,e))}a(Gs,"endReadable");function P_(e,t){!e.endEmitted&&e.length===0&&(e.endEmitted=!0,t.readable=!1,t.emit("end"))}a(P_,"endReadableNT");function nd(e,t){for(var r=0,n=e.length;r<n;r++)if(e[r]===t)return r;return-1}a(nd,"indexOf")});var Xs=P((ZT,sd)=>{"use strict";sd.exports=kt;var Pa=yr(),od=Object.create(rn());od.inherits=nn();od.inherits(kt,Pa);function I_(e,t){var r=this._transformState;r.transforming=!1;var n=r.writecb;if(!n)return this.emit("error",new Error("write callback called multiple times"));r.writechunk=null,r.writecb=null,t!=null&&this.push(t),n(e);var o=this._readableState;o.reading=!1,(o.needReadable||o.length<o.highWaterMark)&&this._read(o.highWaterMark)}a(I_,"afterTransform");function kt(e){if(!(this instanceof kt))return new kt(e);Pa.call(this,e),this._transformState={afterTransform:I_.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,e&&(typeof e.transform=="function"&&(this._transform=e.transform),typeof e.flush=="function"&&(this._flush=e.flush)),this.on("prefinish",F_)}a(kt,"Transform");function F_(){var e=this;typeof this._flush=="function"?this._flush(function(t,r){ad(e,t,r)}):ad(this,null,null)}a(F_,"prefinish");kt.prototype.push=function(e,t){return this._transformState.needTransform=!1,Pa.prototype.push.call(this,e,t)};kt.prototype._transform=function(e,t,r){throw new Error("_transform() is not implemented")};kt.prototype._write=function(e,t,r){var n=this._transformState;if(n.writecb=r,n.writechunk=e,n.writeencoding=t,!n.transforming){var o=this._readableState;(n.needTransform||o.needReadable||o.length<o.highWaterMark)&&this._read(o.highWaterMark)}};kt.prototype._read=function(e){var t=this._transformState;t.writechunk!==null&&t.writecb&&!t.transforming?(t.transforming=!0,this._transform(t.writechunk,t.writeencoding,t.afterTransform)):t.needTransform=!0};kt.prototype._destroy=function(e,t){var r=this;Pa.prototype._destroy.call(this,e,function(n){t(n),r.emit("close")})};function ad(e,t,r){if(t)return e.emit("error",t);if(r!=null&&e.push(r),e._writableState.length)throw new Error("Calling transform done when ws.length != 0");if(e._transformState.transforming)throw new Error("Calling transform done when still transforming");return e.push(null)}a(ad,"done")});var cd=P((GT,fd)=>{"use strict";fd.exports=oi;var ld=Xs(),ud=Object.create(rn());ud.inherits=nn();ud.inherits(oi,ld);function oi(e){if(!(this instanceof oi))return new oi(e);ld.call(this,e)}a(oi,"PassThrough");oi.prototype._transform=function(e,t,r){r(null,e)}});var Js=P((ue,Ia)=>{var lt=require("stream");process.env.READABLE_STREAM==="disable"&<?(Ia.exports=lt,ue=Ia.exports=lt.Readable,ue.Readable=lt.Readable,ue.Writable=lt.Writable,ue.Duplex=lt.Duplex,ue.Transform=lt.Transform,ue.PassThrough=lt.PassThrough,ue.Stream=lt):(ue=Ia.exports=Ws(),ue.Stream=lt||ue,ue.Readable=ue,ue.Writable=qs(),ue.Duplex=yr(),ue.Transform=Xs(),ue.PassThrough=cd())});var Et=P(Ae=>{"use strict";Ae.base64=!0;Ae.array=!0;Ae.string=!0;Ae.arraybuffer=typeof ArrayBuffer<"u"&&typeof Uint8Array<"u";Ae.nodebuffer=typeof Buffer<"u";Ae.uint8array=typeof Uint8Array<"u";if(typeof ArrayBuffer>"u")Ae.blob=!1;else{Qs=new ArrayBuffer(0);try{Ae.blob=new Blob([Qs],{type:"application/zip"}).size===0}catch{try{dd=self.BlobBuilder||self.WebKitBlobBuilder||self.MozBlobBuilder||self.MSBlobBuilder,el=new dd,el.append(Qs),Ae.blob=el.getBlob("application/zip").size===0}catch{Ae.blob=!1}}}var Qs,dd,el;try{Ae.nodestream=!!Js().Readable}catch{Ae.nodestream=!1}});var rl=P(tl=>{"use strict";var O_=ee(),D_=Et(),ut="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";tl.encode=function(e){for(var t=[],r,n,o,l,u,d,m,c=0,h=e.length,x=h,y=O_.getTypeOf(e)!=="string";c<e.length;)x=h-c,y?(r=e[c++],n=c<h?e[c++]:0,o=c<h?e[c++]:0):(r=e.charCodeAt(c++),n=c<h?e.charCodeAt(c++):0,o=c<h?e.charCodeAt(c++):0),l=r>>2,u=(r&3)<<4|n>>4,d=x>1?(n&15)<<2|o>>6:64,m=x>2?o&63:64,t.push(ut.charAt(l)+ut.charAt(u)+ut.charAt(d)+ut.charAt(m));return t.join("")};tl.decode=function(e){var t,r,n,o,l,u,d,m=0,c=0,h="data:";if(e.substr(0,h.length)===h)throw new Error("Invalid base64 input, it looks like a data url.");e=e.replace(/[^A-Za-z0-9+/=]/g,"");var x=e.length*3/4;if(e.charAt(e.length-1)===ut.charAt(64)&&x--,e.charAt(e.length-2)===ut.charAt(64)&&x--,x%1!==0)throw new Error("Invalid base64 input, bad content length.");var y;for(D_.uint8array?y=new Uint8Array(x|0):y=new Array(x|0);m<e.length;)o=ut.indexOf(e.charAt(m++)),l=ut.indexOf(e.charAt(m++)),u=ut.indexOf(e.charAt(m++)),d=ut.indexOf(e.charAt(m++)),t=o<<2|l>>4,r=(l&15)<<4|u>>2,n=(u&3)<<6|d,y[c++]=t,u!==64&&(y[c++]=r),d!==64&&(y[c++]=n);return y}});var si=P((JT,hd)=>{"use strict";hd.exports={isNode:typeof Buffer<"u",newBufferFrom:a(function(e,t){if(Buffer.from&&Buffer.from!==Uint8Array.from)return Buffer.from(e,t);if(typeof e=="number")throw new Error('The "data" argument must not be a number');return new Buffer(e,t)},"newBufferFrom"),allocBuffer:a(function(e){if(Buffer.alloc)return Buffer.alloc(e);var t=new Buffer(e);return t.fill(0),t},"allocBuffer"),isBuffer:a(function(e){return Buffer.isBuffer(e)},"isBuffer"),isStream:a(function(e){return e&&typeof e.on=="function"&&typeof e.pause=="function"&&typeof e.resume=="function"},"isStream")}});var bd=P((eR,gd)=>{"use strict";var pd=global.MutationObserver||global.WebKitMutationObserver,ln;process.browser?pd?(nl=0,md=new pd(li),il=global.document.createTextNode(""),md.observe(il,{characterData:!0}),ln=a(function(){il.data=nl=++nl%2},"scheduleDrain")):!global.setImmediate&&typeof global.MessageChannel<"u"?(al=new global.MessageChannel,al.port1.onmessage=li,ln=a(function(){al.port2.postMessage(0)},"scheduleDrain")):"document"in global&&"onreadystatechange"in global.document.createElement("script")?ln=a(function(){var e=global.document.createElement("script");e.onreadystatechange=function(){li(),e.onreadystatechange=null,e.parentNode.removeChild(e),e=null},global.document.documentElement.appendChild(e)},"scheduleDrain"):ln=a(function(){setTimeout(li,0)},"scheduleDrain"):ln=a(function(){process.nextTick(li)},"scheduleDrain");var nl,md,il,al,ol,ui=[];function li(){ol=!0;for(var e,t,r=ui.length;r;){for(t=ui,ui=[],e=-1;++e<r;)t[e]();r=ui.length}ol=!1}a(li,"nextTick");gd.exports=B_;function B_(e){ui.push(e)===1&&!ol&&ln()}a(B_,"immediate")});var Rd=P((rR,Td)=>{"use strict";var yd=bd();function un(){}a(un,"INTERNAL");var he={},_d=["REJECTED"],sl=["FULFILLED"],vd=["PENDING"];process.browser||(fi=["UNHANDLED"]);var fi;Td.exports=$t;function $t(e){if(typeof e!="function")throw new TypeError("resolver must be a function");this.state=vd,this.queue=[],this.outcome=void 0,process.browser||(this.handled=fi),e!==un&&wd(this,e)}a($t,"Promise");$t.prototype.finally=function(e){if(typeof e!="function")return this;var t=this.constructor;return this.then(r,n);function r(o){function l(){return o}return a(l,"yes"),t.resolve(e()).then(l)}function n(o){function l(){throw o}return a(l,"no"),t.resolve(e()).then(l)}};$t.prototype.catch=function(e){return this.then(null,e)};$t.prototype.then=function(e,t){if(typeof e!="function"&&this.state===sl||typeof t!="function"&&this.state===_d)return this;var r=new this.constructor(un);if(process.browser||this.handled===fi&&(this.handled=null),this.state!==vd){var n=this.state===sl?e:t;ll(r,n,this.outcome)}else this.queue.push(new ci(r,e,t));return r};function ci(e,t,r){this.promise=e,typeof t=="function"&&(this.onFulfilled=t,this.callFulfilled=this.otherCallFulfilled),typeof r=="function"&&(this.onRejected=r,this.callRejected=this.otherCallRejected)}a(ci,"QueueItem");ci.prototype.callFulfilled=function(e){he.resolve(this.promise,e)};ci.prototype.otherCallFulfilled=function(e){ll(this.promise,this.onFulfilled,e)};ci.prototype.callRejected=function(e){he.reject(this.promise,e)};ci.prototype.otherCallRejected=function(e){ll(this.promise,this.onRejected,e)};function ll(e,t,r){yd(function(){var n;try{n=t(r)}catch(o){return he.reject(e,o)}n===e?he.reject(e,new TypeError("Cannot resolve promise with itself")):he.resolve(e,n)})}a(ll,"unwrap");he.resolve=function(e,t){var r=Sd(L_,t);if(r.status==="error")return he.reject(e,r.value);var n=r.value;if(n)wd(e,n);else{e.state=sl,e.outcome=t;for(var o=-1,l=e.queue.length;++o<l;)e.queue[o].callFulfilled(t)}return e};he.reject=function(e,t){e.state=_d,e.outcome=t,process.browser||e.handled===fi&&yd(function(){e.handled===fi&&process.emit("unhandledRejection",t,e)});for(var r=-1,n=e.queue.length;++r<n;)e.queue[r].callRejected(t);return e};function L_(e){var t=e&&e.then;if(e&&(typeof e=="object"||typeof e=="function")&&typeof t=="function")return a(function(){t.apply(e,arguments)},"appyThen")}a(L_,"getThen");function wd(e,t){var r=!1;function n(d){r||(r=!0,he.reject(e,d))}a(n,"onError");function o(d){r||(r=!0,he.resolve(e,d))}a(o,"onSuccess");function l(){t(o,n)}a(l,"tryToUnwrap");var u=Sd(l);u.status==="error"&&n(u.value)}a(wd,"safelyResolveThenable");function Sd(e,t){var r={};try{r.value=e(t),r.status="success"}catch(n){r.status="error",r.value=n}return r}a(Sd,"tryCatch");$t.resolve=z_;function z_(e){return e instanceof this?e:he.resolve(new this(un),e)}a(z_,"resolve");$t.reject=q_;function q_(e){var t=new this(un);return he.reject(t,e)}a(q_,"reject");$t.all=U_;function U_(e){var t=this;if(Object.prototype.toString.call(e)!=="[object Array]")return this.reject(new TypeError("must be an array"));var r=e.length,n=!1;if(!r)return this.resolve([]);for(var o=new Array(r),l=0,u=-1,d=new this(un);++u<r;)m(e[u],u);return d;function m(c,h){t.resolve(c).then(x,function(y){n||(n=!0,he.reject(d,y))});function x(y){o[h]=y,++l===r&&!n&&(n=!0,he.resolve(d,o))}a(x,"resolveFromAll")}}a(U_,"all");$t.race=M_;function M_(e){var t=this;if(Object.prototype.toString.call(e)!=="[object Array]")return this.reject(new TypeError("must be an array"));var r=e.length,n=!1;if(!r)return this.resolve([]);for(var o=-1,l=new this(un);++o<r;)u(e[o]);return l;function u(d){t.resolve(d).then(function(m){n||(n=!0,he.resolve(l,m))},function(m){n||(n=!0,he.reject(l,m))})}}a(M_,"race")});var fn=P((iR,xd)=>{"use strict";var ul=null;typeof Promise<"u"?ul=Promise:ul=Rd();xd.exports={Promise:ul}});var kd=P(Ad=>{(function(e,t){"use strict";if(e.setImmediate)return;var r=1,n={},o=!1,l=e.document,u;function d(A){typeof A!="function"&&(A=new Function(""+A));for(var C=new Array(arguments.length-1),T=0;T<C.length;T++)C[T]=arguments[T+1];var R={callback:A,args:C};return n[r]=R,u(r),r++}a(d,"setImmediate");function m(A){delete n[A]}a(m,"clearImmediate");function c(A){var C=A.callback,T=A.args;switch(T.length){case 0:C();break;case 1:C(T[0]);break;case 2:C(T[0],T[1]);break;case 3:C(T[0],T[1],T[2]);break;default:C.apply(t,T);break}}a(c,"run");function h(A){if(o)setTimeout(h,0,A);else{var C=n[A];if(C){o=!0;try{c(C)}finally{m(A),o=!1}}}}a(h,"runIfPresent");function x(){u=a(function(A){process.nextTick(function(){h(A)})},"registerImmediate")}a(x,"installNextTickImplementation");function y(){if(e.postMessage&&!e.importScripts){var A=!0,C=e.onmessage;return e.onmessage=function(){A=!1},e.postMessage("","*"),e.onmessage=C,A}}a(y,"canUsePostMessage");function w(){var A="setImmediate$"+Math.random()+"$",C=a(function(T){T.source===e&&typeof T.data=="string"&&T.data.indexOf(A)===0&&h(+T.data.slice(A.length))},"onGlobalMessage");e.addEventListener?e.addEventListener("message",C,!1):e.attachEvent("onmessage",C),u=a(function(T){e.postMessage(A+T,"*")},"registerImmediate")}a(w,"installPostMessageImplementation");function v(){var A=new MessageChannel;A.port1.onmessage=function(C){var T=C.data;h(T)},u=a(function(C){A.port2.postMessage(C)},"registerImmediate")}a(v,"installMessageChannelImplementation");function E(){var A=l.documentElement;u=a(function(C){var T=l.createElement("script");T.onreadystatechange=function(){h(C),T.onreadystatechange=null,A.removeChild(T),T=null},A.appendChild(T)},"registerImmediate")}a(E,"installReadyStateChangeImplementation");function k(){u=a(function(A){setTimeout(h,0,A)},"registerImmediate")}a(k,"installSetTimeoutImplementation");var S=Object.getPrototypeOf&&Object.getPrototypeOf(e);S=S&&S.setTimeout?S:e,{}.toString.call(e.process)==="[object process]"?x():y()?w():e.MessageChannel?v():l&&"onreadystatechange"in l.createElement("script")?E():k(),S.setImmediate=d,S.clearImmediate=m})(typeof self>"u"?typeof global>"u"?Ad:global:self)});var ee=P(ie=>{"use strict";var Zt=Et(),W_=rl(),cn=si(),fl=fn();kd();function N_(e){var t=null;return Zt.uint8array?t=new Uint8Array(e.length):t=new Array(e.length),Oa(e,t)}a(N_,"string2binary");ie.newBlob=function(e,t){ie.checkSupport("blob");try{return new Blob([e],{type:t})}catch{try{var r=self.BlobBuilder||self.WebKitBlobBuilder||self.MozBlobBuilder||self.MSBlobBuilder,n=new r;return n.append(e),n.getBlob(t)}catch{throw new Error("Bug : can't construct the Blob.")}}};function di(e){return e}a(di,"identity");function Oa(e,t){for(var r=0;r<e.length;++r)t[r]=e.charCodeAt(r)&255;return t}a(Oa,"stringToArrayLike");var Fa={stringifyByChunk:a(function(e,t,r){var n=[],o=0,l=e.length;if(l<=r)return String.fromCharCode.apply(null,e);for(;o<l;)t==="array"||t==="nodebuffer"?n.push(String.fromCharCode.apply(null,e.slice(o,Math.min(o+r,l)))):n.push(String.fromCharCode.apply(null,e.subarray(o,Math.min(o+r,l)))),o+=r;return n.join("")},"stringifyByChunk"),stringifyByChar:a(function(e){for(var t="",r=0;r<e.length;r++)t+=String.fromCharCode(e[r]);return t},"stringifyByChar"),applyCanBeUsed:{uint8array:function(){try{return Zt.uint8array&&String.fromCharCode.apply(null,new Uint8Array(1)).length===1}catch{return!1}}(),nodebuffer:function(){try{return Zt.nodebuffer&&String.fromCharCode.apply(null,cn.allocBuffer(1)).length===1}catch{return!1}}()}};function hi(e){var t=65536,r=ie.getTypeOf(e),n=!0;if(r==="uint8array"?n=Fa.applyCanBeUsed.uint8array:r==="nodebuffer"&&(n=Fa.applyCanBeUsed.nodebuffer),n)for(;t>1;)try{return Fa.stringifyByChunk(e,r,t)}catch{t=Math.floor(t/2)}return Fa.stringifyByChar(e)}a(hi,"arrayLikeToString");ie.applyFromCharCode=hi;function Da(e,t){for(var r=0;r<e.length;r++)t[r]=e[r];return t}a(Da,"arrayLikeToArrayLike");var Vt={};Vt.string={string:di,array:a(function(e){return Oa(e,new Array(e.length))},"array"),arraybuffer:a(function(e){return Vt.string.uint8array(e).buffer},"arraybuffer"),uint8array:a(function(e){return Oa(e,new Uint8Array(e.length))},"uint8array"),nodebuffer:a(function(e){return Oa(e,cn.allocBuffer(e.length))},"nodebuffer")};Vt.array={string:hi,array:di,arraybuffer:a(function(e){return new Uint8Array(e).buffer},"arraybuffer"),uint8array:a(function(e){return new Uint8Array(e)},"uint8array"),nodebuffer:a(function(e){return cn.newBufferFrom(e)},"nodebuffer")};Vt.arraybuffer={string:a(function(e){return hi(new Uint8Array(e))},"string"),array:a(function(e){return Da(new Uint8Array(e),new Array(e.byteLength))},"array"),arraybuffer:di,uint8array:a(function(e){return new Uint8Array(e)},"uint8array"),nodebuffer:a(function(e){return cn.newBufferFrom(new Uint8Array(e))},"nodebuffer")};Vt.uint8array={string:hi,array:a(function(e){return Da(e,new Array(e.length))},"array"),arraybuffer:a(function(e){return e.buffer},"arraybuffer"),uint8array:di,nodebuffer:a(function(e){return cn.newBufferFrom(e)},"nodebuffer")};Vt.nodebuffer={string:hi,array:a(function(e){return Da(e,new Array(e.length))},"array"),arraybuffer:a(function(e){return Vt.nodebuffer.uint8array(e).buffer},"arraybuffer"),uint8array:a(function(e){return Da(e,new Uint8Array(e.length))},"uint8array"),nodebuffer:di};ie.transformTo=function(e,t){if(t||(t=""),!e)return t;ie.checkSupport(e);var r=ie.getTypeOf(t),n=Vt[r][e](t);return n};ie.resolve=function(e){for(var t=e.split("/"),r=[],n=0;n<t.length;n++){var o=t[n];o==="."||o===""&&n!==0&&n!==t.length-1||(o===".."?r.pop():r.push(o))}return r.join("/")};ie.getTypeOf=function(e){if(typeof e=="string")return"string";if(Object.prototype.toString.call(e)==="[object Array]")return"array";if(Zt.nodebuffer&&cn.isBuffer(e))return"nodebuffer";if(Zt.uint8array&&e instanceof Uint8Array)return"uint8array";if(Zt.arraybuffer&&e instanceof ArrayBuffer)return"arraybuffer"};ie.checkSupport=function(e){var t=Zt[e.toLowerCase()];if(!t)throw new Error(e+" is not supported by this platform")};ie.MAX_VALUE_16BITS=65535;ie.MAX_VALUE_32BITS=-1;ie.pretty=function(e){var t="",r,n;for(n=0;n<(e||"").length;n++)r=e.charCodeAt(n),t+="\\x"+(r<16?"0":"")+r.toString(16).toUpperCase();return t};ie.delay=function(e,t,r){setImmediate(function(){e.apply(r||null,t||[])})};ie.inherits=function(e,t){var r=a(function(){},"Obj");r.prototype=t.prototype,e.prototype=new r};ie.extend=function(){var e={},t,r;for(t=0;t<arguments.length;t++)for(r in arguments[t])Object.prototype.hasOwnProperty.call(arguments[t],r)&&typeof e[r]>"u"&&(e[r]=arguments[t][r]);return e};ie.prepareContent=function(e,t,r,n,o){var l=fl.Promise.resolve(t).then(function(u){var d=Zt.blob&&(u instanceof Blob||["[object File]","[object Blob]"].indexOf(Object.prototype.toString.call(u))!==-1);return d&&typeof FileReader<"u"?new fl.Promise(function(m,c){var h=new FileReader;h.onload=function(x){m(x.target.result)},h.onerror=function(x){c(x.target.error)},h.readAsArrayBuffer(u)}):u});return l.then(function(u){var d=ie.getTypeOf(u);return d?(d==="arraybuffer"?u=ie.transformTo("uint8array",u):d==="string"&&(o?u=W_.decode(u):r&&n!==!0&&(u=N_(u))),u):fl.Promise.reject(new Error("Can't read the data of '"+e+"'. Is it in a supported JavaScript type (String, Blob, ArrayBuffer, etc) ?"))})}});var ke=P((uR,Cd)=>{"use strict";function Ed(e){this.name=e||"default",this.streamInfo={},this.generatedError=null,this.extraStreamInfo={},this.isPaused=!0,this.isFinished=!1,this.isLocked=!1,this._listeners={data:[],end:[],error:[]},this.previous=null}a(Ed,"GenericWorker");Ed.prototype={push:a(function(e){this.emit("data",e)},"push"),end:a(function(){if(this.isFinished)return!1;this.flush();try{this.emit("end"),this.cleanUp(),this.isFinished=!0}catch(e){this.emit("error",e)}return!0},"end"),error:a(function(e){return this.isFinished?!1:(this.isPaused?this.generatedError=e:(this.isFinished=!0,this.emit("error",e),this.previous&&this.previous.error(e),this.cleanUp()),!0)},"error"),on:a(function(e,t){return this._listeners[e].push(t),this},"on"),cleanUp:a(function(){this.streamInfo=this.generatedError=this.extraStreamInfo=null,this._listeners=[]},"cleanUp"),emit:a(function(e,t){if(this._listeners[e])for(var r=0;r<this._listeners[e].length;r++)this._listeners[e][r].call(this,t)},"emit"),pipe:a(function(e){return e.registerPrevious(this)},"pipe"),registerPrevious:a(function(e){if(this.isLocked)throw new Error("The stream '"+this+"' has already been used.");this.streamInfo=e.streamInfo,this.mergeStreamInfo(),this.previous=e;var t=this;return e.on("data",function(r){t.processChunk(r)}),e.on("end",function(){t.end()}),e.on("error",function(r){t.error(r)}),this},"registerPrevious"),pause:a(function(){return this.isPaused||this.isFinished?!1:(this.isPaused=!0,this.previous&&this.previous.pause(),!0)},"pause"),resume:a(function(){if(!this.isPaused||this.isFinished)return!1;this.isPaused=!1;var e=!1;return this.generatedError&&(this.error(this.generatedError),e=!0),this.previous&&this.previous.resume(),!e},"resume"),flush:a(function(){},"flush"),processChunk:a(function(e){this.push(e)},"processChunk"),withStreamInfo:a(function(e,t){return this.extraStreamInfo[e]=t,this.mergeStreamInfo(),this},"withStreamInfo"),mergeStreamInfo:a(function(){for(var e in this.extraStreamInfo)Object.prototype.hasOwnProperty.call(this.extraStreamInfo,e)&&(this.streamInfo[e]=this.extraStreamInfo[e])},"mergeStreamInfo"),lock:a(function(){if(this.isLocked)throw new Error("The stream '"+this+"' has already been used.");this.isLocked=!0,this.previous&&this.previous.lock()},"lock"),toString:a(function(){var e="Worker "+this.name;return this.previous?this.previous+" -> "+e:e},"toString")};Cd.exports=Ed});var hn=P(Gt=>{"use strict";var dn=ee(),_r=Et(),j_=si(),Ba=ke(),pi=new Array(256);for(Ct=0;Ct<256;Ct++)pi[Ct]=Ct>=252?6:Ct>=248?5:Ct>=240?4:Ct>=224?3:Ct>=192?2:1;var Ct;pi[254]=pi[254]=1;var H_=a(function(e){var t,r,n,o,l,u=e.length,d=0;for(o=0;o<u;o++)r=e.charCodeAt(o),(r&64512)===55296&&o+1<u&&(n=e.charCodeAt(o+1),(n&64512)===56320&&(r=65536+(r-55296<<10)+(n-56320),o++)),d+=r<128?1:r<2048?2:r<65536?3:4;for(_r.uint8array?t=new Uint8Array(d):t=new Array(d),l=0,o=0;l<d;o++)r=e.charCodeAt(o),(r&64512)===55296&&o+1<u&&(n=e.charCodeAt(o+1),(n&64512)===56320&&(r=65536+(r-55296<<10)+(n-56320),o++)),r<128?t[l++]=r:r<2048?(t[l++]=192|r>>>6,t[l++]=128|r&63):r<65536?(t[l++]=224|r>>>12,t[l++]=128|r>>>6&63,t[l++]=128|r&63):(t[l++]=240|r>>>18,t[l++]=128|r>>>12&63,t[l++]=128|r>>>6&63,t[l++]=128|r&63);return t},"string2buf"),$_=a(function(e,t){var r;for(t=t||e.length,t>e.length&&(t=e.length),r=t-1;r>=0&&(e[r]&192)===128;)r--;return r<0||r===0?t:r+pi[e[r]]>t?r:t},"utf8border"),Z_=a(function(e){var t,r,n,o,l=e.length,u=new Array(l*2);for(r=0,t=0;t<l;){if(n=e[t++],n<128){u[r++]=n;continue}if(o=pi[n],o>4){u[r++]=65533,t+=o-1;continue}for(n&=o===2?31:o===3?15:7;o>1&&t<l;)n=n<<6|e[t++]&63,o--;if(o>1){u[r++]=65533;continue}n<65536?u[r++]=n:(n-=65536,u[r++]=55296|n>>10&1023,u[r++]=56320|n&1023)}return u.length!==r&&(u.subarray?u=u.subarray(0,r):u.length=r),dn.applyFromCharCode(u)},"buf2string");Gt.utf8encode=a(function(t){return _r.nodebuffer?j_.newBufferFrom(t,"utf-8"):H_(t)},"utf8encode");Gt.utf8decode=a(function(t){return _r.nodebuffer?dn.transformTo("nodebuffer",t).toString("utf-8"):(t=dn.transformTo(_r.uint8array?"uint8array":"array",t),Z_(t))},"utf8decode");function La(){Ba.call(this,"utf-8 decode"),this.leftOver=null}a(La,"Utf8DecodeWorker");dn.inherits(La,Ba);La.prototype.processChunk=function(e){var t=dn.transformTo(_r.uint8array?"uint8array":"array",e.data);if(this.leftOver&&this.leftOver.length){if(_r.uint8array){var r=t;t=new Uint8Array(r.length+this.leftOver.length),t.set(this.leftOver,0),t.set(r,this.leftOver.length)}else t=this.leftOver.concat(t);this.leftOver=null}var n=$_(t),o=t;n!==t.length&&(_r.uint8array?(o=t.subarray(0,n),this.leftOver=t.subarray(n,t.length)):(o=t.slice(0,n),this.leftOver=t.slice(n,t.length))),this.push({data:Gt.utf8decode(o),meta:e.meta})};La.prototype.flush=function(){this.leftOver&&this.leftOver.length&&(this.push({data:Gt.utf8decode(this.leftOver),meta:{}}),this.leftOver=null)};Gt.Utf8DecodeWorker=La;function cl(){Ba.call(this,"utf-8 encode")}a(cl,"Utf8EncodeWorker");dn.inherits(cl,Ba);cl.prototype.processChunk=function(e){this.push({data:Gt.utf8encode(e.data),meta:e.meta})};Gt.Utf8EncodeWorker=cl});var Od=P((hR,Fd)=>{"use strict";var Pd=ke(),Id=ee();function dl(e){Pd.call(this,"ConvertWorker to "+e),this.destType=e}a(dl,"ConvertWorker");Id.inherits(dl,Pd);dl.prototype.processChunk=function(e){this.push({data:Id.transformTo(this.destType,e.data),meta:e.meta})};Fd.exports=dl});var Ld=P((mR,Bd)=>{"use strict";var Dd=Js().Readable,V_=ee();V_.inherits(hl,Dd);function hl(e,t,r){Dd.call(this,t),this._helper=e;var n=this;e.on("data",function(o,l){n.push(o)||n._helper.pause(),r&&r(l)}).on("error",function(o){n.emit("error",o)}).on("end",function(){n.push(null)})}a(hl,"NodejsStreamOutputAdapter");hl.prototype._read=function(){this._helper.resume()};Bd.exports=hl});var pl=P((bR,Ud)=>{"use strict";var vr=ee(),G_=Od(),Y_=ke(),K_=rl(),X_=Et(),J_=fn(),zd=null;if(X_.nodestream)try{zd=Ld()}catch{}function Q_(e,t,r){switch(e){case"blob":return vr.newBlob(vr.transformTo("arraybuffer",t),r);case"base64":return K_.encode(t);default:return vr.transformTo(e,t)}}a(Q_,"transformZipOutput");function ev(e,t){var r,n=0,o=null,l=0;for(r=0;r<t.length;r++)l+=t[r].length;switch(e){case"string":return t.join("");case"array":return Array.prototype.concat.apply([],t);case"uint8array":for(o=new Uint8Array(l),r=0;r<t.length;r++)o.set(t[r],n),n+=t[r].length;return o;case"nodebuffer":return Buffer.concat(t);default:throw new Error("concat : unsupported type '"+e+"'")}}a(ev,"concat");function tv(e,t){return new J_.Promise(function(r,n){var o=[],l=e._internalType,u=e._outputType,d=e._mimeType;e.on("data",function(m,c){o.push(m),t&&t(c)}).on("error",function(m){o=[],n(m)}).on("end",function(){try{var m=Q_(u,ev(l,o),d);r(m)}catch(c){n(c)}o=[]}).resume()})}a(tv,"accumulate");function qd(e,t,r){var n=t;switch(t){case"blob":case"arraybuffer":n="uint8array";break;case"base64":n="string";break}try{this._internalType=n,this._outputType=t,this._mimeType=r,vr.checkSupport(n),this._worker=e.pipe(new G_(n)),e.lock()}catch(o){this._worker=new Y_("error"),this._worker.error(o)}}a(qd,"StreamHelper");qd.prototype={accumulate:a(function(e){return tv(this,e)},"accumulate"),on:a(function(e,t){var r=this;return e==="data"?this._worker.on(e,function(n){t.call(r,n.data,n.meta)}):this._worker.on(e,function(){vr.delay(t,arguments,r)}),this},"on"),resume:a(function(){return vr.delay(this._worker.resume,[],this._worker),this},"resume"),pause:a(function(){return this._worker.pause(),this},"pause"),toNodejsStream:a(function(e){if(vr.checkSupport("nodestream"),this._outputType!=="nodebuffer")throw new Error(this._outputType+" is not supported by this method");return new zd(this,{objectMode:this._outputType!=="nodebuffer"},e)},"toNodejsStream")};Ud.exports=qd});var ml=P(Ge=>{"use strict";Ge.base64=!1;Ge.binary=!1;Ge.dir=!1;Ge.createFolders=!0;Ge.date=null;Ge.compression=null;Ge.compressionOptions=null;Ge.comment=null;Ge.unixPermissions=null;Ge.dosPermissions=null});var gl=P((vR,Md)=>{"use strict";var za=ee(),qa=ke(),rv=16*1024;function pn(e){qa.call(this,"DataWorker");var t=this;this.dataIsReady=!1,this.index=0,this.max=0,this.data=null,this.type="",this._tickScheduled=!1,e.then(function(r){t.dataIsReady=!0,t.data=r,t.max=r&&r.length||0,t.type=za.getTypeOf(r),t.isPaused||t._tickAndRepeat()},function(r){t.error(r)})}a(pn,"DataWorker");za.inherits(pn,qa);pn.prototype.cleanUp=function(){qa.prototype.cleanUp.call(this),this.data=null};pn.prototype.resume=function(){return qa.prototype.resume.call(this)?(!this._tickScheduled&&this.dataIsReady&&(this._tickScheduled=!0,za.delay(this._tickAndRepeat,[],this)),!0):!1};pn.prototype._tickAndRepeat=function(){this._tickScheduled=!1,!(this.isPaused||this.isFinished)&&(this._tick(),this.isFinished||(za.delay(this._tickAndRepeat,[],this),this._tickScheduled=!0))};pn.prototype._tick=function(){if(this.isPaused||this.isFinished)return!1;var e=rv,t=null,r=Math.min(this.max,this.index+e);if(this.index>=this.max)return this.end();switch(this.type){case"string":t=this.data.substring(this.index,r);break;case"uint8array":t=this.data.subarray(this.index,r);break;case"array":case"nodebuffer":t=this.data.slice(this.index,r);break}return this.index=r,this.push({data:t,meta:{percent:this.max?this.index/this.max*100:0}})};Md.exports=pn});var Ua=P((SR,Nd)=>{"use strict";var nv=ee();function iv(){for(var e,t=[],r=0;r<256;r++){e=r;for(var n=0;n<8;n++)e=e&1?3988292384^e>>>1:e>>>1;t[r]=e}return t}a(iv,"makeTable");var Wd=iv();function av(e,t,r,n){var o=Wd,l=n+r;e=e^-1;for(var u=n;u<l;u++)e=e>>>8^o[(e^t[u])&255];return e^-1}a(av,"crc32");function ov(e,t,r,n){var o=Wd,l=n+r;e=e^-1;for(var u=n;u<l;u++)e=e>>>8^o[(e^t.charCodeAt(u))&255];return e^-1}a(ov,"crc32str");Nd.exports=a(function(t,r){if(typeof t>"u"||!t.length)return 0;var n=nv.getTypeOf(t)!=="string";return n?av(r|0,t,t.length,0):ov(r|0,t,t.length,0)},"crc32wrapper")});var yl=P((RR,Hd)=>{"use strict";var jd=ke(),sv=Ua(),lv=ee();function bl(){jd.call(this,"Crc32Probe"),this.withStreamInfo("crc32",0)}a(bl,"Crc32Probe");lv.inherits(bl,jd);bl.prototype.processChunk=function(e){this.streamInfo.crc32=sv(e.data,this.streamInfo.crc32||0),this.push(e)};Hd.exports=bl});var Zd=P((AR,$d)=>{"use strict";var uv=ee(),_l=ke();function vl(e){_l.call(this,"DataLengthProbe for "+e),this.propName=e,this.withStreamInfo(e,0)}a(vl,"DataLengthProbe");uv.inherits(vl,_l);vl.prototype.processChunk=function(e){if(e){var t=this.streamInfo[this.propName]||0;this.streamInfo[this.propName]=t+e.data.length}_l.prototype.processChunk.call(this,e)};$d.exports=vl});var Ma=P((ER,Yd)=>{"use strict";var Vd=fn(),Gd=gl(),fv=yl(),wl=Zd();function Sl(e,t,r,n,o){this.compressedSize=e,this.uncompressedSize=t,this.crc32=r,this.compression=n,this.compressedContent=o}a(Sl,"CompressedObject");Sl.prototype={getContentWorker:a(function(){var e=new Gd(Vd.Promise.resolve(this.compressedContent)).pipe(this.compression.uncompressWorker()).pipe(new wl("data_length")),t=this;return e.on("end",function(){if(this.streamInfo.data_length!==t.uncompressedSize)throw new Error("Bug : uncompressed data size mismatch")}),e},"getContentWorker"),getCompressedWorker:a(function(){return new Gd(Vd.Promise.resolve(this.compressedContent)).withStreamInfo("compressedSize",this.compressedSize).withStreamInfo("uncompressedSize",this.uncompressedSize).withStreamInfo("crc32",this.crc32).withStreamInfo("compression",this.compression)},"getCompressedWorker")};Sl.createWorkerFrom=function(e,t,r){return e.pipe(new fv).pipe(new wl("uncompressedSize")).pipe(t.compressWorker(r)).pipe(new wl("compressedSize")).withStreamInfo("compression",t)};Yd.exports=Sl});var Qd=P((PR,Jd)=>{"use strict";var cv=pl(),dv=gl(),Tl=hn(),Rl=Ma(),Kd=ke(),xl=a(function(e,t,r){this.name=e,this.dir=r.dir,this.date=r.date,this.comment=r.comment,this.unixPermissions=r.unixPermissions,this.dosPermissions=r.dosPermissions,this._data=t,this._dataBinary=r.binary,this.options={compression:r.compression,compressionOptions:r.compressionOptions}},"ZipObject");xl.prototype={internalStream:a(function(e){var t=null,r="string";try{if(!e)throw new Error("No output type specified.");r=e.toLowerCase();var n=r==="string"||r==="text";(r==="binarystring"||r==="text")&&(r="string"),t=this._decompressWorker();var o=!this._dataBinary;o&&!n&&(t=t.pipe(new Tl.Utf8EncodeWorker)),!o&&n&&(t=t.pipe(new Tl.Utf8DecodeWorker))}catch(l){t=new Kd("error"),t.error(l)}return new cv(t,r,"")},"internalStream"),async:a(function(e,t){return this.internalStream(e).accumulate(t)},"async"),nodeStream:a(function(e,t){return this.internalStream(e||"nodebuffer").toNodejsStream(t)},"nodeStream"),_compressWorker:a(function(e,t){if(this._data instanceof Rl&&this._data.compression.magic===e.magic)return this._data.getCompressedWorker();var r=this._decompressWorker();return this._dataBinary||(r=r.pipe(new Tl.Utf8EncodeWorker)),Rl.createWorkerFrom(r,e,t)},"_compressWorker"),_decompressWorker:a(function(){return this._data instanceof Rl?this._data.getContentWorker():this._data instanceof Kd?this._data:new dv(this._data)},"_decompressWorker")};var Xd=["asText","asBinary","asNodeBuffer","asUint8Array","asArrayBuffer"],hv=a(function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},"removedFn");for(Wa=0;Wa<Xd.length;Wa++)xl.prototype[Xd[Wa]]=hv;var Wa;Jd.exports=xl});var Pt=P(me=>{"use strict";var pv=typeof Uint8Array<"u"&&typeof Uint16Array<"u"&&typeof Int32Array<"u";function mv(e,t){return Object.prototype.hasOwnProperty.call(e,t)}a(mv,"_has");me.assign=function(e){for(var t=Array.prototype.slice.call(arguments,1);t.length;){var r=t.shift();if(r){if(typeof r!="object")throw new TypeError(r+"must be non-object");for(var n in r)mv(r,n)&&(e[n]=r[n])}}return e};me.shrinkBuf=function(e,t){return e.length===t?e:e.subarray?e.subarray(0,t):(e.length=t,e)};var gv={arraySet:a(function(e,t,r,n,o){if(t.subarray&&e.subarray){e.set(t.subarray(r,r+n),o);return}for(var l=0;l<n;l++)e[o+l]=t[r+l]},"arraySet"),flattenChunks:a(function(e){var t,r,n,o,l,u;for(n=0,t=0,r=e.length;t<r;t++)n+=e[t].length;for(u=new Uint8Array(n),o=0,t=0,r=e.length;t<r;t++)l=e[t],u.set(l,o),o+=l.length;return u},"flattenChunks")},bv={arraySet:a(function(e,t,r,n,o){for(var l=0;l<n;l++)e[o+l]=t[r+l]},"arraySet"),flattenChunks:a(function(e){return[].concat.apply([],e)},"flattenChunks")};me.setTyped=function(e){e?(me.Buf8=Uint8Array,me.Buf16=Uint16Array,me.Buf32=Int32Array,me.assign(me,gv)):(me.Buf8=Array,me.Buf16=Array,me.Buf32=Array,me.assign(me,bv))};me.setTyped(pv)});var Sh=P(bn=>{"use strict";var yv=Pt(),_v=4,eh=0,th=1,vv=2;function gn(e){for(var t=e.length;--t>=0;)e[t]=0}a(gn,"zero");var wv=0,sh=1,Sv=2,Tv=3,Rv=258,Fl=29,vi=256,gi=vi+1+Fl,mn=30,Ol=19,lh=2*gi+1,wr=15,Al=16,xv=7,Dl=256,uh=16,fh=17,ch=18,Pl=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0],Na=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],Av=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],dh=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],kv=512,It=new Array((gi+2)*2);gn(It);var mi=new Array(mn*2);gn(mi);var bi=new Array(kv);gn(bi);var yi=new Array(Rv-Tv+1);gn(yi);var Bl=new Array(Fl);gn(Bl);var ja=new Array(mn);gn(ja);function kl(e,t,r,n,o){this.static_tree=e,this.extra_bits=t,this.extra_base=r,this.elems=n,this.max_length=o,this.has_stree=e&&e.length}a(kl,"StaticTreeDesc");var hh,ph,mh;function El(e,t){this.dyn_tree=e,this.max_code=0,this.stat_desc=t}a(El,"TreeDesc");function gh(e){return e<256?bi[e]:bi[256+(e>>>7)]}a(gh,"d_code");function _i(e,t){e.pending_buf[e.pending++]=t&255,e.pending_buf[e.pending++]=t>>>8&255}a(_i,"put_short");function ve(e,t,r){e.bi_valid>Al-r?(e.bi_buf|=t<<e.bi_valid&65535,_i(e,e.bi_buf),e.bi_buf=t>>Al-e.bi_valid,e.bi_valid+=r-Al):(e.bi_buf|=t<<e.bi_valid&65535,e.bi_valid+=r)}a(ve,"send_bits");function ft(e,t,r){ve(e,r[t*2],r[t*2+1])}a(ft,"send_code");function bh(e,t){var r=0;do r|=e&1,e>>>=1,r<<=1;while(--t>0);return r>>>1}a(bh,"bi_reverse");function Ev(e){e.bi_valid===16?(_i(e,e.bi_buf),e.bi_buf=0,e.bi_valid=0):e.bi_valid>=8&&(e.pending_buf[e.pending++]=e.bi_buf&255,e.bi_buf>>=8,e.bi_valid-=8)}a(Ev,"bi_flush");function Cv(e,t){var r=t.dyn_tree,n=t.max_code,o=t.stat_desc.static_tree,l=t.stat_desc.has_stree,u=t.stat_desc.extra_bits,d=t.stat_desc.extra_base,m=t.stat_desc.max_length,c,h,x,y,w,v,E=0;for(y=0;y<=wr;y++)e.bl_count[y]=0;for(r[e.heap[e.heap_max]*2+1]=0,c=e.heap_max+1;c<lh;c++)h=e.heap[c],y=r[r[h*2+1]*2+1]+1,y>m&&(y=m,E++),r[h*2+1]=y,!(h>n)&&(e.bl_count[y]++,w=0,h>=d&&(w=u[h-d]),v=r[h*2],e.opt_len+=v*(y+w),l&&(e.static_len+=v*(o[h*2+1]+w)));if(E!==0){do{for(y=m-1;e.bl_count[y]===0;)y--;e.bl_count[y]--,e.bl_count[y+1]+=2,e.bl_count[m]--,E-=2}while(E>0);for(y=m;y!==0;y--)for(h=e.bl_count[y];h!==0;)x=e.heap[--c],!(x>n)&&(r[x*2+1]!==y&&(e.opt_len+=(y-r[x*2+1])*r[x*2],r[x*2+1]=y),h--)}}a(Cv,"gen_bitlen");function yh(e,t,r){var n=new Array(wr+1),o=0,l,u;for(l=1;l<=wr;l++)n[l]=o=o+r[l-1]<<1;for(u=0;u<=t;u++){var d=e[u*2+1];d!==0&&(e[u*2]=bh(n[d]++,d))}}a(yh,"gen_codes");function Pv(){var e,t,r,n,o,l=new Array(wr+1);for(r=0,n=0;n<Fl-1;n++)for(Bl[n]=r,e=0;e<1<<Pl[n];e++)yi[r++]=n;for(yi[r-1]=n,o=0,n=0;n<16;n++)for(ja[n]=o,e=0;e<1<<Na[n];e++)bi[o++]=n;for(o>>=7;n<mn;n++)for(ja[n]=o<<7,e=0;e<1<<Na[n]-7;e++)bi[256+o++]=n;for(t=0;t<=wr;t++)l[t]=0;for(e=0;e<=143;)It[e*2+1]=8,e++,l[8]++;for(;e<=255;)It[e*2+1]=9,e++,l[9]++;for(;e<=279;)It[e*2+1]=7,e++,l[7]++;for(;e<=287;)It[e*2+1]=8,e++,l[8]++;for(yh(It,gi+1,l),e=0;e<mn;e++)mi[e*2+1]=5,mi[e*2]=bh(e,5);hh=new kl(It,Pl,vi+1,gi,wr),ph=new kl(mi,Na,0,mn,wr),mh=new kl(new Array(0),Av,0,Ol,xv)}a(Pv,"tr_static_init");function _h(e){var t;for(t=0;t<gi;t++)e.dyn_ltree[t*2]=0;for(t=0;t<mn;t++)e.dyn_dtree[t*2]=0;for(t=0;t<Ol;t++)e.bl_tree[t*2]=0;e.dyn_ltree[Dl*2]=1,e.opt_len=e.static_len=0,e.last_lit=e.matches=0}a(_h,"init_block");function vh(e){e.bi_valid>8?_i(e,e.bi_buf):e.bi_valid>0&&(e.pending_buf[e.pending++]=e.bi_buf),e.bi_buf=0,e.bi_valid=0}a(vh,"bi_windup");function Iv(e,t,r,n){vh(e),n&&(_i(e,r),_i(e,~r)),yv.arraySet(e.pending_buf,e.window,t,r,e.pending),e.pending+=r}a(Iv,"copy_block");function rh(e,t,r,n){var o=t*2,l=r*2;return e[o]<e[l]||e[o]===e[l]&&n[t]<=n[r]}a(rh,"smaller");function Cl(e,t,r){for(var n=e.heap[r],o=r<<1;o<=e.heap_len&&(o<e.heap_len&&rh(t,e.heap[o+1],e.heap[o],e.depth)&&o++,!rh(t,n,e.heap[o],e.depth));)e.heap[r]=e.heap[o],r=o,o<<=1;e.heap[r]=n}a(Cl,"pqdownheap");function nh(e,t,r){var n,o,l=0,u,d;if(e.last_lit!==0)do n=e.pending_buf[e.d_buf+l*2]<<8|e.pending_buf[e.d_buf+l*2+1],o=e.pending_buf[e.l_buf+l],l++,n===0?ft(e,o,t):(u=yi[o],ft(e,u+vi+1,t),d=Pl[u],d!==0&&(o-=Bl[u],ve(e,o,d)),n--,u=gh(n),ft(e,u,r),d=Na[u],d!==0&&(n-=ja[u],ve(e,n,d)));while(l<e.last_lit);ft(e,Dl,t)}a(nh,"compress_block");function Il(e,t){var r=t.dyn_tree,n=t.stat_desc.static_tree,o=t.stat_desc.has_stree,l=t.stat_desc.elems,u,d,m=-1,c;for(e.heap_len=0,e.heap_max=lh,u=0;u<l;u++)r[u*2]!==0?(e.heap[++e.heap_len]=m=u,e.depth[u]=0):r[u*2+1]=0;for(;e.heap_len<2;)c=e.heap[++e.heap_len]=m<2?++m:0,r[c*2]=1,e.depth[c]=0,e.opt_len--,o&&(e.static_len-=n[c*2+1]);for(t.max_code=m,u=e.heap_len>>1;u>=1;u--)Cl(e,r,u);c=l;do u=e.heap[1],e.heap[1]=e.heap[e.heap_len--],Cl(e,r,1),d=e.heap[1],e.heap[--e.heap_max]=u,e.heap[--e.heap_max]=d,r[c*2]=r[u*2]+r[d*2],e.depth[c]=(e.depth[u]>=e.depth[d]?e.depth[u]:e.depth[d])+1,r[u*2+1]=r[d*2+1]=c,e.heap[1]=c++,Cl(e,r,1);while(e.heap_len>=2);e.heap[--e.heap_max]=e.heap[1],Cv(e,t),yh(r,m,e.bl_count)}a(Il,"build_tree");function ih(e,t,r){var n,o=-1,l,u=t[0*2+1],d=0,m=7,c=4;for(u===0&&(m=138,c=3),t[(r+1)*2+1]=65535,n=0;n<=r;n++)l=u,u=t[(n+1)*2+1],!(++d<m&&l===u)&&(d<c?e.bl_tree[l*2]+=d:l!==0?(l!==o&&e.bl_tree[l*2]++,e.bl_tree[uh*2]++):d<=10?e.bl_tree[fh*2]++:e.bl_tree[ch*2]++,d=0,o=l,u===0?(m=138,c=3):l===u?(m=6,c=3):(m=7,c=4))}a(ih,"scan_tree");function ah(e,t,r){var n,o=-1,l,u=t[0*2+1],d=0,m=7,c=4;for(u===0&&(m=138,c=3),n=0;n<=r;n++)if(l=u,u=t[(n+1)*2+1],!(++d<m&&l===u)){if(d<c)do ft(e,l,e.bl_tree);while(--d!==0);else l!==0?(l!==o&&(ft(e,l,e.bl_tree),d--),ft(e,uh,e.bl_tree),ve(e,d-3,2)):d<=10?(ft(e,fh,e.bl_tree),ve(e,d-3,3)):(ft(e,ch,e.bl_tree),ve(e,d-11,7));d=0,o=l,u===0?(m=138,c=3):l===u?(m=6,c=3):(m=7,c=4)}}a(ah,"send_tree");function Fv(e){var t;for(ih(e,e.dyn_ltree,e.l_desc.max_code),ih(e,e.dyn_dtree,e.d_desc.max_code),Il(e,e.bl_desc),t=Ol-1;t>=3&&e.bl_tree[dh[t]*2+1]===0;t--);return e.opt_len+=3*(t+1)+5+5+4,t}a(Fv,"build_bl_tree");function Ov(e,t,r,n){var o;for(ve(e,t-257,5),ve(e,r-1,5),ve(e,n-4,4),o=0;o<n;o++)ve(e,e.bl_tree[dh[o]*2+1],3);ah(e,e.dyn_ltree,t-1),ah(e,e.dyn_dtree,r-1)}a(Ov,"send_all_trees");function Dv(e){var t=4093624447,r;for(r=0;r<=31;r++,t>>>=1)if(t&1&&e.dyn_ltree[r*2]!==0)return eh;if(e.dyn_ltree[9*2]!==0||e.dyn_ltree[10*2]!==0||e.dyn_ltree[13*2]!==0)return th;for(r=32;r<vi;r++)if(e.dyn_ltree[r*2]!==0)return th;return eh}a(Dv,"detect_data_type");var oh=!1;function Bv(e){oh||(Pv(),oh=!0),e.l_desc=new El(e.dyn_ltree,hh),e.d_desc=new El(e.dyn_dtree,ph),e.bl_desc=new El(e.bl_tree,mh),e.bi_buf=0,e.bi_valid=0,_h(e)}a(Bv,"_tr_init");function wh(e,t,r,n){ve(e,(wv<<1)+(n?1:0),3),Iv(e,t,r,!0)}a(wh,"_tr_stored_block");function Lv(e){ve(e,sh<<1,3),ft(e,Dl,It),Ev(e)}a(Lv,"_tr_align");function zv(e,t,r,n){var o,l,u=0;e.level>0?(e.strm.data_type===vv&&(e.strm.data_type=Dv(e)),Il(e,e.l_desc),Il(e,e.d_desc),u=Fv(e),o=e.opt_len+3+7>>>3,l=e.static_len+3+7>>>3,l<=o&&(o=l)):o=l=r+5,r+4<=o&&t!==-1?wh(e,t,r,n):e.strategy===_v||l===o?(ve(e,(sh<<1)+(n?1:0),3),nh(e,It,mi)):(ve(e,(Sv<<1)+(n?1:0),3),Ov(e,e.l_desc.max_code+1,e.d_desc.max_code+1,u+1),nh(e,e.dyn_ltree,e.dyn_dtree)),_h(e),n&&vh(e)}a(zv,"_tr_flush_block");function qv(e,t,r){return e.pending_buf[e.d_buf+e.last_lit*2]=t>>>8&255,e.pending_buf[e.d_buf+e.last_lit*2+1]=t&255,e.pending_buf[e.l_buf+e.last_lit]=r&255,e.last_lit++,t===0?e.dyn_ltree[r*2]++:(e.matches++,t--,e.dyn_ltree[(yi[r]+vi+1)*2]++,e.dyn_dtree[gh(t)*2]++),e.last_lit===e.lit_bufsize-1}a(qv,"_tr_tally");bn._tr_init=Bv;bn._tr_stored_block=wh;bn._tr_flush_block=zv;bn._tr_tally=qv;bn._tr_align=Lv});var Ll=P((LR,Th)=>{"use strict";function Uv(e,t,r,n){for(var o=e&65535|0,l=e>>>16&65535|0,u=0;r!==0;){u=r>2e3?2e3:r,r-=u;do o=o+t[n++]|0,l=l+o|0;while(--u);o%=65521,l%=65521}return o|l<<16|0}a(Uv,"adler32");Th.exports=Uv});var zl=P((qR,Rh)=>{"use strict";function Mv(){for(var e,t=[],r=0;r<256;r++){e=r;for(var n=0;n<8;n++)e=e&1?3988292384^e>>>1:e>>>1;t[r]=e}return t}a(Mv,"makeTable");var Wv=Mv();function Nv(e,t,r,n){var o=Wv,l=n+r;e^=-1;for(var u=n;u<l;u++)e=e>>>8^o[(e^t[u])&255];return e^-1}a(Nv,"crc32");Rh.exports=Nv});var Ha=P((MR,xh)=>{"use strict";xh.exports={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}});var Dh=P(ht=>{"use strict";var ge=Pt(),Le=Sh(),Ch=Ll(),Yt=zl(),jv=Ha(),xr=0,Hv=1,$v=3,er=4,Ah=5,dt=0,kh=1,ze=-2,Zv=-3,ql=-5,Vv=-1,Gv=1,$a=2,Yv=3,Kv=4,Xv=0,Jv=2,Ya=8,Qv=9,e0=15,t0=8,r0=29,n0=256,Ml=n0+1+r0,i0=30,a0=19,o0=2*Ml+1,s0=15,j=3,Jt=258,Ye=Jt+j+1,l0=32,Ka=42,Wl=69,Za=73,Va=91,Ga=103,Sr=113,Si=666,ae=1,Ti=2,Tr=3,vn=4,u0=3;function Qt(e,t){return e.msg=jv[t],t}a(Qt,"err");function Eh(e){return(e<<1)-(e>4?9:0)}a(Eh,"rank");function Xt(e){for(var t=e.length;--t>=0;)e[t]=0}a(Xt,"zero");function Kt(e){var t=e.state,r=t.pending;r>e.avail_out&&(r=e.avail_out),r!==0&&(ge.arraySet(e.output,t.pending_buf,t.pending_out,r,e.next_out),e.next_out+=r,t.pending_out+=r,e.total_out+=r,e.avail_out-=r,t.pending-=r,t.pending===0&&(t.pending_out=0))}a(Kt,"flush_pending");function fe(e,t){Le._tr_flush_block(e,e.block_start>=0?e.block_start:-1,e.strstart-e.block_start,t),e.block_start=e.strstart,Kt(e.strm)}a(fe,"flush_block_only");function H(e,t){e.pending_buf[e.pending++]=t}a(H,"put_byte");function wi(e,t){e.pending_buf[e.pending++]=t>>>8&255,e.pending_buf[e.pending++]=t&255}a(wi,"putShortMSB");function f0(e,t,r,n){var o=e.avail_in;return o>n&&(o=n),o===0?0:(e.avail_in-=o,ge.arraySet(t,e.input,e.next_in,o,r),e.state.wrap===1?e.adler=Ch(e.adler,t,o,r):e.state.wrap===2&&(e.adler=Yt(e.adler,t,o,r)),e.next_in+=o,e.total_in+=o,o)}a(f0,"read_buf");function Ph(e,t){var r=e.max_chain_length,n=e.strstart,o,l,u=e.prev_length,d=e.nice_match,m=e.strstart>e.w_size-Ye?e.strstart-(e.w_size-Ye):0,c=e.window,h=e.w_mask,x=e.prev,y=e.strstart+Jt,w=c[n+u-1],v=c[n+u];e.prev_length>=e.good_match&&(r>>=2),d>e.lookahead&&(d=e.lookahead);do if(o=t,!(c[o+u]!==v||c[o+u-1]!==w||c[o]!==c[n]||c[++o]!==c[n+1])){n+=2,o++;do;while(c[++n]===c[++o]&&c[++n]===c[++o]&&c[++n]===c[++o]&&c[++n]===c[++o]&&c[++n]===c[++o]&&c[++n]===c[++o]&&c[++n]===c[++o]&&c[++n]===c[++o]&&n<y);if(l=Jt-(y-n),n=y-Jt,l>u){if(e.match_start=t,u=l,l>=d)break;w=c[n+u-1],v=c[n+u]}}while((t=x[t&h])>m&&--r!==0);return u<=e.lookahead?u:e.lookahead}a(Ph,"longest_match");function Rr(e){var t=e.w_size,r,n,o,l,u;do{if(l=e.window_size-e.lookahead-e.strstart,e.strstart>=t+(t-Ye)){ge.arraySet(e.window,e.window,t,t,0),e.match_start-=t,e.strstart-=t,e.block_start-=t,n=e.hash_size,r=n;do o=e.head[--r],e.head[r]=o>=t?o-t:0;while(--n);n=t,r=n;do o=e.prev[--r],e.prev[r]=o>=t?o-t:0;while(--n);l+=t}if(e.strm.avail_in===0)break;if(n=f0(e.strm,e.window,e.strstart+e.lookahead,l),e.lookahead+=n,e.lookahead+e.insert>=j)for(u=e.strstart-e.insert,e.ins_h=e.window[u],e.ins_h=(e.ins_h<<e.hash_shift^e.window[u+1])&e.hash_mask;e.insert&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[u+j-1])&e.hash_mask,e.prev[u&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=u,u++,e.insert--,!(e.lookahead+e.insert<j)););}while(e.lookahead<Ye&&e.strm.avail_in!==0)}a(Rr,"fill_window");function c0(e,t){var r=65535;for(r>e.pending_buf_size-5&&(r=e.pending_buf_size-5);;){if(e.lookahead<=1){if(Rr(e),e.lookahead===0&&t===xr)return ae;if(e.lookahead===0)break}e.strstart+=e.lookahead,e.lookahead=0;var n=e.block_start+r;if((e.strstart===0||e.strstart>=n)&&(e.lookahead=e.strstart-n,e.strstart=n,fe(e,!1),e.strm.avail_out===0)||e.strstart-e.block_start>=e.w_size-Ye&&(fe(e,!1),e.strm.avail_out===0))return ae}return e.insert=0,t===er?(fe(e,!0),e.strm.avail_out===0?Tr:vn):(e.strstart>e.block_start&&(fe(e,!1),e.strm.avail_out===0),ae)}a(c0,"deflate_stored");function Ul(e,t){for(var r,n;;){if(e.lookahead<Ye){if(Rr(e),e.lookahead<Ye&&t===xr)return ae;if(e.lookahead===0)break}if(r=0,e.lookahead>=j&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+j-1])&e.hash_mask,r=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),r!==0&&e.strstart-r<=e.w_size-Ye&&(e.match_length=Ph(e,r)),e.match_length>=j)if(n=Le._tr_tally(e,e.strstart-e.match_start,e.match_length-j),e.lookahead-=e.match_length,e.match_length<=e.max_lazy_match&&e.lookahead>=j){e.match_length--;do e.strstart++,e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+j-1])&e.hash_mask,r=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart;while(--e.match_length!==0);e.strstart++}else e.strstart+=e.match_length,e.match_length=0,e.ins_h=e.window[e.strstart],e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+1])&e.hash_mask;else n=Le._tr_tally(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++;if(n&&(fe(e,!1),e.strm.avail_out===0))return ae}return e.insert=e.strstart<j-1?e.strstart:j-1,t===er?(fe(e,!0),e.strm.avail_out===0?Tr:vn):e.last_lit&&(fe(e,!1),e.strm.avail_out===0)?ae:Ti}a(Ul,"deflate_fast");function yn(e,t){for(var r,n,o;;){if(e.lookahead<Ye){if(Rr(e),e.lookahead<Ye&&t===xr)return ae;if(e.lookahead===0)break}if(r=0,e.lookahead>=j&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+j-1])&e.hash_mask,r=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),e.prev_length=e.match_length,e.prev_match=e.match_start,e.match_length=j-1,r!==0&&e.prev_length<e.max_lazy_match&&e.strstart-r<=e.w_size-Ye&&(e.match_length=Ph(e,r),e.match_length<=5&&(e.strategy===Gv||e.match_length===j&&e.strstart-e.match_start>4096)&&(e.match_length=j-1)),e.prev_length>=j&&e.match_length<=e.prev_length){o=e.strstart+e.lookahead-j,n=Le._tr_tally(e,e.strstart-1-e.prev_match,e.prev_length-j),e.lookahead-=e.prev_length-1,e.prev_length-=2;do++e.strstart<=o&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+j-1])&e.hash_mask,r=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart);while(--e.prev_length!==0);if(e.match_available=0,e.match_length=j-1,e.strstart++,n&&(fe(e,!1),e.strm.avail_out===0))return ae}else if(e.match_available){if(n=Le._tr_tally(e,0,e.window[e.strstart-1]),n&&fe(e,!1),e.strstart++,e.lookahead--,e.strm.avail_out===0)return ae}else e.match_available=1,e.strstart++,e.lookahead--}return e.match_available&&(n=Le._tr_tally(e,0,e.window[e.strstart-1]),e.match_available=0),e.insert=e.strstart<j-1?e.strstart:j-1,t===er?(fe(e,!0),e.strm.avail_out===0?Tr:vn):e.last_lit&&(fe(e,!1),e.strm.avail_out===0)?ae:Ti}a(yn,"deflate_slow");function d0(e,t){for(var r,n,o,l,u=e.window;;){if(e.lookahead<=Jt){if(Rr(e),e.lookahead<=Jt&&t===xr)return ae;if(e.lookahead===0)break}if(e.match_length=0,e.lookahead>=j&&e.strstart>0&&(o=e.strstart-1,n=u[o],n===u[++o]&&n===u[++o]&&n===u[++o])){l=e.strstart+Jt;do;while(n===u[++o]&&n===u[++o]&&n===u[++o]&&n===u[++o]&&n===u[++o]&&n===u[++o]&&n===u[++o]&&n===u[++o]&&o<l);e.match_length=Jt-(l-o),e.match_length>e.lookahead&&(e.match_length=e.lookahead)}if(e.match_length>=j?(r=Le._tr_tally(e,1,e.match_length-j),e.lookahead-=e.match_length,e.strstart+=e.match_length,e.match_length=0):(r=Le._tr_tally(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++),r&&(fe(e,!1),e.strm.avail_out===0))return ae}return e.insert=0,t===er?(fe(e,!0),e.strm.avail_out===0?Tr:vn):e.last_lit&&(fe(e,!1),e.strm.avail_out===0)?ae:Ti}a(d0,"deflate_rle");function h0(e,t){for(var r;;){if(e.lookahead===0&&(Rr(e),e.lookahead===0)){if(t===xr)return ae;break}if(e.match_length=0,r=Le._tr_tally(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++,r&&(fe(e,!1),e.strm.avail_out===0))return ae}return e.insert=0,t===er?(fe(e,!0),e.strm.avail_out===0?Tr:vn):e.last_lit&&(fe(e,!1),e.strm.avail_out===0)?ae:Ti}a(h0,"deflate_huff");function ct(e,t,r,n,o){this.good_length=e,this.max_lazy=t,this.nice_length=r,this.max_chain=n,this.func=o}a(ct,"Config");var _n;_n=[new ct(0,0,0,0,c0),new ct(4,4,8,4,Ul),new ct(4,5,16,8,Ul),new ct(4,6,32,32,Ul),new ct(4,4,16,16,yn),new ct(8,16,32,32,yn),new ct(8,16,128,128,yn),new ct(8,32,128,256,yn),new ct(32,128,258,1024,yn),new ct(32,258,258,4096,yn)];function p0(e){e.window_size=2*e.w_size,Xt(e.head),e.max_lazy_match=_n[e.level].max_lazy,e.good_match=_n[e.level].good_length,e.nice_match=_n[e.level].nice_length,e.max_chain_length=_n[e.level].max_chain,e.strstart=0,e.block_start=0,e.lookahead=0,e.insert=0,e.match_length=e.prev_length=j-1,e.match_available=0,e.ins_h=0}a(p0,"lm_init");function m0(){this.strm=null,this.status=0,this.pending_buf=null,this.pending_buf_size=0,this.pending_out=0,this.pending=0,this.wrap=0,this.gzhead=null,this.gzindex=0,this.method=Ya,this.last_flush=-1,this.w_size=0,this.w_bits=0,this.w_mask=0,this.window=null,this.window_size=0,this.prev=null,this.head=null,this.ins_h=0,this.hash_size=0,this.hash_bits=0,this.hash_mask=0,this.hash_shift=0,this.block_start=0,this.match_length=0,this.prev_match=0,this.match_available=0,this.strstart=0,this.match_start=0,this.lookahead=0,this.prev_length=0,this.max_chain_length=0,this.max_lazy_match=0,this.level=0,this.strategy=0,this.good_match=0,this.nice_match=0,this.dyn_ltree=new ge.Buf16(o0*2),this.dyn_dtree=new ge.Buf16((2*i0+1)*2),this.bl_tree=new ge.Buf16((2*a0+1)*2),Xt(this.dyn_ltree),Xt(this.dyn_dtree),Xt(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new ge.Buf16(s0+1),this.heap=new ge.Buf16(2*Ml+1),Xt(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new ge.Buf16(2*Ml+1),Xt(this.depth),this.l_buf=0,this.lit_bufsize=0,this.last_lit=0,this.d_buf=0,this.opt_len=0,this.static_len=0,this.matches=0,this.insert=0,this.bi_buf=0,this.bi_valid=0}a(m0,"DeflateState");function Ih(e){var t;return!e||!e.state?Qt(e,ze):(e.total_in=e.total_out=0,e.data_type=Jv,t=e.state,t.pending=0,t.pending_out=0,t.wrap<0&&(t.wrap=-t.wrap),t.status=t.wrap?Ka:Sr,e.adler=t.wrap===2?0:1,t.last_flush=xr,Le._tr_init(t),dt)}a(Ih,"deflateResetKeep");function Fh(e){var t=Ih(e);return t===dt&&p0(e.state),t}a(Fh,"deflateReset");function g0(e,t){return!e||!e.state||e.state.wrap!==2?ze:(e.state.gzhead=t,dt)}a(g0,"deflateSetHeader");function Oh(e,t,r,n,o,l){if(!e)return ze;var u=1;if(t===Vv&&(t=6),n<0?(u=0,n=-n):n>15&&(u=2,n-=16),o<1||o>Qv||r!==Ya||n<8||n>15||t<0||t>9||l<0||l>Kv)return Qt(e,ze);n===8&&(n=9);var d=new m0;return e.state=d,d.strm=e,d.wrap=u,d.gzhead=null,d.w_bits=n,d.w_size=1<<d.w_bits,d.w_mask=d.w_size-1,d.hash_bits=o+7,d.hash_size=1<<d.hash_bits,d.hash_mask=d.hash_size-1,d.hash_shift=~~((d.hash_bits+j-1)/j),d.window=new ge.Buf8(d.w_size*2),d.head=new ge.Buf16(d.hash_size),d.prev=new ge.Buf16(d.w_size),d.lit_bufsize=1<<o+6,d.pending_buf_size=d.lit_bufsize*4,d.pending_buf=new ge.Buf8(d.pending_buf_size),d.d_buf=1*d.lit_bufsize,d.l_buf=3*d.lit_bufsize,d.level=t,d.strategy=l,d.method=r,Fh(e)}a(Oh,"deflateInit2");function b0(e,t){return Oh(e,t,Ya,e0,t0,Xv)}a(b0,"deflateInit");function y0(e,t){var r,n,o,l;if(!e||!e.state||t>Ah||t<0)return e?Qt(e,ze):ze;if(n=e.state,!e.output||!e.input&&e.avail_in!==0||n.status===Si&&t!==er)return Qt(e,e.avail_out===0?ql:ze);if(n.strm=e,r=n.last_flush,n.last_flush=t,n.status===Ka)if(n.wrap===2)e.adler=0,H(n,31),H(n,139),H(n,8),n.gzhead?(H(n,(n.gzhead.text?1:0)+(n.gzhead.hcrc?2:0)+(n.gzhead.extra?4:0)+(n.gzhead.name?8:0)+(n.gzhead.comment?16:0)),H(n,n.gzhead.time&255),H(n,n.gzhead.time>>8&255),H(n,n.gzhead.time>>16&255),H(n,n.gzhead.time>>24&255),H(n,n.level===9?2:n.strategy>=$a||n.level<2?4:0),H(n,n.gzhead.os&255),n.gzhead.extra&&n.gzhead.extra.length&&(H(n,n.gzhead.extra.length&255),H(n,n.gzhead.extra.length>>8&255)),n.gzhead.hcrc&&(e.adler=Yt(e.adler,n.pending_buf,n.pending,0)),n.gzindex=0,n.status=Wl):(H(n,0),H(n,0),H(n,0),H(n,0),H(n,0),H(n,n.level===9?2:n.strategy>=$a||n.level<2?4:0),H(n,u0),n.status=Sr);else{var u=Ya+(n.w_bits-8<<4)<<8,d=-1;n.strategy>=$a||n.level<2?d=0:n.level<6?d=1:n.level===6?d=2:d=3,u|=d<<6,n.strstart!==0&&(u|=l0),u+=31-u%31,n.status=Sr,wi(n,u),n.strstart!==0&&(wi(n,e.adler>>>16),wi(n,e.adler&65535)),e.adler=1}if(n.status===Wl)if(n.gzhead.extra){for(o=n.pending;n.gzindex<(n.gzhead.extra.length&65535)&&!(n.pending===n.pending_buf_size&&(n.gzhead.hcrc&&n.pending>o&&(e.adler=Yt(e.adler,n.pending_buf,n.pending-o,o)),Kt(e),o=n.pending,n.pending===n.pending_buf_size));)H(n,n.gzhead.extra[n.gzindex]&255),n.gzindex++;n.gzhead.hcrc&&n.pending>o&&(e.adler=Yt(e.adler,n.pending_buf,n.pending-o,o)),n.gzindex===n.gzhead.extra.length&&(n.gzindex=0,n.status=Za)}else n.status=Za;if(n.status===Za)if(n.gzhead.name){o=n.pending;do{if(n.pending===n.pending_buf_size&&(n.gzhead.hcrc&&n.pending>o&&(e.adler=Yt(e.adler,n.pending_buf,n.pending-o,o)),Kt(e),o=n.pending,n.pending===n.pending_buf_size)){l=1;break}n.gzindex<n.gzhead.name.length?l=n.gzhead.name.charCodeAt(n.gzindex++)&255:l=0,H(n,l)}while(l!==0);n.gzhead.hcrc&&n.pending>o&&(e.adler=Yt(e.adler,n.pending_buf,n.pending-o,o)),l===0&&(n.gzindex=0,n.status=Va)}else n.status=Va;if(n.status===Va)if(n.gzhead.comment){o=n.pending;do{if(n.pending===n.pending_buf_size&&(n.gzhead.hcrc&&n.pending>o&&(e.adler=Yt(e.adler,n.pending_buf,n.pending-o,o)),Kt(e),o=n.pending,n.pending===n.pending_buf_size)){l=1;break}n.gzindex<n.gzhead.comment.length?l=n.gzhead.comment.charCodeAt(n.gzindex++)&255:l=0,H(n,l)}while(l!==0);n.gzhead.hcrc&&n.pending>o&&(e.adler=Yt(e.adler,n.pending_buf,n.pending-o,o)),l===0&&(n.status=Ga)}else n.status=Ga;if(n.status===Ga&&(n.gzhead.hcrc?(n.pending+2>n.pending_buf_size&&Kt(e),n.pending+2<=n.pending_buf_size&&(H(n,e.adler&255),H(n,e.adler>>8&255),e.adler=0,n.status=Sr)):n.status=Sr),n.pending!==0){if(Kt(e),e.avail_out===0)return n.last_flush=-1,dt}else if(e.avail_in===0&&Eh(t)<=Eh(r)&&t!==er)return Qt(e,ql);if(n.status===Si&&e.avail_in!==0)return Qt(e,ql);if(e.avail_in!==0||n.lookahead!==0||t!==xr&&n.status!==Si){var m=n.strategy===$a?h0(n,t):n.strategy===Yv?d0(n,t):_n[n.level].func(n,t);if((m===Tr||m===vn)&&(n.status=Si),m===ae||m===Tr)return e.avail_out===0&&(n.last_flush=-1),dt;if(m===Ti&&(t===Hv?Le._tr_align(n):t!==Ah&&(Le._tr_stored_block(n,0,0,!1),t===$v&&(Xt(n.head),n.lookahead===0&&(n.strstart=0,n.block_start=0,n.insert=0))),Kt(e),e.avail_out===0))return n.last_flush=-1,dt}return t!==er?dt:n.wrap<=0?kh:(n.wrap===2?(H(n,e.adler&255),H(n,e.adler>>8&255),H(n,e.adler>>16&255),H(n,e.adler>>24&255),H(n,e.total_in&255),H(n,e.total_in>>8&255),H(n,e.total_in>>16&255),H(n,e.total_in>>24&255)):(wi(n,e.adler>>>16),wi(n,e.adler&65535)),Kt(e),n.wrap>0&&(n.wrap=-n.wrap),n.pending!==0?dt:kh)}a(y0,"deflate");function _0(e){var t;return!e||!e.state?ze:(t=e.state.status,t!==Ka&&t!==Wl&&t!==Za&&t!==Va&&t!==Ga&&t!==Sr&&t!==Si?Qt(e,ze):(e.state=null,t===Sr?Qt(e,Zv):dt))}a(_0,"deflateEnd");function v0(e,t){var r=t.length,n,o,l,u,d,m,c,h;if(!e||!e.state||(n=e.state,u=n.wrap,u===2||u===1&&n.status!==Ka||n.lookahead))return ze;for(u===1&&(e.adler=Ch(e.adler,t,r,0)),n.wrap=0,r>=n.w_size&&(u===0&&(Xt(n.head),n.strstart=0,n.block_start=0,n.insert=0),h=new ge.Buf8(n.w_size),ge.arraySet(h,t,r-n.w_size,n.w_size,0),t=h,r=n.w_size),d=e.avail_in,m=e.next_in,c=e.input,e.avail_in=r,e.next_in=0,e.input=t,Rr(n);n.lookahead>=j;){o=n.strstart,l=n.lookahead-(j-1);do n.ins_h=(n.ins_h<<n.hash_shift^n.window[o+j-1])&n.hash_mask,n.prev[o&n.w_mask]=n.head[n.ins_h],n.head[n.ins_h]=o,o++;while(--l);n.strstart=o,n.lookahead=j-1,Rr(n)}return n.strstart+=n.lookahead,n.block_start=n.strstart,n.insert=n.lookahead,n.lookahead=0,n.match_length=n.prev_length=j-1,n.match_available=0,e.next_in=m,e.input=c,e.avail_in=d,n.wrap=u,dt}a(v0,"deflateSetDictionary");ht.deflateInit=b0;ht.deflateInit2=Oh;ht.deflateReset=Fh;ht.deflateResetKeep=Ih;ht.deflateSetHeader=g0;ht.deflate=y0;ht.deflateEnd=_0;ht.deflateSetDictionary=v0;ht.deflateInfo="pako deflate (from Nodeca project)"});var Nl=P(wn=>{"use strict";var Xa=Pt(),Bh=!0,Lh=!0;try{String.fromCharCode.apply(null,[0])}catch{Bh=!1}try{String.fromCharCode.apply(null,new Uint8Array(1))}catch{Lh=!1}var Ri=new Xa.Buf8(256);for(Ft=0;Ft<256;Ft++)Ri[Ft]=Ft>=252?6:Ft>=248?5:Ft>=240?4:Ft>=224?3:Ft>=192?2:1;var Ft;Ri[254]=Ri[254]=1;wn.string2buf=function(e){var t,r,n,o,l,u=e.length,d=0;for(o=0;o<u;o++)r=e.charCodeAt(o),(r&64512)===55296&&o+1<u&&(n=e.charCodeAt(o+1),(n&64512)===56320&&(r=65536+(r-55296<<10)+(n-56320),o++)),d+=r<128?1:r<2048?2:r<65536?3:4;for(t=new Xa.Buf8(d),l=0,o=0;l<d;o++)r=e.charCodeAt(o),(r&64512)===55296&&o+1<u&&(n=e.charCodeAt(o+1),(n&64512)===56320&&(r=65536+(r-55296<<10)+(n-56320),o++)),r<128?t[l++]=r:r<2048?(t[l++]=192|r>>>6,t[l++]=128|r&63):r<65536?(t[l++]=224|r>>>12,t[l++]=128|r>>>6&63,t[l++]=128|r&63):(t[l++]=240|r>>>18,t[l++]=128|r>>>12&63,t[l++]=128|r>>>6&63,t[l++]=128|r&63);return t};function zh(e,t){if(t<65534&&(e.subarray&&Lh||!e.subarray&&Bh))return String.fromCharCode.apply(null,Xa.shrinkBuf(e,t));for(var r="",n=0;n<t;n++)r+=String.fromCharCode(e[n]);return r}a(zh,"buf2binstring");wn.buf2binstring=function(e){return zh(e,e.length)};wn.binstring2buf=function(e){for(var t=new Xa.Buf8(e.length),r=0,n=t.length;r<n;r++)t[r]=e.charCodeAt(r);return t};wn.buf2string=function(e,t){var r,n,o,l,u=t||e.length,d=new Array(u*2);for(n=0,r=0;r<u;){if(o=e[r++],o<128){d[n++]=o;continue}if(l=Ri[o],l>4){d[n++]=65533,r+=l-1;continue}for(o&=l===2?31:l===3?15:7;l>1&&r<u;)o=o<<6|e[r++]&63,l--;if(l>1){d[n++]=65533;continue}o<65536?d[n++]=o:(o-=65536,d[n++]=55296|o>>10&1023,d[n++]=56320|o&1023)}return zh(d,n)};wn.utf8border=function(e,t){var r;for(t=t||e.length,t>e.length&&(t=e.length),r=t-1;r>=0&&(e[r]&192)===128;)r--;return r<0||r===0?t:r+Ri[e[r]]>t?r:t}});var jl=P(($R,qh)=>{"use strict";function w0(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}a(w0,"ZStream");qh.exports=w0});var Nh=P(ki=>{"use strict";var xi=Dh(),Ai=Pt(),$l=Nl(),Zl=Ha(),S0=jl(),Wh=Object.prototype.toString,T0=0,Hl=4,Sn=0,Uh=1,Mh=2,R0=-1,x0=0,A0=8;function Ar(e){if(!(this instanceof Ar))return new Ar(e);this.options=Ai.assign({level:R0,method:A0,chunkSize:16384,windowBits:15,memLevel:8,strategy:x0,to:""},e||{});var t=this.options;t.raw&&t.windowBits>0?t.windowBits=-t.windowBits:t.gzip&&t.windowBits>0&&t.windowBits<16&&(t.windowBits+=16),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new S0,this.strm.avail_out=0;var r=xi.deflateInit2(this.strm,t.level,t.method,t.windowBits,t.memLevel,t.strategy);if(r!==Sn)throw new Error(Zl[r]);if(t.header&&xi.deflateSetHeader(this.strm,t.header),t.dictionary){var n;if(typeof t.dictionary=="string"?n=$l.string2buf(t.dictionary):Wh.call(t.dictionary)==="[object ArrayBuffer]"?n=new Uint8Array(t.dictionary):n=t.dictionary,r=xi.deflateSetDictionary(this.strm,n),r!==Sn)throw new Error(Zl[r]);this._dict_set=!0}}a(Ar,"Deflate");Ar.prototype.push=function(e,t){var r=this.strm,n=this.options.chunkSize,o,l;if(this.ended)return!1;l=t===~~t?t:t===!0?Hl:T0,typeof e=="string"?r.input=$l.string2buf(e):Wh.call(e)==="[object ArrayBuffer]"?r.input=new Uint8Array(e):r.input=e,r.next_in=0,r.avail_in=r.input.length;do{if(r.avail_out===0&&(r.output=new Ai.Buf8(n),r.next_out=0,r.avail_out=n),o=xi.deflate(r,l),o!==Uh&&o!==Sn)return this.onEnd(o),this.ended=!0,!1;(r.avail_out===0||r.avail_in===0&&(l===Hl||l===Mh))&&(this.options.to==="string"?this.onData($l.buf2binstring(Ai.shrinkBuf(r.output,r.next_out))):this.onData(Ai.shrinkBuf(r.output,r.next_out)))}while((r.avail_in>0||r.avail_out===0)&&o!==Uh);return l===Hl?(o=xi.deflateEnd(this.strm),this.onEnd(o),this.ended=!0,o===Sn):(l===Mh&&(this.onEnd(Sn),r.avail_out=0),!0)};Ar.prototype.onData=function(e){this.chunks.push(e)};Ar.prototype.onEnd=function(e){e===Sn&&(this.options.to==="string"?this.result=this.chunks.join(""):this.result=Ai.flattenChunks(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg};function Vl(e,t){var r=new Ar(t);if(r.push(e,!0),r.err)throw r.msg||Zl[r.err];return r.result}a(Vl,"deflate");function k0(e,t){return t=t||{},t.raw=!0,Vl(e,t)}a(k0,"deflateRaw");function E0(e,t){return t=t||{},t.gzip=!0,Vl(e,t)}a(E0,"gzip");ki.Deflate=Ar;ki.deflate=Vl;ki.deflateRaw=k0;ki.gzip=E0});var Hh=P((YR,jh)=>{"use strict";var Ja=30,C0=12;jh.exports=a(function(t,r){var n,o,l,u,d,m,c,h,x,y,w,v,E,k,S,A,C,T,R,F,z,B,M,V,O;n=t.state,o=t.next_in,V=t.input,l=o+(t.avail_in-5),u=t.next_out,O=t.output,d=u-(r-t.avail_out),m=u+(t.avail_out-257),c=n.dmax,h=n.wsize,x=n.whave,y=n.wnext,w=n.window,v=n.hold,E=n.bits,k=n.lencode,S=n.distcode,A=(1<<n.lenbits)-1,C=(1<<n.distbits)-1;e:do{E<15&&(v+=V[o++]<<E,E+=8,v+=V[o++]<<E,E+=8),T=k[v&A];t:for(;;){if(R=T>>>24,v>>>=R,E-=R,R=T>>>16&255,R===0)O[u++]=T&65535;else if(R&16){F=T&65535,R&=15,R&&(E<R&&(v+=V[o++]<<E,E+=8),F+=v&(1<<R)-1,v>>>=R,E-=R),E<15&&(v+=V[o++]<<E,E+=8,v+=V[o++]<<E,E+=8),T=S[v&C];r:for(;;){if(R=T>>>24,v>>>=R,E-=R,R=T>>>16&255,R&16){if(z=T&65535,R&=15,E<R&&(v+=V[o++]<<E,E+=8,E<R&&(v+=V[o++]<<E,E+=8)),z+=v&(1<<R)-1,z>c){t.msg="invalid distance too far back",n.mode=Ja;break e}if(v>>>=R,E-=R,R=u-d,z>R){if(R=z-R,R>x&&n.sane){t.msg="invalid distance too far back",n.mode=Ja;break e}if(B=0,M=w,y===0){if(B+=h-R,R<F){F-=R;do O[u++]=w[B++];while(--R);B=u-z,M=O}}else if(y<R){if(B+=h+y-R,R-=y,R<F){F-=R;do O[u++]=w[B++];while(--R);if(B=0,y<F){R=y,F-=R;do O[u++]=w[B++];while(--R);B=u-z,M=O}}}else if(B+=y-R,R<F){F-=R;do O[u++]=w[B++];while(--R);B=u-z,M=O}for(;F>2;)O[u++]=M[B++],O[u++]=M[B++],O[u++]=M[B++],F-=3;F&&(O[u++]=M[B++],F>1&&(O[u++]=M[B++]))}else{B=u-z;do O[u++]=O[B++],O[u++]=O[B++],O[u++]=O[B++],F-=3;while(F>2);F&&(O[u++]=O[B++],F>1&&(O[u++]=O[B++]))}}else if(R&64){t.msg="invalid distance code",n.mode=Ja;break e}else{T=S[(T&65535)+(v&(1<<R)-1)];continue r}break}}else if(R&64)if(R&32){n.mode=C0;break e}else{t.msg="invalid literal/length code",n.mode=Ja;break e}else{T=k[(T&65535)+(v&(1<<R)-1)];continue t}break}}while(o<l&&u<m);F=E>>3,o-=F,E-=F<<3,v&=(1<<E)-1,t.next_in=o,t.next_out=u,t.avail_in=o<l?5+(l-o):5-(o-l),t.avail_out=u<m?257+(m-u):257-(u-m),n.hold=v,n.bits=E},"inflate_fast")});var Xh=P((XR,Kh)=>{"use strict";var $h=Pt(),Tn=15,Zh=852,Vh=592,Gh=0,Gl=1,Yh=2,P0=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0],I0=[16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78],F0=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0],O0=[16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64];Kh.exports=a(function(t,r,n,o,l,u,d,m){var c=m.bits,h=0,x=0,y=0,w=0,v=0,E=0,k=0,S=0,A=0,C=0,T,R,F,z,B,M=null,V=0,O,le=new $h.Buf16(Tn+1),ce=new $h.Buf16(Tn+1),mt=null,Or=0,Cn,Dr,Bt;for(h=0;h<=Tn;h++)le[h]=0;for(x=0;x<o;x++)le[r[n+x]]++;for(v=c,w=Tn;w>=1&&le[w]===0;w--);if(v>w&&(v=w),w===0)return l[u++]=1<<24|64<<16|0,l[u++]=1<<24|64<<16|0,m.bits=1,0;for(y=1;y<w&&le[y]===0;y++);for(v<y&&(v=y),S=1,h=1;h<=Tn;h++)if(S<<=1,S-=le[h],S<0)return-1;if(S>0&&(t===Gh||w!==1))return-1;for(ce[1]=0,h=1;h<Tn;h++)ce[h+1]=ce[h]+le[h];for(x=0;x<o;x++)r[n+x]!==0&&(d[ce[r[n+x]]++]=x);if(t===Gh?(M=mt=d,O=19):t===Gl?(M=P0,V-=257,mt=I0,Or-=257,O=256):(M=F0,mt=O0,O=-1),C=0,x=0,h=y,B=u,E=v,k=0,F=-1,A=1<<v,z=A-1,t===Gl&&A>Zh||t===Yh&&A>Vh)return 1;for(;;){Cn=h-k,d[x]<O?(Dr=0,Bt=d[x]):d[x]>O?(Dr=mt[Or+d[x]],Bt=M[V+d[x]]):(Dr=96,Bt=0),T=1<<h-k,R=1<<E,y=R;do R-=T,l[B+(C>>k)+R]=Cn<<24|Dr<<16|Bt|0;while(R!==0);for(T=1<<h-1;C&T;)T>>=1;if(T!==0?(C&=T-1,C+=T):C=0,x++,--le[h]===0){if(h===w)break;h=r[n+d[x]]}if(h>v&&(C&z)!==F){for(k===0&&(k=v),B+=y,E=h-k,S=1<<E;E+k<w&&(S-=le[E+k],!(S<=0));)E++,S<<=1;if(A+=1<<E,t===Gl&&A>Zh||t===Yh&&A>Vh)return 1;F=C&z,l[F]=v<<24|E<<16|B-u|0}}return C!==0&&(l[B+C]=h-k<<24|64<<16|0),m.bits=v,0},"inflate_table")});var Fp=P(Ke=>{"use strict";var Ee=Pt(),eu=Ll(),pt=zl(),D0=Hh(),Ei=Xh(),B0=0,Tp=1,Rp=2,Jh=4,L0=5,Qa=6,kr=0,z0=1,q0=2,qe=-2,xp=-3,tu=-4,U0=-5,Qh=8,Ap=1,ep=2,tp=3,rp=4,np=5,ip=6,ap=7,op=8,sp=9,lp=10,ro=11,Ot=12,Yl=13,up=14,Kl=15,fp=16,cp=17,dp=18,hp=19,eo=20,to=21,pp=22,mp=23,gp=24,bp=25,yp=26,Xl=27,_p=28,vp=29,Q=30,ru=31,M0=32,W0=852,N0=592,j0=15,H0=j0;function wp(e){return(e>>>24&255)+(e>>>8&65280)+((e&65280)<<8)+((e&255)<<24)}a(wp,"zswap32");function $0(){this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new Ee.Buf16(320),this.work=new Ee.Buf16(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}a($0,"InflateState");function kp(e){var t;return!e||!e.state?qe:(t=e.state,e.total_in=e.total_out=t.total=0,e.msg="",t.wrap&&(e.adler=t.wrap&1),t.mode=Ap,t.last=0,t.havedict=0,t.dmax=32768,t.head=null,t.hold=0,t.bits=0,t.lencode=t.lendyn=new Ee.Buf32(W0),t.distcode=t.distdyn=new Ee.Buf32(N0),t.sane=1,t.back=-1,kr)}a(kp,"inflateResetKeep");function Ep(e){var t;return!e||!e.state?qe:(t=e.state,t.wsize=0,t.whave=0,t.wnext=0,kp(e))}a(Ep,"inflateReset");function Cp(e,t){var r,n;return!e||!e.state||(n=e.state,t<0?(r=0,t=-t):(r=(t>>4)+1,t<48&&(t&=15)),t&&(t<8||t>15))?qe:(n.window!==null&&n.wbits!==t&&(n.window=null),n.wrap=r,n.wbits=t,Ep(e))}a(Cp,"inflateReset2");function Pp(e,t){var r,n;return e?(n=new $0,e.state=n,n.window=null,r=Cp(e,t),r!==kr&&(e.state=null),r):qe}a(Pp,"inflateInit2");function Z0(e){return Pp(e,H0)}a(Z0,"inflateInit");var Sp=!0,Jl,Ql;function V0(e){if(Sp){var t;for(Jl=new Ee.Buf32(512),Ql=new Ee.Buf32(32),t=0;t<144;)e.lens[t++]=8;for(;t<256;)e.lens[t++]=9;for(;t<280;)e.lens[t++]=7;for(;t<288;)e.lens[t++]=8;for(Ei(Tp,e.lens,0,288,Jl,0,e.work,{bits:9}),t=0;t<32;)e.lens[t++]=5;Ei(Rp,e.lens,0,32,Ql,0,e.work,{bits:5}),Sp=!1}e.lencode=Jl,e.lenbits=9,e.distcode=Ql,e.distbits=5}a(V0,"fixedtables");function Ip(e,t,r,n){var o,l=e.state;return l.window===null&&(l.wsize=1<<l.wbits,l.wnext=0,l.whave=0,l.window=new Ee.Buf8(l.wsize)),n>=l.wsize?(Ee.arraySet(l.window,t,r-l.wsize,l.wsize,0),l.wnext=0,l.whave=l.wsize):(o=l.wsize-l.wnext,o>n&&(o=n),Ee.arraySet(l.window,t,r-n,o,l.wnext),n-=o,n?(Ee.arraySet(l.window,t,r-n,n,0),l.wnext=n,l.whave=l.wsize):(l.wnext+=o,l.wnext===l.wsize&&(l.wnext=0),l.whave<l.wsize&&(l.whave+=o))),0}a(Ip,"updatewindow");function G0(e,t){var r,n,o,l,u,d,m,c,h,x,y,w,v,E,k=0,S,A,C,T,R,F,z,B,M=new Ee.Buf8(4),V,O,le=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!e||!e.state||!e.output||!e.input&&e.avail_in!==0)return qe;r=e.state,r.mode===Ot&&(r.mode=Yl),u=e.next_out,o=e.output,m=e.avail_out,l=e.next_in,n=e.input,d=e.avail_in,c=r.hold,h=r.bits,x=d,y=m,B=kr;e:for(;;)switch(r.mode){case Ap:if(r.wrap===0){r.mode=Yl;break}for(;h<16;){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}if(r.wrap&2&&c===35615){r.check=0,M[0]=c&255,M[1]=c>>>8&255,r.check=pt(r.check,M,2,0),c=0,h=0,r.mode=ep;break}if(r.flags=0,r.head&&(r.head.done=!1),!(r.wrap&1)||(((c&255)<<8)+(c>>8))%31){e.msg="incorrect header check",r.mode=Q;break}if((c&15)!==Qh){e.msg="unknown compression method",r.mode=Q;break}if(c>>>=4,h-=4,z=(c&15)+8,r.wbits===0)r.wbits=z;else if(z>r.wbits){e.msg="invalid window size",r.mode=Q;break}r.dmax=1<<z,e.adler=r.check=1,r.mode=c&512?lp:Ot,c=0,h=0;break;case ep:for(;h<16;){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}if(r.flags=c,(r.flags&255)!==Qh){e.msg="unknown compression method",r.mode=Q;break}if(r.flags&57344){e.msg="unknown header flags set",r.mode=Q;break}r.head&&(r.head.text=c>>8&1),r.flags&512&&(M[0]=c&255,M[1]=c>>>8&255,r.check=pt(r.check,M,2,0)),c=0,h=0,r.mode=tp;case tp:for(;h<32;){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}r.head&&(r.head.time=c),r.flags&512&&(M[0]=c&255,M[1]=c>>>8&255,M[2]=c>>>16&255,M[3]=c>>>24&255,r.check=pt(r.check,M,4,0)),c=0,h=0,r.mode=rp;case rp:for(;h<16;){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}r.head&&(r.head.xflags=c&255,r.head.os=c>>8),r.flags&512&&(M[0]=c&255,M[1]=c>>>8&255,r.check=pt(r.check,M,2,0)),c=0,h=0,r.mode=np;case np:if(r.flags&1024){for(;h<16;){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}r.length=c,r.head&&(r.head.extra_len=c),r.flags&512&&(M[0]=c&255,M[1]=c>>>8&255,r.check=pt(r.check,M,2,0)),c=0,h=0}else r.head&&(r.head.extra=null);r.mode=ip;case ip:if(r.flags&1024&&(w=r.length,w>d&&(w=d),w&&(r.head&&(z=r.head.extra_len-r.length,r.head.extra||(r.head.extra=new Array(r.head.extra_len)),Ee.arraySet(r.head.extra,n,l,w,z)),r.flags&512&&(r.check=pt(r.check,n,w,l)),d-=w,l+=w,r.length-=w),r.length))break e;r.length=0,r.mode=ap;case ap:if(r.flags&2048){if(d===0)break e;w=0;do z=n[l+w++],r.head&&z&&r.length<65536&&(r.head.name+=String.fromCharCode(z));while(z&&w<d);if(r.flags&512&&(r.check=pt(r.check,n,w,l)),d-=w,l+=w,z)break e}else r.head&&(r.head.name=null);r.length=0,r.mode=op;case op:if(r.flags&4096){if(d===0)break e;w=0;do z=n[l+w++],r.head&&z&&r.length<65536&&(r.head.comment+=String.fromCharCode(z));while(z&&w<d);if(r.flags&512&&(r.check=pt(r.check,n,w,l)),d-=w,l+=w,z)break e}else r.head&&(r.head.comment=null);r.mode=sp;case sp:if(r.flags&512){for(;h<16;){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}if(c!==(r.check&65535)){e.msg="header crc mismatch",r.mode=Q;break}c=0,h=0}r.head&&(r.head.hcrc=r.flags>>9&1,r.head.done=!0),e.adler=r.check=0,r.mode=Ot;break;case lp:for(;h<32;){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}e.adler=r.check=wp(c),c=0,h=0,r.mode=ro;case ro:if(r.havedict===0)return e.next_out=u,e.avail_out=m,e.next_in=l,e.avail_in=d,r.hold=c,r.bits=h,q0;e.adler=r.check=1,r.mode=Ot;case Ot:if(t===L0||t===Qa)break e;case Yl:if(r.last){c>>>=h&7,h-=h&7,r.mode=Xl;break}for(;h<3;){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}switch(r.last=c&1,c>>>=1,h-=1,c&3){case 0:r.mode=up;break;case 1:if(V0(r),r.mode=eo,t===Qa){c>>>=2,h-=2;break e}break;case 2:r.mode=cp;break;case 3:e.msg="invalid block type",r.mode=Q}c>>>=2,h-=2;break;case up:for(c>>>=h&7,h-=h&7;h<32;){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}if((c&65535)!==(c>>>16^65535)){e.msg="invalid stored block lengths",r.mode=Q;break}if(r.length=c&65535,c=0,h=0,r.mode=Kl,t===Qa)break e;case Kl:r.mode=fp;case fp:if(w=r.length,w){if(w>d&&(w=d),w>m&&(w=m),w===0)break e;Ee.arraySet(o,n,l,w,u),d-=w,l+=w,m-=w,u+=w,r.length-=w;break}r.mode=Ot;break;case cp:for(;h<14;){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}if(r.nlen=(c&31)+257,c>>>=5,h-=5,r.ndist=(c&31)+1,c>>>=5,h-=5,r.ncode=(c&15)+4,c>>>=4,h-=4,r.nlen>286||r.ndist>30){e.msg="too many length or distance symbols",r.mode=Q;break}r.have=0,r.mode=dp;case dp:for(;r.have<r.ncode;){for(;h<3;){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}r.lens[le[r.have++]]=c&7,c>>>=3,h-=3}for(;r.have<19;)r.lens[le[r.have++]]=0;if(r.lencode=r.lendyn,r.lenbits=7,V={bits:r.lenbits},B=Ei(B0,r.lens,0,19,r.lencode,0,r.work,V),r.lenbits=V.bits,B){e.msg="invalid code lengths set",r.mode=Q;break}r.have=0,r.mode=hp;case hp:for(;r.have<r.nlen+r.ndist;){for(;k=r.lencode[c&(1<<r.lenbits)-1],S=k>>>24,A=k>>>16&255,C=k&65535,!(S<=h);){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}if(C<16)c>>>=S,h-=S,r.lens[r.have++]=C;else{if(C===16){for(O=S+2;h<O;){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}if(c>>>=S,h-=S,r.have===0){e.msg="invalid bit length repeat",r.mode=Q;break}z=r.lens[r.have-1],w=3+(c&3),c>>>=2,h-=2}else if(C===17){for(O=S+3;h<O;){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}c>>>=S,h-=S,z=0,w=3+(c&7),c>>>=3,h-=3}else{for(O=S+7;h<O;){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}c>>>=S,h-=S,z=0,w=11+(c&127),c>>>=7,h-=7}if(r.have+w>r.nlen+r.ndist){e.msg="invalid bit length repeat",r.mode=Q;break}for(;w--;)r.lens[r.have++]=z}}if(r.mode===Q)break;if(r.lens[256]===0){e.msg="invalid code -- missing end-of-block",r.mode=Q;break}if(r.lenbits=9,V={bits:r.lenbits},B=Ei(Tp,r.lens,0,r.nlen,r.lencode,0,r.work,V),r.lenbits=V.bits,B){e.msg="invalid literal/lengths set",r.mode=Q;break}if(r.distbits=6,r.distcode=r.distdyn,V={bits:r.distbits},B=Ei(Rp,r.lens,r.nlen,r.ndist,r.distcode,0,r.work,V),r.distbits=V.bits,B){e.msg="invalid distances set",r.mode=Q;break}if(r.mode=eo,t===Qa)break e;case eo:r.mode=to;case to:if(d>=6&&m>=258){e.next_out=u,e.avail_out=m,e.next_in=l,e.avail_in=d,r.hold=c,r.bits=h,D0(e,y),u=e.next_out,o=e.output,m=e.avail_out,l=e.next_in,n=e.input,d=e.avail_in,c=r.hold,h=r.bits,r.mode===Ot&&(r.back=-1);break}for(r.back=0;k=r.lencode[c&(1<<r.lenbits)-1],S=k>>>24,A=k>>>16&255,C=k&65535,!(S<=h);){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}if(A&&!(A&240)){for(T=S,R=A,F=C;k=r.lencode[F+((c&(1<<T+R)-1)>>T)],S=k>>>24,A=k>>>16&255,C=k&65535,!(T+S<=h);){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}c>>>=T,h-=T,r.back+=T}if(c>>>=S,h-=S,r.back+=S,r.length=C,A===0){r.mode=yp;break}if(A&32){r.back=-1,r.mode=Ot;break}if(A&64){e.msg="invalid literal/length code",r.mode=Q;break}r.extra=A&15,r.mode=pp;case pp:if(r.extra){for(O=r.extra;h<O;){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}r.length+=c&(1<<r.extra)-1,c>>>=r.extra,h-=r.extra,r.back+=r.extra}r.was=r.length,r.mode=mp;case mp:for(;k=r.distcode[c&(1<<r.distbits)-1],S=k>>>24,A=k>>>16&255,C=k&65535,!(S<=h);){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}if(!(A&240)){for(T=S,R=A,F=C;k=r.distcode[F+((c&(1<<T+R)-1)>>T)],S=k>>>24,A=k>>>16&255,C=k&65535,!(T+S<=h);){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}c>>>=T,h-=T,r.back+=T}if(c>>>=S,h-=S,r.back+=S,A&64){e.msg="invalid distance code",r.mode=Q;break}r.offset=C,r.extra=A&15,r.mode=gp;case gp:if(r.extra){for(O=r.extra;h<O;){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}r.offset+=c&(1<<r.extra)-1,c>>>=r.extra,h-=r.extra,r.back+=r.extra}if(r.offset>r.dmax){e.msg="invalid distance too far back",r.mode=Q;break}r.mode=bp;case bp:if(m===0)break e;if(w=y-m,r.offset>w){if(w=r.offset-w,w>r.whave&&r.sane){e.msg="invalid distance too far back",r.mode=Q;break}w>r.wnext?(w-=r.wnext,v=r.wsize-w):v=r.wnext-w,w>r.length&&(w=r.length),E=r.window}else E=o,v=u-r.offset,w=r.length;w>m&&(w=m),m-=w,r.length-=w;do o[u++]=E[v++];while(--w);r.length===0&&(r.mode=to);break;case yp:if(m===0)break e;o[u++]=r.length,m--,r.mode=to;break;case Xl:if(r.wrap){for(;h<32;){if(d===0)break e;d--,c|=n[l++]<<h,h+=8}if(y-=m,e.total_out+=y,r.total+=y,y&&(e.adler=r.check=r.flags?pt(r.check,o,y,u-y):eu(r.check,o,y,u-y)),y=m,(r.flags?c:wp(c))!==r.check){e.msg="incorrect data check",r.mode=Q;break}c=0,h=0}r.mode=_p;case _p:if(r.wrap&&r.flags){for(;h<32;){if(d===0)break e;d--,c+=n[l++]<<h,h+=8}if(c!==(r.total&4294967295)){e.msg="incorrect length check",r.mode=Q;break}c=0,h=0}r.mode=vp;case vp:B=z0;break e;case Q:B=xp;break e;case ru:return tu;case M0:default:return qe}return e.next_out=u,e.avail_out=m,e.next_in=l,e.avail_in=d,r.hold=c,r.bits=h,(r.wsize||y!==e.avail_out&&r.mode<Q&&(r.mode<Xl||t!==Jh))&&Ip(e,e.output,e.next_out,y-e.avail_out)?(r.mode=ru,tu):(x-=e.avail_in,y-=e.avail_out,e.total_in+=x,e.total_out+=y,r.total+=y,r.wrap&&y&&(e.adler=r.check=r.flags?pt(r.check,o,y,e.next_out-y):eu(r.check,o,y,e.next_out-y)),e.data_type=r.bits+(r.last?64:0)+(r.mode===Ot?128:0)+(r.mode===eo||r.mode===Kl?256:0),(x===0&&y===0||t===Jh)&&B===kr&&(B=U0),B)}a(G0,"inflate");function Y0(e){if(!e||!e.state)return qe;var t=e.state;return t.window&&(t.window=null),e.state=null,kr}a(Y0,"inflateEnd");function K0(e,t){var r;return!e||!e.state||(r=e.state,!(r.wrap&2))?qe:(r.head=t,t.done=!1,kr)}a(K0,"inflateGetHeader");function X0(e,t){var r=t.length,n,o,l;return!e||!e.state||(n=e.state,n.wrap!==0&&n.mode!==ro)?qe:n.mode===ro&&(o=1,o=eu(o,t,r,0),o!==n.check)?xp:(l=Ip(e,t,r,r),l?(n.mode=ru,tu):(n.havedict=1,kr))}a(X0,"inflateSetDictionary");Ke.inflateReset=Ep;Ke.inflateReset2=Cp;Ke.inflateResetKeep=kp;Ke.inflateInit=Z0;Ke.inflateInit2=Pp;Ke.inflate=G0;Ke.inflateEnd=Y0;Ke.inflateGetHeader=K0;Ke.inflateSetDictionary=X0;Ke.inflateInfo="pako inflate (from Nodeca project)"});var nu=P((tx,Op)=>{"use strict";Op.exports={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8}});var Bp=P((rx,Dp)=>{"use strict";function J0(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1}a(J0,"GZheader");Dp.exports=J0});var zp=P(Pi=>{"use strict";var Rn=Fp(),Ci=Pt(),no=Nl(),re=nu(),iu=Ha(),Q0=jl(),ew=Bp(),Lp=Object.prototype.toString;function Er(e){if(!(this instanceof Er))return new Er(e);this.options=Ci.assign({chunkSize:16384,windowBits:0,to:""},e||{});var t=this.options;t.raw&&t.windowBits>=0&&t.windowBits<16&&(t.windowBits=-t.windowBits,t.windowBits===0&&(t.windowBits=-15)),t.windowBits>=0&&t.windowBits<16&&!(e&&e.windowBits)&&(t.windowBits+=32),t.windowBits>15&&t.windowBits<48&&(t.windowBits&15||(t.windowBits|=15)),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new Q0,this.strm.avail_out=0;var r=Rn.inflateInit2(this.strm,t.windowBits);if(r!==re.Z_OK)throw new Error(iu[r]);if(this.header=new ew,Rn.inflateGetHeader(this.strm,this.header),t.dictionary&&(typeof t.dictionary=="string"?t.dictionary=no.string2buf(t.dictionary):Lp.call(t.dictionary)==="[object ArrayBuffer]"&&(t.dictionary=new Uint8Array(t.dictionary)),t.raw&&(r=Rn.inflateSetDictionary(this.strm,t.dictionary),r!==re.Z_OK)))throw new Error(iu[r])}a(Er,"Inflate");Er.prototype.push=function(e,t){var r=this.strm,n=this.options.chunkSize,o=this.options.dictionary,l,u,d,m,c,h=!1;if(this.ended)return!1;u=t===~~t?t:t===!0?re.Z_FINISH:re.Z_NO_FLUSH,typeof e=="string"?r.input=no.binstring2buf(e):Lp.call(e)==="[object ArrayBuffer]"?r.input=new Uint8Array(e):r.input=e,r.next_in=0,r.avail_in=r.input.length;do{if(r.avail_out===0&&(r.output=new Ci.Buf8(n),r.next_out=0,r.avail_out=n),l=Rn.inflate(r,re.Z_NO_FLUSH),l===re.Z_NEED_DICT&&o&&(l=Rn.inflateSetDictionary(this.strm,o)),l===re.Z_BUF_ERROR&&h===!0&&(l=re.Z_OK,h=!1),l!==re.Z_STREAM_END&&l!==re.Z_OK)return this.onEnd(l),this.ended=!0,!1;r.next_out&&(r.avail_out===0||l===re.Z_STREAM_END||r.avail_in===0&&(u===re.Z_FINISH||u===re.Z_SYNC_FLUSH))&&(this.options.to==="string"?(d=no.utf8border(r.output,r.next_out),m=r.next_out-d,c=no.buf2string(r.output,d),r.next_out=m,r.avail_out=n-m,m&&Ci.arraySet(r.output,r.output,d,m,0),this.onData(c)):this.onData(Ci.shrinkBuf(r.output,r.next_out))),r.avail_in===0&&r.avail_out===0&&(h=!0)}while((r.avail_in>0||r.avail_out===0)&&l!==re.Z_STREAM_END);return l===re.Z_STREAM_END&&(u=re.Z_FINISH),u===re.Z_FINISH?(l=Rn.inflateEnd(this.strm),this.onEnd(l),this.ended=!0,l===re.Z_OK):(u===re.Z_SYNC_FLUSH&&(this.onEnd(re.Z_OK),r.avail_out=0),!0)};Er.prototype.onData=function(e){this.chunks.push(e)};Er.prototype.onEnd=function(e){e===re.Z_OK&&(this.options.to==="string"?this.result=this.chunks.join(""):this.result=Ci.flattenChunks(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg};function au(e,t){var r=new Er(t);if(r.push(e,!0),r.err)throw r.msg||iu[r.err];return r.result}a(au,"inflate");function tw(e,t){return t=t||{},t.raw=!0,au(e,t)}a(tw,"inflateRaw");Pi.Inflate=Er;Pi.inflate=au;Pi.inflateRaw=tw;Pi.ungzip=au});var Mp=P((ox,Up)=>{"use strict";var rw=Pt().assign,nw=Nh(),iw=zp(),aw=nu(),qp={};rw(qp,nw,iw,aw);Up.exports=qp});var Np=P(ao=>{"use strict";var ow=typeof Uint8Array<"u"&&typeof Uint16Array<"u"&&typeof Uint32Array<"u",sw=Mp(),Wp=ee(),io=ke(),lw=ow?"uint8array":"array";ao.magic="\b\0";function Cr(e,t){io.call(this,"FlateWorker/"+e),this._pako=null,this._pakoAction=e,this._pakoOptions=t,this.meta={}}a(Cr,"FlateWorker");Wp.inherits(Cr,io);Cr.prototype.processChunk=function(e){this.meta=e.meta,this._pako===null&&this._createPako(),this._pako.push(Wp.transformTo(lw,e.data),!1)};Cr.prototype.flush=function(){io.prototype.flush.call(this),this._pako===null&&this._createPako(),this._pako.push([],!0)};Cr.prototype.cleanUp=function(){io.prototype.cleanUp.call(this),this._pako=null};Cr.prototype._createPako=function(){this._pako=new sw[this._pakoAction]({raw:!0,level:this._pakoOptions.level||-1});var e=this;this._pako.onData=function(t){e.push({data:t,meta:e.meta})}};ao.compressWorker=function(e){return new Cr("Deflate",e)};ao.uncompressWorker=function(){return new Cr("Inflate",{})}});var su=P(ou=>{"use strict";var jp=ke();ou.STORE={magic:"\0\0",compressWorker:a(function(){return new jp("STORE compression")},"compressWorker"),uncompressWorker:a(function(){return new jp("STORE decompression")},"uncompressWorker")};ou.DEFLATE=Np()});var lu=P(Pr=>{"use strict";Pr.LOCAL_FILE_HEADER="PK";Pr.CENTRAL_FILE_HEADER="PK";Pr.CENTRAL_DIRECTORY_END="PK";Pr.ZIP64_CENTRAL_DIRECTORY_LOCATOR="PK\x07";Pr.ZIP64_CENTRAL_DIRECTORY_END="PK";Pr.DATA_DESCRIPTOR="PK\x07\b"});var Vp=P((dx,Zp)=>{"use strict";var xn=ee(),An=ke(),uu=hn(),Hp=Ua(),oo=lu(),X=a(function(e,t){var r="",n;for(n=0;n<t;n++)r+=String.fromCharCode(e&255),e=e>>>8;return r},"decToHex"),uw=a(function(e,t){var r=e;return e||(r=t?16893:33204),(r&65535)<<16},"generateUnixExternalFileAttr"),fw=a(function(e){return(e||0)&63},"generateDosExternalFileAttr"),$p=a(function(e,t,r,n,o,l){var u=e.file,d=e.compression,m=l!==uu.utf8encode,c=xn.transformTo("string",l(u.name)),h=xn.transformTo("string",uu.utf8encode(u.name)),x=u.comment,y=xn.transformTo("string",l(x)),w=xn.transformTo("string",uu.utf8encode(x)),v=h.length!==u.name.length,E=w.length!==x.length,k,S,A="",C="",T="",R=u.dir,F=u.date,z={crc32:0,compressedSize:0,uncompressedSize:0};(!t||r)&&(z.crc32=e.crc32,z.compressedSize=e.compressedSize,z.uncompressedSize=e.uncompressedSize);var B=0;t&&(B|=8),!m&&(v||E)&&(B|=2048);var M=0,V=0;R&&(M|=16),o==="UNIX"?(V=798,M|=uw(u.unixPermissions,R)):(V=20,M|=fw(u.dosPermissions,R)),k=F.getUTCHours(),k=k<<6,k=k|F.getUTCMinutes(),k=k<<5,k=k|F.getUTCSeconds()/2,S=F.getUTCFullYear()-1980,S=S<<4,S=S|F.getUTCMonth()+1,S=S<<5,S=S|F.getUTCDate(),v&&(C=X(1,1)+X(Hp(c),4)+h,A+="up"+X(C.length,2)+C),E&&(T=X(1,1)+X(Hp(y),4)+w,A+="uc"+X(T.length,2)+T);var O="";O+=`
|
|
13
|
+
\0`,O+=X(B,2),O+=d.magic,O+=X(k,2),O+=X(S,2),O+=X(z.crc32,4),O+=X(z.compressedSize,4),O+=X(z.uncompressedSize,4),O+=X(c.length,2),O+=X(A.length,2);var le=oo.LOCAL_FILE_HEADER+O+c+A,ce=oo.CENTRAL_FILE_HEADER+X(V,2)+O+X(y.length,2)+"\0\0\0\0"+X(M,4)+X(n,4)+c+A+y;return{fileRecord:le,dirRecord:ce}},"generateZipParts"),cw=a(function(e,t,r,n,o){var l="",u=xn.transformTo("string",o(n));return l=oo.CENTRAL_DIRECTORY_END+"\0\0\0\0"+X(e,2)+X(e,2)+X(t,4)+X(r,4)+X(u.length,2)+u,l},"generateCentralDirectoryEnd"),dw=a(function(e){var t="";return t=oo.DATA_DESCRIPTOR+X(e.crc32,4)+X(e.compressedSize,4)+X(e.uncompressedSize,4),t},"generateDataDescriptors");function Xe(e,t,r,n){An.call(this,"ZipFileWorker"),this.bytesWritten=0,this.zipComment=t,this.zipPlatform=r,this.encodeFileName=n,this.streamFiles=e,this.accumulate=!1,this.contentBuffer=[],this.dirRecords=[],this.currentSourceOffset=0,this.entriesCount=0,this.currentFile=null,this._sources=[]}a(Xe,"ZipFileWorker");xn.inherits(Xe,An);Xe.prototype.push=function(e){var t=e.meta.percent||0,r=this.entriesCount,n=this._sources.length;this.accumulate?this.contentBuffer.push(e):(this.bytesWritten+=e.data.length,An.prototype.push.call(this,{data:e.data,meta:{currentFile:this.currentFile,percent:r?(t+100*(r-n-1))/r:100}}))};Xe.prototype.openedSource=function(e){this.currentSourceOffset=this.bytesWritten,this.currentFile=e.file.name;var t=this.streamFiles&&!e.file.dir;if(t){var r=$p(e,t,!1,this.currentSourceOffset,this.zipPlatform,this.encodeFileName);this.push({data:r.fileRecord,meta:{percent:0}})}else this.accumulate=!0};Xe.prototype.closedSource=function(e){this.accumulate=!1;var t=this.streamFiles&&!e.file.dir,r=$p(e,t,!0,this.currentSourceOffset,this.zipPlatform,this.encodeFileName);if(this.dirRecords.push(r.dirRecord),t)this.push({data:dw(e),meta:{percent:100}});else for(this.push({data:r.fileRecord,meta:{percent:0}});this.contentBuffer.length;)this.push(this.contentBuffer.shift());this.currentFile=null};Xe.prototype.flush=function(){for(var e=this.bytesWritten,t=0;t<this.dirRecords.length;t++)this.push({data:this.dirRecords[t],meta:{percent:100}});var r=this.bytesWritten-e,n=cw(this.dirRecords.length,r,e,this.zipComment,this.encodeFileName);this.push({data:n,meta:{percent:100}})};Xe.prototype.prepareNextSource=function(){this.previous=this._sources.shift(),this.openedSource(this.previous.streamInfo),this.isPaused?this.previous.pause():this.previous.resume()};Xe.prototype.registerPrevious=function(e){this._sources.push(e);var t=this;return e.on("data",function(r){t.processChunk(r)}),e.on("end",function(){t.closedSource(t.previous.streamInfo),t._sources.length?t.prepareNextSource():t.end()}),e.on("error",function(r){t.error(r)}),this};Xe.prototype.resume=function(){if(!An.prototype.resume.call(this))return!1;if(!this.previous&&this._sources.length)return this.prepareNextSource(),!0;if(!this.previous&&!this._sources.length&&!this.generatedError)return this.end(),!0};Xe.prototype.error=function(e){var t=this._sources;if(!An.prototype.error.call(this,e))return!1;for(var r=0;r<t.length;r++)try{t[r].error(e)}catch{}return!0};Xe.prototype.lock=function(){An.prototype.lock.call(this);for(var e=this._sources,t=0;t<e.length;t++)e[t].lock()};Zp.exports=Xe});var Yp=P(Gp=>{"use strict";var hw=su(),pw=Vp(),mw=a(function(e,t){var r=e||t,n=hw[r];if(!n)throw new Error(r+" is not a valid compression method !");return n},"getCompression");Gp.generateWorker=function(e,t,r){var n=new pw(t.streamFiles,r,t.platform,t.encodeFileName),o=0;try{e.forEach(function(l,u){o++;var d=mw(u.options.compression,t.compression),m=u.options.compressionOptions||t.compressionOptions||{},c=u.dir,h=u.date;u._compressWorker(d,m).withStreamInfo("file",{name:l,dir:c,date:h,comment:u.comment||"",unixPermissions:u.unixPermissions,dosPermissions:u.dosPermissions}).pipe(n)}),n.entriesCount=o}catch(l){n.error(l)}return n}});var Xp=P((gx,Kp)=>{"use strict";var gw=ee(),so=ke();function Ii(e,t){so.call(this,"Nodejs stream input adapter for "+e),this._upstreamEnded=!1,this._bindStream(t)}a(Ii,"NodejsStreamInputAdapter");gw.inherits(Ii,so);Ii.prototype._bindStream=function(e){var t=this;this._stream=e,e.pause(),e.on("data",function(r){t.push({data:r,meta:{percent:0}})}).on("error",function(r){t.isPaused?this.generatedError=r:t.error(r)}).on("end",function(){t.isPaused?t._upstreamEnded=!0:t.end()})};Ii.prototype.pause=function(){return so.prototype.pause.call(this)?(this._stream.pause(),!0):!1};Ii.prototype.resume=function(){return so.prototype.resume.call(this)?(this._upstreamEnded?this.end():this._stream.resume(),!0):!1};Kp.exports=Ii});var sm=P((yx,om)=>{"use strict";var bw=hn(),Fi=ee(),tm=ke(),yw=pl(),rm=ml(),Jp=Ma(),_w=Qd(),vw=Yp(),Qp=si(),ww=Xp(),nm=a(function(e,t,r){var n=Fi.getTypeOf(t),o,l=Fi.extend(r||{},rm);l.date=l.date||new Date,l.compression!==null&&(l.compression=l.compression.toUpperCase()),typeof l.unixPermissions=="string"&&(l.unixPermissions=parseInt(l.unixPermissions,8)),l.unixPermissions&&l.unixPermissions&16384&&(l.dir=!0),l.dosPermissions&&l.dosPermissions&16&&(l.dir=!0),l.dir&&(e=im(e)),l.createFolders&&(o=Sw(e))&&am.call(this,o,!0);var u=n==="string"&&l.binary===!1&&l.base64===!1;(!r||typeof r.binary>"u")&&(l.binary=!u);var d=t instanceof Jp&&t.uncompressedSize===0;(d||l.dir||!t||t.length===0)&&(l.base64=!1,l.binary=!0,t="",l.compression="STORE",n="string");var m=null;t instanceof Jp||t instanceof tm?m=t:Qp.isNode&&Qp.isStream(t)?m=new ww(e,t):m=Fi.prepareContent(e,t,l.binary,l.optimizedBinaryString,l.base64);var c=new _w(e,m,l);this.files[e]=c},"fileAdd"),Sw=a(function(e){e.slice(-1)==="/"&&(e=e.substring(0,e.length-1));var t=e.lastIndexOf("/");return t>0?e.substring(0,t):""},"parentFolder"),im=a(function(e){return e.slice(-1)!=="/"&&(e+="/"),e},"forceTrailingSlash"),am=a(function(e,t){return t=typeof t<"u"?t:rm.createFolders,e=im(e),this.files[e]||nm.call(this,e,null,{dir:!0,createFolders:t}),this.files[e]},"folderAdd");function em(e){return Object.prototype.toString.call(e)==="[object RegExp]"}a(em,"isRegExp");var Tw={load:a(function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},"load"),forEach:a(function(e){var t,r,n;for(t in this.files)n=this.files[t],r=t.slice(this.root.length,t.length),r&&t.slice(0,this.root.length)===this.root&&e(r,n)},"forEach"),filter:a(function(e){var t=[];return this.forEach(function(r,n){e(r,n)&&t.push(n)}),t},"filter"),file:a(function(e,t,r){if(arguments.length===1)if(em(e)){var n=e;return this.filter(function(l,u){return!u.dir&&n.test(l)})}else{var o=this.files[this.root+e];return o&&!o.dir?o:null}else e=this.root+e,nm.call(this,e,t,r);return this},"file"),folder:a(function(e){if(!e)return this;if(em(e))return this.filter(function(o,l){return l.dir&&e.test(o)});var t=this.root+e,r=am.call(this,t),n=this.clone();return n.root=r.name,n},"folder"),remove:a(function(e){e=this.root+e;var t=this.files[e];if(t||(e.slice(-1)!=="/"&&(e+="/"),t=this.files[e]),t&&!t.dir)delete this.files[e];else for(var r=this.filter(function(o,l){return l.name.slice(0,e.length)===e}),n=0;n<r.length;n++)delete this.files[r[n].name];return this},"remove"),generate:a(function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},"generate"),generateInternalStream:a(function(e){var t,r={};try{if(r=Fi.extend(e||{},{streamFiles:!1,compression:"STORE",compressionOptions:null,type:"",platform:"DOS",comment:null,mimeType:"application/zip",encodeFileName:bw.utf8encode}),r.type=r.type.toLowerCase(),r.compression=r.compression.toUpperCase(),r.type==="binarystring"&&(r.type="string"),!r.type)throw new Error("No output type specified.");Fi.checkSupport(r.type),(r.platform==="darwin"||r.platform==="freebsd"||r.platform==="linux"||r.platform==="sunos")&&(r.platform="UNIX"),r.platform==="win32"&&(r.platform="DOS");var n=r.comment||this.comment||"";t=vw.generateWorker(this,r,n)}catch(o){t=new tm("error"),t.error(o)}return new yw(t,r.type||"string",r.mimeType)},"generateInternalStream"),generateAsync:a(function(e,t){return this.generateInternalStream(e).accumulate(t)},"generateAsync"),generateNodeStream:a(function(e,t){return e=e||{},e.type||(e.type="nodebuffer"),this.generateInternalStream(e).toNodejsStream(t)},"generateNodeStream")};om.exports=Tw});var fu=P((vx,um)=>{"use strict";var Rw=ee();function lm(e){this.data=e,this.length=e.length,this.index=0,this.zero=0}a(lm,"DataReader");lm.prototype={checkOffset:a(function(e){this.checkIndex(this.index+e)},"checkOffset"),checkIndex:a(function(e){if(this.length<this.zero+e||e<0)throw new Error("End of data reached (data length = "+this.length+", asked index = "+e+"). Corrupted zip ?")},"checkIndex"),setIndex:a(function(e){this.checkIndex(e),this.index=e},"setIndex"),skip:a(function(e){this.setIndex(this.index+e)},"skip"),byteAt:a(function(){},"byteAt"),readInt:a(function(e){var t=0,r;for(this.checkOffset(e),r=this.index+e-1;r>=this.index;r--)t=(t<<8)+this.byteAt(r);return this.index+=e,t},"readInt"),readString:a(function(e){return Rw.transformTo("string",this.readData(e))},"readString"),readData:a(function(){},"readData"),lastIndexOfSignature:a(function(){},"lastIndexOfSignature"),readAndCheckSignature:a(function(){},"readAndCheckSignature"),readDate:a(function(){var e=this.readInt(4);return new Date(Date.UTC((e>>25&127)+1980,(e>>21&15)-1,e>>16&31,e>>11&31,e>>5&63,(e&31)<<1))},"readDate")};um.exports=lm});var cu=P((Sx,cm)=>{"use strict";var fm=fu(),xw=ee();function kn(e){fm.call(this,e);for(var t=0;t<this.data.length;t++)e[t]=e[t]&255}a(kn,"ArrayReader");xw.inherits(kn,fm);kn.prototype.byteAt=function(e){return this.data[this.zero+e]};kn.prototype.lastIndexOfSignature=function(e){for(var t=e.charCodeAt(0),r=e.charCodeAt(1),n=e.charCodeAt(2),o=e.charCodeAt(3),l=this.length-4;l>=0;--l)if(this.data[l]===t&&this.data[l+1]===r&&this.data[l+2]===n&&this.data[l+3]===o)return l-this.zero;return-1};kn.prototype.readAndCheckSignature=function(e){var t=e.charCodeAt(0),r=e.charCodeAt(1),n=e.charCodeAt(2),o=e.charCodeAt(3),l=this.readData(4);return t===l[0]&&r===l[1]&&n===l[2]&&o===l[3]};kn.prototype.readData=function(e){if(this.checkOffset(e),e===0)return[];var t=this.data.slice(this.zero+this.index,this.zero+this.index+e);return this.index+=e,t};cm.exports=kn});var pm=P((Rx,hm)=>{"use strict";var dm=fu(),Aw=ee();function En(e){dm.call(this,e)}a(En,"StringReader");Aw.inherits(En,dm);En.prototype.byteAt=function(e){return this.data.charCodeAt(this.zero+e)};En.prototype.lastIndexOfSignature=function(e){return this.data.lastIndexOf(e)-this.zero};En.prototype.readAndCheckSignature=function(e){var t=this.readData(4);return e===t};En.prototype.readData=function(e){this.checkOffset(e);var t=this.data.slice(this.zero+this.index,this.zero+this.index+e);return this.index+=e,t};hm.exports=En});var hu=P((Ax,gm)=>{"use strict";var mm=cu(),kw=ee();function du(e){mm.call(this,e)}a(du,"Uint8ArrayReader");kw.inherits(du,mm);du.prototype.readData=function(e){if(this.checkOffset(e),e===0)return new Uint8Array(0);var t=this.data.subarray(this.zero+this.index,this.zero+this.index+e);return this.index+=e,t};gm.exports=du});var _m=P((Ex,ym)=>{"use strict";var bm=hu(),Ew=ee();function pu(e){bm.call(this,e)}a(pu,"NodeBufferReader");Ew.inherits(pu,bm);pu.prototype.readData=function(e){this.checkOffset(e);var t=this.data.slice(this.zero+this.index,this.zero+this.index+e);return this.index+=e,t};ym.exports=pu});var mu=P((Px,wm)=>{"use strict";var lo=ee(),vm=Et(),Cw=cu(),Pw=pm(),Iw=_m(),Fw=hu();wm.exports=function(e){var t=lo.getTypeOf(e);return lo.checkSupport(t),t==="string"&&!vm.uint8array?new Pw(e):t==="nodebuffer"?new Iw(e):vm.uint8array?new Fw(lo.transformTo("uint8array",e)):new Cw(lo.transformTo("array",e))}});var xm=P((Ix,Rm)=>{"use strict";var gu=mu(),tr=ee(),Ow=Ma(),Sm=Ua(),uo=hn(),fo=su(),Dw=Et(),Bw=0,Lw=3,zw=a(function(e){for(var t in fo)if(Object.prototype.hasOwnProperty.call(fo,t)&&fo[t].magic===e)return fo[t];return null},"findCompression");function Tm(e,t){this.options=e,this.loadOptions=t}a(Tm,"ZipEntry");Tm.prototype={isEncrypted:a(function(){return(this.bitFlag&1)===1},"isEncrypted"),useUTF8:a(function(){return(this.bitFlag&2048)===2048},"useUTF8"),readLocalPart:a(function(e){var t,r;if(e.skip(22),this.fileNameLength=e.readInt(2),r=e.readInt(2),this.fileName=e.readData(this.fileNameLength),e.skip(r),this.compressedSize===-1||this.uncompressedSize===-1)throw new Error("Bug or corrupted zip : didn't get enough information from the central directory (compressedSize === -1 || uncompressedSize === -1)");if(t=zw(this.compressionMethod),t===null)throw new Error("Corrupted zip : compression "+tr.pretty(this.compressionMethod)+" unknown (inner file : "+tr.transformTo("string",this.fileName)+")");this.decompressed=new Ow(this.compressedSize,this.uncompressedSize,this.crc32,t,e.readData(this.compressedSize))},"readLocalPart"),readCentralPart:a(function(e){this.versionMadeBy=e.readInt(2),e.skip(2),this.bitFlag=e.readInt(2),this.compressionMethod=e.readString(2),this.date=e.readDate(),this.crc32=e.readInt(4),this.compressedSize=e.readInt(4),this.uncompressedSize=e.readInt(4);var t=e.readInt(2);if(this.extraFieldsLength=e.readInt(2),this.fileCommentLength=e.readInt(2),this.diskNumberStart=e.readInt(2),this.internalFileAttributes=e.readInt(2),this.externalFileAttributes=e.readInt(4),this.localHeaderOffset=e.readInt(4),this.isEncrypted())throw new Error("Encrypted zip are not supported");e.skip(t),this.readExtraFields(e),this.parseZIP64ExtraField(e),this.fileComment=e.readData(this.fileCommentLength)},"readCentralPart"),processAttributes:a(function(){this.unixPermissions=null,this.dosPermissions=null;var e=this.versionMadeBy>>8;this.dir=!!(this.externalFileAttributes&16),e===Bw&&(this.dosPermissions=this.externalFileAttributes&63),e===Lw&&(this.unixPermissions=this.externalFileAttributes>>16&65535),!this.dir&&this.fileNameStr.slice(-1)==="/"&&(this.dir=!0)},"processAttributes"),parseZIP64ExtraField:a(function(){if(this.extraFields[1]){var e=gu(this.extraFields[1].value);this.uncompressedSize===tr.MAX_VALUE_32BITS&&(this.uncompressedSize=e.readInt(8)),this.compressedSize===tr.MAX_VALUE_32BITS&&(this.compressedSize=e.readInt(8)),this.localHeaderOffset===tr.MAX_VALUE_32BITS&&(this.localHeaderOffset=e.readInt(8)),this.diskNumberStart===tr.MAX_VALUE_32BITS&&(this.diskNumberStart=e.readInt(4))}},"parseZIP64ExtraField"),readExtraFields:a(function(e){var t=e.index+this.extraFieldsLength,r,n,o;for(this.extraFields||(this.extraFields={});e.index+4<t;)r=e.readInt(2),n=e.readInt(2),o=e.readData(n),this.extraFields[r]={id:r,length:n,value:o};e.setIndex(t)},"readExtraFields"),handleUTF8:a(function(){var e=Dw.uint8array?"uint8array":"array";if(this.useUTF8())this.fileNameStr=uo.utf8decode(this.fileName),this.fileCommentStr=uo.utf8decode(this.fileComment);else{var t=this.findExtraFieldUnicodePath();if(t!==null)this.fileNameStr=t;else{var r=tr.transformTo(e,this.fileName);this.fileNameStr=this.loadOptions.decodeFileName(r)}var n=this.findExtraFieldUnicodeComment();if(n!==null)this.fileCommentStr=n;else{var o=tr.transformTo(e,this.fileComment);this.fileCommentStr=this.loadOptions.decodeFileName(o)}}},"handleUTF8"),findExtraFieldUnicodePath:a(function(){var e=this.extraFields[28789];if(e){var t=gu(e.value);return t.readInt(1)!==1||Sm(this.fileName)!==t.readInt(4)?null:uo.utf8decode(t.readData(e.length-5))}return null},"findExtraFieldUnicodePath"),findExtraFieldUnicodeComment:a(function(){var e=this.extraFields[25461];if(e){var t=gu(e.value);return t.readInt(1)!==1||Sm(this.fileComment)!==t.readInt(4)?null:uo.utf8decode(t.readData(e.length-5))}return null},"findExtraFieldUnicodeComment")};Rm.exports=Tm});var Em=P((Ox,km)=>{"use strict";var qw=mu(),Dt=ee(),Je=lu(),Uw=xm(),Mw=Et();function Am(e){this.files=[],this.loadOptions=e}a(Am,"ZipEntries");Am.prototype={checkSignature:a(function(e){if(!this.reader.readAndCheckSignature(e)){this.reader.index-=4;var t=this.reader.readString(4);throw new Error("Corrupted zip or bug: unexpected signature ("+Dt.pretty(t)+", expected "+Dt.pretty(e)+")")}},"checkSignature"),isSignature:a(function(e,t){var r=this.reader.index;this.reader.setIndex(e);var n=this.reader.readString(4),o=n===t;return this.reader.setIndex(r),o},"isSignature"),readBlockEndOfCentral:a(function(){this.diskNumber=this.reader.readInt(2),this.diskWithCentralDirStart=this.reader.readInt(2),this.centralDirRecordsOnThisDisk=this.reader.readInt(2),this.centralDirRecords=this.reader.readInt(2),this.centralDirSize=this.reader.readInt(4),this.centralDirOffset=this.reader.readInt(4),this.zipCommentLength=this.reader.readInt(2);var e=this.reader.readData(this.zipCommentLength),t=Mw.uint8array?"uint8array":"array",r=Dt.transformTo(t,e);this.zipComment=this.loadOptions.decodeFileName(r)},"readBlockEndOfCentral"),readBlockZip64EndOfCentral:a(function(){this.zip64EndOfCentralSize=this.reader.readInt(8),this.reader.skip(4),this.diskNumber=this.reader.readInt(4),this.diskWithCentralDirStart=this.reader.readInt(4),this.centralDirRecordsOnThisDisk=this.reader.readInt(8),this.centralDirRecords=this.reader.readInt(8),this.centralDirSize=this.reader.readInt(8),this.centralDirOffset=this.reader.readInt(8),this.zip64ExtensibleData={};for(var e=this.zip64EndOfCentralSize-44,t=0,r,n,o;t<e;)r=this.reader.readInt(2),n=this.reader.readInt(4),o=this.reader.readData(n),this.zip64ExtensibleData[r]={id:r,length:n,value:o}},"readBlockZip64EndOfCentral"),readBlockZip64EndOfCentralLocator:a(function(){if(this.diskWithZip64CentralDirStart=this.reader.readInt(4),this.relativeOffsetEndOfZip64CentralDir=this.reader.readInt(8),this.disksCount=this.reader.readInt(4),this.disksCount>1)throw new Error("Multi-volumes zip are not supported")},"readBlockZip64EndOfCentralLocator"),readLocalFiles:a(function(){var e,t;for(e=0;e<this.files.length;e++)t=this.files[e],this.reader.setIndex(t.localHeaderOffset),this.checkSignature(Je.LOCAL_FILE_HEADER),t.readLocalPart(this.reader),t.handleUTF8(),t.processAttributes()},"readLocalFiles"),readCentralDir:a(function(){var e;for(this.reader.setIndex(this.centralDirOffset);this.reader.readAndCheckSignature(Je.CENTRAL_FILE_HEADER);)e=new Uw({zip64:this.zip64},this.loadOptions),e.readCentralPart(this.reader),this.files.push(e);if(this.centralDirRecords!==this.files.length&&this.centralDirRecords!==0&&this.files.length===0)throw new Error("Corrupted zip or bug: expected "+this.centralDirRecords+" records in central dir, got "+this.files.length)},"readCentralDir"),readEndOfCentral:a(function(){var e=this.reader.lastIndexOfSignature(Je.CENTRAL_DIRECTORY_END);if(e<0){var t=!this.isSignature(0,Je.LOCAL_FILE_HEADER);throw t?new Error("Can't find end of central directory : is this a zip file ? If it is, see https://stuk.github.io/jszip/documentation/howto/read_zip.html"):new Error("Corrupted zip: can't find end of central directory")}this.reader.setIndex(e);var r=e;if(this.checkSignature(Je.CENTRAL_DIRECTORY_END),this.readBlockEndOfCentral(),this.diskNumber===Dt.MAX_VALUE_16BITS||this.diskWithCentralDirStart===Dt.MAX_VALUE_16BITS||this.centralDirRecordsOnThisDisk===Dt.MAX_VALUE_16BITS||this.centralDirRecords===Dt.MAX_VALUE_16BITS||this.centralDirSize===Dt.MAX_VALUE_32BITS||this.centralDirOffset===Dt.MAX_VALUE_32BITS){if(this.zip64=!0,e=this.reader.lastIndexOfSignature(Je.ZIP64_CENTRAL_DIRECTORY_LOCATOR),e<0)throw new Error("Corrupted zip: can't find the ZIP64 end of central directory locator");if(this.reader.setIndex(e),this.checkSignature(Je.ZIP64_CENTRAL_DIRECTORY_LOCATOR),this.readBlockZip64EndOfCentralLocator(),!this.isSignature(this.relativeOffsetEndOfZip64CentralDir,Je.ZIP64_CENTRAL_DIRECTORY_END)&&(this.relativeOffsetEndOfZip64CentralDir=this.reader.lastIndexOfSignature(Je.ZIP64_CENTRAL_DIRECTORY_END),this.relativeOffsetEndOfZip64CentralDir<0))throw new Error("Corrupted zip: can't find the ZIP64 end of central directory");this.reader.setIndex(this.relativeOffsetEndOfZip64CentralDir),this.checkSignature(Je.ZIP64_CENTRAL_DIRECTORY_END),this.readBlockZip64EndOfCentral()}var n=this.centralDirOffset+this.centralDirSize;this.zip64&&(n+=20,n+=12+this.zip64EndOfCentralSize);var o=r-n;if(o>0)this.isSignature(r,Je.CENTRAL_FILE_HEADER)||(this.reader.zero=o);else if(o<0)throw new Error("Corrupted zip: missing "+Math.abs(o)+" bytes.")},"readEndOfCentral"),prepareReader:a(function(e){this.reader=qw(e)},"prepareReader"),load:a(function(e){this.prepareReader(e),this.readEndOfCentral(),this.readCentralDir(),this.readLocalFiles()},"load")};km.exports=Am});var Im=P((Bx,Pm)=>{"use strict";var bu=ee(),co=fn(),Ww=hn(),Nw=Em(),jw=yl(),Cm=si();function Hw(e){return new co.Promise(function(t,r){var n=e.decompressed.getContentWorker().pipe(new jw);n.on("error",function(o){r(o)}).on("end",function(){n.streamInfo.crc32!==e.decompressed.crc32?r(new Error("Corrupted zip : CRC32 mismatch")):t()}).resume()})}a(Hw,"checkEntryCRC32");Pm.exports=function(e,t){var r=this;return t=bu.extend(t||{},{base64:!1,checkCRC32:!1,optimizedBinaryString:!1,createFolders:!1,decodeFileName:Ww.utf8decode}),Cm.isNode&&Cm.isStream(e)?co.Promise.reject(new Error("JSZip can't accept a stream when loading a zip file.")):bu.prepareContent("the loaded zip file",e,!0,t.optimizedBinaryString,t.base64).then(function(n){var o=new Nw(t);return o.load(n),o}).then(a(function(o){var l=[co.Promise.resolve(o)],u=o.files;if(t.checkCRC32)for(var d=0;d<u.length;d++)l.push(Hw(u[d]));return co.Promise.all(l)},"checkCRC32")).then(a(function(o){for(var l=o.shift(),u=l.files,d=0;d<u.length;d++){var m=u[d],c=m.fileNameStr,h=bu.resolve(m.fileNameStr);r.file(h,m.decompressed,{binary:!0,optimizedBinaryString:!0,date:m.date,dir:m.dir,comment:m.fileCommentStr.length?m.fileCommentStr:null,unixPermissions:m.unixPermissions,dosPermissions:m.dosPermissions,createFolders:t.createFolders}),m.dir||(r.file(h).unsafeOriginalName=c)}return l.zipComment.length&&(r.comment=l.zipComment),r},"addFiles"))}});var ho=P((zx,Fm)=>{"use strict";function Ue(){if(!(this instanceof Ue))return new Ue;if(arguments.length)throw new Error("The constructor with parameters has been removed in JSZip 3.0, please check the upgrade guide.");this.files=Object.create(null),this.comment=null,this.root="",this.clone=function(){var e=new Ue;for(var t in this)typeof this[t]!="function"&&(e[t]=this[t]);return e}}a(Ue,"JSZip");Ue.prototype=sm();Ue.prototype.loadAsync=Im();Ue.support=Et();Ue.defaults=ml();Ue.version="3.10.1";Ue.loadAsync=function(e,t){return new Ue().loadAsync(e,t)};Ue.external=fn();Fm.exports=Ue});var Gw={};Mf(Gw,{TestRunMonitor:()=>yo});module.exports=jb(Gw);var $m=Fe(require("net")),nr=require("fs");var vc=Fe(require("http"),1),wc=Fe(require("https"),1),gr=Fe(require("zlib"),1),xe=Fe(require("stream"),1),Xn=require("buffer");function Hb(e){if(!/^data:/i.test(e))throw new TypeError('`uri` does not appear to be a Data URI (must begin with "data:")');e=e.replace(/\r?\n/g,"");let t=e.indexOf(",");if(t===-1||t<=4)throw new TypeError("malformed data: URI");let r=e.substring(5,t).split(";"),n="",o=!1,l=r[0]||"text/plain",u=l;for(let h=1;h<r.length;h++)r[h]==="base64"?o=!0:r[h]&&(u+=`;${r[h]}`,r[h].indexOf("charset=")===0&&(n=r[h].substring(8)));!r[0]&&!n.length&&(u+=";charset=US-ASCII",n="US-ASCII");let d=o?"base64":"ascii",m=unescape(e.substring(t+1)),c=Buffer.from(m,d);return c.type=l,c.typeFull=u,c.charset=n,c}a(Hb,"dataUriToBuffer");var jf=Hb;var De=Fe(require("stream"),1),Rt=require("util"),Te=require("buffer");jn();ua();var ys=class ys extends Error{constructor(t,r){super(t),Error.captureStackTrace(this,this.constructor),this.type=r}get name(){return this.constructor.name}get[Symbol.toStringTag](){return this.constructor.name}};a(ys,"FetchBaseError");var Tt=ys;var _s=class _s extends Tt{constructor(t,r,n){super(t,r),n&&(this.code=this.errno=n.code,this.erroredSysCall=n.syscall)}};a(_s,"FetchError");var ye=_s;var fa=Symbol.toStringTag,vs=a(e=>typeof e=="object"&&typeof e.append=="function"&&typeof e.delete=="function"&&typeof e.get=="function"&&typeof e.getAll=="function"&&typeof e.has=="function"&&typeof e.set=="function"&&typeof e.sort=="function"&&e[fa]==="URLSearchParams","isURLSearchParameters"),Vn=a(e=>e&&typeof e=="object"&&typeof e.arrayBuffer=="function"&&typeof e.type=="string"&&typeof e.stream=="function"&&typeof e.constructor=="function"&&/^(Blob|File)$/.test(e[fa]),"isBlob"),Jf=a(e=>typeof e=="object"&&(e[fa]==="AbortSignal"||e[fa]==="EventTarget"),"isAbortSignal"),Qf=a((e,t)=>{let r=new URL(t).hostname,n=new URL(e).hostname;return r===n||r.endsWith(`.${n}`)},"isDomainOrSubdomain"),ec=a((e,t)=>{let r=new URL(t).protocol,n=new URL(e).protocol;return r===n},"isSameProtocol");var ay=(0,Rt.promisify)(De.default.pipeline),_e=Symbol("Body internals"),xs=class xs{constructor(t,{size:r=0}={}){let n=null;t===null?t=null:vs(t)?t=Te.Buffer.from(t.toString()):Vn(t)||Te.Buffer.isBuffer(t)||(Rt.types.isAnyArrayBuffer(t)?t=Te.Buffer.from(t):ArrayBuffer.isView(t)?t=Te.Buffer.from(t.buffer,t.byteOffset,t.byteLength):t instanceof De.default||(t instanceof dr?(t=Xf(t),n=t.type.split("=")[1]):t=Te.Buffer.from(String(t))));let o=t;Te.Buffer.isBuffer(t)?o=De.default.Readable.from(t):Vn(t)&&(o=De.default.Readable.from(t.stream())),this[_e]={body:t,stream:o,boundary:n,disturbed:!1,error:null},this.size=r,t instanceof De.default&&t.on("error",l=>{let u=l instanceof Tt?l:new ye(`Invalid response body while trying to fetch ${this.url}: ${l.message}`,"system",l);this[_e].error=u})}get body(){return this[_e].stream}get bodyUsed(){return this[_e].disturbed}async arrayBuffer(){let{buffer:t,byteOffset:r,byteLength:n}=await Rs(this);return t.slice(r,r+n)}async formData(){let t=this.headers.get("content-type");if(t.startsWith("application/x-www-form-urlencoded")){let n=new dr,o=new URLSearchParams(await this.text());for(let[l,u]of o)n.append(l,u);return n}let{toFormData:r}=await Promise.resolve().then(()=>(ac(),ic));return r(this.body,t)}async blob(){let t=this.headers&&this.headers.get("content-type")||this[_e].body&&this[_e].body.type||"",r=await this.arrayBuffer();return new St([r],{type:t})}async json(){let t=await this.text();return JSON.parse(t)}async text(){let t=await Rs(this);return new TextDecoder().decode(t)}buffer(){return Rs(this)}};a(xs,"Body");var st=xs;st.prototype.buffer=(0,Rt.deprecate)(st.prototype.buffer,"Please use 'response.arrayBuffer()' instead of 'response.buffer()'","node-fetch#buffer");Object.defineProperties(st.prototype,{body:{enumerable:!0},bodyUsed:{enumerable:!0},arrayBuffer:{enumerable:!0},blob:{enumerable:!0},json:{enumerable:!0},text:{enumerable:!0},data:{get:(0,Rt.deprecate)(()=>{},"data doesn't exist, use json(), text(), arrayBuffer(), or body instead","https://github.com/node-fetch/node-fetch/issues/1000 (response)")}});async function Rs(e){if(e[_e].disturbed)throw new TypeError(`body used already for: ${e.url}`);if(e[_e].disturbed=!0,e[_e].error)throw e[_e].error;let{body:t}=e;if(t===null)return Te.Buffer.alloc(0);if(!(t instanceof De.default))return Te.Buffer.alloc(0);let r=[],n=0;try{for await(let o of t){if(e.size>0&&n+o.length>e.size){let l=new ye(`content size at ${e.url} over limit: ${e.size}`,"max-size");throw t.destroy(l),l}n+=o.length,r.push(o)}}catch(o){throw o instanceof Tt?o:new ye(`Invalid response body while trying to fetch ${e.url}: ${o.message}`,"system",o)}if(t.readableEnded===!0||t._readableState.ended===!0)try{return r.every(o=>typeof o=="string")?Te.Buffer.from(r.join("")):Te.Buffer.concat(r,n)}catch(o){throw new ye(`Could not create Buffer from response body for ${e.url}: ${o.message}`,"system",o)}else throw new ye(`Premature close of server response while trying to fetch ${e.url}`)}a(Rs,"consumeBody");var Qr=a((e,t)=>{let r,n,{body:o}=e[_e];if(e.bodyUsed)throw new Error("cannot clone body after it is used");return o instanceof De.default&&typeof o.getBoundary!="function"&&(r=new De.PassThrough({highWaterMark:t}),n=new De.PassThrough({highWaterMark:t}),o.pipe(r),o.pipe(n),e[_e].stream=r,o=n),o},"clone"),oy=(0,Rt.deprecate)(e=>e.getBoundary(),"form-data doesn't follow the spec and requires special treatment. Use alternative package","https://github.com/node-fetch/node-fetch/issues/1167"),pa=a((e,t)=>e===null?null:typeof e=="string"?"text/plain;charset=UTF-8":vs(e)?"application/x-www-form-urlencoded;charset=UTF-8":Vn(e)?e.type||null:Te.Buffer.isBuffer(e)||Rt.types.isAnyArrayBuffer(e)||ArrayBuffer.isView(e)?null:e instanceof dr?`multipart/form-data; boundary=${t[_e].boundary}`:e&&typeof e.getBoundary=="function"?`multipart/form-data;boundary=${oy(e)}`:e instanceof De.default?null:"text/plain;charset=UTF-8","extractContentType"),oc=a(e=>{let{body:t}=e[_e];return t===null?0:Vn(t)?t.size:Te.Buffer.isBuffer(t)?t.length:t&&typeof t.getLengthSync=="function"&&t.hasKnownLength&&t.hasKnownLength()?t.getLengthSync():null},"getTotalBytes"),sc=a(async(e,{body:t})=>{t===null?e.end():await ay(t,e)},"writeToStream");var As=require("util"),Yn=Fe(require("http"),1);var ma=typeof Yn.default.validateHeaderName=="function"?Yn.default.validateHeaderName:e=>{if(!/^[\^`\-\w!#$%&'*+.|~]+$/.test(e)){let t=new TypeError(`Header name must be a valid HTTP token [${e}]`);throw Object.defineProperty(t,"code",{value:"ERR_INVALID_HTTP_TOKEN"}),t}},ks=typeof Yn.default.validateHeaderValue=="function"?Yn.default.validateHeaderValue:(e,t)=>{if(/[^\t\u0020-\u007E\u0080-\u00FF]/.test(t)){let r=new TypeError(`Invalid character in header content ["${e}"]`);throw Object.defineProperty(r,"code",{value:"ERR_INVALID_CHAR"}),r}},ga=class ga extends URLSearchParams{constructor(t){let r=[];if(t instanceof ga){let n=t.raw();for(let[o,l]of Object.entries(n))r.push(...l.map(u=>[o,u]))}else if(t!=null)if(typeof t=="object"&&!As.types.isBoxedPrimitive(t)){let n=t[Symbol.iterator];if(n==null)r.push(...Object.entries(t));else{if(typeof n!="function")throw new TypeError("Header pairs must be iterable");r=[...t].map(o=>{if(typeof o!="object"||As.types.isBoxedPrimitive(o))throw new TypeError("Each header pair must be an iterable object");return[...o]}).map(o=>{if(o.length!==2)throw new TypeError("Each header pair must be a name/value tuple");return[...o]})}}else throw new TypeError("Failed to construct 'Headers': The provided value is not of type '(sequence<sequence<ByteString>> or record<ByteString, ByteString>)");return r=r.length>0?r.map(([n,o])=>(ma(n),ks(n,String(o)),[String(n).toLowerCase(),String(o)])):void 0,super(r),new Proxy(this,{get(n,o,l){switch(o){case"append":case"set":return(u,d)=>(ma(u),ks(u,String(d)),URLSearchParams.prototype[o].call(n,String(u).toLowerCase(),String(d)));case"delete":case"has":case"getAll":return u=>(ma(u),URLSearchParams.prototype[o].call(n,String(u).toLowerCase()));case"keys":return()=>(n.sort(),new Set(URLSearchParams.prototype.keys.call(n)).keys());default:return Reflect.get(n,o,l)}}})}get[Symbol.toStringTag](){return this.constructor.name}toString(){return Object.prototype.toString.call(this)}get(t){let r=this.getAll(t);if(r.length===0)return null;let n=r.join(", ");return/^content-encoding$/i.test(t)&&(n=n.toLowerCase()),n}forEach(t,r=void 0){for(let n of this.keys())Reflect.apply(t,r,[this.get(n),n,this])}*values(){for(let t of this.keys())yield this.get(t)}*entries(){for(let t of this.keys())yield[t,this.get(t)]}[Symbol.iterator](){return this.entries()}raw(){return[...this.keys()].reduce((t,r)=>(t[r]=this.getAll(r),t),{})}[Symbol.for("nodejs.util.inspect.custom")](){return[...this.keys()].reduce((t,r)=>{let n=this.getAll(r);return r==="host"?t[r]=n[0]:t[r]=n.length>1?n:n[0],t},{})}};a(ga,"Headers");var Re=ga;Object.defineProperties(Re.prototype,["get","entries","forEach","values"].reduce((e,t)=>(e[t]={enumerable:!0},e),{}));function lc(e=[]){return new Re(e.reduce((t,r,n,o)=>(n%2===0&&t.push(o.slice(n,n+2)),t),[]).filter(([t,r])=>{try{return ma(t),ks(t,String(r)),!0}catch{return!1}}))}a(lc,"fromRawHeaders");var sy=new Set([301,302,303,307,308]),ba=a(e=>sy.has(e),"isRedirect");var Ve=Symbol("Response internals"),pr=class pr extends st{constructor(t=null,r={}){super(t,r);let n=r.status!=null?r.status:200,o=new Re(r.headers);if(t!==null&&!o.has("Content-Type")){let l=pa(t,this);l&&o.append("Content-Type",l)}this[Ve]={type:"default",url:r.url,status:n,statusText:r.statusText||"",headers:o,counter:r.counter,highWaterMark:r.highWaterMark}}get type(){return this[Ve].type}get url(){return this[Ve].url||""}get status(){return this[Ve].status}get ok(){return this[Ve].status>=200&&this[Ve].status<300}get redirected(){return this[Ve].counter>0}get statusText(){return this[Ve].statusText}get headers(){return this[Ve].headers}get highWaterMark(){return this[Ve].highWaterMark}clone(){return new pr(Qr(this,this.highWaterMark),{type:this.type,url:this.url,status:this.status,statusText:this.statusText,headers:this.headers,ok:this.ok,redirected:this.redirected,size:this.size,highWaterMark:this.highWaterMark})}static redirect(t,r=302){if(!ba(r))throw new RangeError('Failed to execute "redirect" on "response": Invalid status code');return new pr(null,{headers:{location:new URL(t).toString()},status:r})}static error(){let t=new pr(null,{status:0,statusText:""});return t[Ve].type="error",t}static json(t=void 0,r={}){let n=JSON.stringify(t);if(n===void 0)throw new TypeError("data is not JSON serializable");let o=new Re(r&&r.headers);return o.has("content-type")||o.set("content-type","application/json"),new pr(n,{...r,headers:o})}get[Symbol.toStringTag](){return"Response"}};a(pr,"Response");var Be=pr;Object.defineProperties(Be.prototype,{type:{enumerable:!0},url:{enumerable:!0},status:{enumerable:!0},ok:{enumerable:!0},redirected:{enumerable:!0},statusText:{enumerable:!0},headers:{enumerable:!0},clone:{enumerable:!0}});var bc=require("url"),yc=require("util");var uc=a(e=>{if(e.search)return e.search;let t=e.href.length-1,r=e.hash||(e.href[t]==="#"?"#":"");return e.href[t-r.length]==="?"?"?":""},"getSearch");var cc=require("net");function fc(e,t=!1){return e==null||(e=new URL(e),/^(about|blob|data):$/.test(e.protocol))?"no-referrer":(e.username="",e.password="",e.hash="",t&&(e.pathname="",e.search=""),e)}a(fc,"stripURLForUseAsAReferrer");var dc=new Set(["","no-referrer","no-referrer-when-downgrade","same-origin","origin","strict-origin","origin-when-cross-origin","strict-origin-when-cross-origin","unsafe-url"]),hc="strict-origin-when-cross-origin";function pc(e){if(!dc.has(e))throw new TypeError(`Invalid referrerPolicy: ${e}`);return e}a(pc,"validateReferrerPolicy");function ly(e){if(/^(http|ws)s:$/.test(e.protocol))return!0;let t=e.host.replace(/(^\[)|(]$)/g,""),r=(0,cc.isIP)(t);return r===4&&/^127\./.test(t)||r===6&&/^(((0+:){7})|(::(0+:){0,6}))0*1$/.test(t)?!0:e.host==="localhost"||e.host.endsWith(".localhost")?!1:e.protocol==="file:"}a(ly,"isOriginPotentiallyTrustworthy");function en(e){return/^about:(blank|srcdoc)$/.test(e)||e.protocol==="data:"||/^(blob|filesystem):$/.test(e.protocol)?!0:ly(e)}a(en,"isUrlPotentiallyTrustworthy");function mc(e,{referrerURLCallback:t,referrerOriginCallback:r}={}){if(e.referrer==="no-referrer"||e.referrerPolicy==="")return null;let n=e.referrerPolicy;if(e.referrer==="about:client")return"no-referrer";let o=e.referrer,l=fc(o),u=fc(o,!0);l.toString().length>4096&&(l=u),t&&(l=t(l)),r&&(u=r(u));let d=new URL(e.url);switch(n){case"no-referrer":return"no-referrer";case"origin":return u;case"unsafe-url":return l;case"strict-origin":return en(l)&&!en(d)?"no-referrer":u.toString();case"strict-origin-when-cross-origin":return l.origin===d.origin?l:en(l)&&!en(d)?"no-referrer":u;case"same-origin":return l.origin===d.origin?l:"no-referrer";case"origin-when-cross-origin":return l.origin===d.origin?l:u;case"no-referrer-when-downgrade":return en(l)&&!en(d)?"no-referrer":l;default:throw new TypeError(`Invalid referrerPolicy: ${n}`)}}a(mc,"determineRequestsReferrer");function gc(e){let t=(e.get("referrer-policy")||"").split(/[,\s]+/),r="";for(let n of t)n&&dc.has(n)&&(r=n);return r}a(gc,"parseReferrerPolicyFromHeader");var se=Symbol("Request internals"),Kn=a(e=>typeof e=="object"&&typeof e[se]=="object","isRequest"),uy=(0,yc.deprecate)(()=>{},".data is not a valid RequestInit property, use .body instead","https://github.com/node-fetch/node-fetch/issues/1000 (request)"),ya=class ya extends st{constructor(t,r={}){let n;if(Kn(t)?n=new URL(t.url):(n=new URL(t),t={}),n.username!==""||n.password!=="")throw new TypeError(`${n} is an url with embedded credentials.`);let o=r.method||t.method||"GET";if(/^(delete|get|head|options|post|put)$/i.test(o)&&(o=o.toUpperCase()),!Kn(r)&&"data"in r&&uy(),(r.body!=null||Kn(t)&&t.body!==null)&&(o==="GET"||o==="HEAD"))throw new TypeError("Request with GET/HEAD method cannot have body");let l=r.body?r.body:Kn(t)&&t.body!==null?Qr(t):null;super(l,{size:r.size||t.size||0});let u=new Re(r.headers||t.headers||{});if(l!==null&&!u.has("Content-Type")){let c=pa(l,this);c&&u.set("Content-Type",c)}let d=Kn(t)?t.signal:null;if("signal"in r&&(d=r.signal),d!=null&&!Jf(d))throw new TypeError("Expected signal to be an instanceof AbortSignal or EventTarget");let m=r.referrer==null?t.referrer:r.referrer;if(m==="")m="no-referrer";else if(m){let c=new URL(m);m=/^about:(\/\/)?client$/.test(c)?"client":c}else m=void 0;this[se]={method:o,redirect:r.redirect||t.redirect||"follow",headers:u,parsedURL:n,signal:d,referrer:m},this.follow=r.follow===void 0?t.follow===void 0?20:t.follow:r.follow,this.compress=r.compress===void 0?t.compress===void 0?!0:t.compress:r.compress,this.counter=r.counter||t.counter||0,this.agent=r.agent||t.agent,this.highWaterMark=r.highWaterMark||t.highWaterMark||16384,this.insecureHTTPParser=r.insecureHTTPParser||t.insecureHTTPParser||!1,this.referrerPolicy=r.referrerPolicy||t.referrerPolicy||""}get method(){return this[se].method}get url(){return(0,bc.format)(this[se].parsedURL)}get headers(){return this[se].headers}get redirect(){return this[se].redirect}get signal(){return this[se].signal}get referrer(){if(this[se].referrer==="no-referrer")return"";if(this[se].referrer==="client")return"about:client";if(this[se].referrer)return this[se].referrer.toString()}get referrerPolicy(){return this[se].referrerPolicy}set referrerPolicy(t){this[se].referrerPolicy=pc(t)}clone(){return new ya(this)}get[Symbol.toStringTag](){return"Request"}};a(ya,"Request");var mr=ya;Object.defineProperties(mr.prototype,{method:{enumerable:!0},url:{enumerable:!0},headers:{enumerable:!0},redirect:{enumerable:!0},clone:{enumerable:!0},signal:{enumerable:!0},referrer:{enumerable:!0},referrerPolicy:{enumerable:!0}});var _c=a(e=>{let{parsedURL:t}=e[se],r=new Re(e[se].headers);r.has("Accept")||r.set("Accept","*/*");let n=null;if(e.body===null&&/^(post|put)$/i.test(e.method)&&(n="0"),e.body!==null){let d=oc(e);typeof d=="number"&&!Number.isNaN(d)&&(n=String(d))}n&&r.set("Content-Length",n),e.referrerPolicy===""&&(e.referrerPolicy=hc),e.referrer&&e.referrer!=="no-referrer"?e[se].referrer=mc(e):e[se].referrer="no-referrer",e[se].referrer instanceof URL&&r.set("Referer",e.referrer),r.has("User-Agent")||r.set("User-Agent","node-fetch"),e.compress&&!r.has("Accept-Encoding")&&r.set("Accept-Encoding","gzip, deflate, br");let{agent:o}=e;typeof o=="function"&&(o=o(t));let l=uc(t),u={path:t.pathname+l,method:e.method,headers:r[Symbol.for("nodejs.util.inspect.custom")](),insecureHTTPParser:e.insecureHTTPParser,agent:o};return{parsedURL:t,options:u}},"getNodeRequestOptions");var Es=class Es extends Tt{constructor(t,r="aborted"){super(t,r)}};a(Es,"AbortError");var _a=Es;ua();ws();var fy=new Set(["data:","http:","https:"]);async function va(e,t){return new Promise((r,n)=>{let o=new mr(e,t),{parsedURL:l,options:u}=_c(o);if(!fy.has(l.protocol))throw new TypeError(`node-fetch cannot load ${e}. URL scheme "${l.protocol.replace(/:$/,"")}" is not supported.`);if(l.protocol==="data:"){let v=jf(o.url),E=new Be(v,{headers:{"Content-Type":v.typeFull}});r(E);return}let d=(l.protocol==="https:"?wc.default:vc.default).request,{signal:m}=o,c=null,h=a(()=>{let v=new _a("The operation was aborted.");n(v),o.body&&o.body instanceof xe.default.Readable&&o.body.destroy(v),!(!c||!c.body)&&c.body.emit("error",v)},"abort");if(m&&m.aborted){h();return}let x=a(()=>{h(),w()},"abortAndFinalize"),y=d(l.toString(),u);m&&m.addEventListener("abort",x);let w=a(()=>{y.abort(),m&&m.removeEventListener("abort",x)},"finalize");y.on("error",v=>{n(new ye(`request to ${o.url} failed, reason: ${v.message}`,"system",v)),w()}),cy(y,v=>{c&&c.body&&c.body.destroy(v)}),process.version<"v14"&&y.on("socket",v=>{let E;v.prependListener("end",()=>{E=v._eventsCount}),v.prependListener("close",k=>{if(c&&E<v._eventsCount&&!k){let S=new Error("Premature close");S.code="ERR_STREAM_PREMATURE_CLOSE",c.body.emit("error",S)}})}),y.on("response",v=>{y.setTimeout(0);let E=lc(v.rawHeaders);if(ba(v.statusCode)){let T=E.get("Location"),R=null;try{R=T===null?null:new URL(T,o.url)}catch{if(o.redirect!=="manual"){n(new ye(`uri requested responds with an invalid redirect URL: ${T}`,"invalid-redirect")),w();return}}switch(o.redirect){case"error":n(new ye(`uri requested responds with a redirect, redirect mode is set to error: ${o.url}`,"no-redirect")),w();return;case"manual":break;case"follow":{if(R===null)break;if(o.counter>=o.follow){n(new ye(`maximum redirect reached at: ${o.url}`,"max-redirect")),w();return}let F={headers:new Re(o.headers),follow:o.follow,counter:o.counter+1,agent:o.agent,compress:o.compress,method:o.method,body:Qr(o),signal:o.signal,size:o.size,referrer:o.referrer,referrerPolicy:o.referrerPolicy};if(!Qf(o.url,R)||!ec(o.url,R))for(let B of["authorization","www-authenticate","cookie","cookie2"])F.headers.delete(B);if(v.statusCode!==303&&o.body&&t.body instanceof xe.default.Readable){n(new ye("Cannot follow redirect with body being a readable stream","unsupported-redirect")),w();return}(v.statusCode===303||(v.statusCode===301||v.statusCode===302)&&o.method==="POST")&&(F.method="GET",F.body=void 0,F.headers.delete("content-length"));let z=gc(E);z&&(F.referrerPolicy=z),r(va(new mr(R,F))),w();return}default:return n(new TypeError(`Redirect option '${o.redirect}' is not a valid value of RequestRedirect`))}}m&&v.once("end",()=>{m.removeEventListener("abort",x)});let k=(0,xe.pipeline)(v,new xe.PassThrough,T=>{T&&n(T)});process.version<"v12.10"&&v.on("aborted",x);let S={url:o.url,status:v.statusCode,statusText:v.statusMessage,headers:E,size:o.size,counter:o.counter,highWaterMark:o.highWaterMark},A=E.get("Content-Encoding");if(!o.compress||o.method==="HEAD"||A===null||v.statusCode===204||v.statusCode===304){c=new Be(k,S),r(c);return}let C={flush:gr.default.Z_SYNC_FLUSH,finishFlush:gr.default.Z_SYNC_FLUSH};if(A==="gzip"||A==="x-gzip"){k=(0,xe.pipeline)(k,gr.default.createGunzip(C),T=>{T&&n(T)}),c=new Be(k,S),r(c);return}if(A==="deflate"||A==="x-deflate"){let T=(0,xe.pipeline)(v,new xe.PassThrough,R=>{R&&n(R)});T.once("data",R=>{(R[0]&15)===8?k=(0,xe.pipeline)(k,gr.default.createInflate(),F=>{F&&n(F)}):k=(0,xe.pipeline)(k,gr.default.createInflateRaw(),F=>{F&&n(F)}),c=new Be(k,S),r(c)}),T.once("end",()=>{c||(c=new Be(k,S),r(c))});return}if(A==="br"){k=(0,xe.pipeline)(k,gr.default.createBrotliDecompress(),T=>{T&&n(T)}),c=new Be(k,S),r(c);return}c=new Be(k,S),r(c)}),sc(y,o).catch(n)})}a(va,"fetch");function cy(e,t){let r=Xn.Buffer.from(`0\r
|
|
14
14
|
\r
|
|
15
15
|
`),n=!1,o=!1,l;e.on("response",u=>{let{headers:d}=u;n=d["transfer-encoding"]==="chunked"&&!d["content-length"]}),e.on("socket",u=>{let d=a(()=>{if(n&&!o){let c=new Error("Premature close");c.code="ERR_STREAM_PREMATURE_CLOSE",t(c)}},"onSocketClose"),m=a(c=>{o=Xn.Buffer.compare(c.slice(-5),r)===0,!o&&l&&(o=Xn.Buffer.compare(l.slice(-3),r.slice(0,3))===0&&Xn.Buffer.compare(c.slice(-2),r.slice(3))===0),l=c},"onData");u.prependListener("close",d),u.on("data",m),e.on("close",()=>{u.removeListener("close",d),u.removeListener("data",m)})})}a(cy,"fixResponseChunkedTransferBadEnding");var Qe=require("path");var Om=require("fs"),Dm=require("jsdom"),Bm=Fe(ho()),Lm=require("path");var yu=class yu{constructor(t,r,n,o={}){this.reportHTMLFilePath=t;this.testRunUUID=r;this.pwTestIdToChecksumTestId=n;this.supportVideo=!1;this.config={hosted:!0,assetsBaseURL:"https://api.checksum.ai/api/test-runs"};this.config={...this.config,...o}}async process(){if(this.config.hosted){await this.initializeDOM();try{this.makeLightModeOnly()}catch(t){console.warn("Failed to make light mode only",t.message)}await this.editZipFile(),await this.writeFile()}}testHasTrace(t,r){try{if(!this.report)return!0;let n=Object.keys(this.pwTestIdToChecksumTestId??{}).find(l=>this.pwTestIdToChecksumTestId[l]===t);if(!n)return!0;let o=a(l=>l.some(u=>{var d;return(d=u.attachments)==null?void 0:d.some(m=>m.name==="trace")}),"hasTrace");for(let l of this.report.files)for(let u of l.tests)if(u.testId===n&&u.projectName===r&&o(u.results))return!0;return!1}catch(n){return console.warn("Failed to check if test has trace, assuming trace exists",n),!0}}async initializeDOM(){return this.dom=await Dm.JSDOM.fromFile(this.reportHTMLFilePath,{resources:"usable",runScripts:"dangerously"}),new Promise(t=>this.dom.window.addEventListener("load",t))}async writeFile(){let t=this.dom.serialize();t=t.replace(/window.playwrightReportBase64 = ".*";/,`window.playwrightReportBase64 = "${this.newBase64Zip}";`),(0,Om.writeFileSync)(this.getProcessedFilePath(),t)}getProcessedFilePath(){return this.reportHTMLFilePath.replace(".html",`.${this.testRunUUID}.html`)}getReportsStats(){return this.stats}makeLightModeOnly(){try{this.dom.window.document.querySelector('meta[name="color-scheme"]').setAttribute("content","light");let r=this.dom.window.document.querySelector("head style"),n=r.innerHTML,o=/@media\s*\(prefers-color-scheme:\s*dark\)\s*{[^}]*}/g,l=n.replace(o,"");r.innerHTML=l}catch{}}async editZipFile(){let t=this.dom.window.playwrightReportBase64.replace("data:application/zip;base64,",""),r=await(0,Bm.loadAsync)(t,{base64:!0});for(let o of Object.keys(r.files)){let l=r.file(o);if(l){let u=await l.async("string"),d=JSON.parse(u);o.startsWith("report")?(this.handleReportJSON(d),this.extractStats(d),this.report=d):this.handleFileReportJSON(d),r.file(o,JSON.stringify(d))}}let n=await r.generateAsync({type:"base64",compression:"DEFLATE"});this.newBase64Zip=`data:application/zip;base64,${n}`}extractStats(t){if(!t.stats)return;let r=a(u=>isNaN(u)?0:u,"getStat"),{expected:n,unexpected:o,flaky:l}=t.stats;this.stats={passed:r(l)+r(n),failed:r(o)}}getCloudURL(t){return`${this.config.assetsBaseURL}/${this.testRunUUID}/report-data-file-url?fileName=${(0,Lm.basename)(t)}`}handleReportJSON(t){t.files.forEach(r=>r.tests.forEach(n=>{n.results.forEach(o=>{this.processAttachments(o.attachments,n.testId)})}))}handleFileReportJSON(t){var r;(r=t.tests)==null||r.forEach(n=>{var o;(o=n.results)==null||o.forEach(l=>{this.processAttachments(l.attachments,n.testId)})})}processAttachments(t,r){if(t.forEach(n=>this.updateAttachment(n,r)),!this.supportVideo){let n=t.findIndex(o=>o.name==="video");n!==-1&&t.splice(n,1)}}updateAttachment(t,r){t.path&&(t.path=this.getCloudURL(t.path))}};a(yu,"PlaywrightReportProcessor");var po=yu;var Zm=require("http");var Z=require("fs"),vu=Fe(ho()),wu=require("stream/promises"),zm=require("crypto"),Ir=require("path");var _u,Su=class Su{constructor(t,r,n,o,l=!1){this.mode=t;this.traceDir=r;this.outputZipFilePath=n;this.frontendLogPrefix=o;this.deleteOriginalFiles=l;this.wallTimesToBeRemoved={};this.callIdsRemovals={};this.consoleLogGUIDs=[];this.numberOfLinesPerFile={};this.unarchiveFolder=(0,zm.randomUUID)();this.resourcesFolder=(0,Ir.join)(this.unarchiveFolder,"resources");this.runningIndexes={trace:0,network:0,stacks:0};this.zipFilesBuffers={};this.generationAllowedAPIName=["page.goto","page.waitForNavigation","page.waitForTimeout","locator.fill","locator.click","locator.hover","locator.check","locator.uncheck","locator.dblclick","locator.dragTo"];let{createInterface:u}=require("readline/promises");_u=u}async process(){if(this.mode==="runtime")return!1;try{if(!(0,Z.existsSync)(this.traceDir))return!1;let r=(0,Z.readdirSync)(this.traceDir).filter(n=>n.endsWith(".zip")).sort((n,o)=>{let l=a(m=>{try{let c=m.split(".");return parseInt(c[c.length-2])}catch{return 0}},"getIndex"),u=l(n),d=l(o);return u-d});if(!r.length)return!1;(0,Z.mkdirSync)(this.unarchiveFolder),(0,Z.mkdirSync)(this.resourcesFolder);for(let n of r)await this.processOne((0,Ir.join)(this.traceDir,n));if(await this.reZip(),(0,Z.rmdirSync)(this.unarchiveFolder,{recursive:!0}),this.deleteOriginalFiles)for(let n of r)(0,Z.rmSync)((0,Ir.join)(this.traceDir,n))}catch(t){return console.log("There was an error processing the trace files",t),!1}return!0}getBuffer(t){return this.zipFilesBuffers[t]??(0,Z.readFileSync)(t)}async processOne(t){let n=(await this.unzipAndWriteFiles(t)).trace.map(l=>(0,Ir.join)(this.unarchiveFolder,l));for(let l of n)await this.preprocessFile(l);let o=[...n];for(;o.length>0;)for(let l of o)await this.processFile(l,o)}async unzipAndWriteFiles(t){let r=(0,Z.readFileSync)(t);this.zipFilesBuffers[t]=r;let n=await(0,vu.loadAsync)(r),o={trace:[],network:[],stacks:[]},l=a(u=>{let d=a((m,c)=>(o[c].push(m),m),"addToUnarchivedFiles");return u.endsWith(".trace")?d(`trace${this.runningIndexes.trace++}.trace`,"trace"):u.endsWith(".network")?d(`trace${this.runningIndexes.network++}.network`,"network"):u.endsWith(".stacks")?d(`trace${this.runningIndexes.stacks++}.stacks`,"stacks"):null},"getNewFileName");for(let u of Object.keys(n.files)){let d=l(u);if(!d)continue;let m=n.file(u).nodeStream(),c=(0,Z.createWriteStream)(`${this.unarchiveFolder}/${d}`);await(0,wu.pipeline)(m,c)}for(let u of Object.keys(n.files)){if(!u.startsWith("resources/"))continue;let d=u.replace("resources/",""),m=`${this.resourcesFolder}/${d}`;if(this.mode==="generation"&&d.startsWith("src@")||(0,Z.existsSync)(m))continue;let c=n.file(u).nodeStream(),h=(0,Z.createWriteStream)(m);await(0,wu.pipeline)(c,h)}return o}async reZip(){let t=await(0,vu.loadAsync)("UEsFBgAAAAAAAAAAAAAAAAAAAAAAAA==",{base64:!0});for(let o of(0,Z.readdirSync)(this.unarchiveFolder))if(o.endsWith(".network")||this.shouldIncludeStacksFiles()&&o.endsWith(".stacks")||o.endsWith(".trace")){let l=(0,Z.readFileSync)((0,Ir.join)(this.unarchiveFolder,o));t.file(o,l)}let r=t.folder("resources");for(let o of(0,Z.readdirSync)(this.resourcesFolder)){let l=(0,Z.readFileSync)((0,Ir.join)(this.resourcesFolder,o));r.file(o,l)}let n=await t.generateAsync({type:"nodebuffer",compression:"DEFLATE"});(0,Z.existsSync)(this.outputZipFilePath)&&(0,Z.rmSync)(this.outputZipFilePath),(0,Z.writeFileSync)(this.outputZipFilePath,n)}async preprocessFile(t){this.callIdsRemovals[t]={callIdsToBeRemoved:{},arrayOfCallIdsToBeRemoved:new Set};let r=(0,Z.createReadStream)(t),n=_u({input:r,crlfDelay:1/0}),o=0;for await(let l of n){o++;let u=JSON.parse(l);this.shouldLineBeRemoved(u)&&(u.wallTime&&(this.wallTimesToBeRemoved[u.wallTime]=!0),u.callId&&(this.callIdsRemovals[t].callIdsToBeRemoved[u.callId]=!0,this.callIdsRemovals[t].arrayOfCallIdsToBeRemoved.add(u.callId)))}this.numberOfLinesPerFile[t]=o}async processFile(t,r){var d,m;let n=[],o=(0,Z.createReadStream)(t),l=_u({input:o,crlfDelay:1/0}),u=t;for await(let c of l){let h=JSON.parse(c),x=!1;if(this.frontendLogPrefix){if(this.isChecksumConsoleLog(h)){this.consoleLogGUIDs.push(h.guid);continue}if(this.isConsoleLogMetadata(h)&&this.consoleLogGUIDs.includes((m=(d=h.params)==null?void 0:d.message)==null?void 0:m.guid))continue}if(this.lineCanBeRemoved(h)&&(this.wallTimesToBeRemoved[h.wallTime]||this.callIdsRemovals[u].callIdsToBeRemoved[h.callId]||Array.from(this.callIdsRemovals[u].arrayOfCallIdsToBeRemoved).some(y=>c.includes(`"${y}"`)))&&(x=!0),x){h.callId&&(this.callIdsRemovals[u].callIdsToBeRemoved[h.callId]=!0,this.callIdsRemovals[u].arrayOfCallIdsToBeRemoved.add(h.callId));continue}n.push(c)}if(n.length===this.numberOfLinesPerFile[u]){let c=r.indexOf(u);c>-1&&r.splice(c,1)}else this.numberOfLinesPerFile[u]=n.length,(0,Z.writeFileSync)(t,n.join(`
|
|
16
|
-
`))}isChecksumConsoleLog(t){var r,n;return t.class==="ConsoleMessage"&&((n=(r=t.initializer)==null?void 0:r.text)==null?void 0:n.startsWith(this.frontendLogPrefix))||t.type==="console"&&t.text.startsWith(this.frontendLogPrefix)}isConsoleLogMetadata(t){return t.class==="BrowserContext"&&t.method==="console"}lineCanBeRemoved(t){return!["frame-snapshot"].includes(t.type)}shouldLineBeRemoved(t){switch(this.mode){case"runtime":return this.shouldLineBeRemoved_runtime(t);case"generation":return this.shouldLineBeRemoved_generation(t)}return!1}shouldLineBeRemoved_runtime(t){return!1}shouldIncludeStacksFiles(){return this.mode==="runtime"}shouldLineBeRemoved_generation(t){return!!t.apiName&&!this.generationAllowedAPIName.includes(t.apiName)}};a(Su,"PlaywrightTraceProcessor");var mo=Su;var qm=Fe(ho()),Fr=require("path"),rr=require("fs");async function Um(e,t){let r=await(0,rr.readdirSync)(t);await Promise.all(r.map(async n=>{let o=(0,Fr.join)(t,n);if((await(0,rr.statSync)(o)).isDirectory()){let u=e.folder(n);await Um(u,o)}else{let u=await(0,rr.readFileSync)(o);e.file(n,u)}}))}a(Um,"addFolderToZip");async function Mm(e){try{let t=await(0,qm.loadAsync)("UEsFBgAAAAAAAAAAAAAAAAAAAAAAAA==",{base64:!0});await Um(t,e);let r=await t.generateAsync({type:"nodebuffer",compression:"DEFLATE"}),n=(0,Fr.join)((0,Fr.dirname)(e),`${(0,Fr.basename)(e)}.zip`);return(0,rr.writeFileSync)(n,r),n}catch(t){return console.error("Error creating zip:",t),null}}a(Mm,"zipFolder");var Oi=a(e=>new Promise(t=>setTimeout(t,e)),"awaitSleep"),Wm=a(async(e,t=1e3,r="guardReturnTimedOut")=>{if(t===null)return e;let n="guard-timed-out",o=a(async()=>(await Oi(t+1e3),n),"guard"),l=await Promise.race([e,o()]);if(typeof l=="string"&&l===n)throw new Error(r);return l},"guardReturn");var Nm={trace:"application/zip","trace-backup-file":"application/zip",har:"application/zip",report:"text/html"},Vw={click:"click",fill:"input",click_and_type:"click_and_type",clear_and_type:"clear_and_type",double_click:"double_click",drag_and_drop:"drag_and_drop",hover:"hover",navigate:"navigation",keystroke:"keystroke",selectoption:"selectoption",upload_files:"upload_files",wait:"wait",get_more_items:"get_more_items",reset:void 0,save:void 0,fail:void 0,finish:void 0,dismiss_modal:void 0,vision_help:void 0,switch_tab:"switch_tab",expand_interactable_elements:void 0,approve_release:void 0,logout_and_login:"logout_and_login",canvas_click:"canvas_click"},Qx=Object.fromEntries(Object.entries(Vw).map(([e,t])=>[t,e]));var jm=require("request"),bo=require("fs");var Ru=class Ru{constructor(t,r,n,o,l,u=console.log){this.apiBaseURL=t;this.apiKey=r;this.uploadTimeout=n;this.makeGetUploadUrlAPIPath=o;this.onOutstandingUpload=l;this.log=u}async uploadAsset(t){try{let{path:r}=t.info;if(this.log("Uploading file",r),await this.getSignedURLForUpload(t),!t.uploadURL){this.log("Error getting signed URL for asset",r),t.error=!0;return}let o=(0,bo.statSync)(r).size,l=(0,bo.createReadStream)(r),u=Wm(new Promise((d,m)=>{var h;let c=(0,jm.put)(t.uploadURL,{body:l,headers:{"Content-Type":Nm[t.info.type]??""}},(x,y)=>{x&&m(x),d(y)});(h=this.onOutstandingUpload)==null||h.call(this,{request:c,size:o})}),this.uploadTimeout);u.then(d=>{if(d.statusCode!==200)throw new Error("Upload failed");this.log("File uploaded successfully",r),t.complete=!0}).catch(d=>{this.log("Error uploading asset",r,d),t.error=!0}),t.response=u}catch{t.error=!0}}async getSignedURLForUpload(t){try{let r=t.info,n=await fetch(`${this.apiBaseURL}/${this.makeGetUploadUrlAPIPath(t)}`,{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json",ChecksumAppCode:this.apiKey},body:JSON.stringify(r)}),{url:o}=await n.json();t.uploadURL=o}catch(r){return this.log("Error getting signed URL for artifact",r),null}}};a(Ru,"TestAssetUploader");var go=Ru;var Vm=require("crypto");var Tu=class Tu{constructor(t,r=!1){this.config=t;this.isolationMode=r;this.MAX_UPLOADS=5;this.MONITOR_INTERVAL=2500;this.UPLOAD_TIMEOUT=10*60*1e3;this.WATCH_TIMEOUT=2*60*1e3;this.assets=[];this.watchAssets=[];this.reportComplete=!1;this.processingInProgress=!1;this.pwTestIdToChecksumTestId={};this.outstandingUploads=[];this.testAssetUploader=new go(t.apiURL,t.apiKey,this.UPLOAD_TIMEOUT,()=>`client-api/test-runs/${this.config.sessionId}/get-upload-url`,({request:n,size:o})=>{this.outstandingUploads.push({request:n,size:o})},this.log),setInterval(this.monitorUploads.bind(this),this.MONITOR_INTERVAL),this.listenForMessages(),this.startServer()}listenForMessages(){process.stdin.on("data",async t=>{let r=t.toString().trim();if(!r.startsWith("cli:"))return;let[n,o]=r.substring(4).split("=");switch(this.log("Received message from CLI "+n+" "+o),n){case"report":this.testRunEndTime=Date.now(),o!=="false"?await this.handleReport(o):this.reportComplete=!0,this.monitorUploadsCompletion();break;case"shutdown":this.shutdown();break}})}sendMessage(t){setTimeout(()=>{this.log(`monitor:${t}`)},100)}sendLogToConsole(t){this.sendMessage(`log=${t}`)}async handleReport(t){this.log(`Handling report ${this.isolationMode?"(isolation mode)":""}`+t),this.uploadReportData((0,Qe.dirname)(t));try{let r=new po(t,this.config.sessionId,this.pwTestIdToChecksumTestId,{hosted:!this.isolationMode});try{await r.process(),this.reportAsset=this.initAsset({type:"report",path:r.getProcessedFilePath()}),this.isolationMode?this.reportAsset.complete=!0:this.uploadAsset(this.reportAsset)}catch(o){this.log("Error processing report, "+o.message),this.reportAsset.error=!0}this.stats=r.getReportsStats(),this.log("Checking watch assets");let n=this.watchAssets.filter(o=>!(o.type!=="trace"||r.testHasTrace(o.testId,o.project)));n.length>0&&(this.log("Removed watch assets - "),this.log(JSON.stringify(n.map(o=>o.path)))),this.watchAssets=this.watchAssets.filter(o=>o.type!=="trace"||r.testHasTrace(o.testId,o.project))}catch(r){this.log("Error processing report, "+this.stringify(r)),this.reportAsset.error=!0}}async uploadReportData(t){let r=(0,Qe.join)(t,"data");try{let n=(0,nr.readdirSync)(r),o=[".zip",".webm"],l=n.filter(u=>!o.includes((0,Qe.extname)(u)));this.log("Preparing to upload report data files,"+l);for(let u of l)this.log("Uploading report data file,"+u),this.addAsset({type:"report-data-file",fileName:u,path:`${r}/${u}`})}catch(n){this.log(`Error reading/adding report data files from dir ${r}`+n.message)}}shutdown(){this.log("Received shutdown message from CLI"),this.server.close(),process.exit(0)}async monitorUploadsCompletion(){var t;if(!this.reportComplete&&this.reportAsset&&(this.reportAsset.complete||this.reportAsset.error)){this.reportComplete=!0;let r="{}";try{r=JSON.stringify(this.stats)}catch{this.log("Error stringifying stats")}this.sendMessage(`report-complete=${(t=this.reportAsset)!=null&&t.complete?"true":"false"}:${r}`)}if(!this.processingInProgress&&this.reportComplete&&this.assets.filter(r=>r.complete||r.error).length===this.assets.length&&(this.watchAssets.length===0||this.testRunEndTime&&Date.now()-this.testRunEndTime>this.WATCH_TIMEOUT)){let r=this.assets.find(o=>o.error)?"complete-with-errors":"complete",n=r==="complete"?{}:{uploadErrors:this.assets.filter(o=>o.error),watchAssets:this.watchAssets,testRunEndTime:this.testRunEndTime,now:Date.now()};this.sendMessage(`${r}=${JSON.stringify(n)}`);return}await Oi(1e3),this.monitorUploadsCompletion()}async startServer(){let t=await this.acquirePortNumber();this.sendMessage(`port=${t}`),this.server=(0,Zm.createServer)((r,n)=>{let o=a(u=>{n.writeHead(400,{"Content-Type":"text/plain"}),n.end(u)},"returnErrorWithMessage");if(r.method!=="POST"){n.writeHead(404,{"Content-Type":"text/plain"}),n.end("Method not allowed");return}let l="";r.on("data",u=>{l+=u.toString()}),r.on("end",()=>{let u;try{u=JSON.parse(l)}catch{return o("Invalid body")}let{type:d,payload:m,watch:c}=u;switch(this.log(`Server received message, ${d}, ${this.stringify(m)}`),d){case"asset":if(!m.path||!m.type)return o("Missing arguments");c?this.watchAsset(m):this.processAsset(m);break;case"testInfo":if(!m.pwTestId||!m.checksumTestId)return o("Missing arguments");this.pwTestIdToChecksumTestId[m.pwTestId]=m.checksumTestId;break;case"testStats":break;case"playwrightConfig":this.sendMessage(`playwrightConfig=${JSON.stringify(m)}`);break;default:return o("Invalid message type")}n.writeHead(200,{"Content-Type":"text/plain"}),n.end("OK")})}),this.server.listen(t)}stringify(t){try{return JSON.stringify(t)}catch{return"message"in t?t.message:t}}monitorUploads(){let{totalSize:t,totalUploaded:r}=this.calculateUploadProgress();if(t>0){let l=(r/t*100).toFixed(2);this.sendMessage(`upload-progress=${l}`)}let n=a(()=>this.assets.filter(l=>l.response&&!l.complete&&!l.error),"getActiveUploads"),o=this.assets.filter(l=>!l.response);if(o.length!==0&&!(n().length>=this.MAX_UPLOADS))for(;o.length>0&&n().length<this.MAX_UPLOADS;){let l=o.pop();this.uploadAsset(l)}}calculateUploadProgress(){let{totalSize:t,totalUploaded:r}=this.outstandingUploads.reduce((n,{size:o,request:l})=>(n.totalSize+=o,n.totalUploaded+=l.req.connection._bytesDispatched,n),{totalSize:0,totalUploaded:0});return{totalSize:t,totalUploaded:Math.min(t,r)}}getUploadLogMessage(t){switch(t.info.type){case"report":return"Uploading report";case"har":return`Uploading har file for test ${t.info.testId}`;case"trace":return`Uploading trace file for test ${t.info.testId}`;case"esra":return`Uploading metadata file for test ${t.info.testId}`;case"test-files":return`Uploading auto-healed test code for file ${t.info.path}`}}async uploadAsset(t){try{if(this.isolationMode){t.response=new Promise(n=>{setTimeout(()=>{t.complete=!0,n({statusCode:200,ok:!0,body:"OK"})},10)});return}let r=this.getUploadLogMessage(t);r&&this.sendMessage(`log=${r}`),await this.testAssetUploader.uploadAsset(t)}catch{t.error=!0}}async getSignedURLForUpload(t){try{let{apiKey:r,sessionId:n,apiURL:o}=this.config,l=t.info,u=await va(`${o}/client-api/test-runs/${n}/get-upload-url`,{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json",ChecksumAppCode:r},body:JSON.stringify(l)}),{url:d}=await u.json();t.uploadURL=d}catch(r){return this.log("Error getting signed URL for artifact"+this.stringify(r)),null}}watchAsset(t){this.log("Watching file "+t.path),this.watchAssets.push({...t,addedAt:Date.now()});let r=(0,Qe.dirname)(t.path),n=(0,Qe.basename)(t.path),o=!1,l=(0,nr.watch)(r,async(u,d)=>{if(!(d!==n||o))try{if(this.log("Watched file changed "+t.path),o=!0,!await this.waitForFileComplete(t.path))return;this.processAsset(t),this.watchAssets=this.watchAssets.filter(c=>c.path!==t.path)}finally{l.close()}})}waitForFileComplete(t,r=1e3,n=6e4,o=1){return new Promise(l=>{let u=Date.now(),d=0,m=a(()=>{if(!(0,nr.existsSync)(t))return this.sendLogToConsole(`Asset required for upload doesn't exist anymore ${t}`),l(!1);let c=(0,nr.statSync)(t).size;if(c===d){if(o>0){this.log(`File size has not changed, verifying stabilization, ${t}, size: ${c}, equalSizeValidationCountLeft: ${o}`),o--,setTimeout(m,r);return}return this.log(`File size has not changed, stabilization verified, ${t}, size: ${c}`),l(!0)}if(this.log(`File size changed, waiting for stabilization, ${t}, previous size: ${d}, current size: ${c}`),Date.now()-u>n)return this.sendLogToConsole(`Asset required for upload is taking over ${n} ms to write to disk ${t}`),l(!0);d=c,setTimeout(m,r)},"checkFile");m()})}processAsset(t){switch(t.type){case"trace":return this.processTrace(t.path,t.testId);case"har":return this.processHar(t.path,t.testId);case"esra":case"test-files":return this.addAsset(t)}}async processHar(t,r){await Oi(1e3);let n=await Mm(t);if(this.log("Processed har, sending for upload"),n)return this.addAsset({type:"har",path:n,testId:r})}calculateSha1(t){let r=(0,Vm.createHash)("sha1");return r.update(t),r.digest("hex")}async processTrace(t,r){try{this.processingInProgress=!0,await Oi(1e3);let n=t.replace(".zip",".processed.zip"),o=new mo("runtime",(0,Qe.dirname)(t),n,"$checksum"),l=await o.process(),d=a(()=>{let m=o.getBuffer(t);return this.calculateSha1(m)+(0,Qe.extname)(t)},"makePlaywrightHTMLReporterName")();l?(this.log("Processed trace files and sending for upload"),this.addAsset({type:"report-data-file",path:n,testId:r,fileName:d}),this.addAsset({type:"report-data-file",path:t,testId:r,fileName:`${d}.original`})):(this.log("Trace file has not been processed, sending original file for upload"),this.addAsset({type:"report-data-file",path:t,testId:r,fileName:d}))}catch(n){this.log("Error processing trace file"+this.stringify(n))}finally{this.processingInProgress=!1}}addAsset(t){this.log("Adding file "+t.path);let r=this.initAsset(t);return this.assets.push(r),r}initAsset(t){return{complete:!1,error:!1,response:void 0,info:t}}async acquirePortNumber(){return await new Promise((t,r)=>{let n=$m.createServer();n.unref(),n.on("error",r),n.listen(0,()=>{let o=n.address().port;n.close(()=>{t(o)})})})}log(t){console.log(`{trm}${t}{/trm}`)}};a(Tu,"TestRunMonitor");var yo=Tu,Gm;try{Gm=JSON.parse(process.argv[2])}catch(e){console.log("Error starting test run monitor",e),process.exit(1)}var Hm;new yo(Gm,((Hm=process.argv)==null?void 0:Hm[3])==="isolated");0&&(module.exports={TestRunMonitor});
|
|
16
|
+
`))}isChecksumConsoleLog(t){var r,n;return t.class==="ConsoleMessage"&&((n=(r=t.initializer)==null?void 0:r.text)==null?void 0:n.startsWith(this.frontendLogPrefix))||t.type==="console"&&t.text.startsWith(this.frontendLogPrefix)}isConsoleLogMetadata(t){return t.class==="BrowserContext"&&t.method==="console"}lineCanBeRemoved(t){return!["frame-snapshot"].includes(t.type)}shouldLineBeRemoved(t){switch(this.mode){case"runtime":return this.shouldLineBeRemoved_runtime(t);case"generation":return this.shouldLineBeRemoved_generation(t)}return!1}shouldLineBeRemoved_runtime(t){return!1}shouldIncludeStacksFiles(){return this.mode==="runtime"}shouldLineBeRemoved_generation(t){return!!t.apiName&&!this.generationAllowedAPIName.includes(t.apiName)}};a(Su,"PlaywrightTraceProcessor");var mo=Su;var qm=Fe(ho()),Fr=require("path"),rr=require("fs");async function Um(e,t){let r=await(0,rr.readdirSync)(t);await Promise.all(r.map(async n=>{let o=(0,Fr.join)(t,n);if((await(0,rr.statSync)(o)).isDirectory()){let u=e.folder(n);await Um(u,o)}else{let u=await(0,rr.readFileSync)(o);e.file(n,u)}}))}a(Um,"addFolderToZip");async function Mm(e){try{let t=await(0,qm.loadAsync)("UEsFBgAAAAAAAAAAAAAAAAAAAAAAAA==",{base64:!0});await Um(t,e);let r=await t.generateAsync({type:"nodebuffer",compression:"DEFLATE"}),n=(0,Fr.join)((0,Fr.dirname)(e),`${(0,Fr.basename)(e)}.zip`);return(0,rr.writeFileSync)(n,r),n}catch(t){return console.error("Error creating zip:",t),null}}a(Mm,"zipFolder");var Oi=a(e=>new Promise(t=>setTimeout(t,e)),"awaitSleep"),Wm=a(async(e,t=1e3,r="guardReturnTimedOut")=>{if(t===null)return e;let n="guard-timed-out",o=a(async()=>(await Oi(t+1e3),n),"guard"),l=await Promise.race([e,o()]);if(typeof l=="string"&&l===n)throw new Error(r);return l},"guardReturn");var Nm={trace:"application/zip","trace-backup-file":"application/zip",har:"application/zip",report:"text/html"},Vw={click:"click",fill:"input",click_and_type:"click_and_type",clear_and_type:"clear_and_type",double_click:"double_click",drag_and_drop:"drag_and_drop",hover:"hover",navigate:"navigation",keystroke:"keystroke",selectoption:"selectoption",upload_files:"upload_files",wait:"wait",get_more_items:"get_more_items",reset:void 0,save:void 0,fail:void 0,finish:void 0,dismiss_modal:void 0,vision_help:void 0,switch_tab:"switch_tab",expand_interactable_elements:void 0,approve_release:void 0,logout_and_login:"logout_and_login",canvas_click:"canvas_click"},Qx=Object.fromEntries(Object.entries(Vw).map(([e,t])=>[t,e]));var jm=require("request"),bo=require("fs");var Tu=class Tu{constructor(t,r,n,o,l,u=console.log){this.apiBaseURL=t;this.apiKey=r;this.uploadTimeout=n;this.makeGetUploadUrlAPIPath=o;this.onOutstandingUpload=l;this.log=u}async uploadAsset(t){try{let{path:r}=t.info;if(this.log("Uploading file",r),await this.getSignedURLForUpload(t),!t.uploadURL){this.log("Error getting signed URL for asset",r),t.error=!0;return}let o=(0,bo.statSync)(r).size,l=(0,bo.createReadStream)(r),u=Wm(new Promise((d,m)=>{var h;let c=(0,jm.put)(t.uploadURL,{body:l,headers:{"Content-Type":Nm[t.info.type]??""}},(x,y)=>{x&&m(x),d(y)});(h=this.onOutstandingUpload)==null||h.call(this,{request:c,size:o})}),this.uploadTimeout);u.then(d=>{if(d.statusCode!==200)throw new Error("Upload failed");this.log("File uploaded successfully",r),t.complete=!0}).catch(d=>{this.log("Error uploading asset",r,d),t.error=!0}),t.response=u}catch{t.error=!0}}async getSignedURLForUpload(t){try{let r=t.info,n=await fetch(`${this.apiBaseURL}/${this.makeGetUploadUrlAPIPath(t)}`,{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json",ChecksumAppCode:this.apiKey},body:JSON.stringify(r)}),{url:o}=await n.json();t.uploadURL=o}catch(r){return this.log("Error getting signed URL for artifact",r),null}}};a(Tu,"TestAssetUploader");var go=Tu;var Vm=require("crypto");var Ru=class Ru{constructor(t,r=!1){this.config=t;this.isolationMode=r;this.MAX_UPLOADS=5;this.MONITOR_INTERVAL=2500;this.UPLOAD_TIMEOUT=10*60*1e3;this.WATCH_TIMEOUT=2*60*1e3;this.assets=[];this.watchAssets=[];this.reportComplete=!1;this.processingInProgress=!1;this.pwTestIdToChecksumTestId={};this.outstandingUploads=[];this.testAssetUploader=new go(t.apiURL,t.apiKey,this.UPLOAD_TIMEOUT,()=>`client-api/test-runs/${this.config.sessionId}/get-upload-url`,({request:n,size:o})=>{this.outstandingUploads.push({request:n,size:o})},this.log),setInterval(this.monitorUploads.bind(this),this.MONITOR_INTERVAL),this.listenForMessages(),this.startServer()}listenForMessages(){process.stdin.on("data",async t=>{let r=t.toString().trim();if(!r.startsWith("cli:"))return;let[n,o]=r.substring(4).split("=");switch(this.log("Received message from CLI "+n+" "+o),n){case"report":this.testRunEndTime=Date.now(),o!=="false"?await this.handleReport(o):this.reportComplete=!0,this.monitorUploadsCompletion();break;case"shutdown":this.shutdown();break}})}sendMessage(t){setTimeout(()=>{this.log(`monitor:${t}`)},100)}sendLogToConsole(t){this.sendMessage(`log=${t}`)}async handleReport(t){this.log(`Handling report ${this.isolationMode?"(isolation mode)":""}`+t),this.uploadReportData((0,Qe.dirname)(t));try{let r=new po(t,this.config.sessionId,this.pwTestIdToChecksumTestId,{hosted:!this.isolationMode});try{await r.process(),this.reportAsset=this.initAsset({type:"report",path:r.getProcessedFilePath()}),this.isolationMode?this.reportAsset.complete=!0:this.uploadAsset(this.reportAsset)}catch(o){this.log("Error processing report, "+o.message),this.reportAsset.error=!0}this.stats=r.getReportsStats(),this.log("Checking watch assets");let n=this.watchAssets.filter(o=>!(o.type!=="trace"||r.testHasTrace(o.testId,o.project)));n.length>0&&(this.log("Removed watch assets - "),this.log(JSON.stringify(n.map(o=>o.path)))),this.watchAssets=this.watchAssets.filter(o=>o.type!=="trace"||r.testHasTrace(o.testId,o.project))}catch(r){this.log("Error processing report, "+this.stringify(r)),this.reportAsset.error=!0}}async uploadReportData(t){let r=(0,Qe.join)(t,"data");try{let n=(0,nr.readdirSync)(r),o=[".zip",".webm"],l=n.filter(u=>!o.includes((0,Qe.extname)(u)));this.log("Preparing to upload report data files,"+l);for(let u of l)this.log("Uploading report data file,"+u),this.addAsset({type:"report-data-file",fileName:u,path:`${r}/${u}`})}catch(n){this.log(`Error reading/adding report data files from dir ${r}`+n.message)}}shutdown(){this.log("Received shutdown message from CLI"),this.server.close(),process.exit(0)}async monitorUploadsCompletion(){var t;if(!this.reportComplete&&this.reportAsset&&(this.reportAsset.complete||this.reportAsset.error)){this.reportComplete=!0;let r="{}";try{r=JSON.stringify(this.stats)}catch{this.log("Error stringifying stats")}this.sendMessage(`report-complete=${(t=this.reportAsset)!=null&&t.complete?"true":"false"}:${r}`)}if(!this.processingInProgress&&this.reportComplete&&this.assets.filter(r=>r.complete||r.error).length===this.assets.length&&(this.watchAssets.length===0||this.testRunEndTime&&Date.now()-this.testRunEndTime>this.WATCH_TIMEOUT)){let r=this.assets.find(o=>o.error)?"complete-with-errors":"complete",n=r==="complete"?{}:{uploadErrors:this.assets.filter(o=>o.error),watchAssets:this.watchAssets,testRunEndTime:this.testRunEndTime,now:Date.now()};this.sendMessage(`${r}=${JSON.stringify(n)}`);return}await Oi(1e3),this.monitorUploadsCompletion()}async startServer(){let t=await this.acquirePortNumber();this.sendMessage(`port=${t}`),this.server=(0,Zm.createServer)((r,n)=>{let o=a(u=>{n.writeHead(400,{"Content-Type":"text/plain"}),n.end(u)},"returnErrorWithMessage");if(r.method!=="POST"){n.writeHead(404,{"Content-Type":"text/plain"}),n.end("Method not allowed");return}let l="";r.on("data",u=>{l+=u.toString()}),r.on("end",()=>{let u;try{u=JSON.parse(l)}catch{return o("Invalid body")}let{type:d,payload:m,watch:c}=u;switch(this.log(`Server received message, ${d}, ${this.stringify(m)}`),d){case"asset":if(!m.path||!m.type)return o("Missing arguments");c?this.watchAsset(m):this.processAsset(m);break;case"testInfo":if(!m.pwTestId||!m.checksumTestId)return o("Missing arguments");this.pwTestIdToChecksumTestId[m.pwTestId]=m.checksumTestId;break;case"testStats":break;case"playwrightConfig":this.sendMessage(`playwrightConfig=${JSON.stringify(m)}`);break;default:return o("Invalid message type")}n.writeHead(200,{"Content-Type":"text/plain"}),n.end("OK")})}),this.server.listen(t)}stringify(t){try{return JSON.stringify(t)}catch{return"message"in t?t.message:t}}monitorUploads(){let{totalSize:t,totalUploaded:r}=this.calculateUploadProgress();if(t>0){let l=(r/t*100).toFixed(2);this.sendMessage(`upload-progress=${l}`)}let n=a(()=>this.assets.filter(l=>l.response&&!l.complete&&!l.error),"getActiveUploads"),o=this.assets.filter(l=>!l.response);if(o.length!==0&&!(n().length>=this.MAX_UPLOADS))for(;o.length>0&&n().length<this.MAX_UPLOADS;){let l=o.pop();this.uploadAsset(l)}}calculateUploadProgress(){let{totalSize:t,totalUploaded:r}=this.outstandingUploads.reduce((n,{size:o,request:l})=>(n.totalSize+=o,n.totalUploaded+=l.req.connection._bytesDispatched,n),{totalSize:0,totalUploaded:0});return{totalSize:t,totalUploaded:Math.min(t,r)}}getUploadLogMessage(t){switch(t.info.type){case"report":return"Uploading report";case"har":return`Uploading har file for test ${t.info.testId}`;case"trace":return`Uploading trace file for test ${t.info.testId}`;case"esra":return`Uploading metadata file for test ${t.info.testId}`;case"test-files":return`Uploading auto-healed test code for file ${t.info.path}`}}async uploadAsset(t){try{if(this.isolationMode){t.response=new Promise(n=>{setTimeout(()=>{t.complete=!0,n({statusCode:200,ok:!0,body:"OK"})},10)});return}let r=this.getUploadLogMessage(t);r&&this.sendMessage(`log=${r}`),await this.testAssetUploader.uploadAsset(t)}catch{t.error=!0}}async getSignedURLForUpload(t){try{let{apiKey:r,sessionId:n,apiURL:o}=this.config,l=t.info,u=await va(`${o}/client-api/test-runs/${n}/get-upload-url`,{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json",ChecksumAppCode:r},body:JSON.stringify(l)}),{url:d}=await u.json();t.uploadURL=d}catch(r){return this.log("Error getting signed URL for artifact"+this.stringify(r)),null}}watchAsset(t){this.log("Watching file "+t.path),this.watchAssets.push({...t,addedAt:Date.now()});let r=(0,Qe.dirname)(t.path),n=(0,Qe.basename)(t.path),o=!1,l=(0,nr.watch)(r,async(u,d)=>{if(!(d!==n||o))try{if(this.log("Watched file changed "+t.path),o=!0,!await this.waitForFileComplete(t.path))return;this.processAsset(t),this.watchAssets=this.watchAssets.filter(c=>c.path!==t.path)}finally{l.close()}})}waitForFileComplete(t,r=1e3,n=6e4,o=1){return new Promise(l=>{let u=Date.now(),d=0,m=a(()=>{if(!(0,nr.existsSync)(t))return this.sendLogToConsole(`Asset required for upload doesn't exist anymore ${t}`),l(!1);let c=(0,nr.statSync)(t).size;if(c===d){if(o>0){this.log(`File size has not changed, verifying stabilization, ${t}, size: ${c}, equalSizeValidationCountLeft: ${o}`),o--,setTimeout(m,r);return}return this.log(`File size has not changed, stabilization verified, ${t}, size: ${c}`),l(!0)}if(this.log(`File size changed, waiting for stabilization, ${t}, previous size: ${d}, current size: ${c}`),Date.now()-u>n)return this.sendLogToConsole(`Asset required for upload is taking over ${n} ms to write to disk ${t}`),l(!0);d=c,setTimeout(m,r)},"checkFile");m()})}processAsset(t){switch(t.type){case"trace":return this.processTrace(t.path,t.testId);case"har":return this.processHar(t.path,t.testId);case"esra":case"test-files":return this.addAsset(t)}}async processHar(t,r){await Oi(1e3);let n=await Mm(t);if(this.log("Processed har, sending for upload"),n)return this.addAsset({type:"har",path:n,testId:r})}calculateSha1(t){let r=(0,Vm.createHash)("sha1");return r.update(t),r.digest("hex")}async processTrace(t,r){try{this.processingInProgress=!0,await Oi(1e3);let n=t.replace(".zip",".processed.zip"),o=new mo("runtime",(0,Qe.dirname)(t),n,"$checksum"),l=await o.process(),d=a(()=>{let m=o.getBuffer(t);return this.calculateSha1(m)+(0,Qe.extname)(t)},"makePlaywrightHTMLReporterName")();l?(this.log("Processed trace files and sending for upload"),this.addAsset({type:"report-data-file",path:n,testId:r,fileName:d}),this.addAsset({type:"report-data-file",path:t,testId:r,fileName:`${d}.original`})):(this.log("Trace file has not been processed, sending original file for upload"),this.addAsset({type:"report-data-file",path:t,testId:r,fileName:d}))}catch(n){this.log("Error processing trace file"+this.stringify(n))}finally{this.processingInProgress=!1}}addAsset(t){this.log("Adding file "+t.path);let r=this.initAsset(t);return this.assets.push(r),r}initAsset(t){return{complete:!1,error:!1,response:void 0,info:t}}async acquirePortNumber(){return await new Promise((t,r)=>{let n=$m.createServer();n.unref(),n.on("error",r),n.listen(0,()=>{let o=n.address().port;n.close(()=>{t(o)})})})}log(t){console.log(`{trm}${t}{/trm}`)}};a(Ru,"TestRunMonitor");var yo=Ru,Gm;try{Gm=JSON.parse(process.argv[2])}catch(e){console.log("Error starting test run monitor",e),process.exit(1)}var Hm;new yo(Gm,((Hm=process.argv)==null?void 0:Hm[3])==="isolated");0&&(module.exports={TestRunMonitor});
|
|
17
17
|
/*! Bundled license information:
|
|
18
18
|
|
|
19
19
|
web-streams-polyfill/dist/ponyfill.es2018.js:
|