w-hc2png 1.0.39 → 1.0.41

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.
@@ -1,110 +1,7 @@
1
1
  /*!
2
- * w-hc-2-png v1.0.39
2
+ * w-hc-2-png v1.0.41
3
3
  * (c) 2018-2021 yuda-lyu(semisphere)
4
4
  * Released under the MIT License.
5
5
  */
6
- !function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e(require("fs"),require("path"),require("puppeteer"),require("child_process"),require("stream"),require("constants"),require("util"),require("assert"),require("node:url"),require("node:path"),require("node:fs"),require("node:fs/promises"),require("node:events"),require("node:stream"),require("node:string_decoder"),require("zlib"),require("crypto")):"function"==typeof define&&define.amd?define(["fs","path","puppeteer","child_process","stream","constants","util","assert","node:url","node:path","node:fs","node:fs/promises","node:events","node:stream","node:string_decoder","zlib","crypto"],e):(t="undefined"!=typeof globalThis?globalThis:t||self)["w-hc-2-png"]=e(t.fs,t.path,t.puppeteer,t.require$$0,t.require$$0$1,t.require$$0$2,t.require$$0$3,t.require$$5,t.require$$2$2,t.require$$1$1,t.require$$4,t.require$$5$1,t.require$$0$4,t.require$$1,t.require$$2$1,t.require$$0$5,t.require$$2$3)}(this,function(t,e,r,n,i,o,s,a,l,u,c,h,f,d,p,y,g){"use strict";var b=Array.isArray,m="object"==typeof global&&global&&global.Object===Object&&global,v="object"==typeof self&&self&&self.Object===Object&&self,w=m||v||Function("return this")(),S=w.Symbol,E=Object.prototype,R=E.hasOwnProperty,k=E.toString,T=S?S.toStringTag:void 0;var x=Object.prototype.toString;var A=S?S.toStringTag:void 0;function O(t){return null==t?void 0===t?"[object Undefined]":"[object Null]":A&&A in Object(t)?function(t){var e=R.call(t,T),r=t[T];try{t[T]=void 0;var n=!0}catch(t){}var i=k.call(t);return n&&(e?t[T]=r:delete t[T]),i}(t):function(t){return x.call(t)}(t)}function L(t){return null!=t&&"object"==typeof t}function j(t){return"symbol"==typeof t||L(t)&&"[object Symbol]"==O(t)}var M=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,I=/^\w*$/;function P(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}function D(t){if(!P(t))return!1;var e=O(t);return"[object Function]"==e||"[object GeneratorFunction]"==e||"[object AsyncFunction]"==e||"[object Proxy]"==e}var C,N=w["__core-js_shared__"],F=(C=/[^.]+$/.exec(N&&N.keys&&N.keys.IE_PROTO||""))?"Symbol(src)_1."+C:"";var B=Function.prototype.toString;function W(t){if(null!=t){try{return B.call(t)}catch(t){}try{return t+""}catch(t){}}return""}var U=/^\[object .+?Constructor\]$/,z=Function.prototype,$=Object.prototype,H=z.toString,G=$.hasOwnProperty,q=RegExp("^"+H.call(G).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function V(t){return!(!P(t)||(e=t,F&&F in e))&&(D(t)?q:U).test(W(t));var e}function Z(t,e){var r=function(t,e){return null==t?void 0:t[e]}(t,e);return V(r)?r:void 0}var Y=Z(Object,"create");var K=Object.prototype.hasOwnProperty;var Q=Object.prototype.hasOwnProperty;function J(t){var e=-1,r=null==t?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}function X(t,e){return t===e||t!=t&&e!=e}function tt(t,e){for(var r=t.length;r--;)if(X(t[r][0],e))return r;return-1}J.prototype.clear=function(){this.__data__=Y?Y(null):{},this.size=0},J.prototype.delete=function(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e},J.prototype.get=function(t){var e=this.__data__;if(Y){var r=e[t];return"__lodash_hash_undefined__"===r?void 0:r}return K.call(e,t)?e[t]:void 0},J.prototype.has=function(t){var e=this.__data__;return Y?void 0!==e[t]:Q.call(e,t)},J.prototype.set=function(t,e){var r=this.__data__;return this.size+=this.has(t)?0:1,r[t]=Y&&void 0===e?"__lodash_hash_undefined__":e,this};var et=Array.prototype.splice;function rt(t){var e=-1,r=null==t?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}rt.prototype.clear=function(){this.__data__=[],this.size=0},rt.prototype.delete=function(t){var e=this.__data__,r=tt(e,t);return!(r<0)&&(r==e.length-1?e.pop():et.call(e,r,1),--this.size,!0)},rt.prototype.get=function(t){var e=this.__data__,r=tt(e,t);return r<0?void 0:e[r][1]},rt.prototype.has=function(t){return tt(this.__data__,t)>-1},rt.prototype.set=function(t,e){var r=this.__data__,n=tt(r,t);return n<0?(++this.size,r.push([t,e])):r[n][1]=e,this};var nt=Z(w,"Map");function it(t,e){var r,n,i=t.__data__;return("string"==(n=typeof(r=e))||"number"==n||"symbol"==n||"boolean"==n?"__proto__"!==r:null===r)?i["string"==typeof e?"string":"hash"]:i.map}function ot(t){var e=-1,r=null==t?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}ot.prototype.clear=function(){this.size=0,this.__data__={hash:new J,map:new(nt||rt),string:new J}},ot.prototype.delete=function(t){var e=it(this,t).delete(t);return this.size-=e?1:0,e},ot.prototype.get=function(t){return it(this,t).get(t)},ot.prototype.has=function(t){return it(this,t).has(t)},ot.prototype.set=function(t,e){var r=it(this,t),n=r.size;return r.set(t,e),this.size+=r.size==n?0:1,this};function st(t,e){if("function"!=typeof t||null!=e&&"function"!=typeof e)throw new TypeError("Expected a function");var r=function(){var n=arguments,i=e?e.apply(this,n):n[0],o=r.cache;if(o.has(i))return o.get(i);var s=t.apply(this,n);return r.cache=o.set(i,s)||o,s};return r.cache=new(st.Cache||ot),r}st.Cache=ot;var at,lt,ut,ct=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,ht=/\\(\\)?/g,ft=(at=function(t){var e=[];return 46===t.charCodeAt(0)&&e.push(""),t.replace(ct,function(t,r,n,i){e.push(n?i.replace(ht,"$1"):r||t)}),e},lt=st(at,function(t){return 500===ut.size&&ut.clear(),t}),ut=lt.cache,lt),dt=ft;function pt(t,e){for(var r=-1,n=null==t?0:t.length,i=Array(n);++r<n;)i[r]=e(t[r],r,t);return i}var yt=S?S.prototype:void 0,gt=yt?yt.toString:void 0;function bt(t){if("string"==typeof t)return t;if(b(t))return pt(t,bt)+"";if(j(t))return gt?gt.call(t):"";var e=t+"";return"0"==e&&1/t==-1/0?"-0":e}function mt(t){return null==t?"":bt(t)}function _t(t,e){return b(t)?t:function(t,e){if(b(t))return!1;var r=typeof t;return!("number"!=r&&"symbol"!=r&&"boolean"!=r&&null!=t&&!j(t))||I.test(t)||!M.test(t)||null!=e&&t in Object(e)}(t,e)?[t]:dt(mt(t))}function vt(t){if("string"==typeof t||j(t))return t;var e=t+"";return"0"==e&&1/t==-1/0?"-0":e}function wt(t,e,r){var n=null==t?void 0:function(t,e){for(var r=0,n=(e=_t(e,t)).length;null!=t&&r<n;)t=t[vt(e[r++])];return r&&r==n?t:void 0}(t,e);return void 0===n?r:n}function St(t){return"[object String]"===Object.prototype.toString.call(t)}function Et(t){return!(!St(t)||""===t)}function Rt(t){return t!=t}function kt(t){let e=!1;if(Et(t))e=!isNaN(Number(t));else if(function(t){return"[object Number]"===Object.prototype.toString.call(t)}(t)){if(Rt(t))return!1;e=!0}return e}function Tt(t){return"[object Object]"===Object.prototype.toString.call(t)}var xt=/\s/;var At=/^\s+/;function Ot(t){return t?t.slice(0,function(t){for(var e=t.length;e--&&xt.test(t.charAt(e)););return e}(t)+1).replace(At,""):t}var Lt=/^[-+]0x[0-9a-f]+$/i,jt=/^0b[01]+$/i,Mt=/^0o[0-7]+$/i,It=parseInt;function Pt(t){if("number"==typeof t)return t;if(j(t))return NaN;if(P(t)){var e="function"==typeof t.valueOf?t.valueOf():t;t=P(e)?e+"":e}if("string"!=typeof t)return 0===t?t:+t;t=Ot(t);var r=jt.test(t);return r||Mt.test(t)?It(t.slice(2),r?2:8):Lt.test(t)?NaN:+t}var Dt=1/0;function Ct(t){return t?(t=Pt(t))===Dt||t===-1/0?17976931348623157e292*(t<0?-1:1):t==t?t:0:0===t?t:0}function Nt(t){if(!kt(t))return 0;return Ct(t)}var Ft="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function Bt(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function Wt(t){if(t.__esModule)return t;var e=t.default;if("function"==typeof e){var r=function t(){if(this instanceof t){var r=[null];return r.push.apply(r,arguments),new(Function.bind.apply(e,r))}return e.apply(this,arguments)};r.prototype=e.prototype}else r={};return Object.defineProperty(r,"__esModule",{value:!0}),Object.keys(t).forEach(function(e){var n=Object.getOwnPropertyDescriptor(t,e);Object.defineProperty(r,e,n.get?n:{enumerable:!0,get:function(){return t[e]}})}),r}var Ut=n,zt=Ut.spawn,$t=Ut.exec;function Ht(t,e,r){var n={};try{Object.keys(t).forEach(function(r){t[r].forEach(function(t){n[t]||(Gt(t,e),n[t]=1)}),n[r]||(Gt(r,e),n[r]=1)})}catch(t){if(r)return r(t);throw t}if(r)return r()}function Gt(t,e){try{process.kill(parseInt(t,10),e)}catch(t){if("ESRCH"!==t.code)throw t}}function qt(t,e,r,n,i){var o=n(t),s="";o.stdout.on("data",function(t){t=t.toString("ascii");s+=t});o.on("close",function(o){delete r[t],0==o?s.match(/\d+/g).forEach(function(o){o=parseInt(o,10),e[t].push(o),e[o]=[],r[o]=1,qt(o,e,r,n,i)}):0==Object.keys(r).length&&i()})}var Vt=Bt(function(t,e,r){if("function"==typeof e&&void 0===r&&(r=e,e=void 0),t=parseInt(t),Number.isNaN(t)){if(r)return r(new Error("pid must be a number"));throw new Error("pid must be a number")}var n={},i={};switch(n[t]=[],i[t]=1,process.platform){case"win32":$t("taskkill /pid "+t+" /T /F",r);break;case"darwin":qt(t,n,i,function(t){return zt("pgrep",["-P",t])},function(){Ht(n,e,r)});break;default:qt(t,n,i,function(t){return zt("ps",["-o","pid","--no-headers","--ppid",t])},function(){Ht(n,e,r)})}});function Zt(t,e){for(var r=-1,n=null==t?0:t.length;++r<n&&!1!==e(t[r],r,t););return t}var Yt,Kt=function(t,e,r){for(var n=-1,i=Object(t),o=r(t),s=o.length;s--;){var a=o[Yt?s:++n];if(!1===e(i[a],a,i))break}return t},Qt=Kt;function Jt(t){return L(t)&&"[object Arguments]"==O(t)}var Xt=Object.prototype,te=Xt.hasOwnProperty,ee=Xt.propertyIsEnumerable,re=Jt(function(){return arguments}())?Jt:function(t){return L(t)&&te.call(t,"callee")&&!ee.call(t,"callee")},ne=re;var ie="object"==typeof exports&&exports&&!exports.nodeType&&exports,oe=ie&&"object"==typeof module&&module&&!module.nodeType&&module,se=oe&&oe.exports===ie?w.Buffer:void 0,ae=(se?se.isBuffer:void 0)||function(){return!1},le=/^(?:0|[1-9]\d*)$/;function ue(t,e){var r=typeof t;return!!(e=null==e?9007199254740991:e)&&("number"==r||"symbol"!=r&&le.test(t))&&t>-1&&t%1==0&&t<e}function ce(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=9007199254740991}var he={};he["[object Float32Array]"]=he["[object Float64Array]"]=he["[object Int8Array]"]=he["[object Int16Array]"]=he["[object Int32Array]"]=he["[object Uint8Array]"]=he["[object Uint8ClampedArray]"]=he["[object Uint16Array]"]=he["[object Uint32Array]"]=!0,he["[object Arguments]"]=he["[object Array]"]=he["[object ArrayBuffer]"]=he["[object Boolean]"]=he["[object DataView]"]=he["[object Date]"]=he["[object Error]"]=he["[object Function]"]=he["[object Map]"]=he["[object Number]"]=he["[object Object]"]=he["[object RegExp]"]=he["[object Set]"]=he["[object String]"]=he["[object WeakMap]"]=!1;var fe="object"==typeof exports&&exports&&!exports.nodeType&&exports,de=fe&&"object"==typeof module&&module&&!module.nodeType&&module,pe=de&&de.exports===fe&&m.process,ye=function(){try{var t=de&&de.require&&de.require("util").types;return t||pe&&pe.binding&&pe.binding("util")}catch(t){}}(),ge=ye&&ye.isTypedArray,be=ge?function(t){return function(e){return t(e)}}(ge):function(t){return L(t)&&ce(t.length)&&!!he[O(t)]},me=be,_e=Object.prototype.hasOwnProperty;function ve(t,e){var r=b(t),n=!r&&ne(t),i=!r&&!n&&ae(t),o=!r&&!n&&!i&&me(t),s=r||n||i||o,a=s?function(t,e){for(var r=-1,n=Array(t);++r<t;)n[r]=e(r);return n}(t.length,String):[],l=a.length;for(var u in t)!e&&!_e.call(t,u)||s&&("length"==u||i&&("offset"==u||"parent"==u)||o&&("buffer"==u||"byteLength"==u||"byteOffset"==u)||ue(u,l))||a.push(u);return a}var we=Object.prototype;var Se=function(t,e){return function(r){return t(e(r))}}(Object.keys,Object),Ee=Se,Re=Object.prototype.hasOwnProperty;function ke(t){if(r=(e=t)&&e.constructor,e!==("function"==typeof r&&r.prototype||we))return Ee(t);var e,r,n=[];for(var i in Object(t))Re.call(t,i)&&"constructor"!=i&&n.push(i);return n}function Te(t){return null!=t&&ce(t.length)&&!D(t)}function xe(t){return Te(t)?ve(t):ke(t)}var Ae=function(t,e){return function(r,n){if(null==r)return r;if(!Te(r))return t(r,n);for(var i=r.length,o=e?i:-1,s=Object(r);(e?o--:++o<i)&&!1!==n(s[o],o,s););return r}}(function(t,e){return t&&Qt(t,e,xe)}),Oe=Ae;function Le(t){return t}function je(t,e){var r;return(b(t)?Zt:Oe)(t,"function"==typeof(r=e)?r:Le)}var Me=Z(w,"DataView"),Ie=Z(w,"Promise"),Pe=Z(w,"Set"),De=Z(w,"WeakMap"),Ce="[object Map]",Ne="[object Promise]",Fe="[object Set]",Be="[object WeakMap]",We="[object DataView]",Ue=W(Me),ze=W(nt),$e=W(Ie),He=W(Pe),Ge=W(De),qe=O;(Me&&qe(new Me(new ArrayBuffer(1)))!=We||nt&&qe(new nt)!=Ce||Ie&&qe(Ie.resolve())!=Ne||Pe&&qe(new Pe)!=Fe||De&&qe(new De)!=Be)&&(qe=function(t){var e=O(t),r="[object Object]"==e?t.constructor:void 0,n=r?W(r):"";if(n)switch(n){case Ue:return We;case ze:return Ce;case $e:return Ne;case He:return Fe;case Ge:return Be}return e});var Ve=qe;var Ze,Ye=(Ze="length",function(t){return null==t?void 0:t[Ze]}),Ke=RegExp("[\\u200d\\ud800-\\udfff\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff\\ufe0e\\ufe0f]");var Qe="\\ud800-\\udfff",Je="["+Qe+"]",Xe="[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]",tr="\\ud83c[\\udffb-\\udfff]",er="[^"+Qe+"]",rr="(?:\\ud83c[\\udde6-\\uddff]){2}",nr="[\\ud800-\\udbff][\\udc00-\\udfff]",ir="(?:"+Xe+"|"+tr+")"+"?",or="[\\ufe0e\\ufe0f]?",sr=or+ir+("(?:\\u200d(?:"+[er,rr,nr].join("|")+")"+or+ir+")*"),ar="(?:"+[er+Xe+"?",Xe,rr,nr,Je].join("|")+")",lr=RegExp(tr+"(?="+tr+")|"+ar+sr,"g");function ur(t){return function(t){return Ke.test(t)}(t)?function(t){for(var e=lr.lastIndex=0;lr.test(t);)++e;return e}(t):Ye(t)}function cr(t){if(null==t)return 0;if(Te(t))return"string"==typeof(e=t)||!b(e)&&L(e)&&"[object String]"==O(e)?ur(t):t.length;var e,r=Ve(t);return"[object Map]"==r||"[object Set]"==r?t.size:ke(t).length}function hr(t){return"[object Array]"===Object.prototype.toString.call(t)}function fr(t){return!!function(t){return"[object Undefined]"===Object.prototype.toString.call(t)}(t)||(!!function(t){return"[object Null]"===Object.prototype.toString.call(t)}(t)||(!!function(t){if(Tt(t)){for(let e in t)return!1;return!0}return!1}(t)||(!!function(t){return!(!St(t)||""!==t)}(t)||(!!function(t){return!!hr(t)&&0===t.length}(t)||!!Rt(t)))))}function dr(t){return!!hr(t)&&(0!==t.length&&(1!==t.length||!fr(t[0])))}function pr(t){var e=Ct(t),r=e%1;return e==e?r?e-r:e:0}function yr(t){return!!kt(t)&&(t=Nt(t),"number"==typeof(e=t)&&e==pr(e));var e}var gr=w.isFinite,br=Math.min;var mr=function(t){var e=Math[t];return function(t,r){if(t=Pt(t),(r=null==r?0:br(pr(r),292))&&gr(t)){var n=(mt(t)+"e").split("e");return+((n=(mt(e(n[0]+"e"+(+n[1]+r)))+"e").split("e"))[0]+"e"+(+n[1]-r))}return e(t)}}("round"),_r=mr;function vr(t){if(!kt(t))return 0;t=Nt(t);let e=_r(t);return"0"===String(e)?0:e}function wr(t){if(!yr(t))return!1;return vr(t)>=0}function Sr(t){let e,r=Object.prototype.toString.call(t);if(e="[object Promise]"===r,e)return!0;if("[object Function]"!==r)return!1;try{e="function"!=typeof t.subscribe&&"function"==typeof t.then}catch(t){}return e}var Er={exports:{}};!function(t){t.exports=function(){var t=1e3,e=6e4,r=36e5,n="millisecond",i="second",o="minute",s="hour",a="day",l="week",u="month",c="quarter",h="year",f="date",d="Invalid Date",p=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,y=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,g={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(t){var e=["th","st","nd","rd"],r=t%100;return"["+t+(e[(r-20)%10]||e[r]||e[0])+"]"}},b=function(t,e,r){var n=String(t);return!n||n.length>=e?t:""+Array(e+1-n.length).join(r)+t},m={s:b,z:function(t){var e=-t.utcOffset(),r=Math.abs(e),n=Math.floor(r/60),i=r%60;return(e<=0?"+":"-")+b(n,2,"0")+":"+b(i,2,"0")},m:function t(e,r){if(e.date()<r.date())return-t(r,e);var n=12*(r.year()-e.year())+(r.month()-e.month()),i=e.clone().add(n,u),o=r-i<0,s=e.clone().add(n+(o?-1:1),u);return+(-(n+(r-i)/(o?i-s:s-i))||0)},a:function(t){return t<0?Math.ceil(t)||0:Math.floor(t)},p:function(t){return{M:u,y:h,w:l,d:a,D:f,h:s,m:o,s:i,ms:n,Q:c}[t]||String(t||"").toLowerCase().replace(/s$/,"")},u:function(t){return void 0===t}},_="en",v={};v[_]=g;var w="$isDayjsObject",S=function(t){return t instanceof T||!(!t||!t[w])},E=function t(e,r,n){var i;if(!e)return _;if("string"==typeof e){var o=e.toLowerCase();v[o]&&(i=o),r&&(v[o]=r,i=o);var s=e.split("-");if(!i&&s.length>1)return t(s[0])}else{var a=e.name;v[a]=e,i=a}return!n&&i&&(_=i),i||!n&&_},R=function(t,e){if(S(t))return t.clone();var r="object"==typeof e?e:{};return r.date=t,r.args=arguments,new T(r)},k=m;k.l=E,k.i=S,k.w=function(t,e){return R(t,{locale:e.$L,utc:e.$u,x:e.$x,$offset:e.$offset})};var T=function(){function g(t){this.$L=E(t.locale,null,!0),this.parse(t),this.$x=this.$x||t.x||{},this[w]=!0}var b=g.prototype;return b.parse=function(t){this.$d=function(t){var e=t.date,r=t.utc;if(null===e)return new Date(NaN);if(k.u(e))return new Date;if(e instanceof Date)return new Date(e);if("string"==typeof e&&!/Z$/i.test(e)){var n=e.match(p);if(n){var i=n[2]-1||0,o=(n[7]||"0").substring(0,3);return r?new Date(Date.UTC(n[1],i,n[3]||1,n[4]||0,n[5]||0,n[6]||0,o)):new Date(n[1],i,n[3]||1,n[4]||0,n[5]||0,n[6]||0,o)}}return new Date(e)}(t),this.init()},b.init=function(){var t=this.$d;this.$y=t.getFullYear(),this.$M=t.getMonth(),this.$D=t.getDate(),this.$W=t.getDay(),this.$H=t.getHours(),this.$m=t.getMinutes(),this.$s=t.getSeconds(),this.$ms=t.getMilliseconds()},b.$utils=function(){return k},b.isValid=function(){return!(this.$d.toString()===d)},b.isSame=function(t,e){var r=R(t);return this.startOf(e)<=r&&r<=this.endOf(e)},b.isAfter=function(t,e){return R(t)<this.startOf(e)},b.isBefore=function(t,e){return this.endOf(e)<R(t)},b.$g=function(t,e,r){return k.u(t)?this[e]:this.set(r,t)},b.unix=function(){return Math.floor(this.valueOf()/1e3)},b.valueOf=function(){return this.$d.getTime()},b.startOf=function(t,e){var r=this,n=!!k.u(e)||e,c=k.p(t),d=function(t,e){var i=k.w(r.$u?Date.UTC(r.$y,e,t):new Date(r.$y,e,t),r);return n?i:i.endOf(a)},p=function(t,e){return k.w(r.toDate()[t].apply(r.toDate("s"),(n?[0,0,0,0]:[23,59,59,999]).slice(e)),r)},y=this.$W,g=this.$M,b=this.$D,m="set"+(this.$u?"UTC":"");switch(c){case h:return n?d(1,0):d(31,11);case u:return n?d(1,g):d(0,g+1);case l:var _=this.$locale().weekStart||0,v=(y<_?y+7:y)-_;return d(n?b-v:b+(6-v),g);case a:case f:return p(m+"Hours",0);case s:return p(m+"Minutes",1);case o:return p(m+"Seconds",2);case i:return p(m+"Milliseconds",3);default:return this.clone()}},b.endOf=function(t){return this.startOf(t,!1)},b.$set=function(t,e){var r,l=k.p(t),c="set"+(this.$u?"UTC":""),d=(r={},r[a]=c+"Date",r[f]=c+"Date",r[u]=c+"Month",r[h]=c+"FullYear",r[s]=c+"Hours",r[o]=c+"Minutes",r[i]=c+"Seconds",r[n]=c+"Milliseconds",r)[l],p=l===a?this.$D+(e-this.$W):e;if(l===u||l===h){var y=this.clone().set(f,1);y.$d[d](p),y.init(),this.$d=y.set(f,Math.min(this.$D,y.daysInMonth())).$d}else d&&this.$d[d](p);return this.init(),this},b.set=function(t,e){return this.clone().$set(t,e)},b.get=function(t){return this[k.p(t)]()},b.add=function(n,c){var f,d=this;n=Number(n);var p=k.p(c),y=function(t){var e=R(d);return k.w(e.date(e.date()+Math.round(t*n)),d)};if(p===u)return this.set(u,this.$M+n);if(p===h)return this.set(h,this.$y+n);if(p===a)return y(1);if(p===l)return y(7);var g=(f={},f[o]=e,f[s]=r,f[i]=t,f)[p]||1,b=this.$d.getTime()+n*g;return k.w(b,this)},b.subtract=function(t,e){return this.add(-1*t,e)},b.format=function(t){var e=this,r=this.$locale();if(!this.isValid())return r.invalidDate||d;var n=t||"YYYY-MM-DDTHH:mm:ssZ",i=k.z(this),o=this.$H,s=this.$m,a=this.$M,l=r.weekdays,u=r.months,c=r.meridiem,h=function(t,r,i,o){return t&&(t[r]||t(e,n))||i[r].slice(0,o)},f=function(t){return k.s(o%12||12,t,"0")},p=c||function(t,e,r){var n=t<12?"AM":"PM";return r?n.toLowerCase():n};return n.replace(y,function(t,n){return n||function(t){switch(t){case"YY":return String(e.$y).slice(-2);case"YYYY":return k.s(e.$y,4,"0");case"M":return a+1;case"MM":return k.s(a+1,2,"0");case"MMM":return h(r.monthsShort,a,u,3);case"MMMM":return h(u,a);case"D":return e.$D;case"DD":return k.s(e.$D,2,"0");case"d":return String(e.$W);case"dd":return h(r.weekdaysMin,e.$W,l,2);case"ddd":return h(r.weekdaysShort,e.$W,l,3);case"dddd":return l[e.$W];case"H":return String(o);case"HH":return k.s(o,2,"0");case"h":return f(1);case"hh":return f(2);case"a":return p(o,s,!0);case"A":return p(o,s,!1);case"m":return String(s);case"mm":return k.s(s,2,"0");case"s":return String(e.$s);case"ss":return k.s(e.$s,2,"0");case"SSS":return k.s(e.$ms,3,"0");case"Z":return i}return null}(t)||i.replace(":","")})},b.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},b.diff=function(n,f,d){var p,y=this,g=k.p(f),b=R(n),m=(b.utcOffset()-this.utcOffset())*e,_=this-b,v=function(){return k.m(y,b)};switch(g){case h:p=v()/12;break;case u:p=v();break;case c:p=v()/3;break;case l:p=(_-m)/6048e5;break;case a:p=(_-m)/864e5;break;case s:p=_/r;break;case o:p=_/e;break;case i:p=_/t;break;default:p=_}return d?p:k.a(p)},b.daysInMonth=function(){return this.endOf(u).$D},b.$locale=function(){return v[this.$L]},b.locale=function(t,e){if(!t)return this.$L;var r=this.clone(),n=E(t,e,!0);return n&&(r.$L=n),r},b.clone=function(){return k.w(this.$d,this)},b.toDate=function(){return new Date(this.valueOf())},b.toJSON=function(){return this.isValid()?this.toISOString():null},b.toISOString=function(){return this.$d.toISOString()},b.toString=function(){return this.$d.toUTCString()},g}(),x=T.prototype;return R.prototype=x,[["$ms",n],["$s",i],["$m",o],["$H",s],["$W",a],["$M",u],["$y",h],["$D",f]].forEach(function(t){x[t[1]]=function(e){return this.$g(e,t[0],t[1])}}),R.extend=function(t,e){return t.$i||(t(e,T,R),t.$i=!0),R},R.locale=E,R.isDayjs=S,R.unix=function(t){return R(1e3*t)},R.en=v[_],R.Ls=v,R.p={},R}()}(Er);var Rr=Bt(Er.exports);function kr(t){let e=Object.prototype.toString.call(t);return"[object Function]"===e||"[object AsyncFunction]"===e}function Tr(t){if(!yr(t))return!1;return vr(t)>0}let xr="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz".split(""),Ar=xr.length;function Or(t,e={}){let r=wt(e,"fs");return!!r.existsSync(t)&&(!r.lstatSync(t).isDirectory()&&!r.lstatSync(t).isSymbolicLink())}function Lr(e){return Or(e,{fs:t})}function jr(t,e={}){let r=wt(e,"fs");if(!r.existsSync(t))return!1;let n=r.lstatSync(t);return!n.isFile()&&!n.isSymbolicLink()}function Mr(e){return jr(e,{fs:t})}function Ir(){let t,e,r=new Promise(function(){t=arguments[0],e=arguments[1]});return r.resolve=t,r.reject=e,r}function Pr(t=10){kt(t)||(t=10);let e=Ir();return setTimeout(function(){e.resolve()},t),e}async function Dr(e,r={}){return await async function(t,e={}){let r=wt(e,"numRetry");Tr(r)||(r=5),r=vr(r);let n=wt(e,"fs",null);if(!n.existsSync(t))return"folder does not exist: "+t;if(!jr(t,{fs:n}))return Promise.reject("input path is not a folder: "+t);for(let e=0;e<r;e++)try{n.rmSync(t,{recursive:!0,force:!0});break}catch(t){if("EBUSY"!==t.code)return Promise.reject(t);await Pr(300)}return"done: "+t}(e,{fs:t,...r})}var Cr=Math.ceil,Nr=Math.max;var Fr=function(t){return function(e,r,n){return n&&"number"!=typeof n&&function(t,e,r){if(!P(r))return!1;var n=typeof e;return!!("number"==n?Te(r)&&ue(e,r.length):"string"==n&&e in r)&&X(r[e],t)}(e,r,n)&&(r=n=void 0),e=Ct(e),void 0===r?(r=e,e=0):r=Ct(r),function(t,e,r,n){for(var i=-1,o=Nr(Cr((e-t)/(r||1)),0),s=Array(o);o--;)s[n?o:++i]=t,t+=r;return s}(e,r,n=void 0===n?e<r?1:-1:Ct(n),t)}}(),Br=Fr;function Wr(t,e,r){var n=null==t?0:t.length;return n?function(t,e,r){var n=-1,i=t.length;e<0&&(e=-e>i?0:i+e),(r=r>i?i:r)<0&&(r+=i),i=e>r?0:r-e>>>0,e>>>=0;for(var o=Array(i);++n<i;)o[n]=t[n+e];return o}(t,(e=r||void 0===e?1:pr(e))<0?0:e,n):[]}function Ur(t,e){if(!Et(t))return"";if(!wr(e))return"";if(0===(e=vr(e)))return"";let r=t.length-e;return r<0&&(r=0),t.substring(r,r+e)}function zr(t,e){return Et(t)&&wr(e)?0===(e=vr(e))?t:function(t,e){return Et(t)&&wr(e)?0===(e=vr(e))?"":t.substring(0,e):""}(t,t.length-e):""}function $r(t){if(!Et(t))return{path:"",isRoot:!1};for(;t.indexOf("\\\\")>=0;)t=t.replace("\\\\","\\");for(;t.indexOf("//")>=0;)t=t.replace("//","/");if(":"===Ur(t,1))return{path:`${t}\\`,isRoot:!0};if("\\"===Ur(t,1)){let e=zr(t,1);return":"===Ur(e,1)?{path:t,isRoot:!0}:{path:e,isRoot:!1}}if("/"===Ur(t,1)){let e=zr(t,1);return 0===e.length?{path:t,isRoot:!0}:{path:e,isRoot:!1}}return{path:t,isRoot:!1}}function Hr(t){if(!Et(t))return"";let e=$r(t);if(e.isRoot)return e.path;let r=e.path;try{r=r.split("\\").pop().split("/").pop()}catch(t){}return r}function Gr(t){if(!Et(t))return"";let e=$r(t);if(e.isRoot)return e.path;let r=Hr(t=e.path);if(!Et(r))return t;let n=$r(t=zr(t,r.length));return n.isRoot,n.path}function qr(t,e={}){let r=wt(e,"fs");if(jr(t,{fs:r}))return{success:"input folder is already exists: "+t};if(r.existsSync(t))return{error:"input path already exists: "+t};try{r.mkdirSync(t,{recursive:!0})}catch(t){return{error:t}}return{success:"done: "+t}}async function Vr(e,r){return async function(t,e,r={}){let n="",i=wt(r,"fs"),o=wt(r,"Readable");if(!Et(t))throw new Error("urlIn in not an effective string");let s=Gr(e),a=wt(r,"fnOut","");Et(a)||(a=Hr(e)),jr(s,{fs:i})||qr(s,{fs:i});let l=Ir();try{let r=await fetch(t);if(!r.ok)return l.reject(r.statusText),l;let s=i.createWriteStream(e);o.fromWeb(r.body).pipe(s),s.on("finish",()=>{l.resolve(e)}),s.on("error",t=>{n=t.message,l.reject(n)})}catch(t){n=t.message,l.reject(n)}return l}(e,r,{fs:t,Readable:i.Readable})}function Zr(t,e={}){let r=wt(e,"fs");if(!r.existsSync(t))return{success:"file does not exist: "+t};if(!Or(t,{fs:r}))return{error:"input path is not a file: "+t};try{r.unlinkSync(t)}catch(t){return{error:t}}return{success:"done: "+t}}async function Yr(e,r,n={}){return async function(t,e,r={}){let n="",i=wt(r,"fs");if(!dr(t))throw new Error("fpsIn in not an effective array");let o=Gr(e),s=wt(r,"fnOut","");Et(s)||(s=Hr(e)),jr(o,{fs:i})||qr(o,{fs:i});let a=Ir();try{let r=i.createWriteStream(e);for(let e=0;e<t.length;e++){let o=t[e];if(!Or(o,{fs:i}))throw new Error(`fpIn[${o}] is not a file`);let s=()=>{let t=Ir(),e=i.createReadStream(o);return e.on("error",e=>{n=e.message,t.reject(e)}),e.on("end",()=>{Zr(o,{fs:i}),t.resolve()}),e.pipe(r,{end:!1}),t};await s()}r.end(),r.on("error",t=>{n=t.message,a.reject(n)}),r.on("finish",()=>{let t={filename:s,path:e};a.resolve(t)})}catch(t){n=t.message,a.reject(n)}return a}(e,r,{fs:t,...n})}function Kr(e,r){return function(t,e,r={}){let n=wt(r,"fs");if(!jr(t,{fs:n}))return{error:`pahOld[${t}] is not a folder`};if(n.existsSync(e))return{error:`pahNew[${e}] already exists`};let i=Gr(e);jr(i,{fs:n})||qr(i,{fs:n});try{n.renameSync(t,e)}catch(t){return{error:t}}return{success:"done: "+e}}(e,r,{fs:t})}function Qr(e){return function(t,e={}){let r=wt(e,"fs");if(!r.existsSync(t))return{success:"folder does not exist: "+t};if(!jr(t,{fs:r}))return{error:"input path is not a folder: "+t};try{r.rmSync(t,{recursive:!0,force:!0})}catch(t){return{error:t}}return{success:"done: "+t}}(e,{fs:t})}var Jr,Xr={exports:{}},tn="object"==typeof Reflect?Reflect:null,en=tn&&"function"==typeof tn.apply?tn.apply:function(t,e,r){return Function.prototype.apply.call(t,e,r)};Jr=tn&&"function"==typeof tn.ownKeys?tn.ownKeys:Object.getOwnPropertySymbols?function(t){return Object.getOwnPropertyNames(t).concat(Object.getOwnPropertySymbols(t))}:function(t){return Object.getOwnPropertyNames(t)};var rn=Number.isNaN||function(t){return t!=t};function nn(){nn.init.call(this)}Xr.exports=nn,Xr.exports.once=function(t,e){return new Promise(function(r,n){function i(r){t.removeListener(e,o),n(r)}function o(){"function"==typeof t.removeListener&&t.removeListener("error",i),r([].slice.call(arguments))}pn(t,e,o,{once:!0}),"error"!==e&&function(t,e,r){"function"==typeof t.on&&pn(t,"error",e,r)}(t,i,{once:!0})})},nn.EventEmitter=nn,nn.prototype._events=void 0,nn.prototype._eventsCount=0,nn.prototype._maxListeners=void 0;var on=10;function sn(t){if("function"!=typeof t)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof t)}function an(t){return void 0===t._maxListeners?nn.defaultMaxListeners:t._maxListeners}function ln(t,e,r,n){var i,o,s,a;if(sn(r),void 0===(o=t._events)?(o=t._events=Object.create(null),t._eventsCount=0):(void 0!==o.newListener&&(t.emit("newListener",e,r.listener?r.listener:r),o=t._events),s=o[e]),void 0===s)s=o[e]=r,++t._eventsCount;else if("function"==typeof s?s=o[e]=n?[r,s]:[s,r]:n?s.unshift(r):s.push(r),(i=an(t))>0&&s.length>i&&!s.warned){s.warned=!0;var l=new Error("Possible EventEmitter memory leak detected. "+s.length+" "+String(e)+" listeners added. Use emitter.setMaxListeners() to increase limit");l.name="MaxListenersExceededWarning",l.emitter=t,l.type=e,l.count=s.length,a=l,console&&console.warn&&console.warn(a)}return t}function un(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,0===arguments.length?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function cn(t,e,r){var n={fired:!1,wrapFn:void 0,target:t,type:e,listener:r},i=un.bind(n);return i.listener=r,n.wrapFn=i,i}function hn(t,e,r){var n=t._events;if(void 0===n)return[];var i=n[e];return void 0===i?[]:"function"==typeof i?r?[i.listener||i]:[i]:r?function(t){for(var e=new Array(t.length),r=0;r<e.length;++r)e[r]=t[r].listener||t[r];return e}(i):dn(i,i.length)}function fn(t){var e=this._events;if(void 0!==e){var r=e[t];if("function"==typeof r)return 1;if(void 0!==r)return r.length}return 0}function dn(t,e){for(var r=new Array(e),n=0;n<e;++n)r[n]=t[n];return r}function pn(t,e,r,n){if("function"==typeof t.on)n.once?t.once(e,r):t.on(e,r);else{if("function"!=typeof t.addEventListener)throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type '+typeof t);t.addEventListener(e,function i(o){n.once&&t.removeEventListener(e,i),r(o)})}}Object.defineProperty(nn,"defaultMaxListeners",{enumerable:!0,get:function(){return on},set:function(t){if("number"!=typeof t||t<0||rn(t))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+t+".");on=t}}),nn.init=function(){void 0!==this._events&&this._events!==Object.getPrototypeOf(this)._events||(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},nn.prototype.setMaxListeners=function(t){if("number"!=typeof t||t<0||rn(t))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+t+".");return this._maxListeners=t,this},nn.prototype.getMaxListeners=function(){return an(this)},nn.prototype.emit=function(t){for(var e=[],r=1;r<arguments.length;r++)e.push(arguments[r]);var n="error"===t,i=this._events;if(void 0!==i)n=n&&void 0===i.error;else if(!n)return!1;if(n){var o;if(e.length>0&&(o=e[0]),o instanceof Error)throw o;var s=new Error("Unhandled error."+(o?" ("+o.message+")":""));throw s.context=o,s}var a=i[t];if(void 0===a)return!1;if("function"==typeof a)en(a,this,e);else{var l=a.length,u=dn(a,l);for(r=0;r<l;++r)en(u[r],this,e)}return!0},nn.prototype.addListener=function(t,e){return ln(this,t,e,!1)},nn.prototype.on=nn.prototype.addListener,nn.prototype.prependListener=function(t,e){return ln(this,t,e,!0)},nn.prototype.once=function(t,e){return sn(e),this.on(t,cn(this,t,e)),this},nn.prototype.prependOnceListener=function(t,e){return sn(e),this.prependListener(t,cn(this,t,e)),this},nn.prototype.removeListener=function(t,e){var r,n,i,o,s;if(sn(e),void 0===(n=this._events))return this;if(void 0===(r=n[t]))return this;if(r===e||r.listener===e)0===--this._eventsCount?this._events=Object.create(null):(delete n[t],n.removeListener&&this.emit("removeListener",t,r.listener||e));else if("function"!=typeof r){for(i=-1,o=r.length-1;o>=0;o--)if(r[o]===e||r[o].listener===e){s=r[o].listener,i=o;break}if(i<0)return this;0===i?r.shift():function(t,e){for(;e+1<t.length;e++)t[e]=t[e+1];t.pop()}(r,i),1===r.length&&(n[t]=r[0]),void 0!==n.removeListener&&this.emit("removeListener",t,s||e)}return this},nn.prototype.off=nn.prototype.removeListener,nn.prototype.removeAllListeners=function(t){var e,r,n;if(void 0===(r=this._events))return this;if(void 0===r.removeListener)return 0===arguments.length?(this._events=Object.create(null),this._eventsCount=0):void 0!==r[t]&&(0===--this._eventsCount?this._events=Object.create(null):delete r[t]),this;if(0===arguments.length){var i,o=Object.keys(r);for(n=0;n<o.length;++n)"removeListener"!==(i=o[n])&&this.removeAllListeners(i);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if("function"==typeof(e=r[t]))this.removeListener(t,e);else if(void 0!==e)for(n=e.length-1;n>=0;n--)this.removeListener(t,e[n]);return this},nn.prototype.listeners=function(t){return hn(this,t,!0)},nn.prototype.rawListeners=function(t){return hn(this,t,!1)},nn.listenerCount=function(t,e){return"function"==typeof t.listenerCount?t.listenerCount(e):fn.call(t,e)},nn.prototype.listenerCount=fn,nn.prototype.eventNames=function(){return this._eventsCount>0?Jr(this._events):[]};var yn=Xr.exports;var gn="object"==typeof process&&process&&"win32"===process.platform?{sep:"\\"}:{sep:"/"},bn=mn;function mn(t,e,r){t instanceof RegExp&&(t=_n(t,r)),e instanceof RegExp&&(e=_n(e,r));var n=vn(t,e,r);return n&&{start:n[0],end:n[1],pre:r.slice(0,n[0]),body:r.slice(n[0]+t.length,n[1]),post:r.slice(n[1]+e.length)}}function _n(t,e){var r=e.match(t);return r?r[0]:null}function vn(t,e,r){var n,i,o,s,a,l=r.indexOf(t),u=r.indexOf(e,l+1),c=l;if(l>=0&&u>0){if(t===e)return[l,u];for(n=[],o=r.length;c>=0&&!a;)c==l?(n.push(c),l=r.indexOf(t,c+1)):1==n.length?a=[n.pop(),u]:((i=n.pop())<o&&(o=i,s=u),u=r.indexOf(e,c+1)),c=l<u&&l>=0?l:u;n.length&&(a=[o,s])}return a}mn.range=vn;var wn=bn,Sn=function(t){if(!t)return[];"{}"===t.substr(0,2)&&(t="\\{\\}"+t.substr(2));return Dn(function(t){return t.split("\\\\").join(En).split("\\{").join(Rn).split("\\}").join(kn).split("\\,").join(Tn).split("\\.").join(xn)}(t),!0).map(On)},En="\0SLASH"+Math.random()+"\0",Rn="\0OPEN"+Math.random()+"\0",kn="\0CLOSE"+Math.random()+"\0",Tn="\0COMMA"+Math.random()+"\0",xn="\0PERIOD"+Math.random()+"\0";function An(t){return parseInt(t,10)==t?parseInt(t,10):t.charCodeAt(0)}function On(t){return t.split(En).join("\\").split(Rn).join("{").split(kn).join("}").split(Tn).join(",").split(xn).join(".")}function Ln(t){if(!t)return[""];var e=[],r=wn("{","}",t);if(!r)return t.split(",");var n=r.pre,i=r.body,o=r.post,s=n.split(",");s[s.length-1]+="{"+i+"}";var a=Ln(o);return o.length&&(s[s.length-1]+=a.shift(),s.push.apply(s,a)),e.push.apply(e,s),e}function jn(t){return"{"+t+"}"}function Mn(t){return/^-?0\d/.test(t)}function In(t,e){return t<=e}function Pn(t,e){return t>=e}function Dn(t,e){var r=[],n=wn("{","}",t);if(!n)return[t];var i=n.pre,o=n.post.length?Dn(n.post,!1):[""];if(/\$$/.test(n.pre))for(var s=0;s<o.length;s++){var a=i+"{"+n.body+"}"+o[s];r.push(a)}else{var l,u,c=/^-?\d+\.\.-?\d+(?:\.\.-?\d+)?$/.test(n.body),h=/^[a-zA-Z]\.\.[a-zA-Z](?:\.\.-?\d+)?$/.test(n.body),f=c||h,d=n.body.indexOf(",")>=0;if(!f&&!d)return n.post.match(/,(?!,).*\}/)?Dn(t=n.pre+"{"+n.body+kn+n.post):[t];if(f)l=n.body.split(/\.\./);else if(1===(l=Ln(n.body)).length&&1===(l=Dn(l[0],!1).map(jn)).length)return o.map(function(t){return n.pre+l[0]+t});if(f){var p=An(l[0]),y=An(l[1]),g=Math.max(l[0].length,l[1].length),b=3==l.length?Math.abs(An(l[2])):1,m=In;y<p&&(b*=-1,m=Pn);var _=l.some(Mn);u=[];for(var v=p;m(v,y);v+=b){var w;if(h)"\\"===(w=String.fromCharCode(v))&&(w="");else if(w=String(v),_){var S=g-w.length;if(S>0){var E=new Array(S+1).join("0");w=v<0?"-"+E+w.slice(1):E+w}}u.push(w)}}else{u=[];for(var R=0;R<l.length;R++)u.push.apply(u,Dn(l[R],!1))}for(R=0;R<u.length;R++)for(s=0;s<o.length;s++){a=i+u[R]+o[s];(!e||f||a)&&r.push(a)}}return r}const Cn=(t,e,r={})=>(Kn(e),!(!r.nocomment&&"#"===e.charAt(0))&&new ti(e,r).match(t));var Nn=Cn;const Fn=gn;Cn.sep=Fn.sep;const Bn=Symbol("globstar **");Cn.GLOBSTAR=Bn;const Wn=Sn,Un={"!":{open:"(?:(?!(?:",close:"))[^/]*?)"},"?":{open:"(?:",close:")?"},"+":{open:"(?:",close:")+"},"*":{open:"(?:",close:")*"},"@":{open:"(?:",close:")"}},zn="[^/]",$n=zn+"*?",Hn=t=>t.split("").reduce((t,e)=>(t[e]=!0,t),{}),Gn=Hn("().*{}+?[]^$\\!"),qn=Hn("[.("),Vn=/\/+/;Cn.filter=(t,e={})=>(r,n,i)=>Cn(r,t,e);const Zn=(t,e={})=>{const r={};return Object.keys(t).forEach(e=>r[e]=t[e]),Object.keys(e).forEach(t=>r[t]=e[t]),r};Cn.defaults=t=>{if(!t||"object"!=typeof t||!Object.keys(t).length)return Cn;const e=Cn,r=(r,n,i)=>e(r,n,Zn(t,i));return r.Minimatch=class extends e.Minimatch{constructor(e,r){super(e,Zn(t,r))}},r.Minimatch.defaults=r=>e.defaults(Zn(t,r)).Minimatch,r.filter=(r,n)=>e.filter(r,Zn(t,n)),r.defaults=r=>e.defaults(Zn(t,r)),r.makeRe=(r,n)=>e.makeRe(r,Zn(t,n)),r.braceExpand=(r,n)=>e.braceExpand(r,Zn(t,n)),r.match=(r,n,i)=>e.match(r,n,Zn(t,i)),r},Cn.braceExpand=(t,e)=>Yn(t,e);const Yn=(t,e={})=>(Kn(t),e.nobrace||!/\{(?:(?!\{).)*\}/.test(t)?[t]:Wn(t)),Kn=t=>{if("string"!=typeof t)throw new TypeError("invalid pattern");if(t.length>65536)throw new TypeError("pattern is too long")},Qn=Symbol("subparse");Cn.makeRe=(t,e)=>new ti(t,e||{}).makeRe(),Cn.match=(t,e,r={})=>{const n=new ti(e,r);return t=t.filter(t=>n.match(t)),n.options.nonull&&!t.length&&t.push(e),t};const Jn=t=>t.replace(/\\([^-\]])/g,"$1"),Xn=t=>t.replace(/[[\]\\]/g,"\\$&");let ti=class{constructor(t,e){Kn(t),e||(e={}),this.options=e,this.set=[],this.pattern=t,this.windowsPathsNoEscape=!!e.windowsPathsNoEscape||!1===e.allowWindowsEscape,this.windowsPathsNoEscape&&(this.pattern=this.pattern.replace(/\\/g,"/")),this.regexp=null,this.negate=!1,this.comment=!1,this.empty=!1,this.partial=!!e.partial,this.make()}debug(){}make(){const t=this.pattern,e=this.options;if(!e.nocomment&&"#"===t.charAt(0))return void(this.comment=!0);if(!t)return void(this.empty=!0);this.parseNegate();let r=this.globSet=this.braceExpand();e.debug&&(this.debug=(...t)=>console.error(...t)),this.debug(this.pattern,r),r=this.globParts=r.map(t=>t.split(Vn)),this.debug(this.pattern,r),r=r.map((t,e,r)=>t.map(this.parse,this)),this.debug(this.pattern,r),r=r.filter(t=>-1===t.indexOf(!1)),this.debug(this.pattern,r),this.set=r}parseNegate(){if(this.options.nonegate)return;const t=this.pattern;let e=!1,r=0;for(let n=0;n<t.length&&"!"===t.charAt(n);n++)e=!e,r++;r&&(this.pattern=t.slice(r)),this.negate=e}matchOne(t,e,r){var n=this.options;this.debug("matchOne",{this:this,file:t,pattern:e}),this.debug("matchOne",t.length,e.length);for(var i=0,o=0,s=t.length,a=e.length;i<s&&o<a;i++,o++){this.debug("matchOne loop");var l,u=e[o],c=t[i];if(this.debug(e,u,c),!1===u)return!1;if(u===Bn){this.debug("GLOBSTAR",[e,u,c]);var h=i,f=o+1;if(f===a){for(this.debug("** at the end");i<s;i++)if("."===t[i]||".."===t[i]||!n.dot&&"."===t[i].charAt(0))return!1;return!0}for(;h<s;){var d=t[h];if(this.debug("\nglobstar while",t,h,e,f,d),this.matchOne(t.slice(h),e.slice(f),r))return this.debug("globstar found match!",h,s,d),!0;if("."===d||".."===d||!n.dot&&"."===d.charAt(0)){this.debug("dot detected!",t,h,e,f);break}this.debug("globstar swallow a segment, and continue"),h++}return!(!r||(this.debug("\n>>> no match, partial?",t,h,e,f),h!==s))}if("string"==typeof u?(l=c===u,this.debug("string match",u,c,l)):(l=c.match(u),this.debug("pattern match",u,c,l)),!l)return!1}if(i===s&&o===a)return!0;if(i===s)return r;if(o===a)return i===s-1&&""===t[i];throw new Error("wtf?")}braceExpand(){return Yn(this.pattern,this.options)}parse(t,e){Kn(t);const r=this.options;if("**"===t){if(!r.noglobstar)return Bn;t="*"}if(""===t)return"";let n="",i=!1,o=!1;const s=[],a=[];let l,u,c,h,f=!1,d=-1,p=-1,y="."===t.charAt(0),g=r.dot||y;const b=t=>"."===t.charAt(0)?"":r.dot?"(?!(?:^|\\/)\\.{1,2}(?:$|\\/))":"(?!\\.)",m=()=>{if(l){switch(l){case"*":n+=$n,i=!0;break;case"?":n+=zn,i=!0;break;default:n+="\\"+l}this.debug("clearStateChar %j %j",l,n),l=!1}};for(let e,h=0;h<t.length&&(e=t.charAt(h));h++)if(this.debug("%s\t%s %s %j",t,h,n,e),o){if("/"===e)return!1;Gn[e]&&(n+="\\"),n+=e,o=!1}else switch(e){case"/":return!1;case"\\":if(f&&"-"===t.charAt(h+1)){n+=e;continue}m(),o=!0;continue;case"?":case"*":case"+":case"@":case"!":if(this.debug("%s\t%s %s %j <-- stateChar",t,h,n,e),f){this.debug(" in class"),"!"===e&&h===p+1&&(e="^"),n+=e;continue}this.debug("call clearStateChar %j",l),m(),l=e,r.noext&&m();continue;case"(":{if(f){n+="(";continue}if(!l){n+="\\(";continue}const e={type:l,start:h-1,reStart:n.length,open:Un[l].open,close:Un[l].close};this.debug(this.pattern,"\t",e),s.push(e),n+=e.open,0===e.start&&"!"!==e.type&&(y=!0,n+=b(t.slice(h+1))),this.debug("plType %j %j",l,n),l=!1;continue}case")":{const t=s[s.length-1];if(f||!t){n+="\\)";continue}s.pop(),m(),i=!0,c=t,n+=c.close,"!"===c.type&&a.push(Object.assign(c,{reEnd:n.length}));continue}case"|":{const e=s[s.length-1];if(f||!e){n+="\\|";continue}m(),n+="|",0===e.start&&"!"!==e.type&&(y=!0,n+=b(t.slice(h+1)));continue}case"[":if(m(),f){n+="\\"+e;continue}f=!0,p=h,d=n.length,n+=e;continue;case"]":if(h===p+1||!f){n+="\\"+e;continue}u=t.substring(p+1,h);try{RegExp("["+Xn(Jn(u))+"]"),n+=e}catch(t){n=n.substring(0,d)+"(?:$.)"}i=!0,f=!1;continue;default:m(),!Gn[e]||"^"===e&&f||(n+="\\"),n+=e}for(f&&(u=t.slice(p+1),h=this.parse(u,Qn),n=n.substring(0,d)+"\\["+h[0],i=i||h[1]),c=s.pop();c;c=s.pop()){let t;t=n.slice(c.reStart+c.open.length),this.debug("setting tail",n,c),t=t.replace(/((?:\\{2}){0,64})(\\?)\|/g,(t,e,r)=>(r||(r="\\"),e+e+r+"|")),this.debug("tail=%j\n %s",t,t,c,n);const e="*"===c.type?$n:"?"===c.type?zn:"\\"+c.type;i=!0,n=n.slice(0,c.reStart)+e+"\\("+t}m(),o&&(n+="\\\\");const _=qn[n.charAt(0)];for(let t=a.length-1;t>-1;t--){const r=a[t],i=n.slice(0,r.reStart),o=n.slice(r.reStart,r.reEnd-8);let s=n.slice(r.reEnd);const l=n.slice(r.reEnd-8,r.reEnd)+s,u=i.split(")").length,c=i.split("(").length-u;let h=s;for(let t=0;t<c;t++)h=h.replace(/\)[+*?]?/,"");s=h;n=i+o+s+(""===s&&e!==Qn?"(?:$|\\/)":"")+l}if(""!==n&&i&&(n="(?=.)"+n),_&&(n=(y?"":g?"(?!(?:^|\\/)\\.{1,2}(?:$|\\/))":"(?!\\.)")+n),e===Qn)return[n,i];if(r.nocase&&!i&&(i=t.toUpperCase()!==t.toLowerCase()),!i)return t.replace(/\\(.)/g,"$1");const v=r.nocase?"i":"";try{return Object.assign(new RegExp("^"+n+"$",v),{_glob:t,_src:n})}catch(t){return new RegExp("$.")}}makeRe(){if(this.regexp||!1===this.regexp)return this.regexp;const t=this.set;if(!t.length)return this.regexp=!1,this.regexp;const e=this.options,r=e.noglobstar?$n:e.dot?"(?:(?!(?:\\/|^)(?:\\.{1,2})($|\\/)).)*?":"(?:(?!(?:\\/|^)\\.).)*?",n=e.nocase?"i":"";let i=t.map(t=>(t=t.map(t=>"string"==typeof t?t.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&"):t===Bn?Bn:t._src).reduce((t,e)=>(t[t.length-1]===Bn&&e===Bn||t.push(e),t),[]),t.forEach((e,n)=>{e===Bn&&t[n-1]!==Bn&&(0===n?t.length>1?t[n+1]="(?:\\/|"+r+"\\/)?"+t[n+1]:t[n]=r:n===t.length-1?t[n-1]+="(?:\\/|"+r+")?":(t[n-1]+="(?:\\/|\\/"+r+"\\/)"+t[n+1],t[n+1]=Bn))}),t.filter(t=>t!==Bn).join("/"))).join("|");i="^(?:"+i+")$",this.negate&&(i="^(?!"+i+").*$");try{this.regexp=new RegExp(i,n)}catch(t){this.regexp=!1}return this.regexp}match(t,e=this.partial){if(this.debug("match",t,this.pattern),this.comment)return!1;if(this.empty)return""===t;if("/"===t&&e)return!0;const r=this.options;"/"!==Fn.sep&&(t=t.split(Fn.sep).join("/")),t=t.split(Vn),this.debug(this.pattern,"split",t);const n=this.set;let i;this.debug(this.pattern,"set",n);for(let e=t.length-1;e>=0&&(i=t[e],!i);e--);for(let o=0;o<n.length;o++){const s=n[o];let a=t;r.matchBase&&1===s.length&&(a=[i]);if(this.matchOne(a,s,e))return!!r.flipNegate||!this.negate}return!r.flipNegate&&this.negate}static defaults(t){return Cn.defaults(t).Minimatch}};Cn.Minimatch=ti;var ei=ui;const ri=t,{EventEmitter:ni}=yn,{Minimatch:ii}=Nn,{resolve:oi}=e;function si(t,e){return new Promise((r,n)=>{(e?ri.stat:ri.lstat)(t,(n,i)=>{if(n)if("ENOENT"===n.code)r(e?si(t,!1):null);else r(null);else r(i)})})}async function*ai(t,e,r,n,i,o){let s=await function(t,e){return new Promise((r,n)=>{ri.readdir(t,{withFileTypes:!0},(t,i)=>{if(t)switch(t.code){case"ENOTDIR":e?n(t):r([]);break;case"ENOTSUP":case"ENOENT":case"ENAMETOOLONG":case"UNKNOWN":r([]);break;default:n(t)}else r(i)})})}(e+t,o);for(const o of s){let s=o.name;void 0===s&&(s=o,n=!0);const a=t+"/"+s,l=a.slice(1),u=e+"/"+l;let c=null;(n||r)&&(c=await si(u,r)),c||void 0===o.name||(c=o),null===c&&(c={isDirectory:()=>!1}),c.isDirectory()?i(l)||(yield{relative:l,absolute:u,stats:c},yield*ai(a,e,r,n,i,!1)):yield{relative:l,absolute:u,stats:c}}}class li extends ni{constructor(t,e,r){if(super(),"function"==typeof e&&(r=e,e=null),this.options=function(t){return{pattern:t.pattern,dot:!!t.dot,noglobstar:!!t.noglobstar,matchBase:!!t.matchBase,nocase:!!t.nocase,ignore:t.ignore,skip:t.skip,follow:!!t.follow,stat:!!t.stat,nodir:!!t.nodir,mark:!!t.mark,silent:!!t.silent,absolute:!!t.absolute}}(e||{}),this.matchers=[],this.options.pattern){const t=Array.isArray(this.options.pattern)?this.options.pattern:[this.options.pattern];this.matchers=t.map(t=>new ii(t,{dot:this.options.dot,noglobstar:this.options.noglobstar,matchBase:this.options.matchBase,nocase:this.options.nocase}))}if(this.ignoreMatchers=[],this.options.ignore){const t=Array.isArray(this.options.ignore)?this.options.ignore:[this.options.ignore];this.ignoreMatchers=t.map(t=>new ii(t,{dot:!0}))}if(this.skipMatchers=[],this.options.skip){const t=Array.isArray(this.options.skip)?this.options.skip:[this.options.skip];this.skipMatchers=t.map(t=>new ii(t,{dot:!0}))}this.iterator=async function*(t,e,r,n){yield*ai("",t,e,r,n,!0)}(oi(t||"."),this.options.follow,this.options.stat,this._shouldSkipDirectory.bind(this)),this.paused=!1,this.inactive=!1,this.aborted=!1,r&&(this._matches=[],this.on("match",t=>this._matches.push(this.options.absolute?t.absolute:t.relative)),this.on("error",t=>r(t)),this.on("end",()=>r(null,this._matches))),setTimeout(()=>this._next(),0)}_shouldSkipDirectory(t){return this.skipMatchers.some(e=>e.match(t))}_fileMatches(t,e){const r=t+(e?"/":"");return(0===this.matchers.length||this.matchers.some(t=>t.match(r)))&&!this.ignoreMatchers.some(t=>t.match(r))&&(!this.options.nodir||!e)}_next(){this.paused||this.aborted?this.inactive=!0:this.iterator.next().then(t=>{if(t.done)this.emit("end");else{const e=t.value.stats.isDirectory();if(this._fileMatches(t.value.relative,e)){let r=t.value.relative,n=t.value.absolute;this.options.mark&&e&&(r+="/",n+="/"),this.options.stat?this.emit("match",{relative:r,absolute:n,stat:t.value.stats}):this.emit("match",{relative:r,absolute:n})}this._next(this.iterator)}}).catch(t=>{this.abort(),this.emit("error",t),t.code||this.options.silent||console.error(t)})}abort(){this.aborted=!0}pause(){this.paused=!0}resume(){this.paused=!1,this.inactive&&(this.inactive=!1,this._next())}}function ui(t,e,r){return new li(t,e,r)}function ci(t,...e){return(...r)=>t(...e,...r)}function hi(t){return function(...e){var r=e.pop();return t.call(this,e,r)}}ui.ReaddirGlob=li;var fi="function"==typeof queueMicrotask&&queueMicrotask,di="function"==typeof setImmediate&&setImmediate,pi="object"==typeof process&&"function"==typeof process.nextTick;function yi(t){setTimeout(t,0)}function gi(t){return(e,...r)=>t(()=>e(...r))}var bi=gi(fi?queueMicrotask:di?setImmediate:pi?process.nextTick:yi);function mi(t){return wi(t)?function(...e){const r=e.pop();return _i(t.apply(this,e),r)}:hi(function(e,r){var n;try{n=t.apply(this,e)}catch(t){return r(t)}if(n&&"function"==typeof n.then)return _i(n,r);r(null,n)})}function _i(t,e){return t.then(t=>{vi(e,null,t)},t=>{vi(e,t&&(t instanceof Error||t.message)?t:new Error(t))})}function vi(t,e,r){try{t(e,r)}catch(t){bi(t=>{throw t},t)}}function wi(t){return"AsyncFunction"===t[Symbol.toStringTag]}function Si(t){if("function"!=typeof t)throw new Error("expected a function");return wi(t)?mi(t):t}function Ei(t,e){if(e||(e=t.length),!e)throw new Error("arity is undefined");return function(...r){return"function"==typeof r[e-1]?t.apply(this,r):new Promise((n,i)=>{r[e-1]=(t,...e)=>{if(t)return i(t);n(e.length>1?e:e[0])},t.apply(this,r)})}}function Ri(t){return function(e,...r){return Ei(function(n){var i=this;return t(e,(t,e)=>{Si(t).apply(i,r.concat(e))},n)})}}function ki(t,e,r,n){e=e||[];var i=[],o=0,s=Si(r);return t(e,(t,e,r)=>{var n=o++;s(t,(t,e)=>{i[n]=e,r(t)})},t=>{n(t,i)})}function Ti(t){return t&&"number"==typeof t.length&&t.length>=0&&t.length%1==0}const xi={};function Ai(t){function e(...e){if(null!==t){var r=t;t=null,r.apply(this,e)}}return Object.assign(e,t),e}function Oi(t){if(Ti(t))return function(t){var e=-1,r=t.length;return function(){return++e<r?{value:t[e],key:e}:null}}(t);var e=function(t){return t[Symbol.iterator]&&t[Symbol.iterator]()}(t);return e?function(t){var e=-1;return function(){var r=t.next();return r.done?null:(e++,{value:r.value,key:e})}}(e):function(t){var e=t?Object.keys(t):[],r=-1,n=e.length;return function i(){var o=e[++r];return"__proto__"===o?i():r<n?{value:t[o],key:o}:null}}(t)}function Li(t){return function(...e){if(null===t)throw new Error("Callback was already called.");var r=t;t=null,r.apply(this,e)}}function ji(t,e,r,n){let i=!1,o=!1,s=!1,a=0,l=0;function u(){a>=e||s||i||(s=!0,t.next().then(({value:t,done:e})=>{if(!o&&!i){if(s=!1,e)return i=!0,void(a<=0&&n(null));a++,r(t,l,c),l++,u()}}).catch(h))}function c(t,e){if(a-=1,!o)return t?h(t):!1===t?(i=!0,void(o=!0)):e===xi||i&&a<=0?(i=!0,n(null)):void u()}function h(t){o||(s=!1,i=!0,n(t))}u()}var Mi=t=>(e,r,n)=>{if(n=Ai(n),t<=0)throw new RangeError("concurrency limit cannot be less than 1");if(!e)return n(null);if("AsyncGenerator"===e[Symbol.toStringTag])return ji(e,t,r,n);if(function(t){return"function"==typeof t[Symbol.asyncIterator]}(e))return ji(e[Symbol.asyncIterator](),t,r,n);var i=Oi(e),o=!1,s=!1,a=0,l=!1;function u(t,e){if(!s)if(a-=1,t)o=!0,n(t);else if(!1===t)o=!0,s=!0;else{if(e===xi||o&&a<=0)return o=!0,n(null);l||c()}}function c(){for(l=!0;a<t&&!o;){var e=i();if(null===e)return o=!0,void(a<=0&&n(null));a+=1,r(e.value,e.key,Li(u))}l=!1}c()};var Ii=Ei(function(t,e,r,n){return Mi(e)(t,Si(r),n)},4);function Pi(t,e,r){r=Ai(r);var n=0,i=0,{length:o}=t,s=!1;function a(t,e){!1===t&&(s=!0),!0!==s&&(t?r(t):++i!==o&&e!==xi||r(null))}for(0===o&&r(null);n<o;n++)e(t[n],n,Li(a))}function Di(t,e,r){return Ii(t,1/0,e,r)}var Ci=Ei(function(t,e,r){return(Ti(t)?Pi:Di)(t,Si(e),r)},3);var Ni=Ei(function(t,e,r){return ki(Ci,t,e,r)},3),Fi=Ri(Ni);var Bi=Ei(function(t,e,r){return Ii(t,1,e,r)},3);var Wi=Ei(function(t,e,r){return ki(Bi,t,e,r)},3),Ui=Ri(Wi);const zi=Symbol("promiseCallback");function $i(){let t,e;function r(r,...n){if(r)return e(r);t(n.length>1?n:n[0])}return r[zi]=new Promise((r,n)=>{t=r,e=n}),r}function Hi(t,e,r){"number"!=typeof e&&(r=e,e=null),r=Ai(r||$i());var n=Object.keys(t).length;if(!n)return r(null);e||(e=n);var i={},o=0,s=!1,a=!1,l=Object.create(null),u=[],c=[],h={};function f(t,e){u.push(()=>function(t,e){if(a)return;var n=Li((e,...n)=>{if(o--,!1!==e)if(n.length<2&&([n]=n),e){var u={};if(Object.keys(i).forEach(t=>{u[t]=i[t]}),u[t]=n,a=!0,l=Object.create(null),s)return;r(e,u)}else i[t]=n,(l[t]||[]).forEach(t=>t()),d();else s=!0});o++;var u=Si(e[e.length-1]);e.length>1?u(i,n):u(n)}(t,e))}function d(){if(!s){if(0===u.length&&0===o)return r(null,i);for(;u.length&&o<e;){u.shift()()}}}function p(e){var r=[];return Object.keys(t).forEach(n=>{const i=t[n];Array.isArray(i)&&i.indexOf(e)>=0&&r.push(n)}),r}return Object.keys(t).forEach(e=>{var r=t[e];if(!Array.isArray(r))return f(e,[r]),void c.push(e);var n=r.slice(0,r.length-1),i=n.length;if(0===i)return f(e,r),void c.push(e);h[e]=i,n.forEach(o=>{if(!t[o])throw new Error("async.auto task `"+e+"` has a non-existent dependency `"+o+"` in "+n.join(", "));!function(t,e){var r=l[t];r||(r=l[t]=[]);r.push(e)}(o,()=>{0===--i&&f(e,r)})})}),function(){var t=0;for(;c.length;)t++,p(c.pop()).forEach(t=>{0===--h[t]&&c.push(t)});if(t!==n)throw new Error("async.auto cannot execute tasks due to a recursive dependency")}(),d(),r[zi]}var Gi=/^(?:async\s)?(?:function)?\s*(?:\w+\s*)?\(([^)]+)\)(?:\s*{)/,qi=/^(?:async\s)?\s*(?:\(\s*)?((?:[^)=\s]\s*)*)(?:\)\s*)?=>/,Vi=/,/,Zi=/(=.+)?(\s*)$/;function Yi(t,e){var r={};return Object.keys(t).forEach(e=>{var n,i=t[e],o=wi(i),s=!o&&1===i.length||o&&0===i.length;if(Array.isArray(i))n=[...i],i=n.pop(),r[e]=n.concat(n.length>0?a:i);else if(s)r[e]=i;else{if(n=function(t){const e=function(t){let e="",r=0,n=t.indexOf("*/");for(;r<t.length;)if("/"===t[r]&&"/"===t[r+1]){let e=t.indexOf("\n",r);r=-1===e?t.length:e}else if(-1!==n&&"/"===t[r]&&"*"===t[r+1]){let i=t.indexOf("*/",r);-1!==i?(r=i+2,n=t.indexOf("*/",r)):(e+=t[r],r++)}else e+=t[r],r++;return e}(t.toString());let r=e.match(Gi);if(r||(r=e.match(qi)),!r)throw new Error("could not parse args in autoInject\nSource:\n"+e);let[,n]=r;return n.replace(/\s/g,"").split(Vi).map(t=>t.replace(Zi,"").trim())}(i),0===i.length&&!o&&0===n.length)throw new Error("autoInject task functions require explicit parameters.");o||n.pop(),r[e]=n.concat(a)}function a(t,e){var r=n.map(e=>t[e]);r.push(e),Si(i)(...r)}}),Hi(r,e)}class Ki{constructor(){this.head=this.tail=null,this.length=0}removeLink(t){return t.prev?t.prev.next=t.next:this.head=t.next,t.next?t.next.prev=t.prev:this.tail=t.prev,t.prev=t.next=null,this.length-=1,t}empty(){for(;this.head;)this.shift();return this}insertAfter(t,e){e.prev=t,e.next=t.next,t.next?t.next.prev=e:this.tail=e,t.next=e,this.length+=1}insertBefore(t,e){e.prev=t.prev,e.next=t,t.prev?t.prev.next=e:this.head=e,t.prev=e,this.length+=1}unshift(t){this.head?this.insertBefore(this.head,t):Qi(this,t)}push(t){this.tail?this.insertAfter(this.tail,t):Qi(this,t)}shift(){return this.head&&this.removeLink(this.head)}pop(){return this.tail&&this.removeLink(this.tail)}toArray(){return[...this]}*[Symbol.iterator](){for(var t=this.head;t;)yield t.data,t=t.next}remove(t){for(var e=this.head;e;){var{next:r}=e;t(e)&&this.removeLink(e),e=r}return this}}function Qi(t,e){t.length=1,t.head=t.tail=e}function Ji(t,e,r){if(null==e)e=1;else if(0===e)throw new RangeError("Concurrency must not be zero");var n=Si(t),i=0,o=[];const s={error:[],drain:[],saturated:[],unsaturated:[],empty:[]};function a(t,e){return t?e?void(s[t]=s[t].filter(t=>t!==e)):s[t]=[]:Object.keys(s).forEach(t=>s[t]=[])}function l(t,...e){s[t].forEach(t=>t(...e))}var u=!1;function c(t,e,r,n){if(null!=n&&"function"!=typeof n)throw new Error("task callback must be a function");var i,o;function s(t,...e){return t?r?o(t):i():e.length<=1?i(e[0]):void i(e)}y.started=!0;var a=y._createTaskItem(t,r?s:n||s);if(e?y._tasks.unshift(a):y._tasks.push(a),u||(u=!0,bi(()=>{u=!1,y.process()})),r||!n)return new Promise((t,e)=>{i=t,o=e})}function h(t){return function(e,...r){i-=1;for(var n=0,s=t.length;n<s;n++){var a=t[n],u=o.indexOf(a);0===u?o.shift():u>0&&o.splice(u,1),a.callback(e,...r),null!=e&&l("error",e,a.data)}i<=y.concurrency-y.buffer&&l("unsaturated"),y.idle()&&l("drain"),y.process()}}function f(t){return!(0!==t.length||!y.idle())&&(bi(()=>l("drain")),!0)}const d=t=>e=>{if(!e)return new Promise((e,r)=>{!function(t,e){const r=(...n)=>{a(t,r),e(...n)};s[t].push(r)}(t,(t,n)=>{if(t)return r(t);e(n)})});a(t),function(t,e){s[t].push(e)}(t,e)};var p=!1,y={_tasks:new Ki,_createTaskItem:(t,e)=>({data:t,callback:e}),*[Symbol.iterator](){yield*y._tasks[Symbol.iterator]()},concurrency:e,payload:r,buffer:e/4,started:!1,paused:!1,push(t,e){if(Array.isArray(t)){if(f(t))return;return t.map(t=>c(t,!1,!1,e))}return c(t,!1,!1,e)},pushAsync(t,e){if(Array.isArray(t)){if(f(t))return;return t.map(t=>c(t,!1,!0,e))}return c(t,!1,!0,e)},kill(){a(),y._tasks.empty()},unshift(t,e){if(Array.isArray(t)){if(f(t))return;return t.map(t=>c(t,!0,!1,e))}return c(t,!0,!1,e)},unshiftAsync(t,e){if(Array.isArray(t)){if(f(t))return;return t.map(t=>c(t,!0,!0,e))}return c(t,!0,!0,e)},remove(t){y._tasks.remove(t)},process(){if(!p){for(p=!0;!y.paused&&i<y.concurrency&&y._tasks.length;){var t=[],e=[],r=y._tasks.length;y.payload&&(r=Math.min(r,y.payload));for(var s=0;s<r;s++){var a=y._tasks.shift();t.push(a),o.push(a),e.push(a.data)}i+=1,0===y._tasks.length&&l("empty"),i===y.concurrency&&l("saturated");var u=Li(h(t));n(e,u)}p=!1}},length:()=>y._tasks.length,running:()=>i,workersList:()=>o,idle:()=>y._tasks.length+i===0,pause(){y.paused=!0},resume(){!1!==y.paused&&(y.paused=!1,bi(y.process))}};return Object.defineProperties(y,{saturated:{writable:!1,value:d("saturated")},unsaturated:{writable:!1,value:d("unsaturated")},empty:{writable:!1,value:d("empty")},drain:{writable:!1,value:d("drain")},error:{writable:!1,value:d("error")}}),y}function Xi(t,e){return Ji(t,1,e)}function to(t,e,r){return Ji(t,e,r)}var eo=Ei(function(t,e,r,n){n=Ai(n);var i=Si(r);return Bi(t,(t,r,n)=>{i(e,t,(t,r)=>{e=r,n(t)})},t=>n(t,e))},4);function ro(...t){var e=t.map(Si);return function(...t){var r=this,n=t[t.length-1];return"function"==typeof n?t.pop():n=$i(),eo(e,t,(t,e,n)=>{e.apply(r,t.concat((t,...e)=>{n(t,e)}))},(t,e)=>n(t,...e)),n[zi]}}function no(...t){return ro(...t.reverse())}var io=Ei(function(t,e,r,n){return ki(Mi(e),t,r,n)},4);var oo=Ei(function(t,e,r,n){var i=Si(r);return io(t,e,(t,e)=>{i(t,(t,...r)=>t?e(t):e(t,r))},(t,e)=>{for(var r=[],i=0;i<e.length;i++)e[i]&&(r=r.concat(...e[i]));return n(t,r)})},4);var so=Ei(function(t,e,r){return oo(t,1/0,e,r)},3);var ao=Ei(function(t,e,r){return oo(t,1,e,r)},3);function lo(...t){return function(...e){return e.pop()(null,...t)}}function uo(t,e){return(r,n,i,o)=>{var s,a=!1;const l=Si(i);r(n,(r,n,i)=>{l(r,(n,o)=>n||!1===n?i(n):t(o)&&!s?(a=!0,s=e(!0,r),i(null,xi)):void i())},t=>{if(t)return o(t);o(null,a?s:e(!1))})}}var co=Ei(function(t,e,r){return uo(t=>t,(t,e)=>e)(Ci,t,e,r)},3);var ho=Ei(function(t,e,r,n){return uo(t=>t,(t,e)=>e)(Mi(e),t,r,n)},4);var fo=Ei(function(t,e,r){return uo(t=>t,(t,e)=>e)(Mi(1),t,e,r)},3);function po(t){return(e,...r)=>Si(e)(...r,(e,...r)=>{"object"==typeof console&&(e?console.error&&console.error(e):console[t]&&r.forEach(e=>console[t](e)))})}var yo=po("dir");var go=Ei(function(t,e,r){r=Li(r);var n,i=Si(t),o=Si(e);function s(t,...e){if(t)return r(t);!1!==t&&(n=e,o(...e,a))}function a(t,e){return t?r(t):!1!==t?e?void i(s):r(null,...n):void 0}return a(null,!0)},3);function bo(t,e,r){const n=Si(e);return go(t,(...t)=>{const e=t.pop();n(...t,(t,r)=>e(t,!r))},r)}function mo(t){return(e,r,n)=>t(e,n)}var _o=Ei(function(t,e,r){return Ci(t,mo(Si(e)),r)},3);var vo=Ei(function(t,e,r,n){return Mi(e)(t,mo(Si(r)),n)},4);var wo=Ei(function(t,e,r){return vo(t,1,e,r)},3);function So(t){return wi(t)?t:function(...e){var r=e.pop(),n=!0;e.push((...t)=>{n?bi(()=>r(...t)):r(...t)}),t.apply(this,e),n=!1}}var Eo=Ei(function(t,e,r){return uo(t=>!t,t=>!t)(Ci,t,e,r)},3);var Ro=Ei(function(t,e,r,n){return uo(t=>!t,t=>!t)(Mi(e),t,r,n)},4);var ko=Ei(function(t,e,r){return uo(t=>!t,t=>!t)(Bi,t,e,r)},3);function To(t,e,r,n){var i=new Array(e.length);t(e,(t,e,n)=>{r(t,(t,r)=>{i[e]=!!r,n(t)})},t=>{if(t)return n(t);for(var r=[],o=0;o<e.length;o++)i[o]&&r.push(e[o]);n(null,r)})}function xo(t,e,r,n){var i=[];t(e,(t,e,n)=>{r(t,(r,o)=>{if(r)return n(r);o&&i.push({index:e,value:t}),n(r)})},t=>{if(t)return n(t);n(null,i.sort((t,e)=>t.index-e.index).map(t=>t.value))})}function Ao(t,e,r,n){return(Ti(e)?To:xo)(t,e,Si(r),n)}var Oo=Ei(function(t,e,r){return Ao(Ci,t,e,r)},3);var Lo=Ei(function(t,e,r,n){return Ao(Mi(e),t,r,n)},4);var jo=Ei(function(t,e,r){return Ao(Bi,t,e,r)},3);var Mo=Ei(function(t,e){var r=Li(e),n=Si(So(t));return function t(e){if(e)return r(e);!1!==e&&n(t)}()},2);var Io=Ei(function(t,e,r,n){var i=Si(r);return io(t,e,(t,e)=>{i(t,(r,n)=>r?e(r):e(r,{key:n,val:t}))},(t,e)=>{for(var r={},{hasOwnProperty:i}=Object.prototype,o=0;o<e.length;o++)if(e[o]){var{key:s}=e[o],{val:a}=e[o];i.call(r,s)?r[s].push(a):r[s]=[a]}return n(t,r)})},4);function Po(t,e,r){return Io(t,1/0,e,r)}function Do(t,e,r){return Io(t,1,e,r)}var Co=po("log");var No=Ei(function(t,e,r,n){n=Ai(n);var i={},o=Si(r);return Mi(e)(t,(t,e,r)=>{o(t,e,(t,n)=>{if(t)return r(t);i[e]=n,r(t)})},t=>n(t,i))},4);function Fo(t,e,r){return No(t,1/0,e,r)}function Bo(t,e,r){return No(t,1,e,r)}function Wo(t,e=t=>t){var r=Object.create(null),n=Object.create(null),i=Si(t),o=hi((t,o)=>{var s=e(...t);s in r?bi(()=>o(null,...r[s])):s in n?n[s].push(o):(n[s]=[o],i(...t,(t,...e)=>{t||(r[s]=e);var i=n[s];delete n[s];for(var o=0,a=i.length;o<a;o++)i[o](t,...e)}))});return o.memo=r,o.unmemoized=t,o}var Uo=gi(pi?process.nextTick:di?setImmediate:yi),zo=Ei((t,e,r)=>{var n=Ti(e)?[]:{};t(e,(t,e,r)=>{Si(t)((t,...i)=>{i.length<2&&([i]=i),n[e]=i,r(t)})},t=>r(t,n))},3);function $o(t,e){return zo(Ci,t,e)}function Ho(t,e,r){return zo(Mi(e),t,r)}function Go(t,e){var r=Si(t);return Ji((t,e)=>{r(t[0],e)},e,1)}class qo{constructor(){this.heap=[],this.pushCount=Number.MIN_SAFE_INTEGER}get length(){return this.heap.length}empty(){return this.heap=[],this}percUp(t){let e;for(;t>0&&Yo(this.heap[t],this.heap[e=Zo(t)]);){let r=this.heap[t];this.heap[t]=this.heap[e],this.heap[e]=r,t=e}}percDown(t){let e;for(;(e=Vo(t))<this.heap.length&&(e+1<this.heap.length&&Yo(this.heap[e+1],this.heap[e])&&(e+=1),!Yo(this.heap[t],this.heap[e]));){let r=this.heap[t];this.heap[t]=this.heap[e],this.heap[e]=r,t=e}}push(t){t.pushCount=++this.pushCount,this.heap.push(t),this.percUp(this.heap.length-1)}unshift(t){return this.heap.push(t)}shift(){let[t]=this.heap;return this.heap[0]=this.heap[this.heap.length-1],this.heap.pop(),this.percDown(0),t}toArray(){return[...this]}*[Symbol.iterator](){for(let t=0;t<this.heap.length;t++)yield this.heap[t].data}remove(t){let e=0;for(let r=0;r<this.heap.length;r++)t(this.heap[r])||(this.heap[e]=this.heap[r],e++);this.heap.splice(e);for(let t=Zo(this.heap.length-1);t>=0;t--)this.percDown(t);return this}}function Vo(t){return 1+(t<<1)}function Zo(t){return(t+1>>1)-1}function Yo(t,e){return t.priority!==e.priority?t.priority<e.priority:t.pushCount<e.pushCount}function Ko(t,e){var r=Go(t,e),{push:n,pushAsync:i}=r;function o(t,e){return Array.isArray(t)?t.map(t=>({data:t,priority:e})):{data:t,priority:e}}return r._tasks=new qo,r._createTaskItem=({data:t,priority:e},r)=>({data:t,priority:e,callback:r}),r.push=function(t,e=0,r){return n(o(t,e),r)},r.pushAsync=function(t,e=0,r){return i(o(t,e),r)},delete r.unshift,delete r.unshiftAsync,r}var Qo=Ei(function(t,e){if(e=Ai(e),!Array.isArray(t))return e(new TypeError("First argument to race must be an array of functions"));if(!t.length)return e();for(var r=0,n=t.length;r<n;r++)Si(t[r])(e)},2);function Jo(t,e,r,n){var i=[...t].reverse();return eo(i,e,r,n)}function Xo(t){var e=Si(t);return hi(function(t,r){return t.push((t,...e)=>{let n={};if(t&&(n.error=t),e.length>0){var i=e;e.length<=1&&([i]=e),n.value=i}r(null,n)}),e.apply(this,t)})}function ts(t){var e;return Array.isArray(t)?e=t.map(Xo):(e={},Object.keys(t).forEach(r=>{e[r]=Xo.call(this,t[r])})),e}function es(t,e,r,n){const i=Si(r);return Ao(t,e,(t,e)=>{i(t,(t,r)=>{e(t,!r)})},n)}var rs=Ei(function(t,e,r){return es(Ci,t,e,r)},3);var ns=Ei(function(t,e,r,n){return es(Mi(e),t,r,n)},4);var is=Ei(function(t,e,r){return es(Bi,t,e,r)},3);function os(t){return function(){return t}}function ss(t,e,r){var n={times:5,intervalFunc:os(0)};if(arguments.length<3&&"function"==typeof t?(r=e||$i(),e=t):(!function(t,e){if("object"==typeof e)t.times=+e.times||5,t.intervalFunc="function"==typeof e.interval?e.interval:os(+e.interval||0),t.errorFilter=e.errorFilter;else{if("number"!=typeof e&&"string"!=typeof e)throw new Error("Invalid arguments for async.retry");t.times=+e||5}}(n,t),r=r||$i()),"function"!=typeof e)throw new Error("Invalid arguments for async.retry");var i=Si(e),o=1;return function t(){i((e,...i)=>{!1!==e&&(e&&o++<n.times&&("function"!=typeof n.errorFilter||n.errorFilter(e))?setTimeout(t,n.intervalFunc(o-1)):r(e,...i))})}(),r[zi]}function as(t,e){e||(e=t,t=null);let r=t&&t.arity||e.length;wi(e)&&(r+=1);var n=Si(e);return hi((e,i)=>{function o(t){n(...e,t)}return(e.length<r-1||null==i)&&(e.push(i),i=$i()),t?ss(t,o,i):ss(o,i),i[zi]})}function ls(t,e){return zo(Bi,t,e)}var us=Ei(function(t,e,r){return uo(Boolean,t=>t)(Ci,t,e,r)},3);var cs=Ei(function(t,e,r,n){return uo(Boolean,t=>t)(Mi(e),t,r,n)},4);var hs=Ei(function(t,e,r){return uo(Boolean,t=>t)(Bi,t,e,r)},3);var fs=Ei(function(t,e,r){var n=Si(e);return Ni(t,(t,e)=>{n(t,(r,n)=>{if(r)return e(r);e(r,{value:t,criteria:n})})},(t,e)=>{if(t)return r(t);r(null,e.sort(i).map(t=>t.value))});function i(t,e){var r=t.criteria,n=e.criteria;return r<n?-1:r>n?1:0}},3);function ds(t,e,r){var n=Si(t);return hi((i,o)=>{var s,a=!1;i.push((...t)=>{a||(o(...t),clearTimeout(s))}),s=setTimeout(function(){var e=t.name||"anonymous",n=new Error('Callback function "'+e+'" timed out.');n.code="ETIMEDOUT",r&&(n.info=r),a=!0,o(n)},e),n(...i)})}function ps(t,e,r,n){var i=Si(r);return io(function(t){for(var e=Array(t);t--;)e[t]=t;return e}(t),e,i,n)}function ys(t,e,r){return ps(t,1/0,e,r)}function gs(t,e,r){return ps(t,1,e,r)}function bs(t,e,r,n){arguments.length<=3&&"function"==typeof e&&(n=r,r=e,e=Array.isArray(t)?[]:{}),n=Ai(n||$i());var i=Si(r);return Ci(t,(t,r,n)=>{i(e,t,r,n)},t=>n(t,e)),n[zi]}var ms=Ei(function(t,e){var r,n=null;return wo(t,(t,e)=>{Si(t)((t,...i)=>{if(!1===t)return e(t);i.length<2?[r]=i:r=i,n=t,e(t?null:{})})},()=>e(n,r))});function _s(t){return(...e)=>(t.unmemoized||t)(...e)}var vs=Ei(function(t,e,r){r=Li(r);var n=Si(e),i=Si(t),o=[];function s(t,...e){if(t)return r(t);o=e,!1!==t&&i(a)}function a(t,e){return t?r(t):!1!==t?e?void n(s):r(null,...o):void 0}return i(a)},3);function ws(t,e,r){const n=Si(t);return vs(t=>n((e,r)=>t(e,!r)),e,r)}var Ss=Ei(function(t,e){if(e=Ai(e),!Array.isArray(t))return e(new Error("First argument to waterfall must be an array of functions"));if(!t.length)return e();var r=0;function n(e){Si(t[r++])(...e,Li(i))}function i(i,...o){if(!1!==i)return i||r===t.length?e(i,...o):void n(o)}n([])}),Es={apply:ci,applyEach:Fi,applyEachSeries:Ui,asyncify:mi,auto:Hi,autoInject:Yi,cargo:Xi,cargoQueue:to,compose:no,concat:so,concatLimit:oo,concatSeries:ao,constant:lo,detect:co,detectLimit:ho,detectSeries:fo,dir:yo,doUntil:bo,doWhilst:go,each:_o,eachLimit:vo,eachOf:Ci,eachOfLimit:Ii,eachOfSeries:Bi,eachSeries:wo,ensureAsync:So,every:Eo,everyLimit:Ro,everySeries:ko,filter:Oo,filterLimit:Lo,filterSeries:jo,forever:Mo,groupBy:Po,groupByLimit:Io,groupBySeries:Do,log:Co,map:Ni,mapLimit:io,mapSeries:Wi,mapValues:Fo,mapValuesLimit:No,mapValuesSeries:Bo,memoize:Wo,nextTick:Uo,parallel:$o,parallelLimit:Ho,priorityQueue:Ko,queue:Go,race:Qo,reduce:eo,reduceRight:Jo,reflect:Xo,reflectAll:ts,reject:rs,rejectLimit:ns,rejectSeries:is,retry:ss,retryable:as,seq:ro,series:ls,setImmediate:bi,some:us,someLimit:cs,someSeries:hs,sortBy:fs,timeout:ds,times:ys,timesLimit:ps,timesSeries:gs,transform:bs,tryEach:ms,unmemoize:_s,until:ws,waterfall:Ss,whilst:vs,all:Eo,allLimit:Ro,allSeries:ko,any:us,anyLimit:cs,anySeries:hs,find:co,findLimit:ho,findSeries:fo,flatMap:so,flatMapLimit:oo,flatMapSeries:ao,forEach:_o,forEachSeries:wo,forEachLimit:vo,forEachOf:Ci,forEachOfSeries:Bi,forEachOfLimit:Ii,inject:eo,foldl:eo,foldr:Jo,select:Oo,selectLimit:Lo,selectSeries:jo,wrapSync:mi,during:vs,doDuring:go},Rs=Wt(Object.freeze({__proto__:null,all:Eo,allLimit:Ro,allSeries:ko,any:us,anyLimit:cs,anySeries:hs,apply:ci,applyEach:Fi,applyEachSeries:Ui,asyncify:mi,auto:Hi,autoInject:Yi,cargo:Xi,cargoQueue:to,compose:no,concat:so,concatLimit:oo,concatSeries:ao,constant:lo,default:Es,detect:co,detectLimit:ho,detectSeries:fo,dir:yo,doDuring:go,doUntil:bo,doWhilst:go,during:vs,each:_o,eachLimit:vo,eachOf:Ci,eachOfLimit:Ii,eachOfSeries:Bi,eachSeries:wo,ensureAsync:So,every:Eo,everyLimit:Ro,everySeries:ko,filter:Oo,filterLimit:Lo,filterSeries:jo,find:co,findLimit:ho,findSeries:fo,flatMap:so,flatMapLimit:oo,flatMapSeries:ao,foldl:eo,foldr:Jo,forEach:_o,forEachLimit:vo,forEachOf:Ci,forEachOfLimit:Ii,forEachOfSeries:Bi,forEachSeries:wo,forever:Mo,groupBy:Po,groupByLimit:Io,groupBySeries:Do,inject:eo,log:Co,map:Ni,mapLimit:io,mapSeries:Wi,mapValues:Fo,mapValuesLimit:No,mapValuesSeries:Bo,memoize:Wo,nextTick:Uo,parallel:$o,parallelLimit:Ho,priorityQueue:Ko,queue:Go,race:Qo,reduce:eo,reduceRight:Jo,reflect:Xo,reflectAll:ts,reject:rs,rejectLimit:ns,rejectSeries:is,retry:ss,retryable:as,select:Oo,selectLimit:Lo,selectSeries:jo,seq:ro,series:ls,setImmediate:bi,some:us,someLimit:cs,someSeries:hs,sortBy:fs,timeout:ds,times:ys,timesLimit:ps,timesSeries:gs,transform:bs,tryEach:ms,unmemoize:_s,until:ws,waterfall:Ss,whilst:vs,wrapSync:mi})),ks={exports:{}},Ts=o,xs=process.cwd,As=null,Os=process.env.GRACEFUL_FS_PLATFORM||process.platform;process.cwd=function(){return As||(As=xs.call(process)),As};try{process.cwd()}catch(t){}if("function"==typeof process.chdir){var Ls=process.chdir;process.chdir=function(t){As=null,Ls.call(process,t)},Object.setPrototypeOf&&Object.setPrototypeOf(process.chdir,Ls)}var js=function(t){Ts.hasOwnProperty("O_SYMLINK")&&process.version.match(/^v0\.6\.[0-2]|^v0\.5\./)&&function(t){t.lchmod=function(e,r,n){t.open(e,Ts.O_WRONLY|Ts.O_SYMLINK,r,function(e,i){e?n&&n(e):t.fchmod(i,r,function(e){t.close(i,function(t){n&&n(e||t)})})})},t.lchmodSync=function(e,r){var n,i=t.openSync(e,Ts.O_WRONLY|Ts.O_SYMLINK,r),o=!0;try{n=t.fchmodSync(i,r),o=!1}finally{if(o)try{t.closeSync(i)}catch(t){}else t.closeSync(i)}return n}}(t);t.lutimes||function(t){Ts.hasOwnProperty("O_SYMLINK")&&t.futimes?(t.lutimes=function(e,r,n,i){t.open(e,Ts.O_SYMLINK,function(e,o){e?i&&i(e):t.futimes(o,r,n,function(e){t.close(o,function(t){i&&i(e||t)})})})},t.lutimesSync=function(e,r,n){var i,o=t.openSync(e,Ts.O_SYMLINK),s=!0;try{i=t.futimesSync(o,r,n),s=!1}finally{if(s)try{t.closeSync(o)}catch(t){}else t.closeSync(o)}return i}):t.futimes&&(t.lutimes=function(t,e,r,n){n&&process.nextTick(n)},t.lutimesSync=function(){})}(t);t.chown=n(t.chown),t.fchown=n(t.fchown),t.lchown=n(t.lchown),t.chmod=e(t.chmod),t.fchmod=e(t.fchmod),t.lchmod=e(t.lchmod),t.chownSync=i(t.chownSync),t.fchownSync=i(t.fchownSync),t.lchownSync=i(t.lchownSync),t.chmodSync=r(t.chmodSync),t.fchmodSync=r(t.fchmodSync),t.lchmodSync=r(t.lchmodSync),t.stat=o(t.stat),t.fstat=o(t.fstat),t.lstat=o(t.lstat),t.statSync=s(t.statSync),t.fstatSync=s(t.fstatSync),t.lstatSync=s(t.lstatSync),t.chmod&&!t.lchmod&&(t.lchmod=function(t,e,r){r&&process.nextTick(r)},t.lchmodSync=function(){});t.chown&&!t.lchown&&(t.lchown=function(t,e,r,n){n&&process.nextTick(n)},t.lchownSync=function(){});"win32"===Os&&(t.rename="function"!=typeof t.rename?t.rename:function(e){function r(r,n,i){var o=Date.now(),s=0;e(r,n,function a(l){if(l&&("EACCES"===l.code||"EPERM"===l.code||"EBUSY"===l.code)&&Date.now()-o<6e4)return setTimeout(function(){t.stat(n,function(t,o){t&&"ENOENT"===t.code?e(r,n,a):i(l)})},s),void(s<100&&(s+=10));i&&i(l)})}return Object.setPrototypeOf&&Object.setPrototypeOf(r,e),r}(t.rename));function e(e){return e?function(r,n,i){return e.call(t,r,n,function(t){a(t)&&(t=null),i&&i.apply(this,arguments)})}:e}function r(e){return e?function(r,n){try{return e.call(t,r,n)}catch(t){if(!a(t))throw t}}:e}function n(e){return e?function(r,n,i,o){return e.call(t,r,n,i,function(t){a(t)&&(t=null),o&&o.apply(this,arguments)})}:e}function i(e){return e?function(r,n,i){try{return e.call(t,r,n,i)}catch(t){if(!a(t))throw t}}:e}function o(e){return e?function(r,n,i){function o(t,e){e&&(e.uid<0&&(e.uid+=4294967296),e.gid<0&&(e.gid+=4294967296)),i&&i.apply(this,arguments)}return"function"==typeof n&&(i=n,n=null),n?e.call(t,r,n,o):e.call(t,r,o)}:e}function s(e){return e?function(r,n){var i=n?e.call(t,r,n):e.call(t,r);return i&&(i.uid<0&&(i.uid+=4294967296),i.gid<0&&(i.gid+=4294967296)),i}:e}function a(t){return!t||("ENOSYS"===t.code||!(process.getuid&&0===process.getuid()||"EINVAL"!==t.code&&"EPERM"!==t.code))}t.read="function"!=typeof t.read?t.read:function(e){function r(r,n,i,o,s,a){var l;if(a&&"function"==typeof a){var u=0;l=function(c,h,f){if(c&&"EAGAIN"===c.code&&u<10)return u++,e.call(t,r,n,i,o,s,l);a.apply(this,arguments)}}return e.call(t,r,n,i,o,s,l)}return Object.setPrototypeOf&&Object.setPrototypeOf(r,e),r}(t.read),t.readSync="function"!=typeof t.readSync?t.readSync:(l=t.readSync,function(e,r,n,i,o){for(var s=0;;)try{return l.call(t,e,r,n,i,o)}catch(t){if("EAGAIN"===t.code&&s<10){s++;continue}throw t}});var l};var Ms=i.Stream,Is=function(t){return{ReadStream:function e(r,n){if(!(this instanceof e))return new e(r,n);Ms.call(this);var i=this;this.path=r,this.fd=null,this.readable=!0,this.paused=!1,this.flags="r",this.mode=438,this.bufferSize=65536,n=n||{};for(var o=Object.keys(n),s=0,a=o.length;s<a;s++){var l=o[s];this[l]=n[l]}this.encoding&&this.setEncoding(this.encoding);if(void 0!==this.start){if("number"!=typeof this.start)throw TypeError("start must be a Number");if(void 0===this.end)this.end=1/0;else if("number"!=typeof this.end)throw TypeError("end must be a Number");if(this.start>this.end)throw new Error("start must be <= end");this.pos=this.start}if(null!==this.fd)return void process.nextTick(function(){i._read()});t.open(this.path,this.flags,this.mode,function(t,e){if(t)return i.emit("error",t),void(i.readable=!1);i.fd=e,i.emit("open",e),i._read()})},WriteStream:function e(r,n){if(!(this instanceof e))return new e(r,n);Ms.call(this),this.path=r,this.fd=null,this.writable=!0,this.flags="w",this.encoding="binary",this.mode=438,this.bytesWritten=0,n=n||{};for(var i=Object.keys(n),o=0,s=i.length;o<s;o++){var a=i[o];this[a]=n[a]}if(void 0!==this.start){if("number"!=typeof this.start)throw TypeError("start must be a Number");if(this.start<0)throw new Error("start must be >= zero");this.pos=this.start}this.busy=!1,this._queue=[],null===this.fd&&(this._open=t.open,this._queue.push([this._open,this.path,this.flags,this.mode,void 0]),this.flush())}}};var Ps=function(t){if(null===t||"object"!=typeof t)return t;if(t instanceof Object)var e={__proto__:Ds(t)};else e=Object.create(null);return Object.getOwnPropertyNames(t).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e},Ds=Object.getPrototypeOf||function(t){return t.__proto__};var Cs,Ns,Fs=t,Bs=js,Ws=Is,Us=Ps,zs=s;function $s(t,e){Object.defineProperty(t,Cs,{get:function(){return e}})}"function"==typeof Symbol&&"function"==typeof Symbol.for?(Cs=Symbol.for("graceful-fs.queue"),Ns=Symbol.for("graceful-fs.previous")):(Cs="___graceful-fs.queue",Ns="___graceful-fs.previous");var Hs=function(){};if(zs.debuglog?Hs=zs.debuglog("gfs4"):/\bgfs4\b/i.test(process.env.NODE_DEBUG||"")&&(Hs=function(){var t=zs.format.apply(zs,arguments);t="GFS4: "+t.split(/\n/).join("\nGFS4: "),console.error(t)}),!Fs[Cs]){var Gs=Ft[Cs]||[];$s(Fs,Gs),Fs.close=function(t){function e(e,r){return t.call(Fs,e,function(t){t||Ks(),"function"==typeof r&&r.apply(this,arguments)})}return Object.defineProperty(e,Ns,{value:t}),e}(Fs.close),Fs.closeSync=function(t){function e(e){t.apply(Fs,arguments),Ks()}return Object.defineProperty(e,Ns,{value:t}),e}(Fs.closeSync),/\bgfs4\b/i.test(process.env.NODE_DEBUG||"")&&process.on("exit",function(){Hs(Fs[Cs]),a.equal(Fs[Cs].length,0)})}Ft[Cs]||$s(Ft,Fs[Cs]);var qs,Vs=Zs(Us(Fs));function Zs(t){Bs(t),t.gracefulify=Zs,t.createReadStream=function(e,r){return new t.ReadStream(e,r)},t.createWriteStream=function(e,r){return new t.WriteStream(e,r)};var e=t.readFile;t.readFile=function(t,r,n){"function"==typeof r&&(n=r,r=null);return function t(r,n,i,o){return e(r,n,function(e){!e||"EMFILE"!==e.code&&"ENFILE"!==e.code?"function"==typeof i&&i.apply(this,arguments):Ys([t,[r,n,i],e,o||Date.now(),Date.now()])})}(t,r,n)};var r=t.writeFile;t.writeFile=function(t,e,n,i){"function"==typeof n&&(i=n,n=null);return function t(e,n,i,o,s){return r(e,n,i,function(r){!r||"EMFILE"!==r.code&&"ENFILE"!==r.code?"function"==typeof o&&o.apply(this,arguments):Ys([t,[e,n,i,o],r,s||Date.now(),Date.now()])})}(t,e,n,i)};var n=t.appendFile;n&&(t.appendFile=function(t,e,r,i){"function"==typeof r&&(i=r,r=null);return function t(e,r,i,o,s){return n(e,r,i,function(n){!n||"EMFILE"!==n.code&&"ENFILE"!==n.code?"function"==typeof o&&o.apply(this,arguments):Ys([t,[e,r,i,o],n,s||Date.now(),Date.now()])})}(t,e,r,i)});var i=t.copyFile;i&&(t.copyFile=function(t,e,r,n){"function"==typeof r&&(n=r,r=0);return function t(e,r,n,o,s){return i(e,r,n,function(i){!i||"EMFILE"!==i.code&&"ENFILE"!==i.code?"function"==typeof o&&o.apply(this,arguments):Ys([t,[e,r,n,o],i,s||Date.now(),Date.now()])})}(t,e,r,n)});var o=t.readdir;t.readdir=function(t,e,r){"function"==typeof e&&(r=e,e=null);var n=s.test(process.version)?function(t,e,r,n){return o(t,i(t,e,r,n))}:function(t,e,r,n){return o(t,e,i(t,e,r,n))};return n(t,e,r);function i(t,e,r,i){return function(o,s){!o||"EMFILE"!==o.code&&"ENFILE"!==o.code?(s&&s.sort&&s.sort(),"function"==typeof r&&r.call(this,o,s)):Ys([n,[t,e,r],o,i||Date.now(),Date.now()])}}};var s=/^v[0-5]\./;if("v0.8"===process.version.substr(0,4)){var a=Ws(t);f=a.ReadStream,d=a.WriteStream}var l=t.ReadStream;l&&(f.prototype=Object.create(l.prototype),f.prototype.open=function(){var t=this;y(t.path,t.flags,t.mode,function(e,r){e?(t.autoClose&&t.destroy(),t.emit("error",e)):(t.fd=r,t.emit("open",r),t.read())})});var u=t.WriteStream;u&&(d.prototype=Object.create(u.prototype),d.prototype.open=function(){var t=this;y(t.path,t.flags,t.mode,function(e,r){e?(t.destroy(),t.emit("error",e)):(t.fd=r,t.emit("open",r))})}),Object.defineProperty(t,"ReadStream",{get:function(){return f},set:function(t){f=t},enumerable:!0,configurable:!0}),Object.defineProperty(t,"WriteStream",{get:function(){return d},set:function(t){d=t},enumerable:!0,configurable:!0});var c=f;Object.defineProperty(t,"FileReadStream",{get:function(){return c},set:function(t){c=t},enumerable:!0,configurable:!0});var h=d;function f(t,e){return this instanceof f?(l.apply(this,arguments),this):f.apply(Object.create(f.prototype),arguments)}function d(t,e){return this instanceof d?(u.apply(this,arguments),this):d.apply(Object.create(d.prototype),arguments)}Object.defineProperty(t,"FileWriteStream",{get:function(){return h},set:function(t){h=t},enumerable:!0,configurable:!0});var p=t.open;function y(t,e,r,n){return"function"==typeof r&&(n=r,r=null),function t(e,r,n,i,o){return p(e,r,n,function(s,a){!s||"EMFILE"!==s.code&&"ENFILE"!==s.code?"function"==typeof i&&i.apply(this,arguments):Ys([t,[e,r,n,i],s,o||Date.now(),Date.now()])})}(t,e,r,n)}return t.open=y,t}function Ys(t){Hs("ENQUEUE",t[0].name,t[1]),Fs[Cs].push(t),Qs()}function Ks(){for(var t=Date.now(),e=0;e<Fs[Cs].length;++e)Fs[Cs][e].length>2&&(Fs[Cs][e][3]=t,Fs[Cs][e][4]=t);Qs()}function Qs(){if(clearTimeout(qs),qs=void 0,0!==Fs[Cs].length){var t=Fs[Cs].shift(),e=t[0],r=t[1],n=t[2],i=t[3],o=t[4];if(void 0===i)Hs("RETRY",e.name,r),e.apply(null,r);else if(Date.now()-i>=6e4){Hs("TIMEOUT",e.name,r);var s=r.pop();"function"==typeof s&&s.call(null,n)}else{var a=Date.now()-o,l=Math.max(o-i,1);a>=Math.min(1.2*l,100)?(Hs("RETRY",e.name,r),e.apply(null,r.concat([i]))):Fs[Cs].push(t)}void 0===qs&&(qs=setTimeout(Qs,0))}}process.env.TEST_GRACEFUL_FS_GLOBAL_PATCH&&!Fs.__patched&&(Vs=Zs(Fs),Fs.__patched=!0);const Js=t=>null!==t&&"object"==typeof t&&"function"==typeof t.pipe;Js.writable=t=>Js(t)&&!1!==t.writable&&"function"==typeof t._write&&"object"==typeof t._writableState,Js.readable=t=>Js(t)&&!1!==t.readable&&"function"==typeof t._read&&"object"==typeof t._readableState,Js.duplex=t=>Js.writable(t)&&Js.readable(t),Js.transform=t=>Js.duplex(t)&&"function"==typeof t._transform;var Xs,ta,ea,ra,na,ia=Js,oa={exports:{}},sa={exports:{}};function aa(){if(Xs)return sa.exports;return Xs=1,"undefined"==typeof process||!process.version||0===process.version.indexOf("v0.")||0===process.version.indexOf("v1.")&&0!==process.version.indexOf("v1.8.")?sa.exports={nextTick:function(t,e,r,n){if("function"!=typeof t)throw new TypeError('"callback" argument must be a function');var i,o,s=arguments.length;switch(s){case 0:case 1:return process.nextTick(t);case 2:return process.nextTick(function(){t.call(null,e)});case 3:return process.nextTick(function(){t.call(null,e,r)});case 4:return process.nextTick(function(){t.call(null,e,r,n)});default:for(i=new Array(s-1),o=0;o<i.length;)i[o++]=arguments[o];return process.nextTick(function(){t.apply(null,i)})}}}:sa.exports=process,sa.exports}function la(){return na?ra:(na=1,ra=yn.EventEmitter)}for(var ua={exports:{}},ca={},ha={byteLength:function(t){var e=ba(t),r=e[0],n=e[1];return 3*(r+n)/4-n},toByteArray:function(t){var e,r,n=ba(t),i=n[0],o=n[1],s=new pa(function(t,e,r){return 3*(e+r)/4-r}(0,i,o)),a=0,l=o>0?i-4:i;for(r=0;r<l;r+=4)e=da[t.charCodeAt(r)]<<18|da[t.charCodeAt(r+1)]<<12|da[t.charCodeAt(r+2)]<<6|da[t.charCodeAt(r+3)],s[a++]=e>>16&255,s[a++]=e>>8&255,s[a++]=255&e;2===o&&(e=da[t.charCodeAt(r)]<<2|da[t.charCodeAt(r+1)]>>4,s[a++]=255&e);1===o&&(e=da[t.charCodeAt(r)]<<10|da[t.charCodeAt(r+1)]<<4|da[t.charCodeAt(r+2)]>>2,s[a++]=e>>8&255,s[a++]=255&e);return s},fromByteArray:function(t){for(var e,r=t.length,n=r%3,i=[],o=16383,s=0,a=r-n;s<a;s+=o)i.push(_a(t,s,s+o>a?a:s+o));1===n?(e=t[r-1],i.push(fa[e>>2]+fa[e<<4&63]+"==")):2===n&&(e=(t[r-2]<<8)+t[r-1],i.push(fa[e>>10]+fa[e>>4&63]+fa[e<<2&63]+"="));return i.join("")}},fa=[],da=[],pa="undefined"!=typeof Uint8Array?Uint8Array:Array,ya="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",ga=0;ga<64;++ga)fa[ga]=ya[ga],da[ya.charCodeAt(ga)]=ga;function ba(t){var e=t.length;if(e%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var r=t.indexOf("=");return-1===r&&(r=e),[r,r===e?0:4-r%4]}function ma(t){return fa[t>>18&63]+fa[t>>12&63]+fa[t>>6&63]+fa[63&t]}function _a(t,e,r){for(var n,i=[],o=e;o<r;o+=3)n=(t[o]<<16&16711680)+(t[o+1]<<8&65280)+(255&t[o+2]),i.push(ma(n));return i.join("")}da["-".charCodeAt(0)]=62,da["_".charCodeAt(0)]=63;var va,wa={};
7
- /*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */function Sa(){return va||(va=1,function(t,e){var r=ca,n=r.Buffer;function i(t,e){for(var r in t)e[r]=t[r]}function o(t,e,r){return n(t,e,r)}n.from&&n.alloc&&n.allocUnsafe&&n.allocUnsafeSlow?t.exports=r:(i(r,e),e.Buffer=o),i(n,o),o.from=function(t,e,r){if("number"==typeof t)throw new TypeError("Argument must not be a number");return n(t,e,r)},o.alloc=function(t,e,r){if("number"!=typeof t)throw new TypeError("Argument must be a number");var i=n(t);return void 0!==e?"string"==typeof r?i.fill(e,r):i.fill(e):i.fill(0),i},o.allocUnsafe=function(t){if("number"!=typeof t)throw new TypeError("Argument must be a number");return n(t)},o.allocUnsafeSlow=function(t){if("number"!=typeof t)throw new TypeError("Argument must be a number");return r.SlowBuffer(t)}}(ua,ua.exports)),ua.exports}wa.read=function(t,e,r,n,i){var o,s,a=8*i-n-1,l=(1<<a)-1,u=l>>1,c=-7,h=r?i-1:0,f=r?-1:1,d=t[e+h];for(h+=f,o=d&(1<<-c)-1,d>>=-c,c+=a;c>0;o=256*o+t[e+h],h+=f,c-=8);for(s=o&(1<<-c)-1,o>>=-c,c+=n;c>0;s=256*s+t[e+h],h+=f,c-=8);if(0===o)o=1-u;else{if(o===l)return s?NaN:1/0*(d?-1:1);s+=Math.pow(2,n),o-=u}return(d?-1:1)*s*Math.pow(2,o-n)},wa.write=function(t,e,r,n,i,o){var s,a,l,u=8*o-i-1,c=(1<<u)-1,h=c>>1,f=23===i?Math.pow(2,-24)-Math.pow(2,-77):0,d=n?0:o-1,p=n?1:-1,y=e<0||0===e&&1/e<0?1:0;for(e=Math.abs(e),isNaN(e)||e===1/0?(a=isNaN(e)?1:0,s=c):(s=Math.floor(Math.log(e)/Math.LN2),e*(l=Math.pow(2,-s))<1&&(s--,l*=2),(e+=s+h>=1?f/l:f*Math.pow(2,1-h))*l>=2&&(s++,l/=2),s+h>=c?(a=0,s=c):s+h>=1?(a=(e*l-1)*Math.pow(2,i),s+=h):(a=e*Math.pow(2,h-1)*Math.pow(2,i),s=0));i>=8;t[r+d]=255&a,d+=p,a/=256,i-=8);for(s=s<<i|a,u+=i;u>0;t[r+d]=255&s,d+=p,s/=256,u-=8);t[r+d-p]|=128*y},
8
- /*!
9
- * The buffer module from node.js, for the browser.
10
- *
11
- * @author Feross Aboukhadijeh <https://feross.org>
12
- * @license MIT
13
- */
14
- function(t){const e=ha,r=wa,n="function"==typeof Symbol&&"function"==typeof Symbol.for?Symbol.for("nodejs.util.inspect.custom"):null;t.Buffer=s,t.SlowBuffer=function(t){+t!=t&&(t=0);return s.alloc(+t)},t.INSPECT_MAX_BYTES=50;const i=2147483647;function o(t){if(t>i)throw new RangeError('The value "'+t+'" is invalid for option "size"');const e=new Uint8Array(t);return Object.setPrototypeOf(e,s.prototype),e}function s(t,e,r){if("number"==typeof t){if("string"==typeof e)throw new TypeError('The "string" argument must be of type string. Received type number');return u(t)}return a(t,e,r)}function a(t,e,r){if("string"==typeof t)return function(t,e){"string"==typeof e&&""!==e||(e="utf8");if(!s.isEncoding(e))throw new TypeError("Unknown encoding: "+e);const r=0|d(t,e);let n=o(r);const i=n.write(t,e);i!==r&&(n=n.slice(0,i));return n}(t,e);if(ArrayBuffer.isView(t))return function(t){if(V(t,Uint8Array)){const e=new Uint8Array(t);return h(e.buffer,e.byteOffset,e.byteLength)}return c(t)}(t);if(null==t)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof t);if(V(t,ArrayBuffer)||t&&V(t.buffer,ArrayBuffer))return h(t,e,r);if("undefined"!=typeof SharedArrayBuffer&&(V(t,SharedArrayBuffer)||t&&V(t.buffer,SharedArrayBuffer)))return h(t,e,r);if("number"==typeof t)throw new TypeError('The "value" argument must not be of type number. Received type number');const n=t.valueOf&&t.valueOf();if(null!=n&&n!==t)return s.from(n,e,r);const i=function(t){if(s.isBuffer(t)){const e=0|f(t.length),r=o(e);return 0===r.length||t.copy(r,0,0,e),r}if(void 0!==t.length)return"number"!=typeof t.length||Z(t.length)?o(0):c(t);if("Buffer"===t.type&&Array.isArray(t.data))return c(t.data)}(t);if(i)return i;if("undefined"!=typeof Symbol&&null!=Symbol.toPrimitive&&"function"==typeof t[Symbol.toPrimitive])return s.from(t[Symbol.toPrimitive]("string"),e,r);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof t)}function l(t){if("number"!=typeof t)throw new TypeError('"size" argument must be of type number');if(t<0)throw new RangeError('The value "'+t+'" is invalid for option "size"')}function u(t){return l(t),o(t<0?0:0|f(t))}function c(t){const e=t.length<0?0:0|f(t.length),r=o(e);for(let n=0;n<e;n+=1)r[n]=255&t[n];return r}function h(t,e,r){if(e<0||t.byteLength<e)throw new RangeError('"offset" is outside of buffer bounds');if(t.byteLength<e+(r||0))throw new RangeError('"length" is outside of buffer bounds');let n;return n=void 0===e&&void 0===r?new Uint8Array(t):void 0===r?new Uint8Array(t,e):new Uint8Array(t,e,r),Object.setPrototypeOf(n,s.prototype),n}function f(t){if(t>=i)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+i.toString(16)+" bytes");return 0|t}function d(t,e){if(s.isBuffer(t))return t.length;if(ArrayBuffer.isView(t)||V(t,ArrayBuffer))return t.byteLength;if("string"!=typeof t)throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof t);const r=t.length,n=arguments.length>2&&!0===arguments[2];if(!n&&0===r)return 0;let i=!1;for(;;)switch(e){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":return H(t).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return G(t).length;default:if(i)return n?-1:H(t).length;e=(""+e).toLowerCase(),i=!0}}function p(t,e,r){let n=!1;if((void 0===e||e<0)&&(e=0),e>this.length)return"";if((void 0===r||r>this.length)&&(r=this.length),r<=0)return"";if((r>>>=0)<=(e>>>=0))return"";for(t||(t="utf8");;)switch(t){case"hex":return A(this,e,r);case"utf8":case"utf-8":return R(this,e,r);case"ascii":return T(this,e,r);case"latin1":case"binary":return x(this,e,r);case"base64":return E(this,e,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return O(this,e,r);default:if(n)throw new TypeError("Unknown encoding: "+t);t=(t+"").toLowerCase(),n=!0}}function y(t,e,r){const n=t[e];t[e]=t[r],t[r]=n}function g(t,e,r,n,i){if(0===t.length)return-1;if("string"==typeof r?(n=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),Z(r=+r)&&(r=i?0:t.length-1),r<0&&(r=t.length+r),r>=t.length){if(i)return-1;r=t.length-1}else if(r<0){if(!i)return-1;r=0}if("string"==typeof e&&(e=s.from(e,n)),s.isBuffer(e))return 0===e.length?-1:b(t,e,r,n,i);if("number"==typeof e)return e&=255,"function"==typeof Uint8Array.prototype.indexOf?i?Uint8Array.prototype.indexOf.call(t,e,r):Uint8Array.prototype.lastIndexOf.call(t,e,r):b(t,[e],r,n,i);throw new TypeError("val must be string, number or Buffer")}function b(t,e,r,n,i){let o,s=1,a=t.length,l=e.length;if(void 0!==n&&("ucs2"===(n=String(n).toLowerCase())||"ucs-2"===n||"utf16le"===n||"utf-16le"===n)){if(t.length<2||e.length<2)return-1;s=2,a/=2,l/=2,r/=2}function u(t,e){return 1===s?t[e]:t.readUInt16BE(e*s)}if(i){let n=-1;for(o=r;o<a;o++)if(u(t,o)===u(e,-1===n?0:o-n)){if(-1===n&&(n=o),o-n+1===l)return n*s}else-1!==n&&(o-=o-n),n=-1}else for(r+l>a&&(r=a-l),o=r;o>=0;o--){let r=!0;for(let n=0;n<l;n++)if(u(t,o+n)!==u(e,n)){r=!1;break}if(r)return o}return-1}function m(t,e,r,n){r=Number(r)||0;const i=t.length-r;n?(n=Number(n))>i&&(n=i):n=i;const o=e.length;let s;for(n>o/2&&(n=o/2),s=0;s<n;++s){const n=parseInt(e.substr(2*s,2),16);if(Z(n))return s;t[r+s]=n}return s}function _(t,e,r,n){return q(H(e,t.length-r),t,r,n)}function v(t,e,r,n){return q(function(t){const e=[];for(let r=0;r<t.length;++r)e.push(255&t.charCodeAt(r));return e}(e),t,r,n)}function w(t,e,r,n){return q(G(e),t,r,n)}function S(t,e,r,n){return q(function(t,e){let r,n,i;const o=[];for(let s=0;s<t.length&&!((e-=2)<0);++s)r=t.charCodeAt(s),n=r>>8,i=r%256,o.push(i),o.push(n);return o}(e,t.length-r),t,r,n)}function E(t,r,n){return 0===r&&n===t.length?e.fromByteArray(t):e.fromByteArray(t.slice(r,n))}function R(t,e,r){r=Math.min(t.length,r);const n=[];let i=e;for(;i<r;){const e=t[i];let o=null,s=e>239?4:e>223?3:e>191?2:1;if(i+s<=r){let r,n,a,l;switch(s){case 1:e<128&&(o=e);break;case 2:r=t[i+1],128==(192&r)&&(l=(31&e)<<6|63&r,l>127&&(o=l));break;case 3:r=t[i+1],n=t[i+2],128==(192&r)&&128==(192&n)&&(l=(15&e)<<12|(63&r)<<6|63&n,l>2047&&(l<55296||l>57343)&&(o=l));break;case 4:r=t[i+1],n=t[i+2],a=t[i+3],128==(192&r)&&128==(192&n)&&128==(192&a)&&(l=(15&e)<<18|(63&r)<<12|(63&n)<<6|63&a,l>65535&&l<1114112&&(o=l))}}null===o?(o=65533,s=1):o>65535&&(o-=65536,n.push(o>>>10&1023|55296),o=56320|1023&o),n.push(o),i+=s}return function(t){const e=t.length;if(e<=k)return String.fromCharCode.apply(String,t);let r="",n=0;for(;n<e;)r+=String.fromCharCode.apply(String,t.slice(n,n+=k));return r}(n)}t.kMaxLength=i,s.TYPED_ARRAY_SUPPORT=function(){try{const t=new Uint8Array(1),e={foo:function(){return 42}};return Object.setPrototypeOf(e,Uint8Array.prototype),Object.setPrototypeOf(t,e),42===t.foo()}catch(t){return!1}}(),s.TYPED_ARRAY_SUPPORT||"undefined"==typeof console||"function"!=typeof console.error||console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support."),Object.defineProperty(s.prototype,"parent",{enumerable:!0,get:function(){if(s.isBuffer(this))return this.buffer}}),Object.defineProperty(s.prototype,"offset",{enumerable:!0,get:function(){if(s.isBuffer(this))return this.byteOffset}}),s.poolSize=8192,s.from=function(t,e,r){return a(t,e,r)},Object.setPrototypeOf(s.prototype,Uint8Array.prototype),Object.setPrototypeOf(s,Uint8Array),s.alloc=function(t,e,r){return function(t,e,r){return l(t),t<=0?o(t):void 0!==e?"string"==typeof r?o(t).fill(e,r):o(t).fill(e):o(t)}(t,e,r)},s.allocUnsafe=function(t){return u(t)},s.allocUnsafeSlow=function(t){return u(t)},s.isBuffer=function(t){return null!=t&&!0===t._isBuffer&&t!==s.prototype},s.compare=function(t,e){if(V(t,Uint8Array)&&(t=s.from(t,t.offset,t.byteLength)),V(e,Uint8Array)&&(e=s.from(e,e.offset,e.byteLength)),!s.isBuffer(t)||!s.isBuffer(e))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(t===e)return 0;let r=t.length,n=e.length;for(let i=0,o=Math.min(r,n);i<o;++i)if(t[i]!==e[i]){r=t[i],n=e[i];break}return r<n?-1:n<r?1:0},s.isEncoding=function(t){switch(String(t).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},s.concat=function(t,e){if(!Array.isArray(t))throw new TypeError('"list" argument must be an Array of Buffers');if(0===t.length)return s.alloc(0);let r;if(void 0===e)for(e=0,r=0;r<t.length;++r)e+=t[r].length;const n=s.allocUnsafe(e);let i=0;for(r=0;r<t.length;++r){let e=t[r];if(V(e,Uint8Array))i+e.length>n.length?(s.isBuffer(e)||(e=s.from(e)),e.copy(n,i)):Uint8Array.prototype.set.call(n,e,i);else{if(!s.isBuffer(e))throw new TypeError('"list" argument must be an Array of Buffers');e.copy(n,i)}i+=e.length}return n},s.byteLength=d,s.prototype._isBuffer=!0,s.prototype.swap16=function(){const t=this.length;if(t%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let e=0;e<t;e+=2)y(this,e,e+1);return this},s.prototype.swap32=function(){const t=this.length;if(t%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(let e=0;e<t;e+=4)y(this,e,e+3),y(this,e+1,e+2);return this},s.prototype.swap64=function(){const t=this.length;if(t%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(let e=0;e<t;e+=8)y(this,e,e+7),y(this,e+1,e+6),y(this,e+2,e+5),y(this,e+3,e+4);return this},s.prototype.toString=function(){const t=this.length;return 0===t?"":0===arguments.length?R(this,0,t):p.apply(this,arguments)},s.prototype.toLocaleString=s.prototype.toString,s.prototype.equals=function(t){if(!s.isBuffer(t))throw new TypeError("Argument must be a Buffer");return this===t||0===s.compare(this,t)},s.prototype.inspect=function(){let e="";const r=t.INSPECT_MAX_BYTES;return e=this.toString("hex",0,r).replace(/(.{2})/g,"$1 ").trim(),this.length>r&&(e+=" ... "),"<Buffer "+e+">"},n&&(s.prototype[n]=s.prototype.inspect),s.prototype.compare=function(t,e,r,n,i){if(V(t,Uint8Array)&&(t=s.from(t,t.offset,t.byteLength)),!s.isBuffer(t))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof t);if(void 0===e&&(e=0),void 0===r&&(r=t?t.length:0),void 0===n&&(n=0),void 0===i&&(i=this.length),e<0||r>t.length||n<0||i>this.length)throw new RangeError("out of range index");if(n>=i&&e>=r)return 0;if(n>=i)return-1;if(e>=r)return 1;if(this===t)return 0;let o=(i>>>=0)-(n>>>=0),a=(r>>>=0)-(e>>>=0);const l=Math.min(o,a),u=this.slice(n,i),c=t.slice(e,r);for(let t=0;t<l;++t)if(u[t]!==c[t]){o=u[t],a=c[t];break}return o<a?-1:a<o?1:0},s.prototype.includes=function(t,e,r){return-1!==this.indexOf(t,e,r)},s.prototype.indexOf=function(t,e,r){return g(this,t,e,r,!0)},s.prototype.lastIndexOf=function(t,e,r){return g(this,t,e,r,!1)},s.prototype.write=function(t,e,r,n){if(void 0===e)n="utf8",r=this.length,e=0;else if(void 0===r&&"string"==typeof e)n=e,r=this.length,e=0;else{if(!isFinite(e))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");e>>>=0,isFinite(r)?(r>>>=0,void 0===n&&(n="utf8")):(n=r,r=void 0)}const i=this.length-e;if((void 0===r||r>i)&&(r=i),t.length>0&&(r<0||e<0)||e>this.length)throw new RangeError("Attempt to write outside buffer bounds");n||(n="utf8");let o=!1;for(;;)switch(n){case"hex":return m(this,t,e,r);case"utf8":case"utf-8":return _(this,t,e,r);case"ascii":case"latin1":case"binary":return v(this,t,e,r);case"base64":return w(this,t,e,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return S(this,t,e,r);default:if(o)throw new TypeError("Unknown encoding: "+n);n=(""+n).toLowerCase(),o=!0}},s.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};const k=4096;function T(t,e,r){let n="";r=Math.min(t.length,r);for(let i=e;i<r;++i)n+=String.fromCharCode(127&t[i]);return n}function x(t,e,r){let n="";r=Math.min(t.length,r);for(let i=e;i<r;++i)n+=String.fromCharCode(t[i]);return n}function A(t,e,r){const n=t.length;(!e||e<0)&&(e=0),(!r||r<0||r>n)&&(r=n);let i="";for(let n=e;n<r;++n)i+=Y[t[n]];return i}function O(t,e,r){const n=t.slice(e,r);let i="";for(let t=0;t<n.length-1;t+=2)i+=String.fromCharCode(n[t]+256*n[t+1]);return i}function L(t,e,r){if(t%1!=0||t<0)throw new RangeError("offset is not uint");if(t+e>r)throw new RangeError("Trying to access beyond buffer length")}function j(t,e,r,n,i,o){if(!s.isBuffer(t))throw new TypeError('"buffer" argument must be a Buffer instance');if(e>i||e<o)throw new RangeError('"value" argument is out of bounds');if(r+n>t.length)throw new RangeError("Index out of range")}function M(t,e,r,n,i){W(e,n,i,t,r,7);let o=Number(e&BigInt(4294967295));t[r++]=o,o>>=8,t[r++]=o,o>>=8,t[r++]=o,o>>=8,t[r++]=o;let s=Number(e>>BigInt(32)&BigInt(4294967295));return t[r++]=s,s>>=8,t[r++]=s,s>>=8,t[r++]=s,s>>=8,t[r++]=s,r}function I(t,e,r,n,i){W(e,n,i,t,r,7);let o=Number(e&BigInt(4294967295));t[r+7]=o,o>>=8,t[r+6]=o,o>>=8,t[r+5]=o,o>>=8,t[r+4]=o;let s=Number(e>>BigInt(32)&BigInt(4294967295));return t[r+3]=s,s>>=8,t[r+2]=s,s>>=8,t[r+1]=s,s>>=8,t[r]=s,r+8}function P(t,e,r,n,i,o){if(r+n>t.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("Index out of range")}function D(t,e,n,i,o){return e=+e,n>>>=0,o||P(t,0,n,4),r.write(t,e,n,i,23,4),n+4}function C(t,e,n,i,o){return e=+e,n>>>=0,o||P(t,0,n,8),r.write(t,e,n,i,52,8),n+8}s.prototype.slice=function(t,e){const r=this.length;(t=~~t)<0?(t+=r)<0&&(t=0):t>r&&(t=r),(e=void 0===e?r:~~e)<0?(e+=r)<0&&(e=0):e>r&&(e=r),e<t&&(e=t);const n=this.subarray(t,e);return Object.setPrototypeOf(n,s.prototype),n},s.prototype.readUintLE=s.prototype.readUIntLE=function(t,e,r){t>>>=0,e>>>=0,r||L(t,e,this.length);let n=this[t],i=1,o=0;for(;++o<e&&(i*=256);)n+=this[t+o]*i;return n},s.prototype.readUintBE=s.prototype.readUIntBE=function(t,e,r){t>>>=0,e>>>=0,r||L(t,e,this.length);let n=this[t+--e],i=1;for(;e>0&&(i*=256);)n+=this[t+--e]*i;return n},s.prototype.readUint8=s.prototype.readUInt8=function(t,e){return t>>>=0,e||L(t,1,this.length),this[t]},s.prototype.readUint16LE=s.prototype.readUInt16LE=function(t,e){return t>>>=0,e||L(t,2,this.length),this[t]|this[t+1]<<8},s.prototype.readUint16BE=s.prototype.readUInt16BE=function(t,e){return t>>>=0,e||L(t,2,this.length),this[t]<<8|this[t+1]},s.prototype.readUint32LE=s.prototype.readUInt32LE=function(t,e){return t>>>=0,e||L(t,4,this.length),(this[t]|this[t+1]<<8|this[t+2]<<16)+16777216*this[t+3]},s.prototype.readUint32BE=s.prototype.readUInt32BE=function(t,e){return t>>>=0,e||L(t,4,this.length),16777216*this[t]+(this[t+1]<<16|this[t+2]<<8|this[t+3])},s.prototype.readBigUInt64LE=K(function(t){U(t>>>=0,"offset");const e=this[t],r=this[t+7];void 0!==e&&void 0!==r||z(t,this.length-8);const n=e+256*this[++t]+65536*this[++t]+this[++t]*2**24,i=this[++t]+256*this[++t]+65536*this[++t]+r*2**24;return BigInt(n)+(BigInt(i)<<BigInt(32))}),s.prototype.readBigUInt64BE=K(function(t){U(t>>>=0,"offset");const e=this[t],r=this[t+7];void 0!==e&&void 0!==r||z(t,this.length-8);const n=e*2**24+65536*this[++t]+256*this[++t]+this[++t],i=this[++t]*2**24+65536*this[++t]+256*this[++t]+r;return(BigInt(n)<<BigInt(32))+BigInt(i)}),s.prototype.readIntLE=function(t,e,r){t>>>=0,e>>>=0,r||L(t,e,this.length);let n=this[t],i=1,o=0;for(;++o<e&&(i*=256);)n+=this[t+o]*i;return i*=128,n>=i&&(n-=Math.pow(2,8*e)),n},s.prototype.readIntBE=function(t,e,r){t>>>=0,e>>>=0,r||L(t,e,this.length);let n=e,i=1,o=this[t+--n];for(;n>0&&(i*=256);)o+=this[t+--n]*i;return i*=128,o>=i&&(o-=Math.pow(2,8*e)),o},s.prototype.readInt8=function(t,e){return t>>>=0,e||L(t,1,this.length),128&this[t]?-1*(255-this[t]+1):this[t]},s.prototype.readInt16LE=function(t,e){t>>>=0,e||L(t,2,this.length);const r=this[t]|this[t+1]<<8;return 32768&r?4294901760|r:r},s.prototype.readInt16BE=function(t,e){t>>>=0,e||L(t,2,this.length);const r=this[t+1]|this[t]<<8;return 32768&r?4294901760|r:r},s.prototype.readInt32LE=function(t,e){return t>>>=0,e||L(t,4,this.length),this[t]|this[t+1]<<8|this[t+2]<<16|this[t+3]<<24},s.prototype.readInt32BE=function(t,e){return t>>>=0,e||L(t,4,this.length),this[t]<<24|this[t+1]<<16|this[t+2]<<8|this[t+3]},s.prototype.readBigInt64LE=K(function(t){U(t>>>=0,"offset");const e=this[t],r=this[t+7];void 0!==e&&void 0!==r||z(t,this.length-8);const n=this[t+4]+256*this[t+5]+65536*this[t+6]+(r<<24);return(BigInt(n)<<BigInt(32))+BigInt(e+256*this[++t]+65536*this[++t]+this[++t]*2**24)}),s.prototype.readBigInt64BE=K(function(t){U(t>>>=0,"offset");const e=this[t],r=this[t+7];void 0!==e&&void 0!==r||z(t,this.length-8);const n=(e<<24)+65536*this[++t]+256*this[++t]+this[++t];return(BigInt(n)<<BigInt(32))+BigInt(this[++t]*2**24+65536*this[++t]+256*this[++t]+r)}),s.prototype.readFloatLE=function(t,e){return t>>>=0,e||L(t,4,this.length),r.read(this,t,!0,23,4)},s.prototype.readFloatBE=function(t,e){return t>>>=0,e||L(t,4,this.length),r.read(this,t,!1,23,4)},s.prototype.readDoubleLE=function(t,e){return t>>>=0,e||L(t,8,this.length),r.read(this,t,!0,52,8)},s.prototype.readDoubleBE=function(t,e){return t>>>=0,e||L(t,8,this.length),r.read(this,t,!1,52,8)},s.prototype.writeUintLE=s.prototype.writeUIntLE=function(t,e,r,n){if(t=+t,e>>>=0,r>>>=0,!n){j(this,t,e,r,Math.pow(2,8*r)-1,0)}let i=1,o=0;for(this[e]=255&t;++o<r&&(i*=256);)this[e+o]=t/i&255;return e+r},s.prototype.writeUintBE=s.prototype.writeUIntBE=function(t,e,r,n){if(t=+t,e>>>=0,r>>>=0,!n){j(this,t,e,r,Math.pow(2,8*r)-1,0)}let i=r-1,o=1;for(this[e+i]=255&t;--i>=0&&(o*=256);)this[e+i]=t/o&255;return e+r},s.prototype.writeUint8=s.prototype.writeUInt8=function(t,e,r){return t=+t,e>>>=0,r||j(this,t,e,1,255,0),this[e]=255&t,e+1},s.prototype.writeUint16LE=s.prototype.writeUInt16LE=function(t,e,r){return t=+t,e>>>=0,r||j(this,t,e,2,65535,0),this[e]=255&t,this[e+1]=t>>>8,e+2},s.prototype.writeUint16BE=s.prototype.writeUInt16BE=function(t,e,r){return t=+t,e>>>=0,r||j(this,t,e,2,65535,0),this[e]=t>>>8,this[e+1]=255&t,e+2},s.prototype.writeUint32LE=s.prototype.writeUInt32LE=function(t,e,r){return t=+t,e>>>=0,r||j(this,t,e,4,4294967295,0),this[e+3]=t>>>24,this[e+2]=t>>>16,this[e+1]=t>>>8,this[e]=255&t,e+4},s.prototype.writeUint32BE=s.prototype.writeUInt32BE=function(t,e,r){return t=+t,e>>>=0,r||j(this,t,e,4,4294967295,0),this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=255&t,e+4},s.prototype.writeBigUInt64LE=K(function(t,e=0){return M(this,t,e,BigInt(0),BigInt("0xffffffffffffffff"))}),s.prototype.writeBigUInt64BE=K(function(t,e=0){return I(this,t,e,BigInt(0),BigInt("0xffffffffffffffff"))}),s.prototype.writeIntLE=function(t,e,r,n){if(t=+t,e>>>=0,!n){const n=Math.pow(2,8*r-1);j(this,t,e,r,n-1,-n)}let i=0,o=1,s=0;for(this[e]=255&t;++i<r&&(o*=256);)t<0&&0===s&&0!==this[e+i-1]&&(s=1),this[e+i]=(t/o|0)-s&255;return e+r},s.prototype.writeIntBE=function(t,e,r,n){if(t=+t,e>>>=0,!n){const n=Math.pow(2,8*r-1);j(this,t,e,r,n-1,-n)}let i=r-1,o=1,s=0;for(this[e+i]=255&t;--i>=0&&(o*=256);)t<0&&0===s&&0!==this[e+i+1]&&(s=1),this[e+i]=(t/o|0)-s&255;return e+r},s.prototype.writeInt8=function(t,e,r){return t=+t,e>>>=0,r||j(this,t,e,1,127,-128),t<0&&(t=255+t+1),this[e]=255&t,e+1},s.prototype.writeInt16LE=function(t,e,r){return t=+t,e>>>=0,r||j(this,t,e,2,32767,-32768),this[e]=255&t,this[e+1]=t>>>8,e+2},s.prototype.writeInt16BE=function(t,e,r){return t=+t,e>>>=0,r||j(this,t,e,2,32767,-32768),this[e]=t>>>8,this[e+1]=255&t,e+2},s.prototype.writeInt32LE=function(t,e,r){return t=+t,e>>>=0,r||j(this,t,e,4,2147483647,-2147483648),this[e]=255&t,this[e+1]=t>>>8,this[e+2]=t>>>16,this[e+3]=t>>>24,e+4},s.prototype.writeInt32BE=function(t,e,r){return t=+t,e>>>=0,r||j(this,t,e,4,2147483647,-2147483648),t<0&&(t=4294967295+t+1),this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=255&t,e+4},s.prototype.writeBigInt64LE=K(function(t,e=0){return M(this,t,e,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),s.prototype.writeBigInt64BE=K(function(t,e=0){return I(this,t,e,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),s.prototype.writeFloatLE=function(t,e,r){return D(this,t,e,!0,r)},s.prototype.writeFloatBE=function(t,e,r){return D(this,t,e,!1,r)},s.prototype.writeDoubleLE=function(t,e,r){return C(this,t,e,!0,r)},s.prototype.writeDoubleBE=function(t,e,r){return C(this,t,e,!1,r)},s.prototype.copy=function(t,e,r,n){if(!s.isBuffer(t))throw new TypeError("argument should be a Buffer");if(r||(r=0),n||0===n||(n=this.length),e>=t.length&&(e=t.length),e||(e=0),n>0&&n<r&&(n=r),n===r)return 0;if(0===t.length||0===this.length)return 0;if(e<0)throw new RangeError("targetStart out of bounds");if(r<0||r>=this.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("sourceEnd out of bounds");n>this.length&&(n=this.length),t.length-e<n-r&&(n=t.length-e+r);const i=n-r;return this===t&&"function"==typeof Uint8Array.prototype.copyWithin?this.copyWithin(e,r,n):Uint8Array.prototype.set.call(t,this.subarray(r,n),e),i},s.prototype.fill=function(t,e,r,n){if("string"==typeof t){if("string"==typeof e?(n=e,e=0,r=this.length):"string"==typeof r&&(n=r,r=this.length),void 0!==n&&"string"!=typeof n)throw new TypeError("encoding must be a string");if("string"==typeof n&&!s.isEncoding(n))throw new TypeError("Unknown encoding: "+n);if(1===t.length){const e=t.charCodeAt(0);("utf8"===n&&e<128||"latin1"===n)&&(t=e)}}else"number"==typeof t?t&=255:"boolean"==typeof t&&(t=Number(t));if(e<0||this.length<e||this.length<r)throw new RangeError("Out of range index");if(r<=e)return this;let i;if(e>>>=0,r=void 0===r?this.length:r>>>0,t||(t=0),"number"==typeof t)for(i=e;i<r;++i)this[i]=t;else{const o=s.isBuffer(t)?t:s.from(t,n),a=o.length;if(0===a)throw new TypeError('The value "'+t+'" is invalid for argument "value"');for(i=0;i<r-e;++i)this[i+e]=o[i%a]}return this};const N={};function F(t,e,r){N[t]=class extends r{constructor(){super(),Object.defineProperty(this,"message",{value:e.apply(this,arguments),writable:!0,configurable:!0}),this.name=`${this.name} [${t}]`,this.stack,delete this.name}get code(){return t}set code(t){Object.defineProperty(this,"code",{configurable:!0,enumerable:!0,value:t,writable:!0})}toString(){return`${this.name} [${t}]: ${this.message}`}}}function B(t){let e="",r=t.length;const n="-"===t[0]?1:0;for(;r>=n+4;r-=3)e=`_${t.slice(r-3,r)}${e}`;return`${t.slice(0,r)}${e}`}function W(t,e,r,n,i,o){if(t>r||t<e){const n="bigint"==typeof e?"n":"";let i;throw i=o>3?0===e||e===BigInt(0)?`>= 0${n} and < 2${n} ** ${8*(o+1)}${n}`:`>= -(2${n} ** ${8*(o+1)-1}${n}) and < 2 ** ${8*(o+1)-1}${n}`:`>= ${e}${n} and <= ${r}${n}`,new N.ERR_OUT_OF_RANGE("value",i,t)}!function(t,e,r){U(e,"offset"),void 0!==t[e]&&void 0!==t[e+r]||z(e,t.length-(r+1))}(n,i,o)}function U(t,e){if("number"!=typeof t)throw new N.ERR_INVALID_ARG_TYPE(e,"number",t)}function z(t,e,r){if(Math.floor(t)!==t)throw U(t,r),new N.ERR_OUT_OF_RANGE(r||"offset","an integer",t);if(e<0)throw new N.ERR_BUFFER_OUT_OF_BOUNDS;throw new N.ERR_OUT_OF_RANGE(r||"offset",`>= ${r?1:0} and <= ${e}`,t)}F("ERR_BUFFER_OUT_OF_BOUNDS",function(t){return t?`${t} is outside of buffer bounds`:"Attempt to access memory outside buffer bounds"},RangeError),F("ERR_INVALID_ARG_TYPE",function(t,e){return`The "${t}" argument must be of type number. Received type ${typeof e}`},TypeError),F("ERR_OUT_OF_RANGE",function(t,e,r){let n=`The value of "${t}" is out of range.`,i=r;return Number.isInteger(r)&&Math.abs(r)>2**32?i=B(String(r)):"bigint"==typeof r&&(i=String(r),(r>BigInt(2)**BigInt(32)||r<-(BigInt(2)**BigInt(32)))&&(i=B(i)),i+="n"),n+=` It must be ${e}. Received ${i}`,n},RangeError);const $=/[^+/0-9A-Za-z-_]/g;function H(t,e){let r;e=e||1/0;const n=t.length;let i=null;const o=[];for(let s=0;s<n;++s){if(r=t.charCodeAt(s),r>55295&&r<57344){if(!i){if(r>56319){(e-=3)>-1&&o.push(239,191,189);continue}if(s+1===n){(e-=3)>-1&&o.push(239,191,189);continue}i=r;continue}if(r<56320){(e-=3)>-1&&o.push(239,191,189),i=r;continue}r=65536+(i-55296<<10|r-56320)}else i&&(e-=3)>-1&&o.push(239,191,189);if(i=null,r<128){if((e-=1)<0)break;o.push(r)}else if(r<2048){if((e-=2)<0)break;o.push(r>>6|192,63&r|128)}else if(r<65536){if((e-=3)<0)break;o.push(r>>12|224,r>>6&63|128,63&r|128)}else{if(!(r<1114112))throw new Error("Invalid code point");if((e-=4)<0)break;o.push(r>>18|240,r>>12&63|128,r>>6&63|128,63&r|128)}}return o}function G(t){return e.toByteArray(function(t){if((t=(t=t.split("=")[0]).trim().replace($,"")).length<2)return"";for(;t.length%4!=0;)t+="=";return t}(t))}function q(t,e,r,n){let i;for(i=0;i<n&&!(i+r>=e.length||i>=t.length);++i)e[i+r]=t[i];return i}function V(t,e){return t instanceof e||null!=t&&null!=t.constructor&&null!=t.constructor.name&&t.constructor.name===e.name}function Z(t){return t!=t}const Y=function(){const t="0123456789abcdef",e=new Array(256);for(let r=0;r<16;++r){const n=16*r;for(let i=0;i<16;++i)e[n+i]=t[r]+t[i]}return e}();function K(t){return"undefined"==typeof BigInt?Q:t}function Q(){throw new Error("BigInt not supported")}}(ca);var Ea,Ra={};function ka(){if(Ea)return Ra;function t(t){return Object.prototype.toString.call(t)}return Ea=1,Ra.isArray=function(e){return Array.isArray?Array.isArray(e):"[object Array]"===t(e)},Ra.isBoolean=function(t){return"boolean"==typeof t},Ra.isNull=function(t){return null===t},Ra.isNullOrUndefined=function(t){return null==t},Ra.isNumber=function(t){return"number"==typeof t},Ra.isString=function(t){return"string"==typeof t},Ra.isSymbol=function(t){return"symbol"==typeof t},Ra.isUndefined=function(t){return void 0===t},Ra.isRegExp=function(e){return"[object RegExp]"===t(e)},Ra.isObject=function(t){return"object"==typeof t&&null!==t},Ra.isDate=function(e){return"[object Date]"===t(e)},Ra.isError=function(e){return"[object Error]"===t(e)||e instanceof Error},Ra.isFunction=function(t){return"function"==typeof t},Ra.isPrimitive=function(t){return null===t||"boolean"==typeof t||"number"==typeof t||"string"==typeof t||"symbol"==typeof t||void 0===t},Ra.isBuffer=ca.Buffer.isBuffer,Ra}var Ta={exports:{}};"function"==typeof Object.create?Ta.exports=function(t,e){e&&(t.super_=e,t.prototype=Object.create(e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}))}:Ta.exports=function(t,e){if(e){t.super_=e;var r=function(){};r.prototype=e.prototype,t.prototype=new r,t.prototype.constructor=t}};var xa,Aa,Oa,La,ja,Ma,Ia,Pa,Da,Ca=Ta.exports,Na=Wt(Object.freeze({__proto__:null,default:{}})),Fa={exports:{}};function Ba(){return xa||(xa=1,function(t){var e=Sa().Buffer,r=Na;function n(t,e,r){t.copy(e,r)}t.exports=function(){function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.head=null,this.tail=null,this.length=0}return t.prototype.push=function(t){var e={data:t,next:null};this.length>0?this.tail.next=e:this.head=e,this.tail=e,++this.length},t.prototype.unshift=function(t){var e={data:t,next:this.head};0===this.length&&(this.tail=e),this.head=e,++this.length},t.prototype.shift=function(){if(0!==this.length){var t=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,t}},t.prototype.clear=function(){this.head=this.tail=null,this.length=0},t.prototype.join=function(t){if(0===this.length)return"";for(var e=this.head,r=""+e.data;e=e.next;)r+=t+e.data;return r},t.prototype.concat=function(t){if(0===this.length)return e.alloc(0);for(var r=e.allocUnsafe(t>>>0),i=this.head,o=0;i;)n(i.data,r,o),o+=i.data.length,i=i.next;return r},t}(),r&&r.inspect&&r.inspect.custom&&(t.exports.prototype[r.inspect.custom]=function(){var t=r.inspect({length:this.length});return this.constructor.name+" "+t})}(Fa)),Fa.exports}function Wa(){if(Oa)return Aa;Oa=1;var t=aa();function e(t,e){t.emit("error",e)}return Aa={destroy:function(r,n){var i=this,o=this._readableState&&this._readableState.destroyed,s=this._writableState&&this._writableState.destroyed;return o||s?(n?n(r):r&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,t.nextTick(e,this,r)):t.nextTick(e,this,r)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(r||null,function(r){!n&&r?i._writableState?i._writableState.errorEmitted||(i._writableState.errorEmitted=!0,t.nextTick(e,i,r)):t.nextTick(e,i,r):n&&n(r)}),this)},undestroy:function(){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 Ua(){if(ja)return La;function t(t){try{if(!Ft.localStorage)return!1}catch(t){return!1}var e=Ft.localStorage[t];return null!=e&&"true"===String(e).toLowerCase()}return ja=1,La=function(e,r){if(t("noDeprecation"))return e;var n=!1;return function(){if(!n){if(t("throwDeprecation"))throw new Error(r);t("traceDeprecation")?console.trace(r):console.warn(r),n=!0}return e.apply(this,arguments)}},La}function za(){if(Ia)return Ma;Ia=1;var t=aa();function e(t){var e=this;this.next=null,this.entry=null,this.finish=function(){!function(t,e,r){var n=t.entry;t.entry=null;for(;n;){var i=n.callback;e.pendingcb--,i(r),n=n.next}e.corkedRequestsFree.next=t}(e,t)}}Ma=d;var r,n=!process.browser&&["v0.10","v0.9."].indexOf(process.version.slice(0,5))>-1?setImmediate:t.nextTick;d.WritableState=f;var i=Object.create(ka());i.inherits=Ca;var o={deprecate:Ua()},s=la(),a=Sa().Buffer,l=(void 0!==Ft?Ft:"undefined"!=typeof window?window:"undefined"!=typeof self?self:{}).Uint8Array||function(){};var u,c=Wa();function h(){}function f(i,o){r=r||$a(),i=i||{};var s=o instanceof r;this.objectMode=!!i.objectMode,s&&(this.objectMode=this.objectMode||!!i.writableObjectMode);var a=i.highWaterMark,l=i.writableHighWaterMark,u=this.objectMode?16:16384;this.highWaterMark=a||0===a?a:s&&(l||0===l)?l:u,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var c=!1===i.decodeStrings;this.decodeStrings=!c,this.defaultEncoding=i.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){!function(e,r){var i=e._writableState,o=i.sync,s=i.writecb;if(function(t){t.writing=!1,t.writecb=null,t.length-=t.writelen,t.writelen=0}(i),r)!function(e,r,n,i,o){--r.pendingcb,n?(t.nextTick(o,i),t.nextTick(_,e,r),e._writableState.errorEmitted=!0,e.emit("error",i)):(o(i),e._writableState.errorEmitted=!0,e.emit("error",i),_(e,r))}(e,i,o,r,s);else{var a=b(i);a||i.corked||i.bufferProcessing||!i.bufferedRequest||g(e,i),o?n(y,e,i,a,s):y(e,i,a,s)}}(o,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new e(this)}function d(t){if(r=r||$a(),!(u.call(d,this)||this instanceof r))return new d(t);this._writableState=new f(t,this),this.writable=!0,t&&("function"==typeof t.write&&(this._write=t.write),"function"==typeof t.writev&&(this._writev=t.writev),"function"==typeof t.destroy&&(this._destroy=t.destroy),"function"==typeof t.final&&(this._final=t.final)),s.call(this)}function p(t,e,r,n,i,o,s){e.writelen=n,e.writecb=s,e.writing=!0,e.sync=!0,r?t._writev(i,e.onwrite):t._write(i,o,e.onwrite),e.sync=!1}function y(t,e,r,n){r||function(t,e){0===e.length&&e.needDrain&&(e.needDrain=!1,t.emit("drain"))}(t,e),e.pendingcb--,n(),_(t,e)}function g(t,r){r.bufferProcessing=!0;var n=r.bufferedRequest;if(t._writev&&n&&n.next){var i=r.bufferedRequestCount,o=new Array(i),s=r.corkedRequestsFree;s.entry=n;for(var a=0,l=!0;n;)o[a]=n,n.isBuf||(l=!1),n=n.next,a+=1;o.allBuffers=l,p(t,r,!0,r.length,o,"",s.finish),r.pendingcb++,r.lastBufferedRequest=null,s.next?(r.corkedRequestsFree=s.next,s.next=null):r.corkedRequestsFree=new e(r),r.bufferedRequestCount=0}else{for(;n;){var u=n.chunk,c=n.encoding,h=n.callback;if(p(t,r,!1,r.objectMode?1:u.length,u,c,h),n=n.next,r.bufferedRequestCount--,r.writing)break}null===n&&(r.lastBufferedRequest=null)}r.bufferedRequest=n,r.bufferProcessing=!1}function b(t){return t.ending&&0===t.length&&null===t.bufferedRequest&&!t.finished&&!t.writing}function m(t,e){t._final(function(r){e.pendingcb--,r&&t.emit("error",r),e.prefinished=!0,t.emit("prefinish"),_(t,e)})}function _(e,r){var n=b(r);return n&&(!function(e,r){r.prefinished||r.finalCalled||("function"==typeof e._final?(r.pendingcb++,r.finalCalled=!0,t.nextTick(m,e,r)):(r.prefinished=!0,e.emit("prefinish")))}(e,r),0===r.pendingcb&&(r.finished=!0,e.emit("finish"))),n}return i.inherits(d,s),f.prototype.getBuffer=function(){for(var t=this.bufferedRequest,e=[];t;)e.push(t),t=t.next;return e},function(){try{Object.defineProperty(f.prototype,"buffer",{get:o.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(t){}}(),"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(u=Function.prototype[Symbol.hasInstance],Object.defineProperty(d,Symbol.hasInstance,{value:function(t){return!!u.call(this,t)||this===d&&(t&&t._writableState instanceof f)}})):u=function(t){return t instanceof this},d.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},d.prototype.write=function(e,r,n){var i,o=this._writableState,s=!1,u=!o.objectMode&&(i=e,a.isBuffer(i)||i instanceof l);return u&&!a.isBuffer(e)&&(e=function(t){return a.from(t)}(e)),"function"==typeof r&&(n=r,r=null),u?r="buffer":r||(r=o.defaultEncoding),"function"!=typeof n&&(n=h),o.ended?function(e,r){var n=new Error("write after end");e.emit("error",n),t.nextTick(r,n)}(this,n):(u||function(e,r,n,i){var o=!0,s=!1;return null===n?s=new TypeError("May not write null values to stream"):"string"==typeof n||void 0===n||r.objectMode||(s=new TypeError("Invalid non-string/buffer chunk")),s&&(e.emit("error",s),t.nextTick(i,s),o=!1),o}(this,o,e,n))&&(o.pendingcb++,s=function(t,e,r,n,i,o){if(!r){var s=function(t,e,r){t.objectMode||!1===t.decodeStrings||"string"!=typeof e||(e=a.from(e,r));return e}(e,n,i);n!==s&&(r=!0,i="buffer",n=s)}var l=e.objectMode?1:n.length;e.length+=l;var u=e.length<e.highWaterMark;u||(e.needDrain=!0);if(e.writing||e.corked){var c=e.lastBufferedRequest;e.lastBufferedRequest={chunk:n,encoding:i,isBuf:r,callback:o,next:null},c?c.next=e.lastBufferedRequest:e.bufferedRequest=e.lastBufferedRequest,e.bufferedRequestCount+=1}else p(t,e,!1,l,n,i,o);return u}(this,o,u,e,r,n)),s},d.prototype.cork=function(){this._writableState.corked++},d.prototype.uncork=function(){var t=this._writableState;t.corked&&(t.corked--,t.writing||t.corked||t.bufferProcessing||!t.bufferedRequest||g(this,t))},d.prototype.setDefaultEncoding=function(t){if("string"==typeof t&&(t=t.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((t+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+t);return this._writableState.defaultEncoding=t,this},Object.defineProperty(d.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),d.prototype._write=function(t,e,r){r(new Error("_write() is not implemented"))},d.prototype._writev=null,d.prototype.end=function(e,r,n){var i=this._writableState;"function"==typeof e?(n=e,e=null,r=null):"function"==typeof r&&(n=r,r=null),null!=e&&this.write(e,r),i.corked&&(i.corked=1,this.uncork()),i.ending||function(e,r,n){r.ending=!0,_(e,r),n&&(r.finished?t.nextTick(n):e.once("finish",n));r.ended=!0,e.writable=!1}(this,i,n)},Object.defineProperty(d.prototype,"destroyed",{get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(t){this._writableState&&(this._writableState.destroyed=t)}}),d.prototype.destroy=c.destroy,d.prototype._undestroy=c.undestroy,d.prototype._destroy=function(t,e){this.end(),e(t)},Ma}function $a(){if(Da)return Pa;Da=1;var t=aa(),e=Object.keys||function(t){var e=[];for(var r in t)e.push(r);return e};Pa=l;var r=Object.create(ka());r.inherits=Ca;var n=rl(),i=za();r.inherits(l,n);for(var o=e(i.prototype),s=0;s<o.length;s++){var a=o[s];l.prototype[a]||(l.prototype[a]=i.prototype[a])}function l(t){if(!(this instanceof l))return new l(t);n.call(this,t),i.call(this,t),t&&!1===t.readable&&(this.readable=!1),t&&!1===t.writable&&(this.writable=!1),this.allowHalfOpen=!0,t&&!1===t.allowHalfOpen&&(this.allowHalfOpen=!1),this.once("end",u)}function u(){this.allowHalfOpen||this._writableState.ended||t.nextTick(c,this)}function c(t){t.end()}return Object.defineProperty(l.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(l.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed&&this._writableState.destroyed)},set:function(t){void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed=t,this._writableState.destroyed=t)}}),l.prototype._destroy=function(e,r){this.push(null),this.end(),t.nextTick(r,e)},Pa}var Ha,Ga,qa,Va,Za,Ya,Ka,Qa,Ja,Xa={},tl={exports:{}};function el(){if(Ga)return Xa;Ga=1;var t=(Ha||(Ha=1,function(t,e){var r=ca,n=r.Buffer;function i(t,e){for(var r in t)e[r]=t[r]}function o(t,e,r){return n(t,e,r)}n.from&&n.alloc&&n.allocUnsafe&&n.allocUnsafeSlow?t.exports=r:(i(r,e),e.Buffer=o),i(n,o),o.from=function(t,e,r){if("number"==typeof t)throw new TypeError("Argument must not be a number");return n(t,e,r)},o.alloc=function(t,e,r){if("number"!=typeof t)throw new TypeError("Argument must be a number");var i=n(t);return void 0!==e?"string"==typeof r?i.fill(e,r):i.fill(e):i.fill(0),i},o.allocUnsafe=function(t){if("number"!=typeof t)throw new TypeError("Argument must be a number");return n(t)},o.allocUnsafeSlow=function(t){if("number"!=typeof t)throw new TypeError("Argument must be a number");return r.SlowBuffer(t)}}(tl,tl.exports)),tl.exports).Buffer,e=t.isEncoding||function(t){switch((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 r(r){var n;switch(this.encoding=function(r){var n=function(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}}(r);if("string"!=typeof n&&(t.isEncoding===e||!e(r)))throw new Error("Unknown encoding: "+r);return n||r}(r),this.encoding){case"utf16le":this.text=o,this.end=s,n=4;break;case"utf8":this.fillLast=i,n=4;break;case"base64":this.text=a,this.end=l,n=3;break;default:return this.write=u,void(this.end=c)}this.lastNeed=0,this.lastTotal=0,this.lastChar=t.allocUnsafe(n)}function n(t){return t<=127?0:t>>5==6?2:t>>4==14?3:t>>3==30?4:t>>6==2?-1:-2}function i(t){var e=this.lastTotal-this.lastNeed,r=function(t,e){if(128!=(192&e[0]))return t.lastNeed=0,"�";if(t.lastNeed>1&&e.length>1){if(128!=(192&e[1]))return t.lastNeed=1,"�";if(t.lastNeed>2&&e.length>2&&128!=(192&e[2]))return t.lastNeed=2,"�"}}(this,t);return void 0!==r?r:this.lastNeed<=t.length?(t.copy(this.lastChar,e,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(t.copy(this.lastChar,e,0,t.length),void(this.lastNeed-=t.length))}function o(t,e){if((t.length-e)%2==0){var r=t.toString("utf16le",e);if(r){var n=r.charCodeAt(r.length-1);if(n>=55296&&n<=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 s(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 a(t,e){var r=(t.length-e)%3;return 0===r?t.toString("base64",e):(this.lastNeed=3-r,this.lastTotal=3,1===r?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 l(t){var e=t&&t.length?this.write(t):"";return this.lastNeed?e+this.lastChar.toString("base64",0,3-this.lastNeed):e}function u(t){return t.toString(this.encoding)}function c(t){return t&&t.length?this.write(t):""}return Xa.StringDecoder=r,r.prototype.write=function(t){if(0===t.length)return"";var e,r;if(this.lastNeed){if(void 0===(e=this.fillLast(t)))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||""},r.prototype.end=function(t){var e=t&&t.length?this.write(t):"";return this.lastNeed?e+"�":e},r.prototype.text=function(t,e){var r=function(t,e,r){var i=e.length-1;if(i<r)return 0;var o=n(e[i]);if(o>=0)return o>0&&(t.lastNeed=o-1),o;if(--i<r||-2===o)return 0;if(o=n(e[i]),o>=0)return o>0&&(t.lastNeed=o-2),o;if(--i<r||-2===o)return 0;if(o=n(e[i]),o>=0)return o>0&&(2===o?o=0:t.lastNeed=o-3),o;return 0}(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)},r.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},Xa}function rl(){if(Va)return qa;Va=1;var t=aa();qa=y;var e,r=function(){if(ea)return ta;ea=1;var t={}.toString;return ta=Array.isArray||function(e){return"[object Array]"==t.call(e)}}();y.ReadableState=p,yn.EventEmitter;var n=function(t,e){return t.listeners(e).length},i=la(),o=Sa().Buffer,s=(void 0!==Ft?Ft:"undefined"!=typeof window?window:"undefined"!=typeof self?self:{}).Uint8Array||function(){};var a=Object.create(ka());a.inherits=Ca;var l=Na,u=void 0;u=l&&l.debuglog?l.debuglog("stream"):function(){};var c,h=Ba(),f=Wa();a.inherits(y,i);var d=["error","close","destroy","pause","resume"];function p(t,r){t=t||{};var n=r instanceof(e=e||$a());this.objectMode=!!t.objectMode,n&&(this.objectMode=this.objectMode||!!t.readableObjectMode);var i=t.highWaterMark,o=t.readableHighWaterMark,s=this.objectMode?16:16384;this.highWaterMark=i||0===i?i:n&&(o||0===o)?o:s,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new h,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.destroyed=!1,this.defaultEncoding=t.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,t.encoding&&(c||(c=el().StringDecoder),this.decoder=new c(t.encoding),this.encoding=t.encoding)}function y(t){if(e=e||$a(),!(this instanceof y))return new y(t);this._readableState=new p(t,this),this.readable=!0,t&&("function"==typeof t.read&&(this._read=t.read),"function"==typeof t.destroy&&(this._destroy=t.destroy)),i.call(this)}function g(t,e,r,n,i){var a,l=t._readableState;null===e?(l.reading=!1,function(t,e){if(e.ended)return;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,v(t)}(t,l)):(i||(a=function(t,e){var r;n=e,o.isBuffer(n)||n instanceof s||"string"==typeof e||void 0===e||t.objectMode||(r=new TypeError("Invalid non-string/buffer chunk"));var n;return r}(l,e)),a?t.emit("error",a):l.objectMode||e&&e.length>0?("string"==typeof e||l.objectMode||Object.getPrototypeOf(e)===o.prototype||(e=function(t){return o.from(t)}(e)),n?l.endEmitted?t.emit("error",new Error("stream.unshift() after end event")):b(t,l,e,!0):l.ended?t.emit("error",new Error("stream.push() after EOF")):(l.reading=!1,l.decoder&&!r?(e=l.decoder.write(e),l.objectMode||0!==e.length?b(t,l,e,!1):S(t,l)):b(t,l,e,!1))):n||(l.reading=!1));return function(t){return!t.ended&&(t.needReadable||t.length<t.highWaterMark||0===t.length)}(l)}function b(t,e,r,n){e.flowing&&0===e.length&&!e.sync?(t.emit("data",r),t.read(0)):(e.length+=e.objectMode?1:r.length,n?e.buffer.unshift(r):e.buffer.push(r),e.needReadable&&v(t)),S(t,e)}Object.defineProperty(y.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&this._readableState.destroyed},set:function(t){this._readableState&&(this._readableState.destroyed=t)}}),y.prototype.destroy=f.destroy,y.prototype._undestroy=f.undestroy,y.prototype._destroy=function(t,e){this.push(null),e(t)},y.prototype.push=function(t,e){var r,n=this._readableState;return n.objectMode?r=!0:"string"==typeof t&&((e=e||n.defaultEncoding)!==n.encoding&&(t=o.from(t,e),e=""),r=!0),g(this,t,e,!1,r)},y.prototype.unshift=function(t){return g(this,t,null,!0,!1)},y.prototype.isPaused=function(){return!1===this._readableState.flowing},y.prototype.setEncoding=function(t){return c||(c=el().StringDecoder),this._readableState.decoder=new c(t),this._readableState.encoding=t,this};var m=8388608;function _(t,e){return t<=0||0===e.length&&e.ended?0:e.objectMode?1:t!=t?e.flowing&&e.length?e.buffer.head.data.length:e.length:(t>e.highWaterMark&&(e.highWaterMark=function(t){return t>=m?t=m:(t--,t|=t>>>1,t|=t>>>2,t|=t>>>4,t|=t>>>8,t|=t>>>16,t++),t}(t)),t<=e.length?t:e.ended?e.length:(e.needReadable=!0,0))}function v(e){var r=e._readableState;r.needReadable=!1,r.emittedReadable||(u("emitReadable",r.flowing),r.emittedReadable=!0,r.sync?t.nextTick(w,e):w(e))}function w(t){u("emit readable"),t.emit("readable"),T(t)}function S(e,r){r.readingMore||(r.readingMore=!0,t.nextTick(E,e,r))}function E(t,e){for(var r=e.length;!e.reading&&!e.flowing&&!e.ended&&e.length<e.highWaterMark&&(u("maybeReadMore read 0"),t.read(0),r!==e.length);)r=e.length;e.readingMore=!1}function R(t){u("readable nexttick read 0"),t.read(0)}function k(t,e){e.reading||(u("resume read 0"),t.read(0)),e.resumeScheduled=!1,e.awaitDrain=0,t.emit("resume"),T(t),e.flowing&&!e.reading&&t.read(0)}function T(t){var e=t._readableState;for(u("flow",e.flowing);e.flowing&&null!==t.read(););}function x(t,e){return 0===e.length?null:(e.objectMode?r=e.buffer.shift():!t||t>=e.length?(r=e.decoder?e.buffer.join(""):1===e.buffer.length?e.buffer.head.data:e.buffer.concat(e.length),e.buffer.clear()):r=function(t,e,r){var n;t<e.head.data.length?(n=e.head.data.slice(0,t),e.head.data=e.head.data.slice(t)):n=t===e.head.data.length?e.shift():r?function(t,e){var r=e.head,n=1,i=r.data;t-=i.length;for(;r=r.next;){var o=r.data,s=t>o.length?o.length:t;if(s===o.length?i+=o:i+=o.slice(0,t),0===(t-=s)){s===o.length?(++n,r.next?e.head=r.next:e.head=e.tail=null):(e.head=r,r.data=o.slice(s));break}++n}return e.length-=n,i}(t,e):function(t,e){var r=o.allocUnsafe(t),n=e.head,i=1;n.data.copy(r),t-=n.data.length;for(;n=n.next;){var s=n.data,a=t>s.length?s.length:t;if(s.copy(r,r.length-t,0,a),0===(t-=a)){a===s.length?(++i,n.next?e.head=n.next:e.head=e.tail=null):(e.head=n,n.data=s.slice(a));break}++i}return e.length-=i,r}(t,e);return n}(t,e.buffer,e.decoder),r);var r}function A(e){var r=e._readableState;if(r.length>0)throw new Error('"endReadable()" called on non-empty stream');r.endEmitted||(r.ended=!0,t.nextTick(O,r,e))}function O(t,e){t.endEmitted||0!==t.length||(t.endEmitted=!0,e.readable=!1,e.emit("end"))}function L(t,e){for(var r=0,n=t.length;r<n;r++)if(t[r]===e)return r;return-1}return y.prototype.read=function(t){u("read",t),t=parseInt(t,10);var e=this._readableState,r=t;if(0!==t&&(e.emittedReadable=!1),0===t&&e.needReadable&&(e.length>=e.highWaterMark||e.ended))return u("read: emitReadable",e.length,e.ended),0===e.length&&e.ended?A(this):v(this),null;if(0===(t=_(t,e))&&e.ended)return 0===e.length&&A(this),null;var n,i=e.needReadable;return u("need readable",i),(0===e.length||e.length-t<e.highWaterMark)&&u("length less than watermark",i=!0),e.ended||e.reading?u("reading or ended",i=!1):i&&(u("do read"),e.reading=!0,e.sync=!0,0===e.length&&(e.needReadable=!0),this._read(e.highWaterMark),e.sync=!1,e.reading||(t=_(r,e))),null===(n=t>0?x(t,e):null)?(e.needReadable=!0,t=0):e.length-=t,0===e.length&&(e.ended||(e.needReadable=!0),r!==t&&e.ended&&A(this)),null!==n&&this.emit("data",n),n},y.prototype._read=function(t){this.emit("error",new Error("_read() is not implemented"))},y.prototype.pipe=function(e,i){var o=this,s=this._readableState;switch(s.pipesCount){case 0:s.pipes=e;break;case 1:s.pipes=[s.pipes,e];break;default:s.pipes.push(e)}s.pipesCount+=1,u("pipe count=%d opts=%j",s.pipesCount,i);var a=(!i||!1!==i.end)&&e!==process.stdout&&e!==process.stderr?c:m;function l(t,r){u("onunpipe"),t===o&&r&&!1===r.hasUnpiped&&(r.hasUnpiped=!0,u("cleanup"),e.removeListener("close",g),e.removeListener("finish",b),e.removeListener("drain",h),e.removeListener("error",y),e.removeListener("unpipe",l),o.removeListener("end",c),o.removeListener("end",m),o.removeListener("data",p),f=!0,!s.awaitDrain||e._writableState&&!e._writableState.needDrain||h())}function c(){u("onend"),e.end()}s.endEmitted?t.nextTick(a):o.once("end",a),e.on("unpipe",l);var h=function(t){return function(){var e=t._readableState;u("pipeOnDrain",e.awaitDrain),e.awaitDrain&&e.awaitDrain--,0===e.awaitDrain&&n(t,"data")&&(e.flowing=!0,T(t))}}(o);e.on("drain",h);var f=!1;var d=!1;function p(t){u("ondata"),d=!1,!1!==e.write(t)||d||((1===s.pipesCount&&s.pipes===e||s.pipesCount>1&&-1!==L(s.pipes,e))&&!f&&(u("false write response, pause",s.awaitDrain),s.awaitDrain++,d=!0),o.pause())}function y(t){u("onerror",t),m(),e.removeListener("error",y),0===n(e,"error")&&e.emit("error",t)}function g(){e.removeListener("finish",b),m()}function b(){u("onfinish"),e.removeListener("close",g),m()}function m(){u("unpipe"),o.unpipe(e)}return o.on("data",p),function(t,e,n){if("function"==typeof t.prependListener)return t.prependListener(e,n);t._events&&t._events[e]?r(t._events[e])?t._events[e].unshift(n):t._events[e]=[n,t._events[e]]:t.on(e,n)}(e,"error",y),e.once("close",g),e.once("finish",b),e.emit("pipe",o),s.flowing||(u("pipe resume"),o.resume()),e},y.prototype.unpipe=function(t){var e=this._readableState,r={hasUnpiped:!1};if(0===e.pipesCount)return this;if(1===e.pipesCount)return t&&t!==e.pipes||(t||(t=e.pipes),e.pipes=null,e.pipesCount=0,e.flowing=!1,t&&t.emit("unpipe",this,r)),this;if(!t){var n=e.pipes,i=e.pipesCount;e.pipes=null,e.pipesCount=0,e.flowing=!1;for(var o=0;o<i;o++)n[o].emit("unpipe",this,{hasUnpiped:!1});return this}var s=L(e.pipes,t);return-1===s||(e.pipes.splice(s,1),e.pipesCount-=1,1===e.pipesCount&&(e.pipes=e.pipes[0]),t.emit("unpipe",this,r)),this},y.prototype.on=function(e,r){var n=i.prototype.on.call(this,e,r);if("data"===e)!1!==this._readableState.flowing&&this.resume();else if("readable"===e){var o=this._readableState;o.endEmitted||o.readableListening||(o.readableListening=o.needReadable=!0,o.emittedReadable=!1,o.reading?o.length&&v(this):t.nextTick(R,this))}return n},y.prototype.addListener=y.prototype.on,y.prototype.resume=function(){var e=this._readableState;return e.flowing||(u("resume"),e.flowing=!0,function(e,r){r.resumeScheduled||(r.resumeScheduled=!0,t.nextTick(k,e,r))}(this,e)),this},y.prototype.pause=function(){return u("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(u("pause"),this._readableState.flowing=!1,this.emit("pause")),this},y.prototype.wrap=function(t){var e=this,r=this._readableState,n=!1;for(var i in t.on("end",function(){if(u("wrapped end"),r.decoder&&!r.ended){var t=r.decoder.end();t&&t.length&&e.push(t)}e.push(null)}),t.on("data",function(i){(u("wrapped data"),r.decoder&&(i=r.decoder.write(i)),r.objectMode&&null==i)||(r.objectMode||i&&i.length)&&(e.push(i)||(n=!0,t.pause()))}),t)void 0===this[i]&&"function"==typeof t[i]&&(this[i]=function(e){return function(){return t[e].apply(t,arguments)}}(i));for(var o=0;o<d.length;o++)t.on(d[o],this.emit.bind(this,d[o]));return this._read=function(e){u("wrapped _read",e),n&&(n=!1,t.resume())},this},Object.defineProperty(y.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),y._fromList=x,qa}function nl(){if(Ya)return Za;Ya=1,Za=n;var t=$a(),e=Object.create(ka());function r(t,e){var r=this._transformState;r.transforming=!1;var n=r.writecb;if(!n)return this.emit("error",new Error("write callback called multiple times"));r.writechunk=null,r.writecb=null,null!=e&&this.push(e),n(t);var i=this._readableState;i.reading=!1,(i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}function n(e){if(!(this instanceof n))return new n(e);t.call(this,e),this._transformState={afterTransform:r.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,e&&("function"==typeof e.transform&&(this._transform=e.transform),"function"==typeof e.flush&&(this._flush=e.flush)),this.on("prefinish",i)}function i(){var t=this;"function"==typeof this._flush?this._flush(function(e,r){o(t,e,r)}):o(this,null,null)}function o(t,e,r){if(e)return t.emit("error",e);if(null!=r&&t.push(r),t._writableState.length)throw new Error("Calling transform done when ws.length != 0");if(t._transformState.transforming)throw new Error("Calling transform done when still transforming");return t.push(null)}return e.inherits=Ca,e.inherits(n,t),n.prototype.push=function(e,r){return this._transformState.needTransform=!1,t.prototype.push.call(this,e,r)},n.prototype._transform=function(t,e,r){throw new Error("_transform() is not implemented")},n.prototype._write=function(t,e,r){var n=this._transformState;if(n.writecb=r,n.writechunk=t,n.writeencoding=e,!n.transforming){var i=this._readableState;(n.needTransform||i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}},n.prototype._read=function(t){var e=this._transformState;null!==e.writechunk&&e.writecb&&!e.transforming?(e.transforming=!0,this._transform(e.writechunk,e.writeencoding,e.afterTransform)):e.needTransform=!0},n.prototype._destroy=function(e,r){var n=this;t.prototype._destroy.call(this,e,function(t){r(t),n.emit("close")})},Za}function il(){return Ja||(Ja=1,function(t,e){(e=t.exports=rl()).Stream=e,e.Readable=e,e.Writable=za(),e.Duplex=$a(),e.Transform=nl(),e.PassThrough=function(){if(Qa)return Ka;Qa=1,Ka=r;var t=nl(),e=Object.create(ka());function r(e){if(!(this instanceof r))return new r(e);t.call(this,e)}return e.inherits=Ca,e.inherits(r,t),r.prototype._transform=function(t,e,r){r(null,t)},Ka}()}(oa,oa.exports)),oa.exports}var ol=il().PassThrough,sl=s,al=ol,ll={Readable:cl,Writable:hl};function ul(t,e,r){t[e]=function(){return delete t[e],r.apply(this,arguments),this[e].apply(this,arguments)}}function cl(t,e){if(!(this instanceof cl))return new cl(t,e);al.call(this,e),ul(this,"_read",function(){var r=t.call(this,e),n=this.emit.bind(this,"error");r.on("error",n),r.pipe(this)}),this.emit("readable")}function hl(t,e){if(!(this instanceof hl))return new hl(t,e);al.call(this,e),ul(this,"_write",function(){var r=t.call(this,e),n=this.emit.bind(this,"error");r.on("error",n),this.pipe(r)}),this.emit("writable")}
15
- /*!
16
- * normalize-path <https://github.com/jonschlinkert/normalize-path>
17
- *
18
- * Copyright (c) 2014-2018, Jon Schlinkert.
19
- * Released under the MIT License.
20
- */sl.inherits(cl,al),sl.inherits(hl,al);var fl=function(t,e){if("string"!=typeof t)throw new TypeError("expected path to be a string");if("\\"===t||"/"===t)return"/";var r=t.length;if(r<=1)return t;var n="";if(r>4&&"\\"===t[3]){var i=t[2];"?"!==i&&"."!==i||"\\\\"!==t.slice(0,2)||(t=t.slice(2),n="//")}var o=t.split(/[/\\]+/);return!1!==e&&""===o[o.length-1]&&o.pop(),n+o.join("/")};var dl=function(t){return t};var pl=function(t,e,r){switch(r.length){case 0:return t.call(e);case 1:return t.call(e,r[0]);case 2:return t.call(e,r[0],r[1]);case 3:return t.call(e,r[0],r[1],r[2])}return t.apply(e,r)},yl=pl,gl=Math.max;var bl=function(t,e,r){return e=gl(void 0===e?t.length-1:e,0),function(){for(var n=arguments,i=-1,o=gl(n.length-e,0),s=Array(o);++i<o;)s[i]=n[e+i];i=-1;for(var a=Array(e+1);++i<e;)a[i]=n[i];return a[e]=r(s),yl(t,this,a)}};var ml=function(t){return function(){return t}},_l="object"==typeof Ft&&Ft&&Ft.Object===Object&&Ft,vl=_l,wl="object"==typeof self&&self&&self.Object===Object&&self,Sl=vl||wl||Function("return this")(),El=Sl.Symbol,Rl=El,kl=Object.prototype,Tl=kl.hasOwnProperty,xl=kl.toString,Al=Rl?Rl.toStringTag:void 0;var Ol=function(t){var e=Tl.call(t,Al),r=t[Al];try{t[Al]=void 0;var n=!0}catch(t){}var i=xl.call(t);return n&&(e?t[Al]=r:delete t[Al]),i},Ll=Object.prototype.toString;var jl=Ol,Ml=function(t){return Ll.call(t)},Il=El?El.toStringTag:void 0;var Pl=function(t){return null==t?void 0===t?"[object Undefined]":"[object Null]":Il&&Il in Object(t)?jl(t):Ml(t)};var Dl=function(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)},Cl=Pl,Nl=Dl;var Fl=function(t){if(!Nl(t))return!1;var e=Cl(t);return"[object Function]"==e||"[object GeneratorFunction]"==e||"[object AsyncFunction]"==e||"[object Proxy]"==e},Bl=Sl["__core-js_shared__"],Wl=function(){var t=/[^.]+$/.exec(Bl&&Bl.keys&&Bl.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""}();var Ul=function(t){return!!Wl&&Wl in t},zl=Function.prototype.toString;var $l=function(t){if(null!=t){try{return zl.call(t)}catch(t){}try{return t+""}catch(t){}}return""},Hl=Fl,Gl=Ul,ql=Dl,Vl=$l,Zl=/^\[object .+?Constructor\]$/,Yl=Function.prototype,Kl=Object.prototype,Ql=Yl.toString,Jl=Kl.hasOwnProperty,Xl=RegExp("^"+Ql.call(Jl).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");var tu=function(t,e){return null==t?void 0:t[e]},eu=function(t){return!(!ql(t)||Gl(t))&&(Hl(t)?Xl:Zl).test(Vl(t))},ru=tu;var nu=function(t,e){var r=ru(t,e);return eu(r)?r:void 0},iu=nu,ou=function(){try{var t=iu(Object,"defineProperty");return t({},"",{}),t}catch(t){}}(),su=ml,au=ou,lu=au?function(t,e){return au(t,"toString",{configurable:!0,enumerable:!1,value:su(e),writable:!0})}:dl,uu=lu,cu=Date.now;var hu=function(t){var e=0,r=0;return function(){var n=cu(),i=16-(n-r);if(r=n,i>0){if(++e>=800)return arguments[0]}else e=0;return t.apply(void 0,arguments)}},fu=hu(uu),du=dl,pu=bl,yu=fu;var gu=function(t,e){return yu(pu(t,e,du),t+"")};var bu=function(t,e){return t===e||t!=t&&e!=e};var mu=function(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=9007199254740991},_u=Fl,vu=mu;var wu=function(t){return null!=t&&vu(t.length)&&!_u(t)},Su=/^(?:0|[1-9]\d*)$/;var Eu=function(t,e){var r=typeof t;return!!(e=null==e?9007199254740991:e)&&("number"==r||"symbol"!=r&&Su.test(t))&&t>-1&&t%1==0&&t<e},Ru=bu,ku=wu,Tu=Eu,xu=Dl;var Au=function(t,e,r){if(!xu(r))return!1;var n=typeof e;return!!("number"==n?ku(r)&&Tu(e,r.length):"string"==n&&e in r)&&Ru(r[e],t)};var Ou=function(t,e){for(var r=-1,n=Array(t);++r<t;)n[r]=e(r);return n};var Lu=function(t){return null!=t&&"object"==typeof t},ju=Pl,Mu=Lu;var Iu=function(t){return Mu(t)&&"[object Arguments]"==ju(t)},Pu=Lu,Du=Object.prototype,Cu=Du.hasOwnProperty,Nu=Du.propertyIsEnumerable,Fu=Iu(function(){return arguments}())?Iu:function(t){return Pu(t)&&Cu.call(t,"callee")&&!Nu.call(t,"callee")},Bu=Fu,Wu=Array.isArray,Uu={exports:{}};var zu=function(){return!1};!function(t,e){var r=Sl,n=zu,i=e&&!e.nodeType&&e,o=i&&t&&!t.nodeType&&t,s=o&&o.exports===i?r.Buffer:void 0,a=(s?s.isBuffer:void 0)||n;t.exports=a}(Uu,Uu.exports);var $u=Uu.exports,Hu=Pl,Gu=mu,qu=Lu,Vu={};Vu["[object Float32Array]"]=Vu["[object Float64Array]"]=Vu["[object Int8Array]"]=Vu["[object Int16Array]"]=Vu["[object Int32Array]"]=Vu["[object Uint8Array]"]=Vu["[object Uint8ClampedArray]"]=Vu["[object Uint16Array]"]=Vu["[object Uint32Array]"]=!0,Vu["[object Arguments]"]=Vu["[object Array]"]=Vu["[object ArrayBuffer]"]=Vu["[object Boolean]"]=Vu["[object DataView]"]=Vu["[object Date]"]=Vu["[object Error]"]=Vu["[object Function]"]=Vu["[object Map]"]=Vu["[object Number]"]=Vu["[object Object]"]=Vu["[object RegExp]"]=Vu["[object Set]"]=Vu["[object String]"]=Vu["[object WeakMap]"]=!1;var Zu=function(t){return qu(t)&&Gu(t.length)&&!!Vu[Hu(t)]};var Yu=function(t){return function(e){return t(e)}},Ku={exports:{}};!function(t,e){var r=_l,n=e&&!e.nodeType&&e,i=n&&t&&!t.nodeType&&t,o=i&&i.exports===n&&r.process,s=function(){try{var t=i&&i.require&&i.require("util").types;return t||o&&o.binding&&o.binding("util")}catch(t){}}();t.exports=s}(Ku,Ku.exports);var Qu=Ku.exports,Ju=Zu,Xu=Yu,tc=Qu&&Qu.isTypedArray,ec=tc?Xu(tc):Ju,rc=Ou,nc=Bu,ic=Wu,oc=$u,sc=Eu,ac=ec,lc=Object.prototype.hasOwnProperty;var uc=function(t,e){var r=ic(t),n=!r&&nc(t),i=!r&&!n&&oc(t),o=!r&&!n&&!i&&ac(t),s=r||n||i||o,a=s?rc(t.length,String):[],l=a.length;for(var u in t)!e&&!lc.call(t,u)||s&&("length"==u||i&&("offset"==u||"parent"==u)||o&&("buffer"==u||"byteLength"==u||"byteOffset"==u)||sc(u,l))||a.push(u);return a},cc=Object.prototype;var hc=function(t){var e=[];if(null!=t)for(var r in Object(t))e.push(r);return e},fc=Dl,dc=function(t){var e=t&&t.constructor;return t===("function"==typeof e&&e.prototype||cc)},pc=hc,yc=Object.prototype.hasOwnProperty;var gc=function(t){if(!fc(t))return pc(t);var e=dc(t),r=[];for(var n in t)("constructor"!=n||!e&&yc.call(t,n))&&r.push(n);return r},bc=uc,mc=gc,_c=wu;var vc=gu,wc=bu,Sc=Au,Ec=function(t){return _c(t)?bc(t,!0):mc(t)},Rc=Object.prototype,kc=Rc.hasOwnProperty,Tc=vc(function(t,e){t=Object(t);var r=-1,n=e.length,i=n>2?e[2]:void 0;for(i&&Sc(e[0],e[1],i)&&(n=1);++r<n;)for(var o=e[r],s=Ec(o),a=-1,l=s.length;++a<l;){var u=s[a],c=t[u];(void 0===c||wc(c,Rc[u])&&!kc.call(t,u))&&(t[u]=o[u])}return t}),xc=Tc,Ac={exports:{}},Oc={exports:{}};let Lc=class extends Error{constructor(t){if(!Array.isArray(t))throw new TypeError("Expected input to be an Array, got "+typeof t);let e="";for(let r=0;r<t.length;r++)e+=` ${t[r].stack}\n`;super(e),this.name="AggregateError",this.errors=t}};var jc={AggregateError:Lc,ArrayIsArray:t=>Array.isArray(t),ArrayPrototypeIncludes:(t,e)=>t.includes(e),ArrayPrototypeIndexOf:(t,e)=>t.indexOf(e),ArrayPrototypeJoin:(t,e)=>t.join(e),ArrayPrototypeMap:(t,e)=>t.map(e),ArrayPrototypePop:(t,e)=>t.pop(e),ArrayPrototypePush:(t,e)=>t.push(e),ArrayPrototypeSlice:(t,e,r)=>t.slice(e,r),Error:Error,FunctionPrototypeCall:(t,e,...r)=>t.call(e,...r),FunctionPrototypeSymbolHasInstance:(t,e)=>Function.prototype[Symbol.hasInstance].call(t,e),MathFloor:Math.floor,Number:Number,NumberIsInteger:Number.isInteger,NumberIsNaN:Number.isNaN,NumberMAX_SAFE_INTEGER:Number.MAX_SAFE_INTEGER,NumberMIN_SAFE_INTEGER:Number.MIN_SAFE_INTEGER,NumberParseInt:Number.parseInt,ObjectDefineProperties:(t,e)=>Object.defineProperties(t,e),ObjectDefineProperty:(t,e,r)=>Object.defineProperty(t,e,r),ObjectGetOwnPropertyDescriptor:(t,e)=>Object.getOwnPropertyDescriptor(t,e),ObjectKeys:t=>Object.keys(t),ObjectSetPrototypeOf:(t,e)=>Object.setPrototypeOf(t,e),Promise:Promise,PromisePrototypeCatch:(t,e)=>t.catch(e),PromisePrototypeThen:(t,e,r)=>t.then(e,r),PromiseReject:t=>Promise.reject(t),PromiseResolve:t=>Promise.resolve(t),ReflectApply:Reflect.apply,RegExpPrototypeTest:(t,e)=>t.test(e),SafeSet:Set,String:String,StringPrototypeSlice:(t,e,r)=>t.slice(e,r),StringPrototypeToLowerCase:t=>t.toLowerCase(),StringPrototypeToUpperCase:t=>t.toUpperCase(),StringPrototypeTrim:t=>t.trim(),Symbol:Symbol,SymbolFor:Symbol.for,SymbolAsyncIterator:Symbol.asyncIterator,SymbolHasInstance:Symbol.hasInstance,SymbolIterator:Symbol.iterator,SymbolDispose:Symbol.dispose||Symbol("Symbol.dispose"),SymbolAsyncDispose:Symbol.asyncDispose||Symbol("Symbol.asyncDispose"),TypedArrayPrototypeSet:(t,e,r)=>t.set(e,r),Boolean:Boolean,Uint8Array:Uint8Array},Mc={exports:{}},Ic={format:(t,...e)=>t.replace(/%([sdifj])/g,function(...[t,r]){const n=e.shift();if("f"===r)return n.toFixed(6);if("j"===r)return JSON.stringify(n);if("s"===r&&"object"==typeof n){return`${n.constructor!==Object?n.constructor.name:""} {}`.trim()}return n.toString()}),inspect(t){switch(typeof t){case"string":if(t.includes("'")){if(!t.includes('"'))return`"${t}"`;if(!t.includes("`")&&!t.includes("${"))return`\`${t}\``}return`'${t}'`;case"number":return isNaN(t)?"NaN":Object.is(t,-0)?String(t):t;case"bigint":return`${String(t)}n`;case"boolean":case"undefined":return String(t);case"object":return"{}"}}};const{format:Pc,inspect:Dc}=Ic,{AggregateError:Cc}=jc,Nc=globalThis.AggregateError||Cc,Fc=Symbol("kIsNodeError"),Bc=["string","function","number","object","Function","Object","boolean","bigint","symbol"],Wc=/^([A-Z][a-z0-9]*)+$/,Uc={};function zc(t,e){if(!t)throw new Uc.ERR_INTERNAL_ASSERTION(e)}function $c(t){let e="",r=t.length;const n="-"===t[0]?1:0;for(;r>=n+4;r-=3)e=`_${t.slice(r-3,r)}${e}`;return`${t.slice(0,r)}${e}`}function Hc(t,e,r){r||(r=Error);class n extends r{constructor(...r){super(function(t,e,r){if("function"==typeof e)return zc(e.length<=r.length,`Code: ${t}; The provided arguments length (${r.length}) does not match the required ones (${e.length}).`),e(...r);const n=(e.match(/%[dfijoOs]/g)||[]).length;return zc(n===r.length,`Code: ${t}; The provided arguments length (${r.length}) does not match the required ones (${n}).`),0===r.length?e:Pc(e,...r)}(t,e,r))}toString(){return`${this.name} [${t}]: ${this.message}`}}Object.defineProperties(n.prototype,{name:{value:r.name,writable:!0,enumerable:!1,configurable:!0},toString:{value(){return`${this.name} [${t}]: ${this.message}`},writable:!0,enumerable:!1,configurable:!0}}),n.prototype.code=t,n.prototype[Fc]=!0,Uc[t]=n}function Gc(t){const e="__node_internal_"+t.name;return Object.defineProperty(t,"name",{value:e}),t}let qc=class extends Error{constructor(t="The operation was aborted",e=void 0){if(void 0!==e&&"object"!=typeof e)throw new Uc.ERR_INVALID_ARG_TYPE("options","Object",e);super(t,e),this.code="ABORT_ERR",this.name="AbortError"}};Hc("ERR_ASSERTION","%s",Error),Hc("ERR_INVALID_ARG_TYPE",(t,e,r)=>{zc("string"==typeof t,"'name' must be a string"),Array.isArray(e)||(e=[e]);let n="The ";t.endsWith(" argument")?n+=`${t} `:n+=`"${t}" ${t.includes(".")?"property":"argument"} `,n+="must be ";const i=[],o=[],s=[];for(const t of e)zc("string"==typeof t,"All expected entries have to be of type string"),Bc.includes(t)?i.push(t.toLowerCase()):Wc.test(t)?o.push(t):(zc("object"!==t,'The value "object" should be written as "Object"'),s.push(t));if(o.length>0){const t=i.indexOf("object");-1!==t&&(i.splice(i,t,1),o.push("Object"))}if(i.length>0){switch(i.length){case 1:n+=`of type ${i[0]}`;break;case 2:n+=`one of type ${i[0]} or ${i[1]}`;break;default:{const t=i.pop();n+=`one of type ${i.join(", ")}, or ${t}`}}(o.length>0||s.length>0)&&(n+=" or ")}if(o.length>0){switch(o.length){case 1:n+=`an instance of ${o[0]}`;break;case 2:n+=`an instance of ${o[0]} or ${o[1]}`;break;default:{const t=o.pop();n+=`an instance of ${o.join(", ")}, or ${t}`}}s.length>0&&(n+=" or ")}switch(s.length){case 0:break;case 1:s[0].toLowerCase()!==s[0]&&(n+="an "),n+=`${s[0]}`;break;case 2:n+=`one of ${s[0]} or ${s[1]}`;break;default:{const t=s.pop();n+=`one of ${s.join(", ")}, or ${t}`}}if(null==r)n+=`. Received ${r}`;else if("function"==typeof r&&r.name)n+=`. Received function ${r.name}`;else if("object"==typeof r){var a;if(null!==(a=r.constructor)&&void 0!==a&&a.name)n+=`. Received an instance of ${r.constructor.name}`;else{n+=`. Received ${Dc(r,{depth:-1})}`}}else{let t=Dc(r,{colors:!1});t.length>25&&(t=`${t.slice(0,25)}...`),n+=`. Received type ${typeof r} (${t})`}return n},TypeError),Hc("ERR_INVALID_ARG_VALUE",(t,e,r="is invalid")=>{let n=Dc(e);n.length>128&&(n=n.slice(0,128)+"...");return`The ${t.includes(".")?"property":"argument"} '${t}' ${r}. Received ${n}`},TypeError),Hc("ERR_INVALID_RETURN_VALUE",(t,e,r)=>{var n;return`Expected ${t} to be returned from the "${e}" function but got ${null!=r&&null!==(n=r.constructor)&&void 0!==n&&n.name?`instance of ${r.constructor.name}`:"type "+typeof r}.`},TypeError),Hc("ERR_MISSING_ARGS",(...t)=>{let e;zc(t.length>0,"At least one arg needs to be specified");const r=t.length;switch(t=(Array.isArray(t)?t:[t]).map(t=>`"${t}"`).join(" or "),r){case 1:e+=`The ${t[0]} argument`;break;case 2:e+=`The ${t[0]} and ${t[1]} arguments`;break;default:{const r=t.pop();e+=`The ${t.join(", ")}, and ${r} arguments`}}return`${e} must be specified`},TypeError),Hc("ERR_OUT_OF_RANGE",(t,e,r)=>{let n;if(zc(e,'Missing "range" argument'),Number.isInteger(r)&&Math.abs(r)>2**32)n=$c(String(r));else if("bigint"==typeof r){n=String(r);const t=BigInt(2)**BigInt(32);(r>t||r<-t)&&(n=$c(n)),n+="n"}else n=Dc(r);return`The value of "${t}" is out of range. It must be ${e}. Received ${n}`},RangeError),Hc("ERR_MULTIPLE_CALLBACK","Callback called multiple times",Error),Hc("ERR_METHOD_NOT_IMPLEMENTED","The %s method is not implemented",Error),Hc("ERR_STREAM_ALREADY_FINISHED","Cannot call %s after a stream was finished",Error),Hc("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable",Error),Hc("ERR_STREAM_DESTROYED","Cannot call %s after a stream was destroyed",Error),Hc("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),Hc("ERR_STREAM_PREMATURE_CLOSE","Premature close",Error),Hc("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF",Error),Hc("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event",Error),Hc("ERR_STREAM_WRITE_AFTER_END","write after end",Error),Hc("ERR_UNKNOWN_ENCODING","Unknown encoding: %s",TypeError);var Vc,Zc={AbortError:qc,aggregateTwoErrors:Gc(function(t,e){if(t&&e&&t!==e){if(Array.isArray(e.errors))return e.errors.push(t),e;const r=new Nc([e,t],e.message);return r.code=e.code,r}return t||e}),hideStackFrames:Gc,codes:Uc},Yc={exports:{}};function Kc(){if(Vc)return Yc.exports;Vc=1;const{AbortController:t,AbortSignal:e}="undefined"!=typeof self?self:"undefined"!=typeof window?window:void 0;return Yc.exports=t,Yc.exports.AbortSignal=e,Yc.exports.default=t,Yc.exports}!function(t){const e=ca,{format:r,inspect:n}=Ic,{codes:{ERR_INVALID_ARG_TYPE:i}}=Zc,{kResistStopPropagation:o,AggregateError:s,SymbolDispose:a}=jc,l=globalThis.AbortSignal||Kc().AbortSignal,u=globalThis.AbortController||Kc().AbortController,c=Object.getPrototypeOf(async function(){}).constructor,h=globalThis.Blob||e.Blob,f=void 0!==h?function(t){return t instanceof h}:function(t){return!1},d=(t,e)=>{if(void 0!==t&&(null===t||"object"!=typeof t||!("aborted"in t)))throw new i(e,"AbortSignal",t)};t.exports={AggregateError:s,kEmptyObject:Object.freeze({}),once(t){let e=!1;return function(...r){e||(e=!0,t.apply(this,r))}},createDeferredPromise:function(){let t,e;return{promise:new Promise((r,n)=>{t=r,e=n}),resolve:t,reject:e}},promisify:t=>new Promise((e,r)=>{t((t,...n)=>t?r(t):e(...n))}),debuglog:()=>function(){},format:r,inspect:n,types:{isAsyncFunction:t=>t instanceof c,isArrayBufferView:t=>ArrayBuffer.isView(t)},isBlob:f,deprecate:(t,e)=>t,addAbortListener:yn.addAbortListener||function(t,e){if(void 0===t)throw new i("signal","AbortSignal",t);let r;return d(t,"signal"),((t,e)=>{if("function"!=typeof t)throw new i(e,"Function",t)})(e,"listener"),t.aborted?queueMicrotask(()=>e()):(t.addEventListener("abort",e,{__proto__:null,once:!0,[o]:!0}),r=()=>{t.removeEventListener("abort",e)}),{__proto__:null,[a](){var t;null===(t=r)||void 0===t||t()}}},AbortSignalAny:l.any||function(t){if(1===t.length)return t[0];const e=new u,r=()=>e.abort();return t.forEach(t=>{d(t,"signals"),t.addEventListener("abort",r,{once:!0})}),e.signal.addEventListener("abort",()=>{t.forEach(t=>t.removeEventListener("abort",r))},{once:!0}),e.signal}},t.exports.promisify.custom=Symbol.for("nodejs.util.promisify.custom")}(Mc);var Qc=Mc.exports,Jc={};const{ArrayIsArray:Xc,ArrayPrototypeIncludes:th,ArrayPrototypeJoin:eh,ArrayPrototypeMap:rh,NumberIsInteger:nh,NumberIsNaN:ih,NumberMAX_SAFE_INTEGER:oh,NumberMIN_SAFE_INTEGER:sh,NumberParseInt:ah,ObjectPrototypeHasOwnProperty:lh,RegExpPrototypeExec:uh,String:ch,StringPrototypeToUpperCase:hh,StringPrototypeTrim:fh}=jc,{hideStackFrames:dh,codes:{ERR_SOCKET_BAD_PORT:ph,ERR_INVALID_ARG_TYPE:yh,ERR_INVALID_ARG_VALUE:gh,ERR_OUT_OF_RANGE:bh,ERR_UNKNOWN_SIGNAL:mh}}=Zc,{normalizeEncoding:_h}=Qc,{isAsyncFunction:vh,isArrayBufferView:wh}=Qc.types,Sh={};const Eh=/^[0-7]+$/;const Rh=dh((t,e,r=sh,n=oh)=>{if("number"!=typeof t)throw new yh(e,"number",t);if(!nh(t))throw new bh(e,"an integer",t);if(t<r||t>n)throw new bh(e,`>= ${r} && <= ${n}`,t)}),kh=dh((t,e,r=-2147483648,n=2147483647)=>{if("number"!=typeof t)throw new yh(e,"number",t);if(!nh(t))throw new bh(e,"an integer",t);if(t<r||t>n)throw new bh(e,`>= ${r} && <= ${n}`,t)}),Th=dh((t,e,r=!1)=>{if("number"!=typeof t)throw new yh(e,"number",t);if(!nh(t))throw new bh(e,"an integer",t);const n=r?1:0,i=4294967295;if(t<n||t>i)throw new bh(e,`>= ${n} && <= ${i}`,t)});function xh(t,e){if("string"!=typeof t)throw new yh(e,"string",t)}const Ah=dh((t,e,r)=>{if(!th(r,t)){const n=eh(rh(r,t=>"string"==typeof t?`'${t}'`:ch(t)),", ");throw new gh(e,t,"must be one of: "+n)}});function Oh(t,e){if("boolean"!=typeof t)throw new yh(e,"boolean",t)}function Lh(t,e,r){return null!=t&&lh(t,e)?t[e]:r}const jh=dh((t,e,r=null)=>{const n=Lh(r,"allowArray",!1),i=Lh(r,"allowFunction",!1);if(!Lh(r,"nullable",!1)&&null===t||!n&&Xc(t)||"object"!=typeof t&&(!i||"function"!=typeof t))throw new yh(e,"Object",t)}),Mh=dh((t,e)=>{if(null!=t&&"object"!=typeof t&&"function"!=typeof t)throw new yh(e,"a dictionary",t)}),Ih=dh((t,e,r=0)=>{if(!Xc(t))throw new yh(e,"Array",t);if(t.length<r){throw new gh(e,t,`must be longer than ${r}`)}});const Ph=dh((t,e="buffer")=>{if(!wh(t))throw new yh(e,["Buffer","TypedArray","DataView"],t)});const Dh=dh((t,e)=>{if(void 0!==t&&(null===t||"object"!=typeof t||!("aborted"in t)))throw new yh(e,"AbortSignal",t)}),Ch=dh((t,e)=>{if("function"!=typeof t)throw new yh(e,"Function",t)}),Nh=dh((t,e)=>{if("function"!=typeof t||vh(t))throw new yh(e,"Function",t)}),Fh=dh((t,e)=>{if(void 0!==t)throw new yh(e,"undefined",t)});const Bh=/^(?:<[^>]*>)(?:\s*;\s*[^;"\s]+(?:=(")?[^;"\s]*\1)?)*$/;function Wh(t,e){if(void 0===t||!uh(Bh,t))throw new gh(e,t,'must be an array or string of format "</styles.css>; rel=preload; as=style"')}var Uh,zh,$h={isInt32:function(t){return t===(0|t)},isUint32:function(t){return t===t>>>0},parseFileMode:function(t,e,r){if(void 0===t&&(t=r),"string"==typeof t){if(null===uh(Eh,t))throw new gh(e,t,"must be a 32-bit unsigned integer or an octal string");t=ah(t,8)}return Th(t,e),t},validateArray:Ih,validateStringArray:function(t,e){Ih(t,e);for(let r=0;r<t.length;r++)xh(t[r],`${e}[${r}]`)},validateBooleanArray:function(t,e){Ih(t,e);for(let r=0;r<t.length;r++)Oh(t[r],`${e}[${r}]`)},validateAbortSignalArray:function(t,e){Ih(t,e);for(let r=0;r<t.length;r++){const n=t[r],i=`${e}[${r}]`;if(null==n)throw new yh(i,"AbortSignal",n);Dh(n,i)}},validateBoolean:Oh,validateBuffer:Ph,validateDictionary:Mh,validateEncoding:function(t,e){const r=_h(e),n=t.length;if("hex"===r&&n%2!=0)throw new gh("encoding",e,`is invalid for data of length ${n}`)},validateFunction:Ch,validateInt32:kh,validateInteger:Rh,validateNumber:function(t,e,r=void 0,n){if("number"!=typeof t)throw new yh(e,"number",t);if(null!=r&&t<r||null!=n&&t>n||(null!=r||null!=n)&&ih(t))throw new bh(e,`${null!=r?`>= ${r}`:""}${null!=r&&null!=n?" && ":""}${null!=n?`<= ${n}`:""}`,t)},validateObject:jh,validateOneOf:Ah,validatePlainFunction:Nh,validatePort:function(t,e="Port",r=!0){if("number"!=typeof t&&"string"!=typeof t||"string"==typeof t&&0===fh(t).length||+t!==+t>>>0||t>65535||0===t&&!r)throw new ph(e,t,r);return 0|t},validateSignalName:function(t,e="signal"){if(xh(t,e),void 0===Sh[t]){if(void 0!==Sh[hh(t)])throw new mh(t+" (signals must use all capital letters)");throw new mh(t)}},validateString:xh,validateUint32:Th,validateUndefined:Fh,validateUnion:function(t,e,r){if(!th(r,t))throw new yh(e,`('${eh(r,"|")}')`,t)},validateAbortSignal:Dh,validateLinkHeaderValue:function(t){if("string"==typeof t)return Wh(t,"hints"),t;if(Xc(t)){const e=t.length;let r="";if(0===e)return r;for(let n=0;n<e;n++){const i=t[n];Wh(i,"hints"),r+=i,n!==e-1&&(r+=", ")}return r}throw new gh("hints",t,'must be an array or string of format "</styles.css>; rel=preload; as=style"')}},Hh={exports:{}},Gh={exports:{}},qh=Gh.exports={};function Vh(){throw new Error("setTimeout has not been defined")}function Zh(){throw new Error("clearTimeout has not been defined")}function Yh(t){if(Uh===setTimeout)return setTimeout(t,0);if((Uh===Vh||!Uh)&&setTimeout)return Uh=setTimeout,setTimeout(t,0);try{return Uh(t,0)}catch(e){try{return Uh.call(null,t,0)}catch(e){return Uh.call(this,t,0)}}}!function(){try{Uh="function"==typeof setTimeout?setTimeout:Vh}catch(t){Uh=Vh}try{zh="function"==typeof clearTimeout?clearTimeout:Zh}catch(t){zh=Zh}}();var Kh,Qh=[],Jh=!1,Xh=-1;function tf(){Jh&&Kh&&(Jh=!1,Kh.length?Qh=Kh.concat(Qh):Xh=-1,Qh.length&&ef())}function ef(){if(!Jh){var t=Yh(tf);Jh=!0;for(var e=Qh.length;e;){for(Kh=Qh,Qh=[];++Xh<e;)Kh&&Kh[Xh].run();Xh=-1,e=Qh.length}Kh=null,Jh=!1,function(t){if(zh===clearTimeout)return clearTimeout(t);if((zh===Zh||!zh)&&clearTimeout)return zh=clearTimeout,clearTimeout(t);try{return zh(t)}catch(e){try{return zh.call(null,t)}catch(e){return zh.call(this,t)}}}(t)}}function rf(t,e){this.fun=t,this.array=e}function nf(){}qh.nextTick=function(t){var e=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)e[r-1]=arguments[r];Qh.push(new rf(t,e)),1!==Qh.length||Jh||Yh(ef)},rf.prototype.run=function(){this.fun.apply(null,this.array)},qh.title="browser",qh.browser=!0,qh.env={},qh.argv=[],qh.version="",qh.versions={},qh.on=nf,qh.addListener=nf,qh.once=nf,qh.off=nf,qh.removeListener=nf,qh.removeAllListeners=nf,qh.emit=nf,qh.prependListener=nf,qh.prependOnceListener=nf,qh.listeners=function(t){return[]},qh.binding=function(t){throw new Error("process.binding is not supported")},qh.cwd=function(){return"/"},qh.chdir=function(t){throw new Error("process.chdir is not supported")},qh.umask=function(){return 0};var of=Gh.exports;const{SymbolAsyncIterator:sf,SymbolIterator:af,SymbolFor:lf}=jc,uf=lf("nodejs.stream.destroyed"),cf=lf("nodejs.stream.errored"),hf=lf("nodejs.stream.readable"),ff=lf("nodejs.stream.writable"),df=lf("nodejs.stream.disturbed"),pf=lf("nodejs.webstream.isClosedPromise"),yf=lf("nodejs.webstream.controllerErrorFunction");function gf(t,e=!1){var r;return!(!t||"function"!=typeof t.pipe||"function"!=typeof t.on||e&&("function"!=typeof t.pause||"function"!=typeof t.resume)||t._writableState&&!1===(null===(r=t._readableState)||void 0===r?void 0:r.readable)||t._writableState&&!t._readableState)}function bf(t){var e;return!(!t||"function"!=typeof t.write||"function"!=typeof t.on||t._readableState&&!1===(null===(e=t._writableState)||void 0===e?void 0:e.writable))}function mf(t){return t&&(t._readableState||t._writableState||"function"==typeof t.write&&"function"==typeof t.on||"function"==typeof t.pipe&&"function"==typeof t.on)}function _f(t){return!(!t||mf(t)||"function"!=typeof t.pipeThrough||"function"!=typeof t.getReader||"function"!=typeof t.cancel)}function vf(t){return!(!t||mf(t)||"function"!=typeof t.getWriter||"function"!=typeof t.abort)}function wf(t){return!(!t||mf(t)||"object"!=typeof t.readable||"object"!=typeof t.writable)}function Sf(t){if(!mf(t))return null;const e=t._writableState,r=t._readableState,n=e||r;return!!(t.destroyed||t[uf]||null!=n&&n.destroyed)}function Ef(t){if(!bf(t))return null;if(!0===t.writableEnded)return!0;const e=t._writableState;return(null==e||!e.errored)&&("boolean"!=typeof(null==e?void 0:e.ended)?null:e.ended)}function Rf(t,e){if(!gf(t))return null;const r=t._readableState;return(null==r||!r.errored)&&("boolean"!=typeof(null==r?void 0:r.endEmitted)?null:!!(r.endEmitted||!1===e&&!0===r.ended&&0===r.length))}function kf(t){return t&&null!=t[hf]?t[hf]:"boolean"!=typeof(null==t?void 0:t.readable)?null:!Sf(t)&&(gf(t)&&t.readable&&!Rf(t))}function Tf(t){return t&&null!=t[ff]?t[ff]:"boolean"!=typeof(null==t?void 0:t.writable)?null:!Sf(t)&&(bf(t)&&t.writable&&!Ef(t))}function xf(t){return"boolean"==typeof t._closed&&"boolean"==typeof t._defaultKeepAlive&&"boolean"==typeof t._removedConnection&&"boolean"==typeof t._removedContLen}function Af(t){return"boolean"==typeof t._sent100&&xf(t)}var Of={isDestroyed:Sf,kIsDestroyed:uf,isDisturbed:function(t){var e;return!(!t||!(null!==(e=t[df])&&void 0!==e?e:t.readableDidRead||t.readableAborted))},kIsDisturbed:df,isErrored:function(t){var e,r,n,i,o,s,a,l,u,c;return!(!t||!(null!==(e=null!==(r=null!==(n=null!==(i=null!==(o=null!==(s=t[cf])&&void 0!==s?s:t.readableErrored)&&void 0!==o?o:t.writableErrored)&&void 0!==i?i:null===(a=t._readableState)||void 0===a?void 0:a.errorEmitted)&&void 0!==n?n:null===(l=t._writableState)||void 0===l?void 0:l.errorEmitted)&&void 0!==r?r:null===(u=t._readableState)||void 0===u?void 0:u.errored)&&void 0!==e?e:null===(c=t._writableState)||void 0===c?void 0:c.errored))},kIsErrored:cf,isReadable:kf,kIsReadable:hf,kIsClosedPromise:pf,kControllerErrorFunction:yf,kIsWritable:ff,isClosed:function(t){if(!mf(t))return null;if("boolean"==typeof t.closed)return t.closed;const e=t._writableState,r=t._readableState;return"boolean"==typeof(null==e?void 0:e.closed)||"boolean"==typeof(null==r?void 0:r.closed)?(null==e?void 0:e.closed)||(null==r?void 0:r.closed):"boolean"==typeof t._closed&&xf(t)?t._closed:null},isDuplexNodeStream:function(t){return!(!t||"function"!=typeof t.pipe||!t._readableState||"function"!=typeof t.on||"function"!=typeof t.write)},isFinished:function(t,e){return mf(t)?!!Sf(t)||(!1===(null==e?void 0:e.readable)||!kf(t))&&(!1===(null==e?void 0:e.writable)||!Tf(t)):null},isIterable:function(t,e){return null!=t&&(!0===e?"function"==typeof t[sf]:!1===e?"function"==typeof t[af]:"function"==typeof t[sf]||"function"==typeof t[af])},isReadableNodeStream:gf,isReadableStream:_f,isReadableEnded:function(t){if(!gf(t))return null;if(!0===t.readableEnded)return!0;const e=t._readableState;return!(!e||e.errored)&&("boolean"!=typeof(null==e?void 0:e.ended)?null:e.ended)},isReadableFinished:Rf,isReadableErrored:function(t){var e,r;return mf(t)?t.readableErrored?t.readableErrored:null!==(e=null===(r=t._readableState)||void 0===r?void 0:r.errored)&&void 0!==e?e:null:null},isNodeStream:mf,isWebStream:function(t){return _f(t)||vf(t)||wf(t)},isWritable:Tf,isWritableNodeStream:bf,isWritableStream:vf,isWritableEnded:Ef,isWritableFinished:function(t,e){if(!bf(t))return null;if(!0===t.writableFinished)return!0;const r=t._writableState;return(null==r||!r.errored)&&("boolean"!=typeof(null==r?void 0:r.finished)?null:!!(r.finished||!1===e&&!0===r.ended&&0===r.length))},isWritableErrored:function(t){var e,r;return mf(t)?t.writableErrored?t.writableErrored:null!==(e=null===(r=t._writableState)||void 0===r?void 0:r.errored)&&void 0!==e?e:null:null},isServerRequest:function(t){var e;return"boolean"==typeof t._consuming&&"boolean"==typeof t._dumped&&void 0===(null===(e=t.req)||void 0===e?void 0:e.upgradeOrConnect)},isServerResponse:Af,willEmitClose:function(t){if(!mf(t))return null;const e=t._writableState,r=t._readableState,n=e||r;return!n&&Af(t)||!!(n&&n.autoDestroy&&n.emitClose&&!1===n.closed)},isTransformStream:wf};const Lf=of,{AbortError:jf,codes:Mf}=Zc,{ERR_INVALID_ARG_TYPE:If,ERR_STREAM_PREMATURE_CLOSE:Pf}=Mf,{kEmptyObject:Df,once:Cf}=Qc,{validateAbortSignal:Nf,validateFunction:Ff,validateObject:Bf,validateBoolean:Wf}=$h,{Promise:Uf,PromisePrototypeThen:zf,SymbolDispose:$f}=jc,{isClosed:Hf,isReadable:Gf,isReadableNodeStream:qf,isReadableStream:Vf,isReadableFinished:Zf,isReadableErrored:Yf,isWritable:Kf,isWritableNodeStream:Qf,isWritableStream:Jf,isWritableFinished:Xf,isWritableErrored:td,isNodeStream:ed,willEmitClose:rd,kIsClosedPromise:nd}=Of;let id;const od=()=>{};function sd(t,e,r){var n,i;if(2===arguments.length?(r=e,e=Df):null==e?e=Df:Bf(e,"options"),Ff(r,"callback"),Nf(e.signal,"options.signal"),r=Cf(r),Vf(t)||Jf(t))return function(t,e,r){let n=!1,i=od;if(e.signal)if(i=()=>{n=!0,r.call(t,new jf(void 0,{cause:e.signal.reason}))},e.signal.aborted)Lf.nextTick(i);else{id=id||Qc.addAbortListener;const n=id(e.signal,i),o=r;r=Cf((...e)=>{n[$f](),o.apply(t,e)})}const o=(...e)=>{n||Lf.nextTick(()=>r.apply(t,e))};return zf(t[nd].promise,o,o),od}(t,e,r);if(!ed(t))throw new If("stream",["ReadableStream","WritableStream","Stream"],t);const o=null!==(n=e.readable)&&void 0!==n?n:qf(t),s=null!==(i=e.writable)&&void 0!==i?i:Qf(t),a=t._writableState,l=t._readableState,u=()=>{t.writable||f()};let c=rd(t)&&qf(t)===o&&Qf(t)===s,h=Xf(t,!1);const f=()=>{h=!0,t.destroyed&&(c=!1),(!c||t.readable&&!o)&&(o&&!d||r.call(t))};let d=Zf(t,!1);const p=()=>{d=!0,t.destroyed&&(c=!1),(!c||t.writable&&!s)&&(s&&!h||r.call(t))},y=e=>{r.call(t,e)};let g=Hf(t);const b=()=>{g=!0;const e=td(t)||Yf(t);return e&&"boolean"!=typeof e?r.call(t,e):o&&!d&&qf(t,!0)&&!Zf(t,!1)?r.call(t,new Pf):!s||h||Xf(t,!1)?void r.call(t):r.call(t,new Pf)},m=()=>{g=!0;const e=td(t)||Yf(t);if(e&&"boolean"!=typeof e)return r.call(t,e);r.call(t)},_=()=>{t.req.on("finish",f)};!function(t){return t.setHeader&&"function"==typeof t.abort}(t)?s&&!a&&(t.on("end",u),t.on("close",u)):(t.on("complete",f),c||t.on("abort",b),t.req?_():t.on("request",_)),c||"boolean"!=typeof t.aborted||t.on("aborted",b),t.on("end",p),t.on("finish",f),!1!==e.error&&t.on("error",y),t.on("close",b),g?Lf.nextTick(b):null!=a&&a.errorEmitted||null!=l&&l.errorEmitted?c||Lf.nextTick(m):(o||c&&!Gf(t)||!h&&!1!==Kf(t))&&(s||c&&!Kf(t)||!d&&!1!==Gf(t))?l&&t.req&&t.aborted&&Lf.nextTick(m):Lf.nextTick(m);const v=()=>{r=od,t.removeListener("aborted",b),t.removeListener("complete",f),t.removeListener("abort",b),t.removeListener("request",_),t.req&&t.req.removeListener("finish",f),t.removeListener("end",u),t.removeListener("close",u),t.removeListener("finish",f),t.removeListener("end",p),t.removeListener("error",y),t.removeListener("close",b)};if(e.signal&&!g){const n=()=>{const n=r;v(),n.call(t,new jf(void 0,{cause:e.signal.reason}))};if(e.signal.aborted)Lf.nextTick(n);else{id=id||Qc.addAbortListener;const i=id(e.signal,n),o=r;r=Cf((...e)=>{i[$f](),o.apply(t,e)})}}return v}Hh.exports=sd,Hh.exports.finished=function(t,e){var r;let n=!1;return null===e&&(e=Df),null!==(r=e)&&void 0!==r&&r.cleanup&&(Wf(e.cleanup,"cleanup"),n=e.cleanup),new Uf((r,i)=>{const o=sd(t,e,t=>{n&&o(),t?i(t):r()})})};var ad=Hh.exports;const ld=of,{aggregateTwoErrors:ud,codes:{ERR_MULTIPLE_CALLBACK:cd},AbortError:hd}=Zc,{Symbol:fd}=jc,{kIsDestroyed:dd,isDestroyed:pd,isFinished:yd,isServerRequest:gd}=Of,bd=fd("kDestroy"),md=fd("kConstruct");function _d(t,e,r){t&&(t.stack,e&&!e.errored&&(e.errored=t),r&&!r.errored&&(r.errored=t))}function vd(t,e,r){let n=!1;function i(e){if(n)return;n=!0;const i=t._readableState,o=t._writableState;_d(e,o,i),o&&(o.closed=!0),i&&(i.closed=!0),"function"==typeof r&&r(e),e?ld.nextTick(wd,t,e):ld.nextTick(Sd,t)}try{t._destroy(e||null,i)}catch(e){i(e)}}function wd(t,e){Ed(t,e),Sd(t)}function Sd(t){const e=t._readableState,r=t._writableState;r&&(r.closeEmitted=!0),e&&(e.closeEmitted=!0),(null!=r&&r.emitClose||null!=e&&e.emitClose)&&t.emit("close")}function Ed(t,e){const r=t._readableState,n=t._writableState;null!=n&&n.errorEmitted||null!=r&&r.errorEmitted||(n&&(n.errorEmitted=!0),r&&(r.errorEmitted=!0),t.emit("error",e))}function Rd(t,e,r){const n=t._readableState,i=t._writableState;if(null!=i&&i.destroyed||null!=n&&n.destroyed)return this;null!=n&&n.autoDestroy||null!=i&&i.autoDestroy?t.destroy(e):e&&(e.stack,i&&!i.errored&&(i.errored=e),n&&!n.errored&&(n.errored=e),r?ld.nextTick(Ed,t,e):Ed(t,e))}function kd(t){let e=!1;function r(r){if(e)return void Rd(t,null!=r?r:new cd);e=!0;const n=t._readableState,i=t._writableState,o=i||n;n&&(n.constructed=!0),i&&(i.constructed=!0),o.destroyed?t.emit(bd,r):r?Rd(t,r,!0):ld.nextTick(Td,t)}try{t._construct(t=>{ld.nextTick(r,t)})}catch(t){ld.nextTick(r,t)}}function Td(t){t.emit(md)}function xd(t){return(null==t?void 0:t.setHeader)&&"function"==typeof t.abort}function Ad(t){t.emit("close")}function Od(t,e){t.emit("error",e),ld.nextTick(Ad,t)}var Ld={construct:function(t,e){if("function"!=typeof t._construct)return;const r=t._readableState,n=t._writableState;r&&(r.constructed=!1),n&&(n.constructed=!1),t.once(md,e),t.listenerCount(md)>1||ld.nextTick(kd,t)},destroyer:function(t,e){t&&!pd(t)&&(e||yd(t)||(e=new hd),gd(t)?(t.socket=null,t.destroy(e)):xd(t)?t.abort():xd(t.req)?t.req.abort():"function"==typeof t.destroy?t.destroy(e):"function"==typeof t.close?t.close():e?ld.nextTick(Od,t,e):ld.nextTick(Ad,t),t.destroyed||(t[dd]=!0))},destroy:function(t,e){const r=this._readableState,n=this._writableState,i=n||r;return null!=n&&n.destroyed||null!=r&&r.destroyed?("function"==typeof e&&e(),this):(_d(t,n,r),n&&(n.destroyed=!0),r&&(r.destroyed=!0),i.constructed?vd(this,t,e):this.once(bd,function(r){vd(this,ud(r,t),e)}),this)},undestroy:function(){const t=this._readableState,e=this._writableState;t&&(t.constructed=!0,t.closed=!1,t.closeEmitted=!1,t.destroyed=!1,t.errored=null,t.errorEmitted=!1,t.reading=!1,t.ended=!1===t.readable,t.endEmitted=!1===t.readable),e&&(e.constructed=!0,e.destroyed=!1,e.closed=!1,e.closeEmitted=!1,e.errored=null,e.errorEmitted=!1,e.finalCalled=!1,e.prefinished=!1,e.ended=!1===e.writable,e.ending=!1===e.writable,e.finished=!1===e.writable)},errorOrDestroy:Rd};const{ArrayIsArray:jd,ObjectSetPrototypeOf:Md}=jc,{EventEmitter:Id}=yn;function Pd(t){Id.call(this,t)}function Dd(t,e,r){if("function"==typeof t.prependListener)return t.prependListener(e,r);t._events&&t._events[e]?jd(t._events[e])?t._events[e].unshift(r):t._events[e]=[r,t._events[e]]:t.on(e,r)}Md(Pd.prototype,Id.prototype),Md(Pd,Id),Pd.prototype.pipe=function(t,e){const r=this;function n(e){t.writable&&!1===t.write(e)&&r.pause&&r.pause()}function i(){r.readable&&r.resume&&r.resume()}r.on("data",n),t.on("drain",i),t._isStdio||e&&!1===e.end||(r.on("end",s),r.on("close",a));let o=!1;function s(){o||(o=!0,t.end())}function a(){o||(o=!0,"function"==typeof t.destroy&&t.destroy())}function l(t){u(),0===Id.listenerCount(this,"error")&&this.emit("error",t)}function u(){r.removeListener("data",n),t.removeListener("drain",i),r.removeListener("end",s),r.removeListener("close",a),r.removeListener("error",l),t.removeListener("error",l),r.removeListener("end",u),r.removeListener("close",u),t.removeListener("close",u)}return Dd(r,"error",l),Dd(t,"error",l),r.on("end",u),r.on("close",u),t.on("close",u),t.emit("pipe",r),t};var Cd={Stream:Pd,prependListener:Dd},Nd={exports:{}};!function(t){const{SymbolDispose:e}=jc,{AbortError:r,codes:n}=Zc,{isNodeStream:i,isWebStream:o,kControllerErrorFunction:s}=Of,a=ad,{ERR_INVALID_ARG_TYPE:l}=n;let u;t.exports.addAbortSignal=function(e,r){if(((t,e)=>{if("object"!=typeof t||!("aborted"in t))throw new l(e,"AbortSignal",t)})(e,"signal"),!i(r)&&!o(r))throw new l("stream",["ReadableStream","WritableStream","Stream"],r);return t.exports.addAbortSignalNoValidate(e,r)},t.exports.addAbortSignalNoValidate=function(t,n){if("object"!=typeof t||!("aborted"in t))return n;const o=i(n)?()=>{n.destroy(new r(void 0,{cause:t.reason}))}:()=>{n[s](new r(void 0,{cause:t.reason}))};if(t.aborted)o();else{u=u||Qc.addAbortListener;const r=u(t,o);a(n,r[e])}return n}}(Nd);var Fd=Nd.exports;const{StringPrototypeSlice:Bd,SymbolIterator:Wd,TypedArrayPrototypeSet:Ud,Uint8Array:zd}=jc,{Buffer:$d}=ca,{inspect:Hd}=Qc;var Gd=class{constructor(){this.head=null,this.tail=null,this.length=0}push(t){const e={data:t,next:null};this.length>0?this.tail.next=e:this.head=e,this.tail=e,++this.length}unshift(t){const e={data:t,next:this.head};0===this.length&&(this.tail=e),this.head=e,++this.length}shift(){if(0===this.length)return;const t=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,t}clear(){this.head=this.tail=null,this.length=0}join(t){if(0===this.length)return"";let e=this.head,r=""+e.data;for(;null!==(e=e.next);)r+=t+e.data;return r}concat(t){if(0===this.length)return $d.alloc(0);const e=$d.allocUnsafe(t>>>0);let r=this.head,n=0;for(;r;)Ud(e,r.data,n),n+=r.data.length,r=r.next;return e}consume(t,e){const r=this.head.data;if(t<r.length){const e=r.slice(0,t);return this.head.data=r.slice(t),e}return t===r.length?this.shift():e?this._getString(t):this._getBuffer(t)}first(){return this.head.data}*[Wd](){for(let t=this.head;t;t=t.next)yield t.data}_getString(t){let e="",r=this.head,n=0;do{const i=r.data;if(!(t>i.length)){t===i.length?(e+=i,++n,r.next?this.head=r.next:this.head=this.tail=null):(e+=Bd(i,0,t),this.head=r,r.data=Bd(i,t));break}e+=i,t-=i.length,++n}while(null!==(r=r.next));return this.length-=n,e}_getBuffer(t){const e=$d.allocUnsafe(t),r=t;let n=this.head,i=0;do{const o=n.data;if(!(t>o.length)){t===o.length?(Ud(e,o,r-t),++i,n.next?this.head=n.next:this.head=this.tail=null):(Ud(e,new zd(o.buffer,o.byteOffset,t),r-t),this.head=n,n.data=o.slice(t));break}Ud(e,o,r-t),t-=o.length,++i}while(null!==(n=n.next));return this.length-=i,e}[Symbol.for("nodejs.util.inspect.custom")](t,e){return Hd(this,{...e,depth:0,customInspect:!1})}};const{MathFloor:qd,NumberIsInteger:Vd}=jc,{validateInteger:Zd}=$h,{ERR_INVALID_ARG_VALUE:Yd}=Zc.codes;let Kd=16384,Qd=16;function Jd(t){return t?Qd:Kd}var Xd={getHighWaterMark:function(t,e,r,n){const i=function(t,e,r){return null!=t.highWaterMark?t.highWaterMark:e?t[r]:null}(e,n,r);if(null!=i){if(!Vd(i)||i<0){throw new Yd(n?`options.${r}`:"options.highWaterMark",i)}return qd(i)}return Jd(t.objectMode)},getDefaultHighWaterMark:Jd,setDefaultHighWaterMark:function(t,e){Zd(e,"value",0),t?Qd=e:Kd=e}},tp={},ep={exports:{}};
21
- /*! safe-buffer. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */
22
- !function(t,e){var r=ca,n=r.Buffer;function i(t,e){for(var r in t)e[r]=t[r]}function o(t,e,r){return n(t,e,r)}n.from&&n.alloc&&n.allocUnsafe&&n.allocUnsafeSlow?t.exports=r:(i(r,e),e.Buffer=o),o.prototype=Object.create(n.prototype),i(n,o),o.from=function(t,e,r){if("number"==typeof t)throw new TypeError("Argument must not be a number");return n(t,e,r)},o.alloc=function(t,e,r){if("number"!=typeof t)throw new TypeError("Argument must be a number");var i=n(t);return void 0!==e?"string"==typeof r?i.fill(e,r):i.fill(e):i.fill(0),i},o.allocUnsafe=function(t){if("number"!=typeof t)throw new TypeError("Argument must be a number");return n(t)},o.allocUnsafeSlow=function(t){if("number"!=typeof t)throw new TypeError("Argument must be a number");return r.SlowBuffer(t)}}(ep,ep.exports);var rp=ep.exports,np=rp.Buffer,ip=np.isEncoding||function(t){switch((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 op(t){var e;switch(this.encoding=function(t){var e=function(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}}(t);if("string"!=typeof e&&(np.isEncoding===ip||!ip(t)))throw new Error("Unknown encoding: "+t);return e||t}(t),this.encoding){case"utf16le":this.text=lp,this.end=up,e=4;break;case"utf8":this.fillLast=ap,e=4;break;case"base64":this.text=cp,this.end=hp,e=3;break;default:return this.write=fp,void(this.end=dp)}this.lastNeed=0,this.lastTotal=0,this.lastChar=np.allocUnsafe(e)}function sp(t){return t<=127?0:t>>5==6?2:t>>4==14?3:t>>3==30?4:t>>6==2?-1:-2}function ap(t){var e=this.lastTotal-this.lastNeed,r=function(t,e){if(128!=(192&e[0]))return t.lastNeed=0,"�";if(t.lastNeed>1&&e.length>1){if(128!=(192&e[1]))return t.lastNeed=1,"�";if(t.lastNeed>2&&e.length>2&&128!=(192&e[2]))return t.lastNeed=2,"�"}}(this,t);return void 0!==r?r:this.lastNeed<=t.length?(t.copy(this.lastChar,e,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(t.copy(this.lastChar,e,0,t.length),void(this.lastNeed-=t.length))}function lp(t,e){if((t.length-e)%2==0){var r=t.toString("utf16le",e);if(r){var n=r.charCodeAt(r.length-1);if(n>=55296&&n<=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 up(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 cp(t,e){var r=(t.length-e)%3;return 0===r?t.toString("base64",e):(this.lastNeed=3-r,this.lastTotal=3,1===r?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 hp(t){var e=t&&t.length?this.write(t):"";return this.lastNeed?e+this.lastChar.toString("base64",0,3-this.lastNeed):e}function fp(t){return t.toString(this.encoding)}function dp(t){return t&&t.length?this.write(t):""}tp.StringDecoder=op,op.prototype.write=function(t){if(0===t.length)return"";var e,r;if(this.lastNeed){if(void 0===(e=this.fillLast(t)))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||""},op.prototype.end=function(t){var e=t&&t.length?this.write(t):"";return this.lastNeed?e+"�":e},op.prototype.text=function(t,e){var r=function(t,e,r){var n=e.length-1;if(n<r)return 0;var i=sp(e[n]);if(i>=0)return i>0&&(t.lastNeed=i-1),i;if(--n<r||-2===i)return 0;if(i=sp(e[n]),i>=0)return i>0&&(t.lastNeed=i-2),i;if(--n<r||-2===i)return 0;if(i=sp(e[n]),i>=0)return i>0&&(2===i?i=0:t.lastNeed=i-3),i;return 0}(this,t,e);if(!this.lastNeed)return t.toString("utf8",e);this.lastTotal=r;var n=t.length-(r-this.lastNeed);return t.copy(this.lastChar,0,n),t.toString("utf8",e,n)},op.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};const pp=of,{PromisePrototypeThen:yp,SymbolAsyncIterator:gp,SymbolIterator:bp}=jc,{Buffer:mp}=ca,{ERR_INVALID_ARG_TYPE:_p,ERR_STREAM_NULL_VALUES:vp}=Zc.codes;var wp,Sp,Ep,Rp,kp,Tp,xp,Ap,Op=function(t,e,r){let n,i;if("string"==typeof e||e instanceof mp)return new t({objectMode:!0,...r,read(){this.push(e),this.push(null)}});if(e&&e[gp])i=!0,n=e[gp]();else{if(!e||!e[bp])throw new _p("iterable",["Iterable"],e);i=!1,n=e[bp]()}const o=new t({objectMode:!0,highWaterMark:1,...r});let s=!1;return o._read=function(){s||(s=!0,async function(){for(;;){try{const{value:t,done:e}=i?await n.next():n.next();if(e)o.push(null);else{const e=t&&"function"==typeof t.then?await t:t;if(null===e)throw s=!1,new vp;if(o.push(e))continue;s=!1}}catch(t){o.destroy(t)}break}}())},o._destroy=function(t,e){yp(async function(t){const e=null!=t,r="function"==typeof n.throw;if(e&&r){const{value:e,done:r}=await n.throw(t);if(await e,r)return}if("function"==typeof n.return){const{value:t}=await n.return();await t}}(t),()=>pp.nextTick(e,t),r=>pp.nextTick(e,r||t))},o};function Lp(){if(Sp)return wp;Sp=1;const t=of,{ArrayPrototypeIndexOf:e,NumberIsInteger:r,NumberIsNaN:n,NumberParseInt:i,ObjectDefineProperties:o,ObjectKeys:s,ObjectSetPrototypeOf:a,Promise:l,SafeSet:u,SymbolAsyncDispose:c,SymbolAsyncIterator:h,Symbol:f}=jc;wp=H,H.ReadableState=$;const{EventEmitter:d}=yn,{Stream:p,prependListener:y}=Cd,{Buffer:g}=ca,{addAbortSignal:b}=Fd,m=ad;let _=Qc.debuglog("stream",t=>{_=t});const v=Gd,w=Ld,{getHighWaterMark:S,getDefaultHighWaterMark:E}=Xd,{aggregateTwoErrors:R,codes:{ERR_INVALID_ARG_TYPE:k,ERR_METHOD_NOT_IMPLEMENTED:T,ERR_OUT_OF_RANGE:x,ERR_STREAM_PUSH_AFTER_EOF:A,ERR_STREAM_UNSHIFT_AFTER_END_EVENT:O},AbortError:L}=Zc,{validateObject:j}=$h,M=f("kPaused"),{StringDecoder:I}=tp,P=Op;a(H.prototype,p.prototype),a(H,p);const D=()=>{},{errorOrDestroy:C}=w,N=1,F=16,B=32,W=2048,U=4096;function z(t){return{enumerable:!1,get(){return 0!==(this.state&t)},set(e){e?this.state|=t:this.state&=~t}}}function $(t,e,r){"boolean"!=typeof r&&(r=e instanceof Ip()),this.state=W|U|F|B,t&&t.objectMode&&(this.state|=N),r&&t&&t.readableObjectMode&&(this.state|=N),this.highWaterMark=t?S(this,t,"readableHighWaterMark",r):E(!1),this.buffer=new v,this.length=0,this.pipes=[],this.flowing=null,this[M]=null,t&&!1===t.emitClose&&(this.state&=~W),t&&!1===t.autoDestroy&&(this.state&=~U),this.errored=null,this.defaultEncoding=t&&t.defaultEncoding||"utf8",this.awaitDrainWriters=null,this.decoder=null,this.encoding=null,t&&t.encoding&&(this.decoder=new I(t.encoding),this.encoding=t.encoding)}function H(t){if(!(this instanceof H))return new H(t);const e=this instanceof Ip();this._readableState=new $(t,this,e),t&&("function"==typeof t.read&&(this._read=t.read),"function"==typeof t.destroy&&(this._destroy=t.destroy),"function"==typeof t.construct&&(this._construct=t.construct),t.signal&&!e&&b(t.signal,this)),p.call(this,t),w.construct(this,()=>{this._readableState.needReadable&&K(this,this._readableState)})}function G(t,e,r,n){_("readableAddChunk",e);const i=t._readableState;let o;if(0===(i.state&N)&&("string"==typeof e?(r=r||i.defaultEncoding,i.encoding!==r&&(n&&i.encoding?e=g.from(e,r).toString(i.encoding):(e=g.from(e,r),r=""))):e instanceof g?r="":p._isUint8Array(e)?(e=p._uint8ArrayToBuffer(e),r=""):null!=e&&(o=new k("chunk",["string","Buffer","Uint8Array"],e))),o)C(t,o);else if(null===e)i.state&=-9,function(t,e){if(_("onEofChunk"),e.ended)return;if(e.decoder){const t=e.decoder.end();t&&t.length&&(e.buffer.push(t),e.length+=e.objectMode?1:t.length)}e.ended=!0,e.sync?Z(t):(e.needReadable=!1,e.emittedReadable=!0,Y(t))}(t,i);else if(0!==(i.state&N)||e&&e.length>0)if(n)if(4&i.state)C(t,new O);else{if(i.destroyed||i.errored)return!1;q(t,i,e,!0)}else if(i.ended)C(t,new A);else{if(i.destroyed||i.errored)return!1;i.state&=-9,i.decoder&&!r?(e=i.decoder.write(e),i.objectMode||0!==e.length?q(t,i,e,!1):K(t,i)):q(t,i,e,!1)}else n||(i.state&=-9,K(t,i));return!i.ended&&(i.length<i.highWaterMark||0===i.length)}function q(t,e,r,n){e.flowing&&0===e.length&&!e.sync&&t.listenerCount("data")>0?(65536&e.state?e.awaitDrainWriters.clear():e.awaitDrainWriters=null,e.dataEmitted=!0,t.emit("data",r)):(e.length+=e.objectMode?1:r.length,n?e.buffer.unshift(r):e.buffer.push(r),64&e.state&&Z(t)),K(t,e)}o($.prototype,{objectMode:z(N),ended:z(2),endEmitted:z(4),reading:z(8),constructed:z(F),sync:z(B),needReadable:z(64),emittedReadable:z(128),readableListening:z(256),resumeScheduled:z(512),errorEmitted:z(1024),emitClose:z(W),autoDestroy:z(U),destroyed:z(8192),closed:z(16384),closeEmitted:z(32768),multiAwaitDrain:z(65536),readingMore:z(1<<17),dataEmitted:z(1<<18)}),H.prototype.destroy=w.destroy,H.prototype._undestroy=w.undestroy,H.prototype._destroy=function(t,e){e(t)},H.prototype[d.captureRejectionSymbol]=function(t){this.destroy(t)},H.prototype[c]=function(){let t;return this.destroyed||(t=this.readableEnded?null:new L,this.destroy(t)),new l((e,r)=>m(this,n=>n&&n!==t?r(n):e(null)))},H.prototype.push=function(t,e){return G(this,t,e,!1)},H.prototype.unshift=function(t,e){return G(this,t,e,!0)},H.prototype.isPaused=function(){const t=this._readableState;return!0===t[M]||!1===t.flowing},H.prototype.setEncoding=function(t){const e=new I(t);this._readableState.decoder=e,this._readableState.encoding=this._readableState.decoder.encoding;const r=this._readableState.buffer;let n="";for(const t of r)n+=e.write(t);return r.clear(),""!==n&&r.push(n),this._readableState.length=n.length,this};function V(t,e){return t<=0||0===e.length&&e.ended?0:0!==(e.state&N)?1:n(t)?e.flowing&&e.length?e.buffer.first().length:e.length:t<=e.length?t:e.ended?e.length:0}function Z(e){const r=e._readableState;_("emitReadable",r.needReadable,r.emittedReadable),r.needReadable=!1,r.emittedReadable||(_("emitReadable",r.flowing),r.emittedReadable=!0,t.nextTick(Y,e))}function Y(t){const e=t._readableState;_("emitReadable_",e.destroyed,e.length,e.ended),e.destroyed||e.errored||!e.length&&!e.ended||(t.emit("readable"),e.emittedReadable=!1),e.needReadable=!e.flowing&&!e.ended&&e.length<=e.highWaterMark,et(t)}function K(e,r){!r.readingMore&&r.constructed&&(r.readingMore=!0,t.nextTick(Q,e,r))}function Q(t,e){for(;!e.reading&&!e.ended&&(e.length<e.highWaterMark||e.flowing&&0===e.length);){const r=e.length;if(_("maybeReadMore read 0"),t.read(0),r===e.length)break}e.readingMore=!1}function J(t){const e=t._readableState;e.readableListening=t.listenerCount("readable")>0,e.resumeScheduled&&!1===e[M]?e.flowing=!0:t.listenerCount("data")>0?t.resume():e.readableListening||(e.flowing=null)}function X(t){_("readable nexttick read 0"),t.read(0)}function tt(t,e){_("resume",e.reading),e.reading||t.read(0),e.resumeScheduled=!1,t.emit("resume"),et(t),e.flowing&&!e.reading&&t.read(0)}function et(t){const e=t._readableState;for(_("flow",e.flowing);e.flowing&&null!==t.read(););}function rt(t,e){"function"!=typeof t.read&&(t=H.wrap(t,{objectMode:!0}));const r=async function*(t,e){let r,n=D;function i(e){this===t?(n(),n=D):n=e}t.on("readable",i);const o=m(t,{writable:!1},t=>{r=t?R(r,t):null,n(),n=D});try{for(;;){const e=t.destroyed?null:t.read();if(null!==e)yield e;else{if(r)throw r;if(null===r)return;await new l(i)}}}catch(t){throw r=R(r,t),r}finally{!r&&!1===(null==e?void 0:e.destroyOnReturn)||void 0!==r&&!t._readableState.autoDestroy?(t.off("readable",i),o()):w.destroyer(t,null)}}(t,e);return r.stream=t,r}function nt(t,e){if(0===e.length)return null;let r;return e.objectMode?r=e.buffer.shift():!t||t>=e.length?(r=e.decoder?e.buffer.join(""):1===e.buffer.length?e.buffer.first():e.buffer.concat(e.length),e.buffer.clear()):r=e.buffer.consume(t,e.decoder),r}function it(e){const r=e._readableState;_("endReadable",r.endEmitted),r.endEmitted||(r.ended=!0,t.nextTick(ot,r,e))}function ot(e,r){if(_("endReadableNT",e.endEmitted,e.length),!e.errored&&!e.closeEmitted&&!e.endEmitted&&0===e.length)if(e.endEmitted=!0,r.emit("end"),r.writable&&!1===r.allowHalfOpen)t.nextTick(st,r);else if(e.autoDestroy){const t=r._writableState;(!t||t.autoDestroy&&(t.finished||!1===t.writable))&&r.destroy()}}function st(t){t.writable&&!t.writableEnded&&!t.destroyed&&t.end()}let at;function lt(){return void 0===at&&(at={}),at}return H.prototype.read=function(t){_("read",t),void 0===t?t=NaN:r(t)||(t=i(t,10));const e=this._readableState,n=t;if(t>e.highWaterMark&&(e.highWaterMark=function(t){if(t>1073741824)throw new x("size","<= 1GiB",t);return t--,t|=t>>>1,t|=t>>>2,t|=t>>>4,t|=t>>>8,t|=t>>>16,++t}(t)),0!==t&&(e.state&=-129),0===t&&e.needReadable&&((0!==e.highWaterMark?e.length>=e.highWaterMark:e.length>0)||e.ended))return _("read: emitReadable",e.length,e.ended),0===e.length&&e.ended?it(this):Z(this),null;if(0===(t=V(t,e))&&e.ended)return 0===e.length&&it(this),null;let o,s=!!(64&e.state);if(_("need readable",s),(0===e.length||e.length-t<e.highWaterMark)&&(s=!0,_("length less than watermark",s)),e.ended||e.reading||e.destroyed||e.errored||!e.constructed)s=!1,_("reading, ended or constructing",s);else if(s){_("do read"),e.state|=8|B,0===e.length&&(e.state|=64);try{this._read(e.highWaterMark)}catch(t){C(this,t)}e.state&=~B,e.reading||(t=V(n,e))}return o=t>0?nt(t,e):null,null===o?(e.needReadable=e.length<=e.highWaterMark,t=0):(e.length-=t,e.multiAwaitDrain?e.awaitDrainWriters.clear():e.awaitDrainWriters=null),0===e.length&&(e.ended||(e.needReadable=!0),n!==t&&e.ended&&it(this)),null===o||e.errorEmitted||e.closeEmitted||(e.dataEmitted=!0,this.emit("data",o)),o},H.prototype._read=function(t){throw new T("_read()")},H.prototype.pipe=function(e,r){const n=this,i=this._readableState;1===i.pipes.length&&(i.multiAwaitDrain||(i.multiAwaitDrain=!0,i.awaitDrainWriters=new u(i.awaitDrainWriters?[i.awaitDrainWriters]:[]))),i.pipes.push(e),_("pipe count=%d opts=%j",i.pipes.length,r);const o=(!r||!1!==r.end)&&e!==t.stdout&&e!==t.stderr?a:b;function s(t,r){_("onunpipe"),t===n&&r&&!1===r.hasUnpiped&&(r.hasUnpiped=!0,function(){_("cleanup"),e.removeListener("close",p),e.removeListener("finish",g),l&&e.removeListener("drain",l);e.removeListener("error",d),e.removeListener("unpipe",s),n.removeListener("end",a),n.removeListener("end",b),n.removeListener("data",f),c=!0,l&&i.awaitDrainWriters&&(!e._writableState||e._writableState.needDrain)&&l()}())}function a(){_("onend"),e.end()}let l;i.endEmitted?t.nextTick(o):n.once("end",o),e.on("unpipe",s);let c=!1;function h(){c||(1===i.pipes.length&&i.pipes[0]===e?(_("false write response, pause",0),i.awaitDrainWriters=e,i.multiAwaitDrain=!1):i.pipes.length>1&&i.pipes.includes(e)&&(_("false write response, pause",i.awaitDrainWriters.size),i.awaitDrainWriters.add(e)),n.pause()),l||(l=function(t,e){return function(){const r=t._readableState;r.awaitDrainWriters===e?(_("pipeOnDrain",1),r.awaitDrainWriters=null):r.multiAwaitDrain&&(_("pipeOnDrain",r.awaitDrainWriters.size),r.awaitDrainWriters.delete(e)),r.awaitDrainWriters&&0!==r.awaitDrainWriters.size||!t.listenerCount("data")||t.resume()}}(n,e),e.on("drain",l))}function f(t){_("ondata");const r=e.write(t);_("dest.write",r),!1===r&&h()}function d(t){if(_("onerror",t),b(),e.removeListener("error",d),0===e.listenerCount("error")){const r=e._writableState||e._readableState;r&&!r.errorEmitted?C(e,t):e.emit("error",t)}}function p(){e.removeListener("finish",g),b()}function g(){_("onfinish"),e.removeListener("close",p),b()}function b(){_("unpipe"),n.unpipe(e)}return n.on("data",f),y(e,"error",d),e.once("close",p),e.once("finish",g),e.emit("pipe",n),!0===e.writableNeedDrain?h():i.flowing||(_("pipe resume"),n.resume()),e},H.prototype.unpipe=function(t){const r=this._readableState;if(0===r.pipes.length)return this;if(!t){const t=r.pipes;r.pipes=[],this.pause();for(let e=0;e<t.length;e++)t[e].emit("unpipe",this,{hasUnpiped:!1});return this}const n=e(r.pipes,t);return-1===n||(r.pipes.splice(n,1),0===r.pipes.length&&this.pause(),t.emit("unpipe",this,{hasUnpiped:!1})),this},H.prototype.on=function(e,r){const n=p.prototype.on.call(this,e,r),i=this._readableState;return"data"===e?(i.readableListening=this.listenerCount("readable")>0,!1!==i.flowing&&this.resume()):"readable"===e&&(i.endEmitted||i.readableListening||(i.readableListening=i.needReadable=!0,i.flowing=!1,i.emittedReadable=!1,_("on readable",i.length,i.reading),i.length?Z(this):i.reading||t.nextTick(X,this))),n},H.prototype.addListener=H.prototype.on,H.prototype.removeListener=function(e,r){const n=p.prototype.removeListener.call(this,e,r);return"readable"===e&&t.nextTick(J,this),n},H.prototype.off=H.prototype.removeListener,H.prototype.removeAllListeners=function(e){const r=p.prototype.removeAllListeners.apply(this,arguments);return"readable"!==e&&void 0!==e||t.nextTick(J,this),r},H.prototype.resume=function(){const e=this._readableState;return e.flowing||(_("resume"),e.flowing=!e.readableListening,function(e,r){r.resumeScheduled||(r.resumeScheduled=!0,t.nextTick(tt,e,r))}(this,e)),e[M]=!1,this},H.prototype.pause=function(){return _("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(_("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState[M]=!0,this},H.prototype.wrap=function(t){let e=!1;t.on("data",r=>{!this.push(r)&&t.pause&&(e=!0,t.pause())}),t.on("end",()=>{this.push(null)}),t.on("error",t=>{C(this,t)}),t.on("close",()=>{this.destroy()}),t.on("destroy",()=>{this.destroy()}),this._read=()=>{e&&t.resume&&(e=!1,t.resume())};const r=s(t);for(let e=1;e<r.length;e++){const n=r[e];void 0===this[n]&&"function"==typeof t[n]&&(this[n]=t[n].bind(t))}return this},H.prototype[h]=function(){return rt(this)},H.prototype.iterator=function(t){return void 0!==t&&j(t,"options"),rt(this,t)},o(H.prototype,{readable:{__proto__:null,get(){const t=this._readableState;return!(!t||!1===t.readable||t.destroyed||t.errorEmitted||t.endEmitted)},set(t){this._readableState&&(this._readableState.readable=!!t)}},readableDidRead:{__proto__:null,enumerable:!1,get:function(){return this._readableState.dataEmitted}},readableAborted:{__proto__:null,enumerable:!1,get:function(){return!(!1===this._readableState.readable||!this._readableState.destroyed&&!this._readableState.errored||this._readableState.endEmitted)}},readableHighWaterMark:{__proto__:null,enumerable:!1,get:function(){return this._readableState.highWaterMark}},readableBuffer:{__proto__:null,enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}},readableFlowing:{__proto__:null,enumerable:!1,get:function(){return this._readableState.flowing},set:function(t){this._readableState&&(this._readableState.flowing=t)}},readableLength:{__proto__:null,enumerable:!1,get(){return this._readableState.length}},readableObjectMode:{__proto__:null,enumerable:!1,get(){return!!this._readableState&&this._readableState.objectMode}},readableEncoding:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.encoding:null}},errored:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.errored:null}},closed:{__proto__:null,get(){return!!this._readableState&&this._readableState.closed}},destroyed:{__proto__:null,enumerable:!1,get(){return!!this._readableState&&this._readableState.destroyed},set(t){this._readableState&&(this._readableState.destroyed=t)}},readableEnded:{__proto__:null,enumerable:!1,get(){return!!this._readableState&&this._readableState.endEmitted}}}),o($.prototype,{pipesCount:{__proto__:null,get(){return this.pipes.length}},paused:{__proto__:null,get(){return!1!==this[M]},set(t){this[M]=!!t}}}),H._fromList=nt,H.from=function(t,e){return P(H,t,e)},H.fromWeb=function(t,e){return lt().newStreamReadableFromReadableStream(t,e)},H.toWeb=function(t,e){return lt().newReadableStreamFromStreamReadable(t,e)},H.wrap=function(t,e){var r,n;return new H({objectMode:null===(r=null!==(n=t.readableObjectMode)&&void 0!==n?n:t.objectMode)||void 0===r||r,...e,destroy(e,r){w.destroyer(t,e),r(e)}}).wrap(t)},wp}function jp(){if(Rp)return Ep;Rp=1;const t=of,{ArrayPrototypeSlice:e,Error:r,FunctionPrototypeSymbolHasInstance:n,ObjectDefineProperty:i,ObjectDefineProperties:o,ObjectSetPrototypeOf:s,StringPrototypeToLowerCase:a,Symbol:l,SymbolHasInstance:u}=jc;Ep=j,j.WritableState=O;const{EventEmitter:c}=yn,h=Cd.Stream,{Buffer:f}=ca,d=Ld,{addAbortSignal:p}=Fd,{getHighWaterMark:y,getDefaultHighWaterMark:g}=Xd,{ERR_INVALID_ARG_TYPE:b,ERR_METHOD_NOT_IMPLEMENTED:m,ERR_MULTIPLE_CALLBACK:_,ERR_STREAM_CANNOT_PIPE:v,ERR_STREAM_DESTROYED:w,ERR_STREAM_ALREADY_FINISHED:S,ERR_STREAM_NULL_VALUES:E,ERR_STREAM_WRITE_AFTER_END:R,ERR_UNKNOWN_ENCODING:k}=Zc.codes,{errorOrDestroy:T}=d;function x(){}s(j.prototype,h.prototype),s(j,h);const A=l("kOnFinished");function O(t,e,r){"boolean"!=typeof r&&(r=e instanceof Ip()),this.objectMode=!(!t||!t.objectMode),r&&(this.objectMode=this.objectMode||!(!t||!t.writableObjectMode)),this.highWaterMark=t?y(this,t,"writableHighWaterMark",r):g(!1),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;const n=!(!t||!1!==t.decodeStrings);this.decodeStrings=!n,this.defaultEncoding=t&&t.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=D.bind(void 0,e),this.writecb=null,this.writelen=0,this.afterWriteTickInfo=null,L(this),this.pendingcb=0,this.constructed=!0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=!t||!1!==t.emitClose,this.autoDestroy=!t||!1!==t.autoDestroy,this.errored=null,this.closed=!1,this.closeEmitted=!1,this[A]=[]}function L(t){t.buffered=[],t.bufferedIndex=0,t.allBuffers=!0,t.allNoop=!0}function j(t){const e=this instanceof Ip();if(!e&&!n(j,this))return new j(t);this._writableState=new O(t,this,e),t&&("function"==typeof t.write&&(this._write=t.write),"function"==typeof t.writev&&(this._writev=t.writev),"function"==typeof t.destroy&&(this._destroy=t.destroy),"function"==typeof t.final&&(this._final=t.final),"function"==typeof t.construct&&(this._construct=t.construct),t.signal&&p(t.signal,this)),h.call(this,t),d.construct(this,()=>{const t=this._writableState;t.writing||B(this,t),z(this,t)})}function M(e,r,n,i){const o=e._writableState;if("function"==typeof n)i=n,n=o.defaultEncoding;else{if(n){if("buffer"!==n&&!f.isEncoding(n))throw new k(n)}else n=o.defaultEncoding;"function"!=typeof i&&(i=x)}if(null===r)throw new E;if(!o.objectMode)if("string"==typeof r)!1!==o.decodeStrings&&(r=f.from(r,n),n="buffer");else if(r instanceof f)n="buffer";else{if(!h._isUint8Array(r))throw new b("chunk",["string","Buffer","Uint8Array"],r);r=h._uint8ArrayToBuffer(r),n="buffer"}let s;return o.ending?s=new R:o.destroyed&&(s=new w("write")),s?(t.nextTick(i,s),T(e,s,!0),s):(o.pendingcb++,function(t,e,r,n,i){const o=e.objectMode?1:r.length;e.length+=o;const s=e.length<e.highWaterMark;s||(e.needDrain=!0);e.writing||e.corked||e.errored||!e.constructed?(e.buffered.push({chunk:r,encoding:n,callback:i}),e.allBuffers&&"buffer"!==n&&(e.allBuffers=!1),e.allNoop&&i!==x&&(e.allNoop=!1)):(e.writelen=o,e.writecb=i,e.writing=!0,e.sync=!0,t._write(r,n,e.onwrite),e.sync=!1);return s&&!e.errored&&!e.destroyed}(e,o,r,n,i))}function I(t,e,r,n,i,o,s){e.writelen=n,e.writecb=s,e.writing=!0,e.sync=!0,e.destroyed?e.onwrite(new w("write")):r?t._writev(i,e.onwrite):t._write(i,o,e.onwrite),e.sync=!1}function P(t,e,r,n){--e.pendingcb,n(r),F(e),T(t,r)}function D(e,r){const n=e._writableState,i=n.sync,o=n.writecb;"function"==typeof o?(n.writing=!1,n.writecb=null,n.length-=n.writelen,n.writelen=0,r?(r.stack,n.errored||(n.errored=r),e._readableState&&!e._readableState.errored&&(e._readableState.errored=r),i?t.nextTick(P,e,n,r,o):P(e,n,r,o)):(n.buffered.length>n.bufferedIndex&&B(e,n),i?null!==n.afterWriteTickInfo&&n.afterWriteTickInfo.cb===o?n.afterWriteTickInfo.count++:(n.afterWriteTickInfo={count:1,cb:o,stream:e,state:n},t.nextTick(C,n.afterWriteTickInfo)):N(e,n,1,o))):T(e,new _)}function C({stream:t,state:e,count:r,cb:n}){return e.afterWriteTickInfo=null,N(t,e,r,n)}function N(t,e,r,n){for(!e.ending&&!t.destroyed&&0===e.length&&e.needDrain&&(e.needDrain=!1,t.emit("drain"));r-- >0;)e.pendingcb--,n();e.destroyed&&F(e),z(t,e)}function F(t){if(t.writing)return;for(let r=t.bufferedIndex;r<t.buffered.length;++r){var e;const{chunk:n,callback:i}=t.buffered[r],o=t.objectMode?1:n.length;t.length-=o,i(null!==(e=t.errored)&&void 0!==e?e:new w("write"))}const r=t[A].splice(0);for(let e=0;e<r.length;e++){var n;r[e](null!==(n=t.errored)&&void 0!==n?n:new w("end"))}L(t)}function B(t,r){if(r.corked||r.bufferProcessing||r.destroyed||!r.constructed)return;const{buffered:n,bufferedIndex:i,objectMode:o}=r,s=n.length-i;if(!s)return;let a=i;if(r.bufferProcessing=!0,s>1&&t._writev){r.pendingcb-=s-1;const i=r.allNoop?x:t=>{for(let e=a;e<n.length;++e)n[e].callback(t)},o=r.allNoop&&0===a?n:e(n,a);o.allBuffers=r.allBuffers,I(t,r,!0,r.length,o,"",i),L(r)}else{do{const{chunk:e,encoding:i,callback:s}=n[a];n[a++]=null;I(t,r,!1,o?1:e.length,e,i,s)}while(a<n.length&&!r.writing);a===n.length?L(r):a>256?(n.splice(0,a),r.bufferedIndex=0):r.bufferedIndex=a}r.bufferProcessing=!1}function W(t){return t.ending&&!t.destroyed&&t.constructed&&0===t.length&&!t.errored&&0===t.buffered.length&&!t.finished&&!t.writing&&!t.errorEmitted&&!t.closeEmitted}function U(e,r){r.prefinished||r.finalCalled||("function"!=typeof e._final||r.destroyed?(r.prefinished=!0,e.emit("prefinish")):(r.finalCalled=!0,function(e,r){let n=!1;function i(i){if(n)T(e,null!=i?i:_());else if(n=!0,r.pendingcb--,i){const t=r[A].splice(0);for(let e=0;e<t.length;e++)t[e](i);T(e,i,r.sync)}else W(r)&&(r.prefinished=!0,e.emit("prefinish"),r.pendingcb++,t.nextTick($,e,r))}r.sync=!0,r.pendingcb++;try{e._final(i)}catch(t){i(t)}r.sync=!1}(e,r)))}function z(e,r,n){W(r)&&(U(e,r),0===r.pendingcb&&(n?(r.pendingcb++,t.nextTick((t,e)=>{W(e)?$(t,e):e.pendingcb--},e,r)):W(r)&&(r.pendingcb++,$(e,r))))}function $(t,e){e.pendingcb--,e.finished=!0;const r=e[A].splice(0);for(let t=0;t<r.length;t++)r[t]();if(t.emit("finish"),e.autoDestroy){const e=t._readableState;(!e||e.autoDestroy&&(e.endEmitted||!1===e.readable))&&t.destroy()}}O.prototype.getBuffer=function(){return e(this.buffered,this.bufferedIndex)},i(O.prototype,"bufferedRequestCount",{__proto__:null,get(){return this.buffered.length-this.bufferedIndex}}),i(j,u,{__proto__:null,value:function(t){return!!n(this,t)||this===j&&(t&&t._writableState instanceof O)}}),j.prototype.pipe=function(){T(this,new v)},j.prototype.write=function(t,e,r){return!0===M(this,t,e,r)},j.prototype.cork=function(){this._writableState.corked++},j.prototype.uncork=function(){const t=this._writableState;t.corked&&(t.corked--,t.writing||B(this,t))},j.prototype.setDefaultEncoding=function(t){if("string"==typeof t&&(t=a(t)),!f.isEncoding(t))throw new k(t);return this._writableState.defaultEncoding=t,this},j.prototype._write=function(t,e,r){if(!this._writev)throw new m("_write()");this._writev([{chunk:t,encoding:e}],r)},j.prototype._writev=null,j.prototype.end=function(e,n,i){const o=this._writableState;let s;if("function"==typeof e?(i=e,e=null,n=null):"function"==typeof n&&(i=n,n=null),null!=e){const t=M(this,e,n);t instanceof r&&(s=t)}return o.corked&&(o.corked=1,this.uncork()),s||(o.errored||o.ending?o.finished?s=new S("end"):o.destroyed&&(s=new w("end")):(o.ending=!0,z(this,o,!0),o.ended=!0)),"function"==typeof i&&(s||o.finished?t.nextTick(i,s):o[A].push(i)),this},o(j.prototype,{closed:{__proto__:null,get(){return!!this._writableState&&this._writableState.closed}},destroyed:{__proto__:null,get(){return!!this._writableState&&this._writableState.destroyed},set(t){this._writableState&&(this._writableState.destroyed=t)}},writable:{__proto__:null,get(){const t=this._writableState;return!(!t||!1===t.writable||t.destroyed||t.errored||t.ending||t.ended)},set(t){this._writableState&&(this._writableState.writable=!!t)}},writableFinished:{__proto__:null,get(){return!!this._writableState&&this._writableState.finished}},writableObjectMode:{__proto__:null,get(){return!!this._writableState&&this._writableState.objectMode}},writableBuffer:{__proto__:null,get(){return this._writableState&&this._writableState.getBuffer()}},writableEnded:{__proto__:null,get(){return!!this._writableState&&this._writableState.ending}},writableNeedDrain:{__proto__:null,get(){const t=this._writableState;return!!t&&(!t.destroyed&&!t.ending&&t.needDrain)}},writableHighWaterMark:{__proto__:null,get(){return this._writableState&&this._writableState.highWaterMark}},writableCorked:{__proto__:null,get(){return this._writableState?this._writableState.corked:0}},writableLength:{__proto__:null,get(){return this._writableState&&this._writableState.length}},errored:{__proto__:null,enumerable:!1,get(){return this._writableState?this._writableState.errored:null}},writableAborted:{__proto__:null,enumerable:!1,get:function(){return!(!1===this._writableState.writable||!this._writableState.destroyed&&!this._writableState.errored||this._writableState.finished)}}});const H=d.destroy;let G;function q(){return void 0===G&&(G={}),G}return j.prototype.destroy=function(e,r){const n=this._writableState;return!n.destroyed&&(n.bufferedIndex<n.buffered.length||n[A].length)&&t.nextTick(F,n),H.call(this,e,r),this},j.prototype._undestroy=d.undestroy,j.prototype._destroy=function(t,e){e(t)},j.prototype[c.captureRejectionSymbol]=function(t){this.destroy(t)},j.fromWeb=function(t,e){return q().newStreamWritableFromWritableStream(t,e)},j.toWeb=function(t){return q().newWritableStreamFromStreamWritable(t)},Ep}function Mp(){if(Tp)return kp;Tp=1;const t=of,e=ca,{isReadable:r,isWritable:n,isIterable:i,isNodeStream:o,isReadableNodeStream:s,isWritableNodeStream:a,isDuplexNodeStream:l,isReadableStream:u,isWritableStream:c}=Of,h=ad,{AbortError:f,codes:{ERR_INVALID_ARG_TYPE:d,ERR_INVALID_RETURN_VALUE:p}}=Zc,{destroyer:y}=Ld,g=Ip(),b=Lp(),m=jp(),{createDeferredPromise:_}=Qc,v=Op,w=globalThis.Blob||e.Blob,S=void 0!==w?function(t){return t instanceof w}:function(t){return!1},E=globalThis.AbortController||Kc().AbortController,{FunctionPrototypeCall:R}=jc;class k extends g{constructor(t){super(t),!1===(null==t?void 0:t.readable)&&(this._readableState.readable=!1,this._readableState.ended=!0,this._readableState.endEmitted=!0),!1===(null==t?void 0:t.writable)&&(this._writableState.writable=!1,this._writableState.ending=!0,this._writableState.ended=!0,this._writableState.finished=!0)}}function T(t){const e=t.readable&&"function"!=typeof t.readable.read?b.wrap(t.readable):t.readable,i=t.writable;let o,s,a,l,u,c=!!r(e),d=!!n(i);function p(t){const e=l;l=null,e?e(t):t&&u.destroy(t)}return u=new k({readableObjectMode:!(null==e||!e.readableObjectMode),writableObjectMode:!(null==i||!i.writableObjectMode),readable:c,writable:d}),d&&(h(i,t=>{d=!1,t&&y(e,t),p(t)}),u._write=function(t,e,r){i.write(t,e)?r():o=r},u._final=function(t){i.end(),s=t},i.on("drain",function(){if(o){const t=o;o=null,t()}}),i.on("finish",function(){if(s){const t=s;s=null,t()}})),c&&(h(e,t=>{c=!1,t&&y(e,t),p(t)}),e.on("readable",function(){if(a){const t=a;a=null,t()}}),e.on("end",function(){u.push(null)}),u._read=function(){for(;;){const t=e.read();if(null===t)return void(a=u._read);if(!u.push(t))return}}),u._destroy=function(t,r){t||null===l||(t=new f),a=null,o=null,s=null,null===l?r(t):(l=r,y(i,t),y(e,t))},u}return kp=function e(r,n){if(l(r))return r;if(s(r))return T({readable:r});if(a(r))return T({writable:r});if(o(r))return T({writable:!1,readable:!1});if(u(r))return T({readable:b.fromWeb(r)});if(c(r))return T({writable:m.fromWeb(r)});if("function"==typeof r){const{value:e,write:o,final:s,destroy:a}=function(e){let{promise:r,resolve:n}=_();const i=new E,o=i.signal,s=e(async function*(){for(;;){const e=r;r=null;const{chunk:i,done:s,cb:a}=await e;if(t.nextTick(a),s)return;if(o.aborted)throw new f(void 0,{cause:o.reason});({promise:r,resolve:n}=_()),yield i}}(),{signal:o});return{value:s,write(t,e,r){const i=n;n=null,i({chunk:t,done:!1,cb:r})},final(t){const e=n;n=null,e({done:!0,cb:t})},destroy(t,e){i.abort(),e(t)}}}(r);if(i(e))return v(k,e,{objectMode:!0,write:o,final:s,destroy:a});const l=null==e?void 0:e.then;if("function"==typeof l){let r;const n=R(l,e,t=>{if(null!=t)throw new p("nully","body",t)},t=>{y(r,t)});return r=new k({objectMode:!0,readable:!1,write:o,final(e){s(async()=>{try{await n,t.nextTick(e,null)}catch(r){t.nextTick(e,r)}})},destroy:a})}throw new p("Iterable, AsyncIterable or AsyncFunction",n,e)}if(S(r))return e(r.arrayBuffer());if(i(r))return v(k,r,{objectMode:!0,writable:!1});if(u(null==r?void 0:r.readable)&&c(null==r?void 0:r.writable))return k.fromWeb(r);if("object"==typeof(null==r?void 0:r.writable)||"object"==typeof(null==r?void 0:r.readable)){return T({readable:null!=r&&r.readable?s(null==r?void 0:r.readable)?null==r?void 0:r.readable:e(r.readable):void 0,writable:null!=r&&r.writable?a(null==r?void 0:r.writable)?null==r?void 0:r.writable:e(r.writable):void 0})}const h=null==r?void 0:r.then;if("function"==typeof h){let t;return R(h,r,e=>{null!=e&&t.push(e),t.push(null)},e=>{y(t,e)}),t=new k({objectMode:!0,writable:!1,read(){}})}throw new d(n,["Blob","ReadableStream","WritableStream","Stream","Iterable","AsyncIterable","Function","{ readable, writable } pair","Promise"],r)},kp}function Ip(){if(Ap)return xp;Ap=1;const{ObjectDefineProperties:t,ObjectGetOwnPropertyDescriptor:e,ObjectKeys:r,ObjectSetPrototypeOf:n}=jc;xp=s;const i=Lp(),o=jp();n(s.prototype,i.prototype),n(s,i);{const t=r(o.prototype);for(let e=0;e<t.length;e++){const r=t[e];s.prototype[r]||(s.prototype[r]=o.prototype[r])}}function s(t){if(!(this instanceof s))return new s(t);i.call(this,t),o.call(this,t),t?(this.allowHalfOpen=!1!==t.allowHalfOpen,!1===t.readable&&(this._readableState.readable=!1,this._readableState.ended=!0,this._readableState.endEmitted=!0),!1===t.writable&&(this._writableState.writable=!1,this._writableState.ending=!0,this._writableState.ended=!0,this._writableState.finished=!0)):this.allowHalfOpen=!0}let a,l;function u(){return void 0===a&&(a={}),a}return t(s.prototype,{writable:{__proto__:null,...e(o.prototype,"writable")},writableHighWaterMark:{__proto__:null,...e(o.prototype,"writableHighWaterMark")},writableObjectMode:{__proto__:null,...e(o.prototype,"writableObjectMode")},writableBuffer:{__proto__:null,...e(o.prototype,"writableBuffer")},writableLength:{__proto__:null,...e(o.prototype,"writableLength")},writableFinished:{__proto__:null,...e(o.prototype,"writableFinished")},writableCorked:{__proto__:null,...e(o.prototype,"writableCorked")},writableEnded:{__proto__:null,...e(o.prototype,"writableEnded")},writableNeedDrain:{__proto__:null,...e(o.prototype,"writableNeedDrain")},destroyed:{__proto__:null,get(){return void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed&&this._writableState.destroyed)},set(t){this._readableState&&this._writableState&&(this._readableState.destroyed=t,this._writableState.destroyed=t)}}}),s.fromWeb=function(t,e){return u().newStreamDuplexFromReadableWritablePair(t,e)},s.toWeb=function(t){return u().newReadableWritablePairFromDuplex(t)},s.from=function(t){return l||(l=Mp()),l(t,"body")},xp}const{ObjectSetPrototypeOf:Pp,Symbol:Dp}=jc;var Cp=Up;const{ERR_METHOD_NOT_IMPLEMENTED:Np}=Zc.codes,Fp=Ip(),{getHighWaterMark:Bp}=Xd;Pp(Up.prototype,Fp.prototype),Pp(Up,Fp);const Wp=Dp("kCallback");function Up(t){if(!(this instanceof Up))return new Up(t);const e=t?Bp(this,t,"readableHighWaterMark",!0):null;0===e&&(t={...t,highWaterMark:null,readableHighWaterMark:e,writableHighWaterMark:t.writableHighWaterMark||0}),Fp.call(this,t),this._readableState.sync=!1,this[Wp]=null,t&&("function"==typeof t.transform&&(this._transform=t.transform),"function"==typeof t.flush&&(this._flush=t.flush)),this.on("prefinish",$p)}function zp(t){"function"!=typeof this._flush||this.destroyed?(this.push(null),t&&t()):this._flush((e,r)=>{e?t?t(e):this.destroy(e):(null!=r&&this.push(r),this.push(null),t&&t())})}function $p(){this._final!==zp&&zp.call(this)}Up.prototype._final=zp,Up.prototype._transform=function(t,e,r){throw new Np("_transform()")},Up.prototype._write=function(t,e,r){const n=this._readableState,i=this._writableState,o=n.length;this._transform(t,e,(t,e)=>{t?r(t):(null!=e&&this.push(e),i.ended||o===n.length||n.length<n.highWaterMark?r():this[Wp]=r)})},Up.prototype._read=function(){if(this[Wp]){const t=this[Wp];this[Wp]=null,t()}};const{ObjectSetPrototypeOf:Hp}=jc;var Gp=Vp;const qp=Cp;function Vp(t){if(!(this instanceof Vp))return new Vp(t);qp.call(this,t)}Hp(Vp.prototype,qp.prototype),Hp(Vp,qp),Vp.prototype._transform=function(t,e,r){r(null,t)};const Zp=of,{ArrayIsArray:Yp,Promise:Kp,SymbolAsyncIterator:Qp,SymbolDispose:Jp}=jc,Xp=ad,{once:ty}=Qc,ey=Ld,ry=Ip(),{aggregateTwoErrors:ny,codes:{ERR_INVALID_ARG_TYPE:iy,ERR_INVALID_RETURN_VALUE:oy,ERR_MISSING_ARGS:sy,ERR_STREAM_DESTROYED:ay,ERR_STREAM_PREMATURE_CLOSE:ly},AbortError:uy}=Zc,{validateFunction:cy,validateAbortSignal:hy}=$h,{isIterable:fy,isReadable:dy,isReadableNodeStream:py,isNodeStream:yy,isTransformStream:gy,isWebStream:by,isReadableStream:my,isReadableFinished:_y}=Of,vy=globalThis.AbortController||Kc().AbortController;let wy,Sy,Ey;function Ry(t,e,r){let n=!1;t.on("close",()=>{n=!0});return{destroy:e=>{n||(n=!0,ey.destroyer(t,e||new ay("pipe")))},cleanup:Xp(t,{readable:e,writable:r},t=>{n=!t})}}function ky(t){if(fy(t))return t;if(py(t))return async function*(t){Sy||(Sy=Lp());yield*Sy.prototype[Qp].call(t)}(t);throw new iy("val",["Readable","Iterable","AsyncIterable"],t)}async function Ty(t,e,r,{end:n}){let i,o=null;const s=t=>{if(t&&(i=t),o){const t=o;o=null,t()}},a=()=>new Kp((t,e)=>{i?e(i):o=()=>{i?e(i):t()}});e.on("drain",s);const l=Xp(e,{readable:!1},s);try{e.writableNeedDrain&&await a();for await(const r of t)e.write(r)||await a();n&&(e.end(),await a()),r()}catch(t){r(i!==t?ny(i,t):t)}finally{l(),e.off("drain",s)}}async function xy(t,e,r,{end:n}){gy(e)&&(e=e.writable);const i=e.getWriter();try{for await(const e of t)await i.ready,i.write(e).catch(()=>{});await i.ready,n&&await i.close(),r()}catch(t){try{await i.abort(t),r(t)}catch(t){r(t)}}}function Ay(t,e,r){if(1===t.length&&Yp(t[0])&&(t=t[0]),t.length<2)throw new sy("streams");const n=new vy,i=n.signal,o=null==r?void 0:r.signal,s=[];function a(){y(new uy)}let l,u,c;hy(o,"options.signal"),Ey=Ey||Qc.addAbortListener,o&&(l=Ey(o,a));const h=[];let f,d=0;function p(t){y(t,0===--d)}function y(t,r){var i;if(!t||u&&"ERR_STREAM_PREMATURE_CLOSE"!==u.code||(u=t),u||r){for(;h.length;)h.shift()(u);null===(i=l)||void 0===i||i[Jp](),n.abort(),r&&(u||s.forEach(t=>t()),Zp.nextTick(e,u,c))}}for(let m=0;m<t.length;m++){const _=t[m],v=m<t.length-1,w=m>0,S=v||!1!==(null==r?void 0:r.end),E=m===t.length-1;if(yy(_)){if(S){const{destroy:k,cleanup:T}=Ry(_,v,w);h.push(k),dy(_)&&E&&s.push(T)}function R(t){t&&"AbortError"!==t.name&&"ERR_STREAM_PREMATURE_CLOSE"!==t.code&&p(t)}_.on("error",R),dy(_)&&E&&s.push(()=>{_.removeListener("error",R)})}if(0===m)if("function"==typeof _){if(f=_({signal:i}),!fy(f))throw new oy("Iterable, AsyncIterable or Stream","source",f)}else f=fy(_)||py(_)||gy(_)?_:ry.from(_);else if("function"==typeof _){var g;if(gy(f))f=ky(null===(g=f)||void 0===g?void 0:g.readable);else f=ky(f);if(f=_(f,{signal:i}),v){if(!fy(f,!0))throw new oy("AsyncIterable",`transform[${m-1}]`,f)}else{var b;wy||(wy=Gp);const x=new wy({objectMode:!0}),A=null===(b=f)||void 0===b?void 0:b.then;if("function"==typeof A)d++,A.call(f,t=>{c=t,null!=t&&x.write(t),S&&x.end(),Zp.nextTick(p)},t=>{x.destroy(t),Zp.nextTick(p,t)});else if(fy(f,!0))d++,Ty(f,x,p,{end:S});else{if(!my(f)&&!gy(f))throw new oy("AsyncIterable or Promise","destination",f);{const j=f.readable||f;d++,Ty(j,x,p,{end:S})}}f=x;const{destroy:O,cleanup:L}=Ry(f,!1,!0);h.push(O),E&&s.push(L)}}else if(yy(_)){if(py(f)){d+=2;const M=Oy(f,_,p,{end:S});dy(_)&&E&&s.push(M)}else if(gy(f)||my(f)){const I=f.readable||f;d++,Ty(I,_,p,{end:S})}else{if(!fy(f))throw new iy("val",["Readable","Iterable","AsyncIterable","ReadableStream","TransformStream"],f);d++,Ty(f,_,p,{end:S})}f=_}else if(by(_)){if(py(f))d++,xy(ky(f),_,p,{end:S});else if(my(f)||fy(f))d++,xy(f,_,p,{end:S});else{if(!gy(f))throw new iy("val",["Readable","Iterable","AsyncIterable","ReadableStream","TransformStream"],f);d++,xy(f.readable,_,p,{end:S})}f=_}else f=ry.from(_)}return(null!=i&&i.aborted||null!=o&&o.aborted)&&Zp.nextTick(a),f}function Oy(t,e,r,{end:n}){let i=!1;if(e.on("close",()=>{i||r(new ly)}),t.pipe(e,{end:!1}),n){function o(){i=!0,e.end()}_y(t)?Zp.nextTick(o):t.once("end",o)}else r();return Xp(t,{readable:!0,writable:!1},e=>{const n=t._readableState;e&&"ERR_STREAM_PREMATURE_CLOSE"===e.code&&n&&n.ended&&!n.errored&&!n.errorEmitted?t.once("end",r).once("error",r):r(e)}),Xp(e,{readable:!1,writable:!0},r)}var Ly={pipelineImpl:Ay,pipeline:function(...t){return Ay(t,ty(function(t){return cy(t[t.length-1],"streams[stream.length - 1]"),t.pop()}(t)))}};const{pipeline:jy}=Ly,My=Ip(),{destroyer:Iy}=Ld,{isNodeStream:Py,isReadable:Dy,isWritable:Cy,isWebStream:Ny,isTransformStream:Fy,isWritableStream:By,isReadableStream:Wy}=Of,{AbortError:Uy,codes:{ERR_INVALID_ARG_VALUE:zy,ERR_MISSING_ARGS:$y}}=Zc,Hy=ad;var Gy=function(...t){if(0===t.length)throw new $y("streams");if(1===t.length)return My.from(t[0]);const e=[...t];if("function"==typeof t[0]&&(t[0]=My.from(t[0])),"function"==typeof t[t.length-1]){const e=t.length-1;t[e]=My.from(t[e])}for(let r=0;r<t.length;++r)if(Py(t[r])||Ny(t[r])){if(r<t.length-1&&!(Dy(t[r])||Wy(t[r])||Fy(t[r])))throw new zy(`streams[${r}]`,e[r],"must be readable");if(r>0&&!(Cy(t[r])||By(t[r])||Fy(t[r])))throw new zy(`streams[${r}]`,e[r],"must be writable")}let r,n,i,o,s;const a=t[0],l=jy(t,function(t){const e=o;o=null,e?e(t):t?s.destroy(t):c||u||s.destroy()}),u=!!(Cy(a)||By(a)||Fy(a)),c=!!(Dy(l)||Wy(l)||Fy(l));if(s=new My({writableObjectMode:!(null==a||!a.writableObjectMode),readableObjectMode:!(null==l||!l.readableObjectMode),writable:u,readable:c}),u){if(Py(a))s._write=function(t,e,n){a.write(t,e)?n():r=n},s._final=function(t){a.end(),n=t},a.on("drain",function(){if(r){const t=r;r=null,t()}});else if(Ny(a)){const t=(Fy(a)?a.writable:a).getWriter();s._write=async function(e,r,n){try{await t.ready,t.write(e).catch(()=>{}),n()}catch(t){n(t)}},s._final=async function(e){try{await t.ready,t.close().catch(()=>{}),n=e}catch(t){e(t)}}}const t=Fy(l)?l.readable:l;Hy(t,()=>{if(n){const t=n;n=null,t()}})}if(c)if(Py(l))l.on("readable",function(){if(i){const t=i;i=null,t()}}),l.on("end",function(){s.push(null)}),s._read=function(){for(;;){const t=l.read();if(null===t)return void(i=s._read);if(!s.push(t))return}};else if(Ny(l)){const t=(Fy(l)?l.readable:l).getReader();s._read=async function(){for(;;)try{const{value:e,done:r}=await t.read();if(!s.push(e))return;if(r)return void s.push(null)}catch{return}}}return s._destroy=function(t,e){t||null===o||(t=new Uy),i=null,r=null,n=null,null===o?e(t):(o=e,Py(l)&&Iy(l,t))},s};const qy=globalThis.AbortController||Kc().AbortController,{codes:{ERR_INVALID_ARG_VALUE:Vy,ERR_INVALID_ARG_TYPE:Zy,ERR_MISSING_ARGS:Yy,ERR_OUT_OF_RANGE:Ky},AbortError:Qy}=Zc,{validateAbortSignal:Jy,validateInteger:Xy,validateObject:tg}=$h,eg=jc.Symbol("kWeak"),rg=jc.Symbol("kResistStopPropagation"),{finished:ng}=ad,ig=Gy,{addAbortSignalNoValidate:og}=Fd,{isWritable:sg,isNodeStream:ag}=Of,{deprecate:lg}=Qc,{ArrayPrototypePush:ug,Boolean:cg,MathFloor:hg,Number:fg,NumberIsNaN:dg,Promise:pg,PromiseReject:yg,PromiseResolve:gg,PromisePrototypeThen:bg,Symbol:mg}=jc,_g=mg("kEmpty"),vg=mg("kEof");function wg(t,e){if("function"!=typeof t)throw new Zy("fn",["Function","AsyncFunction"],t);null!=e&&tg(e,"options"),null!=(null==e?void 0:e.signal)&&Jy(e.signal,"options.signal");let r=1;null!=(null==e?void 0:e.concurrency)&&(r=hg(e.concurrency));let n=r-1;return null!=(null==e?void 0:e.highWaterMark)&&(n=hg(e.highWaterMark)),Xy(r,"options.concurrency",1),Xy(n,"options.highWaterMark",0),n+=r,async function*(){const i=Qc.AbortSignalAny([null==e?void 0:e.signal].filter(cg)),o=this,s=[],a={signal:i};let l,u,c=!1,h=0;function f(){c=!0,d()}function d(){h-=1,p()}function p(){u&&!c&&h<r&&s.length<n&&(u(),u=null)}!async function(){try{for await(let e of o){if(c)return;if(i.aborted)throw new Qy;try{if(e=t(e,a),e===_g)continue;e=gg(e)}catch(t){e=yg(t)}h+=1,bg(e,d,f),s.push(e),l&&(l(),l=null),!c&&(s.length>=n||h>=r)&&await new pg(t=>{u=t})}s.push(vg)}catch(t){const e=yg(t);bg(e,d,f),s.push(e)}finally{c=!0,l&&(l(),l=null)}}();try{for(;;){for(;s.length>0;){const t=await s[0];if(t===vg)return;if(i.aborted)throw new Qy;t!==_g&&(yield t),s.shift(),p()}await new pg(t=>{l=t})}}finally{c=!0,u&&(u(),u=null)}}.call(this)}async function Sg(t,e=void 0){for await(const r of Eg.call(this,t,e))return!0;return!1}function Eg(t,e){if("function"!=typeof t)throw new Zy("fn",["Function","AsyncFunction"],t);return wg.call(this,async function(e,r){return await t(e,r)?e:_g},e)}let Rg=class extends Yy{constructor(){super("reduce"),this.message="Reduce of an empty stream requires an initial value"}};function kg(t){if(t=fg(t),dg(t))return 0;if(t<0)throw new Ky("number",">= 0",t);return t}var Tg,xg,Ag;function Og(){if(xg)return Tg;xg=1;const{ArrayPrototypePop:t,Promise:e}=jc,{isIterable:r,isNodeStream:n,isWebStream:i}=Of,{pipelineImpl:o}=Ly,{finished:s}=ad;return Lg(),Tg={finished:s,pipeline:function(...s){return new e((e,a)=>{let l,u;const c=s[s.length-1];if(c&&"object"==typeof c&&!n(c)&&!r(c)&&!i(c)){const e=t(s);l=e.signal,u=e.end}o(s,(t,r)=>{t?a(t):e(r)},{signal:l,end:u})})}},Tg}function Lg(){if(Ag)return Oc.exports;Ag=1;const{Buffer:t}=ca,{ObjectDefineProperty:e,ObjectKeys:r,ReflectApply:n}=jc,{promisify:{custom:i}}=Qc,{streamReturningOperators:o,promiseReturningOperators:s}=Jc,{codes:{ERR_ILLEGAL_CONSTRUCTOR:a}}=Zc,l=Gy,{setDefaultHighWaterMark:u,getDefaultHighWaterMark:c}=Xd,{pipeline:h}=Ly,{destroyer:f}=Ld,d=ad,p=Og(),y=Of,g=Oc.exports=Cd.Stream;g.isDestroyed=y.isDestroyed,g.isDisturbed=y.isDisturbed,g.isErrored=y.isErrored,g.isReadable=y.isReadable,g.isWritable=y.isWritable,g.Readable=Lp();for(const m of r(o)){const _=o[m];function v(...t){if(new.target)throw a();return g.Readable.from(n(_,this,t))}e(v,"name",{__proto__:null,value:_.name}),e(v,"length",{__proto__:null,value:_.length}),e(g.Readable.prototype,m,{__proto__:null,value:v,enumerable:!1,configurable:!0,writable:!0})}for(const w of r(s)){const S=s[w];function E(...t){if(new.target)throw a();return n(S,this,t)}e(E,"name",{__proto__:null,value:S.name}),e(E,"length",{__proto__:null,value:S.length}),e(g.Readable.prototype,w,{__proto__:null,value:E,enumerable:!1,configurable:!0,writable:!0})}g.Writable=jp(),g.Duplex=Ip(),g.Transform=Cp,g.PassThrough=Gp,g.pipeline=h;const{addAbortSignal:b}=Fd;return g.addAbortSignal=b,g.finished=d,g.destroy=f,g.compose=l,g.setDefaultHighWaterMark=u,g.getDefaultHighWaterMark=c,e(g,"promises",{__proto__:null,configurable:!0,enumerable:!0,get:()=>p}),e(h,i,{__proto__:null,enumerable:!0,get:()=>p.pipeline}),e(d,i,{__proto__:null,enumerable:!0,get:()=>p.finished}),g.Stream=g,g._isUint8Array=function(t){return t instanceof Uint8Array},g._uint8ArrayToBuffer=function(e){return t.from(e.buffer,e.byteOffset,e.byteLength)},Oc.exports}Jc.streamReturningOperators={asIndexedPairs:lg(function(t=void 0){return null!=t&&tg(t,"options"),null!=(null==t?void 0:t.signal)&&Jy(t.signal,"options.signal"),async function*(){let e=0;for await(const n of this){var r;if(null!=t&&null!==(r=t.signal)&&void 0!==r&&r.aborted)throw new Qy({cause:t.signal.reason});yield[e++,n]}}.call(this)},"readable.asIndexedPairs will be removed in a future version."),drop:function(t,e=void 0){return null!=e&&tg(e,"options"),null!=(null==e?void 0:e.signal)&&Jy(e.signal,"options.signal"),t=kg(t),async function*(){var r;if(null!=e&&null!==(r=e.signal)&&void 0!==r&&r.aborted)throw new Qy;for await(const r of this){var n;if(null!=e&&null!==(n=e.signal)&&void 0!==n&&n.aborted)throw new Qy;t--<=0&&(yield r)}}.call(this)},filter:Eg,flatMap:function(t,e){const r=wg.call(this,t,e);return async function*(){for await(const t of r)yield*t}.call(this)},map:wg,take:function(t,e=void 0){return null!=e&&tg(e,"options"),null!=(null==e?void 0:e.signal)&&Jy(e.signal,"options.signal"),t=kg(t),async function*(){var r;if(null!=e&&null!==(r=e.signal)&&void 0!==r&&r.aborted)throw new Qy;for await(const r of this){var n;if(null!=e&&null!==(n=e.signal)&&void 0!==n&&n.aborted)throw new Qy;if(t-- >0&&(yield r),t<=0)return}}.call(this)},compose:function(t,e){if(null!=e&&tg(e,"options"),null!=(null==e?void 0:e.signal)&&Jy(e.signal,"options.signal"),ag(t)&&!sg(t))throw new Vy("stream",t,"must be writable");const r=ig(this,t);return null!=e&&e.signal&&og(e.signal,r),r}},Jc.promiseReturningOperators={every:async function(t,e=void 0){if("function"!=typeof t)throw new Zy("fn",["Function","AsyncFunction"],t);return!await Sg.call(this,async(...e)=>!await t(...e),e)},forEach:async function(t,e){if("function"!=typeof t)throw new Zy("fn",["Function","AsyncFunction"],t);for await(const r of wg.call(this,async function(e,r){return await t(e,r),_g},e));},reduce:async function(t,e,r){var n;if("function"!=typeof t)throw new Zy("reducer",["Function","AsyncFunction"],t);null!=r&&tg(r,"options"),null!=(null==r?void 0:r.signal)&&Jy(r.signal,"options.signal");let i=arguments.length>1;if(null!=r&&null!==(n=r.signal)&&void 0!==n&&n.aborted){const t=new Qy(void 0,{cause:r.signal.reason});throw this.once("error",()=>{}),await ng(this.destroy(t)),t}const o=new qy,s=o.signal;if(null!=r&&r.signal){const t={once:!0,[eg]:this,[rg]:!0};r.signal.addEventListener("abort",()=>o.abort(),t)}let a=!1;try{for await(const n of this){var l;if(a=!0,null!=r&&null!==(l=r.signal)&&void 0!==l&&l.aborted)throw new Qy;i?e=await t(e,n,{signal:s}):(e=n,i=!0)}if(!a&&!i)throw new Rg}finally{o.abort()}return e},toArray:async function(t){null!=t&&tg(t,"options"),null!=(null==t?void 0:t.signal)&&Jy(t.signal,"options.signal");const e=[];for await(const n of this){var r;if(null!=t&&null!==(r=t.signal)&&void 0!==r&&r.aborted)throw new Qy(void 0,{cause:t.signal.reason});ug(e,n)}return e},some:Sg,find:async function(t,e){for await(const r of Eg.call(this,t,e))return r}},function(t){const e=Lg(),r=Og(),n=e.Readable.destroy;t.exports=e.Readable,t.exports._uint8ArrayToBuffer=e._uint8ArrayToBuffer,t.exports._isUint8Array=e._isUint8Array,t.exports.isDisturbed=e.isDisturbed,t.exports.isErrored=e.isErrored,t.exports.isReadable=e.isReadable,t.exports.Readable=e.Readable,t.exports.Writable=e.Writable,t.exports.Duplex=e.Duplex,t.exports.Transform=e.Transform,t.exports.PassThrough=e.PassThrough,t.exports.addAbortSignal=e.addAbortSignal,t.exports.finished=e.finished,t.exports.destroy=e.destroy,t.exports.destroy=n,t.exports.pipeline=e.pipeline,t.exports.compose=e.compose,Object.defineProperty(e,"promises",{configurable:!0,enumerable:!0,get:()=>r}),t.exports.Stream=e.Stream,t.exports.default=t.exports}(Ac);var jg=Ac.exports,Mg={exports:{}};var Ig=function(t,e){for(var r=-1,n=e.length,i=t.length;++r<n;)t[i+r]=e[r];return t},Pg=Bu,Dg=Wu,Cg=El?El.isConcatSpreadable:void 0;var Ng=Ig,Fg=function(t){return Dg(t)||Pg(t)||!!(Cg&&t&&t[Cg])};var Bg=function t(e,r,n,i,o){var s=-1,a=e.length;for(n||(n=Fg),o||(o=[]);++s<a;){var l=e[s];r>0&&n(l)?r>1?t(l,r-1,n,i,o):Ng(o,l):i||(o[o.length]=l)}return o},Wg=Bg;var Ug=function(t){return(null==t?0:t.length)?Wg(t,1):[]},zg=nu(Object,"create"),$g=zg;var Hg=function(){this.__data__=$g?$g(null):{},this.size=0};var Gg=function(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e},qg=zg,Vg=Object.prototype.hasOwnProperty;var Zg=function(t){var e=this.__data__;if(qg){var r=e[t];return"__lodash_hash_undefined__"===r?void 0:r}return Vg.call(e,t)?e[t]:void 0},Yg=zg,Kg=Object.prototype.hasOwnProperty;var Qg=function(t){var e=this.__data__;return Yg?void 0!==e[t]:Kg.call(e,t)},Jg=zg;var Xg=function(t,e){var r=this.__data__;return this.size+=this.has(t)?0:1,r[t]=Jg&&void 0===e?"__lodash_hash_undefined__":e,this},tb=Hg,eb=Gg,rb=Zg,nb=Qg,ib=Xg;function ob(t){var e=-1,r=null==t?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}ob.prototype.clear=tb,ob.prototype.delete=eb,ob.prototype.get=rb,ob.prototype.has=nb,ob.prototype.set=ib;var sb=ob;var ab=function(){this.__data__=[],this.size=0},lb=bu;var ub=function(t,e){for(var r=t.length;r--;)if(lb(t[r][0],e))return r;return-1},cb=ub,hb=Array.prototype.splice;var fb=function(t){var e=this.__data__,r=cb(e,t);return!(r<0)&&(r==e.length-1?e.pop():hb.call(e,r,1),--this.size,!0)},db=ub;var pb=function(t){var e=this.__data__,r=db(e,t);return r<0?void 0:e[r][1]},yb=ub;var gb=function(t){return yb(this.__data__,t)>-1},bb=ub;var mb=function(t,e){var r=this.__data__,n=bb(r,t);return n<0?(++this.size,r.push([t,e])):r[n][1]=e,this},_b=ab,vb=fb,wb=pb,Sb=gb,Eb=mb;function Rb(t){var e=-1,r=null==t?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}Rb.prototype.clear=_b,Rb.prototype.delete=vb,Rb.prototype.get=wb,Rb.prototype.has=Sb,Rb.prototype.set=Eb;var kb=Rb,Tb=nu(Sl,"Map"),xb=sb,Ab=kb,Ob=Tb;var Lb=function(t){var e=typeof t;return"string"==e||"number"==e||"symbol"==e||"boolean"==e?"__proto__"!==t:null===t};var jb=function(t,e){var r=t.__data__;return Lb(e)?r["string"==typeof e?"string":"hash"]:r.map},Mb=jb;var Ib=function(t){var e=Mb(this,t).delete(t);return this.size-=e?1:0,e},Pb=jb;var Db=function(t){return Pb(this,t).get(t)},Cb=jb;var Nb=function(t){return Cb(this,t).has(t)},Fb=jb;var Bb=function(t,e){var r=Fb(this,t),n=r.size;return r.set(t,e),this.size+=r.size==n?0:1,this},Wb=function(){this.size=0,this.__data__={hash:new xb,map:new(Ob||Ab),string:new xb}},Ub=Ib,zb=Db,$b=Nb,Hb=Bb;function Gb(t){var e=-1,r=null==t?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}Gb.prototype.clear=Wb,Gb.prototype.delete=Ub,Gb.prototype.get=zb,Gb.prototype.has=$b,Gb.prototype.set=Hb;var qb=Gb,Vb=function(t){return this.__data__.set(t,"__lodash_hash_undefined__"),this},Zb=function(t){return this.__data__.has(t)};function Yb(t){var e=-1,r=null==t?0:t.length;for(this.__data__=new qb;++e<r;)this.add(t[e])}Yb.prototype.add=Yb.prototype.push=Vb,Yb.prototype.has=Zb;var Kb=Yb;var Qb=function(t,e,r,n){for(var i=t.length,o=r+(n?1:-1);n?o--:++o<i;)if(e(t[o],o,t))return o;return-1};var Jb=function(t,e,r){for(var n=r-1,i=t.length;++n<i;)if(t[n]===e)return n;return-1},Xb=Qb,tm=function(t){return t!=t},em=Jb;var rm=function(t,e,r){return e==e?em(t,e,r):Xb(t,tm,r)};var nm=function(t,e){return!!(null==t?0:t.length)&&rm(t,e,0)>-1};var im=function(t,e,r){for(var n=-1,i=null==t?0:t.length;++n<i;)if(r(e,t[n]))return!0;return!1};var om=function(t,e){for(var r=-1,n=null==t?0:t.length,i=Array(n);++r<n;)i[r]=e(t[r],r,t);return i};var sm=function(t,e){return t.has(e)},am=Kb,lm=nm,um=im,cm=om,hm=Yu,fm=sm;var dm=function(t,e,r,n){var i=-1,o=lm,s=!0,a=t.length,l=[],u=e.length;if(!a)return l;r&&(e=cm(e,hm(r))),n?(o=um,s=!1):e.length>=200&&(o=fm,s=!1,e=new am(e));t:for(;++i<a;){var c=t[i],h=null==r?c:r(c);if(c=n||0!==c?c:0,s&&h==h){for(var f=u;f--;)if(e[f]===h)continue t;l.push(c)}else o(e,h,n)||l.push(c)}return l},pm=wu,ym=Lu;var gm=function(t){return ym(t)&&pm(t)},bm=dm,mm=Bg,_m=gm,vm=gu(function(t,e){return _m(t)?bm(t,mm(e,1,_m,!0)):[]}),wm=vm;var Sm=function(t){var e=-1,r=Array(t.size);return t.forEach(function(t){r[++e]=t}),r},Em=nu(Sl,"Set"),Rm=function(){},km=Em&&1/Sm(new Em([,-0]))[1]==1/0?function(t){return new Em(t)}:Rm,Tm=Kb,xm=nm,Am=im,Om=sm,Lm=km,jm=Sm;var Mm=function(t,e,r){var n=-1,i=xm,o=t.length,s=!0,a=[],l=a;if(r)s=!1,i=Am;else if(o>=200){var u=e?null:Lm(t);if(u)return jm(u);s=!1,i=Om,l=new Tm}else l=e?[]:a;t:for(;++n<o;){var c=t[n],h=e?e(c):c;if(c=r||0!==c?c:0,s&&h==h){for(var f=l.length;f--;)if(l[f]===h)continue t;e&&l.push(h),a.push(c)}else i(l,h,r)||(l!==a&&l.push(h),a.push(c))}return a},Im=Bg,Pm=Mm,Dm=gm,Cm=gu(function(t){return Pm(Im(t,1,Dm,!0))});var Nm=function(t,e){return function(r){return t(e(r))}},Fm=Nm(Object.getPrototypeOf,Object),Bm=Pl,Wm=Fm,Um=Lu,zm=Function.prototype,$m=Object.prototype,Hm=zm.toString,Gm=$m.hasOwnProperty,qm=Hm.call(Object);var Vm=function(t){if(!Um(t)||"[object Object]"!=Bm(t))return!1;var e=Wm(t);if(null===e)return!0;var r=Gm.call(e,"constructor")&&e.constructor;return"function"==typeof r&&r instanceof r&&Hm.call(r)==qm},Zm={},Ym={},Km=bn,Qm=function(t){if(!t)return[];"{}"===t.substr(0,2)&&(t="\\{\\}"+t.substr(2));return c_(function(t){return t.split("\\\\").join(Jm).split("\\{").join(Xm).split("\\}").join(t_).split("\\,").join(e_).split("\\.").join(r_)}(t),!0).map(i_)},Jm="\0SLASH"+Math.random()+"\0",Xm="\0OPEN"+Math.random()+"\0",t_="\0CLOSE"+Math.random()+"\0",e_="\0COMMA"+Math.random()+"\0",r_="\0PERIOD"+Math.random()+"\0";function n_(t){return parseInt(t,10)==t?parseInt(t,10):t.charCodeAt(0)}function i_(t){return t.split(Jm).join("\\").split(Xm).join("{").split(t_).join("}").split(e_).join(",").split(r_).join(".")}function o_(t){if(!t)return[""];var e=[],r=Km("{","}",t);if(!r)return t.split(",");var n=r.pre,i=r.body,o=r.post,s=n.split(",");s[s.length-1]+="{"+i+"}";var a=o_(o);return o.length&&(s[s.length-1]+=a.shift(),s.push.apply(s,a)),e.push.apply(e,s),e}function s_(t){return"{"+t+"}"}function a_(t){return/^-?0\d/.test(t)}function l_(t,e){return t<=e}function u_(t,e){return t>=e}function c_(t,e){var r=[],n=Km("{","}",t);if(!n)return[t];var i=n.pre,o=n.post.length?c_(n.post,!1):[""];if(/\$$/.test(n.pre))for(var s=0;s<o.length;s++){var a=i+"{"+n.body+"}"+o[s];r.push(a)}else{var l,u,c=/^-?\d+\.\.-?\d+(?:\.\.-?\d+)?$/.test(n.body),h=/^[a-zA-Z]\.\.[a-zA-Z](?:\.\.-?\d+)?$/.test(n.body),f=c||h,d=n.body.indexOf(",")>=0;if(!f&&!d)return n.post.match(/,(?!,).*\}/)?c_(t=n.pre+"{"+n.body+t_+n.post):[t];if(f)l=n.body.split(/\.\./);else if(1===(l=o_(n.body)).length&&1===(l=c_(l[0],!1).map(s_)).length)return o.map(function(t){return n.pre+l[0]+t});if(f){var p=n_(l[0]),y=n_(l[1]),g=Math.max(l[0].length,l[1].length),b=3==l.length?Math.abs(n_(l[2])):1,m=l_;y<p&&(b*=-1,m=u_);var _=l.some(a_);u=[];for(var v=p;m(v,y);v+=b){var w;if(h)"\\"===(w=String.fromCharCode(v))&&(w="");else if(w=String(v),_){var S=g-w.length;if(S>0){var E=new Array(S+1).join("0");w=v<0?"-"+E+w.slice(1):E+w}}u.push(w)}}else{u=[];for(var R=0;R<l.length;R++)u.push.apply(u,c_(l[R],!1))}for(R=0;R<u.length;R++)for(s=0;s<o.length;s++){a=i+u[R]+o[s];(!e||f||a)&&r.push(a)}}return r}var h_={};Object.defineProperty(h_,"__esModule",{value:!0}),h_.assertValidPattern=void 0;h_.assertValidPattern=t=>{if("string"!=typeof t)throw new TypeError("invalid pattern");if(t.length>65536)throw new TypeError("pattern is too long")};var f_={},d_={};Object.defineProperty(d_,"__esModule",{value:!0}),d_.parseClass=void 0;const p_={"[:alnum:]":["\\p{L}\\p{Nl}\\p{Nd}",!0],"[:alpha:]":["\\p{L}\\p{Nl}",!0],"[:ascii:]":["\\x00-\\x7f",!1],"[:blank:]":["\\p{Zs}\\t",!0],"[:cntrl:]":["\\p{Cc}",!0],"[:digit:]":["\\p{Nd}",!0],"[:graph:]":["\\p{Z}\\p{C}",!0,!0],"[:lower:]":["\\p{Ll}",!0],"[:print:]":["\\p{C}",!0],"[:punct:]":["\\p{P}",!0],"[:space:]":["\\p{Z}\\t\\r\\n\\v\\f",!0],"[:upper:]":["\\p{Lu}",!0],"[:word:]":["\\p{L}\\p{Nl}\\p{Nd}\\p{Pc}",!0],"[:xdigit:]":["A-Fa-f0-9",!1]},y_=t=>t.replace(/[[\]\\-]/g,"\\$&"),g_=t=>t.join("");d_.parseClass=(t,e)=>{const r=e;if("["!==t.charAt(r))throw new Error("not in a brace expression");const n=[],i=[];let o=r+1,s=!1,a=!1,l=!1,u=!1,c=r,h="";t:for(;o<t.length;){const e=t.charAt(o);if("!"!==e&&"^"!==e||o!==r+1){if("]"===e&&s&&!l){c=o+1;break}if(s=!0,"\\"!==e||l){if("["===e&&!l)for(const[e,[s,l,u]]of Object.entries(p_))if(t.startsWith(e,o)){if(h)return["$.",!1,t.length-r,!0];o+=e.length,u?i.push(s):n.push(s),a=a||l;continue t}l=!1,h?(e>h?n.push(y_(h)+"-"+y_(e)):e===h&&n.push(y_(e)),h="",o++):t.startsWith("-]",o+1)?(n.push(y_(e+"-")),o+=2):t.startsWith("-",o+1)?(h=e,o+=2):(n.push(y_(e)),o++)}else l=!0,o++}else u=!0,o++}if(c<o)return["",!1,0,!1];if(!n.length&&!i.length)return["$.",!1,t.length-r,!0];if(0===i.length&&1===n.length&&/^\\?.$/.test(n[0])&&!u){const t=2===n[0].length?n[0].slice(-1):n[0];return[(f=t,f.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&")),!1,c-r,!1]}var f;const d="["+(u?"^":"")+g_(n)+"]",p="["+(u?"":"^")+g_(i)+"]";return[n.length&&i.length?"("+d+"|"+p+")":n.length?d:p,a,c-r,!0]};var b_={};Object.defineProperty(b_,"__esModule",{value:!0}),b_.unescape=void 0;b_.unescape=(t,{windowsPathsNoEscape:e=!1}={})=>e?t.replace(/\[([^\/\\])\]/g,"$1"):t.replace(/((?!\\).|^)\[([^\/\\])\]/g,"$1$2").replace(/\\([^\/])/g,"$1"),Object.defineProperty(f_,"__esModule",{value:!0}),f_.AST=void 0;const m_=d_,__=b_,v_=new Set(["!","?","+","*","@"]),w_=t=>v_.has(t),S_="(?!\\.)",E_=new Set(["[","."]),R_=new Set(["..","."]),k_=new Set("().*{}+?[]^$\\!"),T_=t=>t.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&"),x_="[^/]",A_=x_+"*?",O_=x_+"+?";class L_{type;#t;#e;#r=!1;#n=[];#i;#o;#s;#a=!1;#l;#u;#c=!1;constructor(t,e,r={}){this.type=t,t&&(this.#e=!0),this.#i=e,this.#t=this.#i?this.#i.#t:this,this.#l=this.#t===this?r:this.#t.#l,this.#s=this.#t===this?[]:this.#t.#s,"!"!==t||this.#t.#a||this.#s.push(this),this.#o=this.#i?this.#i.#n.length:0}get hasMagic(){if(void 0!==this.#e)return this.#e;for(const t of this.#n)if("string"!=typeof t&&(t.type||t.hasMagic))return this.#e=!0;return this.#e}toString(){return void 0!==this.#u?this.#u:this.type?this.#u=this.type+"("+this.#n.map(t=>String(t)).join("|")+")":this.#u=this.#n.map(t=>String(t)).join("")}#h(){if(this!==this.#t)throw new Error("should only call on root");if(this.#a)return this;let t;for(this.toString(),this.#a=!0;t=this.#s.pop();){if("!"!==t.type)continue;let e=t,r=e.#i;for(;r;){for(let n=e.#o+1;!r.type&&n<r.#n.length;n++)for(const e of t.#n){if("string"==typeof e)throw new Error("string part in extglob AST??");e.copyIn(r.#n[n])}e=r,r=e.#i}}return this}push(...t){for(const e of t)if(""!==e){if("string"!=typeof e&&!(e instanceof L_&&e.#i===this))throw new Error("invalid part: "+e);this.#n.push(e)}}toJSON(){const t=null===this.type?this.#n.slice().map(t=>"string"==typeof t?t:t.toJSON()):[this.type,...this.#n.map(t=>t.toJSON())];return this.isStart()&&!this.type&&t.unshift([]),this.isEnd()&&(this===this.#t||this.#t.#a&&"!"===this.#i?.type)&&t.push({}),t}isStart(){if(this.#t===this)return!0;if(!this.#i?.isStart())return!1;if(0===this.#o)return!0;const t=this.#i;for(let e=0;e<this.#o;e++){const r=t.#n[e];if(!(r instanceof L_&&"!"===r.type))return!1}return!0}isEnd(){if(this.#t===this)return!0;if("!"===this.#i?.type)return!0;if(!this.#i?.isEnd())return!1;if(!this.type)return this.#i?.isEnd();const t=this.#i?this.#i.#n.length:0;return this.#o===t-1}copyIn(t){"string"==typeof t?this.push(t):this.push(t.clone(this))}clone(t){const e=new L_(this.type,t);for(const t of this.#n)e.copyIn(t);return e}static#f(t,e,r,n){let i=!1,o=!1,s=-1,a=!1;if(null===e.type){let l=r,u="";for(;l<t.length;){const r=t.charAt(l++);if(i||"\\"===r)i=!i,u+=r;else if(o)l===s+1?"^"!==r&&"!"!==r||(a=!0):"]"!==r||l===s+2&&a||(o=!1),u+=r;else if("["!==r){if(!n.noext&&w_(r)&&"("===t.charAt(l)){e.push(u),u="";const i=new L_(r,e);l=L_.#f(t,i,l,n),e.push(i);continue}u+=r}else o=!0,s=l,a=!1,u+=r}return e.push(u),l}let l=r+1,u=new L_(null,e);const c=[];let h="";for(;l<t.length;){const r=t.charAt(l++);if(i||"\\"===r)i=!i,h+=r;else if(o)l===s+1?"^"!==r&&"!"!==r||(a=!0):"]"!==r||l===s+2&&a||(o=!1),h+=r;else if("["!==r){if(w_(r)&&"("===t.charAt(l)){u.push(h),h="";const e=new L_(r,u);u.push(e),l=L_.#f(t,e,l,n);continue}if("|"!==r){if(")"===r)return""===h&&0===e.#n.length&&(e.#c=!0),u.push(h),h="",e.push(...c,u),l;h+=r}else u.push(h),h="",c.push(u),u=new L_(null,e)}else o=!0,s=l,a=!1,h+=r}return e.type=null,e.#e=void 0,e.#n=[t.substring(r-1)],l}static fromGlob(t,e={}){const r=new L_(null,void 0,e);return L_.#f(t,r,0,e),r}toMMPattern(){if(this!==this.#t)return this.#t.toMMPattern();const t=this.toString(),[e,r,n,i]=this.toRegExpSource();if(!(n||this.#e||this.#l.nocase&&!this.#l.nocaseMagicOnly&&t.toUpperCase()!==t.toLowerCase()))return r;const o=(this.#l.nocase?"i":"")+(i?"u":"");return Object.assign(new RegExp(`^${e}$`,o),{_src:e,_glob:t})}get options(){return this.#l}toRegExpSource(t){const e=t??!!this.#l.dot;if(this.#t===this&&this.#h(),!this.type){const r=this.isStart()&&this.isEnd(),n=this.#n.map(e=>{const[n,i,o,s]="string"==typeof e?L_.#d(e,this.#e,r):e.toRegExpSource(t);return this.#e=this.#e||o,this.#r=this.#r||s,n}).join("");let i="";if(this.isStart()&&"string"==typeof this.#n[0]){if(!(1===this.#n.length&&R_.has(this.#n[0]))){const r=E_,o=e&&r.has(n.charAt(0))||n.startsWith("\\.")&&r.has(n.charAt(2))||n.startsWith("\\.\\.")&&r.has(n.charAt(4)),s=!e&&!t&&r.has(n.charAt(0));i=o?"(?!(?:^|/)\\.\\.?(?:$|/))":s?S_:""}}let o="";this.isEnd()&&this.#t.#a&&"!"===this.#i?.type&&(o="(?:$|\\/)");return[i+n+o,(0,__.unescape)(n),this.#e=!!this.#e,this.#r]}const r="*"===this.type||"+"===this.type,n="!"===this.type?"(?:(?!(?:":"(?:";let i=this.#p(e);if(this.isStart()&&this.isEnd()&&!i&&"!"!==this.type){const t=this.toString();return this.#n=[t],this.type=null,this.#e=void 0,[t,(0,__.unescape)(this.toString()),!1,!1]}let o=!r||t||e?"":this.#p(!0);o===i&&(o=""),o&&(i=`(?:${i})(?:${o})*?`);let s="";if("!"===this.type&&this.#c)s=(this.isStart()&&!e?S_:"")+O_;else{s=n+i+("!"===this.type?"))"+(!this.isStart()||e||t?"":S_)+A_+")":"@"===this.type?")":"?"===this.type?")?":"+"===this.type&&o?")":"*"===this.type&&o?")?":`)${this.type}`)}return[s,(0,__.unescape)(i),this.#e=!!this.#e,this.#r]}#p(t){return this.#n.map(e=>{if("string"==typeof e)throw new Error("string type in extglob ast??");const[r,n,i,o]=e.toRegExpSource(t);return this.#r=this.#r||o,r}).filter(t=>!(this.isStart()&&this.isEnd()&&!t)).join("|")}static#d(t,e,r=!1){let n=!1,i="",o=!1;for(let s=0;s<t.length;s++){const a=t.charAt(s);if(n)n=!1,i+=(k_.has(a)?"\\":"")+a;else if("\\"!==a){if("["===a){const[r,n,a,l]=(0,m_.parseClass)(t,s);if(a){i+=r,o=o||n,s+=a-1,e=e||l;continue}}"*"!==a?"?"!==a?i+=T_(a):(i+=x_,e=!0):(i+=r&&"*"===t?O_:A_,e=!0)}else s===t.length-1?i+="\\\\":n=!0}return[i,(0,__.unescape)(t),!!e,o]}}f_.AST=L_;var j_={};Object.defineProperty(j_,"__esModule",{value:!0}),j_.escape=void 0;j_.escape=(t,{windowsPathsNoEscape:e=!1}={})=>e?t.replace(/[?*()[\]]/g,"[$&]"):t.replace(/[?*()[\]\\]/g,"\\$&"),function(t){var e=Ft&&Ft.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(t,"__esModule",{value:!0}),t.unescape=t.escape=t.AST=t.Minimatch=t.match=t.makeRe=t.braceExpand=t.defaults=t.filter=t.GLOBSTAR=t.sep=t.minimatch=void 0;const r=e(Qm),n=h_,i=f_,o=j_,s=b_;t.minimatch=(t,e,r={})=>((0,n.assertValidPattern)(e),!(!r.nocomment&&"#"===e.charAt(0))&&new M(e,r).match(t));const a=/^\*+([^+@!?\*\[\(]*)$/,l=t=>e=>!e.startsWith(".")&&e.endsWith(t),u=t=>e=>e.endsWith(t),c=t=>(t=t.toLowerCase(),e=>!e.startsWith(".")&&e.toLowerCase().endsWith(t)),h=t=>(t=t.toLowerCase(),e=>e.toLowerCase().endsWith(t)),f=/^\*+\.\*+$/,d=t=>!t.startsWith(".")&&t.includes("."),p=t=>"."!==t&&".."!==t&&t.includes("."),y=/^\.\*+$/,g=t=>"."!==t&&".."!==t&&t.startsWith("."),b=/^\*+$/,m=t=>0!==t.length&&!t.startsWith("."),_=t=>0!==t.length&&"."!==t&&".."!==t,v=/^\?+([^+@!?\*\[\(]*)?$/,w=([t,e=""])=>{const r=k([t]);return e?(e=e.toLowerCase(),t=>r(t)&&t.toLowerCase().endsWith(e)):r},S=([t,e=""])=>{const r=T([t]);return e?(e=e.toLowerCase(),t=>r(t)&&t.toLowerCase().endsWith(e)):r},E=([t,e=""])=>{const r=T([t]);return e?t=>r(t)&&t.endsWith(e):r},R=([t,e=""])=>{const r=k([t]);return e?t=>r(t)&&t.endsWith(e):r},k=([t])=>{const e=t.length;return t=>t.length===e&&!t.startsWith(".")},T=([t])=>{const e=t.length;return t=>t.length===e&&"."!==t&&".."!==t},x="object"==typeof process&&process?"object"==typeof process.env&&process.env&&process.env.__MINIMATCH_TESTING_PLATFORM__||process.platform:"posix",A={sep:"\\"},O={sep:"/"};t.sep="win32"===x?A.sep:O.sep,t.minimatch.sep=t.sep,t.GLOBSTAR=Symbol("globstar **"),t.minimatch.GLOBSTAR=t.GLOBSTAR;t.filter=(e,r={})=>n=>(0,t.minimatch)(n,e,r),t.minimatch.filter=t.filter;const L=(t,e={})=>Object.assign({},t,e);t.defaults=e=>{if(!e||"object"!=typeof e||!Object.keys(e).length)return t.minimatch;const r=t.minimatch;return Object.assign((t,n,i={})=>r(t,n,L(e,i)),{Minimatch:class extends r.Minimatch{constructor(t,r={}){super(t,L(e,r))}static defaults(t){return r.defaults(L(e,t)).Minimatch}},AST:class extends r.AST{constructor(t,r,n={}){super(t,r,L(e,n))}static fromGlob(t,n={}){return r.AST.fromGlob(t,L(e,n))}},unescape:(t,n={})=>r.unescape(t,L(e,n)),escape:(t,n={})=>r.escape(t,L(e,n)),filter:(t,n={})=>r.filter(t,L(e,n)),defaults:t=>r.defaults(L(e,t)),makeRe:(t,n={})=>r.makeRe(t,L(e,n)),braceExpand:(t,n={})=>r.braceExpand(t,L(e,n)),match:(t,n,i={})=>r.match(t,n,L(e,i)),sep:r.sep,GLOBSTAR:t.GLOBSTAR})},t.minimatch.defaults=t.defaults;t.braceExpand=(t,e={})=>((0,n.assertValidPattern)(t),e.nobrace||!/\{(?:(?!\{).)*\}/.test(t)?[t]:(0,r.default)(t)),t.minimatch.braceExpand=t.braceExpand;t.makeRe=(t,e={})=>new M(t,e).makeRe(),t.minimatch.makeRe=t.makeRe;t.match=(t,e,r={})=>{const n=new M(e,r);return t=t.filter(t=>n.match(t)),n.options.nonull&&!t.length&&t.push(e),t},t.minimatch.match=t.match;const j=/[?*]|[+@!]\(.*?\)|\[|\]/;class M{options;set;pattern;windowsPathsNoEscape;nonegate;negate;comment;empty;preserveMultipleSlashes;partial;globSet;globParts;nocase;isWindows;platform;windowsNoMagicRoot;regexp;constructor(t,e={}){(0,n.assertValidPattern)(t),e=e||{},this.options=e,this.pattern=t,this.platform=e.platform||x,this.isWindows="win32"===this.platform,this.windowsPathsNoEscape=!!e.windowsPathsNoEscape||!1===e.allowWindowsEscape,this.windowsPathsNoEscape&&(this.pattern=this.pattern.replace(/\\/g,"/")),this.preserveMultipleSlashes=!!e.preserveMultipleSlashes,this.regexp=null,this.negate=!1,this.nonegate=!!e.nonegate,this.comment=!1,this.empty=!1,this.partial=!!e.partial,this.nocase=!!this.options.nocase,this.windowsNoMagicRoot=void 0!==e.windowsNoMagicRoot?e.windowsNoMagicRoot:!(!this.isWindows||!this.nocase),this.globSet=[],this.globParts=[],this.set=[],this.make()}hasMagic(){if(this.options.magicalBraces&&this.set.length>1)return!0;for(const t of this.set)for(const e of t)if("string"!=typeof e)return!0;return!1}debug(...t){}make(){const t=this.pattern,e=this.options;if(!e.nocomment&&"#"===t.charAt(0))return void(this.comment=!0);if(!t)return void(this.empty=!0);this.parseNegate(),this.globSet=[...new Set(this.braceExpand())],e.debug&&(this.debug=(...t)=>console.error(...t)),this.debug(this.pattern,this.globSet);const r=this.globSet.map(t=>this.slashSplit(t));this.globParts=this.preprocess(r),this.debug(this.pattern,this.globParts);let n=this.globParts.map((t,e,r)=>{if(this.isWindows&&this.windowsNoMagicRoot){const e=!(""!==t[0]||""!==t[1]||"?"!==t[2]&&j.test(t[2])||j.test(t[3])),r=/^[a-z]:/i.test(t[0]);if(e)return[...t.slice(0,4),...t.slice(4).map(t=>this.parse(t))];if(r)return[t[0],...t.slice(1).map(t=>this.parse(t))]}return t.map(t=>this.parse(t))});if(this.debug(this.pattern,n),this.set=n.filter(t=>-1===t.indexOf(!1)),this.isWindows)for(let t=0;t<this.set.length;t++){const e=this.set[t];""===e[0]&&""===e[1]&&"?"===this.globParts[t][2]&&"string"==typeof e[3]&&/^[a-z]:$/i.test(e[3])&&(e[2]="?")}this.debug(this.pattern,this.set)}preprocess(t){if(this.options.noglobstar)for(let e=0;e<t.length;e++)for(let r=0;r<t[e].length;r++)"**"===t[e][r]&&(t[e][r]="*");const{optimizationLevel:e=1}=this.options;return e>=2?(t=this.firstPhasePreProcess(t),t=this.secondPhasePreProcess(t)):t=e>=1?this.levelOneOptimize(t):this.adjascentGlobstarOptimize(t),t}adjascentGlobstarOptimize(t){return t.map(t=>{let e=-1;for(;-1!==(e=t.indexOf("**",e+1));){let r=e;for(;"**"===t[r+1];)r++;r!==e&&t.splice(e,r-e)}return t})}levelOneOptimize(t){return t.map(t=>0===(t=t.reduce((t,e)=>{const r=t[t.length-1];return"**"===e&&"**"===r?t:".."===e&&r&&".."!==r&&"."!==r&&"**"!==r?(t.pop(),t):(t.push(e),t)},[])).length?[""]:t)}levelTwoFileOptimize(t){Array.isArray(t)||(t=this.slashSplit(t));let e=!1;do{if(e=!1,!this.preserveMultipleSlashes){for(let r=1;r<t.length-1;r++){const n=t[r];1===r&&""===n&&""===t[0]||("."!==n&&""!==n||(e=!0,t.splice(r,1),r--))}"."!==t[0]||2!==t.length||"."!==t[1]&&""!==t[1]||(e=!0,t.pop())}let r=0;for(;-1!==(r=t.indexOf("..",r+1));){const n=t[r-1];n&&"."!==n&&".."!==n&&"**"!==n&&(e=!0,t.splice(r-1,2),r-=2)}}while(e);return 0===t.length?[""]:t}firstPhasePreProcess(t){let e=!1;do{e=!1;for(let r of t){let n=-1;for(;-1!==(n=r.indexOf("**",n+1));){let i=n;for(;"**"===r[i+1];)i++;i>n&&r.splice(n+1,i-n);let o=r[n+1];const s=r[n+2],a=r[n+3];if(".."!==o)continue;if(!s||"."===s||".."===s||!a||"."===a||".."===a)continue;e=!0,r.splice(n,1);const l=r.slice(0);l[n]="**",t.push(l),n--}if(!this.preserveMultipleSlashes){for(let t=1;t<r.length-1;t++){const n=r[t];1===t&&""===n&&""===r[0]||("."!==n&&""!==n||(e=!0,r.splice(t,1),t--))}"."!==r[0]||2!==r.length||"."!==r[1]&&""!==r[1]||(e=!0,r.pop())}let i=0;for(;-1!==(i=r.indexOf("..",i+1));){const t=r[i-1];if(t&&"."!==t&&".."!==t&&"**"!==t){e=!0;const t=1===i&&"**"===r[i+1]?["."]:[];r.splice(i-1,2,...t),0===r.length&&r.push(""),i-=2}}}}while(e);return t}secondPhasePreProcess(t){for(let e=0;e<t.length-1;e++)for(let r=e+1;r<t.length;r++){const n=this.partsMatch(t[e],t[r],!this.preserveMultipleSlashes);if(n){t[e]=[],t[r]=n;break}}return t.filter(t=>t.length)}partsMatch(t,e,r=!1){let n=0,i=0,o=[],s="";for(;n<t.length&&i<e.length;)if(t[n]===e[i])o.push("b"===s?e[i]:t[n]),n++,i++;else if(r&&"**"===t[n]&&e[i]===t[n+1])o.push(t[n]),n++;else if(r&&"**"===e[i]&&t[n]===e[i+1])o.push(e[i]),i++;else if("*"!==t[n]||!e[i]||!this.options.dot&&e[i].startsWith(".")||"**"===e[i]){if("*"!==e[i]||!t[n]||!this.options.dot&&t[n].startsWith(".")||"**"===t[n])return!1;if("a"===s)return!1;s="b",o.push(e[i]),n++,i++}else{if("b"===s)return!1;s="a",o.push(t[n]),n++,i++}return t.length===e.length&&o}parseNegate(){if(this.nonegate)return;const t=this.pattern;let e=!1,r=0;for(let n=0;n<t.length&&"!"===t.charAt(n);n++)e=!e,r++;r&&(this.pattern=t.slice(r)),this.negate=e}matchOne(e,r,n=!1){const i=this.options;if(this.isWindows){const t="string"==typeof e[0]&&/^[a-z]:$/i.test(e[0]),n=!t&&""===e[0]&&""===e[1]&&"?"===e[2]&&/^[a-z]:$/i.test(e[3]),i="string"==typeof r[0]&&/^[a-z]:$/i.test(r[0]),o=n?3:t?0:void 0,s=!i&&""===r[0]&&""===r[1]&&"?"===r[2]&&"string"==typeof r[3]&&/^[a-z]:$/i.test(r[3])?3:i?0:void 0;if("number"==typeof o&&"number"==typeof s){const[t,n]=[e[o],r[s]];t.toLowerCase()===n.toLowerCase()&&(r[s]=t,s>o?r=r.slice(s):o>s&&(e=e.slice(o)))}}const{optimizationLevel:o=1}=this.options;o>=2&&(e=this.levelTwoFileOptimize(e)),this.debug("matchOne",this,{file:e,pattern:r}),this.debug("matchOne",e.length,r.length);for(var s=0,a=0,l=e.length,u=r.length;s<l&&a<u;s++,a++){this.debug("matchOne loop");var c=r[a],h=e[s];if(this.debug(r,c,h),!1===c)return!1;if(c===t.GLOBSTAR){this.debug("GLOBSTAR",[r,c,h]);var f=s,d=a+1;if(d===u){for(this.debug("** at the end");s<l;s++)if("."===e[s]||".."===e[s]||!i.dot&&"."===e[s].charAt(0))return!1;return!0}for(;f<l;){var p=e[f];if(this.debug("\nglobstar while",e,f,r,d,p),this.matchOne(e.slice(f),r.slice(d),n))return this.debug("globstar found match!",f,l,p),!0;if("."===p||".."===p||!i.dot&&"."===p.charAt(0)){this.debug("dot detected!",e,f,r,d);break}this.debug("globstar swallow a segment, and continue"),f++}return!(!n||(this.debug("\n>>> no match, partial?",e,f,r,d),f!==l))}let o;if("string"==typeof c?(o=h===c,this.debug("string match",c,h,o)):(o=c.test(h),this.debug("pattern match",c,h,o)),!o)return!1}if(s===l&&a===u)return!0;if(s===l)return n;if(a===u)return s===l-1&&""===e[s];throw new Error("wtf?")}braceExpand(){return(0,t.braceExpand)(this.pattern,this.options)}parse(e){(0,n.assertValidPattern)(e);const r=this.options;if("**"===e)return t.GLOBSTAR;if(""===e)return"";let o,s=null;(o=e.match(b))?s=r.dot?_:m:(o=e.match(a))?s=(r.nocase?r.dot?h:c:r.dot?u:l)(o[1]):(o=e.match(v))?s=(r.nocase?r.dot?S:w:r.dot?E:R)(o):(o=e.match(f))?s=r.dot?p:d:(o=e.match(y))&&(s=g);const k=i.AST.fromGlob(e,this.options).toMMPattern();return s&&"object"==typeof k&&Reflect.defineProperty(k,"test",{value:s}),k}makeRe(){if(this.regexp||!1===this.regexp)return this.regexp;const e=this.set;if(!e.length)return this.regexp=!1,this.regexp;const r=this.options,n=r.noglobstar?"[^/]*?":r.dot?"(?:(?!(?:\\/|^)(?:\\.{1,2})($|\\/)).)*?":"(?:(?!(?:\\/|^)\\.).)*?",i=new Set(r.nocase?["i"]:[]);let o=e.map(e=>{const r=e.map(e=>{if(e instanceof RegExp)for(const t of e.flags.split(""))i.add(t);return"string"==typeof e?e.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&"):e===t.GLOBSTAR?t.GLOBSTAR:e._src});return r.forEach((e,i)=>{const o=r[i+1],s=r[i-1];e===t.GLOBSTAR&&s!==t.GLOBSTAR&&(void 0===s?void 0!==o&&o!==t.GLOBSTAR?r[i+1]="(?:\\/|"+n+"\\/)?"+o:r[i]=n:void 0===o?r[i-1]=s+"(?:\\/|"+n+")?":o!==t.GLOBSTAR&&(r[i-1]=s+"(?:\\/|\\/"+n+"\\/)"+o,r[i+1]=t.GLOBSTAR))}),r.filter(e=>e!==t.GLOBSTAR).join("/")}).join("|");const[s,a]=e.length>1?["(?:",")"]:["",""];o="^"+s+o+a+"$",this.negate&&(o="^(?!"+o+").+$");try{this.regexp=new RegExp(o,[...i].join(""))}catch(t){this.regexp=!1}return this.regexp}slashSplit(t){return this.preserveMultipleSlashes?t.split("/"):this.isWindows&&/^\/\/[^\/]+/.test(t)?["",...t.split(/\/+/)]:t.split(/\/+/)}match(t,e=this.partial){if(this.debug("match",t,this.pattern),this.comment)return!1;if(this.empty)return""===t;if("/"===t&&e)return!0;const r=this.options;this.isWindows&&(t=t.split("\\").join("/"));const n=this.slashSplit(t);this.debug(this.pattern,"split",n);const i=this.set;this.debug(this.pattern,"set",i);let o=n[n.length-1];if(!o)for(let t=n.length-2;!o&&t>=0;t--)o=n[t];for(let t=0;t<i.length;t++){const s=i[t];let a=n;r.matchBase&&1===s.length&&(a=[o]);if(this.matchOne(a,s,e))return!!r.flipNegate||!this.negate}return!r.flipNegate&&this.negate}static defaults(e){return t.minimatch.defaults(e).Minimatch}}t.Minimatch=M;var I=f_;Object.defineProperty(t,"AST",{enumerable:!0,get:function(){return I.AST}});var P=j_;Object.defineProperty(t,"escape",{enumerable:!0,get:function(){return P.escape}});var D=b_;Object.defineProperty(t,"unescape",{enumerable:!0,get:function(){return D.unescape}}),t.minimatch.AST=i.AST,t.minimatch.Minimatch=M,t.minimatch.escape=o.escape,t.minimatch.unescape=s.unescape}(Ym);var M_={},I_={},P_={};Object.defineProperty(P_,"__esModule",{value:!0}),P_.LRUCache=void 0;const D_="object"==typeof performance&&performance&&"function"==typeof performance.now?performance:Date,C_=new Set,N_="object"==typeof process&&process?process:{},F_=(t,e,r,n)=>{"function"==typeof N_.emitWarning?N_.emitWarning(t,e,r,n):console.error(`[${r}] ${e}: ${t}`)};let B_=globalThis.AbortController,W_=globalThis.AbortSignal;if(void 0===B_){W_=class{onabort;_onabort=[];reason;aborted=!1;addEventListener(t,e){this._onabort.push(e)}},B_=class{constructor(){e()}signal=new W_;abort(t){if(!this.signal.aborted){this.signal.reason=t,this.signal.aborted=!0;for(const e of this.signal._onabort)e(t);this.signal.onabort?.(t)}}};let t="1"!==N_.env?.LRU_CACHE_IGNORE_AC_WARNING;const e=()=>{t&&(t=!1,F_("AbortController is not defined. If using lru-cache in node 14, load an AbortController polyfill from the `node-abort-controller` package. A minimal polyfill is provided for use by LRUCache.fetch(), but it should not be relied upon in other contexts (eg, passing it to other APIs that use AbortController/AbortSignal might have undesirable effects). You may disable this with LRU_CACHE_IGNORE_AC_WARNING=1 in the env.","NO_ABORT_CONTROLLER","ENOTSUP",e))}}const U_=t=>t&&t===Math.floor(t)&&t>0&&isFinite(t),z_=t=>U_(t)?t<=Math.pow(2,8)?Uint8Array:t<=Math.pow(2,16)?Uint16Array:t<=Math.pow(2,32)?Uint32Array:t<=Number.MAX_SAFE_INTEGER?$_:null:null;class $_ extends Array{constructor(t){super(t),this.fill(0)}}class H_{heap;length;static#y=!1;static create(t){const e=z_(t);if(!e)return[];H_.#y=!0;const r=new H_(t,e);return H_.#y=!1,r}constructor(t,e){if(!H_.#y)throw new TypeError("instantiate Stack using Stack.create(n)");this.heap=new e(t),this.length=0}push(t){this.heap[this.length++]=t}pop(){return this.heap[--this.length]}}class G_{#g;#b;#m;#_;#v;#w;ttl;ttlResolution;ttlAutopurge;updateAgeOnGet;updateAgeOnHas;allowStale;noDisposeOnSet;noUpdateTTL;maxEntrySize;sizeCalculation;noDeleteOnFetchRejection;noDeleteOnStaleGet;allowStaleOnFetchAbort;allowStaleOnFetchRejection;ignoreFetchAbort;#S;#E;#R;#k;#T;#x;#A;#O;#L;#j;#M;#I;#P;#D;#C;#N;#F;static unsafeExposeInternals(t){return{starts:t.#P,ttls:t.#D,sizes:t.#I,keyMap:t.#R,keyList:t.#k,valList:t.#T,next:t.#x,prev:t.#A,get head(){return t.#O},get tail(){return t.#L},free:t.#j,isBackgroundFetch:e=>t.#B(e),backgroundFetch:(e,r,n,i)=>t.#W(e,r,n,i),moveToTail:e=>t.#U(e),indexes:e=>t.#z(e),rindexes:e=>t.#$(e),isStale:e=>t.#H(e)}}get max(){return this.#g}get maxSize(){return this.#b}get calculatedSize(){return this.#E}get size(){return this.#S}get fetchMethod(){return this.#v}get memoMethod(){return this.#w}get dispose(){return this.#m}get disposeAfter(){return this.#_}constructor(t){const{max:e=0,ttl:r,ttlResolution:n=1,ttlAutopurge:i,updateAgeOnGet:o,updateAgeOnHas:s,allowStale:a,dispose:l,disposeAfter:u,noDisposeOnSet:c,noUpdateTTL:h,maxSize:f=0,maxEntrySize:d=0,sizeCalculation:p,fetchMethod:y,memoMethod:g,noDeleteOnFetchRejection:b,noDeleteOnStaleGet:m,allowStaleOnFetchRejection:_,allowStaleOnFetchAbort:v,ignoreFetchAbort:w}=t;if(0!==e&&!U_(e))throw new TypeError("max option must be a nonnegative integer");const S=e?z_(e):Array;if(!S)throw new Error("invalid max value: "+e);if(this.#g=e,this.#b=f,this.maxEntrySize=d||this.#b,this.sizeCalculation=p,this.sizeCalculation){if(!this.#b&&!this.maxEntrySize)throw new TypeError("cannot set sizeCalculation without setting maxSize or maxEntrySize");if("function"!=typeof this.sizeCalculation)throw new TypeError("sizeCalculation set to non-function")}if(void 0!==g&&"function"!=typeof g)throw new TypeError("memoMethod must be a function if defined");if(this.#w=g,void 0!==y&&"function"!=typeof y)throw new TypeError("fetchMethod must be a function if specified");if(this.#v=y,this.#N=!!y,this.#R=new Map,this.#k=new Array(e).fill(void 0),this.#T=new Array(e).fill(void 0),this.#x=new S(e),this.#A=new S(e),this.#O=0,this.#L=0,this.#j=H_.create(e),this.#S=0,this.#E=0,"function"==typeof l&&(this.#m=l),"function"==typeof u?(this.#_=u,this.#M=[]):(this.#_=void 0,this.#M=void 0),this.#C=!!this.#m,this.#F=!!this.#_,this.noDisposeOnSet=!!c,this.noUpdateTTL=!!h,this.noDeleteOnFetchRejection=!!b,this.allowStaleOnFetchRejection=!!_,this.allowStaleOnFetchAbort=!!v,this.ignoreFetchAbort=!!w,0!==this.maxEntrySize){if(0!==this.#b&&!U_(this.#b))throw new TypeError("maxSize must be a positive integer if specified");if(!U_(this.maxEntrySize))throw new TypeError("maxEntrySize must be a positive integer if specified");this.#G()}if(this.allowStale=!!a,this.noDeleteOnStaleGet=!!m,this.updateAgeOnGet=!!o,this.updateAgeOnHas=!!s,this.ttlResolution=U_(n)||0===n?n:1,this.ttlAutopurge=!!i,this.ttl=r||0,this.ttl){if(!U_(this.ttl))throw new TypeError("ttl must be a positive integer if specified");this.#q()}if(0===this.#g&&0===this.ttl&&0===this.#b)throw new TypeError("At least one of max, maxSize, or ttl is required");if(!this.ttlAutopurge&&!this.#g&&!this.#b){const t="LRU_CACHE_UNBOUNDED";if((t=>!C_.has(t))(t)){C_.add(t);F_("TTL caching without ttlAutopurge, max, or maxSize can result in unbounded memory consumption.","UnboundedCacheWarning",t,G_)}}}getRemainingTTL(t){return this.#R.has(t)?1/0:0}#q(){const t=new $_(this.#g),e=new $_(this.#g);this.#D=t,this.#P=e,this.#V=(r,n,i=D_.now())=>{if(e[r]=0!==n?i:0,t[r]=n,0!==n&&this.ttlAutopurge){const t=setTimeout(()=>{this.#H(r)&&this.#Z(this.#k[r],"expire")},n+1);t.unref&&t.unref()}},this.#Y=r=>{e[r]=0!==t[r]?D_.now():0},this.#K=(i,o)=>{if(t[o]){const s=t[o],a=e[o];if(!s||!a)return;i.ttl=s,i.start=a,i.now=r||n();const l=i.now-a;i.remainingTTL=s-l}};let r=0;const n=()=>{const t=D_.now();if(this.ttlResolution>0){r=t;const e=setTimeout(()=>r=0,this.ttlResolution);e.unref&&e.unref()}return t};this.getRemainingTTL=i=>{const o=this.#R.get(i);if(void 0===o)return 0;const s=t[o],a=e[o];if(!s||!a)return 1/0;return s-((r||n())-a)},this.#H=i=>{const o=e[i],s=t[i];return!!s&&!!o&&(r||n())-o>s}}#Y=()=>{};#K=()=>{};#V=()=>{};#H=()=>!1;#G(){const t=new $_(this.#g);this.#E=0,this.#I=t,this.#Q=e=>{this.#E-=t[e],t[e]=0},this.#J=(t,e,r,n)=>{if(this.#B(e))return 0;if(!U_(r)){if(!n)throw new TypeError("invalid size value (must be positive integer). When maxSize or maxEntrySize is used, sizeCalculation or size must be set.");if("function"!=typeof n)throw new TypeError("sizeCalculation must be a function");if(r=n(e,t),!U_(r))throw new TypeError("sizeCalculation return invalid (expect positive integer)")}return r},this.#X=(e,r,n)=>{if(t[e]=r,this.#b){const r=this.#b-t[e];for(;this.#E>r;)this.#tt(!0)}this.#E+=t[e],n&&(n.entrySize=r,n.totalCalculatedSize=this.#E)}}#Q=t=>{};#X=(t,e,r)=>{};#J=(t,e,r,n)=>{if(r||n)throw new TypeError("cannot set size without setting maxSize or maxEntrySize on cache");return 0};*#z({allowStale:t=this.allowStale}={}){if(this.#S)for(let e=this.#L;this.#et(e)&&(!t&&this.#H(e)||(yield e),e!==this.#O);)e=this.#A[e]}*#$({allowStale:t=this.allowStale}={}){if(this.#S)for(let e=this.#O;this.#et(e)&&(!t&&this.#H(e)||(yield e),e!==this.#L);)e=this.#x[e]}#et(t){return void 0!==t&&this.#R.get(this.#k[t])===t}*entries(){for(const t of this.#z())void 0===this.#T[t]||void 0===this.#k[t]||this.#B(this.#T[t])||(yield[this.#k[t],this.#T[t]])}*rentries(){for(const t of this.#$())void 0===this.#T[t]||void 0===this.#k[t]||this.#B(this.#T[t])||(yield[this.#k[t],this.#T[t]])}*keys(){for(const t of this.#z()){const e=this.#k[t];void 0===e||this.#B(this.#T[t])||(yield e)}}*rkeys(){for(const t of this.#$()){const e=this.#k[t];void 0===e||this.#B(this.#T[t])||(yield e)}}*values(){for(const t of this.#z()){void 0===this.#T[t]||this.#B(this.#T[t])||(yield this.#T[t])}}*rvalues(){for(const t of this.#$()){void 0===this.#T[t]||this.#B(this.#T[t])||(yield this.#T[t])}}[Symbol.iterator](){return this.entries()}[Symbol.toStringTag]="LRUCache";find(t,e={}){for(const r of this.#z()){const n=this.#T[r],i=this.#B(n)?n.__staleWhileFetching:n;if(void 0!==i&&t(i,this.#k[r],this))return this.get(this.#k[r],e)}}forEach(t,e=this){for(const r of this.#z()){const n=this.#T[r],i=this.#B(n)?n.__staleWhileFetching:n;void 0!==i&&t.call(e,i,this.#k[r],this)}}rforEach(t,e=this){for(const r of this.#$()){const n=this.#T[r],i=this.#B(n)?n.__staleWhileFetching:n;void 0!==i&&t.call(e,i,this.#k[r],this)}}purgeStale(){let t=!1;for(const e of this.#$({allowStale:!0}))this.#H(e)&&(this.#Z(this.#k[e],"expire"),t=!0);return t}info(t){const e=this.#R.get(t);if(void 0===e)return;const r=this.#T[e],n=this.#B(r)?r.__staleWhileFetching:r;if(void 0===n)return;const i={value:n};if(this.#D&&this.#P){const t=this.#D[e],r=this.#P[e];if(t&&r){const e=t-(D_.now()-r);i.ttl=e,i.start=Date.now()}}return this.#I&&(i.size=this.#I[e]),i}dump(){const t=[];for(const e of this.#z({allowStale:!0})){const r=this.#k[e],n=this.#T[e],i=this.#B(n)?n.__staleWhileFetching:n;if(void 0===i||void 0===r)continue;const o={value:i};if(this.#D&&this.#P){o.ttl=this.#D[e];const t=D_.now()-this.#P[e];o.start=Math.floor(Date.now()-t)}this.#I&&(o.size=this.#I[e]),t.unshift([r,o])}return t}load(t){this.clear();for(const[e,r]of t){if(r.start){const t=Date.now()-r.start;r.start=D_.now()-t}this.set(e,r.value,r)}}set(t,e,r={}){if(void 0===e)return this.delete(t),this;const{ttl:n=this.ttl,start:i,noDisposeOnSet:o=this.noDisposeOnSet,sizeCalculation:s=this.sizeCalculation,status:a}=r;let{noUpdateTTL:l=this.noUpdateTTL}=r;const u=this.#J(t,e,r.size||0,s);if(this.maxEntrySize&&u>this.maxEntrySize)return a&&(a.set="miss",a.maxEntrySizeExceeded=!0),this.#Z(t,"set"),this;let c=0===this.#S?void 0:this.#R.get(t);if(void 0===c)c=0===this.#S?this.#L:0!==this.#j.length?this.#j.pop():this.#S===this.#g?this.#tt(!1):this.#S,this.#k[c]=t,this.#T[c]=e,this.#R.set(t,c),this.#x[this.#L]=c,this.#A[c]=this.#L,this.#L=c,this.#S++,this.#X(c,u,a),a&&(a.set="add"),l=!1;else{this.#U(c);const r=this.#T[c];if(e!==r){if(this.#N&&this.#B(r)){r.__abortController.abort(new Error("replaced"));const{__staleWhileFetching:e}=r;void 0===e||o||(this.#C&&this.#m?.(e,t,"set"),this.#F&&this.#M?.push([e,t,"set"]))}else o||(this.#C&&this.#m?.(r,t,"set"),this.#F&&this.#M?.push([r,t,"set"]));if(this.#Q(c),this.#X(c,u,a),this.#T[c]=e,a){a.set="replace";const t=r&&this.#B(r)?r.__staleWhileFetching:r;void 0!==t&&(a.oldValue=t)}}else a&&(a.set="update")}if(0===n||this.#D||this.#q(),this.#D&&(l||this.#V(c,n,i),a&&this.#K(a,c)),!o&&this.#F&&this.#M){const t=this.#M;let e;for(;e=t?.shift();)this.#_?.(...e)}return this}pop(){try{for(;this.#S;){const t=this.#T[this.#O];if(this.#tt(!0),this.#B(t)){if(t.__staleWhileFetching)return t.__staleWhileFetching}else if(void 0!==t)return t}}finally{if(this.#F&&this.#M){const t=this.#M;let e;for(;e=t?.shift();)this.#_?.(...e)}}}#tt(t){const e=this.#O,r=this.#k[e],n=this.#T[e];return this.#N&&this.#B(n)?n.__abortController.abort(new Error("evicted")):(this.#C||this.#F)&&(this.#C&&this.#m?.(n,r,"evict"),this.#F&&this.#M?.push([n,r,"evict"])),this.#Q(e),t&&(this.#k[e]=void 0,this.#T[e]=void 0,this.#j.push(e)),1===this.#S?(this.#O=this.#L=0,this.#j.length=0):this.#O=this.#x[e],this.#R.delete(r),this.#S--,e}has(t,e={}){const{updateAgeOnHas:r=this.updateAgeOnHas,status:n}=e,i=this.#R.get(t);if(void 0!==i){const t=this.#T[i];if(this.#B(t)&&void 0===t.__staleWhileFetching)return!1;if(!this.#H(i))return r&&this.#Y(i),n&&(n.has="hit",this.#K(n,i)),!0;n&&(n.has="stale",this.#K(n,i))}else n&&(n.has="miss");return!1}peek(t,e={}){const{allowStale:r=this.allowStale}=e,n=this.#R.get(t);if(void 0===n||!r&&this.#H(n))return;const i=this.#T[n];return this.#B(i)?i.__staleWhileFetching:i}#W(t,e,r,n){const i=void 0===e?void 0:this.#T[e];if(this.#B(i))return i;const o=new B_,{signal:s}=r;s?.addEventListener("abort",()=>o.abort(s.reason),{signal:o.signal});const a={signal:o.signal,options:r,context:n},l=(n,i=!1)=>{const{aborted:s}=o.signal,l=r.ignoreFetchAbort&&void 0!==n;if(r.status&&(s&&!i?(r.status.fetchAborted=!0,r.status.fetchError=o.signal.reason,l&&(r.status.fetchAbortIgnored=!0)):r.status.fetchResolved=!0),s&&!l&&!i)return u(o.signal.reason);const h=c;return this.#T[e]===c&&(void 0===n?h.__staleWhileFetching?this.#T[e]=h.__staleWhileFetching:this.#Z(t,"fetch"):(r.status&&(r.status.fetchUpdated=!0),this.set(t,n,a.options))),n},u=n=>{const{aborted:i}=o.signal,s=i&&r.allowStaleOnFetchAbort,a=s||r.allowStaleOnFetchRejection,l=a||r.noDeleteOnFetchRejection,u=c;if(this.#T[e]===c){!l||void 0===u.__staleWhileFetching?this.#Z(t,"fetch"):s||(this.#T[e]=u.__staleWhileFetching)}if(a)return r.status&&void 0!==u.__staleWhileFetching&&(r.status.returnedStale=!0),u.__staleWhileFetching;if(u.__returned===u)throw n};r.status&&(r.status.fetchDispatched=!0);const c=new Promise((e,n)=>{const s=this.#v?.(t,i,a);s&&s instanceof Promise&&s.then(t=>e(void 0===t?void 0:t),n),o.signal.addEventListener("abort",()=>{r.ignoreFetchAbort&&!r.allowStaleOnFetchAbort||(e(void 0),r.allowStaleOnFetchAbort&&(e=t=>l(t,!0)))})}).then(l,t=>(r.status&&(r.status.fetchRejected=!0,r.status.fetchError=t),u(t))),h=Object.assign(c,{__abortController:o,__staleWhileFetching:i,__returned:void 0});return void 0===e?(this.set(t,h,{...a.options,status:void 0}),e=this.#R.get(t)):this.#T[e]=h,h}#B(t){if(!this.#N)return!1;const e=t;return!!e&&e instanceof Promise&&e.hasOwnProperty("__staleWhileFetching")&&e.__abortController instanceof B_}async fetch(t,e={}){const{allowStale:r=this.allowStale,updateAgeOnGet:n=this.updateAgeOnGet,noDeleteOnStaleGet:i=this.noDeleteOnStaleGet,ttl:o=this.ttl,noDisposeOnSet:s=this.noDisposeOnSet,size:a=0,sizeCalculation:l=this.sizeCalculation,noUpdateTTL:u=this.noUpdateTTL,noDeleteOnFetchRejection:c=this.noDeleteOnFetchRejection,allowStaleOnFetchRejection:h=this.allowStaleOnFetchRejection,ignoreFetchAbort:f=this.ignoreFetchAbort,allowStaleOnFetchAbort:d=this.allowStaleOnFetchAbort,context:p,forceRefresh:y=!1,status:g,signal:b}=e;if(!this.#N)return g&&(g.fetch="get"),this.get(t,{allowStale:r,updateAgeOnGet:n,noDeleteOnStaleGet:i,status:g});const m={allowStale:r,updateAgeOnGet:n,noDeleteOnStaleGet:i,ttl:o,noDisposeOnSet:s,size:a,sizeCalculation:l,noUpdateTTL:u,noDeleteOnFetchRejection:c,allowStaleOnFetchRejection:h,allowStaleOnFetchAbort:d,ignoreFetchAbort:f,status:g,signal:b};let _=this.#R.get(t);if(void 0===_){g&&(g.fetch="miss");const e=this.#W(t,_,m,p);return e.__returned=e}{const e=this.#T[_];if(this.#B(e)){const t=r&&void 0!==e.__staleWhileFetching;return g&&(g.fetch="inflight",t&&(g.returnedStale=!0)),t?e.__staleWhileFetching:e.__returned=e}const i=this.#H(_);if(!y&&!i)return g&&(g.fetch="hit"),this.#U(_),n&&this.#Y(_),g&&this.#K(g,_),e;const o=this.#W(t,_,m,p),s=void 0!==o.__staleWhileFetching&&r;return g&&(g.fetch=i?"stale":"refresh",s&&i&&(g.returnedStale=!0)),s?o.__staleWhileFetching:o.__returned=o}}async forceFetch(t,e={}){const r=await this.fetch(t,e);if(void 0===r)throw new Error("fetch() returned undefined");return r}memo(t,e={}){const r=this.#w;if(!r)throw new Error("no memoMethod provided to constructor");const{context:n,forceRefresh:i,...o}=e,s=this.get(t,o);if(!i&&void 0!==s)return s;const a=r(t,s,{options:o,context:n});return this.set(t,a,o),a}get(t,e={}){const{allowStale:r=this.allowStale,updateAgeOnGet:n=this.updateAgeOnGet,noDeleteOnStaleGet:i=this.noDeleteOnStaleGet,status:o}=e,s=this.#R.get(t);if(void 0!==s){const e=this.#T[s],a=this.#B(e);return o&&this.#K(o,s),this.#H(s)?(o&&(o.get="stale"),a?(o&&r&&void 0!==e.__staleWhileFetching&&(o.returnedStale=!0),r?e.__staleWhileFetching:void 0):(i||this.#Z(t,"expire"),o&&r&&(o.returnedStale=!0),r?e:void 0)):(o&&(o.get="hit"),a?e.__staleWhileFetching:(this.#U(s),n&&this.#Y(s),e))}o&&(o.get="miss")}#rt(t,e){this.#A[e]=t,this.#x[t]=e}#U(t){t!==this.#L&&(t===this.#O?this.#O=this.#x[t]:this.#rt(this.#A[t],this.#x[t]),this.#rt(this.#L,t),this.#L=t)}delete(t){return this.#Z(t,"delete")}#Z(t,e){let r=!1;if(0!==this.#S){const n=this.#R.get(t);if(void 0!==n)if(r=!0,1===this.#S)this.#nt(e);else{this.#Q(n);const r=this.#T[n];if(this.#B(r)?r.__abortController.abort(new Error("deleted")):(this.#C||this.#F)&&(this.#C&&this.#m?.(r,t,e),this.#F&&this.#M?.push([r,t,e])),this.#R.delete(t),this.#k[n]=void 0,this.#T[n]=void 0,n===this.#L)this.#L=this.#A[n];else if(n===this.#O)this.#O=this.#x[n];else{const t=this.#A[n];this.#x[t]=this.#x[n];const e=this.#x[n];this.#A[e]=this.#A[n]}this.#S--,this.#j.push(n)}}if(this.#F&&this.#M?.length){const t=this.#M;let e;for(;e=t?.shift();)this.#_?.(...e)}return r}clear(){return this.#nt("delete")}#nt(t){for(const e of this.#$({allowStale:!0})){const r=this.#T[e];if(this.#B(r))r.__abortController.abort(new Error("deleted"));else{const n=this.#k[e];this.#C&&this.#m?.(r,n,t),this.#F&&this.#M?.push([r,n,t])}}if(this.#R.clear(),this.#T.fill(void 0),this.#k.fill(void 0),this.#D&&this.#P&&(this.#D.fill(0),this.#P.fill(0)),this.#I&&this.#I.fill(0),this.#O=0,this.#L=0,this.#j.length=0,this.#E=0,this.#S=0,this.#F&&this.#M){const t=this.#M;let e;for(;e=t?.shift();)this.#_?.(...e)}}}P_.LRUCache=G_;var q_={};!function(t){var e=Ft&&Ft.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(t,"__esModule",{value:!0}),t.Minipass=t.isWritable=t.isReadable=t.isStream=void 0;const r="object"==typeof process&&process?process:{stdout:null,stderr:null},n=f,i=e(d),o=p;t.isStream=e=>!!e&&"object"==typeof e&&(e instanceof H||e instanceof i.default||(0,t.isReadable)(e)||(0,t.isWritable)(e));t.isReadable=t=>!!t&&"object"==typeof t&&t instanceof n.EventEmitter&&"function"==typeof t.pipe&&t.pipe!==i.default.Writable.prototype.pipe;t.isWritable=t=>!!t&&"object"==typeof t&&t instanceof n.EventEmitter&&"function"==typeof t.write&&"function"==typeof t.end;const s=Symbol("EOF"),a=Symbol("maybeEmitEnd"),l=Symbol("emittedEnd"),u=Symbol("emittingEnd"),c=Symbol("emittedError"),h=Symbol("closed"),y=Symbol("read"),g=Symbol("flush"),b=Symbol("flushChunk"),m=Symbol("encoding"),_=Symbol("decoder"),v=Symbol("flowing"),w=Symbol("paused"),S=Symbol("resume"),E=Symbol("buffer"),R=Symbol("pipes"),k=Symbol("bufferLength"),T=Symbol("bufferPush"),x=Symbol("bufferShift"),A=Symbol("objectMode"),O=Symbol("destroyed"),L=Symbol("error"),j=Symbol("emitData"),M=Symbol("emitEnd"),I=Symbol("emitEnd2"),P=Symbol("async"),D=Symbol("abort"),C=Symbol("aborted"),N=Symbol("signal"),F=Symbol("dataListeners"),B=Symbol("discarded"),W=t=>Promise.resolve().then(t),U=t=>t();class z{src;dest;opts;ondrain;constructor(t,e,r){this.src=t,this.dest=e,this.opts=r,this.ondrain=()=>t[S](),this.dest.on("drain",this.ondrain)}unpipe(){this.dest.removeListener("drain",this.ondrain)}proxyErrors(t){}end(){this.unpipe(),this.opts.end&&this.dest.end()}}class $ extends z{unpipe(){this.src.removeListener("error",this.proxyErrors),super.unpipe()}constructor(t,e,r){super(t,e,r),this.proxyErrors=t=>e.emit("error",t),t.on("error",this.proxyErrors)}}class H extends n.EventEmitter{[v]=!1;[w]=!1;[R]=[];[E]=[];[A];[m];[P];[_];[s]=!1;[l]=!1;[u]=!1;[h]=!1;[c]=null;[k]=0;[O]=!1;[N];[C]=!1;[F]=0;[B]=!1;writable=!0;readable=!0;constructor(...t){const e=t[0]||{};if(super(),e.objectMode&&"string"==typeof e.encoding)throw new TypeError("Encoding and objectMode may not be used together");e.objectMode?(this[A]=!0,this[m]=null):(t=>!t.objectMode&&!!t.encoding&&"buffer"!==t.encoding)(e)?(this[m]=e.encoding,this[A]=!1):(this[A]=!1,this[m]=null),this[P]=!!e.async,this[_]=this[m]?new o.StringDecoder(this[m]):null,e&&!0===e.debugExposeBuffer&&Object.defineProperty(this,"buffer",{get:()=>this[E]}),e&&!0===e.debugExposePipes&&Object.defineProperty(this,"pipes",{get:()=>this[R]});const{signal:r}=e;r&&(this[N]=r,r.aborted?this[D]():r.addEventListener("abort",()=>this[D]()))}get bufferLength(){return this[k]}get encoding(){return this[m]}set encoding(t){throw new Error("Encoding must be set at instantiation time")}setEncoding(t){throw new Error("Encoding must be set at instantiation time")}get objectMode(){return this[A]}set objectMode(t){throw new Error("objectMode must be set at instantiation time")}get async(){return this[P]}set async(t){this[P]=this[P]||!!t}[D](){this[C]=!0,this.emit("abort",this[N]?.reason),this.destroy(this[N]?.reason)}get aborted(){return this[C]}set aborted(t){}write(t,e,r){if(this[C])return!1;if(this[s])throw new Error("write after end");if(this[O])return this.emit("error",Object.assign(new Error("Cannot call write after a stream was destroyed"),{code:"ERR_STREAM_DESTROYED"})),!0;"function"==typeof e&&(r=e,e="utf8"),e||(e="utf8");const n=this[P]?W:U;if(!this[A]&&!Buffer.isBuffer(t))if(i=t,!Buffer.isBuffer(i)&&ArrayBuffer.isView(i))t=Buffer.from(t.buffer,t.byteOffset,t.byteLength);else if((t=>t instanceof ArrayBuffer||!!t&&"object"==typeof t&&t.constructor&&"ArrayBuffer"===t.constructor.name&&t.byteLength>=0)(t))t=Buffer.from(t);else if("string"!=typeof t)throw new Error("Non-contiguous data written to non-objectMode stream");var i;return this[A]?(this[v]&&0!==this[k]&&this[g](!0),this[v]?this.emit("data",t):this[T](t),0!==this[k]&&this.emit("readable"),r&&n(r),this[v]):t.length?("string"!=typeof t||e===this[m]&&!this[_]?.lastNeed||(t=Buffer.from(t,e)),Buffer.isBuffer(t)&&this[m]&&(t=this[_].write(t)),this[v]&&0!==this[k]&&this[g](!0),this[v]?this.emit("data",t):this[T](t),0!==this[k]&&this.emit("readable"),r&&n(r),this[v]):(0!==this[k]&&this.emit("readable"),r&&n(r),this[v])}read(t){if(this[O])return null;if(this[B]=!1,0===this[k]||0===t||t&&t>this[k])return this[a](),null;this[A]&&(t=null),this[E].length>1&&!this[A]&&(this[E]=[this[m]?this[E].join(""):Buffer.concat(this[E],this[k])]);const e=this[y](t||null,this[E][0]);return this[a](),e}[y](t,e){if(this[A])this[x]();else{const r=e;t===r.length||null===t?this[x]():"string"==typeof r?(this[E][0]=r.slice(t),e=r.slice(0,t),this[k]-=t):(this[E][0]=r.subarray(t),e=r.subarray(0,t),this[k]-=t)}return this.emit("data",e),this[E].length||this[s]||this.emit("drain"),e}end(t,e,r){return"function"==typeof t&&(r=t,t=void 0),"function"==typeof e&&(r=e,e="utf8"),void 0!==t&&this.write(t,e),r&&this.once("end",r),this[s]=!0,this.writable=!1,!this[v]&&this[w]||this[a](),this}[S](){this[O]||(this[F]||this[R].length||(this[B]=!0),this[w]=!1,this[v]=!0,this.emit("resume"),this[E].length?this[g]():this[s]?this[a]():this.emit("drain"))}resume(){return this[S]()}pause(){this[v]=!1,this[w]=!0,this[B]=!1}get destroyed(){return this[O]}get flowing(){return this[v]}get paused(){return this[w]}[T](t){this[A]?this[k]+=1:this[k]+=t.length,this[E].push(t)}[x](){return this[A]?this[k]-=1:this[k]-=this[E][0].length,this[E].shift()}[g](t=!1){do{}while(this[b](this[x]())&&this[E].length);t||this[E].length||this[s]||this.emit("drain")}[b](t){return this.emit("data",t),this[v]}pipe(t,e){if(this[O])return t;this[B]=!1;const n=this[l];return e=e||{},t===r.stdout||t===r.stderr?e.end=!1:e.end=!1!==e.end,e.proxyErrors=!!e.proxyErrors,n?e.end&&t.end():(this[R].push(e.proxyErrors?new $(this,t,e):new z(this,t,e)),this[P]?W(()=>this[S]()):this[S]()),t}unpipe(t){const e=this[R].find(e=>e.dest===t);e&&(1===this[R].length?(this[v]&&0===this[F]&&(this[v]=!1),this[R]=[]):this[R].splice(this[R].indexOf(e),1),e.unpipe())}addListener(t,e){return this.on(t,e)}on(t,e){const r=super.on(t,e);if("data"===t)this[B]=!1,this[F]++,this[R].length||this[v]||this[S]();else if("readable"===t&&0!==this[k])super.emit("readable");else if((t=>"end"===t||"finish"===t||"prefinish"===t)(t)&&this[l])super.emit(t),this.removeAllListeners(t);else if("error"===t&&this[c]){const t=e;this[P]?W(()=>t.call(this,this[c])):t.call(this,this[c])}return r}removeListener(t,e){return this.off(t,e)}off(t,e){const r=super.off(t,e);return"data"===t&&(this[F]=this.listeners("data").length,0!==this[F]||this[B]||this[R].length||(this[v]=!1)),r}removeAllListeners(t){const e=super.removeAllListeners(t);return"data"!==t&&void 0!==t||(this[F]=0,this[B]||this[R].length||(this[v]=!1)),e}get emittedEnd(){return this[l]}[a](){this[u]||this[l]||this[O]||0!==this[E].length||!this[s]||(this[u]=!0,this.emit("end"),this.emit("prefinish"),this.emit("finish"),this[h]&&this.emit("close"),this[u]=!1)}emit(t,...e){const r=e[0];if("error"!==t&&"close"!==t&&t!==O&&this[O])return!1;if("data"===t)return!(!this[A]&&!r)&&(this[P]?(W(()=>this[j](r)),!0):this[j](r));if("end"===t)return this[M]();if("close"===t){if(this[h]=!0,!this[l]&&!this[O])return!1;const t=super.emit("close");return this.removeAllListeners("close"),t}if("error"===t){this[c]=r,super.emit(L,r);const t=!(this[N]&&!this.listeners("error").length)&&super.emit("error",r);return this[a](),t}if("resume"===t){const t=super.emit("resume");return this[a](),t}if("finish"===t||"prefinish"===t){const e=super.emit(t);return this.removeAllListeners(t),e}const n=super.emit(t,...e);return this[a](),n}[j](t){for(const e of this[R])!1===e.dest.write(t)&&this.pause();const e=!this[B]&&super.emit("data",t);return this[a](),e}[M](){return!this[l]&&(this[l]=!0,this.readable=!1,this[P]?(W(()=>this[I]()),!0):this[I]())}[I](){if(this[_]){const t=this[_].end();if(t){for(const e of this[R])e.dest.write(t);this[B]||super.emit("data",t)}}for(const t of this[R])t.end();const t=super.emit("end");return this.removeAllListeners("end"),t}async collect(){const t=Object.assign([],{dataLength:0});this[A]||(t.dataLength=0);const e=this.promise();return this.on("data",e=>{t.push(e),this[A]||(t.dataLength+=e.length)}),await e,t}async concat(){if(this[A])throw new Error("cannot concat in objectMode");const t=await this.collect();return this[m]?t.join(""):Buffer.concat(t,t.dataLength)}async promise(){return new Promise((t,e)=>{this.on(O,()=>e(new Error("stream destroyed"))),this.on("error",t=>e(t)),this.on("end",()=>t())})}[Symbol.asyncIterator](){this[B]=!1;let t=!1;const e=async()=>(this.pause(),t=!0,{value:void 0,done:!0});return{next:()=>{if(t)return e();const r=this.read();if(null!==r)return Promise.resolve({done:!1,value:r});if(this[s])return e();let n,i;const o=t=>{this.off("data",a),this.off("end",l),this.off(O,u),e(),i(t)},a=t=>{this.off("error",o),this.off("end",l),this.off(O,u),this.pause(),n({value:t,done:!!this[s]})},l=()=>{this.off("error",o),this.off("data",a),this.off(O,u),e(),n({done:!0,value:void 0})},u=()=>o(new Error("stream destroyed"));return new Promise((t,e)=>{i=e,n=t,this.once(O,u),this.once("error",o),this.once("end",l),this.once("data",a)})},throw:e,return:e,[Symbol.asyncIterator](){return this}}}[Symbol.iterator](){this[B]=!1;let t=!1;const e=()=>(this.pause(),this.off(L,e),this.off(O,e),this.off("end",e),t=!0,{done:!0,value:void 0});return this.once("end",e),this.once(L,e),this.once(O,e),{next:()=>{if(t)return e();const r=this.read();return null===r?e():{done:!1,value:r}},throw:e,return:e,[Symbol.iterator](){return this}}}destroy(t){if(this[O])return t?this.emit("error",t):this.emit(O),this;this[O]=!0,this[B]=!0,this[E].length=0,this[k]=0;return"function"!=typeof this.close||this[h]||this.close(),t?this.emit("error",t):this.emit(O),this}static get isStream(){return t.isStream}}t.Minipass=H}(q_);var V_=Ft&&Ft.__createBinding||(Object.create?function(t,e,r,n){void 0===n&&(n=r);var i=Object.getOwnPropertyDescriptor(e,r);i&&!("get"in i?!e.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,i)}:function(t,e,r,n){void 0===n&&(n=r),t[n]=e[r]}),Z_=Ft&&Ft.__setModuleDefault||(Object.create?function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}:function(t,e){t.default=e}),Y_=Ft&&Ft.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)"default"!==r&&Object.prototype.hasOwnProperty.call(t,r)&&V_(e,t,r);return Z_(e,t),e};Object.defineProperty(I_,"__esModule",{value:!0}),I_.PathScurry=I_.Path=I_.PathScurryDarwin=I_.PathScurryPosix=I_.PathScurryWin32=I_.PathScurryBase=I_.PathPosix=I_.PathWin32=I_.PathBase=I_.ChildrenCache=I_.ResolveCache=void 0;const K_=P_,Q_=u,J_=l,X_=t,tv=Y_(c),ev=X_.realpathSync.native,rv=h,nv=q_,iv={lstatSync:X_.lstatSync,readdir:X_.readdir,readdirSync:X_.readdirSync,readlinkSync:X_.readlinkSync,realpathSync:ev,promises:{lstat:rv.lstat,readdir:rv.readdir,readlink:rv.readlink,realpath:rv.realpath}},ov=t=>t&&t!==iv&&t!==tv?{...iv,...t,promises:{...iv.promises,...t.promises||{}}}:iv,sv=/^\\\\\?\\([a-z]:)\\?$/i,av=/[\\\/]/,lv=10,uv=15,cv=-16,hv=128,fv=256,dv=512,pv=t=>t.isFile()?8:t.isDirectory()?4:t.isSymbolicLink()?lv:t.isCharacterDevice()?2:t.isBlockDevice()?6:t.isSocket()?12:t.isFIFO()?1:0,yv=new Map,gv=t=>{const e=yv.get(t);if(e)return e;const r=t.normalize("NFKD");return yv.set(t,r),r},bv=new Map,mv=t=>{const e=bv.get(t);if(e)return e;const r=gv(t.toLowerCase());return bv.set(t,r),r};class _v extends K_.LRUCache{constructor(){super({max:256})}}I_.ResolveCache=_v;class vv extends K_.LRUCache{constructor(t=16384){super({maxSize:t,sizeCalculation:t=>t.length+1})}}I_.ChildrenCache=vv;const wv=Symbol("PathScurry setAsCwd");class Sv{name;root;roots;parent;nocase;isCWD=!1;#it;#ot;get dev(){return this.#ot}#st;get mode(){return this.#st}#at;get nlink(){return this.#at}#lt;get uid(){return this.#lt}#ut;get gid(){return this.#ut}#ct;get rdev(){return this.#ct}#ht;get blksize(){return this.#ht}#ft;get ino(){return this.#ft}#S;get size(){return this.#S}#dt;get blocks(){return this.#dt}#pt;get atimeMs(){return this.#pt}#yt;get mtimeMs(){return this.#yt}#gt;get ctimeMs(){return this.#gt}#bt;get birthtimeMs(){return this.#bt}#mt;get atime(){return this.#mt}#_t;get mtime(){return this.#_t}#vt;get ctime(){return this.#vt}#wt;get birthtime(){return this.#wt}#St;#Et;#Rt;#kt;#Tt;#xt;#At;#Ot;#Lt;#jt;get parentPath(){return(this.parent||this).fullpath()}get path(){return this.parentPath}constructor(t,e=0,r,n,i,o,s){this.name=t,this.#St=i?mv(t):gv(t),this.#At=1023&e,this.nocase=i,this.roots=n,this.root=r||this,this.#Ot=o,this.#Rt=s.fullpath,this.#Tt=s.relative,this.#xt=s.relativePosix,this.parent=s.parent,this.parent?this.#it=this.parent.#it:this.#it=ov(s.fs)}depth(){return void 0!==this.#Et?this.#Et:this.parent?this.#Et=this.parent.depth()+1:this.#Et=0}childrenCache(){return this.#Ot}resolve(t){if(!t)return this;const e=this.getRootString(t),r=t.substring(e.length).split(this.splitSep);return e?this.getRoot(e).#Mt(r):this.#Mt(r)}#Mt(t){let e=this;for(const r of t)e=e.child(r);return e}children(){const t=this.#Ot.get(this);if(t)return t;const e=Object.assign([],{provisional:0});return this.#Ot.set(this,e),this.#At&=-17,e}child(t,e){if(""===t||"."===t)return this;if(".."===t)return this.parent||this;const r=this.children(),n=this.nocase?mv(t):gv(t);for(const t of r)if(t.#St===n)return t;const i=this.parent?this.sep:"",o=this.#Rt?this.#Rt+i+t:void 0,s=this.newChild(t,0,{...e,parent:this,fullpath:o});return this.canReaddir()||(s.#At|=hv),r.push(s),s}relative(){if(this.isCWD)return"";if(void 0!==this.#Tt)return this.#Tt;const t=this.name,e=this.parent;if(!e)return this.#Tt=this.name;const r=e.relative();return r+(r&&e.parent?this.sep:"")+t}relativePosix(){if("/"===this.sep)return this.relative();if(this.isCWD)return"";if(void 0!==this.#xt)return this.#xt;const t=this.name,e=this.parent;if(!e)return this.#xt=this.fullpathPosix();const r=e.relativePosix();return r+(r&&e.parent?"/":"")+t}fullpath(){if(void 0!==this.#Rt)return this.#Rt;const t=this.name,e=this.parent;if(!e)return this.#Rt=this.name;const r=e.fullpath()+(e.parent?this.sep:"")+t;return this.#Rt=r}fullpathPosix(){if(void 0!==this.#kt)return this.#kt;if("/"===this.sep)return this.#kt=this.fullpath();if(!this.parent){const t=this.fullpath().replace(/\\/g,"/");return/^[a-z]:\//i.test(t)?this.#kt=`//?/${t}`:this.#kt=t}const t=this.parent,e=t.fullpathPosix(),r=e+(e&&t.parent?"/":"")+this.name;return this.#kt=r}isUnknown(){return 0===(this.#At&uv)}isType(t){return this[`is${t}`]()}getType(){return this.isUnknown()?"Unknown":this.isDirectory()?"Directory":this.isFile()?"File":this.isSymbolicLink()?"SymbolicLink":this.isFIFO()?"FIFO":this.isCharacterDevice()?"CharacterDevice":this.isBlockDevice()?"BlockDevice":this.isSocket()?"Socket":"Unknown"}isFile(){return 8===(this.#At&uv)}isDirectory(){return 4===(this.#At&uv)}isCharacterDevice(){return 2===(this.#At&uv)}isBlockDevice(){return 6===(this.#At&uv)}isFIFO(){return 1===(this.#At&uv)}isSocket(){return 12===(this.#At&uv)}isSymbolicLink(){return(this.#At&lv)===lv}lstatCached(){return 32&this.#At?this:void 0}readlinkCached(){return this.#Lt}realpathCached(){return this.#jt}readdirCached(){const t=this.children();return t.slice(0,t.provisional)}canReadlink(){if(this.#Lt)return!0;if(!this.parent)return!1;const t=this.#At&uv;return!(0!==t&&t!==lv||this.#At&fv||this.#At&hv)}calledReaddir(){return!!(16&this.#At)}isENOENT(){return!!(this.#At&hv)}isNamed(t){return this.nocase?this.#St===mv(t):this.#St===gv(t)}async readlink(){const t=this.#Lt;if(t)return t;if(this.canReadlink()&&this.parent)try{const t=await this.#it.promises.readlink(this.fullpath()),e=(await this.parent.realpath())?.resolve(t);if(e)return this.#Lt=e}catch(t){return void this.#It(t.code)}}readlinkSync(){const t=this.#Lt;if(t)return t;if(this.canReadlink()&&this.parent)try{const t=this.#it.readlinkSync(this.fullpath()),e=this.parent.realpathSync()?.resolve(t);if(e)return this.#Lt=e}catch(t){return void this.#It(t.code)}}#Pt(t){this.#At|=16;for(let e=t.provisional;e<t.length;e++){const r=t[e];r&&r.#Dt()}}#Dt(){this.#At&hv||(this.#At=(this.#At|hv)&cv,this.#Ct())}#Ct(){const t=this.children();t.provisional=0;for(const e of t)e.#Dt()}#Nt(){this.#At|=dv,this.#Ft()}#Ft(){if(64&this.#At)return;let t=this.#At;4===(t&uv)&&(t&=cv),this.#At=64|t,this.#Ct()}#Bt(t=""){"ENOTDIR"===t||"EPERM"===t?this.#Ft():"ENOENT"===t?this.#Dt():this.children().provisional=0}#Wt(t=""){if("ENOTDIR"===t){this.parent.#Ft()}else"ENOENT"===t&&this.#Dt()}#It(t=""){let e=this.#At;e|=fv,"ENOENT"===t&&(e|=hv),"EINVAL"!==t&&"UNKNOWN"!==t||(e&=cv),this.#At=e,"ENOTDIR"===t&&this.parent&&this.parent.#Ft()}#Ut(t,e){return this.#zt(t,e)||this.#$t(t,e)}#$t(t,e){const r=pv(t),n=this.newChild(t.name,r,{parent:this}),i=n.#At&uv;return 4!==i&&i!==lv&&0!==i&&(n.#At|=64),e.unshift(n),e.provisional++,n}#zt(t,e){for(let r=e.provisional;r<e.length;r++){const n=e[r];if((this.nocase?mv(t.name):gv(t.name))===n.#St)return this.#Ht(t,n,r,e)}}#Ht(t,e,r,n){const i=e.name;return e.#At=e.#At&cv|pv(t),i!==t.name&&(e.name=t.name),r!==n.provisional&&(r===n.length-1?n.pop():n.splice(r,1),n.unshift(e)),n.provisional++,e}async lstat(){if(0===(this.#At&hv))try{return this.#Gt(await this.#it.promises.lstat(this.fullpath())),this}catch(t){this.#Wt(t.code)}}lstatSync(){if(0===(this.#At&hv))try{return this.#Gt(this.#it.lstatSync(this.fullpath())),this}catch(t){this.#Wt(t.code)}}#Gt(t){const{atime:e,atimeMs:r,birthtime:n,birthtimeMs:i,blksize:o,blocks:s,ctime:a,ctimeMs:l,dev:u,gid:c,ino:h,mode:f,mtime:d,mtimeMs:p,nlink:y,rdev:g,size:b,uid:m}=t;this.#mt=e,this.#pt=r,this.#wt=n,this.#bt=i,this.#ht=o,this.#dt=s,this.#vt=a,this.#gt=l,this.#ot=u,this.#ut=c,this.#ft=h,this.#st=f,this.#_t=d,this.#yt=p,this.#at=y,this.#ct=g,this.#S=b,this.#lt=m;const _=pv(t);this.#At=this.#At&cv|_|32,0!==_&&4!==_&&_!==lv&&(this.#At|=64)}#qt=[];#Vt=!1;#Zt(t){this.#Vt=!1;const e=this.#qt.slice();this.#qt.length=0,e.forEach(e=>e(null,t))}readdirCB(t,e=!1){if(!this.canReaddir())return void(e?t(null,[]):queueMicrotask(()=>t(null,[])));const r=this.children();if(this.calledReaddir()){const n=r.slice(0,r.provisional);return void(e?t(null,n):queueMicrotask(()=>t(null,n)))}if(this.#qt.push(t),this.#Vt)return;this.#Vt=!0;const n=this.fullpath();this.#it.readdir(n,{withFileTypes:!0},(t,e)=>{if(t)this.#Bt(t.code),r.provisional=0;else{for(const t of e)this.#Ut(t,r);this.#Pt(r)}this.#Zt(r.slice(0,r.provisional))})}#Yt;async readdir(){if(!this.canReaddir())return[];const t=this.children();if(this.calledReaddir())return t.slice(0,t.provisional);const e=this.fullpath();if(this.#Yt)await this.#Yt;else{let r=()=>{};this.#Yt=new Promise(t=>r=t);try{for(const r of await this.#it.promises.readdir(e,{withFileTypes:!0}))this.#Ut(r,t);this.#Pt(t)}catch(e){this.#Bt(e.code),t.provisional=0}this.#Yt=void 0,r()}return t.slice(0,t.provisional)}readdirSync(){if(!this.canReaddir())return[];const t=this.children();if(this.calledReaddir())return t.slice(0,t.provisional);const e=this.fullpath();try{for(const r of this.#it.readdirSync(e,{withFileTypes:!0}))this.#Ut(r,t);this.#Pt(t)}catch(e){this.#Bt(e.code),t.provisional=0}return t.slice(0,t.provisional)}canReaddir(){if(704&this.#At)return!1;const t=uv&this.#At;return 0===t||4===t||t===lv}shouldWalk(t,e){return!(4&~this.#At)&&!(704&this.#At)&&!t.has(this)&&(!e||e(this))}async realpath(){if(this.#jt)return this.#jt;if(!(896&this.#At))try{const t=await this.#it.promises.realpath(this.fullpath());return this.#jt=this.resolve(t)}catch(t){this.#Nt()}}realpathSync(){if(this.#jt)return this.#jt;if(!(896&this.#At))try{const t=this.#it.realpathSync(this.fullpath());return this.#jt=this.resolve(t)}catch(t){this.#Nt()}}[wv](t){if(t===this)return;t.isCWD=!1,this.isCWD=!0;const e=new Set([]);let r=[],n=this;for(;n&&n.parent;)e.add(n),n.#Tt=r.join(this.sep),n.#xt=r.join("/"),n=n.parent,r.push("..");for(n=t;n&&n.parent&&!e.has(n);)n.#Tt=void 0,n.#xt=void 0,n=n.parent}}I_.PathBase=Sv;class Ev extends Sv{sep="\\";splitSep=av;constructor(t,e=0,r,n,i,o,s){super(t,e,r,n,i,o,s)}newChild(t,e=0,r={}){return new Ev(t,e,this.root,this.roots,this.nocase,this.childrenCache(),r)}getRootString(t){return Q_.win32.parse(t).root}getRoot(t){if((t=(t=>t.replace(/\//g,"\\").replace(sv,"$1\\"))(t.toUpperCase()))===this.root.name)return this.root;for(const[e,r]of Object.entries(this.roots))if(this.sameRoot(t,e))return this.roots[t]=r;return this.roots[t]=new Tv(t,this).root}sameRoot(t,e=this.root.name){return(t=t.toUpperCase().replace(/\//g,"\\").replace(sv,"$1\\"))===e}}I_.PathWin32=Ev;class Rv extends Sv{splitSep="/";sep="/";constructor(t,e=0,r,n,i,o,s){super(t,e,r,n,i,o,s)}getRootString(t){return t.startsWith("/")?"/":""}getRoot(t){return this.root}newChild(t,e=0,r={}){return new Rv(t,e,this.root,this.roots,this.nocase,this.childrenCache(),r)}}I_.PathPosix=Rv;class kv{root;rootPath;roots;cwd;#Kt;#Qt;#Ot;nocase;#it;constructor(t=process.cwd(),e,r,{nocase:n,childrenCacheSize:i=16384,fs:o=iv}={}){this.#it=ov(o),(t instanceof URL||t.startsWith("file://"))&&(t=(0,J_.fileURLToPath)(t));const s=e.resolve(t);this.roots=Object.create(null),this.rootPath=this.parseRootPath(s),this.#Kt=new _v,this.#Qt=new _v,this.#Ot=new vv(i);const a=s.substring(this.rootPath.length).split(r);if(1!==a.length||a[0]||a.pop(),void 0===n)throw new TypeError("must provide nocase setting to PathScurryBase ctor");this.nocase=n,this.root=this.newRoot(this.#it),this.roots[this.rootPath]=this.root;let l=this.root,u=a.length-1;const c=e.sep;let h=this.rootPath,f=!1;for(const t of a){const e=u--;l=l.child(t,{relative:new Array(e).fill("..").join(c),relativePosix:new Array(e).fill("..").join("/"),fullpath:h+=(f?"":c)+t}),f=!0}this.cwd=l}depth(t=this.cwd){return"string"==typeof t&&(t=this.cwd.resolve(t)),t.depth()}childrenCache(){return this.#Ot}resolve(...t){let e="";for(let r=t.length-1;r>=0;r--){const n=t[r];if(n&&"."!==n&&(e=e?`${n}/${e}`:n,this.isAbsolute(n)))break}const r=this.#Kt.get(e);if(void 0!==r)return r;const n=this.cwd.resolve(e).fullpath();return this.#Kt.set(e,n),n}resolvePosix(...t){let e="";for(let r=t.length-1;r>=0;r--){const n=t[r];if(n&&"."!==n&&(e=e?`${n}/${e}`:n,this.isAbsolute(n)))break}const r=this.#Qt.get(e);if(void 0!==r)return r;const n=this.cwd.resolve(e).fullpathPosix();return this.#Qt.set(e,n),n}relative(t=this.cwd){return"string"==typeof t&&(t=this.cwd.resolve(t)),t.relative()}relativePosix(t=this.cwd){return"string"==typeof t&&(t=this.cwd.resolve(t)),t.relativePosix()}basename(t=this.cwd){return"string"==typeof t&&(t=this.cwd.resolve(t)),t.name}dirname(t=this.cwd){return"string"==typeof t&&(t=this.cwd.resolve(t)),(t.parent||t).fullpath()}async readdir(t=this.cwd,e={withFileTypes:!0}){"string"==typeof t?t=this.cwd.resolve(t):t instanceof Sv||(e=t,t=this.cwd);const{withFileTypes:r}=e;if(t.canReaddir()){const e=await t.readdir();return r?e:e.map(t=>t.name)}return[]}readdirSync(t=this.cwd,e={withFileTypes:!0}){"string"==typeof t?t=this.cwd.resolve(t):t instanceof Sv||(e=t,t=this.cwd);const{withFileTypes:r=!0}=e;return t.canReaddir()?r?t.readdirSync():t.readdirSync().map(t=>t.name):[]}async lstat(t=this.cwd){return"string"==typeof t&&(t=this.cwd.resolve(t)),t.lstat()}lstatSync(t=this.cwd){return"string"==typeof t&&(t=this.cwd.resolve(t)),t.lstatSync()}async readlink(t=this.cwd,{withFileTypes:e}={withFileTypes:!1}){"string"==typeof t?t=this.cwd.resolve(t):t instanceof Sv||(e=t.withFileTypes,t=this.cwd);const r=await t.readlink();return e?r:r?.fullpath()}readlinkSync(t=this.cwd,{withFileTypes:e}={withFileTypes:!1}){"string"==typeof t?t=this.cwd.resolve(t):t instanceof Sv||(e=t.withFileTypes,t=this.cwd);const r=t.readlinkSync();return e?r:r?.fullpath()}async realpath(t=this.cwd,{withFileTypes:e}={withFileTypes:!1}){"string"==typeof t?t=this.cwd.resolve(t):t instanceof Sv||(e=t.withFileTypes,t=this.cwd);const r=await t.realpath();return e?r:r?.fullpath()}realpathSync(t=this.cwd,{withFileTypes:e}={withFileTypes:!1}){"string"==typeof t?t=this.cwd.resolve(t):t instanceof Sv||(e=t.withFileTypes,t=this.cwd);const r=t.realpathSync();return e?r:r?.fullpath()}async walk(t=this.cwd,e={}){"string"==typeof t?t=this.cwd.resolve(t):t instanceof Sv||(e=t,t=this.cwd);const{withFileTypes:r=!0,follow:n=!1,filter:i,walkFilter:o}=e,s=[];i&&!i(t)||s.push(r?t:t.fullpath());const a=new Set,l=(t,e)=>{a.add(t),t.readdirCB((t,u)=>{if(t)return e(t);let c=u.length;if(!c)return e();const h=()=>{0===--c&&e()};for(const t of u)i&&!i(t)||s.push(r?t:t.fullpath()),n&&t.isSymbolicLink()?t.realpath().then(t=>t?.isUnknown()?t.lstat():t).then(t=>t?.shouldWalk(a,o)?l(t,h):h()):t.shouldWalk(a,o)?l(t,h):h()},!0)},u=t;return new Promise((t,e)=>{l(u,r=>{if(r)return e(r);t(s)})})}walkSync(t=this.cwd,e={}){"string"==typeof t?t=this.cwd.resolve(t):t instanceof Sv||(e=t,t=this.cwd);const{withFileTypes:r=!0,follow:n=!1,filter:i,walkFilter:o}=e,s=[];i&&!i(t)||s.push(r?t:t.fullpath());const a=new Set([t]);for(const t of a){const e=t.readdirSync();for(const t of e){i&&!i(t)||s.push(r?t:t.fullpath());let e=t;if(t.isSymbolicLink()){if(!n||!(e=t.realpathSync()))continue;e.isUnknown()&&e.lstatSync()}e.shouldWalk(a,o)&&a.add(e)}}return s}[Symbol.asyncIterator](){return this.iterate()}iterate(t=this.cwd,e={}){return"string"==typeof t?t=this.cwd.resolve(t):t instanceof Sv||(e=t,t=this.cwd),this.stream(t,e)[Symbol.asyncIterator]()}[Symbol.iterator](){return this.iterateSync()}*iterateSync(t=this.cwd,e={}){"string"==typeof t?t=this.cwd.resolve(t):t instanceof Sv||(e=t,t=this.cwd);const{withFileTypes:r=!0,follow:n=!1,filter:i,walkFilter:o}=e;i&&!i(t)||(yield r?t:t.fullpath());const s=new Set([t]);for(const t of s){const e=t.readdirSync();for(const t of e){i&&!i(t)||(yield r?t:t.fullpath());let e=t;if(t.isSymbolicLink()){if(!n||!(e=t.realpathSync()))continue;e.isUnknown()&&e.lstatSync()}e.shouldWalk(s,o)&&s.add(e)}}}stream(t=this.cwd,e={}){"string"==typeof t?t=this.cwd.resolve(t):t instanceof Sv||(e=t,t=this.cwd);const{withFileTypes:r=!0,follow:n=!1,filter:i,walkFilter:o}=e,s=new nv.Minipass({objectMode:!0});i&&!i(t)||s.write(r?t:t.fullpath());const a=new Set,l=[t];let u=0;const c=()=>{let t=!1;for(;!t;){const e=l.shift();if(!e)return void(0===u&&s.end());u++,a.add(e);const h=(e,d,p=!1)=>{if(e)return s.emit("error",e);if(n&&!p){const t=[];for(const e of d)e.isSymbolicLink()&&t.push(e.realpath().then(t=>t?.isUnknown()?t.lstat():t));if(t.length)return void Promise.all(t).then(()=>h(null,d,!0))}for(const e of d)!e||i&&!i(e)||s.write(r?e:e.fullpath())||(t=!0);u--;for(const t of d){const e=t.realpathCached()||t;e.shouldWalk(a,o)&&l.push(e)}t&&!s.flowing?s.once("drain",c):f||c()};let f=!0;e.readdirCB(h,!0),f=!1}};return c(),s}streamSync(t=this.cwd,e={}){"string"==typeof t?t=this.cwd.resolve(t):t instanceof Sv||(e=t,t=this.cwd);const{withFileTypes:r=!0,follow:n=!1,filter:i,walkFilter:o}=e,s=new nv.Minipass({objectMode:!0}),a=new Set;i&&!i(t)||s.write(r?t:t.fullpath());const l=[t];let u=0;const c=()=>{let t=!1;for(;!t;){const e=l.shift();if(!e)return void(0===u&&s.end());u++,a.add(e);const c=e.readdirSync();for(const e of c)i&&!i(e)||s.write(r?e:e.fullpath())||(t=!0);u--;for(const t of c){let e=t;if(t.isSymbolicLink()){if(!n||!(e=t.realpathSync()))continue;e.isUnknown()&&e.lstatSync()}e.shouldWalk(a,o)&&l.push(e)}}t&&!s.flowing&&s.once("drain",c)};return c(),s}chdir(t=this.cwd){const e=this.cwd;this.cwd="string"==typeof t?this.cwd.resolve(t):t,this.cwd[wv](e)}}I_.PathScurryBase=kv;class Tv extends kv{sep="\\";constructor(t=process.cwd(),e={}){const{nocase:r=!0}=e;super(t,Q_.win32,"\\",{...e,nocase:r}),this.nocase=r;for(let t=this.cwd;t;t=t.parent)t.nocase=this.nocase}parseRootPath(t){return Q_.win32.parse(t).root.toUpperCase()}newRoot(t){return new Ev(this.rootPath,4,void 0,this.roots,this.nocase,this.childrenCache(),{fs:t})}isAbsolute(t){return t.startsWith("/")||t.startsWith("\\")||/^[a-z]:(\/|\\)/i.test(t)}}I_.PathScurryWin32=Tv;class xv extends kv{sep="/";constructor(t=process.cwd(),e={}){const{nocase:r=!1}=e;super(t,Q_.posix,"/",{...e,nocase:r}),this.nocase=r}parseRootPath(t){return"/"}newRoot(t){return new Rv(this.rootPath,4,void 0,this.roots,this.nocase,this.childrenCache(),{fs:t})}isAbsolute(t){return t.startsWith("/")}}I_.PathScurryPosix=xv;class Av extends xv{constructor(t=process.cwd(),e={}){const{nocase:r=!0}=e;super(t,{...e,nocase:r})}}I_.PathScurryDarwin=Av,I_.Path="win32"===process.platform?Ev:Rv,I_.PathScurry="win32"===process.platform?Tv:"darwin"===process.platform?Av:xv;var Ov={};Object.defineProperty(Ov,"__esModule",{value:!0}),Ov.Pattern=void 0;const Lv=Ym;class jv{#Jt;#Xt;#te;length;#ee;#re;#ne;#ie;#oe;#se;#ae=!0;constructor(t,e,r,n){if(!(t.length>=1))throw new TypeError("empty pattern list");if(!(e.length>=1))throw new TypeError("empty glob list");if(e.length!==t.length)throw new TypeError("mismatched pattern list and glob list lengths");if(this.length=t.length,r<0||r>=this.length)throw new TypeError("index out of range");if(this.#Jt=t,this.#Xt=e,this.#te=r,this.#ee=n,0===this.#te)if(this.isUNC()){const[t,e,r,n,...i]=this.#Jt,[o,s,a,l,...u]=this.#Xt;""===i[0]&&(i.shift(),u.shift());const c=[t,e,r,n,""].join("/"),h=[o,s,a,l,""].join("/");this.#Jt=[c,...i],this.#Xt=[h,...u],this.length=this.#Jt.length}else if(this.isDrive()||this.isAbsolute()){const[t,...e]=this.#Jt,[r,...n]=this.#Xt;""===e[0]&&(e.shift(),n.shift());const i=t+"/",o=r+"/";this.#Jt=[i,...e],this.#Xt=[o,...n],this.length=this.#Jt.length}}pattern(){return this.#Jt[this.#te]}isString(){return"string"==typeof this.#Jt[this.#te]}isGlobstar(){return this.#Jt[this.#te]===Lv.GLOBSTAR}isRegExp(){return this.#Jt[this.#te]instanceof RegExp}globString(){return this.#ne=this.#ne||(0===this.#te?this.isAbsolute()?this.#Xt[0]+this.#Xt.slice(1).join("/"):this.#Xt.join("/"):this.#Xt.slice(this.#te).join("/"))}hasMore(){return this.length>this.#te+1}rest(){return void 0!==this.#re?this.#re:this.hasMore()?(this.#re=new jv(this.#Jt,this.#Xt,this.#te+1,this.#ee),this.#re.#se=this.#se,this.#re.#oe=this.#oe,this.#re.#ie=this.#ie,this.#re):this.#re=null}isUNC(){const t=this.#Jt;return void 0!==this.#oe?this.#oe:this.#oe="win32"===this.#ee&&0===this.#te&&""===t[0]&&""===t[1]&&"string"==typeof t[2]&&!!t[2]&&"string"==typeof t[3]&&!!t[3]}isDrive(){const t=this.#Jt;return void 0!==this.#ie?this.#ie:this.#ie="win32"===this.#ee&&0===this.#te&&this.length>1&&"string"==typeof t[0]&&/^[a-z]:$/i.test(t[0])}isAbsolute(){const t=this.#Jt;return void 0!==this.#se?this.#se:this.#se=""===t[0]&&t.length>1||this.isDrive()||this.isUNC()}root(){const t=this.#Jt[0];return"string"==typeof t&&this.isAbsolute()&&0===this.#te?t:""}checkFollowGlobstar(){return!(0===this.#te||!this.isGlobstar()||!this.#ae)}markFollowGlobstar(){return!(0===this.#te||!this.isGlobstar()||!this.#ae)&&(this.#ae=!1,!0)}}Ov.Pattern=jv;var Mv={},Iv={};Object.defineProperty(Iv,"__esModule",{value:!0}),Iv.Ignore=void 0;const Pv=Ym,Dv=Ov,Cv="object"==typeof process&&process&&"string"==typeof process.platform?process.platform:"linux";Iv.Ignore=class{relative;relativeChildren;absolute;absoluteChildren;platform;mmopts;constructor(t,{nobrace:e,nocase:r,noext:n,noglobstar:i,platform:o=Cv}){this.relative=[],this.absolute=[],this.relativeChildren=[],this.absoluteChildren=[],this.platform=o,this.mmopts={dot:!0,nobrace:e,nocase:r,noext:n,noglobstar:i,optimizationLevel:2,platform:o,nocomment:!0,nonegate:!0};for(const e of t)this.add(e)}add(t){const e=new Pv.Minimatch(t,this.mmopts);for(let t=0;t<e.set.length;t++){const r=e.set[t],n=e.globParts[t];if(!r||!n)throw new Error("invalid pattern object");for(;"."===r[0]&&"."===n[0];)r.shift(),n.shift();const i=new Dv.Pattern(r,n,0,this.platform),o=new Pv.Minimatch(i.globString(),this.mmopts),s="**"===n[n.length-1],a=i.isAbsolute();a?this.absolute.push(o):this.relative.push(o),s&&(a?this.absoluteChildren.push(o):this.relativeChildren.push(o))}}ignored(t){const e=t.fullpath(),r=`${e}/`,n=t.relative()||".",i=`${n}/`;for(const t of this.relative)if(t.match(n)||t.match(i))return!0;for(const t of this.absolute)if(t.match(e)||t.match(r))return!0;return!1}childrenIgnored(t){const e=t.fullpath()+"/",r=(t.relative()||".")+"/";for(const t of this.relativeChildren)if(t.match(r))return!0;for(const t of this.absoluteChildren)if(t.match(e))return!0;return!1}};var Nv={};Object.defineProperty(Nv,"__esModule",{value:!0}),Nv.Processor=Nv.SubWalks=Nv.MatchRecord=Nv.HasWalkedCache=void 0;const Fv=Ym;class Bv{store;constructor(t=new Map){this.store=t}copy(){return new Bv(new Map(this.store))}hasWalked(t,e){return this.store.get(t.fullpath())?.has(e.globString())}storeWalked(t,e){const r=t.fullpath(),n=this.store.get(r);n?n.add(e.globString()):this.store.set(r,new Set([e.globString()]))}}Nv.HasWalkedCache=Bv;class Wv{store=new Map;add(t,e,r){const n=(e?2:0)|(r?1:0),i=this.store.get(t);this.store.set(t,void 0===i?n:n&i)}entries(){return[...this.store.entries()].map(([t,e])=>[t,!!(2&e),!!(1&e)])}}Nv.MatchRecord=Wv;class Uv{store=new Map;add(t,e){if(!t.canReaddir())return;const r=this.store.get(t);r?r.find(t=>t.globString()===e.globString())||r.push(e):this.store.set(t,[e])}get(t){const e=this.store.get(t);if(!e)throw new Error("attempting to walk unknown path");return e}entries(){return this.keys().map(t=>[t,this.store.get(t)])}keys(){return[...this.store.keys()].filter(t=>t.canReaddir())}}Nv.SubWalks=Uv;class zv{hasWalkedCache;matches=new Wv;subwalks=new Uv;patterns;follow;dot;opts;constructor(t,e){this.opts=t,this.follow=!!t.follow,this.dot=!!t.dot,this.hasWalkedCache=e?e.copy():new Bv}processPatterns(t,e){this.patterns=e;const r=e.map(e=>[t,e]);for(let[t,e]of r){this.hasWalkedCache.storeWalked(t,e);const r=e.root(),n=e.isAbsolute()&&!1!==this.opts.absolute;if(r){t=t.resolve("/"===r&&void 0!==this.opts.root?this.opts.root:r);const n=e.rest();if(!n){this.matches.add(t,!0,!1);continue}e=n}if(t.isENOENT())continue;let i,o,s=!1;for(;"string"==typeof(i=e.pattern())&&(o=e.rest());){const r=t.resolve(i);t=r,e=o,s=!0}if(i=e.pattern(),o=e.rest(),s){if(this.hasWalkedCache.hasWalked(t,e))continue;this.hasWalkedCache.storeWalked(t,e)}if("string"==typeof i){const e=".."===i||""===i||"."===i;this.matches.add(t.resolve(i),n,e);continue}if(i===Fv.GLOBSTAR){(!t.isSymbolicLink()||this.follow||e.checkFollowGlobstar())&&this.subwalks.add(t,e);const r=o?.pattern(),i=o?.rest();if(o&&(""!==r&&"."!==r||i)){if(".."===r){const e=t.parent||t;i?this.hasWalkedCache.hasWalked(e,i)||this.subwalks.add(e,i):this.matches.add(e,n,!0)}}else this.matches.add(t,n,""===r||"."===r)}else i instanceof RegExp&&this.subwalks.add(t,e)}return this}subwalkTargets(){return this.subwalks.keys()}child(){return new zv(this.opts,this.hasWalkedCache)}filterEntries(t,e){const r=this.subwalks.get(t),n=this.child();for(const t of e)for(const e of r){const r=e.isAbsolute(),i=e.pattern(),o=e.rest();i===Fv.GLOBSTAR?n.testGlobstar(t,e,o,r):i instanceof RegExp?n.testRegExp(t,i,o,r):n.testString(t,i,o,r)}return n}testGlobstar(t,e,r,n){if(!this.dot&&t.name.startsWith(".")||(e.hasMore()||this.matches.add(t,n,!1),t.canReaddir()&&(this.follow||!t.isSymbolicLink()?this.subwalks.add(t,e):t.isSymbolicLink()&&(r&&e.checkFollowGlobstar()?this.subwalks.add(t,r):e.markFollowGlobstar()&&this.subwalks.add(t,e)))),r){const e=r.pattern();if("string"==typeof e&&".."!==e&&""!==e&&"."!==e)this.testString(t,e,r.rest(),n);else if(".."===e){const e=t.parent||t;this.subwalks.add(e,r)}else e instanceof RegExp&&this.testRegExp(t,e,r.rest(),n)}}testRegExp(t,e,r,n){e.test(t.name)&&(r?this.subwalks.add(t,r):this.matches.add(t,n,!1))}testString(t,e,r,n){t.isNamed(e)&&(r?this.subwalks.add(t,r):this.matches.add(t,n,!1))}}Nv.Processor=zv,Object.defineProperty(Mv,"__esModule",{value:!0}),Mv.GlobStream=Mv.GlobWalker=Mv.GlobUtil=void 0;const $v=q_,Hv=Iv,Gv=Nv;class qv{path;patterns;opts;seen=new Set;paused=!1;aborted=!1;#le=[];#ue;#ce;signal;maxDepth;includeChildMatches;constructor(t,e,r){if(this.patterns=t,this.path=e,this.opts=r,this.#ce=r.posix||"win32"!==r.platform?"/":"\\",this.includeChildMatches=!1!==r.includeChildMatches,(r.ignore||!this.includeChildMatches)&&(this.#ue=((t,e)=>"string"==typeof t?new Hv.Ignore([t],e):Array.isArray(t)?new Hv.Ignore(t,e):t)(r.ignore??[],r),!this.includeChildMatches&&"function"!=typeof this.#ue.add)){throw new Error("cannot ignore child matches, ignore lacks add() method.")}this.maxDepth=r.maxDepth||1/0,r.signal&&(this.signal=r.signal,this.signal.addEventListener("abort",()=>{this.#le.length=0}))}#he(t){return this.seen.has(t)||!!this.#ue?.ignored?.(t)}#fe(t){return!!this.#ue?.childrenIgnored?.(t)}pause(){this.paused=!0}resume(){if(this.signal?.aborted)return;let t;for(this.paused=!1;!this.paused&&(t=this.#le.shift());)t()}onResume(t){this.signal?.aborted||(this.paused?this.#le.push(t):t())}async matchCheck(t,e){if(e&&this.opts.nodir)return;let r;if(this.opts.realpath){if(r=t.realpathCached()||await t.realpath(),!r)return;t=r}const n=t.isUnknown()||this.opts.stat?await t.lstat():t;if(this.opts.follow&&this.opts.nodir&&n?.isSymbolicLink()){const t=await n.realpath();t&&(t.isUnknown()||this.opts.stat)&&await t.lstat()}return this.matchCheckTest(n,e)}matchCheckTest(t,e){return!t||!(this.maxDepth===1/0||t.depth()<=this.maxDepth)||e&&!t.canReaddir()||this.opts.nodir&&t.isDirectory()||this.opts.nodir&&this.opts.follow&&t.isSymbolicLink()&&t.realpathCached()?.isDirectory()||this.#he(t)?void 0:t}matchCheckSync(t,e){if(e&&this.opts.nodir)return;let r;if(this.opts.realpath){if(r=t.realpathCached()||t.realpathSync(),!r)return;t=r}const n=t.isUnknown()||this.opts.stat?t.lstatSync():t;if(this.opts.follow&&this.opts.nodir&&n?.isSymbolicLink()){const t=n.realpathSync();t&&(t?.isUnknown()||this.opts.stat)&&t.lstatSync()}return this.matchCheckTest(n,e)}matchFinish(t,e){if(this.#he(t))return;if(!this.includeChildMatches&&this.#ue?.add){const e=`${t.relativePosix()}/**`;this.#ue.add(e)}const r=void 0===this.opts.absolute?e:this.opts.absolute;this.seen.add(t);const n=this.opts.mark&&t.isDirectory()?this.#ce:"";if(this.opts.withFileTypes)this.matchEmit(t);else if(r){const e=this.opts.posix?t.fullpathPosix():t.fullpath();this.matchEmit(e+n)}else{const e=this.opts.posix?t.relativePosix():t.relative(),r=this.opts.dotRelative&&!e.startsWith(".."+this.#ce)?"."+this.#ce:"";this.matchEmit(e?r+e+n:"."+n)}}async match(t,e,r){const n=await this.matchCheck(t,r);n&&this.matchFinish(n,e)}matchSync(t,e,r){const n=this.matchCheckSync(t,r);n&&this.matchFinish(n,e)}walkCB(t,e,r){this.signal?.aborted&&r(),this.walkCB2(t,e,new Gv.Processor(this.opts),r)}walkCB2(t,e,r,n){if(this.#fe(t))return n();if(this.signal?.aborted&&n(),this.paused)return void this.onResume(()=>this.walkCB2(t,e,r,n));r.processPatterns(t,e);let i=1;const o=()=>{0===--i&&n()};for(const[t,e,n]of r.matches.entries())this.#he(t)||(i++,this.match(t,e,n).then(()=>o()));for(const t of r.subwalkTargets()){if(this.maxDepth!==1/0&&t.depth()>=this.maxDepth)continue;i++;const e=t.readdirCached();t.calledReaddir()?this.walkCB3(t,e,r,o):t.readdirCB((e,n)=>this.walkCB3(t,n,r,o),!0)}o()}walkCB3(t,e,r,n){r=r.filterEntries(t,e);let i=1;const o=()=>{0===--i&&n()};for(const[t,e,n]of r.matches.entries())this.#he(t)||(i++,this.match(t,e,n).then(()=>o()));for(const[t,e]of r.subwalks.entries())i++,this.walkCB2(t,e,r.child(),o);o()}walkCBSync(t,e,r){this.signal?.aborted&&r(),this.walkCB2Sync(t,e,new Gv.Processor(this.opts),r)}walkCB2Sync(t,e,r,n){if(this.#fe(t))return n();if(this.signal?.aborted&&n(),this.paused)return void this.onResume(()=>this.walkCB2Sync(t,e,r,n));r.processPatterns(t,e);let i=1;const o=()=>{0===--i&&n()};for(const[t,e,n]of r.matches.entries())this.#he(t)||this.matchSync(t,e,n);for(const t of r.subwalkTargets()){if(this.maxDepth!==1/0&&t.depth()>=this.maxDepth)continue;i++;const e=t.readdirSync();this.walkCB3Sync(t,e,r,o)}o()}walkCB3Sync(t,e,r,n){r=r.filterEntries(t,e);let i=1;const o=()=>{0===--i&&n()};for(const[t,e,n]of r.matches.entries())this.#he(t)||this.matchSync(t,e,n);for(const[t,e]of r.subwalks.entries())i++,this.walkCB2Sync(t,e,r.child(),o);o()}}Mv.GlobUtil=qv;Mv.GlobWalker=class extends qv{matches=new Set;constructor(t,e,r){super(t,e,r)}matchEmit(t){this.matches.add(t)}async walk(){if(this.signal?.aborted)throw this.signal.reason;return this.path.isUnknown()&&await this.path.lstat(),await new Promise((t,e)=>{this.walkCB(this.path,this.patterns,()=>{this.signal?.aborted?e(this.signal.reason):t(this.matches)})}),this.matches}walkSync(){if(this.signal?.aborted)throw this.signal.reason;return this.path.isUnknown()&&this.path.lstatSync(),this.walkCBSync(this.path,this.patterns,()=>{if(this.signal?.aborted)throw this.signal.reason}),this.matches}};Mv.GlobStream=class extends qv{results;constructor(t,e,r){super(t,e,r),this.results=new $v.Minipass({signal:this.signal,objectMode:!0}),this.results.on("drain",()=>this.resume()),this.results.on("resume",()=>this.resume())}matchEmit(t){this.results.write(t),this.results.flowing||this.pause()}stream(){const t=this.path;return t.isUnknown()?t.lstat().then(()=>{this.walkCB(t,this.patterns,()=>this.results.end())}):this.walkCB(t,this.patterns,()=>this.results.end()),this.results}streamSync(){return this.path.isUnknown()&&this.path.lstatSync(),this.walkCBSync(this.path,this.patterns,()=>this.results.end()),this.results}},Object.defineProperty(M_,"__esModule",{value:!0}),M_.Glob=void 0;const Vv=Ym,Zv=l,Yv=I_,Kv=Ov,Qv=Mv,Jv="object"==typeof process&&process&&"string"==typeof process.platform?process.platform:"linux";class Xv{absolute;cwd;root;dot;dotRelative;follow;ignore;magicalBraces;mark;matchBase;maxDepth;nobrace;nocase;nodir;noext;noglobstar;pattern;platform;realpath;scurry;stat;signal;windowsPathsNoEscape;withFileTypes;includeChildMatches;opts;patterns;constructor(t,e){if(!e)throw new TypeError("glob options required");if(this.withFileTypes=!!e.withFileTypes,this.signal=e.signal,this.follow=!!e.follow,this.dot=!!e.dot,this.dotRelative=!!e.dotRelative,this.nodir=!!e.nodir,this.mark=!!e.mark,e.cwd?(e.cwd instanceof URL||e.cwd.startsWith("file://"))&&(e.cwd=(0,Zv.fileURLToPath)(e.cwd)):this.cwd="",this.cwd=e.cwd||"",this.root=e.root,this.magicalBraces=!!e.magicalBraces,this.nobrace=!!e.nobrace,this.noext=!!e.noext,this.realpath=!!e.realpath,this.absolute=e.absolute,this.includeChildMatches=!1!==e.includeChildMatches,this.noglobstar=!!e.noglobstar,this.matchBase=!!e.matchBase,this.maxDepth="number"==typeof e.maxDepth?e.maxDepth:1/0,this.stat=!!e.stat,this.ignore=e.ignore,this.withFileTypes&&void 0!==this.absolute)throw new Error("cannot set absolute and withFileTypes:true");if("string"==typeof t&&(t=[t]),this.windowsPathsNoEscape=!!e.windowsPathsNoEscape||!1===e.allowWindowsEscape,this.windowsPathsNoEscape&&(t=t.map(t=>t.replace(/\\/g,"/"))),this.matchBase){if(e.noglobstar)throw new TypeError("base matching requires globstar");t=t.map(t=>t.includes("/")?t:`./**/${t}`)}if(this.pattern=t,this.platform=e.platform||Jv,this.opts={...e,platform:this.platform},e.scurry){if(this.scurry=e.scurry,void 0!==e.nocase&&e.nocase!==e.scurry.nocase)throw new Error("nocase option contradicts provided scurry option")}else{const t="win32"===e.platform?Yv.PathScurryWin32:"darwin"===e.platform?Yv.PathScurryDarwin:e.platform?Yv.PathScurryPosix:Yv.PathScurry;this.scurry=new t(this.cwd,{nocase:e.nocase,fs:e.fs})}this.nocase=this.scurry.nocase;const r="darwin"===this.platform||"win32"===this.platform,n={...e,dot:this.dot,matchBase:this.matchBase,nobrace:this.nobrace,nocase:this.nocase,nocaseMagicOnly:r,nocomment:!0,noext:this.noext,nonegate:!0,optimizationLevel:2,platform:this.platform,windowsPathsNoEscape:this.windowsPathsNoEscape,debug:!!this.opts.debug},i=this.pattern.map(t=>new Vv.Minimatch(t,n)),[o,s]=i.reduce((t,e)=>(t[0].push(...e.set),t[1].push(...e.globParts),t),[[],[]]);this.patterns=o.map((t,e)=>{const r=s[e];if(!r)throw new Error("invalid pattern object");return new Kv.Pattern(t,r,0,this.platform)})}async walk(){return[...await new Qv.GlobWalker(this.patterns,this.scurry.cwd,{...this.opts,maxDepth:this.maxDepth!==1/0?this.maxDepth+this.scurry.cwd.depth():1/0,platform:this.platform,nocase:this.nocase,includeChildMatches:this.includeChildMatches}).walk()]}walkSync(){return[...new Qv.GlobWalker(this.patterns,this.scurry.cwd,{...this.opts,maxDepth:this.maxDepth!==1/0?this.maxDepth+this.scurry.cwd.depth():1/0,platform:this.platform,nocase:this.nocase,includeChildMatches:this.includeChildMatches}).walkSync()]}stream(){return new Qv.GlobStream(this.patterns,this.scurry.cwd,{...this.opts,maxDepth:this.maxDepth!==1/0?this.maxDepth+this.scurry.cwd.depth():1/0,platform:this.platform,nocase:this.nocase,includeChildMatches:this.includeChildMatches}).stream()}streamSync(){return new Qv.GlobStream(this.patterns,this.scurry.cwd,{...this.opts,maxDepth:this.maxDepth!==1/0?this.maxDepth+this.scurry.cwd.depth():1/0,platform:this.platform,nocase:this.nocase,includeChildMatches:this.includeChildMatches}).streamSync()}iterateSync(){return this.streamSync()[Symbol.iterator]()}[Symbol.iterator](){return this.iterateSync()}iterate(){return this.stream()[Symbol.asyncIterator]()}[Symbol.asyncIterator](){return this.iterate()}}M_.Glob=Xv;var tw={};Object.defineProperty(tw,"__esModule",{value:!0}),tw.hasMagic=void 0;const ew=Ym;tw.hasMagic=(t,e={})=>{Array.isArray(t)||(t=[t]);for(const r of t)if(new ew.Minimatch(r,e).hasMagic())return!0;return!1},function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.glob=t.sync=t.iterate=t.iterateSync=t.stream=t.streamSync=t.Ignore=t.hasMagic=t.Glob=t.unescape=t.escape=void 0,t.globStreamSync=l,t.globStream=u,t.globSync=c,t.globIterateSync=f,t.globIterate=d;const e=Ym,r=M_,n=tw;var i=Ym;Object.defineProperty(t,"escape",{enumerable:!0,get:function(){return i.escape}}),Object.defineProperty(t,"unescape",{enumerable:!0,get:function(){return i.unescape}});var o=M_;Object.defineProperty(t,"Glob",{enumerable:!0,get:function(){return o.Glob}});var s=tw;Object.defineProperty(t,"hasMagic",{enumerable:!0,get:function(){return s.hasMagic}});var a=Iv;function l(t,e={}){return new r.Glob(t,e).streamSync()}function u(t,e={}){return new r.Glob(t,e).stream()}function c(t,e={}){return new r.Glob(t,e).walkSync()}async function h(t,e={}){return new r.Glob(t,e).walk()}function f(t,e={}){return new r.Glob(t,e).iterateSync()}function d(t,e={}){return new r.Glob(t,e).iterate()}Object.defineProperty(t,"Ignore",{enumerable:!0,get:function(){return a.Ignore}}),t.streamSync=l,t.stream=Object.assign(u,{sync:l}),t.iterateSync=f,t.iterate=Object.assign(d,{sync:f}),t.sync=Object.assign(c,{stream:l,iterate:f}),t.glob=Object.assign(h,{glob:h,globSync:c,sync:t.sync,globStream:u,stream:t.stream,globStreamSync:l,streamSync:t.streamSync,globIterate:d,iterate:t.iterate,globIterateSync:f,iterateSync:t.iterateSync,Glob:r.Glob,hasMagic:n.hasMagic,escape:e.escape,unescape:e.unescape}),t.glob.glob=t.glob}(Zm);var rw=Vs,nw=e,iw=Ug,ow=wm,sw=Cm,aw=Vm,lw=Zm,uw=Mg.exports={},cw=/[\/\\]/g;uw.exists=function(){var t=nw.join.apply(nw,arguments);return rw.existsSync(t)},uw.expand=function(...t){var e=aw(t[0])?t.shift():{},r=Array.isArray(t[0])?t[0]:t;if(0===r.length)return[];var n=function(t,e){var r=[];return iw(t).forEach(function(t){var n=0===t.indexOf("!");n&&(t=t.slice(1));var i=e(t);r=n?ow(r,i):sw(r,i)}),r}(r,function(t){return lw.sync(t,e)});return e.filter&&(n=n.filter(function(t){t=nw.join(e.cwd||"",t);try{return"function"==typeof e.filter?e.filter(t):rw.statSync(t)[e.filter]()}catch(t){return!1}})),n},uw.expandMapping=function(t,e,r){r=Object.assign({rename:function(t,e){return nw.join(t||"",e)}},r);var n=[],i={};return uw.expand(r,t).forEach(function(t){var o=t;r.flatten&&(o=nw.basename(o)),r.ext&&(o=o.replace(/(\.[^\/]*)?$/,r.ext));var s=r.rename(e,o,r);r.cwd&&(t=nw.join(r.cwd,t)),s=s.replace(cw,"/"),t=t.replace(cw,"/"),i[s]?i[s].src.push(t):(n.push({src:[t],dest:s}),i[s]=n[n.length-1])}),n},uw.normalizeFilesArray=function(t){var e=[];return t.forEach(function(t){("src"in t||"dest"in t)&&e.push(t)}),0===e.length?[]:(e=_(e).chain().forEach(function(t){"src"in t&&t.src&&(Array.isArray(t.src)?t.src=iw(t.src):t.src=[t.src])}).map(function(t){var e=Object.assign({},t);if(delete e.src,delete e.dest,t.expand)return uw.expandMapping(t.src,t.dest,e).map(function(e){var r=Object.assign({},t);return r.orig=Object.assign({},t),r.src=e.src,r.dest=e.dest,["expand","cwd","flatten","rename","ext"].forEach(function(t){delete r[t]}),r});var r=Object.assign({},t);return r.orig=Object.assign({},t),"src"in r&&Object.defineProperty(r,"src",{enumerable:!0,get:function r(){var n;return"result"in r||(n=t.src,n=Array.isArray(n)?iw(n):[n],r.result=uw.expand(e,n)),r.result}}),"dest"in r&&(r.dest=t.dest),r}).flatten().value(),e)};var hw=Mg.exports,fw=Vs,dw=e,pw=ia,yw=ll,gw=fl,bw=xc;i.Stream;var mw=jg.PassThrough,_w=ks.exports={};_w.file=hw,_w.collectStream=function(t,e){var r=[],n=0;t.on("error",e),t.on("data",function(t){r.push(t),n+=t.length}),t.on("end",function(){var t=Buffer.alloc(n),i=0;r.forEach(function(e){e.copy(t,i),i+=e.length}),e(null,t)})},_w.dateify=function(t){return(t=t||new Date)instanceof Date||(t="string"==typeof t?new Date(t):new Date),t},_w.defaults=function(t,e,r){var n=arguments;return n[0]=n[0]||{},bw(...n)},_w.isStream=function(t){return pw(t)},_w.lazyReadStream=function(t){return new yw.Readable(function(){return fw.createReadStream(t)})},_w.normalizeInputSource=function(t){return null===t?Buffer.alloc(0):"string"==typeof t?Buffer.from(t):_w.isStream(t)?t.pipe(new mw):t},_w.sanitizePath=function(t){return gw(t,!1).replace(/^\w+:/,"").replace(/^(\.\.\/|\/)+/,"")},_w.trailingSlashIt=function(t){return"/"!==t.slice(-1)?t+"/":t},_w.unixifyPath=function(t){return gw(t,!1).replace(/^\w+:/,"")},_w.walkdir=function(t,e,r){var n=[];"function"==typeof e&&(r=e,e=t),fw.readdir(t,function(i,o){var s,a,l=0;if(i)return r(i);!function i(){if(!(s=o[l++]))return r(null,n);a=dw.join(t,s),fw.stat(a,function(t,o){n.push({path:a,relative:dw.relative(e,a).replace(/\\/g,"/"),stats:o}),o&&o.isDirectory()?_w.walkdir(a,e,function(t,e){if(t)return r(t);e.forEach(function(t){n.push(t)}),i()}):i()})}()})};var vw=ks.exports,ww={exports:{}};
23
- /**
24
- * Archiver Core
25
- *
26
- * @ignore
27
- * @license [MIT]{@link https://github.com/archiverjs/node-archiver/blob/master/LICENSE}
28
- * @copyright (c) 2012-2014 Chris Talkington, contributors.
29
- */
30
- !function(t){const e={ABORTED:"archive was aborted",DIRECTORYDIRPATHREQUIRED:"diretory dirpath argument must be a non-empty string value",DIRECTORYFUNCTIONINVALIDDATA:"invalid data returned by directory custom data function",ENTRYNAMEREQUIRED:"entry name must be a non-empty string value",FILEFILEPATHREQUIRED:"file filepath argument must be a non-empty string value",FINALIZING:"archive already finalizing",QUEUECLOSED:"queue closed",NOENDMETHOD:"no suitable finalize/end method defined by module",DIRECTORYNOTSUPPORTED:"support for directory entries not defined by module",FORMATSET:"archive format already set",INPUTSTEAMBUFFERREQUIRED:"input source must be valid Stream or Buffer instance",MODULESET:"module already set",SYMLINKNOTSUPPORTED:"support for symlink entries not defined by module",SYMLINKFILEPATHREQUIRED:"symlink filepath argument must be a non-empty string value",SYMLINKTARGETREQUIRED:"symlink target argument must be a non-empty string value",ENTRYNOTSUPPORTED:"entry not supported"};function r(t,r){Error.captureStackTrace(this,this.constructor),this.message=e[t]||t,this.code=t,this.data=r}s.inherits(r,Error),t.exports=r}(ww);var Sw=ww.exports,Ew={exports:{}},Rw={exports:{}};let kw=class extends Error{constructor(t){if(!Array.isArray(t))throw new TypeError("Expected input to be an Array, got "+typeof t);let e="";for(let r=0;r<t.length;r++)e+=` ${t[r].stack}\n`;super(e),this.name="AggregateError",this.errors=t}};var Tw={AggregateError:kw,ArrayIsArray:t=>Array.isArray(t),ArrayPrototypeIncludes:(t,e)=>t.includes(e),ArrayPrototypeIndexOf:(t,e)=>t.indexOf(e),ArrayPrototypeJoin:(t,e)=>t.join(e),ArrayPrototypeMap:(t,e)=>t.map(e),ArrayPrototypePop:(t,e)=>t.pop(e),ArrayPrototypePush:(t,e)=>t.push(e),ArrayPrototypeSlice:(t,e,r)=>t.slice(e,r),Error:Error,FunctionPrototypeCall:(t,e,...r)=>t.call(e,...r),FunctionPrototypeSymbolHasInstance:(t,e)=>Function.prototype[Symbol.hasInstance].call(t,e),MathFloor:Math.floor,Number:Number,NumberIsInteger:Number.isInteger,NumberIsNaN:Number.isNaN,NumberMAX_SAFE_INTEGER:Number.MAX_SAFE_INTEGER,NumberMIN_SAFE_INTEGER:Number.MIN_SAFE_INTEGER,NumberParseInt:Number.parseInt,ObjectDefineProperties:(t,e)=>Object.defineProperties(t,e),ObjectDefineProperty:(t,e,r)=>Object.defineProperty(t,e,r),ObjectGetOwnPropertyDescriptor:(t,e)=>Object.getOwnPropertyDescriptor(t,e),ObjectKeys:t=>Object.keys(t),ObjectSetPrototypeOf:(t,e)=>Object.setPrototypeOf(t,e),Promise:Promise,PromisePrototypeCatch:(t,e)=>t.catch(e),PromisePrototypeThen:(t,e,r)=>t.then(e,r),PromiseReject:t=>Promise.reject(t),PromiseResolve:t=>Promise.resolve(t),ReflectApply:Reflect.apply,RegExpPrototypeTest:(t,e)=>t.test(e),SafeSet:Set,String:String,StringPrototypeSlice:(t,e,r)=>t.slice(e,r),StringPrototypeToLowerCase:t=>t.toLowerCase(),StringPrototypeToUpperCase:t=>t.toUpperCase(),StringPrototypeTrim:t=>t.trim(),Symbol:Symbol,SymbolFor:Symbol.for,SymbolAsyncIterator:Symbol.asyncIterator,SymbolHasInstance:Symbol.hasInstance,SymbolIterator:Symbol.iterator,SymbolDispose:Symbol.dispose||Symbol("Symbol.dispose"),SymbolAsyncDispose:Symbol.asyncDispose||Symbol("Symbol.asyncDispose"),TypedArrayPrototypeSet:(t,e,r)=>t.set(e,r),Boolean:Boolean,Uint8Array:Uint8Array},xw={exports:{}},Aw={format:(t,...e)=>t.replace(/%([sdifj])/g,function(...[t,r]){const n=e.shift();if("f"===r)return n.toFixed(6);if("j"===r)return JSON.stringify(n);if("s"===r&&"object"==typeof n){return`${n.constructor!==Object?n.constructor.name:""} {}`.trim()}return n.toString()}),inspect(t){switch(typeof t){case"string":if(t.includes("'")){if(!t.includes('"'))return`"${t}"`;if(!t.includes("`")&&!t.includes("${"))return`\`${t}\``}return`'${t}'`;case"number":return isNaN(t)?"NaN":Object.is(t,-0)?String(t):t;case"bigint":return`${String(t)}n`;case"boolean":case"undefined":return String(t);case"object":return"{}"}}};const{format:Ow,inspect:Lw}=Aw,{AggregateError:jw}=Tw,Mw=globalThis.AggregateError||jw,Iw=Symbol("kIsNodeError"),Pw=["string","function","number","object","Function","Object","boolean","bigint","symbol"],Dw=/^([A-Z][a-z0-9]*)+$/,Cw={};function Nw(t,e){if(!t)throw new Cw.ERR_INTERNAL_ASSERTION(e)}function Fw(t){let e="",r=t.length;const n="-"===t[0]?1:0;for(;r>=n+4;r-=3)e=`_${t.slice(r-3,r)}${e}`;return`${t.slice(0,r)}${e}`}function Bw(t,e,r){r||(r=Error);class n extends r{constructor(...r){super(function(t,e,r){if("function"==typeof e)return Nw(e.length<=r.length,`Code: ${t}; The provided arguments length (${r.length}) does not match the required ones (${e.length}).`),e(...r);const n=(e.match(/%[dfijoOs]/g)||[]).length;return Nw(n===r.length,`Code: ${t}; The provided arguments length (${r.length}) does not match the required ones (${n}).`),0===r.length?e:Ow(e,...r)}(t,e,r))}toString(){return`${this.name} [${t}]: ${this.message}`}}Object.defineProperties(n.prototype,{name:{value:r.name,writable:!0,enumerable:!1,configurable:!0},toString:{value(){return`${this.name} [${t}]: ${this.message}`},writable:!0,enumerable:!1,configurable:!0}}),n.prototype.code=t,n.prototype[Iw]=!0,Cw[t]=n}function Ww(t){const e="__node_internal_"+t.name;return Object.defineProperty(t,"name",{value:e}),t}let Uw=class extends Error{constructor(t="The operation was aborted",e=void 0){if(void 0!==e&&"object"!=typeof e)throw new Cw.ERR_INVALID_ARG_TYPE("options","Object",e);super(t,e),this.code="ABORT_ERR",this.name="AbortError"}};Bw("ERR_ASSERTION","%s",Error),Bw("ERR_INVALID_ARG_TYPE",(t,e,r)=>{Nw("string"==typeof t,"'name' must be a string"),Array.isArray(e)||(e=[e]);let n="The ";t.endsWith(" argument")?n+=`${t} `:n+=`"${t}" ${t.includes(".")?"property":"argument"} `,n+="must be ";const i=[],o=[],s=[];for(const t of e)Nw("string"==typeof t,"All expected entries have to be of type string"),Pw.includes(t)?i.push(t.toLowerCase()):Dw.test(t)?o.push(t):(Nw("object"!==t,'The value "object" should be written as "Object"'),s.push(t));if(o.length>0){const t=i.indexOf("object");-1!==t&&(i.splice(i,t,1),o.push("Object"))}if(i.length>0){switch(i.length){case 1:n+=`of type ${i[0]}`;break;case 2:n+=`one of type ${i[0]} or ${i[1]}`;break;default:{const t=i.pop();n+=`one of type ${i.join(", ")}, or ${t}`}}(o.length>0||s.length>0)&&(n+=" or ")}if(o.length>0){switch(o.length){case 1:n+=`an instance of ${o[0]}`;break;case 2:n+=`an instance of ${o[0]} or ${o[1]}`;break;default:{const t=o.pop();n+=`an instance of ${o.join(", ")}, or ${t}`}}s.length>0&&(n+=" or ")}switch(s.length){case 0:break;case 1:s[0].toLowerCase()!==s[0]&&(n+="an "),n+=`${s[0]}`;break;case 2:n+=`one of ${s[0]} or ${s[1]}`;break;default:{const t=s.pop();n+=`one of ${s.join(", ")}, or ${t}`}}if(null==r)n+=`. Received ${r}`;else if("function"==typeof r&&r.name)n+=`. Received function ${r.name}`;else if("object"==typeof r){var a;if(null!==(a=r.constructor)&&void 0!==a&&a.name)n+=`. Received an instance of ${r.constructor.name}`;else{n+=`. Received ${Lw(r,{depth:-1})}`}}else{let t=Lw(r,{colors:!1});t.length>25&&(t=`${t.slice(0,25)}...`),n+=`. Received type ${typeof r} (${t})`}return n},TypeError),Bw("ERR_INVALID_ARG_VALUE",(t,e,r="is invalid")=>{let n=Lw(e);n.length>128&&(n=n.slice(0,128)+"...");return`The ${t.includes(".")?"property":"argument"} '${t}' ${r}. Received ${n}`},TypeError),Bw("ERR_INVALID_RETURN_VALUE",(t,e,r)=>{var n;return`Expected ${t} to be returned from the "${e}" function but got ${null!=r&&null!==(n=r.constructor)&&void 0!==n&&n.name?`instance of ${r.constructor.name}`:"type "+typeof r}.`},TypeError),Bw("ERR_MISSING_ARGS",(...t)=>{let e;Nw(t.length>0,"At least one arg needs to be specified");const r=t.length;switch(t=(Array.isArray(t)?t:[t]).map(t=>`"${t}"`).join(" or "),r){case 1:e+=`The ${t[0]} argument`;break;case 2:e+=`The ${t[0]} and ${t[1]} arguments`;break;default:{const r=t.pop();e+=`The ${t.join(", ")}, and ${r} arguments`}}return`${e} must be specified`},TypeError),Bw("ERR_OUT_OF_RANGE",(t,e,r)=>{let n;if(Nw(e,'Missing "range" argument'),Number.isInteger(r)&&Math.abs(r)>2**32)n=Fw(String(r));else if("bigint"==typeof r){n=String(r);const t=BigInt(2)**BigInt(32);(r>t||r<-t)&&(n=Fw(n)),n+="n"}else n=Lw(r);return`The value of "${t}" is out of range. It must be ${e}. Received ${n}`},RangeError),Bw("ERR_MULTIPLE_CALLBACK","Callback called multiple times",Error),Bw("ERR_METHOD_NOT_IMPLEMENTED","The %s method is not implemented",Error),Bw("ERR_STREAM_ALREADY_FINISHED","Cannot call %s after a stream was finished",Error),Bw("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable",Error),Bw("ERR_STREAM_DESTROYED","Cannot call %s after a stream was destroyed",Error),Bw("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),Bw("ERR_STREAM_PREMATURE_CLOSE","Premature close",Error),Bw("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF",Error),Bw("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event",Error),Bw("ERR_STREAM_WRITE_AFTER_END","write after end",Error),Bw("ERR_UNKNOWN_ENCODING","Unknown encoding: %s",TypeError);var zw={AbortError:Uw,aggregateTwoErrors:Ww(function(t,e){if(t&&e&&t!==e){if(Array.isArray(e.errors))return e.errors.push(t),e;const r=new Mw([e,t],e.message);return r.code=e.code,r}return t||e}),hideStackFrames:Ww,codes:Cw};!function(t){const e=ca,{format:r,inspect:n}=Aw,{codes:{ERR_INVALID_ARG_TYPE:i}}=zw,{kResistStopPropagation:o,AggregateError:s,SymbolDispose:a}=Tw,l=globalThis.AbortSignal||Kc().AbortSignal,u=globalThis.AbortController||Kc().AbortController,c=Object.getPrototypeOf(async function(){}).constructor,h=globalThis.Blob||e.Blob,f=void 0!==h?function(t){return t instanceof h}:function(t){return!1},d=(t,e)=>{if(void 0!==t&&(null===t||"object"!=typeof t||!("aborted"in t)))throw new i(e,"AbortSignal",t)};t.exports={AggregateError:s,kEmptyObject:Object.freeze({}),once(t){let e=!1;return function(...r){e||(e=!0,t.apply(this,r))}},createDeferredPromise:function(){let t,e;return{promise:new Promise((r,n)=>{t=r,e=n}),resolve:t,reject:e}},promisify:t=>new Promise((e,r)=>{t((t,...n)=>t?r(t):e(...n))}),debuglog:()=>function(){},format:r,inspect:n,types:{isAsyncFunction:t=>t instanceof c,isArrayBufferView:t=>ArrayBuffer.isView(t)},isBlob:f,deprecate:(t,e)=>t,addAbortListener:yn.addAbortListener||function(t,e){if(void 0===t)throw new i("signal","AbortSignal",t);let r;return d(t,"signal"),((t,e)=>{if("function"!=typeof t)throw new i(e,"Function",t)})(e,"listener"),t.aborted?queueMicrotask(()=>e()):(t.addEventListener("abort",e,{__proto__:null,once:!0,[o]:!0}),r=()=>{t.removeEventListener("abort",e)}),{__proto__:null,[a](){var t;null===(t=r)||void 0===t||t()}}},AbortSignalAny:l.any||function(t){if(1===t.length)return t[0];const e=new u,r=()=>e.abort();return t.forEach(t=>{d(t,"signals"),t.addEventListener("abort",r,{once:!0})}),e.signal.addEventListener("abort",()=>{t.forEach(t=>t.removeEventListener("abort",r))},{once:!0}),e.signal}},t.exports.promisify.custom=Symbol.for("nodejs.util.promisify.custom")}(xw);var $w=xw.exports,Hw={};const{ArrayIsArray:Gw,ArrayPrototypeIncludes:qw,ArrayPrototypeJoin:Vw,ArrayPrototypeMap:Zw,NumberIsInteger:Yw,NumberIsNaN:Kw,NumberMAX_SAFE_INTEGER:Qw,NumberMIN_SAFE_INTEGER:Jw,NumberParseInt:Xw,ObjectPrototypeHasOwnProperty:tS,RegExpPrototypeExec:eS,String:rS,StringPrototypeToUpperCase:nS,StringPrototypeTrim:iS}=Tw,{hideStackFrames:oS,codes:{ERR_SOCKET_BAD_PORT:sS,ERR_INVALID_ARG_TYPE:aS,ERR_INVALID_ARG_VALUE:lS,ERR_OUT_OF_RANGE:uS,ERR_UNKNOWN_SIGNAL:cS}}=zw,{normalizeEncoding:hS}=$w,{isAsyncFunction:fS,isArrayBufferView:dS}=$w.types,pS={};const yS=/^[0-7]+$/;const gS=oS((t,e,r=Jw,n=Qw)=>{if("number"!=typeof t)throw new aS(e,"number",t);if(!Yw(t))throw new uS(e,"an integer",t);if(t<r||t>n)throw new uS(e,`>= ${r} && <= ${n}`,t)}),bS=oS((t,e,r=-2147483648,n=2147483647)=>{if("number"!=typeof t)throw new aS(e,"number",t);if(!Yw(t))throw new uS(e,"an integer",t);if(t<r||t>n)throw new uS(e,`>= ${r} && <= ${n}`,t)}),mS=oS((t,e,r=!1)=>{if("number"!=typeof t)throw new aS(e,"number",t);if(!Yw(t))throw new uS(e,"an integer",t);const n=r?1:0,i=4294967295;if(t<n||t>i)throw new uS(e,`>= ${n} && <= ${i}`,t)});function _S(t,e){if("string"!=typeof t)throw new aS(e,"string",t)}const vS=oS((t,e,r)=>{if(!qw(r,t)){const n=Vw(Zw(r,t=>"string"==typeof t?`'${t}'`:rS(t)),", ");throw new lS(e,t,"must be one of: "+n)}});function wS(t,e){if("boolean"!=typeof t)throw new aS(e,"boolean",t)}function SS(t,e,r){return null!=t&&tS(t,e)?t[e]:r}const ES=oS((t,e,r=null)=>{const n=SS(r,"allowArray",!1),i=SS(r,"allowFunction",!1);if(!SS(r,"nullable",!1)&&null===t||!n&&Gw(t)||"object"!=typeof t&&(!i||"function"!=typeof t))throw new aS(e,"Object",t)}),RS=oS((t,e)=>{if(null!=t&&"object"!=typeof t&&"function"!=typeof t)throw new aS(e,"a dictionary",t)}),kS=oS((t,e,r=0)=>{if(!Gw(t))throw new aS(e,"Array",t);if(t.length<r){throw new lS(e,t,`must be longer than ${r}`)}});const TS=oS((t,e="buffer")=>{if(!dS(t))throw new aS(e,["Buffer","TypedArray","DataView"],t)});const xS=oS((t,e)=>{if(void 0!==t&&(null===t||"object"!=typeof t||!("aborted"in t)))throw new aS(e,"AbortSignal",t)}),AS=oS((t,e)=>{if("function"!=typeof t)throw new aS(e,"Function",t)}),OS=oS((t,e)=>{if("function"!=typeof t||fS(t))throw new aS(e,"Function",t)}),LS=oS((t,e)=>{if(void 0!==t)throw new aS(e,"undefined",t)});const jS=/^(?:<[^>]*>)(?:\s*;\s*[^;"\s]+(?:=(")?[^;"\s]*\1)?)*$/;function MS(t,e){if(void 0===t||!eS(jS,t))throw new lS(e,t,'must be an array or string of format "</styles.css>; rel=preload; as=style"')}var IS={isInt32:function(t){return t===(0|t)},isUint32:function(t){return t===t>>>0},parseFileMode:function(t,e,r){if(void 0===t&&(t=r),"string"==typeof t){if(null===eS(yS,t))throw new lS(e,t,"must be a 32-bit unsigned integer or an octal string");t=Xw(t,8)}return mS(t,e),t},validateArray:kS,validateStringArray:function(t,e){kS(t,e);for(let r=0;r<t.length;r++)_S(t[r],`${e}[${r}]`)},validateBooleanArray:function(t,e){kS(t,e);for(let r=0;r<t.length;r++)wS(t[r],`${e}[${r}]`)},validateAbortSignalArray:function(t,e){kS(t,e);for(let r=0;r<t.length;r++){const n=t[r],i=`${e}[${r}]`;if(null==n)throw new aS(i,"AbortSignal",n);xS(n,i)}},validateBoolean:wS,validateBuffer:TS,validateDictionary:RS,validateEncoding:function(t,e){const r=hS(e),n=t.length;if("hex"===r&&n%2!=0)throw new lS("encoding",e,`is invalid for data of length ${n}`)},validateFunction:AS,validateInt32:bS,validateInteger:gS,validateNumber:function(t,e,r=void 0,n){if("number"!=typeof t)throw new aS(e,"number",t);if(null!=r&&t<r||null!=n&&t>n||(null!=r||null!=n)&&Kw(t))throw new uS(e,`${null!=r?`>= ${r}`:""}${null!=r&&null!=n?" && ":""}${null!=n?`<= ${n}`:""}`,t)},validateObject:ES,validateOneOf:vS,validatePlainFunction:OS,validatePort:function(t,e="Port",r=!0){if("number"!=typeof t&&"string"!=typeof t||"string"==typeof t&&0===iS(t).length||+t!==+t>>>0||t>65535||0===t&&!r)throw new sS(e,t,r);return 0|t},validateSignalName:function(t,e="signal"){if(_S(t,e),void 0===pS[t]){if(void 0!==pS[nS(t)])throw new cS(t+" (signals must use all capital letters)");throw new cS(t)}},validateString:_S,validateUint32:mS,validateUndefined:LS,validateUnion:function(t,e,r){if(!qw(r,t))throw new aS(e,`('${Vw(r,"|")}')`,t)},validateAbortSignal:xS,validateLinkHeaderValue:function(t){if("string"==typeof t)return MS(t,"hints"),t;if(Gw(t)){const e=t.length;let r="";if(0===e)return r;for(let n=0;n<e;n++){const i=t[n];MS(i,"hints"),r+=i,n!==e-1&&(r+=", ")}return r}throw new lS("hints",t,'must be an array or string of format "</styles.css>; rel=preload; as=style"')}},PS={exports:{}};const{SymbolAsyncIterator:DS,SymbolIterator:CS,SymbolFor:NS}=Tw,FS=NS("nodejs.stream.destroyed"),BS=NS("nodejs.stream.errored"),WS=NS("nodejs.stream.readable"),US=NS("nodejs.stream.writable"),zS=NS("nodejs.stream.disturbed"),$S=NS("nodejs.webstream.isClosedPromise"),HS=NS("nodejs.webstream.controllerErrorFunction");function GS(t,e=!1){var r;return!(!t||"function"!=typeof t.pipe||"function"!=typeof t.on||e&&("function"!=typeof t.pause||"function"!=typeof t.resume)||t._writableState&&!1===(null===(r=t._readableState)||void 0===r?void 0:r.readable)||t._writableState&&!t._readableState)}function qS(t){var e;return!(!t||"function"!=typeof t.write||"function"!=typeof t.on||t._readableState&&!1===(null===(e=t._writableState)||void 0===e?void 0:e.writable))}function VS(t){return t&&(t._readableState||t._writableState||"function"==typeof t.write&&"function"==typeof t.on||"function"==typeof t.pipe&&"function"==typeof t.on)}function ZS(t){return!(!t||VS(t)||"function"!=typeof t.pipeThrough||"function"!=typeof t.getReader||"function"!=typeof t.cancel)}function YS(t){return!(!t||VS(t)||"function"!=typeof t.getWriter||"function"!=typeof t.abort)}function KS(t){return!(!t||VS(t)||"object"!=typeof t.readable||"object"!=typeof t.writable)}function QS(t){if(!VS(t))return null;const e=t._writableState,r=t._readableState,n=e||r;return!!(t.destroyed||t[FS]||null!=n&&n.destroyed)}function JS(t){if(!qS(t))return null;if(!0===t.writableEnded)return!0;const e=t._writableState;return(null==e||!e.errored)&&("boolean"!=typeof(null==e?void 0:e.ended)?null:e.ended)}function XS(t,e){if(!GS(t))return null;const r=t._readableState;return(null==r||!r.errored)&&("boolean"!=typeof(null==r?void 0:r.endEmitted)?null:!!(r.endEmitted||!1===e&&!0===r.ended&&0===r.length))}function tE(t){return t&&null!=t[WS]?t[WS]:"boolean"!=typeof(null==t?void 0:t.readable)?null:!QS(t)&&(GS(t)&&t.readable&&!XS(t))}function eE(t){return t&&null!=t[US]?t[US]:"boolean"!=typeof(null==t?void 0:t.writable)?null:!QS(t)&&(qS(t)&&t.writable&&!JS(t))}function rE(t){return"boolean"==typeof t._closed&&"boolean"==typeof t._defaultKeepAlive&&"boolean"==typeof t._removedConnection&&"boolean"==typeof t._removedContLen}function nE(t){return"boolean"==typeof t._sent100&&rE(t)}var iE={isDestroyed:QS,kIsDestroyed:FS,isDisturbed:function(t){var e;return!(!t||!(null!==(e=t[zS])&&void 0!==e?e:t.readableDidRead||t.readableAborted))},kIsDisturbed:zS,isErrored:function(t){var e,r,n,i,o,s,a,l,u,c;return!(!t||!(null!==(e=null!==(r=null!==(n=null!==(i=null!==(o=null!==(s=t[BS])&&void 0!==s?s:t.readableErrored)&&void 0!==o?o:t.writableErrored)&&void 0!==i?i:null===(a=t._readableState)||void 0===a?void 0:a.errorEmitted)&&void 0!==n?n:null===(l=t._writableState)||void 0===l?void 0:l.errorEmitted)&&void 0!==r?r:null===(u=t._readableState)||void 0===u?void 0:u.errored)&&void 0!==e?e:null===(c=t._writableState)||void 0===c?void 0:c.errored))},kIsErrored:BS,isReadable:tE,kIsReadable:WS,kIsClosedPromise:$S,kControllerErrorFunction:HS,kIsWritable:US,isClosed:function(t){if(!VS(t))return null;if("boolean"==typeof t.closed)return t.closed;const e=t._writableState,r=t._readableState;return"boolean"==typeof(null==e?void 0:e.closed)||"boolean"==typeof(null==r?void 0:r.closed)?(null==e?void 0:e.closed)||(null==r?void 0:r.closed):"boolean"==typeof t._closed&&rE(t)?t._closed:null},isDuplexNodeStream:function(t){return!(!t||"function"!=typeof t.pipe||!t._readableState||"function"!=typeof t.on||"function"!=typeof t.write)},isFinished:function(t,e){return VS(t)?!!QS(t)||(!1===(null==e?void 0:e.readable)||!tE(t))&&(!1===(null==e?void 0:e.writable)||!eE(t)):null},isIterable:function(t,e){return null!=t&&(!0===e?"function"==typeof t[DS]:!1===e?"function"==typeof t[CS]:"function"==typeof t[DS]||"function"==typeof t[CS])},isReadableNodeStream:GS,isReadableStream:ZS,isReadableEnded:function(t){if(!GS(t))return null;if(!0===t.readableEnded)return!0;const e=t._readableState;return!(!e||e.errored)&&("boolean"!=typeof(null==e?void 0:e.ended)?null:e.ended)},isReadableFinished:XS,isReadableErrored:function(t){var e,r;return VS(t)?t.readableErrored?t.readableErrored:null!==(e=null===(r=t._readableState)||void 0===r?void 0:r.errored)&&void 0!==e?e:null:null},isNodeStream:VS,isWebStream:function(t){return ZS(t)||YS(t)||KS(t)},isWritable:eE,isWritableNodeStream:qS,isWritableStream:YS,isWritableEnded:JS,isWritableFinished:function(t,e){if(!qS(t))return null;if(!0===t.writableFinished)return!0;const r=t._writableState;return(null==r||!r.errored)&&("boolean"!=typeof(null==r?void 0:r.finished)?null:!!(r.finished||!1===e&&!0===r.ended&&0===r.length))},isWritableErrored:function(t){var e,r;return VS(t)?t.writableErrored?t.writableErrored:null!==(e=null===(r=t._writableState)||void 0===r?void 0:r.errored)&&void 0!==e?e:null:null},isServerRequest:function(t){var e;return"boolean"==typeof t._consuming&&"boolean"==typeof t._dumped&&void 0===(null===(e=t.req)||void 0===e?void 0:e.upgradeOrConnect)},isServerResponse:nE,willEmitClose:function(t){if(!VS(t))return null;const e=t._writableState,r=t._readableState,n=e||r;return!n&&nE(t)||!!(n&&n.autoDestroy&&n.emitClose&&!1===n.closed)},isTransformStream:KS};const oE=of,{AbortError:sE,codes:aE}=zw,{ERR_INVALID_ARG_TYPE:lE,ERR_STREAM_PREMATURE_CLOSE:uE}=aE,{kEmptyObject:cE,once:hE}=$w,{validateAbortSignal:fE,validateFunction:dE,validateObject:pE,validateBoolean:yE}=IS,{Promise:gE,PromisePrototypeThen:bE,SymbolDispose:mE}=Tw,{isClosed:_E,isReadable:vE,isReadableNodeStream:wE,isReadableStream:SE,isReadableFinished:EE,isReadableErrored:RE,isWritable:kE,isWritableNodeStream:TE,isWritableStream:xE,isWritableFinished:AE,isWritableErrored:OE,isNodeStream:LE,willEmitClose:jE,kIsClosedPromise:ME}=iE;let IE;const PE=()=>{};function DE(t,e,r){var n,i;if(2===arguments.length?(r=e,e=cE):null==e?e=cE:pE(e,"options"),dE(r,"callback"),fE(e.signal,"options.signal"),r=hE(r),SE(t)||xE(t))return function(t,e,r){let n=!1,i=PE;if(e.signal)if(i=()=>{n=!0,r.call(t,new sE(void 0,{cause:e.signal.reason}))},e.signal.aborted)oE.nextTick(i);else{IE=IE||$w.addAbortListener;const n=IE(e.signal,i),o=r;r=hE((...e)=>{n[mE](),o.apply(t,e)})}const o=(...e)=>{n||oE.nextTick(()=>r.apply(t,e))};return bE(t[ME].promise,o,o),PE}(t,e,r);if(!LE(t))throw new lE("stream",["ReadableStream","WritableStream","Stream"],t);const o=null!==(n=e.readable)&&void 0!==n?n:wE(t),s=null!==(i=e.writable)&&void 0!==i?i:TE(t),a=t._writableState,l=t._readableState,u=()=>{t.writable||f()};let c=jE(t)&&wE(t)===o&&TE(t)===s,h=AE(t,!1);const f=()=>{h=!0,t.destroyed&&(c=!1),(!c||t.readable&&!o)&&(o&&!d||r.call(t))};let d=EE(t,!1);const p=()=>{d=!0,t.destroyed&&(c=!1),(!c||t.writable&&!s)&&(s&&!h||r.call(t))},y=e=>{r.call(t,e)};let g=_E(t);const b=()=>{g=!0;const e=OE(t)||RE(t);return e&&"boolean"!=typeof e?r.call(t,e):o&&!d&&wE(t,!0)&&!EE(t,!1)?r.call(t,new uE):!s||h||AE(t,!1)?void r.call(t):r.call(t,new uE)},m=()=>{g=!0;const e=OE(t)||RE(t);if(e&&"boolean"!=typeof e)return r.call(t,e);r.call(t)},_=()=>{t.req.on("finish",f)};!function(t){return t.setHeader&&"function"==typeof t.abort}(t)?s&&!a&&(t.on("end",u),t.on("close",u)):(t.on("complete",f),c||t.on("abort",b),t.req?_():t.on("request",_)),c||"boolean"!=typeof t.aborted||t.on("aborted",b),t.on("end",p),t.on("finish",f),!1!==e.error&&t.on("error",y),t.on("close",b),g?oE.nextTick(b):null!=a&&a.errorEmitted||null!=l&&l.errorEmitted?c||oE.nextTick(m):(o||c&&!vE(t)||!h&&!1!==kE(t))&&(s||c&&!kE(t)||!d&&!1!==vE(t))?l&&t.req&&t.aborted&&oE.nextTick(m):oE.nextTick(m);const v=()=>{r=PE,t.removeListener("aborted",b),t.removeListener("complete",f),t.removeListener("abort",b),t.removeListener("request",_),t.req&&t.req.removeListener("finish",f),t.removeListener("end",u),t.removeListener("close",u),t.removeListener("finish",f),t.removeListener("end",p),t.removeListener("error",y),t.removeListener("close",b)};if(e.signal&&!g){const n=()=>{const n=r;v(),n.call(t,new sE(void 0,{cause:e.signal.reason}))};if(e.signal.aborted)oE.nextTick(n);else{IE=IE||$w.addAbortListener;const i=IE(e.signal,n),o=r;r=hE((...e)=>{i[mE](),o.apply(t,e)})}}return v}PS.exports=DE,PS.exports.finished=function(t,e){var r;let n=!1;return null===e&&(e=cE),null!==(r=e)&&void 0!==r&&r.cleanup&&(yE(e.cleanup,"cleanup"),n=e.cleanup),new gE((r,i)=>{const o=DE(t,e,t=>{n&&o(),t?i(t):r()})})};var CE=PS.exports;const NE=of,{aggregateTwoErrors:FE,codes:{ERR_MULTIPLE_CALLBACK:BE},AbortError:WE}=zw,{Symbol:UE}=Tw,{kIsDestroyed:zE,isDestroyed:$E,isFinished:HE,isServerRequest:GE}=iE,qE=UE("kDestroy"),VE=UE("kConstruct");function ZE(t,e,r){t&&(t.stack,e&&!e.errored&&(e.errored=t),r&&!r.errored&&(r.errored=t))}function YE(t,e,r){let n=!1;function i(e){if(n)return;n=!0;const i=t._readableState,o=t._writableState;ZE(e,o,i),o&&(o.closed=!0),i&&(i.closed=!0),"function"==typeof r&&r(e),e?NE.nextTick(KE,t,e):NE.nextTick(QE,t)}try{t._destroy(e||null,i)}catch(e){i(e)}}function KE(t,e){JE(t,e),QE(t)}function QE(t){const e=t._readableState,r=t._writableState;r&&(r.closeEmitted=!0),e&&(e.closeEmitted=!0),(null!=r&&r.emitClose||null!=e&&e.emitClose)&&t.emit("close")}function JE(t,e){const r=t._readableState,n=t._writableState;null!=n&&n.errorEmitted||null!=r&&r.errorEmitted||(n&&(n.errorEmitted=!0),r&&(r.errorEmitted=!0),t.emit("error",e))}function XE(t,e,r){const n=t._readableState,i=t._writableState;if(null!=i&&i.destroyed||null!=n&&n.destroyed)return this;null!=n&&n.autoDestroy||null!=i&&i.autoDestroy?t.destroy(e):e&&(e.stack,i&&!i.errored&&(i.errored=e),n&&!n.errored&&(n.errored=e),r?NE.nextTick(JE,t,e):JE(t,e))}function tR(t){let e=!1;function r(r){if(e)return void XE(t,null!=r?r:new BE);e=!0;const n=t._readableState,i=t._writableState,o=i||n;n&&(n.constructed=!0),i&&(i.constructed=!0),o.destroyed?t.emit(qE,r):r?XE(t,r,!0):NE.nextTick(eR,t)}try{t._construct(t=>{NE.nextTick(r,t)})}catch(t){NE.nextTick(r,t)}}function eR(t){t.emit(VE)}function rR(t){return(null==t?void 0:t.setHeader)&&"function"==typeof t.abort}function nR(t){t.emit("close")}function iR(t,e){t.emit("error",e),NE.nextTick(nR,t)}var oR={construct:function(t,e){if("function"!=typeof t._construct)return;const r=t._readableState,n=t._writableState;r&&(r.constructed=!1),n&&(n.constructed=!1),t.once(VE,e),t.listenerCount(VE)>1||NE.nextTick(tR,t)},destroyer:function(t,e){t&&!$E(t)&&(e||HE(t)||(e=new WE),GE(t)?(t.socket=null,t.destroy(e)):rR(t)?t.abort():rR(t.req)?t.req.abort():"function"==typeof t.destroy?t.destroy(e):"function"==typeof t.close?t.close():e?NE.nextTick(iR,t,e):NE.nextTick(nR,t),t.destroyed||(t[zE]=!0))},destroy:function(t,e){const r=this._readableState,n=this._writableState,i=n||r;return null!=n&&n.destroyed||null!=r&&r.destroyed?("function"==typeof e&&e(),this):(ZE(t,n,r),n&&(n.destroyed=!0),r&&(r.destroyed=!0),i.constructed?YE(this,t,e):this.once(qE,function(r){YE(this,FE(r,t),e)}),this)},undestroy:function(){const t=this._readableState,e=this._writableState;t&&(t.constructed=!0,t.closed=!1,t.closeEmitted=!1,t.destroyed=!1,t.errored=null,t.errorEmitted=!1,t.reading=!1,t.ended=!1===t.readable,t.endEmitted=!1===t.readable),e&&(e.constructed=!0,e.destroyed=!1,e.closed=!1,e.closeEmitted=!1,e.errored=null,e.errorEmitted=!1,e.finalCalled=!1,e.prefinished=!1,e.ended=!1===e.writable,e.ending=!1===e.writable,e.finished=!1===e.writable)},errorOrDestroy:XE};const{ArrayIsArray:sR,ObjectSetPrototypeOf:aR}=Tw,{EventEmitter:lR}=yn;function uR(t){lR.call(this,t)}function cR(t,e,r){if("function"==typeof t.prependListener)return t.prependListener(e,r);t._events&&t._events[e]?sR(t._events[e])?t._events[e].unshift(r):t._events[e]=[r,t._events[e]]:t.on(e,r)}aR(uR.prototype,lR.prototype),aR(uR,lR),uR.prototype.pipe=function(t,e){const r=this;function n(e){t.writable&&!1===t.write(e)&&r.pause&&r.pause()}function i(){r.readable&&r.resume&&r.resume()}r.on("data",n),t.on("drain",i),t._isStdio||e&&!1===e.end||(r.on("end",s),r.on("close",a));let o=!1;function s(){o||(o=!0,t.end())}function a(){o||(o=!0,"function"==typeof t.destroy&&t.destroy())}function l(t){u(),0===lR.listenerCount(this,"error")&&this.emit("error",t)}function u(){r.removeListener("data",n),t.removeListener("drain",i),r.removeListener("end",s),r.removeListener("close",a),r.removeListener("error",l),t.removeListener("error",l),r.removeListener("end",u),r.removeListener("close",u),t.removeListener("close",u)}return cR(r,"error",l),cR(t,"error",l),r.on("end",u),r.on("close",u),t.on("close",u),t.emit("pipe",r),t};var hR={Stream:uR,prependListener:cR},fR={exports:{}};!function(t){const{SymbolDispose:e}=Tw,{AbortError:r,codes:n}=zw,{isNodeStream:i,isWebStream:o,kControllerErrorFunction:s}=iE,a=CE,{ERR_INVALID_ARG_TYPE:l}=n;let u;t.exports.addAbortSignal=function(e,r){if(((t,e)=>{if("object"!=typeof t||!("aborted"in t))throw new l(e,"AbortSignal",t)})(e,"signal"),!i(r)&&!o(r))throw new l("stream",["ReadableStream","WritableStream","Stream"],r);return t.exports.addAbortSignalNoValidate(e,r)},t.exports.addAbortSignalNoValidate=function(t,n){if("object"!=typeof t||!("aborted"in t))return n;const o=i(n)?()=>{n.destroy(new r(void 0,{cause:t.reason}))}:()=>{n[s](new r(void 0,{cause:t.reason}))};if(t.aborted)o();else{u=u||$w.addAbortListener;const r=u(t,o);a(n,r[e])}return n}}(fR);var dR=fR.exports;const{StringPrototypeSlice:pR,SymbolIterator:yR,TypedArrayPrototypeSet:gR,Uint8Array:bR}=Tw,{Buffer:mR}=ca,{inspect:_R}=$w;var vR=class{constructor(){this.head=null,this.tail=null,this.length=0}push(t){const e={data:t,next:null};this.length>0?this.tail.next=e:this.head=e,this.tail=e,++this.length}unshift(t){const e={data:t,next:this.head};0===this.length&&(this.tail=e),this.head=e,++this.length}shift(){if(0===this.length)return;const t=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,t}clear(){this.head=this.tail=null,this.length=0}join(t){if(0===this.length)return"";let e=this.head,r=""+e.data;for(;null!==(e=e.next);)r+=t+e.data;return r}concat(t){if(0===this.length)return mR.alloc(0);const e=mR.allocUnsafe(t>>>0);let r=this.head,n=0;for(;r;)gR(e,r.data,n),n+=r.data.length,r=r.next;return e}consume(t,e){const r=this.head.data;if(t<r.length){const e=r.slice(0,t);return this.head.data=r.slice(t),e}return t===r.length?this.shift():e?this._getString(t):this._getBuffer(t)}first(){return this.head.data}*[yR](){for(let t=this.head;t;t=t.next)yield t.data}_getString(t){let e="",r=this.head,n=0;do{const i=r.data;if(!(t>i.length)){t===i.length?(e+=i,++n,r.next?this.head=r.next:this.head=this.tail=null):(e+=pR(i,0,t),this.head=r,r.data=pR(i,t));break}e+=i,t-=i.length,++n}while(null!==(r=r.next));return this.length-=n,e}_getBuffer(t){const e=mR.allocUnsafe(t),r=t;let n=this.head,i=0;do{const o=n.data;if(!(t>o.length)){t===o.length?(gR(e,o,r-t),++i,n.next?this.head=n.next:this.head=this.tail=null):(gR(e,new bR(o.buffer,o.byteOffset,t),r-t),this.head=n,n.data=o.slice(t));break}gR(e,o,r-t),t-=o.length,++i}while(null!==(n=n.next));return this.length-=i,e}[Symbol.for("nodejs.util.inspect.custom")](t,e){return _R(this,{...e,depth:0,customInspect:!1})}};const{MathFloor:wR,NumberIsInteger:SR}=Tw,{validateInteger:ER}=IS,{ERR_INVALID_ARG_VALUE:RR}=zw.codes;let kR=16384,TR=16;function xR(t){return t?TR:kR}var AR={getHighWaterMark:function(t,e,r,n){const i=function(t,e,r){return null!=t.highWaterMark?t.highWaterMark:e?t[r]:null}(e,n,r);if(null!=i){if(!SR(i)||i<0){throw new RR(n?`options.${r}`:"options.highWaterMark",i)}return wR(i)}return xR(t.objectMode)},getDefaultHighWaterMark:xR,setDefaultHighWaterMark:function(t,e){ER(e,"value",0),t?TR=e:kR=e}},OR={},LR=rp.Buffer,jR=LR.isEncoding||function(t){switch((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 MR(t){var e;switch(this.encoding=function(t){var e=function(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}}(t);if("string"!=typeof e&&(LR.isEncoding===jR||!jR(t)))throw new Error("Unknown encoding: "+t);return e||t}(t),this.encoding){case"utf16le":this.text=DR,this.end=CR,e=4;break;case"utf8":this.fillLast=PR,e=4;break;case"base64":this.text=NR,this.end=FR,e=3;break;default:return this.write=BR,void(this.end=WR)}this.lastNeed=0,this.lastTotal=0,this.lastChar=LR.allocUnsafe(e)}function IR(t){return t<=127?0:t>>5==6?2:t>>4==14?3:t>>3==30?4:t>>6==2?-1:-2}function PR(t){var e=this.lastTotal-this.lastNeed,r=function(t,e){if(128!=(192&e[0]))return t.lastNeed=0,"�";if(t.lastNeed>1&&e.length>1){if(128!=(192&e[1]))return t.lastNeed=1,"�";if(t.lastNeed>2&&e.length>2&&128!=(192&e[2]))return t.lastNeed=2,"�"}}(this,t);return void 0!==r?r:this.lastNeed<=t.length?(t.copy(this.lastChar,e,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(t.copy(this.lastChar,e,0,t.length),void(this.lastNeed-=t.length))}function DR(t,e){if((t.length-e)%2==0){var r=t.toString("utf16le",e);if(r){var n=r.charCodeAt(r.length-1);if(n>=55296&&n<=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 CR(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 NR(t,e){var r=(t.length-e)%3;return 0===r?t.toString("base64",e):(this.lastNeed=3-r,this.lastTotal=3,1===r?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 FR(t){var e=t&&t.length?this.write(t):"";return this.lastNeed?e+this.lastChar.toString("base64",0,3-this.lastNeed):e}function BR(t){return t.toString(this.encoding)}function WR(t){return t&&t.length?this.write(t):""}OR.StringDecoder=MR,MR.prototype.write=function(t){if(0===t.length)return"";var e,r;if(this.lastNeed){if(void 0===(e=this.fillLast(t)))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||""},MR.prototype.end=function(t){var e=t&&t.length?this.write(t):"";return this.lastNeed?e+"�":e},MR.prototype.text=function(t,e){var r=function(t,e,r){var n=e.length-1;if(n<r)return 0;var i=IR(e[n]);if(i>=0)return i>0&&(t.lastNeed=i-1),i;if(--n<r||-2===i)return 0;if(i=IR(e[n]),i>=0)return i>0&&(t.lastNeed=i-2),i;if(--n<r||-2===i)return 0;if(i=IR(e[n]),i>=0)return i>0&&(2===i?i=0:t.lastNeed=i-3),i;return 0}(this,t,e);if(!this.lastNeed)return t.toString("utf8",e);this.lastTotal=r;var n=t.length-(r-this.lastNeed);return t.copy(this.lastChar,0,n),t.toString("utf8",e,n)},MR.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};const UR=of,{PromisePrototypeThen:zR,SymbolAsyncIterator:$R,SymbolIterator:HR}=Tw,{Buffer:GR}=ca,{ERR_INVALID_ARG_TYPE:qR,ERR_STREAM_NULL_VALUES:VR}=zw.codes;var ZR,YR,KR,QR,JR,XR,tk,ek,rk=function(t,e,r){let n,i;if("string"==typeof e||e instanceof GR)return new t({objectMode:!0,...r,read(){this.push(e),this.push(null)}});if(e&&e[$R])i=!0,n=e[$R]();else{if(!e||!e[HR])throw new qR("iterable",["Iterable"],e);i=!1,n=e[HR]()}const o=new t({objectMode:!0,highWaterMark:1,...r});let s=!1;return o._read=function(){s||(s=!0,async function(){for(;;){try{const{value:t,done:e}=i?await n.next():n.next();if(e)o.push(null);else{const e=t&&"function"==typeof t.then?await t:t;if(null===e)throw s=!1,new VR;if(o.push(e))continue;s=!1}}catch(t){o.destroy(t)}break}}())},o._destroy=function(t,e){zR(async function(t){const e=null!=t,r="function"==typeof n.throw;if(e&&r){const{value:e,done:r}=await n.throw(t);if(await e,r)return}if("function"==typeof n.return){const{value:t}=await n.return();await t}}(t),()=>UR.nextTick(e,t),r=>UR.nextTick(e,r||t))},o};function nk(){if(YR)return ZR;YR=1;const t=of,{ArrayPrototypeIndexOf:e,NumberIsInteger:r,NumberIsNaN:n,NumberParseInt:i,ObjectDefineProperties:o,ObjectKeys:s,ObjectSetPrototypeOf:a,Promise:l,SafeSet:u,SymbolAsyncDispose:c,SymbolAsyncIterator:h,Symbol:f}=Tw;ZR=H,H.ReadableState=$;const{EventEmitter:d}=yn,{Stream:p,prependListener:y}=hR,{Buffer:g}=ca,{addAbortSignal:b}=dR,m=CE;let _=$w.debuglog("stream",t=>{_=t});const v=vR,w=oR,{getHighWaterMark:S,getDefaultHighWaterMark:E}=AR,{aggregateTwoErrors:R,codes:{ERR_INVALID_ARG_TYPE:k,ERR_METHOD_NOT_IMPLEMENTED:T,ERR_OUT_OF_RANGE:x,ERR_STREAM_PUSH_AFTER_EOF:A,ERR_STREAM_UNSHIFT_AFTER_END_EVENT:O},AbortError:L}=zw,{validateObject:j}=IS,M=f("kPaused"),{StringDecoder:I}=OR,P=rk;a(H.prototype,p.prototype),a(H,p);const D=()=>{},{errorOrDestroy:C}=w,N=1,F=16,B=32,W=2048,U=4096;function z(t){return{enumerable:!1,get(){return 0!==(this.state&t)},set(e){e?this.state|=t:this.state&=~t}}}function $(t,e,r){"boolean"!=typeof r&&(r=e instanceof sk()),this.state=W|U|F|B,t&&t.objectMode&&(this.state|=N),r&&t&&t.readableObjectMode&&(this.state|=N),this.highWaterMark=t?S(this,t,"readableHighWaterMark",r):E(!1),this.buffer=new v,this.length=0,this.pipes=[],this.flowing=null,this[M]=null,t&&!1===t.emitClose&&(this.state&=~W),t&&!1===t.autoDestroy&&(this.state&=~U),this.errored=null,this.defaultEncoding=t&&t.defaultEncoding||"utf8",this.awaitDrainWriters=null,this.decoder=null,this.encoding=null,t&&t.encoding&&(this.decoder=new I(t.encoding),this.encoding=t.encoding)}function H(t){if(!(this instanceof H))return new H(t);const e=this instanceof sk();this._readableState=new $(t,this,e),t&&("function"==typeof t.read&&(this._read=t.read),"function"==typeof t.destroy&&(this._destroy=t.destroy),"function"==typeof t.construct&&(this._construct=t.construct),t.signal&&!e&&b(t.signal,this)),p.call(this,t),w.construct(this,()=>{this._readableState.needReadable&&K(this,this._readableState)})}function G(t,e,r,n){_("readableAddChunk",e);const i=t._readableState;let o;if(0===(i.state&N)&&("string"==typeof e?(r=r||i.defaultEncoding,i.encoding!==r&&(n&&i.encoding?e=g.from(e,r).toString(i.encoding):(e=g.from(e,r),r=""))):e instanceof g?r="":p._isUint8Array(e)?(e=p._uint8ArrayToBuffer(e),r=""):null!=e&&(o=new k("chunk",["string","Buffer","Uint8Array"],e))),o)C(t,o);else if(null===e)i.state&=-9,function(t,e){if(_("onEofChunk"),e.ended)return;if(e.decoder){const t=e.decoder.end();t&&t.length&&(e.buffer.push(t),e.length+=e.objectMode?1:t.length)}e.ended=!0,e.sync?Z(t):(e.needReadable=!1,e.emittedReadable=!0,Y(t))}(t,i);else if(0!==(i.state&N)||e&&e.length>0)if(n)if(4&i.state)C(t,new O);else{if(i.destroyed||i.errored)return!1;q(t,i,e,!0)}else if(i.ended)C(t,new A);else{if(i.destroyed||i.errored)return!1;i.state&=-9,i.decoder&&!r?(e=i.decoder.write(e),i.objectMode||0!==e.length?q(t,i,e,!1):K(t,i)):q(t,i,e,!1)}else n||(i.state&=-9,K(t,i));return!i.ended&&(i.length<i.highWaterMark||0===i.length)}function q(t,e,r,n){e.flowing&&0===e.length&&!e.sync&&t.listenerCount("data")>0?(65536&e.state?e.awaitDrainWriters.clear():e.awaitDrainWriters=null,e.dataEmitted=!0,t.emit("data",r)):(e.length+=e.objectMode?1:r.length,n?e.buffer.unshift(r):e.buffer.push(r),64&e.state&&Z(t)),K(t,e)}o($.prototype,{objectMode:z(N),ended:z(2),endEmitted:z(4),reading:z(8),constructed:z(F),sync:z(B),needReadable:z(64),emittedReadable:z(128),readableListening:z(256),resumeScheduled:z(512),errorEmitted:z(1024),emitClose:z(W),autoDestroy:z(U),destroyed:z(8192),closed:z(16384),closeEmitted:z(32768),multiAwaitDrain:z(65536),readingMore:z(1<<17),dataEmitted:z(1<<18)}),H.prototype.destroy=w.destroy,H.prototype._undestroy=w.undestroy,H.prototype._destroy=function(t,e){e(t)},H.prototype[d.captureRejectionSymbol]=function(t){this.destroy(t)},H.prototype[c]=function(){let t;return this.destroyed||(t=this.readableEnded?null:new L,this.destroy(t)),new l((e,r)=>m(this,n=>n&&n!==t?r(n):e(null)))},H.prototype.push=function(t,e){return G(this,t,e,!1)},H.prototype.unshift=function(t,e){return G(this,t,e,!0)},H.prototype.isPaused=function(){const t=this._readableState;return!0===t[M]||!1===t.flowing},H.prototype.setEncoding=function(t){const e=new I(t);this._readableState.decoder=e,this._readableState.encoding=this._readableState.decoder.encoding;const r=this._readableState.buffer;let n="";for(const t of r)n+=e.write(t);return r.clear(),""!==n&&r.push(n),this._readableState.length=n.length,this};function V(t,e){return t<=0||0===e.length&&e.ended?0:0!==(e.state&N)?1:n(t)?e.flowing&&e.length?e.buffer.first().length:e.length:t<=e.length?t:e.ended?e.length:0}function Z(e){const r=e._readableState;_("emitReadable",r.needReadable,r.emittedReadable),r.needReadable=!1,r.emittedReadable||(_("emitReadable",r.flowing),r.emittedReadable=!0,t.nextTick(Y,e))}function Y(t){const e=t._readableState;_("emitReadable_",e.destroyed,e.length,e.ended),e.destroyed||e.errored||!e.length&&!e.ended||(t.emit("readable"),e.emittedReadable=!1),e.needReadable=!e.flowing&&!e.ended&&e.length<=e.highWaterMark,et(t)}function K(e,r){!r.readingMore&&r.constructed&&(r.readingMore=!0,t.nextTick(Q,e,r))}function Q(t,e){for(;!e.reading&&!e.ended&&(e.length<e.highWaterMark||e.flowing&&0===e.length);){const r=e.length;if(_("maybeReadMore read 0"),t.read(0),r===e.length)break}e.readingMore=!1}function J(t){const e=t._readableState;e.readableListening=t.listenerCount("readable")>0,e.resumeScheduled&&!1===e[M]?e.flowing=!0:t.listenerCount("data")>0?t.resume():e.readableListening||(e.flowing=null)}function X(t){_("readable nexttick read 0"),t.read(0)}function tt(t,e){_("resume",e.reading),e.reading||t.read(0),e.resumeScheduled=!1,t.emit("resume"),et(t),e.flowing&&!e.reading&&t.read(0)}function et(t){const e=t._readableState;for(_("flow",e.flowing);e.flowing&&null!==t.read(););}function rt(t,e){"function"!=typeof t.read&&(t=H.wrap(t,{objectMode:!0}));const r=async function*(t,e){let r,n=D;function i(e){this===t?(n(),n=D):n=e}t.on("readable",i);const o=m(t,{writable:!1},t=>{r=t?R(r,t):null,n(),n=D});try{for(;;){const e=t.destroyed?null:t.read();if(null!==e)yield e;else{if(r)throw r;if(null===r)return;await new l(i)}}}catch(t){throw r=R(r,t),r}finally{!r&&!1===(null==e?void 0:e.destroyOnReturn)||void 0!==r&&!t._readableState.autoDestroy?(t.off("readable",i),o()):w.destroyer(t,null)}}(t,e);return r.stream=t,r}function nt(t,e){if(0===e.length)return null;let r;return e.objectMode?r=e.buffer.shift():!t||t>=e.length?(r=e.decoder?e.buffer.join(""):1===e.buffer.length?e.buffer.first():e.buffer.concat(e.length),e.buffer.clear()):r=e.buffer.consume(t,e.decoder),r}function it(e){const r=e._readableState;_("endReadable",r.endEmitted),r.endEmitted||(r.ended=!0,t.nextTick(ot,r,e))}function ot(e,r){if(_("endReadableNT",e.endEmitted,e.length),!e.errored&&!e.closeEmitted&&!e.endEmitted&&0===e.length)if(e.endEmitted=!0,r.emit("end"),r.writable&&!1===r.allowHalfOpen)t.nextTick(st,r);else if(e.autoDestroy){const t=r._writableState;(!t||t.autoDestroy&&(t.finished||!1===t.writable))&&r.destroy()}}function st(t){t.writable&&!t.writableEnded&&!t.destroyed&&t.end()}let at;function lt(){return void 0===at&&(at={}),at}return H.prototype.read=function(t){_("read",t),void 0===t?t=NaN:r(t)||(t=i(t,10));const e=this._readableState,n=t;if(t>e.highWaterMark&&(e.highWaterMark=function(t){if(t>1073741824)throw new x("size","<= 1GiB",t);return t--,t|=t>>>1,t|=t>>>2,t|=t>>>4,t|=t>>>8,t|=t>>>16,++t}(t)),0!==t&&(e.state&=-129),0===t&&e.needReadable&&((0!==e.highWaterMark?e.length>=e.highWaterMark:e.length>0)||e.ended))return _("read: emitReadable",e.length,e.ended),0===e.length&&e.ended?it(this):Z(this),null;if(0===(t=V(t,e))&&e.ended)return 0===e.length&&it(this),null;let o,s=!!(64&e.state);if(_("need readable",s),(0===e.length||e.length-t<e.highWaterMark)&&(s=!0,_("length less than watermark",s)),e.ended||e.reading||e.destroyed||e.errored||!e.constructed)s=!1,_("reading, ended or constructing",s);else if(s){_("do read"),e.state|=8|B,0===e.length&&(e.state|=64);try{this._read(e.highWaterMark)}catch(t){C(this,t)}e.state&=~B,e.reading||(t=V(n,e))}return o=t>0?nt(t,e):null,null===o?(e.needReadable=e.length<=e.highWaterMark,t=0):(e.length-=t,e.multiAwaitDrain?e.awaitDrainWriters.clear():e.awaitDrainWriters=null),0===e.length&&(e.ended||(e.needReadable=!0),n!==t&&e.ended&&it(this)),null===o||e.errorEmitted||e.closeEmitted||(e.dataEmitted=!0,this.emit("data",o)),o},H.prototype._read=function(t){throw new T("_read()")},H.prototype.pipe=function(e,r){const n=this,i=this._readableState;1===i.pipes.length&&(i.multiAwaitDrain||(i.multiAwaitDrain=!0,i.awaitDrainWriters=new u(i.awaitDrainWriters?[i.awaitDrainWriters]:[]))),i.pipes.push(e),_("pipe count=%d opts=%j",i.pipes.length,r);const o=(!r||!1!==r.end)&&e!==t.stdout&&e!==t.stderr?a:b;function s(t,r){_("onunpipe"),t===n&&r&&!1===r.hasUnpiped&&(r.hasUnpiped=!0,function(){_("cleanup"),e.removeListener("close",p),e.removeListener("finish",g),l&&e.removeListener("drain",l);e.removeListener("error",d),e.removeListener("unpipe",s),n.removeListener("end",a),n.removeListener("end",b),n.removeListener("data",f),c=!0,l&&i.awaitDrainWriters&&(!e._writableState||e._writableState.needDrain)&&l()}())}function a(){_("onend"),e.end()}let l;i.endEmitted?t.nextTick(o):n.once("end",o),e.on("unpipe",s);let c=!1;function h(){c||(1===i.pipes.length&&i.pipes[0]===e?(_("false write response, pause",0),i.awaitDrainWriters=e,i.multiAwaitDrain=!1):i.pipes.length>1&&i.pipes.includes(e)&&(_("false write response, pause",i.awaitDrainWriters.size),i.awaitDrainWriters.add(e)),n.pause()),l||(l=function(t,e){return function(){const r=t._readableState;r.awaitDrainWriters===e?(_("pipeOnDrain",1),r.awaitDrainWriters=null):r.multiAwaitDrain&&(_("pipeOnDrain",r.awaitDrainWriters.size),r.awaitDrainWriters.delete(e)),r.awaitDrainWriters&&0!==r.awaitDrainWriters.size||!t.listenerCount("data")||t.resume()}}(n,e),e.on("drain",l))}function f(t){_("ondata");const r=e.write(t);_("dest.write",r),!1===r&&h()}function d(t){if(_("onerror",t),b(),e.removeListener("error",d),0===e.listenerCount("error")){const r=e._writableState||e._readableState;r&&!r.errorEmitted?C(e,t):e.emit("error",t)}}function p(){e.removeListener("finish",g),b()}function g(){_("onfinish"),e.removeListener("close",p),b()}function b(){_("unpipe"),n.unpipe(e)}return n.on("data",f),y(e,"error",d),e.once("close",p),e.once("finish",g),e.emit("pipe",n),!0===e.writableNeedDrain?h():i.flowing||(_("pipe resume"),n.resume()),e},H.prototype.unpipe=function(t){const r=this._readableState;if(0===r.pipes.length)return this;if(!t){const t=r.pipes;r.pipes=[],this.pause();for(let e=0;e<t.length;e++)t[e].emit("unpipe",this,{hasUnpiped:!1});return this}const n=e(r.pipes,t);return-1===n||(r.pipes.splice(n,1),0===r.pipes.length&&this.pause(),t.emit("unpipe",this,{hasUnpiped:!1})),this},H.prototype.on=function(e,r){const n=p.prototype.on.call(this,e,r),i=this._readableState;return"data"===e?(i.readableListening=this.listenerCount("readable")>0,!1!==i.flowing&&this.resume()):"readable"===e&&(i.endEmitted||i.readableListening||(i.readableListening=i.needReadable=!0,i.flowing=!1,i.emittedReadable=!1,_("on readable",i.length,i.reading),i.length?Z(this):i.reading||t.nextTick(X,this))),n},H.prototype.addListener=H.prototype.on,H.prototype.removeListener=function(e,r){const n=p.prototype.removeListener.call(this,e,r);return"readable"===e&&t.nextTick(J,this),n},H.prototype.off=H.prototype.removeListener,H.prototype.removeAllListeners=function(e){const r=p.prototype.removeAllListeners.apply(this,arguments);return"readable"!==e&&void 0!==e||t.nextTick(J,this),r},H.prototype.resume=function(){const e=this._readableState;return e.flowing||(_("resume"),e.flowing=!e.readableListening,function(e,r){r.resumeScheduled||(r.resumeScheduled=!0,t.nextTick(tt,e,r))}(this,e)),e[M]=!1,this},H.prototype.pause=function(){return _("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(_("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState[M]=!0,this},H.prototype.wrap=function(t){let e=!1;t.on("data",r=>{!this.push(r)&&t.pause&&(e=!0,t.pause())}),t.on("end",()=>{this.push(null)}),t.on("error",t=>{C(this,t)}),t.on("close",()=>{this.destroy()}),t.on("destroy",()=>{this.destroy()}),this._read=()=>{e&&t.resume&&(e=!1,t.resume())};const r=s(t);for(let e=1;e<r.length;e++){const n=r[e];void 0===this[n]&&"function"==typeof t[n]&&(this[n]=t[n].bind(t))}return this},H.prototype[h]=function(){return rt(this)},H.prototype.iterator=function(t){return void 0!==t&&j(t,"options"),rt(this,t)},o(H.prototype,{readable:{__proto__:null,get(){const t=this._readableState;return!(!t||!1===t.readable||t.destroyed||t.errorEmitted||t.endEmitted)},set(t){this._readableState&&(this._readableState.readable=!!t)}},readableDidRead:{__proto__:null,enumerable:!1,get:function(){return this._readableState.dataEmitted}},readableAborted:{__proto__:null,enumerable:!1,get:function(){return!(!1===this._readableState.readable||!this._readableState.destroyed&&!this._readableState.errored||this._readableState.endEmitted)}},readableHighWaterMark:{__proto__:null,enumerable:!1,get:function(){return this._readableState.highWaterMark}},readableBuffer:{__proto__:null,enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}},readableFlowing:{__proto__:null,enumerable:!1,get:function(){return this._readableState.flowing},set:function(t){this._readableState&&(this._readableState.flowing=t)}},readableLength:{__proto__:null,enumerable:!1,get(){return this._readableState.length}},readableObjectMode:{__proto__:null,enumerable:!1,get(){return!!this._readableState&&this._readableState.objectMode}},readableEncoding:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.encoding:null}},errored:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.errored:null}},closed:{__proto__:null,get(){return!!this._readableState&&this._readableState.closed}},destroyed:{__proto__:null,enumerable:!1,get(){return!!this._readableState&&this._readableState.destroyed},set(t){this._readableState&&(this._readableState.destroyed=t)}},readableEnded:{__proto__:null,enumerable:!1,get(){return!!this._readableState&&this._readableState.endEmitted}}}),o($.prototype,{pipesCount:{__proto__:null,get(){return this.pipes.length}},paused:{__proto__:null,get(){return!1!==this[M]},set(t){this[M]=!!t}}}),H._fromList=nt,H.from=function(t,e){return P(H,t,e)},H.fromWeb=function(t,e){return lt().newStreamReadableFromReadableStream(t,e)},H.toWeb=function(t,e){return lt().newReadableStreamFromStreamReadable(t,e)},H.wrap=function(t,e){var r,n;return new H({objectMode:null===(r=null!==(n=t.readableObjectMode)&&void 0!==n?n:t.objectMode)||void 0===r||r,...e,destroy(e,r){w.destroyer(t,e),r(e)}}).wrap(t)},ZR}function ik(){if(QR)return KR;QR=1;const t=of,{ArrayPrototypeSlice:e,Error:r,FunctionPrototypeSymbolHasInstance:n,ObjectDefineProperty:i,ObjectDefineProperties:o,ObjectSetPrototypeOf:s,StringPrototypeToLowerCase:a,Symbol:l,SymbolHasInstance:u}=Tw;KR=j,j.WritableState=O;const{EventEmitter:c}=yn,h=hR.Stream,{Buffer:f}=ca,d=oR,{addAbortSignal:p}=dR,{getHighWaterMark:y,getDefaultHighWaterMark:g}=AR,{ERR_INVALID_ARG_TYPE:b,ERR_METHOD_NOT_IMPLEMENTED:m,ERR_MULTIPLE_CALLBACK:_,ERR_STREAM_CANNOT_PIPE:v,ERR_STREAM_DESTROYED:w,ERR_STREAM_ALREADY_FINISHED:S,ERR_STREAM_NULL_VALUES:E,ERR_STREAM_WRITE_AFTER_END:R,ERR_UNKNOWN_ENCODING:k}=zw.codes,{errorOrDestroy:T}=d;function x(){}s(j.prototype,h.prototype),s(j,h);const A=l("kOnFinished");function O(t,e,r){"boolean"!=typeof r&&(r=e instanceof sk()),this.objectMode=!(!t||!t.objectMode),r&&(this.objectMode=this.objectMode||!(!t||!t.writableObjectMode)),this.highWaterMark=t?y(this,t,"writableHighWaterMark",r):g(!1),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;const n=!(!t||!1!==t.decodeStrings);this.decodeStrings=!n,this.defaultEncoding=t&&t.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=D.bind(void 0,e),this.writecb=null,this.writelen=0,this.afterWriteTickInfo=null,L(this),this.pendingcb=0,this.constructed=!0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=!t||!1!==t.emitClose,this.autoDestroy=!t||!1!==t.autoDestroy,this.errored=null,this.closed=!1,this.closeEmitted=!1,this[A]=[]}function L(t){t.buffered=[],t.bufferedIndex=0,t.allBuffers=!0,t.allNoop=!0}function j(t){const e=this instanceof sk();if(!e&&!n(j,this))return new j(t);this._writableState=new O(t,this,e),t&&("function"==typeof t.write&&(this._write=t.write),"function"==typeof t.writev&&(this._writev=t.writev),"function"==typeof t.destroy&&(this._destroy=t.destroy),"function"==typeof t.final&&(this._final=t.final),"function"==typeof t.construct&&(this._construct=t.construct),t.signal&&p(t.signal,this)),h.call(this,t),d.construct(this,()=>{const t=this._writableState;t.writing||B(this,t),z(this,t)})}function M(e,r,n,i){const o=e._writableState;if("function"==typeof n)i=n,n=o.defaultEncoding;else{if(n){if("buffer"!==n&&!f.isEncoding(n))throw new k(n)}else n=o.defaultEncoding;"function"!=typeof i&&(i=x)}if(null===r)throw new E;if(!o.objectMode)if("string"==typeof r)!1!==o.decodeStrings&&(r=f.from(r,n),n="buffer");else if(r instanceof f)n="buffer";else{if(!h._isUint8Array(r))throw new b("chunk",["string","Buffer","Uint8Array"],r);r=h._uint8ArrayToBuffer(r),n="buffer"}let s;return o.ending?s=new R:o.destroyed&&(s=new w("write")),s?(t.nextTick(i,s),T(e,s,!0),s):(o.pendingcb++,function(t,e,r,n,i){const o=e.objectMode?1:r.length;e.length+=o;const s=e.length<e.highWaterMark;s||(e.needDrain=!0);e.writing||e.corked||e.errored||!e.constructed?(e.buffered.push({chunk:r,encoding:n,callback:i}),e.allBuffers&&"buffer"!==n&&(e.allBuffers=!1),e.allNoop&&i!==x&&(e.allNoop=!1)):(e.writelen=o,e.writecb=i,e.writing=!0,e.sync=!0,t._write(r,n,e.onwrite),e.sync=!1);return s&&!e.errored&&!e.destroyed}(e,o,r,n,i))}function I(t,e,r,n,i,o,s){e.writelen=n,e.writecb=s,e.writing=!0,e.sync=!0,e.destroyed?e.onwrite(new w("write")):r?t._writev(i,e.onwrite):t._write(i,o,e.onwrite),e.sync=!1}function P(t,e,r,n){--e.pendingcb,n(r),F(e),T(t,r)}function D(e,r){const n=e._writableState,i=n.sync,o=n.writecb;"function"==typeof o?(n.writing=!1,n.writecb=null,n.length-=n.writelen,n.writelen=0,r?(r.stack,n.errored||(n.errored=r),e._readableState&&!e._readableState.errored&&(e._readableState.errored=r),i?t.nextTick(P,e,n,r,o):P(e,n,r,o)):(n.buffered.length>n.bufferedIndex&&B(e,n),i?null!==n.afterWriteTickInfo&&n.afterWriteTickInfo.cb===o?n.afterWriteTickInfo.count++:(n.afterWriteTickInfo={count:1,cb:o,stream:e,state:n},t.nextTick(C,n.afterWriteTickInfo)):N(e,n,1,o))):T(e,new _)}function C({stream:t,state:e,count:r,cb:n}){return e.afterWriteTickInfo=null,N(t,e,r,n)}function N(t,e,r,n){for(!e.ending&&!t.destroyed&&0===e.length&&e.needDrain&&(e.needDrain=!1,t.emit("drain"));r-- >0;)e.pendingcb--,n();e.destroyed&&F(e),z(t,e)}function F(t){if(t.writing)return;for(let r=t.bufferedIndex;r<t.buffered.length;++r){var e;const{chunk:n,callback:i}=t.buffered[r],o=t.objectMode?1:n.length;t.length-=o,i(null!==(e=t.errored)&&void 0!==e?e:new w("write"))}const r=t[A].splice(0);for(let e=0;e<r.length;e++){var n;r[e](null!==(n=t.errored)&&void 0!==n?n:new w("end"))}L(t)}function B(t,r){if(r.corked||r.bufferProcessing||r.destroyed||!r.constructed)return;const{buffered:n,bufferedIndex:i,objectMode:o}=r,s=n.length-i;if(!s)return;let a=i;if(r.bufferProcessing=!0,s>1&&t._writev){r.pendingcb-=s-1;const i=r.allNoop?x:t=>{for(let e=a;e<n.length;++e)n[e].callback(t)},o=r.allNoop&&0===a?n:e(n,a);o.allBuffers=r.allBuffers,I(t,r,!0,r.length,o,"",i),L(r)}else{do{const{chunk:e,encoding:i,callback:s}=n[a];n[a++]=null;I(t,r,!1,o?1:e.length,e,i,s)}while(a<n.length&&!r.writing);a===n.length?L(r):a>256?(n.splice(0,a),r.bufferedIndex=0):r.bufferedIndex=a}r.bufferProcessing=!1}function W(t){return t.ending&&!t.destroyed&&t.constructed&&0===t.length&&!t.errored&&0===t.buffered.length&&!t.finished&&!t.writing&&!t.errorEmitted&&!t.closeEmitted}function U(e,r){r.prefinished||r.finalCalled||("function"!=typeof e._final||r.destroyed?(r.prefinished=!0,e.emit("prefinish")):(r.finalCalled=!0,function(e,r){let n=!1;function i(i){if(n)T(e,null!=i?i:_());else if(n=!0,r.pendingcb--,i){const t=r[A].splice(0);for(let e=0;e<t.length;e++)t[e](i);T(e,i,r.sync)}else W(r)&&(r.prefinished=!0,e.emit("prefinish"),r.pendingcb++,t.nextTick($,e,r))}r.sync=!0,r.pendingcb++;try{e._final(i)}catch(t){i(t)}r.sync=!1}(e,r)))}function z(e,r,n){W(r)&&(U(e,r),0===r.pendingcb&&(n?(r.pendingcb++,t.nextTick((t,e)=>{W(e)?$(t,e):e.pendingcb--},e,r)):W(r)&&(r.pendingcb++,$(e,r))))}function $(t,e){e.pendingcb--,e.finished=!0;const r=e[A].splice(0);for(let t=0;t<r.length;t++)r[t]();if(t.emit("finish"),e.autoDestroy){const e=t._readableState;(!e||e.autoDestroy&&(e.endEmitted||!1===e.readable))&&t.destroy()}}O.prototype.getBuffer=function(){return e(this.buffered,this.bufferedIndex)},i(O.prototype,"bufferedRequestCount",{__proto__:null,get(){return this.buffered.length-this.bufferedIndex}}),i(j,u,{__proto__:null,value:function(t){return!!n(this,t)||this===j&&(t&&t._writableState instanceof O)}}),j.prototype.pipe=function(){T(this,new v)},j.prototype.write=function(t,e,r){return!0===M(this,t,e,r)},j.prototype.cork=function(){this._writableState.corked++},j.prototype.uncork=function(){const t=this._writableState;t.corked&&(t.corked--,t.writing||B(this,t))},j.prototype.setDefaultEncoding=function(t){if("string"==typeof t&&(t=a(t)),!f.isEncoding(t))throw new k(t);return this._writableState.defaultEncoding=t,this},j.prototype._write=function(t,e,r){if(!this._writev)throw new m("_write()");this._writev([{chunk:t,encoding:e}],r)},j.prototype._writev=null,j.prototype.end=function(e,n,i){const o=this._writableState;let s;if("function"==typeof e?(i=e,e=null,n=null):"function"==typeof n&&(i=n,n=null),null!=e){const t=M(this,e,n);t instanceof r&&(s=t)}return o.corked&&(o.corked=1,this.uncork()),s||(o.errored||o.ending?o.finished?s=new S("end"):o.destroyed&&(s=new w("end")):(o.ending=!0,z(this,o,!0),o.ended=!0)),"function"==typeof i&&(s||o.finished?t.nextTick(i,s):o[A].push(i)),this},o(j.prototype,{closed:{__proto__:null,get(){return!!this._writableState&&this._writableState.closed}},destroyed:{__proto__:null,get(){return!!this._writableState&&this._writableState.destroyed},set(t){this._writableState&&(this._writableState.destroyed=t)}},writable:{__proto__:null,get(){const t=this._writableState;return!(!t||!1===t.writable||t.destroyed||t.errored||t.ending||t.ended)},set(t){this._writableState&&(this._writableState.writable=!!t)}},writableFinished:{__proto__:null,get(){return!!this._writableState&&this._writableState.finished}},writableObjectMode:{__proto__:null,get(){return!!this._writableState&&this._writableState.objectMode}},writableBuffer:{__proto__:null,get(){return this._writableState&&this._writableState.getBuffer()}},writableEnded:{__proto__:null,get(){return!!this._writableState&&this._writableState.ending}},writableNeedDrain:{__proto__:null,get(){const t=this._writableState;return!!t&&(!t.destroyed&&!t.ending&&t.needDrain)}},writableHighWaterMark:{__proto__:null,get(){return this._writableState&&this._writableState.highWaterMark}},writableCorked:{__proto__:null,get(){return this._writableState?this._writableState.corked:0}},writableLength:{__proto__:null,get(){return this._writableState&&this._writableState.length}},errored:{__proto__:null,enumerable:!1,get(){return this._writableState?this._writableState.errored:null}},writableAborted:{__proto__:null,enumerable:!1,get:function(){return!(!1===this._writableState.writable||!this._writableState.destroyed&&!this._writableState.errored||this._writableState.finished)}}});const H=d.destroy;let G;function q(){return void 0===G&&(G={}),G}return j.prototype.destroy=function(e,r){const n=this._writableState;return!n.destroyed&&(n.bufferedIndex<n.buffered.length||n[A].length)&&t.nextTick(F,n),H.call(this,e,r),this},j.prototype._undestroy=d.undestroy,j.prototype._destroy=function(t,e){e(t)},j.prototype[c.captureRejectionSymbol]=function(t){this.destroy(t)},j.fromWeb=function(t,e){return q().newStreamWritableFromWritableStream(t,e)},j.toWeb=function(t){return q().newWritableStreamFromStreamWritable(t)},KR}function ok(){if(XR)return JR;XR=1;const t=of,e=ca,{isReadable:r,isWritable:n,isIterable:i,isNodeStream:o,isReadableNodeStream:s,isWritableNodeStream:a,isDuplexNodeStream:l,isReadableStream:u,isWritableStream:c}=iE,h=CE,{AbortError:f,codes:{ERR_INVALID_ARG_TYPE:d,ERR_INVALID_RETURN_VALUE:p}}=zw,{destroyer:y}=oR,g=sk(),b=nk(),m=ik(),{createDeferredPromise:_}=$w,v=rk,w=globalThis.Blob||e.Blob,S=void 0!==w?function(t){return t instanceof w}:function(t){return!1},E=globalThis.AbortController||Kc().AbortController,{FunctionPrototypeCall:R}=Tw;class k extends g{constructor(t){super(t),!1===(null==t?void 0:t.readable)&&(this._readableState.readable=!1,this._readableState.ended=!0,this._readableState.endEmitted=!0),!1===(null==t?void 0:t.writable)&&(this._writableState.writable=!1,this._writableState.ending=!0,this._writableState.ended=!0,this._writableState.finished=!0)}}function T(t){const e=t.readable&&"function"!=typeof t.readable.read?b.wrap(t.readable):t.readable,i=t.writable;let o,s,a,l,u,c=!!r(e),d=!!n(i);function p(t){const e=l;l=null,e?e(t):t&&u.destroy(t)}return u=new k({readableObjectMode:!(null==e||!e.readableObjectMode),writableObjectMode:!(null==i||!i.writableObjectMode),readable:c,writable:d}),d&&(h(i,t=>{d=!1,t&&y(e,t),p(t)}),u._write=function(t,e,r){i.write(t,e)?r():o=r},u._final=function(t){i.end(),s=t},i.on("drain",function(){if(o){const t=o;o=null,t()}}),i.on("finish",function(){if(s){const t=s;s=null,t()}})),c&&(h(e,t=>{c=!1,t&&y(e,t),p(t)}),e.on("readable",function(){if(a){const t=a;a=null,t()}}),e.on("end",function(){u.push(null)}),u._read=function(){for(;;){const t=e.read();if(null===t)return void(a=u._read);if(!u.push(t))return}}),u._destroy=function(t,r){t||null===l||(t=new f),a=null,o=null,s=null,null===l?r(t):(l=r,y(i,t),y(e,t))},u}return JR=function e(r,n){if(l(r))return r;if(s(r))return T({readable:r});if(a(r))return T({writable:r});if(o(r))return T({writable:!1,readable:!1});if(u(r))return T({readable:b.fromWeb(r)});if(c(r))return T({writable:m.fromWeb(r)});if("function"==typeof r){const{value:e,write:o,final:s,destroy:a}=function(e){let{promise:r,resolve:n}=_();const i=new E,o=i.signal,s=e(async function*(){for(;;){const e=r;r=null;const{chunk:i,done:s,cb:a}=await e;if(t.nextTick(a),s)return;if(o.aborted)throw new f(void 0,{cause:o.reason});({promise:r,resolve:n}=_()),yield i}}(),{signal:o});return{value:s,write(t,e,r){const i=n;n=null,i({chunk:t,done:!1,cb:r})},final(t){const e=n;n=null,e({done:!0,cb:t})},destroy(t,e){i.abort(),e(t)}}}(r);if(i(e))return v(k,e,{objectMode:!0,write:o,final:s,destroy:a});const l=null==e?void 0:e.then;if("function"==typeof l){let r;const n=R(l,e,t=>{if(null!=t)throw new p("nully","body",t)},t=>{y(r,t)});return r=new k({objectMode:!0,readable:!1,write:o,final(e){s(async()=>{try{await n,t.nextTick(e,null)}catch(r){t.nextTick(e,r)}})},destroy:a})}throw new p("Iterable, AsyncIterable or AsyncFunction",n,e)}if(S(r))return e(r.arrayBuffer());if(i(r))return v(k,r,{objectMode:!0,writable:!1});if(u(null==r?void 0:r.readable)&&c(null==r?void 0:r.writable))return k.fromWeb(r);if("object"==typeof(null==r?void 0:r.writable)||"object"==typeof(null==r?void 0:r.readable)){return T({readable:null!=r&&r.readable?s(null==r?void 0:r.readable)?null==r?void 0:r.readable:e(r.readable):void 0,writable:null!=r&&r.writable?a(null==r?void 0:r.writable)?null==r?void 0:r.writable:e(r.writable):void 0})}const h=null==r?void 0:r.then;if("function"==typeof h){let t;return R(h,r,e=>{null!=e&&t.push(e),t.push(null)},e=>{y(t,e)}),t=new k({objectMode:!0,writable:!1,read(){}})}throw new d(n,["Blob","ReadableStream","WritableStream","Stream","Iterable","AsyncIterable","Function","{ readable, writable } pair","Promise"],r)},JR}function sk(){if(ek)return tk;ek=1;const{ObjectDefineProperties:t,ObjectGetOwnPropertyDescriptor:e,ObjectKeys:r,ObjectSetPrototypeOf:n}=Tw;tk=s;const i=nk(),o=ik();n(s.prototype,i.prototype),n(s,i);{const t=r(o.prototype);for(let e=0;e<t.length;e++){const r=t[e];s.prototype[r]||(s.prototype[r]=o.prototype[r])}}function s(t){if(!(this instanceof s))return new s(t);i.call(this,t),o.call(this,t),t?(this.allowHalfOpen=!1!==t.allowHalfOpen,!1===t.readable&&(this._readableState.readable=!1,this._readableState.ended=!0,this._readableState.endEmitted=!0),!1===t.writable&&(this._writableState.writable=!1,this._writableState.ending=!0,this._writableState.ended=!0,this._writableState.finished=!0)):this.allowHalfOpen=!0}let a,l;function u(){return void 0===a&&(a={}),a}return t(s.prototype,{writable:{__proto__:null,...e(o.prototype,"writable")},writableHighWaterMark:{__proto__:null,...e(o.prototype,"writableHighWaterMark")},writableObjectMode:{__proto__:null,...e(o.prototype,"writableObjectMode")},writableBuffer:{__proto__:null,...e(o.prototype,"writableBuffer")},writableLength:{__proto__:null,...e(o.prototype,"writableLength")},writableFinished:{__proto__:null,...e(o.prototype,"writableFinished")},writableCorked:{__proto__:null,...e(o.prototype,"writableCorked")},writableEnded:{__proto__:null,...e(o.prototype,"writableEnded")},writableNeedDrain:{__proto__:null,...e(o.prototype,"writableNeedDrain")},destroyed:{__proto__:null,get(){return void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed&&this._writableState.destroyed)},set(t){this._readableState&&this._writableState&&(this._readableState.destroyed=t,this._writableState.destroyed=t)}}}),s.fromWeb=function(t,e){return u().newStreamDuplexFromReadableWritablePair(t,e)},s.toWeb=function(t){return u().newReadableWritablePairFromDuplex(t)},s.from=function(t){return l||(l=ok()),l(t,"body")},tk}const{ObjectSetPrototypeOf:ak,Symbol:lk}=Tw;var uk=pk;const{ERR_METHOD_NOT_IMPLEMENTED:ck}=zw.codes,hk=sk(),{getHighWaterMark:fk}=AR;ak(pk.prototype,hk.prototype),ak(pk,hk);const dk=lk("kCallback");function pk(t){if(!(this instanceof pk))return new pk(t);const e=t?fk(this,t,"readableHighWaterMark",!0):null;0===e&&(t={...t,highWaterMark:null,readableHighWaterMark:e,writableHighWaterMark:t.writableHighWaterMark||0}),hk.call(this,t),this._readableState.sync=!1,this[dk]=null,t&&("function"==typeof t.transform&&(this._transform=t.transform),"function"==typeof t.flush&&(this._flush=t.flush)),this.on("prefinish",gk)}function yk(t){"function"!=typeof this._flush||this.destroyed?(this.push(null),t&&t()):this._flush((e,r)=>{e?t?t(e):this.destroy(e):(null!=r&&this.push(r),this.push(null),t&&t())})}function gk(){this._final!==yk&&yk.call(this)}pk.prototype._final=yk,pk.prototype._transform=function(t,e,r){throw new ck("_transform()")},pk.prototype._write=function(t,e,r){const n=this._readableState,i=this._writableState,o=n.length;this._transform(t,e,(t,e)=>{t?r(t):(null!=e&&this.push(e),i.ended||o===n.length||n.length<n.highWaterMark?r():this[dk]=r)})},pk.prototype._read=function(){if(this[dk]){const t=this[dk];this[dk]=null,t()}};const{ObjectSetPrototypeOf:bk}=Tw;var mk=vk;const _k=uk;function vk(t){if(!(this instanceof vk))return new vk(t);_k.call(this,t)}bk(vk.prototype,_k.prototype),bk(vk,_k),vk.prototype._transform=function(t,e,r){r(null,t)};const wk=of,{ArrayIsArray:Sk,Promise:Ek,SymbolAsyncIterator:Rk,SymbolDispose:kk}=Tw,Tk=CE,{once:xk}=$w,Ak=oR,Ok=sk(),{aggregateTwoErrors:Lk,codes:{ERR_INVALID_ARG_TYPE:jk,ERR_INVALID_RETURN_VALUE:Mk,ERR_MISSING_ARGS:Ik,ERR_STREAM_DESTROYED:Pk,ERR_STREAM_PREMATURE_CLOSE:Dk},AbortError:Ck}=zw,{validateFunction:Nk,validateAbortSignal:Fk}=IS,{isIterable:Bk,isReadable:Wk,isReadableNodeStream:Uk,isNodeStream:zk,isTransformStream:$k,isWebStream:Hk,isReadableStream:Gk,isReadableFinished:qk}=iE,Vk=globalThis.AbortController||Kc().AbortController;let Zk,Yk,Kk;function Qk(t,e,r){let n=!1;t.on("close",()=>{n=!0});return{destroy:e=>{n||(n=!0,Ak.destroyer(t,e||new Pk("pipe")))},cleanup:Tk(t,{readable:e,writable:r},t=>{n=!t})}}function Jk(t){if(Bk(t))return t;if(Uk(t))return async function*(t){Yk||(Yk=nk());yield*Yk.prototype[Rk].call(t)}(t);throw new jk("val",["Readable","Iterable","AsyncIterable"],t)}async function Xk(t,e,r,{end:n}){let i,o=null;const s=t=>{if(t&&(i=t),o){const t=o;o=null,t()}},a=()=>new Ek((t,e)=>{i?e(i):o=()=>{i?e(i):t()}});e.on("drain",s);const l=Tk(e,{readable:!1},s);try{e.writableNeedDrain&&await a();for await(const r of t)e.write(r)||await a();n&&(e.end(),await a()),r()}catch(t){r(i!==t?Lk(i,t):t)}finally{l(),e.off("drain",s)}}async function tT(t,e,r,{end:n}){$k(e)&&(e=e.writable);const i=e.getWriter();try{for await(const e of t)await i.ready,i.write(e).catch(()=>{});await i.ready,n&&await i.close(),r()}catch(t){try{await i.abort(t),r(t)}catch(t){r(t)}}}function eT(t,e,r){if(1===t.length&&Sk(t[0])&&(t=t[0]),t.length<2)throw new Ik("streams");const n=new Vk,i=n.signal,o=null==r?void 0:r.signal,s=[];function a(){y(new Ck)}let l,u,c;Fk(o,"options.signal"),Kk=Kk||$w.addAbortListener,o&&(l=Kk(o,a));const h=[];let f,d=0;function p(t){y(t,0===--d)}function y(t,r){var i;if(!t||u&&"ERR_STREAM_PREMATURE_CLOSE"!==u.code||(u=t),u||r){for(;h.length;)h.shift()(u);null===(i=l)||void 0===i||i[kk](),n.abort(),r&&(u||s.forEach(t=>t()),wk.nextTick(e,u,c))}}for(let m=0;m<t.length;m++){const _=t[m],v=m<t.length-1,w=m>0,S=v||!1!==(null==r?void 0:r.end),E=m===t.length-1;if(zk(_)){if(S){const{destroy:k,cleanup:T}=Qk(_,v,w);h.push(k),Wk(_)&&E&&s.push(T)}function R(t){t&&"AbortError"!==t.name&&"ERR_STREAM_PREMATURE_CLOSE"!==t.code&&p(t)}_.on("error",R),Wk(_)&&E&&s.push(()=>{_.removeListener("error",R)})}if(0===m)if("function"==typeof _){if(f=_({signal:i}),!Bk(f))throw new Mk("Iterable, AsyncIterable or Stream","source",f)}else f=Bk(_)||Uk(_)||$k(_)?_:Ok.from(_);else if("function"==typeof _){var g;if($k(f))f=Jk(null===(g=f)||void 0===g?void 0:g.readable);else f=Jk(f);if(f=_(f,{signal:i}),v){if(!Bk(f,!0))throw new Mk("AsyncIterable",`transform[${m-1}]`,f)}else{var b;Zk||(Zk=mk);const x=new Zk({objectMode:!0}),A=null===(b=f)||void 0===b?void 0:b.then;if("function"==typeof A)d++,A.call(f,t=>{c=t,null!=t&&x.write(t),S&&x.end(),wk.nextTick(p)},t=>{x.destroy(t),wk.nextTick(p,t)});else if(Bk(f,!0))d++,Xk(f,x,p,{end:S});else{if(!Gk(f)&&!$k(f))throw new Mk("AsyncIterable or Promise","destination",f);{const j=f.readable||f;d++,Xk(j,x,p,{end:S})}}f=x;const{destroy:O,cleanup:L}=Qk(f,!1,!0);h.push(O),E&&s.push(L)}}else if(zk(_)){if(Uk(f)){d+=2;const M=rT(f,_,p,{end:S});Wk(_)&&E&&s.push(M)}else if($k(f)||Gk(f)){const I=f.readable||f;d++,Xk(I,_,p,{end:S})}else{if(!Bk(f))throw new jk("val",["Readable","Iterable","AsyncIterable","ReadableStream","TransformStream"],f);d++,Xk(f,_,p,{end:S})}f=_}else if(Hk(_)){if(Uk(f))d++,tT(Jk(f),_,p,{end:S});else if(Gk(f)||Bk(f))d++,tT(f,_,p,{end:S});else{if(!$k(f))throw new jk("val",["Readable","Iterable","AsyncIterable","ReadableStream","TransformStream"],f);d++,tT(f.readable,_,p,{end:S})}f=_}else f=Ok.from(_)}return(null!=i&&i.aborted||null!=o&&o.aborted)&&wk.nextTick(a),f}function rT(t,e,r,{end:n}){let i=!1;if(e.on("close",()=>{i||r(new Dk)}),t.pipe(e,{end:!1}),n){function o(){i=!0,e.end()}qk(t)?wk.nextTick(o):t.once("end",o)}else r();return Tk(t,{readable:!0,writable:!1},e=>{const n=t._readableState;e&&"ERR_STREAM_PREMATURE_CLOSE"===e.code&&n&&n.ended&&!n.errored&&!n.errorEmitted?t.once("end",r).once("error",r):r(e)}),Tk(e,{readable:!1,writable:!0},r)}var nT={pipelineImpl:eT,pipeline:function(...t){return eT(t,xk(function(t){return Nk(t[t.length-1],"streams[stream.length - 1]"),t.pop()}(t)))}};const{pipeline:iT}=nT,oT=sk(),{destroyer:sT}=oR,{isNodeStream:aT,isReadable:lT,isWritable:uT,isWebStream:cT,isTransformStream:hT,isWritableStream:fT,isReadableStream:dT}=iE,{AbortError:pT,codes:{ERR_INVALID_ARG_VALUE:yT,ERR_MISSING_ARGS:gT}}=zw,bT=CE;var mT=function(...t){if(0===t.length)throw new gT("streams");if(1===t.length)return oT.from(t[0]);const e=[...t];if("function"==typeof t[0]&&(t[0]=oT.from(t[0])),"function"==typeof t[t.length-1]){const e=t.length-1;t[e]=oT.from(t[e])}for(let r=0;r<t.length;++r)if(aT(t[r])||cT(t[r])){if(r<t.length-1&&!(lT(t[r])||dT(t[r])||hT(t[r])))throw new yT(`streams[${r}]`,e[r],"must be readable");if(r>0&&!(uT(t[r])||fT(t[r])||hT(t[r])))throw new yT(`streams[${r}]`,e[r],"must be writable")}let r,n,i,o,s;const a=t[0],l=iT(t,function(t){const e=o;o=null,e?e(t):t?s.destroy(t):c||u||s.destroy()}),u=!!(uT(a)||fT(a)||hT(a)),c=!!(lT(l)||dT(l)||hT(l));if(s=new oT({writableObjectMode:!(null==a||!a.writableObjectMode),readableObjectMode:!(null==l||!l.readableObjectMode),writable:u,readable:c}),u){if(aT(a))s._write=function(t,e,n){a.write(t,e)?n():r=n},s._final=function(t){a.end(),n=t},a.on("drain",function(){if(r){const t=r;r=null,t()}});else if(cT(a)){const t=(hT(a)?a.writable:a).getWriter();s._write=async function(e,r,n){try{await t.ready,t.write(e).catch(()=>{}),n()}catch(t){n(t)}},s._final=async function(e){try{await t.ready,t.close().catch(()=>{}),n=e}catch(t){e(t)}}}const t=hT(l)?l.readable:l;bT(t,()=>{if(n){const t=n;n=null,t()}})}if(c)if(aT(l))l.on("readable",function(){if(i){const t=i;i=null,t()}}),l.on("end",function(){s.push(null)}),s._read=function(){for(;;){const t=l.read();if(null===t)return void(i=s._read);if(!s.push(t))return}};else if(cT(l)){const t=(hT(l)?l.readable:l).getReader();s._read=async function(){for(;;)try{const{value:e,done:r}=await t.read();if(!s.push(e))return;if(r)return void s.push(null)}catch{return}}}return s._destroy=function(t,e){t||null===o||(t=new pT),i=null,r=null,n=null,null===o?e(t):(o=e,aT(l)&&sT(l,t))},s};const _T=globalThis.AbortController||Kc().AbortController,{codes:{ERR_INVALID_ARG_VALUE:vT,ERR_INVALID_ARG_TYPE:wT,ERR_MISSING_ARGS:ST,ERR_OUT_OF_RANGE:ET},AbortError:RT}=zw,{validateAbortSignal:kT,validateInteger:TT,validateObject:xT}=IS,AT=Tw.Symbol("kWeak"),OT=Tw.Symbol("kResistStopPropagation"),{finished:LT}=CE,jT=mT,{addAbortSignalNoValidate:MT}=dR,{isWritable:IT,isNodeStream:PT}=iE,{deprecate:DT}=$w,{ArrayPrototypePush:CT,Boolean:NT,MathFloor:FT,Number:BT,NumberIsNaN:WT,Promise:UT,PromiseReject:zT,PromiseResolve:$T,PromisePrototypeThen:HT,Symbol:GT}=Tw,qT=GT("kEmpty"),VT=GT("kEof");function ZT(t,e){if("function"!=typeof t)throw new wT("fn",["Function","AsyncFunction"],t);null!=e&&xT(e,"options"),null!=(null==e?void 0:e.signal)&&kT(e.signal,"options.signal");let r=1;null!=(null==e?void 0:e.concurrency)&&(r=FT(e.concurrency));let n=r-1;return null!=(null==e?void 0:e.highWaterMark)&&(n=FT(e.highWaterMark)),TT(r,"options.concurrency",1),TT(n,"options.highWaterMark",0),n+=r,async function*(){const i=$w.AbortSignalAny([null==e?void 0:e.signal].filter(NT)),o=this,s=[],a={signal:i};let l,u,c=!1,h=0;function f(){c=!0,d()}function d(){h-=1,p()}function p(){u&&!c&&h<r&&s.length<n&&(u(),u=null)}!async function(){try{for await(let e of o){if(c)return;if(i.aborted)throw new RT;try{if(e=t(e,a),e===qT)continue;e=$T(e)}catch(t){e=zT(t)}h+=1,HT(e,d,f),s.push(e),l&&(l(),l=null),!c&&(s.length>=n||h>=r)&&await new UT(t=>{u=t})}s.push(VT)}catch(t){const e=zT(t);HT(e,d,f),s.push(e)}finally{c=!0,l&&(l(),l=null)}}();try{for(;;){for(;s.length>0;){const t=await s[0];if(t===VT)return;if(i.aborted)throw new RT;t!==qT&&(yield t),s.shift(),p()}await new UT(t=>{l=t})}}finally{c=!0,u&&(u(),u=null)}}.call(this)}async function YT(t,e=void 0){for await(const r of KT.call(this,t,e))return!0;return!1}function KT(t,e){if("function"!=typeof t)throw new wT("fn",["Function","AsyncFunction"],t);return ZT.call(this,async function(e,r){return await t(e,r)?e:qT},e)}let QT=class extends ST{constructor(){super("reduce"),this.message="Reduce of an empty stream requires an initial value"}};function JT(t){if(t=BT(t),WT(t))return 0;if(t<0)throw new ET("number",">= 0",t);return t}var XT,tx,ex;function rx(){if(tx)return XT;tx=1;const{ArrayPrototypePop:t,Promise:e}=Tw,{isIterable:r,isNodeStream:n,isWebStream:i}=iE,{pipelineImpl:o}=nT,{finished:s}=CE;return nx(),XT={finished:s,pipeline:function(...s){return new e((e,a)=>{let l,u;const c=s[s.length-1];if(c&&"object"==typeof c&&!n(c)&&!r(c)&&!i(c)){const e=t(s);l=e.signal,u=e.end}o(s,(t,r)=>{t?a(t):e(r)},{signal:l,end:u})})}},XT}function nx(){if(ex)return Rw.exports;ex=1;const{Buffer:t}=ca,{ObjectDefineProperty:e,ObjectKeys:r,ReflectApply:n}=Tw,{promisify:{custom:i}}=$w,{streamReturningOperators:o,promiseReturningOperators:s}=Hw,{codes:{ERR_ILLEGAL_CONSTRUCTOR:a}}=zw,l=mT,{setDefaultHighWaterMark:u,getDefaultHighWaterMark:c}=AR,{pipeline:h}=nT,{destroyer:f}=oR,d=CE,p=rx(),y=iE,g=Rw.exports=hR.Stream;g.isDestroyed=y.isDestroyed,g.isDisturbed=y.isDisturbed,g.isErrored=y.isErrored,g.isReadable=y.isReadable,g.isWritable=y.isWritable,g.Readable=nk();for(const m of r(o)){const _=o[m];function v(...t){if(new.target)throw a();return g.Readable.from(n(_,this,t))}e(v,"name",{__proto__:null,value:_.name}),e(v,"length",{__proto__:null,value:_.length}),e(g.Readable.prototype,m,{__proto__:null,value:v,enumerable:!1,configurable:!0,writable:!0})}for(const w of r(s)){const S=s[w];function E(...t){if(new.target)throw a();return n(S,this,t)}e(E,"name",{__proto__:null,value:S.name}),e(E,"length",{__proto__:null,value:S.length}),e(g.Readable.prototype,w,{__proto__:null,value:E,enumerable:!1,configurable:!0,writable:!0})}g.Writable=ik(),g.Duplex=sk(),g.Transform=uk,g.PassThrough=mk,g.pipeline=h;const{addAbortSignal:b}=dR;return g.addAbortSignal=b,g.finished=d,g.destroy=f,g.compose=l,g.setDefaultHighWaterMark=u,g.getDefaultHighWaterMark=c,e(g,"promises",{__proto__:null,configurable:!0,enumerable:!0,get:()=>p}),e(h,i,{__proto__:null,enumerable:!0,get:()=>p.pipeline}),e(d,i,{__proto__:null,enumerable:!0,get:()=>p.finished}),g.Stream=g,g._isUint8Array=function(t){return t instanceof Uint8Array},g._uint8ArrayToBuffer=function(e){return t.from(e.buffer,e.byteOffset,e.byteLength)},Rw.exports}Hw.streamReturningOperators={asIndexedPairs:DT(function(t=void 0){return null!=t&&xT(t,"options"),null!=(null==t?void 0:t.signal)&&kT(t.signal,"options.signal"),async function*(){let e=0;for await(const n of this){var r;if(null!=t&&null!==(r=t.signal)&&void 0!==r&&r.aborted)throw new RT({cause:t.signal.reason});yield[e++,n]}}.call(this)},"readable.asIndexedPairs will be removed in a future version."),drop:function(t,e=void 0){return null!=e&&xT(e,"options"),null!=(null==e?void 0:e.signal)&&kT(e.signal,"options.signal"),t=JT(t),async function*(){var r;if(null!=e&&null!==(r=e.signal)&&void 0!==r&&r.aborted)throw new RT;for await(const r of this){var n;if(null!=e&&null!==(n=e.signal)&&void 0!==n&&n.aborted)throw new RT;t--<=0&&(yield r)}}.call(this)},filter:KT,flatMap:function(t,e){const r=ZT.call(this,t,e);return async function*(){for await(const t of r)yield*t}.call(this)},map:ZT,take:function(t,e=void 0){return null!=e&&xT(e,"options"),null!=(null==e?void 0:e.signal)&&kT(e.signal,"options.signal"),t=JT(t),async function*(){var r;if(null!=e&&null!==(r=e.signal)&&void 0!==r&&r.aborted)throw new RT;for await(const r of this){var n;if(null!=e&&null!==(n=e.signal)&&void 0!==n&&n.aborted)throw new RT;if(t-- >0&&(yield r),t<=0)return}}.call(this)},compose:function(t,e){if(null!=e&&xT(e,"options"),null!=(null==e?void 0:e.signal)&&kT(e.signal,"options.signal"),PT(t)&&!IT(t))throw new vT("stream",t,"must be writable");const r=jT(this,t);return null!=e&&e.signal&&MT(e.signal,r),r}},Hw.promiseReturningOperators={every:async function(t,e=void 0){if("function"!=typeof t)throw new wT("fn",["Function","AsyncFunction"],t);return!await YT.call(this,async(...e)=>!await t(...e),e)},forEach:async function(t,e){if("function"!=typeof t)throw new wT("fn",["Function","AsyncFunction"],t);for await(const r of ZT.call(this,async function(e,r){return await t(e,r),qT},e));},reduce:async function(t,e,r){var n;if("function"!=typeof t)throw new wT("reducer",["Function","AsyncFunction"],t);null!=r&&xT(r,"options"),null!=(null==r?void 0:r.signal)&&kT(r.signal,"options.signal");let i=arguments.length>1;if(null!=r&&null!==(n=r.signal)&&void 0!==n&&n.aborted){const t=new RT(void 0,{cause:r.signal.reason});throw this.once("error",()=>{}),await LT(this.destroy(t)),t}const o=new _T,s=o.signal;if(null!=r&&r.signal){const t={once:!0,[AT]:this,[OT]:!0};r.signal.addEventListener("abort",()=>o.abort(),t)}let a=!1;try{for await(const n of this){var l;if(a=!0,null!=r&&null!==(l=r.signal)&&void 0!==l&&l.aborted)throw new RT;i?e=await t(e,n,{signal:s}):(e=n,i=!0)}if(!a&&!i)throw new QT}finally{o.abort()}return e},toArray:async function(t){null!=t&&xT(t,"options"),null!=(null==t?void 0:t.signal)&&kT(t.signal,"options.signal");const e=[];for await(const n of this){var r;if(null!=t&&null!==(r=t.signal)&&void 0!==r&&r.aborted)throw new RT(void 0,{cause:t.signal.reason});CT(e,n)}return e},some:YT,find:async function(t,e){for await(const r of KT.call(this,t,e))return r}},function(t){const e=nx(),r=rx(),n=e.Readable.destroy;t.exports=e.Readable,t.exports._uint8ArrayToBuffer=e._uint8ArrayToBuffer,t.exports._isUint8Array=e._isUint8Array,t.exports.isDisturbed=e.isDisturbed,t.exports.isErrored=e.isErrored,t.exports.isReadable=e.isReadable,t.exports.Readable=e.Readable,t.exports.Writable=e.Writable,t.exports.Duplex=e.Duplex,t.exports.Transform=e.Transform,t.exports.PassThrough=e.PassThrough,t.exports.addAbortSignal=e.addAbortSignal,t.exports.finished=e.finished,t.exports.destroy=e.destroy,t.exports.destroy=n,t.exports.pipeline=e.pipeline,t.exports.compose=e.compose,Object.defineProperty(e,"promises",{configurable:!0,enumerable:!0,get:()=>r}),t.exports.Stream=e.Stream,t.exports.default=t.exports}(Ew);var ix=Ew.exports,ox=t,sx=ei,ax=Rs,lx=e,ux=vw,cx=s.inherits,hx=Sw,fx=ix.Transform,dx="win32"===process.platform,px=function(t,e){if(!(this instanceof px))return new px(t,e);"string"!=typeof t&&(e=t,t="zip"),e=this.options=ux.defaults(e,{highWaterMark:1048576,statConcurrency:4}),fx.call(this,e),this._format=!1,this._module=!1,this._pending=0,this._pointer=0,this._entriesCount=0,this._entriesProcessedCount=0,this._fsEntriesTotalBytes=0,this._fsEntriesProcessedBytes=0,this._queue=ax.queue(this._onQueueTask.bind(this),1),this._queue.drain(this._onQueueDrain.bind(this)),this._statQueue=ax.queue(this._onStatQueueTask.bind(this),e.statConcurrency),this._statQueue.drain(this._onQueueDrain.bind(this)),this._state={aborted:!1,finalize:!1,finalizing:!1,finalized:!1,modulePiped:!1},this._streams=[]};
31
- /**
32
- * Archiver Core
33
- *
34
- * @ignore
35
- * @license [MIT]{@link https://github.com/archiverjs/node-archiver/blob/master/LICENSE}
36
- * @copyright (c) 2012-2014 Chris Talkington, contributors.
37
- */cx(px,fx),px.prototype._abort=function(){this._state.aborted=!0,this._queue.kill(),this._statQueue.kill(),this._queue.idle()&&this._shutdown()},px.prototype._append=function(t,e){var r={source:null,filepath:t};(e=e||{}).name||(e.name=t),e.sourcePath=t,r.data=e,this._entriesCount++,e.stats&&e.stats instanceof ox.Stats?(r=this._updateQueueTaskWithStats(r,e.stats))&&(e.stats.size&&(this._fsEntriesTotalBytes+=e.stats.size),this._queue.push(r)):this._statQueue.push(r)},px.prototype._finalize=function(){this._state.finalizing||this._state.finalized||this._state.aborted||(this._state.finalizing=!0,this._moduleFinalize(),this._state.finalizing=!1,this._state.finalized=!0)},px.prototype._maybeFinalize=function(){return!(this._state.finalizing||this._state.finalized||this._state.aborted)&&(!!(this._state.finalize&&0===this._pending&&this._queue.idle()&&this._statQueue.idle())&&(this._finalize(),!0))},px.prototype._moduleAppend=function(t,e,r){this._state.aborted?r():this._module.append(t,e,function(t){if(this._task=null,this._state.aborted)this._shutdown();else{if(t)return this.emit("error",t),void setImmediate(r);this.emit("entry",e),this._entriesProcessedCount++,e.stats&&e.stats.size&&(this._fsEntriesProcessedBytes+=e.stats.size),this.emit("progress",{entries:{total:this._entriesCount,processed:this._entriesProcessedCount},fs:{totalBytes:this._fsEntriesTotalBytes,processedBytes:this._fsEntriesProcessedBytes}}),setImmediate(r)}}.bind(this))},px.prototype._moduleFinalize=function(){"function"==typeof this._module.finalize?this._module.finalize():"function"==typeof this._module.end?this._module.end():this.emit("error",new hx("NOENDMETHOD"))},px.prototype._modulePipe=function(){this._module.on("error",this._onModuleError.bind(this)),this._module.pipe(this),this._state.modulePiped=!0},px.prototype._moduleSupports=function(t){return!(!this._module.supports||!this._module.supports[t])&&this._module.supports[t]},px.prototype._moduleUnpipe=function(){this._module.unpipe(this),this._state.modulePiped=!1},px.prototype._normalizeEntryData=function(t,e){t=ux.defaults(t,{type:"file",name:null,date:null,mode:null,prefix:null,sourcePath:null,stats:!1}),e&&!1===t.stats&&(t.stats=e);var r="directory"===t.type;return t.name&&("string"==typeof t.prefix&&""!==t.prefix&&(t.name=t.prefix+"/"+t.name,t.prefix=null),t.name=ux.sanitizePath(t.name),"symlink"!==t.type&&"/"===t.name.slice(-1)?(r=!0,t.type="directory"):r&&(t.name+="/")),"number"==typeof t.mode?t.mode&=dx?511:4095:t.stats&&null===t.mode?(t.mode=dx?511&t.stats.mode:4095&t.stats.mode,dx&&r&&(t.mode=493)):null===t.mode&&(t.mode=r?493:420),t.stats&&null===t.date?t.date=t.stats.mtime:t.date=ux.dateify(t.date),t},px.prototype._onModuleError=function(t){this.emit("error",t)},px.prototype._onQueueDrain=function(){this._state.finalizing||this._state.finalized||this._state.aborted||this._state.finalize&&0===this._pending&&this._queue.idle()&&this._statQueue.idle()&&this._finalize()},px.prototype._onQueueTask=function(t,e){var r=()=>{t.data.callback&&t.data.callback(),e()};this._state.finalizing||this._state.finalized||this._state.aborted?r():(this._task=t,this._moduleAppend(t.source,t.data,r))},px.prototype._onStatQueueTask=function(t,e){this._state.finalizing||this._state.finalized||this._state.aborted?e():ox.lstat(t.filepath,function(r,n){if(this._state.aborted)setImmediate(e);else{if(r)return this._entriesCount--,this.emit("warning",r),void setImmediate(e);(t=this._updateQueueTaskWithStats(t,n))&&(n.size&&(this._fsEntriesTotalBytes+=n.size),this._queue.push(t)),setImmediate(e)}}.bind(this))},px.prototype._shutdown=function(){this._moduleUnpipe(),this.end()},px.prototype._transform=function(t,e,r){t&&(this._pointer+=t.length),r(null,t)},px.prototype._updateQueueTaskWithStats=function(t,e){if(e.isFile())t.data.type="file",t.data.sourceType="stream",t.source=ux.lazyReadStream(t.filepath);else if(e.isDirectory()&&this._moduleSupports("directory"))t.data.name=ux.trailingSlashIt(t.data.name),t.data.type="directory",t.data.sourcePath=ux.trailingSlashIt(t.filepath),t.data.sourceType="buffer",t.source=Buffer.concat([]);else{if(!e.isSymbolicLink()||!this._moduleSupports("symlink"))return e.isDirectory()?this.emit("warning",new hx("DIRECTORYNOTSUPPORTED",t.data)):e.isSymbolicLink()?this.emit("warning",new hx("SYMLINKNOTSUPPORTED",t.data)):this.emit("warning",new hx("ENTRYNOTSUPPORTED",t.data)),null;var r=ox.readlinkSync(t.filepath),n=lx.dirname(t.filepath);t.data.type="symlink",t.data.linkname=lx.relative(n,lx.resolve(n,r)),t.data.sourceType="buffer",t.source=Buffer.concat([])}return t.data=this._normalizeEntryData(t.data,e),t},px.prototype.abort=function(){return this._state.aborted||this._state.finalized||this._abort(),this},px.prototype.append=function(t,e){if(this._state.finalize||this._state.aborted)return this.emit("error",new hx("QUEUECLOSED")),this;if("string"!=typeof(e=this._normalizeEntryData(e)).name||0===e.name.length)return this.emit("error",new hx("ENTRYNAMEREQUIRED")),this;if("directory"===e.type&&!this._moduleSupports("directory"))return this.emit("error",new hx("DIRECTORYNOTSUPPORTED",{name:e.name})),this;if(t=ux.normalizeInputSource(t),Buffer.isBuffer(t))e.sourceType="buffer";else{if(!ux.isStream(t))return this.emit("error",new hx("INPUTSTEAMBUFFERREQUIRED",{name:e.name})),this;e.sourceType="stream"}return this._entriesCount++,this._queue.push({data:e,source:t}),this},px.prototype.directory=function(t,e,r){if(this._state.finalize||this._state.aborted)return this.emit("error",new hx("QUEUECLOSED")),this;if("string"!=typeof t||0===t.length)return this.emit("error",new hx("DIRECTORYDIRPATHREQUIRED")),this;this._pending++,!1===e?e="":"string"!=typeof e&&(e=t);var n=!1;"function"==typeof r?(n=r,r={}):"object"!=typeof r&&(r={});var i=sx(t,{stat:!0,dot:!0});return i.on("error",function(t){this.emit("error",t)}.bind(this)),i.on("match",function(o){i.pause();var s=!1,a=Object.assign({},r);a.name=o.relative,a.prefix=e,a.stats=o.stat,a.callback=i.resume.bind(i);try{if(n)if(!1===(a=n(a)))s=!0;else if("object"!=typeof a)throw new hx("DIRECTORYFUNCTIONINVALIDDATA",{dirpath:t})}catch(t){return void this.emit("error",t)}s?i.resume():this._append(o.absolute,a)}.bind(this)),i.on("end",function(){this._pending--,this._maybeFinalize()}.bind(this)),this},px.prototype.file=function(t,e){return this._state.finalize||this._state.aborted?(this.emit("error",new hx("QUEUECLOSED")),this):"string"!=typeof t||0===t.length?(this.emit("error",new hx("FILEFILEPATHREQUIRED")),this):(this._append(t,e),this)},px.prototype.glob=function(t,e,r){this._pending++,e=ux.defaults(e,{stat:!0,pattern:t});var n=sx(e.cwd||".",e);return n.on("error",function(t){this.emit("error",t)}.bind(this)),n.on("match",function(t){n.pause();var e=Object.assign({},r);e.callback=n.resume.bind(n),e.stats=t.stat,e.name=t.relative,this._append(t.absolute,e)}.bind(this)),n.on("end",function(){this._pending--,this._maybeFinalize()}.bind(this)),this},px.prototype.finalize=function(){if(this._state.aborted){var t=new hx("ABORTED");return this.emit("error",t),Promise.reject(t)}if(this._state.finalize){var e=new hx("FINALIZING");return this.emit("error",e),Promise.reject(e)}this._state.finalize=!0,0===this._pending&&this._queue.idle()&&this._statQueue.idle()&&this._finalize();var r=this;return new Promise(function(t,e){var n;r._module.on("end",function(){n||t()}),r._module.on("error",function(t){n=!0,e(t)})})},px.prototype.setFormat=function(t){return this._format?(this.emit("error",new hx("FORMATSET")),this):(this._format=t,this)},px.prototype.setModule=function(t){return this._state.aborted?(this.emit("error",new hx("ABORTED")),this):this._state.module?(this.emit("error",new hx("MODULESET")),this):(this._module=t,this._modulePipe(),this)},px.prototype.symlink=function(t,e,r){if(this._state.finalize||this._state.aborted)return this.emit("error",new hx("QUEUECLOSED")),this;if("string"!=typeof t||0===t.length)return this.emit("error",new hx("SYMLINKFILEPATHREQUIRED")),this;if("string"!=typeof e||0===e.length)return this.emit("error",new hx("SYMLINKTARGETREQUIRED",{filepath:t})),this;if(!this._moduleSupports("symlink"))return this.emit("error",new hx("SYMLINKNOTSUPPORTED",{filepath:t})),this;var n={type:"symlink"};return n.name=t.replace(/\\/g,"/"),n.linkname=e.replace(/\\/g,"/"),n.sourceType="buffer","number"==typeof r&&(n.mode=r),this._entriesCount++,this._queue.push({data:n,source:Buffer.concat([])}),this},px.prototype.pointer=function(){return this._pointer},px.prototype.use=function(t){return this._streams.push(t),this};var yx=px,gx={exports:{}},bx={exports:{}},mx=bx.exports=function(){};mx.prototype.getName=function(){},mx.prototype.getSize=function(){},mx.prototype.getLastModifiedDate=function(){},mx.prototype.isDirectory=function(){};var _x=bx.exports,vx={exports:{}},wx={exports:{}},Sx={exports:{}},Ex=Sx.exports={};Ex.dateToDos=function(t,e){var r=(e=e||!1)?t.getFullYear():t.getUTCFullYear();return r<1980?2162688:r>=2044?2141175677:r-1980<<25|(e?t.getMonth():t.getUTCMonth())+1<<21|(e?t.getDate():t.getUTCDate())<<16|(e?t.getHours():t.getUTCHours())<<11|(e?t.getMinutes():t.getUTCMinutes())<<5|(e?t.getSeconds():t.getUTCSeconds())/2},Ex.dosToDate=function(t){return new Date(1980+(t>>25&127),(t>>21&15)-1,t>>16&31,t>>11&31,t>>5&63,(31&t)<<1)},Ex.fromDosTime=function(t){return Ex.dosToDate(t.readUInt32LE(0))},Ex.getEightBytes=function(t){var e=Buffer.alloc(8);return e.writeUInt32LE(t%4294967296,0),e.writeUInt32LE(t/4294967296|0,4),e},Ex.getShortBytes=function(t){var e=Buffer.alloc(2);return e.writeUInt16LE((65535&t)>>>0,0),e},Ex.getShortBytesValue=function(t,e){return t.readUInt16LE(e)},Ex.getLongBytes=function(t){var e=Buffer.alloc(4);return e.writeUInt32LE((4294967295&t)>>>0,0),e},Ex.getLongBytesValue=function(t,e){return t.readUInt32LE(e)},Ex.toDosTime=function(t){return Ex.getLongBytes(Ex.dateToDos(t))};var Rx=Sx.exports,kx=Rx,Tx=wx.exports=function(){return this instanceof Tx?(this.descriptor=!1,this.encryption=!1,this.utf8=!1,this.numberOfShannonFanoTrees=0,this.strongEncryption=!1,this.slidingDictionarySize=0,this):new Tx};Tx.prototype.encode=function(){return kx.getShortBytes((this.descriptor?8:0)|(this.utf8?2048:0)|(this.encryption?1:0)|(this.strongEncryption?64:0))},Tx.prototype.parse=function(t,e){var r=kx.getShortBytesValue(t,e),n=new Tx;return n.useDataDescriptor(!!(8&r)),n.useUTF8ForNames(!!(2048&r)),n.useStrongEncryption(!!(64&r)),n.useEncryption(!!(1&r)),n.setSlidingDictionarySize(2&r?8192:4096),n.setNumberOfShannonFanoTrees(4&r?3:2),n},Tx.prototype.setNumberOfShannonFanoTrees=function(t){this.numberOfShannonFanoTrees=t},Tx.prototype.getNumberOfShannonFanoTrees=function(){return this.numberOfShannonFanoTrees},Tx.prototype.setSlidingDictionarySize=function(t){this.slidingDictionarySize=t},Tx.prototype.getSlidingDictionarySize=function(){return this.slidingDictionarySize},Tx.prototype.useDataDescriptor=function(t){this.descriptor=t},Tx.prototype.usesDataDescriptor=function(){return this.descriptor},Tx.prototype.useEncryption=function(t){this.encryption=t},Tx.prototype.usesEncryption=function(){return this.encryption},Tx.prototype.useStrongEncryption=function(t){this.strongEncryption=t},Tx.prototype.usesStrongEncryption=function(){return this.strongEncryption},Tx.prototype.useUTF8ForNames=function(t){this.utf8=t},Tx.prototype.usesUTF8ForNames=function(){return this.utf8};var xx=wx.exports,Ax={WORD:4,DWORD:8,EMPTY:Buffer.alloc(0),SHORT:2,SHORT_MASK:65535,SHORT_SHIFT:16,SHORT_ZERO:Buffer.from(Array(2)),LONG:4,LONG_ZERO:Buffer.from(Array(4)),MIN_VERSION_INITIAL:10,MIN_VERSION_DATA_DESCRIPTOR:20,MIN_VERSION_ZIP64:45,VERSION_MADEBY:45,METHOD_STORED:0,METHOD_DEFLATED:8,PLATFORM_UNIX:3,PLATFORM_FAT:0,SIG_LFH:67324752,SIG_DD:134695760,SIG_CFH:33639248,SIG_EOCD:101010256,SIG_ZIP64_EOCD:101075792,SIG_ZIP64_EOCD_LOC:117853008,ZIP64_MAGIC_SHORT:65535,ZIP64_MAGIC:4294967295,ZIP64_EXTRA_ID:1,ZLIB_NO_COMPRESSION:0,ZLIB_BEST_SPEED:1,ZLIB_BEST_COMPRESSION:9,ZLIB_DEFAULT_COMPRESSION:-1,MODE_MASK:4095,DEFAULT_FILE_MODE:33188,DEFAULT_DIR_MODE:16877,EXT_FILE_ATTR_DIR:1106051088,EXT_FILE_ATTR_FILE:2175008800,S_IFMT:61440,S_IFIFO:4096,S_IFCHR:8192,S_IFDIR:16384,S_IFBLK:24576,S_IFREG:32768,S_IFLNK:40960,S_IFSOCK:49152,S_DOS_A:32,S_DOS_D:16,S_DOS_V:8,S_DOS_S:4,S_DOS_H:2,S_DOS_R:1},Ox=s.inherits,Lx=fl,jx=_x,Mx=xx,Ix={PERM_MASK:4095,FILE_TYPE_FLAG:61440,LINK_FLAG:40960,FILE_FLAG:32768,DIR_FLAG:16384,DEFAULT_LINK_PERM:511,DEFAULT_DIR_PERM:493,DEFAULT_FILE_PERM:420},Px=Ax,Dx=Rx,Cx=vx.exports=function(t){if(!(this instanceof Cx))return new Cx(t);jx.call(this),this.platform=Px.PLATFORM_FAT,this.method=-1,this.name=null,this.size=0,this.csize=0,this.gpb=new Mx,this.crc=0,this.time=-1,this.minver=Px.MIN_VERSION_INITIAL,this.mode=-1,this.extra=null,this.exattr=0,this.inattr=0,this.comment=null,t&&this.setName(t)};Ox(Cx,jx),Cx.prototype.getCentralDirectoryExtra=function(){return this.getExtra()},Cx.prototype.getComment=function(){return null!==this.comment?this.comment:""},Cx.prototype.getCompressedSize=function(){return this.csize},Cx.prototype.getCrc=function(){return this.crc},Cx.prototype.getExternalAttributes=function(){return this.exattr},Cx.prototype.getExtra=function(){return null!==this.extra?this.extra:Px.EMPTY},Cx.prototype.getGeneralPurposeBit=function(){return this.gpb},Cx.prototype.getInternalAttributes=function(){return this.inattr},Cx.prototype.getLastModifiedDate=function(){return this.getTime()},Cx.prototype.getLocalFileDataExtra=function(){return this.getExtra()},Cx.prototype.getMethod=function(){return this.method},Cx.prototype.getName=function(){return this.name},Cx.prototype.getPlatform=function(){return this.platform},Cx.prototype.getSize=function(){return this.size},Cx.prototype.getTime=function(){return-1!==this.time?Dx.dosToDate(this.time):-1},Cx.prototype.getTimeDos=function(){return-1!==this.time?this.time:0},Cx.prototype.getUnixMode=function(){return this.platform!==Px.PLATFORM_UNIX?0:this.getExternalAttributes()>>Px.SHORT_SHIFT&Px.SHORT_MASK},Cx.prototype.getVersionNeededToExtract=function(){return this.minver},Cx.prototype.setComment=function(t){Buffer.byteLength(t)!==t.length&&this.getGeneralPurposeBit().useUTF8ForNames(!0),this.comment=t},Cx.prototype.setCompressedSize=function(t){if(t<0)throw new Error("invalid entry compressed size");this.csize=t},Cx.prototype.setCrc=function(t){if(t<0)throw new Error("invalid entry crc32");this.crc=t},Cx.prototype.setExternalAttributes=function(t){this.exattr=t>>>0},Cx.prototype.setExtra=function(t){this.extra=t},Cx.prototype.setGeneralPurposeBit=function(t){if(!(t instanceof Mx))throw new Error("invalid entry GeneralPurposeBit");this.gpb=t},Cx.prototype.setInternalAttributes=function(t){this.inattr=t},Cx.prototype.setMethod=function(t){if(t<0)throw new Error("invalid entry compression method");this.method=t},Cx.prototype.setName=function(t,e=!1){t=Lx(t,!1).replace(/^\w+:/,"").replace(/^(\.\.\/|\/)+/,""),e&&(t=`/${t}`),Buffer.byteLength(t)!==t.length&&this.getGeneralPurposeBit().useUTF8ForNames(!0),this.name=t},Cx.prototype.setPlatform=function(t){this.platform=t},Cx.prototype.setSize=function(t){if(t<0)throw new Error("invalid entry size");this.size=t},Cx.prototype.setTime=function(t,e){if(!(t instanceof Date))throw new Error("invalid entry time");this.time=Dx.dateToDos(t,e)},Cx.prototype.setUnixMode=function(t){var e=0;e|=(t|=this.isDirectory()?Px.S_IFDIR:Px.S_IFREG)<<Px.SHORT_SHIFT|(this.isDirectory()?Px.S_DOS_D:Px.S_DOS_A),this.setExternalAttributes(e),this.mode=t&Px.MODE_MASK,this.platform=Px.PLATFORM_UNIX},Cx.prototype.setVersionNeededToExtract=function(t){this.minver=t},Cx.prototype.isDirectory=function(){return"/"===this.getName().slice(-1)},Cx.prototype.isUnixSymlink=function(){return(this.getUnixMode()&Ix.FILE_TYPE_FLAG)===Ix.LINK_FLAG},Cx.prototype.isZip64=function(){return this.csize>Px.ZIP64_MAGIC||this.size>Px.ZIP64_MAGIC};var Nx=vx.exports,Fx={exports:{}};const Bx=t=>null!==t&&"object"==typeof t&&"function"==typeof t.pipe;Bx.writable=t=>Bx(t)&&!1!==t.writable&&"function"==typeof t._write&&"object"==typeof t._writableState,Bx.readable=t=>Bx(t)&&!1!==t.readable&&"function"==typeof t._read&&"object"==typeof t._readableState,Bx.duplex=t=>Bx.writable(t)&&Bx.readable(t),Bx.transform=t=>Bx.duplex(t)&&"function"==typeof t._transform;var Wx=Bx,Ux={exports:{}},zx={exports:{}};let $x=class extends Error{constructor(t){if(!Array.isArray(t))throw new TypeError("Expected input to be an Array, got "+typeof t);let e="";for(let r=0;r<t.length;r++)e+=` ${t[r].stack}\n`;super(e),this.name="AggregateError",this.errors=t}};var Hx={AggregateError:$x,ArrayIsArray:t=>Array.isArray(t),ArrayPrototypeIncludes:(t,e)=>t.includes(e),ArrayPrototypeIndexOf:(t,e)=>t.indexOf(e),ArrayPrototypeJoin:(t,e)=>t.join(e),ArrayPrototypeMap:(t,e)=>t.map(e),ArrayPrototypePop:(t,e)=>t.pop(e),ArrayPrototypePush:(t,e)=>t.push(e),ArrayPrototypeSlice:(t,e,r)=>t.slice(e,r),Error:Error,FunctionPrototypeCall:(t,e,...r)=>t.call(e,...r),FunctionPrototypeSymbolHasInstance:(t,e)=>Function.prototype[Symbol.hasInstance].call(t,e),MathFloor:Math.floor,Number:Number,NumberIsInteger:Number.isInteger,NumberIsNaN:Number.isNaN,NumberMAX_SAFE_INTEGER:Number.MAX_SAFE_INTEGER,NumberMIN_SAFE_INTEGER:Number.MIN_SAFE_INTEGER,NumberParseInt:Number.parseInt,ObjectDefineProperties:(t,e)=>Object.defineProperties(t,e),ObjectDefineProperty:(t,e,r)=>Object.defineProperty(t,e,r),ObjectGetOwnPropertyDescriptor:(t,e)=>Object.getOwnPropertyDescriptor(t,e),ObjectKeys:t=>Object.keys(t),ObjectSetPrototypeOf:(t,e)=>Object.setPrototypeOf(t,e),Promise:Promise,PromisePrototypeCatch:(t,e)=>t.catch(e),PromisePrototypeThen:(t,e,r)=>t.then(e,r),PromiseReject:t=>Promise.reject(t),PromiseResolve:t=>Promise.resolve(t),ReflectApply:Reflect.apply,RegExpPrototypeTest:(t,e)=>t.test(e),SafeSet:Set,String:String,StringPrototypeSlice:(t,e,r)=>t.slice(e,r),StringPrototypeToLowerCase:t=>t.toLowerCase(),StringPrototypeToUpperCase:t=>t.toUpperCase(),StringPrototypeTrim:t=>t.trim(),Symbol:Symbol,SymbolFor:Symbol.for,SymbolAsyncIterator:Symbol.asyncIterator,SymbolHasInstance:Symbol.hasInstance,SymbolIterator:Symbol.iterator,SymbolDispose:Symbol.dispose||Symbol("Symbol.dispose"),SymbolAsyncDispose:Symbol.asyncDispose||Symbol("Symbol.asyncDispose"),TypedArrayPrototypeSet:(t,e,r)=>t.set(e,r),Boolean:Boolean,Uint8Array:Uint8Array},Gx={exports:{}},qx={format:(t,...e)=>t.replace(/%([sdifj])/g,function(...[t,r]){const n=e.shift();if("f"===r)return n.toFixed(6);if("j"===r)return JSON.stringify(n);if("s"===r&&"object"==typeof n){return`${n.constructor!==Object?n.constructor.name:""} {}`.trim()}return n.toString()}),inspect(t){switch(typeof t){case"string":if(t.includes("'")){if(!t.includes('"'))return`"${t}"`;if(!t.includes("`")&&!t.includes("${"))return`\`${t}\``}return`'${t}'`;case"number":return isNaN(t)?"NaN":Object.is(t,-0)?String(t):t;case"bigint":return`${String(t)}n`;case"boolean":case"undefined":return String(t);case"object":return"{}"}}};const{format:Vx,inspect:Zx}=qx,{AggregateError:Yx}=Hx,Kx=globalThis.AggregateError||Yx,Qx=Symbol("kIsNodeError"),Jx=["string","function","number","object","Function","Object","boolean","bigint","symbol"],Xx=/^([A-Z][a-z0-9]*)+$/,tA={};function eA(t,e){if(!t)throw new tA.ERR_INTERNAL_ASSERTION(e)}function rA(t){let e="",r=t.length;const n="-"===t[0]?1:0;for(;r>=n+4;r-=3)e=`_${t.slice(r-3,r)}${e}`;return`${t.slice(0,r)}${e}`}function nA(t,e,r){r||(r=Error);class n extends r{constructor(...r){super(function(t,e,r){if("function"==typeof e)return eA(e.length<=r.length,`Code: ${t}; The provided arguments length (${r.length}) does not match the required ones (${e.length}).`),e(...r);const n=(e.match(/%[dfijoOs]/g)||[]).length;return eA(n===r.length,`Code: ${t}; The provided arguments length (${r.length}) does not match the required ones (${n}).`),0===r.length?e:Vx(e,...r)}(t,e,r))}toString(){return`${this.name} [${t}]: ${this.message}`}}Object.defineProperties(n.prototype,{name:{value:r.name,writable:!0,enumerable:!1,configurable:!0},toString:{value(){return`${this.name} [${t}]: ${this.message}`},writable:!0,enumerable:!1,configurable:!0}}),n.prototype.code=t,n.prototype[Qx]=!0,tA[t]=n}function iA(t){const e="__node_internal_"+t.name;return Object.defineProperty(t,"name",{value:e}),t}let oA=class extends Error{constructor(t="The operation was aborted",e=void 0){if(void 0!==e&&"object"!=typeof e)throw new tA.ERR_INVALID_ARG_TYPE("options","Object",e);super(t,e),this.code="ABORT_ERR",this.name="AbortError"}};nA("ERR_ASSERTION","%s",Error),nA("ERR_INVALID_ARG_TYPE",(t,e,r)=>{eA("string"==typeof t,"'name' must be a string"),Array.isArray(e)||(e=[e]);let n="The ";t.endsWith(" argument")?n+=`${t} `:n+=`"${t}" ${t.includes(".")?"property":"argument"} `,n+="must be ";const i=[],o=[],s=[];for(const t of e)eA("string"==typeof t,"All expected entries have to be of type string"),Jx.includes(t)?i.push(t.toLowerCase()):Xx.test(t)?o.push(t):(eA("object"!==t,'The value "object" should be written as "Object"'),s.push(t));if(o.length>0){const t=i.indexOf("object");-1!==t&&(i.splice(i,t,1),o.push("Object"))}if(i.length>0){switch(i.length){case 1:n+=`of type ${i[0]}`;break;case 2:n+=`one of type ${i[0]} or ${i[1]}`;break;default:{const t=i.pop();n+=`one of type ${i.join(", ")}, or ${t}`}}(o.length>0||s.length>0)&&(n+=" or ")}if(o.length>0){switch(o.length){case 1:n+=`an instance of ${o[0]}`;break;case 2:n+=`an instance of ${o[0]} or ${o[1]}`;break;default:{const t=o.pop();n+=`an instance of ${o.join(", ")}, or ${t}`}}s.length>0&&(n+=" or ")}switch(s.length){case 0:break;case 1:s[0].toLowerCase()!==s[0]&&(n+="an "),n+=`${s[0]}`;break;case 2:n+=`one of ${s[0]} or ${s[1]}`;break;default:{const t=s.pop();n+=`one of ${s.join(", ")}, or ${t}`}}if(null==r)n+=`. Received ${r}`;else if("function"==typeof r&&r.name)n+=`. Received function ${r.name}`;else if("object"==typeof r){var a;if(null!==(a=r.constructor)&&void 0!==a&&a.name)n+=`. Received an instance of ${r.constructor.name}`;else{n+=`. Received ${Zx(r,{depth:-1})}`}}else{let t=Zx(r,{colors:!1});t.length>25&&(t=`${t.slice(0,25)}...`),n+=`. Received type ${typeof r} (${t})`}return n},TypeError),nA("ERR_INVALID_ARG_VALUE",(t,e,r="is invalid")=>{let n=Zx(e);n.length>128&&(n=n.slice(0,128)+"...");return`The ${t.includes(".")?"property":"argument"} '${t}' ${r}. Received ${n}`},TypeError),nA("ERR_INVALID_RETURN_VALUE",(t,e,r)=>{var n;return`Expected ${t} to be returned from the "${e}" function but got ${null!=r&&null!==(n=r.constructor)&&void 0!==n&&n.name?`instance of ${r.constructor.name}`:"type "+typeof r}.`},TypeError),nA("ERR_MISSING_ARGS",(...t)=>{let e;eA(t.length>0,"At least one arg needs to be specified");const r=t.length;switch(t=(Array.isArray(t)?t:[t]).map(t=>`"${t}"`).join(" or "),r){case 1:e+=`The ${t[0]} argument`;break;case 2:e+=`The ${t[0]} and ${t[1]} arguments`;break;default:{const r=t.pop();e+=`The ${t.join(", ")}, and ${r} arguments`}}return`${e} must be specified`},TypeError),nA("ERR_OUT_OF_RANGE",(t,e,r)=>{let n;if(eA(e,'Missing "range" argument'),Number.isInteger(r)&&Math.abs(r)>2**32)n=rA(String(r));else if("bigint"==typeof r){n=String(r);const t=BigInt(2)**BigInt(32);(r>t||r<-t)&&(n=rA(n)),n+="n"}else n=Zx(r);return`The value of "${t}" is out of range. It must be ${e}. Received ${n}`},RangeError),nA("ERR_MULTIPLE_CALLBACK","Callback called multiple times",Error),nA("ERR_METHOD_NOT_IMPLEMENTED","The %s method is not implemented",Error),nA("ERR_STREAM_ALREADY_FINISHED","Cannot call %s after a stream was finished",Error),nA("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable",Error),nA("ERR_STREAM_DESTROYED","Cannot call %s after a stream was destroyed",Error),nA("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),nA("ERR_STREAM_PREMATURE_CLOSE","Premature close",Error),nA("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF",Error),nA("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event",Error),nA("ERR_STREAM_WRITE_AFTER_END","write after end",Error),nA("ERR_UNKNOWN_ENCODING","Unknown encoding: %s",TypeError);var sA={AbortError:oA,aggregateTwoErrors:iA(function(t,e){if(t&&e&&t!==e){if(Array.isArray(e.errors))return e.errors.push(t),e;const r=new Kx([e,t],e.message);return r.code=e.code,r}return t||e}),hideStackFrames:iA,codes:tA};!function(t){const e=ca,{format:r,inspect:n}=qx,{codes:{ERR_INVALID_ARG_TYPE:i}}=sA,{kResistStopPropagation:o,AggregateError:s,SymbolDispose:a}=Hx,l=globalThis.AbortSignal||Kc().AbortSignal,u=globalThis.AbortController||Kc().AbortController,c=Object.getPrototypeOf(async function(){}).constructor,h=globalThis.Blob||e.Blob,f=void 0!==h?function(t){return t instanceof h}:function(t){return!1},d=(t,e)=>{if(void 0!==t&&(null===t||"object"!=typeof t||!("aborted"in t)))throw new i(e,"AbortSignal",t)};t.exports={AggregateError:s,kEmptyObject:Object.freeze({}),once(t){let e=!1;return function(...r){e||(e=!0,t.apply(this,r))}},createDeferredPromise:function(){let t,e;return{promise:new Promise((r,n)=>{t=r,e=n}),resolve:t,reject:e}},promisify:t=>new Promise((e,r)=>{t((t,...n)=>t?r(t):e(...n))}),debuglog:()=>function(){},format:r,inspect:n,types:{isAsyncFunction:t=>t instanceof c,isArrayBufferView:t=>ArrayBuffer.isView(t)},isBlob:f,deprecate:(t,e)=>t,addAbortListener:yn.addAbortListener||function(t,e){if(void 0===t)throw new i("signal","AbortSignal",t);let r;return d(t,"signal"),((t,e)=>{if("function"!=typeof t)throw new i(e,"Function",t)})(e,"listener"),t.aborted?queueMicrotask(()=>e()):(t.addEventListener("abort",e,{__proto__:null,once:!0,[o]:!0}),r=()=>{t.removeEventListener("abort",e)}),{__proto__:null,[a](){var t;null===(t=r)||void 0===t||t()}}},AbortSignalAny:l.any||function(t){if(1===t.length)return t[0];const e=new u,r=()=>e.abort();return t.forEach(t=>{d(t,"signals"),t.addEventListener("abort",r,{once:!0})}),e.signal.addEventListener("abort",()=>{t.forEach(t=>t.removeEventListener("abort",r))},{once:!0}),e.signal}},t.exports.promisify.custom=Symbol.for("nodejs.util.promisify.custom")}(Gx);var aA=Gx.exports,lA={};const{ArrayIsArray:uA,ArrayPrototypeIncludes:cA,ArrayPrototypeJoin:hA,ArrayPrototypeMap:fA,NumberIsInteger:dA,NumberIsNaN:pA,NumberMAX_SAFE_INTEGER:yA,NumberMIN_SAFE_INTEGER:gA,NumberParseInt:bA,ObjectPrototypeHasOwnProperty:mA,RegExpPrototypeExec:_A,String:vA,StringPrototypeToUpperCase:wA,StringPrototypeTrim:SA}=Hx,{hideStackFrames:EA,codes:{ERR_SOCKET_BAD_PORT:RA,ERR_INVALID_ARG_TYPE:kA,ERR_INVALID_ARG_VALUE:TA,ERR_OUT_OF_RANGE:xA,ERR_UNKNOWN_SIGNAL:AA}}=sA,{normalizeEncoding:OA}=aA,{isAsyncFunction:LA,isArrayBufferView:jA}=aA.types,MA={};const IA=/^[0-7]+$/;const PA=EA((t,e,r=gA,n=yA)=>{if("number"!=typeof t)throw new kA(e,"number",t);if(!dA(t))throw new xA(e,"an integer",t);if(t<r||t>n)throw new xA(e,`>= ${r} && <= ${n}`,t)}),DA=EA((t,e,r=-2147483648,n=2147483647)=>{if("number"!=typeof t)throw new kA(e,"number",t);if(!dA(t))throw new xA(e,"an integer",t);if(t<r||t>n)throw new xA(e,`>= ${r} && <= ${n}`,t)}),CA=EA((t,e,r=!1)=>{if("number"!=typeof t)throw new kA(e,"number",t);if(!dA(t))throw new xA(e,"an integer",t);const n=r?1:0,i=4294967295;if(t<n||t>i)throw new xA(e,`>= ${n} && <= ${i}`,t)});function NA(t,e){if("string"!=typeof t)throw new kA(e,"string",t)}const FA=EA((t,e,r)=>{if(!cA(r,t)){const n=hA(fA(r,t=>"string"==typeof t?`'${t}'`:vA(t)),", ");throw new TA(e,t,"must be one of: "+n)}});function BA(t,e){if("boolean"!=typeof t)throw new kA(e,"boolean",t)}function WA(t,e,r){return null!=t&&mA(t,e)?t[e]:r}const UA=EA((t,e,r=null)=>{const n=WA(r,"allowArray",!1),i=WA(r,"allowFunction",!1);if(!WA(r,"nullable",!1)&&null===t||!n&&uA(t)||"object"!=typeof t&&(!i||"function"!=typeof t))throw new kA(e,"Object",t)}),zA=EA((t,e)=>{if(null!=t&&"object"!=typeof t&&"function"!=typeof t)throw new kA(e,"a dictionary",t)}),$A=EA((t,e,r=0)=>{if(!uA(t))throw new kA(e,"Array",t);if(t.length<r){throw new TA(e,t,`must be longer than ${r}`)}});const HA=EA((t,e="buffer")=>{if(!jA(t))throw new kA(e,["Buffer","TypedArray","DataView"],t)});const GA=EA((t,e)=>{if(void 0!==t&&(null===t||"object"!=typeof t||!("aborted"in t)))throw new kA(e,"AbortSignal",t)}),qA=EA((t,e)=>{if("function"!=typeof t)throw new kA(e,"Function",t)}),VA=EA((t,e)=>{if("function"!=typeof t||LA(t))throw new kA(e,"Function",t)}),ZA=EA((t,e)=>{if(void 0!==t)throw new kA(e,"undefined",t)});const YA=/^(?:<[^>]*>)(?:\s*;\s*[^;"\s]+(?:=(")?[^;"\s]*\1)?)*$/;function KA(t,e){if(void 0===t||!_A(YA,t))throw new TA(e,t,'must be an array or string of format "</styles.css>; rel=preload; as=style"')}var QA={isInt32:function(t){return t===(0|t)},isUint32:function(t){return t===t>>>0},parseFileMode:function(t,e,r){if(void 0===t&&(t=r),"string"==typeof t){if(null===_A(IA,t))throw new TA(e,t,"must be a 32-bit unsigned integer or an octal string");t=bA(t,8)}return CA(t,e),t},validateArray:$A,validateStringArray:function(t,e){$A(t,e);for(let r=0;r<t.length;r++)NA(t[r],`${e}[${r}]`)},validateBooleanArray:function(t,e){$A(t,e);for(let r=0;r<t.length;r++)BA(t[r],`${e}[${r}]`)},validateAbortSignalArray:function(t,e){$A(t,e);for(let r=0;r<t.length;r++){const n=t[r],i=`${e}[${r}]`;if(null==n)throw new kA(i,"AbortSignal",n);GA(n,i)}},validateBoolean:BA,validateBuffer:HA,validateDictionary:zA,validateEncoding:function(t,e){const r=OA(e),n=t.length;if("hex"===r&&n%2!=0)throw new TA("encoding",e,`is invalid for data of length ${n}`)},validateFunction:qA,validateInt32:DA,validateInteger:PA,validateNumber:function(t,e,r=void 0,n){if("number"!=typeof t)throw new kA(e,"number",t);if(null!=r&&t<r||null!=n&&t>n||(null!=r||null!=n)&&pA(t))throw new xA(e,`${null!=r?`>= ${r}`:""}${null!=r&&null!=n?" && ":""}${null!=n?`<= ${n}`:""}`,t)},validateObject:UA,validateOneOf:FA,validatePlainFunction:VA,validatePort:function(t,e="Port",r=!0){if("number"!=typeof t&&"string"!=typeof t||"string"==typeof t&&0===SA(t).length||+t!==+t>>>0||t>65535||0===t&&!r)throw new RA(e,t,r);return 0|t},validateSignalName:function(t,e="signal"){if(NA(t,e),void 0===MA[t]){if(void 0!==MA[wA(t)])throw new AA(t+" (signals must use all capital letters)");throw new AA(t)}},validateString:NA,validateUint32:CA,validateUndefined:ZA,validateUnion:function(t,e,r){if(!cA(r,t))throw new kA(e,`('${hA(r,"|")}')`,t)},validateAbortSignal:GA,validateLinkHeaderValue:function(t){if("string"==typeof t)return KA(t,"hints"),t;if(uA(t)){const e=t.length;let r="";if(0===e)return r;for(let n=0;n<e;n++){const i=t[n];KA(i,"hints"),r+=i,n!==e-1&&(r+=", ")}return r}throw new TA("hints",t,'must be an array or string of format "</styles.css>; rel=preload; as=style"')}},JA={exports:{}};const{SymbolAsyncIterator:XA,SymbolIterator:tO,SymbolFor:eO}=Hx,rO=eO("nodejs.stream.destroyed"),nO=eO("nodejs.stream.errored"),iO=eO("nodejs.stream.readable"),oO=eO("nodejs.stream.writable"),sO=eO("nodejs.stream.disturbed"),aO=eO("nodejs.webstream.isClosedPromise"),lO=eO("nodejs.webstream.controllerErrorFunction");function uO(t,e=!1){var r;return!(!t||"function"!=typeof t.pipe||"function"!=typeof t.on||e&&("function"!=typeof t.pause||"function"!=typeof t.resume)||t._writableState&&!1===(null===(r=t._readableState)||void 0===r?void 0:r.readable)||t._writableState&&!t._readableState)}function cO(t){var e;return!(!t||"function"!=typeof t.write||"function"!=typeof t.on||t._readableState&&!1===(null===(e=t._writableState)||void 0===e?void 0:e.writable))}function hO(t){return t&&(t._readableState||t._writableState||"function"==typeof t.write&&"function"==typeof t.on||"function"==typeof t.pipe&&"function"==typeof t.on)}function fO(t){return!(!t||hO(t)||"function"!=typeof t.pipeThrough||"function"!=typeof t.getReader||"function"!=typeof t.cancel)}function dO(t){return!(!t||hO(t)||"function"!=typeof t.getWriter||"function"!=typeof t.abort)}function pO(t){return!(!t||hO(t)||"object"!=typeof t.readable||"object"!=typeof t.writable)}function yO(t){if(!hO(t))return null;const e=t._writableState,r=t._readableState,n=e||r;return!!(t.destroyed||t[rO]||null!=n&&n.destroyed)}function gO(t){if(!cO(t))return null;if(!0===t.writableEnded)return!0;const e=t._writableState;return(null==e||!e.errored)&&("boolean"!=typeof(null==e?void 0:e.ended)?null:e.ended)}function bO(t,e){if(!uO(t))return null;const r=t._readableState;return(null==r||!r.errored)&&("boolean"!=typeof(null==r?void 0:r.endEmitted)?null:!!(r.endEmitted||!1===e&&!0===r.ended&&0===r.length))}function mO(t){return t&&null!=t[iO]?t[iO]:"boolean"!=typeof(null==t?void 0:t.readable)?null:!yO(t)&&(uO(t)&&t.readable&&!bO(t))}function _O(t){return t&&null!=t[oO]?t[oO]:"boolean"!=typeof(null==t?void 0:t.writable)?null:!yO(t)&&(cO(t)&&t.writable&&!gO(t))}function vO(t){return"boolean"==typeof t._closed&&"boolean"==typeof t._defaultKeepAlive&&"boolean"==typeof t._removedConnection&&"boolean"==typeof t._removedContLen}function wO(t){return"boolean"==typeof t._sent100&&vO(t)}var SO={isDestroyed:yO,kIsDestroyed:rO,isDisturbed:function(t){var e;return!(!t||!(null!==(e=t[sO])&&void 0!==e?e:t.readableDidRead||t.readableAborted))},kIsDisturbed:sO,isErrored:function(t){var e,r,n,i,o,s,a,l,u,c;return!(!t||!(null!==(e=null!==(r=null!==(n=null!==(i=null!==(o=null!==(s=t[nO])&&void 0!==s?s:t.readableErrored)&&void 0!==o?o:t.writableErrored)&&void 0!==i?i:null===(a=t._readableState)||void 0===a?void 0:a.errorEmitted)&&void 0!==n?n:null===(l=t._writableState)||void 0===l?void 0:l.errorEmitted)&&void 0!==r?r:null===(u=t._readableState)||void 0===u?void 0:u.errored)&&void 0!==e?e:null===(c=t._writableState)||void 0===c?void 0:c.errored))},kIsErrored:nO,isReadable:mO,kIsReadable:iO,kIsClosedPromise:aO,kControllerErrorFunction:lO,kIsWritable:oO,isClosed:function(t){if(!hO(t))return null;if("boolean"==typeof t.closed)return t.closed;const e=t._writableState,r=t._readableState;return"boolean"==typeof(null==e?void 0:e.closed)||"boolean"==typeof(null==r?void 0:r.closed)?(null==e?void 0:e.closed)||(null==r?void 0:r.closed):"boolean"==typeof t._closed&&vO(t)?t._closed:null},isDuplexNodeStream:function(t){return!(!t||"function"!=typeof t.pipe||!t._readableState||"function"!=typeof t.on||"function"!=typeof t.write)},isFinished:function(t,e){return hO(t)?!!yO(t)||(!1===(null==e?void 0:e.readable)||!mO(t))&&(!1===(null==e?void 0:e.writable)||!_O(t)):null},isIterable:function(t,e){return null!=t&&(!0===e?"function"==typeof t[XA]:!1===e?"function"==typeof t[tO]:"function"==typeof t[XA]||"function"==typeof t[tO])},isReadableNodeStream:uO,isReadableStream:fO,isReadableEnded:function(t){if(!uO(t))return null;if(!0===t.readableEnded)return!0;const e=t._readableState;return!(!e||e.errored)&&("boolean"!=typeof(null==e?void 0:e.ended)?null:e.ended)},isReadableFinished:bO,isReadableErrored:function(t){var e,r;return hO(t)?t.readableErrored?t.readableErrored:null!==(e=null===(r=t._readableState)||void 0===r?void 0:r.errored)&&void 0!==e?e:null:null},isNodeStream:hO,isWebStream:function(t){return fO(t)||dO(t)||pO(t)},isWritable:_O,isWritableNodeStream:cO,isWritableStream:dO,isWritableEnded:gO,isWritableFinished:function(t,e){if(!cO(t))return null;if(!0===t.writableFinished)return!0;const r=t._writableState;return(null==r||!r.errored)&&("boolean"!=typeof(null==r?void 0:r.finished)?null:!!(r.finished||!1===e&&!0===r.ended&&0===r.length))},isWritableErrored:function(t){var e,r;return hO(t)?t.writableErrored?t.writableErrored:null!==(e=null===(r=t._writableState)||void 0===r?void 0:r.errored)&&void 0!==e?e:null:null},isServerRequest:function(t){var e;return"boolean"==typeof t._consuming&&"boolean"==typeof t._dumped&&void 0===(null===(e=t.req)||void 0===e?void 0:e.upgradeOrConnect)},isServerResponse:wO,willEmitClose:function(t){if(!hO(t))return null;const e=t._writableState,r=t._readableState,n=e||r;return!n&&wO(t)||!!(n&&n.autoDestroy&&n.emitClose&&!1===n.closed)},isTransformStream:pO};const EO=of,{AbortError:RO,codes:kO}=sA,{ERR_INVALID_ARG_TYPE:TO,ERR_STREAM_PREMATURE_CLOSE:xO}=kO,{kEmptyObject:AO,once:OO}=aA,{validateAbortSignal:LO,validateFunction:jO,validateObject:MO,validateBoolean:IO}=QA,{Promise:PO,PromisePrototypeThen:DO,SymbolDispose:CO}=Hx,{isClosed:NO,isReadable:FO,isReadableNodeStream:BO,isReadableStream:WO,isReadableFinished:UO,isReadableErrored:zO,isWritable:$O,isWritableNodeStream:HO,isWritableStream:GO,isWritableFinished:qO,isWritableErrored:VO,isNodeStream:ZO,willEmitClose:YO,kIsClosedPromise:KO}=SO;let QO;const JO=()=>{};function XO(t,e,r){var n,i;if(2===arguments.length?(r=e,e=AO):null==e?e=AO:MO(e,"options"),jO(r,"callback"),LO(e.signal,"options.signal"),r=OO(r),WO(t)||GO(t))return function(t,e,r){let n=!1,i=JO;if(e.signal)if(i=()=>{n=!0,r.call(t,new RO(void 0,{cause:e.signal.reason}))},e.signal.aborted)EO.nextTick(i);else{QO=QO||aA.addAbortListener;const n=QO(e.signal,i),o=r;r=OO((...e)=>{n[CO](),o.apply(t,e)})}const o=(...e)=>{n||EO.nextTick(()=>r.apply(t,e))};return DO(t[KO].promise,o,o),JO}(t,e,r);if(!ZO(t))throw new TO("stream",["ReadableStream","WritableStream","Stream"],t);const o=null!==(n=e.readable)&&void 0!==n?n:BO(t),s=null!==(i=e.writable)&&void 0!==i?i:HO(t),a=t._writableState,l=t._readableState,u=()=>{t.writable||f()};let c=YO(t)&&BO(t)===o&&HO(t)===s,h=qO(t,!1);const f=()=>{h=!0,t.destroyed&&(c=!1),(!c||t.readable&&!o)&&(o&&!d||r.call(t))};let d=UO(t,!1);const p=()=>{d=!0,t.destroyed&&(c=!1),(!c||t.writable&&!s)&&(s&&!h||r.call(t))},y=e=>{r.call(t,e)};let g=NO(t);const b=()=>{g=!0;const e=VO(t)||zO(t);return e&&"boolean"!=typeof e?r.call(t,e):o&&!d&&BO(t,!0)&&!UO(t,!1)?r.call(t,new xO):!s||h||qO(t,!1)?void r.call(t):r.call(t,new xO)},m=()=>{g=!0;const e=VO(t)||zO(t);if(e&&"boolean"!=typeof e)return r.call(t,e);r.call(t)},_=()=>{t.req.on("finish",f)};!function(t){return t.setHeader&&"function"==typeof t.abort}(t)?s&&!a&&(t.on("end",u),t.on("close",u)):(t.on("complete",f),c||t.on("abort",b),t.req?_():t.on("request",_)),c||"boolean"!=typeof t.aborted||t.on("aborted",b),t.on("end",p),t.on("finish",f),!1!==e.error&&t.on("error",y),t.on("close",b),g?EO.nextTick(b):null!=a&&a.errorEmitted||null!=l&&l.errorEmitted?c||EO.nextTick(m):(o||c&&!FO(t)||!h&&!1!==$O(t))&&(s||c&&!$O(t)||!d&&!1!==FO(t))?l&&t.req&&t.aborted&&EO.nextTick(m):EO.nextTick(m);const v=()=>{r=JO,t.removeListener("aborted",b),t.removeListener("complete",f),t.removeListener("abort",b),t.removeListener("request",_),t.req&&t.req.removeListener("finish",f),t.removeListener("end",u),t.removeListener("close",u),t.removeListener("finish",f),t.removeListener("end",p),t.removeListener("error",y),t.removeListener("close",b)};if(e.signal&&!g){const n=()=>{const n=r;v(),n.call(t,new RO(void 0,{cause:e.signal.reason}))};if(e.signal.aborted)EO.nextTick(n);else{QO=QO||aA.addAbortListener;const i=QO(e.signal,n),o=r;r=OO((...e)=>{i[CO](),o.apply(t,e)})}}return v}JA.exports=XO,JA.exports.finished=function(t,e){var r;let n=!1;return null===e&&(e=AO),null!==(r=e)&&void 0!==r&&r.cleanup&&(IO(e.cleanup,"cleanup"),n=e.cleanup),new PO((r,i)=>{const o=XO(t,e,t=>{n&&o(),t?i(t):r()})})};var tL=JA.exports;const eL=of,{aggregateTwoErrors:rL,codes:{ERR_MULTIPLE_CALLBACK:nL},AbortError:iL}=sA,{Symbol:oL}=Hx,{kIsDestroyed:sL,isDestroyed:aL,isFinished:lL,isServerRequest:uL}=SO,cL=oL("kDestroy"),hL=oL("kConstruct");function fL(t,e,r){t&&(t.stack,e&&!e.errored&&(e.errored=t),r&&!r.errored&&(r.errored=t))}function dL(t,e,r){let n=!1;function i(e){if(n)return;n=!0;const i=t._readableState,o=t._writableState;fL(e,o,i),o&&(o.closed=!0),i&&(i.closed=!0),"function"==typeof r&&r(e),e?eL.nextTick(pL,t,e):eL.nextTick(yL,t)}try{t._destroy(e||null,i)}catch(e){i(e)}}function pL(t,e){gL(t,e),yL(t)}function yL(t){const e=t._readableState,r=t._writableState;r&&(r.closeEmitted=!0),e&&(e.closeEmitted=!0),(null!=r&&r.emitClose||null!=e&&e.emitClose)&&t.emit("close")}function gL(t,e){const r=t._readableState,n=t._writableState;null!=n&&n.errorEmitted||null!=r&&r.errorEmitted||(n&&(n.errorEmitted=!0),r&&(r.errorEmitted=!0),t.emit("error",e))}function bL(t,e,r){const n=t._readableState,i=t._writableState;if(null!=i&&i.destroyed||null!=n&&n.destroyed)return this;null!=n&&n.autoDestroy||null!=i&&i.autoDestroy?t.destroy(e):e&&(e.stack,i&&!i.errored&&(i.errored=e),n&&!n.errored&&(n.errored=e),r?eL.nextTick(gL,t,e):gL(t,e))}function mL(t){let e=!1;function r(r){if(e)return void bL(t,null!=r?r:new nL);e=!0;const n=t._readableState,i=t._writableState,o=i||n;n&&(n.constructed=!0),i&&(i.constructed=!0),o.destroyed?t.emit(cL,r):r?bL(t,r,!0):eL.nextTick(_L,t)}try{t._construct(t=>{eL.nextTick(r,t)})}catch(t){eL.nextTick(r,t)}}function _L(t){t.emit(hL)}function vL(t){return(null==t?void 0:t.setHeader)&&"function"==typeof t.abort}function wL(t){t.emit("close")}function SL(t,e){t.emit("error",e),eL.nextTick(wL,t)}var EL={construct:function(t,e){if("function"!=typeof t._construct)return;const r=t._readableState,n=t._writableState;r&&(r.constructed=!1),n&&(n.constructed=!1),t.once(hL,e),t.listenerCount(hL)>1||eL.nextTick(mL,t)},destroyer:function(t,e){t&&!aL(t)&&(e||lL(t)||(e=new iL),uL(t)?(t.socket=null,t.destroy(e)):vL(t)?t.abort():vL(t.req)?t.req.abort():"function"==typeof t.destroy?t.destroy(e):"function"==typeof t.close?t.close():e?eL.nextTick(SL,t,e):eL.nextTick(wL,t),t.destroyed||(t[sL]=!0))},destroy:function(t,e){const r=this._readableState,n=this._writableState,i=n||r;return null!=n&&n.destroyed||null!=r&&r.destroyed?("function"==typeof e&&e(),this):(fL(t,n,r),n&&(n.destroyed=!0),r&&(r.destroyed=!0),i.constructed?dL(this,t,e):this.once(cL,function(r){dL(this,rL(r,t),e)}),this)},undestroy:function(){const t=this._readableState,e=this._writableState;t&&(t.constructed=!0,t.closed=!1,t.closeEmitted=!1,t.destroyed=!1,t.errored=null,t.errorEmitted=!1,t.reading=!1,t.ended=!1===t.readable,t.endEmitted=!1===t.readable),e&&(e.constructed=!0,e.destroyed=!1,e.closed=!1,e.closeEmitted=!1,e.errored=null,e.errorEmitted=!1,e.finalCalled=!1,e.prefinished=!1,e.ended=!1===e.writable,e.ending=!1===e.writable,e.finished=!1===e.writable)},errorOrDestroy:bL};const{ArrayIsArray:RL,ObjectSetPrototypeOf:kL}=Hx,{EventEmitter:TL}=yn;function xL(t){TL.call(this,t)}function AL(t,e,r){if("function"==typeof t.prependListener)return t.prependListener(e,r);t._events&&t._events[e]?RL(t._events[e])?t._events[e].unshift(r):t._events[e]=[r,t._events[e]]:t.on(e,r)}kL(xL.prototype,TL.prototype),kL(xL,TL),xL.prototype.pipe=function(t,e){const r=this;function n(e){t.writable&&!1===t.write(e)&&r.pause&&r.pause()}function i(){r.readable&&r.resume&&r.resume()}r.on("data",n),t.on("drain",i),t._isStdio||e&&!1===e.end||(r.on("end",s),r.on("close",a));let o=!1;function s(){o||(o=!0,t.end())}function a(){o||(o=!0,"function"==typeof t.destroy&&t.destroy())}function l(t){u(),0===TL.listenerCount(this,"error")&&this.emit("error",t)}function u(){r.removeListener("data",n),t.removeListener("drain",i),r.removeListener("end",s),r.removeListener("close",a),r.removeListener("error",l),t.removeListener("error",l),r.removeListener("end",u),r.removeListener("close",u),t.removeListener("close",u)}return AL(r,"error",l),AL(t,"error",l),r.on("end",u),r.on("close",u),t.on("close",u),t.emit("pipe",r),t};var OL={Stream:xL,prependListener:AL},LL={exports:{}};!function(t){const{SymbolDispose:e}=Hx,{AbortError:r,codes:n}=sA,{isNodeStream:i,isWebStream:o,kControllerErrorFunction:s}=SO,a=tL,{ERR_INVALID_ARG_TYPE:l}=n;let u;t.exports.addAbortSignal=function(e,r){if(((t,e)=>{if("object"!=typeof t||!("aborted"in t))throw new l(e,"AbortSignal",t)})(e,"signal"),!i(r)&&!o(r))throw new l("stream",["ReadableStream","WritableStream","Stream"],r);return t.exports.addAbortSignalNoValidate(e,r)},t.exports.addAbortSignalNoValidate=function(t,n){if("object"!=typeof t||!("aborted"in t))return n;const o=i(n)?()=>{n.destroy(new r(void 0,{cause:t.reason}))}:()=>{n[s](new r(void 0,{cause:t.reason}))};if(t.aborted)o();else{u=u||aA.addAbortListener;const r=u(t,o);a(n,r[e])}return n}}(LL);var jL=LL.exports;const{StringPrototypeSlice:ML,SymbolIterator:IL,TypedArrayPrototypeSet:PL,Uint8Array:DL}=Hx,{Buffer:CL}=ca,{inspect:NL}=aA;var FL=class{constructor(){this.head=null,this.tail=null,this.length=0}push(t){const e={data:t,next:null};this.length>0?this.tail.next=e:this.head=e,this.tail=e,++this.length}unshift(t){const e={data:t,next:this.head};0===this.length&&(this.tail=e),this.head=e,++this.length}shift(){if(0===this.length)return;const t=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,t}clear(){this.head=this.tail=null,this.length=0}join(t){if(0===this.length)return"";let e=this.head,r=""+e.data;for(;null!==(e=e.next);)r+=t+e.data;return r}concat(t){if(0===this.length)return CL.alloc(0);const e=CL.allocUnsafe(t>>>0);let r=this.head,n=0;for(;r;)PL(e,r.data,n),n+=r.data.length,r=r.next;return e}consume(t,e){const r=this.head.data;if(t<r.length){const e=r.slice(0,t);return this.head.data=r.slice(t),e}return t===r.length?this.shift():e?this._getString(t):this._getBuffer(t)}first(){return this.head.data}*[IL](){for(let t=this.head;t;t=t.next)yield t.data}_getString(t){let e="",r=this.head,n=0;do{const i=r.data;if(!(t>i.length)){t===i.length?(e+=i,++n,r.next?this.head=r.next:this.head=this.tail=null):(e+=ML(i,0,t),this.head=r,r.data=ML(i,t));break}e+=i,t-=i.length,++n}while(null!==(r=r.next));return this.length-=n,e}_getBuffer(t){const e=CL.allocUnsafe(t),r=t;let n=this.head,i=0;do{const o=n.data;if(!(t>o.length)){t===o.length?(PL(e,o,r-t),++i,n.next?this.head=n.next:this.head=this.tail=null):(PL(e,new DL(o.buffer,o.byteOffset,t),r-t),this.head=n,n.data=o.slice(t));break}PL(e,o,r-t),t-=o.length,++i}while(null!==(n=n.next));return this.length-=i,e}[Symbol.for("nodejs.util.inspect.custom")](t,e){return NL(this,{...e,depth:0,customInspect:!1})}};const{MathFloor:BL,NumberIsInteger:WL}=Hx,{validateInteger:UL}=QA,{ERR_INVALID_ARG_VALUE:zL}=sA.codes;let $L=16384,HL=16;function GL(t){return t?HL:$L}var qL={getHighWaterMark:function(t,e,r,n){const i=function(t,e,r){return null!=t.highWaterMark?t.highWaterMark:e?t[r]:null}(e,n,r);if(null!=i){if(!WL(i)||i<0){throw new zL(n?`options.${r}`:"options.highWaterMark",i)}return BL(i)}return GL(t.objectMode)},getDefaultHighWaterMark:GL,setDefaultHighWaterMark:function(t,e){UL(e,"value",0),t?HL=e:$L=e}},VL={},ZL=rp.Buffer,YL=ZL.isEncoding||function(t){switch((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 KL(t){var e;switch(this.encoding=function(t){var e=function(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}}(t);if("string"!=typeof e&&(ZL.isEncoding===YL||!YL(t)))throw new Error("Unknown encoding: "+t);return e||t}(t),this.encoding){case"utf16le":this.text=XL,this.end=tj,e=4;break;case"utf8":this.fillLast=JL,e=4;break;case"base64":this.text=ej,this.end=rj,e=3;break;default:return this.write=nj,void(this.end=ij)}this.lastNeed=0,this.lastTotal=0,this.lastChar=ZL.allocUnsafe(e)}function QL(t){return t<=127?0:t>>5==6?2:t>>4==14?3:t>>3==30?4:t>>6==2?-1:-2}function JL(t){var e=this.lastTotal-this.lastNeed,r=function(t,e){if(128!=(192&e[0]))return t.lastNeed=0,"�";if(t.lastNeed>1&&e.length>1){if(128!=(192&e[1]))return t.lastNeed=1,"�";if(t.lastNeed>2&&e.length>2&&128!=(192&e[2]))return t.lastNeed=2,"�"}}(this,t);return void 0!==r?r:this.lastNeed<=t.length?(t.copy(this.lastChar,e,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(t.copy(this.lastChar,e,0,t.length),void(this.lastNeed-=t.length))}function XL(t,e){if((t.length-e)%2==0){var r=t.toString("utf16le",e);if(r){var n=r.charCodeAt(r.length-1);if(n>=55296&&n<=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 tj(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 ej(t,e){var r=(t.length-e)%3;return 0===r?t.toString("base64",e):(this.lastNeed=3-r,this.lastTotal=3,1===r?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 rj(t){var e=t&&t.length?this.write(t):"";return this.lastNeed?e+this.lastChar.toString("base64",0,3-this.lastNeed):e}function nj(t){return t.toString(this.encoding)}function ij(t){return t&&t.length?this.write(t):""}VL.StringDecoder=KL,KL.prototype.write=function(t){if(0===t.length)return"";var e,r;if(this.lastNeed){if(void 0===(e=this.fillLast(t)))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||""},KL.prototype.end=function(t){var e=t&&t.length?this.write(t):"";return this.lastNeed?e+"�":e},KL.prototype.text=function(t,e){var r=function(t,e,r){var n=e.length-1;if(n<r)return 0;var i=QL(e[n]);if(i>=0)return i>0&&(t.lastNeed=i-1),i;if(--n<r||-2===i)return 0;if(i=QL(e[n]),i>=0)return i>0&&(t.lastNeed=i-2),i;if(--n<r||-2===i)return 0;if(i=QL(e[n]),i>=0)return i>0&&(2===i?i=0:t.lastNeed=i-3),i;return 0}(this,t,e);if(!this.lastNeed)return t.toString("utf8",e);this.lastTotal=r;var n=t.length-(r-this.lastNeed);return t.copy(this.lastChar,0,n),t.toString("utf8",e,n)},KL.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};const oj=of,{PromisePrototypeThen:sj,SymbolAsyncIterator:aj,SymbolIterator:lj}=Hx,{Buffer:uj}=ca,{ERR_INVALID_ARG_TYPE:cj,ERR_STREAM_NULL_VALUES:hj}=sA.codes;var fj,dj,pj,yj,gj,bj,mj,_j,vj=function(t,e,r){let n,i;if("string"==typeof e||e instanceof uj)return new t({objectMode:!0,...r,read(){this.push(e),this.push(null)}});if(e&&e[aj])i=!0,n=e[aj]();else{if(!e||!e[lj])throw new cj("iterable",["Iterable"],e);i=!1,n=e[lj]()}const o=new t({objectMode:!0,highWaterMark:1,...r});let s=!1;return o._read=function(){s||(s=!0,async function(){for(;;){try{const{value:t,done:e}=i?await n.next():n.next();if(e)o.push(null);else{const e=t&&"function"==typeof t.then?await t:t;if(null===e)throw s=!1,new hj;if(o.push(e))continue;s=!1}}catch(t){o.destroy(t)}break}}())},o._destroy=function(t,e){sj(async function(t){const e=null!=t,r="function"==typeof n.throw;if(e&&r){const{value:e,done:r}=await n.throw(t);if(await e,r)return}if("function"==typeof n.return){const{value:t}=await n.return();await t}}(t),()=>oj.nextTick(e,t),r=>oj.nextTick(e,r||t))},o};function wj(){if(dj)return fj;dj=1;const t=of,{ArrayPrototypeIndexOf:e,NumberIsInteger:r,NumberIsNaN:n,NumberParseInt:i,ObjectDefineProperties:o,ObjectKeys:s,ObjectSetPrototypeOf:a,Promise:l,SafeSet:u,SymbolAsyncDispose:c,SymbolAsyncIterator:h,Symbol:f}=Hx;fj=H,H.ReadableState=$;const{EventEmitter:d}=yn,{Stream:p,prependListener:y}=OL,{Buffer:g}=ca,{addAbortSignal:b}=jL,m=tL;let _=aA.debuglog("stream",t=>{_=t});const v=FL,w=EL,{getHighWaterMark:S,getDefaultHighWaterMark:E}=qL,{aggregateTwoErrors:R,codes:{ERR_INVALID_ARG_TYPE:k,ERR_METHOD_NOT_IMPLEMENTED:T,ERR_OUT_OF_RANGE:x,ERR_STREAM_PUSH_AFTER_EOF:A,ERR_STREAM_UNSHIFT_AFTER_END_EVENT:O},AbortError:L}=sA,{validateObject:j}=QA,M=f("kPaused"),{StringDecoder:I}=VL,P=vj;a(H.prototype,p.prototype),a(H,p);const D=()=>{},{errorOrDestroy:C}=w,N=1,F=16,B=32,W=2048,U=4096;function z(t){return{enumerable:!1,get(){return 0!==(this.state&t)},set(e){e?this.state|=t:this.state&=~t}}}function $(t,e,r){"boolean"!=typeof r&&(r=e instanceof Rj()),this.state=W|U|F|B,t&&t.objectMode&&(this.state|=N),r&&t&&t.readableObjectMode&&(this.state|=N),this.highWaterMark=t?S(this,t,"readableHighWaterMark",r):E(!1),this.buffer=new v,this.length=0,this.pipes=[],this.flowing=null,this[M]=null,t&&!1===t.emitClose&&(this.state&=~W),t&&!1===t.autoDestroy&&(this.state&=~U),this.errored=null,this.defaultEncoding=t&&t.defaultEncoding||"utf8",this.awaitDrainWriters=null,this.decoder=null,this.encoding=null,t&&t.encoding&&(this.decoder=new I(t.encoding),this.encoding=t.encoding)}function H(t){if(!(this instanceof H))return new H(t);const e=this instanceof Rj();this._readableState=new $(t,this,e),t&&("function"==typeof t.read&&(this._read=t.read),"function"==typeof t.destroy&&(this._destroy=t.destroy),"function"==typeof t.construct&&(this._construct=t.construct),t.signal&&!e&&b(t.signal,this)),p.call(this,t),w.construct(this,()=>{this._readableState.needReadable&&K(this,this._readableState)})}function G(t,e,r,n){_("readableAddChunk",e);const i=t._readableState;let o;if(0===(i.state&N)&&("string"==typeof e?(r=r||i.defaultEncoding,i.encoding!==r&&(n&&i.encoding?e=g.from(e,r).toString(i.encoding):(e=g.from(e,r),r=""))):e instanceof g?r="":p._isUint8Array(e)?(e=p._uint8ArrayToBuffer(e),r=""):null!=e&&(o=new k("chunk",["string","Buffer","Uint8Array"],e))),o)C(t,o);else if(null===e)i.state&=-9,function(t,e){if(_("onEofChunk"),e.ended)return;if(e.decoder){const t=e.decoder.end();t&&t.length&&(e.buffer.push(t),e.length+=e.objectMode?1:t.length)}e.ended=!0,e.sync?Z(t):(e.needReadable=!1,e.emittedReadable=!0,Y(t))}(t,i);else if(0!==(i.state&N)||e&&e.length>0)if(n)if(4&i.state)C(t,new O);else{if(i.destroyed||i.errored)return!1;q(t,i,e,!0)}else if(i.ended)C(t,new A);else{if(i.destroyed||i.errored)return!1;i.state&=-9,i.decoder&&!r?(e=i.decoder.write(e),i.objectMode||0!==e.length?q(t,i,e,!1):K(t,i)):q(t,i,e,!1)}else n||(i.state&=-9,K(t,i));return!i.ended&&(i.length<i.highWaterMark||0===i.length)}function q(t,e,r,n){e.flowing&&0===e.length&&!e.sync&&t.listenerCount("data")>0?(65536&e.state?e.awaitDrainWriters.clear():e.awaitDrainWriters=null,e.dataEmitted=!0,t.emit("data",r)):(e.length+=e.objectMode?1:r.length,n?e.buffer.unshift(r):e.buffer.push(r),64&e.state&&Z(t)),K(t,e)}o($.prototype,{objectMode:z(N),ended:z(2),endEmitted:z(4),reading:z(8),constructed:z(F),sync:z(B),needReadable:z(64),emittedReadable:z(128),readableListening:z(256),resumeScheduled:z(512),errorEmitted:z(1024),emitClose:z(W),autoDestroy:z(U),destroyed:z(8192),closed:z(16384),closeEmitted:z(32768),multiAwaitDrain:z(65536),readingMore:z(1<<17),dataEmitted:z(1<<18)}),H.prototype.destroy=w.destroy,H.prototype._undestroy=w.undestroy,H.prototype._destroy=function(t,e){e(t)},H.prototype[d.captureRejectionSymbol]=function(t){this.destroy(t)},H.prototype[c]=function(){let t;return this.destroyed||(t=this.readableEnded?null:new L,this.destroy(t)),new l((e,r)=>m(this,n=>n&&n!==t?r(n):e(null)))},H.prototype.push=function(t,e){return G(this,t,e,!1)},H.prototype.unshift=function(t,e){return G(this,t,e,!0)},H.prototype.isPaused=function(){const t=this._readableState;return!0===t[M]||!1===t.flowing},H.prototype.setEncoding=function(t){const e=new I(t);this._readableState.decoder=e,this._readableState.encoding=this._readableState.decoder.encoding;const r=this._readableState.buffer;let n="";for(const t of r)n+=e.write(t);return r.clear(),""!==n&&r.push(n),this._readableState.length=n.length,this};function V(t,e){return t<=0||0===e.length&&e.ended?0:0!==(e.state&N)?1:n(t)?e.flowing&&e.length?e.buffer.first().length:e.length:t<=e.length?t:e.ended?e.length:0}function Z(e){const r=e._readableState;_("emitReadable",r.needReadable,r.emittedReadable),r.needReadable=!1,r.emittedReadable||(_("emitReadable",r.flowing),r.emittedReadable=!0,t.nextTick(Y,e))}function Y(t){const e=t._readableState;_("emitReadable_",e.destroyed,e.length,e.ended),e.destroyed||e.errored||!e.length&&!e.ended||(t.emit("readable"),e.emittedReadable=!1),e.needReadable=!e.flowing&&!e.ended&&e.length<=e.highWaterMark,et(t)}function K(e,r){!r.readingMore&&r.constructed&&(r.readingMore=!0,t.nextTick(Q,e,r))}function Q(t,e){for(;!e.reading&&!e.ended&&(e.length<e.highWaterMark||e.flowing&&0===e.length);){const r=e.length;if(_("maybeReadMore read 0"),t.read(0),r===e.length)break}e.readingMore=!1}function J(t){const e=t._readableState;e.readableListening=t.listenerCount("readable")>0,e.resumeScheduled&&!1===e[M]?e.flowing=!0:t.listenerCount("data")>0?t.resume():e.readableListening||(e.flowing=null)}function X(t){_("readable nexttick read 0"),t.read(0)}function tt(t,e){_("resume",e.reading),e.reading||t.read(0),e.resumeScheduled=!1,t.emit("resume"),et(t),e.flowing&&!e.reading&&t.read(0)}function et(t){const e=t._readableState;for(_("flow",e.flowing);e.flowing&&null!==t.read(););}function rt(t,e){"function"!=typeof t.read&&(t=H.wrap(t,{objectMode:!0}));const r=async function*(t,e){let r,n=D;function i(e){this===t?(n(),n=D):n=e}t.on("readable",i);const o=m(t,{writable:!1},t=>{r=t?R(r,t):null,n(),n=D});try{for(;;){const e=t.destroyed?null:t.read();if(null!==e)yield e;else{if(r)throw r;if(null===r)return;await new l(i)}}}catch(t){throw r=R(r,t),r}finally{!r&&!1===(null==e?void 0:e.destroyOnReturn)||void 0!==r&&!t._readableState.autoDestroy?(t.off("readable",i),o()):w.destroyer(t,null)}}(t,e);return r.stream=t,r}function nt(t,e){if(0===e.length)return null;let r;return e.objectMode?r=e.buffer.shift():!t||t>=e.length?(r=e.decoder?e.buffer.join(""):1===e.buffer.length?e.buffer.first():e.buffer.concat(e.length),e.buffer.clear()):r=e.buffer.consume(t,e.decoder),r}function it(e){const r=e._readableState;_("endReadable",r.endEmitted),r.endEmitted||(r.ended=!0,t.nextTick(ot,r,e))}function ot(e,r){if(_("endReadableNT",e.endEmitted,e.length),!e.errored&&!e.closeEmitted&&!e.endEmitted&&0===e.length)if(e.endEmitted=!0,r.emit("end"),r.writable&&!1===r.allowHalfOpen)t.nextTick(st,r);else if(e.autoDestroy){const t=r._writableState;(!t||t.autoDestroy&&(t.finished||!1===t.writable))&&r.destroy()}}function st(t){t.writable&&!t.writableEnded&&!t.destroyed&&t.end()}let at;function lt(){return void 0===at&&(at={}),at}return H.prototype.read=function(t){_("read",t),void 0===t?t=NaN:r(t)||(t=i(t,10));const e=this._readableState,n=t;if(t>e.highWaterMark&&(e.highWaterMark=function(t){if(t>1073741824)throw new x("size","<= 1GiB",t);return t--,t|=t>>>1,t|=t>>>2,t|=t>>>4,t|=t>>>8,t|=t>>>16,++t}(t)),0!==t&&(e.state&=-129),0===t&&e.needReadable&&((0!==e.highWaterMark?e.length>=e.highWaterMark:e.length>0)||e.ended))return _("read: emitReadable",e.length,e.ended),0===e.length&&e.ended?it(this):Z(this),null;if(0===(t=V(t,e))&&e.ended)return 0===e.length&&it(this),null;let o,s=!!(64&e.state);if(_("need readable",s),(0===e.length||e.length-t<e.highWaterMark)&&(s=!0,_("length less than watermark",s)),e.ended||e.reading||e.destroyed||e.errored||!e.constructed)s=!1,_("reading, ended or constructing",s);else if(s){_("do read"),e.state|=8|B,0===e.length&&(e.state|=64);try{this._read(e.highWaterMark)}catch(t){C(this,t)}e.state&=~B,e.reading||(t=V(n,e))}return o=t>0?nt(t,e):null,null===o?(e.needReadable=e.length<=e.highWaterMark,t=0):(e.length-=t,e.multiAwaitDrain?e.awaitDrainWriters.clear():e.awaitDrainWriters=null),0===e.length&&(e.ended||(e.needReadable=!0),n!==t&&e.ended&&it(this)),null===o||e.errorEmitted||e.closeEmitted||(e.dataEmitted=!0,this.emit("data",o)),o},H.prototype._read=function(t){throw new T("_read()")},H.prototype.pipe=function(e,r){const n=this,i=this._readableState;1===i.pipes.length&&(i.multiAwaitDrain||(i.multiAwaitDrain=!0,i.awaitDrainWriters=new u(i.awaitDrainWriters?[i.awaitDrainWriters]:[]))),i.pipes.push(e),_("pipe count=%d opts=%j",i.pipes.length,r);const o=(!r||!1!==r.end)&&e!==t.stdout&&e!==t.stderr?a:b;function s(t,r){_("onunpipe"),t===n&&r&&!1===r.hasUnpiped&&(r.hasUnpiped=!0,function(){_("cleanup"),e.removeListener("close",p),e.removeListener("finish",g),l&&e.removeListener("drain",l);e.removeListener("error",d),e.removeListener("unpipe",s),n.removeListener("end",a),n.removeListener("end",b),n.removeListener("data",f),c=!0,l&&i.awaitDrainWriters&&(!e._writableState||e._writableState.needDrain)&&l()}())}function a(){_("onend"),e.end()}let l;i.endEmitted?t.nextTick(o):n.once("end",o),e.on("unpipe",s);let c=!1;function h(){c||(1===i.pipes.length&&i.pipes[0]===e?(_("false write response, pause",0),i.awaitDrainWriters=e,i.multiAwaitDrain=!1):i.pipes.length>1&&i.pipes.includes(e)&&(_("false write response, pause",i.awaitDrainWriters.size),i.awaitDrainWriters.add(e)),n.pause()),l||(l=function(t,e){return function(){const r=t._readableState;r.awaitDrainWriters===e?(_("pipeOnDrain",1),r.awaitDrainWriters=null):r.multiAwaitDrain&&(_("pipeOnDrain",r.awaitDrainWriters.size),r.awaitDrainWriters.delete(e)),r.awaitDrainWriters&&0!==r.awaitDrainWriters.size||!t.listenerCount("data")||t.resume()}}(n,e),e.on("drain",l))}function f(t){_("ondata");const r=e.write(t);_("dest.write",r),!1===r&&h()}function d(t){if(_("onerror",t),b(),e.removeListener("error",d),0===e.listenerCount("error")){const r=e._writableState||e._readableState;r&&!r.errorEmitted?C(e,t):e.emit("error",t)}}function p(){e.removeListener("finish",g),b()}function g(){_("onfinish"),e.removeListener("close",p),b()}function b(){_("unpipe"),n.unpipe(e)}return n.on("data",f),y(e,"error",d),e.once("close",p),e.once("finish",g),e.emit("pipe",n),!0===e.writableNeedDrain?h():i.flowing||(_("pipe resume"),n.resume()),e},H.prototype.unpipe=function(t){const r=this._readableState;if(0===r.pipes.length)return this;if(!t){const t=r.pipes;r.pipes=[],this.pause();for(let e=0;e<t.length;e++)t[e].emit("unpipe",this,{hasUnpiped:!1});return this}const n=e(r.pipes,t);return-1===n||(r.pipes.splice(n,1),0===r.pipes.length&&this.pause(),t.emit("unpipe",this,{hasUnpiped:!1})),this},H.prototype.on=function(e,r){const n=p.prototype.on.call(this,e,r),i=this._readableState;return"data"===e?(i.readableListening=this.listenerCount("readable")>0,!1!==i.flowing&&this.resume()):"readable"===e&&(i.endEmitted||i.readableListening||(i.readableListening=i.needReadable=!0,i.flowing=!1,i.emittedReadable=!1,_("on readable",i.length,i.reading),i.length?Z(this):i.reading||t.nextTick(X,this))),n},H.prototype.addListener=H.prototype.on,H.prototype.removeListener=function(e,r){const n=p.prototype.removeListener.call(this,e,r);return"readable"===e&&t.nextTick(J,this),n},H.prototype.off=H.prototype.removeListener,H.prototype.removeAllListeners=function(e){const r=p.prototype.removeAllListeners.apply(this,arguments);return"readable"!==e&&void 0!==e||t.nextTick(J,this),r},H.prototype.resume=function(){const e=this._readableState;return e.flowing||(_("resume"),e.flowing=!e.readableListening,function(e,r){r.resumeScheduled||(r.resumeScheduled=!0,t.nextTick(tt,e,r))}(this,e)),e[M]=!1,this},H.prototype.pause=function(){return _("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(_("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState[M]=!0,this},H.prototype.wrap=function(t){let e=!1;t.on("data",r=>{!this.push(r)&&t.pause&&(e=!0,t.pause())}),t.on("end",()=>{this.push(null)}),t.on("error",t=>{C(this,t)}),t.on("close",()=>{this.destroy()}),t.on("destroy",()=>{this.destroy()}),this._read=()=>{e&&t.resume&&(e=!1,t.resume())};const r=s(t);for(let e=1;e<r.length;e++){const n=r[e];void 0===this[n]&&"function"==typeof t[n]&&(this[n]=t[n].bind(t))}return this},H.prototype[h]=function(){return rt(this)},H.prototype.iterator=function(t){return void 0!==t&&j(t,"options"),rt(this,t)},o(H.prototype,{readable:{__proto__:null,get(){const t=this._readableState;return!(!t||!1===t.readable||t.destroyed||t.errorEmitted||t.endEmitted)},set(t){this._readableState&&(this._readableState.readable=!!t)}},readableDidRead:{__proto__:null,enumerable:!1,get:function(){return this._readableState.dataEmitted}},readableAborted:{__proto__:null,enumerable:!1,get:function(){return!(!1===this._readableState.readable||!this._readableState.destroyed&&!this._readableState.errored||this._readableState.endEmitted)}},readableHighWaterMark:{__proto__:null,enumerable:!1,get:function(){return this._readableState.highWaterMark}},readableBuffer:{__proto__:null,enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}},readableFlowing:{__proto__:null,enumerable:!1,get:function(){return this._readableState.flowing},set:function(t){this._readableState&&(this._readableState.flowing=t)}},readableLength:{__proto__:null,enumerable:!1,get(){return this._readableState.length}},readableObjectMode:{__proto__:null,enumerable:!1,get(){return!!this._readableState&&this._readableState.objectMode}},readableEncoding:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.encoding:null}},errored:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.errored:null}},closed:{__proto__:null,get(){return!!this._readableState&&this._readableState.closed}},destroyed:{__proto__:null,enumerable:!1,get(){return!!this._readableState&&this._readableState.destroyed},set(t){this._readableState&&(this._readableState.destroyed=t)}},readableEnded:{__proto__:null,enumerable:!1,get(){return!!this._readableState&&this._readableState.endEmitted}}}),o($.prototype,{pipesCount:{__proto__:null,get(){return this.pipes.length}},paused:{__proto__:null,get(){return!1!==this[M]},set(t){this[M]=!!t}}}),H._fromList=nt,H.from=function(t,e){return P(H,t,e)},H.fromWeb=function(t,e){return lt().newStreamReadableFromReadableStream(t,e)},H.toWeb=function(t,e){return lt().newReadableStreamFromStreamReadable(t,e)},H.wrap=function(t,e){var r,n;return new H({objectMode:null===(r=null!==(n=t.readableObjectMode)&&void 0!==n?n:t.objectMode)||void 0===r||r,...e,destroy(e,r){w.destroyer(t,e),r(e)}}).wrap(t)},fj}function Sj(){if(yj)return pj;yj=1;const t=of,{ArrayPrototypeSlice:e,Error:r,FunctionPrototypeSymbolHasInstance:n,ObjectDefineProperty:i,ObjectDefineProperties:o,ObjectSetPrototypeOf:s,StringPrototypeToLowerCase:a,Symbol:l,SymbolHasInstance:u}=Hx;pj=j,j.WritableState=O;const{EventEmitter:c}=yn,h=OL.Stream,{Buffer:f}=ca,d=EL,{addAbortSignal:p}=jL,{getHighWaterMark:y,getDefaultHighWaterMark:g}=qL,{ERR_INVALID_ARG_TYPE:b,ERR_METHOD_NOT_IMPLEMENTED:m,ERR_MULTIPLE_CALLBACK:_,ERR_STREAM_CANNOT_PIPE:v,ERR_STREAM_DESTROYED:w,ERR_STREAM_ALREADY_FINISHED:S,ERR_STREAM_NULL_VALUES:E,ERR_STREAM_WRITE_AFTER_END:R,ERR_UNKNOWN_ENCODING:k}=sA.codes,{errorOrDestroy:T}=d;function x(){}s(j.prototype,h.prototype),s(j,h);const A=l("kOnFinished");function O(t,e,r){"boolean"!=typeof r&&(r=e instanceof Rj()),this.objectMode=!(!t||!t.objectMode),r&&(this.objectMode=this.objectMode||!(!t||!t.writableObjectMode)),this.highWaterMark=t?y(this,t,"writableHighWaterMark",r):g(!1),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;const n=!(!t||!1!==t.decodeStrings);this.decodeStrings=!n,this.defaultEncoding=t&&t.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=D.bind(void 0,e),this.writecb=null,this.writelen=0,this.afterWriteTickInfo=null,L(this),this.pendingcb=0,this.constructed=!0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=!t||!1!==t.emitClose,this.autoDestroy=!t||!1!==t.autoDestroy,this.errored=null,this.closed=!1,this.closeEmitted=!1,this[A]=[]}function L(t){t.buffered=[],t.bufferedIndex=0,t.allBuffers=!0,t.allNoop=!0}function j(t){const e=this instanceof Rj();if(!e&&!n(j,this))return new j(t);this._writableState=new O(t,this,e),t&&("function"==typeof t.write&&(this._write=t.write),"function"==typeof t.writev&&(this._writev=t.writev),"function"==typeof t.destroy&&(this._destroy=t.destroy),"function"==typeof t.final&&(this._final=t.final),"function"==typeof t.construct&&(this._construct=t.construct),t.signal&&p(t.signal,this)),h.call(this,t),d.construct(this,()=>{const t=this._writableState;t.writing||B(this,t),z(this,t)})}function M(e,r,n,i){const o=e._writableState;if("function"==typeof n)i=n,n=o.defaultEncoding;else{if(n){if("buffer"!==n&&!f.isEncoding(n))throw new k(n)}else n=o.defaultEncoding;"function"!=typeof i&&(i=x)}if(null===r)throw new E;if(!o.objectMode)if("string"==typeof r)!1!==o.decodeStrings&&(r=f.from(r,n),n="buffer");else if(r instanceof f)n="buffer";else{if(!h._isUint8Array(r))throw new b("chunk",["string","Buffer","Uint8Array"],r);r=h._uint8ArrayToBuffer(r),n="buffer"}let s;return o.ending?s=new R:o.destroyed&&(s=new w("write")),s?(t.nextTick(i,s),T(e,s,!0),s):(o.pendingcb++,function(t,e,r,n,i){const o=e.objectMode?1:r.length;e.length+=o;const s=e.length<e.highWaterMark;s||(e.needDrain=!0);e.writing||e.corked||e.errored||!e.constructed?(e.buffered.push({chunk:r,encoding:n,callback:i}),e.allBuffers&&"buffer"!==n&&(e.allBuffers=!1),e.allNoop&&i!==x&&(e.allNoop=!1)):(e.writelen=o,e.writecb=i,e.writing=!0,e.sync=!0,t._write(r,n,e.onwrite),e.sync=!1);return s&&!e.errored&&!e.destroyed}(e,o,r,n,i))}function I(t,e,r,n,i,o,s){e.writelen=n,e.writecb=s,e.writing=!0,e.sync=!0,e.destroyed?e.onwrite(new w("write")):r?t._writev(i,e.onwrite):t._write(i,o,e.onwrite),e.sync=!1}function P(t,e,r,n){--e.pendingcb,n(r),F(e),T(t,r)}function D(e,r){const n=e._writableState,i=n.sync,o=n.writecb;"function"==typeof o?(n.writing=!1,n.writecb=null,n.length-=n.writelen,n.writelen=0,r?(r.stack,n.errored||(n.errored=r),e._readableState&&!e._readableState.errored&&(e._readableState.errored=r),i?t.nextTick(P,e,n,r,o):P(e,n,r,o)):(n.buffered.length>n.bufferedIndex&&B(e,n),i?null!==n.afterWriteTickInfo&&n.afterWriteTickInfo.cb===o?n.afterWriteTickInfo.count++:(n.afterWriteTickInfo={count:1,cb:o,stream:e,state:n},t.nextTick(C,n.afterWriteTickInfo)):N(e,n,1,o))):T(e,new _)}function C({stream:t,state:e,count:r,cb:n}){return e.afterWriteTickInfo=null,N(t,e,r,n)}function N(t,e,r,n){for(!e.ending&&!t.destroyed&&0===e.length&&e.needDrain&&(e.needDrain=!1,t.emit("drain"));r-- >0;)e.pendingcb--,n();e.destroyed&&F(e),z(t,e)}function F(t){if(t.writing)return;for(let r=t.bufferedIndex;r<t.buffered.length;++r){var e;const{chunk:n,callback:i}=t.buffered[r],o=t.objectMode?1:n.length;t.length-=o,i(null!==(e=t.errored)&&void 0!==e?e:new w("write"))}const r=t[A].splice(0);for(let e=0;e<r.length;e++){var n;r[e](null!==(n=t.errored)&&void 0!==n?n:new w("end"))}L(t)}function B(t,r){if(r.corked||r.bufferProcessing||r.destroyed||!r.constructed)return;const{buffered:n,bufferedIndex:i,objectMode:o}=r,s=n.length-i;if(!s)return;let a=i;if(r.bufferProcessing=!0,s>1&&t._writev){r.pendingcb-=s-1;const i=r.allNoop?x:t=>{for(let e=a;e<n.length;++e)n[e].callback(t)},o=r.allNoop&&0===a?n:e(n,a);o.allBuffers=r.allBuffers,I(t,r,!0,r.length,o,"",i),L(r)}else{do{const{chunk:e,encoding:i,callback:s}=n[a];n[a++]=null;I(t,r,!1,o?1:e.length,e,i,s)}while(a<n.length&&!r.writing);a===n.length?L(r):a>256?(n.splice(0,a),r.bufferedIndex=0):r.bufferedIndex=a}r.bufferProcessing=!1}function W(t){return t.ending&&!t.destroyed&&t.constructed&&0===t.length&&!t.errored&&0===t.buffered.length&&!t.finished&&!t.writing&&!t.errorEmitted&&!t.closeEmitted}function U(e,r){r.prefinished||r.finalCalled||("function"!=typeof e._final||r.destroyed?(r.prefinished=!0,e.emit("prefinish")):(r.finalCalled=!0,function(e,r){let n=!1;function i(i){if(n)T(e,null!=i?i:_());else if(n=!0,r.pendingcb--,i){const t=r[A].splice(0);for(let e=0;e<t.length;e++)t[e](i);T(e,i,r.sync)}else W(r)&&(r.prefinished=!0,e.emit("prefinish"),r.pendingcb++,t.nextTick($,e,r))}r.sync=!0,r.pendingcb++;try{e._final(i)}catch(t){i(t)}r.sync=!1}(e,r)))}function z(e,r,n){W(r)&&(U(e,r),0===r.pendingcb&&(n?(r.pendingcb++,t.nextTick((t,e)=>{W(e)?$(t,e):e.pendingcb--},e,r)):W(r)&&(r.pendingcb++,$(e,r))))}function $(t,e){e.pendingcb--,e.finished=!0;const r=e[A].splice(0);for(let t=0;t<r.length;t++)r[t]();if(t.emit("finish"),e.autoDestroy){const e=t._readableState;(!e||e.autoDestroy&&(e.endEmitted||!1===e.readable))&&t.destroy()}}O.prototype.getBuffer=function(){return e(this.buffered,this.bufferedIndex)},i(O.prototype,"bufferedRequestCount",{__proto__:null,get(){return this.buffered.length-this.bufferedIndex}}),i(j,u,{__proto__:null,value:function(t){return!!n(this,t)||this===j&&(t&&t._writableState instanceof O)}}),j.prototype.pipe=function(){T(this,new v)},j.prototype.write=function(t,e,r){return!0===M(this,t,e,r)},j.prototype.cork=function(){this._writableState.corked++},j.prototype.uncork=function(){const t=this._writableState;t.corked&&(t.corked--,t.writing||B(this,t))},j.prototype.setDefaultEncoding=function(t){if("string"==typeof t&&(t=a(t)),!f.isEncoding(t))throw new k(t);return this._writableState.defaultEncoding=t,this},j.prototype._write=function(t,e,r){if(!this._writev)throw new m("_write()");this._writev([{chunk:t,encoding:e}],r)},j.prototype._writev=null,j.prototype.end=function(e,n,i){const o=this._writableState;let s;if("function"==typeof e?(i=e,e=null,n=null):"function"==typeof n&&(i=n,n=null),null!=e){const t=M(this,e,n);t instanceof r&&(s=t)}return o.corked&&(o.corked=1,this.uncork()),s||(o.errored||o.ending?o.finished?s=new S("end"):o.destroyed&&(s=new w("end")):(o.ending=!0,z(this,o,!0),o.ended=!0)),"function"==typeof i&&(s||o.finished?t.nextTick(i,s):o[A].push(i)),this},o(j.prototype,{closed:{__proto__:null,get(){return!!this._writableState&&this._writableState.closed}},destroyed:{__proto__:null,get(){return!!this._writableState&&this._writableState.destroyed},set(t){this._writableState&&(this._writableState.destroyed=t)}},writable:{__proto__:null,get(){const t=this._writableState;return!(!t||!1===t.writable||t.destroyed||t.errored||t.ending||t.ended)},set(t){this._writableState&&(this._writableState.writable=!!t)}},writableFinished:{__proto__:null,get(){return!!this._writableState&&this._writableState.finished}},writableObjectMode:{__proto__:null,get(){return!!this._writableState&&this._writableState.objectMode}},writableBuffer:{__proto__:null,get(){return this._writableState&&this._writableState.getBuffer()}},writableEnded:{__proto__:null,get(){return!!this._writableState&&this._writableState.ending}},writableNeedDrain:{__proto__:null,get(){const t=this._writableState;return!!t&&(!t.destroyed&&!t.ending&&t.needDrain)}},writableHighWaterMark:{__proto__:null,get(){return this._writableState&&this._writableState.highWaterMark}},writableCorked:{__proto__:null,get(){return this._writableState?this._writableState.corked:0}},writableLength:{__proto__:null,get(){return this._writableState&&this._writableState.length}},errored:{__proto__:null,enumerable:!1,get(){return this._writableState?this._writableState.errored:null}},writableAborted:{__proto__:null,enumerable:!1,get:function(){return!(!1===this._writableState.writable||!this._writableState.destroyed&&!this._writableState.errored||this._writableState.finished)}}});const H=d.destroy;let G;function q(){return void 0===G&&(G={}),G}return j.prototype.destroy=function(e,r){const n=this._writableState;return!n.destroyed&&(n.bufferedIndex<n.buffered.length||n[A].length)&&t.nextTick(F,n),H.call(this,e,r),this},j.prototype._undestroy=d.undestroy,j.prototype._destroy=function(t,e){e(t)},j.prototype[c.captureRejectionSymbol]=function(t){this.destroy(t)},j.fromWeb=function(t,e){return q().newStreamWritableFromWritableStream(t,e)},j.toWeb=function(t){return q().newWritableStreamFromStreamWritable(t)},pj}function Ej(){if(bj)return gj;bj=1;const t=of,e=ca,{isReadable:r,isWritable:n,isIterable:i,isNodeStream:o,isReadableNodeStream:s,isWritableNodeStream:a,isDuplexNodeStream:l,isReadableStream:u,isWritableStream:c}=SO,h=tL,{AbortError:f,codes:{ERR_INVALID_ARG_TYPE:d,ERR_INVALID_RETURN_VALUE:p}}=sA,{destroyer:y}=EL,g=Rj(),b=wj(),m=Sj(),{createDeferredPromise:_}=aA,v=vj,w=globalThis.Blob||e.Blob,S=void 0!==w?function(t){return t instanceof w}:function(t){return!1},E=globalThis.AbortController||Kc().AbortController,{FunctionPrototypeCall:R}=Hx;class k extends g{constructor(t){super(t),!1===(null==t?void 0:t.readable)&&(this._readableState.readable=!1,this._readableState.ended=!0,this._readableState.endEmitted=!0),!1===(null==t?void 0:t.writable)&&(this._writableState.writable=!1,this._writableState.ending=!0,this._writableState.ended=!0,this._writableState.finished=!0)}}function T(t){const e=t.readable&&"function"!=typeof t.readable.read?b.wrap(t.readable):t.readable,i=t.writable;let o,s,a,l,u,c=!!r(e),d=!!n(i);function p(t){const e=l;l=null,e?e(t):t&&u.destroy(t)}return u=new k({readableObjectMode:!(null==e||!e.readableObjectMode),writableObjectMode:!(null==i||!i.writableObjectMode),readable:c,writable:d}),d&&(h(i,t=>{d=!1,t&&y(e,t),p(t)}),u._write=function(t,e,r){i.write(t,e)?r():o=r},u._final=function(t){i.end(),s=t},i.on("drain",function(){if(o){const t=o;o=null,t()}}),i.on("finish",function(){if(s){const t=s;s=null,t()}})),c&&(h(e,t=>{c=!1,t&&y(e,t),p(t)}),e.on("readable",function(){if(a){const t=a;a=null,t()}}),e.on("end",function(){u.push(null)}),u._read=function(){for(;;){const t=e.read();if(null===t)return void(a=u._read);if(!u.push(t))return}}),u._destroy=function(t,r){t||null===l||(t=new f),a=null,o=null,s=null,null===l?r(t):(l=r,y(i,t),y(e,t))},u}return gj=function e(r,n){if(l(r))return r;if(s(r))return T({readable:r});if(a(r))return T({writable:r});if(o(r))return T({writable:!1,readable:!1});if(u(r))return T({readable:b.fromWeb(r)});if(c(r))return T({writable:m.fromWeb(r)});if("function"==typeof r){const{value:e,write:o,final:s,destroy:a}=function(e){let{promise:r,resolve:n}=_();const i=new E,o=i.signal,s=e(async function*(){for(;;){const e=r;r=null;const{chunk:i,done:s,cb:a}=await e;if(t.nextTick(a),s)return;if(o.aborted)throw new f(void 0,{cause:o.reason});({promise:r,resolve:n}=_()),yield i}}(),{signal:o});return{value:s,write(t,e,r){const i=n;n=null,i({chunk:t,done:!1,cb:r})},final(t){const e=n;n=null,e({done:!0,cb:t})},destroy(t,e){i.abort(),e(t)}}}(r);if(i(e))return v(k,e,{objectMode:!0,write:o,final:s,destroy:a});const l=null==e?void 0:e.then;if("function"==typeof l){let r;const n=R(l,e,t=>{if(null!=t)throw new p("nully","body",t)},t=>{y(r,t)});return r=new k({objectMode:!0,readable:!1,write:o,final(e){s(async()=>{try{await n,t.nextTick(e,null)}catch(r){t.nextTick(e,r)}})},destroy:a})}throw new p("Iterable, AsyncIterable or AsyncFunction",n,e)}if(S(r))return e(r.arrayBuffer());if(i(r))return v(k,r,{objectMode:!0,writable:!1});if(u(null==r?void 0:r.readable)&&c(null==r?void 0:r.writable))return k.fromWeb(r);if("object"==typeof(null==r?void 0:r.writable)||"object"==typeof(null==r?void 0:r.readable)){return T({readable:null!=r&&r.readable?s(null==r?void 0:r.readable)?null==r?void 0:r.readable:e(r.readable):void 0,writable:null!=r&&r.writable?a(null==r?void 0:r.writable)?null==r?void 0:r.writable:e(r.writable):void 0})}const h=null==r?void 0:r.then;if("function"==typeof h){let t;return R(h,r,e=>{null!=e&&t.push(e),t.push(null)},e=>{y(t,e)}),t=new k({objectMode:!0,writable:!1,read(){}})}throw new d(n,["Blob","ReadableStream","WritableStream","Stream","Iterable","AsyncIterable","Function","{ readable, writable } pair","Promise"],r)},gj}function Rj(){if(_j)return mj;_j=1;const{ObjectDefineProperties:t,ObjectGetOwnPropertyDescriptor:e,ObjectKeys:r,ObjectSetPrototypeOf:n}=Hx;mj=s;const i=wj(),o=Sj();n(s.prototype,i.prototype),n(s,i);{const t=r(o.prototype);for(let e=0;e<t.length;e++){const r=t[e];s.prototype[r]||(s.prototype[r]=o.prototype[r])}}function s(t){if(!(this instanceof s))return new s(t);i.call(this,t),o.call(this,t),t?(this.allowHalfOpen=!1!==t.allowHalfOpen,!1===t.readable&&(this._readableState.readable=!1,this._readableState.ended=!0,this._readableState.endEmitted=!0),!1===t.writable&&(this._writableState.writable=!1,this._writableState.ending=!0,this._writableState.ended=!0,this._writableState.finished=!0)):this.allowHalfOpen=!0}let a,l;function u(){return void 0===a&&(a={}),a}return t(s.prototype,{writable:{__proto__:null,...e(o.prototype,"writable")},writableHighWaterMark:{__proto__:null,...e(o.prototype,"writableHighWaterMark")},writableObjectMode:{__proto__:null,...e(o.prototype,"writableObjectMode")},writableBuffer:{__proto__:null,...e(o.prototype,"writableBuffer")},writableLength:{__proto__:null,...e(o.prototype,"writableLength")},writableFinished:{__proto__:null,...e(o.prototype,"writableFinished")},writableCorked:{__proto__:null,...e(o.prototype,"writableCorked")},writableEnded:{__proto__:null,...e(o.prototype,"writableEnded")},writableNeedDrain:{__proto__:null,...e(o.prototype,"writableNeedDrain")},destroyed:{__proto__:null,get(){return void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed&&this._writableState.destroyed)},set(t){this._readableState&&this._writableState&&(this._readableState.destroyed=t,this._writableState.destroyed=t)}}}),s.fromWeb=function(t,e){return u().newStreamDuplexFromReadableWritablePair(t,e)},s.toWeb=function(t){return u().newReadableWritablePairFromDuplex(t)},s.from=function(t){return l||(l=Ej()),l(t,"body")},mj}const{ObjectSetPrototypeOf:kj,Symbol:Tj}=Hx;var xj=Mj;const{ERR_METHOD_NOT_IMPLEMENTED:Aj}=sA.codes,Oj=Rj(),{getHighWaterMark:Lj}=qL;kj(Mj.prototype,Oj.prototype),kj(Mj,Oj);const jj=Tj("kCallback");function Mj(t){if(!(this instanceof Mj))return new Mj(t);const e=t?Lj(this,t,"readableHighWaterMark",!0):null;0===e&&(t={...t,highWaterMark:null,readableHighWaterMark:e,writableHighWaterMark:t.writableHighWaterMark||0}),Oj.call(this,t),this._readableState.sync=!1,this[jj]=null,t&&("function"==typeof t.transform&&(this._transform=t.transform),"function"==typeof t.flush&&(this._flush=t.flush)),this.on("prefinish",Pj)}function Ij(t){"function"!=typeof this._flush||this.destroyed?(this.push(null),t&&t()):this._flush((e,r)=>{e?t?t(e):this.destroy(e):(null!=r&&this.push(r),this.push(null),t&&t())})}function Pj(){this._final!==Ij&&Ij.call(this)}Mj.prototype._final=Ij,Mj.prototype._transform=function(t,e,r){throw new Aj("_transform()")},Mj.prototype._write=function(t,e,r){const n=this._readableState,i=this._writableState,o=n.length;this._transform(t,e,(t,e)=>{t?r(t):(null!=e&&this.push(e),i.ended||o===n.length||n.length<n.highWaterMark?r():this[jj]=r)})},Mj.prototype._read=function(){if(this[jj]){const t=this[jj];this[jj]=null,t()}};const{ObjectSetPrototypeOf:Dj}=Hx;var Cj=Fj;const Nj=xj;function Fj(t){if(!(this instanceof Fj))return new Fj(t);Nj.call(this,t)}Dj(Fj.prototype,Nj.prototype),Dj(Fj,Nj),Fj.prototype._transform=function(t,e,r){r(null,t)};const Bj=of,{ArrayIsArray:Wj,Promise:Uj,SymbolAsyncIterator:zj,SymbolDispose:$j}=Hx,Hj=tL,{once:Gj}=aA,qj=EL,Vj=Rj(),{aggregateTwoErrors:Zj,codes:{ERR_INVALID_ARG_TYPE:Yj,ERR_INVALID_RETURN_VALUE:Kj,ERR_MISSING_ARGS:Qj,ERR_STREAM_DESTROYED:Jj,ERR_STREAM_PREMATURE_CLOSE:Xj},AbortError:tM}=sA,{validateFunction:eM,validateAbortSignal:rM}=QA,{isIterable:nM,isReadable:iM,isReadableNodeStream:oM,isNodeStream:sM,isTransformStream:aM,isWebStream:lM,isReadableStream:uM,isReadableFinished:cM}=SO,hM=globalThis.AbortController||Kc().AbortController;let fM,dM,pM;function yM(t,e,r){let n=!1;t.on("close",()=>{n=!0});return{destroy:e=>{n||(n=!0,qj.destroyer(t,e||new Jj("pipe")))},cleanup:Hj(t,{readable:e,writable:r},t=>{n=!t})}}function gM(t){if(nM(t))return t;if(oM(t))return async function*(t){dM||(dM=wj());yield*dM.prototype[zj].call(t)}(t);throw new Yj("val",["Readable","Iterable","AsyncIterable"],t)}async function bM(t,e,r,{end:n}){let i,o=null;const s=t=>{if(t&&(i=t),o){const t=o;o=null,t()}},a=()=>new Uj((t,e)=>{i?e(i):o=()=>{i?e(i):t()}});e.on("drain",s);const l=Hj(e,{readable:!1},s);try{e.writableNeedDrain&&await a();for await(const r of t)e.write(r)||await a();n&&(e.end(),await a()),r()}catch(t){r(i!==t?Zj(i,t):t)}finally{l(),e.off("drain",s)}}async function mM(t,e,r,{end:n}){aM(e)&&(e=e.writable);const i=e.getWriter();try{for await(const e of t)await i.ready,i.write(e).catch(()=>{});await i.ready,n&&await i.close(),r()}catch(t){try{await i.abort(t),r(t)}catch(t){r(t)}}}function _M(t,e,r){if(1===t.length&&Wj(t[0])&&(t=t[0]),t.length<2)throw new Qj("streams");const n=new hM,i=n.signal,o=null==r?void 0:r.signal,s=[];function a(){y(new tM)}let l,u,c;rM(o,"options.signal"),pM=pM||aA.addAbortListener,o&&(l=pM(o,a));const h=[];let f,d=0;function p(t){y(t,0===--d)}function y(t,r){var i;if(!t||u&&"ERR_STREAM_PREMATURE_CLOSE"!==u.code||(u=t),u||r){for(;h.length;)h.shift()(u);null===(i=l)||void 0===i||i[$j](),n.abort(),r&&(u||s.forEach(t=>t()),Bj.nextTick(e,u,c))}}for(let m=0;m<t.length;m++){const _=t[m],v=m<t.length-1,w=m>0,S=v||!1!==(null==r?void 0:r.end),E=m===t.length-1;if(sM(_)){if(S){const{destroy:k,cleanup:T}=yM(_,v,w);h.push(k),iM(_)&&E&&s.push(T)}function R(t){t&&"AbortError"!==t.name&&"ERR_STREAM_PREMATURE_CLOSE"!==t.code&&p(t)}_.on("error",R),iM(_)&&E&&s.push(()=>{_.removeListener("error",R)})}if(0===m)if("function"==typeof _){if(f=_({signal:i}),!nM(f))throw new Kj("Iterable, AsyncIterable or Stream","source",f)}else f=nM(_)||oM(_)||aM(_)?_:Vj.from(_);else if("function"==typeof _){var g;if(aM(f))f=gM(null===(g=f)||void 0===g?void 0:g.readable);else f=gM(f);if(f=_(f,{signal:i}),v){if(!nM(f,!0))throw new Kj("AsyncIterable",`transform[${m-1}]`,f)}else{var b;fM||(fM=Cj);const x=new fM({objectMode:!0}),A=null===(b=f)||void 0===b?void 0:b.then;if("function"==typeof A)d++,A.call(f,t=>{c=t,null!=t&&x.write(t),S&&x.end(),Bj.nextTick(p)},t=>{x.destroy(t),Bj.nextTick(p,t)});else if(nM(f,!0))d++,bM(f,x,p,{end:S});else{if(!uM(f)&&!aM(f))throw new Kj("AsyncIterable or Promise","destination",f);{const j=f.readable||f;d++,bM(j,x,p,{end:S})}}f=x;const{destroy:O,cleanup:L}=yM(f,!1,!0);h.push(O),E&&s.push(L)}}else if(sM(_)){if(oM(f)){d+=2;const M=vM(f,_,p,{end:S});iM(_)&&E&&s.push(M)}else if(aM(f)||uM(f)){const I=f.readable||f;d++,bM(I,_,p,{end:S})}else{if(!nM(f))throw new Yj("val",["Readable","Iterable","AsyncIterable","ReadableStream","TransformStream"],f);d++,bM(f,_,p,{end:S})}f=_}else if(lM(_)){if(oM(f))d++,mM(gM(f),_,p,{end:S});else if(uM(f)||nM(f))d++,mM(f,_,p,{end:S});else{if(!aM(f))throw new Yj("val",["Readable","Iterable","AsyncIterable","ReadableStream","TransformStream"],f);d++,mM(f.readable,_,p,{end:S})}f=_}else f=Vj.from(_)}return(null!=i&&i.aborted||null!=o&&o.aborted)&&Bj.nextTick(a),f}function vM(t,e,r,{end:n}){let i=!1;if(e.on("close",()=>{i||r(new Xj)}),t.pipe(e,{end:!1}),n){function o(){i=!0,e.end()}cM(t)?Bj.nextTick(o):t.once("end",o)}else r();return Hj(t,{readable:!0,writable:!1},e=>{const n=t._readableState;e&&"ERR_STREAM_PREMATURE_CLOSE"===e.code&&n&&n.ended&&!n.errored&&!n.errorEmitted?t.once("end",r).once("error",r):r(e)}),Hj(e,{readable:!1,writable:!0},r)}var wM={pipelineImpl:_M,pipeline:function(...t){return _M(t,Gj(function(t){return eM(t[t.length-1],"streams[stream.length - 1]"),t.pop()}(t)))}};const{pipeline:SM}=wM,EM=Rj(),{destroyer:RM}=EL,{isNodeStream:kM,isReadable:TM,isWritable:xM,isWebStream:AM,isTransformStream:OM,isWritableStream:LM,isReadableStream:jM}=SO,{AbortError:MM,codes:{ERR_INVALID_ARG_VALUE:IM,ERR_MISSING_ARGS:PM}}=sA,DM=tL;var CM=function(...t){if(0===t.length)throw new PM("streams");if(1===t.length)return EM.from(t[0]);const e=[...t];if("function"==typeof t[0]&&(t[0]=EM.from(t[0])),"function"==typeof t[t.length-1]){const e=t.length-1;t[e]=EM.from(t[e])}for(let r=0;r<t.length;++r)if(kM(t[r])||AM(t[r])){if(r<t.length-1&&!(TM(t[r])||jM(t[r])||OM(t[r])))throw new IM(`streams[${r}]`,e[r],"must be readable");if(r>0&&!(xM(t[r])||LM(t[r])||OM(t[r])))throw new IM(`streams[${r}]`,e[r],"must be writable")}let r,n,i,o,s;const a=t[0],l=SM(t,function(t){const e=o;o=null,e?e(t):t?s.destroy(t):c||u||s.destroy()}),u=!!(xM(a)||LM(a)||OM(a)),c=!!(TM(l)||jM(l)||OM(l));if(s=new EM({writableObjectMode:!(null==a||!a.writableObjectMode),readableObjectMode:!(null==l||!l.readableObjectMode),writable:u,readable:c}),u){if(kM(a))s._write=function(t,e,n){a.write(t,e)?n():r=n},s._final=function(t){a.end(),n=t},a.on("drain",function(){if(r){const t=r;r=null,t()}});else if(AM(a)){const t=(OM(a)?a.writable:a).getWriter();s._write=async function(e,r,n){try{await t.ready,t.write(e).catch(()=>{}),n()}catch(t){n(t)}},s._final=async function(e){try{await t.ready,t.close().catch(()=>{}),n=e}catch(t){e(t)}}}const t=OM(l)?l.readable:l;DM(t,()=>{if(n){const t=n;n=null,t()}})}if(c)if(kM(l))l.on("readable",function(){if(i){const t=i;i=null,t()}}),l.on("end",function(){s.push(null)}),s._read=function(){for(;;){const t=l.read();if(null===t)return void(i=s._read);if(!s.push(t))return}};else if(AM(l)){const t=(OM(l)?l.readable:l).getReader();s._read=async function(){for(;;)try{const{value:e,done:r}=await t.read();if(!s.push(e))return;if(r)return void s.push(null)}catch{return}}}return s._destroy=function(t,e){t||null===o||(t=new MM),i=null,r=null,n=null,null===o?e(t):(o=e,kM(l)&&RM(l,t))},s};const NM=globalThis.AbortController||Kc().AbortController,{codes:{ERR_INVALID_ARG_VALUE:FM,ERR_INVALID_ARG_TYPE:BM,ERR_MISSING_ARGS:WM,ERR_OUT_OF_RANGE:UM},AbortError:zM}=sA,{validateAbortSignal:$M,validateInteger:HM,validateObject:GM}=QA,qM=Hx.Symbol("kWeak"),VM=Hx.Symbol("kResistStopPropagation"),{finished:ZM}=tL,YM=CM,{addAbortSignalNoValidate:KM}=jL,{isWritable:QM,isNodeStream:JM}=SO,{deprecate:XM}=aA,{ArrayPrototypePush:tI,Boolean:eI,MathFloor:rI,Number:nI,NumberIsNaN:iI,Promise:oI,PromiseReject:sI,PromiseResolve:aI,PromisePrototypeThen:lI,Symbol:uI}=Hx,cI=uI("kEmpty"),hI=uI("kEof");function fI(t,e){if("function"!=typeof t)throw new BM("fn",["Function","AsyncFunction"],t);null!=e&&GM(e,"options"),null!=(null==e?void 0:e.signal)&&$M(e.signal,"options.signal");let r=1;null!=(null==e?void 0:e.concurrency)&&(r=rI(e.concurrency));let n=r-1;return null!=(null==e?void 0:e.highWaterMark)&&(n=rI(e.highWaterMark)),HM(r,"options.concurrency",1),HM(n,"options.highWaterMark",0),n+=r,async function*(){const i=aA.AbortSignalAny([null==e?void 0:e.signal].filter(eI)),o=this,s=[],a={signal:i};let l,u,c=!1,h=0;function f(){c=!0,d()}function d(){h-=1,p()}function p(){u&&!c&&h<r&&s.length<n&&(u(),u=null)}!async function(){try{for await(let e of o){if(c)return;if(i.aborted)throw new zM;try{if(e=t(e,a),e===cI)continue;e=aI(e)}catch(t){e=sI(t)}h+=1,lI(e,d,f),s.push(e),l&&(l(),l=null),!c&&(s.length>=n||h>=r)&&await new oI(t=>{u=t})}s.push(hI)}catch(t){const e=sI(t);lI(e,d,f),s.push(e)}finally{c=!0,l&&(l(),l=null)}}();try{for(;;){for(;s.length>0;){const t=await s[0];if(t===hI)return;if(i.aborted)throw new zM;t!==cI&&(yield t),s.shift(),p()}await new oI(t=>{l=t})}}finally{c=!0,u&&(u(),u=null)}}.call(this)}async function dI(t,e=void 0){for await(const r of pI.call(this,t,e))return!0;return!1}function pI(t,e){if("function"!=typeof t)throw new BM("fn",["Function","AsyncFunction"],t);return fI.call(this,async function(e,r){return await t(e,r)?e:cI},e)}class yI extends WM{constructor(){super("reduce"),this.message="Reduce of an empty stream requires an initial value"}}function gI(t){if(t=nI(t),iI(t))return 0;if(t<0)throw new UM("number",">= 0",t);return t}var bI,mI,_I;function vI(){if(mI)return bI;mI=1;const{ArrayPrototypePop:t,Promise:e}=Hx,{isIterable:r,isNodeStream:n,isWebStream:i}=SO,{pipelineImpl:o}=wM,{finished:s}=tL;return wI(),bI={finished:s,pipeline:function(...s){return new e((e,a)=>{let l,u;const c=s[s.length-1];if(c&&"object"==typeof c&&!n(c)&&!r(c)&&!i(c)){const e=t(s);l=e.signal,u=e.end}o(s,(t,r)=>{t?a(t):e(r)},{signal:l,end:u})})}},bI}function wI(){if(_I)return zx.exports;_I=1;const{Buffer:t}=ca,{ObjectDefineProperty:e,ObjectKeys:r,ReflectApply:n}=Hx,{promisify:{custom:i}}=aA,{streamReturningOperators:o,promiseReturningOperators:s}=lA,{codes:{ERR_ILLEGAL_CONSTRUCTOR:a}}=sA,l=CM,{setDefaultHighWaterMark:u,getDefaultHighWaterMark:c}=qL,{pipeline:h}=wM,{destroyer:f}=EL,d=tL,p=vI(),y=SO,g=zx.exports=OL.Stream;g.isDestroyed=y.isDestroyed,g.isDisturbed=y.isDisturbed,g.isErrored=y.isErrored,g.isReadable=y.isReadable,g.isWritable=y.isWritable,g.Readable=wj();for(const m of r(o)){const _=o[m];function v(...t){if(new.target)throw a();return g.Readable.from(n(_,this,t))}e(v,"name",{__proto__:null,value:_.name}),e(v,"length",{__proto__:null,value:_.length}),e(g.Readable.prototype,m,{__proto__:null,value:v,enumerable:!1,configurable:!0,writable:!0})}for(const w of r(s)){const S=s[w];function E(...t){if(new.target)throw a();return n(S,this,t)}e(E,"name",{__proto__:null,value:S.name}),e(E,"length",{__proto__:null,value:S.length}),e(g.Readable.prototype,w,{__proto__:null,value:E,enumerable:!1,configurable:!0,writable:!0})}g.Writable=Sj(),g.Duplex=Rj(),g.Transform=xj,g.PassThrough=Cj,g.pipeline=h;const{addAbortSignal:b}=jL;return g.addAbortSignal=b,g.finished=d,g.destroy=f,g.compose=l,g.setDefaultHighWaterMark=u,g.getDefaultHighWaterMark=c,e(g,"promises",{__proto__:null,configurable:!0,enumerable:!0,get:()=>p}),e(h,i,{__proto__:null,enumerable:!0,get:()=>p.pipeline}),e(d,i,{__proto__:null,enumerable:!0,get:()=>p.finished}),g.Stream=g,g._isUint8Array=function(t){return t instanceof Uint8Array},g._uint8ArrayToBuffer=function(e){return t.from(e.buffer,e.byteOffset,e.byteLength)},zx.exports}lA.streamReturningOperators={asIndexedPairs:XM(function(t=void 0){return null!=t&&GM(t,"options"),null!=(null==t?void 0:t.signal)&&$M(t.signal,"options.signal"),async function*(){let e=0;for await(const n of this){var r;if(null!=t&&null!==(r=t.signal)&&void 0!==r&&r.aborted)throw new zM({cause:t.signal.reason});yield[e++,n]}}.call(this)},"readable.asIndexedPairs will be removed in a future version."),drop:function(t,e=void 0){return null!=e&&GM(e,"options"),null!=(null==e?void 0:e.signal)&&$M(e.signal,"options.signal"),t=gI(t),async function*(){var r;if(null!=e&&null!==(r=e.signal)&&void 0!==r&&r.aborted)throw new zM;for await(const r of this){var n;if(null!=e&&null!==(n=e.signal)&&void 0!==n&&n.aborted)throw new zM;t--<=0&&(yield r)}}.call(this)},filter:pI,flatMap:function(t,e){const r=fI.call(this,t,e);return async function*(){for await(const t of r)yield*t}.call(this)},map:fI,take:function(t,e=void 0){return null!=e&&GM(e,"options"),null!=(null==e?void 0:e.signal)&&$M(e.signal,"options.signal"),t=gI(t),async function*(){var r;if(null!=e&&null!==(r=e.signal)&&void 0!==r&&r.aborted)throw new zM;for await(const r of this){var n;if(null!=e&&null!==(n=e.signal)&&void 0!==n&&n.aborted)throw new zM;if(t-- >0&&(yield r),t<=0)return}}.call(this)},compose:function(t,e){if(null!=e&&GM(e,"options"),null!=(null==e?void 0:e.signal)&&$M(e.signal,"options.signal"),JM(t)&&!QM(t))throw new FM("stream",t,"must be writable");const r=YM(this,t);return null!=e&&e.signal&&KM(e.signal,r),r}},lA.promiseReturningOperators={every:async function(t,e=void 0){if("function"!=typeof t)throw new BM("fn",["Function","AsyncFunction"],t);return!await dI.call(this,async(...e)=>!await t(...e),e)},forEach:async function(t,e){if("function"!=typeof t)throw new BM("fn",["Function","AsyncFunction"],t);for await(const r of fI.call(this,async function(e,r){return await t(e,r),cI},e));},reduce:async function(t,e,r){var n;if("function"!=typeof t)throw new BM("reducer",["Function","AsyncFunction"],t);null!=r&&GM(r,"options"),null!=(null==r?void 0:r.signal)&&$M(r.signal,"options.signal");let i=arguments.length>1;if(null!=r&&null!==(n=r.signal)&&void 0!==n&&n.aborted){const t=new zM(void 0,{cause:r.signal.reason});throw this.once("error",()=>{}),await ZM(this.destroy(t)),t}const o=new NM,s=o.signal;if(null!=r&&r.signal){const t={once:!0,[qM]:this,[VM]:!0};r.signal.addEventListener("abort",()=>o.abort(),t)}let a=!1;try{for await(const n of this){var l;if(a=!0,null!=r&&null!==(l=r.signal)&&void 0!==l&&l.aborted)throw new zM;i?e=await t(e,n,{signal:s}):(e=n,i=!0)}if(!a&&!i)throw new yI}finally{o.abort()}return e},toArray:async function(t){null!=t&&GM(t,"options"),null!=(null==t?void 0:t.signal)&&$M(t.signal,"options.signal");const e=[];for await(const n of this){var r;if(null!=t&&null!==(r=t.signal)&&void 0!==r&&r.aborted)throw new zM(void 0,{cause:t.signal.reason});tI(e,n)}return e},some:dI,find:async function(t,e){for await(const r of pI.call(this,t,e))return r}},function(t){const e=wI(),r=vI(),n=e.Readable.destroy;t.exports=e.Readable,t.exports._uint8ArrayToBuffer=e._uint8ArrayToBuffer,t.exports._isUint8Array=e._isUint8Array,t.exports.isDisturbed=e.isDisturbed,t.exports.isErrored=e.isErrored,t.exports.isReadable=e.isReadable,t.exports.Readable=e.Readable,t.exports.Writable=e.Writable,t.exports.Duplex=e.Duplex,t.exports.Transform=e.Transform,t.exports.PassThrough=e.PassThrough,t.exports.addAbortSignal=e.addAbortSignal,t.exports.finished=e.finished,t.exports.destroy=e.destroy,t.exports.destroy=n,t.exports.pipeline=e.pipeline,t.exports.compose=e.compose,Object.defineProperty(e,"promises",{configurable:!0,enumerable:!0,get:()=>r}),t.exports.Stream=e.Stream,t.exports.default=t.exports}(Ux);var SI=Ux.exports,EI={exports:{}};i.Stream;var RI=SI.PassThrough,kI=Wx;(EI.exports={}).normalizeInputSource=function(t){if(null===t)return Buffer.alloc(0);if("string"==typeof t)return Buffer.from(t);if(kI(t)&&!t._readableState){var e=new RI;return t.pipe(e),e}return t};var TI=EI.exports,xI=s.inherits,AI=Wx,OI=SI.Transform,LI=_x,jI=TI,MI=Fx.exports=function(t){if(!(this instanceof MI))return new MI(t);OI.call(this,t),this.offset=0,this._archive={finish:!1,finished:!1,processing:!1}};xI(MI,OI),MI.prototype._appendBuffer=function(t,e,r){},MI.prototype._appendStream=function(t,e,r){},MI.prototype._emitErrorCallback=function(t){t&&this.emit("error",t)},MI.prototype._finish=function(t){},MI.prototype._normalizeEntry=function(t){},MI.prototype._transform=function(t,e,r){r(null,t)},MI.prototype.entry=function(t,e,r){if(e=e||null,"function"!=typeof r&&(r=this._emitErrorCallback.bind(this)),t instanceof LI)if(this._archive.finish||this._archive.finished)r(new Error("unacceptable entry after finish"));else{if(!this._archive.processing){if(this._archive.processing=!0,this._normalizeEntry(t),this._entry=t,e=jI.normalizeInputSource(e),Buffer.isBuffer(e))this._appendBuffer(t,e,r);else{if(!AI(e))return this._archive.processing=!1,void r(new Error("input source must be valid Stream or Buffer instance"));this._appendStream(t,e,r)}return this}r(new Error("already processing an entry"))}else r(new Error("not a valid instance of ArchiveEntry"))},MI.prototype.finish=function(){this._archive.processing?this._archive.finish=!0:this._finish()},MI.prototype.getBytesWritten=function(){return this.offset},MI.prototype.write=function(t,e){return t&&(this.offset+=t.length),OI.prototype.write.call(this,t,e)};var II=Fx.exports,PI={exports:{}},DI={};
38
- /*! crc32.js (C) 2014-present SheetJS -- http://sheetjs.com */
39
- !function(t){var e;e=function(t){t.version="1.2.2";var e=function(){for(var t=0,e=new Array(256),r=0;256!=r;++r)t=1&(t=1&(t=1&(t=1&(t=1&(t=1&(t=1&(t=1&(t=r)?-306674912^t>>>1:t>>>1)?-306674912^t>>>1:t>>>1)?-306674912^t>>>1:t>>>1)?-306674912^t>>>1:t>>>1)?-306674912^t>>>1:t>>>1)?-306674912^t>>>1:t>>>1)?-306674912^t>>>1:t>>>1)?-306674912^t>>>1:t>>>1,e[r]=t;return"undefined"!=typeof Int32Array?new Int32Array(e):e}(),r=function(t){var e=0,r=0,n=0,i="undefined"!=typeof Int32Array?new Int32Array(4096):new Array(4096);for(n=0;256!=n;++n)i[n]=t[n];for(n=0;256!=n;++n)for(r=t[n],e=256+n;e<4096;e+=256)r=i[e]=r>>>8^t[255&r];var o=[];for(n=1;16!=n;++n)o[n-1]="undefined"!=typeof Int32Array?i.subarray(256*n,256*n+256):i.slice(256*n,256*n+256);return o}(e),n=r[0],i=r[1],o=r[2],s=r[3],a=r[4],l=r[5],u=r[6],c=r[7],h=r[8],f=r[9],d=r[10],p=r[11],y=r[12],g=r[13],b=r[14];t.table=e,t.bstr=function(t,r){for(var n=-1^r,i=0,o=t.length;i<o;)n=n>>>8^e[255&(n^t.charCodeAt(i++))];return~n},t.buf=function(t,r){for(var m=-1^r,_=t.length-15,v=0;v<_;)m=b[t[v++]^255&m]^g[t[v++]^m>>8&255]^y[t[v++]^m>>16&255]^p[t[v++]^m>>>24]^d[t[v++]]^f[t[v++]]^h[t[v++]]^c[t[v++]]^u[t[v++]]^l[t[v++]]^a[t[v++]]^s[t[v++]]^o[t[v++]]^i[t[v++]]^n[t[v++]]^e[t[v++]];for(_+=15;v<_;)m=m>>>8^e[255&(m^t[v++])];return~m},t.str=function(t,r){for(var n=-1^r,i=0,o=t.length,s=0,a=0;i<o;)(s=t.charCodeAt(i++))<128?n=n>>>8^e[255&(n^s)]:s<2048?n=(n=n>>>8^e[255&(n^(192|s>>6&31))])>>>8^e[255&(n^(128|63&s))]:s>=55296&&s<57344?(s=64+(1023&s),a=1023&t.charCodeAt(i++),n=(n=(n=(n=n>>>8^e[255&(n^(240|s>>8&7))])>>>8^e[255&(n^(128|s>>2&63))])>>>8^e[255&(n^(128|a>>6&15|(3&s)<<4))])>>>8^e[255&(n^(128|63&a))]):n=(n=(n=n>>>8^e[255&(n^(224|s>>12&15))])>>>8^e[255&(n^(128|s>>6&63))])>>>8^e[255&(n^(128|63&s))];return~n}},"undefined"==typeof DO_NOT_EXPORT_CRC?e(t):e({})}(DI);const{Transform:CI}=SI,NI=DI;var FI=class extends CI{constructor(t){super(t),this.checksum=Buffer.allocUnsafe(4),this.checksum.writeInt32BE(0,0),this.rawSize=0}_transform(t,e,r){t&&(this.checksum=NI.buf(t,this.checksum)>>>0,this.rawSize+=t.length),r(null,t)}digest(t){const e=Buffer.allocUnsafe(4);return e.writeUInt32BE(this.checksum>>>0,0),t?e.toString(t):e}hex(){return this.digest("hex").toUpperCase()}size(){return this.rawSize}};const{DeflateRaw:BI}=y,WI=DI;var UI={CRC32Stream:FI,DeflateCRC32Stream:class extends BI{constructor(t){super(t),this.checksum=Buffer.allocUnsafe(4),this.checksum.writeInt32BE(0,0),this.rawSize=0,this.compressedSize=0}push(t,e){return t&&(this.compressedSize+=t.length),super.push(t,e)}_transform(t,e,r){t&&(this.checksum=WI.buf(t,this.checksum)>>>0,this.rawSize+=t.length),super._transform(t,e,r)}digest(t){const e=Buffer.allocUnsafe(4);return e.writeUInt32BE(this.checksum>>>0,0),t?e.toString(t):e}hex(){return this.digest("hex").toUpperCase()}size(t=!1){return t?this.compressedSize:this.rawSize}}},zI=s.inherits,$I=DI,{CRC32Stream:HI}=UI,{DeflateCRC32Stream:GI}=UI,qI=II,VI=Ax,ZI=Rx,YI=PI.exports=function(t){if(!(this instanceof YI))return new YI(t);t=this.options=this._defaults(t),qI.call(this,t),this._entry=null,this._entries=[],this._archive={centralLength:0,centralOffset:0,comment:"",finish:!1,finished:!1,processing:!1,forceZip64:t.forceZip64,forceLocalTime:t.forceLocalTime}};zI(YI,qI),YI.prototype._afterAppend=function(t){this._entries.push(t),t.getGeneralPurposeBit().usesDataDescriptor()&&this._writeDataDescriptor(t),this._archive.processing=!1,this._entry=null,this._archive.finish&&!this._archive.finished&&this._finish()},YI.prototype._appendBuffer=function(t,e,r){0===e.length&&t.setMethod(VI.METHOD_STORED);var n=t.getMethod();return n===VI.METHOD_STORED&&(t.setSize(e.length),t.setCompressedSize(e.length),t.setCrc($I.buf(e)>>>0)),this._writeLocalFileHeader(t),n===VI.METHOD_STORED?(this.write(e),this._afterAppend(t),void r(null,t)):n===VI.METHOD_DEFLATED?void this._smartStream(t,r).end(e):void r(new Error("compression method "+n+" not implemented"))},YI.prototype._appendStream=function(t,e,r){t.getGeneralPurposeBit().useDataDescriptor(!0),t.setVersionNeededToExtract(VI.MIN_VERSION_DATA_DESCRIPTOR),this._writeLocalFileHeader(t);var n=this._smartStream(t,r);e.once("error",function(t){n.emit("error",t),n.end()}),e.pipe(n)},YI.prototype._defaults=function(t){return"object"!=typeof t&&(t={}),"object"!=typeof t.zlib&&(t.zlib={}),"number"!=typeof t.zlib.level&&(t.zlib.level=VI.ZLIB_BEST_SPEED),t.forceZip64=!!t.forceZip64,t.forceLocalTime=!!t.forceLocalTime,t},YI.prototype._finish=function(){this._archive.centralOffset=this.offset,this._entries.forEach(function(t){this._writeCentralFileHeader(t)}.bind(this)),this._archive.centralLength=this.offset-this._archive.centralOffset,this.isZip64()&&this._writeCentralDirectoryZip64(),this._writeCentralDirectoryEnd(),this._archive.processing=!1,this._archive.finish=!0,this._archive.finished=!0,this.end()},YI.prototype._normalizeEntry=function(t){-1===t.getMethod()&&t.setMethod(VI.METHOD_DEFLATED),t.getMethod()===VI.METHOD_DEFLATED&&(t.getGeneralPurposeBit().useDataDescriptor(!0),t.setVersionNeededToExtract(VI.MIN_VERSION_DATA_DESCRIPTOR)),-1===t.getTime()&&t.setTime(new Date,this._archive.forceLocalTime),t._offsets={file:0,data:0,contents:0}},YI.prototype._smartStream=function(t,e){var r=t.getMethod()===VI.METHOD_DEFLATED?new GI(this.options.zlib):new HI,n=null;return r.once("end",function(){var i=r.digest().readUInt32BE(0);t.setCrc(i),t.setSize(r.size()),t.setCompressedSize(r.size(!0)),this._afterAppend(t),e(n,t)}.bind(this)),r.once("error",function(t){n=t}),r.pipe(this,{end:!1}),r},YI.prototype._writeCentralDirectoryEnd=function(){var t=this._entries.length,e=this._archive.centralLength,r=this._archive.centralOffset;this.isZip64()&&(t=VI.ZIP64_MAGIC_SHORT,e=VI.ZIP64_MAGIC,r=VI.ZIP64_MAGIC),this.write(ZI.getLongBytes(VI.SIG_EOCD)),this.write(VI.SHORT_ZERO),this.write(VI.SHORT_ZERO),this.write(ZI.getShortBytes(t)),this.write(ZI.getShortBytes(t)),this.write(ZI.getLongBytes(e)),this.write(ZI.getLongBytes(r));var n=this.getComment(),i=Buffer.byteLength(n);this.write(ZI.getShortBytes(i)),this.write(n)},YI.prototype._writeCentralDirectoryZip64=function(){this.write(ZI.getLongBytes(VI.SIG_ZIP64_EOCD)),this.write(ZI.getEightBytes(44)),this.write(ZI.getShortBytes(VI.MIN_VERSION_ZIP64)),this.write(ZI.getShortBytes(VI.MIN_VERSION_ZIP64)),this.write(VI.LONG_ZERO),this.write(VI.LONG_ZERO),this.write(ZI.getEightBytes(this._entries.length)),this.write(ZI.getEightBytes(this._entries.length)),this.write(ZI.getEightBytes(this._archive.centralLength)),this.write(ZI.getEightBytes(this._archive.centralOffset)),this.write(ZI.getLongBytes(VI.SIG_ZIP64_EOCD_LOC)),this.write(VI.LONG_ZERO),this.write(ZI.getEightBytes(this._archive.centralOffset+this._archive.centralLength)),this.write(ZI.getLongBytes(1))},YI.prototype._writeCentralFileHeader=function(t){var e=t.getGeneralPurposeBit(),r=t.getMethod(),n=t._offsets.file,i=t.getSize(),o=t.getCompressedSize();if(t.isZip64()||n>VI.ZIP64_MAGIC){i=VI.ZIP64_MAGIC,o=VI.ZIP64_MAGIC,n=VI.ZIP64_MAGIC,t.setVersionNeededToExtract(VI.MIN_VERSION_ZIP64);var s=Buffer.concat([ZI.getShortBytes(VI.ZIP64_EXTRA_ID),ZI.getShortBytes(24),ZI.getEightBytes(t.getSize()),ZI.getEightBytes(t.getCompressedSize()),ZI.getEightBytes(t._offsets.file)],28);t.setExtra(s)}this.write(ZI.getLongBytes(VI.SIG_CFH)),this.write(ZI.getShortBytes(t.getPlatform()<<8|VI.VERSION_MADEBY)),this.write(ZI.getShortBytes(t.getVersionNeededToExtract())),this.write(e.encode()),this.write(ZI.getShortBytes(r)),this.write(ZI.getLongBytes(t.getTimeDos())),this.write(ZI.getLongBytes(t.getCrc())),this.write(ZI.getLongBytes(o)),this.write(ZI.getLongBytes(i));var a=t.getName(),l=t.getComment(),u=t.getCentralDirectoryExtra();e.usesUTF8ForNames()&&(a=Buffer.from(a),l=Buffer.from(l)),this.write(ZI.getShortBytes(a.length)),this.write(ZI.getShortBytes(u.length)),this.write(ZI.getShortBytes(l.length)),this.write(VI.SHORT_ZERO),this.write(ZI.getShortBytes(t.getInternalAttributes())),this.write(ZI.getLongBytes(t.getExternalAttributes())),this.write(ZI.getLongBytes(n)),this.write(a),this.write(u),this.write(l)},YI.prototype._writeDataDescriptor=function(t){this.write(ZI.getLongBytes(VI.SIG_DD)),this.write(ZI.getLongBytes(t.getCrc())),t.isZip64()?(this.write(ZI.getEightBytes(t.getCompressedSize())),this.write(ZI.getEightBytes(t.getSize()))):(this.write(ZI.getLongBytes(t.getCompressedSize())),this.write(ZI.getLongBytes(t.getSize())))},YI.prototype._writeLocalFileHeader=function(t){var e=t.getGeneralPurposeBit(),r=t.getMethod(),n=t.getName(),i=t.getLocalFileDataExtra();t.isZip64()&&(e.useDataDescriptor(!0),t.setVersionNeededToExtract(VI.MIN_VERSION_ZIP64)),e.usesUTF8ForNames()&&(n=Buffer.from(n)),t._offsets.file=this.offset,this.write(ZI.getLongBytes(VI.SIG_LFH)),this.write(ZI.getShortBytes(t.getVersionNeededToExtract())),this.write(e.encode()),this.write(ZI.getShortBytes(r)),this.write(ZI.getLongBytes(t.getTimeDos())),t._offsets.data=this.offset,e.usesDataDescriptor()?(this.write(VI.LONG_ZERO),this.write(VI.LONG_ZERO),this.write(VI.LONG_ZERO)):(this.write(ZI.getLongBytes(t.getCrc())),this.write(ZI.getLongBytes(t.getCompressedSize())),this.write(ZI.getLongBytes(t.getSize()))),this.write(ZI.getShortBytes(n.length)),this.write(ZI.getShortBytes(i.length)),this.write(n),this.write(i),t._offsets.contents=this.offset},YI.prototype.getComment=function(t){return null!==this._archive.comment?this._archive.comment:""},YI.prototype.isZip64=function(){return this._archive.forceZip64||this._entries.length>VI.ZIP64_MAGIC_SHORT||this._archive.centralLength>VI.ZIP64_MAGIC||this._archive.centralOffset>VI.ZIP64_MAGIC},YI.prototype.setComment=function(t){this._archive.comment=t};var KI={ArchiveEntry:_x,ZipArchiveEntry:Nx,ArchiveOutputStream:II,ZipArchiveOutputStream:PI.exports},QI=s.inherits,JI=KI.ZipArchiveOutputStream,XI=KI.ZipArchiveEntry,tP=vw,eP=gx.exports=function(t){if(!(this instanceof eP))return new eP(t);(t=this.options=t||{}).zlib=t.zlib||{},JI.call(this,t),"number"==typeof t.level&&t.level>=0&&(t.zlib.level=t.level,delete t.level),t.forceZip64||"number"!=typeof t.zlib.level||0!==t.zlib.level||(t.store=!0),t.namePrependSlash=t.namePrependSlash||!1,t.comment&&t.comment.length>0&&this.setComment(t.comment)};QI(eP,JI),eP.prototype._normalizeFileData=function(t){var e="directory"===(t=tP.defaults(t,{type:"file",name:null,namePrependSlash:this.options.namePrependSlash,linkname:null,date:null,mode:null,store:this.options.store,comment:""})).type,r="symlink"===t.type;return t.name&&(t.name=tP.sanitizePath(t.name),r||"/"!==t.name.slice(-1)?e&&(t.name+="/"):(e=!0,t.type="directory")),(e||r)&&(t.store=!0),t.date=tP.dateify(t.date),t},eP.prototype.entry=function(t,e,r){if("function"!=typeof r&&(r=this._emitErrorCallback.bind(this)),"file"===(e=this._normalizeFileData(e)).type||"directory"===e.type||"symlink"===e.type)if("string"==typeof e.name&&0!==e.name.length){if("symlink"!==e.type||"string"==typeof e.linkname){var n=new XI(e.name);return n.setTime(e.date,this.options.forceLocalTime),e.namePrependSlash&&n.setName(e.name,!0),e.store&&n.setMethod(0),e.comment.length>0&&n.setComment(e.comment),"symlink"===e.type&&"number"!=typeof e.mode&&(e.mode=40960),"number"==typeof e.mode&&("symlink"===e.type&&(e.mode|=40960),n.setUnixMode(e.mode)),"symlink"===e.type&&"string"==typeof e.linkname&&(t=Buffer.from(e.linkname)),JI.prototype.entry.call(this,n,t,r)}r(new Error("entry linkname must be a non-empty string value when type equals symlink"))}else r(new Error("entry name must be a non-empty string value"));else r(new Error(e.type+" entries not currently supported"))},eP.prototype.finalize=function(){this.finish()};var rP=gx.exports,nP=vw,iP=function(t){if(!(this instanceof iP))return new iP(t);t=this.options=nP.defaults(t,{comment:"",forceUTC:!1,namePrependSlash:!1,store:!1}),this.supports={directory:!0,symlink:!0},this.engine=new rP(t)};
40
- /**
41
- * ZIP Format Plugin
42
- *
43
- * @module plugins/zip
44
- * @license [MIT]{@link https://github.com/archiverjs/node-archiver/blob/master/LICENSE}
45
- * @copyright (c) 2012-2014 Chris Talkington, contributors.
46
- */iP.prototype.append=function(t,e,r){this.engine.entry(t,e,r)},iP.prototype.finalize=function(){this.engine.finalize()},iP.prototype.on=function(){return this.engine.on.apply(this.engine,arguments)},iP.prototype.pipe=function(){return this.engine.pipe.apply(this.engine,arguments)},iP.prototype.unpipe=function(){return this.engine.unpipe.apply(this.engine,arguments)};var oP=iP,sP={};const aP=class{constructor(t){if(!(t>0)||t-1&t)throw new Error("Max size for a FixedFIFO should be a power of two");this.buffer=new Array(t),this.mask=t-1,this.top=0,this.btm=0,this.next=null}clear(){this.top=this.btm=0,this.next=null,this.buffer.fill(void 0)}push(t){return void 0===this.buffer[this.top]&&(this.buffer[this.top]=t,this.top=this.top+1&this.mask,!0)}shift(){const t=this.buffer[this.btm];if(void 0!==t)return this.buffer[this.btm]=void 0,this.btm=this.btm+1&this.mask,t}peek(){return this.buffer[this.btm]}isEmpty(){return void 0===this.buffer[this.btm]}};var lP=class{constructor(t){this.hwm=t||16,this.head=new aP(this.hwm),this.tail=this.head,this.length=0}clear(){this.head=this.tail,this.head.clear(),this.length=0}push(t){if(this.length++,!this.head.push(t)){const e=this.head;this.head=e.next=new aP(2*this.head.buffer.length),this.head.push(t)}}shift(){0!==this.length&&this.length--;const t=this.tail.shift();if(void 0===t&&this.tail.next){const t=this.tail.next;return this.tail.next=null,this.tail=t,this.tail.shift()}return t}peek(){const t=this.tail.peek();return void 0===t&&this.tail.next?this.tail.next.peek():t}isEmpty(){return 0===this.length}},uP=class{constructor(t){this.decoder=new TextDecoder("utf16le"===t?"utf16-le":t)}get remaining(){return-1}decode(t){return this.decoder.decode(t,{stream:!0})}flush(){return this.decoder.decode(new Uint8Array(0))}};const cP=uP,hP=uP;const{EventEmitter:fP}=yn,dP=new Error("Stream was destroyed"),pP=new Error("Premature close"),yP=lP,gP=class{constructor(t="utf8"){switch(this.encoding=function(t){switch(t=t.toLowerCase()){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:throw new Error("Unknown encoding: "+t)}}(t),this.encoding){case"utf8":this.decoder=new hP;break;case"utf16le":case"base64":throw new Error("Unsupported encoding: "+this.encoding);default:this.decoder=new cP(this.encoding)}}get remaining(){return this.decoder.remaining}push(t){return"string"==typeof t?t:this.decoder.decode(t)}write(t){return this.push(t)}end(t){let e="";return t&&(e=this.push(t)),e+=this.decoder.flush(),e}},bP="undefined"==typeof queueMicrotask?t=>Ft.process.nextTick(t):queueMicrotask,mP=536870911,_P=1^mP,vP=2^mP,wP=32,SP=64,EP=128,RP=256,kP=1024,TP=2048,xP=4096,AP=8192,OP=16384,LP=32768,jP=131072,MP=131328,IP=16^mP,PP=536805375,DP=768^mP,CP=536838143,NP=536739839,FP=1<<18,BP=2<<18,WP=4<<18,UP=8<<18,zP=16<<18,$P=32<<18,HP=64<<18,GP=128<<18,qP=256<<18,VP=512<<18,ZP=1024<<18,YP=535822335,KP=503316479,QP=268435455,JP=262160,XP=536608751,tD=8404992,eD=14,rD=15,nD=8405006,iD=33587200,oD=33587215,sD=2359296,aD=270794767,lD=Symbol.asyncIterator||Symbol("asyncIterator");class uD{constructor(t,{highWaterMark:e=16384,map:r=null,mapWritable:n,byteLength:i,byteLengthWritable:o}={}){this.stream=t,this.queue=new yP,this.highWaterMark=e,this.buffered=0,this.error=null,this.pipeline=null,this.drains=null,this.byteLength=o||i||ID,this.map=n||r,this.afterWrite=gD.bind(this),this.afterUpdateNextTick=_D.bind(this)}get ended(){return 0!==(this.stream._duplexState&$P)}push(t){return!(142606350&this.stream._duplexState)&&(null!==this.map&&(t=this.map(t)),this.buffered+=this.byteLength(t),this.queue.push(t),this.buffered<this.highWaterMark?(this.stream._duplexState|=UP,!0):(this.stream._duplexState|=6291456,!1))}shift(){const t=this.queue.shift();return this.buffered-=this.byteLength(t),0===this.buffered&&(this.stream._duplexState&=534773759),t}end(t){"function"==typeof t?this.stream.once("finish",t):null!=t&&this.push(t),this.stream._duplexState=(this.stream._duplexState|VP)&YP}autoBatch(t,e){const r=[],n=this.stream;for(r.push(t);(n._duplexState&aD)===sD;)r.push(n._writableState.shift());if(0!==(n._duplexState&rD))return e(null);n._writev(r,e)}update(){const t=this.stream;t._duplexState|=BP;do{for(;(t._duplexState&aD)===UP;){const e=this.shift();t._duplexState|=67371008,t._write(e,this.afterWrite)}1310720&t._duplexState||this.updateNonPrimary()}while(!0===this.continueUpdate());t._duplexState&=536346623}updateNonPrimary(){const t=this.stream;if((144965647&t._duplexState)===VP)return t._duplexState=t._duplexState|FP,void t._final(pD.bind(this));4!==(t._duplexState&eD)?1===(t._duplexState&oD)&&(t._duplexState=(t._duplexState|JP)&_P,t._open(vD.bind(this))):0===(t._duplexState&iD)&&(t._duplexState|=JP,t._destroy(yD.bind(this)))}continueUpdate(){return 0!==(this.stream._duplexState&GP)&&(this.stream._duplexState&=KP,!0)}updateCallback(){(35127311&this.stream._duplexState)===WP?this.update():this.updateNextTick()}updateNextTick(){0===(this.stream._duplexState&GP)&&(this.stream._duplexState|=GP,0===(this.stream._duplexState&BP)&&bP(this.afterUpdateNextTick))}}class cD{constructor(t,{highWaterMark:e=16384,map:r=null,mapReadable:n,byteLength:i,byteLengthReadable:o}={}){this.stream=t,this.queue=new yP,this.highWaterMark=0===e?1:e,this.buffered=0,this.readAhead=e>0,this.error=null,this.pipeline=null,this.byteLength=o||i||ID,this.map=n||r,this.pipeTo=null,this.afterRead=bD.bind(this),this.afterUpdateNextTick=mD.bind(this)}get ended(){return 0!==(this.stream._duplexState&OP)}pipe(t,e){if(null!==this.pipeTo)throw new Error("Can only pipe to one destination");if("function"!=typeof e&&(e=null),this.stream._duplexState|=512,this.pipeTo=t,this.pipeline=new fD(this.stream,t,e),e&&this.stream.on("error",PD),MD(t))t._writableState.pipeline=this.pipeline,e&&t.on("error",PD),t.on("finish",this.pipeline.finished.bind(this.pipeline));else{const e=this.pipeline.done.bind(this.pipeline,t),r=this.pipeline.done.bind(this.pipeline,t,null);t.on("error",e),t.on("close",r),t.on("finish",this.pipeline.finished.bind(this.pipeline))}t.on("drain",dD.bind(this)),this.stream.emit("piping",t),t.emit("pipe",this.stream)}push(t){const e=this.stream;return null===t?(this.highWaterMark=0,e._duplexState=536805311&e._duplexState|1024,!1):null!==this.map&&null===(t=this.map(t))?(e._duplexState&=PP,this.buffered<this.highWaterMark):(this.buffered+=this.byteLength(t),this.queue.push(t),e._duplexState=(e._duplexState|EP)&PP,this.buffered<this.highWaterMark)}shift(){const t=this.queue.shift();return this.buffered-=this.byteLength(t),0===this.buffered&&(this.stream._duplexState&=536862591),t}unshift(t){const e=[null!==this.map?this.map(t):t];for(;this.buffered>0;)e.push(this.shift());for(let t=0;t<e.length-1;t++){const r=e[t];this.buffered+=this.byteLength(r),this.queue.push(r)}this.push(e[e.length-1])}read(){const t=this.stream;if((16527&t._duplexState)===EP){const e=this.shift();return null!==this.pipeTo&&!1===this.pipeTo.write(e)&&(t._duplexState&=DP),0!==(t._duplexState&TP)&&t.emit("data",e),e}return!1===this.readAhead&&(t._duplexState|=jP,this.updateNextTick()),null}drain(){const t=this.stream;for(;(16527&t._duplexState)===EP&&768&t._duplexState;){const e=this.shift();null!==this.pipeTo&&!1===this.pipeTo.write(e)&&(t._duplexState&=DP),0!==(t._duplexState&TP)&&t.emit("data",e)}}update(){const t=this.stream;t._duplexState|=wP;do{for(this.drain();this.buffered<this.highWaterMark&&(214047&t._duplexState)===jP;)t._duplexState|=65552,t._read(this.afterRead),this.drain();4224==(12431&t._duplexState)&&(t._duplexState|=AP,t.emit("readable")),80&t._duplexState||this.updateNonPrimary()}while(!0===this.continueUpdate());t._duplexState&=536870879}updateNonPrimary(){const t=this.stream;(1167&t._duplexState)===kP&&(t._duplexState=536869887&t._duplexState|16384,t.emit("end"),(t._duplexState&nD)===tD&&(t._duplexState|=4),null!==this.pipeTo&&this.pipeTo.end()),4!==(t._duplexState&eD)?1===(t._duplexState&oD)&&(t._duplexState=(t._duplexState|JP)&_P,t._open(vD.bind(this))):0===(t._duplexState&iD)&&(t._duplexState|=JP,t._destroy(yD.bind(this)))}continueUpdate(){return 0!==(this.stream._duplexState&LP)&&(this.stream._duplexState&=CP,!0)}updateCallback(){(32879&this.stream._duplexState)===SP?this.update():this.updateNextTick()}updateNextTickIfOpen(){32769&this.stream._duplexState||(this.stream._duplexState|=LP,0===(this.stream._duplexState&wP)&&bP(this.afterUpdateNextTick))}updateNextTick(){0===(this.stream._duplexState&LP)&&(this.stream._duplexState|=LP,0===(this.stream._duplexState&wP)&&bP(this.afterUpdateNextTick))}}class hD{constructor(t){this.data=null,this.afterTransform=wD.bind(t),this.afterFinal=null}}class fD{constructor(t,e,r){this.from=t,this.to=e,this.afterPipe=r,this.error=null,this.pipeToFinished=!1}finished(){this.pipeToFinished=!0}done(t,e){e&&(this.error=e),t!==this.to||(this.to=null,null===this.from)?t!==this.from||(this.from=null,null===this.to)?(null!==this.afterPipe&&this.afterPipe(this.error),this.to=this.from=this.afterPipe=null):0===(t._duplexState&OP)&&this.to.destroy(this.error||new Error("Readable stream closed before ending")):0!==(this.from._duplexState&OP)&&this.pipeToFinished||this.from.destroy(this.error||new Error("Writable stream closed prematurely"))}}function dD(){this.stream._duplexState|=512,this.updateCallback()}function pD(t){const e=this.stream;t&&e.destroy(t),0===(e._duplexState&eD)&&(e._duplexState|=$P,e.emit("finish")),(e._duplexState&nD)===tD&&(e._duplexState|=4),e._duplexState&=402391039,0===(e._duplexState&BP)?this.update():this.updateNextTick()}function yD(t){const e=this.stream;t||this.error===dP||(t=this.error),t&&e.emit("error",t),e._duplexState|=8,e.emit("close");const r=e._readableState,n=e._writableState;if(null!==r&&null!==r.pipeline&&r.pipeline.done(e,t),null!==n){for(;null!==n.drains&&n.drains.length>0;)n.drains.shift().resolve(!1);null!==n.pipeline&&n.pipeline.done(e,t)}}function gD(t){const e=this.stream;t&&e.destroy(t),e._duplexState&=469499903,null!==this.drains&&function(t){for(let e=0;e<t.length;e++)0===--t[e].writes&&(t.shift().resolve(!0),e--)}(this.drains),(6553615&e._duplexState)===zP&&(e._duplexState&=532676607,(e._duplexState&HP)===HP&&e.emit("drain")),this.updateCallback()}function bD(t){t&&this.stream.destroy(t),this.stream._duplexState&=IP,!1===this.readAhead&&0===(this.stream._duplexState&RP)&&(this.stream._duplexState&=NP),this.updateCallback()}function mD(){0===(this.stream._duplexState&wP)&&(this.stream._duplexState&=CP,this.update())}function _D(){0===(this.stream._duplexState&BP)&&(this.stream._duplexState&=KP,this.update())}function vD(t){const e=this.stream;t&&e.destroy(t),4&e._duplexState||(17423&e._duplexState||(e._duplexState|=SP),142606351&e._duplexState||(e._duplexState|=WP),e.emit("open")),e._duplexState&=XP,null!==e._writableState&&e._writableState.updateCallback(),null!==e._readableState&&e._readableState.updateCallback()}function wD(t,e){null!=e&&this.push(e),this._writableState.afterWrite(t)}function SD(t){null!==this._readableState&&("data"===t&&(this._duplexState|=133376,this._readableState.updateNextTick()),"readable"===t&&(this._duplexState|=xP,this._readableState.updateNextTick())),null!==this._writableState&&"drain"===t&&(this._duplexState|=HP,this._writableState.updateNextTick())}let ED=class extends fP{constructor(t){super(),this._duplexState=0,this._readableState=null,this._writableState=null,t&&(t.open&&(this._open=t.open),t.destroy&&(this._destroy=t.destroy),t.predestroy&&(this._predestroy=t.predestroy),t.signal&&t.signal.addEventListener("abort",DD.bind(this))),this.on("newListener",SD)}_open(t){t(null)}_destroy(t){t(null)}_predestroy(){}get readable(){return null!==this._readableState||void 0}get writable(){return null!==this._writableState||void 0}get destroyed(){return!!(8&this._duplexState)}get destroying(){return 0!==(this._duplexState&eD)}destroy(t){0===(this._duplexState&eD)&&(t||(t=dP),this._duplexState=535822271&this._duplexState|4,null!==this._readableState&&(this._readableState.highWaterMark=0,this._readableState.error=t),null!==this._writableState&&(this._writableState.highWaterMark=0,this._writableState.error=t),this._duplexState|=2,this._predestroy(),this._duplexState&=vP,null!==this._readableState&&this._readableState.updateNextTick(),null!==this._writableState&&this._writableState.updateNextTick())}},RD=class t extends ED{constructor(t){super(t),this._duplexState|=8519681,this._readableState=new cD(this,t),t&&(!1===this._readableState.readAhead&&(this._duplexState&=NP),t.read&&(this._read=t.read),t.eagerOpen&&this._readableState.updateNextTick(),t.encoding&&this.setEncoding(t.encoding))}setEncoding(t){const e=new gP(t),r=this._readableState.map||LD;return this._readableState.map=function(t){const n=e.push(t);return""===n&&(0!==t.byteLength||e.remaining>0)?null:r(n)},this}_read(t){t(null)}pipe(t,e){return this._readableState.updateNextTick(),this._readableState.pipe(t,e),t}read(){return this._readableState.updateNextTick(),this._readableState.read()}push(t){return this._readableState.updateNextTickIfOpen(),this._readableState.push(t)}unshift(t){return this._readableState.updateNextTickIfOpen(),this._readableState.unshift(t)}resume(){return this._duplexState|=MP,this._readableState.updateNextTick(),this}pause(){return this._duplexState&=!1===this._readableState.readAhead?536739583:536870655,this}static _fromAsyncIterator(e,r){let n;const i=new t({...r,read(t){e.next().then(o).then(t.bind(null,null)).catch(t)},predestroy(){n=e.return()},destroy(t){if(!n)return t(null);n.then(t.bind(null,null)).catch(t)}});return i;function o(t){t.done?i.push(null):i.push(t.value)}}static from(e,r){if(function(t){return MD(t)&&t.readable}(e))return e;if(e[lD])return this._fromAsyncIterator(e[lD](),r);Array.isArray(e)||(e=void 0===e?[]:[e]);let n=0;return new t({...r,read(t){this.push(n===e.length?null:e[n++]),t(null)}})}static isBackpressured(t){return!!(17422&t._duplexState)||t._readableState.buffered>=t._readableState.highWaterMark}static isPaused(t){return 0===(t._duplexState&RP)}[lD](){const t=this;let e=null,r=null,n=null;return this.on("error",t=>{e=t}),this.on("readable",function(){null!==r&&i(t.read())}),this.on("close",function(){null!==r&&i(null)}),{[lD](){return this},next:()=>new Promise(function(e,o){r=e,n=o;const s=t.read();null!==s?i(s):8&t._duplexState&&i(null)}),return:()=>o(null),throw:t=>o(t)};function i(i){null!==n&&(e?n(e):null===i&&0===(t._duplexState&OP)?n(dP):r({value:i,done:null===i}),n=r=null)}function o(e){return t.destroy(e),new Promise((r,n)=>{if(8&t._duplexState)return r({value:void 0,done:!0});t.once("close",function(){e?n(e):r({value:void 0,done:!0})})})}}},kD=class extends ED{constructor(t){super(t),this._duplexState|=16385,this._writableState=new uD(this,t),t&&(t.writev&&(this._writev=t.writev),t.write&&(this._write=t.write),t.final&&(this._final=t.final),t.eagerOpen&&this._writableState.updateNextTick())}cork(){this._duplexState|=ZP}uncork(){this._duplexState&=QP,this._writableState.updateNextTick()}_writev(t,e){e(null)}_write(t,e){this._writableState.autoBatch(t,e)}_final(t){t(null)}static isBackpressured(t){return!!(146800654&t._duplexState)}static drained(t){if(t.destroyed)return Promise.resolve(!1);const e=t._writableState;var r;const n=((r=t)._writev!==kD.prototype._writev&&r._writev!==TD.prototype._writev?Math.min(1,e.queue.length):e.queue.length)+(t._duplexState&qP?1:0);return 0===n?Promise.resolve(!0):(null===e.drains&&(e.drains=[]),new Promise(t=>{e.drains.push({writes:n,resolve:t})}))}write(t){return this._writableState.updateNextTick(),this._writableState.push(t)}end(t){return this._writableState.updateNextTick(),this._writableState.end(t),this}},TD=class extends RD{constructor(t){super(t),this._duplexState=1|this._duplexState&jP,this._writableState=new uD(this,t),t&&(t.writev&&(this._writev=t.writev),t.write&&(this._write=t.write),t.final&&(this._final=t.final))}cork(){this._duplexState|=ZP}uncork(){this._duplexState&=QP,this._writableState.updateNextTick()}_writev(t,e){e(null)}_write(t,e){this._writableState.autoBatch(t,e)}_final(t){t(null)}write(t){return this._writableState.updateNextTick(),this._writableState.push(t)}end(t){return this._writableState.updateNextTick(),this._writableState.end(t),this}},xD=class extends TD{constructor(t){super(t),this._transformState=new hD(this),t&&(t.transform&&(this._transform=t.transform),t.flush&&(this._flush=t.flush))}_write(t,e){this._readableState.buffered>=this._readableState.highWaterMark?this._transformState.data=t:this._transform(t,this._transformState.afterTransform)}_read(t){if(null!==this._transformState.data){const e=this._transformState.data;this._transformState.data=null,t(null),this._transform(e,this._transformState.afterTransform)}else t(null)}destroy(t){super.destroy(t),null!==this._transformState.data&&(this._transformState.data=null,this._transformState.afterTransform())}_transform(t,e){e(null,t)}_flush(t){t(null)}_final(t){this._transformState.afterFinal=t,this._flush(AD.bind(this))}};function AD(t,e){const r=this._transformState.afterFinal;if(t)return r(t);null!=e&&this.push(e),this.push(null),r(null)}function OD(t,...e){const r=Array.isArray(t)?[...t,...e]:[t,...e],n=r.length&&"function"==typeof r[r.length-1]?r.pop():null;if(r.length<2)throw new Error("Pipeline requires at least 2 streams");let i=r[0],o=null,s=null;for(let t=1;t<r.length;t++)o=r[t],MD(i)?i.pipe(o,l):(a(i,!0,t>1,l),i.pipe(o)),i=o;if(n){let t=!1;const e=MD(o)||!(!o._writableState||!o._writableState.autoDestroy);o.on("error",t=>{null===s&&(s=t)}),o.on("finish",()=>{t=!0,e||n(s)}),e&&o.on("close",()=>n(s||(t?null:pP)))}return o;function a(t,e,r,n){t.on("error",n),t.on("close",function(){if(e&&t._readableState&&!t._readableState.ended)return n(pP);if(r&&t._writableState&&!t._writableState.ended)return n(pP)})}function l(t){if(t&&!s){s=t;for(const e of r)e.destroy(t)}}}function LD(t){return t}function jD(t){return!!t._readableState||!!t._writableState}function MD(t){return"number"==typeof t._duplexState&&jD(t)}function ID(t){return function(t){return"object"==typeof t&&null!==t&&"number"==typeof t.byteLength}(t)?t.byteLength:1024}function PD(){}function DD(){this.destroy(new Error("Stream aborted."))}var CD={pipeline:OD,pipelinePromise:function(...t){return new Promise((e,r)=>OD(...t,t=>{if(t)return r(t);e()}))},isStream:jD,isStreamx:MD,isEnded:function(t){return!!t._readableState&&t._readableState.ended},isFinished:function(t){return!!t._writableState&&t._writableState.ended},isDisturbed:function(t){return!!(1&~t._duplexState)||0!==(t._duplexState&iD)},getStreamError:function(t,e={}){const r=t._readableState&&t._readableState.error||t._writableState&&t._writableState.error;return e.all||r!==dP?r:null},Stream:ED,Writable:kD,Readable:RD,Duplex:TD,Transform:xD,PassThrough:class extends xD{}},ND={exports:{}};function FD(t){return t.length}var BD={byteLength:FD,toString:function(t){const e=t.byteLength;let r="";for(let n=0;n<e;n++)r+=String.fromCharCode(t[n]);return r},write:function(t,e,r=0,n=FD(e)){const i=Math.min(n,t.byteLength-r);for(let n=0;n<i;n++)t[r+n]=e.charCodeAt(n);return i}};const WD="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",UD=new Uint8Array(256);for(let t=0;t<64;t++)UD[WD.charCodeAt(t)]=t;function zD(t){let e=t.length;return 61===t.charCodeAt(e-1)&&e--,e>1&&61===t.charCodeAt(e-1)&&e--,3*e>>>2}UD[45]=62,UD[95]=63;var $D={byteLength:zD,toString:function(t){const e=t.byteLength;let r="";for(let n=0;n<e;n+=3)r+=WD[t[n]>>2]+WD[(3&t[n])<<4|t[n+1]>>4]+WD[(15&t[n+1])<<2|t[n+2]>>6]+WD[63&t[n+2]];return e%3==2?r=r.substring(0,r.length-1)+"=":e%3==1&&(r=r.substring(0,r.length-2)+"=="),r},write:function(t,e,r=0,n=zD(e)){const i=Math.min(n,t.byteLength-r);for(let r=0,n=0;n<i;r+=4){const i=UD[e.charCodeAt(r)],o=UD[e.charCodeAt(r+1)],s=UD[e.charCodeAt(r+2)],a=UD[e.charCodeAt(r+3)];t[n++]=i<<2|o>>4,t[n++]=(15&o)<<4|s>>2,t[n++]=(3&s)<<6|63&a}return i}};function HD(t){return t.length>>>1}var GD={byteLength:HD,toString:function(t){const e=t.byteLength;t=new DataView(t.buffer,t.byteOffset,e);let r="",n=0;for(let i=e-e%4;n<i;n+=4)r+=t.getUint32(n).toString(16).padStart(8,"0");for(;n<e;n++)r+=t.getUint8(n).toString(16).padStart(2,"0");return r},write:function(t,e,r=0,n=HD(e)){const i=Math.min(n,t.byteLength-r);for(let n=0;n<i;n++){const i=qD(e.charCodeAt(2*n)),o=qD(e.charCodeAt(2*n+1));if(void 0===i||void 0===o)return t.subarray(0,n);t[r+n]=i<<4|o}return i}};function qD(t){return t>=48&&t<=57?t-48:t>=65&&t<=70?t-65+10:t>=97&&t<=102?t-97+10:void 0}function VD(t){let e=0;for(let r=0,n=t.length;r<n;r++){const i=t.charCodeAt(r);if(i>=55296&&i<=56319&&r+1<n){const n=t.charCodeAt(r+1);if(n>=56320&&n<=57343){e+=4,r++;continue}}e+=i<=127?1:i<=2047?2:3}return e}let ZD,YD;if("undefined"!=typeof TextDecoder){const t=new TextDecoder;ZD=function(e){return t.decode(e)}}else ZD=function(t){const e=t.byteLength;let r="",n=0;for(;n<e;){let i=t[n];if(i<=127){r+=String.fromCharCode(i),n++;continue}let o=0,s=0;if(i<=223?(o=1,s=31&i):i<=239?(o=2,s=15&i):i<=244&&(o=3,s=7&i),e-n-o>0){let e=0;for(;e<o;)i=t[n+e+1],s=s<<6|63&i,e+=1}else s=65533,o=e-n;r+=String.fromCodePoint(s),n+=o+1}return r};if("undefined"!=typeof TextEncoder){const t=new TextEncoder;YD=function(e,r,n=0,i=VD(r)){const o=Math.min(i,e.byteLength-n);return t.encodeInto(r,e.subarray(n,n+o)),o}}else YD=function(t,e,r=0,n=VD(e)){const i=Math.min(n,t.byteLength-r);t=t.subarray(r,r+i);let o=0,s=0;for(;o<e.length;){const r=e.codePointAt(o);if(r<=127){t[s++]=r,o++;continue}let n=0,i=0;for(r<=2047?(n=6,i=192):r<=65535?(n=12,i=224):r<=2097151&&(n=18,i=240),t[s++]=i|r>>n,n-=6;n>=0;)t[s++]=128|r>>n&63,n-=6;o+=r>=65536?2:1}return i};var KD={byteLength:VD,toString:ZD,write:YD};function QD(t){return 2*t.length}var JD={byteLength:QD,toString:function(t){const e=t.byteLength;let r="";for(let n=0;n<e-1;n+=2)r+=String.fromCharCode(t[n]+256*t[n+1]);return r},write:function(t,e,r=0,n=QD(e)){const i=Math.min(n,t.byteLength-r);let o=i;for(let n=0;n<e.length&&!((o-=2)<0);++n){const i=e.charCodeAt(n),o=i>>8,s=i%256;t[r+2*n]=s,t[r+2*n+1]=o}return i}};!function(t,e){const r=BD,n=$D,i=GD,o=KD,s=JD,a=255===new Uint8Array(Uint16Array.of(255).buffer)[0];function l(t){switch(t){case"ascii":return r;case"base64":return n;case"hex":return i;case"utf8":case"utf-8":case void 0:case null:return o;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return s;default:throw new Error(`Unknown encoding: ${t}`)}}function u(t){return t instanceof Uint8Array}function c(t,e,r){return"string"==typeof t?function(t,e){const r=l(e),n=new Uint8Array(r.byteLength(t));return r.write(n,t,0,n.byteLength),n}(t,e):Array.isArray(t)?function(t){const e=new Uint8Array(t.length);return e.set(t),e}(t):ArrayBuffer.isView(t)?function(t){const e=new Uint8Array(t.byteLength);return e.set(t),e}(t):function(t,e,r){return new Uint8Array(t,e,r)}(t,e,r)}function h(t,e,r,n,i){if(0===t.byteLength)return-1;if("string"==typeof r?(n=r,r=0):void 0===r?r=i?0:t.length-1:r<0&&(r+=t.byteLength),r>=t.byteLength){if(i)return-1;r=t.byteLength-1}else if(r<0){if(!i)return-1;r=0}if("string"==typeof e)e=c(e,n);else if("number"==typeof e)return e&=255,i?t.indexOf(e,r):t.lastIndexOf(e,r);if(0===e.byteLength)return-1;if(i){let n=-1;for(let i=r;i<t.byteLength;i++)if(t[i]===e[-1===n?0:i-n]){if(-1===n&&(n=i),i-n+1===e.byteLength)return n}else-1!==n&&(i-=i-n),n=-1}else{r+e.byteLength>t.byteLength&&(r=t.byteLength-e.byteLength);for(let n=r;n>=0;n--){let r=!0;for(let i=0;i<e.byteLength;i++)if(t[n+i]!==e[i]){r=!1;break}if(r)return n}}return-1}function f(t,e,r,n){return h(t,e,r,n,!0)}function d(t,e,r){const n=t[e];t[e]=t[r],t[r]=n}t.exports=e={isBuffer:u,isEncoding:function(t){try{return l(t),!0}catch{return!1}},alloc:function(t,r,n){const i=new Uint8Array(t);return void 0!==r&&e.fill(i,r,0,i.byteLength,n),i},allocUnsafe:function(t){return new Uint8Array(t)},allocUnsafeSlow:function(t){return new Uint8Array(t)},byteLength:function(t,e){return l(e).byteLength(t)},compare:function(t,e){if(t===e)return 0;const r=Math.min(t.byteLength,e.byteLength);t=new DataView(t.buffer,t.byteOffset,t.byteLength),e=new DataView(e.buffer,e.byteOffset,e.byteLength);let n=0;for(let i=r-r%4;n<i;n+=4){if(t.getUint32(n,a)!==e.getUint32(n,a))break}for(;n<r;n++){const r=t.getUint8(n),i=e.getUint8(n);if(r<i)return-1;if(r>i)return 1}return t.byteLength>e.byteLength?1:t.byteLength<e.byteLength?-1:0},concat:function(t,e){void 0===e&&(e=t.reduce((t,e)=>t+e.byteLength,0));const r=new Uint8Array(e);let n=0;for(const e of t){if(n+e.byteLength>r.byteLength){const t=e.subarray(0,r.byteLength-n);return r.set(t,n),r}r.set(e,n),n+=e.byteLength}return r},copy:function(t,e,r=0,n=0,i=t.byteLength){if(i>0&&i<n)return 0;if(i===n)return 0;if(0===t.byteLength||0===e.byteLength)return 0;if(r<0)throw new RangeError("targetStart is out of range");if(n<0||n>=t.byteLength)throw new RangeError("sourceStart is out of range");if(i<0)throw new RangeError("sourceEnd is out of range");r>=e.byteLength&&(r=e.byteLength),i>t.byteLength&&(i=t.byteLength),e.byteLength-r<i-n&&(i=e.length-r+n);const o=i-n;return t===e?e.copyWithin(r,n,i):e.set(t.subarray(n,i),r),o},equals:function(t,e){if(t===e)return!0;if(t.byteLength!==e.byteLength)return!1;const r=t.byteLength;t=new DataView(t.buffer,t.byteOffset,t.byteLength),e=new DataView(e.buffer,e.byteOffset,e.byteLength);let n=0;for(let i=r-r%4;n<i;n+=4)if(t.getUint32(n,a)!==e.getUint32(n,a))return!1;for(;n<r;n++)if(t.getUint8(n)!==e.getUint8(n))return!1;return!0},fill:function(t,e,r,n,i){if("string"==typeof e?"string"==typeof r?(i=r,r=0,n=t.byteLength):"string"==typeof n&&(i=n,n=t.byteLength):"number"==typeof e?e&=255:"boolean"==typeof e&&(e=+e),r<0||t.byteLength<r||t.byteLength<n)throw new RangeError("Out of range index");if(void 0===r&&(r=0),void 0===n&&(n=t.byteLength),n<=r)return t;if(e||(e=0),"number"==typeof e)for(let i=r;i<n;++i)t[i]=e;else{const o=(e=u(e)?e:c(e,i)).byteLength;for(let i=0;i<n-r;++i)t[i+r]=e[i%o]}return t},from:c,includes:function(t,e,r,n){return-1!==f(t,e,r,n)},indexOf:f,lastIndexOf:function(t,e,r,n){return h(t,e,r,n,!1)},swap16:function(t){const e=t.byteLength;if(e%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let r=0;r<e;r+=2)d(t,r,r+1);return t},swap32:function(t){const e=t.byteLength;if(e%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(let r=0;r<e;r+=4)d(t,r,r+3),d(t,r+1,r+2);return t},swap64:function(t){const e=t.byteLength;if(e%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(let r=0;r<e;r+=8)d(t,r,r+7),d(t,r+1,r+6),d(t,r+2,r+5),d(t,r+3,r+4);return t},toBuffer:function(t){return t},toString:function(t,e,r=0,n=t.byteLength){const i=t.byteLength;return r>=i||n<=r?"":(r<0&&(r=0),n>i&&(n=i),(0!==r||n<i)&&(t=t.subarray(r,n)),l(e).toString(t))},write:function(t,e,r,n,i){return void 0===r?i="utf8":void 0===n&&"string"==typeof r?(i=r,r=void 0):void 0===i&&"string"==typeof n&&(i=n,n=void 0),l(i).write(t,e,r,n)},writeDoubleLE:function(t,e,r){return void 0===r&&(r=0),new DataView(t.buffer,t.byteOffset,t.byteLength).setFloat64(r,e,!0),r+8},writeFloatLE:function(t,e,r){return void 0===r&&(r=0),new DataView(t.buffer,t.byteOffset,t.byteLength).setFloat32(r,e,!0),r+4},writeUInt32LE:function(t,e,r){return void 0===r&&(r=0),new DataView(t.buffer,t.byteOffset,t.byteLength).setUint32(r,e,!0),r+4},writeInt32LE:function(t,e,r){return void 0===r&&(r=0),new DataView(t.buffer,t.byteOffset,t.byteLength).setInt32(r,e,!0),r+4},readDoubleLE:function(t,e){return void 0===e&&(e=0),new DataView(t.buffer,t.byteOffset,t.byteLength).getFloat64(e,!0)},readFloatLE:function(t,e){return void 0===e&&(e=0),new DataView(t.buffer,t.byteOffset,t.byteLength).getFloat32(e,!0)},readUInt32LE:function(t,e){return void 0===e&&(e=0),new DataView(t.buffer,t.byteOffset,t.byteLength).getUint32(e,!0)},readInt32LE:function(t,e){return void 0===e&&(e=0),new DataView(t.buffer,t.byteOffset,t.byteLength).getInt32(e,!0)},writeDoubleBE:function(t,e,r){return void 0===r&&(r=0),new DataView(t.buffer,t.byteOffset,t.byteLength).setFloat64(r,e,!1),r+8},writeFloatBE:function(t,e,r){return void 0===r&&(r=0),new DataView(t.buffer,t.byteOffset,t.byteLength).setFloat32(r,e,!1),r+4},writeUInt32BE:function(t,e,r){return void 0===r&&(r=0),new DataView(t.buffer,t.byteOffset,t.byteLength).setUint32(r,e,!1),r+4},writeInt32BE:function(t,e,r){return void 0===r&&(r=0),new DataView(t.buffer,t.byteOffset,t.byteLength).setInt32(r,e,!1),r+4},readDoubleBE:function(t,e){return void 0===e&&(e=0),new DataView(t.buffer,t.byteOffset,t.byteLength).getFloat64(e,!1)},readFloatBE:function(t,e){return void 0===e&&(e=0),new DataView(t.buffer,t.byteOffset,t.byteLength).getFloat32(e,!1)},readUInt32BE:function(t,e){return void 0===e&&(e=0),new DataView(t.buffer,t.byteOffset,t.byteLength).getUint32(e,!1)},readInt32BE:function(t,e){return void 0===e&&(e=0),new DataView(t.buffer,t.byteOffset,t.byteLength).getInt32(e,!1)}}}(ND,ND.exports);var XD=ND.exports,tC={};const eC=XD,rC="0".charCodeAt(0),nC=eC.from([117,115,116,97,114,0]),iC=eC.from([rC,rC]),oC=eC.from([117,115,116,97,114,32]),sC=eC.from([32,0]),aC=257,lC=263;function uC(t,e,r,n){for(;r<n;r++)if(t[r]===e)return r;return n}function cC(t){let e=256;for(let r=0;r<148;r++)e+=t[r];for(let r=156;r<512;r++)e+=t[r];return e}function hC(t,e){return(t=t.toString(8)).length>e?"7777777777777777777".slice(0,e)+" ":"0000000000000000000".slice(0,e-t.length)+t+" "}function fC(t,e,r){if(128&(t=t.subarray(e,e+r))[e=0])return function(t){let e;if(128===t[0])e=!0;else{if(255!==t[0])return null;e=!1}const r=[];let n;for(n=t.length-1;n>0;n--){const i=t[n];e?r.push(i):r.push(255-i)}let i=0;const o=r.length;for(n=0;n<o;n++)i+=r[n]*Math.pow(256,n);return e?i:-1*i}(t);{for(;e<t.length&&32===t[e];)e++;const r=function(t,e,r){return"number"!=typeof t?r:(t=~~t)>=e?e:t>=0||(t+=e)>=0?t:0}(uC(t,32,e,t.length),t.length,t.length);for(;e<r&&0===t[e];)e++;return r===e?0:parseInt(eC.toString(t.subarray(e,r)),8)}}function dC(t,e,r,n){return eC.toString(t.subarray(e,uC(t,0,e,e+r)),n)}function pC(t){const e=eC.byteLength(t);let r=Math.floor(Math.log(e)/Math.log(10))+1;return e+r>=Math.pow(10,r)&&r++,e+r+t}tC.decodeLongPath=function(t,e){return dC(t,0,t.length,e)},tC.encodePax=function(t){let e="";t.name&&(e+=pC(" path="+t.name+"\n")),t.linkname&&(e+=pC(" linkpath="+t.linkname+"\n"));const r=t.pax;if(r)for(const t in r)e+=pC(" "+t+"="+r[t]+"\n");return eC.from(e)},tC.decodePax=function(t){const e={};for(;t.length;){let r=0;for(;r<t.length&&32!==t[r];)r++;const n=parseInt(eC.toString(t.subarray(0,r)),10);if(!n)return e;const i=eC.toString(t.subarray(r+1,n-1)),o=i.indexOf("=");if(-1===o)return e;e[i.slice(0,o)]=i.slice(o+1),t=t.subarray(n)}return e},tC.encode=function(t){const e=eC.alloc(512);let r=t.name,n="";if(5===t.typeflag&&"/"!==r[r.length-1]&&(r+="/"),eC.byteLength(r)!==r.length)return null;for(;eC.byteLength(r)>100;){const t=r.indexOf("/");if(-1===t)return null;n+=n?"/"+r.slice(0,t):r.slice(0,t),r=r.slice(t+1)}return eC.byteLength(r)>100||eC.byteLength(n)>155||t.linkname&&eC.byteLength(t.linkname)>100?null:(eC.write(e,r),eC.write(e,hC(4095&t.mode,6),100),eC.write(e,hC(t.uid,6),108),eC.write(e,hC(t.gid,6),116),function(t,e,r){t.toString(8).length>11?function(t,e,r){e[r]=128;for(let n=11;n>0;n--)e[r+n]=255&t,t=Math.floor(t/256)}(t,e,r):eC.write(e,hC(t,11),r)}(t.size,e,124),eC.write(e,hC(t.mtime.getTime()/1e3|0,11),136),e[156]=rC+function(t){switch(t){case"file":return 0;case"link":return 1;case"symlink":return 2;case"character-device":return 3;case"block-device":return 4;case"directory":return 5;case"fifo":return 6;case"contiguous-file":return 7;case"pax-header":return 72}return 0}(t.type),t.linkname&&eC.write(e,t.linkname,157),eC.copy(nC,e,aC),eC.copy(iC,e,263),t.uname&&eC.write(e,t.uname,265),t.gname&&eC.write(e,t.gname,297),eC.write(e,hC(t.devmajor||0,6),329),eC.write(e,hC(t.devminor||0,6),337),n&&eC.write(e,n,345),eC.write(e,hC(cC(e),6),148),e)},tC.decode=function(t,e,r){let n=0===t[156]?0:t[156]-rC,i=dC(t,0,100,e);const o=fC(t,100,8),s=fC(t,108,8),a=fC(t,116,8),l=fC(t,124,12),u=fC(t,136,12),c=function(t){switch(t){case 0:return"file";case 1:return"link";case 2:return"symlink";case 3:return"character-device";case 4:return"block-device";case 5:return"directory";case 6:return"fifo";case 7:return"contiguous-file";case 72:return"pax-header";case 55:return"pax-global-header";case 27:return"gnu-long-link-path";case 28:case 30:return"gnu-long-path"}return null}(n),h=0===t[157]?null:dC(t,157,100,e),f=dC(t,265,32),d=dC(t,297,32),p=fC(t,329,8),y=fC(t,337,8),g=cC(t);if(256===g)return null;if(g!==fC(t,148,8))throw new Error("Invalid tar header. Maybe the tar is corrupted or it needs to be gunzipped?");if(function(t){return eC.equals(nC,t.subarray(aC,263))}(t))t[345]&&(i=dC(t,345,155,e)+"/"+i);else if(function(t){return eC.equals(oC,t.subarray(aC,263))&&eC.equals(sC,t.subarray(lC,265))}(t));else if(!r)throw new Error("Invalid tar header: unknown format.");return 0===n&&i&&"/"===i[i.length-1]&&(n=5),{name:i,mode:o,uid:s,gid:a,size:l,mtime:new Date(1e3*u),type:c,linkname:h,uname:f,gname:d,devmajor:p,devminor:y,pax:null}};const{Writable:yC,Readable:gC,getStreamError:bC}=CD,mC=lP,_C=XD,vC=tC,wC=_C.alloc(0);class SC{constructor(){this.buffered=0,this.shifted=0,this.queue=new mC,this._offset=0}push(t){this.buffered+=t.byteLength,this.queue.push(t)}shiftFirst(t){return 0===this._buffered?null:this._next(t)}shift(t){if(t>this.buffered)return null;if(0===t)return wC;let e=this._next(t);if(t===e.byteLength)return e;const r=[e];for(;(t-=e.byteLength)>0;)e=this._next(t),r.push(e);return _C.concat(r)}_next(t){const e=this.queue.peek(),r=e.byteLength-this._offset;if(t>=r){const t=this._offset?e.subarray(this._offset,e.byteLength):e;return this.queue.shift(),this._offset=0,this.buffered-=r,this.shifted+=r,t}return this.buffered-=t,this.shifted+=t,e.subarray(this._offset,this._offset+=t)}}class EC extends gC{constructor(t,e,r){super(),this.header=e,this.offset=r,this._parent=t}_read(t){0===this.header.size&&this.push(null),this._parent._stream===this&&this._parent._update(),t(null)}_predestroy(){this._parent.destroy(bC(this))}_detach(){this._parent._stream===this&&(this._parent._stream=null,this._parent._missing=TC(this.header.size),this._parent._update())}_destroy(t){this._detach(),t(null)}}let RC=class extends yC{constructor(t){super(t),t||(t={}),this._buffer=new SC,this._offset=0,this._header=null,this._stream=null,this._missing=0,this._longHeader=!1,this._callback=kC,this._locked=!1,this._finished=!1,this._pax=null,this._paxGlobal=null,this._gnuLongPath=null,this._gnuLongLinkPath=null,this._filenameEncoding=t.filenameEncoding||"utf-8",this._allowUnknownFormat=!!t.allowUnknownFormat,this._unlockBound=this._unlock.bind(this)}_unlock(t){if(this._locked=!1,t)return this.destroy(t),void this._continueWrite(t);this._update()}_consumeHeader(){if(this._locked)return!1;this._offset=this._buffer.shifted;try{this._header=vC.decode(this._buffer.shift(512),this._filenameEncoding,this._allowUnknownFormat)}catch(t){return this._continueWrite(t),!1}if(!this._header)return!0;switch(this._header.type){case"gnu-long-path":case"gnu-long-link-path":case"pax-global-header":case"pax-header":return this._longHeader=!0,this._missing=this._header.size,!0}return this._locked=!0,this._applyLongHeaders(),0===this._header.size||"directory"===this._header.type?(this.emit("entry",this._header,this._createStream(),this._unlockBound),!0):(this._stream=this._createStream(),this._missing=this._header.size,this.emit("entry",this._header,this._stream,this._unlockBound),!0)}_applyLongHeaders(){this._gnuLongPath&&(this._header.name=this._gnuLongPath,this._gnuLongPath=null),this._gnuLongLinkPath&&(this._header.linkname=this._gnuLongLinkPath,this._gnuLongLinkPath=null),this._pax&&(this._pax.path&&(this._header.name=this._pax.path),this._pax.linkpath&&(this._header.linkname=this._pax.linkpath),this._pax.size&&(this._header.size=parseInt(this._pax.size,10)),this._header.pax=this._pax,this._pax=null)}_decodeLongHeader(t){switch(this._header.type){case"gnu-long-path":this._gnuLongPath=vC.decodeLongPath(t,this._filenameEncoding);break;case"gnu-long-link-path":this._gnuLongLinkPath=vC.decodeLongPath(t,this._filenameEncoding);break;case"pax-global-header":this._paxGlobal=vC.decodePax(t);break;case"pax-header":this._pax=null===this._paxGlobal?vC.decodePax(t):Object.assign({},this._paxGlobal,vC.decodePax(t))}}_consumeLongHeader(){this._longHeader=!1,this._missing=TC(this._header.size);const t=this._buffer.shift(this._header.size);try{this._decodeLongHeader(t)}catch(t){return this._continueWrite(t),!1}return!0}_consumeStream(){const t=this._buffer.shiftFirst(this._missing);if(null===t)return!1;this._missing-=t.byteLength;const e=this._stream.push(t);return 0===this._missing?(this._stream.push(null),e&&this._stream._detach(),e&&!1===this._locked):e}_createStream(){return new EC(this,this._header,this._offset)}_update(){for(;this._buffer.buffered>0&&!this.destroying;){if(this._missing>0){if(null!==this._stream){if(!1===this._consumeStream())return;continue}if(!0===this._longHeader){if(this._missing>this._buffer.buffered)break;if(!1===this._consumeLongHeader())return!1;continue}const t=this._buffer.shiftFirst(this._missing);null!==t&&(this._missing-=t.byteLength);continue}if(this._buffer.buffered<512)break;if(null!==this._stream||!1===this._consumeHeader())return}this._continueWrite(null)}_continueWrite(t){const e=this._callback;this._callback=kC,e(t)}_write(t,e){this._callback=e,this._buffer.push(t),this._update()}_final(t){this._finished=0===this._missing&&0===this._buffer.buffered,t(this._finished?null:new Error("Unexpected end of data"))}_predestroy(){this._continueWrite(null)}_destroy(t){this._stream&&this._stream.destroy(bC(this)),t(null)}[Symbol.asyncIterator](){let t=null,e=null,r=null,n=null,i=null;const o=this;return this.on("entry",function(t,o,s){i=s,o.on("error",kC),e?(e({value:o,done:!1}),e=r=null):n=o}),this.on("error",e=>{t=e}),this.on("close",function(){if(s(t),!e)return;t?r(t):e({value:void 0,done:!0});e=r=null}),{[Symbol.asyncIterator](){return this},next:()=>new Promise(a),return:()=>l(null),throw:t=>l(t)};function s(t){if(!i)return;const e=i;i=null,e(t)}function a(i,a){return t?a(t):n?(i({value:n,done:!1}),void(n=null)):(e=i,r=a,s(null),void(o._finished&&e&&(e({value:void 0,done:!0}),e=r=null)))}function l(t){return o.destroy(t),s(t),new Promise((e,r)=>{if(o.destroyed)return e({value:void 0,done:!0});o.once("close",function(){t?r(t):e({value:void 0,done:!0})})})}}};function kC(){}function TC(t){return(t&=511)&&512-t}var xC={exports:{}};const AC={S_IFMT:61440,S_IFDIR:16384,S_IFCHR:8192,S_IFBLK:24576,S_IFIFO:4096,S_IFLNK:40960};try{xC.exports=require("fs").constants||AC}catch{xC.exports=AC}var OC=xC.exports;const{Readable:LC,Writable:jC,getStreamError:MC}=CD,IC=XD,PC=OC,DC=tC,CC=IC.alloc(1024);class NC extends jC{constructor(t,e,r){super({mapWritable:UC,eagerOpen:!0}),this.written=0,this.header=e,this._callback=r,this._linkname=null,this._isLinkname="symlink"===e.type&&!e.linkname,this._isVoid="file"!==e.type&&"contiguous-file"!==e.type,this._finished=!1,this._pack=t,this._openCallback=null,null===this._pack._stream?this._pack._stream=this:this._pack._pending.push(this)}_open(t){this._openCallback=t,this._pack._stream===this&&this._continueOpen()}_continuePack(t){if(null===this._callback)return;const e=this._callback;this._callback=null,e(t)}_continueOpen(){null===this._pack._stream&&(this._pack._stream=this);const t=this._openCallback;if(this._openCallback=null,null!==t){if(this._pack.destroying)return t(new Error("pack stream destroyed"));if(this._pack._finalized)return t(new Error("pack stream is already finalized"));this._pack._stream=this,this._isLinkname||this._pack._encode(this.header),this._isVoid&&(this._finish(),this._continuePack(null)),t(null)}}_write(t,e){return this._isLinkname?(this._linkname=this._linkname?IC.concat([this._linkname,t]):t,e(null)):this._isVoid?t.byteLength>0?e(new Error("No body allowed for this entry")):e():(this.written+=t.byteLength,this._pack.push(t)?e():void(this._pack._drain=e))}_finish(){this._finished||(this._finished=!0,this._isLinkname&&(this.header.linkname=this._linkname?IC.toString(this._linkname,"utf-8"):"",this._pack._encode(this.header)),WC(this._pack,this.header.size),this._pack._done(this))}_final(t){if(this.written!==this.header.size)return t(new Error("Size mismatch"));this._finish(),t(null)}_getError(){return MC(this)||new Error("tar entry destroyed")}_predestroy(){this._pack.destroy(this._getError())}_destroy(t){this._pack._done(this),this._continuePack(this._finished?null:this._getError()),t()}}class FC extends LC{constructor(t){super(t),this._drain=BC,this._finalized=!1,this._finalizing=!1,this._pending=[],this._stream=null}entry(t,e,r){if(this._finalized||this.destroying)throw new Error("already finalized or destroyed");"function"==typeof e&&(r=e,e=null),r||(r=BC),t.size&&"symlink"!==t.type||(t.size=0),t.type||(t.type=function(t){switch(t&PC.S_IFMT){case PC.S_IFBLK:return"block-device";case PC.S_IFCHR:return"character-device";case PC.S_IFDIR:return"directory";case PC.S_IFIFO:return"fifo";case PC.S_IFLNK:return"symlink"}return"file"}(t.mode)),t.mode||(t.mode="directory"===t.type?493:420),t.uid||(t.uid=0),t.gid||(t.gid=0),t.mtime||(t.mtime=new Date),"string"==typeof e&&(e=IC.from(e));const n=new NC(this,t,r);return IC.isBuffer(e)?(t.size=e.byteLength,n.write(e),n.end(),n):(n._isVoid,n)}finalize(){this._stream||this._pending.length>0?this._finalizing=!0:this._finalized||(this._finalized=!0,this.push(CC),this.push(null))}_done(t){t===this._stream&&(this._stream=null,this._finalizing&&this.finalize(),this._pending.length&&this._pending.shift()._continueOpen())}_encode(t){if(!t.pax){const e=DC.encode(t);if(e)return void this.push(e)}this._encodePax(t)}_encodePax(t){const e=DC.encodePax({name:t.name,linkname:t.linkname,pax:t.pax}),r={name:"PaxHeader",mode:t.mode,uid:t.uid,gid:t.gid,size:e.byteLength,mtime:t.mtime,type:"pax-header",linkname:t.linkname&&"PaxHeader",uname:t.uname,gname:t.gname,devmajor:t.devmajor,devminor:t.devminor};this.push(DC.encode(r)),this.push(e),WC(this,e.byteLength),r.size=t.size,r.type=t.type,this.push(DC.encode(r))}_doDrain(){const t=this._drain;this._drain=BC,t()}_predestroy(){const t=MC(this);for(this._stream&&this._stream.destroy(t);this._pending.length;){const e=this._pending.shift();e.destroy(t),e._continueOpen()}this._doDrain()}_read(t){this._doDrain(),t()}}function BC(){}function WC(t,e){(e&=511)&&t.push(CC.subarray(0,512-e))}function UC(t){return IC.isBuffer(t)?t:IC.from(t)}sP.extract=function(t){return new RC(t)},sP.pack=function(t){return new FC(t)};
47
- /**
48
- * TAR Format Plugin
49
- *
50
- * @module plugins/tar
51
- * @license [MIT]{@link https://github.com/archiverjs/node-archiver/blob/master/LICENSE}
52
- * @copyright (c) 2012-2014 Chris Talkington, contributors.
53
- */
54
- var zC=y,$C=sP,HC=vw,GC=function(t){if(!(this instanceof GC))return new GC(t);"object"!=typeof(t=this.options=HC.defaults(t,{gzip:!1})).gzipOptions&&(t.gzipOptions={}),this.supports={directory:!0,symlink:!0},this.engine=$C.pack(t),this.compressor=!1,t.gzip&&(this.compressor=zC.createGzip(t.gzipOptions),this.compressor.on("error",this._onCompressorError.bind(this)))};GC.prototype._onCompressorError=function(t){this.engine.emit("error",t)},GC.prototype.append=function(t,e,r){var n=this;function i(t,i){t?r(t):n.engine.entry(e,i,function(t){r(t,e)})}if(e.mtime=e.date,"buffer"===e.sourceType)i(null,t);else if("stream"===e.sourceType&&e.stats){e.size=e.stats.size;var o=n.engine.entry(e,function(t){r(t,e)});t.pipe(o)}else"stream"===e.sourceType&&HC.collectStream(t,i)},GC.prototype.finalize=function(){this.engine.finalize()},GC.prototype.on=function(){return this.engine.on.apply(this.engine,arguments)},GC.prototype.pipe=function(t,e){return this.compressor?this.engine.pipe.apply(this.engine,[this.compressor]).pipe(t,e):this.engine.pipe.apply(this.engine,arguments)},GC.prototype.unpipe=function(){return this.compressor?this.compressor.unpipe.apply(this.compressor,arguments):this.engine.unpipe.apply(this.engine,arguments)};var qC=GC;function VC(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}const ZC=new Int32Array([0,1996959894,3993919788,2567524794,124634137,1886057615,3915621685,2657392035,249268274,2044508324,3772115230,2547177864,162941995,2125561021,3887607047,2428444049,498536548,1789927666,4089016648,2227061214,450548861,1843258603,4107580753,2211677639,325883990,1684777152,4251122042,2321926636,335633487,1661365465,4195302755,2366115317,997073096,1281953886,3579855332,2724688242,1006888145,1258607687,3524101629,2768942443,901097722,1119000684,3686517206,2898065728,853044451,1172266101,3705015759,2882616665,651767980,1373503546,3369554304,3218104598,565507253,1454621731,3485111705,3099436303,671266974,1594198024,3322730930,2970347812,795835527,1483230225,3244367275,3060149565,1994146192,31158534,2563907772,4023717930,1907459465,112637215,2680153253,3904427059,2013776290,251722036,2517215374,3775830040,2137656763,141376813,2439277719,3865271297,1802195444,476864866,2238001368,4066508878,1812370925,453092731,2181625025,4111451223,1706088902,314042704,2344532202,4240017532,1658658271,366619977,2362670323,4224994405,1303535960,984961486,2747007092,3569037538,1256170817,1037604311,2765210733,3554079995,1131014506,879679996,2909243462,3663771856,1141124467,855842277,2852801631,3708648649,1342533948,654459306,3188396048,3373015174,1466479909,544179635,3110523913,3462522015,1591671054,702138776,2966460450,3352799412,1504918807,783551873,3082640443,3233442989,3988292384,2596254646,62317068,1957810842,3939845945,2647816111,81470997,1943803523,3814918930,2489596804,225274430,2053790376,3826175755,2466906013,167816743,2097651377,4027552580,2265490386,503444072,1762050814,4150417245,2154129355,426522225,1852507879,4275313526,2312317920,282753626,1742555852,4189708143,2394877945,397917763,1622183637,3604390888,2714866558,953729732,1340076626,3518719985,2797360999,1068828381,1219638859,3624741850,2936675148,906185462,1090812512,3747672003,2825379669,829329135,1181335161,3412177804,3160834842,628085408,1382605366,3423369109,3138078467,570562233,1426400815,3317316542,2998733608,733239954,1555261956,3268935591,3050360625,752459403,1541320221,2607071920,3965973030,1969922972,40735498,2617837225,3943577151,1913087877,83908371,2512341634,3803740692,2075208622,213261112,2463272603,3855990285,2094854071,198958881,2262029012,4057260610,1759359992,534414190,2176718541,4139329115,1873836001,414664567,2282248934,4279200368,1711684554,285281116,2405801727,4167216745,1634467795,376229701,2685067896,3608007406,1308918612,956543938,2808555105,3495958263,1231636301,1047427035,2932959818,3654703836,1088359270,936918e3,2847714899,3736837829,1202900863,817233897,3183342108,3401237130,1404277552,615818150,3134207493,3453421203,1423857449,601450431,3009837614,3294710456,1567103746,711928724,3020668471,3272380065,1510334235,755167117]);function YC(t){if(Buffer.isBuffer(t))return t;if("number"==typeof t)return Buffer.alloc(t);if("string"==typeof t)return Buffer.from(t);throw new Error("input must be buffer, number, or string, received "+typeof t)}function KC(t,e){t=YC(t),Buffer.isBuffer(e)&&(e=e.readUInt32BE(0));let r=-1^e;for(var n=0;n<t.length;n++)r=ZC[255&(r^t[n])]^r>>>8;return-1^r}function QC(){return function(t){const e=YC(4);return e.writeInt32BE(t,0),e}(KC.apply(null,arguments))}QC.signed=function(){return KC.apply(null,arguments)},QC.unsigned=function(){return KC.apply(null,arguments)>>>0};var JC=VC(QC),XC=s.inherits,tN=ix.Transform,eN=JC,rN=vw,nN=function(t){if(!(this instanceof nN))return new nN(t);t=this.options=rN.defaults(t,{}),tN.call(this,t),this.supports={directory:!0,symlink:!0},this.files=[]};
55
- /**
56
- * JSON Format Plugin
57
- *
58
- * @module plugins/json
59
- * @license [MIT]{@link https://github.com/archiverjs/node-archiver/blob/master/LICENSE}
60
- * @copyright (c) 2012-2014 Chris Talkington, contributors.
61
- */XC(nN,tN),nN.prototype._transform=function(t,e,r){r(null,t)},nN.prototype._writeStringified=function(){var t=JSON.stringify(this.files);this.write(t)},nN.prototype.append=function(t,e,r){var n=this;function i(t,i){t?r(t):(e.size=i.length||0,e.crc32=eN.unsigned(i),n.files.push(e),r(null,e))}e.crc32=0,"buffer"===e.sourceType?i(null,t):"stream"===e.sourceType&&rN.collectStream(t,i)},nN.prototype.finalize=function(){this._writeStringified(),this.end()};var iN=nN,oN=yx,sN={},aN=function(t,e){return aN.create(t,e)};
62
- /**
63
- * Archiver Vending
64
- *
65
- * @ignore
66
- * @license [MIT]{@link https://github.com/archiverjs/node-archiver/blob/master/LICENSE}
67
- * @copyright (c) 2012-2014 Chris Talkington, contributors.
68
- */aN.create=function(t,e){if(sN[t]){var r=new oN(t,e);return r.setFormat(t),r.setModule(new sN[t](e)),r}throw new Error("create("+t+"): format not registered")},aN.registerFormat=function(t,e){if(sN[t])throw new Error("register("+t+"): format already registered");if("function"!=typeof e)throw new Error("register("+t+"): format module invalid");if("function"!=typeof e.prototype.append||"function"!=typeof e.prototype.finalize)throw new Error("register("+t+"): format module missing methods");sN[t]=e},aN.isRegisteredFormat=function(t){return!!sN[t]},aN.registerFormat("zip",oP),aN.registerFormat("tar",qC),aN.registerFormat("json",iN);var lN=Bt(aN);const uN=[];for(let t=0;t<256;t++){let e=t;for(let t=0;t<8;t++)1&~e?e>>>=1:e=e>>>1^3988292384;uN[t]=e}const cN=function(t,e){return t>>>8^uN[255&(t^e)]},hN=t=>4294967295&t;function fN(t){this.key=t,Buffer.isBuffer(t)||(this.key=Buffer.from(this.key)),this._init()}fN.prototype._init=function(){this.key0=305419896,this.key1=591751049,this.key2=878082192;for(let t of this.key)this._updateKeys(t)},fN.prototype._updateKeys=function(t){this.key0=cN(this.key0,t),this.key1=hN(this.key1+(255&this.key0)),this.key1=hN(Math.imul(this.key1,134775813)+1),this.key2=cN(this.key2,this.key1>>>24)},fN.prototype._streamByte=function(){let t=2|this.key2;return 255&Math.imul(t,1^t)>>>8},fN.prototype._encryptByte=function(t){let e=this._streamByte()^t;return this._updateKeys(t),e},fN.prototype._decryptByte=function(t){let e=this._streamByte()^t;return this._updateKeys(e),e},fN.prototype.encrypt=function(t){let e=Buffer.alloc(Buffer.byteLength(t)),r=0;for(let n of t)e.writeUInt8(this._encryptByte(n),r++);return e},fN.prototype.decrypt=function(t){let e=Buffer.alloc(Buffer.byteLength(t)),r=0;for(let n of t)e.writeUInt8(this._decryptByte(n),r++);return e};var dN=fN;const pN=s.inherits,{Transform:yN}=i,gN=g,bN=dN;function mN(t={key:null,crc:null,transformOptions:{}}){if(!(this instanceof mN))return new mN(t);yN.call(this,t),this.key=t.key,this.crc=t.crc,this.cipher=new bN(this.key),this.headerSent=!1}pN(mN,yN),mN.prototype._encrypt=function(t){return this.cipher.encrypt(t)},mN.prototype._transform=function(t,e,r){if(!this.headerSent){let t=gN.randomBytes(12);t.writeUInt16LE(this.crc.readUInt16BE(0),10);let e=this._encrypt(t);this.push(e),this.headerSent=!0}let n=this._encrypt(t);n.length>0&&this.push(n),r()};var _N=mN,vN={exports:{}},wN={exports:{}},SN=wN.exports=function(){};SN.prototype.getName=function(){},SN.prototype.getSize=function(){},SN.prototype.getLastModifiedDate=function(){},SN.prototype.isDirectory=function(){};var EN=wN.exports,RN={exports:{}},kN={exports:{}},TN={exports:{}},xN=TN.exports={};xN.dateToDos=function(t,e){var r=(e=e||!1)?t.getFullYear():t.getUTCFullYear();return r<1980?2162688:r>=2044?2141175677:r-1980<<25|(e?t.getMonth():t.getUTCMonth())+1<<21|(e?t.getDate():t.getUTCDate())<<16|(e?t.getHours():t.getUTCHours())<<11|(e?t.getMinutes():t.getUTCMinutes())<<5|(e?t.getSeconds():t.getUTCSeconds())/2},xN.dosToDate=function(t){return new Date(1980+(t>>25&127),(t>>21&15)-1,t>>16&31,t>>11&31,t>>5&63,(31&t)<<1)},xN.fromDosTime=function(t){return xN.dosToDate(t.readUInt32LE(0))},xN.getEightBytes=function(t){var e=Buffer.alloc(8);return e.writeUInt32LE(t%4294967296,0),e.writeUInt32LE(t/4294967296|0,4),e},xN.getShortBytes=function(t){var e=Buffer.alloc(2);return e.writeUInt16LE((65535&t)>>>0,0),e},xN.getShortBytesValue=function(t,e){return t.readUInt16LE(e)},xN.getLongBytes=function(t){var e=Buffer.alloc(4);return e.writeUInt32LE((4294967295&t)>>>0,0),e},xN.getLongBytesValue=function(t,e){return t.readUInt32LE(e)},xN.toDosTime=function(t){return xN.getLongBytes(xN.dateToDos(t))};var AN=TN.exports,ON=AN,LN=kN.exports=function(){return this instanceof LN?(this.descriptor=!1,this.encryption=!1,this.utf8=!1,this.numberOfShannonFanoTrees=0,this.strongEncryption=!1,this.slidingDictionarySize=0,this):new LN};LN.prototype.encode=function(){return ON.getShortBytes((this.descriptor?8:0)|(this.utf8?2048:0)|(this.encryption?1:0)|(this.strongEncryption?64:0))},LN.prototype.parse=function(t,e){var r=ON.getShortBytesValue(t,e),n=new LN;return n.useDataDescriptor(!!(8&r)),n.useUTF8ForNames(!!(2048&r)),n.useStrongEncryption(!!(64&r)),n.useEncryption(!!(1&r)),n.setSlidingDictionarySize(2&r?8192:4096),n.setNumberOfShannonFanoTrees(4&r?3:2),n},LN.prototype.setNumberOfShannonFanoTrees=function(t){this.numberOfShannonFanoTrees=t},LN.prototype.getNumberOfShannonFanoTrees=function(){return this.numberOfShannonFanoTrees},LN.prototype.setSlidingDictionarySize=function(t){this.slidingDictionarySize=t},LN.prototype.getSlidingDictionarySize=function(){return this.slidingDictionarySize},LN.prototype.useDataDescriptor=function(t){this.descriptor=t},LN.prototype.usesDataDescriptor=function(){return this.descriptor},LN.prototype.useEncryption=function(t){this.encryption=t},LN.prototype.usesEncryption=function(){return this.encryption},LN.prototype.useStrongEncryption=function(t){this.strongEncryption=t},LN.prototype.usesStrongEncryption=function(){return this.strongEncryption},LN.prototype.useUTF8ForNames=function(t){this.utf8=t},LN.prototype.usesUTF8ForNames=function(){return this.utf8};var jN=kN.exports,MN={WORD:4,DWORD:8,EMPTY:Buffer.alloc(0),SHORT:2,SHORT_MASK:65535,SHORT_SHIFT:16,SHORT_ZERO:Buffer.from(Array(2)),LONG:4,LONG_ZERO:Buffer.from(Array(4)),MIN_VERSION_INITIAL:10,MIN_VERSION_DATA_DESCRIPTOR:20,MIN_VERSION_ZIP64:45,VERSION_MADEBY:45,METHOD_STORED:0,METHOD_DEFLATED:8,PLATFORM_UNIX:3,PLATFORM_FAT:0,SIG_LFH:67324752,SIG_DD:134695760,SIG_CFH:33639248,SIG_EOCD:101010256,SIG_ZIP64_EOCD:101075792,SIG_ZIP64_EOCD_LOC:117853008,ZIP64_MAGIC_SHORT:65535,ZIP64_MAGIC:4294967295,ZIP64_EXTRA_ID:1,ZLIB_NO_COMPRESSION:0,ZLIB_BEST_SPEED:1,ZLIB_BEST_COMPRESSION:9,ZLIB_DEFAULT_COMPRESSION:-1,MODE_MASK:4095,DEFAULT_FILE_MODE:33188,DEFAULT_DIR_MODE:16877,EXT_FILE_ATTR_DIR:1106051088,EXT_FILE_ATTR_FILE:2175008800,S_IFMT:61440,S_IFIFO:4096,S_IFCHR:8192,S_IFDIR:16384,S_IFBLK:24576,S_IFREG:32768,S_IFLNK:40960,S_IFSOCK:49152,S_DOS_A:32,S_DOS_D:16,S_DOS_V:8,S_DOS_S:4,S_DOS_H:2,S_DOS_R:1},IN=s.inherits,PN=fl,DN=EN,CN=jN,NN={PERM_MASK:4095,FILE_TYPE_FLAG:61440,LINK_FLAG:40960,FILE_FLAG:32768,DIR_FLAG:16384,DEFAULT_LINK_PERM:511,DEFAULT_DIR_PERM:493,DEFAULT_FILE_PERM:420},FN=MN,BN=AN,WN=RN.exports=function(t){if(!(this instanceof WN))return new WN(t);DN.call(this),this.platform=FN.PLATFORM_FAT,this.method=-1,this.name=null,this.size=0,this.csize=0,this.gpb=new CN,this.crc=0,this.time=-1,this.minver=FN.MIN_VERSION_INITIAL,this.mode=-1,this.extra=null,this.exattr=0,this.inattr=0,this.comment=null,t&&this.setName(t)};IN(WN,DN),WN.prototype.getCentralDirectoryExtra=function(){return this.getExtra()},WN.prototype.getComment=function(){return null!==this.comment?this.comment:""},WN.prototype.getCompressedSize=function(){return this.csize},WN.prototype.getCrc=function(){return this.crc},WN.prototype.getExternalAttributes=function(){return this.exattr},WN.prototype.getExtra=function(){return null!==this.extra?this.extra:FN.EMPTY},WN.prototype.getGeneralPurposeBit=function(){return this.gpb},WN.prototype.getInternalAttributes=function(){return this.inattr},WN.prototype.getLastModifiedDate=function(){return this.getTime()},WN.prototype.getLocalFileDataExtra=function(){return this.getExtra()},WN.prototype.getMethod=function(){return this.method},WN.prototype.getName=function(){return this.name},WN.prototype.getPlatform=function(){return this.platform},WN.prototype.getSize=function(){return this.size},WN.prototype.getTime=function(){return-1!==this.time?BN.dosToDate(this.time):-1},WN.prototype.getTimeDos=function(){return-1!==this.time?this.time:0},WN.prototype.getUnixMode=function(){return this.platform!==FN.PLATFORM_UNIX?0:this.getExternalAttributes()>>FN.SHORT_SHIFT&FN.SHORT_MASK},WN.prototype.getVersionNeededToExtract=function(){return this.minver},WN.prototype.setComment=function(t){Buffer.byteLength(t)!==t.length&&this.getGeneralPurposeBit().useUTF8ForNames(!0),this.comment=t},WN.prototype.setCompressedSize=function(t){if(t<0)throw new Error("invalid entry compressed size");this.csize=t},WN.prototype.setCrc=function(t){if(t<0)throw new Error("invalid entry crc32");this.crc=t},WN.prototype.setExternalAttributes=function(t){this.exattr=t>>>0},WN.prototype.setExtra=function(t){this.extra=t},WN.prototype.setGeneralPurposeBit=function(t){if(!(t instanceof CN))throw new Error("invalid entry GeneralPurposeBit");this.gpb=t},WN.prototype.setInternalAttributes=function(t){this.inattr=t},WN.prototype.setMethod=function(t){if(t<0)throw new Error("invalid entry compression method");this.method=t},WN.prototype.setName=function(t,e=!1){t=PN(t,!1).replace(/^\w+:/,"").replace(/^(\.\.\/|\/)+/,""),e&&(t=`/${t}`),Buffer.byteLength(t)!==t.length&&this.getGeneralPurposeBit().useUTF8ForNames(!0),this.name=t},WN.prototype.setPlatform=function(t){this.platform=t},WN.prototype.setSize=function(t){if(t<0)throw new Error("invalid entry size");this.size=t},WN.prototype.setTime=function(t,e){if(!(t instanceof Date))throw new Error("invalid entry time");this.time=BN.dateToDos(t,e)},WN.prototype.setUnixMode=function(t){var e=0;e|=(t|=this.isDirectory()?FN.S_IFDIR:FN.S_IFREG)<<FN.SHORT_SHIFT|(this.isDirectory()?FN.S_DOS_D:FN.S_DOS_A),this.setExternalAttributes(e),this.mode=t&FN.MODE_MASK,this.platform=FN.PLATFORM_UNIX},WN.prototype.setVersionNeededToExtract=function(t){this.minver=t},WN.prototype.isDirectory=function(){return"/"===this.getName().slice(-1)},WN.prototype.isUnixSymlink=function(){return(this.getUnixMode()&NN.FILE_TYPE_FLAG)===NN.LINK_FLAG},WN.prototype.isZip64=function(){return this.csize>FN.ZIP64_MAGIC||this.size>FN.ZIP64_MAGIC};var UN,zN,$N,HN,GN=RN.exports,qN={exports:{}},VN={exports:{}};function ZN(){return zN?UN:(zN=1,UN=yn.EventEmitter)}function YN(){if(HN)return $N;function t(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),r.push.apply(r,n)}return r}function e(e){for(var n=1;n<arguments.length;n++){var i=null!=arguments[n]?arguments[n]:{};n%2?t(Object(i),!0).forEach(function(t){r(e,t,i[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):t(Object(i)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))})}return e}function r(t,e,r){return(e=i(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function n(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,i(n.key),n)}}function i(t){var e=function(t,e){if("object"!=typeof t||null===t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var n=r.call(t,e||"default");if("object"!=typeof n)return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"==typeof e?e:String(e)}HN=1;var o=ca.Buffer,s=Na.inspect,a=s&&s.custom||"inspect";function l(t,e,r){o.prototype.copy.call(t,e,r)}return $N=function(){function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.head=null,this.tail=null,this.length=0}var r,i,u;return r=t,i=[{key:"push",value:function(t){var e={data:t,next:null};this.length>0?this.tail.next=e:this.head=e,this.tail=e,++this.length}},{key:"unshift",value:function(t){var e={data:t,next:this.head};0===this.length&&(this.tail=e),this.head=e,++this.length}},{key:"shift",value:function(){if(0!==this.length){var t=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,t}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(t){if(0===this.length)return"";for(var e=this.head,r=""+e.data;e=e.next;)r+=t+e.data;return r}},{key:"concat",value:function(t){if(0===this.length)return o.alloc(0);for(var e=o.allocUnsafe(t>>>0),r=this.head,n=0;r;)l(r.data,e,n),n+=r.data.length,r=r.next;return e}},{key:"consume",value:function(t,e){var r;return t<this.head.data.length?(r=this.head.data.slice(0,t),this.head.data=this.head.data.slice(t)):r=t===this.head.data.length?this.shift():e?this._getString(t):this._getBuffer(t),r}},{key:"first",value:function(){return this.head.data}},{key:"_getString",value:function(t){var e=this.head,r=1,n=e.data;for(t-=n.length;e=e.next;){var i=e.data,o=t>i.length?i.length:t;if(o===i.length?n+=i:n+=i.slice(0,t),0===(t-=o)){o===i.length?(++r,e.next?this.head=e.next:this.head=this.tail=null):(this.head=e,e.data=i.slice(o));break}++r}return this.length-=r,n}},{key:"_getBuffer",value:function(t){var e=o.allocUnsafe(t),r=this.head,n=1;for(r.data.copy(e),t-=r.data.length;r=r.next;){var i=r.data,s=t>i.length?i.length:t;if(i.copy(e,e.length-t,0,s),0===(t-=s)){s===i.length?(++n,r.next?this.head=r.next:this.head=this.tail=null):(this.head=r,r.data=i.slice(s));break}++n}return this.length-=n,e}},{key:a,value:function(t,r){return s(this,e(e({},r),{},{depth:0,customInspect:!1}))}}],i&&n(r.prototype,i),u&&n(r,u),Object.defineProperty(r,"prototype",{writable:!1}),t}(),$N}function KN(t,e){JN(t,e),QN(t)}function QN(t){t._writableState&&!t._writableState.emitClose||t._readableState&&!t._readableState.emitClose||t.emit("close")}function JN(t,e){t.emit("error",e)}var XN={destroy:function(t,e){var r=this,n=this._readableState&&this._readableState.destroyed,i=this._writableState&&this._writableState.destroyed;return n||i?(e?e(t):t&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,process.nextTick(JN,this,t)):process.nextTick(JN,this,t)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(t||null,function(t){!e&&t?r._writableState?r._writableState.errorEmitted?process.nextTick(QN,r):(r._writableState.errorEmitted=!0,process.nextTick(KN,r,t)):process.nextTick(KN,r,t):e?(process.nextTick(QN,r),e(t)):process.nextTick(QN,r)}),this)},undestroy:function(){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)},errorOrDestroy:function(t,e){var r=t._readableState,n=t._writableState;r&&r.autoDestroy||n&&n.autoDestroy?t.destroy(e):t.emit("error",e)}},tF={};var eF={};function rF(t,e,r){r||(r=Error);var n=function(t){var r,n;function i(r,n,i){return t.call(this,function(t,r,n){return"string"==typeof e?e:e(t,r,n)}(r,n,i))||this}return n=t,(r=i).prototype=Object.create(n.prototype),r.prototype.constructor=r,r.__proto__=n,i}(r);n.prototype.name=r.name,n.prototype.code=t,eF[t]=n}function nF(t,e){if(Array.isArray(t)){var r=t.length;return t=t.map(function(t){return String(t)}),r>2?"one of ".concat(e," ").concat(t.slice(0,r-1).join(", "),", or ")+t[r-1]:2===r?"one of ".concat(e," ").concat(t[0]," or ").concat(t[1]):"of ".concat(e," ").concat(t[0])}return"of ".concat(e," ").concat(String(t))}rF("ERR_INVALID_OPT_VALUE",function(t,e){return'The value "'+e+'" is invalid for option "'+t+'"'},TypeError),rF("ERR_INVALID_ARG_TYPE",function(t,e,r){var n,i,o,s;if("string"==typeof e&&(i="not ",e.substr(!o||o<0?0:+o,i.length)===i)?(n="must not be",e=e.replace(/^not /,"")):n="must be",function(t,e,r){return(void 0===r||r>t.length)&&(r=t.length),t.substring(r-e.length,r)===e}(t," argument"))s="The ".concat(t," ").concat(n," ").concat(nF(e,"type"));else{var a=function(t,e,r){return"number"!=typeof r&&(r=0),!(r+e.length>t.length)&&-1!==t.indexOf(e,r)}(t,".")?"property":"argument";s='The "'.concat(t,'" ').concat(a," ").concat(n," ").concat(nF(e,"type"))}return s+=". Received type ".concat(typeof r)},TypeError),rF("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),rF("ERR_METHOD_NOT_IMPLEMENTED",function(t){return"The "+t+" method is not implemented"}),rF("ERR_STREAM_PREMATURE_CLOSE","Premature close"),rF("ERR_STREAM_DESTROYED",function(t){return"Cannot call "+t+" after a stream was destroyed"}),rF("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),rF("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),rF("ERR_STREAM_WRITE_AFTER_END","write after end"),rF("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),rF("ERR_UNKNOWN_ENCODING",function(t){return"Unknown encoding: "+t},TypeError),rF("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),tF.codes=eF;var iF=tF.codes.ERR_INVALID_OPT_VALUE;var oF,sF,aF,lF,uF={getHighWaterMark:function(t,e,r,n){var i=function(t,e,r){return null!=t.highWaterMark?t.highWaterMark:e?t[r]:null}(e,n,r);if(null!=i){if(!isFinite(i)||Math.floor(i)!==i||i<0)throw new iF(n?r:"highWaterMark",i);return Math.floor(i)}return t.objectMode?16:16384}};function cF(){if(sF)return oF;function t(t){var e=this;this.next=null,this.entry=null,this.finish=function(){!function(t,e,r){var n=t.entry;t.entry=null;for(;n;){var i=n.callback;e.pendingcb--,i(r),n=n.next}e.corkedRequestsFree.next=t}(e,t)}}var e;sF=1,oF=w,w.WritableState=v;var r={deprecate:Ua()},n=ZN(),i=ca.Buffer,o=(void 0!==Ft?Ft:"undefined"!=typeof window?window:"undefined"!=typeof self?self:{}).Uint8Array||function(){};var s,a=XN,l=uF.getHighWaterMark,u=tF.codes,c=u.ERR_INVALID_ARG_TYPE,h=u.ERR_METHOD_NOT_IMPLEMENTED,f=u.ERR_MULTIPLE_CALLBACK,d=u.ERR_STREAM_CANNOT_PIPE,p=u.ERR_STREAM_DESTROYED,y=u.ERR_STREAM_NULL_VALUES,g=u.ERR_STREAM_WRITE_AFTER_END,b=u.ERR_UNKNOWN_ENCODING,m=a.errorOrDestroy;function _(){}function v(r,n,i){e=e||hF(),r=r||{},"boolean"!=typeof i&&(i=n instanceof e),this.objectMode=!!r.objectMode,i&&(this.objectMode=this.objectMode||!!r.writableObjectMode),this.highWaterMark=l(this,r,"writableHighWaterMark",i),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var o=!1===r.decodeStrings;this.decodeStrings=!o,this.defaultEncoding=r.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(t){!function(t,e){var r=t._writableState,n=r.sync,i=r.writecb;if("function"!=typeof i)throw new f;if(function(t){t.writing=!1,t.writecb=null,t.length-=t.writelen,t.writelen=0}(r),e)!function(t,e,r,n,i){--e.pendingcb,r?(process.nextTick(i,n),process.nextTick(x,t,e),t._writableState.errorEmitted=!0,m(t,n)):(i(n),t._writableState.errorEmitted=!0,m(t,n),x(t,e))}(t,r,n,e,i);else{var o=k(r)||t.destroyed;o||r.corked||r.bufferProcessing||!r.bufferedRequest||R(t,r),n?process.nextTick(E,t,r,o,i):E(t,r,o,i)}}(n,t)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=!1!==r.emitClose,this.autoDestroy=!!r.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new t(this)}function w(t){var r=this instanceof(e=e||hF());if(!r&&!s.call(w,this))return new w(t);this._writableState=new v(t,this,r),this.writable=!0,t&&("function"==typeof t.write&&(this._write=t.write),"function"==typeof t.writev&&(this._writev=t.writev),"function"==typeof t.destroy&&(this._destroy=t.destroy),"function"==typeof t.final&&(this._final=t.final)),n.call(this)}function S(t,e,r,n,i,o,s){e.writelen=n,e.writecb=s,e.writing=!0,e.sync=!0,e.destroyed?e.onwrite(new p("write")):r?t._writev(i,e.onwrite):t._write(i,o,e.onwrite),e.sync=!1}function E(t,e,r,n){r||function(t,e){0===e.length&&e.needDrain&&(e.needDrain=!1,t.emit("drain"))}(t,e),e.pendingcb--,n(),x(t,e)}function R(e,r){r.bufferProcessing=!0;var n=r.bufferedRequest;if(e._writev&&n&&n.next){var i=r.bufferedRequestCount,o=new Array(i),s=r.corkedRequestsFree;s.entry=n;for(var a=0,l=!0;n;)o[a]=n,n.isBuf||(l=!1),n=n.next,a+=1;o.allBuffers=l,S(e,r,!0,r.length,o,"",s.finish),r.pendingcb++,r.lastBufferedRequest=null,s.next?(r.corkedRequestsFree=s.next,s.next=null):r.corkedRequestsFree=new t(r),r.bufferedRequestCount=0}else{for(;n;){var u=n.chunk,c=n.encoding,h=n.callback;if(S(e,r,!1,r.objectMode?1:u.length,u,c,h),n=n.next,r.bufferedRequestCount--,r.writing)break}null===n&&(r.lastBufferedRequest=null)}r.bufferedRequest=n,r.bufferProcessing=!1}function k(t){return t.ending&&0===t.length&&null===t.bufferedRequest&&!t.finished&&!t.writing}function T(t,e){t._final(function(r){e.pendingcb--,r&&m(t,r),e.prefinished=!0,t.emit("prefinish"),x(t,e)})}function x(t,e){var r=k(e);if(r&&(function(t,e){e.prefinished||e.finalCalled||("function"!=typeof t._final||e.destroyed?(e.prefinished=!0,t.emit("prefinish")):(e.pendingcb++,e.finalCalled=!0,process.nextTick(T,t,e)))}(t,e),0===e.pendingcb&&(e.finished=!0,t.emit("finish"),e.autoDestroy))){var n=t._readableState;(!n||n.autoDestroy&&n.endEmitted)&&t.destroy()}return r}return Ca(w,n),v.prototype.getBuffer=function(){for(var t=this.bufferedRequest,e=[];t;)e.push(t),t=t.next;return e},function(){try{Object.defineProperty(v.prototype,"buffer",{get:r.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(t){}}(),"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(s=Function.prototype[Symbol.hasInstance],Object.defineProperty(w,Symbol.hasInstance,{value:function(t){return!!s.call(this,t)||this===w&&(t&&t._writableState instanceof v)}})):s=function(t){return t instanceof this},w.prototype.pipe=function(){m(this,new d)},w.prototype.write=function(t,e,r){var n,s=this._writableState,a=!1,l=!s.objectMode&&(n=t,i.isBuffer(n)||n instanceof o);return l&&!i.isBuffer(t)&&(t=function(t){return i.from(t)}(t)),"function"==typeof e&&(r=e,e=null),l?e="buffer":e||(e=s.defaultEncoding),"function"!=typeof r&&(r=_),s.ending?function(t,e){var r=new g;m(t,r),process.nextTick(e,r)}(this,r):(l||function(t,e,r,n){var i;return null===r?i=new y:"string"==typeof r||e.objectMode||(i=new c("chunk",["string","Buffer"],r)),!i||(m(t,i),process.nextTick(n,i),!1)}(this,s,t,r))&&(s.pendingcb++,a=function(t,e,r,n,o,s){if(!r){var a=function(t,e,r){t.objectMode||!1===t.decodeStrings||"string"!=typeof e||(e=i.from(e,r));return e}(e,n,o);n!==a&&(r=!0,o="buffer",n=a)}var l=e.objectMode?1:n.length;e.length+=l;var u=e.length<e.highWaterMark;u||(e.needDrain=!0);if(e.writing||e.corked){var c=e.lastBufferedRequest;e.lastBufferedRequest={chunk:n,encoding:o,isBuf:r,callback:s,next:null},c?c.next=e.lastBufferedRequest:e.bufferedRequest=e.lastBufferedRequest,e.bufferedRequestCount+=1}else S(t,e,!1,l,n,o,s);return u}(this,s,l,t,e,r)),a},w.prototype.cork=function(){this._writableState.corked++},w.prototype.uncork=function(){var t=this._writableState;t.corked&&(t.corked--,t.writing||t.corked||t.bufferProcessing||!t.bufferedRequest||R(this,t))},w.prototype.setDefaultEncoding=function(t){if("string"==typeof t&&(t=t.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((t+"").toLowerCase())>-1))throw new b(t);return this._writableState.defaultEncoding=t,this},Object.defineProperty(w.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(w.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),w.prototype._write=function(t,e,r){r(new h("_write()"))},w.prototype._writev=null,w.prototype.end=function(t,e,r){var n=this._writableState;return"function"==typeof t?(r=t,t=null,e=null):"function"==typeof e&&(r=e,e=null),null!=t&&this.write(t,e),n.corked&&(n.corked=1,this.uncork()),n.ending||function(t,e,r){e.ending=!0,x(t,e),r&&(e.finished?process.nextTick(r):t.once("finish",r));e.ended=!0,t.writable=!1}(this,n,r),this},Object.defineProperty(w.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(w.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(t){this._writableState&&(this._writableState.destroyed=t)}}),w.prototype.destroy=a.destroy,w.prototype._undestroy=a.undestroy,w.prototype._destroy=function(t,e){e(t)},oF}function hF(){if(lF)return aF;lF=1;var t=Object.keys||function(t){var e=[];for(var r in t)e.push(r);return e};aF=s;var e=SF(),r=cF();Ca(s,e);for(var n=t(r.prototype),i=0;i<n.length;i++){var o=n[i];s.prototype[o]||(s.prototype[o]=r.prototype[o])}function s(t){if(!(this instanceof s))return new s(t);e.call(this,t),r.call(this,t),this.allowHalfOpen=!0,t&&(!1===t.readable&&(this.readable=!1),!1===t.writable&&(this.writable=!1),!1===t.allowHalfOpen&&(this.allowHalfOpen=!1,this.once("end",a)))}function a(){this._writableState.ended||process.nextTick(l,this)}function l(t){t.end()}return Object.defineProperty(s.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(s.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(s.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(s.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed&&this._writableState.destroyed)},set:function(t){void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed=t,this._writableState.destroyed=t)}}),aF}var fF=tF.codes.ERR_STREAM_PREMATURE_CLOSE;function dF(){}var pF,yF,gF,bF,mF,_F,vF=function t(e,r,n){if("function"==typeof r)return t(e,null,r);r||(r={}),n=function(t){var e=!1;return function(){if(!e){e=!0;for(var r=arguments.length,n=new Array(r),i=0;i<r;i++)n[i]=arguments[i];t.apply(this,n)}}}(n||dF);var i=r.readable||!1!==r.readable&&e.readable,o=r.writable||!1!==r.writable&&e.writable,s=function(){e.writable||l()},a=e._writableState&&e._writableState.finished,l=function(){o=!1,a=!0,i||n.call(e)},u=e._readableState&&e._readableState.endEmitted,c=function(){i=!1,u=!0,o||n.call(e)},h=function(t){n.call(e,t)},f=function(){var t;return i&&!u?(e._readableState&&e._readableState.ended||(t=new fF),n.call(e,t)):o&&!a?(e._writableState&&e._writableState.ended||(t=new fF),n.call(e,t)):void 0},d=function(){e.req.on("finish",l)};return!function(t){return t.setHeader&&"function"==typeof t.abort}(e)?o&&!e._writableState&&(e.on("end",s),e.on("close",s)):(e.on("complete",l),e.on("abort",f),e.req?d():e.on("request",d)),e.on("end",c),e.on("finish",l),!1!==r.error&&e.on("error",h),e.on("close",f),function(){e.removeListener("complete",l),e.removeListener("abort",f),e.removeListener("request",d),e.req&&e.req.removeListener("finish",l),e.removeListener("end",s),e.removeListener("close",s),e.removeListener("finish",l),e.removeListener("end",c),e.removeListener("error",h),e.removeListener("close",f)}};function wF(){if(yF)return pF;var t;function e(t,e,r){return(e=function(t){var e=function(t,e){if("object"!=typeof t||null===t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var n=r.call(t,e||"default");if("object"!=typeof n)return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"==typeof e?e:String(e)}(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}yF=1;var r=vF,n=Symbol("lastResolve"),i=Symbol("lastReject"),o=Symbol("error"),s=Symbol("ended"),a=Symbol("lastPromise"),l=Symbol("handlePromise"),u=Symbol("stream");function c(t,e){return{value:t,done:e}}function h(t){var e=t[n];if(null!==e){var r=t[u].read();null!==r&&(t[a]=null,t[n]=null,t[i]=null,e(c(r,!1)))}}function f(t){process.nextTick(h,t)}var d=Object.getPrototypeOf(function(){}),p=Object.setPrototypeOf((t={get stream(){return this[u]},next:function(){var t=this,e=this[o];if(null!==e)return Promise.reject(e);if(this[s])return Promise.resolve(c(void 0,!0));if(this[u].destroyed)return new Promise(function(e,r){process.nextTick(function(){t[o]?r(t[o]):e(c(void 0,!0))})});var r,n=this[a];if(n)r=new Promise(function(t,e){return function(r,n){t.then(function(){e[s]?r(c(void 0,!0)):e[l](r,n)},n)}}(n,this));else{var i=this[u].read();if(null!==i)return Promise.resolve(c(i,!1));r=new Promise(this[l])}return this[a]=r,r}},e(t,Symbol.asyncIterator,function(){return this}),e(t,"return",function(){var t=this;return new Promise(function(e,r){t[u].destroy(null,function(t){t?r(t):e(c(void 0,!0))})})}),t),d);return pF=function(t){var h,d=Object.create(p,(e(h={},u,{value:t,writable:!0}),e(h,n,{value:null,writable:!0}),e(h,i,{value:null,writable:!0}),e(h,o,{value:null,writable:!0}),e(h,s,{value:t._readableState.endEmitted,writable:!0}),e(h,l,{value:function(t,e){var r=d[u].read();r?(d[a]=null,d[n]=null,d[i]=null,t(c(r,!1))):(d[n]=t,d[i]=e)},writable:!0}),h));return d[a]=null,r(t,function(t){if(t&&"ERR_STREAM_PREMATURE_CLOSE"!==t.code){var e=d[i];return null!==e&&(d[a]=null,d[n]=null,d[i]=null,e(t)),void(d[o]=t)}var r=d[n];null!==r&&(d[a]=null,d[n]=null,d[i]=null,r(c(void 0,!0))),d[s]=!0}),t.on("readable",f.bind(null,d)),d},pF}function SF(){if(_F)return mF;var t;_F=1,mF=w,w.ReadableState=v,yn.EventEmitter;var e=function(t,e){return t.listeners(e).length},r=ZN(),n=ca.Buffer,i=(void 0!==Ft?Ft:"undefined"!=typeof window?window:"undefined"!=typeof self?self:{}).Uint8Array||function(){};var o,s=Na;o=s&&s.debuglog?s.debuglog("stream"):function(){};var a,l,u,c=YN(),h=XN,f=uF.getHighWaterMark,d=tF.codes,p=d.ERR_INVALID_ARG_TYPE,y=d.ERR_STREAM_PUSH_AFTER_EOF,g=d.ERR_METHOD_NOT_IMPLEMENTED,b=d.ERR_STREAM_UNSHIFT_AFTER_END_EVENT;Ca(w,r);var m=h.errorOrDestroy,_=["error","close","destroy","pause","resume"];function v(e,r,n){t=t||hF(),e=e||{},"boolean"!=typeof n&&(n=r instanceof t),this.objectMode=!!e.objectMode,n&&(this.objectMode=this.objectMode||!!e.readableObjectMode),this.highWaterMark=f(this,e,"readableHighWaterMark",n),this.buffer=new c,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=!1!==e.emitClose,this.autoDestroy=!!e.autoDestroy,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(a||(a=el().StringDecoder),this.decoder=new a(e.encoding),this.encoding=e.encoding)}function w(e){if(t=t||hF(),!(this instanceof w))return new w(e);var n=this instanceof t;this._readableState=new v(e,this,n),this.readable=!0,e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy&&(this._destroy=e.destroy)),r.call(this)}function S(t,e,r,s,a){o("readableAddChunk",e);var l,u=t._readableState;if(null===e)u.reading=!1,function(t,e){if(o("onEofChunk"),e.ended)return;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?T(t):(e.needReadable=!1,e.emittedReadable||(e.emittedReadable=!0,x(t)))}(t,u);else if(a||(l=function(t,e){var r;o=e,n.isBuffer(o)||o instanceof i||"string"==typeof e||void 0===e||t.objectMode||(r=new p("chunk",["string","Buffer","Uint8Array"],e));var o;return r}(u,e)),l)m(t,l);else if(u.objectMode||e&&e.length>0)if("string"==typeof e||u.objectMode||Object.getPrototypeOf(e)===n.prototype||(e=function(t){return n.from(t)}(e)),s)u.endEmitted?m(t,new b):E(t,u,e,!0);else if(u.ended)m(t,new y);else{if(u.destroyed)return!1;u.reading=!1,u.decoder&&!r?(e=u.decoder.write(e),u.objectMode||0!==e.length?E(t,u,e,!1):A(t,u)):E(t,u,e,!1)}else s||(u.reading=!1,A(t,u));return!u.ended&&(u.length<u.highWaterMark||0===u.length)}function E(t,e,r,n){e.flowing&&0===e.length&&!e.sync?(e.awaitDrain=0,t.emit("data",r)):(e.length+=e.objectMode?1:r.length,n?e.buffer.unshift(r):e.buffer.push(r),e.needReadable&&T(t)),A(t,e)}Object.defineProperty(w.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._readableState&&this._readableState.destroyed},set:function(t){this._readableState&&(this._readableState.destroyed=t)}}),w.prototype.destroy=h.destroy,w.prototype._undestroy=h.undestroy,w.prototype._destroy=function(t,e){e(t)},w.prototype.push=function(t,e){var r,i=this._readableState;return i.objectMode?r=!0:"string"==typeof t&&((e=e||i.defaultEncoding)!==i.encoding&&(t=n.from(t,e),e=""),r=!0),S(this,t,e,!1,r)},w.prototype.unshift=function(t){return S(this,t,null,!0,!1)},w.prototype.isPaused=function(){return!1===this._readableState.flowing},w.prototype.setEncoding=function(t){a||(a=el().StringDecoder);var e=new a(t);this._readableState.decoder=e,this._readableState.encoding=this._readableState.decoder.encoding;for(var r=this._readableState.buffer.head,n="";null!==r;)n+=e.write(r.data),r=r.next;return this._readableState.buffer.clear(),""!==n&&this._readableState.buffer.push(n),this._readableState.length=n.length,this};var R=1073741824;function k(t,e){return t<=0||0===e.length&&e.ended?0:e.objectMode?1:t!=t?e.flowing&&e.length?e.buffer.head.data.length:e.length:(t>e.highWaterMark&&(e.highWaterMark=function(t){return t>=R?t=R:(t--,t|=t>>>1,t|=t>>>2,t|=t>>>4,t|=t>>>8,t|=t>>>16,t++),t}(t)),t<=e.length?t:e.ended?e.length:(e.needReadable=!0,0))}function T(t){var e=t._readableState;o("emitReadable",e.needReadable,e.emittedReadable),e.needReadable=!1,e.emittedReadable||(o("emitReadable",e.flowing),e.emittedReadable=!0,process.nextTick(x,t))}function x(t){var e=t._readableState;o("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,I(t)}function A(t,e){e.readingMore||(e.readingMore=!0,process.nextTick(O,t,e))}function O(t,e){for(;!e.reading&&!e.ended&&(e.length<e.highWaterMark||e.flowing&&0===e.length);){var r=e.length;if(o("maybeReadMore read 0"),t.read(0),r===e.length)break}e.readingMore=!1}function L(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 j(t){o("readable nexttick read 0"),t.read(0)}function M(t,e){o("resume",e.reading),e.reading||t.read(0),e.resumeScheduled=!1,t.emit("resume"),I(t),e.flowing&&!e.reading&&t.read(0)}function I(t){var e=t._readableState;for(o("flow",e.flowing);e.flowing&&null!==t.read(););}function P(t,e){return 0===e.length?null:(e.objectMode?r=e.buffer.shift():!t||t>=e.length?(r=e.decoder?e.buffer.join(""):1===e.buffer.length?e.buffer.first():e.buffer.concat(e.length),e.buffer.clear()):r=e.buffer.consume(t,e.decoder),r);var r}function D(t){var e=t._readableState;o("endReadable",e.endEmitted),e.endEmitted||(e.ended=!0,process.nextTick(C,e,t))}function C(t,e){if(o("endReadableNT",t.endEmitted,t.length),!t.endEmitted&&0===t.length&&(t.endEmitted=!0,e.readable=!1,e.emit("end"),t.autoDestroy)){var r=e._writableState;(!r||r.autoDestroy&&r.finished)&&e.destroy()}}function N(t,e){for(var r=0,n=t.length;r<n;r++)if(t[r]===e)return r;return-1}return w.prototype.read=function(t){o("read",t),t=parseInt(t,10);var e=this._readableState,r=t;if(0!==t&&(e.emittedReadable=!1),0===t&&e.needReadable&&((0!==e.highWaterMark?e.length>=e.highWaterMark:e.length>0)||e.ended))return o("read: emitReadable",e.length,e.ended),0===e.length&&e.ended?D(this):T(this),null;if(0===(t=k(t,e))&&e.ended)return 0===e.length&&D(this),null;var n,i=e.needReadable;return o("need readable",i),(0===e.length||e.length-t<e.highWaterMark)&&o("length less than watermark",i=!0),e.ended||e.reading?o("reading or ended",i=!1):i&&(o("do read"),e.reading=!0,e.sync=!0,0===e.length&&(e.needReadable=!0),this._read(e.highWaterMark),e.sync=!1,e.reading||(t=k(r,e))),null===(n=t>0?P(t,e):null)?(e.needReadable=e.length<=e.highWaterMark,t=0):(e.length-=t,e.awaitDrain=0),0===e.length&&(e.ended||(e.needReadable=!0),r!==t&&e.ended&&D(this)),null!==n&&this.emit("data",n),n},w.prototype._read=function(t){m(this,new g("_read()"))},w.prototype.pipe=function(t,r){var n=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)}i.pipesCount+=1,o("pipe count=%d opts=%j",i.pipesCount,r);var s=(!r||!1!==r.end)&&t!==process.stdout&&t!==process.stderr?l:y;function a(e,r){o("onunpipe"),e===n&&r&&!1===r.hasUnpiped&&(r.hasUnpiped=!0,o("cleanup"),t.removeListener("close",d),t.removeListener("finish",p),t.removeListener("drain",u),t.removeListener("error",f),t.removeListener("unpipe",a),n.removeListener("end",l),n.removeListener("end",y),n.removeListener("data",h),c=!0,!i.awaitDrain||t._writableState&&!t._writableState.needDrain||u())}function l(){o("onend"),t.end()}i.endEmitted?process.nextTick(s):n.once("end",s),t.on("unpipe",a);var u=function(t){return function(){var r=t._readableState;o("pipeOnDrain",r.awaitDrain),r.awaitDrain&&r.awaitDrain--,0===r.awaitDrain&&e(t,"data")&&(r.flowing=!0,I(t))}}(n);t.on("drain",u);var c=!1;function h(e){o("ondata");var r=t.write(e);o("dest.write",r),!1===r&&((1===i.pipesCount&&i.pipes===t||i.pipesCount>1&&-1!==N(i.pipes,t))&&!c&&(o("false write response, pause",i.awaitDrain),i.awaitDrain++),n.pause())}function f(r){o("onerror",r),y(),t.removeListener("error",f),0===e(t,"error")&&m(t,r)}function d(){t.removeListener("finish",p),y()}function p(){o("onfinish"),t.removeListener("close",d),y()}function y(){o("unpipe"),n.unpipe(t)}return n.on("data",h),function(t,e,r){if("function"==typeof t.prependListener)return t.prependListener(e,r);t._events&&t._events[e]?Array.isArray(t._events[e])?t._events[e].unshift(r):t._events[e]=[r,t._events[e]]:t.on(e,r)}(t,"error",f),t.once("close",d),t.once("finish",p),t.emit("pipe",n),i.flowing||(o("pipe resume"),n.resume()),t},w.prototype.unpipe=function(t){var e=this._readableState,r={hasUnpiped:!1};if(0===e.pipesCount)return this;if(1===e.pipesCount)return t&&t!==e.pipes||(t||(t=e.pipes),e.pipes=null,e.pipesCount=0,e.flowing=!1,t&&t.emit("unpipe",this,r)),this;if(!t){var n=e.pipes,i=e.pipesCount;e.pipes=null,e.pipesCount=0,e.flowing=!1;for(var o=0;o<i;o++)n[o].emit("unpipe",this,{hasUnpiped:!1});return this}var s=N(e.pipes,t);return-1===s||(e.pipes.splice(s,1),e.pipesCount-=1,1===e.pipesCount&&(e.pipes=e.pipes[0]),t.emit("unpipe",this,r)),this},w.prototype.on=function(t,e){var n=r.prototype.on.call(this,t,e),i=this._readableState;return"data"===t?(i.readableListening=this.listenerCount("readable")>0,!1!==i.flowing&&this.resume()):"readable"===t&&(i.endEmitted||i.readableListening||(i.readableListening=i.needReadable=!0,i.flowing=!1,i.emittedReadable=!1,o("on readable",i.length,i.reading),i.length?T(this):i.reading||process.nextTick(j,this))),n},w.prototype.addListener=w.prototype.on,w.prototype.removeListener=function(t,e){var n=r.prototype.removeListener.call(this,t,e);return"readable"===t&&process.nextTick(L,this),n},w.prototype.removeAllListeners=function(t){var e=r.prototype.removeAllListeners.apply(this,arguments);return"readable"!==t&&void 0!==t||process.nextTick(L,this),e},w.prototype.resume=function(){var t=this._readableState;return t.flowing||(o("resume"),t.flowing=!t.readableListening,function(t,e){e.resumeScheduled||(e.resumeScheduled=!0,process.nextTick(M,t,e))}(this,t)),t.paused=!1,this},w.prototype.pause=function(){return o("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(o("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this},w.prototype.wrap=function(t){var e=this,r=this._readableState,n=!1;for(var i in t.on("end",function(){if(o("wrapped end"),r.decoder&&!r.ended){var t=r.decoder.end();t&&t.length&&e.push(t)}e.push(null)}),t.on("data",function(i){(o("wrapped data"),r.decoder&&(i=r.decoder.write(i)),r.objectMode&&null==i)||(r.objectMode||i&&i.length)&&(e.push(i)||(n=!0,t.pause()))}),t)void 0===this[i]&&"function"==typeof t[i]&&(this[i]=function(e){return function(){return t[e].apply(t,arguments)}}(i));for(var s=0;s<_.length;s++)t.on(_[s],this.emit.bind(this,_[s]));return this._read=function(e){o("wrapped _read",e),n&&(n=!1,t.resume())},this},"function"==typeof Symbol&&(w.prototype[Symbol.asyncIterator]=function(){return void 0===l&&(l=wF()),l(this)}),Object.defineProperty(w.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),Object.defineProperty(w.prototype,"readableBuffer",{enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}}),Object.defineProperty(w.prototype,"readableFlowing",{enumerable:!1,get:function(){return this._readableState.flowing},set:function(t){this._readableState&&(this._readableState.flowing=t)}}),w._fromList=P,Object.defineProperty(w.prototype,"readableLength",{enumerable:!1,get:function(){return this._readableState.length}}),"function"==typeof Symbol&&(w.from=function(t,e){return void 0===u&&(u=bF?gF:(bF=1,gF=function(){throw new Error("Readable.from is not available in the browser")})),u(w,t,e)}),mF}var EF=jF,RF=tF.codes,kF=RF.ERR_METHOD_NOT_IMPLEMENTED,TF=RF.ERR_MULTIPLE_CALLBACK,xF=RF.ERR_TRANSFORM_ALREADY_TRANSFORMING,AF=RF.ERR_TRANSFORM_WITH_LENGTH_0,OF=hF();function LF(t,e){var r=this._transformState;r.transforming=!1;var n=r.writecb;if(null===n)return this.emit("error",new TF);r.writechunk=null,r.writecb=null,null!=e&&this.push(e),n(t);var i=this._readableState;i.reading=!1,(i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}function jF(t){if(!(this instanceof jF))return new jF(t);OF.call(this,t),this._transformState={afterTransform:LF.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,t&&("function"==typeof t.transform&&(this._transform=t.transform),"function"==typeof t.flush&&(this._flush=t.flush)),this.on("prefinish",MF)}function MF(){var t=this;"function"!=typeof this._flush||this._readableState.destroyed?IF(this,null,null):this._flush(function(e,r){IF(t,e,r)})}function IF(t,e,r){if(e)return t.emit("error",e);if(null!=r&&t.push(r),t._writableState.length)throw new AF;if(t._transformState.transforming)throw new xF;return t.push(null)}Ca(jF,OF),jF.prototype.push=function(t,e){return this._transformState.needTransform=!1,OF.prototype.push.call(this,t,e)},jF.prototype._transform=function(t,e,r){r(new kF("_transform()"))},jF.prototype._write=function(t,e,r){var n=this._transformState;if(n.writecb=r,n.writechunk=t,n.writeencoding=e,!n.transforming){var i=this._readableState;(n.needTransform||i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}},jF.prototype._read=function(t){var e=this._transformState;null===e.writechunk||e.transforming?e.needTransform=!0:(e.transforming=!0,this._transform(e.writechunk,e.writeencoding,e.afterTransform))},jF.prototype._destroy=function(t,e){OF.prototype._destroy.call(this,t,function(t){e(t)})};var PF,DF=NF,CF=EF;function NF(t){if(!(this instanceof NF))return new NF(t);CF.call(this,t)}Ca(NF,CF),NF.prototype._transform=function(t,e,r){r(null,t)};var FF=tF.codes,BF=FF.ERR_MISSING_ARGS,WF=FF.ERR_STREAM_DESTROYED;function UF(t){if(t)throw t}function zF(t){t()}function $F(t,e){return t.pipe(e)}var HF=function(){for(var t=arguments.length,e=new Array(t),r=0;r<t;r++)e[r]=arguments[r];var n,i=function(t){return t.length?"function"!=typeof t[t.length-1]?UF:t.pop():UF}(e);if(Array.isArray(e[0])&&(e=e[0]),e.length<2)throw new BF("streams");var o=e.map(function(t,r){var s=r<e.length-1;return function(t,e,r,n){n=function(t){var e=!1;return function(){e||(e=!0,t.apply(void 0,arguments))}}(n);var i=!1;t.on("close",function(){i=!0}),void 0===PF&&(PF=vF),PF(t,{readable:e,writable:r},function(t){if(t)return n(t);i=!0,n()});var o=!1;return function(e){if(!i&&!o)return o=!0,function(t){return t.setHeader&&"function"==typeof t.abort}(t)?t.abort():"function"==typeof t.destroy?t.destroy():void n(e||new WF("pipe"))}}(t,s,r>0,function(t){n||(n=t),t&&o.forEach(zF),s||(o.forEach(zF),i(n))})});return e.reduce($F)};!function(t,e){(e=t.exports=SF()).Stream=e,e.Readable=e,e.Writable=cF(),e.Duplex=hF(),e.Transform=EF,e.PassThrough=DF,e.finished=vF,e.pipeline=HF}(VN,VN.exports);var GF=VN.exports,qF={exports:{}},VF=i.Stream,ZF=GF.PassThrough,YF=qF.exports={};YF.isStream=function(t){return t instanceof VF},YF.normalizeInputSource=function(t){if(null===t)return Buffer.alloc(0);if("string"==typeof t)return Buffer.from(t);if(YF.isStream(t)&&!t._readableState){var e=new ZF;return t.pipe(e),e}return t};var KF=qF.exports,QF=s.inherits,JF=GF.Transform,XF=EN,tB=KF,eB=qN.exports=function(t){if(!(this instanceof eB))return new eB(t);JF.call(this,t),this.offset=0,this._archive={finish:!1,finished:!1,processing:!1}};QF(eB,JF),eB.prototype._appendBuffer=function(t,e,r){},eB.prototype._appendStream=function(t,e,r){},eB.prototype._emitErrorCallback=function(t){t&&this.emit("error",t)},eB.prototype._finish=function(t){},eB.prototype._normalizeEntry=function(t){},eB.prototype._transform=function(t,e,r){r(null,t)},eB.prototype.entry=function(t,e,r){if(e=e||null,"function"!=typeof r&&(r=this._emitErrorCallback.bind(this)),t instanceof XF)if(this._archive.finish||this._archive.finished)r(new Error("unacceptable entry after finish"));else{if(!this._archive.processing){if(this._archive.processing=!0,this._normalizeEntry(t),this._entry=t,e=tB.normalizeInputSource(e),Buffer.isBuffer(e))this._appendBuffer(t,e,r);else{if(!tB.isStream(e))return this._archive.processing=!1,void r(new Error("input source must be valid Stream or Buffer instance"));this._appendStream(t,e,r)}return this}r(new Error("already processing an entry"))}else r(new Error("not a valid instance of ArchiveEntry"))},eB.prototype.finish=function(){this._archive.processing?this._archive.finish=!0:this._finish()},eB.prototype.getBytesWritten=function(){return this.offset},eB.prototype.write=function(t,e){return t&&(this.offset+=t.length),JF.prototype.write.call(this,t,e)};var rB=qN.exports,nB={exports:{}},iB=ca.Buffer,oB=[0,1996959894,3993919788,2567524794,124634137,1886057615,3915621685,2657392035,249268274,2044508324,3772115230,2547177864,162941995,2125561021,3887607047,2428444049,498536548,1789927666,4089016648,2227061214,450548861,1843258603,4107580753,2211677639,325883990,1684777152,4251122042,2321926636,335633487,1661365465,4195302755,2366115317,997073096,1281953886,3579855332,2724688242,1006888145,1258607687,3524101629,2768942443,901097722,1119000684,3686517206,2898065728,853044451,1172266101,3705015759,2882616665,651767980,1373503546,3369554304,3218104598,565507253,1454621731,3485111705,3099436303,671266974,1594198024,3322730930,2970347812,795835527,1483230225,3244367275,3060149565,1994146192,31158534,2563907772,4023717930,1907459465,112637215,2680153253,3904427059,2013776290,251722036,2517215374,3775830040,2137656763,141376813,2439277719,3865271297,1802195444,476864866,2238001368,4066508878,1812370925,453092731,2181625025,4111451223,1706088902,314042704,2344532202,4240017532,1658658271,366619977,2362670323,4224994405,1303535960,984961486,2747007092,3569037538,1256170817,1037604311,2765210733,3554079995,1131014506,879679996,2909243462,3663771856,1141124467,855842277,2852801631,3708648649,1342533948,654459306,3188396048,3373015174,1466479909,544179635,3110523913,3462522015,1591671054,702138776,2966460450,3352799412,1504918807,783551873,3082640443,3233442989,3988292384,2596254646,62317068,1957810842,3939845945,2647816111,81470997,1943803523,3814918930,2489596804,225274430,2053790376,3826175755,2466906013,167816743,2097651377,4027552580,2265490386,503444072,1762050814,4150417245,2154129355,426522225,1852507879,4275313526,2312317920,282753626,1742555852,4189708143,2394877945,397917763,1622183637,3604390888,2714866558,953729732,1340076626,3518719985,2797360999,1068828381,1219638859,3624741850,2936675148,906185462,1090812512,3747672003,2825379669,829329135,1181335161,3412177804,3160834842,628085408,1382605366,3423369109,3138078467,570562233,1426400815,3317316542,2998733608,733239954,1555261956,3268935591,3050360625,752459403,1541320221,2607071920,3965973030,1969922972,40735498,2617837225,3943577151,1913087877,83908371,2512341634,3803740692,2075208622,213261112,2463272603,3855990285,2094854071,198958881,2262029012,4057260610,1759359992,534414190,2176718541,4139329115,1873836001,414664567,2282248934,4279200368,1711684554,285281116,2405801727,4167216745,1634467795,376229701,2685067896,3608007406,1308918612,956543938,2808555105,3495958263,1231636301,1047427035,2932959818,3654703836,1088359270,936918e3,2847714899,3736837829,1202900863,817233897,3183342108,3401237130,1404277552,615818150,3134207493,3453421203,1423857449,601450431,3009837614,3294710456,1567103746,711928724,3020668471,3272380065,1510334235,755167117];function sB(t){if(iB.isBuffer(t))return t;var e="function"==typeof iB.alloc&&"function"==typeof iB.from;if("number"==typeof t)return e?iB.alloc(t):new iB(t);if("string"==typeof t)return e?iB.from(t):new iB(t);throw new Error("input must be buffer, number, or string, received "+typeof t)}function aB(t,e){t=sB(t),iB.isBuffer(e)&&(e=e.readUInt32BE(0));for(var r=-1^e,n=0;n<t.length;n++)r=oB[255&(r^t[n])]^r>>>8;return-1^r}function lB(){return t=aB.apply(null,arguments),(e=sB(4)).writeInt32BE(t,0),e;var t,e}"undefined"!=typeof Int32Array&&(oB=new Int32Array(oB)),lB.signed=function(){return aB.apply(null,arguments)},lB.unsigned=function(){return aB.apply(null,arguments)>>>0};var uB,cB,hB,fB,dB=lB,pB={exports:{}};function yB(){return cB?uB:(cB=1,uB=yn.EventEmitter)}function gB(){if(fB)return hB;function t(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),r.push.apply(r,n)}return r}function e(e){for(var n=1;n<arguments.length;n++){var i=null!=arguments[n]?arguments[n]:{};n%2?t(Object(i),!0).forEach(function(t){r(e,t,i[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):t(Object(i)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))})}return e}function r(t,e,r){return(e=i(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function n(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,i(n.key),n)}}function i(t){var e=function(t,e){if("object"!=typeof t||null===t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var n=r.call(t,e||"default");if("object"!=typeof n)return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"==typeof e?e:String(e)}fB=1;var o=ca.Buffer,s=Na.inspect,a=s&&s.custom||"inspect";function l(t,e,r){o.prototype.copy.call(t,e,r)}return hB=function(){function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.head=null,this.tail=null,this.length=0}var r,i,u;return r=t,i=[{key:"push",value:function(t){var e={data:t,next:null};this.length>0?this.tail.next=e:this.head=e,this.tail=e,++this.length}},{key:"unshift",value:function(t){var e={data:t,next:this.head};0===this.length&&(this.tail=e),this.head=e,++this.length}},{key:"shift",value:function(){if(0!==this.length){var t=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,t}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(t){if(0===this.length)return"";for(var e=this.head,r=""+e.data;e=e.next;)r+=t+e.data;return r}},{key:"concat",value:function(t){if(0===this.length)return o.alloc(0);for(var e=o.allocUnsafe(t>>>0),r=this.head,n=0;r;)l(r.data,e,n),n+=r.data.length,r=r.next;return e}},{key:"consume",value:function(t,e){var r;return t<this.head.data.length?(r=this.head.data.slice(0,t),this.head.data=this.head.data.slice(t)):r=t===this.head.data.length?this.shift():e?this._getString(t):this._getBuffer(t),r}},{key:"first",value:function(){return this.head.data}},{key:"_getString",value:function(t){var e=this.head,r=1,n=e.data;for(t-=n.length;e=e.next;){var i=e.data,o=t>i.length?i.length:t;if(o===i.length?n+=i:n+=i.slice(0,t),0===(t-=o)){o===i.length?(++r,e.next?this.head=e.next:this.head=this.tail=null):(this.head=e,e.data=i.slice(o));break}++r}return this.length-=r,n}},{key:"_getBuffer",value:function(t){var e=o.allocUnsafe(t),r=this.head,n=1;for(r.data.copy(e),t-=r.data.length;r=r.next;){var i=r.data,s=t>i.length?i.length:t;if(i.copy(e,e.length-t,0,s),0===(t-=s)){s===i.length?(++n,r.next?this.head=r.next:this.head=this.tail=null):(this.head=r,r.data=i.slice(s));break}++n}return this.length-=n,e}},{key:a,value:function(t,r){return s(this,e(e({},r),{},{depth:0,customInspect:!1}))}}],i&&n(r.prototype,i),u&&n(r,u),Object.defineProperty(r,"prototype",{writable:!1}),t}(),hB}function bB(t,e){_B(t,e),mB(t)}function mB(t){t._writableState&&!t._writableState.emitClose||t._readableState&&!t._readableState.emitClose||t.emit("close")}function _B(t,e){t.emit("error",e)}var vB={destroy:function(t,e){var r=this,n=this._readableState&&this._readableState.destroyed,i=this._writableState&&this._writableState.destroyed;return n||i?(e?e(t):t&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,process.nextTick(_B,this,t)):process.nextTick(_B,this,t)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(t||null,function(t){!e&&t?r._writableState?r._writableState.errorEmitted?process.nextTick(mB,r):(r._writableState.errorEmitted=!0,process.nextTick(bB,r,t)):process.nextTick(bB,r,t):e?(process.nextTick(mB,r),e(t)):process.nextTick(mB,r)}),this)},undestroy:function(){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)},errorOrDestroy:function(t,e){var r=t._readableState,n=t._writableState;r&&r.autoDestroy||n&&n.autoDestroy?t.destroy(e):t.emit("error",e)}},wB={};var SB={};function EB(t,e,r){r||(r=Error);var n=function(t){var r,n;function i(r,n,i){return t.call(this,function(t,r,n){return"string"==typeof e?e:e(t,r,n)}(r,n,i))||this}return n=t,(r=i).prototype=Object.create(n.prototype),r.prototype.constructor=r,r.__proto__=n,i}(r);n.prototype.name=r.name,n.prototype.code=t,SB[t]=n}function RB(t,e){if(Array.isArray(t)){var r=t.length;return t=t.map(function(t){return String(t)}),r>2?"one of ".concat(e," ").concat(t.slice(0,r-1).join(", "),", or ")+t[r-1]:2===r?"one of ".concat(e," ").concat(t[0]," or ").concat(t[1]):"of ".concat(e," ").concat(t[0])}return"of ".concat(e," ").concat(String(t))}EB("ERR_INVALID_OPT_VALUE",function(t,e){return'The value "'+e+'" is invalid for option "'+t+'"'},TypeError),EB("ERR_INVALID_ARG_TYPE",function(t,e,r){var n,i,o,s;if("string"==typeof e&&(i="not ",e.substr(!o||o<0?0:+o,i.length)===i)?(n="must not be",e=e.replace(/^not /,"")):n="must be",function(t,e,r){return(void 0===r||r>t.length)&&(r=t.length),t.substring(r-e.length,r)===e}(t," argument"))s="The ".concat(t," ").concat(n," ").concat(RB(e,"type"));else{var a=function(t,e,r){return"number"!=typeof r&&(r=0),!(r+e.length>t.length)&&-1!==t.indexOf(e,r)}(t,".")?"property":"argument";s='The "'.concat(t,'" ').concat(a," ").concat(n," ").concat(RB(e,"type"))}return s+=". Received type ".concat(typeof r)},TypeError),EB("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),EB("ERR_METHOD_NOT_IMPLEMENTED",function(t){return"The "+t+" method is not implemented"}),EB("ERR_STREAM_PREMATURE_CLOSE","Premature close"),EB("ERR_STREAM_DESTROYED",function(t){return"Cannot call "+t+" after a stream was destroyed"}),EB("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),EB("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),EB("ERR_STREAM_WRITE_AFTER_END","write after end"),EB("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),EB("ERR_UNKNOWN_ENCODING",function(t){return"Unknown encoding: "+t},TypeError),EB("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),wB.codes=SB;var kB=wB.codes.ERR_INVALID_OPT_VALUE;var TB,xB,AB,OB,LB={getHighWaterMark:function(t,e,r,n){var i=function(t,e,r){return null!=t.highWaterMark?t.highWaterMark:e?t[r]:null}(e,n,r);if(null!=i){if(!isFinite(i)||Math.floor(i)!==i||i<0)throw new kB(n?r:"highWaterMark",i);return Math.floor(i)}return t.objectMode?16:16384}};function jB(){if(xB)return TB;function t(t){var e=this;this.next=null,this.entry=null,this.finish=function(){!function(t,e,r){var n=t.entry;t.entry=null;for(;n;){var i=n.callback;e.pendingcb--,i(r),n=n.next}e.corkedRequestsFree.next=t}(e,t)}}var e;xB=1,TB=w,w.WritableState=v;var r={deprecate:Ua()},n=yB(),i=ca.Buffer,o=(void 0!==Ft?Ft:"undefined"!=typeof window?window:"undefined"!=typeof self?self:{}).Uint8Array||function(){};var s,a=vB,l=LB.getHighWaterMark,u=wB.codes,c=u.ERR_INVALID_ARG_TYPE,h=u.ERR_METHOD_NOT_IMPLEMENTED,f=u.ERR_MULTIPLE_CALLBACK,d=u.ERR_STREAM_CANNOT_PIPE,p=u.ERR_STREAM_DESTROYED,y=u.ERR_STREAM_NULL_VALUES,g=u.ERR_STREAM_WRITE_AFTER_END,b=u.ERR_UNKNOWN_ENCODING,m=a.errorOrDestroy;function _(){}function v(r,n,i){e=e||MB(),r=r||{},"boolean"!=typeof i&&(i=n instanceof e),this.objectMode=!!r.objectMode,i&&(this.objectMode=this.objectMode||!!r.writableObjectMode),this.highWaterMark=l(this,r,"writableHighWaterMark",i),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var o=!1===r.decodeStrings;this.decodeStrings=!o,this.defaultEncoding=r.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(t){!function(t,e){var r=t._writableState,n=r.sync,i=r.writecb;if("function"!=typeof i)throw new f;if(function(t){t.writing=!1,t.writecb=null,t.length-=t.writelen,t.writelen=0}(r),e)!function(t,e,r,n,i){--e.pendingcb,r?(process.nextTick(i,n),process.nextTick(x,t,e),t._writableState.errorEmitted=!0,m(t,n)):(i(n),t._writableState.errorEmitted=!0,m(t,n),x(t,e))}(t,r,n,e,i);else{var o=k(r)||t.destroyed;o||r.corked||r.bufferProcessing||!r.bufferedRequest||R(t,r),n?process.nextTick(E,t,r,o,i):E(t,r,o,i)}}(n,t)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=!1!==r.emitClose,this.autoDestroy=!!r.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new t(this)}function w(t){var r=this instanceof(e=e||MB());if(!r&&!s.call(w,this))return new w(t);this._writableState=new v(t,this,r),this.writable=!0,t&&("function"==typeof t.write&&(this._write=t.write),"function"==typeof t.writev&&(this._writev=t.writev),"function"==typeof t.destroy&&(this._destroy=t.destroy),"function"==typeof t.final&&(this._final=t.final)),n.call(this)}function S(t,e,r,n,i,o,s){e.writelen=n,e.writecb=s,e.writing=!0,e.sync=!0,e.destroyed?e.onwrite(new p("write")):r?t._writev(i,e.onwrite):t._write(i,o,e.onwrite),e.sync=!1}function E(t,e,r,n){r||function(t,e){0===e.length&&e.needDrain&&(e.needDrain=!1,t.emit("drain"))}(t,e),e.pendingcb--,n(),x(t,e)}function R(e,r){r.bufferProcessing=!0;var n=r.bufferedRequest;if(e._writev&&n&&n.next){var i=r.bufferedRequestCount,o=new Array(i),s=r.corkedRequestsFree;s.entry=n;for(var a=0,l=!0;n;)o[a]=n,n.isBuf||(l=!1),n=n.next,a+=1;o.allBuffers=l,S(e,r,!0,r.length,o,"",s.finish),r.pendingcb++,r.lastBufferedRequest=null,s.next?(r.corkedRequestsFree=s.next,s.next=null):r.corkedRequestsFree=new t(r),r.bufferedRequestCount=0}else{for(;n;){var u=n.chunk,c=n.encoding,h=n.callback;if(S(e,r,!1,r.objectMode?1:u.length,u,c,h),n=n.next,r.bufferedRequestCount--,r.writing)break}null===n&&(r.lastBufferedRequest=null)}r.bufferedRequest=n,r.bufferProcessing=!1}function k(t){return t.ending&&0===t.length&&null===t.bufferedRequest&&!t.finished&&!t.writing}function T(t,e){t._final(function(r){e.pendingcb--,r&&m(t,r),e.prefinished=!0,t.emit("prefinish"),x(t,e)})}function x(t,e){var r=k(e);if(r&&(function(t,e){e.prefinished||e.finalCalled||("function"!=typeof t._final||e.destroyed?(e.prefinished=!0,t.emit("prefinish")):(e.pendingcb++,e.finalCalled=!0,process.nextTick(T,t,e)))}(t,e),0===e.pendingcb&&(e.finished=!0,t.emit("finish"),e.autoDestroy))){var n=t._readableState;(!n||n.autoDestroy&&n.endEmitted)&&t.destroy()}return r}return Ca(w,n),v.prototype.getBuffer=function(){for(var t=this.bufferedRequest,e=[];t;)e.push(t),t=t.next;return e},function(){try{Object.defineProperty(v.prototype,"buffer",{get:r.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(t){}}(),"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(s=Function.prototype[Symbol.hasInstance],Object.defineProperty(w,Symbol.hasInstance,{value:function(t){return!!s.call(this,t)||this===w&&(t&&t._writableState instanceof v)}})):s=function(t){return t instanceof this},w.prototype.pipe=function(){m(this,new d)},w.prototype.write=function(t,e,r){var n,s=this._writableState,a=!1,l=!s.objectMode&&(n=t,i.isBuffer(n)||n instanceof o);return l&&!i.isBuffer(t)&&(t=function(t){return i.from(t)}(t)),"function"==typeof e&&(r=e,e=null),l?e="buffer":e||(e=s.defaultEncoding),"function"!=typeof r&&(r=_),s.ending?function(t,e){var r=new g;m(t,r),process.nextTick(e,r)}(this,r):(l||function(t,e,r,n){var i;return null===r?i=new y:"string"==typeof r||e.objectMode||(i=new c("chunk",["string","Buffer"],r)),!i||(m(t,i),process.nextTick(n,i),!1)}(this,s,t,r))&&(s.pendingcb++,a=function(t,e,r,n,o,s){if(!r){var a=function(t,e,r){t.objectMode||!1===t.decodeStrings||"string"!=typeof e||(e=i.from(e,r));return e}(e,n,o);n!==a&&(r=!0,o="buffer",n=a)}var l=e.objectMode?1:n.length;e.length+=l;var u=e.length<e.highWaterMark;u||(e.needDrain=!0);if(e.writing||e.corked){var c=e.lastBufferedRequest;e.lastBufferedRequest={chunk:n,encoding:o,isBuf:r,callback:s,next:null},c?c.next=e.lastBufferedRequest:e.bufferedRequest=e.lastBufferedRequest,e.bufferedRequestCount+=1}else S(t,e,!1,l,n,o,s);return u}(this,s,l,t,e,r)),a},w.prototype.cork=function(){this._writableState.corked++},w.prototype.uncork=function(){var t=this._writableState;t.corked&&(t.corked--,t.writing||t.corked||t.bufferProcessing||!t.bufferedRequest||R(this,t))},w.prototype.setDefaultEncoding=function(t){if("string"==typeof t&&(t=t.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((t+"").toLowerCase())>-1))throw new b(t);return this._writableState.defaultEncoding=t,this},Object.defineProperty(w.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(w.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),w.prototype._write=function(t,e,r){r(new h("_write()"))},w.prototype._writev=null,w.prototype.end=function(t,e,r){var n=this._writableState;return"function"==typeof t?(r=t,t=null,e=null):"function"==typeof e&&(r=e,e=null),null!=t&&this.write(t,e),n.corked&&(n.corked=1,this.uncork()),n.ending||function(t,e,r){e.ending=!0,x(t,e),r&&(e.finished?process.nextTick(r):t.once("finish",r));e.ended=!0,t.writable=!1}(this,n,r),this},Object.defineProperty(w.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(w.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(t){this._writableState&&(this._writableState.destroyed=t)}}),w.prototype.destroy=a.destroy,w.prototype._undestroy=a.undestroy,w.prototype._destroy=function(t,e){e(t)},TB}function MB(){if(OB)return AB;OB=1;var t=Object.keys||function(t){var e=[];for(var r in t)e.push(r);return e};AB=s;var e=$B(),r=jB();Ca(s,e);for(var n=t(r.prototype),i=0;i<n.length;i++){var o=n[i];s.prototype[o]||(s.prototype[o]=r.prototype[o])}function s(t){if(!(this instanceof s))return new s(t);e.call(this,t),r.call(this,t),this.allowHalfOpen=!0,t&&(!1===t.readable&&(this.readable=!1),!1===t.writable&&(this.writable=!1),!1===t.allowHalfOpen&&(this.allowHalfOpen=!1,this.once("end",a)))}function a(){this._writableState.ended||process.nextTick(l,this)}function l(t){t.end()}return Object.defineProperty(s.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(s.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(s.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(s.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed&&this._writableState.destroyed)},set:function(t){void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed=t,this._writableState.destroyed=t)}}),AB}var IB=wB.codes.ERR_STREAM_PREMATURE_CLOSE;function PB(){}var DB,CB,NB,FB,BB,WB,UB=function t(e,r,n){if("function"==typeof r)return t(e,null,r);r||(r={}),n=function(t){var e=!1;return function(){if(!e){e=!0;for(var r=arguments.length,n=new Array(r),i=0;i<r;i++)n[i]=arguments[i];t.apply(this,n)}}}(n||PB);var i=r.readable||!1!==r.readable&&e.readable,o=r.writable||!1!==r.writable&&e.writable,s=function(){e.writable||l()},a=e._writableState&&e._writableState.finished,l=function(){o=!1,a=!0,i||n.call(e)},u=e._readableState&&e._readableState.endEmitted,c=function(){i=!1,u=!0,o||n.call(e)},h=function(t){n.call(e,t)},f=function(){var t;return i&&!u?(e._readableState&&e._readableState.ended||(t=new IB),n.call(e,t)):o&&!a?(e._writableState&&e._writableState.ended||(t=new IB),n.call(e,t)):void 0},d=function(){e.req.on("finish",l)};return!function(t){return t.setHeader&&"function"==typeof t.abort}(e)?o&&!e._writableState&&(e.on("end",s),e.on("close",s)):(e.on("complete",l),e.on("abort",f),e.req?d():e.on("request",d)),e.on("end",c),e.on("finish",l),!1!==r.error&&e.on("error",h),e.on("close",f),function(){e.removeListener("complete",l),e.removeListener("abort",f),e.removeListener("request",d),e.req&&e.req.removeListener("finish",l),e.removeListener("end",s),e.removeListener("close",s),e.removeListener("finish",l),e.removeListener("end",c),e.removeListener("error",h),e.removeListener("close",f)}};function zB(){if(CB)return DB;var t;function e(t,e,r){return(e=function(t){var e=function(t,e){if("object"!=typeof t||null===t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var n=r.call(t,e||"default");if("object"!=typeof n)return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"==typeof e?e:String(e)}(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}CB=1;var r=UB,n=Symbol("lastResolve"),i=Symbol("lastReject"),o=Symbol("error"),s=Symbol("ended"),a=Symbol("lastPromise"),l=Symbol("handlePromise"),u=Symbol("stream");function c(t,e){return{value:t,done:e}}function h(t){var e=t[n];if(null!==e){var r=t[u].read();null!==r&&(t[a]=null,t[n]=null,t[i]=null,e(c(r,!1)))}}function f(t){process.nextTick(h,t)}var d=Object.getPrototypeOf(function(){}),p=Object.setPrototypeOf((t={get stream(){return this[u]},next:function(){var t=this,e=this[o];if(null!==e)return Promise.reject(e);if(this[s])return Promise.resolve(c(void 0,!0));if(this[u].destroyed)return new Promise(function(e,r){process.nextTick(function(){t[o]?r(t[o]):e(c(void 0,!0))})});var r,n=this[a];if(n)r=new Promise(function(t,e){return function(r,n){t.then(function(){e[s]?r(c(void 0,!0)):e[l](r,n)},n)}}(n,this));else{var i=this[u].read();if(null!==i)return Promise.resolve(c(i,!1));r=new Promise(this[l])}return this[a]=r,r}},e(t,Symbol.asyncIterator,function(){return this}),e(t,"return",function(){var t=this;return new Promise(function(e,r){t[u].destroy(null,function(t){t?r(t):e(c(void 0,!0))})})}),t),d);return DB=function(t){var h,d=Object.create(p,(e(h={},u,{value:t,writable:!0}),e(h,n,{value:null,writable:!0}),e(h,i,{value:null,writable:!0}),e(h,o,{value:null,writable:!0}),e(h,s,{value:t._readableState.endEmitted,writable:!0}),e(h,l,{value:function(t,e){var r=d[u].read();r?(d[a]=null,d[n]=null,d[i]=null,t(c(r,!1))):(d[n]=t,d[i]=e)},writable:!0}),h));return d[a]=null,r(t,function(t){if(t&&"ERR_STREAM_PREMATURE_CLOSE"!==t.code){var e=d[i];return null!==e&&(d[a]=null,d[n]=null,d[i]=null,e(t)),void(d[o]=t)}var r=d[n];null!==r&&(d[a]=null,d[n]=null,d[i]=null,r(c(void 0,!0))),d[s]=!0}),t.on("readable",f.bind(null,d)),d},DB}function $B(){if(WB)return BB;var t;WB=1,BB=w,w.ReadableState=v,yn.EventEmitter;var e=function(t,e){return t.listeners(e).length},r=yB(),n=ca.Buffer,i=(void 0!==Ft?Ft:"undefined"!=typeof window?window:"undefined"!=typeof self?self:{}).Uint8Array||function(){};var o,s=Na;o=s&&s.debuglog?s.debuglog("stream"):function(){};var a,l,u,c=gB(),h=vB,f=LB.getHighWaterMark,d=wB.codes,p=d.ERR_INVALID_ARG_TYPE,y=d.ERR_STREAM_PUSH_AFTER_EOF,g=d.ERR_METHOD_NOT_IMPLEMENTED,b=d.ERR_STREAM_UNSHIFT_AFTER_END_EVENT;Ca(w,r);var m=h.errorOrDestroy,_=["error","close","destroy","pause","resume"];function v(e,r,n){t=t||MB(),e=e||{},"boolean"!=typeof n&&(n=r instanceof t),this.objectMode=!!e.objectMode,n&&(this.objectMode=this.objectMode||!!e.readableObjectMode),this.highWaterMark=f(this,e,"readableHighWaterMark",n),this.buffer=new c,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=!1!==e.emitClose,this.autoDestroy=!!e.autoDestroy,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(a||(a=el().StringDecoder),this.decoder=new a(e.encoding),this.encoding=e.encoding)}function w(e){if(t=t||MB(),!(this instanceof w))return new w(e);var n=this instanceof t;this._readableState=new v(e,this,n),this.readable=!0,e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy&&(this._destroy=e.destroy)),r.call(this)}function S(t,e,r,s,a){o("readableAddChunk",e);var l,u=t._readableState;if(null===e)u.reading=!1,function(t,e){if(o("onEofChunk"),e.ended)return;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?T(t):(e.needReadable=!1,e.emittedReadable||(e.emittedReadable=!0,x(t)))}(t,u);else if(a||(l=function(t,e){var r;o=e,n.isBuffer(o)||o instanceof i||"string"==typeof e||void 0===e||t.objectMode||(r=new p("chunk",["string","Buffer","Uint8Array"],e));var o;return r}(u,e)),l)m(t,l);else if(u.objectMode||e&&e.length>0)if("string"==typeof e||u.objectMode||Object.getPrototypeOf(e)===n.prototype||(e=function(t){return n.from(t)}(e)),s)u.endEmitted?m(t,new b):E(t,u,e,!0);else if(u.ended)m(t,new y);else{if(u.destroyed)return!1;u.reading=!1,u.decoder&&!r?(e=u.decoder.write(e),u.objectMode||0!==e.length?E(t,u,e,!1):A(t,u)):E(t,u,e,!1)}else s||(u.reading=!1,A(t,u));return!u.ended&&(u.length<u.highWaterMark||0===u.length)}function E(t,e,r,n){e.flowing&&0===e.length&&!e.sync?(e.awaitDrain=0,t.emit("data",r)):(e.length+=e.objectMode?1:r.length,n?e.buffer.unshift(r):e.buffer.push(r),e.needReadable&&T(t)),A(t,e)}Object.defineProperty(w.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._readableState&&this._readableState.destroyed},set:function(t){this._readableState&&(this._readableState.destroyed=t)}}),w.prototype.destroy=h.destroy,w.prototype._undestroy=h.undestroy,w.prototype._destroy=function(t,e){e(t)},w.prototype.push=function(t,e){var r,i=this._readableState;return i.objectMode?r=!0:"string"==typeof t&&((e=e||i.defaultEncoding)!==i.encoding&&(t=n.from(t,e),e=""),r=!0),S(this,t,e,!1,r)},w.prototype.unshift=function(t){return S(this,t,null,!0,!1)},w.prototype.isPaused=function(){return!1===this._readableState.flowing},w.prototype.setEncoding=function(t){a||(a=el().StringDecoder);var e=new a(t);this._readableState.decoder=e,this._readableState.encoding=this._readableState.decoder.encoding;for(var r=this._readableState.buffer.head,n="";null!==r;)n+=e.write(r.data),r=r.next;return this._readableState.buffer.clear(),""!==n&&this._readableState.buffer.push(n),this._readableState.length=n.length,this};var R=1073741824;function k(t,e){return t<=0||0===e.length&&e.ended?0:e.objectMode?1:t!=t?e.flowing&&e.length?e.buffer.head.data.length:e.length:(t>e.highWaterMark&&(e.highWaterMark=function(t){return t>=R?t=R:(t--,t|=t>>>1,t|=t>>>2,t|=t>>>4,t|=t>>>8,t|=t>>>16,t++),t}(t)),t<=e.length?t:e.ended?e.length:(e.needReadable=!0,0))}function T(t){var e=t._readableState;o("emitReadable",e.needReadable,e.emittedReadable),e.needReadable=!1,e.emittedReadable||(o("emitReadable",e.flowing),e.emittedReadable=!0,process.nextTick(x,t))}function x(t){var e=t._readableState;o("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,I(t)}function A(t,e){e.readingMore||(e.readingMore=!0,process.nextTick(O,t,e))}function O(t,e){for(;!e.reading&&!e.ended&&(e.length<e.highWaterMark||e.flowing&&0===e.length);){var r=e.length;if(o("maybeReadMore read 0"),t.read(0),r===e.length)break}e.readingMore=!1}function L(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 j(t){o("readable nexttick read 0"),t.read(0)}function M(t,e){o("resume",e.reading),e.reading||t.read(0),e.resumeScheduled=!1,t.emit("resume"),I(t),e.flowing&&!e.reading&&t.read(0)}function I(t){var e=t._readableState;for(o("flow",e.flowing);e.flowing&&null!==t.read(););}function P(t,e){return 0===e.length?null:(e.objectMode?r=e.buffer.shift():!t||t>=e.length?(r=e.decoder?e.buffer.join(""):1===e.buffer.length?e.buffer.first():e.buffer.concat(e.length),e.buffer.clear()):r=e.buffer.consume(t,e.decoder),r);var r}function D(t){var e=t._readableState;o("endReadable",e.endEmitted),e.endEmitted||(e.ended=!0,process.nextTick(C,e,t))}function C(t,e){if(o("endReadableNT",t.endEmitted,t.length),!t.endEmitted&&0===t.length&&(t.endEmitted=!0,e.readable=!1,e.emit("end"),t.autoDestroy)){var r=e._writableState;(!r||r.autoDestroy&&r.finished)&&e.destroy()}}function N(t,e){for(var r=0,n=t.length;r<n;r++)if(t[r]===e)return r;return-1}return w.prototype.read=function(t){o("read",t),t=parseInt(t,10);var e=this._readableState,r=t;if(0!==t&&(e.emittedReadable=!1),0===t&&e.needReadable&&((0!==e.highWaterMark?e.length>=e.highWaterMark:e.length>0)||e.ended))return o("read: emitReadable",e.length,e.ended),0===e.length&&e.ended?D(this):T(this),null;if(0===(t=k(t,e))&&e.ended)return 0===e.length&&D(this),null;var n,i=e.needReadable;return o("need readable",i),(0===e.length||e.length-t<e.highWaterMark)&&o("length less than watermark",i=!0),e.ended||e.reading?o("reading or ended",i=!1):i&&(o("do read"),e.reading=!0,e.sync=!0,0===e.length&&(e.needReadable=!0),this._read(e.highWaterMark),e.sync=!1,e.reading||(t=k(r,e))),null===(n=t>0?P(t,e):null)?(e.needReadable=e.length<=e.highWaterMark,t=0):(e.length-=t,e.awaitDrain=0),0===e.length&&(e.ended||(e.needReadable=!0),r!==t&&e.ended&&D(this)),null!==n&&this.emit("data",n),n},w.prototype._read=function(t){m(this,new g("_read()"))},w.prototype.pipe=function(t,r){var n=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)}i.pipesCount+=1,o("pipe count=%d opts=%j",i.pipesCount,r);var s=(!r||!1!==r.end)&&t!==process.stdout&&t!==process.stderr?l:y;function a(e,r){o("onunpipe"),e===n&&r&&!1===r.hasUnpiped&&(r.hasUnpiped=!0,o("cleanup"),t.removeListener("close",d),t.removeListener("finish",p),t.removeListener("drain",u),t.removeListener("error",f),t.removeListener("unpipe",a),n.removeListener("end",l),n.removeListener("end",y),n.removeListener("data",h),c=!0,!i.awaitDrain||t._writableState&&!t._writableState.needDrain||u())}function l(){o("onend"),t.end()}i.endEmitted?process.nextTick(s):n.once("end",s),t.on("unpipe",a);var u=function(t){return function(){var r=t._readableState;o("pipeOnDrain",r.awaitDrain),r.awaitDrain&&r.awaitDrain--,0===r.awaitDrain&&e(t,"data")&&(r.flowing=!0,I(t))}}(n);t.on("drain",u);var c=!1;function h(e){o("ondata");var r=t.write(e);o("dest.write",r),!1===r&&((1===i.pipesCount&&i.pipes===t||i.pipesCount>1&&-1!==N(i.pipes,t))&&!c&&(o("false write response, pause",i.awaitDrain),i.awaitDrain++),n.pause())}function f(r){o("onerror",r),y(),t.removeListener("error",f),0===e(t,"error")&&m(t,r)}function d(){t.removeListener("finish",p),y()}function p(){o("onfinish"),t.removeListener("close",d),y()}function y(){o("unpipe"),n.unpipe(t)}return n.on("data",h),function(t,e,r){if("function"==typeof t.prependListener)return t.prependListener(e,r);t._events&&t._events[e]?Array.isArray(t._events[e])?t._events[e].unshift(r):t._events[e]=[r,t._events[e]]:t.on(e,r)}(t,"error",f),t.once("close",d),t.once("finish",p),t.emit("pipe",n),i.flowing||(o("pipe resume"),n.resume()),t},w.prototype.unpipe=function(t){var e=this._readableState,r={hasUnpiped:!1};if(0===e.pipesCount)return this;if(1===e.pipesCount)return t&&t!==e.pipes||(t||(t=e.pipes),e.pipes=null,e.pipesCount=0,e.flowing=!1,t&&t.emit("unpipe",this,r)),this;if(!t){var n=e.pipes,i=e.pipesCount;e.pipes=null,e.pipesCount=0,e.flowing=!1;for(var o=0;o<i;o++)n[o].emit("unpipe",this,{hasUnpiped:!1});return this}var s=N(e.pipes,t);return-1===s||(e.pipes.splice(s,1),e.pipesCount-=1,1===e.pipesCount&&(e.pipes=e.pipes[0]),t.emit("unpipe",this,r)),this},w.prototype.on=function(t,e){var n=r.prototype.on.call(this,t,e),i=this._readableState;return"data"===t?(i.readableListening=this.listenerCount("readable")>0,!1!==i.flowing&&this.resume()):"readable"===t&&(i.endEmitted||i.readableListening||(i.readableListening=i.needReadable=!0,i.flowing=!1,i.emittedReadable=!1,o("on readable",i.length,i.reading),i.length?T(this):i.reading||process.nextTick(j,this))),n},w.prototype.addListener=w.prototype.on,w.prototype.removeListener=function(t,e){var n=r.prototype.removeListener.call(this,t,e);return"readable"===t&&process.nextTick(L,this),n},w.prototype.removeAllListeners=function(t){var e=r.prototype.removeAllListeners.apply(this,arguments);return"readable"!==t&&void 0!==t||process.nextTick(L,this),e},w.prototype.resume=function(){var t=this._readableState;return t.flowing||(o("resume"),t.flowing=!t.readableListening,function(t,e){e.resumeScheduled||(e.resumeScheduled=!0,process.nextTick(M,t,e))}(this,t)),t.paused=!1,this},w.prototype.pause=function(){return o("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(o("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this},w.prototype.wrap=function(t){var e=this,r=this._readableState,n=!1;for(var i in t.on("end",function(){if(o("wrapped end"),r.decoder&&!r.ended){var t=r.decoder.end();t&&t.length&&e.push(t)}e.push(null)}),t.on("data",function(i){(o("wrapped data"),r.decoder&&(i=r.decoder.write(i)),r.objectMode&&null==i)||(r.objectMode||i&&i.length)&&(e.push(i)||(n=!0,t.pause()))}),t)void 0===this[i]&&"function"==typeof t[i]&&(this[i]=function(e){return function(){return t[e].apply(t,arguments)}}(i));for(var s=0;s<_.length;s++)t.on(_[s],this.emit.bind(this,_[s]));return this._read=function(e){o("wrapped _read",e),n&&(n=!1,t.resume())},this},"function"==typeof Symbol&&(w.prototype[Symbol.asyncIterator]=function(){return void 0===l&&(l=zB()),l(this)}),Object.defineProperty(w.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),Object.defineProperty(w.prototype,"readableBuffer",{enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}}),Object.defineProperty(w.prototype,"readableFlowing",{enumerable:!1,get:function(){return this._readableState.flowing},set:function(t){this._readableState&&(this._readableState.flowing=t)}}),w._fromList=P,Object.defineProperty(w.prototype,"readableLength",{enumerable:!1,get:function(){return this._readableState.length}}),"function"==typeof Symbol&&(w.from=function(t,e){return void 0===u&&(u=FB?NB:(FB=1,NB=function(){throw new Error("Readable.from is not available in the browser")})),u(w,t,e)}),BB}var HB=JB,GB=wB.codes,qB=GB.ERR_METHOD_NOT_IMPLEMENTED,VB=GB.ERR_MULTIPLE_CALLBACK,ZB=GB.ERR_TRANSFORM_ALREADY_TRANSFORMING,YB=GB.ERR_TRANSFORM_WITH_LENGTH_0,KB=MB();function QB(t,e){var r=this._transformState;r.transforming=!1;var n=r.writecb;if(null===n)return this.emit("error",new VB);r.writechunk=null,r.writecb=null,null!=e&&this.push(e),n(t);var i=this._readableState;i.reading=!1,(i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}function JB(t){if(!(this instanceof JB))return new JB(t);KB.call(this,t),this._transformState={afterTransform:QB.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,t&&("function"==typeof t.transform&&(this._transform=t.transform),"function"==typeof t.flush&&(this._flush=t.flush)),this.on("prefinish",XB)}function XB(){var t=this;"function"!=typeof this._flush||this._readableState.destroyed?tW(this,null,null):this._flush(function(e,r){tW(t,e,r)})}function tW(t,e,r){if(e)return t.emit("error",e);if(null!=r&&t.push(r),t._writableState.length)throw new YB;if(t._transformState.transforming)throw new ZB;return t.push(null)}Ca(JB,KB),JB.prototype.push=function(t,e){return this._transformState.needTransform=!1,KB.prototype.push.call(this,t,e)},JB.prototype._transform=function(t,e,r){r(new qB("_transform()"))},JB.prototype._write=function(t,e,r){var n=this._transformState;if(n.writecb=r,n.writechunk=t,n.writeencoding=e,!n.transforming){var i=this._readableState;(n.needTransform||i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}},JB.prototype._read=function(t){var e=this._transformState;null===e.writechunk||e.transforming?e.needTransform=!0:(e.transforming=!0,this._transform(e.writechunk,e.writeencoding,e.afterTransform))},JB.prototype._destroy=function(t,e){KB.prototype._destroy.call(this,t,function(t){e(t)})};var eW,rW=iW,nW=HB;function iW(t){if(!(this instanceof iW))return new iW(t);nW.call(this,t)}Ca(iW,nW),iW.prototype._transform=function(t,e,r){r(null,t)};var oW=wB.codes,sW=oW.ERR_MISSING_ARGS,aW=oW.ERR_STREAM_DESTROYED;function lW(t){if(t)throw t}function uW(t){t()}function cW(t,e){return t.pipe(e)}var hW=function(){for(var t=arguments.length,e=new Array(t),r=0;r<t;r++)e[r]=arguments[r];var n,i=function(t){return t.length?"function"!=typeof t[t.length-1]?lW:t.pop():lW}(e);if(Array.isArray(e[0])&&(e=e[0]),e.length<2)throw new sW("streams");var o=e.map(function(t,r){var s=r<e.length-1;return function(t,e,r,n){n=function(t){var e=!1;return function(){e||(e=!0,t.apply(void 0,arguments))}}(n);var i=!1;t.on("close",function(){i=!0}),void 0===eW&&(eW=UB),eW(t,{readable:e,writable:r},function(t){if(t)return n(t);i=!0,n()});var o=!1;return function(e){if(!i&&!o)return o=!0,function(t){return t.setHeader&&"function"==typeof t.abort}(t)?t.abort():"function"==typeof t.destroy?t.destroy():void n(e||new aW("pipe"))}}(t,s,r>0,function(t){n||(n=t),t&&o.forEach(uW),s||(o.forEach(uW),i(n))})});return e.reduce(cW)};!function(t,e){(e=t.exports=$B()).Stream=e,e.Readable=e,e.Writable=jB(),e.Duplex=MB(),e.Transform=HB,e.PassThrough=rW,e.finished=UB,e.pipeline=hW}(pB,pB.exports);var fW=pB.exports;const{Transform:dW}=fW,pW=DI;var yW=class extends dW{constructor(t){super(t),this.checksum=Buffer.allocUnsafe(4),this.checksum.writeInt32BE(0,0),this.rawSize=0}_transform(t,e,r){t&&(this.checksum=pW.buf(t,this.checksum)>>>0,this.rawSize+=t.length),r(null,t)}digest(t){const e=Buffer.allocUnsafe(4);return e.writeUInt32BE(this.checksum>>>0,0),t?e.toString(t):e}hex(){return this.digest("hex").toUpperCase()}size(){return this.rawSize}};const{DeflateRaw:gW}=y,bW=DI;var mW={CRC32Stream:yW,DeflateCRC32Stream:class extends gW{constructor(t){super(t),this.checksum=Buffer.allocUnsafe(4),this.checksum.writeInt32BE(0,0),this.rawSize=0,this.compressedSize=0}push(t,e){return t&&(this.compressedSize+=t.length),super.push(t,e)}_transform(t,e,r){t&&(this.checksum=bW.buf(t,this.checksum)>>>0,this.rawSize+=t.length),super._transform(t,e,r)}digest(t){const e=Buffer.allocUnsafe(4);return e.writeUInt32BE(this.checksum>>>0,0),t?e.toString(t):e}hex(){return this.digest("hex").toUpperCase()}size(t=!1){return t?this.compressedSize:this.rawSize}}},_W=s.inherits,vW=dB,{CRC32Stream:wW}=mW,{DeflateCRC32Stream:SW}=mW,EW=rB,RW=MN,kW=AN,TW=nB.exports=function(t){if(!(this instanceof TW))return new TW(t);t=this.options=this._defaults(t),EW.call(this,t),this._entry=null,this._entries=[],this._archive={centralLength:0,centralOffset:0,comment:"",finish:!1,finished:!1,processing:!1,forceZip64:t.forceZip64,forceLocalTime:t.forceLocalTime}};_W(TW,EW),TW.prototype._afterAppend=function(t){this._entries.push(t),t.getGeneralPurposeBit().usesDataDescriptor()&&this._writeDataDescriptor(t),this._archive.processing=!1,this._entry=null,this._archive.finish&&!this._archive.finished&&this._finish()},TW.prototype._appendBuffer=function(t,e,r){0===e.length&&t.setMethod(RW.METHOD_STORED);var n=t.getMethod();return n===RW.METHOD_STORED&&(t.setSize(e.length),t.setCompressedSize(e.length),t.setCrc(vW.unsigned(e))),this._writeLocalFileHeader(t),n===RW.METHOD_STORED?(this.write(e),this._afterAppend(t),void r(null,t)):n===RW.METHOD_DEFLATED?void this._smartStream(t,r).end(e):void r(new Error("compression method "+n+" not implemented"))},TW.prototype._appendStream=function(t,e,r){t.getGeneralPurposeBit().useDataDescriptor(!0),t.setVersionNeededToExtract(RW.MIN_VERSION_DATA_DESCRIPTOR),this._writeLocalFileHeader(t);var n=this._smartStream(t,r);e.once("error",function(t){n.emit("error",t),n.end()}),e.pipe(n)},TW.prototype._defaults=function(t){return"object"!=typeof t&&(t={}),"object"!=typeof t.zlib&&(t.zlib={}),"number"!=typeof t.zlib.level&&(t.zlib.level=RW.ZLIB_BEST_SPEED),t.forceZip64=!!t.forceZip64,t.forceLocalTime=!!t.forceLocalTime,t},TW.prototype._finish=function(){this._archive.centralOffset=this.offset,this._entries.forEach(function(t){this._writeCentralFileHeader(t)}.bind(this)),this._archive.centralLength=this.offset-this._archive.centralOffset,this.isZip64()&&this._writeCentralDirectoryZip64(),this._writeCentralDirectoryEnd(),this._archive.processing=!1,this._archive.finish=!0,this._archive.finished=!0,this.end()},TW.prototype._normalizeEntry=function(t){-1===t.getMethod()&&t.setMethod(RW.METHOD_DEFLATED),t.getMethod()===RW.METHOD_DEFLATED&&(t.getGeneralPurposeBit().useDataDescriptor(!0),t.setVersionNeededToExtract(RW.MIN_VERSION_DATA_DESCRIPTOR)),-1===t.getTime()&&t.setTime(new Date,this._archive.forceLocalTime),t._offsets={file:0,data:0,contents:0}},TW.prototype._smartStream=function(t,e){var r=t.getMethod()===RW.METHOD_DEFLATED?new SW(this.options.zlib):new wW,n=null;return r.once("end",function(){var i=r.digest().readUInt32BE(0);t.setCrc(i),t.setSize(r.size()),t.setCompressedSize(r.size(!0)),this._afterAppend(t),e(n,t)}.bind(this)),r.once("error",function(t){n=t}),r.pipe(this,{end:!1}),r},TW.prototype._writeCentralDirectoryEnd=function(){var t=this._entries.length,e=this._archive.centralLength,r=this._archive.centralOffset;this.isZip64()&&(t=RW.ZIP64_MAGIC_SHORT,e=RW.ZIP64_MAGIC,r=RW.ZIP64_MAGIC),this.write(kW.getLongBytes(RW.SIG_EOCD)),this.write(RW.SHORT_ZERO),this.write(RW.SHORT_ZERO),this.write(kW.getShortBytes(t)),this.write(kW.getShortBytes(t)),this.write(kW.getLongBytes(e)),this.write(kW.getLongBytes(r));var n=this.getComment(),i=Buffer.byteLength(n);this.write(kW.getShortBytes(i)),this.write(n)},TW.prototype._writeCentralDirectoryZip64=function(){this.write(kW.getLongBytes(RW.SIG_ZIP64_EOCD)),this.write(kW.getEightBytes(44)),this.write(kW.getShortBytes(RW.MIN_VERSION_ZIP64)),this.write(kW.getShortBytes(RW.MIN_VERSION_ZIP64)),this.write(RW.LONG_ZERO),this.write(RW.LONG_ZERO),this.write(kW.getEightBytes(this._entries.length)),this.write(kW.getEightBytes(this._entries.length)),this.write(kW.getEightBytes(this._archive.centralLength)),this.write(kW.getEightBytes(this._archive.centralOffset)),this.write(kW.getLongBytes(RW.SIG_ZIP64_EOCD_LOC)),this.write(RW.LONG_ZERO),this.write(kW.getEightBytes(this._archive.centralOffset+this._archive.centralLength)),this.write(kW.getLongBytes(1))},TW.prototype._writeCentralFileHeader=function(t){var e=t.getGeneralPurposeBit(),r=t.getMethod(),n=t._offsets,i=t.getSize(),o=t.getCompressedSize();if(t.isZip64()||n.file>RW.ZIP64_MAGIC){i=RW.ZIP64_MAGIC,o=RW.ZIP64_MAGIC,t.setVersionNeededToExtract(RW.MIN_VERSION_ZIP64);var s=Buffer.concat([kW.getShortBytes(RW.ZIP64_EXTRA_ID),kW.getShortBytes(24),kW.getEightBytes(t.getSize()),kW.getEightBytes(t.getCompressedSize()),kW.getEightBytes(n.file)],28);t.setExtra(s)}this.write(kW.getLongBytes(RW.SIG_CFH)),this.write(kW.getShortBytes(t.getPlatform()<<8|RW.VERSION_MADEBY)),this.write(kW.getShortBytes(t.getVersionNeededToExtract())),this.write(e.encode()),this.write(kW.getShortBytes(r)),this.write(kW.getLongBytes(t.getTimeDos())),this.write(kW.getLongBytes(t.getCrc())),this.write(kW.getLongBytes(o)),this.write(kW.getLongBytes(i));var a=t.getName(),l=t.getComment(),u=t.getCentralDirectoryExtra();e.usesUTF8ForNames()&&(a=Buffer.from(a),l=Buffer.from(l)),this.write(kW.getShortBytes(a.length)),this.write(kW.getShortBytes(u.length)),this.write(kW.getShortBytes(l.length)),this.write(RW.SHORT_ZERO),this.write(kW.getShortBytes(t.getInternalAttributes())),this.write(kW.getLongBytes(t.getExternalAttributes())),n.file>RW.ZIP64_MAGIC?this.write(kW.getLongBytes(RW.ZIP64_MAGIC)):this.write(kW.getLongBytes(n.file)),this.write(a),this.write(u),this.write(l)},TW.prototype._writeDataDescriptor=function(t){this.write(kW.getLongBytes(RW.SIG_DD)),this.write(kW.getLongBytes(t.getCrc())),t.isZip64()?(this.write(kW.getEightBytes(t.getCompressedSize())),this.write(kW.getEightBytes(t.getSize()))):(this.write(kW.getLongBytes(t.getCompressedSize())),this.write(kW.getLongBytes(t.getSize())))},TW.prototype._writeLocalFileHeader=function(t){var e=t.getGeneralPurposeBit(),r=t.getMethod(),n=t.getName(),i=t.getLocalFileDataExtra();t.isZip64()&&(e.useDataDescriptor(!0),t.setVersionNeededToExtract(RW.MIN_VERSION_ZIP64)),e.usesUTF8ForNames()&&(n=Buffer.from(n)),t._offsets.file=this.offset,this.write(kW.getLongBytes(RW.SIG_LFH)),this.write(kW.getShortBytes(t.getVersionNeededToExtract())),this.write(e.encode()),this.write(kW.getShortBytes(r)),this.write(kW.getLongBytes(t.getTimeDos())),t._offsets.data=this.offset,e.usesDataDescriptor()?(this.write(RW.LONG_ZERO),this.write(RW.LONG_ZERO),this.write(RW.LONG_ZERO)):(this.write(kW.getLongBytes(t.getCrc())),this.write(kW.getLongBytes(t.getCompressedSize())),this.write(kW.getLongBytes(t.getSize()))),this.write(kW.getShortBytes(n.length)),this.write(kW.getShortBytes(i.length)),this.write(n),this.write(i),t._offsets.contents=this.offset},TW.prototype.getComment=function(t){return null!==this._archive.comment?this._archive.comment:""},TW.prototype.isZip64=function(){return this._archive.forceZip64||this._entries.length>RW.ZIP64_MAGIC_SHORT||this._archive.centralLength>RW.ZIP64_MAGIC||this._archive.centralOffset>RW.ZIP64_MAGIC},TW.prototype.setComment=function(t){this._archive.comment=t};var xW={ArchiveEntry:EN,ZipArchiveEntry:GN,ArchiveOutputStream:rB,ZipArchiveOutputStream:nB.exports},AW={exports:{}},OW=9007199254740991,LW="[object Arguments]",jW="[object Function]",MW="[object GeneratorFunction]",IW=/^(?:0|[1-9]\d*)$/;function PW(t,e,r){switch(r.length){case 0:return t.call(e);case 1:return t.call(e,r[0]);case 2:return t.call(e,r[0],r[1]);case 3:return t.call(e,r[0],r[1],r[2])}return t.apply(e,r)}var DW=Object.prototype,CW=DW.hasOwnProperty,NW=DW.toString,FW=DW.propertyIsEnumerable,BW=Math.max;function WW(t,e){var r=VW(t)||function(t){return function(t){return function(t){return!!t&&"object"==typeof t}(t)&&ZW(t)}(t)&&CW.call(t,"callee")&&(!FW.call(t,"callee")||NW.call(t)==LW)}(t)?function(t,e){for(var r=-1,n=Array(t);++r<t;)n[r]=e(r);return n}(t.length,String):[],n=r.length,i=!!n;for(var o in t)!e&&!CW.call(t,o)||i&&("length"==o||GW(o,n))||r.push(o);return r}function UW(t,e,r,n){return void 0===t||qW(t,DW[r])&&!CW.call(n,r)?e:t}function zW(t,e,r){var n=t[e];CW.call(t,e)&&qW(n,r)&&(void 0!==r||e in t)||(t[e]=r)}function $W(t){if(!YW(t))return function(t){var e=[];if(null!=t)for(var r in Object(t))e.push(r);return e}(t);var e,r,n,i=(r=(e=t)&&e.constructor,n="function"==typeof r&&r.prototype||DW,e===n),o=[];for(var s in t)("constructor"!=s||!i&&CW.call(t,s))&&o.push(s);return o}function HW(t,e){return e=BW(void 0===e?t.length-1:e,0),function(){for(var r=arguments,n=-1,i=BW(r.length-e,0),o=Array(i);++n<i;)o[n]=r[e+n];n=-1;for(var s=Array(e+1);++n<e;)s[n]=r[n];return s[e]=o,PW(t,this,s)}}function GW(t,e){return!!(e=null==e?OW:e)&&("number"==typeof t||IW.test(t))&&t>-1&&t%1==0&&t<e}function qW(t,e){return t===e||t!=t&&e!=e}var VW=Array.isArray;function ZW(t){return null!=t&&function(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=OW}(t.length)&&!function(t){var e=YW(t)?NW.call(t):"";return e==jW||e==MW}(t)}function YW(t){var e=typeof t;return!!t&&("object"==e||"function"==e)}var KW,QW=(KW=function(t,e,r,n){!function(t,e,r,n){r||(r={});for(var i=-1,o=e.length;++i<o;){var s=e[i],a=n?n(r[s],t[s],s,r,t):void 0;zW(r,s,void 0===a?t[s]:a)}}(e,function(t){return ZW(t)?WW(t,!0):$W(t)}(e),t,n)},HW(function(t,e){var r=-1,n=e.length,i=n>1?e[n-1]:void 0,o=n>2?e[2]:void 0;for(i=KW.length>3&&"function"==typeof i?(n--,i):void 0,o&&function(t,e,r){if(!YW(r))return!1;var n=typeof e;return!!("number"==n?ZW(r)&&GW(e,r.length):"string"==n&&e in r)&&qW(r[e],t)}(e[0],e[1],o)&&(i=n<3?void 0:i,n=1),t=Object(t);++r<n;){var s=e[r];s&&KW(t,s,r,i)}return t}));var JW,XW,tU,eU,rU=HW(function(t){return t.push(void 0,UW),PW(QW,void 0,t)}),nU={exports:{}};function iU(){return XW?JW:(XW=1,JW=yn.EventEmitter)}function oU(){if(eU)return tU;function t(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),r.push.apply(r,n)}return r}function e(e){for(var n=1;n<arguments.length;n++){var i=null!=arguments[n]?arguments[n]:{};n%2?t(Object(i),!0).forEach(function(t){r(e,t,i[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):t(Object(i)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))})}return e}function r(t,e,r){return(e=i(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function n(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,i(n.key),n)}}function i(t){var e=function(t,e){if("object"!=typeof t||null===t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var n=r.call(t,e||"default");if("object"!=typeof n)return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"==typeof e?e:String(e)}eU=1;var o=ca.Buffer,s=Na.inspect,a=s&&s.custom||"inspect";function l(t,e,r){o.prototype.copy.call(t,e,r)}return tU=function(){function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.head=null,this.tail=null,this.length=0}var r,i,u;return r=t,i=[{key:"push",value:function(t){var e={data:t,next:null};this.length>0?this.tail.next=e:this.head=e,this.tail=e,++this.length}},{key:"unshift",value:function(t){var e={data:t,next:this.head};0===this.length&&(this.tail=e),this.head=e,++this.length}},{key:"shift",value:function(){if(0!==this.length){var t=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,t}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(t){if(0===this.length)return"";for(var e=this.head,r=""+e.data;e=e.next;)r+=t+e.data;return r}},{key:"concat",value:function(t){if(0===this.length)return o.alloc(0);for(var e=o.allocUnsafe(t>>>0),r=this.head,n=0;r;)l(r.data,e,n),n+=r.data.length,r=r.next;return e}},{key:"consume",value:function(t,e){var r;return t<this.head.data.length?(r=this.head.data.slice(0,t),this.head.data=this.head.data.slice(t)):r=t===this.head.data.length?this.shift():e?this._getString(t):this._getBuffer(t),r}},{key:"first",value:function(){return this.head.data}},{key:"_getString",value:function(t){var e=this.head,r=1,n=e.data;for(t-=n.length;e=e.next;){var i=e.data,o=t>i.length?i.length:t;if(o===i.length?n+=i:n+=i.slice(0,t),0===(t-=o)){o===i.length?(++r,e.next?this.head=e.next:this.head=this.tail=null):(this.head=e,e.data=i.slice(o));break}++r}return this.length-=r,n}},{key:"_getBuffer",value:function(t){var e=o.allocUnsafe(t),r=this.head,n=1;for(r.data.copy(e),t-=r.data.length;r=r.next;){var i=r.data,s=t>i.length?i.length:t;if(i.copy(e,e.length-t,0,s),0===(t-=s)){s===i.length?(++n,r.next?this.head=r.next:this.head=this.tail=null):(this.head=r,r.data=i.slice(s));break}++n}return this.length-=n,e}},{key:a,value:function(t,r){return s(this,e(e({},r),{},{depth:0,customInspect:!1}))}}],i&&n(r.prototype,i),u&&n(r,u),Object.defineProperty(r,"prototype",{writable:!1}),t}(),tU}function sU(t,e){lU(t,e),aU(t)}function aU(t){t._writableState&&!t._writableState.emitClose||t._readableState&&!t._readableState.emitClose||t.emit("close")}function lU(t,e){t.emit("error",e)}var uU={destroy:function(t,e){var r=this,n=this._readableState&&this._readableState.destroyed,i=this._writableState&&this._writableState.destroyed;return n||i?(e?e(t):t&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,process.nextTick(lU,this,t)):process.nextTick(lU,this,t)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(t||null,function(t){!e&&t?r._writableState?r._writableState.errorEmitted?process.nextTick(aU,r):(r._writableState.errorEmitted=!0,process.nextTick(sU,r,t)):process.nextTick(sU,r,t):e?(process.nextTick(aU,r),e(t)):process.nextTick(aU,r)}),this)},undestroy:function(){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)},errorOrDestroy:function(t,e){var r=t._readableState,n=t._writableState;r&&r.autoDestroy||n&&n.autoDestroy?t.destroy(e):t.emit("error",e)}},cU={};var hU={};function fU(t,e,r){r||(r=Error);var n=function(t){var r,n;function i(r,n,i){return t.call(this,function(t,r,n){return"string"==typeof e?e:e(t,r,n)}(r,n,i))||this}return n=t,(r=i).prototype=Object.create(n.prototype),r.prototype.constructor=r,r.__proto__=n,i}(r);n.prototype.name=r.name,n.prototype.code=t,hU[t]=n}function dU(t,e){if(Array.isArray(t)){var r=t.length;return t=t.map(function(t){return String(t)}),r>2?"one of ".concat(e," ").concat(t.slice(0,r-1).join(", "),", or ")+t[r-1]:2===r?"one of ".concat(e," ").concat(t[0]," or ").concat(t[1]):"of ".concat(e," ").concat(t[0])}return"of ".concat(e," ").concat(String(t))}fU("ERR_INVALID_OPT_VALUE",function(t,e){return'The value "'+e+'" is invalid for option "'+t+'"'},TypeError),fU("ERR_INVALID_ARG_TYPE",function(t,e,r){var n,i,o,s;if("string"==typeof e&&(i="not ",e.substr(!o||o<0?0:+o,i.length)===i)?(n="must not be",e=e.replace(/^not /,"")):n="must be",function(t,e,r){return(void 0===r||r>t.length)&&(r=t.length),t.substring(r-e.length,r)===e}(t," argument"))s="The ".concat(t," ").concat(n," ").concat(dU(e,"type"));else{var a=function(t,e,r){return"number"!=typeof r&&(r=0),!(r+e.length>t.length)&&-1!==t.indexOf(e,r)}(t,".")?"property":"argument";s='The "'.concat(t,'" ').concat(a," ").concat(n," ").concat(dU(e,"type"))}return s+=". Received type ".concat(typeof r)},TypeError),fU("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),fU("ERR_METHOD_NOT_IMPLEMENTED",function(t){return"The "+t+" method is not implemented"}),fU("ERR_STREAM_PREMATURE_CLOSE","Premature close"),fU("ERR_STREAM_DESTROYED",function(t){return"Cannot call "+t+" after a stream was destroyed"}),fU("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),fU("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),fU("ERR_STREAM_WRITE_AFTER_END","write after end"),fU("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),fU("ERR_UNKNOWN_ENCODING",function(t){return"Unknown encoding: "+t},TypeError),fU("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),cU.codes=hU;var pU=cU.codes.ERR_INVALID_OPT_VALUE;var yU,gU,bU,mU,_U={getHighWaterMark:function(t,e,r,n){var i=function(t,e,r){return null!=t.highWaterMark?t.highWaterMark:e?t[r]:null}(e,n,r);if(null!=i){if(!isFinite(i)||Math.floor(i)!==i||i<0)throw new pU(n?r:"highWaterMark",i);return Math.floor(i)}return t.objectMode?16:16384}};function vU(){if(gU)return yU;function t(t){var e=this;this.next=null,this.entry=null,this.finish=function(){!function(t,e,r){var n=t.entry;t.entry=null;for(;n;){var i=n.callback;e.pendingcb--,i(r),n=n.next}e.corkedRequestsFree.next=t}(e,t)}}var e;gU=1,yU=w,w.WritableState=v;var r={deprecate:Ua()},n=iU(),i=ca.Buffer,o=(void 0!==Ft?Ft:"undefined"!=typeof window?window:"undefined"!=typeof self?self:{}).Uint8Array||function(){};var s,a=uU,l=_U.getHighWaterMark,u=cU.codes,c=u.ERR_INVALID_ARG_TYPE,h=u.ERR_METHOD_NOT_IMPLEMENTED,f=u.ERR_MULTIPLE_CALLBACK,d=u.ERR_STREAM_CANNOT_PIPE,p=u.ERR_STREAM_DESTROYED,y=u.ERR_STREAM_NULL_VALUES,g=u.ERR_STREAM_WRITE_AFTER_END,b=u.ERR_UNKNOWN_ENCODING,m=a.errorOrDestroy;function _(){}function v(r,n,i){e=e||wU(),r=r||{},"boolean"!=typeof i&&(i=n instanceof e),this.objectMode=!!r.objectMode,i&&(this.objectMode=this.objectMode||!!r.writableObjectMode),this.highWaterMark=l(this,r,"writableHighWaterMark",i),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var o=!1===r.decodeStrings;this.decodeStrings=!o,this.defaultEncoding=r.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(t){!function(t,e){var r=t._writableState,n=r.sync,i=r.writecb;if("function"!=typeof i)throw new f;if(function(t){t.writing=!1,t.writecb=null,t.length-=t.writelen,t.writelen=0}(r),e)!function(t,e,r,n,i){--e.pendingcb,r?(process.nextTick(i,n),process.nextTick(x,t,e),t._writableState.errorEmitted=!0,m(t,n)):(i(n),t._writableState.errorEmitted=!0,m(t,n),x(t,e))}(t,r,n,e,i);else{var o=k(r)||t.destroyed;o||r.corked||r.bufferProcessing||!r.bufferedRequest||R(t,r),n?process.nextTick(E,t,r,o,i):E(t,r,o,i)}}(n,t)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=!1!==r.emitClose,this.autoDestroy=!!r.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new t(this)}function w(t){var r=this instanceof(e=e||wU());if(!r&&!s.call(w,this))return new w(t);this._writableState=new v(t,this,r),this.writable=!0,t&&("function"==typeof t.write&&(this._write=t.write),"function"==typeof t.writev&&(this._writev=t.writev),"function"==typeof t.destroy&&(this._destroy=t.destroy),"function"==typeof t.final&&(this._final=t.final)),n.call(this)}function S(t,e,r,n,i,o,s){e.writelen=n,e.writecb=s,e.writing=!0,e.sync=!0,e.destroyed?e.onwrite(new p("write")):r?t._writev(i,e.onwrite):t._write(i,o,e.onwrite),e.sync=!1}function E(t,e,r,n){r||function(t,e){0===e.length&&e.needDrain&&(e.needDrain=!1,t.emit("drain"))}(t,e),e.pendingcb--,n(),x(t,e)}function R(e,r){r.bufferProcessing=!0;var n=r.bufferedRequest;if(e._writev&&n&&n.next){var i=r.bufferedRequestCount,o=new Array(i),s=r.corkedRequestsFree;s.entry=n;for(var a=0,l=!0;n;)o[a]=n,n.isBuf||(l=!1),n=n.next,a+=1;o.allBuffers=l,S(e,r,!0,r.length,o,"",s.finish),r.pendingcb++,r.lastBufferedRequest=null,s.next?(r.corkedRequestsFree=s.next,s.next=null):r.corkedRequestsFree=new t(r),r.bufferedRequestCount=0}else{for(;n;){var u=n.chunk,c=n.encoding,h=n.callback;if(S(e,r,!1,r.objectMode?1:u.length,u,c,h),n=n.next,r.bufferedRequestCount--,r.writing)break}null===n&&(r.lastBufferedRequest=null)}r.bufferedRequest=n,r.bufferProcessing=!1}function k(t){return t.ending&&0===t.length&&null===t.bufferedRequest&&!t.finished&&!t.writing}function T(t,e){t._final(function(r){e.pendingcb--,r&&m(t,r),e.prefinished=!0,t.emit("prefinish"),x(t,e)})}function x(t,e){var r=k(e);if(r&&(function(t,e){e.prefinished||e.finalCalled||("function"!=typeof t._final||e.destroyed?(e.prefinished=!0,t.emit("prefinish")):(e.pendingcb++,e.finalCalled=!0,process.nextTick(T,t,e)))}(t,e),0===e.pendingcb&&(e.finished=!0,t.emit("finish"),e.autoDestroy))){var n=t._readableState;(!n||n.autoDestroy&&n.endEmitted)&&t.destroy()}return r}return Ca(w,n),v.prototype.getBuffer=function(){for(var t=this.bufferedRequest,e=[];t;)e.push(t),t=t.next;return e},function(){try{Object.defineProperty(v.prototype,"buffer",{get:r.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(t){}}(),"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(s=Function.prototype[Symbol.hasInstance],Object.defineProperty(w,Symbol.hasInstance,{value:function(t){return!!s.call(this,t)||this===w&&(t&&t._writableState instanceof v)}})):s=function(t){return t instanceof this},w.prototype.pipe=function(){m(this,new d)},w.prototype.write=function(t,e,r){var n,s=this._writableState,a=!1,l=!s.objectMode&&(n=t,i.isBuffer(n)||n instanceof o);return l&&!i.isBuffer(t)&&(t=function(t){return i.from(t)}(t)),"function"==typeof e&&(r=e,e=null),l?e="buffer":e||(e=s.defaultEncoding),"function"!=typeof r&&(r=_),s.ending?function(t,e){var r=new g;m(t,r),process.nextTick(e,r)}(this,r):(l||function(t,e,r,n){var i;return null===r?i=new y:"string"==typeof r||e.objectMode||(i=new c("chunk",["string","Buffer"],r)),!i||(m(t,i),process.nextTick(n,i),!1)}(this,s,t,r))&&(s.pendingcb++,a=function(t,e,r,n,o,s){if(!r){var a=function(t,e,r){t.objectMode||!1===t.decodeStrings||"string"!=typeof e||(e=i.from(e,r));return e}(e,n,o);n!==a&&(r=!0,o="buffer",n=a)}var l=e.objectMode?1:n.length;e.length+=l;var u=e.length<e.highWaterMark;u||(e.needDrain=!0);if(e.writing||e.corked){var c=e.lastBufferedRequest;e.lastBufferedRequest={chunk:n,encoding:o,isBuf:r,callback:s,next:null},c?c.next=e.lastBufferedRequest:e.bufferedRequest=e.lastBufferedRequest,e.bufferedRequestCount+=1}else S(t,e,!1,l,n,o,s);return u}(this,s,l,t,e,r)),a},w.prototype.cork=function(){this._writableState.corked++},w.prototype.uncork=function(){var t=this._writableState;t.corked&&(t.corked--,t.writing||t.corked||t.bufferProcessing||!t.bufferedRequest||R(this,t))},w.prototype.setDefaultEncoding=function(t){if("string"==typeof t&&(t=t.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((t+"").toLowerCase())>-1))throw new b(t);return this._writableState.defaultEncoding=t,this},Object.defineProperty(w.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(w.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),w.prototype._write=function(t,e,r){r(new h("_write()"))},w.prototype._writev=null,w.prototype.end=function(t,e,r){var n=this._writableState;return"function"==typeof t?(r=t,t=null,e=null):"function"==typeof e&&(r=e,e=null),null!=t&&this.write(t,e),n.corked&&(n.corked=1,this.uncork()),n.ending||function(t,e,r){e.ending=!0,x(t,e),r&&(e.finished?process.nextTick(r):t.once("finish",r));e.ended=!0,t.writable=!1}(this,n,r),this},Object.defineProperty(w.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(w.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(t){this._writableState&&(this._writableState.destroyed=t)}}),w.prototype.destroy=a.destroy,w.prototype._undestroy=a.undestroy,w.prototype._destroy=function(t,e){e(t)},yU}function wU(){if(mU)return bU;mU=1;var t=Object.keys||function(t){var e=[];for(var r in t)e.push(r);return e};bU=s;var e=MU(),r=vU();Ca(s,e);for(var n=t(r.prototype),i=0;i<n.length;i++){var o=n[i];s.prototype[o]||(s.prototype[o]=r.prototype[o])}function s(t){if(!(this instanceof s))return new s(t);e.call(this,t),r.call(this,t),this.allowHalfOpen=!0,t&&(!1===t.readable&&(this.readable=!1),!1===t.writable&&(this.writable=!1),!1===t.allowHalfOpen&&(this.allowHalfOpen=!1,this.once("end",a)))}function a(){this._writableState.ended||process.nextTick(l,this)}function l(t){t.end()}return Object.defineProperty(s.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(s.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(s.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(s.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed&&this._writableState.destroyed)},set:function(t){void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed=t,this._writableState.destroyed=t)}}),bU}var SU=cU.codes.ERR_STREAM_PREMATURE_CLOSE;function EU(){}var RU,kU,TU,xU,AU,OU,LU=function t(e,r,n){if("function"==typeof r)return t(e,null,r);r||(r={}),n=function(t){var e=!1;return function(){if(!e){e=!0;for(var r=arguments.length,n=new Array(r),i=0;i<r;i++)n[i]=arguments[i];t.apply(this,n)}}}(n||EU);var i=r.readable||!1!==r.readable&&e.readable,o=r.writable||!1!==r.writable&&e.writable,s=function(){e.writable||l()},a=e._writableState&&e._writableState.finished,l=function(){o=!1,a=!0,i||n.call(e)},u=e._readableState&&e._readableState.endEmitted,c=function(){i=!1,u=!0,o||n.call(e)},h=function(t){n.call(e,t)},f=function(){var t;return i&&!u?(e._readableState&&e._readableState.ended||(t=new SU),n.call(e,t)):o&&!a?(e._writableState&&e._writableState.ended||(t=new SU),n.call(e,t)):void 0},d=function(){e.req.on("finish",l)};return!function(t){return t.setHeader&&"function"==typeof t.abort}(e)?o&&!e._writableState&&(e.on("end",s),e.on("close",s)):(e.on("complete",l),e.on("abort",f),e.req?d():e.on("request",d)),e.on("end",c),e.on("finish",l),!1!==r.error&&e.on("error",h),e.on("close",f),function(){e.removeListener("complete",l),e.removeListener("abort",f),e.removeListener("request",d),e.req&&e.req.removeListener("finish",l),e.removeListener("end",s),e.removeListener("close",s),e.removeListener("finish",l),e.removeListener("end",c),e.removeListener("error",h),e.removeListener("close",f)}};function jU(){if(kU)return RU;var t;function e(t,e,r){return(e=function(t){var e=function(t,e){if("object"!=typeof t||null===t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var n=r.call(t,e||"default");if("object"!=typeof n)return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"==typeof e?e:String(e)}(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}kU=1;var r=LU,n=Symbol("lastResolve"),i=Symbol("lastReject"),o=Symbol("error"),s=Symbol("ended"),a=Symbol("lastPromise"),l=Symbol("handlePromise"),u=Symbol("stream");function c(t,e){return{value:t,done:e}}function h(t){var e=t[n];if(null!==e){var r=t[u].read();null!==r&&(t[a]=null,t[n]=null,t[i]=null,e(c(r,!1)))}}function f(t){process.nextTick(h,t)}var d=Object.getPrototypeOf(function(){}),p=Object.setPrototypeOf((t={get stream(){return this[u]},next:function(){var t=this,e=this[o];if(null!==e)return Promise.reject(e);if(this[s])return Promise.resolve(c(void 0,!0));if(this[u].destroyed)return new Promise(function(e,r){process.nextTick(function(){t[o]?r(t[o]):e(c(void 0,!0))})});var r,n=this[a];if(n)r=new Promise(function(t,e){return function(r,n){t.then(function(){e[s]?r(c(void 0,!0)):e[l](r,n)},n)}}(n,this));else{var i=this[u].read();if(null!==i)return Promise.resolve(c(i,!1));r=new Promise(this[l])}return this[a]=r,r}},e(t,Symbol.asyncIterator,function(){return this}),e(t,"return",function(){var t=this;return new Promise(function(e,r){t[u].destroy(null,function(t){t?r(t):e(c(void 0,!0))})})}),t),d);return RU=function(t){var h,d=Object.create(p,(e(h={},u,{value:t,writable:!0}),e(h,n,{value:null,writable:!0}),e(h,i,{value:null,writable:!0}),e(h,o,{value:null,writable:!0}),e(h,s,{value:t._readableState.endEmitted,writable:!0}),e(h,l,{value:function(t,e){var r=d[u].read();r?(d[a]=null,d[n]=null,d[i]=null,t(c(r,!1))):(d[n]=t,d[i]=e)},writable:!0}),h));return d[a]=null,r(t,function(t){if(t&&"ERR_STREAM_PREMATURE_CLOSE"!==t.code){var e=d[i];return null!==e&&(d[a]=null,d[n]=null,d[i]=null,e(t)),void(d[o]=t)}var r=d[n];null!==r&&(d[a]=null,d[n]=null,d[i]=null,r(c(void 0,!0))),d[s]=!0}),t.on("readable",f.bind(null,d)),d},RU}function MU(){if(OU)return AU;var t;OU=1,AU=w,w.ReadableState=v,yn.EventEmitter;var e=function(t,e){return t.listeners(e).length},r=iU(),n=ca.Buffer,i=(void 0!==Ft?Ft:"undefined"!=typeof window?window:"undefined"!=typeof self?self:{}).Uint8Array||function(){};var o,s=Na;o=s&&s.debuglog?s.debuglog("stream"):function(){};var a,l,u,c=oU(),h=uU,f=_U.getHighWaterMark,d=cU.codes,p=d.ERR_INVALID_ARG_TYPE,y=d.ERR_STREAM_PUSH_AFTER_EOF,g=d.ERR_METHOD_NOT_IMPLEMENTED,b=d.ERR_STREAM_UNSHIFT_AFTER_END_EVENT;Ca(w,r);var m=h.errorOrDestroy,_=["error","close","destroy","pause","resume"];function v(e,r,n){t=t||wU(),e=e||{},"boolean"!=typeof n&&(n=r instanceof t),this.objectMode=!!e.objectMode,n&&(this.objectMode=this.objectMode||!!e.readableObjectMode),this.highWaterMark=f(this,e,"readableHighWaterMark",n),this.buffer=new c,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=!1!==e.emitClose,this.autoDestroy=!!e.autoDestroy,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(a||(a=el().StringDecoder),this.decoder=new a(e.encoding),this.encoding=e.encoding)}function w(e){if(t=t||wU(),!(this instanceof w))return new w(e);var n=this instanceof t;this._readableState=new v(e,this,n),this.readable=!0,e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy&&(this._destroy=e.destroy)),r.call(this)}function S(t,e,r,s,a){o("readableAddChunk",e);var l,u=t._readableState;if(null===e)u.reading=!1,function(t,e){if(o("onEofChunk"),e.ended)return;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?T(t):(e.needReadable=!1,e.emittedReadable||(e.emittedReadable=!0,x(t)))}(t,u);else if(a||(l=function(t,e){var r;o=e,n.isBuffer(o)||o instanceof i||"string"==typeof e||void 0===e||t.objectMode||(r=new p("chunk",["string","Buffer","Uint8Array"],e));var o;return r}(u,e)),l)m(t,l);else if(u.objectMode||e&&e.length>0)if("string"==typeof e||u.objectMode||Object.getPrototypeOf(e)===n.prototype||(e=function(t){return n.from(t)}(e)),s)u.endEmitted?m(t,new b):E(t,u,e,!0);else if(u.ended)m(t,new y);else{if(u.destroyed)return!1;u.reading=!1,u.decoder&&!r?(e=u.decoder.write(e),u.objectMode||0!==e.length?E(t,u,e,!1):A(t,u)):E(t,u,e,!1)}else s||(u.reading=!1,A(t,u));return!u.ended&&(u.length<u.highWaterMark||0===u.length)}function E(t,e,r,n){e.flowing&&0===e.length&&!e.sync?(e.awaitDrain=0,t.emit("data",r)):(e.length+=e.objectMode?1:r.length,n?e.buffer.unshift(r):e.buffer.push(r),e.needReadable&&T(t)),A(t,e)}Object.defineProperty(w.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._readableState&&this._readableState.destroyed},set:function(t){this._readableState&&(this._readableState.destroyed=t)}}),w.prototype.destroy=h.destroy,w.prototype._undestroy=h.undestroy,w.prototype._destroy=function(t,e){e(t)},w.prototype.push=function(t,e){var r,i=this._readableState;return i.objectMode?r=!0:"string"==typeof t&&((e=e||i.defaultEncoding)!==i.encoding&&(t=n.from(t,e),e=""),r=!0),S(this,t,e,!1,r)},w.prototype.unshift=function(t){return S(this,t,null,!0,!1)},w.prototype.isPaused=function(){return!1===this._readableState.flowing},w.prototype.setEncoding=function(t){a||(a=el().StringDecoder);var e=new a(t);this._readableState.decoder=e,this._readableState.encoding=this._readableState.decoder.encoding;for(var r=this._readableState.buffer.head,n="";null!==r;)n+=e.write(r.data),r=r.next;return this._readableState.buffer.clear(),""!==n&&this._readableState.buffer.push(n),this._readableState.length=n.length,this};var R=1073741824;function k(t,e){return t<=0||0===e.length&&e.ended?0:e.objectMode?1:t!=t?e.flowing&&e.length?e.buffer.head.data.length:e.length:(t>e.highWaterMark&&(e.highWaterMark=function(t){return t>=R?t=R:(t--,t|=t>>>1,t|=t>>>2,t|=t>>>4,t|=t>>>8,t|=t>>>16,t++),t}(t)),t<=e.length?t:e.ended?e.length:(e.needReadable=!0,0))}function T(t){var e=t._readableState;o("emitReadable",e.needReadable,e.emittedReadable),e.needReadable=!1,e.emittedReadable||(o("emitReadable",e.flowing),e.emittedReadable=!0,process.nextTick(x,t))}function x(t){var e=t._readableState;o("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,I(t)}function A(t,e){e.readingMore||(e.readingMore=!0,process.nextTick(O,t,e))}function O(t,e){for(;!e.reading&&!e.ended&&(e.length<e.highWaterMark||e.flowing&&0===e.length);){var r=e.length;if(o("maybeReadMore read 0"),t.read(0),r===e.length)break}e.readingMore=!1}function L(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 j(t){o("readable nexttick read 0"),t.read(0)}function M(t,e){o("resume",e.reading),e.reading||t.read(0),e.resumeScheduled=!1,t.emit("resume"),I(t),e.flowing&&!e.reading&&t.read(0)}function I(t){var e=t._readableState;for(o("flow",e.flowing);e.flowing&&null!==t.read(););}function P(t,e){return 0===e.length?null:(e.objectMode?r=e.buffer.shift():!t||t>=e.length?(r=e.decoder?e.buffer.join(""):1===e.buffer.length?e.buffer.first():e.buffer.concat(e.length),e.buffer.clear()):r=e.buffer.consume(t,e.decoder),r);var r}function D(t){var e=t._readableState;o("endReadable",e.endEmitted),e.endEmitted||(e.ended=!0,process.nextTick(C,e,t))}function C(t,e){if(o("endReadableNT",t.endEmitted,t.length),!t.endEmitted&&0===t.length&&(t.endEmitted=!0,e.readable=!1,e.emit("end"),t.autoDestroy)){var r=e._writableState;(!r||r.autoDestroy&&r.finished)&&e.destroy()}}function N(t,e){for(var r=0,n=t.length;r<n;r++)if(t[r]===e)return r;return-1}return w.prototype.read=function(t){o("read",t),t=parseInt(t,10);var e=this._readableState,r=t;if(0!==t&&(e.emittedReadable=!1),0===t&&e.needReadable&&((0!==e.highWaterMark?e.length>=e.highWaterMark:e.length>0)||e.ended))return o("read: emitReadable",e.length,e.ended),0===e.length&&e.ended?D(this):T(this),null;if(0===(t=k(t,e))&&e.ended)return 0===e.length&&D(this),null;var n,i=e.needReadable;return o("need readable",i),(0===e.length||e.length-t<e.highWaterMark)&&o("length less than watermark",i=!0),e.ended||e.reading?o("reading or ended",i=!1):i&&(o("do read"),e.reading=!0,e.sync=!0,0===e.length&&(e.needReadable=!0),this._read(e.highWaterMark),e.sync=!1,e.reading||(t=k(r,e))),null===(n=t>0?P(t,e):null)?(e.needReadable=e.length<=e.highWaterMark,t=0):(e.length-=t,e.awaitDrain=0),0===e.length&&(e.ended||(e.needReadable=!0),r!==t&&e.ended&&D(this)),null!==n&&this.emit("data",n),n},w.prototype._read=function(t){m(this,new g("_read()"))},w.prototype.pipe=function(t,r){var n=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)}i.pipesCount+=1,o("pipe count=%d opts=%j",i.pipesCount,r);var s=(!r||!1!==r.end)&&t!==process.stdout&&t!==process.stderr?l:y;function a(e,r){o("onunpipe"),e===n&&r&&!1===r.hasUnpiped&&(r.hasUnpiped=!0,o("cleanup"),t.removeListener("close",d),t.removeListener("finish",p),t.removeListener("drain",u),t.removeListener("error",f),t.removeListener("unpipe",a),n.removeListener("end",l),n.removeListener("end",y),n.removeListener("data",h),c=!0,!i.awaitDrain||t._writableState&&!t._writableState.needDrain||u())}function l(){o("onend"),t.end()}i.endEmitted?process.nextTick(s):n.once("end",s),t.on("unpipe",a);var u=function(t){return function(){var r=t._readableState;o("pipeOnDrain",r.awaitDrain),r.awaitDrain&&r.awaitDrain--,0===r.awaitDrain&&e(t,"data")&&(r.flowing=!0,I(t))}}(n);t.on("drain",u);var c=!1;function h(e){o("ondata");var r=t.write(e);o("dest.write",r),!1===r&&((1===i.pipesCount&&i.pipes===t||i.pipesCount>1&&-1!==N(i.pipes,t))&&!c&&(o("false write response, pause",i.awaitDrain),i.awaitDrain++),n.pause())}function f(r){o("onerror",r),y(),t.removeListener("error",f),0===e(t,"error")&&m(t,r)}function d(){t.removeListener("finish",p),y()}function p(){o("onfinish"),t.removeListener("close",d),y()}function y(){o("unpipe"),n.unpipe(t)}return n.on("data",h),function(t,e,r){if("function"==typeof t.prependListener)return t.prependListener(e,r);t._events&&t._events[e]?Array.isArray(t._events[e])?t._events[e].unshift(r):t._events[e]=[r,t._events[e]]:t.on(e,r)}(t,"error",f),t.once("close",d),t.once("finish",p),t.emit("pipe",n),i.flowing||(o("pipe resume"),n.resume()),t},w.prototype.unpipe=function(t){var e=this._readableState,r={hasUnpiped:!1};if(0===e.pipesCount)return this;if(1===e.pipesCount)return t&&t!==e.pipes||(t||(t=e.pipes),e.pipes=null,e.pipesCount=0,e.flowing=!1,t&&t.emit("unpipe",this,r)),this;if(!t){var n=e.pipes,i=e.pipesCount;e.pipes=null,e.pipesCount=0,e.flowing=!1;for(var o=0;o<i;o++)n[o].emit("unpipe",this,{hasUnpiped:!1});return this}var s=N(e.pipes,t);return-1===s||(e.pipes.splice(s,1),e.pipesCount-=1,1===e.pipesCount&&(e.pipes=e.pipes[0]),t.emit("unpipe",this,r)),this},w.prototype.on=function(t,e){var n=r.prototype.on.call(this,t,e),i=this._readableState;return"data"===t?(i.readableListening=this.listenerCount("readable")>0,!1!==i.flowing&&this.resume()):"readable"===t&&(i.endEmitted||i.readableListening||(i.readableListening=i.needReadable=!0,i.flowing=!1,i.emittedReadable=!1,o("on readable",i.length,i.reading),i.length?T(this):i.reading||process.nextTick(j,this))),n},w.prototype.addListener=w.prototype.on,w.prototype.removeListener=function(t,e){var n=r.prototype.removeListener.call(this,t,e);return"readable"===t&&process.nextTick(L,this),n},w.prototype.removeAllListeners=function(t){var e=r.prototype.removeAllListeners.apply(this,arguments);return"readable"!==t&&void 0!==t||process.nextTick(L,this),e},w.prototype.resume=function(){var t=this._readableState;return t.flowing||(o("resume"),t.flowing=!t.readableListening,function(t,e){e.resumeScheduled||(e.resumeScheduled=!0,process.nextTick(M,t,e))}(this,t)),t.paused=!1,this},w.prototype.pause=function(){return o("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(o("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this},w.prototype.wrap=function(t){var e=this,r=this._readableState,n=!1;for(var i in t.on("end",function(){if(o("wrapped end"),r.decoder&&!r.ended){var t=r.decoder.end();t&&t.length&&e.push(t)}e.push(null)}),t.on("data",function(i){(o("wrapped data"),r.decoder&&(i=r.decoder.write(i)),r.objectMode&&null==i)||(r.objectMode||i&&i.length)&&(e.push(i)||(n=!0,t.pause()))}),t)void 0===this[i]&&"function"==typeof t[i]&&(this[i]=function(e){return function(){return t[e].apply(t,arguments)}}(i));for(var s=0;s<_.length;s++)t.on(_[s],this.emit.bind(this,_[s]));return this._read=function(e){o("wrapped _read",e),n&&(n=!1,t.resume())},this},"function"==typeof Symbol&&(w.prototype[Symbol.asyncIterator]=function(){return void 0===l&&(l=jU()),l(this)}),Object.defineProperty(w.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),Object.defineProperty(w.prototype,"readableBuffer",{enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}}),Object.defineProperty(w.prototype,"readableFlowing",{enumerable:!1,get:function(){return this._readableState.flowing},set:function(t){this._readableState&&(this._readableState.flowing=t)}}),w._fromList=P,Object.defineProperty(w.prototype,"readableLength",{enumerable:!1,get:function(){return this._readableState.length}}),"function"==typeof Symbol&&(w.from=function(t,e){return void 0===u&&(u=xU?TU:(xU=1,TU=function(){throw new Error("Readable.from is not available in the browser")})),u(w,t,e)}),AU}var IU=UU,PU=cU.codes,DU=PU.ERR_METHOD_NOT_IMPLEMENTED,CU=PU.ERR_MULTIPLE_CALLBACK,NU=PU.ERR_TRANSFORM_ALREADY_TRANSFORMING,FU=PU.ERR_TRANSFORM_WITH_LENGTH_0,BU=wU();function WU(t,e){var r=this._transformState;r.transforming=!1;var n=r.writecb;if(null===n)return this.emit("error",new CU);r.writechunk=null,r.writecb=null,null!=e&&this.push(e),n(t);var i=this._readableState;i.reading=!1,(i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}function UU(t){if(!(this instanceof UU))return new UU(t);BU.call(this,t),this._transformState={afterTransform:WU.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,t&&("function"==typeof t.transform&&(this._transform=t.transform),"function"==typeof t.flush&&(this._flush=t.flush)),this.on("prefinish",zU)}function zU(){var t=this;"function"!=typeof this._flush||this._readableState.destroyed?$U(this,null,null):this._flush(function(e,r){$U(t,e,r)})}function $U(t,e,r){if(e)return t.emit("error",e);if(null!=r&&t.push(r),t._writableState.length)throw new FU;if(t._transformState.transforming)throw new NU;return t.push(null)}Ca(UU,BU),UU.prototype.push=function(t,e){return this._transformState.needTransform=!1,BU.prototype.push.call(this,t,e)},UU.prototype._transform=function(t,e,r){r(new DU("_transform()"))},UU.prototype._write=function(t,e,r){var n=this._transformState;if(n.writecb=r,n.writechunk=t,n.writeencoding=e,!n.transforming){var i=this._readableState;(n.needTransform||i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}},UU.prototype._read=function(t){var e=this._transformState;null===e.writechunk||e.transforming?e.needTransform=!0:(e.transforming=!0,this._transform(e.writechunk,e.writeencoding,e.afterTransform))},UU.prototype._destroy=function(t,e){BU.prototype._destroy.call(this,t,function(t){e(t)})};var HU,GU=VU,qU=IU;function VU(t){if(!(this instanceof VU))return new VU(t);qU.call(this,t)}Ca(VU,qU),VU.prototype._transform=function(t,e,r){r(null,t)};var ZU=cU.codes,YU=ZU.ERR_MISSING_ARGS,KU=ZU.ERR_STREAM_DESTROYED;function QU(t){if(t)throw t}function JU(t){t()}function XU(t,e){return t.pipe(e)}var tz=function(){for(var t=arguments.length,e=new Array(t),r=0;r<t;r++)e[r]=arguments[r];var n,i=function(t){return t.length?"function"!=typeof t[t.length-1]?QU:t.pop():QU}(e);if(Array.isArray(e[0])&&(e=e[0]),e.length<2)throw new YU("streams");var o=e.map(function(t,r){var s=r<e.length-1;return function(t,e,r,n){n=function(t){var e=!1;return function(){e||(e=!0,t.apply(void 0,arguments))}}(n);var i=!1;t.on("close",function(){i=!0}),void 0===HU&&(HU=LU),HU(t,{readable:e,writable:r},function(t){if(t)return n(t);i=!0,n()});var o=!1;return function(e){if(!i&&!o)return o=!0,function(t){return t.setHeader&&"function"==typeof t.abort}(t)?t.abort():"function"==typeof t.destroy?t.destroy():void n(e||new KU("pipe"))}}(t,s,r>0,function(t){n||(n=t),t&&o.forEach(JU),s||(o.forEach(JU),i(n))})});return e.reduce(XU)};!function(t,e){(e=t.exports=MU()).Stream=e,e.Readable=e,e.Writable=vU(),e.Duplex=wU(),e.Transform=IU,e.PassThrough=GU,e.finished=LU,e.pipeline=tz}(nU,nU.exports);var ez=nU.exports,rz={exports:{}},nz=9007199254740991,iz="[object Arguments]",oz="[object Function]",sz="[object GeneratorFunction]",az="object"==typeof Ft&&Ft&&Ft.Object===Object&&Ft,lz="object"==typeof self&&self&&self.Object===Object&&self,uz=az||lz||Function("return this")();function cz(t,e){for(var r=-1,n=e.length,i=t.length;++r<n;)t[i+r]=e[r];return t}var hz=Object.prototype,fz=hz.hasOwnProperty,dz=hz.toString,pz=uz.Symbol,yz=hz.propertyIsEnumerable,gz=pz?pz.isConcatSpreadable:void 0;function bz(t,e,r,n,i){var o=-1,s=t.length;for(r||(r=mz),i||(i=[]);++o<s;){var a=t[o];e>0&&r(a)?e>1?bz(a,e-1,r,n,i):cz(i,a):n||(i[i.length]=a)}return i}function mz(t){return _z(t)||function(t){return function(t){return function(t){return!!t&&"object"==typeof t}(t)&&function(t){return null!=t&&function(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=nz}(t.length)&&!function(t){var e=function(t){var e=typeof t;return!!t&&("object"==e||"function"==e)}(t)?dz.call(t):"";return e==oz||e==sz}(t)}(t)}(t)&&fz.call(t,"callee")&&(!yz.call(t,"callee")||dz.call(t)==iz)}(t)||!!(gz&&t&&t[gz])}var _z=Array.isArray;var vz=function(t){return(t?t.length:0)?bz(t,1):[]},wz="__lodash_hash_undefined__",Sz=9007199254740991,Ez="[object Arguments]",Rz=/^\[object .+?Constructor\]$/,kz="object"==typeof Ft&&Ft&&Ft.Object===Object&&Ft,Tz="object"==typeof self&&self&&self.Object===Object&&self,xz=kz||Tz||Function("return this")();function Az(t,e){return!!(t?t.length:0)&&function(t,e,r){if(e!=e)return function(t,e,r,n){var i=t.length,o=r+(n?1:-1);for(;n?o--:++o<i;)if(e(t[o],o,t))return o;return-1}(t,jz,r);var n=r-1,i=t.length;for(;++n<i;)if(t[n]===e)return n;return-1}(t,e,0)>-1}function Oz(t,e,r){for(var n=-1,i=t?t.length:0;++n<i;)if(r(e,t[n]))return!0;return!1}function Lz(t,e){for(var r=-1,n=e.length,i=t.length;++r<n;)t[i+r]=e[r];return t}function jz(t){return t!=t}function Mz(t,e){return t.has(e)}var Iz=Array.prototype,Pz=Function.prototype,Dz=Object.prototype,Cz=xz["__core-js_shared__"],Nz=function(){var t=/[^.]+$/.exec(Cz&&Cz.keys&&Cz.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""}(),Fz=Pz.toString,Bz=Dz.hasOwnProperty,Wz=Dz.toString,Uz=RegExp("^"+Fz.call(Bz).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),zz=xz.Symbol,$z=Dz.propertyIsEnumerable,Hz=Iz.splice,Gz=zz?zz.isConcatSpreadable:void 0,qz=Math.max,Vz=i$(xz,"Map"),Zz=i$(Object,"create");function Yz(t){var e=-1,r=t?t.length:0;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}function Kz(t){var e=-1,r=t?t.length:0;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}function Qz(t){var e=-1,r=t?t.length:0;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}function Jz(t){var e=-1,r=t?t.length:0;for(this.__data__=new Qz;++e<r;)this.add(t[e])}function Xz(t,e){for(var r=t.length;r--;)if(a$(t[r][0],e))return r;return-1}function t$(t,e,r,n){var i=-1,o=Az,s=!0,a=t.length,l=[],u=e.length;if(!a)return l;r&&(e=function(t,e){for(var r=-1,n=t?t.length:0,i=Array(n);++r<n;)i[r]=e(t[r],r,t);return i}(e,function(t){return function(e){return t(e)}}(r))),n?(o=Oz,s=!1):e.length>=200&&(o=Mz,s=!1,e=new Jz(e));t:for(;++i<a;){var c=t[i],h=r?r(c):c;if(c=n||0!==c?c:0,s&&h==h){for(var f=u;f--;)if(e[f]===h)continue t;l.push(c)}else o(e,h,n)||l.push(c)}return l}function e$(t,e,r,n,i){var o=-1,s=t.length;for(r||(r=o$),i||(i=[]);++o<s;){var a=t[o];e>0&&r(a)?e>1?e$(a,e-1,r,n,i):Lz(i,a):n||(i[i.length]=a)}return i}function r$(t){if(!f$(t)||function(t){return!!Nz&&Nz in t}(t))return!1;var e=h$(t)||function(t){var e=!1;if(null!=t&&"function"!=typeof t.toString)try{e=!!(t+"")}catch(t){}return e}(t)?Uz:Rz;return e.test(function(t){if(null!=t){try{return Fz.call(t)}catch(t){}try{return t+""}catch(t){}}return""}(t))}function n$(t,e){var r,n,i=t.__data__;return("string"==(n=typeof(r=e))||"number"==n||"symbol"==n||"boolean"==n?"__proto__"!==r:null===r)?i["string"==typeof e?"string":"hash"]:i.map}function i$(t,e){var r=function(t,e){return null==t?void 0:t[e]}(t,e);return r$(r)?r:void 0}function o$(t){return l$(t)||function(t){return c$(t)&&Bz.call(t,"callee")&&(!$z.call(t,"callee")||Wz.call(t)==Ez)}(t)||!!(Gz&&t&&t[Gz])}Yz.prototype.clear=function(){this.__data__=Zz?Zz(null):{}},Yz.prototype.delete=function(t){return this.has(t)&&delete this.__data__[t]},Yz.prototype.get=function(t){var e=this.__data__;if(Zz){var r=e[t];return r===wz?void 0:r}return Bz.call(e,t)?e[t]:void 0},Yz.prototype.has=function(t){var e=this.__data__;return Zz?void 0!==e[t]:Bz.call(e,t)},Yz.prototype.set=function(t,e){return this.__data__[t]=Zz&&void 0===e?wz:e,this},Kz.prototype.clear=function(){this.__data__=[]},Kz.prototype.delete=function(t){var e=this.__data__,r=Xz(e,t);return!(r<0)&&(r==e.length-1?e.pop():Hz.call(e,r,1),!0)},Kz.prototype.get=function(t){var e=this.__data__,r=Xz(e,t);return r<0?void 0:e[r][1]},Kz.prototype.has=function(t){return Xz(this.__data__,t)>-1},Kz.prototype.set=function(t,e){var r=this.__data__,n=Xz(r,t);return n<0?r.push([t,e]):r[n][1]=e,this},Qz.prototype.clear=function(){this.__data__={hash:new Yz,map:new(Vz||Kz),string:new Yz}},Qz.prototype.delete=function(t){return n$(this,t).delete(t)},Qz.prototype.get=function(t){return n$(this,t).get(t)},Qz.prototype.has=function(t){return n$(this,t).has(t)},Qz.prototype.set=function(t,e){return n$(this,t).set(t,e),this},Jz.prototype.add=Jz.prototype.push=function(t){return this.__data__.set(t,wz),this},Jz.prototype.has=function(t){return this.__data__.has(t)};var s$=function(t,e){return e=qz(void 0===e?t.length-1:e,0),function(){for(var r=arguments,n=-1,i=qz(r.length-e,0),o=Array(i);++n<i;)o[n]=r[e+n];n=-1;for(var s=Array(e+1);++n<e;)s[n]=r[n];return s[e]=o,function(t,e,r){switch(r.length){case 0:return t.call(e);case 1:return t.call(e,r[0]);case 2:return t.call(e,r[0],r[1]);case 3:return t.call(e,r[0],r[1],r[2])}return t.apply(e,r)}(t,this,s)}}(function(t,e){return c$(t)?t$(t,e$(e,1,c$,!0)):[]});function a$(t,e){return t===e||t!=t&&e!=e}var l$=Array.isArray;function u$(t){return null!=t&&function(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=Sz}(t.length)&&!h$(t)}function c$(t){return function(t){return!!t&&"object"==typeof t}(t)&&u$(t)}function h$(t){var e=f$(t)?Wz.call(t):"";return"[object Function]"==e||"[object GeneratorFunction]"==e}function f$(t){var e=typeof t;return!!t&&("object"==e||"function"==e)}var d$=s$,p$="__lodash_hash_undefined__",y$=9007199254740991,g$="[object Arguments]",b$=/^\[object .+?Constructor\]$/,m$="object"==typeof Ft&&Ft&&Ft.Object===Object&&Ft,_$="object"==typeof self&&self&&self.Object===Object&&self,v$=m$||_$||Function("return this")();function w$(t,e){return!!(t?t.length:0)&&function(t,e,r){if(e!=e)return function(t,e,r,n){var i=t.length,o=r+(n?1:-1);for(;n?o--:++o<i;)if(e(t[o],o,t))return o;return-1}(t,R$,r);var n=r-1,i=t.length;for(;++n<i;)if(t[n]===e)return n;return-1}(t,e,0)>-1}function S$(t,e,r){for(var n=-1,i=t?t.length:0;++n<i;)if(r(e,t[n]))return!0;return!1}function E$(t,e){for(var r=-1,n=e.length,i=t.length;++r<n;)t[i+r]=e[r];return t}function R$(t){return t!=t}function k$(t,e){return t.has(e)}function T$(t){var e=-1,r=Array(t.size);return t.forEach(function(t){r[++e]=t}),r}var x$=Array.prototype,A$=Function.prototype,O$=Object.prototype,L$=v$["__core-js_shared__"],j$=function(){var t=/[^.]+$/.exec(L$&&L$.keys&&L$.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""}(),M$=A$.toString,I$=O$.hasOwnProperty,P$=O$.toString,D$=RegExp("^"+M$.call(I$).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),C$=v$.Symbol,N$=O$.propertyIsEnumerable,F$=x$.splice,B$=C$?C$.isConcatSpreadable:void 0,W$=Math.max,U$=X$(v$,"Map"),z$=X$(v$,"Set"),$$=X$(Object,"create");function H$(t){var e=-1,r=t?t.length:0;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}function G$(t){var e=-1,r=t?t.length:0;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}function q$(t){var e=-1,r=t?t.length:0;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}function V$(t){var e=-1,r=t?t.length:0;for(this.__data__=new q$;++e<r;)this.add(t[e])}function Z$(t,e){for(var r=t.length;r--;)if(rH(t[r][0],e))return r;return-1}function Y$(t,e,r,n,i){var o=-1,s=t.length;for(r||(r=tH),i||(i=[]);++o<s;){var a=t[o];e>0&&r(a)?e>1?Y$(a,e-1,r,n,i):E$(i,a):n||(i[i.length]=a)}return i}function K$(t){if(!aH(t)||function(t){return!!j$&&j$ in t}(t))return!1;var e=sH(t)||function(t){var e=!1;if(null!=t&&"function"!=typeof t.toString)try{e=!!(t+"")}catch(t){}return e}(t)?D$:b$;return e.test(function(t){if(null!=t){try{return M$.call(t)}catch(t){}try{return t+""}catch(t){}}return""}(t))}H$.prototype.clear=function(){this.__data__=$$?$$(null):{}},H$.prototype.delete=function(t){return this.has(t)&&delete this.__data__[t]},H$.prototype.get=function(t){var e=this.__data__;if($$){var r=e[t];return r===p$?void 0:r}return I$.call(e,t)?e[t]:void 0},H$.prototype.has=function(t){var e=this.__data__;return $$?void 0!==e[t]:I$.call(e,t)},H$.prototype.set=function(t,e){return this.__data__[t]=$$&&void 0===e?p$:e,this},G$.prototype.clear=function(){this.__data__=[]},G$.prototype.delete=function(t){var e=this.__data__,r=Z$(e,t);return!(r<0)&&(r==e.length-1?e.pop():F$.call(e,r,1),!0)},G$.prototype.get=function(t){var e=this.__data__,r=Z$(e,t);return r<0?void 0:e[r][1]},G$.prototype.has=function(t){return Z$(this.__data__,t)>-1},G$.prototype.set=function(t,e){var r=this.__data__,n=Z$(r,t);return n<0?r.push([t,e]):r[n][1]=e,this},q$.prototype.clear=function(){this.__data__={hash:new H$,map:new(U$||G$),string:new H$}},q$.prototype.delete=function(t){return J$(this,t).delete(t)},q$.prototype.get=function(t){return J$(this,t).get(t)},q$.prototype.has=function(t){return J$(this,t).has(t)},q$.prototype.set=function(t,e){return J$(this,t).set(t,e),this},V$.prototype.add=V$.prototype.push=function(t){return this.__data__.set(t,p$),this},V$.prototype.has=function(t){return this.__data__.has(t)};var Q$=z$&&1/T$(new z$([,-0]))[1]==1/0?function(t){return new z$(t)}:function(){};function J$(t,e){var r,n,i=t.__data__;return("string"==(n=typeof(r=e))||"number"==n||"symbol"==n||"boolean"==n?"__proto__"!==r:null===r)?i["string"==typeof e?"string":"hash"]:i.map}function X$(t,e){var r=function(t,e){return null==t?void 0:t[e]}(t,e);return K$(r)?r:void 0}function tH(t){return nH(t)||function(t){return oH(t)&&I$.call(t,"callee")&&(!N$.call(t,"callee")||P$.call(t)==g$)}(t)||!!(B$&&t&&t[B$])}var eH=function(t,e){return e=W$(void 0===e?t.length-1:e,0),function(){for(var r=arguments,n=-1,i=W$(r.length-e,0),o=Array(i);++n<i;)o[n]=r[e+n];n=-1;for(var s=Array(e+1);++n<e;)s[n]=r[n];return s[e]=o,function(t,e,r){switch(r.length){case 0:return t.call(e);case 1:return t.call(e,r[0]);case 2:return t.call(e,r[0],r[1]);case 3:return t.call(e,r[0],r[1],r[2])}return t.apply(e,r)}(t,this,s)}}(function(t){return function(t,e,r){var n=-1,i=w$,o=t.length,s=!0,a=[],l=a;if(r)s=!1,i=S$;else if(o>=200){var u=e?null:Q$(t);if(u)return T$(u);s=!1,i=k$,l=new V$}else l=e?[]:a;t:for(;++n<o;){var c=t[n],h=e?e(c):c;if(c=r||0!==c?c:0,s&&h==h){for(var f=l.length;f--;)if(l[f]===h)continue t;e&&l.push(h),a.push(c)}else i(l,h,r)||(l!==a&&l.push(h),a.push(c))}return a}(Y$(t,1,oH,!0))});function rH(t,e){return t===e||t!=t&&e!=e}var nH=Array.isArray;function iH(t){return null!=t&&function(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=y$}(t.length)&&!sH(t)}function oH(t){return function(t){return!!t&&"object"==typeof t}(t)&&iH(t)}function sH(t){var e=aH(t)?P$.call(t):"";return"[object Function]"==e||"[object GeneratorFunction]"==e}function aH(t){var e=typeof t;return!!t&&("object"==e||"function"==e)}var lH=eH;var uH=Function.prototype,cH=Object.prototype,hH=uH.toString,fH=cH.hasOwnProperty,dH=hH.call(Object),pH=cH.toString,yH=function(t,e){return function(r){return t(e(r))}}(Object.getPrototypeOf,Object);var gH,bH,mH,_H,vH,wH,SH,EH,RH,kH=function(t){if(!function(t){return!!t&&"object"==typeof t}(t)||"[object Object]"!=pH.call(t)||function(t){var e=!1;if(null!=t&&"function"!=typeof t.toString)try{e=!!(t+"")}catch(t){}return e}(t))return!1;var e=yH(t);if(null===e)return!0;var r=fH.call(e,"constructor")&&e.constructor;return"function"==typeof r&&r instanceof r&&hH.call(r)==dH},TH={};function xH(){if(gH)return TH;gH=1;var r=e,n="win32"===process.platform,i=t,o=process.env.NODE_DEBUG&&/fs/.test(process.env.NODE_DEBUG);function s(t){return"function"==typeof t?t:function(){var t;if(o){var e=new Error;t=function(t){t&&(e.message=t.message,r(t=e))}}else t=r;return t;function r(t){if(t){if(process.throwDeprecation)throw t;if(!process.noDeprecation){var e="fs: missing callback "+(t.stack||t.message);process.traceDeprecation?console.trace(e):console.error(e)}}}}()}if(r.normalize,n)var a=/(.*?)(?:[\/\\]+|$)/g;else a=/(.*?)(?:[\/]+|$)/g;if(n)var l=/^(?:[a-zA-Z]:|[\\\/]{2}[^\\\/]+[\\\/][^\\\/]+)?[\\\/]*/;else l=/^[\/]*/;return TH.realpathSync=function(t,e){if(t=r.resolve(t),e&&Object.prototype.hasOwnProperty.call(e,t))return e[t];var o,s,u,c,h=t,f={},d={};function p(){var e=l.exec(t);o=e[0].length,s=e[0],u=e[0],c="",n&&!d[u]&&(i.lstatSync(u),d[u]=!0)}for(p();o<t.length;){a.lastIndex=o;var y=a.exec(t);if(c=s,s+=y[0],u=c+y[1],o=a.lastIndex,!(d[u]||e&&e[u]===u)){var g;if(e&&Object.prototype.hasOwnProperty.call(e,u))g=e[u];else{var b=i.lstatSync(u);if(!b.isSymbolicLink()){d[u]=!0,e&&(e[u]=u);continue}var m=null;if(!n){var _=b.dev.toString(32)+":"+b.ino.toString(32);f.hasOwnProperty(_)&&(m=f[_])}null===m&&(i.statSync(u),m=i.readlinkSync(u)),g=r.resolve(c,m),e&&(e[u]=g),n||(f[_]=m)}t=r.resolve(g,t.slice(o)),p()}}return e&&(e[h]=t),t},TH.realpath=function(t,e,o){if("function"!=typeof o&&(o=s(e),e=null),t=r.resolve(t),e&&Object.prototype.hasOwnProperty.call(e,t))return process.nextTick(o.bind(null,null,e[t]));var u,c,h,f,d=t,p={},y={};function g(){var e=l.exec(t);u=e[0].length,c=e[0],h=e[0],f="",n&&!y[h]?i.lstat(h,function(t){if(t)return o(t);y[h]=!0,b()}):process.nextTick(b)}function b(){if(u>=t.length)return e&&(e[d]=t),o(null,t);a.lastIndex=u;var r=a.exec(t);return f=c,c+=r[0],h=f+r[1],u=a.lastIndex,y[h]||e&&e[h]===h?process.nextTick(b):e&&Object.prototype.hasOwnProperty.call(e,h)?v(e[h]):i.lstat(h,m)}function m(t,r){if(t)return o(t);if(!r.isSymbolicLink())return y[h]=!0,e&&(e[h]=h),process.nextTick(b);if(!n){var s=r.dev.toString(32)+":"+r.ino.toString(32);if(p.hasOwnProperty(s))return _(null,p[s],h)}i.stat(h,function(t){if(t)return o(t);i.readlink(h,function(t,e){n||(p[s]=e),_(t,e)})})}function _(t,n,i){if(t)return o(t);var s=r.resolve(f,n);e&&(e[i]=s),v(s)}function v(e){t=r.resolve(e,t.slice(u)),g()}g()},TH}function AH(){if(mH)return bH;mH=1,bH=l,l.realpath=l,l.sync=u,l.realpathSync=u,l.monkeypatch=function(){e.realpath=l,e.realpathSync=u},l.unmonkeypatch=function(){e.realpath=r,e.realpathSync=n};var e=t,r=e.realpath,n=e.realpathSync,i=process.version,o=/^v[0-5]\./.test(i),s=xH();function a(t){return t&&"realpath"===t.syscall&&("ELOOP"===t.code||"ENOMEM"===t.code||"ENAMETOOLONG"===t.code)}function l(t,e,n){if(o)return r(t,e,n);"function"==typeof e&&(n=e,e=null),r(t,e,function(r,i){a(r)?s.realpath(t,e,n):n(r,i)})}function u(t,e){if(o)return n(t,e);try{return n(t,e)}catch(r){if(a(r))return s.realpathSync(t,e);throw r}}return bH}function OH(){if(vH)return _H;vH=1,_H=function(e,r){for(var n=[],i=0;i<e.length;i++){var o=r(e[i],i);t(o)?n.push.apply(n,o):n.push(o)}return n};var t=Array.isArray||function(t){return"[object Array]"===Object.prototype.toString.call(t)};return _H}function LH(){if(SH)return wH;SH=1;var t=OH(),e=bn;wH=function(t){if(!t)return[];"{}"===t.substr(0,2)&&(t="\\{\\}"+t.substr(2));return p(function(t){return t.split("\\\\").join(r).split("\\{").join(n).split("\\}").join(i).split("\\,").join(o).split("\\.").join(s)}(t),!0).map(l)};var r="\0SLASH"+Math.random()+"\0",n="\0OPEN"+Math.random()+"\0",i="\0CLOSE"+Math.random()+"\0",o="\0COMMA"+Math.random()+"\0",s="\0PERIOD"+Math.random()+"\0";function a(t){return parseInt(t,10)==t?parseInt(t,10):t.charCodeAt(0)}function l(t){return t.split(r).join("\\").split(n).join("{").split(i).join("}").split(o).join(",").split(s).join(".")}function u(t){if(!t)return[""];var r=[],n=e("{","}",t);if(!n)return t.split(",");var i=n.pre,o=n.body,s=n.post,a=i.split(",");a[a.length-1]+="{"+o+"}";var l=u(s);return s.length&&(a[a.length-1]+=l.shift(),a.push.apply(a,l)),r.push.apply(r,a),r}function c(t){return"{"+t+"}"}function h(t){return/^-?0\d/.test(t)}function f(t,e){return t<=e}function d(t,e){return t>=e}function p(r,n){var o=[],s=e("{","}",r);if(!s||/\$$/.test(s.pre))return[r];var l,y=/^-?\d+\.\.-?\d+(?:\.\.-?\d+)?$/.test(s.body),g=/^[a-zA-Z]\.\.[a-zA-Z](?:\.\.-?\d+)?$/.test(s.body),b=y||g,m=s.body.indexOf(",")>=0;if(!b&&!m)return s.post.match(/,(?!,).*\}/)?p(r=s.pre+"{"+s.body+i+s.post):[r];if(b)l=s.body.split(/\.\./);else if(1===(l=u(s.body)).length&&1===(l=p(l[0],!1).map(c)).length)return(w=s.post.length?p(s.post,!1):[""]).map(function(t){return s.pre+l[0]+t});var _,v=s.pre,w=s.post.length?p(s.post,!1):[""];if(b){var S=a(l[0]),E=a(l[1]),R=Math.max(l[0].length,l[1].length),k=3==l.length?Math.abs(a(l[2])):1,T=f;E<S&&(k*=-1,T=d);var x=l.some(h);_=[];for(var A=S;T(A,E);A+=k){var O;if(g)"\\"===(O=String.fromCharCode(A))&&(O="");else if(O=String(A),x){var L=R-O.length;if(L>0){var j=new Array(L+1).join("0");O=A<0?"-"+j+O.slice(1):j+O}}_.push(O)}}else _=t(l,function(t){return p(t,!1)});for(var M=0;M<_.length;M++)for(var I=0;I<w.length;I++){var P=v+_[M]+w[I];(!n||b||P)&&o.push(P)}return o}return wH}function jH(){if(RH)return EH;RH=1,EH=u,u.Minimatch=c;var t=function(){try{return require("path")}catch(t){}}()||{sep:"/"};u.sep=t.sep;var e=u.GLOBSTAR=c.GLOBSTAR={},r=LH(),n={"!":{open:"(?:(?!(?:",close:"))[^/]*?)"},"?":{open:"(?:",close:")?"},"+":{open:"(?:",close:")+"},"*":{open:"(?:",close:")*"},"@":{open:"(?:",close:")"}},i="[^/]",o=i+"*?",s="().*{}+?[]^$\\!".split("").reduce(function(t,e){return t[e]=!0,t},{});var a=/\/+/;function l(t,e){e=e||{};var r={};return Object.keys(t).forEach(function(e){r[e]=t[e]}),Object.keys(e).forEach(function(t){r[t]=e[t]}),r}function u(t,e,r){return f(e),r||(r={}),!(!r.nocomment&&"#"===e.charAt(0))&&new c(e,r).match(t)}function c(e,r){if(!(this instanceof c))return new c(e,r);f(e),r||(r={}),e=e.trim(),r.allowWindowsEscape||"/"===t.sep||(e=e.split(t.sep).join("/")),this.options=r,this.set=[],this.pattern=e,this.regexp=null,this.negate=!1,this.comment=!1,this.empty=!1,this.partial=!!r.partial,this.make()}function h(t,e){return e||(e=this instanceof c?this.options:{}),t=void 0===t?this.pattern:t,f(t),e.nobrace||!/\{(?:(?!\{).)*\}/.test(t)?[t]:r(t)}u.filter=function(t,e){return e=e||{},function(r,n,i){return u(r,t,e)}},u.defaults=function(t){if(!t||"object"!=typeof t||!Object.keys(t).length)return u;var e=u,r=function(r,n,i){return e(r,n,l(t,i))};return r.Minimatch=function(r,n){return new e.Minimatch(r,l(t,n))},r.Minimatch.defaults=function(r){return e.defaults(l(t,r)).Minimatch},r.filter=function(r,n){return e.filter(r,l(t,n))},r.defaults=function(r){return e.defaults(l(t,r))},r.makeRe=function(r,n){return e.makeRe(r,l(t,n))},r.braceExpand=function(r,n){return e.braceExpand(r,l(t,n))},r.match=function(r,n,i){return e.match(r,n,l(t,i))},r},c.defaults=function(t){return u.defaults(t).Minimatch},c.prototype.debug=function(){},c.prototype.make=function(){var t=this.pattern,e=this.options;if(!e.nocomment&&"#"===t.charAt(0))return void(this.comment=!0);if(!t)return void(this.empty=!0);this.parseNegate();var r=this.globSet=this.braceExpand();e.debug&&(this.debug=function(){console.error.apply(console,arguments)});this.debug(this.pattern,r),r=this.globParts=r.map(function(t){return t.split(a)}),this.debug(this.pattern,r),r=r.map(function(t,e,r){return t.map(this.parse,this)},this),this.debug(this.pattern,r),r=r.filter(function(t){return-1===t.indexOf(!1)}),this.debug(this.pattern,r),this.set=r},c.prototype.parseNegate=function(){var t=this.pattern,e=!1,r=this.options,n=0;if(r.nonegate)return;for(var i=0,o=t.length;i<o&&"!"===t.charAt(i);i++)e=!e,n++;n&&(this.pattern=t.substr(n));this.negate=e},u.braceExpand=function(t,e){return h(t,e)},c.prototype.braceExpand=h;var f=function(t){if("string"!=typeof t)throw new TypeError("invalid pattern");if(t.length>65536)throw new TypeError("pattern is too long")};c.prototype.parse=function(t,r){f(t);var a=this.options;if("**"===t){if(!a.noglobstar)return e;t="*"}if(""===t)return"";var l,u="",c=!!a.nocase,h=!1,p=[],y=[],g=!1,b=-1,m=-1,_="."===t.charAt(0)?"":a.dot?"(?!(?:^|\\/)\\.{1,2}(?:$|\\/))":"(?!\\.)",v=this;function w(){if(l){switch(l){case"*":u+=o,c=!0;break;case"?":u+=i,c=!0;break;default:u+="\\"+l}v.debug("clearStateChar %j %j",l,u),l=!1}}for(var S,E=0,R=t.length;E<R&&(S=t.charAt(E));E++)if(this.debug("%s\t%s %s %j",t,E,u,S),h&&s[S])u+="\\"+S,h=!1;else switch(S){case"/":return!1;case"\\":w(),h=!0;continue;case"?":case"*":case"+":case"@":case"!":if(this.debug("%s\t%s %s %j <-- stateChar",t,E,u,S),g){this.debug(" in class"),"!"===S&&E===m+1&&(S="^"),u+=S;continue}v.debug("call clearStateChar %j",l),w(),l=S,a.noext&&w();continue;case"(":if(g){u+="(";continue}if(!l){u+="\\(";continue}p.push({type:l,start:E-1,reStart:u.length,open:n[l].open,close:n[l].close}),u+="!"===l?"(?:(?!(?:":"(?:",this.debug("plType %j %j",l,u),l=!1;continue;case")":if(g||!p.length){u+="\\)";continue}w(),c=!0;var k=p.pop();u+=k.close,"!"===k.type&&y.push(k),k.reEnd=u.length;continue;case"|":if(g||!p.length||h){u+="\\|",h=!1;continue}w(),u+="|";continue;case"[":if(w(),g){u+="\\"+S;continue}g=!0,m=E,b=u.length,u+=S;continue;case"]":if(E===m+1||!g){u+="\\"+S,h=!1;continue}var T=t.substring(m+1,E);try{RegExp("["+T+"]")}catch(t){var x=this.parse(T,d);u=u.substr(0,b)+"\\["+x[0]+"\\]",c=c||x[1],g=!1;continue}c=!0,g=!1,u+=S;continue;default:w(),h?h=!1:!s[S]||"^"===S&&g||(u+="\\"),u+=S}g&&(T=t.substr(m+1),x=this.parse(T,d),u=u.substr(0,b)+"\\["+x[0],c=c||x[1]);for(k=p.pop();k;k=p.pop()){var A=u.slice(k.reStart+k.open.length);this.debug("setting tail",u,k),A=A.replace(/((?:\\{2}){0,64})(\\?)\|/g,function(t,e,r){return r||(r="\\"),e+e+r+"|"}),this.debug("tail=%j\n %s",A,A,k,u);var O="*"===k.type?o:"?"===k.type?i:"\\"+k.type;c=!0,u=u.slice(0,k.reStart)+O+"\\("+A}w(),h&&(u+="\\\\");var L=!1;switch(u.charAt(0)){case"[":case".":case"(":L=!0}for(var j=y.length-1;j>-1;j--){var M=y[j],I=u.slice(0,M.reStart),P=u.slice(M.reStart,M.reEnd-8),D=u.slice(M.reEnd-8,M.reEnd),C=u.slice(M.reEnd);D+=C;var N=I.split("(").length-1,F=C;for(E=0;E<N;E++)F=F.replace(/\)[+*?]?/,"");var B="";""===(C=F)&&r!==d&&(B="$"),u=I+P+C+B+D}""!==u&&c&&(u="(?=.)"+u);L&&(u=_+u);if(r===d)return[u,c];if(!c)return function(t){return t.replace(/\\(.)/g,"$1")}(t);var W=a.nocase?"i":"";try{var U=new RegExp("^"+u+"$",W)}catch(t){return new RegExp("$.")}return U._glob=t,U._src=u,U};var d={};return u.makeRe=function(t,e){return new c(t,e||{}).makeRe()},c.prototype.makeRe=function(){if(this.regexp||!1===this.regexp)return this.regexp;var t=this.set;if(!t.length)return this.regexp=!1,this.regexp;var r=this.options,n=r.noglobstar?o:r.dot?"(?:(?!(?:\\/|^)(?:\\.{1,2})($|\\/)).)*?":"(?:(?!(?:\\/|^)\\.).)*?",i=r.nocase?"i":"",s=t.map(function(t){return t.map(function(t){return t===e?n:"string"==typeof t?function(t){return t.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&")}(t):t._src}).join("\\/")}).join("|");s="^(?:"+s+")$",this.negate&&(s="^(?!"+s+").*$");try{this.regexp=new RegExp(s,i)}catch(t){this.regexp=!1}return this.regexp},u.match=function(t,e,r){var n=new c(e,r=r||{});return t=t.filter(function(t){return n.match(t)}),n.options.nonull&&!t.length&&t.push(e),t},c.prototype.match=function(e,r){if(void 0===r&&(r=this.partial),this.debug("match",e,this.pattern),this.comment)return!1;if(this.empty)return""===e;if("/"===e&&r)return!0;var n=this.options;"/"!==t.sep&&(e=e.split(t.sep).join("/")),e=e.split(a),this.debug(this.pattern,"split",e);var i,o,s=this.set;for(this.debug(this.pattern,"set",s),o=e.length-1;o>=0&&!(i=e[o]);o--);for(o=0;o<s.length;o++){var l=s[o],u=e;if(n.matchBase&&1===l.length&&(u=[i]),this.matchOne(u,l,r))return!!n.flipNegate||!this.negate}return!n.flipNegate&&this.negate},c.prototype.matchOne=function(t,r,n){var i=this.options;this.debug("matchOne",{this:this,file:t,pattern:r}),this.debug("matchOne",t.length,r.length);for(var o=0,s=0,a=t.length,l=r.length;o<a&&s<l;o++,s++){this.debug("matchOne loop");var u,c=r[s],h=t[o];if(this.debug(r,c,h),!1===c)return!1;if(c===e){this.debug("GLOBSTAR",[r,c,h]);var f=o,d=s+1;if(d===l){for(this.debug("** at the end");o<a;o++)if("."===t[o]||".."===t[o]||!i.dot&&"."===t[o].charAt(0))return!1;return!0}for(;f<a;){var p=t[f];if(this.debug("\nglobstar while",t,f,r,d,p),this.matchOne(t.slice(f),r.slice(d),n))return this.debug("globstar found match!",f,a,p),!0;if("."===p||".."===p||!i.dot&&"."===p.charAt(0)){this.debug("dot detected!",t,f,r,d);break}this.debug("globstar swallow a segment, and continue"),f++}return!(!n||(this.debug("\n>>> no match, partial?",t,f,r,d),f!==a))}if("string"==typeof c?(u=h===c,this.debug("string match",c,h,u)):(u=h.match(c),this.debug("pattern match",c,h,u)),!u)return!1}if(o===a&&s===l)return!0;if(o===a)return n;if(s===l)return o===a-1&&""===t[o];throw new Error("wtf?")},EH}var MH,IH={exports:{}};function PH(){if(MH)return IH.exports;function t(t){return"/"===t.charAt(0)}function e(t){var e=/^([a-zA-Z]:|[\\\/]{2}[^\\\/]+[\\\/]+[^\\\/]+)?([\\\/])?([\s\S]*?)$/.exec(t),r=e[1]||"",n=Boolean(r&&":"!==r.charAt(1));return Boolean(e[2]||n)}return MH=1,IH.exports="win32"===process.platform?e:t,IH.exports.posix=t,IH.exports.win32=e,IH.exports}var DH,CH,NH,FH,BH,WH={};function UH(){if(DH)return WH;function r(t,e){return Object.prototype.hasOwnProperty.call(t,e)}DH=1,WH.setopts=function(t,e,o){o||(o={});if(o.matchBase&&-1===e.indexOf("/")){if(o.noglobstar)throw new Error("base matching requires globstar");e="**/"+e}t.silent=!!o.silent,t.pattern=e,t.strict=!1!==o.strict,t.realpath=!!o.realpath,t.realpathCache=o.realpathCache||Object.create(null),t.follow=!!o.follow,t.dot=!!o.dot,t.mark=!!o.mark,t.nodir=!!o.nodir,t.nodir&&(t.mark=!0);t.sync=!!o.sync,t.nounique=!!o.nounique,t.nonull=!!o.nonull,t.nosort=!!o.nosort,t.nocase=!!o.nocase,t.stat=!!o.stat,t.noprocess=!!o.noprocess,t.absolute=!!o.absolute,t.fs=o.fs||n,t.maxLength=o.maxLength||1/0,t.cache=o.cache||Object.create(null),t.statCache=o.statCache||Object.create(null),t.symlinks=o.symlinks||Object.create(null),function(t,e){t.ignore=e.ignore||[],Array.isArray(t.ignore)||(t.ignore=[t.ignore]);t.ignore.length&&(t.ignore=t.ignore.map(u))}(t,o),t.changedCwd=!1;var l=process.cwd();r(o,"cwd")?(t.cwd=i.resolve(o.cwd),t.changedCwd=t.cwd!==l):t.cwd=l;t.root=o.root||i.resolve(t.cwd,"/"),t.root=i.resolve(t.root),"win32"===process.platform&&(t.root=t.root.replace(/\\/g,"/"));t.cwdAbs=s(t.cwd)?t.cwd:c(t,t.cwd),"win32"===process.platform&&(t.cwdAbs=t.cwdAbs.replace(/\\/g,"/"));t.nomount=!!o.nomount,o.nonegate=!0,o.nocomment=!0,o.allowWindowsEscape=!1,t.minimatch=new a(e,o),t.options=t.minimatch.options},WH.ownProp=r,WH.makeAbs=c,WH.finish=function(t){for(var e=t.nounique,r=e?[]:Object.create(null),n=0,i=t.matches.length;n<i;n++){var o=t.matches[n];if(o&&0!==Object.keys(o).length){var s=Object.keys(o);e?r.push.apply(r,s):s.forEach(function(t){r[t]=!0})}else if(t.nonull){var a=t.minimatch.globSet[n];e?r.push(a):r[a]=!0}}e||(r=Object.keys(r));t.nosort||(r=r.sort(l));if(t.mark){for(n=0;n<r.length;n++)r[n]=t._mark(r[n]);t.nodir&&(r=r.filter(function(e){var r=!/\/$/.test(e),n=t.cache[e]||t.cache[c(t,e)];return r&&n&&(r="DIR"!==n&&!Array.isArray(n)),r}))}t.ignore.length&&(r=r.filter(function(e){return!h(t,e)}));t.found=r},WH.mark=function(t,e){var r=c(t,e),n=t.cache[r],i=e;if(n){var o="DIR"===n||Array.isArray(n),s="/"===e.slice(-1);if(o&&!s?i+="/":!o&&s&&(i=i.slice(0,-1)),i!==e){var a=c(t,i);t.statCache[a]=t.statCache[r],t.cache[a]=t.cache[r]}}return i},WH.isIgnored=h,WH.childrenIgnored=function(t,e){return!!t.ignore.length&&t.ignore.some(function(t){return!(!t.gmatcher||!t.gmatcher.match(e))})};var n=t,i=e,o=jH(),s=PH(),a=o.Minimatch;function l(t,e){return t.localeCompare(e,"en")}function u(t){var e=null;if("/**"===t.slice(-3)){var r=t.replace(/(\/\*\*)+$/,"");e=new a(r,{dot:!0})}return{matcher:new a(t,{dot:!0}),gmatcher:e}}function c(t,e){var r=e;return r="/"===e.charAt(0)?i.join(t.root,e):s(e)||""===e?e:t.changedCwd?i.resolve(t.cwd,e):i.resolve(e),"win32"===process.platform&&(r=r.replace(/\\/g,"/")),r}function h(t,e){return!!t.ignore.length&&t.ignore.some(function(t){return t.matcher.match(e)||!(!t.gmatcher||!t.gmatcher.match(e))})}return WH}function zH(){if(BH)return FH;return BH=1,FH=function t(e,r){if(e&&r)return t(e)(r);if("function"!=typeof e)throw new TypeError("need wrapper function");return Object.keys(e).forEach(function(t){n[t]=e[t]}),n;function n(){for(var t=new Array(arguments.length),r=0;r<t.length;r++)t[r]=arguments[r];var n=e.apply(this,t),i=t[t.length-1];return"function"==typeof n&&n!==i&&Object.keys(i).forEach(function(t){n[t]=i[t]}),n}},FH}var $H,HH,GH,qH,VH,ZH={exports:{}};function YH(){if($H)return ZH.exports;$H=1;var t=zH();function e(t){var e=function(){return e.called?e.value:(e.called=!0,e.value=t.apply(this,arguments))};return e.called=!1,e}function r(t){var e=function(){if(e.called)throw new Error(e.onceError);return e.called=!0,e.value=t.apply(this,arguments)},r=t.name||"Function wrapped with `once`";return e.onceError=r+" shouldn't be called more than once",e.called=!1,e}return ZH.exports=t(e),ZH.exports.strict=t(r),e.proto=e(function(){Object.defineProperty(Function.prototype,"once",{value:function(){return e(this)},configurable:!0}),Object.defineProperty(Function.prototype,"onceStrict",{value:function(){return r(this)},configurable:!0})}),ZH.exports}function KH(){if(GH)return HH;GH=1;var t=zH(),e=Object.create(null),r=YH();return HH=t(function(t,n){return e[t]?(e[t].push(n),null):(e[t]=[n],function(t){return r(function r(){var n=e[t],i=n.length,o=function(t){for(var e=t.length,r=[],n=0;n<e;n++)r[n]=t[n];return r}(arguments);try{for(var s=0;s<i;s++)n[s].apply(null,o)}finally{n.length>i?(n.splice(0,i),process.nextTick(function(){r.apply(null,o)})):delete e[t]}})}(t))}),HH}function QH(){if(VH)return qH;VH=1,qH=b;var t=AH(),r=jH();r.Minimatch;var n=Ca,i=yn.EventEmitter,o=e,s=a,l=PH(),u=function(){if(NH)return CH;NH=1,CH=f,f.GlobSync=d;var t=AH(),r=jH();r.Minimatch,QH().Glob;var n=e,i=a,o=PH(),s=UH(),l=s.setopts,u=s.ownProp,c=s.childrenIgnored,h=s.isIgnored;function f(t,e){if("function"==typeof e||3===arguments.length)throw new TypeError("callback provided to sync glob\nSee: https://github.com/isaacs/node-glob/issues/167");return new d(t,e).found}function d(t,e){if(!t)throw new Error("must provide pattern");if("function"==typeof e||3===arguments.length)throw new TypeError("callback provided to sync glob\nSee: https://github.com/isaacs/node-glob/issues/167");if(!(this instanceof d))return new d(t,e);if(l(this,t,e),this.noprocess)return this;var r=this.minimatch.set.length;this.matches=new Array(r);for(var n=0;n<r;n++)this._process(this.minimatch.set[n],n,!1);this._finish()}return d.prototype._finish=function(){if(i.ok(this instanceof d),this.realpath){var e=this;this.matches.forEach(function(r,n){var i=e.matches[n]=Object.create(null);for(var o in r)try{o=e._makeAbs(o),i[t.realpathSync(o,e.realpathCache)]=!0}catch(t){if("stat"!==t.syscall)throw t;i[e._makeAbs(o)]=!0}})}s.finish(this)},d.prototype._process=function(t,e,n){i.ok(this instanceof d);for(var s,a=0;"string"==typeof t[a];)a++;switch(a){case t.length:return void this._processSimple(t.join("/"),e);case 0:s=null;break;default:s=t.slice(0,a).join("/")}var l,u=t.slice(a);null===s?l=".":o(s)||o(t.map(function(t){return"string"==typeof t?t:"[*]"}).join("/"))?(s&&o(s)||(s="/"+s),l=s):l=s;var h=this._makeAbs(l);c(this,l)||(u[0]===r.GLOBSTAR?this._processGlobStar(s,l,h,u,e,n):this._processReaddir(s,l,h,u,e,n))},d.prototype._processReaddir=function(t,e,r,i,o,s){var a=this._readdir(r,s);if(a){for(var l=i[0],u=!!this.minimatch.negate,c=l._glob,h=this.dot||"."===c.charAt(0),f=[],d=0;d<a.length;d++)("."!==(g=a[d]).charAt(0)||h)&&(u&&!t?!g.match(l):g.match(l))&&f.push(g);var p=f.length;if(0!==p)if(1!==i.length||this.mark||this.stat)for(i.shift(),d=0;d<p;d++){var y;g=f[d],y=t?[t,g]:[g],this._process(y.concat(i),o,s)}else{this.matches[o]||(this.matches[o]=Object.create(null));for(d=0;d<p;d++){var g=f[d];t&&(g="/"!==t.slice(-1)?t+"/"+g:t+g),"/"!==g.charAt(0)||this.nomount||(g=n.join(this.root,g)),this._emitMatch(o,g)}}}},d.prototype._emitMatch=function(t,e){if(!h(this,e)){var r=this._makeAbs(e);if(this.mark&&(e=this._mark(e)),this.absolute&&(e=r),!this.matches[t][e]){if(this.nodir){var n=this.cache[r];if("DIR"===n||Array.isArray(n))return}this.matches[t][e]=!0,this.stat&&this._stat(e)}}},d.prototype._readdirInGlobStar=function(t){if(this.follow)return this._readdir(t,!1);var e,r;try{r=this.fs.lstatSync(t)}catch(t){if("ENOENT"===t.code)return null}var n=r&&r.isSymbolicLink();return this.symlinks[t]=n,n||!r||r.isDirectory()?e=this._readdir(t,!1):this.cache[t]="FILE",e},d.prototype._readdir=function(t,e){if(e&&!u(this.symlinks,t))return this._readdirInGlobStar(t);if(u(this.cache,t)){var r=this.cache[t];if(!r||"FILE"===r)return null;if(Array.isArray(r))return r}try{return this._readdirEntries(t,this.fs.readdirSync(t))}catch(e){return this._readdirError(t,e),null}},d.prototype._readdirEntries=function(t,e){if(!this.mark&&!this.stat)for(var r=0;r<e.length;r++){var n=e[r];n="/"===t?t+n:t+"/"+n,this.cache[n]=!0}return this.cache[t]=e,e},d.prototype._readdirError=function(t,e){switch(e.code){case"ENOTSUP":case"ENOTDIR":var r=this._makeAbs(t);if(this.cache[r]="FILE",r===this.cwdAbs){var n=new Error(e.code+" invalid cwd "+this.cwd);throw n.path=this.cwd,n.code=e.code,n}break;case"ENOENT":case"ELOOP":case"ENAMETOOLONG":case"UNKNOWN":this.cache[this._makeAbs(t)]=!1;break;default:if(this.cache[this._makeAbs(t)]=!1,this.strict)throw e;this.silent||console.error("glob error",e)}},d.prototype._processGlobStar=function(t,e,r,n,i,o){var s=this._readdir(r,o);if(s){var a=n.slice(1),l=t?[t]:[],u=l.concat(a);this._process(u,i,!1);var c=s.length;if(!this.symlinks[r]||!o)for(var h=0;h<c;h++)if("."!==s[h].charAt(0)||this.dot){var f=l.concat(s[h],a);this._process(f,i,!0);var d=l.concat(s[h],n);this._process(d,i,!0)}}},d.prototype._processSimple=function(t,e){var r=this._stat(t);if(this.matches[e]||(this.matches[e]=Object.create(null)),r){if(t&&o(t)&&!this.nomount){var i=/[\/\\]$/.test(t);"/"===t.charAt(0)?t=n.join(this.root,t):(t=n.resolve(this.root,t),i&&(t+="/"))}"win32"===process.platform&&(t=t.replace(/\\/g,"/")),this._emitMatch(e,t)}},d.prototype._stat=function(t){var e=this._makeAbs(t),r="/"===t.slice(-1);if(t.length>this.maxLength)return!1;if(!this.stat&&u(this.cache,e)){var n=this.cache[e];if(Array.isArray(n)&&(n="DIR"),!r||"DIR"===n)return n;if(r&&"FILE"===n)return!1}var i=this.statCache[e];if(!i){var o;try{o=this.fs.lstatSync(e)}catch(t){if(t&&("ENOENT"===t.code||"ENOTDIR"===t.code))return this.statCache[e]=!1,!1}if(o&&o.isSymbolicLink())try{i=this.fs.statSync(e)}catch(t){i=o}else i=o}return this.statCache[e]=i,n=!0,i&&(n=i.isDirectory()?"DIR":"FILE"),this.cache[e]=this.cache[e]||n,(!r||"FILE"!==n)&&n},d.prototype._mark=function(t){return s.mark(this,t)},d.prototype._makeAbs=function(t){return s.makeAbs(this,t)},CH}(),c=UH(),h=c.setopts,f=c.ownProp,d=KH(),p=c.childrenIgnored,y=c.isIgnored,g=YH();function b(t,e,r){if("function"==typeof e&&(r=e,e={}),e||(e={}),e.sync){if(r)throw new TypeError("callback provided to sync glob");return u(t,e)}return new _(t,e,r)}b.sync=u;var m=b.GlobSync=u.GlobSync;function _(t,e,r){if("function"==typeof e&&(r=e,e=null),e&&e.sync){if(r)throw new TypeError("callback provided to sync glob");return new m(t,e)}if(!(this instanceof _))return new _(t,e,r);h(this,t,e),this._didRealPath=!1;var n=this.minimatch.set.length;this.matches=new Array(n),"function"==typeof r&&(r=g(r),this.on("error",r),this.on("end",function(t){r(null,t)}));var i=this;if(this._processing=0,this._emitQueue=[],this._processQueue=[],this.paused=!1,this.noprocess)return this;if(0===n)return a();for(var o=!0,s=0;s<n;s++)this._process(this.minimatch.set[s],s,!1,a);function a(){--i._processing,i._processing<=0&&(o?process.nextTick(function(){i._finish()}):i._finish())}o=!1}return b.glob=b,b.hasMagic=function(t,e){var r=function(t,e){if(null===e||"object"!=typeof e)return t;for(var r=Object.keys(e),n=r.length;n--;)t[r[n]]=e[r[n]];return t}({},e);r.noprocess=!0;var n=new _(t,r).minimatch.set;if(!t)return!1;if(n.length>1)return!0;for(var i=0;i<n[0].length;i++)if("string"!=typeof n[0][i])return!0;return!1},b.Glob=_,n(_,i),_.prototype._finish=function(){if(s(this instanceof _),!this.aborted){if(this.realpath&&!this._didRealpath)return this._realpath();c.finish(this),this.emit("end",this.found)}},_.prototype._realpath=function(){if(!this._didRealpath){this._didRealpath=!0;var t=this.matches.length;if(0===t)return this._finish();for(var e=this,r=0;r<this.matches.length;r++)this._realpathSet(r,n)}function n(){0===--t&&e._finish()}},_.prototype._realpathSet=function(e,r){var n=this.matches[e];if(!n)return r();var i=Object.keys(n),o=this,s=i.length;if(0===s)return r();var a=this.matches[e]=Object.create(null);i.forEach(function(n,i){n=o._makeAbs(n),t.realpath(n,o.realpathCache,function(t,i){t?"stat"===t.syscall?a[n]=!0:o.emit("error",t):a[i]=!0,0===--s&&(o.matches[e]=a,r())})})},_.prototype._mark=function(t){return c.mark(this,t)},_.prototype._makeAbs=function(t){return c.makeAbs(this,t)},_.prototype.abort=function(){this.aborted=!0,this.emit("abort")},_.prototype.pause=function(){this.paused||(this.paused=!0,this.emit("pause"))},_.prototype.resume=function(){if(this.paused){if(this.emit("resume"),this.paused=!1,this._emitQueue.length){var t=this._emitQueue.slice(0);this._emitQueue.length=0;for(var e=0;e<t.length;e++){var r=t[e];this._emitMatch(r[0],r[1])}}if(this._processQueue.length){var n=this._processQueue.slice(0);this._processQueue.length=0;for(e=0;e<n.length;e++){var i=n[e];this._processing--,this._process(i[0],i[1],i[2],i[3])}}}},_.prototype._process=function(t,e,n,i){if(s(this instanceof _),s("function"==typeof i),!this.aborted)if(this._processing++,this.paused)this._processQueue.push([t,e,n,i]);else{for(var o,a=0;"string"==typeof t[a];)a++;switch(a){case t.length:return void this._processSimple(t.join("/"),e,i);case 0:o=null;break;default:o=t.slice(0,a).join("/")}var u,c=t.slice(a);null===o?u=".":l(o)||l(t.map(function(t){return"string"==typeof t?t:"[*]"}).join("/"))?(o&&l(o)||(o="/"+o),u=o):u=o;var h=this._makeAbs(u);if(p(this,u))return i();c[0]===r.GLOBSTAR?this._processGlobStar(o,u,h,c,e,n,i):this._processReaddir(o,u,h,c,e,n,i)}},_.prototype._processReaddir=function(t,e,r,n,i,o,s){var a=this;this._readdir(r,o,function(l,u){return a._processReaddir2(t,e,r,n,i,o,u,s)})},_.prototype._processReaddir2=function(t,e,r,n,i,s,a,l){if(!a)return l();for(var u=n[0],c=!!this.minimatch.negate,h=u._glob,f=this.dot||"."===h.charAt(0),d=[],p=0;p<a.length;p++){if("."!==(g=a[p]).charAt(0)||f)(c&&!t?!g.match(u):g.match(u))&&d.push(g)}var y=d.length;if(0===y)return l();if(1===n.length&&!this.mark&&!this.stat){this.matches[i]||(this.matches[i]=Object.create(null));for(p=0;p<y;p++){var g=d[p];t&&(g="/"!==t?t+"/"+g:t+g),"/"!==g.charAt(0)||this.nomount||(g=o.join(this.root,g)),this._emitMatch(i,g)}return l()}n.shift();for(p=0;p<y;p++){g=d[p];t&&(g="/"!==t?t+"/"+g:t+g),this._process([g].concat(n),i,s,l)}l()},_.prototype._emitMatch=function(t,e){if(!this.aborted&&!y(this,e))if(this.paused)this._emitQueue.push([t,e]);else{var r=l(e)?e:this._makeAbs(e);if(this.mark&&(e=this._mark(e)),this.absolute&&(e=r),!this.matches[t][e]){if(this.nodir){var n=this.cache[r];if("DIR"===n||Array.isArray(n))return}this.matches[t][e]=!0;var i=this.statCache[r];i&&this.emit("stat",e,i),this.emit("match",e)}}},_.prototype._readdirInGlobStar=function(t,e){if(!this.aborted){if(this.follow)return this._readdir(t,!1,e);var r=this,n=d("lstat\0"+t,function(n,i){if(n&&"ENOENT"===n.code)return e();var o=i&&i.isSymbolicLink();r.symlinks[t]=o,o||!i||i.isDirectory()?r._readdir(t,!1,e):(r.cache[t]="FILE",e())});n&&r.fs.lstat(t,n)}},_.prototype._readdir=function(t,e,r){if(!this.aborted&&(r=d("readdir\0"+t+"\0"+e,r))){if(e&&!f(this.symlinks,t))return this._readdirInGlobStar(t,r);if(f(this.cache,t)){var n=this.cache[t];if(!n||"FILE"===n)return r();if(Array.isArray(n))return r(null,n)}this.fs.readdir(t,function(t,e,r){return function(n,i){n?t._readdirError(e,n,r):t._readdirEntries(e,i,r)}}(this,t,r))}},_.prototype._readdirEntries=function(t,e,r){if(!this.aborted){if(!this.mark&&!this.stat)for(var n=0;n<e.length;n++){var i=e[n];i="/"===t?t+i:t+"/"+i,this.cache[i]=!0}return this.cache[t]=e,r(null,e)}},_.prototype._readdirError=function(t,e,r){if(!this.aborted){switch(e.code){case"ENOTSUP":case"ENOTDIR":var n=this._makeAbs(t);if(this.cache[n]="FILE",n===this.cwdAbs){var i=new Error(e.code+" invalid cwd "+this.cwd);i.path=this.cwd,i.code=e.code,this.emit("error",i),this.abort()}break;case"ENOENT":case"ELOOP":case"ENAMETOOLONG":case"UNKNOWN":this.cache[this._makeAbs(t)]=!1;break;default:this.cache[this._makeAbs(t)]=!1,this.strict&&(this.emit("error",e),this.abort()),this.silent||console.error("glob error",e)}return r()}},_.prototype._processGlobStar=function(t,e,r,n,i,o,s){var a=this;this._readdir(r,o,function(l,u){a._processGlobStar2(t,e,r,n,i,o,u,s)})},_.prototype._processGlobStar2=function(t,e,r,n,i,o,s,a){if(!s)return a();var l=n.slice(1),u=t?[t]:[],c=u.concat(l);this._process(c,i,!1,a);var h=this.symlinks[r],f=s.length;if(h&&o)return a();for(var d=0;d<f;d++){if("."!==s[d].charAt(0)||this.dot){var p=u.concat(s[d],l);this._process(p,i,!0,a);var y=u.concat(s[d],n);this._process(y,i,!0,a)}}a()},_.prototype._processSimple=function(t,e,r){var n=this;this._stat(t,function(i,o){n._processSimple2(t,e,i,o,r)})},_.prototype._processSimple2=function(t,e,r,n,i){if(this.matches[e]||(this.matches[e]=Object.create(null)),!n)return i();if(t&&l(t)&&!this.nomount){var s=/[\/\\]$/.test(t);"/"===t.charAt(0)?t=o.join(this.root,t):(t=o.resolve(this.root,t),s&&(t+="/"))}"win32"===process.platform&&(t=t.replace(/\\/g,"/")),this._emitMatch(e,t),i()},_.prototype._stat=function(t,e){var r=this._makeAbs(t),n="/"===t.slice(-1);if(t.length>this.maxLength)return e();if(!this.stat&&f(this.cache,r)){var i=this.cache[r];if(Array.isArray(i)&&(i="DIR"),!n||"DIR"===i)return e(null,i);if(n&&"FILE"===i)return e()}var o=this.statCache[r];if(void 0!==o){if(!1===o)return e(null,o);var s=o.isDirectory()?"DIR":"FILE";return n&&"FILE"===s?e():e(null,s,o)}var a=this,l=d("stat\0"+r,function(n,i){if(i&&i.isSymbolicLink())return a.fs.stat(r,function(n,o){n?a._stat2(t,r,null,i,e):a._stat2(t,r,n,o,e)});a._stat2(t,r,n,i,e)});l&&a.fs.lstat(r,l)},_.prototype._stat2=function(t,e,r,n,i){if(r&&("ENOENT"===r.code||"ENOTDIR"===r.code))return this.statCache[e]=!1,i();var o="/"===t.slice(-1);if(this.statCache[e]=n,"/"===e.slice(-1)&&n&&!n.isDirectory())return i(null,!1,n);var s=!0;return n&&(s=n.isDirectory()?"DIR":"FILE"),this.cache[e]=this.cache[e]||s,o&&"FILE"===s?i():i(null,s,n)},qH}var JH=Vs,XH=e,tG=vz,eG=d$,rG=lH,nG=kH,iG=QH(),oG=rz.exports={},sG=/[\/\\]/g;oG.exists=function(){var t=XH.join.apply(XH,arguments);return JH.existsSync(t)},oG.expand=function(...t){var e=nG(t[0])?t.shift():{},r=Array.isArray(t[0])?t[0]:t;if(0===r.length)return[];var n=function(t,e){var r=[];return tG(t).forEach(function(t){var n=0===t.indexOf("!");n&&(t=t.slice(1));var i=e(t);r=n?eG(r,i):rG(r,i)}),r}(r,function(t){return iG.sync(t,e)});return e.filter&&(n=n.filter(function(t){t=XH.join(e.cwd||"",t);try{return"function"==typeof e.filter?e.filter(t):JH.statSync(t)[e.filter]()}catch(t){return!1}})),n},oG.expandMapping=function(t,e,r){r=Object.assign({rename:function(t,e){return XH.join(t||"",e)}},r);var n=[],i={};return oG.expand(r,t).forEach(function(t){var o=t;r.flatten&&(o=XH.basename(o)),r.ext&&(o=o.replace(/(\.[^\/]*)?$/,r.ext));var s=r.rename(e,o,r);r.cwd&&(t=XH.join(r.cwd,t)),s=s.replace(sG,"/"),t=t.replace(sG,"/"),i[s]?i[s].src.push(t):(n.push({src:[t],dest:s}),i[s]=n[n.length-1])}),n},oG.normalizeFilesArray=function(t){var e=[];return t.forEach(function(t){("src"in t||"dest"in t)&&e.push(t)}),0===e.length?[]:(e=_(e).chain().forEach(function(t){"src"in t&&t.src&&(Array.isArray(t.src)?t.src=tG(t.src):t.src=[t.src])}).map(function(t){var e=Object.assign({},t);if(delete e.src,delete e.dest,t.expand)return oG.expandMapping(t.src,t.dest,e).map(function(e){var r=Object.assign({},t);return r.orig=Object.assign({},t),r.src=e.src,r.dest=e.dest,["expand","cwd","flatten","rename","ext"].forEach(function(t){delete r[t]}),r});var r=Object.assign({},t);return r.orig=Object.assign({},t),"src"in r&&Object.defineProperty(r,"src",{enumerable:!0,get:function r(){var n;return"result"in r||(n=t.src,n=Array.isArray(n)?tG(n):[n],r.result=oG.expand(e,n)),r.result}}),"dest"in r&&(r.dest=t.dest),r}).flatten().value(),e)};var aG=rz.exports,lG=Vs,uG=e,cG=ll,hG=fl,fG=rU,dG=i.Stream,pG=ez.PassThrough,yG=AW.exports={};yG.file=aG,yG.collectStream=function(t,e){var r=[],n=0;t.on("error",e),t.on("data",function(t){r.push(t),n+=t.length}),t.on("end",function(){var t=Buffer.alloc(n),i=0;r.forEach(function(e){e.copy(t,i),i+=e.length}),e(null,t)})},yG.dateify=function(t){return(t=t||new Date)instanceof Date||(t="string"==typeof t?new Date(t):new Date),t},yG.defaults=function(t,e,r){var n=arguments;return n[0]=n[0]||{},fG(...n)},yG.isStream=function(t){return t instanceof dG},yG.lazyReadStream=function(t){return new cG.Readable(function(){return lG.createReadStream(t)})},yG.normalizeInputSource=function(t){return null===t?Buffer.alloc(0):"string"==typeof t?Buffer.from(t):yG.isStream(t)?t.pipe(new pG):t},yG.sanitizePath=function(t){return hG(t,!1).replace(/^\w+:/,"").replace(/^(\.\.\/|\/)+/,"")},yG.trailingSlashIt=function(t){return"/"!==t.slice(-1)?t+"/":t},yG.unixifyPath=function(t){return hG(t,!1).replace(/^\w+:/,"")},yG.walkdir=function(t,e,r){var n=[];"function"==typeof e&&(r=e,e=t),lG.readdir(t,function(i,o){var s,a,l=0;if(i)return r(i);!function i(){if(!(s=o[l++]))return r(null,n);a=uG.join(t,s),lG.stat(a,function(t,r){n.push({path:a,relative:uG.relative(e,a).replace(/\\/g,"/"),stats:r}),r&&r.isDirectory()?yG.walkdir(a,e,function(t,e){e.forEach(function(t){n.push(t)}),i()}):i()})}()})};var gG=AW.exports,bG=s.inherits,mG=xW.ZipArchiveOutputStream,_G=xW.ZipArchiveEntry,vG=gG,wG=vN.exports=function(t){if(!(this instanceof wG))return new wG(t);(t=this.options=t||{}).zlib=t.zlib||{},mG.call(this,t),"number"==typeof t.level&&t.level>=0&&(t.zlib.level=t.level,delete t.level),t.forceZip64||"number"!=typeof t.zlib.level||0!==t.zlib.level||(t.store=!0),t.namePrependSlash=t.namePrependSlash||!1,t.comment&&t.comment.length>0&&this.setComment(t.comment)};
69
- /**
70
- * ZipStream
71
- *
72
- * @ignore
73
- * @license [MIT]{@link https://github.com/archiverjs/node-zip-stream/blob/master/LICENSE}
74
- * @copyright (c) 2014 Chris Talkington, contributors.
75
- */bG(wG,mG),wG.prototype._normalizeFileData=function(t){var e="directory"===(t=vG.defaults(t,{type:"file",name:null,namePrependSlash:this.options.namePrependSlash,linkname:null,date:null,mode:null,store:this.options.store,comment:""})).type,r="symlink"===t.type;return t.name&&(t.name=vG.sanitizePath(t.name),r||"/"!==t.name.slice(-1)?e&&(t.name+="/"):(e=!0,t.type="directory")),(e||r)&&(t.store=!0),t.date=vG.dateify(t.date),t},wG.prototype.entry=function(t,e,r){if("function"!=typeof r&&(r=this._emitErrorCallback.bind(this)),"file"===(e=this._normalizeFileData(e)).type||"directory"===e.type||"symlink"===e.type)if("string"==typeof e.name&&0!==e.name.length){if("symlink"!==e.type||"string"==typeof e.linkname){var n=new _G(e.name);return n.setTime(e.date,this.options.forceLocalTime),e.namePrependSlash&&n.setName(e.name,!0),e.store&&n.setMethod(0),e.comment.length>0&&n.setComment(e.comment),"symlink"===e.type&&"number"!=typeof e.mode&&(e.mode=40960),"number"==typeof e.mode&&("symlink"===e.type&&(e.mode|=40960),n.setUnixMode(e.mode)),"symlink"===e.type&&"string"==typeof e.linkname&&(t=Buffer.from(e.linkname)),mG.prototype.entry.call(this,n,t,r)}r(new Error("entry linkname must be a non-empty string value when type equals symlink"))}else r(new Error("entry name must be a non-empty string value"));else r(new Error(e.type+" entries not currently supported"))},wG.prototype.finalize=function(){this.finish()};var SG=vN.exports;const EG=s.inherits,RG=_N,kG=SG,{DeflateCRC32Stream:TG,CRC32Stream:xG}=mW,AG=MN,OG=function(t={zlib:{}}){if(!(this instanceof OG))return new OG(t);this.key=t.password,Buffer.isBuffer(this.key)||(this.key=Buffer.from(t.password)),kG.call(this,t)};function LG(t,e){return new Promise((r,n)=>{t.write(e,t=>{t?n():r()})})}EG(OG,kG),OG.prototype._writeLocalFileHeader=function(t){t.getGeneralPurposeBit().useEncryption(!0),kG.prototype._writeLocalFileHeader.call(this,t)},OG.prototype._smartStream=function(t,e){let r=t.getMethod()===AG.METHOD_DEFLATED?new TG(this.options.zlib):new xG,n=null,i=[];return r.once("error",function(t){n=t}),r.on("data",t=>{i.push(t)}),r.once("end",()=>{let o=r.digest();t.setCrc(o.readUInt32BE(0)),t.setSize(r.size()),t.setCompressedSize(r.size(!0)+12),this._writeLocalFileHeader(t);let s=new RG({key:this.key,crc:o}),a=[];for(let t of i)a.push(()=>LG(s,t));jG(a).then(()=>s.end()),s.once("end",()=>{this._afterAppend(t),e(n,t)}),s.once("error",function(t){n=t}),s.pipe(this,{end:!1})}),r},OG.prototype._appendBuffer=function(t,e,r){t.setSize(e.length),t.setCompressedSize(e.length),t.getGeneralPurposeBit().useDataDescriptor(!1),this._smartStream(t,r).end(e)},OG.prototype._appendStream=function(t,e,r){t.setVersionNeededToExtract(AG.MIN_VERSION_DATA_DESCRIPTOR),t.getGeneralPurposeBit().useDataDescriptor(!1);var n=this._smartStream(t,r);e.once("error",function(t){n.emit("error",t),n.end()}),e.pipe(n)};const jG=t=>t.reduce((t,e)=>t.then(t=>e().then(Array.prototype.concat.bind(t))),Promise.resolve([]));var MG=OG,IG={exports:{}};
76
- /*! MIT License. Copyright 2015-2018 Richard Moore <me@ricmoo.com>. See LICENSE.txt. */
77
- !function(t){!function(){function e(t){return parseInt(t)===t}function r(t){if(!e(t.length))return!1;for(var r=0;r<t.length;r++)if(!e(t[r])||t[r]<0||t[r]>255)return!1;return!0}function n(t,n){if(t.buffer&&"Uint8Array"===t.name)return n&&(t=t.slice?t.slice():Array.prototype.slice.call(t)),t;if(Array.isArray(t)){if(!r(t))throw new Error("Array contains invalid value: "+t);return new Uint8Array(t)}if(e(t.length)&&r(t))return new Uint8Array(t);throw new Error("unsupported array-like object")}function i(t){return new Uint8Array(t)}function o(t,e,r,n,i){null==n&&null==i||(t=t.slice?t.slice(n,i):Array.prototype.slice.call(t,n,i)),e.set(t,r)}var s,a={toBytes:function(t){var e=[],r=0;for(t=encodeURI(t);r<t.length;){var i=t.charCodeAt(r++);37===i?(e.push(parseInt(t.substr(r,2),16)),r+=2):e.push(i)}return n(e)},fromBytes:function(t){for(var e=[],r=0;r<t.length;){var n=t[r];n<128?(e.push(String.fromCharCode(n)),r++):n>191&&n<224?(e.push(String.fromCharCode((31&n)<<6|63&t[r+1])),r+=2):(e.push(String.fromCharCode((15&n)<<12|(63&t[r+1])<<6|63&t[r+2])),r+=3)}return e.join("")}},l=(s="0123456789abcdef",{toBytes:function(t){for(var e=[],r=0;r<t.length;r+=2)e.push(parseInt(t.substr(r,2),16));return e},fromBytes:function(t){for(var e=[],r=0;r<t.length;r++){var n=t[r];e.push(s[(240&n)>>4]+s[15&n])}return e.join("")}}),u={16:10,24:12,32:14},c=[1,2,4,8,16,32,64,128,27,54,108,216,171,77,154,47,94,188,99,198,151,53,106,212,179,125,250,239,197,145],h=[99,124,119,123,242,107,111,197,48,1,103,43,254,215,171,118,202,130,201,125,250,89,71,240,173,212,162,175,156,164,114,192,183,253,147,38,54,63,247,204,52,165,229,241,113,216,49,21,4,199,35,195,24,150,5,154,7,18,128,226,235,39,178,117,9,131,44,26,27,110,90,160,82,59,214,179,41,227,47,132,83,209,0,237,32,252,177,91,106,203,190,57,74,76,88,207,208,239,170,251,67,77,51,133,69,249,2,127,80,60,159,168,81,163,64,143,146,157,56,245,188,182,218,33,16,255,243,210,205,12,19,236,95,151,68,23,196,167,126,61,100,93,25,115,96,129,79,220,34,42,144,136,70,238,184,20,222,94,11,219,224,50,58,10,73,6,36,92,194,211,172,98,145,149,228,121,231,200,55,109,141,213,78,169,108,86,244,234,101,122,174,8,186,120,37,46,28,166,180,198,232,221,116,31,75,189,139,138,112,62,181,102,72,3,246,14,97,53,87,185,134,193,29,158,225,248,152,17,105,217,142,148,155,30,135,233,206,85,40,223,140,161,137,13,191,230,66,104,65,153,45,15,176,84,187,22],f=[82,9,106,213,48,54,165,56,191,64,163,158,129,243,215,251,124,227,57,130,155,47,255,135,52,142,67,68,196,222,233,203,84,123,148,50,166,194,35,61,238,76,149,11,66,250,195,78,8,46,161,102,40,217,36,178,118,91,162,73,109,139,209,37,114,248,246,100,134,104,152,22,212,164,92,204,93,101,182,146,108,112,72,80,253,237,185,218,94,21,70,87,167,141,157,132,144,216,171,0,140,188,211,10,247,228,88,5,184,179,69,6,208,44,30,143,202,63,15,2,193,175,189,3,1,19,138,107,58,145,17,65,79,103,220,234,151,242,207,206,240,180,230,115,150,172,116,34,231,173,53,133,226,249,55,232,28,117,223,110,71,241,26,113,29,41,197,137,111,183,98,14,170,24,190,27,252,86,62,75,198,210,121,32,154,219,192,254,120,205,90,244,31,221,168,51,136,7,199,49,177,18,16,89,39,128,236,95,96,81,127,169,25,181,74,13,45,229,122,159,147,201,156,239,160,224,59,77,174,42,245,176,200,235,187,60,131,83,153,97,23,43,4,126,186,119,214,38,225,105,20,99,85,33,12,125],d=[3328402341,4168907908,4000806809,4135287693,4294111757,3597364157,3731845041,2445657428,1613770832,33620227,3462883241,1445669757,3892248089,3050821474,1303096294,3967186586,2412431941,528646813,2311702848,4202528135,4026202645,2992200171,2387036105,4226871307,1101901292,3017069671,1604494077,1169141738,597466303,1403299063,3832705686,2613100635,1974974402,3791519004,1033081774,1277568618,1815492186,2118074177,4126668546,2211236943,1748251740,1369810420,3521504564,4193382664,3799085459,2883115123,1647391059,706024767,134480908,2512897874,1176707941,2646852446,806885416,932615841,168101135,798661301,235341577,605164086,461406363,3756188221,3454790438,1311188841,2142417613,3933566367,302582043,495158174,1479289972,874125870,907746093,3698224818,3025820398,1537253627,2756858614,1983593293,3084310113,2108928974,1378429307,3722699582,1580150641,327451799,2790478837,3117535592,0,3253595436,1075847264,3825007647,2041688520,3059440621,3563743934,2378943302,1740553945,1916352843,2487896798,2555137236,2958579944,2244988746,3151024235,3320835882,1336584933,3992714006,2252555205,2588757463,1714631509,293963156,2319795663,3925473552,67240454,4269768577,2689618160,2017213508,631218106,1269344483,2723238387,1571005438,2151694528,93294474,1066570413,563977660,1882732616,4059428100,1673313503,2008463041,2950355573,1109467491,537923632,3858759450,4260623118,3218264685,2177748300,403442708,638784309,3287084079,3193921505,899127202,2286175436,773265209,2479146071,1437050866,4236148354,2050833735,3362022572,3126681063,840505643,3866325909,3227541664,427917720,2655997905,2749160575,1143087718,1412049534,999329963,193497219,2353415882,3354324521,1807268051,672404540,2816401017,3160301282,369822493,2916866934,3688947771,1681011286,1949973070,336202270,2454276571,201721354,1210328172,3093060836,2680341085,3184776046,1135389935,3294782118,965841320,831886756,3554993207,4068047243,3588745010,2345191491,1849112409,3664604599,26054028,2983581028,2622377682,1235855840,3630984372,2891339514,4092916743,3488279077,3395642799,4101667470,1202630377,268961816,1874508501,4034427016,1243948399,1546530418,941366308,1470539505,1941222599,2546386513,3421038627,2715671932,3899946140,1042226977,2521517021,1639824860,227249030,260737669,3765465232,2084453954,1907733956,3429263018,2420656344,100860677,4160157185,470683154,3261161891,1781871967,2924959737,1773779408,394692241,2579611992,974986535,664706745,3655459128,3958962195,731420851,571543859,3530123707,2849626480,126783113,865375399,765172662,1008606754,361203602,3387549984,2278477385,2857719295,1344809080,2782912378,59542671,1503764984,160008576,437062935,1707065306,3622233649,2218934982,3496503480,2185314755,697932208,1512910199,504303377,2075177163,2824099068,1841019862,739644986],p=[2781242211,2230877308,2582542199,2381740923,234877682,3184946027,2984144751,1418839493,1348481072,50462977,2848876391,2102799147,434634494,1656084439,3863849899,2599188086,1167051466,2636087938,1082771913,2281340285,368048890,3954334041,3381544775,201060592,3963727277,1739838676,4250903202,3930435503,3206782108,4149453988,2531553906,1536934080,3262494647,484572669,2923271059,1783375398,1517041206,1098792767,49674231,1334037708,1550332980,4098991525,886171109,150598129,2481090929,1940642008,1398944049,1059722517,201851908,1385547719,1699095331,1587397571,674240536,2704774806,252314885,3039795866,151914247,908333586,2602270848,1038082786,651029483,1766729511,3447698098,2682942837,454166793,2652734339,1951935532,775166490,758520603,3000790638,4004797018,4217086112,4137964114,1299594043,1639438038,3464344499,2068982057,1054729187,1901997871,2534638724,4121318227,1757008337,0,750906861,1614815264,535035132,3363418545,3988151131,3201591914,1183697867,3647454910,1265776953,3734260298,3566750796,3903871064,1250283471,1807470800,717615087,3847203498,384695291,3313910595,3617213773,1432761139,2484176261,3481945413,283769337,100925954,2180939647,4037038160,1148730428,3123027871,3813386408,4087501137,4267549603,3229630528,2315620239,2906624658,3156319645,1215313976,82966005,3747855548,3245848246,1974459098,1665278241,807407632,451280895,251524083,1841287890,1283575245,337120268,891687699,801369324,3787349855,2721421207,3431482436,959321879,1469301956,4065699751,2197585534,1199193405,2898814052,3887750493,724703513,2514908019,2696962144,2551808385,3516813135,2141445340,1715741218,2119445034,2872807568,2198571144,3398190662,700968686,3547052216,1009259540,2041044702,3803995742,487983883,1991105499,1004265696,1449407026,1316239930,504629770,3683797321,168560134,1816667172,3837287516,1570751170,1857934291,4014189740,2797888098,2822345105,2754712981,936633572,2347923833,852879335,1133234376,1500395319,3084545389,2348912013,1689376213,3533459022,3762923945,3034082412,4205598294,133428468,634383082,2949277029,2398386810,3913789102,403703816,3580869306,2297460856,1867130149,1918643758,607656988,4049053350,3346248884,1368901318,600565992,2090982877,2632479860,557719327,3717614411,3697393085,2249034635,2232388234,2430627952,1115438654,3295786421,2865522278,3633334344,84280067,33027830,303828494,2747425121,1600795957,4188952407,3496589753,2434238086,1486471617,658119965,3106381470,953803233,334231800,3005978776,857870609,3151128937,1890179545,2298973838,2805175444,3056442267,574365214,2450884487,550103529,1233637070,4289353045,2018519080,2057691103,2399374476,4166623649,2148108681,387583245,3664101311,836232934,3330556482,3100665960,3280093505,2955516313,2002398509,287182607,3413881008,4238890068,3597515707,975967766],y=[1671808611,2089089148,2006576759,2072901243,4061003762,1807603307,1873927791,3310653893,810573872,16974337,1739181671,729634347,4263110654,3613570519,2883997099,1989864566,3393556426,2191335298,3376449993,2106063485,4195741690,1508618841,1204391495,4027317232,2917941677,3563566036,2734514082,2951366063,2629772188,2767672228,1922491506,3227229120,3082974647,4246528509,2477669779,644500518,911895606,1061256767,4144166391,3427763148,878471220,2784252325,3845444069,4043897329,1905517169,3631459288,827548209,356461077,67897348,3344078279,593839651,3277757891,405286936,2527147926,84871685,2595565466,118033927,305538066,2157648768,3795705826,3945188843,661212711,2999812018,1973414517,152769033,2208177539,745822252,439235610,455947803,1857215598,1525593178,2700827552,1391895634,994932283,3596728278,3016654259,695947817,3812548067,795958831,2224493444,1408607827,3513301457,0,3979133421,543178784,4229948412,2982705585,1542305371,1790891114,3410398667,3201918910,961245753,1256100938,1289001036,1491644504,3477767631,3496721360,4012557807,2867154858,4212583931,1137018435,1305975373,861234739,2241073541,1171229253,4178635257,33948674,2139225727,1357946960,1011120188,2679776671,2833468328,1374921297,2751356323,1086357568,2408187279,2460827538,2646352285,944271416,4110742005,3168756668,3066132406,3665145818,560153121,271589392,4279952895,4077846003,3530407890,3444343245,202643468,322250259,3962553324,1608629855,2543990167,1154254916,389623319,3294073796,2817676711,2122513534,1028094525,1689045092,1575467613,422261273,1939203699,1621147744,2174228865,1339137615,3699352540,577127458,712922154,2427141008,2290289544,1187679302,3995715566,3100863416,339486740,3732514782,1591917662,186455563,3681988059,3762019296,844522546,978220090,169743370,1239126601,101321734,611076132,1558493276,3260915650,3547250131,2901361580,1655096418,2443721105,2510565781,3828863972,2039214713,3878868455,3359869896,928607799,1840765549,2374762893,3580146133,1322425422,2850048425,1823791212,1459268694,4094161908,3928346602,1706019429,2056189050,2934523822,135794696,3134549946,2022240376,628050469,779246638,472135708,2800834470,3032970164,3327236038,3894660072,3715932637,1956440180,522272287,1272813131,3185336765,2340818315,2323976074,1888542832,1044544574,3049550261,1722469478,1222152264,50660867,4127324150,236067854,1638122081,895445557,1475980887,3117443513,2257655686,3243809217,489110045,2662934430,3778599393,4162055160,2561878936,288563729,1773916777,3648039385,2391345038,2493985684,2612407707,505560094,2274497927,3911240169,3460925390,1442818645,678973480,3749357023,2358182796,2717407649,2306869641,219617805,3218761151,3862026214,1120306242,1756942440,1103331905,2578459033,762796589,252780047,2966125488,1425844308,3151392187,372911126],g=[1667474886,2088535288,2004326894,2071694838,4075949567,1802223062,1869591006,3318043793,808472672,16843522,1734846926,724270422,4278065639,3621216949,2880169549,1987484396,3402253711,2189597983,3385409673,2105378810,4210693615,1499065266,1195886990,4042263547,2913856577,3570689971,2728590687,2947541573,2627518243,2762274643,1920112356,3233831835,3082273397,4261223649,2475929149,640051788,909531756,1061110142,4160160501,3435941763,875846760,2779116625,3857003729,4059105529,1903268834,3638064043,825316194,353713962,67374088,3351728789,589522246,3284360861,404236336,2526454071,84217610,2593830191,117901582,303183396,2155911963,3806477791,3958056653,656894286,2998062463,1970642922,151591698,2206440989,741110872,437923380,454765878,1852748508,1515908788,2694904667,1381168804,993742198,3604373943,3014905469,690584402,3823320797,791638366,2223281939,1398011302,3520161977,0,3991743681,538992704,4244381667,2981218425,1532751286,1785380564,3419096717,3200178535,960056178,1246420628,1280103576,1482221744,3486468741,3503319995,4025428677,2863326543,4227536621,1128514950,1296947098,859002214,2240123921,1162203018,4193849577,33687044,2139062782,1347481760,1010582648,2678045221,2829640523,1364325282,2745433693,1077985408,2408548869,2459086143,2644360225,943212656,4126475505,3166494563,3065430391,3671750063,555836226,269496352,4294908645,4092792573,3537006015,3452783745,202118168,320025894,3974901699,1600119230,2543297077,1145359496,387397934,3301201811,2812801621,2122220284,1027426170,1684319432,1566435258,421079858,1936954854,1616945344,2172753945,1330631070,3705438115,572679748,707427924,2425400123,2290647819,1179044492,4008585671,3099120491,336870440,3739122087,1583276732,185277718,3688593069,3772791771,842159716,976899700,168435220,1229577106,101059084,606366792,1549591736,3267517855,3553849021,2897014595,1650632388,2442242105,2509612081,3840161747,2038008818,3890688725,3368567691,926374254,1835907034,2374863873,3587531953,1313788572,2846482505,1819063512,1448540844,4109633523,3941213647,1701162954,2054852340,2930698567,134748176,3132806511,2021165296,623210314,774795868,471606328,2795958615,3031746419,3334885783,3907527627,3722280097,1953799400,522133822,1263263126,3183336545,2341176845,2324333839,1886425312,1044267644,3048588401,1718004428,1212733584,50529542,4143317495,235803164,1633788866,892690282,1465383342,3115962473,2256965911,3250673817,488449850,2661202215,3789633753,4177007595,2560144171,286339874,1768537042,3654906025,2391705863,2492770099,2610673197,505291324,2273808917,3924369609,3469625735,1431699370,673740880,3755965093,2358021891,2711746649,2307489801,218961690,3217021541,3873845719,1111672452,1751693520,1094828930,2576986153,757954394,252645662,2964376443,1414855848,3149649517,370555436],b=[1374988112,2118214995,437757123,975658646,1001089995,530400753,2902087851,1273168787,540080725,2910219766,2295101073,4110568485,1340463100,3307916247,641025152,3043140495,3736164937,632953703,1172967064,1576976609,3274667266,2169303058,2370213795,1809054150,59727847,361929877,3211623147,2505202138,3569255213,1484005843,1239443753,2395588676,1975683434,4102977912,2572697195,666464733,3202437046,4035489047,3374361702,2110667444,1675577880,3843699074,2538681184,1649639237,2976151520,3144396420,4269907996,4178062228,1883793496,2403728665,2497604743,1383856311,2876494627,1917518562,3810496343,1716890410,3001755655,800440835,2261089178,3543599269,807962610,599762354,33778362,3977675356,2328828971,2809771154,4077384432,1315562145,1708848333,101039829,3509871135,3299278474,875451293,2733856160,92987698,2767645557,193195065,1080094634,1584504582,3178106961,1042385657,2531067453,3711829422,1306967366,2438237621,1908694277,67556463,1615861247,429456164,3602770327,2302690252,1742315127,2968011453,126454664,3877198648,2043211483,2709260871,2084704233,4169408201,0,159417987,841739592,504459436,1817866830,4245618683,260388950,1034867998,908933415,168810852,1750902305,2606453969,607530554,202008497,2472011535,3035535058,463180190,2160117071,1641816226,1517767529,470948374,3801332234,3231722213,1008918595,303765277,235474187,4069246893,766945465,337553864,1475418501,2943682380,4003061179,2743034109,4144047775,1551037884,1147550661,1543208500,2336434550,3408119516,3069049960,3102011747,3610369226,1113818384,328671808,2227573024,2236228733,3535486456,2935566865,3341394285,496906059,3702665459,226906860,2009195472,733156972,2842737049,294930682,1206477858,2835123396,2700099354,1451044056,573804783,2269728455,3644379585,2362090238,2564033334,2801107407,2776292904,3669462566,1068351396,742039012,1350078989,1784663195,1417561698,4136440770,2430122216,775550814,2193862645,2673705150,1775276924,1876241833,3475313331,3366754619,270040487,3902563182,3678124923,3441850377,1851332852,3969562369,2203032232,3868552805,2868897406,566021896,4011190502,3135740889,1248802510,3936291284,699432150,832877231,708780849,3332740144,899835584,1951317047,4236429990,3767586992,866637845,4043610186,1106041591,2144161806,395441711,1984812685,1139781709,3433712980,3835036895,2664543715,1282050075,3240894392,1181045119,2640243204,25965917,4203181171,4211818798,3009879386,2463879762,3910161971,1842759443,2597806476,933301370,1509430414,3943906441,3467192302,3076639029,3776767469,2051518780,2631065433,1441952575,404016761,1942435775,1408749034,1610459739,3745345300,2017778566,3400528769,3110650942,941896748,3265478751,371049330,3168937228,675039627,4279080257,967311729,135050206,3635733660,1683407248,2076935265,3576870512,1215061108,3501741890],m=[1347548327,1400783205,3273267108,2520393566,3409685355,4045380933,2880240216,2471224067,1428173050,4138563181,2441661558,636813900,4233094615,3620022987,2149987652,2411029155,1239331162,1730525723,2554718734,3781033664,46346101,310463728,2743944855,3328955385,3875770207,2501218972,3955191162,3667219033,768917123,3545789473,692707433,1150208456,1786102409,2029293177,1805211710,3710368113,3065962831,401639597,1724457132,3028143674,409198410,2196052529,1620529459,1164071807,3769721975,2226875310,486441376,2499348523,1483753576,428819965,2274680428,3075636216,598438867,3799141122,1474502543,711349675,129166120,53458370,2592523643,2782082824,4063242375,2988687269,3120694122,1559041666,730517276,2460449204,4042459122,2706270690,3446004468,3573941694,533804130,2328143614,2637442643,2695033685,839224033,1973745387,957055980,2856345839,106852767,1371368976,4181598602,1033297158,2933734917,1179510461,3046200461,91341917,1862534868,4284502037,605657339,2547432937,3431546947,2003294622,3182487618,2282195339,954669403,3682191598,1201765386,3917234703,3388507166,0,2198438022,1211247597,2887651696,1315723890,4227665663,1443857720,507358933,657861945,1678381017,560487590,3516619604,975451694,2970356327,261314535,3535072918,2652609425,1333838021,2724322336,1767536459,370938394,182621114,3854606378,1128014560,487725847,185469197,2918353863,3106780840,3356761769,2237133081,1286567175,3152976349,4255350624,2683765030,3160175349,3309594171,878443390,1988838185,3704300486,1756818940,1673061617,3403100636,272786309,1075025698,545572369,2105887268,4174560061,296679730,1841768865,1260232239,4091327024,3960309330,3497509347,1814803222,2578018489,4195456072,575138148,3299409036,446754879,3629546796,4011996048,3347532110,3252238545,4270639778,915985419,3483825537,681933534,651868046,2755636671,3828103837,223377554,2607439820,1649704518,3270937875,3901806776,1580087799,4118987695,3198115200,2087309459,2842678573,3016697106,1003007129,2802849917,1860738147,2077965243,164439672,4100872472,32283319,2827177882,1709610350,2125135846,136428751,3874428392,3652904859,3460984630,3572145929,3593056380,2939266226,824852259,818324884,3224740454,930369212,2801566410,2967507152,355706840,1257309336,4148292826,243256656,790073846,2373340630,1296297904,1422699085,3756299780,3818836405,457992840,3099667487,2135319889,77422314,1560382517,1945798516,788204353,1521706781,1385356242,870912086,325965383,2358957921,2050466060,2388260884,2313884476,4006521127,901210569,3990953189,1014646705,1503449823,1062597235,2031621326,3212035895,3931371469,1533017514,350174575,2256028891,2177544179,1052338372,741876788,1606591296,1914052035,213705253,2334669897,1107234197,1899603969,3725069491,2631447780,2422494913,1635502980,1893020342,1950903388,1120974935],_=[2807058932,1699970625,2764249623,1586903591,1808481195,1173430173,1487645946,59984867,4199882800,1844882806,1989249228,1277555970,3623636965,3419915562,1149249077,2744104290,1514790577,459744698,244860394,3235995134,1963115311,4027744588,2544078150,4190530515,1608975247,2627016082,2062270317,1507497298,2200818878,567498868,1764313568,3359936201,2305455554,2037970062,1047239e3,1910319033,1337376481,2904027272,2892417312,984907214,1243112415,830661914,861968209,2135253587,2011214180,2927934315,2686254721,731183368,1750626376,4246310725,1820824798,4172763771,3542330227,48394827,2404901663,2871682645,671593195,3254988725,2073724613,145085239,2280796200,2779915199,1790575107,2187128086,472615631,3029510009,4075877127,3802222185,4107101658,3201631749,1646252340,4270507174,1402811438,1436590835,3778151818,3950355702,3963161475,4020912224,2667994737,273792366,2331590177,104699613,95345982,3175501286,2377486676,1560637892,3564045318,369057872,4213447064,3919042237,1137477952,2658625497,1119727848,2340947849,1530455833,4007360968,172466556,266959938,516552836,0,2256734592,3980931627,1890328081,1917742170,4294704398,945164165,3575528878,958871085,3647212047,2787207260,1423022939,775562294,1739656202,3876557655,2530391278,2443058075,3310321856,547512796,1265195639,437656594,3121275539,719700128,3762502690,387781147,218828297,3350065803,2830708150,2848461854,428169201,122466165,3720081049,1627235199,648017665,4122762354,1002783846,2117360635,695634755,3336358691,4234721005,4049844452,3704280881,2232435299,574624663,287343814,612205898,1039717051,840019705,2708326185,793451934,821288114,1391201670,3822090177,376187827,3113855344,1224348052,1679968233,2361698556,1058709744,752375421,2431590963,1321699145,3519142200,2734591178,188127444,2177869557,3727205754,2384911031,3215212461,2648976442,2450346104,3432737375,1180849278,331544205,3102249176,4150144569,2952102595,2159976285,2474404304,766078933,313773861,2570832044,2108100632,1668212892,3145456443,2013908262,418672217,3070356634,2594734927,1852171925,3867060991,3473416636,3907448597,2614737639,919489135,164948639,2094410160,2997825956,590424639,2486224549,1723872674,3157750862,3399941250,3501252752,3625268135,2555048196,3673637356,1343127501,4130281361,3599595085,2957853679,1297403050,81781910,3051593425,2283490410,532201772,1367295589,3926170974,895287692,1953757831,1093597963,492483431,3528626907,1446242576,1192455638,1636604631,209336225,344873464,1015671571,669961897,3375740769,3857572124,2973530695,3747192018,1933530610,3464042516,935293895,3454686199,2858115069,1863638845,3683022916,4085369519,3292445032,875313188,1080017571,3279033885,621591778,1233856572,2504130317,24197544,3017672716,3835484340,3247465558,2220981195,3060847922,1551124588,1463996600],v=[4104605777,1097159550,396673818,660510266,2875968315,2638606623,4200115116,3808662347,821712160,1986918061,3430322568,38544885,3856137295,718002117,893681702,1654886325,2975484382,3122358053,3926825029,4274053469,796197571,1290801793,1184342925,3556361835,2405426947,2459735317,1836772287,1381620373,3196267988,1948373848,3764988233,3385345166,3263785589,2390325492,1480485785,3111247143,3780097726,2293045232,548169417,3459953789,3746175075,439452389,1362321559,1400849762,1685577905,1806599355,2174754046,137073913,1214797936,1174215055,3731654548,2079897426,1943217067,1258480242,529487843,1437280870,3945269170,3049390895,3313212038,923313619,679998e3,3215307299,57326082,377642221,3474729866,2041877159,133361907,1776460110,3673476453,96392454,878845905,2801699524,777231668,4082475170,2330014213,4142626212,2213296395,1626319424,1906247262,1846563261,562755902,3708173718,1040559837,3871163981,1418573201,3294430577,114585348,1343618912,2566595609,3186202582,1078185097,3651041127,3896688048,2307622919,425408743,3371096953,2081048481,1108339068,2216610296,0,2156299017,736970802,292596766,1517440620,251657213,2235061775,2933202493,758720310,265905162,1554391400,1532285339,908999204,174567692,1474760595,4002861748,2610011675,3234156416,3693126241,2001430874,303699484,2478443234,2687165888,585122620,454499602,151849742,2345119218,3064510765,514443284,4044981591,1963412655,2581445614,2137062819,19308535,1928707164,1715193156,4219352155,1126790795,600235211,3992742070,3841024952,836553431,1669664834,2535604243,3323011204,1243905413,3141400786,4180808110,698445255,2653899549,2989552604,2253581325,3252932727,3004591147,1891211689,2487810577,3915653703,4237083816,4030667424,2100090966,865136418,1229899655,953270745,3399679628,3557504664,4118925222,2061379749,3079546586,2915017791,983426092,2022837584,1607244650,2118541908,2366882550,3635996816,972512814,3283088770,1568718495,3499326569,3576539503,621982671,2895723464,410887952,2623762152,1002142683,645401037,1494807662,2595684844,1335535747,2507040230,4293295786,3167684641,367585007,3885750714,1865862730,2668221674,2960971305,2763173681,1059270954,2777952454,2724642869,1320957812,2194319100,2429595872,2815956275,77089521,3973773121,3444575871,2448830231,1305906550,4021308739,2857194700,2516901860,3518358430,1787304780,740276417,1699839814,1592394909,2352307457,2272556026,188821243,1729977011,3687994002,274084841,3594982253,3613494426,2701949495,4162096729,322734571,2837966542,1640576439,484830689,1202797690,3537852828,4067639125,349075736,3342319475,4157467219,4255800159,1030690015,1155237496,2951971274,1757691577,607398968,2738905026,499347990,3794078908,1011452712,227885567,2818666809,213114376,3034881240,1455525988,3414450555,850817237,1817998408,3092726480],w=[0,235474187,470948374,303765277,941896748,908933415,607530554,708780849,1883793496,2118214995,1817866830,1649639237,1215061108,1181045119,1417561698,1517767529,3767586992,4003061179,4236429990,4069246893,3635733660,3602770327,3299278474,3400528769,2430122216,2664543715,2362090238,2193862645,2835123396,2801107407,3035535058,3135740889,3678124923,3576870512,3341394285,3374361702,3810496343,3977675356,4279080257,4043610186,2876494627,2776292904,3076639029,3110650942,2472011535,2640243204,2403728665,2169303058,1001089995,899835584,666464733,699432150,59727847,226906860,530400753,294930682,1273168787,1172967064,1475418501,1509430414,1942435775,2110667444,1876241833,1641816226,2910219766,2743034109,2976151520,3211623147,2505202138,2606453969,2302690252,2269728455,3711829422,3543599269,3240894392,3475313331,3843699074,3943906441,4178062228,4144047775,1306967366,1139781709,1374988112,1610459739,1975683434,2076935265,1775276924,1742315127,1034867998,866637845,566021896,800440835,92987698,193195065,429456164,395441711,1984812685,2017778566,1784663195,1683407248,1315562145,1080094634,1383856311,1551037884,101039829,135050206,437757123,337553864,1042385657,807962610,573804783,742039012,2531067453,2564033334,2328828971,2227573024,2935566865,2700099354,3001755655,3168937228,3868552805,3902563182,4203181171,4102977912,3736164937,3501741890,3265478751,3433712980,1106041591,1340463100,1576976609,1408749034,2043211483,2009195472,1708848333,1809054150,832877231,1068351396,766945465,599762354,159417987,126454664,361929877,463180190,2709260871,2943682380,3178106961,3009879386,2572697195,2538681184,2236228733,2336434550,3509871135,3745345300,3441850377,3274667266,3910161971,3877198648,4110568485,4211818798,2597806476,2497604743,2261089178,2295101073,2733856160,2902087851,3202437046,2968011453,3936291284,3835036895,4136440770,4169408201,3535486456,3702665459,3467192302,3231722213,2051518780,1951317047,1716890410,1750902305,1113818384,1282050075,1584504582,1350078989,168810852,67556463,371049330,404016761,841739592,1008918595,775550814,540080725,3969562369,3801332234,4035489047,4269907996,3569255213,3669462566,3366754619,3332740144,2631065433,2463879762,2160117071,2395588676,2767645557,2868897406,3102011747,3069049960,202008497,33778362,270040487,504459436,875451293,975658646,675039627,641025152,2084704233,1917518562,1615861247,1851332852,1147550661,1248802510,1484005843,1451044056,933301370,967311729,733156972,632953703,260388950,25965917,328671808,496906059,1206477858,1239443753,1543208500,1441952575,2144161806,1908694277,1675577880,1842759443,3610369226,3644379585,3408119516,3307916247,4011190502,3776767469,4077384432,4245618683,2809771154,2842737049,3144396420,3043140495,2673705150,2438237621,2203032232,2370213795],S=[0,185469197,370938394,487725847,741876788,657861945,975451694,824852259,1483753576,1400783205,1315723890,1164071807,1950903388,2135319889,1649704518,1767536459,2967507152,3152976349,2801566410,2918353863,2631447780,2547432937,2328143614,2177544179,3901806776,3818836405,4270639778,4118987695,3299409036,3483825537,3535072918,3652904859,2077965243,1893020342,1841768865,1724457132,1474502543,1559041666,1107234197,1257309336,598438867,681933534,901210569,1052338372,261314535,77422314,428819965,310463728,3409685355,3224740454,3710368113,3593056380,3875770207,3960309330,4045380933,4195456072,2471224067,2554718734,2237133081,2388260884,3212035895,3028143674,2842678573,2724322336,4138563181,4255350624,3769721975,3955191162,3667219033,3516619604,3431546947,3347532110,2933734917,2782082824,3099667487,3016697106,2196052529,2313884476,2499348523,2683765030,1179510461,1296297904,1347548327,1533017514,1786102409,1635502980,2087309459,2003294622,507358933,355706840,136428751,53458370,839224033,957055980,605657339,790073846,2373340630,2256028891,2607439820,2422494913,2706270690,2856345839,3075636216,3160175349,3573941694,3725069491,3273267108,3356761769,4181598602,4063242375,4011996048,3828103837,1033297158,915985419,730517276,545572369,296679730,446754879,129166120,213705253,1709610350,1860738147,1945798516,2029293177,1239331162,1120974935,1606591296,1422699085,4148292826,4233094615,3781033664,3931371469,3682191598,3497509347,3446004468,3328955385,2939266226,2755636671,3106780840,2988687269,2198438022,2282195339,2501218972,2652609425,1201765386,1286567175,1371368976,1521706781,1805211710,1620529459,2105887268,1988838185,533804130,350174575,164439672,46346101,870912086,954669403,636813900,788204353,2358957921,2274680428,2592523643,2441661558,2695033685,2880240216,3065962831,3182487618,3572145929,3756299780,3270937875,3388507166,4174560061,4091327024,4006521127,3854606378,1014646705,930369212,711349675,560487590,272786309,457992840,106852767,223377554,1678381017,1862534868,1914052035,2031621326,1211247597,1128014560,1580087799,1428173050,32283319,182621114,401639597,486441376,768917123,651868046,1003007129,818324884,1503449823,1385356242,1333838021,1150208456,1973745387,2125135846,1673061617,1756818940,2970356327,3120694122,2802849917,2887651696,2637442643,2520393566,2334669897,2149987652,3917234703,3799141122,4284502037,4100872472,3309594171,3460984630,3545789473,3629546796,2050466060,1899603969,1814803222,1730525723,1443857720,1560382517,1075025698,1260232239,575138148,692707433,878443390,1062597235,243256656,91341917,409198410,325965383,3403100636,3252238545,3704300486,3620022987,3874428392,3990953189,4042459122,4227665663,2460449204,2578018489,2226875310,2411029155,3198115200,3046200461,2827177882,2743944855],E=[0,218828297,437656594,387781147,875313188,958871085,775562294,590424639,1750626376,1699970625,1917742170,2135253587,1551124588,1367295589,1180849278,1265195639,3501252752,3720081049,3399941250,3350065803,3835484340,3919042237,4270507174,4085369519,3102249176,3051593425,2734591178,2952102595,2361698556,2177869557,2530391278,2614737639,3145456443,3060847922,2708326185,2892417312,2404901663,2187128086,2504130317,2555048196,3542330227,3727205754,3375740769,3292445032,3876557655,3926170974,4246310725,4027744588,1808481195,1723872674,1910319033,2094410160,1608975247,1391201670,1173430173,1224348052,59984867,244860394,428169201,344873464,935293895,984907214,766078933,547512796,1844882806,1627235199,2011214180,2062270317,1507497298,1423022939,1137477952,1321699145,95345982,145085239,532201772,313773861,830661914,1015671571,731183368,648017665,3175501286,2957853679,2807058932,2858115069,2305455554,2220981195,2474404304,2658625497,3575528878,3625268135,3473416636,3254988725,3778151818,3963161475,4213447064,4130281361,3599595085,3683022916,3432737375,3247465558,3802222185,4020912224,4172763771,4122762354,3201631749,3017672716,2764249623,2848461854,2331590177,2280796200,2431590963,2648976442,104699613,188127444,472615631,287343814,840019705,1058709744,671593195,621591778,1852171925,1668212892,1953757831,2037970062,1514790577,1463996600,1080017571,1297403050,3673637356,3623636965,3235995134,3454686199,4007360968,3822090177,4107101658,4190530515,2997825956,3215212461,2830708150,2779915199,2256734592,2340947849,2627016082,2443058075,172466556,122466165,273792366,492483431,1047239e3,861968209,612205898,695634755,1646252340,1863638845,2013908262,1963115311,1446242576,1530455833,1277555970,1093597963,1636604631,1820824798,2073724613,1989249228,1436590835,1487645946,1337376481,1119727848,164948639,81781910,331544205,516552836,1039717051,821288114,669961897,719700128,2973530695,3157750862,2871682645,2787207260,2232435299,2283490410,2667994737,2450346104,3647212047,3564045318,3279033885,3464042516,3980931627,3762502690,4150144569,4199882800,3070356634,3121275539,2904027272,2686254721,2200818878,2384911031,2570832044,2486224549,3747192018,3528626907,3310321856,3359936201,3950355702,3867060991,4049844452,4234721005,1739656202,1790575107,2108100632,1890328081,1402811438,1586903591,1233856572,1149249077,266959938,48394827,369057872,418672217,1002783846,919489135,567498868,752375421,209336225,24197544,376187827,459744698,945164165,895287692,574624663,793451934,1679968233,1764313568,2117360635,1933530610,1343127501,1560637892,1243112415,1192455638,3704280881,3519142200,3336358691,3419915562,3907448597,3857572124,4075877127,4294704398,3029510009,3113855344,2927934315,2744104290,2159976285,2377486676,2594734927,2544078150],R=[0,151849742,303699484,454499602,607398968,758720310,908999204,1059270954,1214797936,1097159550,1517440620,1400849762,1817998408,1699839814,2118541908,2001430874,2429595872,2581445614,2194319100,2345119218,3034881240,3186202582,2801699524,2951971274,3635996816,3518358430,3399679628,3283088770,4237083816,4118925222,4002861748,3885750714,1002142683,850817237,698445255,548169417,529487843,377642221,227885567,77089521,1943217067,2061379749,1640576439,1757691577,1474760595,1592394909,1174215055,1290801793,2875968315,2724642869,3111247143,2960971305,2405426947,2253581325,2638606623,2487810577,3808662347,3926825029,4044981591,4162096729,3342319475,3459953789,3576539503,3693126241,1986918061,2137062819,1685577905,1836772287,1381620373,1532285339,1078185097,1229899655,1040559837,923313619,740276417,621982671,439452389,322734571,137073913,19308535,3871163981,4021308739,4104605777,4255800159,3263785589,3414450555,3499326569,3651041127,2933202493,2815956275,3167684641,3049390895,2330014213,2213296395,2566595609,2448830231,1305906550,1155237496,1607244650,1455525988,1776460110,1626319424,2079897426,1928707164,96392454,213114376,396673818,514443284,562755902,679998e3,865136418,983426092,3708173718,3557504664,3474729866,3323011204,4180808110,4030667424,3945269170,3794078908,2507040230,2623762152,2272556026,2390325492,2975484382,3092726480,2738905026,2857194700,3973773121,3856137295,4274053469,4157467219,3371096953,3252932727,3673476453,3556361835,2763173681,2915017791,3064510765,3215307299,2156299017,2307622919,2459735317,2610011675,2081048481,1963412655,1846563261,1729977011,1480485785,1362321559,1243905413,1126790795,878845905,1030690015,645401037,796197571,274084841,425408743,38544885,188821243,3613494426,3731654548,3313212038,3430322568,4082475170,4200115116,3780097726,3896688048,2668221674,2516901860,2366882550,2216610296,3141400786,2989552604,2837966542,2687165888,1202797690,1320957812,1437280870,1554391400,1669664834,1787304780,1906247262,2022837584,265905162,114585348,499347990,349075736,736970802,585122620,972512814,821712160,2595684844,2478443234,2293045232,2174754046,3196267988,3079546586,2895723464,2777952454,3537852828,3687994002,3234156416,3385345166,4142626212,4293295786,3841024952,3992742070,174567692,57326082,410887952,292596766,777231668,660510266,1011452712,893681702,1108339068,1258480242,1343618912,1494807662,1715193156,1865862730,1948373848,2100090966,2701949495,2818666809,3004591147,3122358053,2235061775,2352307457,2535604243,2653899549,3915653703,3764988233,4219352155,4067639125,3444575871,3294430577,3746175075,3594982253,836553431,953270745,600235211,718002117,367585007,484830689,133361907,251657213,2041877159,1891211689,1806599355,1654886325,1568718495,1418573201,1335535747,1184342925];function k(t){for(var e=[],r=0;r<t.length;r+=4)e.push(t[r]<<24|t[r+1]<<16|t[r+2]<<8|t[r+3]);return e}var T=function(t){if(!(this instanceof T))throw Error("AES must be instanitated with `new`");Object.defineProperty(this,"key",{value:n(t,!0)}),this._prepare()};T.prototype._prepare=function(){var t=u[this.key.length];if(null==t)throw new Error("invalid key size (must be 16, 24 or 32 bytes)");this._Ke=[],this._Kd=[];for(var e=0;e<=t;e++)this._Ke.push([0,0,0,0]),this._Kd.push([0,0,0,0]);var r,n=4*(t+1),i=this.key.length/4,o=k(this.key);for(e=0;e<i;e++)r=e>>2,this._Ke[r][e%4]=o[e],this._Kd[t-r][e%4]=o[e];for(var s,a=0,l=i;l<n;){if(s=o[i-1],o[0]^=h[s>>16&255]<<24^h[s>>8&255]<<16^h[255&s]<<8^h[s>>24&255]^c[a]<<24,a+=1,8!=i)for(e=1;e<i;e++)o[e]^=o[e-1];else{for(e=1;e<i/2;e++)o[e]^=o[e-1];s=o[i/2-1],o[i/2]^=h[255&s]^h[s>>8&255]<<8^h[s>>16&255]<<16^h[s>>24&255]<<24;for(e=i/2+1;e<i;e++)o[e]^=o[e-1]}for(e=0;e<i&&l<n;)f=l>>2,d=l%4,this._Ke[f][d]=o[e],this._Kd[t-f][d]=o[e++],l++}for(var f=1;f<t;f++)for(var d=0;d<4;d++)s=this._Kd[f][d],this._Kd[f][d]=w[s>>24&255]^S[s>>16&255]^E[s>>8&255]^R[255&s]},T.prototype.encrypt=function(t){if(16!=t.length)throw new Error("invalid plaintext size (must be 16 bytes)");for(var e=this._Ke.length-1,r=[0,0,0,0],n=k(t),o=0;o<4;o++)n[o]^=this._Ke[0][o];for(var s=1;s<e;s++){for(o=0;o<4;o++)r[o]=d[n[o]>>24&255]^p[n[(o+1)%4]>>16&255]^y[n[(o+2)%4]>>8&255]^g[255&n[(o+3)%4]]^this._Ke[s][o];n=r.slice()}var a,l=i(16);for(o=0;o<4;o++)a=this._Ke[e][o],l[4*o]=255&(h[n[o]>>24&255]^a>>24),l[4*o+1]=255&(h[n[(o+1)%4]>>16&255]^a>>16),l[4*o+2]=255&(h[n[(o+2)%4]>>8&255]^a>>8),l[4*o+3]=255&(h[255&n[(o+3)%4]]^a);return l},T.prototype.decrypt=function(t){if(16!=t.length)throw new Error("invalid ciphertext size (must be 16 bytes)");for(var e=this._Kd.length-1,r=[0,0,0,0],n=k(t),o=0;o<4;o++)n[o]^=this._Kd[0][o];for(var s=1;s<e;s++){for(o=0;o<4;o++)r[o]=b[n[o]>>24&255]^m[n[(o+3)%4]>>16&255]^_[n[(o+2)%4]>>8&255]^v[255&n[(o+1)%4]]^this._Kd[s][o];n=r.slice()}var a,l=i(16);for(o=0;o<4;o++)a=this._Kd[e][o],l[4*o]=255&(f[n[o]>>24&255]^a>>24),l[4*o+1]=255&(f[n[(o+3)%4]>>16&255]^a>>16),l[4*o+2]=255&(f[n[(o+2)%4]>>8&255]^a>>8),l[4*o+3]=255&(f[255&n[(o+1)%4]]^a);return l};var x=function(t){if(!(this instanceof x))throw Error("AES must be instanitated with `new`");this.description="Electronic Code Block",this.name="ecb",this._aes=new T(t)};x.prototype.encrypt=function(t){if((t=n(t)).length%16!=0)throw new Error("invalid plaintext size (must be multiple of 16 bytes)");for(var e=i(t.length),r=i(16),s=0;s<t.length;s+=16)o(t,r,0,s,s+16),o(r=this._aes.encrypt(r),e,s);return e},x.prototype.decrypt=function(t){if((t=n(t)).length%16!=0)throw new Error("invalid ciphertext size (must be multiple of 16 bytes)");for(var e=i(t.length),r=i(16),s=0;s<t.length;s+=16)o(t,r,0,s,s+16),o(r=this._aes.decrypt(r),e,s);return e};var A=function(t,e){if(!(this instanceof A))throw Error("AES must be instanitated with `new`");if(this.description="Cipher Block Chaining",this.name="cbc",e){if(16!=e.length)throw new Error("invalid initialation vector size (must be 16 bytes)")}else e=i(16);this._lastCipherblock=n(e,!0),this._aes=new T(t)};A.prototype.encrypt=function(t){if((t=n(t)).length%16!=0)throw new Error("invalid plaintext size (must be multiple of 16 bytes)");for(var e=i(t.length),r=i(16),s=0;s<t.length;s+=16){o(t,r,0,s,s+16);for(var a=0;a<16;a++)r[a]^=this._lastCipherblock[a];this._lastCipherblock=this._aes.encrypt(r),o(this._lastCipherblock,e,s)}return e},A.prototype.decrypt=function(t){if((t=n(t)).length%16!=0)throw new Error("invalid ciphertext size (must be multiple of 16 bytes)");for(var e=i(t.length),r=i(16),s=0;s<t.length;s+=16){o(t,r,0,s,s+16),r=this._aes.decrypt(r);for(var a=0;a<16;a++)e[s+a]=r[a]^this._lastCipherblock[a];o(t,this._lastCipherblock,0,s,s+16)}return e};var O=function(t,e,r){if(!(this instanceof O))throw Error("AES must be instanitated with `new`");if(this.description="Cipher Feedback",this.name="cfb",e){if(16!=e.length)throw new Error("invalid initialation vector size (must be 16 size)")}else e=i(16);r||(r=1),this.segmentSize=r,this._shiftRegister=n(e,!0),this._aes=new T(t)};O.prototype.encrypt=function(t){if(t.length%this.segmentSize!=0)throw new Error("invalid plaintext size (must be segmentSize bytes)");for(var e,r=n(t,!0),i=0;i<r.length;i+=this.segmentSize){e=this._aes.encrypt(this._shiftRegister);for(var s=0;s<this.segmentSize;s++)r[i+s]^=e[s];o(this._shiftRegister,this._shiftRegister,0,this.segmentSize),o(r,this._shiftRegister,16-this.segmentSize,i,i+this.segmentSize)}return r},O.prototype.decrypt=function(t){if(t.length%this.segmentSize!=0)throw new Error("invalid ciphertext size (must be segmentSize bytes)");for(var e,r=n(t,!0),i=0;i<r.length;i+=this.segmentSize){e=this._aes.encrypt(this._shiftRegister);for(var s=0;s<this.segmentSize;s++)r[i+s]^=e[s];o(this._shiftRegister,this._shiftRegister,0,this.segmentSize),o(t,this._shiftRegister,16-this.segmentSize,i,i+this.segmentSize)}return r};var L=function(t,e){if(!(this instanceof L))throw Error("AES must be instanitated with `new`");if(this.description="Output Feedback",this.name="ofb",e){if(16!=e.length)throw new Error("invalid initialation vector size (must be 16 bytes)")}else e=i(16);this._lastPrecipher=n(e,!0),this._lastPrecipherIndex=16,this._aes=new T(t)};L.prototype.encrypt=function(t){for(var e=n(t,!0),r=0;r<e.length;r++)16===this._lastPrecipherIndex&&(this._lastPrecipher=this._aes.encrypt(this._lastPrecipher),this._lastPrecipherIndex=0),e[r]^=this._lastPrecipher[this._lastPrecipherIndex++];return e},L.prototype.decrypt=L.prototype.encrypt;var j=function(t){if(!(this instanceof j))throw Error("Counter must be instanitated with `new`");0===t||t||(t=1),"number"==typeof t?(this._counter=i(16),this.setValue(t)):this.setBytes(t)};j.prototype.setValue=function(t){if("number"!=typeof t||parseInt(t)!=t)throw new Error("invalid counter value (must be an integer)");if(t>Number.MAX_SAFE_INTEGER)throw new Error("integer value out of safe range");for(var e=15;e>=0;--e)this._counter[e]=t%256,t=parseInt(t/256)},j.prototype.setBytes=function(t){if(16!=(t=n(t,!0)).length)throw new Error("invalid counter bytes size (must be 16 bytes)");this._counter=t},j.prototype.increment=function(){for(var t=15;t>=0;t--){if(255!==this._counter[t]){this._counter[t]++;break}this._counter[t]=0}};var M=function(t,e){if(!(this instanceof M))throw Error("AES must be instanitated with `new`");this.description="Counter",this.name="ctr",e instanceof j||(e=new j(e)),this._counter=e,this._remainingCounter=null,this._remainingCounterIndex=16,this._aes=new T(t)};M.prototype.encrypt=function(t){for(var e=n(t,!0),r=0;r<e.length;r++)16===this._remainingCounterIndex&&(this._remainingCounter=this._aes.encrypt(this._counter._counter),this._remainingCounterIndex=0,this._counter.increment()),e[r]^=this._remainingCounter[this._remainingCounterIndex++];return e},M.prototype.decrypt=M.prototype.encrypt;var I={AES:T,Counter:j,ModeOfOperation:{ecb:x,cbc:A,cfb:O,ofb:L,ctr:M},utils:{hex:l,utf8:a},padding:{pkcs7:{pad:function(t){var e=16-(t=n(t,!0)).length%16,r=i(t.length+e);o(t,r);for(var s=t.length;s<r.length;s++)r[s]=e;return r},strip:function(t){if((t=n(t,!0)).length<16)throw new Error("PKCS#7 invalid length");var e=t[t.length-1];if(e>16)throw new Error("PKCS#7 padding byte out of range");for(var r=t.length-e,s=0;s<e;s++)if(t[r+s]!==e)throw new Error("PKCS#7 invalid padding byte");var a=i(r);return o(t,a,0,0,r),a}}},_arrayTest:{coerceArray:n,createArray:i,copyArray:o}};t.exports=I}()}(IG);var PG=IG.exports;const DG=s.inherits,{Transform:CG}=i,NG=g,FG=PG;function BG(t={key:null,salt:null,transformOptions:{}}){if(!(this instanceof BG))return new BG(t);CG.call(this,t),this.salt=t.salt,this.salt||(this.salt=NG.randomBytes(16)),this.key=this.deriveKey(this.salt,t.key),this.cipher=new FG.ModeOfOperation.ctr(new Uint8Array(this.key.aesKey),new FG.Counter(new Uint8Array(Buffer.from("01000000000000000000000000000000","hex")))),this.hmac=NG.createHmac("sha1",this.key.hmacKey),this.passwordVerifier=this.key.passwordVerifier,this.headerSent=!1,this.totalSize=0}FG.Counter.prototype.increment=function(){for(var t=0;t<16;t++){if(255!==this._counter[t]){this._counter[t]++;break}this._counter[t]=0}},DG(BG,CG),BG.prototype.deriveKey=function(t,e){const r=NG.pbkdf2Sync(e,t,1e3,66,"sha1");return{aesKey:r.slice(0,32),hmacKey:r.slice(32,64),passwordVerifier:r.slice(64)}},BG.prototype.getTotalSize=function(){return this.totalSize},BG.prototype.ensureHeaderSent=function(){this.headerSent||(this.push(this.salt),this.totalSize+=this.salt.length,this.push(this.passwordVerifier),this.totalSize+=this.passwordVerifier.length,this.headerSent=!0)},BG.prototype._transform=function(t,e,r){this.ensureHeaderSent();let n=this.cipher.encrypt(new Uint8Array(t));n.length>0&&(this.hmac.update(n),this.push(Buffer.from(n)),this.totalSize+=n.length),r()},BG.prototype._flush=function(t){this.ensureHeaderSent();let e=this.hmac.digest().slice(0,10);this.push(e),this.totalSize+=e.length,t()};var WG=BG,UG=ca.Buffer,zG=[0,1996959894,3993919788,2567524794,124634137,1886057615,3915621685,2657392035,249268274,2044508324,3772115230,2547177864,162941995,2125561021,3887607047,2428444049,498536548,1789927666,4089016648,2227061214,450548861,1843258603,4107580753,2211677639,325883990,1684777152,4251122042,2321926636,335633487,1661365465,4195302755,2366115317,997073096,1281953886,3579855332,2724688242,1006888145,1258607687,3524101629,2768942443,901097722,1119000684,3686517206,2898065728,853044451,1172266101,3705015759,2882616665,651767980,1373503546,3369554304,3218104598,565507253,1454621731,3485111705,3099436303,671266974,1594198024,3322730930,2970347812,795835527,1483230225,3244367275,3060149565,1994146192,31158534,2563907772,4023717930,1907459465,112637215,2680153253,3904427059,2013776290,251722036,2517215374,3775830040,2137656763,141376813,2439277719,3865271297,1802195444,476864866,2238001368,4066508878,1812370925,453092731,2181625025,4111451223,1706088902,314042704,2344532202,4240017532,1658658271,366619977,2362670323,4224994405,1303535960,984961486,2747007092,3569037538,1256170817,1037604311,2765210733,3554079995,1131014506,879679996,2909243462,3663771856,1141124467,855842277,2852801631,3708648649,1342533948,654459306,3188396048,3373015174,1466479909,544179635,3110523913,3462522015,1591671054,702138776,2966460450,3352799412,1504918807,783551873,3082640443,3233442989,3988292384,2596254646,62317068,1957810842,3939845945,2647816111,81470997,1943803523,3814918930,2489596804,225274430,2053790376,3826175755,2466906013,167816743,2097651377,4027552580,2265490386,503444072,1762050814,4150417245,2154129355,426522225,1852507879,4275313526,2312317920,282753626,1742555852,4189708143,2394877945,397917763,1622183637,3604390888,2714866558,953729732,1340076626,3518719985,2797360999,1068828381,1219638859,3624741850,2936675148,906185462,1090812512,3747672003,2825379669,829329135,1181335161,3412177804,3160834842,628085408,1382605366,3423369109,3138078467,570562233,1426400815,3317316542,2998733608,733239954,1555261956,3268935591,3050360625,752459403,1541320221,2607071920,3965973030,1969922972,40735498,2617837225,3943577151,1913087877,83908371,2512341634,3803740692,2075208622,213261112,2463272603,3855990285,2094854071,198958881,2262029012,4057260610,1759359992,534414190,2176718541,4139329115,1873836001,414664567,2282248934,4279200368,1711684554,285281116,2405801727,4167216745,1634467795,376229701,2685067896,3608007406,1308918612,956543938,2808555105,3495958263,1231636301,1047427035,2932959818,3654703836,1088359270,936918e3,2847714899,3736837829,1202900863,817233897,3183342108,3401237130,1404277552,615818150,3134207493,3453421203,1423857449,601450431,3009837614,3294710456,1567103746,711928724,3020668471,3272380065,1510334235,755167117];function $G(t){if(UG.isBuffer(t))return t;var e="function"==typeof UG.alloc&&"function"==typeof UG.from;if("number"==typeof t)return e?UG.alloc(t):new UG(t);if("string"==typeof t)return e?UG.from(t):new UG(t);throw new Error("input must be buffer, number, or string, received "+typeof t)}function HG(t,e){t=$G(t),UG.isBuffer(e)&&(e=e.readUInt32BE(0));for(var r=-1^e,n=0;n<t.length;n++)r=zG[255&(r^t[n])]^r>>>8;return-1^r}function GG(){return t=HG.apply(null,arguments),(e=$G(4)).writeInt32BE(t,0),e;var t,e}"undefined"!=typeof Int32Array&&(zG=new Int32Array(zG)),GG.signed=function(){return HG.apply(null,arguments)},GG.unsigned=function(){return HG.apply(null,arguments)>>>0};var qG=GG;const VG=s.inherits,ZG=WG,YG=SG,{DeflateCRC32Stream:KG,CRC32Stream:QG}=mW,JG=qG,XG=MN,tq=AN,eq=function(t={zlib:{}}){if(!(this instanceof eq))return new eq(t);this.key=t.password,Buffer.isBuffer(this.key)||(this.key=Buffer.from(this.key)),YG.call(this,t)};function rq(t){let e=Buffer.alloc(11);return e.writeUInt16LE(39169,0),e.writeUInt16LE(7,2),e.writeUInt16LE(1,4),e.writeUInt16LE(17729,6),e.writeInt8(3,8),e.writeUInt16LE(t.getMethod(),9),e}VG(eq,YG),eq.prototype._writeLocalFileHeader=function(t){t.getGeneralPurposeBit().useEncryption(!0),t.setExtra(Buffer.concat([t.getExtra(),rq(t)])),t.setMethod(99),t.setVersionNeededToExtract(51),YG.prototype._writeLocalFileHeader.call(this,t)},eq.prototype._writeCentralFileHeader=function(t){var e=t.getGeneralPurposeBit(),r=t.getMethod(),n=t._offsets,i=t.getSize(),o=t.getCompressedSize();if(t.isZip64()||n.file>XG.ZIP64_MAGIC){i=XG.ZIP64_MAGIC,o=XG.ZIP64_MAGIC,t.setVersionNeededToExtract(XG.MIN_VERSION_ZIP64);var s=Buffer.concat([tq.getShortBytes(XG.ZIP64_EXTRA_ID),tq.getShortBytes(24),tq.getEightBytes(t.getSize()),tq.getEightBytes(t.getCompressedSize()),tq.getEightBytes(n.file)],28);t.setExtra(Buffer.concat([t.getExtra(),s]))}this.write(tq.getLongBytes(XG.SIG_CFH)),this.write(tq.getShortBytes(t.getPlatform()<<8|XG.VERSION_MADEBY)),this.write(tq.getShortBytes(t.getVersionNeededToExtract())),this.write(e.encode()),this.write(tq.getShortBytes(r)),this.write(tq.getLongBytes(t.getTimeDos())),this.write(tq.getLongBytes(t.getCrc())),this.write(tq.getLongBytes(o)),this.write(tq.getLongBytes(i));var a=t.getName(),l=t.getComment(),u=t.getCentralDirectoryExtra();e.usesUTF8ForNames()&&(a=Buffer.from(a),l=Buffer.from(l)),this.write(tq.getShortBytes(a.length)),this.write(tq.getShortBytes(u.length)),this.write(tq.getShortBytes(l.length)),this.write(XG.SHORT_ZERO),this.write(tq.getShortBytes(t.getInternalAttributes())),this.write(tq.getLongBytes(t.getExternalAttributes())),n.file>XG.ZIP64_MAGIC?this.write(tq.getLongBytes(XG.ZIP64_MAGIC)):this.write(tq.getLongBytes(n.file)),this.write(a),this.write(u),this.write(l)},eq.prototype._appendBuffer=function(t,e,r){t.setSize(e.length),t.setCompressedSize(e.length+28),t.setCrc(JG.unsigned(e)),this._writeLocalFileHeader(t),this._smartStream(t,r).end(e)},eq.prototype._smartStream=function(t,e){var r=t.getExtra().readInt16LE(9)>0?new KG(this.options.zlib):new QG,n=new ZG({key:this.key,salt:this.options.salt}),i=null;return n.once("end",function(){var o=r.digest().readUInt32BE(0);t.setCrc(o),t.setSize(r.size()),t.setCompressedSize(n.getTotalSize()),this._afterAppend(t),e(i,t)}.bind(this)),r.once("error",function(t){i=t}),r.pipe(n).pipe(this,{end:!1}),r};var nq=eq,iq={exports:{}},oq={exports:{}},sq=Vs,aq=e,lq=vz,uq=d$,cq=lH,hq=kH,fq=QH(),dq=oq.exports={},pq=/[\/\\]/g;dq.exists=function(){var t=aq.join.apply(aq,arguments);return sq.existsSync(t)},dq.expand=function(...t){var e=hq(t[0])?t.shift():{},r=Array.isArray(t[0])?t[0]:t;if(0===r.length)return[];var n=function(t,e){var r=[];return lq(t).forEach(function(t){var n=0===t.indexOf("!");n&&(t=t.slice(1));var i=e(t);r=n?uq(r,i):cq(r,i)}),r}(r,function(t){return fq.sync(t,e)});return e.filter&&(n=n.filter(function(t){t=aq.join(e.cwd||"",t);try{return"function"==typeof e.filter?e.filter(t):sq.statSync(t)[e.filter]()}catch(t){return!1}})),n},dq.expandMapping=function(t,e,r){r=Object.assign({rename:function(t,e){return aq.join(t||"",e)}},r);var n=[],i={};return dq.expand(r,t).forEach(function(t){var o=t;r.flatten&&(o=aq.basename(o)),r.ext&&(o=o.replace(/(\.[^\/]*)?$/,r.ext));var s=r.rename(e,o,r);r.cwd&&(t=aq.join(r.cwd,t)),s=s.replace(pq,"/"),t=t.replace(pq,"/"),i[s]?i[s].src.push(t):(n.push({src:[t],dest:s}),i[s]=n[n.length-1])}),n},dq.normalizeFilesArray=function(t){var e=[];return t.forEach(function(t){("src"in t||"dest"in t)&&e.push(t)}),0===e.length?[]:(e=_(e).chain().forEach(function(t){"src"in t&&t.src&&(Array.isArray(t.src)?t.src=lq(t.src):t.src=[t.src])}).map(function(t){var e=Object.assign({},t);if(delete e.src,delete e.dest,t.expand)return dq.expandMapping(t.src,t.dest,e).map(function(e){var r=Object.assign({},t);return r.orig=Object.assign({},t),r.src=e.src,r.dest=e.dest,["expand","cwd","flatten","rename","ext"].forEach(function(t){delete r[t]}),r});var r=Object.assign({},t);return r.orig=Object.assign({},t),"src"in r&&Object.defineProperty(r,"src",{enumerable:!0,get:function r(){var n;return"result"in r||(n=t.src,n=Array.isArray(n)?lq(n):[n],r.result=dq.expand(e,n)),r.result}}),"dest"in r&&(r.dest=t.dest),r}).flatten().value(),e)};var yq=oq.exports,gq=Vs,bq=e,mq=ll,_q=fl,vq=rU,wq=i.Stream,Sq=il().PassThrough,Eq=iq.exports={};Eq.file=yq,Eq.collectStream=function(t,e){var r=[],n=0;t.on("error",e),t.on("data",function(t){r.push(t),n+=t.length}),t.on("end",function(){var t=new Buffer(n),i=0;r.forEach(function(e){e.copy(t,i),i+=e.length}),e(null,t)})},Eq.dateify=function(t){return(t=t||new Date)instanceof Date||(t="string"==typeof t?new Date(t):new Date),t},Eq.defaults=function(t,e,r){var n=arguments;return n[0]=n[0]||{},vq(...n)},Eq.isStream=function(t){return t instanceof wq},Eq.lazyReadStream=function(t){return new mq.Readable(function(){return gq.createReadStream(t)})},Eq.normalizeInputSource=function(t){if(null===t)return new Buffer(0);if("string"==typeof t)return new Buffer(t);if(Eq.isStream(t)&&!t._readableState){var e=new Sq;return t.pipe(e),e}return t},Eq.sanitizePath=function(t){return _q(t,!1).replace(/^\w+:/,"").replace(/^(\.\.\/|\/)+/,"")},Eq.trailingSlashIt=function(t){return"/"!==t.slice(-1)?t+"/":t},Eq.unixifyPath=function(t){return _q(t,!1).replace(/^\w+:/,"")},Eq.walkdir=function(t,e,r){var n=[];"function"==typeof e&&(r=e,e=t),gq.readdir(t,function(i,o){var s,a,l=0;if(i)return r(i);!function i(){if(!(s=o[l++]))return r(null,n);a=bq.join(t,s),gq.stat(a,function(t,r){n.push({path:a,relative:bq.relative(e,a).replace(/\\/g,"/"),stats:r}),r&&r.isDirectory()?Eq.walkdir(a,e,function(t,e){e.forEach(function(t){n.push(t)}),i()}):i()})}()})};var Rq=iq.exports,kq=SG,Tq=Rq,xq=function(t){if(!(this instanceof xq))return new xq(t);t=this.options=Tq.defaults(t,{comment:"",forceUTC:!1,namePrependSlash:!1,store:!1}),this.supports={directory:!0,symlink:!0},this.engine=new kq(t)};
78
- /**
79
- * ZIP Format Plugin
80
- *
81
- * @module plugins/zip
82
- * @license [MIT]{@link https://github.com/archiverjs/node-archiver/blob/master/LICENSE}
83
- * @copyright (c) 2012-2014 Chris Talkington, contributors.
84
- */xq.prototype.append=function(t,e,r){this.engine.entry(t,e,r)},xq.prototype.finalize=function(){this.engine.finalize()},xq.prototype.on=function(){return this.engine.on.apply(this.engine,arguments)},xq.prototype.pipe=function(){return this.engine.pipe.apply(this.engine,arguments)},xq.prototype.unpipe=function(){return this.engine.unpipe.apply(this.engine,arguments)};var Aq=xq;const Oq=s.inherits,Lq=MG,jq=nq,Mq=Aq,Iq=function(t={}){if(!t.password)throw new Error("options.password is required");if(Buffer.isBuffer(t.password)||(t.password=Buffer.from(t.password,"utf-8")),!(this instanceof Iq))return new Iq(t);switch(Mq.call(this,t),t.encryptionMethod){case"aes256":this.engine=new jq(t);break;case"zip20":this.engine=new Lq(t);break;default:throw new Error(`Unsupported encryption method: '${t.encryptionMethod}'. Please use either 'aes256' or 'zip20'.`)}};Oq(Iq,Mq);var Pq=Bt(Iq),Dq={};yn.listenerCount;var Cq=function(t){return(process&&process.version?process.version:"v5.0.0").split(".")[0].replace("v","")<6?new Buffer(t):Buffer.from(t)};function Nq(t,e){"string"==typeof t||t instanceof String?t=Cq(t):("number"==typeof t||t instanceof Number)&&(t=Cq([t]));for(var r=t.length,n=e=e||this.length-r;n>=0;n--){for(var i=!1,o=0;o<r;o++)if(this[n+o]!=t[o]){i=!0;break}if(!i)return n}return-1}Buffer.prototype.indexOf||(Buffer.prototype.indexOf=function(t,e){e=e||0,"string"==typeof t||t instanceof String?t=Cq(t):("number"==typeof t||t instanceof Number)&&(t=Cq([t]));for(var r=t.length,n=e;n<=this.length-r;n++){for(var i=!1,o=0;o<r;o++)if(this[n+o]!=t[o]){i=!0;break}if(!i)return n}return-1}),Buffer.prototype.lastIndexOf?-1===Cq("ABC").lastIndexOf("ABC")&&(Buffer.prototype.lastIndexOf=Nq):Buffer.prototype.lastIndexOf=Nq,function(t){if(!t.setImmediate){var e,r,n,i,o,s=1,a={},l=!1,u=t.document,c=Object.getPrototypeOf&&Object.getPrototypeOf(t);c=c&&c.setTimeout?c:t,"[object process]"==={}.toString.call(t.process)?e=function(t){process.nextTick(function(){f(t)})}:!function(){if(t.postMessage&&!t.importScripts){var e=!0,r=t.onmessage;return t.onmessage=function(){e=!1},t.postMessage("","*"),t.onmessage=r,e}}()?t.MessageChannel?((n=new MessageChannel).port1.onmessage=function(t){f(t.data)},e=function(t){n.port2.postMessage(t)}):u&&"onreadystatechange"in u.createElement("script")?(r=u.documentElement,e=function(t){var e=u.createElement("script");e.onreadystatechange=function(){f(t),e.onreadystatechange=null,r.removeChild(e),e=null},r.appendChild(e)}):e=function(t){setTimeout(f,0,t)}:(i="setImmediate$"+Math.random()+"$",o=function(e){e.source===t&&"string"==typeof e.data&&0===e.data.indexOf(i)&&f(+e.data.slice(i.length))},t.addEventListener?t.addEventListener("message",o,!1):t.attachEvent("onmessage",o),e=function(e){t.postMessage(i+e,"*")}),c.setImmediate=function(t){"function"!=typeof t&&(t=new Function(""+t));for(var r=new Array(arguments.length-1),n=0;n<r.length;n++)r[n]=arguments[n+1];var i={callback:t,args:r};return a[s]=i,e(s),s++},c.clearImmediate=h}function h(t){delete a[t]}function f(t){if(l)setTimeout(f,0,t);else{var e=a[t];if(e){l=!0;try{!function(t){var e=t.callback,r=t.args;switch(r.length){case 0:e();break;case 1:e(r[0]);break;case 2:e(r[0],r[1]);break;case 3:e(r[0],r[1],r[2]);break;default:e.apply(void 0,r)}}(e)}finally{h(t),l=!1}}}}}("undefined"==typeof self?Ft:self);var Fq={exports:{}},Bq=Wq;function Wq(t){if(!(this instanceof Wq))return new Wq(t);this.value=t}function Uq(t,e,r){var n=[],i=[],o=!0;return function t(s){var a=r?zq(s):s,l={},u={node:a,node_:s,path:[].concat(n),parent:i.slice(-1)[0],key:n.slice(-1)[0],isRoot:0===n.length,level:n.length,circular:null,update:function(t){u.isRoot||(u.parent.node[u.key]=t),u.node=t},delete:function(){delete u.parent.node[u.key]},remove:function(){Array.isArray(u.parent.node)?u.parent.node.splice(u.key,1):delete u.parent.node[u.key]},before:function(t){l.before=t},after:function(t){l.after=t},pre:function(t){l.pre=t},post:function(t){l.post=t},stop:function(){o=!1}};if(!o)return u;if("object"==typeof a&&null!==a){u.isLeaf=0==Object.keys(a).length;for(var c=0;c<i.length;c++)if(i[c].node_===s){u.circular=i[c];break}}else u.isLeaf=!0;u.notLeaf=!u.isLeaf,u.notRoot=!u.isRoot;var h=e.call(u,u.node);if(void 0!==h&&u.update&&u.update(h),l.before&&l.before.call(u,u.node),"object"==typeof u.node&&null!==u.node&&!u.circular){i.push(u);var f=Object.keys(u.node);f.forEach(function(e,i){n.push(e),l.pre&&l.pre.call(u,u.node[e],e);var o=t(u.node[e]);r&&Object.hasOwnProperty.call(u.node,e)&&(u.node[e]=o.node),o.isLast=i==f.length-1,o.isFirst=0==i,l.post&&l.post.call(u,o),n.pop()}),i.pop()}return l.after&&l.after.call(u,u.node),u}(t).node}function zq(t){var e;return"object"==typeof t&&null!==t?(e=Array.isArray(t)?[]:t instanceof Date?new Date(t):t instanceof Boolean?new Boolean(t):t instanceof Number?new Number(t):t instanceof String?new String(t):Object.create(Object.getPrototypeOf(t)),Object.keys(t).forEach(function(r){e[r]=t[r]}),e):t}Wq.prototype.get=function(t){for(var e=this.value,r=0;r<t.length;r++){var n=t[r];if(!Object.hasOwnProperty.call(e,n)){e=void 0;break}e=e[n]}return e},Wq.prototype.set=function(t,e){for(var r=this.value,n=0;n<t.length-1;n++){var i=t[n];Object.hasOwnProperty.call(r,i)||(r[i]={}),r=r[i]}return r[t[n]]=e,e},Wq.prototype.map=function(t){return Uq(this.value,t,!0)},Wq.prototype.forEach=function(t){return this.value=Uq(this.value,t,!1),this.value},Wq.prototype.reduce=function(t,e){var r=1===arguments.length,n=r?this.value:e;return this.forEach(function(e){this.isRoot&&r||(n=t.call(this,n,e))}),n},Wq.prototype.deepEqual=function(t){if(1!==arguments.length)throw new Error("deepEqual requires exactly one object to compare against");var e=!0,r=t;return this.forEach(function(n){var i=function(){e=!1}.bind(this);if(!this.isRoot){if("object"!=typeof r)return i();r=r[this.key]}var o=r;this.post(function(){r=o});var s=function(t){return Object.prototype.toString.call(t)};if(this.circular)Wq(t).get(this.circular.path)!==o&&i();else if(typeof o!=typeof n)i();else if(null===o||null===n||void 0===o||void 0===n)o!==n&&i();else if(o.__proto__!==n.__proto__)i();else if(o===n);else if("function"==typeof o)o instanceof RegExp?o.toString()!=n.toString()&&i():o!==n&&i();else if("object"==typeof o)if("[object Arguments]"===s(n)||"[object Arguments]"===s(o))s(o)!==s(n)&&i();else if(o instanceof Date||n instanceof Date)o instanceof Date&&n instanceof Date&&o.getTime()===n.getTime()||i();else{var a=Object.keys(o),l=Object.keys(n);if(a.length!==l.length)return i();for(var u=0;u<a.length;u++){var c=a[u];Object.hasOwnProperty.call(n,c)||i()}}}),e},Wq.prototype.paths=function(){var t=[];return this.forEach(function(e){t.push(this.path)}),t},Wq.prototype.nodes=function(){var t=[];return this.forEach(function(e){t.push(this.node)}),t},Wq.prototype.clone=function(){var t=[],e=[];return function r(n){for(var i=0;i<t.length;i++)if(t[i]===n)return e[i];if("object"==typeof n&&null!==n){var o=zq(n);return t.push(n),e.push(o),Object.keys(n).forEach(function(t){o[t]=r(n[t])}),t.pop(),e.pop(),o}return n}(this.value)},Object.keys(Wq.prototype).forEach(function(t){Wq[t]=function(e){var r=[].slice.call(arguments,1),n=Wq(e);return n[t].apply(n,r)}});var $q=Bq,Hq=yn.EventEmitter,Gq=qq;function qq(t){var e=qq.saw(t,{}),r=t.call(e.handlers,e);return void 0!==r&&(e.handlers=r),e.record(),e.chain()}qq.light=function(t){var e=qq.saw(t,{}),r=t.call(e.handlers,e);return void 0!==r&&(e.handlers=r),e.chain()},qq.saw=function(t,e){var r=new Hq;return r.handlers=e,r.actions=[],r.chain=function(){var t=$q(r.handlers).map(function(e){if(this.isRoot)return e;var n=this.path;"function"==typeof e&&this.update(function(){return r.actions.push({path:n,args:[].slice.call(arguments)}),t})});return process.nextTick(function(){r.emit("begin"),r.next()}),t},r.pop=function(){return r.actions.shift()},r.next=function(){var t=r.pop();if(t){if(!t.trap){var e=r.handlers;t.path.forEach(function(t){e=e[t]}),e.apply(r.handlers,t.args)}}else r.emit("end")},r.nest=function(e){var n=[].slice.call(arguments,1),i=!0;if("boolean"==typeof e){i=e;e=n.shift()}var o=qq.saw(t,{}),s=t.call(o.handlers,o);void 0!==s&&(o.handlers=s),void 0!==r.step&&o.record(),e.apply(o.chain(),n),!1!==i&&o.on("end",r.next)},r.record=function(){!function(t){t.step=0,t.pop=function(){return t.actions[t.step++]},t.trap=function(e,r){var n=Array.isArray(e)?e:[e];t.actions.push({path:n,step:t.step,cb:r,trap:!0})},t.down=function(e){var r=(Array.isArray(e)?e:[e]).join("/"),n=t.actions.slice(t.step).map(function(e){return!(e.trap&&e.step<=t.step)&&e.path.join("/")==r}).indexOf(!0);n>=0?t.step+=n:t.step=t.actions.length;var i=t.actions[t.step-1];i&&i.trap?(t.step=i.step,i.cb()):t.next()},t.jump=function(e){t.step=e,t.next()}}(r)},["trap","down","jump"].forEach(function(t){r[t]=function(){throw new Error("To use the trap, down and jump features, please call record() first to start recording actions.")}}),r};var Vq=Zq;function Zq(t){if(!(this instanceof Zq))return new Zq(t);this.buffers=t||[],this.length=this.buffers.reduce(function(t,e){return t+e.length},0)}Zq.prototype.push=function(){for(var t=0;t<arguments.length;t++)if(!Buffer.isBuffer(arguments[t]))throw new TypeError("Tried to push a non-buffer");for(t=0;t<arguments.length;t++){var e=arguments[t];this.buffers.push(e),this.length+=e.length}return this.length},Zq.prototype.unshift=function(){for(var t=0;t<arguments.length;t++)if(!Buffer.isBuffer(arguments[t]))throw new TypeError("Tried to unshift a non-buffer");for(t=0;t<arguments.length;t++){var e=arguments[t];this.buffers.unshift(e),this.length+=e.length}return this.length},Zq.prototype.copy=function(t,e,r,n){return this.slice(r,n).copy(t,e,0,n-r)},Zq.prototype.splice=function(t,e){var r=this.buffers,n=t>=0?t:this.length-t,i=[].slice.call(arguments,2);(void 0===e||e>this.length-n)&&(e=this.length-n);for(t=0;t<i.length;t++)this.length+=i[t].length;for(var o=new Zq,s=0,a=0;a<r.length&&s+r[a].length<n;a++)s+=r[a].length;if(n-s>0){var l=n-s;if(l+e<r[a].length){o.push(r[a].slice(l,l+e));var u=r[a],c=new Buffer(l);for(t=0;t<l;t++)c[t]=u[t];var h=new Buffer(u.length-l-e);for(t=l+e;t<u.length;t++)h[t-e-l]=u[t];if(i.length>0){var f=i.slice();f.unshift(c),f.push(h),r.splice.apply(r,[a,1].concat(f)),a+=f.length,i=[]}else r.splice(a,1,c,h),a+=2}else o.push(r[a].slice(l)),r[a]=r[a].slice(0,l),a++}for(i.length>0&&(r.splice.apply(r,[a,0].concat(i)),a+=i.length);o.length<e;){var d=r[a],p=d.length,y=Math.min(p,e-o.length);y===p?(o.push(d),r.splice(a,1)):(o.push(d.slice(0,y)),r[a]=r[a].slice(y))}return this.length-=o.length,o},Zq.prototype.slice=function(t,e){var r=this.buffers;void 0===e&&(e=this.length),void 0===t&&(t=0),e>this.length&&(e=this.length);for(var n=0,i=0;i<r.length&&n+r[i].length<=t;i++)n+=r[i].length;for(var o=new Buffer(e-t),s=0,a=i;s<e-t&&a<r.length;a++){var l=r[a].length,u=0===s?t-n:0,c=s+l>=e-t?Math.min(u+(e-t)-s,l):l;r[a].copy(o,s,u,c),s+=c-u}return o},Zq.prototype.pos=function(t){if(t<0||t>=this.length)throw new Error("oob");for(var e=t,r=0,n=null;;){if(e<(n=this.buffers[r]).length)return{buf:r,offset:e};e-=n.length,r++}},Zq.prototype.get=function(t){var e=this.pos(t);return this.buffers[e.buf].get(e.offset)},Zq.prototype.set=function(t,e){var r=this.pos(t);return this.buffers[r.buf].set(r.offset,e)},Zq.prototype.indexOf=function(t,e){if("string"==typeof t)t=new Buffer(t);else if(!(t instanceof Buffer))throw new Error("Invalid type for a search string");if(!t.length)return 0;if(!this.length)return-1;var r,n=0,i=0,o=0,s=0;if(e){var a=this.pos(e);n=a.buf,i=a.offset,s=e}for(;;){for(;i>=this.buffers[n].length;)if(i=0,++n>=this.buffers.length)return-1;if(this.buffers[n][i]==t[o]){if(0==o&&(r={i:n,j:i,pos:s}),++o==t.length)return r.pos}else 0!=o&&(n=r.i,i=r.j,s=r.pos,o=0);i++,s++}},Zq.prototype.toBuffer=function(){return this.slice()},Zq.prototype.toString=function(t,e,r){return this.slice(e,r).toString(t)};var Yq=function(t){function e(t,e){var n=r.store,i=t.split(".");i.slice(0,-1).forEach(function(t){void 0===n[t]&&(n[t]={}),n=n[t]});var o=i[i.length-1];return 1==arguments.length?n[o]:n[o]=e}var r={get:function(t){return e(t)},set:function(t,r){return e(t,r)},store:t||{}};return r};!function(t,e){var r=Gq,n=yn.EventEmitter,o=Vq,s=Yq,a=i.Stream;function l(t){for(var e=0,r=0;r<t.length;r++)e+=Math.pow(256,r)*t[r];return e}function u(t){for(var e=0,r=0;r<t.length;r++)e+=Math.pow(256,t.length-r-1)*t[r];return e}function c(t){var e=u(t);return 128&~t[0]||(e-=Math.pow(256,t.length)),e}function h(t){var e=l(t);return 128&~t[t.length-1]||(e-=Math.pow(256,t.length)),e}function f(t){var e={};return[1,2,4,8].forEach(function(r){var n=8*r;e["word"+n+"le"]=e["word"+n+"lu"]=t(r,l),e["word"+n+"ls"]=t(r,h),e["word"+n+"be"]=e["word"+n+"bu"]=t(r,u),e["word"+n+"bs"]=t(r,c)}),e.word8=e.word8u=e.word8be,e.word8s=e.word8bs,e}(e=t.exports=function(t,r){if(Buffer.isBuffer(t))return e.parse(t);var n=e.stream();return t&&t.pipe?t.pipe(n):t&&(t.on(r||"data",function(t){n.write(t)}),t.on("end",function(){n.end()})),n}).stream=function(t){if(t)return e.apply(null,arguments);var i=null;function l(t,e,r){i={bytes:t,skip:r,cb:function(t){i=null,e(t)}},c()}var u=null;function c(){if(i)if("function"==typeof i)i();else{var t,e=u+i.bytes;if(d.length>=e)null==u?(t=d.splice(0,e),i.skip||(t=t.slice())):(i.skip||(t=d.slice(u,e)),u=e),i.skip?i.cb():i.cb(t)}else g&&(y=!0)}var h=r.light(function(t){function e(){y||t.next()}var r=f(function(t,r){return function(n){l(t,function(t){p.set(n,r(t)),e()})}});return r.tap=function(e){t.nest(e,p.store)},r.into=function(e,r){p.get(e)||p.set(e,{});var n=p;p=s(n.get(e)),t.nest(function(){r.apply(this,arguments),this.tap(function(){p=n})},p.store)},r.flush=function(){p.store={},e()},r.loop=function(r){var n=!1;t.nest(!1,function i(){this.vars=p.store,r.call(this,function(){n=!0,e()},p.store),this.tap(function(){n?t.next():i.call(this)}.bind(this))},p.store)},r.buffer=function(t,r){"string"==typeof r&&(r=p.get(r)),l(r,function(r){p.set(t,r),e()})},r.skip=function(t){"string"==typeof t&&(t=p.get(t)),l(t,function(){e()})},r.scan=function(t,r){if("string"==typeof r)r=new Buffer(r);else if(!Buffer.isBuffer(r))throw new Error("search must be a Buffer or a string");var n=0;i=function(){var o=d.indexOf(r,u+n),s=o-u-n;-1!==o?(i=null,null!=u?(p.set(t,d.slice(u,u+n+s)),u+=n+s+r.length):(p.set(t,d.slice(0,n+s)),d.splice(0,n+s+r.length)),e(),c()):s=Math.max(d.length-r.length-u-n,0),n+=s},c()},r.peek=function(e){u=0,t.nest(function(){e.call(this,p.store),this.tap(function(){u=null})})},r});h.writable=!0;var d=o();h.write=function(t){d.push(t),c()};var p=s(),y=!1,g=!1;return h.end=function(){g=!0},h.pipe=a.prototype.pipe,Object.getOwnPropertyNames(n.prototype).forEach(function(t){h[t]=n.prototype[t]}),h},e.parse=function(t){var e=f(function(i,o){return function(s){if(r+i<=t.length){var a=t.slice(r,r+i);r+=i,n.set(s,o(a))}else n.set(s,null);return e}}),r=0,n=s();return e.vars=n.store,e.tap=function(t){return t.call(e,n.store),e},e.into=function(t,r){n.get(t)||n.set(t,{});var i=n;return n=s(i.get(t)),r.call(e,n.store),n=i,e},e.loop=function(t){for(var r=!1,i=function(){r=!0};!1===r;)t.call(e,i,n.store);return e},e.buffer=function(i,o){"string"==typeof o&&(o=n.get(o));var s=t.slice(r,Math.min(t.length,r+o));return r+=o,n.set(i,s),e},e.skip=function(t){return"string"==typeof t&&(t=n.get(t)),r+=t,e},e.scan=function(i,o){if("string"==typeof o)o=new Buffer(o);else if(!Buffer.isBuffer(o))throw new Error("search must be a Buffer or a string");n.set(i,null);for(var s=0;s+r<=t.length-o.length+1;s++){for(var a=0;a<o.length&&t[r+s+a]===o[a];a++);if(a===o.length)break}return n.set(i,t.slice(r,r+s)),r+=s+o.length,e},e.peek=function(t){var i=r;return t.call(e,n.store),r=i,e},e.flush=function(){return n.store={},e},e.eof=function(){return r>=t.length},e}}(Fq,Fq.exports);var Kq=Fq.exports,Qq={exports:{}};
85
- /* @preserve
86
- * The MIT License (MIT)
87
- *
88
- * Copyright (c) 2013-2015 Petka Antonov
89
- *
90
- * Permission is hereby granted, free of charge, to any person obtaining a copy
91
- * of this software and associated documentation files (the "Software"), to deal
92
- * in the Software without restriction, including without limitation the rights
93
- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
94
- * copies of the Software, and to permit persons to whom the Software is
95
- * furnished to do so, subject to the following conditions:
96
- *
97
- * The above copyright notice and this permission notice shall be included in
98
- * all copies or substantial portions of the Software.
99
- *
100
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
101
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
102
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
103
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
104
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
105
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
106
- * THE SOFTWARE.
107
- *
108
- */
109
- !function(t){t.exports=function t(e,r,n){function i(s,a){if(!r[s]){if(!e[s]){var l="function"==typeof _dereq_&&_dereq_;if(!a&&l)return l(s,!0);if(o)return o(s,!0);var u=new Error("Cannot find module '"+s+"'");throw u.code="MODULE_NOT_FOUND",u}var c=r[s]={exports:{}};e[s][0].call(c.exports,function(t){var r=e[s][1][t];return i(r||t)},c,c.exports,t,e,r,n)}return r[s].exports}for(var o="function"==typeof _dereq_&&_dereq_,s=0;s<n.length;s++)i(n[s]);return i}({1:[function(t,e,r){e.exports=function(t){var e=t._SomePromiseArray;function r(t){var r=new e(t),n=r.promise();return r.setHowMany(1),r.setUnwrap(),r.init(),n}t.any=function(t){return r(t)},t.prototype.any=function(){return r(this)}}},{}],2:[function(t,e,r){var n;try{throw new Error}catch(t){n=t}var i=t("./schedule"),o=t("./queue"),s=t("./util");function a(){this._customScheduler=!1,this._isTickUsed=!1,this._lateQueue=new o(16),this._normalQueue=new o(16),this._haveDrainedQueues=!1,this._trampolineEnabled=!0;var t=this;this.drainQueues=function(){t._drainQueues()},this._schedule=i}function l(t,e,r){this._lateQueue.push(t,e,r),this._queueTick()}function u(t,e,r){this._normalQueue.push(t,e,r),this._queueTick()}function c(t){this._normalQueue._pushOne(t),this._queueTick()}a.prototype.setScheduler=function(t){var e=this._schedule;return this._schedule=t,this._customScheduler=!0,e},a.prototype.hasCustomScheduler=function(){return this._customScheduler},a.prototype.enableTrampoline=function(){this._trampolineEnabled=!0},a.prototype.disableTrampolineIfNecessary=function(){s.hasDevTools&&(this._trampolineEnabled=!1)},a.prototype.haveItemsQueued=function(){return this._isTickUsed||this._haveDrainedQueues},a.prototype.fatalError=function(t,e){e?(process.stderr.write("Fatal "+(t instanceof Error?t.stack:t)+"\n"),process.exit(2)):this.throwLater(t)},a.prototype.throwLater=function(t,e){if(1===arguments.length&&(e=t,t=function(){throw e}),"undefined"!=typeof setTimeout)setTimeout(function(){t(e)},0);else try{this._schedule(function(){t(e)})}catch(t){throw new Error("No async scheduler available\n\n See http://goo.gl/MqrFmX\n")}},s.hasDevTools?(a.prototype.invokeLater=function(t,e,r){this._trampolineEnabled?l.call(this,t,e,r):this._schedule(function(){setTimeout(function(){t.call(e,r)},100)})},a.prototype.invoke=function(t,e,r){this._trampolineEnabled?u.call(this,t,e,r):this._schedule(function(){t.call(e,r)})},a.prototype.settlePromises=function(t){this._trampolineEnabled?c.call(this,t):this._schedule(function(){t._settlePromises()})}):(a.prototype.invokeLater=l,a.prototype.invoke=u,a.prototype.settlePromises=c),a.prototype._drainQueue=function(t){for(;t.length()>0;){var e=t.shift();if("function"==typeof e){var r=t.shift(),n=t.shift();e.call(r,n)}else e._settlePromises()}},a.prototype._drainQueues=function(){this._drainQueue(this._normalQueue),this._reset(),this._haveDrainedQueues=!0,this._drainQueue(this._lateQueue)},a.prototype._queueTick=function(){this._isTickUsed||(this._isTickUsed=!0,this._schedule(this.drainQueues))},a.prototype._reset=function(){this._isTickUsed=!1},e.exports=a,e.exports.firstLineError=n},{"./queue":26,"./schedule":29,"./util":36}],3:[function(t,e,r){e.exports=function(t,e,r,n){var i=!1,o=function(t,e){this._reject(e)},s=function(t,e){e.promiseRejectionQueued=!0,e.bindingPromise._then(o,o,null,this,t)},a=function(t,e){50397184&this._bitField||this._resolveCallback(e.target)},l=function(t,e){e.promiseRejectionQueued||this._reject(t)};t.prototype.bind=function(o){i||(i=!0,t.prototype._propagateFrom=n.propagateFromFunction(),t.prototype._boundValue=n.boundValueFunction());var u=r(o),c=new t(e);c._propagateFrom(this,1);var h=this._target();if(c._setBoundTo(u),u instanceof t){var f={promiseRejectionQueued:!1,promise:c,target:h,bindingPromise:u};h._then(e,s,void 0,c,f),u._then(a,l,void 0,c,f),c._setOnCancel(u)}else c._resolveCallback(h);return c},t.prototype._setBoundTo=function(t){void 0!==t?(this._bitField=2097152|this._bitField,this._boundTo=t):this._bitField=-2097153&this._bitField},t.prototype._isBound=function(){return!(2097152&~this._bitField)},t.bind=function(e,r){return t.resolve(r).bind(e)}}},{}],4:[function(t,e,r){var n;function i(){try{Promise===o&&(Promise=n)}catch(t){}return o}"undefined"!=typeof Promise&&(n=Promise);var o=t("./promise")();o.noConflict=i,e.exports=o},{"./promise":22}],5:[function(t,e,r){var n=Object.create;if(n){var i=n(null),o=n(null);i[" size"]=o[" size"]=0}e.exports=function(e){var r,n=t("./util"),i=n.canEvaluate;function o(t,r){var i;if(null!=t&&(i=t[r]),"function"!=typeof i){var o="Object "+n.classString(t)+" has no method '"+n.toString(r)+"'";throw new e.TypeError(o)}return i}function s(t){return o(t,this.pop()).apply(t,this)}function a(t){return t[this]}function l(t){var e=+this;return e<0&&(e=Math.max(0,e+t.length)),t[e]}n.isIdentifier,e.prototype.call=function(t){var e=[].slice.call(arguments,1);return e.push(t),this._then(s,void 0,void 0,e,void 0)},e.prototype.get=function(t){var e;if("number"==typeof t)e=l;else if(i){var n=r(t);e=null!==n?n:a}else e=a;return this._then(e,void 0,void 0,t,void 0)}}},{"./util":36}],6:[function(t,e,r){e.exports=function(e,r,n,i){var o=t("./util"),s=o.tryCatch,a=o.errorObj,l=e._async;e.prototype.break=e.prototype.cancel=function(){if(!i.cancellation())return this._warn("cancellation is disabled");for(var t=this,e=t;t._isCancellable();){if(!t._cancelBy(e)){e._isFollowing()?e._followee().cancel():e._cancelBranched();break}var r=t._cancellationParent;if(null==r||!r._isCancellable()){t._isFollowing()?t._followee().cancel():t._cancelBranched();break}t._isFollowing()&&t._followee().cancel(),t._setWillBeCancelled(),e=t,t=r}},e.prototype._branchHasCancelled=function(){this._branchesRemainingToCancel--},e.prototype._enoughBranchesHaveCancelled=function(){return void 0===this._branchesRemainingToCancel||this._branchesRemainingToCancel<=0},e.prototype._cancelBy=function(t){return t===this?(this._branchesRemainingToCancel=0,this._invokeOnCancel(),!0):(this._branchHasCancelled(),!!this._enoughBranchesHaveCancelled()&&(this._invokeOnCancel(),!0))},e.prototype._cancelBranched=function(){this._enoughBranchesHaveCancelled()&&this._cancel()},e.prototype._cancel=function(){this._isCancellable()&&(this._setCancelled(),l.invoke(this._cancelPromises,this,void 0))},e.prototype._cancelPromises=function(){this._length()>0&&this._settlePromises()},e.prototype._unsetOnCancel=function(){this._onCancelField=void 0},e.prototype._isCancellable=function(){return this.isPending()&&!this._isCancelled()},e.prototype.isCancellable=function(){return this.isPending()&&!this.isCancelled()},e.prototype._doInvokeOnCancel=function(t,e){if(o.isArray(t))for(var r=0;r<t.length;++r)this._doInvokeOnCancel(t[r],e);else if(void 0!==t)if("function"==typeof t){if(!e){var n=s(t).call(this._boundValue());n===a&&(this._attachExtraTrace(n.e),l.throwLater(n.e))}}else t._resultCancelled(this)},e.prototype._invokeOnCancel=function(){var t=this._onCancel();this._unsetOnCancel(),l.invoke(this._doInvokeOnCancel,this,t)},e.prototype._invokeInternalOnCancel=function(){this._isCancellable()&&(this._doInvokeOnCancel(this._onCancel(),!0),this._unsetOnCancel())},e.prototype._resultCancelled=function(){this.cancel()}}},{"./util":36}],7:[function(t,e,r){e.exports=function(e){var r=t("./util"),n=t("./es5").keys,i=r.tryCatch,o=r.errorObj;function s(t,s,a){return function(l){var u=a._boundValue();t:for(var c=0;c<t.length;++c){var h=t[c];if(h===Error||null!=h&&h.prototype instanceof Error){if(l instanceof h)return i(s).call(u,l)}else if("function"==typeof h){var f=i(h).call(u,l);if(f===o)return f;if(f)return i(s).call(u,l)}else if(r.isObject(l)){for(var d=n(h),p=0;p<d.length;++p){var y=d[p];if(h[y]!=l[y])continue t}return i(s).call(u,l)}}return e}}return s}},{"./es5":13,"./util":36}],8:[function(t,e,r){e.exports=function(t){var e=!1,r=[];function n(){this._trace=new n.CapturedTrace(o())}function i(){if(e)return new n}function o(){var t=r.length-1;if(t>=0)return r[t]}return t.prototype._promiseCreated=function(){},t.prototype._pushContext=function(){},t.prototype._popContext=function(){return null},t._peekContext=t.prototype._peekContext=function(){},n.prototype._pushContext=function(){void 0!==this._trace&&(this._trace._promiseCreated=null,r.push(this._trace))},n.prototype._popContext=function(){if(void 0!==this._trace){var t=r.pop(),e=t._promiseCreated;return t._promiseCreated=null,e}return null},n.CapturedTrace=null,n.create=i,n.deactivateLongStackTraces=function(){},n.activateLongStackTraces=function(){var r=t.prototype._pushContext,i=t.prototype._popContext,s=t._peekContext,a=t.prototype._peekContext,l=t.prototype._promiseCreated;n.deactivateLongStackTraces=function(){t.prototype._pushContext=r,t.prototype._popContext=i,t._peekContext=s,t.prototype._peekContext=a,t.prototype._promiseCreated=l,e=!1},e=!0,t.prototype._pushContext=n.prototype._pushContext,t.prototype._popContext=n.prototype._popContext,t._peekContext=t.prototype._peekContext=o,t.prototype._promiseCreated=function(){var t=this._peekContext();t&&null==t._promiseCreated&&(t._promiseCreated=this)}},n}},{}],9:[function(t,e,r){e.exports=function(e,r){var n,i,o,s=e._getDomain,a=e._async,l=t("./errors").Warning,u=t("./util"),c=u.canAttachTrace,h=/[\\\/]bluebird[\\\/]js[\\\/](release|debug|instrumented)/,f=/\((?:timers\.js):\d+:\d+\)/,d=/[\/<\(](.+?):(\d+):(\d+)\)?\s*$/,p=null,y=null,g=!1,b=!(0==u.env("BLUEBIRD_DEBUG")),m=!(0==u.env("BLUEBIRD_WARNINGS")||!b&&!u.env("BLUEBIRD_WARNINGS")),_=!(0==u.env("BLUEBIRD_LONG_STACK_TRACES")||!b&&!u.env("BLUEBIRD_LONG_STACK_TRACES")),v=0!=u.env("BLUEBIRD_W_FORGOTTEN_RETURN")&&(m||!!u.env("BLUEBIRD_W_FORGOTTEN_RETURN"));e.prototype.suppressUnhandledRejections=function(){var t=this._target();t._bitField=-1048577&t._bitField|524288},e.prototype._ensurePossibleRejectionHandled=function(){524288&this._bitField||(this._setRejectionIsUnhandled(),a.invokeLater(this._notifyUnhandledRejection,this,void 0))},e.prototype._notifyUnhandledRejectionIsHandled=function(){Y("rejectionHandled",n,void 0,this)},e.prototype._setReturnedNonUndefined=function(){this._bitField=268435456|this._bitField},e.prototype._returnedNonUndefined=function(){return!!(268435456&this._bitField)},e.prototype._notifyUnhandledRejection=function(){if(this._isRejectionUnhandled()){var t=this._settledValue();this._setUnhandledRejectionIsNotified(),Y("unhandledRejection",i,t,this)}},e.prototype._setUnhandledRejectionIsNotified=function(){this._bitField=262144|this._bitField},e.prototype._unsetUnhandledRejectionIsNotified=function(){this._bitField=-262145&this._bitField},e.prototype._isUnhandledRejectionNotified=function(){return(262144&this._bitField)>0},e.prototype._setRejectionIsUnhandled=function(){this._bitField=1048576|this._bitField},e.prototype._unsetRejectionIsUnhandled=function(){this._bitField=-1048577&this._bitField,this._isUnhandledRejectionNotified()&&(this._unsetUnhandledRejectionIsNotified(),this._notifyUnhandledRejectionIsHandled())},e.prototype._isRejectionUnhandled=function(){return(1048576&this._bitField)>0},e.prototype._warn=function(t,e,r){return U(t,e,r||this)},e.onPossiblyUnhandledRejection=function(t){var e=s();i="function"==typeof t?null===e?t:u.domainBind(e,t):void 0},e.onUnhandledRejectionHandled=function(t){var e=s();n="function"==typeof t?null===e?t:u.domainBind(e,t):void 0};var w=function(){};e.longStackTraces=function(){if(a.haveItemsQueued()&&!ot.longStackTraces)throw new Error("cannot enable long stack traces after promises have been created\n\n See http://goo.gl/MqrFmX\n");if(!ot.longStackTraces&&J()){var t=e.prototype._captureStackTrace,n=e.prototype._attachExtraTrace;ot.longStackTraces=!0,w=function(){if(a.haveItemsQueued()&&!ot.longStackTraces)throw new Error("cannot enable long stack traces after promises have been created\n\n See http://goo.gl/MqrFmX\n");e.prototype._captureStackTrace=t,e.prototype._attachExtraTrace=n,r.deactivateLongStackTraces(),a.enableTrampoline(),ot.longStackTraces=!1},e.prototype._captureStackTrace=N,e.prototype._attachExtraTrace=F,r.activateLongStackTraces(),a.disableTrampolineIfNecessary()}},e.hasLongStackTraces=function(){return ot.longStackTraces&&J()};var S=function(){try{if("function"==typeof CustomEvent){var t=new CustomEvent("CustomEvent");return u.global.dispatchEvent(t),function(t,e){var r=new CustomEvent(t.toLowerCase(),{detail:e,cancelable:!0});return!u.global.dispatchEvent(r)}}return"function"==typeof Event?(t=new Event("CustomEvent"),u.global.dispatchEvent(t),function(t,e){var r=new Event(t.toLowerCase(),{cancelable:!0});return r.detail=e,!u.global.dispatchEvent(r)}):((t=document.createEvent("CustomEvent")).initCustomEvent("testingtheevent",!1,!0,{}),u.global.dispatchEvent(t),function(t,e){var r=document.createEvent("CustomEvent");return r.initCustomEvent(t.toLowerCase(),!1,!0,e),!u.global.dispatchEvent(r)})}catch(t){}return function(){return!1}}(),E=u.isNode?function(){return process.emit.apply(process,arguments)}:u.global?function(t){var e="on"+t.toLowerCase(),r=u.global[e];return!!r&&(r.apply(u.global,[].slice.call(arguments,1)),!0)}:function(){return!1};function R(t,e){return{promise:e}}var k={promiseCreated:R,promiseFulfilled:R,promiseRejected:R,promiseResolved:R,promiseCancelled:R,promiseChained:function(t,e,r){return{promise:e,child:r}},warning:function(t,e){return{warning:e}},unhandledRejection:function(t,e,r){return{reason:e,promise:r}},rejectionHandled:R},T=function(t){var e=!1;try{e=E.apply(null,arguments)}catch(t){a.throwLater(t),e=!0}var r=!1;try{r=S(t,k[t].apply(null,arguments))}catch(t){a.throwLater(t),r=!0}return r||e};function x(){return!1}function A(t,e,r){var n=this;try{t(e,r,function(t){if("function"!=typeof t)throw new TypeError("onCancel must be a function, got: "+u.toString(t));n._attachCancellationCallback(t)})}catch(t){return t}}function O(t){if(!this._isCancellable())return this;var e=this._onCancel();void 0!==e?u.isArray(e)?e.push(t):this._setOnCancel([e,t]):this._setOnCancel(t)}function L(){return this._onCancelField}function j(t){this._onCancelField=t}function M(){this._cancellationParent=void 0,this._onCancelField=void 0}function I(t,e){if(1&e){this._cancellationParent=t;var r=t._branchesRemainingToCancel;void 0===r&&(r=0),t._branchesRemainingToCancel=r+1}2&e&&t._isBound()&&this._setBoundTo(t._boundTo)}function P(t,e){2&e&&t._isBound()&&this._setBoundTo(t._boundTo)}e.config=function(t){if("longStackTraces"in(t=Object(t))&&(t.longStackTraces?e.longStackTraces():!t.longStackTraces&&e.hasLongStackTraces()&&w()),"warnings"in t){var r=t.warnings;ot.warnings=!!r,v=ot.warnings,u.isObject(r)&&"wForgottenReturn"in r&&(v=!!r.wForgottenReturn)}if("cancellation"in t&&t.cancellation&&!ot.cancellation){if(a.haveItemsQueued())throw new Error("cannot enable cancellation after promises are in use");e.prototype._clearCancellationData=M,e.prototype._propagateFrom=I,e.prototype._onCancel=L,e.prototype._setOnCancel=j,e.prototype._attachCancellationCallback=O,e.prototype._execute=A,D=I,ot.cancellation=!0}return"monitoring"in t&&(t.monitoring&&!ot.monitoring?(ot.monitoring=!0,e.prototype._fireEvent=T):!t.monitoring&&ot.monitoring&&(ot.monitoring=!1,e.prototype._fireEvent=x)),e},e.prototype._fireEvent=x,e.prototype._execute=function(t,e,r){try{t(e,r)}catch(t){return t}},e.prototype._onCancel=function(){},e.prototype._setOnCancel=function(t){},e.prototype._attachCancellationCallback=function(t){},e.prototype._captureStackTrace=function(){},e.prototype._attachExtraTrace=function(){},e.prototype._clearCancellationData=function(){},e.prototype._propagateFrom=function(t,e){};var D=P;function C(){var t=this._boundTo;return void 0!==t&&t instanceof e?t.isFulfilled()?t.value():void 0:t}function N(){this._trace=new nt(this._peekContext())}function F(t,e){if(c(t)){var r=this._trace;if(void 0!==r&&e&&(r=r._parent),void 0!==r)r.attachExtraTrace(t);else if(!t.__stackCleaned__){var n=V(t);u.notEnumerableProp(t,"stack",n.message+"\n"+n.stack.join("\n")),u.notEnumerableProp(t,"__stackCleaned__",!0)}}}function B(t,e,r,n,i){if(void 0===t&&null!==e&&v){if(void 0!==i&&i._returnedNonUndefined())return;if(!(65535&n._bitField))return;r&&(r+=" ");var o="",s="";if(e._trace){for(var a=e._trace.stack.split("\n"),l=G(a),u=l.length-1;u>=0;--u){var c=l[u];if(!f.test(c)){var h=c.match(d);h&&(o="at "+h[1]+":"+h[2]+":"+h[3]+" ");break}}if(l.length>0){var p=l[0];for(u=0;u<a.length;++u)if(a[u]===p){u>0&&(s="\n"+a[u-1]);break}}}var y="a promise was created in a "+r+"handler "+o+"but was not returned from it, see http://goo.gl/rRqMUw"+s;n._warn(y,!0,e)}}function W(t,e){var r=t+" is deprecated and will be removed in a future version.";return e&&(r+=" Use "+e+" instead."),U(r)}function U(t,r,n){if(ot.warnings){var i,o=new l(t);if(r)n._attachExtraTrace(o);else if(ot.longStackTraces&&(i=e._peekContext()))i.attachExtraTrace(o);else{var s=V(o);o.stack=s.message+"\n"+s.stack.join("\n")}T("warning",o)||Z(o,"",!0)}}function z(t,e){for(var r=0;r<e.length-1;++r)e[r].push("From previous event:"),e[r]=e[r].join("\n");return r<e.length&&(e[r]=e[r].join("\n")),t+"\n"+e.join("\n")}function $(t){for(var e=0;e<t.length;++e)(0===t[e].length||e+1<t.length&&t[e][0]===t[e+1][0])&&(t.splice(e,1),e--)}function H(t){for(var e=t[0],r=1;r<t.length;++r){for(var n=t[r],i=e.length-1,o=e[i],s=-1,a=n.length-1;a>=0;--a)if(n[a]===o){s=a;break}for(a=s;a>=0;--a){var l=n[a];if(e[i]!==l)break;e.pop(),i--}e=n}}function G(t){for(var e=[],r=0;r<t.length;++r){var n=t[r],i=" (No stack trace)"===n||p.test(n),o=i&&X(n);i&&!o&&(g&&" "!==n.charAt(0)&&(n=" "+n),e.push(n))}return e}function q(t){for(var e=t.stack.replace(/\s+$/g,"").split("\n"),r=0;r<e.length;++r){var n=e[r];if(" (No stack trace)"===n||p.test(n))break}return r>0&&"SyntaxError"!=t.name&&(e=e.slice(r)),e}function V(t){var e=t.stack,r=t.toString();return e="string"==typeof e&&e.length>0?q(t):[" (No stack trace)"],{message:r,stack:"SyntaxError"==t.name?e:G(e)}}function Z(t,e,r){if("undefined"!=typeof console){var n;if(u.isObject(t)){var i=t.stack;n=e+y(i,t)}else n=e+String(t);"function"==typeof o?o(n,r):"function"!=typeof console.log&&"object"!=typeof console.log||console.log(n)}}function Y(t,e,r,n){var i=!1;try{"function"==typeof e&&(i=!0,"rejectionHandled"===t?e(n):e(r,n))}catch(t){a.throwLater(t)}"unhandledRejection"===t?T(t,r,n)||i||Z(r,"Unhandled rejection "):T(t,n)}function K(t){var e;if("function"==typeof t)e="[function "+(t.name||"anonymous")+"]";else{if(e=t&&"function"==typeof t.toString?t.toString():u.toString(t),/\[object [a-zA-Z0-9$_]+\]/.test(e))try{e=JSON.stringify(t)}catch(t){}0===e.length&&(e="(empty array)")}return"(<"+Q(e)+">, no stack trace)"}function Q(t){var e=41;return t.length<e?t:t.substr(0,e-3)+"..."}function J(){return"function"==typeof it}var X=function(){return!1},tt=/[\/<\(]([^:\/]+):(\d+):(?:\d+)\)?\s*$/;function et(t){var e=t.match(tt);if(e)return{fileName:e[1],line:parseInt(e[2],10)}}function rt(t,e){if(J()){for(var r,n,i=t.stack.split("\n"),o=e.stack.split("\n"),s=-1,a=-1,l=0;l<i.length;++l)if(u=et(i[l])){r=u.fileName,s=u.line;break}for(l=0;l<o.length;++l){var u;if(u=et(o[l])){n=u.fileName,a=u.line;break}}s<0||a<0||!r||!n||r!==n||s>=a||(X=function(t){if(h.test(t))return!0;var e=et(t);return!!(e&&e.fileName===r&&s<=e.line&&e.line<=a)})}}function nt(t){this._parent=t,this._promisesCreated=0;var e=this._length=1+(void 0===t?0:t._length);it(this,nt),e>32&&this.uncycle()}u.inherits(nt,Error),r.CapturedTrace=nt,nt.prototype.uncycle=function(){var t=this._length;if(!(t<2)){for(var e=[],r={},n=0,i=this;void 0!==i;++n)e.push(i),i=i._parent;for(n=(t=this._length=n)-1;n>=0;--n){var o=e[n].stack;void 0===r[o]&&(r[o]=n)}for(n=0;n<t;++n){var s=r[e[n].stack];if(void 0!==s&&s!==n){s>0&&(e[s-1]._parent=void 0,e[s-1]._length=1),e[n]._parent=void 0,e[n]._length=1;var a=n>0?e[n-1]:this;s<t-1?(a._parent=e[s+1],a._parent.uncycle(),a._length=a._parent._length+1):(a._parent=void 0,a._length=1);for(var l=a._length+1,u=n-2;u>=0;--u)e[u]._length=l,l++;return}}}},nt.prototype.attachExtraTrace=function(t){if(!t.__stackCleaned__){this.uncycle();for(var e=V(t),r=e.message,n=[e.stack],i=this;void 0!==i;)n.push(G(i.stack.split("\n"))),i=i._parent;H(n),$(n),u.notEnumerableProp(t,"stack",z(r,n)),u.notEnumerableProp(t,"__stackCleaned__",!0)}};var it=function(){var t=/^\s*at\s*/,e=function(t,e){return"string"==typeof t?t:void 0!==e.name&&void 0!==e.message?e.toString():K(e)};if("number"==typeof Error.stackTraceLimit&&"function"==typeof Error.captureStackTrace){Error.stackTraceLimit+=6,p=t,y=e;var r=Error.captureStackTrace;return X=function(t){return h.test(t)},function(t,e){Error.stackTraceLimit+=6,r(t,e),Error.stackTraceLimit-=6}}var n,i=new Error;if("string"==typeof i.stack&&i.stack.split("\n")[0].indexOf("stackDetection@")>=0)return p=/@/,y=e,g=!0,function(t){t.stack=(new Error).stack};try{throw new Error}catch(t){n="stack"in t}return!("stack"in i)&&n&&"number"==typeof Error.stackTraceLimit?(p=t,y=e,function(t){Error.stackTraceLimit+=6;try{throw new Error}catch(e){t.stack=e.stack}Error.stackTraceLimit-=6}):(y=function(t,e){return"string"==typeof t?t:"object"!=typeof e&&"function"!=typeof e||void 0===e.name||void 0===e.message?K(e):e.toString()},null)}();"undefined"!=typeof console&&void 0!==console.warn&&(o=function(t){console.warn(t)},u.isNode&&process.stderr.isTTY?o=function(t,e){var r=e?"":"";console.warn(r+t+"\n")}:u.isNode||"string"!=typeof(new Error).stack||(o=function(t,e){console.warn("%c"+t,e?"color: darkorange":"color: red")}));var ot={warnings:m,longStackTraces:!1,cancellation:!1,monitoring:!1};return _&&e.longStackTraces(),{longStackTraces:function(){return ot.longStackTraces},warnings:function(){return ot.warnings},cancellation:function(){return ot.cancellation},monitoring:function(){return ot.monitoring},propagateFromFunction:function(){return D},boundValueFunction:function(){return C},checkForgottenReturns:B,setBounds:rt,warn:U,deprecated:W,CapturedTrace:nt,fireDomEvent:S,fireGlobalEvent:E}}},{"./errors":12,"./util":36}],10:[function(t,e,r){e.exports=function(t){function e(){return this.value}function r(){throw this.reason}t.prototype.return=t.prototype.thenReturn=function(r){return r instanceof t&&r.suppressUnhandledRejections(),this._then(e,void 0,void 0,{value:r},void 0)},t.prototype.throw=t.prototype.thenThrow=function(t){return this._then(r,void 0,void 0,{reason:t},void 0)},t.prototype.catchThrow=function(t){if(arguments.length<=1)return this._then(void 0,r,void 0,{reason:t},void 0);var e=arguments[1],n=function(){throw e};return this.caught(t,n)},t.prototype.catchReturn=function(r){if(arguments.length<=1)return r instanceof t&&r.suppressUnhandledRejections(),this._then(void 0,e,void 0,{value:r},void 0);var n=arguments[1];n instanceof t&&n.suppressUnhandledRejections();var i=function(){return n};return this.caught(r,i)}}},{}],11:[function(t,e,r){e.exports=function(t,e){var r=t.reduce,n=t.all;function i(){return n(this)}function o(t,n){return r(t,n,e,e)}t.prototype.each=function(t){return r(this,t,e,0)._then(i,void 0,void 0,this,void 0)},t.prototype.mapSeries=function(t){return r(this,t,e,e)},t.each=function(t,n){return r(t,n,e,0)._then(i,void 0,void 0,t,void 0)},t.mapSeries=o}},{}],12:[function(t,e,r){var n,i,o=t("./es5"),s=o.freeze,a=t("./util"),l=a.inherits,u=a.notEnumerableProp;function c(t,e){function r(n){if(!(this instanceof r))return new r(n);u(this,"message","string"==typeof n?n:e),u(this,"name",t),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):Error.call(this)}return l(r,Error),r}var h=c("Warning","warning"),f=c("CancellationError","cancellation error"),d=c("TimeoutError","timeout error"),p=c("AggregateError","aggregate error");try{n=TypeError,i=RangeError}catch(t){n=c("TypeError","type error"),i=c("RangeError","range error")}for(var y="join pop push shift unshift slice filter forEach some every map indexOf lastIndexOf reduce reduceRight sort reverse".split(" "),g=0;g<y.length;++g)"function"==typeof Array.prototype[y[g]]&&(p.prototype[y[g]]=Array.prototype[y[g]]);o.defineProperty(p.prototype,"length",{value:0,configurable:!1,writable:!0,enumerable:!0}),p.prototype.isOperational=!0;var b=0;function m(t){if(!(this instanceof m))return new m(t);u(this,"name","OperationalError"),u(this,"message",t),this.cause=t,this.isOperational=!0,t instanceof Error?(u(this,"message",t.message),u(this,"stack",t.stack)):Error.captureStackTrace&&Error.captureStackTrace(this,this.constructor)}p.prototype.toString=function(){var t=Array(4*b+1).join(" "),e="\n"+t+"AggregateError of:\n";b++,t=Array(4*b+1).join(" ");for(var r=0;r<this.length;++r){for(var n=this[r]===this?"[Circular AggregateError]":this[r]+"",i=n.split("\n"),o=0;o<i.length;++o)i[o]=t+i[o];e+=(n=i.join("\n"))+"\n"}return b--,e},l(m,Error);var _=Error.__BluebirdErrorTypes__;_||(_=s({CancellationError:f,TimeoutError:d,OperationalError:m,RejectionError:m,AggregateError:p}),o.defineProperty(Error,"__BluebirdErrorTypes__",{value:_,writable:!1,enumerable:!1,configurable:!1})),e.exports={Error:Error,TypeError:n,RangeError:i,CancellationError:_.CancellationError,OperationalError:_.OperationalError,TimeoutError:_.TimeoutError,AggregateError:_.AggregateError,Warning:h}},{"./es5":13,"./util":36}],13:[function(t,e,r){var n=function(){return void 0===this}();if(n)e.exports={freeze:Object.freeze,defineProperty:Object.defineProperty,getDescriptor:Object.getOwnPropertyDescriptor,keys:Object.keys,names:Object.getOwnPropertyNames,getPrototypeOf:Object.getPrototypeOf,isArray:Array.isArray,isES5:n,propertyIsWritable:function(t,e){var r=Object.getOwnPropertyDescriptor(t,e);return!(r&&!r.writable&&!r.set)}};else{var i={}.hasOwnProperty,o={}.toString,s={}.constructor.prototype,a=function(t){var e=[];for(var r in t)i.call(t,r)&&e.push(r);return e},l=function(t,e){return{value:t[e]}},u=function(t,e,r){return t[e]=r.value,t},c=function(t){return t},h=function(t){try{return Object(t).constructor.prototype}catch(t){return s}},f=function(t){try{return"[object Array]"===o.call(t)}catch(t){return!1}};e.exports={isArray:f,keys:a,names:a,defineProperty:u,getDescriptor:l,freeze:c,getPrototypeOf:h,isES5:n,propertyIsWritable:function(){return!0}}}},{}],14:[function(t,e,r){e.exports=function(t,e){var r=t.map;t.prototype.filter=function(t,n){return r(this,t,n,e)},t.filter=function(t,n,i){return r(t,n,i,e)}}},{}],15:[function(t,e,r){e.exports=function(e,r){var n=t("./util"),i=e.CancellationError,o=n.errorObj;function s(t,e,r){this.promise=t,this.type=e,this.handler=r,this.called=!1,this.cancelPromise=null}function a(t){this.finallyHandler=t}function l(t,e){return null!=t.cancelPromise&&(arguments.length>1?t.cancelPromise._reject(e):t.cancelPromise._cancel(),t.cancelPromise=null,!0)}function u(){return h.call(this,this.promise._target()._settledValue())}function c(t){if(!l(this,t))return o.e=t,o}function h(t){var n=this.promise,s=this.handler;if(!this.called){this.called=!0;var h=this.isFinallyHandler()?s.call(n._boundValue()):s.call(n._boundValue(),t);if(void 0!==h){n._setReturnedNonUndefined();var f=r(h,n);if(f instanceof e){if(null!=this.cancelPromise){if(f._isCancelled()){var d=new i("late cancellation observer");return n._attachExtraTrace(d),o.e=d,o}f.isPending()&&f._attachCancellationCallback(new a(this))}return f._then(u,c,void 0,this,void 0)}}}return n.isRejected()?(l(this),o.e=t,o):(l(this),t)}return s.prototype.isFinallyHandler=function(){return 0===this.type},a.prototype._resultCancelled=function(){l(this.finallyHandler)},e.prototype._passThrough=function(t,e,r,n){return"function"!=typeof t?this.then():this._then(r,n,void 0,new s(this,e,t),void 0)},e.prototype.lastly=e.prototype.finally=function(t){return this._passThrough(t,0,h,h)},e.prototype.tap=function(t){return this._passThrough(t,1,h)},s}},{"./util":36}],16:[function(t,e,r){e.exports=function(e,r,n,i,o,s){var a=t("./errors").TypeError,l=t("./util"),u=l.errorObj,c=l.tryCatch,h=[];function f(t,r,n){for(var o=0;o<r.length;++o){n._pushContext();var s=c(r[o])(t);if(n._popContext(),s===u){n._pushContext();var a=e.reject(u.e);return n._popContext(),a}var l=i(s,n);if(l instanceof e)return l}return null}function d(t,r,i,o){if(s.cancellation()){var a=new e(n),l=this._finallyPromise=new e(n);this._promise=a.lastly(function(){return l}),a._captureStackTrace(),a._setOnCancel(this)}else(this._promise=new e(n))._captureStackTrace();this._stack=o,this._generatorFunction=t,this._receiver=r,this._generator=void 0,this._yieldHandlers="function"==typeof i?[i].concat(h):h,this._yieldedPromise=null,this._cancellationPhase=!1}l.inherits(d,o),d.prototype._isResolved=function(){return null===this._promise},d.prototype._cleanup=function(){this._promise=this._generator=null,s.cancellation()&&null!==this._finallyPromise&&(this._finallyPromise._fulfill(),this._finallyPromise=null)},d.prototype._promiseCancelled=function(){if(!this._isResolved()){var t;if(void 0!==this._generator.return)this._promise._pushContext(),t=c(this._generator.return).call(this._generator,void 0),this._promise._popContext();else{var r=new e.CancellationError("generator .return() sentinel");e.coroutine.returnSentinel=r,this._promise._attachExtraTrace(r),this._promise._pushContext(),t=c(this._generator.throw).call(this._generator,r),this._promise._popContext()}this._cancellationPhase=!0,this._yieldedPromise=null,this._continue(t)}},d.prototype._promiseFulfilled=function(t){this._yieldedPromise=null,this._promise._pushContext();var e=c(this._generator.next).call(this._generator,t);this._promise._popContext(),this._continue(e)},d.prototype._promiseRejected=function(t){this._yieldedPromise=null,this._promise._attachExtraTrace(t),this._promise._pushContext();var e=c(this._generator.throw).call(this._generator,t);this._promise._popContext(),this._continue(e)},d.prototype._resultCancelled=function(){if(this._yieldedPromise instanceof e){var t=this._yieldedPromise;this._yieldedPromise=null,t.cancel()}},d.prototype.promise=function(){return this._promise},d.prototype._run=function(){this._generator=this._generatorFunction.call(this._receiver),this._receiver=this._generatorFunction=void 0,this._promiseFulfilled(void 0)},d.prototype._continue=function(t){var r=this._promise;if(t===u)return this._cleanup(),this._cancellationPhase?r.cancel():r._rejectCallback(t.e,!1);var n=t.value;if(!0===t.done)return this._cleanup(),this._cancellationPhase?r.cancel():r._resolveCallback(n);var o=i(n,this._promise);if(o instanceof e||null!==(o=f(o,this._yieldHandlers,this._promise))){var s=(o=o._target())._bitField;50397184&s?33554432&s?e._async.invoke(this._promiseFulfilled,this,o._value()):16777216&s?e._async.invoke(this._promiseRejected,this,o._reason()):this._promiseCancelled():(this._yieldedPromise=o,o._proxy(this,null))}else this._promiseRejected(new a("A value %s was yielded that could not be treated as a promise\n\n See http://goo.gl/MqrFmX\n\n".replace("%s",n)+"From coroutine:\n"+this._stack.split("\n").slice(1,-7).join("\n")))},e.coroutine=function(t,e){if("function"!=typeof t)throw new a("generatorFunction must be a function\n\n See http://goo.gl/MqrFmX\n");var r=Object(e).yieldHandler,n=d,i=(new Error).stack;return function(){var e=t.apply(this,arguments),o=new n(void 0,void 0,r,i),s=o.promise();return o._generator=e,o._promiseFulfilled(void 0),s}},e.coroutine.addYieldHandler=function(t){if("function"!=typeof t)throw new a("expecting a function but got "+l.classString(t));h.push(t)},e.spawn=function(t){if(s.deprecated("Promise.spawn()","Promise.coroutine()"),"function"!=typeof t)return r("generatorFunction must be a function\n\n See http://goo.gl/MqrFmX\n");var n=new d(t,this),i=n.promise();return n._run(e.spawn),i}}},{"./errors":12,"./util":36}],17:[function(t,e,r){e.exports=function(e,r,n,i,o,s){var a=t("./util");a.canEvaluate,a.tryCatch,a.errorObj,e.join=function(){var t,e=arguments.length-1;e>0&&"function"==typeof arguments[e]&&(t=arguments[e]);var n=[].slice.call(arguments);t&&n.pop();var i=new r(n).promise();return void 0!==t?i.spread(t):i}}},{"./util":36}],18:[function(t,e,r){e.exports=function(e,r,n,i,o,s){var a=e._getDomain,l=t("./util"),u=l.tryCatch,c=l.errorObj,h=e._async;function f(t,e,r,n){this.constructor$(t),this._promise._captureStackTrace();var i=a();this._callback=null===i?e:l.domainBind(i,e),this._preservedValues=n===o?new Array(this.length()):null,this._limit=r,this._inFlight=0,this._queue=[],h.invoke(this._asyncInit,this,void 0)}function d(t,r,i,o){if("function"!=typeof r)return n("expecting a function but got "+l.classString(r));var s=0;if(void 0!==i){if("object"!=typeof i||null===i)return e.reject(new TypeError("options argument must be an object but it is "+l.classString(i)));if("number"!=typeof i.concurrency)return e.reject(new TypeError("'concurrency' must be a number but it is "+l.classString(i.concurrency)));s=i.concurrency}return new f(t,r,s="number"==typeof s&&isFinite(s)&&s>=1?s:0,o).promise()}l.inherits(f,r),f.prototype._asyncInit=function(){this._init$(void 0,-2)},f.prototype._init=function(){},f.prototype._promiseFulfilled=function(t,r){var n=this._values,o=this.length(),a=this._preservedValues,l=this._limit;if(r<0){if(n[r=-1*r-1]=t,l>=1&&(this._inFlight--,this._drainQueue(),this._isResolved()))return!0}else{if(l>=1&&this._inFlight>=l)return n[r]=t,this._queue.push(r),!1;null!==a&&(a[r]=t);var h=this._promise,f=this._callback,d=h._boundValue();h._pushContext();var p=u(f).call(d,t,r,o),y=h._popContext();if(s.checkForgottenReturns(p,y,null!==a?"Promise.filter":"Promise.map",h),p===c)return this._reject(p.e),!0;var g=i(p,this._promise);if(g instanceof e){var b=(g=g._target())._bitField;if(!(50397184&b))return l>=1&&this._inFlight++,n[r]=g,g._proxy(this,-1*(r+1)),!1;if(!(33554432&b))return 16777216&b?(this._reject(g._reason()),!0):(this._cancel(),!0);p=g._value()}n[r]=p}return++this._totalResolved>=o&&(null!==a?this._filter(n,a):this._resolve(n),!0)},f.prototype._drainQueue=function(){for(var t=this._queue,e=this._limit,r=this._values;t.length>0&&this._inFlight<e;){if(this._isResolved())return;var n=t.pop();this._promiseFulfilled(r[n],n)}},f.prototype._filter=function(t,e){for(var r=e.length,n=new Array(r),i=0,o=0;o<r;++o)t[o]&&(n[i++]=e[o]);n.length=i,this._resolve(n)},f.prototype.preservedValues=function(){return this._preservedValues},e.prototype.map=function(t,e){return d(this,t,e,null)},e.map=function(t,e,r,n){return d(t,e,r,n)}}},{"./util":36}],19:[function(t,e,r){e.exports=function(e,r,n,i,o){var s=t("./util"),a=s.tryCatch;e.method=function(t){if("function"!=typeof t)throw new e.TypeError("expecting a function but got "+s.classString(t));return function(){var n=new e(r);n._captureStackTrace(),n._pushContext();var i=a(t).apply(this,arguments),s=n._popContext();return o.checkForgottenReturns(i,s,"Promise.method",n),n._resolveFromSyncValue(i),n}},e.attempt=e.try=function(t){if("function"!=typeof t)return i("expecting a function but got "+s.classString(t));var n,l=new e(r);if(l._captureStackTrace(),l._pushContext(),arguments.length>1){o.deprecated("calling Promise.try with more than 1 argument");var u=arguments[1],c=arguments[2];n=s.isArray(u)?a(t).apply(c,u):a(t).call(c,u)}else n=a(t)();var h=l._popContext();return o.checkForgottenReturns(n,h,"Promise.try",l),l._resolveFromSyncValue(n),l},e.prototype._resolveFromSyncValue=function(t){t===s.errorObj?this._rejectCallback(t.e,!1):this._resolveCallback(t,!0)}}},{"./util":36}],20:[function(t,e,r){var n=t("./util"),i=n.maybeWrapAsError,o=t("./errors").OperationalError,s=t("./es5");function a(t){return t instanceof Error&&s.getPrototypeOf(t)===Error.prototype}var l=/^(?:name|message|stack|cause)$/;function u(t){var e;if(a(t)){(e=new o(t)).name=t.name,e.message=t.message,e.stack=t.stack;for(var r=s.keys(t),i=0;i<r.length;++i){var u=r[i];l.test(u)||(e[u]=t[u])}return e}return n.markAsOriginatingFromRejection(t),t}function c(t,e){return function(r,n){if(null!==t){if(r){var o=u(i(r));t._attachExtraTrace(o),t._reject(o)}else if(e){var s=[].slice.call(arguments,1);t._fulfill(s)}else t._fulfill(n);t=null}}}e.exports=c},{"./errors":12,"./es5":13,"./util":36}],21:[function(t,e,r){e.exports=function(e){var r=t("./util"),n=e._async,i=r.tryCatch,o=r.errorObj;function s(t,e){var s=this;if(!r.isArray(t))return a.call(s,t,e);var l=i(e).apply(s._boundValue(),[null].concat(t));l===o&&n.throwLater(l.e)}function a(t,e){var r=this._boundValue(),s=void 0===t?i(e).call(r,null):i(e).call(r,null,t);s===o&&n.throwLater(s.e)}function l(t,e){var r=this;if(!t){var s=new Error(t+"");s.cause=t,t=s}var a=i(e).call(r._boundValue(),t);a===o&&n.throwLater(a.e)}e.prototype.asCallback=e.prototype.nodeify=function(t,e){if("function"==typeof t){var r=a;void 0!==e&&Object(e).spread&&(r=s),this._then(r,l,void 0,this,t)}return this}}},{"./util":36}],22:[function(t,e,r){e.exports=function(){var r=function(){return new d("circular promise resolution chain\n\n See http://goo.gl/MqrFmX\n")},n=function(){return new O.PromiseInspection(this._target())},i=function(t){return O.reject(new d(t))};function o(){}var s,a={},l=t("./util");s=l.isNode?function(){var t=process.domain;return void 0===t&&(t=null),t}:function(){return null},l.notEnumerableProp(O,"_getDomain",s);var u=t("./es5"),c=t("./async"),h=new c;u.defineProperty(O,"_async",{value:h});var f=t("./errors"),d=O.TypeError=f.TypeError;O.RangeError=f.RangeError;var p=O.CancellationError=f.CancellationError;O.TimeoutError=f.TimeoutError,O.OperationalError=f.OperationalError,O.RejectionError=f.OperationalError,O.AggregateError=f.AggregateError;var y=function(){},g={},b={},m=t("./thenables")(O,y),_=t("./promise_array")(O,y,m,i,o),v=t("./context")(O),w=v.create,S=t("./debuggability")(O,v);S.CapturedTrace;var E=t("./finally")(O,m),R=t("./catch_filter")(b),k=t("./nodeback"),T=l.errorObj,x=l.tryCatch;function A(t,e){if("function"!=typeof e)throw new d("expecting a function but got "+l.classString(e));if(t.constructor!==O)throw new d("the promise constructor cannot be invoked directly\n\n See http://goo.gl/MqrFmX\n")}function O(t){this._bitField=0,this._fulfillmentHandler0=void 0,this._rejectionHandler0=void 0,this._promise0=void 0,this._receiver0=void 0,t!==y&&(A(this,t),this._resolveFromExecutor(t)),this._promiseCreated(),this._fireEvent("promiseCreated",this)}function L(t){this.promise._resolveCallback(t)}function j(t){this.promise._rejectCallback(t,!1)}function M(t){var e=new O(y);e._fulfillmentHandler0=t,e._rejectionHandler0=t,e._promise0=t,e._receiver0=t}return O.prototype.toString=function(){return"[object Promise]"},O.prototype.caught=O.prototype.catch=function(t){var e=arguments.length;if(e>1){var r,n=new Array(e-1),o=0;for(r=0;r<e-1;++r){var s=arguments[r];if(!l.isObject(s))return i("expecting an object but got A catch statement predicate "+l.classString(s));n[o++]=s}return n.length=o,t=arguments[r],this.then(void 0,R(n,t,this))}return this.then(void 0,t)},O.prototype.reflect=function(){return this._then(n,n,void 0,this,void 0)},O.prototype.then=function(t,e){if(S.warnings()&&arguments.length>0&&"function"!=typeof t&&"function"!=typeof e){var r=".then() only accepts functions but was passed: "+l.classString(t);arguments.length>1&&(r+=", "+l.classString(e)),this._warn(r)}return this._then(t,e,void 0,void 0,void 0)},O.prototype.done=function(t,e){this._then(t,e,void 0,void 0,void 0)._setIsFinal()},O.prototype.spread=function(t){return"function"!=typeof t?i("expecting a function but got "+l.classString(t)):this.all()._then(t,void 0,void 0,g,void 0)},O.prototype.toJSON=function(){var t={isFulfilled:!1,isRejected:!1,fulfillmentValue:void 0,rejectionReason:void 0};return this.isFulfilled()?(t.fulfillmentValue=this.value(),t.isFulfilled=!0):this.isRejected()&&(t.rejectionReason=this.reason(),t.isRejected=!0),t},O.prototype.all=function(){return arguments.length>0&&this._warn(".all() was passed arguments but it does not take any"),new _(this).promise()},O.prototype.error=function(t){return this.caught(l.originatesFromRejection,t)},O.getNewLibraryCopy=e.exports,O.is=function(t){return t instanceof O},O.fromNode=O.fromCallback=function(t){var e=new O(y);e._captureStackTrace();var r=arguments.length>1&&!!Object(arguments[1]).multiArgs,n=x(t)(k(e,r));return n===T&&e._rejectCallback(n.e,!0),e._isFateSealed()||e._setAsyncGuaranteed(),e},O.all=function(t){return new _(t).promise()},O.cast=function(t){var e=m(t);return e instanceof O||((e=new O(y))._captureStackTrace(),e._setFulfilled(),e._rejectionHandler0=t),e},O.resolve=O.fulfilled=O.cast,O.reject=O.rejected=function(t){var e=new O(y);return e._captureStackTrace(),e._rejectCallback(t,!0),e},O.setScheduler=function(t){if("function"!=typeof t)throw new d("expecting a function but got "+l.classString(t));return h.setScheduler(t)},O.prototype._then=function(t,e,r,n,i){var o=void 0!==i,a=o?i:new O(y),u=this._target(),c=u._bitField;o||(a._propagateFrom(this,3),a._captureStackTrace(),void 0===n&&2097152&this._bitField&&(n=50397184&c?this._boundValue():u===this?void 0:this._boundTo),this._fireEvent("promiseChained",this,a));var f=s();if(50397184&c){var d,g,b=u._settlePromiseCtx;33554432&c?(g=u._rejectionHandler0,d=t):16777216&c?(g=u._fulfillmentHandler0,d=e,u._unsetRejectionIsUnhandled()):(b=u._settlePromiseLateCancellationObserver,g=new p("late cancellation observer"),u._attachExtraTrace(g),d=e),h.invoke(b,u,{handler:null===f?d:"function"==typeof d&&l.domainBind(f,d),promise:a,receiver:n,value:g})}else u._addCallbacks(t,e,a,n,f);return a},O.prototype._length=function(){return 65535&this._bitField},O.prototype._isFateSealed=function(){return!!(117506048&this._bitField)},O.prototype._isFollowing=function(){return!(67108864&~this._bitField)},O.prototype._setLength=function(t){this._bitField=-65536&this._bitField|65535&t},O.prototype._setFulfilled=function(){this._bitField=33554432|this._bitField,this._fireEvent("promiseFulfilled",this)},O.prototype._setRejected=function(){this._bitField=16777216|this._bitField,this._fireEvent("promiseRejected",this)},O.prototype._setFollowing=function(){this._bitField=67108864|this._bitField,this._fireEvent("promiseResolved",this)},O.prototype._setIsFinal=function(){this._bitField=4194304|this._bitField},O.prototype._isFinal=function(){return(4194304&this._bitField)>0},O.prototype._unsetCancelled=function(){this._bitField=-65537&this._bitField},O.prototype._setCancelled=function(){this._bitField=65536|this._bitField,this._fireEvent("promiseCancelled",this)},O.prototype._setWillBeCancelled=function(){this._bitField=8388608|this._bitField},O.prototype._setAsyncGuaranteed=function(){h.hasCustomScheduler()||(this._bitField=134217728|this._bitField)},O.prototype._receiverAt=function(t){var e=0===t?this._receiver0:this[4*t-4+3];if(e!==a)return void 0===e&&this._isBound()?this._boundValue():e},O.prototype._promiseAt=function(t){return this[4*t-4+2]},O.prototype._fulfillmentHandlerAt=function(t){return this[4*t-4+0]},O.prototype._rejectionHandlerAt=function(t){return this[4*t-4+1]},O.prototype._boundValue=function(){},O.prototype._migrateCallback0=function(t){t._bitField;var e=t._fulfillmentHandler0,r=t._rejectionHandler0,n=t._promise0,i=t._receiverAt(0);void 0===i&&(i=a),this._addCallbacks(e,r,n,i,null)},O.prototype._migrateCallbackAt=function(t,e){var r=t._fulfillmentHandlerAt(e),n=t._rejectionHandlerAt(e),i=t._promiseAt(e),o=t._receiverAt(e);void 0===o&&(o=a),this._addCallbacks(r,n,i,o,null)},O.prototype._addCallbacks=function(t,e,r,n,i){var o=this._length();if(o>=65531&&(o=0,this._setLength(0)),0===o)this._promise0=r,this._receiver0=n,"function"==typeof t&&(this._fulfillmentHandler0=null===i?t:l.domainBind(i,t)),"function"==typeof e&&(this._rejectionHandler0=null===i?e:l.domainBind(i,e));else{var s=4*o-4;this[s+2]=r,this[s+3]=n,"function"==typeof t&&(this[s+0]=null===i?t:l.domainBind(i,t)),"function"==typeof e&&(this[s+1]=null===i?e:l.domainBind(i,e))}return this._setLength(o+1),o},O.prototype._proxy=function(t,e){this._addCallbacks(void 0,void 0,e,t,null)},O.prototype._resolveCallback=function(t,e){if(!(117506048&this._bitField)){if(t===this)return this._rejectCallback(r(),!1);var n=m(t,this);if(!(n instanceof O))return this._fulfill(t);e&&this._propagateFrom(n,2);var i=n._target();if(i!==this){var o=i._bitField;if(50397184&o)if(33554432&o)this._fulfill(i._value());else if(16777216&o)this._reject(i._reason());else{var s=new p("late cancellation observer");i._attachExtraTrace(s),this._reject(s)}else{var a=this._length();a>0&&i._migrateCallback0(this);for(var l=1;l<a;++l)i._migrateCallbackAt(this,l);this._setFollowing(),this._setLength(0),this._setFollowee(i)}}else this._reject(r())}},O.prototype._rejectCallback=function(t,e,r){var n=l.ensureErrorObject(t),i=n===t;if(!i&&!r&&S.warnings()){var o="a promise was rejected with a non-error: "+l.classString(t);this._warn(o,!0)}this._attachExtraTrace(n,!!e&&i),this._reject(t)},O.prototype._resolveFromExecutor=function(t){var e=this;this._captureStackTrace(),this._pushContext();var r=!0,n=this._execute(t,function(t){e._resolveCallback(t)},function(t){e._rejectCallback(t,r)});r=!1,this._popContext(),void 0!==n&&e._rejectCallback(n,!0)},O.prototype._settlePromiseFromHandler=function(t,e,r,n){var i=n._bitField;if(!(65536&i)){var o;n._pushContext(),e===g?r&&"number"==typeof r.length?o=x(t).apply(this._boundValue(),r):(o=T).e=new d("cannot .spread() a non-array: "+l.classString(r)):o=x(t).call(e,r);var s=n._popContext();65536&(i=n._bitField)||(o===b?n._reject(r):o===T?n._rejectCallback(o.e,!1):(S.checkForgottenReturns(o,s,"",n,this),n._resolveCallback(o)))}},O.prototype._target=function(){for(var t=this;t._isFollowing();)t=t._followee();return t},O.prototype._followee=function(){return this._rejectionHandler0},O.prototype._setFollowee=function(t){this._rejectionHandler0=t},O.prototype._settlePromise=function(t,e,r,i){var s=t instanceof O,a=this._bitField,l=!!(134217728&a);65536&a?(s&&t._invokeInternalOnCancel(),r instanceof E&&r.isFinallyHandler()?(r.cancelPromise=t,x(e).call(r,i)===T&&t._reject(T.e)):e===n?t._fulfill(n.call(r)):r instanceof o?r._promiseCancelled(t):s||t instanceof _?t._cancel():r.cancel()):"function"==typeof e?s?(l&&t._setAsyncGuaranteed(),this._settlePromiseFromHandler(e,r,i,t)):e.call(r,i,t):r instanceof o?r._isResolved()||(33554432&a?r._promiseFulfilled(i,t):r._promiseRejected(i,t)):s&&(l&&t._setAsyncGuaranteed(),33554432&a?t._fulfill(i):t._reject(i))},O.prototype._settlePromiseLateCancellationObserver=function(t){var e=t.handler,r=t.promise,n=t.receiver,i=t.value;"function"==typeof e?r instanceof O?this._settlePromiseFromHandler(e,n,i,r):e.call(n,i,r):r instanceof O&&r._reject(i)},O.prototype._settlePromiseCtx=function(t){this._settlePromise(t.promise,t.handler,t.receiver,t.value)},O.prototype._settlePromise0=function(t,e,r){var n=this._promise0,i=this._receiverAt(0);this._promise0=void 0,this._receiver0=void 0,this._settlePromise(n,t,i,e)},O.prototype._clearCallbackDataAtIndex=function(t){var e=4*t-4;this[e+2]=this[e+3]=this[e+0]=this[e+1]=void 0},O.prototype._fulfill=function(t){var e=this._bitField;if(!((117506048&e)>>>16)){if(t===this){var n=r();return this._attachExtraTrace(n),this._reject(n)}this._setFulfilled(),this._rejectionHandler0=t,(65535&e)>0&&(134217728&e?this._settlePromises():h.settlePromises(this))}},O.prototype._reject=function(t){var e=this._bitField;if(!((117506048&e)>>>16)){if(this._setRejected(),this._fulfillmentHandler0=t,this._isFinal())return h.fatalError(t,l.isNode);(65535&e)>0?h.settlePromises(this):this._ensurePossibleRejectionHandled()}},O.prototype._fulfillPromises=function(t,e){for(var r=1;r<t;r++){var n=this._fulfillmentHandlerAt(r),i=this._promiseAt(r),o=this._receiverAt(r);this._clearCallbackDataAtIndex(r),this._settlePromise(i,n,o,e)}},O.prototype._rejectPromises=function(t,e){for(var r=1;r<t;r++){var n=this._rejectionHandlerAt(r),i=this._promiseAt(r),o=this._receiverAt(r);this._clearCallbackDataAtIndex(r),this._settlePromise(i,n,o,e)}},O.prototype._settlePromises=function(){var t=this._bitField,e=65535&t;if(e>0){if(16842752&t){var r=this._fulfillmentHandler0;this._settlePromise0(this._rejectionHandler0,r,t),this._rejectPromises(e,r)}else{var n=this._rejectionHandler0;this._settlePromise0(this._fulfillmentHandler0,n,t),this._fulfillPromises(e,n)}this._setLength(0)}this._clearCancellationData()},O.prototype._settledValue=function(){var t=this._bitField;return 33554432&t?this._rejectionHandler0:16777216&t?this._fulfillmentHandler0:void 0},O.defer=O.pending=function(){return S.deprecated("Promise.defer","new Promise"),{promise:new O(y),resolve:L,reject:j}},l.notEnumerableProp(O,"_makeSelfResolutionError",r),t("./method")(O,y,m,i,S),t("./bind")(O,y,m,S),t("./cancel")(O,_,i,S),t("./direct_resolve")(O),t("./synchronous_inspection")(O),t("./join")(O,_,m,y,h,s),O.Promise=O,O.version="3.4.7",t("./map.js")(O,_,i,m,y,S),t("./call_get.js")(O),t("./using.js")(O,i,m,w,y,S),t("./timers.js")(O,y,S),t("./generators.js")(O,i,y,m,o,S),t("./nodeify.js")(O),t("./promisify.js")(O,y),t("./props.js")(O,_,m,i),t("./race.js")(O,y,m,i),t("./reduce.js")(O,_,i,m,y,S),t("./settle.js")(O,_,S),t("./some.js")(O,_,i),t("./filter.js")(O,y),t("./each.js")(O,y),t("./any.js")(O),l.toFastProperties(O),l.toFastProperties(O.prototype),M({a:1}),M({b:2}),M({c:3}),M(1),M(function(){}),M(void 0),M(!1),M(new O(y)),S.setBounds(c.firstLineError,l.lastLineError),O}},{"./any.js":1,"./async":2,"./bind":3,"./call_get.js":5,"./cancel":6,"./catch_filter":7,"./context":8,"./debuggability":9,"./direct_resolve":10,"./each.js":11,"./errors":12,"./es5":13,"./filter.js":14,"./finally":15,"./generators.js":16,"./join":17,"./map.js":18,"./method":19,"./nodeback":20,"./nodeify.js":21,"./promise_array":23,"./promisify.js":24,"./props.js":25,"./race.js":27,"./reduce.js":28,"./settle.js":30,"./some.js":31,"./synchronous_inspection":32,"./thenables":33,"./timers.js":34,"./using.js":35,"./util":36}],23:[function(t,e,r){e.exports=function(e,r,n,i,o){var s=t("./util");function a(t){switch(t){case-2:return[];case-3:return{}}}function l(t){var n=this._promise=new e(r);t instanceof e&&n._propagateFrom(t,3),n._setOnCancel(this),this._values=t,this._length=0,this._totalResolved=0,this._init(void 0,-2)}return s.isArray,s.inherits(l,o),l.prototype.length=function(){return this._length},l.prototype.promise=function(){return this._promise},l.prototype._init=function t(r,o){var l=n(this._values,this._promise);if(l instanceof e){var u=(l=l._target())._bitField;if(this._values=l,!(50397184&u))return this._promise._setAsyncGuaranteed(),l._then(t,this._reject,void 0,this,o);if(!(33554432&u))return 16777216&u?this._reject(l._reason()):this._cancel();l=l._value()}if(null!==(l=s.asArray(l)))0!==l.length?this._iterate(l):-5===o?this._resolveEmptyArray():this._resolve(a(o));else{var c=i("expecting an array or an iterable object but got "+s.classString(l)).reason();this._promise._rejectCallback(c,!1)}},l.prototype._iterate=function(t){var r=this.getActualLength(t.length);this._length=r,this._values=this.shouldCopyValues()?new Array(r):this._values;for(var i=this._promise,o=!1,s=null,a=0;a<r;++a){var l=n(t[a],i);s=l instanceof e?(l=l._target())._bitField:null,o?null!==s&&l.suppressUnhandledRejections():null!==s?50397184&s?o=33554432&s?this._promiseFulfilled(l._value(),a):16777216&s?this._promiseRejected(l._reason(),a):this._promiseCancelled(a):(l._proxy(this,a),this._values[a]=l):o=this._promiseFulfilled(l,a)}o||i._setAsyncGuaranteed()},l.prototype._isResolved=function(){return null===this._values},l.prototype._resolve=function(t){this._values=null,this._promise._fulfill(t)},l.prototype._cancel=function(){!this._isResolved()&&this._promise._isCancellable()&&(this._values=null,this._promise._cancel())},l.prototype._reject=function(t){this._values=null,this._promise._rejectCallback(t,!1)},l.prototype._promiseFulfilled=function(t,e){return this._values[e]=t,++this._totalResolved>=this._length&&(this._resolve(this._values),!0)},l.prototype._promiseCancelled=function(){return this._cancel(),!0},l.prototype._promiseRejected=function(t){return this._totalResolved++,this._reject(t),!0},l.prototype._resultCancelled=function(){if(!this._isResolved()){var t=this._values;if(this._cancel(),t instanceof e)t.cancel();else for(var r=0;r<t.length;++r)t[r]instanceof e&&t[r].cancel()}},l.prototype.shouldCopyValues=function(){return!0},l.prototype.getActualLength=function(t){return t},l}},{"./util":36}],24:[function(t,e,r){e.exports=function(e,r){var n={},i=t("./util"),o=t("./nodeback"),s=i.withAppended,a=i.maybeWrapAsError,l=i.canEvaluate,u=t("./errors").TypeError,c="Async",h={__isPromisified__:!0},f=new RegExp("^(?:"+["arity","length","name","arguments","caller","callee","prototype","__isPromisified__"].join("|")+")$"),d=function(t){return i.isIdentifier(t)&&"_"!==t.charAt(0)&&"constructor"!==t};function p(t){return!f.test(t)}function y(t){try{return!0===t.__isPromisified__}catch(t){return!1}}function g(t,e,r){var n=i.getDataPropertyOrDefault(t,e+r,h);return!!n&&y(n)}function b(t,e,r){for(var n=0;n<t.length;n+=2){var i=t[n];if(r.test(i))for(var o=i.replace(r,""),s=0;s<t.length;s+=2)if(t[s]===o)throw new u("Cannot promisify an API that has normal methods with '%s'-suffix\n\n See http://goo.gl/MqrFmX\n".replace("%s",e))}}function m(t,e,r,n){for(var o=i.inheritedDataKeys(t),s=[],a=0;a<o.length;++a){var l=o[a],u=t[l],c=n===d||d(l);"function"!=typeof u||y(u)||g(t,l,e)||!n(l,u,t,c)||s.push(l,u)}return b(s,e,r),s}var _,v=function(t){return t.replace(/([$])/,"\\$")};function w(t,l,u,c,h,f){var d=function(){return this}(),p=t;function y(){var i=l;l===n&&(i=this);var u=new e(r);u._captureStackTrace();var c="string"==typeof p&&this!==d?this[p]:t,h=o(u,f);try{c.apply(i,s(arguments,h))}catch(t){u._rejectCallback(a(t),!0,!0)}return u._isFateSealed()||u._setAsyncGuaranteed(),u}return"string"==typeof p&&(t=c),i.notEnumerableProp(y,"__isPromisified__",!0),y}var S=l?_:w;function E(t,e,r,o,s){for(var a=new RegExp(v(e)+"$"),l=m(t,e,a,r),u=0,c=l.length;u<c;u+=2){var h=l[u],f=l[u+1],d=h+e;if(o===S)t[d]=S(h,n,h,f,e,s);else{var p=o(f,function(){return S(h,n,h,f,e,s)});i.notEnumerableProp(p,"__isPromisified__",!0),t[d]=p}}return i.toFastProperties(t),t}function R(t,e,r){return S(t,e,void 0,t,null,r)}e.promisify=function(t,e){if("function"!=typeof t)throw new u("expecting a function but got "+i.classString(t));if(y(t))return t;var r=R(t,void 0===(e=Object(e)).context?n:e.context,!!e.multiArgs);return i.copyDescriptors(t,r,p),r},e.promisifyAll=function(t,e){if("function"!=typeof t&&"object"!=typeof t)throw new u("the target of promisifyAll must be an object or a function\n\n See http://goo.gl/MqrFmX\n");var r=!!(e=Object(e)).multiArgs,n=e.suffix;"string"!=typeof n&&(n=c);var o=e.filter;"function"!=typeof o&&(o=d);var s=e.promisifier;if("function"!=typeof s&&(s=S),!i.isIdentifier(n))throw new RangeError("suffix must be a valid identifier\n\n See http://goo.gl/MqrFmX\n");for(var a=i.inheritedDataKeys(t),l=0;l<a.length;++l){var h=t[a[l]];"constructor"!==a[l]&&i.isClass(h)&&(E(h.prototype,n,o,s,r),E(h,n,o,s,r))}return E(t,n,o,s,r)}}},{"./errors":12,"./nodeback":20,"./util":36}],25:[function(t,e,r){e.exports=function(e,r,n,i){var o,s=t("./util"),a=s.isObject,l=t("./es5");"function"==typeof Map&&(o=Map);var u=function(){var t=0,e=0;function r(r,n){this[t]=r,this[t+e]=n,t++}return function(n){e=n.size,t=0;var i=new Array(2*n.size);return n.forEach(r,i),i}}(),c=function(t){for(var e=new o,r=t.length/2|0,n=0;n<r;++n){var i=t[r+n],s=t[n];e.set(i,s)}return e};function h(t){var e,r=!1;if(void 0!==o&&t instanceof o)e=u(t),r=!0;else{var n=l.keys(t),i=n.length;e=new Array(2*i);for(var s=0;s<i;++s){var a=n[s];e[s]=t[a],e[s+i]=a}}this.constructor$(e),this._isMap=r,this._init$(void 0,-3)}function f(t){var r,o=n(t);return a(o)?(r=o instanceof e?o._then(e.props,void 0,void 0,void 0,void 0):new h(o).promise(),o instanceof e&&r._propagateFrom(o,2),r):i("cannot await properties of a non-object\n\n See http://goo.gl/MqrFmX\n")}s.inherits(h,r),h.prototype._init=function(){},h.prototype._promiseFulfilled=function(t,e){if(this._values[e]=t,++this._totalResolved>=this._length){var r;if(this._isMap)r=c(this._values);else{r={};for(var n=this.length(),i=0,o=this.length();i<o;++i)r[this._values[i+n]]=this._values[i]}return this._resolve(r),!0}return!1},h.prototype.shouldCopyValues=function(){return!1},h.prototype.getActualLength=function(t){return t>>1},e.prototype.props=function(){return f(this)},e.props=function(t){return f(t)}}},{"./es5":13,"./util":36}],26:[function(t,e,r){function n(t,e,r,n,i){for(var o=0;o<i;++o)r[o+n]=t[o+e],t[o+e]=void 0}function i(t){this._capacity=t,this._length=0,this._front=0}i.prototype._willBeOverCapacity=function(t){return this._capacity<t},i.prototype._pushOne=function(t){var e=this.length();this._checkCapacity(e+1),this[this._front+e&this._capacity-1]=t,this._length=e+1},i.prototype.push=function(t,e,r){var n=this.length()+3;if(this._willBeOverCapacity(n))return this._pushOne(t),this._pushOne(e),void this._pushOne(r);var i=this._front+n-3;this._checkCapacity(n);var o=this._capacity-1;this[i+0&o]=t,this[i+1&o]=e,this[i+2&o]=r,this._length=n},i.prototype.shift=function(){var t=this._front,e=this[t];return this[t]=void 0,this._front=t+1&this._capacity-1,this._length--,e},i.prototype.length=function(){return this._length},i.prototype._checkCapacity=function(t){this._capacity<t&&this._resizeTo(this._capacity<<1)},i.prototype._resizeTo=function(t){var e=this._capacity;this._capacity=t,n(this,0,this,e,this._front+this._length&e-1)},e.exports=i},{}],27:[function(t,e,r){e.exports=function(e,r,n,i){var o=t("./util"),s=function(t){return t.then(function(e){return a(e,t)})};function a(t,a){var l=n(t);if(l instanceof e)return s(l);if(null===(t=o.asArray(t)))return i("expecting an array or an iterable object but got "+o.classString(t));var u=new e(r);void 0!==a&&u._propagateFrom(a,3);for(var c=u._fulfill,h=u._reject,f=0,d=t.length;f<d;++f){var p=t[f];(void 0!==p||f in t)&&e.cast(p)._then(c,h,void 0,u,null)}return u}e.race=function(t){return a(t,void 0)},e.prototype.race=function(){return a(this,void 0)}}},{"./util":36}],28:[function(t,e,r){e.exports=function(e,r,n,i,o,s){var a=e._getDomain,l=t("./util"),u=l.tryCatch;function c(t,r,n,i){this.constructor$(t);var s=a();this._fn=null===s?r:l.domainBind(s,r),void 0!==n&&(n=e.resolve(n))._attachCancellationCallback(this),this._initialValue=n,this._currentCancellable=null,this._eachValues=i===o?Array(this._length):0===i?null:void 0,this._promise._captureStackTrace(),this._init$(void 0,-5)}function h(t,e){this.isFulfilled()?e._resolve(t):e._reject(t)}function f(t,e,r,i){return"function"!=typeof e?n("expecting a function but got "+l.classString(e)):new c(t,e,r,i).promise()}function d(t){this.accum=t,this.array._gotAccum(t);var r=i(this.value,this.array._promise);return r instanceof e?(this.array._currentCancellable=r,r._then(p,void 0,void 0,this,void 0)):p.call(this,r)}function p(t){var r,n=this.array,i=n._promise,o=u(n._fn);i._pushContext(),(r=void 0!==n._eachValues?o.call(i._boundValue(),t,this.index,this.length):o.call(i._boundValue(),this.accum,t,this.index,this.length))instanceof e&&(n._currentCancellable=r);var a=i._popContext();return s.checkForgottenReturns(r,a,void 0!==n._eachValues?"Promise.each":"Promise.reduce",i),r}l.inherits(c,r),c.prototype._gotAccum=function(t){void 0!==this._eachValues&&null!==this._eachValues&&t!==o&&this._eachValues.push(t)},c.prototype._eachComplete=function(t){return null!==this._eachValues&&this._eachValues.push(t),this._eachValues},c.prototype._init=function(){},c.prototype._resolveEmptyArray=function(){this._resolve(void 0!==this._eachValues?this._eachValues:this._initialValue)},c.prototype.shouldCopyValues=function(){return!1},c.prototype._resolve=function(t){this._promise._resolveCallback(t),this._values=null},c.prototype._resultCancelled=function(t){if(t===this._initialValue)return this._cancel();this._isResolved()||(this._resultCancelled$(),this._currentCancellable instanceof e&&this._currentCancellable.cancel(),this._initialValue instanceof e&&this._initialValue.cancel())},c.prototype._iterate=function(t){var r,n;this._values=t;var i=t.length;if(void 0!==this._initialValue?(r=this._initialValue,n=0):(r=e.resolve(t[0]),n=1),this._currentCancellable=r,!r.isRejected())for(;n<i;++n){var o={accum:null,value:t[n],index:n,length:i,array:this};r=r._then(d,void 0,void 0,o,void 0)}void 0!==this._eachValues&&(r=r._then(this._eachComplete,void 0,void 0,this,void 0)),r._then(h,h,void 0,r,this)},e.prototype.reduce=function(t,e){return f(this,t,e,null)},e.reduce=function(t,e,r,n){return f(t,e,r,n)}}},{"./util":36}],29:[function(t,e,r){var n,i=t("./util"),o=function(){throw new Error("No async scheduler available\n\n See http://goo.gl/MqrFmX\n")},s=i.getNativePromise();if(i.isNode&&"undefined"==typeof MutationObserver){var a=Ft.setImmediate,l=process.nextTick;n=i.isRecentNode?function(t){a.call(Ft,t)}:function(t){l.call(process,t)}}else if("function"==typeof s&&"function"==typeof s.resolve){var u=s.resolve();n=function(t){u.then(t)}}else n="undefined"==typeof MutationObserver||"undefined"!=typeof window&&window.navigator&&(window.navigator.standalone||window.cordova)?"undefined"!=typeof setImmediate?function(t){setImmediate(t)}:"undefined"!=typeof setTimeout?function(t){setTimeout(t,0)}:o:function(){var t=document.createElement("div"),e={attributes:!0},r=!1,n=document.createElement("div");new MutationObserver(function(){t.classList.toggle("foo"),r=!1}).observe(n,e);var i=function(){r||(r=!0,n.classList.toggle("foo"))};return function(r){var n=new MutationObserver(function(){n.disconnect(),r()});n.observe(t,e),i()}}();e.exports=n},{"./util":36}],30:[function(t,e,r){e.exports=function(e,r,n){var i=e.PromiseInspection;function o(t){this.constructor$(t)}t("./util").inherits(o,r),o.prototype._promiseResolved=function(t,e){return this._values[t]=e,++this._totalResolved>=this._length&&(this._resolve(this._values),!0)},o.prototype._promiseFulfilled=function(t,e){var r=new i;return r._bitField=33554432,r._settledValueField=t,this._promiseResolved(e,r)},o.prototype._promiseRejected=function(t,e){var r=new i;return r._bitField=16777216,r._settledValueField=t,this._promiseResolved(e,r)},e.settle=function(t){return n.deprecated(".settle()",".reflect()"),new o(t).promise()},e.prototype.settle=function(){return e.settle(this)}}},{"./util":36}],31:[function(t,e,r){e.exports=function(e,r,n){var i=t("./util"),o=t("./errors").RangeError,s=t("./errors").AggregateError,a=i.isArray,l={};function u(t){this.constructor$(t),this._howMany=0,this._unwrap=!1,this._initialized=!1}function c(t,e){if((0|e)!==e||e<0)return n("expecting a positive integer\n\n See http://goo.gl/MqrFmX\n");var r=new u(t),i=r.promise();return r.setHowMany(e),r.init(),i}i.inherits(u,r),u.prototype._init=function(){if(this._initialized)if(0!==this._howMany){this._init$(void 0,-5);var t=a(this._values);!this._isResolved()&&t&&this._howMany>this._canPossiblyFulfill()&&this._reject(this._getRangeError(this.length()))}else this._resolve([])},u.prototype.init=function(){this._initialized=!0,this._init()},u.prototype.setUnwrap=function(){this._unwrap=!0},u.prototype.howMany=function(){return this._howMany},u.prototype.setHowMany=function(t){this._howMany=t},u.prototype._promiseFulfilled=function(t){return this._addFulfilled(t),this._fulfilled()===this.howMany()&&(this._values.length=this.howMany(),1===this.howMany()&&this._unwrap?this._resolve(this._values[0]):this._resolve(this._values),!0)},u.prototype._promiseRejected=function(t){return this._addRejected(t),this._checkOutcome()},u.prototype._promiseCancelled=function(){return this._values instanceof e||null==this._values?this._cancel():(this._addRejected(l),this._checkOutcome())},u.prototype._checkOutcome=function(){if(this.howMany()>this._canPossiblyFulfill()){for(var t=new s,e=this.length();e<this._values.length;++e)this._values[e]!==l&&t.push(this._values[e]);return t.length>0?this._reject(t):this._cancel(),!0}return!1},u.prototype._fulfilled=function(){return this._totalResolved},u.prototype._rejected=function(){return this._values.length-this.length()},u.prototype._addRejected=function(t){this._values.push(t)},u.prototype._addFulfilled=function(t){this._values[this._totalResolved++]=t},u.prototype._canPossiblyFulfill=function(){return this.length()-this._rejected()},u.prototype._getRangeError=function(t){var e="Input array must contain at least "+this._howMany+" items but contains only "+t+" items";return new o(e)},u.prototype._resolveEmptyArray=function(){this._reject(this._getRangeError(0))},e.some=function(t,e){return c(t,e)},e.prototype.some=function(t){return c(this,t)},e._SomePromiseArray=u}},{"./errors":12,"./util":36}],32:[function(t,e,r){e.exports=function(t){function e(t){void 0!==t?(t=t._target(),this._bitField=t._bitField,this._settledValueField=t._isFateSealed()?t._settledValue():void 0):(this._bitField=0,this._settledValueField=void 0)}e.prototype._settledValue=function(){return this._settledValueField};var r=e.prototype.value=function(){if(!this.isFulfilled())throw new TypeError("cannot get fulfillment value of a non-fulfilled promise\n\n See http://goo.gl/MqrFmX\n");return this._settledValue()},n=e.prototype.error=e.prototype.reason=function(){if(!this.isRejected())throw new TypeError("cannot get rejection reason of a non-rejected promise\n\n See http://goo.gl/MqrFmX\n");return this._settledValue()},i=e.prototype.isFulfilled=function(){return!!(33554432&this._bitField)},o=e.prototype.isRejected=function(){return!!(16777216&this._bitField)},s=e.prototype.isPending=function(){return!(50397184&this._bitField)},a=e.prototype.isResolved=function(){return!!(50331648&this._bitField)};e.prototype.isCancelled=function(){return!!(8454144&this._bitField)},t.prototype.__isCancelled=function(){return!(65536&~this._bitField)},t.prototype._isCancelled=function(){return this._target().__isCancelled()},t.prototype.isCancelled=function(){return!!(8454144&this._target()._bitField)},t.prototype.isPending=function(){return s.call(this._target())},t.prototype.isRejected=function(){return o.call(this._target())},t.prototype.isFulfilled=function(){return i.call(this._target())},t.prototype.isResolved=function(){return a.call(this._target())},t.prototype.value=function(){return r.call(this._target())},t.prototype.reason=function(){var t=this._target();return t._unsetRejectionIsUnhandled(),n.call(t)},t.prototype._value=function(){return this._settledValue()},t.prototype._reason=function(){return this._unsetRejectionIsUnhandled(),this._settledValue()},t.PromiseInspection=e}},{}],33:[function(t,e,r){e.exports=function(e,r){var n=t("./util"),i=n.errorObj,o=n.isObject;function s(t,n){if(o(t)){if(t instanceof e)return t;var s=l(t);if(s===i){n&&n._pushContext();var a=e.reject(s.e);return n&&n._popContext(),a}if("function"==typeof s)return c(t)?(a=new e(r),t._then(a._fulfill,a._reject,void 0,a,null),a):h(t,s,n)}return t}function a(t){return t.then}function l(t){try{return a(t)}catch(t){return i.e=t,i}}var u={}.hasOwnProperty;function c(t){try{return u.call(t,"_promise0")}catch(t){return!1}}function h(t,o,s){var a=new e(r),l=a;s&&s._pushContext(),a._captureStackTrace(),s&&s._popContext();var u=!0,c=n.tryCatch(o).call(t,h,f);function h(t){a&&(a._resolveCallback(t),a=null)}function f(t){a&&(a._rejectCallback(t,u,!0),a=null)}return u=!1,a&&c===i&&(a._rejectCallback(c.e,!0,!0),a=null),l}return s}},{"./util":36}],34:[function(t,e,r){e.exports=function(e,r,n){var i=t("./util"),o=e.TimeoutError;function s(t){this.handle=t}s.prototype._resultCancelled=function(){clearTimeout(this.handle)};var a=function(t){return l(+this).thenReturn(t)},l=e.delay=function(t,i){var o,l;return void 0!==i?(o=e.resolve(i)._then(a,null,null,t,void 0),n.cancellation()&&i instanceof e&&o._setOnCancel(i)):(o=new e(r),l=setTimeout(function(){o._fulfill()},+t),n.cancellation()&&o._setOnCancel(new s(l)),o._captureStackTrace()),o._setAsyncGuaranteed(),o};e.prototype.delay=function(t){return l(t,this)};var u=function(t,e,r){var n;n="string"!=typeof e?e instanceof Error?e:new o("operation timed out"):new o(e),i.markAsOriginatingFromRejection(n),t._attachExtraTrace(n),t._reject(n),null!=r&&r.cancel()};function c(t){return clearTimeout(this.handle),t}function h(t){throw clearTimeout(this.handle),t}e.prototype.timeout=function(t,e){var r,i;t=+t;var o=new s(setTimeout(function(){r.isPending()&&u(r,e,i)},t));return n.cancellation()?(i=this.then(),(r=i._then(c,h,void 0,o,void 0))._setOnCancel(o)):r=this._then(c,h,void 0,o,void 0),r}}},{"./util":36}],35:[function(t,e,r){e.exports=function(e,r,n,i,o,s){var a=t("./util"),l=t("./errors").TypeError,u=t("./util").inherits,c=a.errorObj,h=a.tryCatch,f={};function d(t){setTimeout(function(){throw t},0)}function p(t){var e=n(t);return e!==t&&"function"==typeof t._isDisposable&&"function"==typeof t._getDisposer&&t._isDisposable()&&e._setDisposable(t._getDisposer()),e}function y(t,r){var i=0,s=t.length,a=new e(o);function l(){if(i>=s)return a._fulfill();var o=p(t[i++]);if(o instanceof e&&o._isDisposable()){try{o=n(o._getDisposer().tryDispose(r),t.promise)}catch(t){return d(t)}if(o instanceof e)return o._then(l,d,null,null,null)}l()}return l(),a}function g(t,e,r){this._data=t,this._promise=e,this._context=r}function b(t,e,r){this.constructor$(t,e,r)}function m(t){return g.isDisposer(t)?(this.resources[this.index]._setDisposable(t),t.promise()):t}function _(t){this.length=t,this.promise=null,this[t-1]=null}g.prototype.data=function(){return this._data},g.prototype.promise=function(){return this._promise},g.prototype.resource=function(){return this.promise().isFulfilled()?this.promise().value():f},g.prototype.tryDispose=function(t){var e=this.resource(),r=this._context;void 0!==r&&r._pushContext();var n=e!==f?this.doDispose(e,t):null;return void 0!==r&&r._popContext(),this._promise._unsetDisposable(),this._data=null,n},g.isDisposer=function(t){return null!=t&&"function"==typeof t.resource&&"function"==typeof t.tryDispose},u(b,g),b.prototype.doDispose=function(t,e){return this.data().call(t,t,e)},_.prototype._resultCancelled=function(){for(var t=this.length,r=0;r<t;++r){var n=this[r];n instanceof e&&n.cancel()}},e.using=function(){var t=arguments.length;if(t<2)return r("you must pass at least 2 arguments to Promise.using");var i,o=arguments[t-1];if("function"!=typeof o)return r("expecting a function but got "+a.classString(o));var l=!0;2===t&&Array.isArray(arguments[0])?(t=(i=arguments[0]).length,l=!1):(i=arguments,t--);for(var u=new _(t),f=0;f<t;++f){var d=i[f];if(g.isDisposer(d)){var p=d;(d=d.promise())._setDisposable(p)}else{var b=n(d);b instanceof e&&(d=b._then(m,null,null,{resources:u,index:f},void 0))}u[f]=d}var v=new Array(u.length);for(f=0;f<v.length;++f)v[f]=e.resolve(u[f]).reflect();var w=e.all(v).then(function(t){for(var e=0;e<t.length;++e){var r=t[e];if(r.isRejected())return c.e=r.error(),c;if(!r.isFulfilled())return void w.cancel();t[e]=r.value()}S._pushContext(),o=h(o);var n=l?o.apply(void 0,t):o(t),i=S._popContext();return s.checkForgottenReturns(n,i,"Promise.using",S),n}),S=w.lastly(function(){var t=new e.PromiseInspection(w);return y(u,t)});return u.promise=S,S._setOnCancel(u),S},e.prototype._setDisposable=function(t){this._bitField=131072|this._bitField,this._disposer=t},e.prototype._isDisposable=function(){return(131072&this._bitField)>0},e.prototype._getDisposer=function(){return this._disposer},e.prototype._unsetDisposable=function(){this._bitField=-131073&this._bitField,this._disposer=void 0},e.prototype.disposer=function(t){if("function"==typeof t)return new b(t,this,i());throw new l}}},{"./errors":12,"./util":36}],36:[function(t,e,r){var n,i=t("./es5"),o="undefined"==typeof navigator,s={e:{}},a="undefined"!=typeof self?self:"undefined"!=typeof window?window:void 0!==Ft?Ft:void 0!==this?this:null;function l(){try{var t=n;return n=null,t.apply(this,arguments)}catch(t){return s.e=t,s}}function u(t){return n=t,l}var c=function(t,e){var r={}.hasOwnProperty;function n(){for(var n in this.constructor=t,this.constructor$=e,e.prototype)r.call(e.prototype,n)&&"$"!==n.charAt(n.length-1)&&(this[n+"$"]=e.prototype[n])}return n.prototype=e.prototype,t.prototype=new n,t.prototype};function h(t){return null==t||!0===t||!1===t||"string"==typeof t||"number"==typeof t}function f(t){return"function"==typeof t||"object"==typeof t&&null!==t}function d(t){return h(t)?new Error(k(t)):t}function p(t,e){var r,n=t.length,i=new Array(n+1);for(r=0;r<n;++r)i[r]=t[r];return i[r]=e,i}function y(t,e,r){if(!i.isES5)return{}.hasOwnProperty.call(t,e)?t[e]:void 0;var n=Object.getOwnPropertyDescriptor(t,e);return null!=n?null==n.get&&null==n.set?n.value:r:void 0}function g(t,e,r){if(h(t))return t;var n={value:r,configurable:!0,enumerable:!1,writable:!0};return i.defineProperty(t,e,n),t}function b(t){throw t}var m=function(){var t=[Array.prototype,Object.prototype,Function.prototype],e=function(e){for(var r=0;r<t.length;++r)if(t[r]===e)return!0;return!1};if(i.isES5){var r=Object.getOwnPropertyNames;return function(t){for(var n=[],o=Object.create(null);null!=t&&!e(t);){var s;try{s=r(t)}catch(t){return n}for(var a=0;a<s.length;++a){var l=s[a];if(!o[l]){o[l]=!0;var u=Object.getOwnPropertyDescriptor(t,l);null!=u&&null==u.get&&null==u.set&&n.push(l)}}t=i.getPrototypeOf(t)}return n}}var n={}.hasOwnProperty;return function(r){if(e(r))return[];var i=[];t:for(var o in r)if(n.call(r,o))i.push(o);else{for(var s=0;s<t.length;++s)if(n.call(t[s],o))continue t;i.push(o)}return i}}(),_=/this\s*\.\s*\S+\s*=/;function v(t){try{if("function"==typeof t){var e=i.names(t.prototype),r=i.isES5&&e.length>1,n=e.length>0&&!(1===e.length&&"constructor"===e[0]),o=_.test(t+"")&&i.names(t).length>0;if(r||n||o)return!0}return!1}catch(t){return!1}}function w(t){return t}var S=/^[a-z$_][a-z$_0-9]*$/i;function E(t){return S.test(t)}function R(t,e,r){for(var n=new Array(t),i=0;i<t;++i)n[i]=e+i+r;return n}function k(t){try{return t+""}catch(t){return"[no string representation]"}}function T(t){return null!==t&&"object"==typeof t&&"string"==typeof t.message&&"string"==typeof t.name}function x(t){try{g(t,"isOperational",!0)}catch(t){}}function A(t){return null!=t&&(t instanceof Error.__BluebirdErrorTypes__.OperationalError||!0===t.isOperational)}function O(t){return T(t)&&i.propertyIsWritable(t,"stack")}var L="stack"in new Error?function(t){return O(t)?t:new Error(k(t))}:function(t){if(O(t))return t;try{throw new Error(k(t))}catch(t){return t}};function j(t){return{}.toString.call(t)}function M(t,e,r){for(var n=i.names(t),o=0;o<n.length;++o){var s=n[o];if(r(s))try{i.defineProperty(e,s,i.getDescriptor(t,s))}catch(t){}}}var I=function(t){return i.isArray(t)?t:null};if("undefined"!=typeof Symbol&&Symbol.iterator){var P="function"==typeof Array.from?function(t){return Array.from(t)}:function(t){for(var e,r=[],n=t[Symbol.iterator]();!(e=n.next()).done;)r.push(e.value);return r};I=function(t){return i.isArray(t)?t:null!=t&&"function"==typeof t[Symbol.iterator]?P(t):null}}var D="undefined"!=typeof process&&"[object process]"===j(process).toLowerCase(),C="undefined"!=typeof process&&void 0!==process.env;function N(t){return C?process.env[t]:void 0}function F(){if("function"==typeof Promise)try{var t=new Promise(function(){});if("[object Promise]"==={}.toString.call(t))return Promise}catch(t){}}function B(t,e){return t.bind(e)}var W,U={isClass:v,isIdentifier:E,inheritedDataKeys:m,getDataPropertyOrDefault:y,thrower:b,isArray:i.isArray,asArray:I,notEnumerableProp:g,isPrimitive:h,isObject:f,isError:T,canEvaluate:o,errorObj:s,tryCatch:u,inherits:c,withAppended:p,maybeWrapAsError:d,toFastProperties:w,filledRange:R,toString:k,canAttachTrace:O,ensureErrorObject:L,originatesFromRejection:A,markAsOriginatingFromRejection:x,classString:j,copyDescriptors:M,hasDevTools:"undefined"!=typeof chrome&&chrome&&"function"==typeof chrome.loadTimes,isNode:D,hasEnvVariables:C,env:N,global:a,getNativePromise:F,domainBind:B};U.isRecentNode=U.isNode&&(0===(W=process.versions.node.split(".").map(Number))[0]&&W[1]>10||W[0]>0),U.isNode&&U.toFastProperties(process);try{throw new Error}catch(t){U.lastLineError=t}e.exports=U},{"./es5":13}]},{},[4])(4),"undefined"!=typeof window&&null!==window?window.P=window.Promise:"undefined"!=typeof self&&null!==self&&(self.P=self.Promise)}(Qq);var Jq=Qq.exports,Xq=ca.Buffer;void 0===Xq.from&&(Xq.from=function(t,e,r){return new Xq(t,e,r)},Xq.alloc=Xq.from);var tV=Xq,eV=i,rV=Jq,nV=s,iV=tV;function oV(){if(!(this instanceof oV))return new oV;eV.Duplex.call(this,{decodeStrings:!1,objectMode:!0}),this.buffer=iV.from("");var t=this;t.on("finish",function(){t.finished=!0,t.emit("chunk",!1)})}eV.Writable&&eV.Writable.prototype.destroy||(eV=il()),nV.inherits(oV,eV.Duplex),oV.prototype._write=function(t,e,r){this.buffer=iV.concat([this.buffer,t]),this.cb=r,this.emit("chunk")},oV.prototype.stream=function(t,e){var r,n=eV.PassThrough(),i=this;function o(){if("function"==typeof i.cb){var t=i.cb;return i.cb=void 0,t()}}function s(){var a;if(i.buffer&&i.buffer.length){if("number"==typeof t)a=i.buffer.slice(0,t),i.buffer=i.buffer.slice(t),t-=a.length,r=!t;else{var l=i.buffer.indexOf(t);if(-1!==l)i.match=l,e&&(l+=t.length),a=i.buffer.slice(0,l),i.buffer=i.buffer.slice(l),r=!0;else{var u=i.buffer.length-t.length;u<=0?o():(a=i.buffer.slice(0,u),i.buffer=i.buffer.slice(u))}}a&&n.write(a,function(){(0===i.buffer.length||t.length&&i.buffer.length<=t.length)&&o()})}if(r)i.removeListener("chunk",s),n.end();else if(i.finished)return i.removeListener("chunk",s),void i.emit("error",new Error("FILE_ENDED"))}return i.on("chunk",s),s(),n},oV.prototype.pull=function(t,e){if(0===t)return rV.resolve("");if(!isNaN(t)&&this.buffer.length>t){var r=this.buffer.slice(0,t);return this.buffer=this.buffer.slice(t),rV.resolve(r)}var n,i,o=iV.from(""),s=this,a=eV.Transform();return a._transform=function(t,e,r){o=iV.concat([o,t]),r()},new rV(function(r,l){if(n=l,i=function(t){s.__emittedError=t,l(t)},s.finished)return l(new Error("FILE_ENDED"));s.once("error",i),s.stream(t,e).on("error",l).pipe(a).on("finish",function(){r(o)}).on("error",l)}).finally(function(){s.removeListener("error",n),s.removeListener("error",i)})},oV.prototype._read=function(){};var sV=oV,aV=i,lV=s;function uV(){if(!(this instanceof uV))return new uV;aV.Transform.call(this)}aV.Writable&&aV.Writable.prototype.destroy||(aV=il()),lV.inherits(uV,aV.Transform),uV.prototype._transform=function(t,e,r){r()};var cV=uV,hV=Jq,fV=i,dV=tV;fV.Writable&&fV.Writable.prototype.destroy||(fV=il());var pV=function(t){return new hV(function(e,r){var n=[],i=fV.Transform().on("finish",function(){e(dV.concat(n))}).on("error",r);i._transform=function(t,e,r){n.push(t),r()},t.on("error",r).pipe(i)})},yV=Kq,gV=function(t,e){for(var r;!r&&t&&t.length;){var n=yV.parse(t).word16lu("signature").word16lu("partsize").word64lu("uncompressedSize").word64lu("compressedSize").word64lu("offset").word64lu("disknum").vars;1===n.signature?r=n:t=t.slice(n.partsize+4)}return r=r||{},4294967295===e.compressedSize&&(e.compressedSize=r.compressedSize),4294967295===e.uncompressedSize&&(e.uncompressedSize=r.uncompressedSize),4294967295===e.offsetToLocalFileHeader&&(e.offsetToLocalFileHeader=r.offset),r},bV=function(t,e){const r=31&t,n=t>>5&15,i=1980+(t>>9&127),o=e?2*(31&e):0,s=e?e>>5&63:0,a=e?e>>11:0;return new Date(Date.UTC(i,n-1,r,a,s,o))},mV=s,_V=y,vV=i,wV=Kq,SV=Jq,EV=sV,RV=cV,kV=pV,TV=gV,xV=tV,AV=bV;vV.Writable&&vV.Writable.prototype.destroy||(vV=il());var OV=xV.alloc(4);function LV(t){if(!(this instanceof LV))return new LV(t);var e=this;e._opts=t||{verbose:!1},EV.call(e,e._opts),e.on("finish",function(){e.emit("end"),e.emit("close")}),e._readRecord().catch(function(t){e.__emittedError&&e.__emittedError===t||e.emit("error",t)})}OV.writeUInt32LE(101010256,0),mV.inherits(LV,EV),LV.prototype._readRecord=function(){var t=this;return t.pull(4).then(function(e){if(0!==e.length){var r=e.readUInt32LE(0);if(875721283===r)return t._readCrxHeader();if(67324752===r)return t._readFile();if(33639248===r)return t.reachedCD=!0,t._readCentralDirectoryFileHeader();if(101010256===r)return t._readEndOfCentralDirectoryRecord();if(t.reachedCD){return t.pull(OV,!0).then(function(){return t._readEndOfCentralDirectoryRecord()})}t.emit("error",new Error("invalid signature: 0x"+r.toString(16)))}})},LV.prototype._readCrxHeader=function(){var t=this;return t.pull(12).then(function(e){return t.crxHeader=wV.parse(e).word32lu("version").word32lu("pubKeyLength").word32lu("signatureLength").vars,t.pull(t.crxHeader.pubKeyLength+t.crxHeader.signatureLength)}).then(function(e){return t.crxHeader.publicKey=e.slice(0,t.crxHeader.pubKeyLength),t.crxHeader.signature=e.slice(t.crxHeader.pubKeyLength),t.emit("crx-header",t.crxHeader),t._readRecord()})},LV.prototype._readFile=function(){var t=this;return t.pull(26).then(function(e){var r=wV.parse(e).word16lu("versionsNeededToExtract").word16lu("flags").word16lu("compressionMethod").word16lu("lastModifiedTime").word16lu("lastModifiedDate").word32lu("crc32").word32lu("compressedSize").word32lu("uncompressedSize").word16lu("fileNameLength").word16lu("extraFieldLength").vars;return r.lastModifiedDateTime=AV(r.lastModifiedDate,r.lastModifiedTime),t.crxHeader&&(r.crxHeader=t.crxHeader),t.pull(r.fileNameLength).then(function(e){var n=e.toString("utf8"),i=vV.PassThrough(),o=!1;return i.autodrain=function(){o=!0;var t=i.pipe(RV());return t.promise=function(){return new SV(function(e,r){t.on("finish",e),t.on("error",r)})},t},i.buffer=function(){return kV(i)},i.path=n,i.props={},i.props.path=n,i.props.pathBuffer=e,i.props.flags={isUnicode:!!(2048&r.flags)},i.type=0===r.uncompressedSize&&/[\/\\]$/.test(n)?"Directory":"File",t._opts.verbose&&("Directory"===i.type?console.log(" creating:",n):"File"===i.type&&(0===r.compressionMethod?console.log(" extracting:",n):console.log(" inflating:",n))),t.pull(r.extraFieldLength).then(function(e){var s=TV(e,r);i.vars=r,i.extra=s,t._opts.forceStream?t.push(i):(t.emit("entry",i),(t._readableState.pipesCount||t._readableState.pipes&&t._readableState.pipes.length)&&t.push(i)),t._opts.verbose&&console.log({filename:n,vars:r,extra:s});var a,l=!(8&r.flags)||r.compressedSize>0;i.__autodraining=o;var u=r.compressionMethod&&!o?_V.createInflateRaw():vV.PassThrough();return l?(i.size=r.uncompressedSize,a=r.compressedSize):(a=xV.alloc(4)).writeUInt32LE(134695760,0),new SV(function(e,r){t.stream(a).pipe(u).on("error",function(e){t.emit("error",e)}).pipe(i).on("finish",function(){return l?t._readRecord().then(e).catch(r):t._processDataDescriptor(i).then(e).catch(r)})})})})})},LV.prototype._processDataDescriptor=function(t){var e=this;return e.pull(16).then(function(r){var n=wV.parse(r).word32lu("dataDescriptorSignature").word32lu("crc32").word32lu("compressedSize").word32lu("uncompressedSize").vars;return t.size=n.uncompressedSize,e._readRecord()})},LV.prototype._readCentralDirectoryFileHeader=function(){var t=this;return t.pull(42).then(function(e){var r=wV.parse(e).word16lu("versionMadeBy").word16lu("versionsNeededToExtract").word16lu("flags").word16lu("compressionMethod").word16lu("lastModifiedTime").word16lu("lastModifiedDate").word32lu("crc32").word32lu("compressedSize").word32lu("uncompressedSize").word16lu("fileNameLength").word16lu("extraFieldLength").word16lu("fileCommentLength").word16lu("diskNumber").word16lu("internalFileAttributes").word32lu("externalFileAttributes").word32lu("offsetToLocalFileHeader").vars;return t.pull(r.fileNameLength).then(function(e){return r.fileName=e.toString("utf8"),t.pull(r.extraFieldLength)}).then(function(e){return t.pull(r.fileCommentLength)}).then(function(e){return t._readRecord()})})},LV.prototype._readEndOfCentralDirectoryRecord=function(){var t=this;return t.pull(18).then(function(e){var r=wV.parse(e).word16lu("diskNumber").word16lu("diskStart").word16lu("numberOfRecordsOnDisk").word16lu("numberOfRecords").word32lu("sizeOfCentralDirectory").word32lu("offsetToStartOfCentralDirectory").word16lu("commentLength").vars;return t.pull(r.commentLength).then(function(e){e=e.toString("utf8"),t.end(),t.push(null)})})},LV.prototype.promise=function(){var t=this;return new SV(function(e,r){t.on("finish",e),t.on("error",r)})};var jV=LV,MV={exports:{}},IV=il();function PV(t,e,r){void 0===r&&(r=e,e=t,t=null),IV.Duplex.call(this,t),"function"!=typeof r.read&&(r=new IV.Readable(t).wrap(r)),this._writable=e,this._readable=r,this._waiting=!1;var n=this;e.once("finish",function(){n.end()}),this.once("finish",function(){e.end()}),r.on("readable",function(){n._waiting&&(n._waiting=!1,n._read())}),r.once("end",function(){n.push(null)}),t&&void 0!==t.bubbleErrors&&!t.bubbleErrors||(e.on("error",function(t){n.emit("error",t)}),r.on("error",function(t){n.emit("error",t)}))}PV.prototype=Object.create(IV.Duplex.prototype,{constructor:{value:PV}}),PV.prototype._write=function(t,e,r){this._writable.write(t,e,r)},PV.prototype._read=function(){for(var t,e=0;null!==(t=this._readable.read());)this.push(t),e++;0===e&&(this._waiting=!0)},MV.exports=function(t,e,r){return new PV(t,e,r)},MV.exports.DuplexWrapper=PV;var DV=MV.exports,CV=i,NV=jV,FV=DV,BV=pV;CV.Writable&&CV.Writable.prototype.destroy||(CV=il());var WV=function(t,e){var r,n=CV.PassThrough({objectMode:!0}),i=CV.PassThrough(),o=CV.Transform({objectMode:!0}),s=t instanceof RegExp?t:t&&new RegExp(t);o._transform=function(t,e,n){if(r||s&&!s.exec(t.path))return t.autodrain(),n();r=!0,a.emit("entry",t),t.on("error",function(t){i.emit("error",t)}),t.pipe(i).on("error",function(t){n(t)}).on("finish",function(t){n(null,t)})},n.pipe(NV(e)).on("error",function(t){i.emit("error",t)}).pipe(o).on("error",Object).on("finish",function(){r?i.end():i.emit("error",new Error("PATTERN_NOT_FOUND"))});var a=FV(n,i);return a.buffer=function(){return BV(i)},a},UV={},zV=HV,$V=i.Stream;function HV(){$V.call(this)}function GV(t,e,r){return t instanceof Error||(t=new Error(t)),t.code=t.code||e,t.path=t.path||r.path,t.fstream_type=t.fstream_type||r.type,t.fstream_path=t.fstream_path||r.path,r._path!==r.path&&(t.fstream_unc_path=t.fstream_unc_path||r._path),r.linkpath&&(t.fstream_linkpath=t.fstream_linkpath||r.linkpath),t.fstream_class=t.fstream_class||r.constructor.name,t.fstream_stack=t.fstream_stack||(new Error).stack.split(/\n/).slice(3).map(function(t){return t.replace(/^ {4}at /,"")}),t}Ca(HV,$V),HV.prototype.on=function(t,e){return"ready"===t&&this.ready?process.nextTick(e.bind(this)):$V.prototype.on.call(this,t,e),this},HV.prototype.abort=function(){this._aborted=!0,this.emit("abort")},HV.prototype.destroy=function(){},HV.prototype.warn=function(t,e){var r=this,n=GV(t,e,r);r.listeners("warn")?r.emit("warn",n):console.error("%s %s\npath = %s\nsyscall = %s\nfstream_type = %s\nfstream_path = %s\nfstream_unc_path = %s\nfstream_class = %s\nfstream_stack =\n%s\n",e||"UNKNOWN",n.stack,n.path,n.syscall,n.fstream_type,n.fstream_path,n.fstream_unc_path,n.fstream_class,n.fstream_stack.join("\n"))},HV.prototype.info=function(t,e){this.emit("info",t,e)},HV.prototype.error=function(t,e,r){var n=GV(t,e,this);if(r)throw n;this.emit("error",n)};var qV,VV,ZV,YV,KV,QV,JV,XV,tZ,eZ,rZ,nZ,iZ=function(t){var e,r=["Directory","File","SymbolicLink","Link","BlockDevice","CharacterDevice","FIFO","Socket"];if(t.type&&-1!==r.indexOf(t.type))return t[t.type]=!0,t.type;for(var n=0,i=r.length;n<i;n++){var o=t[e=r[n]]||t["is"+e];if("function"==typeof o&&(o=o.call(t)),o)return t[e]=!0,t.type=e,e}return null};function oZ(){if(VV)return qV;VV=1,qV=n;var t=Vs,e=Ca,r=uZ();function n(t){if(!(this instanceof n))throw new Error("LinkReader must be called as constructor.");if(!("Link"===t.type&&t.Link||"SymbolicLink"===t.type&&t.SymbolicLink))throw new Error("Non-link type "+t.type);r.call(this,t)}return e(n,r),n.prototype._stat=function(e){var n=this;t.readlink(n._path,function(t,i){if(t)return n.error(t);n.linkpath=n.props.linkpath=i,n.emit("linkpath",i),r.prototype._stat.call(n,e)})},n.prototype._read=function(){var t=this;t._paused||t._ended||(t.emit("end"),t.emit("close"),t._ended=!0)},qV}function sZ(){if(YV)return ZV;YV=1,ZV=s;var t=Vs,r=Ca,n=e,i=uZ(),o=a.ok;function s(t){var e=this;if(!(e instanceof s))throw new Error("DirReader must be called as constructor.");if("Directory"!==t.type||!t.Directory)throw new Error("Non-directory type "+t.type);e.entries=null,e._index=-1,e._paused=!1,e._length=-1,t.sort&&(this.sort=t.sort),i.call(this,t)}return r(s,i),s.prototype._getEntries=function(){var e=this;e._gotEntries||(e._gotEntries=!0,t.readdir(e._path,function(t,r){if(t)return e.error(t);function n(){e._length=e.entries.length,"function"==typeof e.sort&&(e.entries=e.entries.sort(e.sort.bind(e))),e._read()}e.entries=r,e.emit("entries",r),e._paused?e.once("resume",n):n()}))},s.prototype._read=function(){var e=this;if(!e.entries)return e._getEntries();if(!(e._paused||e._currentEntry||e._aborted))if(e._index++,e._index>=e.entries.length)e._ended||(e._ended=!0,e.emit("end"),e.emit("close"));else{var r=n.resolve(e._path,e.entries[e._index]);o(r!==e._path),o(e.entries[e._index]),e._currentEntry=r,t[e.props.follow?"stat":"lstat"](r,function(t,o){if(t)return e.error(t);var s=e._proxy||e;o.path=r,o.basename=n.basename(r),o.dirname=n.dirname(r);var a=e.getChildProps.call(s,o);a.path=r,a.basename=n.basename(r),a.dirname=n.dirname(r);var l=i(a,o);e._currentEntry=l,l.on("pause",function(t){e._paused||l._disowned||e.pause(t)}),l.on("resume",function(t){e._paused&&!l._disowned&&e.resume(t)}),l.on("stat",function(t){e.emit("_entryStat",l,t),l._aborted||(l._paused?l.once("resume",function(){e.emit("entryStat",l,t)}):e.emit("entryStat",l,t))}),l.on("ready",function t(){if(e._paused)return l.pause(e),e.once("resume",t);"Socket"===l.type?e.emit("socket",l):e.emitEntry(l)});var u=!1;function c(){u||(u=!0,e.emit("childEnd",l),e.emit("entryEnd",l),e._currentEntry=null,e._paused||e._read())}l.on("close",c),l.on("disown",c),l.on("error",function(t){l._swallowErrors?(e.warn(t),l.emit("end"),l.emit("close")):e.emit("error",t)}),["child","childEnd","warn"].forEach(function(t){l.on(t,e.emit.bind(e,t))})})}},s.prototype.disown=function(t){t.emit("beforeDisown"),t._disowned=!0,t.parent=t.root=null,t===this._currentEntry&&(this._currentEntry=null),t.emit("disown")},s.prototype.getChildProps=function(){return{depth:this.depth+1,root:this.root||this,parent:this,follow:this.follow,filter:this.filter,sort:this.props.sort,hardlinks:this.props.hardlinks}},s.prototype.pause=function(t){var e=this;e._paused||(t=t||e,e._paused=!0,e._currentEntry&&e._currentEntry.pause&&e._currentEntry.pause(t),e.emit("pause",t))},s.prototype.resume=function(t){var e=this;e._paused&&(t=t||e,e._paused=!1,e.emit("resume",t),e._paused||(e._currentEntry?e._currentEntry.resume&&e._currentEntry.resume(t):e._read()))},s.prototype.emitEntry=function(t){this.emit("entry",t),this.emit("child",t)},ZV}function aZ(){if(QV)return KV;QV=1,KV=o;var t=Vs,e=Ca,r=uZ(),n={EOF:!0},i={CLOSE:!0};function o(t){var e=this;if(!(e instanceof o))throw new Error("FileReader must be called as constructor.");if(!("Link"===t.type&&t.Link||"File"===t.type&&t.File))throw new Error("Non-file type "+t.type);e._buffer=[],e._bytesEmitted=0,r.call(e,t)}return e(o,r),o.prototype._getStream=function(){var e=this,r=e._stream=t.createReadStream(e._path,e.props);e.props.blksize&&(r.bufferSize=e.props.blksize),r.on("open",e.emit.bind(e,"open")),r.on("data",function(t){e._bytesEmitted+=t.length,t.length&&(e._paused||e._buffer.length?(e._buffer.push(t),e._read()):e.emit("data",t))}),r.on("end",function(){e._paused||e._buffer.length?(e._buffer.push(n),e._read()):e.emit("end"),e._bytesEmitted!==e.props.size&&e.error("Didn't get expected byte count\nexpect: "+e.props.size+"\nactual: "+e._bytesEmitted)}),r.on("close",function(){e._paused||e._buffer.length?(e._buffer.push(i),e._read()):e.emit("close")}),r.on("error",function(t){e.emit("error",t)}),e._read()},o.prototype._read=function(){var t=this;if(!t._paused){if(!t._stream)return t._getStream();if(t._buffer.length){for(var e=t._buffer,r=0,o=e.length;r<o;r++){var s=e[r];if(s===n?t.emit("end"):s===i?t.emit("close"):t.emit("data",s),t._paused)return void(t._buffer=e.slice(r))}t._buffer.length=0}}},o.prototype.pause=function(t){var e=this;e._paused||(t=t||e,e._paused=!0,e._stream&&e._stream.pause(),e.emit("pause",t))},o.prototype.resume=function(t){var e=this;e._paused&&(t=t||e,e.emit("resume",t),e._paused=!1,e._stream&&e._stream.resume(),e._read())},KV}function lZ(){if(eZ)return tZ;eZ=1,tZ=n;var t=uZ(),e=iZ,r=Vs;function n(e){var r=this;if(!(r instanceof n))throw new Error("ProxyReader must be called as constructor.");r.props=e,r._buffer=[],r.ready=!1,t.call(r,e)}return Ca(n,t),n.prototype._stat=function(){var n=this,i=n.props,o=i.follow?"stat":"lstat";r[o](i.path,function(r,o){var s;s=r||!o?"File":e(o),i[s]=!0,i.type=n.type=s,n._old=o,n._addProxy(t(i,o))})},n.prototype._addProxy=function(t){var e=this;if(e._proxyTarget)return e.error("proxy already set");e._proxyTarget=t,t._proxy=e,["error","data","end","close","linkpath","entry","entryEnd","child","childEnd","warn","stat"].forEach(function(r){t.on(r,e.emit.bind(e,r))}),e.emit("proxy",t),t.on("ready",function(){e.ready=!0,e.emit("ready")});var r=e._buffer;e._buffer.length=0,r.forEach(function(e){t[e[0]].apply(t,e[1])})},n.prototype.pause=function(){return!!this._proxyTarget&&this._proxyTarget.pause()},n.prototype.resume=function(){return!!this._proxyTarget&&this._proxyTarget.resume()},tZ}function uZ(){if(nZ)return rZ;nZ=1,rZ=c;var t=Vs,r=i.Stream,n=Ca,o=e,s=iZ,a=c.hardLinks={},l=zV;n(c,l);var u=oZ();function c(t,e){var r,n,i=this;if(!(i instanceof c))return new c(t,e);switch("string"==typeof t&&(t={path:t}),t.type&&"function"==typeof t.type?n=r=t.type:(r=s(t),n=c),e&&!r&&(t[r=s(e)]=!0,t.type=r),r){case"Directory":n=sZ();break;case"Link":case"File":n=aZ();break;case"SymbolicLink":n=u;break;case"Socket":n=function(){if(XV)return JV;XV=1,JV=r;var t=Ca,e=uZ();function r(t){if(!(this instanceof r))throw new Error("SocketReader must be called as constructor.");if("Socket"!==t.type||!t.Socket)throw new Error("Non-socket type "+t.type);e.call(this,t)}return t(r,e),r.prototype._read=function(){var t=this;t._paused||t._ended||(t.emit("end"),t.emit("close"),t._ended=!0)},JV}();break;case null:n=lZ()}if(!(i instanceof n))return new n(t);l.call(i),t.path||i.error("Must provide a path",null,!0),i.readable=!0,i.writable=!1,i.type=r,i.props=t,i.depth=t.depth=t.depth||0,i.parent=t.parent||null,i.root=t.root||t.parent&&t.parent.root||i,i._path=i.path=o.resolve(t.path),"win32"===process.platform&&(i.path=i._path=i.path.replace(/\?/g,"_"),i._path.length>=260&&(i._swallowErrors=!0,i._path="\\\\?\\"+i.path.replace(/\//g,"\\"))),i.basename=t.basename=o.basename(i.path),i.dirname=t.dirname=o.dirname(i.path),t.parent=t.root=null,i.size=t.size,i.filter="function"==typeof t.filter?t.filter:null,"alpha"===t.sort&&(t.sort=h),i._stat(e)}function h(t,e){return t===e?0:t.toLowerCase()>e.toLowerCase()?1:t.toLowerCase()<e.toLowerCase()?-1:t>e?1:-1}return c.prototype._stat=function(e){var r=this,n=r.props,i=n.follow?"stat":"lstat";function o(t,e){if(t)return r.error(t);if(Object.keys(e).forEach(function(t){n[t]=e[t]}),void 0!==r.size&&n.size!==r.size)return r.error("incorrect size");r.size=n.size;var i=s(n);if(!1!==n.hardlinks&&"Directory"!==i&&n.nlink&&n.nlink>1){var o=n.dev+":"+n.ino;a[o]!==r._path&&a[o]?(i=r.type=r.props.type="Link",r.Link=r.props.Link=!0,r.linkpath=r.props.linkpath=a[o],r._stat=r._read=u.prototype._read):a[o]=r._path}if(r.type&&r.type!==i&&r.error("Unexpected type: "+i),r.filter){var l=r._proxy||r;if(!r.filter.call(l,l,n))return void(r._disowned||(r.abort(),r.emit("end"),r.emit("close")))}var c=["_stat","stat","ready"],h=0;!function t(){if(r._aborted)return r.emit("end"),void r.emit("close");if(r._paused&&"Directory"!==r.type)r.once("resume",t);else{var e=c[h++];if(!e)return r._read();r.emit(e,n),t()}}()}e?process.nextTick(o.bind(null,null,e)):t[i](r._path,o)},c.prototype.pipe=function(t){var e=this;return"function"==typeof t.add&&e.on("entry",function(r){!1===t.add(r)&&e.pause()}),r.prototype.pipe.apply(this,arguments)},c.prototype.pause=function(t){this._paused=!0,t=t||this,this.emit("pause",t),this._stream&&this._stream.pause(t)},c.prototype.resume=function(t){this._paused=!1,t=t||this,this.emit("resume",t),this._stream&&this._stream.resume(t),this._read()},c.prototype._read=function(){this.error("Cannot read unknown type: "+this.type)},rZ}var cZ=vZ;vZ.sync=kZ;var hZ=a,fZ=e,dZ=t,pZ=void 0;try{pZ=QH()}catch(t){}var yZ=parseInt("666",8),gZ={nosort:!0,silent:!0},bZ=0,mZ="win32"===process.platform;function _Z(t){if(["unlink","chmod","stat","lstat","rmdir","readdir"].forEach(function(e){t[e]=t[e]||dZ[e],t[e+="Sync"]=t[e]||dZ[e]}),t.maxBusyTries=t.maxBusyTries||3,t.emfileWait=t.emfileWait||1e3,!1===t.glob&&(t.disableGlob=!0),!0!==t.disableGlob&&void 0===pZ)throw Error("glob dependency not found, set `options.disableGlob = true` if intentional");t.disableGlob=t.disableGlob||!1,t.glob=t.glob||gZ}function vZ(t,e,r){"function"==typeof e&&(r=e,e={}),hZ(t,"rimraf: missing path"),hZ.equal(typeof t,"string","rimraf: path should be a string"),hZ.equal(typeof r,"function","rimraf: callback function required"),hZ(e,"rimraf: invalid options argument provided"),hZ.equal(typeof e,"object","rimraf: options should be object"),_Z(e);var n=0,i=null,o=0;if(e.disableGlob||!pZ.hasMagic(t))return s(null,[t]);function s(t,s){return t?r(t):0===(o=s.length)?r():void s.forEach(function(t){wZ(t,e,function s(a){if(a){if(("EBUSY"===a.code||"ENOTEMPTY"===a.code||"EPERM"===a.code)&&n<e.maxBusyTries)return n++,setTimeout(function(){wZ(t,e,s)},100*n);if("EMFILE"===a.code&&bZ<e.emfileWait)return setTimeout(function(){wZ(t,e,s)},bZ++);"ENOENT"===a.code&&(a=null)}bZ=0,function(t){i=i||t,0===--o&&r(i)}(a)})})}e.lstat(t,function(r,n){if(!r)return s(null,[t]);pZ(t,e.glob,s)})}function wZ(t,e,r){hZ(t),hZ(e),hZ("function"==typeof r),e.lstat(t,function(n,i){return n&&"ENOENT"===n.code?r(null):(n&&"EPERM"===n.code&&mZ&&SZ(t,e,n,r),i&&i.isDirectory()?RZ(t,e,n,r):void e.unlink(t,function(n){if(n){if("ENOENT"===n.code)return r(null);if("EPERM"===n.code)return mZ?SZ(t,e,n,r):RZ(t,e,n,r);if("EISDIR"===n.code)return RZ(t,e,n,r)}return r(n)}))})}function SZ(t,e,r,n){hZ(t),hZ(e),hZ("function"==typeof n),r&&hZ(r instanceof Error),e.chmod(t,yZ,function(i){i?n("ENOENT"===i.code?null:r):e.stat(t,function(i,o){i?n("ENOENT"===i.code?null:r):o.isDirectory()?RZ(t,e,r,n):e.unlink(t,n)})})}function EZ(t,e,r){hZ(t),hZ(e),r&&hZ(r instanceof Error);try{e.chmodSync(t,yZ)}catch(t){if("ENOENT"===t.code)return;throw r}try{var n=e.statSync(t)}catch(t){if("ENOENT"===t.code)return;throw r}n.isDirectory()?TZ(t,e,r):e.unlinkSync(t)}function RZ(t,e,r,n){hZ(t),hZ(e),r&&hZ(r instanceof Error),hZ("function"==typeof n),e.rmdir(t,function(i){!i||"ENOTEMPTY"!==i.code&&"EEXIST"!==i.code&&"EPERM"!==i.code?i&&"ENOTDIR"===i.code?n(r):n(i):function(t,e,r){hZ(t),hZ(e),hZ("function"==typeof r),e.readdir(t,function(n,i){if(n)return r(n);var o,s=i.length;if(0===s)return e.rmdir(t,r);i.forEach(function(n){vZ(fZ.join(t,n),e,function(n){if(!o)return n?r(o=n):void(0===--s&&e.rmdir(t,r))})})})}(t,e,n)})}function kZ(t,e){var r;if(_Z(e=e||{}),hZ(t,"rimraf: missing path"),hZ.equal(typeof t,"string","rimraf: path should be a string"),hZ(e,"rimraf: missing options"),hZ.equal(typeof e,"object","rimraf: options should be object"),e.disableGlob||!pZ.hasMagic(t))r=[t];else try{e.lstatSync(t),r=[t]}catch(n){r=pZ.sync(t,e.glob)}if(r.length)for(var n=0;n<r.length;n++){t=r[n];try{var i=e.lstatSync(t)}catch(r){if("ENOENT"===r.code)return;"EPERM"===r.code&&mZ&&EZ(t,e,r)}try{i&&i.isDirectory()?TZ(t,e,null):e.unlinkSync(t)}catch(r){if("ENOENT"===r.code)return;if("EPERM"===r.code)return mZ?EZ(t,e,r):TZ(t,e,r);if("EISDIR"!==r.code)throw r;TZ(t,e,r)}}}function TZ(t,e,r){hZ(t),hZ(e),r&&hZ(r instanceof Error);try{e.rmdirSync(t)}catch(n){if("ENOENT"===n.code)return;if("ENOTDIR"===n.code)throw r;"ENOTEMPTY"!==n.code&&"EEXIST"!==n.code&&"EPERM"!==n.code||function(t,e){hZ(t),hZ(e),e.readdirSync(t).forEach(function(r){kZ(fZ.join(t,r),e)});var r=mZ?100:1,n=0;for(;;){var i=!0;try{var o=e.rmdirSync(t,e);return i=!1,o}finally{if(++n<r&&i)continue}}}(t,e)}}var xZ=e,AZ=t,OZ=parseInt("0777",8),LZ=jZ.mkdirp=jZ.mkdirP=jZ;function jZ(t,e,r,n){"function"==typeof e?(r=e,e={}):e&&"object"==typeof e||(e={mode:e});var i=e.mode,o=e.fs||AZ;void 0===i&&(i=OZ),n||(n=null);var s=r||function(){};t=xZ.resolve(t),o.mkdir(t,i,function(r){if(!r)return s(null,n=n||t);if("ENOENT"===r.code){if(xZ.dirname(t)===t)return s(r);jZ(xZ.dirname(t),e,function(r,n){r?s(r,n):jZ(t,e,s,n)})}else o.stat(t,function(t,e){t||!e.isDirectory()?s(r,n):s(null,n)})})}jZ.sync=function t(e,r,n){r&&"object"==typeof r||(r={mode:r});var i=r.mode,o=r.fs||AZ;void 0===i&&(i=OZ),n||(n=null),e=xZ.resolve(e);try{o.mkdirSync(e,i),n=n||e}catch(i){if("ENOENT"===i.code)n=t(xZ.dirname(e),r,n),t(e,r,n);else{var s;try{s=o.statSync(e)}catch(t){throw i}if(!s.isDirectory())throw i}}return n};var MZ,IZ,PZ,DZ,CZ,NZ,FZ,BZ,WZ,UZ,zZ=function t(e){if(e._collected)return;if(e._paused)return e.on("resume",t.bind(null,e));e._collected=!0,e.pause(),e.on("data",n),e.on("end",n);var r=[];function n(t){"string"==typeof t&&(t=new Buffer(t)),Buffer.isBuffer(t)&&!t.length||r.push(t)}e.on("entry",o);var i=[];function o(e){t(e),i.push(e)}e.on("proxy",function(t){t.pause()}),e.pipe=(s=e.pipe,function(t){var a=0;return function l(){var u=i[a++];if(!u)return e.removeListener("entry",o),e.removeListener("data",n),e.removeListener("end",n),e.pipe=s,t&&e.pipe(t),r.forEach(function(t){t?e.emit("data",t):e.emit("end")}),void e.resume();u.on("end",l),t?t.add(u):e.emit("entry",u)}(),t});var s};function $Z(){if(IZ)return MZ;IZ=1,MZ=o;var t=VZ(),r=LZ,n=e,i=zZ;function o(e){var r=this;r instanceof o||r.error("DirWriter must be called as constructor.",null,!0),"Directory"===e.type&&e.Directory||r.error("Non-directory type "+e.type+" "+JSON.stringify(e),null,!0),t.call(this,e)}return Ca(o,t),o.prototype._create=function(){var e=this;r(e._path,t.dirmode,function(t){if(t)return e.error(t);e.ready=!0,e.emit("ready"),e._process()})},o.prototype.write=function(){return!0},o.prototype.end=function(){this._ended=!0,this._process()},o.prototype.add=function(t){var e=this;return i(t),!e.ready||e._currentEntry?(e._buffer.push(t),!1):e._ended?e.error("add after end"):(e._buffer.push(t),e._process(),0===this._buffer.length)},o.prototype._process=function(){var e=this;if(!e._processing){var r=e._buffer.shift();if(!r)return e.emit("drain"),void(e._ended&&e._finish());e._processing=!0,e.emit("entry",r);var i,o=r;do{if((i=o._path||o.path)===e.root._path||i===e._path||i&&0===i.indexOf(e._path))return e._processing=!1,r._collected&&r.pipe(),e._process();o=o.parent}while(o);var s={parent:e,root:e.root||e,type:r.type,depth:e.depth+1};i=r._path||r.path||r.props.path,r.parent&&(i=i.substr(r.parent._path.length+1)),s.path=n.join(e.path,n.join("/",i)),s.filter=e.filter,Object.keys(r.props).forEach(function(t){s.hasOwnProperty(t)||(s[t]=r.props[t])});var a=e._currentChild=new t(s);a.on("ready",function(){r.pipe(a),r.resume()}),a.on("error",function(t){a._swallowErrors?(e.warn(t),a.emit("end"),a.emit("close")):e.emit("error",t)}),a.on("close",function(){if(l)return;l=!0,e._currentChild=null,e._processing=!1,e._process()});var l=!1}},MZ}function HZ(){if(DZ)return PZ;DZ=1,PZ=o;var t=Vs,r=VZ(),n=e,i=cZ;function o(t){if(!(this instanceof o))throw new Error("LinkWriter must be called as constructor.");if(!("Link"===t.type&&t.Link||"SymbolicLink"===t.type&&t.SymbolicLink))throw new Error("Non-link type "+t.type);""===t.linkpath&&(t.linkpath="."),t.linkpath||this.error("Need linkpath property to create "+t.type),r.call(this,t)}function s(e,r,n){i(e._path,function(i){if(i)return e.error(i);!function(e,r,n){t[n](r,e._path,function(t){if(t){if("ENOENT"!==t.code&&"EACCES"!==t.code&&"EPERM"!==t.code||"win32"!==process.platform)return e.error(t);e.ready=!0,e.emit("ready"),e.emit("end"),e.emit("close"),e.end=e._finish=function(){}}a(e)})}(e,r,n)})}function a(t){t.ready=!0,t.emit("ready"),t._ended&&!t._finished&&t._finish()}return Ca(o,r),o.prototype._create=function(){var e=this,r="Link"===e.type||"win32"===process.platform,i=r?"link":"symlink",o=r?n.resolve(e.dirname,e.linkpath):e.linkpath;if(r)return s(e,o,i);t.readlink(e._path,function(t,r){if(r&&r===o)return a(e);s(e,o,i)})},o.prototype.end=function(){this._ended=!0,this.ready&&(this._finished=!0,this._finish())},PZ}function GZ(){if(NZ)return CZ;NZ=1,CZ=n;var t=Vs,e=VZ(),r={};function n(t){var r=this;if(!(r instanceof n))throw new Error("FileWriter must be called as constructor.");if("File"!==t.type||!t.File)throw new Error("Non-file type "+t.type);r._buffer=[],r._bytesWritten=0,e.call(this,t)}return Ca(n,e),n.prototype._create=function(){var n=this;if(!n._stream){var i={};n.props.flags&&(i.flags=n.props.flags),i.mode=e.filemode,n._old&&n._old.blksize&&(i.bufferSize=n._old.blksize),n._stream=t.createWriteStream(n._path,i),n._stream.on("open",function(){n.ready=!0,n._buffer.forEach(function(t){t===r?n._stream.end():n._stream.write(t)}),n.emit("ready"),n.emit("drain")}),n._stream.on("error",function(t){n.emit("error",t)}),n._stream.on("drain",function(){n.emit("drain")}),n._stream.on("close",function(){n._finish()})}},n.prototype.write=function(t){var e=this;if(e._bytesWritten+=t.length,!e.ready){if(!Buffer.isBuffer(t)&&"string"!=typeof t)throw new Error("invalid write data");return e._buffer.push(t),!1}var r=e._stream.write(t);return!1===r&&e._stream._queue?e._stream._queue.length<=2:r},n.prototype.end=function(t){var e=this;return t&&e.write(t),e.ready?e._stream.end():(e._buffer.push(r),!1)},n.prototype._finish=function(){var t=this;"number"==typeof t.size&&t._bytesWritten!==t.size&&t.error("Did not get expected byte count.\nexpect: "+t.size+"\nactual: "+t._bytesWritten),e.prototype._finish.call(t)},CZ}function qZ(){if(BZ)return FZ;BZ=1,FZ=o;var e=VZ(),r=iZ,n=zZ,i=t;function o(t){var r=this;if(!(r instanceof o))throw new Error("ProxyWriter must be called as constructor.");r.props=t,r._needDrain=!1,e.call(r,t)}return Ca(o,e),o.prototype._stat=function(){var t=this,n=t.props,o=n.follow?"stat":"lstat";i[o](n.path,function(i,o){var s;s=i||!o?"File":r(o),n[s]=!0,n.type=t.type=s,t._old=o,t._addProxy(e(n,o))})},o.prototype._addProxy=function(t){var e=this;if(e._proxy)return e.error("proxy already set");e._proxy=t,["ready","error","close","pipe","drain","warn"].forEach(function(r){t.on(r,e.emit.bind(e,r))}),e.emit("proxy",t),e._buffer.forEach(function(e){t[e[0]].apply(t,e[1])}),e._buffer.length=0,e._needsDrain&&e.emit("drain")},o.prototype.add=function(t){return n(t),this._proxy?this._proxy.add(t):(this._buffer.push(["add",[t]]),this._needDrain=!0,!1)},o.prototype.write=function(t){return this._proxy?this._proxy.write(t):(this._buffer.push(["write",[t]]),this._needDrain=!0,!1)},o.prototype.end=function(t){return this._proxy?this._proxy.end(t):(this._buffer.push(["end",[t]]),!1)},FZ}function VZ(){if(UZ)return WZ;UZ=1,WZ=d;var t=Vs,r=Ca,n=cZ,i=LZ,o=e,s="win32"===process.platform?0:process.umask(),a=iZ,l=zV;r(d,l),d.dirmode=parseInt("0777",8)&~s,d.filemode=parseInt("0666",8)&~s;var u=$Z(),c=HZ(),h=GZ(),f=qZ();function d(t,e){var r=this;"string"==typeof t&&(t={path:t});var n=d;switch(a(t)){case"Directory":n=u;break;case"File":n=h;break;case"Link":case"SymbolicLink":n=c;break;default:n=f}if(!(r instanceof n))return new n(t);l.call(r),t.path||r.error("Must provide a path",null,!0),r.type=t.type,r.props=t,r.depth=t.depth||0,r.clobber=!1!==t.clobber||t.clobber,r.parent=t.parent||null,r.root=t.root||t.parent&&t.parent.root||r,r._path=r.path=o.resolve(t.path),"win32"===process.platform&&(r.path=r._path=r.path.replace(/\?/g,"_"),r._path.length>=260&&(r._swallowErrors=!0,r._path="\\\\?\\"+r.path.replace(/\//g,"\\"))),r.basename=o.basename(t.path),r.dirname=o.dirname(t.path),r.linkpath=t.linkpath||null,t.parent=t.root=null,r.size=t.size,"string"==typeof t.mode&&(t.mode=parseInt(t.mode,8)),r.readable=!1,r.writable=!0,r._buffer=[],r.ready=!1,r.filter="function"==typeof t.filter?t.filter:null,r._stat(e)}function p(t){i(o.dirname(t._path),d.dirmode,function(e,r){return e?t.error(e):(t._madeDir=r,t._create())})}function y(e,r,n,i,o){var s=r.mode,a=r.follow||"SymbolicLink"!==e.type?"chmod":"lchmod";if(!t[a])return o();if("number"!=typeof s)return o();var l=n.mode&parseInt("0777",8);if((s&=parseInt("0777",8))===l)return o();t[a](i,s,o)}function g(e,r,n,i,o){if("win32"===process.platform)return o();if(!process.getuid||0!==process.getuid())return o();if("number"!=typeof r.uid&&"number"!=typeof r.gid)return o();if(n.uid===r.uid&&n.gid===r.gid)return o();var s=e.props.follow||"SymbolicLink"!==e.type?"chown":"lchown";if(!t[s])return o();"number"!=typeof r.uid&&(r.uid=n.uid),"number"!=typeof r.gid&&(r.gid=n.gid),t[s](i,r.uid,r.gid,o)}function b(e,r,n,i,o){if(!t.utimes||"win32"===process.platform)return o();var s=r.follow||"SymbolicLink"!==e.type?"utimes":"lutimes";if("lutimes"!==s||t[s]||(s="utimes"),!t[s])return o();var a=n.atime,l=n.mtime,u=r.atime,c=r.mtime;if(void 0===u&&(u=a),void 0===c&&(c=l),_(u)||(u=new Date(u)),_(c)||(u=new Date(c)),u.getTime()===a.getTime()&&c.getTime()===l.getTime())return o();t[s](i,u,c,o)}function m(e,r,n){var i=e._madeDir,s=o.dirname(r);!function(e,r,n){var i={};Object.keys(e.props).forEach(function(t){i[t]=e.props[t],"mode"===t&&"Directory"!==e.type&&(i[t]=i[t]|parseInt("0111",8))});var o=3,s=null;function a(t){if(!s)return t?n(s=t):0===--o?n():void 0}t.stat(r,function(t,o){if(t)return n(s=t);y(e,i,o,r,a),g(e,i,o,r,a),b(e,i,o,r,a)})}(e,s,function(t){return t?n(t):s===i?n():void m(e,s,n)})}function _(t){return"object"==typeof t&&"[object Date]"===function(t){return Object.prototype.toString.call(t)}(t)}return d.prototype._create=function(){var e=this;t[e.props.follow?"stat":"lstat"](e._path,function(t){if(t)return e.warn("Cannot create "+e._path+"\nUnsupported type: "+e.type,"ENOTSUP");e._finish()})},d.prototype._stat=function(e){var r=this,i=r.props.follow?"stat":"lstat",o=r._proxy||r;function s(t,e){return r.filter&&!r.filter.call(o,o,e)?(r._aborted=!0,r.emit("end"),void r.emit("close")):t||!e?p(r):(r._old=e,a(e)!==r.type||"File"===r.type&&e.nlink>1?n(r._path,function(t){if(t)return r.error(t);r._old=null,p(r)}):void p(r))}e?s(null,e):t[i](r._path,s)},d.prototype._finish=function(){var e=this;if(e._finishing);else{e._finishing=!0;var r=0,n=null,i=!1;if(e._old)e._old.atime=new Date(0),e._old.mtime=new Date(0),s(e._old);else{var o=e.props.follow?"stat":"lstat";t[o](e._path,function(t,r){if(t)return"ENOENT"!==t.code||"Link"!==e.type&&"SymbolicLink"!==e.type||"win32"!==process.platform?e.error(t):(e.ready=!0,e.emit("ready"),e.emit("end"),e.emit("close"),void(e.end=e._finish=function(){}));s(e._old=r)})}}function s(t){r+=3,y(e,e.props,t,e._path,a("chmod")),g(e,e.props,t,e._path,a("chown")),b(e,e.props,t,e._path,a("utimes"))}function a(t){return function(o){if(!n){if(o)return o.fstream_finish_call=t,e.error(n=o);if(!(--r>0||i)){if(i=!0,!e._madeDir)return s();m(e,e._path,s)}}function s(t){if(t)return t.fstream_finish_call="setupMadeDir",e.error(t);e.emit("end"),e.emit("close")}}}},d.prototype.pipe=function(){this.error("Can't pipe from writable stream")},d.prototype.add=function(){this.error("Can't add to non-Directory type")},d.prototype.write=function(){return!0},WZ}!function(t){t.Abstract=zV,t.Reader=uZ(),t.Writer=VZ(),t.File={Reader:aZ(),Writer:GZ()},t.Dir={Reader:sZ(),Writer:$Z()},t.Link={Reader:oZ(),Writer:HZ()},t.Proxy={Reader:lZ(),Writer:qZ()},t.Reader.Dir=t.DirReader=t.Dir.Reader,t.Reader.File=t.FileReader=t.File.Reader,t.Reader.Link=t.LinkReader=t.Link.Reader,t.Reader.Proxy=t.ProxyReader=t.Proxy.Reader,t.Writer.Dir=t.DirWriter=t.Dir.Writer,t.Writer.File=t.FileWriter=t.File.Writer,t.Writer.Link=t.LinkWriter=t.Link.Writer,t.Writer.Proxy=t.ProxyWriter=t.Proxy.Writer,t.collect=zZ}(UV);var ZZ=function(t){t.path=QZ.resolve(QZ.normalize(t.path));var e=new YZ(t),r=new JZ.Writable({objectMode:!0});r._write=function(e,r,n){if("Directory"==e.type)return n();var i=QZ.join(t.path,e.path);if(0!=i.indexOf(t.path))return n();const o=t.getWriter?t.getWriter({path:i}):KZ({path:i});e.pipe(o).on("error",n).on("close",n)};var n=XZ(e,r);return e.once("crx-header",function(t){n.crxHeader=t}),e.pipe(r).on("finish",function(){n.emit("close")}),n.promise=function(){return new tY(function(t,e){n.on("close",t),n.on("error",e)})},n},YZ=jV,KZ=UV.Writer,QZ=e,JZ=i,XZ=DV,tY=Jq;var eY={exports:{}};!function(t){var e=function(t){var r=1e7,n=9007199254740992,i=f(n),o="0123456789abcdefghijklmnopqrstuvwxyz",s="function"==typeof BigInt;function a(t,e,r,n){return void 0===t?a[0]:void 0!==e&&(10!==+e||r)?H(t,e,r,n):Y(t)}function l(t,e){this.value=t,this.sign=e,this.isSmall=!1}function u(t){this.value=t,this.sign=t<0,this.isSmall=!0}function c(t){this.value=t}function h(t){return-n<t&&t<n}function f(t){return t<1e7?[t]:t<1e14?[t%1e7,Math.floor(t/1e7)]:[t%1e7,Math.floor(t/1e7)%1e7,Math.floor(t/1e14)]}function d(t){p(t);var e=t.length;if(e<4&&L(t,i)<0)switch(e){case 0:return 0;case 1:return t[0];case 2:return t[0]+t[1]*r;default:return t[0]+(t[1]+t[2]*r)*r}return t}function p(t){for(var e=t.length;0===t[--e];);t.length=e+1}function y(t){for(var e=new Array(t),r=-1;++r<t;)e[r]=0;return e}function g(t){return t>0?Math.floor(t):Math.ceil(t)}function b(t,e){var n,i,o=t.length,s=e.length,a=new Array(o),l=0,u=r;for(i=0;i<s;i++)l=(n=t[i]+e[i]+l)>=u?1:0,a[i]=n-l*u;for(;i<o;)l=(n=t[i]+l)===u?1:0,a[i++]=n-l*u;return l>0&&a.push(l),a}function m(t,e){return t.length>=e.length?b(t,e):b(e,t)}function _(t,e){var n,i,o=t.length,s=new Array(o),a=r;for(i=0;i<o;i++)n=t[i]-a+e,e=Math.floor(n/a),s[i]=n-e*a,e+=1;for(;e>0;)s[i++]=e%a,e=Math.floor(e/a);return s}function v(t,e){var n,i,o=t.length,s=e.length,a=new Array(o),l=0,u=r;for(n=0;n<s;n++)(i=t[n]-l-e[n])<0?(i+=u,l=1):l=0,a[n]=i;for(n=s;n<o;n++){if(!((i=t[n]-l)<0)){a[n++]=i;break}i+=u,a[n]=i}for(;n<o;n++)a[n]=t[n];return p(a),a}function w(t,e,n){var i,o,s=t.length,a=new Array(s),c=-e,h=r;for(i=0;i<s;i++)o=t[i]+c,c=Math.floor(o/h),o%=h,a[i]=o<0?o+h:o;return"number"==typeof(a=d(a))?(n&&(a=-a),new u(a)):new l(a,n)}function S(t,e){var n,i,o,s,a=t.length,l=e.length,u=y(a+l),c=r;for(o=0;o<a;++o){s=t[o];for(var h=0;h<l;++h)n=s*e[h]+u[o+h],i=Math.floor(n/c),u[o+h]=n-i*c,u[o+h+1]+=i}return p(u),u}function E(t,e){var n,i,o=t.length,s=new Array(o),a=r,l=0;for(i=0;i<o;i++)n=t[i]*e+l,l=Math.floor(n/a),s[i]=n-l*a;for(;l>0;)s[i++]=l%a,l=Math.floor(l/a);return s}function R(t,e){for(var r=[];e-- >0;)r.push(0);return r.concat(t)}function k(t,e){var r=Math.max(t.length,e.length);if(r<=30)return S(t,e);r=Math.ceil(r/2);var n=t.slice(r),i=t.slice(0,r),o=e.slice(r),s=e.slice(0,r),a=k(i,s),l=k(n,o),u=k(m(i,n),m(s,o)),c=m(m(a,R(v(v(u,a),l),r)),R(l,2*r));return p(c),c}function T(t,e,n){return new l(t<r?E(e,t):S(e,f(t)),n)}function x(t){var e,n,i,o,s=t.length,a=y(s+s),l=r;for(i=0;i<s;i++){n=0-(o=t[i])*o;for(var u=i;u<s;u++)e=o*t[u]*2+a[i+u]+n,n=Math.floor(e/l),a[i+u]=e-n*l;a[i+s]=n}return p(a),a}function A(t,e){var n,i,o,s,a=t.length,l=y(a),u=r;for(o=0,n=a-1;n>=0;--n)o=(s=o*u+t[n])-(i=g(s/e))*e,l[n]=0|i;return[l,0|o]}function O(t,e){var n,i=Y(e);if(s)return[new c(t.value/i.value),new c(t.value%i.value)];var o,h=t.value,b=i.value;if(0===b)throw new Error("Cannot divide by zero");if(t.isSmall)return i.isSmall?[new u(g(h/b)),new u(h%b)]:[a[0],t];if(i.isSmall){if(1===b)return[t,a[0]];if(-1==b)return[t.negate(),a[0]];var m=Math.abs(b);if(m<r){o=d((n=A(h,m))[0]);var _=n[1];return t.sign&&(_=-_),"number"==typeof o?(t.sign!==i.sign&&(o=-o),[new u(o),new u(_)]):[new l(o,t.sign!==i.sign),new u(_)]}b=f(m)}var w=L(h,b);if(-1===w)return[a[0],t];if(0===w)return[a[t.sign===i.sign?1:-1],a[0]];n=h.length+b.length<=200?function(t,e){var n,i,o,s,a,l,u,c=t.length,h=e.length,f=r,p=y(e.length),g=e[h-1],b=Math.ceil(f/(2*g)),m=E(t,b),_=E(e,b);for(m.length<=c&&m.push(0),_.push(0),g=_[h-1],i=c-h;i>=0;i--){for(n=f-1,m[i+h]!==g&&(n=Math.floor((m[i+h]*f+m[i+h-1])/g)),o=0,s=0,l=_.length,a=0;a<l;a++)o+=n*_[a],u=Math.floor(o/f),s+=m[i+a]-(o-u*f),o=u,s<0?(m[i+a]=s+f,s=-1):(m[i+a]=s,s=0);for(;0!==s;){for(n-=1,o=0,a=0;a<l;a++)(o+=m[i+a]-f+_[a])<0?(m[i+a]=o+f,o=0):(m[i+a]=o,o=1);s+=o}p[i]=n}return m=A(m,b)[0],[d(p),d(m)]}(h,b):function(t,e){for(var n,i,o,s,a,l=t.length,u=e.length,c=[],h=[],f=r;l;)if(h.unshift(t[--l]),p(h),L(h,e)<0)c.push(0);else{o=h[(i=h.length)-1]*f+h[i-2],s=e[u-1]*f+e[u-2],i>u&&(o=(o+1)*f),n=Math.ceil(o/s);do{if(L(a=E(e,n),h)<=0)break;n--}while(n);c.push(n),h=v(h,a)}return c.reverse(),[d(c),d(h)]}(h,b),o=n[0];var S=t.sign!==i.sign,R=n[1],k=t.sign;return"number"==typeof o?(S&&(o=-o),o=new u(o)):o=new l(o,S),"number"==typeof R?(k&&(R=-R),R=new u(R)):R=new l(R,k),[o,R]}function L(t,e){if(t.length!==e.length)return t.length>e.length?1:-1;for(var r=t.length-1;r>=0;r--)if(t[r]!==e[r])return t[r]>e[r]?1:-1;return 0}function j(t){var e=t.abs();return!e.isUnit()&&(!!(e.equals(2)||e.equals(3)||e.equals(5))||!(e.isEven()||e.isDivisibleBy(3)||e.isDivisibleBy(5))&&(!!e.lesser(49)||void 0))}function M(t,r){for(var n,i,o,s=t.prev(),a=s,l=0;a.isEven();)a=a.divide(2),l++;t:for(i=0;i<r.length;i++)if(!t.lesser(r[i])&&!(o=e(r[i]).modPow(a,t)).isUnit()&&!o.equals(s)){for(n=l-1;0!=n;n--){if((o=o.square().mod(t)).isUnit())return!1;if(o.equals(s))continue t}return!1}return!0}l.prototype=Object.create(a.prototype),u.prototype=Object.create(a.prototype),c.prototype=Object.create(a.prototype),l.prototype.add=function(t){var e=Y(t);if(this.sign!==e.sign)return this.subtract(e.negate());var r=this.value,n=e.value;return e.isSmall?new l(_(r,Math.abs(n)),this.sign):new l(m(r,n),this.sign)},l.prototype.plus=l.prototype.add,u.prototype.add=function(t){var e=Y(t),r=this.value;if(r<0!==e.sign)return this.subtract(e.negate());var n=e.value;if(e.isSmall){if(h(r+n))return new u(r+n);n=f(Math.abs(n))}return new l(_(n,Math.abs(r)),r<0)},u.prototype.plus=u.prototype.add,c.prototype.add=function(t){return new c(this.value+Y(t).value)},c.prototype.plus=c.prototype.add,l.prototype.subtract=function(t){var e=Y(t);if(this.sign!==e.sign)return this.add(e.negate());var r=this.value,n=e.value;return e.isSmall?w(r,Math.abs(n),this.sign):function(t,e,r){var n;return L(t,e)>=0?n=v(t,e):(n=v(e,t),r=!r),"number"==typeof(n=d(n))?(r&&(n=-n),new u(n)):new l(n,r)}(r,n,this.sign)},l.prototype.minus=l.prototype.subtract,u.prototype.subtract=function(t){var e=Y(t),r=this.value;if(r<0!==e.sign)return this.add(e.negate());var n=e.value;return e.isSmall?new u(r-n):w(n,Math.abs(r),r>=0)},u.prototype.minus=u.prototype.subtract,c.prototype.subtract=function(t){return new c(this.value-Y(t).value)},c.prototype.minus=c.prototype.subtract,l.prototype.negate=function(){return new l(this.value,!this.sign)},u.prototype.negate=function(){var t=this.sign,e=new u(-this.value);return e.sign=!t,e},c.prototype.negate=function(){return new c(-this.value)},l.prototype.abs=function(){return new l(this.value,!1)},u.prototype.abs=function(){return new u(Math.abs(this.value))},c.prototype.abs=function(){return new c(this.value>=0?this.value:-this.value)},l.prototype.multiply=function(t){var e,n,i,o=Y(t),s=this.value,u=o.value,c=this.sign!==o.sign;if(o.isSmall){if(0===u)return a[0];if(1===u)return this;if(-1===u)return this.negate();if((e=Math.abs(u))<r)return new l(E(s,e),c);u=f(e)}return n=s.length,i=u.length,new l(-.012*n-.012*i+15e-6*n*i>0?k(s,u):S(s,u),c)},l.prototype.times=l.prototype.multiply,u.prototype._multiplyBySmall=function(t){return h(t.value*this.value)?new u(t.value*this.value):T(Math.abs(t.value),f(Math.abs(this.value)),this.sign!==t.sign)},l.prototype._multiplyBySmall=function(t){return 0===t.value?a[0]:1===t.value?this:-1===t.value?this.negate():T(Math.abs(t.value),this.value,this.sign!==t.sign)},u.prototype.multiply=function(t){return Y(t)._multiplyBySmall(this)},u.prototype.times=u.prototype.multiply,c.prototype.multiply=function(t){return new c(this.value*Y(t).value)},c.prototype.times=c.prototype.multiply,l.prototype.square=function(){return new l(x(this.value),!1)},u.prototype.square=function(){var t=this.value*this.value;return h(t)?new u(t):new l(x(f(Math.abs(this.value))),!1)},c.prototype.square=function(t){return new c(this.value*this.value)},l.prototype.divmod=function(t){var e=O(this,t);return{quotient:e[0],remainder:e[1]}},c.prototype.divmod=u.prototype.divmod=l.prototype.divmod,l.prototype.divide=function(t){return O(this,t)[0]},c.prototype.over=c.prototype.divide=function(t){return new c(this.value/Y(t).value)},u.prototype.over=u.prototype.divide=l.prototype.over=l.prototype.divide,l.prototype.mod=function(t){return O(this,t)[1]},c.prototype.mod=c.prototype.remainder=function(t){return new c(this.value%Y(t).value)},u.prototype.remainder=u.prototype.mod=l.prototype.remainder=l.prototype.mod,l.prototype.pow=function(t){var e,r,n,i=Y(t),o=this.value,s=i.value;if(0===s)return a[1];if(0===o)return a[0];if(1===o)return a[1];if(-1===o)return i.isEven()?a[1]:a[-1];if(i.sign)return a[0];if(!i.isSmall)throw new Error("The exponent "+i.toString()+" is too large.");if(this.isSmall&&h(e=Math.pow(o,s)))return new u(g(e));for(r=this,n=a[1];!0&s&&(n=n.times(r),--s),0!==s;)s/=2,r=r.square();return n},u.prototype.pow=l.prototype.pow,c.prototype.pow=function(t){var e=Y(t),r=this.value,n=e.value,i=BigInt(0),o=BigInt(1),s=BigInt(2);if(n===i)return a[1];if(r===i)return a[0];if(r===o)return a[1];if(r===BigInt(-1))return e.isEven()?a[1]:a[-1];if(e.isNegative())return new c(i);for(var l=this,u=a[1];(n&o)===o&&(u=u.times(l),--n),n!==i;)n/=s,l=l.square();return u},l.prototype.modPow=function(t,e){if(t=Y(t),(e=Y(e)).isZero())throw new Error("Cannot take modPow with modulus 0");var r=a[1],n=this.mod(e);for(t.isNegative()&&(t=t.multiply(a[-1]),n=n.modInv(e));t.isPositive();){if(n.isZero())return a[0];t.isOdd()&&(r=r.multiply(n).mod(e)),t=t.divide(2),n=n.square().mod(e)}return r},c.prototype.modPow=u.prototype.modPow=l.prototype.modPow,l.prototype.compareAbs=function(t){var e=Y(t),r=this.value,n=e.value;return e.isSmall?1:L(r,n)},u.prototype.compareAbs=function(t){var e=Y(t),r=Math.abs(this.value),n=e.value;return e.isSmall?r===(n=Math.abs(n))?0:r>n?1:-1:-1},c.prototype.compareAbs=function(t){var e=this.value,r=Y(t).value;return(e=e>=0?e:-e)===(r=r>=0?r:-r)?0:e>r?1:-1},l.prototype.compare=function(t){if(t===1/0)return-1;if(t===-1/0)return 1;var e=Y(t),r=this.value,n=e.value;return this.sign!==e.sign?e.sign?1:-1:e.isSmall?this.sign?-1:1:L(r,n)*(this.sign?-1:1)},l.prototype.compareTo=l.prototype.compare,u.prototype.compare=function(t){if(t===1/0)return-1;if(t===-1/0)return 1;var e=Y(t),r=this.value,n=e.value;return e.isSmall?r==n?0:r>n?1:-1:r<0!==e.sign?r<0?-1:1:r<0?1:-1},u.prototype.compareTo=u.prototype.compare,c.prototype.compare=function(t){if(t===1/0)return-1;if(t===-1/0)return 1;var e=this.value,r=Y(t).value;return e===r?0:e>r?1:-1},c.prototype.compareTo=c.prototype.compare,l.prototype.equals=function(t){return 0===this.compare(t)},c.prototype.eq=c.prototype.equals=u.prototype.eq=u.prototype.equals=l.prototype.eq=l.prototype.equals,l.prototype.notEquals=function(t){return 0!==this.compare(t)},c.prototype.neq=c.prototype.notEquals=u.prototype.neq=u.prototype.notEquals=l.prototype.neq=l.prototype.notEquals,l.prototype.greater=function(t){return this.compare(t)>0},c.prototype.gt=c.prototype.greater=u.prototype.gt=u.prototype.greater=l.prototype.gt=l.prototype.greater,l.prototype.lesser=function(t){return this.compare(t)<0},c.prototype.lt=c.prototype.lesser=u.prototype.lt=u.prototype.lesser=l.prototype.lt=l.prototype.lesser,l.prototype.greaterOrEquals=function(t){return this.compare(t)>=0},c.prototype.geq=c.prototype.greaterOrEquals=u.prototype.geq=u.prototype.greaterOrEquals=l.prototype.geq=l.prototype.greaterOrEquals,l.prototype.lesserOrEquals=function(t){return this.compare(t)<=0},c.prototype.leq=c.prototype.lesserOrEquals=u.prototype.leq=u.prototype.lesserOrEquals=l.prototype.leq=l.prototype.lesserOrEquals,l.prototype.isEven=function(){return!(1&this.value[0])},u.prototype.isEven=function(){return!(1&this.value)},c.prototype.isEven=function(){return(this.value&BigInt(1))===BigInt(0)},l.prototype.isOdd=function(){return!(1&~this.value[0])},u.prototype.isOdd=function(){return!(1&~this.value)},c.prototype.isOdd=function(){return(this.value&BigInt(1))===BigInt(1)},l.prototype.isPositive=function(){return!this.sign},u.prototype.isPositive=function(){return this.value>0},c.prototype.isPositive=u.prototype.isPositive,l.prototype.isNegative=function(){return this.sign},u.prototype.isNegative=function(){return this.value<0},c.prototype.isNegative=u.prototype.isNegative,l.prototype.isUnit=function(){return!1},u.prototype.isUnit=function(){return 1===Math.abs(this.value)},c.prototype.isUnit=function(){return this.abs().value===BigInt(1)},l.prototype.isZero=function(){return!1},u.prototype.isZero=function(){return 0===this.value},c.prototype.isZero=function(){return this.value===BigInt(0)},l.prototype.isDivisibleBy=function(t){var e=Y(t);return!e.isZero()&&(!!e.isUnit()||(0===e.compareAbs(2)?this.isEven():this.mod(e).isZero()))},c.prototype.isDivisibleBy=u.prototype.isDivisibleBy=l.prototype.isDivisibleBy,l.prototype.isPrime=function(r){var n=j(this);if(n!==t)return n;var i=this.abs(),o=i.bitLength();if(o<=64)return M(i,[2,3,5,7,11,13,17,19,23,29,31,37]);for(var s=Math.log(2)*o.toJSNumber(),a=Math.ceil(!0===r?2*Math.pow(s,2):s),l=[],u=0;u<a;u++)l.push(e(u+2));return M(i,l)},c.prototype.isPrime=u.prototype.isPrime=l.prototype.isPrime,l.prototype.isProbablePrime=function(r,n){var i=j(this);if(i!==t)return i;for(var o=this.abs(),s=r===t?5:r,a=[],l=0;l<s;l++)a.push(e.randBetween(2,o.minus(2),n));return M(o,a)},c.prototype.isProbablePrime=u.prototype.isProbablePrime=l.prototype.isProbablePrime,l.prototype.modInv=function(t){for(var r,n,i,o=e.zero,s=e.one,a=Y(t),l=this.abs();!l.isZero();)r=a.divide(l),n=o,i=a,o=s,a=l,s=n.subtract(r.multiply(s)),l=i.subtract(r.multiply(l));if(!a.isUnit())throw new Error(this.toString()+" and "+t.toString()+" are not co-prime");return-1===o.compare(0)&&(o=o.add(t)),this.isNegative()?o.negate():o},c.prototype.modInv=u.prototype.modInv=l.prototype.modInv,l.prototype.next=function(){var t=this.value;return this.sign?w(t,1,this.sign):new l(_(t,1),this.sign)},u.prototype.next=function(){var t=this.value;return t+1<n?new u(t+1):new l(i,!1)},c.prototype.next=function(){return new c(this.value+BigInt(1))},l.prototype.prev=function(){var t=this.value;return this.sign?new l(_(t,1),!0):w(t,1,this.sign)},u.prototype.prev=function(){var t=this.value;return t-1>-n?new u(t-1):new l(i,!0)},c.prototype.prev=function(){return new c(this.value-BigInt(1))};for(var I=[1];2*I[I.length-1]<=r;)I.push(2*I[I.length-1]);var P=I.length,D=I[P-1];function C(t){return Math.abs(t)<=r}function N(t,r,n){r=Y(r);for(var i=t.isNegative(),o=r.isNegative(),s=i?t.not():t,a=o?r.not():r,l=0,u=0,c=null,h=null,f=[];!s.isZero()||!a.isZero();)l=(c=O(s,D))[1].toJSNumber(),i&&(l=D-1-l),u=(h=O(a,D))[1].toJSNumber(),o&&(u=D-1-u),s=c[0],a=h[0],f.push(n(l,u));for(var d=0!==n(i?1:0,o?1:0)?e(-1):e(0),p=f.length-1;p>=0;p-=1)d=d.multiply(D).add(e(f[p]));return d}l.prototype.shiftLeft=function(t){var e=Y(t).toJSNumber();if(!C(e))throw new Error(String(e)+" is too large for shifting.");if(e<0)return this.shiftRight(-e);var r=this;if(r.isZero())return r;for(;e>=P;)r=r.multiply(D),e-=P-1;return r.multiply(I[e])},c.prototype.shiftLeft=u.prototype.shiftLeft=l.prototype.shiftLeft,l.prototype.shiftRight=function(t){var e,r=Y(t).toJSNumber();if(!C(r))throw new Error(String(r)+" is too large for shifting.");if(r<0)return this.shiftLeft(-r);for(var n=this;r>=P;){if(n.isZero()||n.isNegative()&&n.isUnit())return n;n=(e=O(n,D))[1].isNegative()?e[0].prev():e[0],r-=P-1}return(e=O(n,I[r]))[1].isNegative()?e[0].prev():e[0]},c.prototype.shiftRight=u.prototype.shiftRight=l.prototype.shiftRight,l.prototype.not=function(){return this.negate().prev()},c.prototype.not=u.prototype.not=l.prototype.not,l.prototype.and=function(t){return N(this,t,function(t,e){return t&e})},c.prototype.and=u.prototype.and=l.prototype.and,l.prototype.or=function(t){return N(this,t,function(t,e){return t|e})},c.prototype.or=u.prototype.or=l.prototype.or,l.prototype.xor=function(t){return N(this,t,function(t,e){return t^e})},c.prototype.xor=u.prototype.xor=l.prototype.xor;var F=1<<30;function B(t){var e=t.value,n="number"==typeof e?e|F:"bigint"==typeof e?e|BigInt(F):e[0]+e[1]*r|1073758208;return n&-n}function W(t,r){if(r.compareTo(t)<=0){var n=W(t,r.square(r)),i=n.p,o=n.e,s=i.multiply(r);return s.compareTo(t)<=0?{p:s,e:2*o+1}:{p:i,e:2*o}}return{p:e(1),e:0}}function U(t,e){return t=Y(t),e=Y(e),t.greater(e)?t:e}function z(t,e){return t=Y(t),e=Y(e),t.lesser(e)?t:e}function $(t,e){if(t=Y(t).abs(),e=Y(e).abs(),t.equals(e))return t;if(t.isZero())return e;if(e.isZero())return t;for(var r,n,i=a[1];t.isEven()&&e.isEven();)r=z(B(t),B(e)),t=t.divide(r),e=e.divide(r),i=i.multiply(r);for(;t.isEven();)t=t.divide(B(t));do{for(;e.isEven();)e=e.divide(B(e));t.greater(e)&&(n=e,e=t,t=n),e=e.subtract(t)}while(!e.isZero());return i.isUnit()?t:t.multiply(i)}l.prototype.bitLength=function(){var t=this;return t.compareTo(e(0))<0&&(t=t.negate().subtract(e(1))),0===t.compareTo(e(0))?e(0):e(W(t,e(2)).e).add(e(1))},c.prototype.bitLength=u.prototype.bitLength=l.prototype.bitLength;var H=function(t,e,r,n){r=r||o,t=String(t),n||(t=t.toLowerCase(),r=r.toLowerCase());var i,s=t.length,a=Math.abs(e),l={};for(i=0;i<r.length;i++)l[r[i]]=i;for(i=0;i<s;i++){if("-"!==(h=t[i])&&(h in l&&l[h]>=a)){if("1"===h&&1===a)continue;throw new Error(h+" is not a valid digit in base "+e+".")}}e=Y(e);var u=[],c="-"===t[0];for(i=c?1:0;i<t.length;i++){var h;if((h=t[i])in l)u.push(Y(l[h]));else{if("<"!==h)throw new Error(h+" is not a valid character");var f=i;do{i++}while(">"!==t[i]&&i<t.length);u.push(Y(t.slice(f+1,i)))}}return G(u,e,c)};function G(t,e,r){var n,i=a[0],o=a[1];for(n=t.length-1;n>=0;n--)i=i.add(t[n].times(o)),o=o.times(e);return r?i.negate():i}function q(t,r){if((r=e(r)).isZero()){if(t.isZero())return{value:[0],isNegative:!1};throw new Error("Cannot convert nonzero numbers to base 0.")}if(r.equals(-1)){if(t.isZero())return{value:[0],isNegative:!1};if(t.isNegative())return{value:[].concat.apply([],Array.apply(null,Array(-t.toJSNumber())).map(Array.prototype.valueOf,[1,0])),isNegative:!1};var n=Array.apply(null,Array(t.toJSNumber()-1)).map(Array.prototype.valueOf,[0,1]);return n.unshift([1]),{value:[].concat.apply([],n),isNegative:!1}}var i=!1;if(t.isNegative()&&r.isPositive()&&(i=!0,t=t.abs()),r.isUnit())return t.isZero()?{value:[0],isNegative:!1}:{value:Array.apply(null,Array(t.toJSNumber())).map(Number.prototype.valueOf,1),isNegative:i};for(var o,s=[],a=t;a.isNegative()||a.compareAbs(r)>=0;){o=a.divmod(r),a=o.quotient;var l=o.remainder;l.isNegative()&&(l=r.minus(l).abs(),a=a.next()),s.push(l.toJSNumber())}return s.push(a.toJSNumber()),{value:s.reverse(),isNegative:i}}function V(t,e,r){var n=q(t,e);return(n.isNegative?"-":"")+n.value.map(function(t){return function(t,e){return t<(e=e||o).length?e[t]:"<"+t+">"}(t,r)}).join("")}function Z(t){if(h(+t)){var e=+t;if(e===g(e))return s?new c(BigInt(e)):new u(e);throw new Error("Invalid integer: "+t)}var r="-"===t[0];r&&(t=t.slice(1));var n=t.split(/e/i);if(n.length>2)throw new Error("Invalid integer: "+n.join("e"));if(2===n.length){var i=n[1];if("+"===i[0]&&(i=i.slice(1)),(i=+i)!==g(i)||!h(i))throw new Error("Invalid integer: "+i+" is not a valid exponent.");var o=n[0],a=o.indexOf(".");if(a>=0&&(i-=o.length-a-1,o=o.slice(0,a)+o.slice(a+1)),i<0)throw new Error("Cannot include negative exponent part for integers");t=o+=new Array(i+1).join("0")}if(!/^([0-9][0-9]*)$/.test(t))throw new Error("Invalid integer: "+t);if(s)return new c(BigInt(r?"-"+t:t));for(var f=[],d=t.length,y=d-7;d>0;)f.push(+t.slice(y,d)),(y-=7)<0&&(y=0),d-=7;return p(f),new l(f,r)}function Y(t){return"number"==typeof t?function(t){if(s)return new c(BigInt(t));if(h(t)){if(t!==g(t))throw new Error(t+" is not an integer.");return new u(t)}return Z(t.toString())}(t):"string"==typeof t?Z(t):"bigint"==typeof t?new c(t):t}l.prototype.toArray=function(t){return q(this,t)},u.prototype.toArray=function(t){return q(this,t)},c.prototype.toArray=function(t){return q(this,t)},l.prototype.toString=function(e,r){if(e===t&&(e=10),10!==e||r)return V(this,e,r);for(var n,i=this.value,o=i.length,s=String(i[--o]);--o>=0;)n=String(i[o]),s+="0000000".slice(n.length)+n;return(this.sign?"-":"")+s},u.prototype.toString=function(e,r){return e===t&&(e=10),10!=e||r?V(this,e,r):String(this.value)},c.prototype.toString=u.prototype.toString,c.prototype.toJSON=l.prototype.toJSON=u.prototype.toJSON=function(){return this.toString()},l.prototype.valueOf=function(){return parseInt(this.toString(),10)},l.prototype.toJSNumber=l.prototype.valueOf,u.prototype.valueOf=function(){return this.value},u.prototype.toJSNumber=u.prototype.valueOf,c.prototype.valueOf=c.prototype.toJSNumber=function(){return parseInt(this.toString(),10)};for(var K=0;K<1e3;K++)a[K]=Y(K),K>0&&(a[-K]=Y(-K));return a.one=a[1],a.zero=a[0],a.minusOne=a[-1],a.max=U,a.min=z,a.gcd=$,a.lcm=function(t,e){return t=Y(t).abs(),e=Y(e).abs(),t.divide($(t,e)).multiply(e)},a.isInstance=function(t){return t instanceof l||t instanceof u||t instanceof c},a.randBetween=function(t,e,n){t=Y(t),e=Y(e);var i=n||Math.random,o=z(t,e),s=U(t,e).subtract(o).add(1);if(s.isSmall)return o.add(Math.floor(i()*s));for(var l=q(s,r).value,u=[],c=!0,h=0;h<l.length;h++){var f=c?l[h]+(h+1<l.length?l[h+1]/r:0):r,d=g(i()*f);u.push(d),d<l[h]&&(c=!1)}return o.add(a.fromArray(u,r,!1))},a.fromArray=function(t,e,r){return G(t.map(Y),Y(e||10),r)},a}();t.hasOwnProperty("exports")&&(t.exports=e)}(eY);var rY,nY=eY.exports,iY=i;function oY(t,e){return rY||function(){var t,e,r;for(rY=[],e=0;e<256;e++){for(t=e,r=0;r<8;r++)t=1&t?3988292384^t>>>1:t>>>=1;rY[e]=t>>>0}}(),t.charCodeAt&&(t=t.charCodeAt(0)),nY(e).shiftRight(8).and(16777215).xor(rY[nY(e).xor(t).and(255)]).value}function sY(){if(!(this instanceof sY))return new sY;this.key0=305419896,this.key1=591751049,this.key2=878082192}iY.Writable&&iY.Writable.prototype.destroy||(iY=il()),sY.prototype.update=function(t){this.key0=oY(t,this.key0),this.key1=nY(this.key0).and(255).and(4294967295).add(this.key1),this.key1=nY(this.key1).multiply(134775813).add(1).and(4294967295).value,this.key2=oY(nY(this.key1).shiftRight(24).and(255),this.key2)},sY.prototype.decryptByte=function(t){var e=nY(this.key2).or(2);return t^=nY(e).multiply(nY(1^e)).shiftRight(8).and(255),this.update(t),t},sY.prototype.stream=function(){var t=iY.Transform(),e=this;return t._transform=function(t,r,n){for(var i=0;i<t.length;i++)t[i]=e.decryptByte(t[i]);this.push(t),n()},t};var aY=Jq,lY=sY,uY=sV,cY=i,hY=Kq,fY=y,dY=gV,pY=tV,yY=bV;cY.Writable&&cY.Writable.prototype.destroy||(cY=il());var gY=Kq,bY=sV,mY=function(t,e,r,n){var i=uY(),o=cY.PassThrough(),s=t.stream(e);return s.pipe(i).on("error",function(t){o.emit("error",t)}),o.vars=i.pull(30).then(function(t){var e=hY.parse(t).word32lu("signature").word16lu("versionsNeededToExtract").word16lu("flags").word16lu("compressionMethod").word16lu("lastModifiedTime").word16lu("lastModifiedDate").word32lu("crc32").word32lu("compressedSize").word32lu("uncompressedSize").word16lu("fileNameLength").word16lu("extraFieldLength").vars;return e.lastModifiedDateTime=yY(e.lastModifiedDate,e.lastModifiedTime),i.pull(e.fileNameLength).then(function(t){return e.fileName=t.toString("utf8"),i.pull(e.extraFieldLength)}).then(function(t){var s;return e.extra=dY(t,e),n&&n.compressedSize&&(e=n),1&e.flags&&(s=i.pull(12).then(function(t){if(!r)throw new Error("MISSING_PASSWORD");var n=lY();String(r).split("").forEach(function(t){n.update(t)});for(var i=0;i<t.length;i++)t[i]=n.decryptByte(t[i]);e.decrypt=n,e.compressedSize-=12;var o=8&e.flags?e.lastModifiedTime>>8&255:e.crc32>>24&255;if(t[11]!==o)throw new Error("BAD_PASSWORD");return e})),aY.resolve(s).then(function(){return o.emit("vars",e),e})})}),o.vars.then(function(t){var e,r=!(8&t.flags)||t.compressedSize>0,n=t.compressionMethod?fY.createInflateRaw():cY.PassThrough();r?(o.size=t.uncompressedSize,e=t.compressedSize):(e=pY.alloc(4)).writeUInt32LE(134695760,0);var a=i.stream(e);t.decrypt&&(a=a.pipe(t.decrypt.stream())),a.pipe(n).on("error",function(t){o.emit("error",t)}).pipe(o).on("finish",function(){s.destroy?s.destroy():s.abort?s.abort():s.close?s.close():s.push?s.push():console.log("warning - unable to close stream")})}).catch(function(t){o.emit("error",t)}),o},_Y=Jq,vY=pV,wY=gV,SY=e,EY=UV.Writer,RY=bV,kY=tV.alloc(4);kY.writeUInt32LE(101010256,0);var TY=Vs,xY=Jq,AY=function(t,e){var r,n,i,o,s=bY(),a=bY(),l=e&&e.tailSize||80;return e&&e.crx&&(n=function(t){var e=t.stream(0).pipe(bY());return e.pull(4).then(function(t){var r;if(875721283===t.readUInt32LE(0))return e.pull(12).then(function(t){r=gY.parse(t).word32lu("version").word32lu("pubKeyLength").word32lu("signatureLength").vars}).then(function(){return e.pull(r.pubKeyLength+r.signatureLength)}).then(function(t){return r.publicKey=t.slice(0,r.pubKeyLength),r.signature=t.slice(r.pubKeyLength),r.size=16+r.pubKeyLength+r.signatureLength,r})})}(t)),t.size().then(function(e){return r=e,t.stream(Math.max(0,e-l)).on("error",function(t){s.emit("error",t)}).pipe(s),s.pull(kY)}).then(function(){return _Y.props({directory:s.pull(22),crxHeader:n})}).then(function(e){var n=e.directory;if(i=e.crxHeader&&e.crxHeader.size||0,65535==(o=gY.parse(n).word32lu("signature").word16lu("diskNumber").word16lu("diskStart").word16lu("numberOfRecordsOnDisk").word16lu("numberOfRecords").word32lu("sizeOfCentralDirectory").word32lu("offsetToStartOfCentralDirectory").word16lu("commentLength").vars).numberOfRecords||65535==o.numberOfRecords||4294967295==o.offsetToStartOfCentralDirectory){const e=20,n=r-(l-s.match+e),i=bY();return t.stream(n).pipe(i),i.pull(e).then(function(e){return function(t,e){var r=gY.parse(e).word32lu("signature").word32lu("diskNumber").word64lu("offsetToStartOfCentralDirectory").word32lu("numberOfDisks").vars;if(117853008!=r.signature)throw new Error("invalid zip64 end of central dir locator signature (0x07064b50): 0x"+r.signature.toString(16));var n=bY();return t.stream(r.offsetToStartOfCentralDirectory).pipe(n),n.pull(56)}(t,e)}).then(function(t){o=function(t){var e=gY.parse(t).word32lu("signature").word64lu("sizeOfCentralDirectory").word16lu("version").word16lu("versionsNeededToExtract").word32lu("diskNumber").word32lu("diskStart").word64lu("numberOfRecordsOnDisk").word64lu("numberOfRecords").word64lu("sizeOfCentralDirectory").word64lu("offsetToStartOfCentralDirectory").vars;if(101075792!=e.signature)throw new Error("invalid zip64 end of central dir locator signature (0x06064b50): 0x0"+e.signature.toString(16));return e}(t)})}o.offsetToStartOfCentralDirectory+=i}).then(function(){if(o.commentLength)return s.pull(o.commentLength).then(function(t){o.comment=t.toString("utf8")})}).then(function(){return t.stream(o.offsetToStartOfCentralDirectory).pipe(a),o.extract=function(t){if(!t||!t.path)throw new Error("PATH_MISSING");return t.path=SY.resolve(SY.normalize(t.path)),o.files.then(function(e){return _Y.map(e,function(e){if("Directory"!=e.type){var r=SY.join(t.path,e.path);if(0==r.indexOf(t.path)){var n=t.getWriter?t.getWriter({path:r}):EY({path:r});return new _Y(function(r,i){e.stream(t.password).on("error",i).pipe(n).on("close",r).on("error",i)})}}},{concurrency:t.concurrency>1?t.concurrency:1})})},o.files=_Y.mapSeries(Array(o.numberOfRecords),function(){return a.pull(46).then(function(e){var r=gY.parse(e).word32lu("signature").word16lu("versionMadeBy").word16lu("versionsNeededToExtract").word16lu("flags").word16lu("compressionMethod").word16lu("lastModifiedTime").word16lu("lastModifiedDate").word32lu("crc32").word32lu("compressedSize").word32lu("uncompressedSize").word16lu("fileNameLength").word16lu("extraFieldLength").word16lu("fileCommentLength").word16lu("diskNumber").word16lu("internalFileAttributes").word32lu("externalFileAttributes").word32lu("offsetToLocalFileHeader").vars;return r.offsetToLocalFileHeader+=i,r.lastModifiedDateTime=RY(r.lastModifiedDate,r.lastModifiedTime),a.pull(r.fileNameLength).then(function(t){return r.pathBuffer=t,r.path=t.toString("utf8"),r.isUnicode=!!(2048&r.flags),a.pull(r.extraFieldLength)}).then(function(t){return r.extra=wY(t,r),a.pull(r.fileCommentLength)}).then(function(e){return r.comment=e,r.type=0===r.uncompressedSize&&/[\/\\]$/.test(r.path)?"Directory":"File",r.stream=function(e){return mY(t,r.offsetToLocalFileHeader,e,r)},r.buffer=function(t){return vY(r.stream(t))},r})})}),_Y.props(o)})},OY=i;OY.Writable&&OY.Writable.prototype.destroy||(OY=il());var LY={buffer:function(t,e){var r={stream:function(e,r){var n=OY.PassThrough();return n.end(t.slice(e,r)),n},size:function(){return xY.resolve(t.length)}};return AY(r,e)},file:function(t,e){var r={stream:function(e,r){return TY.createReadStream(t,{start:e,end:r&&e+r})},size:function(){return new xY(function(e,r){TY.stat(t,function(t,n){t?r(t):e(n.size)})})}};return AY(r,e)},url:function(t,e,r){if("string"==typeof e&&(e={url:e}),!e.url)throw"URL missing";e.headers=e.headers||{};var n={stream:function(r,n){var i=Object.create(e);return i.headers=Object.create(e.headers),i.headers.range="bytes="+r+"-"+(n||""),t(i)},size:function(){return new xY(function(r,n){var i=t(e);i.on("response",function(t){i.abort(),t.headers["content-length"]?r(t.headers["content-length"]):n(new Error("Missing content length header"))}).on("error",n)})}};return AY(n,r)},s3:function(t,e,r){var n={size:function(){return new xY(function(r,n){t.headObject(e,function(t,e){t?n(t):r(e.ContentLength)})})},stream:function(r,n){var i={};for(var o in e)i[o]=e[o];return i.Range="bytes="+r+"-"+(n||""),t.getObject(i).createReadStream()}};return AY(n,r)},custom:function(t,e){return AY(t,e)}};function jY(t){return null==t?[]:function(t,e){return pt(e,function(e){return t[e]})}(t,xe(t))}Dq.Parse=jV,Dq.ParseOne=WV,Dq.Extract=ZZ,Dq.Open=LY;var MY={exports:{}};!function(t){var e=Object.prototype.hasOwnProperty,r="~";function n(){}function i(t,e,r){this.fn=t,this.context=e,this.once=r||!1}function o(t,e,n,o,s){if("function"!=typeof n)throw new TypeError("The listener must be a function");var a=new i(n,o||t,s),l=r?r+e:e;return t._events[l]?t._events[l].fn?t._events[l]=[t._events[l],a]:t._events[l].push(a):(t._events[l]=a,t._eventsCount++),t}function s(t,e){0===--t._eventsCount?t._events=new n:delete t._events[e]}function a(){this._events=new n,this._eventsCount=0}Object.create&&(n.prototype=Object.create(null),(new n).__proto__||(r=!1)),a.prototype.eventNames=function(){var t,n,i=[];if(0===this._eventsCount)return i;for(n in t=this._events)e.call(t,n)&&i.push(r?n.slice(1):n);return Object.getOwnPropertySymbols?i.concat(Object.getOwnPropertySymbols(t)):i},a.prototype.listeners=function(t){var e=r?r+t:t,n=this._events[e];if(!n)return[];if(n.fn)return[n.fn];for(var i=0,o=n.length,s=new Array(o);i<o;i++)s[i]=n[i].fn;return s},a.prototype.listenerCount=function(t){var e=r?r+t:t,n=this._events[e];return n?n.fn?1:n.length:0},a.prototype.emit=function(t,e,n,i,o,s){var a=r?r+t:t;if(!this._events[a])return!1;var l,u,c=this._events[a],h=arguments.length;if(c.fn){switch(c.once&&this.removeListener(t,c.fn,void 0,!0),h){case 1:return c.fn.call(c.context),!0;case 2:return c.fn.call(c.context,e),!0;case 3:return c.fn.call(c.context,e,n),!0;case 4:return c.fn.call(c.context,e,n,i),!0;case 5:return c.fn.call(c.context,e,n,i,o),!0;case 6:return c.fn.call(c.context,e,n,i,o,s),!0}for(u=1,l=new Array(h-1);u<h;u++)l[u-1]=arguments[u];c.fn.apply(c.context,l)}else{var f,d=c.length;for(u=0;u<d;u++)switch(c[u].once&&this.removeListener(t,c[u].fn,void 0,!0),h){case 1:c[u].fn.call(c[u].context);break;case 2:c[u].fn.call(c[u].context,e);break;case 3:c[u].fn.call(c[u].context,e,n);break;case 4:c[u].fn.call(c[u].context,e,n,i);break;default:if(!l)for(f=1,l=new Array(h-1);f<h;f++)l[f-1]=arguments[f];c[u].fn.apply(c[u].context,l)}}return!0},a.prototype.on=function(t,e,r){return o(this,t,e,r,!1)},a.prototype.once=function(t,e,r){return o(this,t,e,r,!0)},a.prototype.removeListener=function(t,e,n,i){var o=r?r+t:t;if(!this._events[o])return this;if(!e)return s(this,o),this;var a=this._events[o];if(a.fn)a.fn!==e||i&&!a.once||n&&a.context!==n||s(this,o);else{for(var l=0,u=[],c=a.length;l<c;l++)(a[l].fn!==e||i&&!a[l].once||n&&a[l].context!==n)&&u.push(a[l]);u.length?this._events[o]=1===u.length?u[0]:u:s(this,o)}return this},a.prototype.removeAllListeners=function(t){var e;return t?(e=r?r+t:t,this._events[e]&&s(this,e)):(this._events=new n,this._eventsCount=0),this},a.prototype.off=a.prototype.removeListener,a.prototype.addListener=a.prototype.on,a.prefixed=r,a.EventEmitter=a,t.exports=a}(MY);var IY=Bt(MY.exports);function PY(t=0){let e=0,r=[];var n;yr(n=t)&&vr(n)<0&&(t=0),t=vr(t);let i=new IY;return i.get=function(){if(r.length>0){return e+=1,r.splice(0,1)[0]}return null},i.cb=function(){e-=1,e<0&&(e=0),r.length>0&&i.emit("message",r)},i.push=function(n){r.push(n),(t<=0||e<t)&&i.emit("message",r)},i.clear=function(){e=0,r=[]},i}async function DY(e){try{Lr(e)?t.unlinkSync(e):Mr(e)&&Qr(e),t.writeFileSync(e,"test","utf8"),t.unlinkSync(e)}catch(t){return!1}return!0}lN.registerFormat("zip-encrypted",Pq);var CY={zipFile:async function(r,n,i={}){if(!t.existsSync(r))return Promise.reject("invalid path of source file");if(!t.lstatSync(r).isFile())return Promise.reject("path of source is not file");if(!DY(n))return Promise.reject("invalid fpSrc");let o=wt(i,"level",9),s=wt(i,"pw","");try{let i=Ir();t.existsSync(e.dirname(n))||t.mkdirSync(e.dirname(n),{recursive:!0});let a,l=t.createWriteStream(n);return a=""===s?lN("zip",{zlib:{level:o}}):lN("zip-encrypted",{zlib:{level:o},encryptionMethod:"zip20",password:s}),l.on("close",function(){i.resolve("done: "+n)}),a.on("warning",function(t){}),a.on("error",function(t){Promise.reject(t)}),a.pipe(l),a.file(r,{name:e.basename(r)}),a.finalize(),i}catch(t){return Promise.reject(t)}},zipFolder:async function(r,n,i={}){if(!t.existsSync(r))return Promise.reject("invalid path of source file");if(!t.lstatSync(r).isDirectory())return Promise.reject("path of source is not folder");if(!DY(n))return Promise.reject("invalid fpSrc");let o=wt(i,"level",9),s=wt(i,"pw","");try{let i=Ir();t.existsSync(e.dirname(n))||t.mkdirSync(e.dirname(n),{recursive:!0});let a,l=t.createWriteStream(n);return a=""===s?lN("zip",{zlib:{level:o}}):lN("zip-encrypted",{zlib:{level:o},encryptionMethod:"zip20",password:s}),l.on("close",function(){i.resolve("done: "+n)}),a.on("warning",function(t){}),a.on("error",function(t){Promise.reject(t)}),a.pipe(l),a.directory(r,e.basename(r)),a.finalize(),i}catch(t){return Promise.reject(t)}},unzip:async function(r,n,i={}){if(!t.existsSync(r))return Promise.reject("invalid path of source file");if(!t.lstatSync(r).isFile())return Promise.reject("path of source is not file");if(!DY(n))return Promise.reject("invalid fpSrc");let o=wt(i,"pw","");try{return await async function(r,n,i){return function(t,e,r=0){let n={},i=!1,o=Ir();if(!hr(t)&&!Tt(t))return o.reject("rs is not an array or object"),o;let s=!1;if(Tt(t)){s=!0;let e=[];je(t,(t,r)=>{e.push({k:r,v:t})}),t=e}let a=PY(r);return a.on("message",function(r){if(i)return;let l,u=a.get();if(kr(e)){let t=u.key,r=u.value;s&&(t=u.value.k,r=u.value.v),l=e(r,t)}else l=u.value;l.then(t=>{n[u.key]=t}).catch(t=>{i=!0,a.clear(),o.reject(t)}).finally(()=>{a.cb(),cr(n)===cr(t)&&o.resolve(jY(n))})}),je(t,(t,e)=>{a.push({key:e,value:t})}),o}((await Dq.Open.file(r)).files,async r=>{let o=e.join(n,r.path);return"File"===r.type?async function(r,n,i=""){try{t.existsSync(e.dirname(n))||t.mkdirSync(e.dirname(n),{recursive:!0});let o=await r.buffer(i);t.writeFileSync(n,o)}catch(t){return Promise.reject(t)}return"done"}(r,o,i):async function(e){try{t.existsSync(e)||t.mkdirSync(e,{recursive:!0})}catch(t){return Promise.reject(t)}return"done"}(o)})}(r,n,o),Promise.resolve("done: "+Hr(n))}catch(t){return Promise.reject(t)}}};async function NY(e){let r=`${e}portable.zip`,n=[],i=[];je(Br(1,9),t=>{let r=`portable.zip.00${t}`,o=`${e}${r}`;n.push(r),i.push(o)}),await function(t,e){let r=Ir();if(!hr(t)&&!Tt(t))return r.reject("rs is not an array or object"),r;let n=!1;if(Tt(t)){n=!0;let e=[];je(t,(t,r)=>{e.push({k:r,v:t})}),t=e}kr(e)||(e=function(t){return t});let i=-1,o=[];return t.reduce(function(t,r){return t.then(function(t){o.push(t),i+=1;let s=i,a=r;return n&&(s=r.k,a=r.v),kr(e)?e(a,s):a})},Promise.resolve()).then(function(t){o.push(t),o=Wr(o),r.resolve(o)}).catch(function(t){r.reject(t)}),r}(n,async(t,e)=>{let r=i[e],n=`https://github.com/yuda-lyu/w-html2png/raw/refs/heads/master/chrome/${t}`;console.log(`downloading url[${n}]...`,`to fp[${r}]`),await Vr(n,r)}),await Yr(i,r);let o=`${e}temp`;await CY.unzip(r,o);Kr(`${e}temp/portable`,`${e}portable`);Qr(o),Zr(r,{fs:t})}let FY=e.resolve();async function BY(n=700,i=400,o=3,s="",a={}){if("win32"!==process.platform)return Promise.reject("operating system is not windows");if(!kt(n))return Promise.reject("width is not a number");if((n=Nt(n))<=0)return Promise.reject("width <= 0");if(!kt(i))return Promise.reject("height is not a number");if((i=Nt(i))<=0)return Promise.reject("height <= 0");if(!kt(o))return Promise.reject("scale is not a number");if((o=Nt(o))<=0)return Promise.reject("scale <= 0");if(!Et(s))return Promise.reject("html is not an effective string");let l=s,u=wt(a,"modeHeadless");!0!==u&&!1!==u&&"new"!==u&&"shell"!==u&&(u="new");let c=wt(a,"scriptsHead");dr(c)||(c=[]);let h="";je(c,t=>{h+=`<script src="${t}"><\/script>\n`});let f=wt(a,"execJsHead");Et(f)&&(f=[f]),dr(f)||(f=[]);let d="";je(f,t=>{d+=`<script>${t}<\/script>\n\n`});let p=wt(a,"execJsPost");Et(p)&&(p=[p]),dr(p)||(p=[]);let y="";je(p,t=>{y+=`<script>${t}<\/script>\n\n`});let g=`${FY}/node_modules/w-html2png/chrome/`,b=`${FY}/chrome/`;Mr(g)&&(b=g);let m=`${`${b}portable/App/Chrome-bin/138.0.7204.97/`}chrome.exe`;Lr(m)||await NY(b);let _=wt(a,"executablePath","");Et(_)||(_=m);let v=process.cwd(),w=`${function(){if(!kr(Rr))throw new Error("invalid dayjs");return Rr().format("YYYYMMDDHHmmss")}()}-${function(t=32){let e=[];t=Tr(t)?vr(t):32;for(let r=0;r<t;r++)e[r]=xr[0|Math.random()*Ar];return e.join("")}()}`,S=await(async()=>{let s=[],a=[],c="",f=null,p=null,g=null;if(f=await(async r=>{let n=[],i=`./whpic-${w}.png`,o=e.resolve(v,i),s=`./whweb-${w}.html`,a=e.resolve(v,s),u='\n<!DOCTYPE html>\n<html>\n<head>\n <meta charset="UTF-8">\n <title>highcharts to png</title>\n\n <script src="https://cdn.jsdelivr.net/npm/lodash@4.17.21/lodash.min.js"><\/script>\n\n <script src="https://cdn.jsdelivr.net/npm/wsemi/dist/wsemi.umd.js"><\/script>\n <script>\n let w = wsemi\n <\/script>\n\n {cScriptsHead}\n\n {cExecJsHead}\n\n</head>\n<body style="padding:0; margin:0;">\n\n <div id="pl">\n {cHtml}\n </div>\n\n {cExecJsPost}\n\n</body>\n</html>\n';u=u.replace("{cHtml}",l),u=u.replace("{cScriptsHead}",h),u=u.replace("{cExecJsHead}",d),u=u.replace("{cExecJsPost}",y);try{t.writeFileSync(a,u,"utf8")}catch(t){n.push({anchor:"fs.writeFileSync(fpHtml, g, 'utf8')",err:t})}if(0===cr(n))try{let t=r(a,o);Sr(t)&&(t=await t)}catch(t){n.push({anchor:"fun(fpHtml, fpOut)",err:t})}if(Lr(a))try{t.unlinkSync(a)}catch(t){}if(Lr(o))try{t.unlinkSync(o)}catch(t){}return cr(n)>0?{state:"error",msg:n}:{state:"success",msg:""}})(async(e,s)=>{if(p=await(async t=>{let e=[],n=`./_puppeteer_profile_${w}`,i={headless:u,slowMo:20,protocolTimeout:6e4,userDataDir:n,args:["--no-sandbox","--incognito","--disable-gpu","--disable-software-rasterizer","--disable-setuid-sandbox","--disable-dev-shm-usage","--disable-sync","--disable-extensions","--disable-default-apps","--disable-features=VizDisplayCompositor","--metrics-recording-only","--mute-audio","--no-first-run","--safebrowsing-disable-auto-update"]};Et(_)&&(i.executablePath=_);let o=null,s=null,a=null;try{o=await r.launch(i),s=o.process(),a=wt(s,"pid","")}catch(t){e.push({anchor:"puppeteer.launch(puppeteerOpt)",err:t})}if(null!==o)try{let e=t(o);Sr(e)&&(e=await e)}catch(t){e.push({anchor:"fun(browser)",err:t})}if(null!==o)try{await o.close()}catch(t){e.push({anchor:"browser.close()",err:t})}if(wr(a))try{Vt(a,"SIGKILL")}catch(t){}try{await Dr(n)}catch(t){e.push({anchor:"fsDeleteFolderSafe(fd)",err:t})}return cr(e)>0?{state:"error",msg:e}:{state:"success",msg:""}})(async r=>{g=await(async(t,e)=>{let r=[],n=null;try{n=await t.newPage(),n.setDefaultNavigationTimeout(6e4)}catch(t){r.push({anchor:"browser.newPage()",err:t})}if(null!==n)try{let t=e(n);Sr(t)&&(t=await t)}catch(t){r.push({anchor:"fun(page)",err:t})}if(null!==n)try{await n.close()}catch(t){r.push({anchor:"page.close()",err:t})}return cr(r)>0?{state:"error",msg:r}:{state:"success",msg:""}})(r,async t=>{let r={x:0,y:0,width:Number(n),height:Number(i),deviceScaleFactor:Number(o)};await t.goto(e,{waitUntil:["domcontentloaded","networkidle2"],timeout:6e4}),await t.setViewport(r),await t.screenshot({path:s,timeout:6e4})}).catch(e=>{t.writeFileSync(`./_err_${w}_supplyPage.json`,e.message,"utf8")})}).catch(e=>{t.writeFileSync(`./_err_${w}_supplyBrowser.json`,e.message,"utf8")}),"error"!==wt(p,"state","")){if(Lr(s)){try{c=t.readFileSync(s,{encoding:"base64"})}catch(t){return void a.push({anchor:"fs.readFileSync(fpOut, { encoding: 'base64' })",err:t})}return null}a.push({anchor:"fsIsFile(fpOut)",err:new Error(`no file[${s}]`)})}}).catch(e=>{t.writeFileSync(`./_err_${w}_supplyHtml.json`,e.message,"utf8")}),"error"===wt(f,"state","")&&(s=[...s,...f.msg]),"error"===wt(p,"state","")&&(s=[...s,...p.msg]),"error"===wt(g,"state","")&&(s=[...s,...g.msg]),cr(a)>0&&(s=[...s,...a]),cr(s)>0){{let e="";je(s,t=>{let r=wt(t,"err.message","");e+=r+"\n"}),t.writeFileSync(`./_err_${w}_earrs.json`,e,"utf8")}let e=s[0],r=`${e.err.message} in ${e.anchor}`;return Promise.reject(r)}return Et(c)?c:Promise.reject("b64 is not an effective string")})().finally(()=>{let e=`./whweb-${w}.html`;Lr(e)&&t.writeFileSync(`./_err_${w}_fsIsFile_fnHtml.json`,`html檔[${e}]未正常刪除`,"utf8");let r=`./_puppeteer_profile_${w}`;Mr(r)&&t.writeFileSync(`./_err_${w}_fsIsFolder_profile.json`,`profile資料夾[${r}]未正常刪除`,"utf8");let n=`./whpic-${w}.png`;Lr(n)&&t.writeFileSync(`./_err_${w}_fsIsFile_fnPng.json`,`png檔[${n}]未正常刪除`,"utf8")});return S}let WY=t.readFileSync("./node_modules/highcharts/highcharts.js","utf8"),UY=t.readFileSync("./node_modules/highcharts/highcharts-more.js","utf8"),zY=t.readFileSync("./node_modules/highcharts/modules/stock.js","utf8"),$Y=t.readFileSync("./node_modules/highcharts/modules/annotations.js","utf8"),HY=t.readFileSync("./node_modules/highcharts/modules/heatmap.js","utf8"),GY=t.readFileSync("./node_modules/highcharts/modules/boost.js","utf8"),qY=t.readFileSync("./node_modules/highcharts/modules/boost-canvas.js","utf8");return async function(t=700,e=400,r=3,n={},i={}){if(!kt(t))return Promise.reject("width is not a number");if((t=Nt(t))<=0)return Promise.reject("width <= 0");if(!kt(e))return Promise.reject("height is not a number");if((e=Nt(e))<=0)return Promise.reject("height <= 0");if(!kt(r))return Promise.reject("scale is not a number");if((r=Nt(r))<=0)return Promise.reject("scale <= 0");if(!function(t){if(Tt(t)){for(let e in t)return!0;return!1}return!1}(n)&&!Et(n))return Promise.reject("opt is not an effective object or string");let o=[WY,UY,zY,$Y,HY,GY,qY],s="";if(Et(n))s=n;else{s=`let opt=${JSON.stringify(n)};`}let a=`\n\n ${s}\n\n if(_.isObject(opt)){\n\n //強制關閉動畫避免過慢顯示無法截到數據圖\n _.set(opt, 'chart.animation', false)\n _.set(opt, 'plotOptions.series.animation', false)\n // console.log('opt', opt)\n \n //plot\n Highcharts.chart('hc', opt)\n\n }\n else{\n console.log('invalid opt')\n }\n\n `;a=[a];let l=`\n\n <div id="hc" style="width:${t}px; height:${e}px;"></div>\n\n `,u=wt(i,"execJsHead","");Et(u)&&(u=[u]),u=[...u,...o],i.execJsHead=u;let c=wt(i,"execJsPost","");return Et(c)&&(c=[c]),c=[...c,...a],i.execJsPost=c,await BY(t,e,r,l,i)}});
6
+ !function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e(require("fs"),require("path"),require("puppeteer"),require("tree-kill")):"function"==typeof define&&define.amd?define(["fs","path","puppeteer","tree-kill"],e):(t="undefined"!=typeof globalThis?globalThis:t||self)["w-hc-2-png"]=e(t.fs,t.path,t.puppeteer,t["tree-kill"])}(this,function(t,e,r,n){"use strict";var i=Array.isArray,o="object"==typeof global&&global&&global.Object===Object&&global,u="object"==typeof self&&self&&self.Object===Object&&self,s=o||u||Function("return this")(),a=s.Symbol,c=Object.prototype,l=c.hasOwnProperty,f=c.toString,h=a?a.toStringTag:void 0;var p=Object.prototype.toString;var d=a?a.toStringTag:void 0;function y(t){return null==t?void 0===t?"[object Undefined]":"[object Null]":d&&d in Object(t)?function(t){var e=l.call(t,h),r=t[h];try{t[h]=void 0;var n=!0}catch(t){}var i=f.call(t);return n&&(e?t[h]=r:delete t[h]),i}(t):function(t){return p.call(t)}(t)}function b(t){return null!=t&&"object"==typeof t}function m(t){return"symbol"==typeof t||b(t)&&"[object Symbol]"==y(t)}var g=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,v=/^\w*$/;function j(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}function _(t){if(!j(t))return!1;var e=y(t);return"[object Function]"==e||"[object GeneratorFunction]"==e||"[object AsyncFunction]"==e||"[object Proxy]"==e}var w,$=s["__core-js_shared__"],S=(w=/[^.]+$/.exec($&&$.keys&&$.keys.IE_PROTO||""))?"Symbol(src)_1."+w:"";var O=Function.prototype.toString;function M(t){if(null!=t){try{return O.call(t)}catch(t){}try{return t+""}catch(t){}}return""}var x=/^\[object .+?Constructor\]$/,D=Function.prototype,P=Object.prototype,F=D.toString,k=P.hasOwnProperty,A=RegExp("^"+F.call(k).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function H(t){return!(!j(t)||(e=t,S&&S in e))&&(_(t)?A:x).test(M(t));var e}function T(t,e){var r=function(t,e){return null==t?void 0:t[e]}(t,e);return H(r)?r:void 0}var E=T(Object,"create");var N=Object.prototype.hasOwnProperty;var Y=Object.prototype.hasOwnProperty;function z(t){var e=-1,r=null==t?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}function C(t,e){return t===e||t!=t&&e!=e}function I(t,e){for(var r=t.length;r--;)if(C(t[r][0],e))return r;return-1}z.prototype.clear=function(){this.__data__=E?E(null):{},this.size=0},z.prototype.delete=function(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e},z.prototype.get=function(t){var e=this.__data__;if(E){var r=e[t];return"__lodash_hash_undefined__"===r?void 0:r}return N.call(e,t)?e[t]:void 0},z.prototype.has=function(t){var e=this.__data__;return E?void 0!==e[t]:Y.call(e,t)},z.prototype.set=function(t,e){var r=this.__data__;return this.size+=this.has(t)?0:1,r[t]=E&&void 0===e?"__lodash_hash_undefined__":e,this};var J=Array.prototype.splice;function L(t){var e=-1,r=null==t?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}L.prototype.clear=function(){this.__data__=[],this.size=0},L.prototype.delete=function(t){var e=this.__data__,r=I(e,t);return!(r<0)&&(r==e.length-1?e.pop():J.call(e,r,1),--this.size,!0)},L.prototype.get=function(t){var e=this.__data__,r=I(e,t);return r<0?void 0:e[r][1]},L.prototype.has=function(t){return I(this.__data__,t)>-1},L.prototype.set=function(t,e){var r=this.__data__,n=I(r,t);return n<0?(++this.size,r.push([t,e])):r[n][1]=e,this};var U=T(s,"Map");function W(t,e){var r,n,i=t.__data__;return("string"==(n=typeof(r=e))||"number"==n||"symbol"==n||"boolean"==n?"__proto__"!==r:null===r)?i["string"==typeof e?"string":"hash"]:i.map}function B(t){var e=-1,r=null==t?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}B.prototype.clear=function(){this.size=0,this.__data__={hash:new z,map:new(U||L),string:new z}},B.prototype.delete=function(t){var e=W(this,t).delete(t);return this.size-=e?1:0,e},B.prototype.get=function(t){return W(this,t).get(t)},B.prototype.has=function(t){return W(this,t).has(t)},B.prototype.set=function(t,e){var r=W(this,t),n=r.size;return r.set(t,e),this.size+=r.size==n?0:1,this};function V(t,e){if("function"!=typeof t||null!=e&&"function"!=typeof e)throw new TypeError("Expected a function");var r=function(){var n=arguments,i=e?e.apply(this,n):n[0],o=r.cache;if(o.has(i))return o.get(i);var u=t.apply(this,n);return r.cache=o.set(i,u)||o,u};return r.cache=new(V.Cache||B),r}V.Cache=B;var q,R,Z,G=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,K=/\\(\\)?/g,Q=(q=function(t){var e=[];return 46===t.charCodeAt(0)&&e.push(""),t.replace(G,function(t,r,n,i){e.push(n?i.replace(K,"$1"):r||t)}),e},R=V(q,function(t){return 500===Z.size&&Z.clear(),t}),Z=R.cache,R),X=Q;var tt=a?a.prototype:void 0,et=tt?tt.toString:void 0;function rt(t){if("string"==typeof t)return t;if(i(t))return function(t,e){for(var r=-1,n=null==t?0:t.length,i=Array(n);++r<n;)i[r]=e(t[r],r,t);return i}(t,rt)+"";if(m(t))return et?et.call(t):"";var e=t+"";return"0"==e&&1/t==-1/0?"-0":e}function nt(t){return null==t?"":rt(t)}function it(t,e){return i(t)?t:function(t,e){if(i(t))return!1;var r=typeof t;return!("number"!=r&&"symbol"!=r&&"boolean"!=r&&null!=t&&!m(t))||v.test(t)||!g.test(t)||null!=e&&t in Object(e)}(t,e)?[t]:X(nt(t))}function ot(t){if("string"==typeof t||m(t))return t;var e=t+"";return"0"==e&&1/t==-1/0?"-0":e}function ut(t,e,r){var n=null==t?void 0:function(t,e){for(var r=0,n=(e=it(e,t)).length;null!=t&&r<n;)t=t[ot(e[r++])];return r&&r==n?t:void 0}(t,e);return void 0===n?r:n}function st(t){return"[object String]"===Object.prototype.toString.call(t)}function at(t){return!(!st(t)||""===t)}function ct(t){return t!=t}function lt(t){let e=!1;if(at(t))e=!isNaN(Number(t));else if(function(t){return"[object Number]"===Object.prototype.toString.call(t)}(t)){if(ct(t))return!1;e=!0}return e}function ft(t){return"[object Object]"===Object.prototype.toString.call(t)}var ht=/\s/;var pt=/^\s+/;function dt(t){return t?t.slice(0,function(t){for(var e=t.length;e--&&ht.test(t.charAt(e)););return e}(t)+1).replace(pt,""):t}var yt=/^[-+]0x[0-9a-f]+$/i,bt=/^0b[01]+$/i,mt=/^0o[0-7]+$/i,gt=parseInt;function vt(t){if("number"==typeof t)return t;if(m(t))return NaN;if(j(t)){var e="function"==typeof t.valueOf?t.valueOf():t;t=j(e)?e+"":e}if("string"!=typeof t)return 0===t?t:+t;t=dt(t);var r=bt.test(t);return r||mt.test(t)?gt(t.slice(2),r?2:8):yt.test(t)?NaN:+t}var jt=1/0;function _t(t){return t?(t=vt(t))===jt||t===-1/0?17976931348623157e292*(t<0?-1:1):t==t?t:0:0===t?t:0}function wt(t){if(!lt(t))return 0;return _t(t)}function $t(t,e){for(var r=-1,n=null==t?0:t.length;++r<n&&!1!==e(t[r],r,t););return t}var St,Ot=function(t,e,r){for(var n=-1,i=Object(t),o=r(t),u=o.length;u--;){var s=o[St?u:++n];if(!1===e(i[s],s,i))break}return t},Mt=Ot;function xt(t){return b(t)&&"[object Arguments]"==y(t)}var Dt=Object.prototype,Pt=Dt.hasOwnProperty,Ft=Dt.propertyIsEnumerable,kt=xt(function(){return arguments}())?xt:function(t){return b(t)&&Pt.call(t,"callee")&&!Ft.call(t,"callee")},At=kt;var Ht="object"==typeof exports&&exports&&!exports.nodeType&&exports,Tt=Ht&&"object"==typeof module&&module&&!module.nodeType&&module,Et=Tt&&Tt.exports===Ht?s.Buffer:void 0,Nt=(Et?Et.isBuffer:void 0)||function(){return!1},Yt=/^(?:0|[1-9]\d*)$/;function zt(t,e){var r=typeof t;return!!(e=null==e?9007199254740991:e)&&("number"==r||"symbol"!=r&&Yt.test(t))&&t>-1&&t%1==0&&t<e}function Ct(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=9007199254740991}var It={};It["[object Float32Array]"]=It["[object Float64Array]"]=It["[object Int8Array]"]=It["[object Int16Array]"]=It["[object Int32Array]"]=It["[object Uint8Array]"]=It["[object Uint8ClampedArray]"]=It["[object Uint16Array]"]=It["[object Uint32Array]"]=!0,It["[object Arguments]"]=It["[object Array]"]=It["[object ArrayBuffer]"]=It["[object Boolean]"]=It["[object DataView]"]=It["[object Date]"]=It["[object Error]"]=It["[object Function]"]=It["[object Map]"]=It["[object Number]"]=It["[object Object]"]=It["[object RegExp]"]=It["[object Set]"]=It["[object String]"]=It["[object WeakMap]"]=!1;var Jt="object"==typeof exports&&exports&&!exports.nodeType&&exports,Lt=Jt&&"object"==typeof module&&module&&!module.nodeType&&module,Ut=Lt&&Lt.exports===Jt&&o.process,Wt=function(){try{var t=Lt&&Lt.require&&Lt.require("util").types;return t||Ut&&Ut.binding&&Ut.binding("util")}catch(t){}}(),Bt=Wt&&Wt.isTypedArray,Vt=Bt?function(t){return function(e){return t(e)}}(Bt):function(t){return b(t)&&Ct(t.length)&&!!It[y(t)]},qt=Vt,Rt=Object.prototype.hasOwnProperty;function Zt(t,e){var r=i(t),n=!r&&At(t),o=!r&&!n&&Nt(t),u=!r&&!n&&!o&&qt(t),s=r||n||o||u,a=s?function(t,e){for(var r=-1,n=Array(t);++r<t;)n[r]=e(r);return n}(t.length,String):[],c=a.length;for(var l in t)!e&&!Rt.call(t,l)||s&&("length"==l||o&&("offset"==l||"parent"==l)||u&&("buffer"==l||"byteLength"==l||"byteOffset"==l)||zt(l,c))||a.push(l);return a}var Gt=Object.prototype;var Kt=function(t,e){return function(r){return t(e(r))}}(Object.keys,Object),Qt=Kt,Xt=Object.prototype.hasOwnProperty;function te(t){if(r=(e=t)&&e.constructor,e!==("function"==typeof r&&r.prototype||Gt))return Qt(t);var e,r,n=[];for(var i in Object(t))Xt.call(t,i)&&"constructor"!=i&&n.push(i);return n}function ee(t){return null!=t&&Ct(t.length)&&!_(t)}function re(t){return ee(t)?Zt(t):te(t)}var ne=function(t,e){return function(r,n){if(null==r)return r;if(!ee(r))return t(r,n);for(var i=r.length,o=e?i:-1,u=Object(r);(e?o--:++o<i)&&!1!==n(u[o],o,u););return r}}(function(t,e){return t&&Mt(t,e,re)}),ie=ne;function oe(t){return t}function ue(t,e){var r;return(i(t)?$t:ie)(t,"function"==typeof(r=e)?r:oe)}var se=T(s,"DataView"),ae=T(s,"Promise"),ce=T(s,"Set"),le=T(s,"WeakMap"),fe="[object Map]",he="[object Promise]",pe="[object Set]",de="[object WeakMap]",ye="[object DataView]",be=M(se),me=M(U),ge=M(ae),ve=M(ce),je=M(le),_e=y;(se&&_e(new se(new ArrayBuffer(1)))!=ye||U&&_e(new U)!=fe||ae&&_e(ae.resolve())!=he||ce&&_e(new ce)!=pe||le&&_e(new le)!=de)&&(_e=function(t){var e=y(t),r="[object Object]"==e?t.constructor:void 0,n=r?M(r):"";if(n)switch(n){case be:return ye;case me:return fe;case ge:return he;case ve:return pe;case je:return de}return e});var we=_e;var $e,Se=($e="length",function(t){return null==t?void 0:t[$e]}),Oe=RegExp("[\\u200d\\ud800-\\udfff\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff\\ufe0e\\ufe0f]");var Me="\\ud800-\\udfff",xe="["+Me+"]",De="[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]",Pe="\\ud83c[\\udffb-\\udfff]",Fe="[^"+Me+"]",ke="(?:\\ud83c[\\udde6-\\uddff]){2}",Ae="[\\ud800-\\udbff][\\udc00-\\udfff]",He="(?:"+De+"|"+Pe+")"+"?",Te="[\\ufe0e\\ufe0f]?",Ee=Te+He+("(?:\\u200d(?:"+[Fe,ke,Ae].join("|")+")"+Te+He+")*"),Ne="(?:"+[Fe+De+"?",De,ke,Ae,xe].join("|")+")",Ye=RegExp(Pe+"(?="+Pe+")|"+Ne+Ee,"g");function ze(t){return function(t){return Oe.test(t)}(t)?function(t){for(var e=Ye.lastIndex=0;Ye.test(t);)++e;return e}(t):Se(t)}function Ce(t){if(null==t)return 0;if(ee(t))return"string"==typeof(e=t)||!i(e)&&b(e)&&"[object String]"==y(e)?ze(t):t.length;var e,r=we(t);return"[object Map]"==r||"[object Set]"==r?t.size:te(t).length}function Ie(t){return"[object Array]"===Object.prototype.toString.call(t)}function Je(t){return!!function(t){return"[object Undefined]"===Object.prototype.toString.call(t)}(t)||(!!function(t){return"[object Null]"===Object.prototype.toString.call(t)}(t)||(!!function(t){if(ft(t)){for(let e in t)return!1;return!0}return!1}(t)||(!!function(t){return!(!st(t)||""!==t)}(t)||(!!function(t){return!!Ie(t)&&0===t.length}(t)||!!ct(t)))))}function Le(t){return!!Ie(t)&&(0!==t.length&&(1!==t.length||!Je(t[0])))}function Ue(t){var e=_t(t),r=e%1;return e==e?r?e-r:e:0}function We(t){return!!lt(t)&&(t=wt(t),"number"==typeof(e=t)&&e==Ue(e));var e}var Be=s.isFinite,Ve=Math.min;var qe=function(t){var e=Math[t];return function(t,r){if(t=vt(t),(r=null==r?0:Ve(Ue(r),292))&&Be(t)){var n=(nt(t)+"e").split("e");return+((n=(nt(e(n[0]+"e"+(+n[1]+r)))+"e").split("e"))[0]+"e"+(+n[1]-r))}return e(t)}}("round"),Re=qe;function Ze(t){if(!lt(t))return 0;t=wt(t);let e=Re(t);return"0"===String(e)?0:e}function Ge(t){if(!We(t))return!1;return Ze(t)>0}function Ke(t){return!0===(e=t)||!1===e||b(e)&&"[object Boolean]"==y(e);var e}function Qe(t){let e,r=Object.prototype.toString.call(t);if(e="[object Promise]"===r,e)return!0;if("[object Function]"!==r)return!1;try{e="function"!=typeof t.subscribe&&"function"==typeof t.then}catch(t){}return e}"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self&&self;function Xe(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var tr={exports:{}};!function(t){t.exports=function(){var t=1e3,e=6e4,r=36e5,n="millisecond",i="second",o="minute",u="hour",s="day",a="week",c="month",l="quarter",f="year",h="date",p="Invalid Date",d=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,y=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,b={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(t){var e=["th","st","nd","rd"],r=t%100;return"["+t+(e[(r-20)%10]||e[r]||e[0])+"]"}},m=function(t,e,r){var n=String(t);return!n||n.length>=e?t:""+Array(e+1-n.length).join(r)+t},g={s:m,z:function(t){var e=-t.utcOffset(),r=Math.abs(e),n=Math.floor(r/60),i=r%60;return(e<=0?"+":"-")+m(n,2,"0")+":"+m(i,2,"0")},m:function t(e,r){if(e.date()<r.date())return-t(r,e);var n=12*(r.year()-e.year())+(r.month()-e.month()),i=e.clone().add(n,c),o=r-i<0,u=e.clone().add(n+(o?-1:1),c);return+(-(n+(r-i)/(o?i-u:u-i))||0)},a:function(t){return t<0?Math.ceil(t)||0:Math.floor(t)},p:function(t){return{M:c,y:f,w:a,d:s,D:h,h:u,m:o,s:i,ms:n,Q:l}[t]||String(t||"").toLowerCase().replace(/s$/,"")},u:function(t){return void 0===t}},v="en",j={};j[v]=b;var _="$isDayjsObject",w=function(t){return t instanceof M||!(!t||!t[_])},$=function t(e,r,n){var i;if(!e)return v;if("string"==typeof e){var o=e.toLowerCase();j[o]&&(i=o),r&&(j[o]=r,i=o);var u=e.split("-");if(!i&&u.length>1)return t(u[0])}else{var s=e.name;j[s]=e,i=s}return!n&&i&&(v=i),i||!n&&v},S=function(t,e){if(w(t))return t.clone();var r="object"==typeof e?e:{};return r.date=t,r.args=arguments,new M(r)},O=g;O.l=$,O.i=w,O.w=function(t,e){return S(t,{locale:e.$L,utc:e.$u,x:e.$x,$offset:e.$offset})};var M=function(){function b(t){this.$L=$(t.locale,null,!0),this.parse(t),this.$x=this.$x||t.x||{},this[_]=!0}var m=b.prototype;return m.parse=function(t){this.$d=function(t){var e=t.date,r=t.utc;if(null===e)return new Date(NaN);if(O.u(e))return new Date;if(e instanceof Date)return new Date(e);if("string"==typeof e&&!/Z$/i.test(e)){var n=e.match(d);if(n){var i=n[2]-1||0,o=(n[7]||"0").substring(0,3);return r?new Date(Date.UTC(n[1],i,n[3]||1,n[4]||0,n[5]||0,n[6]||0,o)):new Date(n[1],i,n[3]||1,n[4]||0,n[5]||0,n[6]||0,o)}}return new Date(e)}(t),this.init()},m.init=function(){var t=this.$d;this.$y=t.getFullYear(),this.$M=t.getMonth(),this.$D=t.getDate(),this.$W=t.getDay(),this.$H=t.getHours(),this.$m=t.getMinutes(),this.$s=t.getSeconds(),this.$ms=t.getMilliseconds()},m.$utils=function(){return O},m.isValid=function(){return!(this.$d.toString()===p)},m.isSame=function(t,e){var r=S(t);return this.startOf(e)<=r&&r<=this.endOf(e)},m.isAfter=function(t,e){return S(t)<this.startOf(e)},m.isBefore=function(t,e){return this.endOf(e)<S(t)},m.$g=function(t,e,r){return O.u(t)?this[e]:this.set(r,t)},m.unix=function(){return Math.floor(this.valueOf()/1e3)},m.valueOf=function(){return this.$d.getTime()},m.startOf=function(t,e){var r=this,n=!!O.u(e)||e,l=O.p(t),p=function(t,e){var i=O.w(r.$u?Date.UTC(r.$y,e,t):new Date(r.$y,e,t),r);return n?i:i.endOf(s)},d=function(t,e){return O.w(r.toDate()[t].apply(r.toDate("s"),(n?[0,0,0,0]:[23,59,59,999]).slice(e)),r)},y=this.$W,b=this.$M,m=this.$D,g="set"+(this.$u?"UTC":"");switch(l){case f:return n?p(1,0):p(31,11);case c:return n?p(1,b):p(0,b+1);case a:var v=this.$locale().weekStart||0,j=(y<v?y+7:y)-v;return p(n?m-j:m+(6-j),b);case s:case h:return d(g+"Hours",0);case u:return d(g+"Minutes",1);case o:return d(g+"Seconds",2);case i:return d(g+"Milliseconds",3);default:return this.clone()}},m.endOf=function(t){return this.startOf(t,!1)},m.$set=function(t,e){var r,a=O.p(t),l="set"+(this.$u?"UTC":""),p=(r={},r[s]=l+"Date",r[h]=l+"Date",r[c]=l+"Month",r[f]=l+"FullYear",r[u]=l+"Hours",r[o]=l+"Minutes",r[i]=l+"Seconds",r[n]=l+"Milliseconds",r)[a],d=a===s?this.$D+(e-this.$W):e;if(a===c||a===f){var y=this.clone().set(h,1);y.$d[p](d),y.init(),this.$d=y.set(h,Math.min(this.$D,y.daysInMonth())).$d}else p&&this.$d[p](d);return this.init(),this},m.set=function(t,e){return this.clone().$set(t,e)},m.get=function(t){return this[O.p(t)]()},m.add=function(n,l){var h,p=this;n=Number(n);var d=O.p(l),y=function(t){var e=S(p);return O.w(e.date(e.date()+Math.round(t*n)),p)};if(d===c)return this.set(c,this.$M+n);if(d===f)return this.set(f,this.$y+n);if(d===s)return y(1);if(d===a)return y(7);var b=(h={},h[o]=e,h[u]=r,h[i]=t,h)[d]||1,m=this.$d.getTime()+n*b;return O.w(m,this)},m.subtract=function(t,e){return this.add(-1*t,e)},m.format=function(t){var e=this,r=this.$locale();if(!this.isValid())return r.invalidDate||p;var n=t||"YYYY-MM-DDTHH:mm:ssZ",i=O.z(this),o=this.$H,u=this.$m,s=this.$M,a=r.weekdays,c=r.months,l=r.meridiem,f=function(t,r,i,o){return t&&(t[r]||t(e,n))||i[r].slice(0,o)},h=function(t){return O.s(o%12||12,t,"0")},d=l||function(t,e,r){var n=t<12?"AM":"PM";return r?n.toLowerCase():n};return n.replace(y,function(t,n){return n||function(t){switch(t){case"YY":return String(e.$y).slice(-2);case"YYYY":return O.s(e.$y,4,"0");case"M":return s+1;case"MM":return O.s(s+1,2,"0");case"MMM":return f(r.monthsShort,s,c,3);case"MMMM":return f(c,s);case"D":return e.$D;case"DD":return O.s(e.$D,2,"0");case"d":return String(e.$W);case"dd":return f(r.weekdaysMin,e.$W,a,2);case"ddd":return f(r.weekdaysShort,e.$W,a,3);case"dddd":return a[e.$W];case"H":return String(o);case"HH":return O.s(o,2,"0");case"h":return h(1);case"hh":return h(2);case"a":return d(o,u,!0);case"A":return d(o,u,!1);case"m":return String(u);case"mm":return O.s(u,2,"0");case"s":return String(e.$s);case"ss":return O.s(e.$s,2,"0");case"SSS":return O.s(e.$ms,3,"0");case"Z":return i}return null}(t)||i.replace(":","")})},m.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},m.diff=function(n,h,p){var d,y=this,b=O.p(h),m=S(n),g=(m.utcOffset()-this.utcOffset())*e,v=this-m,j=function(){return O.m(y,m)};switch(b){case f:d=j()/12;break;case c:d=j();break;case l:d=j()/3;break;case a:d=(v-g)/6048e5;break;case s:d=(v-g)/864e5;break;case u:d=v/r;break;case o:d=v/e;break;case i:d=v/t;break;default:d=v}return p?d:O.a(d)},m.daysInMonth=function(){return this.endOf(c).$D},m.$locale=function(){return j[this.$L]},m.locale=function(t,e){if(!t)return this.$L;var r=this.clone(),n=$(t,e,!0);return n&&(r.$L=n),r},m.clone=function(){return O.w(this.$d,this)},m.toDate=function(){return new Date(this.valueOf())},m.toJSON=function(){return this.isValid()?this.toISOString():null},m.toISOString=function(){return this.$d.toISOString()},m.toString=function(){return this.$d.toUTCString()},b}(),x=M.prototype;return S.prototype=x,[["$ms",n],["$s",i],["$m",o],["$H",u],["$W",s],["$M",c],["$y",f],["$D",h]].forEach(function(t){x[t[1]]=function(e){return this.$g(e,t[0],t[1])}}),S.extend=function(t,e){return t.$i||(t(e,M,S),t.$i=!0),S},S.locale=$,S.isDayjs=w,S.unix=function(t){return S(1e3*t)},S.en=j[v],S.Ls=j,S.p={},S}()}(tr);var er=Xe(tr.exports);function rr(){if(!function(t){let e=Object.prototype.toString.call(t);return"[object Function]"===e||"[object AsyncFunction]"===e}(er))throw new Error("invalid dayjs");return er().format("YYYYMMDDHHmmss")}let nr="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz".split(""),ir=nr.length;function or(t=10){lt(t)||(t=10);let e=function(){let t,e,r=new Promise(function(){t=arguments[0],e=arguments[1]});return r.resolve=t,r.reject=e,r}();return setTimeout(function(){e.resolve()},t),e}function ur(e){return function(t,e={}){let r=ut(e,"fs");return!!r.existsSync(t)&&!r.lstatSync(t).isDirectory()&&!r.lstatSync(t).isSymbolicLink()}(e,{fs:t})}function sr(t,e={}){let r=ut(e,"fs");if(!r.existsSync(t))return!1;let n=r.lstatSync(t);return!n.isFile()&&!n.isSymbolicLink()}function ar(e){return sr(e,{fs:t})}async function cr(e,r={}){return await async function(t,e={}){let r=ut(e,"numRetry");Ge(r)||(r=5),r=Ze(r);let n=ut(e,"fs",null);if(!n.existsSync(t))return"folder does not exist: "+t;if(!sr(t,{fs:n}))return Promise.reject("input path is not a folder: "+t);for(let e=0;e<r;e++)try{n.rmSync(t,{recursive:!0,force:!0});break}catch(t){if("EBUSY"!==t.code)return Promise.reject(t);await or(300)}return"done: "+t}(e,{fs:t,...r})}let lr=e.resolve();async function fr(i=700,o=400,u=3,s="",a={}){if("win32"!==process.platform)return Promise.reject("operating system is not windows");if(!lt(i))return Promise.reject("width is not a number");if((i=wt(i))<=0)return Promise.reject("width <= 0");if(!lt(o))return Promise.reject("height is not a number");if((o=wt(o))<=0)return Promise.reject("height <= 0");if(!lt(u))return Promise.reject("scale is not a number");if((u=wt(u))<=0)return Promise.reject("scale <= 0");if(!at(s))return Promise.reject("html is not an effective string");let c=s,l=ut(a,"modeHeadless");!0!==l&&!1!==l&&"new"!==l&&"shell"!==l&&(l="new");let f=ut(a,"scriptsHead");Le(f)||(f=[]);let h="";ue(f,t=>{h+=`<script src="${t}"><\/script>\n`});let p=ut(a,"execJsHead");at(p)&&(p=[p]),Le(p)||(p=[]);let d="";ue(p,t=>{d+=`<script>${t}<\/script>\n\n`});let y=ut(a,"execJsPost");at(y)&&(y=[y]),Le(y)||(y=[]);let b="";ue(y,t=>{b+=`<script>${t}<\/script>\n\n`});let m=`${lr}/node_modules/w-html2png/chrome/`,g=`${lr}/chrome/`;ar(m)&&(g=m);let v=`${`${g}portable/App/Chrome-bin/138.0.7204.97/`}chrome.exe`;if(!ur(v))throw new Error(`invalid fpExe[${v}], need to run postinstall`);let j=v,_=ut(a,"retry");Ge(_)||(_=3),_=Ze(_);let w=ut(a,"writeError");Ke(w)||(w=!1);let $=`${rr()}-${function(t=32){let e=[];t=Ge(t)?Ze(t):32;for(let r=0;r<t;r++)e[r]=nr[0|Math.random()*ir];return e.join("")}()}`,S=0,O=async()=>{let s=null,a="";S++;let f=`${$}-${S}`;return await(async()=>{let s=[],a=[],p=async t=>{let e=[],i=`./_puppeteer_profile_${f}`,o={headless:l,slowMo:20,protocolTimeout:6e4,userDataDir:i,args:["--no-sandbox","--incognito","--disable-gpu","--disable-software-rasterizer","--disable-setuid-sandbox","--disable-dev-shm-usage","--disable-sync","--disable-extensions","--disable-default-apps","--disable-features=VizDisplayCompositor","--metrics-recording-only","--mute-audio","--no-first-run","--safebrowsing-disable-auto-update"]};at(j)&&(o.executablePath=j);let u=null,s=null,a=null;try{u=await r.launch(o),s=u.process(),a=ut(s,"pid","")}catch(t){e.push({anchor:"puppeteer.launch(puppeteerOpt)",err:t})}if(null!==u)try{let e=t(u);Qe(e)&&(e=await e)}catch(t){e.push({anchor:"fun(browser)",err:t})}if(null!==u)try{await u.close()}catch(t){e.push({anchor:"browser.close()",err:t})}if(We(c=a)&&Ze(c)>=0)try{n(a,"SIGKILL")}catch(t){}var c;try{await cr(i)}catch(t){e.push({anchor:"fsDeleteFolderSafe(fd)",err:t})}return Ce(e)>0?{state:"error",msg:e}:{state:"success",msg:""}},y="",m=null,g=null,v=null;if(m=await(async r=>{let n=[],i=`./whpic_${f}.png`,o=e.resolve(i),u=`./whweb_${f}.html`,s=e.resolve(u),a='\n<!DOCTYPE html>\n<html>\n<head>\n <meta charset="UTF-8">\n <title>highcharts to png</title>\n\n <script src="https://cdn.jsdelivr.net/npm/lodash@4.17.21/lodash.min.js"><\/script>\n\n <script src="https://cdn.jsdelivr.net/npm/wsemi/dist/wsemi.umd.js"><\/script>\n <script>\n let w = wsemi\n <\/script>\n\n {cScriptsHead}\n\n {cExecJsHead}\n\n</head>\n<body style="padding:0; margin:0;">\n\n <div id="pl">\n {cHtml}\n </div>\n\n {cExecJsPost}\n\n</body>\n</html>\n';a=a.replace("{cHtml}",c),a=a.replace("{cScriptsHead}",h),a=a.replace("{cExecJsHead}",d),a=a.replace("{cExecJsPost}",b);try{t.writeFileSync(s,a,"utf8")}catch(t){n.push({anchor:"fs.writeFileSync(fpHtml, g, 'utf8')",err:t})}if(0===Ce(n))try{let t=r(s,o);Qe(t)&&(t=await t)}catch(t){n.push({anchor:"fun(fpHtml, fpOut)",err:t})}if(ur(s))try{t.unlinkSync(s)}catch(t){}if(ur(o))try{t.unlinkSync(o)}catch(t){}return Ce(n)>0?{state:"error",msg:n}:{state:"success",msg:""}})(async(e,r)=>{if(g=await p(async n=>{v=await(async(t,e)=>{let r=[],n=null;try{n=await t.newPage(),n.setDefaultNavigationTimeout(6e4)}catch(t){r.push({anchor:"browser.newPage()",err:t})}if(null!==n)try{let t=e(n);Qe(t)&&(t=await t)}catch(t){r.push({anchor:"fun(page)",err:t})}if(null!==n)try{await n.close()}catch(t){r.push({anchor:"page.close()",err:t})}return Ce(r)>0?{state:"error",msg:r}:{state:"success",msg:""}})(n,async t=>{let n={x:0,y:0,width:Number(i),height:Number(o),deviceScaleFactor:Number(u)};await t.goto(e,{waitUntil:["domcontentloaded","networkidle2"],timeout:6e4}),await t.setViewport(n),await t.screenshot({path:r,timeout:6e4})}).catch(e=>{w&&t.writeFileSync(`./_err_${f}_supplyPage.json`,e.message,"utf8")})}).catch(e=>{w&&t.writeFileSync(`./_err_${f}_supplyBrowser.json`,e.message,"utf8")}),"error"!==ut(g,"state","")){if(ur(r)){try{y=t.readFileSync(r,{encoding:"base64"})}catch(t){return void a.push({anchor:"fs.readFileSync(fpOut, { encoding: 'base64' })",err:t})}return null}a.push({anchor:"fsIsFile(fpOut)",err:new Error(`no file[${r}]`)})}}).catch(e=>{w&&t.writeFileSync(`./_err_${f}_supplyHtml.json`,e.message,"utf8")}),"error"===ut(m,"state","")&&(s=[...s,...m.msg]),"error"===ut(g,"state","")&&(s=[...s,...g.msg]),"error"===ut(v,"state","")&&(s=[...s,...v.msg]),Ce(a)>0&&(s=[...s,...a]),Ce(s)>0){let e="";return ue(s,t=>{let r=`${ut(t,"err.message","")} in ${t.anchor}`;e+=r+"\n"}),w&&t.writeFileSync(`./_err_${f}_all.json`,e,"utf8"),Promise.reject(e)}return at(y)?y:Promise.reject("b64 is not an effective string")})().then(t=>{a=t}).catch(t=>{s=t}).finally(()=>{let e=`./whweb_${f}.html`;w&&ur(e)&&t.writeFileSync(`./_err_${f}_fnHtml.json`,`can not delete html[${e}]`,"utf8");let r=`./_puppeteer_profile_${f}`;w&&ar(r)&&t.writeFileSync(`./_err_${f}_profile.json`,`can not delete profile[${r}]`,"utf8");let n=`./whpic_${f}.png`;w&&ur(n)&&t.writeFileSync(`./_err_${f}_fnPng.json`,`can not delete png[${n}]`,"utf8")}),{state:null===s?"success":"error",message:s,b64:a}};return await(async()=>{let t=null,e="";for(;;){let r=await O().catch(()=>{});if("success"===ut(r,"state","")){e=r.b64;break}if(S>=_){t=r.message;break}await or(5e3)}return null!==t?Promise.reject(t):e})()}let hr=t.readFileSync("./node_modules/highcharts/highcharts.js","utf8"),pr=t.readFileSync("./node_modules/highcharts/highcharts-more.js","utf8"),dr=t.readFileSync("./node_modules/highcharts/modules/stock.js","utf8"),yr=t.readFileSync("./node_modules/highcharts/modules/annotations.js","utf8"),br=t.readFileSync("./node_modules/highcharts/modules/heatmap.js","utf8"),mr=t.readFileSync("./node_modules/highcharts/modules/boost.js","utf8"),gr=t.readFileSync("./node_modules/highcharts/modules/boost-canvas.js","utf8");return async function(t=700,e=400,r=3,n={},i={}){if(!lt(t))return Promise.reject("width is not a number");if((t=wt(t))<=0)return Promise.reject("width <= 0");if(!lt(e))return Promise.reject("height is not a number");if((e=wt(e))<=0)return Promise.reject("height <= 0");if(!lt(r))return Promise.reject("scale is not a number");if((r=wt(r))<=0)return Promise.reject("scale <= 0");if(!function(t){if(ft(t)){for(let e in t)return!0;return!1}return!1}(n)&&!at(n))return Promise.reject("opt is not an effective object or string");let o=[hr,pr,dr,yr,br,mr,gr],u="";if(at(n))u=n;else{u=`let opt=${JSON.stringify(n)};`}let s=`\n\n ${u}\n\n if(_.isObject(opt)){\n\n //強制關閉動畫避免過慢顯示無法截到數據圖\n _.set(opt, 'chart.animation', false)\n _.set(opt, 'plotOptions.series.animation', false)\n // console.log('opt', opt)\n \n //plot\n Highcharts.chart('hc', opt)\n\n }\n else{\n console.log('invalid opt')\n }\n\n `;s=[s];let a=`\n\n <div id="hc" style="width:${t}px; height:${e}px;"></div>\n\n `,c=ut(i,"execJsHead","");at(c)&&(c=[c]),c=[...c,...o],i.execJsHead=c;let l=ut(i,"execJsPost","");return at(l)&&(l=[l]),l=[...l,...s],i.execJsPost=l,await fr(t,e,r,a,i)}});
110
7
  //# sourceMappingURL=w-hc-2-png.umd.js.map