@sebbo2002/vestaboard2mqtt 6.0.3-develop.4 → 6.0.3-develop.6
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/dist/bin/start.cjs +1 -1
- package/dist/bin/start.cjs.map +1 -1
- package/dist/bin/start.js +1 -1
- package/dist/{chunk-JCVHJVDZ.js → chunk-GAFNM5FO.js} +2 -2
- package/dist/{chunk-JCVHJVDZ.js.map → chunk-GAFNM5FO.js.map} +1 -1
- package/dist/lib/index.cjs +1 -1
- package/dist/lib/index.cjs.map +1 -1
- package/dist/lib/index.js +1 -1
- package/package.json +5 -5
package/dist/bin/start.cjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
"use strict";var bu=Object.create;var dr=Object.defineProperty;var wu=Object.getOwnPropertyDescriptor;var Su=Object.getOwnPropertyNames;var Eu=Object.getPrototypeOf,xu=Object.prototype.hasOwnProperty;var U=(t,e)=>()=>(t&&(e=t(t=0)),e);var g=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),Tu=(t,e)=>{for(var r in e)dr(t,r,{get:e[r],enumerable:!0})},Gn=(t,e,r,i)=>{if(e&&typeof e=="object"||typeof e=="function")for(let n of Su(e))!xu.call(t,n)&&n!==r&&dr(t,n,{get:()=>e[n],enumerable:!(i=wu(e,n))||i.enumerable});return t};var ui=(t,e,r)=>(r=t!=null?bu(Eu(t)):{},Gn(e||!t||!t.__esModule?dr(r,"default",{value:t,enumerable:!0}):r,t)),Cu=t=>Gn(dr({},"__esModule",{value:!0}),t);var pr=g((Qg,Qn)=>{"use strict";Qn.exports=Ou;var Pu=Object.prototype.hasOwnProperty;function Ou(){for(var t={},e=0;e<arguments.length;e++){var r=arguments[e];for(var i in r)Pu.call(r,i)&&(t[i]=r[i])}return t}});var fi=g((Yg,Yn)=>{"use strict";Yn.exports=require("stream")});var es=g((Xg,Zn)=>{"use strict";function Xn(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter(function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable})),r.push.apply(r,i)}return r}function Iu(t){for(var e=1;e<arguments.length;e++){var r=arguments[e]!=null?arguments[e]:{};e%2?Xn(Object(r),!0).forEach(function(i){Ru(t,i,r[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):Xn(Object(r)).forEach(function(i){Object.defineProperty(t,i,Object.getOwnPropertyDescriptor(r,i))})}return t}function Ru(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function Au(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function Jn(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}function Bu(t,e,r){return e&&Jn(t.prototype,e),r&&Jn(t,r),t}var ku=require("buffer"),gr=ku.Buffer,Lu=require("util"),ci=Lu.inspect,Mu=ci&&ci.custom||"inspect";function qu(t,e,r){gr.prototype.copy.call(t,e,r)}Zn.exports=function(){function t(){Au(this,t),this.head=null,this.tail=null,this.length=0}return Bu(t,[{key:"push",value:function(r){var i={data:r,next:null};this.length>0?this.tail.next=i:this.head=i,this.tail=i,++this.length}},{key:"unshift",value:function(r){var i={data:r,next:this.head};this.length===0&&(this.tail=i),this.head=i,++this.length}},{key:"shift",value: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}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(r){if(this.length===0)return"";for(var i=this.head,n=""+i.data;i=i.next;)n+=r+i.data;return n}},{key:"concat",value:function(r){if(this.length===0)return gr.alloc(0);for(var i=gr.allocUnsafe(r>>>0),n=this.head,s=0;n;)qu(n.data,i,s),s+=n.data.length,n=n.next;return i}},{key:"consume",value:function(r,i){var n;return r<this.head.data.length?(n=this.head.data.slice(0,r),this.head.data=this.head.data.slice(r)):r===this.head.data.length?n=this.shift():n=i?this._getString(r):this._getBuffer(r),n}},{key:"first",value:function(){return this.head.data}},{key:"_getString",value:function(r){var i=this.head,n=1,s=i.data;for(r-=s.length;i=i.next;){var o=i.data,a=r>o.length?o.length:r;if(a===o.length?s+=o:s+=o.slice(0,r),r-=a,r===0){a===o.length?(++n,i.next?this.head=i.next:this.head=this.tail=null):(this.head=i,i.data=o.slice(a));break}++n}return this.length-=n,s}},{key:"_getBuffer",value:function(r){var i=gr.allocUnsafe(r),n=this.head,s=1;for(n.data.copy(i),r-=n.data.length;n=n.next;){var o=n.data,a=r>o.length?o.length:r;if(o.copy(i,i.length-r,0,a),r-=a,r===0){a===o.length?(++s,n.next?this.head=n.next:this.head=this.tail=null):(this.head=n,n.data=o.slice(a));break}++s}return this.length-=s,i}},{key:Mu,value:function(r,i){return ci(this,Iu({},i,{depth:0,customInspect:!1}))}}]),t}()});var di=g((Jg,rs)=>{"use strict";function Nu(t,e){var r=this,i=this._readableState&&this._readableState.destroyed,n=this._writableState&&this._writableState.destroyed;return i||n?(e?e(t):t&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,process.nextTick(hi,this,t)):process.nextTick(hi,this,t)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(t||null,function(s){!e&&s?r._writableState?r._writableState.errorEmitted?process.nextTick(yr,r):(r._writableState.errorEmitted=!0,process.nextTick(ts,r,s)):process.nextTick(ts,r,s):e?(process.nextTick(yr,r),e(s)):process.nextTick(yr,r)}),this)}function ts(t,e){hi(t,e),yr(t)}function yr(t){t._writableState&&!t._writableState.emitClose||t._readableState&&!t._readableState.emitClose||t.emit("close")}function Du(){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)}function hi(t,e){t.emit("error",e)}function Uu(t,e){var r=t._readableState,i=t._writableState;r&&r.autoDestroy||i&&i.autoDestroy?t.destroy(e):t.emit("error",e)}rs.exports={destroy:Nu,undestroy:Du,errorOrDestroy:Uu}});var Be=g((Zg,ss)=>{"use strict";var ns={};function ne(t,e,r){r||(r=Error);function i(s,o,a){return typeof e=="string"?e:e(s,o,a)}class n extends r{constructor(o,a,u){super(i(o,a,u))}}n.prototype.name=r.name,n.prototype.code=t,ns[t]=n}function is(t,e){if(Array.isArray(t)){let r=t.length;return t=t.map(i=>String(i)),r>2?`one of ${e} ${t.slice(0,r-1).join(", ")}, or `+t[r-1]:r===2?`one of ${e} ${t[0]} or ${t[1]}`:`of ${e} ${t[0]}`}else return`of ${e} ${String(t)}`}function ju(t,e,r){return t.substr(!r||r<0?0:+r,e.length)===e}function Fu(t,e,r){return(r===void 0||r>t.length)&&(r=t.length),t.substring(r-e.length,r)===e}function Wu(t,e,r){return typeof r!="number"&&(r=0),r+e.length>t.length?!1:t.indexOf(e,r)!==-1}ne("ERR_INVALID_OPT_VALUE",function(t,e){return'The value "'+e+'" is invalid for option "'+t+'"'},TypeError);ne("ERR_INVALID_ARG_TYPE",function(t,e,r){let i;typeof e=="string"&&ju(e,"not ")?(i="must not be",e=e.replace(/^not /,"")):i="must be";let n;if(Fu(t," argument"))n=`The ${t} ${i} ${is(e,"type")}`;else{let s=Wu(t,".")?"property":"argument";n=`The "${t}" ${s} ${i} ${is(e,"type")}`}return n+=`. Received type ${typeof r}`,n},TypeError);ne("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF");ne("ERR_METHOD_NOT_IMPLEMENTED",function(t){return"The "+t+" method is not implemented"});ne("ERR_STREAM_PREMATURE_CLOSE","Premature close");ne("ERR_STREAM_DESTROYED",function(t){return"Cannot call "+t+" after a stream was destroyed"});ne("ERR_MULTIPLE_CALLBACK","Callback called multiple times");ne("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable");ne("ERR_STREAM_WRITE_AFTER_END","write after end");ne("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError);ne("ERR_UNKNOWN_ENCODING",function(t){return"Unknown encoding: "+t},TypeError);ne("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event");ss.exports.codes=ns});var pi=g((ey,os)=>{"use strict";var Vu=Be().codes.ERR_INVALID_OPT_VALUE;function Hu(t,e,r){return t.highWaterMark!=null?t.highWaterMark:e?t[r]:null}function Ku(t,e,r,i){var n=Hu(e,i,r);if(n!=null){if(!(isFinite(n)&&Math.floor(n)===n)||n<0){var s=i?r:"highWaterMark";throw new Vu(s,n)}return Math.floor(n)}return t.objectMode?16:16*1024}os.exports={getHighWaterMark:Ku}});var as=g((ty,gi)=>{"use strict";typeof Object.create=="function"?gi.exports=function(e,r){r&&(e.super_=r,e.prototype=Object.create(r.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:gi.exports=function(e,r){if(r){e.super_=r;var i=function(){};i.prototype=r.prototype,e.prototype=new i,e.prototype.constructor=e}}});var we=g((ry,_i)=>{"use strict";try{if(yi=require("util"),typeof yi.inherits!="function")throw"";_i.exports=yi.inherits}catch{_i.exports=as()}var yi});var us=g((iy,ls)=>{"use strict";ls.exports=require("util").deprecate});var bi=g((ny,gs)=>{"use strict";gs.exports=L;function cs(t){var e=this;this.next=null,this.entry=null,this.finish=function(){vf(e,t)}}var yt;L.WritableState=Lt;var zu={deprecate:us()},hs=fi(),mr=require("buffer").Buffer,$u=global.Uint8Array||function(){};function Gu(t){return mr.from(t)}function Qu(t){return mr.isBuffer(t)||t instanceof $u}var vi=di(),Yu=pi(),Xu=Yu.getHighWaterMark,ke=Be().codes,Ju=ke.ERR_INVALID_ARG_TYPE,Zu=ke.ERR_METHOD_NOT_IMPLEMENTED,ef=ke.ERR_MULTIPLE_CALLBACK,tf=ke.ERR_STREAM_CANNOT_PIPE,rf=ke.ERR_STREAM_DESTROYED,nf=ke.ERR_STREAM_NULL_VALUES,sf=ke.ERR_STREAM_WRITE_AFTER_END,of=ke.ERR_UNKNOWN_ENCODING,_t=vi.errorOrDestroy;we()(L,hs);function af(){}function Lt(t,e,r){yt=yt||Je(),t=t||{},typeof r!="boolean"&&(r=e instanceof yt),this.objectMode=!!t.objectMode,r&&(this.objectMode=this.objectMode||!!t.writableObjectMode),this.highWaterMark=Xu(this,t,"writableHighWaterMark",r),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var i=t.decodeStrings===!1;this.decodeStrings=!i,this.defaultEncoding=t.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(n){pf(e,n)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=t.emitClose!==!1,this.autoDestroy=!!t.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new cs(this)}Lt.prototype.getBuffer=function(){for(var e=this.bufferedRequest,r=[];e;)r.push(e),e=e.next;return r};(function(){try{Object.defineProperty(Lt.prototype,"buffer",{get:zu.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch{}})();var _r;typeof Symbol=="function"&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]=="function"?(_r=Function.prototype[Symbol.hasInstance],Object.defineProperty(L,Symbol.hasInstance,{value:function(e){return _r.call(this,e)?!0:this!==L?!1:e&&e._writableState instanceof Lt}})):_r=function(e){return e instanceof this};function L(t){yt=yt||Je();var e=this instanceof yt;if(!e&&!_r.call(L,this))return new L(t);this._writableState=new Lt(t,this,e),this.writable=!0,t&&(typeof t.write=="function"&&(this._write=t.write),typeof t.writev=="function"&&(this._writev=t.writev),typeof t.destroy=="function"&&(this._destroy=t.destroy),typeof t.final=="function"&&(this._final=t.final)),hs.call(this)}L.prototype.pipe=function(){_t(this,new tf)};function lf(t,e){var r=new sf;_t(t,r),process.nextTick(e,r)}function uf(t,e,r,i){var n;return r===null?n=new nf:typeof r!="string"&&!e.objectMode&&(n=new Ju("chunk",["string","Buffer"],r)),n?(_t(t,n),process.nextTick(i,n),!1):!0}L.prototype.write=function(t,e,r){var i=this._writableState,n=!1,s=!i.objectMode&&Qu(t);return s&&!mr.isBuffer(t)&&(t=Gu(t)),typeof e=="function"&&(r=e,e=null),s?e="buffer":e||(e=i.defaultEncoding),typeof r!="function"&&(r=af),i.ending?lf(this,r):(s||uf(this,i,t,r))&&(i.pendingcb++,n=cf(this,i,s,t,e,r)),n};L.prototype.cork=function(){this._writableState.corked++};L.prototype.uncork=function(){var t=this._writableState;t.corked&&(t.corked--,!t.writing&&!t.corked&&!t.bufferProcessing&&t.bufferedRequest&&ds(this,t))};L.prototype.setDefaultEncoding=function(e){if(typeof e=="string"&&(e=e.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((e+"").toLowerCase())>-1))throw new of(e);return this._writableState.defaultEncoding=e,this};Object.defineProperty(L.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}});function ff(t,e,r){return!t.objectMode&&t.decodeStrings!==!1&&typeof e=="string"&&(e=mr.from(e,r)),e}Object.defineProperty(L.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});function cf(t,e,r,i,n,s){if(!r){var o=ff(e,i,n);i!==o&&(r=!0,n="buffer",i=o)}var a=e.objectMode?1:i.length;e.length+=a;var u=e.length<e.highWaterMark;if(u||(e.needDrain=!0),e.writing||e.corked){var l=e.lastBufferedRequest;e.lastBufferedRequest={chunk:i,encoding:n,isBuf:r,callback:s,next:null},l?l.next=e.lastBufferedRequest:e.bufferedRequest=e.lastBufferedRequest,e.bufferedRequestCount+=1}else mi(t,e,!1,a,i,n,s);return u}function mi(t,e,r,i,n,s,o){e.writelen=i,e.writecb=o,e.writing=!0,e.sync=!0,e.destroyed?e.onwrite(new rf("write")):r?t._writev(n,e.onwrite):t._write(n,s,e.onwrite),e.sync=!1}function hf(t,e,r,i,n){--e.pendingcb,r?(process.nextTick(n,i),process.nextTick(kt,t,e),t._writableState.errorEmitted=!0,_t(t,i)):(n(i),t._writableState.errorEmitted=!0,_t(t,i),kt(t,e))}function df(t){t.writing=!1,t.writecb=null,t.length-=t.writelen,t.writelen=0}function pf(t,e){var r=t._writableState,i=r.sync,n=r.writecb;if(typeof n!="function")throw new ef;if(df(r),e)hf(t,r,i,e,n);else{var s=ps(r)||t.destroyed;!s&&!r.corked&&!r.bufferProcessing&&r.bufferedRequest&&ds(t,r),i?process.nextTick(fs,t,r,s,n):fs(t,r,s,n)}}function fs(t,e,r,i){r||gf(t,e),e.pendingcb--,i(),kt(t,e)}function gf(t,e){e.length===0&&e.needDrain&&(e.needDrain=!1,t.emit("drain"))}function ds(t,e){e.bufferProcessing=!0;var r=e.bufferedRequest;if(t._writev&&r&&r.next){var i=e.bufferedRequestCount,n=new Array(i),s=e.corkedRequestsFree;s.entry=r;for(var o=0,a=!0;r;)n[o]=r,r.isBuf||(a=!1),r=r.next,o+=1;n.allBuffers=a,mi(t,e,!0,e.length,n,"",s.finish),e.pendingcb++,e.lastBufferedRequest=null,s.next?(e.corkedRequestsFree=s.next,s.next=null):e.corkedRequestsFree=new cs(e),e.bufferedRequestCount=0}else{for(;r;){var u=r.chunk,l=r.encoding,f=r.callback,h=e.objectMode?1:u.length;if(mi(t,e,!1,h,u,l,f),r=r.next,e.bufferedRequestCount--,e.writing)break}r===null&&(e.lastBufferedRequest=null)}e.bufferedRequest=r,e.bufferProcessing=!1}L.prototype._write=function(t,e,r){r(new Zu("_write()"))};L.prototype._writev=null;L.prototype.end=function(t,e,r){var i=this._writableState;return typeof t=="function"?(r=t,t=null,e=null):typeof e=="function"&&(r=e,e=null),t!=null&&this.write(t,e),i.corked&&(i.corked=1,this.uncork()),i.ending||mf(this,i,r),this};Object.defineProperty(L.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}});function ps(t){return t.ending&&t.length===0&&t.bufferedRequest===null&&!t.finished&&!t.writing}function yf(t,e){t._final(function(r){e.pendingcb--,r&&_t(t,r),e.prefinished=!0,t.emit("prefinish"),kt(t,e)})}function _f(t,e){!e.prefinished&&!e.finalCalled&&(typeof t._final=="function"&&!e.destroyed?(e.pendingcb++,e.finalCalled=!0,process.nextTick(yf,t,e)):(e.prefinished=!0,t.emit("prefinish")))}function kt(t,e){var r=ps(e);if(r&&(_f(t,e),e.pendingcb===0&&(e.finished=!0,t.emit("finish"),e.autoDestroy))){var i=t._readableState;(!i||i.autoDestroy&&i.endEmitted)&&t.destroy()}return r}function mf(t,e,r){e.ending=!0,kt(t,e),r&&(e.finished?process.nextTick(r):t.once("finish",r)),e.ended=!0,t.writable=!1}function vf(t,e,r){var i=t.entry;for(t.entry=null;i;){var n=i.callback;e.pendingcb--,n(r),i=i.next}e.corkedRequestsFree.next=t}Object.defineProperty(L.prototype,"destroyed",{enumerable:!1,get:function(){return this._writableState===void 0?!1:this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}});L.prototype.destroy=vi.destroy;L.prototype._undestroy=vi.undestroy;L.prototype._destroy=function(t,e){e(t)}});var Je=g((sy,_s)=>{"use strict";var bf=Object.keys||function(t){var e=[];for(var r in t)e.push(r);return e};_s.exports=ge;var ys=Ei(),Si=bi();we()(ge,ys);for(wi=bf(Si.prototype),vr=0;vr<wi.length;vr++)br=wi[vr],ge.prototype[br]||(ge.prototype[br]=Si.prototype[br]);var wi,br,vr;function ge(t){if(!(this instanceof ge))return new ge(t);ys.call(this,t),Si.call(this,t),this.allowHalfOpen=!0,t&&(t.readable===!1&&(this.readable=!1),t.writable===!1&&(this.writable=!1),t.allowHalfOpen===!1&&(this.allowHalfOpen=!1,this.once("end",wf)))}Object.defineProperty(ge.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});Object.defineProperty(ge.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}});Object.defineProperty(ge.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}});function wf(){this._writableState.ended||process.nextTick(Sf,this)}function Sf(t){t.end()}Object.defineProperty(ge.prototype,"destroyed",{enumerable:!1,get:function(){return this._readableState===void 0||this._writableState===void 0?!1:this._readableState.destroyed&&this._writableState.destroyed},set:function(e){this._readableState===void 0||this._writableState===void 0||(this._readableState.destroyed=e,this._writableState.destroyed=e)}})});var bs=g((xi,vs)=>{"use strict";var wr=require("buffer"),ye=wr.Buffer;function ms(t,e){for(var r in t)e[r]=t[r]}ye.from&&ye.alloc&&ye.allocUnsafe&&ye.allocUnsafeSlow?vs.exports=wr:(ms(wr,xi),xi.Buffer=Ze);function Ze(t,e,r){return ye(t,e,r)}Ze.prototype=Object.create(ye.prototype);ms(ye,Ze);Ze.from=function(t,e,r){if(typeof t=="number")throw new TypeError("Argument must not be a number");return ye(t,e,r)};Ze.alloc=function(t,e,r){if(typeof t!="number")throw new TypeError("Argument must be a number");var i=ye(t);return e!==void 0?typeof r=="string"?i.fill(e,r):i.fill(e):i.fill(0),i};Ze.allocUnsafe=function(t){if(typeof t!="number")throw new TypeError("Argument must be a number");return ye(t)};Ze.allocUnsafeSlow=function(t){if(typeof t!="number")throw new TypeError("Argument must be a number");return wr.SlowBuffer(t)}});var Pi=g(Ss=>{"use strict";var Ci=bs().Buffer,ws=Ci.isEncoding||function(t){switch(t=""+t,t&&t.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 Ef(t){if(!t)return"utf8";for(var e;;)switch(t){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 t;default:if(e)return;t=(""+t).toLowerCase(),e=!0}}function xf(t){var e=Ef(t);if(typeof e!="string"&&(Ci.isEncoding===ws||!ws(t)))throw new Error("Unknown encoding: "+t);return e||t}Ss.StringDecoder=Mt;function Mt(t){this.encoding=xf(t);var e;switch(this.encoding){case"utf16le":this.text=Rf,this.end=Af,e=4;break;case"utf8":this.fillLast=Pf,e=4;break;case"base64":this.text=Bf,this.end=kf,e=3;break;default:this.write=Lf,this.end=Mf;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=Ci.allocUnsafe(e)}Mt.prototype.write=function(t){if(t.length===0)return"";var e,r;if(this.lastNeed){if(e=this.fillLast(t),e===void 0)return"";r=this.lastNeed,this.lastNeed=0}else r=0;return r<t.length?e?e+this.text(t,r):this.text(t,r):e||""};Mt.prototype.end=If;Mt.prototype.text=Of;Mt.prototype.fillLast=function(t){if(this.lastNeed<=t.length)return t.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);t.copy(this.lastChar,this.lastTotal-this.lastNeed,0,t.length),this.lastNeed-=t.length};function Ti(t){return t<=127?0:t>>5===6?2:t>>4===14?3:t>>3===30?4:t>>6===2?-1:-2}function Tf(t,e,r){var i=e.length-1;if(i<r)return 0;var n=Ti(e[i]);return n>=0?(n>0&&(t.lastNeed=n-1),n):--i<r||n===-2?0:(n=Ti(e[i]),n>=0?(n>0&&(t.lastNeed=n-2),n):--i<r||n===-2?0:(n=Ti(e[i]),n>=0?(n>0&&(n===2?n=0:t.lastNeed=n-3),n):0))}function Cf(t,e,r){if((e[0]&192)!==128)return t.lastNeed=0,"\uFFFD";if(t.lastNeed>1&&e.length>1){if((e[1]&192)!==128)return t.lastNeed=1,"\uFFFD";if(t.lastNeed>2&&e.length>2&&(e[2]&192)!==128)return t.lastNeed=2,"\uFFFD"}}function Pf(t){var e=this.lastTotal-this.lastNeed,r=Cf(this,t,e);if(r!==void 0)return r;if(this.lastNeed<=t.length)return t.copy(this.lastChar,e,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);t.copy(this.lastChar,e,0,t.length),this.lastNeed-=t.length}function Of(t,e){var r=Tf(this,t,e);if(!this.lastNeed)return t.toString("utf8",e);this.lastTotal=r;var i=t.length-(r-this.lastNeed);return t.copy(this.lastChar,0,i),t.toString("utf8",e,i)}function If(t){var e=t&&t.length?this.write(t):"";return this.lastNeed?e+"\uFFFD":e}function Rf(t,e){if((t.length-e)%2===0){var r=t.toString("utf16le",e);if(r){var i=r.charCodeAt(r.length-1);if(i>=55296&&i<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=t[t.length-2],this.lastChar[1]=t[t.length-1],r.slice(0,-1)}return r}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=t[t.length-1],t.toString("utf16le",e,t.length-1)}function Af(t){var e=t&&t.length?this.write(t):"";if(this.lastNeed){var r=this.lastTotal-this.lastNeed;return e+this.lastChar.toString("utf16le",0,r)}return e}function Bf(t,e){var r=(t.length-e)%3;return r===0?t.toString("base64",e):(this.lastNeed=3-r,this.lastTotal=3,r===1?this.lastChar[0]=t[t.length-1]:(this.lastChar[0]=t[t.length-2],this.lastChar[1]=t[t.length-1]),t.toString("base64",e,t.length-r))}function kf(t){var e=t&&t.length?this.write(t):"";return this.lastNeed?e+this.lastChar.toString("base64",0,3-this.lastNeed):e}function Lf(t){return t.toString(this.encoding)}function Mf(t){return t&&t.length?this.write(t):""}});var Sr=g((ay,Ts)=>{"use strict";var Es=Be().codes.ERR_STREAM_PREMATURE_CLOSE;function qf(t){var e=!1;return function(){if(!e){e=!0;for(var r=arguments.length,i=new Array(r),n=0;n<r;n++)i[n]=arguments[n];t.apply(this,i)}}}function Nf(){}function Df(t){return t.setHeader&&typeof t.abort=="function"}function xs(t,e,r){if(typeof e=="function")return xs(t,null,e);e||(e={}),r=qf(r||Nf);var i=e.readable||e.readable!==!1&&t.readable,n=e.writable||e.writable!==!1&&t.writable,s=function(){t.writable||a()},o=t._writableState&&t._writableState.finished,a=function(){n=!1,o=!0,i||r.call(t)},u=t._readableState&&t._readableState.endEmitted,l=function(){i=!1,u=!0,n||r.call(t)},f=function(m){r.call(t,m)},h=function(){var m;if(i&&!u)return(!t._readableState||!t._readableState.ended)&&(m=new Es),r.call(t,m);if(n&&!o)return(!t._writableState||!t._writableState.ended)&&(m=new Es),r.call(t,m)},c=function(){t.req.on("finish",a)};return Df(t)?(t.on("complete",a),t.on("abort",h),t.req?c():t.on("request",c)):n&&!t._writableState&&(t.on("end",s),t.on("close",s)),t.on("end",l),t.on("finish",a),e.error!==!1&&t.on("error",f),t.on("close",h),function(){t.removeListener("complete",a),t.removeListener("abort",h),t.removeListener("request",c),t.req&&t.req.removeListener("finish",a),t.removeListener("end",s),t.removeListener("close",s),t.removeListener("finish",a),t.removeListener("end",l),t.removeListener("error",f),t.removeListener("close",h)}}Ts.exports=xs});var Ps=g((ly,Cs)=>{"use strict";var Er;function Le(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var Uf=Sr(),Me=Symbol("lastResolve"),et=Symbol("lastReject"),qt=Symbol("error"),xr=Symbol("ended"),tt=Symbol("lastPromise"),Oi=Symbol("handlePromise"),rt=Symbol("stream");function qe(t,e){return{value:t,done:e}}function jf(t){var e=t[Me];if(e!==null){var r=t[rt].read();r!==null&&(t[tt]=null,t[Me]=null,t[et]=null,e(qe(r,!1)))}}function Ff(t){process.nextTick(jf,t)}function Wf(t,e){return function(r,i){t.then(function(){if(e[xr]){r(qe(void 0,!0));return}e[Oi](r,i)},i)}}var Vf=Object.getPrototypeOf(function(){}),Hf=Object.setPrototypeOf((Er={get stream(){return this[rt]},next:function(){var e=this,r=this[qt];if(r!==null)return Promise.reject(r);if(this[xr])return Promise.resolve(qe(void 0,!0));if(this[rt].destroyed)return new Promise(function(o,a){process.nextTick(function(){e[qt]?a(e[qt]):o(qe(void 0,!0))})});var i=this[tt],n;if(i)n=new Promise(Wf(i,this));else{var s=this[rt].read();if(s!==null)return Promise.resolve(qe(s,!1));n=new Promise(this[Oi])}return this[tt]=n,n}},Le(Er,Symbol.asyncIterator,function(){return this}),Le(Er,"return",function(){var e=this;return new Promise(function(r,i){e[rt].destroy(null,function(n){if(n){i(n);return}r(qe(void 0,!0))})})}),Er),Vf),Kf=function(e){var r,i=Object.create(Hf,(r={},Le(r,rt,{value:e,writable:!0}),Le(r,Me,{value:null,writable:!0}),Le(r,et,{value:null,writable:!0}),Le(r,qt,{value:null,writable:!0}),Le(r,xr,{value:e._readableState.endEmitted,writable:!0}),Le(r,Oi,{value:function(s,o){var a=i[rt].read();a?(i[tt]=null,i[Me]=null,i[et]=null,s(qe(a,!1))):(i[Me]=s,i[et]=o)},writable:!0}),r));return i[tt]=null,Uf(e,function(n){if(n&&n.code!=="ERR_STREAM_PREMATURE_CLOSE"){var s=i[et];s!==null&&(i[tt]=null,i[Me]=null,i[et]=null,s(n)),i[qt]=n;return}var o=i[Me];o!==null&&(i[tt]=null,i[Me]=null,i[et]=null,o(qe(void 0,!0))),i[xr]=!0}),e.on("readable",Ff.bind(null,i)),i};Cs.exports=Kf});var As=g((uy,Rs)=>{"use strict";function Os(t,e,r,i,n,s,o){try{var a=t[s](o),u=a.value}catch(l){r(l);return}a.done?e(u):Promise.resolve(u).then(i,n)}function zf(t){return function(){var e=this,r=arguments;return new Promise(function(i,n){var s=t.apply(e,r);function o(u){Os(s,i,n,o,a,"next",u)}function a(u){Os(s,i,n,o,a,"throw",u)}o(void 0)})}}function Is(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter(function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable})),r.push.apply(r,i)}return r}function $f(t){for(var e=1;e<arguments.length;e++){var r=arguments[e]!=null?arguments[e]:{};e%2?Is(Object(r),!0).forEach(function(i){Gf(t,i,r[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):Is(Object(r)).forEach(function(i){Object.defineProperty(t,i,Object.getOwnPropertyDescriptor(r,i))})}return t}function Gf(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var Qf=Be().codes.ERR_INVALID_ARG_TYPE;function Yf(t,e,r){var i;if(e&&typeof e.next=="function")i=e;else if(e&&e[Symbol.asyncIterator])i=e[Symbol.asyncIterator]();else if(e&&e[Symbol.iterator])i=e[Symbol.iterator]();else throw new Qf("iterable",["Iterable"],e);var n=new t($f({objectMode:!0},r)),s=!1;n._read=function(){s||(s=!0,o())};function o(){return a.apply(this,arguments)}function a(){return a=zf(function*(){try{var u=yield i.next(),l=u.value,f=u.done;f?n.push(null):n.push(yield l)?o():s=!1}catch(h){n.destroy(h)}}),a.apply(this,arguments)}return n}Rs.exports=Yf});var Ei=g((cy,Fs)=>{"use strict";Fs.exports=P;var mt;P.ReadableState=Ms;var fy=require("events").EventEmitter,Ls=function(e,r){return e.listeners(r).length},Dt=fi(),Tr=require("buffer").Buffer,Xf=global.Uint8Array||function(){};function Jf(t){return Tr.from(t)}function Zf(t){return Tr.isBuffer(t)||t instanceof Xf}var Ii=require("util"),x;Ii&&Ii.debuglog?x=Ii.debuglog("stream"):x=function(){};var ec=es(),qi=di(),tc=pi(),rc=tc.getHighWaterMark,Cr=Be().codes,ic=Cr.ERR_INVALID_ARG_TYPE,nc=Cr.ERR_STREAM_PUSH_AFTER_EOF,sc=Cr.ERR_METHOD_NOT_IMPLEMENTED,oc=Cr.ERR_STREAM_UNSHIFT_AFTER_END_EVENT,vt,Ri,Ai;we()(P,Dt);var Nt=qi.errorOrDestroy,Bi=["error","close","destroy","pause","resume"];function ac(t,e,r){if(typeof t.prependListener=="function")return t.prependListener(e,r);!t._events||!t._events[e]?t.on(e,r):Array.isArray(t._events[e])?t._events[e].unshift(r):t._events[e]=[r,t._events[e]]}function Ms(t,e,r){mt=mt||Je(),t=t||{},typeof r!="boolean"&&(r=e instanceof mt),this.objectMode=!!t.objectMode,r&&(this.objectMode=this.objectMode||!!t.readableObjectMode),this.highWaterMark=rc(this,t,"readableHighWaterMark",r),this.buffer=new ec,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.paused=!0,this.emitClose=t.emitClose!==!1,this.autoDestroy=!!t.autoDestroy,this.destroyed=!1,this.defaultEncoding=t.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,t.encoding&&(vt||(vt=Pi().StringDecoder),this.decoder=new vt(t.encoding),this.encoding=t.encoding)}function P(t){if(mt=mt||Je(),!(this instanceof P))return new P(t);var e=this instanceof mt;this._readableState=new Ms(t,this,e),this.readable=!0,t&&(typeof t.read=="function"&&(this._read=t.read),typeof t.destroy=="function"&&(this._destroy=t.destroy)),Dt.call(this)}Object.defineProperty(P.prototype,"destroyed",{enumerable:!1,get:function(){return this._readableState===void 0?!1:this._readableState.destroyed},set:function(e){this._readableState&&(this._readableState.destroyed=e)}});P.prototype.destroy=qi.destroy;P.prototype._undestroy=qi.undestroy;P.prototype._destroy=function(t,e){e(t)};P.prototype.push=function(t,e){var r=this._readableState,i;return r.objectMode?i=!0:typeof t=="string"&&(e=e||r.defaultEncoding,e!==r.encoding&&(t=Tr.from(t,e),e=""),i=!0),qs(this,t,e,!1,i)};P.prototype.unshift=function(t){return qs(this,t,null,!0,!1)};function qs(t,e,r,i,n){x("readableAddChunk",e);var s=t._readableState;if(e===null)s.reading=!1,fc(t,s);else{var o;if(n||(o=lc(s,e)),o)Nt(t,o);else if(s.objectMode||e&&e.length>0)if(typeof e!="string"&&!s.objectMode&&Object.getPrototypeOf(e)!==Tr.prototype&&(e=Jf(e)),i)s.endEmitted?Nt(t,new oc):ki(t,s,e,!0);else if(s.ended)Nt(t,new nc);else{if(s.destroyed)return!1;s.reading=!1,s.decoder&&!r?(e=s.decoder.write(e),s.objectMode||e.length!==0?ki(t,s,e,!1):Mi(t,s)):ki(t,s,e,!1)}else i||(s.reading=!1,Mi(t,s))}return!s.ended&&(s.length<s.highWaterMark||s.length===0)}function ki(t,e,r,i){e.flowing&&e.length===0&&!e.sync?(e.awaitDrain=0,t.emit("data",r)):(e.length+=e.objectMode?1:r.length,i?e.buffer.unshift(r):e.buffer.push(r),e.needReadable&&Pr(t)),Mi(t,e)}function lc(t,e){var r;return!Zf(e)&&typeof e!="string"&&e!==void 0&&!t.objectMode&&(r=new ic("chunk",["string","Buffer","Uint8Array"],e)),r}P.prototype.isPaused=function(){return this._readableState.flowing===!1};P.prototype.setEncoding=function(t){vt||(vt=Pi().StringDecoder);var e=new vt(t);this._readableState.decoder=e,this._readableState.encoding=this._readableState.decoder.encoding;for(var r=this._readableState.buffer.head,i="";r!==null;)i+=e.write(r.data),r=r.next;return this._readableState.buffer.clear(),i!==""&&this._readableState.buffer.push(i),this._readableState.length=i.length,this};var Bs=1073741824;function uc(t){return t>=Bs?t=Bs:(t--,t|=t>>>1,t|=t>>>2,t|=t>>>4,t|=t>>>8,t|=t>>>16,t++),t}function ks(t,e){return t<=0||e.length===0&&e.ended?0:e.objectMode?1:t!==t?e.flowing&&e.length?e.buffer.head.data.length:e.length:(t>e.highWaterMark&&(e.highWaterMark=uc(t)),t<=e.length?t:e.ended?e.length:(e.needReadable=!0,0))}P.prototype.read=function(t){x("read",t),t=parseInt(t,10);var e=this._readableState,r=t;if(t!==0&&(e.emittedReadable=!1),t===0&&e.needReadable&&((e.highWaterMark!==0?e.length>=e.highWaterMark:e.length>0)||e.ended))return x("read: emitReadable",e.length,e.ended),e.length===0&&e.ended?Li(this):Pr(this),null;if(t=ks(t,e),t===0&&e.ended)return e.length===0&&Li(this),null;var i=e.needReadable;x("need readable",i),(e.length===0||e.length-t<e.highWaterMark)&&(i=!0,x("length less than watermark",i)),e.ended||e.reading?(i=!1,x("reading or ended",i)):i&&(x("do read"),e.reading=!0,e.sync=!0,e.length===0&&(e.needReadable=!0),this._read(e.highWaterMark),e.sync=!1,e.reading||(t=ks(r,e)));var n;return t>0?n=Us(t,e):n=null,n===null?(e.needReadable=e.length<=e.highWaterMark,t=0):(e.length-=t,e.awaitDrain=0),e.length===0&&(e.ended||(e.needReadable=!0),r!==t&&e.ended&&Li(this)),n!==null&&this.emit("data",n),n};function fc(t,e){if(x("onEofChunk"),!e.ended){if(e.decoder){var r=e.decoder.end();r&&r.length&&(e.buffer.push(r),e.length+=e.objectMode?1:r.length)}e.ended=!0,e.sync?Pr(t):(e.needReadable=!1,e.emittedReadable||(e.emittedReadable=!0,Ns(t)))}}function Pr(t){var e=t._readableState;x("emitReadable",e.needReadable,e.emittedReadable),e.needReadable=!1,e.emittedReadable||(x("emitReadable",e.flowing),e.emittedReadable=!0,process.nextTick(Ns,t))}function Ns(t){var e=t._readableState;x("emitReadable_",e.destroyed,e.length,e.ended),!e.destroyed&&(e.length||e.ended)&&(t.emit("readable"),e.emittedReadable=!1),e.needReadable=!e.flowing&&!e.ended&&e.length<=e.highWaterMark,Ni(t)}function Mi(t,e){e.readingMore||(e.readingMore=!0,process.nextTick(cc,t,e))}function cc(t,e){for(;!e.reading&&!e.ended&&(e.length<e.highWaterMark||e.flowing&&e.length===0);){var r=e.length;if(x("maybeReadMore read 0"),t.read(0),r===e.length)break}e.readingMore=!1}P.prototype._read=function(t){Nt(this,new sc("_read()"))};P.prototype.pipe=function(t,e){var r=this,i=this._readableState;switch(i.pipesCount){case 0:i.pipes=t;break;case 1:i.pipes=[i.pipes,t];break;default:i.pipes.push(t);break}i.pipesCount+=1,x("pipe count=%d opts=%j",i.pipesCount,e);var n=(!e||e.end!==!1)&&t!==process.stdout&&t!==process.stderr,s=n?a:y;i.endEmitted?process.nextTick(s):r.once("end",s),t.on("unpipe",o);function o(v,b){x("onunpipe"),v===r&&b&&b.hasUnpiped===!1&&(b.hasUnpiped=!0,f())}function a(){x("onend"),t.end()}var u=hc(r);t.on("drain",u);var l=!1;function f(){x("cleanup"),t.removeListener("close",d),t.removeListener("finish",m),t.removeListener("drain",u),t.removeListener("error",c),t.removeListener("unpipe",o),r.removeListener("end",a),r.removeListener("end",y),r.removeListener("data",h),l=!0,i.awaitDrain&&(!t._writableState||t._writableState.needDrain)&&u()}r.on("data",h);function h(v){x("ondata");var b=t.write(v);x("dest.write",b),b===!1&&((i.pipesCount===1&&i.pipes===t||i.pipesCount>1&&js(i.pipes,t)!==-1)&&!l&&(x("false write response, pause",i.awaitDrain),i.awaitDrain++),r.pause())}function c(v){x("onerror",v),y(),t.removeListener("error",c),Ls(t,"error")===0&&Nt(t,v)}ac(t,"error",c);function d(){t.removeListener("finish",m),y()}t.once("close",d);function m(){x("onfinish"),t.removeListener("close",d),y()}t.once("finish",m);function y(){x("unpipe"),r.unpipe(t)}return t.emit("pipe",r),i.flowing||(x("pipe resume"),r.resume()),t};function hc(t){return function(){var r=t._readableState;x("pipeOnDrain",r.awaitDrain),r.awaitDrain&&r.awaitDrain--,r.awaitDrain===0&&Ls(t,"data")&&(r.flowing=!0,Ni(t))}}P.prototype.unpipe=function(t){var e=this._readableState,r={hasUnpiped:!1};if(e.pipesCount===0)return this;if(e.pipesCount===1)return t&&t!==e.pipes?this:(t||(t=e.pipes),e.pipes=null,e.pipesCount=0,e.flowing=!1,t&&t.emit("unpipe",this,r),this);if(!t){var i=e.pipes,n=e.pipesCount;e.pipes=null,e.pipesCount=0,e.flowing=!1;for(var s=0;s<n;s++)i[s].emit("unpipe",this,{hasUnpiped:!1});return this}var o=js(e.pipes,t);return o===-1?this:(e.pipes.splice(o,1),e.pipesCount-=1,e.pipesCount===1&&(e.pipes=e.pipes[0]),t.emit("unpipe",this,r),this)};P.prototype.on=function(t,e){var r=Dt.prototype.on.call(this,t,e),i=this._readableState;return t==="data"?(i.readableListening=this.listenerCount("readable")>0,i.flowing!==!1&&this.resume()):t==="readable"&&!i.endEmitted&&!i.readableListening&&(i.readableListening=i.needReadable=!0,i.flowing=!1,i.emittedReadable=!1,x("on readable",i.length,i.reading),i.length?Pr(this):i.reading||process.nextTick(dc,this)),r};P.prototype.addListener=P.prototype.on;P.prototype.removeListener=function(t,e){var r=Dt.prototype.removeListener.call(this,t,e);return t==="readable"&&process.nextTick(Ds,this),r};P.prototype.removeAllListeners=function(t){var e=Dt.prototype.removeAllListeners.apply(this,arguments);return(t==="readable"||t===void 0)&&process.nextTick(Ds,this),e};function Ds(t){var e=t._readableState;e.readableListening=t.listenerCount("readable")>0,e.resumeScheduled&&!e.paused?e.flowing=!0:t.listenerCount("data")>0&&t.resume()}function dc(t){x("readable nexttick read 0"),t.read(0)}P.prototype.resume=function(){var t=this._readableState;return t.flowing||(x("resume"),t.flowing=!t.readableListening,pc(this,t)),t.paused=!1,this};function pc(t,e){e.resumeScheduled||(e.resumeScheduled=!0,process.nextTick(gc,t,e))}function gc(t,e){x("resume",e.reading),e.reading||t.read(0),e.resumeScheduled=!1,t.emit("resume"),Ni(t),e.flowing&&!e.reading&&t.read(0)}P.prototype.pause=function(){return x("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(x("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this};function Ni(t){var e=t._readableState;for(x("flow",e.flowing);e.flowing&&t.read()!==null;);}P.prototype.wrap=function(t){var e=this,r=this._readableState,i=!1;t.on("end",function(){if(x("wrapped end"),r.decoder&&!r.ended){var o=r.decoder.end();o&&o.length&&e.push(o)}e.push(null)}),t.on("data",function(o){if(x("wrapped data"),r.decoder&&(o=r.decoder.write(o)),!(r.objectMode&&o==null)&&!(!r.objectMode&&(!o||!o.length))){var a=e.push(o);a||(i=!0,t.pause())}});for(var n in t)this[n]===void 0&&typeof t[n]=="function"&&(this[n]=function(a){return function(){return t[a].apply(t,arguments)}}(n));for(var s=0;s<Bi.length;s++)t.on(Bi[s],this.emit.bind(this,Bi[s]));return this._read=function(o){x("wrapped _read",o),i&&(i=!1,t.resume())},this};typeof Symbol=="function"&&(P.prototype[Symbol.asyncIterator]=function(){return Ri===void 0&&(Ri=Ps()),Ri(this)});Object.defineProperty(P.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}});Object.defineProperty(P.prototype,"readableBuffer",{enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}});Object.defineProperty(P.prototype,"readableFlowing",{enumerable:!1,get:function(){return this._readableState.flowing},set:function(e){this._readableState&&(this._readableState.flowing=e)}});P._fromList=Us;Object.defineProperty(P.prototype,"readableLength",{enumerable:!1,get:function(){return this._readableState.length}});function Us(t,e){if(e.length===0)return null;var r;return e.objectMode?r=e.buffer.shift():!t||t>=e.length?(e.decoder?r=e.buffer.join(""):e.buffer.length===1?r=e.buffer.first():r=e.buffer.concat(e.length),e.buffer.clear()):r=e.buffer.consume(t,e.decoder),r}function Li(t){var e=t._readableState;x("endReadable",e.endEmitted),e.endEmitted||(e.ended=!0,process.nextTick(yc,e,t))}function yc(t,e){if(x("endReadableNT",t.endEmitted,t.length),!t.endEmitted&&t.length===0&&(t.endEmitted=!0,e.readable=!1,e.emit("end"),t.autoDestroy)){var r=e._writableState;(!r||r.autoDestroy&&r.finished)&&e.destroy()}}typeof Symbol=="function"&&(P.from=function(t,e){return Ai===void 0&&(Ai=As()),Ai(P,t,e)});function js(t,e){for(var r=0,i=t.length;r<i;r++)if(t[r]===e)return r;return-1}});var Di=g((hy,Vs)=>{"use strict";Vs.exports=Se;var Or=Be().codes,_c=Or.ERR_METHOD_NOT_IMPLEMENTED,mc=Or.ERR_MULTIPLE_CALLBACK,vc=Or.ERR_TRANSFORM_ALREADY_TRANSFORMING,bc=Or.ERR_TRANSFORM_WITH_LENGTH_0,Ir=Je();we()(Se,Ir);function wc(t,e){var r=this._transformState;r.transforming=!1;var i=r.writecb;if(i===null)return this.emit("error",new mc);r.writechunk=null,r.writecb=null,e!=null&&this.push(e),i(t);var n=this._readableState;n.reading=!1,(n.needReadable||n.length<n.highWaterMark)&&this._read(n.highWaterMark)}function Se(t){if(!(this instanceof Se))return new Se(t);Ir.call(this,t),this._transformState={afterTransform:wc.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,t&&(typeof t.transform=="function"&&(this._transform=t.transform),typeof t.flush=="function"&&(this._flush=t.flush)),this.on("prefinish",Sc)}function Sc(){var t=this;typeof this._flush=="function"&&!this._readableState.destroyed?this._flush(function(e,r){Ws(t,e,r)}):Ws(this,null,null)}Se.prototype.push=function(t,e){return this._transformState.needTransform=!1,Ir.prototype.push.call(this,t,e)};Se.prototype._transform=function(t,e,r){r(new _c("_transform()"))};Se.prototype._write=function(t,e,r){var i=this._transformState;if(i.writecb=r,i.writechunk=t,i.writeencoding=e,!i.transforming){var n=this._readableState;(i.needTransform||n.needReadable||n.length<n.highWaterMark)&&this._read(n.highWaterMark)}};Se.prototype._read=function(t){var e=this._transformState;e.writechunk!==null&&!e.transforming?(e.transforming=!0,this._transform(e.writechunk,e.writeencoding,e.afterTransform)):e.needTransform=!0};Se.prototype._destroy=function(t,e){Ir.prototype._destroy.call(this,t,function(r){e(r)})};function Ws(t,e,r){if(e)return t.emit("error",e);if(r!=null&&t.push(r),t._writableState.length)throw new bc;if(t._transformState.transforming)throw new vc;return t.push(null)}});var zs=g((dy,Ks)=>{"use strict";Ks.exports=Ut;var Hs=Di();we()(Ut,Hs);function Ut(t){if(!(this instanceof Ut))return new Ut(t);Hs.call(this,t)}Ut.prototype._transform=function(t,e,r){r(null,t)}});var Xs=g((py,Ys)=>{"use strict";var Ui;function Ec(t){var e=!1;return function(){e||(e=!0,t.apply(void 0,arguments))}}var Qs=Be().codes,xc=Qs.ERR_MISSING_ARGS,Tc=Qs.ERR_STREAM_DESTROYED;function $s(t){if(t)throw t}function Cc(t){return t.setHeader&&typeof t.abort=="function"}function Pc(t,e,r,i){i=Ec(i);var n=!1;t.on("close",function(){n=!0}),Ui===void 0&&(Ui=Sr()),Ui(t,{readable:e,writable:r},function(o){if(o)return i(o);n=!0,i()});var s=!1;return function(o){if(!n&&!s){if(s=!0,Cc(t))return t.abort();if(typeof t.destroy=="function")return t.destroy();i(o||new Tc("pipe"))}}}function Gs(t){t()}function Oc(t,e){return t.pipe(e)}function Ic(t){return!t.length||typeof t[t.length-1]!="function"?$s:t.pop()}function Rc(){for(var t=arguments.length,e=new Array(t),r=0;r<t;r++)e[r]=arguments[r];var i=Ic(e);if(Array.isArray(e[0])&&(e=e[0]),e.length<2)throw new xc("streams");var n,s=e.map(function(o,a){var u=a<e.length-1,l=a>0;return Pc(o,u,l,function(f){n||(n=f),f&&s.forEach(Gs),!u&&(s.forEach(Gs),i(n))})});return e.reduce(Oc)}Ys.exports=Rc});var Ne=g((se,Ft)=>{"use strict";var jt=require("stream");process.env.READABLE_STREAM==="disable"&&jt?(Ft.exports=jt.Readable,Object.assign(Ft.exports,jt),Ft.exports.Stream=jt):(se=Ft.exports=Ei(),se.Stream=jt||se,se.Readable=se,se.Writable=bi(),se.Duplex=Je(),se.Transform=Di(),se.PassThrough=zs(),se.finished=Sr(),se.pipeline=Xs())});var Rr=g((gy,Js)=>{"use strict";var Ac=pr(),Bc=Ne().Readable,kc={objectMode:!0},Lc={clean:!0};function De(t){if(!(this instanceof De))return new De(t);this.options=t||{},this.options=Ac(Lc,t),this._inflights=new Map}De.prototype.put=function(t,e){return this._inflights.set(t.messageId,t),e&&e(),this};De.prototype.createStream=function(){let t=new Bc(kc),e=[],r=!1,i=0;return this._inflights.forEach(function(n,s){e.push(n)}),t._read=function(){!r&&i<e.length?this.push(e[i++]):this.push(null)},t.destroy=function(){if(r)return;let n=this;r=!0,setTimeout(function(){n.emit("close")},0)},t};De.prototype.del=function(t,e){return t=this._inflights.get(t.messageId),t?(this._inflights.delete(t.messageId),e(null,t)):e&&e(new Error("missing packet")),this};De.prototype.get=function(t,e){return t=this._inflights.get(t.messageId),t?e(null,t):e&&e(new Error("missing packet")),this};De.prototype.close=function(t){this.options.clean&&(this._inflights=null),t&&t()};Js.exports=De});var eo=g((yy,Zs)=>{"use strict";function bt(t){if(!(this instanceof bt))return new bt(t);this.aliasToTopic={},this.max=t}bt.prototype.put=function(t,e){return e===0||e>this.max?!1:(this.aliasToTopic[e]=t,this.length=Object.keys(this.aliasToTopic).length,!0)};bt.prototype.getTopicByAlias=function(t){return this.aliasToTopic[t]};bt.prototype.clear=function(){this.aliasToTopic={}};Zs.exports=bt});var ro=g((_y,to)=>{"use strict";to.exports=function(t){t.prototype[Symbol.iterator]=function*(){for(let e=this.head;e;e=e.next)yield e.value}}});var no=g((my,io)=>{"use strict";io.exports=O;O.Node=it;O.create=O;function O(t){var e=this;if(e instanceof O||(e=new O),e.tail=null,e.head=null,e.length=0,t&&typeof t.forEach=="function")t.forEach(function(n){e.push(n)});else if(arguments.length>0)for(var r=0,i=arguments.length;r<i;r++)e.push(arguments[r]);return e}O.prototype.removeNode=function(t){if(t.list!==this)throw new Error("removing node which does not belong to this list");var e=t.next,r=t.prev;return e&&(e.prev=r),r&&(r.next=e),t===this.head&&(this.head=e),t===this.tail&&(this.tail=r),t.list.length--,t.next=null,t.prev=null,t.list=null,e};O.prototype.unshiftNode=function(t){if(t!==this.head){t.list&&t.list.removeNode(t);var e=this.head;t.list=this,t.next=e,e&&(e.prev=t),this.head=t,this.tail||(this.tail=t),this.length++}};O.prototype.pushNode=function(t){if(t!==this.tail){t.list&&t.list.removeNode(t);var e=this.tail;t.list=this,t.prev=e,e&&(e.next=t),this.tail=t,this.head||(this.head=t),this.length++}};O.prototype.push=function(){for(var t=0,e=arguments.length;t<e;t++)qc(this,arguments[t]);return this.length};O.prototype.unshift=function(){for(var t=0,e=arguments.length;t<e;t++)Nc(this,arguments[t]);return this.length};O.prototype.pop=function(){if(this.tail){var t=this.tail.value;return this.tail=this.tail.prev,this.tail?this.tail.next=null:this.head=null,this.length--,t}};O.prototype.shift=function(){if(this.head){var t=this.head.value;return this.head=this.head.next,this.head?this.head.prev=null:this.tail=null,this.length--,t}};O.prototype.forEach=function(t,e){e=e||this;for(var r=this.head,i=0;r!==null;i++)t.call(e,r.value,i,this),r=r.next};O.prototype.forEachReverse=function(t,e){e=e||this;for(var r=this.tail,i=this.length-1;r!==null;i--)t.call(e,r.value,i,this),r=r.prev};O.prototype.get=function(t){for(var e=0,r=this.head;r!==null&&e<t;e++)r=r.next;if(e===t&&r!==null)return r.value};O.prototype.getReverse=function(t){for(var e=0,r=this.tail;r!==null&&e<t;e++)r=r.prev;if(e===t&&r!==null)return r.value};O.prototype.map=function(t,e){e=e||this;for(var r=new O,i=this.head;i!==null;)r.push(t.call(e,i.value,this)),i=i.next;return r};O.prototype.mapReverse=function(t,e){e=e||this;for(var r=new O,i=this.tail;i!==null;)r.push(t.call(e,i.value,this)),i=i.prev;return r};O.prototype.reduce=function(t,e){var r,i=this.head;if(arguments.length>1)r=e;else if(this.head)i=this.head.next,r=this.head.value;else throw new TypeError("Reduce of empty list with no initial value");for(var n=0;i!==null;n++)r=t(r,i.value,n),i=i.next;return r};O.prototype.reduceReverse=function(t,e){var r,i=this.tail;if(arguments.length>1)r=e;else if(this.tail)i=this.tail.prev,r=this.tail.value;else throw new TypeError("Reduce of empty list with no initial value");for(var n=this.length-1;i!==null;n--)r=t(r,i.value,n),i=i.prev;return r};O.prototype.toArray=function(){for(var t=new Array(this.length),e=0,r=this.head;r!==null;e++)t[e]=r.value,r=r.next;return t};O.prototype.toArrayReverse=function(){for(var t=new Array(this.length),e=0,r=this.tail;r!==null;e++)t[e]=r.value,r=r.prev;return t};O.prototype.slice=function(t,e){e=e||this.length,e<0&&(e+=this.length),t=t||0,t<0&&(t+=this.length);var r=new O;if(e<t||e<0)return r;t<0&&(t=0),e>this.length&&(e=this.length);for(var i=0,n=this.head;n!==null&&i<t;i++)n=n.next;for(;n!==null&&i<e;i++,n=n.next)r.push(n.value);return r};O.prototype.sliceReverse=function(t,e){e=e||this.length,e<0&&(e+=this.length),t=t||0,t<0&&(t+=this.length);var r=new O;if(e<t||e<0)return r;t<0&&(t=0),e>this.length&&(e=this.length);for(var i=this.length,n=this.tail;n!==null&&i>e;i--)n=n.prev;for(;n!==null&&i>t;i--,n=n.prev)r.push(n.value);return r};O.prototype.splice=function(t,e,...r){t>this.length&&(t=this.length-1),t<0&&(t=this.length+t);for(var i=0,n=this.head;n!==null&&i<t;i++)n=n.next;for(var s=[],i=0;n&&i<e;i++)s.push(n.value),n=this.removeNode(n);n===null&&(n=this.tail),n!==this.head&&n!==this.tail&&(n=n.prev);for(var i=0;i<r.length;i++)n=Mc(this,n,r[i]);return s};O.prototype.reverse=function(){for(var t=this.head,e=this.tail,r=t;r!==null;r=r.prev){var i=r.prev;r.prev=r.next,r.next=i}return this.head=e,this.tail=t,this};function Mc(t,e,r){var i=e===t.head?new it(r,null,e,t):new it(r,e,e.next,t);return i.next===null&&(t.tail=i),i.prev===null&&(t.head=i),t.length++,i}function qc(t,e){t.tail=new it(e,t.tail,null,t),t.head||(t.head=t.tail),t.length++}function Nc(t,e){t.head=new it(e,null,t.head,t),t.tail||(t.tail=t.head),t.length++}function it(t,e,r,i){if(!(this instanceof it))return new it(t,e,r,i);this.list=i,this.value=t,e?(e.next=this,this.prev=e):this.prev=null,r?(r.prev=this,this.next=r):this.next=null}try{ro()(O)}catch{}});var uo=g((vy,lo)=>{"use strict";var Dc=no(),nt=Symbol("max"),xe=Symbol("length"),wt=Symbol("lengthCalculator"),Vt=Symbol("allowStale"),st=Symbol("maxAge"),Ee=Symbol("dispose"),so=Symbol("noDisposeOnSet"),W=Symbol("lruList"),ue=Symbol("cache"),ao=Symbol("updateAgeOnGet"),ji=()=>1,Wi=class{constructor(e){if(typeof e=="number"&&(e={max:e}),e||(e={}),e.max&&(typeof e.max!="number"||e.max<0))throw new TypeError("max must be a non-negative number");let r=this[nt]=e.max||1/0,i=e.length||ji;if(this[wt]=typeof i!="function"?ji:i,this[Vt]=e.stale||!1,e.maxAge&&typeof e.maxAge!="number")throw new TypeError("maxAge must be a number");this[st]=e.maxAge||0,this[Ee]=e.dispose,this[so]=e.noDisposeOnSet||!1,this[ao]=e.updateAgeOnGet||!1,this.reset()}set max(e){if(typeof e!="number"||e<0)throw new TypeError("max must be a non-negative number");this[nt]=e||1/0,Wt(this)}get max(){return this[nt]}set allowStale(e){this[Vt]=!!e}get allowStale(){return this[Vt]}set maxAge(e){if(typeof e!="number")throw new TypeError("maxAge must be a non-negative number");this[st]=e,Wt(this)}get maxAge(){return this[st]}set lengthCalculator(e){typeof e!="function"&&(e=ji),e!==this[wt]&&(this[wt]=e,this[xe]=0,this[W].forEach(r=>{r.length=this[wt](r.value,r.key),this[xe]+=r.length})),Wt(this)}get lengthCalculator(){return this[wt]}get length(){return this[xe]}get itemCount(){return this[W].length}rforEach(e,r){r=r||this;for(let i=this[W].tail;i!==null;){let n=i.prev;oo(this,e,i,r),i=n}}forEach(e,r){r=r||this;for(let i=this[W].head;i!==null;){let n=i.next;oo(this,e,i,r),i=n}}keys(){return this[W].toArray().map(e=>e.key)}values(){return this[W].toArray().map(e=>e.value)}reset(){this[Ee]&&this[W]&&this[W].length&&this[W].forEach(e=>this[Ee](e.key,e.value)),this[ue]=new Map,this[W]=new Dc,this[xe]=0}dump(){return this[W].map(e=>Ar(this,e)?!1:{k:e.key,v:e.value,e:e.now+(e.maxAge||0)}).toArray().filter(e=>e)}dumpLru(){return this[W]}set(e,r,i){if(i=i||this[st],i&&typeof i!="number")throw new TypeError("maxAge must be a number");let n=i?Date.now():0,s=this[wt](r,e);if(this[ue].has(e)){if(s>this[nt])return St(this,this[ue].get(e)),!1;let u=this[ue].get(e).value;return this[Ee]&&(this[so]||this[Ee](e,u.value)),u.now=n,u.maxAge=i,u.value=r,this[xe]+=s-u.length,u.length=s,this.get(e),Wt(this),!0}let o=new Vi(e,r,s,n,i);return o.length>this[nt]?(this[Ee]&&this[Ee](e,r),!1):(this[xe]+=o.length,this[W].unshift(o),this[ue].set(e,this[W].head),Wt(this),!0)}has(e){if(!this[ue].has(e))return!1;let r=this[ue].get(e).value;return!Ar(this,r)}get(e){return Fi(this,e,!0)}peek(e){return Fi(this,e,!1)}pop(){let e=this[W].tail;return e?(St(this,e),e.value):null}del(e){St(this,this[ue].get(e))}load(e){this.reset();let r=Date.now();for(let i=e.length-1;i>=0;i--){let n=e[i],s=n.e||0;if(s===0)this.set(n.k,n.v);else{let o=s-r;o>0&&this.set(n.k,n.v,o)}}}prune(){this[ue].forEach((e,r)=>Fi(this,r,!1))}},Fi=(t,e,r)=>{let i=t[ue].get(e);if(i){let n=i.value;if(Ar(t,n)){if(St(t,i),!t[Vt])return}else r&&(t[ao]&&(i.value.now=Date.now()),t[W].unshiftNode(i));return n.value}},Ar=(t,e)=>{if(!e||!e.maxAge&&!t[st])return!1;let r=Date.now()-e.now;return e.maxAge?r>e.maxAge:t[st]&&r>t[st]},Wt=t=>{if(t[xe]>t[nt])for(let e=t[W].tail;t[xe]>t[nt]&&e!==null;){let r=e.prev;St(t,e),e=r}},St=(t,e)=>{if(e){let r=e.value;t[Ee]&&t[Ee](r.key,r.value),t[xe]-=r.length,t[ue].delete(r.key),t[W].removeNode(e)}},Vi=class{constructor(e,r,i,n,s){this.key=e,this.value=r,this.length=i,this.now=n,this.maxAge=s||0}},oo=(t,e,r,i)=>{let n=r.value;Ar(t,n)&&(St(t,r),t[Vt]||(n=void 0)),n&&e.call(i,n.value,n.key,t)};lo.exports=Wi});var Uc,A,Te,Et,Y=U(()=>{"use strict";Uc=function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}(),A=function(){function t(e){e===void 0&&(e=t.NORMAL),this.iteratorType=e}return t.NORMAL=!1,t.REVERSE=!0,t}(),Te=function(){function t(){this.length=0}return t.prototype.size=function(){return this.length},t.prototype.empty=function(){return this.length===0},t}(),Et=function(t){Uc(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e}(Te)});var jc,Fc,fo,co=U(()=>{"use strict";Y();jc=function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}(),Fc=function(t){jc(e,t);function e(r){r===void 0&&(r=[]);var i=t.call(this)||this;return i.stack=[],r.forEach(function(n){return i.push(n)}),i}return e.prototype.clear=function(){this.length=0,this.stack.length=0},e.prototype.push=function(r){this.stack.push(r),this.length+=1},e.prototype.pop=function(){this.stack.pop(),this.length>0&&(this.length-=1)},e.prototype.top=function(){return this.stack[this.length-1]},e}(Te),fo=Fc});var Wc,Vc,Ue,Ht=U(()=>{"use strict";Y();Wc=function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}(),Vc=function(t){Wc(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e}(Et),Ue=Vc});function B(t,e,r){if(t<e||t>r)throw new RangeError}var je=U(()=>{"use strict"});var Hc,Br,Hi=U(()=>{"use strict";je();Y();Hc=function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}(),Br=function(t){Hc(e,t);function e(r,i,n,s,o){var a=t.call(this,o)||this;return a.node=r,a.size=i,a.getElementByPos=n,a.setElementByPos=s,a.iteratorType===A.NORMAL?(a.pre=function(){if(this.node===0)throw new RangeError("Deque iterator access denied!");return this.node-=1,this},a.next=function(){if(this.node===this.size())throw new RangeError("Deque Iterator access denied!");return this.node+=1,this}):(a.pre=function(){if(this.node===this.size()-1)throw new RangeError("Deque iterator access denied!");return this.node+=1,this},a.next=function(){if(this.node===-1)throw new RangeError("Deque iterator access denied!");return this.node-=1,this}),a}return Object.defineProperty(e.prototype,"pointer",{get:function(){return B(this.node,0,this.size()-1),this.getElementByPos(this.node)},set:function(r){B(this.node,0,this.size()-1),this.setElementByPos(this.node,r)},enumerable:!1,configurable:!0}),e.prototype.equals=function(r){return this.node===r.node},e}(A)});var ho,Kc,zc,$c,ot,Gc,kr,Ki=U(()=>{"use strict";Ht();je();Y();Hi();ho=function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}(),Kc=function(t,e){var r={label:0,sent:function(){if(s[0]&1)throw s[1];return s[1]},trys:[],ops:[]},i,n,s,o;return o={next:a(0),throw:a(1),return:a(2)},typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function a(l){return function(f){return u([l,f])}}function u(l){if(i)throw new TypeError("Generator is already executing.");for(;r;)try{if(i=1,n&&(s=l[0]&2?n.return:l[0]?n.throw||((s=n.return)&&s.call(n),0):n.next)&&!(s=s.call(n,l[1])).done)return s;switch(n=0,s&&(l=[l[0]&2,s.value]),l[0]){case 0:case 1:s=l;break;case 4:return r.label++,{value:l[1],done:!1};case 5:r.label++,n=l[1],l=[0];continue;case 7:l=r.ops.pop(),r.trys.pop();continue;default:if(s=r.trys,!(s=s.length>0&&s[s.length-1])&&(l[0]===6||l[0]===2)){r=0;continue}if(l[0]===3&&(!s||l[1]>s[0]&&l[1]<s[3])){r.label=l[1];break}if(l[0]===6&&r.label<s[1]){r.label=s[1],s=l;break}if(s&&r.label<s[2]){r.label=s[2],r.ops.push(l);break}s[2]&&r.ops.pop(),r.trys.pop();continue}l=e.call(t,r)}catch(f){l=[6,f],n=0}finally{i=s=0}if(l[0]&5)throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}},zc=function(t,e){var r=typeof Symbol=="function"&&t[Symbol.iterator];if(!r)return t;var i=r.call(t),n,s=[],o;try{for(;(e===void 0||e-- >0)&&!(n=i.next()).done;)s.push(n.value)}catch(a){o={error:a}}finally{try{n&&!n.done&&(r=i.return)&&r.call(i)}finally{if(o)throw o.error}}return s},$c=function(t,e,r){if(r||arguments.length===2)for(var i=0,n=e.length,s;i<n;i++)(s||!(i in e))&&(s||(s=Array.prototype.slice.call(e,0,i)),s[i]=e[i]);return t.concat(s||Array.prototype.slice.call(e))},ot=function(t){ho(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.prototype.copy=function(){return new e(this.node,this.size,this.getElementByPos,this.setElementByPos,this.iteratorType)},e}(Br),Gc=function(t){ho(e,t);function e(r,i){r===void 0&&(r=[]),i===void 0&&(i=4096);var n=t.call(this)||this;n.first=0,n.curFirst=0,n.last=0,n.curLast=0,n.bucketNum=0,n.map=[];var s;if("size"in r)typeof r.size=="number"?s=r.size:s=r.size();else if("length"in r)s=r.length;else throw new RangeError("Can't get container's size!");n.bucketSize=i,n.bucketNum=Math.max(Math.ceil(s/n.bucketSize),1);for(var o=0;o<n.bucketNum;++o)n.map.push(new Array(n.bucketSize));var a=Math.ceil(s/n.bucketSize);return n.first=n.last=(n.bucketNum>>1)-(a>>1),n.curFirst=n.curLast=n.bucketSize-s%n.bucketSize>>1,r.forEach(function(u){return n.pushBack(u)}),n.size=n.size.bind(n),n.getElementByPos=n.getElementByPos.bind(n),n.setElementByPos=n.setElementByPos.bind(n),n}return e.prototype.reAllocate=function(){for(var r=[],i=Math.max(this.bucketNum>>1,1),n=0;n<i;++n)r[n]=new Array(this.bucketSize);for(var n=this.first;n<this.bucketNum;++n)r[r.length]=this.map[n];for(var n=0;n<this.last;++n)r[r.length]=this.map[n];r[r.length]=$c([],zc(this.map[this.last]),!1),this.first=i,this.last=r.length-1;for(var n=0;n<i;++n)r[r.length]=new Array(this.bucketSize);this.map=r,this.bucketNum=r.length},e.prototype.getElementIndex=function(r){var i=this.curFirst+r+1,n=i%this.bucketSize,s=n-1,o=this.first+(i-n)/this.bucketSize;return n===0&&(o-=1),o%=this.bucketNum,s<0&&(s+=this.bucketSize),{curNodeBucketIndex:o,curNodePointerIndex:s}},e.prototype.clear=function(){this.map=[[]],this.bucketNum=1,this.first=this.last=this.length=0,this.curFirst=this.curLast=this.bucketSize>>1},e.prototype.front=function(){return this.map[this.first][this.curFirst]},e.prototype.back=function(){return this.map[this.last][this.curLast]},e.prototype.begin=function(){return new ot(0,this.size,this.getElementByPos,this.setElementByPos)},e.prototype.end=function(){return new ot(this.length,this.size,this.getElementByPos,this.setElementByPos)},e.prototype.rBegin=function(){return new ot(this.length-1,this.size,this.getElementByPos,this.setElementByPos,A.REVERSE)},e.prototype.rEnd=function(){return new ot(-1,this.size,this.getElementByPos,this.setElementByPos,A.REVERSE)},e.prototype.pushBack=function(r){this.length&&(this.curLast<this.bucketSize-1?this.curLast+=1:this.last<this.bucketNum-1?(this.last+=1,this.curLast=0):(this.last=0,this.curLast=0),this.last===this.first&&this.curLast===this.curFirst&&this.reAllocate()),this.length+=1,this.map[this.last][this.curLast]=r},e.prototype.popBack=function(){this.length&&(this.map[this.last][this.curLast]=void 0,this.length!==1&&(this.curLast>0?this.curLast-=1:this.last>0?(this.last-=1,this.curLast=this.bucketSize-1):(this.last=this.bucketNum-1,this.curLast=this.bucketSize-1)),this.length-=1)},e.prototype.pushFront=function(r){this.length&&(this.curFirst>0?this.curFirst-=1:this.first>0?(this.first-=1,this.curFirst=this.bucketSize-1):(this.first=this.bucketNum-1,this.curFirst=this.bucketSize-1),this.first===this.last&&this.curFirst===this.curLast&&this.reAllocate()),this.length+=1,this.map[this.first][this.curFirst]=r},e.prototype.popFront=function(){this.length&&(this.map[this.first][this.curFirst]=void 0,this.length!==1&&(this.curFirst<this.bucketSize-1?this.curFirst+=1:this.first<this.bucketNum-1?(this.first+=1,this.curFirst=0):(this.first=0,this.curFirst=0)),this.length-=1)},e.prototype.forEach=function(r){for(var i=0;i<this.length;++i)r(this.getElementByPos(i),i)},e.prototype.getElementByPos=function(r){B(r,0,this.length-1);var i=this.getElementIndex(r),n=i.curNodeBucketIndex,s=i.curNodePointerIndex;return this.map[n][s]},e.prototype.setElementByPos=function(r,i){B(r,0,this.length-1);var n=this.getElementIndex(r),s=n.curNodeBucketIndex,o=n.curNodePointerIndex;this.map[s][o]=i},e.prototype.insert=function(r,i,n){if(n===void 0&&(n=1),B(r,0,this.length),r===0)for(;n--;)this.pushFront(i);else if(r===this.length)for(;n--;)this.pushBack(i);else{for(var s=[],o=r;o<this.length;++o)s.push(this.getElementByPos(o));this.cut(r-1);for(var o=0;o<n;++o)this.pushBack(i);for(var o=0;o<s.length;++o)this.pushBack(s[o])}},e.prototype.cut=function(r){if(r<0){this.clear();return}var i=this.getElementIndex(r),n=i.curNodeBucketIndex,s=i.curNodePointerIndex;this.last=n,this.curLast=s,this.length=r+1},e.prototype.eraseElementByPos=function(r){var i=this;if(B(r,0,this.length-1),r===0)this.popFront();else if(r===this.length-1)this.popBack();else{for(var n=[],s=r+1;s<this.length;++s)n.push(this.getElementByPos(s));this.cut(r),this.popBack(),n.forEach(function(o){return i.pushBack(o)})}},e.prototype.eraseElementByValue=function(r){if(this.length){for(var i=[],n=0;n<this.length;++n){var s=this.getElementByPos(n);s!==r&&i.push(s)}for(var o=i.length,n=0;n<o;++n)this.setElementByPos(n,i[n]);this.cut(o-1)}},e.prototype.eraseElementByIterator=function(r){var i=r.node;return this.eraseElementByPos(i),r=r.next(),r},e.prototype.find=function(r){for(var i=0;i<this.length;++i)if(this.getElementByPos(i)===r)return new ot(i,this.size,this.getElementByPos,this.setElementByPos);return this.end()},e.prototype.reverse=function(){for(var r=0,i=this.length-1;r<i;){var n=this.getElementByPos(r);this.setElementByPos(r,this.getElementByPos(i)),this.setElementByPos(i,n),r+=1,i-=1}},e.prototype.unique=function(){if(!(this.length<=1)){for(var r=1,i=this.getElementByPos(0),n=1;n<this.length;++n){var s=this.getElementByPos(n);s!==i&&(i=s,this.setElementByPos(r++,s))}for(;this.length>r;)this.popBack()}},e.prototype.sort=function(r){for(var i=[],n=0;n<this.length;++n)i.push(this.getElementByPos(n));i.sort(r);for(var n=0;n<this.length;++n)this.setElementByPos(n,i[n])},e.prototype.shrinkToFit=function(){if(this.length){var r=[];this.forEach(function(n){return r.push(n)}),this.bucketNum=Math.max(Math.ceil(this.length/this.bucketSize),1),this.length=this.first=this.last=this.curFirst=this.curLast=0,this.map=[];for(var i=0;i<this.bucketNum;++i)this.map.push(new Array(this.bucketSize));for(var i=0;i<r.length;++i)this.pushBack(r[i])}},e.prototype[Symbol.iterator]=function(){return function(){var r;return Kc(this,function(i){switch(i.label){case 0:r=0,i.label=1;case 1:return r<this.length?[4,this.getElementByPos(r)]:[3,4];case 2:i.sent(),i.label=3;case 3:return++r,[3,1];case 4:return[2]}})}.bind(this)()},e}(Ue),kr=Gc});var Qc,Yc,po,go=U(()=>{"use strict";Ki();Y();Qc=function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}(),Yc=function(t){Qc(e,t);function e(r){r===void 0&&(r=[]);var i=t.call(this)||this;return i.queue=new kr(r),i.length=i.queue.size(),i}return e.prototype.clear=function(){this.queue.clear(),this.length=0},e.prototype.push=function(r){this.queue.pushBack(r),this.length+=1},e.prototype.pop=function(){this.queue.popFront(),this.length&&(this.length-=1)},e.prototype.front=function(){return this.queue.front()},e}(Te),po=Yc});var Xc,Lr,Jc,Zc,yo,_o=U(()=>{"use strict";Y();Xc=function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}(),Lr=function(t,e){var r=typeof Symbol=="function"&&t[Symbol.iterator];if(!r)return t;var i=r.call(t),n,s=[],o;try{for(;(e===void 0||e-- >0)&&!(n=i.next()).done;)s.push(n.value)}catch(a){o={error:a}}finally{try{n&&!n.done&&(r=i.return)&&r.call(i)}finally{if(o)throw o.error}}return s},Jc=function(t,e,r){if(r||arguments.length===2)for(var i=0,n=e.length,s;i<n;i++)(s||!(i in e))&&(s||(s=Array.prototype.slice.call(e,0,i)),s[i]=e[i]);return t.concat(s||Array.prototype.slice.call(e))},Zc=function(t){Xc(e,t);function e(r,i,n){var s;r===void 0&&(r=[]),i===void 0&&(i=function(d,m){return d>m?-1:d<m?1:0}),n===void 0&&(n=!0);var o=t.call(this)||this;o.cmp=i,Array.isArray(r)?o.priorityQueue=n?Jc([],Lr(r),!1):r:(o.priorityQueue=[],r.forEach(function(d){return o.priorityQueue.push(d)})),o.length=o.priorityQueue.length;for(var a=o.length-1>>1;a>=0;--a)for(var u=a,l=u<<1|1;l<o.length;){var f=l,h=f+1,c=f;if(h<o.length&&o.cmp(o.priorityQueue[f],o.priorityQueue[h])>0&&(c=h),o.cmp(o.priorityQueue[u],o.priorityQueue[c])<=0)break;s=Lr([o.priorityQueue[c],o.priorityQueue[u]],2),o.priorityQueue[u]=s[0],o.priorityQueue[c]=s[1],u=c,l=u<<1|1}return o}return e.prototype.adjust=function(r){var i,n,s=r<<1|1,o=(r<<1)+2;s<this.length&&this.cmp(this.priorityQueue[r],this.priorityQueue[s])>0&&(i=Lr([this.priorityQueue[s],this.priorityQueue[r]],2),this.priorityQueue[r]=i[0],this.priorityQueue[s]=i[1]),o<this.length&&this.cmp(this.priorityQueue[r],this.priorityQueue[o])>0&&(n=Lr([this.priorityQueue[o],this.priorityQueue[r]],2),this.priorityQueue[r]=n[0],this.priorityQueue[o]=n[1])},e.prototype.clear=function(){this.length=0,this.priorityQueue.length=0},e.prototype.push=function(r){if(this.priorityQueue.push(r),this.length+=1,this.length!==1)for(var i=this.length-1;i>0;){var n=i-1>>1;if(this.cmp(this.priorityQueue[n],r)<=0)break;this.adjust(n),i=n}},e.prototype.pop=function(){if(this.length){var r=this.priorityQueue[this.length-1];this.length-=1;for(var i=0;i<this.length;){var n=i<<1|1,s=(i<<1)+2;if(n>=this.length)break;var o=n;if(s<this.length&&this.cmp(this.priorityQueue[n],this.priorityQueue[s])>0&&(o=s),this.cmp(this.priorityQueue[o],r)>=0)break;this.priorityQueue[i]=this.priorityQueue[o],i=o}this.priorityQueue[i]=r,this.priorityQueue.pop()}},e.prototype.top=function(){return this.priorityQueue[0]},e}(Te),yo=Zc});var bo,eh,mo,vo,th,at,rh,M,Mr=U(()=>{"use strict";Ht();je();Y();Hi();bo=function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}(),eh=function(t,e){var r={label:0,sent:function(){if(s[0]&1)throw s[1];return s[1]},trys:[],ops:[]},i,n,s,o;return o={next:a(0),throw:a(1),return:a(2)},typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function a(l){return function(f){return u([l,f])}}function u(l){if(i)throw new TypeError("Generator is already executing.");for(;r;)try{if(i=1,n&&(s=l[0]&2?n.return:l[0]?n.throw||((s=n.return)&&s.call(n),0):n.next)&&!(s=s.call(n,l[1])).done)return s;switch(n=0,s&&(l=[l[0]&2,s.value]),l[0]){case 0:case 1:s=l;break;case 4:return r.label++,{value:l[1],done:!1};case 5:r.label++,n=l[1],l=[0];continue;case 7:l=r.ops.pop(),r.trys.pop();continue;default:if(s=r.trys,!(s=s.length>0&&s[s.length-1])&&(l[0]===6||l[0]===2)){r=0;continue}if(l[0]===3&&(!s||l[1]>s[0]&&l[1]<s[3])){r.label=l[1];break}if(l[0]===6&&r.label<s[1]){r.label=s[1],s=l;break}if(s&&r.label<s[2]){r.label=s[2],r.ops.push(l);break}s[2]&&r.ops.pop(),r.trys.pop();continue}l=e.call(t,r)}catch(f){l=[6,f],n=0}finally{i=s=0}if(l[0]&5)throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}},mo=function(t,e){var r=typeof Symbol=="function"&&t[Symbol.iterator];if(!r)return t;var i=r.call(t),n,s=[],o;try{for(;(e===void 0||e-- >0)&&!(n=i.next()).done;)s.push(n.value)}catch(a){o={error:a}}finally{try{n&&!n.done&&(r=i.return)&&r.call(i)}finally{if(o)throw o.error}}return s},vo=function(t,e,r){if(r||arguments.length===2)for(var i=0,n=e.length,s;i<n;i++)(s||!(i in e))&&(s||(s=Array.prototype.slice.call(e,0,i)),s[i]=e[i]);return t.concat(s||Array.prototype.slice.call(e))},th=function(t){var e=typeof Symbol=="function"&&Symbol.iterator,r=e&&t[e],i=0;if(r)return r.call(t);if(t&&typeof t.length=="number")return{next:function(){return t&&i>=t.length&&(t=void 0),{value:t&&t[i++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},at=function(t){bo(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.prototype.copy=function(){return new e(this.node,this.size,this.getElementByPos,this.setElementByPos,this.iteratorType)},e}(Br),rh=function(t){bo(e,t);function e(r,i){r===void 0&&(r=[]),i===void 0&&(i=!0);var n=t.call(this)||this;return Array.isArray(r)?(n.vector=i?vo([],mo(r),!1):r,n.length=r.length):(n.vector=[],r.forEach(function(s){return n.pushBack(s)})),n.size=n.size.bind(n),n.getElementByPos=n.getElementByPos.bind(n),n.setElementByPos=n.setElementByPos.bind(n),n}return e.prototype.clear=function(){this.length=0,this.vector.length=0},e.prototype.begin=function(){return new at(0,this.size,this.getElementByPos,this.setElementByPos)},e.prototype.end=function(){return new at(this.length,this.size,this.getElementByPos,this.setElementByPos)},e.prototype.rBegin=function(){return new at(this.length-1,this.size,this.getElementByPos,this.setElementByPos,A.REVERSE)},e.prototype.rEnd=function(){return new at(-1,this.size,this.getElementByPos,this.setElementByPos,A.REVERSE)},e.prototype.front=function(){return this.vector[0]},e.prototype.back=function(){return this.vector[this.length-1]},e.prototype.forEach=function(r){for(var i=0;i<this.length;++i)r(this.vector[i],i)},e.prototype.getElementByPos=function(r){return B(r,0,this.length-1),this.vector[r]},e.prototype.eraseElementByPos=function(r){B(r,0,this.length-1),this.vector.splice(r,1),this.length-=1},e.prototype.eraseElementByValue=function(r){for(var i=0,n=0;n<this.length;++n)this.vector[n]!==r&&(this.vector[i++]=this.vector[n]);this.length=this.vector.length=i},e.prototype.eraseElementByIterator=function(r){var i=r.node;return r=r.next(),this.eraseElementByPos(i),r},e.prototype.pushBack=function(r){this.vector.push(r),this.length+=1},e.prototype.popBack=function(){this.length&&(this.vector.pop(),this.length-=1)},e.prototype.setElementByPos=function(r,i){B(r,0,this.length-1),this.vector[r]=i},e.prototype.insert=function(r,i,n){var s;n===void 0&&(n=1),B(r,0,this.length),(s=this.vector).splice.apply(s,vo([r,0],mo(new Array(n).fill(i)),!1)),this.length+=n},e.prototype.find=function(r){for(var i=0;i<this.length;++i)if(this.vector[i]===r)return new at(i,this.size,this.getElementByPos,this.getElementByPos);return this.end()},e.prototype.reverse=function(){this.vector.reverse()},e.prototype.unique=function(){for(var r=1,i=1;i<this.length;++i)this.vector[i]!==this.vector[i-1]&&(this.vector[r++]=this.vector[i]);this.length=this.vector.length=r},e.prototype.sort=function(r){this.vector.sort(r)},e.prototype[Symbol.iterator]=function(){return function(){return eh(this,function(r){switch(r.label){case 0:return[5,th(this.vector)];case 1:return[2,r.sent()]}})}.bind(this)()},e}(Ue),M=rh});var wo,ih,Kt,lt,nh,So,Eo=U(()=>{"use strict";Ht();je();Y();wo=function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}(),ih=function(t,e){var r={label:0,sent:function(){if(s[0]&1)throw s[1];return s[1]},trys:[],ops:[]},i,n,s,o;return o={next:a(0),throw:a(1),return:a(2)},typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function a(l){return function(f){return u([l,f])}}function u(l){if(i)throw new TypeError("Generator is already executing.");for(;r;)try{if(i=1,n&&(s=l[0]&2?n.return:l[0]?n.throw||((s=n.return)&&s.call(n),0):n.next)&&!(s=s.call(n,l[1])).done)return s;switch(n=0,s&&(l=[l[0]&2,s.value]),l[0]){case 0:case 1:s=l;break;case 4:return r.label++,{value:l[1],done:!1};case 5:r.label++,n=l[1],l=[0];continue;case 7:l=r.ops.pop(),r.trys.pop();continue;default:if(s=r.trys,!(s=s.length>0&&s[s.length-1])&&(l[0]===6||l[0]===2)){r=0;continue}if(l[0]===3&&(!s||l[1]>s[0]&&l[1]<s[3])){r.label=l[1];break}if(l[0]===6&&r.label<s[1]){r.label=s[1],s=l;break}if(s&&r.label<s[2]){r.label=s[2],r.ops.push(l);break}s[2]&&r.ops.pop(),r.trys.pop();continue}l=e.call(t,r)}catch(f){l=[6,f],n=0}finally{i=s=0}if(l[0]&5)throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}},Kt=function(){function t(e){this.value=void 0,this.pre=void 0,this.next=void 0,this.value=e}return t}(),lt=function(t){wo(e,t);function e(r,i,n){var s=t.call(this,n)||this;return s.node=r,s.header=i,s.iteratorType===A.NORMAL?(s.pre=function(){if(this.node.pre===this.header)throw new RangeError("LinkList iterator access denied!");return this.node=this.node.pre,this},s.next=function(){if(this.node===this.header)throw new RangeError("LinkList iterator access denied!");return this.node=this.node.next,this}):(s.pre=function(){if(this.node.next===this.header)throw new RangeError("LinkList iterator access denied!");return this.node=this.node.next,this},s.next=function(){if(this.node===this.header)throw new RangeError("LinkList iterator access denied!");return this.node=this.node.pre,this}),s}return Object.defineProperty(e.prototype,"pointer",{get:function(){if(this.node===this.header)throw new RangeError("LinkList iterator access denied!");return this.node.value},set:function(r){if(this.node===this.header)throw new RangeError("LinkList iterator access denied!");this.node.value=r},enumerable:!1,configurable:!0}),e.prototype.equals=function(r){return this.node===r.node},e.prototype.copy=function(){return new e(this.node,this.header,this.iteratorType)},e}(A),nh=function(t){wo(e,t);function e(r){r===void 0&&(r=[]);var i=t.call(this)||this;return i.header=new Kt,i.head=void 0,i.tail=void 0,r.forEach(function(n){return i.pushBack(n)}),i}return e.prototype.clear=function(){this.length=0,this.head=this.tail=void 0,this.header.pre=this.header.next=void 0},e.prototype.begin=function(){return new lt(this.head||this.header,this.header)},e.prototype.end=function(){return new lt(this.header,this.header)},e.prototype.rBegin=function(){return new lt(this.tail||this.header,this.header,A.REVERSE)},e.prototype.rEnd=function(){return new lt(this.header,this.header,A.REVERSE)},e.prototype.front=function(){return this.head?this.head.value:void 0},e.prototype.back=function(){return this.tail?this.tail.value:void 0},e.prototype.forEach=function(r){if(this.length)for(var i=this.head,n=0;i!==this.header;)r(i.value,n++),i=i.next},e.prototype.getElementByPos=function(r){B(r,0,this.length-1);for(var i=this.head;r--;)i=i.next;return i.value},e.prototype.eraseElementByPos=function(r){if(B(r,0,this.length-1),r===0)this.popFront();else if(r===this.length-1)this.popBack();else{for(var i=this.head;r--;)i=i.next;i=i;var n=i.pre,s=i.next;s.pre=n,n.next=s,this.length-=1}},e.prototype.eraseElementByValue=function(r){for(;this.head&&this.head.value===r;)this.popFront();for(;this.tail&&this.tail.value===r;)this.popBack();if(this.head)for(var i=this.head;i!==this.header;){if(i.value===r){var n=i.pre,s=i.next;s&&(s.pre=n),n&&(n.next=s),this.length-=1}i=i.next}},e.prototype.eraseElementByIterator=function(r){var i=r.node;if(i===this.header)throw new RangeError("Invalid iterator");if(r=r.next(),this.head===i)this.popFront();else if(this.tail===i)this.popBack();else{var n=i.pre,s=i.next;s&&(s.pre=n),n&&(n.next=s),this.length-=1}return r},e.prototype.pushBack=function(r){this.length+=1;var i=new Kt(r);this.tail?(this.tail.next=i,i.pre=this.tail,this.tail=i):(this.head=this.tail=i,this.header.next=this.head,this.head.pre=this.header),this.tail.next=this.header,this.header.pre=this.tail},e.prototype.popBack=function(){this.tail&&(this.length-=1,this.head===this.tail?(this.head=this.tail=void 0,this.header.next=void 0):(this.tail=this.tail.pre,this.tail&&(this.tail.next=void 0)),this.header.pre=this.tail,this.tail&&(this.tail.next=this.header))},e.prototype.setElementByPos=function(r,i){B(r,0,this.length-1);for(var n=this.head;r--;)n=n.next;n.value=i},e.prototype.insert=function(r,i,n){if(n===void 0&&(n=1),B(r,0,this.length),!(n<=0))if(r===0)for(;n--;)this.pushFront(i);else if(r===this.length)for(;n--;)this.pushBack(i);else{for(var s=this.head,o=1;o<r;++o)s=s.next;var a=s.next;for(this.length+=n;n--;)s.next=new Kt(i),s.next.pre=s,s=s.next;s.next=a,a&&(a.pre=s)}},e.prototype.find=function(r){if(!this.head)return this.end();for(var i=this.head;i!==this.header;){if(i.value===r)return new lt(i,this.header);i=i.next}return this.end()},e.prototype.reverse=function(){if(!(this.length<=1))for(var r=this.head,i=this.tail,n=0;n<<1<this.length;){var s=r.value;r.value=i.value,i.value=s,r=r.next,i=i.pre,n+=1}},e.prototype.unique=function(){if(!(this.length<=1))for(var r=this.head;r!==this.header;){for(var i=r;i.next&&i.value===i.next.value;)i=i.next,this.length-=1;r.next=i.next,r.next&&(r.next.pre=r),r=r.next}},e.prototype.sort=function(r){if(!(this.length<=1)){var i=[];this.forEach(function(s){return i.push(s)}),i.sort(r);var n=this.head;i.forEach(function(s){n.value=s,n=n.next})}},e.prototype.pushFront=function(r){this.length+=1;var i=new Kt(r);this.head?(i.next=this.head,this.head.pre=i,this.head=i):(this.head=this.tail=i,this.tail.next=this.header,this.header.pre=this.tail),this.header.next=this.head,this.head.pre=this.header},e.prototype.popFront=function(){this.head&&(this.length-=1,this.head===this.tail?(this.head=this.tail=void 0,this.header.pre=this.tail):(this.head=this.head.next,this.head&&(this.head.pre=this.header)),this.header.next=this.head)},e.prototype.merge=function(r){var i=this;if(!this.head){r.forEach(function(s){return i.pushBack(s)});return}var n=this.head;r.forEach(function(s){for(;n&&n!==i.header&&n.value<=s;)n=n.next;if(n===i.header)i.pushBack(s),n=i.tail;else if(n===i.head)i.pushFront(s),n=i.head;else{i.length+=1;var o=n.pre;o.next=new Kt(s),o.next.pre=o,o.next.next=n,n.pre=o.next}})},e.prototype[Symbol.iterator]=function(){return function(){var r;return ih(this,function(i){switch(i.label){case 0:if(!this.head)return[2];r=this.head,i.label=1;case 1:return r===this.header?[3,3]:[4,r.value];case 2:return i.sent(),r=r.next,[3,1];case 3:return[2]}})}.bind(this)()},e}(Ue),So=nh});var sh,w,xo=U(()=>{"use strict";sh=function(){function t(e,r){this.color=!0,this.key=void 0,this.value=void 0,this.left=void 0,this.right=void 0,this.parent=void 0,this.key=e,this.value=r}return t.prototype.pre=function(){var e=this;if(e.color===t.RED&&e.parent.parent===e)e=e.right;else if(e.left)for(e=e.left;e.right;)e=e.right;else{for(var r=e.parent;r.left===e;)e=r,r=e.parent;e=r}return e},t.prototype.next=function(){var e=this;if(e.right)for(e=e.right;e.left;)e=e.left;else{for(var r=e.parent;r.right===e;)e=r,r=e.parent;e.right!==r&&(e=r)}return e},t.prototype.rotateLeft=function(){var e=this.parent,r=this.right,i=r.left;return e.parent===this?e.parent=r:e.left===this?e.left=r:e.right=r,r.parent=e,r.left=this,this.parent=r,this.right=i,i&&(i.parent=this),r},t.prototype.rotateRight=function(){var e=this.parent,r=this.left,i=r.right;return e.parent===this?e.parent=r:e.left===this?e.left=r:e.right=r,r.parent=e,r.right=this,this.parent=r,this.left=i,i&&(i.parent=this),r},t.prototype.remove=function(){var e=this.parent;this===e.left?e.left=void 0:e.right=void 0},t.RED=!0,t.BLACK=!1,t}(),w=sh});var oh,To,ah,xt,qr=U(()=>{"use strict";xo();Y();je();oh=function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}(),To=function(t,e){var r=typeof Symbol=="function"&&t[Symbol.iterator];if(!r)return t;var i=r.call(t),n,s=[],o;try{for(;(e===void 0||e-- >0)&&!(n=i.next()).done;)s.push(n.value)}catch(a){o={error:a}}finally{try{n&&!n.done&&(r=i.return)&&r.call(i)}finally{if(o)throw o.error}}return s},ah=function(t){oh(e,t);function e(r){r===void 0&&(r=function(n,s){return n<s?-1:n>s?1:0});var i=t.call(this)||this;return i.root=void 0,i.header=new w,i.inOrderTraversal=function(n,s){if(n===void 0)return!1;var o=i.inOrderTraversal(n.left,s);return o||s(n)?!0:i.inOrderTraversal(n.right,s)},i.cmp=r,i}return e.prototype._lowerBound=function(r,i){for(var n;r;){var s=this.cmp(r.key,i);if(s<0)r=r.right;else if(s>0)n=r,r=r.left;else return r}return n===void 0?this.header:n},e.prototype._upperBound=function(r,i){for(var n;r;){var s=this.cmp(r.key,i);s<=0?r=r.right:s>0&&(n=r,r=r.left)}return n===void 0?this.header:n},e.prototype._reverseLowerBound=function(r,i){for(var n;r;){var s=this.cmp(r.key,i);if(s<0)n=r,r=r.right;else if(s>0)r=r.left;else return r}return n===void 0?this.header:n},e.prototype._reverseUpperBound=function(r,i){for(var n;r;){var s=this.cmp(r.key,i);s<0?(n=r,r=r.right):s>=0&&(r=r.left)}return n===void 0?this.header:n},e.prototype.eraseNodeSelfBalance=function(r){for(;;){var i=r.parent;if(i===this.header)return;if(r.color===w.RED){r.color=w.BLACK;return}if(r===i.left){var n=i.right;if(n.color===w.RED)n.color=w.BLACK,i.color=w.RED,i===this.root?this.root=i.rotateLeft():i.rotateLeft();else if(n.color===w.BLACK)if(n.right&&n.right.color===w.RED){n.color=i.color,i.color=w.BLACK,n.right.color=w.BLACK,i===this.root?this.root=i.rotateLeft():i.rotateLeft();return}else n.left&&n.left.color===w.RED?(n.color=w.RED,n.left.color=w.BLACK,n.rotateRight()):(n.color=w.RED,r=i)}else{var n=i.left;if(n.color===w.RED)n.color=w.BLACK,i.color=w.RED,i===this.root?this.root=i.rotateRight():i.rotateRight();else if(n.left&&n.left.color===w.RED){n.color=i.color,i.color=w.BLACK,n.left.color=w.BLACK,i===this.root?this.root=i.rotateRight():i.rotateRight();return}else n.right&&n.right.color===w.RED?(n.color=w.RED,n.right.color=w.BLACK,n.rotateLeft()):(n.color=w.RED,r=i)}}},e.prototype.eraseNode=function(r){var i,n;if(this.length===1){this.clear();return}for(var s=r;s.left||s.right;){if(s.right)for(s=s.right;s.left;)s=s.left;else s.left&&(s=s.left);i=To([s.key,r.key],2),r.key=i[0],s.key=i[1],n=To([s.value,r.value],2),r.value=n[0],s.value=n[1],r=s}this.header.left===s?this.header.left=s.parent:this.header.right===s&&(this.header.right=s.parent),this.eraseNodeSelfBalance(s),s.remove(),this.length-=1,this.root.color=w.BLACK},e.prototype.insertNodeSelfBalance=function(r){for(;;){var i=r.parent;if(i.color===w.BLACK)return;var n=i.parent;if(i===n.left){var s=n.right;if(s&&s.color===w.RED){if(s.color=i.color=w.BLACK,n===this.root)return;n.color=w.RED,r=n;continue}else if(r===i.right){if(r.color=w.BLACK,r.left&&(r.left.parent=i),r.right&&(r.right.parent=n),i.right=r.left,n.left=r.right,r.left=i,r.right=n,n===this.root)this.root=r,this.header.parent=r;else{var o=n.parent;o.left===n?o.left=r:o.right=r}r.parent=n.parent,i.parent=r,n.parent=r}else i.color=w.BLACK,n===this.root?this.root=n.rotateRight():n.rotateRight();n.color=w.RED}else{var s=n.left;if(s&&s.color===w.RED){if(s.color=i.color=w.BLACK,n===this.root)return;n.color=w.RED,r=n;continue}else if(r===i.left){if(r.color=w.BLACK,r.left&&(r.left.parent=n),r.right&&(r.right.parent=i),n.right=r.left,i.left=r.right,r.left=n,r.right=i,n===this.root)this.root=r,this.header.parent=r;else{var o=n.parent;o.left===n?o.left=r:o.right=r}r.parent=n.parent,i.parent=r,n.parent=r}else i.color=w.BLACK,n===this.root?this.root=n.rotateLeft():n.rotateLeft();n.color=w.RED}return}},e.prototype.findElementNode=function(r,i){for(;r;){var n=this.cmp(r.key,i);if(n<0)r=r.right;else if(n>0)r=r.left;else return r}return r},e.prototype.set=function(r,i,n){if(this.root===void 0){this.length+=1,this.root=new w(r,i),this.root.color=w.BLACK,this.root.parent=this.header,this.header.parent=this.root,this.header.left=this.root,this.header.right=this.root;return}var s,o=this.header.left,a=this.cmp(o.key,r);if(a===0){o.value=i;return}else if(a>0)o.left=new w(r,i),o.left.parent=o,s=o.left,this.header.left=s;else{var u=this.header.right,l=this.cmp(u.key,r);if(l===0){u.value=i;return}else if(l<0)u.right=new w(r,i),u.right.parent=u,s=u.right,this.header.right=s;else{if(n!==void 0){var f=n.node;if(f!==this.header){var h=this.cmp(f.key,r);if(h===0){f.value=i;return}else if(h>0){var c=f.pre(),d=this.cmp(c.key,r);if(d===0){c.value=i;return}else d<0&&(s=new w(r,i),c.right===void 0?(c.right=s,s.parent=c):(f.left=s,s.parent=f))}}}if(s===void 0)for(s=this.root;;){var m=this.cmp(s.key,r);if(m>0){if(s.left===void 0){s.left=new w(r,i),s.left.parent=s,s=s.left;break}s=s.left}else if(m<0){if(s.right===void 0){s.right=new w(r,i),s.right.parent=s,s=s.right;break}s=s.right}else{s.value=i;return}}}}this.length+=1,this.insertNodeSelfBalance(s)},e.prototype.clear=function(){this.length=0,this.root=void 0,this.header.parent=void 0,this.header.left=this.header.right=void 0},e.prototype.updateKeyByIterator=function(r,i){var n=r.node;if(n===this.header)throw new TypeError("Invalid iterator!");if(this.length===1)return n.key=i,!0;if(n===this.header.left)return this.cmp(n.next().key,i)>0?(n.key=i,!0):!1;if(n===this.header.right)return this.cmp(n.pre().key,i)<0?(n.key=i,!0):!1;var s=n.pre().key;if(this.cmp(s,i)>=0)return!1;var o=n.next().key;return this.cmp(o,i)<=0?!1:(n.key=i,!0)},e.prototype.eraseElementByPos=function(r){var i=this;B(r,0,this.length-1);var n=0;this.inOrderTraversal(this.root,function(s){return r===n?(i.eraseNode(s),!0):(n+=1,!1)})},e.prototype.eraseElementByKey=function(r){if(this.length){var i=this.findElementNode(this.root,r);i!==void 0&&this.eraseNode(i)}},e.prototype.eraseElementByIterator=function(r){var i=r.node;if(i===this.header)throw new RangeError("Invalid iterator");return i.right===void 0&&(r=r.next()),this.eraseNode(i),r},e.prototype.getHeight=function(){if(!this.length)return 0;var r=function(i){return i?Math.max(r(i.left),r(i.right))+1:0};return r(this.root)},e}(Et),xt=ah});var lh,uh,Nr,zi=U(()=>{"use strict";Y();lh=function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}(),uh=function(t){lh(e,t);function e(r,i,n){var s=t.call(this,n)||this;return s.node=r,s.header=i,s.iteratorType===A.NORMAL?(s.pre=function(){if(this.node===this.header.left)throw new RangeError("LinkList iterator access denied!");return this.node=this.node.pre(),this},s.next=function(){if(this.node===this.header)throw new RangeError("LinkList iterator access denied!");return this.node=this.node.next(),this}):(s.pre=function(){if(this.node===this.header.right)throw new RangeError("LinkList iterator access denied!");return this.node=this.node.next(),this},s.next=function(){if(this.node===this.header)throw new RangeError("LinkList iterator access denied!");return this.node=this.node.pre(),this}),s}return e.prototype.equals=function(r){return this.node===r.node},e}(A),Nr=uh});var Co,fh,Dr,fe,ch,Ce,$i=U(()=>{"use strict";qr();Y();je();zi();Co=function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}(),fh=function(t,e){var r={label:0,sent:function(){if(s[0]&1)throw s[1];return s[1]},trys:[],ops:[]},i,n,s,o;return o={next:a(0),throw:a(1),return:a(2)},typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function a(l){return function(f){return u([l,f])}}function u(l){if(i)throw new TypeError("Generator is already executing.");for(;r;)try{if(i=1,n&&(s=l[0]&2?n.return:l[0]?n.throw||((s=n.return)&&s.call(n),0):n.next)&&!(s=s.call(n,l[1])).done)return s;switch(n=0,s&&(l=[l[0]&2,s.value]),l[0]){case 0:case 1:s=l;break;case 4:return r.label++,{value:l[1],done:!1};case 5:r.label++,n=l[1],l=[0];continue;case 7:l=r.ops.pop(),r.trys.pop();continue;default:if(s=r.trys,!(s=s.length>0&&s[s.length-1])&&(l[0]===6||l[0]===2)){r=0;continue}if(l[0]===3&&(!s||l[1]>s[0]&&l[1]<s[3])){r.label=l[1];break}if(l[0]===6&&r.label<s[1]){r.label=s[1],s=l;break}if(s&&r.label<s[2]){r.label=s[2],r.ops.push(l);break}s[2]&&r.ops.pop(),r.trys.pop();continue}l=e.call(t,r)}catch(f){l=[6,f],n=0}finally{i=s=0}if(l[0]&5)throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}},Dr=function(t){var e=typeof Symbol=="function"&&Symbol.iterator,r=e&&t[e],i=0;if(r)return r.call(t);if(t&&typeof t.length=="number")return{next:function(){return t&&i>=t.length&&(t=void 0),{value:t&&t[i++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},fe=function(t){Co(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return Object.defineProperty(e.prototype,"pointer",{get:function(){if(this.node===this.header)throw new RangeError("OrderedSet iterator access denied!");return this.node.key},enumerable:!1,configurable:!0}),e.prototype.copy=function(){return new e(this.node,this.header,this.iteratorType)},e}(Nr),ch=function(t){Co(e,t);function e(r,i){r===void 0&&(r=[]);var n=t.call(this,i)||this;return n.iterationFunc=function(s){return fh(this,function(o){switch(o.label){case 0:return s===void 0?[2]:[5,Dr(this.iterationFunc(s.left))];case 1:return o.sent(),[4,s.key];case 2:return o.sent(),[5,Dr(this.iterationFunc(s.right))];case 3:return o.sent(),[2]}})},r.forEach(function(s){return n.insert(s)}),n.iterationFunc=n.iterationFunc.bind(n),n}return e.prototype.begin=function(){return new fe(this.header.left||this.header,this.header)},e.prototype.end=function(){return new fe(this.header,this.header)},e.prototype.rBegin=function(){return new fe(this.header.right||this.header,this.header,A.REVERSE)},e.prototype.rEnd=function(){return new fe(this.header,this.header,A.REVERSE)},e.prototype.front=function(){return this.header.left?this.header.left.key:void 0},e.prototype.back=function(){return this.header.right?this.header.right.key:void 0},e.prototype.forEach=function(r){var i,n,s=0;try{for(var o=Dr(this),a=o.next();!a.done;a=o.next()){var u=a.value;r(u,s++)}}catch(l){i={error:l}}finally{try{a&&!a.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}},e.prototype.getElementByPos=function(r){var i,n;B(r,0,this.length-1);var s,o=0;try{for(var a=Dr(this),u=a.next();!u.done;u=a.next()){var l=u.value;o===r&&(s=l),o+=1}}catch(f){i={error:f}}finally{try{u&&!u.done&&(n=a.return)&&n.call(a)}finally{if(i)throw i.error}}return s},e.prototype.insert=function(r,i){this.set(r,void 0,i)},e.prototype.find=function(r){var i=this.findElementNode(this.root,r);return i!==void 0?new fe(i,this.header):this.end()},e.prototype.lowerBound=function(r){var i=this._lowerBound(this.root,r);return new fe(i,this.header)},e.prototype.upperBound=function(r){var i=this._upperBound(this.root,r);return new fe(i,this.header)},e.prototype.reverseLowerBound=function(r){var i=this._reverseLowerBound(this.root,r);return new fe(i,this.header)},e.prototype.reverseUpperBound=function(r){var i=this._reverseUpperBound(this.root,r);return new fe(i,this.header)},e.prototype.union=function(r){var i=this;r.forEach(function(n){return i.insert(n)})},e.prototype[Symbol.iterator]=function(){return this.iterationFunc(this.root)},e}(xt),Ce=ch});var Oo,hh,Po,Ur,ce,dh,he,Gi=U(()=>{"use strict";Y();je();qr();zi();Oo=function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}(),hh=function(t,e){var r={label:0,sent:function(){if(s[0]&1)throw s[1];return s[1]},trys:[],ops:[]},i,n,s,o;return o={next:a(0),throw:a(1),return:a(2)},typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function a(l){return function(f){return u([l,f])}}function u(l){if(i)throw new TypeError("Generator is already executing.");for(;r;)try{if(i=1,n&&(s=l[0]&2?n.return:l[0]?n.throw||((s=n.return)&&s.call(n),0):n.next)&&!(s=s.call(n,l[1])).done)return s;switch(n=0,s&&(l=[l[0]&2,s.value]),l[0]){case 0:case 1:s=l;break;case 4:return r.label++,{value:l[1],done:!1};case 5:r.label++,n=l[1],l=[0];continue;case 7:l=r.ops.pop(),r.trys.pop();continue;default:if(s=r.trys,!(s=s.length>0&&s[s.length-1])&&(l[0]===6||l[0]===2)){r=0;continue}if(l[0]===3&&(!s||l[1]>s[0]&&l[1]<s[3])){r.label=l[1];break}if(l[0]===6&&r.label<s[1]){r.label=s[1],s=l;break}if(s&&r.label<s[2]){r.label=s[2],r.ops.push(l);break}s[2]&&r.ops.pop(),r.trys.pop();continue}l=e.call(t,r)}catch(f){l=[6,f],n=0}finally{i=s=0}if(l[0]&5)throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}},Po=function(t,e){var r=typeof Symbol=="function"&&t[Symbol.iterator];if(!r)return t;var i=r.call(t),n,s=[],o;try{for(;(e===void 0||e-- >0)&&!(n=i.next()).done;)s.push(n.value)}catch(a){o={error:a}}finally{try{n&&!n.done&&(r=i.return)&&r.call(i)}finally{if(o)throw o.error}}return s},Ur=function(t){var e=typeof Symbol=="function"&&Symbol.iterator,r=e&&t[e],i=0;if(r)return r.call(t);if(t&&typeof t.length=="number")return{next:function(){return t&&i>=t.length&&(t=void 0),{value:t&&t[i++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},ce=function(t){Oo(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return Object.defineProperty(e.prototype,"pointer",{get:function(){var r=this;if(this.node===this.header)throw new RangeError("OrderedMap iterator access denied");return new Proxy([],{get:function(i,n){if(n==="0")return r.node.key;if(n==="1")return r.node.value},set:function(i,n,s){if(n!=="1")throw new TypeError("props must be 1");return r.node.value=s,!0}})},enumerable:!1,configurable:!0}),e.prototype.copy=function(){return new e(this.node,this.header,this.iteratorType)},e}(Nr),dh=function(t){Oo(e,t);function e(r,i){r===void 0&&(r=[]);var n=t.call(this,i)||this;return n.iterationFunc=function(s){return hh(this,function(o){switch(o.label){case 0:return s===void 0?[2]:[5,Ur(this.iterationFunc(s.left))];case 1:return o.sent(),[4,[s.key,s.value]];case 2:return o.sent(),[5,Ur(this.iterationFunc(s.right))];case 3:return o.sent(),[2]}})},n.iterationFunc=n.iterationFunc.bind(n),r.forEach(function(s){var o=Po(s,2),a=o[0],u=o[1];return n.setElement(a,u)}),n}return e.prototype.begin=function(){return new ce(this.header.left||this.header,this.header)},e.prototype.end=function(){return new ce(this.header,this.header)},e.prototype.rBegin=function(){return new ce(this.header.right||this.header,this.header,A.REVERSE)},e.prototype.rEnd=function(){return new ce(this.header,this.header,A.REVERSE)},e.prototype.front=function(){if(this.length){var r=this.header.left;return[r.key,r.value]}},e.prototype.back=function(){if(this.length){var r=this.header.right;return[r.key,r.value]}},e.prototype.forEach=function(r){var i,n,s=0;try{for(var o=Ur(this),a=o.next();!a.done;a=o.next()){var u=a.value;r(u,s++)}}catch(l){i={error:l}}finally{try{a&&!a.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}},e.prototype.lowerBound=function(r){var i=this._lowerBound(this.root,r);return new ce(i,this.header)},e.prototype.upperBound=function(r){var i=this._upperBound(this.root,r);return new ce(i,this.header)},e.prototype.reverseLowerBound=function(r){var i=this._reverseLowerBound(this.root,r);return new ce(i,this.header)},e.prototype.reverseUpperBound=function(r){var i=this._reverseUpperBound(this.root,r);return new ce(i,this.header)},e.prototype.setElement=function(r,i,n){this.set(r,i,n)},e.prototype.find=function(r){var i=this.findElementNode(this.root,r);return i!==void 0?new ce(i,this.header):this.end()},e.prototype.getElementByKey=function(r){var i=this.findElementNode(this.root,r);return i?i.value:void 0},e.prototype.getElementByPos=function(r){var i,n;B(r,0,this.length-1);var s,o=0;try{for(var a=Ur(this),u=a.next();!u.done;u=a.next()){var l=u.value;if(o===r){s=l;break}o+=1}}catch(f){i={error:f}}finally{try{u&&!u.done&&(n=a.return)&&n.call(a)}finally{if(i)throw i.error}}return s},e.prototype.union=function(r){var i=this;r.forEach(function(n){var s=Po(n,2),o=s[0],a=s[1];return i.setElement(o,a)})},e.prototype[Symbol.iterator]=function(){return this.iterationFunc(this.root)},e}(xt),he=dh});var ph,gh,q,jr=U(()=>{"use strict";Y();ph=function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}(),gh=function(t){ph(e,t);function e(r,i){r===void 0&&(r=16),i===void 0&&(i=function(s){var o;typeof s!="string"?o=JSON.stringify(s):o=s;for(var a=0,u=o.length,l=0;l<u;l++){var f=o.charCodeAt(l);a=(a<<5)-a+f,a|=0}return a>>>0});var n=t.call(this)||this;if(r<16||(r&r-1)!==0)throw new RangeError("InitBucketNum range error");return n.bucketNum=n.initBucketNum=r,n.hashFunc=i,n}return e.prototype.clear=function(){this.length=0,this.bucketNum=this.initBucketNum,this.hashTable=[]},e.sigma=.75,e.treeifyThreshold=8,e.untreeifyThreshold=6,e.minTreeifySize=64,e.maxBucketNum=1<<30,e}(Te),q=gh});var yh,_h,mh,vh,Io,Ro=U(()=>{"use strict";jr();Mr();$i();yh=function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}(),_h=function(t,e){var r={label:0,sent:function(){if(s[0]&1)throw s[1];return s[1]},trys:[],ops:[]},i,n,s,o;return o={next:a(0),throw:a(1),return:a(2)},typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function a(l){return function(f){return u([l,f])}}function u(l){if(i)throw new TypeError("Generator is already executing.");for(;r;)try{if(i=1,n&&(s=l[0]&2?n.return:l[0]?n.throw||((s=n.return)&&s.call(n),0):n.next)&&!(s=s.call(n,l[1])).done)return s;switch(n=0,s&&(l=[l[0]&2,s.value]),l[0]){case 0:case 1:s=l;break;case 4:return r.label++,{value:l[1],done:!1};case 5:r.label++,n=l[1],l=[0];continue;case 7:l=r.ops.pop(),r.trys.pop();continue;default:if(s=r.trys,!(s=s.length>0&&s[s.length-1])&&(l[0]===6||l[0]===2)){r=0;continue}if(l[0]===3&&(!s||l[1]>s[0]&&l[1]<s[3])){r.label=l[1];break}if(l[0]===6&&r.label<s[1]){r.label=s[1],s=l;break}if(s&&r.label<s[2]){r.label=s[2],r.ops.push(l);break}s[2]&&r.ops.pop(),r.trys.pop();continue}l=e.call(t,r)}catch(f){l=[6,f],n=0}finally{i=s=0}if(l[0]&5)throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}},mh=function(t){var e=typeof Symbol=="function"&&Symbol.iterator,r=e&&t[e],i=0;if(r)return r.call(t);if(t&&typeof t.length=="number")return{next:function(){return t&&i>=t.length&&(t=void 0),{value:t&&t[i++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},vh=function(t){yh(e,t);function e(r,i,n){r===void 0&&(r=[]);var s=t.call(this,i,n)||this;return s.hashTable=[],r.forEach(function(o){return s.insert(o)}),s}return e.prototype.reAllocate=function(){var r=this;if(!(this.bucketNum>=q.maxBucketNum)){var i=[],n=this.bucketNum;this.bucketNum<<=1;for(var s=Object.keys(this.hashTable),o=s.length,a=function(f){var h=parseInt(s[f]),c=u.hashTable[h],d=c.size();if(d===0)return"continue";if(d===1){var m=c.front();return i[u.hashFunc(m)&u.bucketNum-1]=new M([m],!1),"continue"}var y=[],v=[];c.forEach(function(b){var C=r.hashFunc(b);(C&n)===0?y.push(b):v.push(b)}),c instanceof Ce?(y.length>q.untreeifyThreshold?i[h]=new Ce(y):y.length&&(i[h]=new M(y,!1)),v.length>q.untreeifyThreshold?i[h+n]=new Ce(v):v.length&&(i[h+n]=new M(v,!1))):(y.length>=q.treeifyThreshold?i[h]=new Ce(y):y.length&&(i[h]=new M(y,!1)),v.length>=q.treeifyThreshold?i[h+n]=new Ce(v):v.length&&(i[h+n]=new M(v,!1)))},u=this,l=0;l<o;++l)a(l);this.hashTable=i}},e.prototype.forEach=function(r){for(var i=Object.values(this.hashTable),n=i.length,s=0,o=0;o<n;++o)i[o].forEach(function(a){return r(a,s++)})},e.prototype.insert=function(r){var i=this.hashFunc(r)&this.bucketNum-1,n=this.hashTable[i];if(!n)this.hashTable[i]=new M([r],!1),this.length+=1;else{var s=n.size();if(n instanceof M){if(!n.find(r).equals(n.end()))return;if(n.pushBack(r),s+1>=q.treeifyThreshold){if(this.bucketNum<=q.minTreeifySize){this.length+=1,this.reAllocate();return}this.hashTable[i]=new Ce(n)}this.length+=1}else{n.insert(r);var o=n.size();this.length+=o-s}}this.length>this.bucketNum*q.sigma&&this.reAllocate()},e.prototype.eraseElementByKey=function(r){var i=this.hashFunc(r)&this.bucketNum-1,n=this.hashTable[i];if(n){var s=n.size();if(s!==0)if(n instanceof M){n.eraseElementByValue(r);var o=n.size();this.length+=o-s}else{n.eraseElementByKey(r);var o=n.size();this.length+=o-s,o<=q.untreeifyThreshold&&(this.hashTable[i]=new M(n))}}},e.prototype.find=function(r){var i=this.hashFunc(r)&this.bucketNum-1,n=this.hashTable[i];return n?!n.find(r).equals(n.end()):!1},e.prototype[Symbol.iterator]=function(){return function(){var r,i,n,s,o,a,u,l,f,h;return _h(this,function(c){switch(c.label){case 0:r=Object.values(this.hashTable),i=r.length,n=0,c.label=1;case 1:if(!(n<i))return[3,10];s=r[n],c.label=2;case 2:c.trys.push([2,7,8,9]),o=(f=void 0,mh(s)),a=o.next(),c.label=3;case 3:return a.done?[3,6]:(u=a.value,[4,u]);case 4:c.sent(),c.label=5;case 5:return a=o.next(),[3,3];case 6:return[3,9];case 7:return l=c.sent(),f={error:l},[3,9];case 8:try{a&&!a.done&&(h=o.return)&&h.call(o)}finally{if(f)throw f.error}return[7];case 9:return++n,[3,1];case 10:return[2]}})}.bind(this)()},e}(q),Io=vh});var bh,wh,zt,Sh,Ao,Bo=U(()=>{"use strict";jr();Mr();Gi();bh=function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}(),wh=function(t,e){var r={label:0,sent:function(){if(s[0]&1)throw s[1];return s[1]},trys:[],ops:[]},i,n,s,o;return o={next:a(0),throw:a(1),return:a(2)},typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function a(l){return function(f){return u([l,f])}}function u(l){if(i)throw new TypeError("Generator is already executing.");for(;r;)try{if(i=1,n&&(s=l[0]&2?n.return:l[0]?n.throw||((s=n.return)&&s.call(n),0):n.next)&&!(s=s.call(n,l[1])).done)return s;switch(n=0,s&&(l=[l[0]&2,s.value]),l[0]){case 0:case 1:s=l;break;case 4:return r.label++,{value:l[1],done:!1};case 5:r.label++,n=l[1],l=[0];continue;case 7:l=r.ops.pop(),r.trys.pop();continue;default:if(s=r.trys,!(s=s.length>0&&s[s.length-1])&&(l[0]===6||l[0]===2)){r=0;continue}if(l[0]===3&&(!s||l[1]>s[0]&&l[1]<s[3])){r.label=l[1];break}if(l[0]===6&&r.label<s[1]){r.label=s[1],s=l;break}if(s&&r.label<s[2]){r.label=s[2],r.ops.push(l);break}s[2]&&r.ops.pop(),r.trys.pop();continue}l=e.call(t,r)}catch(f){l=[6,f],n=0}finally{i=s=0}if(l[0]&5)throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}},zt=function(t){var e=typeof Symbol=="function"&&Symbol.iterator,r=e&&t[e],i=0;if(r)return r.call(t);if(t&&typeof t.length=="number")return{next:function(){return t&&i>=t.length&&(t=void 0),{value:t&&t[i++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},Sh=function(t){bh(e,t);function e(r,i,n){r===void 0&&(r=[]);var s=t.call(this,i,n)||this;return s.hashTable=[],r.forEach(function(o){return s.setElement(o[0],o[1])}),s}return e.prototype.reAllocate=function(){var r=this;if(!(this.bucketNum>=q.maxBucketNum)){var i=[],n=this.bucketNum;this.bucketNum<<=1;for(var s=Object.keys(this.hashTable),o=s.length,a=function(f){var h=parseInt(s[f]),c=u.hashTable[h],d=c.size();if(d===0)return"continue";if(d===1){var m=c.front();return i[u.hashFunc(m[0])&u.bucketNum-1]=new M([m],!1),"continue"}var y=[],v=[];c.forEach(function(b){var C=r.hashFunc(b[0]);(C&n)===0?y.push(b):v.push(b)}),c instanceof he?(y.length>q.untreeifyThreshold?i[h]=new he(y):y.length&&(i[h]=new M(y,!1)),v.length>q.untreeifyThreshold?i[h+n]=new he(v):v.length&&(i[h+n]=new M(v,!1))):(y.length>=q.treeifyThreshold?i[h]=new he(y):y.length&&(i[h]=new M(y,!1)),v.length>=q.treeifyThreshold?i[h+n]=new he(v):v.length&&(i[h+n]=new M(v,!1)))},u=this,l=0;l<o;++l)a(l);this.hashTable=i}},e.prototype.forEach=function(r){for(var i=Object.values(this.hashTable),n=i.length,s=0,o=0;o<n;++o)i[o].forEach(function(a){return r(a,s++)})},e.prototype.setElement=function(r,i){var n,s,o=this.hashFunc(r)&this.bucketNum-1,a=this.hashTable[o];if(!a)this.length+=1,this.hashTable[o]=new M([[r,i]],!1);else{var u=a.size();if(a instanceof M){try{for(var l=zt(a),f=l.next();!f.done;f=l.next()){var h=f.value;if(h[0]===r){h[1]=i;return}}}catch(d){n={error:d}}finally{try{f&&!f.done&&(s=l.return)&&s.call(l)}finally{if(n)throw n.error}}if(a.pushBack([r,i]),u+1>=e.treeifyThreshold){if(this.bucketNum<=e.minTreeifySize){this.length+=1,this.reAllocate();return}this.hashTable[o]=new he(this.hashTable[o])}this.length+=1}else{a.setElement(r,i);var c=a.size();this.length+=c-u}}this.length>this.bucketNum*e.sigma&&this.reAllocate()},e.prototype.getElementByKey=function(r){var i,n,s=this.hashFunc(r)&this.bucketNum-1,o=this.hashTable[s];if(o){if(o instanceof he)return o.getElementByKey(r);try{for(var a=zt(o),u=a.next();!u.done;u=a.next()){var l=u.value;if(l[0]===r)return l[1]}}catch(f){i={error:f}}finally{try{u&&!u.done&&(n=a.return)&&n.call(a)}finally{if(i)throw i.error}}}},e.prototype.eraseElementByKey=function(r){var i,n,s=this.hashFunc(r)&this.bucketNum-1,o=this.hashTable[s];if(o)if(o instanceof M){var a=0;try{for(var u=zt(o),l=u.next();!l.done;l=u.next()){var f=l.value;if(f[0]===r){o.eraseElementByPos(a),this.length-=1;return}a+=1}}catch(d){i={error:d}}finally{try{l&&!l.done&&(n=u.return)&&n.call(u)}finally{if(i)throw i.error}}}else{var h=o.size();o.eraseElementByKey(r);var c=o.size();this.length+=c-h,c<=q.untreeifyThreshold&&(this.hashTable[s]=new M(o))}},e.prototype.find=function(r){var i,n,s=this.hashFunc(r)&this.bucketNum-1,o=this.hashTable[s];if(!o)return!1;if(o instanceof he)return!o.find(r).equals(o.end());try{for(var a=zt(o),u=a.next();!u.done;u=a.next()){var l=u.value;if(l[0]===r)return!0}}catch(f){i={error:f}}finally{try{u&&!u.done&&(n=a.return)&&n.call(a)}finally{if(i)throw i.error}}return!1},e.prototype[Symbol.iterator]=function(){return function(){var r,i,n,s,o,a,u,l,f,h;return wh(this,function(c){switch(c.label){case 0:r=Object.values(this.hashTable),i=r.length,n=0,c.label=1;case 1:if(!(n<i))return[3,10];s=r[n],c.label=2;case 2:c.trys.push([2,7,8,9]),o=(f=void 0,zt(s)),a=o.next(),c.label=3;case 3:return a.done?[3,6]:(u=a.value,[4,u]);case 4:c.sent(),c.label=5;case 5:return a=o.next(),[3,3];case 6:return[3,9];case 7:return l=c.sent(),f={error:l},[3,9];case 8:try{a&&!a.done&&(h=o.return)&&h.call(o)}finally{if(f)throw f.error}return[7];case 9:return++n,[3,1];case 10:return[2]}})}.bind(this)()},e}(q),Ao=Sh});var ko={};Tu(ko,{Container:()=>Et,ContainerIterator:()=>A,Deque:()=>kr,DequeIterator:()=>ot,HashContainer:()=>q,HashMap:()=>Ao,HashSet:()=>Io,LinkList:()=>So,LinkListIterator:()=>lt,OrderedMap:()=>he,OrderedMapIterator:()=>ce,OrderedSet:()=>Ce,OrderedSetIterator:()=>fe,PriorityQueue:()=>yo,Queue:()=>po,SequentialContainer:()=>Ue,Stack:()=>fo,TreeContainer:()=>xt,Vector:()=>M,VectorIterator:()=>at});var Lo=U(()=>{"use strict";co();go();_o();Mr();Eo();Ki();$i();Gi();Ro();Bo();Y();Ht();qr();jr()});var qo=g((M_,Mo)=>{"use strict";var Tt=1e3,Ct=Tt*60,Pt=Ct*60,ut=Pt*24,Eh=ut*7,xh=ut*365.25;Mo.exports=function(t,e){e=e||{};var r=typeof t;if(r==="string"&&t.length>0)return Th(t);if(r==="number"&&isFinite(t))return e.long?Ph(t):Ch(t);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(t))};function Th(t){if(t=String(t),!(t.length>100)){var e=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(t);if(e){var r=parseFloat(e[1]),i=(e[2]||"ms").toLowerCase();switch(i){case"years":case"year":case"yrs":case"yr":case"y":return r*xh;case"weeks":case"week":case"w":return r*Eh;case"days":case"day":case"d":return r*ut;case"hours":case"hour":case"hrs":case"hr":case"h":return r*Pt;case"minutes":case"minute":case"mins":case"min":case"m":return r*Ct;case"seconds":case"second":case"secs":case"sec":case"s":return r*Tt;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return r;default:return}}}}function Ch(t){var e=Math.abs(t);return e>=ut?Math.round(t/ut)+"d":e>=Pt?Math.round(t/Pt)+"h":e>=Ct?Math.round(t/Ct)+"m":e>=Tt?Math.round(t/Tt)+"s":t+"ms"}function Ph(t){var e=Math.abs(t);return e>=ut?Fr(t,e,ut,"day"):e>=Pt?Fr(t,e,Pt,"hour"):e>=Ct?Fr(t,e,Ct,"minute"):e>=Tt?Fr(t,e,Tt,"second"):t+" ms"}function Fr(t,e,r,i){var n=e>=r*1.5;return Math.round(t/r)+" "+i+(n?"s":"")}});var Qi=g((q_,No)=>{"use strict";function Oh(t){r.debug=r,r.default=r,r.coerce=u,r.disable=o,r.enable=n,r.enabled=a,r.humanize=qo(),r.destroy=l,Object.keys(t).forEach(f=>{r[f]=t[f]}),r.names=[],r.skips=[],r.formatters={};function e(f){let h=0;for(let c=0;c<f.length;c++)h=(h<<5)-h+f.charCodeAt(c),h|=0;return r.colors[Math.abs(h)%r.colors.length]}r.selectColor=e;function r(f){let h,c=null,d,m;function y(...v){if(!y.enabled)return;let b=y,C=Number(new Date),D=C-(h||C);b.diff=D,b.prev=h,b.curr=C,h=C,v[0]=r.coerce(v[0]),typeof v[0]!="string"&&v.unshift("%O");let K=0;v[0]=v[0].replace(/%([a-zA-Z%])/g,(Xe,Bt)=>{if(Xe==="%%")return"%";K++;let hr=r.formatters[Bt];if(typeof hr=="function"){let vu=v[K];Xe=hr.call(b,vu),v.splice(K,1),K--}return Xe}),r.formatArgs.call(b,v),(b.log||r.log).apply(b,v)}return y.namespace=f,y.useColors=r.useColors(),y.color=r.selectColor(f),y.extend=i,y.destroy=r.destroy,Object.defineProperty(y,"enabled",{enumerable:!0,configurable:!1,get:()=>c!==null?c:(d!==r.namespaces&&(d=r.namespaces,m=r.enabled(f)),m),set:v=>{c=v}}),typeof r.init=="function"&&r.init(y),y}function i(f,h){let c=r(this.namespace+(typeof h>"u"?":":h)+f);return c.log=this.log,c}function n(f){r.save(f),r.namespaces=f,r.names=[],r.skips=[];let h=(typeof f=="string"?f:"").trim().replace(" ",",").split(",").filter(Boolean);for(let c of h)c[0]==="-"?r.skips.push(c.slice(1)):r.names.push(c)}function s(f,h){let c=0,d=0,m=-1,y=0;for(;c<f.length;)if(d<h.length&&(h[d]===f[c]||h[d]==="*"))h[d]==="*"?(m=d,y=c,d++):(c++,d++);else if(m!==-1)d=m+1,y++,c=y;else return!1;for(;d<h.length&&h[d]==="*";)d++;return d===h.length}function o(){let f=[...r.names,...r.skips.map(h=>"-"+h)].join(",");return r.enable(""),f}function a(f){for(let h of r.skips)if(s(f,h))return!1;for(let h of r.names)if(s(f,h))return!0;return!1}function u(f){return f instanceof Error?f.stack||f.message:f}function l(){console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")}return r.enable(r.load()),r}No.exports=Oh});var Do=g((te,Wr)=>{"use strict";te.formatArgs=Rh;te.save=Ah;te.load=Bh;te.useColors=Ih;te.storage=kh();te.destroy=(()=>{let t=!1;return()=>{t||(t=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."))}})();te.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"];function Ih(){if(typeof window<"u"&&window.process&&(window.process.type==="renderer"||window.process.__nwjs))return!0;if(typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))return!1;let t;return typeof document<"u"&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||typeof window<"u"&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||typeof navigator<"u"&&navigator.userAgent&&(t=navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/))&&parseInt(t[1],10)>=31||typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)}function Rh(t){if(t[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+t[0]+(this.useColors?"%c ":" ")+"+"+Wr.exports.humanize(this.diff),!this.useColors)return;let e="color: "+this.color;t.splice(1,0,e,"color: inherit");let r=0,i=0;t[0].replace(/%[a-zA-Z%]/g,n=>{n!=="%%"&&(r++,n==="%c"&&(i=r))}),t.splice(i,0,e)}te.log=console.debug||console.log||(()=>{});function Ah(t){try{t?te.storage.setItem("debug",t):te.storage.removeItem("debug")}catch{}}function Bh(){let t;try{t=te.storage.getItem("debug")}catch{}return!t&&typeof process<"u"&&"env"in process&&(t=process.env.DEBUG),t}function kh(){try{return localStorage}catch{}}Wr.exports=Qi()(te);var{formatters:Lh}=Wr.exports;Lh.j=function(t){try{return JSON.stringify(t)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}});var jo=g((N_,Uo)=>{"use strict";Uo.exports=(t,e=process.argv)=>{let r=t.startsWith("-")?"":t.length===1?"-":"--",i=e.indexOf(r+t),n=e.indexOf("--");return i!==-1&&(n===-1||i<n)}});var Vo=g((D_,Wo)=>{"use strict";var Mh=require("os"),Fo=require("tty"),oe=jo(),{env:V}=process,Fe;oe("no-color")||oe("no-colors")||oe("color=false")||oe("color=never")?Fe=0:(oe("color")||oe("colors")||oe("color=true")||oe("color=always"))&&(Fe=1);"FORCE_COLOR"in V&&(V.FORCE_COLOR==="true"?Fe=1:V.FORCE_COLOR==="false"?Fe=0:Fe=V.FORCE_COLOR.length===0?1:Math.min(parseInt(V.FORCE_COLOR,10),3));function Yi(t){return t===0?!1:{level:t,hasBasic:!0,has256:t>=2,has16m:t>=3}}function Xi(t,e){if(Fe===0)return 0;if(oe("color=16m")||oe("color=full")||oe("color=truecolor"))return 3;if(oe("color=256"))return 2;if(t&&!e&&Fe===void 0)return 0;let r=Fe||0;if(V.TERM==="dumb")return r;if(process.platform==="win32"){let i=Mh.release().split(".");return Number(i[0])>=10&&Number(i[2])>=10586?Number(i[2])>=14931?3:2:1}if("CI"in V)return["TRAVIS","CIRCLECI","APPVEYOR","GITLAB_CI","GITHUB_ACTIONS","BUILDKITE"].some(i=>i in V)||V.CI_NAME==="codeship"?1:r;if("TEAMCITY_VERSION"in V)return/^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(V.TEAMCITY_VERSION)?1:0;if(V.COLORTERM==="truecolor")return 3;if("TERM_PROGRAM"in V){let i=parseInt((V.TERM_PROGRAM_VERSION||"").split(".")[0],10);switch(V.TERM_PROGRAM){case"iTerm.app":return i>=3?3:2;case"Apple_Terminal":return 2}}return/-256(color)?$/i.test(V.TERM)?2:/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(V.TERM)||"COLORTERM"in V?1:r}function qh(t){let e=Xi(t,t&&t.isTTY);return Yi(e)}Wo.exports={supportsColor:qh,stdout:Yi(Xi(!0,Fo.isatty(1))),stderr:Yi(Xi(!0,Fo.isatty(2)))}});var Ko=g((H,Hr)=>{"use strict";var Nh=require("tty"),Vr=require("util");H.init=Hh;H.log=Fh;H.formatArgs=Uh;H.save=Wh;H.load=Vh;H.useColors=Dh;H.destroy=Vr.deprecate(()=>{},"Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.");H.colors=[6,2,3,4,5,1];try{let t=Vo();t&&(t.stderr||t).level>=2&&(H.colors=[20,21,26,27,32,33,38,39,40,41,42,43,44,45,56,57,62,63,68,69,74,75,76,77,78,79,80,81,92,93,98,99,112,113,128,129,134,135,148,149,160,161,162,163,164,165,166,167,168,169,170,171,172,173,178,179,184,185,196,197,198,199,200,201,202,203,204,205,206,207,208,209,214,215,220,221])}catch{}H.inspectOpts=Object.keys(process.env).filter(t=>/^debug_/i.test(t)).reduce((t,e)=>{let r=e.substring(6).toLowerCase().replace(/_([a-z])/g,(n,s)=>s.toUpperCase()),i=process.env[e];return/^(yes|on|true|enabled)$/i.test(i)?i=!0:/^(no|off|false|disabled)$/i.test(i)?i=!1:i==="null"?i=null:i=Number(i),t[r]=i,t},{});function Dh(){return"colors"in H.inspectOpts?!!H.inspectOpts.colors:Nh.isatty(process.stderr.fd)}function Uh(t){let{namespace:e,useColors:r}=this;if(r){let i=this.color,n="\x1B[3"+(i<8?i:"8;5;"+i),s=` ${n};1m${e} \x1B[0m`;t[0]=s+t[0].split(`
|
|
2
|
+
"use strict";var bu=Object.create;var dr=Object.defineProperty;var wu=Object.getOwnPropertyDescriptor;var Su=Object.getOwnPropertyNames;var Eu=Object.getPrototypeOf,xu=Object.prototype.hasOwnProperty;var U=(t,e)=>()=>(t&&(e=t(t=0)),e);var g=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),Tu=(t,e)=>{for(var r in e)dr(t,r,{get:e[r],enumerable:!0})},Gn=(t,e,r,i)=>{if(e&&typeof e=="object"||typeof e=="function")for(let n of Su(e))!xu.call(t,n)&&n!==r&&dr(t,n,{get:()=>e[n],enumerable:!(i=wu(e,n))||i.enumerable});return t};var ui=(t,e,r)=>(r=t!=null?bu(Eu(t)):{},Gn(e||!t||!t.__esModule?dr(r,"default",{value:t,enumerable:!0}):r,t)),Cu=t=>Gn(dr({},"__esModule",{value:!0}),t);var pr=g((Qg,Qn)=>{"use strict";Qn.exports=Ou;var Pu=Object.prototype.hasOwnProperty;function Ou(){for(var t={},e=0;e<arguments.length;e++){var r=arguments[e];for(var i in r)Pu.call(r,i)&&(t[i]=r[i])}return t}});var fi=g((Yg,Yn)=>{"use strict";Yn.exports=require("stream")});var es=g((Xg,Zn)=>{"use strict";function Xn(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter(function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable})),r.push.apply(r,i)}return r}function Iu(t){for(var e=1;e<arguments.length;e++){var r=arguments[e]!=null?arguments[e]:{};e%2?Xn(Object(r),!0).forEach(function(i){Ru(t,i,r[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):Xn(Object(r)).forEach(function(i){Object.defineProperty(t,i,Object.getOwnPropertyDescriptor(r,i))})}return t}function Ru(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function Au(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function Jn(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}function Bu(t,e,r){return e&&Jn(t.prototype,e),r&&Jn(t,r),t}var ku=require("buffer"),gr=ku.Buffer,Lu=require("util"),ci=Lu.inspect,Mu=ci&&ci.custom||"inspect";function qu(t,e,r){gr.prototype.copy.call(t,e,r)}Zn.exports=(function(){function t(){Au(this,t),this.head=null,this.tail=null,this.length=0}return Bu(t,[{key:"push",value:function(r){var i={data:r,next:null};this.length>0?this.tail.next=i:this.head=i,this.tail=i,++this.length}},{key:"unshift",value:function(r){var i={data:r,next:this.head};this.length===0&&(this.tail=i),this.head=i,++this.length}},{key:"shift",value: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}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(r){if(this.length===0)return"";for(var i=this.head,n=""+i.data;i=i.next;)n+=r+i.data;return n}},{key:"concat",value:function(r){if(this.length===0)return gr.alloc(0);for(var i=gr.allocUnsafe(r>>>0),n=this.head,s=0;n;)qu(n.data,i,s),s+=n.data.length,n=n.next;return i}},{key:"consume",value:function(r,i){var n;return r<this.head.data.length?(n=this.head.data.slice(0,r),this.head.data=this.head.data.slice(r)):r===this.head.data.length?n=this.shift():n=i?this._getString(r):this._getBuffer(r),n}},{key:"first",value:function(){return this.head.data}},{key:"_getString",value:function(r){var i=this.head,n=1,s=i.data;for(r-=s.length;i=i.next;){var o=i.data,a=r>o.length?o.length:r;if(a===o.length?s+=o:s+=o.slice(0,r),r-=a,r===0){a===o.length?(++n,i.next?this.head=i.next:this.head=this.tail=null):(this.head=i,i.data=o.slice(a));break}++n}return this.length-=n,s}},{key:"_getBuffer",value:function(r){var i=gr.allocUnsafe(r),n=this.head,s=1;for(n.data.copy(i),r-=n.data.length;n=n.next;){var o=n.data,a=r>o.length?o.length:r;if(o.copy(i,i.length-r,0,a),r-=a,r===0){a===o.length?(++s,n.next?this.head=n.next:this.head=this.tail=null):(this.head=n,n.data=o.slice(a));break}++s}return this.length-=s,i}},{key:Mu,value:function(r,i){return ci(this,Iu({},i,{depth:0,customInspect:!1}))}}]),t})()});var di=g((Jg,rs)=>{"use strict";function Nu(t,e){var r=this,i=this._readableState&&this._readableState.destroyed,n=this._writableState&&this._writableState.destroyed;return i||n?(e?e(t):t&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,process.nextTick(hi,this,t)):process.nextTick(hi,this,t)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(t||null,function(s){!e&&s?r._writableState?r._writableState.errorEmitted?process.nextTick(yr,r):(r._writableState.errorEmitted=!0,process.nextTick(ts,r,s)):process.nextTick(ts,r,s):e?(process.nextTick(yr,r),e(s)):process.nextTick(yr,r)}),this)}function ts(t,e){hi(t,e),yr(t)}function yr(t){t._writableState&&!t._writableState.emitClose||t._readableState&&!t._readableState.emitClose||t.emit("close")}function Du(){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)}function hi(t,e){t.emit("error",e)}function Uu(t,e){var r=t._readableState,i=t._writableState;r&&r.autoDestroy||i&&i.autoDestroy?t.destroy(e):t.emit("error",e)}rs.exports={destroy:Nu,undestroy:Du,errorOrDestroy:Uu}});var Be=g((Zg,ss)=>{"use strict";var ns={};function ne(t,e,r){r||(r=Error);function i(s,o,a){return typeof e=="string"?e:e(s,o,a)}class n extends r{constructor(o,a,u){super(i(o,a,u))}}n.prototype.name=r.name,n.prototype.code=t,ns[t]=n}function is(t,e){if(Array.isArray(t)){let r=t.length;return t=t.map(i=>String(i)),r>2?`one of ${e} ${t.slice(0,r-1).join(", ")}, or `+t[r-1]:r===2?`one of ${e} ${t[0]} or ${t[1]}`:`of ${e} ${t[0]}`}else return`of ${e} ${String(t)}`}function ju(t,e,r){return t.substr(!r||r<0?0:+r,e.length)===e}function Fu(t,e,r){return(r===void 0||r>t.length)&&(r=t.length),t.substring(r-e.length,r)===e}function Wu(t,e,r){return typeof r!="number"&&(r=0),r+e.length>t.length?!1:t.indexOf(e,r)!==-1}ne("ERR_INVALID_OPT_VALUE",function(t,e){return'The value "'+e+'" is invalid for option "'+t+'"'},TypeError);ne("ERR_INVALID_ARG_TYPE",function(t,e,r){let i;typeof e=="string"&&ju(e,"not ")?(i="must not be",e=e.replace(/^not /,"")):i="must be";let n;if(Fu(t," argument"))n=`The ${t} ${i} ${is(e,"type")}`;else{let s=Wu(t,".")?"property":"argument";n=`The "${t}" ${s} ${i} ${is(e,"type")}`}return n+=`. Received type ${typeof r}`,n},TypeError);ne("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF");ne("ERR_METHOD_NOT_IMPLEMENTED",function(t){return"The "+t+" method is not implemented"});ne("ERR_STREAM_PREMATURE_CLOSE","Premature close");ne("ERR_STREAM_DESTROYED",function(t){return"Cannot call "+t+" after a stream was destroyed"});ne("ERR_MULTIPLE_CALLBACK","Callback called multiple times");ne("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable");ne("ERR_STREAM_WRITE_AFTER_END","write after end");ne("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError);ne("ERR_UNKNOWN_ENCODING",function(t){return"Unknown encoding: "+t},TypeError);ne("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event");ss.exports.codes=ns});var pi=g((ey,os)=>{"use strict";var Vu=Be().codes.ERR_INVALID_OPT_VALUE;function Hu(t,e,r){return t.highWaterMark!=null?t.highWaterMark:e?t[r]:null}function Ku(t,e,r,i){var n=Hu(e,i,r);if(n!=null){if(!(isFinite(n)&&Math.floor(n)===n)||n<0){var s=i?r:"highWaterMark";throw new Vu(s,n)}return Math.floor(n)}return t.objectMode?16:16*1024}os.exports={getHighWaterMark:Ku}});var as=g((ty,gi)=>{"use strict";typeof Object.create=="function"?gi.exports=function(e,r){r&&(e.super_=r,e.prototype=Object.create(r.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:gi.exports=function(e,r){if(r){e.super_=r;var i=function(){};i.prototype=r.prototype,e.prototype=new i,e.prototype.constructor=e}}});var we=g((ry,_i)=>{"use strict";try{if(yi=require("util"),typeof yi.inherits!="function")throw"";_i.exports=yi.inherits}catch{_i.exports=as()}var yi});var us=g((iy,ls)=>{"use strict";ls.exports=require("util").deprecate});var bi=g((ny,gs)=>{"use strict";gs.exports=L;function cs(t){var e=this;this.next=null,this.entry=null,this.finish=function(){vf(e,t)}}var yt;L.WritableState=Lt;var zu={deprecate:us()},hs=fi(),mr=require("buffer").Buffer,$u=global.Uint8Array||function(){};function Gu(t){return mr.from(t)}function Qu(t){return mr.isBuffer(t)||t instanceof $u}var vi=di(),Yu=pi(),Xu=Yu.getHighWaterMark,ke=Be().codes,Ju=ke.ERR_INVALID_ARG_TYPE,Zu=ke.ERR_METHOD_NOT_IMPLEMENTED,ef=ke.ERR_MULTIPLE_CALLBACK,tf=ke.ERR_STREAM_CANNOT_PIPE,rf=ke.ERR_STREAM_DESTROYED,nf=ke.ERR_STREAM_NULL_VALUES,sf=ke.ERR_STREAM_WRITE_AFTER_END,of=ke.ERR_UNKNOWN_ENCODING,_t=vi.errorOrDestroy;we()(L,hs);function af(){}function Lt(t,e,r){yt=yt||Je(),t=t||{},typeof r!="boolean"&&(r=e instanceof yt),this.objectMode=!!t.objectMode,r&&(this.objectMode=this.objectMode||!!t.writableObjectMode),this.highWaterMark=Xu(this,t,"writableHighWaterMark",r),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var i=t.decodeStrings===!1;this.decodeStrings=!i,this.defaultEncoding=t.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(n){pf(e,n)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=t.emitClose!==!1,this.autoDestroy=!!t.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new cs(this)}Lt.prototype.getBuffer=function(){for(var e=this.bufferedRequest,r=[];e;)r.push(e),e=e.next;return r};(function(){try{Object.defineProperty(Lt.prototype,"buffer",{get:zu.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch{}})();var _r;typeof Symbol=="function"&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]=="function"?(_r=Function.prototype[Symbol.hasInstance],Object.defineProperty(L,Symbol.hasInstance,{value:function(e){return _r.call(this,e)?!0:this!==L?!1:e&&e._writableState instanceof Lt}})):_r=function(e){return e instanceof this};function L(t){yt=yt||Je();var e=this instanceof yt;if(!e&&!_r.call(L,this))return new L(t);this._writableState=new Lt(t,this,e),this.writable=!0,t&&(typeof t.write=="function"&&(this._write=t.write),typeof t.writev=="function"&&(this._writev=t.writev),typeof t.destroy=="function"&&(this._destroy=t.destroy),typeof t.final=="function"&&(this._final=t.final)),hs.call(this)}L.prototype.pipe=function(){_t(this,new tf)};function lf(t,e){var r=new sf;_t(t,r),process.nextTick(e,r)}function uf(t,e,r,i){var n;return r===null?n=new nf:typeof r!="string"&&!e.objectMode&&(n=new Ju("chunk",["string","Buffer"],r)),n?(_t(t,n),process.nextTick(i,n),!1):!0}L.prototype.write=function(t,e,r){var i=this._writableState,n=!1,s=!i.objectMode&&Qu(t);return s&&!mr.isBuffer(t)&&(t=Gu(t)),typeof e=="function"&&(r=e,e=null),s?e="buffer":e||(e=i.defaultEncoding),typeof r!="function"&&(r=af),i.ending?lf(this,r):(s||uf(this,i,t,r))&&(i.pendingcb++,n=cf(this,i,s,t,e,r)),n};L.prototype.cork=function(){this._writableState.corked++};L.prototype.uncork=function(){var t=this._writableState;t.corked&&(t.corked--,!t.writing&&!t.corked&&!t.bufferProcessing&&t.bufferedRequest&&ds(this,t))};L.prototype.setDefaultEncoding=function(e){if(typeof e=="string"&&(e=e.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((e+"").toLowerCase())>-1))throw new of(e);return this._writableState.defaultEncoding=e,this};Object.defineProperty(L.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}});function ff(t,e,r){return!t.objectMode&&t.decodeStrings!==!1&&typeof e=="string"&&(e=mr.from(e,r)),e}Object.defineProperty(L.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});function cf(t,e,r,i,n,s){if(!r){var o=ff(e,i,n);i!==o&&(r=!0,n="buffer",i=o)}var a=e.objectMode?1:i.length;e.length+=a;var u=e.length<e.highWaterMark;if(u||(e.needDrain=!0),e.writing||e.corked){var l=e.lastBufferedRequest;e.lastBufferedRequest={chunk:i,encoding:n,isBuf:r,callback:s,next:null},l?l.next=e.lastBufferedRequest:e.bufferedRequest=e.lastBufferedRequest,e.bufferedRequestCount+=1}else mi(t,e,!1,a,i,n,s);return u}function mi(t,e,r,i,n,s,o){e.writelen=i,e.writecb=o,e.writing=!0,e.sync=!0,e.destroyed?e.onwrite(new rf("write")):r?t._writev(n,e.onwrite):t._write(n,s,e.onwrite),e.sync=!1}function hf(t,e,r,i,n){--e.pendingcb,r?(process.nextTick(n,i),process.nextTick(kt,t,e),t._writableState.errorEmitted=!0,_t(t,i)):(n(i),t._writableState.errorEmitted=!0,_t(t,i),kt(t,e))}function df(t){t.writing=!1,t.writecb=null,t.length-=t.writelen,t.writelen=0}function pf(t,e){var r=t._writableState,i=r.sync,n=r.writecb;if(typeof n!="function")throw new ef;if(df(r),e)hf(t,r,i,e,n);else{var s=ps(r)||t.destroyed;!s&&!r.corked&&!r.bufferProcessing&&r.bufferedRequest&&ds(t,r),i?process.nextTick(fs,t,r,s,n):fs(t,r,s,n)}}function fs(t,e,r,i){r||gf(t,e),e.pendingcb--,i(),kt(t,e)}function gf(t,e){e.length===0&&e.needDrain&&(e.needDrain=!1,t.emit("drain"))}function ds(t,e){e.bufferProcessing=!0;var r=e.bufferedRequest;if(t._writev&&r&&r.next){var i=e.bufferedRequestCount,n=new Array(i),s=e.corkedRequestsFree;s.entry=r;for(var o=0,a=!0;r;)n[o]=r,r.isBuf||(a=!1),r=r.next,o+=1;n.allBuffers=a,mi(t,e,!0,e.length,n,"",s.finish),e.pendingcb++,e.lastBufferedRequest=null,s.next?(e.corkedRequestsFree=s.next,s.next=null):e.corkedRequestsFree=new cs(e),e.bufferedRequestCount=0}else{for(;r;){var u=r.chunk,l=r.encoding,f=r.callback,h=e.objectMode?1:u.length;if(mi(t,e,!1,h,u,l,f),r=r.next,e.bufferedRequestCount--,e.writing)break}r===null&&(e.lastBufferedRequest=null)}e.bufferedRequest=r,e.bufferProcessing=!1}L.prototype._write=function(t,e,r){r(new Zu("_write()"))};L.prototype._writev=null;L.prototype.end=function(t,e,r){var i=this._writableState;return typeof t=="function"?(r=t,t=null,e=null):typeof e=="function"&&(r=e,e=null),t!=null&&this.write(t,e),i.corked&&(i.corked=1,this.uncork()),i.ending||mf(this,i,r),this};Object.defineProperty(L.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}});function ps(t){return t.ending&&t.length===0&&t.bufferedRequest===null&&!t.finished&&!t.writing}function yf(t,e){t._final(function(r){e.pendingcb--,r&&_t(t,r),e.prefinished=!0,t.emit("prefinish"),kt(t,e)})}function _f(t,e){!e.prefinished&&!e.finalCalled&&(typeof t._final=="function"&&!e.destroyed?(e.pendingcb++,e.finalCalled=!0,process.nextTick(yf,t,e)):(e.prefinished=!0,t.emit("prefinish")))}function kt(t,e){var r=ps(e);if(r&&(_f(t,e),e.pendingcb===0&&(e.finished=!0,t.emit("finish"),e.autoDestroy))){var i=t._readableState;(!i||i.autoDestroy&&i.endEmitted)&&t.destroy()}return r}function mf(t,e,r){e.ending=!0,kt(t,e),r&&(e.finished?process.nextTick(r):t.once("finish",r)),e.ended=!0,t.writable=!1}function vf(t,e,r){var i=t.entry;for(t.entry=null;i;){var n=i.callback;e.pendingcb--,n(r),i=i.next}e.corkedRequestsFree.next=t}Object.defineProperty(L.prototype,"destroyed",{enumerable:!1,get:function(){return this._writableState===void 0?!1:this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}});L.prototype.destroy=vi.destroy;L.prototype._undestroy=vi.undestroy;L.prototype._destroy=function(t,e){e(t)}});var Je=g((sy,_s)=>{"use strict";var bf=Object.keys||function(t){var e=[];for(var r in t)e.push(r);return e};_s.exports=ge;var ys=Ei(),Si=bi();we()(ge,ys);for(wi=bf(Si.prototype),vr=0;vr<wi.length;vr++)br=wi[vr],ge.prototype[br]||(ge.prototype[br]=Si.prototype[br]);var wi,br,vr;function ge(t){if(!(this instanceof ge))return new ge(t);ys.call(this,t),Si.call(this,t),this.allowHalfOpen=!0,t&&(t.readable===!1&&(this.readable=!1),t.writable===!1&&(this.writable=!1),t.allowHalfOpen===!1&&(this.allowHalfOpen=!1,this.once("end",wf)))}Object.defineProperty(ge.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});Object.defineProperty(ge.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}});Object.defineProperty(ge.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}});function wf(){this._writableState.ended||process.nextTick(Sf,this)}function Sf(t){t.end()}Object.defineProperty(ge.prototype,"destroyed",{enumerable:!1,get:function(){return this._readableState===void 0||this._writableState===void 0?!1:this._readableState.destroyed&&this._writableState.destroyed},set:function(e){this._readableState===void 0||this._writableState===void 0||(this._readableState.destroyed=e,this._writableState.destroyed=e)}})});var bs=g((xi,vs)=>{"use strict";var wr=require("buffer"),ye=wr.Buffer;function ms(t,e){for(var r in t)e[r]=t[r]}ye.from&&ye.alloc&&ye.allocUnsafe&&ye.allocUnsafeSlow?vs.exports=wr:(ms(wr,xi),xi.Buffer=Ze);function Ze(t,e,r){return ye(t,e,r)}Ze.prototype=Object.create(ye.prototype);ms(ye,Ze);Ze.from=function(t,e,r){if(typeof t=="number")throw new TypeError("Argument must not be a number");return ye(t,e,r)};Ze.alloc=function(t,e,r){if(typeof t!="number")throw new TypeError("Argument must be a number");var i=ye(t);return e!==void 0?typeof r=="string"?i.fill(e,r):i.fill(e):i.fill(0),i};Ze.allocUnsafe=function(t){if(typeof t!="number")throw new TypeError("Argument must be a number");return ye(t)};Ze.allocUnsafeSlow=function(t){if(typeof t!="number")throw new TypeError("Argument must be a number");return wr.SlowBuffer(t)}});var Pi=g(Ss=>{"use strict";var Ci=bs().Buffer,ws=Ci.isEncoding||function(t){switch(t=""+t,t&&t.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 Ef(t){if(!t)return"utf8";for(var e;;)switch(t){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 t;default:if(e)return;t=(""+t).toLowerCase(),e=!0}}function xf(t){var e=Ef(t);if(typeof e!="string"&&(Ci.isEncoding===ws||!ws(t)))throw new Error("Unknown encoding: "+t);return e||t}Ss.StringDecoder=Mt;function Mt(t){this.encoding=xf(t);var e;switch(this.encoding){case"utf16le":this.text=Rf,this.end=Af,e=4;break;case"utf8":this.fillLast=Pf,e=4;break;case"base64":this.text=Bf,this.end=kf,e=3;break;default:this.write=Lf,this.end=Mf;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=Ci.allocUnsafe(e)}Mt.prototype.write=function(t){if(t.length===0)return"";var e,r;if(this.lastNeed){if(e=this.fillLast(t),e===void 0)return"";r=this.lastNeed,this.lastNeed=0}else r=0;return r<t.length?e?e+this.text(t,r):this.text(t,r):e||""};Mt.prototype.end=If;Mt.prototype.text=Of;Mt.prototype.fillLast=function(t){if(this.lastNeed<=t.length)return t.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);t.copy(this.lastChar,this.lastTotal-this.lastNeed,0,t.length),this.lastNeed-=t.length};function Ti(t){return t<=127?0:t>>5===6?2:t>>4===14?3:t>>3===30?4:t>>6===2?-1:-2}function Tf(t,e,r){var i=e.length-1;if(i<r)return 0;var n=Ti(e[i]);return n>=0?(n>0&&(t.lastNeed=n-1),n):--i<r||n===-2?0:(n=Ti(e[i]),n>=0?(n>0&&(t.lastNeed=n-2),n):--i<r||n===-2?0:(n=Ti(e[i]),n>=0?(n>0&&(n===2?n=0:t.lastNeed=n-3),n):0))}function Cf(t,e,r){if((e[0]&192)!==128)return t.lastNeed=0,"\uFFFD";if(t.lastNeed>1&&e.length>1){if((e[1]&192)!==128)return t.lastNeed=1,"\uFFFD";if(t.lastNeed>2&&e.length>2&&(e[2]&192)!==128)return t.lastNeed=2,"\uFFFD"}}function Pf(t){var e=this.lastTotal-this.lastNeed,r=Cf(this,t,e);if(r!==void 0)return r;if(this.lastNeed<=t.length)return t.copy(this.lastChar,e,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);t.copy(this.lastChar,e,0,t.length),this.lastNeed-=t.length}function Of(t,e){var r=Tf(this,t,e);if(!this.lastNeed)return t.toString("utf8",e);this.lastTotal=r;var i=t.length-(r-this.lastNeed);return t.copy(this.lastChar,0,i),t.toString("utf8",e,i)}function If(t){var e=t&&t.length?this.write(t):"";return this.lastNeed?e+"\uFFFD":e}function Rf(t,e){if((t.length-e)%2===0){var r=t.toString("utf16le",e);if(r){var i=r.charCodeAt(r.length-1);if(i>=55296&&i<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=t[t.length-2],this.lastChar[1]=t[t.length-1],r.slice(0,-1)}return r}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=t[t.length-1],t.toString("utf16le",e,t.length-1)}function Af(t){var e=t&&t.length?this.write(t):"";if(this.lastNeed){var r=this.lastTotal-this.lastNeed;return e+this.lastChar.toString("utf16le",0,r)}return e}function Bf(t,e){var r=(t.length-e)%3;return r===0?t.toString("base64",e):(this.lastNeed=3-r,this.lastTotal=3,r===1?this.lastChar[0]=t[t.length-1]:(this.lastChar[0]=t[t.length-2],this.lastChar[1]=t[t.length-1]),t.toString("base64",e,t.length-r))}function kf(t){var e=t&&t.length?this.write(t):"";return this.lastNeed?e+this.lastChar.toString("base64",0,3-this.lastNeed):e}function Lf(t){return t.toString(this.encoding)}function Mf(t){return t&&t.length?this.write(t):""}});var Sr=g((ay,Ts)=>{"use strict";var Es=Be().codes.ERR_STREAM_PREMATURE_CLOSE;function qf(t){var e=!1;return function(){if(!e){e=!0;for(var r=arguments.length,i=new Array(r),n=0;n<r;n++)i[n]=arguments[n];t.apply(this,i)}}}function Nf(){}function Df(t){return t.setHeader&&typeof t.abort=="function"}function xs(t,e,r){if(typeof e=="function")return xs(t,null,e);e||(e={}),r=qf(r||Nf);var i=e.readable||e.readable!==!1&&t.readable,n=e.writable||e.writable!==!1&&t.writable,s=function(){t.writable||a()},o=t._writableState&&t._writableState.finished,a=function(){n=!1,o=!0,i||r.call(t)},u=t._readableState&&t._readableState.endEmitted,l=function(){i=!1,u=!0,n||r.call(t)},f=function(m){r.call(t,m)},h=function(){var m;if(i&&!u)return(!t._readableState||!t._readableState.ended)&&(m=new Es),r.call(t,m);if(n&&!o)return(!t._writableState||!t._writableState.ended)&&(m=new Es),r.call(t,m)},c=function(){t.req.on("finish",a)};return Df(t)?(t.on("complete",a),t.on("abort",h),t.req?c():t.on("request",c)):n&&!t._writableState&&(t.on("end",s),t.on("close",s)),t.on("end",l),t.on("finish",a),e.error!==!1&&t.on("error",f),t.on("close",h),function(){t.removeListener("complete",a),t.removeListener("abort",h),t.removeListener("request",c),t.req&&t.req.removeListener("finish",a),t.removeListener("end",s),t.removeListener("close",s),t.removeListener("finish",a),t.removeListener("end",l),t.removeListener("error",f),t.removeListener("close",h)}}Ts.exports=xs});var Ps=g((ly,Cs)=>{"use strict";var Er;function Le(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var Uf=Sr(),Me=Symbol("lastResolve"),et=Symbol("lastReject"),qt=Symbol("error"),xr=Symbol("ended"),tt=Symbol("lastPromise"),Oi=Symbol("handlePromise"),rt=Symbol("stream");function qe(t,e){return{value:t,done:e}}function jf(t){var e=t[Me];if(e!==null){var r=t[rt].read();r!==null&&(t[tt]=null,t[Me]=null,t[et]=null,e(qe(r,!1)))}}function Ff(t){process.nextTick(jf,t)}function Wf(t,e){return function(r,i){t.then(function(){if(e[xr]){r(qe(void 0,!0));return}e[Oi](r,i)},i)}}var Vf=Object.getPrototypeOf(function(){}),Hf=Object.setPrototypeOf((Er={get stream(){return this[rt]},next:function(){var e=this,r=this[qt];if(r!==null)return Promise.reject(r);if(this[xr])return Promise.resolve(qe(void 0,!0));if(this[rt].destroyed)return new Promise(function(o,a){process.nextTick(function(){e[qt]?a(e[qt]):o(qe(void 0,!0))})});var i=this[tt],n;if(i)n=new Promise(Wf(i,this));else{var s=this[rt].read();if(s!==null)return Promise.resolve(qe(s,!1));n=new Promise(this[Oi])}return this[tt]=n,n}},Le(Er,Symbol.asyncIterator,function(){return this}),Le(Er,"return",function(){var e=this;return new Promise(function(r,i){e[rt].destroy(null,function(n){if(n){i(n);return}r(qe(void 0,!0))})})}),Er),Vf),Kf=function(e){var r,i=Object.create(Hf,(r={},Le(r,rt,{value:e,writable:!0}),Le(r,Me,{value:null,writable:!0}),Le(r,et,{value:null,writable:!0}),Le(r,qt,{value:null,writable:!0}),Le(r,xr,{value:e._readableState.endEmitted,writable:!0}),Le(r,Oi,{value:function(s,o){var a=i[rt].read();a?(i[tt]=null,i[Me]=null,i[et]=null,s(qe(a,!1))):(i[Me]=s,i[et]=o)},writable:!0}),r));return i[tt]=null,Uf(e,function(n){if(n&&n.code!=="ERR_STREAM_PREMATURE_CLOSE"){var s=i[et];s!==null&&(i[tt]=null,i[Me]=null,i[et]=null,s(n)),i[qt]=n;return}var o=i[Me];o!==null&&(i[tt]=null,i[Me]=null,i[et]=null,o(qe(void 0,!0))),i[xr]=!0}),e.on("readable",Ff.bind(null,i)),i};Cs.exports=Kf});var As=g((uy,Rs)=>{"use strict";function Os(t,e,r,i,n,s,o){try{var a=t[s](o),u=a.value}catch(l){r(l);return}a.done?e(u):Promise.resolve(u).then(i,n)}function zf(t){return function(){var e=this,r=arguments;return new Promise(function(i,n){var s=t.apply(e,r);function o(u){Os(s,i,n,o,a,"next",u)}function a(u){Os(s,i,n,o,a,"throw",u)}o(void 0)})}}function Is(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter(function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable})),r.push.apply(r,i)}return r}function $f(t){for(var e=1;e<arguments.length;e++){var r=arguments[e]!=null?arguments[e]:{};e%2?Is(Object(r),!0).forEach(function(i){Gf(t,i,r[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):Is(Object(r)).forEach(function(i){Object.defineProperty(t,i,Object.getOwnPropertyDescriptor(r,i))})}return t}function Gf(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var Qf=Be().codes.ERR_INVALID_ARG_TYPE;function Yf(t,e,r){var i;if(e&&typeof e.next=="function")i=e;else if(e&&e[Symbol.asyncIterator])i=e[Symbol.asyncIterator]();else if(e&&e[Symbol.iterator])i=e[Symbol.iterator]();else throw new Qf("iterable",["Iterable"],e);var n=new t($f({objectMode:!0},r)),s=!1;n._read=function(){s||(s=!0,o())};function o(){return a.apply(this,arguments)}function a(){return a=zf(function*(){try{var u=yield i.next(),l=u.value,f=u.done;f?n.push(null):n.push(yield l)?o():s=!1}catch(h){n.destroy(h)}}),a.apply(this,arguments)}return n}Rs.exports=Yf});var Ei=g((cy,Fs)=>{"use strict";Fs.exports=P;var mt;P.ReadableState=Ms;var fy=require("events").EventEmitter,Ls=function(e,r){return e.listeners(r).length},Dt=fi(),Tr=require("buffer").Buffer,Xf=global.Uint8Array||function(){};function Jf(t){return Tr.from(t)}function Zf(t){return Tr.isBuffer(t)||t instanceof Xf}var Ii=require("util"),x;Ii&&Ii.debuglog?x=Ii.debuglog("stream"):x=function(){};var ec=es(),qi=di(),tc=pi(),rc=tc.getHighWaterMark,Cr=Be().codes,ic=Cr.ERR_INVALID_ARG_TYPE,nc=Cr.ERR_STREAM_PUSH_AFTER_EOF,sc=Cr.ERR_METHOD_NOT_IMPLEMENTED,oc=Cr.ERR_STREAM_UNSHIFT_AFTER_END_EVENT,vt,Ri,Ai;we()(P,Dt);var Nt=qi.errorOrDestroy,Bi=["error","close","destroy","pause","resume"];function ac(t,e,r){if(typeof t.prependListener=="function")return t.prependListener(e,r);!t._events||!t._events[e]?t.on(e,r):Array.isArray(t._events[e])?t._events[e].unshift(r):t._events[e]=[r,t._events[e]]}function Ms(t,e,r){mt=mt||Je(),t=t||{},typeof r!="boolean"&&(r=e instanceof mt),this.objectMode=!!t.objectMode,r&&(this.objectMode=this.objectMode||!!t.readableObjectMode),this.highWaterMark=rc(this,t,"readableHighWaterMark",r),this.buffer=new ec,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.paused=!0,this.emitClose=t.emitClose!==!1,this.autoDestroy=!!t.autoDestroy,this.destroyed=!1,this.defaultEncoding=t.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,t.encoding&&(vt||(vt=Pi().StringDecoder),this.decoder=new vt(t.encoding),this.encoding=t.encoding)}function P(t){if(mt=mt||Je(),!(this instanceof P))return new P(t);var e=this instanceof mt;this._readableState=new Ms(t,this,e),this.readable=!0,t&&(typeof t.read=="function"&&(this._read=t.read),typeof t.destroy=="function"&&(this._destroy=t.destroy)),Dt.call(this)}Object.defineProperty(P.prototype,"destroyed",{enumerable:!1,get:function(){return this._readableState===void 0?!1:this._readableState.destroyed},set:function(e){this._readableState&&(this._readableState.destroyed=e)}});P.prototype.destroy=qi.destroy;P.prototype._undestroy=qi.undestroy;P.prototype._destroy=function(t,e){e(t)};P.prototype.push=function(t,e){var r=this._readableState,i;return r.objectMode?i=!0:typeof t=="string"&&(e=e||r.defaultEncoding,e!==r.encoding&&(t=Tr.from(t,e),e=""),i=!0),qs(this,t,e,!1,i)};P.prototype.unshift=function(t){return qs(this,t,null,!0,!1)};function qs(t,e,r,i,n){x("readableAddChunk",e);var s=t._readableState;if(e===null)s.reading=!1,fc(t,s);else{var o;if(n||(o=lc(s,e)),o)Nt(t,o);else if(s.objectMode||e&&e.length>0)if(typeof e!="string"&&!s.objectMode&&Object.getPrototypeOf(e)!==Tr.prototype&&(e=Jf(e)),i)s.endEmitted?Nt(t,new oc):ki(t,s,e,!0);else if(s.ended)Nt(t,new nc);else{if(s.destroyed)return!1;s.reading=!1,s.decoder&&!r?(e=s.decoder.write(e),s.objectMode||e.length!==0?ki(t,s,e,!1):Mi(t,s)):ki(t,s,e,!1)}else i||(s.reading=!1,Mi(t,s))}return!s.ended&&(s.length<s.highWaterMark||s.length===0)}function ki(t,e,r,i){e.flowing&&e.length===0&&!e.sync?(e.awaitDrain=0,t.emit("data",r)):(e.length+=e.objectMode?1:r.length,i?e.buffer.unshift(r):e.buffer.push(r),e.needReadable&&Pr(t)),Mi(t,e)}function lc(t,e){var r;return!Zf(e)&&typeof e!="string"&&e!==void 0&&!t.objectMode&&(r=new ic("chunk",["string","Buffer","Uint8Array"],e)),r}P.prototype.isPaused=function(){return this._readableState.flowing===!1};P.prototype.setEncoding=function(t){vt||(vt=Pi().StringDecoder);var e=new vt(t);this._readableState.decoder=e,this._readableState.encoding=this._readableState.decoder.encoding;for(var r=this._readableState.buffer.head,i="";r!==null;)i+=e.write(r.data),r=r.next;return this._readableState.buffer.clear(),i!==""&&this._readableState.buffer.push(i),this._readableState.length=i.length,this};var Bs=1073741824;function uc(t){return t>=Bs?t=Bs:(t--,t|=t>>>1,t|=t>>>2,t|=t>>>4,t|=t>>>8,t|=t>>>16,t++),t}function ks(t,e){return t<=0||e.length===0&&e.ended?0:e.objectMode?1:t!==t?e.flowing&&e.length?e.buffer.head.data.length:e.length:(t>e.highWaterMark&&(e.highWaterMark=uc(t)),t<=e.length?t:e.ended?e.length:(e.needReadable=!0,0))}P.prototype.read=function(t){x("read",t),t=parseInt(t,10);var e=this._readableState,r=t;if(t!==0&&(e.emittedReadable=!1),t===0&&e.needReadable&&((e.highWaterMark!==0?e.length>=e.highWaterMark:e.length>0)||e.ended))return x("read: emitReadable",e.length,e.ended),e.length===0&&e.ended?Li(this):Pr(this),null;if(t=ks(t,e),t===0&&e.ended)return e.length===0&&Li(this),null;var i=e.needReadable;x("need readable",i),(e.length===0||e.length-t<e.highWaterMark)&&(i=!0,x("length less than watermark",i)),e.ended||e.reading?(i=!1,x("reading or ended",i)):i&&(x("do read"),e.reading=!0,e.sync=!0,e.length===0&&(e.needReadable=!0),this._read(e.highWaterMark),e.sync=!1,e.reading||(t=ks(r,e)));var n;return t>0?n=Us(t,e):n=null,n===null?(e.needReadable=e.length<=e.highWaterMark,t=0):(e.length-=t,e.awaitDrain=0),e.length===0&&(e.ended||(e.needReadable=!0),r!==t&&e.ended&&Li(this)),n!==null&&this.emit("data",n),n};function fc(t,e){if(x("onEofChunk"),!e.ended){if(e.decoder){var r=e.decoder.end();r&&r.length&&(e.buffer.push(r),e.length+=e.objectMode?1:r.length)}e.ended=!0,e.sync?Pr(t):(e.needReadable=!1,e.emittedReadable||(e.emittedReadable=!0,Ns(t)))}}function Pr(t){var e=t._readableState;x("emitReadable",e.needReadable,e.emittedReadable),e.needReadable=!1,e.emittedReadable||(x("emitReadable",e.flowing),e.emittedReadable=!0,process.nextTick(Ns,t))}function Ns(t){var e=t._readableState;x("emitReadable_",e.destroyed,e.length,e.ended),!e.destroyed&&(e.length||e.ended)&&(t.emit("readable"),e.emittedReadable=!1),e.needReadable=!e.flowing&&!e.ended&&e.length<=e.highWaterMark,Ni(t)}function Mi(t,e){e.readingMore||(e.readingMore=!0,process.nextTick(cc,t,e))}function cc(t,e){for(;!e.reading&&!e.ended&&(e.length<e.highWaterMark||e.flowing&&e.length===0);){var r=e.length;if(x("maybeReadMore read 0"),t.read(0),r===e.length)break}e.readingMore=!1}P.prototype._read=function(t){Nt(this,new sc("_read()"))};P.prototype.pipe=function(t,e){var r=this,i=this._readableState;switch(i.pipesCount){case 0:i.pipes=t;break;case 1:i.pipes=[i.pipes,t];break;default:i.pipes.push(t);break}i.pipesCount+=1,x("pipe count=%d opts=%j",i.pipesCount,e);var n=(!e||e.end!==!1)&&t!==process.stdout&&t!==process.stderr,s=n?a:y;i.endEmitted?process.nextTick(s):r.once("end",s),t.on("unpipe",o);function o(v,b){x("onunpipe"),v===r&&b&&b.hasUnpiped===!1&&(b.hasUnpiped=!0,f())}function a(){x("onend"),t.end()}var u=hc(r);t.on("drain",u);var l=!1;function f(){x("cleanup"),t.removeListener("close",d),t.removeListener("finish",m),t.removeListener("drain",u),t.removeListener("error",c),t.removeListener("unpipe",o),r.removeListener("end",a),r.removeListener("end",y),r.removeListener("data",h),l=!0,i.awaitDrain&&(!t._writableState||t._writableState.needDrain)&&u()}r.on("data",h);function h(v){x("ondata");var b=t.write(v);x("dest.write",b),b===!1&&((i.pipesCount===1&&i.pipes===t||i.pipesCount>1&&js(i.pipes,t)!==-1)&&!l&&(x("false write response, pause",i.awaitDrain),i.awaitDrain++),r.pause())}function c(v){x("onerror",v),y(),t.removeListener("error",c),Ls(t,"error")===0&&Nt(t,v)}ac(t,"error",c);function d(){t.removeListener("finish",m),y()}t.once("close",d);function m(){x("onfinish"),t.removeListener("close",d),y()}t.once("finish",m);function y(){x("unpipe"),r.unpipe(t)}return t.emit("pipe",r),i.flowing||(x("pipe resume"),r.resume()),t};function hc(t){return function(){var r=t._readableState;x("pipeOnDrain",r.awaitDrain),r.awaitDrain&&r.awaitDrain--,r.awaitDrain===0&&Ls(t,"data")&&(r.flowing=!0,Ni(t))}}P.prototype.unpipe=function(t){var e=this._readableState,r={hasUnpiped:!1};if(e.pipesCount===0)return this;if(e.pipesCount===1)return t&&t!==e.pipes?this:(t||(t=e.pipes),e.pipes=null,e.pipesCount=0,e.flowing=!1,t&&t.emit("unpipe",this,r),this);if(!t){var i=e.pipes,n=e.pipesCount;e.pipes=null,e.pipesCount=0,e.flowing=!1;for(var s=0;s<n;s++)i[s].emit("unpipe",this,{hasUnpiped:!1});return this}var o=js(e.pipes,t);return o===-1?this:(e.pipes.splice(o,1),e.pipesCount-=1,e.pipesCount===1&&(e.pipes=e.pipes[0]),t.emit("unpipe",this,r),this)};P.prototype.on=function(t,e){var r=Dt.prototype.on.call(this,t,e),i=this._readableState;return t==="data"?(i.readableListening=this.listenerCount("readable")>0,i.flowing!==!1&&this.resume()):t==="readable"&&!i.endEmitted&&!i.readableListening&&(i.readableListening=i.needReadable=!0,i.flowing=!1,i.emittedReadable=!1,x("on readable",i.length,i.reading),i.length?Pr(this):i.reading||process.nextTick(dc,this)),r};P.prototype.addListener=P.prototype.on;P.prototype.removeListener=function(t,e){var r=Dt.prototype.removeListener.call(this,t,e);return t==="readable"&&process.nextTick(Ds,this),r};P.prototype.removeAllListeners=function(t){var e=Dt.prototype.removeAllListeners.apply(this,arguments);return(t==="readable"||t===void 0)&&process.nextTick(Ds,this),e};function Ds(t){var e=t._readableState;e.readableListening=t.listenerCount("readable")>0,e.resumeScheduled&&!e.paused?e.flowing=!0:t.listenerCount("data")>0&&t.resume()}function dc(t){x("readable nexttick read 0"),t.read(0)}P.prototype.resume=function(){var t=this._readableState;return t.flowing||(x("resume"),t.flowing=!t.readableListening,pc(this,t)),t.paused=!1,this};function pc(t,e){e.resumeScheduled||(e.resumeScheduled=!0,process.nextTick(gc,t,e))}function gc(t,e){x("resume",e.reading),e.reading||t.read(0),e.resumeScheduled=!1,t.emit("resume"),Ni(t),e.flowing&&!e.reading&&t.read(0)}P.prototype.pause=function(){return x("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(x("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this};function Ni(t){var e=t._readableState;for(x("flow",e.flowing);e.flowing&&t.read()!==null;);}P.prototype.wrap=function(t){var e=this,r=this._readableState,i=!1;t.on("end",function(){if(x("wrapped end"),r.decoder&&!r.ended){var o=r.decoder.end();o&&o.length&&e.push(o)}e.push(null)}),t.on("data",function(o){if(x("wrapped data"),r.decoder&&(o=r.decoder.write(o)),!(r.objectMode&&o==null)&&!(!r.objectMode&&(!o||!o.length))){var a=e.push(o);a||(i=!0,t.pause())}});for(var n in t)this[n]===void 0&&typeof t[n]=="function"&&(this[n]=(function(a){return function(){return t[a].apply(t,arguments)}})(n));for(var s=0;s<Bi.length;s++)t.on(Bi[s],this.emit.bind(this,Bi[s]));return this._read=function(o){x("wrapped _read",o),i&&(i=!1,t.resume())},this};typeof Symbol=="function"&&(P.prototype[Symbol.asyncIterator]=function(){return Ri===void 0&&(Ri=Ps()),Ri(this)});Object.defineProperty(P.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}});Object.defineProperty(P.prototype,"readableBuffer",{enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}});Object.defineProperty(P.prototype,"readableFlowing",{enumerable:!1,get:function(){return this._readableState.flowing},set:function(e){this._readableState&&(this._readableState.flowing=e)}});P._fromList=Us;Object.defineProperty(P.prototype,"readableLength",{enumerable:!1,get:function(){return this._readableState.length}});function Us(t,e){if(e.length===0)return null;var r;return e.objectMode?r=e.buffer.shift():!t||t>=e.length?(e.decoder?r=e.buffer.join(""):e.buffer.length===1?r=e.buffer.first():r=e.buffer.concat(e.length),e.buffer.clear()):r=e.buffer.consume(t,e.decoder),r}function Li(t){var e=t._readableState;x("endReadable",e.endEmitted),e.endEmitted||(e.ended=!0,process.nextTick(yc,e,t))}function yc(t,e){if(x("endReadableNT",t.endEmitted,t.length),!t.endEmitted&&t.length===0&&(t.endEmitted=!0,e.readable=!1,e.emit("end"),t.autoDestroy)){var r=e._writableState;(!r||r.autoDestroy&&r.finished)&&e.destroy()}}typeof Symbol=="function"&&(P.from=function(t,e){return Ai===void 0&&(Ai=As()),Ai(P,t,e)});function js(t,e){for(var r=0,i=t.length;r<i;r++)if(t[r]===e)return r;return-1}});var Di=g((hy,Vs)=>{"use strict";Vs.exports=Se;var Or=Be().codes,_c=Or.ERR_METHOD_NOT_IMPLEMENTED,mc=Or.ERR_MULTIPLE_CALLBACK,vc=Or.ERR_TRANSFORM_ALREADY_TRANSFORMING,bc=Or.ERR_TRANSFORM_WITH_LENGTH_0,Ir=Je();we()(Se,Ir);function wc(t,e){var r=this._transformState;r.transforming=!1;var i=r.writecb;if(i===null)return this.emit("error",new mc);r.writechunk=null,r.writecb=null,e!=null&&this.push(e),i(t);var n=this._readableState;n.reading=!1,(n.needReadable||n.length<n.highWaterMark)&&this._read(n.highWaterMark)}function Se(t){if(!(this instanceof Se))return new Se(t);Ir.call(this,t),this._transformState={afterTransform:wc.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,t&&(typeof t.transform=="function"&&(this._transform=t.transform),typeof t.flush=="function"&&(this._flush=t.flush)),this.on("prefinish",Sc)}function Sc(){var t=this;typeof this._flush=="function"&&!this._readableState.destroyed?this._flush(function(e,r){Ws(t,e,r)}):Ws(this,null,null)}Se.prototype.push=function(t,e){return this._transformState.needTransform=!1,Ir.prototype.push.call(this,t,e)};Se.prototype._transform=function(t,e,r){r(new _c("_transform()"))};Se.prototype._write=function(t,e,r){var i=this._transformState;if(i.writecb=r,i.writechunk=t,i.writeencoding=e,!i.transforming){var n=this._readableState;(i.needTransform||n.needReadable||n.length<n.highWaterMark)&&this._read(n.highWaterMark)}};Se.prototype._read=function(t){var e=this._transformState;e.writechunk!==null&&!e.transforming?(e.transforming=!0,this._transform(e.writechunk,e.writeencoding,e.afterTransform)):e.needTransform=!0};Se.prototype._destroy=function(t,e){Ir.prototype._destroy.call(this,t,function(r){e(r)})};function Ws(t,e,r){if(e)return t.emit("error",e);if(r!=null&&t.push(r),t._writableState.length)throw new bc;if(t._transformState.transforming)throw new vc;return t.push(null)}});var zs=g((dy,Ks)=>{"use strict";Ks.exports=Ut;var Hs=Di();we()(Ut,Hs);function Ut(t){if(!(this instanceof Ut))return new Ut(t);Hs.call(this,t)}Ut.prototype._transform=function(t,e,r){r(null,t)}});var Xs=g((py,Ys)=>{"use strict";var Ui;function Ec(t){var e=!1;return function(){e||(e=!0,t.apply(void 0,arguments))}}var Qs=Be().codes,xc=Qs.ERR_MISSING_ARGS,Tc=Qs.ERR_STREAM_DESTROYED;function $s(t){if(t)throw t}function Cc(t){return t.setHeader&&typeof t.abort=="function"}function Pc(t,e,r,i){i=Ec(i);var n=!1;t.on("close",function(){n=!0}),Ui===void 0&&(Ui=Sr()),Ui(t,{readable:e,writable:r},function(o){if(o)return i(o);n=!0,i()});var s=!1;return function(o){if(!n&&!s){if(s=!0,Cc(t))return t.abort();if(typeof t.destroy=="function")return t.destroy();i(o||new Tc("pipe"))}}}function Gs(t){t()}function Oc(t,e){return t.pipe(e)}function Ic(t){return!t.length||typeof t[t.length-1]!="function"?$s:t.pop()}function Rc(){for(var t=arguments.length,e=new Array(t),r=0;r<t;r++)e[r]=arguments[r];var i=Ic(e);if(Array.isArray(e[0])&&(e=e[0]),e.length<2)throw new xc("streams");var n,s=e.map(function(o,a){var u=a<e.length-1,l=a>0;return Pc(o,u,l,function(f){n||(n=f),f&&s.forEach(Gs),!u&&(s.forEach(Gs),i(n))})});return e.reduce(Oc)}Ys.exports=Rc});var Ne=g((se,Ft)=>{"use strict";var jt=require("stream");process.env.READABLE_STREAM==="disable"&&jt?(Ft.exports=jt.Readable,Object.assign(Ft.exports,jt),Ft.exports.Stream=jt):(se=Ft.exports=Ei(),se.Stream=jt||se,se.Readable=se,se.Writable=bi(),se.Duplex=Je(),se.Transform=Di(),se.PassThrough=zs(),se.finished=Sr(),se.pipeline=Xs())});var Rr=g((gy,Js)=>{"use strict";var Ac=pr(),Bc=Ne().Readable,kc={objectMode:!0},Lc={clean:!0};function De(t){if(!(this instanceof De))return new De(t);this.options=t||{},this.options=Ac(Lc,t),this._inflights=new Map}De.prototype.put=function(t,e){return this._inflights.set(t.messageId,t),e&&e(),this};De.prototype.createStream=function(){let t=new Bc(kc),e=[],r=!1,i=0;return this._inflights.forEach(function(n,s){e.push(n)}),t._read=function(){!r&&i<e.length?this.push(e[i++]):this.push(null)},t.destroy=function(){if(r)return;let n=this;r=!0,setTimeout(function(){n.emit("close")},0)},t};De.prototype.del=function(t,e){return t=this._inflights.get(t.messageId),t?(this._inflights.delete(t.messageId),e(null,t)):e&&e(new Error("missing packet")),this};De.prototype.get=function(t,e){return t=this._inflights.get(t.messageId),t?e(null,t):e&&e(new Error("missing packet")),this};De.prototype.close=function(t){this.options.clean&&(this._inflights=null),t&&t()};Js.exports=De});var eo=g((yy,Zs)=>{"use strict";function bt(t){if(!(this instanceof bt))return new bt(t);this.aliasToTopic={},this.max=t}bt.prototype.put=function(t,e){return e===0||e>this.max?!1:(this.aliasToTopic[e]=t,this.length=Object.keys(this.aliasToTopic).length,!0)};bt.prototype.getTopicByAlias=function(t){return this.aliasToTopic[t]};bt.prototype.clear=function(){this.aliasToTopic={}};Zs.exports=bt});var ro=g((_y,to)=>{"use strict";to.exports=function(t){t.prototype[Symbol.iterator]=function*(){for(let e=this.head;e;e=e.next)yield e.value}}});var no=g((my,io)=>{"use strict";io.exports=O;O.Node=it;O.create=O;function O(t){var e=this;if(e instanceof O||(e=new O),e.tail=null,e.head=null,e.length=0,t&&typeof t.forEach=="function")t.forEach(function(n){e.push(n)});else if(arguments.length>0)for(var r=0,i=arguments.length;r<i;r++)e.push(arguments[r]);return e}O.prototype.removeNode=function(t){if(t.list!==this)throw new Error("removing node which does not belong to this list");var e=t.next,r=t.prev;return e&&(e.prev=r),r&&(r.next=e),t===this.head&&(this.head=e),t===this.tail&&(this.tail=r),t.list.length--,t.next=null,t.prev=null,t.list=null,e};O.prototype.unshiftNode=function(t){if(t!==this.head){t.list&&t.list.removeNode(t);var e=this.head;t.list=this,t.next=e,e&&(e.prev=t),this.head=t,this.tail||(this.tail=t),this.length++}};O.prototype.pushNode=function(t){if(t!==this.tail){t.list&&t.list.removeNode(t);var e=this.tail;t.list=this,t.prev=e,e&&(e.next=t),this.tail=t,this.head||(this.head=t),this.length++}};O.prototype.push=function(){for(var t=0,e=arguments.length;t<e;t++)qc(this,arguments[t]);return this.length};O.prototype.unshift=function(){for(var t=0,e=arguments.length;t<e;t++)Nc(this,arguments[t]);return this.length};O.prototype.pop=function(){if(this.tail){var t=this.tail.value;return this.tail=this.tail.prev,this.tail?this.tail.next=null:this.head=null,this.length--,t}};O.prototype.shift=function(){if(this.head){var t=this.head.value;return this.head=this.head.next,this.head?this.head.prev=null:this.tail=null,this.length--,t}};O.prototype.forEach=function(t,e){e=e||this;for(var r=this.head,i=0;r!==null;i++)t.call(e,r.value,i,this),r=r.next};O.prototype.forEachReverse=function(t,e){e=e||this;for(var r=this.tail,i=this.length-1;r!==null;i--)t.call(e,r.value,i,this),r=r.prev};O.prototype.get=function(t){for(var e=0,r=this.head;r!==null&&e<t;e++)r=r.next;if(e===t&&r!==null)return r.value};O.prototype.getReverse=function(t){for(var e=0,r=this.tail;r!==null&&e<t;e++)r=r.prev;if(e===t&&r!==null)return r.value};O.prototype.map=function(t,e){e=e||this;for(var r=new O,i=this.head;i!==null;)r.push(t.call(e,i.value,this)),i=i.next;return r};O.prototype.mapReverse=function(t,e){e=e||this;for(var r=new O,i=this.tail;i!==null;)r.push(t.call(e,i.value,this)),i=i.prev;return r};O.prototype.reduce=function(t,e){var r,i=this.head;if(arguments.length>1)r=e;else if(this.head)i=this.head.next,r=this.head.value;else throw new TypeError("Reduce of empty list with no initial value");for(var n=0;i!==null;n++)r=t(r,i.value,n),i=i.next;return r};O.prototype.reduceReverse=function(t,e){var r,i=this.tail;if(arguments.length>1)r=e;else if(this.tail)i=this.tail.prev,r=this.tail.value;else throw new TypeError("Reduce of empty list with no initial value");for(var n=this.length-1;i!==null;n--)r=t(r,i.value,n),i=i.prev;return r};O.prototype.toArray=function(){for(var t=new Array(this.length),e=0,r=this.head;r!==null;e++)t[e]=r.value,r=r.next;return t};O.prototype.toArrayReverse=function(){for(var t=new Array(this.length),e=0,r=this.tail;r!==null;e++)t[e]=r.value,r=r.prev;return t};O.prototype.slice=function(t,e){e=e||this.length,e<0&&(e+=this.length),t=t||0,t<0&&(t+=this.length);var r=new O;if(e<t||e<0)return r;t<0&&(t=0),e>this.length&&(e=this.length);for(var i=0,n=this.head;n!==null&&i<t;i++)n=n.next;for(;n!==null&&i<e;i++,n=n.next)r.push(n.value);return r};O.prototype.sliceReverse=function(t,e){e=e||this.length,e<0&&(e+=this.length),t=t||0,t<0&&(t+=this.length);var r=new O;if(e<t||e<0)return r;t<0&&(t=0),e>this.length&&(e=this.length);for(var i=this.length,n=this.tail;n!==null&&i>e;i--)n=n.prev;for(;n!==null&&i>t;i--,n=n.prev)r.push(n.value);return r};O.prototype.splice=function(t,e,...r){t>this.length&&(t=this.length-1),t<0&&(t=this.length+t);for(var i=0,n=this.head;n!==null&&i<t;i++)n=n.next;for(var s=[],i=0;n&&i<e;i++)s.push(n.value),n=this.removeNode(n);n===null&&(n=this.tail),n!==this.head&&n!==this.tail&&(n=n.prev);for(var i=0;i<r.length;i++)n=Mc(this,n,r[i]);return s};O.prototype.reverse=function(){for(var t=this.head,e=this.tail,r=t;r!==null;r=r.prev){var i=r.prev;r.prev=r.next,r.next=i}return this.head=e,this.tail=t,this};function Mc(t,e,r){var i=e===t.head?new it(r,null,e,t):new it(r,e,e.next,t);return i.next===null&&(t.tail=i),i.prev===null&&(t.head=i),t.length++,i}function qc(t,e){t.tail=new it(e,t.tail,null,t),t.head||(t.head=t.tail),t.length++}function Nc(t,e){t.head=new it(e,null,t.head,t),t.tail||(t.tail=t.head),t.length++}function it(t,e,r,i){if(!(this instanceof it))return new it(t,e,r,i);this.list=i,this.value=t,e?(e.next=this,this.prev=e):this.prev=null,r?(r.prev=this,this.next=r):this.next=null}try{ro()(O)}catch{}});var uo=g((vy,lo)=>{"use strict";var Dc=no(),nt=Symbol("max"),xe=Symbol("length"),wt=Symbol("lengthCalculator"),Vt=Symbol("allowStale"),st=Symbol("maxAge"),Ee=Symbol("dispose"),so=Symbol("noDisposeOnSet"),W=Symbol("lruList"),ue=Symbol("cache"),ao=Symbol("updateAgeOnGet"),ji=()=>1,Wi=class{constructor(e){if(typeof e=="number"&&(e={max:e}),e||(e={}),e.max&&(typeof e.max!="number"||e.max<0))throw new TypeError("max must be a non-negative number");let r=this[nt]=e.max||1/0,i=e.length||ji;if(this[wt]=typeof i!="function"?ji:i,this[Vt]=e.stale||!1,e.maxAge&&typeof e.maxAge!="number")throw new TypeError("maxAge must be a number");this[st]=e.maxAge||0,this[Ee]=e.dispose,this[so]=e.noDisposeOnSet||!1,this[ao]=e.updateAgeOnGet||!1,this.reset()}set max(e){if(typeof e!="number"||e<0)throw new TypeError("max must be a non-negative number");this[nt]=e||1/0,Wt(this)}get max(){return this[nt]}set allowStale(e){this[Vt]=!!e}get allowStale(){return this[Vt]}set maxAge(e){if(typeof e!="number")throw new TypeError("maxAge must be a non-negative number");this[st]=e,Wt(this)}get maxAge(){return this[st]}set lengthCalculator(e){typeof e!="function"&&(e=ji),e!==this[wt]&&(this[wt]=e,this[xe]=0,this[W].forEach(r=>{r.length=this[wt](r.value,r.key),this[xe]+=r.length})),Wt(this)}get lengthCalculator(){return this[wt]}get length(){return this[xe]}get itemCount(){return this[W].length}rforEach(e,r){r=r||this;for(let i=this[W].tail;i!==null;){let n=i.prev;oo(this,e,i,r),i=n}}forEach(e,r){r=r||this;for(let i=this[W].head;i!==null;){let n=i.next;oo(this,e,i,r),i=n}}keys(){return this[W].toArray().map(e=>e.key)}values(){return this[W].toArray().map(e=>e.value)}reset(){this[Ee]&&this[W]&&this[W].length&&this[W].forEach(e=>this[Ee](e.key,e.value)),this[ue]=new Map,this[W]=new Dc,this[xe]=0}dump(){return this[W].map(e=>Ar(this,e)?!1:{k:e.key,v:e.value,e:e.now+(e.maxAge||0)}).toArray().filter(e=>e)}dumpLru(){return this[W]}set(e,r,i){if(i=i||this[st],i&&typeof i!="number")throw new TypeError("maxAge must be a number");let n=i?Date.now():0,s=this[wt](r,e);if(this[ue].has(e)){if(s>this[nt])return St(this,this[ue].get(e)),!1;let u=this[ue].get(e).value;return this[Ee]&&(this[so]||this[Ee](e,u.value)),u.now=n,u.maxAge=i,u.value=r,this[xe]+=s-u.length,u.length=s,this.get(e),Wt(this),!0}let o=new Vi(e,r,s,n,i);return o.length>this[nt]?(this[Ee]&&this[Ee](e,r),!1):(this[xe]+=o.length,this[W].unshift(o),this[ue].set(e,this[W].head),Wt(this),!0)}has(e){if(!this[ue].has(e))return!1;let r=this[ue].get(e).value;return!Ar(this,r)}get(e){return Fi(this,e,!0)}peek(e){return Fi(this,e,!1)}pop(){let e=this[W].tail;return e?(St(this,e),e.value):null}del(e){St(this,this[ue].get(e))}load(e){this.reset();let r=Date.now();for(let i=e.length-1;i>=0;i--){let n=e[i],s=n.e||0;if(s===0)this.set(n.k,n.v);else{let o=s-r;o>0&&this.set(n.k,n.v,o)}}}prune(){this[ue].forEach((e,r)=>Fi(this,r,!1))}},Fi=(t,e,r)=>{let i=t[ue].get(e);if(i){let n=i.value;if(Ar(t,n)){if(St(t,i),!t[Vt])return}else r&&(t[ao]&&(i.value.now=Date.now()),t[W].unshiftNode(i));return n.value}},Ar=(t,e)=>{if(!e||!e.maxAge&&!t[st])return!1;let r=Date.now()-e.now;return e.maxAge?r>e.maxAge:t[st]&&r>t[st]},Wt=t=>{if(t[xe]>t[nt])for(let e=t[W].tail;t[xe]>t[nt]&&e!==null;){let r=e.prev;St(t,e),e=r}},St=(t,e)=>{if(e){let r=e.value;t[Ee]&&t[Ee](r.key,r.value),t[xe]-=r.length,t[ue].delete(r.key),t[W].removeNode(e)}},Vi=class{constructor(e,r,i,n,s){this.key=e,this.value=r,this.length=i,this.now=n,this.maxAge=s||0}},oo=(t,e,r,i)=>{let n=r.value;Ar(t,n)&&(St(t,r),t[Vt]||(n=void 0)),n&&e.call(i,n.value,n.key,t)};lo.exports=Wi});var Uc,A,Te,Et,Y=U(()=>{"use strict";Uc=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}})(),A=(function(){function t(e){e===void 0&&(e=t.NORMAL),this.iteratorType=e}return t.NORMAL=!1,t.REVERSE=!0,t})(),Te=(function(){function t(){this.length=0}return t.prototype.size=function(){return this.length},t.prototype.empty=function(){return this.length===0},t})(),Et=(function(t){Uc(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e})(Te)});var jc,Fc,fo,co=U(()=>{"use strict";Y();jc=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}})(),Fc=(function(t){jc(e,t);function e(r){r===void 0&&(r=[]);var i=t.call(this)||this;return i.stack=[],r.forEach(function(n){return i.push(n)}),i}return e.prototype.clear=function(){this.length=0,this.stack.length=0},e.prototype.push=function(r){this.stack.push(r),this.length+=1},e.prototype.pop=function(){this.stack.pop(),this.length>0&&(this.length-=1)},e.prototype.top=function(){return this.stack[this.length-1]},e})(Te),fo=Fc});var Wc,Vc,Ue,Ht=U(()=>{"use strict";Y();Wc=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}})(),Vc=(function(t){Wc(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e})(Et),Ue=Vc});function B(t,e,r){if(t<e||t>r)throw new RangeError}var je=U(()=>{"use strict"});var Hc,Br,Hi=U(()=>{"use strict";je();Y();Hc=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}})(),Br=(function(t){Hc(e,t);function e(r,i,n,s,o){var a=t.call(this,o)||this;return a.node=r,a.size=i,a.getElementByPos=n,a.setElementByPos=s,a.iteratorType===A.NORMAL?(a.pre=function(){if(this.node===0)throw new RangeError("Deque iterator access denied!");return this.node-=1,this},a.next=function(){if(this.node===this.size())throw new RangeError("Deque Iterator access denied!");return this.node+=1,this}):(a.pre=function(){if(this.node===this.size()-1)throw new RangeError("Deque iterator access denied!");return this.node+=1,this},a.next=function(){if(this.node===-1)throw new RangeError("Deque iterator access denied!");return this.node-=1,this}),a}return Object.defineProperty(e.prototype,"pointer",{get:function(){return B(this.node,0,this.size()-1),this.getElementByPos(this.node)},set:function(r){B(this.node,0,this.size()-1),this.setElementByPos(this.node,r)},enumerable:!1,configurable:!0}),e.prototype.equals=function(r){return this.node===r.node},e})(A)});var ho,Kc,zc,$c,ot,Gc,kr,Ki=U(()=>{"use strict";Ht();je();Y();Hi();ho=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}})(),Kc=function(t,e){var r={label:0,sent:function(){if(s[0]&1)throw s[1];return s[1]},trys:[],ops:[]},i,n,s,o;return o={next:a(0),throw:a(1),return:a(2)},typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function a(l){return function(f){return u([l,f])}}function u(l){if(i)throw new TypeError("Generator is already executing.");for(;r;)try{if(i=1,n&&(s=l[0]&2?n.return:l[0]?n.throw||((s=n.return)&&s.call(n),0):n.next)&&!(s=s.call(n,l[1])).done)return s;switch(n=0,s&&(l=[l[0]&2,s.value]),l[0]){case 0:case 1:s=l;break;case 4:return r.label++,{value:l[1],done:!1};case 5:r.label++,n=l[1],l=[0];continue;case 7:l=r.ops.pop(),r.trys.pop();continue;default:if(s=r.trys,!(s=s.length>0&&s[s.length-1])&&(l[0]===6||l[0]===2)){r=0;continue}if(l[0]===3&&(!s||l[1]>s[0]&&l[1]<s[3])){r.label=l[1];break}if(l[0]===6&&r.label<s[1]){r.label=s[1],s=l;break}if(s&&r.label<s[2]){r.label=s[2],r.ops.push(l);break}s[2]&&r.ops.pop(),r.trys.pop();continue}l=e.call(t,r)}catch(f){l=[6,f],n=0}finally{i=s=0}if(l[0]&5)throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}},zc=function(t,e){var r=typeof Symbol=="function"&&t[Symbol.iterator];if(!r)return t;var i=r.call(t),n,s=[],o;try{for(;(e===void 0||e-- >0)&&!(n=i.next()).done;)s.push(n.value)}catch(a){o={error:a}}finally{try{n&&!n.done&&(r=i.return)&&r.call(i)}finally{if(o)throw o.error}}return s},$c=function(t,e,r){if(r||arguments.length===2)for(var i=0,n=e.length,s;i<n;i++)(s||!(i in e))&&(s||(s=Array.prototype.slice.call(e,0,i)),s[i]=e[i]);return t.concat(s||Array.prototype.slice.call(e))},ot=(function(t){ho(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.prototype.copy=function(){return new e(this.node,this.size,this.getElementByPos,this.setElementByPos,this.iteratorType)},e})(Br),Gc=(function(t){ho(e,t);function e(r,i){r===void 0&&(r=[]),i===void 0&&(i=4096);var n=t.call(this)||this;n.first=0,n.curFirst=0,n.last=0,n.curLast=0,n.bucketNum=0,n.map=[];var s;if("size"in r)typeof r.size=="number"?s=r.size:s=r.size();else if("length"in r)s=r.length;else throw new RangeError("Can't get container's size!");n.bucketSize=i,n.bucketNum=Math.max(Math.ceil(s/n.bucketSize),1);for(var o=0;o<n.bucketNum;++o)n.map.push(new Array(n.bucketSize));var a=Math.ceil(s/n.bucketSize);return n.first=n.last=(n.bucketNum>>1)-(a>>1),n.curFirst=n.curLast=n.bucketSize-s%n.bucketSize>>1,r.forEach(function(u){return n.pushBack(u)}),n.size=n.size.bind(n),n.getElementByPos=n.getElementByPos.bind(n),n.setElementByPos=n.setElementByPos.bind(n),n}return e.prototype.reAllocate=function(){for(var r=[],i=Math.max(this.bucketNum>>1,1),n=0;n<i;++n)r[n]=new Array(this.bucketSize);for(var n=this.first;n<this.bucketNum;++n)r[r.length]=this.map[n];for(var n=0;n<this.last;++n)r[r.length]=this.map[n];r[r.length]=$c([],zc(this.map[this.last]),!1),this.first=i,this.last=r.length-1;for(var n=0;n<i;++n)r[r.length]=new Array(this.bucketSize);this.map=r,this.bucketNum=r.length},e.prototype.getElementIndex=function(r){var i=this.curFirst+r+1,n=i%this.bucketSize,s=n-1,o=this.first+(i-n)/this.bucketSize;return n===0&&(o-=1),o%=this.bucketNum,s<0&&(s+=this.bucketSize),{curNodeBucketIndex:o,curNodePointerIndex:s}},e.prototype.clear=function(){this.map=[[]],this.bucketNum=1,this.first=this.last=this.length=0,this.curFirst=this.curLast=this.bucketSize>>1},e.prototype.front=function(){return this.map[this.first][this.curFirst]},e.prototype.back=function(){return this.map[this.last][this.curLast]},e.prototype.begin=function(){return new ot(0,this.size,this.getElementByPos,this.setElementByPos)},e.prototype.end=function(){return new ot(this.length,this.size,this.getElementByPos,this.setElementByPos)},e.prototype.rBegin=function(){return new ot(this.length-1,this.size,this.getElementByPos,this.setElementByPos,A.REVERSE)},e.prototype.rEnd=function(){return new ot(-1,this.size,this.getElementByPos,this.setElementByPos,A.REVERSE)},e.prototype.pushBack=function(r){this.length&&(this.curLast<this.bucketSize-1?this.curLast+=1:this.last<this.bucketNum-1?(this.last+=1,this.curLast=0):(this.last=0,this.curLast=0),this.last===this.first&&this.curLast===this.curFirst&&this.reAllocate()),this.length+=1,this.map[this.last][this.curLast]=r},e.prototype.popBack=function(){this.length&&(this.map[this.last][this.curLast]=void 0,this.length!==1&&(this.curLast>0?this.curLast-=1:this.last>0?(this.last-=1,this.curLast=this.bucketSize-1):(this.last=this.bucketNum-1,this.curLast=this.bucketSize-1)),this.length-=1)},e.prototype.pushFront=function(r){this.length&&(this.curFirst>0?this.curFirst-=1:this.first>0?(this.first-=1,this.curFirst=this.bucketSize-1):(this.first=this.bucketNum-1,this.curFirst=this.bucketSize-1),this.first===this.last&&this.curFirst===this.curLast&&this.reAllocate()),this.length+=1,this.map[this.first][this.curFirst]=r},e.prototype.popFront=function(){this.length&&(this.map[this.first][this.curFirst]=void 0,this.length!==1&&(this.curFirst<this.bucketSize-1?this.curFirst+=1:this.first<this.bucketNum-1?(this.first+=1,this.curFirst=0):(this.first=0,this.curFirst=0)),this.length-=1)},e.prototype.forEach=function(r){for(var i=0;i<this.length;++i)r(this.getElementByPos(i),i)},e.prototype.getElementByPos=function(r){B(r,0,this.length-1);var i=this.getElementIndex(r),n=i.curNodeBucketIndex,s=i.curNodePointerIndex;return this.map[n][s]},e.prototype.setElementByPos=function(r,i){B(r,0,this.length-1);var n=this.getElementIndex(r),s=n.curNodeBucketIndex,o=n.curNodePointerIndex;this.map[s][o]=i},e.prototype.insert=function(r,i,n){if(n===void 0&&(n=1),B(r,0,this.length),r===0)for(;n--;)this.pushFront(i);else if(r===this.length)for(;n--;)this.pushBack(i);else{for(var s=[],o=r;o<this.length;++o)s.push(this.getElementByPos(o));this.cut(r-1);for(var o=0;o<n;++o)this.pushBack(i);for(var o=0;o<s.length;++o)this.pushBack(s[o])}},e.prototype.cut=function(r){if(r<0){this.clear();return}var i=this.getElementIndex(r),n=i.curNodeBucketIndex,s=i.curNodePointerIndex;this.last=n,this.curLast=s,this.length=r+1},e.prototype.eraseElementByPos=function(r){var i=this;if(B(r,0,this.length-1),r===0)this.popFront();else if(r===this.length-1)this.popBack();else{for(var n=[],s=r+1;s<this.length;++s)n.push(this.getElementByPos(s));this.cut(r),this.popBack(),n.forEach(function(o){return i.pushBack(o)})}},e.prototype.eraseElementByValue=function(r){if(this.length){for(var i=[],n=0;n<this.length;++n){var s=this.getElementByPos(n);s!==r&&i.push(s)}for(var o=i.length,n=0;n<o;++n)this.setElementByPos(n,i[n]);this.cut(o-1)}},e.prototype.eraseElementByIterator=function(r){var i=r.node;return this.eraseElementByPos(i),r=r.next(),r},e.prototype.find=function(r){for(var i=0;i<this.length;++i)if(this.getElementByPos(i)===r)return new ot(i,this.size,this.getElementByPos,this.setElementByPos);return this.end()},e.prototype.reverse=function(){for(var r=0,i=this.length-1;r<i;){var n=this.getElementByPos(r);this.setElementByPos(r,this.getElementByPos(i)),this.setElementByPos(i,n),r+=1,i-=1}},e.prototype.unique=function(){if(!(this.length<=1)){for(var r=1,i=this.getElementByPos(0),n=1;n<this.length;++n){var s=this.getElementByPos(n);s!==i&&(i=s,this.setElementByPos(r++,s))}for(;this.length>r;)this.popBack()}},e.prototype.sort=function(r){for(var i=[],n=0;n<this.length;++n)i.push(this.getElementByPos(n));i.sort(r);for(var n=0;n<this.length;++n)this.setElementByPos(n,i[n])},e.prototype.shrinkToFit=function(){if(this.length){var r=[];this.forEach(function(n){return r.push(n)}),this.bucketNum=Math.max(Math.ceil(this.length/this.bucketSize),1),this.length=this.first=this.last=this.curFirst=this.curLast=0,this.map=[];for(var i=0;i<this.bucketNum;++i)this.map.push(new Array(this.bucketSize));for(var i=0;i<r.length;++i)this.pushBack(r[i])}},e.prototype[Symbol.iterator]=function(){return function(){var r;return Kc(this,function(i){switch(i.label){case 0:r=0,i.label=1;case 1:return r<this.length?[4,this.getElementByPos(r)]:[3,4];case 2:i.sent(),i.label=3;case 3:return++r,[3,1];case 4:return[2]}})}.bind(this)()},e})(Ue),kr=Gc});var Qc,Yc,po,go=U(()=>{"use strict";Ki();Y();Qc=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}})(),Yc=(function(t){Qc(e,t);function e(r){r===void 0&&(r=[]);var i=t.call(this)||this;return i.queue=new kr(r),i.length=i.queue.size(),i}return e.prototype.clear=function(){this.queue.clear(),this.length=0},e.prototype.push=function(r){this.queue.pushBack(r),this.length+=1},e.prototype.pop=function(){this.queue.popFront(),this.length&&(this.length-=1)},e.prototype.front=function(){return this.queue.front()},e})(Te),po=Yc});var Xc,Lr,Jc,Zc,yo,_o=U(()=>{"use strict";Y();Xc=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}})(),Lr=function(t,e){var r=typeof Symbol=="function"&&t[Symbol.iterator];if(!r)return t;var i=r.call(t),n,s=[],o;try{for(;(e===void 0||e-- >0)&&!(n=i.next()).done;)s.push(n.value)}catch(a){o={error:a}}finally{try{n&&!n.done&&(r=i.return)&&r.call(i)}finally{if(o)throw o.error}}return s},Jc=function(t,e,r){if(r||arguments.length===2)for(var i=0,n=e.length,s;i<n;i++)(s||!(i in e))&&(s||(s=Array.prototype.slice.call(e,0,i)),s[i]=e[i]);return t.concat(s||Array.prototype.slice.call(e))},Zc=(function(t){Xc(e,t);function e(r,i,n){var s;r===void 0&&(r=[]),i===void 0&&(i=function(d,m){return d>m?-1:d<m?1:0}),n===void 0&&(n=!0);var o=t.call(this)||this;o.cmp=i,Array.isArray(r)?o.priorityQueue=n?Jc([],Lr(r),!1):r:(o.priorityQueue=[],r.forEach(function(d){return o.priorityQueue.push(d)})),o.length=o.priorityQueue.length;for(var a=o.length-1>>1;a>=0;--a)for(var u=a,l=u<<1|1;l<o.length;){var f=l,h=f+1,c=f;if(h<o.length&&o.cmp(o.priorityQueue[f],o.priorityQueue[h])>0&&(c=h),o.cmp(o.priorityQueue[u],o.priorityQueue[c])<=0)break;s=Lr([o.priorityQueue[c],o.priorityQueue[u]],2),o.priorityQueue[u]=s[0],o.priorityQueue[c]=s[1],u=c,l=u<<1|1}return o}return e.prototype.adjust=function(r){var i,n,s=r<<1|1,o=(r<<1)+2;s<this.length&&this.cmp(this.priorityQueue[r],this.priorityQueue[s])>0&&(i=Lr([this.priorityQueue[s],this.priorityQueue[r]],2),this.priorityQueue[r]=i[0],this.priorityQueue[s]=i[1]),o<this.length&&this.cmp(this.priorityQueue[r],this.priorityQueue[o])>0&&(n=Lr([this.priorityQueue[o],this.priorityQueue[r]],2),this.priorityQueue[r]=n[0],this.priorityQueue[o]=n[1])},e.prototype.clear=function(){this.length=0,this.priorityQueue.length=0},e.prototype.push=function(r){if(this.priorityQueue.push(r),this.length+=1,this.length!==1)for(var i=this.length-1;i>0;){var n=i-1>>1;if(this.cmp(this.priorityQueue[n],r)<=0)break;this.adjust(n),i=n}},e.prototype.pop=function(){if(this.length){var r=this.priorityQueue[this.length-1];this.length-=1;for(var i=0;i<this.length;){var n=i<<1|1,s=(i<<1)+2;if(n>=this.length)break;var o=n;if(s<this.length&&this.cmp(this.priorityQueue[n],this.priorityQueue[s])>0&&(o=s),this.cmp(this.priorityQueue[o],r)>=0)break;this.priorityQueue[i]=this.priorityQueue[o],i=o}this.priorityQueue[i]=r,this.priorityQueue.pop()}},e.prototype.top=function(){return this.priorityQueue[0]},e})(Te),yo=Zc});var bo,eh,mo,vo,th,at,rh,M,Mr=U(()=>{"use strict";Ht();je();Y();Hi();bo=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}})(),eh=function(t,e){var r={label:0,sent:function(){if(s[0]&1)throw s[1];return s[1]},trys:[],ops:[]},i,n,s,o;return o={next:a(0),throw:a(1),return:a(2)},typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function a(l){return function(f){return u([l,f])}}function u(l){if(i)throw new TypeError("Generator is already executing.");for(;r;)try{if(i=1,n&&(s=l[0]&2?n.return:l[0]?n.throw||((s=n.return)&&s.call(n),0):n.next)&&!(s=s.call(n,l[1])).done)return s;switch(n=0,s&&(l=[l[0]&2,s.value]),l[0]){case 0:case 1:s=l;break;case 4:return r.label++,{value:l[1],done:!1};case 5:r.label++,n=l[1],l=[0];continue;case 7:l=r.ops.pop(),r.trys.pop();continue;default:if(s=r.trys,!(s=s.length>0&&s[s.length-1])&&(l[0]===6||l[0]===2)){r=0;continue}if(l[0]===3&&(!s||l[1]>s[0]&&l[1]<s[3])){r.label=l[1];break}if(l[0]===6&&r.label<s[1]){r.label=s[1],s=l;break}if(s&&r.label<s[2]){r.label=s[2],r.ops.push(l);break}s[2]&&r.ops.pop(),r.trys.pop();continue}l=e.call(t,r)}catch(f){l=[6,f],n=0}finally{i=s=0}if(l[0]&5)throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}},mo=function(t,e){var r=typeof Symbol=="function"&&t[Symbol.iterator];if(!r)return t;var i=r.call(t),n,s=[],o;try{for(;(e===void 0||e-- >0)&&!(n=i.next()).done;)s.push(n.value)}catch(a){o={error:a}}finally{try{n&&!n.done&&(r=i.return)&&r.call(i)}finally{if(o)throw o.error}}return s},vo=function(t,e,r){if(r||arguments.length===2)for(var i=0,n=e.length,s;i<n;i++)(s||!(i in e))&&(s||(s=Array.prototype.slice.call(e,0,i)),s[i]=e[i]);return t.concat(s||Array.prototype.slice.call(e))},th=function(t){var e=typeof Symbol=="function"&&Symbol.iterator,r=e&&t[e],i=0;if(r)return r.call(t);if(t&&typeof t.length=="number")return{next:function(){return t&&i>=t.length&&(t=void 0),{value:t&&t[i++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},at=(function(t){bo(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.prototype.copy=function(){return new e(this.node,this.size,this.getElementByPos,this.setElementByPos,this.iteratorType)},e})(Br),rh=(function(t){bo(e,t);function e(r,i){r===void 0&&(r=[]),i===void 0&&(i=!0);var n=t.call(this)||this;return Array.isArray(r)?(n.vector=i?vo([],mo(r),!1):r,n.length=r.length):(n.vector=[],r.forEach(function(s){return n.pushBack(s)})),n.size=n.size.bind(n),n.getElementByPos=n.getElementByPos.bind(n),n.setElementByPos=n.setElementByPos.bind(n),n}return e.prototype.clear=function(){this.length=0,this.vector.length=0},e.prototype.begin=function(){return new at(0,this.size,this.getElementByPos,this.setElementByPos)},e.prototype.end=function(){return new at(this.length,this.size,this.getElementByPos,this.setElementByPos)},e.prototype.rBegin=function(){return new at(this.length-1,this.size,this.getElementByPos,this.setElementByPos,A.REVERSE)},e.prototype.rEnd=function(){return new at(-1,this.size,this.getElementByPos,this.setElementByPos,A.REVERSE)},e.prototype.front=function(){return this.vector[0]},e.prototype.back=function(){return this.vector[this.length-1]},e.prototype.forEach=function(r){for(var i=0;i<this.length;++i)r(this.vector[i],i)},e.prototype.getElementByPos=function(r){return B(r,0,this.length-1),this.vector[r]},e.prototype.eraseElementByPos=function(r){B(r,0,this.length-1),this.vector.splice(r,1),this.length-=1},e.prototype.eraseElementByValue=function(r){for(var i=0,n=0;n<this.length;++n)this.vector[n]!==r&&(this.vector[i++]=this.vector[n]);this.length=this.vector.length=i},e.prototype.eraseElementByIterator=function(r){var i=r.node;return r=r.next(),this.eraseElementByPos(i),r},e.prototype.pushBack=function(r){this.vector.push(r),this.length+=1},e.prototype.popBack=function(){this.length&&(this.vector.pop(),this.length-=1)},e.prototype.setElementByPos=function(r,i){B(r,0,this.length-1),this.vector[r]=i},e.prototype.insert=function(r,i,n){var s;n===void 0&&(n=1),B(r,0,this.length),(s=this.vector).splice.apply(s,vo([r,0],mo(new Array(n).fill(i)),!1)),this.length+=n},e.prototype.find=function(r){for(var i=0;i<this.length;++i)if(this.vector[i]===r)return new at(i,this.size,this.getElementByPos,this.getElementByPos);return this.end()},e.prototype.reverse=function(){this.vector.reverse()},e.prototype.unique=function(){for(var r=1,i=1;i<this.length;++i)this.vector[i]!==this.vector[i-1]&&(this.vector[r++]=this.vector[i]);this.length=this.vector.length=r},e.prototype.sort=function(r){this.vector.sort(r)},e.prototype[Symbol.iterator]=function(){return function(){return eh(this,function(r){switch(r.label){case 0:return[5,th(this.vector)];case 1:return[2,r.sent()]}})}.bind(this)()},e})(Ue),M=rh});var wo,ih,Kt,lt,nh,So,Eo=U(()=>{"use strict";Ht();je();Y();wo=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}})(),ih=function(t,e){var r={label:0,sent:function(){if(s[0]&1)throw s[1];return s[1]},trys:[],ops:[]},i,n,s,o;return o={next:a(0),throw:a(1),return:a(2)},typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function a(l){return function(f){return u([l,f])}}function u(l){if(i)throw new TypeError("Generator is already executing.");for(;r;)try{if(i=1,n&&(s=l[0]&2?n.return:l[0]?n.throw||((s=n.return)&&s.call(n),0):n.next)&&!(s=s.call(n,l[1])).done)return s;switch(n=0,s&&(l=[l[0]&2,s.value]),l[0]){case 0:case 1:s=l;break;case 4:return r.label++,{value:l[1],done:!1};case 5:r.label++,n=l[1],l=[0];continue;case 7:l=r.ops.pop(),r.trys.pop();continue;default:if(s=r.trys,!(s=s.length>0&&s[s.length-1])&&(l[0]===6||l[0]===2)){r=0;continue}if(l[0]===3&&(!s||l[1]>s[0]&&l[1]<s[3])){r.label=l[1];break}if(l[0]===6&&r.label<s[1]){r.label=s[1],s=l;break}if(s&&r.label<s[2]){r.label=s[2],r.ops.push(l);break}s[2]&&r.ops.pop(),r.trys.pop();continue}l=e.call(t,r)}catch(f){l=[6,f],n=0}finally{i=s=0}if(l[0]&5)throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}},Kt=(function(){function t(e){this.value=void 0,this.pre=void 0,this.next=void 0,this.value=e}return t})(),lt=(function(t){wo(e,t);function e(r,i,n){var s=t.call(this,n)||this;return s.node=r,s.header=i,s.iteratorType===A.NORMAL?(s.pre=function(){if(this.node.pre===this.header)throw new RangeError("LinkList iterator access denied!");return this.node=this.node.pre,this},s.next=function(){if(this.node===this.header)throw new RangeError("LinkList iterator access denied!");return this.node=this.node.next,this}):(s.pre=function(){if(this.node.next===this.header)throw new RangeError("LinkList iterator access denied!");return this.node=this.node.next,this},s.next=function(){if(this.node===this.header)throw new RangeError("LinkList iterator access denied!");return this.node=this.node.pre,this}),s}return Object.defineProperty(e.prototype,"pointer",{get:function(){if(this.node===this.header)throw new RangeError("LinkList iterator access denied!");return this.node.value},set:function(r){if(this.node===this.header)throw new RangeError("LinkList iterator access denied!");this.node.value=r},enumerable:!1,configurable:!0}),e.prototype.equals=function(r){return this.node===r.node},e.prototype.copy=function(){return new e(this.node,this.header,this.iteratorType)},e})(A),nh=(function(t){wo(e,t);function e(r){r===void 0&&(r=[]);var i=t.call(this)||this;return i.header=new Kt,i.head=void 0,i.tail=void 0,r.forEach(function(n){return i.pushBack(n)}),i}return e.prototype.clear=function(){this.length=0,this.head=this.tail=void 0,this.header.pre=this.header.next=void 0},e.prototype.begin=function(){return new lt(this.head||this.header,this.header)},e.prototype.end=function(){return new lt(this.header,this.header)},e.prototype.rBegin=function(){return new lt(this.tail||this.header,this.header,A.REVERSE)},e.prototype.rEnd=function(){return new lt(this.header,this.header,A.REVERSE)},e.prototype.front=function(){return this.head?this.head.value:void 0},e.prototype.back=function(){return this.tail?this.tail.value:void 0},e.prototype.forEach=function(r){if(this.length)for(var i=this.head,n=0;i!==this.header;)r(i.value,n++),i=i.next},e.prototype.getElementByPos=function(r){B(r,0,this.length-1);for(var i=this.head;r--;)i=i.next;return i.value},e.prototype.eraseElementByPos=function(r){if(B(r,0,this.length-1),r===0)this.popFront();else if(r===this.length-1)this.popBack();else{for(var i=this.head;r--;)i=i.next;i=i;var n=i.pre,s=i.next;s.pre=n,n.next=s,this.length-=1}},e.prototype.eraseElementByValue=function(r){for(;this.head&&this.head.value===r;)this.popFront();for(;this.tail&&this.tail.value===r;)this.popBack();if(this.head)for(var i=this.head;i!==this.header;){if(i.value===r){var n=i.pre,s=i.next;s&&(s.pre=n),n&&(n.next=s),this.length-=1}i=i.next}},e.prototype.eraseElementByIterator=function(r){var i=r.node;if(i===this.header)throw new RangeError("Invalid iterator");if(r=r.next(),this.head===i)this.popFront();else if(this.tail===i)this.popBack();else{var n=i.pre,s=i.next;s&&(s.pre=n),n&&(n.next=s),this.length-=1}return r},e.prototype.pushBack=function(r){this.length+=1;var i=new Kt(r);this.tail?(this.tail.next=i,i.pre=this.tail,this.tail=i):(this.head=this.tail=i,this.header.next=this.head,this.head.pre=this.header),this.tail.next=this.header,this.header.pre=this.tail},e.prototype.popBack=function(){this.tail&&(this.length-=1,this.head===this.tail?(this.head=this.tail=void 0,this.header.next=void 0):(this.tail=this.tail.pre,this.tail&&(this.tail.next=void 0)),this.header.pre=this.tail,this.tail&&(this.tail.next=this.header))},e.prototype.setElementByPos=function(r,i){B(r,0,this.length-1);for(var n=this.head;r--;)n=n.next;n.value=i},e.prototype.insert=function(r,i,n){if(n===void 0&&(n=1),B(r,0,this.length),!(n<=0))if(r===0)for(;n--;)this.pushFront(i);else if(r===this.length)for(;n--;)this.pushBack(i);else{for(var s=this.head,o=1;o<r;++o)s=s.next;var a=s.next;for(this.length+=n;n--;)s.next=new Kt(i),s.next.pre=s,s=s.next;s.next=a,a&&(a.pre=s)}},e.prototype.find=function(r){if(!this.head)return this.end();for(var i=this.head;i!==this.header;){if(i.value===r)return new lt(i,this.header);i=i.next}return this.end()},e.prototype.reverse=function(){if(!(this.length<=1))for(var r=this.head,i=this.tail,n=0;n<<1<this.length;){var s=r.value;r.value=i.value,i.value=s,r=r.next,i=i.pre,n+=1}},e.prototype.unique=function(){if(!(this.length<=1))for(var r=this.head;r!==this.header;){for(var i=r;i.next&&i.value===i.next.value;)i=i.next,this.length-=1;r.next=i.next,r.next&&(r.next.pre=r),r=r.next}},e.prototype.sort=function(r){if(!(this.length<=1)){var i=[];this.forEach(function(s){return i.push(s)}),i.sort(r);var n=this.head;i.forEach(function(s){n.value=s,n=n.next})}},e.prototype.pushFront=function(r){this.length+=1;var i=new Kt(r);this.head?(i.next=this.head,this.head.pre=i,this.head=i):(this.head=this.tail=i,this.tail.next=this.header,this.header.pre=this.tail),this.header.next=this.head,this.head.pre=this.header},e.prototype.popFront=function(){this.head&&(this.length-=1,this.head===this.tail?(this.head=this.tail=void 0,this.header.pre=this.tail):(this.head=this.head.next,this.head&&(this.head.pre=this.header)),this.header.next=this.head)},e.prototype.merge=function(r){var i=this;if(!this.head){r.forEach(function(s){return i.pushBack(s)});return}var n=this.head;r.forEach(function(s){for(;n&&n!==i.header&&n.value<=s;)n=n.next;if(n===i.header)i.pushBack(s),n=i.tail;else if(n===i.head)i.pushFront(s),n=i.head;else{i.length+=1;var o=n.pre;o.next=new Kt(s),o.next.pre=o,o.next.next=n,n.pre=o.next}})},e.prototype[Symbol.iterator]=function(){return function(){var r;return ih(this,function(i){switch(i.label){case 0:if(!this.head)return[2];r=this.head,i.label=1;case 1:return r===this.header?[3,3]:[4,r.value];case 2:return i.sent(),r=r.next,[3,1];case 3:return[2]}})}.bind(this)()},e})(Ue),So=nh});var sh,w,xo=U(()=>{"use strict";sh=(function(){function t(e,r){this.color=!0,this.key=void 0,this.value=void 0,this.left=void 0,this.right=void 0,this.parent=void 0,this.key=e,this.value=r}return t.prototype.pre=function(){var e=this;if(e.color===t.RED&&e.parent.parent===e)e=e.right;else if(e.left)for(e=e.left;e.right;)e=e.right;else{for(var r=e.parent;r.left===e;)e=r,r=e.parent;e=r}return e},t.prototype.next=function(){var e=this;if(e.right)for(e=e.right;e.left;)e=e.left;else{for(var r=e.parent;r.right===e;)e=r,r=e.parent;e.right!==r&&(e=r)}return e},t.prototype.rotateLeft=function(){var e=this.parent,r=this.right,i=r.left;return e.parent===this?e.parent=r:e.left===this?e.left=r:e.right=r,r.parent=e,r.left=this,this.parent=r,this.right=i,i&&(i.parent=this),r},t.prototype.rotateRight=function(){var e=this.parent,r=this.left,i=r.right;return e.parent===this?e.parent=r:e.left===this?e.left=r:e.right=r,r.parent=e,r.right=this,this.parent=r,this.left=i,i&&(i.parent=this),r},t.prototype.remove=function(){var e=this.parent;this===e.left?e.left=void 0:e.right=void 0},t.RED=!0,t.BLACK=!1,t})(),w=sh});var oh,To,ah,xt,qr=U(()=>{"use strict";xo();Y();je();oh=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}})(),To=function(t,e){var r=typeof Symbol=="function"&&t[Symbol.iterator];if(!r)return t;var i=r.call(t),n,s=[],o;try{for(;(e===void 0||e-- >0)&&!(n=i.next()).done;)s.push(n.value)}catch(a){o={error:a}}finally{try{n&&!n.done&&(r=i.return)&&r.call(i)}finally{if(o)throw o.error}}return s},ah=(function(t){oh(e,t);function e(r){r===void 0&&(r=function(n,s){return n<s?-1:n>s?1:0});var i=t.call(this)||this;return i.root=void 0,i.header=new w,i.inOrderTraversal=function(n,s){if(n===void 0)return!1;var o=i.inOrderTraversal(n.left,s);return o||s(n)?!0:i.inOrderTraversal(n.right,s)},i.cmp=r,i}return e.prototype._lowerBound=function(r,i){for(var n;r;){var s=this.cmp(r.key,i);if(s<0)r=r.right;else if(s>0)n=r,r=r.left;else return r}return n===void 0?this.header:n},e.prototype._upperBound=function(r,i){for(var n;r;){var s=this.cmp(r.key,i);s<=0?r=r.right:s>0&&(n=r,r=r.left)}return n===void 0?this.header:n},e.prototype._reverseLowerBound=function(r,i){for(var n;r;){var s=this.cmp(r.key,i);if(s<0)n=r,r=r.right;else if(s>0)r=r.left;else return r}return n===void 0?this.header:n},e.prototype._reverseUpperBound=function(r,i){for(var n;r;){var s=this.cmp(r.key,i);s<0?(n=r,r=r.right):s>=0&&(r=r.left)}return n===void 0?this.header:n},e.prototype.eraseNodeSelfBalance=function(r){for(;;){var i=r.parent;if(i===this.header)return;if(r.color===w.RED){r.color=w.BLACK;return}if(r===i.left){var n=i.right;if(n.color===w.RED)n.color=w.BLACK,i.color=w.RED,i===this.root?this.root=i.rotateLeft():i.rotateLeft();else if(n.color===w.BLACK)if(n.right&&n.right.color===w.RED){n.color=i.color,i.color=w.BLACK,n.right.color=w.BLACK,i===this.root?this.root=i.rotateLeft():i.rotateLeft();return}else n.left&&n.left.color===w.RED?(n.color=w.RED,n.left.color=w.BLACK,n.rotateRight()):(n.color=w.RED,r=i)}else{var n=i.left;if(n.color===w.RED)n.color=w.BLACK,i.color=w.RED,i===this.root?this.root=i.rotateRight():i.rotateRight();else if(n.left&&n.left.color===w.RED){n.color=i.color,i.color=w.BLACK,n.left.color=w.BLACK,i===this.root?this.root=i.rotateRight():i.rotateRight();return}else n.right&&n.right.color===w.RED?(n.color=w.RED,n.right.color=w.BLACK,n.rotateLeft()):(n.color=w.RED,r=i)}}},e.prototype.eraseNode=function(r){var i,n;if(this.length===1){this.clear();return}for(var s=r;s.left||s.right;){if(s.right)for(s=s.right;s.left;)s=s.left;else s.left&&(s=s.left);i=To([s.key,r.key],2),r.key=i[0],s.key=i[1],n=To([s.value,r.value],2),r.value=n[0],s.value=n[1],r=s}this.header.left===s?this.header.left=s.parent:this.header.right===s&&(this.header.right=s.parent),this.eraseNodeSelfBalance(s),s.remove(),this.length-=1,this.root.color=w.BLACK},e.prototype.insertNodeSelfBalance=function(r){for(;;){var i=r.parent;if(i.color===w.BLACK)return;var n=i.parent;if(i===n.left){var s=n.right;if(s&&s.color===w.RED){if(s.color=i.color=w.BLACK,n===this.root)return;n.color=w.RED,r=n;continue}else if(r===i.right){if(r.color=w.BLACK,r.left&&(r.left.parent=i),r.right&&(r.right.parent=n),i.right=r.left,n.left=r.right,r.left=i,r.right=n,n===this.root)this.root=r,this.header.parent=r;else{var o=n.parent;o.left===n?o.left=r:o.right=r}r.parent=n.parent,i.parent=r,n.parent=r}else i.color=w.BLACK,n===this.root?this.root=n.rotateRight():n.rotateRight();n.color=w.RED}else{var s=n.left;if(s&&s.color===w.RED){if(s.color=i.color=w.BLACK,n===this.root)return;n.color=w.RED,r=n;continue}else if(r===i.left){if(r.color=w.BLACK,r.left&&(r.left.parent=n),r.right&&(r.right.parent=i),n.right=r.left,i.left=r.right,r.left=n,r.right=i,n===this.root)this.root=r,this.header.parent=r;else{var o=n.parent;o.left===n?o.left=r:o.right=r}r.parent=n.parent,i.parent=r,n.parent=r}else i.color=w.BLACK,n===this.root?this.root=n.rotateLeft():n.rotateLeft();n.color=w.RED}return}},e.prototype.findElementNode=function(r,i){for(;r;){var n=this.cmp(r.key,i);if(n<0)r=r.right;else if(n>0)r=r.left;else return r}return r},e.prototype.set=function(r,i,n){if(this.root===void 0){this.length+=1,this.root=new w(r,i),this.root.color=w.BLACK,this.root.parent=this.header,this.header.parent=this.root,this.header.left=this.root,this.header.right=this.root;return}var s,o=this.header.left,a=this.cmp(o.key,r);if(a===0){o.value=i;return}else if(a>0)o.left=new w(r,i),o.left.parent=o,s=o.left,this.header.left=s;else{var u=this.header.right,l=this.cmp(u.key,r);if(l===0){u.value=i;return}else if(l<0)u.right=new w(r,i),u.right.parent=u,s=u.right,this.header.right=s;else{if(n!==void 0){var f=n.node;if(f!==this.header){var h=this.cmp(f.key,r);if(h===0){f.value=i;return}else if(h>0){var c=f.pre(),d=this.cmp(c.key,r);if(d===0){c.value=i;return}else d<0&&(s=new w(r,i),c.right===void 0?(c.right=s,s.parent=c):(f.left=s,s.parent=f))}}}if(s===void 0)for(s=this.root;;){var m=this.cmp(s.key,r);if(m>0){if(s.left===void 0){s.left=new w(r,i),s.left.parent=s,s=s.left;break}s=s.left}else if(m<0){if(s.right===void 0){s.right=new w(r,i),s.right.parent=s,s=s.right;break}s=s.right}else{s.value=i;return}}}}this.length+=1,this.insertNodeSelfBalance(s)},e.prototype.clear=function(){this.length=0,this.root=void 0,this.header.parent=void 0,this.header.left=this.header.right=void 0},e.prototype.updateKeyByIterator=function(r,i){var n=r.node;if(n===this.header)throw new TypeError("Invalid iterator!");if(this.length===1)return n.key=i,!0;if(n===this.header.left)return this.cmp(n.next().key,i)>0?(n.key=i,!0):!1;if(n===this.header.right)return this.cmp(n.pre().key,i)<0?(n.key=i,!0):!1;var s=n.pre().key;if(this.cmp(s,i)>=0)return!1;var o=n.next().key;return this.cmp(o,i)<=0?!1:(n.key=i,!0)},e.prototype.eraseElementByPos=function(r){var i=this;B(r,0,this.length-1);var n=0;this.inOrderTraversal(this.root,function(s){return r===n?(i.eraseNode(s),!0):(n+=1,!1)})},e.prototype.eraseElementByKey=function(r){if(this.length){var i=this.findElementNode(this.root,r);i!==void 0&&this.eraseNode(i)}},e.prototype.eraseElementByIterator=function(r){var i=r.node;if(i===this.header)throw new RangeError("Invalid iterator");return i.right===void 0&&(r=r.next()),this.eraseNode(i),r},e.prototype.getHeight=function(){if(!this.length)return 0;var r=function(i){return i?Math.max(r(i.left),r(i.right))+1:0};return r(this.root)},e})(Et),xt=ah});var lh,uh,Nr,zi=U(()=>{"use strict";Y();lh=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}})(),uh=(function(t){lh(e,t);function e(r,i,n){var s=t.call(this,n)||this;return s.node=r,s.header=i,s.iteratorType===A.NORMAL?(s.pre=function(){if(this.node===this.header.left)throw new RangeError("LinkList iterator access denied!");return this.node=this.node.pre(),this},s.next=function(){if(this.node===this.header)throw new RangeError("LinkList iterator access denied!");return this.node=this.node.next(),this}):(s.pre=function(){if(this.node===this.header.right)throw new RangeError("LinkList iterator access denied!");return this.node=this.node.next(),this},s.next=function(){if(this.node===this.header)throw new RangeError("LinkList iterator access denied!");return this.node=this.node.pre(),this}),s}return e.prototype.equals=function(r){return this.node===r.node},e})(A),Nr=uh});var Co,fh,Dr,fe,ch,Ce,$i=U(()=>{"use strict";qr();Y();je();zi();Co=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}})(),fh=function(t,e){var r={label:0,sent:function(){if(s[0]&1)throw s[1];return s[1]},trys:[],ops:[]},i,n,s,o;return o={next:a(0),throw:a(1),return:a(2)},typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function a(l){return function(f){return u([l,f])}}function u(l){if(i)throw new TypeError("Generator is already executing.");for(;r;)try{if(i=1,n&&(s=l[0]&2?n.return:l[0]?n.throw||((s=n.return)&&s.call(n),0):n.next)&&!(s=s.call(n,l[1])).done)return s;switch(n=0,s&&(l=[l[0]&2,s.value]),l[0]){case 0:case 1:s=l;break;case 4:return r.label++,{value:l[1],done:!1};case 5:r.label++,n=l[1],l=[0];continue;case 7:l=r.ops.pop(),r.trys.pop();continue;default:if(s=r.trys,!(s=s.length>0&&s[s.length-1])&&(l[0]===6||l[0]===2)){r=0;continue}if(l[0]===3&&(!s||l[1]>s[0]&&l[1]<s[3])){r.label=l[1];break}if(l[0]===6&&r.label<s[1]){r.label=s[1],s=l;break}if(s&&r.label<s[2]){r.label=s[2],r.ops.push(l);break}s[2]&&r.ops.pop(),r.trys.pop();continue}l=e.call(t,r)}catch(f){l=[6,f],n=0}finally{i=s=0}if(l[0]&5)throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}},Dr=function(t){var e=typeof Symbol=="function"&&Symbol.iterator,r=e&&t[e],i=0;if(r)return r.call(t);if(t&&typeof t.length=="number")return{next:function(){return t&&i>=t.length&&(t=void 0),{value:t&&t[i++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},fe=(function(t){Co(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return Object.defineProperty(e.prototype,"pointer",{get:function(){if(this.node===this.header)throw new RangeError("OrderedSet iterator access denied!");return this.node.key},enumerable:!1,configurable:!0}),e.prototype.copy=function(){return new e(this.node,this.header,this.iteratorType)},e})(Nr),ch=(function(t){Co(e,t);function e(r,i){r===void 0&&(r=[]);var n=t.call(this,i)||this;return n.iterationFunc=function(s){return fh(this,function(o){switch(o.label){case 0:return s===void 0?[2]:[5,Dr(this.iterationFunc(s.left))];case 1:return o.sent(),[4,s.key];case 2:return o.sent(),[5,Dr(this.iterationFunc(s.right))];case 3:return o.sent(),[2]}})},r.forEach(function(s){return n.insert(s)}),n.iterationFunc=n.iterationFunc.bind(n),n}return e.prototype.begin=function(){return new fe(this.header.left||this.header,this.header)},e.prototype.end=function(){return new fe(this.header,this.header)},e.prototype.rBegin=function(){return new fe(this.header.right||this.header,this.header,A.REVERSE)},e.prototype.rEnd=function(){return new fe(this.header,this.header,A.REVERSE)},e.prototype.front=function(){return this.header.left?this.header.left.key:void 0},e.prototype.back=function(){return this.header.right?this.header.right.key:void 0},e.prototype.forEach=function(r){var i,n,s=0;try{for(var o=Dr(this),a=o.next();!a.done;a=o.next()){var u=a.value;r(u,s++)}}catch(l){i={error:l}}finally{try{a&&!a.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}},e.prototype.getElementByPos=function(r){var i,n;B(r,0,this.length-1);var s,o=0;try{for(var a=Dr(this),u=a.next();!u.done;u=a.next()){var l=u.value;o===r&&(s=l),o+=1}}catch(f){i={error:f}}finally{try{u&&!u.done&&(n=a.return)&&n.call(a)}finally{if(i)throw i.error}}return s},e.prototype.insert=function(r,i){this.set(r,void 0,i)},e.prototype.find=function(r){var i=this.findElementNode(this.root,r);return i!==void 0?new fe(i,this.header):this.end()},e.prototype.lowerBound=function(r){var i=this._lowerBound(this.root,r);return new fe(i,this.header)},e.prototype.upperBound=function(r){var i=this._upperBound(this.root,r);return new fe(i,this.header)},e.prototype.reverseLowerBound=function(r){var i=this._reverseLowerBound(this.root,r);return new fe(i,this.header)},e.prototype.reverseUpperBound=function(r){var i=this._reverseUpperBound(this.root,r);return new fe(i,this.header)},e.prototype.union=function(r){var i=this;r.forEach(function(n){return i.insert(n)})},e.prototype[Symbol.iterator]=function(){return this.iterationFunc(this.root)},e})(xt),Ce=ch});var Oo,hh,Po,Ur,ce,dh,he,Gi=U(()=>{"use strict";Y();je();qr();zi();Oo=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}})(),hh=function(t,e){var r={label:0,sent:function(){if(s[0]&1)throw s[1];return s[1]},trys:[],ops:[]},i,n,s,o;return o={next:a(0),throw:a(1),return:a(2)},typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function a(l){return function(f){return u([l,f])}}function u(l){if(i)throw new TypeError("Generator is already executing.");for(;r;)try{if(i=1,n&&(s=l[0]&2?n.return:l[0]?n.throw||((s=n.return)&&s.call(n),0):n.next)&&!(s=s.call(n,l[1])).done)return s;switch(n=0,s&&(l=[l[0]&2,s.value]),l[0]){case 0:case 1:s=l;break;case 4:return r.label++,{value:l[1],done:!1};case 5:r.label++,n=l[1],l=[0];continue;case 7:l=r.ops.pop(),r.trys.pop();continue;default:if(s=r.trys,!(s=s.length>0&&s[s.length-1])&&(l[0]===6||l[0]===2)){r=0;continue}if(l[0]===3&&(!s||l[1]>s[0]&&l[1]<s[3])){r.label=l[1];break}if(l[0]===6&&r.label<s[1]){r.label=s[1],s=l;break}if(s&&r.label<s[2]){r.label=s[2],r.ops.push(l);break}s[2]&&r.ops.pop(),r.trys.pop();continue}l=e.call(t,r)}catch(f){l=[6,f],n=0}finally{i=s=0}if(l[0]&5)throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}},Po=function(t,e){var r=typeof Symbol=="function"&&t[Symbol.iterator];if(!r)return t;var i=r.call(t),n,s=[],o;try{for(;(e===void 0||e-- >0)&&!(n=i.next()).done;)s.push(n.value)}catch(a){o={error:a}}finally{try{n&&!n.done&&(r=i.return)&&r.call(i)}finally{if(o)throw o.error}}return s},Ur=function(t){var e=typeof Symbol=="function"&&Symbol.iterator,r=e&&t[e],i=0;if(r)return r.call(t);if(t&&typeof t.length=="number")return{next:function(){return t&&i>=t.length&&(t=void 0),{value:t&&t[i++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},ce=(function(t){Oo(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return Object.defineProperty(e.prototype,"pointer",{get:function(){var r=this;if(this.node===this.header)throw new RangeError("OrderedMap iterator access denied");return new Proxy([],{get:function(i,n){if(n==="0")return r.node.key;if(n==="1")return r.node.value},set:function(i,n,s){if(n!=="1")throw new TypeError("props must be 1");return r.node.value=s,!0}})},enumerable:!1,configurable:!0}),e.prototype.copy=function(){return new e(this.node,this.header,this.iteratorType)},e})(Nr),dh=(function(t){Oo(e,t);function e(r,i){r===void 0&&(r=[]);var n=t.call(this,i)||this;return n.iterationFunc=function(s){return hh(this,function(o){switch(o.label){case 0:return s===void 0?[2]:[5,Ur(this.iterationFunc(s.left))];case 1:return o.sent(),[4,[s.key,s.value]];case 2:return o.sent(),[5,Ur(this.iterationFunc(s.right))];case 3:return o.sent(),[2]}})},n.iterationFunc=n.iterationFunc.bind(n),r.forEach(function(s){var o=Po(s,2),a=o[0],u=o[1];return n.setElement(a,u)}),n}return e.prototype.begin=function(){return new ce(this.header.left||this.header,this.header)},e.prototype.end=function(){return new ce(this.header,this.header)},e.prototype.rBegin=function(){return new ce(this.header.right||this.header,this.header,A.REVERSE)},e.prototype.rEnd=function(){return new ce(this.header,this.header,A.REVERSE)},e.prototype.front=function(){if(this.length){var r=this.header.left;return[r.key,r.value]}},e.prototype.back=function(){if(this.length){var r=this.header.right;return[r.key,r.value]}},e.prototype.forEach=function(r){var i,n,s=0;try{for(var o=Ur(this),a=o.next();!a.done;a=o.next()){var u=a.value;r(u,s++)}}catch(l){i={error:l}}finally{try{a&&!a.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}},e.prototype.lowerBound=function(r){var i=this._lowerBound(this.root,r);return new ce(i,this.header)},e.prototype.upperBound=function(r){var i=this._upperBound(this.root,r);return new ce(i,this.header)},e.prototype.reverseLowerBound=function(r){var i=this._reverseLowerBound(this.root,r);return new ce(i,this.header)},e.prototype.reverseUpperBound=function(r){var i=this._reverseUpperBound(this.root,r);return new ce(i,this.header)},e.prototype.setElement=function(r,i,n){this.set(r,i,n)},e.prototype.find=function(r){var i=this.findElementNode(this.root,r);return i!==void 0?new ce(i,this.header):this.end()},e.prototype.getElementByKey=function(r){var i=this.findElementNode(this.root,r);return i?i.value:void 0},e.prototype.getElementByPos=function(r){var i,n;B(r,0,this.length-1);var s,o=0;try{for(var a=Ur(this),u=a.next();!u.done;u=a.next()){var l=u.value;if(o===r){s=l;break}o+=1}}catch(f){i={error:f}}finally{try{u&&!u.done&&(n=a.return)&&n.call(a)}finally{if(i)throw i.error}}return s},e.prototype.union=function(r){var i=this;r.forEach(function(n){var s=Po(n,2),o=s[0],a=s[1];return i.setElement(o,a)})},e.prototype[Symbol.iterator]=function(){return this.iterationFunc(this.root)},e})(xt),he=dh});var ph,gh,q,jr=U(()=>{"use strict";Y();ph=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}})(),gh=(function(t){ph(e,t);function e(r,i){r===void 0&&(r=16),i===void 0&&(i=function(s){var o;typeof s!="string"?o=JSON.stringify(s):o=s;for(var a=0,u=o.length,l=0;l<u;l++){var f=o.charCodeAt(l);a=(a<<5)-a+f,a|=0}return a>>>0});var n=t.call(this)||this;if(r<16||(r&r-1)!==0)throw new RangeError("InitBucketNum range error");return n.bucketNum=n.initBucketNum=r,n.hashFunc=i,n}return e.prototype.clear=function(){this.length=0,this.bucketNum=this.initBucketNum,this.hashTable=[]},e.sigma=.75,e.treeifyThreshold=8,e.untreeifyThreshold=6,e.minTreeifySize=64,e.maxBucketNum=1<<30,e})(Te),q=gh});var yh,_h,mh,vh,Io,Ro=U(()=>{"use strict";jr();Mr();$i();yh=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}})(),_h=function(t,e){var r={label:0,sent:function(){if(s[0]&1)throw s[1];return s[1]},trys:[],ops:[]},i,n,s,o;return o={next:a(0),throw:a(1),return:a(2)},typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function a(l){return function(f){return u([l,f])}}function u(l){if(i)throw new TypeError("Generator is already executing.");for(;r;)try{if(i=1,n&&(s=l[0]&2?n.return:l[0]?n.throw||((s=n.return)&&s.call(n),0):n.next)&&!(s=s.call(n,l[1])).done)return s;switch(n=0,s&&(l=[l[0]&2,s.value]),l[0]){case 0:case 1:s=l;break;case 4:return r.label++,{value:l[1],done:!1};case 5:r.label++,n=l[1],l=[0];continue;case 7:l=r.ops.pop(),r.trys.pop();continue;default:if(s=r.trys,!(s=s.length>0&&s[s.length-1])&&(l[0]===6||l[0]===2)){r=0;continue}if(l[0]===3&&(!s||l[1]>s[0]&&l[1]<s[3])){r.label=l[1];break}if(l[0]===6&&r.label<s[1]){r.label=s[1],s=l;break}if(s&&r.label<s[2]){r.label=s[2],r.ops.push(l);break}s[2]&&r.ops.pop(),r.trys.pop();continue}l=e.call(t,r)}catch(f){l=[6,f],n=0}finally{i=s=0}if(l[0]&5)throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}},mh=function(t){var e=typeof Symbol=="function"&&Symbol.iterator,r=e&&t[e],i=0;if(r)return r.call(t);if(t&&typeof t.length=="number")return{next:function(){return t&&i>=t.length&&(t=void 0),{value:t&&t[i++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},vh=(function(t){yh(e,t);function e(r,i,n){r===void 0&&(r=[]);var s=t.call(this,i,n)||this;return s.hashTable=[],r.forEach(function(o){return s.insert(o)}),s}return e.prototype.reAllocate=function(){var r=this;if(!(this.bucketNum>=q.maxBucketNum)){var i=[],n=this.bucketNum;this.bucketNum<<=1;for(var s=Object.keys(this.hashTable),o=s.length,a=function(f){var h=parseInt(s[f]),c=u.hashTable[h],d=c.size();if(d===0)return"continue";if(d===1){var m=c.front();return i[u.hashFunc(m)&u.bucketNum-1]=new M([m],!1),"continue"}var y=[],v=[];c.forEach(function(b){var C=r.hashFunc(b);(C&n)===0?y.push(b):v.push(b)}),c instanceof Ce?(y.length>q.untreeifyThreshold?i[h]=new Ce(y):y.length&&(i[h]=new M(y,!1)),v.length>q.untreeifyThreshold?i[h+n]=new Ce(v):v.length&&(i[h+n]=new M(v,!1))):(y.length>=q.treeifyThreshold?i[h]=new Ce(y):y.length&&(i[h]=new M(y,!1)),v.length>=q.treeifyThreshold?i[h+n]=new Ce(v):v.length&&(i[h+n]=new M(v,!1)))},u=this,l=0;l<o;++l)a(l);this.hashTable=i}},e.prototype.forEach=function(r){for(var i=Object.values(this.hashTable),n=i.length,s=0,o=0;o<n;++o)i[o].forEach(function(a){return r(a,s++)})},e.prototype.insert=function(r){var i=this.hashFunc(r)&this.bucketNum-1,n=this.hashTable[i];if(!n)this.hashTable[i]=new M([r],!1),this.length+=1;else{var s=n.size();if(n instanceof M){if(!n.find(r).equals(n.end()))return;if(n.pushBack(r),s+1>=q.treeifyThreshold){if(this.bucketNum<=q.minTreeifySize){this.length+=1,this.reAllocate();return}this.hashTable[i]=new Ce(n)}this.length+=1}else{n.insert(r);var o=n.size();this.length+=o-s}}this.length>this.bucketNum*q.sigma&&this.reAllocate()},e.prototype.eraseElementByKey=function(r){var i=this.hashFunc(r)&this.bucketNum-1,n=this.hashTable[i];if(n){var s=n.size();if(s!==0)if(n instanceof M){n.eraseElementByValue(r);var o=n.size();this.length+=o-s}else{n.eraseElementByKey(r);var o=n.size();this.length+=o-s,o<=q.untreeifyThreshold&&(this.hashTable[i]=new M(n))}}},e.prototype.find=function(r){var i=this.hashFunc(r)&this.bucketNum-1,n=this.hashTable[i];return n?!n.find(r).equals(n.end()):!1},e.prototype[Symbol.iterator]=function(){return function(){var r,i,n,s,o,a,u,l,f,h;return _h(this,function(c){switch(c.label){case 0:r=Object.values(this.hashTable),i=r.length,n=0,c.label=1;case 1:if(!(n<i))return[3,10];s=r[n],c.label=2;case 2:c.trys.push([2,7,8,9]),o=(f=void 0,mh(s)),a=o.next(),c.label=3;case 3:return a.done?[3,6]:(u=a.value,[4,u]);case 4:c.sent(),c.label=5;case 5:return a=o.next(),[3,3];case 6:return[3,9];case 7:return l=c.sent(),f={error:l},[3,9];case 8:try{a&&!a.done&&(h=o.return)&&h.call(o)}finally{if(f)throw f.error}return[7];case 9:return++n,[3,1];case 10:return[2]}})}.bind(this)()},e})(q),Io=vh});var bh,wh,zt,Sh,Ao,Bo=U(()=>{"use strict";jr();Mr();Gi();bh=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}})(),wh=function(t,e){var r={label:0,sent:function(){if(s[0]&1)throw s[1];return s[1]},trys:[],ops:[]},i,n,s,o;return o={next:a(0),throw:a(1),return:a(2)},typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function a(l){return function(f){return u([l,f])}}function u(l){if(i)throw new TypeError("Generator is already executing.");for(;r;)try{if(i=1,n&&(s=l[0]&2?n.return:l[0]?n.throw||((s=n.return)&&s.call(n),0):n.next)&&!(s=s.call(n,l[1])).done)return s;switch(n=0,s&&(l=[l[0]&2,s.value]),l[0]){case 0:case 1:s=l;break;case 4:return r.label++,{value:l[1],done:!1};case 5:r.label++,n=l[1],l=[0];continue;case 7:l=r.ops.pop(),r.trys.pop();continue;default:if(s=r.trys,!(s=s.length>0&&s[s.length-1])&&(l[0]===6||l[0]===2)){r=0;continue}if(l[0]===3&&(!s||l[1]>s[0]&&l[1]<s[3])){r.label=l[1];break}if(l[0]===6&&r.label<s[1]){r.label=s[1],s=l;break}if(s&&r.label<s[2]){r.label=s[2],r.ops.push(l);break}s[2]&&r.ops.pop(),r.trys.pop();continue}l=e.call(t,r)}catch(f){l=[6,f],n=0}finally{i=s=0}if(l[0]&5)throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}},zt=function(t){var e=typeof Symbol=="function"&&Symbol.iterator,r=e&&t[e],i=0;if(r)return r.call(t);if(t&&typeof t.length=="number")return{next:function(){return t&&i>=t.length&&(t=void 0),{value:t&&t[i++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},Sh=(function(t){bh(e,t);function e(r,i,n){r===void 0&&(r=[]);var s=t.call(this,i,n)||this;return s.hashTable=[],r.forEach(function(o){return s.setElement(o[0],o[1])}),s}return e.prototype.reAllocate=function(){var r=this;if(!(this.bucketNum>=q.maxBucketNum)){var i=[],n=this.bucketNum;this.bucketNum<<=1;for(var s=Object.keys(this.hashTable),o=s.length,a=function(f){var h=parseInt(s[f]),c=u.hashTable[h],d=c.size();if(d===0)return"continue";if(d===1){var m=c.front();return i[u.hashFunc(m[0])&u.bucketNum-1]=new M([m],!1),"continue"}var y=[],v=[];c.forEach(function(b){var C=r.hashFunc(b[0]);(C&n)===0?y.push(b):v.push(b)}),c instanceof he?(y.length>q.untreeifyThreshold?i[h]=new he(y):y.length&&(i[h]=new M(y,!1)),v.length>q.untreeifyThreshold?i[h+n]=new he(v):v.length&&(i[h+n]=new M(v,!1))):(y.length>=q.treeifyThreshold?i[h]=new he(y):y.length&&(i[h]=new M(y,!1)),v.length>=q.treeifyThreshold?i[h+n]=new he(v):v.length&&(i[h+n]=new M(v,!1)))},u=this,l=0;l<o;++l)a(l);this.hashTable=i}},e.prototype.forEach=function(r){for(var i=Object.values(this.hashTable),n=i.length,s=0,o=0;o<n;++o)i[o].forEach(function(a){return r(a,s++)})},e.prototype.setElement=function(r,i){var n,s,o=this.hashFunc(r)&this.bucketNum-1,a=this.hashTable[o];if(!a)this.length+=1,this.hashTable[o]=new M([[r,i]],!1);else{var u=a.size();if(a instanceof M){try{for(var l=zt(a),f=l.next();!f.done;f=l.next()){var h=f.value;if(h[0]===r){h[1]=i;return}}}catch(d){n={error:d}}finally{try{f&&!f.done&&(s=l.return)&&s.call(l)}finally{if(n)throw n.error}}if(a.pushBack([r,i]),u+1>=e.treeifyThreshold){if(this.bucketNum<=e.minTreeifySize){this.length+=1,this.reAllocate();return}this.hashTable[o]=new he(this.hashTable[o])}this.length+=1}else{a.setElement(r,i);var c=a.size();this.length+=c-u}}this.length>this.bucketNum*e.sigma&&this.reAllocate()},e.prototype.getElementByKey=function(r){var i,n,s=this.hashFunc(r)&this.bucketNum-1,o=this.hashTable[s];if(o){if(o instanceof he)return o.getElementByKey(r);try{for(var a=zt(o),u=a.next();!u.done;u=a.next()){var l=u.value;if(l[0]===r)return l[1]}}catch(f){i={error:f}}finally{try{u&&!u.done&&(n=a.return)&&n.call(a)}finally{if(i)throw i.error}}}},e.prototype.eraseElementByKey=function(r){var i,n,s=this.hashFunc(r)&this.bucketNum-1,o=this.hashTable[s];if(o)if(o instanceof M){var a=0;try{for(var u=zt(o),l=u.next();!l.done;l=u.next()){var f=l.value;if(f[0]===r){o.eraseElementByPos(a),this.length-=1;return}a+=1}}catch(d){i={error:d}}finally{try{l&&!l.done&&(n=u.return)&&n.call(u)}finally{if(i)throw i.error}}}else{var h=o.size();o.eraseElementByKey(r);var c=o.size();this.length+=c-h,c<=q.untreeifyThreshold&&(this.hashTable[s]=new M(o))}},e.prototype.find=function(r){var i,n,s=this.hashFunc(r)&this.bucketNum-1,o=this.hashTable[s];if(!o)return!1;if(o instanceof he)return!o.find(r).equals(o.end());try{for(var a=zt(o),u=a.next();!u.done;u=a.next()){var l=u.value;if(l[0]===r)return!0}}catch(f){i={error:f}}finally{try{u&&!u.done&&(n=a.return)&&n.call(a)}finally{if(i)throw i.error}}return!1},e.prototype[Symbol.iterator]=function(){return function(){var r,i,n,s,o,a,u,l,f,h;return wh(this,function(c){switch(c.label){case 0:r=Object.values(this.hashTable),i=r.length,n=0,c.label=1;case 1:if(!(n<i))return[3,10];s=r[n],c.label=2;case 2:c.trys.push([2,7,8,9]),o=(f=void 0,zt(s)),a=o.next(),c.label=3;case 3:return a.done?[3,6]:(u=a.value,[4,u]);case 4:c.sent(),c.label=5;case 5:return a=o.next(),[3,3];case 6:return[3,9];case 7:return l=c.sent(),f={error:l},[3,9];case 8:try{a&&!a.done&&(h=o.return)&&h.call(o)}finally{if(f)throw f.error}return[7];case 9:return++n,[3,1];case 10:return[2]}})}.bind(this)()},e})(q),Ao=Sh});var ko={};Tu(ko,{Container:()=>Et,ContainerIterator:()=>A,Deque:()=>kr,DequeIterator:()=>ot,HashContainer:()=>q,HashMap:()=>Ao,HashSet:()=>Io,LinkList:()=>So,LinkListIterator:()=>lt,OrderedMap:()=>he,OrderedMapIterator:()=>ce,OrderedSet:()=>Ce,OrderedSetIterator:()=>fe,PriorityQueue:()=>yo,Queue:()=>po,SequentialContainer:()=>Ue,Stack:()=>fo,TreeContainer:()=>xt,Vector:()=>M,VectorIterator:()=>at});var Lo=U(()=>{"use strict";co();go();_o();Mr();Eo();Ki();$i();Gi();Ro();Bo();Y();Ht();qr();jr()});var qo=g((M_,Mo)=>{"use strict";var Tt=1e3,Ct=Tt*60,Pt=Ct*60,ut=Pt*24,Eh=ut*7,xh=ut*365.25;Mo.exports=function(t,e){e=e||{};var r=typeof t;if(r==="string"&&t.length>0)return Th(t);if(r==="number"&&isFinite(t))return e.long?Ph(t):Ch(t);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(t))};function Th(t){if(t=String(t),!(t.length>100)){var e=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(t);if(e){var r=parseFloat(e[1]),i=(e[2]||"ms").toLowerCase();switch(i){case"years":case"year":case"yrs":case"yr":case"y":return r*xh;case"weeks":case"week":case"w":return r*Eh;case"days":case"day":case"d":return r*ut;case"hours":case"hour":case"hrs":case"hr":case"h":return r*Pt;case"minutes":case"minute":case"mins":case"min":case"m":return r*Ct;case"seconds":case"second":case"secs":case"sec":case"s":return r*Tt;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return r;default:return}}}}function Ch(t){var e=Math.abs(t);return e>=ut?Math.round(t/ut)+"d":e>=Pt?Math.round(t/Pt)+"h":e>=Ct?Math.round(t/Ct)+"m":e>=Tt?Math.round(t/Tt)+"s":t+"ms"}function Ph(t){var e=Math.abs(t);return e>=ut?Fr(t,e,ut,"day"):e>=Pt?Fr(t,e,Pt,"hour"):e>=Ct?Fr(t,e,Ct,"minute"):e>=Tt?Fr(t,e,Tt,"second"):t+" ms"}function Fr(t,e,r,i){var n=e>=r*1.5;return Math.round(t/r)+" "+i+(n?"s":"")}});var Qi=g((q_,No)=>{"use strict";function Oh(t){r.debug=r,r.default=r,r.coerce=u,r.disable=o,r.enable=n,r.enabled=a,r.humanize=qo(),r.destroy=l,Object.keys(t).forEach(f=>{r[f]=t[f]}),r.names=[],r.skips=[],r.formatters={};function e(f){let h=0;for(let c=0;c<f.length;c++)h=(h<<5)-h+f.charCodeAt(c),h|=0;return r.colors[Math.abs(h)%r.colors.length]}r.selectColor=e;function r(f){let h,c=null,d,m;function y(...v){if(!y.enabled)return;let b=y,C=Number(new Date),D=C-(h||C);b.diff=D,b.prev=h,b.curr=C,h=C,v[0]=r.coerce(v[0]),typeof v[0]!="string"&&v.unshift("%O");let K=0;v[0]=v[0].replace(/%([a-zA-Z%])/g,(Xe,Bt)=>{if(Xe==="%%")return"%";K++;let hr=r.formatters[Bt];if(typeof hr=="function"){let vu=v[K];Xe=hr.call(b,vu),v.splice(K,1),K--}return Xe}),r.formatArgs.call(b,v),(b.log||r.log).apply(b,v)}return y.namespace=f,y.useColors=r.useColors(),y.color=r.selectColor(f),y.extend=i,y.destroy=r.destroy,Object.defineProperty(y,"enabled",{enumerable:!0,configurable:!1,get:()=>c!==null?c:(d!==r.namespaces&&(d=r.namespaces,m=r.enabled(f)),m),set:v=>{c=v}}),typeof r.init=="function"&&r.init(y),y}function i(f,h){let c=r(this.namespace+(typeof h>"u"?":":h)+f);return c.log=this.log,c}function n(f){r.save(f),r.namespaces=f,r.names=[],r.skips=[];let h=(typeof f=="string"?f:"").trim().replace(" ",",").split(",").filter(Boolean);for(let c of h)c[0]==="-"?r.skips.push(c.slice(1)):r.names.push(c)}function s(f,h){let c=0,d=0,m=-1,y=0;for(;c<f.length;)if(d<h.length&&(h[d]===f[c]||h[d]==="*"))h[d]==="*"?(m=d,y=c,d++):(c++,d++);else if(m!==-1)d=m+1,y++,c=y;else return!1;for(;d<h.length&&h[d]==="*";)d++;return d===h.length}function o(){let f=[...r.names,...r.skips.map(h=>"-"+h)].join(",");return r.enable(""),f}function a(f){for(let h of r.skips)if(s(f,h))return!1;for(let h of r.names)if(s(f,h))return!0;return!1}function u(f){return f instanceof Error?f.stack||f.message:f}function l(){console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")}return r.enable(r.load()),r}No.exports=Oh});var Do=g((te,Wr)=>{"use strict";te.formatArgs=Rh;te.save=Ah;te.load=Bh;te.useColors=Ih;te.storage=kh();te.destroy=(()=>{let t=!1;return()=>{t||(t=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."))}})();te.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"];function Ih(){if(typeof window<"u"&&window.process&&(window.process.type==="renderer"||window.process.__nwjs))return!0;if(typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))return!1;let t;return typeof document<"u"&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||typeof window<"u"&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||typeof navigator<"u"&&navigator.userAgent&&(t=navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/))&&parseInt(t[1],10)>=31||typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)}function Rh(t){if(t[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+t[0]+(this.useColors?"%c ":" ")+"+"+Wr.exports.humanize(this.diff),!this.useColors)return;let e="color: "+this.color;t.splice(1,0,e,"color: inherit");let r=0,i=0;t[0].replace(/%[a-zA-Z%]/g,n=>{n!=="%%"&&(r++,n==="%c"&&(i=r))}),t.splice(i,0,e)}te.log=console.debug||console.log||(()=>{});function Ah(t){try{t?te.storage.setItem("debug",t):te.storage.removeItem("debug")}catch{}}function Bh(){let t;try{t=te.storage.getItem("debug")}catch{}return!t&&typeof process<"u"&&"env"in process&&(t=process.env.DEBUG),t}function kh(){try{return localStorage}catch{}}Wr.exports=Qi()(te);var{formatters:Lh}=Wr.exports;Lh.j=function(t){try{return JSON.stringify(t)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}});var jo=g((N_,Uo)=>{"use strict";Uo.exports=(t,e=process.argv)=>{let r=t.startsWith("-")?"":t.length===1?"-":"--",i=e.indexOf(r+t),n=e.indexOf("--");return i!==-1&&(n===-1||i<n)}});var Vo=g((D_,Wo)=>{"use strict";var Mh=require("os"),Fo=require("tty"),oe=jo(),{env:V}=process,Fe;oe("no-color")||oe("no-colors")||oe("color=false")||oe("color=never")?Fe=0:(oe("color")||oe("colors")||oe("color=true")||oe("color=always"))&&(Fe=1);"FORCE_COLOR"in V&&(V.FORCE_COLOR==="true"?Fe=1:V.FORCE_COLOR==="false"?Fe=0:Fe=V.FORCE_COLOR.length===0?1:Math.min(parseInt(V.FORCE_COLOR,10),3));function Yi(t){return t===0?!1:{level:t,hasBasic:!0,has256:t>=2,has16m:t>=3}}function Xi(t,e){if(Fe===0)return 0;if(oe("color=16m")||oe("color=full")||oe("color=truecolor"))return 3;if(oe("color=256"))return 2;if(t&&!e&&Fe===void 0)return 0;let r=Fe||0;if(V.TERM==="dumb")return r;if(process.platform==="win32"){let i=Mh.release().split(".");return Number(i[0])>=10&&Number(i[2])>=10586?Number(i[2])>=14931?3:2:1}if("CI"in V)return["TRAVIS","CIRCLECI","APPVEYOR","GITLAB_CI","GITHUB_ACTIONS","BUILDKITE"].some(i=>i in V)||V.CI_NAME==="codeship"?1:r;if("TEAMCITY_VERSION"in V)return/^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(V.TEAMCITY_VERSION)?1:0;if(V.COLORTERM==="truecolor")return 3;if("TERM_PROGRAM"in V){let i=parseInt((V.TERM_PROGRAM_VERSION||"").split(".")[0],10);switch(V.TERM_PROGRAM){case"iTerm.app":return i>=3?3:2;case"Apple_Terminal":return 2}}return/-256(color)?$/i.test(V.TERM)?2:/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(V.TERM)||"COLORTERM"in V?1:r}function qh(t){let e=Xi(t,t&&t.isTTY);return Yi(e)}Wo.exports={supportsColor:qh,stdout:Yi(Xi(!0,Fo.isatty(1))),stderr:Yi(Xi(!0,Fo.isatty(2)))}});var Ko=g((H,Hr)=>{"use strict";var Nh=require("tty"),Vr=require("util");H.init=Hh;H.log=Fh;H.formatArgs=Uh;H.save=Wh;H.load=Vh;H.useColors=Dh;H.destroy=Vr.deprecate(()=>{},"Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.");H.colors=[6,2,3,4,5,1];try{let t=Vo();t&&(t.stderr||t).level>=2&&(H.colors=[20,21,26,27,32,33,38,39,40,41,42,43,44,45,56,57,62,63,68,69,74,75,76,77,78,79,80,81,92,93,98,99,112,113,128,129,134,135,148,149,160,161,162,163,164,165,166,167,168,169,170,171,172,173,178,179,184,185,196,197,198,199,200,201,202,203,204,205,206,207,208,209,214,215,220,221])}catch{}H.inspectOpts=Object.keys(process.env).filter(t=>/^debug_/i.test(t)).reduce((t,e)=>{let r=e.substring(6).toLowerCase().replace(/_([a-z])/g,(n,s)=>s.toUpperCase()),i=process.env[e];return/^(yes|on|true|enabled)$/i.test(i)?i=!0:/^(no|off|false|disabled)$/i.test(i)?i=!1:i==="null"?i=null:i=Number(i),t[r]=i,t},{});function Dh(){return"colors"in H.inspectOpts?!!H.inspectOpts.colors:Nh.isatty(process.stderr.fd)}function Uh(t){let{namespace:e,useColors:r}=this;if(r){let i=this.color,n="\x1B[3"+(i<8?i:"8;5;"+i),s=` ${n};1m${e} \x1B[0m`;t[0]=s+t[0].split(`
|
|
3
3
|
`).join(`
|
|
4
4
|
`+s),t.push(n+"m+"+Hr.exports.humanize(this.diff)+"\x1B[0m")}else t[0]=jh()+e+" "+t[0]}function jh(){return H.inspectOpts.hideDate?"":new Date().toISOString()+" "}function Fh(...t){return process.stderr.write(Vr.formatWithOptions(H.inspectOpts,...t)+`
|
|
5
5
|
`)}function Wh(t){t?process.env.DEBUG=t:delete process.env.DEBUG}function Vh(){return process.env.DEBUG}function Hh(t){t.inspectOpts={};let e=Object.keys(H.inspectOpts);for(let r=0;r<e.length;r++)t.inspectOpts[e[r]]=H.inspectOpts[e[r]]}Hr.exports=Qi()(H);var{formatters:Ho}=Hr.exports;Ho.o=function(t){return this.inspectOpts.colors=this.useColors,Vr.inspect(t,this.inspectOpts).split(`
|