@transai/connector-runner-file 0.19.0 → 0.19.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +4 -0
- package/index.cjs +288 -48
- package/index.cjs.map +4 -4
- package/libs/connector-runner-file/src/lib/actions/action-delete-file.d.ts +3 -2
- package/libs/connector-runner-file/src/lib/actions/action-extract-archive.d.ts +17 -0
- package/libs/connector-runner-file/src/lib/actions/action-list-directory.d.ts +17 -0
- package/libs/connector-runner-file/src/lib/functions.d.ts +2 -0
- package/package.json +4 -1
package/index.cjs
CHANGED
|
@@ -1,52 +1,292 @@
|
|
|
1
|
-
"use strict";var kg=Object.create;var en=Object.defineProperty;var Bg=Object.getOwnPropertyDescriptor;var $g=Object.getOwnPropertyNames;var Ug=Object.getPrototypeOf,Vg=Object.prototype.hasOwnProperty;var S=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),Hg=(t,e)=>{for(var r in e)en(t,r,{get:e[r],enumerable:!0})},wa=(t,e,r,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of $g(e))!Vg.call(t,i)&&i!==r&&en(t,i,{get:()=>e[i],enumerable:!(n=Bg(e,i))||n.enumerable});return t};var Te=(t,e,r)=>(r=t!=null?kg(Ug(t)):{},wa(e||!t||!t.__esModule?en(r,"default",{value:t,enumerable:!0}):r,t)),Wg=t=>wa(en({},"__esModule",{value:!0}),t);var ye=S((RD,Sa)=>{"use strict";var Yi=class t extends Error{constructor(e){super(`Format functions must be synchronous taking a two arguments: (info, opts)
|
|
2
|
-
Found: ${e.toString().split(`
|
|
1
|
+
"use strict";var mde=Object.create;var Jg=Object.defineProperty;var gde=Object.getOwnPropertyDescriptor;var yde=Object.getOwnPropertyNames;var _de=Object.getPrototypeOf,bde=Object.prototype.hasOwnProperty;var Y=(e,t)=>()=>(e&&(t=e(e=0)),t);var E=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),Nn=(e,t)=>{for(var r in t)Jg(e,r,{get:t[r],enumerable:!0})},vL=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of yde(t))!bde.call(e,i)&&i!==r&&Jg(e,i,{get:()=>t[i],enumerable:!(n=gde(t,i))||n.enumerable});return e};var z=(e,t,r)=>(r=e!=null?mde(_de(e)):{},vL(t||!e||!e.__esModule?Jg(r,"default",{value:e,enumerable:!0}):r,e)),Ve=e=>vL(Jg({},"__esModule",{value:!0}),e);var ry=E((Yut,AL)=>{"use strict";var ty=require("stream"),wde=require("util"),Sde="function";function ia(){if(!(this instanceof ia))return new ia;ty.Duplex.call(this,{decodeStrings:!1,objectMode:!0}),this.buffer=Buffer.from("");let e=this;e.on("finish",function(){e.finished=!0,e.emit("chunk",!1)})}wde.inherits(ia,ty.Duplex);ia.prototype._write=function(e,t,r){this.buffer=Buffer.concat([this.buffer,e]),this.cb=r,this.emit("chunk")};ia.prototype.stream=function(e,t){let r=ty.PassThrough(),n,i=this;function o(){if(typeof i.cb===Sde){let a=i.cb;return i.cb=void 0,a()}}function s(){let a;if(i.buffer&&i.buffer.length){if(typeof e=="number")a=i.buffer.slice(0,e),i.buffer=i.buffer.slice(e),e-=a.length,n=n||!e;else{let c=i.buffer.indexOf(e);if(c!==-1)i.match=c,t&&(c=c+e.length),a=i.buffer.slice(0,c),i.buffer=i.buffer.slice(c),n=!0;else{let u=i.buffer.length-e.length;u<=0?o():(a=i.buffer.slice(0,u),i.buffer=i.buffer.slice(u))}}a&&r.write(a,function(){(i.buffer.length===0||e.length&&i.buffer.length<=e.length)&&o()})}if(n)i.removeListener("chunk",s),r.end();else if(i.finished){i.removeListener("chunk",s),i.emit("error",new Error("FILE_ENDED"));return}}return i.on("chunk",s),s(),r};ia.prototype.pull=function(e,t){if(e===0)return Promise.resolve("");if(!isNaN(e)&&this.buffer.length>e){let a=this.buffer.slice(0,e);return this.buffer=this.buffer.slice(e),Promise.resolve(a)}let r=Buffer.from(""),n=this,i=new ty.Transform;i._transform=function(a,c,u){r=Buffer.concat([r,a]),u()};let o,s;return new Promise(function(a,c){if(o=c,s=function(u){n.__emittedError=u,c(u)},n.finished)return c(new Error("FILE_ENDED"));n.once("error",s),n.stream(e,t).on("error",c).pipe(i).on("finish",function(){a(r)}).on("error",c)}).finally(function(){n.removeListener("error",o),n.removeListener("error",s)})};ia.prototype._read=function(){};AL.exports=ia});var OL=E((Xut,PL)=>{"use strict";var RL=require("stream"),vde=require("util");function tp(){if(!(this instanceof tp))return new tp;RL.Transform.call(this)}vde.inherits(tp,RL.Transform);tp.prototype._transform=function(e,t,r){r()};PL.exports=tp});var ny=E((Jut,IL)=>{"use strict";var Cde=require("stream");IL.exports=function(e){return new Promise(function(t,r){let n=[],i=Cde.Transform().on("finish",function(){t(Buffer.concat(n))}).on("error",r);i._transform=function(o,s,a){n.push(o),a()},e.on("error",r).pipe(i)})}});var rp=E((Qut,DL)=>{"use strict";var xde=function(e,t,r){let n;switch(r){case 1:n=e.readUInt8(t);break;case 2:n=e.readUInt16LE(t);break;case 4:n=e.readUInt32LE(t);break;case 8:n=Number(e.readBigUInt64LE(t));break;default:throw new Error("Unsupported UInt LE size!")}return n},Tde=function(e,t){let r={},n=0;for(let[i,o]of t)e.length>=n+o?r[i]=xde(e,n,o):r[i]=null,n+=o;return r};DL.exports={parse:Tde}});var iy=E((Zut,NL)=>{"use strict";var kL=rp();NL.exports=function(e,t){let r;for(;!r&&e&&e.length;){let n=kL.parse(e,[["signature",2],["partSize",2]]);if(n.signature===1){let i=[];t.uncompressedSize===4294967295&&i.push(["uncompressedSize",8]),t.compressedSize===4294967295&&i.push(["compressedSize",8]),t.offsetToLocalFileHeader===4294967295&&i.push(["offsetToLocalFileHeader",8]),r=kL.parse(e.slice(4),i)}else e=e.slice(n.partSize+4)}return r=r||{},t.compressedSize===4294967295&&(t.compressedSize=r.compressedSize),t.uncompressedSize===4294967295&&(t.uncompressedSize=r.uncompressedSize),t.offsetToLocalFileHeader===4294967295&&(t.offsetToLocalFileHeader=r.offsetToLocalFileHeader),r}});var oy=E((elt,ML)=>{"use strict";ML.exports=function(t,r){let n=t&31,i=t>>5&15,o=(t>>9&127)+1980,s=r?(r&31)*2:0,a=r?r>>5&63:0,c=r?r>>11:0;return new Date(Date.UTC(o,i-1,n,c,a,s))}});var sy=E((tlt,FL)=>{"use strict";var Ade=require("util"),Rde=require("zlib"),jx=require("stream"),LL=ry(),Pde=OL(),Ode=ny(),Ide=iy(),Dde=oy(),kde=jx.pipeline,np=rp(),BL=Buffer.alloc(4);BL.writeUInt32LE(101010256,0);function Zi(e){if(!(this instanceof Zi))return new Zi(e);let t=this;t._opts=e||{verbose:!1},LL.call(t,t._opts),t.on("finish",function(){t.emit("end"),t.emit("close")}),t._readRecord().catch(function(r){(!t.__emittedError||t.__emittedError!==r)&&t.emit("error",r)})}Ade.inherits(Zi,LL);Zi.prototype._readRecord=function(){let e=this;return e.pull(4).then(function(t){if(t.length===0)return;let r=t.readUInt32LE(0);if(r===875721283)return e._readCrxHeader();if(r===67324752)return e._readFile();if(r===33639248)return e.reachedCD=!0,e._readCentralDirectoryFileHeader();if(r===101010256)return e._readEndOfCentralDirectoryRecord();if(e.reachedCD)return e.pull(BL,!0).then(function(){return e._readEndOfCentralDirectoryRecord()});e.emit("error",new Error("invalid signature: 0x"+r.toString(16)))}).then((function(t){if(t)return e._readRecord()}))};Zi.prototype._readCrxHeader=function(){let e=this;return e.pull(12).then(function(t){return e.crxHeader=np.parse(t,[["version",4],["pubKeyLength",4],["signatureLength",4]]),e.pull(e.crxHeader.pubKeyLength+e.crxHeader.signatureLength)}).then(function(t){return e.crxHeader.publicKey=t.slice(0,e.crxHeader.pubKeyLength),e.crxHeader.signature=t.slice(e.crxHeader.pubKeyLength),e.emit("crx-header",e.crxHeader),!0})};Zi.prototype._readFile=function(){let e=this;return e.pull(26).then(function(t){let r=np.parse(t,[["versionsNeededToExtract",2],["flags",2],["compressionMethod",2],["lastModifiedTime",2],["lastModifiedDate",2],["crc32",4],["compressedSize",4],["uncompressedSize",4],["fileNameLength",2],["extraFieldLength",2]]);return r.lastModifiedDateTime=Dde(r.lastModifiedDate,r.lastModifiedTime),e.crxHeader&&(r.crxHeader=e.crxHeader),e.pull(r.fileNameLength).then(function(n){let i=n.toString("utf8"),o=jx.PassThrough(),s=!1;return o.autodrain=function(){s=!0;let a=o.pipe(Pde());return a.promise=function(){return new Promise(function(c,u){a.on("finish",c),a.on("error",u)})},a},o.buffer=function(){return Ode(o)},o.path=i,o.props={},o.props.path=i,o.props.pathBuffer=n,o.props.flags={isUnicode:(r.flags&2048)!=0},o.type=r.uncompressedSize===0&&/[/\\]$/.test(i)?"Directory":"File",e._opts.verbose&&(o.type==="Directory"?console.log(" creating:",i):o.type==="File"&&(r.compressionMethod===0?console.log(" extracting:",i):console.log(" inflating:",i))),e.pull(r.extraFieldLength).then(function(a){let c=Ide(a,r);o.vars=r,o.extra=c,e._opts.forceStream?e.push(o):(e.emit("entry",o),(e._readableState.pipesCount||e._readableState.pipes&&e._readableState.pipes.length)&&e.push(o)),e._opts.verbose&&console.log({filename:i,vars:r,extra:c});let u=!(r.flags&8)||r.compressedSize>0,l;o.__autodraining=s;let d=r.compressionMethod&&!s?Rde.createInflateRaw():jx.PassThrough();return u?(o.size=r.uncompressedSize,l=r.compressedSize):(l=Buffer.alloc(4),l.writeUInt32LE(134695760,0)),new Promise(function(h,f){kde(e.stream(l),d,o,function(p){return p?f(p):u?h(u):e._processDataDescriptor(o).then(h).catch(f)})})})})})};Zi.prototype._processDataDescriptor=function(e){return this.pull(16).then(function(r){let n=np.parse(r,[["dataDescriptorSignature",4],["crc32",4],["compressedSize",4],["uncompressedSize",4]]);return e.size=n.uncompressedSize,!0})};Zi.prototype._readCentralDirectoryFileHeader=function(){let e=this;return e.pull(42).then(function(t){let r=np.parse(t,[["versionMadeBy",2],["versionsNeededToExtract",2],["flags",2],["compressionMethod",2],["lastModifiedTime",2],["lastModifiedDate",2],["crc32",4],["compressedSize",4],["uncompressedSize",4],["fileNameLength",2],["extraFieldLength",2],["fileCommentLength",2],["diskNumber",2],["internalFileAttributes",2],["externalFileAttributes",4],["offsetToLocalFileHeader",4]]);return e.pull(r.fileNameLength).then(function(n){return r.fileName=n.toString("utf8"),e.pull(r.extraFieldLength)}).then(function(){return e.pull(r.fileCommentLength)}).then(function(){return!0})})};Zi.prototype._readEndOfCentralDirectoryRecord=function(){let e=this;return e.pull(18).then(function(t){let r=np.parse(t,[["diskNumber",2],["diskStart",2],["numberOfRecordsOnDisk",2],["numberOfRecords",2],["sizeOfCentralDirectory",4],["offsetToStartOfCentralDirectory",4],["commentLength",2]]);return e.pull(r.commentLength).then(function(){e.end(),e.push(null)})})};Zi.prototype.promise=function(){let e=this;return new Promise(function(t,r){e.on("finish",t),e.on("error",r)})};FL.exports=Zi});var ip=E((rlt,Ux)=>{"use strict";typeof process>"u"||!process.version||process.version.indexOf("v0.")===0||process.version.indexOf("v1.")===0&&process.version.indexOf("v1.8.")!==0?Ux.exports={nextTick:Nde}:Ux.exports=process;function Nde(e,t,r,n){if(typeof e!="function")throw new TypeError('"callback" argument must be a function');var i=arguments.length,o,s;switch(i){case 0:case 1:return process.nextTick(e);case 2:return process.nextTick(function(){e.call(null,t)});case 3:return process.nextTick(function(){e.call(null,t,r)});case 4:return process.nextTick(function(){e.call(null,t,r,n)});default:for(o=new Array(i-1),s=0;s<o.length;)o[s++]=arguments[s];return process.nextTick(function(){e.apply(null,o)})}}});var jL=E((nlt,qL)=>{"use strict";var Mde={}.toString;qL.exports=Array.isArray||function(e){return Mde.call(e)=="[object Array]"}});var Hx=E((ilt,UL)=>{"use strict";UL.exports=require("stream")});var op=E(($x,$L)=>{"use strict";var ay=require("buffer"),hs=ay.Buffer;function HL(e,t){for(var r in e)t[r]=e[r]}hs.from&&hs.alloc&&hs.allocUnsafe&&hs.allocUnsafeSlow?$L.exports=ay:(HL(ay,$x),$x.Buffer=ol);function ol(e,t,r){return hs(e,t,r)}HL(hs,ol);ol.from=function(e,t,r){if(typeof e=="number")throw new TypeError("Argument must not be a number");return hs(e,t,r)};ol.alloc=function(e,t,r){if(typeof e!="number")throw new TypeError("Argument must be a number");var n=hs(e);return t!==void 0?typeof r=="string"?n.fill(t,r):n.fill(t):n.fill(0),n};ol.allocUnsafe=function(e){if(typeof e!="number")throw new TypeError("Argument must be a number");return hs(e)};ol.allocUnsafeSlow=function(e){if(typeof e!="number")throw new TypeError("Argument must be a number");return ay.SlowBuffer(e)}});var sl=E(mn=>{"use strict";function Lde(e){return Array.isArray?Array.isArray(e):cy(e)==="[object Array]"}mn.isArray=Lde;function Bde(e){return typeof e=="boolean"}mn.isBoolean=Bde;function Fde(e){return e===null}mn.isNull=Fde;function qde(e){return e==null}mn.isNullOrUndefined=qde;function jde(e){return typeof e=="number"}mn.isNumber=jde;function Ude(e){return typeof e=="string"}mn.isString=Ude;function Hde(e){return typeof e=="symbol"}mn.isSymbol=Hde;function $de(e){return e===void 0}mn.isUndefined=$de;function Gde(e){return cy(e)==="[object RegExp]"}mn.isRegExp=Gde;function zde(e){return typeof e=="object"&&e!==null}mn.isObject=zde;function Vde(e){return cy(e)==="[object Date]"}mn.isDate=Vde;function Wde(e){return cy(e)==="[object Error]"||e instanceof Error}mn.isError=Wde;function Kde(e){return typeof e=="function"}mn.isFunction=Kde;function Yde(e){return e===null||typeof e=="boolean"||typeof e=="number"||typeof e=="string"||typeof e=="symbol"||typeof e>"u"}mn.isPrimitive=Yde;mn.isBuffer=require("buffer").Buffer.isBuffer;function cy(e){return Object.prototype.toString.call(e)}});var GL=E((slt,Gx)=>{"use strict";typeof Object.create=="function"?Gx.exports=function(t,r){r&&(t.super_=r,t.prototype=Object.create(r.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}))}:Gx.exports=function(t,r){if(r){t.super_=r;var n=function(){};n.prototype=r.prototype,t.prototype=new n,t.prototype.constructor=t}}});var ri=E((alt,Vx)=>{"use strict";try{if(zx=require("util"),typeof zx.inherits!="function")throw"";Vx.exports=zx.inherits}catch{Vx.exports=GL()}var zx});var VL=E((clt,Wx)=>{"use strict";function Xde(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var zL=op().Buffer,sp=require("util");function Jde(e,t,r){e.copy(t,r)}Wx.exports=(function(){function e(){Xde(this,e),this.head=null,this.tail=null,this.length=0}return e.prototype.push=function(r){var n={data:r,next:null};this.length>0?this.tail.next=n:this.head=n,this.tail=n,++this.length},e.prototype.unshift=function(r){var n={data:r,next:this.head};this.length===0&&(this.tail=n),this.head=n,++this.length},e.prototype.shift=function(){if(this.length!==0){var r=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,r}},e.prototype.clear=function(){this.head=this.tail=null,this.length=0},e.prototype.join=function(r){if(this.length===0)return"";for(var n=this.head,i=""+n.data;n=n.next;)i+=r+n.data;return i},e.prototype.concat=function(r){if(this.length===0)return zL.alloc(0);for(var n=zL.allocUnsafe(r>>>0),i=this.head,o=0;i;)Jde(i.data,n,o),o+=i.data.length,i=i.next;return n},e})();sp&&sp.inspect&&sp.inspect.custom&&(Wx.exports.prototype[sp.inspect.custom]=function(){var e=sp.inspect({length:this.length});return this.constructor.name+" "+e})});var Kx=E((ult,WL)=>{"use strict";var uy=ip();function Qde(e,t){var r=this,n=this._readableState&&this._readableState.destroyed,i=this._writableState&&this._writableState.destroyed;return n||i?(t?t(e):e&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,uy.nextTick(ly,this,e)):uy.nextTick(ly,this,e)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,function(o){!t&&o?r._writableState?r._writableState.errorEmitted||(r._writableState.errorEmitted=!0,uy.nextTick(ly,r,o)):uy.nextTick(ly,r,o):t&&t(o)}),this)}function Zde(){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 ly(e,t){e.emit("error",t)}WL.exports={destroy:Qde,undestroy:Zde}});var fy=E((llt,KL)=>{"use strict";KL.exports=require("util").deprecate});var Xx=E((flt,rB)=>{"use strict";var Ic=ip();rB.exports=vr;function XL(e){var t=this;this.next=null,this.entry=null,this.finish=function(){ype(t,e)}}var epe=!process.browser&&["v0.10","v0.9."].indexOf(process.version.slice(0,5))>-1?setImmediate:Ic.nextTick,al;vr.WritableState=cp;var JL=Object.create(sl());JL.inherits=ri();var tpe={deprecate:fy()},QL=Hx(),py=op().Buffer,rpe=(typeof global<"u"?global:typeof window<"u"?window:typeof self<"u"?self:{}).Uint8Array||function(){};function npe(e){return py.from(e)}function ipe(e){return py.isBuffer(e)||e instanceof rpe}var ZL=Kx();JL.inherits(vr,QL);function ope(){}function cp(e,t){al=al||Dc(),e=e||{};var r=t instanceof al;this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.writableObjectMode);var n=e.highWaterMark,i=e.writableHighWaterMark,o=this.objectMode?16:16*1024;n||n===0?this.highWaterMark=n:r&&(i||i===0)?this.highWaterMark=i:this.highWaterMark=o,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 s=e.decodeStrings===!1;this.decodeStrings=!s,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(a){dpe(t,a)},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 XL(this)}cp.prototype.getBuffer=function(){for(var t=this.bufferedRequest,r=[];t;)r.push(t),t=t.next;return r};(function(){try{Object.defineProperty(cp.prototype,"buffer",{get:tpe.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch{}})();var dy;typeof Symbol=="function"&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]=="function"?(dy=Function.prototype[Symbol.hasInstance],Object.defineProperty(vr,Symbol.hasInstance,{value:function(e){return dy.call(this,e)?!0:this!==vr?!1:e&&e._writableState instanceof cp}})):dy=function(e){return e instanceof this};function vr(e){if(al=al||Dc(),!dy.call(vr,this)&&!(this instanceof al))return new vr(e);this._writableState=new cp(e,this),this.writable=!0,e&&(typeof e.write=="function"&&(this._write=e.write),typeof e.writev=="function"&&(this._writev=e.writev),typeof e.destroy=="function"&&(this._destroy=e.destroy),typeof e.final=="function"&&(this._final=e.final)),QL.call(this)}vr.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))};function spe(e,t){var r=new Error("write after end");e.emit("error",r),Ic.nextTick(t,r)}function ape(e,t,r,n){var i=!0,o=!1;return r===null?o=new TypeError("May not write null values to stream"):typeof r!="string"&&r!==void 0&&!t.objectMode&&(o=new TypeError("Invalid non-string/buffer chunk")),o&&(e.emit("error",o),Ic.nextTick(n,o),i=!1),i}vr.prototype.write=function(e,t,r){var n=this._writableState,i=!1,o=!n.objectMode&&ipe(e);return o&&!py.isBuffer(e)&&(e=npe(e)),typeof t=="function"&&(r=t,t=null),o?t="buffer":t||(t=n.defaultEncoding),typeof r!="function"&&(r=ope),n.ended?spe(this,r):(o||ape(this,n,e,r))&&(n.pendingcb++,i=upe(this,n,o,e,t,r)),i};vr.prototype.cork=function(){var e=this._writableState;e.corked++};vr.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,!e.writing&&!e.corked&&!e.bufferProcessing&&e.bufferedRequest&&eB(this,e))};vr.prototype.setDefaultEncoding=function(t){if(typeof t=="string"&&(t=t.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((t+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+t);return this._writableState.defaultEncoding=t,this};function cpe(e,t,r){return!e.objectMode&&e.decodeStrings!==!1&&typeof t=="string"&&(t=py.from(t,r)),t}Object.defineProperty(vr.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});function upe(e,t,r,n,i,o){if(!r){var s=cpe(t,n,i);n!==s&&(r=!0,i="buffer",n=s)}var a=t.objectMode?1:n.length;t.length+=a;var c=t.length<t.highWaterMark;if(c||(t.needDrain=!0),t.writing||t.corked){var u=t.lastBufferedRequest;t.lastBufferedRequest={chunk:n,encoding:i,isBuf:r,callback:o,next:null},u?u.next=t.lastBufferedRequest:t.bufferedRequest=t.lastBufferedRequest,t.bufferedRequestCount+=1}else Yx(e,t,!1,a,n,i,o);return c}function Yx(e,t,r,n,i,o,s){t.writelen=n,t.writecb=s,t.writing=!0,t.sync=!0,r?e._writev(i,t.onwrite):e._write(i,o,t.onwrite),t.sync=!1}function lpe(e,t,r,n,i){--t.pendingcb,r?(Ic.nextTick(i,n),Ic.nextTick(ap,e,t),e._writableState.errorEmitted=!0,e.emit("error",n)):(i(n),e._writableState.errorEmitted=!0,e.emit("error",n),ap(e,t))}function fpe(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}function dpe(e,t){var r=e._writableState,n=r.sync,i=r.writecb;if(fpe(r),t)lpe(e,r,n,t,i);else{var o=tB(r);!o&&!r.corked&&!r.bufferProcessing&&r.bufferedRequest&&eB(e,r),n?epe(YL,e,r,o,i):YL(e,r,o,i)}}function YL(e,t,r,n){r||ppe(e,t),t.pendingcb--,n(),ap(e,t)}function ppe(e,t){t.length===0&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}function eB(e,t){t.bufferProcessing=!0;var r=t.bufferedRequest;if(e._writev&&r&&r.next){var n=t.bufferedRequestCount,i=new Array(n),o=t.corkedRequestsFree;o.entry=r;for(var s=0,a=!0;r;)i[s]=r,r.isBuf||(a=!1),r=r.next,s+=1;i.allBuffers=a,Yx(e,t,!0,t.length,i,"",o.finish),t.pendingcb++,t.lastBufferedRequest=null,o.next?(t.corkedRequestsFree=o.next,o.next=null):t.corkedRequestsFree=new XL(t),t.bufferedRequestCount=0}else{for(;r;){var c=r.chunk,u=r.encoding,l=r.callback,d=t.objectMode?1:c.length;if(Yx(e,t,!1,d,c,u,l),r=r.next,t.bufferedRequestCount--,t.writing)break}r===null&&(t.lastBufferedRequest=null)}t.bufferedRequest=r,t.bufferProcessing=!1}vr.prototype._write=function(e,t,r){r(new Error("_write() is not implemented"))};vr.prototype._writev=null;vr.prototype.end=function(e,t,r){var n=this._writableState;typeof e=="function"?(r=e,e=null,t=null):typeof t=="function"&&(r=t,t=null),e!=null&&this.write(e,t),n.corked&&(n.corked=1,this.uncork()),n.ending||gpe(this,n,r)};function tB(e){return e.ending&&e.length===0&&e.bufferedRequest===null&&!e.finished&&!e.writing}function hpe(e,t){e._final(function(r){t.pendingcb--,r&&e.emit("error",r),t.prefinished=!0,e.emit("prefinish"),ap(e,t)})}function mpe(e,t){!t.prefinished&&!t.finalCalled&&(typeof e._final=="function"?(t.pendingcb++,t.finalCalled=!0,Ic.nextTick(hpe,e,t)):(t.prefinished=!0,e.emit("prefinish")))}function ap(e,t){var r=tB(t);return r&&(mpe(e,t),t.pendingcb===0&&(t.finished=!0,e.emit("finish"))),r}function gpe(e,t,r){t.ending=!0,ap(e,t),r&&(t.finished?Ic.nextTick(r):e.once("finish",r)),t.ended=!0,e.writable=!1}function ype(e,t,r){var n=e.entry;for(e.entry=null;n;){var i=n.callback;t.pendingcb--,i(r),n=n.next}t.corkedRequestsFree.next=e}Object.defineProperty(vr.prototype,"destroyed",{get:function(){return this._writableState===void 0?!1:this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}});vr.prototype.destroy=ZL.destroy;vr.prototype._undestroy=ZL.undestroy;vr.prototype._destroy=function(e,t){this.end(),t(e)}});var Dc=E((dlt,sB)=>{"use strict";var nB=ip(),_pe=Object.keys||function(e){var t=[];for(var r in e)t.push(r);return t};sB.exports=ms;var iB=Object.create(sl());iB.inherits=ri();var oB=Zx(),Qx=Xx();iB.inherits(ms,oB);for(Jx=_pe(Qx.prototype),hy=0;hy<Jx.length;hy++)my=Jx[hy],ms.prototype[my]||(ms.prototype[my]=Qx.prototype[my]);var Jx,my,hy;function ms(e){if(!(this instanceof ms))return new ms(e);oB.call(this,e),Qx.call(this,e),e&&e.readable===!1&&(this.readable=!1),e&&e.writable===!1&&(this.writable=!1),this.allowHalfOpen=!0,e&&e.allowHalfOpen===!1&&(this.allowHalfOpen=!1),this.once("end",bpe)}Object.defineProperty(ms.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});function bpe(){this.allowHalfOpen||this._writableState.ended||nB.nextTick(Epe,this)}function Epe(e){e.end()}Object.defineProperty(ms.prototype,"destroyed",{get:function(){return this._readableState===void 0||this._writableState===void 0?!1:this._readableState.destroyed&&this._writableState.destroyed},set:function(e){this._readableState===void 0||this._writableState===void 0||(this._readableState.destroyed=e,this._writableState.destroyed=e)}});ms.prototype._destroy=function(e,t){this.push(null),this.end(),nB.nextTick(t,e)}});var rT=E(cB=>{"use strict";var tT=op().Buffer,aB=tT.isEncoding||function(e){switch(e=""+e,e&&e.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function wpe(e){if(!e)return"utf8";for(var t;;)switch(e){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return e;default:if(t)return;e=(""+e).toLowerCase(),t=!0}}function Spe(e){var t=wpe(e);if(typeof t!="string"&&(tT.isEncoding===aB||!aB(e)))throw new Error("Unknown encoding: "+e);return t||e}cB.StringDecoder=up;function up(e){this.encoding=Spe(e);var t;switch(this.encoding){case"utf16le":this.text=Rpe,this.end=Ppe,t=4;break;case"utf8":this.fillLast=xpe,t=4;break;case"base64":this.text=Ope,this.end=Ipe,t=3;break;default:this.write=Dpe,this.end=kpe;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=tT.allocUnsafe(t)}up.prototype.write=function(e){if(e.length===0)return"";var t,r;if(this.lastNeed){if(t=this.fillLast(e),t===void 0)return"";r=this.lastNeed,this.lastNeed=0}else r=0;return r<e.length?t?t+this.text(e,r):this.text(e,r):t||""};up.prototype.end=Ape;up.prototype.text=Tpe;up.prototype.fillLast=function(e){if(this.lastNeed<=e.length)return e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,e.length),this.lastNeed-=e.length};function eT(e){return e<=127?0:e>>5===6?2:e>>4===14?3:e>>3===30?4:e>>6===2?-1:-2}function vpe(e,t,r){var n=t.length-1;if(n<r)return 0;var i=eT(t[n]);return i>=0?(i>0&&(e.lastNeed=i-1),i):--n<r||i===-2?0:(i=eT(t[n]),i>=0?(i>0&&(e.lastNeed=i-2),i):--n<r||i===-2?0:(i=eT(t[n]),i>=0?(i>0&&(i===2?i=0:e.lastNeed=i-3),i):0))}function Cpe(e,t,r){if((t[0]&192)!==128)return e.lastNeed=0,"\uFFFD";if(e.lastNeed>1&&t.length>1){if((t[1]&192)!==128)return e.lastNeed=1,"\uFFFD";if(e.lastNeed>2&&t.length>2&&(t[2]&192)!==128)return e.lastNeed=2,"\uFFFD"}}function xpe(e){var t=this.lastTotal-this.lastNeed,r=Cpe(this,e,t);if(r!==void 0)return r;if(this.lastNeed<=e.length)return e.copy(this.lastChar,t,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);e.copy(this.lastChar,t,0,e.length),this.lastNeed-=e.length}function Tpe(e,t){var r=vpe(this,e,t);if(!this.lastNeed)return e.toString("utf8",t);this.lastTotal=r;var n=e.length-(r-this.lastNeed);return e.copy(this.lastChar,0,n),e.toString("utf8",t,n)}function Ape(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+"\uFFFD":t}function Rpe(e,t){if((e.length-t)%2===0){var r=e.toString("utf16le",t);if(r){var n=r.charCodeAt(r.length-1);if(n>=55296&&n<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1],r.slice(0,-1)}return r}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=e[e.length-1],e.toString("utf16le",t,e.length-1)}function Ppe(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed){var r=this.lastTotal-this.lastNeed;return t+this.lastChar.toString("utf16le",0,r)}return t}function Ope(e,t){var r=(e.length-t)%3;return r===0?e.toString("base64",t):(this.lastNeed=3-r,this.lastTotal=3,r===1?this.lastChar[0]=e[e.length-1]:(this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1]),e.toString("base64",t,e.length-r))}function Ipe(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+this.lastChar.toString("base64",0,3-this.lastNeed):t}function Dpe(e){return e.toString(this.encoding)}function kpe(e){return e&&e.length?this.write(e):""}});var Zx=E((mlt,EB)=>{"use strict";var ul=ip();EB.exports=Xt;var Npe=jL(),lp;Xt.ReadableState=mB;var hlt=require("events").EventEmitter,dB=function(e,t){return e.listeners(t).length},aT=Hx(),fp=op().Buffer,Mpe=(typeof global<"u"?global:typeof window<"u"?window:typeof self<"u"?self:{}).Uint8Array||function(){};function Lpe(e){return fp.from(e)}function Bpe(e){return fp.isBuffer(e)||e instanceof Mpe}var pB=Object.create(sl());pB.inherits=ri();var nT=require("util"),Ct=void 0;nT&&nT.debuglog?Ct=nT.debuglog("stream"):Ct=function(){};var Fpe=VL(),hB=Kx(),cl;pB.inherits(Xt,aT);var iT=["error","close","destroy","pause","resume"];function qpe(e,t,r){if(typeof e.prependListener=="function")return e.prependListener(t,r);!e._events||!e._events[t]?e.on(t,r):Npe(e._events[t])?e._events[t].unshift(r):e._events[t]=[r,e._events[t]]}function mB(e,t){lp=lp||Dc(),e=e||{};var r=t instanceof lp;this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.readableObjectMode);var n=e.highWaterMark,i=e.readableHighWaterMark,o=this.objectMode?16:16*1024;n||n===0?this.highWaterMark=n:r&&(i||i===0)?this.highWaterMark=i:this.highWaterMark=o,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new Fpe,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(cl||(cl=rT().StringDecoder),this.decoder=new cl(e.encoding),this.encoding=e.encoding)}function Xt(e){if(lp=lp||Dc(),!(this instanceof Xt))return new Xt(e);this._readableState=new mB(e,this),this.readable=!0,e&&(typeof e.read=="function"&&(this._read=e.read),typeof e.destroy=="function"&&(this._destroy=e.destroy)),aT.call(this)}Object.defineProperty(Xt.prototype,"destroyed",{get:function(){return this._readableState===void 0?!1:this._readableState.destroyed},set:function(e){this._readableState&&(this._readableState.destroyed=e)}});Xt.prototype.destroy=hB.destroy;Xt.prototype._undestroy=hB.undestroy;Xt.prototype._destroy=function(e,t){this.push(null),t(e)};Xt.prototype.push=function(e,t){var r=this._readableState,n;return r.objectMode?n=!0:typeof e=="string"&&(t=t||r.defaultEncoding,t!==r.encoding&&(e=fp.from(e,t),t=""),n=!0),gB(this,e,t,!1,n)};Xt.prototype.unshift=function(e){return gB(this,e,null,!0,!1)};function gB(e,t,r,n,i){var o=e._readableState;if(t===null)o.reading=!1,$pe(e,o);else{var s;i||(s=jpe(o,t)),s?e.emit("error",s):o.objectMode||t&&t.length>0?(typeof t!="string"&&!o.objectMode&&Object.getPrototypeOf(t)!==fp.prototype&&(t=Lpe(t)),n?o.endEmitted?e.emit("error",new Error("stream.unshift() after end event")):oT(e,o,t,!0):o.ended?e.emit("error",new Error("stream.push() after EOF")):(o.reading=!1,o.decoder&&!r?(t=o.decoder.write(t),o.objectMode||t.length!==0?oT(e,o,t,!1):yB(e,o)):oT(e,o,t,!1))):n||(o.reading=!1)}return Upe(o)}function oT(e,t,r,n){t.flowing&&t.length===0&&!t.sync?(e.emit("data",r),e.read(0)):(t.length+=t.objectMode?1:r.length,n?t.buffer.unshift(r):t.buffer.push(r),t.needReadable&&gy(e)),yB(e,t)}function jpe(e,t){var r;return!Bpe(t)&&typeof t!="string"&&t!==void 0&&!e.objectMode&&(r=new TypeError("Invalid non-string/buffer chunk")),r}function Upe(e){return!e.ended&&(e.needReadable||e.length<e.highWaterMark||e.length===0)}Xt.prototype.isPaused=function(){return this._readableState.flowing===!1};Xt.prototype.setEncoding=function(e){return cl||(cl=rT().StringDecoder),this._readableState.decoder=new cl(e),this._readableState.encoding=e,this};var uB=8388608;function Hpe(e){return e>=uB?e=uB:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}function lB(e,t){return e<=0||t.length===0&&t.ended?0:t.objectMode?1:e!==e?t.flowing&&t.length?t.buffer.head.data.length:t.length:(e>t.highWaterMark&&(t.highWaterMark=Hpe(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}Xt.prototype.read=function(e){Ct("read",e),e=parseInt(e,10);var t=this._readableState,r=e;if(e!==0&&(t.emittedReadable=!1),e===0&&t.needReadable&&(t.length>=t.highWaterMark||t.ended))return Ct("read: emitReadable",t.length,t.ended),t.length===0&&t.ended?sT(this):gy(this),null;if(e=lB(e,t),e===0&&t.ended)return t.length===0&&sT(this),null;var n=t.needReadable;Ct("need readable",n),(t.length===0||t.length-e<t.highWaterMark)&&(n=!0,Ct("length less than watermark",n)),t.ended||t.reading?(n=!1,Ct("reading or ended",n)):n&&(Ct("do read"),t.reading=!0,t.sync=!0,t.length===0&&(t.needReadable=!0),this._read(t.highWaterMark),t.sync=!1,t.reading||(e=lB(r,t)));var i;return e>0?i=_B(e,t):i=null,i===null?(t.needReadable=!0,e=0):t.length-=e,t.length===0&&(t.ended||(t.needReadable=!0),r!==e&&t.ended&&sT(this)),i!==null&&this.emit("data",i),i};function $pe(e,t){if(!t.ended){if(t.decoder){var r=t.decoder.end();r&&r.length&&(t.buffer.push(r),t.length+=t.objectMode?1:r.length)}t.ended=!0,gy(e)}}function gy(e){var t=e._readableState;t.needReadable=!1,t.emittedReadable||(Ct("emitReadable",t.flowing),t.emittedReadable=!0,t.sync?ul.nextTick(fB,e):fB(e))}function fB(e){Ct("emit readable"),e.emit("readable"),cT(e)}function yB(e,t){t.readingMore||(t.readingMore=!0,ul.nextTick(Gpe,e,t))}function Gpe(e,t){for(var r=t.length;!t.reading&&!t.flowing&&!t.ended&&t.length<t.highWaterMark&&(Ct("maybeReadMore read 0"),e.read(0),r!==t.length);)r=t.length;t.readingMore=!1}Xt.prototype._read=function(e){this.emit("error",new Error("_read() is not implemented"))};Xt.prototype.pipe=function(e,t){var r=this,n=this._readableState;switch(n.pipesCount){case 0:n.pipes=e;break;case 1:n.pipes=[n.pipes,e];break;default:n.pipes.push(e);break}n.pipesCount+=1,Ct("pipe count=%d opts=%j",n.pipesCount,t);var i=(!t||t.end!==!1)&&e!==process.stdout&&e!==process.stderr,o=i?a:_;n.endEmitted?ul.nextTick(o):r.once("end",o),e.on("unpipe",s);function s(w,R){Ct("onunpipe"),w===r&&R&&R.hasUnpiped===!1&&(R.hasUnpiped=!0,l())}function a(){Ct("onend"),e.end()}var c=zpe(r);e.on("drain",c);var u=!1;function l(){Ct("cleanup"),e.removeListener("close",p),e.removeListener("finish",m),e.removeListener("drain",c),e.removeListener("error",f),e.removeListener("unpipe",s),r.removeListener("end",a),r.removeListener("end",_),r.removeListener("data",h),u=!0,n.awaitDrain&&(!e._writableState||e._writableState.needDrain)&&c()}var d=!1;r.on("data",h);function h(w){Ct("ondata"),d=!1;var R=e.write(w);R===!1&&!d&&((n.pipesCount===1&&n.pipes===e||n.pipesCount>1&&bB(n.pipes,e)!==-1)&&!u&&(Ct("false write response, pause",n.awaitDrain),n.awaitDrain++,d=!0),r.pause())}function f(w){Ct("onerror",w),_(),e.removeListener("error",f),dB(e,"error")===0&&e.emit("error",w)}qpe(e,"error",f);function p(){e.removeListener("finish",m),_()}e.once("close",p);function m(){Ct("onfinish"),e.removeListener("close",p),_()}e.once("finish",m);function _(){Ct("unpipe"),r.unpipe(e)}return e.emit("pipe",r),n.flowing||(Ct("pipe resume"),r.resume()),e};function zpe(e){return function(){var t=e._readableState;Ct("pipeOnDrain",t.awaitDrain),t.awaitDrain&&t.awaitDrain--,t.awaitDrain===0&&dB(e,"data")&&(t.flowing=!0,cT(e))}}Xt.prototype.unpipe=function(e){var t=this._readableState,r={hasUnpiped:!1};if(t.pipesCount===0)return this;if(t.pipesCount===1)return e&&e!==t.pipes?this:(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,r),this);if(!e){var n=t.pipes,i=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var o=0;o<i;o++)n[o].emit("unpipe",this,{hasUnpiped:!1});return this}var s=bB(t.pipes,e);return s===-1?this:(t.pipes.splice(s,1),t.pipesCount-=1,t.pipesCount===1&&(t.pipes=t.pipes[0]),e.emit("unpipe",this,r),this)};Xt.prototype.on=function(e,t){var r=aT.prototype.on.call(this,e,t);if(e==="data")this._readableState.flowing!==!1&&this.resume();else if(e==="readable"){var n=this._readableState;!n.endEmitted&&!n.readableListening&&(n.readableListening=n.needReadable=!0,n.emittedReadable=!1,n.reading?n.length&&gy(this):ul.nextTick(Vpe,this))}return r};Xt.prototype.addListener=Xt.prototype.on;function Vpe(e){Ct("readable nexttick read 0"),e.read(0)}Xt.prototype.resume=function(){var e=this._readableState;return e.flowing||(Ct("resume"),e.flowing=!0,Wpe(this,e)),this};function Wpe(e,t){t.resumeScheduled||(t.resumeScheduled=!0,ul.nextTick(Kpe,e,t))}function Kpe(e,t){t.reading||(Ct("resume read 0"),e.read(0)),t.resumeScheduled=!1,t.awaitDrain=0,e.emit("resume"),cT(e),t.flowing&&!t.reading&&e.read(0)}Xt.prototype.pause=function(){return Ct("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(Ct("pause"),this._readableState.flowing=!1,this.emit("pause")),this};function cT(e){var t=e._readableState;for(Ct("flow",t.flowing);t.flowing&&e.read()!==null;);}Xt.prototype.wrap=function(e){var t=this,r=this._readableState,n=!1;e.on("end",function(){if(Ct("wrapped end"),r.decoder&&!r.ended){var s=r.decoder.end();s&&s.length&&t.push(s)}t.push(null)}),e.on("data",function(s){if(Ct("wrapped data"),r.decoder&&(s=r.decoder.write(s)),!(r.objectMode&&s==null)&&!(!r.objectMode&&(!s||!s.length))){var a=t.push(s);a||(n=!0,e.pause())}});for(var i in e)this[i]===void 0&&typeof e[i]=="function"&&(this[i]=(function(s){return function(){return e[s].apply(e,arguments)}})(i));for(var o=0;o<iT.length;o++)e.on(iT[o],this.emit.bind(this,iT[o]));return this._read=function(s){Ct("wrapped _read",s),n&&(n=!1,e.resume())},this};Object.defineProperty(Xt.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}});Xt._fromList=_B;function _B(e,t){if(t.length===0)return null;var r;return t.objectMode?r=t.buffer.shift():!e||e>=t.length?(t.decoder?r=t.buffer.join(""):t.buffer.length===1?r=t.buffer.head.data:r=t.buffer.concat(t.length),t.buffer.clear()):r=Ype(e,t.buffer,t.decoder),r}function Ype(e,t,r){var n;return e<t.head.data.length?(n=t.head.data.slice(0,e),t.head.data=t.head.data.slice(e)):e===t.head.data.length?n=t.shift():n=r?Xpe(e,t):Jpe(e,t),n}function Xpe(e,t){var r=t.head,n=1,i=r.data;for(e-=i.length;r=r.next;){var o=r.data,s=e>o.length?o.length:e;if(s===o.length?i+=o:i+=o.slice(0,e),e-=s,e===0){s===o.length?(++n,r.next?t.head=r.next:t.head=t.tail=null):(t.head=r,r.data=o.slice(s));break}++n}return t.length-=n,i}function Jpe(e,t){var r=fp.allocUnsafe(e),n=t.head,i=1;for(n.data.copy(r),e-=n.data.length;n=n.next;){var o=n.data,s=e>o.length?o.length:e;if(o.copy(r,r.length-e,0,s),e-=s,e===0){s===o.length?(++i,n.next?t.head=n.next:t.head=t.tail=null):(t.head=n,n.data=o.slice(s));break}++i}return t.length-=i,r}function sT(e){var t=e._readableState;if(t.length>0)throw new Error('"endReadable()" called on non-empty stream');t.endEmitted||(t.ended=!0,ul.nextTick(Qpe,t,e))}function Qpe(e,t){!e.endEmitted&&e.length===0&&(e.endEmitted=!0,t.readable=!1,t.emit("end"))}function bB(e,t){for(var r=0,n=e.length;r<n;r++)if(e[r]===t)return r;return-1}});var uT=E((glt,vB)=>{"use strict";vB.exports=gs;var yy=Dc(),SB=Object.create(sl());SB.inherits=ri();SB.inherits(gs,yy);function Zpe(e,t){var r=this._transformState;r.transforming=!1;var n=r.writecb;if(!n)return this.emit("error",new Error("write callback called multiple times"));r.writechunk=null,r.writecb=null,t!=null&&this.push(t),n(e);var i=this._readableState;i.reading=!1,(i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}function gs(e){if(!(this instanceof gs))return new gs(e);yy.call(this,e),this._transformState={afterTransform:Zpe.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,e&&(typeof e.transform=="function"&&(this._transform=e.transform),typeof e.flush=="function"&&(this._flush=e.flush)),this.on("prefinish",ehe)}function ehe(){var e=this;typeof this._flush=="function"?this._flush(function(t,r){wB(e,t,r)}):wB(this,null,null)}gs.prototype.push=function(e,t){return this._transformState.needTransform=!1,yy.prototype.push.call(this,e,t)};gs.prototype._transform=function(e,t,r){throw new Error("_transform() is not implemented")};gs.prototype._write=function(e,t,r){var n=this._transformState;if(n.writecb=r,n.writechunk=e,n.writeencoding=t,!n.transforming){var i=this._readableState;(n.needTransform||i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}};gs.prototype._read=function(e){var t=this._transformState;t.writechunk!==null&&t.writecb&&!t.transforming?(t.transforming=!0,this._transform(t.writechunk,t.writeencoding,t.afterTransform)):t.needTransform=!0};gs.prototype._destroy=function(e,t){var r=this;yy.prototype._destroy.call(this,e,function(n){t(n),r.emit("close")})};function wB(e,t,r){if(t)return e.emit("error",t);if(r!=null&&e.push(r),e._writableState.length)throw new Error("Calling transform done when ws.length != 0");if(e._transformState.transforming)throw new Error("Calling transform done when still transforming");return e.push(null)}});var AB=E((ylt,TB)=>{"use strict";TB.exports=dp;var CB=uT(),xB=Object.create(sl());xB.inherits=ri();xB.inherits(dp,CB);function dp(e){if(!(this instanceof dp))return new dp(e);CB.call(this,e)}dp.prototype._transform=function(e,t,r){r(null,e)}});var RB=E((nn,_y)=>{"use strict";var Ro=require("stream");process.env.READABLE_STREAM==="disable"&&Ro?(_y.exports=Ro,nn=_y.exports=Ro.Readable,nn.Readable=Ro.Readable,nn.Writable=Ro.Writable,nn.Duplex=Ro.Duplex,nn.Transform=Ro.Transform,nn.PassThrough=Ro.PassThrough,nn.Stream=Ro):(nn=_y.exports=Zx(),nn.Stream=Ro||nn,nn.Readable=nn,nn.Writable=Xx(),nn.Duplex=Dc(),nn.Transform=uT(),nn.PassThrough=AB())});var dT=E((_lt,fT)=>{"use strict";var lT=RB();function ll(e,t,r){typeof r>"u"&&(r=t,t=e,e=null),lT.Duplex.call(this,e),typeof r.read!="function"&&(r=new lT.Readable(e).wrap(r)),this._writable=t,this._readable=r,this._waiting=!1;var n=this;t.once("finish",function(){n.end()}),this.once("finish",function(){t.end()}),r.on("readable",function(){n._waiting&&(n._waiting=!1,n._read())}),r.once("end",function(){n.push(null)}),(!e||typeof e.bubbleErrors>"u"||e.bubbleErrors)&&(t.on("error",function(i){n.emit("error",i)}),r.on("error",function(i){n.emit("error",i)}))}ll.prototype=Object.create(lT.Duplex.prototype,{constructor:{value:ll}});ll.prototype._write=function(t,r,n){this._writable.write(t,r,n)};ll.prototype._read=function(){for(var t,r=0;(t=this._readable.read())!==null;)this.push(t),r++;r===0&&(this._waiting=!0)};fT.exports=function(t,r,n){return new ll(t,r,n)};fT.exports.DuplexWrapper=ll});var OB=E((blt,PB)=>{"use strict";var pT=require("stream"),the=sy(),rhe=dT(),nhe=ny();function ihe(e,t){let r=pT.PassThrough({objectMode:!0}),n=pT.PassThrough(),i=pT.Transform({objectMode:!0}),o=e instanceof RegExp?e:e&&new RegExp(e),s;i._transform=function(c,u,l){if(s||o&&!o.exec(c.path))return c.autodrain(),l();s=!0,a.emit("entry",c),c.on("error",function(d){n.emit("error",d)}),c.pipe(n).on("error",function(d){l(d)}).on("finish",function(d){l(null,d)})},r.pipe(the(t)).on("error",function(c){n.emit("error",c)}).pipe(i).on("error",Object).on("finish",function(){s?n.end():n.emit("error",new Error("PATTERN_NOT_FOUND"))});let a=rhe(r,n);return a.buffer=function(){return nhe(n)},a}PB.exports=ihe});var Hr=E(hT=>{"use strict";hT.fromCallback=function(e){return Object.defineProperty(function(...t){if(typeof t[t.length-1]=="function")e.apply(this,t);else return new Promise((r,n)=>{t.push((i,o)=>i!=null?n(i):r(o)),e.apply(this,t)})},"name",{value:e.name})};hT.fromPromise=function(e){return Object.defineProperty(function(...t){let r=t[t.length-1];if(typeof r!="function")return e.apply(this,t);t.pop(),e.apply(this,t).then(n=>r(null,n),r)},"name",{value:e.name})}});var DB=E((wlt,IB)=>{"use strict";var oa=require("constants"),ohe=process.cwd,by=null,she=process.env.GRACEFUL_FS_PLATFORM||process.platform;process.cwd=function(){return by||(by=ohe.call(process)),by};try{process.cwd()}catch{}typeof process.chdir=="function"&&(mT=process.chdir,process.chdir=function(e){by=null,mT.call(process,e)},Object.setPrototypeOf&&Object.setPrototypeOf(process.chdir,mT));var mT;IB.exports=ahe;function ahe(e){oa.hasOwnProperty("O_SYMLINK")&&process.version.match(/^v0\.6\.[0-2]|^v0\.5\./)&&t(e),e.lutimes||r(e),e.chown=o(e.chown),e.fchown=o(e.fchown),e.lchown=o(e.lchown),e.chmod=n(e.chmod),e.fchmod=n(e.fchmod),e.lchmod=n(e.lchmod),e.chownSync=s(e.chownSync),e.fchownSync=s(e.fchownSync),e.lchownSync=s(e.lchownSync),e.chmodSync=i(e.chmodSync),e.fchmodSync=i(e.fchmodSync),e.lchmodSync=i(e.lchmodSync),e.stat=a(e.stat),e.fstat=a(e.fstat),e.lstat=a(e.lstat),e.statSync=c(e.statSync),e.fstatSync=c(e.fstatSync),e.lstatSync=c(e.lstatSync),e.chmod&&!e.lchmod&&(e.lchmod=function(l,d,h){h&&process.nextTick(h)},e.lchmodSync=function(){}),e.chown&&!e.lchown&&(e.lchown=function(l,d,h,f){f&&process.nextTick(f)},e.lchownSync=function(){}),she==="win32"&&(e.rename=typeof e.rename!="function"?e.rename:(function(l){function d(h,f,p){var m=Date.now(),_=0;l(h,f,function w(R){if(R&&(R.code==="EACCES"||R.code==="EPERM"||R.code==="EBUSY")&&Date.now()-m<6e4){setTimeout(function(){e.stat(f,function(v,y){v&&v.code==="ENOENT"?l(h,f,w):p(R)})},_),_<100&&(_+=10);return}p&&p(R)})}return Object.setPrototypeOf&&Object.setPrototypeOf(d,l),d})(e.rename)),e.read=typeof e.read!="function"?e.read:(function(l){function d(h,f,p,m,_,w){var R;if(w&&typeof w=="function"){var v=0;R=function(y,S,O){if(y&&y.code==="EAGAIN"&&v<10)return v++,l.call(e,h,f,p,m,_,R);w.apply(this,arguments)}}return l.call(e,h,f,p,m,_,R)}return Object.setPrototypeOf&&Object.setPrototypeOf(d,l),d})(e.read),e.readSync=typeof e.readSync!="function"?e.readSync:(function(l){return function(d,h,f,p,m){for(var _=0;;)try{return l.call(e,d,h,f,p,m)}catch(w){if(w.code==="EAGAIN"&&_<10){_++;continue}throw w}}})(e.readSync);function t(l){l.lchmod=function(d,h,f){l.open(d,oa.O_WRONLY|oa.O_SYMLINK,h,function(p,m){if(p){f&&f(p);return}l.fchmod(m,h,function(_){l.close(m,function(w){f&&f(_||w)})})})},l.lchmodSync=function(d,h){var f=l.openSync(d,oa.O_WRONLY|oa.O_SYMLINK,h),p=!0,m;try{m=l.fchmodSync(f,h),p=!1}finally{if(p)try{l.closeSync(f)}catch{}else l.closeSync(f)}return m}}function r(l){oa.hasOwnProperty("O_SYMLINK")&&l.futimes?(l.lutimes=function(d,h,f,p){l.open(d,oa.O_SYMLINK,function(m,_){if(m){p&&p(m);return}l.futimes(_,h,f,function(w){l.close(_,function(R){p&&p(w||R)})})})},l.lutimesSync=function(d,h,f){var p=l.openSync(d,oa.O_SYMLINK),m,_=!0;try{m=l.futimesSync(p,h,f),_=!1}finally{if(_)try{l.closeSync(p)}catch{}else l.closeSync(p)}return m}):l.futimes&&(l.lutimes=function(d,h,f,p){p&&process.nextTick(p)},l.lutimesSync=function(){})}function n(l){return l&&function(d,h,f){return l.call(e,d,h,function(p){u(p)&&(p=null),f&&f.apply(this,arguments)})}}function i(l){return l&&function(d,h){try{return l.call(e,d,h)}catch(f){if(!u(f))throw f}}}function o(l){return l&&function(d,h,f,p){return l.call(e,d,h,f,function(m){u(m)&&(m=null),p&&p.apply(this,arguments)})}}function s(l){return l&&function(d,h,f){try{return l.call(e,d,h,f)}catch(p){if(!u(p))throw p}}}function a(l){return l&&function(d,h,f){typeof h=="function"&&(f=h,h=null);function p(m,_){_&&(_.uid<0&&(_.uid+=4294967296),_.gid<0&&(_.gid+=4294967296)),f&&f.apply(this,arguments)}return h?l.call(e,d,h,p):l.call(e,d,p)}}function c(l){return l&&function(d,h){var f=h?l.call(e,d,h):l.call(e,d);return f&&(f.uid<0&&(f.uid+=4294967296),f.gid<0&&(f.gid+=4294967296)),f}}function u(l){if(!l||l.code==="ENOSYS")return!0;var d=!process.getuid||process.getuid()!==0;return!!(d&&(l.code==="EINVAL"||l.code==="EPERM"))}}});var MB=E((Slt,NB)=>{"use strict";var kB=require("stream").Stream;NB.exports=che;function che(e){return{ReadStream:t,WriteStream:r};function t(n,i){if(!(this instanceof t))return new t(n,i);kB.call(this);var o=this;this.path=n,this.fd=null,this.readable=!0,this.paused=!1,this.flags="r",this.mode=438,this.bufferSize=64*1024,i=i||{};for(var s=Object.keys(i),a=0,c=s.length;a<c;a++){var u=s[a];this[u]=i[u]}if(this.encoding&&this.setEncoding(this.encoding),this.start!==void 0){if(typeof this.start!="number")throw TypeError("start must be a Number");if(this.end===void 0)this.end=1/0;else if(typeof this.end!="number")throw TypeError("end must be a Number");if(this.start>this.end)throw new Error("start must be <= end");this.pos=this.start}if(this.fd!==null){process.nextTick(function(){o._read()});return}e.open(this.path,this.flags,this.mode,function(l,d){if(l){o.emit("error",l),o.readable=!1;return}o.fd=d,o.emit("open",d),o._read()})}function r(n,i){if(!(this instanceof r))return new r(n,i);kB.call(this),this.path=n,this.fd=null,this.writable=!0,this.flags="w",this.encoding="binary",this.mode=438,this.bytesWritten=0,i=i||{};for(var o=Object.keys(i),s=0,a=o.length;s<a;s++){var c=o[s];this[c]=i[c]}if(this.start!==void 0){if(typeof this.start!="number")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=[],this.fd===null&&(this._open=e.open,this._queue.push([this._open,this.path,this.flags,this.mode,void 0]),this.flush())}}});var BB=E((vlt,LB)=>{"use strict";LB.exports=lhe;var uhe=Object.getPrototypeOf||function(e){return e.__proto__};function lhe(e){if(e===null||typeof e!="object")return e;if(e instanceof Object)var t={__proto__:uhe(e)};else var t=Object.create(null);return Object.getOwnPropertyNames(e).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(e,r))}),t}});var Nc=E((Clt,_T)=>{"use strict";var or=require("fs"),fhe=DB(),dhe=MB(),phe=BB(),Ey=require("util"),on,Sy;typeof Symbol=="function"&&typeof Symbol.for=="function"?(on=Symbol.for("graceful-fs.queue"),Sy=Symbol.for("graceful-fs.previous")):(on="___graceful-fs.queue",Sy="___graceful-fs.previous");function hhe(){}function jB(e,t){Object.defineProperty(e,on,{get:function(){return t}})}var kc=hhe;Ey.debuglog?kc=Ey.debuglog("gfs4"):/\bgfs4\b/i.test(process.env.NODE_DEBUG||"")&&(kc=function(){var e=Ey.format.apply(Ey,arguments);e="GFS4: "+e.split(/\n/).join(`
|
|
2
|
+
GFS4: `),console.error(e)});or[on]||(FB=global[on]||[],jB(or,FB),or.close=(function(e){function t(r,n){return e.call(or,r,function(i){i||qB(),typeof n=="function"&&n.apply(this,arguments)})}return Object.defineProperty(t,Sy,{value:e}),t})(or.close),or.closeSync=(function(e){function t(r){e.apply(or,arguments),qB()}return Object.defineProperty(t,Sy,{value:e}),t})(or.closeSync),/\bgfs4\b/i.test(process.env.NODE_DEBUG||"")&&process.on("exit",function(){kc(or[on]),require("assert").equal(or[on].length,0)}));var FB;global[on]||jB(global,or[on]);_T.exports=gT(phe(or));process.env.TEST_GRACEFUL_FS_GLOBAL_PATCH&&!or.__patched&&(_T.exports=gT(or),or.__patched=!0);function gT(e){fhe(e),e.gracefulify=gT,e.createReadStream=S,e.createWriteStream=O;var t=e.readFile;e.readFile=r;function r(D,I,N){return typeof I=="function"&&(N=I,I=null),J(D,I,N);function J(U,ie,be,B){return t(U,ie,function(te){te&&(te.code==="EMFILE"||te.code==="ENFILE")?fl([J,[U,ie,be],te,B||Date.now(),Date.now()]):typeof be=="function"&&be.apply(this,arguments)})}}var n=e.writeFile;e.writeFile=i;function i(D,I,N,J){return typeof N=="function"&&(J=N,N=null),U(D,I,N,J);function U(ie,be,B,te,ge){return n(ie,be,B,function($){$&&($.code==="EMFILE"||$.code==="ENFILE")?fl([U,[ie,be,B,te],$,ge||Date.now(),Date.now()]):typeof te=="function"&&te.apply(this,arguments)})}}var o=e.appendFile;o&&(e.appendFile=s);function s(D,I,N,J){return typeof N=="function"&&(J=N,N=null),U(D,I,N,J);function U(ie,be,B,te,ge){return o(ie,be,B,function($){$&&($.code==="EMFILE"||$.code==="ENFILE")?fl([U,[ie,be,B,te],$,ge||Date.now(),Date.now()]):typeof te=="function"&&te.apply(this,arguments)})}}var a=e.copyFile;a&&(e.copyFile=c);function c(D,I,N,J){return typeof N=="function"&&(J=N,N=0),U(D,I,N,J);function U(ie,be,B,te,ge){return a(ie,be,B,function($){$&&($.code==="EMFILE"||$.code==="ENFILE")?fl([U,[ie,be,B,te],$,ge||Date.now(),Date.now()]):typeof te=="function"&&te.apply(this,arguments)})}}var u=e.readdir;e.readdir=d;var l=/^v[0-5]\./;function d(D,I,N){typeof I=="function"&&(N=I,I=null);var J=l.test(process.version)?function(be,B,te,ge){return u(be,U(be,B,te,ge))}:function(be,B,te,ge){return u(be,B,U(be,B,te,ge))};return J(D,I,N);function U(ie,be,B,te){return function(ge,$){ge&&(ge.code==="EMFILE"||ge.code==="ENFILE")?fl([J,[ie,be,B],ge,te||Date.now(),Date.now()]):($&&$.sort&&$.sort(),typeof B=="function"&&B.call(this,ge,$))}}}if(process.version.substr(0,4)==="v0.8"){var h=dhe(e);w=h.ReadStream,v=h.WriteStream}var f=e.ReadStream;f&&(w.prototype=Object.create(f.prototype),w.prototype.open=R);var p=e.WriteStream;p&&(v.prototype=Object.create(p.prototype),v.prototype.open=y),Object.defineProperty(e,"ReadStream",{get:function(){return w},set:function(D){w=D},enumerable:!0,configurable:!0}),Object.defineProperty(e,"WriteStream",{get:function(){return v},set:function(D){v=D},enumerable:!0,configurable:!0});var m=w;Object.defineProperty(e,"FileReadStream",{get:function(){return m},set:function(D){m=D},enumerable:!0,configurable:!0});var _=v;Object.defineProperty(e,"FileWriteStream",{get:function(){return _},set:function(D){_=D},enumerable:!0,configurable:!0});function w(D,I){return this instanceof w?(f.apply(this,arguments),this):w.apply(Object.create(w.prototype),arguments)}function R(){var D=this;A(D.path,D.flags,D.mode,function(I,N){I?(D.autoClose&&D.destroy(),D.emit("error",I)):(D.fd=N,D.emit("open",N),D.read())})}function v(D,I){return this instanceof v?(p.apply(this,arguments),this):v.apply(Object.create(v.prototype),arguments)}function y(){var D=this;A(D.path,D.flags,D.mode,function(I,N){I?(D.destroy(),D.emit("error",I)):(D.fd=N,D.emit("open",N))})}function S(D,I){return new e.ReadStream(D,I)}function O(D,I){return new e.WriteStream(D,I)}var M=e.open;e.open=A;function A(D,I,N,J){return typeof N=="function"&&(J=N,N=null),U(D,I,N,J);function U(ie,be,B,te,ge){return M(ie,be,B,function($,ve){$&&($.code==="EMFILE"||$.code==="ENFILE")?fl([U,[ie,be,B,te],$,ge||Date.now(),Date.now()]):typeof te=="function"&&te.apply(this,arguments)})}}return e}function fl(e){kc("ENQUEUE",e[0].name,e[1]),or[on].push(e),yT()}var wy;function qB(){for(var e=Date.now(),t=0;t<or[on].length;++t)or[on][t].length>2&&(or[on][t][3]=e,or[on][t][4]=e);yT()}function yT(){if(clearTimeout(wy),wy=void 0,or[on].length!==0){var e=or[on].shift(),t=e[0],r=e[1],n=e[2],i=e[3],o=e[4];if(i===void 0)kc("RETRY",t.name,r),t.apply(null,r);else if(Date.now()-i>=6e4){kc("TIMEOUT",t.name,r);var s=r.pop();typeof s=="function"&&s.call(null,n)}else{var a=Date.now()-o,c=Math.max(o-i,1),u=Math.min(c*1.2,100);a>=u?(kc("RETRY",t.name,r),t.apply(null,r.concat([i]))):or[on].push(e)}wy===void 0&&(wy=setTimeout(yT,0))}}});var Ln=E(ys=>{"use strict";var UB=Hr().fromCallback,Mn=Nc(),mhe=["access","appendFile","chmod","chown","close","copyFile","cp","fchmod","fchown","fdatasync","fstat","fsync","ftruncate","futimes","glob","lchmod","lchown","lutimes","link","lstat","mkdir","mkdtemp","open","opendir","readdir","readFile","readlink","realpath","rename","rm","rmdir","stat","statfs","symlink","truncate","unlink","utimes","writeFile"].filter(e=>typeof Mn[e]=="function");Object.assign(ys,Mn);mhe.forEach(e=>{ys[e]=UB(Mn[e])});ys.exists=function(e,t){return typeof t=="function"?Mn.exists(e,t):new Promise(r=>Mn.exists(e,r))};ys.read=function(e,t,r,n,i,o){return typeof o=="function"?Mn.read(e,t,r,n,i,o):new Promise((s,a)=>{Mn.read(e,t,r,n,i,(c,u,l)=>{if(c)return a(c);s({bytesRead:u,buffer:l})})})};ys.write=function(e,t,...r){return typeof r[r.length-1]=="function"?Mn.write(e,t,...r):new Promise((n,i)=>{Mn.write(e,t,...r,(o,s,a)=>{if(o)return i(o);n({bytesWritten:s,buffer:a})})})};ys.readv=function(e,t,...r){return typeof r[r.length-1]=="function"?Mn.readv(e,t,...r):new Promise((n,i)=>{Mn.readv(e,t,...r,(o,s,a)=>{if(o)return i(o);n({bytesRead:s,buffers:a})})})};ys.writev=function(e,t,...r){return typeof r[r.length-1]=="function"?Mn.writev(e,t,...r):new Promise((n,i)=>{Mn.writev(e,t,...r,(o,s,a)=>{if(o)return i(o);n({bytesWritten:s,buffers:a})})})};typeof Mn.realpath.native=="function"?ys.realpath.native=UB(Mn.realpath.native):process.emitWarning("fs.realpath.native is not a function. Is fs being monkey-patched?","Warning","fs-extra-WARN0003")});var $B=E((Tlt,HB)=>{"use strict";var ghe=require("path");HB.exports.checkPath=function(t){if(process.platform==="win32"&&/[<>:"|?*]/.test(t.replace(ghe.parse(t).root,""))){let n=new Error(`Path contains invalid characters: ${t}`);throw n.code="EINVAL",n}}});var WB=E((Alt,bT)=>{"use strict";var GB=Ln(),{checkPath:zB}=$B(),VB=e=>{let t={mode:511};return typeof e=="number"?e:{...t,...e}.mode};bT.exports.makeDir=async(e,t)=>(zB(e),GB.mkdir(e,{mode:VB(t),recursive:!0}));bT.exports.makeDirSync=(e,t)=>(zB(e),GB.mkdirSync(e,{mode:VB(t),recursive:!0}))});var eo=E((Rlt,KB)=>{"use strict";var yhe=Hr().fromPromise,{makeDir:_he,makeDirSync:ET}=WB(),wT=yhe(_he);KB.exports={mkdirs:wT,mkdirsSync:ET,mkdirp:wT,mkdirpSync:ET,ensureDir:wT,ensureDirSync:ET}});var sa=E((Plt,XB)=>{"use strict";var bhe=Hr().fromPromise,YB=Ln();function Ehe(e){return YB.access(e).then(()=>!0).catch(()=>!1)}XB.exports={pathExists:bhe(Ehe),pathExistsSync:YB.existsSync}});var ST=E((Olt,JB)=>{"use strict";var dl=Ln(),whe=Hr().fromPromise;async function She(e,t,r){let n=await dl.open(e,"r+"),i=null;try{await dl.futimes(n,t,r)}finally{try{await dl.close(n)}catch(o){i=o}}if(i)throw i}function vhe(e,t,r){let n=dl.openSync(e,"r+");return dl.futimesSync(n,t,r),dl.closeSync(n)}JB.exports={utimesMillis:whe(She),utimesMillisSync:vhe}});var Mc=E((Ilt,t2)=>{"use strict";var pl=Ln(),$r=require("path"),QB=Hr().fromPromise;function Che(e,t,r){let n=r.dereference?i=>pl.stat(i,{bigint:!0}):i=>pl.lstat(i,{bigint:!0});return Promise.all([n(e),n(t).catch(i=>{if(i.code==="ENOENT")return null;throw i})]).then(([i,o])=>({srcStat:i,destStat:o}))}function xhe(e,t,r){let n,i=r.dereference?s=>pl.statSync(s,{bigint:!0}):s=>pl.lstatSync(s,{bigint:!0}),o=i(e);try{n=i(t)}catch(s){if(s.code==="ENOENT")return{srcStat:o,destStat:null};throw s}return{srcStat:o,destStat:n}}async function The(e,t,r,n){let{srcStat:i,destStat:o}=await Che(e,t,n);if(o){if(pp(i,o)){let s=$r.basename(e),a=$r.basename(t);if(r==="move"&&s!==a&&s.toLowerCase()===a.toLowerCase())return{srcStat:i,destStat:o,isChangingCase:!0};throw new Error("Source and destination must not be the same.")}if(i.isDirectory()&&!o.isDirectory())throw new Error(`Cannot overwrite non-directory '${t}' with directory '${e}'.`);if(!i.isDirectory()&&o.isDirectory())throw new Error(`Cannot overwrite directory '${t}' with non-directory '${e}'.`)}if(i.isDirectory()&&vT(e,t))throw new Error(vy(e,t,r));return{srcStat:i,destStat:o}}function Ahe(e,t,r,n){let{srcStat:i,destStat:o}=xhe(e,t,n);if(o){if(pp(i,o)){let s=$r.basename(e),a=$r.basename(t);if(r==="move"&&s!==a&&s.toLowerCase()===a.toLowerCase())return{srcStat:i,destStat:o,isChangingCase:!0};throw new Error("Source and destination must not be the same.")}if(i.isDirectory()&&!o.isDirectory())throw new Error(`Cannot overwrite non-directory '${t}' with directory '${e}'.`);if(!i.isDirectory()&&o.isDirectory())throw new Error(`Cannot overwrite directory '${t}' with non-directory '${e}'.`)}if(i.isDirectory()&&vT(e,t))throw new Error(vy(e,t,r));return{srcStat:i,destStat:o}}async function ZB(e,t,r,n){let i=$r.resolve($r.dirname(e)),o=$r.resolve($r.dirname(r));if(o===i||o===$r.parse(o).root)return;let s;try{s=await pl.stat(o,{bigint:!0})}catch(a){if(a.code==="ENOENT")return;throw a}if(pp(t,s))throw new Error(vy(e,r,n));return ZB(e,t,o,n)}function e2(e,t,r,n){let i=$r.resolve($r.dirname(e)),o=$r.resolve($r.dirname(r));if(o===i||o===$r.parse(o).root)return;let s;try{s=pl.statSync(o,{bigint:!0})}catch(a){if(a.code==="ENOENT")return;throw a}if(pp(t,s))throw new Error(vy(e,r,n));return e2(e,t,o,n)}function pp(e,t){return t.ino!==void 0&&t.dev!==void 0&&t.ino===e.ino&&t.dev===e.dev}function vT(e,t){let r=$r.resolve(e).split($r.sep).filter(i=>i),n=$r.resolve(t).split($r.sep).filter(i=>i);return r.every((i,o)=>n[o]===i)}function vy(e,t,r){return`Cannot ${r} '${e}' to a subdirectory of itself, '${t}'.`}t2.exports={checkPaths:QB(The),checkPathsSync:Ahe,checkParentPaths:QB(ZB),checkParentPathsSync:e2,isSrcSubdir:vT,areIdentical:pp}});var n2=E((Dlt,r2)=>{"use strict";async function Rhe(e,t){let r=[];for await(let n of e)r.push(t(n).then(()=>null,i=>i??new Error("unknown error")));await Promise.all(r.map(n=>n.then(i=>{if(i!==null)throw i})))}r2.exports={asyncIteratorConcurrentProcess:Rhe}});var c2=E((klt,a2)=>{"use strict";var gn=Ln(),hp=require("path"),{mkdirs:Phe}=eo(),{pathExists:Ohe}=sa(),{utimesMillis:Ihe}=ST(),mp=Mc(),{asyncIteratorConcurrentProcess:Dhe}=n2();async function khe(e,t,r={}){typeof r=="function"&&(r={filter:r}),r.clobber="clobber"in r?!!r.clobber:!0,r.overwrite="overwrite"in r?!!r.overwrite:r.clobber,r.preserveTimestamps&&process.arch==="ia32"&&process.emitWarning(`Using the preserveTimestamps option in 32-bit node is not recommended;
|
|
3
|
+
|
|
4
|
+
see https://github.com/jprichardson/node-fs-extra/issues/269`,"Warning","fs-extra-WARN0001");let{srcStat:n,destStat:i}=await mp.checkPaths(e,t,"copy",r);if(await mp.checkParentPaths(e,n,t,"copy"),!await o2(e,t,r))return;let s=hp.dirname(t);await Ohe(s)||await Phe(s),await s2(i,e,t,r)}async function o2(e,t,r){return r.filter?r.filter(e,t):!0}async function s2(e,t,r,n){let o=await(n.dereference?gn.stat:gn.lstat)(t);if(o.isDirectory())return Bhe(o,e,t,r,n);if(o.isFile()||o.isCharacterDevice()||o.isBlockDevice())return Nhe(o,e,t,r,n);if(o.isSymbolicLink())return Fhe(e,t,r,n);throw o.isSocket()?new Error(`Cannot copy a socket file: ${t}`):o.isFIFO()?new Error(`Cannot copy a FIFO pipe: ${t}`):new Error(`Unknown file: ${t}`)}async function Nhe(e,t,r,n,i){if(!t)return i2(e,r,n,i);if(i.overwrite)return await gn.unlink(n),i2(e,r,n,i);if(i.errorOnExist)throw new Error(`'${n}' already exists`)}async function i2(e,t,r,n){if(await gn.copyFile(t,r),n.preserveTimestamps){Mhe(e.mode)&&await Lhe(r,e.mode);let i=await gn.stat(t);await Ihe(r,i.atime,i.mtime)}return gn.chmod(r,e.mode)}function Mhe(e){return(e&128)===0}function Lhe(e,t){return gn.chmod(e,t|128)}async function Bhe(e,t,r,n,i){t||await gn.mkdir(n),await Dhe(await gn.opendir(r),async o=>{let s=hp.join(r,o.name),a=hp.join(n,o.name);if(await o2(s,a,i)){let{destStat:u}=await mp.checkPaths(s,a,"copy",i);await s2(u,s,a,i)}}),t||await gn.chmod(n,e.mode)}async function Fhe(e,t,r,n){let i=await gn.readlink(t);if(n.dereference&&(i=hp.resolve(process.cwd(),i)),!e)return gn.symlink(i,r);let o=null;try{o=await gn.readlink(r)}catch(s){if(s.code==="EINVAL"||s.code==="UNKNOWN")return gn.symlink(i,r);throw s}if(n.dereference&&(o=hp.resolve(process.cwd(),o)),i!==o){if(mp.isSrcSubdir(i,o))throw new Error(`Cannot copy '${i}' to a subdirectory of itself, '${o}'.`);if(mp.isSrcSubdir(o,i))throw new Error(`Cannot overwrite '${o}' with '${i}'.`)}return await gn.unlink(r),gn.symlink(i,r)}a2.exports=khe});var p2=E((Nlt,d2)=>{"use strict";var Bn=Nc(),gp=require("path"),qhe=eo().mkdirsSync,jhe=ST().utimesMillisSync,yp=Mc();function Uhe(e,t,r){typeof r=="function"&&(r={filter:r}),r=r||{},r.clobber="clobber"in r?!!r.clobber:!0,r.overwrite="overwrite"in r?!!r.overwrite:r.clobber,r.preserveTimestamps&&process.arch==="ia32"&&process.emitWarning(`Using the preserveTimestamps option in 32-bit node is not recommended;
|
|
5
|
+
|
|
6
|
+
see https://github.com/jprichardson/node-fs-extra/issues/269`,"Warning","fs-extra-WARN0002");let{srcStat:n,destStat:i}=yp.checkPathsSync(e,t,"copy",r);if(yp.checkParentPathsSync(e,n,t,"copy"),r.filter&&!r.filter(e,t))return;let o=gp.dirname(t);return Bn.existsSync(o)||qhe(o),u2(i,e,t,r)}function u2(e,t,r,n){let o=(n.dereference?Bn.statSync:Bn.lstatSync)(t);if(o.isDirectory())return Khe(o,e,t,r,n);if(o.isFile()||o.isCharacterDevice()||o.isBlockDevice())return Hhe(o,e,t,r,n);if(o.isSymbolicLink())return Jhe(e,t,r,n);throw o.isSocket()?new Error(`Cannot copy a socket file: ${t}`):o.isFIFO()?new Error(`Cannot copy a FIFO pipe: ${t}`):new Error(`Unknown file: ${t}`)}function Hhe(e,t,r,n,i){return t?$he(e,r,n,i):l2(e,r,n,i)}function $he(e,t,r,n){if(n.overwrite)return Bn.unlinkSync(r),l2(e,t,r,n);if(n.errorOnExist)throw new Error(`'${r}' already exists`)}function l2(e,t,r,n){return Bn.copyFileSync(t,r),n.preserveTimestamps&&Ghe(e.mode,t,r),CT(r,e.mode)}function Ghe(e,t,r){return zhe(e)&&Vhe(r,e),Whe(t,r)}function zhe(e){return(e&128)===0}function Vhe(e,t){return CT(e,t|128)}function CT(e,t){return Bn.chmodSync(e,t)}function Whe(e,t){let r=Bn.statSync(e);return jhe(t,r.atime,r.mtime)}function Khe(e,t,r,n,i){return t?f2(r,n,i):Yhe(e.mode,r,n,i)}function Yhe(e,t,r,n){return Bn.mkdirSync(r),f2(t,r,n),CT(r,e)}function f2(e,t,r){let n=Bn.opendirSync(e);try{let i;for(;(i=n.readSync())!==null;)Xhe(i.name,e,t,r)}finally{n.closeSync()}}function Xhe(e,t,r,n){let i=gp.join(t,e),o=gp.join(r,e);if(n.filter&&!n.filter(i,o))return;let{destStat:s}=yp.checkPathsSync(i,o,"copy",n);return u2(s,i,o,n)}function Jhe(e,t,r,n){let i=Bn.readlinkSync(t);if(n.dereference&&(i=gp.resolve(process.cwd(),i)),e){let o;try{o=Bn.readlinkSync(r)}catch(s){if(s.code==="EINVAL"||s.code==="UNKNOWN")return Bn.symlinkSync(i,r);throw s}if(n.dereference&&(o=gp.resolve(process.cwd(),o)),i!==o){if(yp.isSrcSubdir(i,o))throw new Error(`Cannot copy '${i}' to a subdirectory of itself, '${o}'.`);if(yp.isSrcSubdir(o,i))throw new Error(`Cannot overwrite '${o}' with '${i}'.`)}return Qhe(i,r)}else return Bn.symlinkSync(i,r)}function Qhe(e,t){return Bn.unlinkSync(t),Bn.symlinkSync(e,t)}d2.exports=Uhe});var Cy=E((Mlt,h2)=>{"use strict";var Zhe=Hr().fromPromise;h2.exports={copy:Zhe(c2()),copySync:p2()}});var _p=E((Llt,g2)=>{"use strict";var m2=Nc(),eme=Hr().fromCallback;function tme(e,t){m2.rm(e,{recursive:!0,force:!0},t)}function rme(e){m2.rmSync(e,{recursive:!0,force:!0})}g2.exports={remove:eme(tme),removeSync:rme}});var C2=E((Blt,v2)=>{"use strict";var nme=Hr().fromPromise,b2=Ln(),E2=require("path"),w2=eo(),S2=_p(),y2=nme(async function(t){let r;try{r=await b2.readdir(t)}catch{return w2.mkdirs(t)}return Promise.all(r.map(n=>S2.remove(E2.join(t,n))))});function _2(e){let t;try{t=b2.readdirSync(e)}catch{return w2.mkdirsSync(e)}t.forEach(r=>{r=E2.join(e,r),S2.removeSync(r)})}v2.exports={emptyDirSync:_2,emptydirSync:_2,emptyDir:y2,emptydir:y2}});var R2=E((Flt,A2)=>{"use strict";var ime=Hr().fromPromise,x2=require("path"),_s=Ln(),T2=eo();async function ome(e){let t;try{t=await _s.stat(e)}catch{}if(t&&t.isFile())return;let r=x2.dirname(e),n=null;try{n=await _s.stat(r)}catch(i){if(i.code==="ENOENT"){await T2.mkdirs(r),await _s.writeFile(e,"");return}else throw i}n.isDirectory()?await _s.writeFile(e,""):await _s.readdir(r)}function sme(e){let t;try{t=_s.statSync(e)}catch{}if(t&&t.isFile())return;let r=x2.dirname(e);try{_s.statSync(r).isDirectory()||_s.readdirSync(r)}catch(n){if(n&&n.code==="ENOENT")T2.mkdirsSync(r);else throw n}_s.writeFileSync(e,"")}A2.exports={createFile:ime(ome),createFileSync:sme}});var k2=E((qlt,D2)=>{"use strict";var ame=Hr().fromPromise,P2=require("path"),aa=Ln(),O2=eo(),{pathExists:cme}=sa(),{areIdentical:I2}=Mc();async function ume(e,t){let r;try{r=await aa.lstat(t)}catch{}let n;try{n=await aa.lstat(e)}catch(s){throw s.message=s.message.replace("lstat","ensureLink"),s}if(r&&I2(n,r))return;let i=P2.dirname(t);await cme(i)||await O2.mkdirs(i),await aa.link(e,t)}function lme(e,t){let r;try{r=aa.lstatSync(t)}catch{}try{let o=aa.lstatSync(e);if(r&&I2(o,r))return}catch(o){throw o.message=o.message.replace("lstat","ensureLink"),o}let n=P2.dirname(t);return aa.existsSync(n)||O2.mkdirsSync(n),aa.linkSync(e,t)}D2.exports={createLink:ame(ume),createLinkSync:lme}});var M2=E((jlt,N2)=>{"use strict";var ca=require("path"),bp=Ln(),{pathExists:fme}=sa(),dme=Hr().fromPromise;async function pme(e,t){if(ca.isAbsolute(e)){try{await bp.lstat(e)}catch(o){throw o.message=o.message.replace("lstat","ensureSymlink"),o}return{toCwd:e,toDst:e}}let r=ca.dirname(t),n=ca.join(r,e);if(await fme(n))return{toCwd:n,toDst:e};try{await bp.lstat(e)}catch(o){throw o.message=o.message.replace("lstat","ensureSymlink"),o}return{toCwd:e,toDst:ca.relative(r,e)}}function hme(e,t){if(ca.isAbsolute(e)){if(!bp.existsSync(e))throw new Error("absolute srcpath does not exist");return{toCwd:e,toDst:e}}let r=ca.dirname(t),n=ca.join(r,e);if(bp.existsSync(n))return{toCwd:n,toDst:e};if(!bp.existsSync(e))throw new Error("relative srcpath does not exist");return{toCwd:e,toDst:ca.relative(r,e)}}N2.exports={symlinkPaths:dme(pme),symlinkPathsSync:hme}});var F2=E((Ult,B2)=>{"use strict";var L2=Ln(),mme=Hr().fromPromise;async function gme(e,t){if(t)return t;let r;try{r=await L2.lstat(e)}catch{return"file"}return r&&r.isDirectory()?"dir":"file"}function yme(e,t){if(t)return t;let r;try{r=L2.lstatSync(e)}catch{return"file"}return r&&r.isDirectory()?"dir":"file"}B2.exports={symlinkType:mme(gme),symlinkTypeSync:yme}});var U2=E((Hlt,j2)=>{"use strict";var _me=Hr().fromPromise,ua=require("path"),ni=Ln(),{mkdirs:bme,mkdirsSync:Eme}=eo(),{symlinkPaths:wme,symlinkPathsSync:Sme}=M2(),{symlinkType:vme,symlinkTypeSync:Cme}=F2(),{pathExists:xme}=sa(),{areIdentical:q2}=Mc();async function Tme(e,t,r){let n;try{n=await ni.lstat(t)}catch{}if(n&&n.isSymbolicLink()){let a;if(ua.isAbsolute(e))a=await ni.stat(e);else{let u=ua.dirname(t),l=ua.join(u,e);try{a=await ni.stat(l)}catch{a=await ni.stat(e)}}let c=await ni.stat(t);if(q2(a,c))return}let i=await wme(e,t);e=i.toDst;let o=await vme(i.toCwd,r),s=ua.dirname(t);return await xme(s)||await bme(s),ni.symlink(e,t,o)}function Ame(e,t,r){let n;try{n=ni.lstatSync(t)}catch{}if(n&&n.isSymbolicLink()){let a;if(ua.isAbsolute(e))a=ni.statSync(e);else{let u=ua.dirname(t),l=ua.join(u,e);try{a=ni.statSync(l)}catch{a=ni.statSync(e)}}let c=ni.statSync(t);if(q2(a,c))return}let i=Sme(e,t);e=i.toDst,r=Cme(i.toCwd,r);let o=ua.dirname(t);return ni.existsSync(o)||Eme(o),ni.symlinkSync(e,t,r)}j2.exports={createSymlink:_me(Tme),createSymlinkSync:Ame}});var Y2=E(($lt,K2)=>{"use strict";var{createFile:H2,createFileSync:$2}=R2(),{createLink:G2,createLinkSync:z2}=k2(),{createSymlink:V2,createSymlinkSync:W2}=U2();K2.exports={createFile:H2,createFileSync:$2,ensureFile:H2,ensureFileSync:$2,createLink:G2,createLinkSync:z2,ensureLink:G2,ensureLinkSync:z2,createSymlink:V2,createSymlinkSync:W2,ensureSymlink:V2,ensureSymlinkSync:W2}});var xy=E((Glt,X2)=>{"use strict";function Rme(e,{EOL:t=`
|
|
7
|
+
`,finalEOL:r=!0,replacer:n=null,spaces:i}={}){let o=r?t:"";return JSON.stringify(e,n,i).replace(/\n/g,t)+o}function Pme(e){return Buffer.isBuffer(e)&&(e=e.toString("utf8")),e.replace(/^\uFEFF/,"")}X2.exports={stringify:Rme,stripBom:Pme}});var e3=E((zlt,Z2)=>{"use strict";var hl;try{hl=Nc()}catch{hl=require("fs")}var Ty=Hr(),{stringify:J2,stripBom:Q2}=xy();async function Ome(e,t={}){typeof t=="string"&&(t={encoding:t});let r=t.fs||hl,n="throws"in t?t.throws:!0,i=await Ty.fromCallback(r.readFile)(e,t);i=Q2(i);let o;try{o=JSON.parse(i,t?t.reviver:null)}catch(s){if(n)throw s.message=`${e}: ${s.message}`,s;return null}return o}var Ime=Ty.fromPromise(Ome);function Dme(e,t={}){typeof t=="string"&&(t={encoding:t});let r=t.fs||hl,n="throws"in t?t.throws:!0;try{let i=r.readFileSync(e,t);return i=Q2(i),JSON.parse(i,t.reviver)}catch(i){if(n)throw i.message=`${e}: ${i.message}`,i;return null}}async function kme(e,t,r={}){let n=r.fs||hl,i=J2(t,r);await Ty.fromCallback(n.writeFile)(e,i,r)}var Nme=Ty.fromPromise(kme);function Mme(e,t,r={}){let n=r.fs||hl,i=J2(t,r);return n.writeFileSync(e,i,r)}Z2.exports={readFile:Ime,readFileSync:Dme,writeFile:Nme,writeFileSync:Mme}});var r3=E((Vlt,t3)=>{"use strict";var Ay=e3();t3.exports={readJson:Ay.readFile,readJsonSync:Ay.readFileSync,writeJson:Ay.writeFile,writeJsonSync:Ay.writeFileSync}});var Ry=E((Wlt,o3)=>{"use strict";var Lme=Hr().fromPromise,xT=Ln(),n3=require("path"),i3=eo(),Bme=sa().pathExists;async function Fme(e,t,r="utf-8"){let n=n3.dirname(e);return await Bme(n)||await i3.mkdirs(n),xT.writeFile(e,t,r)}function qme(e,...t){let r=n3.dirname(e);xT.existsSync(r)||i3.mkdirsSync(r),xT.writeFileSync(e,...t)}o3.exports={outputFile:Lme(Fme),outputFileSync:qme}});var a3=E((Klt,s3)=>{"use strict";var{stringify:jme}=xy(),{outputFile:Ume}=Ry();async function Hme(e,t,r={}){let n=jme(t,r);await Ume(e,n,r)}s3.exports=Hme});var u3=E((Ylt,c3)=>{"use strict";var{stringify:$me}=xy(),{outputFileSync:Gme}=Ry();function zme(e,t,r){let n=$me(t,r);Gme(e,n,r)}c3.exports=zme});var f3=E((Xlt,l3)=>{"use strict";var Vme=Hr().fromPromise,Fn=r3();Fn.outputJson=Vme(a3());Fn.outputJsonSync=u3();Fn.outputJSON=Fn.outputJson;Fn.outputJSONSync=Fn.outputJsonSync;Fn.writeJSON=Fn.writeJson;Fn.writeJSONSync=Fn.writeJsonSync;Fn.readJSON=Fn.readJson;Fn.readJSONSync=Fn.readJsonSync;l3.exports=Fn});var g3=E((Jlt,m3)=>{"use strict";var Wme=Ln(),d3=require("path"),{copy:Kme}=Cy(),{remove:h3}=_p(),{mkdirp:Yme}=eo(),{pathExists:Xme}=sa(),p3=Mc();async function Jme(e,t,r={}){let n=r.overwrite||r.clobber||!1,{srcStat:i,isChangingCase:o=!1}=await p3.checkPaths(e,t,"move",r);await p3.checkParentPaths(e,i,t,"move");let s=d3.dirname(t);return d3.parse(s).root!==s&&await Yme(s),Qme(e,t,n,o)}async function Qme(e,t,r,n){if(!n){if(r)await h3(t);else if(await Xme(t))throw new Error("dest already exists.")}try{await Wme.rename(e,t)}catch(i){if(i.code!=="EXDEV")throw i;await Zme(e,t,r)}}async function Zme(e,t,r){return await Kme(e,t,{overwrite:r,errorOnExist:!0,preserveTimestamps:!0}),h3(e)}m3.exports=Jme});var w3=E((Qlt,E3)=>{"use strict";var _3=Nc(),AT=require("path"),ege=Cy().copySync,b3=_p().removeSync,tge=eo().mkdirpSync,y3=Mc();function rge(e,t,r){r=r||{};let n=r.overwrite||r.clobber||!1,{srcStat:i,isChangingCase:o=!1}=y3.checkPathsSync(e,t,"move",r);return y3.checkParentPathsSync(e,i,t,"move"),nge(t)||tge(AT.dirname(t)),ige(e,t,n,o)}function nge(e){let t=AT.dirname(e);return AT.parse(t).root===t}function ige(e,t,r,n){if(n)return TT(e,t,r);if(r)return b3(t),TT(e,t,r);if(_3.existsSync(t))throw new Error("dest already exists.");return TT(e,t,r)}function TT(e,t,r){try{_3.renameSync(e,t)}catch(n){if(n.code!=="EXDEV")throw n;return oge(e,t,r)}}function oge(e,t,r){return ege(e,t,{overwrite:r,errorOnExist:!0,preserveTimestamps:!0}),b3(e)}E3.exports=rge});var v3=E((Zlt,S3)=>{"use strict";var sge=Hr().fromPromise;S3.exports={move:sge(g3()),moveSync:w3()}});var RT=E((eft,C3)=>{"use strict";C3.exports={...Ln(),...Cy(),...C2(),...Y2(),...f3(),...eo(),...v3(),...Ry(),...sa(),..._p()}});var T3=E((tft,x3)=>{"use strict";x3.exports=lge;var age=sy(),PT=RT(),Py=require("path"),cge=require("stream"),uge=dT();function lge(e){e.path=Py.resolve(Py.normalize(e.path));let t=new age(e),r=new cge.Writable({objectMode:!0});r._write=async function(i,o,s){let a=Py.join(e.path,i.path.replace(/\\/g,"/"));if(a.indexOf(e.path)!=0)return s();if(i.type=="Directory")return await PT.ensureDir(a),s();await PT.ensureDir(Py.dirname(a));let c=e.getWriter?e.getWriter({path:a}):PT.createWriteStream(a);i.pipe(c).on("error",s).on("close",s)};let n=uge(t,r);return t.once("crx-header",function(i){n.crxHeader=i}),t.pipe(r).on("finish",function(){n.emit("close")}),n.promise=function(){return new Promise(function(i,o){n.on("close",i),n.on("error",o)})},n}});var P3=E((rft,R3)=>{"use strict";var OT=4294967296,A3=[];for(ml=0;ml<256;ml++)A3[ml]=(ml>15?"":"0")+ml.toString(16);var ml,Ep=R3.exports=function(e,t){e instanceof Buffer?(this.buffer=e,this.offset=t||0):Object.prototype.toString.call(e)=="[object Uint8Array]"?(this.buffer=new Buffer(e),this.offset=t||0):(this.buffer=this.buffer||new Buffer(8),this.offset=0,this.setValue.apply(this,arguments))};Ep.MAX_INT=Math.pow(2,53);Ep.MIN_INT=-Math.pow(2,53);Ep.prototype={constructor:Ep,_2scomp:function(){for(var e=this.buffer,t=this.offset,r=1,n=t+7;n>=t;n--){var i=(e[n]^255)+r;e[n]=i&255,r=i>>8}},setValue:function(e,t){var r=!1;if(arguments.length==1)if(typeof e=="number"){if(r=e<0,e=Math.abs(e),t=e%OT,e=e/OT,e>OT)throw new RangeError(e+" is outside Int64 range");e=e|0}else if(typeof e=="string")e=(e+"").replace(/^0x/,""),t=e.substr(-8),e=e.length>8?e.substr(0,e.length-8):"",e=parseInt(e,16),t=parseInt(t,16);else throw new Error(e+" must be a Number or String");for(var n=this.buffer,i=this.offset,o=7;o>=0;o--)n[i+o]=t&255,t=o==4?e:t>>>8;r&&this._2scomp()},toNumber:function(e){for(var t=this.buffer,r=this.offset,n=t[r]&128,i=0,o=1,s=7,a=1;s>=0;s--,a*=256){var c=t[r+s];n&&(c=(c^255)+o,o=c>>8,c=c&255),i+=c*a}return!e&&i>=Ep.MAX_INT?n?-1/0:1/0:n?-i:i},valueOf:function(){return this.toNumber(!1)},toString:function(e){return this.valueOf().toString(e||10)},toOctetString:function(e){for(var t=new Array(8),r=this.buffer,n=this.offset,i=0;i<8;i++)t[i]=A3[r[n+i]];return t.join(e||"")},toBuffer:function(e){if(e&&this.offset===0)return this.buffer;var t=new Buffer(8);return this.buffer.copy(t,0,this.offset,this.offset+8),t},copy:function(e,t){this.buffer.copy(e,t||0,this.offset,this.offset+8)},compare:function(e){if((this.buffer[this.offset]&128)!=(e.buffer[e.offset]&128))return e.buffer[e.offset]-this.buffer[this.offset];for(var t=0;t<8;t++)if(this.buffer[this.offset+t]!==e.buffer[e.offset+t])return this.buffer[this.offset+t]-e.buffer[e.offset+t];return 0},equals:function(e){return this.compare(e)===0},inspect:function(){return"[Int64 value:"+this+" octets:"+this.toOctetString(" ")+"]"}}});var er=E((nft,O3)=>{"use strict";var IT=class extends Error{constructor(t){if(!Array.isArray(t))throw new TypeError(`Expected input to be an Array, got ${typeof t}`);let r="";for(let n=0;n<t.length;n++)r+=` ${t[n].stack}
|
|
8
|
+
`;super(r),this.name="AggregateError",this.errors=t}};O3.exports={AggregateError:IT,ArrayIsArray(e){return Array.isArray(e)},ArrayPrototypeIncludes(e,t){return e.includes(t)},ArrayPrototypeIndexOf(e,t){return e.indexOf(t)},ArrayPrototypeJoin(e,t){return e.join(t)},ArrayPrototypeMap(e,t){return e.map(t)},ArrayPrototypePop(e,t){return e.pop(t)},ArrayPrototypePush(e,t){return e.push(t)},ArrayPrototypeSlice(e,t,r){return e.slice(t,r)},Error,FunctionPrototypeCall(e,t,...r){return e.call(t,...r)},FunctionPrototypeSymbolHasInstance(e,t){return Function.prototype[Symbol.hasInstance].call(e,t)},MathFloor:Math.floor,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(e,t){return Object.defineProperties(e,t)},ObjectDefineProperty(e,t,r){return Object.defineProperty(e,t,r)},ObjectGetOwnPropertyDescriptor(e,t){return Object.getOwnPropertyDescriptor(e,t)},ObjectKeys(e){return Object.keys(e)},ObjectSetPrototypeOf(e,t){return Object.setPrototypeOf(e,t)},Promise,PromisePrototypeCatch(e,t){return e.catch(t)},PromisePrototypeThen(e,t,r){return e.then(t,r)},PromiseReject(e){return Promise.reject(e)},PromiseResolve(e){return Promise.resolve(e)},ReflectApply:Reflect.apply,RegExpPrototypeTest(e,t){return e.test(t)},SafeSet:Set,String,StringPrototypeSlice(e,t,r){return e.slice(t,r)},StringPrototypeToLowerCase(e){return e.toLowerCase()},StringPrototypeToUpperCase(e){return e.toUpperCase()},StringPrototypeTrim(e){return e.trim()},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(e,t,r){return e.set(t,r)},Boolean,Uint8Array}});var DT=E((ift,I3)=>{"use strict";I3.exports={format(e,...t){return e.replace(/%([sdifj])/g,function(...[r,n]){let i=t.shift();return n==="f"?i.toFixed(6):n==="j"?JSON.stringify(i):n==="s"&&typeof i=="object"?`${i.constructor!==Object?i.constructor.name:""} {}`.trim():i.toString()})},inspect(e){switch(typeof e){case"string":if(e.includes("'"))if(e.includes('"')){if(!e.includes("`")&&!e.includes("${"))return`\`${e}\``}else return`"${e}"`;return`'${e}'`;case"number":return isNaN(e)?"NaN":Object.is(e,-0)?String(e):e;case"bigint":return`${String(e)}n`;case"boolean":case"undefined":return String(e);case"object":return"{}"}}}});var yn=E((oft,N3)=>{"use strict";var{format:fge,inspect:Oy}=DT(),{AggregateError:dge}=er(),pge=globalThis.AggregateError||dge,hge=Symbol("kIsNodeError"),mge=["string","function","number","object","Function","Object","boolean","bigint","symbol"],gge=/^([A-Z][a-z0-9]*)+$/,yge="__node_internal_",Iy={};function Lc(e,t){if(!e)throw new Iy.ERR_INTERNAL_ASSERTION(t)}function D3(e){let t="",r=e.length,n=e[0]==="-"?1:0;for(;r>=n+4;r-=3)t=`_${e.slice(r-3,r)}${t}`;return`${e.slice(0,r)}${t}`}function _ge(e,t,r){if(typeof t=="function")return Lc(t.length<=r.length,`Code: ${e}; The provided arguments length (${r.length}) does not match the required ones (${t.length}).`),t(...r);let n=(t.match(/%[dfijoOs]/g)||[]).length;return Lc(n===r.length,`Code: ${e}; The provided arguments length (${r.length}) does not match the required ones (${n}).`),r.length===0?t:fge(t,...r)}function sn(e,t,r){r||(r=Error);class n extends r{constructor(...o){super(_ge(e,t,o))}toString(){return`${this.name} [${e}]: ${this.message}`}}Object.defineProperties(n.prototype,{name:{value:r.name,writable:!0,enumerable:!1,configurable:!0},toString:{value(){return`${this.name} [${e}]: ${this.message}`},writable:!0,enumerable:!1,configurable:!0}}),n.prototype.code=e,n.prototype[hge]=!0,Iy[e]=n}function k3(e){let t=yge+e.name;return Object.defineProperty(e,"name",{value:t}),e}function bge(e,t){if(e&&t&&e!==t){if(Array.isArray(t.errors))return t.errors.push(e),t;let r=new pge([t,e],t.message);return r.code=t.code,r}return e||t}var kT=class extends Error{constructor(t="The operation was aborted",r=void 0){if(r!==void 0&&typeof r!="object")throw new Iy.ERR_INVALID_ARG_TYPE("options","Object",r);super(t,r),this.code="ABORT_ERR",this.name="AbortError"}};sn("ERR_ASSERTION","%s",Error);sn("ERR_INVALID_ARG_TYPE",(e,t,r)=>{Lc(typeof e=="string","'name' must be a string"),Array.isArray(t)||(t=[t]);let n="The ";e.endsWith(" argument")?n+=`${e} `:n+=`"${e}" ${e.includes(".")?"property":"argument"} `,n+="must be ";let i=[],o=[],s=[];for(let c of t)Lc(typeof c=="string","All expected entries have to be of type string"),mge.includes(c)?i.push(c.toLowerCase()):gge.test(c)?o.push(c):(Lc(c!=="object",'The value "object" should be written as "Object"'),s.push(c));if(o.length>0){let c=i.indexOf("object");c!==-1&&(i.splice(i,c,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:{let c=i.pop();n+=`one of type ${i.join(", ")}, or ${c}`}}(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:{let c=o.pop();n+=`an instance of ${o.join(", ")}, or ${c}`}}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:{let c=s.pop();n+=`one of ${s.join(", ")}, or ${c}`}}if(r==null)n+=`. Received ${r}`;else if(typeof r=="function"&&r.name)n+=`. Received function ${r.name}`;else if(typeof r=="object"){var a;if((a=r.constructor)!==null&&a!==void 0&&a.name)n+=`. Received an instance of ${r.constructor.name}`;else{let c=Oy(r,{depth:-1});n+=`. Received ${c}`}}else{let c=Oy(r,{colors:!1});c.length>25&&(c=`${c.slice(0,25)}...`),n+=`. Received type ${typeof r} (${c})`}return n},TypeError);sn("ERR_INVALID_ARG_VALUE",(e,t,r="is invalid")=>{let n=Oy(t);return n.length>128&&(n=n.slice(0,128)+"..."),`The ${e.includes(".")?"property":"argument"} '${e}' ${r}. Received ${n}`},TypeError);sn("ERR_INVALID_RETURN_VALUE",(e,t,r)=>{var n;let i=r!=null&&(n=r.constructor)!==null&&n!==void 0&&n.name?`instance of ${r.constructor.name}`:`type ${typeof r}`;return`Expected ${e} to be returned from the "${t}" function but got ${i}.`},TypeError);sn("ERR_MISSING_ARGS",(...e)=>{Lc(e.length>0,"At least one arg needs to be specified");let t,r=e.length;switch(e=(Array.isArray(e)?e:[e]).map(n=>`"${n}"`).join(" or "),r){case 1:t+=`The ${e[0]} argument`;break;case 2:t+=`The ${e[0]} and ${e[1]} arguments`;break;default:{let n=e.pop();t+=`The ${e.join(", ")}, and ${n} arguments`}break}return`${t} must be specified`},TypeError);sn("ERR_OUT_OF_RANGE",(e,t,r)=>{Lc(t,'Missing "range" argument');let n;if(Number.isInteger(r)&&Math.abs(r)>2**32)n=D3(String(r));else if(typeof r=="bigint"){n=String(r);let i=BigInt(2)**BigInt(32);(r>i||r<-i)&&(n=D3(n)),n+="n"}else n=Oy(r);return`The value of "${e}" is out of range. It must be ${t}. Received ${n}`},RangeError);sn("ERR_MULTIPLE_CALLBACK","Callback called multiple times",Error);sn("ERR_METHOD_NOT_IMPLEMENTED","The %s method is not implemented",Error);sn("ERR_STREAM_ALREADY_FINISHED","Cannot call %s after a stream was finished",Error);sn("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable",Error);sn("ERR_STREAM_DESTROYED","Cannot call %s after a stream was destroyed",Error);sn("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError);sn("ERR_STREAM_PREMATURE_CLOSE","Premature close",Error);sn("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF",Error);sn("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event",Error);sn("ERR_STREAM_WRITE_AFTER_END","write after end",Error);sn("ERR_UNKNOWN_ENCODING","Unknown encoding: %s",TypeError);N3.exports={AbortError:kT,aggregateTwoErrors:k3(bge),hideStackFrames:k3,codes:Iy}});var G3=E((vp,Sp)=>{"use strict";Object.defineProperty(vp,"__esModule",{value:!0});var j3=new WeakMap,NT=new WeakMap;function Jt(e){let t=j3.get(e);return console.assert(t!=null,"'this' is expected an Event object, but got",e),t}function M3(e){if(e.passiveListener!=null){typeof console<"u"&&typeof console.error=="function"&&console.error("Unable to preventDefault inside passive event listener invocation.",e.passiveListener);return}e.event.cancelable&&(e.canceled=!0,typeof e.event.preventDefault=="function"&&e.event.preventDefault())}function gl(e,t){j3.set(this,{eventTarget:e,event:t,eventPhase:2,currentTarget:e,canceled:!1,stopped:!1,immediateStopped:!1,passiveListener:null,timeStamp:t.timeStamp||Date.now()}),Object.defineProperty(this,"isTrusted",{value:!1,enumerable:!0});let r=Object.keys(t);for(let n=0;n<r.length;++n){let i=r[n];i in this||Object.defineProperty(this,i,U3(i))}}gl.prototype={get type(){return Jt(this).event.type},get target(){return Jt(this).eventTarget},get currentTarget(){return Jt(this).currentTarget},composedPath(){let e=Jt(this).currentTarget;return e==null?[]:[e]},get NONE(){return 0},get CAPTURING_PHASE(){return 1},get AT_TARGET(){return 2},get BUBBLING_PHASE(){return 3},get eventPhase(){return Jt(this).eventPhase},stopPropagation(){let e=Jt(this);e.stopped=!0,typeof e.event.stopPropagation=="function"&&e.event.stopPropagation()},stopImmediatePropagation(){let e=Jt(this);e.stopped=!0,e.immediateStopped=!0,typeof e.event.stopImmediatePropagation=="function"&&e.event.stopImmediatePropagation()},get bubbles(){return!!Jt(this).event.bubbles},get cancelable(){return!!Jt(this).event.cancelable},preventDefault(){M3(Jt(this))},get defaultPrevented(){return Jt(this).canceled},get composed(){return!!Jt(this).event.composed},get timeStamp(){return Jt(this).timeStamp},get srcElement(){return Jt(this).eventTarget},get cancelBubble(){return Jt(this).stopped},set cancelBubble(e){if(!e)return;let t=Jt(this);t.stopped=!0,typeof t.event.cancelBubble=="boolean"&&(t.event.cancelBubble=!0)},get returnValue(){return!Jt(this).canceled},set returnValue(e){e||M3(Jt(this))},initEvent(){}};Object.defineProperty(gl.prototype,"constructor",{value:gl,configurable:!0,writable:!0});typeof window<"u"&&typeof window.Event<"u"&&(Object.setPrototypeOf(gl.prototype,window.Event.prototype),NT.set(window.Event.prototype,gl));function U3(e){return{get(){return Jt(this).event[e]},set(t){Jt(this).event[e]=t},configurable:!0,enumerable:!0}}function Ege(e){return{value(){let t=Jt(this).event;return t[e].apply(t,arguments)},configurable:!0,enumerable:!0}}function wge(e,t){let r=Object.keys(t);if(r.length===0)return e;function n(i,o){e.call(this,i,o)}n.prototype=Object.create(e.prototype,{constructor:{value:n,configurable:!0,writable:!0}});for(let i=0;i<r.length;++i){let o=r[i];if(!(o in e.prototype)){let a=typeof Object.getOwnPropertyDescriptor(t,o).value=="function";Object.defineProperty(n.prototype,o,a?Ege(o):U3(o))}}return n}function H3(e){if(e==null||e===Object.prototype)return gl;let t=NT.get(e);return t==null&&(t=wge(H3(Object.getPrototypeOf(e)),e),NT.set(e,t)),t}function Sge(e,t){let r=H3(Object.getPrototypeOf(t));return new r(e,t)}function vge(e){return Jt(e).immediateStopped}function Cge(e,t){Jt(e).eventPhase=t}function xge(e,t){Jt(e).currentTarget=t}function L3(e,t){Jt(e).passiveListener=t}var $3=new WeakMap,B3=1,F3=2,Dy=3;function ky(e){return e!==null&&typeof e=="object"}function wp(e){let t=$3.get(e);if(t==null)throw new TypeError("'this' is expected an EventTarget object, but got another value.");return t}function Tge(e){return{get(){let r=wp(this).get(e);for(;r!=null;){if(r.listenerType===Dy)return r.listener;r=r.next}return null},set(t){typeof t!="function"&&!ky(t)&&(t=null);let r=wp(this),n=null,i=r.get(e);for(;i!=null;)i.listenerType===Dy?n!==null?n.next=i.next:i.next!==null?r.set(e,i.next):r.delete(e):n=i,i=i.next;if(t!==null){let o={listener:t,listenerType:Dy,passive:!1,once:!1,next:null};n===null?r.set(e,o):n.next=o}},configurable:!0,enumerable:!0}}function MT(e,t){Object.defineProperty(e,`on${t}`,Tge(t))}function q3(e){function t(){to.call(this)}t.prototype=Object.create(to.prototype,{constructor:{value:t,configurable:!0,writable:!0}});for(let r=0;r<e.length;++r)MT(t.prototype,e[r]);return t}function to(){if(this instanceof to){$3.set(this,new Map);return}if(arguments.length===1&&Array.isArray(arguments[0]))return q3(arguments[0]);if(arguments.length>0){let e=new Array(arguments.length);for(let t=0;t<arguments.length;++t)e[t]=arguments[t];return q3(e)}throw new TypeError("Cannot call a class as a function")}to.prototype={addEventListener(e,t,r){if(t==null)return;if(typeof t!="function"&&!ky(t))throw new TypeError("'listener' should be a function or an object.");let n=wp(this),i=ky(r),s=(i?!!r.capture:!!r)?B3:F3,a={listener:t,listenerType:s,passive:i&&!!r.passive,once:i&&!!r.once,next:null},c=n.get(e);if(c===void 0){n.set(e,a);return}let u=null;for(;c!=null;){if(c.listener===t&&c.listenerType===s)return;u=c,c=c.next}u.next=a},removeEventListener(e,t,r){if(t==null)return;let n=wp(this),o=(ky(r)?!!r.capture:!!r)?B3:F3,s=null,a=n.get(e);for(;a!=null;){if(a.listener===t&&a.listenerType===o){s!==null?s.next=a.next:a.next!==null?n.set(e,a.next):n.delete(e);return}s=a,a=a.next}},dispatchEvent(e){if(e==null||typeof e.type!="string")throw new TypeError('"event.type" should be a string.');let t=wp(this),r=e.type,n=t.get(r);if(n==null)return!0;let i=Sge(this,e),o=null;for(;n!=null;){if(n.once?o!==null?o.next=n.next:n.next!==null?t.set(r,n.next):t.delete(r):o=n,L3(i,n.passive?n.listener:null),typeof n.listener=="function")try{n.listener.call(this,i)}catch(s){typeof console<"u"&&typeof console.error=="function"&&console.error(s)}else n.listenerType!==Dy&&typeof n.listener.handleEvent=="function"&&n.listener.handleEvent(i);if(vge(i))break;n=n.next}return L3(i,null),Cge(i,0),xge(i,null),!i.defaultPrevented}};Object.defineProperty(to.prototype,"constructor",{value:to,configurable:!0,writable:!0});typeof window<"u"&&typeof window.EventTarget<"u"&&Object.setPrototypeOf(to.prototype,window.EventTarget.prototype);vp.defineEventAttribute=MT;vp.EventTarget=to;vp.default=to;Sp.exports=to;Sp.exports.EventTarget=Sp.exports.default=to;Sp.exports.defineEventAttribute=MT});var yl=E((xp,Cp)=>{"use strict";Object.defineProperty(xp,"__esModule",{value:!0});var LT=G3(),la=class extends LT.EventTarget{constructor(){throw super(),new TypeError("AbortSignal cannot be constructed directly")}get aborted(){let t=Ny.get(this);if(typeof t!="boolean")throw new TypeError(`Expected 'this' to be an 'AbortSignal' object, but got ${this===null?"null":typeof this}`);return t}};LT.defineEventAttribute(la.prototype,"abort");function Age(){let e=Object.create(la.prototype);return LT.EventTarget.call(e),Ny.set(e,!1),e}function Rge(e){Ny.get(e)===!1&&(Ny.set(e,!0),e.dispatchEvent({type:"abort"}))}var Ny=new WeakMap;Object.defineProperties(la.prototype,{aborted:{enumerable:!0}});typeof Symbol=="function"&&typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(la.prototype,Symbol.toStringTag,{configurable:!0,value:"AbortSignal"});var fa=class{constructor(){V3.set(this,Age())}get signal(){return z3(this)}abort(){Rge(z3(this))}},V3=new WeakMap;function z3(e){let t=V3.get(e);if(t==null)throw new TypeError(`Expected 'this' to be an 'AbortController' object, but got ${e===null?"null":typeof e}`);return t}Object.defineProperties(fa.prototype,{signal:{enumerable:!0},abort:{enumerable:!0}});typeof Symbol=="function"&&typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(fa.prototype,Symbol.toStringTag,{configurable:!0,value:"AbortController"});xp.AbortController=fa;xp.AbortSignal=la;xp.default=fa;Cp.exports=fa;Cp.exports.AbortController=Cp.exports.default=fa;Cp.exports.AbortSignal=la});var qn=E((sft,FT)=>{"use strict";var Pge=require("buffer"),{format:Oge,inspect:Ige}=DT(),{codes:{ERR_INVALID_ARG_TYPE:BT}}=yn(),{kResistStopPropagation:Dge,AggregateError:kge,SymbolDispose:Nge}=er(),Mge=globalThis.AbortSignal||yl().AbortSignal,Lge=globalThis.AbortController||yl().AbortController,Bge=Object.getPrototypeOf(async function(){}).constructor,W3=globalThis.Blob||Pge.Blob,Fge=typeof W3<"u"?function(t){return t instanceof W3}:function(t){return!1},K3=(e,t)=>{if(e!==void 0&&(e===null||typeof e!="object"||!("aborted"in e)))throw new BT(t,"AbortSignal",e)},qge=(e,t)=>{if(typeof e!="function")throw new BT(t,"Function",e)};FT.exports={AggregateError:kge,kEmptyObject:Object.freeze({}),once(e){let t=!1;return function(...r){t||(t=!0,e.apply(this,r))}},createDeferredPromise:function(){let e,t;return{promise:new Promise((n,i)=>{e=n,t=i}),resolve:e,reject:t}},promisify(e){return new Promise((t,r)=>{e((n,...i)=>n?r(n):t(...i))})},debuglog(){return function(){}},format:Oge,inspect:Ige,types:{isAsyncFunction(e){return e instanceof Bge},isArrayBufferView(e){return ArrayBuffer.isView(e)}},isBlob:Fge,deprecate(e,t){return e},addAbortListener:require("events").addAbortListener||function(t,r){if(t===void 0)throw new BT("signal","AbortSignal",t);K3(t,"signal"),qge(r,"listener");let n;return t.aborted?queueMicrotask(()=>r()):(t.addEventListener("abort",r,{__proto__:null,once:!0,[Dge]:!0}),n=()=>{t.removeEventListener("abort",r)}),{__proto__:null,[Nge](){var i;(i=n)===null||i===void 0||i()}}},AbortSignalAny:Mge.any||function(t){if(t.length===1)return t[0];let r=new Lge,n=()=>r.abort();return t.forEach(i=>{K3(i,"signals"),i.addEventListener("abort",n,{once:!0})}),r.signal.addEventListener("abort",()=>{t.forEach(i=>i.removeEventListener("abort",n))},{once:!0}),r.signal}};FT.exports.promisify.custom=Symbol.for("nodejs.util.promisify.custom")});var bl=E((aft,iF)=>{"use strict";var{ArrayIsArray:jT,ArrayPrototypeIncludes:Q3,ArrayPrototypeJoin:Z3,ArrayPrototypeMap:jge,NumberIsInteger:UT,NumberIsNaN:Uge,NumberMAX_SAFE_INTEGER:Hge,NumberMIN_SAFE_INTEGER:$ge,NumberParseInt:Gge,ObjectPrototypeHasOwnProperty:zge,RegExpPrototypeExec:eF,String:Vge,StringPrototypeToUpperCase:Wge,StringPrototypeTrim:Kge}=er(),{hideStackFrames:Oi,codes:{ERR_SOCKET_BAD_PORT:Yge,ERR_INVALID_ARG_TYPE:_n,ERR_INVALID_ARG_VALUE:_l,ERR_OUT_OF_RANGE:Bc,ERR_UNKNOWN_SIGNAL:Y3}}=yn(),{normalizeEncoding:Xge}=qn(),{isAsyncFunction:Jge,isArrayBufferView:Qge}=qn().types,X3={};function Zge(e){return e===(e|0)}function eye(e){return e===e>>>0}var tye=/^[0-7]+$/,rye="must be a 32-bit unsigned integer or an octal string";function nye(e,t,r){if(typeof e>"u"&&(e=r),typeof e=="string"){if(eF(tye,e)===null)throw new _l(t,e,rye);e=Gge(e,8)}return tF(e,t),e}var iye=Oi((e,t,r=$ge,n=Hge)=>{if(typeof e!="number")throw new _n(t,"number",e);if(!UT(e))throw new Bc(t,"an integer",e);if(e<r||e>n)throw new Bc(t,`>= ${r} && <= ${n}`,e)}),oye=Oi((e,t,r=-2147483648,n=2147483647)=>{if(typeof e!="number")throw new _n(t,"number",e);if(!UT(e))throw new Bc(t,"an integer",e);if(e<r||e>n)throw new Bc(t,`>= ${r} && <= ${n}`,e)}),tF=Oi((e,t,r=!1)=>{if(typeof e!="number")throw new _n(t,"number",e);if(!UT(e))throw new Bc(t,"an integer",e);let n=r?1:0,i=4294967295;if(e<n||e>i)throw new Bc(t,`>= ${n} && <= ${i}`,e)});function HT(e,t){if(typeof e!="string")throw new _n(t,"string",e)}function sye(e,t,r=void 0,n){if(typeof e!="number")throw new _n(t,"number",e);if(r!=null&&e<r||n!=null&&e>n||(r!=null||n!=null)&&Uge(e))throw new Bc(t,`${r!=null?`>= ${r}`:""}${r!=null&&n!=null?" && ":""}${n!=null?`<= ${n}`:""}`,e)}var aye=Oi((e,t,r)=>{if(!Q3(r,e)){let i="must be one of: "+Z3(jge(r,o=>typeof o=="string"?`'${o}'`:Vge(o)),", ");throw new _l(t,e,i)}});function rF(e,t){if(typeof e!="boolean")throw new _n(t,"boolean",e)}function qT(e,t,r){return e==null||!zge(e,t)?r:e[t]}var cye=Oi((e,t,r=null)=>{let n=qT(r,"allowArray",!1),i=qT(r,"allowFunction",!1);if(!qT(r,"nullable",!1)&&e===null||!n&&jT(e)||typeof e!="object"&&(!i||typeof e!="function"))throw new _n(t,"Object",e)}),uye=Oi((e,t)=>{if(e!=null&&typeof e!="object"&&typeof e!="function")throw new _n(t,"a dictionary",e)}),My=Oi((e,t,r=0)=>{if(!jT(e))throw new _n(t,"Array",e);if(e.length<r){let n=`must be longer than ${r}`;throw new _l(t,e,n)}});function lye(e,t){My(e,t);for(let r=0;r<e.length;r++)HT(e[r],`${t}[${r}]`)}function fye(e,t){My(e,t);for(let r=0;r<e.length;r++)rF(e[r],`${t}[${r}]`)}function dye(e,t){My(e,t);for(let r=0;r<e.length;r++){let n=e[r],i=`${t}[${r}]`;if(n==null)throw new _n(i,"AbortSignal",n);nF(n,i)}}function pye(e,t="signal"){if(HT(e,t),X3[e]===void 0)throw X3[Wge(e)]!==void 0?new Y3(e+" (signals must use all capital letters)"):new Y3(e)}var hye=Oi((e,t="buffer")=>{if(!Qge(e))throw new _n(t,["Buffer","TypedArray","DataView"],e)});function mye(e,t){let r=Xge(t),n=e.length;if(r==="hex"&&n%2!==0)throw new _l("encoding",t,`is invalid for data of length ${n}`)}function gye(e,t="Port",r=!0){if(typeof e!="number"&&typeof e!="string"||typeof e=="string"&&Kge(e).length===0||+e!==+e>>>0||e>65535||e===0&&!r)throw new Yge(t,e,r);return e|0}var nF=Oi((e,t)=>{if(e!==void 0&&(e===null||typeof e!="object"||!("aborted"in e)))throw new _n(t,"AbortSignal",e)}),yye=Oi((e,t)=>{if(typeof e!="function")throw new _n(t,"Function",e)}),_ye=Oi((e,t)=>{if(typeof e!="function"||Jge(e))throw new _n(t,"Function",e)}),bye=Oi((e,t)=>{if(e!==void 0)throw new _n(t,"undefined",e)});function Eye(e,t,r){if(!Q3(r,e))throw new _n(t,`('${Z3(r,"|")}')`,e)}var wye=/^(?:<[^>]*>)(?:\s*;\s*[^;"\s]+(?:=(")?[^;"\s]*\1)?)*$/;function J3(e,t){if(typeof e>"u"||!eF(wye,e))throw new _l(t,e,'must be an array or string of format "</styles.css>; rel=preload; as=style"')}function Sye(e){if(typeof e=="string")return J3(e,"hints"),e;if(jT(e)){let t=e.length,r="";if(t===0)return r;for(let n=0;n<t;n++){let i=e[n];J3(i,"hints"),r+=i,n!==t-1&&(r+=", ")}return r}throw new _l("hints",e,'must be an array or string of format "</styles.css>; rel=preload; as=style"')}iF.exports={isInt32:Zge,isUint32:eye,parseFileMode:nye,validateArray:My,validateStringArray:lye,validateBooleanArray:fye,validateAbortSignalArray:dye,validateBoolean:rF,validateBuffer:hye,validateDictionary:uye,validateEncoding:mye,validateFunction:yye,validateInt32:oye,validateInteger:iye,validateNumber:sye,validateObject:cye,validateOneOf:aye,validatePlainFunction:_ye,validatePort:gye,validateSignalName:pye,validateString:HT,validateUint32:tF,validateUndefined:bye,validateUnion:Eye,validateAbortSignal:nF,validateLinkHeaderValue:Sye}});var da=E((cft,oF)=>{"use strict";oF.exports=global.process});var Oo=E((uft,EF)=>{"use strict";var{SymbolAsyncIterator:sF,SymbolIterator:aF,SymbolFor:Fc}=er(),cF=Fc("nodejs.stream.destroyed"),uF=Fc("nodejs.stream.errored"),$T=Fc("nodejs.stream.readable"),GT=Fc("nodejs.stream.writable"),lF=Fc("nodejs.stream.disturbed"),vye=Fc("nodejs.webstream.isClosedPromise"),Cye=Fc("nodejs.webstream.controllerErrorFunction");function Ly(e,t=!1){var r;return!!(e&&typeof e.pipe=="function"&&typeof e.on=="function"&&(!t||typeof e.pause=="function"&&typeof e.resume=="function")&&(!e._writableState||((r=e._readableState)===null||r===void 0?void 0:r.readable)!==!1)&&(!e._writableState||e._readableState))}function By(e){var t;return!!(e&&typeof e.write=="function"&&typeof e.on=="function"&&(!e._readableState||((t=e._writableState)===null||t===void 0?void 0:t.writable)!==!1))}function xye(e){return!!(e&&typeof e.pipe=="function"&&e._readableState&&typeof e.on=="function"&&typeof e.write=="function")}function Po(e){return e&&(e._readableState||e._writableState||typeof e.write=="function"&&typeof e.on=="function"||typeof e.pipe=="function"&&typeof e.on=="function")}function fF(e){return!!(e&&!Po(e)&&typeof e.pipeThrough=="function"&&typeof e.getReader=="function"&&typeof e.cancel=="function")}function dF(e){return!!(e&&!Po(e)&&typeof e.getWriter=="function"&&typeof e.abort=="function")}function pF(e){return!!(e&&!Po(e)&&typeof e.readable=="object"&&typeof e.writable=="object")}function Tye(e){return fF(e)||dF(e)||pF(e)}function Aye(e,t){return e==null?!1:t===!0?typeof e[sF]=="function":t===!1?typeof e[aF]=="function":typeof e[sF]=="function"||typeof e[aF]=="function"}function Fy(e){if(!Po(e))return null;let t=e._writableState,r=e._readableState,n=t||r;return!!(e.destroyed||e[cF]||n!=null&&n.destroyed)}function hF(e){if(!By(e))return null;if(e.writableEnded===!0)return!0;let t=e._writableState;return t!=null&&t.errored?!1:typeof t?.ended!="boolean"?null:t.ended}function Rye(e,t){if(!By(e))return null;if(e.writableFinished===!0)return!0;let r=e._writableState;return r!=null&&r.errored?!1:typeof r?.finished!="boolean"?null:!!(r.finished||t===!1&&r.ended===!0&&r.length===0)}function Pye(e){if(!Ly(e))return null;if(e.readableEnded===!0)return!0;let t=e._readableState;return!t||t.errored?!1:typeof t?.ended!="boolean"?null:t.ended}function mF(e,t){if(!Ly(e))return null;let r=e._readableState;return r!=null&&r.errored?!1:typeof r?.endEmitted!="boolean"?null:!!(r.endEmitted||t===!1&&r.ended===!0&&r.length===0)}function gF(e){return e&&e[$T]!=null?e[$T]:typeof e?.readable!="boolean"?null:Fy(e)?!1:Ly(e)&&e.readable&&!mF(e)}function yF(e){return e&&e[GT]!=null?e[GT]:typeof e?.writable!="boolean"?null:Fy(e)?!1:By(e)&&e.writable&&!hF(e)}function Oye(e,t){return Po(e)?Fy(e)?!0:!(t?.readable!==!1&&gF(e)||t?.writable!==!1&&yF(e)):null}function Iye(e){var t,r;return Po(e)?e.writableErrored?e.writableErrored:(t=(r=e._writableState)===null||r===void 0?void 0:r.errored)!==null&&t!==void 0?t:null:null}function Dye(e){var t,r;return Po(e)?e.readableErrored?e.readableErrored:(t=(r=e._readableState)===null||r===void 0?void 0:r.errored)!==null&&t!==void 0?t:null:null}function kye(e){if(!Po(e))return null;if(typeof e.closed=="boolean")return e.closed;let t=e._writableState,r=e._readableState;return typeof t?.closed=="boolean"||typeof r?.closed=="boolean"?t?.closed||r?.closed:typeof e._closed=="boolean"&&_F(e)?e._closed:null}function _F(e){return typeof e._closed=="boolean"&&typeof e._defaultKeepAlive=="boolean"&&typeof e._removedConnection=="boolean"&&typeof e._removedContLen=="boolean"}function bF(e){return typeof e._sent100=="boolean"&&_F(e)}function Nye(e){var t;return typeof e._consuming=="boolean"&&typeof e._dumped=="boolean"&&((t=e.req)===null||t===void 0?void 0:t.upgradeOrConnect)===void 0}function Mye(e){if(!Po(e))return null;let t=e._writableState,r=e._readableState,n=t||r;return!n&&bF(e)||!!(n&&n.autoDestroy&&n.emitClose&&n.closed===!1)}function Lye(e){var t;return!!(e&&((t=e[lF])!==null&&t!==void 0?t:e.readableDidRead||e.readableAborted))}function Bye(e){var t,r,n,i,o,s,a,c,u,l;return!!(e&&((t=(r=(n=(i=(o=(s=e[uF])!==null&&s!==void 0?s:e.readableErrored)!==null&&o!==void 0?o:e.writableErrored)!==null&&i!==void 0?i:(a=e._readableState)===null||a===void 0?void 0:a.errorEmitted)!==null&&n!==void 0?n:(c=e._writableState)===null||c===void 0?void 0:c.errorEmitted)!==null&&r!==void 0?r:(u=e._readableState)===null||u===void 0?void 0:u.errored)!==null&&t!==void 0?t:!((l=e._writableState)===null||l===void 0)&&l.errored))}EF.exports={isDestroyed:Fy,kIsDestroyed:cF,isDisturbed:Lye,kIsDisturbed:lF,isErrored:Bye,kIsErrored:uF,isReadable:gF,kIsReadable:$T,kIsClosedPromise:vye,kControllerErrorFunction:Cye,kIsWritable:GT,isClosed:kye,isDuplexNodeStream:xye,isFinished:Oye,isIterable:Aye,isReadableNodeStream:Ly,isReadableStream:fF,isReadableEnded:Pye,isReadableFinished:mF,isReadableErrored:Dye,isNodeStream:Po,isWebStream:Tye,isWritable:yF,isWritableNodeStream:By,isWritableStream:dF,isWritableEnded:hF,isWritableFinished:Rye,isWritableErrored:Iye,isServerRequest:Nye,isServerResponse:bF,willEmitClose:Mye,isTransformStream:pF}});var bs=E((lft,YT)=>{"use strict";var pa=da(),{AbortError:PF,codes:Fye}=yn(),{ERR_INVALID_ARG_TYPE:qye,ERR_STREAM_PREMATURE_CLOSE:wF}=Fye,{kEmptyObject:VT,once:WT}=qn(),{validateAbortSignal:jye,validateFunction:Uye,validateObject:Hye,validateBoolean:$ye}=bl(),{Promise:Gye,PromisePrototypeThen:zye,SymbolDispose:OF}=er(),{isClosed:Vye,isReadable:SF,isReadableNodeStream:zT,isReadableStream:Wye,isReadableFinished:vF,isReadableErrored:CF,isWritable:xF,isWritableNodeStream:TF,isWritableStream:Kye,isWritableFinished:AF,isWritableErrored:RF,isNodeStream:Yye,willEmitClose:Xye,kIsClosedPromise:Jye}=Oo(),El;function Qye(e){return e.setHeader&&typeof e.abort=="function"}var KT=()=>{};function IF(e,t,r){var n,i;if(arguments.length===2?(r=t,t=VT):t==null?t=VT:Hye(t,"options"),Uye(r,"callback"),jye(t.signal,"options.signal"),r=WT(r),Wye(e)||Kye(e))return Zye(e,t,r);if(!Yye(e))throw new qye("stream",["ReadableStream","WritableStream","Stream"],e);let o=(n=t.readable)!==null&&n!==void 0?n:zT(e),s=(i=t.writable)!==null&&i!==void 0?i:TF(e),a=e._writableState,c=e._readableState,u=()=>{e.writable||h()},l=Xye(e)&&zT(e)===o&&TF(e)===s,d=AF(e,!1),h=()=>{d=!0,e.destroyed&&(l=!1),!(l&&(!e.readable||o))&&(!o||f)&&r.call(e)},f=vF(e,!1),p=()=>{f=!0,e.destroyed&&(l=!1),!(l&&(!e.writable||s))&&(!s||d)&&r.call(e)},m=S=>{r.call(e,S)},_=Vye(e),w=()=>{_=!0;let S=RF(e)||CF(e);if(S&&typeof S!="boolean")return r.call(e,S);if(o&&!f&&zT(e,!0)&&!vF(e,!1))return r.call(e,new wF);if(s&&!d&&!AF(e,!1))return r.call(e,new wF);r.call(e)},R=()=>{_=!0;let S=RF(e)||CF(e);if(S&&typeof S!="boolean")return r.call(e,S);r.call(e)},v=()=>{e.req.on("finish",h)};Qye(e)?(e.on("complete",h),l||e.on("abort",w),e.req?v():e.on("request",v)):s&&!a&&(e.on("end",u),e.on("close",u)),!l&&typeof e.aborted=="boolean"&&e.on("aborted",w),e.on("end",p),e.on("finish",h),t.error!==!1&&e.on("error",m),e.on("close",w),_?pa.nextTick(w):a!=null&&a.errorEmitted||c!=null&&c.errorEmitted?l||pa.nextTick(R):(!o&&(!l||SF(e))&&(d||xF(e)===!1)||!s&&(!l||xF(e))&&(f||SF(e)===!1)||c&&e.req&&e.aborted)&&pa.nextTick(R);let y=()=>{r=KT,e.removeListener("aborted",w),e.removeListener("complete",h),e.removeListener("abort",w),e.removeListener("request",v),e.req&&e.req.removeListener("finish",h),e.removeListener("end",u),e.removeListener("close",u),e.removeListener("finish",h),e.removeListener("end",p),e.removeListener("error",m),e.removeListener("close",w)};if(t.signal&&!_){let S=()=>{let O=r;y(),O.call(e,new PF(void 0,{cause:t.signal.reason}))};if(t.signal.aborted)pa.nextTick(S);else{El=El||qn().addAbortListener;let O=El(t.signal,S),M=r;r=WT((...A)=>{O[OF](),M.apply(e,A)})}}return y}function Zye(e,t,r){let n=!1,i=KT;if(t.signal)if(i=()=>{n=!0,r.call(e,new PF(void 0,{cause:t.signal.reason}))},t.signal.aborted)pa.nextTick(i);else{El=El||qn().addAbortListener;let s=El(t.signal,i),a=r;r=WT((...c)=>{s[OF](),a.apply(e,c)})}let o=(...s)=>{n||pa.nextTick(()=>r.apply(e,s))};return zye(e[Jye].promise,o,o),KT}function e_e(e,t){var r;let n=!1;return t===null&&(t=VT),(r=t)!==null&&r!==void 0&&r.cleanup&&($ye(t.cleanup,"cleanup"),n=t.cleanup),new Gye((i,o)=>{let s=IF(e,t,a=>{n&&s(),a?o(a):i()})})}YT.exports=IF;YT.exports.finished=e_e});var qc=E((fft,qF)=>{"use strict";var Io=da(),{aggregateTwoErrors:t_e,codes:{ERR_MULTIPLE_CALLBACK:r_e},AbortError:n_e}=yn(),{Symbol:NF}=er(),{kIsDestroyed:i_e,isDestroyed:o_e,isFinished:s_e,isServerRequest:a_e}=Oo(),MF=NF("kDestroy"),XT=NF("kConstruct");function LF(e,t,r){e&&(e.stack,t&&!t.errored&&(t.errored=e),r&&!r.errored&&(r.errored=e))}function c_e(e,t){let r=this._readableState,n=this._writableState,i=n||r;return n!=null&&n.destroyed||r!=null&&r.destroyed?(typeof t=="function"&&t(),this):(LF(e,n,r),n&&(n.destroyed=!0),r&&(r.destroyed=!0),i.constructed?DF(this,e,t):this.once(MF,function(o){DF(this,t_e(o,e),t)}),this)}function DF(e,t,r){let n=!1;function i(o){if(n)return;n=!0;let s=e._readableState,a=e._writableState;LF(o,a,s),a&&(a.closed=!0),s&&(s.closed=!0),typeof r=="function"&&r(o),o?Io.nextTick(u_e,e,o):Io.nextTick(BF,e)}try{e._destroy(t||null,i)}catch(o){i(o)}}function u_e(e,t){JT(e,t),BF(e)}function BF(e){let t=e._readableState,r=e._writableState;r&&(r.closeEmitted=!0),t&&(t.closeEmitted=!0),(r!=null&&r.emitClose||t!=null&&t.emitClose)&&e.emit("close")}function JT(e,t){let r=e._readableState,n=e._writableState;n!=null&&n.errorEmitted||r!=null&&r.errorEmitted||(n&&(n.errorEmitted=!0),r&&(r.errorEmitted=!0),e.emit("error",t))}function l_e(){let e=this._readableState,t=this._writableState;e&&(e.constructed=!0,e.closed=!1,e.closeEmitted=!1,e.destroyed=!1,e.errored=null,e.errorEmitted=!1,e.reading=!1,e.ended=e.readable===!1,e.endEmitted=e.readable===!1),t&&(t.constructed=!0,t.destroyed=!1,t.closed=!1,t.closeEmitted=!1,t.errored=null,t.errorEmitted=!1,t.finalCalled=!1,t.prefinished=!1,t.ended=t.writable===!1,t.ending=t.writable===!1,t.finished=t.writable===!1)}function QT(e,t,r){let n=e._readableState,i=e._writableState;if(i!=null&&i.destroyed||n!=null&&n.destroyed)return this;n!=null&&n.autoDestroy||i!=null&&i.autoDestroy?e.destroy(t):t&&(t.stack,i&&!i.errored&&(i.errored=t),n&&!n.errored&&(n.errored=t),r?Io.nextTick(JT,e,t):JT(e,t))}function f_e(e,t){if(typeof e._construct!="function")return;let r=e._readableState,n=e._writableState;r&&(r.constructed=!1),n&&(n.constructed=!1),e.once(XT,t),!(e.listenerCount(XT)>1)&&Io.nextTick(d_e,e)}function d_e(e){let t=!1;function r(n){if(t){QT(e,n??new r_e);return}t=!0;let i=e._readableState,o=e._writableState,s=o||i;i&&(i.constructed=!0),o&&(o.constructed=!0),s.destroyed?e.emit(MF,n):n?QT(e,n,!0):Io.nextTick(p_e,e)}try{e._construct(n=>{Io.nextTick(r,n)})}catch(n){Io.nextTick(r,n)}}function p_e(e){e.emit(XT)}function kF(e){return e?.setHeader&&typeof e.abort=="function"}function FF(e){e.emit("close")}function h_e(e,t){e.emit("error",t),Io.nextTick(FF,e)}function m_e(e,t){!e||o_e(e)||(!t&&!s_e(e)&&(t=new n_e),a_e(e)?(e.socket=null,e.destroy(t)):kF(e)?e.abort():kF(e.req)?e.req.abort():typeof e.destroy=="function"?e.destroy(t):typeof e.close=="function"?e.close():t?Io.nextTick(h_e,e,t):Io.nextTick(FF,e),e.destroyed||(e[i_e]=!0))}qF.exports={construct:f_e,destroyer:m_e,destroy:c_e,undestroy:l_e,errorOrDestroy:QT}});var Uy=E((dft,UF)=>{"use strict";var{ArrayIsArray:g_e,ObjectSetPrototypeOf:jF}=er(),{EventEmitter:qy}=require("events");function jy(e){qy.call(this,e)}jF(jy.prototype,qy.prototype);jF(jy,qy);jy.prototype.pipe=function(e,t){let r=this;function n(l){e.writable&&e.write(l)===!1&&r.pause&&r.pause()}r.on("data",n);function i(){r.readable&&r.resume&&r.resume()}e.on("drain",i),!e._isStdio&&(!t||t.end!==!1)&&(r.on("end",s),r.on("close",a));let o=!1;function s(){o||(o=!0,e.end())}function a(){o||(o=!0,typeof e.destroy=="function"&&e.destroy())}function c(l){u(),qy.listenerCount(this,"error")===0&&this.emit("error",l)}ZT(r,"error",c),ZT(e,"error",c);function u(){r.removeListener("data",n),e.removeListener("drain",i),r.removeListener("end",s),r.removeListener("close",a),r.removeListener("error",c),e.removeListener("error",c),r.removeListener("end",u),r.removeListener("close",u),e.removeListener("close",u)}return r.on("end",u),r.on("close",u),e.on("close",u),e.emit("pipe",r),e};function ZT(e,t,r){if(typeof e.prependListener=="function")return e.prependListener(t,r);!e._events||!e._events[t]?e.on(t,r):g_e(e._events[t])?e._events[t].unshift(r):e._events[t]=[r,e._events[t]]}UF.exports={Stream:jy,prependListener:ZT}});var Tp=E((pft,Hy)=>{"use strict";var{SymbolDispose:y_e}=er(),{AbortError:HF,codes:__e}=yn(),{isNodeStream:$F,isWebStream:b_e,kControllerErrorFunction:E_e}=Oo(),w_e=bs(),{ERR_INVALID_ARG_TYPE:GF}=__e,eA,S_e=(e,t)=>{if(typeof e!="object"||!("aborted"in e))throw new GF(t,"AbortSignal",e)};Hy.exports.addAbortSignal=function(t,r){if(S_e(t,"signal"),!$F(r)&&!b_e(r))throw new GF("stream",["ReadableStream","WritableStream","Stream"],r);return Hy.exports.addAbortSignalNoValidate(t,r)};Hy.exports.addAbortSignalNoValidate=function(e,t){if(typeof e!="object"||!("aborted"in e))return t;let r=$F(t)?()=>{t.destroy(new HF(void 0,{cause:e.reason}))}:()=>{t[E_e](new HF(void 0,{cause:e.reason}))};if(e.aborted)r();else{eA=eA||qn().addAbortListener;let n=eA(e,r);w_e(t,n[y_e])}return t}});var WF=E((mft,VF)=>{"use strict";var{StringPrototypeSlice:zF,SymbolIterator:v_e,TypedArrayPrototypeSet:$y,Uint8Array:C_e}=er(),{Buffer:tA}=require("buffer"),{inspect:x_e}=qn();VF.exports=class{constructor(){this.head=null,this.tail=null,this.length=0}push(t){let r={data:t,next:null};this.length>0?this.tail.next=r:this.head=r,this.tail=r,++this.length}unshift(t){let r={data:t,next:this.head};this.length===0&&(this.tail=r),this.head=r,++this.length}shift(){if(this.length===0)return;let t=this.head.data;return this.length===1?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(this.length===0)return"";let r=this.head,n=""+r.data;for(;(r=r.next)!==null;)n+=t+r.data;return n}concat(t){if(this.length===0)return tA.alloc(0);let r=tA.allocUnsafe(t>>>0),n=this.head,i=0;for(;n;)$y(r,n.data,i),i+=n.data.length,n=n.next;return r}consume(t,r){let n=this.head.data;if(t<n.length){let i=n.slice(0,t);return this.head.data=n.slice(t),i}return t===n.length?this.shift():r?this._getString(t):this._getBuffer(t)}first(){return this.head.data}*[v_e](){for(let t=this.head;t;t=t.next)yield t.data}_getString(t){let r="",n=this.head,i=0;do{let o=n.data;if(t>o.length)r+=o,t-=o.length;else{t===o.length?(r+=o,++i,n.next?this.head=n.next:this.head=this.tail=null):(r+=zF(o,0,t),this.head=n,n.data=zF(o,t));break}++i}while((n=n.next)!==null);return this.length-=i,r}_getBuffer(t){let r=tA.allocUnsafe(t),n=t,i=this.head,o=0;do{let s=i.data;if(t>s.length)$y(r,s,n-t),t-=s.length;else{t===s.length?($y(r,s,n-t),++o,i.next?this.head=i.next:this.head=this.tail=null):($y(r,new C_e(s.buffer,s.byteOffset,t),n-t),this.head=i,i.data=s.slice(t));break}++o}while((i=i.next)!==null);return this.length-=o,r}[Symbol.for("nodejs.util.inspect.custom")](t,r){return x_e(this,{...r,depth:0,customInspect:!1})}}});var Ap=E((gft,JF)=>{"use strict";var{MathFloor:T_e,NumberIsInteger:A_e}=er(),{validateInteger:R_e}=bl(),{ERR_INVALID_ARG_VALUE:P_e}=yn().codes,KF=16*1024,YF=16;function O_e(e,t,r){return e.highWaterMark!=null?e.highWaterMark:t?e[r]:null}function XF(e){return e?YF:KF}function I_e(e,t){R_e(t,"value",0),e?YF=t:KF=t}function D_e(e,t,r,n){let i=O_e(t,n,r);if(i!=null){if(!A_e(i)||i<0){let o=n?`options.${r}`:"options.highWaterMark";throw new P_e(o,i)}return T_e(i)}return XF(e.objectMode)}JF.exports={getHighWaterMark:D_e,getDefaultHighWaterMark:XF,setDefaultHighWaterMark:I_e}});var eq=E((rA,ZF)=>{"use strict";var Gy=require("buffer"),Do=Gy.Buffer;function QF(e,t){for(var r in e)t[r]=e[r]}Do.from&&Do.alloc&&Do.allocUnsafe&&Do.allocUnsafeSlow?ZF.exports=Gy:(QF(Gy,rA),rA.Buffer=jc);function jc(e,t,r){return Do(e,t,r)}jc.prototype=Object.create(Do.prototype);QF(Do,jc);jc.from=function(e,t,r){if(typeof e=="number")throw new TypeError("Argument must not be a number");return Do(e,t,r)};jc.alloc=function(e,t,r){if(typeof e!="number")throw new TypeError("Argument must be a number");var n=Do(e);return t!==void 0?typeof r=="string"?n.fill(t,r):n.fill(t):n.fill(0),n};jc.allocUnsafe=function(e){if(typeof e!="number")throw new TypeError("Argument must be a number");return Do(e)};jc.allocUnsafeSlow=function(e){if(typeof e!="number")throw new TypeError("Argument must be a number");return Gy.SlowBuffer(e)}});var wl=E(rq=>{"use strict";var iA=eq().Buffer,tq=iA.isEncoding||function(e){switch(e=""+e,e&&e.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function k_e(e){if(!e)return"utf8";for(var t;;)switch(e){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return e;default:if(t)return;e=(""+e).toLowerCase(),t=!0}}function N_e(e){var t=k_e(e);if(typeof t!="string"&&(iA.isEncoding===tq||!tq(e)))throw new Error("Unknown encoding: "+e);return t||e}rq.StringDecoder=Rp;function Rp(e){this.encoding=N_e(e);var t;switch(this.encoding){case"utf16le":this.text=j_e,this.end=U_e,t=4;break;case"utf8":this.fillLast=B_e,t=4;break;case"base64":this.text=H_e,this.end=$_e,t=3;break;default:this.write=G_e,this.end=z_e;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=iA.allocUnsafe(t)}Rp.prototype.write=function(e){if(e.length===0)return"";var t,r;if(this.lastNeed){if(t=this.fillLast(e),t===void 0)return"";r=this.lastNeed,this.lastNeed=0}else r=0;return r<e.length?t?t+this.text(e,r):this.text(e,r):t||""};Rp.prototype.end=q_e;Rp.prototype.text=F_e;Rp.prototype.fillLast=function(e){if(this.lastNeed<=e.length)return e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,e.length),this.lastNeed-=e.length};function nA(e){return e<=127?0:e>>5===6?2:e>>4===14?3:e>>3===30?4:e>>6===2?-1:-2}function M_e(e,t,r){var n=t.length-1;if(n<r)return 0;var i=nA(t[n]);return i>=0?(i>0&&(e.lastNeed=i-1),i):--n<r||i===-2?0:(i=nA(t[n]),i>=0?(i>0&&(e.lastNeed=i-2),i):--n<r||i===-2?0:(i=nA(t[n]),i>=0?(i>0&&(i===2?i=0:e.lastNeed=i-3),i):0))}function L_e(e,t,r){if((t[0]&192)!==128)return e.lastNeed=0,"\uFFFD";if(e.lastNeed>1&&t.length>1){if((t[1]&192)!==128)return e.lastNeed=1,"\uFFFD";if(e.lastNeed>2&&t.length>2&&(t[2]&192)!==128)return e.lastNeed=2,"\uFFFD"}}function B_e(e){var t=this.lastTotal-this.lastNeed,r=L_e(this,e,t);if(r!==void 0)return r;if(this.lastNeed<=e.length)return e.copy(this.lastChar,t,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);e.copy(this.lastChar,t,0,e.length),this.lastNeed-=e.length}function F_e(e,t){var r=M_e(this,e,t);if(!this.lastNeed)return e.toString("utf8",t);this.lastTotal=r;var n=e.length-(r-this.lastNeed);return e.copy(this.lastChar,0,n),e.toString("utf8",t,n)}function q_e(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+"\uFFFD":t}function j_e(e,t){if((e.length-t)%2===0){var r=e.toString("utf16le",t);if(r){var n=r.charCodeAt(r.length-1);if(n>=55296&&n<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1],r.slice(0,-1)}return r}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=e[e.length-1],e.toString("utf16le",t,e.length-1)}function U_e(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed){var r=this.lastTotal-this.lastNeed;return t+this.lastChar.toString("utf16le",0,r)}return t}function H_e(e,t){var r=(e.length-t)%3;return r===0?e.toString("base64",t):(this.lastNeed=3-r,this.lastTotal=3,r===1?this.lastChar[0]=e[e.length-1]:(this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1]),e.toString("base64",t,e.length-r))}function $_e(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+this.lastChar.toString("base64",0,3-this.lastNeed):t}function G_e(e){return e.toString(this.encoding)}function z_e(e){return e&&e.length?this.write(e):""}});var oA=E((_ft,sq)=>{"use strict";var nq=da(),{PromisePrototypeThen:V_e,SymbolAsyncIterator:iq,SymbolIterator:oq}=er(),{Buffer:W_e}=require("buffer"),{ERR_INVALID_ARG_TYPE:K_e,ERR_STREAM_NULL_VALUES:Y_e}=yn().codes;function X_e(e,t,r){let n;if(typeof t=="string"||t instanceof W_e)return new e({objectMode:!0,...r,read(){this.push(t),this.push(null)}});let i;if(t&&t[iq])i=!0,n=t[iq]();else if(t&&t[oq])i=!1,n=t[oq]();else throw new K_e("iterable",["Iterable"],t);let o=new e({objectMode:!0,highWaterMark:1,...r}),s=!1;o._read=function(){s||(s=!0,c())},o._destroy=function(u,l){V_e(a(u),()=>nq.nextTick(l,u),d=>nq.nextTick(l,d||u))};async function a(u){let l=u!=null,d=typeof n.throw=="function";if(l&&d){let{value:h,done:f}=await n.throw(u);if(await h,f)return}if(typeof n.return=="function"){let{value:h}=await n.return();await h}}async function c(){for(;;){try{let{value:u,done:l}=i?await n.next():n.next();if(l)o.push(null);else{let d=u&&typeof u.then=="function"?await u:u;if(d===null)throw s=!1,new Y_e;if(o.push(d))continue;s=!1}}catch(u){o.destroy(u)}break}}return o}sq.exports=X_e});var Op=E((bft,Cq)=>{"use strict";var ro=da(),{ArrayPrototypeIndexOf:J_e,NumberIsInteger:Q_e,NumberIsNaN:Z_e,NumberParseInt:ebe,ObjectDefineProperties:pA,ObjectKeys:tbe,ObjectSetPrototypeOf:uq,Promise:lq,SafeSet:rbe,SymbolAsyncDispose:nbe,SymbolAsyncIterator:ibe,Symbol:obe}=er();Cq.exports=Ye;Ye.ReadableState=Ky;var{EventEmitter:sbe}=require("events"),{Stream:ha,prependListener:abe}=Uy(),{Buffer:sA}=require("buffer"),{addAbortSignal:cbe}=Tp(),fq=bs(),ut=qn().debuglog("stream",e=>{ut=e}),ube=WF(),Cl=qc(),{getHighWaterMark:lbe,getDefaultHighWaterMark:fbe}=Ap(),{aggregateTwoErrors:aq,codes:{ERR_INVALID_ARG_TYPE:dbe,ERR_METHOD_NOT_IMPLEMENTED:pbe,ERR_OUT_OF_RANGE:hbe,ERR_STREAM_PUSH_AFTER_EOF:mbe,ERR_STREAM_UNSHIFT_AFTER_END_EVENT:gbe},AbortError:ybe}=yn(),{validateObject:_be}=bl(),Uc=obe("kPaused"),{StringDecoder:dq}=wl(),bbe=oA();uq(Ye.prototype,ha.prototype);uq(Ye,ha);var aA=()=>{},{errorOrDestroy:Sl}=Cl,vl=1,Ebe=2,pq=4,Pp=8,hq=16,zy=32,Vy=64,mq=128,wbe=256,Sbe=512,vbe=1024,fA=2048,dA=4096,Cbe=8192,xbe=16384,Tbe=32768,gq=65536,Abe=1<<17,Rbe=1<<18;function Or(e){return{enumerable:!1,get(){return(this.state&e)!==0},set(t){t?this.state|=e:this.state&=~e}}}pA(Ky.prototype,{objectMode:Or(vl),ended:Or(Ebe),endEmitted:Or(pq),reading:Or(Pp),constructed:Or(hq),sync:Or(zy),needReadable:Or(Vy),emittedReadable:Or(mq),readableListening:Or(wbe),resumeScheduled:Or(Sbe),errorEmitted:Or(vbe),emitClose:Or(fA),autoDestroy:Or(dA),destroyed:Or(Cbe),closed:Or(xbe),closeEmitted:Or(Tbe),multiAwaitDrain:Or(gq),readingMore:Or(Abe),dataEmitted:Or(Rbe)});function Ky(e,t,r){typeof r!="boolean"&&(r=t instanceof ko()),this.state=fA|dA|hq|zy,e&&e.objectMode&&(this.state|=vl),r&&e&&e.readableObjectMode&&(this.state|=vl),this.highWaterMark=e?lbe(this,e,"readableHighWaterMark",r):fbe(!1),this.buffer=new ube,this.length=0,this.pipes=[],this.flowing=null,this[Uc]=null,e&&e.emitClose===!1&&(this.state&=~fA),e&&e.autoDestroy===!1&&(this.state&=~dA),this.errored=null,this.defaultEncoding=e&&e.defaultEncoding||"utf8",this.awaitDrainWriters=null,this.decoder=null,this.encoding=null,e&&e.encoding&&(this.decoder=new dq(e.encoding),this.encoding=e.encoding)}function Ye(e){if(!(this instanceof Ye))return new Ye(e);let t=this instanceof ko();this._readableState=new Ky(e,this,t),e&&(typeof e.read=="function"&&(this._read=e.read),typeof e.destroy=="function"&&(this._destroy=e.destroy),typeof e.construct=="function"&&(this._construct=e.construct),e.signal&&!t&&cbe(e.signal,this)),ha.call(this,e),Cl.construct(this,()=>{this._readableState.needReadable&&Wy(this,this._readableState)})}Ye.prototype.destroy=Cl.destroy;Ye.prototype._undestroy=Cl.undestroy;Ye.prototype._destroy=function(e,t){t(e)};Ye.prototype[sbe.captureRejectionSymbol]=function(e){this.destroy(e)};Ye.prototype[nbe]=function(){let e;return this.destroyed||(e=this.readableEnded?null:new ybe,this.destroy(e)),new lq((t,r)=>fq(this,n=>n&&n!==e?r(n):t(null)))};Ye.prototype.push=function(e,t){return yq(this,e,t,!1)};Ye.prototype.unshift=function(e,t){return yq(this,e,t,!0)};function yq(e,t,r,n){ut("readableAddChunk",t);let i=e._readableState,o;if((i.state&vl)===0&&(typeof t=="string"?(r=r||i.defaultEncoding,i.encoding!==r&&(n&&i.encoding?t=sA.from(t,r).toString(i.encoding):(t=sA.from(t,r),r=""))):t instanceof sA?r="":ha._isUint8Array(t)?(t=ha._uint8ArrayToBuffer(t),r=""):t!=null&&(o=new dbe("chunk",["string","Buffer","Uint8Array"],t))),o)Sl(e,o);else if(t===null)i.state&=~Pp,Ibe(e,i);else if((i.state&vl)!==0||t&&t.length>0)if(n)if((i.state&pq)!==0)Sl(e,new gbe);else{if(i.destroyed||i.errored)return!1;cA(e,i,t,!0)}else if(i.ended)Sl(e,new mbe);else{if(i.destroyed||i.errored)return!1;i.state&=~Pp,i.decoder&&!r?(t=i.decoder.write(t),i.objectMode||t.length!==0?cA(e,i,t,!1):Wy(e,i)):cA(e,i,t,!1)}else n||(i.state&=~Pp,Wy(e,i));return!i.ended&&(i.length<i.highWaterMark||i.length===0)}function cA(e,t,r,n){t.flowing&&t.length===0&&!t.sync&&e.listenerCount("data")>0?((t.state&gq)!==0?t.awaitDrainWriters.clear():t.awaitDrainWriters=null,t.dataEmitted=!0,e.emit("data",r)):(t.length+=t.objectMode?1:r.length,n?t.buffer.unshift(r):t.buffer.push(r),(t.state&Vy)!==0&&Yy(e)),Wy(e,t)}Ye.prototype.isPaused=function(){let e=this._readableState;return e[Uc]===!0||e.flowing===!1};Ye.prototype.setEncoding=function(e){let t=new dq(e);this._readableState.decoder=t,this._readableState.encoding=this._readableState.decoder.encoding;let r=this._readableState.buffer,n="";for(let i of r)n+=t.write(i);return r.clear(),n!==""&&r.push(n),this._readableState.length=n.length,this};var Pbe=1073741824;function Obe(e){if(e>Pbe)throw new hbe("size","<= 1GiB",e);return e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++,e}function cq(e,t){return e<=0||t.length===0&&t.ended?0:(t.state&vl)!==0?1:Z_e(e)?t.flowing&&t.length?t.buffer.first().length:t.length:e<=t.length?e:t.ended?t.length:0}Ye.prototype.read=function(e){ut("read",e),e===void 0?e=NaN:Q_e(e)||(e=ebe(e,10));let t=this._readableState,r=e;if(e>t.highWaterMark&&(t.highWaterMark=Obe(e)),e!==0&&(t.state&=~mq),e===0&&t.needReadable&&((t.highWaterMark!==0?t.length>=t.highWaterMark:t.length>0)||t.ended))return ut("read: emitReadable",t.length,t.ended),t.length===0&&t.ended?uA(this):Yy(this),null;if(e=cq(e,t),e===0&&t.ended)return t.length===0&&uA(this),null;let n=(t.state&Vy)!==0;if(ut("need readable",n),(t.length===0||t.length-e<t.highWaterMark)&&(n=!0,ut("length less than watermark",n)),t.ended||t.reading||t.destroyed||t.errored||!t.constructed)n=!1,ut("reading, ended or constructing",n);else if(n){ut("do read"),t.state|=Pp|zy,t.length===0&&(t.state|=Vy);try{this._read(t.highWaterMark)}catch(o){Sl(this,o)}t.state&=~zy,t.reading||(e=cq(r,t))}let i;return e>0?i=Sq(e,t):i=null,i===null?(t.needReadable=t.length<=t.highWaterMark,e=0):(t.length-=e,t.multiAwaitDrain?t.awaitDrainWriters.clear():t.awaitDrainWriters=null),t.length===0&&(t.ended||(t.needReadable=!0),r!==e&&t.ended&&uA(this)),i!==null&&!t.errorEmitted&&!t.closeEmitted&&(t.dataEmitted=!0,this.emit("data",i)),i};function Ibe(e,t){if(ut("onEofChunk"),!t.ended){if(t.decoder){let r=t.decoder.end();r&&r.length&&(t.buffer.push(r),t.length+=t.objectMode?1:r.length)}t.ended=!0,t.sync?Yy(e):(t.needReadable=!1,t.emittedReadable=!0,_q(e))}}function Yy(e){let t=e._readableState;ut("emitReadable",t.needReadable,t.emittedReadable),t.needReadable=!1,t.emittedReadable||(ut("emitReadable",t.flowing),t.emittedReadable=!0,ro.nextTick(_q,e))}function _q(e){let t=e._readableState;ut("emitReadable_",t.destroyed,t.length,t.ended),!t.destroyed&&!t.errored&&(t.length||t.ended)&&(e.emit("readable"),t.emittedReadable=!1),t.needReadable=!t.flowing&&!t.ended&&t.length<=t.highWaterMark,Eq(e)}function Wy(e,t){!t.readingMore&&t.constructed&&(t.readingMore=!0,ro.nextTick(Dbe,e,t))}function Dbe(e,t){for(;!t.reading&&!t.ended&&(t.length<t.highWaterMark||t.flowing&&t.length===0);){let r=t.length;if(ut("maybeReadMore read 0"),e.read(0),r===t.length)break}t.readingMore=!1}Ye.prototype._read=function(e){throw new pbe("_read()")};Ye.prototype.pipe=function(e,t){let r=this,n=this._readableState;n.pipes.length===1&&(n.multiAwaitDrain||(n.multiAwaitDrain=!0,n.awaitDrainWriters=new rbe(n.awaitDrainWriters?[n.awaitDrainWriters]:[]))),n.pipes.push(e),ut("pipe count=%d opts=%j",n.pipes.length,t);let o=(!t||t.end!==!1)&&e!==ro.stdout&&e!==ro.stderr?a:_;n.endEmitted?ro.nextTick(o):r.once("end",o),e.on("unpipe",s);function s(w,R){ut("onunpipe"),w===r&&R&&R.hasUnpiped===!1&&(R.hasUnpiped=!0,l())}function a(){ut("onend"),e.end()}let c,u=!1;function l(){ut("cleanup"),e.removeListener("close",p),e.removeListener("finish",m),c&&e.removeListener("drain",c),e.removeListener("error",f),e.removeListener("unpipe",s),r.removeListener("end",a),r.removeListener("end",_),r.removeListener("data",h),u=!0,c&&n.awaitDrainWriters&&(!e._writableState||e._writableState.needDrain)&&c()}function d(){u||(n.pipes.length===1&&n.pipes[0]===e?(ut("false write response, pause",0),n.awaitDrainWriters=e,n.multiAwaitDrain=!1):n.pipes.length>1&&n.pipes.includes(e)&&(ut("false write response, pause",n.awaitDrainWriters.size),n.awaitDrainWriters.add(e)),r.pause()),c||(c=kbe(r,e),e.on("drain",c))}r.on("data",h);function h(w){ut("ondata");let R=e.write(w);ut("dest.write",R),R===!1&&d()}function f(w){if(ut("onerror",w),_(),e.removeListener("error",f),e.listenerCount("error")===0){let R=e._writableState||e._readableState;R&&!R.errorEmitted?Sl(e,w):e.emit("error",w)}}abe(e,"error",f);function p(){e.removeListener("finish",m),_()}e.once("close",p);function m(){ut("onfinish"),e.removeListener("close",p),_()}e.once("finish",m);function _(){ut("unpipe"),r.unpipe(e)}return e.emit("pipe",r),e.writableNeedDrain===!0?d():n.flowing||(ut("pipe resume"),r.resume()),e};function kbe(e,t){return function(){let n=e._readableState;n.awaitDrainWriters===t?(ut("pipeOnDrain",1),n.awaitDrainWriters=null):n.multiAwaitDrain&&(ut("pipeOnDrain",n.awaitDrainWriters.size),n.awaitDrainWriters.delete(t)),(!n.awaitDrainWriters||n.awaitDrainWriters.size===0)&&e.listenerCount("data")&&e.resume()}}Ye.prototype.unpipe=function(e){let t=this._readableState,r={hasUnpiped:!1};if(t.pipes.length===0)return this;if(!e){let i=t.pipes;t.pipes=[],this.pause();for(let o=0;o<i.length;o++)i[o].emit("unpipe",this,{hasUnpiped:!1});return this}let n=J_e(t.pipes,e);return n===-1?this:(t.pipes.splice(n,1),t.pipes.length===0&&this.pause(),e.emit("unpipe",this,r),this)};Ye.prototype.on=function(e,t){let r=ha.prototype.on.call(this,e,t),n=this._readableState;return e==="data"?(n.readableListening=this.listenerCount("readable")>0,n.flowing!==!1&&this.resume()):e==="readable"&&!n.endEmitted&&!n.readableListening&&(n.readableListening=n.needReadable=!0,n.flowing=!1,n.emittedReadable=!1,ut("on readable",n.length,n.reading),n.length?Yy(this):n.reading||ro.nextTick(Nbe,this)),r};Ye.prototype.addListener=Ye.prototype.on;Ye.prototype.removeListener=function(e,t){let r=ha.prototype.removeListener.call(this,e,t);return e==="readable"&&ro.nextTick(bq,this),r};Ye.prototype.off=Ye.prototype.removeListener;Ye.prototype.removeAllListeners=function(e){let t=ha.prototype.removeAllListeners.apply(this,arguments);return(e==="readable"||e===void 0)&&ro.nextTick(bq,this),t};function bq(e){let t=e._readableState;t.readableListening=e.listenerCount("readable")>0,t.resumeScheduled&&t[Uc]===!1?t.flowing=!0:e.listenerCount("data")>0?e.resume():t.readableListening||(t.flowing=null)}function Nbe(e){ut("readable nexttick read 0"),e.read(0)}Ye.prototype.resume=function(){let e=this._readableState;return e.flowing||(ut("resume"),e.flowing=!e.readableListening,Mbe(this,e)),e[Uc]=!1,this};function Mbe(e,t){t.resumeScheduled||(t.resumeScheduled=!0,ro.nextTick(Lbe,e,t))}function Lbe(e,t){ut("resume",t.reading),t.reading||e.read(0),t.resumeScheduled=!1,e.emit("resume"),Eq(e),t.flowing&&!t.reading&&e.read(0)}Ye.prototype.pause=function(){return ut("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(ut("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState[Uc]=!0,this};function Eq(e){let t=e._readableState;for(ut("flow",t.flowing);t.flowing&&e.read()!==null;);}Ye.prototype.wrap=function(e){let t=!1;e.on("data",n=>{!this.push(n)&&e.pause&&(t=!0,e.pause())}),e.on("end",()=>{this.push(null)}),e.on("error",n=>{Sl(this,n)}),e.on("close",()=>{this.destroy()}),e.on("destroy",()=>{this.destroy()}),this._read=()=>{t&&e.resume&&(t=!1,e.resume())};let r=tbe(e);for(let n=1;n<r.length;n++){let i=r[n];this[i]===void 0&&typeof e[i]=="function"&&(this[i]=e[i].bind(e))}return this};Ye.prototype[ibe]=function(){return wq(this)};Ye.prototype.iterator=function(e){return e!==void 0&&_be(e,"options"),wq(this,e)};function wq(e,t){typeof e.read!="function"&&(e=Ye.wrap(e,{objectMode:!0}));let r=Bbe(e,t);return r.stream=e,r}async function*Bbe(e,t){let r=aA;function n(s){this===e?(r(),r=aA):r=s}e.on("readable",n);let i,o=fq(e,{writable:!1},s=>{i=s?aq(i,s):null,r(),r=aA});try{for(;;){let s=e.destroyed?null:e.read();if(s!==null)yield s;else{if(i)throw i;if(i===null)return;await new lq(n)}}}catch(s){throw i=aq(i,s),i}finally{(i||t?.destroyOnReturn!==!1)&&(i===void 0||e._readableState.autoDestroy)?Cl.destroyer(e,null):(e.off("readable",n),o())}}pA(Ye.prototype,{readable:{__proto__:null,get(){let e=this._readableState;return!!e&&e.readable!==!1&&!e.destroyed&&!e.errorEmitted&&!e.endEmitted},set(e){this._readableState&&(this._readableState.readable=!!e)}},readableDidRead:{__proto__:null,enumerable:!1,get:function(){return this._readableState.dataEmitted}},readableAborted:{__proto__:null,enumerable:!1,get:function(){return!!(this._readableState.readable!==!1&&(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(e){this._readableState&&(this._readableState.flowing=e)}},readableLength:{__proto__:null,enumerable:!1,get(){return this._readableState.length}},readableObjectMode:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.objectMode:!1}},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:!1}},destroyed:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.destroyed:!1},set(e){this._readableState&&(this._readableState.destroyed=e)}},readableEnded:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.endEmitted:!1}}});pA(Ky.prototype,{pipesCount:{__proto__:null,get(){return this.pipes.length}},paused:{__proto__:null,get(){return this[Uc]!==!1},set(e){this[Uc]=!!e}}});Ye._fromList=Sq;function Sq(e,t){if(t.length===0)return null;let r;return t.objectMode?r=t.buffer.shift():!e||e>=t.length?(t.decoder?r=t.buffer.join(""):t.buffer.length===1?r=t.buffer.first():r=t.buffer.concat(t.length),t.buffer.clear()):r=t.buffer.consume(e,t.decoder),r}function uA(e){let t=e._readableState;ut("endReadable",t.endEmitted),t.endEmitted||(t.ended=!0,ro.nextTick(Fbe,t,e))}function Fbe(e,t){if(ut("endReadableNT",e.endEmitted,e.length),!e.errored&&!e.closeEmitted&&!e.endEmitted&&e.length===0){if(e.endEmitted=!0,t.emit("end"),t.writable&&t.allowHalfOpen===!1)ro.nextTick(qbe,t);else if(e.autoDestroy){let r=t._writableState;(!r||r.autoDestroy&&(r.finished||r.writable===!1))&&t.destroy()}}}function qbe(e){e.writable&&!e.writableEnded&&!e.destroyed&&e.end()}Ye.from=function(e,t){return bbe(Ye,e,t)};var lA;function vq(){return lA===void 0&&(lA={}),lA}Ye.fromWeb=function(e,t){return vq().newStreamReadableFromReadableStream(e,t)};Ye.toWeb=function(e,t){return vq().newReadableStreamFromStreamReadable(e,t)};Ye.wrap=function(e,t){var r,n;return new Ye({objectMode:(r=(n=e.readableObjectMode)!==null&&n!==void 0?n:e.objectMode)!==null&&r!==void 0?r:!0,...t,destroy(i,o){Cl.destroyer(e,i),o(i)}}).wrap(e)}});var e_=E((Eft,Lq)=>{"use strict";var Hc=da(),{ArrayPrototypeSlice:Aq,Error:jbe,FunctionPrototypeSymbolHasInstance:Rq,ObjectDefineProperty:Pq,ObjectDefineProperties:Ube,ObjectSetPrototypeOf:Oq,StringPrototypeToLowerCase:Hbe,Symbol:$be,SymbolHasInstance:Gbe}=er();Lq.exports=sr;sr.WritableState=kp;var{EventEmitter:zbe}=require("events"),Ip=Uy().Stream,{Buffer:Xy}=require("buffer"),Zy=qc(),{addAbortSignal:Vbe}=Tp(),{getHighWaterMark:Wbe,getDefaultHighWaterMark:Kbe}=Ap(),{ERR_INVALID_ARG_TYPE:Ybe,ERR_METHOD_NOT_IMPLEMENTED:Xbe,ERR_MULTIPLE_CALLBACK:Iq,ERR_STREAM_CANNOT_PIPE:Jbe,ERR_STREAM_DESTROYED:Dp,ERR_STREAM_ALREADY_FINISHED:Qbe,ERR_STREAM_NULL_VALUES:Zbe,ERR_STREAM_WRITE_AFTER_END:e0e,ERR_UNKNOWN_ENCODING:Dq}=yn().codes,{errorOrDestroy:xl}=Zy;Oq(sr.prototype,Ip.prototype);Oq(sr,Ip);function gA(){}var Tl=$be("kOnFinished");function kp(e,t,r){typeof r!="boolean"&&(r=t instanceof ko()),this.objectMode=!!(e&&e.objectMode),r&&(this.objectMode=this.objectMode||!!(e&&e.writableObjectMode)),this.highWaterMark=e?Wbe(this,e,"writableHighWaterMark",r):Kbe(!1),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;let n=!!(e&&e.decodeStrings===!1);this.decodeStrings=!n,this.defaultEncoding=e&&e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=r0e.bind(void 0,t),this.writecb=null,this.writelen=0,this.afterWriteTickInfo=null,Qy(this),this.pendingcb=0,this.constructed=!0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=!e||e.emitClose!==!1,this.autoDestroy=!e||e.autoDestroy!==!1,this.errored=null,this.closed=!1,this.closeEmitted=!1,this[Tl]=[]}function Qy(e){e.buffered=[],e.bufferedIndex=0,e.allBuffers=!0,e.allNoop=!0}kp.prototype.getBuffer=function(){return Aq(this.buffered,this.bufferedIndex)};Pq(kp.prototype,"bufferedRequestCount",{__proto__:null,get(){return this.buffered.length-this.bufferedIndex}});function sr(e){let t=this instanceof ko();if(!t&&!Rq(sr,this))return new sr(e);this._writableState=new kp(e,this,t),e&&(typeof e.write=="function"&&(this._write=e.write),typeof e.writev=="function"&&(this._writev=e.writev),typeof e.destroy=="function"&&(this._destroy=e.destroy),typeof e.final=="function"&&(this._final=e.final),typeof e.construct=="function"&&(this._construct=e.construct),e.signal&&Vbe(e.signal,this)),Ip.call(this,e),Zy.construct(this,()=>{let r=this._writableState;r.writing||_A(this,r),bA(this,r)})}Pq(sr,Gbe,{__proto__:null,value:function(e){return Rq(this,e)?!0:this!==sr?!1:e&&e._writableState instanceof kp}});sr.prototype.pipe=function(){xl(this,new Jbe)};function kq(e,t,r,n){let i=e._writableState;if(typeof r=="function")n=r,r=i.defaultEncoding;else{if(!r)r=i.defaultEncoding;else if(r!=="buffer"&&!Xy.isEncoding(r))throw new Dq(r);typeof n!="function"&&(n=gA)}if(t===null)throw new Zbe;if(!i.objectMode)if(typeof t=="string")i.decodeStrings!==!1&&(t=Xy.from(t,r),r="buffer");else if(t instanceof Xy)r="buffer";else if(Ip._isUint8Array(t))t=Ip._uint8ArrayToBuffer(t),r="buffer";else throw new Ybe("chunk",["string","Buffer","Uint8Array"],t);let o;return i.ending?o=new e0e:i.destroyed&&(o=new Dp("write")),o?(Hc.nextTick(n,o),xl(e,o,!0),o):(i.pendingcb++,t0e(e,i,t,r,n))}sr.prototype.write=function(e,t,r){return kq(this,e,t,r)===!0};sr.prototype.cork=function(){this._writableState.corked++};sr.prototype.uncork=function(){let e=this._writableState;e.corked&&(e.corked--,e.writing||_A(this,e))};sr.prototype.setDefaultEncoding=function(t){if(typeof t=="string"&&(t=Hbe(t)),!Xy.isEncoding(t))throw new Dq(t);return this._writableState.defaultEncoding=t,this};function t0e(e,t,r,n,i){let o=t.objectMode?1:r.length;t.length+=o;let s=t.length<t.highWaterMark;return s||(t.needDrain=!0),t.writing||t.corked||t.errored||!t.constructed?(t.buffered.push({chunk:r,encoding:n,callback:i}),t.allBuffers&&n!=="buffer"&&(t.allBuffers=!1),t.allNoop&&i!==gA&&(t.allNoop=!1)):(t.writelen=o,t.writecb=i,t.writing=!0,t.sync=!0,e._write(r,n,t.onwrite),t.sync=!1),s&&!t.errored&&!t.destroyed}function xq(e,t,r,n,i,o,s){t.writelen=n,t.writecb=s,t.writing=!0,t.sync=!0,t.destroyed?t.onwrite(new Dp("write")):r?e._writev(i,t.onwrite):e._write(i,o,t.onwrite),t.sync=!1}function Tq(e,t,r,n){--t.pendingcb,n(r),yA(t),xl(e,r)}function r0e(e,t){let r=e._writableState,n=r.sync,i=r.writecb;if(typeof i!="function"){xl(e,new Iq);return}r.writing=!1,r.writecb=null,r.length-=r.writelen,r.writelen=0,t?(t.stack,r.errored||(r.errored=t),e._readableState&&!e._readableState.errored&&(e._readableState.errored=t),n?Hc.nextTick(Tq,e,r,t,i):Tq(e,r,t,i)):(r.buffered.length>r.bufferedIndex&&_A(e,r),n?r.afterWriteTickInfo!==null&&r.afterWriteTickInfo.cb===i?r.afterWriteTickInfo.count++:(r.afterWriteTickInfo={count:1,cb:i,stream:e,state:r},Hc.nextTick(n0e,r.afterWriteTickInfo)):Nq(e,r,1,i))}function n0e({stream:e,state:t,count:r,cb:n}){return t.afterWriteTickInfo=null,Nq(e,t,r,n)}function Nq(e,t,r,n){for(!t.ending&&!e.destroyed&&t.length===0&&t.needDrain&&(t.needDrain=!1,e.emit("drain"));r-- >0;)t.pendingcb--,n();t.destroyed&&yA(t),bA(e,t)}function yA(e){if(e.writing)return;for(let i=e.bufferedIndex;i<e.buffered.length;++i){var t;let{chunk:o,callback:s}=e.buffered[i],a=e.objectMode?1:o.length;e.length-=a,s((t=e.errored)!==null&&t!==void 0?t:new Dp("write"))}let r=e[Tl].splice(0);for(let i=0;i<r.length;i++){var n;r[i]((n=e.errored)!==null&&n!==void 0?n:new Dp("end"))}Qy(e)}function _A(e,t){if(t.corked||t.bufferProcessing||t.destroyed||!t.constructed)return;let{buffered:r,bufferedIndex:n,objectMode:i}=t,o=r.length-n;if(!o)return;let s=n;if(t.bufferProcessing=!0,o>1&&e._writev){t.pendingcb-=o-1;let a=t.allNoop?gA:u=>{for(let l=s;l<r.length;++l)r[l].callback(u)},c=t.allNoop&&s===0?r:Aq(r,s);c.allBuffers=t.allBuffers,xq(e,t,!0,t.length,c,"",a),Qy(t)}else{do{let{chunk:a,encoding:c,callback:u}=r[s];r[s++]=null;let l=i?1:a.length;xq(e,t,!1,l,a,c,u)}while(s<r.length&&!t.writing);s===r.length?Qy(t):s>256?(r.splice(0,s),t.bufferedIndex=0):t.bufferedIndex=s}t.bufferProcessing=!1}sr.prototype._write=function(e,t,r){if(this._writev)this._writev([{chunk:e,encoding:t}],r);else throw new Xbe("_write()")};sr.prototype._writev=null;sr.prototype.end=function(e,t,r){let n=this._writableState;typeof e=="function"?(r=e,e=null,t=null):typeof t=="function"&&(r=t,t=null);let i;if(e!=null){let o=kq(this,e,t);o instanceof jbe&&(i=o)}return n.corked&&(n.corked=1,this.uncork()),i||(!n.errored&&!n.ending?(n.ending=!0,bA(this,n,!0),n.ended=!0):n.finished?i=new Qbe("end"):n.destroyed&&(i=new Dp("end"))),typeof r=="function"&&(i||n.finished?Hc.nextTick(r,i):n[Tl].push(r)),this};function Jy(e){return e.ending&&!e.destroyed&&e.constructed&&e.length===0&&!e.errored&&e.buffered.length===0&&!e.finished&&!e.writing&&!e.errorEmitted&&!e.closeEmitted}function i0e(e,t){let r=!1;function n(i){if(r){xl(e,i??Iq());return}if(r=!0,t.pendingcb--,i){let o=t[Tl].splice(0);for(let s=0;s<o.length;s++)o[s](i);xl(e,i,t.sync)}else Jy(t)&&(t.prefinished=!0,e.emit("prefinish"),t.pendingcb++,Hc.nextTick(mA,e,t))}t.sync=!0,t.pendingcb++;try{e._final(n)}catch(i){n(i)}t.sync=!1}function o0e(e,t){!t.prefinished&&!t.finalCalled&&(typeof e._final=="function"&&!t.destroyed?(t.finalCalled=!0,i0e(e,t)):(t.prefinished=!0,e.emit("prefinish")))}function bA(e,t,r){Jy(t)&&(o0e(e,t),t.pendingcb===0&&(r?(t.pendingcb++,Hc.nextTick((n,i)=>{Jy(i)?mA(n,i):i.pendingcb--},e,t)):Jy(t)&&(t.pendingcb++,mA(e,t))))}function mA(e,t){t.pendingcb--,t.finished=!0;let r=t[Tl].splice(0);for(let n=0;n<r.length;n++)r[n]();if(e.emit("finish"),t.autoDestroy){let n=e._readableState;(!n||n.autoDestroy&&(n.endEmitted||n.readable===!1))&&e.destroy()}}Ube(sr.prototype,{closed:{__proto__:null,get(){return this._writableState?this._writableState.closed:!1}},destroyed:{__proto__:null,get(){return this._writableState?this._writableState.destroyed:!1},set(e){this._writableState&&(this._writableState.destroyed=e)}},writable:{__proto__:null,get(){let e=this._writableState;return!!e&&e.writable!==!1&&!e.destroyed&&!e.errored&&!e.ending&&!e.ended},set(e){this._writableState&&(this._writableState.writable=!!e)}},writableFinished:{__proto__:null,get(){return this._writableState?this._writableState.finished:!1}},writableObjectMode:{__proto__:null,get(){return this._writableState?this._writableState.objectMode:!1}},writableBuffer:{__proto__:null,get(){return this._writableState&&this._writableState.getBuffer()}},writableEnded:{__proto__:null,get(){return this._writableState?this._writableState.ending:!1}},writableNeedDrain:{__proto__:null,get(){let e=this._writableState;return e?!e.destroyed&&!e.ending&&e.needDrain:!1}},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!!(this._writableState.writable!==!1&&(this._writableState.destroyed||this._writableState.errored)&&!this._writableState.finished)}}});var s0e=Zy.destroy;sr.prototype.destroy=function(e,t){let r=this._writableState;return!r.destroyed&&(r.bufferedIndex<r.buffered.length||r[Tl].length)&&Hc.nextTick(yA,r),s0e.call(this,e,t),this};sr.prototype._undestroy=Zy.undestroy;sr.prototype._destroy=function(e,t){t(e)};sr.prototype[zbe.captureRejectionSymbol]=function(e){this.destroy(e)};var hA;function Mq(){return hA===void 0&&(hA={}),hA}sr.fromWeb=function(e,t){return Mq().newStreamWritableFromWritableStream(e,t)};sr.toWeb=function(e){return Mq().newWritableStreamFromStreamWritable(e)}});var Jq=E((wft,Xq)=>{"use strict";var EA=da(),a0e=require("buffer"),{isReadable:c0e,isWritable:u0e,isIterable:Bq,isNodeStream:l0e,isReadableNodeStream:Fq,isWritableNodeStream:qq,isDuplexNodeStream:f0e,isReadableStream:jq,isWritableStream:Uq}=Oo(),Hq=bs(),{AbortError:Kq,codes:{ERR_INVALID_ARG_TYPE:d0e,ERR_INVALID_RETURN_VALUE:$q}}=yn(),{destroyer:Rl}=qc(),p0e=ko(),Yq=Op(),h0e=e_(),{createDeferredPromise:Gq}=qn(),zq=oA(),Vq=globalThis.Blob||a0e.Blob,m0e=typeof Vq<"u"?function(t){return t instanceof Vq}:function(t){return!1},g0e=globalThis.AbortController||yl().AbortController,{FunctionPrototypeCall:Wq}=er(),ma=class extends p0e{constructor(t){super(t),t?.readable===!1&&(this._readableState.readable=!1,this._readableState.ended=!0,this._readableState.endEmitted=!0),t?.writable===!1&&(this._writableState.writable=!1,this._writableState.ending=!0,this._writableState.ended=!0,this._writableState.finished=!0)}};Xq.exports=function e(t,r){if(f0e(t))return t;if(Fq(t))return Al({readable:t});if(qq(t))return Al({writable:t});if(l0e(t))return Al({writable:!1,readable:!1});if(jq(t))return Al({readable:Yq.fromWeb(t)});if(Uq(t))return Al({writable:h0e.fromWeb(t)});if(typeof t=="function"){let{value:i,write:o,final:s,destroy:a}=y0e(t);if(Bq(i))return zq(ma,i,{objectMode:!0,write:o,final:s,destroy:a});let c=i?.then;if(typeof c=="function"){let u,l=Wq(c,i,d=>{if(d!=null)throw new $q("nully","body",d)},d=>{Rl(u,d)});return u=new ma({objectMode:!0,readable:!1,write:o,final(d){s(async()=>{try{await l,EA.nextTick(d,null)}catch(h){EA.nextTick(d,h)}})},destroy:a})}throw new $q("Iterable, AsyncIterable or AsyncFunction",r,i)}if(m0e(t))return e(t.arrayBuffer());if(Bq(t))return zq(ma,t,{objectMode:!0,writable:!1});if(jq(t?.readable)&&Uq(t?.writable))return ma.fromWeb(t);if(typeof t?.writable=="object"||typeof t?.readable=="object"){let i=t!=null&&t.readable?Fq(t?.readable)?t?.readable:e(t.readable):void 0,o=t!=null&&t.writable?qq(t?.writable)?t?.writable:e(t.writable):void 0;return Al({readable:i,writable:o})}let n=t?.then;if(typeof n=="function"){let i;return Wq(n,t,o=>{o!=null&&i.push(o),i.push(null)},o=>{Rl(i,o)}),i=new ma({objectMode:!0,writable:!1,read(){}})}throw new d0e(r,["Blob","ReadableStream","WritableStream","Stream","Iterable","AsyncIterable","Function","{ readable, writable } pair","Promise"],t)};function y0e(e){let{promise:t,resolve:r}=Gq(),n=new g0e,i=n.signal;return{value:e((async function*(){for(;;){let s=t;t=null;let{chunk:a,done:c,cb:u}=await s;if(EA.nextTick(u),c)return;if(i.aborted)throw new Kq(void 0,{cause:i.reason});({promise:t,resolve:r}=Gq()),yield a}})(),{signal:i}),write(s,a,c){let u=r;r=null,u({chunk:s,done:!1,cb:c})},final(s){let a=r;r=null,a({done:!0,cb:s})},destroy(s,a){n.abort(),a(s)}}}function Al(e){let t=e.readable&&typeof e.readable.read!="function"?Yq.wrap(e.readable):e.readable,r=e.writable,n=!!c0e(t),i=!!u0e(r),o,s,a,c,u;function l(d){let h=c;c=null,h?h(d):d&&u.destroy(d)}return u=new ma({readableObjectMode:!!(t!=null&&t.readableObjectMode),writableObjectMode:!!(r!=null&&r.writableObjectMode),readable:n,writable:i}),i&&(Hq(r,d=>{i=!1,d&&Rl(t,d),l(d)}),u._write=function(d,h,f){r.write(d,h)?f():o=f},u._final=function(d){r.end(),s=d},r.on("drain",function(){if(o){let d=o;o=null,d()}}),r.on("finish",function(){if(s){let d=s;s=null,d()}})),n&&(Hq(t,d=>{n=!1,d&&Rl(t,d),l(d)}),t.on("readable",function(){if(a){let d=a;a=null,d()}}),t.on("end",function(){u.push(null)}),u._read=function(){for(;;){let d=t.read();if(d===null){a=u._read;return}if(!u.push(d))return}}),u._destroy=function(d,h){!d&&c!==null&&(d=new Kq),a=null,o=null,s=null,c===null?h(d):(c=h,Rl(r,d),Rl(t,d))},u}});var ko=E((Sft,ej)=>{"use strict";var{ObjectDefineProperties:_0e,ObjectGetOwnPropertyDescriptor:Es,ObjectKeys:b0e,ObjectSetPrototypeOf:Qq}=er();ej.exports=no;var vA=Op(),Ii=e_();Qq(no.prototype,vA.prototype);Qq(no,vA);{let e=b0e(Ii.prototype);for(let t=0;t<e.length;t++){let r=e[t];no.prototype[r]||(no.prototype[r]=Ii.prototype[r])}}function no(e){if(!(this instanceof no))return new no(e);vA.call(this,e),Ii.call(this,e),e?(this.allowHalfOpen=e.allowHalfOpen!==!1,e.readable===!1&&(this._readableState.readable=!1,this._readableState.ended=!0,this._readableState.endEmitted=!0),e.writable===!1&&(this._writableState.writable=!1,this._writableState.ending=!0,this._writableState.ended=!0,this._writableState.finished=!0)):this.allowHalfOpen=!0}_0e(no.prototype,{writable:{__proto__:null,...Es(Ii.prototype,"writable")},writableHighWaterMark:{__proto__:null,...Es(Ii.prototype,"writableHighWaterMark")},writableObjectMode:{__proto__:null,...Es(Ii.prototype,"writableObjectMode")},writableBuffer:{__proto__:null,...Es(Ii.prototype,"writableBuffer")},writableLength:{__proto__:null,...Es(Ii.prototype,"writableLength")},writableFinished:{__proto__:null,...Es(Ii.prototype,"writableFinished")},writableCorked:{__proto__:null,...Es(Ii.prototype,"writableCorked")},writableEnded:{__proto__:null,...Es(Ii.prototype,"writableEnded")},writableNeedDrain:{__proto__:null,...Es(Ii.prototype,"writableNeedDrain")},destroyed:{__proto__:null,get(){return this._readableState===void 0||this._writableState===void 0?!1:this._readableState.destroyed&&this._writableState.destroyed},set(e){this._readableState&&this._writableState&&(this._readableState.destroyed=e,this._writableState.destroyed=e)}}});var wA;function Zq(){return wA===void 0&&(wA={}),wA}no.fromWeb=function(e,t){return Zq().newStreamDuplexFromReadableWritablePair(e,t)};no.toWeb=function(e){return Zq().newReadableWritablePairFromDuplex(e)};var SA;no.from=function(e){return SA||(SA=Jq()),SA(e,"body")}});var TA=E((vft,rj)=>{"use strict";var{ObjectSetPrototypeOf:tj,Symbol:E0e}=er();rj.exports=ws;var{ERR_METHOD_NOT_IMPLEMENTED:w0e}=yn().codes,xA=ko(),{getHighWaterMark:S0e}=Ap();tj(ws.prototype,xA.prototype);tj(ws,xA);var Np=E0e("kCallback");function ws(e){if(!(this instanceof ws))return new ws(e);let t=e?S0e(this,e,"readableHighWaterMark",!0):null;t===0&&(e={...e,highWaterMark:null,readableHighWaterMark:t,writableHighWaterMark:e.writableHighWaterMark||0}),xA.call(this,e),this._readableState.sync=!1,this[Np]=null,e&&(typeof e.transform=="function"&&(this._transform=e.transform),typeof e.flush=="function"&&(this._flush=e.flush)),this.on("prefinish",v0e)}function CA(e){typeof this._flush=="function"&&!this.destroyed?this._flush((t,r)=>{if(t){e?e(t):this.destroy(t);return}r!=null&&this.push(r),this.push(null),e&&e()}):(this.push(null),e&&e())}function v0e(){this._final!==CA&&CA.call(this)}ws.prototype._final=CA;ws.prototype._transform=function(e,t,r){throw new w0e("_transform()")};ws.prototype._write=function(e,t,r){let n=this._readableState,i=this._writableState,o=n.length;this._transform(e,t,(s,a)=>{if(s){r(s);return}a!=null&&this.push(a),i.ended||o===n.length||n.length<n.highWaterMark?r():this[Np]=r})};ws.prototype._read=function(){if(this[Np]){let e=this[Np];this[Np]=null,e()}}});var RA=E((Cft,ij)=>{"use strict";var{ObjectSetPrototypeOf:nj}=er();ij.exports=Pl;var AA=TA();nj(Pl.prototype,AA.prototype);nj(Pl,AA);function Pl(e){if(!(this instanceof Pl))return new Pl(e);AA.call(this,e)}Pl.prototype._transform=function(e,t,r){r(null,e)}});var i_=E((xft,uj)=>{"use strict";var Mp=da(),{ArrayIsArray:C0e,Promise:x0e,SymbolAsyncIterator:T0e,SymbolDispose:A0e}=er(),n_=bs(),{once:R0e}=qn(),P0e=qc(),oj=ko(),{aggregateTwoErrors:O0e,codes:{ERR_INVALID_ARG_TYPE:BA,ERR_INVALID_RETURN_VALUE:PA,ERR_MISSING_ARGS:I0e,ERR_STREAM_DESTROYED:D0e,ERR_STREAM_PREMATURE_CLOSE:k0e},AbortError:N0e}=yn(),{validateFunction:M0e,validateAbortSignal:L0e}=bl(),{isIterable:$c,isReadable:OA,isReadableNodeStream:r_,isNodeStream:sj,isTransformStream:Ol,isWebStream:B0e,isReadableStream:IA,isReadableFinished:F0e}=Oo(),q0e=globalThis.AbortController||yl().AbortController,DA,kA,NA;function aj(e,t,r){let n=!1;e.on("close",()=>{n=!0});let i=n_(e,{readable:t,writable:r},o=>{n=!o});return{destroy:o=>{n||(n=!0,P0e.destroyer(e,o||new D0e("pipe")))},cleanup:i}}function j0e(e){return M0e(e[e.length-1],"streams[stream.length - 1]"),e.pop()}function MA(e){if($c(e))return e;if(r_(e))return U0e(e);throw new BA("val",["Readable","Iterable","AsyncIterable"],e)}async function*U0e(e){kA||(kA=Op()),yield*kA.prototype[T0e].call(e)}async function t_(e,t,r,{end:n}){let i,o=null,s=u=>{if(u&&(i=u),o){let l=o;o=null,l()}},a=()=>new x0e((u,l)=>{i?l(i):o=()=>{i?l(i):u()}});t.on("drain",s);let c=n_(t,{readable:!1},s);try{t.writableNeedDrain&&await a();for await(let u of e)t.write(u)||await a();n&&(t.end(),await a()),r()}catch(u){r(i!==u?O0e(i,u):u)}finally{c(),t.off("drain",s)}}async function LA(e,t,r,{end:n}){Ol(t)&&(t=t.writable);let i=t.getWriter();try{for await(let o of e)await i.ready,i.write(o).catch(()=>{});await i.ready,n&&await i.close(),r()}catch(o){try{await i.abort(o),r(o)}catch(s){r(s)}}}function H0e(...e){return cj(e,R0e(j0e(e)))}function cj(e,t,r){if(e.length===1&&C0e(e[0])&&(e=e[0]),e.length<2)throw new I0e("streams");let n=new q0e,i=n.signal,o=r?.signal,s=[];L0e(o,"options.signal");function a(){p(new N0e)}NA=NA||qn().addAbortListener;let c;o&&(c=NA(o,a));let u,l,d=[],h=0;function f(v){p(v,--h===0)}function p(v,y){var S;if(v&&(!u||u.code==="ERR_STREAM_PREMATURE_CLOSE")&&(u=v),!(!u&&!y)){for(;d.length;)d.shift()(u);(S=c)===null||S===void 0||S[A0e](),n.abort(),y&&(u||s.forEach(O=>O()),Mp.nextTick(t,u,l))}}let m;for(let v=0;v<e.length;v++){let y=e[v],S=v<e.length-1,O=v>0,M=S||r?.end!==!1,A=v===e.length-1;if(sj(y)){let D=function(I){I&&I.name!=="AbortError"&&I.code!=="ERR_STREAM_PREMATURE_CLOSE"&&f(I)};var R=D;if(M){let{destroy:I,cleanup:N}=aj(y,S,O);d.push(I),OA(y)&&A&&s.push(N)}y.on("error",D),OA(y)&&A&&s.push(()=>{y.removeListener("error",D)})}if(v===0)if(typeof y=="function"){if(m=y({signal:i}),!$c(m))throw new PA("Iterable, AsyncIterable or Stream","source",m)}else $c(y)||r_(y)||Ol(y)?m=y:m=oj.from(y);else if(typeof y=="function"){if(Ol(m)){var _;m=MA((_=m)===null||_===void 0?void 0:_.readable)}else m=MA(m);if(m=y(m,{signal:i}),S){if(!$c(m,!0))throw new PA("AsyncIterable",`transform[${v-1}]`,m)}else{var w;DA||(DA=RA());let D=new DA({objectMode:!0}),I=(w=m)===null||w===void 0?void 0:w.then;if(typeof I=="function")h++,I.call(m,U=>{l=U,U!=null&&D.write(U),M&&D.end(),Mp.nextTick(f)},U=>{D.destroy(U),Mp.nextTick(f,U)});else if($c(m,!0))h++,t_(m,D,f,{end:M});else if(IA(m)||Ol(m)){let U=m.readable||m;h++,t_(U,D,f,{end:M})}else throw new PA("AsyncIterable or Promise","destination",m);m=D;let{destroy:N,cleanup:J}=aj(m,!1,!0);d.push(N),A&&s.push(J)}}else if(sj(y)){if(r_(m)){h+=2;let D=$0e(m,y,f,{end:M});OA(y)&&A&&s.push(D)}else if(Ol(m)||IA(m)){let D=m.readable||m;h++,t_(D,y,f,{end:M})}else if($c(m))h++,t_(m,y,f,{end:M});else throw new BA("val",["Readable","Iterable","AsyncIterable","ReadableStream","TransformStream"],m);m=y}else if(B0e(y)){if(r_(m))h++,LA(MA(m),y,f,{end:M});else if(IA(m)||$c(m))h++,LA(m,y,f,{end:M});else if(Ol(m))h++,LA(m.readable,y,f,{end:M});else throw new BA("val",["Readable","Iterable","AsyncIterable","ReadableStream","TransformStream"],m);m=y}else m=oj.from(y)}return(i!=null&&i.aborted||o!=null&&o.aborted)&&Mp.nextTick(a),m}function $0e(e,t,r,{end:n}){let i=!1;if(t.on("close",()=>{i||r(new k0e)}),e.pipe(t,{end:!1}),n){let s=function(){i=!0,t.end()};var o=s;F0e(e)?Mp.nextTick(s):e.once("end",s)}else r();return n_(e,{readable:!0,writable:!1},s=>{let a=e._readableState;s&&s.code==="ERR_STREAM_PREMATURE_CLOSE"&&a&&a.ended&&!a.errored&&!a.errorEmitted?e.once("end",r).once("error",r):r(s)}),n_(t,{readable:!1,writable:!0},r)}uj.exports={pipelineImpl:cj,pipeline:H0e}});var qA=E((Tft,mj)=>{"use strict";var{pipeline:G0e}=i_(),o_=ko(),{destroyer:z0e}=qc(),{isNodeStream:s_,isReadable:lj,isWritable:fj,isWebStream:FA,isTransformStream:Gc,isWritableStream:dj,isReadableStream:pj}=Oo(),{AbortError:V0e,codes:{ERR_INVALID_ARG_VALUE:hj,ERR_MISSING_ARGS:W0e}}=yn(),K0e=bs();mj.exports=function(...t){if(t.length===0)throw new W0e("streams");if(t.length===1)return o_.from(t[0]);let r=[...t];if(typeof t[0]=="function"&&(t[0]=o_.from(t[0])),typeof t[t.length-1]=="function"){let f=t.length-1;t[f]=o_.from(t[f])}for(let f=0;f<t.length;++f)if(!(!s_(t[f])&&!FA(t[f]))){if(f<t.length-1&&!(lj(t[f])||pj(t[f])||Gc(t[f])))throw new hj(`streams[${f}]`,r[f],"must be readable");if(f>0&&!(fj(t[f])||dj(t[f])||Gc(t[f])))throw new hj(`streams[${f}]`,r[f],"must be writable")}let n,i,o,s,a;function c(f){let p=s;s=null,p?p(f):f?a.destroy(f):!h&&!d&&a.destroy()}let u=t[0],l=G0e(t,c),d=!!(fj(u)||dj(u)||Gc(u)),h=!!(lj(l)||pj(l)||Gc(l));if(a=new o_({writableObjectMode:!!(u!=null&&u.writableObjectMode),readableObjectMode:!!(l!=null&&l.readableObjectMode),writable:d,readable:h}),d){if(s_(u))a._write=function(p,m,_){u.write(p,m)?_():n=_},a._final=function(p){u.end(),i=p},u.on("drain",function(){if(n){let p=n;n=null,p()}});else if(FA(u)){let m=(Gc(u)?u.writable:u).getWriter();a._write=async function(_,w,R){try{await m.ready,m.write(_).catch(()=>{}),R()}catch(v){R(v)}},a._final=async function(_){try{await m.ready,m.close().catch(()=>{}),i=_}catch(w){_(w)}}}let f=Gc(l)?l.readable:l;K0e(f,()=>{if(i){let p=i;i=null,p()}})}if(h){if(s_(l))l.on("readable",function(){if(o){let f=o;o=null,f()}}),l.on("end",function(){a.push(null)}),a._read=function(){for(;;){let f=l.read();if(f===null){o=a._read;return}if(!a.push(f))return}};else if(FA(l)){let p=(Gc(l)?l.readable:l).getReader();a._read=async function(){for(;;)try{let{value:m,done:_}=await p.read();if(!a.push(m))return;if(_){a.push(null);return}}catch{return}}}}return a._destroy=function(f,p){!f&&s!==null&&(f=new V0e),o=null,n=null,i=null,s===null?p(f):(s=p,s_(l)&&z0e(l,f))},a}});var xj=E((Aft,HA)=>{"use strict";var Y0e=globalThis.AbortController||yl().AbortController,{codes:{ERR_INVALID_ARG_VALUE:X0e,ERR_INVALID_ARG_TYPE:Lp,ERR_MISSING_ARGS:J0e,ERR_OUT_OF_RANGE:Q0e},AbortError:No}=yn(),{validateAbortSignal:zc,validateInteger:gj,validateObject:Vc}=bl(),Z0e=er().Symbol("kWeak"),eEe=er().Symbol("kResistStopPropagation"),{finished:tEe}=bs(),rEe=qA(),{addAbortSignalNoValidate:nEe}=Tp(),{isWritable:iEe,isNodeStream:oEe}=Oo(),{deprecate:sEe}=qn(),{ArrayPrototypePush:aEe,Boolean:cEe,MathFloor:yj,Number:uEe,NumberIsNaN:lEe,Promise:_j,PromiseReject:bj,PromiseResolve:fEe,PromisePrototypeThen:Ej,Symbol:Sj}=er(),a_=Sj("kEmpty"),wj=Sj("kEof");function dEe(e,t){if(t!=null&&Vc(t,"options"),t?.signal!=null&&zc(t.signal,"options.signal"),oEe(e)&&!iEe(e))throw new X0e("stream",e,"must be writable");let r=rEe(this,e);return t!=null&&t.signal&&nEe(t.signal,r),r}function c_(e,t){if(typeof e!="function")throw new Lp("fn",["Function","AsyncFunction"],e);t!=null&&Vc(t,"options"),t?.signal!=null&&zc(t.signal,"options.signal");let r=1;t?.concurrency!=null&&(r=yj(t.concurrency));let n=r-1;return t?.highWaterMark!=null&&(n=yj(t.highWaterMark)),gj(r,"options.concurrency",1),gj(n,"options.highWaterMark",0),n+=r,async function*(){let o=qn().AbortSignalAny([t?.signal].filter(cEe)),s=this,a=[],c={signal:o},u,l,d=!1,h=0;function f(){d=!0,p()}function p(){h-=1,m()}function m(){l&&!d&&h<r&&a.length<n&&(l(),l=null)}async function _(){try{for await(let w of s){if(d)return;if(o.aborted)throw new No;try{if(w=e(w,c),w===a_)continue;w=fEe(w)}catch(R){w=bj(R)}h+=1,Ej(w,p,f),a.push(w),u&&(u(),u=null),!d&&(a.length>=n||h>=r)&&await new _j(R=>{l=R})}a.push(wj)}catch(w){let R=bj(w);Ej(R,p,f),a.push(R)}finally{d=!0,u&&(u(),u=null)}}_();try{for(;;){for(;a.length>0;){let w=await a[0];if(w===wj)return;if(o.aborted)throw new No;w!==a_&&(yield w),a.shift(),m()}await new _j(w=>{u=w})}}finally{d=!0,l&&(l(),l=null)}}.call(this)}function pEe(e=void 0){return e!=null&&Vc(e,"options"),e?.signal!=null&&zc(e.signal,"options.signal"),async function*(){let r=0;for await(let i of this){var n;if(e!=null&&(n=e.signal)!==null&&n!==void 0&&n.aborted)throw new No({cause:e.signal.reason});yield[r++,i]}}.call(this)}async function vj(e,t=void 0){for await(let r of UA.call(this,e,t))return!0;return!1}async function hEe(e,t=void 0){if(typeof e!="function")throw new Lp("fn",["Function","AsyncFunction"],e);return!await vj.call(this,async(...r)=>!await e(...r),t)}async function mEe(e,t){for await(let r of UA.call(this,e,t))return r}async function gEe(e,t){if(typeof e!="function")throw new Lp("fn",["Function","AsyncFunction"],e);async function r(n,i){return await e(n,i),a_}for await(let n of c_.call(this,r,t));}function UA(e,t){if(typeof e!="function")throw new Lp("fn",["Function","AsyncFunction"],e);async function r(n,i){return await e(n,i)?n:a_}return c_.call(this,r,t)}var jA=class extends J0e{constructor(){super("reduce"),this.message="Reduce of an empty stream requires an initial value"}};async function yEe(e,t,r){var n;if(typeof e!="function")throw new Lp("reducer",["Function","AsyncFunction"],e);r!=null&&Vc(r,"options"),r?.signal!=null&&zc(r.signal,"options.signal");let i=arguments.length>1;if(r!=null&&(n=r.signal)!==null&&n!==void 0&&n.aborted){let u=new No(void 0,{cause:r.signal.reason});throw this.once("error",()=>{}),await tEe(this.destroy(u)),u}let o=new Y0e,s=o.signal;if(r!=null&&r.signal){let u={once:!0,[Z0e]:this,[eEe]:!0};r.signal.addEventListener("abort",()=>o.abort(),u)}let a=!1;try{for await(let u of this){var c;if(a=!0,r!=null&&(c=r.signal)!==null&&c!==void 0&&c.aborted)throw new No;i?t=await e(t,u,{signal:s}):(t=u,i=!0)}if(!a&&!i)throw new jA}finally{o.abort()}return t}async function _Ee(e){e!=null&&Vc(e,"options"),e?.signal!=null&&zc(e.signal,"options.signal");let t=[];for await(let n of this){var r;if(e!=null&&(r=e.signal)!==null&&r!==void 0&&r.aborted)throw new No(void 0,{cause:e.signal.reason});aEe(t,n)}return t}function bEe(e,t){let r=c_.call(this,e,t);return async function*(){for await(let i of r)yield*i}.call(this)}function Cj(e){if(e=uEe(e),lEe(e))return 0;if(e<0)throw new Q0e("number",">= 0",e);return e}function EEe(e,t=void 0){return t!=null&&Vc(t,"options"),t?.signal!=null&&zc(t.signal,"options.signal"),e=Cj(e),async function*(){var n;if(t!=null&&(n=t.signal)!==null&&n!==void 0&&n.aborted)throw new No;for await(let o of this){var i;if(t!=null&&(i=t.signal)!==null&&i!==void 0&&i.aborted)throw new No;e--<=0&&(yield o)}}.call(this)}function wEe(e,t=void 0){return t!=null&&Vc(t,"options"),t?.signal!=null&&zc(t.signal,"options.signal"),e=Cj(e),async function*(){var n;if(t!=null&&(n=t.signal)!==null&&n!==void 0&&n.aborted)throw new No;for await(let o of this){var i;if(t!=null&&(i=t.signal)!==null&&i!==void 0&&i.aborted)throw new No;if(e-- >0&&(yield o),e<=0)return}}.call(this)}HA.exports.streamReturningOperators={asIndexedPairs:sEe(pEe,"readable.asIndexedPairs will be removed in a future version."),drop:EEe,filter:UA,flatMap:bEe,map:c_,take:wEe,compose:dEe};HA.exports.promiseReturningOperators={every:hEe,forEach:gEe,reduce:yEe,toArray:_Ee,some:vj,find:mEe}});var $A=E((Rft,Tj)=>{"use strict";var{ArrayPrototypePop:SEe,Promise:vEe}=er(),{isIterable:CEe,isNodeStream:xEe,isWebStream:TEe}=Oo(),{pipelineImpl:AEe}=i_(),{finished:REe}=bs();GA();function PEe(...e){return new vEe((t,r)=>{let n,i,o=e[e.length-1];if(o&&typeof o=="object"&&!xEe(o)&&!CEe(o)&&!TEe(o)){let s=SEe(e);n=s.signal,i=s.end}AEe(e,(s,a)=>{s?r(s):t(a)},{signal:n,end:i})})}Tj.exports={finished:REe,pipeline:PEe}});var GA=E((Pft,Mj)=>{"use strict";var{Buffer:OEe}=require("buffer"),{ObjectDefineProperty:Ss,ObjectKeys:Pj,ReflectApply:Oj}=er(),{promisify:{custom:Ij}}=qn(),{streamReturningOperators:Aj,promiseReturningOperators:Rj}=xj(),{codes:{ERR_ILLEGAL_CONSTRUCTOR:Dj}}=yn(),IEe=qA(),{setDefaultHighWaterMark:DEe,getDefaultHighWaterMark:kEe}=Ap(),{pipeline:kj}=i_(),{destroyer:NEe}=qc(),Nj=bs(),zA=$A(),Bp=Oo(),Qt=Mj.exports=Uy().Stream;Qt.isDestroyed=Bp.isDestroyed;Qt.isDisturbed=Bp.isDisturbed;Qt.isErrored=Bp.isErrored;Qt.isReadable=Bp.isReadable;Qt.isWritable=Bp.isWritable;Qt.Readable=Op();for(let e of Pj(Aj)){let r=function(...n){if(new.target)throw Dj();return Qt.Readable.from(Oj(t,this,n))},t=Aj[e];Ss(r,"name",{__proto__:null,value:t.name}),Ss(r,"length",{__proto__:null,value:t.length}),Ss(Qt.Readable.prototype,e,{__proto__:null,value:r,enumerable:!1,configurable:!0,writable:!0})}for(let e of Pj(Rj)){let r=function(...n){if(new.target)throw Dj();return Oj(t,this,n)},t=Rj[e];Ss(r,"name",{__proto__:null,value:t.name}),Ss(r,"length",{__proto__:null,value:t.length}),Ss(Qt.Readable.prototype,e,{__proto__:null,value:r,enumerable:!1,configurable:!0,writable:!0})}Qt.Writable=e_();Qt.Duplex=ko();Qt.Transform=TA();Qt.PassThrough=RA();Qt.pipeline=kj;var{addAbortSignal:MEe}=Tp();Qt.addAbortSignal=MEe;Qt.finished=Nj;Qt.destroy=NEe;Qt.compose=IEe;Qt.setDefaultHighWaterMark=DEe;Qt.getDefaultHighWaterMark=kEe;Ss(Qt,"promises",{__proto__:null,configurable:!0,enumerable:!0,get(){return zA}});Ss(kj,Ij,{__proto__:null,enumerable:!0,get(){return zA.pipeline}});Ss(Nj,Ij,{__proto__:null,enumerable:!0,get(){return zA.finished}});Qt.Stream=Qt;Qt._isUint8Array=function(t){return t instanceof Uint8Array};Qt._uint8ArrayToBuffer=function(t){return OEe.from(t.buffer,t.byteOffset,t.byteLength)}});var Lj=E((Oft,it)=>{"use strict";var Ir=require("stream");if(Ir&&process.env.READABLE_STREAM==="disable"){let e=Ir.promises;it.exports._uint8ArrayToBuffer=Ir._uint8ArrayToBuffer,it.exports._isUint8Array=Ir._isUint8Array,it.exports.isDisturbed=Ir.isDisturbed,it.exports.isErrored=Ir.isErrored,it.exports.isReadable=Ir.isReadable,it.exports.Readable=Ir.Readable,it.exports.Writable=Ir.Writable,it.exports.Duplex=Ir.Duplex,it.exports.Transform=Ir.Transform,it.exports.PassThrough=Ir.PassThrough,it.exports.addAbortSignal=Ir.addAbortSignal,it.exports.finished=Ir.finished,it.exports.destroy=Ir.destroy,it.exports.pipeline=Ir.pipeline,it.exports.compose=Ir.compose,Object.defineProperty(Ir,"promises",{configurable:!0,enumerable:!0,get(){return e}}),it.exports.Stream=Ir.Stream}else{let e=GA(),t=$A(),r=e.Readable.destroy;it.exports=e.Readable,it.exports._uint8ArrayToBuffer=e._uint8ArrayToBuffer,it.exports._isUint8Array=e._isUint8Array,it.exports.isDisturbed=e.isDisturbed,it.exports.isErrored=e.isErrored,it.exports.isReadable=e.isReadable,it.exports.Readable=e.Readable,it.exports.Writable=e.Writable,it.exports.Duplex=e.Duplex,it.exports.Transform=e.Transform,it.exports.PassThrough=e.PassThrough,it.exports.addAbortSignal=e.addAbortSignal,it.exports.finished=e.finished,it.exports.destroy=e.destroy,it.exports.destroy=r,it.exports.pipeline=e.pipeline,it.exports.compose=e.compose,Object.defineProperty(e,"promises",{configurable:!0,enumerable:!0,get(){return t}}),it.exports.Stream=e.Stream}it.exports.default=it.exports});var jj=E((Ift,qj)=>{"use strict";var LEe=P3(),u_=require("stream");(!u_.Writable||!u_.Writable.prototype.destroy)&&(u_=Lj());var l_;function BEe(){let t,r,n;for(l_=[],r=0;r<256;r++){for(t=r,n=0;n<8;n++)t=t&1?3988292384^t>>>1:t=t>>>1;l_[r]=t>>>0}}function Bj(e,t){l_||BEe(),e.charCodeAt&&(e=e.charCodeAt(0));let r=t.readUInt32BE()>>8&16777215,n=l_[(t.readUInt32BE()^e>>>0)&255];return(r^n)>>>0}function Fj(e,t){let r=e>>16&65535,n=e&65535,i=t>>16&65535,o=t&65535;return((r*o+n*i&65535)<<16>>>0)+n*o}function Il(){if(!(this instanceof Il))return new Il;this.key0=Buffer.allocUnsafe(4),this.key1=Buffer.allocUnsafe(4),this.key2=Buffer.allocUnsafe(4),this.key0.writeUInt32BE(305419896,0),this.key1.writeUInt32BE(591751049,0),this.key2.writeUInt32BE(878082192,0)}Il.prototype.update=function(e){this.key0.writeUInt32BE(Bj(e,this.key0)),this.key1.writeUInt32BE((this.key0.readUInt32BE()&255&4294967295)+this.key1.readUInt32BE()>>>0);let t=new LEe(Fj(this.key1.readUInt32BE(),134775813)+1&4294967295),r=Buffer.alloc(8);t.copy(r,0),r.copy(this.key1,0,4,8),this.key2.writeUInt32BE(Bj((this.key1.readUInt32BE()>>24&255)>>>0,this.key2))};Il.prototype.decryptByte=function(e){let t=(this.key2.readUInt32BE()|2)>>>0;return e=e^Fj(t,t^1)>>8&255,this.update(e),e};Il.prototype.stream=function(){let e=u_.Transform(),t=this;return e._transform=function(r,n,i){for(let o=0;o<r.length;o++)r[o]=t.decryptByte(r[o]);this.push(r),i()},e};qj.exports=Il});var $j=E((Dft,Hj)=>{"use strict";var FEe=jj(),qEe=ry(),Uj=require("stream"),jEe=require("zlib"),UEe=iy(),HEe=oy(),$Ee=rp();Hj.exports=function(t,r,n,i,o){let s=qEe(),a=Uj.PassThrough(),c=t.stream(r,o);return c.pipe(s).on("error",function(u){a.emit("error",u)}),a.vars=s.pull(30).then(function(u){let l=$Ee.parse(u,[["signature",4],["versionsNeededToExtract",2],["flags",2],["compressionMethod",2],["lastModifiedTime",2],["lastModifiedDate",2],["crc32",4],["compressedSize",4],["uncompressedSize",4],["fileNameLength",2],["extraFieldLength",2]]);return l.lastModifiedDateTime=HEe(l.lastModifiedDate,l.lastModifiedTime),s.pull(l.fileNameLength).then(function(d){return l.fileName=d.toString("utf8"),s.pull(l.extraFieldLength)}).then(function(d){let h;return l.extra=UEe(d,l),i&&i.compressedSize&&(l=i),l.flags&1&&(h=s.pull(12).then(function(f){if(!n)throw new Error("MISSING_PASSWORD");let p=FEe();String(n).split("").forEach(function(_){p.update(_)});for(let _=0;_<f.length;_++)f[_]=p.decryptByte(f[_]);l.decrypt=p,l.compressedSize-=12;let m=l.flags&8?l.lastModifiedTime>>8&255:l.crc32>>24&255;if(f[11]!==m)throw new Error("BAD_PASSWORD");return l})),Promise.resolve(h).then(function(){return a.emit("vars",l),l})})}),a.vars.then(function(u){let l=!(u.flags&8)||u.compressedSize>0,d,h=u.compressionMethod?jEe.createInflateRaw():Uj.PassThrough();l?(a.size=u.uncompressedSize,d=u.compressedSize):(d=Buffer.alloc(4),d.writeUInt32LE(134695760,0));let f=s.stream(d);u.decrypt&&(f=f.pipe(u.decrypt.stream())),f.pipe(h).on("error",function(p){a.emit("error",p)}).pipe(a).on("finish",function(){c.destroy?c.destroy():c.abort?c.abort():c.close?c.close():c.push?c.push():console.log("warning - unable to close stream")})}).catch(function(u){a.emit("error",u)}),a}});var ga=E((kft,KA)=>{"use strict";var VA=(function(){"use strict";return this===void 0})();VA?KA.exports={freeze:Object.freeze,defineProperty:Object.defineProperty,getDescriptor:Object.getOwnPropertyDescriptor,keys:Object.keys,names:Object.getOwnPropertyNames,getPrototypeOf:Object.getPrototypeOf,isArray:Array.isArray,isES5:VA,propertyIsWritable:function(e,t){var r=Object.getOwnPropertyDescriptor(e,t);return!!(!r||r.writable||r.set)}}:(Gj={}.hasOwnProperty,zj={}.toString,Vj={}.constructor.prototype,WA=function(e){var t=[];for(var r in e)Gj.call(e,r)&&t.push(r);return t},Wj=function(e,t){return{value:e[t]}},Kj=function(e,t,r){return e[t]=r.value,e},Yj=function(e){return e},Xj=function(e){try{return Object(e).constructor.prototype}catch{return Vj}},Jj=function(e){try{return zj.call(e)==="[object Array]"}catch{return!1}},KA.exports={isArray:Jj,keys:WA,names:WA,defineProperty:Kj,getDescriptor:Wj,freeze:Yj,getPrototypeOf:Xj,isES5:VA,propertyIsWritable:function(){return!0}});var Gj,zj,Vj,WA,Wj,Kj,Yj,Xj,Jj});var Vt=E((exports,module)=>{"use strict";var es5=ga(),canEvaluate=typeof navigator>"u",errorObj={e:{}},tryCatchTarget,globalObject=typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:exports!==void 0?exports:null;function tryCatcher(){try{var e=tryCatchTarget;return tryCatchTarget=null,e.apply(this,arguments)}catch(t){return errorObj.e=t,errorObj}}function tryCatch(e){return tryCatchTarget=e,tryCatcher}var inherits=function(e,t){var r={}.hasOwnProperty;function n(){this.constructor=e,this.constructor$=t;for(var i in t.prototype)r.call(t.prototype,i)&&i.charAt(i.length-1)!=="$"&&(this[i+"$"]=t.prototype[i])}return n.prototype=t.prototype,e.prototype=new n,e.prototype};function isPrimitive(e){return e==null||e===!0||e===!1||typeof e=="string"||typeof e=="number"}function isObject(e){return typeof e=="function"||typeof e=="object"&&e!==null}function maybeWrapAsError(e){return isPrimitive(e)?new Error(safeToString(e)):e}function withAppended(e,t){var r=e.length,n=new Array(r+1),i;for(i=0;i<r;++i)n[i]=e[i];return n[i]=t,n}function getDataPropertyOrDefault(e,t,r){if(es5.isES5){var n=Object.getOwnPropertyDescriptor(e,t);if(n!=null)return n.get==null&&n.set==null?n.value:r}else return{}.hasOwnProperty.call(e,t)?e[t]:void 0}function notEnumerableProp(e,t,r){if(isPrimitive(e))return e;var n={value:r,configurable:!0,enumerable:!1,writable:!0};return es5.defineProperty(e,t,n),e}function thrower(e){throw e}var inheritedDataKeys=(function(){var e=[Array.prototype,Object.prototype,Function.prototype],t=function(i){for(var o=0;o<e.length;++o)if(e[o]===i)return!0;return!1};if(es5.isES5){var r=Object.getOwnPropertyNames;return function(i){for(var o=[],s=Object.create(null);i!=null&&!t(i);){var a;try{a=r(i)}catch{return o}for(var c=0;c<a.length;++c){var u=a[c];if(!s[u]){s[u]=!0;var l=Object.getOwnPropertyDescriptor(i,u);l!=null&&l.get==null&&l.set==null&&o.push(u)}}i=es5.getPrototypeOf(i)}return o}}else{var n={}.hasOwnProperty;return function(i){if(t(i))return[];var o=[];e:for(var s in i)if(n.call(i,s))o.push(s);else{for(var a=0;a<e.length;++a)if(n.call(e[a],s))continue e;o.push(s)}return o}}})(),thisAssignmentPattern=/this\s*\.\s*\S+\s*=/;function isClass(e){try{if(typeof e=="function"){var t=es5.names(e.prototype),r=es5.isES5&&t.length>1,n=t.length>0&&!(t.length===1&&t[0]==="constructor"),i=thisAssignmentPattern.test(e+"")&&es5.names(e).length>0;if(r||n||i)return!0}return!1}catch{return!1}}function toFastProperties(obj){function FakeConstructor(){}FakeConstructor.prototype=obj;var receiver=new FakeConstructor;function ic(){return typeof receiver.foo}return ic(),ic(),obj;eval(obj)}var rident=/^[a-z$_][a-z$_0-9]*$/i;function isIdentifier(e){return rident.test(e)}function filledRange(e,t,r){for(var n=new Array(e),i=0;i<e;++i)n[i]=t+i+r;return n}function safeToString(e){try{return e+""}catch{return"[no string representation]"}}function isError(e){return e instanceof Error||e!==null&&typeof e=="object"&&typeof e.message=="string"&&typeof e.name=="string"}function markAsOriginatingFromRejection(e){try{notEnumerableProp(e,"isOperational",!0)}catch{}}function originatesFromRejection(e){return e==null?!1:e instanceof Error.__BluebirdErrorTypes__.OperationalError||e.isOperational===!0}function canAttachTrace(e){return isError(e)&&es5.propertyIsWritable(e,"stack")}var ensureErrorObject=(function(){return"stack"in new Error?function(e){return canAttachTrace(e)?e:new Error(safeToString(e))}:function(e){if(canAttachTrace(e))return e;try{throw new Error(safeToString(e))}catch(t){return t}}})();function classString(e){return{}.toString.call(e)}function copyDescriptors(e,t,r){for(var n=es5.names(e),i=0;i<n.length;++i){var o=n[i];if(r(o))try{es5.defineProperty(t,o,es5.getDescriptor(e,o))}catch{}}}var asArray=function(e){return es5.isArray(e)?e:null};typeof Symbol<"u"&&Symbol.iterator&&(ArrayFrom=typeof Array.from=="function"?function(e){return Array.from(e)}:function(e){for(var t=[],r=e[Symbol.iterator](),n;!(n=r.next()).done;)t.push(n.value);return t},asArray=function(e){return es5.isArray(e)?e:e!=null&&typeof e[Symbol.iterator]=="function"?ArrayFrom(e):null});var ArrayFrom,isNode=typeof process<"u"&&classString(process).toLowerCase()==="[object process]",hasEnvVariables=typeof process<"u"&&typeof process.env<"u";function env(e){return hasEnvVariables?process.env[e]:void 0}function getNativePromise(){if(typeof Promise=="function")try{var e=new Promise(function(){});if(classString(e)==="[object Promise]")return Promise}catch{}}var reflectHandler;function contextBind(e,t){if(e===null||typeof t!="function"||t===reflectHandler)return t;e.domain!==null&&(t=e.domain.bind(t));var r=e.async;if(r!==null){var n=t;t=function(){for(var i=arguments.length+2,o=new Array(i),s=2;s<i;++s)o[s]=arguments[s-2];return o[0]=n,o[1]=this,r.runInAsyncScope.apply(r,o)}}return t}var ret={setReflectHandler:function(e){reflectHandler=e},isClass,isIdentifier,inheritedDataKeys,getDataPropertyOrDefault,thrower,isArray:es5.isArray,asArray,notEnumerableProp,isPrimitive,isObject,isError,canEvaluate,errorObj,tryCatch,inherits,withAppended,maybeWrapAsError,toFastProperties,filledRange,toString:safeToString,canAttachTrace,ensureErrorObject,originatesFromRejection,markAsOriginatingFromRejection,classString,copyDescriptors,isNode,hasEnvVariables,env,global:globalObject,getNativePromise,contextBind};ret.isRecentNode=ret.isNode&&(function(){var e;return process.versions&&process.versions.node?e=process.versions.node.split(".").map(Number):process.version&&(e=process.version.split(".").map(Number)),e[0]===0&&e[1]>10||e[0]>0})();ret.nodeSupportsAsyncResource=ret.isNode&&(function(){var e=!1;try{var t=require("async_hooks").AsyncResource;e=typeof t.prototype.runInAsyncScope=="function"}catch{e=!1}return e})();ret.isNode&&ret.toFastProperties(process);try{throw new Error}catch(e){ret.lastLineError=e}module.exports=ret});var rU=E((Nft,tU)=>{"use strict";var XA=Vt(),Wc,GEe=function(){throw new Error(`No async scheduler available
|
|
9
|
+
|
|
10
|
+
See http://goo.gl/MqrFmX
|
|
11
|
+
`)},YA=XA.getNativePromise();XA.isNode&&typeof MutationObserver>"u"?(Qj=global.setImmediate,Zj=process.nextTick,Wc=XA.isRecentNode?function(e){Qj.call(global,e)}:function(e){Zj.call(process,e)}):typeof YA=="function"&&typeof YA.resolve=="function"?(eU=YA.resolve(),Wc=function(e){eU.then(e)}):typeof MutationObserver<"u"&&!(typeof window<"u"&&window.navigator&&(window.navigator.standalone||window.cordova))&&"classList"in document.documentElement?Wc=(function(){var e=document.createElement("div"),t={attributes:!0},r=!1,n=document.createElement("div"),i=new MutationObserver(function(){e.classList.toggle("foo"),r=!1});i.observe(n,t);var o=function(){r||(r=!0,n.classList.toggle("foo"))};return function(a){var c=new MutationObserver(function(){c.disconnect(),a()});c.observe(e,t),o()}})():typeof setImmediate<"u"?Wc=function(e){setImmediate(e)}:typeof setTimeout<"u"?Wc=function(e){setTimeout(e,0)}:Wc=GEe;var Qj,Zj,eU;tU.exports=Wc});var iU=E((Mft,nU)=>{"use strict";function zEe(e,t,r,n,i){for(var o=0;o<i;++o)r[o+n]=e[o+t],e[o+t]=void 0}function ya(e){this._capacity=e,this._length=0,this._front=0}ya.prototype._willBeOverCapacity=function(e){return this._capacity<e};ya.prototype._pushOne=function(e){var t=this.length();this._checkCapacity(t+1);var r=this._front+t&this._capacity-1;this[r]=e,this._length=t+1};ya.prototype.push=function(e,t,r){var n=this.length()+3;if(this._willBeOverCapacity(n)){this._pushOne(e),this._pushOne(t),this._pushOne(r);return}var i=this._front+n-3;this._checkCapacity(n);var o=this._capacity-1;this[i+0&o]=e,this[i+1&o]=t,this[i+2&o]=r,this._length=n};ya.prototype.shift=function(){var e=this._front,t=this[e];return this[e]=void 0,this._front=e+1&this._capacity-1,this._length--,t};ya.prototype.length=function(){return this._length};ya.prototype._checkCapacity=function(e){this._capacity<e&&this._resizeTo(this._capacity<<1)};ya.prototype._resizeTo=function(e){var t=this._capacity;this._capacity=e;var r=this._front,n=this._length,i=r+n&t-1;zEe(this,0,this,t,i)};nU.exports=ya});var cU=E((Lft,JA)=>{"use strict";var aU;try{throw new Error}catch(e){aU=e}var VEe=rU(),oU=iU();function Di(){this._customScheduler=!1,this._isTickUsed=!1,this._lateQueue=new oU(16),this._normalQueue=new oU(16),this._haveDrainedQueues=!1;var e=this;this.drainQueues=function(){e._drainQueues()},this._schedule=VEe}Di.prototype.setScheduler=function(e){var t=this._schedule;return this._schedule=e,this._customScheduler=!0,t};Di.prototype.hasCustomScheduler=function(){return this._customScheduler};Di.prototype.haveItemsQueued=function(){return this._isTickUsed||this._haveDrainedQueues};Di.prototype.fatalError=function(e,t){t?(process.stderr.write("Fatal "+(e instanceof Error?e.stack:e)+`
|
|
12
|
+
`),process.exit(2)):this.throwLater(e)};Di.prototype.throwLater=function(e,t){if(arguments.length===1&&(t=e,e=function(){throw t}),typeof setTimeout<"u")setTimeout(function(){e(t)},0);else try{this._schedule(function(){e(t)})}catch{throw new Error(`No async scheduler available
|
|
13
|
+
|
|
14
|
+
See http://goo.gl/MqrFmX
|
|
15
|
+
`)}};function WEe(e,t,r){this._lateQueue.push(e,t,r),this._queueTick()}function KEe(e,t,r){this._normalQueue.push(e,t,r),this._queueTick()}function YEe(e){this._normalQueue._pushOne(e),this._queueTick()}Di.prototype.invokeLater=WEe;Di.prototype.invoke=KEe;Di.prototype.settlePromises=YEe;function sU(e){for(;e.length()>0;)XEe(e)}function XEe(e){var t=e.shift();if(typeof t!="function")t._settlePromises();else{var r=e.shift(),n=e.shift();t.call(r,n)}}Di.prototype._drainQueues=function(){sU(this._normalQueue),this._reset(),this._haveDrainedQueues=!0,sU(this._lateQueue)};Di.prototype._queueTick=function(){this._isTickUsed||(this._isTickUsed=!0,this._schedule(this.drainQueues))};Di.prototype._reset=function(){this._isTickUsed=!1};JA.exports=Di;JA.exports.firstLineError=aU});var vs=E((Bft,fU)=>{"use strict";var eR=ga(),JEe=eR.freeze,uU=Vt(),lU=uU.inherits,kl=uU.notEnumerableProp;function Nl(e,t){function r(n){if(!(this instanceof r))return new r(n);kl(this,"message",typeof n=="string"?n:t),kl(this,"name",e),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):Error.call(this)}return lU(r,Error),r}var QA,ZA,QEe=Nl("Warning","warning"),ZEe=Nl("CancellationError","cancellation error"),ewe=Nl("TimeoutError","timeout error"),qp=Nl("AggregateError","aggregate error");try{QA=TypeError,ZA=RangeError}catch{QA=Nl("TypeError","type error"),ZA=Nl("RangeError","range error")}var f_="join pop push shift unshift slice filter forEach some every map indexOf lastIndexOf reduce reduceRight sort reverse".split(" ");for(Dl=0;Dl<f_.length;++Dl)typeof Array.prototype[f_[Dl]]=="function"&&(qp.prototype[f_[Dl]]=Array.prototype[f_[Dl]]);var Dl;eR.defineProperty(qp.prototype,"length",{value:0,configurable:!1,writable:!0,enumerable:!0});qp.prototype.isOperational=!0;var d_=0;qp.prototype.toString=function(){var e=Array(d_*4+1).join(" "),t=`
|
|
16
|
+
`+e+`AggregateError of:
|
|
17
|
+
`;d_++,e=Array(d_*4+1).join(" ");for(var r=0;r<this.length;++r){for(var n=this[r]===this?"[Circular AggregateError]":this[r]+"",i=n.split(`
|
|
18
|
+
`),o=0;o<i.length;++o)i[o]=e+i[o];n=i.join(`
|
|
19
|
+
`),t+=n+`
|
|
20
|
+
`}return d_--,t};function Fp(e){if(!(this instanceof Fp))return new Fp(e);kl(this,"name","OperationalError"),kl(this,"message",e),this.cause=e,this.isOperational=!0,e instanceof Error?(kl(this,"message",e.message),kl(this,"stack",e.stack)):Error.captureStackTrace&&Error.captureStackTrace(this,this.constructor)}lU(Fp,Error);var Kc=Error.__BluebirdErrorTypes__;Kc||(Kc=JEe({CancellationError:ZEe,TimeoutError:ewe,OperationalError:Fp,RejectionError:Fp,AggregateError:qp}),eR.defineProperty(Error,"__BluebirdErrorTypes__",{value:Kc,writable:!1,enumerable:!1,configurable:!1}));fU.exports={Error,TypeError:QA,RangeError:ZA,CancellationError:Kc.CancellationError,OperationalError:Kc.OperationalError,TimeoutError:Kc.TimeoutError,AggregateError:Kc.AggregateError,Warning:QEe}});var pU=E((Fft,dU)=>{"use strict";dU.exports=function(e,t){var r=Vt(),n=r.errorObj,i=r.isObject;function o(d,h){if(i(d)){if(d instanceof e)return d;var f=a(d);if(f===n){h&&h._pushContext();var p=e.reject(f.e);return h&&h._popContext(),p}else if(typeof f=="function"){if(u(d)){var p=new e(t);return d._then(p._fulfill,p._reject,void 0,p,null),p}return l(d,f,h)}}return d}function s(d){return d.then}function a(d){try{return s(d)}catch(h){return n.e=h,n}}var c={}.hasOwnProperty;function u(d){try{return c.call(d,"_promise0")}catch{return!1}}function l(d,h,f){var p=new e(t),m=p;f&&f._pushContext(),p._captureStackTrace(),f&&f._popContext();var _=!0,w=r.tryCatch(h).call(d,R,v);_=!1,p&&w===n&&(p._rejectCallback(w.e,!0,!0),p=null);function R(y){p&&(p._resolveCallback(y),p=null)}function v(y){p&&(p._rejectCallback(y,_,!0),p=null)}return m}return o}});var mU=E((qft,hU)=>{"use strict";hU.exports=function(e,t,r,n,i){var o=Vt(),s=o.isArray;function a(u){switch(u){case-2:return[];case-3:return{};case-6:return new Map}}function c(u){var l=this._promise=new e(t);u instanceof e&&(l._propagateFrom(u,3),u.suppressUnhandledRejections()),l._setOnCancel(this),this._values=u,this._length=0,this._totalResolved=0,this._init(void 0,-2)}return o.inherits(c,i),c.prototype.length=function(){return this._length},c.prototype.promise=function(){return this._promise},c.prototype._init=function u(l,d){var h=r(this._values,this._promise);if(h instanceof e){h=h._target();var f=h._bitField;if(this._values=h,(f&50397184)===0)return this._promise._setAsyncGuaranteed(),h._then(u,this._reject,void 0,this,d);if((f&33554432)!==0)h=h._value();else return(f&16777216)!==0?this._reject(h._reason()):this._cancel()}if(h=o.asArray(h),h===null){var p=n("expecting an array or an iterable object but got "+o.classString(h)).reason();this._promise._rejectCallback(p,!1);return}if(h.length===0){d===-5?this._resolveEmptyArray():this._resolve(a(d));return}this._iterate(h)},c.prototype._iterate=function(u){var l=this.getActualLength(u.length);this._length=l,this._values=this.shouldCopyValues()?new Array(l):this._values;for(var d=this._promise,h=!1,f=null,p=0;p<l;++p){var m=r(u[p],d);m instanceof e?(m=m._target(),f=m._bitField):f=null,h?f!==null&&m.suppressUnhandledRejections():f!==null?(f&50397184)===0?(m._proxy(this,p),this._values[p]=m):(f&33554432)!==0?h=this._promiseFulfilled(m._value(),p):(f&16777216)!==0?h=this._promiseRejected(m._reason(),p):h=this._promiseCancelled(p):h=this._promiseFulfilled(m,p)}h||d._setAsyncGuaranteed()},c.prototype._isResolved=function(){return this._values===null},c.prototype._resolve=function(u){this._values=null,this._promise._fulfill(u)},c.prototype._cancel=function(){this._isResolved()||!this._promise._isCancellable()||(this._values=null,this._promise._cancel())},c.prototype._reject=function(u){this._values=null,this._promise._rejectCallback(u,!1)},c.prototype._promiseFulfilled=function(u,l){this._values[l]=u;var d=++this._totalResolved;return d>=this._length?(this._resolve(this._values),!0):!1},c.prototype._promiseCancelled=function(){return this._cancel(),!0},c.prototype._promiseRejected=function(u){return this._totalResolved++,this._reject(u),!0},c.prototype._resultCancelled=function(){if(!this._isResolved()){var u=this._values;if(this._cancel(),u instanceof e)u.cancel();else for(var l=0;l<u.length;++l)u[l]instanceof e&&u[l].cancel()}},c.prototype.shouldCopyValues=function(){return!0},c.prototype.getActualLength=function(u){return u},c}});var yU=E((jft,gU)=>{"use strict";gU.exports=function(e){var t=!1,r=[];e.prototype._promiseCreated=function(){},e.prototype._pushContext=function(){},e.prototype._popContext=function(){return null},e._peekContext=e.prototype._peekContext=function(){};function n(){this._trace=new n.CapturedTrace(o())}n.prototype._pushContext=function(){this._trace!==void 0&&(this._trace._promiseCreated=null,r.push(this._trace))},n.prototype._popContext=function(){if(this._trace!==void 0){var s=r.pop(),a=s._promiseCreated;return s._promiseCreated=null,a}return null};function i(){if(t)return new n}function o(){var s=r.length-1;if(s>=0)return r[s]}return n.CapturedTrace=null,n.create=i,n.deactivateLongStackTraces=function(){},n.activateLongStackTraces=function(){var s=e.prototype._pushContext,a=e.prototype._popContext,c=e._peekContext,u=e.prototype._peekContext,l=e.prototype._promiseCreated;n.deactivateLongStackTraces=function(){e.prototype._pushContext=s,e.prototype._popContext=a,e._peekContext=c,e.prototype._peekContext=u,e.prototype._promiseCreated=l,t=!1},t=!0,e.prototype._pushContext=n.prototype._pushContext,e.prototype._popContext=n.prototype._popContext,e._peekContext=e.prototype._peekContext=o,e.prototype._promiseCreated=function(){var d=this._peekContext();d&&d._promiseCreated==null&&(d._promiseCreated=this)}},n}});var bU=E((Uft,_U)=>{"use strict";_U.exports=function(e,t,r,n){var i=e._async,o=vs().Warning,s=Vt(),a=ga(),c=s.canAttachTrace,u,l,d=/[\\\/]bluebird[\\\/]js[\\\/](release|debug|instrumented)/,h=/\((?:timers\.js):\d+:\d+\)/,f=/[\/<\(](.+?):(\d+):(\d+)\)?\s*$/,p=null,m=null,_=!1,w,R=!!(s.env("BLUEBIRD_DEBUG")!=0&&(s.env("BLUEBIRD_DEBUG")||s.env("NODE_ENV")==="development")),v=!!(s.env("BLUEBIRD_WARNINGS")!=0&&(R||s.env("BLUEBIRD_WARNINGS"))),y=!!(s.env("BLUEBIRD_LONG_STACK_TRACES")!=0&&(R||s.env("BLUEBIRD_LONG_STACK_TRACES"))),S=s.env("BLUEBIRD_W_FORGOTTEN_RETURN")!=0&&(v||!!s.env("BLUEBIRD_W_FORGOTTEN_RETURN")),O;(function(){var X=[];function Q(){for(var ye=0;ye<X.length;++ye)X[ye]._notifyUnhandledRejection();de()}function de(){X.length=0}O=function(ye){X.push(ye),setTimeout(Q,1)},a.defineProperty(e,"_unhandledRejectionCheck",{value:Q}),a.defineProperty(e,"_unhandledRejectionClear",{value:de})})(),e.prototype.suppressUnhandledRejections=function(){var X=this._target();X._bitField=X._bitField&-1048577|524288},e.prototype._ensurePossibleRejectionHandled=function(){(this._bitField&524288)===0&&(this._setRejectionIsUnhandled(),O(this))},e.prototype._notifyUnhandledRejectionIsHandled=function(){gr("rejectionHandled",u,void 0,this)},e.prototype._setReturnedNonUndefined=function(){this._bitField=this._bitField|268435456},e.prototype._returnedNonUndefined=function(){return(this._bitField&268435456)!==0},e.prototype._notifyUnhandledRejection=function(){if(this._isRejectionUnhandled()){var X=this._settledValue();this._setUnhandledRejectionIsNotified(),gr("unhandledRejection",l,X,this)}},e.prototype._setUnhandledRejectionIsNotified=function(){this._bitField=this._bitField|262144},e.prototype._unsetUnhandledRejectionIsNotified=function(){this._bitField=this._bitField&-262145},e.prototype._isUnhandledRejectionNotified=function(){return(this._bitField&262144)>0},e.prototype._setRejectionIsUnhandled=function(){this._bitField=this._bitField|1048576},e.prototype._unsetRejectionIsUnhandled=function(){this._bitField=this._bitField&-1048577,this._isUnhandledRejectionNotified()&&(this._unsetUnhandledRejectionIsNotified(),this._notifyUnhandledRejectionIsHandled())},e.prototype._isRejectionUnhandled=function(){return(this._bitField&1048576)>0},e.prototype._warn=function(X,Q,de){return j(X,Q,de||this)},e.onPossiblyUnhandledRejection=function(X){var Q=e._getContext();l=s.contextBind(Q,X)},e.onUnhandledRejectionHandled=function(X){var Q=e._getContext();u=s.contextBind(Q,X)};var M=function(){};e.longStackTraces=function(){if(i.haveItemsQueued()&&!Yt.longStackTraces)throw new Error(`cannot enable long stack traces after promises have been created
|
|
21
|
+
|
|
22
|
+
See http://goo.gl/MqrFmX
|
|
23
|
+
`);if(!Yt.longStackTraces&&Pi()){var X=e.prototype._captureStackTrace,Q=e.prototype._attachExtraTrace,de=e.prototype._dereferenceTrace;Yt.longStackTraces=!0,M=function(){if(i.haveItemsQueued()&&!Yt.longStackTraces)throw new Error(`cannot enable long stack traces after promises have been created
|
|
24
|
+
|
|
25
|
+
See http://goo.gl/MqrFmX
|
|
26
|
+
`);e.prototype._captureStackTrace=X,e.prototype._attachExtraTrace=Q,e.prototype._dereferenceTrace=de,t.deactivateLongStackTraces(),Yt.longStackTraces=!1},e.prototype._captureStackTrace=ce,e.prototype._attachExtraTrace=Se,e.prototype._dereferenceTrace=P,t.activateLongStackTraces()}},e.hasLongStackTraces=function(){return Yt.longStackTraces&&Pi()};var A={unhandledrejection:{before:function(){var X=s.global.onunhandledrejection;return s.global.onunhandledrejection=null,X},after:function(X){s.global.onunhandledrejection=X}},rejectionhandled:{before:function(){var X=s.global.onrejectionhandled;return s.global.onrejectionhandled=null,X},after:function(X){s.global.onrejectionhandled=X}}},D=(function(){var X=function(de,ye){if(de){var Ne;try{return Ne=de.before(),!s.global.dispatchEvent(ye)}finally{de.after(Ne)}}else return!s.global.dispatchEvent(ye)};try{if(typeof CustomEvent=="function"){var Q=new CustomEvent("CustomEvent");return s.global.dispatchEvent(Q),function(de,ye){de=de.toLowerCase();var Ne={detail:ye,cancelable:!0},ct=new CustomEvent(de,Ne);return a.defineProperty(ct,"promise",{value:ye.promise}),a.defineProperty(ct,"reason",{value:ye.reason}),X(A[de],ct)}}else if(typeof Event=="function"){var Q=new Event("CustomEvent");return s.global.dispatchEvent(Q),function(ye,Ne){ye=ye.toLowerCase();var ct=new Event(ye,{cancelable:!0});return ct.detail=Ne,a.defineProperty(ct,"promise",{value:Ne.promise}),a.defineProperty(ct,"reason",{value:Ne.reason}),X(A[ye],ct)}}else{var Q=document.createEvent("CustomEvent");return Q.initCustomEvent("testingtheevent",!1,!0,{}),s.global.dispatchEvent(Q),function(ye,Ne){ye=ye.toLowerCase();var ct=document.createEvent("CustomEvent");return ct.initCustomEvent(ye,!1,!0,Ne),X(A[ye],ct)}}}catch{}return function(){return!1}})(),I=(function(){return s.isNode?function(){return process.emit.apply(process,arguments)}:s.global?function(X){var Q="on"+X.toLowerCase(),de=s.global[Q];return de?(de.apply(s.global,[].slice.call(arguments,1)),!0):!1}:function(){return!1}})();function N(X,Q){return{promise:Q}}var J={promiseCreated:N,promiseFulfilled:N,promiseRejected:N,promiseResolved:N,promiseCancelled:N,promiseChained:function(X,Q,de){return{promise:Q,child:de}},warning:function(X,Q){return{warning:Q}},unhandledRejection:function(X,Q,de){return{reason:Q,promise:de}},rejectionHandled:N},U=function(X){var Q=!1;try{Q=I.apply(null,arguments)}catch(ye){i.throwLater(ye),Q=!0}var de=!1;try{de=D(X,J[X].apply(null,arguments))}catch(ye){i.throwLater(ye),de=!0}return de||Q};e.config=function(X){if(X=Object(X),"longStackTraces"in X&&(X.longStackTraces?e.longStackTraces():!X.longStackTraces&&e.hasLongStackTraces()&&M()),"warnings"in X){var Q=X.warnings;Yt.warnings=!!Q,S=Yt.warnings,s.isObject(Q)&&"wForgottenReturn"in Q&&(S=!!Q.wForgottenReturn)}if("cancellation"in X&&X.cancellation&&!Yt.cancellation){if(i.haveItemsQueued())throw new Error("cannot enable cancellation after promises are in use");e.prototype._clearCancellationData=$,e.prototype._propagateFrom=ve,e.prototype._onCancel=te,e.prototype._setOnCancel=ge,e.prototype._attachCancellationCallback=B,e.prototype._execute=be,at=ve,Yt.cancellation=!0}if("monitoring"in X&&(X.monitoring&&!Yt.monitoring?(Yt.monitoring=!0,e.prototype._fireEvent=U):!X.monitoring&&Yt.monitoring&&(Yt.monitoring=!1,e.prototype._fireEvent=ie)),"asyncHooks"in X&&s.nodeSupportsAsyncResource){var de=Yt.asyncHooks,ye=!!X.asyncHooks;de!==ye&&(Yt.asyncHooks=ye,ye?r():n())}return e};function ie(){return!1}e.prototype._fireEvent=ie,e.prototype._execute=function(X,Q,de){try{X(Q,de)}catch(ye){return ye}},e.prototype._onCancel=function(){},e.prototype._setOnCancel=function(X){},e.prototype._attachCancellationCallback=function(X){},e.prototype._captureStackTrace=function(){},e.prototype._attachExtraTrace=function(){},e.prototype._dereferenceTrace=function(){},e.prototype._clearCancellationData=function(){},e.prototype._propagateFrom=function(X,Q){};function be(X,Q,de){var ye=this;try{X(Q,de,function(Ne){if(typeof Ne!="function")throw new TypeError("onCancel must be a function, got: "+s.toString(Ne));ye._attachCancellationCallback(Ne)})}catch(Ne){return Ne}}function B(X){if(!this._isCancellable())return this;var Q=this._onCancel();Q!==void 0?s.isArray(Q)?Q.push(X):this._setOnCancel([Q,X]):this._setOnCancel(X)}function te(){return this._onCancelField}function ge(X){this._onCancelField=X}function $(){this._cancellationParent=void 0,this._onCancelField=void 0}function ve(X,Q){if((Q&1)!==0){this._cancellationParent=X;var de=X._branchesRemainingToCancel;de===void 0&&(de=0),X._branchesRemainingToCancel=de+1}(Q&2)!==0&&X._isBound()&&this._setBoundTo(X._boundTo)}function Ze(X,Q){(Q&2)!==0&&X._isBound()&&this._setBoundTo(X._boundTo)}var at=Ze;function G(){var X=this._boundTo;return X!==void 0&&X instanceof e?X.isFulfilled()?X.value():void 0:X}function ce(){this._trace=new ps(this._peekContext())}function Se(X,Q){if(c(X)){var de=this._trace;if(de!==void 0&&Q&&(de=de._parent),de!==void 0)de.attachExtraTrace(X);else if(!X.__stackCleaned__){var ye=Ur(X);s.notEnumerableProp(X,"stack",ye.message+`
|
|
27
|
+
`+ye.stack.join(`
|
|
28
|
+
`)),s.notEnumerableProp(X,"__stackCleaned__",!0)}}}function P(){this._trace=void 0}function T(X,Q,de,ye,Ne){if(X===void 0&&Q!==null&&S){if(Ne!==void 0&&Ne._returnedNonUndefined()||(ye._bitField&65535)===0)return;de&&(de=de+" ");var ct="",Bt="";if(Q._trace){for(var C=Q._trace.stack.split(`
|
|
29
|
+
`),x=wt(C),L=x.length-1;L>=0;--L){var V=x[L];if(!h.test(V)){var H=V.match(f);H&&(ct="at "+H[1]+":"+H[2]+":"+H[3]+" ");break}}if(x.length>0){for(var W=x[0],L=0;L<C.length;++L)if(C[L]===W){L>0&&(Bt=`
|
|
30
|
+
`+C[L-1]);break}}}var ae="a promise was created in a "+de+"handler "+ct+"but was not returned from it, see http://goo.gl/rRqMUw"+Bt;ye._warn(ae,!0,Q)}}function K(X,Q){var de=X+" is deprecated and will be removed in a future version.";return Q&&(de+=" Use "+Q+" instead."),j(de)}function j(X,Q,de){if(Yt.warnings){var ye=new o(X),Ne;if(Q)de._attachExtraTrace(ye);else if(Yt.longStackTraces&&(Ne=e._peekContext()))Ne.attachExtraTrace(ye);else{var ct=Ur(ye);ye.stack=ct.message+`
|
|
31
|
+
`+ct.stack.join(`
|
|
32
|
+
`)}U("warning",ye)||Tt(ye,"",!0)}}function Be(X,Q){for(var de=0;de<Q.length-1;++de)Q[de].push("From previous event:"),Q[de]=Q[de].join(`
|
|
33
|
+
`);return de<Q.length&&(Q[de]=Q[de].join(`
|
|
34
|
+
`)),X+`
|
|
35
|
+
`+Q.join(`
|
|
36
|
+
`)}function yt(X){for(var Q=0;Q<X.length;++Q)(X[Q].length===0||Q+1<X.length&&X[Q][0]===X[Q+1][0])&&(X.splice(Q,1),Q--)}function ft(X){for(var Q=X[0],de=1;de<X.length;++de){for(var ye=X[de],Ne=Q.length-1,ct=Q[Ne],Bt=-1,C=ye.length-1;C>=0;--C)if(ye[C]===ct){Bt=C;break}for(var C=Bt;C>=0;--C){var x=ye[C];if(Q[Ne]===x)Q.pop(),Ne--;else break}Q=ye}}function wt(X){for(var Q=[],de=0;de<X.length;++de){var ye=X[de],Ne=ye===" (No stack trace)"||p.test(ye),ct=Ne&&ra(ye);Ne&&!ct&&(_&&ye.charAt(0)!==" "&&(ye=" "+ye),Q.push(ye))}return Q}function Dt(X){for(var Q=X.stack.replace(/\s+$/g,"").split(`
|
|
37
|
+
`),de=0;de<Q.length;++de){var ye=Q[de];if(ye===" (No stack trace)"||p.test(ye))break}return de>0&&X.name!="SyntaxError"&&(Q=Q.slice(de)),Q}function Ur(X){var Q=X.stack,de=X.toString();return Q=typeof Q=="string"&&Q.length>0?Dt(X):[" (No stack trace)"],{message:de,stack:X.name=="SyntaxError"?Q:wt(Q)}}function Tt(X,Q,de){if(typeof console<"u"){var ye;if(s.isObject(X)){var Ne=X.stack;ye=Q+m(Ne,X)}else ye=Q+String(X);typeof w=="function"?w(ye,de):(typeof console.log=="function"||typeof console.log=="object")&&console.log(ye)}}function gr(X,Q,de,ye){var Ne=!1;try{typeof Q=="function"&&(Ne=!0,X==="rejectionHandled"?Q(ye):Q(de,ye))}catch(ct){i.throwLater(ct)}X==="unhandledRejection"?!U(X,de,ye)&&!Ne&&Tt(de,"Unhandled rejection "):U(X,ye)}function Qi(X){var Q;if(typeof X=="function")Q="[function "+(X.name||"anonymous")+"]";else{Q=X&&typeof X.toString=="function"?X.toString():s.toString(X);var de=/\[object [a-zA-Z0-9$_]+\]/;if(de.test(Q))try{var ye=JSON.stringify(X);Q=ye}catch{}Q.length===0&&(Q="(empty array)")}return"(<"+ta(Q)+">, no stack trace)"}function ta(X){var Q=41;return X.length<Q?X:X.substr(0,Q-3)+"..."}function Pi(){return typeof Xd=="function"}var ra=function(){return!1},Bx=/[\/<\(]([^:\/]+):(\d+):(?:\d+)\)?\s*$/;function Yd(X){var Q=X.match(Bx);if(Q)return{fileName:Q[1],line:parseInt(Q[2],10)}}function Xg(X,Q){if(Pi()){for(var de=(X.stack||"").split(`
|
|
38
|
+
`),ye=(Q.stack||"").split(`
|
|
39
|
+
`),Ne=-1,ct=-1,Bt,C,x=0;x<de.length;++x){var L=Yd(de[x]);if(L){Bt=L.fileName,Ne=L.line;break}}for(var x=0;x<ye.length;++x){var L=Yd(ye[x]);if(L){C=L.fileName,ct=L.line;break}}Ne<0||ct<0||!Bt||!C||Bt!==C||Ne>=ct||(ra=function(V){if(d.test(V))return!0;var H=Yd(V);return!!(H&&H.fileName===Bt&&Ne<=H.line&&H.line<=ct)})}}function ps(X){this._parent=X,this._promisesCreated=0;var Q=this._length=1+(X===void 0?0:X._length);Xd(this,ps),Q>32&&this.uncycle()}s.inherits(ps,Error),t.CapturedTrace=ps,ps.prototype.uncycle=function(){var X=this._length;if(!(X<2)){for(var Q=[],de={},ye=0,Ne=this;Ne!==void 0;++ye)Q.push(Ne),Ne=Ne._parent;X=this._length=ye;for(var ye=X-1;ye>=0;--ye){var ct=Q[ye].stack;de[ct]===void 0&&(de[ct]=ye)}for(var ye=0;ye<X;++ye){var Bt=Q[ye].stack,C=de[Bt];if(C!==void 0&&C!==ye){C>0&&(Q[C-1]._parent=void 0,Q[C-1]._length=1),Q[ye]._parent=void 0,Q[ye]._length=1;var x=ye>0?Q[ye-1]:this;C<X-1?(x._parent=Q[C+1],x._parent.uncycle(),x._length=x._parent._length+1):(x._parent=void 0,x._length=1);for(var L=x._length+1,V=ye-2;V>=0;--V)Q[V]._length=L,L++;return}}}},ps.prototype.attachExtraTrace=function(X){if(!X.__stackCleaned__){this.uncycle();for(var Q=Ur(X),de=Q.message,ye=[Q.stack],Ne=this;Ne!==void 0;)ye.push(wt(Ne.stack.split(`
|
|
40
|
+
`))),Ne=Ne._parent;ft(ye),yt(ye),s.notEnumerableProp(X,"stack",Be(de,ye)),s.notEnumerableProp(X,"__stackCleaned__",!0)}};var Xd=(function(){var Q=/^\s*at\s*/,de=function(Bt,C){return typeof Bt=="string"?Bt:C.name!==void 0&&C.message!==void 0?C.toString():Qi(C)};if(typeof Error.stackTraceLimit=="number"&&typeof Error.captureStackTrace=="function"){Error.stackTraceLimit+=6,p=Q,m=de;var ye=Error.captureStackTrace;return ra=function(Bt){return d.test(Bt)},function(Bt,C){Error.stackTraceLimit+=6,ye(Bt,C),Error.stackTraceLimit-=6}}var Ne=new Error;if(typeof Ne.stack=="string"&&Ne.stack.split(`
|
|
41
|
+
`)[0].indexOf("stackDetection@")>=0)return p=/@/,m=de,_=!0,function(C){C.stack=new Error().stack};var ct;try{throw new Error}catch(Bt){ct="stack"in Bt}return!("stack"in Ne)&&ct&&typeof Error.stackTraceLimit=="number"?(p=Q,m=de,function(C){Error.stackTraceLimit+=6;try{throw new Error}catch(x){C.stack=x.stack}Error.stackTraceLimit-=6}):(m=function(Bt,C){return typeof Bt=="string"?Bt:(typeof C=="object"||typeof C=="function")&&C.name!==void 0&&C.message!==void 0?C.toString():Qi(C)},null)})([]);typeof console<"u"&&typeof console.warn<"u"&&(w=function(X){console.warn(X)},s.isNode&&process.stderr.isTTY?w=function(X,Q){var de=Q?"\x1B[33m":"\x1B[31m";console.warn(de+X+`\x1B[0m
|
|
42
|
+
`)}:!s.isNode&&typeof new Error().stack=="string"&&(w=function(X,Q){console.warn("%c"+X,Q?"color: darkorange":"color: red")}));var Yt={warnings:v,longStackTraces:!1,cancellation:!1,monitoring:!1,asyncHooks:!1};return y&&e.longStackTraces(),{asyncHooks:function(){return Yt.asyncHooks},longStackTraces:function(){return Yt.longStackTraces},warnings:function(){return Yt.warnings},cancellation:function(){return Yt.cancellation},monitoring:function(){return Yt.monitoring},propagateFromFunction:function(){return at},boundValueFunction:function(){return G},checkForgottenReturns:T,setBounds:Xg,warn:j,deprecated:K,CapturedTrace:ps,fireDomEvent:D,fireGlobalEvent:I}}});var tR=E((Hft,EU)=>{"use strict";EU.exports=function(e){var t=Vt(),r=ga().keys,n=t.tryCatch,i=t.errorObj;function o(s,a,c){return function(u){var l=c._boundValue();e:for(var d=0;d<s.length;++d){var h=s[d];if(h===Error||h!=null&&h.prototype instanceof Error){if(u instanceof h)return n(a).call(l,u)}else if(typeof h=="function"){var f=n(h).call(l,u);if(f===i)return f;if(f)return n(a).call(l,u)}else if(t.isObject(u)){for(var p=r(h),m=0;m<p.length;++m){var _=p[m];if(h[_]!=u[_])continue e}return n(a).call(l,u)}}return e}}return o}});var SU=E(($ft,wU)=>{"use strict";wU.exports=function(e,t,r){var n=Vt(),i=e.CancellationError,o=n.errorObj,s=tR()(r);function a(f,p,m){this.promise=f,this.type=p,this.handler=m,this.called=!1,this.cancelPromise=null}a.prototype.isFinallyHandler=function(){return this.type===0};function c(f){this.finallyHandler=f}c.prototype._resultCancelled=function(){u(this.finallyHandler)};function u(f,p){return f.cancelPromise!=null?(arguments.length>1?f.cancelPromise._reject(p):f.cancelPromise._cancel(),f.cancelPromise=null,!0):!1}function l(){return h.call(this,this.promise._target()._settledValue())}function d(f){if(!u(this,f))return o.e=f,o}function h(f){var p=this.promise,m=this.handler;if(!this.called){this.called=!0;var _=this.isFinallyHandler()?m.call(p._boundValue()):m.call(p._boundValue(),f);if(_===r)return _;if(_!==void 0){p._setReturnedNonUndefined();var w=t(_,p);if(w instanceof e){if(this.cancelPromise!=null)if(w._isCancelled()){var R=new i("late cancellation observer");return p._attachExtraTrace(R),o.e=R,o}else w.isPending()&&w._attachCancellationCallback(new c(this));return w._then(l,d,void 0,this,void 0)}}}return p.isRejected()?(u(this),o.e=f,o):(u(this),f)}return e.prototype._passThrough=function(f,p,m,_){return typeof f!="function"?this.then():this._then(m,_,void 0,new a(this,p,f),void 0)},e.prototype.lastly=e.prototype.finally=function(f){return this._passThrough(f,0,h,h)},e.prototype.tap=function(f){return this._passThrough(f,1,h)},e.prototype.tapCatch=function(f){var p=arguments.length;if(p===1)return this._passThrough(f,1,void 0,h);var m=new Array(p-1),_=0,w;for(w=0;w<p-1;++w){var R=arguments[w];if(n.isObject(R))m[_++]=R;else return e.reject(new TypeError("tapCatch statement predicate: expecting an object but got "+n.classString(R)))}m.length=_;var v=arguments[w];return this._passThrough(s(m,v,this),1,void 0,h)},a}});var rR=E((Gft,xU)=>{"use strict";var vU=Vt(),twe=vU.maybeWrapAsError,rwe=vs(),nwe=rwe.OperationalError,CU=ga();function iwe(e){return e instanceof Error&&CU.getPrototypeOf(e)===Error.prototype}var owe=/^(?:name|message|stack|cause)$/;function swe(e){var t;if(iwe(e)){t=new nwe(e),t.name=e.name,t.message=e.message,t.stack=e.stack;for(var r=CU.keys(e),n=0;n<r.length;++n){var i=r[n];owe.test(i)||(t[i]=e[i])}return t}return vU.markAsOriginatingFromRejection(e),e}function awe(e,t){return function(r,n){if(e!==null){if(r){var i=swe(twe(r));e._attachExtraTrace(i),e._reject(i)}else if(!t)e._fulfill(n);else{for(var o=arguments.length,s=new Array(Math.max(o-1,0)),a=1;a<o;++a)s[a-1]=arguments[a];e._fulfill(s)}e=null}}}xU.exports=awe});var AU=E((zft,TU)=>{"use strict";TU.exports=function(e,t,r,n,i){var o=Vt(),s=o.tryCatch;e.method=function(a){if(typeof a!="function")throw new e.TypeError("expecting a function but got "+o.classString(a));return function(){var c=new e(t);c._captureStackTrace(),c._pushContext();var u=s(a).apply(this,arguments),l=c._popContext();return i.checkForgottenReturns(u,l,"Promise.method",c),c._resolveFromSyncValue(u),c}},e.attempt=e.try=function(a){if(typeof a!="function")return n("expecting a function but got "+o.classString(a));var c=new e(t);c._captureStackTrace(),c._pushContext();var u;if(arguments.length>1){i.deprecated("calling Promise.try with more than 1 argument");var l=arguments[1],d=arguments[2];u=o.isArray(l)?s(a).apply(d,l):s(a).call(d,l)}else u=s(a)();var h=c._popContext();return i.checkForgottenReturns(u,h,"Promise.try",c),c._resolveFromSyncValue(u),c},e.prototype._resolveFromSyncValue=function(a){a===o.errorObj?this._rejectCallback(a.e,!1):this._resolveCallback(a,!0)}}});var PU=E((Vft,RU)=>{"use strict";RU.exports=function(e,t,r,n){var i=!1,o=function(u,l){this._reject(l)},s=function(u,l){l.promiseRejectionQueued=!0,l.bindingPromise._then(o,o,null,this,u)},a=function(u,l){(this._bitField&50397184)===0&&this._resolveCallback(l.target)},c=function(u,l){l.promiseRejectionQueued||this._reject(u)};e.prototype.bind=function(u){i||(i=!0,e.prototype._propagateFrom=n.propagateFromFunction(),e.prototype._boundValue=n.boundValueFunction());var l=r(u),d=new e(t);d._propagateFrom(this,1);var h=this._target();if(d._setBoundTo(l),l instanceof e){var f={promiseRejectionQueued:!1,promise:d,target:h,bindingPromise:l};h._then(t,s,void 0,d,f),l._then(a,c,void 0,d,f),d._setOnCancel(l)}else d._resolveCallback(h);return d},e.prototype._setBoundTo=function(u){u!==void 0?(this._bitField=this._bitField|2097152,this._boundTo=u):this._bitField=this._bitField&-2097153},e.prototype._isBound=function(){return(this._bitField&2097152)===2097152},e.bind=function(u,l){return e.resolve(l).bind(u)}}});var IU=E((Wft,OU)=>{"use strict";OU.exports=function(e,t,r,n){var i=Vt(),o=i.tryCatch,s=i.errorObj,a=e._async;e.prototype.break=e.prototype.cancel=function(){if(!n.cancellation())return this._warn("cancellation is disabled");for(var c=this,u=c;c._isCancellable();){if(!c._cancelBy(u)){u._isFollowing()?u._followee().cancel():u._cancelBranched();break}var l=c._cancellationParent;if(l==null||!l._isCancellable()){c._isFollowing()?c._followee().cancel():c._cancelBranched();break}else c._isFollowing()&&c._followee().cancel(),c._setWillBeCancelled(),u=c,c=l}},e.prototype._branchHasCancelled=function(){this._branchesRemainingToCancel--},e.prototype._enoughBranchesHaveCancelled=function(){return this._branchesRemainingToCancel===void 0||this._branchesRemainingToCancel<=0},e.prototype._cancelBy=function(c){return c===this?(this._branchesRemainingToCancel=0,this._invokeOnCancel(),!0):(this._branchHasCancelled(),this._enoughBranchesHaveCancelled()?(this._invokeOnCancel(),!0):!1)},e.prototype._cancelBranched=function(){this._enoughBranchesHaveCancelled()&&this._cancel()},e.prototype._cancel=function(){this._isCancellable()&&(this._setCancelled(),a.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(c,u){if(i.isArray(c))for(var l=0;l<c.length;++l)this._doInvokeOnCancel(c[l],u);else if(c!==void 0)if(typeof c=="function"){if(!u){var d=o(c).call(this._boundValue());d===s&&(this._attachExtraTrace(d.e),a.throwLater(d.e))}}else c._resultCancelled(this)},e.prototype._invokeOnCancel=function(){var c=this._onCancel();this._unsetOnCancel(),a.invoke(this._doInvokeOnCancel,this,c)},e.prototype._invokeInternalOnCancel=function(){this._isCancellable()&&(this._doInvokeOnCancel(this._onCancel(),!0),this._unsetOnCancel())},e.prototype._resultCancelled=function(){this.cancel()}}});var kU=E((Kft,DU)=>{"use strict";DU.exports=function(e){function t(){return this.value}function r(){throw this.reason}e.prototype.return=e.prototype.thenReturn=function(n){return n instanceof e&&n.suppressUnhandledRejections(),this._then(t,void 0,void 0,{value:n},void 0)},e.prototype.throw=e.prototype.thenThrow=function(n){return this._then(r,void 0,void 0,{reason:n},void 0)},e.prototype.catchThrow=function(n){if(arguments.length<=1)return this._then(void 0,r,void 0,{reason:n},void 0);var i=arguments[1],o=function(){throw i};return this.caught(n,o)},e.prototype.catchReturn=function(n){if(arguments.length<=1)return n instanceof e&&n.suppressUnhandledRejections(),this._then(void 0,t,void 0,{value:n},void 0);var i=arguments[1];i instanceof e&&i.suppressUnhandledRejections();var o=function(){return i};return this.caught(n,o)}}});var MU=E((Yft,NU)=>{"use strict";NU.exports=function(e){function t(c){c!==void 0?(c=c._target(),this._bitField=c._bitField,this._settledValueField=c._isFateSealed()?c._settledValue():void 0):(this._bitField=0,this._settledValueField=void 0)}t.prototype._settledValue=function(){return this._settledValueField};var r=t.prototype.value=function(){if(!this.isFulfilled())throw new TypeError(`cannot get fulfillment value of a non-fulfilled promise
|
|
43
|
+
|
|
44
|
+
See http://goo.gl/MqrFmX
|
|
45
|
+
`);return this._settledValue()},n=t.prototype.error=t.prototype.reason=function(){if(!this.isRejected())throw new TypeError(`cannot get rejection reason of a non-rejected promise
|
|
46
|
+
|
|
47
|
+
See http://goo.gl/MqrFmX
|
|
48
|
+
`);return this._settledValue()},i=t.prototype.isFulfilled=function(){return(this._bitField&33554432)!==0},o=t.prototype.isRejected=function(){return(this._bitField&16777216)!==0},s=t.prototype.isPending=function(){return(this._bitField&50397184)===0},a=t.prototype.isResolved=function(){return(this._bitField&50331648)!==0};t.prototype.isCancelled=function(){return(this._bitField&8454144)!==0},e.prototype.__isCancelled=function(){return(this._bitField&65536)===65536},e.prototype._isCancelled=function(){return this._target().__isCancelled()},e.prototype.isCancelled=function(){return(this._target()._bitField&8454144)!==0},e.prototype.isPending=function(){return s.call(this._target())},e.prototype.isRejected=function(){return o.call(this._target())},e.prototype.isFulfilled=function(){return i.call(this._target())},e.prototype.isResolved=function(){return a.call(this._target())},e.prototype.value=function(){return r.call(this._target())},e.prototype.reason=function(){var c=this._target();return c._unsetRejectionIsUnhandled(),n.call(c)},e.prototype._value=function(){return this._settledValue()},e.prototype._reason=function(){return this._unsetRejectionIsUnhandled(),this._settledValue()},e.PromiseInspection=t}});var BU=E((Xft,LU)=>{"use strict";LU.exports=function(e,t,r,n,i){var o=Vt(),s=o.canEvaluate,a=o.tryCatch,c=o.errorObj,u;if(s){for(var l=function(w){return new Function("value","holder",`
|
|
49
|
+
'use strict';
|
|
50
|
+
holder.pIndex = value;
|
|
51
|
+
holder.checkFulfillment(this);
|
|
52
|
+
`.replace(/Index/g,w))},d=function(w){return new Function("promise","holder",`
|
|
53
|
+
'use strict';
|
|
54
|
+
holder.pIndex = promise;
|
|
55
|
+
`.replace(/Index/g,w))},h=function(w){for(var R=new Array(w),v=0;v<R.length;++v)R[v]="this.p"+(v+1);var y=R.join(" = ")+" = null;",S=`var promise;
|
|
56
|
+
`+R.map(function(D){return`
|
|
57
|
+
promise = `+D+`;
|
|
58
|
+
if (promise instanceof Promise) {
|
|
59
|
+
promise.cancel();
|
|
60
|
+
}
|
|
61
|
+
`}).join(`
|
|
62
|
+
`),O=R.join(", "),M="Holder$"+w,A=`return function(tryCatch, errorObj, Promise, async) {
|
|
63
|
+
'use strict';
|
|
64
|
+
function [TheName](fn) {
|
|
65
|
+
[TheProperties]
|
|
66
|
+
this.fn = fn;
|
|
67
|
+
this.asyncNeeded = true;
|
|
68
|
+
this.now = 0;
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
[TheName].prototype._callFunction = function(promise) {
|
|
72
|
+
promise._pushContext();
|
|
73
|
+
var ret = tryCatch(this.fn)([ThePassedArguments]);
|
|
74
|
+
promise._popContext();
|
|
75
|
+
if (ret === errorObj) {
|
|
76
|
+
promise._rejectCallback(ret.e, false);
|
|
77
|
+
} else {
|
|
78
|
+
promise._resolveCallback(ret);
|
|
79
|
+
}
|
|
80
|
+
};
|
|
81
|
+
|
|
82
|
+
[TheName].prototype.checkFulfillment = function(promise) {
|
|
83
|
+
var now = ++this.now;
|
|
84
|
+
if (now === [TheTotal]) {
|
|
85
|
+
if (this.asyncNeeded) {
|
|
86
|
+
async.invoke(this._callFunction, this, promise);
|
|
87
|
+
} else {
|
|
88
|
+
this._callFunction(promise);
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
}
|
|
92
|
+
};
|
|
93
|
+
|
|
94
|
+
[TheName].prototype._resultCancelled = function() {
|
|
95
|
+
[CancellationCode]
|
|
96
|
+
};
|
|
97
|
+
|
|
98
|
+
return [TheName];
|
|
99
|
+
}(tryCatch, errorObj, Promise, async);
|
|
100
|
+
`;return A=A.replace(/\[TheName\]/g,M).replace(/\[TheTotal\]/g,w).replace(/\[ThePassedArguments\]/g,O).replace(/\[TheProperties\]/g,y).replace(/\[CancellationCode\]/g,S),new Function("tryCatch","errorObj","Promise","async",A)(a,c,e,i)},f=[],p=[],m=[],_=0;_<8;++_)f.push(h(_+1)),p.push(l(_+1)),m.push(d(_+1));u=function(w){this._reject(w)}}e.join=function(){var w=arguments.length-1,R;if(w>0&&typeof arguments[w]=="function"&&(R=arguments[w],w<=8&&s)){var U=new e(n);U._captureStackTrace();for(var v=f[w-1],y=new v(R),S=p,O=0;O<w;++O){var M=r(arguments[O],U);if(M instanceof e){M=M._target();var A=M._bitField;(A&50397184)===0?(M._then(S[O],u,void 0,U,y),m[O](M,y),y.asyncNeeded=!1):(A&33554432)!==0?S[O].call(U,M._value(),y):(A&16777216)!==0?U._reject(M._reason()):U._cancel()}else S[O].call(U,M,y)}if(!U._isFateSealed()){if(y.asyncNeeded){var D=e._getContext();y.fn=o.contextBind(D,y.fn)}U._setAsyncGuaranteed(),U._setOnCancel(y)}return U}for(var I=arguments.length,N=new Array(I),J=0;J<I;++J)N[J]=arguments[J];R&&N.pop();var U=new t(N).promise();return R!==void 0?U.spread(R):U}}});var qU=E((Jft,FU)=>{"use strict";var nR=Object.create;nR&&(iR=nR(null),oR=nR(null),iR[" size"]=oR[" size"]=0);var iR,oR;FU.exports=function(e){var t=Vt(),r=t.canEvaluate,n=t.isIdentifier,i,o,s=function(f){return new Function("ensureMethod",`
|
|
101
|
+
return function(obj) {
|
|
102
|
+
'use strict'
|
|
103
|
+
var len = this.length;
|
|
104
|
+
ensureMethod(obj, 'methodName');
|
|
105
|
+
switch(len) {
|
|
106
|
+
case 1: return obj.methodName(this[0]);
|
|
107
|
+
case 2: return obj.methodName(this[0], this[1]);
|
|
108
|
+
case 3: return obj.methodName(this[0], this[1], this[2]);
|
|
109
|
+
case 0: return obj.methodName();
|
|
110
|
+
default:
|
|
111
|
+
return obj.methodName.apply(obj, this);
|
|
112
|
+
}
|
|
113
|
+
};
|
|
114
|
+
`.replace(/methodName/g,f))(u)},a=function(f){return new Function("obj",`
|
|
115
|
+
'use strict';
|
|
116
|
+
return obj.propertyName;
|
|
117
|
+
`.replace("propertyName",f))},c=function(f,p,m){var _=m[f];if(typeof _!="function"){if(!n(f))return null;if(_=p(f),m[f]=_,m[" size"]++,m[" size"]>512){for(var w=Object.keys(m),R=0;R<256;++R)delete m[w[R]];m[" size"]=w.length-256}}return _};i=function(f){return c(f,s,iR)},o=function(f){return c(f,a,oR)};function u(f,p){var m;if(f!=null&&(m=f[p]),typeof m!="function"){var _="Object "+t.classString(f)+" has no method '"+t.toString(p)+"'";throw new e.TypeError(_)}return m}function l(f){var p=this.pop(),m=u(f,p);return m.apply(f,this)}e.prototype.call=function(f){for(var p=arguments.length,m=new Array(Math.max(p-1,0)),_=1;_<p;++_)m[_-1]=arguments[_];if(r){var w=i(f);if(w!==null)return this._then(w,void 0,void 0,m,void 0)}return m.push(f),this._then(l,void 0,void 0,m,void 0)};function d(f){return f[this]}function h(f){var p=+this;return p<0&&(p=Math.max(0,p+f.length)),f[p]}e.prototype.get=function(f){var p=typeof f=="number",m;if(p)m=h;else if(r){var _=o(f);m=_!==null?_:d}else m=d;return this._then(m,void 0,void 0,f,void 0)}}});var UU=E((Qft,jU)=>{"use strict";jU.exports=function(e,t,r,n,i,o){var s=vs(),a=s.TypeError,c=Vt(),u=c.errorObj,l=c.tryCatch,d=[];function h(p,m,_){for(var w=0;w<m.length;++w){_._pushContext();var R=l(m[w])(p);if(_._popContext(),R===u){_._pushContext();var v=e.reject(u.e);return _._popContext(),v}var y=n(R,_);if(y instanceof e)return y}return null}function f(p,m,_,w){if(o.cancellation()){var R=new e(r),v=this._finallyPromise=new e(r);this._promise=R.lastly(function(){return v}),R._captureStackTrace(),R._setOnCancel(this)}else{var y=this._promise=new e(r);y._captureStackTrace()}this._stack=w,this._generatorFunction=p,this._receiver=m,this._generator=void 0,this._yieldHandlers=typeof _=="function"?[_].concat(d):d,this._yieldedPromise=null,this._cancellationPhase=!1}c.inherits(f,i),f.prototype._isResolved=function(){return this._promise===null},f.prototype._cleanup=function(){this._promise=this._generator=null,o.cancellation()&&this._finallyPromise!==null&&(this._finallyPromise._fulfill(),this._finallyPromise=null)},f.prototype._promiseCancelled=function(){if(!this._isResolved()){var p=typeof this._generator.return<"u",m;if(p)this._promise._pushContext(),m=l(this._generator.return).call(this._generator,void 0),this._promise._popContext();else{var _=new e.CancellationError("generator .return() sentinel");e.coroutine.returnSentinel=_,this._promise._attachExtraTrace(_),this._promise._pushContext(),m=l(this._generator.throw).call(this._generator,_),this._promise._popContext()}this._cancellationPhase=!0,this._yieldedPromise=null,this._continue(m)}},f.prototype._promiseFulfilled=function(p){this._yieldedPromise=null,this._promise._pushContext();var m=l(this._generator.next).call(this._generator,p);this._promise._popContext(),this._continue(m)},f.prototype._promiseRejected=function(p){this._yieldedPromise=null,this._promise._attachExtraTrace(p),this._promise._pushContext();var m=l(this._generator.throw).call(this._generator,p);this._promise._popContext(),this._continue(m)},f.prototype._resultCancelled=function(){if(this._yieldedPromise instanceof e){var p=this._yieldedPromise;this._yieldedPromise=null,p.cancel()}},f.prototype.promise=function(){return this._promise},f.prototype._run=function(){this._generator=this._generatorFunction.call(this._receiver),this._receiver=this._generatorFunction=void 0,this._promiseFulfilled(void 0)},f.prototype._continue=function(p){var m=this._promise;if(p===u)return this._cleanup(),this._cancellationPhase?m.cancel():m._rejectCallback(p.e,!1);var _=p.value;if(p.done===!0)return this._cleanup(),this._cancellationPhase?m.cancel():m._resolveCallback(_);var w=n(_,this._promise);if(!(w instanceof e)&&(w=h(w,this._yieldHandlers,this._promise),w===null)){this._promiseRejected(new a(`A value %s was yielded that could not be treated as a promise
|
|
118
|
+
|
|
119
|
+
See http://goo.gl/MqrFmX
|
|
120
|
+
|
|
121
|
+
`.replace("%s",String(_))+`From coroutine:
|
|
122
|
+
`+this._stack.split(`
|
|
123
|
+
`).slice(1,-7).join(`
|
|
124
|
+
`)));return}w=w._target();var R=w._bitField;(R&50397184)===0?(this._yieldedPromise=w,w._proxy(this,null)):(R&33554432)!==0?e._async.invoke(this._promiseFulfilled,this,w._value()):(R&16777216)!==0?e._async.invoke(this._promiseRejected,this,w._reason()):this._promiseCancelled()},e.coroutine=function(p,m){if(typeof p!="function")throw new a(`generatorFunction must be a function
|
|
125
|
+
|
|
126
|
+
See http://goo.gl/MqrFmX
|
|
127
|
+
`);var _=Object(m).yieldHandler,w=f,R=new Error().stack;return function(){var v=p.apply(this,arguments),y=new w(void 0,void 0,_,R),S=y.promise();return y._generator=v,y._promiseFulfilled(void 0),S}},e.coroutine.addYieldHandler=function(p){if(typeof p!="function")throw new a("expecting a function but got "+c.classString(p));d.push(p)},e.spawn=function(p){if(o.deprecated("Promise.spawn()","Promise.coroutine()"),typeof p!="function")return t(`generatorFunction must be a function
|
|
128
|
+
|
|
129
|
+
See http://goo.gl/MqrFmX
|
|
130
|
+
`);var m=new f(p,this),_=m.promise();return m._run(e.spawn),_}}});var $U=E((Zft,HU)=>{"use strict";HU.exports=function(e,t,r,n,i,o){var s=Vt(),a=s.tryCatch,c=s.errorObj,u=e._async;function l(h,f,p,m){this.constructor$(h),this._promise._captureStackTrace();var _=e._getContext();if(this._callback=s.contextBind(_,f),this._preservedValues=m===i?new Array(this.length()):null,this._limit=p,this._inFlight=0,this._queue=[],u.invoke(this._asyncInit,this,void 0),s.isArray(h))for(var w=0;w<h.length;++w){var R=h[w];R instanceof e&&R.suppressUnhandledRejections()}}s.inherits(l,t),l.prototype._asyncInit=function(){this._init$(void 0,-2)},l.prototype._init=function(){},l.prototype._promiseFulfilled=function(h,f){var p=this._values,m=this.length(),_=this._preservedValues,w=this._limit;if(f<0){if(f=f*-1-1,p[f]=h,w>=1&&(this._inFlight--,this._drainQueue(),this._isResolved()))return!0}else{if(w>=1&&this._inFlight>=w)return p[f]=h,this._queue.push(f),!1;_!==null&&(_[f]=h);var R=this._promise,v=this._callback,y=R._boundValue();R._pushContext();var S=a(v).call(y,h,f,m),O=R._popContext();if(o.checkForgottenReturns(S,O,_!==null?"Promise.filter":"Promise.map",R),S===c)return this._reject(S.e),!0;var M=n(S,this._promise);if(M instanceof e){M=M._target();var A=M._bitField;if((A&50397184)===0)return w>=1&&this._inFlight++,p[f]=M,M._proxy(this,(f+1)*-1),!1;if((A&33554432)!==0)S=M._value();else return(A&16777216)!==0?(this._reject(M._reason()),!0):(this._cancel(),!0)}p[f]=S}var D=++this._totalResolved;return D>=m?(_!==null?this._filter(p,_):this._resolve(p),!0):!1},l.prototype._drainQueue=function(){for(var h=this._queue,f=this._limit,p=this._values;h.length>0&&this._inFlight<f;){if(this._isResolved())return;var m=h.pop();this._promiseFulfilled(p[m],m)}},l.prototype._filter=function(h,f){for(var p=f.length,m=new Array(p),_=0,w=0;w<p;++w)h[w]&&(m[_++]=f[w]);m.length=_,this._resolve(m)},l.prototype.preservedValues=function(){return this._preservedValues};function d(h,f,p,m){if(typeof f!="function")return r("expecting a function but got "+s.classString(f));var _=0;if(p!==void 0)if(typeof p=="object"&&p!==null){if(typeof p.concurrency!="number")return e.reject(new TypeError("'concurrency' must be a number but it is "+s.classString(p.concurrency)));_=p.concurrency}else return e.reject(new TypeError("options argument must be an object but it is "+s.classString(p)));return _=typeof _=="number"&&isFinite(_)&&_>=1?_:0,new l(h,f,_,m).promise()}e.prototype.map=function(h,f){return d(this,h,f,null)},e.map=function(h,f,p,m){return d(h,f,p,m)}}});var zU=E((edt,GU)=>{"use strict";GU.exports=function(e){var t=Vt(),r=e._async,n=t.tryCatch,i=t.errorObj;function o(c,u){var l=this;if(!t.isArray(c))return s.call(l,c,u);var d=n(u).apply(l._boundValue(),[null].concat(c));d===i&&r.throwLater(d.e)}function s(c,u){var l=this,d=l._boundValue(),h=c===void 0?n(u).call(d,null):n(u).call(d,null,c);h===i&&r.throwLater(h.e)}function a(c,u){var l=this;if(!c){var d=new Error(c+"");d.cause=c,c=d}var h=n(u).call(l._boundValue(),c);h===i&&r.throwLater(h.e)}e.prototype.asCallback=e.prototype.nodeify=function(c,u){if(typeof c=="function"){var l=s;u!==void 0&&Object(u).spread&&(l=o),this._then(l,a,void 0,this,c)}return this}}});var WU=E((tdt,VU)=>{"use strict";VU.exports=function(e,t){var r={},n=Vt(),i=rR(),o=n.withAppended,s=n.maybeWrapAsError,a=n.canEvaluate,c=vs().TypeError,u="Async",l={__isPromisified__:!0},d=["arity","length","name","arguments","caller","callee","prototype","__isPromisified__"],h=new RegExp("^(?:"+d.join("|")+")$"),f=function(U){return n.isIdentifier(U)&&U.charAt(0)!=="_"&&U!=="constructor"};function p(U){return!h.test(U)}function m(U){try{return U.__isPromisified__===!0}catch{return!1}}function _(U,ie,be){var B=n.getDataPropertyOrDefault(U,ie+be,l);return B?m(B):!1}function w(U,ie,be){for(var B=0;B<U.length;B+=2){var te=U[B];if(be.test(te)){for(var ge=te.replace(be,""),$=0;$<U.length;$+=2)if(U[$]===ge)throw new c(`Cannot promisify an API that has normal methods with '%s'-suffix
|
|
131
|
+
|
|
132
|
+
See http://goo.gl/MqrFmX
|
|
133
|
+
`.replace("%s",ie))}}}function R(U,ie,be,B){for(var te=n.inheritedDataKeys(U),ge=[],$=0;$<te.length;++$){var ve=te[$],Ze=U[ve],at=B===f?!0:f(ve,Ze,U);typeof Ze=="function"&&!m(Ze)&&!_(U,ve,ie)&&B(ve,Ze,U,at)&&ge.push(ve,Ze)}return w(ge,ie,be),ge}var v=function(U){return U.replace(/([$])/,"\\$")},y,S=function(U){for(var ie=[U],be=Math.max(0,U-1-3),B=U-1;B>=be;--B)ie.push(B);for(var B=U+1;B<=3;++B)ie.push(B);return ie},O=function(U){return n.filledRange(U,"_arg","")},M=function(U){return n.filledRange(Math.max(U,3),"_arg","")},A=function(U){return typeof U.length=="number"?Math.max(Math.min(U.length,1024),0):0};y=function(U,ie,be,B,te,ge){var $=Math.max(0,A(B)-1),ve=S($),Ze=typeof U=="string"||ie===r;function at(P){var T=O(P).join(", "),K=P>0?", ":"",j;return Ze?j=`ret = callback.call(this, {{args}}, nodeback); break;
|
|
134
|
+
`:j=ie===void 0?`ret = callback({{args}}, nodeback); break;
|
|
135
|
+
`:`ret = callback.call(receiver, {{args}}, nodeback); break;
|
|
136
|
+
`,j.replace("{{args}}",T).replace(", ",K)}function G(){for(var P="",T=0;T<ve.length;++T)P+="case "+ve[T]+":"+at(ve[T]);return P+=`
|
|
137
|
+
default:
|
|
138
|
+
var args = new Array(len + 1);
|
|
139
|
+
var i = 0;
|
|
140
|
+
for (var i = 0; i < len; ++i) {
|
|
141
|
+
args[i] = arguments[i];
|
|
142
|
+
}
|
|
143
|
+
args[i] = nodeback;
|
|
144
|
+
[CodeForCall]
|
|
145
|
+
break;
|
|
146
|
+
`.replace("[CodeForCall]",Ze?`ret = callback.apply(this, args);
|
|
147
|
+
`:`ret = callback.apply(receiver, args);
|
|
148
|
+
`),P}var ce=typeof U=="string"?"this != null ? this['"+U+"'] : fn":"fn",Se=`'use strict';
|
|
149
|
+
var ret = function (Parameters) {
|
|
150
|
+
'use strict';
|
|
151
|
+
var len = arguments.length;
|
|
152
|
+
var promise = new Promise(INTERNAL);
|
|
153
|
+
promise._captureStackTrace();
|
|
154
|
+
var nodeback = nodebackForPromise(promise, `+ge+`);
|
|
155
|
+
var ret;
|
|
156
|
+
var callback = tryCatch([GetFunctionCode]);
|
|
157
|
+
switch(len) {
|
|
158
|
+
[CodeForSwitchCase]
|
|
159
|
+
}
|
|
160
|
+
if (ret === errorObj) {
|
|
161
|
+
promise._rejectCallback(maybeWrapAsError(ret.e), true, true);
|
|
162
|
+
}
|
|
163
|
+
if (!promise._isFateSealed()) promise._setAsyncGuaranteed();
|
|
164
|
+
return promise;
|
|
165
|
+
};
|
|
166
|
+
notEnumerableProp(ret, '__isPromisified__', true);
|
|
167
|
+
return ret;
|
|
168
|
+
`.replace("[CodeForSwitchCase]",G()).replace("[GetFunctionCode]",ce);return Se=Se.replace("Parameters",M($)),new Function("Promise","fn","receiver","withAppended","maybeWrapAsError","nodebackForPromise","tryCatch","errorObj","notEnumerableProp","INTERNAL",Se)(e,B,ie,o,s,i,n.tryCatch,n.errorObj,n.notEnumerableProp,t)};function D(U,ie,be,B,te,ge){var $=(function(){return this})(),ve=U;typeof ve=="string"&&(U=B);function Ze(){var at=ie;ie===r&&(at=this);var G=new e(t);G._captureStackTrace();var ce=typeof ve=="string"&&this!==$?this[ve]:U,Se=i(G,ge);try{ce.apply(at,o(arguments,Se))}catch(P){G._rejectCallback(s(P),!0,!0)}return G._isFateSealed()||G._setAsyncGuaranteed(),G}return n.notEnumerableProp(Ze,"__isPromisified__",!0),Ze}var I=a?y:D;function N(U,ie,be,B,te){for(var ge=new RegExp(v(ie)+"$"),$=R(U,ie,ge,be),ve=0,Ze=$.length;ve<Ze;ve+=2){var at=$[ve],G=$[ve+1],ce=at+ie;if(B===I)U[ce]=I(at,r,at,G,ie,te);else{var Se=B(G,function(){return I(at,r,at,G,ie,te)});n.notEnumerableProp(Se,"__isPromisified__",!0),U[ce]=Se}}return n.toFastProperties(U),U}function J(U,ie,be){return I(U,ie,void 0,U,null,be)}e.promisify=function(U,ie){if(typeof U!="function")throw new c("expecting a function but got "+n.classString(U));if(m(U))return U;ie=Object(ie);var be=ie.context===void 0?r:ie.context,B=!!ie.multiArgs,te=J(U,be,B);return n.copyDescriptors(U,te,p),te},e.promisifyAll=function(U,ie){if(typeof U!="function"&&typeof U!="object")throw new c(`the target of promisifyAll must be an object or a function
|
|
169
|
+
|
|
170
|
+
See http://goo.gl/MqrFmX
|
|
171
|
+
`);ie=Object(ie);var be=!!ie.multiArgs,B=ie.suffix;typeof B!="string"&&(B=u);var te=ie.filter;typeof te!="function"&&(te=f);var ge=ie.promisifier;if(typeof ge!="function"&&(ge=I),!n.isIdentifier(B))throw new RangeError(`suffix must be a valid identifier
|
|
172
|
+
|
|
173
|
+
See http://goo.gl/MqrFmX
|
|
174
|
+
`);for(var $=n.inheritedDataKeys(U),ve=0;ve<$.length;++ve){var Ze=U[$[ve]];$[ve]!=="constructor"&&n.isClass(Ze)&&(N(Ze.prototype,B,te,ge,be),N(Ze,B,te,ge,be))}return N(U,B,te,ge,be)}}});var YU=E((rdt,KU)=>{"use strict";KU.exports=function(e,t,r,n){var i=Vt(),o=i.isObject,s=ga(),a;typeof Map=="function"&&(a=Map);var c=(function(){var h=0,f=0;function p(m,_){this[h]=m,this[h+f]=_,h++}return function(_){f=_.size,h=0;var w=new Array(_.size*2);return _.forEach(p,w),w}})(),u=function(h){for(var f=new a,p=h.length/2|0,m=0;m<p;++m){var _=h[p+m],w=h[m];f.set(_,w)}return f};function l(h){var f=!1,p;if(a!==void 0&&h instanceof a)p=c(h),f=!0;else{var m=s.keys(h),_=m.length;p=new Array(_*2);for(var w=0;w<_;++w){var R=m[w];p[w]=h[R],p[w+_]=R}}this.constructor$(p),this._isMap=f,this._init$(void 0,f?-6:-3)}i.inherits(l,t),l.prototype._init=function(){},l.prototype._promiseFulfilled=function(h,f){this._values[f]=h;var p=++this._totalResolved;if(p>=this._length){var m;if(this._isMap)m=u(this._values);else{m={};for(var _=this.length(),w=0,R=this.length();w<R;++w)m[this._values[w+_]]=this._values[w]}return this._resolve(m),!0}return!1},l.prototype.shouldCopyValues=function(){return!1},l.prototype.getActualLength=function(h){return h>>1};function d(h){var f,p=r(h);if(o(p))p instanceof e?f=p._then(e.props,void 0,void 0,void 0,void 0):f=new l(p).promise();else return n(`cannot await properties of a non-object
|
|
175
|
+
|
|
176
|
+
See http://goo.gl/MqrFmX
|
|
177
|
+
`);return p instanceof e&&f._propagateFrom(p,2),f}e.prototype.props=function(){return d(this)},e.props=function(h){return d(h)}}});var JU=E((ndt,XU)=>{"use strict";XU.exports=function(e,t,r,n){var i=Vt(),o=function(a){return a.then(function(c){return s(c,a)})};function s(a,c){var u=r(a);if(u instanceof e)return o(u);if(a=i.asArray(a),a===null)return n("expecting an array or an iterable object but got "+i.classString(a));var l=new e(t);c!==void 0&&l._propagateFrom(c,3);for(var d=l._fulfill,h=l._reject,f=0,p=a.length;f<p;++f){var m=a[f];m===void 0&&!(f in a)||e.cast(m)._then(d,h,void 0,l,null)}return l}e.race=function(a){return s(a,void 0)},e.prototype.race=function(){return s(this,void 0)}}});var ZU=E((idt,QU)=>{"use strict";QU.exports=function(e,t,r,n,i,o){var s=Vt(),a=s.tryCatch;function c(f,p,m,_){this.constructor$(f);var w=e._getContext();this._fn=s.contextBind(w,p),m!==void 0&&(m=e.resolve(m),m._attachCancellationCallback(this)),this._initialValue=m,this._currentCancellable=null,_===i?this._eachValues=Array(this._length):_===0?this._eachValues=null:this._eachValues=void 0,this._promise._captureStackTrace(),this._init$(void 0,-5)}s.inherits(c,t),c.prototype._gotAccum=function(f){this._eachValues!==void 0&&this._eachValues!==null&&f!==i&&this._eachValues.push(f)},c.prototype._eachComplete=function(f){return this._eachValues!==null&&this._eachValues.push(f),this._eachValues},c.prototype._init=function(){},c.prototype._resolveEmptyArray=function(){this._resolve(this._eachValues!==void 0?this._eachValues:this._initialValue)},c.prototype.shouldCopyValues=function(){return!1},c.prototype._resolve=function(f){this._promise._resolveCallback(f),this._values=null},c.prototype._resultCancelled=function(f){if(f===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(f){this._values=f;var p,m,_=f.length;this._initialValue!==void 0?(p=this._initialValue,m=0):(p=e.resolve(f[0]),m=1),this._currentCancellable=p;for(var w=m;w<_;++w){var R=f[w];R instanceof e&&R.suppressUnhandledRejections()}if(!p.isRejected())for(;m<_;++m){var v={accum:null,value:f[m],index:m,length:_,array:this};p=p._then(d,void 0,void 0,v,void 0),(m&127)===0&&p._setNoAsyncGuarantee()}this._eachValues!==void 0&&(p=p._then(this._eachComplete,void 0,void 0,this,void 0)),p._then(u,u,void 0,p,this)},e.prototype.reduce=function(f,p){return l(this,f,p,null)},e.reduce=function(f,p,m,_){return l(f,p,m,_)};function u(f,p){this.isFulfilled()?p._resolve(f):p._reject(f)}function l(f,p,m,_){if(typeof p!="function")return r("expecting a function but got "+s.classString(p));var w=new c(f,p,m,_);return w.promise()}function d(f){this.accum=f,this.array._gotAccum(f);var p=n(this.value,this.array._promise);return p instanceof e?(this.array._currentCancellable=p,p._then(h,void 0,void 0,this,void 0)):h.call(this,p)}function h(f){var p=this.array,m=p._promise,_=a(p._fn);m._pushContext();var w;p._eachValues!==void 0?w=_.call(m._boundValue(),f,this.index,this.length):w=_.call(m._boundValue(),this.accum,f,this.index,this.length),w instanceof e&&(p._currentCancellable=w);var R=m._popContext();return o.checkForgottenReturns(w,R,p._eachValues!==void 0?"Promise.each":"Promise.reduce",m),w}}});var t4=E((odt,e4)=>{"use strict";e4.exports=function(e,t,r){var n=e.PromiseInspection,i=Vt();function o(s){this.constructor$(s)}i.inherits(o,t),o.prototype._promiseResolved=function(s,a){this._values[s]=a;var c=++this._totalResolved;return c>=this._length?(this._resolve(this._values),!0):!1},o.prototype._promiseFulfilled=function(s,a){var c=new n;return c._bitField=33554432,c._settledValueField=s,this._promiseResolved(a,c)},o.prototype._promiseRejected=function(s,a){var c=new n;return c._bitField=16777216,c._settledValueField=s,this._promiseResolved(a,c)},e.settle=function(s){return r.deprecated(".settle()",".reflect()"),new o(s).promise()},e.allSettled=function(s){return new o(s).promise()},e.prototype.settle=function(){return e.settle(this)}}});var n4=E((sdt,r4)=>{"use strict";r4.exports=function(e,t,r){var n=Vt(),i=vs().RangeError,o=vs().AggregateError,s=n.isArray,a={};function c(l){this.constructor$(l),this._howMany=0,this._unwrap=!1,this._initialized=!1}n.inherits(c,t),c.prototype._init=function(){if(this._initialized){if(this._howMany===0){this._resolve([]);return}this._init$(void 0,-5);var l=s(this._values);!this._isResolved()&&l&&this._howMany>this._canPossiblyFulfill()&&this._reject(this._getRangeError(this.length()))}},c.prototype.init=function(){this._initialized=!0,this._init()},c.prototype.setUnwrap=function(){this._unwrap=!0},c.prototype.howMany=function(){return this._howMany},c.prototype.setHowMany=function(l){this._howMany=l},c.prototype._promiseFulfilled=function(l){return this._addFulfilled(l),this._fulfilled()===this.howMany()?(this._values.length=this.howMany(),this.howMany()===1&&this._unwrap?this._resolve(this._values[0]):this._resolve(this._values),!0):!1},c.prototype._promiseRejected=function(l){return this._addRejected(l),this._checkOutcome()},c.prototype._promiseCancelled=function(){return this._values instanceof e||this._values==null?this._cancel():(this._addRejected(a),this._checkOutcome())},c.prototype._checkOutcome=function(){if(this.howMany()>this._canPossiblyFulfill()){for(var l=new o,d=this.length();d<this._values.length;++d)this._values[d]!==a&&l.push(this._values[d]);return l.length>0?this._reject(l):this._cancel(),!0}return!1},c.prototype._fulfilled=function(){return this._totalResolved},c.prototype._rejected=function(){return this._values.length-this.length()},c.prototype._addRejected=function(l){this._values.push(l)},c.prototype._addFulfilled=function(l){this._values[this._totalResolved++]=l},c.prototype._canPossiblyFulfill=function(){return this.length()-this._rejected()},c.prototype._getRangeError=function(l){var d="Input array must contain at least "+this._howMany+" items but contains only "+l+" items";return new i(d)},c.prototype._resolveEmptyArray=function(){this._reject(this._getRangeError(0))};function u(l,d){if((d|0)!==d||d<0)return r(`expecting a positive integer
|
|
178
|
+
|
|
179
|
+
See http://goo.gl/MqrFmX
|
|
180
|
+
`);var h=new c(l),f=h.promise();return h.setHowMany(d),h.init(),f}e.some=function(l,d){return u(l,d)},e.prototype.some=function(l){return u(this,l)},e._SomePromiseArray=c}});var o4=E((adt,i4)=>{"use strict";i4.exports=function(e,t,r){var n=Vt(),i=e.TimeoutError;function o(d){this.handle=d}o.prototype._resultCancelled=function(){clearTimeout(this.handle)};var s=function(d){return a(+this).thenReturn(d)},a=e.delay=function(d,h){var f,p;return h!==void 0?(f=e.resolve(h)._then(s,null,null,d,void 0),r.cancellation()&&h instanceof e&&f._setOnCancel(h)):(f=new e(t),p=setTimeout(function(){f._fulfill()},+d),r.cancellation()&&f._setOnCancel(new o(p)),f._captureStackTrace()),f._setAsyncGuaranteed(),f};e.prototype.delay=function(d){return a(d,this)};var c=function(d,h,f){var p;typeof h!="string"?h instanceof Error?p=h:p=new i("operation timed out"):p=new i(h),n.markAsOriginatingFromRejection(p),d._attachExtraTrace(p),d._reject(p),f?.cancel()};function u(d){return clearTimeout(this.handle),d}function l(d){throw clearTimeout(this.handle),d}e.prototype.timeout=function(d,h){d=+d;var f,p,m=new o(setTimeout(function(){f.isPending()&&c(f,h,p)},d));return r.cancellation()?(p=this.then(),f=p._then(u,l,void 0,m,void 0),f._setOnCancel(m)):f=this._then(u,l,void 0,m,void 0),f}}});var a4=E((cdt,s4)=>{"use strict";s4.exports=function(e,t,r,n,i,o){var s=Vt(),a=vs().TypeError,c=Vt().inherits,u=s.errorObj,l=s.tryCatch,d={};function h(v){setTimeout(function(){throw v},0)}function f(v){var y=r(v);return y!==v&&typeof v._isDisposable=="function"&&typeof v._getDisposer=="function"&&v._isDisposable()&&y._setDisposable(v._getDisposer()),y}function p(v,y){var S=0,O=v.length,M=new e(i);function A(){if(S>=O)return M._fulfill();var D=f(v[S++]);if(D instanceof e&&D._isDisposable()){try{D=r(D._getDisposer().tryDispose(y),v.promise)}catch(I){return h(I)}if(D instanceof e)return D._then(A,h,null,null,null)}A()}return A(),M}function m(v,y,S){this._data=v,this._promise=y,this._context=S}m.prototype.data=function(){return this._data},m.prototype.promise=function(){return this._promise},m.prototype.resource=function(){return this.promise().isFulfilled()?this.promise().value():d},m.prototype.tryDispose=function(v){var y=this.resource(),S=this._context;S!==void 0&&S._pushContext();var O=y!==d?this.doDispose(y,v):null;return S!==void 0&&S._popContext(),this._promise._unsetDisposable(),this._data=null,O},m.isDisposer=function(v){return v!=null&&typeof v.resource=="function"&&typeof v.tryDispose=="function"};function _(v,y,S){this.constructor$(v,y,S)}c(_,m),_.prototype.doDispose=function(v,y){var S=this.data();return S.call(v,v,y)};function w(v){return m.isDisposer(v)?(this.resources[this.index]._setDisposable(v),v.promise()):v}function R(v){this.length=v,this.promise=null,this[v-1]=null}R.prototype._resultCancelled=function(){for(var v=this.length,y=0;y<v;++y){var S=this[y];S instanceof e&&S.cancel()}},e.using=function(){var v=arguments.length;if(v<2)return t("you must pass at least 2 arguments to Promise.using");var y=arguments[v-1];if(typeof y!="function")return t("expecting a function but got "+s.classString(y));var S,O=!0;v===2&&Array.isArray(arguments[0])?(S=arguments[0],v=S.length,O=!1):(S=arguments,v--);for(var M=new R(v),A=0;A<v;++A){var D=S[A];if(m.isDisposer(D)){var I=D;D=D.promise(),D._setDisposable(I)}else{var N=r(D);N instanceof e&&(D=N._then(w,null,null,{resources:M,index:A},void 0))}M[A]=D}for(var J=new Array(M.length),A=0;A<J.length;++A)J[A]=e.resolve(M[A]).reflect();var U=e.all(J).then(function(be){for(var B=0;B<be.length;++B){var te=be[B];if(te.isRejected())return u.e=te.error(),u;if(!te.isFulfilled()){U.cancel();return}be[B]=te.value()}ie._pushContext(),y=l(y);var ge=O?y.apply(void 0,be):y(be),$=ie._popContext();return o.checkForgottenReturns(ge,$,"Promise.using",ie),ge}),ie=U.lastly(function(){var be=new e.PromiseInspection(U);return p(M,be)});return M.promise=ie,ie._setOnCancel(M),ie},e.prototype._setDisposable=function(v){this._bitField=this._bitField|131072,this._disposer=v},e.prototype._isDisposable=function(){return(this._bitField&131072)>0},e.prototype._getDisposer=function(){return this._disposer},e.prototype._unsetDisposable=function(){this._bitField=this._bitField&-131073,this._disposer=void 0},e.prototype.disposer=function(v){if(typeof v=="function")return new _(v,this,n());throw new a}}});var u4=E((udt,c4)=>{"use strict";c4.exports=function(e){var t=e._SomePromiseArray;function r(n){var i=new t(n),o=i.promise();return i.setHowMany(1),i.setUnwrap(),i.init(),o}e.any=function(n){return r(n)},e.prototype.any=function(){return r(this)}}});var f4=E((ldt,l4)=>{"use strict";l4.exports=function(e,t){var r=e.reduce,n=e.all;function i(){return n(this)}function o(s,a){return r(s,a,t,t)}e.prototype.each=function(s){return r(this,s,t,0)._then(i,void 0,void 0,this,void 0)},e.prototype.mapSeries=function(s){return r(this,s,t,t)},e.each=function(s,a){return r(s,a,t,0)._then(i,void 0,void 0,s,void 0)},e.mapSeries=o}});var p4=E((fdt,d4)=>{"use strict";d4.exports=function(e,t){var r=e.map;e.prototype.filter=function(n,i){return r(this,n,i,t)},e.filter=function(n,i,o){return r(n,i,o,t)}}});var h4=E((ddt,sR)=>{"use strict";sR.exports=function(){var e=function(){return new R(`circular promise resolution chain
|
|
181
|
+
|
|
182
|
+
See http://goo.gl/MqrFmX
|
|
183
|
+
`)},t=function(){return new $.PromiseInspection(this._target())},r=function(G){return $.reject(new R(G))};function n(){}var i={},o=Vt();o.setReflectHandler(t);var s=function(){var G=process.domain;return G===void 0?null:G},a=function(){return null},c=function(){return{domain:s(),async:null}},u=o.isNode&&o.nodeSupportsAsyncResource?require("async_hooks").AsyncResource:null,l=function(){return{domain:s(),async:new u("Bluebird::Promise")}},d=o.isNode?c:a;o.notEnumerableProp($,"_getContext",d);var h=function(){d=l,o.notEnumerableProp($,"_getContext",l)},f=function(){d=c,o.notEnumerableProp($,"_getContext",c)},p=ga(),m=cU(),_=new m;p.defineProperty($,"_async",{value:_});var w=vs(),R=$.TypeError=w.TypeError;$.RangeError=w.RangeError;var v=$.CancellationError=w.CancellationError;$.TimeoutError=w.TimeoutError,$.OperationalError=w.OperationalError,$.RejectionError=w.OperationalError,$.AggregateError=w.AggregateError;var y=function(){},S={},O={},M=pU()($,y),A=mU()($,y,M,r,n),D=yU()($),I=D.create,N=bU()($,D,h,f),J=N.CapturedTrace,U=SU()($,M,O),ie=tR()(O),be=rR(),B=o.errorObj,te=o.tryCatch;function ge(G,ce){if(G==null||G.constructor!==$)throw new R(`the promise constructor cannot be invoked directly
|
|
184
|
+
|
|
185
|
+
See http://goo.gl/MqrFmX
|
|
186
|
+
`);if(typeof ce!="function")throw new R("expecting a function but got "+o.classString(ce))}function $(G){G!==y&&ge(this,G),this._bitField=0,this._fulfillmentHandler0=void 0,this._rejectionHandler0=void 0,this._promise0=void 0,this._receiver0=void 0,this._resolveFromExecutor(G),this._promiseCreated(),this._fireEvent("promiseCreated",this)}$.prototype.toString=function(){return"[object Promise]"},$.prototype.caught=$.prototype.catch=function(G){var ce=arguments.length;if(ce>1){var Se=new Array(ce-1),P=0,T;for(T=0;T<ce-1;++T){var K=arguments[T];if(o.isObject(K))Se[P++]=K;else return r("Catch statement predicate: expecting an object but got "+o.classString(K))}if(Se.length=P,G=arguments[T],typeof G!="function")throw new R("The last argument to .catch() must be a function, got "+o.toString(G));return this.then(void 0,ie(Se,G,this))}return this.then(void 0,G)},$.prototype.reflect=function(){return this._then(t,t,void 0,this,void 0)},$.prototype.then=function(G,ce){if(N.warnings()&&arguments.length>0&&typeof G!="function"&&typeof ce!="function"){var Se=".then() only accepts functions but was passed: "+o.classString(G);arguments.length>1&&(Se+=", "+o.classString(ce)),this._warn(Se)}return this._then(G,ce,void 0,void 0,void 0)},$.prototype.done=function(G,ce){var Se=this._then(G,ce,void 0,void 0,void 0);Se._setIsFinal()},$.prototype.spread=function(G){return typeof G!="function"?r("expecting a function but got "+o.classString(G)):this.all()._then(G,void 0,void 0,S,void 0)},$.prototype.toJSON=function(){var G={isFulfilled:!1,isRejected:!1,fulfillmentValue:void 0,rejectionReason:void 0};return this.isFulfilled()?(G.fulfillmentValue=this.value(),G.isFulfilled=!0):this.isRejected()&&(G.rejectionReason=this.reason(),G.isRejected=!0),G},$.prototype.all=function(){return arguments.length>0&&this._warn(".all() was passed arguments but it does not take any"),new A(this).promise()},$.prototype.error=function(G){return this.caught(o.originatesFromRejection,G)},$.getNewLibraryCopy=sR.exports,$.is=function(G){return G instanceof $},$.fromNode=$.fromCallback=function(G){var ce=new $(y);ce._captureStackTrace();var Se=arguments.length>1?!!Object(arguments[1]).multiArgs:!1,P=te(G)(be(ce,Se));return P===B&&ce._rejectCallback(P.e,!0),ce._isFateSealed()||ce._setAsyncGuaranteed(),ce},$.all=function(G){return new A(G).promise()},$.cast=function(G){var ce=M(G);return ce instanceof $||(ce=new $(y),ce._captureStackTrace(),ce._setFulfilled(),ce._rejectionHandler0=G),ce},$.resolve=$.fulfilled=$.cast,$.reject=$.rejected=function(G){var ce=new $(y);return ce._captureStackTrace(),ce._rejectCallback(G,!0),ce},$.setScheduler=function(G){if(typeof G!="function")throw new R("expecting a function but got "+o.classString(G));return _.setScheduler(G)},$.prototype._then=function(G,ce,Se,P,T){var K=T!==void 0,j=K?T:new $(y),Be=this._target(),yt=Be._bitField;K||(j._propagateFrom(this,3),j._captureStackTrace(),P===void 0&&(this._bitField&2097152)!==0&&((yt&50397184)!==0?P=this._boundValue():P=Be===this?void 0:this._boundTo),this._fireEvent("promiseChained",this,j));var ft=d();if((yt&50397184)!==0){var wt,Dt,Ur=Be._settlePromiseCtx;(yt&33554432)!==0?(Dt=Be._rejectionHandler0,wt=G):(yt&16777216)!==0?(Dt=Be._fulfillmentHandler0,wt=ce,Be._unsetRejectionIsUnhandled()):(Ur=Be._settlePromiseLateCancellationObserver,Dt=new v("late cancellation observer"),Be._attachExtraTrace(Dt),wt=ce),_.invoke(Ur,Be,{handler:o.contextBind(ft,wt),promise:j,receiver:P,value:Dt})}else Be._addCallbacks(G,ce,j,P,ft);return j},$.prototype._length=function(){return this._bitField&65535},$.prototype._isFateSealed=function(){return(this._bitField&117506048)!==0},$.prototype._isFollowing=function(){return(this._bitField&67108864)===67108864},$.prototype._setLength=function(G){this._bitField=this._bitField&-65536|G&65535},$.prototype._setFulfilled=function(){this._bitField=this._bitField|33554432,this._fireEvent("promiseFulfilled",this)},$.prototype._setRejected=function(){this._bitField=this._bitField|16777216,this._fireEvent("promiseRejected",this)},$.prototype._setFollowing=function(){this._bitField=this._bitField|67108864,this._fireEvent("promiseResolved",this)},$.prototype._setIsFinal=function(){this._bitField=this._bitField|4194304},$.prototype._isFinal=function(){return(this._bitField&4194304)>0},$.prototype._unsetCancelled=function(){this._bitField=this._bitField&-65537},$.prototype._setCancelled=function(){this._bitField=this._bitField|65536,this._fireEvent("promiseCancelled",this)},$.prototype._setWillBeCancelled=function(){this._bitField=this._bitField|8388608},$.prototype._setAsyncGuaranteed=function(){if(!_.hasCustomScheduler()){var G=this._bitField;this._bitField=G|(G&536870912)>>2^134217728}},$.prototype._setNoAsyncGuarantee=function(){this._bitField=(this._bitField|536870912)&-134217729},$.prototype._receiverAt=function(G){var ce=G===0?this._receiver0:this[G*4-4+3];if(ce!==i)return ce===void 0&&this._isBound()?this._boundValue():ce},$.prototype._promiseAt=function(G){return this[G*4-4+2]},$.prototype._fulfillmentHandlerAt=function(G){return this[G*4-4+0]},$.prototype._rejectionHandlerAt=function(G){return this[G*4-4+1]},$.prototype._boundValue=function(){},$.prototype._migrateCallback0=function(G){var ce=G._bitField,Se=G._fulfillmentHandler0,P=G._rejectionHandler0,T=G._promise0,K=G._receiverAt(0);K===void 0&&(K=i),this._addCallbacks(Se,P,T,K,null)},$.prototype._migrateCallbackAt=function(G,ce){var Se=G._fulfillmentHandlerAt(ce),P=G._rejectionHandlerAt(ce),T=G._promiseAt(ce),K=G._receiverAt(ce);K===void 0&&(K=i),this._addCallbacks(Se,P,T,K,null)},$.prototype._addCallbacks=function(G,ce,Se,P,T){var K=this._length();if(K>=65531&&(K=0,this._setLength(0)),K===0)this._promise0=Se,this._receiver0=P,typeof G=="function"&&(this._fulfillmentHandler0=o.contextBind(T,G)),typeof ce=="function"&&(this._rejectionHandler0=o.contextBind(T,ce));else{var j=K*4-4;this[j+2]=Se,this[j+3]=P,typeof G=="function"&&(this[j+0]=o.contextBind(T,G)),typeof ce=="function"&&(this[j+1]=o.contextBind(T,ce))}return this._setLength(K+1),K},$.prototype._proxy=function(G,ce){this._addCallbacks(void 0,void 0,ce,G,null)},$.prototype._resolveCallback=function(G,ce){if((this._bitField&117506048)===0){if(G===this)return this._rejectCallback(e(),!1);var Se=M(G,this);if(!(Se instanceof $))return this._fulfill(G);ce&&this._propagateFrom(Se,2);var P=Se._target();if(P===this){this._reject(e());return}var T=P._bitField;if((T&50397184)===0){var K=this._length();K>0&&P._migrateCallback0(this);for(var j=1;j<K;++j)P._migrateCallbackAt(this,j);this._setFollowing(),this._setLength(0),this._setFollowee(Se)}else if((T&33554432)!==0)this._fulfill(P._value());else if((T&16777216)!==0)this._reject(P._reason());else{var Be=new v("late cancellation observer");P._attachExtraTrace(Be),this._reject(Be)}}},$.prototype._rejectCallback=function(G,ce,Se){var P=o.ensureErrorObject(G),T=P===G;if(!T&&!Se&&N.warnings()){var K="a promise was rejected with a non-error: "+o.classString(G);this._warn(K,!0)}this._attachExtraTrace(P,ce?T:!1),this._reject(G)},$.prototype._resolveFromExecutor=function(G){if(G!==y){var ce=this;this._captureStackTrace(),this._pushContext();var Se=!0,P=this._execute(G,function(T){ce._resolveCallback(T)},function(T){ce._rejectCallback(T,Se)});Se=!1,this._popContext(),P!==void 0&&ce._rejectCallback(P,!0)}},$.prototype._settlePromiseFromHandler=function(G,ce,Se,P){var T=P._bitField;if((T&65536)===0){P._pushContext();var K;ce===S?!Se||typeof Se.length!="number"?(K=B,K.e=new R("cannot .spread() a non-array: "+o.classString(Se))):K=te(G).apply(this._boundValue(),Se):K=te(G).call(ce,Se);var j=P._popContext();T=P._bitField,(T&65536)===0&&(K===O?P._reject(Se):K===B?P._rejectCallback(K.e,!1):(N.checkForgottenReturns(K,j,"",P,this),P._resolveCallback(K)))}},$.prototype._target=function(){for(var G=this;G._isFollowing();)G=G._followee();return G},$.prototype._followee=function(){return this._rejectionHandler0},$.prototype._setFollowee=function(G){this._rejectionHandler0=G},$.prototype._settlePromise=function(G,ce,Se,P){var T=G instanceof $,K=this._bitField,j=(K&134217728)!==0;(K&65536)!==0?(T&&G._invokeInternalOnCancel(),Se instanceof U&&Se.isFinallyHandler()?(Se.cancelPromise=G,te(ce).call(Se,P)===B&&G._reject(B.e)):ce===t?G._fulfill(t.call(Se)):Se instanceof n?Se._promiseCancelled(G):T||G instanceof A?G._cancel():Se.cancel()):typeof ce=="function"?T?(j&&G._setAsyncGuaranteed(),this._settlePromiseFromHandler(ce,Se,P,G)):ce.call(Se,P,G):Se instanceof n?Se._isResolved()||((K&33554432)!==0?Se._promiseFulfilled(P,G):Se._promiseRejected(P,G)):T&&(j&&G._setAsyncGuaranteed(),(K&33554432)!==0?G._fulfill(P):G._reject(P))},$.prototype._settlePromiseLateCancellationObserver=function(G){var ce=G.handler,Se=G.promise,P=G.receiver,T=G.value;typeof ce=="function"?Se instanceof $?this._settlePromiseFromHandler(ce,P,T,Se):ce.call(P,T,Se):Se instanceof $&&Se._reject(T)},$.prototype._settlePromiseCtx=function(G){this._settlePromise(G.promise,G.handler,G.receiver,G.value)},$.prototype._settlePromise0=function(G,ce,Se){var P=this._promise0,T=this._receiverAt(0);this._promise0=void 0,this._receiver0=void 0,this._settlePromise(P,G,T,ce)},$.prototype._clearCallbackDataAtIndex=function(G){var ce=G*4-4;this[ce+2]=this[ce+3]=this[ce+0]=this[ce+1]=void 0},$.prototype._fulfill=function(G){var ce=this._bitField;if(!((ce&117506048)>>>16)){if(G===this){var Se=e();return this._attachExtraTrace(Se),this._reject(Se)}this._setFulfilled(),this._rejectionHandler0=G,(ce&65535)>0&&((ce&134217728)!==0?this._settlePromises():_.settlePromises(this),this._dereferenceTrace())}},$.prototype._reject=function(G){var ce=this._bitField;if(!((ce&117506048)>>>16)){if(this._setRejected(),this._fulfillmentHandler0=G,this._isFinal())return _.fatalError(G,o.isNode);(ce&65535)>0?_.settlePromises(this):this._ensurePossibleRejectionHandled()}},$.prototype._fulfillPromises=function(G,ce){for(var Se=1;Se<G;Se++){var P=this._fulfillmentHandlerAt(Se),T=this._promiseAt(Se),K=this._receiverAt(Se);this._clearCallbackDataAtIndex(Se),this._settlePromise(T,P,K,ce)}},$.prototype._rejectPromises=function(G,ce){for(var Se=1;Se<G;Se++){var P=this._rejectionHandlerAt(Se),T=this._promiseAt(Se),K=this._receiverAt(Se);this._clearCallbackDataAtIndex(Se),this._settlePromise(T,P,K,ce)}},$.prototype._settlePromises=function(){var G=this._bitField,ce=G&65535;if(ce>0){if((G&16842752)!==0){var Se=this._fulfillmentHandler0;this._settlePromise0(this._rejectionHandler0,Se,G),this._rejectPromises(ce,Se)}else{var P=this._rejectionHandler0;this._settlePromise0(this._fulfillmentHandler0,P,G),this._fulfillPromises(ce,P)}this._setLength(0)}this._clearCancellationData()},$.prototype._settledValue=function(){var G=this._bitField;if((G&33554432)!==0)return this._rejectionHandler0;if((G&16777216)!==0)return this._fulfillmentHandler0},typeof Symbol<"u"&&Symbol.toStringTag&&p.defineProperty($.prototype,Symbol.toStringTag,{get:function(){return"Object"}});function ve(G){this.promise._resolveCallback(G)}function Ze(G){this.promise._rejectCallback(G,!1)}$.defer=$.pending=function(){N.deprecated("Promise.defer","new Promise");var G=new $(y);return{promise:G,resolve:ve,reject:Ze}},o.notEnumerableProp($,"_makeSelfResolutionError",e),AU()($,y,M,r,N),PU()($,y,M,N),IU()($,A,r,N),kU()($),MU()($),BU()($,A,M,y,_),$.Promise=$,$.version="3.7.2",qU()($),UU()($,r,y,M,n,N),$U()($,A,r,M,y,N),zU()($),WU()($,y),YU()($,A,M,r),JU()($,y,M,r),ZU()($,A,r,M,y,N),t4()($,A,N),n4()($,A,r),o4()($,y,N),a4()($,r,M,I,y,N),u4()($),f4()($,y),p4()($,y),o.toFastProperties($),o.toFastProperties($.prototype);function at(G){var ce=new $(y);ce._fulfillmentHandler0=G,ce._rejectionHandler0=G,ce._promise0=G,ce._receiver0=G}return at({a:1}),at({b:2}),at({c:3}),at(1),at(function(){}),at(void 0),at(!1),at(new $(y)),N.setBounds(m.firstLineError,o.lastLineError),$}});var y4=E((pdt,g4)=>{"use strict";var m4;typeof Promise<"u"&&(m4=Promise);function cwe(){try{Promise===p_&&(Promise=m4)}catch{}return p_}var p_=h4()();p_.noConflict=cwe;g4.exports=p_});var E4=E((hdt,b4)=>{"use strict";var jp=ry(),uwe=$j(),lwe=ny(),fwe=iy(),h_=require("path"),aR=RT(),dwe=oy(),Up=rp(),m_=y4(),_4=Buffer.alloc(4);_4.writeUInt32LE(101010256,0);function pwe(e){let t=e.stream(0).pipe(jp());return t.pull(4).then(function(r){if(r.readUInt32LE(0)===875721283){let i;return t.pull(12).then(function(o){i=Up.parse(o,[["version",4],["pubKeyLength",4],["signatureLength",4]])}).then(function(){return t.pull(i.pubKeyLength+i.signatureLength)}).then(function(o){return i.publicKey=o.slice(0,i.pubKeyLength),i.signature=o.slice(i.pubKeyLength),i.size=16+i.pubKeyLength+i.signatureLength,i})}})}function hwe(e,t){let r=Up.parse(t,[["signature",4],["diskNumber",4],["offsetToStartOfCentralDirectory",8],["numberOfDisks",4]]);if(r.signature!=117853008)throw new Error("invalid zip64 end of central dir locator signature (0x07064b50): 0x"+r.signature.toString(16));let n=jp();return e.stream(r.offsetToStartOfCentralDirectory).pipe(n),n.pull(56)}function mwe(e){let t=Up.parse(e,[["signature",4],["sizeOfCentralDirectory",8],["version",2],["versionsNeededToExtract",2],["diskNumber",4],["diskStart",4],["numberOfRecordsOnDisk",8],["numberOfRecords",8],["sizeOfCentralDirectory",8],["offsetToStartOfCentralDirectory",8]]);if(t.signature!=101075792)throw new Error("invalid zip64 end of central dir locator signature (0x06064b50): 0x0"+t.signature.toString(16));return t}b4.exports=function(t,r){let n=jp(),i=jp(),o=r&&r.tailSize||80,s,a,c,u;return r&&r.crx&&(a=pwe(t)),t.size().then(function(l){return s=l,t.stream(Math.max(0,l-o)).on("error",function(d){n.emit("error",d)}).pipe(n),n.pull(_4)}).then(function(){return m_.props({directory:n.pull(22),crxHeader:a})}).then(function(l){let d=l.directory;if(c=l.crxHeader&&l.crxHeader.size||0,u=Up.parse(d,[["signature",4],["diskNumber",2],["diskStart",2],["numberOfRecordsOnDisk",2],["numberOfRecords",2],["sizeOfCentralDirectory",4],["offsetToStartOfCentralDirectory",4],["commentLength",2]]),u.diskNumber==65535||u.numberOfRecords==65535||u.offsetToStartOfCentralDirectory==4294967295){let f=s-(o-n.match+20),p=jp();return t.stream(f).pipe(p),p.pull(20).then(function(m){return hwe(t,m)}).then(function(m){u=mwe(m)})}else u.offsetToStartOfCentralDirectory+=c}).then(function(){if(u.commentLength)return n.pull(u.commentLength).then(function(l){u.comment=l.toString("utf8")})}).then(function(){return t.stream(u.offsetToStartOfCentralDirectory).pipe(i),u.extract=function(l){if(!l||!l.path)throw new Error("PATH_MISSING");return l.path=h_.resolve(h_.normalize(l.path)),u.files.then(function(d){return m_.map(d,async function(h){let f=h_.join(l.path,h.path);if(f.indexOf(l.path)!=0)return;if(h.type=="Directory"){await aR.ensureDir(f);return}await aR.ensureDir(h_.dirname(f));let p=l.getWriter?l.getWriter({path:f}):aR.createWriteStream(f);return new Promise(function(m,_){h.stream(l.password).on("error",_).pipe(p).on("close",m).on("error",_)})},{concurrency:l.concurrency>1?l.concurrency:1})})},u.files=m_.mapSeries(Array(u.numberOfRecords),function(){return i.pull(46).then(function(l){let d=Up.parse(l,[["signature",4],["versionMadeBy",2],["versionsNeededToExtract",2],["flags",2],["compressionMethod",2],["lastModifiedTime",2],["lastModifiedDate",2],["crc32",4],["compressedSize",4],["uncompressedSize",4],["fileNameLength",2],["extraFieldLength",2],["fileCommentLength",2],["diskNumber",2],["internalFileAttributes",2],["externalFileAttributes",4],["offsetToLocalFileHeader",4]]);return d.offsetToLocalFileHeader+=c,d.lastModifiedDateTime=dwe(d.lastModifiedDate,d.lastModifiedTime),i.pull(d.fileNameLength).then(function(h){return d.pathBuffer=h,d.path=h.toString("utf8"),d.isUnicode=(d.flags&2048)!=0,i.pull(d.extraFieldLength)}).then(function(h){return d.extra=fwe(h,d),i.pull(d.fileCommentLength)}).then(function(h){d.comment=h,d.type=d.uncompressedSize===0&&/[/\\]$/.test(d.path)?"Directory":"File";let f=r&&r.padding||1e3;return d.stream=function(p){let m=30+f+(d.extraFieldLength||0)+(d.fileNameLength||0)+d.compressedSize;return uwe(t,d.offsetToLocalFileHeader,p,d,m)},d.buffer=function(p){return lwe(d.stream(p))},d})})}),m_.props(u)})}});var Cs=E(Ut=>{"use strict";Ut.HttpAuthLocation=void 0;(function(e){e.HEADER="header",e.QUERY="query"})(Ut.HttpAuthLocation||(Ut.HttpAuthLocation={}));Ut.HttpApiKeyAuthLocation=void 0;(function(e){e.HEADER="header",e.QUERY="query"})(Ut.HttpApiKeyAuthLocation||(Ut.HttpApiKeyAuthLocation={}));Ut.EndpointURLScheme=void 0;(function(e){e.HTTP="http",e.HTTPS="https"})(Ut.EndpointURLScheme||(Ut.EndpointURLScheme={}));Ut.AlgorithmId=void 0;(function(e){e.MD5="md5",e.CRC32="crc32",e.CRC32C="crc32c",e.SHA1="sha1",e.SHA256="sha256"})(Ut.AlgorithmId||(Ut.AlgorithmId={}));var gwe=e=>{let t=[];return e.sha256!==void 0&&t.push({algorithmId:()=>Ut.AlgorithmId.SHA256,checksumConstructor:()=>e.sha256}),e.md5!=null&&t.push({algorithmId:()=>Ut.AlgorithmId.MD5,checksumConstructor:()=>e.md5}),{addChecksumAlgorithm(r){t.push(r)},checksumAlgorithms(){return t}}},ywe=e=>{let t={};return e.checksumAlgorithms().forEach(r=>{t[r.algorithmId()]=r.checksumConstructor()}),t},_we=e=>gwe(e),bwe=e=>ywe(e);Ut.FieldPosition=void 0;(function(e){e[e.HEADER=0]="HEADER",e[e.TRAILER=1]="TRAILER"})(Ut.FieldPosition||(Ut.FieldPosition={}));var Ewe="__smithy_context";Ut.IniSectionType=void 0;(function(e){e.PROFILE="profile",e.SSO_SESSION="sso-session",e.SERVICES="services"})(Ut.IniSectionType||(Ut.IniSectionType={}));Ut.RequestHandlerProtocol=void 0;(function(e){e.HTTP_0_9="http/0.9",e.HTTP_1_0="http/1.0",e.TDS_8_0="tds/8.0"})(Ut.RequestHandlerProtocol||(Ut.RequestHandlerProtocol={}));Ut.SMITHY_CONTEXT_KEY=Ewe;Ut.getDefaultClientConfiguration=_we;Ut.resolveDefaultRuntimeConfig=bwe});var St=E(_a=>{"use strict";var wwe=Cs(),Swe=e=>({setHttpHandler(t){e.httpHandler=t},httpHandler(){return e.httpHandler},updateHttpClientConfig(t,r){e.httpHandler?.updateHttpClientConfig(t,r)},httpHandlerConfigs(){return e.httpHandler.httpHandlerConfigs()}}),vwe=e=>({httpHandler:e.httpHandler()}),cR=class{name;kind;values;constructor({name:t,kind:r=wwe.FieldPosition.HEADER,values:n=[]}){this.name=t,this.kind=r,this.values=n}add(t){this.values.push(t)}set(t){this.values=t}remove(t){this.values=this.values.filter(r=>r!==t)}toString(){return this.values.map(t=>t.includes(",")||t.includes(" ")?`"${t}"`:t).join(", ")}get(){return this.values}},uR=class{entries={};encoding;constructor({fields:t=[],encoding:r="utf-8"}){t.forEach(this.setField.bind(this)),this.encoding=r}setField(t){this.entries[t.name.toLowerCase()]=t}getField(t){return this.entries[t.toLowerCase()]}removeField(t){delete this.entries[t.toLowerCase()]}getByType(t){return Object.values(this.entries).filter(r=>r.kind===t)}},lR=class e{method;protocol;hostname;port;path;query;headers;username;password;fragment;body;constructor(t){this.method=t.method||"GET",this.hostname=t.hostname||"localhost",this.port=t.port,this.query=t.query||{},this.headers=t.headers||{},this.body=t.body,this.protocol=t.protocol?t.protocol.slice(-1)!==":"?`${t.protocol}:`:t.protocol:"https:",this.path=t.path?t.path.charAt(0)!=="/"?`/${t.path}`:t.path:"/",this.username=t.username,this.password=t.password,this.fragment=t.fragment}static clone(t){let r=new e({...t,headers:{...t.headers}});return r.query&&(r.query=Cwe(r.query)),r}static isInstance(t){if(!t)return!1;let r=t;return"method"in r&&"protocol"in r&&"hostname"in r&&"path"in r&&typeof r.query=="object"&&typeof r.headers=="object"}clone(){return e.clone(this)}};function Cwe(e){return Object.keys(e).reduce((t,r)=>{let n=e[r];return{...t,[r]:Array.isArray(n)?[...n]:n}},{})}var fR=class{statusCode;reason;headers;body;constructor(t){this.statusCode=t.statusCode,this.reason=t.reason,this.headers=t.headers||{},this.body=t.body}static isInstance(t){if(!t)return!1;let r=t;return typeof r.statusCode=="number"&&typeof r.headers=="object"}};function xwe(e){return/^[a-z0-9][a-z0-9\.\-]*[a-z0-9]$/.test(e)}_a.Field=cR;_a.Fields=uR;_a.HttpRequest=lR;_a.HttpResponse=fR;_a.getHttpHandlerExtensionConfiguration=Swe;_a.isValidHostname=xwe;_a.resolveHttpHandlerRuntimeConfig=vwe});var v4=E(g_=>{"use strict";var Twe=St();function w4(e){return t=>async r=>{let{request:n}=r;if(e.expectContinueHeader!==!1&&Twe.HttpRequest.isInstance(n)&&n.body&&e.runtime==="node"&&e.requestHandler?.constructor?.name!=="FetchHttpHandler"){let i=!0;if(typeof e.expectContinueHeader=="number")try{i=(Number(n.headers?.["content-length"])??e.bodyLengthChecker?.(n.body)??1/0)>=e.expectContinueHeader}catch{}else i=!!e.expectContinueHeader;i&&(n.headers.Expect="100-continue")}return t({...r,request:n})}}var S4={step:"build",tags:["SET_EXPECT_HEADER","EXPECT_HEADER"],name:"addExpectContinueMiddleware",override:!0},Awe=e=>({applyToStack:t=>{t.add(w4(e),S4)}});g_.addExpectContinueMiddleware=w4;g_.addExpectContinueMiddlewareOptions=S4;g_.getAddExpectContinuePlugin=Awe});var y_,ba,C4=Y(()=>{"use strict";y_={warningEmitted:!1},ba=e=>{e&&!y_.warningEmitted&&parseInt(e.substring(1,e.indexOf(".")))<18&&(y_.warningEmitted=!0,process.emitWarning(`NodeDeprecationWarning: The AWS SDK for JavaScript (v3) will
|
|
187
|
+
no longer support Node.js 16.x on January 6, 2025.
|
|
188
|
+
|
|
189
|
+
To continue receiving updates to AWS services, bug fixes, and security
|
|
190
|
+
updates please upgrade to a supported Node.js LTS version.
|
|
191
|
+
|
|
192
|
+
More information can be found at: https://a.co/74kJMmI`))}});function Ea(e,t,r){return e.$source||(e.$source={}),e.$source[t]=r,e}var x4=Y(()=>{"use strict"});function T4(e,t,r){e.__aws_sdk_context?e.__aws_sdk_context.features||(e.__aws_sdk_context.features={}):e.__aws_sdk_context={features:{}},e.__aws_sdk_context.features[t]=r}var A4=Y(()=>{"use strict"});function R4(e,t,r){return e.$source||(e.$source={}),e.$source[t]=r,e}var P4=Y(()=>{"use strict"});var xs={};Nn(xs,{emitWarningIfUnsupportedVersion:()=>ba,setCredentialFeature:()=>Ea,setFeature:()=>T4,setTokenFeature:()=>R4,state:()=>y_});var ki=Y(()=>{"use strict";C4();x4();A4();P4()});var O4,dR,I4=Y(()=>{"use strict";O4=z(St()),dR=e=>O4.HttpResponse.isInstance(e)?e.headers?.date??e.headers?.Date:void 0});var Ml,pR=Y(()=>{"use strict";Ml=e=>new Date(Date.now()+e)});var D4,k4=Y(()=>{"use strict";pR();D4=(e,t)=>Math.abs(Ml(t).getTime()-e)>=3e5});var hR,N4=Y(()=>{"use strict";k4();hR=(e,t)=>{let r=Date.parse(e);return D4(r,t)?r-Date.now():t}});var mR=Y(()=>{"use strict";I4();pR();N4()});var M4,Hp,Ll,bn,gR,yR=Y(()=>{"use strict";M4=z(St());mR();Hp=(e,t)=>{if(!t)throw new Error(`Property \`${e}\` is not resolved for AWS SDK SigV4Auth`);return t},Ll=async e=>{let t=Hp("context",e.context),r=Hp("config",e.config),n=t.endpointV2?.properties?.authSchemes?.[0],o=await Hp("signer",r.signer)(n),s=e?.signingRegion,a=e?.signingRegionSet,c=e?.signingName;return{config:r,signer:o,signingRegion:s,signingRegionSet:a,signingName:c}},bn=class{async sign(t,r,n){if(!M4.HttpRequest.isInstance(t))throw new Error("The request is not an instance of `HttpRequest` and cannot be signed");let i=await Ll(n),{config:o,signer:s}=i,{signingRegion:a,signingName:c}=i,u=n.context;if(u?.authSchemes?.length??!1){let[d,h]=u.authSchemes;d?.name==="sigv4a"&&h?.name==="sigv4"&&(a=h?.signingRegion??a,c=h?.signingName??c)}return await s.sign(t,{signingDate:Ml(o.systemClockOffset),signingRegion:a,signingService:c})}errorHandler(t){return r=>{let n=r.ServerTime??dR(r.$response);if(n){let i=Hp("config",t.config),o=i.systemClockOffset;i.systemClockOffset=hR(n,i.systemClockOffset),i.systemClockOffset!==o&&r.$metadata&&(r.$metadata.clockSkewCorrected=!0)}throw r}}successHandler(t,r){let n=dR(t);if(n){let i=Hp("config",r.config);i.systemClockOffset=hR(n,i.systemClockOffset)}}},gR=bn});var L4,$p,B4=Y(()=>{"use strict";L4=z(St());mR();yR();$p=class extends bn{async sign(t,r,n){if(!L4.HttpRequest.isInstance(t))throw new Error("The request is not an instance of `HttpRequest` and cannot be signed");let{config:i,signer:o,signingRegion:s,signingRegionSet:a,signingName:c}=await Ll(n),l=(await i.sigv4aSigningRegionSet?.()??a??[s]).join(",");return await o.sign(t,{signingDate:Ml(i.systemClockOffset),signingRegion:l,signingService:c})}}});var _R,F4=Y(()=>{"use strict";_R=e=>typeof e=="string"&&e.length>0?e.split(",").map(t=>t.trim()):[]});var __,bR=Y(()=>{"use strict";__=e=>`AWS_BEARER_TOKEN_${e.replace(/[\s-]/g,"_").toUpperCase()}`});var q4,j4,wa,U4=Y(()=>{"use strict";F4();bR();q4="AWS_AUTH_SCHEME_PREFERENCE",j4="auth_scheme_preference",wa={environmentVariableSelector:(e,t)=>{if(t?.signingName&&__(t.signingName)in e)return["httpBearerAuth"];if(q4 in e)return _R(e[q4])},configFileSelector:e=>{if(j4 in e)return _R(e[j4])},default:[]}});var ER,Rwe,H4=Y(()=>{"use strict";ER=z(Cs()),Rwe=e=>e[ER.SMITHY_CONTEXT_KEY]||(e[ER.SMITHY_CONTEXT_KEY]={})});var an=E(wR=>{"use strict";var $4=Cs(),Pwe=e=>e[$4.SMITHY_CONTEXT_KEY]||(e[$4.SMITHY_CONTEXT_KEY]={}),Owe=e=>{if(typeof e=="function")return e;let t=Promise.resolve(e);return()=>t};wR.getSmithyContext=Pwe;wR.normalizeProvider=Owe});var G4,z4=Y(()=>{"use strict";G4=(e,t)=>{if(!t||t.length===0)return e;let r=[];for(let n of t)for(let i of e)i.schemeId.split("#")[1]===n&&r.push(i);for(let n of e)r.find(({schemeId:i})=>i===n.schemeId)||r.push(n);return r}});function Iwe(e){let t=new Map;for(let r of e)t.set(r.schemeId,r);return t}var V4,Gp,b_=Y(()=>{"use strict";V4=z(an());z4();Gp=(e,t)=>(r,n)=>async i=>{let o=e.httpAuthSchemeProvider(await t.httpAuthSchemeParametersProvider(e,n,i.input)),s=e.authSchemePreference?await e.authSchemePreference():[],a=G4(o,s),c=Iwe(e.httpAuthSchemes),u=(0,V4.getSmithyContext)(n),l=[];for(let d of a){let h=c.get(d.schemeId);if(!h){l.push(`HttpAuthScheme \`${d.schemeId}\` was not enabled for this service.`);continue}let f=h.identityProvider(await t.identityProviderConfigProvider(e));if(!f){l.push(`HttpAuthScheme \`${d.schemeId}\` did not have an IdentityProvider configured.`);continue}let{identityProperties:p={},signingProperties:m={}}=d.propertiesExtractor?.(e,n)||{};d.identityProperties=Object.assign(d.identityProperties||{},p),d.signingProperties=Object.assign(d.signingProperties||{},m),u.selectedHttpAuthScheme={httpAuthOption:d,identity:await f(d.identityProperties),signer:h.signer};break}if(!u.selectedHttpAuthScheme)throw new Error(l.join(`
|
|
193
|
+
`));return r(i)}});var W4,Yc,K4=Y(()=>{"use strict";b_();W4={step:"serialize",tags:["HTTP_AUTH_SCHEME"],name:"httpAuthSchemeMiddleware",override:!0,relation:"before",toMiddleware:"endpointV2Middleware"},Yc=(e,{httpAuthSchemeParametersProvider:t,identityProviderConfigProvider:r})=>({applyToStack:n=>{n.addRelativeTo(Gp(e,{httpAuthSchemeParametersProvider:t,identityProviderConfigProvider:r}),W4)}})});var vR=E(Bl=>{"use strict";var Dwe=St(),Y4=(e,t)=>(r,n)=>async i=>{let{response:o}=await r(i);try{let s=await t(o,e);return{response:o,output:s}}catch(s){if(Object.defineProperty(s,"$response",{value:o,enumerable:!1,writable:!1,configurable:!1}),!("$metadata"in s)){let a="Deserialization error: to see the raw response, inspect the hidden field {error}.$response on this object.";try{s.message+=`
|
|
194
|
+
`+a}catch{!n.logger||n.logger?.constructor?.name==="NoOpLogger"?console.warn(a):n.logger?.warn?.(a)}typeof s.$responseBodyText<"u"&&s.$response&&(s.$response.body=s.$responseBodyText);try{if(Dwe.HttpResponse.isInstance(o)){let{headers:c={}}=o,u=Object.entries(c);s.$metadata={httpStatusCode:o.statusCode,requestId:SR(/^x-[\w-]+-request-?id$/,u),extendedRequestId:SR(/^x-[\w-]+-id-2$/,u),cfId:SR(/^x-[\w-]+-cf-id$/,u)}}}catch{}}throw s}},SR=(e,t)=>(t.find(([r])=>r.match(e))||[void 0,void 0])[1],X4=(e,t)=>(r,n)=>async i=>{let o=e,s=n.endpointV2?.url&&o.urlParser?async()=>o.urlParser(n.endpointV2.url):o.endpoint;if(!s)throw new Error("No valid endpoint provider available.");let a=await t(i.input,{...e,endpoint:s});return r({...i,request:a})},J4={name:"deserializerMiddleware",step:"deserialize",tags:["DESERIALIZER"],override:!0},Q4={name:"serializerMiddleware",step:"serialize",tags:["SERIALIZER"],override:!0};function kwe(e,t,r){return{applyToStack:n=>{n.add(Y4(e,r),J4),n.add(X4(e,t),Q4)}}}Bl.deserializerMiddleware=Y4;Bl.deserializerMiddlewareOption=J4;Bl.getSerdePlugin=kwe;Bl.serializerMiddleware=X4;Bl.serializerMiddlewareOption=Q4});var Z4,eH,Nwe,tH=Y(()=>{"use strict";Z4=z(vR());b_();eH={step:"serialize",tags:["HTTP_AUTH_SCHEME"],name:"httpAuthSchemeMiddleware",override:!0,relation:"before",toMiddleware:Z4.serializerMiddlewareOption.name},Nwe=(e,{httpAuthSchemeParametersProvider:t,identityProviderConfigProvider:r})=>({applyToStack:n=>{n.addRelativeTo(Gp(e,{httpAuthSchemeParametersProvider:t,identityProviderConfigProvider:r}),eH)}})});var rH=Y(()=>{"use strict";b_();K4();tH()});var nH,iH,Mwe,Lwe,CR,xR=Y(()=>{"use strict";nH=z(St()),iH=z(an()),Mwe=e=>t=>{throw t},Lwe=(e,t)=>{},CR=e=>(t,r)=>async n=>{if(!nH.HttpRequest.isInstance(n.request))return t(n);let o=(0,iH.getSmithyContext)(r).selectedHttpAuthScheme;if(!o)throw new Error("No HttpAuthScheme was selected: unable to sign request");let{httpAuthOption:{signingProperties:s={}},identity:a,signer:c}=o,u=await t({...n,request:await c.sign(n.request,a,s)}).catch((c.errorHandler||Mwe)(s));return(c.successHandler||Lwe)(u.response,s),u}});var oH,Xc,sH=Y(()=>{"use strict";xR();oH={step:"finalizeRequest",tags:["HTTP_SIGNING"],name:"httpSigningMiddleware",aliases:["apiKeyMiddleware","tokenMiddleware","awsAuthMiddleware"],override:!0,relation:"after",toMiddleware:"retryMiddleware"},Xc=e=>({applyToStack:t=>{t.addRelativeTo(CR(e),oH)}})});var aH=Y(()=>{"use strict";xR();sH()});var Sa,cH=Y(()=>{"use strict";Sa=e=>{if(typeof e=="function")return e;let t=Promise.resolve(e);return()=>t}});function uH(e,t,r,n,i){return async function*(s,a,...c){let u=a,l=s.startingToken??u[r],d=!0,h;for(;d;){if(u[r]=l,i&&(u[i]=u[i]??s.pageSize),s.client instanceof e)h=await Bwe(t,s.client,a,s.withCommand,...c);else throw new Error(`Invalid client, expected instance of ${e.name}`);yield h;let f=l;l=Fwe(h,n),d=!!(l&&(!s.stopOnSameToken||l!==f))}return void 0}}var Bwe,Fwe,lH=Y(()=>{"use strict";Bwe=async(e,t,r,n=o=>o,...i)=>{let o=new e(r);return o=n(o)??o,await t.send(o,...i)};Fwe=(e,t)=>{let r=e,n=t.split(".");for(let i of n){if(!r||typeof r!="object")return;r=r[i]}return r}});var E_=E(fH=>{"use strict";var qwe=e=>typeof ArrayBuffer=="function"&&e instanceof ArrayBuffer||Object.prototype.toString.call(e)==="[object ArrayBuffer]";fH.isArrayBuffer=qwe});var Fl=E(AR=>{"use strict";var jwe=E_(),TR=require("buffer"),Uwe=(e,t=0,r=e.byteLength-t)=>{if(!jwe.isArrayBuffer(e))throw new TypeError(`The "input" argument must be ArrayBuffer. Received type ${typeof e} (${e})`);return TR.Buffer.from(e,t,r)},Hwe=(e,t)=>{if(typeof e!="string")throw new TypeError(`The "input" argument must be of type string. Received type ${typeof e} (${e})`);return t?TR.Buffer.from(e,t):TR.Buffer.from(e)};AR.fromArrayBuffer=Uwe;AR.fromString=Hwe});var dH=E(w_=>{"use strict";Object.defineProperty(w_,"__esModule",{value:!0});w_.fromBase64=void 0;var $we=Fl(),Gwe=/^[A-Za-z0-9+/]*={0,2}$/,zwe=e=>{if(e.length*3%4!==0)throw new TypeError("Incorrect padding on base64 string.");if(!Gwe.exec(e))throw new TypeError("Invalid base64 string.");let t=(0,$we.fromString)(e,"base64");return new Uint8Array(t.buffer,t.byteOffset,t.byteLength)};w_.fromBase64=zwe});var Cr=E(S_=>{"use strict";var pH=Fl(),hH=e=>{let t=pH.fromString(e,"utf8");return new Uint8Array(t.buffer,t.byteOffset,t.byteLength/Uint8Array.BYTES_PER_ELEMENT)},Vwe=e=>typeof e=="string"?hH(e):ArrayBuffer.isView(e)?new Uint8Array(e.buffer,e.byteOffset,e.byteLength/Uint8Array.BYTES_PER_ELEMENT):new Uint8Array(e),Wwe=e=>{if(typeof e=="string")return e;if(typeof e!="object"||typeof e.byteOffset!="number"||typeof e.byteLength!="number")throw new Error("@smithy/util-utf8: toUtf8 encoder function only accepts string | Uint8Array.");return pH.fromArrayBuffer(e.buffer,e.byteOffset,e.byteLength).toString("utf8")};S_.fromUtf8=hH;S_.toUint8Array=Vwe;S_.toUtf8=Wwe});var mH=E(v_=>{"use strict";Object.defineProperty(v_,"__esModule",{value:!0});v_.toBase64=void 0;var Kwe=Fl(),Ywe=Cr(),Xwe=e=>{let t;if(typeof e=="string"?t=(0,Ywe.fromUtf8)(e):t=e,typeof t!="object"||typeof t.byteOffset!="number"||typeof t.byteLength!="number")throw new Error("@smithy/util-base64: toBase64 encoder function only accepts string | Uint8Array.");return(0,Kwe.fromArrayBuffer)(t.buffer,t.byteOffset,t.byteLength).toString("base64")};v_.toBase64=Xwe});var Gr=E(zp=>{"use strict";var gH=dH(),yH=mH();Object.keys(gH).forEach(function(e){e!=="default"&&!Object.prototype.hasOwnProperty.call(zp,e)&&Object.defineProperty(zp,e,{enumerable:!0,get:function(){return gH[e]}})});Object.keys(yH).forEach(function(e){e!=="default"&&!Object.prototype.hasOwnProperty.call(zp,e)&&Object.defineProperty(zp,e,{enumerable:!0,get:function(){return yH[e]}})})});var PR=E(C_=>{"use strict";Object.defineProperty(C_,"__esModule",{value:!0});C_.ChecksumStream=void 0;var Jwe=Gr(),Qwe=require("stream"),RR=class extends Qwe.Duplex{expectedChecksum;checksumSourceLocation;checksum;source;base64Encoder;constructor({expectedChecksum:t,checksum:r,source:n,checksumSourceLocation:i,base64Encoder:o}){if(super(),typeof n.pipe=="function")this.source=n;else throw new Error(`@smithy/util-stream: unsupported source type ${n?.constructor?.name??n} in ChecksumStream.`);this.base64Encoder=o??Jwe.toBase64,this.expectedChecksum=t,this.checksum=r,this.checksumSourceLocation=i,this.source.pipe(this)}_read(t){}_write(t,r,n){try{this.checksum.update(t),this.push(t)}catch(i){return n(i)}return n()}async _final(t){try{let r=await this.checksum.digest(),n=this.base64Encoder(r);if(this.expectedChecksum!==n)return t(new Error(`Checksum mismatch: expected "${this.expectedChecksum}" but received "${n}" in response header "${this.checksumSourceLocation}".`))}catch(r){return t(r)}return this.push(null),t()}};C_.ChecksumStream=RR});var va=E(ql=>{"use strict";Object.defineProperty(ql,"__esModule",{value:!0});ql.isBlob=ql.isReadableStream=void 0;var Zwe=e=>typeof ReadableStream=="function"&&(e?.constructor?.name===ReadableStream.name||e instanceof ReadableStream);ql.isReadableStream=Zwe;var eSe=e=>typeof Blob=="function"&&(e?.constructor?.name===Blob.name||e instanceof Blob);ql.isBlob=eSe});var _H=E(x_=>{"use strict";Object.defineProperty(x_,"__esModule",{value:!0});x_.ChecksumStream=void 0;var tSe=typeof ReadableStream=="function"?ReadableStream:function(){},OR=class extends tSe{};x_.ChecksumStream=OR});var bH=E(T_=>{"use strict";Object.defineProperty(T_,"__esModule",{value:!0});T_.createChecksumStream=void 0;var rSe=Gr(),nSe=va(),iSe=_H(),oSe=({expectedChecksum:e,checksum:t,source:r,checksumSourceLocation:n,base64Encoder:i})=>{if(!(0,nSe.isReadableStream)(r))throw new Error(`@smithy/util-stream: unsupported source type ${r?.constructor?.name??r} in ChecksumStream.`);let o=i??rSe.toBase64;if(typeof TransformStream!="function")throw new Error("@smithy/util-stream: unable to instantiate ChecksumStream because API unavailable: ReadableStream/TransformStream.");let s=new TransformStream({start(){},async transform(c,u){t.update(c),u.enqueue(c)},async flush(c){let u=await t.digest(),l=o(u);if(e!==l){let d=new Error(`Checksum mismatch: expected "${e}" but received "${l}" in response header "${n}".`);c.error(d)}else c.terminate()}});r.pipeThrough(s);let a=s.readable;return Object.setPrototypeOf(a,iSe.ChecksumStream.prototype),a};T_.createChecksumStream=oSe});var EH=E(IR=>{"use strict";Object.defineProperty(IR,"__esModule",{value:!0});IR.createChecksumStream=uSe;var sSe=va(),aSe=PR(),cSe=bH();function uSe(e){return typeof ReadableStream=="function"&&(0,sSe.isReadableStream)(e.source)?(0,cSe.createChecksumStream)(e):new aSe.ChecksumStream(e)}});var kR=E(A_=>{"use strict";Object.defineProperty(A_,"__esModule",{value:!0});A_.ByteArrayCollector=void 0;var DR=class{allocByteArray;byteLength=0;byteArrays=[];constructor(t){this.allocByteArray=t}push(t){this.byteArrays.push(t),this.byteLength+=t.byteLength}flush(){if(this.byteArrays.length===1){let n=this.byteArrays[0];return this.reset(),n}let t=this.allocByteArray(this.byteLength),r=0;for(let n=0;n<this.byteArrays.length;++n){let i=this.byteArrays[n];t.set(i,r),r+=i.byteLength}return this.reset(),t}reset(){this.byteArrays=[],this.byteLength=0}};A_.ByteArrayCollector=DR});var CH=E(Ts=>{"use strict";Object.defineProperty(Ts,"__esModule",{value:!0});Ts.createBufferedReadable=void 0;Ts.createBufferedReadableStream=wH;Ts.merge=SH;Ts.flush=R_;Ts.sizeOf=jl;Ts.modeOf=vH;var lSe=kR();function wH(e,t,r){let n=e.getReader(),i=!1,o=0,s=["",new lSe.ByteArrayCollector(u=>new Uint8Array(u))],a=-1,c=async u=>{let{value:l,done:d}=await n.read(),h=l;if(d){if(a!==-1){let f=R_(s,a);jl(f)>0&&u.enqueue(f)}u.close()}else{let f=vH(h,!1);if(a!==f&&(a>=0&&u.enqueue(R_(s,a)),a=f),a===-1){u.enqueue(h);return}let p=jl(h);o+=p;let m=jl(s[a]);if(p>=t&&m===0)u.enqueue(h);else{let _=SH(s,a,h);!i&&o>t*2&&(i=!0,r?.warn(`@smithy/util-stream - stream chunk size ${p} is below threshold of ${t}, automatically buffering.`)),_>=t?u.enqueue(R_(s,a)):await c(u)}}};return new ReadableStream({pull:c})}Ts.createBufferedReadable=wH;function SH(e,t,r){switch(t){case 0:return e[0]+=r,jl(e[0]);case 1:case 2:return e[t].push(r),jl(e[t])}}function R_(e,t){switch(t){case 0:let r=e[0];return e[0]="",r;case 1:case 2:return e[t].flush()}throw new Error(`@smithy/util-stream - invalid index ${t} given to flush()`)}function jl(e){return e?.byteLength??e?.length??0}function vH(e,t=!0){return t&&typeof Buffer<"u"&&e instanceof Buffer?2:e instanceof Uint8Array?1:typeof e=="string"?0:-1}});var TH=E(NR=>{"use strict";Object.defineProperty(NR,"__esModule",{value:!0});NR.createBufferedReadable=pSe;var fSe=require("node:stream"),xH=kR(),As=CH(),dSe=va();function pSe(e,t,r){if((0,dSe.isReadableStream)(e))return(0,As.createBufferedReadableStream)(e,t,r);let n=new fSe.Readable({read(){}}),i=!1,o=0,s=["",new xH.ByteArrayCollector(c=>new Uint8Array(c)),new xH.ByteArrayCollector(c=>Buffer.from(new Uint8Array(c)))],a=-1;return e.on("data",c=>{let u=(0,As.modeOf)(c,!0);if(a!==u&&(a>=0&&n.push((0,As.flush)(s,a)),a=u),a===-1){n.push(c);return}let l=(0,As.sizeOf)(c);o+=l;let d=(0,As.sizeOf)(s[a]);if(l>=t&&d===0)n.push(c);else{let h=(0,As.merge)(s,a,c);!i&&o>t*2&&(i=!0,r?.warn(`@smithy/util-stream - stream chunk size ${l} is below threshold of ${t}, automatically buffering.`)),h>=t&&n.push((0,As.flush)(s,a))}}),e.on("end",()=>{if(a!==-1){let c=(0,As.flush)(s,a);(0,As.sizeOf)(c)>0&&n.push(c)}n.push(null)}),n}});var AH=E(P_=>{"use strict";Object.defineProperty(P_,"__esModule",{value:!0});P_.getAwsChunkedEncodingStream=void 0;var hSe=require("stream"),mSe=(e,t)=>{let{base64Encoder:r,bodyLengthChecker:n,checksumAlgorithmFn:i,checksumLocationName:o,streamHasher:s}=t,a=r!==void 0&&i!==void 0&&o!==void 0&&s!==void 0,c=a?s(i,e):void 0,u=new hSe.Readable({read:()=>{}});return e.on("data",l=>{let d=n(l)||0;u.push(`${d.toString(16)}\r
|
|
195
|
+
`),u.push(l),u.push(`\r
|
|
196
|
+
`)}),e.on("end",async()=>{if(u.push(`0\r
|
|
197
|
+
`),a){let l=r(await c);u.push(`${o}:${l}\r
|
|
198
|
+
`),u.push(`\r
|
|
199
|
+
`)}u.push(null)}),u};P_.getAwsChunkedEncodingStream=mSe});var RH=E(MR=>{"use strict";Object.defineProperty(MR,"__esModule",{value:!0});MR.headStream=gSe;async function gSe(e,t){let r=0,n=[],i=e.getReader(),o=!1;for(;!o;){let{done:c,value:u}=await i.read();if(u&&(n.push(u),r+=u?.byteLength??0),r>=t)break;o=c}i.releaseLock();let s=new Uint8Array(Math.min(t,r)),a=0;for(let c of n){if(c.byteLength>s.byteLength-a){s.set(c.subarray(0,s.byteLength-a),a);break}else s.set(c,a);a+=c.length}return s}});var PH=E(O_=>{"use strict";Object.defineProperty(O_,"__esModule",{value:!0});O_.headStream=void 0;var ySe=require("stream"),_Se=RH(),bSe=va(),ESe=(e,t)=>(0,bSe.isReadableStream)(e)?(0,_Se.headStream)(e,t):new Promise((r,n)=>{let i=new LR;i.limit=t,e.pipe(i),e.on("error",o=>{i.end(),n(o)}),i.on("error",n),i.on("finish",function(){let o=new Uint8Array(Buffer.concat(this.buffers));r(o)})});O_.headStream=ESe;var LR=class extends ySe.Writable{buffers=[];limit=1/0;bytesBuffered=0;_write(t,r,n){if(this.buffers.push(t),this.bytesBuffered+=t.byteLength??0,this.bytesBuffered>=this.limit){let i=this.bytesBuffered-this.limit,o=this.buffers[this.buffers.length-1];this.buffers[this.buffers.length-1]=o.subarray(0,o.byteLength-i),this.emit("finish")}n()}}});var FR=E(BR=>{"use strict";var OH=e=>encodeURIComponent(e).replace(/[!'()*]/g,wSe),wSe=e=>`%${e.charCodeAt(0).toString(16).toUpperCase()}`,SSe=e=>e.split("/").map(OH).join("/");BR.escapeUri=OH;BR.escapeUriPath=SSe});var jR=E(IH=>{"use strict";var qR=FR();function vSe(e){let t=[];for(let r of Object.keys(e).sort()){let n=e[r];if(r=qR.escapeUri(r),Array.isArray(n))for(let i=0,o=n.length;i<o;i++)t.push(`${r}=${qR.escapeUri(n[i])}`);else{let i=r;(n||typeof n=="string")&&(i+=`=${qR.escapeUri(n)}`),t.push(i)}}return t.join("&")}IH.buildQueryString=vSe});var Ca=E(Vp=>{"use strict";var MH=St(),LH=jR(),I_=require("http"),D_=require("https"),BH=require("stream"),UR=require("http2"),CSe=["ECONNRESET","EPIPE","ETIMEDOUT"],FH=e=>{let t={};for(let r of Object.keys(e)){let n=e[r];t[r]=Array.isArray(n)?n.join(","):n}return t},jn={setTimeout:(e,t)=>setTimeout(e,t),clearTimeout:e=>clearTimeout(e)},DH=1e3,xSe=(e,t,r=0)=>{if(!r)return-1;let n=i=>{let o=jn.setTimeout(()=>{e.destroy(),t(Object.assign(new Error(`@smithy/node-http-handler - the request socket did not establish a connection with the server within the configured timeout of ${r} ms.`),{name:"TimeoutError"}))},r-i),s=a=>{a?.connecting?a.on("connect",()=>{jn.clearTimeout(o)}):jn.clearTimeout(o)};e.socket?s(e.socket):e.on("socket",s)};return r<2e3?(n(0),0):jn.setTimeout(n.bind(null,DH),DH)},TSe=(e,t,r=0,n,i)=>r?jn.setTimeout(()=>{let o=`@smithy/node-http-handler - [${n?"ERROR":"WARN"}] a request has exceeded the configured ${r} ms requestTimeout.`;if(n){let s=Object.assign(new Error(o),{name:"TimeoutError",code:"ETIMEDOUT"});e.destroy(s),t(s)}else o+=" Init client requestHandler with throwOnRequestTimeout=true to turn this into an error.",i?.warn?.(o)},r):-1,ASe=3e3,RSe=(e,{keepAlive:t,keepAliveMsecs:r},n=ASe)=>{if(t!==!0)return-1;let i=()=>{e.socket?e.socket.setKeepAlive(t,r||0):e.on("socket",o=>{o.setKeepAlive(t,r||0)})};return n===0?(i(),0):jn.setTimeout(i,n)},kH=3e3,PSe=(e,t,r=0)=>{let n=i=>{let o=r-i,s=()=>{e.destroy(),t(Object.assign(new Error(`@smithy/node-http-handler - the request socket timed out after ${r} ms of inactivity (configured by client requestHandler).`),{name:"TimeoutError"}))};e.socket?(e.socket.setTimeout(o,s),e.on("close",()=>e.socket?.removeListener("timeout",s))):e.setTimeout(o,s)};return 0<r&&r<6e3?(n(0),0):jn.setTimeout(n.bind(null,r===0?0:kH),kH)},NH=6e3;async function qH(e,t,r=NH,n=!1){let i=t.headers??{},o=i.Expect||i.expect,s=-1,a=!0;!n&&o==="100-continue"&&(a=await Promise.race([new Promise(c=>{s=Number(jn.setTimeout(()=>c(!0),Math.max(NH,r)))}),new Promise(c=>{e.on("continue",()=>{jn.clearTimeout(s),c(!0)}),e.on("response",()=>{jn.clearTimeout(s),c(!1)}),e.on("error",()=>{jn.clearTimeout(s),c(!1)})})])),a&&OSe(e,t.body)}function OSe(e,t){if(t instanceof BH.Readable){t.pipe(e);return}if(t){if(Buffer.isBuffer(t)||typeof t=="string"){e.end(t);return}let r=t;if(typeof r=="object"&&r.buffer&&typeof r.byteOffset=="number"&&typeof r.byteLength=="number"){e.end(Buffer.from(r.buffer,r.byteOffset,r.byteLength));return}e.end(Buffer.from(t));return}e.end()}var ISe=0,HR=class e{config;configProvider;socketWarningTimestamp=0;externalAgent=!1;metadata={handlerProtocol:"http/1.1"};static create(t){return typeof t?.handle=="function"?t:new e(t)}static checkSocketUsage(t,r,n=console){let{sockets:i,requests:o,maxSockets:s}=t;if(typeof s!="number"||s===1/0||Date.now()-15e3<r)return r;if(i&&o)for(let c in i){let u=i[c]?.length??0,l=o[c]?.length??0;if(u>=s&&l>=2*s)return n?.warn?.(`@smithy/node-http-handler:WARN - socket usage at capacity=${u} and ${l} additional requests are enqueued.
|
|
200
|
+
See https://docs.aws.amazon.com/sdk-for-javascript/v3/developer-guide/node-configuring-maxsockets.html
|
|
201
|
+
or increase socketAcquisitionWarningTimeout=(millis) in the NodeHttpHandler config.`),Date.now()}return r}constructor(t){this.configProvider=new Promise((r,n)=>{typeof t=="function"?t().then(i=>{r(this.resolveDefaultConfig(i))}).catch(n):r(this.resolveDefaultConfig(t))})}resolveDefaultConfig(t){let{requestTimeout:r,connectionTimeout:n,socketTimeout:i,socketAcquisitionWarningTimeout:o,httpAgent:s,httpsAgent:a,throwOnRequestTimeout:c}=t||{},u=!0,l=50;return{connectionTimeout:n,requestTimeout:r,socketTimeout:i,socketAcquisitionWarningTimeout:o,throwOnRequestTimeout:c,httpAgent:s instanceof I_.Agent||typeof s?.destroy=="function"?(this.externalAgent=!0,s):new I_.Agent({keepAlive:u,maxSockets:l,...s}),httpsAgent:a instanceof D_.Agent||typeof a?.destroy=="function"?(this.externalAgent=!0,a):new D_.Agent({keepAlive:u,maxSockets:l,...a}),logger:console}}destroy(){this.config?.httpAgent?.destroy(),this.config?.httpsAgent?.destroy()}async handle(t,{abortSignal:r,requestTimeout:n}={}){return this.config||(this.config=await this.configProvider),new Promise((i,o)=>{let s=this.config,a,c=[],u=async A=>{await a,c.forEach(jn.clearTimeout),i(A)},l=async A=>{await a,c.forEach(jn.clearTimeout),o(A)};if(r?.aborted){let A=new Error("Request aborted");A.name="AbortError",l(A);return}let d=t.protocol==="https:",h=t.headers??{},f=(h.Expect??h.expect)==="100-continue",p=d?s.httpsAgent:s.httpAgent;f&&!this.externalAgent&&(p=new(d?D_.Agent:I_.Agent)({keepAlive:!1,maxSockets:1/0})),c.push(jn.setTimeout(()=>{this.socketWarningTimestamp=e.checkSocketUsage(p,this.socketWarningTimestamp,s.logger)},s.socketAcquisitionWarningTimeout??(s.requestTimeout??2e3)+(s.connectionTimeout??1e3)));let m=LH.buildQueryString(t.query||{}),_;if(t.username!=null||t.password!=null){let A=t.username??"",D=t.password??"";_=`${A}:${D}`}let w=t.path;m&&(w+=`?${m}`),t.fragment&&(w+=`#${t.fragment}`);let R=t.hostname??"";R[0]==="["&&R.endsWith("]")?R=t.hostname.slice(1,-1):R=t.hostname;let v={headers:t.headers,host:R,method:t.method,path:w,port:t.port,agent:p,auth:_},S=(d?D_.request:I_.request)(v,A=>{let D=new MH.HttpResponse({statusCode:A.statusCode||-1,reason:A.statusMessage,headers:FH(A.headers),body:A});u({response:D})});if(S.on("error",A=>{CSe.includes(A.code)?l(Object.assign(A,{name:"TimeoutError"})):l(A)}),r){let A=()=>{S.destroy();let D=new Error("Request aborted");D.name="AbortError",l(D)};if(typeof r.addEventListener=="function"){let D=r;D.addEventListener("abort",A,{once:!0}),S.once("close",()=>D.removeEventListener("abort",A))}else r.onabort=A}let O=n??s.requestTimeout;c.push(xSe(S,l,s.connectionTimeout)),c.push(TSe(S,l,O,s.throwOnRequestTimeout,s.logger??console)),c.push(PSe(S,l,s.socketTimeout));let M=v.agent;typeof M=="object"&&"keepAlive"in M&&c.push(RSe(S,{keepAlive:M.keepAlive,keepAliveMsecs:M.keepAliveMsecs})),a=qH(S,t,O,this.externalAgent).catch(A=>(c.forEach(jn.clearTimeout),o(A)))})}updateHttpClientConfig(t,r){this.config=void 0,this.configProvider=this.configProvider.then(n=>({...n,[t]:r}))}httpHandlerConfigs(){return this.config??{}}},$R=class{sessions=[];constructor(t){this.sessions=t??[]}poll(){if(this.sessions.length>0)return this.sessions.shift()}offerLast(t){this.sessions.push(t)}contains(t){return this.sessions.includes(t)}remove(t){this.sessions=this.sessions.filter(r=>r!==t)}[Symbol.iterator](){return this.sessions[Symbol.iterator]()}destroy(t){for(let r of this.sessions)r===t&&(r.destroyed||r.destroy())}},GR=class{constructor(t){if(this.config=t,this.config.maxConcurrency&&this.config.maxConcurrency<=0)throw new RangeError("maxConcurrency must be greater than zero.")}config;sessionCache=new Map;lease(t,r){let n=this.getUrlString(t),i=this.sessionCache.get(n);if(i){let c=i.poll();if(c&&!this.config.disableConcurrency)return c}let o=UR.connect(n);this.config.maxConcurrency&&o.settings({maxConcurrentStreams:this.config.maxConcurrency},c=>{if(c)throw new Error("Fail to set maxConcurrentStreams to "+this.config.maxConcurrency+"when creating new session for "+t.destination.toString())}),o.unref();let s=()=>{o.destroy(),this.deleteSession(n,o)};o.on("goaway",s),o.on("error",s),o.on("frameError",s),o.on("close",()=>this.deleteSession(n,o)),r.requestTimeout&&o.setTimeout(r.requestTimeout,s);let a=this.sessionCache.get(n)||new $R;return a.offerLast(o),this.sessionCache.set(n,a),o}deleteSession(t,r){let n=this.sessionCache.get(t);n&&n.contains(r)&&(n.remove(r),this.sessionCache.set(t,n))}release(t,r){let n=this.getUrlString(t);this.sessionCache.get(n)?.offerLast(r)}destroy(){for(let[t,r]of this.sessionCache){for(let n of r)n.destroyed||n.destroy(),r.remove(n);this.sessionCache.delete(t)}}setMaxConcurrentStreams(t){if(t&&t<=0)throw new RangeError("maxConcurrentStreams must be greater than zero.");this.config.maxConcurrency=t}setDisableConcurrentStreams(t){this.config.disableConcurrency=t}getUrlString(t){return t.destination.toString()}},zR=class e{config;configProvider;metadata={handlerProtocol:"h2"};connectionManager=new GR({});static create(t){return typeof t?.handle=="function"?t:new e(t)}constructor(t){this.configProvider=new Promise((r,n)=>{typeof t=="function"?t().then(i=>{r(i||{})}).catch(n):r(t||{})})}destroy(){this.connectionManager.destroy()}async handle(t,{abortSignal:r,requestTimeout:n}={}){this.config||(this.config=await this.configProvider,this.connectionManager.setDisableConcurrentStreams(this.config.disableConcurrentStreams||!1),this.config.maxConcurrentStreams&&this.connectionManager.setMaxConcurrentStreams(this.config.maxConcurrentStreams));let{requestTimeout:i,disableConcurrentStreams:o}=this.config,s=n??i;return new Promise((a,c)=>{let u=!1,l,d=async I=>{await l,a(I)},h=async I=>{await l,c(I)};if(r?.aborted){u=!0;let I=new Error("Request aborted");I.name="AbortError",h(I);return}let{hostname:f,method:p,port:m,protocol:_,query:w}=t,R="";if(t.username!=null||t.password!=null){let I=t.username??"",N=t.password??"";R=`${I}:${N}@`}let v=`${_}//${R}${f}${m?`:${m}`:""}`,y={destination:new URL(v)},S=this.connectionManager.lease(y,{requestTimeout:this.config?.sessionTimeout,disableConcurrentStreams:o||!1}),O=I=>{o&&this.destroySession(S),u=!0,h(I)},M=LH.buildQueryString(w||{}),A=t.path;M&&(A+=`?${M}`),t.fragment&&(A+=`#${t.fragment}`);let D=S.request({...t.headers,[UR.constants.HTTP2_HEADER_PATH]:A,[UR.constants.HTTP2_HEADER_METHOD]:p});if(S.ref(),D.on("response",I=>{let N=new MH.HttpResponse({statusCode:I[":status"]||-1,headers:FH(I),body:D});u=!0,d({response:N}),o&&(S.close(),this.connectionManager.deleteSession(v,S))}),s&&D.setTimeout(s,()=>{D.close();let I=new Error(`Stream timed out because of no activity for ${s} ms`);I.name="TimeoutError",O(I)}),r){let I=()=>{D.close();let N=new Error("Request aborted");N.name="AbortError",O(N)};if(typeof r.addEventListener=="function"){let N=r;N.addEventListener("abort",I,{once:!0}),D.once("close",()=>N.removeEventListener("abort",I))}else r.onabort=I}D.on("frameError",(I,N,J)=>{O(new Error(`Frame type id ${I} in stream id ${J} has failed with code ${N}.`))}),D.on("error",O),D.on("aborted",()=>{O(new Error(`HTTP/2 stream is abnormally aborted in mid-communication with result code ${D.rstCode}.`))}),D.on("close",()=>{S.unref(),o&&S.destroy(),u||O(new Error("Unexpected error: http2 request did not get a response"))}),l=qH(D,t,s)})}updateHttpClientConfig(t,r){this.config=void 0,this.configProvider=this.configProvider.then(n=>({...n,[t]:r}))}httpHandlerConfigs(){return this.config??{}}destroySession(t){t.destroyed||t.destroy()}},VR=class extends BH.Writable{bufferedBytes=[];_write(t,r,n){this.bufferedBytes.push(t),n()}},DSe=e=>kSe(e)?NSe(e):new Promise((t,r)=>{let n=new VR;e.pipe(n),e.on("error",i=>{n.end(),r(i)}),n.on("error",r),n.on("finish",function(){let i=new Uint8Array(Buffer.concat(this.bufferedBytes));t(i)})}),kSe=e=>typeof ReadableStream=="function"&&e instanceof ReadableStream;async function NSe(e){let t=[],r=e.getReader(),n=!1,i=0;for(;!n;){let{done:a,value:c}=await r.read();c&&(t.push(c),i+=c.length),n=a}let o=new Uint8Array(i),s=0;for(let a of t)o.set(a,s),s+=a.length;return o}Vp.DEFAULT_REQUEST_TIMEOUT=ISe;Vp.NodeHttp2Handler=zR;Vp.NodeHttpHandler=HR;Vp.streamCollector=DSe});var HH=E(N_=>{"use strict";var jH=St(),MSe=jR(),LSe=Gr();function UH(e,t){return new Request(e,t)}function BSe(e=0){return new Promise((t,r)=>{e&&setTimeout(()=>{let n=new Error(`Request did not complete within ${e} ms`);n.name="TimeoutError",r(n)},e)})}var k_={supported:void 0},WR=class e{config;configProvider;static create(t){return typeof t?.handle=="function"?t:new e(t)}constructor(t){typeof t=="function"?this.configProvider=t().then(r=>r||{}):(this.config=t??{},this.configProvider=Promise.resolve(this.config)),k_.supported===void 0&&(k_.supported=typeof Request<"u"&&"keepalive"in UH("https://[::1]"))}destroy(){}async handle(t,{abortSignal:r,requestTimeout:n}={}){this.config||(this.config=await this.configProvider);let i=n??this.config.requestTimeout,o=this.config.keepAlive===!0,s=this.config.credentials;if(r?.aborted){let R=new Error("Request aborted");return R.name="AbortError",Promise.reject(R)}let a=t.path,c=MSe.buildQueryString(t.query||{});c&&(a+=`?${c}`),t.fragment&&(a+=`#${t.fragment}`);let u="";if(t.username!=null||t.password!=null){let R=t.username??"",v=t.password??"";u=`${R}:${v}@`}let{port:l,method:d}=t,h=`${t.protocol}//${u}${t.hostname}${l?`:${l}`:""}${a}`,f=d==="GET"||d==="HEAD"?void 0:t.body,p={body:f,headers:new Headers(t.headers),method:d,credentials:s};this.config?.cache&&(p.cache=this.config.cache),f&&(p.duplex="half"),typeof AbortController<"u"&&(p.signal=r),k_.supported&&(p.keepalive=o),typeof this.config.requestInit=="function"&&Object.assign(p,this.config.requestInit(t));let m=()=>{},_=UH(h,p),w=[fetch(_).then(R=>{let v=R.headers,y={};for(let O of v.entries())y[O[0]]=O[1];return R.body!=null?{response:new jH.HttpResponse({headers:y,reason:R.statusText,statusCode:R.status,body:R.body})}:R.blob().then(O=>({response:new jH.HttpResponse({headers:y,reason:R.statusText,statusCode:R.status,body:O})}))}),BSe(i)];return r&&w.push(new Promise((R,v)=>{let y=()=>{let S=new Error("Request aborted");S.name="AbortError",v(S)};if(typeof r.addEventListener=="function"){let S=r;S.addEventListener("abort",y,{once:!0}),m=()=>S.removeEventListener("abort",y)}else r.onabort=y})),Promise.race(w).finally(m)}updateHttpClientConfig(t,r){this.config=void 0,this.configProvider=this.configProvider.then(n=>(n[t]=r,n))}httpHandlerConfigs(){return this.config??{}}},FSe=async e=>typeof Blob=="function"&&e instanceof Blob||e.constructor?.name==="Blob"?Blob.prototype.arrayBuffer!==void 0?new Uint8Array(await e.arrayBuffer()):qSe(e):jSe(e);async function qSe(e){let t=await USe(e),r=LSe.fromBase64(t);return new Uint8Array(r)}async function jSe(e){let t=[],r=e.getReader(),n=!1,i=0;for(;!n;){let{done:a,value:c}=await r.read();c&&(t.push(c),i+=c.length),n=a}let o=new Uint8Array(i),s=0;for(let a of t)o.set(a,s),s+=a.length;return o}function USe(e){return new Promise((t,r)=>{let n=new FileReader;n.onloadend=()=>{if(n.readyState!==2)return r(new Error("Reader aborted too early"));let i=n.result??"",o=i.indexOf(","),s=o>-1?o+1:i.length;t(i.substring(s))},n.onabort=()=>r(new Error("Read aborted")),n.onerror=()=>r(n.error),n.readAsDataURL(e)})}N_.FetchHttpHandler=WR;N_.keepAliveSupport=k_;N_.streamCollector=FSe});var M_=E(YR=>{"use strict";var $H={},KR={};for(let e=0;e<256;e++){let t=e.toString(16).toLowerCase();t.length===1&&(t=`0${t}`),$H[e]=t,KR[t]=e}function HSe(e){if(e.length%2!==0)throw new Error("Hex encoded strings must have an even number length");let t=new Uint8Array(e.length/2);for(let r=0;r<e.length;r+=2){let n=e.slice(r,r+2).toLowerCase();if(n in KR)t[r/2]=KR[n];else throw new Error(`Cannot decode unrecognized sequence ${n} as hexadecimal`)}return t}function $Se(e){let t="";for(let r=0;r<e.byteLength;r++)t+=$H[e[r]];return t}YR.fromHex=HSe;YR.toHex=$Se});var WH=E(L_=>{"use strict";Object.defineProperty(L_,"__esModule",{value:!0});L_.sdkStreamMixin=void 0;var GSe=HH(),zSe=Gr(),VSe=M_(),WSe=Cr(),GH=va(),zH="The stream has already been transformed.",KSe=e=>{if(!VH(e)&&!(0,GH.isReadableStream)(e)){let i=e?.__proto__?.constructor?.name||e;throw new Error(`Unexpected stream implementation, expect Blob or ReadableStream, got ${i}`)}let t=!1,r=async()=>{if(t)throw new Error(zH);return t=!0,await(0,GSe.streamCollector)(e)},n=i=>{if(typeof i.stream!="function")throw new Error(`Cannot transform payload Blob to web stream. Please make sure the Blob.stream() is polyfilled.
|
|
202
|
+
If you are using React Native, this API is not yet supported, see: https://react-native.canny.io/feature-requests/p/fetch-streaming-body`);return i.stream()};return Object.assign(e,{transformToByteArray:r,transformToString:async i=>{let o=await r();if(i==="base64")return(0,zSe.toBase64)(o);if(i==="hex")return(0,VSe.toHex)(o);if(i===void 0||i==="utf8"||i==="utf-8")return(0,WSe.toUtf8)(o);if(typeof TextDecoder=="function")return new TextDecoder(i).decode(o);throw new Error("TextDecoder is not available, please make sure polyfill is provided.")},transformToWebStream:()=>{if(t)throw new Error(zH);if(t=!0,VH(e))return n(e);if((0,GH.isReadableStream)(e))return e;throw new Error(`Cannot transform payload to web stream, got ${e}`)}})};L_.sdkStreamMixin=KSe;var VH=e=>typeof Blob=="function"&&e instanceof Blob});var YH=E(B_=>{"use strict";Object.defineProperty(B_,"__esModule",{value:!0});B_.sdkStreamMixin=void 0;var YSe=Ca(),XSe=Fl(),XR=require("stream"),JSe=WH(),KH="The stream has already been transformed.",QSe=e=>{if(!(e instanceof XR.Readable))try{return(0,JSe.sdkStreamMixin)(e)}catch{let i=e?.__proto__?.constructor?.name||e;throw new Error(`Unexpected stream implementation, expect Stream.Readable instance, got ${i}`)}let t=!1,r=async()=>{if(t)throw new Error(KH);return t=!0,await(0,YSe.streamCollector)(e)};return Object.assign(e,{transformToByteArray:r,transformToString:async n=>{let i=await r();return n===void 0||Buffer.isEncoding(n)?(0,XSe.fromArrayBuffer)(i.buffer,i.byteOffset,i.byteLength).toString(n):new TextDecoder(n).decode(i)},transformToWebStream:()=>{if(t)throw new Error(KH);if(e.readableFlowing!==null)throw new Error("The stream has been consumed by other callbacks.");if(typeof XR.Readable.toWeb!="function")throw new Error("Readable.toWeb() is not supported. Please ensure a polyfill is available.");return t=!0,XR.Readable.toWeb(e)}})};B_.sdkStreamMixin=QSe});var XH=E(JR=>{"use strict";Object.defineProperty(JR,"__esModule",{value:!0});JR.splitStream=ZSe;async function ZSe(e){return typeof e.stream=="function"&&(e=e.stream()),e.tee()}});var ZH=E(QR=>{"use strict";Object.defineProperty(QR,"__esModule",{value:!0});QR.splitStream=tve;var JH=require("stream"),eve=XH(),QH=va();async function tve(e){if((0,QH.isReadableStream)(e)||(0,QH.isBlob)(e))return(0,eve.splitStream)(e);let t=new JH.PassThrough,r=new JH.PassThrough;return e.pipe(t),e.pipe(r),[t,r]}});var Jc=E(zr=>{"use strict";var e5=Gr(),t5=Cr(),r5=PR(),n5=EH(),i5=TH(),o5=AH(),s5=PH(),a5=YH(),c5=ZH(),u5=va(),ZR=class e extends Uint8Array{static fromString(t,r="utf-8"){if(typeof t=="string")return r==="base64"?e.mutate(e5.fromBase64(t)):e.mutate(t5.fromUtf8(t));throw new Error(`Unsupported conversion from ${typeof t} to Uint8ArrayBlobAdapter.`)}static mutate(t){return Object.setPrototypeOf(t,e.prototype),t}transformToString(t="utf-8"){return t==="base64"?e5.toBase64(this):t5.toUtf8(this)}};zr.Uint8ArrayBlobAdapter=ZR;Object.keys(r5).forEach(function(e){e!=="default"&&!Object.prototype.hasOwnProperty.call(zr,e)&&Object.defineProperty(zr,e,{enumerable:!0,get:function(){return r5[e]}})});Object.keys(n5).forEach(function(e){e!=="default"&&!Object.prototype.hasOwnProperty.call(zr,e)&&Object.defineProperty(zr,e,{enumerable:!0,get:function(){return n5[e]}})});Object.keys(i5).forEach(function(e){e!=="default"&&!Object.prototype.hasOwnProperty.call(zr,e)&&Object.defineProperty(zr,e,{enumerable:!0,get:function(){return i5[e]}})});Object.keys(o5).forEach(function(e){e!=="default"&&!Object.prototype.hasOwnProperty.call(zr,e)&&Object.defineProperty(zr,e,{enumerable:!0,get:function(){return o5[e]}})});Object.keys(s5).forEach(function(e){e!=="default"&&!Object.prototype.hasOwnProperty.call(zr,e)&&Object.defineProperty(zr,e,{enumerable:!0,get:function(){return s5[e]}})});Object.keys(a5).forEach(function(e){e!=="default"&&!Object.prototype.hasOwnProperty.call(zr,e)&&Object.defineProperty(zr,e,{enumerable:!0,get:function(){return a5[e]}})});Object.keys(c5).forEach(function(e){e!=="default"&&!Object.prototype.hasOwnProperty.call(zr,e)&&Object.defineProperty(zr,e,{enumerable:!0,get:function(){return c5[e]}})});Object.keys(u5).forEach(function(e){e!=="default"&&!Object.prototype.hasOwnProperty.call(zr,e)&&Object.defineProperty(zr,e,{enumerable:!0,get:function(){return u5[e]}})})});var F_,Ni,q_=Y(()=>{"use strict";F_=z(Jc()),Ni=async(e=new Uint8Array,t)=>{if(e instanceof Uint8Array)return F_.Uint8ArrayBlobAdapter.mutate(e);if(!e)return F_.Uint8ArrayBlobAdapter.mutate(new Uint8Array);let r=t.streamCollector(e);return F_.Uint8ArrayBlobAdapter.mutate(await r)}});function Mo(e){return encodeURIComponent(e).replace(/[!'()*]/g,function(t){return"%"+t.charCodeAt(0).toString(16).toUpperCase()})}var j_=Y(()=>{"use strict"});var io,eP=Y(()=>{"use strict";io=e=>typeof e=="function"?e():e});var Wp,U_=Y(()=>{"use strict";Wp=(e,t,r,n,i)=>({name:t,namespace:e,traits:r,input:n,output:i})});var l5,f5,d5,tP,p5=Y(()=>{"use strict";l5=z(St()),f5=z(an());U_();d5=e=>(t,r)=>async n=>{let{response:i}=await t(n),{operationSchema:o}=(0,f5.getSmithyContext)(r),[,s,a,c,u,l]=o??[];try{let d=await e.protocol.deserializeResponse(Wp(s,a,c,u,l),{...e,...r},i);return{response:i,output:d}}catch(d){if(Object.defineProperty(d,"$response",{value:i,enumerable:!1,writable:!1,configurable:!1}),!("$metadata"in d)){let h="Deserialization error: to see the raw response, inspect the hidden field {error}.$response on this object.";try{d.message+=`
|
|
203
|
+
`+h}catch{!r.logger||r.logger?.constructor?.name==="NoOpLogger"?console.warn(h):r.logger?.warn?.(h)}typeof d.$responseBodyText<"u"&&d.$response&&(d.$response.body=d.$responseBodyText);try{if(l5.HttpResponse.isInstance(i)){let{headers:f={}}=i,p=Object.entries(f);d.$metadata={httpStatusCode:i.statusCode,requestId:tP(/^x-[\w-]+-request-?id$/,p),extendedRequestId:tP(/^x-[\w-]+-id-2$/,p),cfId:tP(/^x-[\w-]+-cf-id$/,p)}}}catch{}}throw d}},tP=(e,t)=>(t.find(([r])=>r.match(e))||[void 0,void 0])[1]});var h5,m5,g5=Y(()=>{"use strict";h5=z(an());U_();m5=e=>(t,r)=>async n=>{let{operationSchema:i}=(0,h5.getSmithyContext)(r),[,o,s,a,c,u]=i??[],l=r.endpointV2?.url&&e.urlParser?async()=>e.urlParser(r.endpointV2.url):e.endpoint,d=await e.protocol.serializeRequest(Wp(o,s,a,c,u),n.input,{...e,...r,endpoint:l});return t({...n,request:d})}});function Qc(e){return{applyToStack:t=>{t.add(m5(e),_5),t.add(d5(e),y5),e.protocol.setSerdeContext(e)}}}var y5,_5,b5=Y(()=>{"use strict";p5();g5();y5={name:"deserializerMiddleware",step:"deserialize",tags:["DESERIALIZER"],override:!0},_5={name:"serializerMiddleware",step:"serialize",tags:["SERIALIZER"],override:!0}});var yr,xa=Y(()=>{"use strict";yr=class{name;namespace;traits;static assign(t,r){return Object.assign(t,r)}static[Symbol.hasInstance](t){let r=this.prototype.isPrototypeOf(t);return!r&&typeof t=="object"&&t!==null?t.symbol===this.symbol:r}getName(){return this.namespace+"#"+this.name}}});var H_,rve,E5=Y(()=>{"use strict";xa();H_=class e extends yr{static symbol=Symbol.for("@smithy/lis");name;traits;valueSchema;symbol=e.symbol},rve=(e,t,r,n)=>yr.assign(new H_,{name:t,namespace:e,traits:r,valueSchema:n})});var $_,nve,w5=Y(()=>{"use strict";xa();$_=class e extends yr{static symbol=Symbol.for("@smithy/map");name;traits;keySchema;valueSchema;symbol=e.symbol},nve=(e,t,r,n,i)=>yr.assign(new $_,{name:t,namespace:e,traits:r,keySchema:n,valueSchema:i})});var G_,ive,S5=Y(()=>{"use strict";xa();G_=class e extends yr{static symbol=Symbol.for("@smithy/ope");name;traits;input;output;symbol=e.symbol},ive=(e,t,r,n,i)=>yr.assign(new G_,{name:t,namespace:e,traits:r,input:n,output:i})});var Ul,ove,rP=Y(()=>{"use strict";xa();Ul=class e extends yr{static symbol=Symbol.for("@smithy/str");name;traits;memberNames;memberList;symbol=e.symbol},ove=(e,t,r,n,i)=>yr.assign(new Ul,{name:t,namespace:e,traits:r,memberNames:n,memberList:i})});var z_,sve,v5=Y(()=>{"use strict";xa();rP();z_=class e extends Ul{static symbol=Symbol.for("@smithy/err");ctor;symbol=e.symbol},sve=(e,t,r,n,i,o)=>yr.assign(new z_,{name:t,namespace:e,traits:r,memberNames:n,memberList:i,ctor:null})});function Lo(e){if(typeof e=="object")return e;e=e|0;let t={},r=0;for(let n of["httpLabel","idempotent","idempotencyToken","sensitive","httpPayload","httpResponseCode","httpQueryParams"])(e>>r++&1)===1&&(t[n]=1);return t}var nP=Y(()=>{"use strict"});function Kp(e,t){if(e instanceof ke)return Object.assign(e,{memberName:t,_isMemberSchema:!0});let r=ke;return new r(e,t)}var ke,iP,C5,x5=Y(()=>{"use strict";eP();nP();ke=class e{ref;memberName;static symbol=Symbol.for("@smithy/nor");symbol=e.symbol;name;schema;_isMemberSchema;traits;memberTraits;normalizedTraits;constructor(t,r){this.ref=t,this.memberName=r;let n=[],i=t,o=t;for(this._isMemberSchema=!1;iP(i);)n.push(i[1]),i=i[0],o=io(i),this._isMemberSchema=!0;if(n.length>0){this.memberTraits={};for(let s=n.length-1;s>=0;--s){let a=n[s];Object.assign(this.memberTraits,Lo(a))}}else this.memberTraits=0;if(o instanceof e){let s=this.memberTraits;Object.assign(this,o),this.memberTraits=Object.assign({},s,o.getMemberTraits(),this.getMemberTraits()),this.normalizedTraits=void 0,this.memberName=r??o.memberName;return}if(this.schema=io(o),C5(this.schema)?(this.name=`${this.schema[1]}#${this.schema[2]}`,this.traits=this.schema[3]):(this.name=this.memberName??String(o),this.traits=0),this._isMemberSchema&&!r)throw new Error(`@smithy/core/schema - NormalizedSchema member init ${this.getName(!0)} missing member name.`)}static[Symbol.hasInstance](t){let r=this.prototype.isPrototypeOf(t);return!r&&typeof t=="object"&&t!==null?t.symbol===this.symbol:r}static of(t){let r=io(t);if(r instanceof e)return r;if(iP(r)){let[n,i]=r;if(n instanceof e)return Object.assign(n.getMergedTraits(),Lo(i)),n;throw new Error(`@smithy/core/schema - may not init unwrapped member schema=${JSON.stringify(t,null,2)}.`)}return new e(r)}getSchema(){let t=this.schema;return t[0]===0?t[4]:t}getName(t=!1){let{name:r}=this;return!t&&r&&r.includes("#")?r.split("#")[1]:r||void 0}getMemberName(){return this.memberName}isMemberSchema(){return this._isMemberSchema}isListSchema(){let t=this.getSchema();return typeof t=="number"?t>=64&&t<128:t[0]===1}isMapSchema(){let t=this.getSchema();return typeof t=="number"?t>=128&&t<=255:t[0]===2}isStructSchema(){let t=this.getSchema();return t[0]===3||t[0]===-3}isBlobSchema(){let t=this.getSchema();return t===21||t===42}isTimestampSchema(){let t=this.getSchema();return typeof t=="number"&&t>=4&&t<=7}isUnitSchema(){return this.getSchema()==="unit"}isDocumentSchema(){return this.getSchema()===15}isStringSchema(){return this.getSchema()===0}isBooleanSchema(){return this.getSchema()===2}isNumericSchema(){return this.getSchema()===1}isBigIntegerSchema(){return this.getSchema()===17}isBigDecimalSchema(){return this.getSchema()===19}isStreaming(){let{streaming:t}=this.getMergedTraits();return!!t||this.getSchema()===42}isIdempotencyToken(){let t=o=>(o&4)===4||!!o?.idempotencyToken,{normalizedTraits:r,traits:n,memberTraits:i}=this;return t(r)||t(n)||t(i)}getMergedTraits(){return this.normalizedTraits??(this.normalizedTraits={...this.getOwnTraits(),...this.getMemberTraits()})}getMemberTraits(){return Lo(this.memberTraits)}getOwnTraits(){return Lo(this.traits)}getKeySchema(){let[t,r]=[this.isDocumentSchema(),this.isMapSchema()];if(!t&&!r)throw new Error(`@smithy/core/schema - cannot get key for non-map: ${this.getName(!0)}`);let n=this.getSchema(),i=t?15:n[4]??0;return Kp([i,0],"key")}getValueSchema(){let t=this.getSchema(),[r,n,i]=[this.isDocumentSchema(),this.isMapSchema(),this.isListSchema()],o=typeof t=="number"?63&t:t&&typeof t=="object"&&(n||i)?t[3+t[0]]:r?15:void 0;if(o!=null)return Kp([o,0],n?"value":"member");throw new Error(`@smithy/core/schema - ${this.getName(!0)} has no value member.`)}getMemberSchema(t){let r=this.getSchema();if(this.isStructSchema()&&r[4].includes(t)){let n=r[4].indexOf(t),i=r[5][n];return Kp(iP(i)?i:[i,0],t)}if(this.isDocumentSchema())return Kp([15,0],t);throw new Error(`@smithy/core/schema - ${this.getName(!0)} has no no member=${t}.`)}getMemberSchemas(){let t={};try{for(let[r,n]of this.structIterator())t[r]=n}catch{}return t}getEventStreamMember(){if(this.isStructSchema()){for(let[t,r]of this.structIterator())if(r.isStreaming()&&r.isStructSchema())return t}return""}*structIterator(){if(this.isUnitSchema())return;if(!this.isStructSchema())throw new Error("@smithy/core/schema - cannot iterate non-struct schema.");let t=this.getSchema();for(let r=0;r<t[4].length;++r)yield[t[4][r],Kp([t[5][r],0],t[4][r])]}};iP=e=>Array.isArray(e)&&e.length===2,C5=e=>Array.isArray(e)&&e.length>=5});var Yp,ave,cve,T5=Y(()=>{"use strict";xa();Yp=class e extends yr{static symbol=Symbol.for("@smithy/sim");name;schemaRef;traits;symbol=e.symbol},ave=(e,t,r,n)=>yr.assign(new Yp,{name:t,namespace:e,traits:n,schemaRef:r}),cve=(e,t,r,n)=>yr.assign(new Yp,{name:t,namespace:e,traits:r,schemaRef:n})});var uve,A5=Y(()=>{"use strict";uve={BLOB:21,STREAMING_BLOB:42,BOOLEAN:2,STRING:0,NUMERIC:1,BIG_INTEGER:17,BIG_DECIMAL:19,DOCUMENT:15,TIMESTAMP_DEFAULT:4,TIMESTAMP_DATE_TIME:5,TIMESTAMP_HTTP_DATE:6,TIMESTAMP_EPOCH_SECONDS:7,LIST_MODIFIER:64,MAP_MODIFIER:128}});var Ue,R5=Y(()=>{"use strict";Ue=class e{namespace;schemas;exceptions;static registries=new Map;constructor(t,r=new Map,n=new Map){this.namespace=t,this.schemas=r,this.exceptions=n}static for(t){return e.registries.has(t)||e.registries.set(t,new e(t)),e.registries.get(t)}register(t,r){let n=this.normalizeShapeId(t);e.for(n.split("#")[0]).schemas.set(n,r)}getSchema(t){let r=this.normalizeShapeId(t);if(!this.schemas.has(r))throw new Error(`@smithy/core/schema - schema not found for ${r}`);return this.schemas.get(r)}registerError(t,r){let n=t,i=e.for(n[1]);i.schemas.set(n[1]+"#"+n[2],n),i.exceptions.set(n,r)}getErrorCtor(t){let r=t;return e.for(r[1]).exceptions.get(r)}getBaseException(){for(let t of this.exceptions.keys())if(Array.isArray(t)){let[,r,n]=t,i=r+"#"+n;if(i.startsWith("smithy.ts.sdk.synthetic.")&&i.endsWith("ServiceException"))return t}}find(t){return[...this.schemas.values()].find(t)}clear(){this.schemas.clear(),this.exceptions.clear()}normalizeShapeId(t){return t.includes("#")?t:this.namespace+"#"+t}}});var V_={};Nn(V_,{ErrorSchema:()=>z_,ListSchema:()=>H_,MapSchema:()=>$_,NormalizedSchema:()=>ke,OperationSchema:()=>G_,SCHEMA:()=>uve,Schema:()=>yr,SimpleSchema:()=>Yp,StructureSchema:()=>Ul,TypeRegistry:()=>Ue,deref:()=>io,deserializerMiddlewareOption:()=>y5,error:()=>sve,getSchemaSerdePlugin:()=>Qc,isStaticSchema:()=>C5,list:()=>rve,map:()=>nve,op:()=>ive,operation:()=>Wp,serializerMiddlewareOption:()=>_5,sim:()=>ave,simAdapter:()=>cve,struct:()=>ove,translateTraits:()=>Lo});var xt=Y(()=>{"use strict";eP();b5();E5();w5();S5();U_();v5();x5();xa();T5();rP();A5();nP();R5()});var lve,P5=Y(()=>{"use strict";lve=(e,t,r=n=>n)=>e});var fve,dve,Xp,pve,W_,Jp,hve,oP,sP,aP,cP,mve,gve,O5,yve,_ve,Y_,bve,uP,Eve,Hl,lP,wve,Sve,vve,I5,D5,Cve,xve,Zc,fP,K_,Qp,dP=Y(()=>{"use strict";fve=e=>{switch(e){case"true":return!0;case"false":return!1;default:throw new Error(`Unable to parse boolean value "${e}"`)}},dve=e=>{if(e!=null){if(typeof e=="number"){if((e===0||e===1)&&Qp.warn(K_(`Expected boolean, got ${typeof e}: ${e}`)),e===0)return!1;if(e===1)return!0}if(typeof e=="string"){let t=e.toLowerCase();if((t==="false"||t==="true")&&Qp.warn(K_(`Expected boolean, got ${typeof e}: ${e}`)),t==="false")return!1;if(t==="true")return!0}if(typeof e=="boolean")return e;throw new TypeError(`Expected boolean, got ${typeof e}: ${e}`)}},Xp=e=>{if(e!=null){if(typeof e=="string"){let t=parseFloat(e);if(!Number.isNaN(t))return String(t)!==String(e)&&Qp.warn(K_(`Expected number but observed string: ${e}`)),t}if(typeof e=="number")return e;throw new TypeError(`Expected number, got ${typeof e}: ${e}`)}},pve=Math.ceil(34028234663852886e22),W_=e=>{let t=Xp(e);if(t!==void 0&&!Number.isNaN(t)&&t!==1/0&&t!==-1/0&&Math.abs(t)>pve)throw new TypeError(`Expected 32-bit float, got ${e}`);return t},Jp=e=>{if(e!=null){if(Number.isInteger(e)&&!Number.isNaN(e))return e;throw new TypeError(`Expected integer, got ${typeof e}: ${e}`)}},hve=Jp,oP=e=>cP(e,32),sP=e=>cP(e,16),aP=e=>cP(e,8),cP=(e,t)=>{let r=Jp(e);if(r!==void 0&&mve(r,t)!==r)throw new TypeError(`Expected ${t}-bit integer, got ${e}`);return r},mve=(e,t)=>{switch(t){case 32:return Int32Array.of(e)[0];case 16:return Int16Array.of(e)[0];case 8:return Int8Array.of(e)[0]}},gve=(e,t)=>{if(e==null)throw t?new TypeError(`Expected a non-null value for ${t}`):new TypeError("Expected a non-null value");return e},O5=e=>{if(e==null)return;if(typeof e=="object"&&!Array.isArray(e))return e;let t=Array.isArray(e)?"array":typeof e;throw new TypeError(`Expected object, got ${t}: ${e}`)},yve=e=>{if(e!=null){if(typeof e=="string")return e;if(["boolean","number","bigint"].includes(typeof e))return Qp.warn(K_(`Expected string, got ${typeof e}: ${e}`)),String(e);throw new TypeError(`Expected string, got ${typeof e}: ${e}`)}},_ve=e=>{if(e==null)return;let t=O5(e),r=Object.entries(t).filter(([,n])=>n!=null).map(([n])=>n);if(r.length===0)throw new TypeError("Unions must have exactly one non-null member. None were found.");if(r.length>1)throw new TypeError(`Unions must have exactly one non-null member. Keys ${r} were not null.`);return t},Y_=e=>Xp(typeof e=="string"?Hl(e):e),bve=Y_,uP=e=>W_(typeof e=="string"?Hl(e):e),Eve=/(-?(?:0|[1-9]\d*)(?:\.\d+)?(?:[eE][+-]?\d+)?)|(-?Infinity)|(NaN)/g,Hl=e=>{let t=e.match(Eve);if(t===null||t[0].length!==e.length)throw new TypeError("Expected real number, got implicit NaN");return parseFloat(e)},lP=e=>typeof e=="string"?I5(e):Xp(e),wve=lP,Sve=lP,vve=e=>typeof e=="string"?I5(e):W_(e),I5=e=>{switch(e){case"NaN":return NaN;case"Infinity":return 1/0;case"-Infinity":return-1/0;default:throw new Error(`Unable to parse float value: ${e}`)}},D5=e=>Jp(typeof e=="string"?Hl(e):e),Cve=D5,xve=e=>oP(typeof e=="string"?Hl(e):e),Zc=e=>sP(typeof e=="string"?Hl(e):e),fP=e=>aP(typeof e=="string"?Hl(e):e),K_=e=>String(new TypeError(e).stack||e).split(`
|
|
204
|
+
`).slice(0,5).filter(t=>!t.includes("stackTraceWarning")).join(`
|
|
205
|
+
`),Qp={warn:console.warn}});function eh(e){let t=e.getUTCFullYear(),r=e.getUTCMonth(),n=e.getUTCDay(),i=e.getUTCDate(),o=e.getUTCHours(),s=e.getUTCMinutes(),a=e.getUTCSeconds(),c=i<10?`0${i}`:`${i}`,u=o<10?`0${o}`:`${o}`,l=s<10?`0${s}`:`${s}`,d=a<10?`0${a}`:`${a}`;return`${Tve[n]}, ${c} ${hP[r]} ${t} ${u}:${l}:${d} GMT`}var Tve,hP,Ave,Rve,Pve,mP,Ove,Ive,Dve,gP,yP,Zp,kve,Nve,Mve,pP,Lve,Bve,Fve,Bo,qve,jve,$l,k5=Y(()=>{"use strict";dP();Tve=["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],hP=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];Ave=new RegExp(/^(\d{4})-(\d{2})-(\d{2})[tT](\d{2}):(\d{2}):(\d{2})(?:\.(\d+))?[zZ]$/),Rve=e=>{if(e==null)return;if(typeof e!="string")throw new TypeError("RFC-3339 date-times must be expressed as strings");let t=Ave.exec(e);if(!t)throw new TypeError("Invalid RFC-3339 date-time value");let[r,n,i,o,s,a,c,u]=t,l=Zc($l(n)),d=Bo(i,"month",1,12),h=Bo(o,"day",1,31);return Zp(l,d,h,{hours:s,minutes:a,seconds:c,fractionalMilliseconds:u})},Pve=new RegExp(/^(\d{4})-(\d{2})-(\d{2})[tT](\d{2}):(\d{2}):(\d{2})(?:\.(\d+))?(([-+]\d{2}\:\d{2})|[zZ])$/),mP=e=>{if(e==null)return;if(typeof e!="string")throw new TypeError("RFC-3339 date-times must be expressed as strings");let t=Pve.exec(e);if(!t)throw new TypeError("Invalid RFC-3339 date-time value");let[r,n,i,o,s,a,c,u,l]=t,d=Zc($l(n)),h=Bo(i,"month",1,12),f=Bo(o,"day",1,31),p=Zp(d,h,f,{hours:s,minutes:a,seconds:c,fractionalMilliseconds:u});return l.toUpperCase()!="Z"&&p.setTime(p.getTime()-jve(l)),p},Ove=new RegExp(/^(?:Mon|Tue|Wed|Thu|Fri|Sat|Sun), (\d{2}) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) (\d{4}) (\d{1,2}):(\d{2}):(\d{2})(?:\.(\d+))? GMT$/),Ive=new RegExp(/^(?:Monday|Tuesday|Wednesday|Thursday|Friday|Saturday|Sunday), (\d{2})-(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)-(\d{2}) (\d{1,2}):(\d{2}):(\d{2})(?:\.(\d+))? GMT$/),Dve=new RegExp(/^(?:Mon|Tue|Wed|Thu|Fri|Sat|Sun) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) ( [1-9]|\d{2}) (\d{1,2}):(\d{2}):(\d{2})(?:\.(\d+))? (\d{4})$/),gP=e=>{if(e==null)return;if(typeof e!="string")throw new TypeError("RFC-7231 date-times must be expressed as strings");let t=Ove.exec(e);if(t){let[r,n,i,o,s,a,c,u]=t;return Zp(Zc($l(o)),pP(i),Bo(n,"day",1,31),{hours:s,minutes:a,seconds:c,fractionalMilliseconds:u})}if(t=Ive.exec(e),t){let[r,n,i,o,s,a,c,u]=t;return Mve(Zp(kve(o),pP(i),Bo(n,"day",1,31),{hours:s,minutes:a,seconds:c,fractionalMilliseconds:u}))}if(t=Dve.exec(e),t){let[r,n,i,o,s,a,c,u]=t;return Zp(Zc($l(u)),pP(n),Bo(i.trimLeft(),"day",1,31),{hours:o,minutes:s,seconds:a,fractionalMilliseconds:c})}throw new TypeError("Invalid RFC-7231 date-time value")},yP=e=>{if(e==null)return;let t;if(typeof e=="number")t=e;else if(typeof e=="string")t=Y_(e);else if(typeof e=="object"&&e.tag===1)t=e.value;else throw new TypeError("Epoch timestamps must be expressed as floating point numbers or their string representation");if(Number.isNaN(t)||t===1/0||t===-1/0)throw new TypeError("Epoch timestamps must be valid, non-Infinite, non-NaN numerics");return new Date(Math.round(t*1e3))},Zp=(e,t,r,n)=>{let i=t-1;return Bve(e,i,r),new Date(Date.UTC(e,i,r,Bo(n.hours,"hour",0,23),Bo(n.minutes,"minute",0,59),Bo(n.seconds,"seconds",0,60),qve(n.fractionalMilliseconds)))},kve=e=>{let t=new Date().getUTCFullYear(),r=Math.floor(t/100)*100+Zc($l(e));return r<t?r+100:r},Nve=50*365*24*60*60*1e3,Mve=e=>e.getTime()-new Date().getTime()>Nve?new Date(Date.UTC(e.getUTCFullYear()-100,e.getUTCMonth(),e.getUTCDate(),e.getUTCHours(),e.getUTCMinutes(),e.getUTCSeconds(),e.getUTCMilliseconds())):e,pP=e=>{let t=hP.indexOf(e);if(t<0)throw new TypeError(`Invalid month: ${e}`);return t+1},Lve=[31,28,31,30,31,30,31,31,30,31,30,31],Bve=(e,t,r)=>{let n=Lve[t];if(t===1&&Fve(e)&&(n=29),r>n)throw new TypeError(`Invalid day for ${hP[t]} in ${e}: ${r}`)},Fve=e=>e%4===0&&(e%100!==0||e%400===0),Bo=(e,t,r,n)=>{let i=fP($l(e));if(i<r||i>n)throw new TypeError(`${t} must be between ${r} and ${n}, inclusive`);return i},qve=e=>e==null?0:uP("0."+e)*1e3,jve=e=>{let t=e[0],r=1;if(t=="+")r=1;else if(t=="-")r=-1;else throw new TypeError(`Offset direction, ${t}, must be "+" or "-"`);let n=Number(e.substring(1,3)),i=Number(e.substring(4,6));return r*(n*60+i)*60*1e3},$l=e=>{let t=0;for(;t<e.length-1&&e.charAt(t)==="0";)t++;return t===0?e:e.slice(t)}});var Fo={};Nn(Fo,{__addDisposableResource:()=>i6,__assign:()=>X_,__asyncDelegator:()=>X5,__asyncGenerator:()=>Y5,__asyncValues:()=>J5,__await:()=>Gl,__awaiter:()=>$5,__classPrivateFieldGet:()=>t6,__classPrivateFieldIn:()=>n6,__classPrivateFieldSet:()=>r6,__createBinding:()=>Q_,__decorate:()=>L5,__disposeResources:()=>o6,__esDecorate:()=>F5,__exportStar:()=>z5,__extends:()=>N5,__generator:()=>G5,__importDefault:()=>e6,__importStar:()=>Z5,__makeTemplateObject:()=>Q5,__metadata:()=>H5,__param:()=>B5,__propKey:()=>j5,__read:()=>EP,__rest:()=>M5,__rewriteRelativeImportExtension:()=>s6,__runInitializers:()=>q5,__setFunctionName:()=>U5,__spread:()=>V5,__spreadArray:()=>K5,__spreadArrays:()=>W5,__values:()=>J_,default:()=>$ve});function N5(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");_P(e,t);function r(){this.constructor=e}e.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}function M5(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,n=Object.getOwnPropertySymbols(e);i<n.length;i++)t.indexOf(n[i])<0&&Object.prototype.propertyIsEnumerable.call(e,n[i])&&(r[n[i]]=e[n[i]]);return r}function L5(e,t,r,n){var i=arguments.length,o=i<3?t:n===null?n=Object.getOwnPropertyDescriptor(t,r):n,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")o=Reflect.decorate(e,t,r,n);else for(var a=e.length-1;a>=0;a--)(s=e[a])&&(o=(i<3?s(o):i>3?s(t,r,o):s(t,r))||o);return i>3&&o&&Object.defineProperty(t,r,o),o}function B5(e,t){return function(r,n){t(r,n,e)}}function F5(e,t,r,n,i,o){function s(w){if(w!==void 0&&typeof w!="function")throw new TypeError("Function expected");return w}for(var a=n.kind,c=a==="getter"?"get":a==="setter"?"set":"value",u=!t&&e?n.static?e:e.prototype:null,l=t||(u?Object.getOwnPropertyDescriptor(u,n.name):{}),d,h=!1,f=r.length-1;f>=0;f--){var p={};for(var m in n)p[m]=m==="access"?{}:n[m];for(var m in n.access)p.access[m]=n.access[m];p.addInitializer=function(w){if(h)throw new TypeError("Cannot add initializers after decoration has completed");o.push(s(w||null))};var _=(0,r[f])(a==="accessor"?{get:l.get,set:l.set}:l[c],p);if(a==="accessor"){if(_===void 0)continue;if(_===null||typeof _!="object")throw new TypeError("Object expected");(d=s(_.get))&&(l.get=d),(d=s(_.set))&&(l.set=d),(d=s(_.init))&&i.unshift(d)}else(d=s(_))&&(a==="field"?i.unshift(d):l[c]=d)}u&&Object.defineProperty(u,n.name,l),h=!0}function q5(e,t,r){for(var n=arguments.length>2,i=0;i<t.length;i++)r=n?t[i].call(e,r):t[i].call(e);return n?r:void 0}function j5(e){return typeof e=="symbol"?e:"".concat(e)}function U5(e,t,r){return typeof t=="symbol"&&(t=t.description?"[".concat(t.description,"]"):""),Object.defineProperty(e,"name",{configurable:!0,value:r?"".concat(r," ",t):t})}function H5(e,t){if(typeof Reflect=="object"&&typeof Reflect.metadata=="function")return Reflect.metadata(e,t)}function $5(e,t,r,n){function i(o){return o instanceof r?o:new r(function(s){s(o)})}return new(r||(r=Promise))(function(o,s){function a(l){try{u(n.next(l))}catch(d){s(d)}}function c(l){try{u(n.throw(l))}catch(d){s(d)}}function u(l){l.done?o(l.value):i(l.value).then(a,c)}u((n=n.apply(e,t||[])).next())})}function G5(e,t){var r={label:0,sent:function(){if(o[0]&1)throw o[1];return o[1]},trys:[],ops:[]},n,i,o,s=Object.create((typeof Iterator=="function"?Iterator:Object).prototype);return s.next=a(0),s.throw=a(1),s.return=a(2),typeof Symbol=="function"&&(s[Symbol.iterator]=function(){return this}),s;function a(u){return function(l){return c([u,l])}}function c(u){if(n)throw new TypeError("Generator is already executing.");for(;s&&(s=0,u[0]&&(r=0)),r;)try{if(n=1,i&&(o=u[0]&2?i.return:u[0]?i.throw||((o=i.return)&&o.call(i),0):i.next)&&!(o=o.call(i,u[1])).done)return o;switch(i=0,o&&(u=[u[0]&2,o.value]),u[0]){case 0:case 1:o=u;break;case 4:return r.label++,{value:u[1],done:!1};case 5:r.label++,i=u[1],u=[0];continue;case 7:u=r.ops.pop(),r.trys.pop();continue;default:if(o=r.trys,!(o=o.length>0&&o[o.length-1])&&(u[0]===6||u[0]===2)){r=0;continue}if(u[0]===3&&(!o||u[1]>o[0]&&u[1]<o[3])){r.label=u[1];break}if(u[0]===6&&r.label<o[1]){r.label=o[1],o=u;break}if(o&&r.label<o[2]){r.label=o[2],r.ops.push(u);break}o[2]&&r.ops.pop(),r.trys.pop();continue}u=t.call(e,r)}catch(l){u=[6,l],i=0}finally{n=o=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}function z5(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&Q_(t,e,r)}function J_(e){var t=typeof Symbol=="function"&&Symbol.iterator,r=t&&e[t],n=0;if(r)return r.call(e);if(e&&typeof e.length=="number")return{next:function(){return e&&n>=e.length&&(e=void 0),{value:e&&e[n++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function EP(e,t){var r=typeof Symbol=="function"&&e[Symbol.iterator];if(!r)return e;var n=r.call(e),i,o=[],s;try{for(;(t===void 0||t-- >0)&&!(i=n.next()).done;)o.push(i.value)}catch(a){s={error:a}}finally{try{i&&!i.done&&(r=n.return)&&r.call(n)}finally{if(s)throw s.error}}return o}function V5(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(EP(arguments[t]));return e}function W5(){for(var e=0,t=0,r=arguments.length;t<r;t++)e+=arguments[t].length;for(var n=Array(e),i=0,t=0;t<r;t++)for(var o=arguments[t],s=0,a=o.length;s<a;s++,i++)n[i]=o[s];return n}function K5(e,t,r){if(r||arguments.length===2)for(var n=0,i=t.length,o;n<i;n++)(o||!(n in t))&&(o||(o=Array.prototype.slice.call(t,0,n)),o[n]=t[n]);return e.concat(o||Array.prototype.slice.call(t))}function Gl(e){return this instanceof Gl?(this.v=e,this):new Gl(e)}function Y5(e,t,r){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var n=r.apply(e,t||[]),i,o=[];return i=Object.create((typeof AsyncIterator=="function"?AsyncIterator:Object).prototype),a("next"),a("throw"),a("return",s),i[Symbol.asyncIterator]=function(){return this},i;function s(f){return function(p){return Promise.resolve(p).then(f,d)}}function a(f,p){n[f]&&(i[f]=function(m){return new Promise(function(_,w){o.push([f,m,_,w])>1||c(f,m)})},p&&(i[f]=p(i[f])))}function c(f,p){try{u(n[f](p))}catch(m){h(o[0][3],m)}}function u(f){f.value instanceof Gl?Promise.resolve(f.value.v).then(l,d):h(o[0][2],f)}function l(f){c("next",f)}function d(f){c("throw",f)}function h(f,p){f(p),o.shift(),o.length&&c(o[0][0],o[0][1])}}function X5(e){var t,r;return t={},n("next"),n("throw",function(i){throw i}),n("return"),t[Symbol.iterator]=function(){return this},t;function n(i,o){t[i]=e[i]?function(s){return(r=!r)?{value:Gl(e[i](s)),done:!1}:o?o(s):s}:o}}function J5(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],r;return t?t.call(e):(e=typeof J_=="function"?J_(e):e[Symbol.iterator](),r={},n("next"),n("throw"),n("return"),r[Symbol.asyncIterator]=function(){return this},r);function n(o){r[o]=e[o]&&function(s){return new Promise(function(a,c){s=e[o](s),i(a,c,s.done,s.value)})}}function i(o,s,a,c){Promise.resolve(c).then(function(u){o({value:u,done:a})},s)}}function Q5(e,t){return Object.defineProperty?Object.defineProperty(e,"raw",{value:t}):e.raw=t,e}function Z5(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r=bP(e),n=0;n<r.length;n++)r[n]!=="default"&&Q_(t,e,r[n]);return Uve(t,e),t}function e6(e){return e&&e.__esModule?e:{default:e}}function t6(e,t,r,n){if(r==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof t=="function"?e!==t||!n:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return r==="m"?n:r==="a"?n.call(e):n?n.value:t.get(e)}function r6(e,t,r,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof t=="function"?e!==t||!i:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(e,r):i?i.value=r:t.set(e,r),r}function n6(e,t){if(t===null||typeof t!="object"&&typeof t!="function")throw new TypeError("Cannot use 'in' operator on non-object");return typeof e=="function"?t===e:e.has(t)}function i6(e,t,r){if(t!=null){if(typeof t!="object"&&typeof t!="function")throw new TypeError("Object expected.");var n,i;if(r){if(!Symbol.asyncDispose)throw new TypeError("Symbol.asyncDispose is not defined.");n=t[Symbol.asyncDispose]}if(n===void 0){if(!Symbol.dispose)throw new TypeError("Symbol.dispose is not defined.");n=t[Symbol.dispose],r&&(i=n)}if(typeof n!="function")throw new TypeError("Object not disposable.");i&&(n=function(){try{i.call(this)}catch(o){return Promise.reject(o)}}),e.stack.push({value:t,dispose:n,async:r})}else r&&e.stack.push({async:!0});return t}function o6(e){function t(o){e.error=e.hasError?new Hve(o,e.error,"An error was suppressed during disposal."):o,e.hasError=!0}var r,n=0;function i(){for(;r=e.stack.pop();)try{if(!r.async&&n===1)return n=0,e.stack.push(r),Promise.resolve().then(i);if(r.dispose){var o=r.dispose.call(r.value);if(r.async)return n|=2,Promise.resolve(o).then(i,function(s){return t(s),i()})}else n|=1}catch(s){t(s)}if(n===1)return e.hasError?Promise.reject(e.error):Promise.resolve();if(e.hasError)throw e.error}return i()}function s6(e,t){return typeof e=="string"&&/^\.\.?\//.test(e)?e.replace(/\.(tsx)$|((?:\.d)?)((?:\.[^./]+?)?)\.([cm]?)ts$/i,function(r,n,i,o,s){return n?t?".jsx":".js":i&&(!o||!s)?r:i+o+"."+s.toLowerCase()+"js"}):e}var _P,X_,Q_,Uve,bP,Hve,$ve,qo=Y(()=>{"use strict";_P=function(e,t){return _P=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,n){r.__proto__=n}||function(r,n){for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(r[i]=n[i])},_P(e,t)};X_=function(){return X_=Object.assign||function(t){for(var r,n=1,i=arguments.length;n<i;n++){r=arguments[n];for(var o in r)Object.prototype.hasOwnProperty.call(r,o)&&(t[o]=r[o])}return t},X_.apply(this,arguments)};Q_=Object.create?(function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}):(function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]});Uve=Object.create?(function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}):function(e,t){e.default=t},bP=function(e){return bP=Object.getOwnPropertyNames||function(t){var r=[];for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(r[r.length]=n);return r},bP(e)};Hve=typeof SuppressedError=="function"?SuppressedError:function(e,t,r){var n=new Error(r);return n.name="SuppressedError",n.error=e,n.suppressed=t,n};$ve={__extends:N5,__assign:X_,__rest:M5,__decorate:L5,__param:B5,__esDecorate:F5,__runInitializers:q5,__propKey:j5,__setFunctionName:U5,__metadata:H5,__awaiter:$5,__generator:G5,__createBinding:Q_,__exportStar:z5,__values:J_,__read:EP,__spread:V5,__spreadArrays:W5,__spreadArray:K5,__await:Gl,__asyncGenerator:Y5,__asyncDelegator:X5,__asyncValues:J5,__makeTemplateObject:Q5,__importStar:Z5,__importDefault:e6,__classPrivateFieldGet:t6,__classPrivateFieldSet:r6,__classPrivateFieldIn:n6,__addDisposableResource:i6,__disposeResources:o6,__rewriteRelativeImportExtension:s6}});var c6=E(Z_=>{"use strict";Object.defineProperty(Z_,"__esModule",{value:!0});Z_.randomUUID=void 0;var Gve=(qo(),Ve(Fo)),a6=Gve.__importDefault(require("crypto"));Z_.randomUUID=a6.default.randomUUID.bind(a6.default)});var wP=E(l6=>{"use strict";var u6=c6(),En=Array.from({length:256},(e,t)=>t.toString(16).padStart(2,"0")),zve=()=>{if(u6.randomUUID)return u6.randomUUID();let e=new Uint8Array(16);return crypto.getRandomValues(e),e[6]=e[6]&15|64,e[8]=e[8]&63|128,En[e[0]]+En[e[1]]+En[e[2]]+En[e[3]]+"-"+En[e[4]]+En[e[5]]+"-"+En[e[6]]+En[e[7]]+"-"+En[e[8]]+En[e[9]]+"-"+En[e[10]]+En[e[11]]+En[e[12]]+En[e[13]]+En[e[14]]+En[e[15]]};l6.v4=zve});var Mi,f6=Y(()=>{"use strict";Mi=z(wP())});var Un,d6=Y(()=>{"use strict";Un=function(t){return Object.assign(new String(t),{deserializeJSON(){return JSON.parse(String(t))},toString(){return String(t)},toJSON(){return String(t)}})};Un.from=e=>e&&typeof e=="object"&&(e instanceof Un||"deserializeJSON"in e)?e:typeof e=="string"||Object.getPrototypeOf(e)===String.prototype?Un(String(e)):Un(JSON.stringify(e));Un.fromObject=Un.from});function SP(e){return(e.includes(",")||e.includes('"'))&&(e=`"${e.replace(/"/g,'\\"')}"`),e}var p6=Y(()=>{"use strict"});function Rs(e,t,r){let n=Number(e);if(n<t||n>r)throw new Error(`Value ${n} out of range [${t}, ${r}]`)}var vP,CP,xP,h6,m6,Vve,Wve,Kve,Yve,Xve,zl,TP,AP,g6=Y(()=>{"use strict";vP="(?:Mon|Tue|Wed|Thu|Fri|Sat|Sun)(?:[ne|u?r]?s?day)?",CP="(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)",xP="(\\d?\\d):(\\d{2}):(\\d{2})(?:\\.(\\d+))?",h6="(\\d?\\d)",m6="(\\d{4})",Vve=new RegExp(/^(\d{4})-(\d\d)-(\d\d)[tT](\d\d):(\d\d):(\d\d)(\.(\d+))?(([-+]\d\d:\d\d)|[zZ])$/),Wve=new RegExp(`^${vP}, ${h6} ${CP} ${m6} ${xP} GMT$`),Kve=new RegExp(`^${vP}, ${h6}-${CP}-(\\d\\d) ${xP} GMT$`),Yve=new RegExp(`^${vP} ${CP} ( [1-9]|\\d\\d) ${xP} ${m6}$`),Xve=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],zl=e=>{if(e==null)return;let t=NaN;if(typeof e=="number")t=e;else if(typeof e=="string"){if(!/^-?\d*\.?\d+$/.test(e))throw new TypeError("parseEpochTimestamp - numeric string invalid.");t=Number.parseFloat(e)}else typeof e=="object"&&e.tag===1&&(t=e.value);if(isNaN(t)||Math.abs(t)===1/0)throw new TypeError("Epoch timestamps must be valid finite numbers.");return new Date(Math.round(t*1e3))},TP=e=>{if(e==null)return;if(typeof e!="string")throw new TypeError("RFC3339 timestamps must be strings");let t=Vve.exec(e);if(!t)throw new TypeError(`Invalid RFC3339 timestamp format ${e}`);let[,r,n,i,o,s,a,,c,u]=t;Rs(n,1,12),Rs(i,1,31),Rs(o,0,23),Rs(s,0,59),Rs(a,0,60);let l=new Date(Date.UTC(Number(r),Number(n)-1,Number(i),Number(o),Number(s),Number(a),Number(c)?Math.round(parseFloat(`0.${c}`)*1e3):0));if(l.setUTCFullYear(Number(r)),u.toUpperCase()!="Z"){let[,d,h,f]=/([+-])(\d\d):(\d\d)/.exec(u)||[void 0,"+",0,0],p=d==="-"?1:-1;l.setTime(l.getTime()+p*(Number(h)*60*60*1e3+Number(f)*60*1e3))}return l},AP=e=>{if(e==null)return;if(typeof e!="string")throw new TypeError("RFC7231 timestamps must be strings.");let t,r,n,i,o,s,a,c;if((c=Wve.exec(e))?[,t,r,n,i,o,s,a]=c:(c=Kve.exec(e))?([,t,r,n,i,o,s,a]=c,n=(Number(n)+1900).toString()):(c=Yve.exec(e))&&([,r,t,i,o,s,a,n]=c),n&&s){let u=Date.UTC(Number(n),Xve.indexOf(r),Number(t),Number(i),Number(o),Number(s),a?Math.round(parseFloat(`0.${a}`)*1e3):0);Rs(t,1,31),Rs(i,0,23),Rs(o,0,59),Rs(s,0,60);let l=new Date(u);return l.setUTCFullYear(Number(n)),l}throw new TypeError(`Invalid RFC7231 date-time value ${e}.`)}});function RP(e,t,r){if(r<=0||!Number.isInteger(r))throw new Error("Invalid number of delimiters ("+r+") for splitEvery.");let n=e.split(t);if(r===1)return n;let i=[],o="";for(let s=0;s<n.length;s++)o===""?o=n[s]:o+=t+n[s],(s+1)%r===0&&(i.push(o),o="");return o!==""&&i.push(o),i}var y6=Y(()=>{"use strict"});var th,_6=Y(()=>{"use strict";th=e=>{let t=e.length,r=[],n=!1,i,o=0;for(let s=0;s<t;++s){let a=e[s];switch(a){case'"':i!=="\\"&&(n=!n);break;case",":n||(r.push(e.slice(o,s)),o=s+1);break;default:}i=a}return r.push(e.slice(o)),r.map(s=>{s=s.trim();let a=s.length;return a<2?s:(s[0]==='"'&&s[a-1]==='"'&&(s=s.slice(1,a-1)),s.replace(/\\"/g,'"'))})}});function PP(e){return new tr(String(e),"bigDecimal")}var b6,tr,E6=Y(()=>{"use strict";b6=/^-?\d*(\.\d+)?$/,tr=class e{string;type;constructor(t,r){if(this.string=t,this.type=r,!b6.test(t))throw new Error('@smithy/core/serde - NumericValue must only contain [0-9], at most one decimal point ".", and an optional negation prefix "-".')}toString(){return this.string}static[Symbol.hasInstance](t){if(!t||typeof t!="object")return!1;let r=t;return e.prototype.isPrototypeOf(t)||r.type==="bigDecimal"&&b6.test(r.string)}}});var w6={};Nn(w6,{LazyJsonString:()=>Un,NumericValue:()=>tr,_parseEpochTimestamp:()=>zl,_parseRfc3339DateTimeWithOffset:()=>TP,_parseRfc7231DateTime:()=>AP,copyDocumentWithTransform:()=>lve,dateToUtcString:()=>eh,expectBoolean:()=>dve,expectByte:()=>aP,expectFloat32:()=>W_,expectInt:()=>hve,expectInt32:()=>oP,expectLong:()=>Jp,expectNonNull:()=>gve,expectNumber:()=>Xp,expectObject:()=>O5,expectShort:()=>sP,expectString:()=>yve,expectUnion:()=>_ve,generateIdempotencyToken:()=>Mi.v4,handleFloat:()=>wve,limitedParseDouble:()=>lP,limitedParseFloat:()=>Sve,limitedParseFloat32:()=>vve,logger:()=>Qp,nv:()=>PP,parseBoolean:()=>fve,parseEpochTimestamp:()=>yP,parseRfc3339DateTime:()=>Rve,parseRfc3339DateTimeWithOffset:()=>mP,parseRfc7231DateTime:()=>gP,quoteHeader:()=>SP,splitEvery:()=>RP,splitHeader:()=>th,strictParseByte:()=>fP,strictParseDouble:()=>Y_,strictParseFloat:()=>bve,strictParseFloat32:()=>uP,strictParseInt:()=>Cve,strictParseInt32:()=>xve,strictParseLong:()=>D5,strictParseShort:()=>Zc});var ii=Y(()=>{"use strict";P5();k5();f6();d6();dP();p6();g6();y6();_6();E6()});var Hn,Vl=Y(()=>{"use strict";Hn=class{serdeContext;setSerdeContext(t){this.serdeContext=t}}});var eb,OP,S6=Y(()=>{"use strict";eb=z(Cr()),OP=class{marshaller;serializer;deserializer;serdeContext;defaultContentType;constructor({marshaller:t,serializer:r,deserializer:n,serdeContext:i,defaultContentType:o}){this.marshaller=t,this.serializer=r,this.deserializer=n,this.serdeContext=i,this.defaultContentType=o}async serializeEventStream({eventStream:t,requestSchema:r,initialRequest:n}){let i=this.marshaller,o=r.getEventStreamMember(),s=r.getMemberSchema(o),a=this.serializer,c=this.defaultContentType,u=Symbol("initialRequestMarker"),l={async*[Symbol.asyncIterator](){if(n){let d={":event-type":{type:"string",value:"initial-request"},":message-type":{type:"string",value:"event"},":content-type":{type:"string",value:c}};a.write(r,n);let h=a.flush();yield{[u]:!0,headers:d,body:h}}for await(let d of t)yield d}};return i.serialize(l,d=>{if(d[u])return{headers:d.headers,body:d.body};let h=Object.keys(d).find(R=>R!=="__type")??"",{additionalHeaders:f,body:p,eventType:m,explicitPayloadContentType:_}=this.writeEventBody(h,s,d);return{headers:{":event-type":{type:"string",value:m},":message-type":{type:"string",value:"event"},":content-type":{type:"string",value:_??c},...f},body:p}})}async deserializeEventStream({response:t,responseSchema:r,initialResponseContainer:n}){let i=this.marshaller,o=r.getEventStreamMember(),a=r.getMemberSchema(o).getMemberSchemas(),c=Symbol("initialResponseMarker"),u=i.deserialize(t.body,async h=>{let f=Object.keys(h).find(m=>m!=="__type")??"",p=h[f].body;if(f==="initial-response"){let m=await this.deserializer.read(r,p);return delete m[o],{[c]:!0,...m}}else if(f in a){let m=a[f];if(m.isStructSchema()){let _={},w=!1;for(let[R,v]of m.structIterator()){let{eventHeader:y,eventPayload:S}=v.getMergedTraits();if(w=w||!!(y||S),S)v.isBlobSchema()?_[R]=p:v.isStringSchema()?_[R]=(this.serdeContext?.utf8Encoder??eb.toUtf8)(p):v.isStructSchema()&&(_[R]=await this.deserializer.read(v,p));else if(y){let O=h[f].headers[R]?.value;O!=null&&(v.isNumericSchema()?O&&typeof O=="object"&&"bytes"in O?_[R]=BigInt(O.toString()):_[R]=Number(O):_[R]=O)}}if(w)return{[f]:_}}return{[f]:await this.deserializer.read(m,p)}}else return{$unknown:h}}),l=u[Symbol.asyncIterator](),d=await l.next();if(d.done)return u;if(d.value?.[c]){if(!r)throw new Error("@smithy::core/protocols - initial-response event encountered in event stream but no response schema given.");for(let[h,f]of Object.entries(d.value))n[h]=f}return{async*[Symbol.asyncIterator](){for(d?.value?.[c]||(yield d.value);;){let{done:h,value:f}=await l.next();if(h)break;yield f}}}}writeEventBody(t,r,n){let i=this.serializer,o=t,s=null,a,c=r.getSchema()[4].includes(t),u={};if(c){let h=r.getMemberSchema(t);if(h.isStructSchema()){for(let[f,p]of h.structIterator()){let{eventHeader:m,eventPayload:_}=p.getMergedTraits();if(_)s=f;else if(m){let w=n[t][f],R="binary";p.isNumericSchema()?(-2)**31<=w&&w<=2**31-1?R="integer":R="long":p.isTimestampSchema()?R="timestamp":p.isStringSchema()?R="string":p.isBooleanSchema()&&(R="boolean"),w!=null&&(u[f]={type:R,value:w},delete n[t][f])}}if(s!==null){let f=h.getMemberSchema(s);f.isBlobSchema()?a="application/octet-stream":f.isStringSchema()&&(a="text/plain"),i.write(f,n[t][s])}else i.write(h,n[t])}else throw new Error("@smithy/core/event-streams - non-struct member not supported in event stream union.")}else{let[h,f]=n[t];o=h,i.write(15,f)}let l=i.flush();return{body:typeof l=="string"?(this.serdeContext?.utf8Decoder??eb.fromUtf8)(l):l,eventType:o,explicitPayloadContentType:a,additionalHeaders:u}}}});var v6={};Nn(v6,{EventStreamSerde:()=>OP});var C6=Y(()=>{"use strict";S6()});var tb,eu,rb=Y(()=>{"use strict";xt();tb=z(St());Vl();eu=class extends Hn{options;constructor(t){super(),this.options=t}getRequestType(){return tb.HttpRequest}getResponseType(){return tb.HttpResponse}setSerdeContext(t){this.serdeContext=t,this.serializer.setSerdeContext(t),this.deserializer.setSerdeContext(t),this.getPayloadCodec()&&this.getPayloadCodec().setSerdeContext(t)}updateServiceEndpoint(t,r){if("url"in r){t.protocol=r.url.protocol,t.hostname=r.url.hostname,t.port=r.url.port?Number(r.url.port):void 0,t.path=r.url.pathname,t.fragment=r.url.hash||void 0,t.username=r.url.username||void 0,t.password=r.url.password||void 0,t.query||(t.query={});for(let[n,i]of r.url.searchParams.entries())t.query[n]=i;return t}else return t.protocol=r.protocol,t.hostname=r.hostname,t.port=r.port?Number(r.port):void 0,t.path=r.path,t.query={...r.query},t}setHostPrefix(t,r,n){let i=ke.of(r.input),o=Lo(r.traits??{});if(o.endpoint){let s=o.endpoint?.[0];if(typeof s=="string"){let a=[...i.structIterator()].filter(([,c])=>c.getMergedTraits().hostLabel);for(let[c]of a){let u=n[c];if(typeof u!="string")throw new Error(`@smithy/core/schema - ${c} in input must be a string as hostLabel.`);s=s.replace(`{${c}}`,u)}t.hostname=s+t.hostname}}}deserializeMetadata(t){return{httpStatusCode:t.statusCode,requestId:t.headers["x-amzn-requestid"]??t.headers["x-amzn-request-id"]??t.headers["x-amz-request-id"],extendedRequestId:t.headers["x-amz-id-2"],cfId:t.headers["x-amz-cf-id"]}}async serializeEventStream({eventStream:t,requestSchema:r,initialRequest:n}){return(await this.loadEventStreamCapability()).serializeEventStream({eventStream:t,requestSchema:r,initialRequest:n})}async deserializeEventStream({response:t,responseSchema:r,initialResponseContainer:n}){return(await this.loadEventStreamCapability()).deserializeEventStream({response:t,responseSchema:r,initialResponseContainer:n})}async loadEventStreamCapability(){let{EventStreamSerde:t}=await Promise.resolve().then(()=>(C6(),v6));return new t({marshaller:this.getEventStreamMarshaller(),serializer:this.serializer,deserializer:this.deserializer,serdeContext:this.serdeContext,defaultContentType:this.getDefaultContentType()})}getDefaultContentType(){throw new Error(`@smithy/core/protocols - ${this.constructor.name} getDefaultContentType() implementation missing.`)}async deserializeHttpMessage(t,r,n,i,o){return[]}getEventStreamMarshaller(){let t=this.serdeContext;if(!t.eventStreamMarshaller)throw new Error("@smithy/core - HttpProtocol: eventStreamMarshaller missing in serdeContext.");return t.eventStreamMarshaller}}});var x6,T6,tu,A6=Y(()=>{"use strict";xt();ii();x6=z(St()),T6=z(Jc());q_();j_();rb();tu=class extends eu{async serializeRequest(t,r,n){let i={...r??{}},o=this.serializer,s={},a={},c=await n.endpoint(),u=ke.of(t?.input),l=u.getSchema(),d=!1,h,f=new x6.HttpRequest({protocol:"",hostname:"",port:void 0,path:"",fragment:void 0,query:s,headers:a,body:void 0});if(c){this.updateServiceEndpoint(f,c),this.setHostPrefix(f,t,i);let p=Lo(t.traits);if(p.http){f.method=p.http[0];let[m,_]=p.http[1].split("?");f.path=="/"?f.path=m:f.path+=m;let w=new URLSearchParams(_??"");Object.assign(s,Object.fromEntries(w))}}for(let[p,m]of u.structIterator()){let _=m.getMergedTraits()??{},w=i[p];if(!(w==null&&!m.isIdempotencyToken()))if(_.httpPayload)m.isStreaming()?m.isStructSchema()?i[p]&&(h=await this.serializeEventStream({eventStream:i[p],requestSchema:u})):h=w:(o.write(m,w),h=o.flush()),delete i[p];else if(_.httpLabel){o.write(m,w);let R=o.flush();f.path.includes(`{${p}+}`)?f.path=f.path.replace(`{${p}+}`,R.split("/").map(Mo).join("/")):f.path.includes(`{${p}}`)&&(f.path=f.path.replace(`{${p}}`,Mo(R))),delete i[p]}else if(_.httpHeader)o.write(m,w),a[_.httpHeader.toLowerCase()]=String(o.flush()),delete i[p];else if(typeof _.httpPrefixHeaders=="string"){for(let[R,v]of Object.entries(w)){let y=_.httpPrefixHeaders+R;o.write([m.getValueSchema(),{httpHeader:y}],v),a[y.toLowerCase()]=o.flush()}delete i[p]}else _.httpQuery||_.httpQueryParams?(this.serializeQuery(m,w,s),delete i[p]):d=!0}return d&&i&&(o.write(l,i),h=o.flush()),f.headers=a,f.query=s,f.body=h,f}serializeQuery(t,r,n){let i=this.serializer,o=t.getMergedTraits();if(o.httpQueryParams){for(let[s,a]of Object.entries(r))if(!(s in n)){let c=t.getValueSchema();Object.assign(c.getMergedTraits(),{...o,httpQuery:s,httpQueryParams:void 0}),this.serializeQuery(c,a,n)}return}if(t.isListSchema()){let s=!!t.getMergedTraits().sparse,a=[];for(let c of r){i.write([t.getValueSchema(),o],c);let u=i.flush();(s||u!==void 0)&&a.push(u)}n[o.httpQuery]=a}else i.write([t,o],r),n[o.httpQuery]=i.flush()}async deserializeResponse(t,r,n){let i=this.deserializer,o=ke.of(t.output),s={};if(n.statusCode>=300){let c=await Ni(n.body,r);throw c.byteLength>0&&Object.assign(s,await i.read(15,c)),await this.handleError(t,r,n,s,this.deserializeMetadata(n)),new Error("@smithy/core/protocols - HTTP Protocol error handler failed to throw.")}for(let c in n.headers){let u=n.headers[c];delete n.headers[c],n.headers[c.toLowerCase()]=u}let a=await this.deserializeHttpMessage(o,r,n,s);if(a.length){let c=await Ni(n.body,r);if(c.byteLength>0){let u=await i.read(o,c);for(let l of a)s[l]=u[l]}}else a.discardResponseBody&&await Ni(n.body,r);return s.$metadata=this.deserializeMetadata(n),s}async deserializeHttpMessage(t,r,n,i,o){let s;i instanceof Set?s=o:s=i;let a=!0,c=this.deserializer,u=ke.of(t),l=[];for(let[d,h]of u.structIterator()){let f=h.getMemberTraits();if(f.httpPayload){if(a=!1,h.isStreaming())h.isStructSchema()?s[d]=await this.deserializeEventStream({response:n,responseSchema:u}):s[d]=(0,T6.sdkStreamMixin)(n.body);else if(n.body){let m=await Ni(n.body,r);m.byteLength>0&&(s[d]=await c.read(h,m))}}else if(f.httpHeader){let p=String(f.httpHeader).toLowerCase(),m=n.headers[p];if(m!=null)if(h.isListSchema()){let _=h.getValueSchema();_.getMergedTraits().httpHeader=p;let w;_.isTimestampSchema()&&_.getSchema()===4?w=RP(m,",",2):w=th(m);let R=[];for(let v of w)R.push(await c.read(_,v.trim()));s[d]=R}else s[d]=await c.read(h,m)}else if(f.httpPrefixHeaders!==void 0){s[d]={};for(let[p,m]of Object.entries(n.headers))if(p.startsWith(f.httpPrefixHeaders)){let _=h.getValueSchema();_.getMergedTraits().httpHeader=p,s[d][p.slice(f.httpPrefixHeaders.length)]=await c.read(_,m)}}else f.httpResponseCode?s[d]=n.statusCode:l.push(d)}return l.discardResponseBody=a,l}}});var R6,Ps,P6=Y(()=>{"use strict";xt();R6=z(St());q_();rb();Ps=class extends eu{async serializeRequest(t,r,n){let i=this.serializer,o={},s={},a=await n.endpoint(),c=ke.of(t?.input),u=c.getSchema(),l,d=new R6.HttpRequest({protocol:"",hostname:"",port:void 0,path:"/",fragment:void 0,query:o,headers:s,body:void 0});a&&(this.updateServiceEndpoint(d,a),this.setHostPrefix(d,t,r));let h={...r};if(r){let f=c.getEventStreamMember();if(f){if(h[f]){let p={};for(let[m,_]of c.structIterator())m!==f&&h[m]&&(i.write(_,h[m]),p[m]=i.flush());l=await this.serializeEventStream({eventStream:h[f],requestSchema:c,initialRequest:p})}}else i.write(u,h),l=i.flush()}return d.headers=s,d.query=o,d.body=l,d.method="POST",d}async deserializeResponse(t,r,n){let i=this.deserializer,o=ke.of(t.output),s={};if(n.statusCode>=300){let c=await Ni(n.body,r);throw c.byteLength>0&&Object.assign(s,await i.read(15,c)),await this.handleError(t,r,n,s,this.deserializeMetadata(n)),new Error("@smithy/core/protocols - RPC Protocol error handler failed to throw.")}for(let c in n.headers){let u=n.headers[c];delete n.headers[c],n.headers[c.toLowerCase()]=u}let a=o.getEventStreamMember();if(a)s[a]=await this.deserializeEventStream({response:n,responseSchema:o,initialResponseContainer:s});else{let c=await Ni(n.body,r);c.byteLength>0&&Object.assign(s,await i.read(o,c))}return s.$metadata=this.deserializeMetadata(n),s}}});var IP,DP=Y(()=>{"use strict";j_();IP=(e,t,r,n,i,o)=>{if(t!=null&&t[r]!==void 0){let s=n();if(s.length<=0)throw new Error("Empty value provided for input HTTP label: "+r+".");e=e.replace(i,o?s.split("/").map(a=>Mo(a)).join("/"):Mo(s))}else throw new Error("No value provided for input HTTP label: "+r+".");return e}});function kP(e,t){return new nb(e,t)}var O6,nb,I6=Y(()=>{"use strict";O6=z(St());DP();nb=class{input;context;query={};method="";headers={};path="";body=null;hostname="";resolvePathStack=[];constructor(t,r){this.input=t,this.context=r}async build(){let{hostname:t,protocol:r="https",port:n,path:i}=await this.context.endpoint();this.path=i;for(let o of this.resolvePathStack)o(this.path);return new O6.HttpRequest({protocol:r,hostname:this.hostname||t,port:n,method:this.method,path:this.path,query:this.query,body:this.body,headers:this.headers})}hn(t){return this.hostname=t,this}bp(t){return this.resolvePathStack.push(r=>{this.path=`${r?.endsWith("/")?r.slice(0,-1):r||""}`+t}),this}p(t,r,n,i){return this.resolvePathStack.push(o=>{this.path=IP(o,this.input,t,r,n,i)}),this}h(t){return this.headers=t,this}q(t){return this.query=t,this}b(t){return this.body=t,this}m(t){return this.method=t,this}}});function gi(e,t){if(t.timestampFormat.useTrait&&e.isTimestampSchema()&&(e.getSchema()===5||e.getSchema()===6||e.getSchema()===7))return e.getSchema();let{httpLabel:r,httpPrefixHeaders:n,httpHeader:i,httpQuery:o}=e.getMergedTraits();return(t.httpBindings?typeof n=="string"||i?6:o||r?5:void 0:void 0)??t.timestampFormat.default}var ib=Y(()=>{"use strict"});var NP,D6,ru,MP=Y(()=>{"use strict";xt();ii();NP=z(Gr()),D6=z(Cr());Vl();ib();ru=class extends Hn{settings;constructor(t){super(),this.settings=t}read(t,r){let n=ke.of(t);if(n.isListSchema())return th(r).map(i=>this.read(n.getValueSchema(),i));if(n.isBlobSchema())return(this.serdeContext?.base64Decoder??NP.fromBase64)(r);if(n.isTimestampSchema())switch(gi(n,this.settings)){case 5:return TP(r);case 6:return AP(r);case 7:return zl(r);default:return console.warn("Missing timestamp format, parsing value with Date constructor:",r),new Date(r)}if(n.isStringSchema()){let i=n.getMergedTraits().mediaType,o=r;if(i)return n.getMergedTraits().httpHeader&&(o=this.base64ToUtf8(o)),(i==="application/json"||i.endsWith("+json"))&&(o=Un.from(o)),o}return n.isNumericSchema()?Number(r):n.isBigIntegerSchema()?BigInt(r):n.isBigDecimalSchema()?new tr(r,"bigDecimal"):n.isBooleanSchema()?String(r).toLowerCase()==="true":r}base64ToUtf8(t){return(this.serdeContext?.utf8Encoder??D6.toUtf8)((this.serdeContext?.base64Decoder??NP.fromBase64)(t))}}});var ob,nu,k6=Y(()=>{"use strict";xt();ob=z(Cr());Vl();MP();nu=class extends Hn{codecDeserializer;stringDeserializer;constructor(t,r){super(),this.codecDeserializer=t,this.stringDeserializer=new ru(r)}setSerdeContext(t){this.stringDeserializer.setSerdeContext(t),this.codecDeserializer.setSerdeContext(t),this.serdeContext=t}read(t,r){let n=ke.of(t),i=n.getMergedTraits(),o=this.serdeContext?.utf8Encoder??ob.toUtf8;if(i.httpHeader||i.httpResponseCode)return this.stringDeserializer.read(n,o(r));if(i.httpPayload){if(n.isBlobSchema()){let s=this.serdeContext?.utf8Decoder??ob.fromUtf8;return typeof r=="string"?s(r):r}else if(n.isStringSchema())return"byteLength"in r?o(r):r}return this.codecDeserializer.read(n,r)}}});var LP,rh,BP=Y(()=>{"use strict";xt();ii();LP=z(Gr());Vl();ib();rh=class extends Hn{settings;stringBuffer="";constructor(t){super(),this.settings=t}write(t,r){let n=ke.of(t);switch(typeof r){case"object":if(r===null){this.stringBuffer="null";return}if(n.isTimestampSchema()){if(!(r instanceof Date))throw new Error(`@smithy/core/protocols - received non-Date value ${r} when schema expected Date in ${n.getName(!0)}`);switch(gi(n,this.settings)){case 5:this.stringBuffer=r.toISOString().replace(".000Z","Z");break;case 6:this.stringBuffer=eh(r);break;case 7:this.stringBuffer=String(r.getTime()/1e3);break;default:console.warn("Missing timestamp format, using epoch seconds",r),this.stringBuffer=String(r.getTime()/1e3)}return}if(n.isBlobSchema()&&"byteLength"in r){this.stringBuffer=(this.serdeContext?.base64Encoder??LP.toBase64)(r);return}if(n.isListSchema()&&Array.isArray(r)){let s="";for(let a of r){this.write([n.getValueSchema(),n.getMergedTraits()],a);let c=this.flush(),u=n.getValueSchema().isTimestampSchema()?c:SP(c);s!==""&&(s+=", "),s+=u}this.stringBuffer=s;return}this.stringBuffer=JSON.stringify(r,null,2);break;case"string":let i=n.getMergedTraits().mediaType,o=r;if(i&&((i==="application/json"||i.endsWith("+json"))&&(o=Un.from(o)),n.getMergedTraits().httpHeader)){this.stringBuffer=(this.serdeContext?.base64Encoder??LP.toBase64)(o.toString());return}this.stringBuffer=r;break;default:n.isIdempotencyToken()?this.stringBuffer=(0,Mi.v4)():this.stringBuffer=String(r)}}flush(){let t=this.stringBuffer;return this.stringBuffer="",t}}});var iu,N6=Y(()=>{"use strict";xt();BP();iu=class{codecSerializer;stringSerializer;buffer;constructor(t,r,n=new rh(r)){this.codecSerializer=t,this.stringSerializer=n}setSerdeContext(t){this.codecSerializer.setSerdeContext(t),this.stringSerializer.setSerdeContext(t)}write(t,r){let n=ke.of(t),i=n.getMergedTraits();if(i.httpHeader||i.httpLabel||i.httpQuery){this.stringSerializer.write(n,r),this.buffer=this.stringSerializer.flush();return}return this.codecSerializer.write(n,r)}flush(){if(this.buffer!==void 0){let t=this.buffer;return this.buffer=void 0,t}return this.codecSerializer.flush()}}});var M6={};Nn(M6,{FromStringShapeDeserializer:()=>ru,HttpBindingProtocol:()=>tu,HttpInterceptingShapeDeserializer:()=>nu,HttpInterceptingShapeSerializer:()=>iu,HttpProtocol:()=>eu,RequestBuilder:()=>nb,RpcProtocol:()=>Ps,SerdeContext:()=>Hn,ToStringShapeSerializer:()=>rh,collectBody:()=>Ni,determineTimestampFormat:()=>gi,extendedEncodeURIComponent:()=>Mo,requestBuilder:()=>kP,resolvedPath:()=>IP});var oi=Y(()=>{"use strict";q_();j_();A6();rb();P6();I6();DP();MP();k6();N6();BP();ib();Vl()});var L6=Y(()=>{"use strict";oi()});function Jve(e,t,r){e.__smithy_context?e.__smithy_context.features||(e.__smithy_context.features={}):e.__smithy_context={features:{}},e.__smithy_context.features[t]=r}var B6=Y(()=>{"use strict"});var Os,F6=Y(()=>{"use strict";Os=class{authSchemes=new Map;constructor(t){for(let[r,n]of Object.entries(t))n!==void 0&&this.authSchemes.set(r,n)}getIdentityProvider(t){return this.authSchemes.get(t)}}});var q6,FP,qP,j6=Y(()=>{"use strict";q6=z(St()),FP=z(Cs()),qP=class{async sign(t,r,n){if(!n)throw new Error("request could not be signed with `apiKey` since the `name` and `in` signer properties are missing");if(!n.name)throw new Error("request could not be signed with `apiKey` since the `name` signer property is missing");if(!n.in)throw new Error("request could not be signed with `apiKey` since the `in` signer property is missing");if(!r.apiKey)throw new Error("request could not be signed with `apiKey` since the `apiKey` is not defined");let i=q6.HttpRequest.clone(t);if(n.in===FP.HttpApiKeyAuthLocation.QUERY)i.query[n.name]=r.apiKey;else if(n.in===FP.HttpApiKeyAuthLocation.HEADER)i.headers[n.name]=n.scheme?`${n.scheme} ${r.apiKey}`:r.apiKey;else throw new Error("request can only be signed with `apiKey` locations `query` or `header`, but found: `"+n.in+"`");return i}}});var U6,jP,H6=Y(()=>{"use strict";U6=z(St()),jP=class{async sign(t,r,n){let i=U6.HttpRequest.clone(t);if(!r.token)throw new Error("request could not be signed with `token` since the `token` is not defined");return i.headers.Authorization=`Bearer ${r.token}`,i}}});var oo,$6=Y(()=>{"use strict";oo=class{async sign(t,r,n){return t}}});var G6=Y(()=>{"use strict";j6();H6();$6()});var z6,Qve,UP,sb,HP,V6=Y(()=>{"use strict";z6=e=>function(r){return sb(r)&&r.expiration.getTime()-Date.now()<e},Qve=3e5,UP=z6(3e5),sb=e=>e.expiration!==void 0,HP=(e,t,r)=>{if(e===void 0)return;let n=typeof e!="function"?async()=>Promise.resolve(e):e,i,o,s,a=!1,c=async u=>{o||(o=n(u));try{i=await o,s=!0,a=!1}finally{o=void 0}return i};return t===void 0?async u=>((!s||u?.forceRefresh)&&(i=await c(u)),i):async u=>((!s||u?.forceRefresh)&&(i=await c(u)),a?i:r(i)?(t(i)&&await c(u),i):(a=!0,i))}});var W6=Y(()=>{"use strict";F6();G6();V6()});var ou={};Nn(ou,{DefaultIdentityProviderConfig:()=>Os,EXPIRATION_MS:()=>Qve,HttpApiKeyAuthSigner:()=>qP,HttpBearerAuthSigner:()=>jP,NoAuthSigner:()=>oo,createIsIdentityExpiredFunction:()=>z6,createPaginator:()=>uH,doesIdentityRequireRefresh:()=>sb,getHttpAuthSchemeEndpointRuleSetPlugin:()=>Yc,getHttpAuthSchemePlugin:()=>Nwe,getHttpSigningPlugin:()=>Xc,getSmithyContext:()=>Rwe,httpAuthSchemeEndpointRuleSetMiddlewareOptions:()=>W4,httpAuthSchemeMiddleware:()=>Gp,httpAuthSchemeMiddlewareOptions:()=>eH,httpSigningMiddleware:()=>CR,httpSigningMiddlewareOptions:()=>oH,isIdentityExpired:()=>UP,memoizeIdentityProvider:()=>HP,normalizeProvider:()=>Sa,requestBuilder:()=>kP,setFeature:()=>Jve});var wn=Y(()=>{"use strict";H4();rH();aH();cH();lH();L6();B6();W6()});var Sn=E(su=>{"use strict";var Wl=class e extends Error{name="ProviderError";tryNextLink;constructor(t,r=!0){let n,i=!0;typeof r=="boolean"?(n=void 0,i=r):r!=null&&typeof r=="object"&&(n=r.logger,i=r.tryNextLink??!0),super(t),this.tryNextLink=i,Object.setPrototypeOf(this,e.prototype),n?.debug?.(`@smithy/property-provider ${i?"->":"(!)"} ${t}`)}static from(t,r=!0){return Object.assign(new this(t.message,r),t)}},$P=class e extends Wl{name="CredentialsProviderError";constructor(t,r=!0){super(t,r),Object.setPrototypeOf(this,e.prototype)}},GP=class e extends Wl{name="TokenProviderError";constructor(t,r=!0){super(t,r),Object.setPrototypeOf(this,e.prototype)}},Zve=(...e)=>async()=>{if(e.length===0)throw new Wl("No providers in chain");let t;for(let r of e)try{return await r()}catch(n){if(t=n,n?.tryNextLink)continue;throw n}throw t},eCe=e=>()=>Promise.resolve(e),tCe=(e,t,r)=>{let n,i,o,s=!1,a=async()=>{i||(i=e());try{n=await i,o=!0,s=!1}finally{i=void 0}return n};return t===void 0?async c=>((!o||c?.forceRefresh)&&(n=await a()),n):async c=>((!o||c?.forceRefresh)&&(n=await a()),s?n:r&&!r(n)?(s=!0,n):(t(n)&&await a(),n))};su.CredentialsProviderError=$P;su.ProviderError=Wl;su.TokenProviderError=GP;su.chain=Zve;su.fromStatic=eCe;su.memoize=tCe});var zP,K6,Y6,X6=Y(()=>{"use strict";wn();zP=z(Sn()),K6=e=>(e.sigv4aSigningRegionSet=Sa(e.sigv4aSigningRegionSet),e),Y6={environmentVariableSelector(e){if(e.AWS_SIGV4A_SIGNING_REGION_SET)return e.AWS_SIGV4A_SIGNING_REGION_SET.split(",").map(t=>t.trim());throw new zP.ProviderError("AWS_SIGV4A_SIGNING_REGION_SET not set in env.",{tryNextLink:!0})},configFileSelector(e){if(e.sigv4a_signing_region_set)return(e.sigv4a_signing_region_set??"").split(",").map(t=>t.trim());throw new zP.ProviderError("sigv4a_signing_region_set not set in profile.",{tryNextLink:!0})},default:void 0}});var hb=E(Xe=>{"use strict";var Ta=M_(),au=Cr(),rCe=E_(),e$=St(),J6=an(),ab=FR(),t$="X-Amz-Algorithm",r$="X-Amz-Credential",JP="X-Amz-Date",n$="X-Amz-SignedHeaders",i$="X-Amz-Expires",QP="X-Amz-Signature",ZP="X-Amz-Security-Token",nCe="X-Amz-Region-Set",eO="authorization",tO=JP.toLowerCase(),o$="date",s$=[eO,tO,o$],a$=QP.toLowerCase(),db="x-amz-content-sha256",c$=ZP.toLowerCase(),iCe="host",u$={authorization:!0,"cache-control":!0,connection:!0,expect:!0,from:!0,"keep-alive":!0,"max-forwards":!0,pragma:!0,referer:!0,te:!0,trailer:!0,"transfer-encoding":!0,upgrade:!0,"user-agent":!0,"x-amzn-trace-id":!0},l$=/^proxy-/,f$=/^sec-/,oCe=[/^proxy-/i,/^sec-/i],cb="AWS4-HMAC-SHA256",sCe="AWS4-ECDSA-P256-SHA256",d$="AWS4-HMAC-SHA256-PAYLOAD",p$="UNSIGNED-PAYLOAD",h$=50,rO="aws4_request",m$=3600*24*7,Kl={},ub=[],lb=(e,t,r)=>`${e}/${t}/${r}/${rO}`,g$=async(e,t,r,n,i)=>{let o=await Q6(e,t.secretAccessKey,t.accessKeyId),s=`${r}:${n}:${i}:${Ta.toHex(o)}:${t.sessionToken}`;if(s in Kl)return Kl[s];for(ub.push(s);ub.length>h$;)delete Kl[ub.shift()];let a=`AWS4${t.secretAccessKey}`;for(let c of[r,n,i,rO])a=await Q6(e,a,c);return Kl[s]=a},aCe=()=>{ub.length=0,Object.keys(Kl).forEach(e=>{delete Kl[e]})},Q6=(e,t,r)=>{let n=new e(t);return n.update(au.toUint8Array(r)),n.digest()},VP=({headers:e},t,r)=>{let n={};for(let i of Object.keys(e).sort()){if(e[i]==null)continue;let o=i.toLowerCase();(o in u$||t?.has(o)||l$.test(o)||f$.test(o))&&(!r||r&&!r.has(o))||(n[o]=e[i].trim().replace(/\s+/g," "))}return n},fb=async({headers:e,body:t},r)=>{for(let n of Object.keys(e))if(n.toLowerCase()===db)return e[n];if(t==null)return"e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855";if(typeof t=="string"||ArrayBuffer.isView(t)||rCe.isArrayBuffer(t)){let n=new r;return n.update(au.toUint8Array(t)),Ta.toHex(await n.digest())}return p$},WP=class{format(t){let r=[];for(let o of Object.keys(t)){let s=au.fromUtf8(o);r.push(Uint8Array.from([s.byteLength]),s,this.formatHeaderValue(t[o]))}let n=new Uint8Array(r.reduce((o,s)=>o+s.byteLength,0)),i=0;for(let o of r)n.set(o,i),i+=o.byteLength;return n}formatHeaderValue(t){switch(t.type){case"boolean":return Uint8Array.from([t.value?0:1]);case"byte":return Uint8Array.from([2,t.value]);case"short":let r=new DataView(new ArrayBuffer(3));return r.setUint8(0,3),r.setInt16(1,t.value,!1),new Uint8Array(r.buffer);case"integer":let n=new DataView(new ArrayBuffer(5));return n.setUint8(0,4),n.setInt32(1,t.value,!1),new Uint8Array(n.buffer);case"long":let i=new Uint8Array(9);return i[0]=5,i.set(t.value.bytes,1),i;case"binary":let o=new DataView(new ArrayBuffer(3+t.value.byteLength));o.setUint8(0,6),o.setUint16(1,t.value.byteLength,!1);let s=new Uint8Array(o.buffer);return s.set(t.value,3),s;case"string":let a=au.fromUtf8(t.value),c=new DataView(new ArrayBuffer(3+a.byteLength));c.setUint8(0,7),c.setUint16(1,a.byteLength,!1);let u=new Uint8Array(c.buffer);return u.set(a,3),u;case"timestamp":let l=new Uint8Array(9);return l[0]=8,l.set(KP.fromNumber(t.value.valueOf()).bytes,1),l;case"uuid":if(!cCe.test(t.value))throw new Error(`Invalid UUID received: ${t.value}`);let d=new Uint8Array(17);return d[0]=9,d.set(Ta.fromHex(t.value.replace(/\-/g,"")),1),d}}},cCe=/^[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}$/,KP=class e{bytes;constructor(t){if(this.bytes=t,t.byteLength!==8)throw new Error("Int64 buffers must be exactly 8 bytes")}static fromNumber(t){if(t>9223372036854776e3||t<-9223372036854776e3)throw new Error(`${t} is too large (or, if negative, too small) to represent as an Int64`);let r=new Uint8Array(8);for(let n=7,i=Math.abs(Math.round(t));n>-1&&i>0;n--,i/=256)r[n]=i;return t<0&&Z6(r),new e(r)}valueOf(){let t=this.bytes.slice(0),r=t[0]&128;return r&&Z6(t),parseInt(Ta.toHex(t),16)*(r?-1:1)}toString(){return String(this.valueOf())}};function Z6(e){for(let t=0;t<8;t++)e[t]^=255;for(let t=7;t>-1&&(e[t]++,e[t]===0);t--);}var y$=(e,t)=>{e=e.toLowerCase();for(let r of Object.keys(t))if(e===r.toLowerCase())return!0;return!1},_$=(e,t={})=>{let{headers:r,query:n={}}=e$.HttpRequest.clone(e);for(let i of Object.keys(r)){let o=i.toLowerCase();(o.slice(0,6)==="x-amz-"&&!t.unhoistableHeaders?.has(o)||t.hoistableHeaders?.has(o))&&(n[i]=r[i],delete r[i])}return{...e,headers:r,query:n}},YP=e=>{e=e$.HttpRequest.clone(e);for(let t of Object.keys(e.headers))s$.indexOf(t.toLowerCase())>-1&&delete e.headers[t];return e},b$=({query:e={}})=>{let t=[],r={};for(let n of Object.keys(e)){if(n.toLowerCase()===a$)continue;let i=ab.escapeUri(n);t.push(i);let o=e[n];typeof o=="string"?r[i]=`${i}=${ab.escapeUri(o)}`:Array.isArray(o)&&(r[i]=o.slice(0).reduce((s,a)=>s.concat([`${i}=${ab.escapeUri(a)}`]),[]).sort().join("&"))}return t.sort().map(n=>r[n]).filter(n=>n).join("&")},uCe=e=>lCe(e).toISOString().replace(/\.\d{3}Z$/,"Z"),lCe=e=>typeof e=="number"?new Date(e*1e3):typeof e=="string"?Number(e)?new Date(Number(e)*1e3):new Date(e):e,pb=class{service;regionProvider;credentialProvider;sha256;uriEscapePath;applyChecksum;constructor({applyChecksum:t,credentials:r,region:n,service:i,sha256:o,uriEscapePath:s=!0}){this.service=i,this.sha256=o,this.uriEscapePath=s,this.applyChecksum=typeof t=="boolean"?t:!0,this.regionProvider=J6.normalizeProvider(n),this.credentialProvider=J6.normalizeProvider(r)}createCanonicalRequest(t,r,n){let i=Object.keys(r).sort();return`${t.method}
|
|
206
|
+
${this.getCanonicalPath(t)}
|
|
207
|
+
${b$(t)}
|
|
208
|
+
${i.map(o=>`${o}:${r[o]}`).join(`
|
|
209
|
+
`)}
|
|
210
|
+
|
|
211
|
+
${i.join(";")}
|
|
212
|
+
${n}`}async createStringToSign(t,r,n,i){let o=new this.sha256;o.update(au.toUint8Array(n));let s=await o.digest();return`${i}
|
|
213
|
+
${t}
|
|
214
|
+
${r}
|
|
215
|
+
${Ta.toHex(s)}`}getCanonicalPath({path:t}){if(this.uriEscapePath){let r=[];for(let o of t.split("/"))o?.length!==0&&o!=="."&&(o===".."?r.pop():r.push(o));let n=`${t?.startsWith("/")?"/":""}${r.join("/")}${r.length>0&&t?.endsWith("/")?"/":""}`;return ab.escapeUri(n).replace(/%2F/g,"/")}return t}validateResolvedCredentials(t){if(typeof t!="object"||typeof t.accessKeyId!="string"||typeof t.secretAccessKey!="string")throw new Error("Resolved credential object is not valid")}formatDate(t){let r=uCe(t).replace(/[\-:]/g,"");return{longDate:r,shortDate:r.slice(0,8)}}getCanonicalHeaderList(t){return Object.keys(t).sort().join(";")}},XP=class extends pb{headerFormatter=new WP;constructor({applyChecksum:t,credentials:r,region:n,service:i,sha256:o,uriEscapePath:s=!0}){super({applyChecksum:t,credentials:r,region:n,service:i,sha256:o,uriEscapePath:s})}async presign(t,r={}){let{signingDate:n=new Date,expiresIn:i=3600,unsignableHeaders:o,unhoistableHeaders:s,signableHeaders:a,hoistableHeaders:c,signingRegion:u,signingService:l}=r,d=await this.credentialProvider();this.validateResolvedCredentials(d);let h=u??await this.regionProvider(),{longDate:f,shortDate:p}=this.formatDate(n);if(i>m$)return Promise.reject("Signature version 4 presigned URLs must have an expiration date less than one week in the future");let m=lb(p,h,l??this.service),_=_$(YP(t),{unhoistableHeaders:s,hoistableHeaders:c});d.sessionToken&&(_.query[ZP]=d.sessionToken),_.query[t$]=cb,_.query[r$]=`${d.accessKeyId}/${m}`,_.query[JP]=f,_.query[i$]=i.toString(10);let w=VP(_,o,a);return _.query[n$]=this.getCanonicalHeaderList(w),_.query[QP]=await this.getSignature(f,m,this.getSigningKey(d,h,p,l),this.createCanonicalRequest(_,w,await fb(t,this.sha256))),_}async sign(t,r){return typeof t=="string"?this.signString(t,r):t.headers&&t.payload?this.signEvent(t,r):t.message?this.signMessage(t,r):this.signRequest(t,r)}async signEvent({headers:t,payload:r},{signingDate:n=new Date,priorSignature:i,signingRegion:o,signingService:s}){let a=o??await this.regionProvider(),{shortDate:c,longDate:u}=this.formatDate(n),l=lb(c,a,s??this.service),d=await fb({headers:{},body:r},this.sha256),h=new this.sha256;h.update(t);let f=Ta.toHex(await h.digest()),p=[d$,u,l,i,f,d].join(`
|
|
216
|
+
`);return this.signString(p,{signingDate:n,signingRegion:a,signingService:s})}async signMessage(t,{signingDate:r=new Date,signingRegion:n,signingService:i}){return this.signEvent({headers:this.headerFormatter.format(t.message.headers),payload:t.message.body},{signingDate:r,signingRegion:n,signingService:i,priorSignature:t.priorSignature}).then(s=>({message:t.message,signature:s}))}async signString(t,{signingDate:r=new Date,signingRegion:n,signingService:i}={}){let o=await this.credentialProvider();this.validateResolvedCredentials(o);let s=n??await this.regionProvider(),{shortDate:a}=this.formatDate(r),c=new this.sha256(await this.getSigningKey(o,s,a,i));return c.update(au.toUint8Array(t)),Ta.toHex(await c.digest())}async signRequest(t,{signingDate:r=new Date,signableHeaders:n,unsignableHeaders:i,signingRegion:o,signingService:s}={}){let a=await this.credentialProvider();this.validateResolvedCredentials(a);let c=o??await this.regionProvider(),u=YP(t),{longDate:l,shortDate:d}=this.formatDate(r),h=lb(d,c,s??this.service);u.headers[tO]=l,a.sessionToken&&(u.headers[c$]=a.sessionToken);let f=await fb(u,this.sha256);!y$(db,u.headers)&&this.applyChecksum&&(u.headers[db]=f);let p=VP(u,i,n),m=await this.getSignature(l,h,this.getSigningKey(a,c,d,s),this.createCanonicalRequest(u,p,f));return u.headers[eO]=`${cb} Credential=${a.accessKeyId}/${h}, SignedHeaders=${this.getCanonicalHeaderList(p)}, Signature=${m}`,u}async getSignature(t,r,n,i){let o=await this.createStringToSign(t,r,i,cb),s=new this.sha256(await n);return s.update(au.toUint8Array(o)),Ta.toHex(await s.digest())}getSigningKey(t,r,n,i){return g$(this.sha256,t,n,r,i||this.service)}},fCe={SignatureV4a:null};Xe.ALGORITHM_IDENTIFIER=cb;Xe.ALGORITHM_IDENTIFIER_V4A=sCe;Xe.ALGORITHM_QUERY_PARAM=t$;Xe.ALWAYS_UNSIGNABLE_HEADERS=u$;Xe.AMZ_DATE_HEADER=tO;Xe.AMZ_DATE_QUERY_PARAM=JP;Xe.AUTH_HEADER=eO;Xe.CREDENTIAL_QUERY_PARAM=r$;Xe.DATE_HEADER=o$;Xe.EVENT_ALGORITHM_IDENTIFIER=d$;Xe.EXPIRES_QUERY_PARAM=i$;Xe.GENERATED_HEADERS=s$;Xe.HOST_HEADER=iCe;Xe.KEY_TYPE_IDENTIFIER=rO;Xe.MAX_CACHE_SIZE=h$;Xe.MAX_PRESIGNED_TTL=m$;Xe.PROXY_HEADER_PATTERN=l$;Xe.REGION_SET_PARAM=nCe;Xe.SEC_HEADER_PATTERN=f$;Xe.SHA256_HEADER=db;Xe.SIGNATURE_HEADER=a$;Xe.SIGNATURE_QUERY_PARAM=QP;Xe.SIGNED_HEADERS_QUERY_PARAM=n$;Xe.SignatureV4=XP;Xe.SignatureV4Base=pb;Xe.TOKEN_HEADER=c$;Xe.TOKEN_QUERY_PARAM=ZP;Xe.UNSIGNABLE_PATTERNS=oCe;Xe.UNSIGNED_PAYLOAD=p$;Xe.clearCredentialCache=aCe;Xe.createScope=lb;Xe.getCanonicalHeaders=VP;Xe.getCanonicalQuery=b$;Xe.getPayloadHash=fb;Xe.getSigningKey=g$;Xe.hasHeader=y$;Xe.moveHeadersToQuery=_$;Xe.prepareRequest=YP;Xe.signatureV4aContainer=fCe});function dCe(e,{credentials:t,credentialDefaultProvider:r}){let n;return t?t?.memoized?n=t:n=HP(t,UP,sb):r?n=Sa(r(Object.assign({},e,{parentClientConfig:e}))):n=async()=>{throw new Error("@aws-sdk/core::resolveAwsSdkSigV4Config - `credentials` not provided and no credentialDefaultProvider was configured.")},n.memoized=!0,n}function pCe(e,t){if(t.configBound)return t;let r=async n=>t({...n,callerClientConfig:e});return r.memoized=t.memoized,r.configBound=!0,r}var nO,Is,E$,w$=Y(()=>{"use strict";ki();wn();nO=z(hb()),Is=e=>{let t=e.credentials,r=!!e.credentials,n;Object.defineProperty(e,"credentials",{set(u){u&&u!==t&&u!==n&&(r=!0),t=u;let l=dCe(e,{credentials:t,credentialDefaultProvider:e.credentialDefaultProvider}),d=pCe(e,l);r&&!d.attributed?(n=async h=>d(h).then(f=>Ea(f,"CREDENTIALS_CODE","e")),n.memoized=d.memoized,n.configBound=d.configBound,n.attributed=!0):n=d},get(){return n},enumerable:!0,configurable:!0}),e.credentials=t;let{signingEscapePath:i=!0,systemClockOffset:o=e.systemClockOffset||0,sha256:s}=e,a;return e.signer?a=Sa(e.signer):e.regionInfoProvider?a=()=>Sa(e.region)().then(async u=>[await e.regionInfoProvider(u,{useFipsEndpoint:await e.useFipsEndpoint(),useDualstackEndpoint:await e.useDualstackEndpoint()})||{},u]).then(([u,l])=>{let{signingRegion:d,signingService:h}=u;e.signingRegion=e.signingRegion||d||l,e.signingName=e.signingName||h||e.serviceId;let f={...e,credentials:e.credentials,region:e.signingRegion,service:e.signingName,sha256:s,uriEscapePath:i},p=e.signerConstructor||nO.SignatureV4;return new p(f)}):a=async u=>{u=Object.assign({},{name:"sigv4",signingName:e.signingName||e.defaultSigningName,signingRegion:await Sa(e.region)(),properties:{}},u);let l=u.signingRegion,d=u.signingName;e.signingRegion=e.signingRegion||l,e.signingName=e.signingName||d||e.serviceId;let h={...e,credentials:e.credentials,region:e.signingRegion,service:e.signingName,sha256:s,uriEscapePath:i},f=e.signerConstructor||nO.SignatureV4;return new f(h)},Object.assign(e,{systemClockOffset:o,signingEscapePath:i,signer:a})},E$=Is});var S$=Y(()=>{"use strict";yR();B4();U4();X6();w$()});var v$={};Nn(v$,{AWSSDKSigV4Signer:()=>gR,AwsSdkSigV4ASigner:()=>$p,AwsSdkSigV4Signer:()=>bn,NODE_AUTH_SCHEME_PREFERENCE_OPTIONS:()=>wa,NODE_SIGV4A_CONFIG_OPTIONS:()=>Y6,getBearerTokenEnvKey:()=>__,resolveAWSSDKSigV4Config:()=>E$,resolveAwsSdkSigV4AConfig:()=>K6,resolveAwsSdkSigV4Config:()=>Is,validateSigningProperties:()=>Ll});var iO=Y(()=>{"use strict";S$();bR()});function Aa(e){return typeof Buffer<"u"?Buffer.alloc(e):new Uint8Array(e)}function mb(e){return e[oO]=!0,e}var oO,gb=Y(()=>{"use strict";oO=Symbol("@smithy/core/cbor::tagSymbol")});function T$(e){Ft=e,ks=new DataView(Ft.buffer,Ft.byteOffset,Ft.byteLength)}function jo(e,t){if(e>=t)throw new Error("unexpected end of (decode) payload.");let r=(Ft[e]&224)>>5,n=Ft[e]&31;switch(r){case 0:case 1:case 6:let i,o;if(n<24)i=n,o=1;else switch(n){case 24:case 25:case 26:case 27:let s=R$[n],a=s+1;if(o=a,t-e<a)throw new Error(`countLength ${s} greater than remaining buf len.`);let c=e+1;s===1?i=Ft[c]:s===2?i=ks.getUint16(c):s===4?i=ks.getUint32(c):i=ks.getBigUint64(c);break;default:throw new Error(`unexpected minor value ${n}.`)}if(r===0)return et=o,sO(i);if(r===1){let s;return typeof i=="bigint"?s=BigInt(-1)-i:s=-1-i,et=o,sO(s)}else if(n===2||n===3){let s=sh(e+o,t),a=BigInt(0),c=e+o+et;for(let u=c;u<c+s;++u)a=a<<BigInt(8)|BigInt(Ft[u]);return et=o+et+s,n===3?-a-BigInt(1):a}else if(n===4){let s=jo(e+o,t),[a,c]=s,u=c<0?-1:1,l="0".repeat(Math.abs(a)+1)+String(BigInt(u)*BigInt(c)),d,h=c<0?"-":"";return d=a===0?l:l.slice(0,l.length+a)+"."+l.slice(a),d=d.replace(/^0+/g,""),d===""&&(d="0"),d[0]==="."&&(d="0"+d),d=h+d,et=o+et,PP(d)}else{let s=jo(e+o,t);return et=o+et,mb({tag:sO(i),value:s})}case 3:case 5:case 4:case 2:if(n===31)switch(r){case 3:return ECe(e,t);case 5:return xCe(e,t);case 4:return vCe(e,t);case 2:return wCe(e,t)}else switch(r){case 3:return bCe(e,t);case 5:return CCe(e,t);case 4:return SCe(e,t);case 2:return dO(e,t)}default:return TCe(e,t)}}function A$(e,t,r){return gCe&&e.constructor?.name==="Buffer"?e.toString("utf-8",t,r):C$?C$.decode(e.subarray(t,r)):(0,x$.toUtf8)(e.subarray(t,r))}function yCe(e){let t=Number(e);return(t<Number.MIN_SAFE_INTEGER||Number.MAX_SAFE_INTEGER<t)&&console.warn(new Error(`@smithy/core/cbor - truncating BigInt(${e}) to ${t} with loss of precision.`)),t}function _Ce(e,t){let r=e>>7,n=(e&124)>>2,i=(e&3)<<8|t,o=r===0?1:-1,s,a;if(n===0){if(i===0)return 0;s=Math.pow(2,-14),a=0}else{if(n===31)return i===0?o*(1/0):NaN;s=Math.pow(2,n-15),a=1}return a+=i/1024,o*(s*a)}function sh(e,t){let r=Ft[e]&31;if(r<24)return et=1,r;if(r===24||r===25||r===26||r===27){let n=R$[r];if(et=n+1,t-e<et)throw new Error(`countLength ${n} greater than remaining buf len.`);let i=e+1;return n===1?Ft[i]:n===2?ks.getUint16(i):n===4?ks.getUint32(i):yCe(ks.getBigUint64(i))}throw new Error(`unexpected minor value ${r}.`)}function bCe(e,t){let r=sh(e,t),n=et;if(e+=n,t-e<r)throw new Error(`string len ${r} greater than remaining buf len.`);let i=A$(Ft,e,e+r);return et=n+r,i}function ECe(e,t){e+=1;let r=[];for(let n=e;e<t;){if(Ft[e]===255){let c=Aa(r.length);return c.set(r,0),et=e-n+2,A$(c,0,c.length)}let i=(Ft[e]&224)>>5,o=Ft[e]&31;if(i!==3)throw new Error(`unexpected major type ${i} in indefinite string.`);if(o===31)throw new Error("nested indefinite string.");let s=dO(e,t);e+=et;for(let c=0;c<s.length;++c)r.push(s[c])}throw new Error("expected break marker.")}function dO(e,t){let r=sh(e,t),n=et;if(e+=n,t-e<r)throw new Error(`unstructured byte string len ${r} greater than remaining buf len.`);let i=Ft.subarray(e,e+r);return et=n+r,i}function wCe(e,t){e+=1;let r=[];for(let n=e;e<t;){if(Ft[e]===255){let c=Aa(r.length);return c.set(r,0),et=e-n+2,c}let i=(Ft[e]&224)>>5,o=Ft[e]&31;if(i!==2)throw new Error(`unexpected major type ${i} in indefinite string.`);if(o===31)throw new Error("nested indefinite string.");let s=dO(e,t);e+=et;for(let c=0;c<s.length;++c)r.push(s[c])}throw new Error("expected break marker.")}function SCe(e,t){let r=sh(e,t),n=et;e+=n;let i=e,o=Array(r);for(let s=0;s<r;++s){let a=jo(e,t),c=et;o[s]=a,e+=c}return et=n+(e-i),o}function vCe(e,t){e+=1;let r=[];for(let n=e;e<t;){if(Ft[e]===255)return et=e-n+2,r;let i=jo(e,t);e+=et,r.push(i)}throw new Error("expected break marker.")}function CCe(e,t){let r=sh(e,t),n=et;e+=n;let i=e,o={};for(let s=0;s<r;++s){if(e>=t)throw new Error("unexpected end of map payload.");let a=(Ft[e]&224)>>5;if(a!==3)throw new Error(`unexpected major type ${a} for map key at index ${e}.`);let c=jo(e,t);e+=et;let u=jo(e,t);e+=et,o[c]=u}return et=n+(e-i),o}function xCe(e,t){e+=1;let r=e,n={};for(;e<t;){if(e>=t)throw new Error("unexpected end of map payload.");if(Ft[e]===255)return et=e-r+2,n;let i=(Ft[e]&224)>>5;if(i!==3)throw new Error(`unexpected major type ${i} for map key.`);let o=jo(e,t);e+=et;let s=jo(e,t);e+=et,n[o]=s}throw new Error("expected break marker.")}function TCe(e,t){let r=Ft[e]&31;switch(r){case 21:case 20:return et=1,r===21;case 22:return et=1,null;case 23:return et=1,null;case 25:if(t-e<3)throw new Error("incomplete float16 at end of buf.");return et=3,_Ce(Ft[e+1],Ft[e+2]);case 26:if(t-e<5)throw new Error("incomplete float32 at end of buf.");return et=5,ks.getFloat32(e+1);case 27:if(t-e<9)throw new Error("incomplete float64 at end of buf.");return et=9,ks.getFloat64(e+1);default:throw new Error(`unexpected minor value ${r}.`)}}function sO(e){if(typeof e=="number")return e;let t=Number(e);return Number.MIN_SAFE_INTEGER<=t&&t<=Number.MAX_SAFE_INTEGER?t:e}var x$,mCe,gCe,Ft,ks,C$,et,R$,P$=Y(()=>{"use strict";ii();x$=z(Cr());gb();mCe=typeof TextDecoder<"u",gCe=typeof Buffer<"u",Ft=Aa(0),ks=new DataView(Ft.buffer,Ft.byteOffset,Ft.byteLength),C$=mCe?new TextDecoder:null,et=0;R$={24:1,25:2,26:4,27:8}});function hO(e){He.byteLength-Me<e&&(Me<16e6?_b(Math.max(He.byteLength*4,He.byteLength+e)):_b(He.byteLength+e+16e6))}function mO(){let e=Aa(Me);return e.set(He.subarray(0,Me),0),Me=0,e}function _b(e){let t=He;He=Aa(e),t&&(t.copy?t.copy(He,0,0,t.byteLength):He.set(t,0)),Ls=new DataView(He.buffer,He.byteOffset,He.byteLength)}function Ms(e,t){t<24?He[Me++]=e<<5|t:t<256?(He[Me++]=e<<5|24,He[Me++]=t):t<65536?(He[Me++]=e<<5|25,Ls.setUint16(Me,t),Me+=2):t<2**32?(He[Me++]=e<<5|26,Ls.setUint32(Me,t),Me+=4):(He[Me++]=e<<5|27,Ls.setBigUint64(Me,typeof t=="bigint"?t:BigInt(t)),Me+=8)}function D$(e){let t=[e];for(;t.length;){let r=t.pop();if(hO(typeof r=="string"?r.length*4:64),typeof r=="string"){if(O$)Ms(3,Buffer.byteLength(r)),Me+=He.write(r,Me);else{let n=(0,I$.fromUtf8)(r);Ms(3,n.byteLength),He.set(n,Me),Me+=n.byteLength}continue}else if(typeof r=="number"){if(Number.isInteger(r)){let n=r>=0,i=n?0:1,o=n?r:-r-1;o<24?He[Me++]=i<<5|o:o<256?(He[Me++]=i<<5|24,He[Me++]=o):o<65536?(He[Me++]=i<<5|25,He[Me++]=o>>8,He[Me++]=o):o<4294967296?(He[Me++]=i<<5|26,Ls.setUint32(Me,o),Me+=4):(He[Me++]=i<<5|27,Ls.setBigUint64(Me,BigInt(o)),Me+=8);continue}He[Me++]=251,Ls.setFloat64(Me,r),Me+=8;continue}else if(typeof r=="bigint"){let n=r>=0,i=n?0:1,o=n?r:-r-BigInt(1),s=Number(o);if(s<24)He[Me++]=i<<5|s;else if(s<256)He[Me++]=i<<5|24,He[Me++]=s;else if(s<65536)He[Me++]=i<<5|25,He[Me++]=s>>8,He[Me++]=s&255;else if(s<4294967296)He[Me++]=i<<5|26,Ls.setUint32(Me,s),Me+=4;else if(o<BigInt("18446744073709551616"))He[Me++]=i<<5|27,Ls.setBigUint64(Me,o),Me+=8;else{let a=o.toString(2),c=new Uint8Array(Math.ceil(a.length/8)),u=o,l=0;for(;c.byteLength-++l>=0;)c[c.byteLength-l]=Number(u&BigInt(255)),u>>=BigInt(8);hO(c.byteLength*2),He[Me++]=n?194:195,O$?Ms(2,Buffer.byteLength(c)):Ms(2,c.byteLength),He.set(c,Me),Me+=c.byteLength}continue}else if(r===null){He[Me++]=246;continue}else if(typeof r=="boolean"){He[Me++]=224|(r?21:20);continue}else{if(typeof r>"u")throw new Error("@smithy/core/cbor: client may not serialize undefined value.");if(Array.isArray(r)){for(let n=r.length-1;n>=0;--n)t.push(r[n]);Ms(4,r.length);continue}else if(typeof r.byteLength=="number"){hO(r.length*2),Ms(2,r.length),He.set(r,Me),Me+=r.byteLength;continue}else if(typeof r=="object"){if(r instanceof tr){let i=r.string.indexOf("."),o=i===-1?0:i-r.string.length+1,s=BigInt(r.string.replace(".",""));He[Me++]=196,t.push(s),t.push(o),Ms(4,2);continue}if(r[oO])if("tag"in r&&"value"in r){t.push(r.value),Ms(6,r.tag);continue}else throw new Error("tag encountered with missing fields, need 'tag' and 'value', found: "+JSON.stringify(r));let n=Object.keys(r);for(let i=n.length-1;i>=0;--i){let o=n[i];t.push(r[o]),t.push(o)}Ms(5,n.length);continue}}throw new Error(`data type ${r?.constructor?.name??typeof r} not compatible for encoding.`)}}var I$,O$,ACe,He,Ls,Me,k$=Y(()=>{"use strict";ii();I$=z(Cr());gb();O$=typeof Buffer<"u",ACe=2048,He=Aa(ACe),Ls=new DataView(He.buffer,He.byteOffset,He.byteLength),Me=0});var gO,N$=Y(()=>{"use strict";P$();k$();gO={deserialize(e){return T$(e),jo(0,e.length)},serialize(e){try{return D$(e),mO()}catch(t){throw mO(),t}},resizeEncodingBuffer(e){_b(e)}}});var bb,Eb,wb=Y(()=>{"use strict";gb();bb=e=>mb({tag:1,value:e.getTime()/1e3}),Eb=(e,t)=>{let r=i=>{let o=i;return typeof o=="number"&&(o=o.toString()),o.indexOf(",")>=0&&(o=o.split(",")[0]),o.indexOf(":")>=0&&(o=o.split(":")[0]),o.indexOf("#")>=0&&(o=o.split("#")[1]),o};if(t.__type!==void 0)return r(t.__type);let n=Object.keys(t).find(i=>i.toLowerCase()==="code");if(n&&t[n]!==void 0)return r(t[n])}});var bO,Sb,yO,_O,EO=Y(()=>{"use strict";oi();xt();ii();bO=z(Gr());N$();wb();Sb=class extends Hn{createSerializer(){let t=new yO;return t.setSerdeContext(this.serdeContext),t}createDeserializer(){let t=new _O;return t.setSerdeContext(this.serdeContext),t}},yO=class extends Hn{value;write(t,r){this.value=this.serialize(t,r)}serialize(t,r){let n=ke.of(t);if(r==null)return n.isIdempotencyToken()?(0,Mi.v4)():r;if(n.isBlobSchema())return typeof r=="string"?(this.serdeContext?.base64Decoder??bO.fromBase64)(r):r;if(n.isTimestampSchema())return typeof r=="number"||typeof r=="bigint"?bb(new Date(Number(r)/1e3|0)):bb(r);if(typeof r=="function"||typeof r=="object"){let i=r;if(n.isListSchema()&&Array.isArray(i)){let s=!!n.getMergedTraits().sparse,a=[],c=0;for(let u of i){let l=this.serialize(n.getValueSchema(),u);(l!=null||s)&&(a[c++]=l)}return a}if(i instanceof Date)return bb(i);let o={};if(n.isMapSchema()){let s=!!n.getMergedTraits().sparse;for(let a of Object.keys(i)){let c=this.serialize(n.getValueSchema(),i[a]);(c!=null||s)&&(o[a]=c)}}else if(n.isStructSchema())for(let[s,a]of n.structIterator()){let c=this.serialize(a,i[s]);c!=null&&(o[s]=c)}else if(n.isDocumentSchema())for(let s of Object.keys(i))o[s]=this.serialize(n.getValueSchema(),i[s]);return o}return r}flush(){let t=gO.serialize(this.value);return this.value=void 0,t}},_O=class extends Hn{read(t,r){let n=gO.deserialize(r);return this.readValue(t,n)}readValue(t,r){let n=ke.of(t);if(n.isTimestampSchema()){if(typeof r=="number")return zl(r);if(typeof r=="object"&&r.tag===1&&"value"in r)return zl(r.value)}if(n.isBlobSchema())return typeof r=="string"?(this.serdeContext?.base64Decoder??bO.fromBase64)(r):r;if(typeof r>"u"||typeof r=="boolean"||typeof r=="number"||typeof r=="string"||typeof r=="bigint"||typeof r=="symbol")return r;if(typeof r=="object"){if(r===null)return null;if("byteLength"in r||r instanceof Date||n.isDocumentSchema())return r;if(n.isListSchema()){let o=[],s=n.getValueSchema(),a=!!n.getMergedTraits().sparse;for(let c of r){let u=this.readValue(s,c);(u!=null||a)&&o.push(u)}return o}let i={};if(n.isMapSchema()){let o=!!n.getMergedTraits().sparse,s=n.getValueSchema();for(let a of Object.keys(r)){let c=this.readValue(s,r[a]);(c!=null||o)&&(i[a]=c)}}else if(n.isStructSchema())for(let[o,s]of n.structIterator()){let a=this.readValue(s,r[o]);a!=null&&(i[o]=a)}return i}else return r}}});var M$,vb,L$=Y(()=>{"use strict";oi();xt();M$=z(an());EO();wb();vb=class extends Ps{codec=new Sb;serializer=this.codec.createSerializer();deserializer=this.codec.createDeserializer();constructor({defaultNamespace:t}){super({defaultNamespace:t})}getShapeId(){return"smithy.protocols#rpcv2Cbor"}getPayloadCodec(){return this.codec}async serializeRequest(t,r,n){let i=await super.serializeRequest(t,r,n);if(Object.assign(i.headers,{"content-type":this.getDefaultContentType(),"smithy-protocol":"rpc-v2-cbor",accept:this.getDefaultContentType()}),io(t.input)==="unit")delete i.body,delete i.headers["content-type"];else{i.body||(this.serializer.write(15,{}),i.body=this.serializer.flush());try{i.headers["content-length"]=String(i.body.byteLength)}catch{}}let{service:o,operation:s}=(0,M$.getSmithyContext)(n),a=`/service/${o}/operation/${s}`;return i.path.endsWith("/")?i.path+=a.slice(1):i.path+=a,i}async deserializeResponse(t,r,n){return super.deserializeResponse(t,r,n)}async handleError(t,r,n,i,o){let s=Eb(n,i)??"Unknown",a=this.options.defaultNamespace;s.includes("#")&&([a]=s.split("#"));let c={$metadata:o,$fault:n.statusCode<=500?"client":"server"},u=Ue.for(a),l;try{l=u.getSchema(s)}catch{i.Message&&(i.message=i.Message);let w=Ue.for("smithy.ts.sdk.synthetic."+a),R=w.getBaseException();if(R){let v=w.getErrorCtor(R);throw Object.assign(new v({name:s}),c,i)}throw Object.assign(new Error(s),c,i)}let d=ke.of(l),h=u.getErrorCtor(l),f=i.message??i.Message??"Unknown",p=new h(f),m={};for(let[_,w]of d.structIterator())m[_]=this.deserializer.readValue(w,i[_]);throw Object.assign(p,c,{$fault:d.getMergedTraits().error,message:f},m)}getDefaultContentType(){return"application/cbor"}}});var B$=Y(()=>{"use strict";wb();L$();EO()});var U$=E(j$=>{"use strict";var cu=(e,t)=>{let r=[];if(e&&r.push(e),t)for(let n of t)r.push(n);return r},Ia=(e,t)=>`${e||"anonymous"}${t&&t.length>0?` (a.k.a. ${t.join(",")})`:""}`,wO=()=>{let e=[],t=[],r=!1,n=new Set,i=d=>d.sort((h,f)=>F$[f.step]-F$[h.step]||q$[f.priority||"normal"]-q$[h.priority||"normal"]),o=d=>{let h=!1,f=p=>{let m=cu(p.name,p.aliases);if(m.includes(d)){h=!0;for(let _ of m)n.delete(_);return!1}return!0};return e=e.filter(f),t=t.filter(f),h},s=d=>{let h=!1,f=p=>{if(p.middleware===d){h=!0;for(let m of cu(p.name,p.aliases))n.delete(m);return!1}return!0};return e=e.filter(f),t=t.filter(f),h},a=d=>(e.forEach(h=>{d.add(h.middleware,{...h})}),t.forEach(h=>{d.addRelativeTo(h.middleware,{...h})}),d.identifyOnResolve?.(l.identifyOnResolve()),d),c=d=>{let h=[];return d.before.forEach(f=>{f.before.length===0&&f.after.length===0?h.push(f):h.push(...c(f))}),h.push(d),d.after.reverse().forEach(f=>{f.before.length===0&&f.after.length===0?h.push(f):h.push(...c(f))}),h},u=(d=!1)=>{let h=[],f=[],p={};return e.forEach(_=>{let w={..._,before:[],after:[]};for(let R of cu(w.name,w.aliases))p[R]=w;h.push(w)}),t.forEach(_=>{let w={..._,before:[],after:[]};for(let R of cu(w.name,w.aliases))p[R]=w;f.push(w)}),f.forEach(_=>{if(_.toMiddleware){let w=p[_.toMiddleware];if(w===void 0){if(d)return;throw new Error(`${_.toMiddleware} is not found when adding ${Ia(_.name,_.aliases)} middleware ${_.relation} ${_.toMiddleware}`)}_.relation==="after"&&w.after.push(_),_.relation==="before"&&w.before.push(_)}}),i(h).map(c).reduce((_,w)=>(_.push(...w),_),[])},l={add:(d,h={})=>{let{name:f,override:p,aliases:m}=h,_={step:"initialize",priority:"normal",middleware:d,...h},w=cu(f,m);if(w.length>0){if(w.some(R=>n.has(R))){if(!p)throw new Error(`Duplicate middleware name '${Ia(f,m)}'`);for(let R of w){let v=e.findIndex(S=>S.name===R||S.aliases?.some(O=>O===R));if(v===-1)continue;let y=e[v];if(y.step!==_.step||_.priority!==y.priority)throw new Error(`"${Ia(y.name,y.aliases)}" middleware with ${y.priority} priority in ${y.step} step cannot be overridden by "${Ia(f,m)}" middleware with ${_.priority} priority in ${_.step} step.`);e.splice(v,1)}}for(let R of w)n.add(R)}e.push(_)},addRelativeTo:(d,h)=>{let{name:f,override:p,aliases:m}=h,_={middleware:d,...h},w=cu(f,m);if(w.length>0){if(w.some(R=>n.has(R))){if(!p)throw new Error(`Duplicate middleware name '${Ia(f,m)}'`);for(let R of w){let v=t.findIndex(S=>S.name===R||S.aliases?.some(O=>O===R));if(v===-1)continue;let y=t[v];if(y.toMiddleware!==_.toMiddleware||y.relation!==_.relation)throw new Error(`"${Ia(y.name,y.aliases)}" middleware ${y.relation} "${y.toMiddleware}" middleware cannot be overridden by "${Ia(f,m)}" middleware ${_.relation} "${_.toMiddleware}" middleware.`);t.splice(v,1)}}for(let R of w)n.add(R)}t.push(_)},clone:()=>a(wO()),use:d=>{d.applyToStack(l)},remove:d=>typeof d=="string"?o(d):s(d),removeByTag:d=>{let h=!1,f=p=>{let{tags:m,name:_,aliases:w}=p;if(m&&m.includes(d)){let R=cu(_,w);for(let v of R)n.delete(v);return h=!0,!1}return!0};return e=e.filter(f),t=t.filter(f),h},concat:d=>{let h=a(wO());return h.use(d),h.identifyOnResolve(r||h.identifyOnResolve()||(d.identifyOnResolve?.()??!1)),h},applyToStack:a,identify:()=>u(!0).map(d=>{let h=d.step??d.relation+" "+d.toMiddleware;return Ia(d.name,d.aliases)+" - "+h}),identifyOnResolve(d){return typeof d=="boolean"&&(r=d),r},resolve:(d,h)=>{for(let f of u().map(p=>p.middleware).reverse())d=f(d,h);return r&&console.log(l.identify()),d}};return l},F$={initialize:5,serialize:4,build:3,finalizeRequest:2,deserialize:1},q$={high:3,normal:2,low:1};j$.constructStack=wO});var Ge=E(Nt=>{"use strict";var G$=U$(),OO=(oi(),Ve(M6)),vO=Cs(),RCe=(xt(),Ve(V_)),H$=(ii(),Ve(w6)),CO=class{config;middlewareStack=G$.constructStack();initConfig;handlers;constructor(t){this.config=t}send(t,r,n){let i=typeof r!="function"?r:void 0,o=typeof r=="function"?r:n,s=i===void 0&&this.config.cacheMiddleware===!0,a;if(s){this.handlers||(this.handlers=new WeakMap);let c=this.handlers;c.has(t.constructor)?a=c.get(t.constructor):(a=t.resolveMiddleware(this.middlewareStack,this.config,i),c.set(t.constructor,a))}else delete this.handlers,a=t.resolveMiddleware(this.middlewareStack,this.config,i);if(o)a(t).then(c=>o(null,c.output),c=>o(c)).catch(()=>{});else return a(t).then(c=>c.output)}destroy(){this.config?.requestHandler?.destroy?.(),delete this.handlers}},SO="***SensitiveInformation***";function xO(e,t){if(t==null)return t;let r=RCe.NormalizedSchema.of(e);if(r.getMergedTraits().sensitive)return SO;if(r.isListSchema()){if(!!r.getValueSchema().getMergedTraits().sensitive)return SO}else if(r.isMapSchema()){if(!!r.getKeySchema().getMergedTraits().sensitive||!!r.getValueSchema().getMergedTraits().sensitive)return SO}else if(r.isStructSchema()&&typeof t=="object"){let n=t,i={};for(let[o,s]of r.structIterator())n[o]!=null&&(i[o]=xO(s,n[o]));return i}return t}var Cb=class{middlewareStack=G$.constructStack();schema;static classBuilder(){return new TO}resolveMiddlewareWithContext(t,r,n,{middlewareFn:i,clientName:o,commandName:s,inputFilterSensitiveLog:a,outputFilterSensitiveLog:c,smithyContext:u,additionalContext:l,CommandCtor:d}){for(let _ of i.bind(this)(d,t,r,n))this.middlewareStack.use(_);let h=t.concat(this.middlewareStack),{logger:f}=r,p={logger:f,clientName:o,commandName:s,inputFilterSensitiveLog:a,outputFilterSensitiveLog:c,[vO.SMITHY_CONTEXT_KEY]:{commandInstance:this,...u},...l},{requestHandler:m}=r;return h.resolve(_=>m.handle(_.request,n||{}),p)}},TO=class{_init=()=>{};_ep={};_middlewareFn=()=>[];_commandName="";_clientName="";_additionalContext={};_smithyContext={};_inputFilterSensitiveLog=void 0;_outputFilterSensitiveLog=void 0;_serializer=null;_deserializer=null;_operationSchema;init(t){this._init=t}ep(t){return this._ep=t,this}m(t){return this._middlewareFn=t,this}s(t,r,n={}){return this._smithyContext={service:t,operation:r,...n},this}c(t={}){return this._additionalContext=t,this}n(t,r){return this._clientName=t,this._commandName=r,this}f(t=n=>n,r=n=>n){return this._inputFilterSensitiveLog=t,this._outputFilterSensitiveLog=r,this}ser(t){return this._serializer=t,this}de(t){return this._deserializer=t,this}sc(t){return this._operationSchema=t,this._smithyContext.operationSchema=t,this}build(){let t=this,r;return r=class extends Cb{input;static getEndpointParameterInstructions(){return t._ep}constructor(...[n]){super(),this.input=n??{},t._init(this),this.schema=t._operationSchema}resolveMiddleware(n,i,o){let s=t._operationSchema,a=s?.[4]??s?.input,c=s?.[5]??s?.output;return this.resolveMiddlewareWithContext(n,i,o,{CommandCtor:r,middlewareFn:t._middlewareFn,clientName:t._clientName,commandName:t._commandName,inputFilterSensitiveLog:t._inputFilterSensitiveLog??(s?xO.bind(null,a):u=>u),outputFilterSensitiveLog:t._outputFilterSensitiveLog??(s?xO.bind(null,c):u=>u),smithyContext:t._smithyContext,additionalContext:t._additionalContext})}serialize=t._serializer;deserialize=t._deserializer}}},PCe="***SensitiveInformation***",OCe=(e,t)=>{for(let r of Object.keys(e)){let n=e[r],i=async function(s,a,c){let u=new n(s);if(typeof a=="function")this.send(u,a);else if(typeof c=="function"){if(typeof a!="object")throw new Error(`Expected http options but got ${typeof a}`);this.send(u,a||{},c)}else return this.send(u,a)},o=(r[0].toLowerCase()+r.slice(1)).replace(/Command$/,"");t.prototype[o]=i}},AO=class e extends Error{$fault;$response;$retryable;$metadata;constructor(t){super(t.message),Object.setPrototypeOf(this,Object.getPrototypeOf(this).constructor.prototype),this.name=t.name,this.$fault=t.$fault,this.$metadata=t.$metadata}static isInstance(t){if(!t)return!1;let r=t;return e.prototype.isPrototypeOf(r)||!!r.$fault&&!!r.$metadata&&(r.$fault==="client"||r.$fault==="server")}static[Symbol.hasInstance](t){if(!t)return!1;let r=t;return this===e?e.isInstance(t):e.isInstance(t)?r.name&&this.name?this.prototype.isPrototypeOf(t)||r.name===this.name:this.prototype.isPrototypeOf(t):!1}},z$=(e,t={})=>{Object.entries(t).filter(([,n])=>n!==void 0).forEach(([n,i])=>{(e[n]==null||e[n]==="")&&(e[n]=i)});let r=e.message||e.Message||"UnknownError";return e.message=r,delete e.Message,e},V$=({output:e,parsedBody:t,exceptionCtor:r,errorCode:n})=>{let i=DCe(e),o=i.httpStatusCode?i.httpStatusCode+"":void 0,s=new r({name:t?.code||t?.Code||n||o||"UnknownError",$fault:"client",$metadata:i});throw z$(s,t)},ICe=e=>({output:t,parsedBody:r,errorCode:n})=>{V$({output:t,parsedBody:r,exceptionCtor:e,errorCode:n})},DCe=e=>({httpStatusCode:e.statusCode,requestId:e.headers["x-amzn-requestid"]??e.headers["x-amzn-request-id"]??e.headers["x-amz-request-id"],extendedRequestId:e.headers["x-amz-id-2"],cfId:e.headers["x-amz-cf-id"]}),kCe=e=>{switch(e){case"standard":return{retryMode:"standard",connectionTimeout:3100};case"in-region":return{retryMode:"standard",connectionTimeout:1100};case"cross-region":return{retryMode:"standard",connectionTimeout:3100};case"mobile":return{retryMode:"standard",connectionTimeout:3e4};default:return{}}},$$=!1,NCe=e=>{e&&!$$&&parseInt(e.substring(1,e.indexOf(".")))<16&&($$=!0)},MCe=e=>{let t=[];for(let r in vO.AlgorithmId){let n=vO.AlgorithmId[r];e[n]!==void 0&&t.push({algorithmId:()=>n,checksumConstructor:()=>e[n]})}return{addChecksumAlgorithm(r){t.push(r)},checksumAlgorithms(){return t}}},LCe=e=>{let t={};return e.checksumAlgorithms().forEach(r=>{t[r.algorithmId()]=r.checksumConstructor()}),t},BCe=e=>({setRetryStrategy(t){e.retryStrategy=t},retryStrategy(){return e.retryStrategy}}),FCe=e=>{let t={};return t.retryStrategy=e.retryStrategy(),t},W$=e=>Object.assign(MCe(e),BCe(e)),qCe=W$,jCe=e=>Object.assign(LCe(e),FCe(e)),UCe=e=>Array.isArray(e)?e:[e],K$=e=>{let t="#text";for(let r in e)e.hasOwnProperty(r)&&e[r][t]!==void 0?e[r]=e[r][t]:typeof e[r]=="object"&&e[r]!==null&&(e[r]=K$(e[r]));return e},HCe=e=>e!=null,RO=class{trace(){}debug(){}info(){}warn(){}error(){}};function Y$(e,t,r){let n,i,o;if(typeof t>"u"&&typeof r>"u")n={},o=e;else{if(n=e,typeof t=="function")return i=t,o=r,zCe(n,i,o);o=t}for(let s of Object.keys(o)){if(!Array.isArray(o[s])){n[s]=o[s];continue}X$(n,null,o,s)}return n}var $Ce=e=>{let t={};for(let[r,n]of Object.entries(e||{}))t[r]=[,n];return t},GCe=(e,t)=>{let r={};for(let n in t)X$(r,e,t,n);return r},zCe=(e,t,r)=>Y$(e,Object.entries(r).reduce((n,[i,o])=>(Array.isArray(o)?n[i]=o:typeof o=="function"?n[i]=[t,o()]:n[i]=[t,o],n),{})),X$=(e,t,r,n)=>{if(t!==null){let s=r[n];typeof s=="function"&&(s=[,s]);let[a=VCe,c=WCe,u=n]=s;(typeof a=="function"&&a(t[u])||typeof a!="function"&&a)&&(e[n]=c(t[u]));return}let[i,o]=r[n];if(typeof o=="function"){let s,a=i===void 0&&(s=o())!=null,c=typeof i=="function"&&!!i(void 0)||typeof i!="function"&&!!i;a?e[n]=s:c&&(e[n]=o())}else{let s=i===void 0&&o!=null,a=typeof i=="function"&&!!i(o)||typeof i!="function"&&!!i;(s||a)&&(e[n]=o)}},VCe=e=>e!=null,WCe=e=>e,KCe=e=>{if(e!==e)return"NaN";switch(e){case 1/0:return"Infinity";case-1/0:return"-Infinity";default:return e}},YCe=e=>e.toISOString().replace(".000Z","Z"),PO=e=>{if(e==null)return{};if(Array.isArray(e))return e.filter(t=>t!=null).map(PO);if(typeof e=="object"){let t={};for(let r of Object.keys(e))e[r]!=null&&(t[r]=PO(e[r]));return t}return e};Object.defineProperty(Nt,"collectBody",{enumerable:!0,get:function(){return OO.collectBody}});Object.defineProperty(Nt,"extendedEncodeURIComponent",{enumerable:!0,get:function(){return OO.extendedEncodeURIComponent}});Object.defineProperty(Nt,"resolvedPath",{enumerable:!0,get:function(){return OO.resolvedPath}});Nt.Client=CO;Nt.Command=Cb;Nt.NoOpLogger=RO;Nt.SENSITIVE_STRING=PCe;Nt.ServiceException=AO;Nt._json=PO;Nt.convertMap=$Ce;Nt.createAggregatedClient=OCe;Nt.decorateServiceException=z$;Nt.emitWarningIfUnsupportedVersion=NCe;Nt.getArrayIfSingleItem=UCe;Nt.getDefaultClientConfiguration=qCe;Nt.getDefaultExtensionConfiguration=W$;Nt.getValueFromTextNode=K$;Nt.isSerializableHeaderValue=HCe;Nt.loadConfigsForDefaultMode=kCe;Nt.map=Y$;Nt.resolveDefaultRuntimeConfig=jCe;Nt.serializeDateTime=YCe;Nt.serializeFloat=KCe;Nt.take=GCe;Nt.throwDefaultError=V$;Nt.withBaseException=ICe;Object.keys(H$).forEach(function(e){e!=="default"&&!Object.prototype.hasOwnProperty.call(Nt,e)&&Object.defineProperty(Nt,e,{enumerable:!0,get:function(){return H$[e]}})})});var IO,Li,Xl=Y(()=>{"use strict";xt();IO=z(Ge()),Li=class{queryCompat;constructor(t=!1){this.queryCompat=t}resolveRestContentType(t,r){let n=r.getMemberSchemas(),i=Object.values(n).find(o=>!!o.getMergedTraits().httpPayload);if(i){let o=i.getMergedTraits().mediaType;return o||(i.isStringSchema()?"text/plain":i.isBlobSchema()?"application/octet-stream":t)}else if(!r.isUnitSchema()&&Object.values(n).find(s=>{let{httpQuery:a,httpQueryParams:c,httpHeader:u,httpLabel:l,httpPrefixHeaders:d}=s.getMergedTraits();return!a&&!c&&!u&&!l&&d===void 0}))return t}async getErrorSchemaOrThrowBaseException(t,r,n,i,o,s){let a=r,c=t;t.includes("#")&&([a,c]=t.split("#"));let u={$metadata:o,$fault:n.statusCode<500?"client":"server"},l=Ue.for(a);try{return{errorSchema:s?.(l,c)??l.getSchema(t),errorMetadata:u}}catch{i.message=i.message??i.Message??"UnknownError";let h=Ue.for("smithy.ts.sdk.synthetic."+a),f=h.getBaseException();if(f){let p=h.getErrorCtor(f)??Error;throw this.decorateServiceException(Object.assign(new p({name:c}),u),i)}throw this.decorateServiceException(Object.assign(new Error(c),u),i)}}decorateServiceException(t,r={}){if(this.queryCompat){let n=t.Message??r.Message,i=(0,IO.decorateServiceException)(t,r);return n&&(i.Message=n,i.message=n),i}return(0,IO.decorateServiceException)(t,r)}setQueryCompatError(t,r){let n=r.headers?.["x-amzn-query-error"];if(t!==void 0&&n!=null){let[i,o]=n.split(";"),s=Object.entries(t),a={Code:i,Type:o};Object.assign(t,a);for(let[c,u]of s)a[c]=u;delete a.__type,t.Error=a}}queryCompatOutput(t,r){t.Error&&(r.Error=t.Error),t.Type&&(r.Type=t.Type),t.Code&&(r.Code=t.Code)}}});var xb,J$=Y(()=>{"use strict";B$();xt();Xl();xb=class extends vb{awsQueryCompatible;mixin;constructor({defaultNamespace:t,awsQueryCompatible:r}){super({defaultNamespace:t}),this.awsQueryCompatible=!!r,this.mixin=new Li(this.awsQueryCompatible)}async serializeRequest(t,r,n){let i=await super.serializeRequest(t,r,n);return this.awsQueryCompatible&&(i.headers["x-amzn-query-mode"]="true"),i}async handleError(t,r,n,i,o){this.awsQueryCompatible&&this.mixin.setQueryCompatError(i,n);let s=Eb(n,i)??"Unknown",{errorSchema:a,errorMetadata:c}=await this.mixin.getErrorSchemaOrThrowBaseException(s,this.options.defaultNamespace,n,i,o),u=ke.of(a),l=i.message??i.Message??"Unknown",d=Ue.for(a[1]).getErrorCtor(a)??Error,h=new d(l),f={};for(let[p,m]of u.structIterator())f[p]=this.deserializer.readValue(m,i[p]);throw this.awsQueryCompatible&&this.mixin.queryCompatOutput(i,f),this.mixin.decorateServiceException(Object.assign(h,c,{$fault:u.getMergedTraits().error,message:l},f),i)}}});var Q$,Z$,e8,t8=Y(()=>{"use strict";Q$=e=>{if(e==null)return e;if(typeof e=="number"||typeof e=="bigint"){let t=new Error(`Received number ${e} where a string was expected.`);return t.name="Warning",console.warn(t),String(e)}if(typeof e=="boolean"){let t=new Error(`Received boolean ${e} where a string was expected.`);return t.name="Warning",console.warn(t),String(e)}return e},Z$=e=>{if(e==null)return e;if(typeof e=="string"){let t=e.toLowerCase();if(e!==""&&t!=="false"&&t!=="true"){let r=new Error(`Received string "${e}" where a boolean was expected.`);r.name="Warning",console.warn(r)}return e!==""&&t!=="false"}return e},e8=e=>{if(e==null)return e;if(typeof e=="string"){let t=Number(e);if(t.toString()!==e){let r=new Error(`Received string "${e}" where a number was expected.`);return r.name="Warning",console.warn(r),e}return t}return e}});var vn,Da=Y(()=>{"use strict";vn=class{serdeContext;setSerdeContext(t){this.serdeContext=t}}});function*Jl(e,t){if(e.isUnitSchema())return;let r=e.getSchema();for(let n=0;n<r[4].length;++n){let i=r[4][n],o=r[5][n],s=new ke([o,0],i);!(i in t)&&!s.isIdempotencyToken()||(yield[i,s])}}function*r8(e,t,r){if(e.isUnitSchema())return;let n=e.getSchema(),i=Object.keys(t).filter(o=>o!=="__type").length;for(let o=0;o<n[4].length&&i!==0;++o){let s=n[4][o],a=n[5][o],c=new ke([a,0],s),u=s;r&&(u=c.getMergedTraits()[r]??s),u in t&&(yield[s,c],i-=1)}}var ah=Y(()=>{"use strict";xt()});function n8(e,t,r){if(r?.source){let n=r.source;if(typeof t=="number"&&(t>Number.MAX_SAFE_INTEGER||t<Number.MIN_SAFE_INTEGER||n!==String(t)))return n.includes(".")?new tr(n,"bigDecimal"):BigInt(n)}return t}var i8=Y(()=>{"use strict";ii()});var o8,s8,Tb,DO=Y(()=>{"use strict";o8=z(Ge()),s8=z(Cr()),Tb=(e,t)=>(0,o8.collectBody)(e,t).then(r=>(t?.utf8Encoder??s8.toUtf8)(r))});var ch,a8,Ql,uh=Y(()=>{"use strict";DO();ch=(e,t)=>Tb(e,t).then(r=>{if(r.length)try{return JSON.parse(r)}catch(n){throw n?.name==="SyntaxError"&&Object.defineProperty(n,"$responseBodyText",{value:r}),n}return{}}),a8=async(e,t)=>{let r=await ch(e,t);return r.message=r.message??r.Message,r},Ql=(e,t)=>{let r=(o,s)=>Object.keys(o).find(a=>a.toLowerCase()===s.toLowerCase()),n=o=>{let s=o;return typeof s=="number"&&(s=s.toString()),s.indexOf(",")>=0&&(s=s.split(",")[0]),s.indexOf(":")>=0&&(s=s.split(":")[0]),s.indexOf("#")>=0&&(s=s.split("#")[1]),s},i=r(e.headers,"x-amzn-errortype");if(i!==void 0)return n(e.headers[i]);if(t&&typeof t=="object"){let o=r(t,"code");if(o&&t[o]!==void 0)return n(t[o]);if(t.__type!==void 0)return n(t.__type)}}});var c8,Zl,kO=Y(()=>{"use strict";oi();xt();ii();c8=z(Gr());Da();ah();i8();uh();Zl=class extends vn{settings;constructor(t){super(),this.settings=t}async read(t,r){return this._read(t,typeof r=="string"?JSON.parse(r,n8):await ch(r,this.serdeContext))}readObject(t,r){return this._read(t,r)}_read(t,r){let n=r!==null&&typeof r=="object",i=ke.of(t);if(n){if(i.isStructSchema()){let s={};for(let[a,c]of r8(i,r,this.settings.jsonName?"jsonName":!1)){let u=this.settings.jsonName?c.getMergedTraits().jsonName??a:a,l=this._read(c,r[u]);l!=null&&(s[a]=l)}return s}if(Array.isArray(r)&&i.isListSchema()){let s=i.getValueSchema(),a=[],c=!!i.getMergedTraits().sparse;for(let u of r)(c||u!=null)&&a.push(this._read(s,u));return a}if(i.isMapSchema()){let s=i.getValueSchema(),a={},c=!!i.getMergedTraits().sparse;for(let[u,l]of Object.entries(r))(c||l!=null)&&(a[u]=this._read(s,l));return a}}if(i.isBlobSchema()&&typeof r=="string")return(0,c8.fromBase64)(r);let o=i.getMergedTraits().mediaType;if(i.isStringSchema()&&typeof r=="string"&&o)return o==="application/json"||o.endsWith("+json")?Un.from(r):r;if(i.isTimestampSchema()&&r!=null)switch(gi(i,this.settings)){case 5:return mP(r);case 6:return gP(r);case 7:return yP(r);default:return console.warn("Missing timestamp format, parsing value with Date constructor:",r),new Date(r)}if(i.isBigIntegerSchema()&&(typeof r=="number"||typeof r=="string"))return BigInt(r);if(i.isBigDecimalSchema()&&r!=null){if(r instanceof tr)return r;let s=r;return s.type==="bigDecimal"&&"string"in s?new tr(s.string,s.type):new tr(String(r),"bigDecimal")}if(i.isNumericSchema()&&typeof r=="string"){switch(r){case"Infinity":return 1/0;case"-Infinity":return-1/0;case"NaN":return NaN}return r}if(i.isDocumentSchema())if(n){let s=Array.isArray(r)?[]:{};for(let[a,c]of Object.entries(r))c instanceof tr?s[a]=c:s[a]=this._read(i,c);return s}else return structuredClone(r);return r}}});var u8,Ab,l8=Y(()=>{"use strict";ii();u8="\u039D",Ab=class{values=new Map;counter=0;stage=0;createReplacer(){if(this.stage===1)throw new Error("@aws-sdk/core/protocols - JsonReplacer already created.");if(this.stage===2)throw new Error("@aws-sdk/core/protocols - JsonReplacer exhausted.");return this.stage=1,(t,r)=>{if(r instanceof tr){let n=`${u8+"nv"+this.counter++}_`+r.string;return this.values.set(`"${n}"`,r.string),n}if(typeof r=="bigint"){let n=r.toString(),i=`${u8+"b"+this.counter++}_`+n;return this.values.set(`"${i}"`,n),i}return r}}replaceInJson(t){if(this.stage===0)throw new Error("@aws-sdk/core/protocols - JsonReplacer not created yet.");if(this.stage===2)throw new Error("@aws-sdk/core/protocols - JsonReplacer exhausted.");if(this.stage=2,this.counter===0)return t;for(let[r,n]of this.values)t=t.replace(r,n);return t}}});var NO,ef,MO=Y(()=>{"use strict";oi();xt();ii();NO=z(Gr());Da();ah();l8();ef=class extends vn{settings;buffer;useReplacer=!1;rootSchema;constructor(t){super(),this.settings=t}write(t,r){this.rootSchema=ke.of(t),this.buffer=this._write(this.rootSchema,r)}writeDiscriminatedDocument(t,r){this.write(t,r),typeof this.buffer=="object"&&(this.buffer.__type=ke.of(t).getName(!0))}flush(){let{rootSchema:t,useReplacer:r}=this;if(this.rootSchema=void 0,this.useReplacer=!1,t?.isStructSchema()||t?.isDocumentSchema()){if(!r)return JSON.stringify(this.buffer);let n=new Ab;return n.replaceInJson(JSON.stringify(this.buffer,n.createReplacer(),0))}return this.buffer}_write(t,r,n){let i=r!==null&&typeof r=="object",o=ke.of(t);if(i){if(o.isStructSchema()){let s={};for(let[a,c]of Jl(o,r)){let u=this._write(c,r[a],o);if(u!==void 0){let l=c.getMergedTraits().jsonName,d=this.settings.jsonName?l??a:a;s[d]=u}}return s}if(Array.isArray(r)&&o.isListSchema()){let s=o.getValueSchema(),a=[],c=!!o.getMergedTraits().sparse;for(let u of r)(c||u!=null)&&a.push(this._write(s,u));return a}if(o.isMapSchema()){let s=o.getValueSchema(),a={},c=!!o.getMergedTraits().sparse;for(let[u,l]of Object.entries(r))(c||l!=null)&&(a[u]=this._write(s,l));return a}if(r instanceof Uint8Array&&(o.isBlobSchema()||o.isDocumentSchema()))return o===this.rootSchema?r:(this.serdeContext?.base64Encoder??NO.toBase64)(r);if(r instanceof Date&&(o.isTimestampSchema()||o.isDocumentSchema()))switch(gi(o,this.settings)){case 5:return r.toISOString().replace(".000Z","Z");case 6:return eh(r);case 7:return r.getTime()/1e3;default:return console.warn("Missing timestamp format, using epoch seconds",r),r.getTime()/1e3}r instanceof tr&&(this.useReplacer=!0)}if(!(r===null&&n?.isStructSchema())){if(o.isStringSchema()){if(typeof r>"u"&&o.isIdempotencyToken())return(0,Mi.v4)();let s=o.getMergedTraits().mediaType;return r!=null&&s&&(s==="application/json"||s.endsWith("+json"))?Un.from(r):r}if(typeof r=="number"&&o.isNumericSchema())return Math.abs(r)===1/0||isNaN(r)?String(r):r;if(typeof r=="string"&&o.isBlobSchema())return o===this.rootSchema?r:(this.serdeContext?.base64Encoder??NO.toBase64)(r);if(typeof r=="bigint"&&(this.useReplacer=!0),o.isDocumentSchema())if(i){let s=Array.isArray(r)?[]:{};for(let[a,c]of Object.entries(r))c instanceof tr?(this.useReplacer=!0,s[a]=c):s[a]=this._write(o,c);return s}else return structuredClone(r);return r}}}});var ka,Rb=Y(()=>{"use strict";Da();kO();MO();ka=class extends vn{settings;constructor(t){super(),this.settings=t}createSerializer(){let t=new ef(this.settings);return t.setSerdeContext(this.serdeContext),t}createDeserializer(){let t=new Zl(this.settings);return t.setSerdeContext(this.serdeContext),t}}});var Na,Pb=Y(()=>{"use strict";oi();xt();Xl();Rb();uh();Na=class extends Ps{serializer;deserializer;serviceTarget;codec;mixin;awsQueryCompatible;constructor({defaultNamespace:t,serviceTarget:r,awsQueryCompatible:n,jsonCodec:i}){super({defaultNamespace:t}),this.serviceTarget=r,this.codec=i??new ka({timestampFormat:{useTrait:!0,default:7},jsonName:!1}),this.serializer=this.codec.createSerializer(),this.deserializer=this.codec.createDeserializer(),this.awsQueryCompatible=!!n,this.mixin=new Li(this.awsQueryCompatible)}async serializeRequest(t,r,n){let i=await super.serializeRequest(t,r,n);return i.path.endsWith("/")||(i.path+="/"),Object.assign(i.headers,{"content-type":`application/x-amz-json-${this.getJsonRpcVersion()}`,"x-amz-target":`${this.serviceTarget}.${t.name}`}),this.awsQueryCompatible&&(i.headers["x-amzn-query-mode"]="true"),(io(t.input)==="unit"||!i.body)&&(i.body="{}"),i}getPayloadCodec(){return this.codec}async handleError(t,r,n,i,o){this.awsQueryCompatible&&this.mixin.setQueryCompatError(i,n);let s=Ql(n,i)??"Unknown",{errorSchema:a,errorMetadata:c}=await this.mixin.getErrorSchemaOrThrowBaseException(s,this.options.defaultNamespace,n,i,o),u=ke.of(a),l=i.message??i.Message??"Unknown",d=Ue.for(a[1]).getErrorCtor(a)??Error,h=new d(l),f={};for(let[p,m]of u.structIterator()){let _=m.getMergedTraits().jsonName??p;f[p]=this.codec.createDeserializer().readObject(m,i[_])}throw this.awsQueryCompatible&&this.mixin.queryCompatOutput(i,f),this.mixin.decorateServiceException(Object.assign(h,c,{$fault:u.getMergedTraits().error,message:l},f),i)}}});var Ob,f8=Y(()=>{"use strict";Pb();Ob=class extends Na{constructor({defaultNamespace:t,serviceTarget:r,awsQueryCompatible:n,jsonCodec:i}){super({defaultNamespace:t,serviceTarget:r,awsQueryCompatible:n,jsonCodec:i})}getShapeId(){return"aws.protocols#awsJson1_0"}getJsonRpcVersion(){return"1.0"}getDefaultContentType(){return"application/x-amz-json-1.0"}}});var Ib,d8=Y(()=>{"use strict";Pb();Ib=class extends Na{constructor({defaultNamespace:t,serviceTarget:r,awsQueryCompatible:n,jsonCodec:i}){super({defaultNamespace:t,serviceTarget:r,awsQueryCompatible:n,jsonCodec:i})}getShapeId(){return"aws.protocols#awsJson1_1"}getJsonRpcVersion(){return"1.1"}getDefaultContentType(){return"application/x-amz-json-1.1"}}});var Ma,p8=Y(()=>{"use strict";oi();xt();Xl();Rb();uh();Ma=class extends tu{serializer;deserializer;codec;mixin=new Li;constructor({defaultNamespace:t}){super({defaultNamespace:t});let r={timestampFormat:{useTrait:!0,default:7},httpBindings:!0,jsonName:!0};this.codec=new ka(r),this.serializer=new iu(this.codec.createSerializer(),r),this.deserializer=new nu(this.codec.createDeserializer(),r)}getShapeId(){return"aws.protocols#restJson1"}getPayloadCodec(){return this.codec}setSerdeContext(t){this.codec.setSerdeContext(t),super.setSerdeContext(t)}async serializeRequest(t,r,n){let i=await super.serializeRequest(t,r,n),o=ke.of(t.input);if(!i.headers["content-type"]){let s=this.mixin.resolveRestContentType(this.getDefaultContentType(),o);s&&(i.headers["content-type"]=s)}return i.body==null&&i.headers["content-type"]===this.getDefaultContentType()&&(i.body="{}"),i}async deserializeResponse(t,r,n){let i=await super.deserializeResponse(t,r,n),o=ke.of(t.output);for(let[s,a]of o.structIterator())a.getMemberTraits().httpPayload&&!(s in i)&&(i[s]=null);return i}async handleError(t,r,n,i,o){let s=Ql(n,i)??"Unknown",{errorSchema:a,errorMetadata:c}=await this.mixin.getErrorSchemaOrThrowBaseException(s,this.options.defaultNamespace,n,i,o),u=ke.of(a),l=i.message??i.Message??"Unknown",d=Ue.for(a[1]).getErrorCtor(a)??Error,h=new d(l);await this.deserializeHttpMessage(a,r,n,i);let f={};for(let[p,m]of u.structIterator()){let _=m.getMergedTraits().jsonName??p;f[p]=this.codec.createDeserializer().readObject(m,i[_])}throw this.mixin.decorateServiceException(Object.assign(h,c,{$fault:u.getMergedTraits().error,message:l},f),i)}getDefaultContentType(){return"application/json"}}});var h8,m8,g8=Y(()=>{"use strict";h8=z(Ge()),m8=e=>{if(e!=null)return typeof e=="object"&&"__type"in e&&delete e.__type,(0,h8.expectUnion)(e)}});var _8=E((d_t,y8)=>{"use strict";(()=>{"use strict";var e={d:(C,x)=>{for(var L in x)e.o(x,L)&&!e.o(C,L)&&Object.defineProperty(C,L,{enumerable:!0,get:x[L]})},o:(C,x)=>Object.prototype.hasOwnProperty.call(C,x),r:C=>{typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(C,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(C,"__esModule",{value:!0})}},t={};e.r(t),e.d(t,{XMLBuilder:()=>de,XMLParser:()=>Bx,XMLValidator:()=>Bt});let r=":A-Za-z_\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD",n=new RegExp("^["+r+"]["+r+"\\-.\\d\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$");function i(C,x){let L=[],V=x.exec(C);for(;V;){let H=[];H.startIndex=x.lastIndex-V[0].length;let W=V.length;for(let ae=0;ae<W;ae++)H.push(V[ae]);L.push(H),V=x.exec(C)}return L}let o=function(C){return n.exec(C)!=null},s={allowBooleanAttributes:!1,unpairedTags:[]};function a(C,x){x=Object.assign({},s,x);let L=[],V=!1,H=!1;C[0]==="\uFEFF"&&(C=C.substr(1));for(let W=0;W<C.length;W++)if(C[W]==="<"&&C[W+1]==="?"){if(W+=2,W=u(C,W),W.err)return W}else{if(C[W]!=="<"){if(c(C[W]))continue;return w("InvalidChar","char '"+C[W]+"' is not expected.",v(C,W))}{let ae=W;if(W++,C[W]==="!"){W=l(C,W);continue}{let ne=!1;C[W]==="/"&&(ne=!0,W++);let _e="";for(;W<C.length&&C[W]!==">"&&C[W]!==" "&&C[W]!==" "&&C[W]!==`
|
|
217
|
+
`&&C[W]!=="\r";W++)_e+=C[W];if(_e=_e.trim(),_e[_e.length-1]==="/"&&(_e=_e.substring(0,_e.length-1),W--),!o(_e)){let Le;return Le=_e.trim().length===0?"Invalid space after '<'.":"Tag '"+_e+"' is an invalid name.",w("InvalidTag",Le,v(C,W))}let Re=f(C,W);if(Re===!1)return w("InvalidAttr","Attributes for '"+_e+"' have open quote.",v(C,W));let $e=Re.value;if(W=Re.index,$e[$e.length-1]==="/"){let Le=W-$e.length;$e=$e.substring(0,$e.length-1);let ht=m($e,x);if(ht!==!0)return w(ht.err.code,ht.err.msg,v(C,Le+ht.err.line));V=!0}else if(ne){if(!Re.tagClosed)return w("InvalidTag","Closing tag '"+_e+"' doesn't have proper closing.",v(C,W));if($e.trim().length>0)return w("InvalidTag","Closing tag '"+_e+"' can't have attributes or invalid starting.",v(C,ae));if(L.length===0)return w("InvalidTag","Closing tag '"+_e+"' has not been opened.",v(C,ae));{let Le=L.pop();if(_e!==Le.tagName){let ht=v(C,Le.tagStartPos);return w("InvalidTag","Expected closing tag '"+Le.tagName+"' (opened in line "+ht.line+", col "+ht.col+") instead of closing tag '"+_e+"'.",v(C,ae))}L.length==0&&(H=!0)}}else{let Le=m($e,x);if(Le!==!0)return w(Le.err.code,Le.err.msg,v(C,W-$e.length+Le.err.line));if(H===!0)return w("InvalidXml","Multiple possible root nodes found.",v(C,W));x.unpairedTags.indexOf(_e)!==-1||L.push({tagName:_e,tagStartPos:ae}),V=!0}for(W++;W<C.length;W++)if(C[W]==="<"){if(C[W+1]==="!"){W++,W=l(C,W);continue}if(C[W+1]!=="?")break;if(W=u(C,++W),W.err)return W}else if(C[W]==="&"){let Le=_(C,W);if(Le==-1)return w("InvalidChar","char '&' is not expected.",v(C,W));W=Le}else if(H===!0&&!c(C[W]))return w("InvalidXml","Extra text at the end",v(C,W));C[W]==="<"&&W--}}}return V?L.length==1?w("InvalidTag","Unclosed tag '"+L[0].tagName+"'.",v(C,L[0].tagStartPos)):!(L.length>0)||w("InvalidXml","Invalid '"+JSON.stringify(L.map((W=>W.tagName)),null,4).replace(/\r?\n/g,"")+"' found.",{line:1,col:1}):w("InvalidXml","Start tag expected.",1)}function c(C){return C===" "||C===" "||C===`
|
|
218
|
+
`||C==="\r"}function u(C,x){let L=x;for(;x<C.length;x++)if(!(C[x]!="?"&&C[x]!=" ")){let V=C.substr(L,x-L);if(x>5&&V==="xml")return w("InvalidXml","XML declaration allowed only at the start of the document.",v(C,x));if(C[x]=="?"&&C[x+1]==">"){x++;break}}return x}function l(C,x){if(C.length>x+5&&C[x+1]==="-"&&C[x+2]==="-"){for(x+=3;x<C.length;x++)if(C[x]==="-"&&C[x+1]==="-"&&C[x+2]===">"){x+=2;break}}else if(C.length>x+8&&C[x+1]==="D"&&C[x+2]==="O"&&C[x+3]==="C"&&C[x+4]==="T"&&C[x+5]==="Y"&&C[x+6]==="P"&&C[x+7]==="E"){let L=1;for(x+=8;x<C.length;x++)if(C[x]==="<")L++;else if(C[x]===">"&&(L--,L===0))break}else if(C.length>x+9&&C[x+1]==="["&&C[x+2]==="C"&&C[x+3]==="D"&&C[x+4]==="A"&&C[x+5]==="T"&&C[x+6]==="A"&&C[x+7]==="["){for(x+=8;x<C.length;x++)if(C[x]==="]"&&C[x+1]==="]"&&C[x+2]===">"){x+=2;break}}return x}let d='"',h="'";function f(C,x){let L="",V="",H=!1;for(;x<C.length;x++){if(C[x]===d||C[x]===h)V===""?V=C[x]:V!==C[x]||(V="");else if(C[x]===">"&&V===""){H=!0;break}L+=C[x]}return V===""&&{value:L,index:x,tagClosed:H}}let p=new RegExp(`(\\s*)([^\\s=]+)(\\s*=)?(\\s*(['"])(([\\s\\S])*?)\\5)?`,"g");function m(C,x){let L=i(C,p),V={};for(let H=0;H<L.length;H++){if(L[H][1].length===0)return w("InvalidAttr","Attribute '"+L[H][2]+"' has no space in starting.",y(L[H]));if(L[H][3]!==void 0&&L[H][4]===void 0)return w("InvalidAttr","Attribute '"+L[H][2]+"' is without value.",y(L[H]));if(L[H][3]===void 0&&!x.allowBooleanAttributes)return w("InvalidAttr","boolean attribute '"+L[H][2]+"' is not allowed.",y(L[H]));let W=L[H][2];if(!R(W))return w("InvalidAttr","Attribute '"+W+"' is an invalid name.",y(L[H]));if(V.hasOwnProperty(W))return w("InvalidAttr","Attribute '"+W+"' is repeated.",y(L[H]));V[W]=1}return!0}function _(C,x){if(C[++x]===";")return-1;if(C[x]==="#")return(function(V,H){let W=/\d/;for(V[H]==="x"&&(H++,W=/[\da-fA-F]/);H<V.length;H++){if(V[H]===";")return H;if(!V[H].match(W))break}return-1})(C,++x);let L=0;for(;x<C.length;x++,L++)if(!(C[x].match(/\w/)&&L<20)){if(C[x]===";")break;return-1}return x}function w(C,x,L){return{err:{code:C,msg:x,line:L.line||L,col:L.col}}}function R(C){return o(C)}function v(C,x){let L=C.substring(0,x).split(/\r?\n/);return{line:L.length,col:L[L.length-1].length+1}}function y(C){return C.startIndex+C[1].length}let S={preserveOrder:!1,attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,removeNSPrefix:!1,allowBooleanAttributes:!1,parseTagValue:!0,parseAttributeValue:!1,trimValues:!0,cdataPropName:!1,numberParseOptions:{hex:!0,leadingZeros:!0,eNotation:!0},tagValueProcessor:function(C,x){return x},attributeValueProcessor:function(C,x){return x},stopNodes:[],alwaysCreateTextNode:!1,isArray:()=>!1,commentPropName:!1,unpairedTags:[],processEntities:!0,htmlEntities:!1,ignoreDeclaration:!1,ignorePiTags:!1,transformTagName:!1,transformAttributeName:!1,updateTag:function(C,x,L){return C},captureMetaData:!1},O;O=typeof Symbol!="function"?"@@xmlMetadata":Symbol("XML Node Metadata");class M{constructor(x){this.tagname=x,this.child=[],this[":@"]={}}add(x,L){x==="__proto__"&&(x="#__proto__"),this.child.push({[x]:L})}addChild(x,L){x.tagname==="__proto__"&&(x.tagname="#__proto__"),x[":@"]&&Object.keys(x[":@"]).length>0?this.child.push({[x.tagname]:x.child,":@":x[":@"]}):this.child.push({[x.tagname]:x.child}),L!==void 0&&(this.child[this.child.length-1][O]={startIndex:L})}static getMetaDataSymbol(){return O}}function A(C,x){let L={};if(C[x+3]!=="O"||C[x+4]!=="C"||C[x+5]!=="T"||C[x+6]!=="Y"||C[x+7]!=="P"||C[x+8]!=="E")throw new Error("Invalid Tag instead of DOCTYPE");{x+=9;let V=1,H=!1,W=!1,ae="";for(;x<C.length;x++)if(C[x]!=="<"||W)if(C[x]===">"){if(W?C[x-1]==="-"&&C[x-2]==="-"&&(W=!1,V--):V--,V===0)break}else C[x]==="["?H=!0:ae+=C[x];else{if(H&&ie(C,"!ENTITY",x)){let ne,_e;x+=7,[ne,_e,x]=I(C,x+1),_e.indexOf("&")===-1&&(L[ne]={regx:RegExp(`&${ne};`,"g"),val:_e})}else if(H&&ie(C,"!ELEMENT",x)){x+=8;let{index:ne}=U(C,x+1);x=ne}else if(H&&ie(C,"!ATTLIST",x))x+=8;else if(H&&ie(C,"!NOTATION",x)){x+=9;let{index:ne}=N(C,x+1);x=ne}else{if(!ie(C,"!--",x))throw new Error("Invalid DOCTYPE");W=!0}V++,ae=""}if(V!==0)throw new Error("Unclosed DOCTYPE")}return{entities:L,i:x}}let D=(C,x)=>{for(;x<C.length&&/\s/.test(C[x]);)x++;return x};function I(C,x){x=D(C,x);let L="";for(;x<C.length&&!/\s/.test(C[x])&&C[x]!=='"'&&C[x]!=="'";)L+=C[x],x++;if(be(L),x=D(C,x),C.substring(x,x+6).toUpperCase()==="SYSTEM")throw new Error("External entities are not supported");if(C[x]==="%")throw new Error("Parameter entities are not supported");let V="";return[x,V]=J(C,x,"entity"),[L,V,--x]}function N(C,x){x=D(C,x);let L="";for(;x<C.length&&!/\s/.test(C[x]);)L+=C[x],x++;be(L),x=D(C,x);let V=C.substring(x,x+6).toUpperCase();if(V!=="SYSTEM"&&V!=="PUBLIC")throw new Error(`Expected SYSTEM or PUBLIC, found "${V}"`);x+=V.length,x=D(C,x);let H=null,W=null;if(V==="PUBLIC")[x,H]=J(C,x,"publicIdentifier"),C[x=D(C,x)]!=='"'&&C[x]!=="'"||([x,W]=J(C,x,"systemIdentifier"));else if(V==="SYSTEM"&&([x,W]=J(C,x,"systemIdentifier"),!W))throw new Error("Missing mandatory system identifier for SYSTEM notation");return{notationName:L,publicIdentifier:H,systemIdentifier:W,index:--x}}function J(C,x,L){let V="",H=C[x];if(H!=='"'&&H!=="'")throw new Error(`Expected quoted string, found "${H}"`);for(x++;x<C.length&&C[x]!==H;)V+=C[x],x++;if(C[x]!==H)throw new Error(`Unterminated ${L} value`);return[++x,V]}function U(C,x){x=D(C,x);let L="";for(;x<C.length&&!/\s/.test(C[x]);)L+=C[x],x++;if(!be(L))throw new Error(`Invalid element name: "${L}"`);let V="";if(C[x=D(C,x)]==="E"&&ie(C,"MPTY",x))x+=4;else if(C[x]==="A"&&ie(C,"NY",x))x+=2;else{if(C[x]!=="(")throw new Error(`Invalid Element Expression, found "${C[x]}"`);for(x++;x<C.length&&C[x]!==")";)V+=C[x],x++;if(C[x]!==")")throw new Error("Unterminated content model")}return{elementName:L,contentModel:V.trim(),index:x}}function ie(C,x,L){for(let V=0;V<x.length;V++)if(x[V]!==C[L+V+1])return!1;return!0}function be(C){if(o(C))return C;throw new Error(`Invalid entity name ${C}`)}let B=/^[-+]?0x[a-fA-F0-9]+$/,te=/^([\-\+])?(0*)([0-9]*(\.[0-9]*)?)$/,ge={hex:!0,leadingZeros:!0,decimalPoint:".",eNotation:!0},$=/^([-+])?(0*)(\d*(\.\d*)?[eE][-\+]?\d+)$/;function ve(C){return typeof C=="function"?C:Array.isArray(C)?x=>{for(let L of C)if(typeof L=="string"&&x===L||L instanceof RegExp&&L.test(x))return!0}:()=>!1}class Ze{constructor(x){this.options=x,this.currentNode=null,this.tagsNodeStack=[],this.docTypeEntities={},this.lastEntities={apos:{regex:/&(apos|#39|#x27);/g,val:"'"},gt:{regex:/&(gt|#62|#x3E);/g,val:">"},lt:{regex:/&(lt|#60|#x3C);/g,val:"<"},quot:{regex:/&(quot|#34|#x22);/g,val:'"'}},this.ampEntity={regex:/&(amp|#38|#x26);/g,val:"&"},this.htmlEntities={space:{regex:/&(nbsp|#160);/g,val:" "},cent:{regex:/&(cent|#162);/g,val:"\xA2"},pound:{regex:/&(pound|#163);/g,val:"\xA3"},yen:{regex:/&(yen|#165);/g,val:"\xA5"},euro:{regex:/&(euro|#8364);/g,val:"\u20AC"},copyright:{regex:/&(copy|#169);/g,val:"\xA9"},reg:{regex:/&(reg|#174);/g,val:"\xAE"},inr:{regex:/&(inr|#8377);/g,val:"\u20B9"},num_dec:{regex:/&#([0-9]{1,7});/g,val:(L,V)=>String.fromCodePoint(Number.parseInt(V,10))},num_hex:{regex:/&#x([0-9a-fA-F]{1,6});/g,val:(L,V)=>String.fromCodePoint(Number.parseInt(V,16))}},this.addExternalEntities=at,this.parseXml=T,this.parseTextData=G,this.resolveNameSpace=ce,this.buildAttributesMap=P,this.isItStopNode=yt,this.replaceEntitiesValue=j,this.readStopNodeData=Dt,this.saveTextToParentTag=Be,this.addChild=K,this.ignoreAttributesFn=ve(this.options.ignoreAttributes)}}function at(C){let x=Object.keys(C);for(let L=0;L<x.length;L++){let V=x[L];this.lastEntities[V]={regex:new RegExp("&"+V+";","g"),val:C[V]}}}function G(C,x,L,V,H,W,ae){if(C!==void 0&&(this.options.trimValues&&!V&&(C=C.trim()),C.length>0)){ae||(C=this.replaceEntitiesValue(C));let ne=this.options.tagValueProcessor(x,C,L,H,W);return ne==null?C:typeof ne!=typeof C||ne!==C?ne:this.options.trimValues||C.trim()===C?Ur(C,this.options.parseTagValue,this.options.numberParseOptions):C}}function ce(C){if(this.options.removeNSPrefix){let x=C.split(":"),L=C.charAt(0)==="/"?"/":"";if(x[0]==="xmlns")return"";x.length===2&&(C=L+x[1])}return C}let Se=new RegExp(`([^\\s=]+)\\s*(=\\s*(['"])([\\s\\S]*?)\\3)?`,"gm");function P(C,x,L){if(this.options.ignoreAttributes!==!0&&typeof C=="string"){let V=i(C,Se),H=V.length,W={};for(let ae=0;ae<H;ae++){let ne=this.resolveNameSpace(V[ae][1]);if(this.ignoreAttributesFn(ne,x))continue;let _e=V[ae][4],Re=this.options.attributeNamePrefix+ne;if(ne.length)if(this.options.transformAttributeName&&(Re=this.options.transformAttributeName(Re)),Re==="__proto__"&&(Re="#__proto__"),_e!==void 0){this.options.trimValues&&(_e=_e.trim()),_e=this.replaceEntitiesValue(_e);let $e=this.options.attributeValueProcessor(ne,_e,x);W[Re]=$e==null?_e:typeof $e!=typeof _e||$e!==_e?$e:Ur(_e,this.options.parseAttributeValue,this.options.numberParseOptions)}else this.options.allowBooleanAttributes&&(W[Re]=!0)}if(!Object.keys(W).length)return;if(this.options.attributesGroupName){let ae={};return ae[this.options.attributesGroupName]=W,ae}return W}}let T=function(C){C=C.replace(/\r\n?/g,`
|
|
219
|
+
`);let x=new M("!xml"),L=x,V="",H="";for(let W=0;W<C.length;W++)if(C[W]==="<")if(C[W+1]==="/"){let ae=ft(C,">",W,"Closing Tag is not closed."),ne=C.substring(W+2,ae).trim();if(this.options.removeNSPrefix){let $e=ne.indexOf(":");$e!==-1&&(ne=ne.substr($e+1))}this.options.transformTagName&&(ne=this.options.transformTagName(ne)),L&&(V=this.saveTextToParentTag(V,L,H));let _e=H.substring(H.lastIndexOf(".")+1);if(ne&&this.options.unpairedTags.indexOf(ne)!==-1)throw new Error(`Unpaired tag can not be used as closing tag: </${ne}>`);let Re=0;_e&&this.options.unpairedTags.indexOf(_e)!==-1?(Re=H.lastIndexOf(".",H.lastIndexOf(".")-1),this.tagsNodeStack.pop()):Re=H.lastIndexOf("."),H=H.substring(0,Re),L=this.tagsNodeStack.pop(),V="",W=ae}else if(C[W+1]==="?"){let ae=wt(C,W,!1,"?>");if(!ae)throw new Error("Pi Tag is not closed.");if(V=this.saveTextToParentTag(V,L,H),!(this.options.ignoreDeclaration&&ae.tagName==="?xml"||this.options.ignorePiTags)){let ne=new M(ae.tagName);ne.add(this.options.textNodeName,""),ae.tagName!==ae.tagExp&&ae.attrExpPresent&&(ne[":@"]=this.buildAttributesMap(ae.tagExp,H,ae.tagName)),this.addChild(L,ne,H,W)}W=ae.closeIndex+1}else if(C.substr(W+1,3)==="!--"){let ae=ft(C,"-->",W+4,"Comment is not closed.");if(this.options.commentPropName){let ne=C.substring(W+4,ae-2);V=this.saveTextToParentTag(V,L,H),L.add(this.options.commentPropName,[{[this.options.textNodeName]:ne}])}W=ae}else if(C.substr(W+1,2)==="!D"){let ae=A(C,W);this.docTypeEntities=ae.entities,W=ae.i}else if(C.substr(W+1,2)==="!["){let ae=ft(C,"]]>",W,"CDATA is not closed.")-2,ne=C.substring(W+9,ae);V=this.saveTextToParentTag(V,L,H);let _e=this.parseTextData(ne,L.tagname,H,!0,!1,!0,!0);_e==null&&(_e=""),this.options.cdataPropName?L.add(this.options.cdataPropName,[{[this.options.textNodeName]:ne}]):L.add(this.options.textNodeName,_e),W=ae+2}else{let ae=wt(C,W,this.options.removeNSPrefix),ne=ae.tagName,_e=ae.rawTagName,Re=ae.tagExp,$e=ae.attrExpPresent,Le=ae.closeIndex;this.options.transformTagName&&(ne=this.options.transformTagName(ne)),L&&V&&L.tagname!=="!xml"&&(V=this.saveTextToParentTag(V,L,H,!1));let ht=L;ht&&this.options.unpairedTags.indexOf(ht.tagname)!==-1&&(L=this.tagsNodeStack.pop(),H=H.substring(0,H.lastIndexOf("."))),ne!==x.tagname&&(H+=H?"."+ne:ne);let kt=W;if(this.isItStopNode(this.options.stopNodes,H,ne)){let _t="";if(Re.length>0&&Re.lastIndexOf("/")===Re.length-1)ne[ne.length-1]==="/"?(ne=ne.substr(0,ne.length-1),H=H.substr(0,H.length-1),Re=ne):Re=Re.substr(0,Re.length-1),W=ae.closeIndex;else if(this.options.unpairedTags.indexOf(ne)!==-1)W=ae.closeIndex;else{let To=this.readStopNodeData(C,_e,Le+1);if(!To)throw new Error(`Unexpected end of ${_e}`);W=To.i,_t=To.tagContent}let Sr=new M(ne);ne!==Re&&$e&&(Sr[":@"]=this.buildAttributesMap(Re,H,ne)),_t&&(_t=this.parseTextData(_t,ne,H,!0,$e,!0,!0)),H=H.substr(0,H.lastIndexOf(".")),Sr.add(this.options.textNodeName,_t),this.addChild(L,Sr,H,kt)}else{if(Re.length>0&&Re.lastIndexOf("/")===Re.length-1){ne[ne.length-1]==="/"?(ne=ne.substr(0,ne.length-1),H=H.substr(0,H.length-1),Re=ne):Re=Re.substr(0,Re.length-1),this.options.transformTagName&&(ne=this.options.transformTagName(ne));let _t=new M(ne);ne!==Re&&$e&&(_t[":@"]=this.buildAttributesMap(Re,H,ne)),this.addChild(L,_t,H,kt),H=H.substr(0,H.lastIndexOf("."))}else{let _t=new M(ne);this.tagsNodeStack.push(L),ne!==Re&&$e&&(_t[":@"]=this.buildAttributesMap(Re,H,ne)),this.addChild(L,_t,H,kt),L=_t}V="",W=Le}}else V+=C[W];return x.child};function K(C,x,L,V){this.options.captureMetaData||(V=void 0);let H=this.options.updateTag(x.tagname,L,x[":@"]);H===!1||(typeof H=="string"&&(x.tagname=H),C.addChild(x,V))}let j=function(C){if(this.options.processEntities){for(let x in this.docTypeEntities){let L=this.docTypeEntities[x];C=C.replace(L.regx,L.val)}for(let x in this.lastEntities){let L=this.lastEntities[x];C=C.replace(L.regex,L.val)}if(this.options.htmlEntities)for(let x in this.htmlEntities){let L=this.htmlEntities[x];C=C.replace(L.regex,L.val)}C=C.replace(this.ampEntity.regex,this.ampEntity.val)}return C};function Be(C,x,L,V){return C&&(V===void 0&&(V=x.child.length===0),(C=this.parseTextData(C,x.tagname,L,!1,!!x[":@"]&&Object.keys(x[":@"]).length!==0,V))!==void 0&&C!==""&&x.add(this.options.textNodeName,C),C=""),C}function yt(C,x,L){let V="*."+L;for(let H in C){let W=C[H];if(V===W||x===W)return!0}return!1}function ft(C,x,L,V){let H=C.indexOf(x,L);if(H===-1)throw new Error(V);return H+x.length-1}function wt(C,x,L,V=">"){let H=(function(Le,ht,kt=">"){let _t,Sr="";for(let To=ht;To<Le.length;To++){let na=Le[To];if(_t)na===_t&&(_t="");else if(na==='"'||na==="'")_t=na;else if(na===kt[0]){if(!kt[1])return{data:Sr,index:To};if(Le[To+1]===kt[1])return{data:Sr,index:To}}else na===" "&&(na=" ");Sr+=na}})(C,x+1,V);if(!H)return;let W=H.data,ae=H.index,ne=W.search(/\s/),_e=W,Re=!0;ne!==-1&&(_e=W.substring(0,ne),W=W.substring(ne+1).trimStart());let $e=_e;if(L){let Le=_e.indexOf(":");Le!==-1&&(_e=_e.substr(Le+1),Re=_e!==H.data.substr(Le+1))}return{tagName:_e,tagExp:W,closeIndex:ae,attrExpPresent:Re,rawTagName:$e}}function Dt(C,x,L){let V=L,H=1;for(;L<C.length;L++)if(C[L]==="<")if(C[L+1]==="/"){let W=ft(C,">",L,`${x} is not closed`);if(C.substring(L+2,W).trim()===x&&(H--,H===0))return{tagContent:C.substring(V,L),i:W};L=W}else if(C[L+1]==="?")L=ft(C,"?>",L+1,"StopNode is not closed.");else if(C.substr(L+1,3)==="!--")L=ft(C,"-->",L+3,"StopNode is not closed.");else if(C.substr(L+1,2)==="![")L=ft(C,"]]>",L,"StopNode is not closed.")-2;else{let W=wt(C,L,">");W&&((W&&W.tagName)===x&&W.tagExp[W.tagExp.length-1]!=="/"&&H++,L=W.closeIndex)}}function Ur(C,x,L){if(x&&typeof C=="string"){let V=C.trim();return V==="true"||V!=="false"&&(function(H,W={}){if(W=Object.assign({},ge,W),!H||typeof H!="string")return H;let ae=H.trim();if(W.skipLike!==void 0&&W.skipLike.test(ae))return H;if(H==="0")return 0;if(W.hex&&B.test(ae))return(function(_e){if(parseInt)return parseInt(_e,16);if(Number.parseInt)return Number.parseInt(_e,16);if(window&&window.parseInt)return window.parseInt(_e,16);throw new Error("parseInt, Number.parseInt, window.parseInt are not supported")})(ae);if(ae.search(/.+[eE].+/)!==-1)return(function(_e,Re,$e){if(!$e.eNotation)return _e;let Le=Re.match($);if(Le){let ht=Le[1]||"",kt=Le[3].indexOf("e")===-1?"E":"e",_t=Le[2],Sr=ht?_e[_t.length+1]===kt:_e[_t.length]===kt;return _t.length>1&&Sr?_e:_t.length!==1||!Le[3].startsWith(`.${kt}`)&&Le[3][0]!==kt?$e.leadingZeros&&!Sr?(Re=(Le[1]||"")+Le[3],Number(Re)):_e:Number(Re)}return _e})(H,ae,W);{let _e=te.exec(ae);if(_e){let Re=_e[1]||"",$e=_e[2],Le=((ne=_e[3])&&ne.indexOf(".")!==-1&&((ne=ne.replace(/0+$/,""))==="."?ne="0":ne[0]==="."?ne="0"+ne:ne[ne.length-1]==="."&&(ne=ne.substring(0,ne.length-1))),ne),ht=Re?H[$e.length+1]===".":H[$e.length]===".";if(!W.leadingZeros&&($e.length>1||$e.length===1&&!ht))return H;{let kt=Number(ae),_t=String(kt);if(kt===0||kt===-0)return kt;if(_t.search(/[eE]/)!==-1)return W.eNotation?kt:H;if(ae.indexOf(".")!==-1)return _t==="0"||_t===Le||_t===`${Re}${Le}`?kt:H;let Sr=$e?Le:ae;return $e?Sr===_t||Re+Sr===_t?kt:H:Sr===_t||Sr===Re+_t?kt:H}}return H}var ne})(C,L)}return C!==void 0?C:""}let Tt=M.getMetaDataSymbol();function gr(C,x){return Qi(C,x)}function Qi(C,x,L){let V,H={};for(let W=0;W<C.length;W++){let ae=C[W],ne=ta(ae),_e="";if(_e=L===void 0?ne:L+"."+ne,ne===x.textNodeName)V===void 0?V=ae[ne]:V+=""+ae[ne];else{if(ne===void 0)continue;if(ae[ne]){let Re=Qi(ae[ne],x,_e),$e=ra(Re,x);ae[Tt]!==void 0&&(Re[Tt]=ae[Tt]),ae[":@"]?Pi(Re,ae[":@"],_e,x):Object.keys(Re).length!==1||Re[x.textNodeName]===void 0||x.alwaysCreateTextNode?Object.keys(Re).length===0&&(x.alwaysCreateTextNode?Re[x.textNodeName]="":Re=""):Re=Re[x.textNodeName],H[ne]!==void 0&&H.hasOwnProperty(ne)?(Array.isArray(H[ne])||(H[ne]=[H[ne]]),H[ne].push(Re)):x.isArray(ne,_e,$e)?H[ne]=[Re]:H[ne]=Re}}}return typeof V=="string"?V.length>0&&(H[x.textNodeName]=V):V!==void 0&&(H[x.textNodeName]=V),H}function ta(C){let x=Object.keys(C);for(let L=0;L<x.length;L++){let V=x[L];if(V!==":@")return V}}function Pi(C,x,L,V){if(x){let H=Object.keys(x),W=H.length;for(let ae=0;ae<W;ae++){let ne=H[ae];V.isArray(ne,L+"."+ne,!0,!0)?C[ne]=[x[ne]]:C[ne]=x[ne]}}}function ra(C,x){let{textNodeName:L}=x,V=Object.keys(C).length;return V===0||!(V!==1||!C[L]&&typeof C[L]!="boolean"&&C[L]!==0)}class Bx{constructor(x){this.externalEntities={},this.options=(function(L){return Object.assign({},S,L)})(x)}parse(x,L){if(typeof x!="string"){if(!x.toString)throw new Error("XML data is accepted in String or Bytes[] form.");x=x.toString()}if(L){L===!0&&(L={});let W=a(x,L);if(W!==!0)throw Error(`${W.err.msg}:${W.err.line}:${W.err.col}`)}let V=new Ze(this.options);V.addExternalEntities(this.externalEntities);let H=V.parseXml(x);return this.options.preserveOrder||H===void 0?H:gr(H,this.options)}addEntity(x,L){if(L.indexOf("&")!==-1)throw new Error("Entity value can't have '&'");if(x.indexOf("&")!==-1||x.indexOf(";")!==-1)throw new Error("An entity must be set without '&' and ';'. Eg. use '#xD' for '
'");if(L==="&")throw new Error("An entity with value '&' is not permitted");this.externalEntities[x]=L}static getMetaDataSymbol(){return M.getMetaDataSymbol()}}function Yd(C,x){let L="";return x.format&&x.indentBy.length>0&&(L=`
|
|
220
|
+
`),Xg(C,x,"",L)}function Xg(C,x,L,V){let H="",W=!1;for(let ae=0;ae<C.length;ae++){let ne=C[ae],_e=ps(ne);if(_e===void 0)continue;let Re="";if(Re=L.length===0?_e:`${L}.${_e}`,_e===x.textNodeName){let kt=ne[_e];Yt(Re,x)||(kt=x.tagValueProcessor(_e,kt),kt=X(kt,x)),W&&(H+=V),H+=kt,W=!1;continue}if(_e===x.cdataPropName){W&&(H+=V),H+=`<![CDATA[${ne[_e][0][x.textNodeName]}]]>`,W=!1;continue}if(_e===x.commentPropName){H+=V+`<!--${ne[_e][0][x.textNodeName]}-->`,W=!0;continue}if(_e[0]==="?"){let kt=Xd(ne[":@"],x),_t=_e==="?xml"?"":V,Sr=ne[_e][0][x.textNodeName];Sr=Sr.length!==0?" "+Sr:"",H+=_t+`<${_e}${Sr}${kt}?>`,W=!0;continue}let $e=V;$e!==""&&($e+=x.indentBy);let Le=V+`<${_e}${Xd(ne[":@"],x)}`,ht=Xg(ne[_e],x,Re,$e);x.unpairedTags.indexOf(_e)!==-1?x.suppressUnpairedNode?H+=Le+">":H+=Le+"/>":ht&&ht.length!==0||!x.suppressEmptyNode?ht&&ht.endsWith(">")?H+=Le+`>${ht}${V}</${_e}>`:(H+=Le+">",ht&&V!==""&&(ht.includes("/>")||ht.includes("</"))?H+=V+x.indentBy+ht+V:H+=ht,H+=`</${_e}>`):H+=Le+"/>",W=!0}return H}function ps(C){let x=Object.keys(C);for(let L=0;L<x.length;L++){let V=x[L];if(C.hasOwnProperty(V)&&V!==":@")return V}}function Xd(C,x){let L="";if(C&&!x.ignoreAttributes)for(let V in C){if(!C.hasOwnProperty(V))continue;let H=x.attributeValueProcessor(V,C[V]);H=X(H,x),H===!0&&x.suppressBooleanAttributes?L+=` ${V.substr(x.attributeNamePrefix.length)}`:L+=` ${V.substr(x.attributeNamePrefix.length)}="${H}"`}return L}function Yt(C,x){let L=(C=C.substr(0,C.length-x.textNodeName.length-1)).substr(C.lastIndexOf(".")+1);for(let V in x.stopNodes)if(x.stopNodes[V]===C||x.stopNodes[V]==="*."+L)return!0;return!1}function X(C,x){if(C&&C.length>0&&x.processEntities)for(let L=0;L<x.entities.length;L++){let V=x.entities[L];C=C.replace(V.regex,V.val)}return C}let Q={attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,cdataPropName:!1,format:!1,indentBy:" ",suppressEmptyNode:!1,suppressUnpairedNode:!0,suppressBooleanAttributes:!0,tagValueProcessor:function(C,x){return x},attributeValueProcessor:function(C,x){return x},preserveOrder:!1,commentPropName:!1,unpairedTags:[],entities:[{regex:new RegExp("&","g"),val:"&"},{regex:new RegExp(">","g"),val:">"},{regex:new RegExp("<","g"),val:"<"},{regex:new RegExp("'","g"),val:"'"},{regex:new RegExp('"',"g"),val:"""}],processEntities:!0,stopNodes:[],oneListGroup:!1};function de(C){this.options=Object.assign({},Q,C),this.options.ignoreAttributes===!0||this.options.attributesGroupName?this.isAttribute=function(){return!1}:(this.ignoreAttributesFn=ve(this.options.ignoreAttributes),this.attrPrefixLen=this.options.attributeNamePrefix.length,this.isAttribute=ct),this.processTextOrObjNode=ye,this.options.format?(this.indentate=Ne,this.tagEndChar=`>
|
|
221
|
+
`,this.newLine=`
|
|
222
|
+
`):(this.indentate=function(){return""},this.tagEndChar=">",this.newLine="")}function ye(C,x,L,V){let H=this.j2x(C,L+1,V.concat(x));return C[this.options.textNodeName]!==void 0&&Object.keys(C).length===1?this.buildTextValNode(C[this.options.textNodeName],x,H.attrStr,L):this.buildObjectNode(H.val,x,H.attrStr,L)}function Ne(C){return this.options.indentBy.repeat(C)}function ct(C){return!(!C.startsWith(this.options.attributeNamePrefix)||C===this.options.textNodeName)&&C.substr(this.attrPrefixLen)}de.prototype.build=function(C){return this.options.preserveOrder?Yd(C,this.options):(Array.isArray(C)&&this.options.arrayNodeName&&this.options.arrayNodeName.length>1&&(C={[this.options.arrayNodeName]:C}),this.j2x(C,0,[]).val)},de.prototype.j2x=function(C,x,L){let V="",H="",W=L.join(".");for(let ae in C)if(Object.prototype.hasOwnProperty.call(C,ae))if(C[ae]===void 0)this.isAttribute(ae)&&(H+="");else if(C[ae]===null)this.isAttribute(ae)||ae===this.options.cdataPropName?H+="":ae[0]==="?"?H+=this.indentate(x)+"<"+ae+"?"+this.tagEndChar:H+=this.indentate(x)+"<"+ae+"/"+this.tagEndChar;else if(C[ae]instanceof Date)H+=this.buildTextValNode(C[ae],ae,"",x);else if(typeof C[ae]!="object"){let ne=this.isAttribute(ae);if(ne&&!this.ignoreAttributesFn(ne,W))V+=this.buildAttrPairStr(ne,""+C[ae]);else if(!ne)if(ae===this.options.textNodeName){let _e=this.options.tagValueProcessor(ae,""+C[ae]);H+=this.replaceEntitiesValue(_e)}else H+=this.buildTextValNode(C[ae],ae,"",x)}else if(Array.isArray(C[ae])){let ne=C[ae].length,_e="",Re="";for(let $e=0;$e<ne;$e++){let Le=C[ae][$e];if(Le!==void 0)if(Le===null)ae[0]==="?"?H+=this.indentate(x)+"<"+ae+"?"+this.tagEndChar:H+=this.indentate(x)+"<"+ae+"/"+this.tagEndChar;else if(typeof Le=="object")if(this.options.oneListGroup){let ht=this.j2x(Le,x+1,L.concat(ae));_e+=ht.val,this.options.attributesGroupName&&Le.hasOwnProperty(this.options.attributesGroupName)&&(Re+=ht.attrStr)}else _e+=this.processTextOrObjNode(Le,ae,x,L);else if(this.options.oneListGroup){let ht=this.options.tagValueProcessor(ae,Le);ht=this.replaceEntitiesValue(ht),_e+=ht}else _e+=this.buildTextValNode(Le,ae,"",x)}this.options.oneListGroup&&(_e=this.buildObjectNode(_e,ae,Re,x)),H+=_e}else if(this.options.attributesGroupName&&ae===this.options.attributesGroupName){let ne=Object.keys(C[ae]),_e=ne.length;for(let Re=0;Re<_e;Re++)V+=this.buildAttrPairStr(ne[Re],""+C[ae][ne[Re]])}else H+=this.processTextOrObjNode(C[ae],ae,x,L);return{attrStr:V,val:H}},de.prototype.buildAttrPairStr=function(C,x){return x=this.options.attributeValueProcessor(C,""+x),x=this.replaceEntitiesValue(x),this.options.suppressBooleanAttributes&&x==="true"?" "+C:" "+C+'="'+x+'"'},de.prototype.buildObjectNode=function(C,x,L,V){if(C==="")return x[0]==="?"?this.indentate(V)+"<"+x+L+"?"+this.tagEndChar:this.indentate(V)+"<"+x+L+this.closeTag(x)+this.tagEndChar;{let H="</"+x+this.tagEndChar,W="";return x[0]==="?"&&(W="?",H=""),!L&&L!==""||C.indexOf("<")!==-1?this.options.commentPropName!==!1&&x===this.options.commentPropName&&W.length===0?this.indentate(V)+`<!--${C}-->`+this.newLine:this.indentate(V)+"<"+x+L+W+this.tagEndChar+C+this.indentate(V)+H:this.indentate(V)+"<"+x+L+W+">"+C+H}},de.prototype.closeTag=function(C){let x="";return this.options.unpairedTags.indexOf(C)!==-1?this.options.suppressUnpairedNode||(x="/"):x=this.options.suppressEmptyNode?"/":`></${C}`,x},de.prototype.buildTextValNode=function(C,x,L,V){if(this.options.cdataPropName!==!1&&x===this.options.cdataPropName)return this.indentate(V)+`<![CDATA[${C}]]>`+this.newLine;if(this.options.commentPropName!==!1&&x===this.options.commentPropName)return this.indentate(V)+`<!--${C}-->`+this.newLine;if(x[0]==="?")return this.indentate(V)+"<"+x+L+"?"+this.tagEndChar;{let H=this.options.tagValueProcessor(x,C);return H=this.replaceEntitiesValue(H),H===""?this.indentate(V)+"<"+x+L+this.closeTag(x)+this.tagEndChar:this.indentate(V)+"<"+x+L+">"+H+"</"+x+this.tagEndChar}},de.prototype.replaceEntitiesValue=function(C){if(C&&C.length>0&&this.options.processEntities)for(let x=0;x<this.options.entities.length;x++){let L=this.options.entities[x];C=C.replace(L.regex,L.val)}return C};let Bt={validate:a};y8.exports=t})()});var b8=E(BO=>{"use strict";Object.defineProperty(BO,"__esModule",{value:!0});BO.parseXML=JCe;var XCe=_8(),LO=new XCe.XMLParser({attributeNamePrefix:"",htmlEntities:!0,ignoreAttributes:!1,ignoreDeclaration:!0,parseTagValue:!1,trimValues:!1,tagValueProcessor:(e,t)=>t.trim()===""&&t.includes(`
|
|
223
|
+
`)?"":void 0});LO.addEntity("#xD","\r");LO.addEntity("#10",`
|
|
224
|
+
`);function JCe(e){return LO.parse(e,!0)}});var Nb=E(kb=>{"use strict";var QCe=b8();function ZCe(e){return e.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""")}function exe(e){return e.replace(/&/g,"&").replace(/"/g,""").replace(/'/g,"'").replace(/</g,"<").replace(/>/g,">").replace(/\r/g,"
").replace(/\n/g,"
").replace(/\u0085/g,"…").replace(/\u2028/,"
")}var Db=class{value;constructor(t){this.value=t}toString(){return exe(""+this.value)}},FO=class e{name;children;attributes={};static of(t,r,n){let i=new e(t);return r!==void 0&&i.addChildNode(new Db(r)),n!==void 0&&i.withName(n),i}constructor(t,r=[]){this.name=t,this.children=r}withName(t){return this.name=t,this}addAttribute(t,r){return this.attributes[t]=r,this}addChildNode(t){return this.children.push(t),this}removeAttribute(t){return delete this.attributes[t],this}n(t){return this.name=t,this}c(t){return this.children.push(t),this}a(t,r){return r!=null&&(this.attributes[t]=r),this}cc(t,r,n=r){if(t[r]!=null){let i=e.of(r,t[r]).withName(n);this.c(i)}}l(t,r,n,i){t[r]!=null&&i().map(s=>{s.withName(n),this.c(s)})}lc(t,r,n,i){if(t[r]!=null){let o=i(),s=new e(n);o.map(a=>{s.c(a)}),this.c(s)}}toString(){let t=!!this.children.length,r=`<${this.name}`,n=this.attributes;for(let i of Object.keys(n)){let o=n[i];o!=null&&(r+=` ${i}="${ZCe(""+o)}"`)}return r+=t?`>${this.children.map(i=>i.toString()).join("")}</${this.name}>`:"/>"}};Object.defineProperty(kb,"parseXML",{enumerable:!0,get:function(){return QCe.parseXML}});kb.XmlNode=FO;kb.XmlText=Db});var E8,w8,S8,La,Mb=Y(()=>{"use strict";E8=z(Nb());oi();xt();w8=z(Ge()),S8=z(Cr());Da();La=class extends vn{settings;stringDeserializer;constructor(t){super(),this.settings=t,this.stringDeserializer=new ru(t)}setSerdeContext(t){this.serdeContext=t,this.stringDeserializer.setSerdeContext(t)}read(t,r,n){let i=ke.of(t),o=i.getMemberSchemas();if(i.isStructSchema()&&i.isMemberSchema()&&!!Object.values(o).find(u=>!!u.getMemberTraits().eventPayload)){let u={},l=Object.keys(o)[0];return o[l].isBlobSchema()?u[l]=r:u[l]=this.read(o[l],r),u}let a=(this.serdeContext?.utf8Encoder??S8.toUtf8)(r),c=this.parseXml(a);return this.readSchema(t,n?c[n]:c)}readSchema(t,r){let n=ke.of(t);if(n.isUnitSchema())return;let i=n.getMergedTraits();if(n.isListSchema()&&!Array.isArray(r))return this.readSchema(n,[r]);if(r==null)return r;if(typeof r=="object"){let o=!!i.sparse,s=!!i.xmlFlattened;if(n.isListSchema()){let c=n.getValueSchema(),u=[],l=c.getMergedTraits().xmlName??"member",d=s?r:(r[0]??r)[l],h=Array.isArray(d)?d:[d];for(let f of h)(f!=null||o)&&u.push(this.readSchema(c,f));return u}let a={};if(n.isMapSchema()){let c=n.getKeySchema(),u=n.getValueSchema(),l;s?l=Array.isArray(r)?r:[r]:l=Array.isArray(r.entry)?r.entry:[r.entry];let d=c.getMergedTraits().xmlName??"key",h=u.getMergedTraits().xmlName??"value";for(let f of l){let p=f[d],m=f[h];(m!=null||o)&&(a[p]=this.readSchema(u,m))}return a}if(n.isStructSchema()){for(let[c,u]of n.structIterator()){let l=u.getMergedTraits(),d=l.httpPayload?l.xmlName??u.getName():u.getMemberTraits().xmlName??c;r[d]!=null&&(a[c]=this.readSchema(u,r[d]))}return a}if(n.isDocumentSchema())return r;throw new Error(`@aws-sdk/core/protocols - xml deserializer unhandled schema type for ${n.getName(!0)}`)}return n.isListSchema()?[]:n.isMapSchema()||n.isStructSchema()?{}:this.stringDeserializer.read(n,r)}parseXml(t){if(t.length){let r;try{r=(0,E8.parseXML)(t)}catch(s){throw s&&typeof s=="object"&&Object.defineProperty(s,"$responseBodyText",{value:t}),s}let n="#text",i=Object.keys(r)[0],o=r[i];return o[n]&&(o[i]=o[n],delete o[n]),(0,w8.getValueFromTextNode)(o)}return{}}}});var v8,C8,Lb,x8=Y(()=>{"use strict";oi();xt();ii();v8=z(Ge()),C8=z(Gr());Da();ah();Lb=class extends vn{settings;buffer;constructor(t){super(),this.settings=t}write(t,r,n=""){this.buffer===void 0&&(this.buffer="");let i=ke.of(t);if(n&&!n.endsWith(".")&&(n+="."),i.isBlobSchema())(typeof r=="string"||r instanceof Uint8Array)&&(this.writeKey(n),this.writeValue((this.serdeContext?.base64Encoder??C8.toBase64)(r)));else if(i.isBooleanSchema()||i.isNumericSchema()||i.isStringSchema())r!=null?(this.writeKey(n),this.writeValue(String(r))):i.isIdempotencyToken()&&(this.writeKey(n),this.writeValue((0,Mi.v4)()));else if(i.isBigIntegerSchema())r!=null&&(this.writeKey(n),this.writeValue(String(r)));else if(i.isBigDecimalSchema())r!=null&&(this.writeKey(n),this.writeValue(r instanceof tr?r.string:String(r)));else if(i.isTimestampSchema()){if(r instanceof Date)switch(this.writeKey(n),gi(i,this.settings)){case 5:this.writeValue(r.toISOString().replace(".000Z","Z"));break;case 6:this.writeValue((0,v8.dateToUtcString)(r));break;case 7:this.writeValue(String(r.getTime()/1e3));break}}else{if(i.isDocumentSchema())throw new Error(`@aws-sdk/core/protocols - QuerySerializer unsupported document type ${i.getName(!0)}`);if(i.isListSchema()){if(Array.isArray(r))if(r.length===0)this.settings.serializeEmptyLists&&(this.writeKey(n),this.writeValue(""));else{let o=i.getValueSchema(),s=this.settings.flattenLists||i.getMergedTraits().xmlFlattened,a=1;for(let c of r){if(c==null)continue;let u=this.getKey("member",o.getMergedTraits().xmlName),l=s?`${n}${a}`:`${n}${u}.${a}`;this.write(o,c,l),++a}}}else if(i.isMapSchema()){if(r&&typeof r=="object"){let o=i.getKeySchema(),s=i.getValueSchema(),a=i.getMergedTraits().xmlFlattened,c=1;for(let[u,l]of Object.entries(r)){if(l==null)continue;let d=this.getKey("key",o.getMergedTraits().xmlName),h=a?`${n}${c}.${d}`:`${n}entry.${c}.${d}`,f=this.getKey("value",s.getMergedTraits().xmlName),p=a?`${n}${c}.${f}`:`${n}entry.${c}.${f}`;this.write(o,u,h),this.write(s,l,p),++c}}}else if(i.isStructSchema()){if(r&&typeof r=="object")for(let[o,s]of Jl(i,r)){if(r[o]==null&&!s.isIdempotencyToken())continue;let a=this.getKey(o,s.getMergedTraits().xmlName),c=`${n}${a}`;this.write(s,r[o],c)}}else if(!i.isUnitSchema())throw new Error(`@aws-sdk/core/protocols - QuerySerializer unrecognized schema type ${i.getName(!0)}`)}}flush(){if(this.buffer===void 0)throw new Error("@aws-sdk/core/protocols - QuerySerializer cannot flush with nothing written to buffer.");let t=this.buffer;return delete this.buffer,t}getKey(t,r){let n=r??t;return this.settings.capitalizeKeys?n[0].toUpperCase()+n.slice(1):n}writeKey(t){t.endsWith(".")&&(t=t.slice(0,t.length-1)),this.buffer+=`&${Mo(t)}=`}writeValue(t){this.buffer+=Mo(t)}}});var Ba,qO=Y(()=>{"use strict";oi();xt();Xl();Mb();x8();Ba=class extends Ps{options;serializer;deserializer;mixin=new Li;constructor(t){super({defaultNamespace:t.defaultNamespace}),this.options=t;let r={timestampFormat:{useTrait:!0,default:5},httpBindings:!1,xmlNamespace:t.xmlNamespace,serviceNamespace:t.defaultNamespace,serializeEmptyLists:!0};this.serializer=new Lb(r),this.deserializer=new La(r)}getShapeId(){return"aws.protocols#awsQuery"}setSerdeContext(t){this.serializer.setSerdeContext(t),this.deserializer.setSerdeContext(t)}getPayloadCodec(){throw new Error("AWSQuery protocol has no payload codec.")}async serializeRequest(t,r,n){let i=await super.serializeRequest(t,r,n);i.path.endsWith("/")||(i.path+="/"),Object.assign(i.headers,{"content-type":"application/x-www-form-urlencoded"}),(io(t.input)==="unit"||!i.body)&&(i.body="");let o=t.name.split("#")[1]??t.name;return i.body=`Action=${o}&Version=${this.options.version}`+i.body,i.body.endsWith("&")&&(i.body=i.body.slice(-1)),i}async deserializeResponse(t,r,n){let i=this.deserializer,o=ke.of(t.output),s={};if(n.statusCode>=300){let d=await Ni(n.body,r);d.byteLength>0&&Object.assign(s,await i.read(15,d)),await this.handleError(t,r,n,s,this.deserializeMetadata(n))}for(let d in n.headers){let h=n.headers[d];delete n.headers[d],n.headers[d.toLowerCase()]=h}let a=t.name.split("#")[1]??t.name,c=o.isStructSchema()&&this.useNestedResult()?a+"Result":void 0,u=await Ni(n.body,r);return u.byteLength>0&&Object.assign(s,await i.read(o,u,c)),{$metadata:this.deserializeMetadata(n),...s}}useNestedResult(){return!0}async handleError(t,r,n,i,o){let s=this.loadQueryErrorCode(n,i)??"Unknown",a=this.loadQueryError(i),c=this.loadQueryErrorMessage(i);a.message=c,a.Error={Type:a.Type,Code:a.Code,Message:c};let{errorSchema:u,errorMetadata:l}=await this.mixin.getErrorSchemaOrThrowBaseException(s,this.options.defaultNamespace,n,a,o,(m,_)=>{try{return m.getSchema(_)}catch{return m.find(R=>ke.of(R).getMergedTraits().awsQueryError?.[0]===_)}}),d=ke.of(u),h=Ue.for(u[1]).getErrorCtor(u)??Error,f=new h(c),p={Error:a.Error};for(let[m,_]of d.structIterator()){let w=_.getMergedTraits().xmlName??m,R=a[w]??i[w];p[m]=this.deserializer.readSchema(_,R)}throw this.mixin.decorateServiceException(Object.assign(f,l,{$fault:d.getMergedTraits().error,message:c},p),i)}loadQueryErrorCode(t,r){let n=(r.Errors?.[0]?.Error??r.Errors?.Error??r.Error)?.Code;if(n!==void 0)return n;if(t.statusCode==404)return"NotFound"}loadQueryError(t){return t.Errors?.[0]?.Error??t.Errors?.Error??t.Error}loadQueryErrorMessage(t){let r=this.loadQueryError(t);return r?.message??r?.Message??t.message??t.Message??"Unknown"}getDefaultContentType(){return"application/x-www-form-urlencoded"}}});var Bb,T8=Y(()=>{"use strict";qO();Bb=class extends Ba{options;constructor(t){super(t),this.options=t;let r={capitalizeKeys:!0,flattenLists:!0,serializeEmptyLists:!1};Object.assign(this.serializer.settings,r)}useNestedResult(){return!1}}});var A8,R8,jO,P8,Fb,UO=Y(()=>{"use strict";A8=z(Nb()),R8=z(Ge());DO();jO=(e,t)=>Tb(e,t).then(r=>{if(r.length){let n;try{n=(0,A8.parseXML)(r)}catch(a){throw a&&typeof a=="object"&&Object.defineProperty(a,"$responseBodyText",{value:r}),a}let i="#text",o=Object.keys(n)[0],s=n[o];return s[i]&&(s[o]=s[i],delete s[i]),(0,R8.getValueFromTextNode)(s)}return{}}),P8=async(e,t)=>{let r=await jO(e,t);return r.Error&&(r.Error.message=r.Error.message??r.Error.Message),r},Fb=(e,t)=>{if(t?.Error?.Code!==void 0)return t.Error.Code;if(t?.Code!==void 0)return t.Code;if(e.statusCode==404)return"NotFound"}});var Bi,HO,qb,tf,$O=Y(()=>{"use strict";Bi=z(Nb());oi();xt();ii();HO=z(Ge()),qb=z(Gr());Da();ah();tf=class extends vn{settings;stringBuffer;byteBuffer;buffer;constructor(t){super(),this.settings=t}write(t,r){let n=ke.of(t);if(n.isStringSchema()&&typeof r=="string")this.stringBuffer=r;else if(n.isBlobSchema())this.byteBuffer="byteLength"in r?r:(this.serdeContext?.base64Decoder??qb.fromBase64)(r);else{this.buffer=this.writeStruct(n,r,void 0);let i=n.getMergedTraits();i.httpPayload&&!i.xmlName&&this.buffer.withName(n.getName())}}flush(){if(this.byteBuffer!==void 0){let r=this.byteBuffer;return delete this.byteBuffer,r}if(this.stringBuffer!==void 0){let r=this.stringBuffer;return delete this.stringBuffer,r}let t=this.buffer;return this.settings.xmlNamespace&&(t?.attributes?.xmlns||t.addAttribute("xmlns",this.settings.xmlNamespace)),delete this.buffer,t.toString()}writeStruct(t,r,n){let i=t.getMergedTraits(),o=t.isMemberSchema()&&!i.httpPayload?t.getMemberTraits().xmlName??t.getMemberName():i.xmlName??t.getName();if(!o||!t.isStructSchema())throw new Error(`@aws-sdk/core/protocols - xml serializer, cannot write struct with empty name or non-struct, schema=${t.getName(!0)}.`);let s=Bi.XmlNode.of(o),[a,c]=this.getXmlnsAttribute(t,n);for(let[u,l]of Jl(t,r)){let d=r[u];if(d!=null||l.isIdempotencyToken()){if(l.getMergedTraits().xmlAttribute){s.addAttribute(l.getMergedTraits().xmlName??u,this.writeSimple(l,d));continue}if(l.isListSchema())this.writeList(l,d,s,c);else if(l.isMapSchema())this.writeMap(l,d,s,c);else if(l.isStructSchema())s.addChildNode(this.writeStruct(l,d,c));else{let h=Bi.XmlNode.of(l.getMergedTraits().xmlName??l.getMemberName());this.writeSimpleInto(l,d,h,c),s.addChildNode(h)}}}return c&&s.addAttribute(a,c),s}writeList(t,r,n,i){if(!t.isMemberSchema())throw new Error(`@aws-sdk/core/protocols - xml serializer, cannot write non-member list: ${t.getName(!0)}`);let o=t.getMergedTraits(),s=t.getValueSchema(),a=s.getMergedTraits(),c=!!a.sparse,u=!!o.xmlFlattened,[l,d]=this.getXmlnsAttribute(t,i),h=(f,p)=>{if(s.isListSchema())this.writeList(s,Array.isArray(p)?p:[p],f,d);else if(s.isMapSchema())this.writeMap(s,p,f,d);else if(s.isStructSchema()){let m=this.writeStruct(s,p,d);f.addChildNode(m.withName(u?o.xmlName??t.getMemberName():a.xmlName??"member"))}else{let m=Bi.XmlNode.of(u?o.xmlName??t.getMemberName():a.xmlName??"member");this.writeSimpleInto(s,p,m,d),f.addChildNode(m)}};if(u)for(let f of r)(c||f!=null)&&h(n,f);else{let f=Bi.XmlNode.of(o.xmlName??t.getMemberName());d&&f.addAttribute(l,d);for(let p of r)(c||p!=null)&&h(f,p);n.addChildNode(f)}}writeMap(t,r,n,i,o=!1){if(!t.isMemberSchema())throw new Error(`@aws-sdk/core/protocols - xml serializer, cannot write non-member map: ${t.getName(!0)}`);let s=t.getMergedTraits(),a=t.getKeySchema(),u=a.getMergedTraits().xmlName??"key",l=t.getValueSchema(),d=l.getMergedTraits(),h=d.xmlName??"value",f=!!d.sparse,p=!!s.xmlFlattened,[m,_]=this.getXmlnsAttribute(t,i),w=(R,v,y)=>{let S=Bi.XmlNode.of(u,v),[O,M]=this.getXmlnsAttribute(a,_);M&&S.addAttribute(O,M),R.addChildNode(S);let A=Bi.XmlNode.of(h);l.isListSchema()?this.writeList(l,y,A,_):l.isMapSchema()?this.writeMap(l,y,A,_,!0):l.isStructSchema()?A=this.writeStruct(l,y,_):this.writeSimpleInto(l,y,A,_),R.addChildNode(A)};if(p){for(let[R,v]of Object.entries(r))if(f||v!=null){let y=Bi.XmlNode.of(s.xmlName??t.getMemberName());w(y,R,v),n.addChildNode(y)}}else{let R;o||(R=Bi.XmlNode.of(s.xmlName??t.getMemberName()),_&&R.addAttribute(m,_),n.addChildNode(R));for(let[v,y]of Object.entries(r))if(f||y!=null){let S=Bi.XmlNode.of("entry");w(S,v,y),(o?n:R).addChildNode(S)}}}writeSimple(t,r){if(r===null)throw new Error("@aws-sdk/core/protocols - (XML serializer) cannot write null value.");let n=ke.of(t),i=null;if(r&&typeof r=="object")if(n.isBlobSchema())i=(this.serdeContext?.base64Encoder??qb.toBase64)(r);else if(n.isTimestampSchema()&&r instanceof Date)switch(gi(n,this.settings)){case 5:i=r.toISOString().replace(".000Z","Z");break;case 6:i=(0,HO.dateToUtcString)(r);break;case 7:i=String(r.getTime()/1e3);break;default:console.warn("Missing timestamp format, using http date",r),i=(0,HO.dateToUtcString)(r);break}else{if(n.isBigDecimalSchema()&&r)return r instanceof tr?r.string:String(r);throw n.isMapSchema()||n.isListSchema()?new Error("@aws-sdk/core/protocols - xml serializer, cannot call _write() on List/Map schema, call writeList or writeMap() instead."):new Error(`@aws-sdk/core/protocols - xml serializer, unhandled schema type for object value and schema: ${n.getName(!0)}`)}if((n.isBooleanSchema()||n.isNumericSchema()||n.isBigIntegerSchema()||n.isBigDecimalSchema())&&(i=String(r)),n.isStringSchema()&&(r===void 0&&n.isIdempotencyToken()?i=(0,Mi.v4)():i=String(r)),i===null)throw new Error(`Unhandled schema-value pair ${n.getName(!0)}=${r}`);return i}writeSimpleInto(t,r,n,i){let o=this.writeSimple(t,r),s=ke.of(t),a=new Bi.XmlText(o),[c,u]=this.getXmlnsAttribute(s,i);u&&n.addAttribute(c,u),n.addChildNode(a)}getXmlnsAttribute(t,r){let n=t.getMergedTraits(),[i,o]=n.xmlNamespace??[];return o&&o!==r?[i?`xmlns:${i}`:"xmlns",o]:[void 0,void 0]}}});var rf,GO=Y(()=>{"use strict";Da();Mb();$O();rf=class extends vn{settings;constructor(t){super(),this.settings=t}createSerializer(){let t=new tf(this.settings);return t.setSerdeContext(this.serdeContext),t}createDeserializer(){let t=new La(this.settings);return t.setSerdeContext(this.serdeContext),t}}});var jb,O8=Y(()=>{"use strict";oi();xt();Xl();UO();GO();jb=class extends tu{codec;serializer;deserializer;mixin=new Li;constructor(t){super(t);let r={timestampFormat:{useTrait:!0,default:5},httpBindings:!0,xmlNamespace:t.xmlNamespace,serviceNamespace:t.defaultNamespace};this.codec=new rf(r),this.serializer=new iu(this.codec.createSerializer(),r),this.deserializer=new nu(this.codec.createDeserializer(),r)}getPayloadCodec(){return this.codec}getShapeId(){return"aws.protocols#restXml"}async serializeRequest(t,r,n){let i=await super.serializeRequest(t,r,n),o=ke.of(t.input);if(!i.headers["content-type"]){let s=this.mixin.resolveRestContentType(this.getDefaultContentType(),o);s&&(i.headers["content-type"]=s)}return i.headers["content-type"]===this.getDefaultContentType()&&typeof i.body=="string"&&(i.body='<?xml version="1.0" encoding="UTF-8"?>'+i.body),i}async deserializeResponse(t,r,n){return super.deserializeResponse(t,r,n)}async handleError(t,r,n,i,o){let s=Fb(n,i)??"Unknown",{errorSchema:a,errorMetadata:c}=await this.mixin.getErrorSchemaOrThrowBaseException(s,this.options.defaultNamespace,n,i,o),u=ke.of(a),l=i.Error?.message??i.Error?.Message??i.message??i.Message??"Unknown",d=Ue.for(a[1]).getErrorCtor(a)??Error,h=new d(l);await this.deserializeHttpMessage(a,r,n,i);let f={};for(let[p,m]of u.structIterator()){let _=m.getMergedTraits().xmlName??p,w=i.Error?.[_]??i[_];f[p]=this.codec.createDeserializer().readSchema(m,w)}throw this.mixin.decorateServiceException(Object.assign(h,c,{$fault:u.getMergedTraits().error,message:l},f),i)}getDefaultContentType(){return"application/xml"}}});var zO={};Nn(zO,{AwsEc2QueryProtocol:()=>Bb,AwsJson1_0Protocol:()=>Ob,AwsJson1_1Protocol:()=>Ib,AwsJsonRpcProtocol:()=>Na,AwsQueryProtocol:()=>Ba,AwsRestJsonProtocol:()=>Ma,AwsRestXmlProtocol:()=>jb,AwsSmithyRpcV2CborProtocol:()=>xb,JsonCodec:()=>ka,JsonShapeDeserializer:()=>Zl,JsonShapeSerializer:()=>ef,XmlCodec:()=>rf,XmlShapeDeserializer:()=>La,XmlShapeSerializer:()=>tf,_toBool:()=>Z$,_toNum:()=>e8,_toStr:()=>Q$,awsExpectUnion:()=>m8,loadRestJsonErrorCode:()=>Ql,loadRestXmlErrorCode:()=>Fb,parseJsonBody:()=>ch,parseJsonErrorBody:()=>a8,parseXmlBody:()=>jO,parseXmlErrorBody:()=>P8});var uu=Y(()=>{"use strict";J$();t8();f8();d8();Pb();p8();Rb();kO();MO();g8();uh();T8();qO();O8();GO();Mb();$O();UO()});var Uo={};Nn(Uo,{AWSSDKSigV4Signer:()=>gR,AwsEc2QueryProtocol:()=>Bb,AwsJson1_0Protocol:()=>Ob,AwsJson1_1Protocol:()=>Ib,AwsJsonRpcProtocol:()=>Na,AwsQueryProtocol:()=>Ba,AwsRestJsonProtocol:()=>Ma,AwsRestXmlProtocol:()=>jb,AwsSdkSigV4ASigner:()=>$p,AwsSdkSigV4Signer:()=>bn,AwsSmithyRpcV2CborProtocol:()=>xb,JsonCodec:()=>ka,JsonShapeDeserializer:()=>Zl,JsonShapeSerializer:()=>ef,NODE_AUTH_SCHEME_PREFERENCE_OPTIONS:()=>wa,NODE_SIGV4A_CONFIG_OPTIONS:()=>Y6,XmlCodec:()=>rf,XmlShapeDeserializer:()=>La,XmlShapeSerializer:()=>tf,_toBool:()=>Z$,_toNum:()=>e8,_toStr:()=>Q$,awsExpectUnion:()=>m8,emitWarningIfUnsupportedVersion:()=>ba,getBearerTokenEnvKey:()=>__,loadRestJsonErrorCode:()=>Ql,loadRestXmlErrorCode:()=>Fb,parseJsonBody:()=>ch,parseJsonErrorBody:()=>a8,parseXmlBody:()=>jO,parseXmlErrorBody:()=>P8,resolveAWSSDKSigV4Config:()=>E$,resolveAwsSdkSigV4AConfig:()=>K6,resolveAwsSdkSigV4Config:()=>Is,setCredentialFeature:()=>Ea,setFeature:()=>T4,setTokenFeature:()=>R4,state:()=>y_,validateSigningProperties:()=>Ll});var Dr=Y(()=>{"use strict";ki();iO();uu()});var k8=E((_bt,D8)=>{"use strict";var Ub=Object.defineProperty,txe=Object.getOwnPropertyDescriptor,rxe=Object.getOwnPropertyNames,nxe=Object.prototype.hasOwnProperty,ixe=(e,t)=>Ub(e,"name",{value:t,configurable:!0}),oxe=(e,t)=>{for(var r in t)Ub(e,r,{get:t[r],enumerable:!0})},sxe=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of rxe(t))!nxe.call(e,i)&&i!==r&&Ub(e,i,{get:()=>t[i],enumerable:!(n=txe(t,i))||n.enumerable});return e},axe=e=>sxe(Ub({},"__esModule",{value:!0}),e),I8={};oxe(I8,{isArrayBuffer:()=>cxe});D8.exports=axe(I8);var cxe=ixe(e=>typeof ArrayBuffer=="function"&&e instanceof ArrayBuffer||Object.prototype.toString.call(e)==="[object ArrayBuffer]","isArrayBuffer")});var B8=E((bbt,L8)=>{"use strict";var Hb=Object.defineProperty,uxe=Object.getOwnPropertyDescriptor,lxe=Object.getOwnPropertyNames,fxe=Object.prototype.hasOwnProperty,N8=(e,t)=>Hb(e,"name",{value:t,configurable:!0}),dxe=(e,t)=>{for(var r in t)Hb(e,r,{get:t[r],enumerable:!0})},pxe=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of lxe(t))!fxe.call(e,i)&&i!==r&&Hb(e,i,{get:()=>t[i],enumerable:!(n=uxe(t,i))||n.enumerable});return e},hxe=e=>pxe(Hb({},"__esModule",{value:!0}),e),M8={};dxe(M8,{fromArrayBuffer:()=>gxe,fromString:()=>yxe});L8.exports=hxe(M8);var mxe=k8(),VO=require("buffer"),gxe=N8((e,t=0,r=e.byteLength-t)=>{if(!(0,mxe.isArrayBuffer)(e))throw new TypeError(`The "input" argument must be ArrayBuffer. Received type ${typeof e} (${e})`);return VO.Buffer.from(e,t,r)},"fromArrayBuffer"),yxe=N8((e,t)=>{if(typeof e!="string")throw new TypeError(`The "input" argument must be of type string. Received type ${typeof e} (${e})`);return t?VO.Buffer.from(e,t):VO.Buffer.from(e)},"fromString")});var H8=E((Ebt,U8)=>{"use strict";var $b=Object.defineProperty,_xe=Object.getOwnPropertyDescriptor,bxe=Object.getOwnPropertyNames,Exe=Object.prototype.hasOwnProperty,WO=(e,t)=>$b(e,"name",{value:t,configurable:!0}),wxe=(e,t)=>{for(var r in t)$b(e,r,{get:t[r],enumerable:!0})},Sxe=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of bxe(t))!Exe.call(e,i)&&i!==r&&$b(e,i,{get:()=>t[i],enumerable:!(n=_xe(t,i))||n.enumerable});return e},vxe=e=>Sxe($b({},"__esModule",{value:!0}),e),F8={};wxe(F8,{fromUtf8:()=>j8,toUint8Array:()=>Cxe,toUtf8:()=>xxe});U8.exports=vxe(F8);var q8=B8(),j8=WO(e=>{let t=(0,q8.fromString)(e,"utf8");return new Uint8Array(t.buffer,t.byteOffset,t.byteLength/Uint8Array.BYTES_PER_ELEMENT)},"fromUtf8"),Cxe=WO(e=>typeof e=="string"?j8(e):ArrayBuffer.isView(e)?new Uint8Array(e.buffer,e.byteOffset,e.byteLength/Uint8Array.BYTES_PER_ELEMENT):new Uint8Array(e),"toUint8Array"),xxe=WO(e=>{if(typeof e=="string")return e;if(typeof e!="object"||typeof e.byteOffset!="number"||typeof e.byteLength!="number")throw new Error("@smithy/util-utf8: toUtf8 encoder function only accepts string | Uint8Array.");return(0,q8.fromArrayBuffer)(e.buffer,e.byteOffset,e.byteLength).toString("utf8")},"toUtf8")});var $8=E(Gb=>{"use strict";Object.defineProperty(Gb,"__esModule",{value:!0});Gb.convertToBuffer=void 0;var Txe=H8(),Axe=typeof Buffer<"u"&&Buffer.from?function(e){return Buffer.from(e,"utf8")}:Txe.fromUtf8;function Rxe(e){return e instanceof Uint8Array?e:typeof e=="string"?Axe(e):ArrayBuffer.isView(e)?new Uint8Array(e.buffer,e.byteOffset,e.byteLength/Uint8Array.BYTES_PER_ELEMENT):new Uint8Array(e)}Gb.convertToBuffer=Rxe});var G8=E(zb=>{"use strict";Object.defineProperty(zb,"__esModule",{value:!0});zb.isEmptyData=void 0;function Pxe(e){return typeof e=="string"?e.length===0:e.byteLength===0}zb.isEmptyData=Pxe});var z8=E(Vb=>{"use strict";Object.defineProperty(Vb,"__esModule",{value:!0});Vb.numToUint8=void 0;function Oxe(e){return new Uint8Array([(e&4278190080)>>24,(e&16711680)>>16,(e&65280)>>8,e&255])}Vb.numToUint8=Oxe});var V8=E(Wb=>{"use strict";Object.defineProperty(Wb,"__esModule",{value:!0});Wb.uint32ArrayFrom=void 0;function Ixe(e){if(!Uint32Array.from){for(var t=new Uint32Array(e.length),r=0;r<e.length;)t[r]=e[r],r+=1;return t}return Uint32Array.from(e)}Wb.uint32ArrayFrom=Ixe});var nf=E(Ho=>{"use strict";Object.defineProperty(Ho,"__esModule",{value:!0});Ho.uint32ArrayFrom=Ho.numToUint8=Ho.isEmptyData=Ho.convertToBuffer=void 0;var Dxe=$8();Object.defineProperty(Ho,"convertToBuffer",{enumerable:!0,get:function(){return Dxe.convertToBuffer}});var kxe=G8();Object.defineProperty(Ho,"isEmptyData",{enumerable:!0,get:function(){return kxe.isEmptyData}});var Nxe=z8();Object.defineProperty(Ho,"numToUint8",{enumerable:!0,get:function(){return Nxe.numToUint8}});var Mxe=V8();Object.defineProperty(Ho,"uint32ArrayFrom",{enumerable:!0,get:function(){return Mxe.uint32ArrayFrom}})});var Y8=E(Kb=>{"use strict";Object.defineProperty(Kb,"__esModule",{value:!0});Kb.AwsCrc32c=void 0;var W8=(qo(),Ve(Fo)),KO=nf(),K8=YO(),Lxe=(function(){function e(){this.crc32c=new K8.Crc32c}return e.prototype.update=function(t){(0,KO.isEmptyData)(t)||this.crc32c.update((0,KO.convertToBuffer)(t))},e.prototype.digest=function(){return W8.__awaiter(this,void 0,void 0,function(){return W8.__generator(this,function(t){return[2,(0,KO.numToUint8)(this.crc32c.digest())]})})},e.prototype.reset=function(){this.crc32c=new K8.Crc32c},e})();Kb.AwsCrc32c=Lxe});var YO=E(Fa=>{"use strict";Object.defineProperty(Fa,"__esModule",{value:!0});Fa.AwsCrc32c=Fa.Crc32c=Fa.crc32c=void 0;var Bxe=(qo(),Ve(Fo)),Fxe=nf();function qxe(e){return new X8().update(e).digest()}Fa.crc32c=qxe;var X8=(function(){function e(){this.checksum=4294967295}return e.prototype.update=function(t){var r,n;try{for(var i=Bxe.__values(t),o=i.next();!o.done;o=i.next()){var s=o.value;this.checksum=this.checksum>>>8^Uxe[(this.checksum^s)&255]}}catch(a){r={error:a}}finally{try{o&&!o.done&&(n=i.return)&&n.call(i)}finally{if(r)throw r.error}}return this},e.prototype.digest=function(){return(this.checksum^4294967295)>>>0},e})();Fa.Crc32c=X8;var jxe=[0,4067132163,3778769143,324072436,3348797215,904991772,648144872,3570033899,2329499855,2024987596,1809983544,2575936315,1296289744,3207089363,2893594407,1578318884,274646895,3795141740,4049975192,51262619,3619967088,632279923,922689671,3298075524,2592579488,1760304291,2075979607,2312596564,1562183871,2943781820,3156637768,1313733451,549293790,3537243613,3246849577,871202090,3878099393,357341890,102525238,4101499445,2858735121,1477399826,1264559846,3107202533,1845379342,2677391885,2361733625,2125378298,820201905,3263744690,3520608582,598981189,4151959214,85089709,373468761,3827903834,3124367742,1213305469,1526817161,2842354314,2107672161,2412447074,2627466902,1861252501,1098587580,3004210879,2688576843,1378610760,2262928035,1955203488,1742404180,2511436119,3416409459,969524848,714683780,3639785095,205050476,4266873199,3976438427,526918040,1361435347,2739821008,2954799652,1114974503,2529119692,1691668175,2005155131,2247081528,3690758684,697762079,986182379,3366744552,476452099,3993867776,4250756596,255256311,1640403810,2477592673,2164122517,1922457750,2791048317,1412925310,1197962378,3037525897,3944729517,427051182,170179418,4165941337,746937522,3740196785,3451792453,1070968646,1905808397,2213795598,2426610938,1657317369,3053634322,1147748369,1463399397,2773627110,4215344322,153784257,444234805,3893493558,1021025245,3467647198,3722505002,797665321,2197175160,1889384571,1674398607,2443626636,1164749927,3070701412,2757221520,1446797203,137323447,4198817972,3910406976,461344835,3484808360,1037989803,781091935,3705997148,2460548119,1623424788,1939049696,2180517859,1429367560,2807687179,3020495871,1180866812,410100952,3927582683,4182430767,186734380,3756733383,763408580,1053836080,3434856499,2722870694,1344288421,1131464017,2971354706,1708204729,2545590714,2229949006,1988219213,680717673,3673779818,3383336350,1002577565,4010310262,493091189,238226049,4233660802,2987750089,1082061258,1395524158,2705686845,1972364758,2279892693,2494862625,1725896226,952904198,3399985413,3656866545,731699698,4283874585,222117402,510512622,3959836397,3280807620,837199303,582374963,3504198960,68661723,4135334616,3844915500,390545967,1230274059,3141532936,2825850620,1510247935,2395924756,2091215383,1878366691,2644384480,3553878443,565732008,854102364,3229815391,340358836,3861050807,4117890627,119113024,1493875044,2875275879,3090270611,1247431312,2660249211,1828433272,2141937292,2378227087,3811616794,291187481,34330861,4032846830,615137029,3603020806,3314634738,939183345,1776939221,2609017814,2295496738,2058945313,2926798794,1545135305,1330124605,3173225534,4084100981,17165430,307568514,3762199681,888469610,3332340585,3587147933,665062302,2042050490,2346497209,2559330125,1793573966,3190661285,1279665062,1595330642,2910671697],Uxe=(0,Fxe.uint32ArrayFrom)(jxe),Hxe=Y8();Object.defineProperty(Fa,"AwsCrc32c",{enumerable:!0,get:function(){return Hxe.AwsCrc32c}})});var Z8=E(Yb=>{"use strict";Object.defineProperty(Yb,"__esModule",{value:!0});Yb.AwsCrc32=void 0;var J8=(qo(),Ve(Fo)),XO=nf(),Q8=Xb(),$xe=(function(){function e(){this.crc32=new Q8.Crc32}return e.prototype.update=function(t){(0,XO.isEmptyData)(t)||this.crc32.update((0,XO.convertToBuffer)(t))},e.prototype.digest=function(){return J8.__awaiter(this,void 0,void 0,function(){return J8.__generator(this,function(t){return[2,(0,XO.numToUint8)(this.crc32.digest())]})})},e.prototype.reset=function(){this.crc32=new Q8.Crc32},e})();Yb.AwsCrc32=$xe});var Xb=E(qa=>{"use strict";Object.defineProperty(qa,"__esModule",{value:!0});qa.AwsCrc32=qa.Crc32=qa.crc32=void 0;var Gxe=(qo(),Ve(Fo)),zxe=nf();function Vxe(e){return new eG().update(e).digest()}qa.crc32=Vxe;var eG=(function(){function e(){this.checksum=4294967295}return e.prototype.update=function(t){var r,n;try{for(var i=Gxe.__values(t),o=i.next();!o.done;o=i.next()){var s=o.value;this.checksum=this.checksum>>>8^Kxe[(this.checksum^s)&255]}}catch(a){r={error:a}}finally{try{o&&!o.done&&(n=i.return)&&n.call(i)}finally{if(r)throw r.error}}return this},e.prototype.digest=function(){return(this.checksum^4294967295)>>>0},e})();qa.Crc32=eG;var Wxe=[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],Kxe=(0,zxe.uint32ArrayFrom)(Wxe),Yxe=Z8();Object.defineProperty(qa,"AwsCrc32",{enumerable:!0,get:function(){return Yxe.AwsCrc32}})});var rG=E(Jb=>{"use strict";Object.defineProperty(Jb,"__esModule",{value:!0});Jb.getCrc32ChecksumAlgorithmFunction=void 0;var Xxe=(qo(),Ve(Fo)),Jxe=Xb(),Qxe=nf(),tG=Xxe.__importStar(require("zlib")),JO=class{checksum=0;update(t){this.checksum=tG.crc32(t,this.checksum)}async digest(){return(0,Qxe.numToUint8)(this.checksum)}reset(){this.checksum=0}},Zxe=()=>typeof tG.crc32>"u"?Jxe.AwsCrc32:JO;Jb.getCrc32ChecksumAlgorithmFunction=Zxe});var nI=E(Fe=>{"use strict";var Bs=(Dr(),Ve(Uo)),iG=St(),oG=Jc(),eTe=E_(),tTe=YO(),rTe=rG(),nTe=Cr(),nG=an(),Fs={WHEN_SUPPORTED:"WHEN_SUPPORTED",WHEN_REQUIRED:"WHEN_REQUIRED"},eI=Fs.WHEN_SUPPORTED,of={WHEN_SUPPORTED:"WHEN_SUPPORTED",WHEN_REQUIRED:"WHEN_REQUIRED"},tI=Fs.WHEN_SUPPORTED;Fe.ChecksumAlgorithm=void 0;(function(e){e.MD5="MD5",e.CRC32="CRC32",e.CRC32C="CRC32C",e.CRC64NVME="CRC64NVME",e.SHA1="SHA1",e.SHA256="SHA256"})(Fe.ChecksumAlgorithm||(Fe.ChecksumAlgorithm={}));Fe.ChecksumLocation=void 0;(function(e){e.HEADER="header",e.TRAILER="trailer"})(Fe.ChecksumLocation||(Fe.ChecksumLocation={}));var Qb=Fe.ChecksumAlgorithm.CRC32,sf;(function(e){e.ENV="env",e.CONFIG="shared config entry"})(sf||(sf={}));var Zb=(e,t,r,n)=>{if(!(t in e))return;let i=e[t].toUpperCase();if(!Object.values(r).includes(i))throw new TypeError(`Cannot load ${n} '${t}'. Expected one of ${Object.values(r)}, got '${e[t]}'.`);return i},sG="AWS_REQUEST_CHECKSUM_CALCULATION",aG="request_checksum_calculation",iTe={environmentVariableSelector:e=>Zb(e,sG,Fs,sf.ENV),configFileSelector:e=>Zb(e,aG,Fs,sf.CONFIG),default:eI},cG="AWS_RESPONSE_CHECKSUM_VALIDATION",uG="response_checksum_validation",oTe={environmentVariableSelector:e=>Zb(e,cG,of,sf.ENV),configFileSelector:e=>Zb(e,uG,of,sf.CONFIG),default:tI},QO={CrtCrc64Nvme:null},ZO=[Fe.ChecksumAlgorithm.CRC32,Fe.ChecksumAlgorithm.CRC32C,Fe.ChecksumAlgorithm.CRC64NVME,Fe.ChecksumAlgorithm.SHA1,Fe.ChecksumAlgorithm.SHA256],sTe=[Fe.ChecksumAlgorithm.SHA256,Fe.ChecksumAlgorithm.SHA1,Fe.ChecksumAlgorithm.CRC32,Fe.ChecksumAlgorithm.CRC32C,Fe.ChecksumAlgorithm.CRC64NVME],aTe=(e,{requestChecksumRequired:t,requestAlgorithmMember:r,requestChecksumCalculation:n})=>{if(!r)return n===Fs.WHEN_SUPPORTED||t?Qb:void 0;if(!e[r])return;let i=e[r];if(!ZO.includes(i))throw new Error(`The checksum algorithm "${i}" is not supported by the client. Select one of ${ZO}.`);return i},rI=e=>e===Fe.ChecksumAlgorithm.MD5?"content-md5":`x-amz-checksum-${e.toLowerCase()}`,cTe=(e,t)=>{let r=e.toLowerCase();for(let n of Object.keys(t))if(r===n.toLowerCase())return!0;return!1},uTe=(e,t)=>{let r=e.toLowerCase();for(let n of Object.keys(t))if(n.toLowerCase().startsWith(r))return!0;return!1},lG=e=>e!==void 0&&typeof e!="string"&&!ArrayBuffer.isView(e)&&!eTe.isArrayBuffer(e),fG=(e,t)=>{switch(e){case Fe.ChecksumAlgorithm.MD5:return t.md5;case Fe.ChecksumAlgorithm.CRC32:return rTe.getCrc32ChecksumAlgorithmFunction();case Fe.ChecksumAlgorithm.CRC32C:return tTe.AwsCrc32c;case Fe.ChecksumAlgorithm.CRC64NVME:if(typeof QO.CrtCrc64Nvme!="function")throw new Error(`Please check whether you have installed the "@aws-sdk/crc64-nvme-crt" package explicitly.
|
|
225
|
+
You must also register the package by calling [require("@aws-sdk/crc64-nvme-crt");] or an ESM equivalent such as [import "@aws-sdk/crc64-nvme-crt";].
|
|
226
|
+
For more information please go to https://github.com/aws/aws-sdk-js-v3#functionality-requiring-aws-common-runtime-crt`);return QO.CrtCrc64Nvme;case Fe.ChecksumAlgorithm.SHA1:return t.sha1;case Fe.ChecksumAlgorithm.SHA256:return t.sha256;default:throw new Error(`Unsupported checksum algorithm: ${e}`)}},dG=(e,t)=>{let r=new e;return r.update(nTe.toUint8Array(t||"")),r.digest()},pG={name:"flexibleChecksumsMiddleware",step:"build",tags:["BODY_CHECKSUM"],override:!0},hG=(e,t)=>(r,n)=>async i=>{if(!iG.HttpRequest.isInstance(i.request)||uTe("x-amz-checksum-",i.request.headers))return r(i);let{request:o,input:s}=i,{body:a,headers:c}=o,{base64Encoder:u,streamHasher:l}=e,{requestChecksumRequired:d,requestAlgorithmMember:h}=t,f=await e.requestChecksumCalculation(),p=h?.name,m=h?.httpHeader;p&&!s[p]&&(f===Fs.WHEN_SUPPORTED||d)&&(s[p]=Qb,m&&(c[m]=Qb));let _=aTe(s,{requestChecksumRequired:d,requestAlgorithmMember:h?.name,requestChecksumCalculation:f}),w=a,R=c;if(_){switch(_){case Fe.ChecksumAlgorithm.CRC32:Bs.setFeature(n,"FLEXIBLE_CHECKSUMS_REQ_CRC32","U");break;case Fe.ChecksumAlgorithm.CRC32C:Bs.setFeature(n,"FLEXIBLE_CHECKSUMS_REQ_CRC32C","V");break;case Fe.ChecksumAlgorithm.CRC64NVME:Bs.setFeature(n,"FLEXIBLE_CHECKSUMS_REQ_CRC64","W");break;case Fe.ChecksumAlgorithm.SHA1:Bs.setFeature(n,"FLEXIBLE_CHECKSUMS_REQ_SHA1","X");break;case Fe.ChecksumAlgorithm.SHA256:Bs.setFeature(n,"FLEXIBLE_CHECKSUMS_REQ_SHA256","Y");break}let y=rI(_),S=fG(_,e);if(lG(a)){let{getAwsChunkedEncodingStream:O,bodyLengthChecker:M}=e;w=O(typeof e.requestStreamBufferSize=="number"&&e.requestStreamBufferSize>=8*1024?oG.createBufferedReadable(a,e.requestStreamBufferSize,n.logger):a,{base64Encoder:u,bodyLengthChecker:M,checksumLocationName:y,checksumAlgorithmFn:S,streamHasher:l}),R={...c,"content-encoding":c["content-encoding"]?`${c["content-encoding"]},aws-chunked`:"aws-chunked","transfer-encoding":"chunked","x-amz-decoded-content-length":c["content-length"],"x-amz-content-sha256":"STREAMING-UNSIGNED-PAYLOAD-TRAILER","x-amz-trailer":y},delete R["content-length"]}else if(!cTe(y,c)){let O=await dG(S,a);R={...c,[y]:u(O)}}}return await r({...i,request:{...o,headers:R,body:w}})},lTe={name:"flexibleChecksumsInputMiddleware",toMiddleware:"serializerMiddleware",relation:"before",tags:["BODY_CHECKSUM"],override:!0},fTe=(e,t)=>(r,n)=>async i=>{let o=i.input,{requestValidationModeMember:s}=t,a=await e.requestChecksumCalculation(),c=await e.responseChecksumValidation();switch(a){case Fs.WHEN_REQUIRED:Bs.setFeature(n,"FLEXIBLE_CHECKSUMS_REQ_WHEN_REQUIRED","a");break;case Fs.WHEN_SUPPORTED:Bs.setFeature(n,"FLEXIBLE_CHECKSUMS_REQ_WHEN_SUPPORTED","Z");break}switch(c){case of.WHEN_REQUIRED:Bs.setFeature(n,"FLEXIBLE_CHECKSUMS_RES_WHEN_REQUIRED","c");break;case of.WHEN_SUPPORTED:Bs.setFeature(n,"FLEXIBLE_CHECKSUMS_RES_WHEN_SUPPORTED","b");break}return s&&!o[s]&&c===of.WHEN_SUPPORTED&&(o[s]="ENABLED"),r(i)},mG=(e=[])=>{let t=[];for(let r of sTe)!e.includes(r)||!ZO.includes(r)||t.push(r);return t},dTe=e=>{let t=e.lastIndexOf("-");if(t!==-1){let r=e.slice(t+1);if(!r.startsWith("0")){let n=parseInt(r,10);if(!isNaN(n)&&n>=1&&n<=1e4)return!0}}return!1},pTe=async(e,{checksumAlgorithmFn:t,base64Encoder:r})=>r(await dG(t,e)),hTe=async(e,{config:t,responseAlgorithms:r,logger:n})=>{let i=mG(r),{body:o,headers:s}=e;for(let a of i){let c=rI(a),u=s[c];if(u){let l;try{l=fG(a,t)}catch(f){if(a===Fe.ChecksumAlgorithm.CRC64NVME){n?.warn(`Skipping ${Fe.ChecksumAlgorithm.CRC64NVME} checksum validation: ${f.message}`);continue}throw f}let{base64Encoder:d}=t;if(lG(o)){e.body=oG.createChecksumStream({expectedChecksum:u,checksumSourceLocation:c,checksum:new l,source:o,base64Encoder:d});return}let h=await pTe(o,{checksumAlgorithmFn:l,base64Encoder:d});if(h===u)break;throw new Error(`Checksum mismatch: expected "${h}" but received "${u}" in response header "${c}".`)}}},mTe={name:"flexibleChecksumsResponseMiddleware",toMiddleware:"deserializerMiddleware",relation:"after",tags:["BODY_CHECKSUM"],override:!0},gTe=(e,t)=>(r,n)=>async i=>{if(!iG.HttpRequest.isInstance(i.request))return r(i);let o=i.input,s=await r(i),a=s.response,{requestValidationModeMember:c,responseAlgorithms:u}=t;if(c&&o[c]==="ENABLED"){let{clientName:l,commandName:d}=n;if(l==="S3Client"&&d==="GetObjectCommand"&&mG(u).every(f=>{let p=rI(f),m=a.headers[p];return!m||dTe(m)}))return s;await hTe(a,{config:e,responseAlgorithms:u,logger:n.logger})}return s},yTe=(e,t)=>({applyToStack:r=>{r.add(hG(e,t),pG),r.addRelativeTo(fTe(e,t),lTe),r.addRelativeTo(gTe(e,t),mTe)}}),_Te=e=>{let{requestChecksumCalculation:t,responseChecksumValidation:r,requestStreamBufferSize:n}=e;return Object.assign(e,{requestChecksumCalculation:nG.normalizeProvider(t??eI),responseChecksumValidation:nG.normalizeProvider(r??tI),requestStreamBufferSize:Number(n??0)})};Fe.CONFIG_REQUEST_CHECKSUM_CALCULATION=aG;Fe.CONFIG_RESPONSE_CHECKSUM_VALIDATION=uG;Fe.DEFAULT_CHECKSUM_ALGORITHM=Qb;Fe.DEFAULT_REQUEST_CHECKSUM_CALCULATION=eI;Fe.DEFAULT_RESPONSE_CHECKSUM_VALIDATION=tI;Fe.ENV_REQUEST_CHECKSUM_CALCULATION=sG;Fe.ENV_RESPONSE_CHECKSUM_VALIDATION=cG;Fe.NODE_REQUEST_CHECKSUM_CALCULATION_CONFIG_OPTIONS=iTe;Fe.NODE_RESPONSE_CHECKSUM_VALIDATION_CONFIG_OPTIONS=oTe;Fe.RequestChecksumCalculation=Fs;Fe.ResponseChecksumValidation=of;Fe.crc64NvmeCrtContainer=QO;Fe.flexibleChecksumsMiddleware=hG;Fe.flexibleChecksumsMiddlewareOptions=pG;Fe.getFlexibleChecksumsPlugin=yTe;Fe.resolveFlexibleChecksumsConfig=_Te});var af=E(lh=>{"use strict";var bTe=St();function ETe(e){return e}var gG=e=>t=>async r=>{if(!bTe.HttpRequest.isInstance(r.request))return t(r);let{request:n}=r,{handlerProtocol:i=""}=e.requestHandler.metadata||{};if(i.indexOf("h2")>=0&&!n.headers[":authority"])delete n.headers.host,n.headers[":authority"]=n.hostname+(n.port?":"+n.port:"");else if(!n.headers.host){let o=n.hostname;n.port!=null&&(o+=`:${n.port}`),n.headers.host=o}return t(r)},yG={name:"hostHeaderMiddleware",step:"build",priority:"low",tags:["HOST"],override:!0},wTe=e=>({applyToStack:t=>{t.add(gG(e),yG)}});lh.getHostHeaderPlugin=wTe;lh.hostHeaderMiddleware=gG;lh.hostHeaderMiddlewareOptions=yG;lh.resolveHostHeaderConfig=ETe});var cf=E(e0=>{"use strict";var _G=()=>(e,t)=>async r=>{try{let n=await e(r),{clientName:i,commandName:o,logger:s,dynamoDbDocumentClientOptions:a={}}=t,{overrideInputFilterSensitiveLog:c,overrideOutputFilterSensitiveLog:u}=a,l=c??t.inputFilterSensitiveLog,d=u??t.outputFilterSensitiveLog,{$metadata:h,...f}=n.output;return s?.info?.({clientName:i,commandName:o,input:l(r.input),output:d(f),metadata:h}),n}catch(n){let{clientName:i,commandName:o,logger:s,dynamoDbDocumentClientOptions:a={}}=t,{overrideInputFilterSensitiveLog:c}=a,u=c??t.inputFilterSensitiveLog;throw s?.error?.({clientName:i,commandName:o,input:u(r.input),error:n,metadata:n.$metadata}),n}},bG={name:"loggerMiddleware",tags:["LOGGER"],step:"initialize",override:!0},STe=e=>({applyToStack:t=>{t.add(_G(),bG)}});e0.getLoggerPlugin=STe;e0.loggerMiddleware=_G;e0.loggerMiddlewareOptions=bG});var EG={};Nn(EG,{InvokeStore:()=>aI,InvokeStoreBase:()=>dh});var fh,iI,dh,oI,sI,aI,wG=Y(()=>{"use strict";fh={REQUEST_ID:Symbol.for("_AWS_LAMBDA_REQUEST_ID"),X_RAY_TRACE_ID:Symbol.for("_AWS_LAMBDA_X_RAY_TRACE_ID"),TENANT_ID:Symbol.for("_AWS_LAMBDA_TENANT_ID")},iI=["true","1"].includes(process.env?.AWS_LAMBDA_NODEJS_NO_GLOBAL_AWSLAMBDA??"");iI||(globalThis.awslambda=globalThis.awslambda||{});dh=class{static PROTECTED_KEYS=fh;isProtectedKey(t){return Object.values(fh).includes(t)}getRequestId(){return this.get(fh.REQUEST_ID)??"-"}getXRayTraceId(){return this.get(fh.X_RAY_TRACE_ID)}getTenantId(){return this.get(fh.TENANT_ID)}},oI=class extends dh{currentContext;getContext(){return this.currentContext}hasContext(){return this.currentContext!==void 0}get(t){return this.currentContext?.[t]}set(t,r){if(this.isProtectedKey(t))throw new Error(`Cannot modify protected Lambda context field: ${String(t)}`);this.currentContext=this.currentContext||{},this.currentContext[t]=r}run(t,r){return this.currentContext=t,r()}},sI=class e extends dh{als;static async create(){let t=new e,r=await import("node:async_hooks");return t.als=new r.AsyncLocalStorage,t}getContext(){return this.als.getStore()}hasContext(){return this.als.getStore()!==void 0}get(t){return this.als.getStore()?.[t]}set(t,r){if(this.isProtectedKey(t))throw new Error(`Cannot modify protected Lambda context field: ${String(t)}`);let n=this.als.getStore();if(!n)throw new Error("No context available");n[t]=r}run(t,r){return this.als.run(t,r)}};(function(e){let t=null;async function r(){return t||(t=(async()=>{let i="AWS_LAMBDA_MAX_CONCURRENCY"in process.env?await sI.create():new oI;return!iI&&globalThis.awslambda?.InvokeStore?globalThis.awslambda.InvokeStore:(!iI&&globalThis.awslambda&&(globalThis.awslambda.InvokeStore=i),i)})()),t}e.getInstanceAsync=r,e._testing=process.env.AWS_LAMBDA_BENCHMARK_MODE==="1"?{reset:()=>{t=null,globalThis.awslambda?.InvokeStore&&delete globalThis.awslambda.InvokeStore,globalThis.awslambda={}}}:void 0})(aI||(aI={}))});var SG=E(t0=>{"use strict";Object.defineProperty(t0,"__esModule",{value:!0});t0.recursionDetectionMiddleware=void 0;var vTe=(wG(),Ve(EG)),CTe=St(),cI="X-Amzn-Trace-Id",xTe="AWS_LAMBDA_FUNCTION_NAME",TTe="_X_AMZN_TRACE_ID",ATe=()=>e=>async t=>{let{request:r}=t;if(!CTe.HttpRequest.isInstance(r))return e(t);let n=Object.keys(r.headers??{}).find(l=>l.toLowerCase()===cI.toLowerCase())??cI;if(r.headers.hasOwnProperty(n))return e(t);let i=process.env[xTe],o=process.env[TTe],c=(await vTe.InvokeStore.getInstanceAsync())?.getXRayTraceId()??o,u=l=>typeof l=="string"&&l.length>0;return u(i)&&u(c)&&(r.headers[cI]=c),e({...t,request:r})};t0.recursionDetectionMiddleware=ATe});var uf=E(r0=>{"use strict";var uI=SG(),RTe={step:"build",tags:["RECURSION_DETECTION"],name:"recursionDetectionMiddleware",override:!0,priority:"low"},PTe=e=>({applyToStack:t=>{t.add(uI.recursionDetectionMiddleware(),RTe)}});r0.getRecursionDetectionPlugin=PTe;Object.keys(uI).forEach(function(e){e!=="default"&&!Object.prototype.hasOwnProperty.call(r0,e)&&Object.defineProperty(r0,e,{enumerable:!0,get:function(){return uI[e]}})})});var n0=E(lf=>{"use strict";var OTe=(e,t,r)=>{if(t in e){if(e[t]==="true")return!0;if(e[t]==="false")return!1;throw new Error(`Cannot load ${r} "${t}". Expected "true" or "false", got ${e[t]}.`)}},ITe=(e,t,r)=>{if(!(t in e))return;let n=parseInt(e[t],10);if(Number.isNaN(n))throw new TypeError(`Cannot load ${r} '${t}'. Expected number, got '${e[t]}'.`);return n};lf.SelectorType=void 0;(function(e){e.ENV="env",e.CONFIG="shared config entry"})(lf.SelectorType||(lf.SelectorType={}));lf.booleanSelector=OTe;lf.numberSelector=ITe});var fI=E((Bbt,CG)=>{"use strict";var i0=Object.defineProperty,DTe=Object.getOwnPropertyDescriptor,kTe=Object.getOwnPropertyNames,NTe=Object.prototype.hasOwnProperty,lI=(e,t)=>i0(e,"name",{value:t,configurable:!0}),MTe=(e,t)=>{for(var r in t)i0(e,r,{get:t[r],enumerable:!0})},LTe=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of kTe(t))!NTe.call(e,i)&&i!==r&&i0(e,i,{get:()=>t[i],enumerable:!(n=DTe(t,i))||n.enumerable});return e},BTe=e=>LTe(i0({},"__esModule",{value:!0}),e),vG={};MTe(vG,{build:()=>jTe,parse:()=>qTe,validate:()=>FTe});CG.exports=BTe(vG);var FTe=lI(e=>typeof e=="string"&&e.indexOf("arn:")===0&&e.split(":").length>=6,"validate"),qTe=lI(e=>{let t=e.split(":");if(t.length<6||t[0]!=="arn")throw new Error("Malformed ARN");let[,r,n,i,o,...s]=t;return{partition:r,service:n,region:i,accountId:o,resource:s.join(":")}},"parse"),jTe=lI(e=>{let{partition:t="aws",service:r,region:n,accountId:i,resource:o}=e;if([r,n,i,o].some(s=>typeof s!="string"))throw new Error("Input ARN object is invalid");return`arn:${t}:${r}:${n}:${i}:${o}`},"build")});var c0=E(At=>{"use strict";var ph=St(),RG=Ge(),UTe=hb(),o0=n0(),HTe=(Dr(),Ve(Uo)),PG=(wn(),Ve(ou));Cs();var $Te=an(),xG=Jc(),GTe=fI(),zTe="content-length",VTe="x-amz-decoded-content-length";function OG(){return(e,t)=>async r=>{let{request:n}=r;if(ph.HttpRequest.isInstance(n)&&!(zTe in n.headers)&&!(VTe in n.headers)){let i="Are you using a Stream of unknown length as the Body of a PutObject request? Consider using Upload instead from @aws-sdk/lib-storage.";typeof t?.logger?.warn=="function"&&!(t.logger instanceof RG.NoOpLogger)?t.logger.warn(i):console.warn(i)}return e({...r})}}var IG={step:"finalizeRequest",tags:["CHECK_CONTENT_LENGTH_HEADER"],name:"getCheckContentLengthHeaderPlugin",override:!0},WTe=e=>({applyToStack:t=>{t.add(OG(),IG)}}),DG=e=>(t,r)=>async n=>{let i=await e.region(),o=e.region,s=()=>{};r.__s3RegionRedirect&&(Object.defineProperty(e,"region",{writable:!1,value:async()=>r.__s3RegionRedirect}),s=()=>Object.defineProperty(e,"region",{writable:!0,value:o}));try{let a=await t(n);if(r.__s3RegionRedirect){s();let c=await e.region();if(i!==c)throw new Error("Region was not restored following S3 region redirect.")}return a}catch(a){throw s(),a}},kG={tags:["REGION_REDIRECT","S3"],name:"regionRedirectEndpointMiddleware",override:!0,relation:"before",toMiddleware:"endpointV2Middleware"};function NG(e){return(t,r)=>async n=>{try{return await t(n)}catch(i){if(e.followRegionRedirects){let o=i?.$metadata?.httpStatusCode,s=r.commandName==="HeadBucketCommand",a=i?.$response?.headers?.["x-amz-bucket-region"];if(a&&(o===301||o===400&&(i?.name==="IllegalLocationConstraintException"||s))){try{let c=a;r.logger?.debug(`Redirecting from ${await e.region()} to ${c}`),r.__s3RegionRedirect=c}catch(c){throw new Error("Region redirect failed: "+c)}return t(n)}}throw i}}}var MG={step:"initialize",tags:["REGION_REDIRECT","S3"],name:"regionRedirectMiddleware",override:!0},KTe=e=>({applyToStack:t=>{t.add(NG(e),MG),t.addRelativeTo(DG(e),kG)}}),LG=e=>(t,r)=>async n=>{let i=await t(n),{response:o}=i;if(ph.HttpResponse.isInstance(o)&&o.headers.expires){o.headers.expiresstring=o.headers.expires;try{RG.parseRfc7231DateTime(o.headers.expires)}catch(s){r.logger?.warn(`AWS SDK Warning for ${r.clientName}::${r.commandName} response parsing (${o.headers.expires}): ${s}`),delete o.headers.expires}}return i},BG={tags:["S3"],name:"s3ExpiresMiddleware",override:!0,relation:"after",toMiddleware:"deserializerMiddleware"},YTe=e=>({applyToStack:t=>{t.addRelativeTo(LG(),BG)}}),s0=class e{data;lastPurgeTime=Date.now();static EXPIRED_CREDENTIAL_PURGE_INTERVAL_MS=3e4;constructor(t={}){this.data=t}get(t){let r=this.data[t];if(r)return r}set(t,r){return this.data[t]=r,r}delete(t){delete this.data[t]}async purgeExpired(){let t=Date.now();if(!(this.lastPurgeTime+e.EXPIRED_CREDENTIAL_PURGE_INTERVAL_MS>t))for(let r in this.data){let n=this.data[r];if(!n.isRefreshing){let i=await n.identity;i.expiration&&i.expiration.getTime()<t&&delete this.data[r]}}}},ff=class{_identity;isRefreshing;accessed;constructor(t,r=!1,n=Date.now()){this._identity=t,this.isRefreshing=r,this.accessed=n}get identity(){return this.accessed=Date.now(),this._identity}},a0=class e{createSessionFn;cache;static REFRESH_WINDOW_MS=6e4;constructor(t,r=new s0){this.createSessionFn=t,this.cache=r}async getS3ExpressIdentity(t,r){let n=r.Bucket,{cache:i}=this,o=i.get(n);return o?o.identity.then(s=>(s.expiration?.getTime()??0)<Date.now()?i.set(n,new ff(this.getIdentity(n))).identity:((s.expiration?.getTime()??0)<Date.now()+e.REFRESH_WINDOW_MS&&!o.isRefreshing&&(o.isRefreshing=!0,this.getIdentity(n).then(u=>{i.set(n,new ff(Promise.resolve(u)))})),s)):i.set(n,new ff(this.getIdentity(n))).identity}async getIdentity(t){await this.cache.purgeExpired().catch(i=>{console.warn(`Error while clearing expired entries in S3ExpressIdentityCache:
|
|
227
|
+
`+i)});let r=await this.createSessionFn(t);if(!r.Credentials?.AccessKeyId||!r.Credentials?.SecretAccessKey)throw new Error("s3#createSession response credential missing AccessKeyId or SecretAccessKey.");return{accessKeyId:r.Credentials.AccessKeyId,secretAccessKey:r.Credentials.SecretAccessKey,sessionToken:r.Credentials.SessionToken,expiration:r.Credentials.Expiration?new Date(r.Credentials.Expiration):void 0}}},XTe="Directory",JTe="S3Express",QTe="sigv4-s3express",dI="X-Amz-S3session-Token",pI=dI.toLowerCase(),ZTe="AWS_S3_DISABLE_EXPRESS_SESSION_AUTH",eAe="s3_disable_express_session_auth",tAe={environmentVariableSelector:e=>o0.booleanSelector(e,ZTe,o0.SelectorType.ENV),configFileSelector:e=>o0.booleanSelector(e,eAe,o0.SelectorType.CONFIG),default:!1},hI=class extends UTe.SignatureV4{async signWithCredentials(t,r,n){let i=TG(r);t.headers[pI]=r.sessionToken;let o=this;return AG(o,i),o.signRequest(t,n??{})}async presignWithCredentials(t,r,n){let i=TG(r);return delete t.headers[pI],t.headers[dI]=r.sessionToken,t.query=t.query??{},t.query[dI]=r.sessionToken,AG(this,i),this.presign(t,n)}};function TG(e){return{accessKeyId:e.accessKeyId,secretAccessKey:e.secretAccessKey,expiration:e.expiration}}function AG(e,t){let r=setTimeout(()=>{throw new Error("SignatureV4S3Express credential override was created but not called.")},10),n=e.credentialProvider,i=()=>(clearTimeout(r),e.credentialProvider=n,Promise.resolve(t));e.credentialProvider=i}var FG=e=>(t,r)=>async n=>{if(r.endpointV2){let i=r.endpointV2,o=i.properties?.authSchemes?.[0]?.name===QTe;if((i.properties?.backend===JTe||i.properties?.bucketType===XTe)&&(HTe.setFeature(r,"S3_EXPRESS_BUCKET","J"),r.isS3ExpressBucket=!0),o){let a=n.input.Bucket;if(a){let c=await e.s3ExpressIdentityProvider.getS3ExpressIdentity(await e.credentials(),{Bucket:a});r.s3ExpressIdentity=c,ph.HttpRequest.isInstance(n.request)&&c.sessionToken&&(n.request.headers[pI]=c.sessionToken)}}}return t(n)},qG={name:"s3ExpressMiddleware",step:"build",tags:["S3","S3_EXPRESS"],override:!0},rAe=e=>({applyToStack:t=>{t.add(FG(e),qG)}}),nAe=async(e,t,r,n)=>{let i=await n.signWithCredentials(r,e,{});if(i.headers["X-Amz-Security-Token"]||i.headers["x-amz-security-token"])throw new Error("X-Amz-Security-Token must not be set for s3-express requests.");return i},iAe=e=>t=>{throw t},oAe=(e,t)=>{},sAe=PG.httpSigningMiddlewareOptions,jG=e=>(t,r)=>async n=>{if(!ph.HttpRequest.isInstance(n.request))return t(n);let o=$Te.getSmithyContext(r).selectedHttpAuthScheme;if(!o)throw new Error("No HttpAuthScheme was selected: unable to sign request");let{httpAuthOption:{signingProperties:s={}},identity:a,signer:c}=o,u;r.s3ExpressIdentity?u=await nAe(r.s3ExpressIdentity,s,n.request,await e.signer()):u=await c.sign(n.request,a,s);let l=await t({...n,request:u}).catch((c.errorHandler||iAe)(s));return(c.successHandler||oAe)(l.response,s),l},aAe=e=>({applyToStack:t=>{t.addRelativeTo(jG(e),PG.httpSigningMiddlewareOptions)}}),cAe=(e,{session:t})=>{let[r,n]=t,{forcePathStyle:i,useAccelerateEndpoint:o,disableMultiregionAccessPoints:s,followRegionRedirects:a,s3ExpressIdentityProvider:c,bucketEndpoint:u,expectContinueHeader:l}=e;return Object.assign(e,{forcePathStyle:i??!1,useAccelerateEndpoint:o??!1,disableMultiregionAccessPoints:s??!1,followRegionRedirects:a??!1,s3ExpressIdentityProvider:c??new a0(async d=>r().send(new n({Bucket:d}))),bucketEndpoint:u??!1,expectContinueHeader:l??2097152})},uAe={CopyObjectCommand:!0,UploadPartCopyCommand:!0,CompleteMultipartUploadCommand:!0},lAe=3e3,UG=e=>(t,r)=>async n=>{let i=await t(n),{response:o}=i;if(!ph.HttpResponse.isInstance(o))return i;let{statusCode:s,body:a}=o;if(s<200||s>=300||!(typeof a?.stream=="function"||typeof a?.pipe=="function"||typeof a?.tee=="function"))return i;let u=a,l=a;a&&typeof a=="object"&&!(a instanceof Uint8Array)&&([u,l]=await xG.splitStream(a)),o.body=l;let d=await fAe(u,{streamCollector:async f=>xG.headStream(f,lAe)});typeof u?.destroy=="function"&&u.destroy();let h=e.utf8Encoder(d.subarray(d.length-16));if(d.length===0&&uAe[r.commandName]){let f=new Error("S3 aborted request");throw f.name="InternalError",f}return h&&h.endsWith("</Error>")&&(o.statusCode=400),i},fAe=(e=new Uint8Array,t)=>e instanceof Uint8Array?Promise.resolve(e):t.streamCollector(e)||Promise.resolve(new Uint8Array),HG={relation:"after",toMiddleware:"deserializerMiddleware",tags:["THROW_200_EXCEPTIONS","S3"],name:"throw200ExceptionsMiddleware",override:!0},dAe=e=>({applyToStack:t=>{t.addRelativeTo(UG(e),HG)}});function pAe(e){return(t,r)=>async n=>{if(e.bucketEndpoint){let i=r.endpointV2;if(i){let o=n.input.Bucket;if(typeof o=="string")try{let s=new URL(o);r.endpointV2={...i,url:s}}catch(s){let a=`@aws-sdk/middleware-sdk-s3: bucketEndpoint=true was set but Bucket=${o} could not be parsed as URL.`;throw r.logger?.constructor?.name==="NoOpLogger"?console.warn(a):r.logger?.warn?.(a),s}}}return t(n)}}var hAe={name:"bucketEndpointMiddleware",override:!0,relation:"after",toMiddleware:"endpointV2Middleware"};function $G({bucketEndpoint:e}){return t=>async r=>{let{input:{Bucket:n}}=r;if(!e&&typeof n=="string"&&!GTe.validate(n)&&n.indexOf("/")>=0){let i=new Error(`Bucket name shouldn't contain '/', received '${n}'`);throw i.name="InvalidBucketName",i}return t({...r})}}var GG={step:"initialize",tags:["VALIDATE_BUCKET_NAME"],name:"validateBucketNameMiddleware",override:!0},mAe=e=>({applyToStack:t=>{t.add($G(e),GG),t.addRelativeTo(pAe(e),hAe)}});At.NODE_DISABLE_S3_EXPRESS_SESSION_AUTH_OPTIONS=tAe;At.S3ExpressIdentityCache=s0;At.S3ExpressIdentityCacheEntry=ff;At.S3ExpressIdentityProviderImpl=a0;At.SignatureV4S3Express=hI;At.checkContentLengthHeader=OG;At.checkContentLengthHeaderMiddlewareOptions=IG;At.getCheckContentLengthHeaderPlugin=WTe;At.getRegionRedirectMiddlewarePlugin=KTe;At.getS3ExpiresMiddlewarePlugin=YTe;At.getS3ExpressHttpSigningPlugin=aAe;At.getS3ExpressPlugin=rAe;At.getThrow200ExceptionsPlugin=dAe;At.getValidateBucketNamePlugin=mAe;At.regionRedirectEndpointMiddleware=DG;At.regionRedirectEndpointMiddlewareOptions=kG;At.regionRedirectMiddleware=NG;At.regionRedirectMiddlewareOptions=MG;At.resolveS3Config=cAe;At.s3ExpiresMiddleware=LG;At.s3ExpiresMiddlewareOptions=BG;At.s3ExpressHttpSigningMiddleware=jG;At.s3ExpressHttpSigningMiddlewareOptions=sAe;At.s3ExpressMiddleware=FG;At.s3ExpressMiddlewareOptions=qG;At.throw200ExceptionsMiddleware=UG;At.throw200ExceptionsMiddlewareOptions=HG;At.validateBucketNameMiddleware=$G;At.validateBucketNameMiddlewareOptions=GG});var Ua=E(lu=>{"use strict";var gI=Cs(),yI=class{capacity;data=new Map;parameters=[];constructor({size:t,params:r}){this.capacity=t??50,r&&(this.parameters=r)}get(t,r){let n=this.hash(t);if(n===!1)return r();if(!this.data.has(n)){if(this.data.size>this.capacity+10){let i=this.data.keys(),o=0;for(;;){let{value:s,done:a}=i.next();if(this.data.delete(s),a||++o>10)break}}this.data.set(n,r())}return this.data.get(n)}size(){return this.data.size}hash(t){let r="",{parameters:n}=this;if(n.length===0)return!1;for(let i of n){let o=String(t[i]??"");if(o.includes("|;"))return!1;r+=o+"|;"}return r}},gAe=new RegExp("^(?:25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]\\d|\\d)(?:\\.(?:25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]\\d|\\d)){3}$"),zG=e=>gAe.test(e)||e.startsWith("[")&&e.endsWith("]"),yAe=new RegExp("^(?!.*-$)(?!-)[a-zA-Z0-9-]{1,63}$"),bI=(e,t=!1)=>{if(!t)return yAe.test(e);let r=e.split(".");for(let n of r)if(!bI(n))return!1;return!0},_I={},hh="endpoints";function ja(e){return typeof e!="object"||e==null?e:"ref"in e?`$${ja(e.ref)}`:"fn"in e?`${e.fn}(${(e.argv||[]).map(ja).join(", ")})`:JSON.stringify(e,null,2)}var Cn=class extends Error{constructor(t){super(t),this.name="EndpointError"}},_Ae=(e,t)=>e===t,bAe=e=>{let t=e.split("."),r=[];for(let n of t){let i=n.indexOf("[");if(i!==-1){if(n.indexOf("]")!==n.length-1)throw new Cn(`Path: '${e}' does not end with ']'`);let o=n.slice(i+1,-1);if(Number.isNaN(parseInt(o)))throw new Cn(`Invalid array index: '${o}' in path: '${e}'`);i!==0&&r.push(n.slice(0,i)),r.push(o)}else r.push(n)}return r},VG=(e,t)=>bAe(t).reduce((r,n)=>{if(typeof r!="object")throw new Cn(`Index '${n}' in '${t}' not found in '${JSON.stringify(e)}'`);return Array.isArray(r)?r[parseInt(n)]:r[n]},e),EAe=e=>e!=null,wAe=e=>!e,mI={[gI.EndpointURLScheme.HTTP]:80,[gI.EndpointURLScheme.HTTPS]:443},SAe=e=>{let t=(()=>{try{if(e instanceof URL)return e;if(typeof e=="object"&&"hostname"in e){let{hostname:h,port:f,protocol:p="",path:m="",query:_={}}=e,w=new URL(`${p}//${h}${f?`:${f}`:""}${m}`);return w.search=Object.entries(_).map(([R,v])=>`${R}=${v}`).join("&"),w}return new URL(e)}catch{return null}})();if(!t)return console.error(`Unable to parse ${JSON.stringify(e)} as a whatwg URL.`),null;let r=t.href,{host:n,hostname:i,pathname:o,protocol:s,search:a}=t;if(a)return null;let c=s.slice(0,-1);if(!Object.values(gI.EndpointURLScheme).includes(c))return null;let u=zG(i),l=r.includes(`${n}:${mI[c]}`)||typeof e=="string"&&e.includes(`${n}:${mI[c]}`),d=`${n}${l?`:${mI[c]}`:""}`;return{scheme:c,authority:d,path:o,normalizedPath:o.endsWith("/")?o:`${o}/`,isIp:u}},vAe=(e,t)=>e===t,CAe=(e,t,r,n)=>t>=r||e.length<r?null:n?e.substring(e.length-r,e.length-t):e.substring(t,r),xAe=e=>encodeURIComponent(e).replace(/[!*'()]/g,t=>`%${t.charCodeAt(0).toString(16).toUpperCase()}`),TAe={booleanEquals:_Ae,getAttr:VG,isSet:EAe,isValidHostLabel:bI,not:wAe,parseURL:SAe,stringEquals:vAe,substring:CAe,uriEncode:xAe},WG=(e,t)=>{let r=[],n={...t.endpointParams,...t.referenceRecord},i=0;for(;i<e.length;){let o=e.indexOf("{",i);if(o===-1){r.push(e.slice(i));break}r.push(e.slice(i,o));let s=e.indexOf("}",o);if(s===-1){r.push(e.slice(o));break}e[o+1]==="{"&&e[s+1]==="}"&&(r.push(e.slice(o+1,s)),i=s+2);let a=e.substring(o+1,s);if(a.includes("#")){let[c,u]=a.split("#");r.push(VG(n[c],u))}else r.push(n[a]);i=s+1}return r.join("")},AAe=({ref:e},t)=>({...t.endpointParams,...t.referenceRecord})[e],u0=(e,t,r)=>{if(typeof e=="string")return WG(e,r);if(e.fn)return YG.callFunction(e,r);if(e.ref)return AAe(e,r);throw new Cn(`'${t}': ${String(e)} is not a string, function or reference.`)},KG=({fn:e,argv:t},r)=>{let n=t.map(o=>["boolean","number"].includes(typeof o)?o:YG.evaluateExpression(o,"arg",r)),i=e.split(".");return i[0]in _I&&i[1]!=null?_I[i[0]][i[1]](...n):TAe[e](...n)},YG={evaluateExpression:u0,callFunction:KG},RAe=({assign:e,...t},r)=>{if(e&&e in r.referenceRecord)throw new Cn(`'${e}' is already defined in Reference Record.`);let n=KG(t,r);return r.logger?.debug?.(`${hh} evaluateCondition: ${ja(t)} = ${ja(n)}`),{result:n===""?!0:!!n,...e!=null&&{toAssign:{name:e,value:n}}}},EI=(e=[],t)=>{let r={};for(let n of e){let{result:i,toAssign:o}=RAe(n,{...t,referenceRecord:{...t.referenceRecord,...r}});if(!i)return{result:i};o&&(r[o.name]=o.value,t.logger?.debug?.(`${hh} assign: ${o.name} := ${ja(o.value)}`))}return{result:!0,referenceRecord:r}},PAe=(e,t)=>Object.entries(e).reduce((r,[n,i])=>({...r,[n]:i.map(o=>{let s=u0(o,"Header value entry",t);if(typeof s!="string")throw new Cn(`Header '${n}' value '${s}' is not a string`);return s})}),{}),XG=(e,t)=>Object.entries(e).reduce((r,[n,i])=>({...r,[n]:QG.getEndpointProperty(i,t)}),{}),JG=(e,t)=>{if(Array.isArray(e))return e.map(r=>JG(r,t));switch(typeof e){case"string":return WG(e,t);case"object":if(e===null)throw new Cn(`Unexpected endpoint property: ${e}`);return QG.getEndpointProperties(e,t);case"boolean":return e;default:throw new Cn(`Unexpected endpoint property type: ${typeof e}`)}},QG={getEndpointProperty:JG,getEndpointProperties:XG},OAe=(e,t)=>{let r=u0(e,"Endpoint URL",t);if(typeof r=="string")try{return new URL(r)}catch(n){throw console.error(`Failed to construct URL with ${r}`,n),n}throw new Cn(`Endpoint URL must be a string, got ${typeof r}`)},IAe=(e,t)=>{let{conditions:r,endpoint:n}=e,{result:i,referenceRecord:o}=EI(r,t);if(!i)return;let s={...t,referenceRecord:{...t.referenceRecord,...o}},{url:a,properties:c,headers:u}=n;return t.logger?.debug?.(`${hh} Resolving endpoint from template: ${ja(n)}`),{...u!=null&&{headers:PAe(u,s)},...c!=null&&{properties:XG(c,s)},url:OAe(a,s)}},DAe=(e,t)=>{let{conditions:r,error:n}=e,{result:i,referenceRecord:o}=EI(r,t);if(i)throw new Cn(u0(n,"Error",{...t,referenceRecord:{...t.referenceRecord,...o}}))},ZG=(e,t)=>{for(let r of e)if(r.type==="endpoint"){let n=IAe(r,t);if(n)return n}else if(r.type==="error")DAe(r,t);else if(r.type==="tree"){let n=ez.evaluateTreeRule(r,t);if(n)return n}else throw new Cn(`Unknown endpoint rule: ${r}`);throw new Cn("Rules evaluation failed")},kAe=(e,t)=>{let{conditions:r,rules:n}=e,{result:i,referenceRecord:o}=EI(r,t);if(i)return ez.evaluateRules(n,{...t,referenceRecord:{...t.referenceRecord,...o}})},ez={evaluateRules:ZG,evaluateTreeRule:kAe},NAe=(e,t)=>{let{endpointParams:r,logger:n}=t,{parameters:i,rules:o}=e;t.logger?.debug?.(`${hh} Initial EndpointParams: ${ja(r)}`);let s=Object.entries(i).filter(([,u])=>u.default!=null).map(([u,l])=>[u,l.default]);if(s.length>0)for(let[u,l]of s)r[u]=r[u]??l;let a=Object.entries(i).filter(([,u])=>u.required).map(([u])=>u);for(let u of a)if(r[u]==null)throw new Cn(`Missing required parameter: '${u}'`);let c=ZG(o,{endpointParams:r,logger:n,referenceRecord:{}});return t.logger?.debug?.(`${hh} Resolved endpoint: ${ja(c)}`),c};lu.EndpointCache=yI;lu.EndpointError=Cn;lu.customEndpointFunctions=_I;lu.isIpAddress=zG;lu.isValidHostLabel=bI;lu.resolveEndpoint=NAe});var rz=E(tz=>{"use strict";function MAe(e){let t={};if(e=e.replace(/^\?/,""),e)for(let r of e.split("&")){let[n,i=null]=r.split("=");n=decodeURIComponent(n),i&&(i=decodeURIComponent(i)),n in t?Array.isArray(t[n])?t[n].push(i):t[n]=[t[n],i]:t[n]=i}return t}tz.parseQueryString=MAe});var qs=E(iz=>{"use strict";var LAe=rz(),nz=e=>{if(typeof e=="string")return nz(new URL(e));let{hostname:t,pathname:r,port:n,protocol:i,search:o}=e,s;return o&&(s=LAe.parseQueryString(o)),{hostname:t,port:n?parseInt(n):void 0,protocol:i,path:r,query:s}};iz.parseUrl=nz});var fu=E(so=>{"use strict";var df=Ua(),BAe=qs(),sz=(e,t=!1)=>{if(t){for(let r of e.split("."))if(!sz(r))return!1;return!0}return!(!df.isValidHostLabel(e)||e.length<3||e.length>63||e!==e.toLowerCase()||df.isIpAddress(e))},oz=":",FAe="/",qAe=e=>{let t=e.split(oz);if(t.length<6)return null;let[r,n,i,o,s,...a]=t;if(r!=="arn"||n===""||i===""||a.join(oz)==="")return null;let c=a.map(u=>u.split(FAe)).flat();return{partition:n,service:i,region:o,accountId:s,resourceId:c}},jAe=[{id:"aws",outputs:{dnsSuffix:"amazonaws.com",dualStackDnsSuffix:"api.aws",implicitGlobalRegion:"us-east-1",name:"aws",supportsDualStack:!0,supportsFIPS:!0},regionRegex:"^(us|eu|ap|sa|ca|me|af|il|mx)\\-\\w+\\-\\d+$",regions:{"af-south-1":{description:"Africa (Cape Town)"},"ap-east-1":{description:"Asia Pacific (Hong Kong)"},"ap-east-2":{description:"Asia Pacific (Taipei)"},"ap-northeast-1":{description:"Asia Pacific (Tokyo)"},"ap-northeast-2":{description:"Asia Pacific (Seoul)"},"ap-northeast-3":{description:"Asia Pacific (Osaka)"},"ap-south-1":{description:"Asia Pacific (Mumbai)"},"ap-south-2":{description:"Asia Pacific (Hyderabad)"},"ap-southeast-1":{description:"Asia Pacific (Singapore)"},"ap-southeast-2":{description:"Asia Pacific (Sydney)"},"ap-southeast-3":{description:"Asia Pacific (Jakarta)"},"ap-southeast-4":{description:"Asia Pacific (Melbourne)"},"ap-southeast-5":{description:"Asia Pacific (Malaysia)"},"ap-southeast-6":{description:"Asia Pacific (New Zealand)"},"ap-southeast-7":{description:"Asia Pacific (Thailand)"},"aws-global":{description:"aws global region"},"ca-central-1":{description:"Canada (Central)"},"ca-west-1":{description:"Canada West (Calgary)"},"eu-central-1":{description:"Europe (Frankfurt)"},"eu-central-2":{description:"Europe (Zurich)"},"eu-north-1":{description:"Europe (Stockholm)"},"eu-south-1":{description:"Europe (Milan)"},"eu-south-2":{description:"Europe (Spain)"},"eu-west-1":{description:"Europe (Ireland)"},"eu-west-2":{description:"Europe (London)"},"eu-west-3":{description:"Europe (Paris)"},"il-central-1":{description:"Israel (Tel Aviv)"},"me-central-1":{description:"Middle East (UAE)"},"me-south-1":{description:"Middle East (Bahrain)"},"mx-central-1":{description:"Mexico (Central)"},"sa-east-1":{description:"South America (Sao Paulo)"},"us-east-1":{description:"US East (N. Virginia)"},"us-east-2":{description:"US East (Ohio)"},"us-west-1":{description:"US West (N. California)"},"us-west-2":{description:"US West (Oregon)"}}},{id:"aws-cn",outputs:{dnsSuffix:"amazonaws.com.cn",dualStackDnsSuffix:"api.amazonwebservices.com.cn",implicitGlobalRegion:"cn-northwest-1",name:"aws-cn",supportsDualStack:!0,supportsFIPS:!0},regionRegex:"^cn\\-\\w+\\-\\d+$",regions:{"aws-cn-global":{description:"aws-cn global region"},"cn-north-1":{description:"China (Beijing)"},"cn-northwest-1":{description:"China (Ningxia)"}}},{id:"aws-eusc",outputs:{dnsSuffix:"amazonaws.eu",dualStackDnsSuffix:"api.amazonwebservices.eu",implicitGlobalRegion:"eusc-de-east-1",name:"aws-eusc",supportsDualStack:!0,supportsFIPS:!0},regionRegex:"^eusc\\-(de)\\-\\w+\\-\\d+$",regions:{"eusc-de-east-1":{description:"EU (Germany)"}}},{id:"aws-iso",outputs:{dnsSuffix:"c2s.ic.gov",dualStackDnsSuffix:"api.aws.ic.gov",implicitGlobalRegion:"us-iso-east-1",name:"aws-iso",supportsDualStack:!0,supportsFIPS:!0},regionRegex:"^us\\-iso\\-\\w+\\-\\d+$",regions:{"aws-iso-global":{description:"aws-iso global region"},"us-iso-east-1":{description:"US ISO East"},"us-iso-west-1":{description:"US ISO WEST"}}},{id:"aws-iso-b",outputs:{dnsSuffix:"sc2s.sgov.gov",dualStackDnsSuffix:"api.aws.scloud",implicitGlobalRegion:"us-isob-east-1",name:"aws-iso-b",supportsDualStack:!0,supportsFIPS:!0},regionRegex:"^us\\-isob\\-\\w+\\-\\d+$",regions:{"aws-iso-b-global":{description:"aws-iso-b global region"},"us-isob-east-1":{description:"US ISOB East (Ohio)"},"us-isob-west-1":{description:"US ISOB West"}}},{id:"aws-iso-e",outputs:{dnsSuffix:"cloud.adc-e.uk",dualStackDnsSuffix:"api.cloud-aws.adc-e.uk",implicitGlobalRegion:"eu-isoe-west-1",name:"aws-iso-e",supportsDualStack:!0,supportsFIPS:!0},regionRegex:"^eu\\-isoe\\-\\w+\\-\\d+$",regions:{"aws-iso-e-global":{description:"aws-iso-e global region"},"eu-isoe-west-1":{description:"EU ISOE West"}}},{id:"aws-iso-f",outputs:{dnsSuffix:"csp.hci.ic.gov",dualStackDnsSuffix:"api.aws.hci.ic.gov",implicitGlobalRegion:"us-isof-south-1",name:"aws-iso-f",supportsDualStack:!0,supportsFIPS:!0},regionRegex:"^us\\-isof\\-\\w+\\-\\d+$",regions:{"aws-iso-f-global":{description:"aws-iso-f global region"},"us-isof-east-1":{description:"US ISOF EAST"},"us-isof-south-1":{description:"US ISOF SOUTH"}}},{id:"aws-us-gov",outputs:{dnsSuffix:"amazonaws.com",dualStackDnsSuffix:"api.aws",implicitGlobalRegion:"us-gov-west-1",name:"aws-us-gov",supportsDualStack:!0,supportsFIPS:!0},regionRegex:"^us\\-gov\\-\\w+\\-\\d+$",regions:{"aws-us-gov-global":{description:"aws-us-gov global region"},"us-gov-east-1":{description:"AWS GovCloud (US-East)"},"us-gov-west-1":{description:"AWS GovCloud (US-West)"}}}],UAe="1.1",az={partitions:jAe,version:UAe},cz=az,uz="",lz=e=>{let{partitions:t}=cz;for(let n of t){let{regions:i,outputs:o}=n;for(let[s,a]of Object.entries(i))if(s===e)return{...o,...a}}for(let n of t){let{regionRegex:i,outputs:o}=n;if(new RegExp(i).test(e))return{...o}}let r=t.find(n=>n.id==="aws");if(!r)throw new Error("Provided region was not found in the partition array or regex, and default partition with id 'aws' doesn't exist.");return{...r.outputs}},fz=(e,t="")=>{cz=e,uz=t},HAe=()=>{fz(az,"")},$Ae=()=>uz,dz={isVirtualHostableS3Bucket:sz,parseArn:qAe,partition:lz};df.customEndpointFunctions.aws=dz;var GAe=e=>{if(typeof e.endpointProvider!="function")throw new Error("@aws-sdk/util-endpoint - endpointProvider and endpoint missing in config for this client.");let{endpoint:t}=e;return t===void 0&&(e.endpoint=async()=>pz(e.endpointProvider({Region:typeof e.region=="function"?await e.region():e.region,UseDualStack:typeof e.useDualstackEndpoint=="function"?await e.useDualstackEndpoint():e.useDualstackEndpoint,UseFIPS:typeof e.useFipsEndpoint=="function"?await e.useFipsEndpoint():e.useFipsEndpoint,Endpoint:void 0},{logger:e.logger}))),e},pz=e=>BAe.parseUrl(e.url);Object.defineProperty(so,"EndpointError",{enumerable:!0,get:function(){return df.EndpointError}});Object.defineProperty(so,"isIpAddress",{enumerable:!0,get:function(){return df.isIpAddress}});Object.defineProperty(so,"resolveEndpoint",{enumerable:!0,get:function(){return df.resolveEndpoint}});so.awsEndpointFunctions=dz;so.getUserAgentPrefix=$Ae;so.partition=lz;so.resolveDefaultAwsRegionalEndpointsConfig=GAe;so.setPartitionInfo=fz;so.toEndpointV1=pz;so.useDefaultPartitionInfo=HAe});var du=E(pf=>{"use strict";var zAe=(wn(),Ve(ou)),VAe=fu(),WAe=St(),$o=(Dr(),Ve(Uo)),yz=void 0;function KAe(e){return e===void 0?!0:typeof e=="string"&&e.length<=50}function YAe(e){let t=zAe.normalizeProvider(e.userAgentAppId??yz),{customUserAgent:r}=e;return Object.assign(e,{customUserAgent:typeof r=="string"?[[r]]:r,userAgentAppId:async()=>{let n=await t();if(!KAe(n)){let i=e.logger?.constructor?.name==="NoOpLogger"||!e.logger?console:e.logger;typeof n!="string"?i?.warn("userAgentAppId must be a string or undefined."):n.length>50&&i?.warn("The provided userAgentAppId exceeds the maximum length of 50 characters.")}return n}})}var XAe=/\d{12}\.ddb/;async function JAe(e,t,r){if(r.request?.headers?.["smithy-protocol"]==="rpc-v2-cbor"&&$o.setFeature(e,"PROTOCOL_RPC_V2_CBOR","M"),typeof t.retryStrategy=="function"){let o=await t.retryStrategy();typeof o.acquireInitialRetryToken=="function"?o.constructor?.name?.includes("Adaptive")?$o.setFeature(e,"RETRY_MODE_ADAPTIVE","F"):$o.setFeature(e,"RETRY_MODE_STANDARD","E"):$o.setFeature(e,"RETRY_MODE_LEGACY","D")}if(typeof t.accountIdEndpointMode=="function"){let o=e.endpointV2;switch(String(o?.url?.hostname).match(XAe)&&$o.setFeature(e,"ACCOUNT_ID_ENDPOINT","O"),await t.accountIdEndpointMode?.()){case"disabled":$o.setFeature(e,"ACCOUNT_ID_MODE_DISABLED","Q");break;case"preferred":$o.setFeature(e,"ACCOUNT_ID_MODE_PREFERRED","P");break;case"required":$o.setFeature(e,"ACCOUNT_ID_MODE_REQUIRED","R");break}}let i=e.__smithy_context?.selectedHttpAuthScheme?.identity;if(i?.$source){let o=i;o.accountId&&$o.setFeature(e,"RESOLVED_ACCOUNT_ID","T");for(let[s,a]of Object.entries(o.$source??{}))$o.setFeature(e,s,a)}}var hz="user-agent",wI="x-amz-user-agent",mz=" ",SI="/",QAe=/[^!$%&'*+\-.^_`|~\w]/g,ZAe=/[^!$%&'*+\-.^_`|~\w#]/g,gz="-",eRe=1024;function tRe(e){let t="";for(let r in e){let n=e[r];if(t.length+n.length+1<=eRe){t.length?t+=","+n:t+=n;continue}break}return t}var _z=e=>(t,r)=>async n=>{let{request:i}=n;if(!WAe.HttpRequest.isInstance(i))return t(n);let{headers:o}=i,s=r?.userAgent?.map(l0)||[],a=(await e.defaultUserAgentProvider()).map(l0);await JAe(r,e,n);let c=r;a.push(`m/${tRe(Object.assign({},r.__smithy_context?.features,c.__aws_sdk_context?.features))}`);let u=e?.customUserAgent?.map(l0)||[],l=await e.userAgentAppId();l&&a.push(l0(["app",`${l}`]));let d=VAe.getUserAgentPrefix(),h=(d?[d]:[]).concat([...a,...s,...u]).join(mz),f=[...a.filter(p=>p.startsWith("aws-sdk-")),...u].join(mz);return e.runtime!=="browser"?(f&&(o[wI]=o[wI]?`${o[hz]} ${f}`:f),o[hz]=h):o[wI]=h,t({...n,request:i})},l0=e=>{let t=e[0].split(SI).map(s=>s.replace(QAe,gz)).join(SI),r=e[1]?.replace(ZAe,gz),n=t.indexOf(SI),i=t.substring(0,n),o=t.substring(n+1);return i==="api"&&(o=o.toLowerCase()),[i,o,r].filter(s=>s&&s.length>0).reduce((s,a,c)=>{switch(c){case 0:return a;case 1:return`${s}/${a}`;default:return`${s}#${a}`}},"")},bz={name:"getUserAgentMiddleware",step:"build",priority:"low",tags:["SET_USER_AGENT","USER_AGENT"],override:!0},rRe=e=>({applyToStack:t=>{t.add(_z(e),bz)}});pf.DEFAULT_UA_APP_ID=yz;pf.getUserAgentMiddlewareOptions=bz;pf.getUserAgentPlugin=rRe;pf.resolveUserAgentConfig=YAe;pf.userAgentMiddleware=_z});var si=E(cn=>{"use strict";var Ha=n0(),f0=an(),nRe=Ua(),Sz="AWS_USE_DUALSTACK_ENDPOINT",vz="use_dualstack_endpoint",iRe=!1,oRe={environmentVariableSelector:e=>Ha.booleanSelector(e,Sz,Ha.SelectorType.ENV),configFileSelector:e=>Ha.booleanSelector(e,vz,Ha.SelectorType.CONFIG),default:!1},Cz="AWS_USE_FIPS_ENDPOINT",xz="use_fips_endpoint",sRe=!1,aRe={environmentVariableSelector:e=>Ha.booleanSelector(e,Cz,Ha.SelectorType.ENV),configFileSelector:e=>Ha.booleanSelector(e,xz,Ha.SelectorType.CONFIG),default:!1},cRe=e=>{let{tls:t,endpoint:r,urlParser:n,useDualstackEndpoint:i}=e;return Object.assign(e,{tls:t??!0,endpoint:f0.normalizeProvider(typeof r=="string"?n(r):r),isCustomEndpoint:!0,useDualstackEndpoint:f0.normalizeProvider(i??!1)})},uRe=async e=>{let{tls:t=!0}=e,r=await e.region();if(!new RegExp(/^([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]{0,61}[a-zA-Z0-9])$/).test(r))throw new Error("Invalid region in client config");let i=await e.useDualstackEndpoint(),o=await e.useFipsEndpoint(),{hostname:s}=await e.regionInfoProvider(r,{useDualstackEndpoint:i,useFipsEndpoint:o})??{};if(!s)throw new Error("Cannot resolve hostname from client config");return e.urlParser(`${t?"https:":"http:"}//${s}`)},lRe=e=>{let t=f0.normalizeProvider(e.useDualstackEndpoint??!1),{endpoint:r,useFipsEndpoint:n,urlParser:i,tls:o}=e;return Object.assign(e,{tls:o??!0,endpoint:r?f0.normalizeProvider(typeof r=="string"?i(r):r):()=>uRe({...e,useDualstackEndpoint:t,useFipsEndpoint:n}),isCustomEndpoint:!!r,useDualstackEndpoint:t})},Tz="AWS_REGION",Az="region",fRe={environmentVariableSelector:e=>e[Tz],configFileSelector:e=>e[Az],default:()=>{throw new Error("Region is missing")}},dRe={preferredFile:"credentials"},Ez=new Set,pRe=(e,t=nRe.isValidHostLabel)=>{if(!Ez.has(e)&&!t(e))if(e==="*")console.warn('@smithy/config-resolver WARN - Please use the caller region instead of "*". See "sigv4a" in https://github.com/aws/aws-sdk-js-v3/blob/main/supplemental-docs/CLIENTS.md.');else throw new Error(`Region not accepted: region="${e}" is not a valid hostname component.`);else Ez.add(e)},Rz=e=>typeof e=="string"&&(e.startsWith("fips-")||e.endsWith("-fips")),hRe=e=>Rz(e)?["fips-aws-global","aws-fips"].includes(e)?"us-east-1":e.replace(/fips-(dkr-|prod-)?|-fips/,""):e,mRe=e=>{let{region:t,useFipsEndpoint:r}=e;if(!t)throw new Error("Region is missing");return Object.assign(e,{region:async()=>{let n=typeof t=="function"?await t():t,i=hRe(n);return pRe(i),i},useFipsEndpoint:async()=>{let n=typeof t=="string"?t:await t();return Rz(n)?!0:typeof r!="function"?Promise.resolve(!!r):r()}})},wz=(e=[],{useFipsEndpoint:t,useDualstackEndpoint:r})=>e.find(({tags:n})=>t===n.includes("fips")&&r===n.includes("dualstack"))?.hostname,gRe=(e,{regionHostname:t,partitionHostname:r})=>t||(r?r.replace("{region}",e):void 0),yRe=(e,{partitionHash:t})=>Object.keys(t||{}).find(r=>t[r].regions.includes(e))??"aws",_Re=(e,{signingRegion:t,regionRegex:r,useFipsEndpoint:n})=>{if(t)return t;if(n){let i=r.replace("\\\\","\\").replace(/^\^/g,"\\.").replace(/\$$/g,"\\."),o=e.match(i);if(o)return o[0].slice(1,-1)}},bRe=(e,{useFipsEndpoint:t=!1,useDualstackEndpoint:r=!1,signingService:n,regionHash:i,partitionHash:o})=>{let s=yRe(e,{partitionHash:o}),a=e in i?e:o[s]?.endpoint??e,c={useFipsEndpoint:t,useDualstackEndpoint:r},u=wz(i[a]?.variants,c),l=wz(o[s]?.variants,c),d=gRe(a,{regionHostname:u,partitionHostname:l});if(d===void 0)throw new Error(`Endpoint resolution failed for: ${{resolvedRegion:a,useFipsEndpoint:t,useDualstackEndpoint:r}}`);let h=_Re(d,{signingRegion:i[a]?.signingRegion,regionRegex:o[s].regionRegex,useFipsEndpoint:t});return{partition:s,signingService:n,hostname:d,...h&&{signingRegion:h},...i[a]?.signingService&&{signingService:i[a].signingService}}};cn.CONFIG_USE_DUALSTACK_ENDPOINT=vz;cn.CONFIG_USE_FIPS_ENDPOINT=xz;cn.DEFAULT_USE_DUALSTACK_ENDPOINT=iRe;cn.DEFAULT_USE_FIPS_ENDPOINT=sRe;cn.ENV_USE_DUALSTACK_ENDPOINT=Sz;cn.ENV_USE_FIPS_ENDPOINT=Cz;cn.NODE_REGION_CONFIG_FILE_OPTIONS=dRe;cn.NODE_REGION_CONFIG_OPTIONS=fRe;cn.NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS=oRe;cn.NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS=aRe;cn.REGION_ENV_NAME=Tz;cn.REGION_INI_NAME=Az;cn.getRegionInfo=bRe;cn.resolveCustomEndpointsConfig=cRe;cn.resolveEndpointsConfig=lRe;cn.resolveRegionConfig=mRe});var Oz=E(Pz=>{"use strict";var ERe=e=>Object.assign(e,{eventStreamMarshaller:e.eventStreamSerdeProvider(e)});Pz.resolveEventStreamSerdeConfig=ERe});var hf=E(d0=>{"use strict";var wRe=St(),Iz="content-length";function Dz(e){return t=>async r=>{let n=r.request;if(wRe.HttpRequest.isInstance(n)){let{body:i,headers:o}=n;if(i&&Object.keys(o).map(s=>s.toLowerCase()).indexOf(Iz)===-1)try{let s=e(i);n.headers={...n.headers,[Iz]:String(s)}}catch{}}return t({...r,request:n})}}var kz={step:"build",tags:["SET_CONTENT_LENGTH","CONTENT_LENGTH"],name:"contentLengthMiddleware",override:!0},SRe=e=>({applyToStack:t=>{t.add(Dz(e.bodyLengthChecker),kz)}});d0.contentLengthMiddleware=Dz;d0.contentLengthMiddlewareOptions=kz;d0.getContentLengthPlugin=SRe});var CI=E(p0=>{"use strict";Object.defineProperty(p0,"__esModule",{value:!0});p0.getHomeDir=void 0;var vRe=require("os"),CRe=require("path"),vI={},xRe=()=>process&&process.geteuid?`${process.geteuid()}`:"DEFAULT",TRe=()=>{let{HOME:e,USERPROFILE:t,HOMEPATH:r,HOMEDRIVE:n=`C:${CRe.sep}`}=process.env;if(e)return e;if(t)return t;if(r)return`${n}${r}`;let i=xRe();return vI[i]||(vI[i]=(0,vRe.homedir)()),vI[i]};p0.getHomeDir=TRe});var xI=E(h0=>{"use strict";Object.defineProperty(h0,"__esModule",{value:!0});h0.getSSOTokenFilepath=void 0;var ARe=require("crypto"),RRe=require("path"),PRe=CI(),ORe=e=>{let r=(0,ARe.createHash)("sha1").update(e).digest("hex");return(0,RRe.join)((0,PRe.getHomeDir)(),".aws","sso","cache",`${r}.json`)};h0.getSSOTokenFilepath=ORe});var Nz=E($a=>{"use strict";Object.defineProperty($a,"__esModule",{value:!0});$a.getSSOTokenFromFile=$a.tokenIntercept=void 0;var IRe=require("fs/promises"),DRe=xI();$a.tokenIntercept={};var kRe=async e=>{if($a.tokenIntercept[e])return $a.tokenIntercept[e];let t=(0,DRe.getSSOTokenFilepath)(e),r=await(0,IRe.readFile)(t,"utf8");return JSON.parse(r)};$a.getSSOTokenFromFile=kRe});var Mz=E(yi=>{"use strict";Object.defineProperty(yi,"__esModule",{value:!0});yi.readFile=yi.fileIntercept=yi.filePromises=void 0;var NRe=require("node:fs/promises");yi.filePromises={};yi.fileIntercept={};var MRe=(e,t)=>yi.fileIntercept[e]!==void 0?yi.fileIntercept[e]:((!yi.filePromises[e]||t?.ignoreCache)&&(yi.filePromises[e]=(0,NRe.readFile)(e,"utf8")),yi.filePromises[e]);yi.readFile=MRe});var Go=E($n=>{"use strict";var mh=CI(),Lz=xI(),TI=Nz(),m0=require("path"),g0=Cs(),mf=Mz(),Fz="AWS_PROFILE",qz="default",LRe=e=>e.profile||process.env[Fz]||qz,pu=".",BRe=e=>Object.entries(e).filter(([t])=>{let r=t.indexOf(pu);return r===-1?!1:Object.values(g0.IniSectionType).includes(t.substring(0,r))}).reduce((t,[r,n])=>{let i=r.indexOf(pu),o=r.substring(0,i)===g0.IniSectionType.PROFILE?r.substring(i+1):r;return t[o]=n,t},{...e.default&&{default:e.default}}),FRe="AWS_CONFIG_FILE",jz=()=>process.env[FRe]||m0.join(mh.getHomeDir(),".aws","config"),qRe="AWS_SHARED_CREDENTIALS_FILE",jRe=()=>process.env[qRe]||m0.join(mh.getHomeDir(),".aws","credentials"),URe=/^([\w-]+)\s(["'])?([\w-@\+\.%:/]+)\2$/,HRe=["__proto__","profile __proto__"],AI=e=>{let t={},r,n;for(let i of e.split(/\r?\n/)){let o=i.split(/(^|\s)[;#]/)[0].trim();if(o[0]==="["&&o[o.length-1]==="]"){r=void 0,n=void 0;let a=o.substring(1,o.length-1),c=URe.exec(a);if(c){let[,u,,l]=c;Object.values(g0.IniSectionType).includes(u)&&(r=[u,l].join(pu))}else r=a;if(HRe.includes(a))throw new Error(`Found invalid profile name "${a}"`)}else if(r){let a=o.indexOf("=");if(![0,-1].includes(a)){let[c,u]=[o.substring(0,a).trim(),o.substring(a+1).trim()];if(u==="")n=c;else{n&&i.trimStart()===i&&(n=void 0),t[r]=t[r]||{};let l=n?[n,c].join(pu):c;t[r][l]=u}}}}return t},Bz=()=>({}),Uz=async(e={})=>{let{filepath:t=jRe(),configFilepath:r=jz()}=e,n=mh.getHomeDir(),i="~/",o=t;t.startsWith(i)&&(o=m0.join(n,t.slice(2)));let s=r;r.startsWith(i)&&(s=m0.join(n,r.slice(2)));let a=await Promise.all([mf.readFile(s,{ignoreCache:e.ignoreCache}).then(AI).then(BRe).catch(Bz),mf.readFile(o,{ignoreCache:e.ignoreCache}).then(AI).catch(Bz)]);return{configFile:a[0],credentialsFile:a[1]}},$Re=e=>Object.entries(e).filter(([t])=>t.startsWith(g0.IniSectionType.SSO_SESSION+pu)).reduce((t,[r,n])=>({...t,[r.substring(r.indexOf(pu)+1)]:n}),{}),GRe=()=>({}),zRe=async(e={})=>mf.readFile(e.configFilepath??jz()).then(AI).then($Re).catch(GRe),VRe=(...e)=>{let t={};for(let r of e)for(let[n,i]of Object.entries(r))t[n]!==void 0?Object.assign(t[n],i):t[n]=i;return t},WRe=async e=>{let t=await Uz(e);return VRe(t.configFile,t.credentialsFile)},KRe={getFileRecord(){return mf.fileIntercept},interceptFile(e,t){mf.fileIntercept[e]=Promise.resolve(t)},getTokenRecord(){return TI.tokenIntercept},interceptToken(e,t){TI.tokenIntercept[e]=t}};Object.defineProperty($n,"getSSOTokenFromFile",{enumerable:!0,get:function(){return TI.getSSOTokenFromFile}});Object.defineProperty($n,"readFile",{enumerable:!0,get:function(){return mf.readFile}});$n.CONFIG_PREFIX_SEPARATOR=pu;$n.DEFAULT_PROFILE=qz;$n.ENV_PROFILE=Fz;$n.externalDataInterceptor=KRe;$n.getProfileName=LRe;$n.loadSharedConfigFiles=Uz;$n.loadSsoSessionData=zRe;$n.parseKnownFiles=WRe;Object.keys(mh).forEach(function(e){e!=="default"&&!Object.prototype.hasOwnProperty.call($n,e)&&Object.defineProperty($n,e,{enumerable:!0,get:function(){return mh[e]}})});Object.keys(Lz).forEach(function(e){e!=="default"&&!Object.prototype.hasOwnProperty.call($n,e)&&Object.defineProperty($n,e,{enumerable:!0,get:function(){return Lz[e]}})})});var zo=E(Gz=>{"use strict";var gh=Sn(),Hz=Go();function $z(e){try{let t=new Set(Array.from(e.match(/([A-Z_]){3,}/g)??[]));return t.delete("CONFIG"),t.delete("CONFIG_PREFIX_SEPARATOR"),t.delete("ENV"),[...t].join(", ")}catch{return e}}var YRe=(e,t)=>async()=>{try{let r=e(process.env,t);if(r===void 0)throw new Error;return r}catch(r){throw new gh.CredentialsProviderError(r.message||`Not found in ENV: ${$z(e.toString())}`,{logger:t?.logger})}},XRe=(e,{preferredFile:t="config",...r}={})=>async()=>{let n=Hz.getProfileName(r),{configFile:i,credentialsFile:o}=await Hz.loadSharedConfigFiles(r),s=o[n]||{},a=i[n]||{},c=t==="config"?{...s,...a}:{...a,...s};try{let l=e(c,t==="config"?i:o);if(l===void 0)throw new Error;return l}catch(u){throw new gh.CredentialsProviderError(u.message||`Not found in config files w/ profile [${n}]: ${$z(e.toString())}`,{logger:r.logger})}},JRe=e=>typeof e=="function",QRe=e=>JRe(e)?async()=>await e():gh.fromStatic(e),ZRe=({environmentVariableSelector:e,configFileSelector:t,default:r},n={})=>{let{signingName:i,logger:o}=n,s={signingName:i,logger:o};return gh.memoize(gh.chain(YRe(e,s),XRe(t,n),QRe(r)))};Gz.loadConfig=ZRe});var Kz=E(y0=>{"use strict";Object.defineProperty(y0,"__esModule",{value:!0});y0.getEndpointUrlConfig=void 0;var zz=Go(),Vz="AWS_ENDPOINT_URL",Wz="endpoint_url",ePe=e=>({environmentVariableSelector:t=>{let r=e.split(" ").map(o=>o.toUpperCase()),n=t[[Vz,...r].join("_")];if(n)return n;let i=t[Vz];if(i)return i},configFileSelector:(t,r)=>{if(r&&t.services){let i=r[["services",t.services].join(zz.CONFIG_PREFIX_SEPARATOR)];if(i){let o=e.split(" ").map(a=>a.toLowerCase()),s=i[[o.join("_"),Wz].join(zz.CONFIG_PREFIX_SEPARATOR)];if(s)return s}}let n=t[Wz];if(n)return n},default:void 0});y0.getEndpointUrlConfig=ePe});var Yz=E(_0=>{"use strict";Object.defineProperty(_0,"__esModule",{value:!0});_0.getEndpointFromConfig=void 0;var tPe=zo(),rPe=Kz(),nPe=async e=>(0,tPe.loadConfig)((0,rPe.getEndpointUrlConfig)(e??""))();_0.getEndpointFromConfig=nPe});var ao=E(js=>{"use strict";var Jz=Yz(),Xz=qs(),iPe=(wn(),Ve(ou)),b0=an(),oPe=vR(),sPe=async e=>{let t=e?.Bucket||"";if(typeof e.Bucket=="string"&&(e.Bucket=t.replace(/#/g,encodeURIComponent("#")).replace(/\?/g,encodeURIComponent("?"))),fPe(t)){if(e.ForcePathStyle===!0)throw new Error("Path-style addressing cannot be used with ARN buckets")}else(!lPe(t)||t.indexOf(".")!==-1&&!String(e.Endpoint).startsWith("http:")||t.toLowerCase()!==t||t.length<3)&&(e.ForcePathStyle=!0);return e.DisableMultiRegionAccessPoints&&(e.disableMultiRegionAccessPoints=!0,e.DisableMRAP=!0),e},aPe=/^[a-z0-9][a-z0-9\.\-]{1,61}[a-z0-9]$/,cPe=/(\d+\.){3}\d+/,uPe=/\.\./,lPe=e=>aPe.test(e)&&!cPe.test(e)&&!uPe.test(e),fPe=e=>{let[t,r,n,,,i]=e.split(":"),o=t==="arn"&&e.split(":").length>=6,s=!!(o&&r&&n&&i);if(o&&!s)throw new Error(`Invalid ARN: ${e} was an invalid ARN.`);return s},dPe=(e,t,r)=>{let n=async()=>{let i=r[e]??r[t];return typeof i=="function"?i():i};return e==="credentialScope"||t==="CredentialScope"?async()=>{let i=typeof r.credentials=="function"?await r.credentials():r.credentials;return i?.credentialScope??i?.CredentialScope}:e==="accountId"||t==="AccountId"?async()=>{let i=typeof r.credentials=="function"?await r.credentials():r.credentials;return i?.accountId??i?.AccountId}:e==="endpoint"||t==="endpoint"?async()=>{if(r.isCustomEndpoint===!1)return;let i=await n();if(i&&typeof i=="object"){if("url"in i)return i.url.href;if("hostname"in i){let{protocol:o,hostname:s,port:a,path:c}=i;return`${o}//${s}${a?":"+a:""}${c}`}}return i}:n},RI=e=>typeof e=="object"?"url"in e?Xz.parseUrl(e.url):e:Xz.parseUrl(e),Qz=async(e,t,r,n)=>{if(!r.isCustomEndpoint){let s;r.serviceConfiguredEndpoint?s=await r.serviceConfiguredEndpoint():s=await Jz.getEndpointFromConfig(r.serviceId),s&&(r.endpoint=()=>Promise.resolve(RI(s)),r.isCustomEndpoint=!0)}let i=await Zz(e,t,r);if(typeof r.endpointProvider!="function")throw new Error("config.endpointProvider is not set.");return r.endpointProvider(i,n)},Zz=async(e,t,r)=>{let n={},i=t?.getEndpointParameterInstructions?.()||{};for(let[o,s]of Object.entries(i))switch(s.type){case"staticContextParams":n[o]=s.value;break;case"contextParams":n[o]=e[s.name];break;case"clientContextParams":case"builtInParams":n[o]=await dPe(s.name,o,r)();break;case"operationContextParams":n[o]=s.get(e);break;default:throw new Error("Unrecognized endpoint parameter instruction: "+JSON.stringify(s))}return Object.keys(i).length===0&&Object.assign(n,r),String(r.serviceId).toLowerCase()==="s3"&&await sPe(n),n},eV=({config:e,instructions:t})=>(r,n)=>async i=>{e.isCustomEndpoint&&iPe.setFeature(n,"ENDPOINT_OVERRIDE","N");let o=await Qz(i.input,{getEndpointParameterInstructions(){return t}},{...e},n);n.endpointV2=o,n.authSchemes=o.properties?.authSchemes;let s=n.authSchemes?.[0];if(s){n.signing_region=s.signingRegion,n.signing_service=s.signingName;let c=b0.getSmithyContext(n)?.selectedHttpAuthScheme?.httpAuthOption;c&&(c.signingProperties=Object.assign(c.signingProperties||{},{signing_region:s.signingRegion,signingRegion:s.signingRegion,signing_service:s.signingName,signingName:s.signingName,signingRegionSet:s.signingRegionSet},s.properties))}return r({...i})},tV={step:"serialize",tags:["ENDPOINT_PARAMETERS","ENDPOINT_V2","ENDPOINT"],name:"endpointV2Middleware",override:!0,relation:"before",toMiddleware:oPe.serializerMiddlewareOption.name},pPe=(e,t)=>({applyToStack:r=>{r.addRelativeTo(eV({config:e,instructions:t}),tV)}}),hPe=e=>{let t=e.tls??!0,{endpoint:r,useDualstackEndpoint:n,useFipsEndpoint:i}=e,o=r!=null?async()=>RI(await b0.normalizeProvider(r)()):void 0,a=Object.assign(e,{endpoint:o,tls:t,isCustomEndpoint:!!r,useDualstackEndpoint:b0.normalizeProvider(n??!1),useFipsEndpoint:b0.normalizeProvider(i??!1)}),c;return a.serviceConfiguredEndpoint=async()=>(e.serviceId&&!c&&(c=Jz.getEndpointFromConfig(e.serviceId)),c),a},mPe=e=>{let{endpoint:t}=e;return t===void 0&&(e.endpoint=async()=>{throw new Error("@smithy/middleware-endpoint: (default endpointRuleSet) endpoint is not set - you must configure an endpoint.")}),e};js.endpointMiddleware=eV;js.endpointMiddlewareOptions=tV;js.getEndpointFromInstructions=Qz;js.getEndpointPlugin=pPe;js.resolveEndpointConfig=hPe;js.resolveEndpointRequiredConfig=mPe;js.resolveParams=Zz;js.toEndpointV1=RI});var OI=E(Ga=>{"use strict";var gPe=["AuthFailure","InvalidSignatureException","RequestExpired","RequestInTheFuture","RequestTimeTooSkewed","SignatureDoesNotMatch"],yPe=["BandwidthLimitExceeded","EC2ThrottledException","LimitExceededException","PriorRequestNotComplete","ProvisionedThroughputExceededException","RequestLimitExceeded","RequestThrottled","RequestThrottledException","SlowDown","ThrottledException","Throttling","ThrottlingException","TooManyRequestsException","TransactionInProgressException"],_Pe=["TimeoutError","RequestTimeout","RequestTimeoutException"],bPe=[500,502,503,504],EPe=["ECONNRESET","ECONNREFUSED","EPIPE","ETIMEDOUT"],wPe=["EHOSTUNREACH","ENETUNREACH","ENOTFOUND"],rV=e=>e?.$retryable!==void 0,SPe=e=>gPe.includes(e.name),nV=e=>e.$metadata?.clockSkewCorrected,iV=e=>{let t=new Set(["Failed to fetch","NetworkError when attempting to fetch resource","The Internet connection appears to be offline","Load failed","Network request failed"]);return e&&e instanceof TypeError?t.has(e.message):!1},vPe=e=>e.$metadata?.httpStatusCode===429||yPe.includes(e.name)||e.$retryable?.throttling==!0,PI=(e,t=0)=>rV(e)||nV(e)||_Pe.includes(e.name)||EPe.includes(e?.code||"")||wPe.includes(e?.code||"")||bPe.includes(e.$metadata?.httpStatusCode||0)||iV(e)||e.cause!==void 0&&t<=10&&PI(e.cause,t+1),CPe=e=>{if(e.$metadata?.httpStatusCode!==void 0){let t=e.$metadata.httpStatusCode;return 500<=t&&t<=599&&!PI(e)}return!1};Ga.isBrowserNetworkError=iV;Ga.isClockSkewCorrectedError=nV;Ga.isClockSkewError=SPe;Ga.isRetryableByTrait=rV;Ga.isServerError=CPe;Ga.isThrottlingError=vPe;Ga.isTransientError=PI});var hu=E(lr=>{"use strict";var xPe=OI();lr.RETRY_MODES=void 0;(function(e){e.STANDARD="standard",e.ADAPTIVE="adaptive"})(lr.RETRY_MODES||(lr.RETRY_MODES={}));var II=3,TPe=lr.RETRY_MODES.STANDARD,E0=class e{static setTimeoutFn=setTimeout;beta;minCapacity;minFillRate;scaleConstant;smooth;currentCapacity=0;enabled=!1;lastMaxRate=0;measuredTxRate=0;requestCount=0;fillRate;lastThrottleTime;lastTimestamp=0;lastTxRateBucket;maxCapacity;timeWindow=0;constructor(t){this.beta=t?.beta??.7,this.minCapacity=t?.minCapacity??1,this.minFillRate=t?.minFillRate??.5,this.scaleConstant=t?.scaleConstant??.4,this.smooth=t?.smooth??.8;let r=this.getCurrentTimeInSeconds();this.lastThrottleTime=r,this.lastTxRateBucket=Math.floor(this.getCurrentTimeInSeconds()),this.fillRate=this.minFillRate,this.maxCapacity=this.minCapacity}getCurrentTimeInSeconds(){return Date.now()/1e3}async getSendToken(){return this.acquireTokenBucket(1)}async acquireTokenBucket(t){if(this.enabled){if(this.refillTokenBucket(),t>this.currentCapacity){let r=(t-this.currentCapacity)/this.fillRate*1e3;await new Promise(n=>e.setTimeoutFn(n,r))}this.currentCapacity=this.currentCapacity-t}}refillTokenBucket(){let t=this.getCurrentTimeInSeconds();if(!this.lastTimestamp){this.lastTimestamp=t;return}let r=(t-this.lastTimestamp)*this.fillRate;this.currentCapacity=Math.min(this.maxCapacity,this.currentCapacity+r),this.lastTimestamp=t}updateClientSendingRate(t){let r;if(this.updateMeasuredRate(),xPe.isThrottlingError(t)){let i=this.enabled?Math.min(this.measuredTxRate,this.fillRate):this.measuredTxRate;this.lastMaxRate=i,this.calculateTimeWindow(),this.lastThrottleTime=this.getCurrentTimeInSeconds(),r=this.cubicThrottle(i),this.enableTokenBucket()}else this.calculateTimeWindow(),r=this.cubicSuccess(this.getCurrentTimeInSeconds());let n=Math.min(r,2*this.measuredTxRate);this.updateTokenBucketRate(n)}calculateTimeWindow(){this.timeWindow=this.getPrecise(Math.pow(this.lastMaxRate*(1-this.beta)/this.scaleConstant,1/3))}cubicThrottle(t){return this.getPrecise(t*this.beta)}cubicSuccess(t){return this.getPrecise(this.scaleConstant*Math.pow(t-this.lastThrottleTime-this.timeWindow,3)+this.lastMaxRate)}enableTokenBucket(){this.enabled=!0}updateTokenBucketRate(t){this.refillTokenBucket(),this.fillRate=Math.max(t,this.minFillRate),this.maxCapacity=Math.max(t,this.minCapacity),this.currentCapacity=Math.min(this.currentCapacity,this.maxCapacity)}updateMeasuredRate(){let t=this.getCurrentTimeInSeconds(),r=Math.floor(t*2)/2;if(this.requestCount++,r>this.lastTxRateBucket){let n=this.requestCount/(r-this.lastTxRateBucket);this.measuredTxRate=this.getPrecise(n*this.smooth+this.measuredTxRate*(1-this.smooth)),this.requestCount=0,this.lastTxRateBucket=r}}getPrecise(t){return parseFloat(t.toFixed(8))}},yh=100,MI=20*1e3,sV=500,DI=500,aV=5,cV=10,uV=1,APe="amz-sdk-invocation-id",RPe="amz-sdk-request",PPe=()=>{let e=yh;return{computeNextBackoffDelay:n=>Math.floor(Math.min(MI,Math.random()*2**n*e)),setDelayBase:n=>{e=n}}},oV=({retryDelay:e,retryCount:t,retryCost:r})=>({getRetryCount:()=>t,getRetryDelay:()=>Math.min(MI,e),getRetryCost:()=>r}),_h=class{maxAttempts;mode=lr.RETRY_MODES.STANDARD;capacity=DI;retryBackoffStrategy=PPe();maxAttemptsProvider;constructor(t){this.maxAttempts=t,this.maxAttemptsProvider=typeof t=="function"?t:async()=>t}async acquireInitialRetryToken(t){return oV({retryDelay:yh,retryCount:0})}async refreshRetryTokenForRetry(t,r){let n=await this.getMaxAttempts();if(this.shouldRetry(t,r,n)){let i=r.errorType;this.retryBackoffStrategy.setDelayBase(i==="THROTTLING"?sV:yh);let o=this.retryBackoffStrategy.computeNextBackoffDelay(t.getRetryCount()),s=r.retryAfterHint?Math.max(r.retryAfterHint.getTime()-Date.now()||0,o):o,a=this.getCapacityCost(i);return this.capacity-=a,oV({retryDelay:s,retryCount:t.getRetryCount()+1,retryCost:a})}throw new Error("No retry token available")}recordSuccess(t){this.capacity=Math.max(DI,this.capacity+(t.getRetryCost()??uV))}getCapacity(){return this.capacity}async getMaxAttempts(){try{return await this.maxAttemptsProvider()}catch{return console.warn(`Max attempts provider could not resolve. Using default of ${II}`),II}}shouldRetry(t,r,n){return t.getRetryCount()+1<n&&this.capacity>=this.getCapacityCost(r.errorType)&&this.isRetryableError(r.errorType)}getCapacityCost(t){return t==="TRANSIENT"?cV:aV}isRetryableError(t){return t==="THROTTLING"||t==="TRANSIENT"}},kI=class{maxAttemptsProvider;rateLimiter;standardRetryStrategy;mode=lr.RETRY_MODES.ADAPTIVE;constructor(t,r){this.maxAttemptsProvider=t;let{rateLimiter:n}=r??{};this.rateLimiter=n??new E0,this.standardRetryStrategy=new _h(t)}async acquireInitialRetryToken(t){return await this.rateLimiter.getSendToken(),this.standardRetryStrategy.acquireInitialRetryToken(t)}async refreshRetryTokenForRetry(t,r){return this.rateLimiter.updateClientSendingRate(r),this.standardRetryStrategy.refreshRetryTokenForRetry(t,r)}recordSuccess(t){this.rateLimiter.updateClientSendingRate({}),this.standardRetryStrategy.recordSuccess(t)}},NI=class extends _h{computeNextBackoffDelay;constructor(t,r=yh){super(typeof t=="function"?t:async()=>t),typeof r=="number"?this.computeNextBackoffDelay=()=>r:this.computeNextBackoffDelay=r}async refreshRetryTokenForRetry(t,r){let n=await super.refreshRetryTokenForRetry(t,r);return n.getRetryDelay=()=>this.computeNextBackoffDelay(n.getRetryCount()),n}};lr.AdaptiveRetryStrategy=kI;lr.ConfiguredRetryStrategy=NI;lr.DEFAULT_MAX_ATTEMPTS=II;lr.DEFAULT_RETRY_DELAY_BASE=yh;lr.DEFAULT_RETRY_MODE=TPe;lr.DefaultRateLimiter=E0;lr.INITIAL_RETRY_TOKENS=DI;lr.INVOCATION_ID_HEADER=APe;lr.MAXIMUM_RETRY_DELAY=MI;lr.NO_RETRY_INCREMENT=uV;lr.REQUEST_HEADER=RPe;lr.RETRY_COST=aV;lr.StandardRetryStrategy=_h;lr.THROTTLING_RETRY_DELAY_BASE=sV;lr.TIMEOUT_RETRY_COST=cV});var lV=E(w0=>{"use strict";Object.defineProperty(w0,"__esModule",{value:!0});w0.isStreamingPayload=void 0;var OPe=require("stream"),IPe=e=>e?.body instanceof OPe.Readable||typeof ReadableStream<"u"&&e?.body instanceof ReadableStream;w0.isStreamingPayload=IPe});var co=E(kr=>{"use strict";var ar=hu(),gf=St(),za=OI(),dV=wP(),fV=an(),DPe=Ge(),kPe=lV(),NPe=(e,t)=>{let r=e,n=ar.NO_RETRY_INCREMENT,i=ar.RETRY_COST,o=ar.TIMEOUT_RETRY_COST,s=e,a=d=>d.name==="TimeoutError"?o:i,c=d=>a(d)<=s;return Object.freeze({hasRetryTokens:c,retrieveRetryTokens:d=>{if(!c(d))throw new Error("No retry token available");let h=a(d);return s-=h,h},releaseRetryTokens:d=>{s+=d??n,s=Math.min(s,r)}})},pV=(e,t)=>Math.floor(Math.min(ar.MAXIMUM_RETRY_DELAY,Math.random()*2**t*e)),hV=e=>e?za.isRetryableByTrait(e)||za.isClockSkewError(e)||za.isThrottlingError(e)||za.isTransientError(e):!1,mV=e=>e instanceof Error?e:e instanceof Object?Object.assign(new Error,e):typeof e=="string"?new Error(e):new Error(`AWS SDK error wrapper for ${e}`),S0=class{maxAttemptsProvider;retryDecider;delayDecider;retryQuota;mode=ar.RETRY_MODES.STANDARD;constructor(t,r){this.maxAttemptsProvider=t,this.retryDecider=r?.retryDecider??hV,this.delayDecider=r?.delayDecider??pV,this.retryQuota=r?.retryQuota??NPe(ar.INITIAL_RETRY_TOKENS)}shouldRetry(t,r,n){return r<n&&this.retryDecider(t)&&this.retryQuota.hasRetryTokens(t)}async getMaxAttempts(){let t;try{t=await this.maxAttemptsProvider()}catch{t=ar.DEFAULT_MAX_ATTEMPTS}return t}async retry(t,r,n){let i,o=0,s=0,a=await this.getMaxAttempts(),{request:c}=r;for(gf.HttpRequest.isInstance(c)&&(c.headers[ar.INVOCATION_ID_HEADER]=dV.v4());;)try{gf.HttpRequest.isInstance(c)&&(c.headers[ar.REQUEST_HEADER]=`attempt=${o+1}; max=${a}`),n?.beforeRequest&&await n.beforeRequest();let{response:u,output:l}=await t(r);return n?.afterRequest&&n.afterRequest(u),this.retryQuota.releaseRetryTokens(i),l.$metadata.attempts=o+1,l.$metadata.totalRetryDelay=s,{response:u,output:l}}catch(u){let l=mV(u);if(o++,this.shouldRetry(l,o,a)){i=this.retryQuota.retrieveRetryTokens(l);let d=this.delayDecider(za.isThrottlingError(l)?ar.THROTTLING_RETRY_DELAY_BASE:ar.DEFAULT_RETRY_DELAY_BASE,o),h=MPe(l.$response),f=Math.max(h||0,d);s+=f,await new Promise(p=>setTimeout(p,f));continue}throw l.$metadata||(l.$metadata={}),l.$metadata.attempts=o,l.$metadata.totalRetryDelay=s,l}}},MPe=e=>{if(!gf.HttpResponse.isInstance(e))return;let t=Object.keys(e.headers).find(o=>o.toLowerCase()==="retry-after");if(!t)return;let r=e.headers[t],n=Number(r);return Number.isNaN(n)?new Date(r).getTime()-Date.now():n*1e3},LI=class extends S0{rateLimiter;constructor(t,r){let{rateLimiter:n,...i}=r??{};super(t,i),this.rateLimiter=n??new ar.DefaultRateLimiter,this.mode=ar.RETRY_MODES.ADAPTIVE}async retry(t,r){return super.retry(t,r,{beforeRequest:async()=>this.rateLimiter.getSendToken(),afterRequest:n=>{this.rateLimiter.updateClientSendingRate(n)}})}},BI="AWS_MAX_ATTEMPTS",FI="max_attempts",LPe={environmentVariableSelector:e=>{let t=e[BI];if(!t)return;let r=parseInt(t);if(Number.isNaN(r))throw new Error(`Environment variable ${BI} mast be a number, got "${t}"`);return r},configFileSelector:e=>{let t=e[FI];if(!t)return;let r=parseInt(t);if(Number.isNaN(r))throw new Error(`Shared config file entry ${FI} mast be a number, got "${t}"`);return r},default:ar.DEFAULT_MAX_ATTEMPTS},BPe=e=>{let{retryStrategy:t,retryMode:r,maxAttempts:n}=e,i=fV.normalizeProvider(n??ar.DEFAULT_MAX_ATTEMPTS);return Object.assign(e,{maxAttempts:i,retryStrategy:async()=>t||(await fV.normalizeProvider(r)()===ar.RETRY_MODES.ADAPTIVE?new ar.AdaptiveRetryStrategy(i):new ar.StandardRetryStrategy(i))})},gV="AWS_RETRY_MODE",yV="retry_mode",FPe={environmentVariableSelector:e=>e[gV],configFileSelector:e=>e[yV],default:ar.DEFAULT_RETRY_MODE},_V=()=>e=>async t=>{let{request:r}=t;return gf.HttpRequest.isInstance(r)&&(delete r.headers[ar.INVOCATION_ID_HEADER],delete r.headers[ar.REQUEST_HEADER]),e(t)},bV={name:"omitRetryHeadersMiddleware",tags:["RETRY","HEADERS","OMIT_RETRY_HEADERS"],relation:"before",toMiddleware:"awsAuthMiddleware",override:!0},qPe=e=>({applyToStack:t=>{t.addRelativeTo(_V(),bV)}}),EV=e=>(t,r)=>async n=>{let i=await e.retryStrategy(),o=await e.maxAttempts();if(jPe(i)){i=i;let s=await i.acquireInitialRetryToken(r.partition_id),a=new Error,c=0,u=0,{request:l}=n,d=gf.HttpRequest.isInstance(l);for(d&&(l.headers[ar.INVOCATION_ID_HEADER]=dV.v4());;)try{d&&(l.headers[ar.REQUEST_HEADER]=`attempt=${c+1}; max=${o}`);let{response:h,output:f}=await t(n);return i.recordSuccess(s),f.$metadata.attempts=c+1,f.$metadata.totalRetryDelay=u,{response:h,output:f}}catch(h){let f=UPe(h);if(a=mV(h),d&&kPe.isStreamingPayload(l))throw(r.logger instanceof DPe.NoOpLogger?console:r.logger)?.warn("An error was encountered in a non-retryable streaming request."),a;try{s=await i.refreshRetryTokenForRetry(s,f)}catch{throw a.$metadata||(a.$metadata={}),a.$metadata.attempts=c+1,a.$metadata.totalRetryDelay=u,a}c=s.getRetryCount();let p=s.getRetryDelay();u+=p,await new Promise(m=>setTimeout(m,p))}}else return i=i,i?.mode&&(r.userAgent=[...r.userAgent||[],["cfg/retry-mode",i.mode]]),i.retry(t,n)},jPe=e=>typeof e.acquireInitialRetryToken<"u"&&typeof e.refreshRetryTokenForRetry<"u"&&typeof e.recordSuccess<"u",UPe=e=>{let t={error:e,errorType:HPe(e)},r=SV(e.$response);return r&&(t.retryAfterHint=r),t},HPe=e=>za.isThrottlingError(e)?"THROTTLING":za.isTransientError(e)?"TRANSIENT":za.isServerError(e)?"SERVER_ERROR":"CLIENT_ERROR",wV={name:"retryMiddleware",tags:["RETRY"],step:"finalizeRequest",priority:"high",override:!0},$Pe=e=>({applyToStack:t=>{t.add(EV(e),wV)}}),SV=e=>{if(!gf.HttpResponse.isInstance(e))return;let t=Object.keys(e.headers).find(o=>o.toLowerCase()==="retry-after");if(!t)return;let r=e.headers[t],n=Number(r);return Number.isNaN(n)?new Date(r):new Date(n*1e3)};kr.AdaptiveRetryStrategy=LI;kr.CONFIG_MAX_ATTEMPTS=FI;kr.CONFIG_RETRY_MODE=yV;kr.ENV_MAX_ATTEMPTS=BI;kr.ENV_RETRY_MODE=gV;kr.NODE_MAX_ATTEMPT_CONFIG_OPTIONS=LPe;kr.NODE_RETRY_MODE_CONFIG_OPTIONS=FPe;kr.StandardRetryStrategy=S0;kr.defaultDelayDecider=pV;kr.defaultRetryDecider=hV;kr.getOmitRetryHeadersPlugin=qPe;kr.getRetryAfterHint=SV;kr.getRetryPlugin=$Pe;kr.omitRetryHeadersMiddleware=_V;kr.omitRetryHeadersMiddlewareOptions=bV;kr.resolveRetryConfig=BPe;kr.retryMiddleware=EV;kr.retryMiddlewareOptions=wV});var UI=E(jI=>{"use strict";var GPe=c0(),vV=hb(),bh={CrtSignerV4:null},qI=class{sigv4aSigner;sigv4Signer;signerOptions;static sigv4aDependency(){return typeof bh.CrtSignerV4=="function"?"crt":typeof vV.signatureV4aContainer.SignatureV4a=="function"?"js":"none"}constructor(t){this.sigv4Signer=new GPe.SignatureV4S3Express(t),this.signerOptions=t}async sign(t,r={}){return r.signingRegion==="*"?this.getSigv4aSigner().sign(t,r):this.sigv4Signer.sign(t,r)}async signWithCredentials(t,r,n={}){if(n.signingRegion==="*"){let i=this.getSigv4aSigner(),o=bh.CrtSignerV4;if(o&&i instanceof o)return i.signWithCredentials(t,r,n);throw new Error(`signWithCredentials with signingRegion '*' is only supported when using the CRT dependency @aws-sdk/signature-v4-crt. Please check whether you have installed the "@aws-sdk/signature-v4-crt" package explicitly. You must also register the package by calling [require("@aws-sdk/signature-v4-crt");] or an ESM equivalent such as [import "@aws-sdk/signature-v4-crt";]. For more information please go to https://github.com/aws/aws-sdk-js-v3#functionality-requiring-aws-common-runtime-crt`)}return this.sigv4Signer.signWithCredentials(t,r,n)}async presign(t,r={}){if(r.signingRegion==="*"){let n=this.getSigv4aSigner(),i=bh.CrtSignerV4;if(i&&n instanceof i)return n.presign(t,r);throw new Error(`presign with signingRegion '*' is only supported when using the CRT dependency @aws-sdk/signature-v4-crt. Please check whether you have installed the "@aws-sdk/signature-v4-crt" package explicitly. You must also register the package by calling [require("@aws-sdk/signature-v4-crt");] or an ESM equivalent such as [import "@aws-sdk/signature-v4-crt";]. For more information please go to https://github.com/aws/aws-sdk-js-v3#functionality-requiring-aws-common-runtime-crt`)}return this.sigv4Signer.presign(t,r)}async presignWithCredentials(t,r,n={}){if(n.signingRegion==="*")throw new Error("Method presignWithCredentials is not supported for [signingRegion=*].");return this.sigv4Signer.presignWithCredentials(t,r,n)}getSigv4aSigner(){if(!this.sigv4aSigner){let t=bh.CrtSignerV4,r=vV.signatureV4aContainer.SignatureV4a;if(this.signerOptions.runtime==="node"){if(!t&&!r)throw new Error("Neither CRT nor JS SigV4a implementation is available. Please load either @aws-sdk/signature-v4-crt or @aws-sdk/signature-v4a. For more information please go to https://github.com/aws/aws-sdk-js-v3#functionality-requiring-aws-common-runtime-crt");if(t&&typeof t=="function")this.sigv4aSigner=new t({...this.signerOptions,signingAlgorithm:1});else if(r&&typeof r=="function")this.sigv4aSigner=new r({...this.signerOptions});else throw new Error("Available SigV4a implementation is not a valid constructor. Please ensure you've properly imported @aws-sdk/signature-v4-crt or @aws-sdk/signature-v4a.For more information please go to https://github.com/aws/aws-sdk-js-v3#functionality-requiring-aws-common-runtime-crt")}else{if(!r||typeof r!="function")throw new Error("JS SigV4a implementation is not available or not a valid constructor. Please check whether you have installed the @aws-sdk/signature-v4a package explicitly. The CRT implementation is not available for browsers. You must also register the package by calling [require('@aws-sdk/signature-v4a');] or an ESM equivalent such as [import '@aws-sdk/signature-v4a';]. For more information please go to https://github.com/aws/aws-sdk-js-v3#using-javascript-non-crt-implementation-of-sigv4a");this.sigv4aSigner=new r({...this.signerOptions})}}return this.sigv4aSigner}};jI.SignatureV4MultiRegion=qI;jI.signatureV4CrtContainer=bh});var XW=E(D0=>{"use strict";Object.defineProperty(D0,"__esModule",{value:!0});D0.ruleSet=void 0;var dD="required",k="type",oe="rules",F="conditions",Z="fn",ee="argv",De="ref",We="assign",xe="url",Te="properties",Us="backend",Yr="authSchemes",Tr="disableDoubleEncoding",Ar="signingName",un="signingRegion",Ae="headers",pD="signingRegionSet",zPe=6,VPe=!1,Vo=!0,bi="isSet",br="booleanEquals",Ie="error",R0="aws.partition",mt="stringEquals",cr="getAttr",ur="name",Ht="substring",CV="bucketSuffix",hD="parseURL",ue="endpoint",se="tree",P0="aws.isVirtualHostableS3Bucket",O0="{url#scheme}://{Bucket}.{url#authority}{url#path}",Yo="not",xV="accessPointSuffix",A0="{url#scheme}://{url#authority}{url#path}",NW="hardwareType",MW="regionPrefix",TV="bucketAliasSuffix",lD="outpostId",mu="isValidHostLabel",mD="sigv4a",Th="s3-outposts",Ef="s3",LW="{url#scheme}://{url#authority}{url#normalizedPath}{Bucket}",BW="https://{Bucket}.s3-accelerate.{partitionResult#dnsSuffix}",AV="https://{Bucket}.s3.{partitionResult#dnsSuffix}",FW="aws.parseArn",qW="bucketArn",jW="arnType",I0="",gD="s3-object-lambda",UW="accesspoint",yD="accessPointName",RV="{url#scheme}://{accessPointName}-{bucketArn#accountId}.{url#authority}{url#path}",PV="mrapPartition",OV="outpostType",IV="arnPrefix",HW="{url#scheme}://{url#authority}{url#normalizedPath}{uri_encoded_bucket}",DV="https://s3.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",kV="https://s3.{partitionResult#dnsSuffix}",yf={[dD]:!1,[k]:"string"},_f={[dD]:!0,default:!1,[k]:"boolean"},Eh={[dD]:!1,[k]:"boolean"},qi={[Z]:br,[ee]:[{[De]:"Accelerate"},!0]},Wt={[Z]:br,[ee]:[{[De]:"UseFIPS"},!0]},qt={[Z]:br,[ee]:[{[De]:"UseDualStack"},!0]},_r={[Z]:bi,[ee]:[{[De]:"Endpoint"}]},$W={[Z]:R0,[ee]:[{[De]:"Region"}],[We]:"partitionResult"},NV={[Z]:mt,[ee]:[{[Z]:cr,[ee]:[{[De]:"partitionResult"},ur]},"aws-cn"]},Sh={[Z]:bi,[ee]:[{[De]:"Bucket"}]},dt={[De]:"Bucket"},MV={[F]:[qi],[Ie]:"S3Express does not support S3 Accelerate.",[k]:Ie},LV={[F]:[_r,{[Z]:hD,[ee]:[{[De]:"Endpoint"}],[We]:"url"}],[oe]:[{[F]:[{[Z]:bi,[ee]:[{[De]:"DisableS3ExpressSessionAuth"}]},{[Z]:br,[ee]:[{[De]:"DisableS3ExpressSessionAuth"},!0]}],[oe]:[{[F]:[{[Z]:br,[ee]:[{[Z]:cr,[ee]:[{[De]:"url"},"isIp"]},!0]}],[oe]:[{[F]:[{[Z]:"uriEncode",[ee]:[dt],[We]:"uri_encoded_bucket"}],[oe]:[{[ue]:{[xe]:"{url#scheme}://{url#authority}/{uri_encoded_bucket}{url#path}",[Te]:{[Us]:"S3Express",[Yr]:[{[Tr]:!0,[ur]:"sigv4",[Ar]:"s3express",[un]:"{Region}"}]},[Ae]:{}},[k]:ue}],[k]:se}],[k]:se},{[F]:[{[Z]:P0,[ee]:[dt,!1]}],[oe]:[{[ue]:{[xe]:O0,[Te]:{[Us]:"S3Express",[Yr]:[{[Tr]:!0,[ur]:"sigv4",[Ar]:"s3express",[un]:"{Region}"}]},[Ae]:{}},[k]:ue}],[k]:se},{[Ie]:"S3Express bucket name is not a valid virtual hostable name.",[k]:Ie}],[k]:se},{[F]:[{[Z]:br,[ee]:[{[Z]:cr,[ee]:[{[De]:"url"},"isIp"]},!0]}],[oe]:[{[F]:[{[Z]:"uriEncode",[ee]:[dt],[We]:"uri_encoded_bucket"}],[oe]:[{[ue]:{[xe]:"{url#scheme}://{url#authority}/{uri_encoded_bucket}{url#path}",[Te]:{[Us]:"S3Express",[Yr]:[{[Tr]:!0,[ur]:"sigv4-s3express",[Ar]:"s3express",[un]:"{Region}"}]},[Ae]:{}},[k]:ue}],[k]:se}],[k]:se},{[F]:[{[Z]:P0,[ee]:[dt,!1]}],[oe]:[{[ue]:{[xe]:O0,[Te]:{[Us]:"S3Express",[Yr]:[{[Tr]:!0,[ur]:"sigv4-s3express",[Ar]:"s3express",[un]:"{Region}"}]},[Ae]:{}},[k]:ue}],[k]:se},{[Ie]:"S3Express bucket name is not a valid virtual hostable name.",[k]:Ie}],[k]:se},Gn={[Z]:hD,[ee]:[{[De]:"Endpoint"}],[We]:"url"},HI={[Z]:br,[ee]:[{[Z]:cr,[ee]:[{[De]:"url"},"isIp"]},!0]},GW={[De]:"url"},zW={[Z]:"uriEncode",[ee]:[dt],[We]:"uri_encoded_bucket"},_i={[Us]:"S3Express",[Yr]:[{[Tr]:!0,[ur]:"sigv4",[Ar]:"s3express",[un]:"{Region}"}]},qe={},VW={[Z]:P0,[ee]:[dt,!1]},BV={[Ie]:"S3Express bucket name is not a valid virtual hostable name.",[k]:Ie},FV={[Z]:bi,[ee]:[{[De]:"UseS3ExpressControlEndpoint"}]},qV={[Z]:br,[ee]:[{[De]:"UseS3ExpressControlEndpoint"},!0]},ze={[Z]:Yo,[ee]:[_r]},ot={[Z]:br,[ee]:[{[De]:"UseDualStack"},!1]},Je={[Z]:br,[ee]:[{[De]:"UseFIPS"},!1]},v0={[Ie]:"Unrecognized S3Express bucket name format.",[k]:Ie},jV={[Z]:Yo,[ee]:[Sh]},UV={[De]:NW},HV={[F]:[ze],[Ie]:"Expected a endpoint to be specified but no endpoint was found",[k]:Ie},C0={[Yr]:[{[Tr]:!0,[ur]:mD,[Ar]:Th,[pD]:["*"]},{[Tr]:!0,[ur]:"sigv4",[Ar]:Th,[un]:"{Region}"}]},$I={[Z]:br,[ee]:[{[De]:"ForcePathStyle"},!1]},WPe={[De]:"ForcePathStyle"},xr={[Z]:br,[ee]:[{[De]:"Accelerate"},!1]},Nr={[Z]:mt,[ee]:[{[De]:"Region"},"aws-global"]},Vr={[Yr]:[{[Tr]:!0,[ur]:"sigv4",[Ar]:Ef,[un]:"us-east-1"}]},lt={[Z]:Yo,[ee]:[Nr]},Wr={[Z]:br,[ee]:[{[De]:"UseGlobalEndpoint"},!0]},$V={[xe]:"https://{Bucket}.s3-fips.dualstack.{Region}.{partitionResult#dnsSuffix}",[Te]:{[Yr]:[{[Tr]:!0,[ur]:"sigv4",[Ar]:Ef,[un]:"{Region}"}]},[Ae]:{}},Rr={[Yr]:[{[Tr]:!0,[ur]:"sigv4",[Ar]:Ef,[un]:"{Region}"}]},Kr={[Z]:br,[ee]:[{[De]:"UseGlobalEndpoint"},!1]},GV={[xe]:"https://{Bucket}.s3-fips.{Region}.{partitionResult#dnsSuffix}",[Te]:Rr,[Ae]:{}},zV={[xe]:"https://{Bucket}.s3-accelerate.dualstack.{partitionResult#dnsSuffix}",[Te]:Rr,[Ae]:{}},VV={[xe]:"https://{Bucket}.s3.dualstack.{Region}.{partitionResult#dnsSuffix}",[Te]:Rr,[Ae]:{}},GI={[Z]:br,[ee]:[{[Z]:cr,[ee]:[GW,"isIp"]},!1]},zI={[xe]:LW,[Te]:Rr,[Ae]:{}},fD={[xe]:O0,[Te]:Rr,[Ae]:{}},WV={[ue]:fD,[k]:ue},VI={[xe]:BW,[Te]:Rr,[Ae]:{}},KV={[xe]:"https://{Bucket}.s3.{Region}.{partitionResult#dnsSuffix}",[Te]:Rr,[Ae]:{}},x0={[Ie]:"Invalid region: region was not a valid DNS name.",[k]:Ie},ai={[De]:qW},WW={[De]:jW},WI={[Z]:cr,[ee]:[ai,"service"]},_D={[De]:yD},YV={[F]:[qt],[Ie]:"S3 Object Lambda does not support Dual-stack",[k]:Ie},XV={[F]:[qi],[Ie]:"S3 Object Lambda does not support S3 Accelerate",[k]:Ie},JV={[F]:[{[Z]:bi,[ee]:[{[De]:"DisableAccessPoints"}]},{[Z]:br,[ee]:[{[De]:"DisableAccessPoints"},!0]}],[Ie]:"Access points are not supported for this operation",[k]:Ie},KI={[F]:[{[Z]:bi,[ee]:[{[De]:"UseArnRegion"}]},{[Z]:br,[ee]:[{[De]:"UseArnRegion"},!1]},{[Z]:Yo,[ee]:[{[Z]:mt,[ee]:[{[Z]:cr,[ee]:[ai,"region"]},"{Region}"]}]}],[Ie]:"Invalid configuration: region from ARN `{bucketArn#region}` does not match client region `{Region}` and UseArnRegion is `false`",[k]:Ie},KW={[Z]:cr,[ee]:[{[De]:"bucketPartition"},ur]},YW={[Z]:cr,[ee]:[ai,"accountId"]},YI={[Yr]:[{[Tr]:!0,[ur]:"sigv4",[Ar]:gD,[un]:"{bucketArn#region}"}]},QV={[Ie]:"Invalid ARN: The access point name may only contain a-z, A-Z, 0-9 and `-`. Found: `{accessPointName}`",[k]:Ie},XI={[Ie]:"Invalid ARN: The account id may only contain a-z, A-Z, 0-9 and `-`. Found: `{bucketArn#accountId}`",[k]:Ie},JI={[Ie]:"Invalid region in ARN: `{bucketArn#region}` (invalid DNS name)",[k]:Ie},QI={[Ie]:"Client was configured for partition `{partitionResult#name}` but ARN (`{Bucket}`) has `{bucketPartition#name}`",[k]:Ie},ZV={[Ie]:"Invalid ARN: The ARN may only contain a single resource component after `accesspoint`.",[k]:Ie},eW={[Ie]:"Invalid ARN: Expected a resource of the format `accesspoint:<accesspoint name>` but no name was provided",[k]:Ie},wh={[Yr]:[{[Tr]:!0,[ur]:"sigv4",[Ar]:Ef,[un]:"{bucketArn#region}"}]},tW={[Yr]:[{[Tr]:!0,[ur]:mD,[Ar]:Th,[pD]:["*"]},{[Tr]:!0,[ur]:"sigv4",[Ar]:Th,[un]:"{bucketArn#region}"}]},rW={[Z]:FW,[ee]:[dt]},nW={[xe]:"https://s3-fips.dualstack.{Region}.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",[Te]:Rr,[Ae]:{}},iW={[xe]:"https://s3-fips.{Region}.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",[Te]:Rr,[Ae]:{}},oW={[xe]:"https://s3.dualstack.{Region}.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",[Te]:Rr,[Ae]:{}},ZI={[xe]:HW,[Te]:Rr,[Ae]:{}},sW={[xe]:"https://s3.{Region}.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",[Te]:Rr,[Ae]:{}},aW={[De]:"UseObjectLambdaEndpoint"},eD={[Yr]:[{[Tr]:!0,[ur]:"sigv4",[Ar]:gD,[un]:"{Region}"}]},cW={[xe]:"https://s3-fips.dualstack.{Region}.{partitionResult#dnsSuffix}",[Te]:Rr,[Ae]:{}},uW={[xe]:"https://s3-fips.{Region}.{partitionResult#dnsSuffix}",[Te]:Rr,[Ae]:{}},lW={[xe]:"https://s3.dualstack.{Region}.{partitionResult#dnsSuffix}",[Te]:Rr,[Ae]:{}},tD={[xe]:A0,[Te]:Rr,[Ae]:{}},fW={[xe]:"https://s3.{Region}.{partitionResult#dnsSuffix}",[Te]:Rr,[Ae]:{}},rD=[{[De]:"Region"}],KPe=[{[De]:"Endpoint"}],YPe=[dt],nD=[qi],bf=[_r,Gn],dW=[{[Z]:bi,[ee]:[{[De]:"DisableS3ExpressSessionAuth"}]},{[Z]:br,[ee]:[{[De]:"DisableS3ExpressSessionAuth"},!0]}],XPe=[zW],pW=[VW],Fi=[$W],iD=[Wt,qt],vh=[Wt,ot],Ch=[Je,qt],xh=[Je,ot],hW=[{[Z]:Ht,[ee]:[dt,6,14,!0],[We]:"s3expressAvailabilityZoneId"},{[Z]:Ht,[ee]:[dt,14,16,!0],[We]:"s3expressAvailabilityZoneDelim"},{[Z]:mt,[ee]:[{[De]:"s3expressAvailabilityZoneDelim"},"--"]}],Wo=[{[F]:[Wt,qt],[ue]:{[xe]:"https://{Bucket}.s3express-fips-{s3expressAvailabilityZoneId}.dualstack.{Region}.{partitionResult#dnsSuffix}",[Te]:_i,[Ae]:{}},[k]:ue},{[F]:vh,[ue]:{[xe]:"https://{Bucket}.s3express-fips-{s3expressAvailabilityZoneId}.{Region}.{partitionResult#dnsSuffix}",[Te]:_i,[Ae]:{}},[k]:ue},{[F]:Ch,[ue]:{[xe]:"https://{Bucket}.s3express-{s3expressAvailabilityZoneId}.dualstack.{Region}.{partitionResult#dnsSuffix}",[Te]:_i,[Ae]:{}},[k]:ue},{[F]:xh,[ue]:{[xe]:"https://{Bucket}.s3express-{s3expressAvailabilityZoneId}.{Region}.{partitionResult#dnsSuffix}",[Te]:_i,[Ae]:{}},[k]:ue}],mW=[{[Z]:Ht,[ee]:[dt,6,15,!0],[We]:"s3expressAvailabilityZoneId"},{[Z]:Ht,[ee]:[dt,15,17,!0],[We]:"s3expressAvailabilityZoneDelim"},{[Z]:mt,[ee]:[{[De]:"s3expressAvailabilityZoneDelim"},"--"]}],gW=[{[Z]:Ht,[ee]:[dt,6,19,!0],[We]:"s3expressAvailabilityZoneId"},{[Z]:Ht,[ee]:[dt,19,21,!0],[We]:"s3expressAvailabilityZoneDelim"},{[Z]:mt,[ee]:[{[De]:"s3expressAvailabilityZoneDelim"},"--"]}],yW=[{[Z]:Ht,[ee]:[dt,6,20,!0],[We]:"s3expressAvailabilityZoneId"},{[Z]:Ht,[ee]:[dt,20,22,!0],[We]:"s3expressAvailabilityZoneDelim"},{[Z]:mt,[ee]:[{[De]:"s3expressAvailabilityZoneDelim"},"--"]}],_W=[{[Z]:Ht,[ee]:[dt,6,26,!0],[We]:"s3expressAvailabilityZoneId"},{[Z]:Ht,[ee]:[dt,26,28,!0],[We]:"s3expressAvailabilityZoneDelim"},{[Z]:mt,[ee]:[{[De]:"s3expressAvailabilityZoneDelim"},"--"]}],Ko=[{[F]:[Wt,qt],[ue]:{[xe]:"https://{Bucket}.s3express-fips-{s3expressAvailabilityZoneId}.dualstack.{Region}.{partitionResult#dnsSuffix}",[Te]:{[Us]:"S3Express",[Yr]:[{[Tr]:!0,[ur]:"sigv4-s3express",[Ar]:"s3express",[un]:"{Region}"}]},[Ae]:{}},[k]:ue},{[F]:vh,[ue]:{[xe]:"https://{Bucket}.s3express-fips-{s3expressAvailabilityZoneId}.{Region}.{partitionResult#dnsSuffix}",[Te]:{[Us]:"S3Express",[Yr]:[{[Tr]:!0,[ur]:"sigv4-s3express",[Ar]:"s3express",[un]:"{Region}"}]},[Ae]:{}},[k]:ue},{[F]:Ch,[ue]:{[xe]:"https://{Bucket}.s3express-{s3expressAvailabilityZoneId}.dualstack.{Region}.{partitionResult#dnsSuffix}",[Te]:{[Us]:"S3Express",[Yr]:[{[Tr]:!0,[ur]:"sigv4-s3express",[Ar]:"s3express",[un]:"{Region}"}]},[Ae]:{}},[k]:ue},{[F]:xh,[ue]:{[xe]:"https://{Bucket}.s3express-{s3expressAvailabilityZoneId}.{Region}.{partitionResult#dnsSuffix}",[Te]:{[Us]:"S3Express",[Yr]:[{[Tr]:!0,[ur]:"sigv4-s3express",[Ar]:"s3express",[un]:"{Region}"}]},[Ae]:{}},[k]:ue}],bW=[dt,0,7,!0],EW=[{[Z]:Ht,[ee]:[dt,7,15,!0],[We]:"s3expressAvailabilityZoneId"},{[Z]:Ht,[ee]:[dt,15,17,!0],[We]:"s3expressAvailabilityZoneDelim"},{[Z]:mt,[ee]:[{[De]:"s3expressAvailabilityZoneDelim"},"--"]}],wW=[{[Z]:Ht,[ee]:[dt,7,16,!0],[We]:"s3expressAvailabilityZoneId"},{[Z]:Ht,[ee]:[dt,16,18,!0],[We]:"s3expressAvailabilityZoneDelim"},{[Z]:mt,[ee]:[{[De]:"s3expressAvailabilityZoneDelim"},"--"]}],SW=[{[Z]:Ht,[ee]:[dt,7,20,!0],[We]:"s3expressAvailabilityZoneId"},{[Z]:Ht,[ee]:[dt,20,22,!0],[We]:"s3expressAvailabilityZoneDelim"},{[Z]:mt,[ee]:[{[De]:"s3expressAvailabilityZoneDelim"},"--"]}],vW=[{[Z]:Ht,[ee]:[dt,7,21,!0],[We]:"s3expressAvailabilityZoneId"},{[Z]:Ht,[ee]:[dt,21,23,!0],[We]:"s3expressAvailabilityZoneDelim"},{[Z]:mt,[ee]:[{[De]:"s3expressAvailabilityZoneDelim"},"--"]}],CW=[{[Z]:Ht,[ee]:[dt,7,27,!0],[We]:"s3expressAvailabilityZoneId"},{[Z]:Ht,[ee]:[dt,27,29,!0],[We]:"s3expressAvailabilityZoneDelim"},{[Z]:mt,[ee]:[{[De]:"s3expressAvailabilityZoneDelim"},"--"]}],JPe=[Sh],xW=[{[Z]:mu,[ee]:[{[De]:lD},!1]}],TW=[{[Z]:mt,[ee]:[{[De]:MW},"beta"]}],QPe=["*"],AW=[{[Z]:mu,[ee]:[{[De]:"Region"},!1]}],Va=[{[Z]:mt,[ee]:[{[De]:"Region"},"us-east-1"]}],oD=[{[Z]:mt,[ee]:[WW,UW]}],RW=[{[Z]:cr,[ee]:[ai,"resourceId[1]"],[We]:yD},{[Z]:Yo,[ee]:[{[Z]:mt,[ee]:[_D,I0]}]}],ZPe=[ai,"resourceId[1]"],PW=[qt],sD=[{[Z]:Yo,[ee]:[{[Z]:mt,[ee]:[{[Z]:cr,[ee]:[ai,"region"]},I0]}]}],OW=[{[Z]:Yo,[ee]:[{[Z]:bi,[ee]:[{[Z]:cr,[ee]:[ai,"resourceId[2]"]}]}]}],eOe=[ai,"resourceId[2]"],aD=[{[Z]:R0,[ee]:[{[Z]:cr,[ee]:[ai,"region"]}],[We]:"bucketPartition"}],IW=[{[Z]:mt,[ee]:[KW,{[Z]:cr,[ee]:[{[De]:"partitionResult"},ur]}]}],cD=[{[Z]:mu,[ee]:[{[Z]:cr,[ee]:[ai,"region"]},!0]}],uD=[{[Z]:mu,[ee]:[YW,!1]}],DW=[{[Z]:mu,[ee]:[_D,!1]}],T0=[Wt],kW=[{[Z]:mu,[ee]:[{[De]:"Region"},!0]}],tOe={version:"1.0",parameters:{Bucket:yf,Region:yf,UseFIPS:_f,UseDualStack:_f,Endpoint:yf,ForcePathStyle:_f,Accelerate:_f,UseGlobalEndpoint:_f,UseObjectLambdaEndpoint:Eh,Key:yf,Prefix:yf,CopySource:yf,DisableAccessPoints:Eh,DisableMultiRegionAccessPoints:_f,UseArnRegion:Eh,UseS3ExpressControlEndpoint:Eh,DisableS3ExpressSessionAuth:Eh},[oe]:[{[F]:[{[Z]:bi,[ee]:rD}],[oe]:[{[F]:[qi,Wt],error:"Accelerate cannot be used with FIPS",[k]:Ie},{[F]:[qt,_r],error:"Cannot set dual-stack in combination with a custom endpoint.",[k]:Ie},{[F]:[_r,Wt],error:"A custom endpoint cannot be combined with FIPS",[k]:Ie},{[F]:[_r,qi],error:"A custom endpoint cannot be combined with S3 Accelerate",[k]:Ie},{[F]:[Wt,$W,NV],error:"Partition does not support FIPS",[k]:Ie},{[F]:[Sh,{[Z]:Ht,[ee]:[dt,0,zPe,Vo],[We]:CV},{[Z]:mt,[ee]:[{[De]:CV},"--x-s3"]}],[oe]:[MV,LV,{[F]:[FV,qV],[oe]:[{[F]:Fi,[oe]:[{[F]:[zW,ze],[oe]:[{[F]:iD,endpoint:{[xe]:"https://s3express-control-fips.dualstack.{Region}.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",[Te]:_i,[Ae]:qe},[k]:ue},{[F]:vh,endpoint:{[xe]:"https://s3express-control-fips.{Region}.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",[Te]:_i,[Ae]:qe},[k]:ue},{[F]:Ch,endpoint:{[xe]:"https://s3express-control.dualstack.{Region}.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",[Te]:_i,[Ae]:qe},[k]:ue},{[F]:xh,endpoint:{[xe]:"https://s3express-control.{Region}.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",[Te]:_i,[Ae]:qe},[k]:ue}],[k]:se}],[k]:se}],[k]:se},{[F]:pW,[oe]:[{[F]:Fi,[oe]:[{[F]:dW,[oe]:[{[F]:hW,[oe]:Wo,[k]:se},{[F]:mW,[oe]:Wo,[k]:se},{[F]:gW,[oe]:Wo,[k]:se},{[F]:yW,[oe]:Wo,[k]:se},{[F]:_W,[oe]:Wo,[k]:se},v0],[k]:se},{[F]:hW,[oe]:Ko,[k]:se},{[F]:mW,[oe]:Ko,[k]:se},{[F]:gW,[oe]:Ko,[k]:se},{[F]:yW,[oe]:Ko,[k]:se},{[F]:_W,[oe]:Ko,[k]:se},v0],[k]:se}],[k]:se},BV],[k]:se},{[F]:[Sh,{[Z]:Ht,[ee]:bW,[We]:xV},{[Z]:mt,[ee]:[{[De]:xV},"--xa-s3"]}],[oe]:[MV,LV,{[F]:pW,[oe]:[{[F]:Fi,[oe]:[{[F]:dW,[oe]:[{[F]:EW,[oe]:Wo,[k]:se},{[F]:wW,[oe]:Wo,[k]:se},{[F]:SW,[oe]:Wo,[k]:se},{[F]:vW,[oe]:Wo,[k]:se},{[F]:CW,[oe]:Wo,[k]:se},v0],[k]:se},{[F]:EW,[oe]:Ko,[k]:se},{[F]:wW,[oe]:Ko,[k]:se},{[F]:SW,[oe]:Ko,[k]:se},{[F]:vW,[oe]:Ko,[k]:se},{[F]:CW,[oe]:Ko,[k]:se},v0],[k]:se}],[k]:se},BV],[k]:se},{[F]:[jV,FV,qV],[oe]:[{[F]:Fi,[oe]:[{[F]:bf,endpoint:{[xe]:A0,[Te]:_i,[Ae]:qe},[k]:ue},{[F]:iD,endpoint:{[xe]:"https://s3express-control-fips.dualstack.{Region}.{partitionResult#dnsSuffix}",[Te]:_i,[Ae]:qe},[k]:ue},{[F]:vh,endpoint:{[xe]:"https://s3express-control-fips.{Region}.{partitionResult#dnsSuffix}",[Te]:_i,[Ae]:qe},[k]:ue},{[F]:Ch,endpoint:{[xe]:"https://s3express-control.dualstack.{Region}.{partitionResult#dnsSuffix}",[Te]:_i,[Ae]:qe},[k]:ue},{[F]:xh,endpoint:{[xe]:"https://s3express-control.{Region}.{partitionResult#dnsSuffix}",[Te]:_i,[Ae]:qe},[k]:ue}],[k]:se}],[k]:se},{[F]:[Sh,{[Z]:Ht,[ee]:[dt,49,50,Vo],[We]:NW},{[Z]:Ht,[ee]:[dt,8,12,Vo],[We]:MW},{[Z]:Ht,[ee]:bW,[We]:TV},{[Z]:Ht,[ee]:[dt,32,49,Vo],[We]:lD},{[Z]:R0,[ee]:rD,[We]:"regionPartition"},{[Z]:mt,[ee]:[{[De]:TV},"--op-s3"]}],[oe]:[{[F]:xW,[oe]:[{[F]:[{[Z]:mt,[ee]:[UV,"e"]}],[oe]:[{[F]:TW,[oe]:[HV,{[F]:bf,endpoint:{[xe]:"https://{Bucket}.ec2.{url#authority}",[Te]:C0,[Ae]:qe},[k]:ue}],[k]:se},{endpoint:{[xe]:"https://{Bucket}.ec2.s3-outposts.{Region}.{regionPartition#dnsSuffix}",[Te]:C0,[Ae]:qe},[k]:ue}],[k]:se},{[F]:[{[Z]:mt,[ee]:[UV,"o"]}],[oe]:[{[F]:TW,[oe]:[HV,{[F]:bf,endpoint:{[xe]:"https://{Bucket}.op-{outpostId}.{url#authority}",[Te]:C0,[Ae]:qe},[k]:ue}],[k]:se},{endpoint:{[xe]:"https://{Bucket}.op-{outpostId}.s3-outposts.{Region}.{regionPartition#dnsSuffix}",[Te]:C0,[Ae]:qe},[k]:ue}],[k]:se},{error:'Unrecognized hardware type: "Expected hardware type o or e but got {hardwareType}"',[k]:Ie}],[k]:se},{error:"Invalid ARN: The outpost Id must only contain a-z, A-Z, 0-9 and `-`.",[k]:Ie}],[k]:se},{[F]:JPe,[oe]:[{[F]:[_r,{[Z]:Yo,[ee]:[{[Z]:bi,[ee]:[{[Z]:hD,[ee]:KPe}]}]}],error:"Custom endpoint `{Endpoint}` was not a valid URI",[k]:Ie},{[F]:[$I,VW],[oe]:[{[F]:Fi,[oe]:[{[F]:AW,[oe]:[{[F]:[qi,NV],error:"S3 Accelerate cannot be used in this region",[k]:Ie},{[F]:[qt,Wt,xr,ze,Nr],endpoint:{[xe]:"https://{Bucket}.s3-fips.dualstack.us-east-1.{partitionResult#dnsSuffix}",[Te]:Vr,[Ae]:qe},[k]:ue},{[F]:[qt,Wt,xr,ze,lt,Wr],[oe]:[{endpoint:$V,[k]:ue}],[k]:se},{[F]:[qt,Wt,xr,ze,lt,Kr],endpoint:$V,[k]:ue},{[F]:[ot,Wt,xr,ze,Nr],endpoint:{[xe]:"https://{Bucket}.s3-fips.us-east-1.{partitionResult#dnsSuffix}",[Te]:Vr,[Ae]:qe},[k]:ue},{[F]:[ot,Wt,xr,ze,lt,Wr],[oe]:[{endpoint:GV,[k]:ue}],[k]:se},{[F]:[ot,Wt,xr,ze,lt,Kr],endpoint:GV,[k]:ue},{[F]:[qt,Je,qi,ze,Nr],endpoint:{[xe]:"https://{Bucket}.s3-accelerate.dualstack.us-east-1.{partitionResult#dnsSuffix}",[Te]:Vr,[Ae]:qe},[k]:ue},{[F]:[qt,Je,qi,ze,lt,Wr],[oe]:[{endpoint:zV,[k]:ue}],[k]:se},{[F]:[qt,Je,qi,ze,lt,Kr],endpoint:zV,[k]:ue},{[F]:[qt,Je,xr,ze,Nr],endpoint:{[xe]:"https://{Bucket}.s3.dualstack.us-east-1.{partitionResult#dnsSuffix}",[Te]:Vr,[Ae]:qe},[k]:ue},{[F]:[qt,Je,xr,ze,lt,Wr],[oe]:[{endpoint:VV,[k]:ue}],[k]:se},{[F]:[qt,Je,xr,ze,lt,Kr],endpoint:VV,[k]:ue},{[F]:[ot,Je,xr,_r,Gn,HI,Nr],endpoint:{[xe]:LW,[Te]:Vr,[Ae]:qe},[k]:ue},{[F]:[ot,Je,xr,_r,Gn,GI,Nr],endpoint:{[xe]:O0,[Te]:Vr,[Ae]:qe},[k]:ue},{[F]:[ot,Je,xr,_r,Gn,HI,lt,Wr],[oe]:[{[F]:Va,endpoint:zI,[k]:ue},{endpoint:zI,[k]:ue}],[k]:se},{[F]:[ot,Je,xr,_r,Gn,GI,lt,Wr],[oe]:[{[F]:Va,endpoint:fD,[k]:ue},WV],[k]:se},{[F]:[ot,Je,xr,_r,Gn,HI,lt,Kr],endpoint:zI,[k]:ue},{[F]:[ot,Je,xr,_r,Gn,GI,lt,Kr],endpoint:fD,[k]:ue},{[F]:[ot,Je,qi,ze,Nr],endpoint:{[xe]:BW,[Te]:Vr,[Ae]:qe},[k]:ue},{[F]:[ot,Je,qi,ze,lt,Wr],[oe]:[{[F]:Va,endpoint:VI,[k]:ue},{endpoint:VI,[k]:ue}],[k]:se},{[F]:[ot,Je,qi,ze,lt,Kr],endpoint:VI,[k]:ue},{[F]:[ot,Je,xr,ze,Nr],endpoint:{[xe]:AV,[Te]:Vr,[Ae]:qe},[k]:ue},{[F]:[ot,Je,xr,ze,lt,Wr],[oe]:[{[F]:Va,endpoint:{[xe]:AV,[Te]:Rr,[Ae]:qe},[k]:ue},{endpoint:KV,[k]:ue}],[k]:se},{[F]:[ot,Je,xr,ze,lt,Kr],endpoint:KV,[k]:ue}],[k]:se},x0],[k]:se}],[k]:se},{[F]:[_r,Gn,{[Z]:mt,[ee]:[{[Z]:cr,[ee]:[GW,"scheme"]},"http"]},{[Z]:P0,[ee]:[dt,Vo]},$I,Je,ot,xr],[oe]:[{[F]:Fi,[oe]:[{[F]:AW,[oe]:[WV],[k]:se},x0],[k]:se}],[k]:se},{[F]:[$I,{[Z]:FW,[ee]:YPe,[We]:qW}],[oe]:[{[F]:[{[Z]:cr,[ee]:[ai,"resourceId[0]"],[We]:jW},{[Z]:Yo,[ee]:[{[Z]:mt,[ee]:[WW,I0]}]}],[oe]:[{[F]:[{[Z]:mt,[ee]:[WI,gD]}],[oe]:[{[F]:oD,[oe]:[{[F]:RW,[oe]:[YV,XV,{[F]:sD,[oe]:[JV,{[F]:OW,[oe]:[KI,{[F]:aD,[oe]:[{[F]:Fi,[oe]:[{[F]:IW,[oe]:[{[F]:cD,[oe]:[{[F]:[{[Z]:mt,[ee]:[YW,I0]}],error:"Invalid ARN: Missing account id",[k]:Ie},{[F]:uD,[oe]:[{[F]:DW,[oe]:[{[F]:bf,endpoint:{[xe]:RV,[Te]:YI,[Ae]:qe},[k]:ue},{[F]:T0,endpoint:{[xe]:"https://{accessPointName}-{bucketArn#accountId}.s3-object-lambda-fips.{bucketArn#region}.{bucketPartition#dnsSuffix}",[Te]:YI,[Ae]:qe},[k]:ue},{endpoint:{[xe]:"https://{accessPointName}-{bucketArn#accountId}.s3-object-lambda.{bucketArn#region}.{bucketPartition#dnsSuffix}",[Te]:YI,[Ae]:qe},[k]:ue}],[k]:se},QV],[k]:se},XI],[k]:se},JI],[k]:se},QI],[k]:se}],[k]:se}],[k]:se},ZV],[k]:se},{error:"Invalid ARN: bucket ARN is missing a region",[k]:Ie}],[k]:se},eW],[k]:se},{error:"Invalid ARN: Object Lambda ARNs only support `accesspoint` arn types, but found: `{arnType}`",[k]:Ie}],[k]:se},{[F]:oD,[oe]:[{[F]:RW,[oe]:[{[F]:sD,[oe]:[{[F]:oD,[oe]:[{[F]:sD,[oe]:[JV,{[F]:OW,[oe]:[KI,{[F]:aD,[oe]:[{[F]:Fi,[oe]:[{[F]:[{[Z]:mt,[ee]:[KW,"{partitionResult#name}"]}],[oe]:[{[F]:cD,[oe]:[{[F]:[{[Z]:mt,[ee]:[WI,Ef]}],[oe]:[{[F]:uD,[oe]:[{[F]:DW,[oe]:[{[F]:nD,error:"Access Points do not support S3 Accelerate",[k]:Ie},{[F]:iD,endpoint:{[xe]:"https://{accessPointName}-{bucketArn#accountId}.s3-accesspoint-fips.dualstack.{bucketArn#region}.{bucketPartition#dnsSuffix}",[Te]:wh,[Ae]:qe},[k]:ue},{[F]:vh,endpoint:{[xe]:"https://{accessPointName}-{bucketArn#accountId}.s3-accesspoint-fips.{bucketArn#region}.{bucketPartition#dnsSuffix}",[Te]:wh,[Ae]:qe},[k]:ue},{[F]:Ch,endpoint:{[xe]:"https://{accessPointName}-{bucketArn#accountId}.s3-accesspoint.dualstack.{bucketArn#region}.{bucketPartition#dnsSuffix}",[Te]:wh,[Ae]:qe},[k]:ue},{[F]:[Je,ot,_r,Gn],endpoint:{[xe]:RV,[Te]:wh,[Ae]:qe},[k]:ue},{[F]:xh,endpoint:{[xe]:"https://{accessPointName}-{bucketArn#accountId}.s3-accesspoint.{bucketArn#region}.{bucketPartition#dnsSuffix}",[Te]:wh,[Ae]:qe},[k]:ue}],[k]:se},QV],[k]:se},XI],[k]:se},{error:"Invalid ARN: The ARN was not for the S3 service, found: {bucketArn#service}",[k]:Ie}],[k]:se},JI],[k]:se},QI],[k]:se}],[k]:se}],[k]:se},ZV],[k]:se}],[k]:se}],[k]:se},{[F]:[{[Z]:mu,[ee]:[_D,Vo]}],[oe]:[{[F]:PW,error:"S3 MRAP does not support dual-stack",[k]:Ie},{[F]:T0,error:"S3 MRAP does not support FIPS",[k]:Ie},{[F]:nD,error:"S3 MRAP does not support S3 Accelerate",[k]:Ie},{[F]:[{[Z]:br,[ee]:[{[De]:"DisableMultiRegionAccessPoints"},Vo]}],error:"Invalid configuration: Multi-Region Access Point ARNs are disabled.",[k]:Ie},{[F]:[{[Z]:R0,[ee]:rD,[We]:PV}],[oe]:[{[F]:[{[Z]:mt,[ee]:[{[Z]:cr,[ee]:[{[De]:PV},ur]},{[Z]:cr,[ee]:[ai,"partition"]}]}],[oe]:[{endpoint:{[xe]:"https://{accessPointName}.accesspoint.s3-global.{mrapPartition#dnsSuffix}",[Te]:{[Yr]:[{[Tr]:Vo,name:mD,[Ar]:Ef,[pD]:QPe}]},[Ae]:qe},[k]:ue}],[k]:se},{error:"Client was configured for partition `{mrapPartition#name}` but bucket referred to partition `{bucketArn#partition}`",[k]:Ie}],[k]:se}],[k]:se},{error:"Invalid Access Point Name",[k]:Ie}],[k]:se},eW],[k]:se},{[F]:[{[Z]:mt,[ee]:[WI,Th]}],[oe]:[{[F]:PW,error:"S3 Outposts does not support Dual-stack",[k]:Ie},{[F]:T0,error:"S3 Outposts does not support FIPS",[k]:Ie},{[F]:nD,error:"S3 Outposts does not support S3 Accelerate",[k]:Ie},{[F]:[{[Z]:bi,[ee]:[{[Z]:cr,[ee]:[ai,"resourceId[4]"]}]}],error:"Invalid Arn: Outpost Access Point ARN contains sub resources",[k]:Ie},{[F]:[{[Z]:cr,[ee]:ZPe,[We]:lD}],[oe]:[{[F]:xW,[oe]:[KI,{[F]:aD,[oe]:[{[F]:Fi,[oe]:[{[F]:IW,[oe]:[{[F]:cD,[oe]:[{[F]:uD,[oe]:[{[F]:[{[Z]:cr,[ee]:eOe,[We]:OV}],[oe]:[{[F]:[{[Z]:cr,[ee]:[ai,"resourceId[3]"],[We]:yD}],[oe]:[{[F]:[{[Z]:mt,[ee]:[{[De]:OV},UW]}],[oe]:[{[F]:bf,endpoint:{[xe]:"https://{accessPointName}-{bucketArn#accountId}.{outpostId}.{url#authority}",[Te]:tW,[Ae]:qe},[k]:ue},{endpoint:{[xe]:"https://{accessPointName}-{bucketArn#accountId}.{outpostId}.s3-outposts.{bucketArn#region}.{bucketPartition#dnsSuffix}",[Te]:tW,[Ae]:qe},[k]:ue}],[k]:se},{error:"Expected an outpost type `accesspoint`, found {outpostType}",[k]:Ie}],[k]:se},{error:"Invalid ARN: expected an access point name",[k]:Ie}],[k]:se},{error:"Invalid ARN: Expected a 4-component resource",[k]:Ie}],[k]:se},XI],[k]:se},JI],[k]:se},QI],[k]:se}],[k]:se}],[k]:se},{error:"Invalid ARN: The outpost Id may only contain a-z, A-Z, 0-9 and `-`. Found: `{outpostId}`",[k]:Ie}],[k]:se},{error:"Invalid ARN: The Outpost Id was not set",[k]:Ie}],[k]:se},{error:"Invalid ARN: Unrecognized format: {Bucket} (type: {arnType})",[k]:Ie}],[k]:se},{error:"Invalid ARN: No ARN type specified",[k]:Ie}],[k]:se},{[F]:[{[Z]:Ht,[ee]:[dt,0,4,VPe],[We]:IV},{[Z]:mt,[ee]:[{[De]:IV},"arn:"]},{[Z]:Yo,[ee]:[{[Z]:bi,[ee]:[rW]}]}],error:"Invalid ARN: `{Bucket}` was not a valid ARN",[k]:Ie},{[F]:[{[Z]:br,[ee]:[WPe,Vo]},rW],error:"Path-style addressing cannot be used with ARN buckets",[k]:Ie},{[F]:XPe,[oe]:[{[F]:Fi,[oe]:[{[F]:[xr],[oe]:[{[F]:[qt,ze,Wt,Nr],endpoint:{[xe]:"https://s3-fips.dualstack.us-east-1.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",[Te]:Vr,[Ae]:qe},[k]:ue},{[F]:[qt,ze,Wt,lt,Wr],[oe]:[{endpoint:nW,[k]:ue}],[k]:se},{[F]:[qt,ze,Wt,lt,Kr],endpoint:nW,[k]:ue},{[F]:[ot,ze,Wt,Nr],endpoint:{[xe]:"https://s3-fips.us-east-1.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",[Te]:Vr,[Ae]:qe},[k]:ue},{[F]:[ot,ze,Wt,lt,Wr],[oe]:[{endpoint:iW,[k]:ue}],[k]:se},{[F]:[ot,ze,Wt,lt,Kr],endpoint:iW,[k]:ue},{[F]:[qt,ze,Je,Nr],endpoint:{[xe]:"https://s3.dualstack.us-east-1.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",[Te]:Vr,[Ae]:qe},[k]:ue},{[F]:[qt,ze,Je,lt,Wr],[oe]:[{endpoint:oW,[k]:ue}],[k]:se},{[F]:[qt,ze,Je,lt,Kr],endpoint:oW,[k]:ue},{[F]:[ot,_r,Gn,Je,Nr],endpoint:{[xe]:HW,[Te]:Vr,[Ae]:qe},[k]:ue},{[F]:[ot,_r,Gn,Je,lt,Wr],[oe]:[{[F]:Va,endpoint:ZI,[k]:ue},{endpoint:ZI,[k]:ue}],[k]:se},{[F]:[ot,_r,Gn,Je,lt,Kr],endpoint:ZI,[k]:ue},{[F]:[ot,ze,Je,Nr],endpoint:{[xe]:DV,[Te]:Vr,[Ae]:qe},[k]:ue},{[F]:[ot,ze,Je,lt,Wr],[oe]:[{[F]:Va,endpoint:{[xe]:DV,[Te]:Rr,[Ae]:qe},[k]:ue},{endpoint:sW,[k]:ue}],[k]:se},{[F]:[ot,ze,Je,lt,Kr],endpoint:sW,[k]:ue}],[k]:se},{error:"Path-style addressing cannot be used with S3 Accelerate",[k]:Ie}],[k]:se}],[k]:se}],[k]:se},{[F]:[{[Z]:bi,[ee]:[aW]},{[Z]:br,[ee]:[aW,Vo]}],[oe]:[{[F]:Fi,[oe]:[{[F]:kW,[oe]:[YV,XV,{[F]:bf,endpoint:{[xe]:A0,[Te]:eD,[Ae]:qe},[k]:ue},{[F]:T0,endpoint:{[xe]:"https://s3-object-lambda-fips.{Region}.{partitionResult#dnsSuffix}",[Te]:eD,[Ae]:qe},[k]:ue},{endpoint:{[xe]:"https://s3-object-lambda.{Region}.{partitionResult#dnsSuffix}",[Te]:eD,[Ae]:qe},[k]:ue}],[k]:se},x0],[k]:se}],[k]:se},{[F]:[jV],[oe]:[{[F]:Fi,[oe]:[{[F]:kW,[oe]:[{[F]:[Wt,qt,ze,Nr],endpoint:{[xe]:"https://s3-fips.dualstack.us-east-1.{partitionResult#dnsSuffix}",[Te]:Vr,[Ae]:qe},[k]:ue},{[F]:[Wt,qt,ze,lt,Wr],[oe]:[{endpoint:cW,[k]:ue}],[k]:se},{[F]:[Wt,qt,ze,lt,Kr],endpoint:cW,[k]:ue},{[F]:[Wt,ot,ze,Nr],endpoint:{[xe]:"https://s3-fips.us-east-1.{partitionResult#dnsSuffix}",[Te]:Vr,[Ae]:qe},[k]:ue},{[F]:[Wt,ot,ze,lt,Wr],[oe]:[{endpoint:uW,[k]:ue}],[k]:se},{[F]:[Wt,ot,ze,lt,Kr],endpoint:uW,[k]:ue},{[F]:[Je,qt,ze,Nr],endpoint:{[xe]:"https://s3.dualstack.us-east-1.{partitionResult#dnsSuffix}",[Te]:Vr,[Ae]:qe},[k]:ue},{[F]:[Je,qt,ze,lt,Wr],[oe]:[{endpoint:lW,[k]:ue}],[k]:se},{[F]:[Je,qt,ze,lt,Kr],endpoint:lW,[k]:ue},{[F]:[Je,ot,_r,Gn,Nr],endpoint:{[xe]:A0,[Te]:Vr,[Ae]:qe},[k]:ue},{[F]:[Je,ot,_r,Gn,lt,Wr],[oe]:[{[F]:Va,endpoint:tD,[k]:ue},{endpoint:tD,[k]:ue}],[k]:se},{[F]:[Je,ot,_r,Gn,lt,Kr],endpoint:tD,[k]:ue},{[F]:[Je,ot,ze,Nr],endpoint:{[xe]:kV,[Te]:Vr,[Ae]:qe},[k]:ue},{[F]:[Je,ot,ze,lt,Wr],[oe]:[{[F]:Va,endpoint:{[xe]:kV,[Te]:Rr,[Ae]:qe},[k]:ue},{endpoint:fW,[k]:ue}],[k]:se},{[F]:[Je,ot,ze,lt,Kr],endpoint:fW,[k]:ue}],[k]:se},x0],[k]:se}],[k]:se}],[k]:se},{error:"A region must be set when sending requests to S3.",[k]:Ie}]};D0.ruleSet=tOe});var ED=E(k0=>{"use strict";Object.defineProperty(k0,"__esModule",{value:!0});k0.defaultEndpointResolver=void 0;var rOe=fu(),bD=Ua(),nOe=XW(),iOe=new bD.EndpointCache({size:50,params:["Accelerate","Bucket","DisableAccessPoints","DisableMultiRegionAccessPoints","DisableS3ExpressSessionAuth","Endpoint","ForcePathStyle","Region","UseArnRegion","UseDualStack","UseFIPS","UseGlobalEndpoint","UseObjectLambdaEndpoint","UseS3ExpressControlEndpoint"]}),oOe=(e,t={})=>iOe.get(e,()=>(0,bD.resolveEndpoint)(nOe.ruleSet,{endpointParams:e,logger:t.logger}));k0.defaultEndpointResolver=oOe;bD.customEndpointFunctions.aws=rOe.awsEndpointFunctions});var wD=E(Wa=>{"use strict";Object.defineProperty(Wa,"__esModule",{value:!0});Wa.resolveHttpAuthSchemeConfig=Wa.defaultS3HttpAuthSchemeProvider=Wa.defaultS3HttpAuthSchemeParametersProvider=void 0;var JW=(Dr(),Ve(Uo)),sOe=UI(),aOe=ao(),N0=an(),cOe=ED(),uOe=e=>async(t,r,n)=>{if(!n)throw new Error("Could not find `input` for `defaultEndpointRuleSetHttpAuthSchemeParametersProvider`");let i=await e(t,r,n),o=(0,N0.getSmithyContext)(r)?.commandInstance?.constructor?.getEndpointParameterInstructions;if(!o)throw new Error(`getEndpointParameterInstructions() is not defined on \`${r.commandName}\``);let s=await(0,aOe.resolveParams)(n,{getEndpointParameterInstructions:o},t);return Object.assign(i,s)},lOe=async(e,t,r)=>({operation:(0,N0.getSmithyContext)(t).operation,region:await(0,N0.normalizeProvider)(e.region)()||(()=>{throw new Error("expected `region` to be configured for `aws.auth#sigv4`")})()});Wa.defaultS3HttpAuthSchemeParametersProvider=uOe(lOe);function QW(e){return{schemeId:"aws.auth#sigv4",signingProperties:{name:"s3",region:e.region},propertiesExtractor:(t,r)=>({signingProperties:{config:t,context:r}})}}function ZW(e){return{schemeId:"aws.auth#sigv4a",signingProperties:{name:"s3",region:e.region},propertiesExtractor:(t,r)=>({signingProperties:{config:t,context:r}})}}var fOe=(e,t,r)=>i=>{let s=e(i).properties?.authSchemes;if(!s)return t(i);let a=[];for(let c of s){let{name:u,properties:l={},...d}=c,h=u.toLowerCase();u!==h&&console.warn(`HttpAuthScheme has been normalized with lowercasing: \`${u}\` to \`${h}\``);let f;if(h==="sigv4a"){f="aws.auth#sigv4a";let _=s.find(w=>{let R=w.name.toLowerCase();return R!=="sigv4a"&&R.startsWith("sigv4")});if(sOe.SignatureV4MultiRegion.sigv4aDependency()==="none"&&_)continue}else if(h.startsWith("sigv4"))f="aws.auth#sigv4";else throw new Error(`Unknown HttpAuthScheme found in \`@smithy.rules#endpointRuleSet\`: \`${h}\``);let p=r[f];if(!p)throw new Error(`Could not find HttpAuthOption create function for \`${f}\``);let m=p(i);m.schemeId=f,m.signingProperties={...m.signingProperties||{},...d,...l},a.push(m)}return a},dOe=e=>{let t=[];switch(e.operation){default:t.push(QW(e)),t.push(ZW(e))}return t};Wa.defaultS3HttpAuthSchemeProvider=fOe(cOe.defaultEndpointResolver,dOe,{"aws.auth#sigv4":QW,"aws.auth#sigv4a":ZW});var pOe=e=>{let t=(0,JW.resolveAwsSdkSigV4Config)(e),r=(0,JW.resolveAwsSdkSigV4AConfig)(t);return Object.assign(r,{authSchemePreference:(0,N0.normalizeProvider)(e.authSchemePreference??[])})};Wa.resolveHttpAuthSchemeConfig=pOe});var e9=E((l0t,hOe)=>{hOe.exports={name:"@aws-sdk/client-s3",description:"AWS SDK for JavaScript S3 Client for Node.js, Browser and React Native",version:"3.943.0",scripts:{build:"concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'","build:cjs":"node ../../scripts/compilation/inline client-s3","build:es":"tsc -p tsconfig.es.json","build:include:deps":"lerna run --scope $npm_package_name --include-dependencies build","build:types":"tsc -p tsconfig.types.json","build:types:downlevel":"downlevel-dts dist-types dist-types/ts3.4",clean:"rimraf ./dist-* && rimraf *.tsbuildinfo","extract:docs":"api-extractor run --local","generate:client":"node ../../scripts/generate-clients/single-service --solo s3",test:"yarn g:vitest run","test:browser":"node ./test/browser-build/esbuild && yarn g:vitest run -c vitest.config.browser.mts","test:browser:watch":"node ./test/browser-build/esbuild && yarn g:vitest watch -c vitest.config.browser.mts","test:e2e":"yarn g:vitest run -c vitest.config.e2e.mts && yarn test:browser","test:e2e:watch":"yarn g:vitest watch -c vitest.config.e2e.mts","test:integration":"yarn g:vitest run -c vitest.config.integ.mts","test:integration:watch":"yarn g:vitest watch -c vitest.config.integ.mts","test:watch":"yarn g:vitest watch"},main:"./dist-cjs/index.js",types:"./dist-types/index.d.ts",module:"./dist-es/index.js",sideEffects:!1,dependencies:{"@aws-crypto/sha1-browser":"5.2.0","@aws-crypto/sha256-browser":"5.2.0","@aws-crypto/sha256-js":"5.2.0","@aws-sdk/core":"3.943.0","@aws-sdk/credential-provider-node":"3.943.0","@aws-sdk/middleware-bucket-endpoint":"3.936.0","@aws-sdk/middleware-expect-continue":"3.936.0","@aws-sdk/middleware-flexible-checksums":"3.943.0","@aws-sdk/middleware-host-header":"3.936.0","@aws-sdk/middleware-location-constraint":"3.936.0","@aws-sdk/middleware-logger":"3.936.0","@aws-sdk/middleware-recursion-detection":"3.936.0","@aws-sdk/middleware-sdk-s3":"3.943.0","@aws-sdk/middleware-ssec":"3.936.0","@aws-sdk/middleware-user-agent":"3.943.0","@aws-sdk/region-config-resolver":"3.936.0","@aws-sdk/signature-v4-multi-region":"3.943.0","@aws-sdk/types":"3.936.0","@aws-sdk/util-endpoints":"3.936.0","@aws-sdk/util-user-agent-browser":"3.936.0","@aws-sdk/util-user-agent-node":"3.943.0","@smithy/config-resolver":"^4.4.3","@smithy/core":"^3.18.5","@smithy/eventstream-serde-browser":"^4.2.5","@smithy/eventstream-serde-config-resolver":"^4.3.5","@smithy/eventstream-serde-node":"^4.2.5","@smithy/fetch-http-handler":"^5.3.6","@smithy/hash-blob-browser":"^4.2.6","@smithy/hash-node":"^4.2.5","@smithy/hash-stream-node":"^4.2.5","@smithy/invalid-dependency":"^4.2.5","@smithy/md5-js":"^4.2.5","@smithy/middleware-content-length":"^4.2.5","@smithy/middleware-endpoint":"^4.3.12","@smithy/middleware-retry":"^4.4.12","@smithy/middleware-serde":"^4.2.6","@smithy/middleware-stack":"^4.2.5","@smithy/node-config-provider":"^4.3.5","@smithy/node-http-handler":"^4.4.5","@smithy/protocol-http":"^5.3.5","@smithy/smithy-client":"^4.9.8","@smithy/types":"^4.9.0","@smithy/url-parser":"^4.2.5","@smithy/util-base64":"^4.3.0","@smithy/util-body-length-browser":"^4.2.0","@smithy/util-body-length-node":"^4.2.1","@smithy/util-defaults-mode-browser":"^4.3.11","@smithy/util-defaults-mode-node":"^4.2.14","@smithy/util-endpoints":"^3.2.5","@smithy/util-middleware":"^4.2.5","@smithy/util-retry":"^4.2.5","@smithy/util-stream":"^4.5.6","@smithy/util-utf8":"^4.2.0","@smithy/util-waiter":"^4.2.5",tslib:"^2.6.2"},devDependencies:{"@aws-sdk/signature-v4-crt":"3.943.0","@tsconfig/node18":"18.2.4","@types/node":"^18.19.69",concurrently:"7.0.0","downlevel-dts":"0.10.1",rimraf:"3.0.2",typescript:"~5.8.3"},engines:{node:">=18.0.0"},typesVersions:{"<4.0":{"dist-types/*":["dist-types/ts3.4/*"]}},files:["dist-*/**"],author:{name:"AWS SDK for JavaScript Team",url:"https://aws.amazon.com/javascript/"},license:"Apache-2.0",browser:{"./dist-es/runtimeConfig":"./dist-es/runtimeConfig.browser"},"react-native":{"./dist-es/runtimeConfig":"./dist-es/runtimeConfig.native"},homepage:"https://github.com/aws/aws-sdk-js-v3/tree/main/clients/client-s3",repository:{type:"git",url:"https://github.com/aws/aws-sdk-js-v3.git",directory:"clients/client-s3"}}});var SD=E(Ka=>{"use strict";var mOe=(ki(),Ve(xs)),gOe=Sn(),t9="AWS_ACCESS_KEY_ID",r9="AWS_SECRET_ACCESS_KEY",n9="AWS_SESSION_TOKEN",i9="AWS_CREDENTIAL_EXPIRATION",o9="AWS_CREDENTIAL_SCOPE",s9="AWS_ACCOUNT_ID",yOe=e=>async()=>{e?.logger?.debug("@aws-sdk/credential-provider-env - fromEnv");let t=process.env[t9],r=process.env[r9],n=process.env[n9],i=process.env[i9],o=process.env[o9],s=process.env[s9];if(t&&r){let a={accessKeyId:t,secretAccessKey:r,...n&&{sessionToken:n},...i&&{expiration:new Date(i)},...o&&{credentialScope:o},...s&&{accountId:s}};return mOe.setCredentialFeature(a,"CREDENTIALS_ENV_VARS","g"),a}throw new gOe.CredentialsProviderError("Unable to find environment variable credentials.",{logger:e?.logger})};Ka.ENV_ACCOUNT_ID=s9;Ka.ENV_CREDENTIAL_SCOPE=o9;Ka.ENV_EXPIRATION=i9;Ka.ENV_KEY=t9;Ka.ENV_SECRET=r9;Ka.ENV_SESSION=n9;Ka.fromEnv=yOe});var Rh=E(xn=>{"use strict";var Xo=Sn(),_Oe=require("url"),bOe=require("buffer"),EOe=require("http"),AD=zo(),wOe=qs();function Ah(e){return new Promise((t,r)=>{let n=EOe.request({method:"GET",...e,hostname:e.hostname?.replace(/^\[(.+)\]$/,"$1")});n.on("error",i=>{r(Object.assign(new Xo.ProviderError("Unable to connect to instance metadata service"),i)),n.destroy()}),n.on("timeout",()=>{r(new Xo.ProviderError("TimeoutError from instance metadata service")),n.destroy()}),n.on("response",i=>{let{statusCode:o=400}=i;(o<200||300<=o)&&(r(Object.assign(new Xo.ProviderError("Error response received from instance metadata service"),{statusCode:o})),n.destroy());let s=[];i.on("data",a=>{s.push(a)}),i.on("end",()=>{t(bOe.Buffer.concat(s)),n.destroy()})}),n.end()})}var l9=e=>!!e&&typeof e=="object"&&typeof e.AccessKeyId=="string"&&typeof e.SecretAccessKey=="string"&&typeof e.Token=="string"&&typeof e.Expiration=="string",f9=e=>({accessKeyId:e.AccessKeyId,secretAccessKey:e.SecretAccessKey,sessionToken:e.Token,expiration:new Date(e.Expiration),...e.AccountId&&{accountId:e.AccountId}}),d9=1e3,p9=0,RD=({maxRetries:e=p9,timeout:t=d9})=>({maxRetries:e,timeout:t}),CD=(e,t)=>{let r=e();for(let n=0;n<t;n++)r=r.catch(e);return r},M0="AWS_CONTAINER_CREDENTIALS_FULL_URI",L0="AWS_CONTAINER_CREDENTIALS_RELATIVE_URI",xD="AWS_CONTAINER_AUTHORIZATION_TOKEN",SOe=(e={})=>{let{timeout:t,maxRetries:r}=RD(e);return()=>CD(async()=>{let n=await AOe({logger:e.logger}),i=JSON.parse(await vOe(t,n));if(!l9(i))throw new Xo.CredentialsProviderError("Invalid response received from instance metadata service.",{logger:e.logger});return f9(i)},r)},vOe=async(e,t)=>(process.env[xD]&&(t.headers={...t.headers,Authorization:process.env[xD]}),(await Ah({...t,timeout:e})).toString()),COe="169.254.170.2",xOe={localhost:!0,"127.0.0.1":!0},TOe={"http:":!0,"https:":!0},AOe=async({logger:e})=>{if(process.env[L0])return{hostname:COe,path:process.env[L0]};if(process.env[M0]){let t=_Oe.parse(process.env[M0]);if(!t.hostname||!(t.hostname in xOe))throw new Xo.CredentialsProviderError(`${t.hostname} is not a valid container metadata service hostname`,{tryNextLink:!1,logger:e});if(!t.protocol||!(t.protocol in TOe))throw new Xo.CredentialsProviderError(`${t.protocol} is not a valid container metadata service protocol`,{tryNextLink:!1,logger:e});return{...t,port:t.port?parseInt(t.port,10):void 0}}throw new Xo.CredentialsProviderError(`The container metadata credential provider cannot be used unless the ${L0} or ${M0} environment variable is set`,{tryNextLink:!1,logger:e})},TD=class e extends Xo.CredentialsProviderError{tryNextLink;name="InstanceMetadataV1FallbackError";constructor(t,r=!0){super(t,r),this.tryNextLink=r,Object.setPrototypeOf(this,e.prototype)}};xn.Endpoint=void 0;(function(e){e.IPv4="http://169.254.169.254",e.IPv6="http://[fd00:ec2::254]"})(xn.Endpoint||(xn.Endpoint={}));var ROe="AWS_EC2_METADATA_SERVICE_ENDPOINT",POe="ec2_metadata_service_endpoint",OOe={environmentVariableSelector:e=>e[ROe],configFileSelector:e=>e[POe],default:void 0},wf;(function(e){e.IPv4="IPv4",e.IPv6="IPv6"})(wf||(wf={}));var IOe="AWS_EC2_METADATA_SERVICE_ENDPOINT_MODE",DOe="ec2_metadata_service_endpoint_mode",kOe={environmentVariableSelector:e=>e[IOe],configFileSelector:e=>e[DOe],default:wf.IPv4},h9=async()=>wOe.parseUrl(await NOe()||await MOe()),NOe=async()=>AD.loadConfig(OOe)(),MOe=async()=>{let e=await AD.loadConfig(kOe)();switch(e){case wf.IPv4:return xn.Endpoint.IPv4;case wf.IPv6:return xn.Endpoint.IPv6;default:throw new Error(`Unsupported endpoint mode: ${e}. Select from ${Object.values(wf)}`)}},LOe=300,BOe=300,FOe="https://docs.aws.amazon.com/sdkref/latest/guide/feature-static-credentials.html",a9=(e,t)=>{let r=LOe+Math.floor(Math.random()*BOe),n=new Date(Date.now()+r*1e3);t.warn(`Attempting credential expiration extension due to a credential service availability issue. A refresh of these credentials will be attempted after ${new Date(n)}.
|
|
228
|
+
For more information, please visit: `+FOe);let i=e.originalExpiration??e.expiration;return{...e,...i?{originalExpiration:i}:{},expiration:n}},qOe=(e,t={})=>{let r=t?.logger||console,n;return async()=>{let i;try{i=await e(),i.expiration&&i.expiration.getTime()<Date.now()&&(i=a9(i,r))}catch(o){if(n)r.warn("Credential renew failed: ",o),i=a9(n,r);else throw o}return n=i,i}},m9="/latest/meta-data/iam/security-credentials/",jOe="/latest/api/token",vD="AWS_EC2_METADATA_V1_DISABLED",c9="ec2_metadata_v1_disabled",u9="x-aws-ec2-metadata-token",UOe=(e={})=>qOe(HOe(e),{logger:e.logger}),HOe=(e={})=>{let t=!1,{logger:r,profile:n}=e,{timeout:i,maxRetries:o}=RD(e),s=async(a,c)=>{if(t||c.headers?.[u9]==null){let d=!1,h=!1,f=await AD.loadConfig({environmentVariableSelector:p=>{let m=p[vD];if(h=!!m&&m!=="false",m===void 0)throw new Xo.CredentialsProviderError(`${vD} not set in env, checking config file next.`,{logger:e.logger});return h},configFileSelector:p=>{let m=p[c9];return d=!!m&&m!=="false",d},default:!1},{profile:n})();if(e.ec2MetadataV1Disabled||f){let p=[];throw e.ec2MetadataV1Disabled&&p.push("credential provider initialization (runtime option ec2MetadataV1Disabled)"),d&&p.push(`config file profile (${c9})`),h&&p.push(`process environment variable (${vD})`),new TD(`AWS EC2 Metadata v1 fallback has been blocked by AWS SDK configuration in the following: [${p.join(", ")}].`)}}let l=(await CD(async()=>{let d;try{d=await GOe(c)}catch(h){throw h.statusCode===401&&(t=!1),h}return d},a)).trim();return CD(async()=>{let d;try{d=await zOe(l,c,e)}catch(h){throw h.statusCode===401&&(t=!1),h}return d},a)};return async()=>{let a=await h9();if(t)return r?.debug("AWS SDK Instance Metadata","using v1 fallback (no token fetch)"),s(o,{...a,timeout:i});{let c;try{c=(await $Oe({...a,timeout:i})).toString()}catch(u){if(u?.statusCode===400)throw Object.assign(u,{message:"EC2 Metadata token request returned error"});return(u.message==="TimeoutError"||[403,404,405].includes(u.statusCode))&&(t=!0),r?.debug("AWS SDK Instance Metadata","using v1 fallback (initial)"),s(o,{...a,timeout:i})}return s(o,{...a,headers:{[u9]:c},timeout:i})}}},$Oe=async e=>Ah({...e,path:jOe,method:"PUT",headers:{"x-aws-ec2-metadata-token-ttl-seconds":"21600"}}),GOe=async e=>(await Ah({...e,path:m9})).toString(),zOe=async(e,t,r)=>{let n=JSON.parse((await Ah({...t,path:m9+e})).toString());if(!l9(n))throw new Xo.CredentialsProviderError("Invalid response received from instance metadata service.",{logger:r.logger});return f9(n)};xn.DEFAULT_MAX_RETRIES=p9;xn.DEFAULT_TIMEOUT=d9;xn.ENV_CMDS_AUTH_TOKEN=xD;xn.ENV_CMDS_FULL_URI=M0;xn.ENV_CMDS_RELATIVE_URI=L0;xn.fromContainerMetadata=SOe;xn.fromInstanceMetadata=UOe;xn.getInstanceMetadataEndpoint=h9;xn.httpRequest=Ah;xn.providerConfigFromInit=RD});var g9=E(B0=>{"use strict";Object.defineProperty(B0,"__esModule",{value:!0});B0.checkUrl=void 0;var VOe=Sn(),WOe="169.254.170.2",KOe="169.254.170.23",YOe="[fd00:ec2::23]",XOe=(e,t)=>{if(e.protocol!=="https:"&&!(e.hostname===WOe||e.hostname===KOe||e.hostname===YOe)){if(e.hostname.includes("[")){if(e.hostname==="[::1]"||e.hostname==="[0000:0000:0000:0000:0000:0000:0000:0001]")return}else{if(e.hostname==="localhost")return;let r=e.hostname.split("."),n=i=>{let o=parseInt(i,10);return 0<=o&&o<=255};if(r[0]==="127"&&n(r[1])&&n(r[2])&&n(r[3])&&r.length===4)return}throw new VOe.CredentialsProviderError(`URL not accepted. It must either be HTTPS or match one of the following:
|
|
229
|
+
- loopback CIDR 127.0.0.0/8 or [::1/128]
|
|
230
|
+
- ECS container host 169.254.170.2
|
|
231
|
+
- EKS container host 169.254.170.23 or [fd00:ec2::23]`,{logger:t})}};B0.checkUrl=XOe});var y9=E(F0=>{"use strict";Object.defineProperty(F0,"__esModule",{value:!0});F0.createGetRequest=eIe;F0.getCredentials=tIe;var PD=Sn(),JOe=St(),QOe=Ge(),ZOe=Jc();function eIe(e){return new JOe.HttpRequest({protocol:e.protocol,hostname:e.hostname,port:Number(e.port),path:e.pathname,query:Array.from(e.searchParams.entries()).reduce((t,[r,n])=>(t[r]=n,t),{}),fragment:e.hash})}async function tIe(e,t){let n=await(0,ZOe.sdkStreamMixin)(e.body).transformToString();if(e.statusCode===200){let i=JSON.parse(n);if(typeof i.AccessKeyId!="string"||typeof i.SecretAccessKey!="string"||typeof i.Token!="string"||typeof i.Expiration!="string")throw new PD.CredentialsProviderError("HTTP credential provider response not of the required format, an object matching: { AccessKeyId: string, SecretAccessKey: string, Token: string, Expiration: string(rfc3339) }",{logger:t});return{accessKeyId:i.AccessKeyId,secretAccessKey:i.SecretAccessKey,sessionToken:i.Token,expiration:(0,QOe.parseRfc3339DateTime)(i.Expiration)}}if(e.statusCode>=400&&e.statusCode<500){let i={};try{i=JSON.parse(n)}catch{}throw Object.assign(new PD.CredentialsProviderError(`Server responded with status: ${e.statusCode}`,{logger:t}),{Code:i.Code,Message:i.Message})}throw new PD.CredentialsProviderError(`Server responded with status: ${e.statusCode}`,{logger:t})}});var _9=E(q0=>{"use strict";Object.defineProperty(q0,"__esModule",{value:!0});q0.retryWrapper=void 0;var rIe=(e,t,r)=>async()=>{for(let n=0;n<t;++n)try{return await e()}catch{await new Promise(o=>setTimeout(o,r))}return await e()};q0.retryWrapper=rIe});var w9=E(j0=>{"use strict";Object.defineProperty(j0,"__esModule",{value:!0});j0.fromHttp=void 0;var nIe=(qo(),Ve(Fo)),iIe=(ki(),Ve(xs)),oIe=Ca(),b9=Sn(),sIe=nIe.__importDefault(require("fs/promises")),aIe=g9(),E9=y9(),cIe=_9(),uIe="AWS_CONTAINER_CREDENTIALS_RELATIVE_URI",lIe="http://169.254.170.2",fIe="AWS_CONTAINER_CREDENTIALS_FULL_URI",dIe="AWS_CONTAINER_AUTHORIZATION_TOKEN_FILE",pIe="AWS_CONTAINER_AUTHORIZATION_TOKEN",hIe=(e={})=>{e.logger?.debug("@aws-sdk/credential-provider-http - fromHttp");let t,r=e.awsContainerCredentialsRelativeUri??process.env[uIe],n=e.awsContainerCredentialsFullUri??process.env[fIe],i=e.awsContainerAuthorizationToken??process.env[pIe],o=e.awsContainerAuthorizationTokenFile??process.env[dIe],s=e.logger?.constructor?.name==="NoOpLogger"||!e.logger?.warn?console.warn:e.logger.warn.bind(e.logger);if(r&&n&&(s("@aws-sdk/credential-provider-http: you have set both awsContainerCredentialsRelativeUri and awsContainerCredentialsFullUri."),s("awsContainerCredentialsFullUri will take precedence.")),i&&o&&(s("@aws-sdk/credential-provider-http: you have set both awsContainerAuthorizationToken and awsContainerAuthorizationTokenFile."),s("awsContainerAuthorizationToken will take precedence.")),n)t=n;else if(r)t=`${lIe}${r}`;else throw new b9.CredentialsProviderError(`No HTTP credential provider host provided.
|
|
232
|
+
Set AWS_CONTAINER_CREDENTIALS_FULL_URI or AWS_CONTAINER_CREDENTIALS_RELATIVE_URI.`,{logger:e.logger});let a=new URL(t);(0,aIe.checkUrl)(a,e.logger);let c=oIe.NodeHttpHandler.create({requestTimeout:e.timeout??1e3,connectionTimeout:e.timeout??1e3});return(0,cIe.retryWrapper)(async()=>{let u=(0,E9.createGetRequest)(a);i?u.headers.Authorization=i:o&&(u.headers.Authorization=(await sIe.default.readFile(o)).toString());try{let l=await c.handle(u);return(0,E9.getCredentials)(l.response).then(d=>(0,iIe.setCredentialFeature)(d,"CREDENTIALS_HTTP","z"))}catch(l){throw new b9.CredentialsProviderError(String(l),{logger:e.logger})}},e.maxRetries??3,e.timeout??1e3)};j0.fromHttp=hIe});var OD=E(U0=>{"use strict";Object.defineProperty(U0,"__esModule",{value:!0});U0.fromHttp=void 0;var mIe=w9();Object.defineProperty(U0,"fromHttp",{enumerable:!0,get:function(){return mIe.fromHttp}})});function gIe(e){return{schemeId:"aws.auth#sigv4",signingProperties:{name:"sso-oauth",region:e.region},propertiesExtractor:(t,r)=>({signingProperties:{config:t,context:r}})}}function yIe(e){return{schemeId:"smithy.api#noAuth"}}var Ph,S9,v9,C9,ID=Y(()=>{"use strict";Dr();Ph=z(an()),S9=async(e,t,r)=>({operation:(0,Ph.getSmithyContext)(t).operation,region:await(0,Ph.normalizeProvider)(e.region)()||(()=>{throw new Error("expected `region` to be configured for `aws.auth#sigv4`")})()});v9=e=>{let t=[];switch(e.operation){case"CreateToken":{t.push(yIe(e));break}default:t.push(gIe(e))}return t},C9=e=>{let t=Is(e);return Object.assign(t,{authSchemePreference:(0,Ph.normalizeProvider)(e.authSchemePreference??[])})}});var x9,T9,DD=Y(()=>{"use strict";x9=e=>Object.assign(e,{useDualstackEndpoint:e.useDualstackEndpoint??!1,useFipsEndpoint:e.useFipsEndpoint??!1,defaultSigningName:"sso-oauth"}),T9={UseFIPS:{type:"builtInParams",name:"useFipsEndpoint"},Endpoint:{type:"builtInParams",name:"endpoint"},Region:{type:"builtInParams",name:"region"},UseDualStack:{type:"builtInParams",name:"useDualstackEndpoint"}}});var Sf,H0=Y(()=>{Sf={name:"@aws-sdk/nested-clients",version:"3.943.0",description:"Nested clients for AWS SDK packages.",main:"./dist-cjs/index.js",module:"./dist-es/index.js",types:"./dist-types/index.d.ts",scripts:{build:"yarn lint && concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'","build:cjs":"node ../../scripts/compilation/inline nested-clients","build:es":"tsc -p tsconfig.es.json","build:include:deps":"lerna run --scope $npm_package_name --include-dependencies build","build:types":"tsc -p tsconfig.types.json","build:types:downlevel":"downlevel-dts dist-types dist-types/ts3.4",clean:"rimraf ./dist-* && rimraf *.tsbuildinfo",lint:"node ../../scripts/validation/submodules-linter.js --pkg nested-clients",test:"yarn g:vitest run","test:watch":"yarn g:vitest watch"},engines:{node:">=18.0.0"},sideEffects:!1,author:{name:"AWS SDK for JavaScript Team",url:"https://aws.amazon.com/javascript/"},license:"Apache-2.0",dependencies:{"@aws-crypto/sha256-browser":"5.2.0","@aws-crypto/sha256-js":"5.2.0","@aws-sdk/core":"3.943.0","@aws-sdk/middleware-host-header":"3.936.0","@aws-sdk/middleware-logger":"3.936.0","@aws-sdk/middleware-recursion-detection":"3.936.0","@aws-sdk/middleware-user-agent":"3.943.0","@aws-sdk/region-config-resolver":"3.936.0","@aws-sdk/types":"3.936.0","@aws-sdk/util-endpoints":"3.936.0","@aws-sdk/util-user-agent-browser":"3.936.0","@aws-sdk/util-user-agent-node":"3.943.0","@smithy/config-resolver":"^4.4.3","@smithy/core":"^3.18.5","@smithy/fetch-http-handler":"^5.3.6","@smithy/hash-node":"^4.2.5","@smithy/invalid-dependency":"^4.2.5","@smithy/middleware-content-length":"^4.2.5","@smithy/middleware-endpoint":"^4.3.12","@smithy/middleware-retry":"^4.4.12","@smithy/middleware-serde":"^4.2.6","@smithy/middleware-stack":"^4.2.5","@smithy/node-config-provider":"^4.3.5","@smithy/node-http-handler":"^4.4.5","@smithy/protocol-http":"^5.3.5","@smithy/smithy-client":"^4.9.8","@smithy/types":"^4.9.0","@smithy/url-parser":"^4.2.5","@smithy/util-base64":"^4.3.0","@smithy/util-body-length-browser":"^4.2.0","@smithy/util-body-length-node":"^4.2.1","@smithy/util-defaults-mode-browser":"^4.3.11","@smithy/util-defaults-mode-node":"^4.2.14","@smithy/util-endpoints":"^3.2.5","@smithy/util-middleware":"^4.2.5","@smithy/util-retry":"^4.2.5","@smithy/util-utf8":"^4.2.0",tslib:"^2.6.2"},devDependencies:{concurrently:"7.0.0","downlevel-dts":"0.10.1",rimraf:"3.0.2",typescript:"~5.8.3"},typesVersions:{"<4.0":{"dist-types/*":["dist-types/ts3.4/*"]}},files:["./signin.d.ts","./signin.js","./sso-oidc.d.ts","./sso-oidc.js","./sts.d.ts","./sts.js","dist-*/**"],browser:{"./dist-es/submodules/signin/runtimeConfig":"./dist-es/submodules/signin/runtimeConfig.browser","./dist-es/submodules/sso-oidc/runtimeConfig":"./dist-es/submodules/sso-oidc/runtimeConfig.browser","./dist-es/submodules/sts/runtimeConfig":"./dist-es/submodules/sts/runtimeConfig.browser"},"react-native":{},homepage:"https://github.com/aws/aws-sdk-js-v3/tree/main/packages/nested-clients",repository:{type:"git",url:"https://github.com/aws/aws-sdk-js-v3.git",directory:"packages/nested-clients"},exports:{"./package.json":"./package.json","./sso-oidc":{types:"./dist-types/submodules/sso-oidc/index.d.ts",module:"./dist-es/submodules/sso-oidc/index.js",node:"./dist-cjs/submodules/sso-oidc/index.js",import:"./dist-es/submodules/sso-oidc/index.js",require:"./dist-cjs/submodules/sso-oidc/index.js"},"./sts":{types:"./dist-types/submodules/sts/index.d.ts",module:"./dist-es/submodules/sts/index.js",node:"./dist-cjs/submodules/sts/index.js",import:"./dist-es/submodules/sts/index.js",require:"./dist-cjs/submodules/sts/index.js"},"./signin":{types:"./dist-types/submodules/signin/index.d.ts",module:"./dist-es/submodules/signin/index.js",node:"./dist-cjs/submodules/signin/index.js",import:"./dist-es/submodules/signin/index.js",require:"./dist-cjs/submodules/signin/index.js"}}}});var vf=E(gu=>{"use strict";var A9=require("os"),kD=require("process"),bIe=du(),R9={isCrtAvailable:!1},EIe=()=>R9.isCrtAvailable?["md/crt-avail"]:null,P9=({serviceId:e,clientVersion:t})=>async r=>{let n=[["aws-sdk-js",t],["ua","2.1"],[`os/${A9.platform()}`,A9.release()],["lang/js"],["md/nodejs",`${kD.versions.node}`]],i=EIe();i&&n.push(i),e&&n.push([`api/${e}`,t]),kD.env.AWS_EXECUTION_ENV&&n.push([`exec-env/${kD.env.AWS_EXECUTION_ENV}`]);let o=await r?.userAgentAppId?.();return o?[...n,[`app/${o}`]]:[...n]},wIe=P9,O9="AWS_SDK_UA_APP_ID",I9="sdk_ua_app_id",SIe="sdk-ua-app-id",vIe={environmentVariableSelector:e=>e[O9],configFileSelector:e=>e[I9]??e[SIe],default:bIe.DEFAULT_UA_APP_ID};gu.NODE_APP_ID_CONFIG_OPTIONS=vIe;gu.UA_APP_ID_ENV_NAME=O9;gu.UA_APP_ID_INI_NAME=I9;gu.createDefaultUserAgentProvider=P9;gu.crtAvailability=R9;gu.defaultUserAgent=wIe});var Cf=E(N9=>{"use strict";var ND=Fl(),CIe=Cr(),xIe=require("buffer"),D9=require("crypto"),MD=class{algorithmIdentifier;secret;hash;constructor(t,r){this.algorithmIdentifier=t,this.secret=r,this.reset()}update(t,r){this.hash.update(CIe.toUint8Array(k9(t,r)))}digest(){return Promise.resolve(this.hash.digest())}reset(){this.hash=this.secret?D9.createHmac(this.algorithmIdentifier,k9(this.secret)):D9.createHash(this.algorithmIdentifier)}};function k9(e,t){return xIe.Buffer.isBuffer(e)?e:typeof e=="string"?ND.fromString(e,t):ArrayBuffer.isView(e)?ND.fromArrayBuffer(e.buffer,e.byteOffset,e.byteLength):ND.fromArrayBuffer(e)}N9.Hash=MD});var xf=E(M9=>{"use strict";var LD=require("node:fs"),TIe=e=>{if(!e)return 0;if(typeof e=="string")return Buffer.byteLength(e);if(typeof e.byteLength=="number")return e.byteLength;if(typeof e.size=="number")return e.size;if(typeof e.start=="number"&&typeof e.end=="number")return e.end+1-e.start;if(e instanceof LD.ReadStream){if(e.path!=null)return LD.lstatSync(e.path).size;if(typeof e.fd=="number")return LD.fstatSync(e.fd).size}throw new Error(`Body Length computation failed for ${e}`)};M9.calculateBodyLength=TIe});var z9,Ui,L9,Oh,Tf,Af,Hs,BD,FD,B9,F9,q9,V9,W9,ji,j9,K9,U9,H9,$9,G9,AIe,Y9,X9=Y(()=>{"use strict";z9="required",Ui="argv",L9="isSet",Oh="booleanEquals",Tf="error",Af="endpoint",Hs="tree",BD="PartitionResult",FD="getAttr",B9={[z9]:!1,type:"string"},F9={[z9]:!0,default:!1,type:"boolean"},q9={ref:"Endpoint"},V9={fn:Oh,[Ui]:[{ref:"UseFIPS"},!0]},W9={fn:Oh,[Ui]:[{ref:"UseDualStack"},!0]},ji={},j9={fn:FD,[Ui]:[{ref:BD},"supportsFIPS"]},K9={ref:BD},U9={fn:Oh,[Ui]:[!0,{fn:FD,[Ui]:[K9,"supportsDualStack"]}]},H9=[V9],$9=[W9],G9=[{ref:"Region"}],AIe={version:"1.0",parameters:{Region:B9,UseDualStack:F9,UseFIPS:F9,Endpoint:B9},rules:[{conditions:[{fn:L9,[Ui]:[q9]}],rules:[{conditions:H9,error:"Invalid Configuration: FIPS and custom endpoint are not supported",type:Tf},{conditions:$9,error:"Invalid Configuration: Dualstack and custom endpoint are not supported",type:Tf},{endpoint:{url:q9,properties:ji,headers:ji},type:Af}],type:Hs},{conditions:[{fn:L9,[Ui]:G9}],rules:[{conditions:[{fn:"aws.partition",[Ui]:G9,assign:BD}],rules:[{conditions:[V9,W9],rules:[{conditions:[{fn:Oh,[Ui]:[!0,j9]},U9],rules:[{endpoint:{url:"https://oidc-fips.{Region}.{PartitionResult#dualStackDnsSuffix}",properties:ji,headers:ji},type:Af}],type:Hs},{error:"FIPS and DualStack are enabled, but this partition does not support one or both",type:Tf}],type:Hs},{conditions:H9,rules:[{conditions:[{fn:Oh,[Ui]:[j9,!0]}],rules:[{conditions:[{fn:"stringEquals",[Ui]:[{fn:FD,[Ui]:[K9,"name"]},"aws-us-gov"]}],endpoint:{url:"https://oidc.{Region}.amazonaws.com",properties:ji,headers:ji},type:Af},{endpoint:{url:"https://oidc-fips.{Region}.{PartitionResult#dnsSuffix}",properties:ji,headers:ji},type:Af}],type:Hs},{error:"FIPS is enabled but this partition does not support FIPS",type:Tf}],type:Hs},{conditions:$9,rules:[{conditions:[U9],rules:[{endpoint:{url:"https://oidc.{Region}.{PartitionResult#dualStackDnsSuffix}",properties:ji,headers:ji},type:Af}],type:Hs},{error:"DualStack is enabled but this partition does not support DualStack",type:Tf}],type:Hs},{endpoint:{url:"https://oidc.{Region}.{PartitionResult#dnsSuffix}",properties:ji,headers:ji},type:Af}],type:Hs}],type:Hs},{error:"Invalid Configuration: Missing Region",type:Tf}]},Y9=AIe});var J9,Rf,RIe,Q9,Z9=Y(()=>{"use strict";J9=z(fu()),Rf=z(Ua());X9();RIe=new Rf.EndpointCache({size:50,params:["Endpoint","Region","UseDualStack","UseFIPS"]}),Q9=(e,t={})=>RIe.get(e,()=>(0,Rf.resolveEndpoint)(Y9,{endpointParams:e,logger:t.logger}));Rf.customEndpointFunctions.aws=J9.awsEndpointFunctions});var e7,t7,$0,G0,r7,n7=Y(()=>{"use strict";Dr();uu();wn();e7=z(Ge()),t7=z(qs()),$0=z(Gr()),G0=z(Cr());ID();Z9();r7=e=>({apiVersion:"2019-06-10",base64Decoder:e?.base64Decoder??$0.fromBase64,base64Encoder:e?.base64Encoder??$0.toBase64,disableHostPrefix:e?.disableHostPrefix??!1,endpointProvider:e?.endpointProvider??Q9,extensions:e?.extensions??[],httpAuthSchemeProvider:e?.httpAuthSchemeProvider??v9,httpAuthSchemes:e?.httpAuthSchemes??[{schemeId:"aws.auth#sigv4",identityProvider:t=>t.getIdentityProvider("aws.auth#sigv4"),signer:new bn},{schemeId:"smithy.api#noAuth",identityProvider:t=>t.getIdentityProvider("smithy.api#noAuth")||(async()=>({})),signer:new oo}],logger:e?.logger??new e7.NoOpLogger,protocol:e?.protocol??new Ma({defaultNamespace:"com.amazonaws.ssooidc"}),serviceId:e?.serviceId??"SSO OIDC",urlParser:e?.urlParser??t7.parseUrl,utf8Decoder:e?.utf8Decoder??G0.fromUtf8,utf8Encoder:e?.utf8Encoder??G0.toUtf8})});var Pf=E(a7=>{"use strict";var PIe=si(),i7=zo(),OIe=Sn(),IIe="AWS_EXECUTION_ENV",o7="AWS_REGION",s7="AWS_DEFAULT_REGION",DIe="AWS_EC2_METADATA_DISABLED",kIe=["in-region","cross-region","mobile","standard","legacy"],NIe="/latest/meta-data/placement/region",MIe="AWS_DEFAULTS_MODE",LIe="defaults_mode",BIe={environmentVariableSelector:e=>e[MIe],configFileSelector:e=>e[LIe],default:"legacy"},FIe=({region:e=i7.loadConfig(PIe.NODE_REGION_CONFIG_OPTIONS),defaultsMode:t=i7.loadConfig(BIe)}={})=>OIe.memoize(async()=>{let r=typeof t=="function"?await t():t;switch(r?.toLowerCase()){case"auto":return qIe(e);case"in-region":case"cross-region":case"mobile":case"standard":case"legacy":return Promise.resolve(r?.toLocaleLowerCase());case void 0:return Promise.resolve("legacy");default:throw new Error(`Invalid parameter for "defaultsMode", expect ${kIe.join(", ")}, got ${r}`)}}),qIe=async e=>{if(e){let t=typeof e=="function"?await e():e,r=await jIe();return r?t===r?"in-region":"cross-region":"standard"}return"standard"},jIe=async()=>{if(process.env[IIe]&&(process.env[o7]||process.env[s7]))return process.env[o7]??process.env[s7];if(!process.env[DIe])try{let{getInstanceMetadataEndpoint:e,httpRequest:t}=await Promise.resolve().then(()=>z(Rh())),r=await e();return(await t({...r,path:NIe})).toString()}catch{}};a7.resolveDefaultsModeConfig=FIe});var z0,Xa,c7,V0,Ya,W0,u7,l7,f7,d7,p7,h7,m7=Y(()=>{"use strict";H0();Dr();z0=z(vf()),Xa=z(si()),c7=z(Cf()),V0=z(co()),Ya=z(zo()),W0=z(Ca()),u7=z(xf()),l7=z(hu());n7();f7=z(Ge()),d7=z(Pf()),p7=z(Ge()),h7=e=>{(0,p7.emitWarningIfUnsupportedVersion)(process.version);let t=(0,d7.resolveDefaultsModeConfig)(e),r=()=>t().then(f7.loadConfigsForDefaultMode),n=r7(e);ba(process.version);let i={profile:e?.profile,logger:n.logger};return{...n,...e,runtime:"node",defaultsMode:t,authSchemePreference:e?.authSchemePreference??(0,Ya.loadConfig)(wa,i),bodyLengthChecker:e?.bodyLengthChecker??u7.calculateBodyLength,defaultUserAgentProvider:e?.defaultUserAgentProvider??(0,z0.createDefaultUserAgentProvider)({serviceId:n.serviceId,clientVersion:Sf.version}),maxAttempts:e?.maxAttempts??(0,Ya.loadConfig)(V0.NODE_MAX_ATTEMPT_CONFIG_OPTIONS,e),region:e?.region??(0,Ya.loadConfig)(Xa.NODE_REGION_CONFIG_OPTIONS,{...Xa.NODE_REGION_CONFIG_FILE_OPTIONS,...i}),requestHandler:W0.NodeHttpHandler.create(e?.requestHandler??r),retryMode:e?.retryMode??(0,Ya.loadConfig)({...V0.NODE_RETRY_MODE_CONFIG_OPTIONS,default:async()=>(await r()).retryMode||l7.DEFAULT_RETRY_MODE},e),sha256:e?.sha256??c7.Hash.bind(null,"sha256"),streamCollector:e?.streamCollector??W0.streamCollector,useDualstackEndpoint:e?.useDualstackEndpoint??(0,Ya.loadConfig)(Xa.NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS,i),useFipsEndpoint:e?.useFipsEndpoint??(0,Ya.loadConfig)(Xa.NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS,i),userAgentAppId:e?.userAgentAppId??(0,Ya.loadConfig)(z0.NODE_APP_ID_CONFIG_OPTIONS,i)}}});var y7=E(Of=>{"use strict";Object.defineProperty(Of,"__esModule",{value:!0});Of.warning=void 0;Of.stsRegionDefaultResolver=HIe;var g7=si(),UIe=zo();function HIe(e={}){return(0,UIe.loadConfig)({...g7.NODE_REGION_CONFIG_OPTIONS,async default(){return Of.warning.silence||console.warn("@aws-sdk - WARN - default STS region of us-east-1 used. See @aws-sdk/credential-providers README and set a region explicitly."),"us-east-1"}},{...g7.NODE_REGION_CONFIG_FILE_OPTIONS,...e})}Of.warning={silence:!1}});var yu=E(Jo=>{"use strict";var Ih=si(),_7=y7(),$Ie=e=>({setRegion(t){e.region=t},region(){return e.region}}),GIe=e=>({region:e.region()});Object.defineProperty(Jo,"NODE_REGION_CONFIG_FILE_OPTIONS",{enumerable:!0,get:function(){return Ih.NODE_REGION_CONFIG_FILE_OPTIONS}});Object.defineProperty(Jo,"NODE_REGION_CONFIG_OPTIONS",{enumerable:!0,get:function(){return Ih.NODE_REGION_CONFIG_OPTIONS}});Object.defineProperty(Jo,"REGION_ENV_NAME",{enumerable:!0,get:function(){return Ih.REGION_ENV_NAME}});Object.defineProperty(Jo,"REGION_INI_NAME",{enumerable:!0,get:function(){return Ih.REGION_INI_NAME}});Object.defineProperty(Jo,"resolveRegionConfig",{enumerable:!0,get:function(){return Ih.resolveRegionConfig}});Jo.getAwsRegionExtensionConfiguration=$Ie;Jo.resolveAwsRegionExtensionConfiguration=GIe;Object.keys(_7).forEach(function(e){e!=="default"&&!Object.prototype.hasOwnProperty.call(Jo,e)&&Object.defineProperty(Jo,e,{enumerable:!0,get:function(){return _7[e]}})})});var b7,E7,w7=Y(()=>{"use strict";b7=e=>{let t=e.httpAuthSchemes,r=e.httpAuthSchemeProvider,n=e.credentials;return{setHttpAuthScheme(i){let o=t.findIndex(s=>s.schemeId===i.schemeId);o===-1?t.push(i):t.splice(o,1,i)},httpAuthSchemes(){return t},setHttpAuthSchemeProvider(i){r=i},httpAuthSchemeProvider(){return r},setCredentials(i){n=i},credentials(){return n}}},E7=e=>({httpAuthSchemes:e.httpAuthSchemes(),httpAuthSchemeProvider:e.httpAuthSchemeProvider(),credentials:e.credentials()})});var K0,Y0,X0,S7,v7=Y(()=>{"use strict";K0=z(yu()),Y0=z(St()),X0=z(Ge());w7();S7=(e,t)=>{let r=Object.assign((0,K0.getAwsRegionExtensionConfiguration)(e),(0,X0.getDefaultExtensionConfiguration)(e),(0,Y0.getHttpHandlerExtensionConfiguration)(e),b7(e));return t.forEach(n=>n.configure(r)),Object.assign(e,(0,K0.resolveAwsRegionExtensionConfiguration)(r),(0,X0.resolveDefaultRuntimeConfig)(r),(0,Y0.resolveHttpHandlerRuntimeConfig)(r),E7(r))}});var J0,C7,x7,Q0,T7,A7,R7,Z0,qD,Dh,jD=Y(()=>{"use strict";J0=z(af()),C7=z(cf()),x7=z(uf()),Q0=z(du()),T7=z(si());wn();xt();A7=z(hf()),R7=z(ao()),Z0=z(co()),qD=z(Ge());ID();DD();m7();v7();Dh=class extends qD.Client{config;constructor(...[t]){let r=h7(t||{});super(r),this.initConfig=r;let n=x9(r),i=(0,Q0.resolveUserAgentConfig)(n),o=(0,Z0.resolveRetryConfig)(i),s=(0,T7.resolveRegionConfig)(o),a=(0,J0.resolveHostHeaderConfig)(s),c=(0,R7.resolveEndpointConfig)(a),u=C9(c),l=S7(u,t?.extensions||[]);this.config=l,this.middlewareStack.use(Qc(this.config)),this.middlewareStack.use((0,Q0.getUserAgentPlugin)(this.config)),this.middlewareStack.use((0,Z0.getRetryPlugin)(this.config)),this.middlewareStack.use((0,A7.getContentLengthPlugin)(this.config)),this.middlewareStack.use((0,J0.getHostHeaderPlugin)(this.config)),this.middlewareStack.use((0,C7.getLoggerPlugin)(this.config)),this.middlewareStack.use((0,x7.getRecursionDetectionPlugin)(this.config)),this.middlewareStack.use(Yc(this.config,{httpAuthSchemeParametersProvider:S9,identityProviderConfigProvider:async d=>new Os({"aws.auth#sigv4":d.credentials})})),this.middlewareStack.use(Xc(this.config))}destroy(){super.destroy()}}});var P7,Xr,eE=Y(()=>{"use strict";P7=z(Ge()),Xr=class e extends P7.ServiceException{constructor(t){super(t),Object.setPrototypeOf(this,e.prototype)}}});var kh,Nh,Mh,Lh,Bh,Fh,qh,jh,Uh,Hh,$h,UD=Y(()=>{"use strict";eE();kh=class e extends Xr{name="AccessDeniedException";$fault="client";error;reason;error_description;constructor(t){super({name:"AccessDeniedException",$fault:"client",...t}),Object.setPrototypeOf(this,e.prototype),this.error=t.error,this.reason=t.reason,this.error_description=t.error_description}},Nh=class e extends Xr{name="AuthorizationPendingException";$fault="client";error;error_description;constructor(t){super({name:"AuthorizationPendingException",$fault:"client",...t}),Object.setPrototypeOf(this,e.prototype),this.error=t.error,this.error_description=t.error_description}},Mh=class e extends Xr{name="ExpiredTokenException";$fault="client";error;error_description;constructor(t){super({name:"ExpiredTokenException",$fault:"client",...t}),Object.setPrototypeOf(this,e.prototype),this.error=t.error,this.error_description=t.error_description}},Lh=class e extends Xr{name="InternalServerException";$fault="server";error;error_description;constructor(t){super({name:"InternalServerException",$fault:"server",...t}),Object.setPrototypeOf(this,e.prototype),this.error=t.error,this.error_description=t.error_description}},Bh=class e extends Xr{name="InvalidClientException";$fault="client";error;error_description;constructor(t){super({name:"InvalidClientException",$fault:"client",...t}),Object.setPrototypeOf(this,e.prototype),this.error=t.error,this.error_description=t.error_description}},Fh=class e extends Xr{name="InvalidGrantException";$fault="client";error;error_description;constructor(t){super({name:"InvalidGrantException",$fault:"client",...t}),Object.setPrototypeOf(this,e.prototype),this.error=t.error,this.error_description=t.error_description}},qh=class e extends Xr{name="InvalidRequestException";$fault="client";error;reason;error_description;constructor(t){super({name:"InvalidRequestException",$fault:"client",...t}),Object.setPrototypeOf(this,e.prototype),this.error=t.error,this.reason=t.reason,this.error_description=t.error_description}},jh=class e extends Xr{name="InvalidScopeException";$fault="client";error;error_description;constructor(t){super({name:"InvalidScopeException",$fault:"client",...t}),Object.setPrototypeOf(this,e.prototype),this.error=t.error,this.error_description=t.error_description}},Uh=class e extends Xr{name="SlowDownException";$fault="client";error;error_description;constructor(t){super({name:"SlowDownException",$fault:"client",...t}),Object.setPrototypeOf(this,e.prototype),this.error=t.error,this.error_description=t.error_description}},Hh=class e extends Xr{name="UnauthorizedClientException";$fault="client";error;error_description;constructor(t){super({name:"UnauthorizedClientException",$fault:"client",...t}),Object.setPrototypeOf(this,e.prototype),this.error=t.error,this.error_description=t.error_description}},$h=class e extends Xr{name="UnsupportedGrantTypeException";$fault="client";error;error_description;constructor(t){super({name:"UnsupportedGrantTypeException",$fault:"client",...t}),Object.setPrototypeOf(this,e.prototype),this.error=t.error,this.error_description=t.error_description}}});var zIe,VIe,WIe,KIe,YIe,XIe,JIe,QIe,ZIe,eDe,tDe,rDe,nDe,iDe,oDe,sDe,aDe,cDe,uDe,lDe,Qo,fDe,dDe,pDe,hDe,mDe,fr,gDe,uo,yDe,_De,lo,bDe,O7,I7,EDe,wDe,SDe,D7,vDe,Rt,CDe,xDe,TDe,ADe,k7,RDe,PDe,ODe,IDe,DDe,kDe,NDe,MDe,LDe,BDe,FDe,qDe,jDe,UDe,N7,M7=Y(()=>{"use strict";xt();UD();eE();zIe="AccessDeniedException",VIe="AuthorizationPendingException",WIe="AccessToken",KIe="ClientSecret",YIe="CreateToken",XIe="CreateTokenRequest",JIe="CreateTokenResponse",QIe="CodeVerifier",ZIe="ExpiredTokenException",eDe="InvalidClientException",tDe="InvalidGrantException",rDe="InvalidRequestException",nDe="InternalServerException",iDe="InvalidScopeException",oDe="IdToken",sDe="RefreshToken",aDe="SlowDownException",cDe="UnauthorizedClientException",uDe="UnsupportedGrantTypeException",lDe="accessToken",Qo="client",fDe="clientId",dDe="clientSecret",pDe="codeVerifier",hDe="code",mDe="deviceCode",fr="error",gDe="expiresIn",uo="error_description",yDe="grantType",_De="http",lo="httpError",bDe="idToken",O7="reason",I7="refreshToken",EDe="redirectUri",wDe="scope",SDe="server",D7="smithy.ts.sdk.synthetic.com.amazonaws.ssooidc",vDe="tokenType",Rt="com.amazonaws.ssooidc",CDe=[0,Rt,WIe,8,0],xDe=[0,Rt,KIe,8,0],TDe=[0,Rt,QIe,8,0],ADe=[0,Rt,oDe,8,0],k7=[0,Rt,sDe,8,0],RDe=[-3,Rt,zIe,{[fr]:Qo,[lo]:400},[fr,O7,uo],[0,0,0]];Ue.for(Rt).registerError(RDe,kh);PDe=[-3,Rt,VIe,{[fr]:Qo,[lo]:400},[fr,uo],[0,0]];Ue.for(Rt).registerError(PDe,Nh);ODe=[3,Rt,XIe,0,[fDe,dDe,yDe,mDe,hDe,I7,wDe,EDe,pDe],[0,[()=>xDe,0],0,0,0,[()=>k7,0],64,0,[()=>TDe,0]]],IDe=[3,Rt,JIe,0,[lDe,vDe,gDe,I7,bDe],[[()=>CDe,0],0,1,[()=>k7,0],[()=>ADe,0]]],DDe=[-3,Rt,ZIe,{[fr]:Qo,[lo]:400},[fr,uo],[0,0]];Ue.for(Rt).registerError(DDe,Mh);kDe=[-3,Rt,nDe,{[fr]:SDe,[lo]:500},[fr,uo],[0,0]];Ue.for(Rt).registerError(kDe,Lh);NDe=[-3,Rt,eDe,{[fr]:Qo,[lo]:401},[fr,uo],[0,0]];Ue.for(Rt).registerError(NDe,Bh);MDe=[-3,Rt,tDe,{[fr]:Qo,[lo]:400},[fr,uo],[0,0]];Ue.for(Rt).registerError(MDe,Fh);LDe=[-3,Rt,rDe,{[fr]:Qo,[lo]:400},[fr,O7,uo],[0,0,0]];Ue.for(Rt).registerError(LDe,qh);BDe=[-3,Rt,iDe,{[fr]:Qo,[lo]:400},[fr,uo],[0,0]];Ue.for(Rt).registerError(BDe,jh);FDe=[-3,Rt,aDe,{[fr]:Qo,[lo]:400},[fr,uo],[0,0]];Ue.for(Rt).registerError(FDe,Uh);qDe=[-3,Rt,cDe,{[fr]:Qo,[lo]:400},[fr,uo],[0,0]];Ue.for(Rt).registerError(qDe,Hh);jDe=[-3,Rt,uDe,{[fr]:Qo,[lo]:400},[fr,uo],[0,0]];Ue.for(Rt).registerError(jDe,$h);UDe=[-3,D7,"SSOOIDCServiceException",0,[],[]];Ue.for(D7).registerError(UDe,Xr);N7=[9,Rt,YIe,{[_De]:["POST","/token",200]},()=>ODe,()=>IDe]});var L7,HD,Gh,$D=Y(()=>{"use strict";L7=z(ao()),HD=z(Ge());DD();M7();Gh=class extends HD.Command.classBuilder().ep(T9).m(function(t,r,n,i){return[(0,L7.getEndpointPlugin)(n,t.getEndpointParameterInstructions())]}).s("AWSSSOOIDCService","CreateToken",{}).n("SSOOIDCClient","CreateTokenCommand").sc(N7).build(){}});var B7,HDe,tE,F7=Y(()=>{"use strict";B7=z(Ge());$D();jD();HDe={CreateTokenCommand:Gh},tE=class extends Dh{};(0,B7.createAggregatedClient)(HDe,tE)});var q7=Y(()=>{"use strict";$D()});var $De,GDe,j7=Y(()=>{"use strict";$De={KMS_ACCESS_DENIED:"KMS_AccessDeniedException"},GDe={KMS_DISABLED_KEY:"KMS_DisabledException",KMS_INVALID_KEY_USAGE:"KMS_InvalidKeyUsageException",KMS_INVALID_STATE:"KMS_InvalidStateException",KMS_KEY_NOT_FOUND:"KMS_NotFoundException"}});var GD={};Nn(GD,{$Command:()=>HD.Command,AccessDeniedException:()=>kh,AccessDeniedExceptionReason:()=>$De,AuthorizationPendingException:()=>Nh,CreateTokenCommand:()=>Gh,ExpiredTokenException:()=>Mh,InternalServerException:()=>Lh,InvalidClientException:()=>Bh,InvalidGrantException:()=>Fh,InvalidRequestException:()=>qh,InvalidRequestExceptionReason:()=>GDe,InvalidScopeException:()=>jh,SSOOIDC:()=>tE,SSOOIDCClient:()=>Dh,SSOOIDCServiceException:()=>Xr,SlowDownException:()=>Uh,UnauthorizedClientException:()=>Hh,UnsupportedGrantTypeException:()=>$h,__Client:()=>qD.Client});var zD=Y(()=>{"use strict";jD();F7();q7();j7();UD();eE()});var G7=E(Vh=>{"use strict";var zDe=(ki(),Ve(xs)),VDe=(iO(),Ve(v$)),Ei=Sn(),zh=Go(),WDe=require("fs"),KDe=({logger:e,signingName:t}={})=>async()=>{if(e?.debug?.("@aws-sdk/token-providers - fromEnvSigningName"),!t)throw new Ei.TokenProviderError("Please pass 'signingName' to compute environment variable key",{logger:e});let r=VDe.getBearerTokenEnvKey(t);if(!(r in process.env))throw new Ei.TokenProviderError(`Token not present in '${r}' environment variable`,{logger:e});let n={token:process.env[r]};return zDe.setTokenFeature(n,"BEARER_SERVICE_ENV_VARS","3"),n},YDe=300*1e3,VD="To refresh this SSO session run 'aws sso login' with the corresponding profile.",XDe=async(e,t={})=>{let{SSOOIDCClient:r}=await Promise.resolve().then(()=>(zD(),GD)),n=o=>t.clientConfig?.[o]??t.parentClientConfig?.[o];return new r(Object.assign({},t.clientConfig??{},{region:e??t.clientConfig?.region,logger:n("logger"),userAgentAppId:n("userAgentAppId")}))},JDe=async(e,t,r={})=>{let{CreateTokenCommand:n}=await Promise.resolve().then(()=>(zD(),GD));return(await XDe(t,r)).send(new n({clientId:e.clientId,clientSecret:e.clientSecret,refreshToken:e.refreshToken,grantType:"refresh_token"}))},U7=e=>{if(e.expiration&&e.expiration.getTime()<Date.now())throw new Ei.TokenProviderError(`Token is expired. ${VD}`,!1)},_u=(e,t,r=!1)=>{if(typeof t>"u")throw new Ei.TokenProviderError(`Value not present for '${e}' in SSO Token${r?". Cannot refresh":""}. ${VD}`,!1)},{writeFile:QDe}=WDe.promises,ZDe=(e,t)=>{let r=zh.getSSOTokenFilepath(e),n=JSON.stringify(t,null,2);return QDe(r,n)},H7=new Date(0),$7=(e={})=>async({callerClientConfig:t}={})=>{let r={...e,parentClientConfig:{...t,...e.parentClientConfig}};r.logger?.debug("@aws-sdk/token-providers - fromSso");let n=await zh.parseKnownFiles(r),i=zh.getProfileName({profile:r.profile??t?.profile}),o=n[i];if(o){if(!o.sso_session)throw new Ei.TokenProviderError(`Profile '${i}' is missing required property 'sso_session'.`)}else throw new Ei.TokenProviderError(`Profile '${i}' could not be found in shared credentials file.`,!1);let s=o.sso_session,c=(await zh.loadSsoSessionData(r))[s];if(!c)throw new Ei.TokenProviderError(`Sso session '${s}' could not be found in shared credentials file.`,!1);for(let p of["sso_start_url","sso_region"])if(!c[p])throw new Ei.TokenProviderError(`Sso session '${s}' is missing required property '${p}'.`,!1);c.sso_start_url;let u=c.sso_region,l;try{l=await zh.getSSOTokenFromFile(s)}catch{throw new Ei.TokenProviderError(`The SSO session token associated with profile=${i} was not found or is invalid. ${VD}`,!1)}_u("accessToken",l.accessToken),_u("expiresAt",l.expiresAt);let{accessToken:d,expiresAt:h}=l,f={token:d,expiration:new Date(h)};if(f.expiration.getTime()-Date.now()>YDe)return f;if(Date.now()-H7.getTime()<30*1e3)return U7(f),f;_u("clientId",l.clientId,!0),_u("clientSecret",l.clientSecret,!0),_u("refreshToken",l.refreshToken,!0);try{H7.setTime(Date.now());let p=await JDe(l,u,r);_u("accessToken",p.accessToken),_u("expiresIn",p.expiresIn);let m=new Date(Date.now()+p.expiresIn*1e3);try{await ZDe(s,{...l,accessToken:p.accessToken,expiresAt:m.toISOString(),refreshToken:p.refreshToken})}catch{}return{token:p.accessToken,expiration:m}}catch{return U7(f),f}},eke=({token:e,logger:t})=>async()=>{if(t?.debug("@aws-sdk/token-providers - fromStatic"),!e||!e.token)throw new Ei.TokenProviderError("Please pass a valid token to fromStatic",!1);return e},tke=(e={})=>Ei.memoize(Ei.chain($7(e),async()=>{throw new Ei.TokenProviderError("Could not load token from any providers",!1)}),t=>t.expiration!==void 0&&t.expiration.getTime()-Date.now()<3e5,t=>t.expiration!==void 0);Vh.fromEnvSigningName=KDe;Vh.fromSso=$7;Vh.fromStatic=eke;Vh.nodeProvider=tke});var KD=E(Ja=>{"use strict";Object.defineProperty(Ja,"__esModule",{value:!0});Ja.resolveHttpAuthSchemeConfig=Ja.defaultSSOHttpAuthSchemeProvider=Ja.defaultSSOHttpAuthSchemeParametersProvider=void 0;var rke=(Dr(),Ve(Uo)),WD=an(),nke=async(e,t,r)=>({operation:(0,WD.getSmithyContext)(t).operation,region:await(0,WD.normalizeProvider)(e.region)()||(()=>{throw new Error("expected `region` to be configured for `aws.auth#sigv4`")})()});Ja.defaultSSOHttpAuthSchemeParametersProvider=nke;function ike(e){return{schemeId:"aws.auth#sigv4",signingProperties:{name:"awsssoportal",region:e.region},propertiesExtractor:(t,r)=>({signingProperties:{config:t,context:r}})}}function rE(e){return{schemeId:"smithy.api#noAuth"}}var oke=e=>{let t=[];switch(e.operation){case"GetRoleCredentials":{t.push(rE(e));break}case"ListAccountRoles":{t.push(rE(e));break}case"ListAccounts":{t.push(rE(e));break}case"Logout":{t.push(rE(e));break}default:t.push(ike(e))}return t};Ja.defaultSSOHttpAuthSchemeProvider=oke;var ske=e=>{let t=(0,rke.resolveAwsSdkSigV4Config)(e);return Object.assign(t,{authSchemePreference:(0,WD.normalizeProvider)(e.authSchemePreference??[])})};Ja.resolveHttpAuthSchemeConfig=ske});var z7=E((wEt,ake)=>{ake.exports={name:"@aws-sdk/client-sso",description:"AWS SDK for JavaScript Sso Client for Node.js, Browser and React Native",version:"3.943.0",scripts:{build:"concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'","build:cjs":"node ../../scripts/compilation/inline client-sso","build:es":"tsc -p tsconfig.es.json","build:include:deps":"lerna run --scope $npm_package_name --include-dependencies build","build:types":"tsc -p tsconfig.types.json","build:types:downlevel":"downlevel-dts dist-types dist-types/ts3.4",clean:"rimraf ./dist-* && rimraf *.tsbuildinfo","extract:docs":"api-extractor run --local","generate:client":"node ../../scripts/generate-clients/single-service --solo sso"},main:"./dist-cjs/index.js",types:"./dist-types/index.d.ts",module:"./dist-es/index.js",sideEffects:!1,dependencies:{"@aws-crypto/sha256-browser":"5.2.0","@aws-crypto/sha256-js":"5.2.0","@aws-sdk/core":"3.943.0","@aws-sdk/middleware-host-header":"3.936.0","@aws-sdk/middleware-logger":"3.936.0","@aws-sdk/middleware-recursion-detection":"3.936.0","@aws-sdk/middleware-user-agent":"3.943.0","@aws-sdk/region-config-resolver":"3.936.0","@aws-sdk/types":"3.936.0","@aws-sdk/util-endpoints":"3.936.0","@aws-sdk/util-user-agent-browser":"3.936.0","@aws-sdk/util-user-agent-node":"3.943.0","@smithy/config-resolver":"^4.4.3","@smithy/core":"^3.18.5","@smithy/fetch-http-handler":"^5.3.6","@smithy/hash-node":"^4.2.5","@smithy/invalid-dependency":"^4.2.5","@smithy/middleware-content-length":"^4.2.5","@smithy/middleware-endpoint":"^4.3.12","@smithy/middleware-retry":"^4.4.12","@smithy/middleware-serde":"^4.2.6","@smithy/middleware-stack":"^4.2.5","@smithy/node-config-provider":"^4.3.5","@smithy/node-http-handler":"^4.4.5","@smithy/protocol-http":"^5.3.5","@smithy/smithy-client":"^4.9.8","@smithy/types":"^4.9.0","@smithy/url-parser":"^4.2.5","@smithy/util-base64":"^4.3.0","@smithy/util-body-length-browser":"^4.2.0","@smithy/util-body-length-node":"^4.2.1","@smithy/util-defaults-mode-browser":"^4.3.11","@smithy/util-defaults-mode-node":"^4.2.14","@smithy/util-endpoints":"^3.2.5","@smithy/util-middleware":"^4.2.5","@smithy/util-retry":"^4.2.5","@smithy/util-utf8":"^4.2.0",tslib:"^2.6.2"},devDependencies:{"@tsconfig/node18":"18.2.4","@types/node":"^18.19.69",concurrently:"7.0.0","downlevel-dts":"0.10.1",rimraf:"3.0.2",typescript:"~5.8.3"},engines:{node:">=18.0.0"},typesVersions:{"<4.0":{"dist-types/*":["dist-types/ts3.4/*"]}},files:["dist-*/**"],author:{name:"AWS SDK for JavaScript Team",url:"https://aws.amazon.com/javascript/"},license:"Apache-2.0",browser:{"./dist-es/runtimeConfig":"./dist-es/runtimeConfig.browser"},"react-native":{"./dist-es/runtimeConfig":"./dist-es/runtimeConfig.native"},homepage:"https://github.com/aws/aws-sdk-js-v3/tree/main/clients/client-sso",repository:{type:"git",url:"https://github.com/aws/aws-sdk-js-v3.git",directory:"clients/client-sso"}}});var sK=E(nE=>{"use strict";Object.defineProperty(nE,"__esModule",{value:!0});nE.ruleSet=void 0;var rK="required",$i="fn",Gi="argv",kf="ref",V7=!0,W7="isSet",Wh="booleanEquals",If="error",Df="endpoint",$s="tree",YD="PartitionResult",XD="getAttr",K7={[rK]:!1,type:"string"},Y7={[rK]:!0,default:!1,type:"boolean"},X7={[kf]:"Endpoint"},nK={[$i]:Wh,[Gi]:[{[kf]:"UseFIPS"},!0]},iK={[$i]:Wh,[Gi]:[{[kf]:"UseDualStack"},!0]},Hi={},J7={[$i]:XD,[Gi]:[{[kf]:YD},"supportsFIPS"]},oK={[kf]:YD},Q7={[$i]:Wh,[Gi]:[!0,{[$i]:XD,[Gi]:[oK,"supportsDualStack"]}]},Z7=[nK],eK=[iK],tK=[{[kf]:"Region"}],cke={version:"1.0",parameters:{Region:K7,UseDualStack:Y7,UseFIPS:Y7,Endpoint:K7},rules:[{conditions:[{[$i]:W7,[Gi]:[X7]}],rules:[{conditions:Z7,error:"Invalid Configuration: FIPS and custom endpoint are not supported",type:If},{conditions:eK,error:"Invalid Configuration: Dualstack and custom endpoint are not supported",type:If},{endpoint:{url:X7,properties:Hi,headers:Hi},type:Df}],type:$s},{conditions:[{[$i]:W7,[Gi]:tK}],rules:[{conditions:[{[$i]:"aws.partition",[Gi]:tK,assign:YD}],rules:[{conditions:[nK,iK],rules:[{conditions:[{[$i]:Wh,[Gi]:[V7,J7]},Q7],rules:[{endpoint:{url:"https://portal.sso-fips.{Region}.{PartitionResult#dualStackDnsSuffix}",properties:Hi,headers:Hi},type:Df}],type:$s},{error:"FIPS and DualStack are enabled, but this partition does not support one or both",type:If}],type:$s},{conditions:Z7,rules:[{conditions:[{[$i]:Wh,[Gi]:[J7,V7]}],rules:[{conditions:[{[$i]:"stringEquals",[Gi]:[{[$i]:XD,[Gi]:[oK,"name"]},"aws-us-gov"]}],endpoint:{url:"https://portal.sso.{Region}.amazonaws.com",properties:Hi,headers:Hi},type:Df},{endpoint:{url:"https://portal.sso-fips.{Region}.{PartitionResult#dnsSuffix}",properties:Hi,headers:Hi},type:Df}],type:$s},{error:"FIPS is enabled but this partition does not support FIPS",type:If}],type:$s},{conditions:eK,rules:[{conditions:[Q7],rules:[{endpoint:{url:"https://portal.sso.{Region}.{PartitionResult#dualStackDnsSuffix}",properties:Hi,headers:Hi},type:Df}],type:$s},{error:"DualStack is enabled but this partition does not support DualStack",type:If}],type:$s},{endpoint:{url:"https://portal.sso.{Region}.{PartitionResult#dnsSuffix}",properties:Hi,headers:Hi},type:Df}],type:$s}],type:$s},{error:"Invalid Configuration: Missing Region",type:If}]};nE.ruleSet=cke});var aK=E(iE=>{"use strict";Object.defineProperty(iE,"__esModule",{value:!0});iE.defaultEndpointResolver=void 0;var uke=fu(),JD=Ua(),lke=sK(),fke=new JD.EndpointCache({size:50,params:["Endpoint","Region","UseDualStack","UseFIPS"]}),dke=(e,t={})=>fke.get(e,()=>(0,JD.resolveEndpoint)(lke.ruleSet,{endpointParams:e,logger:t.logger}));iE.defaultEndpointResolver=dke;JD.customEndpointFunctions.aws=uke.awsEndpointFunctions});var lK=E(oE=>{"use strict";Object.defineProperty(oE,"__esModule",{value:!0});oE.getRuntimeConfig=void 0;var pke=(Dr(),Ve(Uo)),hke=(uu(),Ve(zO)),mke=(wn(),Ve(ou)),gke=Ge(),yke=qs(),cK=Gr(),uK=Cr(),_ke=KD(),bke=aK(),Eke=e=>({apiVersion:"2019-06-10",base64Decoder:e?.base64Decoder??cK.fromBase64,base64Encoder:e?.base64Encoder??cK.toBase64,disableHostPrefix:e?.disableHostPrefix??!1,endpointProvider:e?.endpointProvider??bke.defaultEndpointResolver,extensions:e?.extensions??[],httpAuthSchemeProvider:e?.httpAuthSchemeProvider??_ke.defaultSSOHttpAuthSchemeProvider,httpAuthSchemes:e?.httpAuthSchemes??[{schemeId:"aws.auth#sigv4",identityProvider:t=>t.getIdentityProvider("aws.auth#sigv4"),signer:new pke.AwsSdkSigV4Signer},{schemeId:"smithy.api#noAuth",identityProvider:t=>t.getIdentityProvider("smithy.api#noAuth")||(async()=>({})),signer:new mke.NoAuthSigner}],logger:e?.logger??new gke.NoOpLogger,protocol:e?.protocol??new hke.AwsRestJsonProtocol({defaultNamespace:"com.amazonaws.sso"}),serviceId:e?.serviceId??"SSO",urlParser:e?.urlParser??yke.parseUrl,utf8Decoder:e?.utf8Decoder??uK.fromUtf8,utf8Encoder:e?.utf8Encoder??uK.toUtf8});oE.getRuntimeConfig=Eke});var mK=E(aE=>{"use strict";Object.defineProperty(aE,"__esModule",{value:!0});aE.getRuntimeConfig=void 0;var wke=(qo(),Ve(Fo)),Ske=wke.__importDefault(z7()),fK=(Dr(),Ve(Uo)),dK=vf(),sE=si(),vke=Cf(),pK=co(),bu=zo(),hK=Ca(),Cke=xf(),xke=hu(),Tke=lK(),Ake=Ge(),Rke=Pf(),Pke=Ge(),Oke=e=>{(0,Pke.emitWarningIfUnsupportedVersion)(process.version);let t=(0,Rke.resolveDefaultsModeConfig)(e),r=()=>t().then(Ake.loadConfigsForDefaultMode),n=(0,Tke.getRuntimeConfig)(e);(0,fK.emitWarningIfUnsupportedVersion)(process.version);let i={profile:e?.profile,logger:n.logger};return{...n,...e,runtime:"node",defaultsMode:t,authSchemePreference:e?.authSchemePreference??(0,bu.loadConfig)(fK.NODE_AUTH_SCHEME_PREFERENCE_OPTIONS,i),bodyLengthChecker:e?.bodyLengthChecker??Cke.calculateBodyLength,defaultUserAgentProvider:e?.defaultUserAgentProvider??(0,dK.createDefaultUserAgentProvider)({serviceId:n.serviceId,clientVersion:Ske.default.version}),maxAttempts:e?.maxAttempts??(0,bu.loadConfig)(pK.NODE_MAX_ATTEMPT_CONFIG_OPTIONS,e),region:e?.region??(0,bu.loadConfig)(sE.NODE_REGION_CONFIG_OPTIONS,{...sE.NODE_REGION_CONFIG_FILE_OPTIONS,...i}),requestHandler:hK.NodeHttpHandler.create(e?.requestHandler??r),retryMode:e?.retryMode??(0,bu.loadConfig)({...pK.NODE_RETRY_MODE_CONFIG_OPTIONS,default:async()=>(await r()).retryMode||xke.DEFAULT_RETRY_MODE},e),sha256:e?.sha256??vke.Hash.bind(null,"sha256"),streamCollector:e?.streamCollector??hK.streamCollector,useDualstackEndpoint:e?.useDualstackEndpoint??(0,bu.loadConfig)(sE.NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS,i),useFipsEndpoint:e?.useFipsEndpoint??(0,bu.loadConfig)(sE.NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS,i),userAgentAppId:e?.userAgentAppId??(0,bu.loadConfig)(dK.NODE_APP_ID_CONFIG_OPTIONS,i)}};aE.getRuntimeConfig=Oke});var BK=E(Tn=>{"use strict";var gK=af(),Ike=cf(),Dke=uf(),yK=du(),kke=si(),Kh=(wn(),Ve(ou)),Mf=(xt(),Ve(V_)),Nke=hf(),Jh=ao(),_K=co(),fo=Ge(),bK=KD(),Mke=mK(),EK=yu(),wK=St(),Lke=e=>Object.assign(e,{useDualstackEndpoint:e.useDualstackEndpoint??!1,useFipsEndpoint:e.useFipsEndpoint??!1,defaultSigningName:"awsssoportal"}),fE={UseFIPS:{type:"builtInParams",name:"useFipsEndpoint"},Endpoint:{type:"builtInParams",name:"endpoint"},Region:{type:"builtInParams",name:"region"},UseDualStack:{type:"builtInParams",name:"useDualstackEndpoint"}},Bke=e=>{let t=e.httpAuthSchemes,r=e.httpAuthSchemeProvider,n=e.credentials;return{setHttpAuthScheme(i){let o=t.findIndex(s=>s.schemeId===i.schemeId);o===-1?t.push(i):t.splice(o,1,i)},httpAuthSchemes(){return t},setHttpAuthSchemeProvider(i){r=i},httpAuthSchemeProvider(){return r},setCredentials(i){n=i},credentials(){return n}}},Fke=e=>({httpAuthSchemes:e.httpAuthSchemes(),httpAuthSchemeProvider:e.httpAuthSchemeProvider(),credentials:e.credentials()}),qke=(e,t)=>{let r=Object.assign(EK.getAwsRegionExtensionConfiguration(e),fo.getDefaultExtensionConfiguration(e),wK.getHttpHandlerExtensionConfiguration(e),Bke(e));return t.forEach(n=>n.configure(r)),Object.assign(e,EK.resolveAwsRegionExtensionConfiguration(r),fo.resolveDefaultRuntimeConfig(r),wK.resolveHttpHandlerRuntimeConfig(r),Fke(r))},Nf=class extends fo.Client{config;constructor(...[t]){let r=Mke.getRuntimeConfig(t||{});super(r),this.initConfig=r;let n=Lke(r),i=yK.resolveUserAgentConfig(n),o=_K.resolveRetryConfig(i),s=kke.resolveRegionConfig(o),a=gK.resolveHostHeaderConfig(s),c=Jh.resolveEndpointConfig(a),u=bK.resolveHttpAuthSchemeConfig(c),l=qke(u,t?.extensions||[]);this.config=l,this.middlewareStack.use(Mf.getSchemaSerdePlugin(this.config)),this.middlewareStack.use(yK.getUserAgentPlugin(this.config)),this.middlewareStack.use(_K.getRetryPlugin(this.config)),this.middlewareStack.use(Nke.getContentLengthPlugin(this.config)),this.middlewareStack.use(gK.getHostHeaderPlugin(this.config)),this.middlewareStack.use(Ike.getLoggerPlugin(this.config)),this.middlewareStack.use(Dke.getRecursionDetectionPlugin(this.config)),this.middlewareStack.use(Kh.getHttpAuthSchemeEndpointRuleSetPlugin(this.config,{httpAuthSchemeParametersProvider:bK.defaultSSOHttpAuthSchemeParametersProvider,identityProviderConfigProvider:async d=>new Kh.DefaultIdentityProviderConfig({"aws.auth#sigv4":d.credentials})})),this.middlewareStack.use(Kh.getHttpSigningPlugin(this.config))}destroy(){super.destroy()}},Lf=class SK extends fo.ServiceException{constructor(t){super(t),Object.setPrototypeOf(this,SK.prototype)}},vK=class CK extends Lf{name="InvalidRequestException";$fault="client";constructor(t){super({name:"InvalidRequestException",$fault:"client",...t}),Object.setPrototypeOf(this,CK.prototype)}},xK=class TK extends Lf{name="ResourceNotFoundException";$fault="client";constructor(t){super({name:"ResourceNotFoundException",$fault:"client",...t}),Object.setPrototypeOf(this,TK.prototype)}},AK=class RK extends Lf{name="TooManyRequestsException";$fault="client";constructor(t){super({name:"TooManyRequestsException",$fault:"client",...t}),Object.setPrototypeOf(this,RK.prototype)}},PK=class OK extends Lf{name="UnauthorizedException";$fault="client";constructor(t){super({name:"UnauthorizedException",$fault:"client",...t}),Object.setPrototypeOf(this,OK.prototype)}},jke="AccountInfo",Uke="AccountListType",Hke="AccessTokenType",$ke="GetRoleCredentials",Gke="GetRoleCredentialsRequest",zke="GetRoleCredentialsResponse",Vke="InvalidRequestException",Wke="Logout",Kke="ListAccounts",Yke="ListAccountsRequest",Xke="ListAccountRolesRequest",Jke="ListAccountRolesResponse",Qke="ListAccountsResponse",Zke="ListAccountRoles",e1e="LogoutRequest",t1e="RoleCredentials",r1e="RoleInfo",n1e="RoleListType",i1e="ResourceNotFoundException",o1e="SecretAccessKeyType",s1e="SessionTokenType",a1e="TooManyRequestsException",c1e="UnauthorizedException",dE="accountId",u1e="accessKeyId",l1e="accountList",f1e="accountName",pE="accessToken",IK="account_id",hE="client",mE="error",d1e="emailAddress",p1e="expiration",gE="http",yE="httpError",_E="httpHeader",Eu="httpQuery",bE="message",DK="maxResults",kK="max_result",EE="nextToken",NK="next_token",h1e="roleCredentials",m1e="roleList",MK="roleName",g1e="role_name",LK="smithy.ts.sdk.synthetic.com.amazonaws.sso",y1e="secretAccessKey",_1e="sessionToken",wE="x-amz-sso_bearer_token",$t="com.amazonaws.sso",SE=[0,$t,Hke,8,0],b1e=[0,$t,o1e,8,0],E1e=[0,$t,s1e,8,0],w1e=[3,$t,jke,0,[dE,f1e,d1e],[0,0,0]],S1e=[3,$t,Gke,0,[MK,dE,pE],[[0,{[Eu]:g1e}],[0,{[Eu]:IK}],[()=>SE,{[_E]:wE}]]],v1e=[3,$t,zke,0,[h1e],[[()=>I1e,0]]],C1e=[-3,$t,Vke,{[mE]:hE,[yE]:400},[bE],[0]];Mf.TypeRegistry.for($t).registerError(C1e,vK);var x1e=[3,$t,Xke,0,[EE,DK,pE,dE],[[0,{[Eu]:NK}],[1,{[Eu]:kK}],[()=>SE,{[_E]:wE}],[0,{[Eu]:IK}]]],T1e=[3,$t,Jke,0,[EE,m1e],[0,()=>F1e]],A1e=[3,$t,Yke,0,[EE,DK,pE],[[0,{[Eu]:NK}],[1,{[Eu]:kK}],[()=>SE,{[_E]:wE}]]],R1e=[3,$t,Qke,0,[EE,l1e],[0,()=>B1e]],P1e=[3,$t,e1e,0,[pE],[[()=>SE,{[_E]:wE}]]],O1e=[-3,$t,i1e,{[mE]:hE,[yE]:404},[bE],[0]];Mf.TypeRegistry.for($t).registerError(O1e,xK);var I1e=[3,$t,t1e,0,[u1e,y1e,_1e,p1e],[0,[()=>b1e,0],[()=>E1e,0],1]],D1e=[3,$t,r1e,0,[MK,dE],[0,0]],k1e=[-3,$t,a1e,{[mE]:hE,[yE]:429},[bE],[0]];Mf.TypeRegistry.for($t).registerError(k1e,AK);var N1e=[-3,$t,c1e,{[mE]:hE,[yE]:401},[bE],[0]];Mf.TypeRegistry.for($t).registerError(N1e,PK);var M1e="unit",L1e=[-3,LK,"SSOServiceException",0,[],[]];Mf.TypeRegistry.for(LK).registerError(L1e,Lf);var B1e=[1,$t,Uke,0,()=>w1e],F1e=[1,$t,n1e,0,()=>D1e],q1e=[9,$t,$ke,{[gE]:["GET","/federation/credentials",200]},()=>S1e,()=>v1e],j1e=[9,$t,Zke,{[gE]:["GET","/assignment/roles",200]},()=>x1e,()=>T1e],U1e=[9,$t,Kke,{[gE]:["GET","/assignment/accounts",200]},()=>A1e,()=>R1e],H1e=[9,$t,Wke,{[gE]:["POST","/logout",200]},()=>P1e,()=>M1e],cE=class extends fo.Command.classBuilder().ep(fE).m(function(t,r,n,i){return[Jh.getEndpointPlugin(n,t.getEndpointParameterInstructions())]}).s("SWBPortalService","GetRoleCredentials",{}).n("SSOClient","GetRoleCredentialsCommand").sc(q1e).build(){},Yh=class extends fo.Command.classBuilder().ep(fE).m(function(t,r,n,i){return[Jh.getEndpointPlugin(n,t.getEndpointParameterInstructions())]}).s("SWBPortalService","ListAccountRoles",{}).n("SSOClient","ListAccountRolesCommand").sc(j1e).build(){},Xh=class extends fo.Command.classBuilder().ep(fE).m(function(t,r,n,i){return[Jh.getEndpointPlugin(n,t.getEndpointParameterInstructions())]}).s("SWBPortalService","ListAccounts",{}).n("SSOClient","ListAccountsCommand").sc(U1e).build(){},uE=class extends fo.Command.classBuilder().ep(fE).m(function(t,r,n,i){return[Jh.getEndpointPlugin(n,t.getEndpointParameterInstructions())]}).s("SWBPortalService","Logout",{}).n("SSOClient","LogoutCommand").sc(H1e).build(){},$1e={GetRoleCredentialsCommand:cE,ListAccountRolesCommand:Yh,ListAccountsCommand:Xh,LogoutCommand:uE},lE=class extends Nf{};fo.createAggregatedClient($1e,lE);var G1e=Kh.createPaginator(Nf,Yh,"nextToken","nextToken","maxResults"),z1e=Kh.createPaginator(Nf,Xh,"nextToken","nextToken","maxResults");Object.defineProperty(Tn,"$Command",{enumerable:!0,get:function(){return fo.Command}});Object.defineProperty(Tn,"__Client",{enumerable:!0,get:function(){return fo.Client}});Tn.GetRoleCredentialsCommand=cE;Tn.InvalidRequestException=vK;Tn.ListAccountRolesCommand=Yh;Tn.ListAccountsCommand=Xh;Tn.LogoutCommand=uE;Tn.ResourceNotFoundException=xK;Tn.SSO=lE;Tn.SSOClient=Nf;Tn.SSOServiceException=Lf;Tn.TooManyRequestsException=AK;Tn.UnauthorizedException=PK;Tn.paginateListAccountRoles=G1e;Tn.paginateListAccounts=z1e});var qK=E(QD=>{"use strict";var FK=BK();Object.defineProperty(QD,"GetRoleCredentialsCommand",{enumerable:!0,get:function(){return FK.GetRoleCredentialsCommand}});Object.defineProperty(QD,"SSOClient",{enumerable:!0,get:function(){return FK.SSOClient}})});var ZD=E(CE=>{"use strict";var po=Sn(),vE=Go(),jK=(ki(),Ve(xs)),V1e=G7(),HK=e=>e&&(typeof e.sso_start_url=="string"||typeof e.sso_account_id=="string"||typeof e.sso_session=="string"||typeof e.sso_region=="string"||typeof e.sso_role_name=="string"),Qh=!1,UK=async({ssoStartUrl:e,ssoSession:t,ssoAccountId:r,ssoRegion:n,ssoRoleName:i,ssoClient:o,clientConfig:s,parentClientConfig:a,profile:c,filepath:u,configFilepath:l,ignoreCache:d,logger:h})=>{let f,p="To refresh this SSO session run aws sso login with the corresponding profile.";if(t)try{let N=await V1e.fromSso({profile:c,filepath:u,configFilepath:l,ignoreCache:d})();f={accessToken:N.token,expiresAt:new Date(N.expiration).toISOString()}}catch(N){throw new po.CredentialsProviderError(N.message,{tryNextLink:Qh,logger:h})}else try{f=await vE.getSSOTokenFromFile(e)}catch{throw new po.CredentialsProviderError(`The SSO session associated with this profile is invalid. ${p}`,{tryNextLink:Qh,logger:h})}if(new Date(f.expiresAt).getTime()-Date.now()<=0)throw new po.CredentialsProviderError(`The SSO session associated with this profile has expired. ${p}`,{tryNextLink:Qh,logger:h});let{accessToken:m}=f,{SSOClient:_,GetRoleCredentialsCommand:w}=await Promise.resolve().then(function(){return qK()}),R=o||new _(Object.assign({},s??{},{logger:s?.logger??a?.logger,region:s?.region??n,userAgentAppId:s?.userAgentAppId??a?.userAgentAppId})),v;try{v=await R.send(new w({accountId:r,roleName:i,accessToken:m}))}catch(N){throw new po.CredentialsProviderError(N,{tryNextLink:Qh,logger:h})}let{roleCredentials:{accessKeyId:y,secretAccessKey:S,sessionToken:O,expiration:M,credentialScope:A,accountId:D}={}}=v;if(!y||!S||!O||!M)throw new po.CredentialsProviderError("SSO returns an invalid temporary credential.",{tryNextLink:Qh,logger:h});let I={accessKeyId:y,secretAccessKey:S,sessionToken:O,expiration:new Date(M),...A&&{credentialScope:A},...D&&{accountId:D}};return t?jK.setCredentialFeature(I,"CREDENTIALS_SSO","s"):jK.setCredentialFeature(I,"CREDENTIALS_SSO_LEGACY","u"),I},$K=(e,t)=>{let{sso_start_url:r,sso_account_id:n,sso_region:i,sso_role_name:o}=e;if(!r||!n||!i||!o)throw new po.CredentialsProviderError(`Profile is configured with invalid SSO credentials. Required parameters "sso_account_id", "sso_region", "sso_role_name", "sso_start_url". Got ${Object.keys(e).join(", ")}
|
|
233
|
+
Reference: https://docs.aws.amazon.com/cli/latest/userguide/cli-configure-sso.html`,{tryNextLink:!1,logger:t});return e},W1e=(e={})=>async({callerClientConfig:t}={})=>{e.logger?.debug("@aws-sdk/credential-provider-sso - fromSSO");let{ssoStartUrl:r,ssoAccountId:n,ssoRegion:i,ssoRoleName:o,ssoSession:s}=e,{ssoClient:a}=e,c=vE.getProfileName({profile:e.profile??t?.profile});if(!r&&!n&&!i&&!o&&!s){let l=(await vE.parseKnownFiles(e))[c];if(!l)throw new po.CredentialsProviderError(`Profile ${c} was not found.`,{logger:e.logger});if(!HK(l))throw new po.CredentialsProviderError(`Profile ${c} is not configured with SSO credentials.`,{logger:e.logger});if(l?.sso_session){let w=(await vE.loadSsoSessionData(e))[l.sso_session],R=` configurations in profile ${c} and sso-session ${l.sso_session}`;if(i&&i!==w.sso_region)throw new po.CredentialsProviderError("Conflicting SSO region"+R,{tryNextLink:!1,logger:e.logger});if(r&&r!==w.sso_start_url)throw new po.CredentialsProviderError("Conflicting SSO start_url"+R,{tryNextLink:!1,logger:e.logger});l.sso_region=w.sso_region,l.sso_start_url=w.sso_start_url}let{sso_start_url:d,sso_account_id:h,sso_region:f,sso_role_name:p,sso_session:m}=$K(l,e.logger);return UK({ssoStartUrl:d,ssoSession:m,ssoAccountId:h,ssoRegion:f,ssoRoleName:p,ssoClient:a,clientConfig:e.clientConfig,parentClientConfig:e.parentClientConfig,profile:c,filepath:e.filepath,configFilepath:e.configFilepath,ignoreCache:e.ignoreCache,logger:e.logger})}else{if(!r||!n||!i||!o)throw new po.CredentialsProviderError('Incomplete configuration. The fromSSO() argument hash must include "ssoStartUrl", "ssoAccountId", "ssoRegion", "ssoRoleName"',{tryNextLink:!1,logger:e.logger});return UK({ssoStartUrl:r,ssoSession:s,ssoAccountId:n,ssoRegion:i,ssoRoleName:o,ssoClient:a,clientConfig:e.clientConfig,parentClientConfig:e.parentClientConfig,profile:c,filepath:e.filepath,configFilepath:e.configFilepath,ignoreCache:e.ignoreCache,logger:e.logger})}};CE.fromSSO=W1e;CE.isSsoProfile=HK;CE.validateSsoProfile=$K});function K1e(e){return{schemeId:"aws.auth#sigv4",signingProperties:{name:"signin",region:e.region},propertiesExtractor:(t,r)=>({signingProperties:{config:t,context:r}})}}function Y1e(e){return{schemeId:"smithy.api#noAuth"}}var Zh,GK,zK,VK,ek=Y(()=>{"use strict";Dr();Zh=z(an()),GK=async(e,t,r)=>({operation:(0,Zh.getSmithyContext)(t).operation,region:await(0,Zh.normalizeProvider)(e.region)()||(()=>{throw new Error("expected `region` to be configured for `aws.auth#sigv4`")})()});zK=e=>{let t=[];switch(e.operation){case"CreateOAuth2Token":{t.push(Y1e(e));break}default:t.push(K1e(e))}return t},VK=e=>{let t=Is(e);return Object.assign(t,{authSchemePreference:(0,Zh.normalizeProvider)(e.authSchemePreference??[])})}});var WK,KK,tk=Y(()=>{"use strict";WK=e=>Object.assign(e,{useDualstackEndpoint:e.useDualstackEndpoint??!1,useFipsEndpoint:e.useFipsEndpoint??!1,defaultSigningName:"signin"}),KK={UseFIPS:{type:"builtInParams",name:"useFipsEndpoint"},Endpoint:{type:"builtInParams",name:"endpoint"},Region:{type:"builtInParams",name:"region"},UseDualStack:{type:"builtInParams",name:"useDualstackEndpoint"}}});var rY,Rn,YK,wu,Bf,Qa,ho,AE,rk,XK,JK,QK,nk,ik,An,ok,xE,TE,ZK,eY,tY,X1e,nY,iY=Y(()=>{"use strict";rY="required",Rn="argv",YK="isSet",wu="booleanEquals",Bf="error",Qa="endpoint",ho="tree",AE="PartitionResult",rk="stringEquals",XK={[rY]:!0,default:!1,type:"boolean"},JK={[rY]:!1,type:"string"},QK={ref:"Endpoint"},nk={fn:wu,[Rn]:[{ref:"UseFIPS"},!0]},ik={fn:wu,[Rn]:[{ref:"UseDualStack"},!0]},An={},ok={fn:"getAttr",[Rn]:[{ref:AE},"name"]},xE={fn:wu,[Rn]:[{ref:"UseFIPS"},!1]},TE={fn:wu,[Rn]:[{ref:"UseDualStack"},!1]},ZK={fn:"getAttr",[Rn]:[{ref:AE},"supportsFIPS"]},eY={fn:wu,[Rn]:[!0,{fn:"getAttr",[Rn]:[{ref:AE},"supportsDualStack"]}]},tY=[{ref:"Region"}],X1e={version:"1.0",parameters:{UseDualStack:XK,UseFIPS:XK,Endpoint:JK,Region:JK},rules:[{conditions:[{fn:YK,[Rn]:[QK]}],rules:[{conditions:[nk],error:"Invalid Configuration: FIPS and custom endpoint are not supported",type:Bf},{rules:[{conditions:[ik],error:"Invalid Configuration: Dualstack and custom endpoint are not supported",type:Bf},{endpoint:{url:QK,properties:An,headers:An},type:Qa}],type:ho}],type:ho},{rules:[{conditions:[{fn:YK,[Rn]:tY}],rules:[{conditions:[{fn:"aws.partition",[Rn]:tY,assign:AE}],rules:[{conditions:[{fn:rk,[Rn]:[ok,"aws"]},xE,TE],endpoint:{url:"https://{Region}.signin.aws.amazon.com",properties:An,headers:An},type:Qa},{conditions:[{fn:rk,[Rn]:[ok,"aws-cn"]},xE,TE],endpoint:{url:"https://{Region}.signin.amazonaws.cn",properties:An,headers:An},type:Qa},{conditions:[{fn:rk,[Rn]:[ok,"aws-us-gov"]},xE,TE],endpoint:{url:"https://{Region}.signin.amazonaws-us-gov.com",properties:An,headers:An},type:Qa},{conditions:[nk,ik],rules:[{conditions:[{fn:wu,[Rn]:[!0,ZK]},eY],rules:[{endpoint:{url:"https://signin-fips.{Region}.{PartitionResult#dualStackDnsSuffix}",properties:An,headers:An},type:Qa}],type:ho},{error:"FIPS and DualStack are enabled, but this partition does not support one or both",type:Bf}],type:ho},{conditions:[nk,TE],rules:[{conditions:[{fn:wu,[Rn]:[ZK,!0]}],rules:[{endpoint:{url:"https://signin-fips.{Region}.{PartitionResult#dnsSuffix}",properties:An,headers:An},type:Qa}],type:ho},{error:"FIPS is enabled but this partition does not support FIPS",type:Bf}],type:ho},{conditions:[xE,ik],rules:[{conditions:[eY],rules:[{endpoint:{url:"https://signin.{Region}.{PartitionResult#dualStackDnsSuffix}",properties:An,headers:An},type:Qa}],type:ho},{error:"DualStack is enabled but this partition does not support DualStack",type:Bf}],type:ho},{endpoint:{url:"https://signin.{Region}.{PartitionResult#dnsSuffix}",properties:An,headers:An},type:Qa}],type:ho}],type:ho},{error:"Invalid Configuration: Missing Region",type:Bf}],type:ho}]},nY=X1e});var oY,Ff,J1e,sY,aY=Y(()=>{"use strict";oY=z(fu()),Ff=z(Ua());iY();J1e=new Ff.EndpointCache({size:50,params:["Endpoint","Region","UseDualStack","UseFIPS"]}),sY=(e,t={})=>J1e.get(e,()=>(0,Ff.resolveEndpoint)(nY,{endpointParams:e,logger:t.logger}));Ff.customEndpointFunctions.aws=oY.awsEndpointFunctions});var cY,uY,RE,PE,lY,fY=Y(()=>{"use strict";Dr();uu();wn();cY=z(Ge()),uY=z(qs()),RE=z(Gr()),PE=z(Cr());ek();aY();lY=e=>({apiVersion:"2023-01-01",base64Decoder:e?.base64Decoder??RE.fromBase64,base64Encoder:e?.base64Encoder??RE.toBase64,disableHostPrefix:e?.disableHostPrefix??!1,endpointProvider:e?.endpointProvider??sY,extensions:e?.extensions??[],httpAuthSchemeProvider:e?.httpAuthSchemeProvider??zK,httpAuthSchemes:e?.httpAuthSchemes??[{schemeId:"aws.auth#sigv4",identityProvider:t=>t.getIdentityProvider("aws.auth#sigv4"),signer:new bn},{schemeId:"smithy.api#noAuth",identityProvider:t=>t.getIdentityProvider("smithy.api#noAuth")||(async()=>({})),signer:new oo}],logger:e?.logger??new cY.NoOpLogger,protocol:e?.protocol??new Ma({defaultNamespace:"com.amazonaws.signin"}),serviceId:e?.serviceId??"Signin",urlParser:e?.urlParser??uY.parseUrl,utf8Decoder:e?.utf8Decoder??PE.fromUtf8,utf8Encoder:e?.utf8Encoder??PE.toUtf8})});var OE,ec,dY,IE,Za,DE,pY,hY,mY,gY,yY,_Y,bY=Y(()=>{"use strict";H0();Dr();OE=z(vf()),ec=z(si()),dY=z(Cf()),IE=z(co()),Za=z(zo()),DE=z(Ca()),pY=z(xf()),hY=z(hu());fY();mY=z(Ge()),gY=z(Pf()),yY=z(Ge()),_Y=e=>{(0,yY.emitWarningIfUnsupportedVersion)(process.version);let t=(0,gY.resolveDefaultsModeConfig)(e),r=()=>t().then(mY.loadConfigsForDefaultMode),n=lY(e);ba(process.version);let i={profile:e?.profile,logger:n.logger};return{...n,...e,runtime:"node",defaultsMode:t,authSchemePreference:e?.authSchemePreference??(0,Za.loadConfig)(wa,i),bodyLengthChecker:e?.bodyLengthChecker??pY.calculateBodyLength,defaultUserAgentProvider:e?.defaultUserAgentProvider??(0,OE.createDefaultUserAgentProvider)({serviceId:n.serviceId,clientVersion:Sf.version}),maxAttempts:e?.maxAttempts??(0,Za.loadConfig)(IE.NODE_MAX_ATTEMPT_CONFIG_OPTIONS,e),region:e?.region??(0,Za.loadConfig)(ec.NODE_REGION_CONFIG_OPTIONS,{...ec.NODE_REGION_CONFIG_FILE_OPTIONS,...i}),requestHandler:DE.NodeHttpHandler.create(e?.requestHandler??r),retryMode:e?.retryMode??(0,Za.loadConfig)({...IE.NODE_RETRY_MODE_CONFIG_OPTIONS,default:async()=>(await r()).retryMode||hY.DEFAULT_RETRY_MODE},e),sha256:e?.sha256??dY.Hash.bind(null,"sha256"),streamCollector:e?.streamCollector??DE.streamCollector,useDualstackEndpoint:e?.useDualstackEndpoint??(0,Za.loadConfig)(ec.NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS,i),useFipsEndpoint:e?.useFipsEndpoint??(0,Za.loadConfig)(ec.NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS,i),userAgentAppId:e?.userAgentAppId??(0,Za.loadConfig)(OE.NODE_APP_ID_CONFIG_OPTIONS,i)}}});var EY,wY,SY=Y(()=>{"use strict";EY=e=>{let t=e.httpAuthSchemes,r=e.httpAuthSchemeProvider,n=e.credentials;return{setHttpAuthScheme(i){let o=t.findIndex(s=>s.schemeId===i.schemeId);o===-1?t.push(i):t.splice(o,1,i)},httpAuthSchemes(){return t},setHttpAuthSchemeProvider(i){r=i},httpAuthSchemeProvider(){return r},setCredentials(i){n=i},credentials(){return n}}},wY=e=>({httpAuthSchemes:e.httpAuthSchemes(),httpAuthSchemeProvider:e.httpAuthSchemeProvider(),credentials:e.credentials()})});var kE,NE,ME,vY,CY=Y(()=>{"use strict";kE=z(yu()),NE=z(St()),ME=z(Ge());SY();vY=(e,t)=>{let r=Object.assign((0,kE.getAwsRegionExtensionConfiguration)(e),(0,ME.getDefaultExtensionConfiguration)(e),(0,NE.getHttpHandlerExtensionConfiguration)(e),EY(e));return t.forEach(n=>n.configure(r)),Object.assign(e,(0,kE.resolveAwsRegionExtensionConfiguration)(r),(0,ME.resolveDefaultRuntimeConfig)(r),(0,NE.resolveHttpHandlerRuntimeConfig)(r),wY(r))}});var LE,xY,TY,BE,AY,RY,PY,FE,sk,em,ak=Y(()=>{"use strict";LE=z(af()),xY=z(cf()),TY=z(uf()),BE=z(du()),AY=z(si());wn();xt();RY=z(hf()),PY=z(ao()),FE=z(co()),sk=z(Ge());ek();tk();bY();CY();em=class extends sk.Client{config;constructor(...[t]){let r=_Y(t||{});super(r),this.initConfig=r;let n=WK(r),i=(0,BE.resolveUserAgentConfig)(n),o=(0,FE.resolveRetryConfig)(i),s=(0,AY.resolveRegionConfig)(o),a=(0,LE.resolveHostHeaderConfig)(s),c=(0,PY.resolveEndpointConfig)(a),u=VK(c),l=vY(u,t?.extensions||[]);this.config=l,this.middlewareStack.use(Qc(this.config)),this.middlewareStack.use((0,BE.getUserAgentPlugin)(this.config)),this.middlewareStack.use((0,FE.getRetryPlugin)(this.config)),this.middlewareStack.use((0,RY.getContentLengthPlugin)(this.config)),this.middlewareStack.use((0,LE.getHostHeaderPlugin)(this.config)),this.middlewareStack.use((0,xY.getLoggerPlugin)(this.config)),this.middlewareStack.use((0,TY.getRecursionDetectionPlugin)(this.config)),this.middlewareStack.use(Yc(this.config,{httpAuthSchemeParametersProvider:GK,identityProviderConfigProvider:async d=>new Os({"aws.auth#sigv4":d.credentials})})),this.middlewareStack.use(Xc(this.config))}destroy(){super.destroy()}}});var OY,mo,qE=Y(()=>{"use strict";OY=z(Ge()),mo=class e extends OY.ServiceException{constructor(t){super(t),Object.setPrototypeOf(this,e.prototype)}}});var tm,rm,nm,im,ck=Y(()=>{"use strict";qE();tm=class e extends mo{name="AccessDeniedException";$fault="client";error;constructor(t){super({name:"AccessDeniedException",$fault:"client",...t}),Object.setPrototypeOf(this,e.prototype),this.error=t.error}},rm=class e extends mo{name="InternalServerException";$fault="server";error;constructor(t){super({name:"InternalServerException",$fault:"server",...t}),Object.setPrototypeOf(this,e.prototype),this.error=t.error}},nm=class e extends mo{name="TooManyRequestsError";$fault="client";error;constructor(t){super({name:"TooManyRequestsError",$fault:"client",...t}),Object.setPrototypeOf(this,e.prototype),this.error=t.error}},im=class e extends mo{name="ValidationException";$fault="client";error;constructor(t){super({name:"ValidationException",$fault:"client",...t}),Object.setPrototypeOf(this,e.prototype),this.error=t.error}}});var Q1e,Z1e,eNe,tNe,rNe,nNe,iNe,oNe,sNe,aNe,cNe,IY,DY,uk,kY,NY,uNe,tc,MY,LY,lNe,lk,BY,wi,UE,jE,FY,fNe,qY,jY,HY,dNe,pNe,UY,zn,$Y,hNe,mNe,gNe,yNe,_Ne,bNe,ENe,wNe,SNe,vNe,GY,zY=Y(()=>{"use strict";xt();ck();qE();Q1e="AccessDeniedException",Z1e="AccessToken",eNe="CreateOAuth2Token",tNe="CreateOAuth2TokenRequest",rNe="CreateOAuth2TokenRequestBody",nNe="CreateOAuth2TokenResponseBody",iNe="CreateOAuth2TokenResponse",oNe="InternalServerException",sNe="RefreshToken",aNe="TooManyRequestsError",cNe="ValidationException",IY="accessKeyId",DY="accessToken",uk="client",kY="clientId",NY="codeVerifier",uNe="code",tc="error",MY="expiresIn",LY="grantType",lNe="http",lk="httpError",BY="idToken",wi="jsonName",UE="message",jE="refreshToken",FY="redirectUri",fNe="server",qY="secretAccessKey",jY="sessionToken",HY="smithy.ts.sdk.synthetic.com.amazonaws.signin",dNe="tokenInput",pNe="tokenOutput",UY="tokenType",zn="com.amazonaws.signin",$Y=[0,zn,sNe,8,0],hNe=[-3,zn,Q1e,{[tc]:uk},[tc,UE],[0,0]];Ue.for(zn).registerError(hNe,tm);mNe=[3,zn,Z1e,8,[IY,qY,jY],[[0,{[wi]:IY}],[0,{[wi]:qY}],[0,{[wi]:jY}]]],gNe=[3,zn,tNe,0,[dNe],[[()=>yNe,16]]],yNe=[3,zn,rNe,0,[kY,LY,uNe,FY,NY,jE],[[0,{[wi]:kY}],[0,{[wi]:LY}],0,[0,{[wi]:FY}],[0,{[wi]:NY}],[()=>$Y,{[wi]:jE}]]],_Ne=[3,zn,iNe,0,[pNe],[[()=>bNe,16]]],bNe=[3,zn,nNe,0,[DY,UY,MY,jE,BY],[[()=>mNe,{[wi]:DY}],[0,{[wi]:UY}],[1,{[wi]:MY}],[()=>$Y,{[wi]:jE}],[0,{[wi]:BY}]]],ENe=[-3,zn,oNe,{[tc]:fNe,[lk]:500},[tc,UE],[0,0]];Ue.for(zn).registerError(ENe,rm);wNe=[-3,zn,aNe,{[tc]:uk,[lk]:429},[tc,UE],[0,0]];Ue.for(zn).registerError(wNe,nm);SNe=[-3,zn,cNe,{[tc]:uk,[lk]:400},[tc,UE],[0,0]];Ue.for(zn).registerError(SNe,im);vNe=[-3,HY,"SigninServiceException",0,[],[]];Ue.for(HY).registerError(vNe,mo);GY=[9,zn,eNe,{[lNe]:["POST","/v1/token",200]},()=>gNe,()=>_Ne]});var VY,fk,om,dk=Y(()=>{"use strict";VY=z(ao()),fk=z(Ge());tk();zY();om=class extends fk.Command.classBuilder().ep(KK).m(function(t,r,n,i){return[(0,VY.getEndpointPlugin)(n,t.getEndpointParameterInstructions())]}).s("Signin","CreateOAuth2Token",{}).n("SigninClient","CreateOAuth2TokenCommand").sc(GY).build(){}});var WY,CNe,HE,KY=Y(()=>{"use strict";WY=z(Ge());dk();ak();CNe={CreateOAuth2TokenCommand:om},HE=class extends em{};(0,WY.createAggregatedClient)(CNe,HE)});var YY=Y(()=>{"use strict";dk()});var xNe,XY=Y(()=>{"use strict";xNe={AUTHCODE_EXPIRED:"AUTHCODE_EXPIRED",INSUFFICIENT_PERMISSIONS:"INSUFFICIENT_PERMISSIONS",INVALID_REQUEST:"INVALID_REQUEST",SERVER_ERROR:"server_error",TOKEN_EXPIRED:"TOKEN_EXPIRED",USER_CREDENTIALS_CHANGED:"USER_CREDENTIALS_CHANGED"}});var JY={};Nn(JY,{$Command:()=>fk.Command,AccessDeniedException:()=>tm,CreateOAuth2TokenCommand:()=>om,InternalServerException:()=>rm,OAuth2ErrorCode:()=>xNe,Signin:()=>HE,SigninClient:()=>em,SigninServiceException:()=>mo,TooManyRequestsError:()=>nm,ValidationException:()=>im,__Client:()=>sk.Client});var QY=Y(()=>{"use strict";ak();KY();YY();XY();ck();qE()});var eX=E(ZY=>{"use strict";var TNe=(ki(),Ve(xs)),rc=Sn(),mk=Go(),ANe=St(),$E=require("node:crypto"),pk=require("node:fs"),RNe=require("node:os"),hk=require("node:path"),gk=class e{profileData;init;callerClientConfig;static REFRESH_THRESHOLD=300*1e3;constructor(t,r,n){this.profileData=t,this.init=r,this.callerClientConfig=n}async loadCredentials(){let t=await this.loadToken();if(!t)throw new rc.CredentialsProviderError(`Failed to load a token for session ${this.loginSession}, please re-authenticate using aws login`,{tryNextLink:!1,logger:this.logger});let r=t.accessToken,n=Date.now();return new Date(r.expiresAt).getTime()-n<=e.REFRESH_THRESHOLD?this.refresh(t):{accessKeyId:r.accessKeyId,secretAccessKey:r.secretAccessKey,sessionToken:r.sessionToken,accountId:r.accountId,expiration:new Date(r.expiresAt)}}get logger(){return this.init?.logger}get loginSession(){return this.profileData.login_session}async refresh(t){let{SigninClient:r,CreateOAuth2TokenCommand:n}=await Promise.resolve().then(()=>(QY(),JY)),{logger:i,userAgentAppId:o}=this.callerClientConfig??{},a=(d=>d?.metadata?.handlerProtocol==="h2")(this.callerClientConfig?.requestHandler)?void 0:this.callerClientConfig?.requestHandler,c=this.profileData.region??await this.callerClientConfig?.region?.()??process.env.AWS_REGION,u=new r({credentials:{accessKeyId:"",secretAccessKey:""},region:c,requestHandler:a,logger:i,userAgentAppId:o,...this.init?.clientConfig});this.createDPoPInterceptor(u.middlewareStack);let l={tokenInput:{clientId:t.clientId,refreshToken:t.refreshToken,grantType:"refresh_token"}};try{let d=await u.send(new n(l)),{accessKeyId:h,secretAccessKey:f,sessionToken:p}=d.tokenOutput?.accessToken??{},{refreshToken:m,expiresIn:_}=d.tokenOutput??{};if(!h||!f||!p||!m)throw new rc.CredentialsProviderError("Token refresh response missing required fields",{logger:this.logger,tryNextLink:!1});let w=(_??900)*1e3,R=new Date(Date.now()+w),v={...t,accessToken:{...t.accessToken,accessKeyId:h,secretAccessKey:f,sessionToken:p,expiresAt:R.toISOString()},refreshToken:m};await this.saveToken(v);let y=v.accessToken;return{accessKeyId:y.accessKeyId,secretAccessKey:y.secretAccessKey,sessionToken:y.sessionToken,accountId:y.accountId,expiration:R}}catch(d){if(d.name==="AccessDeniedException"){let h=d.error,f;switch(h){case"TOKEN_EXPIRED":f="Your session has expired. Please reauthenticate.";break;case"USER_CREDENTIALS_CHANGED":f="Unable to refresh credentials because of a change in your password. Please reauthenticate with your new password.";break;case"INSUFFICIENT_PERMISSIONS":f="Unable to refresh credentials due to insufficient permissions. You may be missing permission for the 'CreateOAuth2Token' action.";break;default:f=`Failed to refresh token: ${String(d)}. Please re-authenticate using \`aws login\``}throw new rc.CredentialsProviderError(f,{logger:this.logger,tryNextLink:!1})}throw new rc.CredentialsProviderError(`Failed to refresh token: ${String(d)}. Please re-authenticate using aws login`,{logger:this.logger})}}async loadToken(){let t=this.getTokenFilePath();try{let r;try{r=await mk.readFile(t,{ignoreCache:this.init?.ignoreCache})}catch{r=await pk.promises.readFile(t,"utf8")}let n=JSON.parse(r),i=["accessToken","clientId","refreshToken","dpopKey"].filter(o=>!n[o]);if(n.accessToken?.accountId||i.push("accountId"),i.length>0)throw new rc.CredentialsProviderError(`Token validation failed, missing fields: ${i.join(", ")}`,{logger:this.logger,tryNextLink:!1});return n}catch(r){throw new rc.CredentialsProviderError(`Failed to load token from ${t}: ${String(r)}`,{logger:this.logger,tryNextLink:!1})}}async saveToken(t){let r=this.getTokenFilePath(),n=hk.dirname(r);try{await pk.promises.mkdir(n,{recursive:!0})}catch{}await pk.promises.writeFile(r,JSON.stringify(t,null,2),"utf8")}getTokenFilePath(){let t=process.env.AWS_LOGIN_CACHE_DIRECTORY??hk.join(RNe.homedir(),".aws","login","cache"),r=Buffer.from(this.loginSession,"utf8"),n=$E.createHash("sha256").update(r).digest("hex");return hk.join(t,`${n}.json`)}derToRawSignature(t){let r=2;if(t[r]!==2)throw new Error("Invalid DER signature");r++;let n=t[r++],i=t.subarray(r,r+n);if(r+=n,t[r]!==2)throw new Error("Invalid DER signature");r++;let o=t[r++],s=t.subarray(r,r+o);i=i[0]===0?i.subarray(1):i,s=s[0]===0?s.subarray(1):s;let a=Buffer.concat([Buffer.alloc(32-i.length),i]),c=Buffer.concat([Buffer.alloc(32-s.length),s]);return Buffer.concat([a,c])}createDPoPInterceptor(t){t.add(r=>async n=>{if(ANe.HttpRequest.isInstance(n.request)){let i=n.request,o=`${i.protocol}//${i.hostname}${i.port?`:${i.port}`:""}${i.path}`,s=await this.generateDpop(i.method,o);i.headers={...i.headers,DPoP:s}}return r(n)},{step:"finalizeRequest",name:"dpopInterceptor",override:!0})}async generateDpop(t="POST",r){let n=await this.loadToken();try{let i=$E.createPrivateKey({key:n.dpopKey,format:"pem",type:"sec1"}),s=$E.createPublicKey(i).export({format:"der",type:"spki"}),a=-1;for(let R=0;R<s.length;R++)if(s[R]===4){a=R;break}let c=s.slice(a+1,a+33),u=s.slice(a+33,a+65),l={alg:"ES256",typ:"dpop+jwt",jwk:{kty:"EC",crv:"P-256",x:c.toString("base64url"),y:u.toString("base64url")}},d={jti:crypto.randomUUID(),htm:t,htu:r,iat:Math.floor(Date.now()/1e3)},h=Buffer.from(JSON.stringify(l)).toString("base64url"),f=Buffer.from(JSON.stringify(d)).toString("base64url"),p=`${h}.${f}`,m=$E.sign("sha256",Buffer.from(p),i),w=this.derToRawSignature(m).toString("base64url");return`${p}.${w}`}catch(i){throw new rc.CredentialsProviderError(`Failed to generate Dpop proof: ${i instanceof Error?i.message:String(i)}`,{logger:this.logger,tryNextLink:!1})}}},PNe=e=>async({callerClientConfig:t}={})=>{e?.logger?.debug?.("@aws-sdk/credential-providers - fromLoginCredentials");let r=await mk.parseKnownFiles(e||{}),n=mk.getProfileName({profile:e?.profile??t?.profile}),i=r[n];if(!i?.login_session)throw new rc.CredentialsProviderError(`Profile ${n} does not contain login_session.`,{tryNextLink:!0,logger:e?.logger});let s=await new gk(i,e,t).loadCredentials();return TNe.setCredentialFeature(s,"CREDENTIALS_LOGIN","AD")};ZY.fromLoginCredentials=PNe});function ONe(e){return{schemeId:"aws.auth#sigv4",signingProperties:{name:"sts",region:e.region},propertiesExtractor:(t,r)=>({signingProperties:{config:t,context:r}})}}function INe(e){return{schemeId:"smithy.api#noAuth"}}var sm,tX,rX,DNe,nX,yk=Y(()=>{"use strict";Dr();sm=z(an());am();tX=async(e,t,r)=>({operation:(0,sm.getSmithyContext)(t).operation,region:await(0,sm.normalizeProvider)(e.region)()||(()=>{throw new Error("expected `region` to be configured for `aws.auth#sigv4`")})()});rX=e=>{let t=[];switch(e.operation){case"AssumeRoleWithWebIdentity":{t.push(INe(e));break}default:t.push(ONe(e))}return t},DNe=e=>Object.assign(e,{stsClientCtor:Zo}),nX=e=>{let t=DNe(e),r=Is(t);return Object.assign(r,{authSchemePreference:(0,sm.normalizeProvider)(e.authSchemePreference??[])})}});var iX,GE,zE=Y(()=>{"use strict";iX=e=>Object.assign(e,{useDualstackEndpoint:e.useDualstackEndpoint??!1,useFipsEndpoint:e.useFipsEndpoint??!1,useGlobalEndpoint:e.useGlobalEndpoint??!1,defaultSigningName:"sts"}),GE={UseGlobalEndpoint:{type:"builtInParams",name:"useGlobalEndpoint"},UseFIPS:{type:"builtInParams",name:"useFipsEndpoint"},Endpoint:{type:"builtInParams",name:"endpoint"},Region:{type:"builtInParams",name:"region"},UseDualStack:{type:"builtInParams",name:"useDualstackEndpoint"}}});var mX,Ke,vt,nc,ln,gX,yX,rr,oX,es,qf,bk,sX,_k,_X,aX,fn,cX,bX,EX,Pn,Si,uX,wX,SX,lX,vX,fX,dX,pX,hX,kNe,CX,xX=Y(()=>{"use strict";mX="required",Ke="type",vt="argv",nc="booleanEquals",ln="stringEquals",gX="sigv4",yX="us-east-1",rr="endpoint",oX="https://sts.{Region}.{PartitionResult#dnsSuffix}",es="tree",qf="error",bk="getAttr",sX={[mX]:!1,[Ke]:"string"},_k={[mX]:!0,default:!1,[Ke]:"boolean"},_X={ref:"Endpoint"},aX={fn:"isSet",[vt]:[{ref:"Region"}]},fn={ref:"Region"},cX={fn:"aws.partition",[vt]:[fn],assign:"PartitionResult"},bX={ref:"UseFIPS"},EX={ref:"UseDualStack"},Pn={url:"https://sts.amazonaws.com",properties:{authSchemes:[{name:gX,signingName:"sts",signingRegion:yX}]},headers:{}},Si={},uX={conditions:[{fn:ln,[vt]:[fn,"aws-global"]}],[rr]:Pn,[Ke]:rr},wX={fn:nc,[vt]:[bX,!0]},SX={fn:nc,[vt]:[EX,!0]},lX={fn:bk,[vt]:[{ref:"PartitionResult"},"supportsFIPS"]},vX={ref:"PartitionResult"},fX={fn:nc,[vt]:[!0,{fn:bk,[vt]:[vX,"supportsDualStack"]}]},dX=[{fn:"isSet",[vt]:[_X]}],pX=[wX],hX=[SX],kNe={version:"1.0",parameters:{Region:sX,UseDualStack:_k,UseFIPS:_k,Endpoint:sX,UseGlobalEndpoint:_k},rules:[{conditions:[{fn:nc,[vt]:[{ref:"UseGlobalEndpoint"},!0]},{fn:"not",[vt]:dX},aX,cX,{fn:nc,[vt]:[bX,!1]},{fn:nc,[vt]:[EX,!1]}],rules:[{conditions:[{fn:ln,[vt]:[fn,"ap-northeast-1"]}],endpoint:Pn,[Ke]:rr},{conditions:[{fn:ln,[vt]:[fn,"ap-south-1"]}],endpoint:Pn,[Ke]:rr},{conditions:[{fn:ln,[vt]:[fn,"ap-southeast-1"]}],endpoint:Pn,[Ke]:rr},{conditions:[{fn:ln,[vt]:[fn,"ap-southeast-2"]}],endpoint:Pn,[Ke]:rr},uX,{conditions:[{fn:ln,[vt]:[fn,"ca-central-1"]}],endpoint:Pn,[Ke]:rr},{conditions:[{fn:ln,[vt]:[fn,"eu-central-1"]}],endpoint:Pn,[Ke]:rr},{conditions:[{fn:ln,[vt]:[fn,"eu-north-1"]}],endpoint:Pn,[Ke]:rr},{conditions:[{fn:ln,[vt]:[fn,"eu-west-1"]}],endpoint:Pn,[Ke]:rr},{conditions:[{fn:ln,[vt]:[fn,"eu-west-2"]}],endpoint:Pn,[Ke]:rr},{conditions:[{fn:ln,[vt]:[fn,"eu-west-3"]}],endpoint:Pn,[Ke]:rr},{conditions:[{fn:ln,[vt]:[fn,"sa-east-1"]}],endpoint:Pn,[Ke]:rr},{conditions:[{fn:ln,[vt]:[fn,yX]}],endpoint:Pn,[Ke]:rr},{conditions:[{fn:ln,[vt]:[fn,"us-east-2"]}],endpoint:Pn,[Ke]:rr},{conditions:[{fn:ln,[vt]:[fn,"us-west-1"]}],endpoint:Pn,[Ke]:rr},{conditions:[{fn:ln,[vt]:[fn,"us-west-2"]}],endpoint:Pn,[Ke]:rr},{endpoint:{url:oX,properties:{authSchemes:[{name:gX,signingName:"sts",signingRegion:"{Region}"}]},headers:Si},[Ke]:rr}],[Ke]:es},{conditions:dX,rules:[{conditions:pX,error:"Invalid Configuration: FIPS and custom endpoint are not supported",[Ke]:qf},{conditions:hX,error:"Invalid Configuration: Dualstack and custom endpoint are not supported",[Ke]:qf},{endpoint:{url:_X,properties:Si,headers:Si},[Ke]:rr}],[Ke]:es},{conditions:[aX],rules:[{conditions:[cX],rules:[{conditions:[wX,SX],rules:[{conditions:[{fn:nc,[vt]:[!0,lX]},fX],rules:[{endpoint:{url:"https://sts-fips.{Region}.{PartitionResult#dualStackDnsSuffix}",properties:Si,headers:Si},[Ke]:rr}],[Ke]:es},{error:"FIPS and DualStack are enabled, but this partition does not support one or both",[Ke]:qf}],[Ke]:es},{conditions:pX,rules:[{conditions:[{fn:nc,[vt]:[lX,!0]}],rules:[{conditions:[{fn:ln,[vt]:[{fn:bk,[vt]:[vX,"name"]},"aws-us-gov"]}],endpoint:{url:"https://sts.{Region}.amazonaws.com",properties:Si,headers:Si},[Ke]:rr},{endpoint:{url:"https://sts-fips.{Region}.{PartitionResult#dnsSuffix}",properties:Si,headers:Si},[Ke]:rr}],[Ke]:es},{error:"FIPS is enabled but this partition does not support FIPS",[Ke]:qf}],[Ke]:es},{conditions:hX,rules:[{conditions:[fX],rules:[{endpoint:{url:"https://sts.{Region}.{PartitionResult#dualStackDnsSuffix}",properties:Si,headers:Si},[Ke]:rr}],[Ke]:es},{error:"DualStack is enabled but this partition does not support DualStack",[Ke]:qf}],[Ke]:es},uX,{endpoint:{url:oX,properties:Si,headers:Si},[Ke]:rr}],[Ke]:es}],[Ke]:es},{error:"Invalid Configuration: Missing Region",[Ke]:qf}]},CX=kNe});var TX,jf,NNe,AX,RX=Y(()=>{"use strict";TX=z(fu()),jf=z(Ua());xX();NNe=new jf.EndpointCache({size:50,params:["Endpoint","Region","UseDualStack","UseFIPS","UseGlobalEndpoint"]}),AX=(e,t={})=>NNe.get(e,()=>(0,jf.resolveEndpoint)(CX,{endpointParams:e,logger:t.logger}));jf.customEndpointFunctions.aws=TX.awsEndpointFunctions});var PX,OX,VE,WE,IX,DX=Y(()=>{"use strict";Dr();uu();wn();PX=z(Ge()),OX=z(qs()),VE=z(Gr()),WE=z(Cr());yk();RX();IX=e=>({apiVersion:"2011-06-15",base64Decoder:e?.base64Decoder??VE.fromBase64,base64Encoder:e?.base64Encoder??VE.toBase64,disableHostPrefix:e?.disableHostPrefix??!1,endpointProvider:e?.endpointProvider??AX,extensions:e?.extensions??[],httpAuthSchemeProvider:e?.httpAuthSchemeProvider??rX,httpAuthSchemes:e?.httpAuthSchemes??[{schemeId:"aws.auth#sigv4",identityProvider:t=>t.getIdentityProvider("aws.auth#sigv4"),signer:new bn},{schemeId:"smithy.api#noAuth",identityProvider:t=>t.getIdentityProvider("smithy.api#noAuth")||(async()=>({})),signer:new oo}],logger:e?.logger??new PX.NoOpLogger,protocol:e?.protocol??new Ba({defaultNamespace:"com.amazonaws.sts",xmlNamespace:"https://sts.amazonaws.com/doc/2011-06-15/",version:"2011-06-15"}),serviceId:e?.serviceId??"STS",urlParser:e?.urlParser??OX.parseUrl,utf8Decoder:e?.utf8Decoder??WE.fromUtf8,utf8Encoder:e?.utf8Encoder??WE.toUtf8})});var KE,sc,kX,YE,oc,XE,NX,MX,LX,BX,FX,qX,jX=Y(()=>{"use strict";H0();Dr();KE=z(vf()),sc=z(si());wn();kX=z(Cf()),YE=z(co()),oc=z(zo()),XE=z(Ca()),NX=z(xf()),MX=z(hu());DX();LX=z(Ge()),BX=z(Pf()),FX=z(Ge()),qX=e=>{(0,FX.emitWarningIfUnsupportedVersion)(process.version);let t=(0,BX.resolveDefaultsModeConfig)(e),r=()=>t().then(LX.loadConfigsForDefaultMode),n=IX(e);ba(process.version);let i={profile:e?.profile,logger:n.logger};return{...n,...e,runtime:"node",defaultsMode:t,authSchemePreference:e?.authSchemePreference??(0,oc.loadConfig)(wa,i),bodyLengthChecker:e?.bodyLengthChecker??NX.calculateBodyLength,defaultUserAgentProvider:e?.defaultUserAgentProvider??(0,KE.createDefaultUserAgentProvider)({serviceId:n.serviceId,clientVersion:Sf.version}),httpAuthSchemes:e?.httpAuthSchemes??[{schemeId:"aws.auth#sigv4",identityProvider:o=>o.getIdentityProvider("aws.auth#sigv4")||(async s=>await e.credentialDefaultProvider(s?.__config||{})()),signer:new bn},{schemeId:"smithy.api#noAuth",identityProvider:o=>o.getIdentityProvider("smithy.api#noAuth")||(async()=>({})),signer:new oo}],maxAttempts:e?.maxAttempts??(0,oc.loadConfig)(YE.NODE_MAX_ATTEMPT_CONFIG_OPTIONS,e),region:e?.region??(0,oc.loadConfig)(sc.NODE_REGION_CONFIG_OPTIONS,{...sc.NODE_REGION_CONFIG_FILE_OPTIONS,...i}),requestHandler:XE.NodeHttpHandler.create(e?.requestHandler??r),retryMode:e?.retryMode??(0,oc.loadConfig)({...YE.NODE_RETRY_MODE_CONFIG_OPTIONS,default:async()=>(await r()).retryMode||MX.DEFAULT_RETRY_MODE},e),sha256:e?.sha256??kX.Hash.bind(null,"sha256"),streamCollector:e?.streamCollector??XE.streamCollector,useDualstackEndpoint:e?.useDualstackEndpoint??(0,oc.loadConfig)(sc.NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS,i),useFipsEndpoint:e?.useFipsEndpoint??(0,oc.loadConfig)(sc.NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS,i),userAgentAppId:e?.userAgentAppId??(0,oc.loadConfig)(KE.NODE_APP_ID_CONFIG_OPTIONS,i)}}});var UX,HX,$X=Y(()=>{"use strict";UX=e=>{let t=e.httpAuthSchemes,r=e.httpAuthSchemeProvider,n=e.credentials;return{setHttpAuthScheme(i){let o=t.findIndex(s=>s.schemeId===i.schemeId);o===-1?t.push(i):t.splice(o,1,i)},httpAuthSchemes(){return t},setHttpAuthSchemeProvider(i){r=i},httpAuthSchemeProvider(){return r},setCredentials(i){n=i},credentials(){return n}}},HX=e=>({httpAuthSchemes:e.httpAuthSchemes(),httpAuthSchemeProvider:e.httpAuthSchemeProvider(),credentials:e.credentials()})});var JE,QE,ZE,GX,zX=Y(()=>{"use strict";JE=z(yu()),QE=z(St()),ZE=z(Ge());$X();GX=(e,t)=>{let r=Object.assign((0,JE.getAwsRegionExtensionConfiguration)(e),(0,ZE.getDefaultExtensionConfiguration)(e),(0,QE.getHttpHandlerExtensionConfiguration)(e),UX(e));return t.forEach(n=>n.configure(r)),Object.assign(e,(0,JE.resolveAwsRegionExtensionConfiguration)(r),(0,ZE.resolveDefaultRuntimeConfig)(r),(0,QE.resolveHttpHandlerRuntimeConfig)(r),HX(r))}});var ew,VX,WX,tw,KX,YX,XX,rw,Ek,Zo,am=Y(()=>{"use strict";ew=z(af()),VX=z(cf()),WX=z(uf()),tw=z(du()),KX=z(si());wn();xt();YX=z(hf()),XX=z(ao()),rw=z(co()),Ek=z(Ge());yk();zE();jX();zX();Zo=class extends Ek.Client{config;constructor(...[t]){let r=qX(t||{});super(r),this.initConfig=r;let n=iX(r),i=(0,tw.resolveUserAgentConfig)(n),o=(0,rw.resolveRetryConfig)(i),s=(0,KX.resolveRegionConfig)(o),a=(0,ew.resolveHostHeaderConfig)(s),c=(0,XX.resolveEndpointConfig)(a),u=nX(c),l=GX(u,t?.extensions||[]);this.config=l,this.middlewareStack.use(Qc(this.config)),this.middlewareStack.use((0,tw.getUserAgentPlugin)(this.config)),this.middlewareStack.use((0,rw.getRetryPlugin)(this.config)),this.middlewareStack.use((0,YX.getContentLengthPlugin)(this.config)),this.middlewareStack.use((0,ew.getHostHeaderPlugin)(this.config)),this.middlewareStack.use((0,VX.getLoggerPlugin)(this.config)),this.middlewareStack.use((0,WX.getRecursionDetectionPlugin)(this.config)),this.middlewareStack.use(Yc(this.config,{httpAuthSchemeParametersProvider:tX,identityProviderConfigProvider:async d=>new Os({"aws.auth#sigv4":d.credentials})})),this.middlewareStack.use(Xc(this.config))}destroy(){super.destroy()}}});var JX,ci,nw=Y(()=>{"use strict";JX=z(Ge()),ci=class e extends JX.ServiceException{constructor(t){super(t),Object.setPrototypeOf(this,e.prototype)}}});var cm,um,lm,fm,dm,pm,hm,wk=Y(()=>{"use strict";nw();cm=class e extends ci{name="ExpiredTokenException";$fault="client";constructor(t){super({name:"ExpiredTokenException",$fault:"client",...t}),Object.setPrototypeOf(this,e.prototype)}},um=class e extends ci{name="MalformedPolicyDocumentException";$fault="client";constructor(t){super({name:"MalformedPolicyDocumentException",$fault:"client",...t}),Object.setPrototypeOf(this,e.prototype)}},lm=class e extends ci{name="PackedPolicyTooLargeException";$fault="client";constructor(t){super({name:"PackedPolicyTooLargeException",$fault:"client",...t}),Object.setPrototypeOf(this,e.prototype)}},fm=class e extends ci{name="RegionDisabledException";$fault="client";constructor(t){super({name:"RegionDisabledException",$fault:"client",...t}),Object.setPrototypeOf(this,e.prototype)}},dm=class e extends ci{name="IDPRejectedClaimException";$fault="client";constructor(t){super({name:"IDPRejectedClaimException",$fault:"client",...t}),Object.setPrototypeOf(this,e.prototype)}},pm=class e extends ci{name="InvalidIdentityTokenException";$fault="client";constructor(t){super({name:"InvalidIdentityTokenException",$fault:"client",...t}),Object.setPrototypeOf(this,e.prototype)}},hm=class e extends ci{name="IDPCommunicationErrorException";$fault="client";constructor(t){super({name:"IDPCommunicationErrorException",$fault:"client",...t}),Object.setPrototypeOf(this,e.prototype)}}});var MNe,LNe,BNe,FNe,qNe,jNe,Sk,UNe,HNe,$Ne,GNe,vk,zNe,QX,VNe,WNe,KNe,YNe,XNe,JNe,QNe,ZNe,ZX,eJ,eMe,tMe,rMe,nMe,iMe,oMe,tJ,sMe,aMe,rJ,cMe,nJ,uMe,lMe,Ck,fMe,dMe,pMe,hMe,mMe,gMe,yMe,_Me,bMe,EMe,Su,vu,wMe,Cu,xu,Tu,SMe,iJ,vMe,Pt,CMe,xMe,oJ,TMe,AMe,RMe,PMe,sJ,OMe,IMe,DMe,kMe,NMe,MMe,LMe,BMe,FMe,qMe,jMe,aJ,UMe,HMe,cJ,uJ,xk=Y(()=>{"use strict";xt();wk();nw();MNe="Arn",LNe="AccessKeyId",BNe="AssumeRole",FNe="AssumedRoleId",qNe="AssumeRoleRequest",jNe="AssumeRoleResponse",Sk="AssumedRoleUser",UNe="AssumeRoleWithWebIdentity",HNe="AssumeRoleWithWebIdentityRequest",$Ne="AssumeRoleWithWebIdentityResponse",GNe="Audience",vk="Credentials",zNe="ContextAssertion",QX="DurationSeconds",VNe="Expiration",WNe="ExternalId",KNe="ExpiredTokenException",YNe="IDPCommunicationErrorException",XNe="IDPRejectedClaimException",JNe="InvalidIdentityTokenException",QNe="Key",ZNe="MalformedPolicyDocumentException",ZX="Policy",eJ="PolicyArns",eMe="ProviderArn",tMe="ProvidedContexts",rMe="ProvidedContextsListType",nMe="ProvidedContext",iMe="PolicyDescriptorType",oMe="ProviderId",tJ="PackedPolicySize",sMe="PackedPolicyTooLargeException",aMe="Provider",rJ="RoleArn",cMe="RegionDisabledException",nJ="RoleSessionName",uMe="SecretAccessKey",lMe="SubjectFromWebIdentityToken",Ck="SourceIdentity",fMe="SerialNumber",dMe="SessionToken",pMe="Tags",hMe="TokenCode",mMe="TransitiveTagKeys",gMe="Tag",yMe="Value",_Me="WebIdentityToken",bMe="arn",EMe="accessKeySecretType",Su="awsQueryError",vu="client",wMe="clientTokenType",Cu="error",xu="httpError",Tu="message",SMe="policyDescriptorListType",iJ="smithy.ts.sdk.synthetic.com.amazonaws.sts",vMe="tagListType",Pt="com.amazonaws.sts",CMe=[0,Pt,EMe,8,0],xMe=[0,Pt,wMe,8,0],oJ=[3,Pt,Sk,0,[FNe,MNe],[0,0]],TMe=[3,Pt,qNe,0,[rJ,nJ,eJ,ZX,QX,pMe,mMe,WNe,fMe,hMe,Ck,tMe],[0,0,()=>aJ,0,1,()=>HMe,64,0,0,0,0,()=>UMe]],AMe=[3,Pt,jNe,0,[vk,Sk,tJ,Ck],[[()=>sJ,0],()=>oJ,1,0]],RMe=[3,Pt,HNe,0,[rJ,nJ,_Me,oMe,eJ,ZX,QX],[0,0,[()=>xMe,0],0,()=>aJ,0,1]],PMe=[3,Pt,$Ne,0,[vk,lMe,Sk,tJ,aMe,GNe,Ck],[[()=>sJ,0],0,()=>oJ,1,0,0,0]],sJ=[3,Pt,vk,0,[LNe,uMe,dMe,VNe],[0,[()=>CMe,0],0,4]],OMe=[-3,Pt,KNe,{[Cu]:vu,[xu]:400,[Su]:["ExpiredTokenException",400]},[Tu],[0]];Ue.for(Pt).registerError(OMe,cm);IMe=[-3,Pt,YNe,{[Cu]:vu,[xu]:400,[Su]:["IDPCommunicationError",400]},[Tu],[0]];Ue.for(Pt).registerError(IMe,hm);DMe=[-3,Pt,XNe,{[Cu]:vu,[xu]:403,[Su]:["IDPRejectedClaim",403]},[Tu],[0]];Ue.for(Pt).registerError(DMe,dm);kMe=[-3,Pt,JNe,{[Cu]:vu,[xu]:400,[Su]:["InvalidIdentityToken",400]},[Tu],[0]];Ue.for(Pt).registerError(kMe,pm);NMe=[-3,Pt,ZNe,{[Cu]:vu,[xu]:400,[Su]:["MalformedPolicyDocument",400]},[Tu],[0]];Ue.for(Pt).registerError(NMe,um);MMe=[-3,Pt,sMe,{[Cu]:vu,[xu]:400,[Su]:["PackedPolicyTooLarge",400]},[Tu],[0]];Ue.for(Pt).registerError(MMe,lm);LMe=[3,Pt,iMe,0,[bMe],[0]],BMe=[3,Pt,nMe,0,[eMe,zNe],[0,0]],FMe=[-3,Pt,cMe,{[Cu]:vu,[xu]:403,[Su]:["RegionDisabledException",403]},[Tu],[0]];Ue.for(Pt).registerError(FMe,fm);qMe=[3,Pt,gMe,0,[QNe,yMe],[0,0]],jMe=[-3,iJ,"STSServiceException",0,[],[]];Ue.for(iJ).registerError(jMe,ci);aJ=[1,Pt,SMe,0,()=>LMe],UMe=[1,Pt,rMe,0,()=>BMe],HMe=[1,Pt,vMe,0,()=>qMe],cJ=[9,Pt,BNe,0,()=>TMe,()=>AMe],uJ=[9,Pt,UNe,0,()=>RMe,()=>PMe]});var lJ,fJ,Au,iw=Y(()=>{"use strict";lJ=z(ao()),fJ=z(Ge());zE();xk();Au=class extends fJ.Command.classBuilder().ep(GE).m(function(t,r,n,i){return[(0,lJ.getEndpointPlugin)(n,t.getEndpointParameterInstructions())]}).s("AWSSecurityTokenServiceV20110615","AssumeRole",{}).n("STSClient","AssumeRoleCommand").sc(cJ).build(){}});var dJ,pJ,Ru,ow=Y(()=>{"use strict";dJ=z(ao()),pJ=z(Ge());zE();xk();Ru=class extends pJ.Command.classBuilder().ep(GE).m(function(t,r,n,i){return[(0,dJ.getEndpointPlugin)(n,t.getEndpointParameterInstructions())]}).s("AWSSecurityTokenServiceV20110615","AssumeRoleWithWebIdentity",{}).n("STSClient","AssumeRoleWithWebIdentityCommand").sc(uJ).build(){}});var hJ,$Me,sw,mJ=Y(()=>{"use strict";hJ=z(Ge());iw();ow();am();$Me={AssumeRoleCommand:Au,AssumeRoleWithWebIdentityCommand:Ru},sw=class extends Zo{};(0,hJ.createAggregatedClient)($Me,sw)});var gJ=Y(()=>{"use strict";iw();ow()});var yJ,_J,bJ,EJ,wJ,SJ,vJ=Y(()=>{"use strict";ki();yJ=z(yu());iw();ow();_J=e=>{if(typeof e?.Arn=="string"){let t=e.Arn.split(":");if(t.length>4&&t[4]!=="")return t[4]}},bJ=async(e,t,r,n={})=>{let i=typeof e=="function"?await e():e,o=typeof t=="function"?await t():t,s=await(0,yJ.stsRegionDefaultResolver)(n)();return r?.debug?.("@aws-sdk/client-sts::resolveRegion","accepting first of:",`${i} (credential provider clientConfig)`,`${o} (contextual client)`,`${s} (STS default: AWS_REGION, profile region, or us-east-1)`),i??o??s},EJ=(e,t)=>{let r,n;return async(i,o)=>{if(n=i,!r){let{logger:l=e?.parentClientConfig?.logger,profile:d=e?.parentClientConfig?.profile,region:h,requestHandler:f=e?.parentClientConfig?.requestHandler,credentialProviderLogger:p,userAgentAppId:m=e?.parentClientConfig?.userAgentAppId}=e,_=await bJ(h,e?.parentClientConfig?.region,p,{logger:l,profile:d}),w=!SJ(f);r=new t({...e,userAgentAppId:m,profile:d,credentialDefaultProvider:()=>async()=>n,region:_,requestHandler:w?f:void 0,logger:l})}let{Credentials:s,AssumedRoleUser:a}=await r.send(new Au(o));if(!s||!s.AccessKeyId||!s.SecretAccessKey)throw new Error(`Invalid response from STS.assumeRole call with role ${o.RoleArn}`);let c=_J(a),u={accessKeyId:s.AccessKeyId,secretAccessKey:s.SecretAccessKey,sessionToken:s.SessionToken,expiration:s.Expiration,...s.CredentialScope&&{credentialScope:s.CredentialScope},...c&&{accountId:c}};return Ea(u,"CREDENTIALS_STS_ASSUME_ROLE","i"),u}},wJ=(e,t)=>{let r;return async n=>{if(!r){let{logger:c=e?.parentClientConfig?.logger,profile:u=e?.parentClientConfig?.profile,region:l,requestHandler:d=e?.parentClientConfig?.requestHandler,credentialProviderLogger:h,userAgentAppId:f=e?.parentClientConfig?.userAgentAppId}=e,p=await bJ(l,e?.parentClientConfig?.region,h,{logger:c,profile:u}),m=!SJ(d);r=new t({...e,userAgentAppId:f,profile:u,region:p,requestHandler:m?d:void 0,logger:c})}let{Credentials:i,AssumedRoleUser:o}=await r.send(new Ru(n));if(!i||!i.AccessKeyId||!i.SecretAccessKey)throw new Error(`Invalid response from STS.assumeRoleWithWebIdentity call with role ${n.RoleArn}`);let s=_J(o),a={accessKeyId:i.AccessKeyId,secretAccessKey:i.SecretAccessKey,sessionToken:i.SessionToken,expiration:i.Expiration,...i.CredentialScope&&{credentialScope:i.CredentialScope},...s&&{accountId:s}};return s&&Ea(a,"RESOLVED_ACCOUNT_ID","T"),Ea(a,"CREDENTIALS_STS_ASSUME_ROLE_WEB_ID","k"),a}},SJ=e=>e?.metadata?.handlerProtocol==="h2"});var CJ,xJ,TJ,GMe,AJ=Y(()=>{"use strict";vJ();am();CJ=(e,t)=>t?class extends e{constructor(n){super(n);for(let i of t)this.middlewareStack.use(i)}}:e,xJ=(e={},t)=>EJ(e,CJ(Zo,t)),TJ=(e={},t)=>wJ(e,CJ(Zo,t)),GMe=e=>t=>e({roleAssumer:xJ(t),roleAssumerWithWebIdentity:TJ(t),...t})});var Tk={};Nn(Tk,{AssumeRoleCommand:()=>Au,AssumeRoleWithWebIdentityCommand:()=>Ru,ExpiredTokenException:()=>cm,IDPCommunicationErrorException:()=>hm,IDPRejectedClaimException:()=>dm,InvalidIdentityTokenException:()=>pm,MalformedPolicyDocumentException:()=>um,PackedPolicyTooLargeException:()=>lm,RegionDisabledException:()=>fm,STS:()=>sw,STSClient:()=>Zo,STSServiceException:()=>ci,__Client:()=>Ek.Client,decorateDefaultCredentialProvider:()=>GMe,getDefaultRoleAssumer:()=>xJ,getDefaultRoleAssumerWithWebIdentity:()=>TJ});var Ak=Y(()=>{"use strict";am();mJ();gJ();wk();AJ();nw()});var Ok=E(RJ=>{"use strict";var Pk=Go(),Rk=Sn(),zMe=require("child_process"),VMe=require("util"),WMe=(ki(),Ve(xs)),KMe=(e,t,r)=>{if(t.Version!==1)throw Error(`Profile ${e} credential_process did not return Version 1.`);if(t.AccessKeyId===void 0||t.SecretAccessKey===void 0)throw Error(`Profile ${e} credential_process returned invalid credentials.`);if(t.Expiration){let o=new Date;if(new Date(t.Expiration)<o)throw Error(`Profile ${e} credential_process returned expired credentials.`)}let n=t.AccountId;!n&&r?.[e]?.aws_account_id&&(n=r[e].aws_account_id);let i={accessKeyId:t.AccessKeyId,secretAccessKey:t.SecretAccessKey,...t.SessionToken&&{sessionToken:t.SessionToken},...t.Expiration&&{expiration:new Date(t.Expiration)},...t.CredentialScope&&{credentialScope:t.CredentialScope},...n&&{accountId:n}};return WMe.setCredentialFeature(i,"CREDENTIALS_PROCESS","w"),i},YMe=async(e,t,r)=>{let n=t[e];if(t[e]){let i=n.credential_process;if(i!==void 0){let o=VMe.promisify(Pk.externalDataInterceptor?.getTokenRecord?.().exec??zMe.exec);try{let{stdout:s}=await o(i),a;try{a=JSON.parse(s.trim())}catch{throw Error(`Profile ${e} credential_process returned invalid JSON.`)}return KMe(e,a,t)}catch(s){throw new Rk.CredentialsProviderError(s.message,{logger:r})}}else throw new Rk.CredentialsProviderError(`Profile ${e} did not contain credential_process.`,{logger:r})}else throw new Rk.CredentialsProviderError(`Profile ${e} could not be found in shared credentials file.`,{logger:r})},XMe=(e={})=>async({callerClientConfig:t}={})=>{e.logger?.debug("@aws-sdk/credential-provider-process - fromProcess");let r=await Pk.parseKnownFiles(e);return YMe(Pk.getProfileName({profile:e.profile??t?.profile}),r,e.logger)};RJ.fromProcess=XMe});var Ik=E(ts=>{"use strict";var JMe=ts&&ts.__createBinding||(Object.create?(function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}):(function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]})),QMe=ts&&ts.__setModuleDefault||(Object.create?(function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}):function(e,t){e.default=t}),ZMe=ts&&ts.__importStar||(function(){var e=function(t){return e=Object.getOwnPropertyNames||function(r){var n=[];for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(n[n.length]=i);return n},e(t)};return function(t){if(t&&t.__esModule)return t;var r={};if(t!=null)for(var n=e(t),i=0;i<n.length;i++)n[i]!=="default"&&JMe(r,t,n[i]);return QMe(r,t),r}})();Object.defineProperty(ts,"__esModule",{value:!0});ts.fromWebToken=void 0;var eLe=e=>async t=>{e.logger?.debug("@aws-sdk/credential-provider-web-identity - fromWebToken");let{roleArn:r,roleSessionName:n,webIdentityToken:i,providerId:o,policyArns:s,policy:a,durationSeconds:c}=e,{roleAssumerWithWebIdentity:u}=e;if(!u){let{getDefaultRoleAssumerWithWebIdentity:l}=await Promise.resolve().then(()=>ZMe((Ak(),Ve(Tk))));u=l({...e.clientConfig,credentialProviderLogger:e.logger,parentClientConfig:{...t?.callerClientConfig,...e.parentClientConfig}},e.clientPlugins)}return u({RoleArn:r,RoleSessionName:n??`aws-sdk-js-session-${Date.now()}`,WebIdentityToken:i,ProviderId:o,PolicyArns:s,Policy:a,DurationSeconds:c})};ts.fromWebToken=eLe});var OJ=E(aw=>{"use strict";Object.defineProperty(aw,"__esModule",{value:!0});aw.fromTokenFile=void 0;var tLe=(ki(),Ve(xs)),rLe=Sn(),nLe=Go(),iLe=require("fs"),oLe=Ik(),PJ="AWS_WEB_IDENTITY_TOKEN_FILE",sLe="AWS_ROLE_ARN",aLe="AWS_ROLE_SESSION_NAME",cLe=(e={})=>async t=>{e.logger?.debug("@aws-sdk/credential-provider-web-identity - fromTokenFile");let r=e?.webIdentityTokenFile??process.env[PJ],n=e?.roleArn??process.env[sLe],i=e?.roleSessionName??process.env[aLe];if(!r||!n)throw new rLe.CredentialsProviderError("Web identity configuration not specified",{logger:e.logger});let o=await(0,oLe.fromWebToken)({...e,webIdentityToken:nLe.externalDataInterceptor?.getTokenRecord?.()[r]??(0,iLe.readFileSync)(r,{encoding:"ascii"}),roleArn:n,roleSessionName:i})(t);return r===process.env[PJ]&&(0,tLe.setCredentialFeature)(o,"CREDENTIALS_ENV_VARS_STS_WEB_ID_TOKEN","h"),o};aw.fromTokenFile=cLe});var Dk=E(mm=>{"use strict";var IJ=OJ(),DJ=Ik();Object.keys(IJ).forEach(function(e){e!=="default"&&!Object.prototype.hasOwnProperty.call(mm,e)&&Object.defineProperty(mm,e,{enumerable:!0,get:function(){return IJ[e]}})});Object.keys(DJ).forEach(function(e){e!=="default"&&!Object.prototype.hasOwnProperty.call(mm,e)&&Object.defineProperty(mm,e,{enumerable:!0,get:function(){return DJ[e]}})})});var FJ=E(BJ=>{"use strict";var Nk=Go(),gm=Sn(),Gs=(ki(),Ve(xs)),uLe=eX(),lLe=(e,t,r)=>{let n={EcsContainer:async i=>{let{fromHttp:o}=await Promise.resolve().then(()=>z(OD())),{fromContainerMetadata:s}=await Promise.resolve().then(()=>z(Rh()));return r?.debug("@aws-sdk/credential-provider-ini - credential_source is EcsContainer"),async()=>gm.chain(o(i??{}),s(i))().then(kk)},Ec2InstanceMetadata:async i=>{r?.debug("@aws-sdk/credential-provider-ini - credential_source is Ec2InstanceMetadata");let{fromInstanceMetadata:o}=await Promise.resolve().then(()=>z(Rh()));return async()=>o(i)().then(kk)},Environment:async i=>{r?.debug("@aws-sdk/credential-provider-ini - credential_source is Environment");let{fromEnv:o}=await Promise.resolve().then(()=>z(SD()));return async()=>o(i)().then(kk)}};if(e in n)return n[e];throw new gm.CredentialsProviderError(`Unsupported credential source in profile ${t}. Got ${e}, expected EcsContainer or Ec2InstanceMetadata or Environment.`,{logger:r})},kk=e=>Gs.setCredentialFeature(e,"CREDENTIALS_PROFILE_NAMED_PROVIDER","p"),fLe=(e,{profile:t="default",logger:r}={})=>!!e&&typeof e=="object"&&typeof e.role_arn=="string"&&["undefined","string"].indexOf(typeof e.role_session_name)>-1&&["undefined","string"].indexOf(typeof e.external_id)>-1&&["undefined","string"].indexOf(typeof e.mfa_serial)>-1&&(dLe(e,{profile:t,logger:r})||pLe(e,{profile:t,logger:r})),dLe=(e,{profile:t,logger:r})=>{let n=typeof e.source_profile=="string"&&typeof e.credential_source>"u";return n&&r?.debug?.(` ${t} isAssumeRoleWithSourceProfile source_profile=${e.source_profile}`),n},pLe=(e,{profile:t,logger:r})=>{let n=typeof e.credential_source=="string"&&typeof e.source_profile>"u";return n&&r?.debug?.(` ${t} isCredentialSourceProfile credential_source=${e.credential_source}`),n},hLe=async(e,t,r,n={},i)=>{r.logger?.debug("@aws-sdk/credential-provider-ini - resolveAssumeRoleCredentials (STS)");let o=t[e],{source_profile:s,region:a}=o;if(!r.roleAssumer){let{getDefaultRoleAssumer:u}=await Promise.resolve().then(()=>(Ak(),Tk));r.roleAssumer=u({...r.clientConfig,credentialProviderLogger:r.logger,parentClientConfig:{...r?.parentClientConfig,region:a??r?.parentClientConfig?.region}},r.clientPlugins)}if(s&&s in n)throw new gm.CredentialsProviderError(`Detected a cycle attempting to resolve credentials for profile ${Nk.getProfileName(r)}. Profiles visited: `+Object.keys(n).join(", "),{logger:r.logger});r.logger?.debug(`@aws-sdk/credential-provider-ini - finding credential resolver using ${s?`source_profile=[${s}]`:`profile=[${e}]`}`);let c=s?i(s,t,r,{...n,[s]:!0},kJ(t[s]??{})):(await lLe(o.credential_source,e,r.logger)(r))();if(kJ(o))return c.then(u=>Gs.setCredentialFeature(u,"CREDENTIALS_PROFILE_SOURCE_PROFILE","o"));{let u={RoleArn:o.role_arn,RoleSessionName:o.role_session_name||`aws-sdk-js-${Date.now()}`,ExternalId:o.external_id,DurationSeconds:parseInt(o.duration_seconds||"3600",10)},{mfa_serial:l}=o;if(l){if(!r.mfaCodeProvider)throw new gm.CredentialsProviderError(`Profile ${e} requires multi-factor authentication, but no MFA code callback was provided.`,{logger:r.logger,tryNextLink:!1});u.SerialNumber=l,u.TokenCode=await r.mfaCodeProvider(l)}let d=await c;return r.roleAssumer(d,u).then(h=>Gs.setCredentialFeature(h,"CREDENTIALS_PROFILE_SOURCE_PROFILE","o"))}},kJ=e=>!e.role_arn&&!!e.credential_source,mLe=e=>!!(e&&e.login_session),gLe=async(e,t)=>{let r=await uLe.fromLoginCredentials({...t,profile:e})();return Gs.setCredentialFeature(r,"CREDENTIALS_PROFILE_LOGIN","AC")},yLe=e=>!!e&&typeof e=="object"&&typeof e.credential_process=="string",_Le=async(e,t)=>Promise.resolve().then(()=>z(Ok())).then(({fromProcess:r})=>r({...e,profile:t})().then(n=>Gs.setCredentialFeature(n,"CREDENTIALS_PROFILE_PROCESS","v"))),bLe=async(e,t,r={})=>{let{fromSSO:n}=await Promise.resolve().then(()=>z(ZD()));return n({profile:e,logger:r.logger,parentClientConfig:r.parentClientConfig,clientConfig:r.clientConfig})().then(i=>t.sso_session?Gs.setCredentialFeature(i,"CREDENTIALS_PROFILE_SSO","r"):Gs.setCredentialFeature(i,"CREDENTIALS_PROFILE_SSO_LEGACY","t"))},ELe=e=>e&&(typeof e.sso_start_url=="string"||typeof e.sso_account_id=="string"||typeof e.sso_session=="string"||typeof e.sso_region=="string"||typeof e.sso_role_name=="string"),NJ=e=>!!e&&typeof e=="object"&&typeof e.aws_access_key_id=="string"&&typeof e.aws_secret_access_key=="string"&&["undefined","string"].indexOf(typeof e.aws_session_token)>-1&&["undefined","string"].indexOf(typeof e.aws_account_id)>-1,MJ=async(e,t)=>{t?.logger?.debug("@aws-sdk/credential-provider-ini - resolveStaticCredentials");let r={accessKeyId:e.aws_access_key_id,secretAccessKey:e.aws_secret_access_key,sessionToken:e.aws_session_token,...e.aws_credential_scope&&{credentialScope:e.aws_credential_scope},...e.aws_account_id&&{accountId:e.aws_account_id}};return Gs.setCredentialFeature(r,"CREDENTIALS_PROFILE","n")},wLe=e=>!!e&&typeof e=="object"&&typeof e.web_identity_token_file=="string"&&typeof e.role_arn=="string"&&["undefined","string"].indexOf(typeof e.role_session_name)>-1,SLe=async(e,t)=>Promise.resolve().then(()=>z(Dk())).then(({fromTokenFile:r})=>r({webIdentityTokenFile:e.web_identity_token_file,roleArn:e.role_arn,roleSessionName:e.role_session_name,roleAssumerWithWebIdentity:t.roleAssumerWithWebIdentity,logger:t.logger,parentClientConfig:t.parentClientConfig})().then(n=>Gs.setCredentialFeature(n,"CREDENTIALS_PROFILE_STS_WEB_ID_TOKEN","q"))),LJ=async(e,t,r,n={},i=!1)=>{let o=t[e];if(Object.keys(n).length>0&&NJ(o))return MJ(o,r);if(i||fLe(o,{profile:e,logger:r.logger}))return hLe(e,t,r,n,LJ);if(NJ(o))return MJ(o,r);if(wLe(o))return SLe(o,r);if(yLe(o))return _Le(r,e);if(ELe(o))return await bLe(e,o,r);if(mLe(o))return gLe(e,r);throw new gm.CredentialsProviderError(`Could not resolve credentials using profile: [${e}] in configuration/credentials file(s).`,{logger:r.logger})},vLe=(e={})=>async({callerClientConfig:t}={})=>{let r={...e,parentClientConfig:{...t,...e.parentClientConfig}};r.logger?.debug("@aws-sdk/credential-provider-ini - fromIni");let n=await Nk.parseKnownFiles(r);return LJ(Nk.getProfileName({profile:e.profile??t?.profile}),n,r)};BJ.fromIni=vLe});var HJ=E(cw=>{"use strict";var Mk=SD(),ym=Sn(),CLe=Go(),qJ="AWS_EC2_METADATA_DISABLED",xLe=async e=>{let{ENV_CMDS_FULL_URI:t,ENV_CMDS_RELATIVE_URI:r,fromContainerMetadata:n,fromInstanceMetadata:i}=await Promise.resolve().then(()=>z(Rh()));if(process.env[r]||process.env[t]){e.logger?.debug("@aws-sdk/credential-provider-node - remoteProvider::fromHttp/fromContainerMetadata");let{fromHttp:o}=await Promise.resolve().then(()=>z(OD()));return ym.chain(o(e),n(e))}return process.env[qJ]&&process.env[qJ]!=="false"?async()=>{throw new ym.CredentialsProviderError("EC2 Instance Metadata Service access disabled",{logger:e.logger})}:(e.logger?.debug("@aws-sdk/credential-provider-node - remoteProvider::fromInstanceMetadata"),i(e))};function TLe(e,t){let r=ALe(e),n,i,o,s=async a=>{if(a?.forceRefresh)return await r(a);if(o?.expiration&&o?.expiration?.getTime()<Date.now()&&(o=void 0),n)await n;else if(!o||t?.(o))if(o)i||(i=r(a).then(c=>{o=c,i=void 0}));else return n=r(a).then(c=>{o=c,n=void 0}),s(a);return o};return s}var ALe=e=>async t=>{let r;for(let n of e)try{return await n(t)}catch(i){if(r=i,i?.tryNextLink)continue;throw i}throw r},jJ=!1,RLe=(e={})=>TLe([async()=>{if(e.profile??process.env[CLe.ENV_PROFILE])throw process.env[Mk.ENV_KEY]&&process.env[Mk.ENV_SECRET]&&(jJ||((e.logger?.warn&&e.logger?.constructor?.name!=="NoOpLogger"?e.logger.warn.bind(e.logger):console.warn)(`@aws-sdk/credential-provider-node - defaultProvider::fromEnv WARNING:
|
|
234
|
+
Multiple credential sources detected:
|
|
235
|
+
Both AWS_PROFILE and the pair AWS_ACCESS_KEY_ID/AWS_SECRET_ACCESS_KEY static credentials are set.
|
|
236
|
+
This SDK will proceed with the AWS_PROFILE value.
|
|
237
|
+
|
|
238
|
+
However, a future version may change this behavior to prefer the ENV static credentials.
|
|
239
|
+
Please ensure that your environment only sets either the AWS_PROFILE or the
|
|
240
|
+
AWS_ACCESS_KEY_ID/AWS_SECRET_ACCESS_KEY pair.
|
|
241
|
+
`),jJ=!0)),new ym.CredentialsProviderError("AWS_PROFILE is set, skipping fromEnv provider.",{logger:e.logger,tryNextLink:!0});return e.logger?.debug("@aws-sdk/credential-provider-node - defaultProvider::fromEnv"),Mk.fromEnv(e)()},async t=>{e.logger?.debug("@aws-sdk/credential-provider-node - defaultProvider::fromSSO");let{ssoStartUrl:r,ssoAccountId:n,ssoRegion:i,ssoRoleName:o,ssoSession:s}=e;if(!r&&!n&&!i&&!o&&!s)throw new ym.CredentialsProviderError("Skipping SSO provider in default chain (inputs do not include SSO fields).",{logger:e.logger});let{fromSSO:a}=await Promise.resolve().then(()=>z(ZD()));return a(e)(t)},async t=>{e.logger?.debug("@aws-sdk/credential-provider-node - defaultProvider::fromIni");let{fromIni:r}=await Promise.resolve().then(()=>z(FJ()));return r(e)(t)},async t=>{e.logger?.debug("@aws-sdk/credential-provider-node - defaultProvider::fromProcess");let{fromProcess:r}=await Promise.resolve().then(()=>z(Ok()));return r(e)(t)},async t=>{e.logger?.debug("@aws-sdk/credential-provider-node - defaultProvider::fromTokenFile");let{fromTokenFile:r}=await Promise.resolve().then(()=>z(Dk()));return r(e)(t)},async()=>(e.logger?.debug("@aws-sdk/credential-provider-node - defaultProvider::remoteProvider"),(await xLe(e))()),async()=>{throw new ym.CredentialsProviderError("Could not load credentials from any providers",{tryNextLink:!1,logger:e.logger})}],UJ),PLe=e=>e?.expiration!==void 0,UJ=e=>e?.expiration!==void 0&&e.expiration.getTime()-Date.now()<3e5;cw.credentialsTreatedAsExpired=UJ;cw.credentialsWillNeedRefresh=PLe;cw.defaultProvider=RLe});var oQ=E(Er=>{"use strict";var ac=n0(),$J=fI(),OLe=St(),GJ="AWS_S3_DISABLE_MULTIREGION_ACCESS_POINTS",zJ="s3_disable_multiregion_access_points",ILe={environmentVariableSelector:e=>ac.booleanSelector(e,GJ,ac.SelectorType.ENV),configFileSelector:e=>ac.booleanSelector(e,zJ,ac.SelectorType.CONFIG),default:!1},VJ="AWS_S3_USE_ARN_REGION",WJ="s3_use_arn_region",DLe={environmentVariableSelector:e=>ac.booleanSelector(e,VJ,ac.SelectorType.ENV),configFileSelector:e=>ac.booleanSelector(e,WJ,ac.SelectorType.CONFIG),default:void 0},kLe=/^[a-z0-9][a-z0-9\.\-]{1,61}[a-z0-9]$/,NLe=/(\d+\.){3}\d+/,MLe=/\.\./,KJ=/\./,LLe=/^(.+\.)?s3(-fips)?(\.dualstack)?[.-]([a-z0-9-]+)\./,YJ=/^s3(-external-1)?\.amazonaws\.com$/,Lk="amazonaws.com",BLe=e=>typeof e.bucketName=="string",FLe=e=>kLe.test(e)&&!NLe.test(e)&&!MLe.test(e),XJ=e=>{let t=e.match(LLe);return[t[4],e.replace(new RegExp(`^${t[0]}`),"")]},qLe=e=>YJ.test(e)?["us-east-1",Lk]:XJ(e),JJ=e=>YJ.test(e)?[e.replace(`.${Lk}`,""),Lk]:XJ(e),jLe=e=>{if(e.pathStyleEndpoint)throw new Error("Path-style S3 endpoint is not supported when bucket is an ARN");if(e.accelerateEndpoint)throw new Error("Accelerate endpoint is not supported when bucket is an ARN");if(!e.tlsCompatible)throw new Error("HTTPS is required when bucket is an ARN")},ULe=e=>{if(e!=="s3"&&e!=="s3-outposts"&&e!=="s3-object-lambda")throw new Error("Expect 's3' or 's3-outposts' or 's3-object-lambda' in ARN service component")},HLe=e=>{if(e!=="s3")throw new Error("Expect 's3' in Accesspoint ARN service component")},QJ=e=>{if(e!=="s3-outposts")throw new Error("Expect 's3-posts' in Outpost ARN service component")},ZJ=(e,t)=>{if(e!==t.clientPartition)throw new Error(`Partition in ARN is incompatible, got "${e}" but expected "${t.clientPartition}"`)},$Le=(e,t)=>{},Fk=e=>{if(["s3-external-1","aws-global"].includes(e))throw new Error(`Client region ${e} is not regional`)},eQ=e=>{if(!/[0-9]{12}/.exec(e))throw new Error("Access point ARN accountID does not match regex '[0-9]{12}'")},Uf=(e,t={tlsCompatible:!0})=>{if(e.length>=64||!/^[a-z0-9][a-z0-9.-]*[a-z0-9]$/.test(e)||/(\d+\.){3}\d+/.test(e)||/[.-]{2}/.test(e)||t?.tlsCompatible&&KJ.test(e))throw new Error(`Invalid DNS label ${e}`)},GLe=e=>{if(e.isCustomEndpoint){if(e.dualstackEndpoint)throw new Error("Dualstack endpoint is not supported with custom endpoint");if(e.accelerateEndpoint)throw new Error("Accelerate endpoint is not supported with custom endpoint")}},tQ=e=>{let t=e.includes(":")?":":"/",[r,...n]=e.split(t);if(r==="accesspoint"){if(n.length!==1||n[0]==="")throw new Error(`Access Point ARN should have one resource accesspoint${t}{accesspointname}`);return{accesspointName:n[0]}}else if(r==="outpost"){if(!n[0]||n[1]!=="accesspoint"||!n[2]||n.length!==3)throw new Error(`Outpost ARN should have resource outpost${t}{outpostId}${t}accesspoint${t}{accesspointName}`);let[i,o,s]=n;return{outpostId:i,accesspointName:s}}else throw new Error(`ARN resource should begin with 'accesspoint${t}' or 'outpost${t}'`)},zLe=e=>{},rQ=e=>{if(e)throw new Error("FIPS region is not supported with Outpost.")},VLe=e=>{try{e.split(".").forEach(t=>{Uf(t)})}catch{throw new Error(`"${e}" is not a DNS compatible name.`)}},Bk=e=>(GLe(e),BLe(e)?WLe(e):KLe(e)),WLe=({accelerateEndpoint:e=!1,clientRegion:t,baseHostname:r,bucketName:n,dualstackEndpoint:i=!1,fipsEndpoint:o=!1,pathStyleEndpoint:s=!1,tlsCompatible:a=!0,isCustomEndpoint:c=!1})=>{let[u,l]=c?[t,r]:qLe(r);return s||!FLe(n)||a&&KJ.test(n)?{bucketEndpoint:!1,hostname:i?`s3.dualstack.${u}.${l}`:r}:(e?r=`s3-accelerate${i?".dualstack":""}.${l}`:i&&(r=`s3.dualstack.${u}.${l}`),{bucketEndpoint:!0,hostname:`${n}.${r}`})},KLe=e=>{let{isCustomEndpoint:t,baseHostname:r,clientRegion:n}=e,i=t?r:JJ(r)[1],{pathStyleEndpoint:o,accelerateEndpoint:s=!1,fipsEndpoint:a=!1,tlsCompatible:c=!0,bucketName:u,clientPartition:l="aws"}=e;jLe({pathStyleEndpoint:o,accelerateEndpoint:s,tlsCompatible:c});let{service:d,partition:h,accountId:f,region:p,resource:m}=u;ULe(d),ZJ(h,{clientPartition:l}),eQ(f);let{accesspointName:_,outpostId:w}=tQ(m);return d==="s3-object-lambda"?YLe({...e,tlsCompatible:c,bucketName:u,accesspointName:_,hostnameSuffix:i}):p===""?XLe({...e,mrapAlias:_,hostnameSuffix:i}):w?JLe({...e,clientRegion:n,outpostId:w,accesspointName:_,hostnameSuffix:i}):QLe({...e,clientRegion:n,accesspointName:_,hostnameSuffix:i})},YLe=({dualstackEndpoint:e=!1,fipsEndpoint:t=!1,tlsCompatible:r=!0,useArnRegion:n,clientRegion:i,clientSigningRegion:o=i,accesspointName:s,bucketName:a,hostnameSuffix:c})=>{let{accountId:u,region:l,service:d}=a;Fk(i);let h=`${s}-${u}`;Uf(h,{tlsCompatible:r});let f=n?l:i,p=n?l:o;return{bucketEndpoint:!0,hostname:`${h}.${d}${t?"-fips":""}.${f}.${c}`,signingRegion:p,signingService:d}},XLe=({disableMultiregionAccessPoints:e,dualstackEndpoint:t=!1,isCustomEndpoint:r,mrapAlias:n,hostnameSuffix:i})=>{if(e===!0)throw new Error("SDK is attempting to use a MRAP ARN. Please enable to feature.");return VLe(n),{bucketEndpoint:!0,hostname:`${n}${r?"":".accesspoint.s3-global"}.${i}`,signingRegion:"*"}},JLe=({useArnRegion:e,clientRegion:t,clientSigningRegion:r=t,bucketName:n,outpostId:i,dualstackEndpoint:o=!1,fipsEndpoint:s=!1,tlsCompatible:a=!0,accesspointName:c,isCustomEndpoint:u,hostnameSuffix:l})=>{Fk(t);let d=`${c}-${n.accountId}`;Uf(d,{tlsCompatible:a});let h=e?n.region:t,f=e?n.region:r;return QJ(n.service),Uf(i,{tlsCompatible:a}),rQ(s),{bucketEndpoint:!0,hostname:`${`${d}.${i}`}${u?"":`.s3-outposts.${h}`}.${l}`,signingRegion:f,signingService:"s3-outposts"}},QLe=({useArnRegion:e,clientRegion:t,clientSigningRegion:r=t,bucketName:n,dualstackEndpoint:i=!1,fipsEndpoint:o=!1,tlsCompatible:s=!0,accesspointName:a,isCustomEndpoint:c,hostnameSuffix:u})=>{Fk(t);let l=`${a}-${n.accountId}`;Uf(l,{tlsCompatible:s});let d=e?n.region:t,h=e?n.region:r;return HLe(n.service),{bucketEndpoint:!0,hostname:`${l}${c?"":`.s3-accesspoint${o?"-fips":""}${i?".dualstack":""}.${d}`}.${u}`,signingRegion:h}},nQ=e=>(t,r)=>async n=>{let{Bucket:i}=n.input,o=e.bucketEndpoint,s=n.request;if(OLe.HttpRequest.isInstance(s)){if(e.bucketEndpoint)s.hostname=i;else if($J.validate(i)){let a=$J.parse(i),c=await e.region(),u=await e.useDualstackEndpoint(),l=await e.useFipsEndpoint(),{partition:d,signingRegion:h=c}=await e.regionInfoProvider(c,{useDualstackEndpoint:u,useFipsEndpoint:l})||{},f=await e.useArnRegion(),{hostname:p,bucketEndpoint:m,signingRegion:_,signingService:w}=Bk({bucketName:a,baseHostname:s.hostname,accelerateEndpoint:e.useAccelerateEndpoint,dualstackEndpoint:u,fipsEndpoint:l,pathStyleEndpoint:e.forcePathStyle,tlsCompatible:s.protocol==="https:",useArnRegion:f,clientPartition:d,clientSigningRegion:h,clientRegion:c,isCustomEndpoint:e.isCustomEndpoint,disableMultiregionAccessPoints:await e.disableMultiregionAccessPoints()});_&&_!==h&&(r.signing_region=_),w&&w!=="s3"&&(r.signing_service=w),s.hostname=p,o=m}else{let a=await e.region(),c=await e.useDualstackEndpoint(),u=await e.useFipsEndpoint(),{hostname:l,bucketEndpoint:d}=Bk({bucketName:i,clientRegion:a,baseHostname:s.hostname,accelerateEndpoint:e.useAccelerateEndpoint,dualstackEndpoint:c,fipsEndpoint:u,pathStyleEndpoint:e.forcePathStyle,tlsCompatible:s.protocol==="https:",isCustomEndpoint:e.isCustomEndpoint});s.hostname=l,o=d}o&&(s.path=s.path.replace(/^(\/)?[^\/]+/,""),s.path===""&&(s.path="/"))}return t({...n,request:s})},iQ={tags:["BUCKET_ENDPOINT"],name:"bucketEndpointMiddleware",relation:"before",toMiddleware:"hostHeaderMiddleware",override:!0},ZLe=e=>({applyToStack:t=>{t.addRelativeTo(nQ(e),iQ)}});function eBe(e){let{bucketEndpoint:t=!1,forcePathStyle:r=!1,useAccelerateEndpoint:n=!1,useArnRegion:i,disableMultiregionAccessPoints:o=!1}=e;return Object.assign(e,{bucketEndpoint:t,forcePathStyle:r,useAccelerateEndpoint:n,useArnRegion:typeof i=="function"?i:()=>Promise.resolve(i),disableMultiregionAccessPoints:typeof o=="function"?o:()=>Promise.resolve(o)})}Er.NODE_DISABLE_MULTIREGION_ACCESS_POINT_CONFIG_OPTIONS=ILe;Er.NODE_DISABLE_MULTIREGION_ACCESS_POINT_ENV_NAME=GJ;Er.NODE_DISABLE_MULTIREGION_ACCESS_POINT_INI_NAME=zJ;Er.NODE_USE_ARN_REGION_CONFIG_OPTIONS=DLe;Er.NODE_USE_ARN_REGION_ENV_NAME=VJ;Er.NODE_USE_ARN_REGION_INI_NAME=WJ;Er.bucketEndpointMiddleware=nQ;Er.bucketEndpointMiddlewareOptions=iQ;Er.bucketHostname=Bk;Er.getArnResources=tQ;Er.getBucketEndpointPlugin=ZLe;Er.getSuffixForArnEndpoint=JJ;Er.resolveBucketEndpointConfig=eBe;Er.validateAccountId=eQ;Er.validateDNSHostLabel=Uf;Er.validateNoDualstack=zLe;Er.validateNoFIPS=rQ;Er.validateOutpostService=QJ;Er.validatePartition=ZJ;Er.validateRegion=$Le});var lQ=E(uc=>{"use strict";var cQ=Xb(),Pu=M_(),Hf=class e{bytes;constructor(t){if(this.bytes=t,t.byteLength!==8)throw new Error("Int64 buffers must be exactly 8 bytes")}static fromNumber(t){if(t>9223372036854776e3||t<-9223372036854776e3)throw new Error(`${t} is too large (or, if negative, too small) to represent as an Int64`);let r=new Uint8Array(8);for(let n=7,i=Math.abs(Math.round(t));n>-1&&i>0;n--,i/=256)r[n]=i;return t<0&&sQ(r),new e(r)}valueOf(){let t=this.bytes.slice(0),r=t[0]&128;return r&&sQ(t),parseInt(Pu.toHex(t),16)*(r?-1:1)}toString(){return String(this.valueOf())}};function sQ(e){for(let t=0;t<8;t++)e[t]^=255;for(let t=7;t>-1&&(e[t]++,e[t]===0);t--);}var uw=class{toUtf8;fromUtf8;constructor(t,r){this.toUtf8=t,this.fromUtf8=r}format(t){let r=[];for(let o of Object.keys(t)){let s=this.fromUtf8(o);r.push(Uint8Array.from([s.byteLength]),s,this.formatHeaderValue(t[o]))}let n=new Uint8Array(r.reduce((o,s)=>o+s.byteLength,0)),i=0;for(let o of r)n.set(o,i),i+=o.byteLength;return n}formatHeaderValue(t){switch(t.type){case"boolean":return Uint8Array.from([t.value?0:1]);case"byte":return Uint8Array.from([2,t.value]);case"short":let r=new DataView(new ArrayBuffer(3));return r.setUint8(0,3),r.setInt16(1,t.value,!1),new Uint8Array(r.buffer);case"integer":let n=new DataView(new ArrayBuffer(5));return n.setUint8(0,4),n.setInt32(1,t.value,!1),new Uint8Array(n.buffer);case"long":let i=new Uint8Array(9);return i[0]=5,i.set(t.value.bytes,1),i;case"binary":let o=new DataView(new ArrayBuffer(3+t.value.byteLength));o.setUint8(0,6),o.setUint16(1,t.value.byteLength,!1);let s=new Uint8Array(o.buffer);return s.set(t.value,3),s;case"string":let a=this.fromUtf8(t.value),c=new DataView(new ArrayBuffer(3+a.byteLength));c.setUint8(0,7),c.setUint16(1,a.byteLength,!1);let u=new Uint8Array(c.buffer);return u.set(a,3),u;case"timestamp":let l=new Uint8Array(9);return l[0]=8,l.set(Hf.fromNumber(t.value.valueOf()).bytes,1),l;case"uuid":if(!uBe.test(t.value))throw new Error(`Invalid UUID received: ${t.value}`);let d=new Uint8Array(17);return d[0]=9,d.set(Pu.fromHex(t.value.replace(/\-/g,"")),1),d}}parse(t){let r={},n=0;for(;n<t.byteLength;){let i=t.getUint8(n++),o=this.toUtf8(new Uint8Array(t.buffer,t.byteOffset+n,i));switch(n+=i,t.getUint8(n++)){case 0:r[o]={type:aQ,value:!0};break;case 1:r[o]={type:aQ,value:!1};break;case 2:r[o]={type:tBe,value:t.getInt8(n++)};break;case 3:r[o]={type:rBe,value:t.getInt16(n,!1)},n+=2;break;case 4:r[o]={type:nBe,value:t.getInt32(n,!1)},n+=4;break;case 5:r[o]={type:iBe,value:new Hf(new Uint8Array(t.buffer,t.byteOffset+n,8))},n+=8;break;case 6:let s=t.getUint16(n,!1);n+=2,r[o]={type:oBe,value:new Uint8Array(t.buffer,t.byteOffset+n,s)},n+=s;break;case 7:let a=t.getUint16(n,!1);n+=2,r[o]={type:sBe,value:this.toUtf8(new Uint8Array(t.buffer,t.byteOffset+n,a))},n+=a;break;case 8:r[o]={type:aBe,value:new Date(new Hf(new Uint8Array(t.buffer,t.byteOffset+n,8)).valueOf())},n+=8;break;case 9:let c=new Uint8Array(t.buffer,t.byteOffset+n,16);n+=16,r[o]={type:cBe,value:`${Pu.toHex(c.subarray(0,4))}-${Pu.toHex(c.subarray(4,6))}-${Pu.toHex(c.subarray(6,8))}-${Pu.toHex(c.subarray(8,10))}-${Pu.toHex(c.subarray(10))}`};break;default:throw new Error("Unrecognized header type tag")}}return r}},aQ="boolean",tBe="byte",rBe="short",nBe="integer",iBe="long",oBe="binary",sBe="string",aBe="timestamp",cBe="uuid",uBe=/^[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}$/,uQ=4,cc=uQ*2,Ou=4,lBe=cc+Ou*2;function fBe({byteLength:e,byteOffset:t,buffer:r}){if(e<lBe)throw new Error("Provided message too short to accommodate event stream message overhead");let n=new DataView(r,t,e),i=n.getUint32(0,!1);if(e!==i)throw new Error("Reported message length does not match received message length");let o=n.getUint32(uQ,!1),s=n.getUint32(cc,!1),a=n.getUint32(e-Ou,!1),c=new cQ.Crc32().update(new Uint8Array(r,t,cc));if(s!==c.digest())throw new Error(`The prelude checksum specified in the message (${s}) does not match the calculated CRC32 checksum (${c.digest()})`);if(c.update(new Uint8Array(r,t+cc,e-(cc+Ou))),a!==c.digest())throw new Error(`The message checksum (${c.digest()}) did not match the expected value of ${a}`);return{headers:new DataView(r,t+cc+Ou,o),body:new Uint8Array(r,t+cc+Ou+o,i-o-(cc+Ou+Ou))}}var qk=class{headerMarshaller;messageBuffer;isEndOfStream;constructor(t,r){this.headerMarshaller=new uw(t,r),this.messageBuffer=[],this.isEndOfStream=!1}feed(t){this.messageBuffer.push(this.decode(t))}endOfStream(){this.isEndOfStream=!0}getMessage(){let t=this.messageBuffer.pop(),r=this.isEndOfStream;return{getMessage(){return t},isEndOfStream(){return r}}}getAvailableMessages(){let t=this.messageBuffer;this.messageBuffer=[];let r=this.isEndOfStream;return{getMessages(){return t},isEndOfStream(){return r}}}encode({headers:t,body:r}){let n=this.headerMarshaller.format(t),i=n.byteLength+r.byteLength+16,o=new Uint8Array(i),s=new DataView(o.buffer,o.byteOffset,o.byteLength),a=new cQ.Crc32;return s.setUint32(0,i,!1),s.setUint32(4,n.byteLength,!1),s.setUint32(8,a.update(o.subarray(0,8)).digest(),!1),o.set(n,12),o.set(r,n.byteLength+12),s.setUint32(i-4,a.update(o.subarray(8,i-4)).digest(),!1),o}decode(t){let{headers:r,body:n}=fBe(t);return{headers:this.headerMarshaller.parse(r),body:n}}formatHeaders(t){return this.headerMarshaller.format(t)}},jk=class{options;constructor(t){this.options=t}[Symbol.asyncIterator](){return this.asyncIterator()}async*asyncIterator(){for await(let t of this.options.inputStream)yield this.options.decoder.decode(t)}},Uk=class{options;constructor(t){this.options=t}[Symbol.asyncIterator](){return this.asyncIterator()}async*asyncIterator(){for await(let t of this.options.messageStream)yield this.options.encoder.encode(t);this.options.includeEndFrame&&(yield new Uint8Array(0))}},Hk=class{options;constructor(t){this.options=t}[Symbol.asyncIterator](){return this.asyncIterator()}async*asyncIterator(){for await(let t of this.options.messageStream){let r=await this.options.deserializer(t);r!==void 0&&(yield r)}}},$k=class{options;constructor(t){this.options=t}[Symbol.asyncIterator](){return this.asyncIterator()}async*asyncIterator(){for await(let t of this.options.inputStream)yield this.options.serializer(t)}};uc.EventStreamCodec=qk;uc.HeaderMarshaller=uw;uc.Int64=Hf;uc.MessageDecoderStream=jk;uc.MessageEncoderStream=Uk;uc.SmithyMessageDecoderStream=Hk;uc.SmithyMessageEncoderStream=$k});var fQ=E(Gk=>{"use strict";var _m=lQ();function dBe(e){let t=0,r=0,n=null,i=null,o=a=>{if(typeof a!="number")throw new Error("Attempted to allocate an event message where size was not a number: "+a);t=a,r=4,n=new Uint8Array(a),new DataView(n.buffer).setUint32(0,a,!1)},s=async function*(){let a=e[Symbol.asyncIterator]();for(;;){let{value:c,done:u}=await a.next();if(u){if(t)if(t===r)yield n;else throw new Error("Truncated event message received.");else return;return}let l=c.length,d=0;for(;d<l;){if(!n){let f=l-d;i||(i=new Uint8Array(4));let p=Math.min(4-r,f);if(i.set(c.slice(d,d+p),r),r+=p,d+=p,r<4)break;o(new DataView(i.buffer).getUint32(0,!1)),i=null}let h=Math.min(t-r,l-d);n.set(c.slice(d,d+h),r),r+=h,d+=h,t&&t===r&&(yield n,n=null,t=0,r=0)}}};return{[Symbol.asyncIterator]:s}}function pBe(e,t){return async function(r){let{value:n}=r.headers[":message-type"];if(n==="error"){let i=new Error(r.headers[":error-message"].value||"UnknownError");throw i.name=r.headers[":error-code"].value,i}else if(n==="exception"){let i=r.headers[":exception-type"].value,o={[i]:r},s=await e(o);if(s.$unknown){let a=new Error(t(r.body));throw a.name=i,a}throw s[i]}else if(n==="event"){let i={[r.headers[":event-type"].value]:r},o=await e(i);return o.$unknown?void 0:o}else throw Error(`Unrecognizable event type: ${r.headers[":event-type"].value}`)}}var lw=class{eventStreamCodec;utfEncoder;constructor({utf8Encoder:t,utf8Decoder:r}){this.eventStreamCodec=new _m.EventStreamCodec(t,r),this.utfEncoder=t}deserialize(t,r){let n=dBe(t);return new _m.SmithyMessageDecoderStream({messageStream:new _m.MessageDecoderStream({inputStream:n,decoder:this.eventStreamCodec}),deserializer:pBe(r,this.utfEncoder)})}serialize(t,r){return new _m.MessageEncoderStream({messageStream:new _m.SmithyMessageEncoderStream({inputStream:t,serializer:r}),encoder:this.eventStreamCodec,includeEndFrame:!0})}},hBe=e=>new lw(e);Gk.EventStreamMarshaller=lw;Gk.eventStreamSerdeProvider=hBe});var dQ=E(zk=>{"use strict";var mBe=fQ(),gBe=require("stream");async function*yBe(e){let t=!1,r=!1,n=new Array;for(e.on("error",i=>{if(t||(t=!0),i)throw i}),e.on("data",i=>{n.push(i)}),e.on("end",()=>{t=!0});!r;){let i=await new Promise(o=>setTimeout(()=>o(n.shift()),0));i&&(yield i),r=t&&n.length===0}}var fw=class{universalMarshaller;constructor({utf8Encoder:t,utf8Decoder:r}){this.universalMarshaller=new mBe.EventStreamMarshaller({utf8Decoder:r,utf8Encoder:t})}deserialize(t,r){let n=typeof t[Symbol.asyncIterator]=="function"?t:yBe(t);return this.universalMarshaller.deserialize(n,r)}serialize(t,r){return gBe.Readable.from(this.universalMarshaller.serialize(t,r))}},_Be=e=>new fw(e);zk.EventStreamMarshaller=fw;zk.eventStreamSerdeProvider=_Be});var pQ=E(Vk=>{"use strict";var bBe=require("fs"),EBe=Cr(),wBe=require("stream"),dw=class extends wBe.Writable{hash;constructor(t,r){super(r),this.hash=t}_write(t,r,n){try{this.hash.update(EBe.toUint8Array(t))}catch(i){return n(i)}n()}},SBe=(e,t)=>new Promise((r,n)=>{if(!vBe(t)){n(new Error("Unable to calculate hash for non-file streams."));return}let i=bBe.createReadStream(t.path,{start:t.start,end:t.end}),o=new e,s=new dw(o);i.pipe(s),i.on("error",a=>{s.end(),n(a)}),s.on("error",n),s.on("finish",function(){o.digest().then(r).catch(n)})}),vBe=e=>typeof e.path=="string",CBe=(e,t)=>{if(t.readableFlowing!==null)throw new Error("Unable to calculate hash for flowing readable stream");let r=new e,n=new dw(r);return t.pipe(n),new Promise((i,o)=>{t.on("error",s=>{n.end(),o(s)}),n.on("error",o),n.on("finish",()=>{r.digest().then(i).catch(o)})})};Vk.fileStreamHasher=SBe;Vk.readableStreamHasher=CBe});var _Q=E(pw=>{"use strict";Object.defineProperty(pw,"__esModule",{value:!0});pw.getRuntimeConfig=void 0;var hQ=(Dr(),Ve(Uo)),xBe=(uu(),Ve(zO)),TBe=UI(),ABe=Ge(),RBe=qs(),mQ=Gr(),gQ=Jc(),yQ=Cr(),PBe=wD(),OBe=ED(),IBe=e=>({apiVersion:"2006-03-01",base64Decoder:e?.base64Decoder??mQ.fromBase64,base64Encoder:e?.base64Encoder??mQ.toBase64,disableHostPrefix:e?.disableHostPrefix??!1,endpointProvider:e?.endpointProvider??OBe.defaultEndpointResolver,extensions:e?.extensions??[],getAwsChunkedEncodingStream:e?.getAwsChunkedEncodingStream??gQ.getAwsChunkedEncodingStream,httpAuthSchemeProvider:e?.httpAuthSchemeProvider??PBe.defaultS3HttpAuthSchemeProvider,httpAuthSchemes:e?.httpAuthSchemes??[{schemeId:"aws.auth#sigv4",identityProvider:t=>t.getIdentityProvider("aws.auth#sigv4"),signer:new hQ.AwsSdkSigV4Signer},{schemeId:"aws.auth#sigv4a",identityProvider:t=>t.getIdentityProvider("aws.auth#sigv4a"),signer:new hQ.AwsSdkSigV4ASigner}],logger:e?.logger??new ABe.NoOpLogger,protocol:e?.protocol??new xBe.AwsRestXmlProtocol({defaultNamespace:"com.amazonaws.s3",xmlNamespace:"http://s3.amazonaws.com/doc/2006-03-01/"}),sdkStreamMixin:e?.sdkStreamMixin??gQ.sdkStreamMixin,serviceId:e?.serviceId??"S3",signerConstructor:e?.signerConstructor??TBe.SignatureV4MultiRegion,signingEscapePath:e?.signingEscapePath??!1,urlParser:e?.urlParser??RBe.parseUrl,useArnRegion:e?.useArnRegion??void 0,utf8Decoder:e?.utf8Decoder??yQ.fromUtf8,utf8Encoder:e?.utf8Encoder??yQ.toUtf8});pw.getRuntimeConfig=IBe});var vQ=E(mw=>{"use strict";Object.defineProperty(mw,"__esModule",{value:!0});mw.getRuntimeConfig=void 0;var DBe=(qo(),Ve(Fo)),kBe=DBe.__importDefault(e9()),Wk=(Dr(),Ve(Uo)),NBe=HJ(),MBe=oQ(),bQ=nI(),LBe=c0(),EQ=vf(),hw=si(),BBe=dQ(),Kk=Cf(),FBe=pQ(),wQ=co(),zi=zo(),SQ=Ca(),qBe=xf(),jBe=hu(),UBe=_Q(),HBe=Ge(),$Be=Pf(),GBe=Ge(),zBe=e=>{(0,GBe.emitWarningIfUnsupportedVersion)(process.version);let t=(0,$Be.resolveDefaultsModeConfig)(e),r=()=>t().then(HBe.loadConfigsForDefaultMode),n=(0,UBe.getRuntimeConfig)(e);(0,Wk.emitWarningIfUnsupportedVersion)(process.version);let i={profile:e?.profile,logger:n.logger};return{...n,...e,runtime:"node",defaultsMode:t,authSchemePreference:e?.authSchemePreference??(0,zi.loadConfig)(Wk.NODE_AUTH_SCHEME_PREFERENCE_OPTIONS,i),bodyLengthChecker:e?.bodyLengthChecker??qBe.calculateBodyLength,credentialDefaultProvider:e?.credentialDefaultProvider??NBe.defaultProvider,defaultUserAgentProvider:e?.defaultUserAgentProvider??(0,EQ.createDefaultUserAgentProvider)({serviceId:n.serviceId,clientVersion:kBe.default.version}),disableS3ExpressSessionAuth:e?.disableS3ExpressSessionAuth??(0,zi.loadConfig)(LBe.NODE_DISABLE_S3_EXPRESS_SESSION_AUTH_OPTIONS,i),eventStreamSerdeProvider:e?.eventStreamSerdeProvider??BBe.eventStreamSerdeProvider,maxAttempts:e?.maxAttempts??(0,zi.loadConfig)(wQ.NODE_MAX_ATTEMPT_CONFIG_OPTIONS,e),md5:e?.md5??Kk.Hash.bind(null,"md5"),region:e?.region??(0,zi.loadConfig)(hw.NODE_REGION_CONFIG_OPTIONS,{...hw.NODE_REGION_CONFIG_FILE_OPTIONS,...i}),requestChecksumCalculation:e?.requestChecksumCalculation??(0,zi.loadConfig)(bQ.NODE_REQUEST_CHECKSUM_CALCULATION_CONFIG_OPTIONS,i),requestHandler:SQ.NodeHttpHandler.create(e?.requestHandler??r),responseChecksumValidation:e?.responseChecksumValidation??(0,zi.loadConfig)(bQ.NODE_RESPONSE_CHECKSUM_VALIDATION_CONFIG_OPTIONS,i),retryMode:e?.retryMode??(0,zi.loadConfig)({...wQ.NODE_RETRY_MODE_CONFIG_OPTIONS,default:async()=>(await r()).retryMode||jBe.DEFAULT_RETRY_MODE},e),sha1:e?.sha1??Kk.Hash.bind(null,"sha1"),sha256:e?.sha256??Kk.Hash.bind(null,"sha256"),sigv4aSigningRegionSet:e?.sigv4aSigningRegionSet??(0,zi.loadConfig)(Wk.NODE_SIGV4A_CONFIG_OPTIONS,i),streamCollector:e?.streamCollector??SQ.streamCollector,streamHasher:e?.streamHasher??FBe.readableStreamHasher,useArnRegion:e?.useArnRegion??(0,zi.loadConfig)(MBe.NODE_USE_ARN_REGION_CONFIG_OPTIONS,i),useDualstackEndpoint:e?.useDualstackEndpoint??(0,zi.loadConfig)(hw.NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS,i),useFipsEndpoint:e?.useFipsEndpoint??(0,zi.loadConfig)(hw.NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS,i),userAgentAppId:e?.userAgentAppId??(0,zi.loadConfig)(EQ.NODE_APP_ID_CONFIG_OPTIONS,i)}};mw.getRuntimeConfig=zBe});var AQ=E(bm=>{"use strict";function CQ(e){return t=>async r=>{let n={...r.input},i=[{target:"SSECustomerKey",hash:"SSECustomerKeyMD5"},{target:"CopySourceSSECustomerKey",hash:"CopySourceSSECustomerKeyMD5"}];for(let o of i){let s=n[o.target];if(s){let a;typeof s=="string"?TQ(s,e)?a=e.base64Decoder(s):(a=e.utf8Decoder(s),n[o.target]=e.base64Encoder(a)):(a=ArrayBuffer.isView(s)?new Uint8Array(s.buffer,s.byteOffset,s.byteLength):new Uint8Array(s),n[o.target]=e.base64Encoder(a));let c=new e.md5;c.update(a),n[o.hash]=e.base64Encoder(await c.digest())}}return t({...r,input:n})}}var xQ={name:"ssecMiddleware",step:"initialize",tags:["SSE"],override:!0},VBe=e=>({applyToStack:t=>{t.add(CQ(e),xQ)}});function TQ(e,t){if(!/^(?:[A-Za-z0-9+/]{4})*([A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/.test(e))return!1;try{return t.base64Decoder(e).length===32}catch{return!1}}bm.getSsecPlugin=VBe;bm.isValidBase64EncodedSSECustomerKey=TQ;bm.ssecMiddleware=CQ;bm.ssecMiddlewareOptions=xQ});var OQ=E(gw=>{"use strict";function RQ(e){return t=>async r=>{let{CreateBucketConfiguration:n}=r.input,i=await e.region();return!n?.LocationConstraint&&!n?.Location&&i!=="us-east-1"&&(r.input.CreateBucketConfiguration=r.input.CreateBucketConfiguration??{},r.input.CreateBucketConfiguration.LocationConstraint=i),t(r)}}var PQ={step:"initialize",tags:["LOCATION_CONSTRAINT","CREATE_BUCKET_CONFIGURATION"],name:"locationConstraintMiddleware",override:!0},WBe=e=>({applyToStack:t=>{t.add(RQ(e),PQ)}});gw.getLocationConstraintPlugin=WBe;gw.locationConstraintMiddleware=RQ;gw.locationConstraintMiddlewareOptions=PQ});var NQ=E(Vn=>{"use strict";var yw=()=>{let e=new WeakSet;return(t,r)=>{if(typeof r=="object"&&r!==null){if(e.has(r))return"[Circular]";e.add(r)}return r}},KBe=e=>new Promise(t=>setTimeout(t,e*1e3)),kQ={minDelay:2,maxDelay:120};Vn.WaiterState=void 0;(function(e){e.ABORTED="ABORTED",e.FAILURE="FAILURE",e.SUCCESS="SUCCESS",e.RETRY="RETRY",e.TIMEOUT="TIMEOUT"})(Vn.WaiterState||(Vn.WaiterState={}));var YBe=e=>{if(e.state===Vn.WaiterState.ABORTED){let t=new Error(`${JSON.stringify({...e,reason:"Request was aborted"},yw())}`);throw t.name="AbortError",t}else if(e.state===Vn.WaiterState.TIMEOUT){let t=new Error(`${JSON.stringify({...e,reason:"Waiter has timed out"},yw())}`);throw t.name="TimeoutError",t}else if(e.state!==Vn.WaiterState.SUCCESS)throw new Error(`${JSON.stringify(e,yw())}`);return e},XBe=(e,t,r,n)=>{if(n>r)return t;let i=e*2**(n-1);return JBe(e,i)},JBe=(e,t)=>e+Math.random()*(t-e),QBe=async({minDelay:e,maxDelay:t,maxWaitTime:r,abortController:n,client:i,abortSignal:o},s,a)=>{let c={},{state:u,reason:l}=await a(i,s);if(l){let p=IQ(l);c[p]|=0,c[p]+=1}if(u!==Vn.WaiterState.RETRY)return{state:u,reason:l,observedResponses:c};let d=1,h=Date.now()+r*1e3,f=Math.log(t/e)/Math.log(2)+1;for(;;){if(n?.signal?.aborted||o?.aborted){let w="AbortController signal aborted.";return c[w]|=0,c[w]+=1,{state:Vn.WaiterState.ABORTED,observedResponses:c}}let p=XBe(e,t,f,d);if(Date.now()+p*1e3>h)return{state:Vn.WaiterState.TIMEOUT,observedResponses:c};await KBe(p);let{state:m,reason:_}=await a(i,s);if(_){let w=IQ(_);c[w]|=0,c[w]+=1}if(m!==Vn.WaiterState.RETRY)return{state:m,reason:_,observedResponses:c};d+=1}},IQ=e=>e?.$responseBodyText?`Deserialization error for body: ${e.$responseBodyText}`:e?.$metadata?.httpStatusCode?e.$response||e.message?`${e.$response.statusCode??e.$metadata.httpStatusCode??"Unknown"}: ${e.message}`:`${e.$metadata.httpStatusCode}: OK`:String(e?.message??JSON.stringify(e,yw())??"Unknown"),ZBe=e=>{if(e.maxWaitTime<=0)throw new Error("WaiterConfiguration.maxWaitTime must be greater than 0");if(e.minDelay<=0)throw new Error("WaiterConfiguration.minDelay must be greater than 0");if(e.maxDelay<=0)throw new Error("WaiterConfiguration.maxDelay must be greater than 0");if(e.maxWaitTime<=e.minDelay)throw new Error(`WaiterConfiguration.maxWaitTime [${e.maxWaitTime}] must be greater than WaiterConfiguration.minDelay [${e.minDelay}] for this waiter`);if(e.maxDelay<e.minDelay)throw new Error(`WaiterConfiguration.maxDelay [${e.maxDelay}] must be greater than WaiterConfiguration.minDelay [${e.minDelay}] for this waiter`)},DQ=e=>{let t,r=new Promise(n=>{t=()=>n({state:Vn.WaiterState.ABORTED}),typeof e.addEventListener=="function"?e.addEventListener("abort",t):e.onabort=t});return{clearListener(){typeof e.removeEventListener=="function"&&e.removeEventListener("abort",t)},aborted:r}},e2e=async(e,t,r)=>{let n={...kQ,...e};ZBe(n);let i=[QBe(n,t,r)],o=[];if(e.abortSignal){let{aborted:s,clearListener:a}=DQ(e.abortSignal);o.push(a),i.push(s)}if(e.abortController?.signal){let{aborted:s,clearListener:a}=DQ(e.abortController.signal);o.push(a),i.push(s)}return Promise.race(i).then(s=>{for(let a of o)a();return s})};Vn.checkExceptions=YBe;Vn.createWaiter=e2e;Vn.waiterServiceDefaults=kQ});var tne=E(q=>{"use strict";var t2e=v4(),Ot=nI(),MQ=af(),r2e=cf(),n2e=uf(),Oe=c0(),LQ=du(),i2e=si(),Iu=(wn(),Ve(ou)),On=(xt(),Ve(V_)),o2e=Oz(),s2e=hf(),pe=ao(),BQ=co(),fe=Ge(),FQ=wD(),a2e=vQ(),qQ=yu(),jQ=St(),_o=AQ(),c2e=OQ(),dr=NQ(),u2e=e=>Object.assign(e,{useFipsEndpoint:e.useFipsEndpoint??!1,useDualstackEndpoint:e.useDualstackEndpoint??!1,forcePathStyle:e.forcePathStyle??!1,useAccelerateEndpoint:e.useAccelerateEndpoint??!1,useGlobalEndpoint:e.useGlobalEndpoint??!1,disableMultiregionAccessPoints:e.disableMultiregionAccessPoints??!1,defaultSigningName:"s3"}),he={ForcePathStyle:{type:"clientContextParams",name:"forcePathStyle"},UseArnRegion:{type:"clientContextParams",name:"useArnRegion"},DisableMultiRegionAccessPoints:{type:"clientContextParams",name:"disableMultiregionAccessPoints"},Accelerate:{type:"clientContextParams",name:"useAccelerateEndpoint"},DisableS3ExpressSessionAuth:{type:"clientContextParams",name:"disableS3ExpressSessionAuth"},UseGlobalEndpoint:{type:"builtInParams",name:"useGlobalEndpoint"},UseFIPS:{type:"builtInParams",name:"useFipsEndpoint"},Endpoint:{type:"builtInParams",name:"endpoint"},Region:{type:"builtInParams",name:"region"},UseDualStack:{type:"builtInParams",name:"useDualstackEndpoint"}},In=class JQ extends fe.ServiceException{constructor(t){super(t),Object.setPrototypeOf(this,JQ.prototype)}},QQ=class ZQ extends In{name="NoSuchUpload";$fault="client";constructor(t){super({name:"NoSuchUpload",$fault:"client",...t}),Object.setPrototypeOf(this,ZQ.prototype)}},eZ=class tZ extends In{name="ObjectNotInActiveTierError";$fault="client";constructor(t){super({name:"ObjectNotInActiveTierError",$fault:"client",...t}),Object.setPrototypeOf(this,tZ.prototype)}},rZ=class nZ extends In{name="BucketAlreadyExists";$fault="client";constructor(t){super({name:"BucketAlreadyExists",$fault:"client",...t}),Object.setPrototypeOf(this,nZ.prototype)}},iZ=class oZ extends In{name="BucketAlreadyOwnedByYou";$fault="client";constructor(t){super({name:"BucketAlreadyOwnedByYou",$fault:"client",...t}),Object.setPrototypeOf(this,oZ.prototype)}},sZ=class aZ extends In{name="NoSuchBucket";$fault="client";constructor(t){super({name:"NoSuchBucket",$fault:"client",...t}),Object.setPrototypeOf(this,aZ.prototype)}},cZ=class uZ extends In{name="InvalidObjectState";$fault="client";StorageClass;AccessTier;constructor(t){super({name:"InvalidObjectState",$fault:"client",...t}),Object.setPrototypeOf(this,uZ.prototype),this.StorageClass=t.StorageClass,this.AccessTier=t.AccessTier}},lZ=class fZ extends In{name="NoSuchKey";$fault="client";constructor(t){super({name:"NoSuchKey",$fault:"client",...t}),Object.setPrototypeOf(this,fZ.prototype)}},dZ=class pZ extends In{name="NotFound";$fault="client";constructor(t){super({name:"NotFound",$fault:"client",...t}),Object.setPrototypeOf(this,pZ.prototype)}},hZ=class mZ extends In{name="EncryptionTypeMismatch";$fault="client";constructor(t){super({name:"EncryptionTypeMismatch",$fault:"client",...t}),Object.setPrototypeOf(this,mZ.prototype)}},gZ=class yZ extends In{name="InvalidRequest";$fault="client";constructor(t){super({name:"InvalidRequest",$fault:"client",...t}),Object.setPrototypeOf(this,yZ.prototype)}},_Z=class bZ extends In{name="InvalidWriteOffset";$fault="client";constructor(t){super({name:"InvalidWriteOffset",$fault:"client",...t}),Object.setPrototypeOf(this,bZ.prototype)}},EZ=class wZ extends In{name="TooManyParts";$fault="client";constructor(t){super({name:"TooManyParts",$fault:"client",...t}),Object.setPrototypeOf(this,wZ.prototype)}},SZ=class vZ extends In{name="IdempotencyParameterMismatch";$fault="client";constructor(t){super({name:"IdempotencyParameterMismatch",$fault:"client",...t}),Object.setPrototypeOf(this,vZ.prototype)}},CZ=class xZ extends In{name="ObjectAlreadyInActiveTierError";$fault="client";constructor(t){super({name:"ObjectAlreadyInActiveTierError",$fault:"client",...t}),Object.setPrototypeOf(this,xZ.prototype)}},l2e="Account",f2e="AnalyticsAndOperator",_w="AccelerateConfiguration",Iv="AccessControlList",zf="ACL",TZ="AnalyticsConfigurationList",Du="AccessControlPolicy",AZ="AccessControlTranslation",Em="AnalyticsConfiguration",RZ="AbortDate",d2e="AnalyticsExportDestination",p2e="AnalyticsFilter",h2e="AllowedHeaders",m2e="AllowedHeader",g2e="AccountId",PZ="AbortIncompleteMultipartUpload",UQ="AccessKeyId",y2e="AllowedMethods",_2e="AbortMultipartUpload",b2e="AbortMultipartUploadOutput",E2e="AbortMultipartUploadRequest",w2e="AllowedMethod",S2e="AllowedOrigins",v2e="AllowedOrigin",C2e="AccessPointAlias",OZ="AccessPointArn",x2e="AllowQuotedRecordDelimiter",n1="AcceptRanges",IZ="AbortRuleId",bw="AbacStatus",T2e="AnalyticsS3BucketDestination",A2e="ApplyServerSideEncryptionByDefault",R2e="ArchiveStatus",DZ="AccessTier",Pm="And",le="Bucket",i1="BucketArn",P2e="BucketAlreadyExists",O2e="BucketAccountId",I2e="BucketAlreadyOwnedByYou",kZ="BlockedEncryptionTypes",o1="BypassGovernanceRetention",D2e="BucketInfo",Wn="BucketKeyEnabled",k2e="BucketLifecycleConfiguration",N2e="BucketLocationName",Ew="BucketLoggingStatus",M2e="BucketLocationType",L2e="BucketName",NZ="BytesProcessed",HQ="BlockPublicAcls",$Q="BlockPublicPolicy",s1="BucketRegion",MZ="BytesReturned",LZ="BytesScanned",Om="Body",a1="Buckets",BZ="Checksum",pt="ChecksumAlgorithm",B2e="CannedACL",F2e="CreateBucket",Yk="CreateBucketConfiguration",q2e="CreateBucketMetadataConfiguration",j2e="CreateBucketMetadataConfigurationRequest",U2e="CreateBucketMetadataTableConfiguration",H2e="CreateBucketMetadataTableConfigurationRequest",$2e="CreateBucketOutput",G2e="CreateBucketRequest",Vf="CacheControl",Kn="ChecksumCRC32",Yn="ChecksumCRC32C",Xn="ChecksumCRC64NVME",Im="Cache-Control",z2e="CreationDate",Dm="Content-Disposition",Wf="ContentDisposition",V2e="ContinuationEvent",km="Content-Encoding",Kf="ContentEncoding",W2e="CloudFunction",K2e="CloudFunctionConfiguration",Yf="ContentLanguage",Nm="Content-Language",Mm="Content-Length",Lm="ContentLength",nr="Content-MD5",ir="ContentMD5",Y2e="CompletedMultipartUpload",X2e="CompleteMultipartUploadOutput",J2e="CreateMultipartUploadOutput",Q2e="CompleteMultipartUploadResult",Z2e="CompleteMultipartUploadRequest",e3e="CreateMultipartUploadRequest",FZ="CompleteMultipartUpload",t3e="CreateMultipartUpload",qZ="ChecksumMode",r3e="CopyObject",n3e="CopyObjectOutput",jZ="CopyObjectResult",ww="CORSConfiguration",c1="CORSRules",u1="CORSRule",i3e="CopyObjectRequest",o3e="CommonPrefix",s3e="CommonPrefixList",a3e="CompletedPartList",UZ="CopyPartResult",c3e="CompletedPart",Dv="CommonPrefixes",l1="ContentRange",u3e="ConfirmRemoveSelfBucketAccess",HZ="Content-Range",$Z="CopySource",Jn="ChecksumSHA1",Qn="ChecksumSHA256",GZ="CopySourceIfMatch",zZ="CopySourceIfModifiedSince",VZ="CopySourceIfNoneMatch",WZ="CopySourceIfUnmodifiedSince",l3e="CreateSessionOutput",f3e="CreateSessionResult",d3e="CopySourceRange",p3e="CreateSessionRequest",KZ="CopySourceSSECustomerAlgorithm",f1="CopySourceSSECustomerKey",YZ="CopySourceSSECustomerKeyMD5",XZ="CSV",JZ="CopySourceVersionId",h3e="CSVInput",m3e="CSVOutput",d1="ConfigurationState",g3e="CreateSession",vi="ChecksumType",Bm="Content-Type",y3e="ClientToken",Xf="ContentType",_3e="CompressionType",ui="ContinuationToken",QZ="Condition",b3e="Code",E3e="Comments",ZZ="Contents",w3e="Cont",GQ="Credentials",Jf="Days",S3e="DaysAfterInitiation",v3e="DeleteBucket",C3e="DeleteBucketAnalyticsConfiguration",x3e="DeleteBucketAnalyticsConfigurationRequest",T3e="DeleteBucketCors",A3e="DeleteBucketCorsRequest",R3e="DeleteBucketEncryption",P3e="DeleteBucketEncryptionRequest",O3e="DeleteBucketInventoryConfiguration",I3e="DeleteBucketInventoryConfigurationRequest",D3e="DeleteBucketIntelligentTieringConfiguration",k3e="DeleteBucketIntelligentTieringConfigurationRequest",N3e="DeleteBucketLifecycle",M3e="DeleteBucketLifecycleRequest",L3e="DeleteBucketMetadataConfiguration",B3e="DeleteBucketMetadataConfigurationRequest",F3e="DeleteBucketMetricsConfigurationRequest",q3e="DeleteBucketMetricsConfiguration",j3e="DeleteBucketMetadataTableConfiguration",U3e="DeleteBucketMetadataTableConfigurationRequest",H3e="DeleteBucketOwnershipControls",$3e="DeleteBucketOwnershipControlsRequest",G3e="DeleteBucketPolicy",z3e="DeleteBucketPolicyRequest",V3e="DeleteBucketRequest",W3e="DeleteBucketReplicationRequest",K3e="DeleteBucketReplication",Y3e="DeleteBucketTagging",X3e="DeleteBucketTaggingRequest",J3e="DeleteBucketWebsite",Q3e="DeleteBucketWebsiteRequest",Z3e="DataExport",eFe="DestinationIfMatch",tFe="DestinationIfModifiedSince",rFe="DestinationIfNoneMatch",nFe="DestinationIfUnmodifiedSince",ku="DeleteMarker",iFe="DeleteMarkerEntry",eee="DeleteMarkerReplication",oFe="DeleteMarkerVersionId",tee="DeleteMarkers",p1="DisplayName",sFe="DeletedObject",aFe="DeleteObjectOutput",cFe="DeleteObjectsOutput",uFe="DeleteObjectRequest",lFe="DeleteObjectsRequest",fFe="DeleteObjectTagging",dFe="DeleteObjectTaggingOutput",pFe="DeleteObjectTaggingRequest",hFe="DeletedObjects",mFe="DeleteObject",gFe="DeleteObjects",yFe="DeletePublicAccessBlock",_Fe="DeletePublicAccessBlockRequest",bFe="DataRedundancy",ree="DefaultRetention",EFe="DeleteResult",nee="DestinationResult",iee="Date",Xk="Delete",wFe="Deleted",fc="Delimiter",kv="Destination",SFe="Description",oee="Details",rs="Expiration",vFe="EmailAddress",see="EventBridgeConfiguration",Ee="ExpectedBucketOwner",Fm="EncryptionConfiguration",aee="ErrorCode",CFe="ErrorDetails",h1="ErrorDocument",xFe="EndEvent",TFe="ExposeHeaders",AFe="ExposeHeader",cee="ErrorMessage",RFe="ExpiredObjectDeleteMarker",uee="ExistingObjectReplication",Sw="ExpiresString",lee="ExpectedSourceBucketOwner",m1="EncryptionType",PFe="EncryptionTypeList",OFe="EncryptionTypeMismatch",Jr="ETag",dc="EncodingType",IFe="EventThreshold",fee="ExpressionType",g1="Encryption",DFe="Enabled",dee="End",pee="Errors",qm="Error",y1="Events",_1="Event",go="Expires",hee="Expression",zs="Filter",mee="FieldDelimiter",kFe="FileHeaderInfo",NFe="FetchOwner",gee="FilterRule",MFe="FilterRuleList",LFe="FilterRules",BFe="Field",yee="Format",FFe="Frequency",Nv="Grants",qFe="GetBucketAbac",jFe="GetBucketAccelerateConfiguration",UFe="GetBucketAccelerateConfigurationOutput",HFe="GetBucketAnalyticsConfigurationOutput",$Fe="GetBucketAccelerateConfigurationRequest",GFe="GetBucketAnalyticsConfigurationRequest",zFe="GetBucketAnalyticsConfiguration",VFe="GetBucketAbacOutput",WFe="GetBucketAclOutput",KFe="GetBucketAbacRequest",YFe="GetBucketAclRequest",XFe="GetBucketAcl",JFe="GetBucketCors",QFe="GetBucketCorsOutput",ZFe="GetBucketCorsRequest",eqe="GetBucketEncryption",tqe="GetBucketEncryptionOutput",rqe="GetBucketEncryptionRequest",nqe="GetBucketInventoryConfiguration",iqe="GetBucketInventoryConfigurationOutput",oqe="GetBucketInventoryConfigurationRequest",sqe="GetBucketIntelligentTieringConfiguration",aqe="GetBucketIntelligentTieringConfigurationOutput",cqe="GetBucketIntelligentTieringConfigurationRequest",uqe="GetBucketLocation",lqe="GetBucketLifecycleConfiguration",fqe="GetBucketLifecycleConfigurationOutput",dqe="GetBucketLifecycleConfigurationRequest",pqe="GetBucketLocationOutput",hqe="GetBucketLoggingOutput",mqe="GetBucketLocationRequest",gqe="GetBucketLoggingRequest",yqe="GetBucketLogging",_qe="GetBucketMetadataConfiguration",bqe="GetBucketMetadataConfigurationOutput",Eqe="GetBucketMetricsConfigurationOutput",_ee="GetBucketMetadataConfigurationResult",wqe="GetBucketMetadataConfigurationRequest",Sqe="GetBucketMetricsConfigurationRequest",vqe="GetBucketMetricsConfiguration",Cqe="GetBucketMetadataTableConfiguration",xqe="GetBucketMetadataTableConfigurationOutput",bee="GetBucketMetadataTableConfigurationResult",Tqe="GetBucketMetadataTableConfigurationRequest",Aqe="GetBucketNotificationConfiguration",Rqe="GetBucketNotificationConfigurationRequest",Pqe="GetBucketOwnershipControls",Oqe="GetBucketOwnershipControlsOutput",Iqe="GetBucketOwnershipControlsRequest",Dqe="GetBucketPolicy",kqe="GetBucketPolicyOutput",Nqe="GetBucketPolicyRequest",Mqe="GetBucketPolicyStatus",Lqe="GetBucketPolicyStatusOutput",Bqe="GetBucketPolicyStatusRequest",Fqe="GetBucketReplication",qqe="GetBucketReplicationOutput",jqe="GetBucketRequestPayment",Uqe="GetBucketRequestPaymentOutput",Hqe="GetBucketRequestPaymentRequest",$qe="GetBucketReplicationRequest",Gqe="GetBucketTagging",zqe="GetBucketTaggingOutput",Vqe="GetBucketTaggingRequest",Wqe="GetBucketVersioning",Kqe="GetBucketVersioningOutput",Yqe="GetBucketVersioningRequest",Xqe="GetBucketWebsite",Jqe="GetBucketWebsiteOutput",Qqe="GetBucketWebsiteRequest",Qf="GrantFullControl",Eee="GlacierJobParameters",Zqe="GetObject",eje="GetObjectAcl",tje="GetObjectAclOutput",rje="GetObjectAttributesOutput",nje="GetObjectAttributesParts",ije="GetObjectAclRequest",oje="GetObjectAttributesResponse",sje="GetObjectAttributesRequest",aje="GetObjectAttributes",cje="GetObjectLockConfiguration",uje="GetObjectLockConfigurationOutput",lje="GetObjectLockConfigurationRequest",fje="GetObjectLegalHold",dje="GetObjectLegalHoldOutput",pje="GetObjectLegalHoldRequest",hje="GetObjectOutput",mje="GetObjectRequest",gje="GetObjectRetentionOutput",yje="GetObjectRetentionRequest",_je="GetObjectRetention",bje="GetObjectTagging",Eje="GetObjectTaggingOutput",wje="GetObjectTorrentOutput",Sje="GetObjectTaggingRequest",vje="GetObjectTorrentRequest",Cje="GetObjectTorrent",xje="GetPublicAccessBlock",Tje="GetPublicAccessBlockOutput",Aje="GetPublicAccessBlockRequest",Zf="GrantRead",ed="GrantReadACP",b1="GrantWrite",td="GrantWriteACP",E1="Grant",w1="Grantee",Rje="HeadBucket",Pje="HeadBucketOutput",Oje="HeadBucketRequest",Ije="HttpErrorCodeReturnedEquals",wee="HostName",Dje="HeadObject",kje="HeadObjectOutput",Nje="HeadObjectRequest",Mje="HttpRedirectCode",Mr="Id",wm="InventoryConfiguration",See="InventoryConfigurationList",rd="ID",S1="IndexDocument",Lje="InventoryDestination",Bje="IsEnabled",Fje="InventoryEncryption",qje="InventoryFilter",vee="IsLatest",nd="IfMatch",jje="IfMatchInitiatedTime",Uje="IfMatchLastModifiedTime",Hje="IfMatchSize",v1="If-Modified-Since",Cee="IfModifiedSince",$je="InitiateMultipartUploadResult",Nu="If-Match",jm="IfNoneMatch",id="If-None-Match",Gje="InventoryOptionalFields",zje="InvalidObjectState",Vje="IncludedObjectVersions",zQ="IsPublic",VQ="IgnorePublicAcls",Wje="IdempotencyParameterMismatch",Kje="InvalidRequest",Yje="IsRestoreInProgress",C1="InputSerialization",Xje="InventoryS3BucketDestination",Jje="InventorySchedule",ns="IsTruncated",Qje="IntelligentTieringAndOperator",Sm="IntelligentTieringConfiguration",xee="IntelligentTieringConfigurationList",Tee="InventoryTableConfigurationResult",Zje="InventoryTableConfigurationUpdates",vw="InventoryTableConfiguration",eUe="IntelligentTieringFilter",Aee="IfUnmodifiedSince",x1="If-Unmodified-Since",tUe="InvalidWriteOffset",T1="Initiator",rUe="Initiated",Ree="JSON",nUe="JSONInput",iUe="JSONOutput",Cw="JournalTableConfiguration",Pee="JournalTableConfigurationResult",oUe="JournalTableConfigurationUpdates",tt="Key",sUe="KeyCount",aUe="KeyId",cUe="KmsKeyArn",Mv="KeyMarker",uUe="KMSContext",lUe="KMSKeyId",fUe="KMSMasterKeyID",dUe="KeyPrefixEquals",xw="Location",pUe="ListAllMyBucketsResult",hUe="ListAllMyDirectoryBucketsResult",mUe="ListBuckets",gUe="ListBucketAnalyticsConfigurations",yUe="ListBucketAnalyticsConfigurationsOutput",_Ue="ListBucketAnalyticsConfigurationResult",bUe="ListBucketAnalyticsConfigurationsRequest",EUe="ListBucketInventoryConfigurations",wUe="ListBucketInventoryConfigurationsOutput",SUe="ListBucketInventoryConfigurationsRequest",vUe="ListBucketIntelligentTieringConfigurations",CUe="ListBucketIntelligentTieringConfigurationsOutput",xUe="ListBucketIntelligentTieringConfigurationsRequest",TUe="ListBucketMetricsConfigurations",AUe="ListBucketMetricsConfigurationsOutput",RUe="ListBucketMetricsConfigurationsRequest",PUe="ListBucketsOutput",OUe="ListBucketsRequest",Oee="ListBucketResult",Jk="LocationConstraint",Qk="LifecycleConfiguration",IUe="ListDirectoryBuckets",DUe="ListDirectoryBucketsOutput",kUe="ListDirectoryBucketsRequest",A1="LoggingEnabled",NUe="LifecycleExpiration",MUe="LambdaFunctionArn",LUe="LambdaFunctionConfiguration",BUe="LambdaFunctionConfigurationList",FUe="LambdaFunctionConfigurations",Tw="LegalHold",qUe="LocationInfo",jUe="ListInventoryConfigurationsResult",is="LastModified",UUe="ListMetricsConfigurationsResult",HUe="LastModifiedTime",$Ue="ListMultipartUploads",GUe="ListMultipartUploadsOutput",zUe="ListMultipartUploadsResult",VUe="ListMultipartUploadsRequest",R1="Last-Modified",WUe="ListObjects",KUe="ListObjectsOutput",YUe="ListObjectsRequest",XUe="ListObjectsV2",JUe="ListObjectsV2Output",QUe="ListObjectVersionsOutput",ZUe="ListObjectsV2Request",e4e="ListObjectVersionsRequest",t4e="ListObjectVersions",r4e="ListParts",n4e="ListPartsOutput",i4e="ListPartsResult",o4e="ListPartsRequest",s4e="LifecycleRule",a4e="LifecycleRuleAndOperator",c4e="LifecycleRuleFilter",u4e="LifecycleRules",l4e="ListVersionsResult",od="Metadata",f4e="MetricsAndOperator",d4e="MaxAgeSeconds",p4e="MaxBuckets",Zk="MetadataConfiguration",Iee="MetricsConfigurationList",Dee="MetadataConfigurationResult",vm="MetricsConfiguration",h4e="MetadataDirective",m4e="MaxDirectoryBuckets",kee="MfaDelete",Nee="MetadataEntry",g4e="MetricsFilter",P1="MFA",Mee="MFADelete",sd="MaxKeys",O1="MissingMeta",y4e="MpuObjectSize",Lv="MaxParts",e1="MetadataTableConfiguration",Lee="MetadataTableConfigurationResult",_4e="MetadataTableEncryptionConfiguration",Bee="MultipartUpload",b4e="MultipartUploadList",Fee="MaxUploads",qee="Marker",jee="Metrics",E4e="Message",w4e="Minutes",Uee="Mode",Mu="Name",t1="NotificationConfiguration",S4e="NotificationConfigurationFilter",Um="NextContinuationToken",Hee="NoncurrentDays",v4e="NotFound",$ee="NextKeyMarker",C4e="NextMarker",Gee="NewerNoncurrentVersions",zee="NextPartNumberMarker",x4e="NoSuchBucket",T4e="NoSuchKey",A4e="NoSuchUpload",R4e="NextUploadIdMarker",Vee="NoncurrentVersionExpiration",P4e="NextVersionIdMarker",O4e="NoncurrentVersionTransitions",I4e="NoncurrentVersionTransitionList",Wee="NoncurrentVersionTransition",bo="Owner",D4e="ObjectAttributes",k4e="ObjectAlreadyInActiveTierError",Aw="OwnershipControls",N4e="OwnershipControlsRule",M4e="OwnershipControlsRules",L4e="OptionalFields",B4e="ObjectIdentifier",F4e="ObjectIdentifierList",Kee="OutputLocation",Rw="ObjectLockConfiguration",q4e="ObjectLockEnabled",j4e="ObjectLockEnabledForBucket",U4e="ObjectLockLegalHold",ad="ObjectLockLegalHoldStatus",cd="ObjectLockMode",H4e="ObjectLockRetention",ud="ObjectLockRetainUntilDate",$4e="ObjectLockRule",G4e="ObjectList",z4e="ObjectNotInActiveTierError",Yee="ObjectOwnership",I1="OptionalObjectAttributes",V4e="ObjectParts",W4e="ObjectPart",K4e="ObjectSize",Xee="ObjectSizeGreaterThan",Jee="ObjectSizeLessThan",Y4e="OutputSchemaVersion",D1="OutputSerialization",X4e="ObjectVersion",J4e="ObjectVersionList",Q4e="Objects",Qee="Object",Gt="Prefix",Pw="PublicAccessBlockConfiguration",Z4e="PutBucketAbac",eHe="PutBucketAccelerateConfiguration",tHe="PutBucketAccelerateConfigurationRequest",rHe="PutBucketAnalyticsConfigurationRequest",nHe="PutBucketAnalyticsConfiguration",iHe="PutBucketAbacRequest",oHe="PutBucketAclRequest",sHe="PutBucketAcl",aHe="PutBucketCors",cHe="PutBucketCorsRequest",uHe="PutBucketEncryption",lHe="PutBucketEncryptionRequest",fHe="PutBucketInventoryConfiguration",dHe="PutBucketInventoryConfigurationRequest",pHe="PutBucketIntelligentTieringConfiguration",hHe="PutBucketIntelligentTieringConfigurationRequest",mHe="PutBucketLogging",gHe="PutBucketLifecycleConfiguration",yHe="PutBucketLifecycleConfigurationOutput",_He="PutBucketLifecycleConfigurationRequest",bHe="PutBucketLoggingRequest",EHe="PutBucketMetricsConfiguration",wHe="PutBucketMetricsConfigurationRequest",SHe="PutBucketNotificationConfiguration",vHe="PutBucketNotificationConfigurationRequest",CHe="PutBucketOwnershipControls",xHe="PutBucketOwnershipControlsRequest",THe="PutBucketPolicy",AHe="PutBucketPolicyRequest",RHe="PutBucketReplication",PHe="PutBucketRequestPayment",OHe="PutBucketRequestPaymentRequest",IHe="PutBucketReplicationRequest",DHe="PutBucketTagging",kHe="PutBucketTaggingRequest",NHe="PutBucketVersioning",MHe="PutBucketVersioningRequest",LHe="PutBucketWebsite",BHe="PutBucketWebsiteRequest",Bv="PartsCount",FHe="PartitionDateSource",qHe="ProgressEvent",jHe="ParquetInput",UHe="PartsList",Lu="PartNumber",Fv="PartNumberMarker",HHe="PutObject",$He="PutObjectAcl",GHe="PutObjectAclOutput",zHe="PutObjectAclRequest",VHe="PutObjectLockConfiguration",WHe="PutObjectLockConfigurationOutput",KHe="PutObjectLockConfigurationRequest",YHe="PutObjectLegalHold",XHe="PutObjectLegalHoldOutput",JHe="PutObjectLegalHoldRequest",QHe="PutObjectOutput",ZHe="PutObjectRequest",e5e="PutObjectRetentionOutput",t5e="PutObjectRetentionRequest",r5e="PutObjectRetention",n5e="PutObjectTagging",i5e="PutObjectTaggingOutput",o5e="PutObjectTaggingRequest",Ow="PartitionedPrefix",s5e="PutPublicAccessBlock",a5e="PutPublicAccessBlockRequest",Zee="PolicyStatus",qv="Parts",jv="Part",c5e="Parquet",ete="Payer",tte="Payload",rte="Permission",nte="Policy",ite="Progress",u5e="Priority",ote="Protocol",l5e="Quiet",f5e="QueueArn",ste="QuoteCharacter",d5e="QueueConfigurationList",p5e="QueueConfigurations",ate="QueueConfiguration",cte="QuoteEscapeCharacter",h5e="QuoteFields",m5e="Queue",Hm="Rules",k1="RedirectAllRequestsTo",Kt="RequestCharged",ute="ResponseCacheControl",lte="ResponseContentDisposition",fte="ResponseContentEncoding",dte="ResponseContentLanguage",pte="ResponseContentType",Iw="ReplicationConfiguration",N1="RecordDelimiter",hte="ResponseExpires",g5e="RestoreExpiryDate",Uv="RecordExpiration",y5e="RecordsEvent",_5e="ReplicaKmsKeyID",b5e="ReplaceKeyPrefixWith",E5e="ReplaceKeyWith",mte="ReplicaModifications",w5e="RenameObject",S5e="RenameObjectOutput",v5e="RestoreObjectOutput",C5e="RestoreOutputPath",x5e="RenameObjectRequest",T5e="RestoreObjectRequest",A5e="RestoreObject",Mt="RequestPayer",WQ="RestrictPublicBuckets",Dw="RequestPaymentConfiguration",gte="RequestProgress",M1="RoutingRules",R5e="ReplicationRuleAndOperator",P5e="ReplicationRuleFilter",O5e="ReplicationRule",I5e="ReplicationRules",D5e="RequestRoute",r1="RestoreRequest",yte="RoutingRule",L1="ReplicationStatus",B1="RestoreStatus",k5e="RenameSource",_te="ReplicationTime",N5e="ReplicationTimeValue",M5e="RequestToken",L5e="RetainUntilDate",kw="Range",F1="Restore",B5e="Records",bte="Redirect",Nw="Retention",F5e="Role",ld="Rule",Dn="Status",Ete="StartAfter",KQ="SecretAccessKey",q5e="SseAlgorithm",j5e="StreamingBlob",wte="S3BucketDestination",kn="StorageClass",Ste="StorageClassAnalysis",U5e="StorageClassAnalysisDataExport",H5e="SessionCredentialValue",$5e="SessionCredentials",G5e="StatusCode",z5e="SkipDestinationValidation",V5e="StatsEvent",W5e="SourceIfMatch",K5e="SourceIfModifiedSince",Y5e="SourceIfNoneMatch",X5e="SourceIfUnmodifiedSince",vte="SSE-KMS",Cte="SseKmsEncryptedObjects",J5e="S3KeyFilter",Q5e="S3Key",Z5e="S3Location",e6e="SessionMode",t6e="SelectObjectContent",r6e="SelectObjectContentEventStream",n6e="SelectObjectContentOutput",i6e="SelectObjectContentRequest",xte="SelectParameters",Mw="SimplePrefix",Tte="ScanRange",Ate="SSE-S3",Rte="SourceSelectionCriteria",li="ServerSideEncryption",o6e="SSEAlgorithm",s6e="ServerSideEncryptionByDefault",Lw="ServerSideEncryptionConfiguration",Lr="SSECustomerAlgorithm",Vi="SSECustomerKey",Br="SSECustomerKeyMD5",Pte="SSEKMS",Vs="SSEKMSEncryptionContext",Zn="SSEKMSKeyId",a6e="ServerSideEncryptionRule",c6e="ServerSideEncryptionRules",Ote="SSES3",YQ="SessionToken",Ite="S3TablesDestination",Dte="S3TablesDestinationResult",u6e="S3",l6e="Schedule",fd="Size",f6e="Start",kte="Stats",d6e="Suffix",dd="Tags",q1="TableArn",p6e="TopicArn",h6e="TargetBucket",j1="TableBucketArn",m6e="TableBucketType",U1="TagCount",g6e="TopicConfigurationList",y6e="TopicConfigurations",Nte="TopicConfiguration",_6e="TaggingDirective",H1="TransitionDefaultMinimumObjectSize",Mte="TargetGrants",b6e="TargetGrant",E6e="TieringList",w6e="TransitionList",S6e="TooManyParts",Lte="TableNamespace",Hv="TableName",Bte="TargetObjectKeyFormat",v6e="TargetPrefix",C6e="TotalPartsCount",$v="TagSet",Fte="TableStatus",Wi="Tag",yo="Tagging",qte="Tier",x6e="Tierings",jte="Tiering",T6e="Time",Ute="Token",A6e="Topic",R6e="Transitions",Hte="Transition",$m="Type",P6e="Uploads",O6e="UpdateBucketMetadataInventoryTableConfiguration",I6e="UpdateBucketMetadataInventoryTableConfigurationRequest",D6e="UpdateBucketMetadataJournalTableConfiguration",k6e="UpdateBucketMetadataJournalTableConfigurationRequest",pc="UploadId",$te="UploadIdMarker",Gte="UserMetadata",N6e="UploadPart",M6e="UploadPartCopy",L6e="UploadPartCopyOutput",B6e="UploadPartCopyRequest",F6e="UploadPartOutput",q6e="UploadPartRequest",j6e="URI",U6e="Upload",$1="Value",Bw="VersioningConfiguration",It="VersionId",zte="VersionIdMarker",H6e="Versions",$6e="Version",Fw="WebsiteConfiguration",G6e="WriteGetObjectResponse",z6e="WriteGetObjectResponseRequest",V6e="WriteOffsetBytes",Gm="WebsiteRedirectLocation",W6e="Years",Vte="accept-ranges",K6e="bucket-region",fi="client",Bu="continuation-token",Gv="delimiter",di="error",G1="eventPayload",Y6e="endpoint",zv="encoding-type",X6e="fetch-owner",me="http",Ci="httpError",g="httpHeader",J6e="hostLabel",gt="httpPayload",pd="httpPrefixHeaders",Ce="httpQuery",Wte="http://www.w3.org/2001/XMLSchema-instance",Ki="id",Q6e="idempotencyToken",Kte="key-marker",Z6e="marker",e$e="max-buckets",t$e="max-directory-buckets",z1="max-keys",r$e="max-parts",n$e="max-uploads",zm="prefix",Vv="partNumber",i$e="part-number-marker",Yte="response-cache-control",Xte="response-content-disposition",Jte="response-content-encoding",Qte="response-content-language",Zte="response-content-type",ere="response-expires",tre="streaming",o$e="start-after",rre="smithy.ts.sdk.synthetic.com.amazonaws.s3",Vm="uploadId",s$e="upload-id-marker",pi="versionId",a$e="version-id-marker",nre="xsi",c$e="xmlAttribute",je="xmlFlattened",re="xmlName",ire="xmlNamespace",hd="x-amz-acl",ore="x-amz-abort-date",u$e="x-amz-access-point-alias",sre="x-amz-abort-rule-id",l$e="x-amz-archive-status",are="x-amz-bucket-arn",V1="x-amz-bypass-governance-retention",f$e="x-amz-bucket-location-name",d$e="x-amz-bucket-location-type",p$e="x-amz-bucket-object-lock-enabled",cre="x-amz-bucket-object-lock-token",h$e="x-amz-bucket-region",W1="x-amz-checksum-algorithm",Fu="x-amz-checksum-crc32",qu="x-amz-checksum-crc32c",ju="x-amz-checksum-crc64nvme",ure="x-amz-checksum-mode",m$e="x-amz-confirm-remove-self-bucket-access",Uu="x-amz-checksum-sha1",Hu="x-amz-checksum-sha256",lre="x-amz-copy-source",fre="x-amz-copy-source-if-match",dre="x-amz-copy-source-if-modified-since",pre="x-amz-copy-source-if-none-match",hre="x-amz-copy-source-if-unmodified-since",g$e="x-amz-create-session-mode",y$e="x-amz-copy-source-range",mre="x-amz-copy-source-server-side-encryption-customer-algorithm",gre="x-amz-copy-source-server-side-encryption-customer-key",yre="x-amz-copy-source-server-side-encryption-customer-key-MD5",_re="x-amz-copy-source-version-id",md="x-amz-checksum-type",_$e="x-amz-client-token",Wv="x-amz-delete-marker",Wm="x-amz-expiration",we="x-amz-expected-bucket-owner",b$e="x-amz-fwd-error-code",E$e="x-amz-fwd-error-message",w$e="x-amz-fwd-header-Cache-Control",S$e="x-amz-fwd-header-Content-Disposition",v$e="x-amz-fwd-header-Content-Encoding",C$e="x-amz-fwd-header-Content-Language",x$e="x-amz-fwd-header-Content-Range",T$e="x-amz-fwd-header-Content-Type",A$e="x-amz-fwd-header-ETag",R$e="x-amz-fwd-header-Expires",P$e="x-amz-fwd-header-Last-Modified",O$e="x-amz-fwd-header-accept-ranges",I$e="x-amz-fwd-header-x-amz-checksum-crc32",D$e="x-amz-fwd-header-x-amz-checksum-crc32c",k$e="x-amz-fwd-header-x-amz-checksum-crc64nvme",N$e="x-amz-fwd-header-x-amz-checksum-sha1",M$e="x-amz-fwd-header-x-amz-checksum-sha256",L$e="x-amz-fwd-header-x-amz-delete-marker",B$e="x-amz-fwd-header-x-amz-expiration",F$e="x-amz-fwd-header-x-amz-missing-meta",q$e="x-amz-fwd-header-x-amz-mp-parts-count",j$e="x-amz-fwd-header-x-amz-object-lock-legal-hold",U$e="x-amz-fwd-header-x-amz-object-lock-mode",H$e="x-amz-fwd-header-x-amz-object-lock-retain-until-date",$$e="x-amz-fwd-header-x-amz-restore",G$e="x-amz-fwd-header-x-amz-request-charged",z$e="x-amz-fwd-header-x-amz-replication-status",V$e="x-amz-fwd-header-x-amz-storage-class",W$e="x-amz-fwd-header-x-amz-server-side-encryption",K$e="x-amz-fwd-header-x-amz-server-side-encryption-aws-kms-key-id",Y$e="x-amz-fwd-header-x-amz-server-side-encryption-bucket-key-enabled",X$e="x-amz-fwd-header-x-amz-server-side-encryption-customer-algorithm",J$e="x-amz-fwd-header-x-amz-server-side-encryption-customer-key-MD5",Q$e="x-amz-fwd-header-x-amz-tagging-count",Z$e="x-amz-fwd-header-x-amz-version-id",e8e="x-amz-fwd-status",gd="x-amz-grant-full-control",yd="x-amz-grant-read",_d="x-amz-grant-read-acp",K1="x-amz-grant-write",bd="x-amz-grant-write-acp",t8e="x-amz-if-match-initiated-time",r8e="x-amz-if-match-last-modified-time",n8e="x-amz-if-match-size",Ed="x-amz-meta-",Y1="x-amz-mfa",i8e="x-amz-metadata-directive",bre="x-amz-missing-meta",o8e="x-amz-mp-object-size",s8e="x-amz-max-parts",Ere="x-amz-mp-parts-count",a8e="x-amz-object-attributes",Km="x-amz-object-lock-legal-hold",Ym="x-amz-object-lock-mode",Xm="x-amz-object-lock-retain-until-date",c8e="x-amz-object-ownership",X1="x-amz-optional-object-attributes",u8e="x-amz-object-size",l8e="x-amz-part-number-marker",wre="x-amz-restore",Zt="x-amz-request-charged",f8e="x-amz-restore-output-path",Lt="x-amz-request-payer",d8e="x-amz-request-route",Sre="x-amz-replication-status",p8e="x-amz-rename-source",h8e="x-amz-rename-source-if-match",m8e="x-amz-rename-source-if-modified-since",g8e="x-amz-rename-source-if-none-match",y8e="x-amz-rename-source-if-unmodified-since",_8e="x-amz-request-token",Jm="x-amz-storage-class",jt="x-amz-sdk-checksum-algorithm",b8e="x-amz-skip-destination-validation",vre="x-amz-source-expected-bucket-owner",xi="x-amz-server-side-encryption",Ti="x-amz-server-side-encryption-aws-kms-key-id",Ai="x-amz-server-side-encryption-bucket-key-enabled",hc="x-amz-server-side-encryption-context",Qr="x-amz-server-side-encryption-customer-algorithm",Eo="x-amz-server-side-encryption-customer-key",Zr="x-amz-server-side-encryption-customer-key-MD5",J1="x-amz-tagging",Cre="x-amz-tagging-count",E8e="x-amz-tagging-directive",Q1="x-amz-transition-default-minimum-object-size",os="x-amz-version-id",w8e="x-amz-write-offset-bytes",Qm="x-amz-website-redirect-location",S8e="xsi:type",b="com.amazonaws.s3",xre=[0,b,f1,8,0],XQ=[0,b,H5e,8,0],wo=[0,b,Vi,8,0],mc=[0,b,Vs,8,0],dn=[0,b,Zn,8,0],Zm=[0,b,j5e,{[tre]:1},42],Tre=[3,b,bw,0,[Dn],[0]],v8e=[3,b,PZ,0,[S3e],[1]],C8e=[3,b,b2e,0,[Kt],[[0,{[g]:Zt}]]],x8e=[3,b,E2e,0,[le,tt,pc,Mt,Ee,jje],[[0,1],[0,1],[0,{[Ce]:Vm}],[0,{[g]:Lt}],[0,{[g]:we}],[6,{[g]:t8e}]]],T8e=[3,b,_w,0,[Dn],[0]],Are=[3,b,Du,0,[Nv,bo],[[()=>Yv,{[re]:Iv}],()=>Ws]],A8e=[3,b,AZ,0,[bo],[0]],R8e=[3,b,f2e,0,[Gt,dd],[0,[()=>Ks,{[re]:Wi,[je]:1}]]],Z1=[3,b,Em,0,[Mr,zs,Ste],[0,[()=>L7e,0],()=>z9e]],P8e=[3,b,d2e,0,[wte],[()=>O8e]],O8e=[3,b,T2e,0,[yee,O2e,le,Gt],[0,0,0,0]],I8e=[3,b,kZ,0,[m1],[[()=>p7e,{[je]:1}]]],D8e=[3,b,le,0,[Mu,z2e,s1,i1],[0,4,0,0]],k8e=[-3,b,P2e,{[di]:fi,[Ci]:409},[],[]];On.TypeRegistry.for(b).registerError(k8e,rZ);var N8e=[-3,b,I2e,{[di]:fi,[Ci]:409},[],[]];On.TypeRegistry.for(b).registerError(N8e,iZ);var M8e=[3,b,D2e,0,[bFe,$m],[0,0]],L8e=[3,b,k2e,0,[Hm],[[()=>Kre,{[re]:ld,[je]:1}]]],B8e=[3,b,Ew,0,[A1],[[()=>kre,0]]],F8e=[3,b,BZ,0,[Kn,Yn,Xn,Jn,Qn,vi],[0,0,0,0,0,0]],q8e=[3,b,o3e,0,[Gt],[0]],j8e=[3,b,Y2e,0,[qv],[[()=>l7e,{[re]:jv,[je]:1}]]],U8e=[3,b,c3e,0,[Jr,Kn,Yn,Xn,Jn,Qn,Lu],[0,0,0,0,0,0,1]],H8e=[3,b,X2e,{[re]:Q2e},[xw,le,tt,rs,Jr,Kn,Yn,Xn,Jn,Qn,vi,li,It,Zn,Wn,Kt],[0,0,0,[0,{[g]:Wm}],0,0,0,0,0,0,0,[0,{[g]:xi}],[0,{[g]:os}],[()=>dn,{[g]:Ti}],[2,{[g]:Ai}],[0,{[g]:Zt}]]],$8e=[3,b,Z2e,0,[le,tt,Bee,pc,Kn,Yn,Xn,Jn,Qn,vi,y4e,Mt,Ee,nd,jm,Lr,Vi,Br],[[0,1],[0,1],[()=>j8e,{[re]:FZ,[gt]:1}],[0,{[Ce]:Vm}],[0,{[g]:Fu}],[0,{[g]:qu}],[0,{[g]:ju}],[0,{[g]:Uu}],[0,{[g]:Hu}],[0,{[g]:md}],[1,{[g]:o8e}],[0,{[g]:Lt}],[0,{[g]:we}],[0,{[g]:Nu}],[0,{[g]:id}],[0,{[g]:Qr}],[()=>wo,{[g]:Eo}],[0,{[g]:Zr}]]],G8e=[3,b,QZ,0,[Ije,dUe],[0,0]],z8e=[3,b,V2e,0,[],[]],V8e=[3,b,n3e,0,[jZ,rs,JZ,It,li,Lr,Br,Zn,Vs,Wn,Kt],[[()=>K8e,16],[0,{[g]:Wm}],[0,{[g]:_re}],[0,{[g]:os}],[0,{[g]:xi}],[0,{[g]:Qr}],[0,{[g]:Zr}],[()=>dn,{[g]:Ti}],[()=>mc,{[g]:hc}],[2,{[g]:Ai}],[0,{[g]:Zt}]]],W8e=[3,b,i3e,0,[zf,le,Vf,pt,Wf,Kf,Yf,Xf,$Z,GZ,zZ,VZ,WZ,go,Qf,Zf,ed,td,nd,jm,tt,od,h4e,_6e,li,kn,Gm,Lr,Vi,Br,Zn,Vs,Wn,KZ,f1,YZ,Mt,yo,cd,ud,ad,Ee,lee],[[0,{[g]:hd}],[0,1],[0,{[g]:Im}],[0,{[g]:W1}],[0,{[g]:Dm}],[0,{[g]:km}],[0,{[g]:Nm}],[0,{[g]:Bm}],[0,{[g]:lre}],[0,{[g]:fre}],[4,{[g]:dre}],[0,{[g]:pre}],[4,{[g]:hre}],[4,{[g]:go}],[0,{[g]:gd}],[0,{[g]:yd}],[0,{[g]:_d}],[0,{[g]:bd}],[0,{[g]:Nu}],[0,{[g]:id}],[0,1],[128,{[pd]:Ed}],[0,{[g]:i8e}],[0,{[g]:E8e}],[0,{[g]:xi}],[0,{[g]:Jm}],[0,{[g]:Qm}],[0,{[g]:Qr}],[()=>wo,{[g]:Eo}],[0,{[g]:Zr}],[()=>dn,{[g]:Ti}],[()=>mc,{[g]:hc}],[2,{[g]:Ai}],[0,{[g]:mre}],[()=>xre,{[g]:gre}],[0,{[g]:yre}],[0,{[g]:Lt}],[0,{[g]:J1}],[0,{[g]:Ym}],[5,{[g]:Xm}],[0,{[g]:Km}],[0,{[g]:we}],[0,{[g]:vre}]]],K8e=[3,b,jZ,0,[Jr,is,vi,Kn,Yn,Xn,Jn,Qn],[0,4,0,0,0,0,0,0]],Y8e=[3,b,UZ,0,[Jr,is,Kn,Yn,Xn,Jn,Qn],[0,4,0,0,0,0,0]],X8e=[3,b,ww,0,[c1],[[()=>Wre,{[re]:u1,[je]:1}]]],J8e=[3,b,u1,0,[rd,h2e,y2e,S2e,TFe,d4e],[0,[64,{[re]:m2e,[je]:1}],[64,{[re]:w2e,[je]:1}],[64,{[re]:v2e,[je]:1}],[64,{[re]:AFe,[je]:1}],1]],Q8e=[3,b,Yk,0,[Jk,xw,le,dd],[0,()=>rWe,()=>M8e,[()=>Ks,0]]],Z8e=[3,b,j2e,0,[le,ir,pt,Zk,Ee],[[0,1],[0,{[g]:nr}],[0,{[g]:jt}],[()=>nWe,{[re]:Zk,[gt]:1}],[0,{[g]:we}]]],eGe=[3,b,H2e,0,[le,ir,pt,e1,Ee],[[0,1],[0,{[g]:nr}],[0,{[g]:jt}],[()=>sWe,{[re]:e1,[gt]:1}],[0,{[g]:we}]]],tGe=[3,b,$2e,0,[xw,i1],[[0,{[g]:xw}],[0,{[g]:are}]]],rGe=[3,b,G2e,0,[zf,le,Yk,Qf,Zf,ed,b1,td,j4e,Yee],[[0,{[g]:hd}],[0,1],[()=>Q8e,{[re]:Yk,[gt]:1}],[0,{[g]:gd}],[0,{[g]:yd}],[0,{[g]:_d}],[0,{[g]:K1}],[0,{[g]:bd}],[2,{[g]:p$e}],[0,{[g]:c8e}]]],nGe=[3,b,J2e,{[re]:$je},[RZ,IZ,le,tt,pc,li,Lr,Br,Zn,Vs,Wn,Kt,pt,vi],[[4,{[g]:ore}],[0,{[g]:sre}],[0,{[re]:le}],0,0,[0,{[g]:xi}],[0,{[g]:Qr}],[0,{[g]:Zr}],[()=>dn,{[g]:Ti}],[()=>mc,{[g]:hc}],[2,{[g]:Ai}],[0,{[g]:Zt}],[0,{[g]:W1}],[0,{[g]:md}]]],iGe=[3,b,e3e,0,[zf,le,Vf,Wf,Kf,Yf,Xf,go,Qf,Zf,ed,td,tt,od,li,kn,Gm,Lr,Vi,Br,Zn,Vs,Wn,Mt,yo,cd,ud,ad,Ee,pt,vi],[[0,{[g]:hd}],[0,1],[0,{[g]:Im}],[0,{[g]:Dm}],[0,{[g]:km}],[0,{[g]:Nm}],[0,{[g]:Bm}],[4,{[g]:go}],[0,{[g]:gd}],[0,{[g]:yd}],[0,{[g]:_d}],[0,{[g]:bd}],[0,1],[128,{[pd]:Ed}],[0,{[g]:xi}],[0,{[g]:Jm}],[0,{[g]:Qm}],[0,{[g]:Qr}],[()=>wo,{[g]:Eo}],[0,{[g]:Zr}],[()=>dn,{[g]:Ti}],[()=>mc,{[g]:hc}],[2,{[g]:Ai}],[0,{[g]:Lt}],[0,{[g]:J1}],[0,{[g]:Ym}],[5,{[g]:Xm}],[0,{[g]:Km}],[0,{[g]:we}],[0,{[g]:W1}],[0,{[g]:md}]]],oGe=[3,b,l3e,{[re]:f3e},[li,Zn,Vs,Wn,GQ],[[0,{[g]:xi}],[()=>dn,{[g]:Ti}],[()=>mc,{[g]:hc}],[2,{[g]:Ai}],[()=>B9e,{[re]:GQ}]]],sGe=[3,b,p3e,0,[e6e,le,li,Zn,Vs,Wn],[[0,{[g]:g$e}],[0,1],[0,{[g]:xi}],[()=>dn,{[g]:Ti}],[()=>mc,{[g]:hc}],[2,{[g]:Ai}]]],aGe=[3,b,h3e,0,[kFe,E3e,cte,N1,mee,ste,x2e],[0,0,0,0,0,0,2]],cGe=[3,b,m3e,0,[h5e,cte,N1,mee,ste],[0,0,0,0,0]],uGe=[3,b,ree,0,[Uee,Jf,W6e],[0,1,1]],lGe=[3,b,Xk,0,[Q4e,l5e],[[()=>v7e,{[re]:Qee,[je]:1}],2]],fGe=[3,b,x3e,0,[le,Mr,Ee],[[0,1],[0,{[Ce]:Ki}],[0,{[g]:we}]]],dGe=[3,b,A3e,0,[le,Ee],[[0,1],[0,{[g]:we}]]],pGe=[3,b,P3e,0,[le,Ee],[[0,1],[0,{[g]:we}]]],hGe=[3,b,k3e,0,[le,Mr,Ee],[[0,1],[0,{[Ce]:Ki}],[0,{[g]:we}]]],mGe=[3,b,I3e,0,[le,Mr,Ee],[[0,1],[0,{[Ce]:Ki}],[0,{[g]:we}]]],gGe=[3,b,M3e,0,[le,Ee],[[0,1],[0,{[g]:we}]]],yGe=[3,b,B3e,0,[le,Ee],[[0,1],[0,{[g]:we}]]],_Ge=[3,b,U3e,0,[le,Ee],[[0,1],[0,{[g]:we}]]],bGe=[3,b,F3e,0,[le,Mr,Ee],[[0,1],[0,{[Ce]:Ki}],[0,{[g]:we}]]],EGe=[3,b,$3e,0,[le,Ee],[[0,1],[0,{[g]:we}]]],wGe=[3,b,z3e,0,[le,Ee],[[0,1],[0,{[g]:we}]]],SGe=[3,b,W3e,0,[le,Ee],[[0,1],[0,{[g]:we}]]],vGe=[3,b,V3e,0,[le,Ee],[[0,1],[0,{[g]:we}]]],CGe=[3,b,X3e,0,[le,Ee],[[0,1],[0,{[g]:we}]]],xGe=[3,b,Q3e,0,[le,Ee],[[0,1],[0,{[g]:we}]]],TGe=[3,b,sFe,0,[tt,It,ku,oFe],[0,0,2,0]],AGe=[3,b,iFe,0,[bo,tt,It,vee,is],[()=>Ws,0,0,2,4]],RGe=[3,b,eee,0,[Dn],[0]],PGe=[3,b,aFe,0,[ku,It,Kt],[[2,{[g]:Wv}],[0,{[g]:os}],[0,{[g]:Zt}]]],OGe=[3,b,uFe,0,[le,tt,P1,It,Mt,o1,Ee,nd,Uje,Hje],[[0,1],[0,1],[0,{[g]:Y1}],[0,{[Ce]:pi}],[0,{[g]:Lt}],[2,{[g]:V1}],[0,{[g]:we}],[0,{[g]:Nu}],[6,{[g]:r8e}],[1,{[g]:n8e}]]],IGe=[3,b,cFe,{[re]:EFe},[wFe,Kt,pee],[[()=>f7e,{[je]:1}],[0,{[g]:Zt}],[()=>h7e,{[re]:qm,[je]:1}]]],DGe=[3,b,lFe,0,[le,Xk,P1,Mt,o1,Ee,pt],[[0,1],[()=>lGe,{[re]:Xk,[gt]:1}],[0,{[g]:Y1}],[0,{[g]:Lt}],[2,{[g]:V1}],[0,{[g]:we}],[0,{[g]:jt}]]],kGe=[3,b,dFe,0,[It],[[0,{[g]:os}]]],NGe=[3,b,pFe,0,[le,tt,It,Ee],[[0,1],[0,1],[0,{[Ce]:pi}],[0,{[g]:we}]]],MGe=[3,b,_Fe,0,[le,Ee],[[0,1],[0,{[g]:we}]]],LGe=[3,b,kv,0,[le,l2e,kn,AZ,Fm,_te,jee],[0,0,0,()=>A8e,()=>qGe,()=>E9e,()=>cWe]],BGe=[3,b,nee,0,[m6e,j1,Lte],[0,0,0]],FGe=[3,b,g1,0,[m1,lUe,uUe],[0,[()=>dn,0],0]],qGe=[3,b,Fm,0,[_5e],[0]],jGe=[-3,b,OFe,{[di]:fi,[Ci]:400},[],[]];On.TypeRegistry.for(b).registerError(jGe,hZ);var UGe=[3,b,xFe,0,[],[]],HGe=[3,b,qm,0,[tt,It,b3e,E4e],[0,0,0,0]],eN=[3,b,CFe,0,[aee,cee],[0,0]],Rre=[3,b,h1,0,[tt],[0]],$Ge=[3,b,see,0,[],[]],GGe=[3,b,uee,0,[Dn],[0]],zGe=[3,b,gee,0,[Mu,$1],[0,0]],VGe=[3,b,VFe,0,[bw],[[()=>Tre,16]]],WGe=[3,b,KFe,0,[le,Ee],[[0,1],[0,{[g]:we}]]],KGe=[3,b,UFe,{[re]:_w},[Dn,Kt],[0,[0,{[g]:Zt}]]],YGe=[3,b,$Fe,0,[le,Ee,Mt],[[0,1],[0,{[g]:we}],[0,{[g]:Lt}]]],XGe=[3,b,WFe,{[re]:Du},[bo,Nv],[()=>Ws,[()=>Yv,{[re]:Iv}]]],JGe=[3,b,YFe,0,[le,Ee],[[0,1],[0,{[g]:we}]]],QGe=[3,b,HFe,0,[Em],[[()=>Z1,16]]],ZGe=[3,b,GFe,0,[le,Mr,Ee],[[0,1],[0,{[Ce]:Ki}],[0,{[g]:we}]]],eze=[3,b,QFe,{[re]:ww},[c1],[[()=>Wre,{[re]:u1,[je]:1}]]],tze=[3,b,ZFe,0,[le,Ee],[[0,1],[0,{[g]:we}]]],rze=[3,b,tqe,0,[Lw],[[()=>zre,16]]],nze=[3,b,rqe,0,[le,Ee],[[0,1],[0,{[g]:we}]]],ize=[3,b,aqe,0,[Sm],[[()=>tN,16]]],oze=[3,b,cqe,0,[le,Mr,Ee],[[0,1],[0,{[Ce]:Ki}],[0,{[g]:we}]]],sze=[3,b,iqe,0,[wm],[[()=>rN,16]]],aze=[3,b,oqe,0,[le,Mr,Ee],[[0,1],[0,{[Ce]:Ki}],[0,{[g]:we}]]],cze=[3,b,fqe,{[re]:Qk},[Hm,H1],[[()=>Kre,{[re]:ld,[je]:1}],[0,{[g]:Q1}]]],uze=[3,b,dqe,0,[le,Ee],[[0,1],[0,{[g]:we}]]],lze=[3,b,pqe,{[re]:Jk},[Jk],[0]],fze=[3,b,mqe,0,[le,Ee],[[0,1],[0,{[g]:we}]]],dze=[3,b,hqe,{[re]:Ew},[A1],[[()=>kre,0]]],pze=[3,b,gqe,0,[le,Ee],[[0,1],[0,{[g]:we}]]],hze=[3,b,bqe,0,[_ee],[[()=>gze,16]]],mze=[3,b,wqe,0,[le,Ee],[[0,1],[0,{[g]:we}]]],gze=[3,b,_ee,0,[Dee],[()=>iWe]],yze=[3,b,xqe,0,[bee],[[()=>bze,16]]],_ze=[3,b,Tqe,0,[le,Ee],[[0,1],[0,{[g]:we}]]],bze=[3,b,bee,0,[Lee,Dn,qm],[()=>aWe,0,()=>eN]],Eze=[3,b,Eqe,0,[vm],[[()=>iN,16]]],wze=[3,b,Sqe,0,[le,Mr,Ee],[[0,1],[0,{[Ce]:Ki}],[0,{[g]:we}]]],Sze=[3,b,Rqe,0,[le,Ee],[[0,1],[0,{[g]:we}]]],vze=[3,b,Oqe,0,[Aw],[[()=>qre,16]]],Cze=[3,b,Iqe,0,[le,Ee],[[0,1],[0,{[g]:we}]]],xze=[3,b,kqe,0,[nte],[[0,16]]],Tze=[3,b,Nqe,0,[le,Ee],[[0,1],[0,{[g]:we}]]],Aze=[3,b,Lqe,0,[Zee],[[()=>PWe,16]]],Rze=[3,b,Bqe,0,[le,Ee],[[0,1],[0,{[g]:we}]]],Pze=[3,b,qqe,0,[Iw],[[()=>Hre,16]]],Oze=[3,b,$qe,0,[le,Ee],[[0,1],[0,{[g]:we}]]],Ize=[3,b,Uqe,{[re]:Dw},[ete],[0]],Dze=[3,b,Hqe,0,[le,Ee],[[0,1],[0,{[g]:we}]]],kze=[3,b,zqe,{[re]:yo},[$v],[[()=>Ks,0]]],Nze=[3,b,Vqe,0,[le,Ee],[[0,1],[0,{[g]:we}]]],Mze=[3,b,Kqe,{[re]:Bw},[Dn,Mee],[0,[0,{[re]:kee}]]],Lze=[3,b,Yqe,0,[le,Ee],[[0,1],[0,{[g]:we}]]],Bze=[3,b,Jqe,{[re]:Fw},[k1,S1,h1,M1],[()=>Ure,()=>Ore,()=>Rre,[()=>Xre,0]]],Fze=[3,b,Qqe,0,[le,Ee],[[0,1],[0,{[g]:we}]]],qze=[3,b,tje,{[re]:Du},[bo,Nv,Kt],[()=>Ws,[()=>Yv,{[re]:Iv}],[0,{[g]:Zt}]]],jze=[3,b,ije,0,[le,tt,It,Mt,Ee],[[0,1],[0,1],[0,{[Ce]:pi}],[0,{[g]:Lt}],[0,{[g]:we}]]],Uze=[3,b,rje,{[re]:oje},[ku,is,It,Kt,Jr,BZ,V4e,kn,K4e],[[2,{[g]:Wv}],[4,{[g]:R1}],[0,{[g]:os}],[0,{[g]:Zt}],0,()=>F8e,[()=>Hze,0],0,1]],Hze=[3,b,nje,0,[C6e,Fv,zee,Lv,ns,qv],[[1,{[re]:Bv}],0,0,1,2,[()=>A7e,{[re]:jv,[je]:1}]]],$ze=[3,b,sje,0,[le,tt,It,Lv,Fv,Lr,Vi,Br,Mt,Ee,D4e],[[0,1],[0,1],[0,{[Ce]:pi}],[1,{[g]:s8e}],[0,{[g]:l8e}],[0,{[g]:Qr}],[()=>wo,{[g]:Eo}],[0,{[g]:Zr}],[0,{[g]:Lt}],[0,{[g]:we}],[64,{[g]:a8e}]]],Gze=[3,b,dje,0,[Tw],[[()=>Lre,{[re]:Tw,[gt]:1}]]],zze=[3,b,pje,0,[le,tt,It,Mt,Ee],[[0,1],[0,1],[0,{[Ce]:pi}],[0,{[g]:Lt}],[0,{[g]:we}]]],Vze=[3,b,uje,0,[Rw],[[()=>Mre,16]]],Wze=[3,b,lje,0,[le,Ee],[[0,1],[0,{[g]:we}]]],Kze=[3,b,hje,0,[Om,ku,n1,rs,F1,is,Lm,Jr,Kn,Yn,Xn,Jn,Qn,vi,O1,It,Vf,Wf,Kf,Yf,l1,Xf,go,Sw,Gm,li,od,Lr,Br,Zn,Wn,kn,Kt,L1,Bv,U1,cd,ud,ad],[[()=>Zm,16],[2,{[g]:Wv}],[0,{[g]:Vte}],[0,{[g]:Wm}],[0,{[g]:wre}],[4,{[g]:R1}],[1,{[g]:Mm}],[0,{[g]:Jr}],[0,{[g]:Fu}],[0,{[g]:qu}],[0,{[g]:ju}],[0,{[g]:Uu}],[0,{[g]:Hu}],[0,{[g]:md}],[1,{[g]:bre}],[0,{[g]:os}],[0,{[g]:Im}],[0,{[g]:Dm}],[0,{[g]:km}],[0,{[g]:Nm}],[0,{[g]:HZ}],[0,{[g]:Bm}],[4,{[g]:go}],[0,{[g]:Sw}],[0,{[g]:Qm}],[0,{[g]:xi}],[128,{[pd]:Ed}],[0,{[g]:Qr}],[0,{[g]:Zr}],[()=>dn,{[g]:Ti}],[2,{[g]:Ai}],[0,{[g]:Jm}],[0,{[g]:Zt}],[0,{[g]:Sre}],[1,{[g]:Ere}],[1,{[g]:Cre}],[0,{[g]:Ym}],[5,{[g]:Xm}],[0,{[g]:Km}]]],Yze=[3,b,mje,0,[le,nd,Cee,jm,Aee,tt,kw,ute,lte,fte,dte,pte,hte,It,Lr,Vi,Br,Mt,Lu,Ee,qZ],[[0,1],[0,{[g]:Nu}],[4,{[g]:v1}],[0,{[g]:id}],[4,{[g]:x1}],[0,1],[0,{[g]:kw}],[0,{[Ce]:Yte}],[0,{[Ce]:Xte}],[0,{[Ce]:Jte}],[0,{[Ce]:Qte}],[0,{[Ce]:Zte}],[6,{[Ce]:ere}],[0,{[Ce]:pi}],[0,{[g]:Qr}],[()=>wo,{[g]:Eo}],[0,{[g]:Zr}],[0,{[g]:Lt}],[1,{[Ce]:Vv}],[0,{[g]:we}],[0,{[g]:ure}]]],Xze=[3,b,gje,0,[Nw],[[()=>Bre,{[re]:Nw,[gt]:1}]]],Jze=[3,b,yje,0,[le,tt,It,Mt,Ee],[[0,1],[0,1],[0,{[Ce]:pi}],[0,{[g]:Lt}],[0,{[g]:we}]]],Qze=[3,b,Eje,{[re]:yo},[It,$v],[[0,{[g]:os}],[()=>Ks,0]]],Zze=[3,b,Sje,0,[le,tt,It,Ee,Mt],[[0,1],[0,1],[0,{[Ce]:pi}],[0,{[g]:we}],[0,{[g]:Lt}]]],eVe=[3,b,wje,0,[Om,Kt],[[()=>Zm,16],[0,{[g]:Zt}]]],tVe=[3,b,vje,0,[le,tt,Mt,Ee],[[0,1],[0,1],[0,{[g]:Lt}],[0,{[g]:we}]]],rVe=[3,b,Tje,0,[Pw],[[()=>jre,16]]],nVe=[3,b,Aje,0,[le,Ee],[[0,1],[0,{[g]:we}]]],iVe=[3,b,Eee,0,[qte],[0]],oVe=[3,b,E1,0,[w1,rte],[[()=>Pre,{[ire]:[nre,Wte]}],0]],Pre=[3,b,w1,0,[p1,vFe,rd,j6e,$m],[0,0,0,0,[0,{[re]:S8e,[c$e]:1}]]],sVe=[3,b,Pje,0,[i1,M2e,N2e,s1,C2e],[[0,{[g]:are}],[0,{[g]:d$e}],[0,{[g]:f$e}],[0,{[g]:h$e}],[2,{[g]:u$e}]]],aVe=[3,b,Oje,0,[le,Ee],[[0,1],[0,{[g]:we}]]],cVe=[3,b,kje,0,[ku,n1,rs,F1,R2e,is,Lm,Kn,Yn,Xn,Jn,Qn,vi,Jr,O1,It,Vf,Wf,Kf,Yf,Xf,l1,go,Sw,Gm,li,od,Lr,Br,Zn,Wn,kn,Kt,L1,Bv,U1,cd,ud,ad],[[2,{[g]:Wv}],[0,{[g]:Vte}],[0,{[g]:Wm}],[0,{[g]:wre}],[0,{[g]:l$e}],[4,{[g]:R1}],[1,{[g]:Mm}],[0,{[g]:Fu}],[0,{[g]:qu}],[0,{[g]:ju}],[0,{[g]:Uu}],[0,{[g]:Hu}],[0,{[g]:md}],[0,{[g]:Jr}],[1,{[g]:bre}],[0,{[g]:os}],[0,{[g]:Im}],[0,{[g]:Dm}],[0,{[g]:km}],[0,{[g]:Nm}],[0,{[g]:Bm}],[0,{[g]:HZ}],[4,{[g]:go}],[0,{[g]:Sw}],[0,{[g]:Qm}],[0,{[g]:xi}],[128,{[pd]:Ed}],[0,{[g]:Qr}],[0,{[g]:Zr}],[()=>dn,{[g]:Ti}],[2,{[g]:Ai}],[0,{[g]:Jm}],[0,{[g]:Zt}],[0,{[g]:Sre}],[1,{[g]:Ere}],[1,{[g]:Cre}],[0,{[g]:Ym}],[5,{[g]:Xm}],[0,{[g]:Km}]]],uVe=[3,b,Nje,0,[le,nd,Cee,jm,Aee,tt,kw,ute,lte,fte,dte,pte,hte,It,Lr,Vi,Br,Mt,Lu,Ee,qZ],[[0,1],[0,{[g]:Nu}],[4,{[g]:v1}],[0,{[g]:id}],[4,{[g]:x1}],[0,1],[0,{[g]:kw}],[0,{[Ce]:Yte}],[0,{[Ce]:Xte}],[0,{[Ce]:Jte}],[0,{[Ce]:Qte}],[0,{[Ce]:Zte}],[6,{[Ce]:ere}],[0,{[Ce]:pi}],[0,{[g]:Qr}],[()=>wo,{[g]:Eo}],[0,{[g]:Zr}],[0,{[g]:Lt}],[1,{[Ce]:Vv}],[0,{[g]:we}],[0,{[g]:ure}]]],lVe=[-3,b,Wje,{[di]:fi,[Ci]:400},[],[]];On.TypeRegistry.for(b).registerError(lVe,SZ);var Ore=[3,b,S1,0,[d6e],[0]],Ire=[3,b,T1,0,[rd,p1],[0,0]],Dre=[3,b,C1,0,[XZ,_3e,Ree,c5e],[()=>aGe,0,()=>AVe,()=>TWe]],fVe=[3,b,Qje,0,[Gt,dd],[0,[()=>Ks,{[re]:Wi,[je]:1}]]],tN=[3,b,Sm,0,[Mr,zs,Dn,x6e],[0,[()=>dVe,0],0,[()=>D7e,{[re]:jte,[je]:1}]]],dVe=[3,b,eUe,0,[Gt,Wi,Pm],[0,()=>wd,[()=>fVe,0]]],pVe=[-3,b,zje,{[di]:fi,[Ci]:403},[kn,DZ],[0,0]];On.TypeRegistry.for(b).registerError(pVe,cZ);var hVe=[-3,b,Kje,{[di]:fi,[Ci]:400},[],[]];On.TypeRegistry.for(b).registerError(hVe,gZ);var mVe=[-3,b,tUe,{[di]:fi,[Ci]:400},[],[]];On.TypeRegistry.for(b).registerError(mVe,_Z);var rN=[3,b,wm,0,[kv,Bje,zs,Mr,Vje,L4e,l6e],[[()=>gVe,0],2,()=>_Ve,0,0,[()=>_7e,0],()=>EVe]],gVe=[3,b,Lje,0,[wte],[[()=>bVe,0]]],yVe=[3,b,Fje,0,[Ote,Pte],[[()=>H9e,{[re]:Ate}],[()=>j9e,{[re]:vte}]]],_Ve=[3,b,qje,0,[Gt],[0]],bVe=[3,b,Xje,0,[g2e,le,yee,Gt,g1],[0,0,0,0,[()=>yVe,0]]],EVe=[3,b,Jje,0,[FFe],[0]],wVe=[3,b,vw,0,[d1,Fm],[0,()=>nN]],SVe=[3,b,Tee,0,[d1,Fte,qm,Hv,q1],[0,0,()=>eN,0,0]],vVe=[3,b,Zje,0,[d1,Fm],[0,()=>nN]],CVe=[3,b,Cw,0,[Uv,Fm],[()=>sN,()=>nN]],xVe=[3,b,Pee,0,[Fte,qm,Hv,q1,Uv],[0,()=>eN,0,0,()=>sN]],TVe=[3,b,oUe,0,[Uv],[()=>sN]],AVe=[3,b,nUe,0,[$m],[0]],RVe=[3,b,iUe,0,[N1],[0]],PVe=[3,b,LUe,0,[Mr,MUe,y1,zs],[0,[0,{[re]:W2e}],[64,{[re]:_1,[je]:1}],[()=>oN,0]]],OVe=[3,b,NUe,0,[iee,Jf,RFe],[5,1,2]],IVe=[3,b,s4e,0,[rs,rd,Gt,zs,Dn,R6e,O4e,Vee,PZ],[()=>OVe,0,0,[()=>kVe,0],0,[()=>N7e,{[re]:Hte,[je]:1}],[()=>S7e,{[re]:Wee,[je]:1}],()=>fWe,()=>v8e]],DVe=[3,b,a4e,0,[Gt,dd,Xee,Jee],[0,[()=>Ks,{[re]:Wi,[je]:1}],1,1]],kVe=[3,b,c4e,0,[Gt,Wi,Xee,Jee,Pm],[0,()=>wd,1,1,[()=>DVe,0]]],NVe=[3,b,yUe,{[re]:_Ue},[ns,ui,Um,TZ],[2,0,0,[()=>u7e,{[re]:Em,[je]:1}]]],MVe=[3,b,bUe,0,[le,ui,Ee],[[0,1],[0,{[Ce]:Bu}],[0,{[g]:we}]]],LVe=[3,b,CUe,0,[ns,ui,Um,xee],[2,0,0,[()=>g7e,{[re]:Sm,[je]:1}]]],BVe=[3,b,xUe,0,[le,ui,Ee],[[0,1],[0,{[Ce]:Bu}],[0,{[g]:we}]]],FVe=[3,b,wUe,{[re]:jUe},[ui,See,ns,Um],[0,[()=>y7e,{[re]:wm,[je]:1}],2,0]],qVe=[3,b,SUe,0,[le,ui,Ee],[[0,1],[0,{[Ce]:Bu}],[0,{[g]:we}]]],jVe=[3,b,AUe,{[re]:UUe},[ns,ui,Um,Iee],[2,0,0,[()=>E7e,{[re]:vm,[je]:1}]]],UVe=[3,b,RUe,0,[le,ui,Ee],[[0,1],[0,{[Ce]:Bu}],[0,{[g]:we}]]],HVe=[3,b,PUe,{[re]:pUe},[a1,bo,ui,Gt],[[()=>Vre,0],()=>Ws,0,0]],$Ve=[3,b,OUe,0,[p4e,ui,Gt,s1],[[1,{[Ce]:e$e}],[0,{[Ce]:Bu}],[0,{[Ce]:zm}],[0,{[Ce]:K6e}]]],GVe=[3,b,DUe,{[re]:hUe},[a1,ui],[[()=>Vre,0],0]],zVe=[3,b,kUe,0,[ui,m4e],[[0,{[Ce]:Bu}],[1,{[Ce]:t$e}]]],VVe=[3,b,GUe,{[re]:zUe},[le,Mv,$te,$ee,Gt,fc,R4e,Fee,ns,P6e,Dv,dc,Kt],[0,0,0,0,0,0,0,1,2,[()=>w7e,{[re]:U6e,[je]:1}],[()=>Kv,{[je]:1}],0,[0,{[g]:Zt}]]],WVe=[3,b,VUe,0,[le,fc,dc,Mv,Fee,Gt,$te,Ee,Mt],[[0,1],[0,{[Ce]:Gv}],[0,{[Ce]:zv}],[0,{[Ce]:Kte}],[1,{[Ce]:n$e}],[0,{[Ce]:zm}],[0,{[Ce]:s$e}],[0,{[g]:we}],[0,{[g]:Lt}]]],KVe=[3,b,KUe,{[re]:Oee},[ns,qee,C4e,ZZ,Mu,Gt,fc,sd,Dv,dc,Kt],[2,0,0,[()=>Yre,{[je]:1}],0,0,0,1,[()=>Kv,{[je]:1}],0,[0,{[g]:Zt}]]],YVe=[3,b,YUe,0,[le,fc,dc,qee,sd,Gt,Mt,Ee,I1],[[0,1],[0,{[Ce]:Gv}],[0,{[Ce]:zv}],[0,{[Ce]:Z6e}],[1,{[Ce]:z1}],[0,{[Ce]:zm}],[0,{[g]:Lt}],[0,{[g]:we}],[64,{[g]:X1}]]],XVe=[3,b,JUe,{[re]:Oee},[ns,ZZ,Mu,Gt,fc,sd,Dv,dc,sUe,ui,Um,Ete,Kt],[2,[()=>Yre,{[je]:1}],0,0,0,1,[()=>Kv,{[je]:1}],0,1,0,0,0,[0,{[g]:Zt}]]],JVe=[3,b,ZUe,0,[le,fc,dc,sd,Gt,ui,NFe,Ete,Mt,Ee,I1],[[0,1],[0,{[Ce]:Gv}],[0,{[Ce]:zv}],[1,{[Ce]:z1}],[0,{[Ce]:zm}],[0,{[Ce]:Bu}],[2,{[Ce]:X6e}],[0,{[Ce]:o$e}],[0,{[g]:Lt}],[0,{[g]:we}],[64,{[g]:X1}]]],QVe=[3,b,QUe,{[re]:l4e},[ns,Mv,zte,$ee,P4e,H6e,tee,Mu,Gt,fc,sd,Dv,dc,Kt],[2,0,0,0,0,[()=>C7e,{[re]:$6e,[je]:1}],[()=>d7e,{[re]:ku,[je]:1}],0,0,0,1,[()=>Kv,{[je]:1}],0,[0,{[g]:Zt}]]],ZVe=[3,b,e4e,0,[le,fc,dc,Mv,sd,Gt,zte,Ee,Mt,I1],[[0,1],[0,{[Ce]:Gv}],[0,{[Ce]:zv}],[0,{[Ce]:Kte}],[1,{[Ce]:z1}],[0,{[Ce]:zm}],[0,{[Ce]:a$e}],[0,{[g]:we}],[0,{[g]:Lt}],[64,{[g]:X1}]]],eWe=[3,b,n4e,{[re]:i4e},[RZ,IZ,le,tt,pc,Fv,zee,Lv,ns,qv,T1,bo,kn,Kt,pt,vi],[[4,{[g]:ore}],[0,{[g]:sre}],0,0,0,0,0,1,2,[()=>T7e,{[re]:jv,[je]:1}],()=>Ire,()=>Ws,0,[0,{[g]:Zt}],0,0]],tWe=[3,b,o4e,0,[le,tt,Lv,Fv,pc,Mt,Ee,Lr,Vi,Br],[[0,1],[0,1],[1,{[Ce]:r$e}],[0,{[Ce]:i$e}],[0,{[Ce]:Vm}],[0,{[g]:Lt}],[0,{[g]:we}],[0,{[g]:Qr}],[()=>wo,{[g]:Eo}],[0,{[g]:Zr}]]],rWe=[3,b,qUe,0,[$m,Mu],[0,0]],kre=[3,b,A1,0,[h6e,Mte,v6e,Bte],[0,[()=>I7e,0],0,[()=>K9e,0]]],nWe=[3,b,Zk,0,[Cw,vw],[()=>CVe,()=>wVe]],iWe=[3,b,Dee,0,[nee,Pee,Tee],[()=>BGe,()=>xVe,()=>SVe]],oWe=[3,b,Nee,0,[Mu,$1],[0,0]],sWe=[3,b,e1,0,[Ite],[()=>P9e]],aWe=[3,b,Lee,0,[Dte],[()=>O9e]],nN=[3,b,_4e,0,[q5e,cUe],[0,0]],cWe=[3,b,jee,0,[Dn,IFe],[0,()=>$re]],uWe=[3,b,f4e,0,[Gt,dd,OZ],[0,[()=>Ks,{[re]:Wi,[je]:1}],0]],iN=[3,b,vm,0,[Mr,zs],[0,[()=>B7e,0]]],lWe=[3,b,Bee,0,[pc,tt,rUe,kn,bo,T1,pt,vi],[0,0,4,0,()=>Ws,()=>Ire,0,0]],fWe=[3,b,Vee,0,[Hee,Gee],[1,1]],dWe=[3,b,Wee,0,[Hee,kn,Gee],[1,0,1]],pWe=[-3,b,x4e,{[di]:fi,[Ci]:404},[],[]];On.TypeRegistry.for(b).registerError(pWe,sZ);var hWe=[-3,b,T4e,{[di]:fi,[Ci]:404},[],[]];On.TypeRegistry.for(b).registerError(hWe,lZ);var mWe=[-3,b,A4e,{[di]:fi,[Ci]:404},[],[]];On.TypeRegistry.for(b).registerError(mWe,QQ);var gWe=[-3,b,v4e,{[di]:fi},[],[]];On.TypeRegistry.for(b).registerError(gWe,dZ);var Nre=[3,b,t1,0,[y6e,p5e,FUe,see],[[()=>k7e,{[re]:Nte,[je]:1}],[()=>R7e,{[re]:ate,[je]:1}],[()=>b7e,{[re]:K2e,[je]:1}],()=>$Ge]],oN=[3,b,S4e,0,[tt],[[()=>A9e,{[re]:Q5e}]]],yWe=[3,b,Qee,0,[tt,is,Jr,pt,vi,fd,kn,bo,B1],[0,4,0,[64,{[je]:1}],0,1,0,()=>Ws,()=>Gre]],_We=[-3,b,k4e,{[di]:fi,[Ci]:403},[],[]];On.TypeRegistry.for(b).registerError(_We,CZ);var bWe=[3,b,B4e,0,[tt,It,Jr,HUe,fd],[0,0,0,6,1]],Mre=[3,b,Rw,0,[q4e,ld],[0,()=>EWe]],Lre=[3,b,U4e,0,[Dn],[0]],Bre=[3,b,H4e,0,[Uee,L5e],[0,5]],EWe=[3,b,$4e,0,[ree],[()=>uGe]],wWe=[-3,b,z4e,{[di]:fi,[Ci]:403},[],[]];On.TypeRegistry.for(b).registerError(wWe,eZ);var SWe=[3,b,W4e,0,[Lu,fd,Kn,Yn,Xn,Jn,Qn],[1,1,0,0,0,0,0]],vWe=[3,b,X4e,0,[Jr,pt,vi,fd,kn,tt,It,vee,is,bo,B1],[0,[64,{[je]:1}],0,1,0,0,0,2,4,()=>Ws,()=>Gre]],CWe=[3,b,Kee,0,[u6e],[[()=>R9e,0]]],Fre=[3,b,D1,0,[XZ,Ree],[()=>cGe,()=>RVe]],Ws=[3,b,bo,0,[p1,rd],[0,0]],qre=[3,b,Aw,0,[Hm],[[()=>x7e,{[re]:ld,[je]:1}]]],xWe=[3,b,N4e,0,[Yee],[0]],TWe=[3,b,jHe,0,[],[]],AWe=[3,b,jv,0,[Lu,is,Jr,fd,Kn,Yn,Xn,Jn,Qn],[1,4,0,1,0,0,0,0,0]],RWe=[3,b,Ow,{[re]:Ow},[FHe],[0]],PWe=[3,b,Zee,0,[zQ],[[2,{[re]:zQ}]]],OWe=[3,b,ite,0,[LZ,NZ,MZ],[1,1,1]],IWe=[3,b,qHe,0,[oee],[[()=>OWe,{[G1]:1}]]],jre=[3,b,Pw,0,[HQ,VQ,$Q,WQ],[[2,{[re]:HQ}],[2,{[re]:VQ}],[2,{[re]:$Q}],[2,{[re]:WQ}]]],DWe=[3,b,iHe,0,[le,ir,pt,Ee,bw],[[0,1],[0,{[g]:nr}],[0,{[g]:jt}],[0,{[g]:we}],[()=>Tre,{[re]:bw,[gt]:1}]]],kWe=[3,b,tHe,0,[le,_w,Ee,pt],[[0,1],[()=>T8e,{[re]:_w,[gt]:1}],[0,{[g]:we}],[0,{[g]:jt}]]],NWe=[3,b,oHe,0,[zf,Du,le,ir,pt,Qf,Zf,ed,b1,td,Ee],[[0,{[g]:hd}],[()=>Are,{[re]:Du,[gt]:1}],[0,1],[0,{[g]:nr}],[0,{[g]:jt}],[0,{[g]:gd}],[0,{[g]:yd}],[0,{[g]:_d}],[0,{[g]:K1}],[0,{[g]:bd}],[0,{[g]:we}]]],MWe=[3,b,rHe,0,[le,Mr,Em,Ee],[[0,1],[0,{[Ce]:Ki}],[()=>Z1,{[re]:Em,[gt]:1}],[0,{[g]:we}]]],LWe=[3,b,cHe,0,[le,ww,ir,pt,Ee],[[0,1],[()=>X8e,{[re]:ww,[gt]:1}],[0,{[g]:nr}],[0,{[g]:jt}],[0,{[g]:we}]]],BWe=[3,b,lHe,0,[le,ir,pt,Lw,Ee],[[0,1],[0,{[g]:nr}],[0,{[g]:jt}],[()=>zre,{[re]:Lw,[gt]:1}],[0,{[g]:we}]]],FWe=[3,b,hHe,0,[le,Mr,Ee,Sm],[[0,1],[0,{[Ce]:Ki}],[0,{[g]:we}],[()=>tN,{[re]:Sm,[gt]:1}]]],qWe=[3,b,dHe,0,[le,Mr,wm,Ee],[[0,1],[0,{[Ce]:Ki}],[()=>rN,{[re]:wm,[gt]:1}],[0,{[g]:we}]]],jWe=[3,b,yHe,0,[H1],[[0,{[g]:Q1}]]],UWe=[3,b,_He,0,[le,pt,Qk,Ee,H1],[[0,1],[0,{[g]:jt}],[()=>L8e,{[re]:Qk,[gt]:1}],[0,{[g]:we}],[0,{[g]:Q1}]]],HWe=[3,b,bHe,0,[le,Ew,ir,pt,Ee],[[0,1],[()=>B8e,{[re]:Ew,[gt]:1}],[0,{[g]:nr}],[0,{[g]:jt}],[0,{[g]:we}]]],$We=[3,b,wHe,0,[le,Mr,vm,Ee],[[0,1],[0,{[Ce]:Ki}],[()=>iN,{[re]:vm,[gt]:1}],[0,{[g]:we}]]],GWe=[3,b,vHe,0,[le,t1,Ee,z5e],[[0,1],[()=>Nre,{[re]:t1,[gt]:1}],[0,{[g]:we}],[2,{[g]:b8e}]]],zWe=[3,b,xHe,0,[le,ir,Ee,Aw,pt],[[0,1],[0,{[g]:nr}],[0,{[g]:we}],[()=>qre,{[re]:Aw,[gt]:1}],[0,{[g]:jt}]]],VWe=[3,b,AHe,0,[le,ir,pt,u3e,nte,Ee],[[0,1],[0,{[g]:nr}],[0,{[g]:jt}],[2,{[g]:m$e}],[0,16],[0,{[g]:we}]]],WWe=[3,b,IHe,0,[le,ir,pt,Iw,Ute,Ee],[[0,1],[0,{[g]:nr}],[0,{[g]:jt}],[()=>Hre,{[re]:Iw,[gt]:1}],[0,{[g]:cre}],[0,{[g]:we}]]],KWe=[3,b,OHe,0,[le,ir,pt,Dw,Ee],[[0,1],[0,{[g]:nr}],[0,{[g]:jt}],[()=>w9e,{[re]:Dw,[gt]:1}],[0,{[g]:we}]]],YWe=[3,b,kHe,0,[le,ir,pt,yo,Ee],[[0,1],[0,{[g]:nr}],[0,{[g]:jt}],[()=>aN,{[re]:yo,[gt]:1}],[0,{[g]:we}]]],XWe=[3,b,MHe,0,[le,ir,pt,P1,Bw,Ee],[[0,1],[0,{[g]:nr}],[0,{[g]:jt}],[0,{[g]:Y1}],[()=>o7e,{[re]:Bw,[gt]:1}],[0,{[g]:we}]]],JWe=[3,b,BHe,0,[le,ir,pt,Fw,Ee],[[0,1],[0,{[g]:nr}],[0,{[g]:jt}],[()=>s7e,{[re]:Fw,[gt]:1}],[0,{[g]:we}]]],QWe=[3,b,GHe,0,[Kt],[[0,{[g]:Zt}]]],ZWe=[3,b,zHe,0,[zf,Du,le,ir,pt,Qf,Zf,ed,b1,td,tt,Mt,It,Ee],[[0,{[g]:hd}],[()=>Are,{[re]:Du,[gt]:1}],[0,1],[0,{[g]:nr}],[0,{[g]:jt}],[0,{[g]:gd}],[0,{[g]:yd}],[0,{[g]:_d}],[0,{[g]:K1}],[0,{[g]:bd}],[0,1],[0,{[g]:Lt}],[0,{[Ce]:pi}],[0,{[g]:we}]]],e9e=[3,b,XHe,0,[Kt],[[0,{[g]:Zt}]]],t9e=[3,b,JHe,0,[le,tt,Tw,Mt,It,ir,pt,Ee],[[0,1],[0,1],[()=>Lre,{[re]:Tw,[gt]:1}],[0,{[g]:Lt}],[0,{[Ce]:pi}],[0,{[g]:nr}],[0,{[g]:jt}],[0,{[g]:we}]]],r9e=[3,b,WHe,0,[Kt],[[0,{[g]:Zt}]]],n9e=[3,b,KHe,0,[le,Rw,Mt,Ute,ir,pt,Ee],[[0,1],[()=>Mre,{[re]:Rw,[gt]:1}],[0,{[g]:Lt}],[0,{[g]:cre}],[0,{[g]:nr}],[0,{[g]:jt}],[0,{[g]:we}]]],i9e=[3,b,QHe,0,[rs,Jr,Kn,Yn,Xn,Jn,Qn,vi,li,It,Lr,Br,Zn,Vs,Wn,fd,Kt],[[0,{[g]:Wm}],[0,{[g]:Jr}],[0,{[g]:Fu}],[0,{[g]:qu}],[0,{[g]:ju}],[0,{[g]:Uu}],[0,{[g]:Hu}],[0,{[g]:md}],[0,{[g]:xi}],[0,{[g]:os}],[0,{[g]:Qr}],[0,{[g]:Zr}],[()=>dn,{[g]:Ti}],[()=>mc,{[g]:hc}],[2,{[g]:Ai}],[1,{[g]:u8e}],[0,{[g]:Zt}]]],o9e=[3,b,ZHe,0,[zf,Om,le,Vf,Wf,Kf,Yf,Lm,ir,Xf,pt,Kn,Yn,Xn,Jn,Qn,go,nd,jm,Qf,Zf,ed,td,tt,V6e,od,li,kn,Gm,Lr,Vi,Br,Zn,Vs,Wn,Mt,yo,cd,ud,ad,Ee],[[0,{[g]:hd}],[()=>Zm,16],[0,1],[0,{[g]:Im}],[0,{[g]:Dm}],[0,{[g]:km}],[0,{[g]:Nm}],[1,{[g]:Mm}],[0,{[g]:nr}],[0,{[g]:Bm}],[0,{[g]:jt}],[0,{[g]:Fu}],[0,{[g]:qu}],[0,{[g]:ju}],[0,{[g]:Uu}],[0,{[g]:Hu}],[4,{[g]:go}],[0,{[g]:Nu}],[0,{[g]:id}],[0,{[g]:gd}],[0,{[g]:yd}],[0,{[g]:_d}],[0,{[g]:bd}],[0,1],[1,{[g]:w8e}],[128,{[pd]:Ed}],[0,{[g]:xi}],[0,{[g]:Jm}],[0,{[g]:Qm}],[0,{[g]:Qr}],[()=>wo,{[g]:Eo}],[0,{[g]:Zr}],[()=>dn,{[g]:Ti}],[()=>mc,{[g]:hc}],[2,{[g]:Ai}],[0,{[g]:Lt}],[0,{[g]:J1}],[0,{[g]:Ym}],[5,{[g]:Xm}],[0,{[g]:Km}],[0,{[g]:we}]]],s9e=[3,b,e5e,0,[Kt],[[0,{[g]:Zt}]]],a9e=[3,b,t5e,0,[le,tt,Nw,Mt,It,o1,ir,pt,Ee],[[0,1],[0,1],[()=>Bre,{[re]:Nw,[gt]:1}],[0,{[g]:Lt}],[0,{[Ce]:pi}],[2,{[g]:V1}],[0,{[g]:nr}],[0,{[g]:jt}],[0,{[g]:we}]]],c9e=[3,b,i5e,0,[It],[[0,{[g]:os}]]],u9e=[3,b,o5e,0,[le,tt,It,ir,pt,yo,Ee,Mt],[[0,1],[0,1],[0,{[Ce]:pi}],[0,{[g]:nr}],[0,{[g]:jt}],[()=>aN,{[re]:yo,[gt]:1}],[0,{[g]:we}],[0,{[g]:Lt}]]],l9e=[3,b,a5e,0,[le,ir,pt,Pw,Ee],[[0,1],[0,{[g]:nr}],[0,{[g]:jt}],[()=>jre,{[re]:Pw,[gt]:1}],[0,{[g]:we}]]],f9e=[3,b,ate,0,[Mr,f5e,y1,zs],[0,[0,{[re]:m5e}],[64,{[re]:_1,[je]:1}],[()=>oN,0]]],sN=[3,b,Uv,0,[rs,Jf],[0,1]],d9e=[3,b,y5e,0,[tte],[[21,{[G1]:1}]]],p9e=[3,b,bte,0,[wee,Mje,ote,b5e,E5e],[0,0,0,0,0]],Ure=[3,b,k1,0,[wee,ote],[0,0]],h9e=[3,b,S5e,0,[],[]],m9e=[3,b,x5e,0,[le,tt,k5e,eFe,rFe,tFe,nFe,W5e,Y5e,K5e,X5e,y3e],[[0,1],[0,1],[0,{[g]:p8e}],[0,{[g]:Nu}],[0,{[g]:id}],[4,{[g]:v1}],[4,{[g]:x1}],[0,{[g]:h8e}],[0,{[g]:g8e}],[6,{[g]:m8e}],[6,{[g]:y8e}],[0,{[g]:_$e,[Q6e]:1}]]],g9e=[3,b,mte,0,[Dn],[0]],Hre=[3,b,Iw,0,[F5e,Hm],[0,[()=>P7e,{[re]:ld,[je]:1}]]],y9e=[3,b,O5e,0,[rd,u5e,Gt,zs,Dn,Rte,uee,kv,eee],[0,1,0,[()=>b9e,0],0,()=>q9e,()=>GGe,()=>LGe,()=>RGe]],_9e=[3,b,R5e,0,[Gt,dd],[0,[()=>Ks,{[re]:Wi,[je]:1}]]],b9e=[3,b,P5e,0,[Gt,Wi,Pm],[0,()=>wd,[()=>_9e,0]]],E9e=[3,b,_te,0,[Dn,T6e],[0,()=>$re]],$re=[3,b,N5e,0,[w4e],[1]],w9e=[3,b,Dw,0,[ete],[0]],S9e=[3,b,gte,0,[DFe],[2]],v9e=[3,b,v5e,0,[Kt,C5e],[[0,{[g]:Zt}],[0,{[g]:f8e}]]],C9e=[3,b,T5e,0,[le,tt,It,r1,Mt,pt,Ee],[[0,1],[0,1],[0,{[Ce]:pi}],[()=>x9e,{[gt]:1,[re]:r1}],[0,{[g]:Lt}],[0,{[g]:jt}],[0,{[g]:we}]]],x9e=[3,b,r1,0,[Jf,Eee,$m,qte,SFe,xte,Kee],[1,()=>iVe,0,0,0,()=>N9e,[()=>CWe,0]]],Gre=[3,b,B1,0,[Yje,g5e],[2,4]],T9e=[3,b,yte,0,[QZ,bte],[()=>G8e,()=>p9e]],A9e=[3,b,J5e,0,[LFe],[[()=>m7e,{[re]:gee,[je]:1}]]],R9e=[3,b,Z5e,0,[L2e,Gt,g1,B2e,Iv,yo,Gte,kn],[0,0,[()=>FGe,0],0,[()=>Yv,0],[()=>aN,0],[()=>M7e,0],0]],P9e=[3,b,Ite,0,[j1,Hv],[0,0]],O9e=[3,b,Dte,0,[j1,Hv,q1,Lte],[0,0,0,0]],I9e=[3,b,Tte,0,[f6e,dee],[1,1]],D9e=[3,b,n6e,0,[tte],[[()=>F7e,16]]],k9e=[3,b,i6e,0,[le,tt,Lr,Vi,Br,hee,fee,gte,C1,D1,Tte,Ee],[[0,1],[0,1],[0,{[g]:Qr}],[()=>wo,{[g]:Eo}],[0,{[g]:Zr}],0,0,()=>S9e,()=>Dre,()=>Fre,()=>I9e,[0,{[g]:we}]]],N9e=[3,b,xte,0,[C1,fee,hee,D1],[()=>Dre,0,0,()=>Fre]],M9e=[3,b,s6e,0,[o6e,fUe],[0,[()=>dn,0]]],zre=[3,b,Lw,0,[Hm],[[()=>O7e,{[re]:ld,[je]:1}]]],L9e=[3,b,a6e,0,[A2e,Wn,kZ],[[()=>M9e,0],2,[()=>I8e,0]]],B9e=[3,b,$5e,0,[UQ,KQ,YQ,rs],[[0,{[re]:UQ}],[()=>XQ,{[re]:KQ}],[()=>XQ,{[re]:YQ}],[4,{[re]:rs}]]],F9e=[3,b,Mw,{[re]:Mw},[],[]],q9e=[3,b,Rte,0,[Cte,mte],[()=>U9e,()=>g9e]],j9e=[3,b,Pte,{[re]:vte},[aUe],[[()=>dn,0]]],U9e=[3,b,Cte,0,[Dn],[0]],H9e=[3,b,Ote,{[re]:Ate},[],[]],$9e=[3,b,kte,0,[LZ,NZ,MZ],[1,1,1]],G9e=[3,b,V5e,0,[oee],[[()=>$9e,{[G1]:1}]]],z9e=[3,b,Ste,0,[Z3e],[()=>V9e]],V9e=[3,b,U5e,0,[Y4e,kv],[0,()=>P8e]],wd=[3,b,Wi,0,[tt,$1],[0,0]],aN=[3,b,yo,0,[$v],[[()=>Ks,0]]],W9e=[3,b,b6e,0,[w1,rte],[[()=>Pre,{[ire]:[nre,Wte]}],0]],K9e=[3,b,Bte,0,[Mw,Ow],[[()=>F9e,{[re]:Mw}],[()=>RWe,{[re]:Ow}]]],Y9e=[3,b,jte,0,[Jf,DZ],[1,0]],X9e=[-3,b,S6e,{[di]:fi,[Ci]:400},[],[]];On.TypeRegistry.for(b).registerError(X9e,EZ);var J9e=[3,b,Nte,0,[Mr,p6e,y1,zs],[0,[0,{[re]:A6e}],[64,{[re]:_1,[je]:1}],[()=>oN,0]]],Q9e=[3,b,Hte,0,[iee,Jf,kn],[5,1,0]],Z9e=[3,b,I6e,0,[le,ir,pt,vw,Ee],[[0,1],[0,{[g]:nr}],[0,{[g]:jt}],[()=>vVe,{[re]:vw,[gt]:1}],[0,{[g]:we}]]],e7e=[3,b,k6e,0,[le,ir,pt,Cw,Ee],[[0,1],[0,{[g]:nr}],[0,{[g]:jt}],[()=>TVe,{[re]:Cw,[gt]:1}],[0,{[g]:we}]]],t7e=[3,b,L6e,0,[JZ,UZ,li,Lr,Br,Zn,Wn,Kt],[[0,{[g]:_re}],[()=>Y8e,16],[0,{[g]:xi}],[0,{[g]:Qr}],[0,{[g]:Zr}],[()=>dn,{[g]:Ti}],[2,{[g]:Ai}],[0,{[g]:Zt}]]],r7e=[3,b,B6e,0,[le,$Z,GZ,zZ,VZ,WZ,d3e,tt,Lu,pc,Lr,Vi,Br,KZ,f1,YZ,Mt,Ee,lee],[[0,1],[0,{[g]:lre}],[0,{[g]:fre}],[4,{[g]:dre}],[0,{[g]:pre}],[4,{[g]:hre}],[0,{[g]:y$e}],[0,1],[1,{[Ce]:Vv}],[0,{[Ce]:Vm}],[0,{[g]:Qr}],[()=>wo,{[g]:Eo}],[0,{[g]:Zr}],[0,{[g]:mre}],[()=>xre,{[g]:gre}],[0,{[g]:yre}],[0,{[g]:Lt}],[0,{[g]:we}],[0,{[g]:vre}]]],n7e=[3,b,F6e,0,[li,Jr,Kn,Yn,Xn,Jn,Qn,Lr,Br,Zn,Wn,Kt],[[0,{[g]:xi}],[0,{[g]:Jr}],[0,{[g]:Fu}],[0,{[g]:qu}],[0,{[g]:ju}],[0,{[g]:Uu}],[0,{[g]:Hu}],[0,{[g]:Qr}],[0,{[g]:Zr}],[()=>dn,{[g]:Ti}],[2,{[g]:Ai}],[0,{[g]:Zt}]]],i7e=[3,b,q6e,0,[Om,le,Lm,ir,pt,Kn,Yn,Xn,Jn,Qn,tt,Lu,pc,Lr,Vi,Br,Mt,Ee],[[()=>Zm,16],[0,1],[1,{[g]:Mm}],[0,{[g]:nr}],[0,{[g]:jt}],[0,{[g]:Fu}],[0,{[g]:qu}],[0,{[g]:ju}],[0,{[g]:Uu}],[0,{[g]:Hu}],[0,1],[1,{[Ce]:Vv}],[0,{[Ce]:Vm}],[0,{[g]:Qr}],[()=>wo,{[g]:Eo}],[0,{[g]:Zr}],[0,{[g]:Lt}],[0,{[g]:we}]]],o7e=[3,b,Bw,0,[Mee,Dn],[[0,{[re]:kee}],0]],s7e=[3,b,Fw,0,[h1,S1,k1,M1],[()=>Rre,()=>Ore,()=>Ure,[()=>Xre,0]]],a7e=[3,b,z6e,0,[D5e,M5e,Om,G5e,aee,cee,n1,Vf,Wf,Kf,Yf,Lm,l1,Xf,Kn,Yn,Xn,Jn,Qn,ku,Jr,go,rs,is,O1,od,cd,ad,ud,Bv,L1,Kt,F1,li,Lr,Zn,Br,kn,U1,It,Wn],[[0,{[J6e]:1,[g]:d8e}],[0,{[g]:_8e}],[()=>Zm,16],[1,{[g]:e8e}],[0,{[g]:b$e}],[0,{[g]:E$e}],[0,{[g]:O$e}],[0,{[g]:w$e}],[0,{[g]:S$e}],[0,{[g]:v$e}],[0,{[g]:C$e}],[1,{[g]:Mm}],[0,{[g]:x$e}],[0,{[g]:T$e}],[0,{[g]:I$e}],[0,{[g]:D$e}],[0,{[g]:k$e}],[0,{[g]:N$e}],[0,{[g]:M$e}],[2,{[g]:L$e}],[0,{[g]:A$e}],[4,{[g]:R$e}],[0,{[g]:B$e}],[4,{[g]:P$e}],[1,{[g]:F$e}],[128,{[pd]:Ed}],[0,{[g]:U$e}],[0,{[g]:j$e}],[5,{[g]:H$e}],[1,{[g]:q$e}],[0,{[g]:z$e}],[0,{[g]:G$e}],[0,{[g]:$$e}],[0,{[g]:W$e}],[0,{[g]:X$e}],[()=>dn,{[g]:K$e}],[0,{[g]:J$e}],[0,{[g]:V$e}],[1,{[g]:Q$e}],[0,{[g]:Z$e}],[2,{[g]:Y$e}]]],Qe="unit",c7e=[-3,rre,"S3ServiceException",0,[],[]];On.TypeRegistry.for(rre).registerError(c7e,In);var u7e=[1,b,TZ,0,[()=>Z1,0]],Vre=[1,b,a1,0,[()=>D8e,{[re]:le}]],Kv=[1,b,s3e,0,()=>q8e],l7e=[1,b,a3e,0,()=>U8e],Wre=[1,b,c1,0,[()=>J8e,0]],f7e=[1,b,hFe,0,()=>TGe],d7e=[1,b,tee,0,()=>AGe],p7e=[1,b,PFe,0,[0,{[re]:m1}]],h7e=[1,b,pee,0,()=>HGe],m7e=[1,b,MFe,0,()=>zGe],Yv=[1,b,Nv,0,[()=>oVe,{[re]:E1}]],g7e=[1,b,xee,0,[()=>tN,0]],y7e=[1,b,See,0,[()=>rN,0]],_7e=[1,b,Gje,0,[0,{[re]:BFe}]],b7e=[1,b,BUe,0,[()=>PVe,0]],Kre=[1,b,u4e,0,[()=>IVe,0]],E7e=[1,b,Iee,0,[()=>iN,0]],w7e=[1,b,b4e,0,()=>lWe],S7e=[1,b,I4e,0,()=>dWe],v7e=[1,b,F4e,0,()=>bWe],Yre=[1,b,G4e,0,[()=>yWe,0]],C7e=[1,b,J4e,0,[()=>vWe,0]],x7e=[1,b,M4e,0,()=>xWe],T7e=[1,b,qv,0,()=>AWe],A7e=[1,b,UHe,0,()=>SWe],R7e=[1,b,d5e,0,[()=>f9e,0]],P7e=[1,b,I5e,0,[()=>y9e,0]],Xre=[1,b,M1,0,[()=>T9e,{[re]:yte}]],O7e=[1,b,c6e,0,[()=>L9e,0]],Ks=[1,b,$v,0,[()=>wd,{[re]:Wi}]],I7e=[1,b,Mte,0,[()=>W9e,{[re]:E1}]],D7e=[1,b,E6e,0,()=>Y9e],k7e=[1,b,g6e,0,[()=>J9e,0]],N7e=[1,b,w6e,0,()=>Q9e],M7e=[1,b,Gte,0,[()=>oWe,{[re]:Nee}]],L7e=[3,b,p2e,0,[Gt,Wi,Pm],[0,()=>wd,[()=>R8e,0]]],B7e=[3,b,g4e,0,[Gt,Wi,OZ,Pm],[0,()=>wd,0,[()=>uWe,0]]],F7e=[3,b,r6e,{[tre]:1},[B5e,kte,ite,w3e,dee],[[()=>d9e,0],[()=>G9e,0],[()=>IWe,0],()=>z8e,()=>UGe]],q7e=[9,b,_2e,{[me]:["DELETE","/{Key+}?x-id=AbortMultipartUpload",204]},()=>x8e,()=>C8e],j7e=[9,b,FZ,{[me]:["POST","/{Key+}",200]},()=>$8e,()=>H8e],U7e=[9,b,r3e,{[me]:["PUT","/{Key+}?x-id=CopyObject",200]},()=>W8e,()=>V8e],H7e=[9,b,F2e,{[me]:["PUT","/",200]},()=>rGe,()=>tGe],$7e=[9,b,q2e,{[me]:["POST","/?metadataConfiguration",200]},()=>Z8e,()=>Qe],G7e=[9,b,U2e,{[me]:["POST","/?metadataTable",200]},()=>eGe,()=>Qe],z7e=[9,b,t3e,{[me]:["POST","/{Key+}?uploads",200]},()=>iGe,()=>nGe],V7e=[9,b,g3e,{[me]:["GET","/?session",200]},()=>sGe,()=>oGe],W7e=[9,b,v3e,{[me]:["DELETE","/",204]},()=>vGe,()=>Qe],K7e=[9,b,C3e,{[me]:["DELETE","/?analytics",204]},()=>fGe,()=>Qe],Y7e=[9,b,T3e,{[me]:["DELETE","/?cors",204]},()=>dGe,()=>Qe],X7e=[9,b,R3e,{[me]:["DELETE","/?encryption",204]},()=>pGe,()=>Qe],J7e=[9,b,D3e,{[me]:["DELETE","/?intelligent-tiering",204]},()=>hGe,()=>Qe],Q7e=[9,b,O3e,{[me]:["DELETE","/?inventory",204]},()=>mGe,()=>Qe],Z7e=[9,b,N3e,{[me]:["DELETE","/?lifecycle",204]},()=>gGe,()=>Qe],eKe=[9,b,L3e,{[me]:["DELETE","/?metadataConfiguration",204]},()=>yGe,()=>Qe],tKe=[9,b,j3e,{[me]:["DELETE","/?metadataTable",204]},()=>_Ge,()=>Qe],rKe=[9,b,q3e,{[me]:["DELETE","/?metrics",204]},()=>bGe,()=>Qe],nKe=[9,b,H3e,{[me]:["DELETE","/?ownershipControls",204]},()=>EGe,()=>Qe],iKe=[9,b,G3e,{[me]:["DELETE","/?policy",204]},()=>wGe,()=>Qe],oKe=[9,b,K3e,{[me]:["DELETE","/?replication",204]},()=>SGe,()=>Qe],sKe=[9,b,Y3e,{[me]:["DELETE","/?tagging",204]},()=>CGe,()=>Qe],aKe=[9,b,J3e,{[me]:["DELETE","/?website",204]},()=>xGe,()=>Qe],cKe=[9,b,mFe,{[me]:["DELETE","/{Key+}?x-id=DeleteObject",204]},()=>OGe,()=>PGe],uKe=[9,b,gFe,{[me]:["POST","/?delete",200]},()=>DGe,()=>IGe],lKe=[9,b,fFe,{[me]:["DELETE","/{Key+}?tagging",204]},()=>NGe,()=>kGe],fKe=[9,b,yFe,{[me]:["DELETE","/?publicAccessBlock",204]},()=>MGe,()=>Qe],dKe=[9,b,qFe,{[me]:["GET","/?abac",200]},()=>WGe,()=>VGe],pKe=[9,b,jFe,{[me]:["GET","/?accelerate",200]},()=>YGe,()=>KGe],hKe=[9,b,XFe,{[me]:["GET","/?acl",200]},()=>JGe,()=>XGe],mKe=[9,b,zFe,{[me]:["GET","/?analytics&x-id=GetBucketAnalyticsConfiguration",200]},()=>ZGe,()=>QGe],gKe=[9,b,JFe,{[me]:["GET","/?cors",200]},()=>tze,()=>eze],yKe=[9,b,eqe,{[me]:["GET","/?encryption",200]},()=>nze,()=>rze],_Ke=[9,b,sqe,{[me]:["GET","/?intelligent-tiering&x-id=GetBucketIntelligentTieringConfiguration",200]},()=>oze,()=>ize],bKe=[9,b,nqe,{[me]:["GET","/?inventory&x-id=GetBucketInventoryConfiguration",200]},()=>aze,()=>sze],EKe=[9,b,lqe,{[me]:["GET","/?lifecycle",200]},()=>uze,()=>cze],wKe=[9,b,uqe,{[me]:["GET","/?location",200]},()=>fze,()=>lze],SKe=[9,b,yqe,{[me]:["GET","/?logging",200]},()=>pze,()=>dze],vKe=[9,b,_qe,{[me]:["GET","/?metadataConfiguration",200]},()=>mze,()=>hze],CKe=[9,b,Cqe,{[me]:["GET","/?metadataTable",200]},()=>_ze,()=>yze],xKe=[9,b,vqe,{[me]:["GET","/?metrics&x-id=GetBucketMetricsConfiguration",200]},()=>wze,()=>Eze],TKe=[9,b,Aqe,{[me]:["GET","/?notification",200]},()=>Sze,()=>Nre],AKe=[9,b,Pqe,{[me]:["GET","/?ownershipControls",200]},()=>Cze,()=>vze],RKe=[9,b,Dqe,{[me]:["GET","/?policy",200]},()=>Tze,()=>xze],PKe=[9,b,Mqe,{[me]:["GET","/?policyStatus",200]},()=>Rze,()=>Aze],OKe=[9,b,Fqe,{[me]:["GET","/?replication",200]},()=>Oze,()=>Pze],IKe=[9,b,jqe,{[me]:["GET","/?requestPayment",200]},()=>Dze,()=>Ize],DKe=[9,b,Gqe,{[me]:["GET","/?tagging",200]},()=>Nze,()=>kze],kKe=[9,b,Wqe,{[me]:["GET","/?versioning",200]},()=>Lze,()=>Mze],NKe=[9,b,Xqe,{[me]:["GET","/?website",200]},()=>Fze,()=>Bze],MKe=[9,b,Zqe,{[me]:["GET","/{Key+}?x-id=GetObject",200]},()=>Yze,()=>Kze],LKe=[9,b,eje,{[me]:["GET","/{Key+}?acl",200]},()=>jze,()=>qze],BKe=[9,b,aje,{[me]:["GET","/{Key+}?attributes",200]},()=>$ze,()=>Uze],FKe=[9,b,fje,{[me]:["GET","/{Key+}?legal-hold",200]},()=>zze,()=>Gze],qKe=[9,b,cje,{[me]:["GET","/?object-lock",200]},()=>Wze,()=>Vze],jKe=[9,b,_je,{[me]:["GET","/{Key+}?retention",200]},()=>Jze,()=>Xze],UKe=[9,b,bje,{[me]:["GET","/{Key+}?tagging",200]},()=>Zze,()=>Qze],HKe=[9,b,Cje,{[me]:["GET","/{Key+}?torrent",200]},()=>tVe,()=>eVe],$Ke=[9,b,xje,{[me]:["GET","/?publicAccessBlock",200]},()=>nVe,()=>rVe],GKe=[9,b,Rje,{[me]:["HEAD","/",200]},()=>aVe,()=>sVe],zKe=[9,b,Dje,{[me]:["HEAD","/{Key+}",200]},()=>uVe,()=>cVe],VKe=[9,b,gUe,{[me]:["GET","/?analytics&x-id=ListBucketAnalyticsConfigurations",200]},()=>MVe,()=>NVe],WKe=[9,b,vUe,{[me]:["GET","/?intelligent-tiering&x-id=ListBucketIntelligentTieringConfigurations",200]},()=>BVe,()=>LVe],KKe=[9,b,EUe,{[me]:["GET","/?inventory&x-id=ListBucketInventoryConfigurations",200]},()=>qVe,()=>FVe],YKe=[9,b,TUe,{[me]:["GET","/?metrics&x-id=ListBucketMetricsConfigurations",200]},()=>UVe,()=>jVe],XKe=[9,b,mUe,{[me]:["GET","/?x-id=ListBuckets",200]},()=>$Ve,()=>HVe],JKe=[9,b,IUe,{[me]:["GET","/?x-id=ListDirectoryBuckets",200]},()=>zVe,()=>GVe],QKe=[9,b,$Ue,{[me]:["GET","/?uploads",200]},()=>WVe,()=>VVe],ZKe=[9,b,WUe,{[me]:["GET","/",200]},()=>YVe,()=>KVe],eYe=[9,b,XUe,{[me]:["GET","/?list-type=2",200]},()=>JVe,()=>XVe],tYe=[9,b,t4e,{[me]:["GET","/?versions",200]},()=>ZVe,()=>QVe],rYe=[9,b,r4e,{[me]:["GET","/{Key+}?x-id=ListParts",200]},()=>tWe,()=>eWe],nYe=[9,b,Z4e,{[me]:["PUT","/?abac",200]},()=>DWe,()=>Qe],iYe=[9,b,eHe,{[me]:["PUT","/?accelerate",200]},()=>kWe,()=>Qe],oYe=[9,b,sHe,{[me]:["PUT","/?acl",200]},()=>NWe,()=>Qe],sYe=[9,b,nHe,{[me]:["PUT","/?analytics",200]},()=>MWe,()=>Qe],aYe=[9,b,aHe,{[me]:["PUT","/?cors",200]},()=>LWe,()=>Qe],cYe=[9,b,uHe,{[me]:["PUT","/?encryption",200]},()=>BWe,()=>Qe],uYe=[9,b,pHe,{[me]:["PUT","/?intelligent-tiering",200]},()=>FWe,()=>Qe],lYe=[9,b,fHe,{[me]:["PUT","/?inventory",200]},()=>qWe,()=>Qe],fYe=[9,b,gHe,{[me]:["PUT","/?lifecycle",200]},()=>UWe,()=>jWe],dYe=[9,b,mHe,{[me]:["PUT","/?logging",200]},()=>HWe,()=>Qe],pYe=[9,b,EHe,{[me]:["PUT","/?metrics",200]},()=>$We,()=>Qe],hYe=[9,b,SHe,{[me]:["PUT","/?notification",200]},()=>GWe,()=>Qe],mYe=[9,b,CHe,{[me]:["PUT","/?ownershipControls",200]},()=>zWe,()=>Qe],gYe=[9,b,THe,{[me]:["PUT","/?policy",200]},()=>VWe,()=>Qe],yYe=[9,b,RHe,{[me]:["PUT","/?replication",200]},()=>WWe,()=>Qe],_Ye=[9,b,PHe,{[me]:["PUT","/?requestPayment",200]},()=>KWe,()=>Qe],bYe=[9,b,DHe,{[me]:["PUT","/?tagging",200]},()=>YWe,()=>Qe],EYe=[9,b,NHe,{[me]:["PUT","/?versioning",200]},()=>XWe,()=>Qe],wYe=[9,b,LHe,{[me]:["PUT","/?website",200]},()=>JWe,()=>Qe],SYe=[9,b,HHe,{[me]:["PUT","/{Key+}?x-id=PutObject",200]},()=>o9e,()=>i9e],vYe=[9,b,$He,{[me]:["PUT","/{Key+}?acl",200]},()=>ZWe,()=>QWe],CYe=[9,b,YHe,{[me]:["PUT","/{Key+}?legal-hold",200]},()=>t9e,()=>e9e],xYe=[9,b,VHe,{[me]:["PUT","/?object-lock",200]},()=>n9e,()=>r9e],TYe=[9,b,r5e,{[me]:["PUT","/{Key+}?retention",200]},()=>a9e,()=>s9e],AYe=[9,b,n5e,{[me]:["PUT","/{Key+}?tagging",200]},()=>u9e,()=>c9e],RYe=[9,b,s5e,{[me]:["PUT","/?publicAccessBlock",200]},()=>l9e,()=>Qe],PYe=[9,b,w5e,{[me]:["PUT","/{Key+}?renameObject",200]},()=>m9e,()=>h9e],OYe=[9,b,A5e,{[me]:["POST","/{Key+}?restore",200]},()=>C9e,()=>v9e],IYe=[9,b,t6e,{[me]:["POST","/{Key+}?select&select-type=2",200]},()=>k9e,()=>D9e],DYe=[9,b,O6e,{[me]:["PUT","/?metadataInventoryTable",200]},()=>Z9e,()=>Qe],kYe=[9,b,D6e,{[me]:["PUT","/?metadataJournalTable",200]},()=>e7e,()=>Qe],NYe=[9,b,N6e,{[me]:["PUT","/{Key+}?x-id=UploadPart",200]},()=>i7e,()=>n7e],MYe=[9,b,M6e,{[me]:["PUT","/{Key+}?x-id=UploadPartCopy",200]},()=>r7e,()=>t7e],LYe=[9,b,G6e,{[Y6e]:["{RequestRoute}."],[me]:["POST","/WriteGetObjectResponse",200]},()=>a7e,()=>Qe],Cm=class extends fe.Command.classBuilder().ep({...he,DisableS3ExpressSessionAuth:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","CreateSession",{}).n("S3Client","CreateSessionCommand").sc(V7e).build(){},BYe=e=>{let t=e.httpAuthSchemes,r=e.httpAuthSchemeProvider,n=e.credentials;return{setHttpAuthScheme(i){let o=t.findIndex(s=>s.schemeId===i.schemeId);o===-1?t.push(i):t.splice(o,1,i)},httpAuthSchemes(){return t},setHttpAuthSchemeProvider(i){r=i},httpAuthSchemeProvider(){return r},setCredentials(i){n=i},credentials(){return n}}},FYe=e=>({httpAuthSchemes:e.httpAuthSchemes(),httpAuthSchemeProvider:e.httpAuthSchemeProvider(),credentials:e.credentials()}),qYe=(e,t)=>{let r=Object.assign(qQ.getAwsRegionExtensionConfiguration(e),fe.getDefaultExtensionConfiguration(e),jQ.getHttpHandlerExtensionConfiguration(e),BYe(e));return t.forEach(n=>n.configure(r)),Object.assign(e,qQ.resolveAwsRegionExtensionConfiguration(r),fe.resolveDefaultRuntimeConfig(r),jQ.resolveHttpHandlerRuntimeConfig(r),FYe(r))},lc=class extends fe.Client{config;constructor(...[t]){let r=a2e.getRuntimeConfig(t||{});super(r),this.initConfig=r;let n=u2e(r),i=LQ.resolveUserAgentConfig(n),o=Ot.resolveFlexibleChecksumsConfig(i),s=BQ.resolveRetryConfig(o),a=i2e.resolveRegionConfig(s),c=MQ.resolveHostHeaderConfig(a),u=pe.resolveEndpointConfig(c),l=o2e.resolveEventStreamSerdeConfig(u),d=FQ.resolveHttpAuthSchemeConfig(l),h=Oe.resolveS3Config(d,{session:[()=>this,Cm]}),f=qYe(h,t?.extensions||[]);this.config=f,this.middlewareStack.use(On.getSchemaSerdePlugin(this.config)),this.middlewareStack.use(LQ.getUserAgentPlugin(this.config)),this.middlewareStack.use(BQ.getRetryPlugin(this.config)),this.middlewareStack.use(s2e.getContentLengthPlugin(this.config)),this.middlewareStack.use(MQ.getHostHeaderPlugin(this.config)),this.middlewareStack.use(r2e.getLoggerPlugin(this.config)),this.middlewareStack.use(n2e.getRecursionDetectionPlugin(this.config)),this.middlewareStack.use(Iu.getHttpAuthSchemeEndpointRuleSetPlugin(this.config,{httpAuthSchemeParametersProvider:FQ.defaultS3HttpAuthSchemeParametersProvider,identityProviderConfigProvider:async p=>new Iu.DefaultIdentityProviderConfig({"aws.auth#sigv4":p.credentials,"aws.auth#sigv4a":p.credentials})})),this.middlewareStack.use(Iu.getHttpSigningPlugin(this.config)),this.middlewareStack.use(Oe.getValidateBucketNamePlugin(this.config)),this.middlewareStack.use(t2e.getAddExpectContinuePlugin(this.config)),this.middlewareStack.use(Oe.getRegionRedirectMiddlewarePlugin(this.config)),this.middlewareStack.use(Oe.getS3ExpressPlugin(this.config)),this.middlewareStack.use(Oe.getS3ExpressHttpSigningPlugin(this.config))}destroy(){super.destroy()}},qw=class extends fe.Command.classBuilder().ep({...he,Bucket:{type:"contextParams",name:"Bucket"},Key:{type:"contextParams",name:"Key"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","AbortMultipartUpload",{}).n("S3Client","AbortMultipartUploadCommand").sc(q7e).build(){},jw=class extends fe.Command.classBuilder().ep({...he,Bucket:{type:"contextParams",name:"Bucket"},Key:{type:"contextParams",name:"Key"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n),_o.getSsecPlugin(n)]}).s("AmazonS3","CompleteMultipartUpload",{}).n("S3Client","CompleteMultipartUploadCommand").sc(j7e).build(){},Uw=class extends fe.Command.classBuilder().ep({...he,DisableS3ExpressSessionAuth:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"},Key:{type:"contextParams",name:"Key"},CopySource:{type:"contextParams",name:"CopySource"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n),_o.getSsecPlugin(n)]}).s("AmazonS3","CopyObject",{}).n("S3Client","CopyObjectCommand").sc(U7e).build(){},Hw=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},DisableAccessPoints:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n),c2e.getLocationConstraintPlugin(n)]}).s("AmazonS3","CreateBucket",{}).n("S3Client","CreateBucketCommand").sc(H7e).build(){},$w=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Ot.getFlexibleChecksumsPlugin(n,{requestAlgorithmMember:{httpHeader:"x-amz-sdk-checksum-algorithm",name:"ChecksumAlgorithm"},requestChecksumRequired:!0})]}).s("AmazonS3","CreateBucketMetadataConfiguration",{}).n("S3Client","CreateBucketMetadataConfigurationCommand").sc($7e).build(){},Gw=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Ot.getFlexibleChecksumsPlugin(n,{requestAlgorithmMember:{httpHeader:"x-amz-sdk-checksum-algorithm",name:"ChecksumAlgorithm"},requestChecksumRequired:!0})]}).s("AmazonS3","CreateBucketMetadataTableConfiguration",{}).n("S3Client","CreateBucketMetadataTableConfigurationCommand").sc(G7e).build(){},zw=class extends fe.Command.classBuilder().ep({...he,Bucket:{type:"contextParams",name:"Bucket"},Key:{type:"contextParams",name:"Key"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n),_o.getSsecPlugin(n)]}).s("AmazonS3","CreateMultipartUpload",{}).n("S3Client","CreateMultipartUploadCommand").sc(z7e).build(){},Vw=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions())]}).s("AmazonS3","DeleteBucketAnalyticsConfiguration",{}).n("S3Client","DeleteBucketAnalyticsConfigurationCommand").sc(K7e).build(){},Ww=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions())]}).s("AmazonS3","DeleteBucket",{}).n("S3Client","DeleteBucketCommand").sc(W7e).build(){},Kw=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions())]}).s("AmazonS3","DeleteBucketCors",{}).n("S3Client","DeleteBucketCorsCommand").sc(Y7e).build(){},Yw=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions())]}).s("AmazonS3","DeleteBucketEncryption",{}).n("S3Client","DeleteBucketEncryptionCommand").sc(X7e).build(){},Xw=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions())]}).s("AmazonS3","DeleteBucketIntelligentTieringConfiguration",{}).n("S3Client","DeleteBucketIntelligentTieringConfigurationCommand").sc(J7e).build(){},Jw=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions())]}).s("AmazonS3","DeleteBucketInventoryConfiguration",{}).n("S3Client","DeleteBucketInventoryConfigurationCommand").sc(Q7e).build(){},Qw=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions())]}).s("AmazonS3","DeleteBucketLifecycle",{}).n("S3Client","DeleteBucketLifecycleCommand").sc(Z7e).build(){},Zw=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions())]}).s("AmazonS3","DeleteBucketMetadataConfiguration",{}).n("S3Client","DeleteBucketMetadataConfigurationCommand").sc(eKe).build(){},eS=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions())]}).s("AmazonS3","DeleteBucketMetadataTableConfiguration",{}).n("S3Client","DeleteBucketMetadataTableConfigurationCommand").sc(tKe).build(){},tS=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions())]}).s("AmazonS3","DeleteBucketMetricsConfiguration",{}).n("S3Client","DeleteBucketMetricsConfigurationCommand").sc(rKe).build(){},rS=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions())]}).s("AmazonS3","DeleteBucketOwnershipControls",{}).n("S3Client","DeleteBucketOwnershipControlsCommand").sc(nKe).build(){},nS=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions())]}).s("AmazonS3","DeleteBucketPolicy",{}).n("S3Client","DeleteBucketPolicyCommand").sc(iKe).build(){},iS=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions())]}).s("AmazonS3","DeleteBucketReplication",{}).n("S3Client","DeleteBucketReplicationCommand").sc(oKe).build(){},oS=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions())]}).s("AmazonS3","DeleteBucketTagging",{}).n("S3Client","DeleteBucketTaggingCommand").sc(sKe).build(){},sS=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions())]}).s("AmazonS3","DeleteBucketWebsite",{}).n("S3Client","DeleteBucketWebsiteCommand").sc(aKe).build(){},aS=class extends fe.Command.classBuilder().ep({...he,Bucket:{type:"contextParams",name:"Bucket"},Key:{type:"contextParams",name:"Key"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","DeleteObject",{}).n("S3Client","DeleteObjectCommand").sc(cKe).build(){},cS=class extends fe.Command.classBuilder().ep({...he,Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Ot.getFlexibleChecksumsPlugin(n,{requestAlgorithmMember:{httpHeader:"x-amz-sdk-checksum-algorithm",name:"ChecksumAlgorithm"},requestChecksumRequired:!0}),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","DeleteObjects",{}).n("S3Client","DeleteObjectsCommand").sc(uKe).build(){},uS=class extends fe.Command.classBuilder().ep({...he,Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","DeleteObjectTagging",{}).n("S3Client","DeleteObjectTaggingCommand").sc(lKe).build(){},lS=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions())]}).s("AmazonS3","DeletePublicAccessBlock",{}).n("S3Client","DeletePublicAccessBlockCommand").sc(fKe).build(){},fS=class extends fe.Command.classBuilder().ep({...he,Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","GetBucketAbac",{}).n("S3Client","GetBucketAbacCommand").sc(dKe).build(){},dS=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","GetBucketAccelerateConfiguration",{}).n("S3Client","GetBucketAccelerateConfigurationCommand").sc(pKe).build(){},pS=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","GetBucketAcl",{}).n("S3Client","GetBucketAclCommand").sc(hKe).build(){},hS=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","GetBucketAnalyticsConfiguration",{}).n("S3Client","GetBucketAnalyticsConfigurationCommand").sc(mKe).build(){},mS=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","GetBucketCors",{}).n("S3Client","GetBucketCorsCommand").sc(gKe).build(){},gS=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","GetBucketEncryption",{}).n("S3Client","GetBucketEncryptionCommand").sc(yKe).build(){},yS=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","GetBucketIntelligentTieringConfiguration",{}).n("S3Client","GetBucketIntelligentTieringConfigurationCommand").sc(_Ke).build(){},_S=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","GetBucketInventoryConfiguration",{}).n("S3Client","GetBucketInventoryConfigurationCommand").sc(bKe).build(){},bS=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","GetBucketLifecycleConfiguration",{}).n("S3Client","GetBucketLifecycleConfigurationCommand").sc(EKe).build(){},ES=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","GetBucketLocation",{}).n("S3Client","GetBucketLocationCommand").sc(wKe).build(){},wS=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","GetBucketLogging",{}).n("S3Client","GetBucketLoggingCommand").sc(SKe).build(){},SS=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","GetBucketMetadataConfiguration",{}).n("S3Client","GetBucketMetadataConfigurationCommand").sc(vKe).build(){},vS=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","GetBucketMetadataTableConfiguration",{}).n("S3Client","GetBucketMetadataTableConfigurationCommand").sc(CKe).build(){},CS=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","GetBucketMetricsConfiguration",{}).n("S3Client","GetBucketMetricsConfigurationCommand").sc(xKe).build(){},xS=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","GetBucketNotificationConfiguration",{}).n("S3Client","GetBucketNotificationConfigurationCommand").sc(TKe).build(){},TS=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","GetBucketOwnershipControls",{}).n("S3Client","GetBucketOwnershipControlsCommand").sc(AKe).build(){},AS=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","GetBucketPolicy",{}).n("S3Client","GetBucketPolicyCommand").sc(RKe).build(){},RS=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","GetBucketPolicyStatus",{}).n("S3Client","GetBucketPolicyStatusCommand").sc(PKe).build(){},PS=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","GetBucketReplication",{}).n("S3Client","GetBucketReplicationCommand").sc(OKe).build(){},OS=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","GetBucketRequestPayment",{}).n("S3Client","GetBucketRequestPaymentCommand").sc(IKe).build(){},IS=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","GetBucketTagging",{}).n("S3Client","GetBucketTaggingCommand").sc(DKe).build(){},DS=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","GetBucketVersioning",{}).n("S3Client","GetBucketVersioningCommand").sc(kKe).build(){},kS=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","GetBucketWebsite",{}).n("S3Client","GetBucketWebsiteCommand").sc(NKe).build(){},NS=class extends fe.Command.classBuilder().ep({...he,Bucket:{type:"contextParams",name:"Bucket"},Key:{type:"contextParams",name:"Key"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","GetObjectAcl",{}).n("S3Client","GetObjectAclCommand").sc(LKe).build(){},MS=class extends fe.Command.classBuilder().ep({...he,Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n),_o.getSsecPlugin(n)]}).s("AmazonS3","GetObjectAttributes",{}).n("S3Client","GetObjectAttributesCommand").sc(BKe).build(){},LS=class extends fe.Command.classBuilder().ep({...he,Bucket:{type:"contextParams",name:"Bucket"},Key:{type:"contextParams",name:"Key"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Ot.getFlexibleChecksumsPlugin(n,{requestChecksumRequired:!1,requestValidationModeMember:"ChecksumMode",responseAlgorithms:["CRC64NVME","CRC32","CRC32C","SHA256","SHA1"]}),_o.getSsecPlugin(n),Oe.getS3ExpiresMiddlewarePlugin(n)]}).s("AmazonS3","GetObject",{}).n("S3Client","GetObjectCommand").sc(MKe).build(){},BS=class extends fe.Command.classBuilder().ep({...he,Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","GetObjectLegalHold",{}).n("S3Client","GetObjectLegalHoldCommand").sc(FKe).build(){},FS=class extends fe.Command.classBuilder().ep({...he,Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","GetObjectLockConfiguration",{}).n("S3Client","GetObjectLockConfigurationCommand").sc(qKe).build(){},qS=class extends fe.Command.classBuilder().ep({...he,Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","GetObjectRetention",{}).n("S3Client","GetObjectRetentionCommand").sc(jKe).build(){},jS=class extends fe.Command.classBuilder().ep({...he,Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","GetObjectTagging",{}).n("S3Client","GetObjectTaggingCommand").sc(UKe).build(){},US=class extends fe.Command.classBuilder().ep({...he,Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions())]}).s("AmazonS3","GetObjectTorrent",{}).n("S3Client","GetObjectTorrentCommand").sc(HKe).build(){},HS=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","GetPublicAccessBlock",{}).n("S3Client","GetPublicAccessBlockCommand").sc($Ke).build(){},$f=class extends fe.Command.classBuilder().ep({...he,Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","HeadBucket",{}).n("S3Client","HeadBucketCommand").sc(GKe).build(){},Gf=class extends fe.Command.classBuilder().ep({...he,Bucket:{type:"contextParams",name:"Bucket"},Key:{type:"contextParams",name:"Key"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n),_o.getSsecPlugin(n),Oe.getS3ExpiresMiddlewarePlugin(n)]}).s("AmazonS3","HeadObject",{}).n("S3Client","HeadObjectCommand").sc(zKe).build(){},$S=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","ListBucketAnalyticsConfigurations",{}).n("S3Client","ListBucketAnalyticsConfigurationsCommand").sc(VKe).build(){},GS=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","ListBucketIntelligentTieringConfigurations",{}).n("S3Client","ListBucketIntelligentTieringConfigurationsCommand").sc(WKe).build(){},zS=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","ListBucketInventoryConfigurations",{}).n("S3Client","ListBucketInventoryConfigurationsCommand").sc(KKe).build(){},VS=class extends fe.Command.classBuilder().ep({...he,Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","ListBucketMetricsConfigurations",{}).n("S3Client","ListBucketMetricsConfigurationsCommand").sc(YKe).build(){},xm=class extends fe.Command.classBuilder().ep(he).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","ListBuckets",{}).n("S3Client","ListBucketsCommand").sc(XKe).build(){},Tm=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","ListDirectoryBuckets",{}).n("S3Client","ListDirectoryBucketsCommand").sc(JKe).build(){},WS=class extends fe.Command.classBuilder().ep({...he,Bucket:{type:"contextParams",name:"Bucket"},Prefix:{type:"contextParams",name:"Prefix"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","ListMultipartUploads",{}).n("S3Client","ListMultipartUploadsCommand").sc(QKe).build(){},KS=class extends fe.Command.classBuilder().ep({...he,Bucket:{type:"contextParams",name:"Bucket"},Prefix:{type:"contextParams",name:"Prefix"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","ListObjects",{}).n("S3Client","ListObjectsCommand").sc(ZKe).build(){},Am=class extends fe.Command.classBuilder().ep({...he,Bucket:{type:"contextParams",name:"Bucket"},Prefix:{type:"contextParams",name:"Prefix"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","ListObjectsV2",{}).n("S3Client","ListObjectsV2Command").sc(eYe).build(){},YS=class extends fe.Command.classBuilder().ep({...he,Bucket:{type:"contextParams",name:"Bucket"},Prefix:{type:"contextParams",name:"Prefix"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","ListObjectVersions",{}).n("S3Client","ListObjectVersionsCommand").sc(tYe).build(){},Rm=class extends fe.Command.classBuilder().ep({...he,Bucket:{type:"contextParams",name:"Bucket"},Key:{type:"contextParams",name:"Key"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n),_o.getSsecPlugin(n)]}).s("AmazonS3","ListParts",{}).n("S3Client","ListPartsCommand").sc(rYe).build(){},XS=class extends fe.Command.classBuilder().ep({...he,Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Ot.getFlexibleChecksumsPlugin(n,{requestAlgorithmMember:{httpHeader:"x-amz-sdk-checksum-algorithm",name:"ChecksumAlgorithm"},requestChecksumRequired:!1})]}).s("AmazonS3","PutBucketAbac",{}).n("S3Client","PutBucketAbacCommand").sc(nYe).build(){},JS=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Ot.getFlexibleChecksumsPlugin(n,{requestAlgorithmMember:{httpHeader:"x-amz-sdk-checksum-algorithm",name:"ChecksumAlgorithm"},requestChecksumRequired:!1})]}).s("AmazonS3","PutBucketAccelerateConfiguration",{}).n("S3Client","PutBucketAccelerateConfigurationCommand").sc(iYe).build(){},QS=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Ot.getFlexibleChecksumsPlugin(n,{requestAlgorithmMember:{httpHeader:"x-amz-sdk-checksum-algorithm",name:"ChecksumAlgorithm"},requestChecksumRequired:!0})]}).s("AmazonS3","PutBucketAcl",{}).n("S3Client","PutBucketAclCommand").sc(oYe).build(){},ZS=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions())]}).s("AmazonS3","PutBucketAnalyticsConfiguration",{}).n("S3Client","PutBucketAnalyticsConfigurationCommand").sc(sYe).build(){},ev=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Ot.getFlexibleChecksumsPlugin(n,{requestAlgorithmMember:{httpHeader:"x-amz-sdk-checksum-algorithm",name:"ChecksumAlgorithm"},requestChecksumRequired:!0})]}).s("AmazonS3","PutBucketCors",{}).n("S3Client","PutBucketCorsCommand").sc(aYe).build(){},tv=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Ot.getFlexibleChecksumsPlugin(n,{requestAlgorithmMember:{httpHeader:"x-amz-sdk-checksum-algorithm",name:"ChecksumAlgorithm"},requestChecksumRequired:!0})]}).s("AmazonS3","PutBucketEncryption",{}).n("S3Client","PutBucketEncryptionCommand").sc(cYe).build(){},rv=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions())]}).s("AmazonS3","PutBucketIntelligentTieringConfiguration",{}).n("S3Client","PutBucketIntelligentTieringConfigurationCommand").sc(uYe).build(){},nv=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions())]}).s("AmazonS3","PutBucketInventoryConfiguration",{}).n("S3Client","PutBucketInventoryConfigurationCommand").sc(lYe).build(){},iv=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Ot.getFlexibleChecksumsPlugin(n,{requestAlgorithmMember:{httpHeader:"x-amz-sdk-checksum-algorithm",name:"ChecksumAlgorithm"},requestChecksumRequired:!0}),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","PutBucketLifecycleConfiguration",{}).n("S3Client","PutBucketLifecycleConfigurationCommand").sc(fYe).build(){},ov=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Ot.getFlexibleChecksumsPlugin(n,{requestAlgorithmMember:{httpHeader:"x-amz-sdk-checksum-algorithm",name:"ChecksumAlgorithm"},requestChecksumRequired:!0})]}).s("AmazonS3","PutBucketLogging",{}).n("S3Client","PutBucketLoggingCommand").sc(dYe).build(){},sv=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions())]}).s("AmazonS3","PutBucketMetricsConfiguration",{}).n("S3Client","PutBucketMetricsConfigurationCommand").sc(pYe).build(){},av=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions())]}).s("AmazonS3","PutBucketNotificationConfiguration",{}).n("S3Client","PutBucketNotificationConfigurationCommand").sc(hYe).build(){},cv=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Ot.getFlexibleChecksumsPlugin(n,{requestAlgorithmMember:{httpHeader:"x-amz-sdk-checksum-algorithm",name:"ChecksumAlgorithm"},requestChecksumRequired:!0})]}).s("AmazonS3","PutBucketOwnershipControls",{}).n("S3Client","PutBucketOwnershipControlsCommand").sc(mYe).build(){},uv=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Ot.getFlexibleChecksumsPlugin(n,{requestAlgorithmMember:{httpHeader:"x-amz-sdk-checksum-algorithm",name:"ChecksumAlgorithm"},requestChecksumRequired:!0})]}).s("AmazonS3","PutBucketPolicy",{}).n("S3Client","PutBucketPolicyCommand").sc(gYe).build(){},lv=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Ot.getFlexibleChecksumsPlugin(n,{requestAlgorithmMember:{httpHeader:"x-amz-sdk-checksum-algorithm",name:"ChecksumAlgorithm"},requestChecksumRequired:!0})]}).s("AmazonS3","PutBucketReplication",{}).n("S3Client","PutBucketReplicationCommand").sc(yYe).build(){},fv=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Ot.getFlexibleChecksumsPlugin(n,{requestAlgorithmMember:{httpHeader:"x-amz-sdk-checksum-algorithm",name:"ChecksumAlgorithm"},requestChecksumRequired:!0})]}).s("AmazonS3","PutBucketRequestPayment",{}).n("S3Client","PutBucketRequestPaymentCommand").sc(_Ye).build(){},dv=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Ot.getFlexibleChecksumsPlugin(n,{requestAlgorithmMember:{httpHeader:"x-amz-sdk-checksum-algorithm",name:"ChecksumAlgorithm"},requestChecksumRequired:!0})]}).s("AmazonS3","PutBucketTagging",{}).n("S3Client","PutBucketTaggingCommand").sc(bYe).build(){},pv=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Ot.getFlexibleChecksumsPlugin(n,{requestAlgorithmMember:{httpHeader:"x-amz-sdk-checksum-algorithm",name:"ChecksumAlgorithm"},requestChecksumRequired:!0})]}).s("AmazonS3","PutBucketVersioning",{}).n("S3Client","PutBucketVersioningCommand").sc(EYe).build(){},hv=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Ot.getFlexibleChecksumsPlugin(n,{requestAlgorithmMember:{httpHeader:"x-amz-sdk-checksum-algorithm",name:"ChecksumAlgorithm"},requestChecksumRequired:!0})]}).s("AmazonS3","PutBucketWebsite",{}).n("S3Client","PutBucketWebsiteCommand").sc(wYe).build(){},mv=class extends fe.Command.classBuilder().ep({...he,Bucket:{type:"contextParams",name:"Bucket"},Key:{type:"contextParams",name:"Key"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Ot.getFlexibleChecksumsPlugin(n,{requestAlgorithmMember:{httpHeader:"x-amz-sdk-checksum-algorithm",name:"ChecksumAlgorithm"},requestChecksumRequired:!0}),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","PutObjectAcl",{}).n("S3Client","PutObjectAclCommand").sc(vYe).build(){},gv=class extends fe.Command.classBuilder().ep({...he,Bucket:{type:"contextParams",name:"Bucket"},Key:{type:"contextParams",name:"Key"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Ot.getFlexibleChecksumsPlugin(n,{requestAlgorithmMember:{httpHeader:"x-amz-sdk-checksum-algorithm",name:"ChecksumAlgorithm"},requestChecksumRequired:!1}),Oe.getCheckContentLengthHeaderPlugin(n),Oe.getThrow200ExceptionsPlugin(n),_o.getSsecPlugin(n)]}).s("AmazonS3","PutObject",{}).n("S3Client","PutObjectCommand").sc(SYe).build(){},yv=class extends fe.Command.classBuilder().ep({...he,Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Ot.getFlexibleChecksumsPlugin(n,{requestAlgorithmMember:{httpHeader:"x-amz-sdk-checksum-algorithm",name:"ChecksumAlgorithm"},requestChecksumRequired:!0}),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","PutObjectLegalHold",{}).n("S3Client","PutObjectLegalHoldCommand").sc(CYe).build(){},_v=class extends fe.Command.classBuilder().ep({...he,Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Ot.getFlexibleChecksumsPlugin(n,{requestAlgorithmMember:{httpHeader:"x-amz-sdk-checksum-algorithm",name:"ChecksumAlgorithm"},requestChecksumRequired:!0}),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","PutObjectLockConfiguration",{}).n("S3Client","PutObjectLockConfigurationCommand").sc(xYe).build(){},bv=class extends fe.Command.classBuilder().ep({...he,Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Ot.getFlexibleChecksumsPlugin(n,{requestAlgorithmMember:{httpHeader:"x-amz-sdk-checksum-algorithm",name:"ChecksumAlgorithm"},requestChecksumRequired:!0}),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","PutObjectRetention",{}).n("S3Client","PutObjectRetentionCommand").sc(TYe).build(){},Ev=class extends fe.Command.classBuilder().ep({...he,Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Ot.getFlexibleChecksumsPlugin(n,{requestAlgorithmMember:{httpHeader:"x-amz-sdk-checksum-algorithm",name:"ChecksumAlgorithm"},requestChecksumRequired:!0}),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","PutObjectTagging",{}).n("S3Client","PutObjectTaggingCommand").sc(AYe).build(){},wv=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Ot.getFlexibleChecksumsPlugin(n,{requestAlgorithmMember:{httpHeader:"x-amz-sdk-checksum-algorithm",name:"ChecksumAlgorithm"},requestChecksumRequired:!0})]}).s("AmazonS3","PutPublicAccessBlock",{}).n("S3Client","PutPublicAccessBlockCommand").sc(RYe).build(){},Sv=class extends fe.Command.classBuilder().ep({...he,Bucket:{type:"contextParams",name:"Bucket"},Key:{type:"contextParams",name:"Key"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","RenameObject",{}).n("S3Client","RenameObjectCommand").sc(PYe).build(){},vv=class extends fe.Command.classBuilder().ep({...he,Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Ot.getFlexibleChecksumsPlugin(n,{requestAlgorithmMember:{httpHeader:"x-amz-sdk-checksum-algorithm",name:"ChecksumAlgorithm"},requestChecksumRequired:!1}),Oe.getThrow200ExceptionsPlugin(n)]}).s("AmazonS3","RestoreObject",{}).n("S3Client","RestoreObjectCommand").sc(OYe).build(){},Cv=class extends fe.Command.classBuilder().ep({...he,Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n),_o.getSsecPlugin(n)]}).s("AmazonS3","SelectObjectContent",{eventStream:{output:!0}}).n("S3Client","SelectObjectContentCommand").sc(IYe).build(){},xv=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Ot.getFlexibleChecksumsPlugin(n,{requestAlgorithmMember:{httpHeader:"x-amz-sdk-checksum-algorithm",name:"ChecksumAlgorithm"},requestChecksumRequired:!0})]}).s("AmazonS3","UpdateBucketMetadataInventoryTableConfiguration",{}).n("S3Client","UpdateBucketMetadataInventoryTableConfigurationCommand").sc(DYe).build(){},Tv=class extends fe.Command.classBuilder().ep({...he,UseS3ExpressControlEndpoint:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Ot.getFlexibleChecksumsPlugin(n,{requestAlgorithmMember:{httpHeader:"x-amz-sdk-checksum-algorithm",name:"ChecksumAlgorithm"},requestChecksumRequired:!0})]}).s("AmazonS3","UpdateBucketMetadataJournalTableConfiguration",{}).n("S3Client","UpdateBucketMetadataJournalTableConfigurationCommand").sc(kYe).build(){},Av=class extends fe.Command.classBuilder().ep({...he,Bucket:{type:"contextParams",name:"Bucket"},Key:{type:"contextParams",name:"Key"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Ot.getFlexibleChecksumsPlugin(n,{requestAlgorithmMember:{httpHeader:"x-amz-sdk-checksum-algorithm",name:"ChecksumAlgorithm"},requestChecksumRequired:!1}),Oe.getThrow200ExceptionsPlugin(n),_o.getSsecPlugin(n)]}).s("AmazonS3","UploadPart",{}).n("S3Client","UploadPartCommand").sc(NYe).build(){},Rv=class extends fe.Command.classBuilder().ep({...he,DisableS3ExpressSessionAuth:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions()),Oe.getThrow200ExceptionsPlugin(n),_o.getSsecPlugin(n)]}).s("AmazonS3","UploadPartCopy",{}).n("S3Client","UploadPartCopyCommand").sc(MYe).build(){},Pv=class extends fe.Command.classBuilder().ep({...he,UseObjectLambdaEndpoint:{type:"staticContextParams",value:!0}}).m(function(t,r,n,i){return[pe.getEndpointPlugin(n,t.getEndpointParameterInstructions())]}).s("AmazonS3","WriteGetObjectResponse",{}).n("S3Client","WriteGetObjectResponseCommand").sc(LYe).build(){},jYe={AbortMultipartUploadCommand:qw,CompleteMultipartUploadCommand:jw,CopyObjectCommand:Uw,CreateBucketCommand:Hw,CreateBucketMetadataConfigurationCommand:$w,CreateBucketMetadataTableConfigurationCommand:Gw,CreateMultipartUploadCommand:zw,CreateSessionCommand:Cm,DeleteBucketCommand:Ww,DeleteBucketAnalyticsConfigurationCommand:Vw,DeleteBucketCorsCommand:Kw,DeleteBucketEncryptionCommand:Yw,DeleteBucketIntelligentTieringConfigurationCommand:Xw,DeleteBucketInventoryConfigurationCommand:Jw,DeleteBucketLifecycleCommand:Qw,DeleteBucketMetadataConfigurationCommand:Zw,DeleteBucketMetadataTableConfigurationCommand:eS,DeleteBucketMetricsConfigurationCommand:tS,DeleteBucketOwnershipControlsCommand:rS,DeleteBucketPolicyCommand:nS,DeleteBucketReplicationCommand:iS,DeleteBucketTaggingCommand:oS,DeleteBucketWebsiteCommand:sS,DeleteObjectCommand:aS,DeleteObjectsCommand:cS,DeleteObjectTaggingCommand:uS,DeletePublicAccessBlockCommand:lS,GetBucketAbacCommand:fS,GetBucketAccelerateConfigurationCommand:dS,GetBucketAclCommand:pS,GetBucketAnalyticsConfigurationCommand:hS,GetBucketCorsCommand:mS,GetBucketEncryptionCommand:gS,GetBucketIntelligentTieringConfigurationCommand:yS,GetBucketInventoryConfigurationCommand:_S,GetBucketLifecycleConfigurationCommand:bS,GetBucketLocationCommand:ES,GetBucketLoggingCommand:wS,GetBucketMetadataConfigurationCommand:SS,GetBucketMetadataTableConfigurationCommand:vS,GetBucketMetricsConfigurationCommand:CS,GetBucketNotificationConfigurationCommand:xS,GetBucketOwnershipControlsCommand:TS,GetBucketPolicyCommand:AS,GetBucketPolicyStatusCommand:RS,GetBucketReplicationCommand:PS,GetBucketRequestPaymentCommand:OS,GetBucketTaggingCommand:IS,GetBucketVersioningCommand:DS,GetBucketWebsiteCommand:kS,GetObjectCommand:LS,GetObjectAclCommand:NS,GetObjectAttributesCommand:MS,GetObjectLegalHoldCommand:BS,GetObjectLockConfigurationCommand:FS,GetObjectRetentionCommand:qS,GetObjectTaggingCommand:jS,GetObjectTorrentCommand:US,GetPublicAccessBlockCommand:HS,HeadBucketCommand:$f,HeadObjectCommand:Gf,ListBucketAnalyticsConfigurationsCommand:$S,ListBucketIntelligentTieringConfigurationsCommand:GS,ListBucketInventoryConfigurationsCommand:zS,ListBucketMetricsConfigurationsCommand:VS,ListBucketsCommand:xm,ListDirectoryBucketsCommand:Tm,ListMultipartUploadsCommand:WS,ListObjectsCommand:KS,ListObjectsV2Command:Am,ListObjectVersionsCommand:YS,ListPartsCommand:Rm,PutBucketAbacCommand:XS,PutBucketAccelerateConfigurationCommand:JS,PutBucketAclCommand:QS,PutBucketAnalyticsConfigurationCommand:ZS,PutBucketCorsCommand:ev,PutBucketEncryptionCommand:tv,PutBucketIntelligentTieringConfigurationCommand:rv,PutBucketInventoryConfigurationCommand:nv,PutBucketLifecycleConfigurationCommand:iv,PutBucketLoggingCommand:ov,PutBucketMetricsConfigurationCommand:sv,PutBucketNotificationConfigurationCommand:av,PutBucketOwnershipControlsCommand:cv,PutBucketPolicyCommand:uv,PutBucketReplicationCommand:lv,PutBucketRequestPaymentCommand:fv,PutBucketTaggingCommand:dv,PutBucketVersioningCommand:pv,PutBucketWebsiteCommand:hv,PutObjectCommand:gv,PutObjectAclCommand:mv,PutObjectLegalHoldCommand:yv,PutObjectLockConfigurationCommand:_v,PutObjectRetentionCommand:bv,PutObjectTaggingCommand:Ev,PutPublicAccessBlockCommand:wv,RenameObjectCommand:Sv,RestoreObjectCommand:vv,SelectObjectContentCommand:Cv,UpdateBucketMetadataInventoryTableConfigurationCommand:xv,UpdateBucketMetadataJournalTableConfigurationCommand:Tv,UploadPartCommand:Av,UploadPartCopyCommand:Rv,WriteGetObjectResponseCommand:Pv},Ov=class extends lc{};fe.createAggregatedClient(jYe,Ov);var UYe=Iu.createPaginator(lc,xm,"ContinuationToken","ContinuationToken","MaxBuckets"),HYe=Iu.createPaginator(lc,Tm,"ContinuationToken","ContinuationToken","MaxDirectoryBuckets"),$Ye=Iu.createPaginator(lc,Am,"ContinuationToken","NextContinuationToken","MaxKeys"),GYe=Iu.createPaginator(lc,Rm,"PartNumberMarker","NextPartNumberMarker","MaxParts"),Jre=async(e,t)=>{let r;try{return r=await e.send(new $f(t)),{state:dr.WaiterState.SUCCESS,reason:r}}catch(n){if(r=n,n.name&&n.name=="NotFound")return{state:dr.WaiterState.RETRY,reason:r}}return{state:dr.WaiterState.RETRY,reason:r}},zYe=async(e,t)=>{let r={minDelay:5,maxDelay:120};return dr.createWaiter({...r,...e},t,Jre)},VYe=async(e,t)=>{let r={minDelay:5,maxDelay:120},n=await dr.createWaiter({...r,...e},t,Jre);return dr.checkExceptions(n)},Qre=async(e,t)=>{let r;try{r=await e.send(new $f(t))}catch(n){if(r=n,n.name&&n.name=="NotFound")return{state:dr.WaiterState.SUCCESS,reason:r}}return{state:dr.WaiterState.RETRY,reason:r}},WYe=async(e,t)=>{let r={minDelay:5,maxDelay:120};return dr.createWaiter({...r,...e},t,Qre)},KYe=async(e,t)=>{let r={minDelay:5,maxDelay:120},n=await dr.createWaiter({...r,...e},t,Qre);return dr.checkExceptions(n)},Zre=async(e,t)=>{let r;try{return r=await e.send(new Gf(t)),{state:dr.WaiterState.SUCCESS,reason:r}}catch(n){if(r=n,n.name&&n.name=="NotFound")return{state:dr.WaiterState.RETRY,reason:r}}return{state:dr.WaiterState.RETRY,reason:r}},YYe=async(e,t)=>{let r={minDelay:5,maxDelay:120};return dr.createWaiter({...r,...e},t,Zre)},XYe=async(e,t)=>{let r={minDelay:5,maxDelay:120},n=await dr.createWaiter({...r,...e},t,Zre);return dr.checkExceptions(n)},ene=async(e,t)=>{let r;try{r=await e.send(new Gf(t))}catch(n){if(r=n,n.name&&n.name=="NotFound")return{state:dr.WaiterState.SUCCESS,reason:r}}return{state:dr.WaiterState.RETRY,reason:r}},JYe=async(e,t)=>{let r={minDelay:5,maxDelay:120};return dr.createWaiter({...r,...e},t,ene)},QYe=async(e,t)=>{let r={minDelay:5,maxDelay:120},n=await dr.createWaiter({...r,...e},t,ene);return dr.checkExceptions(n)},ZYe={Disabled:"Disabled",Enabled:"Enabled"},eXe={requester:"requester"},tXe={requester:"requester"},rXe={Enabled:"Enabled",Suspended:"Suspended"},nXe={AmazonCustomerByEmail:"AmazonCustomerByEmail",CanonicalUser:"CanonicalUser",Group:"Group"},iXe={FULL_CONTROL:"FULL_CONTROL",READ:"READ",READ_ACP:"READ_ACP",WRITE:"WRITE",WRITE_ACP:"WRITE_ACP"},oXe={Destination:"Destination"},sXe={COMPOSITE:"COMPOSITE",FULL_OBJECT:"FULL_OBJECT"},aXe={AES256:"AES256",aws_fsx:"aws:fsx",aws_kms:"aws:kms",aws_kms_dsse:"aws:kms:dsse"},cXe={authenticated_read:"authenticated-read",aws_exec_read:"aws-exec-read",bucket_owner_full_control:"bucket-owner-full-control",bucket_owner_read:"bucket-owner-read",private:"private",public_read:"public-read",public_read_write:"public-read-write"},uXe={CRC32:"CRC32",CRC32C:"CRC32C",CRC64NVME:"CRC64NVME",SHA1:"SHA1",SHA256:"SHA256"},lXe={COPY:"COPY",REPLACE:"REPLACE"},fXe={OFF:"OFF",ON:"ON"},dXe={COMPLIANCE:"COMPLIANCE",GOVERNANCE:"GOVERNANCE"},pXe={DEEP_ARCHIVE:"DEEP_ARCHIVE",EXPRESS_ONEZONE:"EXPRESS_ONEZONE",FSX_ONTAP:"FSX_ONTAP",FSX_OPENZFS:"FSX_OPENZFS",GLACIER:"GLACIER",GLACIER_IR:"GLACIER_IR",INTELLIGENT_TIERING:"INTELLIGENT_TIERING",ONEZONE_IA:"ONEZONE_IA",OUTPOSTS:"OUTPOSTS",REDUCED_REDUNDANCY:"REDUCED_REDUNDANCY",SNOW:"SNOW",STANDARD:"STANDARD",STANDARD_IA:"STANDARD_IA"},hXe={COPY:"COPY",REPLACE:"REPLACE"},mXe={authenticated_read:"authenticated-read",private:"private",public_read:"public-read",public_read_write:"public-read-write"},gXe={SingleAvailabilityZone:"SingleAvailabilityZone",SingleLocalZone:"SingleLocalZone"},yXe={Directory:"Directory"},_Xe={AvailabilityZone:"AvailabilityZone",LocalZone:"LocalZone"},bXe={EU:"EU",af_south_1:"af-south-1",ap_east_1:"ap-east-1",ap_northeast_1:"ap-northeast-1",ap_northeast_2:"ap-northeast-2",ap_northeast_3:"ap-northeast-3",ap_south_1:"ap-south-1",ap_south_2:"ap-south-2",ap_southeast_1:"ap-southeast-1",ap_southeast_2:"ap-southeast-2",ap_southeast_3:"ap-southeast-3",ap_southeast_4:"ap-southeast-4",ap_southeast_5:"ap-southeast-5",ca_central_1:"ca-central-1",cn_north_1:"cn-north-1",cn_northwest_1:"cn-northwest-1",eu_central_1:"eu-central-1",eu_central_2:"eu-central-2",eu_north_1:"eu-north-1",eu_south_1:"eu-south-1",eu_south_2:"eu-south-2",eu_west_1:"eu-west-1",eu_west_2:"eu-west-2",eu_west_3:"eu-west-3",il_central_1:"il-central-1",me_central_1:"me-central-1",me_south_1:"me-south-1",sa_east_1:"sa-east-1",us_east_2:"us-east-2",us_gov_east_1:"us-gov-east-1",us_gov_west_1:"us-gov-west-1",us_west_1:"us-west-1",us_west_2:"us-west-2"},EXe={BucketOwnerEnforced:"BucketOwnerEnforced",BucketOwnerPreferred:"BucketOwnerPreferred",ObjectWriter:"ObjectWriter"},wXe={DISABLED:"DISABLED",ENABLED:"ENABLED"},SXe={AES256:"AES256",aws_kms:"aws:kms"},vXe={DISABLED:"DISABLED",ENABLED:"ENABLED"},CXe={ReadOnly:"ReadOnly",ReadWrite:"ReadWrite"},xXe={CSV:"CSV"},TXe={V_1:"V_1"},AXe={NONE:"NONE",SSE_C:"SSE-C"},RXe={Disabled:"Disabled",Enabled:"Enabled"},PXe={ARCHIVE_ACCESS:"ARCHIVE_ACCESS",DEEP_ARCHIVE_ACCESS:"DEEP_ARCHIVE_ACCESS"},OXe={CSV:"CSV",ORC:"ORC",Parquet:"Parquet"},IXe={All:"All",Current:"Current"},DXe={BucketKeyStatus:"BucketKeyStatus",ChecksumAlgorithm:"ChecksumAlgorithm",ETag:"ETag",EncryptionStatus:"EncryptionStatus",IntelligentTieringAccessTier:"IntelligentTieringAccessTier",IsMultipartUploaded:"IsMultipartUploaded",LastModifiedDate:"LastModifiedDate",ObjectAccessControlList:"ObjectAccessControlList",ObjectLockLegalHoldStatus:"ObjectLockLegalHoldStatus",ObjectLockMode:"ObjectLockMode",ObjectLockRetainUntilDate:"ObjectLockRetainUntilDate",ObjectOwner:"ObjectOwner",ReplicationStatus:"ReplicationStatus",Size:"Size",StorageClass:"StorageClass"},kXe={Daily:"Daily",Weekly:"Weekly"},NXe={DEEP_ARCHIVE:"DEEP_ARCHIVE",GLACIER:"GLACIER",GLACIER_IR:"GLACIER_IR",INTELLIGENT_TIERING:"INTELLIGENT_TIERING",ONEZONE_IA:"ONEZONE_IA",STANDARD_IA:"STANDARD_IA"},MXe={Disabled:"Disabled",Enabled:"Enabled"},LXe={all_storage_classes_128K:"all_storage_classes_128K",varies_by_storage_class:"varies_by_storage_class"},BXe={FULL_CONTROL:"FULL_CONTROL",READ:"READ",WRITE:"WRITE"},FXe={DeliveryTime:"DeliveryTime",EventTime:"EventTime"},qXe={aws:"aws",customer:"customer"},jXe={s3_IntelligentTiering:"s3:IntelligentTiering",s3_LifecycleExpiration_:"s3:LifecycleExpiration:*",s3_LifecycleExpiration_Delete:"s3:LifecycleExpiration:Delete",s3_LifecycleExpiration_DeleteMarkerCreated:"s3:LifecycleExpiration:DeleteMarkerCreated",s3_LifecycleTransition:"s3:LifecycleTransition",s3_ObjectAcl_Put:"s3:ObjectAcl:Put",s3_ObjectCreated_:"s3:ObjectCreated:*",s3_ObjectCreated_CompleteMultipartUpload:"s3:ObjectCreated:CompleteMultipartUpload",s3_ObjectCreated_Copy:"s3:ObjectCreated:Copy",s3_ObjectCreated_Post:"s3:ObjectCreated:Post",s3_ObjectCreated_Put:"s3:ObjectCreated:Put",s3_ObjectRemoved_:"s3:ObjectRemoved:*",s3_ObjectRemoved_Delete:"s3:ObjectRemoved:Delete",s3_ObjectRemoved_DeleteMarkerCreated:"s3:ObjectRemoved:DeleteMarkerCreated",s3_ObjectRestore_:"s3:ObjectRestore:*",s3_ObjectRestore_Completed:"s3:ObjectRestore:Completed",s3_ObjectRestore_Delete:"s3:ObjectRestore:Delete",s3_ObjectRestore_Post:"s3:ObjectRestore:Post",s3_ObjectTagging_:"s3:ObjectTagging:*",s3_ObjectTagging_Delete:"s3:ObjectTagging:Delete",s3_ObjectTagging_Put:"s3:ObjectTagging:Put",s3_ReducedRedundancyLostObject:"s3:ReducedRedundancyLostObject",s3_Replication_:"s3:Replication:*",s3_Replication_OperationFailedReplication:"s3:Replication:OperationFailedReplication",s3_Replication_OperationMissedThreshold:"s3:Replication:OperationMissedThreshold",s3_Replication_OperationNotTracked:"s3:Replication:OperationNotTracked",s3_Replication_OperationReplicatedAfterThreshold:"s3:Replication:OperationReplicatedAfterThreshold"},UXe={prefix:"prefix",suffix:"suffix"},HXe={Disabled:"Disabled",Enabled:"Enabled"},$Xe={Disabled:"Disabled",Enabled:"Enabled"},GXe={Disabled:"Disabled",Enabled:"Enabled"},zXe={Disabled:"Disabled",Enabled:"Enabled"},VXe={Disabled:"Disabled",Enabled:"Enabled"},WXe={Disabled:"Disabled",Enabled:"Enabled"},KXe={Disabled:"Disabled",Enabled:"Enabled"},YXe={BucketOwner:"BucketOwner",Requester:"Requester"},XXe={Disabled:"Disabled",Enabled:"Enabled"},JXe={Enabled:"Enabled",Suspended:"Suspended"},QXe={http:"http",https:"https"},ZXe={COMPLETE:"COMPLETE",COMPLETED:"COMPLETED",FAILED:"FAILED",PENDING:"PENDING",REPLICA:"REPLICA"},eJe={ENABLED:"ENABLED"},tJe={CHECKSUM:"Checksum",ETAG:"ETag",OBJECT_PARTS:"ObjectParts",OBJECT_SIZE:"ObjectSize",STORAGE_CLASS:"StorageClass"},rJe={Enabled:"Enabled"},nJe={COMPLIANCE:"COMPLIANCE",GOVERNANCE:"GOVERNANCE"},iJe={ARCHIVE_ACCESS:"ARCHIVE_ACCESS",DEEP_ARCHIVE_ACCESS:"DEEP_ARCHIVE_ACCESS"},oJe={url:"url"},sJe={DEEP_ARCHIVE:"DEEP_ARCHIVE",EXPRESS_ONEZONE:"EXPRESS_ONEZONE",FSX_ONTAP:"FSX_ONTAP",FSX_OPENZFS:"FSX_OPENZFS",GLACIER:"GLACIER",GLACIER_IR:"GLACIER_IR",INTELLIGENT_TIERING:"INTELLIGENT_TIERING",ONEZONE_IA:"ONEZONE_IA",OUTPOSTS:"OUTPOSTS",REDUCED_REDUNDANCY:"REDUCED_REDUNDANCY",SNOW:"SNOW",STANDARD:"STANDARD",STANDARD_IA:"STANDARD_IA"},aJe={RESTORE_STATUS:"RestoreStatus"},cJe={STANDARD:"STANDARD"},uJe={Disabled:"Disabled",Enabled:"Enabled"},lJe={Bulk:"Bulk",Expedited:"Expedited",Standard:"Standard"},fJe={SQL:"SQL"},dJe={BZIP2:"BZIP2",GZIP:"GZIP",NONE:"NONE"},pJe={IGNORE:"IGNORE",NONE:"NONE",USE:"USE"},hJe={DOCUMENT:"DOCUMENT",LINES:"LINES"},mJe={ALWAYS:"ALWAYS",ASNEEDED:"ASNEEDED"},gJe={SELECT:"SELECT"};Object.defineProperty(q,"$Command",{enumerable:!0,get:function(){return fe.Command}});Object.defineProperty(q,"__Client",{enumerable:!0,get:function(){return fe.Client}});q.AbortMultipartUploadCommand=qw;q.AnalyticsS3ExportFileFormat=xXe;q.ArchiveStatus=iJe;q.BucketAbacStatus=ZYe;q.BucketAccelerateStatus=rXe;q.BucketAlreadyExists=rZ;q.BucketAlreadyOwnedByYou=iZ;q.BucketCannedACL=mXe;q.BucketLocationConstraint=bXe;q.BucketLogsPermission=BXe;q.BucketType=yXe;q.BucketVersioningStatus=JXe;q.ChecksumAlgorithm=uXe;q.ChecksumMode=eJe;q.ChecksumType=sXe;q.CompleteMultipartUploadCommand=jw;q.CompressionType=dJe;q.CopyObjectCommand=Uw;q.CreateBucketCommand=Hw;q.CreateBucketMetadataConfigurationCommand=$w;q.CreateBucketMetadataTableConfigurationCommand=Gw;q.CreateMultipartUploadCommand=zw;q.CreateSessionCommand=Cm;q.DataRedundancy=gXe;q.DeleteBucketAnalyticsConfigurationCommand=Vw;q.DeleteBucketCommand=Ww;q.DeleteBucketCorsCommand=Kw;q.DeleteBucketEncryptionCommand=Yw;q.DeleteBucketIntelligentTieringConfigurationCommand=Xw;q.DeleteBucketInventoryConfigurationCommand=Jw;q.DeleteBucketLifecycleCommand=Qw;q.DeleteBucketMetadataConfigurationCommand=Zw;q.DeleteBucketMetadataTableConfigurationCommand=eS;q.DeleteBucketMetricsConfigurationCommand=tS;q.DeleteBucketOwnershipControlsCommand=rS;q.DeleteBucketPolicyCommand=nS;q.DeleteBucketReplicationCommand=iS;q.DeleteBucketTaggingCommand=oS;q.DeleteBucketWebsiteCommand=sS;q.DeleteMarkerReplicationStatus=HXe;q.DeleteObjectCommand=aS;q.DeleteObjectTaggingCommand=uS;q.DeleteObjectsCommand=cS;q.DeletePublicAccessBlockCommand=lS;q.EncodingType=oJe;q.EncryptionType=AXe;q.EncryptionTypeMismatch=hZ;q.Event=jXe;q.ExistingObjectReplicationStatus=zXe;q.ExpirationState=vXe;q.ExpirationStatus=MXe;q.ExpressionType=fJe;q.FileHeaderInfo=pJe;q.FilterRuleName=UXe;q.GetBucketAbacCommand=fS;q.GetBucketAccelerateConfigurationCommand=dS;q.GetBucketAclCommand=pS;q.GetBucketAnalyticsConfigurationCommand=hS;q.GetBucketCorsCommand=mS;q.GetBucketEncryptionCommand=gS;q.GetBucketIntelligentTieringConfigurationCommand=yS;q.GetBucketInventoryConfigurationCommand=_S;q.GetBucketLifecycleConfigurationCommand=bS;q.GetBucketLocationCommand=ES;q.GetBucketLoggingCommand=wS;q.GetBucketMetadataConfigurationCommand=SS;q.GetBucketMetadataTableConfigurationCommand=vS;q.GetBucketMetricsConfigurationCommand=CS;q.GetBucketNotificationConfigurationCommand=xS;q.GetBucketOwnershipControlsCommand=TS;q.GetBucketPolicyCommand=AS;q.GetBucketPolicyStatusCommand=RS;q.GetBucketReplicationCommand=PS;q.GetBucketRequestPaymentCommand=OS;q.GetBucketTaggingCommand=IS;q.GetBucketVersioningCommand=DS;q.GetBucketWebsiteCommand=kS;q.GetObjectAclCommand=NS;q.GetObjectAttributesCommand=MS;q.GetObjectCommand=LS;q.GetObjectLegalHoldCommand=BS;q.GetObjectLockConfigurationCommand=FS;q.GetObjectRetentionCommand=qS;q.GetObjectTaggingCommand=jS;q.GetObjectTorrentCommand=US;q.GetPublicAccessBlockCommand=HS;q.HeadBucketCommand=$f;q.HeadObjectCommand=Gf;q.IdempotencyParameterMismatch=SZ;q.IntelligentTieringAccessTier=PXe;q.IntelligentTieringStatus=RXe;q.InvalidObjectState=cZ;q.InvalidRequest=gZ;q.InvalidWriteOffset=_Z;q.InventoryConfigurationState=wXe;q.InventoryFormat=OXe;q.InventoryFrequency=kXe;q.InventoryIncludedObjectVersions=IXe;q.InventoryOptionalField=DXe;q.JSONType=hJe;q.ListBucketAnalyticsConfigurationsCommand=$S;q.ListBucketIntelligentTieringConfigurationsCommand=GS;q.ListBucketInventoryConfigurationsCommand=zS;q.ListBucketMetricsConfigurationsCommand=VS;q.ListBucketsCommand=xm;q.ListDirectoryBucketsCommand=Tm;q.ListMultipartUploadsCommand=WS;q.ListObjectVersionsCommand=YS;q.ListObjectsCommand=KS;q.ListObjectsV2Command=Am;q.ListPartsCommand=Rm;q.LocationType=_Xe;q.MFADelete=uJe;q.MFADeleteStatus=XXe;q.MetadataDirective=lXe;q.MetricsStatus=$Xe;q.NoSuchBucket=sZ;q.NoSuchKey=lZ;q.NoSuchUpload=QQ;q.NotFound=dZ;q.ObjectAlreadyInActiveTierError=CZ;q.ObjectAttributes=tJe;q.ObjectCannedACL=cXe;q.ObjectLockEnabled=rJe;q.ObjectLockLegalHoldStatus=fXe;q.ObjectLockMode=dXe;q.ObjectLockRetentionMode=nJe;q.ObjectNotInActiveTierError=eZ;q.ObjectOwnership=EXe;q.ObjectStorageClass=sJe;q.ObjectVersionStorageClass=cJe;q.OptionalObjectAttributes=aJe;q.OwnerOverride=oXe;q.PartitionDateSource=FXe;q.Payer=YXe;q.Permission=iXe;q.Protocol=QXe;q.PutBucketAbacCommand=XS;q.PutBucketAccelerateConfigurationCommand=JS;q.PutBucketAclCommand=QS;q.PutBucketAnalyticsConfigurationCommand=ZS;q.PutBucketCorsCommand=ev;q.PutBucketEncryptionCommand=tv;q.PutBucketIntelligentTieringConfigurationCommand=rv;q.PutBucketInventoryConfigurationCommand=nv;q.PutBucketLifecycleConfigurationCommand=iv;q.PutBucketLoggingCommand=ov;q.PutBucketMetricsConfigurationCommand=sv;q.PutBucketNotificationConfigurationCommand=av;q.PutBucketOwnershipControlsCommand=cv;q.PutBucketPolicyCommand=uv;q.PutBucketReplicationCommand=lv;q.PutBucketRequestPaymentCommand=fv;q.PutBucketTaggingCommand=dv;q.PutBucketVersioningCommand=pv;q.PutBucketWebsiteCommand=hv;q.PutObjectAclCommand=mv;q.PutObjectCommand=gv;q.PutObjectLegalHoldCommand=yv;q.PutObjectLockConfigurationCommand=_v;q.PutObjectRetentionCommand=bv;q.PutObjectTaggingCommand=Ev;q.PutPublicAccessBlockCommand=wv;q.QuoteFields=mJe;q.RenameObjectCommand=Sv;q.ReplicaModificationsStatus=VXe;q.ReplicationRuleStatus=KXe;q.ReplicationStatus=ZXe;q.ReplicationTimeStatus=GXe;q.RequestCharged=eXe;q.RequestPayer=tXe;q.RestoreObjectCommand=vv;q.RestoreRequestType=gJe;q.S3=Ov;q.S3Client=lc;q.S3ServiceException=In;q.S3TablesBucketType=qXe;q.SelectObjectContentCommand=Cv;q.ServerSideEncryption=aXe;q.SessionMode=CXe;q.SseKmsEncryptedObjectsStatus=WXe;q.StorageClass=pXe;q.StorageClassAnalysisSchemaVersion=TXe;q.TableSseAlgorithm=SXe;q.TaggingDirective=hXe;q.Tier=lJe;q.TooManyParts=EZ;q.TransitionDefaultMinimumObjectSize=LXe;q.TransitionStorageClass=NXe;q.Type=nXe;q.UpdateBucketMetadataInventoryTableConfigurationCommand=xv;q.UpdateBucketMetadataJournalTableConfigurationCommand=Tv;q.UploadPartCommand=Av;q.UploadPartCopyCommand=Rv;q.WriteGetObjectResponseCommand=Pv;q.paginateListBuckets=UYe;q.paginateListDirectoryBuckets=HYe;q.paginateListObjectsV2=$Ye;q.paginateListParts=GYe;q.waitForBucketExists=zYe;q.waitForBucketNotExists=WYe;q.waitForObjectExists=YYe;q.waitForObjectNotExists=JYe;q.waitUntilBucketExists=VYe;q.waitUntilBucketNotExists=KYe;q.waitUntilObjectExists=XYe;q.waitUntilObjectNotExists=QYe});var one=E((YSt,ine)=>{"use strict";var rne=Nc(),Sd=E4(),nne=require("stream");ine.exports={buffer:function(e,t){return Sd({stream:function(n,i){let o=nne.PassThrough(),s=i?n+i:void 0;return o.end(e.slice(n,s)),o},size:function(){return Promise.resolve(e.length)}},t)},file:function(e,t){return Sd({stream:function(n,i){let o=i?n+i:void 0;return rne.createReadStream(e,{start:n,end:o})},size:function(){return new Promise(function(n,i){rne.stat(e,function(o,s){o?i(o):n(s.size)})})}},t)},url:function(e,t,r){if(typeof t=="string"&&(t={url:t}),!t.url)throw"URL missing";return t.headers=t.headers||{},Sd({stream:function(i,o){let s=Object.create(t),a=o?i+o:"";return s.headers=Object.create(t.headers),s.headers.range="bytes="+i+"-"+a,e(s)},size:function(){return new Promise(function(i,o){let s=e(t);s.on("response",function(a){s.abort(),a.headers["content-length"]?i(a.headers["content-length"]):o(new Error("Missing content length header"))}).on("error",o)})}},r)},s3:function(e,t,r){return Sd({size:function(){return new Promise(function(i,o){e.headObject(t,function(s,a){s?o(s):i(a.ContentLength)})})},stream:function(i,o){let s={};for(let c in t)s[c]=t[c];let a=o?i+o:"";return s.Range="bytes="+i+"-"+a,e.getObject(s).createReadStream()}},r)},s3_v3:function(e,t,r){let{GetObjectCommand:n,HeadObjectCommand:i}=tne();return Sd({size:async()=>{let s=await e.send(new i({Bucket:t.Bucket,Key:t.Key}));return s.ContentLength?s.ContentLength:0},stream:(s,a)=>{let c=nne.PassThrough(),u=a?s+a:"";return e.send(new n({Bucket:t.Bucket,Key:t.Key,Range:`bytes=${s}-${u}`})).then(l=>{l.Body.pipe(c)}).catch(l=>{c.emit("error",l)}),c}},r)},custom:function(e,t){return Sd(e,t)}}});var sne=E(eg=>{"use strict";eg.Parse=sy();eg.ParseOne=OB();eg.Extract=T3();eg.Open=one()});var hi=E((lvt,ane)=>{"use strict";var cN=class e extends Error{constructor(t){super(`Format functions must be synchronous taking a two arguments: (info, opts)
|
|
242
|
+
Found: ${t.toString().split(`
|
|
3
243
|
`)[0]}
|
|
4
|
-
`),Error.captureStackTrace(this,
|
|
5
|
-
`)!=-1,n=this._styles,i=n.length;i--;){var o
|
|
6
|
-
`));return!0}
|
|
7
|
-
${
|
|
8
|
-
${
|
|
9
|
-
${
|
|
10
|
-
${
|
|
11
|
-
${
|
|
12
|
-
${
|
|
13
|
-
${
|
|
14
|
-
${
|
|
15
|
-
${
|
|
16
|
-
${
|
|
17
|
-
${
|
|
18
|
-
${
|
|
19
|
-
${
|
|
20
|
-
${
|
|
21
|
-
${
|
|
22
|
-
${
|
|
23
|
-
${
|
|
24
|
-
${D}`),v.pop(),`{${_}}`}case"number":return isFinite(h)?String(h):e?e(h):"null";case"boolean":return h===!0?"true":"false";case"undefined":return;case"bigint":if(n)return String(h);default:return e?e(h):void 0}}function E(g,h,v){switch(typeof h){case"string":return Ge(h);case"object":{if(h===null)return"null";if(typeof h.toJSON=="function"){if(h=h.toJSON(g),typeof h!="object")return E(g,h,v);if(h===null)return"null"}if(v.indexOf(h)!==-1)return r;let R="",N=h.length!==void 0;if(N&&Array.isArray(h)){if(h.length===0)return"[]";if(s<v.length+1)return'"[Array]"';v.push(h);let _=Math.min(h.length,a),M=0;for(;M<_-1;M++){let I=E(String(M),h[M],v);R+=I!==void 0?I:"null",R+=","}let p=E(String(M),h[M],v);if(R+=p!==void 0?p:"null",h.length-1>a){let I=h.length-a-1;R+=`,"... ${ft(I)} not stringified"`}return v.pop(),`[${R}]`}let D=Object.keys(h),m=D.length;if(m===0)return"{}";if(s<v.length+1)return'"[Object]"';let c="",l=Math.min(m,a);N&&fo(h)&&(R+=du(h,",",a),D=D.slice(h.length),l-=h.length,c=","),i&&(D=lo(D,o)),v.push(h);for(let _=0;_<l;_++){let M=D[_],p=E(M,h[M],v);p!==void 0&&(R+=`${c}${Ge(M)}:${p}`,c=",")}if(m>a){let _=m-a;R+=`${c}"...":"${ft(_)} not stringified"`}return v.pop(),`{${R}}`}case"number":return isFinite(h)?String(h):e?e(h):"null";case"boolean":return h===!0?"true":"false";case"undefined":return;case"bigint":if(n)return String(h);default:return e?e(h):void 0}}function y(g,h,v){if(arguments.length>1){let R="";if(typeof v=="number"?R=" ".repeat(Math.min(v,10)):typeof v=="string"&&(R=v.slice(0,10)),h!=null){if(typeof h=="function")return u("",{"":g},[],h,R,"");if(Array.isArray(h))return d("",g,[],_y(h),R,"")}if(R.length!==0)return w("",g,[],R,"")}return E("",g,[])}return y}});var po=S((nx,gu)=>{"use strict";var Ey=ye(),{MESSAGE:Sy}=ne(),Ty=or();function Oy(t,e){return typeof e=="bigint"?e.toString():e}gu.exports=Ey((t,e)=>{let r=Ty.configure(e);return t[Sy]=r(t,e.replacer||Oy,e.space),t})});var bu=S((ix,yu)=>{"use strict";var Dy=ye();yu.exports=Dy((t,e)=>e.message?(t.message=`[${e.label}] ${t.message}`,t):(t.label=e.label,t))});var _u=S((ox,wu)=>{"use strict";var xy=ye(),{MESSAGE:Py}=ne(),Iy=or();wu.exports=xy(t=>{let e={};return t.message&&(e["@message"]=t.message,delete t.message),t.timestamp&&(e["@timestamp"]=t.timestamp,delete t.timestamp),e["@fields"]=t,t[Py]=Iy(e),t})});var Eu=S((sx,vu)=>{"use strict";var My=ye();function Ny(t,e,r){let n=e.reduce((o,s)=>(o[s]=t[s],delete t[s],o),{}),i=Object.keys(t).reduce((o,s)=>(o[s]=t[s],delete t[s],o),{});return Object.assign(t,n,{[r]:i}),t}function Ry(t,e,r){return t[r]=e.reduce((n,i)=>(n[i]=t[i],delete t[i],n),{}),t}vu.exports=My((t,e={})=>{let r="metadata";e.key&&(r=e.key);let n=[];return!e.fillExcept&&!e.fillWith&&(n.push("level"),n.push("message")),e.fillExcept&&(n=e.fillExcept),n.length>0?Ny(t,n,r):e.fillWith?Ry(t,e.fillWith,r):t})});var Tu=S((ax,Su)=>{"use strict";var Pt=1e3,It=Pt*60,Mt=It*60,ht=Mt*24,Ay=ht*7,Ly=ht*365.25;Su.exports=function(t,e){e=e||{};var r=typeof t;if(r==="string"&&t.length>0)return Cy(t);if(r==="number"&&isFinite(t))return e.long?Fy(t):qy(t);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(t))};function Cy(t){if(t=String(t),!(t.length>100)){var e=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(t);if(e){var r=parseFloat(e[1]),n=(e[2]||"ms").toLowerCase();switch(n){case"years":case"year":case"yrs":case"yr":case"y":return r*Ly;case"weeks":case"week":case"w":return r*Ay;case"days":case"day":case"d":return r*ht;case"hours":case"hour":case"hrs":case"hr":case"h":return r*Mt;case"minutes":case"minute":case"mins":case"min":case"m":return r*It;case"seconds":case"second":case"secs":case"sec":case"s":return r*Pt;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return r;default:return}}}}function qy(t){var e=Math.abs(t);return e>=ht?Math.round(t/ht)+"d":e>=Mt?Math.round(t/Mt)+"h":e>=It?Math.round(t/It)+"m":e>=Pt?Math.round(t/Pt)+"s":t+"ms"}function Fy(t){var e=Math.abs(t);return e>=ht?hn(t,e,ht,"day"):e>=Mt?hn(t,e,Mt,"hour"):e>=It?hn(t,e,It,"minute"):e>=Pt?hn(t,e,Pt,"second"):t+" ms"}function hn(t,e,r,n){var i=e>=r*1.5;return Math.round(t/r)+" "+n+(i?"s":"")}});var Du=S((sr,Ou)=>{"use strict";var jy=ye(),ky=Tu();Ou.exports=jy(t=>{let e=+new Date;return sr.diff=e-(sr.prevTime||e),sr.prevTime=e,t.ms=`+${ky(sr.diff)}`,t})});var Iu=S((ux,Pu)=>{"use strict";var By=require("util").inspect,$y=ye(),{LEVEL:Uy,MESSAGE:xu,SPLAT:Vy}=ne();Pu.exports=$y((t,e={})=>{let r=Object.assign({},t);return delete r[Uy],delete r[xu],delete r[Vy],t[xu]=By(r,!1,e.depth||null,e.colorize),t})});var Mu=S((lx,pn)=>{"use strict";var{MESSAGE:Hy}=ne(),dn=class{constructor(e){this.template=e}transform(e){return e[Hy]=this.template(e),e}};pn.exports=t=>new dn(t);pn.exports.Printf=pn.exports.Format=dn});var Au=S((fx,Ru)=>{"use strict";var Wy=ye(),{MESSAGE:Nu}=ne(),Xy=or();Ru.exports=Wy(t=>{let e=Xy(Object.assign({},t,{level:void 0,message:void 0,splat:void 0})),r=t.padding&&t.padding[t.level]||"";return e!=="{}"?t[Nu]=`${t.level}:${r} ${t.message} ${e}`:t[Nu]=`${t.level}:${r} ${t.message}`,t})});var qu=S((cx,Cu)=>{"use strict";var Ky=require("util"),{SPLAT:Lu}=ne(),Gy=/%[scdjifoO%]/g,Yy=/%%/g,mo=class{constructor(e){this.options=e}_splat(e,r){let n=e.message,i=e[Lu]||e.splat||[],o=n.match(Yy),s=o&&o.length||0,u=r.length-s-i.length,d=u<0?i.splice(u,-1*u):[],w=d.length;if(w)for(let E=0;E<w;E++)Object.assign(e,d[E]);return e.message=Ky.format(n,...i),e}transform(e){let r=e.message,n=e[Lu]||e.splat;if(!n||!n.length)return e;let i=r&&r.match&&r.match(Gy);if(!i&&(n||n.length)){let o=n.length>1?n.splice(0):n,s=o.length;if(s)for(let a=0;a<s;a++)Object.assign(e,o[a]);return e}return i?this._splat(e,i):e}};Cu.exports=t=>new mo(t)});var ju=S((mn,Fu)=>{"use strict";(function(t,e){typeof mn=="object"&&typeof Fu<"u"?e(mn):typeof define=="function"&&define.amd?define(["exports"],e):e(t.fecha={})})(mn,(function(t){"use strict";var e=/d{1,4}|M{1,4}|YY(?:YY)?|S{1,3}|Do|ZZ|Z|([HhMsDm])\1?|[aA]|"[^"]*"|'[^']*'/g,r="\\d\\d?",n="\\d\\d",i="\\d{3}",o="\\d{4}",s="[^\\s]+",a=/\[([^]*?)\]/gm;function u(x,q){for(var j=[],J=0,k=x.length;J<k;J++)j.push(x[J].substr(0,q));return j}var d=function(x){return function(q,j){var J=j[x].map(function(ge){return ge.toLowerCase()}),k=J.indexOf(q.toLowerCase());return k>-1?k:null}};function w(x){for(var q=[],j=1;j<arguments.length;j++)q[j-1]=arguments[j];for(var J=0,k=q;J<k.length;J++){var ge=k[J];for(var Fe in ge)x[Fe]=ge[Fe]}return x}var E=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],y=["January","February","March","April","May","June","July","August","September","October","November","December"],g=u(y,3),h=u(E,3),v={dayNamesShort:h,dayNames:E,monthNamesShort:g,monthNames:y,amPm:["am","pm"],DoFn:function(x){return x+["th","st","nd","rd"][x%10>3?0:(x-x%10!==10?1:0)*x%10]}},R=w({},v),N=function(x){return R=w(R,x)},D=function(x){return x.replace(/[|\\{()[^$+*?.-]/g,"\\$&")},m=function(x,q){for(q===void 0&&(q=2),x=String(x);x.length<q;)x="0"+x;return x},c={D:function(x){return String(x.getDate())},DD:function(x){return m(x.getDate())},Do:function(x,q){return q.DoFn(x.getDate())},d:function(x){return String(x.getDay())},dd:function(x){return m(x.getDay())},ddd:function(x,q){return q.dayNamesShort[x.getDay()]},dddd:function(x,q){return q.dayNames[x.getDay()]},M:function(x){return String(x.getMonth()+1)},MM:function(x){return m(x.getMonth()+1)},MMM:function(x,q){return q.monthNamesShort[x.getMonth()]},MMMM:function(x,q){return q.monthNames[x.getMonth()]},YY:function(x){return m(String(x.getFullYear()),4).substr(2)},YYYY:function(x){return m(x.getFullYear(),4)},h:function(x){return String(x.getHours()%12||12)},hh:function(x){return m(x.getHours()%12||12)},H:function(x){return String(x.getHours())},HH:function(x){return m(x.getHours())},m:function(x){return String(x.getMinutes())},mm:function(x){return m(x.getMinutes())},s:function(x){return String(x.getSeconds())},ss:function(x){return m(x.getSeconds())},S:function(x){return String(Math.round(x.getMilliseconds()/100))},SS:function(x){return m(Math.round(x.getMilliseconds()/10),2)},SSS:function(x){return m(x.getMilliseconds(),3)},a:function(x,q){return x.getHours()<12?q.amPm[0]:q.amPm[1]},A:function(x,q){return x.getHours()<12?q.amPm[0].toUpperCase():q.amPm[1].toUpperCase()},ZZ:function(x){var q=x.getTimezoneOffset();return(q>0?"-":"+")+m(Math.floor(Math.abs(q)/60)*100+Math.abs(q)%60,4)},Z:function(x){var q=x.getTimezoneOffset();return(q>0?"-":"+")+m(Math.floor(Math.abs(q)/60),2)+":"+m(Math.abs(q)%60,2)}},l=function(x){return+x-1},_=[null,r],M=[null,s],p=["isPm",s,function(x,q){var j=x.toLowerCase();return j===q.amPm[0]?0:j===q.amPm[1]?1:null}],I=["timezoneOffset","[^\\s]*?[\\+\\-]\\d\\d:?\\d\\d|[^\\s]*?Z?",function(x){var q=(x+"").match(/([+-]|\d\d)/gi);if(q){var j=+q[1]*60+parseInt(q[2],10);return q[0]==="+"?j:-j}return 0}],T={D:["day",r],DD:["day",n],Do:["day",r+s,function(x){return parseInt(x,10)}],M:["month",r,l],MM:["month",n,l],YY:["year",n,function(x){var q=new Date,j=+(""+q.getFullYear()).substr(0,2);return+(""+(+x>68?j-1:j)+x)}],h:["hour",r,void 0,"isPm"],hh:["hour",n,void 0,"isPm"],H:["hour",r],HH:["hour",n],m:["minute",r],mm:["minute",n],s:["second",r],ss:["second",n],YYYY:["year",o],S:["millisecond","\\d",function(x){return+x*100}],SS:["millisecond",n,function(x){return+x*10}],SSS:["millisecond",i],d:_,dd:_,ddd:M,dddd:M,MMM:["month",s,d("monthNamesShort")],MMMM:["month",s,d("monthNames")],a:p,A:p,ZZ:I,Z:I},P={default:"ddd MMM DD YYYY HH:mm:ss",shortDate:"M/D/YY",mediumDate:"MMM D, YYYY",longDate:"MMMM D, YYYY",fullDate:"dddd, MMMM D, YYYY",isoDate:"YYYY-MM-DD",isoDateTime:"YYYY-MM-DDTHH:mm:ssZ",shortTime:"HH:mm",mediumTime:"HH:mm:ss",longTime:"HH:mm:ss.SSS"},L=function(x){return w(P,x)},C=function(x,q,j){if(q===void 0&&(q=P.default),j===void 0&&(j={}),typeof x=="number"&&(x=new Date(x)),Object.prototype.toString.call(x)!=="[object Date]"||isNaN(x.getTime()))throw new Error("Invalid Date pass to format");q=P[q]||q;var J=[];q=q.replace(a,function(ge,Fe){return J.push(Fe),"@@@"});var k=w(w({},R),j);return q=q.replace(e,function(ge){return c[ge](x,k)}),q.replace(/@@@/g,function(){return J.shift()})};function B(x,q,j){if(j===void 0&&(j={}),typeof q!="string")throw new Error("Invalid format in fecha parse");if(q=P[q]||q,x.length>1e3)return null;var J=new Date,k={year:J.getFullYear(),month:0,day:1,hour:0,minute:0,second:0,millisecond:0,isPm:null,timezoneOffset:null},ge=[],Fe=[],We=q.replace(a,function(z,de){return Fe.push(D(de)),"@@@"}),Xe={},Qr={};We=D(We).replace(e,function(z){var de=T[z],Zt=de[0],Zr=de[1],Dt=de[3];if(Xe[Zt])throw new Error("Invalid format. "+Zt+" specified twice in format");return Xe[Zt]=!0,Dt&&(Qr[Dt]=!0),ge.push(de),"("+Zr+")"}),Object.keys(Qr).forEach(function(z){if(!Xe[z])throw new Error("Invalid format. "+z+" is required in specified format")}),We=We.replace(/@@@/g,function(){return Fe.shift()});var b=x.match(new RegExp(We,"i"));if(!b)return null;for(var f=w(w({},R),j),A=1;A<b.length;A++){var O=ge[A-1],K=O[0],Y=O[2],Q=Y?Y(b[A],f):+b[A];if(Q==null)return null;k[K]=Q}k.isPm===1&&k.hour!=null&&+k.hour!=12?k.hour=+k.hour+12:k.isPm===0&&+k.hour==12&&(k.hour=0);var ie;if(k.timezoneOffset==null){ie=new Date(k.year,k.month,k.day,k.hour,k.minute,k.second,k.millisecond);for(var oe=[["month","getMonth"],["day","getDate"],["hour","getHours"],["minute","getMinutes"],["second","getSeconds"]],A=0,Ke=oe.length;A<Ke;A++)if(Xe[oe[A][0]]&&k[oe[A][0]]!==ie[oe[A][1]]())return null}else if(ie=new Date(Date.UTC(k.year,k.month,k.day,k.hour,k.minute-k.timezoneOffset,k.second,k.millisecond)),k.month>11||k.month<0||k.day>31||k.day<1||k.hour>23||k.hour<0||k.minute>59||k.minute<0||k.second>59||k.second<0)return null;return ie}var $={format:C,parse:B,defaultI18n:v,setGlobalDateI18n:N,setGlobalDateMasks:L};t.assign=w,t.default=$,t.format=C,t.parse=B,t.defaultI18n=v,t.setGlobalDateI18n=N,t.setGlobalDateMasks=L,Object.defineProperty(t,"__esModule",{value:!0})}))});var Bu=S((hx,ku)=>{"use strict";var zy=ju(),Jy=ye();ku.exports=Jy((t,e={})=>(e.format&&(t.timestamp=typeof e.format=="function"?e.format():zy.format(new Date,e.format)),t.timestamp||(t.timestamp=new Date().toISOString()),e.alias&&(t[e.alias]=t.timestamp),t))});var Uu=S((dx,$u)=>{"use strict";var go=Ji(),Qy=ye(),{MESSAGE:yo}=ne();$u.exports=Qy((t,e)=>(e.level!==!1&&(t.level=go.strip(t.level)),e.message!==!1&&(t.message=go.strip(String(t.message))),e.raw!==!1&&t[yo]&&(t[yo]=go.strip(String(t[yo]))),t))});var wo=S(bo=>{"use strict";var Zy=bo.format=ye();bo.levels=nu();function he(t,e){Object.defineProperty(Zy,t,{get(){return e()},configurable:!0})}he("align",function(){return ou()});he("errors",function(){return uu()});he("cli",function(){return fu()});he("combine",function(){return hu()});he("colorize",function(){return un()});he("json",function(){return po()});he("label",function(){return bu()});he("logstash",function(){return _u()});he("metadata",function(){return Eu()});he("ms",function(){return Du()});he("padLevels",function(){return so()});he("prettyPrint",function(){return Iu()});he("printf",function(){return Mu()});he("simple",function(){return Au()});he("splat",function(){return qu()});he("timestamp",function(){return Bu()});he("uncolorize",function(){return Uu()})});var _o=S(gn=>{"use strict";var{format:Vu}=require("util");gn.warn={deprecated(t){return()=>{throw new Error(Vu("{ %s } was removed in winston@3.0.0.",t))}},useFormat(t){return()=>{throw new Error([Vu("{ %s } was removed in winston@3.0.0.",t),"Use a custom winston.format = winston.format(function) instead."].join(`
|
|
25
|
-
`))}},forFunctions(t,e,r){r.forEach(n=>{t[n]=gn.warn[e](n)})},forProperties(t,e,r){r.forEach(n=>{let i=gn.warn[e](n);Object.defineProperty(t,n,{get:i,set:i})})}}});var Hu=S((gx,eb)=>{eb.exports={name:"winston",description:"A logger for just about everything.",version:"3.18.3",author:"Charlie Robbins <charlie.robbins@gmail.com>",maintainers:["David Hyde <dabh@alumni.stanford.edu>"],repository:{type:"git",url:"https://github.com/winstonjs/winston.git"},keywords:["winston","logger","logging","logs","sysadmin","bunyan","pino","loglevel","tools","json","stream"],dependencies:{"@dabh/diagnostics":"^2.0.8","@colors/colors":"^1.6.0",async:"^3.2.3","is-stream":"^2.0.0",logform:"^2.7.0","one-time":"^1.0.0","readable-stream":"^3.4.0","safe-stable-stringify":"^2.3.1","stack-trace":"0.0.x","triple-beam":"^1.3.0","winston-transport":"^4.9.0"},devDependencies:{"@babel/cli":"^7.23.9","@babel/core":"^7.24.0","@babel/preset-env":"^7.24.0","@dabh/eslint-config-populist":"^4.4.0","@types/node":"^20.11.24","abstract-winston-transport":"^0.5.1",assume:"^2.2.0","cross-spawn-async":"^2.2.5",eslint:"^8.57.0",hock:"^1.4.1",mocha:"^10.3.0",nyc:"^17.1.0",rimraf:"5.0.1",split2:"^4.1.0","std-mocks":"^2.0.0",through2:"^4.0.2","winston-compat":"^0.1.5"},main:"./lib/winston.js",browser:"./dist/winston",types:"./index.d.ts",scripts:{lint:"eslint lib/*.js lib/winston/*.js lib/winston/**/*.js --resolve-plugins-relative-to ./node_modules/@dabh/eslint-config-populist",test:"rimraf test/fixtures/logs/* && mocha","test:coverage":"nyc npm run test:unit","test:unit":"mocha test/unit","test:integration":"mocha test/integration",build:"rimraf dist && babel lib -d dist",prepublishOnly:"npm run build"},engines:{node:">= 12.0.0"},license:"MIT"}});var vo=S((yx,Wu)=>{"use strict";Wu.exports=require("util").deprecate});var Eo=S((bx,Xu)=>{"use strict";Xu.exports=require("stream")});var To=S((wx,Gu)=>{"use strict";function tb(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(So,this,t)):process.nextTick(So,this,t)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(t||null,function(o){!e&&o?r._writableState?r._writableState.errorEmitted?process.nextTick(yn,r):(r._writableState.errorEmitted=!0,process.nextTick(Ku,r,o)):process.nextTick(Ku,r,o):e?(process.nextTick(yn,r),e(o)):process.nextTick(yn,r)}),this)}function Ku(t,e){So(t,e),yn(t)}function yn(t){t._writableState&&!t._writableState.emitClose||t._readableState&&!t._readableState.emitClose||t.emit("close")}function rb(){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 So(t,e){t.emit("error",e)}function nb(t,e){var r=t._readableState,n=t._writableState;r&&r.autoDestroy||n&&n.autoDestroy?t.destroy(e):t.emit("error",e)}Gu.exports={destroy:tb,undestroy:rb,errorOrDestroy:nb}});var Nt=S((_x,Ju)=>{"use strict";var zu={};function ve(t,e,r){r||(r=Error);function n(o,s,a){return typeof e=="string"?e:e(o,s,a)}class i extends r{constructor(s,a,u){super(n(s,a,u))}}i.prototype.name=r.name,i.prototype.code=t,zu[t]=i}function Yu(t,e){if(Array.isArray(t)){let r=t.length;return t=t.map(n=>String(n)),r>2?`one of ${e} ${t.slice(0,r-1).join(", ")}, or `+t[r-1]:r===2?`one of ${e} ${t[0]} or ${t[1]}`:`of ${e} ${t[0]}`}else return`of ${e} ${String(t)}`}function ib(t,e,r){return t.substr(!r||r<0?0:+r,e.length)===e}function ob(t,e,r){return(r===void 0||r>t.length)&&(r=t.length),t.substring(r-e.length,r)===e}function sb(t,e,r){return typeof r!="number"&&(r=0),r+e.length>t.length?!1:t.indexOf(e,r)!==-1}ve("ERR_INVALID_OPT_VALUE",function(t,e){return'The value "'+e+'" is invalid for option "'+t+'"'},TypeError);ve("ERR_INVALID_ARG_TYPE",function(t,e,r){let n;typeof e=="string"&&ib(e,"not ")?(n="must not be",e=e.replace(/^not /,"")):n="must be";let i;if(ob(t," argument"))i=`The ${t} ${n} ${Yu(e,"type")}`;else{let o=sb(t,".")?"property":"argument";i=`The "${t}" ${o} ${n} ${Yu(e,"type")}`}return i+=`. Received type ${typeof r}`,i},TypeError);ve("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF");ve("ERR_METHOD_NOT_IMPLEMENTED",function(t){return"The "+t+" method is not implemented"});ve("ERR_STREAM_PREMATURE_CLOSE","Premature close");ve("ERR_STREAM_DESTROYED",function(t){return"Cannot call "+t+" after a stream was destroyed"});ve("ERR_MULTIPLE_CALLBACK","Callback called multiple times");ve("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable");ve("ERR_STREAM_WRITE_AFTER_END","write after end");ve("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError);ve("ERR_UNKNOWN_ENCODING",function(t){return"Unknown encoding: "+t},TypeError);ve("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event");Ju.exports.codes=zu});var Oo=S((vx,Qu)=>{"use strict";var ab=Nt().codes.ERR_INVALID_OPT_VALUE;function ub(t,e,r){return t.highWaterMark!=null?t.highWaterMark:e?t[r]:null}function lb(t,e,r,n){var i=ub(e,n,r);if(i!=null){if(!(isFinite(i)&&Math.floor(i)===i)||i<0){var o=n?r:"highWaterMark";throw new ab(o,i)}return Math.floor(i)}return t.objectMode?16:16*1024}Qu.exports={getHighWaterMark:lb}});var Zu=S((Ex,Do)=>{"use strict";typeof Object.create=="function"?Do.exports=function(e,r){r&&(e.super_=r,e.prototype=Object.create(r.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:Do.exports=function(e,r){if(r){e.super_=r;var n=function(){};n.prototype=r.prototype,e.prototype=new n,e.prototype.constructor=e}}});var je=S((Sx,Po)=>{"use strict";try{if(xo=require("util"),typeof xo.inherits!="function")throw"";Po.exports=xo.inherits}catch{Po.exports=Zu()}var xo});var ol=S((Tx,il)=>{"use strict";function el(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),r.push.apply(r,n)}return r}function tl(t){for(var e=1;e<arguments.length;e++){var r=arguments[e]!=null?arguments[e]:{};e%2?el(Object(r),!0).forEach(function(n){fb(t,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):el(Object(r)).forEach(function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(r,n))})}return t}function fb(t,e,r){return e=nl(e),e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function cb(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function rl(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,nl(n.key),n)}}function hb(t,e,r){return e&&rl(t.prototype,e),r&&rl(t,r),Object.defineProperty(t,"prototype",{writable:!1}),t}function nl(t){var e=db(t,"string");return typeof e=="symbol"?e:String(e)}function db(t,e){if(typeof t!="object"||t===null)return t;var r=t[Symbol.toPrimitive];if(r!==void 0){var n=r.call(t,e||"default");if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var pb=require("buffer"),bn=pb.Buffer,mb=require("util"),Io=mb.inspect,gb=Io&&Io.custom||"inspect";function yb(t,e,r){bn.prototype.copy.call(t,e,r)}il.exports=(function(){function t(){cb(this,t),this.head=null,this.tail=null,this.length=0}return hb(t,[{key:"push",value:function(r){var n={data:r,next:null};this.length>0?this.tail.next=n:this.head=n,this.tail=n,++this.length}},{key:"unshift",value:function(r){var n={data:r,next:this.head};this.length===0&&(this.tail=n),this.head=n,++this.length}},{key:"shift",value:function(){if(this.length!==0){var r=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,r}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(r){if(this.length===0)return"";for(var n=this.head,i=""+n.data;n=n.next;)i+=r+n.data;return i}},{key:"concat",value:function(r){if(this.length===0)return bn.alloc(0);for(var n=bn.allocUnsafe(r>>>0),i=this.head,o=0;i;)yb(i.data,n,o),o+=i.data.length,i=i.next;return n}},{key:"consume",value:function(r,n){var i;return r<this.head.data.length?(i=this.head.data.slice(0,r),this.head.data=this.head.data.slice(r)):r===this.head.data.length?i=this.shift():i=n?this._getString(r):this._getBuffer(r),i}},{key:"first",value:function(){return this.head.data}},{key:"_getString",value:function(r){var n=this.head,i=1,o=n.data;for(r-=o.length;n=n.next;){var s=n.data,a=r>s.length?s.length:r;if(a===s.length?o+=s:o+=s.slice(0,r),r-=a,r===0){a===s.length?(++i,n.next?this.head=n.next:this.head=this.tail=null):(this.head=n,n.data=s.slice(a));break}++i}return this.length-=i,o}},{key:"_getBuffer",value:function(r){var n=bn.allocUnsafe(r),i=this.head,o=1;for(i.data.copy(n),r-=i.data.length;i=i.next;){var s=i.data,a=r>s.length?s.length:r;if(s.copy(n,n.length-r,0,a),r-=a,r===0){a===s.length?(++o,i.next?this.head=i.next:this.head=this.tail=null):(this.head=i,i.data=s.slice(a));break}++o}return this.length-=o,n}},{key:gb,value:function(r,n){return Io(this,tl(tl({},n),{},{depth:0,customInspect:!1}))}}]),t})()});var ul=S((Mo,al)=>{"use strict";var wn=require("buffer"),Ie=wn.Buffer;function sl(t,e){for(var r in t)e[r]=t[r]}Ie.from&&Ie.alloc&&Ie.allocUnsafe&&Ie.allocUnsafeSlow?al.exports=wn:(sl(wn,Mo),Mo.Buffer=dt);function dt(t,e,r){return Ie(t,e,r)}dt.prototype=Object.create(Ie.prototype);sl(Ie,dt);dt.from=function(t,e,r){if(typeof t=="number")throw new TypeError("Argument must not be a number");return Ie(t,e,r)};dt.alloc=function(t,e,r){if(typeof t!="number")throw new TypeError("Argument must be a number");var n=Ie(t);return e!==void 0?typeof r=="string"?n.fill(e,r):n.fill(e):n.fill(0),n};dt.allocUnsafe=function(t){if(typeof t!="number")throw new TypeError("Argument must be a number");return Ie(t)};dt.allocUnsafeSlow=function(t){if(typeof t!="number")throw new TypeError("Argument must be a number");return wn.SlowBuffer(t)}});var ur=S(fl=>{"use strict";var Ro=ul().Buffer,ll=Ro.isEncoding||function(t){switch(t=""+t,t&&t.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function bb(t){if(!t)return"utf8";for(var e;;)switch(t){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return t;default:if(e)return;t=(""+t).toLowerCase(),e=!0}}function wb(t){var e=bb(t);if(typeof e!="string"&&(Ro.isEncoding===ll||!ll(t)))throw new Error("Unknown encoding: "+t);return e||t}fl.StringDecoder=ar;function ar(t){this.encoding=wb(t);var e;switch(this.encoding){case"utf16le":this.text=Ob,this.end=Db,e=4;break;case"utf8":this.fillLast=Eb,e=4;break;case"base64":this.text=xb,this.end=Pb,e=3;break;default:this.write=Ib,this.end=Mb;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=Ro.allocUnsafe(e)}ar.prototype.write=function(t){if(t.length===0)return"";var e,r;if(this.lastNeed){if(e=this.fillLast(t),e===void 0)return"";r=this.lastNeed,this.lastNeed=0}else r=0;return r<t.length?e?e+this.text(t,r):this.text(t,r):e||""};ar.prototype.end=Tb;ar.prototype.text=Sb;ar.prototype.fillLast=function(t){if(this.lastNeed<=t.length)return t.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);t.copy(this.lastChar,this.lastTotal-this.lastNeed,0,t.length),this.lastNeed-=t.length};function No(t){return t<=127?0:t>>5===6?2:t>>4===14?3:t>>3===30?4:t>>6===2?-1:-2}function _b(t,e,r){var n=e.length-1;if(n<r)return 0;var i=No(e[n]);return i>=0?(i>0&&(t.lastNeed=i-1),i):--n<r||i===-2?0:(i=No(e[n]),i>=0?(i>0&&(t.lastNeed=i-2),i):--n<r||i===-2?0:(i=No(e[n]),i>=0?(i>0&&(i===2?i=0:t.lastNeed=i-3),i):0))}function vb(t,e,r){if((e[0]&192)!==128)return t.lastNeed=0,"\uFFFD";if(t.lastNeed>1&&e.length>1){if((e[1]&192)!==128)return t.lastNeed=1,"\uFFFD";if(t.lastNeed>2&&e.length>2&&(e[2]&192)!==128)return t.lastNeed=2,"\uFFFD"}}function Eb(t){var e=this.lastTotal-this.lastNeed,r=vb(this,t,e);if(r!==void 0)return r;if(this.lastNeed<=t.length)return t.copy(this.lastChar,e,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);t.copy(this.lastChar,e,0,t.length),this.lastNeed-=t.length}function Sb(t,e){var r=_b(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)}function Tb(t){var e=t&&t.length?this.write(t):"";return this.lastNeed?e+"\uFFFD":e}function Ob(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 Db(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 xb(t,e){var r=(t.length-e)%3;return r===0?t.toString("base64",e):(this.lastNeed=3-r,this.lastTotal=3,r===1?this.lastChar[0]=t[t.length-1]:(this.lastChar[0]=t[t.length-2],this.lastChar[1]=t[t.length-1]),t.toString("base64",e,t.length-r))}function Pb(t){var e=t&&t.length?this.write(t):"";return this.lastNeed?e+this.lastChar.toString("base64",0,3-this.lastNeed):e}function Ib(t){return t.toString(this.encoding)}function Mb(t){return t&&t.length?this.write(t):""}});var pl=S((Dx,dl)=>{"use strict";var cl=Nt().codes.ERR_STREAM_PREMATURE_CLOSE;function Nb(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)}}}function Rb(){}function Ab(t){return t.setHeader&&typeof t.abort=="function"}function hl(t,e,r){if(typeof e=="function")return hl(t,null,e);e||(e={}),r=Nb(r||Rb);var n=e.readable||e.readable!==!1&&t.readable,i=e.writable||e.writable!==!1&&t.writable,o=function(){t.writable||a()},s=t._writableState&&t._writableState.finished,a=function(){i=!1,s=!0,n||r.call(t)},u=t._readableState&&t._readableState.endEmitted,d=function(){n=!1,u=!0,i||r.call(t)},w=function(h){r.call(t,h)},E=function(){var h;if(n&&!u)return(!t._readableState||!t._readableState.ended)&&(h=new cl),r.call(t,h);if(i&&!s)return(!t._writableState||!t._writableState.ended)&&(h=new cl),r.call(t,h)},y=function(){t.req.on("finish",a)};return Ab(t)?(t.on("complete",a),t.on("abort",E),t.req?y():t.on("request",y)):i&&!t._writableState&&(t.on("end",o),t.on("close",o)),t.on("end",d),t.on("finish",a),e.error!==!1&&t.on("error",w),t.on("close",E),function(){t.removeListener("complete",a),t.removeListener("abort",E),t.removeListener("request",y),t.req&&t.req.removeListener("finish",a),t.removeListener("end",o),t.removeListener("close",o),t.removeListener("finish",a),t.removeListener("end",d),t.removeListener("error",w),t.removeListener("close",E)}}dl.exports=hl});var gl=S((xx,ml)=>{"use strict";var _n;function Ye(t,e,r){return e=Lb(e),e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function Lb(t){var e=Cb(t,"string");return typeof e=="symbol"?e:String(e)}function Cb(t,e){if(typeof t!="object"||t===null)return t;var r=t[Symbol.toPrimitive];if(r!==void 0){var n=r.call(t,e||"default");if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var qb=pl(),ze=Symbol("lastResolve"),pt=Symbol("lastReject"),lr=Symbol("error"),vn=Symbol("ended"),mt=Symbol("lastPromise"),Ao=Symbol("handlePromise"),gt=Symbol("stream");function Je(t,e){return{value:t,done:e}}function Fb(t){var e=t[ze];if(e!==null){var r=t[gt].read();r!==null&&(t[mt]=null,t[ze]=null,t[pt]=null,e(Je(r,!1)))}}function jb(t){process.nextTick(Fb,t)}function kb(t,e){return function(r,n){t.then(function(){if(e[vn]){r(Je(void 0,!0));return}e[Ao](r,n)},n)}}var Bb=Object.getPrototypeOf(function(){}),$b=Object.setPrototypeOf((_n={get stream(){return this[gt]},next:function(){var e=this,r=this[lr];if(r!==null)return Promise.reject(r);if(this[vn])return Promise.resolve(Je(void 0,!0));if(this[gt].destroyed)return new Promise(function(s,a){process.nextTick(function(){e[lr]?a(e[lr]):s(Je(void 0,!0))})});var n=this[mt],i;if(n)i=new Promise(kb(n,this));else{var o=this[gt].read();if(o!==null)return Promise.resolve(Je(o,!1));i=new Promise(this[Ao])}return this[mt]=i,i}},Ye(_n,Symbol.asyncIterator,function(){return this}),Ye(_n,"return",function(){var e=this;return new Promise(function(r,n){e[gt].destroy(null,function(i){if(i){n(i);return}r(Je(void 0,!0))})})}),_n),Bb),Ub=function(e){var r,n=Object.create($b,(r={},Ye(r,gt,{value:e,writable:!0}),Ye(r,ze,{value:null,writable:!0}),Ye(r,pt,{value:null,writable:!0}),Ye(r,lr,{value:null,writable:!0}),Ye(r,vn,{value:e._readableState.endEmitted,writable:!0}),Ye(r,Ao,{value:function(o,s){var a=n[gt].read();a?(n[mt]=null,n[ze]=null,n[pt]=null,o(Je(a,!1))):(n[ze]=o,n[pt]=s)},writable:!0}),r));return n[mt]=null,qb(e,function(i){if(i&&i.code!=="ERR_STREAM_PREMATURE_CLOSE"){var o=n[pt];o!==null&&(n[mt]=null,n[ze]=null,n[pt]=null,o(i)),n[lr]=i;return}var s=n[ze];s!==null&&(n[mt]=null,n[ze]=null,n[pt]=null,s(Je(void 0,!0))),n[vn]=!0}),e.on("readable",jb.bind(null,n)),n};ml.exports=Ub});var _l=S((Px,wl)=>{"use strict";function yl(t,e,r,n,i,o,s){try{var a=t[o](s),u=a.value}catch(d){r(d);return}a.done?e(u):Promise.resolve(u).then(n,i)}function Vb(t){return function(){var e=this,r=arguments;return new Promise(function(n,i){var o=t.apply(e,r);function s(u){yl(o,n,i,s,a,"next",u)}function a(u){yl(o,n,i,s,a,"throw",u)}s(void 0)})}}function bl(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),r.push.apply(r,n)}return r}function Hb(t){for(var e=1;e<arguments.length;e++){var r=arguments[e]!=null?arguments[e]:{};e%2?bl(Object(r),!0).forEach(function(n){Wb(t,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):bl(Object(r)).forEach(function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(r,n))})}return t}function Wb(t,e,r){return e=Xb(e),e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function Xb(t){var e=Kb(t,"string");return typeof e=="symbol"?e:String(e)}function Kb(t,e){if(typeof t!="object"||t===null)return t;var r=t[Symbol.toPrimitive];if(r!==void 0){var n=r.call(t,e||"default");if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var Gb=Nt().codes.ERR_INVALID_ARG_TYPE;function Yb(t,e,r){var n;if(e&&typeof e.next=="function")n=e;else if(e&&e[Symbol.asyncIterator])n=e[Symbol.asyncIterator]();else if(e&&e[Symbol.iterator])n=e[Symbol.iterator]();else throw new Gb("iterable",["Iterable"],e);var i=new t(Hb({objectMode:!0},r)),o=!1;i._read=function(){o||(o=!0,s())};function s(){return a.apply(this,arguments)}function a(){return a=Vb(function*(){try{var u=yield n.next(),d=u.value,w=u.done;w?i.push(null):i.push(yield d)?s():o=!1}catch(E){i.destroy(E)}}),a.apply(this,arguments)}return i}wl.exports=Yb});var Nl=S((Mx,Ml)=>{"use strict";Ml.exports=W;var Rt;W.ReadableState=Tl;var Ix=require("events").EventEmitter,Sl=function(e,r){return e.listeners(r).length},cr=Eo(),En=require("buffer").Buffer,zb=(typeof global<"u"?global:typeof window<"u"?window:typeof self<"u"?self:{}).Uint8Array||function(){};function Jb(t){return En.from(t)}function Qb(t){return En.isBuffer(t)||t instanceof zb}var Lo=require("util"),U;Lo&&Lo.debuglog?U=Lo.debuglog("stream"):U=function(){};var Zb=ol(),$o=To(),e0=Oo(),t0=e0.getHighWaterMark,Sn=Nt().codes,r0=Sn.ERR_INVALID_ARG_TYPE,n0=Sn.ERR_STREAM_PUSH_AFTER_EOF,i0=Sn.ERR_METHOD_NOT_IMPLEMENTED,o0=Sn.ERR_STREAM_UNSHIFT_AFTER_END_EVENT,At,Co,qo;je()(W,cr);var fr=$o.errorOrDestroy,Fo=["error","close","destroy","pause","resume"];function s0(t,e,r){if(typeof t.prependListener=="function")return t.prependListener(e,r);!t._events||!t._events[e]?t.on(e,r):Array.isArray(t._events[e])?t._events[e].unshift(r):t._events[e]=[r,t._events[e]]}function Tl(t,e,r){Rt=Rt||hr(),t=t||{},typeof r!="boolean"&&(r=e instanceof Rt),this.objectMode=!!t.objectMode,r&&(this.objectMode=this.objectMode||!!t.readableObjectMode),this.highWaterMark=t0(this,t,"readableHighWaterMark",r),this.buffer=new Zb,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.paused=!0,this.emitClose=t.emitClose!==!1,this.autoDestroy=!!t.autoDestroy,this.destroyed=!1,this.defaultEncoding=t.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,t.encoding&&(At||(At=ur().StringDecoder),this.decoder=new At(t.encoding),this.encoding=t.encoding)}function W(t){if(Rt=Rt||hr(),!(this instanceof W))return new W(t);var e=this instanceof Rt;this._readableState=new Tl(t,this,e),this.readable=!0,t&&(typeof t.read=="function"&&(this._read=t.read),typeof t.destroy=="function"&&(this._destroy=t.destroy)),cr.call(this)}Object.defineProperty(W.prototype,"destroyed",{enumerable:!1,get:function(){return this._readableState===void 0?!1:this._readableState.destroyed},set:function(e){this._readableState&&(this._readableState.destroyed=e)}});W.prototype.destroy=$o.destroy;W.prototype._undestroy=$o.undestroy;W.prototype._destroy=function(t,e){e(t)};W.prototype.push=function(t,e){var r=this._readableState,n;return r.objectMode?n=!0:typeof t=="string"&&(e=e||r.defaultEncoding,e!==r.encoding&&(t=En.from(t,e),e=""),n=!0),Ol(this,t,e,!1,n)};W.prototype.unshift=function(t){return Ol(this,t,null,!0,!1)};function Ol(t,e,r,n,i){U("readableAddChunk",e);var o=t._readableState;if(e===null)o.reading=!1,l0(t,o);else{var s;if(i||(s=a0(o,e)),s)fr(t,s);else if(o.objectMode||e&&e.length>0)if(typeof e!="string"&&!o.objectMode&&Object.getPrototypeOf(e)!==En.prototype&&(e=Jb(e)),n)o.endEmitted?fr(t,new o0):jo(t,o,e,!0);else if(o.ended)fr(t,new n0);else{if(o.destroyed)return!1;o.reading=!1,o.decoder&&!r?(e=o.decoder.write(e),o.objectMode||e.length!==0?jo(t,o,e,!1):Bo(t,o)):jo(t,o,e,!1)}else n||(o.reading=!1,Bo(t,o))}return!o.ended&&(o.length<o.highWaterMark||o.length===0)}function jo(t,e,r,n){e.flowing&&e.length===0&&!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&&Tn(t)),Bo(t,e)}function a0(t,e){var r;return!Qb(e)&&typeof e!="string"&&e!==void 0&&!t.objectMode&&(r=new r0("chunk",["string","Buffer","Uint8Array"],e)),r}W.prototype.isPaused=function(){return this._readableState.flowing===!1};W.prototype.setEncoding=function(t){At||(At=ur().StringDecoder);var e=new At(t);this._readableState.decoder=e,this._readableState.encoding=this._readableState.decoder.encoding;for(var r=this._readableState.buffer.head,n="";r!==null;)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 vl=1073741824;function u0(t){return t>=vl?t=vl:(t--,t|=t>>>1,t|=t>>>2,t|=t>>>4,t|=t>>>8,t|=t>>>16,t++),t}function El(t,e){return t<=0||e.length===0&&e.ended?0:e.objectMode?1:t!==t?e.flowing&&e.length?e.buffer.head.data.length:e.length:(t>e.highWaterMark&&(e.highWaterMark=u0(t)),t<=e.length?t:e.ended?e.length:(e.needReadable=!0,0))}W.prototype.read=function(t){U("read",t),t=parseInt(t,10);var e=this._readableState,r=t;if(t!==0&&(e.emittedReadable=!1),t===0&&e.needReadable&&((e.highWaterMark!==0?e.length>=e.highWaterMark:e.length>0)||e.ended))return U("read: emitReadable",e.length,e.ended),e.length===0&&e.ended?ko(this):Tn(this),null;if(t=El(t,e),t===0&&e.ended)return e.length===0&&ko(this),null;var n=e.needReadable;U("need readable",n),(e.length===0||e.length-t<e.highWaterMark)&&(n=!0,U("length less than watermark",n)),e.ended||e.reading?(n=!1,U("reading or ended",n)):n&&(U("do read"),e.reading=!0,e.sync=!0,e.length===0&&(e.needReadable=!0),this._read(e.highWaterMark),e.sync=!1,e.reading||(t=El(r,e)));var i;return t>0?i=Pl(t,e):i=null,i===null?(e.needReadable=e.length<=e.highWaterMark,t=0):(e.length-=t,e.awaitDrain=0),e.length===0&&(e.ended||(e.needReadable=!0),r!==t&&e.ended&&ko(this)),i!==null&&this.emit("data",i),i};function l0(t,e){if(U("onEofChunk"),!e.ended){if(e.decoder){var r=e.decoder.end();r&&r.length&&(e.buffer.push(r),e.length+=e.objectMode?1:r.length)}e.ended=!0,e.sync?Tn(t):(e.needReadable=!1,e.emittedReadable||(e.emittedReadable=!0,Dl(t)))}}function Tn(t){var e=t._readableState;U("emitReadable",e.needReadable,e.emittedReadable),e.needReadable=!1,e.emittedReadable||(U("emitReadable",e.flowing),e.emittedReadable=!0,process.nextTick(Dl,t))}function Dl(t){var e=t._readableState;U("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,Uo(t)}function Bo(t,e){e.readingMore||(e.readingMore=!0,process.nextTick(f0,t,e))}function f0(t,e){for(;!e.reading&&!e.ended&&(e.length<e.highWaterMark||e.flowing&&e.length===0);){var r=e.length;if(U("maybeReadMore read 0"),t.read(0),r===e.length)break}e.readingMore=!1}W.prototype._read=function(t){fr(this,new i0("_read()"))};W.prototype.pipe=function(t,e){var r=this,n=this._readableState;switch(n.pipesCount){case 0:n.pipes=t;break;case 1:n.pipes=[n.pipes,t];break;default:n.pipes.push(t);break}n.pipesCount+=1,U("pipe count=%d opts=%j",n.pipesCount,e);var i=(!e||e.end!==!1)&&t!==process.stdout&&t!==process.stderr,o=i?a:v;n.endEmitted?process.nextTick(o):r.once("end",o),t.on("unpipe",s);function s(R,N){U("onunpipe"),R===r&&N&&N.hasUnpiped===!1&&(N.hasUnpiped=!0,w())}function a(){U("onend"),t.end()}var u=c0(r);t.on("drain",u);var d=!1;function w(){U("cleanup"),t.removeListener("close",g),t.removeListener("finish",h),t.removeListener("drain",u),t.removeListener("error",y),t.removeListener("unpipe",s),r.removeListener("end",a),r.removeListener("end",v),r.removeListener("data",E),d=!0,n.awaitDrain&&(!t._writableState||t._writableState.needDrain)&&u()}r.on("data",E);function E(R){U("ondata");var N=t.write(R);U("dest.write",N),N===!1&&((n.pipesCount===1&&n.pipes===t||n.pipesCount>1&&Il(n.pipes,t)!==-1)&&!d&&(U("false write response, pause",n.awaitDrain),n.awaitDrain++),r.pause())}function y(R){U("onerror",R),v(),t.removeListener("error",y),Sl(t,"error")===0&&fr(t,R)}s0(t,"error",y);function g(){t.removeListener("finish",h),v()}t.once("close",g);function h(){U("onfinish"),t.removeListener("close",g),v()}t.once("finish",h);function v(){U("unpipe"),r.unpipe(t)}return t.emit("pipe",r),n.flowing||(U("pipe resume"),r.resume()),t};function c0(t){return function(){var r=t._readableState;U("pipeOnDrain",r.awaitDrain),r.awaitDrain&&r.awaitDrain--,r.awaitDrain===0&&Sl(t,"data")&&(r.flowing=!0,Uo(t))}}W.prototype.unpipe=function(t){var e=this._readableState,r={hasUnpiped:!1};if(e.pipesCount===0)return this;if(e.pipesCount===1)return t&&t!==e.pipes?this:(t||(t=e.pipes),e.pipes=null,e.pipesCount=0,e.flowing=!1,t&&t.emit("unpipe",this,r),this);if(!t){var 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=Il(e.pipes,t);return s===-1?this:(e.pipes.splice(s,1),e.pipesCount-=1,e.pipesCount===1&&(e.pipes=e.pipes[0]),t.emit("unpipe",this,r),this)};W.prototype.on=function(t,e){var r=cr.prototype.on.call(this,t,e),n=this._readableState;return t==="data"?(n.readableListening=this.listenerCount("readable")>0,n.flowing!==!1&&this.resume()):t==="readable"&&!n.endEmitted&&!n.readableListening&&(n.readableListening=n.needReadable=!0,n.flowing=!1,n.emittedReadable=!1,U("on readable",n.length,n.reading),n.length?Tn(this):n.reading||process.nextTick(h0,this)),r};W.prototype.addListener=W.prototype.on;W.prototype.removeListener=function(t,e){var r=cr.prototype.removeListener.call(this,t,e);return t==="readable"&&process.nextTick(xl,this),r};W.prototype.removeAllListeners=function(t){var e=cr.prototype.removeAllListeners.apply(this,arguments);return(t==="readable"||t===void 0)&&process.nextTick(xl,this),e};function xl(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 h0(t){U("readable nexttick read 0"),t.read(0)}W.prototype.resume=function(){var t=this._readableState;return t.flowing||(U("resume"),t.flowing=!t.readableListening,d0(this,t)),t.paused=!1,this};function d0(t,e){e.resumeScheduled||(e.resumeScheduled=!0,process.nextTick(p0,t,e))}function p0(t,e){U("resume",e.reading),e.reading||t.read(0),e.resumeScheduled=!1,t.emit("resume"),Uo(t),e.flowing&&!e.reading&&t.read(0)}W.prototype.pause=function(){return U("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(U("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this};function Uo(t){var e=t._readableState;for(U("flow",e.flowing);e.flowing&&t.read()!==null;);}W.prototype.wrap=function(t){var e=this,r=this._readableState,n=!1;t.on("end",function(){if(U("wrapped end"),r.decoder&&!r.ended){var s=r.decoder.end();s&&s.length&&e.push(s)}e.push(null)}),t.on("data",function(s){if(U("wrapped data"),r.decoder&&(s=r.decoder.write(s)),!(r.objectMode&&s==null)&&!(!r.objectMode&&(!s||!s.length))){var a=e.push(s);a||(n=!0,t.pause())}});for(var i in t)this[i]===void 0&&typeof t[i]=="function"&&(this[i]=(function(a){return function(){return t[a].apply(t,arguments)}})(i));for(var o=0;o<Fo.length;o++)t.on(Fo[o],this.emit.bind(this,Fo[o]));return this._read=function(s){U("wrapped _read",s),n&&(n=!1,t.resume())},this};typeof Symbol=="function"&&(W.prototype[Symbol.asyncIterator]=function(){return Co===void 0&&(Co=gl()),Co(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(e){this._readableState&&(this._readableState.flowing=e)}});W._fromList=Pl;Object.defineProperty(W.prototype,"readableLength",{enumerable:!1,get:function(){return this._readableState.length}});function Pl(t,e){if(e.length===0)return null;var r;return e.objectMode?r=e.buffer.shift():!t||t>=e.length?(e.decoder?r=e.buffer.join(""):e.buffer.length===1?r=e.buffer.first():r=e.buffer.concat(e.length),e.buffer.clear()):r=e.buffer.consume(t,e.decoder),r}function ko(t){var e=t._readableState;U("endReadable",e.endEmitted),e.endEmitted||(e.ended=!0,process.nextTick(m0,e,t))}function m0(t,e){if(U("endReadableNT",t.endEmitted,t.length),!t.endEmitted&&t.length===0&&(t.endEmitted=!0,e.readable=!1,e.emit("end"),t.autoDestroy)){var r=e._writableState;(!r||r.autoDestroy&&r.finished)&&e.destroy()}}typeof Symbol=="function"&&(W.from=function(t,e){return qo===void 0&&(qo=_l()),qo(W,t,e)});function Il(t,e){for(var r=0,n=t.length;r<n;r++)if(t[r]===e)return r;return-1}});var hr=S((Nx,Al)=>{"use strict";var g0=Object.keys||function(t){var e=[];for(var r in t)e.push(r);return e};Al.exports=Me;var Rl=Nl(),Ho=Wo();je()(Me,Rl);for(Vo=g0(Ho.prototype),On=0;On<Vo.length;On++)Dn=Vo[On],Me.prototype[Dn]||(Me.prototype[Dn]=Ho.prototype[Dn]);var Vo,Dn,On;function Me(t){if(!(this instanceof Me))return new Me(t);Rl.call(this,t),Ho.call(this,t),this.allowHalfOpen=!0,t&&(t.readable===!1&&(this.readable=!1),t.writable===!1&&(this.writable=!1),t.allowHalfOpen===!1&&(this.allowHalfOpen=!1,this.once("end",y0)))}Object.defineProperty(Me.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});Object.defineProperty(Me.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}});Object.defineProperty(Me.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}});function y0(){this._writableState.ended||process.nextTick(b0,this)}function b0(t){t.end()}Object.defineProperty(Me.prototype,"destroyed",{enumerable:!1,get:function(){return this._readableState===void 0||this._writableState===void 0?!1:this._readableState.destroyed&&this._writableState.destroyed},set:function(e){this._readableState===void 0||this._writableState===void 0||(this._readableState.destroyed=e,this._writableState.destroyed=e)}})});var Wo=S((Rx,kl)=>{"use strict";kl.exports=Z;function Cl(t){var e=this;this.next=null,this.entry=null,this.finish=function(){W0(e,t)}}var Lt;Z.WritableState=pr;var w0={deprecate:vo()},ql=Eo(),Pn=require("buffer").Buffer,_0=(typeof global<"u"?global:typeof window<"u"?window:typeof self<"u"?self:{}).Uint8Array||function(){};function v0(t){return Pn.from(t)}function E0(t){return Pn.isBuffer(t)||t instanceof _0}var Ko=To(),S0=Oo(),T0=S0.getHighWaterMark,Qe=Nt().codes,O0=Qe.ERR_INVALID_ARG_TYPE,D0=Qe.ERR_METHOD_NOT_IMPLEMENTED,x0=Qe.ERR_MULTIPLE_CALLBACK,P0=Qe.ERR_STREAM_CANNOT_PIPE,I0=Qe.ERR_STREAM_DESTROYED,M0=Qe.ERR_STREAM_NULL_VALUES,N0=Qe.ERR_STREAM_WRITE_AFTER_END,R0=Qe.ERR_UNKNOWN_ENCODING,Ct=Ko.errorOrDestroy;je()(Z,ql);function A0(){}function pr(t,e,r){Lt=Lt||hr(),t=t||{},typeof r!="boolean"&&(r=e instanceof Lt),this.objectMode=!!t.objectMode,r&&(this.objectMode=this.objectMode||!!t.writableObjectMode),this.highWaterMark=T0(this,t,"writableHighWaterMark",r),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var n=t.decodeStrings===!1;this.decodeStrings=!n,this.defaultEncoding=t.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(i){B0(e,i)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=t.emitClose!==!1,this.autoDestroy=!!t.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new Cl(this)}pr.prototype.getBuffer=function(){for(var e=this.bufferedRequest,r=[];e;)r.push(e),e=e.next;return r};(function(){try{Object.defineProperty(pr.prototype,"buffer",{get:w0.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch{}})();var xn;typeof Symbol=="function"&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]=="function"?(xn=Function.prototype[Symbol.hasInstance],Object.defineProperty(Z,Symbol.hasInstance,{value:function(e){return xn.call(this,e)?!0:this!==Z?!1:e&&e._writableState instanceof pr}})):xn=function(e){return e instanceof this};function Z(t){Lt=Lt||hr();var e=this instanceof Lt;if(!e&&!xn.call(Z,this))return new Z(t);this._writableState=new pr(t,this,e),this.writable=!0,t&&(typeof t.write=="function"&&(this._write=t.write),typeof t.writev=="function"&&(this._writev=t.writev),typeof t.destroy=="function"&&(this._destroy=t.destroy),typeof t.final=="function"&&(this._final=t.final)),ql.call(this)}Z.prototype.pipe=function(){Ct(this,new P0)};function L0(t,e){var r=new N0;Ct(t,r),process.nextTick(e,r)}function C0(t,e,r,n){var i;return r===null?i=new M0:typeof r!="string"&&!e.objectMode&&(i=new O0("chunk",["string","Buffer"],r)),i?(Ct(t,i),process.nextTick(n,i),!1):!0}Z.prototype.write=function(t,e,r){var n=this._writableState,i=!1,o=!n.objectMode&&E0(t);return o&&!Pn.isBuffer(t)&&(t=v0(t)),typeof e=="function"&&(r=e,e=null),o?e="buffer":e||(e=n.defaultEncoding),typeof r!="function"&&(r=A0),n.ending?L0(this,r):(o||C0(this,n,t,r))&&(n.pendingcb++,i=F0(this,n,o,t,e,r)),i};Z.prototype.cork=function(){this._writableState.corked++};Z.prototype.uncork=function(){var t=this._writableState;t.corked&&(t.corked--,!t.writing&&!t.corked&&!t.bufferProcessing&&t.bufferedRequest&&Fl(this,t))};Z.prototype.setDefaultEncoding=function(e){if(typeof e=="string"&&(e=e.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((e+"").toLowerCase())>-1))throw new R0(e);return this._writableState.defaultEncoding=e,this};Object.defineProperty(Z.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}});function q0(t,e,r){return!t.objectMode&&t.decodeStrings!==!1&&typeof e=="string"&&(e=Pn.from(e,r)),e}Object.defineProperty(Z.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});function F0(t,e,r,n,i,o){if(!r){var s=q0(e,n,i);n!==s&&(r=!0,i="buffer",n=s)}var a=e.objectMode?1:n.length;e.length+=a;var u=e.length<e.highWaterMark;if(u||(e.needDrain=!0),e.writing||e.corked){var d=e.lastBufferedRequest;e.lastBufferedRequest={chunk:n,encoding:i,isBuf:r,callback:o,next:null},d?d.next=e.lastBufferedRequest:e.bufferedRequest=e.lastBufferedRequest,e.bufferedRequestCount+=1}else Xo(t,e,!1,a,n,i,o);return u}function Xo(t,e,r,n,i,o,s){e.writelen=n,e.writecb=s,e.writing=!0,e.sync=!0,e.destroyed?e.onwrite(new I0("write")):r?t._writev(i,e.onwrite):t._write(i,o,e.onwrite),e.sync=!1}function j0(t,e,r,n,i){--e.pendingcb,r?(process.nextTick(i,n),process.nextTick(dr,t,e),t._writableState.errorEmitted=!0,Ct(t,n)):(i(n),t._writableState.errorEmitted=!0,Ct(t,n),dr(t,e))}function k0(t){t.writing=!1,t.writecb=null,t.length-=t.writelen,t.writelen=0}function B0(t,e){var r=t._writableState,n=r.sync,i=r.writecb;if(typeof i!="function")throw new x0;if(k0(r),e)j0(t,r,n,e,i);else{var o=jl(r)||t.destroyed;!o&&!r.corked&&!r.bufferProcessing&&r.bufferedRequest&&Fl(t,r),n?process.nextTick(Ll,t,r,o,i):Ll(t,r,o,i)}}function Ll(t,e,r,n){r||$0(t,e),e.pendingcb--,n(),dr(t,e)}function $0(t,e){e.length===0&&e.needDrain&&(e.needDrain=!1,t.emit("drain"))}function Fl(t,e){e.bufferProcessing=!0;var r=e.bufferedRequest;if(t._writev&&r&&r.next){var n=e.bufferedRequestCount,i=new Array(n),o=e.corkedRequestsFree;o.entry=r;for(var s=0,a=!0;r;)i[s]=r,r.isBuf||(a=!1),r=r.next,s+=1;i.allBuffers=a,Xo(t,e,!0,e.length,i,"",o.finish),e.pendingcb++,e.lastBufferedRequest=null,o.next?(e.corkedRequestsFree=o.next,o.next=null):e.corkedRequestsFree=new Cl(e),e.bufferedRequestCount=0}else{for(;r;){var u=r.chunk,d=r.encoding,w=r.callback,E=e.objectMode?1:u.length;if(Xo(t,e,!1,E,u,d,w),r=r.next,e.bufferedRequestCount--,e.writing)break}r===null&&(e.lastBufferedRequest=null)}e.bufferedRequest=r,e.bufferProcessing=!1}Z.prototype._write=function(t,e,r){r(new D0("_write()"))};Z.prototype._writev=null;Z.prototype.end=function(t,e,r){var n=this._writableState;return typeof t=="function"?(r=t,t=null,e=null):typeof e=="function"&&(r=e,e=null),t!=null&&this.write(t,e),n.corked&&(n.corked=1,this.uncork()),n.ending||H0(this,n,r),this};Object.defineProperty(Z.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}});function jl(t){return t.ending&&t.length===0&&t.bufferedRequest===null&&!t.finished&&!t.writing}function U0(t,e){t._final(function(r){e.pendingcb--,r&&Ct(t,r),e.prefinished=!0,t.emit("prefinish"),dr(t,e)})}function V0(t,e){!e.prefinished&&!e.finalCalled&&(typeof t._final=="function"&&!e.destroyed?(e.pendingcb++,e.finalCalled=!0,process.nextTick(U0,t,e)):(e.prefinished=!0,t.emit("prefinish")))}function dr(t,e){var r=jl(e);if(r&&(V0(t,e),e.pendingcb===0&&(e.finished=!0,t.emit("finish"),e.autoDestroy))){var n=t._readableState;(!n||n.autoDestroy&&n.endEmitted)&&t.destroy()}return r}function H0(t,e,r){e.ending=!0,dr(t,e),r&&(e.finished?process.nextTick(r):t.once("finish",r)),e.ended=!0,t.writable=!1}function W0(t,e,r){var n=t.entry;for(t.entry=null;n;){var i=n.callback;e.pendingcb--,i(r),n=n.next}e.corkedRequestsFree.next=t}Object.defineProperty(Z.prototype,"destroyed",{enumerable:!1,get:function(){return this._writableState===void 0?!1:this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}});Z.prototype.destroy=Ko.destroy;Z.prototype._undestroy=Ko.undestroy;Z.prototype._destroy=function(t,e){e(t)}});var Go=S((Ax,Ul)=>{"use strict";var X0=require("util"),Bl=Wo(),{LEVEL:$l}=ne(),mr=Ul.exports=function(e={}){Bl.call(this,{objectMode:!0,highWaterMark:e.highWaterMark}),this.format=e.format,this.level=e.level,this.handleExceptions=e.handleExceptions,this.handleRejections=e.handleRejections,this.silent=e.silent,e.log&&(this.log=e.log),e.logv&&(this.logv=e.logv),e.close&&(this.close=e.close),this.once("pipe",r=>{this.levels=r.levels,this.parent=r}),this.once("unpipe",r=>{r===this.parent&&(this.parent=null,this.close&&this.close())})};X0.inherits(mr,Bl);mr.prototype._write=function(e,r,n){if(this.silent||e.exception===!0&&!this.handleExceptions)return n(null);let i=this.level||this.parent&&this.parent.level;if(!i||this.levels[i]>=this.levels[e[$l]]){if(e&&!this.format)return this.log(e,n);let o,s;try{s=this.format.transform(Object.assign({},e),this.format.options)}catch(a){o=a}if(o||!s){if(n(),o)throw o;return}return this.log(s,n)}return this._writableState.sync=!1,n(null)};mr.prototype._writev=function(e,r){if(this.logv){let n=e.filter(this._accept,this);return n.length?this.logv(n,r):r(null)}for(let n=0;n<e.length;n++){if(!this._accept(e[n]))continue;if(e[n].chunk&&!this.format){this.log(e[n].chunk,e[n].callback);continue}let i,o;try{o=this.format.transform(Object.assign({},e[n].chunk),this.format.options)}catch(s){i=s}if(i||!o){if(e[n].callback(),i)throw r(null),i}else this.log(o,e[n].callback)}return r(null)};mr.prototype._accept=function(e){let r=e.chunk;if(this.silent)return!1;let n=this.level||this.parent&&this.parent.level;return!!((r.exception===!0||!n||this.levels[n]>=this.levels[r[$l]])&&(this.handleExceptions||r.exception!==!0))};mr.prototype._nop=function(){}});var zo=S((Lx,Hl)=>{"use strict";var K0=require("util"),{LEVEL:Yo}=ne(),Vl=Go(),gr=Hl.exports=function(e={}){if(Vl.call(this,e),!e.transport||typeof e.transport.log!="function")throw new Error("Invalid transport, must be an object with a log method.");this.transport=e.transport,this.level=this.level||e.transport.level,this.handleExceptions=this.handleExceptions||e.transport.handleExceptions,this._deprecated();function r(n){this.emit("error",n,this.transport)}this.transport.__winstonError||(this.transport.__winstonError=r.bind(this),this.transport.on("error",this.transport.__winstonError))};K0.inherits(gr,Vl);gr.prototype._write=function(e,r,n){if(this.silent||e.exception===!0&&!this.handleExceptions)return n(null);(!this.level||this.levels[this.level]>=this.levels[e[Yo]])&&this.transport.log(e[Yo],e.message,e,this._nop),n(null)};gr.prototype._writev=function(e,r){for(let n=0;n<e.length;n++)this._accept(e[n])&&(this.transport.log(e[n].chunk[Yo],e[n].chunk.message,e[n].chunk,this._nop),e[n].callback());return r(null)};gr.prototype._deprecated=function(){console.error([`${this.transport.name} is a legacy winston transport. Consider upgrading: `,"- Upgrade docs: https://github.com/winstonjs/winston/blob/master/UPGRADE-3.0.md"].join(`
|
|
26
|
-
`))};gr.prototype.close=function(){this.transport.close&&this.transport.close(),this.transport.__winstonError&&(this.transport.removeListener("error",this.transport.__winstonError),this.transport.__winstonError=null)}});var qt=S((Cx,Jo)=>{"use strict";Jo.exports=Go();Jo.exports.LegacyTransportStream=zo()});var Kl=S((Fx,Xl)=>{"use strict";var G0=require("os"),{LEVEL:Wl,MESSAGE:Ft}=ne(),Y0=qt();Xl.exports=class extends Y0{constructor(e={}){super(e),this.name=e.name||"console",this.stderrLevels=this._stringArrayToSet(e.stderrLevels),this.consoleWarnLevels=this._stringArrayToSet(e.consoleWarnLevels),this.eol=typeof e.eol=="string"?e.eol:G0.EOL,this.forceConsole=e.forceConsole||!1,this._consoleLog=console.log.bind(console),this._consoleWarn=console.warn.bind(console),this._consoleError=console.error.bind(console),this.setMaxListeners(30)}log(e,r){if(setImmediate(()=>this.emit("logged",e)),this.stderrLevels[e[Wl]]){console._stderr&&!this.forceConsole?console._stderr.write(`${e[Ft]}${this.eol}`):this._consoleError(e[Ft]),r&&r();return}else if(this.consoleWarnLevels[e[Wl]]){console._stderr&&!this.forceConsole?console._stderr.write(`${e[Ft]}${this.eol}`):this._consoleWarn(e[Ft]),r&&r();return}console._stdout&&!this.forceConsole?console._stdout.write(`${e[Ft]}${this.eol}`):this._consoleLog(e[Ft]),r&&r()}_stringArrayToSet(e,r){if(!e)return{};if(r=r||"Cannot make set from type other than Array of string elements",!Array.isArray(e))throw new Error(r);return e.reduce((n,i)=>{if(typeof i!="string")throw new Error(r);return n[i]=!0,n},{})}}});var Mn=S((In,Gl)=>{"use strict";Object.defineProperty(In,"__esModule",{value:!0});In.default=z0;function z0(t){return t&&typeof t.length=="number"&&t.length>=0&&t.length%1===0}Gl.exports=In.default});var zl=S((Nn,Yl)=>{"use strict";Object.defineProperty(Nn,"__esModule",{value:!0});Nn.default=function(t){return function(...e){var r=e.pop();return t.call(this,e,r)}};Yl.exports=Nn.default});var Zl=S(Ze=>{"use strict";Object.defineProperty(Ze,"__esModule",{value:!0});Ze.fallback=Jl;Ze.wrap=Ql;var J0=Ze.hasQueueMicrotask=typeof queueMicrotask=="function"&&queueMicrotask,Q0=Ze.hasSetImmediate=typeof setImmediate=="function"&&setImmediate,Z0=Ze.hasNextTick=typeof process=="object"&&typeof process.nextTick=="function";function Jl(t){setTimeout(t,0)}function Ql(t){return(e,...r)=>t(()=>e(...r))}var yr;J0?yr=queueMicrotask:Q0?yr=setImmediate:Z0?yr=process.nextTick:yr=Jl;Ze.default=Ql(yr)});var of=S((Rn,nf)=>{"use strict";Object.defineProperty(Rn,"__esModule",{value:!0});Rn.default=ow;var ew=zl(),tw=rf(ew),rw=Zl(),nw=rf(rw),iw=yt();function rf(t){return t&&t.__esModule?t:{default:t}}function ow(t){return(0,iw.isAsync)(t)?function(...e){let r=e.pop(),n=t.apply(this,e);return ef(n,r)}:(0,tw.default)(function(e,r){var n;try{n=t.apply(this,e)}catch(i){return r(i)}if(n&&typeof n.then=="function")return ef(n,r);r(null,n)})}function ef(t,e){return t.then(r=>{tf(e,null,r)},r=>{tf(e,r&&(r instanceof Error||r.message)?r:new Error(r))})}function tf(t,e,r){try{t(e,r)}catch(n){(0,nw.default)(i=>{throw i},n)}}nf.exports=Rn.default});var yt=S(ke=>{"use strict";Object.defineProperty(ke,"__esModule",{value:!0});ke.isAsyncIterable=ke.isAsyncGenerator=ke.isAsync=void 0;var sw=of(),aw=uw(sw);function uw(t){return t&&t.__esModule?t:{default:t}}function sf(t){return t[Symbol.toStringTag]==="AsyncFunction"}function lw(t){return t[Symbol.toStringTag]==="AsyncGenerator"}function fw(t){return typeof t[Symbol.asyncIterator]=="function"}function cw(t){if(typeof t!="function")throw new Error("expected a function");return sf(t)?(0,aw.default)(t):t}ke.default=cw;ke.isAsync=sf;ke.isAsyncGenerator=lw;ke.isAsyncIterable=fw});var jt=S((An,af)=>{"use strict";Object.defineProperty(An,"__esModule",{value:!0});An.default=hw;function hw(t,e){if(e||(e=t.length),!e)throw new Error("arity is undefined");function r(...n){return typeof n[e-1]=="function"?t.apply(this,n):new Promise((i,o)=>{n[e-1]=(s,...a)=>{if(s)return o(s);i(a.length>1?a:a[0])},t.apply(this,n)})}return r}af.exports=An.default});var lf=S((Ln,uf)=>{"use strict";Object.defineProperty(Ln,"__esModule",{value:!0});var dw=Mn(),pw=Qo(dw),mw=yt(),gw=Qo(mw),yw=jt(),bw=Qo(yw);function Qo(t){return t&&t.__esModule?t:{default:t}}Ln.default=(0,bw.default)((t,e,r)=>{var n=(0,pw.default)(e)?[]:{};t(e,(i,o,s)=>{(0,gw.default)(i)((a,...u)=>{u.length<2&&([u]=u),n[o]=u,s(a)})},i=>r(i,n))},3);uf.exports=Ln.default});var Zo=S((Cn,ff)=>{"use strict";Object.defineProperty(Cn,"__esModule",{value:!0});Cn.default=ww;function ww(t){function e(...r){if(t!==null){var n=t;t=null,n.apply(this,r)}}return Object.assign(e,t),e}ff.exports=Cn.default});var hf=S((qn,cf)=>{"use strict";Object.defineProperty(qn,"__esModule",{value:!0});qn.default=function(t){return t[Symbol.iterator]&&t[Symbol.iterator]()};cf.exports=qn.default});var mf=S((Fn,pf)=>{"use strict";Object.defineProperty(Fn,"__esModule",{value:!0});Fn.default=xw;var _w=Mn(),vw=df(_w),Ew=hf(),Sw=df(Ew);function df(t){return t&&t.__esModule?t:{default:t}}function Tw(t){var e=-1,r=t.length;return function(){return++e<r?{value:t[e],key:e}:null}}function Ow(t){var e=-1;return function(){var n=t.next();return n.done?null:(e++,{value:n.value,key:e})}}function Dw(t){var e=t?Object.keys(t):[],r=-1,n=e.length;return function i(){var o=e[++r];return o==="__proto__"?i():r<n?{value:t[o],key:o}:null}}function xw(t){if((0,vw.default)(t))return Tw(t);var e=(0,Sw.default)(t);return e?Ow(e):Dw(t)}pf.exports=Fn.default});var es=S((jn,gf)=>{"use strict";Object.defineProperty(jn,"__esModule",{value:!0});jn.default=Pw;function Pw(t){return function(...e){if(t===null)throw new Error("Callback was already called.");var r=t;t=null,r.apply(this,e)}}gf.exports=jn.default});var Bn=S((kn,yf)=>{"use strict";Object.defineProperty(kn,"__esModule",{value:!0});var Iw={};kn.default=Iw;yf.exports=kn.default});var wf=S(($n,bf)=>{"use strict";Object.defineProperty($n,"__esModule",{value:!0});$n.default=Aw;var Mw=Bn(),Nw=Rw(Mw);function Rw(t){return t&&t.__esModule?t:{default:t}}function Aw(t,e,r,n){let i=!1,o=!1,s=!1,a=0,u=0;function d(){a>=e||s||i||(s=!0,t.next().then(({value:y,done:g})=>{if(!(o||i)){if(s=!1,g){i=!0,a<=0&&n(null);return}a++,r(y,u,w),u++,d()}}).catch(E))}function w(y,g){if(a-=1,!o){if(y)return E(y);if(y===!1){i=!0,o=!0;return}if(g===Nw.default||i&&a<=0)return i=!0,n(null);d()}}function E(y){o||(s=!1,i=!0,n(y))}d()}bf.exports=$n.default});var Sf=S((Un,Ef)=>{"use strict";Object.defineProperty(Un,"__esModule",{value:!0});var Lw=Zo(),Cw=br(Lw),qw=mf(),Fw=br(qw),jw=es(),kw=br(jw),_f=yt(),Bw=wf(),vf=br(Bw),$w=Bn(),Uw=br($w);function br(t){return t&&t.__esModule?t:{default:t}}Un.default=t=>(e,r,n)=>{if(n=(0,Cw.default)(n),t<=0)throw new RangeError("concurrency limit cannot be less than 1");if(!e)return n(null);if((0,_f.isAsyncGenerator)(e))return(0,vf.default)(e,t,r,n);if((0,_f.isAsyncIterable)(e))return(0,vf.default)(e[Symbol.asyncIterator](),t,r,n);var i=(0,Fw.default)(e),o=!1,s=!1,a=0,u=!1;function d(E,y){if(!s)if(a-=1,E)o=!0,n(E);else if(E===!1)o=!0,s=!0;else{if(y===Uw.default||o&&a<=0)return o=!0,n(null);u||w()}}function w(){for(u=!0;a<t&&!o;){var E=i();if(E===null){o=!0,a<=0&&n(null);return}a+=1,r(E.value,E.key,(0,kw.default)(d))}u=!1}w()};Ef.exports=Un.default});var rs=S((Vn,Tf)=>{"use strict";Object.defineProperty(Vn,"__esModule",{value:!0});var Vw=Sf(),Hw=ts(Vw),Ww=yt(),Xw=ts(Ww),Kw=jt(),Gw=ts(Kw);function ts(t){return t&&t.__esModule?t:{default:t}}function Yw(t,e,r,n){return(0,Hw.default)(e)(t,(0,Xw.default)(r),n)}Vn.default=(0,Gw.default)(Yw,4);Tf.exports=Vn.default});var xf=S((Hn,Df)=>{"use strict";Object.defineProperty(Hn,"__esModule",{value:!0});var zw=rs(),Jw=Of(zw),Qw=jt(),Zw=Of(Qw);function Of(t){return t&&t.__esModule?t:{default:t}}function e_(t,e,r){return(0,Jw.default)(t,1,e,r)}Hn.default=(0,Zw.default)(e_,3);Df.exports=Hn.default});var Mf=S((Wn,If)=>{"use strict";Object.defineProperty(Wn,"__esModule",{value:!0});Wn.default=o_;var t_=lf(),r_=Pf(t_),n_=xf(),i_=Pf(n_);function Pf(t){return t&&t.__esModule?t:{default:t}}function o_(t,e){return(0,r_.default)(i_.default,t,e)}If.exports=Wn.default});var ns=S((Bx,Nf)=>{"use strict";Nf.exports=require("stream")});var Ff=S(($x,qf)=>{"use strict";function Rf(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),r.push.apply(r,n)}return r}function Af(t){for(var e=1;e<arguments.length;e++){var r=arguments[e]!=null?arguments[e]:{};e%2?Rf(Object(r),!0).forEach(function(n){s_(t,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):Rf(Object(r)).forEach(function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(r,n))})}return t}function s_(t,e,r){return e=Cf(e),e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function a_(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function Lf(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,Cf(n.key),n)}}function u_(t,e,r){return e&&Lf(t.prototype,e),r&&Lf(t,r),Object.defineProperty(t,"prototype",{writable:!1}),t}function Cf(t){var e=l_(t,"string");return typeof e=="symbol"?e:String(e)}function l_(t,e){if(typeof t!="object"||t===null)return t;var r=t[Symbol.toPrimitive];if(r!==void 0){var n=r.call(t,e||"default");if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var f_=require("buffer"),Xn=f_.Buffer,c_=require("util"),is=c_.inspect,h_=is&&is.custom||"inspect";function d_(t,e,r){Xn.prototype.copy.call(t,e,r)}qf.exports=(function(){function t(){a_(this,t),this.head=null,this.tail=null,this.length=0}return u_(t,[{key:"push",value:function(r){var n={data:r,next:null};this.length>0?this.tail.next=n:this.head=n,this.tail=n,++this.length}},{key:"unshift",value:function(r){var n={data:r,next:this.head};this.length===0&&(this.tail=n),this.head=n,++this.length}},{key:"shift",value:function(){if(this.length!==0){var r=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,r}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(r){if(this.length===0)return"";for(var n=this.head,i=""+n.data;n=n.next;)i+=r+n.data;return i}},{key:"concat",value:function(r){if(this.length===0)return Xn.alloc(0);for(var n=Xn.allocUnsafe(r>>>0),i=this.head,o=0;i;)d_(i.data,n,o),o+=i.data.length,i=i.next;return n}},{key:"consume",value:function(r,n){var i;return r<this.head.data.length?(i=this.head.data.slice(0,r),this.head.data=this.head.data.slice(r)):r===this.head.data.length?i=this.shift():i=n?this._getString(r):this._getBuffer(r),i}},{key:"first",value:function(){return this.head.data}},{key:"_getString",value:function(r){var n=this.head,i=1,o=n.data;for(r-=o.length;n=n.next;){var s=n.data,a=r>s.length?s.length:r;if(a===s.length?o+=s:o+=s.slice(0,r),r-=a,r===0){a===s.length?(++i,n.next?this.head=n.next:this.head=this.tail=null):(this.head=n,n.data=s.slice(a));break}++i}return this.length-=i,o}},{key:"_getBuffer",value:function(r){var n=Xn.allocUnsafe(r),i=this.head,o=1;for(i.data.copy(n),r-=i.data.length;i=i.next;){var s=i.data,a=r>s.length?s.length:r;if(s.copy(n,n.length-r,0,a),r-=a,r===0){a===s.length?(++o,i.next?this.head=i.next:this.head=this.tail=null):(this.head=i,i.data=s.slice(a));break}++o}return this.length-=o,n}},{key:h_,value:function(r,n){return is(this,Af(Af({},n),{},{depth:0,customInspect:!1}))}}]),t})()});var ss=S((Ux,kf)=>{"use strict";function p_(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(os,this,t)):process.nextTick(os,this,t)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(t||null,function(o){!e&&o?r._writableState?r._writableState.errorEmitted?process.nextTick(Kn,r):(r._writableState.errorEmitted=!0,process.nextTick(jf,r,o)):process.nextTick(jf,r,o):e?(process.nextTick(Kn,r),e(o)):process.nextTick(Kn,r)}),this)}function jf(t,e){os(t,e),Kn(t)}function Kn(t){t._writableState&&!t._writableState.emitClose||t._readableState&&!t._readableState.emitClose||t.emit("close")}function m_(){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 os(t,e){t.emit("error",e)}function g_(t,e){var r=t._readableState,n=t._writableState;r&&r.autoDestroy||n&&n.autoDestroy?t.destroy(e):t.emit("error",e)}kf.exports={destroy:p_,undestroy:m_,errorOrDestroy:g_}});var et=S((Vx,Uf)=>{"use strict";var $f={};function Ee(t,e,r){r||(r=Error);function n(o,s,a){return typeof e=="string"?e:e(o,s,a)}class i extends r{constructor(s,a,u){super(n(s,a,u))}}i.prototype.name=r.name,i.prototype.code=t,$f[t]=i}function Bf(t,e){if(Array.isArray(t)){let r=t.length;return t=t.map(n=>String(n)),r>2?`one of ${e} ${t.slice(0,r-1).join(", ")}, or `+t[r-1]:r===2?`one of ${e} ${t[0]} or ${t[1]}`:`of ${e} ${t[0]}`}else return`of ${e} ${String(t)}`}function y_(t,e,r){return t.substr(!r||r<0?0:+r,e.length)===e}function b_(t,e,r){return(r===void 0||r>t.length)&&(r=t.length),t.substring(r-e.length,r)===e}function w_(t,e,r){return typeof r!="number"&&(r=0),r+e.length>t.length?!1:t.indexOf(e,r)!==-1}Ee("ERR_INVALID_OPT_VALUE",function(t,e){return'The value "'+e+'" is invalid for option "'+t+'"'},TypeError);Ee("ERR_INVALID_ARG_TYPE",function(t,e,r){let n;typeof e=="string"&&y_(e,"not ")?(n="must not be",e=e.replace(/^not /,"")):n="must be";let i;if(b_(t," argument"))i=`The ${t} ${n} ${Bf(e,"type")}`;else{let o=w_(t,".")?"property":"argument";i=`The "${t}" ${o} ${n} ${Bf(e,"type")}`}return i+=`. Received type ${typeof r}`,i},TypeError);Ee("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF");Ee("ERR_METHOD_NOT_IMPLEMENTED",function(t){return"The "+t+" method is not implemented"});Ee("ERR_STREAM_PREMATURE_CLOSE","Premature close");Ee("ERR_STREAM_DESTROYED",function(t){return"Cannot call "+t+" after a stream was destroyed"});Ee("ERR_MULTIPLE_CALLBACK","Callback called multiple times");Ee("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable");Ee("ERR_STREAM_WRITE_AFTER_END","write after end");Ee("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError);Ee("ERR_UNKNOWN_ENCODING",function(t){return"Unknown encoding: "+t},TypeError);Ee("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event");Uf.exports.codes=$f});var as=S((Hx,Vf)=>{"use strict";var __=et().codes.ERR_INVALID_OPT_VALUE;function v_(t,e,r){return t.highWaterMark!=null?t.highWaterMark:e?t[r]:null}function E_(t,e,r,n){var i=v_(e,n,r);if(i!=null){if(!(isFinite(i)&&Math.floor(i)===i)||i<0){var o=n?r:"highWaterMark";throw new __(o,i)}return Math.floor(i)}return t.objectMode?16:16*1024}Vf.exports={getHighWaterMark:E_}});var fs=S((Wx,Yf)=>{"use strict";Yf.exports=ee;function Wf(t){var e=this;this.next=null,this.entry=null,this.finish=function(){Y_(e,t)}}var kt;ee.WritableState=_r;var S_={deprecate:vo()},Xf=ns(),Yn=require("buffer").Buffer,T_=(typeof global<"u"?global:typeof window<"u"?window:typeof self<"u"?self:{}).Uint8Array||function(){};function O_(t){return Yn.from(t)}function D_(t){return Yn.isBuffer(t)||t instanceof T_}var ls=ss(),x_=as(),P_=x_.getHighWaterMark,tt=et().codes,I_=tt.ERR_INVALID_ARG_TYPE,M_=tt.ERR_METHOD_NOT_IMPLEMENTED,N_=tt.ERR_MULTIPLE_CALLBACK,R_=tt.ERR_STREAM_CANNOT_PIPE,A_=tt.ERR_STREAM_DESTROYED,L_=tt.ERR_STREAM_NULL_VALUES,C_=tt.ERR_STREAM_WRITE_AFTER_END,q_=tt.ERR_UNKNOWN_ENCODING,Bt=ls.errorOrDestroy;je()(ee,Xf);function F_(){}function _r(t,e,r){kt=kt||bt(),t=t||{},typeof r!="boolean"&&(r=e instanceof kt),this.objectMode=!!t.objectMode,r&&(this.objectMode=this.objectMode||!!t.writableObjectMode),this.highWaterMark=P_(this,t,"writableHighWaterMark",r),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var n=t.decodeStrings===!1;this.decodeStrings=!n,this.defaultEncoding=t.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(i){H_(e,i)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=t.emitClose!==!1,this.autoDestroy=!!t.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new Wf(this)}_r.prototype.getBuffer=function(){for(var e=this.bufferedRequest,r=[];e;)r.push(e),e=e.next;return r};(function(){try{Object.defineProperty(_r.prototype,"buffer",{get:S_.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch{}})();var Gn;typeof Symbol=="function"&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]=="function"?(Gn=Function.prototype[Symbol.hasInstance],Object.defineProperty(ee,Symbol.hasInstance,{value:function(e){return Gn.call(this,e)?!0:this!==ee?!1:e&&e._writableState instanceof _r}})):Gn=function(e){return e instanceof this};function ee(t){kt=kt||bt();var e=this instanceof kt;if(!e&&!Gn.call(ee,this))return new ee(t);this._writableState=new _r(t,this,e),this.writable=!0,t&&(typeof t.write=="function"&&(this._write=t.write),typeof t.writev=="function"&&(this._writev=t.writev),typeof t.destroy=="function"&&(this._destroy=t.destroy),typeof t.final=="function"&&(this._final=t.final)),Xf.call(this)}ee.prototype.pipe=function(){Bt(this,new R_)};function j_(t,e){var r=new C_;Bt(t,r),process.nextTick(e,r)}function k_(t,e,r,n){var i;return r===null?i=new L_:typeof r!="string"&&!e.objectMode&&(i=new I_("chunk",["string","Buffer"],r)),i?(Bt(t,i),process.nextTick(n,i),!1):!0}ee.prototype.write=function(t,e,r){var n=this._writableState,i=!1,o=!n.objectMode&&D_(t);return o&&!Yn.isBuffer(t)&&(t=O_(t)),typeof e=="function"&&(r=e,e=null),o?e="buffer":e||(e=n.defaultEncoding),typeof r!="function"&&(r=F_),n.ending?j_(this,r):(o||k_(this,n,t,r))&&(n.pendingcb++,i=$_(this,n,o,t,e,r)),i};ee.prototype.cork=function(){this._writableState.corked++};ee.prototype.uncork=function(){var t=this._writableState;t.corked&&(t.corked--,!t.writing&&!t.corked&&!t.bufferProcessing&&t.bufferedRequest&&Kf(this,t))};ee.prototype.setDefaultEncoding=function(e){if(typeof e=="string"&&(e=e.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((e+"").toLowerCase())>-1))throw new q_(e);return this._writableState.defaultEncoding=e,this};Object.defineProperty(ee.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}});function B_(t,e,r){return!t.objectMode&&t.decodeStrings!==!1&&typeof e=="string"&&(e=Yn.from(e,r)),e}Object.defineProperty(ee.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});function $_(t,e,r,n,i,o){if(!r){var s=B_(e,n,i);n!==s&&(r=!0,i="buffer",n=s)}var a=e.objectMode?1:n.length;e.length+=a;var u=e.length<e.highWaterMark;if(u||(e.needDrain=!0),e.writing||e.corked){var d=e.lastBufferedRequest;e.lastBufferedRequest={chunk:n,encoding:i,isBuf:r,callback:o,next:null},d?d.next=e.lastBufferedRequest:e.bufferedRequest=e.lastBufferedRequest,e.bufferedRequestCount+=1}else us(t,e,!1,a,n,i,o);return u}function us(t,e,r,n,i,o,s){e.writelen=n,e.writecb=s,e.writing=!0,e.sync=!0,e.destroyed?e.onwrite(new A_("write")):r?t._writev(i,e.onwrite):t._write(i,o,e.onwrite),e.sync=!1}function U_(t,e,r,n,i){--e.pendingcb,r?(process.nextTick(i,n),process.nextTick(wr,t,e),t._writableState.errorEmitted=!0,Bt(t,n)):(i(n),t._writableState.errorEmitted=!0,Bt(t,n),wr(t,e))}function V_(t){t.writing=!1,t.writecb=null,t.length-=t.writelen,t.writelen=0}function H_(t,e){var r=t._writableState,n=r.sync,i=r.writecb;if(typeof i!="function")throw new N_;if(V_(r),e)U_(t,r,n,e,i);else{var o=Gf(r)||t.destroyed;!o&&!r.corked&&!r.bufferProcessing&&r.bufferedRequest&&Kf(t,r),n?process.nextTick(Hf,t,r,o,i):Hf(t,r,o,i)}}function Hf(t,e,r,n){r||W_(t,e),e.pendingcb--,n(),wr(t,e)}function W_(t,e){e.length===0&&e.needDrain&&(e.needDrain=!1,t.emit("drain"))}function Kf(t,e){e.bufferProcessing=!0;var r=e.bufferedRequest;if(t._writev&&r&&r.next){var n=e.bufferedRequestCount,i=new Array(n),o=e.corkedRequestsFree;o.entry=r;for(var s=0,a=!0;r;)i[s]=r,r.isBuf||(a=!1),r=r.next,s+=1;i.allBuffers=a,us(t,e,!0,e.length,i,"",o.finish),e.pendingcb++,e.lastBufferedRequest=null,o.next?(e.corkedRequestsFree=o.next,o.next=null):e.corkedRequestsFree=new Wf(e),e.bufferedRequestCount=0}else{for(;r;){var u=r.chunk,d=r.encoding,w=r.callback,E=e.objectMode?1:u.length;if(us(t,e,!1,E,u,d,w),r=r.next,e.bufferedRequestCount--,e.writing)break}r===null&&(e.lastBufferedRequest=null)}e.bufferedRequest=r,e.bufferProcessing=!1}ee.prototype._write=function(t,e,r){r(new M_("_write()"))};ee.prototype._writev=null;ee.prototype.end=function(t,e,r){var n=this._writableState;return typeof t=="function"?(r=t,t=null,e=null):typeof e=="function"&&(r=e,e=null),t!=null&&this.write(t,e),n.corked&&(n.corked=1,this.uncork()),n.ending||G_(this,n,r),this};Object.defineProperty(ee.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}});function Gf(t){return t.ending&&t.length===0&&t.bufferedRequest===null&&!t.finished&&!t.writing}function X_(t,e){t._final(function(r){e.pendingcb--,r&&Bt(t,r),e.prefinished=!0,t.emit("prefinish"),wr(t,e)})}function K_(t,e){!e.prefinished&&!e.finalCalled&&(typeof t._final=="function"&&!e.destroyed?(e.pendingcb++,e.finalCalled=!0,process.nextTick(X_,t,e)):(e.prefinished=!0,t.emit("prefinish")))}function wr(t,e){var r=Gf(e);if(r&&(K_(t,e),e.pendingcb===0&&(e.finished=!0,t.emit("finish"),e.autoDestroy))){var n=t._readableState;(!n||n.autoDestroy&&n.endEmitted)&&t.destroy()}return r}function G_(t,e,r){e.ending=!0,wr(t,e),r&&(e.finished?process.nextTick(r):t.once("finish",r)),e.ended=!0,t.writable=!1}function Y_(t,e,r){var n=t.entry;for(t.entry=null;n;){var i=n.callback;e.pendingcb--,i(r),n=n.next}e.corkedRequestsFree.next=t}Object.defineProperty(ee.prototype,"destroyed",{enumerable:!1,get:function(){return this._writableState===void 0?!1:this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}});ee.prototype.destroy=ls.destroy;ee.prototype._undestroy=ls.undestroy;ee.prototype._destroy=function(t,e){e(t)}});var bt=S((Xx,Jf)=>{"use strict";var z_=Object.keys||function(t){var e=[];for(var r in t)e.push(r);return e};Jf.exports=Ne;var zf=ds(),hs=fs();je()(Ne,zf);for(cs=z_(hs.prototype),zn=0;zn<cs.length;zn++)Jn=cs[zn],Ne.prototype[Jn]||(Ne.prototype[Jn]=hs.prototype[Jn]);var cs,Jn,zn;function Ne(t){if(!(this instanceof Ne))return new Ne(t);zf.call(this,t),hs.call(this,t),this.allowHalfOpen=!0,t&&(t.readable===!1&&(this.readable=!1),t.writable===!1&&(this.writable=!1),t.allowHalfOpen===!1&&(this.allowHalfOpen=!1,this.once("end",J_)))}Object.defineProperty(Ne.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});Object.defineProperty(Ne.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}});Object.defineProperty(Ne.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}});function J_(){this._writableState.ended||process.nextTick(Q_,this)}function Q_(t){t.end()}Object.defineProperty(Ne.prototype,"destroyed",{enumerable:!1,get:function(){return this._readableState===void 0||this._writableState===void 0?!1:this._readableState.destroyed&&this._writableState.destroyed},set:function(e){this._readableState===void 0||this._writableState===void 0||(this._readableState.destroyed=e,this._writableState.destroyed=e)}})});var Qn=S((Kx,ec)=>{"use strict";var Qf=et().codes.ERR_STREAM_PREMATURE_CLOSE;function Z_(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)}}}function ev(){}function tv(t){return t.setHeader&&typeof t.abort=="function"}function Zf(t,e,r){if(typeof e=="function")return Zf(t,null,e);e||(e={}),r=Z_(r||ev);var n=e.readable||e.readable!==!1&&t.readable,i=e.writable||e.writable!==!1&&t.writable,o=function(){t.writable||a()},s=t._writableState&&t._writableState.finished,a=function(){i=!1,s=!0,n||r.call(t)},u=t._readableState&&t._readableState.endEmitted,d=function(){n=!1,u=!0,i||r.call(t)},w=function(h){r.call(t,h)},E=function(){var h;if(n&&!u)return(!t._readableState||!t._readableState.ended)&&(h=new Qf),r.call(t,h);if(i&&!s)return(!t._writableState||!t._writableState.ended)&&(h=new Qf),r.call(t,h)},y=function(){t.req.on("finish",a)};return tv(t)?(t.on("complete",a),t.on("abort",E),t.req?y():t.on("request",y)):i&&!t._writableState&&(t.on("end",o),t.on("close",o)),t.on("end",d),t.on("finish",a),e.error!==!1&&t.on("error",w),t.on("close",E),function(){t.removeListener("complete",a),t.removeListener("abort",E),t.removeListener("request",y),t.req&&t.req.removeListener("finish",a),t.removeListener("end",o),t.removeListener("close",o),t.removeListener("finish",a),t.removeListener("end",d),t.removeListener("error",w),t.removeListener("close",E)}}ec.exports=Zf});var rc=S((Gx,tc)=>{"use strict";var Zn;function rt(t,e,r){return e=rv(e),e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function rv(t){var e=nv(t,"string");return typeof e=="symbol"?e:String(e)}function nv(t,e){if(typeof t!="object"||t===null)return t;var r=t[Symbol.toPrimitive];if(r!==void 0){var n=r.call(t,e||"default");if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var iv=Qn(),nt=Symbol("lastResolve"),wt=Symbol("lastReject"),vr=Symbol("error"),ei=Symbol("ended"),_t=Symbol("lastPromise"),ps=Symbol("handlePromise"),vt=Symbol("stream");function it(t,e){return{value:t,done:e}}function ov(t){var e=t[nt];if(e!==null){var r=t[vt].read();r!==null&&(t[_t]=null,t[nt]=null,t[wt]=null,e(it(r,!1)))}}function sv(t){process.nextTick(ov,t)}function av(t,e){return function(r,n){t.then(function(){if(e[ei]){r(it(void 0,!0));return}e[ps](r,n)},n)}}var uv=Object.getPrototypeOf(function(){}),lv=Object.setPrototypeOf((Zn={get stream(){return this[vt]},next:function(){var e=this,r=this[vr];if(r!==null)return Promise.reject(r);if(this[ei])return Promise.resolve(it(void 0,!0));if(this[vt].destroyed)return new Promise(function(s,a){process.nextTick(function(){e[vr]?a(e[vr]):s(it(void 0,!0))})});var n=this[_t],i;if(n)i=new Promise(av(n,this));else{var o=this[vt].read();if(o!==null)return Promise.resolve(it(o,!1));i=new Promise(this[ps])}return this[_t]=i,i}},rt(Zn,Symbol.asyncIterator,function(){return this}),rt(Zn,"return",function(){var e=this;return new Promise(function(r,n){e[vt].destroy(null,function(i){if(i){n(i);return}r(it(void 0,!0))})})}),Zn),uv),fv=function(e){var r,n=Object.create(lv,(r={},rt(r,vt,{value:e,writable:!0}),rt(r,nt,{value:null,writable:!0}),rt(r,wt,{value:null,writable:!0}),rt(r,vr,{value:null,writable:!0}),rt(r,ei,{value:e._readableState.endEmitted,writable:!0}),rt(r,ps,{value:function(o,s){var a=n[vt].read();a?(n[_t]=null,n[nt]=null,n[wt]=null,o(it(a,!1))):(n[nt]=o,n[wt]=s)},writable:!0}),r));return n[_t]=null,iv(e,function(i){if(i&&i.code!=="ERR_STREAM_PREMATURE_CLOSE"){var o=n[wt];o!==null&&(n[_t]=null,n[nt]=null,n[wt]=null,o(i)),n[vr]=i;return}var s=n[nt];s!==null&&(n[_t]=null,n[nt]=null,n[wt]=null,s(it(void 0,!0))),n[ei]=!0}),e.on("readable",sv.bind(null,n)),n};tc.exports=fv});var sc=S((Yx,oc)=>{"use strict";function nc(t,e,r,n,i,o,s){try{var a=t[o](s),u=a.value}catch(d){r(d);return}a.done?e(u):Promise.resolve(u).then(n,i)}function cv(t){return function(){var e=this,r=arguments;return new Promise(function(n,i){var o=t.apply(e,r);function s(u){nc(o,n,i,s,a,"next",u)}function a(u){nc(o,n,i,s,a,"throw",u)}s(void 0)})}}function ic(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),r.push.apply(r,n)}return r}function hv(t){for(var e=1;e<arguments.length;e++){var r=arguments[e]!=null?arguments[e]:{};e%2?ic(Object(r),!0).forEach(function(n){dv(t,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):ic(Object(r)).forEach(function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(r,n))})}return t}function dv(t,e,r){return e=pv(e),e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function pv(t){var e=mv(t,"string");return typeof e=="symbol"?e:String(e)}function mv(t,e){if(typeof t!="object"||t===null)return t;var r=t[Symbol.toPrimitive];if(r!==void 0){var n=r.call(t,e||"default");if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var gv=et().codes.ERR_INVALID_ARG_TYPE;function yv(t,e,r){var n;if(e&&typeof e.next=="function")n=e;else if(e&&e[Symbol.asyncIterator])n=e[Symbol.asyncIterator]();else if(e&&e[Symbol.iterator])n=e[Symbol.iterator]();else throw new gv("iterable",["Iterable"],e);var i=new t(hv({objectMode:!0},r)),o=!1;i._read=function(){o||(o=!0,s())};function s(){return a.apply(this,arguments)}function a(){return a=cv(function*(){try{var u=yield n.next(),d=u.value,w=u.done;w?i.push(null):i.push(yield d)?s():o=!1}catch(E){i.destroy(E)}}),a.apply(this,arguments)}return i}oc.exports=yv});var ds=S((Jx,gc)=>{"use strict";gc.exports=X;var $t;X.ReadableState=fc;var zx=require("events").EventEmitter,lc=function(e,r){return e.listeners(r).length},Sr=ns(),ti=require("buffer").Buffer,bv=(typeof global<"u"?global:typeof window<"u"?window:typeof self<"u"?self:{}).Uint8Array||function(){};function wv(t){return ti.from(t)}function _v(t){return ti.isBuffer(t)||t instanceof bv}var ms=require("util"),V;ms&&ms.debuglog?V=ms.debuglog("stream"):V=function(){};var vv=Ff(),Es=ss(),Ev=as(),Sv=Ev.getHighWaterMark,ri=et().codes,Tv=ri.ERR_INVALID_ARG_TYPE,Ov=ri.ERR_STREAM_PUSH_AFTER_EOF,Dv=ri.ERR_METHOD_NOT_IMPLEMENTED,xv=ri.ERR_STREAM_UNSHIFT_AFTER_END_EVENT,Ut,gs,ys;je()(X,Sr);var Er=Es.errorOrDestroy,bs=["error","close","destroy","pause","resume"];function Pv(t,e,r){if(typeof t.prependListener=="function")return t.prependListener(e,r);!t._events||!t._events[e]?t.on(e,r):Array.isArray(t._events[e])?t._events[e].unshift(r):t._events[e]=[r,t._events[e]]}function fc(t,e,r){$t=$t||bt(),t=t||{},typeof r!="boolean"&&(r=e instanceof $t),this.objectMode=!!t.objectMode,r&&(this.objectMode=this.objectMode||!!t.readableObjectMode),this.highWaterMark=Sv(this,t,"readableHighWaterMark",r),this.buffer=new vv,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.paused=!0,this.emitClose=t.emitClose!==!1,this.autoDestroy=!!t.autoDestroy,this.destroyed=!1,this.defaultEncoding=t.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,t.encoding&&(Ut||(Ut=ur().StringDecoder),this.decoder=new Ut(t.encoding),this.encoding=t.encoding)}function X(t){if($t=$t||bt(),!(this instanceof X))return new X(t);var e=this instanceof $t;this._readableState=new fc(t,this,e),this.readable=!0,t&&(typeof t.read=="function"&&(this._read=t.read),typeof t.destroy=="function"&&(this._destroy=t.destroy)),Sr.call(this)}Object.defineProperty(X.prototype,"destroyed",{enumerable:!1,get:function(){return this._readableState===void 0?!1:this._readableState.destroyed},set:function(e){this._readableState&&(this._readableState.destroyed=e)}});X.prototype.destroy=Es.destroy;X.prototype._undestroy=Es.undestroy;X.prototype._destroy=function(t,e){e(t)};X.prototype.push=function(t,e){var r=this._readableState,n;return r.objectMode?n=!0:typeof t=="string"&&(e=e||r.defaultEncoding,e!==r.encoding&&(t=ti.from(t,e),e=""),n=!0),cc(this,t,e,!1,n)};X.prototype.unshift=function(t){return cc(this,t,null,!0,!1)};function cc(t,e,r,n,i){V("readableAddChunk",e);var o=t._readableState;if(e===null)o.reading=!1,Nv(t,o);else{var s;if(i||(s=Iv(o,e)),s)Er(t,s);else if(o.objectMode||e&&e.length>0)if(typeof e!="string"&&!o.objectMode&&Object.getPrototypeOf(e)!==ti.prototype&&(e=wv(e)),n)o.endEmitted?Er(t,new xv):ws(t,o,e,!0);else if(o.ended)Er(t,new Ov);else{if(o.destroyed)return!1;o.reading=!1,o.decoder&&!r?(e=o.decoder.write(e),o.objectMode||e.length!==0?ws(t,o,e,!1):vs(t,o)):ws(t,o,e,!1)}else n||(o.reading=!1,vs(t,o))}return!o.ended&&(o.length<o.highWaterMark||o.length===0)}function ws(t,e,r,n){e.flowing&&e.length===0&&!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&&ni(t)),vs(t,e)}function Iv(t,e){var r;return!_v(e)&&typeof e!="string"&&e!==void 0&&!t.objectMode&&(r=new Tv("chunk",["string","Buffer","Uint8Array"],e)),r}X.prototype.isPaused=function(){return this._readableState.flowing===!1};X.prototype.setEncoding=function(t){Ut||(Ut=ur().StringDecoder);var e=new Ut(t);this._readableState.decoder=e,this._readableState.encoding=this._readableState.decoder.encoding;for(var r=this._readableState.buffer.head,n="";r!==null;)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 ac=1073741824;function Mv(t){return t>=ac?t=ac:(t--,t|=t>>>1,t|=t>>>2,t|=t>>>4,t|=t>>>8,t|=t>>>16,t++),t}function uc(t,e){return t<=0||e.length===0&&e.ended?0:e.objectMode?1:t!==t?e.flowing&&e.length?e.buffer.head.data.length:e.length:(t>e.highWaterMark&&(e.highWaterMark=Mv(t)),t<=e.length?t:e.ended?e.length:(e.needReadable=!0,0))}X.prototype.read=function(t){V("read",t),t=parseInt(t,10);var e=this._readableState,r=t;if(t!==0&&(e.emittedReadable=!1),t===0&&e.needReadable&&((e.highWaterMark!==0?e.length>=e.highWaterMark:e.length>0)||e.ended))return V("read: emitReadable",e.length,e.ended),e.length===0&&e.ended?_s(this):ni(this),null;if(t=uc(t,e),t===0&&e.ended)return e.length===0&&_s(this),null;var n=e.needReadable;V("need readable",n),(e.length===0||e.length-t<e.highWaterMark)&&(n=!0,V("length less than watermark",n)),e.ended||e.reading?(n=!1,V("reading or ended",n)):n&&(V("do read"),e.reading=!0,e.sync=!0,e.length===0&&(e.needReadable=!0),this._read(e.highWaterMark),e.sync=!1,e.reading||(t=uc(r,e)));var i;return t>0?i=pc(t,e):i=null,i===null?(e.needReadable=e.length<=e.highWaterMark,t=0):(e.length-=t,e.awaitDrain=0),e.length===0&&(e.ended||(e.needReadable=!0),r!==t&&e.ended&&_s(this)),i!==null&&this.emit("data",i),i};function Nv(t,e){if(V("onEofChunk"),!e.ended){if(e.decoder){var r=e.decoder.end();r&&r.length&&(e.buffer.push(r),e.length+=e.objectMode?1:r.length)}e.ended=!0,e.sync?ni(t):(e.needReadable=!1,e.emittedReadable||(e.emittedReadable=!0,hc(t)))}}function ni(t){var e=t._readableState;V("emitReadable",e.needReadable,e.emittedReadable),e.needReadable=!1,e.emittedReadable||(V("emitReadable",e.flowing),e.emittedReadable=!0,process.nextTick(hc,t))}function hc(t){var e=t._readableState;V("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,Ss(t)}function vs(t,e){e.readingMore||(e.readingMore=!0,process.nextTick(Rv,t,e))}function Rv(t,e){for(;!e.reading&&!e.ended&&(e.length<e.highWaterMark||e.flowing&&e.length===0);){var r=e.length;if(V("maybeReadMore read 0"),t.read(0),r===e.length)break}e.readingMore=!1}X.prototype._read=function(t){Er(this,new Dv("_read()"))};X.prototype.pipe=function(t,e){var r=this,n=this._readableState;switch(n.pipesCount){case 0:n.pipes=t;break;case 1:n.pipes=[n.pipes,t];break;default:n.pipes.push(t);break}n.pipesCount+=1,V("pipe count=%d opts=%j",n.pipesCount,e);var i=(!e||e.end!==!1)&&t!==process.stdout&&t!==process.stderr,o=i?a:v;n.endEmitted?process.nextTick(o):r.once("end",o),t.on("unpipe",s);function s(R,N){V("onunpipe"),R===r&&N&&N.hasUnpiped===!1&&(N.hasUnpiped=!0,w())}function a(){V("onend"),t.end()}var u=Av(r);t.on("drain",u);var d=!1;function w(){V("cleanup"),t.removeListener("close",g),t.removeListener("finish",h),t.removeListener("drain",u),t.removeListener("error",y),t.removeListener("unpipe",s),r.removeListener("end",a),r.removeListener("end",v),r.removeListener("data",E),d=!0,n.awaitDrain&&(!t._writableState||t._writableState.needDrain)&&u()}r.on("data",E);function E(R){V("ondata");var N=t.write(R);V("dest.write",N),N===!1&&((n.pipesCount===1&&n.pipes===t||n.pipesCount>1&&mc(n.pipes,t)!==-1)&&!d&&(V("false write response, pause",n.awaitDrain),n.awaitDrain++),r.pause())}function y(R){V("onerror",R),v(),t.removeListener("error",y),lc(t,"error")===0&&Er(t,R)}Pv(t,"error",y);function g(){t.removeListener("finish",h),v()}t.once("close",g);function h(){V("onfinish"),t.removeListener("close",g),v()}t.once("finish",h);function v(){V("unpipe"),r.unpipe(t)}return t.emit("pipe",r),n.flowing||(V("pipe resume"),r.resume()),t};function Av(t){return function(){var r=t._readableState;V("pipeOnDrain",r.awaitDrain),r.awaitDrain&&r.awaitDrain--,r.awaitDrain===0&&lc(t,"data")&&(r.flowing=!0,Ss(t))}}X.prototype.unpipe=function(t){var e=this._readableState,r={hasUnpiped:!1};if(e.pipesCount===0)return this;if(e.pipesCount===1)return t&&t!==e.pipes?this:(t||(t=e.pipes),e.pipes=null,e.pipesCount=0,e.flowing=!1,t&&t.emit("unpipe",this,r),this);if(!t){var 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=mc(e.pipes,t);return s===-1?this:(e.pipes.splice(s,1),e.pipesCount-=1,e.pipesCount===1&&(e.pipes=e.pipes[0]),t.emit("unpipe",this,r),this)};X.prototype.on=function(t,e){var r=Sr.prototype.on.call(this,t,e),n=this._readableState;return t==="data"?(n.readableListening=this.listenerCount("readable")>0,n.flowing!==!1&&this.resume()):t==="readable"&&!n.endEmitted&&!n.readableListening&&(n.readableListening=n.needReadable=!0,n.flowing=!1,n.emittedReadable=!1,V("on readable",n.length,n.reading),n.length?ni(this):n.reading||process.nextTick(Lv,this)),r};X.prototype.addListener=X.prototype.on;X.prototype.removeListener=function(t,e){var r=Sr.prototype.removeListener.call(this,t,e);return t==="readable"&&process.nextTick(dc,this),r};X.prototype.removeAllListeners=function(t){var e=Sr.prototype.removeAllListeners.apply(this,arguments);return(t==="readable"||t===void 0)&&process.nextTick(dc,this),e};function dc(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 Lv(t){V("readable nexttick read 0"),t.read(0)}X.prototype.resume=function(){var t=this._readableState;return t.flowing||(V("resume"),t.flowing=!t.readableListening,Cv(this,t)),t.paused=!1,this};function Cv(t,e){e.resumeScheduled||(e.resumeScheduled=!0,process.nextTick(qv,t,e))}function qv(t,e){V("resume",e.reading),e.reading||t.read(0),e.resumeScheduled=!1,t.emit("resume"),Ss(t),e.flowing&&!e.reading&&t.read(0)}X.prototype.pause=function(){return V("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(V("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this};function Ss(t){var e=t._readableState;for(V("flow",e.flowing);e.flowing&&t.read()!==null;);}X.prototype.wrap=function(t){var e=this,r=this._readableState,n=!1;t.on("end",function(){if(V("wrapped end"),r.decoder&&!r.ended){var s=r.decoder.end();s&&s.length&&e.push(s)}e.push(null)}),t.on("data",function(s){if(V("wrapped data"),r.decoder&&(s=r.decoder.write(s)),!(r.objectMode&&s==null)&&!(!r.objectMode&&(!s||!s.length))){var a=e.push(s);a||(n=!0,t.pause())}});for(var i in t)this[i]===void 0&&typeof t[i]=="function"&&(this[i]=(function(a){return function(){return t[a].apply(t,arguments)}})(i));for(var o=0;o<bs.length;o++)t.on(bs[o],this.emit.bind(this,bs[o]));return this._read=function(s){V("wrapped _read",s),n&&(n=!1,t.resume())},this};typeof Symbol=="function"&&(X.prototype[Symbol.asyncIterator]=function(){return gs===void 0&&(gs=rc()),gs(this)});Object.defineProperty(X.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}});Object.defineProperty(X.prototype,"readableBuffer",{enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}});Object.defineProperty(X.prototype,"readableFlowing",{enumerable:!1,get:function(){return this._readableState.flowing},set:function(e){this._readableState&&(this._readableState.flowing=e)}});X._fromList=pc;Object.defineProperty(X.prototype,"readableLength",{enumerable:!1,get:function(){return this._readableState.length}});function pc(t,e){if(e.length===0)return null;var r;return e.objectMode?r=e.buffer.shift():!t||t>=e.length?(e.decoder?r=e.buffer.join(""):e.buffer.length===1?r=e.buffer.first():r=e.buffer.concat(e.length),e.buffer.clear()):r=e.buffer.consume(t,e.decoder),r}function _s(t){var e=t._readableState;V("endReadable",e.endEmitted),e.endEmitted||(e.ended=!0,process.nextTick(Fv,e,t))}function Fv(t,e){if(V("endReadableNT",t.endEmitted,t.length),!t.endEmitted&&t.length===0&&(t.endEmitted=!0,e.readable=!1,e.emit("end"),t.autoDestroy)){var r=e._writableState;(!r||r.autoDestroy&&r.finished)&&e.destroy()}}typeof Symbol=="function"&&(X.from=function(t,e){return ys===void 0&&(ys=sc()),ys(X,t,e)});function mc(t,e){for(var r=0,n=t.length;r<n;r++)if(t[r]===e)return r;return-1}});var Ts=S((Qx,bc)=>{"use strict";bc.exports=Be;var ii=et().codes,jv=ii.ERR_METHOD_NOT_IMPLEMENTED,kv=ii.ERR_MULTIPLE_CALLBACK,Bv=ii.ERR_TRANSFORM_ALREADY_TRANSFORMING,$v=ii.ERR_TRANSFORM_WITH_LENGTH_0,oi=bt();je()(Be,oi);function Uv(t,e){var r=this._transformState;r.transforming=!1;var n=r.writecb;if(n===null)return this.emit("error",new kv);r.writechunk=null,r.writecb=null,e!=null&&this.push(e),n(t);var i=this._readableState;i.reading=!1,(i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}function Be(t){if(!(this instanceof Be))return new Be(t);oi.call(this,t),this._transformState={afterTransform:Uv.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,t&&(typeof t.transform=="function"&&(this._transform=t.transform),typeof t.flush=="function"&&(this._flush=t.flush)),this.on("prefinish",Vv)}function Vv(){var t=this;typeof this._flush=="function"&&!this._readableState.destroyed?this._flush(function(e,r){yc(t,e,r)}):yc(this,null,null)}Be.prototype.push=function(t,e){return this._transformState.needTransform=!1,oi.prototype.push.call(this,t,e)};Be.prototype._transform=function(t,e,r){r(new jv("_transform()"))};Be.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)}};Be.prototype._read=function(t){var e=this._transformState;e.writechunk!==null&&!e.transforming?(e.transforming=!0,this._transform(e.writechunk,e.writeencoding,e.afterTransform)):e.needTransform=!0};Be.prototype._destroy=function(t,e){oi.prototype._destroy.call(this,t,function(r){e(r)})};function yc(t,e,r){if(e)return t.emit("error",e);if(r!=null&&t.push(r),t._writableState.length)throw new $v;if(t._transformState.transforming)throw new Bv;return t.push(null)}});var vc=S((Zx,_c)=>{"use strict";_c.exports=Tr;var wc=Ts();je()(Tr,wc);function Tr(t){if(!(this instanceof Tr))return new Tr(t);wc.call(this,t)}Tr.prototype._transform=function(t,e,r){r(null,t)}});var Dc=S((eP,Oc)=>{"use strict";var Os;function Hv(t){var e=!1;return function(){e||(e=!0,t.apply(void 0,arguments))}}var Tc=et().codes,Wv=Tc.ERR_MISSING_ARGS,Xv=Tc.ERR_STREAM_DESTROYED;function Ec(t){if(t)throw t}function Kv(t){return t.setHeader&&typeof t.abort=="function"}function Gv(t,e,r,n){n=Hv(n);var i=!1;t.on("close",function(){i=!0}),Os===void 0&&(Os=Qn()),Os(t,{readable:e,writable:r},function(s){if(s)return n(s);i=!0,n()});var o=!1;return function(s){if(!i&&!o){if(o=!0,Kv(t))return t.abort();if(typeof t.destroy=="function")return t.destroy();n(s||new Xv("pipe"))}}}function Sc(t){t()}function Yv(t,e){return t.pipe(e)}function zv(t){return!t.length||typeof t[t.length-1]!="function"?Ec:t.pop()}function Jv(){for(var t=arguments.length,e=new Array(t),r=0;r<t;r++)e[r]=arguments[r];var n=zv(e);if(Array.isArray(e[0])&&(e=e[0]),e.length<2)throw new Wv("streams");var i,o=e.map(function(s,a){var u=a<e.length-1,d=a>0;return Gv(s,u,d,function(w){i||(i=w),w&&o.forEach(Sc),!u&&(o.forEach(Sc),n(i))})});return e.reduce(Yv)}Oc.exports=Jv});var Et=S((Se,Dr)=>{"use strict";var Or=require("stream");process.env.READABLE_STREAM==="disable"&&Or?(Dr.exports=Or.Readable,Object.assign(Dr.exports,Or),Dr.exports.Stream=Or):(Se=Dr.exports=ds(),Se.Stream=Or||Se,Se.Readable=Se,Se.Writable=fs(),Se.Duplex=bt(),Se.Transform=Ts(),Se.PassThrough=vc(),Se.finished=Qn(),Se.pipeline=Dc())});var Rs=S((tP,Pc)=>{"use strict";var Vt=[],xr=[],Ds=function(){};function Ps(t){return~Vt.indexOf(t)?!1:(Vt.push(t),!0)}function Is(t){Ds=t}function Qv(t){for(var e=[],r=0;r<Vt.length;r++){if(Vt[r].async){e.push(Vt[r]);continue}if(Vt[r](t))return!0}return e.length?new Promise(function(i){Promise.all(e.map(function(s){return s(t)})).then(function(s){i(s.some(Boolean))})}):!1}function Ms(t){return~xr.indexOf(t)?!1:(xr.push(t),!0)}function xs(){Ds.apply(Ds,arguments)}function xc(t){for(var e=0;e<xr.length;e++)t=xr[e].apply(xr[e],arguments);return t}function Ns(t,e){var r=Object.prototype.hasOwnProperty;for(var n in e)r.call(e,n)&&(t[n]=e[n]);return t}function Zv(t){return t.enabled=!1,t.modify=Ms,t.set=Is,t.use=Ps,Ns(function(){return!1},t)}function eE(t){function e(){var r=Array.prototype.slice.call(arguments,0);return xs.call(xs,t,xc(r,t)),!0}return t.enabled=!0,t.modify=Ms,t.set=Is,t.use=Ps,Ns(e,t)}Pc.exports=function(e){return e.introduce=Ns,e.enabled=Qv,e.process=xc,e.modify=Ms,e.write=xs,e.nope=Zv,e.yep=eE,e.set=Is,e.use=Ps,e}});var Mc=S((rP,Ic)=>{"use strict";var tE=Rs(),rE=tE(function t(e,r){return r=r||{},r.namespace=e,r.prod=!0,r.dev=!1,r.force||t.force?t.yep(r):t.nope(r)});Ic.exports=rE});var qc=S((nP,Cc)=>{"use strict";var Re={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]},Rc=Object.create(null);for(let t in Re)Object.hasOwn(Re,t)&&(Rc[Re[t]]=t);var ue={to:{},get:{}};ue.get=function(t){let e=t.slice(0,3).toLowerCase(),r,n;switch(e){case"hsl":{r=ue.get.hsl(t),n="hsl";break}case"hwb":{r=ue.get.hwb(t),n="hwb";break}default:{r=ue.get.rgb(t),n="rgb";break}}return r?{model:n,value:r}:null};ue.get.rgb=function(t){if(!t)return null;let e=/^#([a-f\d]{3,4})$/i,r=/^#([a-f\d]{6})([a-f\d]{2})?$/i,n=/^rgba?\(\s*([+-]?\d+)(?=[\s,])\s*(?:,\s*)?([+-]?\d+)(?=[\s,])\s*(?:,\s*)?([+-]?\d+)\s*(?:[\s,|/]\s*([+-]?[\d.]+)(%?)\s*)?\)$/,i=/^rgba?\(\s*([+-]?[\d.]+)%\s*,?\s*([+-]?[\d.]+)%\s*,?\s*([+-]?[\d.]+)%\s*(?:[\s,|/]\s*([+-]?[\d.]+)(%?)\s*)?\)$/,o=/^(\w+)$/,s=[0,0,0,1],a,u,d;if(a=t.match(r)){for(d=a[2],a=a[1],u=0;u<3;u++){let w=u*2;s[u]=Number.parseInt(a.slice(w,w+2),16)}d&&(s[3]=Number.parseInt(d,16)/255)}else if(a=t.match(e)){for(a=a[1],d=a[3],u=0;u<3;u++)s[u]=Number.parseInt(a[u]+a[u],16);d&&(s[3]=Number.parseInt(d+d,16)/255)}else if(a=t.match(n)){for(u=0;u<3;u++)s[u]=Number.parseInt(a[u+1],10);a[4]&&(s[3]=a[5]?Number.parseFloat(a[4])*.01:Number.parseFloat(a[4]))}else if(a=t.match(i)){for(u=0;u<3;u++)s[u]=Math.round(Number.parseFloat(a[u+1])*2.55);a[4]&&(s[3]=a[5]?Number.parseFloat(a[4])*.01:Number.parseFloat(a[4]))}else return(a=t.match(o))?a[1]==="transparent"?[0,0,0,0]:Object.hasOwn(Re,a[1])?(s=Re[a[1]],s[3]=1,s):null:null;for(u=0;u<3;u++)s[u]=ot(s[u],0,255);return s[3]=ot(s[3],0,1),s};ue.get.hsl=function(t){if(!t)return null;let e=/^hsla?\(\s*([+-]?(?:\d{0,3}\.)?\d+)(?:deg)?\s*,?\s*([+-]?[\d.]+)%\s*,?\s*([+-]?[\d.]+)%\s*(?:[,|/]\s*([+-]?(?=\.\d|\d)(?:0|[1-9]\d*)?(?:\.\d*)?(?:[eE][+-]?\d+)?)\s*)?\)$/,r=t.match(e);if(r){let n=Number.parseFloat(r[4]),i=(Number.parseFloat(r[1])%360+360)%360,o=ot(Number.parseFloat(r[2]),0,100),s=ot(Number.parseFloat(r[3]),0,100),a=ot(Number.isNaN(n)?1:n,0,1);return[i,o,s,a]}return null};ue.get.hwb=function(t){if(!t)return null;let e=/^hwb\(\s*([+-]?\d{0,3}(?:\.\d+)?)(?:deg)?\s*[\s,]\s*([+-]?[\d.]+)%\s*[\s,]\s*([+-]?[\d.]+)%\s*(?:[\s,]\s*([+-]?(?=\.\d|\d)(?:0|[1-9]\d*)?(?:\.\d*)?(?:[eE][+-]?\d+)?)\s*)?\)$/,r=t.match(e);if(r){let n=Number.parseFloat(r[4]),i=(Number.parseFloat(r[1])%360+360)%360,o=ot(Number.parseFloat(r[2]),0,100),s=ot(Number.parseFloat(r[3]),0,100),a=ot(Number.isNaN(n)?1:n,0,1);return[i,o,s,a]}return null};ue.to.hex=function(...t){return"#"+si(t[0])+si(t[1])+si(t[2])+(t[3]<1?si(Math.round(t[3]*255)):"")};ue.to.rgb=function(...t){return t.length<4||t[3]===1?"rgb("+Math.round(t[0])+", "+Math.round(t[1])+", "+Math.round(t[2])+")":"rgba("+Math.round(t[0])+", "+Math.round(t[1])+", "+Math.round(t[2])+", "+t[3]+")"};ue.to.rgb.percent=function(...t){let e=Math.round(t[0]/255*100),r=Math.round(t[1]/255*100),n=Math.round(t[2]/255*100);return t.length<4||t[3]===1?"rgb("+e+"%, "+r+"%, "+n+"%)":"rgba("+e+"%, "+r+"%, "+n+"%, "+t[3]+")"};ue.to.hsl=function(...t){return t.length<4||t[3]===1?"hsl("+t[0]+", "+t[1]+"%, "+t[2]+"%)":"hsla("+t[0]+", "+t[1]+"%, "+t[2]+"%, "+t[3]+")"};ue.to.hwb=function(...t){let e="";return t.length>=4&&t[3]!==1&&(e=", "+t[3]),"hwb("+t[0]+", "+t[1]+"%, "+t[2]+"%"+e+")"};ue.to.keyword=function(...t){return Rc[t.slice(0,3)]};function ot(t,e,r){return Math.min(Math.max(e,t),r)}function si(t){let e=Math.round(t).toString(16).toUpperCase();return e.length<2?"0"+e:e}var Ac={};for(let t of Object.keys(Re))Ac[Re[t]]=t;var F={rgb:{channels:3,labels:"rgb"},hsl:{channels:3,labels:"hsl"},hsv:{channels:3,labels:"hsv"},hwb:{channels:3,labels:"hwb"},cmyk:{channels:4,labels:"cmyk"},xyz:{channels:3,labels:"xyz"},lab:{channels:3,labels:"lab"},oklab:{channels:3,labels:["okl","oka","okb"]},lch:{channels:3,labels:"lch"},oklch:{channels:3,labels:["okl","okc","okh"]},hex:{channels:1,labels:["hex"]},keyword:{channels:1,labels:["keyword"]},ansi16:{channels:1,labels:["ansi16"]},ansi256:{channels:1,labels:["ansi256"]},hcg:{channels:3,labels:["h","c","g"]},apple:{channels:3,labels:["r16","g16","b16"]},gray:{channels:1,labels:["gray"]}},$e=(6/29)**3;function Ht(t){let e=t>.0031308?1.055*t**.4166666666666667-.055:t*12.92;return Math.min(Math.max(0,e),1)}function Wt(t){return t>.04045?((t+.055)/1.055)**2.4:t/12.92}for(let t of Object.keys(F)){if(!("channels"in F[t]))throw new Error("missing channels property: "+t);if(!("labels"in F[t]))throw new Error("missing channel labels property: "+t);if(F[t].labels.length!==F[t].channels)throw new Error("channel and label counts mismatch: "+t);let{channels:e,labels:r}=F[t];delete F[t].channels,delete F[t].labels,Object.defineProperty(F[t],"channels",{value:e}),Object.defineProperty(F[t],"labels",{value:r})}F.rgb.hsl=function(t){let e=t[0]/255,r=t[1]/255,n=t[2]/255,i=Math.min(e,r,n),o=Math.max(e,r,n),s=o-i,a,u;switch(o){case i:{a=0;break}case e:{a=(r-n)/s;break}case r:{a=2+(n-e)/s;break}case n:{a=4+(e-r)/s;break}}a=Math.min(a*60,360),a<0&&(a+=360);let d=(i+o)/2;return o===i?u=0:d<=.5?u=s/(o+i):u=s/(2-o-i),[a,u*100,d*100]};F.rgb.hsv=function(t){let e,r,n,i,o,s=t[0]/255,a=t[1]/255,u=t[2]/255,d=Math.max(s,a,u),w=d-Math.min(s,a,u),E=function(y){return(d-y)/6/w+1/2};if(w===0)i=0,o=0;else{switch(o=w/d,e=E(s),r=E(a),n=E(u),d){case s:{i=n-r;break}case a:{i=1/3+e-n;break}case u:{i=2/3+r-e;break}}i<0?i+=1:i>1&&(i-=1)}return[i*360,o*100,d*100]};F.rgb.hwb=function(t){let e=t[0],r=t[1],n=t[2],i=F.rgb.hsl(t)[0],o=1/255*Math.min(e,Math.min(r,n));return n=1-1/255*Math.max(e,Math.max(r,n)),[i,o*100,n*100]};F.rgb.oklab=function(t){let e=Wt(t[0]/255),r=Wt(t[1]/255),n=Wt(t[2]/255),i=Math.cbrt(.4122214708*e+.5363325363*r+.0514459929*n),o=Math.cbrt(.2119034982*e+.6806995451*r+.1073969566*n),s=Math.cbrt(.0883024619*e+.2817188376*r+.6299787005*n),a=.2104542553*i+.793617785*o-.0040720468*s,u=1.9779984951*i-2.428592205*o+.4505937099*s,d=.0259040371*i+.7827717662*o-.808675766*s;return[a*100,u*100,d*100]};F.rgb.cmyk=function(t){let e=t[0]/255,r=t[1]/255,n=t[2]/255,i=Math.min(1-e,1-r,1-n),o=(1-e-i)/(1-i)||0,s=(1-r-i)/(1-i)||0,a=(1-n-i)/(1-i)||0;return[o*100,s*100,a*100,i*100]};function nE(t,e){return(t[0]-e[0])**2+(t[1]-e[1])**2+(t[2]-e[2])**2}F.rgb.keyword=function(t){let e=Ac[t];if(e)return e;let r=Number.POSITIVE_INFINITY,n;for(let i of Object.keys(Re)){let o=Re[i],s=nE(t,o);s<r&&(r=s,n=i)}return n};F.keyword.rgb=function(t){return Re[t]};F.rgb.xyz=function(t){let e=Wt(t[0]/255),r=Wt(t[1]/255),n=Wt(t[2]/255),i=e*.4124564+r*.3575761+n*.1804375,o=e*.2126729+r*.7151522+n*.072175,s=e*.0193339+r*.119192+n*.9503041;return[i*100,o*100,s*100]};F.rgb.lab=function(t){let e=F.rgb.xyz(t),r=e[0],n=e[1],i=e[2];r/=95.047,n/=100,i/=108.883,r=r>$e?r**(1/3):7.787*r+16/116,n=n>$e?n**(1/3):7.787*n+16/116,i=i>$e?i**(1/3):7.787*i+16/116;let o=116*n-16,s=500*(r-n),a=200*(n-i);return[o,s,a]};F.hsl.rgb=function(t){let e=t[0]/360,r=t[1]/100,n=t[2]/100,i,o;if(r===0)return o=n*255,[o,o,o];let s=n<.5?n*(1+r):n+r-n*r,a=2*n-s,u=[0,0,0];for(let d=0;d<3;d++)i=e+1/3*-(d-1),i<0&&i++,i>1&&i--,6*i<1?o=a+(s-a)*6*i:2*i<1?o=s:3*i<2?o=a+(s-a)*(2/3-i)*6:o=a,u[d]=o*255;return u};F.hsl.hsv=function(t){let e=t[0],r=t[1]/100,n=t[2]/100,i=r,o=Math.max(n,.01);n*=2,r*=n<=1?n:2-n,i*=o<=1?o:2-o;let s=(n+r)/2,a=n===0?2*i/(o+i):2*r/(n+r);return[e,a*100,s*100]};F.hsv.rgb=function(t){let e=t[0]/60,r=t[1]/100,n=t[2]/100,i=Math.floor(e)%6,o=e-Math.floor(e),s=255*n*(1-r),a=255*n*(1-r*o),u=255*n*(1-r*(1-o));switch(n*=255,i){case 0:return[n,u,s];case 1:return[a,n,s];case 2:return[s,n,u];case 3:return[s,a,n];case 4:return[u,s,n];case 5:return[n,s,a]}};F.hsv.hsl=function(t){let e=t[0],r=t[1]/100,n=t[2]/100,i=Math.max(n,.01),o,s;s=(2-r)*n;let a=(2-r)*i;return o=r*i,o/=a<=1?a:2-a,o=o||0,s/=2,[e,o*100,s*100]};F.hwb.rgb=function(t){let e=t[0]/360,r=t[1]/100,n=t[2]/100,i=r+n,o;i>1&&(r/=i,n/=i);let s=Math.floor(6*e),a=1-n;o=6*e-s,(s&1)!==0&&(o=1-o);let u=r+o*(a-r),d,w,E;switch(s){default:case 6:case 0:{d=a,w=u,E=r;break}case 1:{d=u,w=a,E=r;break}case 2:{d=r,w=a,E=u;break}case 3:{d=r,w=u,E=a;break}case 4:{d=u,w=r,E=a;break}case 5:{d=a,w=r,E=u;break}}return[d*255,w*255,E*255]};F.cmyk.rgb=function(t){let e=t[0]/100,r=t[1]/100,n=t[2]/100,i=t[3]/100,o=1-Math.min(1,e*(1-i)+i),s=1-Math.min(1,r*(1-i)+i),a=1-Math.min(1,n*(1-i)+i);return[o*255,s*255,a*255]};F.xyz.rgb=function(t){let e=t[0]/100,r=t[1]/100,n=t[2]/100,i,o,s;return i=e*3.2404542+r*-1.5371385+n*-.4985314,o=e*-.969266+r*1.8760108+n*.041556,s=e*.0556434+r*-.2040259+n*1.0572252,i=Ht(i),o=Ht(o),s=Ht(s),[i*255,o*255,s*255]};F.xyz.lab=function(t){let e=t[0],r=t[1],n=t[2];e/=95.047,r/=100,n/=108.883,e=e>$e?e**(1/3):7.787*e+16/116,r=r>$e?r**(1/3):7.787*r+16/116,n=n>$e?n**(1/3):7.787*n+16/116;let i=116*r-16,o=500*(e-r),s=200*(r-n);return[i,o,s]};F.xyz.oklab=function(t){let e=t[0]/100,r=t[1]/100,n=t[2]/100,i=Math.cbrt(.8189330101*e+.3618667424*r-.1288597137*n),o=Math.cbrt(.0329845436*e+.9293118715*r+.0361456387*n),s=Math.cbrt(.0482003018*e+.2643662691*r+.633851707*n),a=.2104542553*i+.793617785*o-.0040720468*s,u=1.9779984951*i-2.428592205*o+.4505937099*s,d=.0259040371*i+.7827717662*o-.808675766*s;return[a*100,u*100,d*100]};F.oklab.oklch=function(t){return F.lab.lch(t)};F.oklab.xyz=function(t){let e=t[0]/100,r=t[1]/100,n=t[2]/100,i=(.999999998*e+.396337792*r+.215803758*n)**3,o=(1.000000008*e-.105561342*r-.063854175*n)**3,s=(1.000000055*e-.089484182*r-1.291485538*n)**3,a=1.227013851*i-.55779998*o+.281256149*s,u=-.040580178*i+1.11225687*o-.071676679*s,d=-.076381285*i-.421481978*o+1.58616322*s;return[a*100,u*100,d*100]};F.oklab.rgb=function(t){let e=t[0]/100,r=t[1]/100,n=t[2]/100,i=(e+.3963377774*r+.2158037573*n)**3,o=(e-.1055613458*r-.0638541728*n)**3,s=(e-.0894841775*r-1.291485548*n)**3,a=Ht(4.0767416621*i-3.3077115913*o+.2309699292*s),u=Ht(-1.2684380046*i+2.6097574011*o-.3413193965*s),d=Ht(-.0041960863*i-.7034186147*o+1.707614701*s);return[a*255,u*255,d*255]};F.oklch.oklab=function(t){return F.lch.lab(t)};F.lab.xyz=function(t){let e=t[0],r=t[1],n=t[2],i,o,s;o=(e+16)/116,i=r/500+o,s=o-n/200;let a=o**3,u=i**3,d=s**3;return o=a>$e?a:(o-16/116)/7.787,i=u>$e?u:(i-16/116)/7.787,s=d>$e?d:(s-16/116)/7.787,i*=95.047,o*=100,s*=108.883,[i,o,s]};F.lab.lch=function(t){let e=t[0],r=t[1],n=t[2],i;i=Math.atan2(n,r)*360/2/Math.PI,i<0&&(i+=360);let s=Math.sqrt(r*r+n*n);return[e,s,i]};F.lch.lab=function(t){let e=t[0],r=t[1],i=t[2]/360*2*Math.PI,o=r*Math.cos(i),s=r*Math.sin(i);return[e,o,s]};F.rgb.ansi16=function(t,e=null){let[r,n,i]=t,o=e===null?F.rgb.hsv(t)[2]:e;if(o=Math.round(o/50),o===0)return 30;let s=30+(Math.round(i/255)<<2|Math.round(n/255)<<1|Math.round(r/255));return o===2&&(s+=60),s};F.hsv.ansi16=function(t){return F.rgb.ansi16(F.hsv.rgb(t),t[2])};F.rgb.ansi256=function(t){let e=t[0],r=t[1],n=t[2];return e>>4===r>>4&&r>>4===n>>4?e<8?16:e>248?231:Math.round((e-8)/247*24)+232:16+36*Math.round(e/255*5)+6*Math.round(r/255*5)+Math.round(n/255*5)};F.ansi16.rgb=function(t){t=t[0];let e=t%10;if(e===0||e===7)return t>50&&(e+=3.5),e=e/10.5*255,[e,e,e];let r=(Math.trunc(t>50)+1)*.5,n=(e&1)*r*255,i=(e>>1&1)*r*255,o=(e>>2&1)*r*255;return[n,i,o]};F.ansi256.rgb=function(t){if(t=t[0],t>=232){let o=(t-232)*10+8;return[o,o,o]}t-=16;let e,r=Math.floor(t/36)/5*255,n=Math.floor((e=t%36)/6)/5*255,i=e%6/5*255;return[r,n,i]};F.rgb.hex=function(t){let r=(((Math.round(t[0])&255)<<16)+((Math.round(t[1])&255)<<8)+(Math.round(t[2])&255)).toString(16).toUpperCase();return"000000".slice(r.length)+r};F.hex.rgb=function(t){let e=t.toString(16).match(/[a-f\d]{6}|[a-f\d]{3}/i);if(!e)return[0,0,0];let r=e[0];e[0].length===3&&(r=[...r].map(a=>a+a).join(""));let n=Number.parseInt(r,16),i=n>>16&255,o=n>>8&255,s=n&255;return[i,o,s]};F.rgb.hcg=function(t){let e=t[0]/255,r=t[1]/255,n=t[2]/255,i=Math.max(Math.max(e,r),n),o=Math.min(Math.min(e,r),n),s=i-o,a,u=s<1?o/(1-s):0;return s<=0?a=0:i===e?a=(r-n)/s%6:i===r?a=2+(n-e)/s:a=4+(e-r)/s,a/=6,a%=1,[a*360,s*100,u*100]};F.hsl.hcg=function(t){let e=t[1]/100,r=t[2]/100,n=r<.5?2*e*r:2*e*(1-r),i=0;return n<1&&(i=(r-.5*n)/(1-n)),[t[0],n*100,i*100]};F.hsv.hcg=function(t){let e=t[1]/100,r=t[2]/100,n=e*r,i=0;return n<1&&(i=(r-n)/(1-n)),[t[0],n*100,i*100]};F.hcg.rgb=function(t){let e=t[0]/360,r=t[1]/100,n=t[2]/100;if(r===0)return[n*255,n*255,n*255];let i=[0,0,0],o=e%1*6,s=o%1,a=1-s,u=0;switch(Math.floor(o)){case 0:{i[0]=1,i[1]=s,i[2]=0;break}case 1:{i[0]=a,i[1]=1,i[2]=0;break}case 2:{i[0]=0,i[1]=1,i[2]=s;break}case 3:{i[0]=0,i[1]=a,i[2]=1;break}case 4:{i[0]=s,i[1]=0,i[2]=1;break}default:i[0]=1,i[1]=0,i[2]=a}return u=(1-r)*n,[(r*i[0]+u)*255,(r*i[1]+u)*255,(r*i[2]+u)*255]};F.hcg.hsv=function(t){let e=t[1]/100,r=t[2]/100,n=e+r*(1-e),i=0;return n>0&&(i=e/n),[t[0],i*100,n*100]};F.hcg.hsl=function(t){let e=t[1]/100,n=t[2]/100*(1-e)+.5*e,i=0;return n>0&&n<.5?i=e/(2*n):n>=.5&&n<1&&(i=e/(2*(1-n))),[t[0],i*100,n*100]};F.hcg.hwb=function(t){let e=t[1]/100,r=t[2]/100,n=e+r*(1-e);return[t[0],(n-e)*100,(1-n)*100]};F.hwb.hcg=function(t){let e=t[1]/100,n=1-t[2]/100,i=n-e,o=0;return i<1&&(o=(n-i)/(1-i)),[t[0],i*100,o*100]};F.apple.rgb=function(t){return[t[0]/65535*255,t[1]/65535*255,t[2]/65535*255]};F.rgb.apple=function(t){return[t[0]/255*65535,t[1]/255*65535,t[2]/255*65535]};F.gray.rgb=function(t){return[t[0]/100*255,t[0]/100*255,t[0]/100*255]};F.gray.hsl=function(t){return[0,0,t[0]]};F.gray.hsv=F.gray.hsl;F.gray.hwb=function(t){return[0,100,t[0]]};F.gray.cmyk=function(t){return[0,0,0,t[0]]};F.gray.lab=function(t){return[t[0],0,0]};F.gray.hex=function(t){let e=Math.round(t[0]/100*255)&255,n=((e<<16)+(e<<8)+e).toString(16).toUpperCase();return"000000".slice(n.length)+n};F.rgb.gray=function(t){return[(t[0]+t[1]+t[2])/3/255*100]};function iE(){let t={},e=Object.keys(F);for(let{length:r}=e,n=0;n<r;n++)t[e[n]]={distance:-1,parent:null};return t}function oE(t){let e=iE(),r=[t];for(e[t].distance=0;r.length>0;){let n=r.pop(),i=Object.keys(F[n]);for(let{length:o}=i,s=0;s<o;s++){let a=i[s],u=e[a];u.distance===-1&&(u.distance=e[n].distance+1,u.parent=n,r.unshift(a))}}return e}function sE(t,e){return function(r){return e(t(r))}}function aE(t,e){let r=[e[t].parent,t],n=F[e[t].parent][t],i=e[t].parent;for(;e[i].parent;)r.unshift(e[i].parent),n=sE(F[e[i].parent][i],n),i=e[i].parent;return n.conversion=r,n}function uE(t){let e=oE(t),r={},n=Object.keys(e);for(let{length:i}=n,o=0;o<i;o++){let s=n[o];e[s].parent!==null&&(r[s]=aE(s,e))}return r}var le={},lE=Object.keys(F);function fE(t){let e=function(...r){let n=r[0];return n==null?n:(n.length>1&&(r=n),t(r))};return"conversion"in t&&(e.conversion=t.conversion),e}function cE(t){let e=function(...r){let n=r[0];if(n==null)return n;n.length>1&&(r=n);let i=t(r);if(typeof i=="object")for(let{length:o}=i,s=0;s<o;s++)i[s]=Math.round(i[s]);return i};return"conversion"in t&&(e.conversion=t.conversion),e}for(let t of lE){le[t]={},Object.defineProperty(le[t],"channels",{value:F[t].channels}),Object.defineProperty(le[t],"labels",{value:F[t].labels});let e=uE(t),r=Object.keys(e);for(let n of r){let i=e[n];le[t][n]=cE(i),le[t][n].raw=fE(i)}}var Lc=["keyword","gray","hex"],As={};for(let t of Object.keys(le))As[[...le[t].labels].sort().join("")]=t;var Ls={};function ae(t,e){if(!(this instanceof ae))return new ae(t,e);if(e&&e in Lc&&(e=null),e&&!(e in le))throw new Error("Unknown model: "+e);let r,n;if(t==null)this.model="rgb",this.color=[0,0,0],this.valpha=1;else if(t instanceof ae)this.model=t.model,this.color=[...t.color],this.valpha=t.valpha;else if(typeof t=="string"){let i=ue.get(t);if(i===null)throw new Error("Unable to parse color from string: "+t);this.model=i.model,n=le[this.model].channels,this.color=i.value.slice(0,n),this.valpha=typeof i.value[n]=="number"?i.value[n]:1}else if(t.length>0){this.model=e||"rgb",n=le[this.model].channels;let i=Array.prototype.slice.call(t,0,n);this.color=Cs(i,n),this.valpha=typeof t[n]=="number"?t[n]:1}else if(typeof t=="number")this.model="rgb",this.color=[t>>16&255,t>>8&255,t&255],this.valpha=1;else{this.valpha=1;let i=Object.keys(t);"alpha"in t&&(i.splice(i.indexOf("alpha"),1),this.valpha=typeof t.alpha=="number"?t.alpha:0);let o=i.sort().join("");if(!(o in As))throw new Error("Unable to parse color from object: "+JSON.stringify(t));this.model=As[o];let{labels:s}=le[this.model],a=[];for(r=0;r<s.length;r++)a.push(t[s[r]]);this.color=Cs(a)}if(Ls[this.model])for(n=le[this.model].channels,r=0;r<n;r++){let i=Ls[this.model][r];i&&(this.color[r]=i(this.color[r]))}this.valpha=Math.max(0,Math.min(1,this.valpha)),Object.freeze&&Object.freeze(this)}ae.prototype={toString(){return this.string()},toJSON(){return this[this.model]()},string(t){let e=this.model in ue.to?this:this.rgb();e=e.round(typeof t=="number"?t:1);let r=e.valpha===1?e.color:[...e.color,this.valpha];return ue.to[e.model](...r)},percentString(t){let e=this.rgb().round(typeof t=="number"?t:1),r=e.valpha===1?e.color:[...e.color,this.valpha];return ue.to.rgb.percent(...r)},array(){return this.valpha===1?[...this.color]:[...this.color,this.valpha]},object(){let t={},{channels:e}=le[this.model],{labels:r}=le[this.model];for(let n=0;n<e;n++)t[r[n]]=this.color[n];return this.valpha!==1&&(t.alpha=this.valpha),t},unitArray(){let t=this.rgb().color;return t[0]/=255,t[1]/=255,t[2]/=255,this.valpha!==1&&t.push(this.valpha),t},unitObject(){let t=this.rgb().object();return t.r/=255,t.g/=255,t.b/=255,this.valpha!==1&&(t.alpha=this.valpha),t},round(t){return t=Math.max(t||0,0),new ae([...this.color.map(dE(t)),this.valpha],this.model)},alpha(t){return t!==void 0?new ae([...this.color,Math.max(0,Math.min(1,t))],this.model):this.valpha},red:te("rgb",0,se(255)),green:te("rgb",1,se(255)),blue:te("rgb",2,se(255)),hue:te(["hsl","hsv","hsl","hwb","hcg"],0,t=>(t%360+360)%360),saturationl:te("hsl",1,se(100)),lightness:te("hsl",2,se(100)),saturationv:te("hsv",1,se(100)),value:te("hsv",2,se(100)),chroma:te("hcg",1,se(100)),gray:te("hcg",2,se(100)),white:te("hwb",1,se(100)),wblack:te("hwb",2,se(100)),cyan:te("cmyk",0,se(100)),magenta:te("cmyk",1,se(100)),yellow:te("cmyk",2,se(100)),black:te("cmyk",3,se(100)),x:te("xyz",0,se(95.047)),y:te("xyz",1,se(100)),z:te("xyz",2,se(108.833)),l:te("lab",0,se(100)),a:te("lab",1),b:te("lab",2),keyword(t){return t!==void 0?new ae(t):le[this.model].keyword(this.color)},hex(t){return t!==void 0?new ae(t):ue.to.hex(...this.rgb().round().color)},hexa(t){if(t!==void 0)return new ae(t);let e=this.rgb().round().color,r=Math.round(this.valpha*255).toString(16).toUpperCase();return r.length===1&&(r="0"+r),ue.to.hex(...e)+r},rgbNumber(){let t=this.rgb().color;return(t[0]&255)<<16|(t[1]&255)<<8|t[2]&255},luminosity(){let t=this.rgb().color,e=[];for(let[r,n]of t.entries()){let i=n/255;e[r]=i<=.04045?i/12.92:((i+.055)/1.055)**2.4}return .2126*e[0]+.7152*e[1]+.0722*e[2]},contrast(t){let e=this.luminosity(),r=t.luminosity();return e>r?(e+.05)/(r+.05):(r+.05)/(e+.05)},level(t){let e=this.contrast(t);return e>=7?"AAA":e>=4.5?"AA":""},isDark(){let t=this.rgb().color;return(t[0]*2126+t[1]*7152+t[2]*722)/1e4<128},isLight(){return!this.isDark()},negate(){let t=this.rgb();for(let e=0;e<3;e++)t.color[e]=255-t.color[e];return t},lighten(t){let e=this.hsl();return e.color[2]+=e.color[2]*t,e},darken(t){let e=this.hsl();return e.color[2]-=e.color[2]*t,e},saturate(t){let e=this.hsl();return e.color[1]+=e.color[1]*t,e},desaturate(t){let e=this.hsl();return e.color[1]-=e.color[1]*t,e},whiten(t){let e=this.hwb();return e.color[1]+=e.color[1]*t,e},blacken(t){let e=this.hwb();return e.color[2]+=e.color[2]*t,e},grayscale(){let t=this.rgb().color,e=t[0]*.3+t[1]*.59+t[2]*.11;return ae.rgb(e,e,e)},fade(t){return this.alpha(this.valpha-this.valpha*t)},opaquer(t){return this.alpha(this.valpha+this.valpha*t)},rotate(t){let e=this.hsl(),r=e.color[0];return r=(r+t)%360,r=r<0?360+r:r,e.color[0]=r,e},mix(t,e){if(!t||!t.rgb)throw new Error('Argument to "mix" was not a Color instance, but rather an instance of '+typeof t);let r=t.rgb(),n=this.rgb(),i=e===void 0?.5:e,o=2*i-1,s=r.alpha()-n.alpha(),a=((o*s===-1?o:(o+s)/(1+o*s))+1)/2,u=1-a;return ae.rgb(a*r.red()+u*n.red(),a*r.green()+u*n.green(),a*r.blue()+u*n.blue(),r.alpha()*i+n.alpha()*(1-i))}};for(let t of Object.keys(le)){if(Lc.includes(t))continue;let{channels:e}=le[t];ae.prototype[t]=function(...r){return this.model===t?new ae(this):r.length>0?new ae(r,t):new ae([...pE(le[this.model][t].raw(this.color)),this.valpha],t)},ae[t]=function(...r){let n=r[0];return typeof n=="number"&&(n=Cs(r,e)),new ae(n,t)}}function hE(t,e){return Number(t.toFixed(e))}function dE(t){return function(e){return hE(e,t)}}function te(t,e,r){t=Array.isArray(t)?t:[t];for(let n of t)(Ls[n]||=[])[e]=r;return t=t[0],function(n){let i;return n!==void 0?(r&&(n=r(n)),i=this[t](),i.color[e]=n,i):(i=this[t]().color[e],r&&(i=r(i)),i)}}function se(t){return function(e){return Math.max(0,Math.min(t,e))}}function pE(t){return Array.isArray(t)?t:[t]}function Cs(t,e){for(let r=0;r<e;r++)typeof t[r]!="number"&&(t[r]=0);return t}function mE(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var gE=function(e){for(var r=0,n=0;r<e.length;n=e.charCodeAt(r++)+((n<<5)-n));var i=Math.floor(Math.abs(Math.sin(n)*1e4%1*16777216)).toString(16);return"#"+Array(6-i.length+1).join("0")+i},Nc=mE(gE);function yE(t,e){let r=t.split(e||":"),n=Nc(r[0]);if(!r.length)return n;for(let i=0,o=r.length-1;i<o;i++)n=ae(n).mix(ae(Nc(r[i+1]))).saturate(1).hex();return n}Cc.exports=yE});var jc=S((iP,Fc)=>{"use strict";function De(t,e){if(e)return new De(t).style(e);if(!(this instanceof De))return new De(t);this.text=t}De.prototype.prefix="\x1B[";De.prototype.suffix="m";De.prototype.hex=function(e){e=e[0]==="#"?e.substring(1):e,e.length===3&&(e=e.split(""),e[5]=e[2],e[4]=e[2],e[3]=e[1],e[2]=e[1],e[1]=e[0],e=e.join(""));var r=e.substring(0,2),n=e.substring(2,4),i=e.substring(4,6);return[parseInt(r,16),parseInt(n,16),parseInt(i,16)]};De.prototype.rgb=function(e,r,n){var i=e/255*5,o=r/255*5,s=n/255*5;return this.ansi(i,o,s)};De.prototype.ansi=function(e,r,n){var i=Math.round(e),o=Math.round(r),s=Math.round(n);return 16+i*36+o*6+s};De.prototype.reset=function(){return this.prefix+"39;49"+this.suffix};De.prototype.style=function(e){return this.prefix+"38;5;"+this.rgb.apply(this,this.hex(e))+this.suffix+this.text+this.reset()};Fc.exports=De});var Bc=S((oP,kc)=>{"use strict";var bE=qc(),wE=jc();kc.exports=function(e,r){var n=r.namespace,i=r.colors!==!1?wE(n+":",bE(n)):n+":";return e[0]=i+" "+e[0],e}});var Uc=S((sP,$c)=>{"use strict";$c.exports=function(e,r){if(!r)return!1;for(var n=r.split(/[\s,]+/),i=0;i<n.length;i++){if(r=n[i].replace("*",".*?"),r.charAt(0)==="-"){if(new RegExp("^"+r.substr(1)+"$").test(e))return!1;continue}if(new RegExp("^"+r+"$").test(e))return!0}return!1}});var Hc=S((aP,Vc)=>{"use strict";var _E=Uc();Vc.exports=function(e){return function(n){try{return _E(n,e())}catch{}return!1}}});var Xc=S((uP,Wc)=>{"use strict";var vE=Hc();Wc.exports=vE(function(){return process.env.DEBUG||process.env.DIAGNOSTICS})});var Gc=S((lP,Kc)=>{"use strict";Kc.exports=function(t,e){try{Function.prototype.apply.call(console.log,console,e)}catch{}}});var zc=S((fP,Yc)=>{"use strict";var EE=Rs(),SE=require("tty").isatty(1),ai=EE(function t(e,r){return r=r||{},r.colors="colors"in r?r.colors:SE,r.namespace=e,r.prod=!1,r.dev=!0,!t.enabled(e)&&!(r.force||t.force)?t.nope(r):t.yep(r)});ai.modify(Bc());ai.use(Xc());ai.set(Gc());Yc.exports=ai});var Pr=S((cP,qs)=>{"use strict";process.env.NODE_ENV==="production"?qs.exports=Mc():qs.exports=zc()});var Qc=S((hP,Jc)=>{"use strict";var Fs=require("fs"),{StringDecoder:TE}=require("string_decoder"),{Stream:OE}=Et();function DE(){}Jc.exports=(t,e)=>{let r=Buffer.alloc(65536),n=new TE("utf8"),i=new OE,o="",s=0,a=0;return t.start===-1&&delete t.start,i.readable=!0,i.destroy=()=>{i.destroyed=!0,i.emit("end"),i.emit("close")},Fs.open(t.file,"a+","0644",(u,d)=>{if(u){e?e(u):i.emit("error",u),i.destroy();return}(function w(){if(i.destroyed){Fs.close(d,DE);return}return Fs.read(d,r,0,r.length,s,(E,y)=>{if(E){e?e(E):i.emit("error",E),i.destroy();return}if(!y)return o&&((t.start==null||a>t.start)&&(e?e(null,o):i.emit("line",o)),a++,o=""),setTimeout(w,1e3);let g=n.write(r.slice(0,y));e||i.emit("data",g),g=(o+g).split(/\n+/);let h=g.length-1,v=0;for(;v<h;v++)(t.start==null||a>t.start)&&(e?e(null,g[v]):i.emit("line",g[v])),a++;return o=g[h],s+=y,w()})})()}),e?i.destroy:i}});var rh=S((pP,th)=>{"use strict";var be=require("fs"),fe=require("path"),Zc=Mf(),xE=require("zlib"),{MESSAGE:PE}=ne(),{Stream:IE,PassThrough:eh}=Et(),ME=qt(),xe=Pr()("winston:file"),NE=require("os"),RE=Qc();th.exports=class extends ME{constructor(e={}){super(e),this.name=e.name||"file";function r(n,...i){i.slice(1).forEach(o=>{if(e[o])throw new Error(`Cannot set ${o} and ${n} together`)})}if(this._stream=new eh,this._stream.setMaxListeners(30),this._onError=this._onError.bind(this),e.filename||e.dirname)r("filename or dirname","stream"),this._basename=this.filename=e.filename?fe.basename(e.filename):"winston.log",this.dirname=e.dirname||fe.dirname(e.filename),this.options=e.options||{flags:"a"};else if(e.stream)console.warn("options.stream will be removed in winston@4. Use winston.transports.Stream"),r("stream","filename","maxsize"),this._dest=this._stream.pipe(this._setupStream(e.stream)),this.dirname=fe.dirname(this._dest.path);else throw new Error("Cannot log to file without filename or stream.");this.maxsize=e.maxsize||null,this.rotationFormat=e.rotationFormat||!1,this.zippedArchive=e.zippedArchive||!1,this.maxFiles=e.maxFiles||null,this.eol=typeof e.eol=="string"?e.eol:NE.EOL,this.tailable=e.tailable||!1,this.lazy=e.lazy||!1,this._size=0,this._pendingSize=0,this._created=0,this._drain=!1,this._opening=!1,this._ending=!1,this._fileExist=!1,this.dirname&&this._createLogDirIfNotExist(this.dirname),this.lazy||this.open()}finishIfEnding(){this._ending&&(this._opening?this.once("open",()=>{this._stream.once("finish",()=>this.emit("finish")),setImmediate(()=>this._stream.end())}):(this._stream.once("finish",()=>this.emit("finish")),setImmediate(()=>this._stream.end())))}log(e,r=()=>{}){if(this.silent)return r(),!0;if(this._drain){this._stream.once("drain",()=>{this._drain=!1,this.log(e,r)});return}if(this._rotate){this._stream.once("rotate",()=>{this._rotate=!1,this.log(e,r)});return}if(this.lazy){if(!this._fileExist){this._opening||this.open(),this.once("open",()=>{this._fileExist=!0,this.log(e,r)});return}if(this._needsNewFile(this._pendingSize)){this._dest.once("close",()=>{this._opening||this.open(),this.once("open",()=>{this.log(e,r)})});return}}let n=`${e[PE]}${this.eol}`,i=Buffer.byteLength(n);function o(){if(this._size+=i,this._pendingSize-=i,xe("logged %s %s",this._size,n),this.emit("logged",e),!this._rotate&&!this._opening&&this._needsNewFile()){if(this.lazy){this._endStream(()=>{this.emit("fileclosed")});return}this._rotate=!0,this._endStream(()=>this._rotateFile())}}this._pendingSize+=i,this._opening&&!this.rotatedWhileOpening&&this._needsNewFile(this._size+this._pendingSize)&&(this.rotatedWhileOpening=!0);let s=this._stream.write(n,o.bind(this));return s?r():(this._drain=!0,this._stream.once("drain",()=>{this._drain=!1,r()})),xe("written",s,this._drain),this.finishIfEnding(),s}query(e,r){typeof e=="function"&&(r=e,e={}),e=E(e);let n=fe.join(this.dirname,this.filename),i="",o=[],s=0,a=be.createReadStream(n,{encoding:"utf8"});a.on("error",y=>{if(a.readable&&a.destroy(),!!r)return y.code!=="ENOENT"?r(y):r(null,o)}),a.on("data",y=>{y=(i+y).split(/\n+/);let g=y.length-1,h=0;for(;h<g;h++)(!e.start||s>=e.start)&&u(y[h]),s++;i=y[g]}),a.on("close",()=>{i&&u(i,!0),e.order==="desc"&&(o=o.reverse()),r&&r(null,o)});function u(y,g){try{let h=JSON.parse(y);w(h)&&d(h)}catch(h){g||a.emit("error",h)}}function d(y){if(e.rows&&o.length>=e.rows&&e.order!=="desc"){a.readable&&a.destroy();return}e.fields&&(y=e.fields.reduce((g,h)=>(g[h]=y[h],g),{})),e.order==="desc"&&o.length>=e.rows&&o.shift(),o.push(y)}function w(y){if(!y||typeof y!="object")return;let g=new Date(y.timestamp);if(!(e.from&&g<e.from||e.until&&g>e.until||e.level&&e.level!==y.level))return!0}function E(y){return y=y||{},y.rows=y.rows||y.limit||10,y.start=y.start||0,y.until=y.until||new Date,typeof y.until!="object"&&(y.until=new Date(y.until)),y.from=y.from||y.until-1440*60*1e3,typeof y.from!="object"&&(y.from=new Date(y.from)),y.order=y.order||"desc",y}}stream(e={}){let r=fe.join(this.dirname,this.filename),n=new IE,i={file:r,start:e.start};return n.destroy=RE(i,(o,s)=>{if(o)return n.emit("error",o);try{n.emit("data",s),s=JSON.parse(s),n.emit("log",s)}catch(a){n.emit("error",a)}}),n}open(){this.filename&&(this._opening||(this._opening=!0,this.stat((e,r)=>{if(e)return this.emit("error",e);xe("stat done: %s { size: %s }",this.filename,r),this._size=r,this._dest=this._createStream(this._stream),this._opening=!1,this.once("open",()=>{this._stream.emit("rotate")||(this._rotate=!1)})})))}stat(e){let r=this._getFile(),n=fe.join(this.dirname,r);be.stat(n,(i,o)=>{if(i&&i.code==="ENOENT")return xe("ENOENT\xA0ok",n),this.filename=r,e(null,0);if(i)return xe(`err ${i.code} ${n}`),e(i);if(!o||this._needsNewFile(o.size))return this._incFile(()=>this.stat(e));this.filename=r,e(null,o.size)})}close(e){this._stream&&this._stream.end(()=>{e&&e(),this.emit("flush"),this.emit("closed")})}_needsNewFile(e){return e=e||this._size,this.maxsize&&e>=this.maxsize}_onError(e){this.emit("error",e)}_setupStream(e){return e.on("error",this._onError),e}_cleanupStream(e){return e.removeListener("error",this._onError),e.destroy(),e}_rotateFile(){this._incFile(()=>this.open())}_endStream(e=()=>{}){this._dest?(this._stream.unpipe(this._dest),this._dest.end(()=>{this._cleanupStream(this._dest),e()})):e()}_createStream(e){let r=fe.join(this.dirname,this.filename);xe("create stream start",r,this.options);let n=be.createWriteStream(r,this.options).on("error",i=>xe(i)).on("close",()=>xe("close",n.path,n.bytesWritten)).on("open",()=>{xe("file open ok",r),this.emit("open",r),e.pipe(n),this.rotatedWhileOpening&&(this._stream=new eh,this._stream.setMaxListeners(30),this._rotateFile(),this.rotatedWhileOpening=!1,this._cleanupStream(n),e.end())});return xe("create stream ok",r),n}_incFile(e){xe("_incFile",this.filename);let r=fe.extname(this._basename),n=fe.basename(this._basename,r),i=[];this.zippedArchive&&i.push(function(o){let s=this._created>0&&!this.tailable?this._created:"";this._compressFile(fe.join(this.dirname,`${n}${s}${r}`),fe.join(this.dirname,`${n}${s}${r}.gz`),o)}.bind(this)),i.push(function(o){this.tailable?this._checkMaxFilesTailable(r,n,o):(this._created+=1,this._checkMaxFilesIncrementing(r,n,o))}.bind(this)),Zc(i,e)}_getFile(){let e=fe.extname(this._basename),r=fe.basename(this._basename,e),n=this.rotationFormat?this.rotationFormat():this._created;return!this.tailable&&this._created?`${r}${n}${e}`:`${r}${e}`}_checkMaxFilesIncrementing(e,r,n){if(!this.maxFiles||this._created<this.maxFiles)return setImmediate(n);let i=this._created-this.maxFiles,o=i!==0?i:"",s=this.zippedArchive?".gz":"",a=`${r}${o}${e}${s}`,u=fe.join(this.dirname,a);be.unlink(u,n)}_checkMaxFilesTailable(e,r,n){let i=[];if(!this.maxFiles)return;let o=this.zippedArchive?".gz":"";for(let s=this.maxFiles-1;s>1;s--)i.push(function(a,u){let d=`${r}${a-1}${e}${o}`,w=fe.join(this.dirname,d);be.exists(w,E=>{if(!E)return u(null);d=`${r}${a}${e}${o}`,be.rename(w,fe.join(this.dirname,d),u)})}.bind(this,s));Zc(i,()=>{be.rename(fe.join(this.dirname,`${r}${e}${o}`),fe.join(this.dirname,`${r}1${e}${o}`),n)})}_compressFile(e,r,n){be.access(e,be.F_OK,i=>{if(i)return n();var o=xE.createGzip(),s=be.createReadStream(e),a=be.createWriteStream(r);a.on("finish",()=>{be.unlink(e,n)}),s.pipe(o).pipe(a)})}_createLogDirIfNotExist(e){be.existsSync(e)||be.mkdirSync(e,{recursive:!0})}}});var ih=S((gP,nh)=>{"use strict";var AE=require("http"),LE=require("https"),{Stream:CE}=Et(),qE=qt(),{configure:FE}=or();nh.exports=class extends qE{constructor(e={}){super(e),this.options=e,this.name=e.name||"http",this.ssl=!!e.ssl,this.host=e.host||"localhost",this.port=e.port,this.auth=e.auth,this.path=e.path||"",this.maximumDepth=e.maximumDepth,this.agent=e.agent,this.headers=e.headers||{},this.headers["content-type"]="application/json",this.batch=e.batch||!1,this.batchInterval=e.batchInterval||5e3,this.batchCount=e.batchCount||10,this.batchOptions=[],this.batchTimeoutID=-1,this.batchCallback={},this.port||(this.port=this.ssl?443:80)}log(e,r){this._request(e,null,null,(n,i)=>{i&&i.statusCode!==200&&(n=new Error(`Invalid HTTP Status Code: ${i.statusCode}`)),n?this.emit("warn",n):this.emit("logged",e)}),r&&setImmediate(r)}query(e,r){typeof e=="function"&&(r=e,e={}),e={method:"query",params:this.normalizeQuery(e)};let n=e.params.auth||null;delete e.params.auth;let i=e.params.path||null;delete e.params.path,this._request(e,n,i,(o,s,a)=>{if(s&&s.statusCode!==200&&(o=new Error(`Invalid HTTP Status Code: ${s.statusCode}`)),o)return r(o);if(typeof a=="string")try{a=JSON.parse(a)}catch(u){return r(u)}r(null,a)})}stream(e={}){let r=new CE;e={method:"stream",params:e};let n=e.params.path||null;delete e.params.path;let i=e.params.auth||null;delete e.params.auth;let o="",s=this._request(e,i,n);return r.destroy=()=>s.destroy(),s.on("data",a=>{a=(o+a).split(/\n+/);let u=a.length-1,d=0;for(;d<u;d++)try{r.emit("log",JSON.parse(a[d]))}catch(w){r.emit("error",w)}o=a[u]}),s.on("error",a=>r.emit("error",a)),r}_request(e,r,n,i){e=e||{},r=r||this.auth,n=n||this.path||"",this.batch?this._doBatch(e,i,r,n):this._doRequest(e,i,r,n)}_doBatch(e,r,n,i){if(this.batchOptions.push(e),this.batchOptions.length===1){let o=this;this.batchCallback=r,this.batchTimeoutID=setTimeout(function(){o.batchTimeoutID=-1,o._doBatchRequest(o.batchCallback,n,i)},this.batchInterval)}this.batchOptions.length===this.batchCount&&this._doBatchRequest(this.batchCallback,n,i)}_doBatchRequest(e,r,n){this.batchTimeoutID>0&&(clearTimeout(this.batchTimeoutID),this.batchTimeoutID=-1);let i=this.batchOptions.slice();this.batchOptions=[],this._doRequest(i,e,r,n)}_doRequest(e,r,n,i){let o=Object.assign({},this.headers);n&&n.bearer&&(o.Authorization=`Bearer ${n.bearer}`);let s=(this.ssl?LE:AE).request({...this.options,method:"POST",host:this.host,port:this.port,path:`/${i.replace(/^\//,"")}`,headers:o,auth:n&&n.username&&n.password?`${n.username}:${n.password}`:"",agent:this.agent});s.on("error",r),s.on("response",u=>u.on("end",()=>r(null,u)).resume());let a=FE({...this.maximumDepth&&{maximumDepth:this.maximumDepth}});s.end(Buffer.from(a(e,this.options.replacer),"utf8"))}}});var js=S((yP,oh)=>{"use strict";var Ae=t=>t!==null&&typeof t=="object"&&typeof t.pipe=="function";Ae.writable=t=>Ae(t)&&t.writable!==!1&&typeof t._write=="function"&&typeof t._writableState=="object";Ae.readable=t=>Ae(t)&&t.readable!==!1&&typeof t._read=="function"&&typeof t._readableState=="object";Ae.duplex=t=>Ae.writable(t)&&Ae.readable(t);Ae.transform=t=>Ae.duplex(t)&&typeof t._transform=="function";oh.exports=Ae});var ah=S((wP,sh)=>{"use strict";var jE=js(),{MESSAGE:kE}=ne(),BE=require("os"),$E=qt();sh.exports=class extends $E{constructor(e={}){if(super(e),!e.stream||!jE(e.stream))throw new Error("options.stream is required.");this._stream=e.stream,this._stream.setMaxListeners(1/0),this.isObjectMode=e.stream._writableState.objectMode,this.eol=typeof e.eol=="string"?e.eol:BE.EOL}log(e,r){if(setImmediate(()=>this.emit("logged",e)),this.isObjectMode){this._stream.write(e),r&&r();return}this._stream.write(`${e[kE]}${this.eol}`),r&&r()}}});var uh=S(Ir=>{"use strict";Object.defineProperty(Ir,"Console",{configurable:!0,enumerable:!0,get(){return Kl()}});Object.defineProperty(Ir,"File",{configurable:!0,enumerable:!0,get(){return rh()}});Object.defineProperty(Ir,"Http",{configurable:!0,enumerable:!0,get(){return ih()}});Object.defineProperty(Ir,"Stream",{configurable:!0,enumerable:!0,get(){return ah()}})});var li=S(Mr=>{"use strict";var ui=wo(),{configs:ks}=ne();Mr.cli=ui.levels(ks.cli);Mr.npm=ui.levels(ks.npm);Mr.syslog=ui.levels(ks.syslog);Mr.addColors=ui.levels});var fh=S((fi,lh)=>{"use strict";Object.defineProperty(fi,"__esModule",{value:!0});var UE=Mn(),VE=St(UE),HE=Bn(),WE=St(HE),XE=rs(),KE=St(XE),GE=Zo(),YE=St(GE),zE=es(),JE=St(zE),QE=yt(),ZE=St(QE),e1=jt(),t1=St(e1);function St(t){return t&&t.__esModule?t:{default:t}}function r1(t,e,r){r=(0,YE.default)(r);var n=0,i=0,{length:o}=t,s=!1;o===0&&r(null);function a(u,d){u===!1&&(s=!0),s!==!0&&(u?r(u):(++i===o||d===WE.default)&&r(null))}for(;n<o;n++)e(t[n],n,(0,JE.default)(a))}function n1(t,e,r){return(0,KE.default)(t,1/0,e,r)}function i1(t,e,r){var n=(0,VE.default)(t)?r1:n1;return n(t,(0,ZE.default)(e),r)}fi.default=(0,t1.default)(i1,3);lh.exports=fi.default});var hh=S((ci,ch)=>{"use strict";Object.defineProperty(ci,"__esModule",{value:!0});ci.default=o1;function o1(t){return(e,r,n)=>t(e,n)}ch.exports=ci.default});var pi=S((di,dh)=>{"use strict";Object.defineProperty(di,"__esModule",{value:!0});var s1=fh(),a1=hi(s1),u1=hh(),l1=hi(u1),f1=yt(),c1=hi(f1),h1=jt(),d1=hi(h1);function hi(t){return t&&t.__esModule?t:{default:t}}function p1(t,e,r){return(0,a1.default)(t,(0,l1.default)((0,c1.default)(e)),r)}di.default=(0,d1.default)(p1,3);dh.exports=di.default});var mh=S((EP,ph)=>{"use strict";var m1=Object.prototype.toString;ph.exports=function(e){if(typeof e.displayName=="string"&&e.constructor.name)return e.displayName;if(typeof e.name=="string"&&e.name)return e.name;if(typeof e=="object"&&e.constructor&&typeof e.constructor.name=="string")return e.constructor.name;var r=e.toString(),n=m1.call(e).slice(8,-1);return n==="Function"?r=r.substring(r.indexOf("(")+1,r.indexOf(")")):r=n,r||"anonymous"}});var Bs=S((SP,gh)=>{"use strict";var g1=mh();gh.exports=function(e){var r=0,n;function i(){return r||(r=1,n=e.apply(this,arguments),e=null),n}return i.displayName=g1(e),i}});var $s=S(Rr=>{"use strict";Rr.get=function(t){var e=Error.stackTraceLimit;Error.stackTraceLimit=1/0;var r={},n=Error.prepareStackTrace;Error.prepareStackTrace=function(o,s){return s},Error.captureStackTrace(r,t||Rr.get);var i=r.stack;return Error.prepareStackTrace=n,Error.stackTraceLimit=e,i};Rr.parse=function(t){if(!t.stack)return[];var e=this,r=t.stack.split(`
|
|
27
|
-
`).slice(1);return r.map(function(n){if(n.match(/^\s*[-]{4,}$/))return
|
|
28
|
-
`),stack:
|
|
29
|
-
`),stack:
|
|
30
|
-
`));
|
|
31
|
-
`))}_onEvent(
|
|
32
|
-
`){
|
|
33
|
-
`;break}else if(
|
|
34
|
-
`){
|
|
35
|
-
`;break}}return
|
|
36
|
-
`}});var
|
|
37
|
-
`))}return{rowsCells:r,partial:n}},t})();Kt.RowSplit=uS});var Qs=S(jr=>{"use strict";var lS=jr&&jr.__extends||(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(n[o]=i[o])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})();Object.defineProperty(jr,"__esModule",{value:!0});var fS=(function(t){lS(e,t);function e(r,n,i){var o=t.call(this,"Error: "+r+". JSON Line number: "+n+(i?" near: "+i:""))||this;return o.err=r,o.line=n,o.extra=i,o.name="CSV Parse Error",o}return e.column_mismatched=function(r,n){return new e("column_mismatched",r,n)},e.unclosed_quote=function(r,n){return new e("unclosed_quote",r,n)},e.fromJSON=function(r){return new e(r.err,r.line,r.extra)},e.prototype.toJSON=function(){return{err:this.err,line:this.line,extra:this.extra}},e})(Error);jr.default=fS});var Xh=S((JP,Wh)=>{"use strict";var cS=typeof global=="object"&&global&&global.Object===Object&&global;Wh.exports=cS});var wi=S((QP,Kh)=>{"use strict";var hS=Xh(),dS=typeof self=="object"&&self&&self.Object===Object&&self,pS=hS||dS||Function("return this")();Kh.exports=pS});var _i=S((ZP,Gh)=>{"use strict";var mS=wi(),gS=mS.Symbol;Gh.exports=gS});var Qh=S((eI,Jh)=>{"use strict";var Yh=_i(),zh=Object.prototype,yS=zh.hasOwnProperty,bS=zh.toString,kr=Yh?Yh.toStringTag:void 0;function wS(t){var e=yS.call(t,kr),r=t[kr];try{t[kr]=void 0;var n=!0}catch{}var i=bS.call(t);return n&&(e?t[kr]=r:delete t[kr]),i}Jh.exports=wS});var ed=S((tI,Zh)=>{"use strict";var _S=Object.prototype,vS=_S.toString;function ES(t){return vS.call(t)}Zh.exports=ES});var Zs=S((rI,nd)=>{"use strict";var td=_i(),SS=Qh(),TS=ed(),OS="[object Null]",DS="[object Undefined]",rd=td?td.toStringTag:void 0;function xS(t){return t==null?t===void 0?DS:OS:rd&&rd in Object(t)?SS(t):TS(t)}nd.exports=xS});var vi=S((nI,id)=>{"use strict";function PS(t){var e=typeof t;return t!=null&&(e=="object"||e=="function")}id.exports=PS});var sd=S((iI,od)=>{"use strict";var IS=Zs(),MS=vi(),NS="[object AsyncFunction]",RS="[object Function]",AS="[object GeneratorFunction]",LS="[object Proxy]";function CS(t){if(!MS(t))return!1;var e=IS(t);return e==RS||e==AS||e==NS||e==LS}od.exports=CS});var ud=S((oI,ad)=>{"use strict";var qS=wi(),FS=qS["__core-js_shared__"];ad.exports=FS});var cd=S((sI,fd)=>{"use strict";var ea=ud(),ld=(function(){var t=/[^.]+$/.exec(ea&&ea.keys&&ea.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""})();function jS(t){return!!ld&&ld in t}fd.exports=jS});var dd=S((aI,hd)=>{"use strict";var kS=Function.prototype,BS=kS.toString;function $S(t){if(t!=null){try{return BS.call(t)}catch{}try{return t+""}catch{}}return""}hd.exports=$S});var md=S((uI,pd)=>{"use strict";var US=sd(),VS=cd(),HS=vi(),WS=dd(),XS=/[\\^$.*+?()[\]{}|]/g,KS=/^\[object .+?Constructor\]$/,GS=Function.prototype,YS=Object.prototype,zS=GS.toString,JS=YS.hasOwnProperty,QS=RegExp("^"+zS.call(JS).replace(XS,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function ZS(t){if(!HS(t)||VS(t))return!1;var e=US(t)?QS:KS;return e.test(WS(t))}pd.exports=ZS});var yd=S((lI,gd)=>{"use strict";function eT(t,e){return t?.[e]}gd.exports=eT});var Ei=S((fI,bd)=>{"use strict";var tT=md(),rT=yd();function nT(t,e){var r=rT(t,e);return tT(r)?r:void 0}bd.exports=nT});var _d=S((cI,wd)=>{"use strict";var iT=Ei(),oT=(function(){try{var t=iT(Object,"defineProperty");return t({},"",{}),t}catch{}})();wd.exports=oT});var Sd=S((hI,Ed)=>{"use strict";var vd=_d();function sT(t,e,r){e=="__proto__"&&vd?vd(t,e,{configurable:!0,enumerable:!0,value:r,writable:!0}):t[e]=r}Ed.exports=sT});var ta=S((dI,Td)=>{"use strict";function aT(t,e){return t===e||t!==t&&e!==e}Td.exports=aT});var Dd=S((pI,Od)=>{"use strict";var uT=Sd(),lT=ta(),fT=Object.prototype,cT=fT.hasOwnProperty;function hT(t,e,r){var n=t[e];(!(cT.call(t,e)&&lT(n,r))||r===void 0&&!(e in t))&&uT(t,e,r)}Od.exports=hT});var Si=S((mI,xd)=>{"use strict";var dT=Array.isArray;xd.exports=dT});var Id=S((gI,Pd)=>{"use strict";function pT(t){return t!=null&&typeof t=="object"}Pd.exports=pT});var Ti=S((yI,Md)=>{"use strict";var mT=Zs(),gT=Id(),yT="[object Symbol]";function bT(t){return typeof t=="symbol"||gT(t)&&mT(t)==yT}Md.exports=bT});var Rd=S((bI,Nd)=>{"use strict";var wT=Si(),_T=Ti(),vT=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,ET=/^\w*$/;function ST(t,e){if(wT(t))return!1;var r=typeof t;return r=="number"||r=="symbol"||r=="boolean"||t==null||_T(t)?!0:ET.test(t)||!vT.test(t)||e!=null&&t in Object(e)}Nd.exports=ST});var Br=S((wI,Ad)=>{"use strict";var TT=Ei(),OT=TT(Object,"create");Ad.exports=OT});var qd=S((_I,Cd)=>{"use strict";var Ld=Br();function DT(){this.__data__=Ld?Ld(null):{},this.size=0}Cd.exports=DT});var jd=S((vI,Fd)=>{"use strict";function xT(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e}Fd.exports=xT});var Bd=S((EI,kd)=>{"use strict";var PT=Br(),IT="__lodash_hash_undefined__",MT=Object.prototype,NT=MT.hasOwnProperty;function RT(t){var e=this.__data__;if(PT){var r=e[t];return r===IT?void 0:r}return NT.call(e,t)?e[t]:void 0}kd.exports=RT});var Ud=S((SI,$d)=>{"use strict";var AT=Br(),LT=Object.prototype,CT=LT.hasOwnProperty;function qT(t){var e=this.__data__;return AT?e[t]!==void 0:CT.call(e,t)}$d.exports=qT});var Hd=S((TI,Vd)=>{"use strict";var FT=Br(),jT="__lodash_hash_undefined__";function kT(t,e){var r=this.__data__;return this.size+=this.has(t)?0:1,r[t]=FT&&e===void 0?jT:e,this}Vd.exports=kT});var Xd=S((OI,Wd)=>{"use strict";var BT=qd(),$T=jd(),UT=Bd(),VT=Ud(),HT=Hd();function Gt(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}Gt.prototype.clear=BT;Gt.prototype.delete=$T;Gt.prototype.get=UT;Gt.prototype.has=VT;Gt.prototype.set=HT;Wd.exports=Gt});var Gd=S((DI,Kd)=>{"use strict";function WT(){this.__data__=[],this.size=0}Kd.exports=WT});var $r=S((xI,Yd)=>{"use strict";var XT=ta();function KT(t,e){for(var r=t.length;r--;)if(XT(t[r][0],e))return r;return-1}Yd.exports=KT});var Jd=S((PI,zd)=>{"use strict";var GT=$r(),YT=Array.prototype,zT=YT.splice;function JT(t){var e=this.__data__,r=GT(e,t);if(r<0)return!1;var n=e.length-1;return r==n?e.pop():zT.call(e,r,1),--this.size,!0}zd.exports=JT});var Zd=S((II,Qd)=>{"use strict";var QT=$r();function ZT(t){var e=this.__data__,r=QT(e,t);return r<0?void 0:e[r][1]}Qd.exports=ZT});var tp=S((MI,ep)=>{"use strict";var eO=$r();function tO(t){return eO(this.__data__,t)>-1}ep.exports=tO});var np=S((NI,rp)=>{"use strict";var rO=$r();function nO(t,e){var r=this.__data__,n=rO(r,t);return n<0?(++this.size,r.push([t,e])):r[n][1]=e,this}rp.exports=nO});var op=S((RI,ip)=>{"use strict";var iO=Gd(),oO=Jd(),sO=Zd(),aO=tp(),uO=np();function Yt(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}Yt.prototype.clear=iO;Yt.prototype.delete=oO;Yt.prototype.get=sO;Yt.prototype.has=aO;Yt.prototype.set=uO;ip.exports=Yt});var ap=S((AI,sp)=>{"use strict";var lO=Ei(),fO=wi(),cO=lO(fO,"Map");sp.exports=cO});var fp=S((LI,lp)=>{"use strict";var up=Xd(),hO=op(),dO=ap();function pO(){this.size=0,this.__data__={hash:new up,map:new(dO||hO),string:new up}}lp.exports=pO});var hp=S((CI,cp)=>{"use strict";function mO(t){var e=typeof t;return e=="string"||e=="number"||e=="symbol"||e=="boolean"?t!=="__proto__":t===null}cp.exports=mO});var Ur=S((qI,dp)=>{"use strict";var gO=hp();function yO(t,e){var r=t.__data__;return gO(e)?r[typeof e=="string"?"string":"hash"]:r.map}dp.exports=yO});var mp=S((FI,pp)=>{"use strict";var bO=Ur();function wO(t){var e=bO(this,t).delete(t);return this.size-=e?1:0,e}pp.exports=wO});var yp=S((jI,gp)=>{"use strict";var _O=Ur();function vO(t){return _O(this,t).get(t)}gp.exports=vO});var wp=S((kI,bp)=>{"use strict";var EO=Ur();function SO(t){return EO(this,t).has(t)}bp.exports=SO});var vp=S((BI,_p)=>{"use strict";var TO=Ur();function OO(t,e){var r=TO(this,t),n=r.size;return r.set(t,e),this.size+=r.size==n?0:1,this}_p.exports=OO});var Sp=S(($I,Ep)=>{"use strict";var DO=fp(),xO=mp(),PO=yp(),IO=wp(),MO=vp();function zt(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}zt.prototype.clear=DO;zt.prototype.delete=xO;zt.prototype.get=PO;zt.prototype.has=IO;zt.prototype.set=MO;Ep.exports=zt});var Dp=S((UI,Op)=>{"use strict";var Tp=Sp(),NO="Expected a function";function ra(t,e){if(typeof t!="function"||e!=null&&typeof e!="function")throw new TypeError(NO);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(ra.Cache||Tp),r}ra.Cache=Tp;Op.exports=ra});var Pp=S((VI,xp)=>{"use strict";var RO=Dp(),AO=500;function LO(t){var e=RO(t,function(n){return r.size===AO&&r.clear(),n}),r=e.cache;return e}xp.exports=LO});var Mp=S((HI,Ip)=>{"use strict";var CO=Pp(),qO=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,FO=/\\(\\)?/g,jO=CO(function(t){var e=[];return t.charCodeAt(0)===46&&e.push(""),t.replace(qO,function(r,n,i,o){e.push(i?o.replace(FO,"$1"):n||r)}),e});Ip.exports=jO});var Rp=S((WI,Np)=>{"use strict";function kO(t,e){for(var r=-1,n=t==null?0:t.length,i=Array(n);++r<n;)i[r]=e(t[r],r,t);return i}Np.exports=kO});var jp=S((XI,Fp)=>{"use strict";var Ap=_i(),BO=Rp(),$O=Si(),UO=Ti(),VO=1/0,Lp=Ap?Ap.prototype:void 0,Cp=Lp?Lp.toString:void 0;function qp(t){if(typeof t=="string")return t;if($O(t))return BO(t,qp)+"";if(UO(t))return Cp?Cp.call(t):"";var e=t+"";return e=="0"&&1/t==-VO?"-0":e}Fp.exports=qp});var Bp=S((KI,kp)=>{"use strict";var HO=jp();function WO(t){return t==null?"":HO(t)}kp.exports=WO});var Up=S((GI,$p)=>{"use strict";var XO=Si(),KO=Rd(),GO=Mp(),YO=Bp();function zO(t,e){return XO(t)?t:KO(t,e)?[t]:GO(YO(t))}$p.exports=zO});var Hp=S((YI,Vp)=>{"use strict";var JO=9007199254740991,QO=/^(?:0|[1-9]\d*)$/;function ZO(t,e){var r=typeof t;return e=e??JO,!!e&&(r=="number"||r!="symbol"&&QO.test(t))&&t>-1&&t%1==0&&t<e}Vp.exports=ZO});var Xp=S((zI,Wp)=>{"use strict";var e2=Ti(),t2=1/0;function r2(t){if(typeof t=="string"||e2(t))return t;var e=t+"";return e=="0"&&1/t==-t2?"-0":e}Wp.exports=r2});var Yp=S((JI,Gp)=>{"use strict";var n2=Dd(),i2=Up(),o2=Hp(),Kp=vi(),s2=Xp();function a2(t,e,r,n){if(!Kp(t))return t;e=i2(e,t);for(var i=-1,o=e.length,s=o-1,a=t;a!=null&&++i<o;){var u=s2(e[i]),d=r;if(u==="__proto__"||u==="constructor"||u==="prototype")return t;if(i!=s){var w=a[u];d=n?n(w,u,a):void 0,d===void 0&&(d=Kp(w)?w:o2(e[i+1])?[]:{})}n2(a,u,d),a=a[u]}return t}Gp.exports=a2});var Jp=S((QI,zp)=>{"use strict";var u2=Yp();function l2(t,e,r){return t==null?t:u2(t,e,r)}zp.exports=l2});var em=S(Hr=>{"use strict";var Zp=Hr&&Hr.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(Hr,"__esModule",{value:!0});Hr.default=d2;var f2=Zp(Qs()),c2=Zp(Jp()),h2=/^[-+]?[0-9]*\.?[0-9]+([eE][-+]?[0-9]+)?$/;function d2(t,e){for(var r=[],n=0,i=t.length;n<i;n++){var o=p2(t[n],e,n);o&&r.push(o)}return r}function p2(t,e,r){if(e.parseParam.checkColumn&&e.parseRuntime.headers&&t.length!==e.parseRuntime.headers.length)throw f2.default.column_mismatched(e.parseRuntime.parsedLineNumber+r);var n=e.parseRuntime.headers||[],i=m2(t,n,e);return i||null}function m2(t,e,r){for(var n=!1,i={},o=0,s=t.length;o<s;o++){var a=t[o];if(!(r.parseParam.ignoreEmpty&&a==="")){n=!0;var u=e[o];(!u||u==="")&&(u=e[o]="field"+(o+1));var d=y2(u,o,r);if(d){var w=d(a,u,i,t,o);w!==void 0&&Qp(i,u,w,r,o)}else{if(r.parseParam.checkType){var E=w2(a,u,o,r);a=E(a)}a!==void 0&&Qp(i,u,a,r,o)}}}return n?i:null}var g2={string:Vr,number:ia,omit:function(){}};function y2(t,e,r){if(r.parseRuntime.columnConv[e]!==void 0)return r.parseRuntime.columnConv[e];var n=r.parseParam.colParser[t];if(n===void 0)return r.parseRuntime.columnConv[e]=null;if(typeof n=="object"&&(n=n.cellParser||"string"),typeof n=="string"){n=n.trim().toLowerCase();var i=g2[n];return i?r.parseRuntime.columnConv[e]=i:r.parseRuntime.columnConv[e]=null}else return typeof n=="function"?r.parseRuntime.columnConv[e]=n:r.parseRuntime.columnConv[e]=null}function Qp(t,e,r,n,i){if(!n.parseRuntime.columnValueSetter[i])if(n.parseParam.flatKeys)n.parseRuntime.columnValueSetter[i]=na;else if(e.indexOf(".")>-1){for(var o=e.split("."),s=!0;o.length>0;){var a=o.shift();if(a.length===0){s=!1;break}}!s||n.parseParam.colParser[e]&&n.parseParam.colParser[e].flat?n.parseRuntime.columnValueSetter[i]=na:n.parseRuntime.columnValueSetter[i]=b2}else n.parseRuntime.columnValueSetter[i]=na;n.parseParam.nullObject===!0&&r==="null"&&(r=null),n.parseRuntime.columnValueSetter[i](t,e,r)}function na(t,e,r){t[e]=r}function b2(t,e,r){(0,c2.default)(t,e,r)}function w2(t,e,r,n){return n.parseRuntime.headerType[r]?n.parseRuntime.headerType[r]:e.indexOf("number#!")>-1?n.parseRuntime.headerType[r]=ia:e.indexOf("string#!")>-1?n.parseRuntime.headerType[r]=Vr:n.parseParam.checkType?n.parseRuntime.headerType[r]=_2:n.parseRuntime.headerType[r]=Vr}function ia(t){var e=parseFloat(t);return isNaN(e)?t:e}function Vr(t){return t.toString()}function _2(t){var e=t.trim();return e===""?Vr(t):h2.test(e)?ia(t):e.length===5&&e.toLowerCase()==="false"||e.length===4&&e.toLowerCase()==="true"?v2(t):e[0]==="{"&&e[e.length-1]==="}"||e[0]==="["&&e[e.length-1]==="]"?E2(t):Vr(t)}function v2(t){var e=t.trim();return!(e.length===5&&e.toLowerCase()==="false")}function E2(t){try{return JSON.parse(t)}catch{return t}}});var nm=S(st=>{"use strict";var S2=st&&st.__extends||(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(n[o]=i[o])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})(),oa=st&&st.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(st,"__esModule",{value:!0});st.ProcessorLocal=void 0;var T2=$h(),O2=Uh(),tm=oa(bi()),D2=Vh(),Wr=Js(),x2=Hh(),P2=oa(em()),I2=oa(Qs()),M2=(function(t){S2(e,t);function e(){var r=t!==null&&t.apply(this,arguments)||this;return r.rowSplit=new x2.RowSplit(r.converter),r.eolEmitted=!1,r._needEmitEol=void 0,r.headEmitted=!1,r._needEmitHead=void 0,r}return e.prototype.flush=function(){var r=this;if(this.runtime.csvLineBuffer&&this.runtime.csvLineBuffer.length>0){var n=this.runtime.csvLineBuffer;return this.runtime.csvLineBuffer=void 0,this.process(n,!0).then(function(i){return r.runtime.csvLineBuffer&&r.runtime.csvLineBuffer.length>0?Promise.reject(I2.default.unclosed_quote(r.runtime.parsedLineNumber,r.runtime.csvLineBuffer.toString())):Promise.resolve(i)})}else return Promise.resolve([])},e.prototype.destroy=function(){return Promise.resolve()},Object.defineProperty(e.prototype,"needEmitEol",{get:function(){return this._needEmitEol===void 0&&(this._needEmitEol=this.converter.listeners("eol").length>0),this._needEmitEol},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"needEmitHead",{get:function(){return this._needEmitHead===void 0&&(this._needEmitHead=this.converter.listeners("header").length>0),this._needEmitHead},enumerable:!1,configurable:!0}),e.prototype.process=function(r,n){var i=this;n===void 0&&(n=!1);var o;return n?o=r.toString():o=(0,O2.prepareData)(r,this.converter.parseRuntime),Promise.resolve().then(function(){return i.runtime.preRawDataHook?i.runtime.preRawDataHook(o):o}).then(function(s){return s&&s.length>0?i.processCSV(s,n):Promise.resolve([])})},e.prototype.processCSV=function(r,n){var i=this,o=this.params,s=this.runtime;s.eol||(0,tm.default)(r,s),this.needEmitEol&&!this.eolEmitted&&s.eol&&(this.converter.emit("eol",s.eol),this.eolEmitted=!0),o.ignoreEmpty&&!s.started&&(r=(0,Wr.trimLeft)(r));var a=(0,D2.stringToLines)(r,s);if(n?(a.lines.push(a.partial),a.partial=""):this.prependLeftBuf((0,Wr.bufFromString)(a.partial)),a.lines.length>0){var u=void 0;return s.preFileLineHook?u=this.runPreLineHook(a.lines):u=Promise.resolve(a.lines),u.then(function(d){return!s.started&&!i.runtime.headers?i.processDataWithHead(d):i.processCSVBody(d)})}else return Promise.resolve([])},e.prototype.processDataWithHead=function(r){if(this.params.noheader)this.params.headers?this.runtime.headers=this.params.headers:this.runtime.headers=[];else{for(var n="",i=[];r.length;){var o=n+r.shift(),s=this.rowSplit.parse(o);if(s.closed){i=s.cells,n="";break}else n=o+(0,tm.default)(o,this.runtime)}if(this.prependLeftBuf((0,Wr.bufFromString)(n)),i.length===0)return[];this.params.headers?this.runtime.headers=this.params.headers:this.runtime.headers=i}return(this.runtime.needProcessIgnoreColumn||this.runtime.needProcessIncludeColumn)&&this.filterHeader(),this.needEmitHead&&!this.headEmitted&&(this.converter.emit("header",this.runtime.headers),this.headEmitted=!0),this.processCSVBody(r)},e.prototype.filterHeader=function(){if(this.runtime.selectedColumns=[],this.runtime.headers){for(var r=this.runtime.headers,n=0;n<r.length;n++)if(this.params.ignoreColumns)if(this.params.ignoreColumns.test(r[n]))if(this.params.includeColumns&&this.params.includeColumns.test(r[n]))this.runtime.selectedColumns.push(n);else continue;else this.runtime.selectedColumns.push(n);else this.params.includeColumns?this.params.includeColumns.test(r[n])&&this.runtime.selectedColumns.push(n):this.runtime.selectedColumns.push(n);this.runtime.headers=(0,Wr.filterArray)(this.runtime.headers,this.runtime.selectedColumns)}},e.prototype.processCSVBody=function(r){if(this.params.output==="line")return r;var n=this.rowSplit.parseMultiLines(r);return this.prependLeftBuf((0,Wr.bufFromString)(n.partial)),this.params.output==="csv"?n.rowsCells:(0,P2.default)(n.rowsCells,this.converter)},e.prototype.prependLeftBuf=function(r){r&&(this.runtime.csvLineBuffer?this.runtime.csvLineBuffer=Buffer.concat([r,this.runtime.csvLineBuffer]):this.runtime.csvLineBuffer=r)},e.prototype.runPreLineHook=function(r){var n=this;return new Promise(function(i,o){rm(r,n.runtime,0,function(s){s?o(s):i(r)})})},e})(T2.Processor);st.ProcessorLocal=M2;function rm(t,e,r,n){if(r>=t.length)n();else if(e.preFileLineHook){var i=t[r],o=e.preFileLineHook(i,e.parsedLineNumber+r);if(r++,o&&o.then)o.then(function(s){t[r-1]=s,rm(t,e,r,n)});else{for(t[r-1]=o;r<t.length;)t[r]=e.preFileLineHook(t[r],e.parsedLineNumber+r),r++;n()}}else n()}});var om=S(Di=>{"use strict";Object.defineProperty(Di,"__esModule",{value:!0});Di.Result=void 0;var Oi=require("os"),N2=(function(){function t(e){this.converter=e,this.finalResult=[]}return Object.defineProperty(t.prototype,"needEmitLine",{get:function(){return!!this.converter.parseRuntime.subscribe&&!!this.converter.parseRuntime.subscribe.onNext||this.needPushDownstream},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"needPushDownstream",{get:function(){return this._needPushDownstream===void 0&&(this._needPushDownstream=this.converter.listeners("data").length>0||this.converter.listeners("readable").length>0),this._needPushDownstream},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"needEmitAll",{get:function(){return!!this.converter.parseRuntime.then&&this.converter.parseParam.needEmitAll},enumerable:!1,configurable:!0}),t.prototype.processResult=function(e){var r=this,n=this.converter.parseRuntime.parsedLineNumber;return this.needPushDownstream&&this.converter.parseParam.downstreamFormat==="array"&&n===0&&Jt(this.converter,"["+Oi.EOL),new Promise(function(i,o){r.needEmitLine?im(e,r.converter,0,r.needPushDownstream,function(s){s?o(s):(r.appendFinalResult(e),i(void 0))}):(r.appendFinalResult(e),i(void 0))})},t.prototype.appendFinalResult=function(e){this.needEmitAll&&(this.finalResult=this.finalResult.concat(e)),this.converter.parseRuntime.parsedLineNumber+=e.length},t.prototype.processError=function(e){this.converter.parseRuntime.subscribe&&this.converter.parseRuntime.subscribe.onError&&this.converter.parseRuntime.subscribe.onError(e),this.converter.parseRuntime.then&&this.converter.parseRuntime.then.onrejected&&this.converter.parseRuntime.then.onrejected(e)},t.prototype.endProcess=function(){this.converter.parseRuntime.then&&this.converter.parseRuntime.then.onfulfilled&&(this.needEmitAll?this.converter.parseRuntime.then.onfulfilled(this.finalResult):this.converter.parseRuntime.then.onfulfilled([])),this.converter.parseRuntime.subscribe&&this.converter.parseRuntime.subscribe.onCompleted&&this.converter.parseRuntime.subscribe.onCompleted(),this.needPushDownstream&&this.converter.parseParam.downstreamFormat==="array"&&Jt(this.converter,"]"+Oi.EOL)},t})();Di.Result=N2;function im(t,e,r,n,i){if(r>=t.length)i();else if(e.parseRuntime.subscribe&&e.parseRuntime.subscribe.onNext){var o=e.parseRuntime.subscribe.onNext,s=t[r],a=o(s,e.parseRuntime.parsedLineNumber+r);if(r++,a&&a.then)a.then(function(){R2(t,o,e,r,n,i,s)},i);else{for(n&&Jt(e,s);r<t.length;){var u=t[r];o(u,e.parseRuntime.parsedLineNumber+r),r++,n&&Jt(e,u)}i()}}else{if(n)for(;r<t.length;){var u=t[r++];Jt(e,u)}i()}}function R2(t,e,r,n,i,o,s){i&&Jt(r,s),im(t,r,n,i,o)}function Jt(t,e){if(typeof e=="object"&&!t.options.objectMode){var r=JSON.stringify(e);t.push(r+(t.parseParam.downstreamFormat==="array"?","+Oi.EOL:Oi.EOL),"utf8")}else t.push(e)}});var am=S(Qt=>{"use strict";var A2=Qt&&Qt.__extends||(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(n[o]=i[o])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})();Object.defineProperty(Qt,"__esModule",{value:!0});Qt.Converter=void 0;var sm=require("stream"),L2=kh(),C2=Bh(),q2=nm(),F2=om(),j2=(function(t){A2(e,t);function e(r,n){n===void 0&&(n={});var i=t.call(this,n)||this;return i.options=n,i.params=(0,L2.mergeParams)(r),i.runtime=(0,C2.initParseRuntime)(i),i.result=new F2.Result(i),i.processor=new q2.ProcessorLocal(i),i.once("error",function(o){setImmediate(function(){i.result.processError(o),i.emit("done",o)})}),i.once("done",function(){i.processor.destroy()}),i}return e.prototype.preRawData=function(r){return this.runtime.preRawDataHook=r,this},e.prototype.preFileLine=function(r){return this.runtime.preFileLineHook=r,this},e.prototype.subscribe=function(r,n,i){return this.parseRuntime.subscribe={onNext:r,onError:n,onCompleted:i},this},e.prototype.fromFile=function(r,n){var i=this,o=require("fs");return o.exists(r,function(s){if(s){var a=o.createReadStream(r,n);a.pipe(i)}else i.emit("error",new Error("File does not exist at ".concat(r,". Check to make sure the file path to your csv is correct.")))}),this},e.prototype.fromStream=function(r){return r.pipe(this),this},e.prototype.fromString=function(r){var n=r.toString(),i=new sm.Readable,o=0;return i._read=function(s){if(o>=r.length)this.push(null);else{var a=r.substring(o,o+s);this.push(a),o+=s}},this.fromStream(i)},e.prototype.then=function(r,n){var i=this;return new Promise(function(o,s){i.parseRuntime.then={onfulfilled:function(a){o(r?r(a):a)},onrejected:function(a){n?o(n(a)):s(a)}}})},Object.defineProperty(e.prototype,"parseParam",{get:function(){return this.params},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"parseRuntime",{get:function(){return this.runtime},enumerable:!1,configurable:!0}),e.prototype._transform=function(r,n,i){var o=this;this.processor.process(r).then(function(s){if(s.length>0)return o.runtime.started=!0,o.result.processResult(s)}).then(function(){o.emit("drained"),i()},function(s){o.runtime.hasError=!0,o.runtime.error=s,o.emit("error",s),i()})},e.prototype._flush=function(r){var n=this;this.processor.flush().then(function(i){if(i.length>0)return n.result.processResult(i)}).then(function(){n.processEnd(r)},function(i){n.emit("error",i),r()})},e.prototype.processEnd=function(r){this.result.endProcess(),this.emit("done"),r()},Object.defineProperty(e.prototype,"parsedLineNumber",{get:function(){return this.runtime.parsedLineNumber},enumerable:!1,configurable:!0}),e})(sm.Transform);Qt.Converter=j2});var fm=S((nM,lm)=>{"use strict";var um=am(),xi=function(t,e){return new um.Converter(t,e)};xi.csv=xi;xi.Converter=um.Converter;lm.exports=xi});var Pi=S(sa=>{"use strict";(function(){sa.defaults={"0.1":{explicitCharkey:!1,trim:!0,normalize:!0,normalizeTags:!1,attrkey:"@",charkey:"#",explicitArray:!1,ignoreAttrs:!1,mergeAttrs:!1,explicitRoot:!1,validator:null,xmlns:!1,explicitChildren:!1,childkey:"@@",charsAsChildren:!1,includeWhiteChars:!1,async:!1,strict:!0,attrNameProcessors:null,attrValueProcessors:null,tagNameProcessors:null,valueProcessors:null,emptyTag:""},"0.2":{explicitCharkey:!1,trim:!1,normalize:!1,normalizeTags:!1,attrkey:"$",charkey:"_",explicitArray:!0,ignoreAttrs:!1,mergeAttrs:!1,explicitRoot:!0,validator:null,xmlns:!1,explicitChildren:!1,preserveChildrenOrder:!1,childkey:"$$",charsAsChildren:!1,includeWhiteChars:!1,async:!1,strict:!0,attrNameProcessors:null,attrValueProcessors:null,tagNameProcessors:null,valueProcessors:null,rootName:"root",xmldec:{version:"1.0",encoding:"UTF-8",standalone:!0},doctype:null,renderOpts:{pretty:!0,indent:" ",newline:`
|
|
38
|
-
`},headless:!1,chunkSize:1e4,emptyTag:"",cdata:!1}}}).call(sa)});var qe=S((cm,at)=>{"use strict";(function(){var t,e,r,n,i,o,s,a=[].slice,u={}.hasOwnProperty;t=function(){var d,w,E,y,g,h;if(h=arguments[0],g=2<=arguments.length?a.call(arguments,1):[],i(Object.assign))Object.assign.apply(null,arguments);else for(d=0,E=g.length;d<E;d++)if(y=g[d],y!=null)for(w in y)u.call(y,w)&&(h[w]=y[w]);return h},i=function(d){return!!d&&Object.prototype.toString.call(d)==="[object Function]"},o=function(d){var w;return!!d&&((w=typeof d)=="function"||w==="object")},r=function(d){return i(Array.isArray)?Array.isArray(d):Object.prototype.toString.call(d)==="[object Array]"},n=function(d){var w;if(r(d))return!d.length;for(w in d)if(u.call(d,w))return!1;return!0},s=function(d){var w,E;return o(d)&&(E=Object.getPrototypeOf(d))&&(w=E.constructor)&&typeof w=="function"&&w instanceof w&&Function.prototype.toString.call(w)===Function.prototype.toString.call(Object)},e=function(d){return i(d.valueOf)?d.valueOf():d},at.exports.assign=t,at.exports.isFunction=i,at.exports.isObject=o,at.exports.isArray=r,at.exports.isEmpty=n,at.exports.isPlainObject=s,at.exports.getValue=e}).call(cm)});var aa=S((hm,dm)=>{"use strict";(function(){var t;dm.exports=t=(function(){function e(){}return e.prototype.hasFeature=function(r,n){return!0},e.prototype.createDocumentType=function(r,n,i){throw new Error("This DOM method is not implemented.")},e.prototype.createDocument=function(r,n,i){throw new Error("This DOM method is not implemented.")},e.prototype.createHTMLDocument=function(r){throw new Error("This DOM method is not implemented.")},e.prototype.getFeature=function(r,n){throw new Error("This DOM method is not implemented.")},e})()}).call(hm)});var gm=S((pm,mm)=>{"use strict";(function(){var t;mm.exports=t=(function(){function e(){}return e.prototype.handleError=function(r){throw new Error(r)},e})()}).call(pm)});var wm=S((ym,bm)=>{"use strict";(function(){var t;bm.exports=t=(function(){function e(r){this.arr=r||[]}return Object.defineProperty(e.prototype,"length",{get:function(){return this.arr.length}}),e.prototype.item=function(r){return this.arr[r]||null},e.prototype.contains=function(r){return this.arr.indexOf(r)!==-1},e})()}).call(ym)});var Em=S((_m,vm)=>{"use strict";(function(){var t,e,r;e=gm(),r=wm(),vm.exports=t=(function(){function n(){var i;this.defaultParams={"canonical-form":!1,"cdata-sections":!1,comments:!1,"datatype-normalization":!1,"element-content-whitespace":!0,entities:!0,"error-handler":new e,infoset:!0,"validate-if-schema":!1,namespaces:!0,"namespace-declarations":!0,"normalize-characters":!1,"schema-location":"","schema-type":"","split-cdata-sections":!0,validate:!1,"well-formed":!0},this.params=i=Object.create(this.defaultParams)}return Object.defineProperty(n.prototype,"parameterNames",{get:function(){return new r(Object.keys(this.defaultParams))}}),n.prototype.getParameter=function(i){return this.params.hasOwnProperty(i)?this.params[i]:null},n.prototype.canSetParameter=function(i,o){return!0},n.prototype.setParameter=function(i,o){return o!=null?this.params[i]=o:delete this.params[i]},n})()}).call(_m)});var re=S((Sm,Tm)=>{"use strict";(function(){Tm.exports={Element:1,Attribute:2,Text:3,CData:4,EntityReference:5,EntityDeclaration:6,ProcessingInstruction:7,Comment:8,Document:9,DocType:10,DocumentFragment:11,NotationDeclaration:12,Declaration:201,Raw:202,AttributeDeclaration:203,ElementDeclaration:204,Dummy:205}}).call(Sm)});var ua=S((Om,Dm)=>{"use strict";(function(){var t,e,r;t=re(),r=we(),Dm.exports=e=(function(){function n(i,o,s){if(this.parent=i,this.parent&&(this.options=this.parent.options,this.stringify=this.parent.stringify),o==null)throw new Error("Missing attribute name. "+this.debugInfo(o));this.name=this.stringify.name(o),this.value=this.stringify.attValue(s),this.type=t.Attribute,this.isId=!1,this.schemaTypeInfo=null}return Object.defineProperty(n.prototype,"nodeType",{get:function(){return this.type}}),Object.defineProperty(n.prototype,"ownerElement",{get:function(){return this.parent}}),Object.defineProperty(n.prototype,"textContent",{get:function(){return this.value},set:function(i){return this.value=i||""}}),Object.defineProperty(n.prototype,"namespaceURI",{get:function(){return""}}),Object.defineProperty(n.prototype,"prefix",{get:function(){return""}}),Object.defineProperty(n.prototype,"localName",{get:function(){return this.name}}),Object.defineProperty(n.prototype,"specified",{get:function(){return!0}}),n.prototype.clone=function(){return Object.create(this)},n.prototype.toString=function(i){return this.options.writer.attribute(this,this.options.writer.filterOptions(i))},n.prototype.debugInfo=function(i){return i=i||this.name,i==null?"parent: <"+this.parent.name+">":"attribute: {"+i+"}, parent: <"+this.parent.name+">"},n.prototype.isEqualNode=function(i){return!(i.namespaceURI!==this.namespaceURI||i.prefix!==this.prefix||i.localName!==this.localName||i.value!==this.value)},n})()}).call(Om)});var Ii=S((xm,Pm)=>{"use strict";(function(){var t;Pm.exports=t=(function(){function e(r){this.nodes=r}return Object.defineProperty(e.prototype,"length",{get:function(){return Object.keys(this.nodes).length||0}}),e.prototype.clone=function(){return this.nodes=null},e.prototype.getNamedItem=function(r){return this.nodes[r]},e.prototype.setNamedItem=function(r){var n;return n=this.nodes[r.nodeName],this.nodes[r.nodeName]=r,n||null},e.prototype.removeNamedItem=function(r){var n;return n=this.nodes[r],delete this.nodes[r],n||null},e.prototype.item=function(r){return this.nodes[Object.keys(this.nodes)[r]]||null},e.prototype.getNamedItemNS=function(r,n){throw new Error("This DOM method is not implemented.")},e.prototype.setNamedItemNS=function(r){throw new Error("This DOM method is not implemented.")},e.prototype.removeNamedItemNS=function(r,n){throw new Error("This DOM method is not implemented.")},e})()}).call(xm)});var Mi=S((Im,Mm)=>{"use strict";(function(){var t,e,r,n,i,o,s,a,u,d=function(E,y){for(var g in y)w.call(y,g)&&(E[g]=y[g]);function h(){this.constructor=E}return h.prototype=y.prototype,E.prototype=new h,E.__super__=y.prototype,E},w={}.hasOwnProperty;u=qe(),a=u.isObject,s=u.isFunction,o=u.getValue,i=we(),t=re(),e=ua(),n=Ii(),Mm.exports=r=(function(E){d(y,E);function y(g,h,v){var R,N,D,m;if(y.__super__.constructor.call(this,g),h==null)throw new Error("Missing element name. "+this.debugInfo());if(this.name=this.stringify.name(h),this.type=t.Element,this.attribs={},this.schemaTypeInfo=null,v!=null&&this.attribute(v),g.type===t.Document&&(this.isRoot=!0,this.documentObject=g,g.rootObject=this,g.children)){for(m=g.children,N=0,D=m.length;N<D;N++)if(R=m[N],R.type===t.DocType){R.name=this.name;break}}}return Object.defineProperty(y.prototype,"tagName",{get:function(){return this.name}}),Object.defineProperty(y.prototype,"namespaceURI",{get:function(){return""}}),Object.defineProperty(y.prototype,"prefix",{get:function(){return""}}),Object.defineProperty(y.prototype,"localName",{get:function(){return this.name}}),Object.defineProperty(y.prototype,"id",{get:function(){throw new Error("This DOM method is not implemented."+this.debugInfo())}}),Object.defineProperty(y.prototype,"className",{get:function(){throw new Error("This DOM method is not implemented."+this.debugInfo())}}),Object.defineProperty(y.prototype,"classList",{get:function(){throw new Error("This DOM method is not implemented."+this.debugInfo())}}),Object.defineProperty(y.prototype,"attributes",{get:function(){return(!this.attributeMap||!this.attributeMap.nodes)&&(this.attributeMap=new n(this.attribs)),this.attributeMap}}),y.prototype.clone=function(){var g,h,v,R;v=Object.create(this),v.isRoot&&(v.documentObject=null),v.attribs={},R=this.attribs;for(h in R)w.call(R,h)&&(g=R[h],v.attribs[h]=g.clone());return v.children=[],this.children.forEach(function(N){var D;return D=N.clone(),D.parent=v,v.children.push(D)}),v},y.prototype.attribute=function(g,h){var v,R;if(g!=null&&(g=o(g)),a(g))for(v in g)w.call(g,v)&&(R=g[v],this.attribute(v,R));else s(h)&&(h=h.apply()),this.options.keepNullAttributes&&h==null?this.attribs[g]=new e(this,g,""):h!=null&&(this.attribs[g]=new e(this,g,h));return this},y.prototype.removeAttribute=function(g){var h,v,R;if(g==null)throw new Error("Missing attribute name. "+this.debugInfo());if(g=o(g),Array.isArray(g))for(v=0,R=g.length;v<R;v++)h=g[v],delete this.attribs[h];else delete this.attribs[g];return this},y.prototype.toString=function(g){return this.options.writer.element(this,this.options.writer.filterOptions(g))},y.prototype.att=function(g,h){return this.attribute(g,h)},y.prototype.a=function(g,h){return this.attribute(g,h)},y.prototype.getAttribute=function(g){return this.attribs.hasOwnProperty(g)?this.attribs[g].value:null},y.prototype.setAttribute=function(g,h){throw new Error("This DOM method is not implemented."+this.debugInfo())},y.prototype.getAttributeNode=function(g){return this.attribs.hasOwnProperty(g)?this.attribs[g]:null},y.prototype.setAttributeNode=function(g){throw new Error("This DOM method is not implemented."+this.debugInfo())},y.prototype.removeAttributeNode=function(g){throw new Error("This DOM method is not implemented."+this.debugInfo())},y.prototype.getElementsByTagName=function(g){throw new Error("This DOM method is not implemented."+this.debugInfo())},y.prototype.getAttributeNS=function(g,h){throw new Error("This DOM method is not implemented."+this.debugInfo())},y.prototype.setAttributeNS=function(g,h,v){throw new Error("This DOM method is not implemented."+this.debugInfo())},y.prototype.removeAttributeNS=function(g,h){throw new Error("This DOM method is not implemented."+this.debugInfo())},y.prototype.getAttributeNodeNS=function(g,h){throw new Error("This DOM method is not implemented."+this.debugInfo())},y.prototype.setAttributeNodeNS=function(g){throw new Error("This DOM method is not implemented."+this.debugInfo())},y.prototype.getElementsByTagNameNS=function(g,h){throw new Error("This DOM method is not implemented."+this.debugInfo())},y.prototype.hasAttribute=function(g){return this.attribs.hasOwnProperty(g)},y.prototype.hasAttributeNS=function(g,h){throw new Error("This DOM method is not implemented."+this.debugInfo())},y.prototype.setIdAttribute=function(g,h){return this.attribs.hasOwnProperty(g)?this.attribs[g].isId:h},y.prototype.setIdAttributeNS=function(g,h,v){throw new Error("This DOM method is not implemented."+this.debugInfo())},y.prototype.setIdAttributeNode=function(g,h){throw new Error("This DOM method is not implemented."+this.debugInfo())},y.prototype.getElementsByTagName=function(g){throw new Error("This DOM method is not implemented."+this.debugInfo())},y.prototype.getElementsByTagNameNS=function(g,h){throw new Error("This DOM method is not implemented."+this.debugInfo())},y.prototype.getElementsByClassName=function(g){throw new Error("This DOM method is not implemented."+this.debugInfo())},y.prototype.isEqualNode=function(g){var h,v,R;if(!y.__super__.isEqualNode.apply(this,arguments).isEqualNode(g)||g.namespaceURI!==this.namespaceURI||g.prefix!==this.prefix||g.localName!==this.localName||g.attribs.length!==this.attribs.length)return!1;for(h=v=0,R=this.attribs.length-1;0<=R?v<=R:v>=R;h=0<=R?++v:--v)if(!this.attribs[h].isEqualNode(g.attribs[h]))return!1;return!0},y})(i)}).call(Im)});var Xr=S((Nm,Rm)=>{"use strict";(function(){var t,e,r=function(i,o){for(var s in o)n.call(o,s)&&(i[s]=o[s]);function a(){this.constructor=i}return a.prototype=o.prototype,i.prototype=new a,i.__super__=o.prototype,i},n={}.hasOwnProperty;e=we(),Rm.exports=t=(function(i){r(o,i);function o(s){o.__super__.constructor.call(this,s),this.value=""}return Object.defineProperty(o.prototype,"data",{get:function(){return this.value},set:function(s){return this.value=s||""}}),Object.defineProperty(o.prototype,"length",{get:function(){return this.value.length}}),Object.defineProperty(o.prototype,"textContent",{get:function(){return this.value},set:function(s){return this.value=s||""}}),o.prototype.clone=function(){return Object.create(this)},o.prototype.substringData=function(s,a){throw new Error("This DOM method is not implemented."+this.debugInfo())},o.prototype.appendData=function(s){throw new Error("This DOM method is not implemented."+this.debugInfo())},o.prototype.insertData=function(s,a){throw new Error("This DOM method is not implemented."+this.debugInfo())},o.prototype.deleteData=function(s,a){throw new Error("This DOM method is not implemented."+this.debugInfo())},o.prototype.replaceData=function(s,a,u){throw new Error("This DOM method is not implemented."+this.debugInfo())},o.prototype.isEqualNode=function(s){return!(!o.__super__.isEqualNode.apply(this,arguments).isEqualNode(s)||s.data!==this.data)},o})(e)}).call(Nm)});var Ni=S((Am,Lm)=>{"use strict";(function(){var t,e,r,n=function(o,s){for(var a in s)i.call(s,a)&&(o[a]=s[a]);function u(){this.constructor=o}return u.prototype=s.prototype,o.prototype=new u,o.__super__=s.prototype,o},i={}.hasOwnProperty;t=re(),r=Xr(),Lm.exports=e=(function(o){n(s,o);function s(a,u){if(s.__super__.constructor.call(this,a),u==null)throw new Error("Missing CDATA text. "+this.debugInfo());this.name="#cdata-section",this.type=t.CData,this.value=this.stringify.cdata(u)}return s.prototype.clone=function(){return Object.create(this)},s.prototype.toString=function(a){return this.options.writer.cdata(this,this.options.writer.filterOptions(a))},s})(r)}).call(Am)});var Ri=S((Cm,qm)=>{"use strict";(function(){var t,e,r,n=function(o,s){for(var a in s)i.call(s,a)&&(o[a]=s[a]);function u(){this.constructor=o}return u.prototype=s.prototype,o.prototype=new u,o.__super__=s.prototype,o},i={}.hasOwnProperty;t=re(),e=Xr(),qm.exports=r=(function(o){n(s,o);function s(a,u){if(s.__super__.constructor.call(this,a),u==null)throw new Error("Missing comment text. "+this.debugInfo());this.name="#comment",this.type=t.Comment,this.value=this.stringify.comment(u)}return s.prototype.clone=function(){return Object.create(this)},s.prototype.toString=function(a){return this.options.writer.comment(this,this.options.writer.filterOptions(a))},s})(e)}).call(Cm)});var Ai=S((Fm,jm)=>{"use strict";(function(){var t,e,r,n,i=function(s,a){for(var u in a)o.call(a,u)&&(s[u]=a[u]);function d(){this.constructor=s}return d.prototype=a.prototype,s.prototype=new d,s.__super__=a.prototype,s},o={}.hasOwnProperty;n=qe().isObject,r=we(),t=re(),jm.exports=e=(function(s){i(a,s);function a(u,d,w,E){var y;a.__super__.constructor.call(this,u),n(d)&&(y=d,d=y.version,w=y.encoding,E=y.standalone),d||(d="1.0"),this.type=t.Declaration,this.version=this.stringify.xmlVersion(d),w!=null&&(this.encoding=this.stringify.xmlEncoding(w)),E!=null&&(this.standalone=this.stringify.xmlStandalone(E))}return a.prototype.toString=function(u){return this.options.writer.declaration(this,this.options.writer.filterOptions(u))},a})(r)}).call(Fm)});var Li=S((km,Bm)=>{"use strict";(function(){var t,e,r,n=function(o,s){for(var a in s)i.call(s,a)&&(o[a]=s[a]);function u(){this.constructor=o}return u.prototype=s.prototype,o.prototype=new u,o.__super__=s.prototype,o},i={}.hasOwnProperty;r=we(),t=re(),Bm.exports=e=(function(o){n(s,o);function s(a,u,d,w,E,y){if(s.__super__.constructor.call(this,a),u==null)throw new Error("Missing DTD element name. "+this.debugInfo());if(d==null)throw new Error("Missing DTD attribute name. "+this.debugInfo(u));if(!w)throw new Error("Missing DTD attribute type. "+this.debugInfo(u));if(!E)throw new Error("Missing DTD attribute default. "+this.debugInfo(u));if(E.indexOf("#")!==0&&(E="#"+E),!E.match(/^(#REQUIRED|#IMPLIED|#FIXED|#DEFAULT)$/))throw new Error("Invalid default value type; expected: #REQUIRED, #IMPLIED, #FIXED or #DEFAULT. "+this.debugInfo(u));if(y&&!E.match(/^(#FIXED|#DEFAULT)$/))throw new Error("Default value only applies to #FIXED or #DEFAULT. "+this.debugInfo(u));this.elementName=this.stringify.name(u),this.type=t.AttributeDeclaration,this.attributeName=this.stringify.name(d),this.attributeType=this.stringify.dtdAttType(w),y&&(this.defaultValue=this.stringify.dtdAttDefault(y)),this.defaultValueType=E}return s.prototype.toString=function(a){return this.options.writer.dtdAttList(this,this.options.writer.filterOptions(a))},s})(r)}).call(km)});var Ci=S(($m,Um)=>{"use strict";(function(){var t,e,r,n,i=function(s,a){for(var u in a)o.call(a,u)&&(s[u]=a[u]);function d(){this.constructor=s}return d.prototype=a.prototype,s.prototype=new d,s.__super__=a.prototype,s},o={}.hasOwnProperty;n=qe().isObject,r=we(),t=re(),Um.exports=e=(function(s){i(a,s);function a(u,d,w,E){if(a.__super__.constructor.call(this,u),w==null)throw new Error("Missing DTD entity name. "+this.debugInfo(w));if(E==null)throw new Error("Missing DTD entity value. "+this.debugInfo(w));if(this.pe=!!d,this.name=this.stringify.name(w),this.type=t.EntityDeclaration,!n(E))this.value=this.stringify.dtdEntityValue(E),this.internal=!0;else{if(!E.pubID&&!E.sysID)throw new Error("Public and/or system identifiers are required for an external entity. "+this.debugInfo(w));if(E.pubID&&!E.sysID)throw new Error("System identifier is required for a public external entity. "+this.debugInfo(w));if(this.internal=!1,E.pubID!=null&&(this.pubID=this.stringify.dtdPubID(E.pubID)),E.sysID!=null&&(this.sysID=this.stringify.dtdSysID(E.sysID)),E.nData!=null&&(this.nData=this.stringify.dtdNData(E.nData)),this.pe&&this.nData)throw new Error("Notation declaration is not allowed in a parameter entity. "+this.debugInfo(w))}}return Object.defineProperty(a.prototype,"publicId",{get:function(){return this.pubID}}),Object.defineProperty(a.prototype,"systemId",{get:function(){return this.sysID}}),Object.defineProperty(a.prototype,"notationName",{get:function(){return this.nData||null}}),Object.defineProperty(a.prototype,"inputEncoding",{get:function(){return null}}),Object.defineProperty(a.prototype,"xmlEncoding",{get:function(){return null}}),Object.defineProperty(a.prototype,"xmlVersion",{get:function(){return null}}),a.prototype.toString=function(u){return this.options.writer.dtdEntity(this,this.options.writer.filterOptions(u))},a})(r)}).call($m)});var qi=S((Vm,Hm)=>{"use strict";(function(){var t,e,r,n=function(o,s){for(var a in s)i.call(s,a)&&(o[a]=s[a]);function u(){this.constructor=o}return u.prototype=s.prototype,o.prototype=new u,o.__super__=s.prototype,o},i={}.hasOwnProperty;r=we(),t=re(),Hm.exports=e=(function(o){n(s,o);function s(a,u,d){if(s.__super__.constructor.call(this,a),u==null)throw new Error("Missing DTD element name. "+this.debugInfo());d||(d="(#PCDATA)"),Array.isArray(d)&&(d="("+d.join(",")+")"),this.name=this.stringify.name(u),this.type=t.ElementDeclaration,this.value=this.stringify.dtdElementValue(d)}return s.prototype.toString=function(a){return this.options.writer.dtdElement(this,this.options.writer.filterOptions(a))},s})(r)}).call(Vm)});var Fi=S((Wm,Xm)=>{"use strict";(function(){var t,e,r,n=function(o,s){for(var a in s)i.call(s,a)&&(o[a]=s[a]);function u(){this.constructor=o}return u.prototype=s.prototype,o.prototype=new u,o.__super__=s.prototype,o},i={}.hasOwnProperty;r=we(),t=re(),Xm.exports=e=(function(o){n(s,o);function s(a,u,d){if(s.__super__.constructor.call(this,a),u==null)throw new Error("Missing DTD notation name. "+this.debugInfo(u));if(!d.pubID&&!d.sysID)throw new Error("Public or system identifiers are required for an external entity. "+this.debugInfo(u));this.name=this.stringify.name(u),this.type=t.NotationDeclaration,d.pubID!=null&&(this.pubID=this.stringify.dtdPubID(d.pubID)),d.sysID!=null&&(this.sysID=this.stringify.dtdSysID(d.sysID))}return Object.defineProperty(s.prototype,"publicId",{get:function(){return this.pubID}}),Object.defineProperty(s.prototype,"systemId",{get:function(){return this.sysID}}),s.prototype.toString=function(a){return this.options.writer.dtdNotation(this,this.options.writer.filterOptions(a))},s})(r)}).call(Wm)});var ji=S((Km,Gm)=>{"use strict";(function(){var t,e,r,n,i,o,s,a,u,d=function(E,y){for(var g in y)w.call(y,g)&&(E[g]=y[g]);function h(){this.constructor=E}return h.prototype=y.prototype,E.prototype=new h,E.__super__=y.prototype,E},w={}.hasOwnProperty;u=qe().isObject,a=we(),t=re(),e=Li(),n=Ci(),r=qi(),i=Fi(),s=Ii(),Gm.exports=o=(function(E){d(y,E);function y(g,h,v){var R,N,D,m,c,l;if(y.__super__.constructor.call(this,g),this.type=t.DocType,g.children){for(m=g.children,N=0,D=m.length;N<D;N++)if(R=m[N],R.type===t.Element){this.name=R.name;break}}this.documentObject=g,u(h)&&(c=h,h=c.pubID,v=c.sysID),v==null&&(l=[h,v],v=l[0],h=l[1]),h!=null&&(this.pubID=this.stringify.dtdPubID(h)),v!=null&&(this.sysID=this.stringify.dtdSysID(v))}return Object.defineProperty(y.prototype,"entities",{get:function(){var g,h,v,R,N;for(R={},N=this.children,h=0,v=N.length;h<v;h++)g=N[h],g.type===t.EntityDeclaration&&!g.pe&&(R[g.name]=g);return new s(R)}}),Object.defineProperty(y.prototype,"notations",{get:function(){var g,h,v,R,N;for(R={},N=this.children,h=0,v=N.length;h<v;h++)g=N[h],g.type===t.NotationDeclaration&&(R[g.name]=g);return new s(R)}}),Object.defineProperty(y.prototype,"publicId",{get:function(){return this.pubID}}),Object.defineProperty(y.prototype,"systemId",{get:function(){return this.sysID}}),Object.defineProperty(y.prototype,"internalSubset",{get:function(){throw new Error("This DOM method is not implemented."+this.debugInfo())}}),y.prototype.element=function(g,h){var v;return v=new r(this,g,h),this.children.push(v),this},y.prototype.attList=function(g,h,v,R,N){var D;return D=new e(this,g,h,v,R,N),this.children.push(D),this},y.prototype.entity=function(g,h){var v;return v=new n(this,!1,g,h),this.children.push(v),this},y.prototype.pEntity=function(g,h){var v;return v=new n(this,!0,g,h),this.children.push(v),this},y.prototype.notation=function(g,h){var v;return v=new i(this,g,h),this.children.push(v),this},y.prototype.toString=function(g){return this.options.writer.docType(this,this.options.writer.filterOptions(g))},y.prototype.ele=function(g,h){return this.element(g,h)},y.prototype.att=function(g,h,v,R,N){return this.attList(g,h,v,R,N)},y.prototype.ent=function(g,h){return this.entity(g,h)},y.prototype.pent=function(g,h){return this.pEntity(g,h)},y.prototype.not=function(g,h){return this.notation(g,h)},y.prototype.up=function(){return this.root()||this.documentObject},y.prototype.isEqualNode=function(g){return!(!y.__super__.isEqualNode.apply(this,arguments).isEqualNode(g)||g.name!==this.name||g.publicId!==this.publicId||g.systemId!==this.systemId)},y})(a)}).call(Km)});var ki=S((Ym,zm)=>{"use strict";(function(){var t,e,r,n=function(o,s){for(var a in s)i.call(s,a)&&(o[a]=s[a]);function u(){this.constructor=o}return u.prototype=s.prototype,o.prototype=new u,o.__super__=s.prototype,o},i={}.hasOwnProperty;t=re(),e=we(),zm.exports=r=(function(o){n(s,o);function s(a,u){if(s.__super__.constructor.call(this,a),u==null)throw new Error("Missing raw text. "+this.debugInfo());this.type=t.Raw,this.value=this.stringify.raw(u)}return s.prototype.clone=function(){return Object.create(this)},s.prototype.toString=function(a){return this.options.writer.raw(this,this.options.writer.filterOptions(a))},s})(e)}).call(Ym)});var Bi=S((Jm,Qm)=>{"use strict";(function(){var t,e,r,n=function(o,s){for(var a in s)i.call(s,a)&&(o[a]=s[a]);function u(){this.constructor=o}return u.prototype=s.prototype,o.prototype=new u,o.__super__=s.prototype,o},i={}.hasOwnProperty;t=re(),e=Xr(),Qm.exports=r=(function(o){n(s,o);function s(a,u){if(s.__super__.constructor.call(this,a),u==null)throw new Error("Missing element text. "+this.debugInfo());this.name="#text",this.type=t.Text,this.value=this.stringify.text(u)}return Object.defineProperty(s.prototype,"isElementContentWhitespace",{get:function(){throw new Error("This DOM method is not implemented."+this.debugInfo())}}),Object.defineProperty(s.prototype,"wholeText",{get:function(){var a,u,d;for(d="",u=this.previousSibling;u;)d=u.data+d,u=u.previousSibling;for(d+=this.data,a=this.nextSibling;a;)d=d+a.data,a=a.nextSibling;return d}}),s.prototype.clone=function(){return Object.create(this)},s.prototype.toString=function(a){return this.options.writer.text(this,this.options.writer.filterOptions(a))},s.prototype.splitText=function(a){throw new Error("This DOM method is not implemented."+this.debugInfo())},s.prototype.replaceWholeText=function(a){throw new Error("This DOM method is not implemented."+this.debugInfo())},s})(e)}).call(Jm)});var $i=S((Zm,eg)=>{"use strict";(function(){var t,e,r,n=function(o,s){for(var a in s)i.call(s,a)&&(o[a]=s[a]);function u(){this.constructor=o}return u.prototype=s.prototype,o.prototype=new u,o.__super__=s.prototype,o},i={}.hasOwnProperty;t=re(),e=Xr(),eg.exports=r=(function(o){n(s,o);function s(a,u,d){if(s.__super__.constructor.call(this,a),u==null)throw new Error("Missing instruction target. "+this.debugInfo());this.type=t.ProcessingInstruction,this.target=this.stringify.insTarget(u),this.name=this.target,d&&(this.value=this.stringify.insValue(d))}return s.prototype.clone=function(){return Object.create(this)},s.prototype.toString=function(a){return this.options.writer.processingInstruction(this,this.options.writer.filterOptions(a))},s.prototype.isEqualNode=function(a){return!(!s.__super__.isEqualNode.apply(this,arguments).isEqualNode(a)||a.target!==this.target)},s})(e)}).call(Zm)});var la=S((tg,rg)=>{"use strict";(function(){var t,e,r,n=function(o,s){for(var a in s)i.call(s,a)&&(o[a]=s[a]);function u(){this.constructor=o}return u.prototype=s.prototype,o.prototype=new u,o.__super__=s.prototype,o},i={}.hasOwnProperty;r=we(),t=re(),rg.exports=e=(function(o){n(s,o);function s(a){s.__super__.constructor.call(this,a),this.type=t.Dummy}return s.prototype.clone=function(){return Object.create(this)},s.prototype.toString=function(a){return""},s})(r)}).call(tg)});var og=S((ng,ig)=>{"use strict";(function(){var t;ig.exports=t=(function(){function e(r){this.nodes=r}return Object.defineProperty(e.prototype,"length",{get:function(){return this.nodes.length||0}}),e.prototype.clone=function(){return this.nodes=null},e.prototype.item=function(r){return this.nodes[r]||null},e})()}).call(ng)});var ug=S((sg,ag)=>{"use strict";(function(){ag.exports={Disconnected:1,Preceding:2,Following:4,Contains:8,ContainedBy:16,ImplementationSpecific:32}}).call(sg)});var we=S((lg,fg)=>{"use strict";(function(){var t,e,r,n,i,o,s,a,u,d,w,E,y,g,h,v,R,N,D,m={}.hasOwnProperty;D=qe(),N=D.isObject,R=D.isFunction,v=D.isEmpty,h=D.getValue,a=null,r=null,n=null,i=null,o=null,y=null,g=null,E=null,s=null,e=null,w=null,u=null,t=null,fg.exports=d=(function(){function c(l){this.parent=l,this.parent&&(this.options=this.parent.options,this.stringify=this.parent.stringify),this.value=null,this.children=[],this.baseURI=null,a||(a=Mi(),r=Ni(),n=Ri(),i=Ai(),o=ji(),y=ki(),g=Bi(),E=$i(),s=la(),e=re(),w=og(),u=Ii(),t=ug())}return Object.defineProperty(c.prototype,"nodeName",{get:function(){return this.name}}),Object.defineProperty(c.prototype,"nodeType",{get:function(){return this.type}}),Object.defineProperty(c.prototype,"nodeValue",{get:function(){return this.value}}),Object.defineProperty(c.prototype,"parentNode",{get:function(){return this.parent}}),Object.defineProperty(c.prototype,"childNodes",{get:function(){return(!this.childNodeList||!this.childNodeList.nodes)&&(this.childNodeList=new w(this.children)),this.childNodeList}}),Object.defineProperty(c.prototype,"firstChild",{get:function(){return this.children[0]||null}}),Object.defineProperty(c.prototype,"lastChild",{get:function(){return this.children[this.children.length-1]||null}}),Object.defineProperty(c.prototype,"previousSibling",{get:function(){var l;return l=this.parent.children.indexOf(this),this.parent.children[l-1]||null}}),Object.defineProperty(c.prototype,"nextSibling",{get:function(){var l;return l=this.parent.children.indexOf(this),this.parent.children[l+1]||null}}),Object.defineProperty(c.prototype,"ownerDocument",{get:function(){return this.document()||null}}),Object.defineProperty(c.prototype,"textContent",{get:function(){var l,_,M,p,I;if(this.nodeType===e.Element||this.nodeType===e.DocumentFragment){for(I="",p=this.children,_=0,M=p.length;_<M;_++)l=p[_],l.textContent&&(I+=l.textContent);return I}else return null},set:function(l){throw new Error("This DOM method is not implemented."+this.debugInfo())}}),c.prototype.setParent=function(l){var _,M,p,I,T;for(this.parent=l,l&&(this.options=l.options,this.stringify=l.stringify),I=this.children,T=[],M=0,p=I.length;M<p;M++)_=I[M],T.push(_.setParent(this));return T},c.prototype.element=function(l,_,M){var p,I,T,P,L,C,B,$,x,q,j;if(C=null,_===null&&M==null&&(x=[{},null],_=x[0],M=x[1]),_==null&&(_={}),_=h(_),N(_)||(q=[_,M],M=q[0],_=q[1]),l!=null&&(l=h(l)),Array.isArray(l))for(T=0,B=l.length;T<B;T++)I=l[T],C=this.element(I);else if(R(l))C=this.element(l.apply());else if(N(l)){for(L in l)if(m.call(l,L))if(j=l[L],R(j)&&(j=j.apply()),!this.options.ignoreDecorators&&this.stringify.convertAttKey&&L.indexOf(this.stringify.convertAttKey)===0)C=this.attribute(L.substr(this.stringify.convertAttKey.length),j);else if(!this.options.separateArrayItems&&Array.isArray(j)&&v(j))C=this.dummy();else if(N(j)&&v(j))C=this.element(L);else if(!this.options.keepNullNodes&&j==null)C=this.dummy();else if(!this.options.separateArrayItems&&Array.isArray(j))for(P=0,$=j.length;P<$;P++)I=j[P],p={},p[L]=I,C=this.element(p);else N(j)?!this.options.ignoreDecorators&&this.stringify.convertTextKey&&L.indexOf(this.stringify.convertTextKey)===0?C=this.element(j):(C=this.element(L),C.element(j)):C=this.element(L,j)}else!this.options.keepNullNodes&&M===null?C=this.dummy():!this.options.ignoreDecorators&&this.stringify.convertTextKey&&l.indexOf(this.stringify.convertTextKey)===0?C=this.text(M):!this.options.ignoreDecorators&&this.stringify.convertCDataKey&&l.indexOf(this.stringify.convertCDataKey)===0?C=this.cdata(M):!this.options.ignoreDecorators&&this.stringify.convertCommentKey&&l.indexOf(this.stringify.convertCommentKey)===0?C=this.comment(M):!this.options.ignoreDecorators&&this.stringify.convertRawKey&&l.indexOf(this.stringify.convertRawKey)===0?C=this.raw(M):!this.options.ignoreDecorators&&this.stringify.convertPIKey&&l.indexOf(this.stringify.convertPIKey)===0?C=this.instruction(l.substr(this.stringify.convertPIKey.length),M):C=this.node(l,_,M);if(C==null)throw new Error("Could not create any elements with: "+l+". "+this.debugInfo());return C},c.prototype.insertBefore=function(l,_,M){var p,I,T,P,L;if(l?.type)return T=l,P=_,T.setParent(this),P?(I=children.indexOf(P),L=children.splice(I),children.push(T),Array.prototype.push.apply(children,L)):children.push(T),T;if(this.isRoot)throw new Error("Cannot insert elements at root level. "+this.debugInfo(l));return I=this.parent.children.indexOf(this),L=this.parent.children.splice(I),p=this.parent.element(l,_,M),Array.prototype.push.apply(this.parent.children,L),p},c.prototype.insertAfter=function(l,_,M){var p,I,T;if(this.isRoot)throw new Error("Cannot insert elements at root level. "+this.debugInfo(l));return I=this.parent.children.indexOf(this),T=this.parent.children.splice(I+1),p=this.parent.element(l,_,M),Array.prototype.push.apply(this.parent.children,T),p},c.prototype.remove=function(){var l,_;if(this.isRoot)throw new Error("Cannot remove the root element. "+this.debugInfo());return l=this.parent.children.indexOf(this),[].splice.apply(this.parent.children,[l,l-l+1].concat(_=[])),this.parent},c.prototype.node=function(l,_,M){var p,I;return l!=null&&(l=h(l)),_||(_={}),_=h(_),N(_)||(I=[_,M],M=I[0],_=I[1]),p=new a(this,l,_),M!=null&&p.text(M),this.children.push(p),p},c.prototype.text=function(l){var _;return N(l)&&this.element(l),_=new g(this,l),this.children.push(_),this},c.prototype.cdata=function(l){var _;return _=new r(this,l),this.children.push(_),this},c.prototype.comment=function(l){var _;return _=new n(this,l),this.children.push(_),this},c.prototype.commentBefore=function(l){var _,M,p;return M=this.parent.children.indexOf(this),p=this.parent.children.splice(M),_=this.parent.comment(l),Array.prototype.push.apply(this.parent.children,p),this},c.prototype.commentAfter=function(l){var _,M,p;return M=this.parent.children.indexOf(this),p=this.parent.children.splice(M+1),_=this.parent.comment(l),Array.prototype.push.apply(this.parent.children,p),this},c.prototype.raw=function(l){var _;return _=new y(this,l),this.children.push(_),this},c.prototype.dummy=function(){var l;return l=new s(this),l},c.prototype.instruction=function(l,_){var M,p,I,T,P;if(l!=null&&(l=h(l)),_!=null&&(_=h(_)),Array.isArray(l))for(T=0,P=l.length;T<P;T++)M=l[T],this.instruction(M);else if(N(l))for(M in l)m.call(l,M)&&(p=l[M],this.instruction(M,p));else R(_)&&(_=_.apply()),I=new E(this,l,_),this.children.push(I);return this},c.prototype.instructionBefore=function(l,_){var M,p,I;return p=this.parent.children.indexOf(this),I=this.parent.children.splice(p),M=this.parent.instruction(l,_),Array.prototype.push.apply(this.parent.children,I),this},c.prototype.instructionAfter=function(l,_){var M,p,I;return p=this.parent.children.indexOf(this),I=this.parent.children.splice(p+1),M=this.parent.instruction(l,_),Array.prototype.push.apply(this.parent.children,I),this},c.prototype.declaration=function(l,_,M){var p,I;return p=this.document(),I=new i(p,l,_,M),p.children.length===0?p.children.unshift(I):p.children[0].type===e.Declaration?p.children[0]=I:p.children.unshift(I),p.root()||p},c.prototype.dtd=function(l,_){var M,p,I,T,P,L,C,B,$,x;for(p=this.document(),I=new o(p,l,_),$=p.children,T=P=0,C=$.length;P<C;T=++P)if(M=$[T],M.type===e.DocType)return p.children[T]=I,I;for(x=p.children,T=L=0,B=x.length;L<B;T=++L)if(M=x[T],M.isRoot)return p.children.splice(T,0,I),I;return p.children.push(I),I},c.prototype.up=function(){if(this.isRoot)throw new Error("The root node has no parent. Use doc() if you need to get the document object.");return this.parent},c.prototype.root=function(){var l;for(l=this;l;){if(l.type===e.Document)return l.rootObject;if(l.isRoot)return l;l=l.parent}},c.prototype.document=function(){var l;for(l=this;l;){if(l.type===e.Document)return l;l=l.parent}},c.prototype.end=function(l){return this.document().end(l)},c.prototype.prev=function(){var l;if(l=this.parent.children.indexOf(this),l<1)throw new Error("Already at the first node. "+this.debugInfo());return this.parent.children[l-1]},c.prototype.next=function(){var l;if(l=this.parent.children.indexOf(this),l===-1||l===this.parent.children.length-1)throw new Error("Already at the last node. "+this.debugInfo());return this.parent.children[l+1]},c.prototype.importDocument=function(l){var _;return _=l.root().clone(),_.parent=this,_.isRoot=!1,this.children.push(_),this},c.prototype.debugInfo=function(l){var _,M;return l=l||this.name,l==null&&!((_=this.parent)!=null&&_.name)?"":l==null?"parent: <"+this.parent.name+">":(M=this.parent)!=null&&M.name?"node: <"+l+">, parent: <"+this.parent.name+">":"node: <"+l+">"},c.prototype.ele=function(l,_,M){return this.element(l,_,M)},c.prototype.nod=function(l,_,M){return this.node(l,_,M)},c.prototype.txt=function(l){return this.text(l)},c.prototype.dat=function(l){return this.cdata(l)},c.prototype.com=function(l){return this.comment(l)},c.prototype.ins=function(l,_){return this.instruction(l,_)},c.prototype.doc=function(){return this.document()},c.prototype.dec=function(l,_,M){return this.declaration(l,_,M)},c.prototype.e=function(l,_,M){return this.element(l,_,M)},c.prototype.n=function(l,_,M){return this.node(l,_,M)},c.prototype.t=function(l){return this.text(l)},c.prototype.d=function(l){return this.cdata(l)},c.prototype.c=function(l){return this.comment(l)},c.prototype.r=function(l){return this.raw(l)},c.prototype.i=function(l,_){return this.instruction(l,_)},c.prototype.u=function(){return this.up()},c.prototype.importXMLBuilder=function(l){return this.importDocument(l)},c.prototype.replaceChild=function(l,_){throw new Error("This DOM method is not implemented."+this.debugInfo())},c.prototype.removeChild=function(l){throw new Error("This DOM method is not implemented."+this.debugInfo())},c.prototype.appendChild=function(l){throw new Error("This DOM method is not implemented."+this.debugInfo())},c.prototype.hasChildNodes=function(){return this.children.length!==0},c.prototype.cloneNode=function(l){throw new Error("This DOM method is not implemented."+this.debugInfo())},c.prototype.normalize=function(){throw new Error("This DOM method is not implemented."+this.debugInfo())},c.prototype.isSupported=function(l,_){return!0},c.prototype.hasAttributes=function(){return this.attribs.length!==0},c.prototype.compareDocumentPosition=function(l){var _,M;return _=this,_===l?0:this.document()!==l.document()?(M=t.Disconnected|t.ImplementationSpecific,Math.random()<.5?M|=t.Preceding:M|=t.Following,M):_.isAncestor(l)?t.Contains|t.Preceding:_.isDescendant(l)?t.Contains|t.Following:_.isPreceding(l)?t.Preceding:t.Following},c.prototype.isSameNode=function(l){throw new Error("This DOM method is not implemented."+this.debugInfo())},c.prototype.lookupPrefix=function(l){throw new Error("This DOM method is not implemented."+this.debugInfo())},c.prototype.isDefaultNamespace=function(l){throw new Error("This DOM method is not implemented."+this.debugInfo())},c.prototype.lookupNamespaceURI=function(l){throw new Error("This DOM method is not implemented."+this.debugInfo())},c.prototype.isEqualNode=function(l){var _,M,p;if(l.nodeType!==this.nodeType||l.children.length!==this.children.length)return!1;for(_=M=0,p=this.children.length-1;0<=p?M<=p:M>=p;_=0<=p?++M:--M)if(!this.children[_].isEqualNode(l.children[_]))return!1;return!0},c.prototype.getFeature=function(l,_){throw new Error("This DOM method is not implemented."+this.debugInfo())},c.prototype.setUserData=function(l,_,M){throw new Error("This DOM method is not implemented."+this.debugInfo())},c.prototype.getUserData=function(l){throw new Error("This DOM method is not implemented."+this.debugInfo())},c.prototype.contains=function(l){return l?l===this||this.isDescendant(l):!1},c.prototype.isDescendant=function(l){var _,M,p,I,T;for(T=this.children,p=0,I=T.length;p<I;p++)if(_=T[p],l===_||(M=_.isDescendant(l),M))return!0;return!1},c.prototype.isAncestor=function(l){return l.isDescendant(this)},c.prototype.isPreceding=function(l){var _,M;return _=this.treePosition(l),M=this.treePosition(this),_===-1||M===-1?!1:_<M},c.prototype.isFollowing=function(l){var _,M;return _=this.treePosition(l),M=this.treePosition(this),_===-1||M===-1?!1:_>M},c.prototype.treePosition=function(l){var _,M;return M=0,_=!1,this.foreachTreeNode(this.document(),function(p){if(M++,!_&&p===l)return _=!0}),_?M:-1},c.prototype.foreachTreeNode=function(l,_){var M,p,I,T,P;for(l||(l=this.document()),T=l.children,p=0,I=T.length;p<I;p++){if(M=T[p],P=_(M))return P;if(P=this.foreachTreeNode(M,_),P)return P}},c})()}).call(lg)});var fa=S((cg,hg)=>{"use strict";(function(){var t,e=function(n,i){return function(){return n.apply(i,arguments)}},r={}.hasOwnProperty;hg.exports=t=(function(){function n(i){this.assertLegalName=e(this.assertLegalName,this),this.assertLegalChar=e(this.assertLegalChar,this);var o,s,a;i||(i={}),this.options=i,this.options.version||(this.options.version="1.0"),s=i.stringify||{};for(o in s)r.call(s,o)&&(a=s[o],this[o]=a)}return n.prototype.name=function(i){return this.options.noValidation?i:this.assertLegalName(""+i||"")},n.prototype.text=function(i){return this.options.noValidation?i:this.assertLegalChar(this.textEscape(""+i||""))},n.prototype.cdata=function(i){return this.options.noValidation?i:(i=""+i||"",i=i.replace("]]>","]]]]><![CDATA[>"),this.assertLegalChar(i))},n.prototype.comment=function(i){if(this.options.noValidation)return i;if(i=""+i||"",i.match(/--/))throw new Error("Comment text cannot contain double-hypen: "+i);return this.assertLegalChar(i)},n.prototype.raw=function(i){return this.options.noValidation?i:""+i||""},n.prototype.attValue=function(i){return this.options.noValidation?i:this.assertLegalChar(this.attEscape(i=""+i||""))},n.prototype.insTarget=function(i){return this.options.noValidation?i:this.assertLegalChar(""+i||"")},n.prototype.insValue=function(i){if(this.options.noValidation)return i;if(i=""+i||"",i.match(/\?>/))throw new Error("Invalid processing instruction value: "+i);return this.assertLegalChar(i)},n.prototype.xmlVersion=function(i){if(this.options.noValidation)return i;if(i=""+i||"",!i.match(/1\.[0-9]+/))throw new Error("Invalid version number: "+i);return i},n.prototype.xmlEncoding=function(i){if(this.options.noValidation)return i;if(i=""+i||"",!i.match(/^[A-Za-z](?:[A-Za-z0-9._-])*$/))throw new Error("Invalid encoding: "+i);return this.assertLegalChar(i)},n.prototype.xmlStandalone=function(i){return this.options.noValidation?i:i?"yes":"no"},n.prototype.dtdPubID=function(i){return this.options.noValidation?i:this.assertLegalChar(""+i||"")},n.prototype.dtdSysID=function(i){return this.options.noValidation?i:this.assertLegalChar(""+i||"")},n.prototype.dtdElementValue=function(i){return this.options.noValidation?i:this.assertLegalChar(""+i||"")},n.prototype.dtdAttType=function(i){return this.options.noValidation?i:this.assertLegalChar(""+i||"")},n.prototype.dtdAttDefault=function(i){return this.options.noValidation?i:this.assertLegalChar(""+i||"")},n.prototype.dtdEntityValue=function(i){return this.options.noValidation?i:this.assertLegalChar(""+i||"")},n.prototype.dtdNData=function(i){return this.options.noValidation?i:this.assertLegalChar(""+i||"")},n.prototype.convertAttKey="@",n.prototype.convertPIKey="?",n.prototype.convertTextKey="#text",n.prototype.convertCDataKey="#cdata",n.prototype.convertCommentKey="#comment",n.prototype.convertRawKey="#raw",n.prototype.assertLegalChar=function(i){var o,s;if(this.options.noValidation)return i;if(o="",this.options.version==="1.0"){if(o=/[\0-\x08\x0B\f\x0E-\x1F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,s=i.match(o))throw new Error("Invalid character in string: "+i+" at index "+s.index)}else if(this.options.version==="1.1"&&(o=/[\0\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,s=i.match(o)))throw new Error("Invalid character in string: "+i+" at index "+s.index);return i},n.prototype.assertLegalName=function(i){var o;if(this.options.noValidation)return i;if(this.assertLegalChar(i),o=/^([:A-Z_a-z\xC0-\xD6\xD8-\xF6\xF8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])([\x2D\.0-:A-Z_a-z\xB7\xC0-\xD6\xD8-\xF6\xF8-\u037D\u037F-\u1FFF\u200C\u200D\u203F\u2040\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])*$/,!i.match(o))throw new Error("Invalid character in name");return i},n.prototype.textEscape=function(i){var o;return this.options.noValidation?i:(o=this.options.noDoubleEncoding?/(?!&\S+;)&/g:/&/g,i.replace(o,"&").replace(/</g,"<").replace(/>/g,">").replace(/\r/g,"
"))},n.prototype.attEscape=function(i){var o;return this.options.noValidation?i:(o=this.options.noDoubleEncoding?/(?!&\S+;)&/g:/&/g,i.replace(o,"&").replace(/</g,"<").replace(/"/g,""").replace(/\t/g,"	").replace(/\n/g,"
").replace(/\r/g,"
"))},n})()}).call(cg)});var Kr=S((dg,pg)=>{"use strict";(function(){pg.exports={None:0,OpenTag:1,InsideTag:2,CloseTag:3}}).call(dg)});var ca=S((mg,gg)=>{"use strict";(function(){var t,e,r,n,i,o,s,a,u,d,w,E,y,g,h,v,R,N={}.hasOwnProperty;R=qe().assign,t=re(),u=Ai(),d=ji(),r=Ni(),n=Ri(),E=Mi(),g=ki(),h=Bi(),y=$i(),w=la(),i=Li(),o=qi(),s=Ci(),a=Fi(),e=Kr(),gg.exports=v=(function(){function D(m){var c,l,_;m||(m={}),this.options=m,l=m.writer||{};for(c in l)N.call(l,c)&&(_=l[c],this["_"+c]=this[c],this[c]=_)}return D.prototype.filterOptions=function(m){var c,l,_,M,p,I,T,P;return m||(m={}),m=R({},this.options,m),c={writer:this},c.pretty=m.pretty||!1,c.allowEmpty=m.allowEmpty||!1,c.indent=(l=m.indent)!=null?l:" ",c.newline=(_=m.newline)!=null?_:`
|
|
39
|
-
`,c.offset=(M=m.offset)!=null?M:0,c.dontPrettyTextNodes=(p=(I=m.dontPrettyTextNodes)!=null?I:m.dontprettytextnodes)!=null?p:0,c.spaceBeforeSlash=(T=(P=m.spaceBeforeSlash)!=null?P:m.spacebeforeslash)!=null?T:"",c.spaceBeforeSlash===!0&&(c.spaceBeforeSlash=" "),c.suppressPrettyCount=0,c.user={},c.state=e.None,c},D.prototype.indent=function(m,c,l){var _;return!c.pretty||c.suppressPrettyCount?"":c.pretty&&(_=(l||0)+c.offset+1,_>0)?new Array(_).join(c.indent):""},D.prototype.endline=function(m,c,l){return!c.pretty||c.suppressPrettyCount?"":c.newline},D.prototype.attribute=function(m,c,l){var _;return this.openAttribute(m,c,l),_=" "+m.name+'="'+m.value+'"',this.closeAttribute(m,c,l),_},D.prototype.cdata=function(m,c,l){var _;return this.openNode(m,c,l),c.state=e.OpenTag,_=this.indent(m,c,l)+"<![CDATA[",c.state=e.InsideTag,_+=m.value,c.state=e.CloseTag,_+="]]>"+this.endline(m,c,l),c.state=e.None,this.closeNode(m,c,l),_},D.prototype.comment=function(m,c,l){var _;return this.openNode(m,c,l),c.state=e.OpenTag,_=this.indent(m,c,l)+"<!-- ",c.state=e.InsideTag,_+=m.value,c.state=e.CloseTag,_+=" -->"+this.endline(m,c,l),c.state=e.None,this.closeNode(m,c,l),_},D.prototype.declaration=function(m,c,l){var _;return this.openNode(m,c,l),c.state=e.OpenTag,_=this.indent(m,c,l)+"<?xml",c.state=e.InsideTag,_+=' version="'+m.version+'"',m.encoding!=null&&(_+=' encoding="'+m.encoding+'"'),m.standalone!=null&&(_+=' standalone="'+m.standalone+'"'),c.state=e.CloseTag,_+=c.spaceBeforeSlash+"?>",_+=this.endline(m,c,l),c.state=e.None,this.closeNode(m,c,l),_},D.prototype.docType=function(m,c,l){var _,M,p,I,T;if(l||(l=0),this.openNode(m,c,l),c.state=e.OpenTag,I=this.indent(m,c,l),I+="<!DOCTYPE "+m.root().name,m.pubID&&m.sysID?I+=' PUBLIC "'+m.pubID+'" "'+m.sysID+'"':m.sysID&&(I+=' SYSTEM "'+m.sysID+'"'),m.children.length>0){for(I+=" [",I+=this.endline(m,c,l),c.state=e.InsideTag,T=m.children,M=0,p=T.length;M<p;M++)_=T[M],I+=this.writeChildNode(_,c,l+1);c.state=e.CloseTag,I+="]"}return c.state=e.CloseTag,I+=c.spaceBeforeSlash+">",I+=this.endline(m,c,l),c.state=e.None,this.closeNode(m,c,l),I},D.prototype.element=function(m,c,l){var _,M,p,I,T,P,L,C,B,$,x,q,j,J;l||(l=0),$=!1,x="",this.openNode(m,c,l),c.state=e.OpenTag,x+=this.indent(m,c,l)+"<"+m.name,q=m.attribs;for(B in q)N.call(q,B)&&(_=q[B],x+=this.attribute(_,c,l));if(p=m.children.length,I=p===0?null:m.children[0],p===0||m.children.every(function(k){return(k.type===t.Text||k.type===t.Raw)&&k.value===""}))c.allowEmpty?(x+=">",c.state=e.CloseTag,x+="</"+m.name+">"+this.endline(m,c,l)):(c.state=e.CloseTag,x+=c.spaceBeforeSlash+"/>"+this.endline(m,c,l));else if(c.pretty&&p===1&&(I.type===t.Text||I.type===t.Raw)&&I.value!=null)x+=">",c.state=e.InsideTag,c.suppressPrettyCount++,$=!0,x+=this.writeChildNode(I,c,l+1),c.suppressPrettyCount--,$=!1,c.state=e.CloseTag,x+="</"+m.name+">"+this.endline(m,c,l);else{if(c.dontPrettyTextNodes){for(j=m.children,T=0,L=j.length;T<L;T++)if(M=j[T],(M.type===t.Text||M.type===t.Raw)&&M.value!=null){c.suppressPrettyCount++,$=!0;break}}for(x+=">"+this.endline(m,c,l),c.state=e.InsideTag,J=m.children,P=0,C=J.length;P<C;P++)M=J[P],x+=this.writeChildNode(M,c,l+1);c.state=e.CloseTag,x+=this.indent(m,c,l)+"</"+m.name+">",$&&c.suppressPrettyCount--,x+=this.endline(m,c,l),c.state=e.None}return this.closeNode(m,c,l),x},D.prototype.writeChildNode=function(m,c,l){switch(m.type){case t.CData:return this.cdata(m,c,l);case t.Comment:return this.comment(m,c,l);case t.Element:return this.element(m,c,l);case t.Raw:return this.raw(m,c,l);case t.Text:return this.text(m,c,l);case t.ProcessingInstruction:return this.processingInstruction(m,c,l);case t.Dummy:return"";case t.Declaration:return this.declaration(m,c,l);case t.DocType:return this.docType(m,c,l);case t.AttributeDeclaration:return this.dtdAttList(m,c,l);case t.ElementDeclaration:return this.dtdElement(m,c,l);case t.EntityDeclaration:return this.dtdEntity(m,c,l);case t.NotationDeclaration:return this.dtdNotation(m,c,l);default:throw new Error("Unknown XML node type: "+m.constructor.name)}},D.prototype.processingInstruction=function(m,c,l){var _;return this.openNode(m,c,l),c.state=e.OpenTag,_=this.indent(m,c,l)+"<?",c.state=e.InsideTag,_+=m.target,m.value&&(_+=" "+m.value),c.state=e.CloseTag,_+=c.spaceBeforeSlash+"?>",_+=this.endline(m,c,l),c.state=e.None,this.closeNode(m,c,l),_},D.prototype.raw=function(m,c,l){var _;return this.openNode(m,c,l),c.state=e.OpenTag,_=this.indent(m,c,l),c.state=e.InsideTag,_+=m.value,c.state=e.CloseTag,_+=this.endline(m,c,l),c.state=e.None,this.closeNode(m,c,l),_},D.prototype.text=function(m,c,l){var _;return this.openNode(m,c,l),c.state=e.OpenTag,_=this.indent(m,c,l),c.state=e.InsideTag,_+=m.value,c.state=e.CloseTag,_+=this.endline(m,c,l),c.state=e.None,this.closeNode(m,c,l),_},D.prototype.dtdAttList=function(m,c,l){var _;return this.openNode(m,c,l),c.state=e.OpenTag,_=this.indent(m,c,l)+"<!ATTLIST",c.state=e.InsideTag,_+=" "+m.elementName+" "+m.attributeName+" "+m.attributeType,m.defaultValueType!=="#DEFAULT"&&(_+=" "+m.defaultValueType),m.defaultValue&&(_+=' "'+m.defaultValue+'"'),c.state=e.CloseTag,_+=c.spaceBeforeSlash+">"+this.endline(m,c,l),c.state=e.None,this.closeNode(m,c,l),_},D.prototype.dtdElement=function(m,c,l){var _;return this.openNode(m,c,l),c.state=e.OpenTag,_=this.indent(m,c,l)+"<!ELEMENT",c.state=e.InsideTag,_+=" "+m.name+" "+m.value,c.state=e.CloseTag,_+=c.spaceBeforeSlash+">"+this.endline(m,c,l),c.state=e.None,this.closeNode(m,c,l),_},D.prototype.dtdEntity=function(m,c,l){var _;return this.openNode(m,c,l),c.state=e.OpenTag,_=this.indent(m,c,l)+"<!ENTITY",c.state=e.InsideTag,m.pe&&(_+=" %"),_+=" "+m.name,m.value?_+=' "'+m.value+'"':(m.pubID&&m.sysID?_+=' PUBLIC "'+m.pubID+'" "'+m.sysID+'"':m.sysID&&(_+=' SYSTEM "'+m.sysID+'"'),m.nData&&(_+=" NDATA "+m.nData)),c.state=e.CloseTag,_+=c.spaceBeforeSlash+">"+this.endline(m,c,l),c.state=e.None,this.closeNode(m,c,l),_},D.prototype.dtdNotation=function(m,c,l){var _;return this.openNode(m,c,l),c.state=e.OpenTag,_=this.indent(m,c,l)+"<!NOTATION",c.state=e.InsideTag,_+=" "+m.name,m.pubID&&m.sysID?_+=' PUBLIC "'+m.pubID+'" "'+m.sysID+'"':m.pubID?_+=' PUBLIC "'+m.pubID+'"':m.sysID&&(_+=' SYSTEM "'+m.sysID+'"'),c.state=e.CloseTag,_+=c.spaceBeforeSlash+">"+this.endline(m,c,l),c.state=e.None,this.closeNode(m,c,l),_},D.prototype.openNode=function(m,c,l){},D.prototype.closeNode=function(m,c,l){},D.prototype.openAttribute=function(m,c,l){},D.prototype.closeAttribute=function(m,c,l){},D})()}).call(mg)});var Ui=S((yg,bg)=>{"use strict";(function(){var t,e,r=function(i,o){for(var s in o)n.call(o,s)&&(i[s]=o[s]);function a(){this.constructor=i}return a.prototype=o.prototype,i.prototype=new a,i.__super__=o.prototype,i},n={}.hasOwnProperty;e=ca(),bg.exports=t=(function(i){r(o,i);function o(s){o.__super__.constructor.call(this,s)}return o.prototype.document=function(s,a){var u,d,w,E,y;for(a=this.filterOptions(a),E="",y=s.children,d=0,w=y.length;d<w;d++)u=y[d],E+=this.writeChildNode(u,a,0);return a.pretty&&E.slice(-a.newline.length)===a.newline&&(E=E.slice(0,-a.newline.length)),E},o})(e)}).call(yg)});var ha=S((wg,_g)=>{"use strict";(function(){var t,e,r,n,i,o,s,a,u=function(w,E){for(var y in E)d.call(E,y)&&(w[y]=E[y]);function g(){this.constructor=w}return g.prototype=E.prototype,w.prototype=new g,w.__super__=E.prototype,w},d={}.hasOwnProperty;a=qe().isPlainObject,r=aa(),e=Em(),i=we(),t=re(),s=fa(),o=Ui(),_g.exports=n=(function(w){u(E,w);function E(y){E.__super__.constructor.call(this,null),this.name="#document",this.type=t.Document,this.documentURI=null,this.domConfig=new e,y||(y={}),y.writer||(y.writer=new o),this.options=y,this.stringify=new s(y)}return Object.defineProperty(E.prototype,"implementation",{value:new r}),Object.defineProperty(E.prototype,"doctype",{get:function(){var y,g,h,v;for(v=this.children,g=0,h=v.length;g<h;g++)if(y=v[g],y.type===t.DocType)return y;return null}}),Object.defineProperty(E.prototype,"documentElement",{get:function(){return this.rootObject||null}}),Object.defineProperty(E.prototype,"inputEncoding",{get:function(){return null}}),Object.defineProperty(E.prototype,"strictErrorChecking",{get:function(){return!1}}),Object.defineProperty(E.prototype,"xmlEncoding",{get:function(){return this.children.length!==0&&this.children[0].type===t.Declaration?this.children[0].encoding:null}}),Object.defineProperty(E.prototype,"xmlStandalone",{get:function(){return this.children.length!==0&&this.children[0].type===t.Declaration?this.children[0].standalone==="yes":!1}}),Object.defineProperty(E.prototype,"xmlVersion",{get:function(){return this.children.length!==0&&this.children[0].type===t.Declaration?this.children[0].version:"1.0"}}),Object.defineProperty(E.prototype,"URL",{get:function(){return this.documentURI}}),Object.defineProperty(E.prototype,"origin",{get:function(){return null}}),Object.defineProperty(E.prototype,"compatMode",{get:function(){return null}}),Object.defineProperty(E.prototype,"characterSet",{get:function(){return null}}),Object.defineProperty(E.prototype,"contentType",{get:function(){return null}}),E.prototype.end=function(y){var g;return g={},y?a(y)&&(g=y,y=this.options.writer):y=this.options.writer,y.document(this,y.filterOptions(g))},E.prototype.toString=function(y){return this.options.writer.document(this,this.options.writer.filterOptions(y))},E.prototype.createElement=function(y){throw new Error("This DOM method is not implemented."+this.debugInfo())},E.prototype.createDocumentFragment=function(){throw new Error("This DOM method is not implemented."+this.debugInfo())},E.prototype.createTextNode=function(y){throw new Error("This DOM method is not implemented."+this.debugInfo())},E.prototype.createComment=function(y){throw new Error("This DOM method is not implemented."+this.debugInfo())},E.prototype.createCDATASection=function(y){throw new Error("This DOM method is not implemented."+this.debugInfo())},E.prototype.createProcessingInstruction=function(y,g){throw new Error("This DOM method is not implemented."+this.debugInfo())},E.prototype.createAttribute=function(y){throw new Error("This DOM method is not implemented."+this.debugInfo())},E.prototype.createEntityReference=function(y){throw new Error("This DOM method is not implemented."+this.debugInfo())},E.prototype.getElementsByTagName=function(y){throw new Error("This DOM method is not implemented."+this.debugInfo())},E.prototype.importNode=function(y,g){throw new Error("This DOM method is not implemented."+this.debugInfo())},E.prototype.createElementNS=function(y,g){throw new Error("This DOM method is not implemented."+this.debugInfo())},E.prototype.createAttributeNS=function(y,g){throw new Error("This DOM method is not implemented."+this.debugInfo())},E.prototype.getElementsByTagNameNS=function(y,g){throw new Error("This DOM method is not implemented."+this.debugInfo())},E.prototype.getElementById=function(y){throw new Error("This DOM method is not implemented."+this.debugInfo())},E.prototype.adoptNode=function(y){throw new Error("This DOM method is not implemented."+this.debugInfo())},E.prototype.normalizeDocument=function(){throw new Error("This DOM method is not implemented."+this.debugInfo())},E.prototype.renameNode=function(y,g,h){throw new Error("This DOM method is not implemented."+this.debugInfo())},E.prototype.getElementsByClassName=function(y){throw new Error("This DOM method is not implemented."+this.debugInfo())},E.prototype.createEvent=function(y){throw new Error("This DOM method is not implemented."+this.debugInfo())},E.prototype.createRange=function(){throw new Error("This DOM method is not implemented."+this.debugInfo())},E.prototype.createNodeIterator=function(y,g,h){throw new Error("This DOM method is not implemented."+this.debugInfo())},E.prototype.createTreeWalker=function(y,g,h){throw new Error("This DOM method is not implemented."+this.debugInfo())},E})(i)}).call(wg)});var Sg=S((vg,Eg)=>{"use strict";(function(){var t,e,r,n,i,o,s,a,u,d,w,E,y,g,h,v,R,N,D,m,c,l,_,M,p={}.hasOwnProperty;M=qe(),l=M.isObject,c=M.isFunction,_=M.isPlainObject,m=M.getValue,t=re(),E=ha(),g=Mi(),n=Ni(),i=Ri(),v=ki(),D=Bi(),h=$i(),d=Ai(),w=ji(),o=Li(),a=Ci(),s=qi(),u=Fi(),r=ua(),N=fa(),R=Ui(),e=Kr(),Eg.exports=y=(function(){function I(T,P,L){var C;this.name="?xml",this.type=t.Document,T||(T={}),C={},T.writer?_(T.writer)&&(C=T.writer,T.writer=new R):T.writer=new R,this.options=T,this.writer=T.writer,this.writerOptions=this.writer.filterOptions(C),this.stringify=new N(T),this.onDataCallback=P||function(){},this.onEndCallback=L||function(){},this.currentNode=null,this.currentLevel=-1,this.openTags={},this.documentStarted=!1,this.documentCompleted=!1,this.root=null}return I.prototype.createChildNode=function(T){var P,L,C,B,$,x,q,j;switch(T.type){case t.CData:this.cdata(T.value);break;case t.Comment:this.comment(T.value);break;case t.Element:C={},q=T.attribs;for(L in q)p.call(q,L)&&(P=q[L],C[L]=P.value);this.node(T.name,C);break;case t.Dummy:this.dummy();break;case t.Raw:this.raw(T.value);break;case t.Text:this.text(T.value);break;case t.ProcessingInstruction:this.instruction(T.target,T.value);break;default:throw new Error("This XML node type is not supported in a JS object: "+T.constructor.name)}for(j=T.children,$=0,x=j.length;$<x;$++)B=j[$],this.createChildNode(B),B.type===t.Element&&this.up();return this},I.prototype.dummy=function(){return this},I.prototype.node=function(T,P,L){var C;if(T==null)throw new Error("Missing node name.");if(this.root&&this.currentLevel===-1)throw new Error("Document can only have one root node. "+this.debugInfo(T));return this.openCurrent(),T=m(T),P==null&&(P={}),P=m(P),l(P)||(C=[P,L],L=C[0],P=C[1]),this.currentNode=new g(this,T,P),this.currentNode.children=!1,this.currentLevel++,this.openTags[this.currentLevel]=this.currentNode,L!=null&&this.text(L),this},I.prototype.element=function(T,P,L){var C,B,$,x,q,j;if(this.currentNode&&this.currentNode.type===t.DocType)this.dtdElement.apply(this,arguments);else if(Array.isArray(T)||l(T)||c(T))for(x=this.options.noValidation,this.options.noValidation=!0,j=new E(this.options).element("TEMP_ROOT"),j.element(T),this.options.noValidation=x,q=j.children,B=0,$=q.length;B<$;B++)C=q[B],this.createChildNode(C),C.type===t.Element&&this.up();else this.node(T,P,L);return this},I.prototype.attribute=function(T,P){var L,C;if(!this.currentNode||this.currentNode.children)throw new Error("att() can only be used immediately after an ele() call in callback mode. "+this.debugInfo(T));if(T!=null&&(T=m(T)),l(T))for(L in T)p.call(T,L)&&(C=T[L],this.attribute(L,C));else c(P)&&(P=P.apply()),this.options.keepNullAttributes&&P==null?this.currentNode.attribs[T]=new r(this,T,""):P!=null&&(this.currentNode.attribs[T]=new r(this,T,P));return this},I.prototype.text=function(T){var P;return this.openCurrent(),P=new D(this,T),this.onData(this.writer.text(P,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},I.prototype.cdata=function(T){var P;return this.openCurrent(),P=new n(this,T),this.onData(this.writer.cdata(P,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},I.prototype.comment=function(T){var P;return this.openCurrent(),P=new i(this,T),this.onData(this.writer.comment(P,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},I.prototype.raw=function(T){var P;return this.openCurrent(),P=new v(this,T),this.onData(this.writer.raw(P,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},I.prototype.instruction=function(T,P){var L,C,B,$,x;if(this.openCurrent(),T!=null&&(T=m(T)),P!=null&&(P=m(P)),Array.isArray(T))for(L=0,$=T.length;L<$;L++)C=T[L],this.instruction(C);else if(l(T))for(C in T)p.call(T,C)&&(B=T[C],this.instruction(C,B));else c(P)&&(P=P.apply()),x=new h(this,T,P),this.onData(this.writer.processingInstruction(x,this.writerOptions,this.currentLevel+1),this.currentLevel+1);return this},I.prototype.declaration=function(T,P,L){var C;if(this.openCurrent(),this.documentStarted)throw new Error("declaration() must be the first node.");return C=new d(this,T,P,L),this.onData(this.writer.declaration(C,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},I.prototype.doctype=function(T,P,L){if(this.openCurrent(),T==null)throw new Error("Missing root node name.");if(this.root)throw new Error("dtd() must come before the root node.");return this.currentNode=new w(this,P,L),this.currentNode.rootNodeName=T,this.currentNode.children=!1,this.currentLevel++,this.openTags[this.currentLevel]=this.currentNode,this},I.prototype.dtdElement=function(T,P){var L;return this.openCurrent(),L=new s(this,T,P),this.onData(this.writer.dtdElement(L,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},I.prototype.attList=function(T,P,L,C,B){var $;return this.openCurrent(),$=new o(this,T,P,L,C,B),this.onData(this.writer.dtdAttList($,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},I.prototype.entity=function(T,P){var L;return this.openCurrent(),L=new a(this,!1,T,P),this.onData(this.writer.dtdEntity(L,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},I.prototype.pEntity=function(T,P){var L;return this.openCurrent(),L=new a(this,!0,T,P),this.onData(this.writer.dtdEntity(L,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},I.prototype.notation=function(T,P){var L;return this.openCurrent(),L=new u(this,T,P),this.onData(this.writer.dtdNotation(L,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},I.prototype.up=function(){if(this.currentLevel<0)throw new Error("The document node has no parent.");return this.currentNode?(this.currentNode.children?this.closeNode(this.currentNode):this.openNode(this.currentNode),this.currentNode=null):this.closeNode(this.openTags[this.currentLevel]),delete this.openTags[this.currentLevel],this.currentLevel--,this},I.prototype.end=function(){for(;this.currentLevel>=0;)this.up();return this.onEnd()},I.prototype.openCurrent=function(){if(this.currentNode)return this.currentNode.children=!0,this.openNode(this.currentNode)},I.prototype.openNode=function(T){var P,L,C,B;if(!T.isOpen){if(!this.root&&this.currentLevel===0&&T.type===t.Element&&(this.root=T),L="",T.type===t.Element){this.writerOptions.state=e.OpenTag,L=this.writer.indent(T,this.writerOptions,this.currentLevel)+"<"+T.name,B=T.attribs;for(C in B)p.call(B,C)&&(P=B[C],L+=this.writer.attribute(P,this.writerOptions,this.currentLevel));L+=(T.children?">":"/>")+this.writer.endline(T,this.writerOptions,this.currentLevel),this.writerOptions.state=e.InsideTag}else this.writerOptions.state=e.OpenTag,L=this.writer.indent(T,this.writerOptions,this.currentLevel)+"<!DOCTYPE "+T.rootNodeName,T.pubID&&T.sysID?L+=' PUBLIC "'+T.pubID+'" "'+T.sysID+'"':T.sysID&&(L+=' SYSTEM "'+T.sysID+'"'),T.children?(L+=" [",this.writerOptions.state=e.InsideTag):(this.writerOptions.state=e.CloseTag,L+=">"),L+=this.writer.endline(T,this.writerOptions,this.currentLevel);return this.onData(L,this.currentLevel),T.isOpen=!0}},I.prototype.closeNode=function(T){var P;if(!T.isClosed)return P="",this.writerOptions.state=e.CloseTag,T.type===t.Element?P=this.writer.indent(T,this.writerOptions,this.currentLevel)+"</"+T.name+">"+this.writer.endline(T,this.writerOptions,this.currentLevel):P=this.writer.indent(T,this.writerOptions,this.currentLevel)+"]>"+this.writer.endline(T,this.writerOptions,this.currentLevel),this.writerOptions.state=e.None,this.onData(P,this.currentLevel),T.isClosed=!0},I.prototype.onData=function(T,P){return this.documentStarted=!0,this.onDataCallback(T,P+1)},I.prototype.onEnd=function(){return this.documentCompleted=!0,this.onEndCallback()},I.prototype.debugInfo=function(T){return T==null?"":"node: <"+T+">"},I.prototype.ele=function(){return this.element.apply(this,arguments)},I.prototype.nod=function(T,P,L){return this.node(T,P,L)},I.prototype.txt=function(T){return this.text(T)},I.prototype.dat=function(T){return this.cdata(T)},I.prototype.com=function(T){return this.comment(T)},I.prototype.ins=function(T,P){return this.instruction(T,P)},I.prototype.dec=function(T,P,L){return this.declaration(T,P,L)},I.prototype.dtd=function(T,P,L){return this.doctype(T,P,L)},I.prototype.e=function(T,P,L){return this.element(T,P,L)},I.prototype.n=function(T,P,L){return this.node(T,P,L)},I.prototype.t=function(T){return this.text(T)},I.prototype.d=function(T){return this.cdata(T)},I.prototype.c=function(T){return this.comment(T)},I.prototype.r=function(T){return this.raw(T)},I.prototype.i=function(T,P){return this.instruction(T,P)},I.prototype.att=function(){return this.currentNode&&this.currentNode.type===t.DocType?this.attList.apply(this,arguments):this.attribute.apply(this,arguments)},I.prototype.a=function(){return this.currentNode&&this.currentNode.type===t.DocType?this.attList.apply(this,arguments):this.attribute.apply(this,arguments)},I.prototype.ent=function(T,P){return this.entity(T,P)},I.prototype.pent=function(T,P){return this.pEntity(T,P)},I.prototype.not=function(T,P){return this.notation(T,P)},I})()}).call(vg)});var Dg=S((Tg,Og)=>{"use strict";(function(){var t,e,r,n,i=function(s,a){for(var u in a)o.call(a,u)&&(s[u]=a[u]);function d(){this.constructor=s}return d.prototype=a.prototype,s.prototype=new d,s.__super__=a.prototype,s},o={}.hasOwnProperty;t=re(),n=ca(),e=Kr(),Og.exports=r=(function(s){i(a,s);function a(u,d){this.stream=u,a.__super__.constructor.call(this,d)}return a.prototype.endline=function(u,d,w){return u.isLastRootNode&&d.state===e.CloseTag?"":a.__super__.endline.call(this,u,d,w)},a.prototype.document=function(u,d){var w,E,y,g,h,v,R,N,D;for(R=u.children,E=y=0,h=R.length;y<h;E=++y)w=R[E],w.isLastRootNode=E===u.children.length-1;for(d=this.filterOptions(d),N=u.children,D=[],g=0,v=N.length;g<v;g++)w=N[g],D.push(this.writeChildNode(w,d,0));return D},a.prototype.attribute=function(u,d,w){return this.stream.write(a.__super__.attribute.call(this,u,d,w))},a.prototype.cdata=function(u,d,w){return this.stream.write(a.__super__.cdata.call(this,u,d,w))},a.prototype.comment=function(u,d,w){return this.stream.write(a.__super__.comment.call(this,u,d,w))},a.prototype.declaration=function(u,d,w){return this.stream.write(a.__super__.declaration.call(this,u,d,w))},a.prototype.docType=function(u,d,w){var E,y,g,h;if(w||(w=0),this.openNode(u,d,w),d.state=e.OpenTag,this.stream.write(this.indent(u,d,w)),this.stream.write("<!DOCTYPE "+u.root().name),u.pubID&&u.sysID?this.stream.write(' PUBLIC "'+u.pubID+'" "'+u.sysID+'"'):u.sysID&&this.stream.write(' SYSTEM "'+u.sysID+'"'),u.children.length>0){for(this.stream.write(" ["),this.stream.write(this.endline(u,d,w)),d.state=e.InsideTag,h=u.children,y=0,g=h.length;y<g;y++)E=h[y],this.writeChildNode(E,d,w+1);d.state=e.CloseTag,this.stream.write("]")}return d.state=e.CloseTag,this.stream.write(d.spaceBeforeSlash+">"),this.stream.write(this.endline(u,d,w)),d.state=e.None,this.closeNode(u,d,w)},a.prototype.element=function(u,d,w){var E,y,g,h,v,R,N,D,m,c;w||(w=0),this.openNode(u,d,w),d.state=e.OpenTag,this.stream.write(this.indent(u,d,w)+"<"+u.name),m=u.attribs;for(N in m)o.call(m,N)&&(E=m[N],this.attribute(E,d,w));if(g=u.children.length,h=g===0?null:u.children[0],g===0||u.children.every(function(l){return(l.type===t.Text||l.type===t.Raw)&&l.value===""}))d.allowEmpty?(this.stream.write(">"),d.state=e.CloseTag,this.stream.write("</"+u.name+">")):(d.state=e.CloseTag,this.stream.write(d.spaceBeforeSlash+"/>"));else if(d.pretty&&g===1&&(h.type===t.Text||h.type===t.Raw)&&h.value!=null)this.stream.write(">"),d.state=e.InsideTag,d.suppressPrettyCount++,D=!0,this.writeChildNode(h,d,w+1),d.suppressPrettyCount--,D=!1,d.state=e.CloseTag,this.stream.write("</"+u.name+">");else{for(this.stream.write(">"+this.endline(u,d,w)),d.state=e.InsideTag,c=u.children,v=0,R=c.length;v<R;v++)y=c[v],this.writeChildNode(y,d,w+1);d.state=e.CloseTag,this.stream.write(this.indent(u,d,w)+"</"+u.name+">")}return this.stream.write(this.endline(u,d,w)),d.state=e.None,this.closeNode(u,d,w)},a.prototype.processingInstruction=function(u,d,w){return this.stream.write(a.__super__.processingInstruction.call(this,u,d,w))},a.prototype.raw=function(u,d,w){return this.stream.write(a.__super__.raw.call(this,u,d,w))},a.prototype.text=function(u,d,w){return this.stream.write(a.__super__.text.call(this,u,d,w))},a.prototype.dtdAttList=function(u,d,w){return this.stream.write(a.__super__.dtdAttList.call(this,u,d,w))},a.prototype.dtdElement=function(u,d,w){return this.stream.write(a.__super__.dtdElement.call(this,u,d,w))},a.prototype.dtdEntity=function(u,d,w){return this.stream.write(a.__super__.dtdEntity.call(this,u,d,w))},a.prototype.dtdNotation=function(u,d,w){return this.stream.write(a.__super__.dtdNotation.call(this,u,d,w))},a})(n)}).call(Tg)});var Pg=S((xg,ut)=>{"use strict";(function(){var t,e,r,n,i,o,s,a,u,d;d=qe(),a=d.assign,u=d.isFunction,r=aa(),n=ha(),i=Sg(),s=Ui(),o=Dg(),t=re(),e=Kr(),ut.exports.create=function(w,E,y,g){var h,v;if(w==null)throw new Error("Root element needs a name.");return g=a({},E,y,g),h=new n(g),v=h.element(w),g.headless||(h.declaration(g),(g.pubID!=null||g.sysID!=null)&&h.dtd(g)),v},ut.exports.begin=function(w,E,y){var g;return u(w)&&(g=[w,E],E=g[0],y=g[1],w={}),E?new i(w,E,y):new n(w)},ut.exports.stringWriter=function(w){return new s(w)},ut.exports.streamWriter=function(w,E){return new o(w,E)},ut.exports.implementation=new r,ut.exports.nodeType=t,ut.exports.writerState=e}).call(xg)});var Ig=S(da=>{"use strict";(function(){"use strict";var t,e,r,n,i,o={}.hasOwnProperty;t=Pg(),e=Pi().defaults,n=function(s){return typeof s=="string"&&(s.indexOf("&")>=0||s.indexOf(">")>=0||s.indexOf("<")>=0)},i=function(s){return"<![CDATA["+r(s)+"]]>"},r=function(s){return s.replace("]]>","]]]]><![CDATA[>")},da.Builder=(function(){function s(a){var u,d,w;this.options={},d=e["0.2"];for(u in d)o.call(d,u)&&(w=d[u],this.options[u]=w);for(u in a)o.call(a,u)&&(w=a[u],this.options[u]=w)}return s.prototype.buildObject=function(a){var u,d,w,E,y;return u=this.options.attrkey,d=this.options.charkey,Object.keys(a).length===1&&this.options.rootName===e["0.2"].rootName?(y=Object.keys(a)[0],a=a[y]):y=this.options.rootName,w=(function(g){return function(h,v){var R,N,D,m,c,l;if(typeof v!="object")g.options.cdata&&n(v)?h.raw(i(v)):h.txt(v);else if(Array.isArray(v)){for(m in v)if(o.call(v,m)){N=v[m];for(c in N)D=N[c],h=w(h.ele(c),D).up()}}else for(c in v)if(o.call(v,c))if(N=v[c],c===u){if(typeof N=="object")for(R in N)l=N[R],h=h.att(R,l)}else if(c===d)g.options.cdata&&n(N)?h=h.raw(i(N)):h=h.txt(N);else if(Array.isArray(N))for(m in N)o.call(N,m)&&(D=N[m],typeof D=="string"?g.options.cdata&&n(D)?h=h.ele(c).raw(i(D)).up():h=h.ele(c,D).up():h=w(h.ele(c),D).up());else typeof N=="object"?h=w(h.ele(c),N).up():typeof N=="string"&&g.options.cdata&&n(N)?h=h.ele(c).raw(i(N)).up():(N==null&&(N=""),h=h.ele(c,N.toString()).up());return h}})(this),E=t.create(y,this.options.xmldec,this.options.doctype,{headless:this.options.headless,allowSurrogateChars:this.options.allowSurrogateChars}),w(E,a).end(this.options.renderOpts)},s})()}).call(da)});var Mg=S(Vi=>{"use strict";(function(t){t.parser=function(b,f){return new r(b,f)},t.SAXParser=r,t.SAXStream=d,t.createStream=u,t.MAX_BUFFER_LENGTH=64*1024;var e=["comment","sgmlDecl","textNode","tagName","doctype","procInstName","procInstBody","entity","attribName","attribValue","cdata","script"];t.EVENTS=["text","processinginstruction","sgmldeclaration","doctype","comment","opentagstart","attribute","opentag","closetag","opencdata","cdata","closecdata","error","end","ready","script","opennamespace","closenamespace"];function r(b,f){if(!(this instanceof r))return new r(b,f);var A=this;i(A),A.q=A.c="",A.bufferCheckPosition=t.MAX_BUFFER_LENGTH,A.opt=f||{},A.opt.lowercase=A.opt.lowercase||A.opt.lowercasetags,A.looseCase=A.opt.lowercase?"toLowerCase":"toUpperCase",A.tags=[],A.closed=A.closedRoot=A.sawRoot=!1,A.tag=A.error=null,A.strict=!!b,A.noscript=!!(b||A.opt.noscript),A.state=p.BEGIN,A.strictEntities=A.opt.strictEntities,A.ENTITIES=A.strictEntities?Object.create(t.XML_ENTITIES):Object.create(t.ENTITIES),A.attribList=[],A.opt.xmlns&&(A.ns=Object.create(h)),A.opt.unquotedAttributeValues===void 0&&(A.opt.unquotedAttributeValues=!b),A.trackPosition=A.opt.position!==!1,A.trackPosition&&(A.position=A.line=A.column=0),T(A,"onready")}Object.create||(Object.create=function(b){function f(){}f.prototype=b;var A=new f;return A}),Object.keys||(Object.keys=function(b){var f=[];for(var A in b)b.hasOwnProperty(A)&&f.push(A);return f});function n(b){for(var f=Math.max(t.MAX_BUFFER_LENGTH,10),A=0,O=0,K=e.length;O<K;O++){var Y=b[e[O]].length;if(Y>f)switch(e[O]){case"textNode":L(b);break;case"cdata":P(b,"oncdata",b.cdata),b.cdata="";break;case"script":P(b,"onscript",b.script),b.script="";break;default:B(b,"Max buffer length exceeded: "+e[O])}A=Math.max(A,Y)}var Q=t.MAX_BUFFER_LENGTH-A;b.bufferCheckPosition=Q+b.position}function i(b){for(var f=0,A=e.length;f<A;f++)b[e[f]]=""}function o(b){L(b),b.cdata!==""&&(P(b,"oncdata",b.cdata),b.cdata=""),b.script!==""&&(P(b,"onscript",b.script),b.script="")}r.prototype={end:function(){$(this)},write:Qr,resume:function(){return this.error=null,this},close:function(){return this.write(null)},flush:function(){o(this)}};var s;try{s=require("stream").Stream}catch{s=function(){}}s||(s=function(){});var a=t.EVENTS.filter(function(b){return b!=="error"&&b!=="end"});function u(b,f){return new d(b,f)}function d(b,f){if(!(this instanceof d))return new d(b,f);s.apply(this),this._parser=new r(b,f),this.writable=!0,this.readable=!0;var A=this;this._parser.onend=function(){A.emit("end")},this._parser.onerror=function(O){A.emit("error",O),A._parser.error=null},this._decoder=null,a.forEach(function(O){Object.defineProperty(A,"on"+O,{get:function(){return A._parser["on"+O]},set:function(K){if(!K)return A.removeAllListeners(O),A._parser["on"+O]=K,K;A.on(O,K)},enumerable:!0,configurable:!1})})}d.prototype=Object.create(s.prototype,{constructor:{value:d}}),d.prototype.write=function(b){if(typeof Buffer=="function"&&typeof Buffer.isBuffer=="function"&&Buffer.isBuffer(b)){if(!this._decoder){var f=require("string_decoder").StringDecoder;this._decoder=new f("utf8")}b=this._decoder.write(b)}return this._parser.write(b.toString()),this.emit("data",b),!0},d.prototype.end=function(b){return b&&b.length&&this.write(b),this._parser.end(),!0},d.prototype.on=function(b,f){var A=this;return!A._parser["on"+b]&&a.indexOf(b)!==-1&&(A._parser["on"+b]=function(){var O=arguments.length===1?[arguments[0]]:Array.apply(null,arguments);O.splice(0,0,b),A.emit.apply(A,O)}),s.prototype.on.call(A,b,f)};var w="[CDATA[",E="DOCTYPE",y="http://www.w3.org/XML/1998/namespace",g="http://www.w3.org/2000/xmlns/",h={xml:y,xmlns:g},v=/[:_A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]/,R=/[:_A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\u00B7\u0300-\u036F\u203F-\u2040.\d-]/,N=/[#:_A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]/,D=/[#:_A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\u00B7\u0300-\u036F\u203F-\u2040.\d-]/;function m(b){return b===" "||b===`
|
|
40
|
-
`||
|
|
41
|
-
Line: `+
|
|
42
|
-
Column: `+
|
|
43
|
-
Char: `+
|
|
44
|
-
Actual: `+
|
|
45
|
-
Actual: `+
|
|
46
|
-
`?(
|
|
47
|
-
`?(
|
|
48
|
-
`?(f.line++,f.column=0):f.column++);f.cdata+=b.substring(Y,A-1),O==="]"&&(f.state=p.CDATA_ENDING);continue;case p.CDATA_ENDING:O==="]"?f.state=p.CDATA_ENDING_2:(f.cdata+="]"+O,f.state=p.CDATA);continue;case p.CDATA_ENDING_2:O===">"?(f.cdata&&P(f,"oncdata",f.cdata),P(f,"onclosecdata"),f.cdata="",f.state=p.TEXT):O==="]"?f.cdata+="]":(f.cdata+="]]"+O,f.state=p.CDATA);continue;case p.PROC_INST:O==="?"?f.state=p.PROC_INST_ENDING:m(O)?f.state=p.PROC_INST_BODY:f.procInstName+=O;continue;case p.PROC_INST_BODY:if(!f.procInstBody&&m(O))continue;O==="?"?f.state=p.PROC_INST_ENDING:f.procInstBody+=O;continue;case p.PROC_INST_ENDING:O===">"?(P(f,"onprocessinginstruction",{name:f.procInstName,body:f.procInstBody}),f.procInstName=f.procInstBody="",f.state=p.TEXT):(f.procInstBody+="?"+O,f.state=p.PROC_INST_BODY);continue;case p.OPEN_TAG:_(R,O)?f.tagName+=O:(q(f),O===">"?k(f):O==="/"?f.state=p.OPEN_TAG_SLASH:(m(O)||x(f,"Invalid character in tag name"),f.state=p.ATTRIB));continue;case p.OPEN_TAG_SLASH:O===">"?(k(f,!0),ge(f)):(x(f,"Forward-slash in opening tag not followed by >"),f.state=p.ATTRIB);continue;case p.ATTRIB:if(m(O))continue;O===">"?k(f):O==="/"?f.state=p.OPEN_TAG_SLASH:_(v,O)?(f.attribName=O,f.attribValue="",f.state=p.ATTRIB_NAME):x(f,"Invalid attribute name");continue;case p.ATTRIB_NAME:O==="="?f.state=p.ATTRIB_VALUE:O===">"?(x(f,"Attribute without value"),f.attribValue=f.attribName,J(f),k(f)):m(O)?f.state=p.ATTRIB_NAME_SAW_WHITE:_(R,O)?f.attribName+=O:x(f,"Invalid attribute name");continue;case p.ATTRIB_NAME_SAW_WHITE:if(O==="=")f.state=p.ATTRIB_VALUE;else{if(m(O))continue;x(f,"Attribute without value"),f.tag.attributes[f.attribName]="",f.attribValue="",P(f,"onattribute",{name:f.attribName,value:""}),f.attribName="",O===">"?k(f):_(v,O)?(f.attribName=O,f.state=p.ATTRIB_NAME):(x(f,"Invalid attribute name"),f.state=p.ATTRIB)}continue;case p.ATTRIB_VALUE:if(m(O))continue;c(O)?(f.q=O,f.state=p.ATTRIB_VALUE_QUOTED):(f.opt.unquotedAttributeValues||B(f,"Unquoted attribute value"),f.state=p.ATTRIB_VALUE_UNQUOTED,f.attribValue=O);continue;case p.ATTRIB_VALUE_QUOTED:if(O!==f.q){O==="&"?f.state=p.ATTRIB_VALUE_ENTITY_Q:f.attribValue+=O;continue}J(f),f.q="",f.state=p.ATTRIB_VALUE_CLOSED;continue;case p.ATTRIB_VALUE_CLOSED:m(O)?f.state=p.ATTRIB:O===">"?k(f):O==="/"?f.state=p.OPEN_TAG_SLASH:_(v,O)?(x(f,"No whitespace between attributes"),f.attribName=O,f.attribValue="",f.state=p.ATTRIB_NAME):x(f,"Invalid attribute name");continue;case p.ATTRIB_VALUE_UNQUOTED:if(!l(O)){O==="&"?f.state=p.ATTRIB_VALUE_ENTITY_U:f.attribValue+=O;continue}J(f),O===">"?k(f):f.state=p.ATTRIB;continue;case p.CLOSE_TAG:if(f.tagName)O===">"?ge(f):_(R,O)?f.tagName+=O:f.script?(f.script+="</"+f.tagName,f.tagName="",f.state=p.SCRIPT):(m(O)||x(f,"Invalid tagname in closing tag"),f.state=p.CLOSE_TAG_SAW_WHITE);else{if(m(O))continue;M(v,O)?f.script?(f.script+="</"+O,f.state=p.SCRIPT):x(f,"Invalid tagname in closing tag."):f.tagName=O}continue;case p.CLOSE_TAG_SAW_WHITE:if(m(O))continue;O===">"?ge(f):x(f,"Invalid characters in closing tag");continue;case p.TEXT_ENTITY:case p.ATTRIB_VALUE_ENTITY_Q:case p.ATTRIB_VALUE_ENTITY_U:var Q,ie;switch(f.state){case p.TEXT_ENTITY:Q=p.TEXT,ie="textNode";break;case p.ATTRIB_VALUE_ENTITY_Q:Q=p.ATTRIB_VALUE_QUOTED,ie="attribValue";break;case p.ATTRIB_VALUE_ENTITY_U:Q=p.ATTRIB_VALUE_UNQUOTED,ie="attribValue";break}if(O===";"){var oe=Fe(f);f.opt.unparsedEntities&&!Object.values(t.XML_ENTITIES).includes(oe)?(f.entity="",f.state=Q,f.write(oe)):(f[ie]+=oe,f.entity="",f.state=Q)}else _(f.entity.length?D:N,O)?f.entity+=O:(x(f,"Invalid character in entity name"),f[ie]+="&"+f.entity+O,f.entity="",f.state=Q);continue;default:throw new Error(f,"Unknown state: "+f.state)}return f.position>=f.bufferCheckPosition&&n(f),f}String.fromCodePoint||(function(){var b=String.fromCharCode,f=Math.floor,A=function(){var O=16384,K=[],Y,Q,ie=-1,oe=arguments.length;if(!oe)return"";for(var Ke="";++ie<oe;){var z=Number(arguments[ie]);if(!isFinite(z)||z<0||z>1114111||f(z)!==z)throw RangeError("Invalid code point: "+z);z<=65535?K.push(z):(z-=65536,Y=(z>>10)+55296,Q=z%1024+56320,K.push(Y,Q)),(ie+1===oe||K.length>O)&&(Ke+=b.apply(null,K),K.length=0)}return Ke};Object.defineProperty?Object.defineProperty(String,"fromCodePoint",{value:A,configurable:!0,writable:!0}):String.fromCodePoint=A})()})(typeof Vi>"u"?Vi.sax={}:Vi)});var Ng=S(pa=>{"use strict";(function(){"use strict";pa.stripBOM=function(t){return t[0]==="\uFEFF"?t.substring(1):t}}).call(pa)});var ma=S(Tt=>{"use strict";(function(){"use strict";var t;t=new RegExp(/(?!xmlns)^.*:/),Tt.normalize=function(e){return e.toLowerCase()},Tt.firstCharLowerCase=function(e){return e.charAt(0).toLowerCase()+e.slice(1)},Tt.stripPrefix=function(e){return e.replace(t,"")},Tt.parseNumbers=function(e){return isNaN(e)||(e=e%1===0?parseInt(e,10):parseFloat(e)),e},Tt.parseBooleans=function(e){return/^(?:true|false)$/i.test(e)&&(e=e.toLowerCase()==="true"),e}}).call(Tt)});var Rg=S(Ve=>{"use strict";(function(){"use strict";var t,e,r,n,i,o,s,a,u,d=function(y,g){return function(){return y.apply(g,arguments)}},w=function(y,g){for(var h in g)E.call(g,h)&&(y[h]=g[h]);function v(){this.constructor=y}return v.prototype=g.prototype,y.prototype=new v,y.__super__=g.prototype,y},E={}.hasOwnProperty;a=Mg(),n=require("events"),t=Ng(),s=ma(),u=require("timers").setImmediate,e=Pi().defaults,i=function(y){return typeof y=="object"&&y!=null&&Object.keys(y).length===0},o=function(y,g,h){var v,R,N;for(v=0,R=y.length;v<R;v++)N=y[v],g=N(g,h);return g},r=function(y,g,h){var v;return v=Object.create(null),v.value=h,v.writable=!0,v.enumerable=!0,v.configurable=!0,Object.defineProperty(y,g,v)},Ve.Parser=(function(y){w(g,y);function g(h){this.parseStringPromise=d(this.parseStringPromise,this),this.parseString=d(this.parseString,this),this.reset=d(this.reset,this),this.assignOrPush=d(this.assignOrPush,this),this.processAsync=d(this.processAsync,this);var v,R,N;if(!(this instanceof Ve.Parser))return new Ve.Parser(h);this.options={},R=e["0.2"];for(v in R)E.call(R,v)&&(N=R[v],this.options[v]=N);for(v in h)E.call(h,v)&&(N=h[v],this.options[v]=N);this.options.xmlns&&(this.options.xmlnskey=this.options.attrkey+"ns"),this.options.normalizeTags&&(this.options.tagNameProcessors||(this.options.tagNameProcessors=[]),this.options.tagNameProcessors.unshift(s.normalize)),this.reset()}return g.prototype.processAsync=function(){var h,v;try{return this.remaining.length<=this.options.chunkSize?(h=this.remaining,this.remaining="",this.saxParser=this.saxParser.write(h),this.saxParser.close()):(h=this.remaining.substr(0,this.options.chunkSize),this.remaining=this.remaining.substr(this.options.chunkSize,this.remaining.length),this.saxParser=this.saxParser.write(h),u(this.processAsync))}catch(R){if(v=R,!this.saxParser.errThrown)return this.saxParser.errThrown=!0,this.emit(v)}},g.prototype.assignOrPush=function(h,v,R){return v in h?(h[v]instanceof Array||r(h,v,[h[v]]),h[v].push(R)):this.options.explicitArray?r(h,v,[R]):r(h,v,R)},g.prototype.reset=function(){var h,v,R,N;return this.removeAllListeners(),this.saxParser=a.parser(this.options.strict,{trim:!1,normalize:!1,xmlns:this.options.xmlns}),this.saxParser.errThrown=!1,this.saxParser.onerror=(function(D){return function(m){if(D.saxParser.resume(),!D.saxParser.errThrown)return D.saxParser.errThrown=!0,D.emit("error",m)}})(this),this.saxParser.onend=(function(D){return function(){if(!D.saxParser.ended)return D.saxParser.ended=!0,D.emit("end",D.resultObject)}})(this),this.saxParser.ended=!1,this.EXPLICIT_CHARKEY=this.options.explicitCharkey,this.resultObject=null,N=[],h=this.options.attrkey,v=this.options.charkey,this.saxParser.onopentag=(function(D){return function(m){var c,l,_,M,p;if(_={},_[v]="",!D.options.ignoreAttrs){p=m.attributes;for(c in p)E.call(p,c)&&(!(h in _)&&!D.options.mergeAttrs&&(_[h]={}),l=D.options.attrValueProcessors?o(D.options.attrValueProcessors,m.attributes[c],c):m.attributes[c],M=D.options.attrNameProcessors?o(D.options.attrNameProcessors,c):c,D.options.mergeAttrs?D.assignOrPush(_,M,l):r(_[h],M,l))}return _["#name"]=D.options.tagNameProcessors?o(D.options.tagNameProcessors,m.name):m.name,D.options.xmlns&&(_[D.options.xmlnskey]={uri:m.uri,local:m.local}),N.push(_)}})(this),this.saxParser.onclosetag=(function(D){return function(){var m,c,l,_,M,p,I,T,P,L;if(p=N.pop(),M=p["#name"],(!D.options.explicitChildren||!D.options.preserveChildrenOrder)&&delete p["#name"],p.cdata===!0&&(m=p.cdata,delete p.cdata),P=N[N.length-1],p[v].match(/^\s*$/)&&!m?(c=p[v],delete p[v]):(D.options.trim&&(p[v]=p[v].trim()),D.options.normalize&&(p[v]=p[v].replace(/\s{2,}/g," ").trim()),p[v]=D.options.valueProcessors?o(D.options.valueProcessors,p[v],M):p[v],Object.keys(p).length===1&&v in p&&!D.EXPLICIT_CHARKEY&&(p=p[v])),i(p)&&(typeof D.options.emptyTag=="function"?p=D.options.emptyTag():p=D.options.emptyTag!==""?D.options.emptyTag:c),D.options.validator!=null&&(L="/"+(function(){var C,B,$;for($=[],C=0,B=N.length;C<B;C++)_=N[C],$.push(_["#name"]);return $})().concat(M).join("/"),(function(){var C;try{return p=D.options.validator(L,P&&P[M],p)}catch(B){return C=B,D.emit("error",C)}})()),D.options.explicitChildren&&!D.options.mergeAttrs&&typeof p=="object"){if(!D.options.preserveChildrenOrder)_={},D.options.attrkey in p&&(_[D.options.attrkey]=p[D.options.attrkey],delete p[D.options.attrkey]),!D.options.charsAsChildren&&D.options.charkey in p&&(_[D.options.charkey]=p[D.options.charkey],delete p[D.options.charkey]),Object.getOwnPropertyNames(p).length>0&&(_[D.options.childkey]=p),p=_;else if(P){P[D.options.childkey]=P[D.options.childkey]||[],I={};for(l in p)E.call(p,l)&&r(I,l,p[l]);P[D.options.childkey].push(I),delete p["#name"],Object.keys(p).length===1&&v in p&&!D.EXPLICIT_CHARKEY&&(p=p[v])}}return N.length>0?D.assignOrPush(P,M,p):(D.options.explicitRoot&&(T=p,p={},r(p,M,T)),D.resultObject=p,D.saxParser.ended=!0,D.emit("end",D.resultObject))}})(this),R=(function(D){return function(m){var c,l;if(l=N[N.length-1],l)return l[v]+=m,D.options.explicitChildren&&D.options.preserveChildrenOrder&&D.options.charsAsChildren&&(D.options.includeWhiteChars||m.replace(/\\n/g,"").trim()!=="")&&(l[D.options.childkey]=l[D.options.childkey]||[],c={"#name":"__text__"},c[v]=m,D.options.normalize&&(c[v]=c[v].replace(/\s{2,}/g," ").trim()),l[D.options.childkey].push(c)),l}})(this),this.saxParser.ontext=R,this.saxParser.oncdata=(function(D){return function(m){var c;if(c=R(m),c)return c.cdata=!0}})(this)},g.prototype.parseString=function(h,v){var R;v!=null&&typeof v=="function"&&(this.on("end",function(N){return this.reset(),v(null,N)}),this.on("error",function(N){return this.reset(),v(N)}));try{return h=h.toString(),h.trim()===""?(this.emit("end",null),!0):(h=t.stripBOM(h),this.options.async?(this.remaining=h,u(this.processAsync),this.saxParser):this.saxParser.write(h).close())}catch(N){if(R=N,this.saxParser.errThrown||this.saxParser.ended){if(this.saxParser.ended)throw R}else return this.emit("error",R),this.saxParser.errThrown=!0}},g.prototype.parseStringPromise=function(h){return new Promise((function(v){return function(R,N){return v.parseString(h,function(D,m){return D?N(D):R(m)})}})(this))},g})(n),Ve.parseString=function(y,g,h){var v,R,N;return h!=null?(typeof h=="function"&&(v=h),typeof g=="object"&&(R=g)):(typeof g=="function"&&(v=g),R={}),N=new Ve.Parser(R),N.parseString(y,v)},Ve.parseStringPromise=function(y,g){var h,v;return typeof g=="object"&&(h=g),v=new Ve.Parser(h),v.parseStringPromise(y)}}).call(Ve)});var Ag=S(He=>{"use strict";(function(){"use strict";var t,e,r,n,i=function(s,a){for(var u in a)o.call(a,u)&&(s[u]=a[u]);function d(){this.constructor=s}return d.prototype=a.prototype,s.prototype=new d,s.__super__=a.prototype,s},o={}.hasOwnProperty;e=Pi(),t=Ig(),r=Rg(),n=ma(),He.defaults=e.defaults,He.processors=n,He.ValidationError=(function(s){i(a,s);function a(u){this.message=u}return a})(Error),He.Builder=t.Builder,He.Parser=r.Parser,He.parseString=r.parseString,He.parseStringPromise=r.parseStringPromise}).call(He)});var k2={};Hg(k2,{ConnectorRunnerFile:()=>ya});module.exports=Wg(k2);var er=Te(require("node:process")),tn=class{#e="connector-runtime";#t;constructor(e,r){this.#t=r,er.default.on?er.default.on("message",n=>{n.cmd===this.#e&&r.logger.verbose(`${er.default.pid} Received message from parent process:`,n)}):r.logger.warn("IPC channel is not available. process.on is undefined."),er.default.send||r.logger.warn("IPC channel is not available. process.send is undefined."),e.actions?.forEach(n=>{if(n.config.templates===void 0)return;let i={};Object.entries(n.config.templates).forEach(([o,s])=>{try{i[o]=r.templating.compile(s)}catch(a){r.logger.error(`Error compiling template ${o} for action ${n.identifier}`,a)}}),n.config.parsedTemplates=i})}init=()=>Promise.resolve();start=()=>Promise.resolve();stop=()=>Promise.resolve();set callbackFunction(e){this.connectorSDK.receiver.registerCallback(this.#r(e))}get connectorSDK(){return this.#t}#r(e){return async r=>{let n=await this.#t.receiver.getActionConfig(r);return n?e(r,n):this.#t.receiver.responses.badRequest("Action not found")(r)}}};var _e=class{info(){}debug(){}error(){}warn(){}verbose(){}};var Fg=Te(require("node:events")),jg=Te(require("node:path"));var tr=class{static TYPE="delete";#e;#t;constructor(e,r=new _e){this.#e=e,this.#t=r}async execute(e){let{remotePath:r}=e;if(!r)throw new Error("Missing required parameter: remotePath");this.#t.debug(`Deleting file at ${r}`);try{await this.#e.delete(r)}catch(n){throw this.#t.error(`Error deleting file at ${r}: ${n instanceof Error?n.message:"Unknown error"}`),n}}};var _a=Te(require("crypto")),nn=new Uint8Array(256),rn=nn.length;function Xi(){return rn>nn.length-16&&(_a.default.randomFillSync(nn),rn=0),nn.slice(rn,rn+=16)}var ce=[];for(let t=0;t<256;++t)ce.push((t+256).toString(16).slice(1));function va(t,e=0){return ce[t[e+0]]+ce[t[e+1]]+ce[t[e+2]]+ce[t[e+3]]+"-"+ce[t[e+4]]+ce[t[e+5]]+"-"+ce[t[e+6]]+ce[t[e+7]]+"-"+ce[t[e+8]]+ce[t[e+9]]+"-"+ce[t[e+10]]+ce[t[e+11]]+ce[t[e+12]]+ce[t[e+13]]+ce[t[e+14]]+ce[t[e+15]]}var Ea=Te(require("crypto")),Ki={randomUUID:Ea.default.randomUUID};function Xg(t,e,r){if(Ki.randomUUID&&!e&&!t)return Ki.randomUUID();t=t||{};let n=t.random||(t.rng||Xi)();if(n[6]=n[6]&15|64,n[8]=n[8]&63|128,e){r=r||0;for(let i=0;i<16;++i)e[r+i]=n[i];return e}return va(n)}var Gi=Xg;var rr=class{static TYPE="download";#e;#t;#r;constructor(e,r,n=new _e){this.#e=e,this.#t=r,this.#r=n}async execute(e){let{remotePath:r}=e;if(!r)throw new Error("Missing required parameter: remotePath");let n=r.split(".").pop(),i=`downloaded-${Gi()}.${n}`;this.#r.debug(`Reading file from ${r} and writing to ${i}`);let o;try{o=await this.#e.read(r),await this.#t.write(i,o)}catch(s){throw this.#r.error(`Error reading file from ${r}: ${s instanceof Error?s.message:"Unknown error"}`),s}finally{o?.close()}return{pathDsn:this.#t.pathAsDsn(i),path:i}}};var Hi=Te(require("node:path")),Lg=require("node:stream");var Pe=Te(require("node:process")),me=Te(Fh()),jh=(o=>(o.error="error",o.warn="warn",o.info="info",o.http="http",o.debug="debug",o))(jh||{}),Cr=class t{static instance;logger;#e;constructor(e="default",r="info"){this.logger=me.default.createLogger({level:r,format:me.default.format.combine(me.default.format.label({label:e}),me.default.format.timestamp(),me.default.format.json(),me.default.format.errors({stack:!0}))});let n=!1;(Pe.default.env.NODE_ENV!=="production"||Pe.default.env.LOG_TO_CONSOLE==="true")&&(n=!0,this.logger.add(new me.default.transports.Console({format:me.default.format.printf(({label:i,level:o,message:s})=>{let a=new Date().toLocaleString();return`[${i}] ${Pe.default.pid} - ${a} ${o}: ${s}`})}))),Pe.default.env.LOG_TO_FILE==="true"&&(n=!0,this.logger.add(new me.default.transports.File({filename:"error.log",level:"error"})),this.logger.add(new me.default.transports.File({filename:"combined.log"}))),n||this.logger.add(new me.default.transports.Console({format:me.default.format.printf(({label:i,level:o,message:s})=>`[${i}] ${o}: ${s}`)}))}static getInstance(e,r){return t.instance||(t.instance=new t(e??"default",t.#r(r))),t.instance}setDatadogTransport(e){let r=e?.apiKey??Pe.default.env.DATADOG_API_KEY;if(!r)return this.debug("DATADOG_API_KEY is not set, cannot add Datadog transport"),this;let n=new URLSearchParams({"dd-api-key":r,ddsource:e?.source??Pe.default.env.DD_SOURCE??"nodejs",service:e?.service??Pe.default.env.DD_SERVICE??"unknown",env:e?.env??Pe.default.env.DD_ENV??"prod"});e?.tags&&n.append("ddtags",Object.entries(e.tags).map(([o,s])=>`${o}:${s}`).join(","));let i={host:`http-intake.logs.${Pe.default.env.DD_SITE??"datadoghq.eu"}`,path:`/api/v2/logs?${n.toString()}`,ssl:!0,batch:!0,format:me.default.format.json(),level:"info"};return this.#e&&this.logger.remove(this.#e),this.#e=new me.default.transports.Http(i),this.logger.add(this.#e),this}info(...e){this.#t(this.logger.info,...e)}static info(...e){this.getInstance().info(...e)}debug(...e){this.#t(this.logger.debug,...e)}static debug(...e){this.getInstance().debug(...e)}error(...e){this.#t(this.logger.error,...e)}static error(...e){this.getInstance().error(...e)}warn(...e){this.#t(this.logger.warn,...e)}static warn(...e){this.getInstance().warn(...e)}verbose(...e){this.#t(this.logger.verbose,...e)}static verbose(...e){this.getInstance().verbose(...e)}#t(e,...r){try{let n=r.map(i=>typeof i=="object"?JSON.stringify(i):String(i));e(n.join(" "),...r)}catch(n){console.error("unknown error in log, function",n)}}static#r=e=>{if(e!==void 0)return e;let r=Pe.default.env.LOG_LEVEL||"info",i=!Object.values(jh).includes(r);return i&&(r="info"),i&&console.error(`Invalid log level: ${r} only allow; 'error', 'warn', 'info', 'debug', 'trace'. Using info as default.`),r}};var Cg=Te(fm()),qg=Te(Ag()),Ot=class t{#e;#t;constructor(e=void 0){this.#e=e,this.#t=Cr.getInstance(),this.#t.info(`FileHandler initialized with delimiter: ${e}`)}async handleBuffer(e,r,n,i){let o;switch(t.getExtension(e)){case".csv":o=await this.parseCSV(r,n,i);break;default:return this.handle(e,r.toString(),n,i)}return o}async handle(e,r,n,i){let o;switch(t.getExtension(e)){case".xml":o=await this.parseXML(r,n);break;case".json":o=JSON.parse(r);break;default:Cr.getInstance().error(`Unsupported file type: ${e}`)}return o}async parseXML(e,r){try{let n=await qg.default.parseStringPromise(e,{explicitArray:!1});return this.xmlOptions(n,r)}catch(n){throw new Error(`Error parsing XML content: ${n.message}`)}}async parseCSV(e,r,n){try{let i=Lg.Readable.from(e),o=!0;return Object.keys(n??{}).includes("noHeader")&&(o=(n??{}).noHeader===!0),(0,Cg.default)({delimiter:this.#e??",",noheader:o}).fromStream(i)}catch(i){throw this.#t.error(`Error parsing CSV: ${i.message}`),new Error(`Error parsing CSV content: ${i.message}`)}}xmlOptions(e,r){let n=i=>{if(typeof i=="object")for(let o of Object.keys(i)){let s=i[o];r.includes(o)?Array.isArray(s)||(i[o]=[s]):o!=="_text"&&(i[o]=n(s))}return i};return n(e)}csvOptions(e,r){let n;return Array.isArray(r)&&r.length>0?n={headers:r}:n=e.split(`
|
|
49
|
-
`)[0].trim().split(",").length>1?{headers:!0}:{noheader:!0},n}stringify(
|
|
244
|
+
`),Error.captureStackTrace(this,e)}};ane.exports=e=>{if(e.length>2)throw new cN(e);function t(n={}){this.options=n}t.prototype.transform=e;function r(n){return new t(n)}return r.Format=t,r}});var fne=E((fvt,lne)=>{"use strict";var une={};lne.exports=une;var cne={reset:[0,0],bold:[1,22],dim:[2,22],italic:[3,23],underline:[4,24],inverse:[7,27],hidden:[8,28],strikethrough:[9,29],black:[30,39],red:[31,39],green:[32,39],yellow:[33,39],blue:[34,39],magenta:[35,39],cyan:[36,39],white:[37,39],gray:[90,39],grey:[90,39],brightRed:[91,39],brightGreen:[92,39],brightYellow:[93,39],brightBlue:[94,39],brightMagenta:[95,39],brightCyan:[96,39],brightWhite:[97,39],bgBlack:[40,49],bgRed:[41,49],bgGreen:[42,49],bgYellow:[43,49],bgBlue:[44,49],bgMagenta:[45,49],bgCyan:[46,49],bgWhite:[47,49],bgGray:[100,49],bgGrey:[100,49],bgBrightRed:[101,49],bgBrightGreen:[102,49],bgBrightYellow:[103,49],bgBrightBlue:[104,49],bgBrightMagenta:[105,49],bgBrightCyan:[106,49],bgBrightWhite:[107,49],blackBG:[40,49],redBG:[41,49],greenBG:[42,49],yellowBG:[43,49],blueBG:[44,49],magentaBG:[45,49],cyanBG:[46,49],whiteBG:[47,49]};Object.keys(cne).forEach(function(e){var t=cne[e],r=une[e]=[];r.open="\x1B["+t[0]+"m",r.close="\x1B["+t[1]+"m"})});var pne=E((dvt,dne)=>{"use strict";dne.exports=function(e,t){t=t||process.argv||[];var r=t.indexOf("--"),n=/^-{1,2}/.test(e)?"":"--",i=t.indexOf(n+e);return i!==-1&&(r===-1?!0:i<r)}});var mne=E((pvt,hne)=>{"use strict";var _Je=require("os"),So=pne(),ei=process.env,vd=void 0;So("no-color")||So("no-colors")||So("color=false")?vd=!1:(So("color")||So("colors")||So("color=true")||So("color=always"))&&(vd=!0);"FORCE_COLOR"in ei&&(vd=ei.FORCE_COLOR.length===0||parseInt(ei.FORCE_COLOR,10)!==0);function bJe(e){return e===0?!1:{level:e,hasBasic:!0,has256:e>=2,has16m:e>=3}}function EJe(e){if(vd===!1)return 0;if(So("color=16m")||So("color=full")||So("color=truecolor"))return 3;if(So("color=256"))return 2;if(e&&!e.isTTY&&vd!==!0)return 0;var t=vd?1:0;if(process.platform==="win32"){var r=_Je.release().split(".");return Number(process.versions.node.split(".")[0])>=8&&Number(r[0])>=10&&Number(r[2])>=10586?Number(r[2])>=14931?3:2:1}if("CI"in ei)return["TRAVIS","CIRCLECI","APPVEYOR","GITLAB_CI"].some(function(i){return i in ei})||ei.CI_NAME==="codeship"?1:t;if("TEAMCITY_VERSION"in ei)return/^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(ei.TEAMCITY_VERSION)?1:0;if("TERM_PROGRAM"in ei){var n=parseInt((ei.TERM_PROGRAM_VERSION||"").split(".")[0],10);switch(ei.TERM_PROGRAM){case"iTerm.app":return n>=3?3:2;case"Hyper":return 3;case"Apple_Terminal":return 2}}return/-256(color)?$/i.test(ei.TERM)?2:/^screen|^xterm|^vt100|^rxvt|color|ansi|cygwin|linux/i.test(ei.TERM)||"COLORTERM"in ei?1:(ei.TERM==="dumb",t)}function uN(e){var t=EJe(e);return bJe(t)}hne.exports={supportsColor:uN,stdout:uN(process.stdout),stderr:uN(process.stderr)}});var yne=E((hvt,gne)=>{"use strict";gne.exports=function(t,r){var n="";t=t||"Run the trap, drop the bass",t=t.split("");var i={a:["@","\u0104","\u023A","\u0245","\u0394","\u039B","\u0414"],b:["\xDF","\u0181","\u0243","\u026E","\u03B2","\u0E3F"],c:["\xA9","\u023B","\u03FE"],d:["\xD0","\u018A","\u0500","\u0501","\u0502","\u0503"],e:["\xCB","\u0115","\u018E","\u0258","\u03A3","\u03BE","\u04BC","\u0A6C"],f:["\u04FA"],g:["\u0262"],h:["\u0126","\u0195","\u04A2","\u04BA","\u04C7","\u050A"],i:["\u0F0F"],j:["\u0134"],k:["\u0138","\u04A0","\u04C3","\u051E"],l:["\u0139"],m:["\u028D","\u04CD","\u04CE","\u0520","\u0521","\u0D69"],n:["\xD1","\u014B","\u019D","\u0376","\u03A0","\u048A"],o:["\xD8","\xF5","\xF8","\u01FE","\u0298","\u047A","\u05DD","\u06DD","\u0E4F"],p:["\u01F7","\u048E"],q:["\u09CD"],r:["\xAE","\u01A6","\u0210","\u024C","\u0280","\u042F"],s:["\xA7","\u03DE","\u03DF","\u03E8"],t:["\u0141","\u0166","\u0373"],u:["\u01B1","\u054D"],v:["\u05D8"],w:["\u0428","\u0460","\u047C","\u0D70"],x:["\u04B2","\u04FE","\u04FC","\u04FD"],y:["\xA5","\u04B0","\u04CB"],z:["\u01B5","\u0240"]};return t.forEach(function(o){o=o.toLowerCase();var s=i[o]||[" "],a=Math.floor(Math.random()*s.length);typeof i[o]<"u"?n+=i[o][a]:n+=o}),n}});var bne=E((mvt,_ne)=>{"use strict";_ne.exports=function(t,r){t=t||" he is here ";var n={up:["\u030D","\u030E","\u0304","\u0305","\u033F","\u0311","\u0306","\u0310","\u0352","\u0357","\u0351","\u0307","\u0308","\u030A","\u0342","\u0313","\u0308","\u034A","\u034B","\u034C","\u0303","\u0302","\u030C","\u0350","\u0300","\u0301","\u030B","\u030F","\u0312","\u0313","\u0314","\u033D","\u0309","\u0363","\u0364","\u0365","\u0366","\u0367","\u0368","\u0369","\u036A","\u036B","\u036C","\u036D","\u036E","\u036F","\u033E","\u035B","\u0346","\u031A"],down:["\u0316","\u0317","\u0318","\u0319","\u031C","\u031D","\u031E","\u031F","\u0320","\u0324","\u0325","\u0326","\u0329","\u032A","\u032B","\u032C","\u032D","\u032E","\u032F","\u0330","\u0331","\u0332","\u0333","\u0339","\u033A","\u033B","\u033C","\u0345","\u0347","\u0348","\u0349","\u034D","\u034E","\u0353","\u0354","\u0355","\u0356","\u0359","\u035A","\u0323"],mid:["\u0315","\u031B","\u0300","\u0301","\u0358","\u0321","\u0322","\u0327","\u0328","\u0334","\u0335","\u0336","\u035C","\u035D","\u035E","\u035F","\u0360","\u0362","\u0338","\u0337","\u0361"," \u0489"]},i=[].concat(n.up,n.down,n.mid);function o(c){var u=Math.floor(Math.random()*c);return u}function s(c){var u=!1;return i.filter(function(l){u=l===c}),u}function a(c,u){var l="",d,h;u=u||{},u.up=typeof u.up<"u"?u.up:!0,u.mid=typeof u.mid<"u"?u.mid:!0,u.down=typeof u.down<"u"?u.down:!0,u.size=typeof u.size<"u"?u.size:"maxi",c=c.split("");for(h in c)if(!s(h)){switch(l=l+c[h],d={up:0,down:0,mid:0},u.size){case"mini":d.up=o(8),d.mid=o(2),d.down=o(8);break;case"maxi":d.up=o(16)+3,d.mid=o(4)+1,d.down=o(64)+3;break;default:d.up=o(8)+1,d.mid=o(6)/2,d.down=o(8)+1;break}var f=["up","mid","down"];for(var p in f)for(var m=f[p],_=0;_<=d[m];_++)u[m]&&(l=l+n[m][o(n[m].length)])}return l}return a(t,r)}});var wne=E((gvt,Ene)=>{"use strict";Ene.exports=function(e){return function(t,r,n){if(t===" ")return t;switch(r%3){case 0:return e.red(t);case 1:return e.white(t);case 2:return e.blue(t)}}}});var vne=E((yvt,Sne)=>{"use strict";Sne.exports=function(e){return function(t,r,n){return r%2===0?t:e.inverse(t)}}});var xne=E((_vt,Cne)=>{"use strict";Cne.exports=function(e){var t=["red","yellow","green","blue","magenta"];return function(r,n,i){return r===" "?r:e[t[n++%t.length]](r)}}});var Ane=E((bvt,Tne)=>{"use strict";Tne.exports=function(e){var t=["underline","inverse","grey","yellow","red","green","blue","white","cyan","magenta","brightYellow","brightRed","brightGreen","brightBlue","brightWhite","brightCyan","brightMagenta"];return function(r,n,i){return r===" "?r:e[t[Math.round(Math.random()*(t.length-2))]](r)}}});var kne=E((wvt,Dne)=>{"use strict";var st={};Dne.exports=st;st.themes={};var wJe=require("util"),$u=st.styles=fne(),Pne=Object.defineProperties,SJe=new RegExp(/[\r\n]+/g);st.supportsColor=mne().supportsColor;typeof st.enabled>"u"&&(st.enabled=st.supportsColor()!==!1);st.enable=function(){st.enabled=!0};st.disable=function(){st.enabled=!1};st.stripColors=st.strip=function(e){return(""+e).replace(/\x1B\[\d+m/g,"")};var Evt=st.stylize=function(t,r){if(!st.enabled)return t+"";var n=$u[r];return!n&&r in st?st[r](t):n.open+t+n.close},vJe=/[|\\{}()[\]^$+*?.]/g,CJe=function(e){if(typeof e!="string")throw new TypeError("Expected a string");return e.replace(vJe,"\\$&")};function One(e){var t=function r(){return TJe.apply(r,arguments)};return t._styles=e,t.__proto__=xJe,t}var Ine=(function(){var e={};return $u.grey=$u.gray,Object.keys($u).forEach(function(t){$u[t].closeRe=new RegExp(CJe($u[t].close),"g"),e[t]={get:function(){return One(this._styles.concat(t))}}}),e})(),xJe=Pne(function(){},Ine);function TJe(){var e=Array.prototype.slice.call(arguments),t=e.map(function(s){return s!=null&&s.constructor===String?s:wJe.inspect(s)}).join(" ");if(!st.enabled||!t)return t;for(var r=t.indexOf(`
|
|
245
|
+
`)!=-1,n=this._styles,i=n.length;i--;){var o=$u[n[i]];t=o.open+t.replace(o.closeRe,o.open)+o.close,r&&(t=t.replace(SJe,function(s){return o.close+s+o.open}))}return t}st.setTheme=function(e){if(typeof e=="string"){console.log("colors.setTheme now only accepts an object, not a string. If you are trying to set a theme from a file, it is now your (the caller's) responsibility to require the file. The old syntax looked like colors.setTheme(__dirname + '/../themes/generic-logging.js'); The new syntax looks like colors.setTheme(require(__dirname + '/../themes/generic-logging.js'));");return}for(var t in e)(function(r){st[r]=function(n){if(typeof e[r]=="object"){var i=n;for(var o in e[r])i=st[e[r][o]](i);return i}return st[e[r]](n)}})(t)};function AJe(){var e={};return Object.keys(Ine).forEach(function(t){e[t]={get:function(){return One([t])}}}),e}var RJe=function(t,r){var n=r.split("");return n=n.map(t),n.join("")};st.trap=yne();st.zalgo=bne();st.maps={};st.maps.america=wne()(st);st.maps.zebra=vne()(st);st.maps.rainbow=xne()(st);st.maps.random=Ane()(st);for(Rne in st.maps)(function(e){st[e]=function(t){return RJe(st.maps[e],t)}})(Rne);var Rne;Pne(st,AJe())});var lN=E((Svt,Nne)=>{"use strict";var PJe=kne();Nne.exports=PJe});var Mne=E(fN=>{"use strict";fN.levels={error:0,warn:1,help:2,data:3,info:4,debug:5,prompt:6,verbose:7,input:8,silly:9};fN.colors={error:"red",warn:"yellow",help:"cyan",data:"grey",info:"green",debug:"blue",prompt:"grey",verbose:"cyan",input:"grey",silly:"magenta"}});var Lne=E(dN=>{"use strict";dN.levels={error:0,warn:1,info:2,http:3,verbose:4,debug:5,silly:6};dN.colors={error:"red",warn:"yellow",info:"green",http:"green",verbose:"cyan",debug:"blue",silly:"magenta"}});var Bne=E(pN=>{"use strict";pN.levels={emerg:0,alert:1,crit:2,error:3,warning:4,notice:5,info:6,debug:7};pN.colors={emerg:"red",alert:"yellow",crit:"red",error:"red",warning:"red",notice:"yellow",info:"green",debug:"blue"}});var Fne=E(Jv=>{"use strict";Object.defineProperty(Jv,"cli",{value:Mne()});Object.defineProperty(Jv,"npm",{value:Lne()});Object.defineProperty(Jv,"syslog",{value:Bne()})});var Pr=E(ng=>{"use strict";Object.defineProperty(ng,"LEVEL",{value:Symbol.for("level")});Object.defineProperty(ng,"MESSAGE",{value:Symbol.for("message")});Object.defineProperty(ng,"SPLAT",{value:Symbol.for("splat")});Object.defineProperty(ng,"configs",{value:Fne()})});var eC=E((Rvt,Zv)=>{"use strict";var gN=lN(),{LEVEL:hN,MESSAGE:mN}=Pr();gN.enabled=!0;var qne=/\s+/,Qv=class e{constructor(t={}){t.colors&&this.addColors(t.colors),this.options=t}static addColors(t){let r=Object.keys(t).reduce((n,i)=>(n[i]=qne.test(t[i])?t[i].split(qne):t[i],n),{});return e.allColors=Object.assign({},e.allColors||{},r),e.allColors}addColors(t){return e.addColors(t)}colorize(t,r,n){if(typeof n>"u"&&(n=r),!Array.isArray(e.allColors[t]))return gN[e.allColors[t]](n);for(let i=0,o=e.allColors[t].length;i<o;i++)n=gN[e.allColors[t][i]](n);return n}transform(t,r){return r.all&&typeof t[mN]=="string"&&(t[mN]=this.colorize(t[hN],t.level,t[mN])),(r.level||r.all||!r.message)&&(t.level=this.colorize(t[hN],t.level)),(r.all||r.message)&&(t.message=this.colorize(t[hN],t.level,t.message)),t}};Zv.exports=e=>new Qv(e);Zv.exports.Colorizer=Zv.exports.Format=Qv});var Une=E((Pvt,jne)=>{"use strict";var{Colorizer:OJe}=eC();jne.exports=e=>(OJe.addColors(e.colors||e),e)});var $ne=E((Ovt,Hne)=>{"use strict";var IJe=hi();Hne.exports=IJe(e=>(e.message=` ${e.message}`,e))});var Vne=E((Ivt,zne)=>{"use strict";var DJe=hi(),{LEVEL:Gne,MESSAGE:yN}=Pr();zne.exports=DJe((e,{stack:t,cause:r})=>{if(e instanceof Error){let i=Object.assign({},e,{level:e.level,[Gne]:e[Gne]||e.level,message:e.message,[yN]:e[yN]||e.message});return t&&(i.stack=e.stack),r&&(i.cause=e.cause),i}if(!(e.message instanceof Error))return e;let n=e.message;return Object.assign(e,n),e.message=n.message,e[yN]=n.message,t&&(e.stack=n.stack),r&&(e.cause=n.cause),e})});var bN=E((Dvt,rC)=>{"use strict";var{configs:kJe,LEVEL:Wne,MESSAGE:_N}=Pr(),tC=class e{constructor(t={levels:kJe.npm.levels}){this.paddings=e.paddingForLevels(t.levels,t.filler),this.options=t}static getLongestLevel(t){let r=Object.keys(t).map(n=>n.length);return Math.max(...r)}static paddingForLevel(t,r,n){let i=n+1-t.length,o=Math.floor(i/r.length);return`${r}${r.repeat(o)}`.slice(0,i)}static paddingForLevels(t,r=" "){let n=e.getLongestLevel(t);return Object.keys(t).reduce((i,o)=>(i[o]=e.paddingForLevel(o,r,n),i),{})}transform(t,r){return t.message=`${this.paddings[t[Wne]]}${t.message}`,t[_N]&&(t[_N]=`${this.paddings[t[Wne]]}${t[_N]}`),t}};rC.exports=e=>new tC(e);rC.exports.Padder=rC.exports.Format=tC});var Kne=E((kvt,EN)=>{"use strict";var{Colorizer:NJe}=eC(),{Padder:MJe}=bN(),{configs:LJe,MESSAGE:BJe}=Pr(),nC=class{constructor(t={}){t.levels||(t.levels=LJe.cli.levels),this.colorizer=new NJe(t),this.padder=new MJe(t),this.options=t}transform(t,r){return this.colorizer.transform(this.padder.transform(t,r),r),t[BJe]=`${t.level}:${t.message}`,t}};EN.exports=e=>new nC(e);EN.exports.Format=nC});var Xne=E((Nvt,wN)=>{"use strict";var FJe=hi();function Yne(e){if(e.every(qJe))return t=>{let r=t;for(let n=0;n<e.length;n++)if(r=e[n].transform(r,e[n].options),!r)return!1;return r}}function qJe(e){if(typeof e.transform!="function")throw new Error(["No transform function found on format. Did you create a format instance?","const myFormat = format(formatFn);","const instance = myFormat();"].join(`
|
|
246
|
+
`));return!0}wN.exports=(...e)=>{let t=FJe(Yne(e)),r=t();return r.Format=t.Format,r};wN.exports.cascade=Yne});var og=E((xN,Zne)=>{"use strict";var{hasOwnProperty:ig}=Object.prototype,zu=CN();zu.configure=CN;zu.stringify=zu;zu.default=zu;xN.stringify=zu;xN.configure=CN;Zne.exports=zu;var jJe=/[\u0000-\u001f\u0022\u005c\ud800-\udfff]/;function gc(e){return e.length<5e3&&!jJe.test(e)?`"${e}"`:JSON.stringify(e)}function SN(e,t){if(e.length>200||t)return e.sort(t);for(let r=1;r<e.length;r++){let n=e[r],i=r;for(;i!==0&&e[i-1]>n;)e[i]=e[i-1],i--;e[i]=n}return e}var UJe=Object.getOwnPropertyDescriptor(Object.getPrototypeOf(Object.getPrototypeOf(new Int8Array)),Symbol.toStringTag).get;function vN(e){return UJe.call(e)!==void 0&&e.length!==0}function Jne(e,t,r){e.length<r&&(r=e.length);let n=t===","?"":" ",i=`"0":${n}${e[0]}`;for(let o=1;o<r;o++)i+=`${t}"${o}":${n}${e[o]}`;return i}function HJe(e){if(ig.call(e,"circularValue")){let t=e.circularValue;if(typeof t=="string")return`"${t}"`;if(t==null)return t;if(t===Error||t===TypeError)return{toString(){throw new TypeError("Converting circular structure to JSON")}};throw new TypeError('The "circularValue" argument must be of type string or the value null or undefined')}return'"[Circular]"'}function $Je(e){let t;if(ig.call(e,"deterministic")&&(t=e.deterministic,typeof t!="boolean"&&typeof t!="function"))throw new TypeError('The "deterministic" argument must be of type boolean or comparator function');return t===void 0?!0:t}function GJe(e,t){let r;if(ig.call(e,t)&&(r=e[t],typeof r!="boolean"))throw new TypeError(`The "${t}" argument must be of type boolean`);return r===void 0?!0:r}function Qne(e,t){let r;if(ig.call(e,t)){if(r=e[t],typeof r!="number")throw new TypeError(`The "${t}" argument must be of type number`);if(!Number.isInteger(r))throw new TypeError(`The "${t}" argument must be an integer`);if(r<1)throw new RangeError(`The "${t}" argument must be >= 1`)}return r===void 0?1/0:r}function Gu(e){return e===1?"1 item":`${e} items`}function zJe(e){let t=new Set;for(let r of e)(typeof r=="string"||typeof r=="number")&&t.add(String(r));return t}function VJe(e){if(ig.call(e,"strict")){let t=e.strict;if(typeof t!="boolean")throw new TypeError('The "strict" argument must be of type boolean');if(t)return r=>{let n=`Object can not safely be stringified. Received type ${typeof r}`;throw typeof r!="function"&&(n+=` (${r.toString()})`),new Error(n)}}}function CN(e){e={...e};let t=VJe(e);t&&(e.bigint===void 0&&(e.bigint=!1),"circularValue"in e||(e.circularValue=Error));let r=HJe(e),n=GJe(e,"bigint"),i=$Je(e),o=typeof i=="function"?i:void 0,s=Qne(e,"maximumDepth"),a=Qne(e,"maximumBreadth");function c(f,p,m,_,w,R){let v=p[f];switch(typeof v=="object"&&v!==null&&typeof v.toJSON=="function"&&(v=v.toJSON(f)),v=_.call(p,f,v),typeof v){case"string":return gc(v);case"object":{if(v===null)return"null";if(m.indexOf(v)!==-1)return r;let y="",S=",",O=R;if(Array.isArray(v)){if(v.length===0)return"[]";if(s<m.length+1)return'"[Array]"';m.push(v),w!==""&&(R+=w,y+=`
|
|
247
|
+
${R}`,S=`,
|
|
248
|
+
${R}`);let J=Math.min(v.length,a),U=0;for(;U<J-1;U++){let be=c(String(U),v,m,_,w,R);y+=be!==void 0?be:"null",y+=S}let ie=c(String(U),v,m,_,w,R);if(y+=ie!==void 0?ie:"null",v.length-1>a){let be=v.length-a-1;y+=`${S}"... ${Gu(be)} not stringified"`}return w!==""&&(y+=`
|
|
249
|
+
${O}`),m.pop(),`[${y}]`}let M=Object.keys(v),A=M.length;if(A===0)return"{}";if(s<m.length+1)return'"[Object]"';let D="",I="";w!==""&&(R+=w,S=`,
|
|
250
|
+
${R}`,D=" ");let N=Math.min(A,a);i&&!vN(v)&&(M=SN(M,o)),m.push(v);for(let J=0;J<N;J++){let U=M[J],ie=c(U,v,m,_,w,R);ie!==void 0&&(y+=`${I}${gc(U)}:${D}${ie}`,I=S)}if(A>a){let J=A-a;y+=`${I}"...":${D}"${Gu(J)} not stringified"`,I=S}return w!==""&&I.length>1&&(y=`
|
|
251
|
+
${R}${y}
|
|
252
|
+
${O}`),m.pop(),`{${y}}`}case"number":return isFinite(v)?String(v):t?t(v):"null";case"boolean":return v===!0?"true":"false";case"undefined":return;case"bigint":if(n)return String(v);default:return t?t(v):void 0}}function u(f,p,m,_,w,R){switch(typeof p=="object"&&p!==null&&typeof p.toJSON=="function"&&(p=p.toJSON(f)),typeof p){case"string":return gc(p);case"object":{if(p===null)return"null";if(m.indexOf(p)!==-1)return r;let v=R,y="",S=",";if(Array.isArray(p)){if(p.length===0)return"[]";if(s<m.length+1)return'"[Array]"';m.push(p),w!==""&&(R+=w,y+=`
|
|
253
|
+
${R}`,S=`,
|
|
254
|
+
${R}`);let A=Math.min(p.length,a),D=0;for(;D<A-1;D++){let N=u(String(D),p[D],m,_,w,R);y+=N!==void 0?N:"null",y+=S}let I=u(String(D),p[D],m,_,w,R);if(y+=I!==void 0?I:"null",p.length-1>a){let N=p.length-a-1;y+=`${S}"... ${Gu(N)} not stringified"`}return w!==""&&(y+=`
|
|
255
|
+
${v}`),m.pop(),`[${y}]`}m.push(p);let O="";w!==""&&(R+=w,S=`,
|
|
256
|
+
${R}`,O=" ");let M="";for(let A of _){let D=u(A,p[A],m,_,w,R);D!==void 0&&(y+=`${M}${gc(A)}:${O}${D}`,M=S)}return w!==""&&M.length>1&&(y=`
|
|
257
|
+
${R}${y}
|
|
258
|
+
${v}`),m.pop(),`{${y}}`}case"number":return isFinite(p)?String(p):t?t(p):"null";case"boolean":return p===!0?"true":"false";case"undefined":return;case"bigint":if(n)return String(p);default:return t?t(p):void 0}}function l(f,p,m,_,w){switch(typeof p){case"string":return gc(p);case"object":{if(p===null)return"null";if(typeof p.toJSON=="function"){if(p=p.toJSON(f),typeof p!="object")return l(f,p,m,_,w);if(p===null)return"null"}if(m.indexOf(p)!==-1)return r;let R=w;if(Array.isArray(p)){if(p.length===0)return"[]";if(s<m.length+1)return'"[Array]"';m.push(p),w+=_;let D=`
|
|
259
|
+
${w}`,I=`,
|
|
260
|
+
${w}`,N=Math.min(p.length,a),J=0;for(;J<N-1;J++){let ie=l(String(J),p[J],m,_,w);D+=ie!==void 0?ie:"null",D+=I}let U=l(String(J),p[J],m,_,w);if(D+=U!==void 0?U:"null",p.length-1>a){let ie=p.length-a-1;D+=`${I}"... ${Gu(ie)} not stringified"`}return D+=`
|
|
261
|
+
${R}`,m.pop(),`[${D}]`}let v=Object.keys(p),y=v.length;if(y===0)return"{}";if(s<m.length+1)return'"[Object]"';w+=_;let S=`,
|
|
262
|
+
${w}`,O="",M="",A=Math.min(y,a);vN(p)&&(O+=Jne(p,S,a),v=v.slice(p.length),A-=p.length,M=S),i&&(v=SN(v,o)),m.push(p);for(let D=0;D<A;D++){let I=v[D],N=l(I,p[I],m,_,w);N!==void 0&&(O+=`${M}${gc(I)}: ${N}`,M=S)}if(y>a){let D=y-a;O+=`${M}"...": "${Gu(D)} not stringified"`,M=S}return M!==""&&(O=`
|
|
263
|
+
${w}${O}
|
|
264
|
+
${R}`),m.pop(),`{${O}}`}case"number":return isFinite(p)?String(p):t?t(p):"null";case"boolean":return p===!0?"true":"false";case"undefined":return;case"bigint":if(n)return String(p);default:return t?t(p):void 0}}function d(f,p,m){switch(typeof p){case"string":return gc(p);case"object":{if(p===null)return"null";if(typeof p.toJSON=="function"){if(p=p.toJSON(f),typeof p!="object")return d(f,p,m);if(p===null)return"null"}if(m.indexOf(p)!==-1)return r;let _="",w=p.length!==void 0;if(w&&Array.isArray(p)){if(p.length===0)return"[]";if(s<m.length+1)return'"[Array]"';m.push(p);let O=Math.min(p.length,a),M=0;for(;M<O-1;M++){let D=d(String(M),p[M],m);_+=D!==void 0?D:"null",_+=","}let A=d(String(M),p[M],m);if(_+=A!==void 0?A:"null",p.length-1>a){let D=p.length-a-1;_+=`,"... ${Gu(D)} not stringified"`}return m.pop(),`[${_}]`}let R=Object.keys(p),v=R.length;if(v===0)return"{}";if(s<m.length+1)return'"[Object]"';let y="",S=Math.min(v,a);w&&vN(p)&&(_+=Jne(p,",",a),R=R.slice(p.length),S-=p.length,y=","),i&&(R=SN(R,o)),m.push(p);for(let O=0;O<S;O++){let M=R[O],A=d(M,p[M],m);A!==void 0&&(_+=`${y}${gc(M)}:${A}`,y=",")}if(v>a){let O=v-a;_+=`${y}"...":"${Gu(O)} not stringified"`}return m.pop(),`{${_}}`}case"number":return isFinite(p)?String(p):t?t(p):"null";case"boolean":return p===!0?"true":"false";case"undefined":return;case"bigint":if(n)return String(p);default:return t?t(p):void 0}}function h(f,p,m){if(arguments.length>1){let _="";if(typeof m=="number"?_=" ".repeat(Math.min(m,10)):typeof m=="string"&&(_=m.slice(0,10)),p!=null){if(typeof p=="function")return c("",{"":f},[],p,_,"");if(Array.isArray(p))return u("",f,[],zJe(p),_,"")}if(_.length!==0)return l("",f,[],_,"")}return d("",f,[])}return h}});var TN=E((Mvt,eie)=>{"use strict";var WJe=hi(),{MESSAGE:KJe}=Pr(),YJe=og();function XJe(e,t){return typeof t=="bigint"?t.toString():t}eie.exports=WJe((e,t)=>{let r=YJe.configure(t);return e[KJe]=r(e,t.replacer||XJe,t.space),e})});var rie=E((Lvt,tie)=>{"use strict";var JJe=hi();tie.exports=JJe((e,t)=>t.message?(e.message=`[${t.label}] ${e.message}`,e):(e.label=t.label,e))});var iie=E((Bvt,nie)=>{"use strict";var QJe=hi(),{MESSAGE:ZJe}=Pr(),eQe=og();nie.exports=QJe(e=>{let t={};return e.message&&(t["@message"]=e.message,delete e.message),e.timestamp&&(t["@timestamp"]=e.timestamp,delete e.timestamp),t["@fields"]=e,e[ZJe]=eQe(t),e})});var sie=E((Fvt,oie)=>{"use strict";var tQe=hi();function rQe(e,t,r){let n=t.reduce((o,s)=>(o[s]=e[s],delete e[s],o),{}),i=Object.keys(e).reduce((o,s)=>(o[s]=e[s],delete e[s],o),{});return Object.assign(e,n,{[r]:i}),e}function nQe(e,t,r){return e[r]=t.reduce((n,i)=>(n[i]=e[i],delete e[i],n),{}),e}oie.exports=tQe((e,t={})=>{let r="metadata";t.key&&(r=t.key);let n=[];return!t.fillExcept&&!t.fillWith&&(n.push("level"),n.push("message")),t.fillExcept&&(n=t.fillExcept),n.length>0?rQe(e,n,r):t.fillWith?nQe(e,t.fillWith,r):e})});var cie=E((qvt,aie)=>{"use strict";var Cd=1e3,xd=Cd*60,Td=xd*60,Vu=Td*24,iQe=Vu*7,oQe=Vu*365.25;aie.exports=function(e,t){t=t||{};var r=typeof e;if(r==="string"&&e.length>0)return sQe(e);if(r==="number"&&isFinite(e))return t.long?cQe(e):aQe(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))};function sQe(e){if(e=String(e),!(e.length>100)){var t=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(e);if(t){var r=parseFloat(t[1]),n=(t[2]||"ms").toLowerCase();switch(n){case"years":case"year":case"yrs":case"yr":case"y":return r*oQe;case"weeks":case"week":case"w":return r*iQe;case"days":case"day":case"d":return r*Vu;case"hours":case"hour":case"hrs":case"hr":case"h":return r*Td;case"minutes":case"minute":case"mins":case"min":case"m":return r*xd;case"seconds":case"second":case"secs":case"sec":case"s":return r*Cd;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return r;default:return}}}}function aQe(e){var t=Math.abs(e);return t>=Vu?Math.round(e/Vu)+"d":t>=Td?Math.round(e/Td)+"h":t>=xd?Math.round(e/xd)+"m":t>=Cd?Math.round(e/Cd)+"s":e+"ms"}function cQe(e){var t=Math.abs(e);return t>=Vu?iC(e,t,Vu,"day"):t>=Td?iC(e,t,Td,"hour"):t>=xd?iC(e,t,xd,"minute"):t>=Cd?iC(e,t,Cd,"second"):e+" ms"}function iC(e,t,r,n){var i=t>=r*1.5;return Math.round(e/r)+" "+n+(i?"s":"")}});var lie=E((sg,uie)=>{"use strict";var uQe=hi(),lQe=cie();uie.exports=uQe(e=>{let t=+new Date;return sg.diff=t-(sg.prevTime||t),sg.prevTime=t,e.ms=`+${lQe(sg.diff)}`,e})});var pie=E((jvt,die)=>{"use strict";var fQe=require("util").inspect,dQe=hi(),{LEVEL:pQe,MESSAGE:fie,SPLAT:hQe}=Pr();die.exports=dQe((e,t={})=>{let r=Object.assign({},e);return delete r[pQe],delete r[fie],delete r[hQe],e[fie]=fQe(r,!1,t.depth||null,t.colorize),e})});var hie=E((Uvt,sC)=>{"use strict";var{MESSAGE:mQe}=Pr(),oC=class{constructor(t){this.template=t}transform(t){return t[mQe]=this.template(t),t}};sC.exports=e=>new oC(e);sC.exports.Printf=sC.exports.Format=oC});var yie=E((Hvt,gie)=>{"use strict";var gQe=hi(),{MESSAGE:mie}=Pr(),yQe=og();gie.exports=gQe(e=>{let t=yQe(Object.assign({},e,{level:void 0,message:void 0,splat:void 0})),r=e.padding&&e.padding[e.level]||"";return t!=="{}"?e[mie]=`${e.level}:${r} ${e.message} ${t}`:e[mie]=`${e.level}:${r} ${e.message}`,e})});var Eie=E(($vt,bie)=>{"use strict";var _Qe=require("util"),{SPLAT:_ie}=Pr(),bQe=/%[scdjifoO%]/g,EQe=/%%/g,AN=class{constructor(t){this.options=t}_splat(t,r){let n=t.message,i=t[_ie]||t.splat||[],o=n.match(EQe),s=o&&o.length||0,c=r.length-s-i.length,u=c<0?i.splice(c,-1*c):[],l=u.length;if(l)for(let d=0;d<l;d++)Object.assign(t,u[d]);return t.message=_Qe.format(n,...i),t}transform(t){let r=t.message,n=t[_ie]||t.splat;if(!n||!n.length)return t;let i=r&&r.match&&r.match(bQe);if(!i&&(n||n.length)){let o=n.length>1?n.splice(0):n,s=o.length;if(s)for(let a=0;a<s;a++)Object.assign(t,o[a]);return t}return i?this._splat(t,i):t}};bie.exports=e=>new AN(e)});var Sie=E((aC,wie)=>{"use strict";(function(e,t){typeof aC=="object"&&typeof wie<"u"?t(aC):typeof define=="function"&&define.amd?define(["exports"],t):t(e.fecha={})})(aC,(function(e){"use strict";var t=/d{1,4}|M{1,4}|YY(?:YY)?|S{1,3}|Do|ZZ|Z|([HhMsDm])\1?|[aA]|"[^"]*"|'[^']*'/g,r="\\d\\d?",n="\\d\\d",i="\\d{3}",o="\\d{4}",s="[^\\s]+",a=/\[([^]*?)\]/gm;function c(B,te){for(var ge=[],$=0,ve=B.length;$<ve;$++)ge.push(B[$].substr(0,te));return ge}var u=function(B){return function(te,ge){var $=ge[B].map(function(Ze){return Ze.toLowerCase()}),ve=$.indexOf(te.toLowerCase());return ve>-1?ve:null}};function l(B){for(var te=[],ge=1;ge<arguments.length;ge++)te[ge-1]=arguments[ge];for(var $=0,ve=te;$<ve.length;$++){var Ze=ve[$];for(var at in Ze)B[at]=Ze[at]}return B}var d=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],h=["January","February","March","April","May","June","July","August","September","October","November","December"],f=c(h,3),p=c(d,3),m={dayNamesShort:p,dayNames:d,monthNamesShort:f,monthNames:h,amPm:["am","pm"],DoFn:function(B){return B+["th","st","nd","rd"][B%10>3?0:(B-B%10!==10?1:0)*B%10]}},_=l({},m),w=function(B){return _=l(_,B)},R=function(B){return B.replace(/[|\\{()[^$+*?.-]/g,"\\$&")},v=function(B,te){for(te===void 0&&(te=2),B=String(B);B.length<te;)B="0"+B;return B},y={D:function(B){return String(B.getDate())},DD:function(B){return v(B.getDate())},Do:function(B,te){return te.DoFn(B.getDate())},d:function(B){return String(B.getDay())},dd:function(B){return v(B.getDay())},ddd:function(B,te){return te.dayNamesShort[B.getDay()]},dddd:function(B,te){return te.dayNames[B.getDay()]},M:function(B){return String(B.getMonth()+1)},MM:function(B){return v(B.getMonth()+1)},MMM:function(B,te){return te.monthNamesShort[B.getMonth()]},MMMM:function(B,te){return te.monthNames[B.getMonth()]},YY:function(B){return v(String(B.getFullYear()),4).substr(2)},YYYY:function(B){return v(B.getFullYear(),4)},h:function(B){return String(B.getHours()%12||12)},hh:function(B){return v(B.getHours()%12||12)},H:function(B){return String(B.getHours())},HH:function(B){return v(B.getHours())},m:function(B){return String(B.getMinutes())},mm:function(B){return v(B.getMinutes())},s:function(B){return String(B.getSeconds())},ss:function(B){return v(B.getSeconds())},S:function(B){return String(Math.round(B.getMilliseconds()/100))},SS:function(B){return v(Math.round(B.getMilliseconds()/10),2)},SSS:function(B){return v(B.getMilliseconds(),3)},a:function(B,te){return B.getHours()<12?te.amPm[0]:te.amPm[1]},A:function(B,te){return B.getHours()<12?te.amPm[0].toUpperCase():te.amPm[1].toUpperCase()},ZZ:function(B){var te=B.getTimezoneOffset();return(te>0?"-":"+")+v(Math.floor(Math.abs(te)/60)*100+Math.abs(te)%60,4)},Z:function(B){var te=B.getTimezoneOffset();return(te>0?"-":"+")+v(Math.floor(Math.abs(te)/60),2)+":"+v(Math.abs(te)%60,2)}},S=function(B){return+B-1},O=[null,r],M=[null,s],A=["isPm",s,function(B,te){var ge=B.toLowerCase();return ge===te.amPm[0]?0:ge===te.amPm[1]?1:null}],D=["timezoneOffset","[^\\s]*?[\\+\\-]\\d\\d:?\\d\\d|[^\\s]*?Z?",function(B){var te=(B+"").match(/([+-]|\d\d)/gi);if(te){var ge=+te[1]*60+parseInt(te[2],10);return te[0]==="+"?ge:-ge}return 0}],I={D:["day",r],DD:["day",n],Do:["day",r+s,function(B){return parseInt(B,10)}],M:["month",r,S],MM:["month",n,S],YY:["year",n,function(B){var te=new Date,ge=+(""+te.getFullYear()).substr(0,2);return+(""+(+B>68?ge-1:ge)+B)}],h:["hour",r,void 0,"isPm"],hh:["hour",n,void 0,"isPm"],H:["hour",r],HH:["hour",n],m:["minute",r],mm:["minute",n],s:["second",r],ss:["second",n],YYYY:["year",o],S:["millisecond","\\d",function(B){return+B*100}],SS:["millisecond",n,function(B){return+B*10}],SSS:["millisecond",i],d:O,dd:O,ddd:M,dddd:M,MMM:["month",s,u("monthNamesShort")],MMMM:["month",s,u("monthNames")],a:A,A,ZZ:D,Z:D},N={default:"ddd MMM DD YYYY HH:mm:ss",shortDate:"M/D/YY",mediumDate:"MMM D, YYYY",longDate:"MMMM D, YYYY",fullDate:"dddd, MMMM D, YYYY",isoDate:"YYYY-MM-DD",isoDateTime:"YYYY-MM-DDTHH:mm:ssZ",shortTime:"HH:mm",mediumTime:"HH:mm:ss",longTime:"HH:mm:ss.SSS"},J=function(B){return l(N,B)},U=function(B,te,ge){if(te===void 0&&(te=N.default),ge===void 0&&(ge={}),typeof B=="number"&&(B=new Date(B)),Object.prototype.toString.call(B)!=="[object Date]"||isNaN(B.getTime()))throw new Error("Invalid Date pass to format");te=N[te]||te;var $=[];te=te.replace(a,function(Ze,at){return $.push(at),"@@@"});var ve=l(l({},_),ge);return te=te.replace(t,function(Ze){return y[Ze](B,ve)}),te.replace(/@@@/g,function(){return $.shift()})};function ie(B,te,ge){if(ge===void 0&&(ge={}),typeof te!="string")throw new Error("Invalid format in fecha parse");if(te=N[te]||te,B.length>1e3)return null;var $=new Date,ve={year:$.getFullYear(),month:0,day:1,hour:0,minute:0,second:0,millisecond:0,isPm:null,timezoneOffset:null},Ze=[],at=[],G=te.replace(a,function(Tt,gr){return at.push(R(gr)),"@@@"}),ce={},Se={};G=R(G).replace(t,function(Tt){var gr=I[Tt],Qi=gr[0],ta=gr[1],Pi=gr[3];if(ce[Qi])throw new Error("Invalid format. "+Qi+" specified twice in format");return ce[Qi]=!0,Pi&&(Se[Pi]=!0),Ze.push(gr),"("+ta+")"}),Object.keys(Se).forEach(function(Tt){if(!ce[Tt])throw new Error("Invalid format. "+Tt+" is required in specified format")}),G=G.replace(/@@@/g,function(){return at.shift()});var P=B.match(new RegExp(G,"i"));if(!P)return null;for(var T=l(l({},_),ge),K=1;K<P.length;K++){var j=Ze[K-1],Be=j[0],yt=j[2],ft=yt?yt(P[K],T):+P[K];if(ft==null)return null;ve[Be]=ft}ve.isPm===1&&ve.hour!=null&&+ve.hour!=12?ve.hour=+ve.hour+12:ve.isPm===0&&+ve.hour==12&&(ve.hour=0);var wt;if(ve.timezoneOffset==null){wt=new Date(ve.year,ve.month,ve.day,ve.hour,ve.minute,ve.second,ve.millisecond);for(var Dt=[["month","getMonth"],["day","getDate"],["hour","getHours"],["minute","getMinutes"],["second","getSeconds"]],K=0,Ur=Dt.length;K<Ur;K++)if(ce[Dt[K][0]]&&ve[Dt[K][0]]!==wt[Dt[K][1]]())return null}else if(wt=new Date(Date.UTC(ve.year,ve.month,ve.day,ve.hour,ve.minute-ve.timezoneOffset,ve.second,ve.millisecond)),ve.month>11||ve.month<0||ve.day>31||ve.day<1||ve.hour>23||ve.hour<0||ve.minute>59||ve.minute<0||ve.second>59||ve.second<0)return null;return wt}var be={format:U,parse:ie,defaultI18n:m,setGlobalDateI18n:w,setGlobalDateMasks:J};e.assign=l,e.default=be,e.format=U,e.parse=ie,e.defaultI18n=m,e.setGlobalDateI18n=w,e.setGlobalDateMasks=J,Object.defineProperty(e,"__esModule",{value:!0})}))});var Cie=E((Gvt,vie)=>{"use strict";var wQe=Sie(),SQe=hi();vie.exports=SQe((e,t={})=>(t.format&&(e.timestamp=typeof t.format=="function"?t.format():wQe.format(new Date,t.format)),e.timestamp||(e.timestamp=new Date().toISOString()),t.alias&&(e[t.alias]=e.timestamp),e))});var Tie=E((zvt,xie)=>{"use strict";var RN=lN(),vQe=hi(),{MESSAGE:PN}=Pr();xie.exports=vQe((e,t)=>(t.level!==!1&&(e.level=RN.strip(e.level)),t.message!==!1&&(e.message=RN.strip(String(e.message))),t.raw!==!1&&e[PN]&&(e[PN]=RN.strip(String(e[PN]))),e))});var IN=E(ON=>{"use strict";var CQe=ON.format=hi();ON.levels=Une();function pn(e,t){Object.defineProperty(CQe,e,{get(){return t()},configurable:!0})}pn("align",function(){return $ne()});pn("errors",function(){return Vne()});pn("cli",function(){return Kne()});pn("combine",function(){return Xne()});pn("colorize",function(){return eC()});pn("json",function(){return TN()});pn("label",function(){return rie()});pn("logstash",function(){return iie()});pn("metadata",function(){return sie()});pn("ms",function(){return lie()});pn("padLevels",function(){return bN()});pn("prettyPrint",function(){return pie()});pn("printf",function(){return hie()});pn("simple",function(){return yie()});pn("splat",function(){return Eie()});pn("timestamp",function(){return Cie()});pn("uncolorize",function(){return Tie()})});var DN=E(cC=>{"use strict";var{format:Aie}=require("util");cC.warn={deprecated(e){return()=>{throw new Error(Aie("{ %s } was removed in winston@3.0.0.",e))}},useFormat(e){return()=>{throw new Error([Aie("{ %s } was removed in winston@3.0.0.",e),"Use a custom winston.format = winston.format(function) instead."].join(`
|
|
265
|
+
`))}},forFunctions(e,t,r){r.forEach(n=>{e[n]=cC.warn[t](n)})},forProperties(e,t,r){r.forEach(n=>{let i=cC.warn[t](n);Object.defineProperty(e,n,{get:i,set:i})})}}});var Rie=E((Kvt,xQe)=>{xQe.exports={name:"winston",description:"A logger for just about everything.",version:"3.18.3",author:"Charlie Robbins <charlie.robbins@gmail.com>",maintainers:["David Hyde <dabh@alumni.stanford.edu>"],repository:{type:"git",url:"https://github.com/winstonjs/winston.git"},keywords:["winston","logger","logging","logs","sysadmin","bunyan","pino","loglevel","tools","json","stream"],dependencies:{"@dabh/diagnostics":"^2.0.8","@colors/colors":"^1.6.0",async:"^3.2.3","is-stream":"^2.0.0",logform:"^2.7.0","one-time":"^1.0.0","readable-stream":"^3.4.0","safe-stable-stringify":"^2.3.1","stack-trace":"0.0.x","triple-beam":"^1.3.0","winston-transport":"^4.9.0"},devDependencies:{"@babel/cli":"^7.23.9","@babel/core":"^7.24.0","@babel/preset-env":"^7.24.0","@dabh/eslint-config-populist":"^4.4.0","@types/node":"^20.11.24","abstract-winston-transport":"^0.5.1",assume:"^2.2.0","cross-spawn-async":"^2.2.5",eslint:"^8.57.0",hock:"^1.4.1",mocha:"^10.3.0",nyc:"^17.1.0",rimraf:"5.0.1",split2:"^4.1.0","std-mocks":"^2.0.0",through2:"^4.0.2","winston-compat":"^0.1.5"},main:"./lib/winston.js",browser:"./dist/winston",types:"./index.d.ts",scripts:{lint:"eslint lib/*.js lib/winston/*.js lib/winston/**/*.js --resolve-plugins-relative-to ./node_modules/@dabh/eslint-config-populist",test:"rimraf test/fixtures/logs/* && mocha","test:coverage":"nyc npm run test:unit","test:unit":"mocha test/unit","test:integration":"mocha test/integration",build:"rimraf dist && babel lib -d dist",prepublishOnly:"npm run build"},engines:{node:">= 12.0.0"},license:"MIT"}});var kN=E((Yvt,Pie)=>{"use strict";Pie.exports=require("stream")});var MN=E((Xvt,Iie)=>{"use strict";function TQe(e,t){var r=this,n=this._readableState&&this._readableState.destroyed,i=this._writableState&&this._writableState.destroyed;return n||i?(t?t(e):e&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,process.nextTick(NN,this,e)):process.nextTick(NN,this,e)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,function(o){!t&&o?r._writableState?r._writableState.errorEmitted?process.nextTick(uC,r):(r._writableState.errorEmitted=!0,process.nextTick(Oie,r,o)):process.nextTick(Oie,r,o):t?(process.nextTick(uC,r),t(o)):process.nextTick(uC,r)}),this)}function Oie(e,t){NN(e,t),uC(e)}function uC(e){e._writableState&&!e._writableState.emitClose||e._readableState&&!e._readableState.emitClose||e.emit("close")}function AQe(){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 NN(e,t){e.emit("error",t)}function RQe(e,t){var r=e._readableState,n=e._writableState;r&&r.autoDestroy||n&&n.autoDestroy?e.destroy(t):e.emit("error",t)}Iie.exports={destroy:TQe,undestroy:AQe,errorOrDestroy:RQe}});var Ad=E((Jvt,Nie)=>{"use strict";var kie={};function Yi(e,t,r){r||(r=Error);function n(o,s,a){return typeof t=="string"?t:t(o,s,a)}class i extends r{constructor(s,a,c){super(n(s,a,c))}}i.prototype.name=r.name,i.prototype.code=e,kie[e]=i}function Die(e,t){if(Array.isArray(e)){let r=e.length;return e=e.map(n=>String(n)),r>2?`one of ${t} ${e.slice(0,r-1).join(", ")}, or `+e[r-1]:r===2?`one of ${t} ${e[0]} or ${e[1]}`:`of ${t} ${e[0]}`}else return`of ${t} ${String(e)}`}function PQe(e,t,r){return e.substr(!r||r<0?0:+r,t.length)===t}function OQe(e,t,r){return(r===void 0||r>e.length)&&(r=e.length),e.substring(r-t.length,r)===t}function IQe(e,t,r){return typeof r!="number"&&(r=0),r+t.length>e.length?!1:e.indexOf(t,r)!==-1}Yi("ERR_INVALID_OPT_VALUE",function(e,t){return'The value "'+t+'" is invalid for option "'+e+'"'},TypeError);Yi("ERR_INVALID_ARG_TYPE",function(e,t,r){let n;typeof t=="string"&&PQe(t,"not ")?(n="must not be",t=t.replace(/^not /,"")):n="must be";let i;if(OQe(e," argument"))i=`The ${e} ${n} ${Die(t,"type")}`;else{let o=IQe(e,".")?"property":"argument";i=`The "${e}" ${o} ${n} ${Die(t,"type")}`}return i+=`. Received type ${typeof r}`,i},TypeError);Yi("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF");Yi("ERR_METHOD_NOT_IMPLEMENTED",function(e){return"The "+e+" method is not implemented"});Yi("ERR_STREAM_PREMATURE_CLOSE","Premature close");Yi("ERR_STREAM_DESTROYED",function(e){return"Cannot call "+e+" after a stream was destroyed"});Yi("ERR_MULTIPLE_CALLBACK","Callback called multiple times");Yi("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable");Yi("ERR_STREAM_WRITE_AFTER_END","write after end");Yi("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError);Yi("ERR_UNKNOWN_ENCODING",function(e){return"Unknown encoding: "+e},TypeError);Yi("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event");Nie.exports.codes=kie});var LN=E((Qvt,Mie)=>{"use strict";var DQe=Ad().codes.ERR_INVALID_OPT_VALUE;function kQe(e,t,r){return e.highWaterMark!=null?e.highWaterMark:t?e[r]:null}function NQe(e,t,r,n){var i=kQe(t,n,r);if(i!=null){if(!(isFinite(i)&&Math.floor(i)===i)||i<0){var o=n?r:"highWaterMark";throw new DQe(o,i)}return Math.floor(i)}return e.objectMode?16:16*1024}Mie.exports={getHighWaterMark:NQe}});var Uie=E((Zvt,jie)=>{"use strict";function Lie(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Bie(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Lie(Object(r),!0).forEach(function(n){MQe(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Lie(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function MQe(e,t,r){return t=qie(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function LQe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Fie(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,qie(n.key),n)}}function BQe(e,t,r){return t&&Fie(e.prototype,t),r&&Fie(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}function qie(e){var t=FQe(e,"string");return typeof t=="symbol"?t:String(t)}function FQe(e,t){if(typeof e!="object"||e===null)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var qQe=require("buffer"),lC=qQe.Buffer,jQe=require("util"),BN=jQe.inspect,UQe=BN&&BN.custom||"inspect";function HQe(e,t,r){lC.prototype.copy.call(e,t,r)}jie.exports=(function(){function e(){LQe(this,e),this.head=null,this.tail=null,this.length=0}return BQe(e,[{key:"push",value:function(r){var n={data:r,next:null};this.length>0?this.tail.next=n:this.head=n,this.tail=n,++this.length}},{key:"unshift",value:function(r){var n={data:r,next:this.head};this.length===0&&(this.tail=n),this.head=n,++this.length}},{key:"shift",value:function(){if(this.length!==0){var r=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,r}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(r){if(this.length===0)return"";for(var n=this.head,i=""+n.data;n=n.next;)i+=r+n.data;return i}},{key:"concat",value:function(r){if(this.length===0)return lC.alloc(0);for(var n=lC.allocUnsafe(r>>>0),i=this.head,o=0;i;)HQe(i.data,n,o),o+=i.data.length,i=i.next;return n}},{key:"consume",value:function(r,n){var i;return r<this.head.data.length?(i=this.head.data.slice(0,r),this.head.data=this.head.data.slice(r)):r===this.head.data.length?i=this.shift():i=n?this._getString(r):this._getBuffer(r),i}},{key:"first",value:function(){return this.head.data}},{key:"_getString",value:function(r){var n=this.head,i=1,o=n.data;for(r-=o.length;n=n.next;){var s=n.data,a=r>s.length?s.length:r;if(a===s.length?o+=s:o+=s.slice(0,r),r-=a,r===0){a===s.length?(++i,n.next?this.head=n.next:this.head=this.tail=null):(this.head=n,n.data=s.slice(a));break}++i}return this.length-=i,o}},{key:"_getBuffer",value:function(r){var n=lC.allocUnsafe(r),i=this.head,o=1;for(i.data.copy(n),r-=i.data.length;i=i.next;){var s=i.data,a=r>s.length?s.length:r;if(s.copy(n,n.length-r,0,a),r-=a,r===0){a===s.length?(++o,i.next?this.head=i.next:this.head=this.tail=null):(this.head=i,i.data=s.slice(a));break}++o}return this.length-=o,n}},{key:UQe,value:function(r,n){return BN(this,Bie(Bie({},n),{},{depth:0,customInspect:!1}))}}]),e})()});var zie=E((eCt,Gie)=>{"use strict";var Hie=Ad().codes.ERR_STREAM_PREMATURE_CLOSE;function $Qe(e){var t=!1;return function(){if(!t){t=!0;for(var r=arguments.length,n=new Array(r),i=0;i<r;i++)n[i]=arguments[i];e.apply(this,n)}}}function GQe(){}function zQe(e){return e.setHeader&&typeof e.abort=="function"}function $ie(e,t,r){if(typeof t=="function")return $ie(e,null,t);t||(t={}),r=$Qe(r||GQe);var n=t.readable||t.readable!==!1&&e.readable,i=t.writable||t.writable!==!1&&e.writable,o=function(){e.writable||a()},s=e._writableState&&e._writableState.finished,a=function(){i=!1,s=!0,n||r.call(e)},c=e._readableState&&e._readableState.endEmitted,u=function(){n=!1,c=!0,i||r.call(e)},l=function(p){r.call(e,p)},d=function(){var p;if(n&&!c)return(!e._readableState||!e._readableState.ended)&&(p=new Hie),r.call(e,p);if(i&&!s)return(!e._writableState||!e._writableState.ended)&&(p=new Hie),r.call(e,p)},h=function(){e.req.on("finish",a)};return zQe(e)?(e.on("complete",a),e.on("abort",d),e.req?h():e.on("request",h)):i&&!e._writableState&&(e.on("end",o),e.on("close",o)),e.on("end",u),e.on("finish",a),t.error!==!1&&e.on("error",l),e.on("close",d),function(){e.removeListener("complete",a),e.removeListener("abort",d),e.removeListener("request",h),e.req&&e.req.removeListener("finish",a),e.removeListener("end",o),e.removeListener("close",o),e.removeListener("finish",a),e.removeListener("end",u),e.removeListener("error",l),e.removeListener("close",d)}}Gie.exports=$ie});var Wie=E((tCt,Vie)=>{"use strict";var fC;function yc(e,t,r){return t=VQe(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function VQe(e){var t=WQe(e,"string");return typeof t=="symbol"?t:String(t)}function WQe(e,t){if(typeof e!="object"||e===null)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var KQe=zie(),_c=Symbol("lastResolve"),Wu=Symbol("lastReject"),ag=Symbol("error"),dC=Symbol("ended"),Ku=Symbol("lastPromise"),FN=Symbol("handlePromise"),Yu=Symbol("stream");function bc(e,t){return{value:e,done:t}}function YQe(e){var t=e[_c];if(t!==null){var r=e[Yu].read();r!==null&&(e[Ku]=null,e[_c]=null,e[Wu]=null,t(bc(r,!1)))}}function XQe(e){process.nextTick(YQe,e)}function JQe(e,t){return function(r,n){e.then(function(){if(t[dC]){r(bc(void 0,!0));return}t[FN](r,n)},n)}}var QQe=Object.getPrototypeOf(function(){}),ZQe=Object.setPrototypeOf((fC={get stream(){return this[Yu]},next:function(){var t=this,r=this[ag];if(r!==null)return Promise.reject(r);if(this[dC])return Promise.resolve(bc(void 0,!0));if(this[Yu].destroyed)return new Promise(function(s,a){process.nextTick(function(){t[ag]?a(t[ag]):s(bc(void 0,!0))})});var n=this[Ku],i;if(n)i=new Promise(JQe(n,this));else{var o=this[Yu].read();if(o!==null)return Promise.resolve(bc(o,!1));i=new Promise(this[FN])}return this[Ku]=i,i}},yc(fC,Symbol.asyncIterator,function(){return this}),yc(fC,"return",function(){var t=this;return new Promise(function(r,n){t[Yu].destroy(null,function(i){if(i){n(i);return}r(bc(void 0,!0))})})}),fC),QQe),eZe=function(t){var r,n=Object.create(ZQe,(r={},yc(r,Yu,{value:t,writable:!0}),yc(r,_c,{value:null,writable:!0}),yc(r,Wu,{value:null,writable:!0}),yc(r,ag,{value:null,writable:!0}),yc(r,dC,{value:t._readableState.endEmitted,writable:!0}),yc(r,FN,{value:function(o,s){var a=n[Yu].read();a?(n[Ku]=null,n[_c]=null,n[Wu]=null,o(bc(a,!1))):(n[_c]=o,n[Wu]=s)},writable:!0}),r));return n[Ku]=null,KQe(t,function(i){if(i&&i.code!=="ERR_STREAM_PREMATURE_CLOSE"){var o=n[Wu];o!==null&&(n[Ku]=null,n[_c]=null,n[Wu]=null,o(i)),n[ag]=i;return}var s=n[_c];s!==null&&(n[Ku]=null,n[_c]=null,n[Wu]=null,s(bc(void 0,!0))),n[dC]=!0}),t.on("readable",XQe.bind(null,n)),n};Vie.exports=eZe});var Jie=E((rCt,Xie)=>{"use strict";function Kie(e,t,r,n,i,o,s){try{var a=e[o](s),c=a.value}catch(u){r(u);return}a.done?t(c):Promise.resolve(c).then(n,i)}function tZe(e){return function(){var t=this,r=arguments;return new Promise(function(n,i){var o=e.apply(t,r);function s(c){Kie(o,n,i,s,a,"next",c)}function a(c){Kie(o,n,i,s,a,"throw",c)}s(void 0)})}}function Yie(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function rZe(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Yie(Object(r),!0).forEach(function(n){nZe(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Yie(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function nZe(e,t,r){return t=iZe(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function iZe(e){var t=oZe(e,"string");return typeof t=="symbol"?t:String(t)}function oZe(e,t){if(typeof e!="object"||e===null)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var sZe=Ad().codes.ERR_INVALID_ARG_TYPE;function aZe(e,t,r){var n;if(t&&typeof t.next=="function")n=t;else if(t&&t[Symbol.asyncIterator])n=t[Symbol.asyncIterator]();else if(t&&t[Symbol.iterator])n=t[Symbol.iterator]();else throw new sZe("iterable",["Iterable"],t);var i=new e(rZe({objectMode:!0},r)),o=!1;i._read=function(){o||(o=!0,s())};function s(){return a.apply(this,arguments)}function a(){return a=tZe(function*(){try{var c=yield n.next(),u=c.value,l=c.done;l?i.push(null):i.push(yield u)?s():o=!1}catch(d){i.destroy(d)}}),a.apply(this,arguments)}return i}Xie.exports=aZe});var coe=E((iCt,aoe)=>{"use strict";aoe.exports=bt;var Rd;bt.ReadableState=toe;var nCt=require("events").EventEmitter,eoe=function(t,r){return t.listeners(r).length},ug=kN(),pC=require("buffer").Buffer,cZe=(typeof global<"u"?global:typeof window<"u"?window:typeof self<"u"?self:{}).Uint8Array||function(){};function uZe(e){return pC.from(e)}function lZe(e){return pC.isBuffer(e)||e instanceof cZe}var qN=require("util"),rt;qN&&qN.debuglog?rt=qN.debuglog("stream"):rt=function(){};var fZe=Uie(),VN=MN(),dZe=LN(),pZe=dZe.getHighWaterMark,hC=Ad().codes,hZe=hC.ERR_INVALID_ARG_TYPE,mZe=hC.ERR_STREAM_PUSH_AFTER_EOF,gZe=hC.ERR_METHOD_NOT_IMPLEMENTED,yZe=hC.ERR_STREAM_UNSHIFT_AFTER_END_EVENT,Pd,jN,UN;ri()(bt,ug);var cg=VN.errorOrDestroy,HN=["error","close","destroy","pause","resume"];function _Ze(e,t,r){if(typeof e.prependListener=="function")return e.prependListener(t,r);!e._events||!e._events[t]?e.on(t,r):Array.isArray(e._events[t])?e._events[t].unshift(r):e._events[t]=[r,e._events[t]]}function toe(e,t,r){Rd=Rd||lg(),e=e||{},typeof r!="boolean"&&(r=t instanceof Rd),this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.readableObjectMode),this.highWaterMark=pZe(this,e,"readableHighWaterMark",r),this.buffer=new fZe,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=e.emitClose!==!1,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&&(Pd||(Pd=wl().StringDecoder),this.decoder=new Pd(e.encoding),this.encoding=e.encoding)}function bt(e){if(Rd=Rd||lg(),!(this instanceof bt))return new bt(e);var t=this instanceof Rd;this._readableState=new toe(e,this,t),this.readable=!0,e&&(typeof e.read=="function"&&(this._read=e.read),typeof e.destroy=="function"&&(this._destroy=e.destroy)),ug.call(this)}Object.defineProperty(bt.prototype,"destroyed",{enumerable:!1,get:function(){return this._readableState===void 0?!1:this._readableState.destroyed},set:function(t){this._readableState&&(this._readableState.destroyed=t)}});bt.prototype.destroy=VN.destroy;bt.prototype._undestroy=VN.undestroy;bt.prototype._destroy=function(e,t){t(e)};bt.prototype.push=function(e,t){var r=this._readableState,n;return r.objectMode?n=!0:typeof e=="string"&&(t=t||r.defaultEncoding,t!==r.encoding&&(e=pC.from(e,t),t=""),n=!0),roe(this,e,t,!1,n)};bt.prototype.unshift=function(e){return roe(this,e,null,!0,!1)};function roe(e,t,r,n,i){rt("readableAddChunk",t);var o=e._readableState;if(t===null)o.reading=!1,wZe(e,o);else{var s;if(i||(s=bZe(o,t)),s)cg(e,s);else if(o.objectMode||t&&t.length>0)if(typeof t!="string"&&!o.objectMode&&Object.getPrototypeOf(t)!==pC.prototype&&(t=uZe(t)),n)o.endEmitted?cg(e,new yZe):$N(e,o,t,!0);else if(o.ended)cg(e,new mZe);else{if(o.destroyed)return!1;o.reading=!1,o.decoder&&!r?(t=o.decoder.write(t),o.objectMode||t.length!==0?$N(e,o,t,!1):zN(e,o)):$N(e,o,t,!1)}else n||(o.reading=!1,zN(e,o))}return!o.ended&&(o.length<o.highWaterMark||o.length===0)}function $N(e,t,r,n){t.flowing&&t.length===0&&!t.sync?(t.awaitDrain=0,e.emit("data",r)):(t.length+=t.objectMode?1:r.length,n?t.buffer.unshift(r):t.buffer.push(r),t.needReadable&&mC(e)),zN(e,t)}function bZe(e,t){var r;return!lZe(t)&&typeof t!="string"&&t!==void 0&&!e.objectMode&&(r=new hZe("chunk",["string","Buffer","Uint8Array"],t)),r}bt.prototype.isPaused=function(){return this._readableState.flowing===!1};bt.prototype.setEncoding=function(e){Pd||(Pd=wl().StringDecoder);var t=new Pd(e);this._readableState.decoder=t,this._readableState.encoding=this._readableState.decoder.encoding;for(var r=this._readableState.buffer.head,n="";r!==null;)n+=t.write(r.data),r=r.next;return this._readableState.buffer.clear(),n!==""&&this._readableState.buffer.push(n),this._readableState.length=n.length,this};var Qie=1073741824;function EZe(e){return e>=Qie?e=Qie:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}function Zie(e,t){return e<=0||t.length===0&&t.ended?0:t.objectMode?1:e!==e?t.flowing&&t.length?t.buffer.head.data.length:t.length:(e>t.highWaterMark&&(t.highWaterMark=EZe(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}bt.prototype.read=function(e){rt("read",e),e=parseInt(e,10);var t=this._readableState,r=e;if(e!==0&&(t.emittedReadable=!1),e===0&&t.needReadable&&((t.highWaterMark!==0?t.length>=t.highWaterMark:t.length>0)||t.ended))return rt("read: emitReadable",t.length,t.ended),t.length===0&&t.ended?GN(this):mC(this),null;if(e=Zie(e,t),e===0&&t.ended)return t.length===0&&GN(this),null;var n=t.needReadable;rt("need readable",n),(t.length===0||t.length-e<t.highWaterMark)&&(n=!0,rt("length less than watermark",n)),t.ended||t.reading?(n=!1,rt("reading or ended",n)):n&&(rt("do read"),t.reading=!0,t.sync=!0,t.length===0&&(t.needReadable=!0),this._read(t.highWaterMark),t.sync=!1,t.reading||(e=Zie(r,t)));var i;return e>0?i=ooe(e,t):i=null,i===null?(t.needReadable=t.length<=t.highWaterMark,e=0):(t.length-=e,t.awaitDrain=0),t.length===0&&(t.ended||(t.needReadable=!0),r!==e&&t.ended&&GN(this)),i!==null&&this.emit("data",i),i};function wZe(e,t){if(rt("onEofChunk"),!t.ended){if(t.decoder){var r=t.decoder.end();r&&r.length&&(t.buffer.push(r),t.length+=t.objectMode?1:r.length)}t.ended=!0,t.sync?mC(e):(t.needReadable=!1,t.emittedReadable||(t.emittedReadable=!0,noe(e)))}}function mC(e){var t=e._readableState;rt("emitReadable",t.needReadable,t.emittedReadable),t.needReadable=!1,t.emittedReadable||(rt("emitReadable",t.flowing),t.emittedReadable=!0,process.nextTick(noe,e))}function noe(e){var t=e._readableState;rt("emitReadable_",t.destroyed,t.length,t.ended),!t.destroyed&&(t.length||t.ended)&&(e.emit("readable"),t.emittedReadable=!1),t.needReadable=!t.flowing&&!t.ended&&t.length<=t.highWaterMark,WN(e)}function zN(e,t){t.readingMore||(t.readingMore=!0,process.nextTick(SZe,e,t))}function SZe(e,t){for(;!t.reading&&!t.ended&&(t.length<t.highWaterMark||t.flowing&&t.length===0);){var r=t.length;if(rt("maybeReadMore read 0"),e.read(0),r===t.length)break}t.readingMore=!1}bt.prototype._read=function(e){cg(this,new gZe("_read()"))};bt.prototype.pipe=function(e,t){var r=this,n=this._readableState;switch(n.pipesCount){case 0:n.pipes=e;break;case 1:n.pipes=[n.pipes,e];break;default:n.pipes.push(e);break}n.pipesCount+=1,rt("pipe count=%d opts=%j",n.pipesCount,t);var i=(!t||t.end!==!1)&&e!==process.stdout&&e!==process.stderr,o=i?a:m;n.endEmitted?process.nextTick(o):r.once("end",o),e.on("unpipe",s);function s(_,w){rt("onunpipe"),_===r&&w&&w.hasUnpiped===!1&&(w.hasUnpiped=!0,l())}function a(){rt("onend"),e.end()}var c=vZe(r);e.on("drain",c);var u=!1;function l(){rt("cleanup"),e.removeListener("close",f),e.removeListener("finish",p),e.removeListener("drain",c),e.removeListener("error",h),e.removeListener("unpipe",s),r.removeListener("end",a),r.removeListener("end",m),r.removeListener("data",d),u=!0,n.awaitDrain&&(!e._writableState||e._writableState.needDrain)&&c()}r.on("data",d);function d(_){rt("ondata");var w=e.write(_);rt("dest.write",w),w===!1&&((n.pipesCount===1&&n.pipes===e||n.pipesCount>1&&soe(n.pipes,e)!==-1)&&!u&&(rt("false write response, pause",n.awaitDrain),n.awaitDrain++),r.pause())}function h(_){rt("onerror",_),m(),e.removeListener("error",h),eoe(e,"error")===0&&cg(e,_)}_Ze(e,"error",h);function f(){e.removeListener("finish",p),m()}e.once("close",f);function p(){rt("onfinish"),e.removeListener("close",f),m()}e.once("finish",p);function m(){rt("unpipe"),r.unpipe(e)}return e.emit("pipe",r),n.flowing||(rt("pipe resume"),r.resume()),e};function vZe(e){return function(){var r=e._readableState;rt("pipeOnDrain",r.awaitDrain),r.awaitDrain&&r.awaitDrain--,r.awaitDrain===0&&eoe(e,"data")&&(r.flowing=!0,WN(e))}}bt.prototype.unpipe=function(e){var t=this._readableState,r={hasUnpiped:!1};if(t.pipesCount===0)return this;if(t.pipesCount===1)return e&&e!==t.pipes?this:(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,r),this);if(!e){var n=t.pipes,i=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var o=0;o<i;o++)n[o].emit("unpipe",this,{hasUnpiped:!1});return this}var s=soe(t.pipes,e);return s===-1?this:(t.pipes.splice(s,1),t.pipesCount-=1,t.pipesCount===1&&(t.pipes=t.pipes[0]),e.emit("unpipe",this,r),this)};bt.prototype.on=function(e,t){var r=ug.prototype.on.call(this,e,t),n=this._readableState;return e==="data"?(n.readableListening=this.listenerCount("readable")>0,n.flowing!==!1&&this.resume()):e==="readable"&&!n.endEmitted&&!n.readableListening&&(n.readableListening=n.needReadable=!0,n.flowing=!1,n.emittedReadable=!1,rt("on readable",n.length,n.reading),n.length?mC(this):n.reading||process.nextTick(CZe,this)),r};bt.prototype.addListener=bt.prototype.on;bt.prototype.removeListener=function(e,t){var r=ug.prototype.removeListener.call(this,e,t);return e==="readable"&&process.nextTick(ioe,this),r};bt.prototype.removeAllListeners=function(e){var t=ug.prototype.removeAllListeners.apply(this,arguments);return(e==="readable"||e===void 0)&&process.nextTick(ioe,this),t};function ioe(e){var t=e._readableState;t.readableListening=e.listenerCount("readable")>0,t.resumeScheduled&&!t.paused?t.flowing=!0:e.listenerCount("data")>0&&e.resume()}function CZe(e){rt("readable nexttick read 0"),e.read(0)}bt.prototype.resume=function(){var e=this._readableState;return e.flowing||(rt("resume"),e.flowing=!e.readableListening,xZe(this,e)),e.paused=!1,this};function xZe(e,t){t.resumeScheduled||(t.resumeScheduled=!0,process.nextTick(TZe,e,t))}function TZe(e,t){rt("resume",t.reading),t.reading||e.read(0),t.resumeScheduled=!1,e.emit("resume"),WN(e),t.flowing&&!t.reading&&e.read(0)}bt.prototype.pause=function(){return rt("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(rt("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this};function WN(e){var t=e._readableState;for(rt("flow",t.flowing);t.flowing&&e.read()!==null;);}bt.prototype.wrap=function(e){var t=this,r=this._readableState,n=!1;e.on("end",function(){if(rt("wrapped end"),r.decoder&&!r.ended){var s=r.decoder.end();s&&s.length&&t.push(s)}t.push(null)}),e.on("data",function(s){if(rt("wrapped data"),r.decoder&&(s=r.decoder.write(s)),!(r.objectMode&&s==null)&&!(!r.objectMode&&(!s||!s.length))){var a=t.push(s);a||(n=!0,e.pause())}});for(var i in e)this[i]===void 0&&typeof e[i]=="function"&&(this[i]=(function(a){return function(){return e[a].apply(e,arguments)}})(i));for(var o=0;o<HN.length;o++)e.on(HN[o],this.emit.bind(this,HN[o]));return this._read=function(s){rt("wrapped _read",s),n&&(n=!1,e.resume())},this};typeof Symbol=="function"&&(bt.prototype[Symbol.asyncIterator]=function(){return jN===void 0&&(jN=Wie()),jN(this)});Object.defineProperty(bt.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}});Object.defineProperty(bt.prototype,"readableBuffer",{enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}});Object.defineProperty(bt.prototype,"readableFlowing",{enumerable:!1,get:function(){return this._readableState.flowing},set:function(t){this._readableState&&(this._readableState.flowing=t)}});bt._fromList=ooe;Object.defineProperty(bt.prototype,"readableLength",{enumerable:!1,get:function(){return this._readableState.length}});function ooe(e,t){if(t.length===0)return null;var r;return t.objectMode?r=t.buffer.shift():!e||e>=t.length?(t.decoder?r=t.buffer.join(""):t.buffer.length===1?r=t.buffer.first():r=t.buffer.concat(t.length),t.buffer.clear()):r=t.buffer.consume(e,t.decoder),r}function GN(e){var t=e._readableState;rt("endReadable",t.endEmitted),t.endEmitted||(t.ended=!0,process.nextTick(AZe,t,e))}function AZe(e,t){if(rt("endReadableNT",e.endEmitted,e.length),!e.endEmitted&&e.length===0&&(e.endEmitted=!0,t.readable=!1,t.emit("end"),e.autoDestroy)){var r=t._writableState;(!r||r.autoDestroy&&r.finished)&&t.destroy()}}typeof Symbol=="function"&&(bt.from=function(e,t){return UN===void 0&&(UN=Jie()),UN(bt,e,t)});function soe(e,t){for(var r=0,n=e.length;r<n;r++)if(e[r]===t)return r;return-1}});var lg=E((oCt,loe)=>{"use strict";var RZe=Object.keys||function(e){var t=[];for(var r in e)t.push(r);return t};loe.exports=ss;var uoe=coe(),YN=XN();ri()(ss,uoe);for(KN=RZe(YN.prototype),gC=0;gC<KN.length;gC++)yC=KN[gC],ss.prototype[yC]||(ss.prototype[yC]=YN.prototype[yC]);var KN,yC,gC;function ss(e){if(!(this instanceof ss))return new ss(e);uoe.call(this,e),YN.call(this,e),this.allowHalfOpen=!0,e&&(e.readable===!1&&(this.readable=!1),e.writable===!1&&(this.writable=!1),e.allowHalfOpen===!1&&(this.allowHalfOpen=!1,this.once("end",PZe)))}Object.defineProperty(ss.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});Object.defineProperty(ss.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}});Object.defineProperty(ss.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}});function PZe(){this._writableState.ended||process.nextTick(OZe,this)}function OZe(e){e.end()}Object.defineProperty(ss.prototype,"destroyed",{enumerable:!1,get:function(){return this._readableState===void 0||this._writableState===void 0?!1:this._readableState.destroyed&&this._writableState.destroyed},set:function(t){this._readableState===void 0||this._writableState===void 0||(this._readableState.destroyed=t,this._writableState.destroyed=t)}})});var XN=E((sCt,goe)=>{"use strict";goe.exports=pr;function doe(e){var t=this;this.next=null,this.entry=null,this.finish=function(){iet(t,e)}}var Od;pr.WritableState=dg;var IZe={deprecate:fy()},poe=kN(),bC=require("buffer").Buffer,DZe=(typeof global<"u"?global:typeof window<"u"?window:typeof self<"u"?self:{}).Uint8Array||function(){};function kZe(e){return bC.from(e)}function NZe(e){return bC.isBuffer(e)||e instanceof DZe}var QN=MN(),MZe=LN(),LZe=MZe.getHighWaterMark,Ec=Ad().codes,BZe=Ec.ERR_INVALID_ARG_TYPE,FZe=Ec.ERR_METHOD_NOT_IMPLEMENTED,qZe=Ec.ERR_MULTIPLE_CALLBACK,jZe=Ec.ERR_STREAM_CANNOT_PIPE,UZe=Ec.ERR_STREAM_DESTROYED,HZe=Ec.ERR_STREAM_NULL_VALUES,$Ze=Ec.ERR_STREAM_WRITE_AFTER_END,GZe=Ec.ERR_UNKNOWN_ENCODING,Id=QN.errorOrDestroy;ri()(pr,poe);function zZe(){}function dg(e,t,r){Od=Od||lg(),e=e||{},typeof r!="boolean"&&(r=t instanceof Od),this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.writableObjectMode),this.highWaterMark=LZe(this,e,"writableHighWaterMark",r),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var n=e.decodeStrings===!1;this.decodeStrings=!n,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(i){QZe(t,i)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=e.emitClose!==!1,this.autoDestroy=!!e.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new doe(this)}dg.prototype.getBuffer=function(){for(var t=this.bufferedRequest,r=[];t;)r.push(t),t=t.next;return r};(function(){try{Object.defineProperty(dg.prototype,"buffer",{get:IZe.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch{}})();var _C;typeof Symbol=="function"&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]=="function"?(_C=Function.prototype[Symbol.hasInstance],Object.defineProperty(pr,Symbol.hasInstance,{value:function(t){return _C.call(this,t)?!0:this!==pr?!1:t&&t._writableState instanceof dg}})):_C=function(t){return t instanceof this};function pr(e){Od=Od||lg();var t=this instanceof Od;if(!t&&!_C.call(pr,this))return new pr(e);this._writableState=new dg(e,this,t),this.writable=!0,e&&(typeof e.write=="function"&&(this._write=e.write),typeof e.writev=="function"&&(this._writev=e.writev),typeof e.destroy=="function"&&(this._destroy=e.destroy),typeof e.final=="function"&&(this._final=e.final)),poe.call(this)}pr.prototype.pipe=function(){Id(this,new jZe)};function VZe(e,t){var r=new $Ze;Id(e,r),process.nextTick(t,r)}function WZe(e,t,r,n){var i;return r===null?i=new HZe:typeof r!="string"&&!t.objectMode&&(i=new BZe("chunk",["string","Buffer"],r)),i?(Id(e,i),process.nextTick(n,i),!1):!0}pr.prototype.write=function(e,t,r){var n=this._writableState,i=!1,o=!n.objectMode&&NZe(e);return o&&!bC.isBuffer(e)&&(e=kZe(e)),typeof t=="function"&&(r=t,t=null),o?t="buffer":t||(t=n.defaultEncoding),typeof r!="function"&&(r=zZe),n.ending?VZe(this,r):(o||WZe(this,n,e,r))&&(n.pendingcb++,i=YZe(this,n,o,e,t,r)),i};pr.prototype.cork=function(){this._writableState.corked++};pr.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,!e.writing&&!e.corked&&!e.bufferProcessing&&e.bufferedRequest&&hoe(this,e))};pr.prototype.setDefaultEncoding=function(t){if(typeof t=="string"&&(t=t.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((t+"").toLowerCase())>-1))throw new GZe(t);return this._writableState.defaultEncoding=t,this};Object.defineProperty(pr.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}});function KZe(e,t,r){return!e.objectMode&&e.decodeStrings!==!1&&typeof t=="string"&&(t=bC.from(t,r)),t}Object.defineProperty(pr.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});function YZe(e,t,r,n,i,o){if(!r){var s=KZe(t,n,i);n!==s&&(r=!0,i="buffer",n=s)}var a=t.objectMode?1:n.length;t.length+=a;var c=t.length<t.highWaterMark;if(c||(t.needDrain=!0),t.writing||t.corked){var u=t.lastBufferedRequest;t.lastBufferedRequest={chunk:n,encoding:i,isBuf:r,callback:o,next:null},u?u.next=t.lastBufferedRequest:t.bufferedRequest=t.lastBufferedRequest,t.bufferedRequestCount+=1}else JN(e,t,!1,a,n,i,o);return c}function JN(e,t,r,n,i,o,s){t.writelen=n,t.writecb=s,t.writing=!0,t.sync=!0,t.destroyed?t.onwrite(new UZe("write")):r?e._writev(i,t.onwrite):e._write(i,o,t.onwrite),t.sync=!1}function XZe(e,t,r,n,i){--t.pendingcb,r?(process.nextTick(i,n),process.nextTick(fg,e,t),e._writableState.errorEmitted=!0,Id(e,n)):(i(n),e._writableState.errorEmitted=!0,Id(e,n),fg(e,t))}function JZe(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}function QZe(e,t){var r=e._writableState,n=r.sync,i=r.writecb;if(typeof i!="function")throw new qZe;if(JZe(r),t)XZe(e,r,n,t,i);else{var o=moe(r)||e.destroyed;!o&&!r.corked&&!r.bufferProcessing&&r.bufferedRequest&&hoe(e,r),n?process.nextTick(foe,e,r,o,i):foe(e,r,o,i)}}function foe(e,t,r,n){r||ZZe(e,t),t.pendingcb--,n(),fg(e,t)}function ZZe(e,t){t.length===0&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}function hoe(e,t){t.bufferProcessing=!0;var r=t.bufferedRequest;if(e._writev&&r&&r.next){var n=t.bufferedRequestCount,i=new Array(n),o=t.corkedRequestsFree;o.entry=r;for(var s=0,a=!0;r;)i[s]=r,r.isBuf||(a=!1),r=r.next,s+=1;i.allBuffers=a,JN(e,t,!0,t.length,i,"",o.finish),t.pendingcb++,t.lastBufferedRequest=null,o.next?(t.corkedRequestsFree=o.next,o.next=null):t.corkedRequestsFree=new doe(t),t.bufferedRequestCount=0}else{for(;r;){var c=r.chunk,u=r.encoding,l=r.callback,d=t.objectMode?1:c.length;if(JN(e,t,!1,d,c,u,l),r=r.next,t.bufferedRequestCount--,t.writing)break}r===null&&(t.lastBufferedRequest=null)}t.bufferedRequest=r,t.bufferProcessing=!1}pr.prototype._write=function(e,t,r){r(new FZe("_write()"))};pr.prototype._writev=null;pr.prototype.end=function(e,t,r){var n=this._writableState;return typeof e=="function"?(r=e,e=null,t=null):typeof t=="function"&&(r=t,t=null),e!=null&&this.write(e,t),n.corked&&(n.corked=1,this.uncork()),n.ending||net(this,n,r),this};Object.defineProperty(pr.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}});function moe(e){return e.ending&&e.length===0&&e.bufferedRequest===null&&!e.finished&&!e.writing}function eet(e,t){e._final(function(r){t.pendingcb--,r&&Id(e,r),t.prefinished=!0,e.emit("prefinish"),fg(e,t)})}function tet(e,t){!t.prefinished&&!t.finalCalled&&(typeof e._final=="function"&&!t.destroyed?(t.pendingcb++,t.finalCalled=!0,process.nextTick(eet,e,t)):(t.prefinished=!0,e.emit("prefinish")))}function fg(e,t){var r=moe(t);if(r&&(tet(e,t),t.pendingcb===0&&(t.finished=!0,e.emit("finish"),t.autoDestroy))){var n=e._readableState;(!n||n.autoDestroy&&n.endEmitted)&&e.destroy()}return r}function net(e,t,r){t.ending=!0,fg(e,t),r&&(t.finished?process.nextTick(r):e.once("finish",r)),t.ended=!0,e.writable=!1}function iet(e,t,r){var n=e.entry;for(e.entry=null;n;){var i=n.callback;t.pendingcb--,i(r),n=n.next}t.corkedRequestsFree.next=e}Object.defineProperty(pr.prototype,"destroyed",{enumerable:!1,get:function(){return this._writableState===void 0?!1:this._writableState.destroyed},set:function(t){this._writableState&&(this._writableState.destroyed=t)}});pr.prototype.destroy=QN.destroy;pr.prototype._undestroy=QN.undestroy;pr.prototype._destroy=function(e,t){t(e)}});var ZN=E((aCt,boe)=>{"use strict";var oet=require("util"),yoe=XN(),{LEVEL:_oe}=Pr(),pg=boe.exports=function(t={}){yoe.call(this,{objectMode:!0,highWaterMark:t.highWaterMark}),this.format=t.format,this.level=t.level,this.handleExceptions=t.handleExceptions,this.handleRejections=t.handleRejections,this.silent=t.silent,t.log&&(this.log=t.log),t.logv&&(this.logv=t.logv),t.close&&(this.close=t.close),this.once("pipe",r=>{this.levels=r.levels,this.parent=r}),this.once("unpipe",r=>{r===this.parent&&(this.parent=null,this.close&&this.close())})};oet.inherits(pg,yoe);pg.prototype._write=function(t,r,n){if(this.silent||t.exception===!0&&!this.handleExceptions)return n(null);let i=this.level||this.parent&&this.parent.level;if(!i||this.levels[i]>=this.levels[t[_oe]]){if(t&&!this.format)return this.log(t,n);let o,s;try{s=this.format.transform(Object.assign({},t),this.format.options)}catch(a){o=a}if(o||!s){if(n(),o)throw o;return}return this.log(s,n)}return this._writableState.sync=!1,n(null)};pg.prototype._writev=function(t,r){if(this.logv){let n=t.filter(this._accept,this);return n.length?this.logv(n,r):r(null)}for(let n=0;n<t.length;n++){if(!this._accept(t[n]))continue;if(t[n].chunk&&!this.format){this.log(t[n].chunk,t[n].callback);continue}let i,o;try{o=this.format.transform(Object.assign({},t[n].chunk),this.format.options)}catch(s){i=s}if(i||!o){if(t[n].callback(),i)throw r(null),i}else this.log(o,t[n].callback)}return r(null)};pg.prototype._accept=function(t){let r=t.chunk;if(this.silent)return!1;let n=this.level||this.parent&&this.parent.level;return!!((r.exception===!0||!n||this.levels[n]>=this.levels[r[_oe]])&&(this.handleExceptions||r.exception!==!0))};pg.prototype._nop=function(){}});var tM=E((cCt,woe)=>{"use strict";var set=require("util"),{LEVEL:eM}=Pr(),Eoe=ZN(),hg=woe.exports=function(t={}){if(Eoe.call(this,t),!t.transport||typeof t.transport.log!="function")throw new Error("Invalid transport, must be an object with a log method.");this.transport=t.transport,this.level=this.level||t.transport.level,this.handleExceptions=this.handleExceptions||t.transport.handleExceptions,this._deprecated();function r(n){this.emit("error",n,this.transport)}this.transport.__winstonError||(this.transport.__winstonError=r.bind(this),this.transport.on("error",this.transport.__winstonError))};set.inherits(hg,Eoe);hg.prototype._write=function(t,r,n){if(this.silent||t.exception===!0&&!this.handleExceptions)return n(null);(!this.level||this.levels[this.level]>=this.levels[t[eM]])&&this.transport.log(t[eM],t.message,t,this._nop),n(null)};hg.prototype._writev=function(t,r){for(let n=0;n<t.length;n++)this._accept(t[n])&&(this.transport.log(t[n].chunk[eM],t[n].chunk.message,t[n].chunk,this._nop),t[n].callback());return r(null)};hg.prototype._deprecated=function(){console.error([`${this.transport.name} is a legacy winston transport. Consider upgrading: `,"- Upgrade docs: https://github.com/winstonjs/winston/blob/master/UPGRADE-3.0.md"].join(`
|
|
266
|
+
`))};hg.prototype.close=function(){this.transport.close&&this.transport.close(),this.transport.__winstonError&&(this.transport.removeListener("error",this.transport.__winstonError),this.transport.__winstonError=null)}});var Dd=E((uCt,rM)=>{"use strict";rM.exports=ZN();rM.exports.LegacyTransportStream=tM()});var Coe=E((fCt,voe)=>{"use strict";var aet=require("os"),{LEVEL:Soe,MESSAGE:kd}=Pr(),cet=Dd();voe.exports=class extends cet{constructor(t={}){super(t),this.name=t.name||"console",this.stderrLevels=this._stringArrayToSet(t.stderrLevels),this.consoleWarnLevels=this._stringArrayToSet(t.consoleWarnLevels),this.eol=typeof t.eol=="string"?t.eol:aet.EOL,this.forceConsole=t.forceConsole||!1,this._consoleLog=console.log.bind(console),this._consoleWarn=console.warn.bind(console),this._consoleError=console.error.bind(console),this.setMaxListeners(30)}log(t,r){if(setImmediate(()=>this.emit("logged",t)),this.stderrLevels[t[Soe]]){console._stderr&&!this.forceConsole?console._stderr.write(`${t[kd]}${this.eol}`):this._consoleError(t[kd]),r&&r();return}else if(this.consoleWarnLevels[t[Soe]]){console._stderr&&!this.forceConsole?console._stderr.write(`${t[kd]}${this.eol}`):this._consoleWarn(t[kd]),r&&r();return}console._stdout&&!this.forceConsole?console._stdout.write(`${t[kd]}${this.eol}`):this._consoleLog(t[kd]),r&&r()}_stringArrayToSet(t,r){if(!t)return{};if(r=r||"Cannot make set from type other than Array of string elements",!Array.isArray(t))throw new Error(r);return t.reduce((n,i)=>{if(typeof i!="string")throw new Error(r);return n[i]=!0,n},{})}}});var wC=E((EC,xoe)=>{"use strict";Object.defineProperty(EC,"__esModule",{value:!0});EC.default=uet;function uet(e){return e&&typeof e.length=="number"&&e.length>=0&&e.length%1===0}xoe.exports=EC.default});var Aoe=E((SC,Toe)=>{"use strict";Object.defineProperty(SC,"__esModule",{value:!0});SC.default=function(e){return function(...t){var r=t.pop();return e.call(this,t,r)}};Toe.exports=SC.default});var Ooe=E(wc=>{"use strict";Object.defineProperty(wc,"__esModule",{value:!0});wc.fallback=Roe;wc.wrap=Poe;var fet=wc.hasQueueMicrotask=typeof queueMicrotask=="function"&&queueMicrotask,det=wc.hasSetImmediate=typeof setImmediate=="function"&&setImmediate,pet=wc.hasNextTick=typeof process=="object"&&typeof process.nextTick=="function";function Roe(e){setTimeout(e,0)}function Poe(e){return(t,...r)=>e(()=>t(...r))}var mg;fet?mg=queueMicrotask:det?mg=setImmediate:pet?mg=process.nextTick:mg=Roe;wc.default=Poe(mg)});var Moe=E((vC,Noe)=>{"use strict";Object.defineProperty(vC,"__esModule",{value:!0});vC.default=bet;var het=Aoe(),met=koe(het),get=Ooe(),yet=koe(get),_et=Xu();function koe(e){return e&&e.__esModule?e:{default:e}}function bet(e){return(0,_et.isAsync)(e)?function(...t){let r=t.pop(),n=e.apply(this,t);return Ioe(n,r)}:(0,met.default)(function(t,r){var n;try{n=e.apply(this,t)}catch(i){return r(i)}if(n&&typeof n.then=="function")return Ioe(n,r);r(null,n)})}function Ioe(e,t){return e.then(r=>{Doe(t,null,r)},r=>{Doe(t,r&&(r instanceof Error||r.message)?r:new Error(r))})}function Doe(e,t,r){try{e(t,r)}catch(n){(0,yet.default)(i=>{throw i},n)}}Noe.exports=vC.default});var Xu=E(Ys=>{"use strict";Object.defineProperty(Ys,"__esModule",{value:!0});Ys.isAsyncIterable=Ys.isAsyncGenerator=Ys.isAsync=void 0;var Eet=Moe(),wet=vet(Eet);function vet(e){return e&&e.__esModule?e:{default:e}}function Loe(e){return e[Symbol.toStringTag]==="AsyncFunction"}function Cet(e){return e[Symbol.toStringTag]==="AsyncGenerator"}function xet(e){return typeof e[Symbol.asyncIterator]=="function"}function Tet(e){if(typeof e!="function")throw new Error("expected a function");return Loe(e)?(0,wet.default)(e):e}Ys.default=Tet;Ys.isAsync=Loe;Ys.isAsyncGenerator=Cet;Ys.isAsyncIterable=xet});var Nd=E((CC,Boe)=>{"use strict";Object.defineProperty(CC,"__esModule",{value:!0});CC.default=Aet;function Aet(e,t){if(t||(t=e.length),!t)throw new Error("arity is undefined");function r(...n){return typeof n[t-1]=="function"?e.apply(this,n):new Promise((i,o)=>{n[t-1]=(s,...a)=>{if(s)return o(s);i(a.length>1?a:a[0])},e.apply(this,n)})}return r}Boe.exports=CC.default});var qoe=E((xC,Foe)=>{"use strict";Object.defineProperty(xC,"__esModule",{value:!0});var Ret=wC(),Pet=nM(Ret),Oet=Xu(),Iet=nM(Oet),Det=Nd(),ket=nM(Det);function nM(e){return e&&e.__esModule?e:{default:e}}xC.default=(0,ket.default)((e,t,r)=>{var n=(0,Pet.default)(t)?[]:{};e(t,(i,o,s)=>{(0,Iet.default)(i)((a,...c)=>{c.length<2&&([c]=c),n[o]=c,s(a)})},i=>r(i,n))},3);Foe.exports=xC.default});var iM=E((TC,joe)=>{"use strict";Object.defineProperty(TC,"__esModule",{value:!0});TC.default=Net;function Net(e){function t(...r){if(e!==null){var n=e;e=null,n.apply(this,r)}}return Object.assign(t,e),t}joe.exports=TC.default});var Hoe=E((AC,Uoe)=>{"use strict";Object.defineProperty(AC,"__esModule",{value:!0});AC.default=function(e){return e[Symbol.iterator]&&e[Symbol.iterator]()};Uoe.exports=AC.default});var zoe=E((RC,Goe)=>{"use strict";Object.defineProperty(RC,"__esModule",{value:!0});RC.default=Het;var Met=wC(),Let=$oe(Met),Bet=Hoe(),Fet=$oe(Bet);function $oe(e){return e&&e.__esModule?e:{default:e}}function qet(e){var t=-1,r=e.length;return function(){return++t<r?{value:e[t],key:t}:null}}function jet(e){var t=-1;return function(){var n=e.next();return n.done?null:(t++,{value:n.value,key:t})}}function Uet(e){var t=e?Object.keys(e):[],r=-1,n=t.length;return function i(){var o=t[++r];return o==="__proto__"?i():r<n?{value:e[o],key:o}:null}}function Het(e){if((0,Let.default)(e))return qet(e);var t=(0,Fet.default)(e);return t?jet(t):Uet(e)}Goe.exports=RC.default});var oM=E((PC,Voe)=>{"use strict";Object.defineProperty(PC,"__esModule",{value:!0});PC.default=$et;function $et(e){return function(...t){if(e===null)throw new Error("Callback was already called.");var r=e;e=null,r.apply(this,t)}}Voe.exports=PC.default});var IC=E((OC,Woe)=>{"use strict";Object.defineProperty(OC,"__esModule",{value:!0});var Get={};OC.default=Get;Woe.exports=OC.default});var Yoe=E((DC,Koe)=>{"use strict";Object.defineProperty(DC,"__esModule",{value:!0});DC.default=Ket;var zet=IC(),Vet=Wet(zet);function Wet(e){return e&&e.__esModule?e:{default:e}}function Ket(e,t,r,n){let i=!1,o=!1,s=!1,a=0,c=0;function u(){a>=t||s||i||(s=!0,e.next().then(({value:h,done:f})=>{if(!(o||i)){if(s=!1,f){i=!0,a<=0&&n(null);return}a++,r(h,c,l),c++,u()}}).catch(d))}function l(h,f){if(a-=1,!o){if(h)return d(h);if(h===!1){i=!0,o=!0;return}if(f===Vet.default||i&&a<=0)return i=!0,n(null);u()}}function d(h){o||(s=!1,i=!0,n(h))}u()}Koe.exports=DC.default});var Zoe=E((kC,Qoe)=>{"use strict";Object.defineProperty(kC,"__esModule",{value:!0});var Yet=iM(),Xet=gg(Yet),Jet=zoe(),Qet=gg(Jet),Zet=oM(),ett=gg(Zet),Xoe=Xu(),ttt=Yoe(),Joe=gg(ttt),rtt=IC(),ntt=gg(rtt);function gg(e){return e&&e.__esModule?e:{default:e}}kC.default=e=>(t,r,n)=>{if(n=(0,Xet.default)(n),e<=0)throw new RangeError("concurrency limit cannot be less than 1");if(!t)return n(null);if((0,Xoe.isAsyncGenerator)(t))return(0,Joe.default)(t,e,r,n);if((0,Xoe.isAsyncIterable)(t))return(0,Joe.default)(t[Symbol.asyncIterator](),e,r,n);var i=(0,Qet.default)(t),o=!1,s=!1,a=0,c=!1;function u(d,h){if(!s)if(a-=1,d)o=!0,n(d);else if(d===!1)o=!0,s=!0;else{if(h===ntt.default||o&&a<=0)return o=!0,n(null);c||l()}}function l(){for(c=!0;a<e&&!o;){var d=i();if(d===null){o=!0,a<=0&&n(null);return}a+=1,r(d.value,d.key,(0,ett.default)(u))}c=!1}l()};Qoe.exports=kC.default});var aM=E((NC,ese)=>{"use strict";Object.defineProperty(NC,"__esModule",{value:!0});var itt=Zoe(),ott=sM(itt),stt=Xu(),att=sM(stt),ctt=Nd(),utt=sM(ctt);function sM(e){return e&&e.__esModule?e:{default:e}}function ltt(e,t,r,n){return(0,ott.default)(t)(e,(0,att.default)(r),n)}NC.default=(0,utt.default)(ltt,4);ese.exports=NC.default});var nse=E((MC,rse)=>{"use strict";Object.defineProperty(MC,"__esModule",{value:!0});var ftt=aM(),dtt=tse(ftt),ptt=Nd(),htt=tse(ptt);function tse(e){return e&&e.__esModule?e:{default:e}}function mtt(e,t,r){return(0,dtt.default)(e,1,t,r)}MC.default=(0,htt.default)(mtt,3);rse.exports=MC.default});var sse=E((LC,ose)=>{"use strict";Object.defineProperty(LC,"__esModule",{value:!0});LC.default=Ett;var gtt=qoe(),ytt=ise(gtt),_tt=nse(),btt=ise(_tt);function ise(e){return e&&e.__esModule?e:{default:e}}function Ett(e,t){return(0,ytt.default)(btt.default,e,t)}ose.exports=LC.default});var cM=E((hCt,ase)=>{"use strict";ase.exports=require("stream")});var pse=E((mCt,dse)=>{"use strict";function cse(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function use(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?cse(Object(r),!0).forEach(function(n){wtt(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):cse(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function wtt(e,t,r){return t=fse(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Stt(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function lse(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,fse(n.key),n)}}function vtt(e,t,r){return t&&lse(e.prototype,t),r&&lse(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}function fse(e){var t=Ctt(e,"string");return typeof t=="symbol"?t:String(t)}function Ctt(e,t){if(typeof e!="object"||e===null)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var xtt=require("buffer"),BC=xtt.Buffer,Ttt=require("util"),uM=Ttt.inspect,Att=uM&&uM.custom||"inspect";function Rtt(e,t,r){BC.prototype.copy.call(e,t,r)}dse.exports=(function(){function e(){Stt(this,e),this.head=null,this.tail=null,this.length=0}return vtt(e,[{key:"push",value:function(r){var n={data:r,next:null};this.length>0?this.tail.next=n:this.head=n,this.tail=n,++this.length}},{key:"unshift",value:function(r){var n={data:r,next:this.head};this.length===0&&(this.tail=n),this.head=n,++this.length}},{key:"shift",value:function(){if(this.length!==0){var r=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,r}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(r){if(this.length===0)return"";for(var n=this.head,i=""+n.data;n=n.next;)i+=r+n.data;return i}},{key:"concat",value:function(r){if(this.length===0)return BC.alloc(0);for(var n=BC.allocUnsafe(r>>>0),i=this.head,o=0;i;)Rtt(i.data,n,o),o+=i.data.length,i=i.next;return n}},{key:"consume",value:function(r,n){var i;return r<this.head.data.length?(i=this.head.data.slice(0,r),this.head.data=this.head.data.slice(r)):r===this.head.data.length?i=this.shift():i=n?this._getString(r):this._getBuffer(r),i}},{key:"first",value:function(){return this.head.data}},{key:"_getString",value:function(r){var n=this.head,i=1,o=n.data;for(r-=o.length;n=n.next;){var s=n.data,a=r>s.length?s.length:r;if(a===s.length?o+=s:o+=s.slice(0,r),r-=a,r===0){a===s.length?(++i,n.next?this.head=n.next:this.head=this.tail=null):(this.head=n,n.data=s.slice(a));break}++i}return this.length-=i,o}},{key:"_getBuffer",value:function(r){var n=BC.allocUnsafe(r),i=this.head,o=1;for(i.data.copy(n),r-=i.data.length;i=i.next;){var s=i.data,a=r>s.length?s.length:r;if(s.copy(n,n.length-r,0,a),r-=a,r===0){a===s.length?(++o,i.next?this.head=i.next:this.head=this.tail=null):(this.head=i,i.data=s.slice(a));break}++o}return this.length-=o,n}},{key:Att,value:function(r,n){return uM(this,use(use({},n),{},{depth:0,customInspect:!1}))}}]),e})()});var fM=E((gCt,mse)=>{"use strict";function Ptt(e,t){var r=this,n=this._readableState&&this._readableState.destroyed,i=this._writableState&&this._writableState.destroyed;return n||i?(t?t(e):e&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,process.nextTick(lM,this,e)):process.nextTick(lM,this,e)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,function(o){!t&&o?r._writableState?r._writableState.errorEmitted?process.nextTick(FC,r):(r._writableState.errorEmitted=!0,process.nextTick(hse,r,o)):process.nextTick(hse,r,o):t?(process.nextTick(FC,r),t(o)):process.nextTick(FC,r)}),this)}function hse(e,t){lM(e,t),FC(e)}function FC(e){e._writableState&&!e._writableState.emitClose||e._readableState&&!e._readableState.emitClose||e.emit("close")}function Ott(){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 lM(e,t){e.emit("error",t)}function Itt(e,t){var r=e._readableState,n=e._writableState;r&&r.autoDestroy||n&&n.autoDestroy?e.destroy(t):e.emit("error",t)}mse.exports={destroy:Ptt,undestroy:Ott,errorOrDestroy:Itt}});var Sc=E((yCt,_se)=>{"use strict";var yse={};function Xi(e,t,r){r||(r=Error);function n(o,s,a){return typeof t=="string"?t:t(o,s,a)}class i extends r{constructor(s,a,c){super(n(s,a,c))}}i.prototype.name=r.name,i.prototype.code=e,yse[e]=i}function gse(e,t){if(Array.isArray(e)){let r=e.length;return e=e.map(n=>String(n)),r>2?`one of ${t} ${e.slice(0,r-1).join(", ")}, or `+e[r-1]:r===2?`one of ${t} ${e[0]} or ${e[1]}`:`of ${t} ${e[0]}`}else return`of ${t} ${String(e)}`}function Dtt(e,t,r){return e.substr(!r||r<0?0:+r,t.length)===t}function ktt(e,t,r){return(r===void 0||r>e.length)&&(r=e.length),e.substring(r-t.length,r)===t}function Ntt(e,t,r){return typeof r!="number"&&(r=0),r+t.length>e.length?!1:e.indexOf(t,r)!==-1}Xi("ERR_INVALID_OPT_VALUE",function(e,t){return'The value "'+t+'" is invalid for option "'+e+'"'},TypeError);Xi("ERR_INVALID_ARG_TYPE",function(e,t,r){let n;typeof t=="string"&&Dtt(t,"not ")?(n="must not be",t=t.replace(/^not /,"")):n="must be";let i;if(ktt(e," argument"))i=`The ${e} ${n} ${gse(t,"type")}`;else{let o=Ntt(e,".")?"property":"argument";i=`The "${e}" ${o} ${n} ${gse(t,"type")}`}return i+=`. Received type ${typeof r}`,i},TypeError);Xi("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF");Xi("ERR_METHOD_NOT_IMPLEMENTED",function(e){return"The "+e+" method is not implemented"});Xi("ERR_STREAM_PREMATURE_CLOSE","Premature close");Xi("ERR_STREAM_DESTROYED",function(e){return"Cannot call "+e+" after a stream was destroyed"});Xi("ERR_MULTIPLE_CALLBACK","Callback called multiple times");Xi("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable");Xi("ERR_STREAM_WRITE_AFTER_END","write after end");Xi("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError);Xi("ERR_UNKNOWN_ENCODING",function(e){return"Unknown encoding: "+e},TypeError);Xi("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event");_se.exports.codes=yse});var dM=E((_Ct,bse)=>{"use strict";var Mtt=Sc().codes.ERR_INVALID_OPT_VALUE;function Ltt(e,t,r){return e.highWaterMark!=null?e.highWaterMark:t?e[r]:null}function Btt(e,t,r,n){var i=Ltt(t,n,r);if(i!=null){if(!(isFinite(i)&&Math.floor(i)===i)||i<0){var o=n?r:"highWaterMark";throw new Mtt(o,i)}return Math.floor(i)}return e.objectMode?16:16*1024}bse.exports={getHighWaterMark:Btt}});var mM=E((bCt,xse)=>{"use strict";xse.exports=hr;function wse(e){var t=this;this.next=null,this.entry=null,this.finish=function(){lrt(t,e)}}var Md;hr.WritableState=_g;var Ftt={deprecate:fy()},Sse=cM(),jC=require("buffer").Buffer,qtt=(typeof global<"u"?global:typeof window<"u"?window:typeof self<"u"?self:{}).Uint8Array||function(){};function jtt(e){return jC.from(e)}function Utt(e){return jC.isBuffer(e)||e instanceof qtt}var hM=fM(),Htt=dM(),$tt=Htt.getHighWaterMark,vc=Sc().codes,Gtt=vc.ERR_INVALID_ARG_TYPE,ztt=vc.ERR_METHOD_NOT_IMPLEMENTED,Vtt=vc.ERR_MULTIPLE_CALLBACK,Wtt=vc.ERR_STREAM_CANNOT_PIPE,Ktt=vc.ERR_STREAM_DESTROYED,Ytt=vc.ERR_STREAM_NULL_VALUES,Xtt=vc.ERR_STREAM_WRITE_AFTER_END,Jtt=vc.ERR_UNKNOWN_ENCODING,Ld=hM.errorOrDestroy;ri()(hr,Sse);function Qtt(){}function _g(e,t,r){Md=Md||Ju(),e=e||{},typeof r!="boolean"&&(r=t instanceof Md),this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.writableObjectMode),this.highWaterMark=$tt(this,e,"writableHighWaterMark",r),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var n=e.decodeStrings===!1;this.decodeStrings=!n,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(i){ort(t,i)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=e.emitClose!==!1,this.autoDestroy=!!e.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new wse(this)}_g.prototype.getBuffer=function(){for(var t=this.bufferedRequest,r=[];t;)r.push(t),t=t.next;return r};(function(){try{Object.defineProperty(_g.prototype,"buffer",{get:Ftt.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch{}})();var qC;typeof Symbol=="function"&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]=="function"?(qC=Function.prototype[Symbol.hasInstance],Object.defineProperty(hr,Symbol.hasInstance,{value:function(t){return qC.call(this,t)?!0:this!==hr?!1:t&&t._writableState instanceof _g}})):qC=function(t){return t instanceof this};function hr(e){Md=Md||Ju();var t=this instanceof Md;if(!t&&!qC.call(hr,this))return new hr(e);this._writableState=new _g(e,this,t),this.writable=!0,e&&(typeof e.write=="function"&&(this._write=e.write),typeof e.writev=="function"&&(this._writev=e.writev),typeof e.destroy=="function"&&(this._destroy=e.destroy),typeof e.final=="function"&&(this._final=e.final)),Sse.call(this)}hr.prototype.pipe=function(){Ld(this,new Wtt)};function Ztt(e,t){var r=new Xtt;Ld(e,r),process.nextTick(t,r)}function ert(e,t,r,n){var i;return r===null?i=new Ytt:typeof r!="string"&&!t.objectMode&&(i=new Gtt("chunk",["string","Buffer"],r)),i?(Ld(e,i),process.nextTick(n,i),!1):!0}hr.prototype.write=function(e,t,r){var n=this._writableState,i=!1,o=!n.objectMode&&Utt(e);return o&&!jC.isBuffer(e)&&(e=jtt(e)),typeof t=="function"&&(r=t,t=null),o?t="buffer":t||(t=n.defaultEncoding),typeof r!="function"&&(r=Qtt),n.ending?Ztt(this,r):(o||ert(this,n,e,r))&&(n.pendingcb++,i=rrt(this,n,o,e,t,r)),i};hr.prototype.cork=function(){this._writableState.corked++};hr.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,!e.writing&&!e.corked&&!e.bufferProcessing&&e.bufferedRequest&&vse(this,e))};hr.prototype.setDefaultEncoding=function(t){if(typeof t=="string"&&(t=t.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((t+"").toLowerCase())>-1))throw new Jtt(t);return this._writableState.defaultEncoding=t,this};Object.defineProperty(hr.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}});function trt(e,t,r){return!e.objectMode&&e.decodeStrings!==!1&&typeof t=="string"&&(t=jC.from(t,r)),t}Object.defineProperty(hr.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});function rrt(e,t,r,n,i,o){if(!r){var s=trt(t,n,i);n!==s&&(r=!0,i="buffer",n=s)}var a=t.objectMode?1:n.length;t.length+=a;var c=t.length<t.highWaterMark;if(c||(t.needDrain=!0),t.writing||t.corked){var u=t.lastBufferedRequest;t.lastBufferedRequest={chunk:n,encoding:i,isBuf:r,callback:o,next:null},u?u.next=t.lastBufferedRequest:t.bufferedRequest=t.lastBufferedRequest,t.bufferedRequestCount+=1}else pM(e,t,!1,a,n,i,o);return c}function pM(e,t,r,n,i,o,s){t.writelen=n,t.writecb=s,t.writing=!0,t.sync=!0,t.destroyed?t.onwrite(new Ktt("write")):r?e._writev(i,t.onwrite):e._write(i,o,t.onwrite),t.sync=!1}function nrt(e,t,r,n,i){--t.pendingcb,r?(process.nextTick(i,n),process.nextTick(yg,e,t),e._writableState.errorEmitted=!0,Ld(e,n)):(i(n),e._writableState.errorEmitted=!0,Ld(e,n),yg(e,t))}function irt(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}function ort(e,t){var r=e._writableState,n=r.sync,i=r.writecb;if(typeof i!="function")throw new Vtt;if(irt(r),t)nrt(e,r,n,t,i);else{var o=Cse(r)||e.destroyed;!o&&!r.corked&&!r.bufferProcessing&&r.bufferedRequest&&vse(e,r),n?process.nextTick(Ese,e,r,o,i):Ese(e,r,o,i)}}function Ese(e,t,r,n){r||srt(e,t),t.pendingcb--,n(),yg(e,t)}function srt(e,t){t.length===0&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}function vse(e,t){t.bufferProcessing=!0;var r=t.bufferedRequest;if(e._writev&&r&&r.next){var n=t.bufferedRequestCount,i=new Array(n),o=t.corkedRequestsFree;o.entry=r;for(var s=0,a=!0;r;)i[s]=r,r.isBuf||(a=!1),r=r.next,s+=1;i.allBuffers=a,pM(e,t,!0,t.length,i,"",o.finish),t.pendingcb++,t.lastBufferedRequest=null,o.next?(t.corkedRequestsFree=o.next,o.next=null):t.corkedRequestsFree=new wse(t),t.bufferedRequestCount=0}else{for(;r;){var c=r.chunk,u=r.encoding,l=r.callback,d=t.objectMode?1:c.length;if(pM(e,t,!1,d,c,u,l),r=r.next,t.bufferedRequestCount--,t.writing)break}r===null&&(t.lastBufferedRequest=null)}t.bufferedRequest=r,t.bufferProcessing=!1}hr.prototype._write=function(e,t,r){r(new ztt("_write()"))};hr.prototype._writev=null;hr.prototype.end=function(e,t,r){var n=this._writableState;return typeof e=="function"?(r=e,e=null,t=null):typeof t=="function"&&(r=t,t=null),e!=null&&this.write(e,t),n.corked&&(n.corked=1,this.uncork()),n.ending||urt(this,n,r),this};Object.defineProperty(hr.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}});function Cse(e){return e.ending&&e.length===0&&e.bufferedRequest===null&&!e.finished&&!e.writing}function art(e,t){e._final(function(r){t.pendingcb--,r&&Ld(e,r),t.prefinished=!0,e.emit("prefinish"),yg(e,t)})}function crt(e,t){!t.prefinished&&!t.finalCalled&&(typeof e._final=="function"&&!t.destroyed?(t.pendingcb++,t.finalCalled=!0,process.nextTick(art,e,t)):(t.prefinished=!0,e.emit("prefinish")))}function yg(e,t){var r=Cse(t);if(r&&(crt(e,t),t.pendingcb===0&&(t.finished=!0,e.emit("finish"),t.autoDestroy))){var n=e._readableState;(!n||n.autoDestroy&&n.endEmitted)&&e.destroy()}return r}function urt(e,t,r){t.ending=!0,yg(e,t),r&&(t.finished?process.nextTick(r):e.once("finish",r)),t.ended=!0,e.writable=!1}function lrt(e,t,r){var n=e.entry;for(e.entry=null;n;){var i=n.callback;t.pendingcb--,i(r),n=n.next}t.corkedRequestsFree.next=e}Object.defineProperty(hr.prototype,"destroyed",{enumerable:!1,get:function(){return this._writableState===void 0?!1:this._writableState.destroyed},set:function(t){this._writableState&&(this._writableState.destroyed=t)}});hr.prototype.destroy=hM.destroy;hr.prototype._undestroy=hM.undestroy;hr.prototype._destroy=function(e,t){t(e)}});var Ju=E((ECt,Ase)=>{"use strict";var frt=Object.keys||function(e){var t=[];for(var r in e)t.push(r);return t};Ase.exports=as;var Tse=_M(),yM=mM();ri()(as,Tse);for(gM=frt(yM.prototype),UC=0;UC<gM.length;UC++)HC=gM[UC],as.prototype[HC]||(as.prototype[HC]=yM.prototype[HC]);var gM,HC,UC;function as(e){if(!(this instanceof as))return new as(e);Tse.call(this,e),yM.call(this,e),this.allowHalfOpen=!0,e&&(e.readable===!1&&(this.readable=!1),e.writable===!1&&(this.writable=!1),e.allowHalfOpen===!1&&(this.allowHalfOpen=!1,this.once("end",drt)))}Object.defineProperty(as.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});Object.defineProperty(as.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}});Object.defineProperty(as.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}});function drt(){this._writableState.ended||process.nextTick(prt,this)}function prt(e){e.end()}Object.defineProperty(as.prototype,"destroyed",{enumerable:!1,get:function(){return this._readableState===void 0||this._writableState===void 0?!1:this._readableState.destroyed&&this._writableState.destroyed},set:function(t){this._readableState===void 0||this._writableState===void 0||(this._readableState.destroyed=t,this._writableState.destroyed=t)}})});var $C=E((wCt,Ose)=>{"use strict";var Rse=Sc().codes.ERR_STREAM_PREMATURE_CLOSE;function hrt(e){var t=!1;return function(){if(!t){t=!0;for(var r=arguments.length,n=new Array(r),i=0;i<r;i++)n[i]=arguments[i];e.apply(this,n)}}}function mrt(){}function grt(e){return e.setHeader&&typeof e.abort=="function"}function Pse(e,t,r){if(typeof t=="function")return Pse(e,null,t);t||(t={}),r=hrt(r||mrt);var n=t.readable||t.readable!==!1&&e.readable,i=t.writable||t.writable!==!1&&e.writable,o=function(){e.writable||a()},s=e._writableState&&e._writableState.finished,a=function(){i=!1,s=!0,n||r.call(e)},c=e._readableState&&e._readableState.endEmitted,u=function(){n=!1,c=!0,i||r.call(e)},l=function(p){r.call(e,p)},d=function(){var p;if(n&&!c)return(!e._readableState||!e._readableState.ended)&&(p=new Rse),r.call(e,p);if(i&&!s)return(!e._writableState||!e._writableState.ended)&&(p=new Rse),r.call(e,p)},h=function(){e.req.on("finish",a)};return grt(e)?(e.on("complete",a),e.on("abort",d),e.req?h():e.on("request",h)):i&&!e._writableState&&(e.on("end",o),e.on("close",o)),e.on("end",u),e.on("finish",a),t.error!==!1&&e.on("error",l),e.on("close",d),function(){e.removeListener("complete",a),e.removeListener("abort",d),e.removeListener("request",h),e.req&&e.req.removeListener("finish",a),e.removeListener("end",o),e.removeListener("close",o),e.removeListener("finish",a),e.removeListener("end",u),e.removeListener("error",l),e.removeListener("close",d)}}Ose.exports=Pse});var Dse=E((SCt,Ise)=>{"use strict";var GC;function Cc(e,t,r){return t=yrt(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function yrt(e){var t=_rt(e,"string");return typeof t=="symbol"?t:String(t)}function _rt(e,t){if(typeof e!="object"||e===null)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var brt=$C(),xc=Symbol("lastResolve"),Qu=Symbol("lastReject"),bg=Symbol("error"),zC=Symbol("ended"),Zu=Symbol("lastPromise"),bM=Symbol("handlePromise"),el=Symbol("stream");function Tc(e,t){return{value:e,done:t}}function Ert(e){var t=e[xc];if(t!==null){var r=e[el].read();r!==null&&(e[Zu]=null,e[xc]=null,e[Qu]=null,t(Tc(r,!1)))}}function wrt(e){process.nextTick(Ert,e)}function Srt(e,t){return function(r,n){e.then(function(){if(t[zC]){r(Tc(void 0,!0));return}t[bM](r,n)},n)}}var vrt=Object.getPrototypeOf(function(){}),Crt=Object.setPrototypeOf((GC={get stream(){return this[el]},next:function(){var t=this,r=this[bg];if(r!==null)return Promise.reject(r);if(this[zC])return Promise.resolve(Tc(void 0,!0));if(this[el].destroyed)return new Promise(function(s,a){process.nextTick(function(){t[bg]?a(t[bg]):s(Tc(void 0,!0))})});var n=this[Zu],i;if(n)i=new Promise(Srt(n,this));else{var o=this[el].read();if(o!==null)return Promise.resolve(Tc(o,!1));i=new Promise(this[bM])}return this[Zu]=i,i}},Cc(GC,Symbol.asyncIterator,function(){return this}),Cc(GC,"return",function(){var t=this;return new Promise(function(r,n){t[el].destroy(null,function(i){if(i){n(i);return}r(Tc(void 0,!0))})})}),GC),vrt),xrt=function(t){var r,n=Object.create(Crt,(r={},Cc(r,el,{value:t,writable:!0}),Cc(r,xc,{value:null,writable:!0}),Cc(r,Qu,{value:null,writable:!0}),Cc(r,bg,{value:null,writable:!0}),Cc(r,zC,{value:t._readableState.endEmitted,writable:!0}),Cc(r,bM,{value:function(o,s){var a=n[el].read();a?(n[Zu]=null,n[xc]=null,n[Qu]=null,o(Tc(a,!1))):(n[xc]=o,n[Qu]=s)},writable:!0}),r));return n[Zu]=null,brt(t,function(i){if(i&&i.code!=="ERR_STREAM_PREMATURE_CLOSE"){var o=n[Qu];o!==null&&(n[Zu]=null,n[xc]=null,n[Qu]=null,o(i)),n[bg]=i;return}var s=n[xc];s!==null&&(n[Zu]=null,n[xc]=null,n[Qu]=null,s(Tc(void 0,!0))),n[zC]=!0}),t.on("readable",wrt.bind(null,n)),n};Ise.exports=xrt});var Lse=E((vCt,Mse)=>{"use strict";function kse(e,t,r,n,i,o,s){try{var a=e[o](s),c=a.value}catch(u){r(u);return}a.done?t(c):Promise.resolve(c).then(n,i)}function Trt(e){return function(){var t=this,r=arguments;return new Promise(function(n,i){var o=e.apply(t,r);function s(c){kse(o,n,i,s,a,"next",c)}function a(c){kse(o,n,i,s,a,"throw",c)}s(void 0)})}}function Nse(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Art(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Nse(Object(r),!0).forEach(function(n){Rrt(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Nse(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Rrt(e,t,r){return t=Prt(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Prt(e){var t=Ort(e,"string");return typeof t=="symbol"?t:String(t)}function Ort(e,t){if(typeof e!="object"||e===null)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Irt=Sc().codes.ERR_INVALID_ARG_TYPE;function Drt(e,t,r){var n;if(t&&typeof t.next=="function")n=t;else if(t&&t[Symbol.asyncIterator])n=t[Symbol.asyncIterator]();else if(t&&t[Symbol.iterator])n=t[Symbol.iterator]();else throw new Irt("iterable",["Iterable"],t);var i=new e(Art({objectMode:!0},r)),o=!1;i._read=function(){o||(o=!0,s())};function s(){return a.apply(this,arguments)}function a(){return a=Trt(function*(){try{var c=yield n.next(),u=c.value,l=c.done;l?i.push(null):i.push(yield u)?s():o=!1}catch(d){i.destroy(d)}}),a.apply(this,arguments)}return i}Mse.exports=Drt});var _M=E((xCt,Vse)=>{"use strict";Vse.exports=Et;var Bd;Et.ReadableState=jse;var CCt=require("events").EventEmitter,qse=function(t,r){return t.listeners(r).length},wg=cM(),VC=require("buffer").Buffer,krt=(typeof global<"u"?global:typeof window<"u"?window:typeof self<"u"?self:{}).Uint8Array||function(){};function Nrt(e){return VC.from(e)}function Mrt(e){return VC.isBuffer(e)||e instanceof krt}var EM=require("util"),nt;EM&&EM.debuglog?nt=EM.debuglog("stream"):nt=function(){};var Lrt=pse(),AM=fM(),Brt=dM(),Frt=Brt.getHighWaterMark,WC=Sc().codes,qrt=WC.ERR_INVALID_ARG_TYPE,jrt=WC.ERR_STREAM_PUSH_AFTER_EOF,Urt=WC.ERR_METHOD_NOT_IMPLEMENTED,Hrt=WC.ERR_STREAM_UNSHIFT_AFTER_END_EVENT,Fd,wM,SM;ri()(Et,wg);var Eg=AM.errorOrDestroy,vM=["error","close","destroy","pause","resume"];function $rt(e,t,r){if(typeof e.prependListener=="function")return e.prependListener(t,r);!e._events||!e._events[t]?e.on(t,r):Array.isArray(e._events[t])?e._events[t].unshift(r):e._events[t]=[r,e._events[t]]}function jse(e,t,r){Bd=Bd||Ju(),e=e||{},typeof r!="boolean"&&(r=t instanceof Bd),this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.readableObjectMode),this.highWaterMark=Frt(this,e,"readableHighWaterMark",r),this.buffer=new Lrt,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=e.emitClose!==!1,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&&(Fd||(Fd=wl().StringDecoder),this.decoder=new Fd(e.encoding),this.encoding=e.encoding)}function Et(e){if(Bd=Bd||Ju(),!(this instanceof Et))return new Et(e);var t=this instanceof Bd;this._readableState=new jse(e,this,t),this.readable=!0,e&&(typeof e.read=="function"&&(this._read=e.read),typeof e.destroy=="function"&&(this._destroy=e.destroy)),wg.call(this)}Object.defineProperty(Et.prototype,"destroyed",{enumerable:!1,get:function(){return this._readableState===void 0?!1:this._readableState.destroyed},set:function(t){this._readableState&&(this._readableState.destroyed=t)}});Et.prototype.destroy=AM.destroy;Et.prototype._undestroy=AM.undestroy;Et.prototype._destroy=function(e,t){t(e)};Et.prototype.push=function(e,t){var r=this._readableState,n;return r.objectMode?n=!0:typeof e=="string"&&(t=t||r.defaultEncoding,t!==r.encoding&&(e=VC.from(e,t),t=""),n=!0),Use(this,e,t,!1,n)};Et.prototype.unshift=function(e){return Use(this,e,null,!0,!1)};function Use(e,t,r,n,i){nt("readableAddChunk",t);var o=e._readableState;if(t===null)o.reading=!1,Vrt(e,o);else{var s;if(i||(s=Grt(o,t)),s)Eg(e,s);else if(o.objectMode||t&&t.length>0)if(typeof t!="string"&&!o.objectMode&&Object.getPrototypeOf(t)!==VC.prototype&&(t=Nrt(t)),n)o.endEmitted?Eg(e,new Hrt):CM(e,o,t,!0);else if(o.ended)Eg(e,new jrt);else{if(o.destroyed)return!1;o.reading=!1,o.decoder&&!r?(t=o.decoder.write(t),o.objectMode||t.length!==0?CM(e,o,t,!1):TM(e,o)):CM(e,o,t,!1)}else n||(o.reading=!1,TM(e,o))}return!o.ended&&(o.length<o.highWaterMark||o.length===0)}function CM(e,t,r,n){t.flowing&&t.length===0&&!t.sync?(t.awaitDrain=0,e.emit("data",r)):(t.length+=t.objectMode?1:r.length,n?t.buffer.unshift(r):t.buffer.push(r),t.needReadable&&KC(e)),TM(e,t)}function Grt(e,t){var r;return!Mrt(t)&&typeof t!="string"&&t!==void 0&&!e.objectMode&&(r=new qrt("chunk",["string","Buffer","Uint8Array"],t)),r}Et.prototype.isPaused=function(){return this._readableState.flowing===!1};Et.prototype.setEncoding=function(e){Fd||(Fd=wl().StringDecoder);var t=new Fd(e);this._readableState.decoder=t,this._readableState.encoding=this._readableState.decoder.encoding;for(var r=this._readableState.buffer.head,n="";r!==null;)n+=t.write(r.data),r=r.next;return this._readableState.buffer.clear(),n!==""&&this._readableState.buffer.push(n),this._readableState.length=n.length,this};var Bse=1073741824;function zrt(e){return e>=Bse?e=Bse:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}function Fse(e,t){return e<=0||t.length===0&&t.ended?0:t.objectMode?1:e!==e?t.flowing&&t.length?t.buffer.head.data.length:t.length:(e>t.highWaterMark&&(t.highWaterMark=zrt(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}Et.prototype.read=function(e){nt("read",e),e=parseInt(e,10);var t=this._readableState,r=e;if(e!==0&&(t.emittedReadable=!1),e===0&&t.needReadable&&((t.highWaterMark!==0?t.length>=t.highWaterMark:t.length>0)||t.ended))return nt("read: emitReadable",t.length,t.ended),t.length===0&&t.ended?xM(this):KC(this),null;if(e=Fse(e,t),e===0&&t.ended)return t.length===0&&xM(this),null;var n=t.needReadable;nt("need readable",n),(t.length===0||t.length-e<t.highWaterMark)&&(n=!0,nt("length less than watermark",n)),t.ended||t.reading?(n=!1,nt("reading or ended",n)):n&&(nt("do read"),t.reading=!0,t.sync=!0,t.length===0&&(t.needReadable=!0),this._read(t.highWaterMark),t.sync=!1,t.reading||(e=Fse(r,t)));var i;return e>0?i=Gse(e,t):i=null,i===null?(t.needReadable=t.length<=t.highWaterMark,e=0):(t.length-=e,t.awaitDrain=0),t.length===0&&(t.ended||(t.needReadable=!0),r!==e&&t.ended&&xM(this)),i!==null&&this.emit("data",i),i};function Vrt(e,t){if(nt("onEofChunk"),!t.ended){if(t.decoder){var r=t.decoder.end();r&&r.length&&(t.buffer.push(r),t.length+=t.objectMode?1:r.length)}t.ended=!0,t.sync?KC(e):(t.needReadable=!1,t.emittedReadable||(t.emittedReadable=!0,Hse(e)))}}function KC(e){var t=e._readableState;nt("emitReadable",t.needReadable,t.emittedReadable),t.needReadable=!1,t.emittedReadable||(nt("emitReadable",t.flowing),t.emittedReadable=!0,process.nextTick(Hse,e))}function Hse(e){var t=e._readableState;nt("emitReadable_",t.destroyed,t.length,t.ended),!t.destroyed&&(t.length||t.ended)&&(e.emit("readable"),t.emittedReadable=!1),t.needReadable=!t.flowing&&!t.ended&&t.length<=t.highWaterMark,RM(e)}function TM(e,t){t.readingMore||(t.readingMore=!0,process.nextTick(Wrt,e,t))}function Wrt(e,t){for(;!t.reading&&!t.ended&&(t.length<t.highWaterMark||t.flowing&&t.length===0);){var r=t.length;if(nt("maybeReadMore read 0"),e.read(0),r===t.length)break}t.readingMore=!1}Et.prototype._read=function(e){Eg(this,new Urt("_read()"))};Et.prototype.pipe=function(e,t){var r=this,n=this._readableState;switch(n.pipesCount){case 0:n.pipes=e;break;case 1:n.pipes=[n.pipes,e];break;default:n.pipes.push(e);break}n.pipesCount+=1,nt("pipe count=%d opts=%j",n.pipesCount,t);var i=(!t||t.end!==!1)&&e!==process.stdout&&e!==process.stderr,o=i?a:m;n.endEmitted?process.nextTick(o):r.once("end",o),e.on("unpipe",s);function s(_,w){nt("onunpipe"),_===r&&w&&w.hasUnpiped===!1&&(w.hasUnpiped=!0,l())}function a(){nt("onend"),e.end()}var c=Krt(r);e.on("drain",c);var u=!1;function l(){nt("cleanup"),e.removeListener("close",f),e.removeListener("finish",p),e.removeListener("drain",c),e.removeListener("error",h),e.removeListener("unpipe",s),r.removeListener("end",a),r.removeListener("end",m),r.removeListener("data",d),u=!0,n.awaitDrain&&(!e._writableState||e._writableState.needDrain)&&c()}r.on("data",d);function d(_){nt("ondata");var w=e.write(_);nt("dest.write",w),w===!1&&((n.pipesCount===1&&n.pipes===e||n.pipesCount>1&&zse(n.pipes,e)!==-1)&&!u&&(nt("false write response, pause",n.awaitDrain),n.awaitDrain++),r.pause())}function h(_){nt("onerror",_),m(),e.removeListener("error",h),qse(e,"error")===0&&Eg(e,_)}$rt(e,"error",h);function f(){e.removeListener("finish",p),m()}e.once("close",f);function p(){nt("onfinish"),e.removeListener("close",f),m()}e.once("finish",p);function m(){nt("unpipe"),r.unpipe(e)}return e.emit("pipe",r),n.flowing||(nt("pipe resume"),r.resume()),e};function Krt(e){return function(){var r=e._readableState;nt("pipeOnDrain",r.awaitDrain),r.awaitDrain&&r.awaitDrain--,r.awaitDrain===0&&qse(e,"data")&&(r.flowing=!0,RM(e))}}Et.prototype.unpipe=function(e){var t=this._readableState,r={hasUnpiped:!1};if(t.pipesCount===0)return this;if(t.pipesCount===1)return e&&e!==t.pipes?this:(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,r),this);if(!e){var n=t.pipes,i=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var o=0;o<i;o++)n[o].emit("unpipe",this,{hasUnpiped:!1});return this}var s=zse(t.pipes,e);return s===-1?this:(t.pipes.splice(s,1),t.pipesCount-=1,t.pipesCount===1&&(t.pipes=t.pipes[0]),e.emit("unpipe",this,r),this)};Et.prototype.on=function(e,t){var r=wg.prototype.on.call(this,e,t),n=this._readableState;return e==="data"?(n.readableListening=this.listenerCount("readable")>0,n.flowing!==!1&&this.resume()):e==="readable"&&!n.endEmitted&&!n.readableListening&&(n.readableListening=n.needReadable=!0,n.flowing=!1,n.emittedReadable=!1,nt("on readable",n.length,n.reading),n.length?KC(this):n.reading||process.nextTick(Yrt,this)),r};Et.prototype.addListener=Et.prototype.on;Et.prototype.removeListener=function(e,t){var r=wg.prototype.removeListener.call(this,e,t);return e==="readable"&&process.nextTick($se,this),r};Et.prototype.removeAllListeners=function(e){var t=wg.prototype.removeAllListeners.apply(this,arguments);return(e==="readable"||e===void 0)&&process.nextTick($se,this),t};function $se(e){var t=e._readableState;t.readableListening=e.listenerCount("readable")>0,t.resumeScheduled&&!t.paused?t.flowing=!0:e.listenerCount("data")>0&&e.resume()}function Yrt(e){nt("readable nexttick read 0"),e.read(0)}Et.prototype.resume=function(){var e=this._readableState;return e.flowing||(nt("resume"),e.flowing=!e.readableListening,Xrt(this,e)),e.paused=!1,this};function Xrt(e,t){t.resumeScheduled||(t.resumeScheduled=!0,process.nextTick(Jrt,e,t))}function Jrt(e,t){nt("resume",t.reading),t.reading||e.read(0),t.resumeScheduled=!1,e.emit("resume"),RM(e),t.flowing&&!t.reading&&e.read(0)}Et.prototype.pause=function(){return nt("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(nt("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this};function RM(e){var t=e._readableState;for(nt("flow",t.flowing);t.flowing&&e.read()!==null;);}Et.prototype.wrap=function(e){var t=this,r=this._readableState,n=!1;e.on("end",function(){if(nt("wrapped end"),r.decoder&&!r.ended){var s=r.decoder.end();s&&s.length&&t.push(s)}t.push(null)}),e.on("data",function(s){if(nt("wrapped data"),r.decoder&&(s=r.decoder.write(s)),!(r.objectMode&&s==null)&&!(!r.objectMode&&(!s||!s.length))){var a=t.push(s);a||(n=!0,e.pause())}});for(var i in e)this[i]===void 0&&typeof e[i]=="function"&&(this[i]=(function(a){return function(){return e[a].apply(e,arguments)}})(i));for(var o=0;o<vM.length;o++)e.on(vM[o],this.emit.bind(this,vM[o]));return this._read=function(s){nt("wrapped _read",s),n&&(n=!1,e.resume())},this};typeof Symbol=="function"&&(Et.prototype[Symbol.asyncIterator]=function(){return wM===void 0&&(wM=Dse()),wM(this)});Object.defineProperty(Et.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}});Object.defineProperty(Et.prototype,"readableBuffer",{enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}});Object.defineProperty(Et.prototype,"readableFlowing",{enumerable:!1,get:function(){return this._readableState.flowing},set:function(t){this._readableState&&(this._readableState.flowing=t)}});Et._fromList=Gse;Object.defineProperty(Et.prototype,"readableLength",{enumerable:!1,get:function(){return this._readableState.length}});function Gse(e,t){if(t.length===0)return null;var r;return t.objectMode?r=t.buffer.shift():!e||e>=t.length?(t.decoder?r=t.buffer.join(""):t.buffer.length===1?r=t.buffer.first():r=t.buffer.concat(t.length),t.buffer.clear()):r=t.buffer.consume(e,t.decoder),r}function xM(e){var t=e._readableState;nt("endReadable",t.endEmitted),t.endEmitted||(t.ended=!0,process.nextTick(Qrt,t,e))}function Qrt(e,t){if(nt("endReadableNT",e.endEmitted,e.length),!e.endEmitted&&e.length===0&&(e.endEmitted=!0,t.readable=!1,t.emit("end"),e.autoDestroy)){var r=t._writableState;(!r||r.autoDestroy&&r.finished)&&t.destroy()}}typeof Symbol=="function"&&(Et.from=function(e,t){return SM===void 0&&(SM=Lse()),SM(Et,e,t)});function zse(e,t){for(var r=0,n=e.length;r<n;r++)if(e[r]===t)return r;return-1}});var PM=E((TCt,Kse)=>{"use strict";Kse.exports=Xs;var YC=Sc().codes,Zrt=YC.ERR_METHOD_NOT_IMPLEMENTED,ent=YC.ERR_MULTIPLE_CALLBACK,tnt=YC.ERR_TRANSFORM_ALREADY_TRANSFORMING,rnt=YC.ERR_TRANSFORM_WITH_LENGTH_0,XC=Ju();ri()(Xs,XC);function nnt(e,t){var r=this._transformState;r.transforming=!1;var n=r.writecb;if(n===null)return this.emit("error",new ent);r.writechunk=null,r.writecb=null,t!=null&&this.push(t),n(e);var i=this._readableState;i.reading=!1,(i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}function Xs(e){if(!(this instanceof Xs))return new Xs(e);XC.call(this,e),this._transformState={afterTransform:nnt.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,e&&(typeof e.transform=="function"&&(this._transform=e.transform),typeof e.flush=="function"&&(this._flush=e.flush)),this.on("prefinish",int)}function int(){var e=this;typeof this._flush=="function"&&!this._readableState.destroyed?this._flush(function(t,r){Wse(e,t,r)}):Wse(this,null,null)}Xs.prototype.push=function(e,t){return this._transformState.needTransform=!1,XC.prototype.push.call(this,e,t)};Xs.prototype._transform=function(e,t,r){r(new Zrt("_transform()"))};Xs.prototype._write=function(e,t,r){var n=this._transformState;if(n.writecb=r,n.writechunk=e,n.writeencoding=t,!n.transforming){var i=this._readableState;(n.needTransform||i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}};Xs.prototype._read=function(e){var t=this._transformState;t.writechunk!==null&&!t.transforming?(t.transforming=!0,this._transform(t.writechunk,t.writeencoding,t.afterTransform)):t.needTransform=!0};Xs.prototype._destroy=function(e,t){XC.prototype._destroy.call(this,e,function(r){t(r)})};function Wse(e,t,r){if(t)return e.emit("error",t);if(r!=null&&e.push(r),e._writableState.length)throw new rnt;if(e._transformState.transforming)throw new tnt;return e.push(null)}});var Jse=E((ACt,Xse)=>{"use strict";Xse.exports=Sg;var Yse=PM();ri()(Sg,Yse);function Sg(e){if(!(this instanceof Sg))return new Sg(e);Yse.call(this,e)}Sg.prototype._transform=function(e,t,r){r(null,e)}});var rae=E((RCt,tae)=>{"use strict";var OM;function ont(e){var t=!1;return function(){t||(t=!0,e.apply(void 0,arguments))}}var eae=Sc().codes,snt=eae.ERR_MISSING_ARGS,ant=eae.ERR_STREAM_DESTROYED;function Qse(e){if(e)throw e}function cnt(e){return e.setHeader&&typeof e.abort=="function"}function unt(e,t,r,n){n=ont(n);var i=!1;e.on("close",function(){i=!0}),OM===void 0&&(OM=$C()),OM(e,{readable:t,writable:r},function(s){if(s)return n(s);i=!0,n()});var o=!1;return function(s){if(!i&&!o){if(o=!0,cnt(e))return e.abort();if(typeof e.destroy=="function")return e.destroy();n(s||new ant("pipe"))}}}function Zse(e){e()}function lnt(e,t){return e.pipe(t)}function fnt(e){return!e.length||typeof e[e.length-1]!="function"?Qse:e.pop()}function dnt(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];var n=fnt(t);if(Array.isArray(t[0])&&(t=t[0]),t.length<2)throw new snt("streams");var i,o=t.map(function(s,a){var c=a<t.length-1,u=a>0;return unt(s,c,u,function(l){i||(i=l),l&&o.forEach(Zse),!c&&(o.forEach(Zse),n(i))})});return t.reduce(lnt)}tae.exports=dnt});var tl=E((Ji,Cg)=>{"use strict";var vg=require("stream");process.env.READABLE_STREAM==="disable"&&vg?(Cg.exports=vg.Readable,Object.assign(Cg.exports,vg),Cg.exports.Stream=vg):(Ji=Cg.exports=_M(),Ji.Stream=vg||Ji,Ji.Readable=Ji,Ji.Writable=mM(),Ji.Duplex=Ju(),Ji.Transform=PM(),Ji.PassThrough=Jse(),Ji.finished=$C(),Ji.pipeline=rae())});var BM=E((PCt,iae)=>{"use strict";var qd=[],xg=[],IM=function(){};function kM(e){return~qd.indexOf(e)?!1:(qd.push(e),!0)}function NM(e){IM=e}function pnt(e){for(var t=[],r=0;r<qd.length;r++){if(qd[r].async){t.push(qd[r]);continue}if(qd[r](e))return!0}return t.length?new Promise(function(i){Promise.all(t.map(function(s){return s(e)})).then(function(s){i(s.some(Boolean))})}):!1}function MM(e){return~xg.indexOf(e)?!1:(xg.push(e),!0)}function DM(){IM.apply(IM,arguments)}function nae(e){for(var t=0;t<xg.length;t++)e=xg[t].apply(xg[t],arguments);return e}function LM(e,t){var r=Object.prototype.hasOwnProperty;for(var n in t)r.call(t,n)&&(e[n]=t[n]);return e}function hnt(e){return e.enabled=!1,e.modify=MM,e.set=NM,e.use=kM,LM(function(){return!1},e)}function mnt(e){function t(){var r=Array.prototype.slice.call(arguments,0);return DM.call(DM,e,nae(r,e)),!0}return e.enabled=!0,e.modify=MM,e.set=NM,e.use=kM,LM(t,e)}iae.exports=function(t){return t.introduce=LM,t.enabled=pnt,t.process=nae,t.modify=MM,t.write=DM,t.nope=hnt,t.yep=mnt,t.set=NM,t.use=kM,t}});var sae=E((OCt,oae)=>{"use strict";var gnt=BM(),ynt=gnt(function e(t,r){return r=r||{},r.namespace=t,r.prod=!0,r.dev=!1,r.force||e.force?e.yep(r):e.nope(r)});oae.exports=ynt});var dae=E((ICt,fae)=>{"use strict";var cs={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]},cae=Object.create(null);for(let e in cs)Object.hasOwn(cs,e)&&(cae[cs[e]]=e);var jr={to:{},get:{}};jr.get=function(e){let t=e.slice(0,3).toLowerCase(),r,n;switch(t){case"hsl":{r=jr.get.hsl(e),n="hsl";break}case"hwb":{r=jr.get.hwb(e),n="hwb";break}default:{r=jr.get.rgb(e),n="rgb";break}}return r?{model:n,value:r}:null};jr.get.rgb=function(e){if(!e)return null;let t=/^#([a-f\d]{3,4})$/i,r=/^#([a-f\d]{6})([a-f\d]{2})?$/i,n=/^rgba?\(\s*([+-]?\d+)(?=[\s,])\s*(?:,\s*)?([+-]?\d+)(?=[\s,])\s*(?:,\s*)?([+-]?\d+)\s*(?:[\s,|/]\s*([+-]?[\d.]+)(%?)\s*)?\)$/,i=/^rgba?\(\s*([+-]?[\d.]+)%\s*,?\s*([+-]?[\d.]+)%\s*,?\s*([+-]?[\d.]+)%\s*(?:[\s,|/]\s*([+-]?[\d.]+)(%?)\s*)?\)$/,o=/^(\w+)$/,s=[0,0,0,1],a,c,u;if(a=e.match(r)){for(u=a[2],a=a[1],c=0;c<3;c++){let l=c*2;s[c]=Number.parseInt(a.slice(l,l+2),16)}u&&(s[3]=Number.parseInt(u,16)/255)}else if(a=e.match(t)){for(a=a[1],u=a[3],c=0;c<3;c++)s[c]=Number.parseInt(a[c]+a[c],16);u&&(s[3]=Number.parseInt(u+u,16)/255)}else if(a=e.match(n)){for(c=0;c<3;c++)s[c]=Number.parseInt(a[c+1],10);a[4]&&(s[3]=a[5]?Number.parseFloat(a[4])*.01:Number.parseFloat(a[4]))}else if(a=e.match(i)){for(c=0;c<3;c++)s[c]=Math.round(Number.parseFloat(a[c+1])*2.55);a[4]&&(s[3]=a[5]?Number.parseFloat(a[4])*.01:Number.parseFloat(a[4]))}else return(a=e.match(o))?a[1]==="transparent"?[0,0,0,0]:Object.hasOwn(cs,a[1])?(s=cs[a[1]],s[3]=1,s):null:null;for(c=0;c<3;c++)s[c]=Ac(s[c],0,255);return s[3]=Ac(s[3],0,1),s};jr.get.hsl=function(e){if(!e)return null;let t=/^hsla?\(\s*([+-]?(?:\d{0,3}\.)?\d+)(?:deg)?\s*,?\s*([+-]?[\d.]+)%\s*,?\s*([+-]?[\d.]+)%\s*(?:[,|/]\s*([+-]?(?=\.\d|\d)(?:0|[1-9]\d*)?(?:\.\d*)?(?:[eE][+-]?\d+)?)\s*)?\)$/,r=e.match(t);if(r){let n=Number.parseFloat(r[4]),i=(Number.parseFloat(r[1])%360+360)%360,o=Ac(Number.parseFloat(r[2]),0,100),s=Ac(Number.parseFloat(r[3]),0,100),a=Ac(Number.isNaN(n)?1:n,0,1);return[i,o,s,a]}return null};jr.get.hwb=function(e){if(!e)return null;let t=/^hwb\(\s*([+-]?\d{0,3}(?:\.\d+)?)(?:deg)?\s*[\s,]\s*([+-]?[\d.]+)%\s*[\s,]\s*([+-]?[\d.]+)%\s*(?:[\s,]\s*([+-]?(?=\.\d|\d)(?:0|[1-9]\d*)?(?:\.\d*)?(?:[eE][+-]?\d+)?)\s*)?\)$/,r=e.match(t);if(r){let n=Number.parseFloat(r[4]),i=(Number.parseFloat(r[1])%360+360)%360,o=Ac(Number.parseFloat(r[2]),0,100),s=Ac(Number.parseFloat(r[3]),0,100),a=Ac(Number.isNaN(n)?1:n,0,1);return[i,o,s,a]}return null};jr.to.hex=function(...e){return"#"+JC(e[0])+JC(e[1])+JC(e[2])+(e[3]<1?JC(Math.round(e[3]*255)):"")};jr.to.rgb=function(...e){return e.length<4||e[3]===1?"rgb("+Math.round(e[0])+", "+Math.round(e[1])+", "+Math.round(e[2])+")":"rgba("+Math.round(e[0])+", "+Math.round(e[1])+", "+Math.round(e[2])+", "+e[3]+")"};jr.to.rgb.percent=function(...e){let t=Math.round(e[0]/255*100),r=Math.round(e[1]/255*100),n=Math.round(e[2]/255*100);return e.length<4||e[3]===1?"rgb("+t+"%, "+r+"%, "+n+"%)":"rgba("+t+"%, "+r+"%, "+n+"%, "+e[3]+")"};jr.to.hsl=function(...e){return e.length<4||e[3]===1?"hsl("+e[0]+", "+e[1]+"%, "+e[2]+"%)":"hsla("+e[0]+", "+e[1]+"%, "+e[2]+"%, "+e[3]+")"};jr.to.hwb=function(...e){let t="";return e.length>=4&&e[3]!==1&&(t=", "+e[3]),"hwb("+e[0]+", "+e[1]+"%, "+e[2]+"%"+t+")"};jr.to.keyword=function(...e){return cae[e.slice(0,3)]};function Ac(e,t,r){return Math.min(Math.max(t,e),r)}function JC(e){let t=Math.round(e).toString(16).toUpperCase();return t.length<2?"0"+t:t}var uae={};for(let e of Object.keys(cs))uae[cs[e]]=e;var Pe={rgb:{channels:3,labels:"rgb"},hsl:{channels:3,labels:"hsl"},hsv:{channels:3,labels:"hsv"},hwb:{channels:3,labels:"hwb"},cmyk:{channels:4,labels:"cmyk"},xyz:{channels:3,labels:"xyz"},lab:{channels:3,labels:"lab"},oklab:{channels:3,labels:["okl","oka","okb"]},lch:{channels:3,labels:"lch"},oklch:{channels:3,labels:["okl","okc","okh"]},hex:{channels:1,labels:["hex"]},keyword:{channels:1,labels:["keyword"]},ansi16:{channels:1,labels:["ansi16"]},ansi256:{channels:1,labels:["ansi256"]},hcg:{channels:3,labels:["h","c","g"]},apple:{channels:3,labels:["r16","g16","b16"]},gray:{channels:1,labels:["gray"]}},Js=(6/29)**3;function jd(e){let t=e>.0031308?1.055*e**.4166666666666667-.055:e*12.92;return Math.min(Math.max(0,t),1)}function Ud(e){return e>.04045?((e+.055)/1.055)**2.4:e/12.92}for(let e of Object.keys(Pe)){if(!("channels"in Pe[e]))throw new Error("missing channels property: "+e);if(!("labels"in Pe[e]))throw new Error("missing channel labels property: "+e);if(Pe[e].labels.length!==Pe[e].channels)throw new Error("channel and label counts mismatch: "+e);let{channels:t,labels:r}=Pe[e];delete Pe[e].channels,delete Pe[e].labels,Object.defineProperty(Pe[e],"channels",{value:t}),Object.defineProperty(Pe[e],"labels",{value:r})}Pe.rgb.hsl=function(e){let t=e[0]/255,r=e[1]/255,n=e[2]/255,i=Math.min(t,r,n),o=Math.max(t,r,n),s=o-i,a,c;switch(o){case i:{a=0;break}case t:{a=(r-n)/s;break}case r:{a=2+(n-t)/s;break}case n:{a=4+(t-r)/s;break}}a=Math.min(a*60,360),a<0&&(a+=360);let u=(i+o)/2;return o===i?c=0:u<=.5?c=s/(o+i):c=s/(2-o-i),[a,c*100,u*100]};Pe.rgb.hsv=function(e){let t,r,n,i,o,s=e[0]/255,a=e[1]/255,c=e[2]/255,u=Math.max(s,a,c),l=u-Math.min(s,a,c),d=function(h){return(u-h)/6/l+1/2};if(l===0)i=0,o=0;else{switch(o=l/u,t=d(s),r=d(a),n=d(c),u){case s:{i=n-r;break}case a:{i=1/3+t-n;break}case c:{i=2/3+r-t;break}}i<0?i+=1:i>1&&(i-=1)}return[i*360,o*100,u*100]};Pe.rgb.hwb=function(e){let t=e[0],r=e[1],n=e[2],i=Pe.rgb.hsl(e)[0],o=1/255*Math.min(t,Math.min(r,n));return n=1-1/255*Math.max(t,Math.max(r,n)),[i,o*100,n*100]};Pe.rgb.oklab=function(e){let t=Ud(e[0]/255),r=Ud(e[1]/255),n=Ud(e[2]/255),i=Math.cbrt(.4122214708*t+.5363325363*r+.0514459929*n),o=Math.cbrt(.2119034982*t+.6806995451*r+.1073969566*n),s=Math.cbrt(.0883024619*t+.2817188376*r+.6299787005*n),a=.2104542553*i+.793617785*o-.0040720468*s,c=1.9779984951*i-2.428592205*o+.4505937099*s,u=.0259040371*i+.7827717662*o-.808675766*s;return[a*100,c*100,u*100]};Pe.rgb.cmyk=function(e){let t=e[0]/255,r=e[1]/255,n=e[2]/255,i=Math.min(1-t,1-r,1-n),o=(1-t-i)/(1-i)||0,s=(1-r-i)/(1-i)||0,a=(1-n-i)/(1-i)||0;return[o*100,s*100,a*100,i*100]};function _nt(e,t){return(e[0]-t[0])**2+(e[1]-t[1])**2+(e[2]-t[2])**2}Pe.rgb.keyword=function(e){let t=uae[e];if(t)return t;let r=Number.POSITIVE_INFINITY,n;for(let i of Object.keys(cs)){let o=cs[i],s=_nt(e,o);s<r&&(r=s,n=i)}return n};Pe.keyword.rgb=function(e){return cs[e]};Pe.rgb.xyz=function(e){let t=Ud(e[0]/255),r=Ud(e[1]/255),n=Ud(e[2]/255),i=t*.4124564+r*.3575761+n*.1804375,o=t*.2126729+r*.7151522+n*.072175,s=t*.0193339+r*.119192+n*.9503041;return[i*100,o*100,s*100]};Pe.rgb.lab=function(e){let t=Pe.rgb.xyz(e),r=t[0],n=t[1],i=t[2];r/=95.047,n/=100,i/=108.883,r=r>Js?r**(1/3):7.787*r+16/116,n=n>Js?n**(1/3):7.787*n+16/116,i=i>Js?i**(1/3):7.787*i+16/116;let o=116*n-16,s=500*(r-n),a=200*(n-i);return[o,s,a]};Pe.hsl.rgb=function(e){let t=e[0]/360,r=e[1]/100,n=e[2]/100,i,o;if(r===0)return o=n*255,[o,o,o];let s=n<.5?n*(1+r):n+r-n*r,a=2*n-s,c=[0,0,0];for(let u=0;u<3;u++)i=t+1/3*-(u-1),i<0&&i++,i>1&&i--,6*i<1?o=a+(s-a)*6*i:2*i<1?o=s:3*i<2?o=a+(s-a)*(2/3-i)*6:o=a,c[u]=o*255;return c};Pe.hsl.hsv=function(e){let t=e[0],r=e[1]/100,n=e[2]/100,i=r,o=Math.max(n,.01);n*=2,r*=n<=1?n:2-n,i*=o<=1?o:2-o;let s=(n+r)/2,a=n===0?2*i/(o+i):2*r/(n+r);return[t,a*100,s*100]};Pe.hsv.rgb=function(e){let t=e[0]/60,r=e[1]/100,n=e[2]/100,i=Math.floor(t)%6,o=t-Math.floor(t),s=255*n*(1-r),a=255*n*(1-r*o),c=255*n*(1-r*(1-o));switch(n*=255,i){case 0:return[n,c,s];case 1:return[a,n,s];case 2:return[s,n,c];case 3:return[s,a,n];case 4:return[c,s,n];case 5:return[n,s,a]}};Pe.hsv.hsl=function(e){let t=e[0],r=e[1]/100,n=e[2]/100,i=Math.max(n,.01),o,s;s=(2-r)*n;let a=(2-r)*i;return o=r*i,o/=a<=1?a:2-a,o=o||0,s/=2,[t,o*100,s*100]};Pe.hwb.rgb=function(e){let t=e[0]/360,r=e[1]/100,n=e[2]/100,i=r+n,o;i>1&&(r/=i,n/=i);let s=Math.floor(6*t),a=1-n;o=6*t-s,(s&1)!==0&&(o=1-o);let c=r+o*(a-r),u,l,d;switch(s){default:case 6:case 0:{u=a,l=c,d=r;break}case 1:{u=c,l=a,d=r;break}case 2:{u=r,l=a,d=c;break}case 3:{u=r,l=c,d=a;break}case 4:{u=c,l=r,d=a;break}case 5:{u=a,l=r,d=c;break}}return[u*255,l*255,d*255]};Pe.cmyk.rgb=function(e){let t=e[0]/100,r=e[1]/100,n=e[2]/100,i=e[3]/100,o=1-Math.min(1,t*(1-i)+i),s=1-Math.min(1,r*(1-i)+i),a=1-Math.min(1,n*(1-i)+i);return[o*255,s*255,a*255]};Pe.xyz.rgb=function(e){let t=e[0]/100,r=e[1]/100,n=e[2]/100,i,o,s;return i=t*3.2404542+r*-1.5371385+n*-.4985314,o=t*-.969266+r*1.8760108+n*.041556,s=t*.0556434+r*-.2040259+n*1.0572252,i=jd(i),o=jd(o),s=jd(s),[i*255,o*255,s*255]};Pe.xyz.lab=function(e){let t=e[0],r=e[1],n=e[2];t/=95.047,r/=100,n/=108.883,t=t>Js?t**(1/3):7.787*t+16/116,r=r>Js?r**(1/3):7.787*r+16/116,n=n>Js?n**(1/3):7.787*n+16/116;let i=116*r-16,o=500*(t-r),s=200*(r-n);return[i,o,s]};Pe.xyz.oklab=function(e){let t=e[0]/100,r=e[1]/100,n=e[2]/100,i=Math.cbrt(.8189330101*t+.3618667424*r-.1288597137*n),o=Math.cbrt(.0329845436*t+.9293118715*r+.0361456387*n),s=Math.cbrt(.0482003018*t+.2643662691*r+.633851707*n),a=.2104542553*i+.793617785*o-.0040720468*s,c=1.9779984951*i-2.428592205*o+.4505937099*s,u=.0259040371*i+.7827717662*o-.808675766*s;return[a*100,c*100,u*100]};Pe.oklab.oklch=function(e){return Pe.lab.lch(e)};Pe.oklab.xyz=function(e){let t=e[0]/100,r=e[1]/100,n=e[2]/100,i=(.999999998*t+.396337792*r+.215803758*n)**3,o=(1.000000008*t-.105561342*r-.063854175*n)**3,s=(1.000000055*t-.089484182*r-1.291485538*n)**3,a=1.227013851*i-.55779998*o+.281256149*s,c=-.040580178*i+1.11225687*o-.071676679*s,u=-.076381285*i-.421481978*o+1.58616322*s;return[a*100,c*100,u*100]};Pe.oklab.rgb=function(e){let t=e[0]/100,r=e[1]/100,n=e[2]/100,i=(t+.3963377774*r+.2158037573*n)**3,o=(t-.1055613458*r-.0638541728*n)**3,s=(t-.0894841775*r-1.291485548*n)**3,a=jd(4.0767416621*i-3.3077115913*o+.2309699292*s),c=jd(-1.2684380046*i+2.6097574011*o-.3413193965*s),u=jd(-.0041960863*i-.7034186147*o+1.707614701*s);return[a*255,c*255,u*255]};Pe.oklch.oklab=function(e){return Pe.lch.lab(e)};Pe.lab.xyz=function(e){let t=e[0],r=e[1],n=e[2],i,o,s;o=(t+16)/116,i=r/500+o,s=o-n/200;let a=o**3,c=i**3,u=s**3;return o=a>Js?a:(o-16/116)/7.787,i=c>Js?c:(i-16/116)/7.787,s=u>Js?u:(s-16/116)/7.787,i*=95.047,o*=100,s*=108.883,[i,o,s]};Pe.lab.lch=function(e){let t=e[0],r=e[1],n=e[2],i;i=Math.atan2(n,r)*360/2/Math.PI,i<0&&(i+=360);let s=Math.sqrt(r*r+n*n);return[t,s,i]};Pe.lch.lab=function(e){let t=e[0],r=e[1],i=e[2]/360*2*Math.PI,o=r*Math.cos(i),s=r*Math.sin(i);return[t,o,s]};Pe.rgb.ansi16=function(e,t=null){let[r,n,i]=e,o=t===null?Pe.rgb.hsv(e)[2]:t;if(o=Math.round(o/50),o===0)return 30;let s=30+(Math.round(i/255)<<2|Math.round(n/255)<<1|Math.round(r/255));return o===2&&(s+=60),s};Pe.hsv.ansi16=function(e){return Pe.rgb.ansi16(Pe.hsv.rgb(e),e[2])};Pe.rgb.ansi256=function(e){let t=e[0],r=e[1],n=e[2];return t>>4===r>>4&&r>>4===n>>4?t<8?16:t>248?231:Math.round((t-8)/247*24)+232:16+36*Math.round(t/255*5)+6*Math.round(r/255*5)+Math.round(n/255*5)};Pe.ansi16.rgb=function(e){e=e[0];let t=e%10;if(t===0||t===7)return e>50&&(t+=3.5),t=t/10.5*255,[t,t,t];let r=(Math.trunc(e>50)+1)*.5,n=(t&1)*r*255,i=(t>>1&1)*r*255,o=(t>>2&1)*r*255;return[n,i,o]};Pe.ansi256.rgb=function(e){if(e=e[0],e>=232){let o=(e-232)*10+8;return[o,o,o]}e-=16;let t,r=Math.floor(e/36)/5*255,n=Math.floor((t=e%36)/6)/5*255,i=t%6/5*255;return[r,n,i]};Pe.rgb.hex=function(e){let r=(((Math.round(e[0])&255)<<16)+((Math.round(e[1])&255)<<8)+(Math.round(e[2])&255)).toString(16).toUpperCase();return"000000".slice(r.length)+r};Pe.hex.rgb=function(e){let t=e.toString(16).match(/[a-f\d]{6}|[a-f\d]{3}/i);if(!t)return[0,0,0];let r=t[0];t[0].length===3&&(r=[...r].map(a=>a+a).join(""));let n=Number.parseInt(r,16),i=n>>16&255,o=n>>8&255,s=n&255;return[i,o,s]};Pe.rgb.hcg=function(e){let t=e[0]/255,r=e[1]/255,n=e[2]/255,i=Math.max(Math.max(t,r),n),o=Math.min(Math.min(t,r),n),s=i-o,a,c=s<1?o/(1-s):0;return s<=0?a=0:i===t?a=(r-n)/s%6:i===r?a=2+(n-t)/s:a=4+(t-r)/s,a/=6,a%=1,[a*360,s*100,c*100]};Pe.hsl.hcg=function(e){let t=e[1]/100,r=e[2]/100,n=r<.5?2*t*r:2*t*(1-r),i=0;return n<1&&(i=(r-.5*n)/(1-n)),[e[0],n*100,i*100]};Pe.hsv.hcg=function(e){let t=e[1]/100,r=e[2]/100,n=t*r,i=0;return n<1&&(i=(r-n)/(1-n)),[e[0],n*100,i*100]};Pe.hcg.rgb=function(e){let t=e[0]/360,r=e[1]/100,n=e[2]/100;if(r===0)return[n*255,n*255,n*255];let i=[0,0,0],o=t%1*6,s=o%1,a=1-s,c=0;switch(Math.floor(o)){case 0:{i[0]=1,i[1]=s,i[2]=0;break}case 1:{i[0]=a,i[1]=1,i[2]=0;break}case 2:{i[0]=0,i[1]=1,i[2]=s;break}case 3:{i[0]=0,i[1]=a,i[2]=1;break}case 4:{i[0]=s,i[1]=0,i[2]=1;break}default:i[0]=1,i[1]=0,i[2]=a}return c=(1-r)*n,[(r*i[0]+c)*255,(r*i[1]+c)*255,(r*i[2]+c)*255]};Pe.hcg.hsv=function(e){let t=e[1]/100,r=e[2]/100,n=t+r*(1-t),i=0;return n>0&&(i=t/n),[e[0],i*100,n*100]};Pe.hcg.hsl=function(e){let t=e[1]/100,n=e[2]/100*(1-t)+.5*t,i=0;return n>0&&n<.5?i=t/(2*n):n>=.5&&n<1&&(i=t/(2*(1-n))),[e[0],i*100,n*100]};Pe.hcg.hwb=function(e){let t=e[1]/100,r=e[2]/100,n=t+r*(1-t);return[e[0],(n-t)*100,(1-n)*100]};Pe.hwb.hcg=function(e){let t=e[1]/100,n=1-e[2]/100,i=n-t,o=0;return i<1&&(o=(n-i)/(1-i)),[e[0],i*100,o*100]};Pe.apple.rgb=function(e){return[e[0]/65535*255,e[1]/65535*255,e[2]/65535*255]};Pe.rgb.apple=function(e){return[e[0]/255*65535,e[1]/255*65535,e[2]/255*65535]};Pe.gray.rgb=function(e){return[e[0]/100*255,e[0]/100*255,e[0]/100*255]};Pe.gray.hsl=function(e){return[0,0,e[0]]};Pe.gray.hsv=Pe.gray.hsl;Pe.gray.hwb=function(e){return[0,100,e[0]]};Pe.gray.cmyk=function(e){return[0,0,0,e[0]]};Pe.gray.lab=function(e){return[e[0],0,0]};Pe.gray.hex=function(e){let t=Math.round(e[0]/100*255)&255,n=((t<<16)+(t<<8)+t).toString(16).toUpperCase();return"000000".slice(n.length)+n};Pe.rgb.gray=function(e){return[(e[0]+e[1]+e[2])/3/255*100]};function bnt(){let e={},t=Object.keys(Pe);for(let{length:r}=t,n=0;n<r;n++)e[t[n]]={distance:-1,parent:null};return e}function Ent(e){let t=bnt(),r=[e];for(t[e].distance=0;r.length>0;){let n=r.pop(),i=Object.keys(Pe[n]);for(let{length:o}=i,s=0;s<o;s++){let a=i[s],c=t[a];c.distance===-1&&(c.distance=t[n].distance+1,c.parent=n,r.unshift(a))}}return t}function wnt(e,t){return function(r){return t(e(r))}}function Snt(e,t){let r=[t[e].parent,e],n=Pe[t[e].parent][e],i=t[e].parent;for(;t[i].parent;)r.unshift(t[i].parent),n=wnt(Pe[t[i].parent][i],n),i=t[i].parent;return n.conversion=r,n}function vnt(e){let t=Ent(e),r={},n=Object.keys(t);for(let{length:i}=n,o=0;o<i;o++){let s=n[o];t[s].parent!==null&&(r[s]=Snt(s,t))}return r}var en={},Cnt=Object.keys(Pe);function xnt(e){let t=function(...r){let n=r[0];return n==null?n:(n.length>1&&(r=n),e(r))};return"conversion"in e&&(t.conversion=e.conversion),t}function Tnt(e){let t=function(...r){let n=r[0];if(n==null)return n;n.length>1&&(r=n);let i=e(r);if(typeof i=="object")for(let{length:o}=i,s=0;s<o;s++)i[s]=Math.round(i[s]);return i};return"conversion"in e&&(t.conversion=e.conversion),t}for(let e of Cnt){en[e]={},Object.defineProperty(en[e],"channels",{value:Pe[e].channels}),Object.defineProperty(en[e],"labels",{value:Pe[e].labels});let t=vnt(e),r=Object.keys(t);for(let n of r){let i=t[n];en[e][n]=Tnt(i),en[e][n].raw=xnt(i)}}var lae=["keyword","gray","hex"],FM={};for(let e of Object.keys(en))FM[[...en[e].labels].sort().join("")]=e;var qM={};function qr(e,t){if(!(this instanceof qr))return new qr(e,t);if(t&&t in lae&&(t=null),t&&!(t in en))throw new Error("Unknown model: "+t);let r,n;if(e==null)this.model="rgb",this.color=[0,0,0],this.valpha=1;else if(e instanceof qr)this.model=e.model,this.color=[...e.color],this.valpha=e.valpha;else if(typeof e=="string"){let i=jr.get(e);if(i===null)throw new Error("Unable to parse color from string: "+e);this.model=i.model,n=en[this.model].channels,this.color=i.value.slice(0,n),this.valpha=typeof i.value[n]=="number"?i.value[n]:1}else if(e.length>0){this.model=t||"rgb",n=en[this.model].channels;let i=Array.prototype.slice.call(e,0,n);this.color=jM(i,n),this.valpha=typeof e[n]=="number"?e[n]:1}else if(typeof e=="number")this.model="rgb",this.color=[e>>16&255,e>>8&255,e&255],this.valpha=1;else{this.valpha=1;let i=Object.keys(e);"alpha"in e&&(i.splice(i.indexOf("alpha"),1),this.valpha=typeof e.alpha=="number"?e.alpha:0);let o=i.sort().join("");if(!(o in FM))throw new Error("Unable to parse color from object: "+JSON.stringify(e));this.model=FM[o];let{labels:s}=en[this.model],a=[];for(r=0;r<s.length;r++)a.push(e[s[r]]);this.color=jM(a)}if(qM[this.model])for(n=en[this.model].channels,r=0;r<n;r++){let i=qM[this.model][r];i&&(this.color[r]=i(this.color[r]))}this.valpha=Math.max(0,Math.min(1,this.valpha)),Object.freeze&&Object.freeze(this)}qr.prototype={toString(){return this.string()},toJSON(){return this[this.model]()},string(e){let t=this.model in jr.to?this:this.rgb();t=t.round(typeof e=="number"?e:1);let r=t.valpha===1?t.color:[...t.color,this.valpha];return jr.to[t.model](...r)},percentString(e){let t=this.rgb().round(typeof e=="number"?e:1),r=t.valpha===1?t.color:[...t.color,this.valpha];return jr.to.rgb.percent(...r)},array(){return this.valpha===1?[...this.color]:[...this.color,this.valpha]},object(){let e={},{channels:t}=en[this.model],{labels:r}=en[this.model];for(let n=0;n<t;n++)e[r[n]]=this.color[n];return this.valpha!==1&&(e.alpha=this.valpha),e},unitArray(){let e=this.rgb().color;return e[0]/=255,e[1]/=255,e[2]/=255,this.valpha!==1&&e.push(this.valpha),e},unitObject(){let e=this.rgb().object();return e.r/=255,e.g/=255,e.b/=255,this.valpha!==1&&(e.alpha=this.valpha),e},round(e){return e=Math.max(e||0,0),new qr([...this.color.map(Rnt(e)),this.valpha],this.model)},alpha(e){return e!==void 0?new qr([...this.color,Math.max(0,Math.min(1,e))],this.model):this.valpha},red:mr("rgb",0,Fr(255)),green:mr("rgb",1,Fr(255)),blue:mr("rgb",2,Fr(255)),hue:mr(["hsl","hsv","hsl","hwb","hcg"],0,e=>(e%360+360)%360),saturationl:mr("hsl",1,Fr(100)),lightness:mr("hsl",2,Fr(100)),saturationv:mr("hsv",1,Fr(100)),value:mr("hsv",2,Fr(100)),chroma:mr("hcg",1,Fr(100)),gray:mr("hcg",2,Fr(100)),white:mr("hwb",1,Fr(100)),wblack:mr("hwb",2,Fr(100)),cyan:mr("cmyk",0,Fr(100)),magenta:mr("cmyk",1,Fr(100)),yellow:mr("cmyk",2,Fr(100)),black:mr("cmyk",3,Fr(100)),x:mr("xyz",0,Fr(95.047)),y:mr("xyz",1,Fr(100)),z:mr("xyz",2,Fr(108.833)),l:mr("lab",0,Fr(100)),a:mr("lab",1),b:mr("lab",2),keyword(e){return e!==void 0?new qr(e):en[this.model].keyword(this.color)},hex(e){return e!==void 0?new qr(e):jr.to.hex(...this.rgb().round().color)},hexa(e){if(e!==void 0)return new qr(e);let t=this.rgb().round().color,r=Math.round(this.valpha*255).toString(16).toUpperCase();return r.length===1&&(r="0"+r),jr.to.hex(...t)+r},rgbNumber(){let e=this.rgb().color;return(e[0]&255)<<16|(e[1]&255)<<8|e[2]&255},luminosity(){let e=this.rgb().color,t=[];for(let[r,n]of e.entries()){let i=n/255;t[r]=i<=.04045?i/12.92:((i+.055)/1.055)**2.4}return .2126*t[0]+.7152*t[1]+.0722*t[2]},contrast(e){let t=this.luminosity(),r=e.luminosity();return t>r?(t+.05)/(r+.05):(r+.05)/(t+.05)},level(e){let t=this.contrast(e);return t>=7?"AAA":t>=4.5?"AA":""},isDark(){let e=this.rgb().color;return(e[0]*2126+e[1]*7152+e[2]*722)/1e4<128},isLight(){return!this.isDark()},negate(){let e=this.rgb();for(let t=0;t<3;t++)e.color[t]=255-e.color[t];return e},lighten(e){let t=this.hsl();return t.color[2]+=t.color[2]*e,t},darken(e){let t=this.hsl();return t.color[2]-=t.color[2]*e,t},saturate(e){let t=this.hsl();return t.color[1]+=t.color[1]*e,t},desaturate(e){let t=this.hsl();return t.color[1]-=t.color[1]*e,t},whiten(e){let t=this.hwb();return t.color[1]+=t.color[1]*e,t},blacken(e){let t=this.hwb();return t.color[2]+=t.color[2]*e,t},grayscale(){let e=this.rgb().color,t=e[0]*.3+e[1]*.59+e[2]*.11;return qr.rgb(t,t,t)},fade(e){return this.alpha(this.valpha-this.valpha*e)},opaquer(e){return this.alpha(this.valpha+this.valpha*e)},rotate(e){let t=this.hsl(),r=t.color[0];return r=(r+e)%360,r=r<0?360+r:r,t.color[0]=r,t},mix(e,t){if(!e||!e.rgb)throw new Error('Argument to "mix" was not a Color instance, but rather an instance of '+typeof e);let r=e.rgb(),n=this.rgb(),i=t===void 0?.5:t,o=2*i-1,s=r.alpha()-n.alpha(),a=((o*s===-1?o:(o+s)/(1+o*s))+1)/2,c=1-a;return qr.rgb(a*r.red()+c*n.red(),a*r.green()+c*n.green(),a*r.blue()+c*n.blue(),r.alpha()*i+n.alpha()*(1-i))}};for(let e of Object.keys(en)){if(lae.includes(e))continue;let{channels:t}=en[e];qr.prototype[e]=function(...r){return this.model===e?new qr(this):r.length>0?new qr(r,e):new qr([...Pnt(en[this.model][e].raw(this.color)),this.valpha],e)},qr[e]=function(...r){let n=r[0];return typeof n=="number"&&(n=jM(r,t)),new qr(n,e)}}function Ant(e,t){return Number(e.toFixed(t))}function Rnt(e){return function(t){return Ant(t,e)}}function mr(e,t,r){e=Array.isArray(e)?e:[e];for(let n of e)(qM[n]||=[])[t]=r;return e=e[0],function(n){let i;return n!==void 0?(r&&(n=r(n)),i=this[e](),i.color[t]=n,i):(i=this[e]().color[t],r&&(i=r(i)),i)}}function Fr(e){return function(t){return Math.max(0,Math.min(e,t))}}function Pnt(e){return Array.isArray(e)?e:[e]}function jM(e,t){for(let r=0;r<t;r++)typeof e[r]!="number"&&(e[r]=0);return e}function Ont(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Int=function(t){for(var r=0,n=0;r<t.length;n=t.charCodeAt(r++)+((n<<5)-n));var i=Math.floor(Math.abs(Math.sin(n)*1e4%1*16777216)).toString(16);return"#"+Array(6-i.length+1).join("0")+i},aae=Ont(Int);function Dnt(e,t){let r=e.split(t||":"),n=aae(r[0]);if(!r.length)return n;for(let i=0,o=r.length-1;i<o;i++)n=qr(n).mix(qr(aae(r[i+1]))).saturate(1).hex();return n}fae.exports=Dnt});var hae=E((DCt,pae)=>{"use strict";function vo(e,t){if(t)return new vo(e).style(t);if(!(this instanceof vo))return new vo(e);this.text=e}vo.prototype.prefix="\x1B[";vo.prototype.suffix="m";vo.prototype.hex=function(t){t=t[0]==="#"?t.substring(1):t,t.length===3&&(t=t.split(""),t[5]=t[2],t[4]=t[2],t[3]=t[1],t[2]=t[1],t[1]=t[0],t=t.join(""));var r=t.substring(0,2),n=t.substring(2,4),i=t.substring(4,6);return[parseInt(r,16),parseInt(n,16),parseInt(i,16)]};vo.prototype.rgb=function(t,r,n){var i=t/255*5,o=r/255*5,s=n/255*5;return this.ansi(i,o,s)};vo.prototype.ansi=function(t,r,n){var i=Math.round(t),o=Math.round(r),s=Math.round(n);return 16+i*36+o*6+s};vo.prototype.reset=function(){return this.prefix+"39;49"+this.suffix};vo.prototype.style=function(t){return this.prefix+"38;5;"+this.rgb.apply(this,this.hex(t))+this.suffix+this.text+this.reset()};pae.exports=vo});var gae=E((kCt,mae)=>{"use strict";var knt=dae(),Nnt=hae();mae.exports=function(t,r){var n=r.namespace,i=r.colors!==!1?Nnt(n+":",knt(n)):n+":";return t[0]=i+" "+t[0],t}});var _ae=E((NCt,yae)=>{"use strict";yae.exports=function(t,r){if(!r)return!1;for(var n=r.split(/[\s,]+/),i=0;i<n.length;i++){if(r=n[i].replace("*",".*?"),r.charAt(0)==="-"){if(new RegExp("^"+r.substr(1)+"$").test(t))return!1;continue}if(new RegExp("^"+r+"$").test(t))return!0}return!1}});var Eae=E((MCt,bae)=>{"use strict";var Mnt=_ae();bae.exports=function(t){return function(n){try{return Mnt(n,t())}catch{}return!1}}});var Sae=E((LCt,wae)=>{"use strict";var Lnt=Eae();wae.exports=Lnt(function(){return process.env.DEBUG||process.env.DIAGNOSTICS})});var Cae=E((BCt,vae)=>{"use strict";vae.exports=function(e,t){try{Function.prototype.apply.call(console.log,console,t)}catch{}}});var Tae=E((FCt,xae)=>{"use strict";var Bnt=BM(),Fnt=require("tty").isatty(1),QC=Bnt(function e(t,r){return r=r||{},r.colors="colors"in r?r.colors:Fnt,r.namespace=t,r.prod=!1,r.dev=!0,!e.enabled(t)&&!(r.force||e.force)?e.nope(r):e.yep(r)});QC.modify(gae());QC.use(Sae());QC.set(Cae());xae.exports=QC});var Tg=E((qCt,UM)=>{"use strict";process.env.NODE_ENV==="production"?UM.exports=sae():UM.exports=Tae()});var Rae=E((jCt,Aae)=>{"use strict";var HM=require("fs"),{StringDecoder:qnt}=require("string_decoder"),{Stream:jnt}=tl();function Unt(){}Aae.exports=(e,t)=>{let r=Buffer.alloc(65536),n=new qnt("utf8"),i=new jnt,o="",s=0,a=0;return e.start===-1&&delete e.start,i.readable=!0,i.destroy=()=>{i.destroyed=!0,i.emit("end"),i.emit("close")},HM.open(e.file,"a+","0644",(c,u)=>{if(c){t?t(c):i.emit("error",c),i.destroy();return}(function l(){if(i.destroyed){HM.close(u,Unt);return}return HM.read(u,r,0,r.length,s,(d,h)=>{if(d){t?t(d):i.emit("error",d),i.destroy();return}if(!h)return o&&((e.start==null||a>e.start)&&(t?t(null,o):i.emit("line",o)),a++,o=""),setTimeout(l,1e3);let f=n.write(r.slice(0,h));t||i.emit("data",f),f=(o+f).split(/\n+/);let p=f.length-1,m=0;for(;m<p;m++)(e.start==null||a>e.start)&&(t?t(null,f[m]):i.emit("line",f[m])),a++;return o=f[p],s+=h,l()})})()}),t?i.destroy:i}});var Dae=E((HCt,Iae)=>{"use strict";var mi=require("fs"),tn=require("path"),Pae=sse(),Hnt=require("zlib"),{MESSAGE:$nt}=Pr(),{Stream:Gnt,PassThrough:Oae}=tl(),znt=Dd(),Co=Tg()("winston:file"),Vnt=require("os"),Wnt=Rae();Iae.exports=class extends znt{constructor(t={}){super(t),this.name=t.name||"file";function r(n,...i){i.slice(1).forEach(o=>{if(t[o])throw new Error(`Cannot set ${o} and ${n} together`)})}if(this._stream=new Oae,this._stream.setMaxListeners(30),this._onError=this._onError.bind(this),t.filename||t.dirname)r("filename or dirname","stream"),this._basename=this.filename=t.filename?tn.basename(t.filename):"winston.log",this.dirname=t.dirname||tn.dirname(t.filename),this.options=t.options||{flags:"a"};else if(t.stream)console.warn("options.stream will be removed in winston@4. Use winston.transports.Stream"),r("stream","filename","maxsize"),this._dest=this._stream.pipe(this._setupStream(t.stream)),this.dirname=tn.dirname(this._dest.path);else throw new Error("Cannot log to file without filename or stream.");this.maxsize=t.maxsize||null,this.rotationFormat=t.rotationFormat||!1,this.zippedArchive=t.zippedArchive||!1,this.maxFiles=t.maxFiles||null,this.eol=typeof t.eol=="string"?t.eol:Vnt.EOL,this.tailable=t.tailable||!1,this.lazy=t.lazy||!1,this._size=0,this._pendingSize=0,this._created=0,this._drain=!1,this._opening=!1,this._ending=!1,this._fileExist=!1,this.dirname&&this._createLogDirIfNotExist(this.dirname),this.lazy||this.open()}finishIfEnding(){this._ending&&(this._opening?this.once("open",()=>{this._stream.once("finish",()=>this.emit("finish")),setImmediate(()=>this._stream.end())}):(this._stream.once("finish",()=>this.emit("finish")),setImmediate(()=>this._stream.end())))}log(t,r=()=>{}){if(this.silent)return r(),!0;if(this._drain){this._stream.once("drain",()=>{this._drain=!1,this.log(t,r)});return}if(this._rotate){this._stream.once("rotate",()=>{this._rotate=!1,this.log(t,r)});return}if(this.lazy){if(!this._fileExist){this._opening||this.open(),this.once("open",()=>{this._fileExist=!0,this.log(t,r)});return}if(this._needsNewFile(this._pendingSize)){this._dest.once("close",()=>{this._opening||this.open(),this.once("open",()=>{this.log(t,r)})});return}}let n=`${t[$nt]}${this.eol}`,i=Buffer.byteLength(n);function o(){if(this._size+=i,this._pendingSize-=i,Co("logged %s %s",this._size,n),this.emit("logged",t),!this._rotate&&!this._opening&&this._needsNewFile()){if(this.lazy){this._endStream(()=>{this.emit("fileclosed")});return}this._rotate=!0,this._endStream(()=>this._rotateFile())}}this._pendingSize+=i,this._opening&&!this.rotatedWhileOpening&&this._needsNewFile(this._size+this._pendingSize)&&(this.rotatedWhileOpening=!0);let s=this._stream.write(n,o.bind(this));return s?r():(this._drain=!0,this._stream.once("drain",()=>{this._drain=!1,r()})),Co("written",s,this._drain),this.finishIfEnding(),s}query(t,r){typeof t=="function"&&(r=t,t={}),t=d(t);let n=tn.join(this.dirname,this.filename),i="",o=[],s=0,a=mi.createReadStream(n,{encoding:"utf8"});a.on("error",h=>{if(a.readable&&a.destroy(),!!r)return h.code!=="ENOENT"?r(h):r(null,o)}),a.on("data",h=>{h=(i+h).split(/\n+/);let f=h.length-1,p=0;for(;p<f;p++)(!t.start||s>=t.start)&&c(h[p]),s++;i=h[f]}),a.on("close",()=>{i&&c(i,!0),t.order==="desc"&&(o=o.reverse()),r&&r(null,o)});function c(h,f){try{let p=JSON.parse(h);l(p)&&u(p)}catch(p){f||a.emit("error",p)}}function u(h){if(t.rows&&o.length>=t.rows&&t.order!=="desc"){a.readable&&a.destroy();return}t.fields&&(h=t.fields.reduce((f,p)=>(f[p]=h[p],f),{})),t.order==="desc"&&o.length>=t.rows&&o.shift(),o.push(h)}function l(h){if(!h||typeof h!="object")return;let f=new Date(h.timestamp);if(!(t.from&&f<t.from||t.until&&f>t.until||t.level&&t.level!==h.level))return!0}function d(h){return h=h||{},h.rows=h.rows||h.limit||10,h.start=h.start||0,h.until=h.until||new Date,typeof h.until!="object"&&(h.until=new Date(h.until)),h.from=h.from||h.until-1440*60*1e3,typeof h.from!="object"&&(h.from=new Date(h.from)),h.order=h.order||"desc",h}}stream(t={}){let r=tn.join(this.dirname,this.filename),n=new Gnt,i={file:r,start:t.start};return n.destroy=Wnt(i,(o,s)=>{if(o)return n.emit("error",o);try{n.emit("data",s),s=JSON.parse(s),n.emit("log",s)}catch(a){n.emit("error",a)}}),n}open(){this.filename&&(this._opening||(this._opening=!0,this.stat((t,r)=>{if(t)return this.emit("error",t);Co("stat done: %s { size: %s }",this.filename,r),this._size=r,this._dest=this._createStream(this._stream),this._opening=!1,this.once("open",()=>{this._stream.emit("rotate")||(this._rotate=!1)})})))}stat(t){let r=this._getFile(),n=tn.join(this.dirname,r);mi.stat(n,(i,o)=>{if(i&&i.code==="ENOENT")return Co("ENOENT\xA0ok",n),this.filename=r,t(null,0);if(i)return Co(`err ${i.code} ${n}`),t(i);if(!o||this._needsNewFile(o.size))return this._incFile(()=>this.stat(t));this.filename=r,t(null,o.size)})}close(t){this._stream&&this._stream.end(()=>{t&&t(),this.emit("flush"),this.emit("closed")})}_needsNewFile(t){return t=t||this._size,this.maxsize&&t>=this.maxsize}_onError(t){this.emit("error",t)}_setupStream(t){return t.on("error",this._onError),t}_cleanupStream(t){return t.removeListener("error",this._onError),t.destroy(),t}_rotateFile(){this._incFile(()=>this.open())}_endStream(t=()=>{}){this._dest?(this._stream.unpipe(this._dest),this._dest.end(()=>{this._cleanupStream(this._dest),t()})):t()}_createStream(t){let r=tn.join(this.dirname,this.filename);Co("create stream start",r,this.options);let n=mi.createWriteStream(r,this.options).on("error",i=>Co(i)).on("close",()=>Co("close",n.path,n.bytesWritten)).on("open",()=>{Co("file open ok",r),this.emit("open",r),t.pipe(n),this.rotatedWhileOpening&&(this._stream=new Oae,this._stream.setMaxListeners(30),this._rotateFile(),this.rotatedWhileOpening=!1,this._cleanupStream(n),t.end())});return Co("create stream ok",r),n}_incFile(t){Co("_incFile",this.filename);let r=tn.extname(this._basename),n=tn.basename(this._basename,r),i=[];this.zippedArchive&&i.push(function(o){let s=this._created>0&&!this.tailable?this._created:"";this._compressFile(tn.join(this.dirname,`${n}${s}${r}`),tn.join(this.dirname,`${n}${s}${r}.gz`),o)}.bind(this)),i.push(function(o){this.tailable?this._checkMaxFilesTailable(r,n,o):(this._created+=1,this._checkMaxFilesIncrementing(r,n,o))}.bind(this)),Pae(i,t)}_getFile(){let t=tn.extname(this._basename),r=tn.basename(this._basename,t),n=this.rotationFormat?this.rotationFormat():this._created;return!this.tailable&&this._created?`${r}${n}${t}`:`${r}${t}`}_checkMaxFilesIncrementing(t,r,n){if(!this.maxFiles||this._created<this.maxFiles)return setImmediate(n);let i=this._created-this.maxFiles,o=i!==0?i:"",s=this.zippedArchive?".gz":"",a=`${r}${o}${t}${s}`,c=tn.join(this.dirname,a);mi.unlink(c,n)}_checkMaxFilesTailable(t,r,n){let i=[];if(!this.maxFiles)return;let o=this.zippedArchive?".gz":"";for(let s=this.maxFiles-1;s>1;s--)i.push(function(a,c){let u=`${r}${a-1}${t}${o}`,l=tn.join(this.dirname,u);mi.exists(l,d=>{if(!d)return c(null);u=`${r}${a}${t}${o}`,mi.rename(l,tn.join(this.dirname,u),c)})}.bind(this,s));Pae(i,()=>{mi.rename(tn.join(this.dirname,`${r}${t}${o}`),tn.join(this.dirname,`${r}1${t}${o}`),n)})}_compressFile(t,r,n){mi.access(t,mi.F_OK,i=>{if(i)return n();var o=Hnt.createGzip(),s=mi.createReadStream(t),a=mi.createWriteStream(r);a.on("finish",()=>{mi.unlink(t,n)}),s.pipe(o).pipe(a)})}_createLogDirIfNotExist(t){mi.existsSync(t)||mi.mkdirSync(t,{recursive:!0})}}});var Nae=E((GCt,kae)=>{"use strict";var Knt=require("http"),Ynt=require("https"),{Stream:Xnt}=tl(),Jnt=Dd(),{configure:Qnt}=og();kae.exports=class extends Jnt{constructor(t={}){super(t),this.options=t,this.name=t.name||"http",this.ssl=!!t.ssl,this.host=t.host||"localhost",this.port=t.port,this.auth=t.auth,this.path=t.path||"",this.maximumDepth=t.maximumDepth,this.agent=t.agent,this.headers=t.headers||{},this.headers["content-type"]="application/json",this.batch=t.batch||!1,this.batchInterval=t.batchInterval||5e3,this.batchCount=t.batchCount||10,this.batchOptions=[],this.batchTimeoutID=-1,this.batchCallback={},this.port||(this.port=this.ssl?443:80)}log(t,r){this._request(t,null,null,(n,i)=>{i&&i.statusCode!==200&&(n=new Error(`Invalid HTTP Status Code: ${i.statusCode}`)),n?this.emit("warn",n):this.emit("logged",t)}),r&&setImmediate(r)}query(t,r){typeof t=="function"&&(r=t,t={}),t={method:"query",params:this.normalizeQuery(t)};let n=t.params.auth||null;delete t.params.auth;let i=t.params.path||null;delete t.params.path,this._request(t,n,i,(o,s,a)=>{if(s&&s.statusCode!==200&&(o=new Error(`Invalid HTTP Status Code: ${s.statusCode}`)),o)return r(o);if(typeof a=="string")try{a=JSON.parse(a)}catch(c){return r(c)}r(null,a)})}stream(t={}){let r=new Xnt;t={method:"stream",params:t};let n=t.params.path||null;delete t.params.path;let i=t.params.auth||null;delete t.params.auth;let o="",s=this._request(t,i,n);return r.destroy=()=>s.destroy(),s.on("data",a=>{a=(o+a).split(/\n+/);let c=a.length-1,u=0;for(;u<c;u++)try{r.emit("log",JSON.parse(a[u]))}catch(l){r.emit("error",l)}o=a[c]}),s.on("error",a=>r.emit("error",a)),r}_request(t,r,n,i){t=t||{},r=r||this.auth,n=n||this.path||"",this.batch?this._doBatch(t,i,r,n):this._doRequest(t,i,r,n)}_doBatch(t,r,n,i){if(this.batchOptions.push(t),this.batchOptions.length===1){let o=this;this.batchCallback=r,this.batchTimeoutID=setTimeout(function(){o.batchTimeoutID=-1,o._doBatchRequest(o.batchCallback,n,i)},this.batchInterval)}this.batchOptions.length===this.batchCount&&this._doBatchRequest(this.batchCallback,n,i)}_doBatchRequest(t,r,n){this.batchTimeoutID>0&&(clearTimeout(this.batchTimeoutID),this.batchTimeoutID=-1);let i=this.batchOptions.slice();this.batchOptions=[],this._doRequest(i,t,r,n)}_doRequest(t,r,n,i){let o=Object.assign({},this.headers);n&&n.bearer&&(o.Authorization=`Bearer ${n.bearer}`);let s=(this.ssl?Ynt:Knt).request({...this.options,method:"POST",host:this.host,port:this.port,path:`/${i.replace(/^\//,"")}`,headers:o,auth:n&&n.username&&n.password?`${n.username}:${n.password}`:"",agent:this.agent});s.on("error",r),s.on("response",c=>c.on("end",()=>r(null,c)).resume());let a=Qnt({...this.maximumDepth&&{maximumDepth:this.maximumDepth}});s.end(Buffer.from(a(t,this.options.replacer),"utf8"))}}});var $M=E((zCt,Mae)=>{"use strict";var us=e=>e!==null&&typeof e=="object"&&typeof e.pipe=="function";us.writable=e=>us(e)&&e.writable!==!1&&typeof e._write=="function"&&typeof e._writableState=="object";us.readable=e=>us(e)&&e.readable!==!1&&typeof e._read=="function"&&typeof e._readableState=="object";us.duplex=e=>us.writable(e)&&us.readable(e);us.transform=e=>us.duplex(e)&&typeof e._transform=="function";Mae.exports=us});var Bae=E((WCt,Lae)=>{"use strict";var Znt=$M(),{MESSAGE:eit}=Pr(),tit=require("os"),rit=Dd();Lae.exports=class extends rit{constructor(t={}){if(super(t),!t.stream||!Znt(t.stream))throw new Error("options.stream is required.");this._stream=t.stream,this._stream.setMaxListeners(1/0),this.isObjectMode=t.stream._writableState.objectMode,this.eol=typeof t.eol=="string"?t.eol:tit.EOL}log(t,r){if(setImmediate(()=>this.emit("logged",t)),this.isObjectMode){this._stream.write(t),r&&r();return}this._stream.write(`${t[eit]}${this.eol}`),r&&r()}}});var Fae=E(Ag=>{"use strict";Object.defineProperty(Ag,"Console",{configurable:!0,enumerable:!0,get(){return Coe()}});Object.defineProperty(Ag,"File",{configurable:!0,enumerable:!0,get(){return Dae()}});Object.defineProperty(Ag,"Http",{configurable:!0,enumerable:!0,get(){return Nae()}});Object.defineProperty(Ag,"Stream",{configurable:!0,enumerable:!0,get(){return Bae()}})});var ex=E(Rg=>{"use strict";var ZC=IN(),{configs:GM}=Pr();Rg.cli=ZC.levels(GM.cli);Rg.npm=ZC.levels(GM.npm);Rg.syslog=ZC.levels(GM.syslog);Rg.addColors=ZC.levels});var jae=E((tx,qae)=>{"use strict";Object.defineProperty(tx,"__esModule",{value:!0});var nit=wC(),iit=rl(nit),oit=IC(),sit=rl(oit),ait=aM(),cit=rl(ait),uit=iM(),lit=rl(uit),fit=oM(),dit=rl(fit),pit=Xu(),hit=rl(pit),mit=Nd(),git=rl(mit);function rl(e){return e&&e.__esModule?e:{default:e}}function yit(e,t,r){r=(0,lit.default)(r);var n=0,i=0,{length:o}=e,s=!1;o===0&&r(null);function a(c,u){c===!1&&(s=!0),s!==!0&&(c?r(c):(++i===o||u===sit.default)&&r(null))}for(;n<o;n++)t(e[n],n,(0,dit.default)(a))}function _it(e,t,r){return(0,cit.default)(e,1/0,t,r)}function bit(e,t,r){var n=(0,iit.default)(e)?yit:_it;return n(e,(0,hit.default)(t),r)}tx.default=(0,git.default)(bit,3);qae.exports=tx.default});var Hae=E((rx,Uae)=>{"use strict";Object.defineProperty(rx,"__esModule",{value:!0});rx.default=Eit;function Eit(e){return(t,r,n)=>e(t,n)}Uae.exports=rx.default});var ox=E((ix,$ae)=>{"use strict";Object.defineProperty(ix,"__esModule",{value:!0});var wit=jae(),Sit=nx(wit),vit=Hae(),Cit=nx(vit),xit=Xu(),Tit=nx(xit),Ait=Nd(),Rit=nx(Ait);function nx(e){return e&&e.__esModule?e:{default:e}}function Pit(e,t,r){return(0,Sit.default)(e,(0,Cit.default)((0,Tit.default)(t)),r)}ix.default=(0,Rit.default)(Pit,3);$ae.exports=ix.default});var zae=E((XCt,Gae)=>{"use strict";var Oit=Object.prototype.toString;Gae.exports=function(t){if(typeof t.displayName=="string"&&t.constructor.name)return t.displayName;if(typeof t.name=="string"&&t.name)return t.name;if(typeof t=="object"&&t.constructor&&typeof t.constructor.name=="string")return t.constructor.name;var r=t.toString(),n=Oit.call(t).slice(8,-1);return n==="Function"?r=r.substring(r.indexOf("(")+1,r.indexOf(")")):r=n,r||"anonymous"}});var zM=E((JCt,Vae)=>{"use strict";var Iit=zae();Vae.exports=function(t){var r=0,n;function i(){return r||(r=1,n=t.apply(this,arguments),t=null),n}return i.displayName=Iit(t),i}});var VM=E(Og=>{"use strict";Og.get=function(e){var t=Error.stackTraceLimit;Error.stackTraceLimit=1/0;var r={},n=Error.prepareStackTrace;Error.prepareStackTrace=function(o,s){return s},Error.captureStackTrace(r,e||Og.get);var i=r.stack;return Error.prepareStackTrace=n,Error.stackTraceLimit=t,i};Og.parse=function(e){if(!e.stack)return[];var t=this,r=e.stack.split(`
|
|
267
|
+
`).slice(1);return r.map(function(n){if(n.match(/^\s*[-]{4,}$/))return t._createParsedCallSite({fileName:n,lineNumber:null,functionName:null,typeName:null,methodName:null,columnNumber:null,native:null});var i=n.match(/at (?:(.+)\s+\()?(?:(.+?):(\d+)(?::(\d+))?|([^)]+))\)?/);if(i){var o=null,s=null,a=null,c=null,u=null,l=i[5]==="native";if(i[1]){a=i[1];var d=a.lastIndexOf(".");if(a[d-1]=="."&&d--,d>0){o=a.substr(0,d),s=a.substr(d+1);var h=o.indexOf(".Module");h>0&&(a=a.substr(h+1),o=o.substr(0,h))}c=null}s&&(c=o,u=s),s==="<anonymous>"&&(u=null,a=null);var f={fileName:i[2]||null,lineNumber:parseInt(i[3],10)||null,functionName:a,typeName:c,methodName:u,columnNumber:parseInt(i[4],10)||null,native:l};return t._createParsedCallSite(f)}}).filter(function(n){return!!n})};function Pg(e){for(var t in e)this[t]=e[t]}var Dit=["this","typeName","functionName","methodName","fileName","lineNumber","columnNumber","function","evalOrigin"],kit=["topLevel","eval","native","constructor"];Dit.forEach(function(e){Pg.prototype[e]=null,Pg.prototype["get"+e[0].toUpperCase()+e.substr(1)]=function(){return this[e]}});kit.forEach(function(e){Pg.prototype[e]=!1,Pg.prototype["is"+e[0].toUpperCase()+e.substr(1)]=function(){return this[e]}});Og._createParsedCallSite=function(e){return new Pg(e)}});var Kae=E((ext,Wae)=>{"use strict";var{Writable:Nit}=tl();Wae.exports=class extends Nit{constructor(t){if(super({objectMode:!0}),!t)throw new Error("ExceptionStream requires a TransportStream instance.");this.handleExceptions=!0,this.transport=t}_write(t,r,n){return t.exception?this.transport.log(t,n):(n(),!0)}}});var KM=E((rxt,Jae)=>{"use strict";var Yae=require("os"),Mit=ox(),WM=Tg()("winston:exception"),Lit=zM(),Xae=VM(),Bit=Kae();Jae.exports=class{constructor(t){if(!t)throw new Error("Logger is required to handle exceptions");this.logger=t,this.handlers=new Map}handle(...t){t.forEach(r=>{if(Array.isArray(r))return r.forEach(n=>this._addHandler(n));this._addHandler(r)}),this.catcher||(this.catcher=this._uncaughtException.bind(this),process.on("uncaughtException",this.catcher))}unhandle(){this.catcher&&(process.removeListener("uncaughtException",this.catcher),this.catcher=!1,Array.from(this.handlers.values()).forEach(t=>this.logger.unpipe(t)))}getAllInfo(t){let r=null;return t&&(r=typeof t=="string"?t:t.message),{error:t,level:"error",message:[`uncaughtException: ${r||"(no error message)"}`,t&&t.stack||" No stack trace"].join(`
|
|
268
|
+
`),stack:t&&t.stack,exception:!0,date:new Date().toString(),process:this.getProcessInfo(),os:this.getOsInfo(),trace:this.getTrace(t)}}getProcessInfo(){return{pid:process.pid,uid:process.getuid?process.getuid():null,gid:process.getgid?process.getgid():null,cwd:process.cwd(),execPath:process.execPath,version:process.version,argv:process.argv,memoryUsage:process.memoryUsage()}}getOsInfo(){return{loadavg:Yae.loadavg(),uptime:Yae.uptime()}}getTrace(t){return(t?Xae.parse(t):Xae.get()).map(n=>({column:n.getColumnNumber(),file:n.getFileName(),function:n.getFunctionName(),line:n.getLineNumber(),method:n.getMethodName(),native:n.isNative()}))}_addHandler(t){if(!this.handlers.has(t)){t.handleExceptions=!0;let r=new Bit(t);this.handlers.set(t,r),this.logger.pipe(r)}}_uncaughtException(t){let r=this.getAllInfo(t),n=this._getExceptionHandlers(),i=typeof this.logger.exitOnError=="function"?this.logger.exitOnError(t):this.logger.exitOnError,o;!n.length&&i&&(console.warn("winston: exitOnError cannot be true with no exception handlers."),console.warn("winston: not exiting process."),i=!1);function s(){WM("doExit",i),WM("process._exiting",process._exiting),i&&!process._exiting&&(o&&clearTimeout(o),process.exit(1))}if(!n||n.length===0)return process.nextTick(s);Mit(n,(a,c)=>{let u=Lit(c),l=a.transport||a;function d(h){return()=>{WM(h),u()}}l._ending=!0,l.once("finish",d("finished")),l.once("error",d("error"))},()=>i&&s()),this.logger.log(r),i&&(o=setTimeout(s,3e3))}_getExceptionHandlers(){return this.logger.transports.filter(t=>(t.transport||t).handleExceptions)}}});var Zae=E((ixt,Qae)=>{"use strict";var{Writable:Fit}=tl();Qae.exports=class extends Fit{constructor(t){if(super({objectMode:!0}),!t)throw new Error("RejectionStream requires a TransportStream instance.");this.handleRejections=!0,this.transport=t}_write(t,r,n){return t.rejection?this.transport.log(t,n):(n(),!0)}}});var XM=E((sxt,rce)=>{"use strict";var ece=require("os"),qit=ox(),YM=Tg()("winston:rejection"),jit=zM(),tce=VM(),Uit=Zae();rce.exports=class{constructor(t){if(!t)throw new Error("Logger is required to handle rejections");this.logger=t,this.handlers=new Map}handle(...t){t.forEach(r=>{if(Array.isArray(r))return r.forEach(n=>this._addHandler(n));this._addHandler(r)}),this.catcher||(this.catcher=this._unhandledRejection.bind(this),process.on("unhandledRejection",this.catcher))}unhandle(){this.catcher&&(process.removeListener("unhandledRejection",this.catcher),this.catcher=!1,Array.from(this.handlers.values()).forEach(t=>this.logger.unpipe(t)))}getAllInfo(t){let r=null;return t&&(r=typeof t=="string"?t:t.message),{error:t,level:"error",message:[`unhandledRejection: ${r||"(no error message)"}`,t&&t.stack||" No stack trace"].join(`
|
|
269
|
+
`),stack:t&&t.stack,rejection:!0,date:new Date().toString(),process:this.getProcessInfo(),os:this.getOsInfo(),trace:this.getTrace(t)}}getProcessInfo(){return{pid:process.pid,uid:process.getuid?process.getuid():null,gid:process.getgid?process.getgid():null,cwd:process.cwd(),execPath:process.execPath,version:process.version,argv:process.argv,memoryUsage:process.memoryUsage()}}getOsInfo(){return{loadavg:ece.loadavg(),uptime:ece.uptime()}}getTrace(t){return(t?tce.parse(t):tce.get()).map(n=>({column:n.getColumnNumber(),file:n.getFileName(),function:n.getFunctionName(),line:n.getLineNumber(),method:n.getMethodName(),native:n.isNative()}))}_addHandler(t){if(!this.handlers.has(t)){t.handleRejections=!0;let r=new Uit(t);this.handlers.set(t,r),this.logger.pipe(r)}}_unhandledRejection(t){let r=this.getAllInfo(t),n=this._getRejectionHandlers(),i=typeof this.logger.exitOnError=="function"?this.logger.exitOnError(t):this.logger.exitOnError,o;!n.length&&i&&(console.warn("winston: exitOnError cannot be true with no rejection handlers."),console.warn("winston: not exiting process."),i=!1);function s(){YM("doExit",i),YM("process._exiting",process._exiting),i&&!process._exiting&&(o&&clearTimeout(o),process.exit(1))}if(!n||n.length===0)return process.nextTick(s);qit(n,(a,c)=>{let u=jit(c),l=a.transport||a;function d(h){return()=>{YM(h),u()}}l._ending=!0,l.once("finish",d("finished")),l.once("error",d("error"))},()=>i&&s()),this.logger.log(r),i&&(o=setTimeout(s,3e3))}_getRejectionHandlers(){return this.logger.transports.filter(t=>(t.transport||t).handleRejections)}}});var ice=E((axt,nce)=>{"use strict";var JM=class{constructor(t){let r=sx();if(typeof t!="object"||Array.isArray(t)||!(t instanceof r))throw new Error("Logger is required for profiling");this.logger=t,this.start=Date.now()}done(...t){typeof t[t.length-1]=="function"&&(console.warn("Callback function no longer supported as of winston@3.0.0"),t.pop());let r=typeof t[t.length-1]=="object"?t.pop():{};return r.level=r.level||"info",r.durationMs=Date.now()-this.start,this.logger.write(r)}};nce.exports=JM});var sx=E((cxt,cce)=>{"use strict";var{Stream:Hit,Transform:$it}=tl(),oce=ox(),{LEVEL:ls,SPLAT:sce}=Pr(),ace=$M(),Git=KM(),zit=XM(),Vit=tM(),Wit=ice(),{warn:Kit}=DN(),Yit=ex(),Xit=/%[scdjifoO%]/g,ax=class extends $it{constructor(t){super({objectMode:!0}),this.configure(t)}child(t){let r=this;return Object.create(r,{write:{value:function(n){let i=Object.assign({},t,n);n instanceof Error&&(i.stack=n.stack,i.message=n.message),r.write(i)}}})}configure({silent:t,format:r,defaultMeta:n,levels:i,level:o="info",exitOnError:s=!0,transports:a,colors:c,emitErrs:u,formatters:l,padLevels:d,rewriters:h,stripColors:f,exceptionHandlers:p,rejectionHandlers:m}={}){if(this.transports.length&&this.clear(),this.silent=t,this.format=r||this.format||TN()(),this.defaultMeta=n||null,this.levels=i||this.levels||Yit.npm.levels,this.level=o,this.exceptions&&this.exceptions.unhandle(),this.rejections&&this.rejections.unhandle(),this.exceptions=new Git(this),this.rejections=new zit(this),this.profilers={},this.exitOnError=s,a&&(a=Array.isArray(a)?a:[a],a.forEach(_=>this.add(_))),c||u||l||d||h||f)throw new Error(["{ colors, emitErrs, formatters, padLevels, rewriters, stripColors } were removed in winston@3.0.0.","Use a custom winston.format(function) instead.","See: https://github.com/winstonjs/winston/tree/master/UPGRADE-3.0.md"].join(`
|
|
270
|
+
`));p&&this.exceptions.handle(p),m&&this.rejections.handle(m)}getHighestLogLevel(){let t=Ig(this.levels,this.level);return!this.transports||this.transports.length===0?t:this.transports.reduce((r,n)=>{let i=Ig(this.levels,n.level);return i!==null&&i>r?i:r},t)}isLevelEnabled(t){let r=Ig(this.levels,t);if(r===null)return!1;let n=Ig(this.levels,this.level);return n===null?!1:!this.transports||this.transports.length===0?n>=r:this.transports.findIndex(o=>{let s=Ig(this.levels,o.level);return s===null&&(s=n),s>=r})!==-1}log(t,r,...n){if(arguments.length===1)return t[ls]=t.level,this._addDefaultMeta(t),this.write(t),this;if(arguments.length===2)return r&&typeof r=="object"?(r[ls]=r.level=t,this._addDefaultMeta(r),this.write(r),this):(r={[ls]:t,level:t,message:r},this._addDefaultMeta(r),this.write(r),this);let[i]=n;if(typeof i=="object"&&i!==null&&!(r&&r.match&&r.match(Xit))){let s=Object.assign({},this.defaultMeta,i,{[ls]:t,[sce]:n,level:t,message:r});return i.message&&(s.message=`${s.message} ${i.message}`),i.stack&&(s.stack=i.stack),i.cause&&(s.cause=i.cause),this.write(s),this}return this.write(Object.assign({},this.defaultMeta,{[ls]:t,[sce]:n,level:t,message:r})),this}_transform(t,r,n){if(this.silent)return n();t[ls]||(t[ls]=t.level),!this.levels[t[ls]]&&this.levels[t[ls]]!==0&&console.error("[winston] Unknown logger level: %s",t[ls]),this._readableState.pipes||console.error("[winston] Attempt to write logs with no transports, which can increase memory usage: %j",t);try{this.push(this.format.transform(t,this.format.options))}finally{this._writableState.sync=!1,n()}}_final(t){let r=this.transports.slice();oce(r,(n,i)=>{if(!n||n.finished)return setImmediate(i);n.once("finish",i),n.end()},t)}add(t){let r=!ace(t)||t.log.length>2?new Vit({transport:t}):t;if(!r._writableState||!r._writableState.objectMode)throw new Error("Transports must WritableStreams in objectMode. Set { objectMode: true }.");return this._onEvent("error",r),this._onEvent("warn",r),this.pipe(r),t.handleExceptions&&this.exceptions.handle(),t.handleRejections&&this.rejections.handle(),this}remove(t){if(!t)return this;let r=t;return(!ace(t)||t.log.length>2)&&(r=this.transports.filter(n=>n.transport===t)[0]),r&&this.unpipe(r),this}clear(){return this.unpipe(),this}close(){return this.exceptions.unhandle(),this.rejections.unhandle(),this.clear(),this.emit("close"),this}setLevels(){Kit.deprecated("setLevels")}query(t,r){typeof t=="function"&&(r=t,t={}),t=t||{};let n={},i=Object.assign({},t.query||{});function o(a,c){t.query&&typeof a.formatQuery=="function"&&(t.query=a.formatQuery(i)),a.query(t,(u,l)=>{if(u)return c(u);typeof a.formatResults=="function"&&(l=a.formatResults(l,t.format)),c(null,l)})}function s(a,c){o(a,(u,l)=>{c&&(l=u||l,l&&(n[a.name]=l),c()),c=null})}oce(this.transports.filter(a=>!!a.query),s,()=>r(null,n))}stream(t={}){let r=new Hit,n=[];return r._streams=n,r.destroy=()=>{let i=n.length;for(;i--;)n[i].destroy()},this.transports.filter(i=>!!i.stream).forEach(i=>{let o=i.stream(t);o&&(n.push(o),o.on("log",s=>{s.transport=s.transport||[],s.transport.push(i.name),r.emit("log",s)}),o.on("error",s=>{s.transport=s.transport||[],s.transport.push(i.name),r.emit("error",s)}))}),r}startTimer(){return new Wit(this)}profile(t,...r){let n=Date.now();if(this.profilers[t]){let i=this.profilers[t];delete this.profilers[t],typeof r[r.length-2]=="function"&&(console.warn("Callback function no longer supported as of winston@3.0.0"),r.pop());let o=typeof r[r.length-1]=="object"?r.pop():{};return o.level=o.level||"info",o.durationMs=n-i,o.message=o.message||t,this.write(o)}return this.profilers[t]=n,this}handleExceptions(...t){console.warn("Deprecated: .handleExceptions() will be removed in winston@4. Use .exceptions.handle()"),this.exceptions.handle(...t)}unhandleExceptions(...t){console.warn("Deprecated: .unhandleExceptions() will be removed in winston@4. Use .exceptions.unhandle()"),this.exceptions.unhandle(...t)}cli(){throw new Error(["Logger.cli() was removed in winston@3.0.0","Use a custom winston.formats.cli() instead.","See: https://github.com/winstonjs/winston/tree/master/UPGRADE-3.0.md"].join(`
|
|
271
|
+
`))}_onEvent(t,r){function n(i){t==="error"&&!this.transports.includes(r)&&this.add(r),this.emit(t,i,r)}r["__winston"+t]||(r["__winston"+t]=n.bind(this),r.on(t,r["__winston"+t]))}_addDefaultMeta(t){this.defaultMeta&&Object.assign(t,this.defaultMeta)}};function Ig(e,t){let r=e[t];return!r&&r!==0?null:r}Object.defineProperty(ax.prototype,"transports",{configurable:!1,enumerable:!0,get(){let{pipes:e}=this._readableState;return Array.isArray(e)?e:[e].filter(Boolean)}});cce.exports=ax});var QM=E((uxt,uce)=>{"use strict";var{LEVEL:Jit}=Pr(),Qit=ex(),Zit=sx(),eot=Tg()("winston:create-logger");function tot(e){return"is"+e.charAt(0).toUpperCase()+e.slice(1)+"Enabled"}uce.exports=function(e={}){e.levels=e.levels||Qit.npm.levels;class t extends Zit{constructor(i){super(i)}}let r=new t(e);return Object.keys(e.levels).forEach(function(n){if(eot('Define prototype method for "%s"',n),n==="log"){console.warn('Level "log" not defined: conflicts with the method "log". Use a different level name.');return}t.prototype[n]=function(...i){let o=this||r;if(i.length===1){let[s]=i,a=s&&s.message&&s||{message:s};return a.level=a[Jit]=n,o._addDefaultMeta(a),o.write(a),this||r}return i.length===0?(o.log(n,""),o):o.log(n,...i)},t.prototype[tot(n)]=function(){return(this||r).isLevelEnabled(n)}}),r}});var fce=E((fxt,lce)=>{"use strict";var rot=QM();lce.exports=class{constructor(t={}){this.loggers=new Map,this.options=t}add(t,r){if(!this.loggers.has(t)){r=Object.assign({},r||this.options);let n=r.transports||this.options.transports;n?r.transports=Array.isArray(n)?n.slice():[n]:r.transports=[];let i=rot(r);i.on("close",()=>this._delete(t)),this.loggers.set(t,i)}return this.loggers.get(t)}get(t,r){return this.add(t,r)}has(t){return!!this.loggers.has(t)}close(t){if(t)return this._removeLogger(t);this.loggers.forEach((r,n)=>this._removeLogger(n))}_removeLogger(t){if(!this.loggers.has(t))return;this.loggers.get(t).close(),this._delete(t)}_delete(t){this.loggers.delete(t)}}});var pce=E(zt=>{"use strict";var dce=IN(),{warn:Dg}=DN();zt.version=Rie().version;zt.transports=Fae();zt.config=ex();zt.addColors=dce.levels;zt.format=dce.format;zt.createLogger=QM();zt.Logger=sx();zt.ExceptionHandler=KM();zt.RejectionHandler=XM();zt.Container=fce();zt.Transport=Dd();zt.loggers=new zt.Container;var fs=zt.createLogger();Object.keys(zt.config.npm.levels).concat(["log","query","stream","add","remove","clear","profile","startTimer","handleExceptions","unhandleExceptions","handleRejections","unhandleRejections","configure","child"]).forEach(e=>zt[e]=(...t)=>fs[e](...t));Object.defineProperty(zt,"level",{get(){return fs.level},set(e){fs.level=e}});Object.defineProperty(zt,"exceptions",{get(){return fs.exceptions}});Object.defineProperty(zt,"rejections",{get(){return fs.rejections}});["exitOnError"].forEach(e=>{Object.defineProperty(zt,e,{get(){return fs[e]},set(t){fs[e]=t}})});Object.defineProperty(zt,"default",{get(){return{exceptionHandlers:fs.exceptionHandlers,rejectionHandlers:fs.rejectionHandlers,transports:fs.transports}}});Dg.deprecated(zt,"setLevels");Dg.forFunctions(zt,"useFormat",["cli"]);Dg.forProperties(zt,"useFormat",["padLevels","stripColors"]);Dg.forFunctions(zt,"deprecated",["addRewriter","addFilter","clone","extend"]);Dg.forProperties(zt,"deprecated",["emitErrs","levelLength"])});var mce=E(Ng=>{"use strict";var not=Ng&&Ng.__spreadArray||function(e,t,r){if(r||arguments.length===2)for(var n=0,i=t.length,o;n<i;n++)(o||!(n in t))&&(o||(o=Array.prototype.slice.call(t,0,n)),o[n]=t[n]);return e.concat(o||Array.prototype.slice.call(t))};Object.defineProperty(Ng,"__esModule",{value:!0});Ng.mergeParams=iot;function iot(e){var t={delimiter:",",ignoreColumns:void 0,includeColumns:void 0,quote:'"',trim:!0,checkType:!1,ignoreEmpty:!1,noheader:!1,headers:void 0,flatKeys:!1,maxRowLength:0,checkColumn:!1,escape:'"',colParser:{},eol:void 0,alwaysSplitAtEOL:!1,output:"json",nullObject:!1,downstreamFormat:"line",needEmitAll:!0};e||(e={});for(var r in e)e.hasOwnProperty(r)&&(Array.isArray(e[r])?t[r]=not([],e[r],!0):t[r]=e[r]);return t}});var gce=E(ZM=>{"use strict";Object.defineProperty(ZM,"__esModule",{value:!0});ZM.initParseRuntime=oot;function oot(e){var t=e.parseParam,r={needProcessIgnoreColumn:!1,needProcessIncludeColumn:!1,selectedColumns:void 0,ended:!1,hasError:!1,error:void 0,delimiter:e.parseParam.delimiter,eol:e.parseParam.eol,columnConv:[],headerType:[],headerTitle:[],headerFlag:[],headers:void 0,started:!1,parsedLineNumber:0,columnValueSetter:[]};return t.ignoreColumns&&(r.needProcessIgnoreColumn=!0),t.includeColumns&&(r.needProcessIncludeColumn=!0),r}});var yce=E(cx=>{"use strict";Object.defineProperty(cx,"__esModule",{value:!0});cx.Processor=void 0;var sot=(function(){function e(t){this.converter=t,this.params=t.parseParam,this.runtime=t.parseRuntime}return e})();cx.Processor=sot});var _ce=E(eL=>{"use strict";Object.defineProperty(eL,"__esModule",{value:!0});eL.prepareData=cot;function aot(e){if(typeof e!="string")throw new TypeError("Expected a string, got ".concat(typeof e));return e.charCodeAt(0)===65279?e.slice(1):e}function cot(e,t){var r=uot(e,t);t.csvLineBuffer=void 0;var n=lot(r,t).toString("utf8");return t.started===!1?aot(n):n}function uot(e,t){return t.csvLineBuffer&&t.csvLineBuffer.length>0?Buffer.concat([t.csvLineBuffer,e]):e}function lot(e,t){var r=e.length-1;if((e[r]&128)!=0){for(;(e[r]&192)===128;)r--;r--}return r!=e.length-1?(t.csvLineBuffer=e.slice(r+1),e.slice(0,r+1)):e}});var ux=E(tL=>{"use strict";Object.defineProperty(tL,"__esModule",{value:!0});tL.default=fot;function fot(e,t){if(!t.eol&&e){for(var r=0,n=e.length;r<n;r++)if(e[r]==="\r"){if(e[r+1]===`
|
|
272
|
+
`){t.eol=`\r
|
|
273
|
+
`;break}else if(e[r+1]){t.eol="\r";break}}else if(e[r]===`
|
|
274
|
+
`){t.eol=`
|
|
275
|
+
`;break}}return t.eol||`
|
|
276
|
+
`}});var bce=E(Mg=>{"use strict";var dot=Mg&&Mg.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(Mg,"__esModule",{value:!0});Mg.stringToLines=hot;var pot=dot(ux());function hot(e,t){var r=(0,pot.default)(e,t),n=e.split(r),i=n.pop()||"";return{lines:n,partial:i}}});var rL=E(Qs=>{"use strict";Object.defineProperty(Qs,"__esModule",{value:!0});Qs.trimRight=Qs.trimLeft=void 0;Qs.bufFromString=mot;Qs.emptyBuffer=got;Qs.filterArray=yot;function mot(e){var t=Buffer.byteLength(e),r=Buffer.allocUnsafe?Buffer.allocUnsafe(t):new Buffer(t);return r.write(e),r}function got(){var e=Buffer.allocUnsafe?Buffer.allocUnsafe(0):new Buffer(0);return e}function yot(e,t){for(var r=[],n=0;n<e.length;n++)t.indexOf(n)>-1&&r.push(e[n]);return r}var _ot=function(t){return t.trimStart()};Qs.trimLeft=_ot;var bot=function(t){return t.trimEnd()};Qs.trimRight=bot});var Ece=E($d=>{"use strict";var Eot=$d&&$d.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty($d,"__esModule",{value:!0});$d.RowSplit=void 0;var wot=Eot(ux()),Hd=rL(),Sot=[",","|"," ",";",":"],vot=(function(){function e(t){this.conv=t,this.cachedRegExp={},this.delimiterEmitted=!1,this._needEmitDelimiter=void 0,this.quote=t.parseParam.quote,this.trim=t.parseParam.trim,this.escape=t.parseParam.escape}return Object.defineProperty(e.prototype,"needEmitDelimiter",{get:function(){return this._needEmitDelimiter===void 0&&(this._needEmitDelimiter=this.conv.listeners("delimiter").length>0),this._needEmitDelimiter},enumerable:!1,configurable:!0}),e.prototype.parse=function(t){if(t.length===0||this.conv.parseParam.ignoreEmpty&&t.trim().length===0)return{cells:[],closed:!0};var r=this.quote,n=this.trim,i=this.escape;(this.conv.parseRuntime.delimiter instanceof Array||this.conv.parseRuntime.delimiter.toLowerCase()==="auto")&&(this.conv.parseRuntime.delimiter=this.getDelimiter(t)),this.needEmitDelimiter&&!this.delimiterEmitted&&(this.conv.emit("delimiter",this.conv.parseRuntime.delimiter),this.delimiterEmitted=!0);var o=this.conv.parseRuntime.delimiter,s=t.split(o);if(r==="off"){if(n)for(var a=0;a<s.length;a++)s[a]=s[a].trim();return{cells:s,closed:!0}}else return this.toCSVRow(s,n,r,o)},e.prototype.toCSVRow=function(t,r,n,i){for(var o=[],s=!1,a="",c=0,u=t.length;c<u;c++){var l=t[c];!s&&r&&(l=(0,Hd.trimLeft)(l));var d=l.length;if(s)this.isQuoteClose(l)?(s=!1,l=l.substr(0,d-1),a+=i+l,a=this.escapeQuote(a),r&&(a=(0,Hd.trimRight)(a)),o.push(a),a=""):a+=i+l;else if(d===2&&l===this.quote+this.quote){o.push("");continue}else if(this.isQuoteOpen(l))if(l=l.substr(1),this.isQuoteClose(l)){l=l.substr(0,l.lastIndexOf(n)),l=this.escapeQuote(l),o.push(l);continue}else if(l.indexOf(n)!==-1){for(var h=0,f="",p=0,m=l;p<m.length;p++){var _=m[p];_===n&&f!==this.escape?(h++,f=""):f=_}if(h%2===1){r&&(l=(0,Hd.trimRight)(l)),o.push(n+l);continue}else{s=!0,a+=l;continue}}else{s=!0,a+=l;continue}else{r&&(l=(0,Hd.trimRight)(l)),o.push(l);continue}}return{cells:o,closed:!s}},e.prototype.getDelimiter=function(t){var r;if(this.conv.parseParam.delimiter==="auto")r=Sot;else if(this.conv.parseParam.delimiter instanceof Array)r=this.conv.parseParam.delimiter;else return this.conv.parseParam.delimiter;var n=0,i=",";return r.forEach(function(o){var s=t.split(o).length;s>n&&(i=o,n=s)}),i},e.prototype.isQuoteOpen=function(t){var r=this.quote,n=this.escape;return t[0]===r&&(t[1]!==r||t[1]===n&&(t[2]===r||t.length===2))},e.prototype.isQuoteClose=function(t){var r=this.quote,n=this.escape;this.conv.parseParam.trim&&(t=(0,Hd.trimRight)(t));for(var i=0,o=t.length-1;t[o]===r||t[o]===n;)o--,i++;return i%2!==0},e.prototype.escapeQuote=function(t){var r="es|"+this.quote+"|"+this.escape;this.cachedRegExp[r]===void 0&&(this.cachedRegExp[r]=new RegExp("\\"+this.escape+"\\"+this.quote,"g"));var n=this.cachedRegExp[r];return t.replace(n,this.quote)},e.prototype.parseMultiLines=function(t){for(var r=[],n="";t.length;){var i=n+t.shift(),o=this.parse(i);o.cells.length===0&&this.conv.parseParam.ignoreEmpty||(o.closed||this.conv.parseParam.alwaysSplitAtEOL?(this.conv.parseRuntime.selectedColumns?r.push((0,Hd.filterArray)(o.cells,this.conv.parseRuntime.selectedColumns)):r.push(o.cells),n=""):n=i+((0,wot.default)(i,this.conv.parseRuntime)||`
|
|
277
|
+
`))}return{rowsCells:r,partial:n}},e})();$d.RowSplit=vot});var nL=E(Lg=>{"use strict";var Cot=Lg&&Lg.__extends||(function(){var e=function(t,r){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(n[o]=i[o])},e(t,r)};return function(t,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");e(t,r);function n(){this.constructor=t}t.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})();Object.defineProperty(Lg,"__esModule",{value:!0});var xot=(function(e){Cot(t,e);function t(r,n,i){var o=e.call(this,"Error: "+r+". JSON Line number: "+n+(i?" near: "+i:""))||this;return o.err=r,o.line=n,o.extra=i,o.name="CSV Parse Error",o}return t.column_mismatched=function(r,n){return new t("column_mismatched",r,n)},t.unclosed_quote=function(r,n){return new t("unclosed_quote",r,n)},t.fromJSON=function(r){return new t(r.err,r.line,r.extra)},t.prototype.toJSON=function(){return{err:this.err,line:this.line,extra:this.extra}},t})(Error);Lg.default=xot});var Sce=E((xxt,wce)=>{"use strict";var Tot=typeof global=="object"&&global&&global.Object===Object&&global;wce.exports=Tot});var lx=E((Txt,vce)=>{"use strict";var Aot=Sce(),Rot=typeof self=="object"&&self&&self.Object===Object&&self,Pot=Aot||Rot||Function("return this")();vce.exports=Pot});var fx=E((Axt,Cce)=>{"use strict";var Oot=lx(),Iot=Oot.Symbol;Cce.exports=Iot});var Rce=E((Rxt,Ace)=>{"use strict";var xce=fx(),Tce=Object.prototype,Dot=Tce.hasOwnProperty,kot=Tce.toString,Bg=xce?xce.toStringTag:void 0;function Not(e){var t=Dot.call(e,Bg),r=e[Bg];try{e[Bg]=void 0;var n=!0}catch{}var i=kot.call(e);return n&&(t?e[Bg]=r:delete e[Bg]),i}Ace.exports=Not});var Oce=E((Pxt,Pce)=>{"use strict";var Mot=Object.prototype,Lot=Mot.toString;function Bot(e){return Lot.call(e)}Pce.exports=Bot});var iL=E((Oxt,kce)=>{"use strict";var Ice=fx(),Fot=Rce(),qot=Oce(),jot="[object Null]",Uot="[object Undefined]",Dce=Ice?Ice.toStringTag:void 0;function Hot(e){return e==null?e===void 0?Uot:jot:Dce&&Dce in Object(e)?Fot(e):qot(e)}kce.exports=Hot});var dx=E((Ixt,Nce)=>{"use strict";function $ot(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}Nce.exports=$ot});var Lce=E((Dxt,Mce)=>{"use strict";var Got=iL(),zot=dx(),Vot="[object AsyncFunction]",Wot="[object Function]",Kot="[object GeneratorFunction]",Yot="[object Proxy]";function Xot(e){if(!zot(e))return!1;var t=Got(e);return t==Wot||t==Kot||t==Vot||t==Yot}Mce.exports=Xot});var Fce=E((kxt,Bce)=>{"use strict";var Jot=lx(),Qot=Jot["__core-js_shared__"];Bce.exports=Qot});var Uce=E((Nxt,jce)=>{"use strict";var oL=Fce(),qce=(function(){var e=/[^.]+$/.exec(oL&&oL.keys&&oL.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""})();function Zot(e){return!!qce&&qce in e}jce.exports=Zot});var $ce=E((Mxt,Hce)=>{"use strict";var est=Function.prototype,tst=est.toString;function rst(e){if(e!=null){try{return tst.call(e)}catch{}try{return e+""}catch{}}return""}Hce.exports=rst});var zce=E((Lxt,Gce)=>{"use strict";var nst=Lce(),ist=Uce(),ost=dx(),sst=$ce(),ast=/[\\^$.*+?()[\]{}|]/g,cst=/^\[object .+?Constructor\]$/,ust=Function.prototype,lst=Object.prototype,fst=ust.toString,dst=lst.hasOwnProperty,pst=RegExp("^"+fst.call(dst).replace(ast,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function hst(e){if(!ost(e)||ist(e))return!1;var t=nst(e)?pst:cst;return t.test(sst(e))}Gce.exports=hst});var Wce=E((Bxt,Vce)=>{"use strict";function mst(e,t){return e?.[t]}Vce.exports=mst});var px=E((Fxt,Kce)=>{"use strict";var gst=zce(),yst=Wce();function _st(e,t){var r=yst(e,t);return gst(r)?r:void 0}Kce.exports=_st});var Xce=E((qxt,Yce)=>{"use strict";var bst=px(),Est=(function(){try{var e=bst(Object,"defineProperty");return e({},"",{}),e}catch{}})();Yce.exports=Est});var Zce=E((jxt,Qce)=>{"use strict";var Jce=Xce();function wst(e,t,r){t=="__proto__"&&Jce?Jce(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r}Qce.exports=wst});var sL=E((Uxt,eue)=>{"use strict";function Sst(e,t){return e===t||e!==e&&t!==t}eue.exports=Sst});var rue=E((Hxt,tue)=>{"use strict";var vst=Zce(),Cst=sL(),xst=Object.prototype,Tst=xst.hasOwnProperty;function Ast(e,t,r){var n=e[t];(!(Tst.call(e,t)&&Cst(n,r))||r===void 0&&!(t in e))&&vst(e,t,r)}tue.exports=Ast});var hx=E(($xt,nue)=>{"use strict";var Rst=Array.isArray;nue.exports=Rst});var oue=E((Gxt,iue)=>{"use strict";function Pst(e){return e!=null&&typeof e=="object"}iue.exports=Pst});var mx=E((zxt,sue)=>{"use strict";var Ost=iL(),Ist=oue(),Dst="[object Symbol]";function kst(e){return typeof e=="symbol"||Ist(e)&&Ost(e)==Dst}sue.exports=kst});var cue=E((Vxt,aue)=>{"use strict";var Nst=hx(),Mst=mx(),Lst=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Bst=/^\w*$/;function Fst(e,t){if(Nst(e))return!1;var r=typeof e;return r=="number"||r=="symbol"||r=="boolean"||e==null||Mst(e)?!0:Bst.test(e)||!Lst.test(e)||t!=null&&e in Object(t)}aue.exports=Fst});var Fg=E((Wxt,uue)=>{"use strict";var qst=px(),jst=qst(Object,"create");uue.exports=jst});var due=E((Kxt,fue)=>{"use strict";var lue=Fg();function Ust(){this.__data__=lue?lue(null):{},this.size=0}fue.exports=Ust});var hue=E((Yxt,pue)=>{"use strict";function Hst(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}pue.exports=Hst});var gue=E((Xxt,mue)=>{"use strict";var $st=Fg(),Gst="__lodash_hash_undefined__",zst=Object.prototype,Vst=zst.hasOwnProperty;function Wst(e){var t=this.__data__;if($st){var r=t[e];return r===Gst?void 0:r}return Vst.call(t,e)?t[e]:void 0}mue.exports=Wst});var _ue=E((Jxt,yue)=>{"use strict";var Kst=Fg(),Yst=Object.prototype,Xst=Yst.hasOwnProperty;function Jst(e){var t=this.__data__;return Kst?t[e]!==void 0:Xst.call(t,e)}yue.exports=Jst});var Eue=E((Qxt,bue)=>{"use strict";var Qst=Fg(),Zst="__lodash_hash_undefined__";function eat(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=Qst&&t===void 0?Zst:t,this}bue.exports=eat});var Sue=E((Zxt,wue)=>{"use strict";var tat=due(),rat=hue(),nat=gue(),iat=_ue(),oat=Eue();function Gd(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}Gd.prototype.clear=tat;Gd.prototype.delete=rat;Gd.prototype.get=nat;Gd.prototype.has=iat;Gd.prototype.set=oat;wue.exports=Gd});var Cue=E((eTt,vue)=>{"use strict";function sat(){this.__data__=[],this.size=0}vue.exports=sat});var qg=E((tTt,xue)=>{"use strict";var aat=sL();function cat(e,t){for(var r=e.length;r--;)if(aat(e[r][0],t))return r;return-1}xue.exports=cat});var Aue=E((rTt,Tue)=>{"use strict";var uat=qg(),lat=Array.prototype,fat=lat.splice;function dat(e){var t=this.__data__,r=uat(t,e);if(r<0)return!1;var n=t.length-1;return r==n?t.pop():fat.call(t,r,1),--this.size,!0}Tue.exports=dat});var Pue=E((nTt,Rue)=>{"use strict";var pat=qg();function hat(e){var t=this.__data__,r=pat(t,e);return r<0?void 0:t[r][1]}Rue.exports=hat});var Iue=E((iTt,Oue)=>{"use strict";var mat=qg();function gat(e){return mat(this.__data__,e)>-1}Oue.exports=gat});var kue=E((oTt,Due)=>{"use strict";var yat=qg();function _at(e,t){var r=this.__data__,n=yat(r,e);return n<0?(++this.size,r.push([e,t])):r[n][1]=t,this}Due.exports=_at});var Mue=E((sTt,Nue)=>{"use strict";var bat=Cue(),Eat=Aue(),wat=Pue(),Sat=Iue(),vat=kue();function zd(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}zd.prototype.clear=bat;zd.prototype.delete=Eat;zd.prototype.get=wat;zd.prototype.has=Sat;zd.prototype.set=vat;Nue.exports=zd});var Bue=E((aTt,Lue)=>{"use strict";var Cat=px(),xat=lx(),Tat=Cat(xat,"Map");Lue.exports=Tat});var jue=E((cTt,que)=>{"use strict";var Fue=Sue(),Aat=Mue(),Rat=Bue();function Pat(){this.size=0,this.__data__={hash:new Fue,map:new(Rat||Aat),string:new Fue}}que.exports=Pat});var Hue=E((uTt,Uue)=>{"use strict";function Oat(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}Uue.exports=Oat});var jg=E((lTt,$ue)=>{"use strict";var Iat=Hue();function Dat(e,t){var r=e.__data__;return Iat(t)?r[typeof t=="string"?"string":"hash"]:r.map}$ue.exports=Dat});var zue=E((fTt,Gue)=>{"use strict";var kat=jg();function Nat(e){var t=kat(this,e).delete(e);return this.size-=t?1:0,t}Gue.exports=Nat});var Wue=E((dTt,Vue)=>{"use strict";var Mat=jg();function Lat(e){return Mat(this,e).get(e)}Vue.exports=Lat});var Yue=E((pTt,Kue)=>{"use strict";var Bat=jg();function Fat(e){return Bat(this,e).has(e)}Kue.exports=Fat});var Jue=E((hTt,Xue)=>{"use strict";var qat=jg();function jat(e,t){var r=qat(this,e),n=r.size;return r.set(e,t),this.size+=r.size==n?0:1,this}Xue.exports=jat});var Zue=E((mTt,Que)=>{"use strict";var Uat=jue(),Hat=zue(),$at=Wue(),Gat=Yue(),zat=Jue();function Vd(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}Vd.prototype.clear=Uat;Vd.prototype.delete=Hat;Vd.prototype.get=$at;Vd.prototype.has=Gat;Vd.prototype.set=zat;Que.exports=Vd});var rle=E((gTt,tle)=>{"use strict";var ele=Zue(),Vat="Expected a function";function aL(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(Vat);var r=function(){var n=arguments,i=t?t.apply(this,n):n[0],o=r.cache;if(o.has(i))return o.get(i);var s=e.apply(this,n);return r.cache=o.set(i,s)||o,s};return r.cache=new(aL.Cache||ele),r}aL.Cache=ele;tle.exports=aL});var ile=E((yTt,nle)=>{"use strict";var Wat=rle(),Kat=500;function Yat(e){var t=Wat(e,function(n){return r.size===Kat&&r.clear(),n}),r=t.cache;return t}nle.exports=Yat});var sle=E((_Tt,ole)=>{"use strict";var Xat=ile(),Jat=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Qat=/\\(\\)?/g,Zat=Xat(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(""),e.replace(Jat,function(r,n,i,o){t.push(i?o.replace(Qat,"$1"):n||r)}),t});ole.exports=Zat});var cle=E((bTt,ale)=>{"use strict";function ect(e,t){for(var r=-1,n=e==null?0:e.length,i=Array(n);++r<n;)i[r]=t(e[r],r,e);return i}ale.exports=ect});var hle=E((ETt,ple)=>{"use strict";var ule=fx(),tct=cle(),rct=hx(),nct=mx(),ict=1/0,lle=ule?ule.prototype:void 0,fle=lle?lle.toString:void 0;function dle(e){if(typeof e=="string")return e;if(rct(e))return tct(e,dle)+"";if(nct(e))return fle?fle.call(e):"";var t=e+"";return t=="0"&&1/e==-ict?"-0":t}ple.exports=dle});var gle=E((wTt,mle)=>{"use strict";var oct=hle();function sct(e){return e==null?"":oct(e)}mle.exports=sct});var _le=E((STt,yle)=>{"use strict";var act=hx(),cct=cue(),uct=sle(),lct=gle();function fct(e,t){return act(e)?e:cct(e,t)?[e]:uct(lct(e))}yle.exports=fct});var Ele=E((vTt,ble)=>{"use strict";var dct=9007199254740991,pct=/^(?:0|[1-9]\d*)$/;function hct(e,t){var r=typeof e;return t=t??dct,!!t&&(r=="number"||r!="symbol"&&pct.test(e))&&e>-1&&e%1==0&&e<t}ble.exports=hct});var Sle=E((CTt,wle)=>{"use strict";var mct=mx(),gct=1/0;function yct(e){if(typeof e=="string"||mct(e))return e;var t=e+"";return t=="0"&&1/e==-gct?"-0":t}wle.exports=yct});var xle=E((xTt,Cle)=>{"use strict";var _ct=rue(),bct=_le(),Ect=Ele(),vle=dx(),wct=Sle();function Sct(e,t,r,n){if(!vle(e))return e;t=bct(t,e);for(var i=-1,o=t.length,s=o-1,a=e;a!=null&&++i<o;){var c=wct(t[i]),u=r;if(c==="__proto__"||c==="constructor"||c==="prototype")return e;if(i!=s){var l=a[c];u=n?n(l,c,a):void 0,u===void 0&&(u=vle(l)?l:Ect(t[i+1])?[]:{})}_ct(a,c,u),a=a[c]}return e}Cle.exports=Sct});var Ale=E((TTt,Tle)=>{"use strict";var vct=xle();function Cct(e,t,r){return e==null?e:vct(e,t,r)}Tle.exports=Cct});var Ole=E(Hg=>{"use strict";var Ple=Hg&&Hg.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(Hg,"__esModule",{value:!0});Hg.default=Rct;var xct=Ple(nL()),Tct=Ple(Ale()),Act=/^[-+]?[0-9]*\.?[0-9]+([eE][-+]?[0-9]+)?$/;function Rct(e,t){for(var r=[],n=0,i=e.length;n<i;n++){var o=Pct(e[n],t,n);o&&r.push(o)}return r}function Pct(e,t,r){if(t.parseParam.checkColumn&&t.parseRuntime.headers&&e.length!==t.parseRuntime.headers.length)throw xct.default.column_mismatched(t.parseRuntime.parsedLineNumber+r);var n=t.parseRuntime.headers||[],i=Oct(e,n,t);return i||null}function Oct(e,t,r){for(var n=!1,i={},o=0,s=e.length;o<s;o++){var a=e[o];if(!(r.parseParam.ignoreEmpty&&a==="")){n=!0;var c=t[o];(!c||c==="")&&(c=t[o]="field"+(o+1));var u=Dct(c,o,r);if(u){var l=u(a,c,i,e,o);l!==void 0&&Rle(i,c,l,r,o)}else{if(r.parseParam.checkType){var d=Nct(a,c,o,r);a=d(a)}a!==void 0&&Rle(i,c,a,r,o)}}}return n?i:null}var Ict={string:Ug,number:uL,omit:function(){}};function Dct(e,t,r){if(r.parseRuntime.columnConv[t]!==void 0)return r.parseRuntime.columnConv[t];var n=r.parseParam.colParser[e];if(n===void 0)return r.parseRuntime.columnConv[t]=null;if(typeof n=="object"&&(n=n.cellParser||"string"),typeof n=="string"){n=n.trim().toLowerCase();var i=Ict[n];return i?r.parseRuntime.columnConv[t]=i:r.parseRuntime.columnConv[t]=null}else return typeof n=="function"?r.parseRuntime.columnConv[t]=n:r.parseRuntime.columnConv[t]=null}function Rle(e,t,r,n,i){if(!n.parseRuntime.columnValueSetter[i])if(n.parseParam.flatKeys)n.parseRuntime.columnValueSetter[i]=cL;else if(t.indexOf(".")>-1){for(var o=t.split("."),s=!0;o.length>0;){var a=o.shift();if(a.length===0){s=!1;break}}!s||n.parseParam.colParser[t]&&n.parseParam.colParser[t].flat?n.parseRuntime.columnValueSetter[i]=cL:n.parseRuntime.columnValueSetter[i]=kct}else n.parseRuntime.columnValueSetter[i]=cL;n.parseParam.nullObject===!0&&r==="null"&&(r=null),n.parseRuntime.columnValueSetter[i](e,t,r)}function cL(e,t,r){e[t]=r}function kct(e,t,r){(0,Tct.default)(e,t,r)}function Nct(e,t,r,n){return n.parseRuntime.headerType[r]?n.parseRuntime.headerType[r]:t.indexOf("number#!")>-1?n.parseRuntime.headerType[r]=uL:t.indexOf("string#!")>-1?n.parseRuntime.headerType[r]=Ug:n.parseParam.checkType?n.parseRuntime.headerType[r]=Mct:n.parseRuntime.headerType[r]=Ug}function uL(e){var t=parseFloat(e);return isNaN(t)?e:t}function Ug(e){return e.toString()}function Mct(e){var t=e.trim();return t===""?Ug(e):Act.test(t)?uL(e):t.length===5&&t.toLowerCase()==="false"||t.length===4&&t.toLowerCase()==="true"?Lct(e):t[0]==="{"&&t[t.length-1]==="}"||t[0]==="["&&t[t.length-1]==="]"?Bct(e):Ug(e)}function Lct(e){var t=e.trim();return!(t.length===5&&t.toLowerCase()==="false")}function Bct(e){try{return JSON.parse(e)}catch{return e}}});var kle=E(Rc=>{"use strict";var Fct=Rc&&Rc.__extends||(function(){var e=function(t,r){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(n[o]=i[o])},e(t,r)};return function(t,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");e(t,r);function n(){this.constructor=t}t.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})(),lL=Rc&&Rc.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(Rc,"__esModule",{value:!0});Rc.ProcessorLocal=void 0;var qct=yce(),jct=_ce(),Ile=lL(ux()),Uct=bce(),$g=rL(),Hct=Ece(),$ct=lL(Ole()),Gct=lL(nL()),zct=(function(e){Fct(t,e);function t(){var r=e!==null&&e.apply(this,arguments)||this;return r.rowSplit=new Hct.RowSplit(r.converter),r.eolEmitted=!1,r._needEmitEol=void 0,r.headEmitted=!1,r._needEmitHead=void 0,r}return t.prototype.flush=function(){var r=this;if(this.runtime.csvLineBuffer&&this.runtime.csvLineBuffer.length>0){var n=this.runtime.csvLineBuffer;return this.runtime.csvLineBuffer=void 0,this.process(n,!0).then(function(i){return r.runtime.csvLineBuffer&&r.runtime.csvLineBuffer.length>0?Promise.reject(Gct.default.unclosed_quote(r.runtime.parsedLineNumber,r.runtime.csvLineBuffer.toString())):Promise.resolve(i)})}else return Promise.resolve([])},t.prototype.destroy=function(){return Promise.resolve()},Object.defineProperty(t.prototype,"needEmitEol",{get:function(){return this._needEmitEol===void 0&&(this._needEmitEol=this.converter.listeners("eol").length>0),this._needEmitEol},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"needEmitHead",{get:function(){return this._needEmitHead===void 0&&(this._needEmitHead=this.converter.listeners("header").length>0),this._needEmitHead},enumerable:!1,configurable:!0}),t.prototype.process=function(r,n){var i=this;n===void 0&&(n=!1);var o;return n?o=r.toString():o=(0,jct.prepareData)(r,this.converter.parseRuntime),Promise.resolve().then(function(){return i.runtime.preRawDataHook?i.runtime.preRawDataHook(o):o}).then(function(s){return s&&s.length>0?i.processCSV(s,n):Promise.resolve([])})},t.prototype.processCSV=function(r,n){var i=this,o=this.params,s=this.runtime;s.eol||(0,Ile.default)(r,s),this.needEmitEol&&!this.eolEmitted&&s.eol&&(this.converter.emit("eol",s.eol),this.eolEmitted=!0),o.ignoreEmpty&&!s.started&&(r=(0,$g.trimLeft)(r));var a=(0,Uct.stringToLines)(r,s);if(n?(a.lines.push(a.partial),a.partial=""):this.prependLeftBuf((0,$g.bufFromString)(a.partial)),a.lines.length>0){var c=void 0;return s.preFileLineHook?c=this.runPreLineHook(a.lines):c=Promise.resolve(a.lines),c.then(function(u){return!s.started&&!i.runtime.headers?i.processDataWithHead(u):i.processCSVBody(u)})}else return Promise.resolve([])},t.prototype.processDataWithHead=function(r){if(this.params.noheader)this.params.headers?this.runtime.headers=this.params.headers:this.runtime.headers=[];else{for(var n="",i=[];r.length;){var o=n+r.shift(),s=this.rowSplit.parse(o);if(s.closed){i=s.cells,n="";break}else n=o+(0,Ile.default)(o,this.runtime)}if(this.prependLeftBuf((0,$g.bufFromString)(n)),i.length===0)return[];this.params.headers?this.runtime.headers=this.params.headers:this.runtime.headers=i}return(this.runtime.needProcessIgnoreColumn||this.runtime.needProcessIncludeColumn)&&this.filterHeader(),this.needEmitHead&&!this.headEmitted&&(this.converter.emit("header",this.runtime.headers),this.headEmitted=!0),this.processCSVBody(r)},t.prototype.filterHeader=function(){if(this.runtime.selectedColumns=[],this.runtime.headers){for(var r=this.runtime.headers,n=0;n<r.length;n++)if(this.params.ignoreColumns)if(this.params.ignoreColumns.test(r[n]))if(this.params.includeColumns&&this.params.includeColumns.test(r[n]))this.runtime.selectedColumns.push(n);else continue;else this.runtime.selectedColumns.push(n);else this.params.includeColumns?this.params.includeColumns.test(r[n])&&this.runtime.selectedColumns.push(n):this.runtime.selectedColumns.push(n);this.runtime.headers=(0,$g.filterArray)(this.runtime.headers,this.runtime.selectedColumns)}},t.prototype.processCSVBody=function(r){if(this.params.output==="line")return r;var n=this.rowSplit.parseMultiLines(r);return this.prependLeftBuf((0,$g.bufFromString)(n.partial)),this.params.output==="csv"?n.rowsCells:(0,$ct.default)(n.rowsCells,this.converter)},t.prototype.prependLeftBuf=function(r){r&&(this.runtime.csvLineBuffer?this.runtime.csvLineBuffer=Buffer.concat([r,this.runtime.csvLineBuffer]):this.runtime.csvLineBuffer=r)},t.prototype.runPreLineHook=function(r){var n=this;return new Promise(function(i,o){Dle(r,n.runtime,0,function(s){s?o(s):i(r)})})},t})(qct.Processor);Rc.ProcessorLocal=zct;function Dle(e,t,r,n){if(r>=e.length)n();else if(t.preFileLineHook){var i=e[r],o=t.preFileLineHook(i,t.parsedLineNumber+r);if(r++,o&&o.then)o.then(function(s){e[r-1]=s,Dle(e,t,r,n)});else{for(e[r-1]=o;r<e.length;)e[r]=t.preFileLineHook(e[r],t.parsedLineNumber+r),r++;n()}}else n()}});var Mle=E(yx=>{"use strict";Object.defineProperty(yx,"__esModule",{value:!0});yx.Result=void 0;var gx=require("os"),Vct=(function(){function e(t){this.converter=t,this.finalResult=[]}return Object.defineProperty(e.prototype,"needEmitLine",{get:function(){return!!this.converter.parseRuntime.subscribe&&!!this.converter.parseRuntime.subscribe.onNext||this.needPushDownstream},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"needPushDownstream",{get:function(){return this._needPushDownstream===void 0&&(this._needPushDownstream=this.converter.listeners("data").length>0||this.converter.listeners("readable").length>0),this._needPushDownstream},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"needEmitAll",{get:function(){return!!this.converter.parseRuntime.then&&this.converter.parseParam.needEmitAll},enumerable:!1,configurable:!0}),e.prototype.processResult=function(t){var r=this,n=this.converter.parseRuntime.parsedLineNumber;return this.needPushDownstream&&this.converter.parseParam.downstreamFormat==="array"&&n===0&&Wd(this.converter,"["+gx.EOL),new Promise(function(i,o){r.needEmitLine?Nle(t,r.converter,0,r.needPushDownstream,function(s){s?o(s):(r.appendFinalResult(t),i(void 0))}):(r.appendFinalResult(t),i(void 0))})},e.prototype.appendFinalResult=function(t){this.needEmitAll&&(this.finalResult=this.finalResult.concat(t)),this.converter.parseRuntime.parsedLineNumber+=t.length},e.prototype.processError=function(t){this.converter.parseRuntime.subscribe&&this.converter.parseRuntime.subscribe.onError&&this.converter.parseRuntime.subscribe.onError(t),this.converter.parseRuntime.then&&this.converter.parseRuntime.then.onrejected&&this.converter.parseRuntime.then.onrejected(t)},e.prototype.endProcess=function(){this.converter.parseRuntime.then&&this.converter.parseRuntime.then.onfulfilled&&(this.needEmitAll?this.converter.parseRuntime.then.onfulfilled(this.finalResult):this.converter.parseRuntime.then.onfulfilled([])),this.converter.parseRuntime.subscribe&&this.converter.parseRuntime.subscribe.onCompleted&&this.converter.parseRuntime.subscribe.onCompleted(),this.needPushDownstream&&this.converter.parseParam.downstreamFormat==="array"&&Wd(this.converter,"]"+gx.EOL)},e})();yx.Result=Vct;function Nle(e,t,r,n,i){if(r>=e.length)i();else if(t.parseRuntime.subscribe&&t.parseRuntime.subscribe.onNext){var o=t.parseRuntime.subscribe.onNext,s=e[r],a=o(s,t.parseRuntime.parsedLineNumber+r);if(r++,a&&a.then)a.then(function(){Wct(e,o,t,r,n,i,s)},i);else{for(n&&Wd(t,s);r<e.length;){var c=e[r];o(c,t.parseRuntime.parsedLineNumber+r),r++,n&&Wd(t,c)}i()}}else{if(n)for(;r<e.length;){var c=e[r++];Wd(t,c)}i()}}function Wct(e,t,r,n,i,o,s){i&&Wd(r,s),Nle(e,r,n,i,o)}function Wd(e,t){if(typeof t=="object"&&!e.options.objectMode){var r=JSON.stringify(t);e.push(r+(e.parseParam.downstreamFormat==="array"?","+gx.EOL:gx.EOL),"utf8")}else e.push(t)}});var Ble=E(Kd=>{"use strict";var Kct=Kd&&Kd.__extends||(function(){var e=function(t,r){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(n[o]=i[o])},e(t,r)};return function(t,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");e(t,r);function n(){this.constructor=t}t.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})();Object.defineProperty(Kd,"__esModule",{value:!0});Kd.Converter=void 0;var Lle=require("stream"),Yct=mce(),Xct=gce(),Jct=kle(),Qct=Mle(),Zct=(function(e){Kct(t,e);function t(r,n){n===void 0&&(n={});var i=e.call(this,n)||this;return i.options=n,i.params=(0,Yct.mergeParams)(r),i.runtime=(0,Xct.initParseRuntime)(i),i.result=new Qct.Result(i),i.processor=new Jct.ProcessorLocal(i),i.once("error",function(o){setImmediate(function(){i.result.processError(o),i.emit("done",o)})}),i.once("done",function(){i.processor.destroy()}),i}return t.prototype.preRawData=function(r){return this.runtime.preRawDataHook=r,this},t.prototype.preFileLine=function(r){return this.runtime.preFileLineHook=r,this},t.prototype.subscribe=function(r,n,i){return this.parseRuntime.subscribe={onNext:r,onError:n,onCompleted:i},this},t.prototype.fromFile=function(r,n){var i=this,o=require("fs");return o.exists(r,function(s){if(s){var a=o.createReadStream(r,n);a.pipe(i)}else i.emit("error",new Error("File does not exist at ".concat(r,". Check to make sure the file path to your csv is correct.")))}),this},t.prototype.fromStream=function(r){return r.pipe(this),this},t.prototype.fromString=function(r){var n=r.toString(),i=new Lle.Readable,o=0;return i._read=function(s){if(o>=r.length)this.push(null);else{var a=r.substring(o,o+s);this.push(a),o+=s}},this.fromStream(i)},t.prototype.then=function(r,n){var i=this;return new Promise(function(o,s){i.parseRuntime.then={onfulfilled:function(a){o(r?r(a):a)},onrejected:function(a){n?o(n(a)):s(a)}}})},Object.defineProperty(t.prototype,"parseParam",{get:function(){return this.params},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"parseRuntime",{get:function(){return this.runtime},enumerable:!1,configurable:!0}),t.prototype._transform=function(r,n,i){var o=this;this.processor.process(r).then(function(s){if(s.length>0)return o.runtime.started=!0,o.result.processResult(s)}).then(function(){o.emit("drained"),i()},function(s){o.runtime.hasError=!0,o.runtime.error=s,o.emit("error",s),i()})},t.prototype._flush=function(r){var n=this;this.processor.flush().then(function(i){if(i.length>0)return n.result.processResult(i)}).then(function(){n.processEnd(r)},function(i){n.emit("error",i),r()})},t.prototype.processEnd=function(r){this.result.endProcess(),this.emit("done"),r()},Object.defineProperty(t.prototype,"parsedLineNumber",{get:function(){return this.runtime.parsedLineNumber},enumerable:!1,configurable:!0}),t})(Lle.Transform);Kd.Converter=Zct});var jle=E((ITt,qle)=>{"use strict";var Fle=Ble(),_x=function(e,t){return new Fle.Converter(e,t)};_x.csv=_x;_x.Converter=Fle.Converter;qle.exports=_x});var bx=E(fL=>{"use strict";(function(){fL.defaults={"0.1":{explicitCharkey:!1,trim:!0,normalize:!0,normalizeTags:!1,attrkey:"@",charkey:"#",explicitArray:!1,ignoreAttrs:!1,mergeAttrs:!1,explicitRoot:!1,validator:null,xmlns:!1,explicitChildren:!1,childkey:"@@",charsAsChildren:!1,includeWhiteChars:!1,async:!1,strict:!0,attrNameProcessors:null,attrValueProcessors:null,tagNameProcessors:null,valueProcessors:null,emptyTag:""},"0.2":{explicitCharkey:!1,trim:!1,normalize:!1,normalizeTags:!1,attrkey:"$",charkey:"_",explicitArray:!0,ignoreAttrs:!1,mergeAttrs:!1,explicitRoot:!0,validator:null,xmlns:!1,explicitChildren:!1,preserveChildrenOrder:!1,childkey:"$$",charsAsChildren:!1,includeWhiteChars:!1,async:!1,strict:!0,attrNameProcessors:null,attrValueProcessors:null,tagNameProcessors:null,valueProcessors:null,rootName:"root",xmldec:{version:"1.0",encoding:"UTF-8",standalone:!0},doctype:null,renderOpts:{pretty:!0,indent:" ",newline:`
|
|
278
|
+
`},headless:!1,chunkSize:1e4,emptyTag:"",cdata:!1}}}).call(fL)});var ds=E((Ule,Pc)=>{"use strict";(function(){var e,t,r,n,i,o,s,a=[].slice,c={}.hasOwnProperty;e=function(){var u,l,d,h,f,p;if(p=arguments[0],f=2<=arguments.length?a.call(arguments,1):[],i(Object.assign))Object.assign.apply(null,arguments);else for(u=0,d=f.length;u<d;u++)if(h=f[u],h!=null)for(l in h)c.call(h,l)&&(p[l]=h[l]);return p},i=function(u){return!!u&&Object.prototype.toString.call(u)==="[object Function]"},o=function(u){var l;return!!u&&((l=typeof u)=="function"||l==="object")},r=function(u){return i(Array.isArray)?Array.isArray(u):Object.prototype.toString.call(u)==="[object Array]"},n=function(u){var l;if(r(u))return!u.length;for(l in u)if(c.call(u,l))return!1;return!0},s=function(u){var l,d;return o(u)&&(d=Object.getPrototypeOf(u))&&(l=d.constructor)&&typeof l=="function"&&l instanceof l&&Function.prototype.toString.call(l)===Function.prototype.toString.call(Object)},t=function(u){return i(u.valueOf)?u.valueOf():u},Pc.exports.assign=e,Pc.exports.isFunction=i,Pc.exports.isObject=o,Pc.exports.isArray=r,Pc.exports.isEmpty=n,Pc.exports.isPlainObject=s,Pc.exports.getValue=t}).call(Ule)});var dL=E((Hle,$le)=>{"use strict";(function(){var e;$le.exports=e=(function(){function t(){}return t.prototype.hasFeature=function(r,n){return!0},t.prototype.createDocumentType=function(r,n,i){throw new Error("This DOM method is not implemented.")},t.prototype.createDocument=function(r,n,i){throw new Error("This DOM method is not implemented.")},t.prototype.createHTMLDocument=function(r){throw new Error("This DOM method is not implemented.")},t.prototype.getFeature=function(r,n){throw new Error("This DOM method is not implemented.")},t})()}).call(Hle)});var Vle=E((Gle,zle)=>{"use strict";(function(){var e;zle.exports=e=(function(){function t(){}return t.prototype.handleError=function(r){throw new Error(r)},t})()}).call(Gle)});var Yle=E((Wle,Kle)=>{"use strict";(function(){var e;Kle.exports=e=(function(){function t(r){this.arr=r||[]}return Object.defineProperty(t.prototype,"length",{get:function(){return this.arr.length}}),t.prototype.item=function(r){return this.arr[r]||null},t.prototype.contains=function(r){return this.arr.indexOf(r)!==-1},t})()}).call(Wle)});var Qle=E((Xle,Jle)=>{"use strict";(function(){var e,t,r;t=Vle(),r=Yle(),Jle.exports=e=(function(){function n(){var i;this.defaultParams={"canonical-form":!1,"cdata-sections":!1,comments:!1,"datatype-normalization":!1,"element-content-whitespace":!0,entities:!0,"error-handler":new t,infoset:!0,"validate-if-schema":!1,namespaces:!0,"namespace-declarations":!0,"normalize-characters":!1,"schema-location":"","schema-type":"","split-cdata-sections":!0,validate:!1,"well-formed":!0},this.params=i=Object.create(this.defaultParams)}return Object.defineProperty(n.prototype,"parameterNames",{get:function(){return new r(Object.keys(this.defaultParams))}}),n.prototype.getParameter=function(i){return this.params.hasOwnProperty(i)?this.params[i]:null},n.prototype.canSetParameter=function(i,o){return!0},n.prototype.setParameter=function(i,o){return o!=null?this.params[i]=o:delete this.params[i]},n})()}).call(Xle)});var wr=E((Zle,efe)=>{"use strict";(function(){efe.exports={Element:1,Attribute:2,Text:3,CData:4,EntityReference:5,EntityDeclaration:6,ProcessingInstruction:7,Comment:8,Document:9,DocType:10,DocumentFragment:11,NotationDeclaration:12,Declaration:201,Raw:202,AttributeDeclaration:203,ElementDeclaration:204,Dummy:205}}).call(Zle)});var pL=E((tfe,rfe)=>{"use strict";(function(){var e,t,r;e=wr(),r=Ri(),rfe.exports=t=(function(){function n(i,o,s){if(this.parent=i,this.parent&&(this.options=this.parent.options,this.stringify=this.parent.stringify),o==null)throw new Error("Missing attribute name. "+this.debugInfo(o));this.name=this.stringify.name(o),this.value=this.stringify.attValue(s),this.type=e.Attribute,this.isId=!1,this.schemaTypeInfo=null}return Object.defineProperty(n.prototype,"nodeType",{get:function(){return this.type}}),Object.defineProperty(n.prototype,"ownerElement",{get:function(){return this.parent}}),Object.defineProperty(n.prototype,"textContent",{get:function(){return this.value},set:function(i){return this.value=i||""}}),Object.defineProperty(n.prototype,"namespaceURI",{get:function(){return""}}),Object.defineProperty(n.prototype,"prefix",{get:function(){return""}}),Object.defineProperty(n.prototype,"localName",{get:function(){return this.name}}),Object.defineProperty(n.prototype,"specified",{get:function(){return!0}}),n.prototype.clone=function(){return Object.create(this)},n.prototype.toString=function(i){return this.options.writer.attribute(this,this.options.writer.filterOptions(i))},n.prototype.debugInfo=function(i){return i=i||this.name,i==null?"parent: <"+this.parent.name+">":"attribute: {"+i+"}, parent: <"+this.parent.name+">"},n.prototype.isEqualNode=function(i){return!(i.namespaceURI!==this.namespaceURI||i.prefix!==this.prefix||i.localName!==this.localName||i.value!==this.value)},n})()}).call(tfe)});var Ex=E((nfe,ife)=>{"use strict";(function(){var e;ife.exports=e=(function(){function t(r){this.nodes=r}return Object.defineProperty(t.prototype,"length",{get:function(){return Object.keys(this.nodes).length||0}}),t.prototype.clone=function(){return this.nodes=null},t.prototype.getNamedItem=function(r){return this.nodes[r]},t.prototype.setNamedItem=function(r){var n;return n=this.nodes[r.nodeName],this.nodes[r.nodeName]=r,n||null},t.prototype.removeNamedItem=function(r){var n;return n=this.nodes[r],delete this.nodes[r],n||null},t.prototype.item=function(r){return this.nodes[Object.keys(this.nodes)[r]]||null},t.prototype.getNamedItemNS=function(r,n){throw new Error("This DOM method is not implemented.")},t.prototype.setNamedItemNS=function(r){throw new Error("This DOM method is not implemented.")},t.prototype.removeNamedItemNS=function(r,n){throw new Error("This DOM method is not implemented.")},t})()}).call(nfe)});var wx=E((ofe,sfe)=>{"use strict";(function(){var e,t,r,n,i,o,s,a,c,u=function(d,h){for(var f in h)l.call(h,f)&&(d[f]=h[f]);function p(){this.constructor=d}return p.prototype=h.prototype,d.prototype=new p,d.__super__=h.prototype,d},l={}.hasOwnProperty;c=ds(),a=c.isObject,s=c.isFunction,o=c.getValue,i=Ri(),e=wr(),t=pL(),n=Ex(),sfe.exports=r=(function(d){u(h,d);function h(f,p,m){var _,w,R,v;if(h.__super__.constructor.call(this,f),p==null)throw new Error("Missing element name. "+this.debugInfo());if(this.name=this.stringify.name(p),this.type=e.Element,this.attribs={},this.schemaTypeInfo=null,m!=null&&this.attribute(m),f.type===e.Document&&(this.isRoot=!0,this.documentObject=f,f.rootObject=this,f.children)){for(v=f.children,w=0,R=v.length;w<R;w++)if(_=v[w],_.type===e.DocType){_.name=this.name;break}}}return Object.defineProperty(h.prototype,"tagName",{get:function(){return this.name}}),Object.defineProperty(h.prototype,"namespaceURI",{get:function(){return""}}),Object.defineProperty(h.prototype,"prefix",{get:function(){return""}}),Object.defineProperty(h.prototype,"localName",{get:function(){return this.name}}),Object.defineProperty(h.prototype,"id",{get:function(){throw new Error("This DOM method is not implemented."+this.debugInfo())}}),Object.defineProperty(h.prototype,"className",{get:function(){throw new Error("This DOM method is not implemented."+this.debugInfo())}}),Object.defineProperty(h.prototype,"classList",{get:function(){throw new Error("This DOM method is not implemented."+this.debugInfo())}}),Object.defineProperty(h.prototype,"attributes",{get:function(){return(!this.attributeMap||!this.attributeMap.nodes)&&(this.attributeMap=new n(this.attribs)),this.attributeMap}}),h.prototype.clone=function(){var f,p,m,_;m=Object.create(this),m.isRoot&&(m.documentObject=null),m.attribs={},_=this.attribs;for(p in _)l.call(_,p)&&(f=_[p],m.attribs[p]=f.clone());return m.children=[],this.children.forEach(function(w){var R;return R=w.clone(),R.parent=m,m.children.push(R)}),m},h.prototype.attribute=function(f,p){var m,_;if(f!=null&&(f=o(f)),a(f))for(m in f)l.call(f,m)&&(_=f[m],this.attribute(m,_));else s(p)&&(p=p.apply()),this.options.keepNullAttributes&&p==null?this.attribs[f]=new t(this,f,""):p!=null&&(this.attribs[f]=new t(this,f,p));return this},h.prototype.removeAttribute=function(f){var p,m,_;if(f==null)throw new Error("Missing attribute name. "+this.debugInfo());if(f=o(f),Array.isArray(f))for(m=0,_=f.length;m<_;m++)p=f[m],delete this.attribs[p];else delete this.attribs[f];return this},h.prototype.toString=function(f){return this.options.writer.element(this,this.options.writer.filterOptions(f))},h.prototype.att=function(f,p){return this.attribute(f,p)},h.prototype.a=function(f,p){return this.attribute(f,p)},h.prototype.getAttribute=function(f){return this.attribs.hasOwnProperty(f)?this.attribs[f].value:null},h.prototype.setAttribute=function(f,p){throw new Error("This DOM method is not implemented."+this.debugInfo())},h.prototype.getAttributeNode=function(f){return this.attribs.hasOwnProperty(f)?this.attribs[f]:null},h.prototype.setAttributeNode=function(f){throw new Error("This DOM method is not implemented."+this.debugInfo())},h.prototype.removeAttributeNode=function(f){throw new Error("This DOM method is not implemented."+this.debugInfo())},h.prototype.getElementsByTagName=function(f){throw new Error("This DOM method is not implemented."+this.debugInfo())},h.prototype.getAttributeNS=function(f,p){throw new Error("This DOM method is not implemented."+this.debugInfo())},h.prototype.setAttributeNS=function(f,p,m){throw new Error("This DOM method is not implemented."+this.debugInfo())},h.prototype.removeAttributeNS=function(f,p){throw new Error("This DOM method is not implemented."+this.debugInfo())},h.prototype.getAttributeNodeNS=function(f,p){throw new Error("This DOM method is not implemented."+this.debugInfo())},h.prototype.setAttributeNodeNS=function(f){throw new Error("This DOM method is not implemented."+this.debugInfo())},h.prototype.getElementsByTagNameNS=function(f,p){throw new Error("This DOM method is not implemented."+this.debugInfo())},h.prototype.hasAttribute=function(f){return this.attribs.hasOwnProperty(f)},h.prototype.hasAttributeNS=function(f,p){throw new Error("This DOM method is not implemented."+this.debugInfo())},h.prototype.setIdAttribute=function(f,p){return this.attribs.hasOwnProperty(f)?this.attribs[f].isId:p},h.prototype.setIdAttributeNS=function(f,p,m){throw new Error("This DOM method is not implemented."+this.debugInfo())},h.prototype.setIdAttributeNode=function(f,p){throw new Error("This DOM method is not implemented."+this.debugInfo())},h.prototype.getElementsByTagName=function(f){throw new Error("This DOM method is not implemented."+this.debugInfo())},h.prototype.getElementsByTagNameNS=function(f,p){throw new Error("This DOM method is not implemented."+this.debugInfo())},h.prototype.getElementsByClassName=function(f){throw new Error("This DOM method is not implemented."+this.debugInfo())},h.prototype.isEqualNode=function(f){var p,m,_;if(!h.__super__.isEqualNode.apply(this,arguments).isEqualNode(f)||f.namespaceURI!==this.namespaceURI||f.prefix!==this.prefix||f.localName!==this.localName||f.attribs.length!==this.attribs.length)return!1;for(p=m=0,_=this.attribs.length-1;0<=_?m<=_:m>=_;p=0<=_?++m:--m)if(!this.attribs[p].isEqualNode(f.attribs[p]))return!1;return!0},h})(i)}).call(ofe)});var Gg=E((afe,cfe)=>{"use strict";(function(){var e,t,r=function(i,o){for(var s in o)n.call(o,s)&&(i[s]=o[s]);function a(){this.constructor=i}return a.prototype=o.prototype,i.prototype=new a,i.__super__=o.prototype,i},n={}.hasOwnProperty;t=Ri(),cfe.exports=e=(function(i){r(o,i);function o(s){o.__super__.constructor.call(this,s),this.value=""}return Object.defineProperty(o.prototype,"data",{get:function(){return this.value},set:function(s){return this.value=s||""}}),Object.defineProperty(o.prototype,"length",{get:function(){return this.value.length}}),Object.defineProperty(o.prototype,"textContent",{get:function(){return this.value},set:function(s){return this.value=s||""}}),o.prototype.clone=function(){return Object.create(this)},o.prototype.substringData=function(s,a){throw new Error("This DOM method is not implemented."+this.debugInfo())},o.prototype.appendData=function(s){throw new Error("This DOM method is not implemented."+this.debugInfo())},o.prototype.insertData=function(s,a){throw new Error("This DOM method is not implemented."+this.debugInfo())},o.prototype.deleteData=function(s,a){throw new Error("This DOM method is not implemented."+this.debugInfo())},o.prototype.replaceData=function(s,a,c){throw new Error("This DOM method is not implemented."+this.debugInfo())},o.prototype.isEqualNode=function(s){return!(!o.__super__.isEqualNode.apply(this,arguments).isEqualNode(s)||s.data!==this.data)},o})(t)}).call(afe)});var Sx=E((ufe,lfe)=>{"use strict";(function(){var e,t,r,n=function(o,s){for(var a in s)i.call(s,a)&&(o[a]=s[a]);function c(){this.constructor=o}return c.prototype=s.prototype,o.prototype=new c,o.__super__=s.prototype,o},i={}.hasOwnProperty;e=wr(),r=Gg(),lfe.exports=t=(function(o){n(s,o);function s(a,c){if(s.__super__.constructor.call(this,a),c==null)throw new Error("Missing CDATA text. "+this.debugInfo());this.name="#cdata-section",this.type=e.CData,this.value=this.stringify.cdata(c)}return s.prototype.clone=function(){return Object.create(this)},s.prototype.toString=function(a){return this.options.writer.cdata(this,this.options.writer.filterOptions(a))},s})(r)}).call(ufe)});var vx=E((ffe,dfe)=>{"use strict";(function(){var e,t,r,n=function(o,s){for(var a in s)i.call(s,a)&&(o[a]=s[a]);function c(){this.constructor=o}return c.prototype=s.prototype,o.prototype=new c,o.__super__=s.prototype,o},i={}.hasOwnProperty;e=wr(),t=Gg(),dfe.exports=r=(function(o){n(s,o);function s(a,c){if(s.__super__.constructor.call(this,a),c==null)throw new Error("Missing comment text. "+this.debugInfo());this.name="#comment",this.type=e.Comment,this.value=this.stringify.comment(c)}return s.prototype.clone=function(){return Object.create(this)},s.prototype.toString=function(a){return this.options.writer.comment(this,this.options.writer.filterOptions(a))},s})(t)}).call(ffe)});var Cx=E((pfe,hfe)=>{"use strict";(function(){var e,t,r,n,i=function(s,a){for(var c in a)o.call(a,c)&&(s[c]=a[c]);function u(){this.constructor=s}return u.prototype=a.prototype,s.prototype=new u,s.__super__=a.prototype,s},o={}.hasOwnProperty;n=ds().isObject,r=Ri(),e=wr(),hfe.exports=t=(function(s){i(a,s);function a(c,u,l,d){var h;a.__super__.constructor.call(this,c),n(u)&&(h=u,u=h.version,l=h.encoding,d=h.standalone),u||(u="1.0"),this.type=e.Declaration,this.version=this.stringify.xmlVersion(u),l!=null&&(this.encoding=this.stringify.xmlEncoding(l)),d!=null&&(this.standalone=this.stringify.xmlStandalone(d))}return a.prototype.toString=function(c){return this.options.writer.declaration(this,this.options.writer.filterOptions(c))},a})(r)}).call(pfe)});var xx=E((mfe,gfe)=>{"use strict";(function(){var e,t,r,n=function(o,s){for(var a in s)i.call(s,a)&&(o[a]=s[a]);function c(){this.constructor=o}return c.prototype=s.prototype,o.prototype=new c,o.__super__=s.prototype,o},i={}.hasOwnProperty;r=Ri(),e=wr(),gfe.exports=t=(function(o){n(s,o);function s(a,c,u,l,d,h){if(s.__super__.constructor.call(this,a),c==null)throw new Error("Missing DTD element name. "+this.debugInfo());if(u==null)throw new Error("Missing DTD attribute name. "+this.debugInfo(c));if(!l)throw new Error("Missing DTD attribute type. "+this.debugInfo(c));if(!d)throw new Error("Missing DTD attribute default. "+this.debugInfo(c));if(d.indexOf("#")!==0&&(d="#"+d),!d.match(/^(#REQUIRED|#IMPLIED|#FIXED|#DEFAULT)$/))throw new Error("Invalid default value type; expected: #REQUIRED, #IMPLIED, #FIXED or #DEFAULT. "+this.debugInfo(c));if(h&&!d.match(/^(#FIXED|#DEFAULT)$/))throw new Error("Default value only applies to #FIXED or #DEFAULT. "+this.debugInfo(c));this.elementName=this.stringify.name(c),this.type=e.AttributeDeclaration,this.attributeName=this.stringify.name(u),this.attributeType=this.stringify.dtdAttType(l),h&&(this.defaultValue=this.stringify.dtdAttDefault(h)),this.defaultValueType=d}return s.prototype.toString=function(a){return this.options.writer.dtdAttList(this,this.options.writer.filterOptions(a))},s})(r)}).call(mfe)});var Tx=E((yfe,_fe)=>{"use strict";(function(){var e,t,r,n,i=function(s,a){for(var c in a)o.call(a,c)&&(s[c]=a[c]);function u(){this.constructor=s}return u.prototype=a.prototype,s.prototype=new u,s.__super__=a.prototype,s},o={}.hasOwnProperty;n=ds().isObject,r=Ri(),e=wr(),_fe.exports=t=(function(s){i(a,s);function a(c,u,l,d){if(a.__super__.constructor.call(this,c),l==null)throw new Error("Missing DTD entity name. "+this.debugInfo(l));if(d==null)throw new Error("Missing DTD entity value. "+this.debugInfo(l));if(this.pe=!!u,this.name=this.stringify.name(l),this.type=e.EntityDeclaration,!n(d))this.value=this.stringify.dtdEntityValue(d),this.internal=!0;else{if(!d.pubID&&!d.sysID)throw new Error("Public and/or system identifiers are required for an external entity. "+this.debugInfo(l));if(d.pubID&&!d.sysID)throw new Error("System identifier is required for a public external entity. "+this.debugInfo(l));if(this.internal=!1,d.pubID!=null&&(this.pubID=this.stringify.dtdPubID(d.pubID)),d.sysID!=null&&(this.sysID=this.stringify.dtdSysID(d.sysID)),d.nData!=null&&(this.nData=this.stringify.dtdNData(d.nData)),this.pe&&this.nData)throw new Error("Notation declaration is not allowed in a parameter entity. "+this.debugInfo(l))}}return Object.defineProperty(a.prototype,"publicId",{get:function(){return this.pubID}}),Object.defineProperty(a.prototype,"systemId",{get:function(){return this.sysID}}),Object.defineProperty(a.prototype,"notationName",{get:function(){return this.nData||null}}),Object.defineProperty(a.prototype,"inputEncoding",{get:function(){return null}}),Object.defineProperty(a.prototype,"xmlEncoding",{get:function(){return null}}),Object.defineProperty(a.prototype,"xmlVersion",{get:function(){return null}}),a.prototype.toString=function(c){return this.options.writer.dtdEntity(this,this.options.writer.filterOptions(c))},a})(r)}).call(yfe)});var Ax=E((bfe,Efe)=>{"use strict";(function(){var e,t,r,n=function(o,s){for(var a in s)i.call(s,a)&&(o[a]=s[a]);function c(){this.constructor=o}return c.prototype=s.prototype,o.prototype=new c,o.__super__=s.prototype,o},i={}.hasOwnProperty;r=Ri(),e=wr(),Efe.exports=t=(function(o){n(s,o);function s(a,c,u){if(s.__super__.constructor.call(this,a),c==null)throw new Error("Missing DTD element name. "+this.debugInfo());u||(u="(#PCDATA)"),Array.isArray(u)&&(u="("+u.join(",")+")"),this.name=this.stringify.name(c),this.type=e.ElementDeclaration,this.value=this.stringify.dtdElementValue(u)}return s.prototype.toString=function(a){return this.options.writer.dtdElement(this,this.options.writer.filterOptions(a))},s})(r)}).call(bfe)});var Rx=E((wfe,Sfe)=>{"use strict";(function(){var e,t,r,n=function(o,s){for(var a in s)i.call(s,a)&&(o[a]=s[a]);function c(){this.constructor=o}return c.prototype=s.prototype,o.prototype=new c,o.__super__=s.prototype,o},i={}.hasOwnProperty;r=Ri(),e=wr(),Sfe.exports=t=(function(o){n(s,o);function s(a,c,u){if(s.__super__.constructor.call(this,a),c==null)throw new Error("Missing DTD notation name. "+this.debugInfo(c));if(!u.pubID&&!u.sysID)throw new Error("Public or system identifiers are required for an external entity. "+this.debugInfo(c));this.name=this.stringify.name(c),this.type=e.NotationDeclaration,u.pubID!=null&&(this.pubID=this.stringify.dtdPubID(u.pubID)),u.sysID!=null&&(this.sysID=this.stringify.dtdSysID(u.sysID))}return Object.defineProperty(s.prototype,"publicId",{get:function(){return this.pubID}}),Object.defineProperty(s.prototype,"systemId",{get:function(){return this.sysID}}),s.prototype.toString=function(a){return this.options.writer.dtdNotation(this,this.options.writer.filterOptions(a))},s})(r)}).call(wfe)});var Px=E((vfe,Cfe)=>{"use strict";(function(){var e,t,r,n,i,o,s,a,c,u=function(d,h){for(var f in h)l.call(h,f)&&(d[f]=h[f]);function p(){this.constructor=d}return p.prototype=h.prototype,d.prototype=new p,d.__super__=h.prototype,d},l={}.hasOwnProperty;c=ds().isObject,a=Ri(),e=wr(),t=xx(),n=Tx(),r=Ax(),i=Rx(),s=Ex(),Cfe.exports=o=(function(d){u(h,d);function h(f,p,m){var _,w,R,v,y,S;if(h.__super__.constructor.call(this,f),this.type=e.DocType,f.children){for(v=f.children,w=0,R=v.length;w<R;w++)if(_=v[w],_.type===e.Element){this.name=_.name;break}}this.documentObject=f,c(p)&&(y=p,p=y.pubID,m=y.sysID),m==null&&(S=[p,m],m=S[0],p=S[1]),p!=null&&(this.pubID=this.stringify.dtdPubID(p)),m!=null&&(this.sysID=this.stringify.dtdSysID(m))}return Object.defineProperty(h.prototype,"entities",{get:function(){var f,p,m,_,w;for(_={},w=this.children,p=0,m=w.length;p<m;p++)f=w[p],f.type===e.EntityDeclaration&&!f.pe&&(_[f.name]=f);return new s(_)}}),Object.defineProperty(h.prototype,"notations",{get:function(){var f,p,m,_,w;for(_={},w=this.children,p=0,m=w.length;p<m;p++)f=w[p],f.type===e.NotationDeclaration&&(_[f.name]=f);return new s(_)}}),Object.defineProperty(h.prototype,"publicId",{get:function(){return this.pubID}}),Object.defineProperty(h.prototype,"systemId",{get:function(){return this.sysID}}),Object.defineProperty(h.prototype,"internalSubset",{get:function(){throw new Error("This DOM method is not implemented."+this.debugInfo())}}),h.prototype.element=function(f,p){var m;return m=new r(this,f,p),this.children.push(m),this},h.prototype.attList=function(f,p,m,_,w){var R;return R=new t(this,f,p,m,_,w),this.children.push(R),this},h.prototype.entity=function(f,p){var m;return m=new n(this,!1,f,p),this.children.push(m),this},h.prototype.pEntity=function(f,p){var m;return m=new n(this,!0,f,p),this.children.push(m),this},h.prototype.notation=function(f,p){var m;return m=new i(this,f,p),this.children.push(m),this},h.prototype.toString=function(f){return this.options.writer.docType(this,this.options.writer.filterOptions(f))},h.prototype.ele=function(f,p){return this.element(f,p)},h.prototype.att=function(f,p,m,_,w){return this.attList(f,p,m,_,w)},h.prototype.ent=function(f,p){return this.entity(f,p)},h.prototype.pent=function(f,p){return this.pEntity(f,p)},h.prototype.not=function(f,p){return this.notation(f,p)},h.prototype.up=function(){return this.root()||this.documentObject},h.prototype.isEqualNode=function(f){return!(!h.__super__.isEqualNode.apply(this,arguments).isEqualNode(f)||f.name!==this.name||f.publicId!==this.publicId||f.systemId!==this.systemId)},h})(a)}).call(vfe)});var Ox=E((xfe,Tfe)=>{"use strict";(function(){var e,t,r,n=function(o,s){for(var a in s)i.call(s,a)&&(o[a]=s[a]);function c(){this.constructor=o}return c.prototype=s.prototype,o.prototype=new c,o.__super__=s.prototype,o},i={}.hasOwnProperty;e=wr(),t=Ri(),Tfe.exports=r=(function(o){n(s,o);function s(a,c){if(s.__super__.constructor.call(this,a),c==null)throw new Error("Missing raw text. "+this.debugInfo());this.type=e.Raw,this.value=this.stringify.raw(c)}return s.prototype.clone=function(){return Object.create(this)},s.prototype.toString=function(a){return this.options.writer.raw(this,this.options.writer.filterOptions(a))},s})(t)}).call(xfe)});var Ix=E((Afe,Rfe)=>{"use strict";(function(){var e,t,r,n=function(o,s){for(var a in s)i.call(s,a)&&(o[a]=s[a]);function c(){this.constructor=o}return c.prototype=s.prototype,o.prototype=new c,o.__super__=s.prototype,o},i={}.hasOwnProperty;e=wr(),t=Gg(),Rfe.exports=r=(function(o){n(s,o);function s(a,c){if(s.__super__.constructor.call(this,a),c==null)throw new Error("Missing element text. "+this.debugInfo());this.name="#text",this.type=e.Text,this.value=this.stringify.text(c)}return Object.defineProperty(s.prototype,"isElementContentWhitespace",{get:function(){throw new Error("This DOM method is not implemented."+this.debugInfo())}}),Object.defineProperty(s.prototype,"wholeText",{get:function(){var a,c,u;for(u="",c=this.previousSibling;c;)u=c.data+u,c=c.previousSibling;for(u+=this.data,a=this.nextSibling;a;)u=u+a.data,a=a.nextSibling;return u}}),s.prototype.clone=function(){return Object.create(this)},s.prototype.toString=function(a){return this.options.writer.text(this,this.options.writer.filterOptions(a))},s.prototype.splitText=function(a){throw new Error("This DOM method is not implemented."+this.debugInfo())},s.prototype.replaceWholeText=function(a){throw new Error("This DOM method is not implemented."+this.debugInfo())},s})(t)}).call(Afe)});var Dx=E((Pfe,Ofe)=>{"use strict";(function(){var e,t,r,n=function(o,s){for(var a in s)i.call(s,a)&&(o[a]=s[a]);function c(){this.constructor=o}return c.prototype=s.prototype,o.prototype=new c,o.__super__=s.prototype,o},i={}.hasOwnProperty;e=wr(),t=Gg(),Ofe.exports=r=(function(o){n(s,o);function s(a,c,u){if(s.__super__.constructor.call(this,a),c==null)throw new Error("Missing instruction target. "+this.debugInfo());this.type=e.ProcessingInstruction,this.target=this.stringify.insTarget(c),this.name=this.target,u&&(this.value=this.stringify.insValue(u))}return s.prototype.clone=function(){return Object.create(this)},s.prototype.toString=function(a){return this.options.writer.processingInstruction(this,this.options.writer.filterOptions(a))},s.prototype.isEqualNode=function(a){return!(!s.__super__.isEqualNode.apply(this,arguments).isEqualNode(a)||a.target!==this.target)},s})(t)}).call(Pfe)});var hL=E((Ife,Dfe)=>{"use strict";(function(){var e,t,r,n=function(o,s){for(var a in s)i.call(s,a)&&(o[a]=s[a]);function c(){this.constructor=o}return c.prototype=s.prototype,o.prototype=new c,o.__super__=s.prototype,o},i={}.hasOwnProperty;r=Ri(),e=wr(),Dfe.exports=t=(function(o){n(s,o);function s(a){s.__super__.constructor.call(this,a),this.type=e.Dummy}return s.prototype.clone=function(){return Object.create(this)},s.prototype.toString=function(a){return""},s})(r)}).call(Ife)});var Mfe=E((kfe,Nfe)=>{"use strict";(function(){var e;Nfe.exports=e=(function(){function t(r){this.nodes=r}return Object.defineProperty(t.prototype,"length",{get:function(){return this.nodes.length||0}}),t.prototype.clone=function(){return this.nodes=null},t.prototype.item=function(r){return this.nodes[r]||null},t})()}).call(kfe)});var Ffe=E((Lfe,Bfe)=>{"use strict";(function(){Bfe.exports={Disconnected:1,Preceding:2,Following:4,Contains:8,ContainedBy:16,ImplementationSpecific:32}}).call(Lfe)});var Ri=E((qfe,jfe)=>{"use strict";(function(){var e,t,r,n,i,o,s,a,c,u,l,d,h,f,p,m,_,w,R,v={}.hasOwnProperty;R=ds(),w=R.isObject,_=R.isFunction,m=R.isEmpty,p=R.getValue,a=null,r=null,n=null,i=null,o=null,h=null,f=null,d=null,s=null,t=null,l=null,c=null,e=null,jfe.exports=u=(function(){function y(S){this.parent=S,this.parent&&(this.options=this.parent.options,this.stringify=this.parent.stringify),this.value=null,this.children=[],this.baseURI=null,a||(a=wx(),r=Sx(),n=vx(),i=Cx(),o=Px(),h=Ox(),f=Ix(),d=Dx(),s=hL(),t=wr(),l=Mfe(),c=Ex(),e=Ffe())}return Object.defineProperty(y.prototype,"nodeName",{get:function(){return this.name}}),Object.defineProperty(y.prototype,"nodeType",{get:function(){return this.type}}),Object.defineProperty(y.prototype,"nodeValue",{get:function(){return this.value}}),Object.defineProperty(y.prototype,"parentNode",{get:function(){return this.parent}}),Object.defineProperty(y.prototype,"childNodes",{get:function(){return(!this.childNodeList||!this.childNodeList.nodes)&&(this.childNodeList=new l(this.children)),this.childNodeList}}),Object.defineProperty(y.prototype,"firstChild",{get:function(){return this.children[0]||null}}),Object.defineProperty(y.prototype,"lastChild",{get:function(){return this.children[this.children.length-1]||null}}),Object.defineProperty(y.prototype,"previousSibling",{get:function(){var S;return S=this.parent.children.indexOf(this),this.parent.children[S-1]||null}}),Object.defineProperty(y.prototype,"nextSibling",{get:function(){var S;return S=this.parent.children.indexOf(this),this.parent.children[S+1]||null}}),Object.defineProperty(y.prototype,"ownerDocument",{get:function(){return this.document()||null}}),Object.defineProperty(y.prototype,"textContent",{get:function(){var S,O,M,A,D;if(this.nodeType===t.Element||this.nodeType===t.DocumentFragment){for(D="",A=this.children,O=0,M=A.length;O<M;O++)S=A[O],S.textContent&&(D+=S.textContent);return D}else return null},set:function(S){throw new Error("This DOM method is not implemented."+this.debugInfo())}}),y.prototype.setParent=function(S){var O,M,A,D,I;for(this.parent=S,S&&(this.options=S.options,this.stringify=S.stringify),D=this.children,I=[],M=0,A=D.length;M<A;M++)O=D[M],I.push(O.setParent(this));return I},y.prototype.element=function(S,O,M){var A,D,I,N,J,U,ie,be,B,te,ge;if(U=null,O===null&&M==null&&(B=[{},null],O=B[0],M=B[1]),O==null&&(O={}),O=p(O),w(O)||(te=[O,M],M=te[0],O=te[1]),S!=null&&(S=p(S)),Array.isArray(S))for(I=0,ie=S.length;I<ie;I++)D=S[I],U=this.element(D);else if(_(S))U=this.element(S.apply());else if(w(S)){for(J in S)if(v.call(S,J))if(ge=S[J],_(ge)&&(ge=ge.apply()),!this.options.ignoreDecorators&&this.stringify.convertAttKey&&J.indexOf(this.stringify.convertAttKey)===0)U=this.attribute(J.substr(this.stringify.convertAttKey.length),ge);else if(!this.options.separateArrayItems&&Array.isArray(ge)&&m(ge))U=this.dummy();else if(w(ge)&&m(ge))U=this.element(J);else if(!this.options.keepNullNodes&&ge==null)U=this.dummy();else if(!this.options.separateArrayItems&&Array.isArray(ge))for(N=0,be=ge.length;N<be;N++)D=ge[N],A={},A[J]=D,U=this.element(A);else w(ge)?!this.options.ignoreDecorators&&this.stringify.convertTextKey&&J.indexOf(this.stringify.convertTextKey)===0?U=this.element(ge):(U=this.element(J),U.element(ge)):U=this.element(J,ge)}else!this.options.keepNullNodes&&M===null?U=this.dummy():!this.options.ignoreDecorators&&this.stringify.convertTextKey&&S.indexOf(this.stringify.convertTextKey)===0?U=this.text(M):!this.options.ignoreDecorators&&this.stringify.convertCDataKey&&S.indexOf(this.stringify.convertCDataKey)===0?U=this.cdata(M):!this.options.ignoreDecorators&&this.stringify.convertCommentKey&&S.indexOf(this.stringify.convertCommentKey)===0?U=this.comment(M):!this.options.ignoreDecorators&&this.stringify.convertRawKey&&S.indexOf(this.stringify.convertRawKey)===0?U=this.raw(M):!this.options.ignoreDecorators&&this.stringify.convertPIKey&&S.indexOf(this.stringify.convertPIKey)===0?U=this.instruction(S.substr(this.stringify.convertPIKey.length),M):U=this.node(S,O,M);if(U==null)throw new Error("Could not create any elements with: "+S+". "+this.debugInfo());return U},y.prototype.insertBefore=function(S,O,M){var A,D,I,N,J;if(S?.type)return I=S,N=O,I.setParent(this),N?(D=children.indexOf(N),J=children.splice(D),children.push(I),Array.prototype.push.apply(children,J)):children.push(I),I;if(this.isRoot)throw new Error("Cannot insert elements at root level. "+this.debugInfo(S));return D=this.parent.children.indexOf(this),J=this.parent.children.splice(D),A=this.parent.element(S,O,M),Array.prototype.push.apply(this.parent.children,J),A},y.prototype.insertAfter=function(S,O,M){var A,D,I;if(this.isRoot)throw new Error("Cannot insert elements at root level. "+this.debugInfo(S));return D=this.parent.children.indexOf(this),I=this.parent.children.splice(D+1),A=this.parent.element(S,O,M),Array.prototype.push.apply(this.parent.children,I),A},y.prototype.remove=function(){var S,O;if(this.isRoot)throw new Error("Cannot remove the root element. "+this.debugInfo());return S=this.parent.children.indexOf(this),[].splice.apply(this.parent.children,[S,S-S+1].concat(O=[])),this.parent},y.prototype.node=function(S,O,M){var A,D;return S!=null&&(S=p(S)),O||(O={}),O=p(O),w(O)||(D=[O,M],M=D[0],O=D[1]),A=new a(this,S,O),M!=null&&A.text(M),this.children.push(A),A},y.prototype.text=function(S){var O;return w(S)&&this.element(S),O=new f(this,S),this.children.push(O),this},y.prototype.cdata=function(S){var O;return O=new r(this,S),this.children.push(O),this},y.prototype.comment=function(S){var O;return O=new n(this,S),this.children.push(O),this},y.prototype.commentBefore=function(S){var O,M,A;return M=this.parent.children.indexOf(this),A=this.parent.children.splice(M),O=this.parent.comment(S),Array.prototype.push.apply(this.parent.children,A),this},y.prototype.commentAfter=function(S){var O,M,A;return M=this.parent.children.indexOf(this),A=this.parent.children.splice(M+1),O=this.parent.comment(S),Array.prototype.push.apply(this.parent.children,A),this},y.prototype.raw=function(S){var O;return O=new h(this,S),this.children.push(O),this},y.prototype.dummy=function(){var S;return S=new s(this),S},y.prototype.instruction=function(S,O){var M,A,D,I,N;if(S!=null&&(S=p(S)),O!=null&&(O=p(O)),Array.isArray(S))for(I=0,N=S.length;I<N;I++)M=S[I],this.instruction(M);else if(w(S))for(M in S)v.call(S,M)&&(A=S[M],this.instruction(M,A));else _(O)&&(O=O.apply()),D=new d(this,S,O),this.children.push(D);return this},y.prototype.instructionBefore=function(S,O){var M,A,D;return A=this.parent.children.indexOf(this),D=this.parent.children.splice(A),M=this.parent.instruction(S,O),Array.prototype.push.apply(this.parent.children,D),this},y.prototype.instructionAfter=function(S,O){var M,A,D;return A=this.parent.children.indexOf(this),D=this.parent.children.splice(A+1),M=this.parent.instruction(S,O),Array.prototype.push.apply(this.parent.children,D),this},y.prototype.declaration=function(S,O,M){var A,D;return A=this.document(),D=new i(A,S,O,M),A.children.length===0?A.children.unshift(D):A.children[0].type===t.Declaration?A.children[0]=D:A.children.unshift(D),A.root()||A},y.prototype.dtd=function(S,O){var M,A,D,I,N,J,U,ie,be,B;for(A=this.document(),D=new o(A,S,O),be=A.children,I=N=0,U=be.length;N<U;I=++N)if(M=be[I],M.type===t.DocType)return A.children[I]=D,D;for(B=A.children,I=J=0,ie=B.length;J<ie;I=++J)if(M=B[I],M.isRoot)return A.children.splice(I,0,D),D;return A.children.push(D),D},y.prototype.up=function(){if(this.isRoot)throw new Error("The root node has no parent. Use doc() if you need to get the document object.");return this.parent},y.prototype.root=function(){var S;for(S=this;S;){if(S.type===t.Document)return S.rootObject;if(S.isRoot)return S;S=S.parent}},y.prototype.document=function(){var S;for(S=this;S;){if(S.type===t.Document)return S;S=S.parent}},y.prototype.end=function(S){return this.document().end(S)},y.prototype.prev=function(){var S;if(S=this.parent.children.indexOf(this),S<1)throw new Error("Already at the first node. "+this.debugInfo());return this.parent.children[S-1]},y.prototype.next=function(){var S;if(S=this.parent.children.indexOf(this),S===-1||S===this.parent.children.length-1)throw new Error("Already at the last node. "+this.debugInfo());return this.parent.children[S+1]},y.prototype.importDocument=function(S){var O;return O=S.root().clone(),O.parent=this,O.isRoot=!1,this.children.push(O),this},y.prototype.debugInfo=function(S){var O,M;return S=S||this.name,S==null&&!((O=this.parent)!=null&&O.name)?"":S==null?"parent: <"+this.parent.name+">":(M=this.parent)!=null&&M.name?"node: <"+S+">, parent: <"+this.parent.name+">":"node: <"+S+">"},y.prototype.ele=function(S,O,M){return this.element(S,O,M)},y.prototype.nod=function(S,O,M){return this.node(S,O,M)},y.prototype.txt=function(S){return this.text(S)},y.prototype.dat=function(S){return this.cdata(S)},y.prototype.com=function(S){return this.comment(S)},y.prototype.ins=function(S,O){return this.instruction(S,O)},y.prototype.doc=function(){return this.document()},y.prototype.dec=function(S,O,M){return this.declaration(S,O,M)},y.prototype.e=function(S,O,M){return this.element(S,O,M)},y.prototype.n=function(S,O,M){return this.node(S,O,M)},y.prototype.t=function(S){return this.text(S)},y.prototype.d=function(S){return this.cdata(S)},y.prototype.c=function(S){return this.comment(S)},y.prototype.r=function(S){return this.raw(S)},y.prototype.i=function(S,O){return this.instruction(S,O)},y.prototype.u=function(){return this.up()},y.prototype.importXMLBuilder=function(S){return this.importDocument(S)},y.prototype.replaceChild=function(S,O){throw new Error("This DOM method is not implemented."+this.debugInfo())},y.prototype.removeChild=function(S){throw new Error("This DOM method is not implemented."+this.debugInfo())},y.prototype.appendChild=function(S){throw new Error("This DOM method is not implemented."+this.debugInfo())},y.prototype.hasChildNodes=function(){return this.children.length!==0},y.prototype.cloneNode=function(S){throw new Error("This DOM method is not implemented."+this.debugInfo())},y.prototype.normalize=function(){throw new Error("This DOM method is not implemented."+this.debugInfo())},y.prototype.isSupported=function(S,O){return!0},y.prototype.hasAttributes=function(){return this.attribs.length!==0},y.prototype.compareDocumentPosition=function(S){var O,M;return O=this,O===S?0:this.document()!==S.document()?(M=e.Disconnected|e.ImplementationSpecific,Math.random()<.5?M|=e.Preceding:M|=e.Following,M):O.isAncestor(S)?e.Contains|e.Preceding:O.isDescendant(S)?e.Contains|e.Following:O.isPreceding(S)?e.Preceding:e.Following},y.prototype.isSameNode=function(S){throw new Error("This DOM method is not implemented."+this.debugInfo())},y.prototype.lookupPrefix=function(S){throw new Error("This DOM method is not implemented."+this.debugInfo())},y.prototype.isDefaultNamespace=function(S){throw new Error("This DOM method is not implemented."+this.debugInfo())},y.prototype.lookupNamespaceURI=function(S){throw new Error("This DOM method is not implemented."+this.debugInfo())},y.prototype.isEqualNode=function(S){var O,M,A;if(S.nodeType!==this.nodeType||S.children.length!==this.children.length)return!1;for(O=M=0,A=this.children.length-1;0<=A?M<=A:M>=A;O=0<=A?++M:--M)if(!this.children[O].isEqualNode(S.children[O]))return!1;return!0},y.prototype.getFeature=function(S,O){throw new Error("This DOM method is not implemented."+this.debugInfo())},y.prototype.setUserData=function(S,O,M){throw new Error("This DOM method is not implemented."+this.debugInfo())},y.prototype.getUserData=function(S){throw new Error("This DOM method is not implemented."+this.debugInfo())},y.prototype.contains=function(S){return S?S===this||this.isDescendant(S):!1},y.prototype.isDescendant=function(S){var O,M,A,D,I;for(I=this.children,A=0,D=I.length;A<D;A++)if(O=I[A],S===O||(M=O.isDescendant(S),M))return!0;return!1},y.prototype.isAncestor=function(S){return S.isDescendant(this)},y.prototype.isPreceding=function(S){var O,M;return O=this.treePosition(S),M=this.treePosition(this),O===-1||M===-1?!1:O<M},y.prototype.isFollowing=function(S){var O,M;return O=this.treePosition(S),M=this.treePosition(this),O===-1||M===-1?!1:O>M},y.prototype.treePosition=function(S){var O,M;return M=0,O=!1,this.foreachTreeNode(this.document(),function(A){if(M++,!O&&A===S)return O=!0}),O?M:-1},y.prototype.foreachTreeNode=function(S,O){var M,A,D,I,N;for(S||(S=this.document()),I=S.children,A=0,D=I.length;A<D;A++){if(M=I[A],N=O(M))return N;if(N=this.foreachTreeNode(M,O),N)return N}},y})()}).call(qfe)});var mL=E((Ufe,Hfe)=>{"use strict";(function(){var e,t=function(n,i){return function(){return n.apply(i,arguments)}},r={}.hasOwnProperty;Hfe.exports=e=(function(){function n(i){this.assertLegalName=t(this.assertLegalName,this),this.assertLegalChar=t(this.assertLegalChar,this);var o,s,a;i||(i={}),this.options=i,this.options.version||(this.options.version="1.0"),s=i.stringify||{};for(o in s)r.call(s,o)&&(a=s[o],this[o]=a)}return n.prototype.name=function(i){return this.options.noValidation?i:this.assertLegalName(""+i||"")},n.prototype.text=function(i){return this.options.noValidation?i:this.assertLegalChar(this.textEscape(""+i||""))},n.prototype.cdata=function(i){return this.options.noValidation?i:(i=""+i||"",i=i.replace("]]>","]]]]><![CDATA[>"),this.assertLegalChar(i))},n.prototype.comment=function(i){if(this.options.noValidation)return i;if(i=""+i||"",i.match(/--/))throw new Error("Comment text cannot contain double-hypen: "+i);return this.assertLegalChar(i)},n.prototype.raw=function(i){return this.options.noValidation?i:""+i||""},n.prototype.attValue=function(i){return this.options.noValidation?i:this.assertLegalChar(this.attEscape(i=""+i||""))},n.prototype.insTarget=function(i){return this.options.noValidation?i:this.assertLegalChar(""+i||"")},n.prototype.insValue=function(i){if(this.options.noValidation)return i;if(i=""+i||"",i.match(/\?>/))throw new Error("Invalid processing instruction value: "+i);return this.assertLegalChar(i)},n.prototype.xmlVersion=function(i){if(this.options.noValidation)return i;if(i=""+i||"",!i.match(/1\.[0-9]+/))throw new Error("Invalid version number: "+i);return i},n.prototype.xmlEncoding=function(i){if(this.options.noValidation)return i;if(i=""+i||"",!i.match(/^[A-Za-z](?:[A-Za-z0-9._-])*$/))throw new Error("Invalid encoding: "+i);return this.assertLegalChar(i)},n.prototype.xmlStandalone=function(i){return this.options.noValidation?i:i?"yes":"no"},n.prototype.dtdPubID=function(i){return this.options.noValidation?i:this.assertLegalChar(""+i||"")},n.prototype.dtdSysID=function(i){return this.options.noValidation?i:this.assertLegalChar(""+i||"")},n.prototype.dtdElementValue=function(i){return this.options.noValidation?i:this.assertLegalChar(""+i||"")},n.prototype.dtdAttType=function(i){return this.options.noValidation?i:this.assertLegalChar(""+i||"")},n.prototype.dtdAttDefault=function(i){return this.options.noValidation?i:this.assertLegalChar(""+i||"")},n.prototype.dtdEntityValue=function(i){return this.options.noValidation?i:this.assertLegalChar(""+i||"")},n.prototype.dtdNData=function(i){return this.options.noValidation?i:this.assertLegalChar(""+i||"")},n.prototype.convertAttKey="@",n.prototype.convertPIKey="?",n.prototype.convertTextKey="#text",n.prototype.convertCDataKey="#cdata",n.prototype.convertCommentKey="#comment",n.prototype.convertRawKey="#raw",n.prototype.assertLegalChar=function(i){var o,s;if(this.options.noValidation)return i;if(o="",this.options.version==="1.0"){if(o=/[\0-\x08\x0B\f\x0E-\x1F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,s=i.match(o))throw new Error("Invalid character in string: "+i+" at index "+s.index)}else if(this.options.version==="1.1"&&(o=/[\0\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,s=i.match(o)))throw new Error("Invalid character in string: "+i+" at index "+s.index);return i},n.prototype.assertLegalName=function(i){var o;if(this.options.noValidation)return i;if(this.assertLegalChar(i),o=/^([:A-Z_a-z\xC0-\xD6\xD8-\xF6\xF8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])([\x2D\.0-:A-Z_a-z\xB7\xC0-\xD6\xD8-\xF6\xF8-\u037D\u037F-\u1FFF\u200C\u200D\u203F\u2040\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])*$/,!i.match(o))throw new Error("Invalid character in name");return i},n.prototype.textEscape=function(i){var o;return this.options.noValidation?i:(o=this.options.noDoubleEncoding?/(?!&\S+;)&/g:/&/g,i.replace(o,"&").replace(/</g,"<").replace(/>/g,">").replace(/\r/g,"
"))},n.prototype.attEscape=function(i){var o;return this.options.noValidation?i:(o=this.options.noDoubleEncoding?/(?!&\S+;)&/g:/&/g,i.replace(o,"&").replace(/</g,"<").replace(/"/g,""").replace(/\t/g,"	").replace(/\n/g,"
").replace(/\r/g,"
"))},n})()}).call(Ufe)});var zg=E(($fe,Gfe)=>{"use strict";(function(){Gfe.exports={None:0,OpenTag:1,InsideTag:2,CloseTag:3}}).call($fe)});var gL=E((zfe,Vfe)=>{"use strict";(function(){var e,t,r,n,i,o,s,a,c,u,l,d,h,f,p,m,_,w={}.hasOwnProperty;_=ds().assign,e=wr(),c=Cx(),u=Px(),r=Sx(),n=vx(),d=wx(),f=Ox(),p=Ix(),h=Dx(),l=hL(),i=xx(),o=Ax(),s=Tx(),a=Rx(),t=zg(),Vfe.exports=m=(function(){function R(v){var y,S,O;v||(v={}),this.options=v,S=v.writer||{};for(y in S)w.call(S,y)&&(O=S[y],this["_"+y]=this[y],this[y]=O)}return R.prototype.filterOptions=function(v){var y,S,O,M,A,D,I,N;return v||(v={}),v=_({},this.options,v),y={writer:this},y.pretty=v.pretty||!1,y.allowEmpty=v.allowEmpty||!1,y.indent=(S=v.indent)!=null?S:" ",y.newline=(O=v.newline)!=null?O:`
|
|
279
|
+
`,y.offset=(M=v.offset)!=null?M:0,y.dontPrettyTextNodes=(A=(D=v.dontPrettyTextNodes)!=null?D:v.dontprettytextnodes)!=null?A:0,y.spaceBeforeSlash=(I=(N=v.spaceBeforeSlash)!=null?N:v.spacebeforeslash)!=null?I:"",y.spaceBeforeSlash===!0&&(y.spaceBeforeSlash=" "),y.suppressPrettyCount=0,y.user={},y.state=t.None,y},R.prototype.indent=function(v,y,S){var O;return!y.pretty||y.suppressPrettyCount?"":y.pretty&&(O=(S||0)+y.offset+1,O>0)?new Array(O).join(y.indent):""},R.prototype.endline=function(v,y,S){return!y.pretty||y.suppressPrettyCount?"":y.newline},R.prototype.attribute=function(v,y,S){var O;return this.openAttribute(v,y,S),O=" "+v.name+'="'+v.value+'"',this.closeAttribute(v,y,S),O},R.prototype.cdata=function(v,y,S){var O;return this.openNode(v,y,S),y.state=t.OpenTag,O=this.indent(v,y,S)+"<![CDATA[",y.state=t.InsideTag,O+=v.value,y.state=t.CloseTag,O+="]]>"+this.endline(v,y,S),y.state=t.None,this.closeNode(v,y,S),O},R.prototype.comment=function(v,y,S){var O;return this.openNode(v,y,S),y.state=t.OpenTag,O=this.indent(v,y,S)+"<!-- ",y.state=t.InsideTag,O+=v.value,y.state=t.CloseTag,O+=" -->"+this.endline(v,y,S),y.state=t.None,this.closeNode(v,y,S),O},R.prototype.declaration=function(v,y,S){var O;return this.openNode(v,y,S),y.state=t.OpenTag,O=this.indent(v,y,S)+"<?xml",y.state=t.InsideTag,O+=' version="'+v.version+'"',v.encoding!=null&&(O+=' encoding="'+v.encoding+'"'),v.standalone!=null&&(O+=' standalone="'+v.standalone+'"'),y.state=t.CloseTag,O+=y.spaceBeforeSlash+"?>",O+=this.endline(v,y,S),y.state=t.None,this.closeNode(v,y,S),O},R.prototype.docType=function(v,y,S){var O,M,A,D,I;if(S||(S=0),this.openNode(v,y,S),y.state=t.OpenTag,D=this.indent(v,y,S),D+="<!DOCTYPE "+v.root().name,v.pubID&&v.sysID?D+=' PUBLIC "'+v.pubID+'" "'+v.sysID+'"':v.sysID&&(D+=' SYSTEM "'+v.sysID+'"'),v.children.length>0){for(D+=" [",D+=this.endline(v,y,S),y.state=t.InsideTag,I=v.children,M=0,A=I.length;M<A;M++)O=I[M],D+=this.writeChildNode(O,y,S+1);y.state=t.CloseTag,D+="]"}return y.state=t.CloseTag,D+=y.spaceBeforeSlash+">",D+=this.endline(v,y,S),y.state=t.None,this.closeNode(v,y,S),D},R.prototype.element=function(v,y,S){var O,M,A,D,I,N,J,U,ie,be,B,te,ge,$;S||(S=0),be=!1,B="",this.openNode(v,y,S),y.state=t.OpenTag,B+=this.indent(v,y,S)+"<"+v.name,te=v.attribs;for(ie in te)w.call(te,ie)&&(O=te[ie],B+=this.attribute(O,y,S));if(A=v.children.length,D=A===0?null:v.children[0],A===0||v.children.every(function(ve){return(ve.type===e.Text||ve.type===e.Raw)&&ve.value===""}))y.allowEmpty?(B+=">",y.state=t.CloseTag,B+="</"+v.name+">"+this.endline(v,y,S)):(y.state=t.CloseTag,B+=y.spaceBeforeSlash+"/>"+this.endline(v,y,S));else if(y.pretty&&A===1&&(D.type===e.Text||D.type===e.Raw)&&D.value!=null)B+=">",y.state=t.InsideTag,y.suppressPrettyCount++,be=!0,B+=this.writeChildNode(D,y,S+1),y.suppressPrettyCount--,be=!1,y.state=t.CloseTag,B+="</"+v.name+">"+this.endline(v,y,S);else{if(y.dontPrettyTextNodes){for(ge=v.children,I=0,J=ge.length;I<J;I++)if(M=ge[I],(M.type===e.Text||M.type===e.Raw)&&M.value!=null){y.suppressPrettyCount++,be=!0;break}}for(B+=">"+this.endline(v,y,S),y.state=t.InsideTag,$=v.children,N=0,U=$.length;N<U;N++)M=$[N],B+=this.writeChildNode(M,y,S+1);y.state=t.CloseTag,B+=this.indent(v,y,S)+"</"+v.name+">",be&&y.suppressPrettyCount--,B+=this.endline(v,y,S),y.state=t.None}return this.closeNode(v,y,S),B},R.prototype.writeChildNode=function(v,y,S){switch(v.type){case e.CData:return this.cdata(v,y,S);case e.Comment:return this.comment(v,y,S);case e.Element:return this.element(v,y,S);case e.Raw:return this.raw(v,y,S);case e.Text:return this.text(v,y,S);case e.ProcessingInstruction:return this.processingInstruction(v,y,S);case e.Dummy:return"";case e.Declaration:return this.declaration(v,y,S);case e.DocType:return this.docType(v,y,S);case e.AttributeDeclaration:return this.dtdAttList(v,y,S);case e.ElementDeclaration:return this.dtdElement(v,y,S);case e.EntityDeclaration:return this.dtdEntity(v,y,S);case e.NotationDeclaration:return this.dtdNotation(v,y,S);default:throw new Error("Unknown XML node type: "+v.constructor.name)}},R.prototype.processingInstruction=function(v,y,S){var O;return this.openNode(v,y,S),y.state=t.OpenTag,O=this.indent(v,y,S)+"<?",y.state=t.InsideTag,O+=v.target,v.value&&(O+=" "+v.value),y.state=t.CloseTag,O+=y.spaceBeforeSlash+"?>",O+=this.endline(v,y,S),y.state=t.None,this.closeNode(v,y,S),O},R.prototype.raw=function(v,y,S){var O;return this.openNode(v,y,S),y.state=t.OpenTag,O=this.indent(v,y,S),y.state=t.InsideTag,O+=v.value,y.state=t.CloseTag,O+=this.endline(v,y,S),y.state=t.None,this.closeNode(v,y,S),O},R.prototype.text=function(v,y,S){var O;return this.openNode(v,y,S),y.state=t.OpenTag,O=this.indent(v,y,S),y.state=t.InsideTag,O+=v.value,y.state=t.CloseTag,O+=this.endline(v,y,S),y.state=t.None,this.closeNode(v,y,S),O},R.prototype.dtdAttList=function(v,y,S){var O;return this.openNode(v,y,S),y.state=t.OpenTag,O=this.indent(v,y,S)+"<!ATTLIST",y.state=t.InsideTag,O+=" "+v.elementName+" "+v.attributeName+" "+v.attributeType,v.defaultValueType!=="#DEFAULT"&&(O+=" "+v.defaultValueType),v.defaultValue&&(O+=' "'+v.defaultValue+'"'),y.state=t.CloseTag,O+=y.spaceBeforeSlash+">"+this.endline(v,y,S),y.state=t.None,this.closeNode(v,y,S),O},R.prototype.dtdElement=function(v,y,S){var O;return this.openNode(v,y,S),y.state=t.OpenTag,O=this.indent(v,y,S)+"<!ELEMENT",y.state=t.InsideTag,O+=" "+v.name+" "+v.value,y.state=t.CloseTag,O+=y.spaceBeforeSlash+">"+this.endline(v,y,S),y.state=t.None,this.closeNode(v,y,S),O},R.prototype.dtdEntity=function(v,y,S){var O;return this.openNode(v,y,S),y.state=t.OpenTag,O=this.indent(v,y,S)+"<!ENTITY",y.state=t.InsideTag,v.pe&&(O+=" %"),O+=" "+v.name,v.value?O+=' "'+v.value+'"':(v.pubID&&v.sysID?O+=' PUBLIC "'+v.pubID+'" "'+v.sysID+'"':v.sysID&&(O+=' SYSTEM "'+v.sysID+'"'),v.nData&&(O+=" NDATA "+v.nData)),y.state=t.CloseTag,O+=y.spaceBeforeSlash+">"+this.endline(v,y,S),y.state=t.None,this.closeNode(v,y,S),O},R.prototype.dtdNotation=function(v,y,S){var O;return this.openNode(v,y,S),y.state=t.OpenTag,O=this.indent(v,y,S)+"<!NOTATION",y.state=t.InsideTag,O+=" "+v.name,v.pubID&&v.sysID?O+=' PUBLIC "'+v.pubID+'" "'+v.sysID+'"':v.pubID?O+=' PUBLIC "'+v.pubID+'"':v.sysID&&(O+=' SYSTEM "'+v.sysID+'"'),y.state=t.CloseTag,O+=y.spaceBeforeSlash+">"+this.endline(v,y,S),y.state=t.None,this.closeNode(v,y,S),O},R.prototype.openNode=function(v,y,S){},R.prototype.closeNode=function(v,y,S){},R.prototype.openAttribute=function(v,y,S){},R.prototype.closeAttribute=function(v,y,S){},R})()}).call(zfe)});var kx=E((Wfe,Kfe)=>{"use strict";(function(){var e,t,r=function(i,o){for(var s in o)n.call(o,s)&&(i[s]=o[s]);function a(){this.constructor=i}return a.prototype=o.prototype,i.prototype=new a,i.__super__=o.prototype,i},n={}.hasOwnProperty;t=gL(),Kfe.exports=e=(function(i){r(o,i);function o(s){o.__super__.constructor.call(this,s)}return o.prototype.document=function(s,a){var c,u,l,d,h;for(a=this.filterOptions(a),d="",h=s.children,u=0,l=h.length;u<l;u++)c=h[u],d+=this.writeChildNode(c,a,0);return a.pretty&&d.slice(-a.newline.length)===a.newline&&(d=d.slice(0,-a.newline.length)),d},o})(t)}).call(Wfe)});var yL=E((Yfe,Xfe)=>{"use strict";(function(){var e,t,r,n,i,o,s,a,c=function(l,d){for(var h in d)u.call(d,h)&&(l[h]=d[h]);function f(){this.constructor=l}return f.prototype=d.prototype,l.prototype=new f,l.__super__=d.prototype,l},u={}.hasOwnProperty;a=ds().isPlainObject,r=dL(),t=Qle(),i=Ri(),e=wr(),s=mL(),o=kx(),Xfe.exports=n=(function(l){c(d,l);function d(h){d.__super__.constructor.call(this,null),this.name="#document",this.type=e.Document,this.documentURI=null,this.domConfig=new t,h||(h={}),h.writer||(h.writer=new o),this.options=h,this.stringify=new s(h)}return Object.defineProperty(d.prototype,"implementation",{value:new r}),Object.defineProperty(d.prototype,"doctype",{get:function(){var h,f,p,m;for(m=this.children,f=0,p=m.length;f<p;f++)if(h=m[f],h.type===e.DocType)return h;return null}}),Object.defineProperty(d.prototype,"documentElement",{get:function(){return this.rootObject||null}}),Object.defineProperty(d.prototype,"inputEncoding",{get:function(){return null}}),Object.defineProperty(d.prototype,"strictErrorChecking",{get:function(){return!1}}),Object.defineProperty(d.prototype,"xmlEncoding",{get:function(){return this.children.length!==0&&this.children[0].type===e.Declaration?this.children[0].encoding:null}}),Object.defineProperty(d.prototype,"xmlStandalone",{get:function(){return this.children.length!==0&&this.children[0].type===e.Declaration?this.children[0].standalone==="yes":!1}}),Object.defineProperty(d.prototype,"xmlVersion",{get:function(){return this.children.length!==0&&this.children[0].type===e.Declaration?this.children[0].version:"1.0"}}),Object.defineProperty(d.prototype,"URL",{get:function(){return this.documentURI}}),Object.defineProperty(d.prototype,"origin",{get:function(){return null}}),Object.defineProperty(d.prototype,"compatMode",{get:function(){return null}}),Object.defineProperty(d.prototype,"characterSet",{get:function(){return null}}),Object.defineProperty(d.prototype,"contentType",{get:function(){return null}}),d.prototype.end=function(h){var f;return f={},h?a(h)&&(f=h,h=this.options.writer):h=this.options.writer,h.document(this,h.filterOptions(f))},d.prototype.toString=function(h){return this.options.writer.document(this,this.options.writer.filterOptions(h))},d.prototype.createElement=function(h){throw new Error("This DOM method is not implemented."+this.debugInfo())},d.prototype.createDocumentFragment=function(){throw new Error("This DOM method is not implemented."+this.debugInfo())},d.prototype.createTextNode=function(h){throw new Error("This DOM method is not implemented."+this.debugInfo())},d.prototype.createComment=function(h){throw new Error("This DOM method is not implemented."+this.debugInfo())},d.prototype.createCDATASection=function(h){throw new Error("This DOM method is not implemented."+this.debugInfo())},d.prototype.createProcessingInstruction=function(h,f){throw new Error("This DOM method is not implemented."+this.debugInfo())},d.prototype.createAttribute=function(h){throw new Error("This DOM method is not implemented."+this.debugInfo())},d.prototype.createEntityReference=function(h){throw new Error("This DOM method is not implemented."+this.debugInfo())},d.prototype.getElementsByTagName=function(h){throw new Error("This DOM method is not implemented."+this.debugInfo())},d.prototype.importNode=function(h,f){throw new Error("This DOM method is not implemented."+this.debugInfo())},d.prototype.createElementNS=function(h,f){throw new Error("This DOM method is not implemented."+this.debugInfo())},d.prototype.createAttributeNS=function(h,f){throw new Error("This DOM method is not implemented."+this.debugInfo())},d.prototype.getElementsByTagNameNS=function(h,f){throw new Error("This DOM method is not implemented."+this.debugInfo())},d.prototype.getElementById=function(h){throw new Error("This DOM method is not implemented."+this.debugInfo())},d.prototype.adoptNode=function(h){throw new Error("This DOM method is not implemented."+this.debugInfo())},d.prototype.normalizeDocument=function(){throw new Error("This DOM method is not implemented."+this.debugInfo())},d.prototype.renameNode=function(h,f,p){throw new Error("This DOM method is not implemented."+this.debugInfo())},d.prototype.getElementsByClassName=function(h){throw new Error("This DOM method is not implemented."+this.debugInfo())},d.prototype.createEvent=function(h){throw new Error("This DOM method is not implemented."+this.debugInfo())},d.prototype.createRange=function(){throw new Error("This DOM method is not implemented."+this.debugInfo())},d.prototype.createNodeIterator=function(h,f,p){throw new Error("This DOM method is not implemented."+this.debugInfo())},d.prototype.createTreeWalker=function(h,f,p){throw new Error("This DOM method is not implemented."+this.debugInfo())},d})(i)}).call(Yfe)});var Zfe=E((Jfe,Qfe)=>{"use strict";(function(){var e,t,r,n,i,o,s,a,c,u,l,d,h,f,p,m,_,w,R,v,y,S,O,M,A={}.hasOwnProperty;M=ds(),S=M.isObject,y=M.isFunction,O=M.isPlainObject,v=M.getValue,e=wr(),d=yL(),f=wx(),n=Sx(),i=vx(),m=Ox(),R=Ix(),p=Dx(),u=Cx(),l=Px(),o=xx(),a=Tx(),s=Ax(),c=Rx(),r=pL(),w=mL(),_=kx(),t=zg(),Qfe.exports=h=(function(){function D(I,N,J){var U;this.name="?xml",this.type=e.Document,I||(I={}),U={},I.writer?O(I.writer)&&(U=I.writer,I.writer=new _):I.writer=new _,this.options=I,this.writer=I.writer,this.writerOptions=this.writer.filterOptions(U),this.stringify=new w(I),this.onDataCallback=N||function(){},this.onEndCallback=J||function(){},this.currentNode=null,this.currentLevel=-1,this.openTags={},this.documentStarted=!1,this.documentCompleted=!1,this.root=null}return D.prototype.createChildNode=function(I){var N,J,U,ie,be,B,te,ge;switch(I.type){case e.CData:this.cdata(I.value);break;case e.Comment:this.comment(I.value);break;case e.Element:U={},te=I.attribs;for(J in te)A.call(te,J)&&(N=te[J],U[J]=N.value);this.node(I.name,U);break;case e.Dummy:this.dummy();break;case e.Raw:this.raw(I.value);break;case e.Text:this.text(I.value);break;case e.ProcessingInstruction:this.instruction(I.target,I.value);break;default:throw new Error("This XML node type is not supported in a JS object: "+I.constructor.name)}for(ge=I.children,be=0,B=ge.length;be<B;be++)ie=ge[be],this.createChildNode(ie),ie.type===e.Element&&this.up();return this},D.prototype.dummy=function(){return this},D.prototype.node=function(I,N,J){var U;if(I==null)throw new Error("Missing node name.");if(this.root&&this.currentLevel===-1)throw new Error("Document can only have one root node. "+this.debugInfo(I));return this.openCurrent(),I=v(I),N==null&&(N={}),N=v(N),S(N)||(U=[N,J],J=U[0],N=U[1]),this.currentNode=new f(this,I,N),this.currentNode.children=!1,this.currentLevel++,this.openTags[this.currentLevel]=this.currentNode,J!=null&&this.text(J),this},D.prototype.element=function(I,N,J){var U,ie,be,B,te,ge;if(this.currentNode&&this.currentNode.type===e.DocType)this.dtdElement.apply(this,arguments);else if(Array.isArray(I)||S(I)||y(I))for(B=this.options.noValidation,this.options.noValidation=!0,ge=new d(this.options).element("TEMP_ROOT"),ge.element(I),this.options.noValidation=B,te=ge.children,ie=0,be=te.length;ie<be;ie++)U=te[ie],this.createChildNode(U),U.type===e.Element&&this.up();else this.node(I,N,J);return this},D.prototype.attribute=function(I,N){var J,U;if(!this.currentNode||this.currentNode.children)throw new Error("att() can only be used immediately after an ele() call in callback mode. "+this.debugInfo(I));if(I!=null&&(I=v(I)),S(I))for(J in I)A.call(I,J)&&(U=I[J],this.attribute(J,U));else y(N)&&(N=N.apply()),this.options.keepNullAttributes&&N==null?this.currentNode.attribs[I]=new r(this,I,""):N!=null&&(this.currentNode.attribs[I]=new r(this,I,N));return this},D.prototype.text=function(I){var N;return this.openCurrent(),N=new R(this,I),this.onData(this.writer.text(N,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},D.prototype.cdata=function(I){var N;return this.openCurrent(),N=new n(this,I),this.onData(this.writer.cdata(N,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},D.prototype.comment=function(I){var N;return this.openCurrent(),N=new i(this,I),this.onData(this.writer.comment(N,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},D.prototype.raw=function(I){var N;return this.openCurrent(),N=new m(this,I),this.onData(this.writer.raw(N,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},D.prototype.instruction=function(I,N){var J,U,ie,be,B;if(this.openCurrent(),I!=null&&(I=v(I)),N!=null&&(N=v(N)),Array.isArray(I))for(J=0,be=I.length;J<be;J++)U=I[J],this.instruction(U);else if(S(I))for(U in I)A.call(I,U)&&(ie=I[U],this.instruction(U,ie));else y(N)&&(N=N.apply()),B=new p(this,I,N),this.onData(this.writer.processingInstruction(B,this.writerOptions,this.currentLevel+1),this.currentLevel+1);return this},D.prototype.declaration=function(I,N,J){var U;if(this.openCurrent(),this.documentStarted)throw new Error("declaration() must be the first node.");return U=new u(this,I,N,J),this.onData(this.writer.declaration(U,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},D.prototype.doctype=function(I,N,J){if(this.openCurrent(),I==null)throw new Error("Missing root node name.");if(this.root)throw new Error("dtd() must come before the root node.");return this.currentNode=new l(this,N,J),this.currentNode.rootNodeName=I,this.currentNode.children=!1,this.currentLevel++,this.openTags[this.currentLevel]=this.currentNode,this},D.prototype.dtdElement=function(I,N){var J;return this.openCurrent(),J=new s(this,I,N),this.onData(this.writer.dtdElement(J,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},D.prototype.attList=function(I,N,J,U,ie){var be;return this.openCurrent(),be=new o(this,I,N,J,U,ie),this.onData(this.writer.dtdAttList(be,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},D.prototype.entity=function(I,N){var J;return this.openCurrent(),J=new a(this,!1,I,N),this.onData(this.writer.dtdEntity(J,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},D.prototype.pEntity=function(I,N){var J;return this.openCurrent(),J=new a(this,!0,I,N),this.onData(this.writer.dtdEntity(J,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},D.prototype.notation=function(I,N){var J;return this.openCurrent(),J=new c(this,I,N),this.onData(this.writer.dtdNotation(J,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},D.prototype.up=function(){if(this.currentLevel<0)throw new Error("The document node has no parent.");return this.currentNode?(this.currentNode.children?this.closeNode(this.currentNode):this.openNode(this.currentNode),this.currentNode=null):this.closeNode(this.openTags[this.currentLevel]),delete this.openTags[this.currentLevel],this.currentLevel--,this},D.prototype.end=function(){for(;this.currentLevel>=0;)this.up();return this.onEnd()},D.prototype.openCurrent=function(){if(this.currentNode)return this.currentNode.children=!0,this.openNode(this.currentNode)},D.prototype.openNode=function(I){var N,J,U,ie;if(!I.isOpen){if(!this.root&&this.currentLevel===0&&I.type===e.Element&&(this.root=I),J="",I.type===e.Element){this.writerOptions.state=t.OpenTag,J=this.writer.indent(I,this.writerOptions,this.currentLevel)+"<"+I.name,ie=I.attribs;for(U in ie)A.call(ie,U)&&(N=ie[U],J+=this.writer.attribute(N,this.writerOptions,this.currentLevel));J+=(I.children?">":"/>")+this.writer.endline(I,this.writerOptions,this.currentLevel),this.writerOptions.state=t.InsideTag}else this.writerOptions.state=t.OpenTag,J=this.writer.indent(I,this.writerOptions,this.currentLevel)+"<!DOCTYPE "+I.rootNodeName,I.pubID&&I.sysID?J+=' PUBLIC "'+I.pubID+'" "'+I.sysID+'"':I.sysID&&(J+=' SYSTEM "'+I.sysID+'"'),I.children?(J+=" [",this.writerOptions.state=t.InsideTag):(this.writerOptions.state=t.CloseTag,J+=">"),J+=this.writer.endline(I,this.writerOptions,this.currentLevel);return this.onData(J,this.currentLevel),I.isOpen=!0}},D.prototype.closeNode=function(I){var N;if(!I.isClosed)return N="",this.writerOptions.state=t.CloseTag,I.type===e.Element?N=this.writer.indent(I,this.writerOptions,this.currentLevel)+"</"+I.name+">"+this.writer.endline(I,this.writerOptions,this.currentLevel):N=this.writer.indent(I,this.writerOptions,this.currentLevel)+"]>"+this.writer.endline(I,this.writerOptions,this.currentLevel),this.writerOptions.state=t.None,this.onData(N,this.currentLevel),I.isClosed=!0},D.prototype.onData=function(I,N){return this.documentStarted=!0,this.onDataCallback(I,N+1)},D.prototype.onEnd=function(){return this.documentCompleted=!0,this.onEndCallback()},D.prototype.debugInfo=function(I){return I==null?"":"node: <"+I+">"},D.prototype.ele=function(){return this.element.apply(this,arguments)},D.prototype.nod=function(I,N,J){return this.node(I,N,J)},D.prototype.txt=function(I){return this.text(I)},D.prototype.dat=function(I){return this.cdata(I)},D.prototype.com=function(I){return this.comment(I)},D.prototype.ins=function(I,N){return this.instruction(I,N)},D.prototype.dec=function(I,N,J){return this.declaration(I,N,J)},D.prototype.dtd=function(I,N,J){return this.doctype(I,N,J)},D.prototype.e=function(I,N,J){return this.element(I,N,J)},D.prototype.n=function(I,N,J){return this.node(I,N,J)},D.prototype.t=function(I){return this.text(I)},D.prototype.d=function(I){return this.cdata(I)},D.prototype.c=function(I){return this.comment(I)},D.prototype.r=function(I){return this.raw(I)},D.prototype.i=function(I,N){return this.instruction(I,N)},D.prototype.att=function(){return this.currentNode&&this.currentNode.type===e.DocType?this.attList.apply(this,arguments):this.attribute.apply(this,arguments)},D.prototype.a=function(){return this.currentNode&&this.currentNode.type===e.DocType?this.attList.apply(this,arguments):this.attribute.apply(this,arguments)},D.prototype.ent=function(I,N){return this.entity(I,N)},D.prototype.pent=function(I,N){return this.pEntity(I,N)},D.prototype.not=function(I,N){return this.notation(I,N)},D})()}).call(Jfe)});var rde=E((ede,tde)=>{"use strict";(function(){var e,t,r,n,i=function(s,a){for(var c in a)o.call(a,c)&&(s[c]=a[c]);function u(){this.constructor=s}return u.prototype=a.prototype,s.prototype=new u,s.__super__=a.prototype,s},o={}.hasOwnProperty;e=wr(),n=gL(),t=zg(),tde.exports=r=(function(s){i(a,s);function a(c,u){this.stream=c,a.__super__.constructor.call(this,u)}return a.prototype.endline=function(c,u,l){return c.isLastRootNode&&u.state===t.CloseTag?"":a.__super__.endline.call(this,c,u,l)},a.prototype.document=function(c,u){var l,d,h,f,p,m,_,w,R;for(_=c.children,d=h=0,p=_.length;h<p;d=++h)l=_[d],l.isLastRootNode=d===c.children.length-1;for(u=this.filterOptions(u),w=c.children,R=[],f=0,m=w.length;f<m;f++)l=w[f],R.push(this.writeChildNode(l,u,0));return R},a.prototype.attribute=function(c,u,l){return this.stream.write(a.__super__.attribute.call(this,c,u,l))},a.prototype.cdata=function(c,u,l){return this.stream.write(a.__super__.cdata.call(this,c,u,l))},a.prototype.comment=function(c,u,l){return this.stream.write(a.__super__.comment.call(this,c,u,l))},a.prototype.declaration=function(c,u,l){return this.stream.write(a.__super__.declaration.call(this,c,u,l))},a.prototype.docType=function(c,u,l){var d,h,f,p;if(l||(l=0),this.openNode(c,u,l),u.state=t.OpenTag,this.stream.write(this.indent(c,u,l)),this.stream.write("<!DOCTYPE "+c.root().name),c.pubID&&c.sysID?this.stream.write(' PUBLIC "'+c.pubID+'" "'+c.sysID+'"'):c.sysID&&this.stream.write(' SYSTEM "'+c.sysID+'"'),c.children.length>0){for(this.stream.write(" ["),this.stream.write(this.endline(c,u,l)),u.state=t.InsideTag,p=c.children,h=0,f=p.length;h<f;h++)d=p[h],this.writeChildNode(d,u,l+1);u.state=t.CloseTag,this.stream.write("]")}return u.state=t.CloseTag,this.stream.write(u.spaceBeforeSlash+">"),this.stream.write(this.endline(c,u,l)),u.state=t.None,this.closeNode(c,u,l)},a.prototype.element=function(c,u,l){var d,h,f,p,m,_,w,R,v,y;l||(l=0),this.openNode(c,u,l),u.state=t.OpenTag,this.stream.write(this.indent(c,u,l)+"<"+c.name),v=c.attribs;for(w in v)o.call(v,w)&&(d=v[w],this.attribute(d,u,l));if(f=c.children.length,p=f===0?null:c.children[0],f===0||c.children.every(function(S){return(S.type===e.Text||S.type===e.Raw)&&S.value===""}))u.allowEmpty?(this.stream.write(">"),u.state=t.CloseTag,this.stream.write("</"+c.name+">")):(u.state=t.CloseTag,this.stream.write(u.spaceBeforeSlash+"/>"));else if(u.pretty&&f===1&&(p.type===e.Text||p.type===e.Raw)&&p.value!=null)this.stream.write(">"),u.state=t.InsideTag,u.suppressPrettyCount++,R=!0,this.writeChildNode(p,u,l+1),u.suppressPrettyCount--,R=!1,u.state=t.CloseTag,this.stream.write("</"+c.name+">");else{for(this.stream.write(">"+this.endline(c,u,l)),u.state=t.InsideTag,y=c.children,m=0,_=y.length;m<_;m++)h=y[m],this.writeChildNode(h,u,l+1);u.state=t.CloseTag,this.stream.write(this.indent(c,u,l)+"</"+c.name+">")}return this.stream.write(this.endline(c,u,l)),u.state=t.None,this.closeNode(c,u,l)},a.prototype.processingInstruction=function(c,u,l){return this.stream.write(a.__super__.processingInstruction.call(this,c,u,l))},a.prototype.raw=function(c,u,l){return this.stream.write(a.__super__.raw.call(this,c,u,l))},a.prototype.text=function(c,u,l){return this.stream.write(a.__super__.text.call(this,c,u,l))},a.prototype.dtdAttList=function(c,u,l){return this.stream.write(a.__super__.dtdAttList.call(this,c,u,l))},a.prototype.dtdElement=function(c,u,l){return this.stream.write(a.__super__.dtdElement.call(this,c,u,l))},a.prototype.dtdEntity=function(c,u,l){return this.stream.write(a.__super__.dtdEntity.call(this,c,u,l))},a.prototype.dtdNotation=function(c,u,l){return this.stream.write(a.__super__.dtdNotation.call(this,c,u,l))},a})(n)}).call(ede)});var ide=E((nde,Oc)=>{"use strict";(function(){var e,t,r,n,i,o,s,a,c,u;u=ds(),a=u.assign,c=u.isFunction,r=dL(),n=yL(),i=Zfe(),s=kx(),o=rde(),e=wr(),t=zg(),Oc.exports.create=function(l,d,h,f){var p,m;if(l==null)throw new Error("Root element needs a name.");return f=a({},d,h,f),p=new n(f),m=p.element(l),f.headless||(p.declaration(f),(f.pubID!=null||f.sysID!=null)&&p.dtd(f)),m},Oc.exports.begin=function(l,d,h){var f;return c(l)&&(f=[l,d],d=f[0],h=f[1],l={}),d?new i(l,d,h):new n(l)},Oc.exports.stringWriter=function(l){return new s(l)},Oc.exports.streamWriter=function(l,d){return new o(l,d)},Oc.exports.implementation=new r,Oc.exports.nodeType=e,Oc.exports.writerState=t}).call(nde)});var ode=E(_L=>{"use strict";(function(){"use strict";var e,t,r,n,i,o={}.hasOwnProperty;e=ide(),t=bx().defaults,n=function(s){return typeof s=="string"&&(s.indexOf("&")>=0||s.indexOf(">")>=0||s.indexOf("<")>=0)},i=function(s){return"<![CDATA["+r(s)+"]]>"},r=function(s){return s.replace("]]>","]]]]><![CDATA[>")},_L.Builder=(function(){function s(a){var c,u,l;this.options={},u=t["0.2"];for(c in u)o.call(u,c)&&(l=u[c],this.options[c]=l);for(c in a)o.call(a,c)&&(l=a[c],this.options[c]=l)}return s.prototype.buildObject=function(a){var c,u,l,d,h;return c=this.options.attrkey,u=this.options.charkey,Object.keys(a).length===1&&this.options.rootName===t["0.2"].rootName?(h=Object.keys(a)[0],a=a[h]):h=this.options.rootName,l=(function(f){return function(p,m){var _,w,R,v,y,S;if(typeof m!="object")f.options.cdata&&n(m)?p.raw(i(m)):p.txt(m);else if(Array.isArray(m)){for(v in m)if(o.call(m,v)){w=m[v];for(y in w)R=w[y],p=l(p.ele(y),R).up()}}else for(y in m)if(o.call(m,y))if(w=m[y],y===c){if(typeof w=="object")for(_ in w)S=w[_],p=p.att(_,S)}else if(y===u)f.options.cdata&&n(w)?p=p.raw(i(w)):p=p.txt(w);else if(Array.isArray(w))for(v in w)o.call(w,v)&&(R=w[v],typeof R=="string"?f.options.cdata&&n(R)?p=p.ele(y).raw(i(R)).up():p=p.ele(y,R).up():p=l(p.ele(y),R).up());else typeof w=="object"?p=l(p.ele(y),w).up():typeof w=="string"&&f.options.cdata&&n(w)?p=p.ele(y).raw(i(w)).up():(w==null&&(w=""),p=p.ele(y,w.toString()).up());return p}})(this),d=e.create(h,this.options.xmldec,this.options.doctype,{headless:this.options.headless,allowSurrogateChars:this.options.allowSurrogateChars}),l(d,a).end(this.options.renderOpts)},s})()}).call(_L)});var sde=E(Nx=>{"use strict";(function(e){e.parser=function(P,T){return new r(P,T)},e.SAXParser=r,e.SAXStream=u,e.createStream=c,e.MAX_BUFFER_LENGTH=64*1024;var t=["comment","sgmlDecl","textNode","tagName","doctype","procInstName","procInstBody","entity","attribName","attribValue","cdata","script"];e.EVENTS=["text","processinginstruction","sgmldeclaration","doctype","comment","opentagstart","attribute","opentag","closetag","opencdata","cdata","closecdata","error","end","ready","script","opennamespace","closenamespace"];function r(P,T){if(!(this instanceof r))return new r(P,T);var K=this;i(K),K.q=K.c="",K.bufferCheckPosition=e.MAX_BUFFER_LENGTH,K.opt=T||{},K.opt.lowercase=K.opt.lowercase||K.opt.lowercasetags,K.looseCase=K.opt.lowercase?"toLowerCase":"toUpperCase",K.tags=[],K.closed=K.closedRoot=K.sawRoot=!1,K.tag=K.error=null,K.strict=!!P,K.noscript=!!(P||K.opt.noscript),K.state=A.BEGIN,K.strictEntities=K.opt.strictEntities,K.ENTITIES=K.strictEntities?Object.create(e.XML_ENTITIES):Object.create(e.ENTITIES),K.attribList=[],K.opt.xmlns&&(K.ns=Object.create(p)),K.opt.unquotedAttributeValues===void 0&&(K.opt.unquotedAttributeValues=!P),K.trackPosition=K.opt.position!==!1,K.trackPosition&&(K.position=K.line=K.column=0),I(K,"onready")}Object.create||(Object.create=function(P){function T(){}T.prototype=P;var K=new T;return K}),Object.keys||(Object.keys=function(P){var T=[];for(var K in P)P.hasOwnProperty(K)&&T.push(K);return T});function n(P){for(var T=Math.max(e.MAX_BUFFER_LENGTH,10),K=0,j=0,Be=t.length;j<Be;j++){var yt=P[t[j]].length;if(yt>T)switch(t[j]){case"textNode":J(P);break;case"cdata":N(P,"oncdata",P.cdata),P.cdata="";break;case"script":N(P,"onscript",P.script),P.script="";break;default:ie(P,"Max buffer length exceeded: "+t[j])}K=Math.max(K,yt)}var ft=e.MAX_BUFFER_LENGTH-K;P.bufferCheckPosition=ft+P.position}function i(P){for(var T=0,K=t.length;T<K;T++)P[t[T]]=""}function o(P){J(P),P.cdata!==""&&(N(P,"oncdata",P.cdata),P.cdata=""),P.script!==""&&(N(P,"onscript",P.script),P.script="")}r.prototype={end:function(){be(this)},write:Se,resume:function(){return this.error=null,this},close:function(){return this.write(null)},flush:function(){o(this)}};var s;try{s=require("stream").Stream}catch{s=function(){}}s||(s=function(){});var a=e.EVENTS.filter(function(P){return P!=="error"&&P!=="end"});function c(P,T){return new u(P,T)}function u(P,T){if(!(this instanceof u))return new u(P,T);s.apply(this),this._parser=new r(P,T),this.writable=!0,this.readable=!0;var K=this;this._parser.onend=function(){K.emit("end")},this._parser.onerror=function(j){K.emit("error",j),K._parser.error=null},this._decoder=null,a.forEach(function(j){Object.defineProperty(K,"on"+j,{get:function(){return K._parser["on"+j]},set:function(Be){if(!Be)return K.removeAllListeners(j),K._parser["on"+j]=Be,Be;K.on(j,Be)},enumerable:!0,configurable:!1})})}u.prototype=Object.create(s.prototype,{constructor:{value:u}}),u.prototype.write=function(P){if(typeof Buffer=="function"&&typeof Buffer.isBuffer=="function"&&Buffer.isBuffer(P)){if(!this._decoder){var T=require("string_decoder").StringDecoder;this._decoder=new T("utf8")}P=this._decoder.write(P)}return this._parser.write(P.toString()),this.emit("data",P),!0},u.prototype.end=function(P){return P&&P.length&&this.write(P),this._parser.end(),!0},u.prototype.on=function(P,T){var K=this;return!K._parser["on"+P]&&a.indexOf(P)!==-1&&(K._parser["on"+P]=function(){var j=arguments.length===1?[arguments[0]]:Array.apply(null,arguments);j.splice(0,0,P),K.emit.apply(K,j)}),s.prototype.on.call(K,P,T)};var l="[CDATA[",d="DOCTYPE",h="http://www.w3.org/XML/1998/namespace",f="http://www.w3.org/2000/xmlns/",p={xml:h,xmlns:f},m=/[:_A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]/,_=/[:_A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\u00B7\u0300-\u036F\u203F-\u2040.\d-]/,w=/[#:_A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]/,R=/[#:_A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\u00B7\u0300-\u036F\u203F-\u2040.\d-]/;function v(P){return P===" "||P===`
|
|
280
|
+
`||P==="\r"||P===" "}function y(P){return P==='"'||P==="'"}function S(P){return P===">"||v(P)}function O(P,T){return P.test(T)}function M(P,T){return!O(P,T)}var A=0;e.STATE={BEGIN:A++,BEGIN_WHITESPACE:A++,TEXT:A++,TEXT_ENTITY:A++,OPEN_WAKA:A++,SGML_DECL:A++,SGML_DECL_QUOTED:A++,DOCTYPE:A++,DOCTYPE_QUOTED:A++,DOCTYPE_DTD:A++,DOCTYPE_DTD_QUOTED:A++,COMMENT_STARTING:A++,COMMENT:A++,COMMENT_ENDING:A++,COMMENT_ENDED:A++,CDATA:A++,CDATA_ENDING:A++,CDATA_ENDING_2:A++,PROC_INST:A++,PROC_INST_BODY:A++,PROC_INST_ENDING:A++,OPEN_TAG:A++,OPEN_TAG_SLASH:A++,ATTRIB:A++,ATTRIB_NAME:A++,ATTRIB_NAME_SAW_WHITE:A++,ATTRIB_VALUE:A++,ATTRIB_VALUE_QUOTED:A++,ATTRIB_VALUE_CLOSED:A++,ATTRIB_VALUE_UNQUOTED:A++,ATTRIB_VALUE_ENTITY_Q:A++,ATTRIB_VALUE_ENTITY_U:A++,CLOSE_TAG:A++,CLOSE_TAG_SAW_WHITE:A++,SCRIPT:A++,SCRIPT_ENDING:A++},e.XML_ENTITIES={amp:"&",gt:">",lt:"<",quot:'"',apos:"'"},e.ENTITIES={amp:"&",gt:">",lt:"<",quot:'"',apos:"'",AElig:198,Aacute:193,Acirc:194,Agrave:192,Aring:197,Atilde:195,Auml:196,Ccedil:199,ETH:208,Eacute:201,Ecirc:202,Egrave:200,Euml:203,Iacute:205,Icirc:206,Igrave:204,Iuml:207,Ntilde:209,Oacute:211,Ocirc:212,Ograve:210,Oslash:216,Otilde:213,Ouml:214,THORN:222,Uacute:218,Ucirc:219,Ugrave:217,Uuml:220,Yacute:221,aacute:225,acirc:226,aelig:230,agrave:224,aring:229,atilde:227,auml:228,ccedil:231,eacute:233,ecirc:234,egrave:232,eth:240,euml:235,iacute:237,icirc:238,igrave:236,iuml:239,ntilde:241,oacute:243,ocirc:244,ograve:242,oslash:248,otilde:245,ouml:246,szlig:223,thorn:254,uacute:250,ucirc:251,ugrave:249,uuml:252,yacute:253,yuml:255,copy:169,reg:174,nbsp:160,iexcl:161,cent:162,pound:163,curren:164,yen:165,brvbar:166,sect:167,uml:168,ordf:170,laquo:171,not:172,shy:173,macr:175,deg:176,plusmn:177,sup1:185,sup2:178,sup3:179,acute:180,micro:181,para:182,middot:183,cedil:184,ordm:186,raquo:187,frac14:188,frac12:189,frac34:190,iquest:191,times:215,divide:247,OElig:338,oelig:339,Scaron:352,scaron:353,Yuml:376,fnof:402,circ:710,tilde:732,Alpha:913,Beta:914,Gamma:915,Delta:916,Epsilon:917,Zeta:918,Eta:919,Theta:920,Iota:921,Kappa:922,Lambda:923,Mu:924,Nu:925,Xi:926,Omicron:927,Pi:928,Rho:929,Sigma:931,Tau:932,Upsilon:933,Phi:934,Chi:935,Psi:936,Omega:937,alpha:945,beta:946,gamma:947,delta:948,epsilon:949,zeta:950,eta:951,theta:952,iota:953,kappa:954,lambda:955,mu:956,nu:957,xi:958,omicron:959,pi:960,rho:961,sigmaf:962,sigma:963,tau:964,upsilon:965,phi:966,chi:967,psi:968,omega:969,thetasym:977,upsih:978,piv:982,ensp:8194,emsp:8195,thinsp:8201,zwnj:8204,zwj:8205,lrm:8206,rlm:8207,ndash:8211,mdash:8212,lsquo:8216,rsquo:8217,sbquo:8218,ldquo:8220,rdquo:8221,bdquo:8222,dagger:8224,Dagger:8225,bull:8226,hellip:8230,permil:8240,prime:8242,Prime:8243,lsaquo:8249,rsaquo:8250,oline:8254,frasl:8260,euro:8364,image:8465,weierp:8472,real:8476,trade:8482,alefsym:8501,larr:8592,uarr:8593,rarr:8594,darr:8595,harr:8596,crarr:8629,lArr:8656,uArr:8657,rArr:8658,dArr:8659,hArr:8660,forall:8704,part:8706,exist:8707,empty:8709,nabla:8711,isin:8712,notin:8713,ni:8715,prod:8719,sum:8721,minus:8722,lowast:8727,radic:8730,prop:8733,infin:8734,ang:8736,and:8743,or:8744,cap:8745,cup:8746,int:8747,there4:8756,sim:8764,cong:8773,asymp:8776,ne:8800,equiv:8801,le:8804,ge:8805,sub:8834,sup:8835,nsub:8836,sube:8838,supe:8839,oplus:8853,otimes:8855,perp:8869,sdot:8901,lceil:8968,rceil:8969,lfloor:8970,rfloor:8971,lang:9001,rang:9002,loz:9674,spades:9824,clubs:9827,hearts:9829,diams:9830},Object.keys(e.ENTITIES).forEach(function(P){var T=e.ENTITIES[P],K=typeof T=="number"?String.fromCharCode(T):T;e.ENTITIES[P]=K});for(var D in e.STATE)e.STATE[e.STATE[D]]=D;A=e.STATE;function I(P,T,K){P[T]&&P[T](K)}function N(P,T,K){P.textNode&&J(P),I(P,T,K)}function J(P){P.textNode=U(P.opt,P.textNode),P.textNode&&I(P,"ontext",P.textNode),P.textNode=""}function U(P,T){return P.trim&&(T=T.trim()),P.normalize&&(T=T.replace(/\s+/g," ")),T}function ie(P,T){return J(P),P.trackPosition&&(T+=`
|
|
281
|
+
Line: `+P.line+`
|
|
282
|
+
Column: `+P.column+`
|
|
283
|
+
Char: `+P.c),T=new Error(T),P.error=T,I(P,"onerror",T),P}function be(P){return P.sawRoot&&!P.closedRoot&&B(P,"Unclosed root tag"),P.state!==A.BEGIN&&P.state!==A.BEGIN_WHITESPACE&&P.state!==A.TEXT&&ie(P,"Unexpected end"),J(P),P.c="",P.closed=!0,I(P,"onend"),r.call(P,P.strict,P.opt),P}function B(P,T){if(typeof P!="object"||!(P instanceof r))throw new Error("bad call to strictFail");P.strict&&ie(P,T)}function te(P){P.strict||(P.tagName=P.tagName[P.looseCase]());var T=P.tags[P.tags.length-1]||P,K=P.tag={name:P.tagName,attributes:{}};P.opt.xmlns&&(K.ns=T.ns),P.attribList.length=0,N(P,"onopentagstart",K)}function ge(P,T){var K=P.indexOf(":"),j=K<0?["",P]:P.split(":"),Be=j[0],yt=j[1];return T&&P==="xmlns"&&(Be="xmlns",yt=""),{prefix:Be,local:yt}}function $(P){if(P.strict||(P.attribName=P.attribName[P.looseCase]()),P.attribList.indexOf(P.attribName)!==-1||P.tag.attributes.hasOwnProperty(P.attribName)){P.attribName=P.attribValue="";return}if(P.opt.xmlns){var T=ge(P.attribName,!0),K=T.prefix,j=T.local;if(K==="xmlns")if(j==="xml"&&P.attribValue!==h)B(P,"xml: prefix must be bound to "+h+`
|
|
284
|
+
Actual: `+P.attribValue);else if(j==="xmlns"&&P.attribValue!==f)B(P,"xmlns: prefix must be bound to "+f+`
|
|
285
|
+
Actual: `+P.attribValue);else{var Be=P.tag,yt=P.tags[P.tags.length-1]||P;Be.ns===yt.ns&&(Be.ns=Object.create(yt.ns)),Be.ns[j]=P.attribValue}P.attribList.push([P.attribName,P.attribValue])}else P.tag.attributes[P.attribName]=P.attribValue,N(P,"onattribute",{name:P.attribName,value:P.attribValue});P.attribName=P.attribValue=""}function ve(P,T){if(P.opt.xmlns){var K=P.tag,j=ge(P.tagName);K.prefix=j.prefix,K.local=j.local,K.uri=K.ns[j.prefix]||"",K.prefix&&!K.uri&&(B(P,"Unbound namespace prefix: "+JSON.stringify(P.tagName)),K.uri=j.prefix);var Be=P.tags[P.tags.length-1]||P;K.ns&&Be.ns!==K.ns&&Object.keys(K.ns).forEach(function(ra){N(P,"onopennamespace",{prefix:ra,uri:K.ns[ra]})});for(var yt=0,ft=P.attribList.length;yt<ft;yt++){var wt=P.attribList[yt],Dt=wt[0],Ur=wt[1],Tt=ge(Dt,!0),gr=Tt.prefix,Qi=Tt.local,ta=gr===""?"":K.ns[gr]||"",Pi={name:Dt,value:Ur,prefix:gr,local:Qi,uri:ta};gr&&gr!=="xmlns"&&!ta&&(B(P,"Unbound namespace prefix: "+JSON.stringify(gr)),Pi.uri=gr),P.tag.attributes[Dt]=Pi,N(P,"onattribute",Pi)}P.attribList.length=0}P.tag.isSelfClosing=!!T,P.sawRoot=!0,P.tags.push(P.tag),N(P,"onopentag",P.tag),T||(!P.noscript&&P.tagName.toLowerCase()==="script"?P.state=A.SCRIPT:P.state=A.TEXT,P.tag=null,P.tagName=""),P.attribName=P.attribValue="",P.attribList.length=0}function Ze(P){if(!P.tagName){B(P,"Weird empty close tag."),P.textNode+="</>",P.state=A.TEXT;return}if(P.script){if(P.tagName!=="script"){P.script+="</"+P.tagName+">",P.tagName="",P.state=A.SCRIPT;return}N(P,"onscript",P.script),P.script=""}var T=P.tags.length,K=P.tagName;P.strict||(K=K[P.looseCase]());for(var j=K;T--;){var Be=P.tags[T];if(Be.name!==j)B(P,"Unexpected close tag");else break}if(T<0){B(P,"Unmatched closing tag: "+P.tagName),P.textNode+="</"+P.tagName+">",P.state=A.TEXT;return}P.tagName=K;for(var yt=P.tags.length;yt-- >T;){var ft=P.tag=P.tags.pop();P.tagName=P.tag.name,N(P,"onclosetag",P.tagName);var wt={};for(var Dt in ft.ns)wt[Dt]=ft.ns[Dt];var Ur=P.tags[P.tags.length-1]||P;P.opt.xmlns&&ft.ns!==Ur.ns&&Object.keys(ft.ns).forEach(function(Tt){var gr=ft.ns[Tt];N(P,"onclosenamespace",{prefix:Tt,uri:gr})})}T===0&&(P.closedRoot=!0),P.tagName=P.attribValue=P.attribName="",P.attribList.length=0,P.state=A.TEXT}function at(P){var T=P.entity,K=T.toLowerCase(),j,Be="";return P.ENTITIES[T]?P.ENTITIES[T]:P.ENTITIES[K]?P.ENTITIES[K]:(T=K,T.charAt(0)==="#"&&(T.charAt(1)==="x"?(T=T.slice(2),j=parseInt(T,16),Be=j.toString(16)):(T=T.slice(1),j=parseInt(T,10),Be=j.toString(10))),T=T.replace(/^0+/,""),isNaN(j)||Be.toLowerCase()!==T||j<0||j>1114111?(B(P,"Invalid character entity"),"&"+P.entity+";"):String.fromCodePoint(j))}function G(P,T){T==="<"?(P.state=A.OPEN_WAKA,P.startTagPosition=P.position):v(T)||(B(P,"Non-whitespace before first tag."),P.textNode=T,P.state=A.TEXT)}function ce(P,T){var K="";return T<P.length&&(K=P.charAt(T)),K}function Se(P){var T=this;if(this.error)throw this.error;if(T.closed)return ie(T,"Cannot write after close. Assign an onready handler.");if(P===null)return be(T);typeof P=="object"&&(P=P.toString());for(var K=0,j="";j=ce(P,K++),T.c=j,!!j;)switch(T.trackPosition&&(T.position++,j===`
|
|
286
|
+
`?(T.line++,T.column=0):T.column++),T.state){case A.BEGIN:if(T.state=A.BEGIN_WHITESPACE,j==="\uFEFF")continue;G(T,j);continue;case A.BEGIN_WHITESPACE:G(T,j);continue;case A.TEXT:if(T.sawRoot&&!T.closedRoot){for(var yt=K-1;j&&j!=="<"&&j!=="&";)j=ce(P,K++),j&&T.trackPosition&&(T.position++,j===`
|
|
287
|
+
`?(T.line++,T.column=0):T.column++);T.textNode+=P.substring(yt,K-1)}j==="<"&&!(T.sawRoot&&T.closedRoot&&!T.strict)?(T.state=A.OPEN_WAKA,T.startTagPosition=T.position):(!v(j)&&(!T.sawRoot||T.closedRoot)&&B(T,"Text data outside of root node."),j==="&"?T.state=A.TEXT_ENTITY:T.textNode+=j);continue;case A.SCRIPT:j==="<"?T.state=A.SCRIPT_ENDING:T.script+=j;continue;case A.SCRIPT_ENDING:j==="/"?T.state=A.CLOSE_TAG:(T.script+="<"+j,T.state=A.SCRIPT);continue;case A.OPEN_WAKA:if(j==="!")T.state=A.SGML_DECL,T.sgmlDecl="";else if(!v(j))if(O(m,j))T.state=A.OPEN_TAG,T.tagName=j;else if(j==="/")T.state=A.CLOSE_TAG,T.tagName="";else if(j==="?")T.state=A.PROC_INST,T.procInstName=T.procInstBody="";else{if(B(T,"Unencoded <"),T.startTagPosition+1<T.position){var Be=T.position-T.startTagPosition;j=new Array(Be).join(" ")+j}T.textNode+="<"+j,T.state=A.TEXT}continue;case A.SGML_DECL:if(T.sgmlDecl+j==="--"){T.state=A.COMMENT,T.comment="",T.sgmlDecl="";continue}T.doctype&&T.doctype!==!0&&T.sgmlDecl?(T.state=A.DOCTYPE_DTD,T.doctype+="<!"+T.sgmlDecl+j,T.sgmlDecl=""):(T.sgmlDecl+j).toUpperCase()===l?(N(T,"onopencdata"),T.state=A.CDATA,T.sgmlDecl="",T.cdata=""):(T.sgmlDecl+j).toUpperCase()===d?(T.state=A.DOCTYPE,(T.doctype||T.sawRoot)&&B(T,"Inappropriately located doctype declaration"),T.doctype="",T.sgmlDecl=""):j===">"?(N(T,"onsgmldeclaration",T.sgmlDecl),T.sgmlDecl="",T.state=A.TEXT):(y(j)&&(T.state=A.SGML_DECL_QUOTED),T.sgmlDecl+=j);continue;case A.SGML_DECL_QUOTED:j===T.q&&(T.state=A.SGML_DECL,T.q=""),T.sgmlDecl+=j;continue;case A.DOCTYPE:j===">"?(T.state=A.TEXT,N(T,"ondoctype",T.doctype),T.doctype=!0):(T.doctype+=j,j==="["?T.state=A.DOCTYPE_DTD:y(j)&&(T.state=A.DOCTYPE_QUOTED,T.q=j));continue;case A.DOCTYPE_QUOTED:T.doctype+=j,j===T.q&&(T.q="",T.state=A.DOCTYPE);continue;case A.DOCTYPE_DTD:j==="]"?(T.doctype+=j,T.state=A.DOCTYPE):j==="<"?(T.state=A.OPEN_WAKA,T.startTagPosition=T.position):y(j)?(T.doctype+=j,T.state=A.DOCTYPE_DTD_QUOTED,T.q=j):T.doctype+=j;continue;case A.DOCTYPE_DTD_QUOTED:T.doctype+=j,j===T.q&&(T.state=A.DOCTYPE_DTD,T.q="");continue;case A.COMMENT:j==="-"?T.state=A.COMMENT_ENDING:T.comment+=j;continue;case A.COMMENT_ENDING:j==="-"?(T.state=A.COMMENT_ENDED,T.comment=U(T.opt,T.comment),T.comment&&N(T,"oncomment",T.comment),T.comment=""):(T.comment+="-"+j,T.state=A.COMMENT);continue;case A.COMMENT_ENDED:j!==">"?(B(T,"Malformed comment"),T.comment+="--"+j,T.state=A.COMMENT):T.doctype&&T.doctype!==!0?T.state=A.DOCTYPE_DTD:T.state=A.TEXT;continue;case A.CDATA:for(var yt=K-1;j&&j!=="]";)j=ce(P,K++),j&&T.trackPosition&&(T.position++,j===`
|
|
288
|
+
`?(T.line++,T.column=0):T.column++);T.cdata+=P.substring(yt,K-1),j==="]"&&(T.state=A.CDATA_ENDING);continue;case A.CDATA_ENDING:j==="]"?T.state=A.CDATA_ENDING_2:(T.cdata+="]"+j,T.state=A.CDATA);continue;case A.CDATA_ENDING_2:j===">"?(T.cdata&&N(T,"oncdata",T.cdata),N(T,"onclosecdata"),T.cdata="",T.state=A.TEXT):j==="]"?T.cdata+="]":(T.cdata+="]]"+j,T.state=A.CDATA);continue;case A.PROC_INST:j==="?"?T.state=A.PROC_INST_ENDING:v(j)?T.state=A.PROC_INST_BODY:T.procInstName+=j;continue;case A.PROC_INST_BODY:if(!T.procInstBody&&v(j))continue;j==="?"?T.state=A.PROC_INST_ENDING:T.procInstBody+=j;continue;case A.PROC_INST_ENDING:j===">"?(N(T,"onprocessinginstruction",{name:T.procInstName,body:T.procInstBody}),T.procInstName=T.procInstBody="",T.state=A.TEXT):(T.procInstBody+="?"+j,T.state=A.PROC_INST_BODY);continue;case A.OPEN_TAG:O(_,j)?T.tagName+=j:(te(T),j===">"?ve(T):j==="/"?T.state=A.OPEN_TAG_SLASH:(v(j)||B(T,"Invalid character in tag name"),T.state=A.ATTRIB));continue;case A.OPEN_TAG_SLASH:j===">"?(ve(T,!0),Ze(T)):(B(T,"Forward-slash in opening tag not followed by >"),T.state=A.ATTRIB);continue;case A.ATTRIB:if(v(j))continue;j===">"?ve(T):j==="/"?T.state=A.OPEN_TAG_SLASH:O(m,j)?(T.attribName=j,T.attribValue="",T.state=A.ATTRIB_NAME):B(T,"Invalid attribute name");continue;case A.ATTRIB_NAME:j==="="?T.state=A.ATTRIB_VALUE:j===">"?(B(T,"Attribute without value"),T.attribValue=T.attribName,$(T),ve(T)):v(j)?T.state=A.ATTRIB_NAME_SAW_WHITE:O(_,j)?T.attribName+=j:B(T,"Invalid attribute name");continue;case A.ATTRIB_NAME_SAW_WHITE:if(j==="=")T.state=A.ATTRIB_VALUE;else{if(v(j))continue;B(T,"Attribute without value"),T.tag.attributes[T.attribName]="",T.attribValue="",N(T,"onattribute",{name:T.attribName,value:""}),T.attribName="",j===">"?ve(T):O(m,j)?(T.attribName=j,T.state=A.ATTRIB_NAME):(B(T,"Invalid attribute name"),T.state=A.ATTRIB)}continue;case A.ATTRIB_VALUE:if(v(j))continue;y(j)?(T.q=j,T.state=A.ATTRIB_VALUE_QUOTED):(T.opt.unquotedAttributeValues||ie(T,"Unquoted attribute value"),T.state=A.ATTRIB_VALUE_UNQUOTED,T.attribValue=j);continue;case A.ATTRIB_VALUE_QUOTED:if(j!==T.q){j==="&"?T.state=A.ATTRIB_VALUE_ENTITY_Q:T.attribValue+=j;continue}$(T),T.q="",T.state=A.ATTRIB_VALUE_CLOSED;continue;case A.ATTRIB_VALUE_CLOSED:v(j)?T.state=A.ATTRIB:j===">"?ve(T):j==="/"?T.state=A.OPEN_TAG_SLASH:O(m,j)?(B(T,"No whitespace between attributes"),T.attribName=j,T.attribValue="",T.state=A.ATTRIB_NAME):B(T,"Invalid attribute name");continue;case A.ATTRIB_VALUE_UNQUOTED:if(!S(j)){j==="&"?T.state=A.ATTRIB_VALUE_ENTITY_U:T.attribValue+=j;continue}$(T),j===">"?ve(T):T.state=A.ATTRIB;continue;case A.CLOSE_TAG:if(T.tagName)j===">"?Ze(T):O(_,j)?T.tagName+=j:T.script?(T.script+="</"+T.tagName,T.tagName="",T.state=A.SCRIPT):(v(j)||B(T,"Invalid tagname in closing tag"),T.state=A.CLOSE_TAG_SAW_WHITE);else{if(v(j))continue;M(m,j)?T.script?(T.script+="</"+j,T.state=A.SCRIPT):B(T,"Invalid tagname in closing tag."):T.tagName=j}continue;case A.CLOSE_TAG_SAW_WHITE:if(v(j))continue;j===">"?Ze(T):B(T,"Invalid characters in closing tag");continue;case A.TEXT_ENTITY:case A.ATTRIB_VALUE_ENTITY_Q:case A.ATTRIB_VALUE_ENTITY_U:var ft,wt;switch(T.state){case A.TEXT_ENTITY:ft=A.TEXT,wt="textNode";break;case A.ATTRIB_VALUE_ENTITY_Q:ft=A.ATTRIB_VALUE_QUOTED,wt="attribValue";break;case A.ATTRIB_VALUE_ENTITY_U:ft=A.ATTRIB_VALUE_UNQUOTED,wt="attribValue";break}if(j===";"){var Dt=at(T);T.opt.unparsedEntities&&!Object.values(e.XML_ENTITIES).includes(Dt)?(T.entity="",T.state=ft,T.write(Dt)):(T[wt]+=Dt,T.entity="",T.state=ft)}else O(T.entity.length?R:w,j)?T.entity+=j:(B(T,"Invalid character in entity name"),T[wt]+="&"+T.entity+j,T.entity="",T.state=ft);continue;default:throw new Error(T,"Unknown state: "+T.state)}return T.position>=T.bufferCheckPosition&&n(T),T}String.fromCodePoint||(function(){var P=String.fromCharCode,T=Math.floor,K=function(){var j=16384,Be=[],yt,ft,wt=-1,Dt=arguments.length;if(!Dt)return"";for(var Ur="";++wt<Dt;){var Tt=Number(arguments[wt]);if(!isFinite(Tt)||Tt<0||Tt>1114111||T(Tt)!==Tt)throw RangeError("Invalid code point: "+Tt);Tt<=65535?Be.push(Tt):(Tt-=65536,yt=(Tt>>10)+55296,ft=Tt%1024+56320,Be.push(yt,ft)),(wt+1===Dt||Be.length>j)&&(Ur+=P.apply(null,Be),Be.length=0)}return Ur};Object.defineProperty?Object.defineProperty(String,"fromCodePoint",{value:K,configurable:!0,writable:!0}):String.fromCodePoint=K})()})(typeof Nx>"u"?Nx.sax={}:Nx)});var ade=E(bL=>{"use strict";(function(){"use strict";bL.stripBOM=function(e){return e[0]==="\uFEFF"?e.substring(1):e}}).call(bL)});var EL=E(nl=>{"use strict";(function(){"use strict";var e;e=new RegExp(/(?!xmlns)^.*:/),nl.normalize=function(t){return t.toLowerCase()},nl.firstCharLowerCase=function(t){return t.charAt(0).toLowerCase()+t.slice(1)},nl.stripPrefix=function(t){return t.replace(e,"")},nl.parseNumbers=function(t){return isNaN(t)||(t=t%1===0?parseInt(t,10):parseFloat(t)),t},nl.parseBooleans=function(t){return/^(?:true|false)$/i.test(t)&&(t=t.toLowerCase()==="true"),t}}).call(nl)});var cde=E(Zs=>{"use strict";(function(){"use strict";var e,t,r,n,i,o,s,a,c,u=function(h,f){return function(){return h.apply(f,arguments)}},l=function(h,f){for(var p in f)d.call(f,p)&&(h[p]=f[p]);function m(){this.constructor=h}return m.prototype=f.prototype,h.prototype=new m,h.__super__=f.prototype,h},d={}.hasOwnProperty;a=sde(),n=require("events"),e=ade(),s=EL(),c=require("timers").setImmediate,t=bx().defaults,i=function(h){return typeof h=="object"&&h!=null&&Object.keys(h).length===0},o=function(h,f,p){var m,_,w;for(m=0,_=h.length;m<_;m++)w=h[m],f=w(f,p);return f},r=function(h,f,p){var m;return m=Object.create(null),m.value=p,m.writable=!0,m.enumerable=!0,m.configurable=!0,Object.defineProperty(h,f,m)},Zs.Parser=(function(h){l(f,h);function f(p){this.parseStringPromise=u(this.parseStringPromise,this),this.parseString=u(this.parseString,this),this.reset=u(this.reset,this),this.assignOrPush=u(this.assignOrPush,this),this.processAsync=u(this.processAsync,this);var m,_,w;if(!(this instanceof Zs.Parser))return new Zs.Parser(p);this.options={},_=t["0.2"];for(m in _)d.call(_,m)&&(w=_[m],this.options[m]=w);for(m in p)d.call(p,m)&&(w=p[m],this.options[m]=w);this.options.xmlns&&(this.options.xmlnskey=this.options.attrkey+"ns"),this.options.normalizeTags&&(this.options.tagNameProcessors||(this.options.tagNameProcessors=[]),this.options.tagNameProcessors.unshift(s.normalize)),this.reset()}return f.prototype.processAsync=function(){var p,m;try{return this.remaining.length<=this.options.chunkSize?(p=this.remaining,this.remaining="",this.saxParser=this.saxParser.write(p),this.saxParser.close()):(p=this.remaining.substr(0,this.options.chunkSize),this.remaining=this.remaining.substr(this.options.chunkSize,this.remaining.length),this.saxParser=this.saxParser.write(p),c(this.processAsync))}catch(_){if(m=_,!this.saxParser.errThrown)return this.saxParser.errThrown=!0,this.emit(m)}},f.prototype.assignOrPush=function(p,m,_){return m in p?(p[m]instanceof Array||r(p,m,[p[m]]),p[m].push(_)):this.options.explicitArray?r(p,m,[_]):r(p,m,_)},f.prototype.reset=function(){var p,m,_,w;return this.removeAllListeners(),this.saxParser=a.parser(this.options.strict,{trim:!1,normalize:!1,xmlns:this.options.xmlns}),this.saxParser.errThrown=!1,this.saxParser.onerror=(function(R){return function(v){if(R.saxParser.resume(),!R.saxParser.errThrown)return R.saxParser.errThrown=!0,R.emit("error",v)}})(this),this.saxParser.onend=(function(R){return function(){if(!R.saxParser.ended)return R.saxParser.ended=!0,R.emit("end",R.resultObject)}})(this),this.saxParser.ended=!1,this.EXPLICIT_CHARKEY=this.options.explicitCharkey,this.resultObject=null,w=[],p=this.options.attrkey,m=this.options.charkey,this.saxParser.onopentag=(function(R){return function(v){var y,S,O,M,A;if(O={},O[m]="",!R.options.ignoreAttrs){A=v.attributes;for(y in A)d.call(A,y)&&(!(p in O)&&!R.options.mergeAttrs&&(O[p]={}),S=R.options.attrValueProcessors?o(R.options.attrValueProcessors,v.attributes[y],y):v.attributes[y],M=R.options.attrNameProcessors?o(R.options.attrNameProcessors,y):y,R.options.mergeAttrs?R.assignOrPush(O,M,S):r(O[p],M,S))}return O["#name"]=R.options.tagNameProcessors?o(R.options.tagNameProcessors,v.name):v.name,R.options.xmlns&&(O[R.options.xmlnskey]={uri:v.uri,local:v.local}),w.push(O)}})(this),this.saxParser.onclosetag=(function(R){return function(){var v,y,S,O,M,A,D,I,N,J;if(A=w.pop(),M=A["#name"],(!R.options.explicitChildren||!R.options.preserveChildrenOrder)&&delete A["#name"],A.cdata===!0&&(v=A.cdata,delete A.cdata),N=w[w.length-1],A[m].match(/^\s*$/)&&!v?(y=A[m],delete A[m]):(R.options.trim&&(A[m]=A[m].trim()),R.options.normalize&&(A[m]=A[m].replace(/\s{2,}/g," ").trim()),A[m]=R.options.valueProcessors?o(R.options.valueProcessors,A[m],M):A[m],Object.keys(A).length===1&&m in A&&!R.EXPLICIT_CHARKEY&&(A=A[m])),i(A)&&(typeof R.options.emptyTag=="function"?A=R.options.emptyTag():A=R.options.emptyTag!==""?R.options.emptyTag:y),R.options.validator!=null&&(J="/"+(function(){var U,ie,be;for(be=[],U=0,ie=w.length;U<ie;U++)O=w[U],be.push(O["#name"]);return be})().concat(M).join("/"),(function(){var U;try{return A=R.options.validator(J,N&&N[M],A)}catch(ie){return U=ie,R.emit("error",U)}})()),R.options.explicitChildren&&!R.options.mergeAttrs&&typeof A=="object"){if(!R.options.preserveChildrenOrder)O={},R.options.attrkey in A&&(O[R.options.attrkey]=A[R.options.attrkey],delete A[R.options.attrkey]),!R.options.charsAsChildren&&R.options.charkey in A&&(O[R.options.charkey]=A[R.options.charkey],delete A[R.options.charkey]),Object.getOwnPropertyNames(A).length>0&&(O[R.options.childkey]=A),A=O;else if(N){N[R.options.childkey]=N[R.options.childkey]||[],D={};for(S in A)d.call(A,S)&&r(D,S,A[S]);N[R.options.childkey].push(D),delete A["#name"],Object.keys(A).length===1&&m in A&&!R.EXPLICIT_CHARKEY&&(A=A[m])}}return w.length>0?R.assignOrPush(N,M,A):(R.options.explicitRoot&&(I=A,A={},r(A,M,I)),R.resultObject=A,R.saxParser.ended=!0,R.emit("end",R.resultObject))}})(this),_=(function(R){return function(v){var y,S;if(S=w[w.length-1],S)return S[m]+=v,R.options.explicitChildren&&R.options.preserveChildrenOrder&&R.options.charsAsChildren&&(R.options.includeWhiteChars||v.replace(/\\n/g,"").trim()!=="")&&(S[R.options.childkey]=S[R.options.childkey]||[],y={"#name":"__text__"},y[m]=v,R.options.normalize&&(y[m]=y[m].replace(/\s{2,}/g," ").trim()),S[R.options.childkey].push(y)),S}})(this),this.saxParser.ontext=_,this.saxParser.oncdata=(function(R){return function(v){var y;if(y=_(v),y)return y.cdata=!0}})(this)},f.prototype.parseString=function(p,m){var _;m!=null&&typeof m=="function"&&(this.on("end",function(w){return this.reset(),m(null,w)}),this.on("error",function(w){return this.reset(),m(w)}));try{return p=p.toString(),p.trim()===""?(this.emit("end",null),!0):(p=e.stripBOM(p),this.options.async?(this.remaining=p,c(this.processAsync),this.saxParser):this.saxParser.write(p).close())}catch(w){if(_=w,this.saxParser.errThrown||this.saxParser.ended){if(this.saxParser.ended)throw _}else return this.emit("error",_),this.saxParser.errThrown=!0}},f.prototype.parseStringPromise=function(p){return new Promise((function(m){return function(_,w){return m.parseString(p,function(R,v){return R?w(R):_(v)})}})(this))},f})(n),Zs.parseString=function(h,f,p){var m,_,w;return p!=null?(typeof p=="function"&&(m=p),typeof f=="object"&&(_=f)):(typeof f=="function"&&(m=f),_={}),w=new Zs.Parser(_),w.parseString(h,m)},Zs.parseStringPromise=function(h,f){var p,m;return typeof f=="object"&&(p=f),m=new Zs.Parser(p),m.parseStringPromise(h)}}).call(Zs)});var ude=E(ea=>{"use strict";(function(){"use strict";var e,t,r,n,i=function(s,a){for(var c in a)o.call(a,c)&&(s[c]=a[c]);function u(){this.constructor=s}return u.prototype=a.prototype,s.prototype=new u,s.__super__=a.prototype,s},o={}.hasOwnProperty;t=bx(),e=ode(),r=cde(),n=EL(),ea.defaults=t.defaults,ea.processors=n,ea.ValidationError=(function(s){i(a,s);function a(c){this.message=c}return a})(Error),ea.Builder=e.Builder,ea.Parser=r.Parser,ea.parseString=r.parseString,ea.parseStringPromise=r.parseStringPromise}).call(ea)});var eut={};Nn(eut,{ConnectorRunnerFile:()=>SL});module.exports=Ve(eut);var Jd=z(require("node:process")),Qg=class{#e="connector-runtime";#t;constructor(t,r){this.#t=r,Jd.default.on?Jd.default.on("message",n=>{n.cmd===this.#e&&r.logger.verbose(`${Jd.default.pid} Received message from parent process:`,n)}):r.logger.warn("IPC channel is not available. process.on is undefined."),Jd.default.send||r.logger.warn("IPC channel is not available. process.send is undefined."),t.actions?.forEach(n=>{if(n.config.templates===void 0)return;let i={};Object.entries(n.config.templates).forEach(([o,s])=>{try{i[o]=r.templating.compile(s)}catch(a){r.logger.error(`Error compiling template ${o} for action ${n.identifier}`,a)}}),n.config.parsedTemplates=i})}init=()=>Promise.resolve();start=()=>Promise.resolve();stop=()=>Promise.resolve();set callbackFunction(t){this.connectorSDK.receiver.registerCallback(this.#r(t))}get connectorSDK(){return this.#t}#r(t){return async r=>{let n=await this.#t.receiver.getActionConfig(r);return n?t(r,n):this.#t.receiver.responses.badRequest("Action not found")(r)}}};var hn=class{info(){}debug(){}error(){}warn(){}verbose(){}};var pde=z(require("node:events")),hde=z(require("node:path"));function Ao(e,t){if(!t.startsWith("file://"))return t;let r=e.pathAsDsn("/");if(t.startsWith(r))return t.slice(r.length-1);throw new Error(`Local path must be of the right format matching the local file SDK, got: ${t}`)}var Qd=class{static TYPE="delete";#e;#t;#r;constructor(t,r,n=new hn){this.#e=t,this.#t=r,this.#r=n}async execute(t){let{remotePath:r,localPath:n}=t;if(!r&&!n)throw new Error("Missing required parameter: remotePath or localPath");if(r&&n)throw new Error("Choose one parameter: remotePath or localPath");this.#r.debug(`Deleting file at ${r??n}`);try{n?await this.#t.delete(Ao(this.#t,n)):r&&await this.#e.delete(r)}catch(i){throw this.#r.error(`Error deleting file at ${r??n}: ${i instanceof Error?i.message:"Unknown error"}`),i}}};var CL=z(require("crypto")),ey=new Uint8Array(256),Zg=ey.length;function Fx(){return Zg>ey.length-16&&(CL.default.randomFillSync(ey),Zg=0),ey.slice(Zg,Zg+=16)}var rn=[];for(let e=0;e<256;++e)rn.push((e+256).toString(16).slice(1));function xL(e,t=0){return rn[e[t+0]]+rn[e[t+1]]+rn[e[t+2]]+rn[e[t+3]]+"-"+rn[e[t+4]]+rn[e[t+5]]+"-"+rn[e[t+6]]+rn[e[t+7]]+"-"+rn[e[t+8]]+rn[e[t+9]]+"-"+rn[e[t+10]]+rn[e[t+11]]+rn[e[t+12]]+rn[e[t+13]]+rn[e[t+14]]+rn[e[t+15]]}var TL=z(require("crypto")),qx={randomUUID:TL.default.randomUUID};function Ede(e,t,r){if(qx.randomUUID&&!t&&!e)return qx.randomUUID();e=e||{};let n=e.random||(e.rng||Fx)();if(n[6]=n[6]&15|64,n[8]=n[8]&63|128,t){r=r||0;for(let i=0;i<16;++i)t[r+i]=n[i];return t}return xL(n)}var Zd=Ede;var ep=class{static TYPE="download";#e;#t;#r;constructor(t,r,n=new hn){this.#e=t,this.#t=r,this.#r=n}async execute(t){let{remotePath:r}=t;if(!r)throw new Error("Missing required parameter: remotePath");let n=r.split(".").pop(),i=`downloaded-${Zd()}.${n}`;this.#r.debug(`Reading file from ${r} and writing to ${i}`);let o;try{o=await this.#e.read(r),await this.#t.write(i,o)}catch(s){throw this.#r.error(`Error reading file from ${r}: ${s instanceof Error?s.message:"Unknown error"}`),s}finally{o?.close()}return{pathDsn:this.#t.pathAsDsn(i),path:i}}};var Xv=z(require("node:path"));var yJe=sne(),tg=class{static TYPE="extract-archive";#e;#t;constructor(t,r=new hn){this.#e=t,this.#t=r}async execute(t){let{localPath:r}=t;if(!r)throw new Error("Missing required parameter: localPath");this.#t.debug(`Reading file from ${r}`);let n;try{let i=Ao(this.#e,r);if(!this.#n(i))throw new Error(`File ${i} is not a zip archive`);return n=await this.#e.read(i),await this.#r(n.get(),`extracted-${Zd()}`)}catch(i){throw this.#t.error(`Error extracting archive from ${r}: ${i instanceof Error?i.message:"Unknown error"}`),i}finally{n?.close()}}async#r(t,r){let n=await yJe.Open.buffer(t),i=n.files.filter(c=>c.type==="Directory"),o=n.files.filter(c=>c.type!=="Directory"),s=await Promise.all(i.map(async c=>{let u=Xv.default.join(r,c.path),l=Xv.default.join(u,".keep");return await this.#e.write(l,Buffer.alloc(0)),await this.#e.delete(l),this.#t.debug(`Created directory: ${u}`),u})),a=await Promise.all(o.map(async c=>{let u=Xv.default.join(r,c.path),l=await c.buffer();return await this.#e.write(u,l),this.#t.debug(`Extracted file: ${u}`),u}));return this.#t.debug(`Extracted ${a.length} file(s) and ${s.length} directory/ies from zip archive`),{files:a,directories:s,outputPath:r}}#n(t){return t.toLowerCase().endsWith(".zip")}};var rg=class{static TYPE="list-directory";#e;#t;#r;constructor(t,r,n=new hn){this.#e=t,this.#t=r,this.#r=n}async execute(t){let{localPath:r,remotePath:n}=t;if(!r&&!n)throw new Error("Missing required parameter: localPath or remotePath");if(r&&n)throw new Error("Use either localPath or remotePath");this.#r.debug(`Reading file from ${r??n}`);let i;try{r?i=await this.#t.list(Ao(this.#t,r)):i=await this.#e.list(n)}catch(a){throw this.#r.error(`Error reading file from ${r??n}: ${a instanceof Error?a.message:"Unknown error"}`),a}let o=i.filter(a=>a.type==="FILE").map(a=>a.name),s=i.filter(a=>a.type==="DIRECTORY").map(a=>a.name);return{files:o,directories:s}}};var Mx=z(require("node:path")),lde=require("node:stream");var xo=z(require("node:process")),ti=z(pce()),hce=(o=>(o.error="error",o.warn="warn",o.info="info",o.http="http",o.debug="debug",o))(hce||{}),kg=class e{static instance;logger;#e;constructor(t="default",r="info"){this.logger=ti.default.createLogger({level:r,format:ti.default.format.combine(ti.default.format.label({label:t}),ti.default.format.timestamp(),ti.default.format.json(),ti.default.format.errors({stack:!0}))});let n=!1;(xo.default.env.NODE_ENV!=="production"||xo.default.env.LOG_TO_CONSOLE==="true")&&(n=!0,this.logger.add(new ti.default.transports.Console({format:ti.default.format.printf(({label:i,level:o,message:s})=>{let a=new Date().toLocaleString();return`[${i}] ${xo.default.pid} - ${a} ${o}: ${s}`})}))),xo.default.env.LOG_TO_FILE==="true"&&(n=!0,this.logger.add(new ti.default.transports.File({filename:"error.log",level:"error"})),this.logger.add(new ti.default.transports.File({filename:"combined.log"}))),n||this.logger.add(new ti.default.transports.Console({format:ti.default.format.printf(({label:i,level:o,message:s})=>`[${i}] ${o}: ${s}`)}))}static getInstance(t,r){return e.instance||(e.instance=new e(t??"default",e.#r(r))),e.instance}setDatadogTransport(t){let r=t?.apiKey??xo.default.env.DATADOG_API_KEY;if(!r)return this.debug("DATADOG_API_KEY is not set, cannot add Datadog transport"),this;let n=new URLSearchParams({"dd-api-key":r,ddsource:t?.source??xo.default.env.DD_SOURCE??"nodejs",service:t?.service??xo.default.env.DD_SERVICE??"unknown",env:t?.env??xo.default.env.DD_ENV??"prod"});t?.tags&&n.append("ddtags",Object.entries(t.tags).map(([o,s])=>`${o}:${s}`).join(","));let i={host:`http-intake.logs.${xo.default.env.DD_SITE??"datadoghq.eu"}`,path:`/api/v2/logs?${n.toString()}`,ssl:!0,batch:!0,format:ti.default.format.json(),level:"info"};return this.#e&&this.logger.remove(this.#e),this.#e=new ti.default.transports.Http(i),this.logger.add(this.#e),this}info(...t){this.#t(this.logger.info,...t)}static info(...t){this.getInstance().info(...t)}debug(...t){this.#t(this.logger.debug,...t)}static debug(...t){this.getInstance().debug(...t)}error(...t){this.#t(this.logger.error,...t)}static error(...t){this.getInstance().error(...t)}warn(...t){this.#t(this.logger.warn,...t)}static warn(...t){this.getInstance().warn(...t)}verbose(...t){this.#t(this.logger.verbose,...t)}static verbose(...t){this.getInstance().verbose(...t)}#t(t,...r){try{let n=r.map(i=>typeof i=="object"?JSON.stringify(i):String(i));t(n.join(" "),...r)}catch(n){console.error("unknown error in log, function",n)}}static#r=t=>{if(t!==void 0)return t;let r=xo.default.env.LOG_LEVEL||"info",i=!Object.values(hce).includes(r);return i&&(r="info"),i&&console.error(`Invalid log level: ${r} only allow; 'error', 'warn', 'info', 'debug', 'trace'. Using info as default.`),r}};var fde=z(jle()),dde=z(ude()),il=class e{#e;#t;constructor(t=void 0){this.#e=t,this.#t=kg.getInstance(),this.#t.info(`FileHandler initialized with delimiter: ${t}`)}async handleBuffer(t,r,n,i){let o;switch(e.getExtension(t)){case".csv":o=await this.parseCSV(r,n,i);break;default:return this.handle(t,r.toString(),n,i)}return o}async handle(t,r,n,i){let o;switch(e.getExtension(t)){case".xml":o=await this.parseXML(r,n);break;case".json":o=JSON.parse(r);break;default:kg.getInstance().error(`Unsupported file type: ${t}`)}return o}async parseXML(t,r){try{let n=await dde.default.parseStringPromise(t,{explicitArray:!1});return this.xmlOptions(n,r)}catch(n){throw new Error(`Error parsing XML content: ${n.message}`)}}async parseCSV(t,r,n){try{let i=lde.Readable.from(t),o=!0;return Object.keys(n??{}).includes("noHeader")&&(o=(n??{}).noHeader===!0),(0,fde.default)({delimiter:this.#e??",",noheader:o}).fromStream(i)}catch(i){throw this.#t.error(`Error parsing CSV: ${i.message}`),new Error(`Error parsing CSV content: ${i.message}`)}}xmlOptions(t,r){let n=i=>{if(typeof i=="object")for(let o of Object.keys(i)){let s=i[o];r.includes(o)?Array.isArray(s)||(i[o]=[s]):o!=="_text"&&(i[o]=n(s))}return i};return n(t)}csvOptions(t,r){let n;return Array.isArray(r)&&r.length>0?n={headers:r}:n=t.split(`
|
|
289
|
+
`)[0].trim().split(",").length>1?{headers:!0}:{noheader:!0},n}stringify(t){return JSON.stringify(t,null,2)}static getPath(t){return Mx.default.dirname(t)}static getFileName(t){return Mx.default.basename(t)}static getExtension(t){return Mx.default.extname(t).toLowerCase()}};var Vg=class{static TYPE="read";#e;#t;#r;#n;constructor(t,r,n=new hn){this.#e=t,this.#t=r,this.#r=n,this.#n=new il}async execute(t){let{localPath:r,remotePath:n}=t;if(!r&&!n)throw new Error("Missing required parameter: localPath or remotePath");if(r&&n)throw new Error("Use either localPath or remotePath");this.#r.debug(`Reading file from ${r??n}`);let i,o;try{r?i=await this.#t.read(Ao(this.#t,r)):i=await this.#e.read(n);let s=i.get();t.raw!==!0&&t.raw!=="true"?o=await this.#n.handleBuffer(r??n,s,[]):o=s.toString()}catch(s){throw this.#r.error(`Error reading file from ${r??n}: ${s instanceof Error?s.message:"Unknown error"}`),s}finally{i?.close()}return{contents:o}}};var Wg=class{static TYPE="upload";#e;#t;#r;constructor(t,r,n=new hn){this.#e=t,this.#t=r,this.#r=n}async execute(t){let{localPath:r,remotePath:n}=t;if(!r)throw new Error("Missing required parameter: localPath");if(!n)throw new Error("Missing required parameter: remotePath");this.#r.debug(`Writing file from ${r} to ${n}`);let i;try{i=await this.#t.read(Ao(this.#t,r));let o=await this.#e.exists(n);if(o&&t.overwrite!==!0&&t.overwrite!=="true")throw new Error(`File already exists at ${n}. Set overwrite to true to replace it.`);o&&await this.#e.delete(n).catch(()=>{}),await this.#e.write(n,i)}catch(o){throw this.#r.error(`Error writing file from ${r} to ${n}: ${o instanceof Error?o.message:"Unknown error"}`),o}finally{i?.close()}}};var Kg=class{static TYPE="write";#e;#t;constructor(t,r=new hn){this.#e=t,this.#t=r}async execute(t){let{contents:r,remotePath:n}=t;if(!r&&r!=="")throw new Error("Missing required parameter: contents");if(!n)throw new Error("Missing required parameter: remotePath");this.#t.debug(`Writing content to ${n}`);try{let i=await this.#e.exists(n);if(i&&t.overwrite!==!0&&t.overwrite!=="true")throw new Error(`File already exists at ${n}. Set overwrite to true to replace it.`);i&&await this.#e.delete(n).catch(()=>{}),await this.#e.write(n,r)}catch(i){throw this.#t.error(`Error writing content to ${n}: ${i instanceof Error?i.message:"Unknown error"}`),i}}};var Lx=class extends pde.default{#e;#t;constructor(t,r,n){super(),this.#e=t,n=n??this.#e.files(`file://${hde.default.join(process.env.RUNTIME_DIRECTORY??process.env.TRANSAI_TMP_DIR??"./tmp","connectors",t.config.datasourceIdentifier??"file")}`),this.#t={[ep.TYPE]:new ep(r,n,this.#e.logger),[Wg.TYPE]:new Wg(r,n,this.#e.logger),[Kg.TYPE]:new Kg(r,this.#e.logger),[Qd.TYPE]:new Qd(r,n,this.#e.logger),[Vg.TYPE]:new Vg(r,n,this.#e.logger),[rg.TYPE]:new rg(r,n,this.#e.logger),[tg.TYPE]:new tg(n,this.#e.logger)}}get callbackFunctionChain(){return this.#r(this.#e.receiver.emitEventType(this.#e.receiver.responses.ok()))}#r(t){return async(r,n)=>{let i=n.identifier.toLowerCase(),o=this.#t[i]||this.#t[i.replace(/^file[.-]/,"")]||this.#t[String(n.config.type)];if(!o)return this.#e.receiver.responses.badRequest(`Action ${i} does not exist.`)(r);try{let s=await o.execute(r.payload);this.#e.logger.debug(`Action ${i} executed successfully with pathDsn: ${JSON.stringify(s)}`);let a=r;return typeof s<"u"&&(a={...r,payload:s}),t(a)}catch(s){return this.#e.logger.error(`Error executing action ${i}: ${s instanceof Error?s.message:"Unknown error"}`),this.#e.receiver.responses.internalServerError(s instanceof Error?s.message:"Unknown error occurred")(r)}}}};var wL=z(require("path"));var Yg=class{static DEFAULT_INTERVAL_SECONDS=60;#e;#t;#r;#n;#o;#i;constructor(t,r,n){this.#e=t,this.#t=r,this.#r=n,this.#o=new il(r.delimiter);let{selector:i}=this.#t;if(this.#i=new RegExp(typeof i!="string"?i.pattern:i,typeof i!="string"&&i.flags?i.flags:"i"),this.#t.destinationDsn)this.#n=this.#e.files(this.#t.destinationDsn);else if(this.#t.action==="move")throw new Error(`Destination DSN must be provided for 'move' action in file selector: ${this.name}`)}get name(){let{selector:t}=this.#t;return`file-processor-${typeof t=="string"?t:t.pattern}`}async onRun(){let t=await this.#s();this.#e.telemetry.increment("files.processed.count",t)}async#s(t="/"){let r=await this.#r.list(t);return(await Promise.all(r.map(async i=>i.type==="FILE"?await this.#a(i,t)?1:0:this.#t.recursive===!0?this.#s(wL.default.join(t,i.name)):Promise.resolve(0)))).reduce((i,o)=>i+o,0)}async#a(t,r){let n=wL.default.join(r,t.name);if(!this.#i.test(n))return this.#e.logger.verbose(`Skipping file at path: ${n} as it does not match selector regex`),!1;this.#e.logger.debug(`Processing file at path: ${n}`);let i,o;try{if(i=await this.#r.read(n),o=await this.#o.handleBuffer(n,i.get(),this.#t.optionalHeaders??[],this.#t.optionalSettings),!o)return this.#e.logger.info(`Failed to parse file at path: ${n}`),i.close(),!1;this.#e.logger.debug(`Parsed file successfully at path: ${n}`)}catch(s){return this.#e.logger.error(`Error parsing file at path: ${n}, error: ${s}`),i?.close(),!1}try{let s={...o,_filename:il.getFileName(n)??t.name},a={keyField:"_filename",collection:`${this.#e.config.datasourceIdentifier??"file"}_${this.#t.identifier??this.#i.source??"default"}`};this.#t.action==="move"&&(s._fileDestination=this.#n?.pathAsDsn(t.name)),this.#t.type==="metric"?await this.#e.sender.metricsLegacy([s],a):await this.#e.sender.documents([s],a)}catch(s){return this.#e.logger.error(`Error sending parsed file from path: ${n}, error: ${s}`),i?.close(),!1}try{switch(this.#t.action){case"move":await this.#n?.write(t.name,i),await this.#r.delete(n),this.#e.logger.debug(`"Moved" file at path: ${n} to ${this.#n?.pathAsDsn(t.name)} after processing`);break;case"delete":await this.#r.delete(n),this.#e.logger.debug(`Deleted file at path: ${n} after processing`);break}}finally{i?.close()}return!0}};var SL=class extends Qg{#e;constructor(t,r){super(t,r);let{config:n}=this.connectorSDK;this.#e=this.connectorSDK.files(n.dsn);let i=new Lx(this.connectorSDK,this.#e);this.callbackFunction=i.callbackFunctionChain}init=async()=>{let{config:t}=this.connectorSDK;await Promise.all((t.fileSelectors??[]).map(async r=>{let n=new Yg(this.connectorSDK,r,this.#e);await this.connectorSDK.processing.registerInterval(r.intervalSeconds??Yg.DEFAULT_INTERVAL_SECONDS,n)}))}};0&&(module.exports={ConnectorRunnerFile});
|
|
50
290
|
/*! Bundled license information:
|
|
51
291
|
|
|
52
292
|
safe-buffer/index.js:
|