@gmod/cram 2.0.2 → 2.0.4

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.
Files changed (76) hide show
  1. package/CHANGELOG.md +9 -0
  2. package/README.md +0 -4
  3. package/dist/craiIndex.js +1 -1
  4. package/dist/craiIndex.js.map +1 -1
  5. package/dist/cram-bundle.js +1 -1
  6. package/dist/cram-bundle.js.LICENSE.txt +0 -2
  7. package/dist/cramFile/codecs/byteArrayStop.d.ts +0 -1
  8. package/dist/cramFile/codecs/getBits.d.ts +0 -1
  9. package/dist/cramFile/codecs/getBits.js +2 -2
  10. package/dist/cramFile/codecs/getBits.js.map +1 -1
  11. package/dist/cramFile/codecs/index.js +1 -2
  12. package/dist/cramFile/codecs/index.js.map +1 -1
  13. package/dist/cramFile/container/index.d.ts +1 -2
  14. package/dist/cramFile/file.d.ts +1 -3
  15. package/dist/cramFile/file.js +2 -2
  16. package/dist/cramFile/file.js.map +1 -1
  17. package/dist/cramFile/sectionParsers.d.ts +0 -1
  18. package/dist/cramFile/sectionParsers.js +3 -3
  19. package/dist/cramFile/sectionParsers.js.map +1 -1
  20. package/dist/cramFile/slice/decodeRecord.js +1 -1
  21. package/dist/cramFile/slice/decodeRecord.js.map +1 -1
  22. package/dist/cramFile/util.d.ts +0 -2
  23. package/dist/cramFile/util.js +5 -6
  24. package/dist/cramFile/util.js.map +1 -1
  25. package/dist/indexedCramFile.d.ts +0 -3
  26. package/dist/indexedCramFile.js +4 -16
  27. package/dist/indexedCramFile.js.map +1 -1
  28. package/dist/io/index.d.ts +1 -3
  29. package/dist/io/index.js +3 -16
  30. package/dist/io/index.js.map +1 -1
  31. package/dist/rans/d04.js +1 -1
  32. package/dist/rans/d04.js.map +1 -1
  33. package/dist/rans/d14.js +1 -1
  34. package/dist/rans/d14.js.map +1 -1
  35. package/dist/rans/frequencies.js +2 -3
  36. package/dist/rans/frequencies.js.map +1 -1
  37. package/dist/rans/index.js +1 -1
  38. package/dist/rans/index.js.map +1 -1
  39. package/dist/sam.d.ts +1 -1
  40. package/dist/sam.js +3 -4
  41. package/dist/sam.js.map +1 -1
  42. package/dist/typescript.d.ts +0 -1
  43. package/dist/typescript.js +0 -8
  44. package/dist/typescript.js.map +1 -1
  45. package/dist/unzip-pako.d.ts +0 -1
  46. package/dist/unzip-pako.js +1 -2
  47. package/dist/unzip-pako.js.map +1 -1
  48. package/dist/unzip.d.ts +0 -1
  49. package/esm/craiIndex.js +1 -1
  50. package/esm/craiIndex.js.map +1 -1
  51. package/esm/cramFile/codecs/byteArrayStop.d.ts +0 -1
  52. package/esm/cramFile/codecs/getBits.d.ts +0 -1
  53. package/esm/cramFile/container/index.d.ts +1 -2
  54. package/esm/cramFile/file.d.ts +1 -3
  55. package/esm/cramFile/sectionParsers.d.ts +0 -1
  56. package/esm/cramFile/util.d.ts +0 -2
  57. package/esm/indexedCramFile.d.ts +0 -3
  58. package/esm/indexedCramFile.js +3 -15
  59. package/esm/indexedCramFile.js.map +1 -1
  60. package/esm/io/index.d.ts +1 -3
  61. package/esm/io/index.js +2 -11
  62. package/esm/io/index.js.map +1 -1
  63. package/esm/sam.d.ts +1 -1
  64. package/esm/sam.js +2 -2
  65. package/esm/sam.js.map +1 -1
  66. package/esm/typescript.d.ts +0 -1
  67. package/esm/typescript.js +1 -6
  68. package/esm/typescript.js.map +1 -1
  69. package/esm/unzip-pako.d.ts +0 -1
  70. package/esm/unzip.d.ts +0 -1
  71. package/package.json +5 -10
  72. package/src/craiIndex.ts +1 -1
  73. package/src/indexedCramFile.ts +3 -25
  74. package/src/io/index.ts +2 -12
  75. package/src/sam.ts +3 -3
  76. package/src/typescript.ts +0 -7
@@ -1,2 +1,2 @@
1
1
  /*! For license information please see cram-bundle.js.LICENSE.txt */
2
- (()=>{var e={4923:function(e,t,r){"use strict";var n=this&&this.__awaiter||function(e,t,r,n){return new(r||(r=Promise))((function(o,i){function a(e){try{f(n.next(e))}catch(e){i(e)}}function s(e){try{f(n.throw(e))}catch(e){i(e)}}function f(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}f((n=n.apply(e,t||[])).next())}))},o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});const i=o(r(8802)),a=o(r(7392)),s=r(8712),f=r(5931),l=r(9747);function u(e,t){const[r,n,o,i,a,s]=t;e[r]||(e[r]=[]),e[r].push({start:n,span:o,containerStart:i,sliceStart:a,sliceBytes:s})}t.default=class{constructor(e){this.filehandle=(0,f.open)(e.url,e.path,e.filehandle),this._parseCache=new i.default({cache:new a.default({maxSize:1}),fill:(e,t)=>this.parseIndex()})}parseIndex(){const e={};return this.filehandle.readFile().then((e=>31===e[0]&&139===e[1]?(0,s.unzip)(e):e)).then((t=>{if(t.length>4&&21578050===t.readUInt32LE(0))throw new l.CramMalformedError("invalid .crai index file. note: file appears to be a .bai index. this is technically legal but please open a github issue if you need support");let r=[],n="";for(const o of t)if(o>=48&&o<=57||!n&&45===o)n+=String.fromCharCode(o);else if(9===o)r.push(Number.parseInt(n,10)),n="";else if(10===o)r.push(Number.parseInt(n,10)),n="",u(e,r),r=[];else if(13!==o&&32!==o)throw new l.CramMalformedError("invalid .crai index file");return n&&r.push(Number.parseInt(n,10)),6===r.length&&u(e,r),Object.entries(e).forEach((([t,r])=>{e[t]=r.sort(((e,t)=>e.start-t.start||e.span-t.span))})),e}))}getIndex(e={}){return this._parseCache.get("index",null,e.signal)}hasDataForReferenceSequence(e){return n(this,void 0,void 0,(function*(){return!!(yield this.getIndex())[e]}))}getEntriesForRange(e,t,r){return n(this,void 0,void 0,(function*(){const n=(yield this.getIndex())[e];if(!n)return[];const o=e=>{const n=e.start,o=e.start+e.span;return n>r?-1:o<=t?1:0},i=[];for(const e of n)0===o(e)&&i.push(e);return i}))}}},9508:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=class{constructor(e,t){this.parameters=e,this.dataType=t}}},368:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});const o=r(9747),i=n(r(9508)),a=r(612);class s extends i.default{constructor(e,t){if(super(e,t),"int"!==this.dataType)throw new o.CramUnimplementedError(`${this.dataType} decoding not yet implemented by BETA codec`)}decode(e,t,r,n){return(0,a.getBits)(t.content,n.coreBlock,this.parameters.length)-this.parameters.offset}}t.default=s},8635:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});const o=r(400),i=n(r(9508));class a extends i.default{constructor(e,t,r){if(super(e,t),this.instantiateCodec=r,"byteArray"!==t)throw new TypeError(`byteArrayLength does not support data type ${t}`)}decode(e,t,r,n){const o=this._getLengthCodec().decode(e,t,r,n),i=this._getDataCodec(),a=new Uint8Array(o);for(let s=0;s<o;s+=1)a[s]=i.decode(e,t,r,n);return a}_getLengthCodec(){const e=this.parameters.lengthsEncoding;return this.instantiateCodec(e,"int")}_getDataCodec(){const e=this.parameters.valuesEncoding;return this.instantiateCodec(e,"byte")}}t.default=a,"_getLengthCodec _getDataCodec".split(" ").forEach((e=>(0,o.tinyMemoize)(a,e)))},4839:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});const o=r(9747),i=n(r(9508)),a=r(612);class s extends i.default{constructor(e,t){if(super(e,t),"byteArray"!==t)throw new TypeError(`byteArrayStop codec does not support data type ${t}`)}decode(e,t,r,n){const{blockContentId:i}=this.parameters,a=r[i];if(!a)throw new o.CramMalformedError(`no block found with content ID ${i}`);const s=n.externalBlocks.getCursor(i);return this._decodeByteArray(a,s)}_decodeByteArray(e,t){const r=e.content,{stopByte:n}=this.parameters,o=t.bytePosition;let i=t.bytePosition;for(;r[i]!==n&&i<r.length;){if(i===r.length)throw new a.CramBufferOverrunError("byteArrayStop reading beyond length of data buffer?");i+=1}return t.bytePosition=i+1,r.subarray(o,i)}}t.default=s},8153:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});const o=r(9747),i=n(r(9508)),a=r(400),s=r(612);class f extends i.default{constructor(e,t){if(super(e,t),"int"===this.dataType)this._decodeData=this._decodeInt;else{if("byte"!==this.dataType)throw new o.CramUnimplementedError(`${this.dataType} decoding not yet implemented by EXTERNAL codec`);this._decodeData=this._decodeByte}}decode(e,t,r,n){const{blockContentId:i}=this.parameters,a=r[i];if(!a)throw new o.CramMalformedError(`no block found with content ID ${i}`);const s=n.externalBlocks.getCursor(i);return this._decodeData(a,s)}_decodeInt(e,t){const[r,n]=(0,a.parseItf8)(e.content,t.bytePosition);return t.bytePosition=t.bytePosition+n,r}_decodeByte(e,t){if(t.bytePosition>=e.content.length)throw new s.CramBufferOverrunError("attempted to read beyond end of block. this file seems truncated.");return e.content[t.bytePosition++]}}t.default=f},8185:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});const o=r(9747),i=n(r(9508)),a=r(612);class s extends i.default{constructor(e,t){if(super(e,t),"int"!==this.dataType)throw new o.CramUnimplementedError(`${this.dataType} decoding not yet implemented by GAMMA codec`)}decode(e,t,r,n){let o=1;for(;0===(0,a.getBits)(t.content,n.coreBlock,1);)o+=1;return((0,a.getBits)(t.content,n.coreBlock,o-1)|1<<o-1)-this.parameters.offset}}t.default=s},612:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getBits=t.CramBufferOverrunError=void 0;class r extends Error{}t.CramBufferOverrunError=r,t.getBits=function(e,t,n){let o=0;if(t.bytePosition+(7-t.bitPosition+n)/8>e.length)throw new r("read error during decoding. the file seems to be truncated.");for(let r=n;r;r--)o<<=1,o|=e[t.bytePosition]>>t.bitPosition&1,t.bitPosition-=1,t.bitPosition<0&&(t.bytePosition+=1),t.bitPosition&=7;return o}},4341:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});const o=r(9747),i=n(r(9508)),a=r(612);class s extends i.default{constructor(e,t){if(super(e,t),this.codes={},this.codeBook={},this.sortedCodes=[],this.sortedValuesByBitCode=[],this.sortedBitCodes=[],this.sortedBitLengthsByBitCode=[],this.bitCodeToValue=[],!["byte","int"].includes(this.dataType))throw new TypeError(`${this.dataType} decoding not yet implemented by HUFFMAN_INT codec`);this.buildCodeBook(),this.buildCodes(),this.buildCaches(),0===this.sortedCodes[0].bitLength&&(this._decode=this._decodeZeroLengthCode)}buildCodeBook(){let e=new Array(this.parameters.numCodes);for(let t=0;t<this.parameters.numCodes;t+=1)e[t]={symbol:this.parameters.symbols[t],bitLength:this.parameters.bitLengths[t]};e=e.sort(((e,t)=>e.bitLength-t.bitLength||e.symbol-t.symbol)),this.codeBook={},e.forEach((e=>{this.codeBook[e.bitLength]||(this.codeBook[e.bitLength]=[]),this.codeBook[e.bitLength].push(e.symbol)}))}buildCodes(){this.codes={};let e=0,t=-1;Object.entries(this.codeBook).forEach((([r,n])=>{const i=parseInt(r,10);n.forEach((r=>{const n={bitLength:i,value:r,bitCode:0};t+=1;const a=i-e;if(t<<=a,n.bitCode=t,e+=a,function(e){let t=e-(e>>1)&1431655765;return t=(858993459&t)+(t>>2&858993459),16843009*(t+(t>>4)&252645135)>>24}(t)>i)throw new o.CramMalformedError("Symbol out of range");this.codes[r]=n}))}))}buildCaches(){this.sortedCodes=Object.values(this.codes).sort(((e,t)=>e.bitLength-t.bitLength||e.bitCode-t.bitCode)),this.sortedValuesByBitCode=this.sortedCodes.map((e=>e.value)),this.sortedBitCodes=this.sortedCodes.map((e=>e.bitCode)),this.sortedBitLengthsByBitCode=this.sortedCodes.map((e=>e.bitLength));const e=Math.max(...this.sortedBitCodes);this.bitCodeToValue=new Array(e+1).fill(-1);for(let e=0;e<this.sortedBitCodes.length;e+=1)this.bitCodeToValue[this.sortedCodes[e].bitCode]=e}decode(e,t,r,n){return this._decode(e,t,n.coreBlock)}_decodeZeroLengthCode(){return this.sortedCodes[0].value}_decode(e,t,r){const n=t.content;let i=0,s=0;for(let e=0;e<this.sortedCodes.length;e+=1){const t=this.sortedCodes[e].bitLength;s<<=t-i,s|=(0,a.getBits)(n,r,t-i),i=t;{const r=this.bitCodeToValue[s];if(r>-1&&this.sortedBitLengthsByBitCode[r]===t)return this.sortedValuesByBitCode[r];for(let r=e;this.sortedCodes[r+1].bitLength===t&&r<this.sortedCodes.length;r+=1)e+=1}}throw new o.CramMalformedError("Huffman symbol not found.")}}t.default=s},6524:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.instantiateCodec=void 0;const o=r(9747),i=n(r(4341)),a=n(r(8153)),s=n(r(4839)),f=n(r(8635)),l=n(r(368)),u=n(r(8185)),c=n(r(99)),A={1:a.default,3:i.default,4:f.default,5:s.default,6:l.default,7:c.default,9:u.default};t.instantiateCodec=function e(t,r){const n=(i="ignore"===r?0:t.codecId,A[i]);var i;if(!n)throw new o.CramUnimplementedError(`no codec implemented for codec ID ${t.codecId}`);return new n(t.parameters,r,e)}},99:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});const o=r(9747),i=n(r(9508)),a=r(612);class s extends i.default{constructor(e,t){if(super(e,t),"int"!==this.dataType)throw new o.CramUnimplementedError(`${this.dataType} decoding not yet implemented by SUBEXP codec`)}decode(e,t,r,n){let o,i,s=0;for(;(0,a.getBits)(t.content,n.coreBlock,1);)s+=1;return 0===s?(o=this.parameters.K,i=(0,a.getBits)(t.content,n.coreBlock,o)):(o=s+this.parameters.K-1,i=1<<o|(0,a.getBits)(t.content,n.coreBlock,o)),i-this.parameters.offset}}t.default=s},7295:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default={CRAM_FLAG_PRESERVE_QUAL_SCORES:1,CRAM_FLAG_DETACHED:2,CRAM_FLAG_MATE_DOWNSTREAM:4,CRAM_FLAG_NO_SEQ:8,CRAM_FLAG_MASK:15,CRAM_M_REVERSE:1,CRAM_M_UNMAP:2,BAM_FPAIRED:1,BAM_FPROPER_PAIR:2,BAM_FUNMAP:4,BAM_FMUNMAP:8,BAM_FREVERSE:16,BAM_FMREVERSE:32,BAM_FREAD1:64,BAM_FREAD2:128,BAM_FSECONDARY:256,BAM_FQCFAIL:512,BAM_FDUP:1024,BAM_FSUPPLEMENTARY:2048,BAM_CMATCH:0,BAM_CINS:1,BAM_CDEL:2,BAM_CREF_SKIP:3,BAM_CSOFT_CLIP:4,BAM_CHARD_CLIP:5,BAM_CPAD:6,BAM_CEQUAL:7,BAM_CDIFF:8,BAM_CBACK:9,BAM_CIGAR_STR:"MIDNSHP:XB",BAM_CIGAR_SHIFT:4,BAM_CIGAR_MASK:15,BAM_CIGAR_TYPE:246183}},7219:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(6524),o=r(9747),i={BF:"int",CF:"int",RI:"int",RL:"int",AP:"int",RG:"int",MF:"int",NS:"int",NP:"int",TS:"int",NF:"int",TC:"byte",TN:"int",FN:"int",FC:"byte",FP:"int",BS:"byte",IN:"byteArray",SC:"byteArray",DL:"int",BA:"byte",BB:"byteArray",RS:"int",PD:"int",HC:"int",MQ:"int",RN:"byteArray",QS:"byte",QQ:"byteArray",TL:"int"};t.default=class{constructor(e){this.dataSeriesCodecCache={},this.tagCodecCache={},this.tagEncoding={},this.readNamesIncluded=e.preservation.RN,this.APdelta=e.preservation.AP,this.referenceRequired=!!e.preservation.RR,this.tagIdsDictionary=e.preservation.TD,this.substitutionMatrix=function(e){const t=new Array(5);for(let e=0;e<5;e+=1)t[e]=new Array(4);return t[0][e[0]>>6&3]="C",t[0][e[0]>>4&3]="G",t[0][e[0]>>2&3]="T",t[0][e[0]>>0&3]="N",t[1][e[1]>>6&3]="A",t[1][e[1]>>4&3]="G",t[1][e[1]>>2&3]="T",t[1][e[1]>>0&3]="N",t[2][e[2]>>6&3]="A",t[2][e[2]>>4&3]="C",t[2][e[2]>>2&3]="T",t[2][e[2]>>0&3]="N",t[3][e[3]>>6&3]="A",t[3][e[3]>>4&3]="C",t[3][e[3]>>2&3]="G",t[3][e[3]>>0&3]="N",t[4][e[4]>>6&3]="A",t[4][e[4]>>4&3]="C",t[4][e[4]>>2&3]="G",t[4][e[4]>>0&3]="T",t}(e.preservation.SM),this.dataSeriesEncoding=e.dataSeriesEncoding,this.tagEncoding=e.tagEncoding,this.preservation=e.preservation,this._size=e._size,this._endPosition=e._endPosition}getCodecForTag(e){if(!this.tagCodecCache[e]){const t=this.tagEncoding[e];t&&(this.tagCodecCache[e]=(0,n.instantiateCodec)(t,"byteArray"))}return this.tagCodecCache[e]}getTagNames(e){return this.tagIdsDictionary[e]}getCodecForDataSeries(e){let t=this.dataSeriesCodecCache[e];if(void 0===t){const r=this.dataSeriesEncoding[e];if(r){const a=i[e];if(!a)throw new o.CramMalformedError(`data series name ${e} not defined in file compression header`);t=(0,n.instantiateCodec)(r,a),this.dataSeriesCodecCache[e]=t}}return t}toJSON(){const e={};return Object.keys(this).forEach((t=>{t.endsWith("Cache")||(e[t]=this[t])})),e}}},78:function(e,t,r){"use strict";var n=this&&this.__awaiter||function(e,t,r,n){return new(r||(r=Promise))((function(o,i){function a(e){try{f(n.next(e))}catch(e){i(e)}}function s(e){try{f(n.throw(e))}catch(e){i(e)}}function f(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}f((n=n.apply(e,t||[])).next())}))},o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});const i=r(9747),a=r(400),s=o(r(6771)),f=o(r(7219));class l{constructor(e,t){this.file=e,this.filePosition=t}getHeader(){return this._readContainerHeader(this.filePosition)}getCompressionHeaderBlock(){return n(this,void 0,void 0,(function*(){if(!(yield this.getHeader()).numRecords)return null;const e=yield this.file.getSectionParsers(),t=yield this.getFirstBlock();if(void 0===t)return;if("COMPRESSION_HEADER"!==t.contentType)throw new i.CramMalformedError(`invalid content type ${t.contentType} in what is supposed to be the compression header block`);const r=(0,a.parseItem)(t.content,e.cramCompressionHeader.parser,0,t.contentPosition);return Object.assign(Object.assign({},t),{parsedContent:r})}))}getFirstBlock(){return n(this,void 0,void 0,(function*(){const e=yield this.getHeader();return this.file.readBlock(e._endPosition)}))}getCompressionScheme(){return n(this,void 0,void 0,(function*(){const e=yield this.getCompressionHeaderBlock();if(e)return new f.default(e.parsedContent)}))}getSlice(e,t){return new s.default(this,e,t)}_readContainerHeader(e){return n(this,void 0,void 0,(function*(){const t=yield this.file.getSectionParsers(),{cramContainerHeader1:r,cramContainerHeader2:n}=t,{size:o}=yield this.file.stat();if(e>=o)return;const i=Buffer.allocUnsafe(r.maxLength);yield this.file.read(i,0,r.maxLength,e);const s=(0,a.parseItem)(i,r.parser),f=(0,a.itf8Size)(s.numLandmarks);if(e+s.length>=o)return void console.warn(`${this.file}: container header at ${e} indicates that the container has length ${s.length}, which extends beyond the length of the file. Skipping this container.`);const l=Buffer.allocUnsafe(n.maxLength(s.numLandmarks));yield this.file.read(l,0,n.maxLength(s.numLandmarks),e+s._size-f);const u=(0,a.parseItem)(l,n.parser);return this.file.validateChecksums&&void 0!==u.crc32&&(yield this.file.checkCrc32(e,s._size+u._size-f-4,u.crc32,`container header beginning at position ${e}`)),Object.assign(s,u,{_size:s._size+u._size-f,_endPosition:s._size+u._size-f+e})}))}}t.default=l,"getHeader getCompressionHeaderBlock getCompressionScheme".split(" ").forEach((e=>(0,a.tinyMemoize)(l,e)))},6794:function(e,t,r){"use strict";var n=this&&this.__awaiter||function(e,t,r,n){return new(r||(r=Promise))((function(o,i){function a(e){try{f(n.next(e))}catch(e){i(e)}}function s(e){try{f(n.throw(e))}catch(e){i(e)}}function f(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}f((n=n.apply(e,t||[])).next())}))},o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});const i=r(8712),a=o(r(4132)),s=o(r(7392)),f=o(r(6960)),l=o(r(235)),u=r(1307),c=r(9747),A=o(r(9989)),h=r(3165),d=o(r(78)),g=r(5931),p=r(400),y=r(5417);class m{constructor(e){var t;if(this.file=(0,g.open)(e.url,e.path,e.filehandle),this.validateChecksums=!0,this.fetchReferenceSequenceCallback=e.seqFetch,this.options={checkSequenceMD5:e.checkSequenceMD5,cacheSize:null!==(t=e.cacheSize)&&void 0!==t?t:2e4},this.featureCache=new s.default({maxSize:this.options.cacheSize}),function(){const e=new Uint32Array([287454020]),t=new Uint8Array(e.buffer);return 68===t[0]?0:17===t[0]?1:2}()>0)throw new Error("Detected big-endian machine, may be unable to run")}read(e,t,r,n){return this.file.read(e,t,r,n)}stat(){return this.file.stat()}getDefinition(){return n(this,void 0,void 0,(function*(){const e=Buffer.allocUnsafe(h.cramFileDefinition.maxLength);yield this.file.read(e,0,h.cramFileDefinition.maxLength,0);const t=h.cramFileDefinition.parser.parse(e).result;if(2!==t.majorVersion&&3!==t.majorVersion)throw new c.CramUnimplementedError(`CRAM version ${t.majorVersion} not supported`);return t}))}getSamHeader(){return n(this,void 0,void 0,(function*(){const e=yield this.getContainerById(0);if(!e)throw new c.CramMalformedError("file contains no containers");const t=yield e.getFirstBlock();if(void 0===t)return(0,y.parseHeaderText)("");const r=t.content,n=r.readInt32LE(0),o=r.toString("utf8",4,4+n);return this.header=o,(0,y.parseHeaderText)(o)}))}getHeaderText(){return n(this,void 0,void 0,(function*(){return yield this.getSamHeader(),this.header}))}getSectionParsers(){return n(this,void 0,void 0,(function*(){const{majorVersion:e}=yield this.getDefinition();return(0,h.getSectionParsers)(e)}))}getContainerById(e){return n(this,void 0,void 0,(function*(){const t=yield this.getSectionParsers();let r=t.cramFileDefinition.maxLength;const{size:n}=yield this.file.stat(),{cramContainerHeader1:o}=t;let i;for(let t=0;t<=e;t+=1){if(r+o.maxLength+8>=n)return;i=this.getContainerAtPosition(r);const a=yield i.getHeader();if(!a)throw new c.CramMalformedError(`container ${e} not found in file`);if(0===t){r=a._endPosition;for(let e=0;e<a.numBlocks;e+=1){const e=yield this.readBlock(r);if(void 0===e)return;r=e._endPosition}}else r+=a._size+a.length}return i}))}checkCrc32(e,t,r,o){return n(this,void 0,void 0,(function*(){const n=Buffer.allocUnsafe(t);yield this.file.read(n,0,t,e);const i=a.default.unsigned(n);if(i!==r)throw new c.CramMalformedError(`crc mismatch in ${o}: recorded CRC32 = ${r}, but calculated CRC32 = ${i}`)}))}containerCount(){return n(this,void 0,void 0,(function*(){const e=yield this.getSectionParsers(),{size:t}=yield this.file.stat(),{cramContainerHeader1:r}=e;let n=0,o=e.cramFileDefinition.maxLength;for(;o+r.maxLength+8<t;){const e=yield this.getContainerAtPosition(o).getHeader();if(!e)break;if(0===n){o=e._endPosition;for(let t=0;t<e.numBlocks;t+=1){const e=yield this.readBlock(o);if(void 0===e)return;o=e._endPosition}}else o+=e._size+e.length;n+=1}return n}))}getContainerAtPosition(e){return new d.default(this,e)}readBlockHeader(e){return n(this,void 0,void 0,(function*(){const t=yield this.getSectionParsers(),{cramBlockHeader:r}=t,{size:n}=yield this.file.stat();if(e+r.maxLength>=n)return;const o=Buffer.allocUnsafe(r.maxLength);return yield this.file.read(o,0,r.maxLength,e),(0,p.parseItem)(o,r.parser,0,e)}))}_parseSection(e,t,r=e.maxLength,o=void 0){return n(this,void 0,void 0,(function*(){let n;if(o)n=o;else{const{size:e}=yield this.file.stat();if(t+r>=e)return;n=Buffer.allocUnsafe(r),yield this.file.read(n,0,r,t)}const i=(0,p.parseItem)(n,e.parser,0,t);if(i._size!==r)throw new c.CramMalformedError(`section read error: requested size ${r} does not equal parsed size ${i._size}`);return i}))}_uncompress(e,t,r){return n(this,void 0,void 0,(function*(){if("gzip"===e)(0,i.unzip)(t).copy(r);else if("bzip2"===e){const e=l.default.array(t);let n,o=l.default.header(e),i=0;do{n=l.default.decompress(e,o),-1!=n&&(Buffer.from(n).copy(r,i),i+=n.length,o-=n.length)}while(-1!=n)}else if("lzma"===e){const e=new Response(new u.XzReadableStream((n=t,new ReadableStream({start(e){e.enqueue(n),e.close()}}))));Buffer.from(yield e.arrayBuffer()).copy(r)}else if("rans"===e)(0,A.default)(t,r);else if("rans4x16"===e)f.default.r4x16_uncompress(t,r);else if("arith"===e)f.default.arith_uncompress(t,r);else if("fqzcomp"===e)f.default.fqzcomp_uncompress(t,r);else{if("tok3"!==e)throw new c.CramUnimplementedError(`${e} decompression not yet implemented`);f.default.tok3_uncompress(t,r)}var n}))}readBlock(e){return n(this,void 0,void 0,(function*(){const{majorVersion:t}=yield this.getDefinition(),r=yield this.getSectionParsers(),n=yield this.readBlockHeader(e);if(void 0===n)return;const o=n._endPosition,i=Buffer.allocUnsafe(n.uncompressedSize),a=Object.assign(Object.assign({},n),{_endPosition:o,contentPosition:o,content:i});if("raw"!==n.compressionMethod){const e=Buffer.allocUnsafe(n.compressedSize);yield this.read(e,0,n.compressedSize,o),yield this._uncompress(n.compressionMethod,e,i)}else yield this.read(i,0,n.uncompressedSize,o);if(t>=3){const t=yield this._parseSection(r.cramBlockCrc32,o+n.compressedSize);if(void 0===t)return;a.crc32=t.crc32,this.validateChecksums&&(yield this.checkCrc32(e,n._size+n.compressedSize,t.crc32,"block data")),a._endPosition=t._endPosition,a._size=a.compressedSize+r.cramBlockCrc32.maxLength}else a._endPosition=o+a.compressedSize,a._size=a.compressedSize;return a}))}}t.default=m,"getDefinition getSectionParsers getSamHeader".split(" ").forEach((e=>(0,p.tinyMemoize)(m,e)))},7390:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.default=t.CramRecord=void 0;var o=r(8401);Object.defineProperty(t,"CramRecord",{enumerable:!0,get:function(){return n(o).default}});var i=r(6794);Object.defineProperty(t,"default",{enumerable:!0,get:function(){return n(i).default}})},8401:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.MateFlagsDecoder=t.CramFlagsDecoder=t.BamFlagsDecoder=t.MateFlags=t.CramFlags=t.BamFlags=void 0;const o=n(r(7295)),i={a:0,A:0,c:1,C:1,g:2,G:2,t:3,T:3,n:4,N:4};function a(e){const t={};for(const[r,n]of e)t["is"+n]=e=>!!(e&r),t["set"+n]=e=>e|r;return t}t.BamFlags=[[1,"Paired"],[2,"ProperlyPaired"],[4,"SegmentUnmapped"],[8,"MateUnmapped"],[16,"ReverseComplemented"],[32,"MateReverseComplemented"],[64,"Read1"],[128,"Read2"],[256,"Secondary"],[512,"FailedQc"],[1024,"Duplicate"],[2048,"Supplementary"]],t.CramFlags=[[1,"PreservingQualityScores"],[2,"Detached"],[4,"WithMateDownstream"],[8,"DecodeSequenceAsStar"]],t.MateFlags=[[1,"OnNegativeStrand"],[2,"Unmapped"]],t.BamFlagsDecoder=a(t.BamFlags),t.CramFlagsDecoder=a(t.CramFlags),t.MateFlagsDecoder=a(t.MateFlags),t.default=class{constructor({flags:e,cramFlags:t,readLength:r,mappingQuality:n,lengthOnRef:o,qualityScores:i,mateRecordNumber:a,readBases:s,readFeatures:f,mateToUse:l,readGroupId:u,readName:c,sequenceId:A,uniqueId:h,templateSize:d,alignmentStart:g,tags:p}){this.flags=e,this.cramFlags=t,this.readLength=r,this.mappingQuality=n,this.lengthOnRef=o,this.qualityScores=i,s&&(this.readBases=s),this.readGroupId=u,this.readName=c,this.sequenceId=A,this.uniqueId=h,this.templateSize=d,this.alignmentStart=g,this.tags=p,f&&(this.readFeatures=f),l&&(this.mate={flags:l.mateFlags,readName:l.mateReadName,sequenceId:l.mateSequenceId,alignmentStart:l.mateAlignmentStart}),a&&(this.mateRecordNumber=a)}isPaired(){return!!(this.flags&o.default.BAM_FPAIRED)}isProperlyPaired(){return!!(this.flags&o.default.BAM_FPROPER_PAIR)}isSegmentUnmapped(){return!!(this.flags&o.default.BAM_FUNMAP)}isMateUnmapped(){return!!(this.flags&o.default.BAM_FMUNMAP)}isReverseComplemented(){return!!(this.flags&o.default.BAM_FREVERSE)}isMateReverseComplemented(){return!!(this.flags&o.default.BAM_FMREVERSE)}isRead1(){return!!(this.flags&o.default.BAM_FREAD1)}isRead2(){return!!(this.flags&o.default.BAM_FREAD2)}isSecondary(){return!!(this.flags&o.default.BAM_FSECONDARY)}isFailedQc(){return!!(this.flags&o.default.BAM_FQCFAIL)}isDuplicate(){return!!(this.flags&o.default.BAM_FDUP)}isSupplementary(){return!!(this.flags&o.default.BAM_FSUPPLEMENTARY)}isDetached(){return!!(this.cramFlags&o.default.CRAM_FLAG_DETACHED)}hasMateDownStream(){return!!(this.cramFlags&o.default.CRAM_FLAG_MATE_DOWNSTREAM)}isPreservingQualityScores(){return!!(this.cramFlags&o.default.CRAM_FLAG_PRESERVE_QUAL_SCORES)}isUnknownBases(){return!!(this.cramFlags&o.default.CRAM_FLAG_NO_SEQ)}getReadBases(){if(!this.readBases&&this._refRegion){const e=function(e,t){if(!e.lengthOnRef&&!e.readLength)return null;if(e.isUnknownBases())return null;const r=e.alignmentStart-t.start;if(!e.readFeatures)return t.seq.slice(r,r+(e.lengthOnRef||0)).toUpperCase();let n="",o=r,i=0;for(;n.length<e.readLength;)if(i<e.readFeatures.length){const r=e.readFeatures[i];if("Q"===r.code||"q"===r.code)i+=1;else if(r.pos===n.length+1)if(i+=1,"b"===r.code){const e=r.data;n+=e,o+=e.length}else"B"===r.code?(n+=r.data[0],o+=1):"X"===r.code?(n+=r.sub,o+=1):"I"===r.code?n+=r.data:"D"===r.code?o+=r.data:"i"===r.code?n+=r.data:"N"===r.code?o+=r.data:"S"===r.code?n+=r.data:"P"===r.code||r.code;else if(i<e.readFeatures.length){const r=t.seq.slice(o,o+e.readFeatures[i].pos-n.length-1);n+=r,o+=r.length}}else{const r=t.seq.slice(o,o+e.readLength-n.length);n+=r,o+=r.length}return n.toUpperCase()}(this,this._refRegion);e&&(this.readBases=e)}return this.readBases}getPairOrientation(){if(!this.isSegmentUnmapped()&&this.isPaired()&&!this.isMateUnmapped()&&this.mate&&this.sequenceId===this.mate.sequenceId){const e=this.isReverseComplemented()?"R":"F",t=this.isMateReverseComplemented()?"R":"F";let r=" ",n=" ";this.isRead1()?(r="1",n="2"):this.isRead2()&&(r="2",n="1");const o=[];let i=this.templateLength||this.templateSize;if(void 0===i)throw new Error("One of templateSize and templateLength must be set");return this.alignmentStart>this.mate.alignmentStart&&i>0&&(i=-i),i>0?(o[0]=e,o[1]=r,o[2]=t,o[3]=n):(o[2]=e,o[3]=r,o[0]=t,o[1]=n),o.join("")}return null}addReferenceSequence(e,t){this.readFeatures&&this.readFeatures.forEach((r=>{"X"===r.code&&function(e,t,r,n){if(!t)return;const o=n.refPos-t.start,a=t.seq.charAt(o);a&&(n.ref=a);let s=i[a];void 0===s&&(s=4);const f=r.substitutionMatrix[s][n.data];f&&(n.sub=f)}(0,e,t,r)})),!this.readBases&&e.start<=this.alignmentStart&&e.end>=this.alignmentStart+(this.lengthOnRef||this.readLength)-1&&(this._refRegion=e)}toJSON(){const e={};return Object.keys(this).forEach((t=>{t.startsWith("_")||(e[t]=this[t])})),e.readBases=this.getReadBases(),e}}},3165:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getSectionParsers=t.cramFileDefinition=t.isMappedSliceHeader=void 0;const n=r(7936),o=(new n.Parser).itf8(),i={parser:(new n.Parser).string("magic",{length:4}).uint8("majorVersion").uint8("minorVersion").string("fileId",{length:20,stripNull:!0}),maxLength:26};t.cramFileDefinition=i;const a={parser:(new n.Parser).uint8("compressionMethod",{formatter:e=>{const t=["raw","gzip","bzip2","lzma","rans","rans4x16","arith","fqzcomp","tok3"][e];if(!t)throw new Error(`compression method number ${e} not implemented`);return t}}).uint8("contentType",{formatter:e=>{const t=["FILE_HEADER","COMPRESSION_HEADER","MAPPED_SLICE_HEADER","UNMAPPED_SLICE_HEADER","EXTERNAL_DATA","CORE_DATA"][e];if(!t)throw new Error(`invalid block content type id ${e}`);return t}}).itf8("contentId").itf8("compressedSize").itf8("uncompressedSize"),maxLength:17},s={parser:(new n.Parser).uint32("crc32"),maxLength:4},f=(new n.Parser).itf8("size").buffer("ents",{length:"size",formatter:e=>{function t(t,r){const n=e.toString("utf8",t,r),o=[];for(let e=0;e<n.length;e+=3)o.push(n.slice(e,e+3));return o}var r,n=[],o=0;for(r=0;r<e.length;r+=1)e[r]||(n.push(t(o,r)),o=r+1);return r>o&&n.push(t(o,r)),n}}),l=(new n.Parser).uint8(null,{formatter:e=>!!e}),u=(new n.Parser).itf8("mapSize").itf8("mapCount").array("ents",{length:"mapCount",type:(new n.Parser).string("key",{length:2,stripNull:!1}).choice("value",{tag:"key",choices:{MI:l,UI:l,PI:l,RN:l,AP:l,RR:l,SM:(new n.Parser).array(null,{type:"uint8",length:5}),TD:(new n.Parser).nest(null,{type:f,formatter:e=>e.ents})}})});function c(e){const t={};for(const{key:r,value:n}of e.ents)t[r]&&console.warn(`duplicate key ${r} in map`),t[r]=n;return t}const A={cramFileDefinition:i,cramBlockHeader:a,cramBlockCrc32:s};t.isMappedSliceHeader=function(e){return"number"==typeof e.refSeqId};const h={cramUnmappedSliceHeader(e){let t=0,r=(new n.Parser).itf8("numRecords");return t+=5,e>=3?(r=r.ltf8("recordCounter"),t+=9):2===e&&(r=r.itf8("recordCounter"),t+=5),r=r.itf8("numBlocks").itf8("numContentIds").array("contentIds",{type:o,length:"numContentIds"}),t+=10,e>=2&&(r=r.array("md5",{type:"uint8",length:16}),t+=16),{parser:r,maxLength:e=>t+5*e}},cramMappedSliceHeader(e){let t=(new n.Parser).itf8("refSeqId").itf8("refSeqStart").itf8("refSeqSpan").itf8("numRecords"),r=20;return e>=3?(t=t.ltf8("recordCounter"),r+=9):2===e&&(t=t.itf8("recordCounter"),r+=5),t=t.itf8("numBlocks").itf8("numContentIds").array("contentIds",{type:o,length:"numContentIds"}).itf8("refBaseBlockId"),r+=15,e>=2&&(t=t.array("md5",{type:"uint8",length:16}),r+=16),{parser:t,maxLength:e=>r+5*e}},cramEncoding:e=>({parser:(new n.Parser).namely("cramEncoding").itf8("codecId").itf8("parametersBytes").choice("parameters",{tag:"codecId",choices:{0:new n.Parser,1:(new n.Parser).itf8("blockContentId"),2:(new n.Parser).itf8("offset").itf8("M"),3:n.Parser.start().itf8("numCodes").array("symbols",{length:"numCodes",type:o}).itf8("numLengths").array("bitLengths",{length:"numLengths",type:o}),4:n.Parser.start().nest("lengthsEncoding",{type:"cramEncoding"}).nest("valuesEncoding",{type:"cramEncoding"}),5:(new n.Parser).uint8("stopByte").itf8("blockContentId"),6:(new n.Parser).itf8("offset").itf8("length"),7:(new n.Parser).itf8("offset").itf8("K"),8:(new n.Parser).itf8("offset").itf8("log2m"),9:(new n.Parser).itf8("offset")}})}),cramDataSeriesEncodingMap(e){return(new n.Parser).itf8("mapSize").itf8("mapCount").array("ents",{length:"mapCount",type:(new n.Parser).string("key",{length:2,stripNull:!1}).nest("value",{type:this.cramEncoding(e).parser})})},cramTagEncodingMap(e){return(new n.Parser).itf8("mapSize").itf8("mapCount").array("ents",{length:"mapCount",type:(new n.Parser).itf8("key",{formatter:e=>String.fromCharCode(e>>16&255)+String.fromCharCode(e>>8&255)+String.fromCharCode(255&e)}).nest("value",{type:this.cramEncoding(e).parser})})},cramCompressionHeader(e){let t=new n.Parser;return t=t.nest("preservation",{type:u,formatter:c}).nest("dataSeriesEncoding",{type:this.cramDataSeriesEncodingMap(e),formatter:c}).nest("tagEncoding",{type:this.cramTagEncodingMap(e),formatter:c}),{parser:t}},cramContainerHeader1(e){let t=(new n.Parser).int32("length").itf8("refSeqId").itf8("refSeqStart").itf8("alignmentSpan").itf8("numRecords"),r=24;return e>=3?(t=t.ltf8("recordCounter"),r+=9):2===e&&(t=t.itf8("recordCounter"),r+=5),e>1&&(t=t.ltf8("numBases"),r+=9),t=t.itf8("numBlocks").itf8("numLandmarks"),r+=10,{parser:t,maxLength:r}},cramContainerHeader2(e){let t=(new n.Parser).itf8("numLandmarks").array("landmarks",{type:(new n.Parser).itf8(),length:"numLandmarks"}),r=0;return e>=3&&(t=t.uint32("crc32"),r=4),{parser:t,maxLength:e=>5+5*e+r}}};t.getSectionParsers=function(e){const t=Object.assign({},A);return Object.keys(h).forEach((r=>{t[r]=h[r](e)})),t}},6484:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});const o=n(r(8570)),i=r(9747),a=r(8401),s=r(3165);function f(e){let t="";for(let r=0;r<e.length&&0!==e[r];r++)t+=String.fromCharCode(e[r]);return t}function l(e,t){if("Z"===e)return f(t);if("A"===e)return String.fromCharCode(t[0]);if("I"===e)return o.default.fromBytesLE(t).toNumber();if("i"===e)return new Int32Array(t.buffer)[0];if("s"===e)return new Int16Array(t.buffer)[0];if("S"===e)return new Uint16Array(t.buffer)[0];if("c"===e)return new Int8Array(t.buffer)[0];if("C"===e)return t[0];if("f"===e)return new Float32Array(t.buffer)[0];if("H"===e)return Number.parseInt(f(t).replace(/^0x/,""),16);if("B"===e)return function(e){const t=String.fromCharCode(e[0]),r=Int32Array.from(e.slice(1))[0],n=new Array(r);if(e=e.slice(5),"c"===t){const t=new Int8Array(e.buffer);for(let e=0;e<r;e+=1)n[e]=t[e]}else if("C"===t){const t=new Uint8Array(e.buffer);for(let e=0;e<r;e+=1)n[e]=t[e]}else if("s"===t){const t=new Int16Array(e.buffer);for(let e=0;e<r;e+=1)n[e]=t[e]}else if("S"===t){const t=new Uint16Array(e.buffer);for(let e=0;e<r;e+=1)n[e]=t[e]}else if("i"===t){const t=new Int32Array(e.buffer);for(let e=0;e<r;e+=1)n[e]=t[e]}else if("I"===t){const t=new Uint32Array(e.buffer);for(let e=0;e<r;e+=1)n[e]=t[e]}else{if("f"!==t)throw new Error("unknown type: "+t);{const t=new Float32Array(e.buffer);for(let e=0;e<r;e+=1)n[e]=t[e]}}return n}(t);throw new i.CramMalformedError(`Unrecognized tag type ${e}`)}t.default=function(e,t,r,n,o,u,c,A,h){let d=t("BF");const g=t("CF");if(!(0,s.isMappedSliceHeader)(n.parsedContent))throw new Error("slice header not mapped");const p=A>1&&-2===n.parsedContent.refSeqId?t("RI"):n.parsedContent.refSeqId,y=t("RL");let m=t("AP");r.APdelta&&(m+=c.lastAlignmentStart),c.lastAlignmentStart=m;const C=t("RG");let I,b,w,v;if(r.readNamesIncluded&&(I=f(t("RN"))),a.CramFlagsDecoder.isDetached(g)){const e=t("MF");let n;r.readNamesIncluded||(n=f(t("RN")),I=n);const o=t("NS"),i=t("NP");(e||o>-1)&&(b={mateFlags:e,mateSequenceId:o,mateAlignmentStart:i,mateReadName:n}),w=t("TS"),a.MateFlagsDecoder.isUnmapped(e)&&(d=a.BamFlagsDecoder.setMateUnmapped(d)),a.MateFlagsDecoder.isOnNegativeStrand(e)&&(d=a.BamFlagsDecoder.setMateReverseComplemented(d))}else a.CramFlagsDecoder.isWithMateDownstream(g)&&(v=t("NF")+h+1);const B=t("TL");if(B<0)throw new i.CramMalformedError("invalid TL index");const E={},_=r.getTagNames(B),Q=_.length;for(let t=0;t<Q;t+=1){const n=_[t],a=n.slice(0,2),s=n.slice(2,3),f=r.getCodecForTag(n);if(!f)throw new i.CramMalformedError(`no codec defined for auxiliary tag ${n}`);const A=f.decode(e,o,u,c);E[a]=l(s,A)}let S,k,R,D,N;if(a.BamFlagsDecoder.isSegmentUnmapped(d))if(a.CramFlagsDecoder.isDecodeSequenceAsStar(g))N=null,D=null;else{const e=new Array(y);for(let r=0;r<e.length;r+=1)e[r]=t("BA");if(N=String.fromCharCode(...e),a.CramFlagsDecoder.isPreservingQualityScores(g)){D=new Array(y);for(let r=0;r<e.length;r+=1)D[r]=t("QS")}}else{const e=t("FN");if(e&&(S=function(e,t,r,n,o){let a=0,s=e-1;const f=new Array(t);function l([e,t]){const n=r(t);if("character"===e)return String.fromCharCode(n);if("string"===e){let e="";for(let t=0;t<n.byteLength;t++)e+=String.fromCharCode(n[t]);return e}return"numArray"===e?n.toArray():n}for(let e=0;e<t;e+=1){const t=String.fromCharCode(r("FC")),n=r("FP"),u={B:["character","BA"],S:["string",o>1?"SC":"IN"],X:["number","BS"],D:["number","DL"],I:["string","IN"],i:["character","BA"],b:["string","BB"],q:["numArray","QQ"],Q:["number","QS"],H:["number","HC"],P:["number","PD"],N:["number","RS"]}[t];if(!u)throw new i.CramMalformedError(`invalid read feature code "${t}"`);let c=l(u);const A={B:["number","QS"]}[t];A&&(c=[c,l(A)]),a+=n;const h=a;s+=n;const d=s;"D"===t||"N"===t?s+=c:"I"===t||"S"===t?s-=c.length:"i"===t&&(s-=1),f[e]={code:t,pos:h,refPos:d,data:c}}return f}(m,e,t,0,A)),k=y,S)for(const{code:e,data:t}of S)"D"===e||"N"===e?k+=t:"I"===e||"S"===e?k-=t.length:"i"===e&&(k-=1);if(Number.isNaN(k)&&(console.warn(`${I||`${p}:${m}`} record has invalid read features`),k=y),R=t("MQ"),a.CramFlagsDecoder.isPreservingQualityScores(g)){D=new Array(y);for(let e=0;e<D.length;e++)D[e]=t("QS")}}return{readLength:y,sequenceId:p,cramFlags:g,flags:d,alignmentStart:m,readGroupId:C,readName:I,mateToUse:b,templateSize:w,mateRecordNumber:v,readFeatures:S,lengthOnRef:k,mappingQuality:R,qualityScores:D,readBases:N,tags:E}}},6771:function(e,t,r){"use strict";var n=this&&this.__awaiter||function(e,t,r,n){return new(r||(r=Promise))((function(o,i){function a(e){try{f(n.next(e))}catch(e){i(e)}}function s(e){try{f(n.throw(e))}catch(e){i(e)}}function f(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}f((n=n.apply(e,t||[])).next())}))},o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});const i=r(9747),a=r(400),s=o(r(7295)),f=o(r(6484)),l=o(r(8401)),u=r(3165),c=r(612);function A(e,t,r,n){if(!n)throw new i.CramMalformedError("could not resolve intra-slice mate pairs, file seems truncated or malformed");const o=!!(n.mate||void 0!==n.mateRecordNumber&&n.mateRecordNumber!==t);r.readName||(r.readName=String(r.uniqueId),n.readName=r.readName),r.mate={sequenceId:n.sequenceId,alignmentStart:n.alignmentStart,uniqueId:n.uniqueId},n.readName&&(r.mate.readName=n.readName),n.mate||void 0!==n.mateRecordNumber||(n.mate={sequenceId:r.sequenceId,alignmentStart:r.alignmentStart,uniqueId:r.uniqueId},r.readName&&(n.mate.readName=r.readName)),r.flags|=s.default.BAM_FPAIRED,n.flags&s.default.BAM_FUNMAP&&(r.flags|=s.default.BAM_FMUNMAP),r.flags&s.default.BAM_FUNMAP&&(n.flags|=s.default.BAM_FMUNMAP),n.flags&s.default.BAM_FREVERSE&&(r.flags|=s.default.BAM_FMREVERSE),r.flags&s.default.BAM_FREVERSE&&(n.flags|=s.default.BAM_FMREVERSE),void 0===r.templateLength&&(o?function(e,t,r){const n=function t(r){const n=[r];if(void 0!==r.mateRecordNumber&&r.mateRecordNumber>=0){const o=e[r.mateRecordNumber];if(!o)throw new i.CramMalformedError("intra-slice mate record not found, this file seems malformed");n.push(...t(o))}return n}(r),o=n.map((e=>e.alignmentStart)),a=n.map((e=>e.alignmentStart+e.readLength-1)),s=Math.max(...a)-Math.min(...o)+1;s>=0&&n.forEach((e=>{if(void 0!==e.templateLength)throw new i.CramMalformedError("mate pair group has some members that have template lengths already, this file seems malformed");e.templateLength=s}))}(e,0,r):function(e,t){const r=Math.min(e.alignmentStart,t.alignmentStart),n=Math.max(e.alignmentStart+e.readLength-1,t.alignmentStart+t.readLength-1)-r+1;e.templateLength=n,t.templateLength=n}(r,n)),delete r.mateRecordNumber}class h{constructor(e,t,r){this.container=e,this.containerPosition=t,this.file=e.file}getHeader(){return n(this,void 0,void 0,(function*(){const e=yield this.file.getSectionParsers(),t=yield this.container.getHeader(),r=yield this.file.readBlock(t._endPosition+this.containerPosition);if(void 0===r)throw new Error("block header undefined");if("MAPPED_SLICE_HEADER"===r.contentType){const n=(0,a.parseItem)(r.content,e.cramMappedSliceHeader.parser,0,t._endPosition);return Object.assign(Object.assign({},r),{parsedContent:n})}if("UNMAPPED_SLICE_HEADER"===r.contentType){const n=(0,a.parseItem)(r.content,e.cramUnmappedSliceHeader.parser,0,t._endPosition);return Object.assign(Object.assign({},r),{parsedContent:n})}throw new i.CramMalformedError(`error reading slice header block, invalid content type ${r.contentType}`)}))}getBlocks(){return n(this,void 0,void 0,(function*(){const e=yield this.getHeader();let t=e._endPosition;const r=new Array(e.parsedContent.numBlocks);for(let e=0;e<r.length;e+=1){const n=yield this.file.readBlock(t);if(void 0===n)throw new Error("block undefined");r[e]=n,t=r[e]._endPosition}return r}))}getCoreDataBlock(){return n(this,void 0,void 0,(function*(){return(yield this.getBlocks())[0]}))}_getBlocksContentIdIndex(){return n(this,void 0,void 0,(function*(){const e=yield this.getBlocks(),t={};return e.forEach((e=>{"EXTERNAL_DATA"===e.contentType&&(t[e.contentId]=e)})),t}))}getBlockByContentId(e){return n(this,void 0,void 0,(function*(){return(yield this._getBlocksContentIdIndex())[e]}))}getReferenceRegion(){return n(this,void 0,void 0,(function*(){const e=(yield this.getHeader()).parsedContent;if(!(0,u.isMappedSliceHeader)(e))throw new Error("slice header not mapped");if(e.refSeqId<0)return;const t=yield this.container.getCompressionScheme();if(void 0===t)throw new Error("compression scheme undefined");if(e.refBaseBlockId>=0){const t=yield this.getBlockByContentId(e.refBaseBlockId);if(!t)throw new i.CramMalformedError("embedded reference specified, but reference block does not exist");return{seq:t.data.toString("utf8"),start:e.refSeqStart,end:e.refSeqStart+e.refSeqSpan-1,span:e.refSeqSpan}}if(t.referenceRequired||this.file.fetchReferenceSequenceCallback){if(!this.file.fetchReferenceSequenceCallback)throw new Error("reference sequence not embedded, and seqFetch callback not provided, cannot fetch reference sequence");const t=yield this.file.fetchReferenceSequenceCallback(e.refSeqId,e.refSeqStart,e.refSeqStart+e.refSeqSpan-1);if(t.length!==e.refSeqSpan)throw new i.CramArgumentError("seqFetch callback returned a reference sequence of the wrong length");return{seq:t,start:e.refSeqStart,end:e.refSeqStart+e.refSeqSpan-1,span:e.refSeqSpan}}}))}getAllRecords(){return this.getRecords((()=>!0))}_fetchRecords(){return n(this,void 0,void 0,(function*(){const{majorVersion:e}=yield this.file.getDefinition(),t=yield this.container.getCompressionScheme();if(void 0===t)throw new Error("compression scheme undefined");const r=yield this.getHeader();if(void 0===r)throw new Error("slice header undefined");const n=yield this._getBlocksContentIdIndex();if(e>1&&this.file.options.checkSequenceMD5&&(0,u.isMappedSliceHeader)(r.parsedContent)&&r.parsedContent.refSeqId>=0&&"0000000000000000"!==r.parsedContent.md5.join("")){const e=yield this.getReferenceRegion();if(e){const{seq:t,start:n,end:o}=e,s=(0,a.sequenceMD5)(t),f=r.parsedContent.md5.map((e=>(e<16?"0":"")+e.toString(16))).join("");if(s!==f)throw new i.CramMalformedError(`MD5 checksum reference mismatch for ref ${r.parsedContent.refSeqId} pos ${n}..${o}. recorded MD5: ${f}, calculated MD5: ${s}`)}}const o=yield this.getCoreDataBlock(),s={lastAlignmentStart:(0,u.isMappedSliceHeader)(r.parsedContent)?r.parsedContent.refSeqStart:0,coreBlock:{bitPosition:7,bytePosition:0},externalBlocks:{map:new Map,getCursor(e){let t=this.map.get(e);return void 0===t&&(t={bitPosition:7,bytePosition:0},this.map.set(e,t)),t}}},h=e=>{const r=t.getCodecForDataSeries(e);if(!r)throw new i.CramMalformedError(`no codec defined for ${e} data series`);return r.decode(this,o,n,s)};let d=new Array(r.parsedContent.numRecords);for(let i=0;i<d.length;i+=1)try{const a=(0,f.default)(this,h,t,r,o,n,s,e,i);d[i]=new l.default(Object.assign(Object.assign({},a),{uniqueId:r.contentPosition+r.parsedContent.recordCounter+i+1}))}catch(e){if(e instanceof c.CramBufferOverrunError){console.warn("read attempted beyond end of buffer, file seems truncated."),d=d.filter((e=>!!e));break}throw e}for(let e=0;e<d.length;e+=1){const{mateRecordNumber:t}=d[e];void 0!==t&&t>=0&&A(d,e,d[e],d[t])}return d}))}getRecords(e){return n(this,void 0,void 0,(function*(){const t=this.container.filePosition+this.containerPosition;let r=this.file.featureCache.get(t.toString());r||(r=this._fetchRecords(),this.file.featureCache.set(t.toString(),r));const o=(yield r).filter(e);if(o.length&&this.file.fetchReferenceSequenceCallback){const e=yield this.getHeader();if((0,u.isMappedSliceHeader)(e.parsedContent)&&(e.parsedContent.refSeqId>=0||-2===e.parsedContent.refSeqId)){const t=e.parsedContent.refSeqId>=0?e.parsedContent.refSeqId:void 0,r=yield this.container.getCompressionScheme();if(void 0===r)throw new Error("compression scheme undefined");const i={};for(const e of o){const r=void 0!==t?t:e.sequenceId;let n=i[r];n||(n={id:r,start:e.alignmentStart,end:-1/0,seq:null},i[r]=n);const o=e.alignmentStart+(e.lengthOnRef||e.readLength)-1;o>n.end&&(n.end=o),e.alignmentStart<n.start&&(n.start=e.alignmentStart)}yield Promise.all(Object.values(i).map((e=>n(this,void 0,void 0,(function*(){-1!==e.id&&e.start<=e.end&&this.file.fetchReferenceSequenceCallback&&(e.seq=yield this.file.fetchReferenceSequenceCallback(e.id,e.start,e.end))})))));for(const e of o){const n=i[void 0!==t?t:e.sequenceId];if(null==n?void 0:n.seq){const t=n.seq;e.addReferenceSequence(Object.assign(Object.assign({},n),{seq:t}),r)}}}}return o}))}}t.default=h,"getHeader getBlocks _getBlocksContentIdIndex".split(" ").forEach((e=>(0,a.tinyMemoize)(h,e)))},400:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.sequenceMD5=t.tinyMemoize=t.parseItem=t.parseItf8=t.itf8Size=void 0;const o=n(r(3503)),i=r(612);t.itf8Size=function(e){return-128&e?-16384&e?-2097152&e?-268435456&e?5:4:3:2:1},t.parseItf8=function(e,t){let r=t;const n=e[r];let o;if(n<128?(o=n,r+=1):n<192?(o=16383&(n<<8|e[r+1]),r+=2):n<224?(o=2097151&(n<<16|e[r+1]<<8|e[r+2]),r+=3):n<240?(o=268435455&(n<<24|e[r+1]<<16|e[r+2]<<8|e[r+3]),r+=4):(o=(15&n)<<28|e[r+1]<<20|e[r+2]<<12|e[r+3]<<4|15&e[r+4],r+=5),r>e.length)throw new i.CramBufferOverrunError("Attempted to read beyond end of buffer; this file seems truncated.");return[o,r-t]},t.parseItem=function(e,t,r=0,n=0){const{offset:o,result:i}=t.parse(e);return Object.assign(Object.assign({},i),{_endPosition:o+n,_size:o-r})},t.tinyMemoize=function(e,t){const r=e.prototype[t],n=`_memo_${t}`;e.prototype[t]=function(){if(!(n in this)){const e=r.call(this);this[n]=e,Promise.resolve(e).catch((()=>{delete this[n]}))}return this[n]}},t.sequenceMD5=function(e){return(0,o.default)(e.toUpperCase().replaceAll(/[^\u0021-\u007e]/g,""))}},9747:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.CramArgumentError=t.CramSizeLimitError=t.CramMalformedError=t.CramUnimplementedError=t.CramError=void 0;class r extends Error{}t.CramError=r;class n extends Error{}t.CramUnimplementedError=n,t.CramMalformedError=class extends r{},t.CramSizeLimitError=class extends r{},t.CramArgumentError=class extends r{}},7806:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.IndexedCramFile=t.CraiIndex=t.CramRecord=t.CramFile=void 0;var o=r(7390);Object.defineProperty(t,"CramFile",{enumerable:!0,get:function(){return n(o).default}}),Object.defineProperty(t,"CramRecord",{enumerable:!0,get:function(){return o.CramRecord}});var i=r(4923);Object.defineProperty(t,"CraiIndex",{enumerable:!0,get:function(){return n(i).default}});var a=r(6014);Object.defineProperty(t,"IndexedCramFile",{enumerable:!0,get:function(){return n(a).default}})},6014:function(e,t,r){"use strict";var n=this&&this.__awaiter||function(e,t,r,n){return new(r||(r=Promise))((function(o,i){function a(e){try{f(n.next(e))}catch(e){i(e)}}function s(e){try{f(n.throw(e))}catch(e){i(e)}}function f(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}f((n=n.apply(e,t||[])).next())}))},o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});const i=r(9747),a=o(r(7390));t.default=class{constructor(e){var t;if(this.cram=null!==(t=e.cram)&&void 0!==t?t:new a.default({url:e.cramUrl,path:e.cramPath,filehandle:e.cramFilehandle,seqFetch:e.seqFetch,checkSequenceMD5:e.checkSequenceMD5,cacheSize:e.cacheSize}),!(this.cram instanceof a.default))throw new Error("invalid arguments: no cramfile");if(this.index=e.index,!this.index.getEntriesForRange)throw new Error("invalid arguments: not an index");this.fetchSizeLimit=e.fetchSizeLimit||3e6}getRecordsForRange(e,t,r,o={}){return n(this,void 0,void 0,(function*(){if(o.viewAsPairs=o.viewAsPairs||!1,o.pairAcrossChr=o.pairAcrossChr||!1,o.maxInsertSize=o.maxInsertSize||2e5,"string"==typeof e)throw new i.CramUnimplementedError("string sequence names not yet supported");const n=e,a=yield this.index.getEntriesForRange(n,t,r),s=a.map((e=>e.sliceBytes)).reduce(((e,t)=>e+t),0);if(s>this.fetchSizeLimit)throw new i.CramSizeLimitError(`data size of ${s.toLocaleString()} bytes exceeded fetch size limit of ${this.fetchSizeLimit.toLocaleString()} bytes`);const f=n=>n.sequenceId===e&&n.alignmentStart<=r&&void 0!==n.lengthOnRef&&n.alignmentStart+n.lengthOnRef-1>=t,l=yield Promise.all(a.map((e=>this.getRecordsInSlice(e,f))));let u=Array.prototype.concat(...l);if(o.viewAsPairs){const e={},t={};for(const r of u){const n=r.readName;if(void 0===n)throw new Error("readName undefined");const o=r.uniqueId;e[n]||(e[n]=0),e[n]+=1,t[o]=1}const r={};Object.entries(e).forEach((([e,t])=>{1===t&&(r[e]=!0)}));const i=[];for(const e of u){const t=e.readName;if(void 0===t)throw new Error("readName undefined");if(r[t]&&e.mate&&(e.mate.sequenceId===n||o.pairAcrossChr)&&Math.abs(e.alignmentStart-e.mate.alignmentStart)<o.maxInsertSize){const t=this.index.getEntriesForRange(e.mate.sequenceId,e.mate.alignmentStart,e.mate.alignmentStart+1);i.push(t)}}const a=yield Promise.all(i);let s=[];for(const e of a)s.push(...e);s=s.sort(((e,t)=>e.toString().localeCompare(t.toString()))).filter(((e,t,r)=>!t||e.toString()!==r[t-1].toString()));const f=[],l=[],c=s.map((e=>e.sliceBytes)).reduce(((e,t)=>e+t),0);if(c>this.fetchSizeLimit)throw new Error(`mate data size of ${c.toLocaleString()} bytes exceeded fetch size limit of ${this.fetchSizeLimit.toLocaleString()} bytes`);s.forEach((e=>{let n=this.cram.featureCache.get(e.toString());n||(n=this.getRecordsInSlice(e,(()=>!0)),this.cram.featureCache.set(e.toString(),n)),f.push(n);const o=n.then((e=>{const n=[];for(const o of e){if(void 0===o.readName)throw new Error("readName undefined");r[o.readName]&&!t[o.uniqueId]&&n.push(o)}return n}));l.push(o)}));const A=yield Promise.all(l);if(A.length){const e=A.reduce(((e,t)=>e.concat(t)));u=u.concat(e)}}return u}))}getRecordsInSlice({containerStart:e,sliceStart:t,sliceBytes:r},n){return this.cram.getContainerAtPosition(e).getSlice(t,r).getRecords(n)}hasDataForReferenceSequence(e){return this.index.hasDataForReferenceSequence(e)}}},5931:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.RemoteFile=t.LocalFile=t.open=t.fromUrl=void 0;const o=n(r(8835)),i=r(7903),a=r(1113);function s(e){const{protocol:t,pathname:r}=o.default.parse(e);return"file:"===t?new a.LocalFile(unescape((0,i.ensureNotNullish)(r))):new a.RemoteFile(e)}t.fromUrl=s,t.open=function(e,t,r){if(r)return r;if(e)return s(e);if(t)return new a.LocalFile(t);throw new Error("no url, path, or filehandle provided, cannot open")};var f=r(1113);Object.defineProperty(t,"LocalFile",{enumerable:!0,get:function(){return f.LocalFile}}),Object.defineProperty(t,"RemoteFile",{enumerable:!0,get:function(){return f.RemoteFile}})},6476:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.RANS_BYTE_L=t.TOTFREQ=t.TF_SHIFT=void 0,t.TF_SHIFT=12,t.TOTFREQ=4096,t.RANS_BYTE_L=1<<23},997:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});const o=r(9747),i=r(6476),a=n(r(488));t.default=function(e,t,r,n){let s=e.getInt(),f=e.getInt(),l=e.getInt(),u=e.getInt();const c=n.remaining(),A=-4&c;for(let o=0;o<A;o+=4){const c=t.R[a.default.get(s,i.TF_SHIFT)],A=t.R[a.default.get(f,i.TF_SHIFT)],h=t.R[a.default.get(l,i.TF_SHIFT)],d=t.R[a.default.get(u,i.TF_SHIFT)];n.putAt(o,c),n.putAt(o+1,A),n.putAt(o+2,h),n.putAt(o+3,d),s=a.default.advanceSymbolStep(s,r[255&c],i.TF_SHIFT),f=a.default.advanceSymbolStep(f,r[255&A],i.TF_SHIFT),l=a.default.advanceSymbolStep(l,r[255&h],i.TF_SHIFT),u=a.default.advanceSymbolStep(u,r[255&d],i.TF_SHIFT),s=a.default.renormalize(s,e),f=a.default.renormalize(f,e),l=a.default.renormalize(l,e),u=a.default.renormalize(u,e)}let h;switch(n.setPosition(A),3&c){case 0:break;case 1:h=t.R[a.default.get(s,i.TF_SHIFT)],a.default.advanceSymbol(s,e,r[255&h],i.TF_SHIFT),n.put(h);break;case 2:h=t.R[a.default.get(s,i.TF_SHIFT)],a.default.advanceSymbol(s,e,r[255&h],i.TF_SHIFT),n.put(h),h=t.R[a.default.get(f,i.TF_SHIFT)],a.default.advanceSymbol(f,e,r[255&h],i.TF_SHIFT),n.put(h);break;case 3:h=t.R[a.default.get(s,i.TF_SHIFT)],a.default.advanceSymbol(s,e,r[255&h],i.TF_SHIFT),n.put(h),h=t.R[a.default.get(f,i.TF_SHIFT)],a.default.advanceSymbol(f,e,r[255&h],i.TF_SHIFT),n.put(h),h=t.R[a.default.get(l,i.TF_SHIFT)],a.default.advanceSymbol(l,e,r[255&h],i.TF_SHIFT),n.put(h);break;default:throw new o.CramMalformedError("invalid output size encountered during rANS decoding")}n.setPosition(0)}},7960:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});const o=r(6476),i=n(r(488));t.default=function(e,t,r,n){const a=t.remaining();let s=e.getInt(),f=e.getInt(),l=e.getInt(),u=e.getInt();const c=a>>2;let A=0,h=c,d=2*c,g=3*c,p=0,y=0,m=0,C=0;for(;A<c;A+=1,h+=1,d+=1,g+=1){const a=255&r[p].R[i.default.get(s,o.TF_SHIFT)],c=255&r[y].R[i.default.get(f,o.TF_SHIFT)],I=255&r[m].R[i.default.get(l,o.TF_SHIFT)],b=255&r[C].R[i.default.get(u,o.TF_SHIFT)];t.putAt(A,a),t.putAt(h,c),t.putAt(d,I),t.putAt(g,b),s=i.default.advanceSymbolStep(s,n[p][a],o.TF_SHIFT),f=i.default.advanceSymbolStep(f,n[y][c],o.TF_SHIFT),l=i.default.advanceSymbolStep(l,n[m][I],o.TF_SHIFT),u=i.default.advanceSymbolStep(u,n[C][b],o.TF_SHIFT),s=i.default.renormalize(s,e),f=i.default.renormalize(f,e),l=i.default.renormalize(l,e),u=i.default.renormalize(u,e),p=a,y=c,m=I,C=b}for(;g<a;g+=1){const a=255&r[C].R[i.default.get(u,o.TF_SHIFT)];t.putAt(g,a),u=i.default.advanceSymbol(u,e,n[C][a],o.TF_SHIFT),C=a}}},488:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(9747),o=r(6476);class i{constructor(){this.F=void 0,this.C=void 0}}function a(e,t,r,n){return r*(e>>n)+(e&(1<<n)-1)-t}const s={FC:i,AriDecoder:class{constructor(){this.fc=new Array(256);for(let e=0;e<this.fc.length;e+=1)this.fc[e]=new i;this.R=null}},Symbol:class{constructor(){this.start=void 0,this.freq=void 0}},symbolInit:function(e,t,r){if(!(t<=65536))throw new n.CramMalformedError("assertion failed: start <= 1<<16");if(!(r<=65536-t))throw new n.CramMalformedError("assertion failed: freq <= 1<<16");e.start=t,e.freq=r},advanceStep:a,advanceSymbolStep:function(e,t,r){return a(e,t.start,t.freq,r)},get:function(e,t){return e&(1<<t)-1},advanceSymbol:function(e,t,r,n){return function(e,t,r,n,i){if((e=n*(e>>i)+(e&(1<<i)-1)-r)<o.RANS_BYTE_L)do{e=e<<8|255&t.get()}while(e<o.RANS_BYTE_L);return e}(e,t,r.start,r.freq,n)},renormalize:function(e,t){if(e<o.RANS_BYTE_L)do{e=e<<8|255&t.get()}while(e<o.RANS_BYTE_L);return e}};t.default=s},1971:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.readStatsO1=t.readStatsO0=void 0;const o=r(9747),i=r(6476),a=n(r(488));function s(e){if(!e)throw new o.CramMalformedError("assertion failed")}t.readStatsO0=function(e,t,r){let n=0,o=0,f=255&e.get();do{null==t.fc[f]&&(t.fc[f]=new a.default.FC),t.fc[f].F=255&e.get(),t.fc[f].F>=128&&(t.fc[f].F&=-129,t.fc[f].F=(127&t.fc[f].F)<<8|255&e.get()),t.fc[f].C=o,a.default.symbolInit(r[f],t.fc[f].C,t.fc[f].F),t.R||(t.R=new Array(i.TOTFREQ)),t.R.fill(f,o,o+t.fc[f].F),o+=t.fc[f].F,0===n&&f+1===(255&e.getByteAt(e.position()))?(f=255&e.get(),n=255&e.get()):0!==n?(n-=1,f+=1):f=255&e.get()}while(0!==f);s(o<i.TOTFREQ)},t.readStatsO1=function(e,t,r){let n=0,o=255&e.get();do{let f=0,l=0,u=255&e.get();null==t[o]&&(t[o]=new a.default.AriDecoder);do{null==t[o].fc[u]&&(t[o].fc[u]=new a.default.FC),t[o].fc[u].F=255&e.get(),t[o].fc[u].F>=128&&(t[o].fc[u].F&=-129,t[o].fc[u].F=(127&t[o].fc[u].F)<<8|255&e.get()),t[o].fc[u].C=l,0===t[o].fc[u].F&&(t[o].fc[u].F=i.TOTFREQ),null==r[o][u]&&(r[o][u]=new a.default.RansDecSymbol),a.default.symbolInit(r[o][u],t[o].fc[u].C,t[o].fc[u].F),null==t[o].R&&(t[o].R=new Array(i.TOTFREQ)),t[o].R.fill(u,l,l+t[o].fc[u].F),l+=t[o].fc[u].F,s(l<=i.TOTFREQ),0===f&&u+1===(255&e.getByteAt(e.position()))?(u=255&e.get(),f=255&e.get()):0!==f?(f-=1,u+=1):u=255&e.get()}while(0!==u);0===n&&o+1===(255&e.getByteAt(e.position()))?(o=255&e.get(),n=255&e.get()):0!==n?(n-=1,o+=1):o=255&e.get()}while(0!==o)}},9989:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});const o=r(9747),i=n(r(488)),a=r(1971),s=n(r(997)),f=n(r(7960));class l{constructor(e,t=0){this._buffer=e,this._position=t,this.length=e.length}get(){const e=this._buffer[this._position];return this._position+=1,e}getByte(){return this.get()}getByteAt(e){return this._buffer[e]}position(){return this._position}put(e){return this._buffer[this._position]=e,this._position+=1,e}putAt(e,t){return this._buffer[e]=t,t}setPosition(e){return this._position=e,e}getInt(){const e=this._buffer.readInt32LE(this._position);return this._position+=4,e}remaining(){return this._buffer.length-this._position}}t.default=function(e,t,r=0){if(0===e.length)return t.fill(0),t;const n=new l(e,r),u=n.get();if(0!==u&&1!==u)throw new o.CramMalformedError(`Invalid rANS order ${u}`);if(n.getInt()!==n.remaining()-4)throw new o.CramMalformedError("Incorrect input length.");const c=n.getInt(),A=new l(t||Buffer.allocUnsafe(c));if(A.length<c)throw new o.CramMalformedError(`Output buffer too small to fit ${c} bytes.`);switch(u){case 0:return function(e,t){const r=new i.default.AriDecoder,n=new Array(256);for(let e=0;e<n.length;e+=1)n[e]=new i.default.Symbol;return(0,a.readStatsO0)(e,r,n),(0,s.default)(e,r,n,t),t}(n,A);case 1:return function(e,t){const r=new Array(256);for(let e=0;e<r.length;e+=1)r[e]=new i.default.AriDecoder;const n=new Array(256);for(let e=0;e<n.length;e+=1){n[e]=new Array(256);for(let t=0;t<n[e].length;t+=1)n[e][t]=new i.default.Symbol}return(0,a.readStatsO1)(e,r,n),(0,f.default)(e,t,r,n),t}(n,A);default:throw new o.CramMalformedError(`Invalid rANS order: ${u}`)}}},5417:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.parseHeaderText=void 0,t.parseHeaderText=function(e){const t=e.split(/\r?\n/),r=[];for(const e of t){const[t,...n]=e.split(/\t/);t&&r.push({tag:t.slice(1),data:n.map((e=>{const t=e.indexOf(":");return-1!==t?{tag:e.slice(0,t),value:e.slice(t+1)}:{tag:e,value:void 0}}))})}return r}},7903:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ensureNotNullish=void 0,t.ensureNotNullish=function(e){if(null==e)throw new Error("Value must not be nullish.");return e}},8712:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.unzip=void 0;const n=r(1668);t.unzip=function(e){return Buffer.from((0,n.inflate)(e))}},7936:(e,t,r)=>{"use strict";function n(e){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n(e)}var o=r(8287).Buffer,i=r(3738),a=r(2838).o,s=r(8570);"undefined"!=typeof window&&(window.Buffer=o),"undefined"!=typeof self&&(self.Buffer=o);var f={UInt8:1,UInt16LE:2,UInt16BE:2,UInt32LE:4,UInt32BE:4,Int8:1,Int16LE:2,Int16BE:2,Int32LE:4,Int32BE:4,FloatLE:4,FloatBE:4,DoubleLE:8,DoubleBE:8,UInt64:8,Int64:8},l={},u="___parser_",c=[];!function(){var e;for(e=1;e<=32;e++)c.push(e)}();var A={};Object.keys(f).concat(Object.keys({String:null,Buffer:null,Array:null,Skip:null,Choice:null,Nest:null,Bit:null,Itf8:null,Ltf8:null})).forEach((function(e){A[e.toLowerCase()]=e}));var h=function(){this.varName="",this.type="",this.options={},this.next=null,this.head=null,this.compiled=null,this.endian="le",this.constructorFn=null,this.alias=null};h.start=function(){return new h},Object.keys(f).forEach((function(e){h.prototype[e.toLowerCase()]=function(t,r){return this.setNextParser(e.toLowerCase(),t,r)};var t=e.replace(/BE|LE/,"").toLowerCase();t in h.prototype||(h.prototype[t]=function(e,r){return this[t+this.endian](e,r)})})),c.forEach((function(e){h.prototype["bit".concat(e.toString())]=function(t,r){return r||(r={}),r.length=e,this.setNextParser("bit",t,r)}})),h.prototype.namely=function(e){return l[e]=this,this.alias=e,this},h.prototype.skip=function(e,t){if(t&&t.assert)throw new Error("assert option on skip is not allowed.");return this.setNextParser("skip","",{length:e})},h.prototype.string=function(e,t){if(!t.zeroTerminated&&!t.length&&!t.greedy)throw new Error("Neither length, zeroTerminated, nor greedy is defined for string.");if((t.zeroTerminated||t.length)&&t.greedy)throw new Error("greedy is mutually exclusive with length and zeroTerminated for string.");if(t.stripNull&&!t.length&&!t.greedy)throw new Error("Length or greedy must be defined if stripNull is defined.");return t.encoding=t.encoding||"utf8",this.setNextParser("string",e,t)},h.prototype.buffer=function(e,t){if(!t.length&&!t.readUntil)throw new Error("Length nor readUntil is defined in buffer parser");return this.setNextParser("buffer",e,t)},h.prototype.array=function(e,t){if(!t.readUntil&&!t.length&&!t.lengthInBytes)throw new Error("Length option of array is not defined.");if(!t.type)throw new Error("Type option of array is not defined.");if("string"==typeof t.type&&!l[t.type]&&Object.keys(f).indexOf(A[t.type])<0)throw new Error('Specified primitive type "'.concat(t.type,'" is not supported.'));return this.setNextParser("array",e,t)},h.prototype.choice=function(e,t){if(1===arguments.length&&"object"===n(e)&&(t=e,e=null),!t.tag)throw new Error("Tag option of array is not defined.");if(!t.choices)throw new Error("Choices option of array is not defined.");return Object.keys(t.choices).forEach((function(r){if(!t.choices[r])throw new Error("Choice Case ".concat(r," of ").concat(e," is not valid."));if("string"==typeof t.choices[r]&&!l[t.choices[r]]&&Object.keys(f).indexOf(A[t.choices[r]])<0)throw new Error('Specified primitive type "'.concat(t.choices[r],'" is not supported.'))}),this),this.setNextParser("choice",e,t)},h.prototype.nest=function(e,t){if(1===arguments.length&&"object"===n(e)&&(t=e,e=null),!t.type)throw new Error("Type option of nest is not defined.");if(!(t.type instanceof h||l[t.type]))throw new Error("Type option of nest must be a Parser object.");if(!(t.type instanceof h||e))throw new Error("options.type must be a object if variable name is omitted.");return this.setNextParser("nest",e,t)},h.prototype.endianess=function(e){switch(e.toLowerCase()){case"little":this.endian="le";break;case"big":this.endian="be";break;default:throw new Error("Invalid endianess: ".concat(e))}return this},h.prototype.create=function(e){if(!(e instanceof Function))throw new Error("Constructor must be a Function object.");return this.constructorFn=e,this},h.prototype.getCode=function(){var e=new a;return e.pushCode("if (!Buffer.isBuffer(buffer)) {"),e.generateError('"argument buffer is not a Buffer object"'),e.pushCode("}"),this.alias?this.addAliasedCode(e):this.addRawCode(e),this.alias?e.pushCode("return {0}(0)",u+this.alias):e.pushCode("return { offset: offset, result: vars };"),e.code},h.prototype.addRawCode=function(e){e.pushCode("var offset = 0;"),this.constructorFn?e.pushCode("var vars = new constructorFn();"):e.pushCode("var vars = {};"),this.generate(e),this.resolveReferences(e),e.pushCode("return { offset: offset, result: vars };")},h.prototype.addAliasedCode=function(e){return e.pushCode("function {0}(offset) {",u+this.alias),this.constructorFn?e.pushCode("var vars = new constructorFn();"):e.pushCode("var vars = {};"),this.generate(e),e.markResolved(this.alias),this.resolveReferences(e),e.pushCode("return { offset: offset, result: vars };"),e.pushCode("}"),e},h.prototype.resolveReferences=function(e){var t=e.getUnresolvedReferences();e.markRequested(t),t.forEach((function(t){l[t].addAliasedCode(e)}))},h.prototype.compile=function(){var e="(function(buffer, constructorFn, Long) { ".concat(this.getCode()," })");this.compiled=i.runInThisContext(e)},h.prototype.sizeOf=function(){var e=NaN;if(Object.keys(f).indexOf(this.type)>=0)e=f[this.type];else if("String"===this.type&&"number"==typeof this.options.length)e=this.options.length;else if("Buffer"===this.type&&"number"==typeof this.options.length)e=this.options.length;else if("Array"===this.type&&"number"==typeof this.options.length){var t=NaN;"string"==typeof this.options.type?t=f[A[this.options.type]]:this.options.type instanceof h&&(t=this.options.type.sizeOf()),e=this.options.length*t}else"Skip"===this.type?e=this.options.length:"Nest"===this.type?e=this.options.type.sizeOf():this.type||(e=0);return this.next&&(e+=this.next.sizeOf()),e},h.prototype.parse=function(e){return this.compiled||this.compile(),this.compiled(e,this.constructorFn,s)},h.prototype.setNextParser=function(e,t,r){var n=new h;return n.type=A[e],n.varName=t,n.options=r||n.options,n.endian=this.endian,this.head?this.head.next=n:this.next=n,this.head=n,this},h.prototype.generate=function(e){this.type&&(this["generate".concat(this.type)](e),this.generateAssert(e));var t=e.generateVariable(this.varName);return this.options.formatter&&this.generateFormatter(e,t,this.options.formatter),this.generateNext(e)},h.prototype.generateAssert=function(e){if(this.options.assert){var t=e.generateVariable(this.varName);switch(n(this.options.assert)){case"function":e.pushCode("if (!({0}).call(vars, {1})) {",this.options.assert,t);break;case"number":e.pushCode("if ({0} !== {1}) {",this.options.assert,t);break;case"string":e.pushCode('if ("{0}" !== {1}) {',this.options.assert,t);break;default:throw new Error("Assert option supports only strings, numbers and assert functions.")}e.generateError('"Assert error: {0} is " + {0}',t),e.pushCode("}")}},h.prototype.generateNext=function(e){return this.next&&(e=this.next.generate(e)),e},Object.keys(f).forEach((function(e){h.prototype["generate".concat(e)]=function(t){"UInt64"===e?t.pushCode("{0} = Long.fromBytes(buffer.slice(offset,offset+8), true, this.endian === 'le').toNumber();",t.generateVariable(this.varName),e):"Int64"===e?t.pushCode("{0} = Long.fromBytes(buffer.slice(offset,offset+8), false, this.endian === 'le').toNumber();",t.generateVariable(this.varName),e):t.pushCode("{0} = buffer.read{1}(offset);",t.generateVariable(this.varName),e),t.pushCode("offset += {0};",f[e])}})),h.prototype.generateBit=function(e){var t=JSON.parse(JSON.stringify(this));if(t.varName=e.generateVariable(t.varName),e.bitFields.push(t),!this.next||this.next&&["Bit","Nest"].indexOf(this.next.type)<0){var r=0;e.bitFields.forEach((function(e){r+=e.options.length}));var n=e.generateTmpVariable();if(r<=8)e.pushCode("var {0} = buffer.readUInt8(offset);",n),r=8;else if(r<=16)e.pushCode("var {0} = buffer.readUInt16BE(offset);",n),r=16;else if(r<=24){var o=e.generateTmpVariable(),i=e.generateTmpVariable();e.pushCode("var {0} = buffer.readUInt16BE(offset);",o),e.pushCode("var {0} = buffer.readUInt8(offset + 2);",i),e.pushCode("var {2} = ({0} << 8) | {1};",o,i,n),r=24}else{if(!(r<=32))throw new Error("Currently, bit field sequence longer than 4-bytes is not supported.");e.pushCode("var {0} = buffer.readUInt32BE(offset);",n),r=32}e.pushCode("offset += {0};",r/8);var a=0,s="be"===this.endian;e.bitFields.forEach((function(t){e.pushCode("{0} = {1} >> {2} & {3};",t.varName,n,s?r-a-t.options.length:a,(1<<t.options.length)-1),a+=t.options.length})),e.bitFields=[]}},h.prototype.generateSkip=function(e){var t=e.generateOption(this.options.length);e.pushCode("offset += {0};",t)},h.prototype.generateString=function(e){var t=e.generateVariable(this.varName),r=e.generateTmpVariable();this.options.length&&this.options.zeroTerminated?(e.pushCode("var {0} = offset;",r),e.pushCode("while(buffer.readUInt8(offset++) !== 0 && offset - {0} < {1});",r,this.options.length),e.pushCode("{0} = buffer.toString('{1}', {2}, offset - {2} < {3} ? offset - 1 : offset);",t,this.options.encoding,r,this.options.length)):this.options.length?(e.pushCode("{0} = buffer.toString('{1}', offset, offset + {2});",t,this.options.encoding,e.generateOption(this.options.length)),e.pushCode("offset += {0};",e.generateOption(this.options.length))):this.options.zeroTerminated?(e.pushCode("var {0} = offset;",r),e.pushCode("while(buffer.readUInt8(offset++) !== 0);"),e.pushCode("{0} = buffer.toString('{1}', {2}, offset - 1);",t,this.options.encoding,r)):this.options.greedy&&(e.pushCode("var {0} = offset;",r),e.pushCode("while(buffer.length > offset++);"),e.pushCode("{0} = buffer.toString('{1}', {2}, offset);",t,this.options.encoding,r)),this.options.stripNull&&e.pushCode("{0} = {0}.replace(/\\x00+$/g, '')",t)},h.prototype.generateBuffer=function(e){"eof"===this.options.readUntil?e.pushCode("{0} = buffer.slice(offset);",e.generateVariable(this.varName)):(e.pushCode("{0} = buffer.slice(offset, offset + {1});",e.generateVariable(this.varName),e.generateOption(this.options.length)),e.pushCode("offset += {0};",e.generateOption(this.options.length))),this.options.clone&&e.pushCode("{0} = Buffer.from({0});",e.generateVariable(this.varName))},h.prototype.generateArray=function(e){var t=e.generateOption(this.options.length),r=e.generateOption(this.options.lengthInBytes),n=this.options.type,o=e.generateTmpVariable(),i=e.generateVariable(this.varName),a=e.generateTmpVariable(),s=this.options.key,c="string"==typeof s;if(c?e.pushCode("{0} = {};",i):e.pushCode("{0} = [];",i),"function"==typeof this.options.readUntil?e.pushCode("do {"):"eof"===this.options.readUntil?e.pushCode("for (var {0} = 0; offset < buffer.length; {0}++) {",o):void 0!==r?e.pushCode("for (var {0} = offset; offset - {0} < {1}; ) {",o,r):e.pushCode("for (var {0} = 0; {0} < {1}; {0}++) {",o,t),"string"==typeof n)if(l[n]){var d=e.generateTmpVariable();e.pushCode("var {0} = {1}(offset);",d,u+n),e.pushCode("var {0} = {1}.result; offset = {1}.offset;",a,d),n!==this.alias&&e.addReference(n)}else e.pushCode("var {0} = buffer.read{1}(offset);",a,A[n]),e.pushCode("offset += {0};",f[A[n]]);else n instanceof h&&(e.pushCode("var {0} = {};",a),e.pushScope(a),n.generate(e),e.popScope());c?e.pushCode("{0}[{2}.{1}] = {2};",i,s,a):e.pushCode("{0}.push({1});",i,a),e.pushCode("}"),"function"==typeof this.options.readUntil&&e.pushCode(" while (!({0}).call(this, {1}, buffer.slice(offset)));",this.options.readUntil,a)},h.prototype.generateChoiceCase=function(e,t,r){if("string"==typeof r)if(l[r]){var n=e.generateTmpVariable();e.pushCode("var {0} = {1}(offset);",n,u+r),e.pushCode("{0} = {1}.result; offset = {1}.offset;",e.generateVariable(this.varName),n),r!==this.alias&&e.addReference(r)}else e.pushCode("{0} = buffer.read{1}(offset);",e.generateVariable(this.varName),A[r]),e.pushCode("offset += {0};",f[A[r]]);else r instanceof h&&(e.pushPath(t),r.generate(e),e.popPath(t))},h.prototype.generateChoice=function(e){var t=e.generateOption(this.options.tag);this.varName&&e.pushCode("{0} = {};",e.generateVariable(this.varName)),e.pushCode("switch({0}) {",t),Object.keys(this.options.choices).forEach((function(t){var r=this.options.choices[t];Number.isNaN(parseInt(t,10))?e.pushCode("case '{0}':",t):e.pushCode("case {0}:",t),this.generateChoiceCase(e,this.varName,r),e.pushCode("break;")}),this),e.pushCode("default:"),this.options.defaultChoice?this.generateChoiceCase(e,this.varName,this.options.defaultChoice):e.generateError('"Met undefined tag value " + {0} + " at choice"',t),e.pushCode("}")},h.prototype.generateNest=function(e){var t=e.generateVariable(this.varName);if(this.options.type instanceof h)this.varName&&e.pushCode("{0} = {};",t),e.pushPath(this.varName),this.options.type.generate(e),e.popPath(this.varName);else if(l[this.options.type]){var r=e.generateTmpVariable();e.pushCode("var {0} = {1}(offset);",r,u+this.options.type),e.pushCode("{0} = {1}.result; offset = {1}.offset;",t,r),this.options.type!==this.alias&&e.addReference(this.options.type)}},h.prototype.generateFormatter=function(e,t,r){"function"==typeof r&&e.pushCode("{0} = ({1}).call(this, {0});",t,r)},h.prototype.isInteger=function(){return!!this.type.match(/U?Int[8|16|32][BE|LE]?|Bit\d+/)},h.prototype.itf8=function(e,t){return this.setNextParser("itf8",e,t)},h.prototype.itf8=function(e,t){return this.setNextParser("itf8",e,t)},h.prototype.generateItf8=function(e){var t=e.generateVariable(this.varName),r=e.generateTmpVariable();e.pushCode("\n var ".concat(r," = buffer[offset];\n if (").concat(r," < 0x80) {\n ").concat(t," = ").concat(r,";\n offset += 1;\n } else if (").concat(r," < 0xc0) {\n ").concat(t," = ((").concat(r,"<<8) | buffer[offset+1]) & 0x3fff;\n offset += 2;\n } else if (").concat(r," < 0xe0) {\n ").concat(t," = ((").concat(r,"<<16) | (buffer[offset+1]<< 8) | buffer[offset+2]) & 0x1fffff;\n offset += 3;\n } else if (").concat(r," < 0xf0) {\n ").concat(t," = ((").concat(r,"<<24) | (buffer[offset+1]<<16) | (buffer[offset+2]<<8) | buffer[offset+3]) & 0x0fffffff;\n offset += 4\n } else {\n ").concat(t," = ((").concat(r," & 0x0f)<<28) | (buffer[offset+1]<<20) | (buffer[offset+2]<<12) | (buffer[offset+3]<<4) | (buffer[offset+4] & 0x0f);\n // x=((0xff & 0x0f)<<28) | (0xff<<20) | (0xff<<12) | (0xff<<4) | (0x0f & 0x0f);\n // TODO *val_p = uv < 0x80000000UL ? uv : -((int32_t) (0xffffffffUL - uv)) - 1;\n offset += 5\n }\n "))},h.prototype.ltf8=function(e,t){return this.setNextParser("ltf8",e,t)},h.prototype.generateLtf8=function(e){var t=e.generateVariable(this.varName),r=e.generateTmpVariable();e.pushCode("\n var ".concat(r," = buffer[offset];\n if (").concat(r," < 0x80) {\n ").concat(t," = ").concat(r,";\n offset += 1;\n } else if (").concat(r," < 0xc0) {\n ").concat(t," = ((buffer[offset]<<8) | buffer[offset+1]) & 0x3fff;\n offset += 2;\n } else if (").concat(r," < 0xe0) {\n ").concat(t," = ((buffer[offset]<<16) | (buffer[offset+1]<<8) | buffer[offset+2]) & 0x1fffff;\n ").concat(t," = (((").concat(r," & 63) << 16) | buffer.readUInt16LE(offset + 1));\n offset += 3;\n } else if (").concat(r," < 0xf0) {\n ").concat(t," = ((buffer[offset]<<24) | (buffer[offset+1]<<16) | (buffer[offset+2]<<8) | buffer[offset+3]) & 0x0fffffff;\n offset += 4;\n } else if (").concat(r," < 0xf8) {\n ").concat(t," = (((buffer[offset] & 15) * Math.pow(2,32))) +\n (buffer[offset+1]<<24) | (buffer[offset+2]<<16 | buffer[offset+3]<<8 | buffer[offset+4])\n // TODO *val_p = uv < 0x80000000UL ? uv : -((int32_t) (0xffffffffUL - uv)) - 1;\n offset += 5;\n } else if (").concat(r," < 0xfc) {\n ").concat(t," = ((((buffer[offset] & 7) << 8) | buffer[offset+1] )) * Math.pow(2,32) +\n (buffer[offset+2]<<24) | (buffer[offset+3]<<16 | buffer[offset+4]<<8 | buffer[offset+5])\n offset += 6;\n } else if (").concat(r," < 0xfe) {\n ").concat(t," = ((((buffer[offset] & 3) << 16) | buffer[offset+1]<<8 | buffer[offset+2])) * Math.pow(2,32) +\n (buffer[offset+3]<<24) | (buffer[offset+4]<<16 | buffer[offset+5]<<8 | buffer[offset+6])\n offset += 7;\n } else if (").concat(r," < 0xff) {\n ").concat(t," = Long.fromBytesBE(buffer.slice(offset+1,offset+8));\n if (").concat(t,".greaterThan(Number.MAX_SAFE_INTEGER) || ").concat(t,".lessThan(Number.MIN_SAFE_INTEGER))\n throw new Error('integer overflow')\n ").concat(t," = ").concat(t,".toNumber()\n offset += 8;\n } else {\n ").concat(t," = Long.fromBytesBE(buffer.slice(offset+1,offset+9));\n if (").concat(t,".greaterThan(Number.MAX_SAFE_INTEGER) || ").concat(t,".lessThan(Number.MIN_SAFE_INTEGER))\n throw new Error('integer overflow')\n ").concat(t," = ").concat(t,".toNumber()\n offset += 9;\n }\n "))},t.Parser=h},2838:(e,t)=>{"use strict";function r(e){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r(e)}var n=function(){this.code="",this.scopes=[["vars"]],this.isAsync=!1,this.bitFields=[],this.tmpVariableCount=0,this.references={}};n.prototype.generateVariable=function(e){var t=[];for(Array.prototype.push.apply(t,this.scopes[this.scopes.length-1]);/^\$parent\./.test(e);)t.pop(),e=e.replace(/^\$parent\./,"");return e&&t.push(e),t.join(".")},n.prototype.generateOption=function(e){switch(r(e)){case"number":return e.toString();case"string":return this.generateVariable(e);case"function":return"(".concat(e,").call(").concat(this.generateVariable(),", vars)");default:return}},n.prototype.generateError=function(){var e=Array.prototype.slice.call(arguments),t=n.interpolate.apply(this,e);this.isAsync?this.pushCode("return process.nextTick(function() { callback(new Error(".concat(t,"), vars); });")):this.pushCode("throw new Error(".concat(t,");"))},n.prototype.generateTmpVariable=function(){return"$tmp".concat(this.tmpVariableCount++)},n.prototype.pushCode=function(){var e=Array.prototype.slice.call(arguments);this.code+="".concat(n.interpolate.apply(this,e),"\n")},n.prototype.pushPath=function(e){e&&this.scopes[this.scopes.length-1].push(e)},n.prototype.popPath=function(e){e&&this.scopes[this.scopes.length-1].pop()},n.prototype.pushScope=function(e){this.scopes.push([e])},n.prototype.popScope=function(){this.scopes.pop()},n.prototype.addReference=function(e){this.references[e]||(this.references[e]={resolved:!1,requested:!1})},n.prototype.markResolved=function(e){this.references[e].resolved=!0},n.prototype.markRequested=function(e){e.forEach(function(e){this.references[e].requested=!0}.bind(this))},n.prototype.getUnresolvedReferences=function(){var e=this.references;return Object.keys(this.references).filter((function(t){return!e[t].resolved&&!e[t].requested}))},n.interpolate=function(e){var t=e.match(/{\d+}/g),r=Array.prototype.slice.call(arguments,1);return t&&t.forEach((function(t){var n=parseInt(t.substr(1,t.length-2),10);e=e.replace(t,r[n].toString())})),e},t.o=n},3738:e=>{e.exports.runInThisContext=function(e){return new Function("code","return eval(code);").call(globalThis,e)}},635:(e,t,r)=>{const n=r(4646),o=r(8706),i=r(9614),a=r(235),s=128;e.exports=class{decode(e){return this.stream=new o(e),this.decodeStream(this.stream)}decodeStream(e,t=0){var r=this.stream.ReadByte();16&r||(t=this.stream.ReadUint7());var n,o=t,i=1&r;if(8&r)return this.decodeStripe(this.stream,t);if(r&s&&([n,o]=this.decodePackMeta(this.stream)),32&r)var a=this.decodeCat(this.stream,o);else a=4&r?this.decodeExt(this.stream,o):64&r?i?this.decodeRLE1(this.stream,o):this.decodeRLE0(this.stream,o):i?this.decode1(this.stream,o):this.decode0(this.stream,o);return r&s&&(a=this.decodePack(a,n,t)),a}encode(e,t){if(this.stream=new o("",0,1.1*e.length+100),this.stream.WriteByte(t),16&t||this.stream.WriteUint7(e.length),8&t)return Buffer.concat([this.stream.buf.slice(0,this.stream.pos),this.encodeStripe(this.stream,e,t>>8)]);var r,n=1&t,i=e.length;return t&s&&([r,e,i]=this.encodePack(e)),t&s&&this.stream.WriteStream(r),64&t?n?this.encodeRLE1(e,i,this.stream):this.encodeRLE0(e,i,this.stream):n?this.encode1(e,i,this.stream):this.encode0(e,i,this.stream)}decode0(e,t){var r=new Buffer.allocUnsafe(t),o=e.ReadByte();0==o&&(o=256);var a=new i(o),s=new n(e);s.RangeStartDecode(e);for(var f=0;f<t;f++)r[f]=a.ModelDecode(e,s);return r}encode0(e,t,r){for(var o=0,a=0;a<t;a++)o<e[a]&&(o=e[a]);o++;var s=new i(o);r.WriteByte(o);var f=new n(r);for(a=0;a<t;a++)s.ModelEncode(r,f,e[a]);return f.RangeFinishEncode(r),r.buf.slice(0,r.pos)}decode1(e,t){var r=new Buffer.allocUnsafe(t),o=e.ReadByte();0==o&&(o=256);for(var a=new Array(o),s=0;s<o;s++)a[s]=new i(o);var f=new n(e);f.RangeStartDecode(e);var l=0;for(s=0;s<t;s++)r[s]=a[l].ModelDecode(e,f),l=r[s];return r}encode1(e,t,r){for(var o=0,a=0;a<t;a++)o<e[a]&&(o=e[a]);o++;var s=new Array(o);for(a=0;a<o;a++)s[a]=new i(o);r.WriteByte(o);var f=new n(r),l=0;for(a=0;a<t;a++)s[l].ModelEncode(r,f,e[a]),l=e[a];return f.RangeFinishEncode(r),r.buf.slice(0,r.pos)}decodeExt(e,t){var r=new Buffer.allocUnsafe(t),n=a.array(e.buf.slice(e.pos)),o=a.header(n),i=0;do{var s=a.decompress(n,o);-1!=s&&(Buffer.from(s).copy(r,i),i+=s.length,o-=s.length)}while(-1!=s);return r}encodeExt(e,t){}decodeRLE0(e,t){var r=new Buffer.allocUnsafe(t),o=e.ReadByte();0==o&&(o=256);for(var a=new i(o),s=new Array(258),f=0;f<=257;f++)s[f]=new i(4);var l=new n(e);for(l.RangeStartDecode(e),f=0;f<t;){r[f]=a.ModelDecode(e,l);for(var u=s[r[f]].ModelDecode(e,l),c=u,A=256;3==u;)u=s[A].ModelDecode(e,l),A=257,c+=u;for(var h=1;h<=c;h++)r[f+h]=r[f];f+=c+1}return r}encodeRLE0(e,t,r){for(var o=0,a=0;a<t;a++)o<e[a]&&(o=e[a]);o++;var s=new i(o),f=new Array(258);for(a=0;a<=257;a++)f[a]=new i(4);r.WriteByte(o);var l=new n(r);for(a=0;a<t;){s.ModelEncode(r,l,e[a]);for(var u=1;a+u<t&&e[a+u]==e[a];)u++;u--;var c=e[a];e[a],a+=u+1;var A=u>=3?3:u;for(f[c].ModelEncode(r,l,A),u-=A,c=256;3==A;)A=u>=3?3:u,f[c].ModelEncode(r,l,A),c=257,u-=A}return l.RangeFinishEncode(r),r.buf.slice(0,r.pos)}decodeRLE1(e,t){var r=new Buffer.allocUnsafe(t),o=e.ReadByte();0==o&&(o=256);for(var a=new Array(o),s=0;s<o;s++)a[s]=new i(o);var f=new Array(258);for(s=0;s<=257;s++)f[s]=new i(4);var l=new n(e);l.RangeStartDecode(e);var u=0;for(s=0;s<t;){r[s]=a[u].ModelDecode(e,l),u=r[s];for(var c=f[r[s]].ModelDecode(e,l),A=c,h=256;3==c;)c=f[h].ModelDecode(e,l),h=257,A+=c;for(var d=1;d<=A;d++)r[s+d]=r[s];s+=A+1}return r}encodeRLE1(e,t,r){for(var o=0,a=0;a<t;a++)o<e[a]&&(o=e[a]);o++;var s=new Array(o);for(a=0;a<o;a++)s[a]=new i(o);var f=new Array(258);for(a=0;a<=257;a++)f[a]=new i(4);r.WriteByte(o);for(var l=new n(r),u=(a=0,0);a<t;){s[u].ModelEncode(r,l,e[a]);for(var c=1;a+c<t&&e[a+c]==e[a];)c++;c--;var A=e[a];u=e[a],a+=c+1;var h=c>=3?3:c;for(f[A].ModelEncode(r,l,h),c-=h,A=256;3==h;)h=c>=3?3:c,f[A].ModelEncode(r,l,h),A=257,c-=h}return l.RangeFinishEncode(r),r.buf.slice(0,r.pos)}decodePackMeta(e){this.nsym=e.ReadByte();for(var t=new Array(this.nsym),r=0;r<this.nsym;r++)t[r]=e.ReadByte();return[t,e.ReadUint7()]}decodePack(e,t,r){var n=new Buffer.allocUnsafe(r);if(this.nsym<=1)for(var o=0;o<r;o++)n[o]=t[0];else if(this.nsym<=2){o=0;for(var i=0;o<r;o++){if(o%8==0)var a=e[i++];n[o]=t[1&a],a>>=1}}else if(this.nsym<=4)for(o=0,i=0;o<r;o++)o%4==0&&(a=e[i++]),n[o]=t[3&a],a>>=2;else{if(!(this.nsym<=16))return e;for(o=0,i=0;o<r;o++)o%2==0&&(a=e[i++]),n[o]=t[15&a],a>>=4}return n}packMeta(e){for(var t=new o("",0,1024),r=new Array(256),n=0;n<e.length;n++)r[e[n]]=1;var i=0;for(n=0;n<256;n++)r[n]&&(r[n]=++i);for(t.WriteByte(i),n=0;n<256;n++)r[n]&&(t.WriteByte(n),r[n]--);return[t,r,i]}encodePack(e){var t,r,n;[t,r,n]=this.packMeta(e);var o=e.length,i=0;if(n<=1)return t.WriteUint7(0),[t,new Buffer.allocUnsafe(0),0];if(n<=2){for(var a=new Buffer.allocUnsafe(Math.floor((o+7)/8)),s=(i=0,0);i<(-8&o);i+=8,s++)a[s]=(r[e[i+0]]<<0)+(r[e[i+1]]<<1)+(r[e[i+2]]<<2)+(r[e[i+3]]<<3)+(r[e[i+4]]<<4)+(r[e[i+5]]<<5)+(r[e[i+6]]<<6)+(r[e[i+7]]<<7);if(i<o){a[s]=0;for(var f=0;i<o;)a[s]|=r[e[i++]]<<f,f++;s++}return t.WriteUint7(s),[t,a,a.length]}if(n<=4){for(a=new Buffer.allocUnsafe(Math.floor((o+3)/4)),i=0,s=0;i<(-4&o);i+=4,s++)a[s]=(r[e[i+0]]<<0)+(r[e[i+1]]<<2)+(r[e[i+2]]<<4)+(r[e[i+3]]<<6);if(i<o){for(a[s]=0,f=0;i<o;)a[s]|=r[e[i++]]<<f,f+=2;s++}return t.WriteUint7(s),[t,a,a.length]}if(n<=16){for(a=new Buffer.allocUnsafe(Math.floor((o+1)/2)),i=0,s=0;i<(-2&o);i+=2,s++)a[s]=(r[e[i+0]]<<0)+(r[e[i+1]]<<4);return i<o&&(a[s++]=r[e[i++]]),t.WriteUint7(s),[t,a,a.length]}return t.WriteUint7(e.length),[t,e,e.length]}encodeStripe(e,t,r){0==r&&(r=4);for(var n=new Array(r),i=new Array(r),a=0;a<r;a++)i[a]=Math.floor(t.length/r)+(t.length%r>a),n[a]=new Array(i[a]);for(var s=0,f=0;f<t.length;f+=r,s++)for(var l=0;l<r;l++)s<n[l].length&&(n[l][s]=t[f+l]);var u=new Array(r),c=0;for(a=0;a<r;a++){var A=this.encode(n[a],0),h=this.encode(n[a],1);u[a]=h.length<A.length?h:A,c+=u[a].length}var d=new o("",0,c+5*r+1);for(d.WriteByte(r),a=0;a<r;a++)d.WriteUint7(u[a].length);for(a=0;a<r;a++)d.WriteData(u[a],u[a].length);return d.buf.slice(0,d.buf.pos)}decodeStripe(e,t){for(var r=e.ReadByte(),n=new Array(r),o=new Array(r),i=0;i<r;i++)n[i]=e.ReadUint7();var a=new Array(r);for(i=0;i<r;i++)o[i]=Math.floor(t/r)+(t%r>i),a[i]=this.decodeStream(e,o[i]);var s=new Buffer.allocUnsafe(t);for(i=0;i<r;i++)for(var f=0;f<o[i];f++)s[f*r+i]=a[i][f];return s}decodeCat(e,t){for(var r=new Buffer.allocUnsafe(t),n=0;n<t;n++)r[n]=e.ReadByte();return r}}},4646:e=>{e.exports=class{constructor(e){this.low=0,this.range=4294967295,this.code=0,this.FFnum=0,this.carry=0,this.cache=0}RangeStartDecode(e){for(var t=0;t<5;t++)this.code=(this.code<<8)+e.ReadByte();this.code&=4294967295,this.code>>>=0}RangeGetFrequency(e){return this.range=Math.floor(this.range/e),Math.floor(this.code/this.range)}RangeDecode(e,t,r,n){for(this.code-=t*this.range,this.range*=r;this.range<1<<24;)this.range*=256,this.code=256*this.code+e.ReadByte()}RangeShiftLow(e){if(this.low<4278190080|this.carry){for(e.WriteByte(this.cache+this.carry);this.FFnum;)e.WriteByte(this.carry-1),this.FFnum--;this.cache=this.low>>>24,this.carry=0}else this.FFnum++;this.low<<=8,this.low>>>=0}RangeEncode(e,t,r,n){var o=this.low;for(this.range=Math.floor(this.range/n),this.low+=t*this.range,this.low>>>=0,this.range*=r,this.low<o&&(0!=this.carry&&console.log("ERROR: Multiple carry"),this.carry=1);this.range<1<<24;)this.range*=256,this.RangeShiftLow(e)}RangeFinishEncode(e){for(var t=0;t<5;t++)this.RangeShiftLow(e)}}},9614:e=>{e.exports=class{constructor(e=256){this.total_freq=e,this.max_sym=e-1,this.S=new Array,this.F=new Array;for(var t=0;t<=this.max_sym;t++)this.S[t]=t,this.F[t]=1}ModelDecode(e,t){for(var r=t.RangeGetFrequency(this.total_freq),n=0,o=0;n+this.F[o]<=r;)n+=this.F[o++];t.RangeDecode(e,n,this.F[o],this.total_freq),this.F[o]+=16,this.total_freq+=16,this.total_freq>65519&&this.ModelRenormalise();var i=this.S[o];if(o>0&&this.F[o]>this.F[o-1]){var a=this.F[o];this.F[o]=this.F[o-1],this.F[o-1]=a,a=this.S[o],this.S[o]=this.S[o-1],this.S[o-1]=a}return i}ModelRenormalise(){this.total_freq=0;for(var e=0;e<=this.max_sym;e++)this.F[e]-=Math.floor(this.F[e]/2),this.total_freq+=this.F[e]}ModelEncode(e,t,r){for(var n=0,o=0;this.S[o]!=r;o++)n+=this.F[o];if(t.RangeEncode(e,n,this.F[o],this.total_freq),this.F[o]+=16,this.total_freq+=16,this.total_freq>65519&&this.ModelRenormalise(),r=this.S[o],o>0&&this.F[o]>this.F[o-1]){var i=this.F[o];this.F[o]=this.F[o-1],this.F[o-1]=i,i=this.S[o],this.S[o]=this.S[o-1],this.S[o-1]=i}}}},6038:(e,t,r)=>{const n=r(8706),o=r(9614),i=r(4646);function a(e,t,r){for(var n=0,o=0,i=-1,a=new Array(1024);o<r;){var s=e.ReadByte();if(a[n++]=s,o+=s,s==i){var f=e.ReadByte();for(o+=s*f;f--;)a[n++]=s}i=s}var l=0;for(n=0,o=0;o<r;){var u=0;do{var c=a[n++];u+=c}while(255==c);for(;u--;)t[o++]=l;l++}}const s=2,f=4,l=8,u=16,c=32,A=64,h=128;function d(e,t,r){var n=e.context;return t.qctx=(t.qctx<<e.qshift)+e.qtab[r],n+=(t.qctx&(1<<e.qbits)-1)<<e.qloc,e.do_pos&&(n+=e.ptab[Math.min(t.p,1023)]<<e.ploc),e.do_delta&&(n+=e.dtab[Math.min(t.delta,255)]<<e.dloc,t.delta+=t.prevq!=r?1:0,t.prevq=r),e.do_sel&&(n+=t.s<<e.sloc),t.p--,65535&n}function g(e){var t={};t.context=e.ReadUint16(),t.pflags=e.ReadByte(),t.do_dedup=t.pflags&s,t.fixed_len=t.pflags&f,t.do_sel=t.pflags&l,t.do_qmap=t.pflags&u,t.do_pos=t.pflags&c,t.do_delta=t.pflags&A,t.do_qtab=t.pflags&h,t.max_sym=e.ReadByte();var r=e.ReadByte();if(t.qbits=r>>4,t.qshift=15&r,r=e.ReadByte(),t.qloc=r>>4,t.sloc=15&r,r=e.ReadByte(),t.ploc=r>>4,t.dloc=15&r,t.qmap=new Array(256),t.pflags&u)for(var n=0;n<t.max_sym;n++)t.qmap[n]=e.ReadByte();else for(n=0;n<256;n++)t.qmap[n]=n;if(t.qtab=new Array(1024),t.qbits>0&&t.pflags&h)a(e,t.qtab,256);else for(n=0;n<256;n++)t.qtab[n]=n;return t.ptab=new Array(1024),t.pflags&c&&a(e,t.ptab,1024),t.dtab=new Array(256),t.pflags&A&&a(e,t.dtab,256),t}function p(e,t,r,n,o,i){r.max_sel>0?o.s=n.sel.ModelDecode(e,t):o.s=0,o.x=r.stab[o.s];var a=r.params[o.x];if(a.fixed_len>=0){var f=n.len[0].ModelDecode(e,t);f|=n.len[1].ModelDecode(e,t)<<8,f|=n.len[2].ModelDecode(e,t)<<16,f|=n.len[3].ModelDecode(e,t)<<24,a.fixed_len>0&&(a.fixed_len=-f)}else f=-a.fixed_len;o.len=f,r.do_rev&&(i[o.rec]=n.rev.ModelDecode(e,t)),o.is_dup=0,a.pflags&s&&n.dup.ModelDecode(e,t)&&(o.is_dup=1),o.p=f,o.delta=0,o.qctx=0,o.prevq=0,o.rec++}function y(e,t,r){for(var n=0,o=0,i=new Array(2*r),a=0;n<r;){for(var s=n;n<r&&t[n]==o;)n++;var f=n-s;do{var l=Math.min(255,f);i[a++]=l,f-=l}while(255==l);o++}var u=-1,c=new Array(2*r),A=0;for(n=0;n<a;){var h=i[n++];if(c[A++]=h,h==u){for(s=n;n<a&&i[n]==u&&n-s<255;)n++;c[A++]=n-s}else u=h}e.WriteData(c,A)}e.exports={decode:function(e,t){return function(e,t){var r=e.ReadUint7(),n=function(e){var t={max_sym:0};if(5==e.ReadByte()){var r=e.ReadByte(),n=1&r?e.ReadByte():1,o=r.nparam>1?r.nparam-1:0,i=new Array(256);if(2&r)o=e.ReadByte(),a(e,i,256);else{for(var s=0;s<n;s++)i[s]=s;for(;s<256;s++)i[s]=n-1}t.do_rev=4&r,t.stab=i,t.max_sel=o,t.params=new Array(t.nparam);for(var f=0;f<n;f++)t.params[f]=g(e),t.max_sym<t.params[f].max_sym&&(t.max_sym=t.params[f].max_sym);return t}console.error("Invalid FQZComp version number")}(e);if(n){var s=n.params,f=new Array(t.length),l=function(e){var t={};t.qual=new Array(65536);for(var r=0;r<65536;r++)t.qual[r]=new o(e.max_sym+1);for(t.len=new Array(4),r=0;r<4;r++)t.len[r]=new o(256);return t.rev=new o(2),t.dup=new o(2),e.max_sel>0&&(t.sel=new o(e.max_sel+1)),t}(n),u=new i(e);u.RangeStartDecode(e);for(var c=new Buffer.allocUnsafe(r),A={qctx:0,prevq:0,delta:0,p:0,s:0,x:0,len:0,is_dup:0,rec:0},h=0;h<r;){if(0==A.p){if(p(e,u,n,l,A,f),A.is_dup>0&&l.dup.ModelDecode(e,u)){for(var y=0;y<len;y++)c[h+y]=c[h+y-A.len];h+=A.len,A.p=0;continue}t.push(A.len);var m=(s=n.params[A.x]).context}var C=l.qual[m].ModelDecode(e,u);c[h++]=s.qmap[C],m=d(s,A,C)}return n.do_rev&&function(e,t,r,n){for(var o=0,i=0;i<t;){if(r[o])for(var a=0,s=n[o]-1;a<s;){var f=e[i+a];e[i+a]=e[i+s],e[i+s]=f,a++,s--}i+=n[o++]}}(c,r,f,t),c}}(new n(e),t)},encode:function(e,t,r){for(var a=new Array(2),d=new Array(2),g=new Array(2),p=new Array(2),m=new Array(256),C=0;C<2;C++)a[C]=new Array(256),d[C]=new Array(256),g[C]=new Array(1024),p[C]=new Array(256);(b=new n("",0,1.1*e.length+100)).WriteUint7(e.length);var I=function(e,t,r,n){for(var o=r[0],i=0;i<r.length&&r[i]==o;i++);var a=i==r.length?1:0,s=0,f=0;for(i=0;i<256;i++)n[0][i]=0;var l=0,u=0;for(i=0;i<e.length;i++)0==u&&(u=t[l<t.length-1?l++:l]),n[0][e[i]]++,u--;for(i=0;i<256;i++)n[0][i]&&(f<i&&(f=i),s++);var c=5,A=0;return s<=16&&(A=1,c=s<=2?1:s<=4?2:s<=8?3:4),[{qbits:8+(c>4),qshift:c,qloc:7,pbits:7,pshift:t[0]>128?1:0,ploc:0,dbits:c>4?0:1,dshift:3,dloc:15,sbits:0,sloc:15,do_stab:0,context:0,max_sym:f,nsym:s,do_qmap:A,do_dedup:0,fixed_len:1==t.length?1:0,do_sel:0,do_rev:0,do_pos:1,do_delta:c<=4?1:0,do_qtab:0,qbits:8+(c>4)-(0==a),sbits:1,sloc:15-(c<=4),do_stab:1,do_sel:1}]}(e,t,r,a),b=function(e,t,r,n,o,i,a){for(var d=[0,1,1,1,2,2,2,2,2,3,3,3,3,3,3,3,4,4,4,4,4,4,4,4,4,5,5,5,5,5,5,5,5,5,5,5,6,6,6,6,6,6,6,6,6,6,6,6,6,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7],g=0;g<t.length;g++)a[g]=g;for(;g<256;g++)a[g]=t.length-1;e.WriteByte(5);var p=(t.length>1?1:0)|(t[0].do_stab?2:0);if(e.WriteByte(p),1&p&&e.WriteByte(t.length),2&p){var m=1<<t[0].sbits;m>0&&m--,e.WriteByte(m),y(e,a,256)}for(var C=0;C<t.length;C++){if(e.WriteUint16(t[C].context),e.WriteByte((t[C].do_qtab?h:0)|(t[C].do_delta?A:0)|(t[C].do_pos?c:0)|(t[C].do_qmap?u:0)|(t[C].do_sel?l:0)|(t[C].fixed_len?f:0)|(t[C].do_dedup?s:0)),t[C].do_qmap?e.WriteByte(t[C].nsym):e.WriteByte(t[C].max_sym),e.WriteByte(t[C].qbits<<4|t[C].qshift),e.WriteByte(t[C].qloc<<4|t[C].sloc),e.WriteByte(t[C].ploc<<4|t[C].dloc),t[C].do_qmap){t[C].max_sym=t[C].nsym;var I=0;for(g=0;g<256;g++)r[C][g]&&(e.WriteByte(g),r[C][g]=I++);for(;I<t[C].nsym;I++)e.WriteByte(0)}else for(g=0;g<256;g++)r[C][g]=g;if(t[C].qbits>0){for(g=0;g<256;g++)n[C][g]=g;t[C].do_qtab&&y(e,n[C],256)}if(t[C].pbits>0){for(g=0;g<1024;g++)o[C][g]=Math.min((1<<t[C].pbits)-1,g>>t[C].pshift);y(e,o[C],1024)}if(t[C].dbits>0){for(g=0;g<256;g++)d[g]>(1<<t[C].dbits)-1&&(d[g]=(1<<t[C].dbits)-1);for(g=0;g<256;g++)i[C][g]=d[Math.min(d.length-1,g>>t[C].dshift)];y(e,i[C],256)}}return e}(b,I,a,d,g,p,m);return function(e,t,r,n,a,s,f,l,u,c){var A=1<<a[0].sbits;A>0&&A--;for(var h=t.length,d=0,g=0;g<a.length;g++)d<a[g].max_sym&&(d=a[g].max_sym);for(var p=new Array(65536),y=0;y<65536;y++)p[y]=new o(d+1);var m=new Array(4);for(y=0;y<4;y++)m[y]=new o(256);new o(2),new o(2);for(var C=new o(A+1),I=new i(t),b=(g=0,y=0,0);y<h;){if(0==g){var w=n[b];a[0].sbits>0&&C.ModelEncode(e,I,w);var v=c[w],B=r[Math.min(r.length-1,b++)];a[v].fixed_len?a[v].fixed_len>0&&(m[0].ModelEncode(e,I,255&B),m[1].ModelEncode(e,I,B>>8&255),m[2].ModelEncode(e,I,B>>16&255),m[3].ModelEncode(e,I,B>>24&255),a[v].fixed_len=-1):(m[0].ModelEncode(e,I,255&B),m[1].ModelEncode(e,I,B>>8&255),m[2].ModelEncode(e,I,B>>16&255),m[3].ModelEncode(e,I,B>>24&255)),a[v].do_dedup&&process.exit(1),g=B;var E=0,_=a[v].context,Q=0,S=0}var k=t[y++],R=s[v][k];p[_].ModelEncode(e,I,R),Q=(Q<<a[v].qshift)+f[v][R],_=a[v].context,_+=(Q&(1<<a[v].qbits)-1)<<a[v].qloc,a[v].pbits>0&&(_+=l[v][Math.min(g,1023)]<<a[v].ploc),a[v].dbits>0&&(_+=u[v][Math.min(E,255)]<<a[v].dloc,E+=S!=R?1:0,S=R),a[v].do_sel&&(_+=w<<a[v].sloc),_&=65535,g--}return I.RangeFinishEncode(e),e.buf.slice(0,e.pos)}(b,e,t,r,I,a,d,g,p,m)}}},6960:(e,t,r)=>{"use strict";var n=r(5460),o=r(8223),i=r(635),a=r(6038),s=r(5997);e.exports={r4x8_uncompress:function(e,t){n.decode(e).copy(t,0,0)},r4x16_uncompress:function(e,t){o.decode(e).copy(t,0,0)},arith_uncompress:function(e,t){i.decode(e).copy(t,0,0)},fqzcomp_uncompress:function(e,t){var r=new Array;a.decode(e,r).copy(t,0,0)},tok3_uncompress:function(e,t){var r=s.decode(e,0,"\0");Buffer.from(r,"binary").copy(t,0,0)}}},8706:e=>{e.exports=class{constructor(e,t=0,r=0){0!=r?(this.buf=Buffer.allocUnsafe(r),this.length=r):(this.buf=e,this.length=e.length),this.pos=t}EOF(){return this.pos>=this.length}ReadData(e){var t=this.buf.slice(this.pos,this.pos+e);return this.pos+=e,t}ReadByte(){const e=this.buf[this.pos];return this.pos++,e}ReadChar(){const e=this.buf[this.pos];return this.pos++,String.fromCharCode(e)}ReadUint16(){return this.ReadByte()|this.ReadByte()<<8}ReadUint32(){const e=this.buf.readInt32LE(this.pos);return this.pos+=4,e}ReadString(){var e="";do{var t=this.buf[this.pos++];t&&(e+=String.fromCharCode(t))}while(t);return e}ReadUint7(){var e=0;do{var t=this.ReadByte();e=e<<7|127&t}while(128&t);return e}ReadITF8(){var e=this.buf[this.pos];return this.pos++,e>=240?(e=(15&e)<<28,e+=(this.buf[this.pos+0]<<20)+(this.buf[this.pos+1]<<12)+(this.buf[this.pos+2]<<4)+(this.buf[this.pos+3]>>4),this.pos+=4):e>=224?(e=(15&e)<<24,e+=(this.buf[this.pos+0]<<16)+(this.buf[this.pos+1]<<8)+(this.buf[this.pos+2]<<0),this.pos+=3):e>=192?(e=(31&e)<<16,e+=(this.buf[this.pos+0]<<8)+(this.buf[this.pos+1]<<0),this.pos+=2):e>=128&&(e=(63&e)<<8,e+=this.buf[this.pos],this.pos++),e}WriteByte(e){this.buf[this.pos++]=e}WriteChar(e){this.buf[this.pos++]=e.charCodeAt(0)}WriteString(e){for(var t=0;t<e.length;t++)this.buf[this.pos++]=e.charCodeAt(t);this.buf[this.pos++]=0}WriteData(e,t){for(var r=0;r<t;r++)this.buf[this.pos++]=e[r]}WriteStream(e){this.WriteData(e.buf,e.pos)}WriteUint16(e){this.WriteByte(255&e),this.WriteByte(e>>8&255)}WriteUint32(e){this.buf.writeInt32LE(e,this.pos),this.pos+=4}WriteUint7(e){var t=0,r=e;do{t+=7,r>>=7}while(r>0);do{t-=7,this.WriteByte((e>>t&127)+((t>0)<<7))}while(t>0)}WriteITF8(e){e<0&&(e=1+e),e<=127?this.buf[this.pos++]=e:e<=16383?(this.buf[this.pos++]=128|Math.floor(e/256),this.buf[this.pos++]=255&e):e<131071?(this.buf[this.pos++]=192|Math.floor(e/65536),this.buf[this.pos++]=255&Math.floor(e/256),this.buf[this.pos++]=255&e):e<268435455?(this.buf[this.pos++]=224|Math.floor(e/16777216),this.buf[this.pos++]=255&Math.floor(e/65536),this.buf[this.pos++]=255&Math.floor(e/256),this.buf[this.pos++]=255&e):(this.buf[this.pos++]=240|Math.floor(e/268435456),this.buf[this.pos++]=255&Math.floor(e/1048576),this.buf[this.pos++]=255&Math.floor(e/4096),this.buf[this.pos++]=255&Math.floor(e/4),this.buf[this.pos++]=15&e)}WriteByteNeg(e){this.buf[--this.pos]=e}}},5460:(e,t,r)=>{const n=r(8706);function o(e){return 4095&e}function i(e,t){for(var r=0;t>=e[r+1];)r++;return r}function a(e){for(var t=new Array(4096),r=0,n=0;n<4096;n++){for(;n>=e[r+1];)r++;t[n]=r}return t}function s(e,t,r){return r*(e>>12)+(4095&e)-t}function f(e,t){for(;t<1<<23;)t=(t<<8)+e.ReadByte();return t}function l(e,t){t.WriteByteNeg(e>>24&255),t.WriteByteNeg(e>>16&255),t.WriteByteNeg(e>>8&255),t.WriteByteNeg(e>>0&255)}function u(e,t,r,n,o){return e=function(e,t,r,n){for(var o=(1<<23>>n<<8)*r;e>=o;)t.WriteByteNeg(255&e),e>>=8;return e}(e,t,n,o),(Math.floor(e/n)<<o)+e%n+r}function c(e,t,r){for(var n=0;n<256;n++)t[n]=0;var o=e.ReadByte(),i=o,a=0;do{var s=e.ReadITF8();t[o]=s,a>0?(a--,o++):(o=e.ReadByte())==i+1&&(a=e.ReadByte()),i=o}while(0!=o);for(r[0]=0,n=0;n<=255;n++)r[n+1]=r[n]+t[n]}function A(e){for(var t=0,r=0;r<256;r++)t+=e[r];const n=4096;var o=n/t;do{var i=0,a=0,s=0;for(t=0,r=0;r<256;r++)0!=e[r]&&(i<e[r]&&(i=e[r],a=r),e[r]=Math.floor(e[r]*o),0==e[r]&&(e[r]=1),t+=e[r]);t<n?e[a]+=n-t:t-n<e[a]/2&&e[a]>2?e[a]-=t-n:t!=n&&(o*=.99,s=1)}while(s)}function h(e,t){for(var r=0,n=0;n<256;n++)if(t[n]){if(r>0)r--;else if(e.WriteByte(n),n>0&&t[n-1]>0){for(r=n+1;r<256&&t[r];r++);r-=n+1,e.WriteByte(r)}e.WriteITF8(t[n])}e.WriteByte(0)}e.exports={decode:function(e){var t=new n(e),r=t.ReadByte(),l=(t.ReadUint32(),t.ReadUint32());return 0==r?function(e,t){var r=new Array(256),n=new Array(256);c(e,r,n);for(var i=a(n),l=new Array(4),u=0;u<4;u++)l[u]=e.ReadUint32();var A=new Buffer.allocUnsafe(t);for(u=0;u<t;u++){var h=u%4,d=i[o(l[h])];A[u]=d,l[h]=s(l[h],n[d],r[d]),l[h]=f(e,l[h])}return A}(t,l):function(e,t){var r=new Array(256),n=new Array(256);!function(e,t,r){for(var n=0;n<256;n++){t[n]=new Array(256),r[n]=new Array(256);for(var o=0;o<256;o++)t[n][o]=0}var i=e.ReadByte(),a=i,s=0;do{c(e,t[i],r[i]),s>0?(s--,i++):(i=e.ReadByte())==a+1&&(s=e.ReadByte()),a=i}while(0!=i)}(e,r,n);for(var l=new Array(256),u=0;u<256;u++)l[u]=a(n[u]);for(var A=new Array(4),h=new Array(4),d=0;d<4;d++)A[d]=e.ReadUint32(),h[d]=0;var g=new Buffer.allocUnsafe(t),p=Math.floor(t/4);for(u=0;u<p;u++)for(d=0;d<4;d++){var y=o(A[d]),m=l[h[d]][y];g[u+d*p]=m,A[d]=s(A[d],n[h[d]][m],r[h[d]][m]),A[d]=f(e,A[d]),h[d]=m}for(u*=4;u<t;)y=o(A[3]),m=i(n[h[3]],y),g[u++]=m,A[3]=s(A[3],n[h[3]][m],r[h[3]][m]),A[3]=f(e,A[3]),h[3]=m;return g}(t,l)},encode:function(e,t){return 0==t?function(e){const t=e.length;var r=new n("",0,780);r.WriteByte(0),r.WriteUint32(0),r.WriteUint32(0);var o=new Array(256);(function(e,t){for(var r=0;r<256;r++)t[r]=0;for(r=0;r<e.length;r++)t[e[r]]++})(e,o),A(o),h(r,o);var i=new Array(256);i[0]=0;for(var a=1;a<256;a++)i[a]=i[a-1]+o[a-1];var s=new Array(4);for(a=0;a<4;a++)s[a]=1<<23;var f=Math.floor(1.05*t+100),c=new n("",f,f);for(a=t-1;a>=0;a--)s[a%4]=u(s[a%4],c,i[e[a]],o[e[a]],12);for(a=3;a>=0;a--)l(s[a],c);var d=r.pos;return r.buf.writeInt32LE(d-9+(c.length-c.pos),1),r.buf.writeInt32LE(t,5),Buffer.concat([r.buf.slice(0,r.pos),c.buf.slice(c.pos,c.length)],r.pos+c.length-c.pos)}(e):function(e){const t=e.length;var r=new n("",0,198156);r.WriteByte(1),r.WriteUint32(0),r.WriteUint32(0);for(var o=new Array(256),i=new Array(256),a=new Array(256),s=0;s<256;s++)i[s]=new Array(256),a[s]=new Array(256);for(function(e,t,r){for(var n=0;n<256;n++){r[n]=0;for(var o=0;o<256;o++)t[n][o]=0}var i=0;for(n=0;n<e.length;n++)r[e[n]]++,t[i][e[n]]++,i=e[n];t[0][e[1*(e.length>>2)]]++,t[0][e[2*(e.length>>2)]]++,t[0][e[3*(e.length>>2)]]++,r[0]+=3}(e,i,o),function(e,t){for(var r=0;r<256;r++)t[r]&&A(e[r])}(i,o),function(e,t,r){for(var n=0,o=0;o<256;o++)if(r[o]){if(n>0)n--;else if(e.WriteByte(o),o>0&&r[o-1]>0){for(n=o+1;n<256&&r[n];n++);n-=o+1,e.WriteByte(n)}h(e,t[o])}e.WriteByte(0)}(r,i,o),s=0;s<256;s++)if(o[s]){a[s][0]=0;for(var f=1;f<256;f++)a[s][f]=a[s][f-1]+i[s][f-1]}var c=new Array(4),d=new Array(4);for(f=0;f<4;f++)c[f]=1<<23,d[f]=0;var g=new n("",t,t),p=Math.floor(t/4),y=new Array(4),m=new Array(4);for(f=0;f<4;f++)y[f]=(f+1)*p-2,m[f]=e[y[f]+1];for(m[3]=e[t-1],s=t-2;s>4*p-2;s--)c[3]=u(c[3],g,a[e[s]][m[3]],i[e[s]][m[3]],12),m[3]=e[s];for(;y[0]>=0;)for(f=3;f>=0;f--){var C=e[y[f]];c[f]=u(c[f],g,a[C][m[f]],i[C][m[f]],12),m[f]=C,y[f]--}for(f=3;f>=0;f--)c[f]=u(c[f],g,a[0][m[f]],i[0][m[f]],12);for(s=3;s>=0;s--)l(c[s],g);var I=r.pos;return r.buf.writeInt32LE(I-9+(g.length-g.pos),1),r.buf.writeInt32LE(t,5),Buffer.concat([r.buf.slice(0,r.pos),g.buf.slice(g.pos,g.length)],r.pos+g.length-g.pos)}(e)}}},8223:(e,t,r)=>{const n=r(8706);function o(e,t){return e&(1<<t)-1}function i(e,t){for(var r=0;t>=e[r+1];)r++;return r}function a(e,t){for(var r=1<<t,n=new Array(r),o=0,i=0;i<r;i++){for(;i>=e[o+1];)o++;n[i]=o}return n}function s(e,t,r,n){return r*(e>>n)+(e&(1<<n)-1)-t}function f(e,t){return t<32768&&(t=(t<<16)+e.ReadUint16()),t}function l(e,t){t.WriteByteNeg(e>>24&255),t.WriteByteNeg(e>>16&255),t.WriteByteNeg(e>>8&255),t.WriteByteNeg(e>>0&255)}function u(e,t,r,n,o){return e=function(e,t,r,n){for(var o=(1<<31-n)*r;e>=o;)t.WriteByteNeg(e>>8&255),t.WriteByteNeg(255&e),e>>=16;return e}(e,t,n,o),(Math.floor(e/n)<<o)+e%n+r}function c(e,t,r){0==r&&(r=4);for(var o=new Array(r),i=new Array(r),a=0;a<r;a++)i[a]=Math.floor(t.length/r)+(t.length%r>a),o[a]=new Array(i[a]);for(var s=0,f=0;f<t.length;f+=r,s++)for(var l=0;l<r;l++)s<o[l].length&&(o[l][s]=t[f+l]);var u=new Array(r),c=0;for(a=0;a<r;a++){var A=h(o[a],0),d=h(o[a],1);u[a]=d.length<A.length?d:A,c+=u[a].length}var g=new n("",0,c+5*r+1);for(g.WriteByte(r),a=0;a<r;a++)g.WriteUint7(u[a].length);for(a=0;a<r;a++)g.WriteData(u[a],u[a].length);return g.buf.slice(0,g.buf.pos)}function A(e,t){var r=e.ReadByte(),l=1&r,u=8&r,c=32&r,h=64&r,p=128&r;if(16&r||(t=e.ReadUint7()),u)return function(e,t){for(var r=e.ReadByte(),n=new Array(r),o=new Array(r),i=0;i<r;i++)n[i]=e.ReadUint7();var a=new Array(r);for(i=0;i<r;i++)o[i]=Math.floor(t/r)+(t%r>i),a[i]=A(e,o[i]);var s=new Buffer.allocUnsafe(t);for(i=0;i<r;i++)for(var f=0;f<o[i];f++)s[f*r+i]=a[i][f];return s}(e,t);if(p)var m=t,[C,I,t]=function(e){for(var t=e.ReadByte(),r=new Array(t),n=0;n<t;n++)r[n]=e.ReadByte();return[r,t,e.ReadUint7()]}(e);if(h)var b=t,[w,v,t]=function(e){var t=e.ReadUint7(),r=e.ReadUint7();if(1&t)var o=e.ReadData((t-1)/2);else{var i=e.ReadUint7();o=e.ReadData(i),o=g(new n(o),t/2)}o=new n(o);var a=new Array(256),s=o.ReadByte();0==s&&(s=256);for(var f=0;f<s;f++)a[o.ReadByte()]=1;return[a,o,r]}(e);if(c)var B=e.ReadData(t);else B=0==l?g(e,t):function(e,t){var r=(A=e.ReadByte())>>4,l=e;if(1&A){var u=e.ReadUint7(),c=e.ReadUint7(),A=new n(e.ReadData(c));l=new n(g(A,u))}var h=new Array(256),p=new Array(256);!function(e,t,r,n){for(var o=0;o<256;o++){t[o]=new Array(256),r[o]=new Array(256);for(var i=0;i<256;i++)t[o][i]=0}var a=d(e);for(o=0;o<256;o++)if(a[o]){var s=0;for(i=0;i<256;i++)a[i]&&(s>0?s--:(t[o][i]=e.ReadUint7(),0==t[o][i]&&(s=e.ReadByte())));for(y(t[o],n),r[o][0]=0,i=0;i<256;i++)r[o][i+1]=r[o][i]+t[o][i]}}(l,h,p,r);for(var m=new Array(256),C=0;C<256;C++)m[C]=a(p[C],r);for(var I=new Array(4),b=new Array(4),w=0;w<4;w++)I[w]=e.ReadUint32(),b[w]=0;var v=new Buffer.allocUnsafe(t),B=Math.floor(t/4);for(C=0;C<B;C++)for(w=0;w<4;w++){var E=o(I[w],r),_=m[b[w]][E];v[C+w*B]=_,I[w]=s(I[w],p[b[w]][_],h[b[w]][_],r),I[w]=f(e,I[w]),b[w]=_}for(C*=4;C<t;)E=o(I[3],r),_=i(p[b[3]],E),v[C++]=_,I[3]=s(I[3],p[b[3]][_],h[b[3]][_],r),I[3]=f(e,I[3]),b[3]=_;return v}(e,t);return h&&(B=function(e,t,r,o){new n(e);for(var i=new Buffer.allocUnsafe(o),a=0,s=0;a<o;s++){var f=e[s];if(t[f])for(var l=r.ReadUint7(),u=0;u<=l;u++)i[a++]=f;else i[a++]=f}return i}(B,w,v,b)),p&&(B=function(e,t,r,n){var o=new Buffer.allocUnsafe(n),i=0;if(r<=1)for(var a=0;a<n;a++)o[a]=t[0];else if(r<=2)for(a=0;a<n;a++){if(a%8==0)var s=e[i++];o[a]=t[1&s],s>>=1}else if(r<=4)for(a=0;a<n;a++)a%4==0&&(s=e[i++]),o[a]=t[3&s],s>>=2;else if(r<=16)for(a=0;a<n;a++)a%2==0&&(s=e[i++]),o[a]=t[15&s],s>>=4;return o}(B,C,I,m)),B}function h(e,t){var r=new n("",0,10);r.WriteByte(t);var o=1&t,i=8&t,a=32&t,s=64&t,f=128&t,A=t>>8;if(16&t||r.WriteUint7(e.length),i)return Buffer.concat([r.buf.slice(0,r.pos),c(0,e,A)]);var h=new Buffer.alloc(0);f&&([h,e]=function(e){for(var t=new Array(256),r=0;r<256;r++)t[r]=0;for(r=0;r<e.length;r++)t[e[r]]++;var o=new Array(256),i=0;for(r=0;r<256;r++)t[r]>0&&(o[r]=i++);if(!(i>16)){if(i<=1)var a=new Buffer.allocUnsafe(0);else if(i<=2){a=new Buffer.allocUnsafe(Math.ceil(e.length/8));var s=-1;for(r=0;r<e.length;r++)r%8==0&&(a[++s]=0),a[s]+=o[e[r]]<<r%8}else if(i<=4)for(a=new Buffer.allocUnsafe(Math.ceil(e.length/4)),s=-1,r=0;r<e.length;r++)r%4==0&&(a[++s]=0),a[s]+=o[e[r]]<<r%4*2;else for(a=new Buffer.allocUnsafe(Math.ceil(e.length/2)),s=-1,r=0;r<e.length;r++)r%2==0&&(a[++s]=0),a[s]+=o[e[r]]<<r%2*4;var f=new n("",0,i+5);for(f.WriteByte(i),s=0,r=0;r<256;r++)t[r]>0&&(t[r]=s++,f.WriteByte(r));return f.WriteUint7(a.length),[f.buf.slice(0,f.pos),a]}}(e));var d=new Buffer.alloc(0);if(s&&([d,e]=function(e){for(var t=new Array(256),r=0;r<256;r++)t[r]=0;var o=-1;for(r=0;r<e.length;r++)t[e[r]]+=e[r]==o?1:-1,o=e[r];var i=0;for(r=0;r<256;r++)t[r]>0&&i++;for(i||(i=1,t[0]=1),(l=new n("",0,i+1+e.length)).WriteByte(i),r=0;r<256;r++)t[r]>0&&l.WriteByte(r);var a=new Buffer.allocUnsafe(e.length),s=0;for(r=0;r<e.length;r++)if(a[s++]=e[r],t[e[r]]>0){o=e[r];for(var f=0;r+f+1<e.length&&e[r+f+1]==o;)f++;l.WriteUint7(f),r+=f}var l,u=C(l.buf.slice(0,l.pos)),c=new n("",0,16);return c.WriteUint7(2*l.pos),c.WriteUint7(s),c.WriteUint7(u.length),[l=Buffer.concat([c.buf.slice(0,c.pos),u]),a.slice(0,s)]}(e)),e.length<4&&1==o&&(o=0,r.buf[0]&=-2),a)var g=e;else g=0==o?C(e):function(e){const t=e.length;for(var r=new n("",0,198156),o=new Array(256),i=new Array(256),a=new Array(256),s=0;s<256;s++)i[s]=new Array(256),a[s]=new Array(256);var f=12;(function(e,t,r){for(var n=0;n<256;n++){r[n]=0;for(var o=0;o<256;o++)t[n][o]=0}var i=0;for(n=0;n<e.length;n++)r[i]++,t[i][e[n]]++,i=e[n];r[i]++,t[0][e[1*(e.length>>2)]]++,t[0][e[2*(e.length>>2)]]++,t[0][e[3*(e.length>>2)]]++,r[0]+=3})(e,i,o),function(e,t,r){for(var n=0;n<256;n++)if(t[n]){var o=Math.ceil(Math.log2(t[n]));o>12&&(o=12),p(e[n],o)}}(i,o);var c=new n("",0,198156);!function(e,t,r){m(e,r);for(var n=0;n<256;n++)if(r[n])for(var o=0,i=0;i<256;i++)if(r[i])if(o)o--;else if(e.WriteUint7(t[n][i]),!t[n][i]){for(var a=i+1;a<256;a++)if(r[a]){if(0!=t[n][a])break;o++}e.WriteByte(o)}}(c,i,o);var A=C(c.buf.slice(0,c.pos));for(A.length<c.pos?(r.WriteByte(193),r.WriteUint7(c.pos),r.WriteUint7(A.length),r.WriteData(A,A.length)):(r.WriteByte(192),r.WriteData(c.buf,c.pos)),function(e,t,r){for(var n=0;n<256;n++)t[n]&&y(e[n],12)}(i,o),s=0;s<256;s++)if(o[s]){a[s][0]=0;for(var h=1;h<256;h++)a[s][h]=a[s][h-1]+i[s][h-1]}var d=new Array(4),g=new Array(4);for(h=0;h<4;h++)d[h]=32768,g[h]=0;var I=new n("",1.05*t+100>>0,1.05*t+100>>0),b=Math.floor(t/4),w=new Array(4),v=new Array(4);for(h=0;h<4;h++)w[h]=(h+1)*b-2,v[h]=e[w[h]+1];for(v[3]=e[t-1],s=t-2;s>4*b-2;s--)d[3]=u(d[3],I,a[e[s]][v[3]],i[e[s]][v[3]],f),v[3]=e[s];for(;w[0]>=0;)for(h=3;h>=0;h--){var B=e[w[h]];d[h]=u(d[h],I,a[B][v[h]],i[B][v[h]],f),v[h]=B,w[h]--}for(h=3;h>=0;h--)d[h]=u(d[h],I,a[0][v[h]],i[0][v[h]],f);for(s=3;s>=0;s--)l(d[s],I);return Buffer.concat([r.buf.slice(0,r.pos),I.buf.slice(I.pos,I.length)],r.pos+I.length-I.pos)}(e);return Buffer.concat([r.buf.slice(0,r.pos),h,d,g])}function d(e){for(var t=new Array(256),r=0;r<256;r++)t[r]=0;var n=0,o=e.ReadByte(),i=o;do{t[o]=1,n>0?(n--,o++):(o=e.ReadByte())==i+1&&(n=e.ReadByte()),i=o}while(0!=o);return t}function g(e,t){var r=new Array(256),n=new Array(256);!function(e,t,r){for(var n=0;n<256;n++)t[n]=0;var o=d(e);for(n=0;n<256;n++)o[n]>0&&(t[n]=e.ReadUint7());for(y(t,12),r[0]=0,n=0;n<=255;n++)r[n+1]=r[n]+t[n]}(e,r,n);for(var i=a(n,12),l=new Array(4),u=0;u<4;u++)l[u]=e.ReadUint32();var c=new Buffer.allocUnsafe(t);for(u=0;u<t;u++){var A=u%4,h=i[o(l[A],12)];c[u]=h,l[A]=s(l[A],n[h],r[h],12),l[A]=f(e,l[A])}return c}function p(e,t){for(var r=0,n=0;n<256;n++)r+=e[n];const o=1<<t;var i=o/r;do{var a=0,s=0,f=0;for(r=0,n=0;n<256;n++)0!=e[n]&&(a<e[n]&&(a=e[n],s=n),e[n]=Math.floor(e[n]*i),0==e[n]&&(e[n]=1),r+=e[n]);r<o?e[s]+=o-r:r-o<e[s]/2&&e[s]>2?e[s]-=r-o:r!=o&&(i=o/r,f=1)}while(f)}function y(e,t){for(var r=0,n=0;n<256;n++)r+=e[n];if(0!=r&&r!=1<<t){for(var o=0;r<1<<t;)r*=2,o++;for(n=0;n<256;n++)e[n]<<=o}}function m(e,t){for(var r=0,n=0;n<256;n++)if(t[n])if(r>0)r--;else if(e.WriteByte(n),n>0&&t[n-1]>0){for(r=n+1;r<256&&t[r];r++);r-=n+1,e.WriteByte(r)}e.WriteByte(0)}function C(e){const t=e.length;var r=new n("",0,780),o=new Array(256);!function(e,t){for(var r=0;r<256;r++)t[r]=0;for(r=0;r<e.length;r++)t[e[r]]++}(e,o);var i=Math.ceil(Math.log2(t));i>12&&(i=12),p(o,i),function(e,t){m(e,t);for(var r=0;r<256;r++)t[r]&&e.WriteUint7(t[r])}(r,o),p(o,12);var a=new Array(256);a[0]=0;for(var s=1;s<256;s++)a[s]=a[s-1]+o[s-1];var f=new Array(4);for(s=0;s<4;s++)f[s]=32768;var c=new n("",1.05*t+100>>0,1.05*t+100>>0);for(s=t-1;s>=0;s--)f[s%4]=u(f[s%4],c,a[e[s]],o[e[s]],12);for(s=3;s>=0;s--)l(f[s],c);return Buffer.concat([r.buf.slice(0,r.pos),c.buf.slice(c.pos,c.length)],r.pos+c.length-c.pos)}e.exports={decode:function(e){return A(new n(e),0)},encode:h}},5997:(e,t,r)=>{const n=r(8706),o=r(8223);var i=new(r(635));function a(e,t){for(var r=e+"";r.length<t;)r="0"+r;return r}function s(e,t,r,n){var o=e[0][0].ReadByte(),i=n-e[0][o].ReadUint32();if(5==o)return t[n]=t[i],r[n]=r[i],t[n];var s=1;t[n]="",r[n]=new Array(256);do{switch(o=e[s][0].ReadByte()){case 2:r[n][s]=e[s][2].ReadChar();break;case 1:r[n][s]=e[s][1].ReadString();break;case 7:r[n][s]=e[s][7].ReadUint32();break;case 3:var f=e[s][3].ReadUint32(),l=e[s][4].ReadByte();r[n][s]=a(f,l);break;case 8:r[n][s]=(r[i][s]>>0)+e[s][8].ReadByte();break;case 9:f=(r[i][s]>>0)+e[s][9].ReadByte(),l=r[i][s].length,r[n][s]=a(f,l);break;case 10:r[n][s]=r[i][s];break;default:r[n][s]=""}t[n]+=r[n][s++]}while(12!=o);return t[n]}function f(e,t,r,n,o,i){for(var a=0;a<n.length;a++)if(!(r>0&&5==t[a][0].type)&&t[a][r])switch(e[0].WriteByte(t[a][r].type),t[a][r].type){case 6:e[6].WriteUint32(t[a][r].val);break;case 5:e[5].WriteUint32(t[a][r].val);break;case 1:e[1].WriteString(t[a][r].val);break;case 2:e[2].WriteChar(t[a][r].val);break;case 7:e[7].WriteUint32(t[a][r].val);break;case 3:e[3].WriteUint32(t[a][r].val),e[4].WriteByte(t[a][r].val.length);break;case 8:case 9:e[t[a][r].type].WriteByte(t[a][r].val)}}function l(e,t,r,n){for(var o=0;o<=12;o++)if(!(e[o].pos<=0)){n.WriteByte(o+(0==o?128:0)),e[o]=e[o].buf.slice(0,e[o].pos);var i=u(e[o],r);n.WriteUint7(i.length),n.WriteData(i,i.length)}}function u(e,t){var r,n=1<<30,a=[0,1,64,65,128,129,201];for(var s in a){var f=a[s];if(!(1&f&&e.length<100||8&f&&e.length%4!=0)){try{var l=t?i.encode(e,f):o.encode(e,f)}catch(e){l=0}l&&n>l.length&&(n=l.length,r=l)}}return r}function c(e,t,r,n,o){var i=0,a=o-1;e[o]=new Array(256),t[n]?e[o][0]={type:5,val:o-t[n]}:e[o][0]={type:6,val:0==o?0:1},t[n]=o;for(var s=n.match(/([a-zA-Z0-9]{1,9})|([^a-zA-Z0-9]+)/g),f=0;f<s.length;f++){var l=f+1,u=1,c=s[f];if(s[f].match(/^0+[0-9]*$/g)?u=3:s[f].match(/^[0-9]+$/g)?u=7:1==s[f].length&&(u=2),a>=0&&e[a][l])if(e[a][l].str==s[f])u=10,c="";else if(7==e[a][l].type||8==e[a][l].type){var A=c-e[a][l].str;r[l]++,A>=0&&A<256&&r[l]>o/2&&(u=8,c=A)}else 3!=e[a][l].type&&9!=e[a][l].type||e[a][l].str.length!=c.length||(A=c-e[a][l].str,r[l]++,A>=0&&A<256&&r[l]>o/2&&(u=9,c=A));e[o][l]={str:s[f],val:c,type:u},i<e[o][l].val.length+3&&(i=e[o][l].val.length+3)}return e[o][++l]={type:12},[l+1,i]}e.exports={encode:function(e,t){var r=e.toString();"\n"==r[r.length-1]&&(r=r.substring(0,r.length-1));var o=r.split("\n"),i=new n("",0,2*r.length+1e4);i.WriteUint32(r.length),i.WriteUint32(o.length),i.WriteByte(t);for(var a=new Array(o.length),s={},u=new Array(256).fill(0),A=0,h=0,d=0;d<o.length;d++){var[g,p]=c(a,s,u,o[d],d);A<g&&(A=g),h<p&&(h=p)}for(var y=0;y<A;y++){for(var m=new Array(13),C=0;C<=12;C++)m[C]=new n("",0,o.length*h);f(m,a,y,o),l(m,0,t,i)}return i.buf.slice(0,i.pos)},decode:function(e,t,r){(e=new n(e)).ReadUint32();var a=e.ReadUint32(),f=e.ReadByte(),l=function(e,t,r,a){for(var s=-1,f=new Array(256);!e.EOF();){var l=e.ReadByte(),u=128&l,c=64&l,A=63&l;if(u&&(f[++s]=new Array(13)),0!=A&&u){var h=new Array(a-1).fill(10);f[s][0]=new n(Buffer.from([A].concat(h)))}if(c){var d=e.ReadByte(),g=e.ReadByte();f[s][A]=new n(f[d][g].buf)}else{var p=e.ReadUint7(),y=e.ReadData(p);f[s][A]=r?i.decode(y):o.decode(y),f[s][A]=new n(f[s][A])}}return f}(e,0,f,a),u=new Array(a),c=new Array(a),A="";void 0===r&&(r="\n");for(var h=0;h<a;h++)A+=s(l,u,c,h)+r;return A}}},7789:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});const o=r(9036),i=n(r(4427)),a=n(r(4026));class s{constructor({fill:e,cache:t}){if("function"!=typeof e)throw new TypeError("must pass a fill function");if("object"!=typeof t)throw new TypeError("must pass a cache object");if("function"!=typeof t.get||"function"!=typeof t.set||"function"!=typeof t.delete)throw new TypeError("cache must implement get(key), set(key, val), and and delete(key)");this.cache=t,this.fillCallback=e}static isAbortException(e){return"AbortError"===e.name||"ERR_ABORTED"===e.code||"AbortError: aborted"===e.message||"Error: aborted"===e.message}evict(e,t){this.cache.get(e)===t&&this.cache.delete(e)}fill(e,t,r,n){const o=new i.default,s=new a.default;s.addCallback(n);const f={aborter:o,promise:this.fillCallback(t,o.signal,(e=>{s.callback(e)})),settled:!1,statusReporter:s,get aborted(){return this.aborter.signal.aborted}};f.aborter.addSignal(r),f.aborter.signal.addEventListener("abort",(()=>{f.settled||this.evict(e,f)})),f.promise.then((()=>{f.settled=!0}),(()=>{f.settled=!0,this.evict(e,f)})).catch((e=>{throw console.error(e),e})),this.cache.set(e,f)}static checkSinglePromise(e,t){function r(){if(t&&t.aborted)throw Object.assign(new Error("aborted"),{code:"ERR_ABORTED"})}return e.then((e=>(r(),e)),(e=>{throw r(),e}))}has(e){return this.cache.has(e)}get(e,t,r,n){if(!r&&t instanceof o.AbortSignal)throw new TypeError("second get argument appears to be an AbortSignal, perhaps you meant to pass `null` for the fill data?");const i=this.cache.get(e);return i?i.aborted&&!i.settled?(this.evict(e,i),this.get(e,t,r,n)):i.settled?i.promise:(i.aborter.addSignal(r),i.statusReporter.addCallback(n),s.checkSinglePromise(i.promise,r)):(this.fill(e,t,r,n),s.checkSinglePromise(this.cache.get(e).promise,r))}delete(e){const t=this.cache.get(e);t&&(t.settled||t.aborter.abort(),this.cache.delete(e))}clear(){const e=this.cache.keys();let t=0;for(let r=e.next();!r.done;r=e.next())this.delete(r.value),t+=1;return t}}t.default=s},4427:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(9036);class o{}t.default=class{constructor(){this.signals=new Set,this.abortController=new n.AbortController}addSignal(e=new o){if(this.signal.aborted)throw new Error("cannot add a signal, already aborted!");this.signals.add(e),e.aborted?this.handleAborted(e):"function"==typeof e.addEventListener&&e.addEventListener("abort",(()=>{this.handleAborted(e)}))}handleAborted(e){this.signals.delete(e),0===this.signals.size&&this.abortController.abort()}get signal(){return this.abortController.signal}abort(){this.abortController.abort()}}},4026:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=class{constructor(){this.callbacks=new Set}addCallback(e=(()=>{})){this.callbacks.add(e),e(this.currentMessage)}callback(e){this.currentMessage=e,this.callbacks.forEach((t=>{t(e)}))}}},9036:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AbortSignal=t.AbortController=void 0;const n=r(1826);var o=function(){if("undefined"!=typeof self)return self;if("undefined"!=typeof window)return window;if(void 0!==r.g)return r.g;throw new Error("unable to locate global object")};let i=void 0===o().AbortController?n.AbortController:o().AbortController;t.AbortController=i;let a=void 0===o().AbortController?n.AbortSignal:o().AbortSignal;t.AbortSignal=a},8802:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});const o=n(r(7789));t.default=o.default},1826:(e,t)=>{"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function n(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,n.key,n)}}function o(e,t,r){return t&&n(e.prototype,t),r&&n(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}function i(e){return i=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},i(e)}function a(e,t){return a=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},a(e,t)}function s(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function f(){return f="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(e,t,r){var n=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=i(e)););return e}(e,t);if(n){var o=Object.getOwnPropertyDescriptor(n,t);return o.get?o.get.call(arguments.length<3?e:r):o.value}},f.apply(this,arguments)}Object.defineProperty(t,"__esModule",{value:!0});var l=function(){function e(){r(this,e),Object.defineProperty(this,"listeners",{value:{},writable:!0,configurable:!0})}return o(e,[{key:"addEventListener",value:function(e,t,r){e in this.listeners||(this.listeners[e]=[]),this.listeners[e].push({callback:t,options:r})}},{key:"removeEventListener",value:function(e,t){if(e in this.listeners)for(var r=this.listeners[e],n=0,o=r.length;n<o;n++)if(r[n].callback===t)return void r.splice(n,1)}},{key:"dispatchEvent",value:function(e){if(e.type in this.listeners){for(var t=this.listeners[e.type].slice(),r=0,n=t.length;r<n;r++){var o=t[r];try{o.callback.call(this,e)}catch(e){Promise.resolve().then((function(){throw e}))}o.options&&o.options.once&&this.removeEventListener(e.type,o.callback)}return!e.defaultPrevented}}}]),e}(),u=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&a(e,t)}(c,e);var t,n,u=(t=c,n=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,r=i(t);if(n){var o=i(this).constructor;e=Reflect.construct(r,arguments,o)}else e=r.apply(this,arguments);return function(e,t){if(t&&("object"==typeof t||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return s(e)}(this,e)});function c(){var e;return r(this,c),(e=u.call(this)).listeners||l.call(s(e)),Object.defineProperty(s(e),"aborted",{value:!1,writable:!0,configurable:!0}),Object.defineProperty(s(e),"onabort",{value:null,writable:!0,configurable:!0}),Object.defineProperty(s(e),"reason",{value:void 0,writable:!0,configurable:!0}),e}return o(c,[{key:"toString",value:function(){return"[object AbortSignal]"}},{key:"dispatchEvent",value:function(e){"abort"===e.type&&(this.aborted=!0,"function"==typeof this.onabort&&this.onabort.call(this,e)),f(i(c.prototype),"dispatchEvent",this).call(this,e)}}]),c}(l),c=function(){function e(){r(this,e),Object.defineProperty(this,"signal",{value:new u,writable:!0,configurable:!0})}return o(e,[{key:"abort",value:function(e){var t;try{t=new Event("abort")}catch(e){"undefined"!=typeof document?document.createEvent?(t=document.createEvent("Event")).initEvent("abort",!1,!1):(t=document.createEventObject()).type="abort":t={type:"abort",bubbles:!1,cancelable:!1}}var r=e;if(void 0===r)if("undefined"==typeof document)(r=new Error("This operation was aborted")).name="AbortError";else try{r=new DOMException("signal is aborted without reason")}catch(e){(r=new Error("This operation was aborted")).name="AbortError"}this.signal.reason=r,this.signal.dispatchEvent(t)}},{key:"toString",value:function(){return"[object AbortController]"}}]),e}();"undefined"!=typeof Symbol&&Symbol.toStringTag&&(c.prototype[Symbol.toStringTag]="AbortController",u.prototype[Symbol.toStringTag]="AbortSignal"),t.AbortController=c,t.AbortSignal=u,t.abortableFetch=function(e){"function"==typeof e&&(e={fetch:e});var t=e,r=t.fetch,n=t.Request,o=void 0===n?r.Request:n,i=t.AbortController,a=t.__FORCE_INSTALL_ABORTCONTROLLER_POLYFILL,s=void 0!==a&&a;if(!function(e){return e.__FORCE_INSTALL_ABORTCONTROLLER_POLYFILL?(console.log("__FORCE_INSTALL_ABORTCONTROLLER_POLYFILL=true is set, will force install polyfill"),!0):"function"==typeof e.Request&&!e.Request.prototype.hasOwnProperty("signal")||!e.AbortController}({fetch:r,Request:o,AbortController:i,__FORCE_INSTALL_ABORTCONTROLLER_POLYFILL:s}))return{fetch:r,Request:f};var f=o;(f&&!f.prototype.hasOwnProperty("signal")||s)&&((f=function(e,t){var r;t&&t.signal&&(r=t.signal,delete t.signal);var n=new o(e,t);return r&&Object.defineProperty(n,"signal",{writable:!1,enumerable:!1,configurable:!0,value:r}),n}).prototype=o.prototype);var l=r;return{fetch:function(e,t){var r=f&&f.prototype.isPrototypeOf(e)?e.signal:t?t.signal:void 0;if(r){var n;try{n=new DOMException("Aborted","AbortError")}catch(e){(n=new Error("Aborted")).name="AbortError"}if(r.aborted)return Promise.reject(n);var o=new Promise((function(e,t){r.addEventListener("abort",(function(){return t(n)}),{once:!0})}));return t&&t.signal&&delete t.signal,Promise.race([o,l(e,t)])}return l(e,t)},Request:f}}},7526:(e,t)=>{"use strict";t.byteLength=function(e){var t=s(e),r=t[0],n=t[1];return 3*(r+n)/4-n},t.toByteArray=function(e){var t,r,i=s(e),a=i[0],f=i[1],l=new o(function(e,t,r){return 3*(t+r)/4-r}(0,a,f)),u=0,c=f>0?a-4:a;for(r=0;r<c;r+=4)t=n[e.charCodeAt(r)]<<18|n[e.charCodeAt(r+1)]<<12|n[e.charCodeAt(r+2)]<<6|n[e.charCodeAt(r+3)],l[u++]=t>>16&255,l[u++]=t>>8&255,l[u++]=255&t;return 2===f&&(t=n[e.charCodeAt(r)]<<2|n[e.charCodeAt(r+1)]>>4,l[u++]=255&t),1===f&&(t=n[e.charCodeAt(r)]<<10|n[e.charCodeAt(r+1)]<<4|n[e.charCodeAt(r+2)]>>2,l[u++]=t>>8&255,l[u++]=255&t),l},t.fromByteArray=function(e){for(var t,n=e.length,o=n%3,i=[],a=16383,s=0,l=n-o;s<l;s+=a)i.push(f(e,s,s+a>l?l:s+a));return 1===o?(t=e[n-1],i.push(r[t>>2]+r[t<<4&63]+"==")):2===o&&(t=(e[n-2]<<8)+e[n-1],i.push(r[t>>10]+r[t>>4&63]+r[t<<2&63]+"=")),i.join("")};for(var r=[],n=[],o="undefined"!=typeof Uint8Array?Uint8Array:Array,i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",a=0;a<64;++a)r[a]=i[a],n[i.charCodeAt(a)]=a;function s(e){var t=e.length;if(t%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var r=e.indexOf("=");return-1===r&&(r=t),[r,r===t?0:4-r%4]}function f(e,t,n){for(var o,i,a=[],s=t;s<n;s+=3)o=(e[s]<<16&16711680)+(e[s+1]<<8&65280)+(255&e[s+2]),a.push(r[(i=o)>>18&63]+r[i>>12&63]+r[i>>6&63]+r[63&i]);return a.join("")}n["-".charCodeAt(0)]=62,n["_".charCodeAt(0)]=63},8287:(e,t,r)=>{"use strict";const n=r(7526),o=r(251),i="function"==typeof Symbol&&"function"==typeof Symbol.for?Symbol.for("nodejs.util.inspect.custom"):null;t.Buffer=f,t.SlowBuffer=function(e){return+e!=e&&(e=0),f.alloc(+e)},t.INSPECT_MAX_BYTES=50;const a=2147483647;function s(e){if(e>a)throw new RangeError('The value "'+e+'" is invalid for option "size"');const t=new Uint8Array(e);return Object.setPrototypeOf(t,f.prototype),t}function f(e,t,r){if("number"==typeof e){if("string"==typeof t)throw new TypeError('The "string" argument must be of type string. Received type number');return c(e)}return l(e,t,r)}function l(e,t,r){if("string"==typeof e)return function(e,t){if("string"==typeof t&&""!==t||(t="utf8"),!f.isEncoding(t))throw new TypeError("Unknown encoding: "+t);const r=0|g(e,t);let n=s(r);const o=n.write(e,t);return o!==r&&(n=n.slice(0,o)),n}(e,t);if(ArrayBuffer.isView(e))return function(e){if(K(e,Uint8Array)){const t=new Uint8Array(e);return h(t.buffer,t.byteOffset,t.byteLength)}return A(e)}(e);if(null==e)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e);if(K(e,ArrayBuffer)||e&&K(e.buffer,ArrayBuffer))return h(e,t,r);if("undefined"!=typeof SharedArrayBuffer&&(K(e,SharedArrayBuffer)||e&&K(e.buffer,SharedArrayBuffer)))return h(e,t,r);if("number"==typeof e)throw new TypeError('The "value" argument must not be of type number. Received type number');const n=e.valueOf&&e.valueOf();if(null!=n&&n!==e)return f.from(n,t,r);const o=function(e){if(f.isBuffer(e)){const t=0|d(e.length),r=s(t);return 0===r.length||e.copy(r,0,0,t),r}return void 0!==e.length?"number"!=typeof e.length||$(e.length)?s(0):A(e):"Buffer"===e.type&&Array.isArray(e.data)?A(e.data):void 0}(e);if(o)return o;if("undefined"!=typeof Symbol&&null!=Symbol.toPrimitive&&"function"==typeof e[Symbol.toPrimitive])return f.from(e[Symbol.toPrimitive]("string"),t,r);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e)}function u(e){if("number"!=typeof e)throw new TypeError('"size" argument must be of type number');if(e<0)throw new RangeError('The value "'+e+'" is invalid for option "size"')}function c(e){return u(e),s(e<0?0:0|d(e))}function A(e){const t=e.length<0?0:0|d(e.length),r=s(t);for(let n=0;n<t;n+=1)r[n]=255&e[n];return r}function h(e,t,r){if(t<0||e.byteLength<t)throw new RangeError('"offset" is outside of buffer bounds');if(e.byteLength<t+(r||0))throw new RangeError('"length" is outside of buffer bounds');let n;return n=void 0===t&&void 0===r?new Uint8Array(e):void 0===r?new Uint8Array(e,t):new Uint8Array(e,t,r),Object.setPrototypeOf(n,f.prototype),n}function d(e){if(e>=a)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+a.toString(16)+" bytes");return 0|e}function g(e,t){if(f.isBuffer(e))return e.length;if(ArrayBuffer.isView(e)||K(e,ArrayBuffer))return e.byteLength;if("string"!=typeof e)throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof e);const r=e.length,n=arguments.length>2&&!0===arguments[2];if(!n&&0===r)return 0;let o=!1;for(;;)switch(t){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":return J(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return W(e).length;default:if(o)return n?-1:J(e).length;t=(""+t).toLowerCase(),o=!0}}function p(e,t,r){let n=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===r||r>this.length)&&(r=this.length),r<=0)return"";if((r>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return R(this,t,r);case"utf8":case"utf-8":return _(this,t,r);case"ascii":return S(this,t,r);case"latin1":case"binary":return k(this,t,r);case"base64":return E(this,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return D(this,t,r);default:if(n)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),n=!0}}function y(e,t,r){const n=e[t];e[t]=e[r],e[r]=n}function m(e,t,r,n,o){if(0===e.length)return-1;if("string"==typeof r?(n=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),$(r=+r)&&(r=o?0:e.length-1),r<0&&(r=e.length+r),r>=e.length){if(o)return-1;r=e.length-1}else if(r<0){if(!o)return-1;r=0}if("string"==typeof t&&(t=f.from(t,n)),f.isBuffer(t))return 0===t.length?-1:C(e,t,r,n,o);if("number"==typeof t)return t&=255,"function"==typeof Uint8Array.prototype.indexOf?o?Uint8Array.prototype.indexOf.call(e,t,r):Uint8Array.prototype.lastIndexOf.call(e,t,r):C(e,[t],r,n,o);throw new TypeError("val must be string, number or Buffer")}function C(e,t,r,n,o){let i,a=1,s=e.length,f=t.length;if(void 0!==n&&("ucs2"===(n=String(n).toLowerCase())||"ucs-2"===n||"utf16le"===n||"utf-16le"===n)){if(e.length<2||t.length<2)return-1;a=2,s/=2,f/=2,r/=2}function l(e,t){return 1===a?e[t]:e.readUInt16BE(t*a)}if(o){let n=-1;for(i=r;i<s;i++)if(l(e,i)===l(t,-1===n?0:i-n)){if(-1===n&&(n=i),i-n+1===f)return n*a}else-1!==n&&(i-=i-n),n=-1}else for(r+f>s&&(r=s-f),i=r;i>=0;i--){let r=!0;for(let n=0;n<f;n++)if(l(e,i+n)!==l(t,n)){r=!1;break}if(r)return i}return-1}function I(e,t,r,n){r=Number(r)||0;const o=e.length-r;n?(n=Number(n))>o&&(n=o):n=o;const i=t.length;let a;for(n>i/2&&(n=i/2),a=0;a<n;++a){const n=parseInt(t.substr(2*a,2),16);if($(n))return a;e[r+a]=n}return a}function b(e,t,r,n){return Y(J(t,e.length-r),e,r,n)}function w(e,t,r,n){return Y(function(e){const t=[];for(let r=0;r<e.length;++r)t.push(255&e.charCodeAt(r));return t}(t),e,r,n)}function v(e,t,r,n){return Y(W(t),e,r,n)}function B(e,t,r,n){return Y(function(e,t){let r,n,o;const i=[];for(let a=0;a<e.length&&!((t-=2)<0);++a)r=e.charCodeAt(a),n=r>>8,o=r%256,i.push(o),i.push(n);return i}(t,e.length-r),e,r,n)}function E(e,t,r){return 0===t&&r===e.length?n.fromByteArray(e):n.fromByteArray(e.slice(t,r))}function _(e,t,r){r=Math.min(e.length,r);const n=[];let o=t;for(;o<r;){const t=e[o];let i=null,a=t>239?4:t>223?3:t>191?2:1;if(o+a<=r){let r,n,s,f;switch(a){case 1:t<128&&(i=t);break;case 2:r=e[o+1],128==(192&r)&&(f=(31&t)<<6|63&r,f>127&&(i=f));break;case 3:r=e[o+1],n=e[o+2],128==(192&r)&&128==(192&n)&&(f=(15&t)<<12|(63&r)<<6|63&n,f>2047&&(f<55296||f>57343)&&(i=f));break;case 4:r=e[o+1],n=e[o+2],s=e[o+3],128==(192&r)&&128==(192&n)&&128==(192&s)&&(f=(15&t)<<18|(63&r)<<12|(63&n)<<6|63&s,f>65535&&f<1114112&&(i=f))}}null===i?(i=65533,a=1):i>65535&&(i-=65536,n.push(i>>>10&1023|55296),i=56320|1023&i),n.push(i),o+=a}return function(e){const t=e.length;if(t<=Q)return String.fromCharCode.apply(String,e);let r="",n=0;for(;n<t;)r+=String.fromCharCode.apply(String,e.slice(n,n+=Q));return r}(n)}t.kMaxLength=a,f.TYPED_ARRAY_SUPPORT=function(){try{const e=new Uint8Array(1),t={foo:function(){return 42}};return Object.setPrototypeOf(t,Uint8Array.prototype),Object.setPrototypeOf(e,t),42===e.foo()}catch(e){return!1}}(),f.TYPED_ARRAY_SUPPORT||"undefined"==typeof console||"function"!=typeof console.error||console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support."),Object.defineProperty(f.prototype,"parent",{enumerable:!0,get:function(){if(f.isBuffer(this))return this.buffer}}),Object.defineProperty(f.prototype,"offset",{enumerable:!0,get:function(){if(f.isBuffer(this))return this.byteOffset}}),f.poolSize=8192,f.from=function(e,t,r){return l(e,t,r)},Object.setPrototypeOf(f.prototype,Uint8Array.prototype),Object.setPrototypeOf(f,Uint8Array),f.alloc=function(e,t,r){return function(e,t,r){return u(e),e<=0?s(e):void 0!==t?"string"==typeof r?s(e).fill(t,r):s(e).fill(t):s(e)}(e,t,r)},f.allocUnsafe=function(e){return c(e)},f.allocUnsafeSlow=function(e){return c(e)},f.isBuffer=function(e){return null!=e&&!0===e._isBuffer&&e!==f.prototype},f.compare=function(e,t){if(K(e,Uint8Array)&&(e=f.from(e,e.offset,e.byteLength)),K(t,Uint8Array)&&(t=f.from(t,t.offset,t.byteLength)),!f.isBuffer(e)||!f.isBuffer(t))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(e===t)return 0;let r=e.length,n=t.length;for(let o=0,i=Math.min(r,n);o<i;++o)if(e[o]!==t[o]){r=e[o],n=t[o];break}return r<n?-1:n<r?1:0},f.isEncoding=function(e){switch(String(e).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},f.concat=function(e,t){if(!Array.isArray(e))throw new TypeError('"list" argument must be an Array of Buffers');if(0===e.length)return f.alloc(0);let r;if(void 0===t)for(t=0,r=0;r<e.length;++r)t+=e[r].length;const n=f.allocUnsafe(t);let o=0;for(r=0;r<e.length;++r){let t=e[r];if(K(t,Uint8Array))o+t.length>n.length?(f.isBuffer(t)||(t=f.from(t)),t.copy(n,o)):Uint8Array.prototype.set.call(n,t,o);else{if(!f.isBuffer(t))throw new TypeError('"list" argument must be an Array of Buffers');t.copy(n,o)}o+=t.length}return n},f.byteLength=g,f.prototype._isBuffer=!0,f.prototype.swap16=function(){const e=this.length;if(e%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let t=0;t<e;t+=2)y(this,t,t+1);return this},f.prototype.swap32=function(){const e=this.length;if(e%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(let t=0;t<e;t+=4)y(this,t,t+3),y(this,t+1,t+2);return this},f.prototype.swap64=function(){const e=this.length;if(e%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(let t=0;t<e;t+=8)y(this,t,t+7),y(this,t+1,t+6),y(this,t+2,t+5),y(this,t+3,t+4);return this},f.prototype.toString=function(){const e=this.length;return 0===e?"":0===arguments.length?_(this,0,e):p.apply(this,arguments)},f.prototype.toLocaleString=f.prototype.toString,f.prototype.equals=function(e){if(!f.isBuffer(e))throw new TypeError("Argument must be a Buffer");return this===e||0===f.compare(this,e)},f.prototype.inspect=function(){let e="";const r=t.INSPECT_MAX_BYTES;return e=this.toString("hex",0,r).replace(/(.{2})/g,"$1 ").trim(),this.length>r&&(e+=" ... "),"<Buffer "+e+">"},i&&(f.prototype[i]=f.prototype.inspect),f.prototype.compare=function(e,t,r,n,o){if(K(e,Uint8Array)&&(e=f.from(e,e.offset,e.byteLength)),!f.isBuffer(e))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof e);if(void 0===t&&(t=0),void 0===r&&(r=e?e.length:0),void 0===n&&(n=0),void 0===o&&(o=this.length),t<0||r>e.length||n<0||o>this.length)throw new RangeError("out of range index");if(n>=o&&t>=r)return 0;if(n>=o)return-1;if(t>=r)return 1;if(this===e)return 0;let i=(o>>>=0)-(n>>>=0),a=(r>>>=0)-(t>>>=0);const s=Math.min(i,a),l=this.slice(n,o),u=e.slice(t,r);for(let e=0;e<s;++e)if(l[e]!==u[e]){i=l[e],a=u[e];break}return i<a?-1:a<i?1:0},f.prototype.includes=function(e,t,r){return-1!==this.indexOf(e,t,r)},f.prototype.indexOf=function(e,t,r){return m(this,e,t,r,!0)},f.prototype.lastIndexOf=function(e,t,r){return m(this,e,t,r,!1)},f.prototype.write=function(e,t,r,n){if(void 0===t)n="utf8",r=this.length,t=0;else if(void 0===r&&"string"==typeof t)n=t,r=this.length,t=0;else{if(!isFinite(t))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");t>>>=0,isFinite(r)?(r>>>=0,void 0===n&&(n="utf8")):(n=r,r=void 0)}const o=this.length-t;if((void 0===r||r>o)&&(r=o),e.length>0&&(r<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");n||(n="utf8");let i=!1;for(;;)switch(n){case"hex":return I(this,e,t,r);case"utf8":case"utf-8":return b(this,e,t,r);case"ascii":case"latin1":case"binary":return w(this,e,t,r);case"base64":return v(this,e,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return B(this,e,t,r);default:if(i)throw new TypeError("Unknown encoding: "+n);n=(""+n).toLowerCase(),i=!0}},f.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};const Q=4096;function S(e,t,r){let n="";r=Math.min(e.length,r);for(let o=t;o<r;++o)n+=String.fromCharCode(127&e[o]);return n}function k(e,t,r){let n="";r=Math.min(e.length,r);for(let o=t;o<r;++o)n+=String.fromCharCode(e[o]);return n}function R(e,t,r){const n=e.length;(!t||t<0)&&(t=0),(!r||r<0||r>n)&&(r=n);let o="";for(let n=t;n<r;++n)o+=V[e[n]];return o}function D(e,t,r){const n=e.slice(t,r);let o="";for(let e=0;e<n.length-1;e+=2)o+=String.fromCharCode(n[e]+256*n[e+1]);return o}function N(e,t,r){if(e%1!=0||e<0)throw new RangeError("offset is not uint");if(e+t>r)throw new RangeError("Trying to access beyond buffer length")}function x(e,t,r,n,o,i){if(!f.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>o||t<i)throw new RangeError('"value" argument is out of bounds');if(r+n>e.length)throw new RangeError("Index out of range")}function F(e,t,r,n,o){j(t,n,o,e,r,7);let i=Number(t&BigInt(4294967295));e[r++]=i,i>>=8,e[r++]=i,i>>=8,e[r++]=i,i>>=8,e[r++]=i;let a=Number(t>>BigInt(32)&BigInt(4294967295));return e[r++]=a,a>>=8,e[r++]=a,a>>=8,e[r++]=a,a>>=8,e[r++]=a,r}function M(e,t,r,n,o){j(t,n,o,e,r,7);let i=Number(t&BigInt(4294967295));e[r+7]=i,i>>=8,e[r+6]=i,i>>=8,e[r+5]=i,i>>=8,e[r+4]=i;let a=Number(t>>BigInt(32)&BigInt(4294967295));return e[r+3]=a,a>>=8,e[r+2]=a,a>>=8,e[r+1]=a,a>>=8,e[r]=a,r+8}function O(e,t,r,n,o,i){if(r+n>e.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("Index out of range")}function L(e,t,r,n,i){return t=+t,r>>>=0,i||O(e,0,r,4),o.write(e,t,r,n,23,4),r+4}function P(e,t,r,n,i){return t=+t,r>>>=0,i||O(e,0,r,8),o.write(e,t,r,n,52,8),r+8}f.prototype.slice=function(e,t){const r=this.length;(e=~~e)<0?(e+=r)<0&&(e=0):e>r&&(e=r),(t=void 0===t?r:~~t)<0?(t+=r)<0&&(t=0):t>r&&(t=r),t<e&&(t=e);const n=this.subarray(e,t);return Object.setPrototypeOf(n,f.prototype),n},f.prototype.readUintLE=f.prototype.readUIntLE=function(e,t,r){e>>>=0,t>>>=0,r||N(e,t,this.length);let n=this[e],o=1,i=0;for(;++i<t&&(o*=256);)n+=this[e+i]*o;return n},f.prototype.readUintBE=f.prototype.readUIntBE=function(e,t,r){e>>>=0,t>>>=0,r||N(e,t,this.length);let n=this[e+--t],o=1;for(;t>0&&(o*=256);)n+=this[e+--t]*o;return n},f.prototype.readUint8=f.prototype.readUInt8=function(e,t){return e>>>=0,t||N(e,1,this.length),this[e]},f.prototype.readUint16LE=f.prototype.readUInt16LE=function(e,t){return e>>>=0,t||N(e,2,this.length),this[e]|this[e+1]<<8},f.prototype.readUint16BE=f.prototype.readUInt16BE=function(e,t){return e>>>=0,t||N(e,2,this.length),this[e]<<8|this[e+1]},f.prototype.readUint32LE=f.prototype.readUInt32LE=function(e,t){return e>>>=0,t||N(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},f.prototype.readUint32BE=f.prototype.readUInt32BE=function(e,t){return e>>>=0,t||N(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},f.prototype.readBigUInt64LE=Z((function(e){z(e>>>=0,"offset");const t=this[e],r=this[e+7];void 0!==t&&void 0!==r||H(e,this.length-8);const n=t+256*this[++e]+65536*this[++e]+this[++e]*2**24,o=this[++e]+256*this[++e]+65536*this[++e]+r*2**24;return BigInt(n)+(BigInt(o)<<BigInt(32))})),f.prototype.readBigUInt64BE=Z((function(e){z(e>>>=0,"offset");const t=this[e],r=this[e+7];void 0!==t&&void 0!==r||H(e,this.length-8);const n=t*2**24+65536*this[++e]+256*this[++e]+this[++e],o=this[++e]*2**24+65536*this[++e]+256*this[++e]+r;return(BigInt(n)<<BigInt(32))+BigInt(o)})),f.prototype.readIntLE=function(e,t,r){e>>>=0,t>>>=0,r||N(e,t,this.length);let n=this[e],o=1,i=0;for(;++i<t&&(o*=256);)n+=this[e+i]*o;return o*=128,n>=o&&(n-=Math.pow(2,8*t)),n},f.prototype.readIntBE=function(e,t,r){e>>>=0,t>>>=0,r||N(e,t,this.length);let n=t,o=1,i=this[e+--n];for(;n>0&&(o*=256);)i+=this[e+--n]*o;return o*=128,i>=o&&(i-=Math.pow(2,8*t)),i},f.prototype.readInt8=function(e,t){return e>>>=0,t||N(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},f.prototype.readInt16LE=function(e,t){e>>>=0,t||N(e,2,this.length);const r=this[e]|this[e+1]<<8;return 32768&r?4294901760|r:r},f.prototype.readInt16BE=function(e,t){e>>>=0,t||N(e,2,this.length);const r=this[e+1]|this[e]<<8;return 32768&r?4294901760|r:r},f.prototype.readInt32LE=function(e,t){return e>>>=0,t||N(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},f.prototype.readInt32BE=function(e,t){return e>>>=0,t||N(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},f.prototype.readBigInt64LE=Z((function(e){z(e>>>=0,"offset");const t=this[e],r=this[e+7];void 0!==t&&void 0!==r||H(e,this.length-8);const n=this[e+4]+256*this[e+5]+65536*this[e+6]+(r<<24);return(BigInt(n)<<BigInt(32))+BigInt(t+256*this[++e]+65536*this[++e]+this[++e]*2**24)})),f.prototype.readBigInt64BE=Z((function(e){z(e>>>=0,"offset");const t=this[e],r=this[e+7];void 0!==t&&void 0!==r||H(e,this.length-8);const n=(t<<24)+65536*this[++e]+256*this[++e]+this[++e];return(BigInt(n)<<BigInt(32))+BigInt(this[++e]*2**24+65536*this[++e]+256*this[++e]+r)})),f.prototype.readFloatLE=function(e,t){return e>>>=0,t||N(e,4,this.length),o.read(this,e,!0,23,4)},f.prototype.readFloatBE=function(e,t){return e>>>=0,t||N(e,4,this.length),o.read(this,e,!1,23,4)},f.prototype.readDoubleLE=function(e,t){return e>>>=0,t||N(e,8,this.length),o.read(this,e,!0,52,8)},f.prototype.readDoubleBE=function(e,t){return e>>>=0,t||N(e,8,this.length),o.read(this,e,!1,52,8)},f.prototype.writeUintLE=f.prototype.writeUIntLE=function(e,t,r,n){e=+e,t>>>=0,r>>>=0,n||x(this,e,t,r,Math.pow(2,8*r)-1,0);let o=1,i=0;for(this[t]=255&e;++i<r&&(o*=256);)this[t+i]=e/o&255;return t+r},f.prototype.writeUintBE=f.prototype.writeUIntBE=function(e,t,r,n){e=+e,t>>>=0,r>>>=0,n||x(this,e,t,r,Math.pow(2,8*r)-1,0);let o=r-1,i=1;for(this[t+o]=255&e;--o>=0&&(i*=256);)this[t+o]=e/i&255;return t+r},f.prototype.writeUint8=f.prototype.writeUInt8=function(e,t,r){return e=+e,t>>>=0,r||x(this,e,t,1,255,0),this[t]=255&e,t+1},f.prototype.writeUint16LE=f.prototype.writeUInt16LE=function(e,t,r){return e=+e,t>>>=0,r||x(this,e,t,2,65535,0),this[t]=255&e,this[t+1]=e>>>8,t+2},f.prototype.writeUint16BE=f.prototype.writeUInt16BE=function(e,t,r){return e=+e,t>>>=0,r||x(this,e,t,2,65535,0),this[t]=e>>>8,this[t+1]=255&e,t+2},f.prototype.writeUint32LE=f.prototype.writeUInt32LE=function(e,t,r){return e=+e,t>>>=0,r||x(this,e,t,4,4294967295,0),this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e,t+4},f.prototype.writeUint32BE=f.prototype.writeUInt32BE=function(e,t,r){return e=+e,t>>>=0,r||x(this,e,t,4,4294967295,0),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},f.prototype.writeBigUInt64LE=Z((function(e,t=0){return F(this,e,t,BigInt(0),BigInt("0xffffffffffffffff"))})),f.prototype.writeBigUInt64BE=Z((function(e,t=0){return M(this,e,t,BigInt(0),BigInt("0xffffffffffffffff"))})),f.prototype.writeIntLE=function(e,t,r,n){if(e=+e,t>>>=0,!n){const n=Math.pow(2,8*r-1);x(this,e,t,r,n-1,-n)}let o=0,i=1,a=0;for(this[t]=255&e;++o<r&&(i*=256);)e<0&&0===a&&0!==this[t+o-1]&&(a=1),this[t+o]=(e/i>>0)-a&255;return t+r},f.prototype.writeIntBE=function(e,t,r,n){if(e=+e,t>>>=0,!n){const n=Math.pow(2,8*r-1);x(this,e,t,r,n-1,-n)}let o=r-1,i=1,a=0;for(this[t+o]=255&e;--o>=0&&(i*=256);)e<0&&0===a&&0!==this[t+o+1]&&(a=1),this[t+o]=(e/i>>0)-a&255;return t+r},f.prototype.writeInt8=function(e,t,r){return e=+e,t>>>=0,r||x(this,e,t,1,127,-128),e<0&&(e=255+e+1),this[t]=255&e,t+1},f.prototype.writeInt16LE=function(e,t,r){return e=+e,t>>>=0,r||x(this,e,t,2,32767,-32768),this[t]=255&e,this[t+1]=e>>>8,t+2},f.prototype.writeInt16BE=function(e,t,r){return e=+e,t>>>=0,r||x(this,e,t,2,32767,-32768),this[t]=e>>>8,this[t+1]=255&e,t+2},f.prototype.writeInt32LE=function(e,t,r){return e=+e,t>>>=0,r||x(this,e,t,4,2147483647,-2147483648),this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24,t+4},f.prototype.writeInt32BE=function(e,t,r){return e=+e,t>>>=0,r||x(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},f.prototype.writeBigInt64LE=Z((function(e,t=0){return F(this,e,t,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))})),f.prototype.writeBigInt64BE=Z((function(e,t=0){return M(this,e,t,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))})),f.prototype.writeFloatLE=function(e,t,r){return L(this,e,t,!0,r)},f.prototype.writeFloatBE=function(e,t,r){return L(this,e,t,!1,r)},f.prototype.writeDoubleLE=function(e,t,r){return P(this,e,t,!0,r)},f.prototype.writeDoubleBE=function(e,t,r){return P(this,e,t,!1,r)},f.prototype.copy=function(e,t,r,n){if(!f.isBuffer(e))throw new TypeError("argument should be a Buffer");if(r||(r=0),n||0===n||(n=this.length),t>=e.length&&(t=e.length),t||(t=0),n>0&&n<r&&(n=r),n===r)return 0;if(0===e.length||0===this.length)return 0;if(t<0)throw new RangeError("targetStart out of bounds");if(r<0||r>=this.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("sourceEnd out of bounds");n>this.length&&(n=this.length),e.length-t<n-r&&(n=e.length-t+r);const o=n-r;return this===e&&"function"==typeof Uint8Array.prototype.copyWithin?this.copyWithin(t,r,n):Uint8Array.prototype.set.call(e,this.subarray(r,n),t),o},f.prototype.fill=function(e,t,r,n){if("string"==typeof e){if("string"==typeof t?(n=t,t=0,r=this.length):"string"==typeof r&&(n=r,r=this.length),void 0!==n&&"string"!=typeof n)throw new TypeError("encoding must be a string");if("string"==typeof n&&!f.isEncoding(n))throw new TypeError("Unknown encoding: "+n);if(1===e.length){const t=e.charCodeAt(0);("utf8"===n&&t<128||"latin1"===n)&&(e=t)}}else"number"==typeof e?e&=255:"boolean"==typeof e&&(e=Number(e));if(t<0||this.length<t||this.length<r)throw new RangeError("Out of range index");if(r<=t)return this;let o;if(t>>>=0,r=void 0===r?this.length:r>>>0,e||(e=0),"number"==typeof e)for(o=t;o<r;++o)this[o]=e;else{const i=f.isBuffer(e)?e:f.from(e,n),a=i.length;if(0===a)throw new TypeError('The value "'+e+'" is invalid for argument "value"');for(o=0;o<r-t;++o)this[o+t]=i[o%a]}return this};const U={};function T(e,t,r){U[e]=class extends r{constructor(){super(),Object.defineProperty(this,"message",{value:t.apply(this,arguments),writable:!0,configurable:!0}),this.name=`${this.name} [${e}]`,this.stack,delete this.name}get code(){return e}set code(e){Object.defineProperty(this,"code",{configurable:!0,enumerable:!0,value:e,writable:!0})}toString(){return`${this.name} [${e}]: ${this.message}`}}}function q(e){let t="",r=e.length;const 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 j(e,t,r,n,o,i){if(e>r||e<t){const n="bigint"==typeof t?"n":"";let o;throw o=i>3?0===t||t===BigInt(0)?`>= 0${n} and < 2${n} ** ${8*(i+1)}${n}`:`>= -(2${n} ** ${8*(i+1)-1}${n}) and < 2 ** ${8*(i+1)-1}${n}`:`>= ${t}${n} and <= ${r}${n}`,new U.ERR_OUT_OF_RANGE("value",o,e)}!function(e,t,r){z(t,"offset"),void 0!==e[t]&&void 0!==e[t+r]||H(t,e.length-(r+1))}(n,o,i)}function z(e,t){if("number"!=typeof e)throw new U.ERR_INVALID_ARG_TYPE(t,"number",e)}function H(e,t,r){if(Math.floor(e)!==e)throw z(e,r),new U.ERR_OUT_OF_RANGE(r||"offset","an integer",e);if(t<0)throw new U.ERR_BUFFER_OUT_OF_BOUNDS;throw new U.ERR_OUT_OF_RANGE(r||"offset",`>= ${r?1:0} and <= ${t}`,e)}T("ERR_BUFFER_OUT_OF_BOUNDS",(function(e){return e?`${e} is outside of buffer bounds`:"Attempt to access memory outside buffer bounds"}),RangeError),T("ERR_INVALID_ARG_TYPE",(function(e,t){return`The "${e}" argument must be of type number. Received type ${typeof t}`}),TypeError),T("ERR_OUT_OF_RANGE",(function(e,t,r){let n=`The value of "${e}" is out of range.`,o=r;return Number.isInteger(r)&&Math.abs(r)>2**32?o=q(String(r)):"bigint"==typeof r&&(o=String(r),(r>BigInt(2)**BigInt(32)||r<-(BigInt(2)**BigInt(32)))&&(o=q(o)),o+="n"),n+=` It must be ${t}. Received ${o}`,n}),RangeError);const G=/[^+/0-9A-Za-z-_]/g;function J(e,t){let r;t=t||1/0;const n=e.length;let o=null;const i=[];for(let a=0;a<n;++a){if(r=e.charCodeAt(a),r>55295&&r<57344){if(!o){if(r>56319){(t-=3)>-1&&i.push(239,191,189);continue}if(a+1===n){(t-=3)>-1&&i.push(239,191,189);continue}o=r;continue}if(r<56320){(t-=3)>-1&&i.push(239,191,189),o=r;continue}r=65536+(o-55296<<10|r-56320)}else o&&(t-=3)>-1&&i.push(239,191,189);if(o=null,r<128){if((t-=1)<0)break;i.push(r)}else if(r<2048){if((t-=2)<0)break;i.push(r>>6|192,63&r|128)}else if(r<65536){if((t-=3)<0)break;i.push(r>>12|224,r>>6&63|128,63&r|128)}else{if(!(r<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;i.push(r>>18|240,r>>12&63|128,r>>6&63|128,63&r|128)}}return i}function W(e){return n.toByteArray(function(e){if((e=(e=e.split("=")[0]).trim().replace(G,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function Y(e,t,r,n){let o;for(o=0;o<n&&!(o+r>=t.length||o>=e.length);++o)t[o+r]=e[o];return o}function K(e,t){return e instanceof t||null!=e&&null!=e.constructor&&null!=e.constructor.name&&e.constructor.name===t.name}function $(e){return e!=e}const V=function(){const e="0123456789abcdef",t=new Array(256);for(let r=0;r<16;++r){const n=16*r;for(let o=0;o<16;++o)t[n+o]=e[r]+e[o]}return t}();function Z(e){return"undefined"==typeof BigInt?X:e}function X(){throw new Error("BigInt not supported")}},235:e=>{var t={array:function(e){var t=0,r=0,n=[0,1,3,7,15,31,63,127,255];return function(o){for(var i=0;o>0;){var a=8-t;o>=a?(i<<=a,i|=n[a]&e[r++],t=0,o-=a):(i<<=o,i|=(e[r]&n[o]<<8-o-t)>>8-o-t,t+=o,o=0)}return i}},simple:function(e){var r,n,o=t.header(e),i=[],a=0;do{-1!=(n=t.decompress(e,o))&&(i.push(n),a+=n.byteLength)}while(-1!=n);r=new Uint8Array(a),a=0;for(var s=0;s<i.length;++s)n=i[s],r.set(n,a),a+=n.byteLength;return r},header:function(e){if(4348520!=e(24))throw"No magic number found";var t=e(8)-48;if(t<1||t>9)throw"Not a BZIP archive";return t},decompress:function(e,t,r){for(var n=9e5,o="",i=0;i<6;i++)o+=e(8).toString(16);if("177245385090"==o)return-1;if("314159265359"!=o)throw"eek not valid bzip data";if(e(32),e(1))throw"unsupported obsolete version";var a=e(24);if(a>n)throw"Initial position larger than buffer size";var s=e(16),f=new Uint8Array(256),l=0;for(i=0;i<16;i++)if(s&1<<15-i){var u=e(16);for(g=0;g<16;g++)u&1<<15-g&&(f[l++]=16*i+g)}var c=e(3);if(c<2||c>6)throw"another error";var A=e(15);if(0==A)throw"meh";var h=[];for(i=0;i<c;i++)h[i]=i;var d=new Uint8Array(32768);for(i=0;i<A;i++){for(var g=0;e(1);g++)if(g>=c)throw"whoops another error";var p=h[g];h.splice(g,1),h.splice(0,0,p),d[i]=p}var y=l+2,m=[];for(g=0;g<c;g++){var C,I,b,w=new Uint8Array(258),v=new Uint8Array(21);for(s=e(5),i=0;i<y;i++){for(;;){if(s<1||s>20)throw"I gave up a while ago on writing error messages";if(!e(1))break;e(1)?s--:s++}w[i]=s}for(C=I=w[0],i=1;i<y;i++)w[i]>I?I=w[i]:w[i]<C&&(C=w[i]);(b=m[g]={}).permute=new Uint32Array(258),b.limit=new Uint32Array(21),b.base=new Uint32Array(21),b.minLen=C,b.maxLen=I;var B=b.base.subarray(1),E=b.limit.subarray(1),_=0;for(i=C;i<=I;i++)for(s=0;s<y;s++)w[s]==i&&(b.permute[_++]=s);for(i=C;i<=I;i++)v[i]=E[i]=0;for(i=0;i<y;i++)v[w[i]]++;for(_=s=0,i=C;i<I;i++)_+=v[i],E[i]=_-1,_<<=1,B[i+1]=_-(s+=v[i]);E[I]=_+v[I]-1,B[C]=0}var Q,S,k,R=new Uint32Array(256);for(i=0;i<256;i++)h[i]=i;Q=S=y=k=0;for(var D=new Uint32Array(n);;){if(!y--){if(y=49,k>=A)throw"meow i'm a kitty, that's an error";B=(b=m[d[k++]]).base.subarray(1),E=b.limit.subarray(1)}for(g=e(i=b.minLen);;){if(i>b.maxLen)throw"rawr i'm a dinosaur";if(g<=E[i])break;i++,g=g<<1|e(1)}if((g-=B[i])<0||g>=258)throw"moo i'm a cow";var N=b.permute[g];if(0!=N&&1!=N){if(Q){if(Q=0,S+s>=n)throw"Boom.";for(R[p=f[h[0]]]+=s;s--;)D[S++]=p}if(N>l)break;if(S>=n)throw"I can't think of anything. Error";p=h[i=N-1],h.splice(i,1),h.splice(0,0,p),R[p=f[p]]++,D[S++]=p}else Q||(Q=1,s=0),s+=0==N?Q:2*Q,Q<<=1}if(a<0||a>=S)throw"I'm a monkey and I'm throwing something at someone, namely you";for(g=0,i=0;i<256;i++)u=g+R[i],R[i]=g,g=u;for(i=0;i<S;i++)D[R[p=255&D[i]]]|=i<<8,R[p]++;var x=0,F=0,M=0;S&&(F=255&(x=D[a]),x>>=8,M=-1);var O,L,P,U=new Uint8Array(n),T=0;for(r||(r=1/0);S;){for(S--,L=F,F=255&(x=D[x]),x>>=8,3==M++?(O=F,P=L,F=-1):(O=1,P=F);O--;)if(U[T++]=P,! --r)return U;F!=L&&(M=0)}return U.subarray(0,T)}};e.exports=t},8075:(e,t,r)=>{"use strict";var n=r(453),o=r(487),i=o(n("String.prototype.indexOf"));e.exports=function(e,t){var r=n(e,!!t);return"function"==typeof r&&i(e,".prototype.")>-1?o(r):r}},487:(e,t,r)=>{"use strict";var n=r(6743),o=r(453),i=r(6897),a=r(9675),s=o("%Function.prototype.apply%"),f=o("%Function.prototype.call%"),l=o("%Reflect.apply%",!0)||n.call(f,s),u=r(655),c=o("%Math.max%");e.exports=function(e){if("function"!=typeof e)throw new a("a function is required");var t=l(n,f,arguments);return i(t,1+c(0,e.length-(arguments.length-1)),!0)};var A=function(){return l(n,s,arguments)};u?u(e.exports,"apply",{value:A}):e.exports.apply=A},2151:e=>{var t={utf8:{stringToBytes:function(e){return t.bin.stringToBytes(unescape(encodeURIComponent(e)))},bytesToString:function(e){return decodeURIComponent(escape(t.bin.bytesToString(e)))}},bin:{stringToBytes:function(e){for(var t=[],r=0;r<e.length;r++)t.push(255&e.charCodeAt(r));return t},bytesToString:function(e){for(var t=[],r=0;r<e.length;r++)t.push(String.fromCharCode(e[r]));return t.join("")}}};e.exports=t},3939:e=>{var t,r;t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",r={rotl:function(e,t){return e<<t|e>>>32-t},rotr:function(e,t){return e<<32-t|e>>>t},endian:function(e){if(e.constructor==Number)return 16711935&r.rotl(e,8)|4278255360&r.rotl(e,24);for(var t=0;t<e.length;t++)e[t]=r.endian(e[t]);return e},randomBytes:function(e){for(var t=[];e>0;e--)t.push(Math.floor(256*Math.random()));return t},bytesToWords:function(e){for(var t=[],r=0,n=0;r<e.length;r++,n+=8)t[n>>>5]|=e[r]<<24-n%32;return t},wordsToBytes:function(e){for(var t=[],r=0;r<32*e.length;r+=8)t.push(e[r>>>5]>>>24-r%32&255);return t},bytesToHex:function(e){for(var t=[],r=0;r<e.length;r++)t.push((e[r]>>>4).toString(16)),t.push((15&e[r]).toString(16));return t.join("")},hexToBytes:function(e){for(var t=[],r=0;r<e.length;r+=2)t.push(parseInt(e.substr(r,2),16));return t},bytesToBase64:function(e){for(var r=[],n=0;n<e.length;n+=3)for(var o=e[n]<<16|e[n+1]<<8|e[n+2],i=0;i<4;i++)8*n+6*i<=8*e.length?r.push(t.charAt(o>>>6*(3-i)&63)):r.push("=");return r.join("")},base64ToBytes:function(e){e=e.replace(/[^A-Z0-9+\/]/gi,"");for(var r=[],n=0,o=0;n<e.length;o=++n%4)0!=o&&r.push((t.indexOf(e.charAt(n-1))&Math.pow(2,-2*o+8)-1)<<2*o|t.indexOf(e.charAt(n))>>>6-2*o);return r}},e.exports=r},41:(e,t,r)=>{"use strict";var n=r(655),o=r(8068),i=r(9675),a=r(5795);e.exports=function(e,t,r){if(!e||"object"!=typeof e&&"function"!=typeof e)throw new i("`obj` must be an object or a function`");if("string"!=typeof t&&"symbol"!=typeof t)throw new i("`property` must be a string or a symbol`");if(arguments.length>3&&"boolean"!=typeof arguments[3]&&null!==arguments[3])throw new i("`nonEnumerable`, if provided, must be a boolean or null");if(arguments.length>4&&"boolean"!=typeof arguments[4]&&null!==arguments[4])throw new i("`nonWritable`, if provided, must be a boolean or null");if(arguments.length>5&&"boolean"!=typeof arguments[5]&&null!==arguments[5])throw new i("`nonConfigurable`, if provided, must be a boolean or null");if(arguments.length>6&&"boolean"!=typeof arguments[6])throw new i("`loose`, if provided, must be a boolean");var s=arguments.length>3?arguments[3]:null,f=arguments.length>4?arguments[4]:null,l=arguments.length>5?arguments[5]:null,u=arguments.length>6&&arguments[6],c=!!a&&a(e,t);if(n)n(e,t,{configurable:null===l&&c?c.configurable:!l,enumerable:null===s&&c?c.enumerable:!s,value:r,writable:null===f&&c?c.writable:!f});else{if(!u&&(s||f||l))throw new o("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable.");e[t]=r}}},655:(e,t,r)=>{"use strict";var n=r(453)("%Object.defineProperty%",!0)||!1;if(n)try{n({},"a",{value:1})}catch(e){n=!1}e.exports=n},1237:e=>{"use strict";e.exports=EvalError},9383:e=>{"use strict";e.exports=Error},9290:e=>{"use strict";e.exports=RangeError},9538:e=>{"use strict";e.exports=ReferenceError},8068:e=>{"use strict";e.exports=SyntaxError},9675:e=>{"use strict";e.exports=TypeError},5345:e=>{"use strict";e.exports=URIError},9353:e=>{"use strict";var t=Object.prototype.toString,r=Math.max,n=function(e,t){for(var r=[],n=0;n<e.length;n+=1)r[n]=e[n];for(var o=0;o<t.length;o+=1)r[o+e.length]=t[o];return r};e.exports=function(e){var o=this;if("function"!=typeof o||"[object Function]"!==t.apply(o))throw new TypeError("Function.prototype.bind called on incompatible "+o);for(var i,a=function(e,t){for(var r=[],n=1,o=0;n<e.length;n+=1,o+=1)r[o]=e[n];return r}(arguments),s=r(0,o.length-a.length),f=[],l=0;l<s;l++)f[l]="$"+l;if(i=Function("binder","return function ("+function(e,t){for(var r="",n=0;n<e.length;n+=1)r+=e[n],n+1<e.length&&(r+=",");return r}(f)+"){ return binder.apply(this,arguments); }")((function(){if(this instanceof i){var t=o.apply(this,n(a,arguments));return Object(t)===t?t:this}return o.apply(e,n(a,arguments))})),o.prototype){var u=function(){};u.prototype=o.prototype,i.prototype=new u,u.prototype=null}return i}},6743:(e,t,r)=>{"use strict";var n=r(9353);e.exports=Function.prototype.bind||n},1113:(e,t,r)=>{"use strict";r.r(t),r.d(t,{BlobFile:()=>f,LocalFile:()=>o(),RemoteFile:()=>a,fromUrl:()=>l,open:()=>u});var n=r(3617),o=r.n(n),i=r(8287);class a{async getBufferFromResponse(e){if("function"==typeof e.buffer)return e.buffer();if("function"==typeof e.arrayBuffer){const t=await e.arrayBuffer();return i.Buffer.from(t)}throw new TypeError("invalid HTTP response object, has no buffer method, and no arrayBuffer method")}constructor(e,t={}){this.baseOverrides={},this.url=e;const r=t.fetch||globalThis.fetch.bind(globalThis);if(!r)throw new TypeError("no fetch function supplied, and none found in global environment");t.overrides&&(this.baseOverrides=t.overrides),this.fetchImplementation=r}async fetch(e,t){let r;try{r=await this.fetchImplementation(e,t)}catch(n){if(!`${n}`.includes("Failed to fetch"))throw n;console.warn(`generic-filehandle: refetching ${e} to attempt to work around chrome CORS header caching bug`),r=await this.fetchImplementation(e,{...t,cache:"reload"})}return r}async read(e,t=0,r,n=0,o={}){const{headers:i={},signal:a,overrides:s={}}=o;r<1/0?i.range=`bytes=${n}-${n+r}`:r===1/0&&0!==n&&(i.range=`bytes=${n}-`);const f={...this.baseOverrides,...s,headers:{...i,...s.headers,...this.baseOverrides.headers},method:"GET",redirect:"follow",mode:"cors",signal:a},l=await this.fetch(this.url,f);if(!l.ok)throw new Error(`HTTP ${l.status} ${l.statusText} ${this.url}`);if(200===l.status&&0===n||206===l.status){const n=await this.getBufferFromResponse(l),o=n.copy(e,t,0,Math.min(r,n.length)),i=l.headers.get("content-range"),a=/\/(\d+)$/.exec(i||"");return a&&a[1]&&(this._stat={size:parseInt(a[1],10)}),{bytesRead:o,buffer:e}}if(200===l.status)throw new Error("${this.url} fetch returned status 200, expected 206");throw new Error(`HTTP ${l.status} fetching ${this.url}`)}async readFile(e={}){let t,r;"string"==typeof e?(t=e,r={}):(t=e.encoding,r=e,delete r.encoding);const{headers:n={},signal:o,overrides:i={}}=r,a={headers:n,method:"GET",redirect:"follow",mode:"cors",signal:o,...this.baseOverrides,...i},s=await this.fetch(this.url,a);if(!s)throw new Error("generic-filehandle failed to fetch");if(200!==s.status)throw Object.assign(new Error(`HTTP ${s.status} fetching ${this.url}`),{status:s.status});if("utf8"===t)return s.text();if(t)throw new Error(`unsupported encoding: ${t}`);return this.getBufferFromResponse(s)}async stat(){if(!this._stat){const e=i.Buffer.allocUnsafe(10);if(await this.read(e,0,10,0),!this._stat)throw new Error(`unable to determine size of file at ${this.url}`)}return this._stat}async close(){}}function s(e){const t=new FileReader;return new Promise(((r,n)=>{t.onerror=()=>{t.abort(),n(new Error("problem reading blob"))},t.onabort=()=>{n(new Error("blob reading was aborted"))},t.onload=()=>{t.result&&"string"!=typeof t.result?r(t.result):n(new Error("unknown error reading blob"))},t.readAsArrayBuffer(e)}))}class f{constructor(e){this.blob=e,this.size=e.size}async read(e,t=0,r,n=0){if(!r)return{bytesRead:0,buffer:e};const o=n,a=o+r,f=await s(this.blob.slice(o,a)),l=i.Buffer.from(f);return{bytesRead:l.copy(e,t),buffer:l}}async readFile(e){let t;if(t="string"==typeof e?e:e&&e.encoding,"utf8"===t)return function(e){const t=new FileReader;return new Promise(((r,n)=>{t.onerror=()=>{t.abort(),n(new Error("problem reading blob"))},t.onabort=()=>{n(new Error("blob reading was aborted"))},t.onload=()=>{t.result&&"string"==typeof t.result?r(t.result):n(new Error("unknown error reading blob"))},t.readAsText(e)}))}(this.blob);if(t)throw new Error(`unsupported encoding: ${t}`);const r=await s(this.blob);return i.Buffer.from(r)}async stat(){return{size:this.size}}async close(){}}function l(e,t={}){return new a(e,t)}function u(e,t,r,n={}){if(void 0!==r)return r;if(void 0!==e)return l(e,n);if(void 0!==t)return new(o())(t,n);throw new Error("no url, path, or filehandle provided, cannot open")}},453:(e,t,r)=>{"use strict";var n,o=r(9383),i=r(1237),a=r(9290),s=r(9538),f=r(8068),l=r(9675),u=r(5345),c=Function,A=function(e){try{return c('"use strict"; return ('+e+").constructor;")()}catch(e){}},h=Object.getOwnPropertyDescriptor;if(h)try{h({},"")}catch(e){h=null}var d=function(){throw new l},g=h?function(){try{return d}catch(e){try{return h(arguments,"callee").get}catch(e){return d}}}():d,p=r(4039)(),y=r(24)(),m=Object.getPrototypeOf||(y?function(e){return e.__proto__}:null),C={},I="undefined"!=typeof Uint8Array&&m?m(Uint8Array):n,b={__proto__:null,"%AggregateError%":"undefined"==typeof AggregateError?n:AggregateError,"%Array%":Array,"%ArrayBuffer%":"undefined"==typeof ArrayBuffer?n:ArrayBuffer,"%ArrayIteratorPrototype%":p&&m?m([][Symbol.iterator]()):n,"%AsyncFromSyncIteratorPrototype%":n,"%AsyncFunction%":C,"%AsyncGenerator%":C,"%AsyncGeneratorFunction%":C,"%AsyncIteratorPrototype%":C,"%Atomics%":"undefined"==typeof Atomics?n:Atomics,"%BigInt%":"undefined"==typeof BigInt?n:BigInt,"%BigInt64Array%":"undefined"==typeof BigInt64Array?n:BigInt64Array,"%BigUint64Array%":"undefined"==typeof BigUint64Array?n:BigUint64Array,"%Boolean%":Boolean,"%DataView%":"undefined"==typeof DataView?n:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":o,"%eval%":eval,"%EvalError%":i,"%Float32Array%":"undefined"==typeof Float32Array?n:Float32Array,"%Float64Array%":"undefined"==typeof Float64Array?n:Float64Array,"%FinalizationRegistry%":"undefined"==typeof FinalizationRegistry?n:FinalizationRegistry,"%Function%":c,"%GeneratorFunction%":C,"%Int8Array%":"undefined"==typeof Int8Array?n:Int8Array,"%Int16Array%":"undefined"==typeof Int16Array?n:Int16Array,"%Int32Array%":"undefined"==typeof Int32Array?n:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":p&&m?m(m([][Symbol.iterator]())):n,"%JSON%":"object"==typeof JSON?JSON:n,"%Map%":"undefined"==typeof Map?n:Map,"%MapIteratorPrototype%":"undefined"!=typeof Map&&p&&m?m((new Map)[Symbol.iterator]()):n,"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":"undefined"==typeof Promise?n:Promise,"%Proxy%":"undefined"==typeof Proxy?n:Proxy,"%RangeError%":a,"%ReferenceError%":s,"%Reflect%":"undefined"==typeof Reflect?n:Reflect,"%RegExp%":RegExp,"%Set%":"undefined"==typeof Set?n:Set,"%SetIteratorPrototype%":"undefined"!=typeof Set&&p&&m?m((new Set)[Symbol.iterator]()):n,"%SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?n:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":p&&m?m(""[Symbol.iterator]()):n,"%Symbol%":p?Symbol:n,"%SyntaxError%":f,"%ThrowTypeError%":g,"%TypedArray%":I,"%TypeError%":l,"%Uint8Array%":"undefined"==typeof Uint8Array?n:Uint8Array,"%Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?n:Uint8ClampedArray,"%Uint16Array%":"undefined"==typeof Uint16Array?n:Uint16Array,"%Uint32Array%":"undefined"==typeof Uint32Array?n:Uint32Array,"%URIError%":u,"%WeakMap%":"undefined"==typeof WeakMap?n:WeakMap,"%WeakRef%":"undefined"==typeof WeakRef?n:WeakRef,"%WeakSet%":"undefined"==typeof WeakSet?n:WeakSet};if(m)try{null.error}catch(e){var w=m(m(e));b["%Error.prototype%"]=w}var v=function e(t){var r;if("%AsyncFunction%"===t)r=A("async function () {}");else if("%GeneratorFunction%"===t)r=A("function* () {}");else if("%AsyncGeneratorFunction%"===t)r=A("async function* () {}");else if("%AsyncGenerator%"===t){var n=e("%AsyncGeneratorFunction%");n&&(r=n.prototype)}else if("%AsyncIteratorPrototype%"===t){var o=e("%AsyncGenerator%");o&&m&&(r=m(o.prototype))}return b[t]=r,r},B={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},E=r(6743),_=r(9957),Q=E.call(Function.call,Array.prototype.concat),S=E.call(Function.apply,Array.prototype.splice),k=E.call(Function.call,String.prototype.replace),R=E.call(Function.call,String.prototype.slice),D=E.call(Function.call,RegExp.prototype.exec),N=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,x=/\\(\\)?/g,F=function(e,t){var r,n=e;if(_(B,n)&&(n="%"+(r=B[n])[0]+"%"),_(b,n)){var o=b[n];if(o===C&&(o=v(n)),void 0===o&&!t)throw new l("intrinsic "+e+" exists, but is not available. Please file an issue!");return{alias:r,name:n,value:o}}throw new f("intrinsic "+e+" does not exist!")};e.exports=function(e,t){if("string"!=typeof e||0===e.length)throw new l("intrinsic name must be a non-empty string");if(arguments.length>1&&"boolean"!=typeof t)throw new l('"allowMissing" argument must be a boolean');if(null===D(/^%?[^%]*%?$/,e))throw new f("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var r=function(e){var t=R(e,0,1),r=R(e,-1);if("%"===t&&"%"!==r)throw new f("invalid intrinsic syntax, expected closing `%`");if("%"===r&&"%"!==t)throw new f("invalid intrinsic syntax, expected opening `%`");var n=[];return k(e,N,(function(e,t,r,o){n[n.length]=r?k(o,x,"$1"):t||e})),n}(e),n=r.length>0?r[0]:"",o=F("%"+n+"%",t),i=o.name,a=o.value,s=!1,u=o.alias;u&&(n=u[0],S(r,Q([0,1],u)));for(var c=1,A=!0;c<r.length;c+=1){var d=r[c],g=R(d,0,1),p=R(d,-1);if(('"'===g||"'"===g||"`"===g||'"'===p||"'"===p||"`"===p)&&g!==p)throw new f("property names with quotes must have matching quotes");if("constructor"!==d&&A||(s=!0),_(b,i="%"+(n+="."+d)+"%"))a=b[i];else if(null!=a){if(!(d in a)){if(!t)throw new l("base intrinsic for "+e+" exists, but the property is not available.");return}if(h&&c+1>=r.length){var y=h(a,d);a=(A=!!y)&&"get"in y&&!("originalValue"in y.get)?y.get:a[d]}else A=_(a,d),a=a[d];A&&!s&&(b[i]=a)}}return a}},5795:(e,t,r)=>{"use strict";var n=r(453)("%Object.getOwnPropertyDescriptor%",!0);if(n)try{n([],"length")}catch(e){n=null}e.exports=n},592:(e,t,r)=>{"use strict";var n=r(655),o=function(){return!!n};o.hasArrayLengthDefineBug=function(){if(!n)return null;try{return 1!==n([],"length",{value:1}).length}catch(e){return!0}},e.exports=o},24:e=>{"use strict";var t={__proto__:null,foo:{}},r=Object;e.exports=function(){return{__proto__:t}.foo===t.foo&&!(t instanceof r)}},4039:(e,t,r)=>{"use strict";var n="undefined"!=typeof Symbol&&Symbol,o=r(1333);e.exports=function(){return"function"==typeof n&&"function"==typeof Symbol&&"symbol"==typeof n("foo")&&"symbol"==typeof Symbol("bar")&&o()}},1333:e=>{"use strict";e.exports=function(){if("function"!=typeof Symbol||"function"!=typeof Object.getOwnPropertySymbols)return!1;if("symbol"==typeof Symbol.iterator)return!0;var e={},t=Symbol("test"),r=Object(t);if("string"==typeof t)return!1;if("[object Symbol]"!==Object.prototype.toString.call(t))return!1;if("[object Symbol]"!==Object.prototype.toString.call(r))return!1;for(t in e[t]=42,e)return!1;if("function"==typeof Object.keys&&0!==Object.keys(e).length)return!1;if("function"==typeof Object.getOwnPropertyNames&&0!==Object.getOwnPropertyNames(e).length)return!1;var n=Object.getOwnPropertySymbols(e);if(1!==n.length||n[0]!==t)return!1;if(!Object.prototype.propertyIsEnumerable.call(e,t))return!1;if("function"==typeof Object.getOwnPropertyDescriptor){var o=Object.getOwnPropertyDescriptor(e,t);if(42!==o.value||!0!==o.enumerable)return!1}return!0}},9957:(e,t,r)=>{"use strict";var n=Function.prototype.call,o=Object.prototype.hasOwnProperty,i=r(6743);e.exports=i.call(n,o)},251:(e,t)=>{t.read=function(e,t,r,n,o){var i,a,s=8*o-n-1,f=(1<<s)-1,l=f>>1,u=-7,c=r?o-1:0,A=r?-1:1,h=e[t+c];for(c+=A,i=h&(1<<-u)-1,h>>=-u,u+=s;u>0;i=256*i+e[t+c],c+=A,u-=8);for(a=i&(1<<-u)-1,i>>=-u,u+=n;u>0;a=256*a+e[t+c],c+=A,u-=8);if(0===i)i=1-l;else{if(i===f)return a?NaN:1/0*(h?-1:1);a+=Math.pow(2,n),i-=l}return(h?-1:1)*a*Math.pow(2,i-n)},t.write=function(e,t,r,n,o,i){var a,s,f,l=8*i-o-1,u=(1<<l)-1,c=u>>1,A=23===o?Math.pow(2,-24)-Math.pow(2,-77):0,h=n?0:i-1,d=n?1:-1,g=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(s=isNaN(t)?1:0,a=u):(a=Math.floor(Math.log(t)/Math.LN2),t*(f=Math.pow(2,-a))<1&&(a--,f*=2),(t+=a+c>=1?A/f:A*Math.pow(2,1-c))*f>=2&&(a++,f/=2),a+c>=u?(s=0,a=u):a+c>=1?(s=(t*f-1)*Math.pow(2,o),a+=c):(s=t*Math.pow(2,c-1)*Math.pow(2,o),a=0));o>=8;e[r+h]=255&s,h+=d,s/=256,o-=8);for(a=a<<o|s,l+=o;l>0;e[r+h]=255&a,h+=d,a/=256,l-=8);e[r+h-d]|=128*g}},8570:e=>{e.exports=r;var t=null;try{t=new WebAssembly.Instance(new WebAssembly.Module(new Uint8Array([0,97,115,109,1,0,0,0,1,13,2,96,0,1,127,96,4,127,127,127,127,1,127,3,7,6,0,1,1,1,1,1,6,6,1,127,1,65,0,11,7,50,6,3,109,117,108,0,1,5,100,105,118,95,115,0,2,5,100,105,118,95,117,0,3,5,114,101,109,95,115,0,4,5,114,101,109,95,117,0,5,8,103,101,116,95,104,105,103,104,0,0,10,191,1,6,4,0,35,0,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,126,34,4,66,32,135,167,36,0,32,4,167,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,127,34,4,66,32,135,167,36,0,32,4,167,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,128,34,4,66,32,135,167,36,0,32,4,167,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,129,34,4,66,32,135,167,36,0,32,4,167,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,130,34,4,66,32,135,167,36,0,32,4,167,11])),{}).exports}catch(e){}function r(e,t,r){this.low=0|e,this.high=0|t,this.unsigned=!!r}function n(e){return!0===(e&&e.__isLong__)}r.prototype.__isLong__,Object.defineProperty(r.prototype,"__isLong__",{value:!0}),r.isLong=n;var o={},i={};function a(e,t){var r,n,a;return t?(a=0<=(e>>>=0)&&e<256)&&(n=i[e])?n:(r=f(e,(0|e)<0?-1:0,!0),a&&(i[e]=r),r):(a=-128<=(e|=0)&&e<128)&&(n=o[e])?n:(r=f(e,e<0?-1:0,!1),a&&(o[e]=r),r)}function s(e,t){if(isNaN(e))return t?y:p;if(t){if(e<0)return y;if(e>=h)return w}else{if(e<=-d)return v;if(e+1>=d)return b}return e<0?s(-e,t).neg():f(e%A|0,e/A|0,t)}function f(e,t,n){return new r(e,t,n)}r.fromInt=a,r.fromNumber=s,r.fromBits=f;var l=Math.pow;function u(e,t,r){if(0===e.length)throw Error("empty string");if("NaN"===e||"Infinity"===e||"+Infinity"===e||"-Infinity"===e)return p;if("number"==typeof t?(r=t,t=!1):t=!!t,(r=r||10)<2||36<r)throw RangeError("radix");var n;if((n=e.indexOf("-"))>0)throw Error("interior hyphen");if(0===n)return u(e.substring(1),t,r).neg();for(var o=s(l(r,8)),i=p,a=0;a<e.length;a+=8){var f=Math.min(8,e.length-a),c=parseInt(e.substring(a,a+f),r);if(f<8){var A=s(l(r,f));i=i.mul(A).add(s(c))}else i=(i=i.mul(o)).add(s(c))}return i.unsigned=t,i}function c(e,t){return"number"==typeof e?s(e,t):"string"==typeof e?u(e,t):f(e.low,e.high,"boolean"==typeof t?t:e.unsigned)}r.fromString=u,r.fromValue=c;var A=4294967296,h=A*A,d=h/2,g=a(1<<24),p=a(0);r.ZERO=p;var y=a(0,!0);r.UZERO=y;var m=a(1);r.ONE=m;var C=a(1,!0);r.UONE=C;var I=a(-1);r.NEG_ONE=I;var b=f(-1,2147483647,!1);r.MAX_VALUE=b;var w=f(-1,-1,!0);r.MAX_UNSIGNED_VALUE=w;var v=f(0,-2147483648,!1);r.MIN_VALUE=v;var B=r.prototype;B.toInt=function(){return this.unsigned?this.low>>>0:this.low},B.toNumber=function(){return this.unsigned?(this.high>>>0)*A+(this.low>>>0):this.high*A+(this.low>>>0)},B.toString=function(e){if((e=e||10)<2||36<e)throw RangeError("radix");if(this.isZero())return"0";if(this.isNegative()){if(this.eq(v)){var t=s(e),r=this.div(t),n=r.mul(t).sub(this);return r.toString(e)+n.toInt().toString(e)}return"-"+this.neg().toString(e)}for(var o=s(l(e,6),this.unsigned),i=this,a="";;){var f=i.div(o),u=(i.sub(f.mul(o)).toInt()>>>0).toString(e);if((i=f).isZero())return u+a;for(;u.length<6;)u="0"+u;a=""+u+a}},B.getHighBits=function(){return this.high},B.getHighBitsUnsigned=function(){return this.high>>>0},B.getLowBits=function(){return this.low},B.getLowBitsUnsigned=function(){return this.low>>>0},B.getNumBitsAbs=function(){if(this.isNegative())return this.eq(v)?64:this.neg().getNumBitsAbs();for(var e=0!=this.high?this.high:this.low,t=31;t>0&&0==(e&1<<t);t--);return 0!=this.high?t+33:t+1},B.isZero=function(){return 0===this.high&&0===this.low},B.eqz=B.isZero,B.isNegative=function(){return!this.unsigned&&this.high<0},B.isPositive=function(){return this.unsigned||this.high>=0},B.isOdd=function(){return 1==(1&this.low)},B.isEven=function(){return 0==(1&this.low)},B.equals=function(e){return n(e)||(e=c(e)),(this.unsigned===e.unsigned||this.high>>>31!=1||e.high>>>31!=1)&&this.high===e.high&&this.low===e.low},B.eq=B.equals,B.notEquals=function(e){return!this.eq(e)},B.neq=B.notEquals,B.ne=B.notEquals,B.lessThan=function(e){return this.comp(e)<0},B.lt=B.lessThan,B.lessThanOrEqual=function(e){return this.comp(e)<=0},B.lte=B.lessThanOrEqual,B.le=B.lessThanOrEqual,B.greaterThan=function(e){return this.comp(e)>0},B.gt=B.greaterThan,B.greaterThanOrEqual=function(e){return this.comp(e)>=0},B.gte=B.greaterThanOrEqual,B.ge=B.greaterThanOrEqual,B.compare=function(e){if(n(e)||(e=c(e)),this.eq(e))return 0;var t=this.isNegative(),r=e.isNegative();return t&&!r?-1:!t&&r?1:this.unsigned?e.high>>>0>this.high>>>0||e.high===this.high&&e.low>>>0>this.low>>>0?-1:1:this.sub(e).isNegative()?-1:1},B.comp=B.compare,B.negate=function(){return!this.unsigned&&this.eq(v)?v:this.not().add(m)},B.neg=B.negate,B.add=function(e){n(e)||(e=c(e));var t=this.high>>>16,r=65535&this.high,o=this.low>>>16,i=65535&this.low,a=e.high>>>16,s=65535&e.high,l=e.low>>>16,u=0,A=0,h=0,d=0;return h+=(d+=i+(65535&e.low))>>>16,A+=(h+=o+l)>>>16,u+=(A+=r+s)>>>16,u+=t+a,f((h&=65535)<<16|(d&=65535),(u&=65535)<<16|(A&=65535),this.unsigned)},B.subtract=function(e){return n(e)||(e=c(e)),this.add(e.neg())},B.sub=B.subtract,B.multiply=function(e){if(this.isZero())return p;if(n(e)||(e=c(e)),t)return f(t.mul(this.low,this.high,e.low,e.high),t.get_high(),this.unsigned);if(e.isZero())return p;if(this.eq(v))return e.isOdd()?v:p;if(e.eq(v))return this.isOdd()?v:p;if(this.isNegative())return e.isNegative()?this.neg().mul(e.neg()):this.neg().mul(e).neg();if(e.isNegative())return this.mul(e.neg()).neg();if(this.lt(g)&&e.lt(g))return s(this.toNumber()*e.toNumber(),this.unsigned);var r=this.high>>>16,o=65535&this.high,i=this.low>>>16,a=65535&this.low,l=e.high>>>16,u=65535&e.high,A=e.low>>>16,h=65535&e.low,d=0,y=0,m=0,C=0;return m+=(C+=a*h)>>>16,y+=(m+=i*h)>>>16,m&=65535,y+=(m+=a*A)>>>16,d+=(y+=o*h)>>>16,y&=65535,d+=(y+=i*A)>>>16,y&=65535,d+=(y+=a*u)>>>16,d+=r*h+o*A+i*u+a*l,f((m&=65535)<<16|(C&=65535),(d&=65535)<<16|(y&=65535),this.unsigned)},B.mul=B.multiply,B.divide=function(e){if(n(e)||(e=c(e)),e.isZero())throw Error("division by zero");var r,o,i;if(t)return this.unsigned||-2147483648!==this.high||-1!==e.low||-1!==e.high?f((this.unsigned?t.div_u:t.div_s)(this.low,this.high,e.low,e.high),t.get_high(),this.unsigned):this;if(this.isZero())return this.unsigned?y:p;if(this.unsigned){if(e.unsigned||(e=e.toUnsigned()),e.gt(this))return y;if(e.gt(this.shru(1)))return C;i=y}else{if(this.eq(v))return e.eq(m)||e.eq(I)?v:e.eq(v)?m:(r=this.shr(1).div(e).shl(1)).eq(p)?e.isNegative()?m:I:(o=this.sub(e.mul(r)),i=r.add(o.div(e)));if(e.eq(v))return this.unsigned?y:p;if(this.isNegative())return e.isNegative()?this.neg().div(e.neg()):this.neg().div(e).neg();if(e.isNegative())return this.div(e.neg()).neg();i=p}for(o=this;o.gte(e);){r=Math.max(1,Math.floor(o.toNumber()/e.toNumber()));for(var a=Math.ceil(Math.log(r)/Math.LN2),u=a<=48?1:l(2,a-48),A=s(r),h=A.mul(e);h.isNegative()||h.gt(o);)h=(A=s(r-=u,this.unsigned)).mul(e);A.isZero()&&(A=m),i=i.add(A),o=o.sub(h)}return i},B.div=B.divide,B.modulo=function(e){return n(e)||(e=c(e)),t?f((this.unsigned?t.rem_u:t.rem_s)(this.low,this.high,e.low,e.high),t.get_high(),this.unsigned):this.sub(this.div(e).mul(e))},B.mod=B.modulo,B.rem=B.modulo,B.not=function(){return f(~this.low,~this.high,this.unsigned)},B.and=function(e){return n(e)||(e=c(e)),f(this.low&e.low,this.high&e.high,this.unsigned)},B.or=function(e){return n(e)||(e=c(e)),f(this.low|e.low,this.high|e.high,this.unsigned)},B.xor=function(e){return n(e)||(e=c(e)),f(this.low^e.low,this.high^e.high,this.unsigned)},B.shiftLeft=function(e){return n(e)&&(e=e.toInt()),0==(e&=63)?this:e<32?f(this.low<<e,this.high<<e|this.low>>>32-e,this.unsigned):f(0,this.low<<e-32,this.unsigned)},B.shl=B.shiftLeft,B.shiftRight=function(e){return n(e)&&(e=e.toInt()),0==(e&=63)?this:e<32?f(this.low>>>e|this.high<<32-e,this.high>>e,this.unsigned):f(this.high>>e-32,this.high>=0?0:-1,this.unsigned)},B.shr=B.shiftRight,B.shiftRightUnsigned=function(e){if(n(e)&&(e=e.toInt()),0==(e&=63))return this;var t=this.high;return e<32?f(this.low>>>e|t<<32-e,t>>>e,this.unsigned):f(32===e?t:t>>>e-32,0,this.unsigned)},B.shru=B.shiftRightUnsigned,B.shr_u=B.shiftRightUnsigned,B.toSigned=function(){return this.unsigned?f(this.low,this.high,!1):this},B.toUnsigned=function(){return this.unsigned?this:f(this.low,this.high,!0)},B.toBytes=function(e){return e?this.toBytesLE():this.toBytesBE()},B.toBytesLE=function(){var e=this.high,t=this.low;return[255&t,t>>>8&255,t>>>16&255,t>>>24,255&e,e>>>8&255,e>>>16&255,e>>>24]},B.toBytesBE=function(){var e=this.high,t=this.low;return[e>>>24,e>>>16&255,e>>>8&255,255&e,t>>>24,t>>>16&255,t>>>8&255,255&t]},r.fromBytes=function(e,t,n){return n?r.fromBytesLE(e,t):r.fromBytesBE(e,t)},r.fromBytesLE=function(e,t){return new r(e[0]|e[1]<<8|e[2]<<16|e[3]<<24,e[4]|e[5]<<8|e[6]<<16|e[7]<<24,t)},r.fromBytesBE=function(e,t){return new r(e[4]<<24|e[5]<<16|e[6]<<8|e[7],e[0]<<24|e[1]<<16|e[2]<<8|e[3],t)}},3503:(e,t,r)=>{var n,o,i,a,s;n=r(3939),o=r(2151).utf8,i=r(652),a=r(2151).bin,(s=function(e,t){e.constructor==String?e=t&&"binary"===t.encoding?a.stringToBytes(e):o.stringToBytes(e):i(e)?e=Array.prototype.slice.call(e,0):Array.isArray(e)||e.constructor===Uint8Array||(e=e.toString());for(var r=n.bytesToWords(e),f=8*e.length,l=1732584193,u=-271733879,c=-1732584194,A=271733878,h=0;h<r.length;h++)r[h]=16711935&(r[h]<<8|r[h]>>>24)|4278255360&(r[h]<<24|r[h]>>>8);r[f>>>5]|=128<<f%32,r[14+(f+64>>>9<<4)]=f;var d=s._ff,g=s._gg,p=s._hh,y=s._ii;for(h=0;h<r.length;h+=16){var m=l,C=u,I=c,b=A;l=d(l,u,c,A,r[h+0],7,-680876936),A=d(A,l,u,c,r[h+1],12,-389564586),c=d(c,A,l,u,r[h+2],17,606105819),u=d(u,c,A,l,r[h+3],22,-1044525330),l=d(l,u,c,A,r[h+4],7,-176418897),A=d(A,l,u,c,r[h+5],12,1200080426),c=d(c,A,l,u,r[h+6],17,-1473231341),u=d(u,c,A,l,r[h+7],22,-45705983),l=d(l,u,c,A,r[h+8],7,1770035416),A=d(A,l,u,c,r[h+9],12,-1958414417),c=d(c,A,l,u,r[h+10],17,-42063),u=d(u,c,A,l,r[h+11],22,-1990404162),l=d(l,u,c,A,r[h+12],7,1804603682),A=d(A,l,u,c,r[h+13],12,-40341101),c=d(c,A,l,u,r[h+14],17,-1502002290),l=g(l,u=d(u,c,A,l,r[h+15],22,1236535329),c,A,r[h+1],5,-165796510),A=g(A,l,u,c,r[h+6],9,-1069501632),c=g(c,A,l,u,r[h+11],14,643717713),u=g(u,c,A,l,r[h+0],20,-373897302),l=g(l,u,c,A,r[h+5],5,-701558691),A=g(A,l,u,c,r[h+10],9,38016083),c=g(c,A,l,u,r[h+15],14,-660478335),u=g(u,c,A,l,r[h+4],20,-405537848),l=g(l,u,c,A,r[h+9],5,568446438),A=g(A,l,u,c,r[h+14],9,-1019803690),c=g(c,A,l,u,r[h+3],14,-187363961),u=g(u,c,A,l,r[h+8],20,1163531501),l=g(l,u,c,A,r[h+13],5,-1444681467),A=g(A,l,u,c,r[h+2],9,-51403784),c=g(c,A,l,u,r[h+7],14,1735328473),l=p(l,u=g(u,c,A,l,r[h+12],20,-1926607734),c,A,r[h+5],4,-378558),A=p(A,l,u,c,r[h+8],11,-2022574463),c=p(c,A,l,u,r[h+11],16,1839030562),u=p(u,c,A,l,r[h+14],23,-35309556),l=p(l,u,c,A,r[h+1],4,-1530992060),A=p(A,l,u,c,r[h+4],11,1272893353),c=p(c,A,l,u,r[h+7],16,-155497632),u=p(u,c,A,l,r[h+10],23,-1094730640),l=p(l,u,c,A,r[h+13],4,681279174),A=p(A,l,u,c,r[h+0],11,-358537222),c=p(c,A,l,u,r[h+3],16,-722521979),u=p(u,c,A,l,r[h+6],23,76029189),l=p(l,u,c,A,r[h+9],4,-640364487),A=p(A,l,u,c,r[h+12],11,-421815835),c=p(c,A,l,u,r[h+15],16,530742520),l=y(l,u=p(u,c,A,l,r[h+2],23,-995338651),c,A,r[h+0],6,-198630844),A=y(A,l,u,c,r[h+7],10,1126891415),c=y(c,A,l,u,r[h+14],15,-1416354905),u=y(u,c,A,l,r[h+5],21,-57434055),l=y(l,u,c,A,r[h+12],6,1700485571),A=y(A,l,u,c,r[h+3],10,-1894986606),c=y(c,A,l,u,r[h+10],15,-1051523),u=y(u,c,A,l,r[h+1],21,-2054922799),l=y(l,u,c,A,r[h+8],6,1873313359),A=y(A,l,u,c,r[h+15],10,-30611744),c=y(c,A,l,u,r[h+6],15,-1560198380),u=y(u,c,A,l,r[h+13],21,1309151649),l=y(l,u,c,A,r[h+4],6,-145523070),A=y(A,l,u,c,r[h+11],10,-1120210379),c=y(c,A,l,u,r[h+2],15,718787259),u=y(u,c,A,l,r[h+9],21,-343485551),l=l+m>>>0,u=u+C>>>0,c=c+I>>>0,A=A+b>>>0}return n.endian([l,u,c,A])})._ff=function(e,t,r,n,o,i,a){var s=e+(t&r|~t&n)+(o>>>0)+a;return(s<<i|s>>>32-i)+t},s._gg=function(e,t,r,n,o,i,a){var s=e+(t&n|r&~n)+(o>>>0)+a;return(s<<i|s>>>32-i)+t},s._hh=function(e,t,r,n,o,i,a){var s=e+(t^r^n)+(o>>>0)+a;return(s<<i|s>>>32-i)+t},s._ii=function(e,t,r,n,o,i,a){var s=e+(r^(t|~n))+(o>>>0)+a;return(s<<i|s>>>32-i)+t},s._blocksize=16,s._digestsize=16,e.exports=function(e,t){if(null==e)throw new Error("Illegal argument "+e);var r=n.wordsToBytes(s(e,t));return t&&t.asBytes?r:t&&t.asString?a.bytesToString(r):n.bytesToHex(r)}},652:e=>{function t(e){return!!e.constructor&&"function"==typeof e.constructor.isBuffer&&e.constructor.isBuffer(e)}e.exports=function(e){return null!=e&&(t(e)||function(e){return"function"==typeof e.readFloatLE&&"function"==typeof e.slice&&t(e.slice(0,0))}(e)||!!e._isBuffer)}},8859:(e,t,r)=>{var n="function"==typeof Map&&Map.prototype,o=Object.getOwnPropertyDescriptor&&n?Object.getOwnPropertyDescriptor(Map.prototype,"size"):null,i=n&&o&&"function"==typeof o.get?o.get:null,a=n&&Map.prototype.forEach,s="function"==typeof Set&&Set.prototype,f=Object.getOwnPropertyDescriptor&&s?Object.getOwnPropertyDescriptor(Set.prototype,"size"):null,l=s&&f&&"function"==typeof f.get?f.get:null,u=s&&Set.prototype.forEach,c="function"==typeof WeakMap&&WeakMap.prototype?WeakMap.prototype.has:null,A="function"==typeof WeakSet&&WeakSet.prototype?WeakSet.prototype.has:null,h="function"==typeof WeakRef&&WeakRef.prototype?WeakRef.prototype.deref:null,d=Boolean.prototype.valueOf,g=Object.prototype.toString,p=Function.prototype.toString,y=String.prototype.match,m=String.prototype.slice,C=String.prototype.replace,I=String.prototype.toUpperCase,b=String.prototype.toLowerCase,w=RegExp.prototype.test,v=Array.prototype.concat,B=Array.prototype.join,E=Array.prototype.slice,_=Math.floor,Q="function"==typeof BigInt?BigInt.prototype.valueOf:null,S=Object.getOwnPropertySymbols,k="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?Symbol.prototype.toString:null,R="function"==typeof Symbol&&"object"==typeof Symbol.iterator,D="function"==typeof Symbol&&Symbol.toStringTag&&(Symbol.toStringTag,1)?Symbol.toStringTag:null,N=Object.prototype.propertyIsEnumerable,x=("function"==typeof Reflect?Reflect.getPrototypeOf:Object.getPrototypeOf)||([].__proto__===Array.prototype?function(e){return e.__proto__}:null);function F(e,t){if(e===1/0||e===-1/0||e!=e||e&&e>-1e3&&e<1e3||w.call(/e/,t))return t;var r=/[0-9](?=(?:[0-9]{3})+(?![0-9]))/g;if("number"==typeof e){var n=e<0?-_(-e):_(e);if(n!==e){var o=String(n),i=m.call(t,o.length+1);return C.call(o,r,"$&_")+"."+C.call(C.call(i,/([0-9]{3})/g,"$&_"),/_$/,"")}}return C.call(t,r,"$&_")}var M=r(2634),O=M.custom,L=j(O)?O:null;function P(e,t,r){var n="double"===(r.quoteStyle||t)?'"':"'";return n+e+n}function U(e){return C.call(String(e),/"/g,"&quot;")}function T(e){return!("[object Array]"!==G(e)||D&&"object"==typeof e&&D in e)}function q(e){return!("[object RegExp]"!==G(e)||D&&"object"==typeof e&&D in e)}function j(e){if(R)return e&&"object"==typeof e&&e instanceof Symbol;if("symbol"==typeof e)return!0;if(!e||"object"!=typeof e||!k)return!1;try{return k.call(e),!0}catch(e){}return!1}e.exports=function e(t,n,o,s){var f=n||{};if(H(f,"quoteStyle")&&"single"!==f.quoteStyle&&"double"!==f.quoteStyle)throw new TypeError('option "quoteStyle" must be "single" or "double"');if(H(f,"maxStringLength")&&("number"==typeof f.maxStringLength?f.maxStringLength<0&&f.maxStringLength!==1/0:null!==f.maxStringLength))throw new TypeError('option "maxStringLength", if provided, must be a positive integer, Infinity, or `null`');var g=!H(f,"customInspect")||f.customInspect;if("boolean"!=typeof g&&"symbol"!==g)throw new TypeError("option \"customInspect\", if provided, must be `true`, `false`, or `'symbol'`");if(H(f,"indent")&&null!==f.indent&&"\t"!==f.indent&&!(parseInt(f.indent,10)===f.indent&&f.indent>0))throw new TypeError('option "indent" must be "\\t", an integer > 0, or `null`');if(H(f,"numericSeparator")&&"boolean"!=typeof f.numericSeparator)throw new TypeError('option "numericSeparator", if provided, must be `true` or `false`');var I=f.numericSeparator;if(void 0===t)return"undefined";if(null===t)return"null";if("boolean"==typeof t)return t?"true":"false";if("string"==typeof t)return W(t,f);if("number"==typeof t){if(0===t)return 1/0/t>0?"0":"-0";var w=String(t);return I?F(t,w):w}if("bigint"==typeof t){var _=String(t)+"n";return I?F(t,_):_}var S=void 0===f.depth?5:f.depth;if(void 0===o&&(o=0),o>=S&&S>0&&"object"==typeof t)return T(t)?"[Array]":"[Object]";var O,z=function(e,t){var r;if("\t"===e.indent)r="\t";else{if(!("number"==typeof e.indent&&e.indent>0))return null;r=B.call(Array(e.indent+1)," ")}return{base:r,prev:B.call(Array(t+1),r)}}(f,o);if(void 0===s)s=[];else if(J(s,t)>=0)return"[Circular]";function Y(t,r,n){if(r&&(s=E.call(s)).push(r),n){var i={depth:f.depth};return H(f,"quoteStyle")&&(i.quoteStyle=f.quoteStyle),e(t,i,o+1,s)}return e(t,f,o+1,s)}if("function"==typeof t&&!q(t)){var ee=function(e){if(e.name)return e.name;var t=y.call(p.call(e),/^function\s*([\w$]+)/);return t?t[1]:null}(t),te=X(t,Y);return"[Function"+(ee?": "+ee:" (anonymous)")+"]"+(te.length>0?" { "+B.call(te,", ")+" }":"")}if(j(t)){var re=R?C.call(String(t),/^(Symbol\(.*\))_[^)]*$/,"$1"):k.call(t);return"object"!=typeof t||R?re:K(re)}if((O=t)&&"object"==typeof O&&("undefined"!=typeof HTMLElement&&O instanceof HTMLElement||"string"==typeof O.nodeName&&"function"==typeof O.getAttribute)){for(var ne="<"+b.call(String(t.nodeName)),oe=t.attributes||[],ie=0;ie<oe.length;ie++)ne+=" "+oe[ie].name+"="+P(U(oe[ie].value),"double",f);return ne+=">",t.childNodes&&t.childNodes.length&&(ne+="..."),ne+"</"+b.call(String(t.nodeName))+">"}if(T(t)){if(0===t.length)return"[]";var ae=X(t,Y);return z&&!function(e){for(var t=0;t<e.length;t++)if(J(e[t],"\n")>=0)return!1;return!0}(ae)?"["+Z(ae,z)+"]":"[ "+B.call(ae,", ")+" ]"}if(function(e){return!("[object Error]"!==G(e)||D&&"object"==typeof e&&D in e)}(t)){var se=X(t,Y);return"cause"in Error.prototype||!("cause"in t)||N.call(t,"cause")?0===se.length?"["+String(t)+"]":"{ ["+String(t)+"] "+B.call(se,", ")+" }":"{ ["+String(t)+"] "+B.call(v.call("[cause]: "+Y(t.cause),se),", ")+" }"}if("object"==typeof t&&g){if(L&&"function"==typeof t[L]&&M)return M(t,{depth:S-o});if("symbol"!==g&&"function"==typeof t.inspect)return t.inspect()}if(function(e){if(!i||!e||"object"!=typeof e)return!1;try{i.call(e);try{l.call(e)}catch(e){return!0}return e instanceof Map}catch(e){}return!1}(t)){var fe=[];return a&&a.call(t,(function(e,r){fe.push(Y(r,t,!0)+" => "+Y(e,t))})),V("Map",i.call(t),fe,z)}if(function(e){if(!l||!e||"object"!=typeof e)return!1;try{l.call(e);try{i.call(e)}catch(e){return!0}return e instanceof Set}catch(e){}return!1}(t)){var le=[];return u&&u.call(t,(function(e){le.push(Y(e,t))})),V("Set",l.call(t),le,z)}if(function(e){if(!c||!e||"object"!=typeof e)return!1;try{c.call(e,c);try{A.call(e,A)}catch(e){return!0}return e instanceof WeakMap}catch(e){}return!1}(t))return $("WeakMap");if(function(e){if(!A||!e||"object"!=typeof e)return!1;try{A.call(e,A);try{c.call(e,c)}catch(e){return!0}return e instanceof WeakSet}catch(e){}return!1}(t))return $("WeakSet");if(function(e){if(!h||!e||"object"!=typeof e)return!1;try{return h.call(e),!0}catch(e){}return!1}(t))return $("WeakRef");if(function(e){return!("[object Number]"!==G(e)||D&&"object"==typeof e&&D in e)}(t))return K(Y(Number(t)));if(function(e){if(!e||"object"!=typeof e||!Q)return!1;try{return Q.call(e),!0}catch(e){}return!1}(t))return K(Y(Q.call(t)));if(function(e){return!("[object Boolean]"!==G(e)||D&&"object"==typeof e&&D in e)}(t))return K(d.call(t));if(function(e){return!("[object String]"!==G(e)||D&&"object"==typeof e&&D in e)}(t))return K(Y(String(t)));if("undefined"!=typeof window&&t===window)return"{ [object Window] }";if(t===r.g)return"{ [object globalThis] }";if(!function(e){return!("[object Date]"!==G(e)||D&&"object"==typeof e&&D in e)}(t)&&!q(t)){var ue=X(t,Y),ce=x?x(t)===Object.prototype:t instanceof Object||t.constructor===Object,Ae=t instanceof Object?"":"null prototype",he=!ce&&D&&Object(t)===t&&D in t?m.call(G(t),8,-1):Ae?"Object":"",de=(ce||"function"!=typeof t.constructor?"":t.constructor.name?t.constructor.name+" ":"")+(he||Ae?"["+B.call(v.call([],he||[],Ae||[]),": ")+"] ":"");return 0===ue.length?de+"{}":z?de+"{"+Z(ue,z)+"}":de+"{ "+B.call(ue,", ")+" }"}return String(t)};var z=Object.prototype.hasOwnProperty||function(e){return e in this};function H(e,t){return z.call(e,t)}function G(e){return g.call(e)}function J(e,t){if(e.indexOf)return e.indexOf(t);for(var r=0,n=e.length;r<n;r++)if(e[r]===t)return r;return-1}function W(e,t){if(e.length>t.maxStringLength){var r=e.length-t.maxStringLength,n="... "+r+" more character"+(r>1?"s":"");return W(m.call(e,0,t.maxStringLength),t)+n}return P(C.call(C.call(e,/(['\\])/g,"\\$1"),/[\x00-\x1f]/g,Y),"single",t)}function Y(e){var t=e.charCodeAt(0),r={8:"b",9:"t",10:"n",12:"f",13:"r"}[t];return r?"\\"+r:"\\x"+(t<16?"0":"")+I.call(t.toString(16))}function K(e){return"Object("+e+")"}function $(e){return e+" { ? }"}function V(e,t,r,n){return e+" ("+t+") {"+(n?Z(r,n):B.call(r,", "))+"}"}function Z(e,t){if(0===e.length)return"";var r="\n"+t.prev+t.base;return r+B.call(e,","+r)+"\n"+t.prev}function X(e,t){var r=T(e),n=[];if(r){n.length=e.length;for(var o=0;o<e.length;o++)n[o]=H(e,o)?t(e[o],e):""}var i,a="function"==typeof S?S(e):[];if(R){i={};for(var s=0;s<a.length;s++)i["$"+a[s]]=a[s]}for(var f in e)H(e,f)&&(r&&String(Number(f))===f&&f<e.length||R&&i["$"+f]instanceof Symbol||(w.call(/[^\w$]/,f)?n.push(t(f,e)+": "+t(e[f],e)):n.push(f+": "+t(e[f],e))));if("function"==typeof S)for(var l=0;l<a.length;l++)N.call(e,a[l])&&n.push("["+t(a[l])+"]: "+t(e[a[l]],e));return n}},1668:(e,t,r)=>{"use strict";var n={};(0,r(9805).assign)(n,r(3303),r(7083),r(9681)),e.exports=n},3303:(e,t,r)=>{"use strict";var n=r(8411),o=r(9805),i=r(1996),a=r(4674),s=r(4442),f=Object.prototype.toString,l=0,u=-1,c=0,A=8;function h(e){if(!(this instanceof h))return new h(e);this.options=o.assign({level:u,method:A,chunkSize:16384,windowBits:15,memLevel:8,strategy:c,to:""},e||{});var t=this.options;t.raw&&t.windowBits>0?t.windowBits=-t.windowBits:t.gzip&&t.windowBits>0&&t.windowBits<16&&(t.windowBits+=16),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new s,this.strm.avail_out=0;var r=n.deflateInit2(this.strm,t.level,t.method,t.windowBits,t.memLevel,t.strategy);if(r!==l)throw new Error(a[r]);if(t.header&&n.deflateSetHeader(this.strm,t.header),t.dictionary){var d;if(d="string"==typeof t.dictionary?i.string2buf(t.dictionary):"[object ArrayBuffer]"===f.call(t.dictionary)?new Uint8Array(t.dictionary):t.dictionary,(r=n.deflateSetDictionary(this.strm,d))!==l)throw new Error(a[r]);this._dict_set=!0}}function d(e,t){var r=new h(t);if(r.push(e,!0),r.err)throw r.msg||a[r.err];return r.result}h.prototype.push=function(e,t){var r,a,s=this.strm,u=this.options.chunkSize;if(this.ended)return!1;a=t===~~t?t:!0===t?4:0,"string"==typeof e?s.input=i.string2buf(e):"[object ArrayBuffer]"===f.call(e)?s.input=new Uint8Array(e):s.input=e,s.next_in=0,s.avail_in=s.input.length;do{if(0===s.avail_out&&(s.output=new o.Buf8(u),s.next_out=0,s.avail_out=u),1!==(r=n.deflate(s,a))&&r!==l)return this.onEnd(r),this.ended=!0,!1;0!==s.avail_out&&(0!==s.avail_in||4!==a&&2!==a)||("string"===this.options.to?this.onData(i.buf2binstring(o.shrinkBuf(s.output,s.next_out))):this.onData(o.shrinkBuf(s.output,s.next_out)))}while((s.avail_in>0||0===s.avail_out)&&1!==r);return 4===a?(r=n.deflateEnd(this.strm),this.onEnd(r),this.ended=!0,r===l):2!==a||(this.onEnd(l),s.avail_out=0,!0)},h.prototype.onData=function(e){this.chunks.push(e)},h.prototype.onEnd=function(e){e===l&&("string"===this.options.to?this.result=this.chunks.join(""):this.result=o.flattenChunks(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg},t.Deflate=h,t.deflate=d,t.deflateRaw=function(e,t){return(t=t||{}).raw=!0,d(e,t)},t.gzip=function(e,t){return(t=t||{}).gzip=!0,d(e,t)}},7083:(e,t,r)=>{"use strict";var n=r(1447),o=r(9805),i=r(1996),a=r(9681),s=r(4674),f=r(4442),l=r(7414),u=Object.prototype.toString;function c(e){if(!(this instanceof c))return new c(e);this.options=o.assign({chunkSize:16384,windowBits:0,to:""},e||{});var t=this.options;t.raw&&t.windowBits>=0&&t.windowBits<16&&(t.windowBits=-t.windowBits,0===t.windowBits&&(t.windowBits=-15)),!(t.windowBits>=0&&t.windowBits<16)||e&&e.windowBits||(t.windowBits+=32),t.windowBits>15&&t.windowBits<48&&0==(15&t.windowBits)&&(t.windowBits|=15),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new f,this.strm.avail_out=0;var r=n.inflateInit2(this.strm,t.windowBits);if(r!==a.Z_OK)throw new Error(s[r]);if(this.header=new l,n.inflateGetHeader(this.strm,this.header),t.dictionary&&("string"==typeof t.dictionary?t.dictionary=i.string2buf(t.dictionary):"[object ArrayBuffer]"===u.call(t.dictionary)&&(t.dictionary=new Uint8Array(t.dictionary)),t.raw&&(r=n.inflateSetDictionary(this.strm,t.dictionary))!==a.Z_OK))throw new Error(s[r])}function A(e,t){var r=new c(t);if(r.push(e,!0),r.err)throw r.msg||s[r.err];return r.result}c.prototype.push=function(e,t){var r,s,f,l,c,A=this.strm,h=this.options.chunkSize,d=this.options.dictionary,g=!1;if(this.ended)return!1;s=t===~~t?t:!0===t?a.Z_FINISH:a.Z_NO_FLUSH,"string"==typeof e?A.input=i.binstring2buf(e):"[object ArrayBuffer]"===u.call(e)?A.input=new Uint8Array(e):A.input=e,A.next_in=0,A.avail_in=A.input.length;do{if(0===A.avail_out&&(A.output=new o.Buf8(h),A.next_out=0,A.avail_out=h),(r=n.inflate(A,a.Z_NO_FLUSH))===a.Z_NEED_DICT&&d&&(r=n.inflateSetDictionary(this.strm,d)),r===a.Z_BUF_ERROR&&!0===g&&(r=a.Z_OK,g=!1),r!==a.Z_STREAM_END&&r!==a.Z_OK)return this.onEnd(r),this.ended=!0,!1;A.next_out&&(0!==A.avail_out&&r!==a.Z_STREAM_END&&(0!==A.avail_in||s!==a.Z_FINISH&&s!==a.Z_SYNC_FLUSH)||("string"===this.options.to?(f=i.utf8border(A.output,A.next_out),l=A.next_out-f,c=i.buf2string(A.output,f),A.next_out=l,A.avail_out=h-l,l&&o.arraySet(A.output,A.output,f,l,0),this.onData(c)):this.onData(o.shrinkBuf(A.output,A.next_out)))),0===A.avail_in&&0===A.avail_out&&(g=!0)}while((A.avail_in>0||0===A.avail_out)&&r!==a.Z_STREAM_END);return r===a.Z_STREAM_END&&(s=a.Z_FINISH),s===a.Z_FINISH?(r=n.inflateEnd(this.strm),this.onEnd(r),this.ended=!0,r===a.Z_OK):s!==a.Z_SYNC_FLUSH||(this.onEnd(a.Z_OK),A.avail_out=0,!0)},c.prototype.onData=function(e){this.chunks.push(e)},c.prototype.onEnd=function(e){e===a.Z_OK&&("string"===this.options.to?this.result=this.chunks.join(""):this.result=o.flattenChunks(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg},t.Inflate=c,t.inflate=A,t.inflateRaw=function(e,t){return(t=t||{}).raw=!0,A(e,t)},t.ungzip=A},9805:(e,t)=>{"use strict";var r="undefined"!=typeof Uint8Array&&"undefined"!=typeof Uint16Array&&"undefined"!=typeof Int32Array;function n(e,t){return Object.prototype.hasOwnProperty.call(e,t)}t.assign=function(e){for(var t=Array.prototype.slice.call(arguments,1);t.length;){var r=t.shift();if(r){if("object"!=typeof r)throw new TypeError(r+"must be non-object");for(var o in r)n(r,o)&&(e[o]=r[o])}}return e},t.shrinkBuf=function(e,t){return e.length===t?e:e.subarray?e.subarray(0,t):(e.length=t,e)};var o={arraySet:function(e,t,r,n,o){if(t.subarray&&e.subarray)e.set(t.subarray(r,r+n),o);else for(var i=0;i<n;i++)e[o+i]=t[r+i]},flattenChunks:function(e){var t,r,n,o,i,a;for(n=0,t=0,r=e.length;t<r;t++)n+=e[t].length;for(a=new Uint8Array(n),o=0,t=0,r=e.length;t<r;t++)i=e[t],a.set(i,o),o+=i.length;return a}},i={arraySet:function(e,t,r,n,o){for(var i=0;i<n;i++)e[o+i]=t[r+i]},flattenChunks:function(e){return[].concat.apply([],e)}};t.setTyped=function(e){e?(t.Buf8=Uint8Array,t.Buf16=Uint16Array,t.Buf32=Int32Array,t.assign(t,o)):(t.Buf8=Array,t.Buf16=Array,t.Buf32=Array,t.assign(t,i))},t.setTyped(r)},1996:(e,t,r)=>{"use strict";var n=r(9805),o=!0,i=!0;try{String.fromCharCode.apply(null,[0])}catch(e){o=!1}try{String.fromCharCode.apply(null,new Uint8Array(1))}catch(e){i=!1}for(var a=new n.Buf8(256),s=0;s<256;s++)a[s]=s>=252?6:s>=248?5:s>=240?4:s>=224?3:s>=192?2:1;function f(e,t){if(t<65534&&(e.subarray&&i||!e.subarray&&o))return String.fromCharCode.apply(null,n.shrinkBuf(e,t));for(var r="",a=0;a<t;a++)r+=String.fromCharCode(e[a]);return r}a[254]=a[254]=1,t.string2buf=function(e){var t,r,o,i,a,s=e.length,f=0;for(i=0;i<s;i++)55296==(64512&(r=e.charCodeAt(i)))&&i+1<s&&56320==(64512&(o=e.charCodeAt(i+1)))&&(r=65536+(r-55296<<10)+(o-56320),i++),f+=r<128?1:r<2048?2:r<65536?3:4;for(t=new n.Buf8(f),a=0,i=0;a<f;i++)55296==(64512&(r=e.charCodeAt(i)))&&i+1<s&&56320==(64512&(o=e.charCodeAt(i+1)))&&(r=65536+(r-55296<<10)+(o-56320),i++),r<128?t[a++]=r:r<2048?(t[a++]=192|r>>>6,t[a++]=128|63&r):r<65536?(t[a++]=224|r>>>12,t[a++]=128|r>>>6&63,t[a++]=128|63&r):(t[a++]=240|r>>>18,t[a++]=128|r>>>12&63,t[a++]=128|r>>>6&63,t[a++]=128|63&r);return t},t.buf2binstring=function(e){return f(e,e.length)},t.binstring2buf=function(e){for(var t=new n.Buf8(e.length),r=0,o=t.length;r<o;r++)t[r]=e.charCodeAt(r);return t},t.buf2string=function(e,t){var r,n,o,i,s=t||e.length,l=new Array(2*s);for(n=0,r=0;r<s;)if((o=e[r++])<128)l[n++]=o;else if((i=a[o])>4)l[n++]=65533,r+=i-1;else{for(o&=2===i?31:3===i?15:7;i>1&&r<s;)o=o<<6|63&e[r++],i--;i>1?l[n++]=65533:o<65536?l[n++]=o:(o-=65536,l[n++]=55296|o>>10&1023,l[n++]=56320|1023&o)}return f(l,n)},t.utf8border=function(e,t){var r;for((t=t||e.length)>e.length&&(t=e.length),r=t-1;r>=0&&128==(192&e[r]);)r--;return r<0||0===r?t:r+a[e[r]]>t?r:t}},3269:e=>{"use strict";e.exports=function(e,t,r,n){for(var o=65535&e|0,i=e>>>16&65535|0,a=0;0!==r;){r-=a=r>2e3?2e3:r;do{i=i+(o=o+t[n++]|0)|0}while(--a);o%=65521,i%=65521}return o|i<<16|0}},9681:e=>{"use strict";e.exports={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8}},4823:e=>{"use strict";var t=function(){for(var e,t=[],r=0;r<256;r++){e=r;for(var n=0;n<8;n++)e=1&e?3988292384^e>>>1:e>>>1;t[r]=e}return t}();e.exports=function(e,r,n,o){var i=t,a=o+n;e^=-1;for(var s=o;s<a;s++)e=e>>>8^i[255&(e^r[s])];return-1^e}},8411:(e,t,r)=>{"use strict";var n,o=r(9805),i=r(3665),a=r(3269),s=r(4823),f=r(4674),l=0,u=0,c=-2,A=2,h=8,d=286,g=30,p=19,y=2*d+1,m=15,C=3,I=258,b=I+C+1,w=42,v=103,B=113,E=666;function _(e,t){return e.msg=f[t],t}function Q(e){return(e<<1)-(e>4?9:0)}function S(e){for(var t=e.length;--t>=0;)e[t]=0}function k(e){var t=e.state,r=t.pending;r>e.avail_out&&(r=e.avail_out),0!==r&&(o.arraySet(e.output,t.pending_buf,t.pending_out,r,e.next_out),e.next_out+=r,t.pending_out+=r,e.total_out+=r,e.avail_out-=r,t.pending-=r,0===t.pending&&(t.pending_out=0))}function R(e,t){i._tr_flush_block(e,e.block_start>=0?e.block_start:-1,e.strstart-e.block_start,t),e.block_start=e.strstart,k(e.strm)}function D(e,t){e.pending_buf[e.pending++]=t}function N(e,t){e.pending_buf[e.pending++]=t>>>8&255,e.pending_buf[e.pending++]=255&t}function x(e,t,r,n){var i=e.avail_in;return i>n&&(i=n),0===i?0:(e.avail_in-=i,o.arraySet(t,e.input,e.next_in,i,r),1===e.state.wrap?e.adler=a(e.adler,t,i,r):2===e.state.wrap&&(e.adler=s(e.adler,t,i,r)),e.next_in+=i,e.total_in+=i,i)}function F(e,t){var r,n,o=e.max_chain_length,i=e.strstart,a=e.prev_length,s=e.nice_match,f=e.strstart>e.w_size-b?e.strstart-(e.w_size-b):0,l=e.window,u=e.w_mask,c=e.prev,A=e.strstart+I,h=l[i+a-1],d=l[i+a];e.prev_length>=e.good_match&&(o>>=2),s>e.lookahead&&(s=e.lookahead);do{if(l[(r=t)+a]===d&&l[r+a-1]===h&&l[r]===l[i]&&l[++r]===l[i+1]){i+=2,r++;do{}while(l[++i]===l[++r]&&l[++i]===l[++r]&&l[++i]===l[++r]&&l[++i]===l[++r]&&l[++i]===l[++r]&&l[++i]===l[++r]&&l[++i]===l[++r]&&l[++i]===l[++r]&&i<A);if(n=I-(A-i),i=A-I,n>a){if(e.match_start=t,a=n,n>=s)break;h=l[i+a-1],d=l[i+a]}}}while((t=c[t&u])>f&&0!=--o);return a<=e.lookahead?a:e.lookahead}function M(e){var t,r,n,i,a,s=e.w_size;do{if(i=e.window_size-e.lookahead-e.strstart,e.strstart>=s+(s-b)){o.arraySet(e.window,e.window,s,s,0),e.match_start-=s,e.strstart-=s,e.block_start-=s,t=r=e.hash_size;do{n=e.head[--t],e.head[t]=n>=s?n-s:0}while(--r);t=r=s;do{n=e.prev[--t],e.prev[t]=n>=s?n-s:0}while(--r);i+=s}if(0===e.strm.avail_in)break;if(r=x(e.strm,e.window,e.strstart+e.lookahead,i),e.lookahead+=r,e.lookahead+e.insert>=C)for(a=e.strstart-e.insert,e.ins_h=e.window[a],e.ins_h=(e.ins_h<<e.hash_shift^e.window[a+1])&e.hash_mask;e.insert&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[a+C-1])&e.hash_mask,e.prev[a&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=a,a++,e.insert--,!(e.lookahead+e.insert<C)););}while(e.lookahead<b&&0!==e.strm.avail_in)}function O(e,t){for(var r,n;;){if(e.lookahead<b){if(M(e),e.lookahead<b&&t===l)return 1;if(0===e.lookahead)break}if(r=0,e.lookahead>=C&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+C-1])&e.hash_mask,r=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),0!==r&&e.strstart-r<=e.w_size-b&&(e.match_length=F(e,r)),e.match_length>=C)if(n=i._tr_tally(e,e.strstart-e.match_start,e.match_length-C),e.lookahead-=e.match_length,e.match_length<=e.max_lazy_match&&e.lookahead>=C){e.match_length--;do{e.strstart++,e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+C-1])&e.hash_mask,r=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart}while(0!=--e.match_length);e.strstart++}else e.strstart+=e.match_length,e.match_length=0,e.ins_h=e.window[e.strstart],e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+1])&e.hash_mask;else n=i._tr_tally(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++;if(n&&(R(e,!1),0===e.strm.avail_out))return 1}return e.insert=e.strstart<C-1?e.strstart:C-1,4===t?(R(e,!0),0===e.strm.avail_out?3:4):e.last_lit&&(R(e,!1),0===e.strm.avail_out)?1:2}function L(e,t){for(var r,n,o;;){if(e.lookahead<b){if(M(e),e.lookahead<b&&t===l)return 1;if(0===e.lookahead)break}if(r=0,e.lookahead>=C&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+C-1])&e.hash_mask,r=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),e.prev_length=e.match_length,e.prev_match=e.match_start,e.match_length=C-1,0!==r&&e.prev_length<e.max_lazy_match&&e.strstart-r<=e.w_size-b&&(e.match_length=F(e,r),e.match_length<=5&&(1===e.strategy||e.match_length===C&&e.strstart-e.match_start>4096)&&(e.match_length=C-1)),e.prev_length>=C&&e.match_length<=e.prev_length){o=e.strstart+e.lookahead-C,n=i._tr_tally(e,e.strstart-1-e.prev_match,e.prev_length-C),e.lookahead-=e.prev_length-1,e.prev_length-=2;do{++e.strstart<=o&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+C-1])&e.hash_mask,r=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart)}while(0!=--e.prev_length);if(e.match_available=0,e.match_length=C-1,e.strstart++,n&&(R(e,!1),0===e.strm.avail_out))return 1}else if(e.match_available){if((n=i._tr_tally(e,0,e.window[e.strstart-1]))&&R(e,!1),e.strstart++,e.lookahead--,0===e.strm.avail_out)return 1}else e.match_available=1,e.strstart++,e.lookahead--}return e.match_available&&(n=i._tr_tally(e,0,e.window[e.strstart-1]),e.match_available=0),e.insert=e.strstart<C-1?e.strstart:C-1,4===t?(R(e,!0),0===e.strm.avail_out?3:4):e.last_lit&&(R(e,!1),0===e.strm.avail_out)?1:2}function P(e,t,r,n,o){this.good_length=e,this.max_lazy=t,this.nice_length=r,this.max_chain=n,this.func=o}function U(){this.strm=null,this.status=0,this.pending_buf=null,this.pending_buf_size=0,this.pending_out=0,this.pending=0,this.wrap=0,this.gzhead=null,this.gzindex=0,this.method=h,this.last_flush=-1,this.w_size=0,this.w_bits=0,this.w_mask=0,this.window=null,this.window_size=0,this.prev=null,this.head=null,this.ins_h=0,this.hash_size=0,this.hash_bits=0,this.hash_mask=0,this.hash_shift=0,this.block_start=0,this.match_length=0,this.prev_match=0,this.match_available=0,this.strstart=0,this.match_start=0,this.lookahead=0,this.prev_length=0,this.max_chain_length=0,this.max_lazy_match=0,this.level=0,this.strategy=0,this.good_match=0,this.nice_match=0,this.dyn_ltree=new o.Buf16(2*y),this.dyn_dtree=new o.Buf16(2*(2*g+1)),this.bl_tree=new o.Buf16(2*(2*p+1)),S(this.dyn_ltree),S(this.dyn_dtree),S(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new o.Buf16(m+1),this.heap=new o.Buf16(2*d+1),S(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new o.Buf16(2*d+1),S(this.depth),this.l_buf=0,this.lit_bufsize=0,this.last_lit=0,this.d_buf=0,this.opt_len=0,this.static_len=0,this.matches=0,this.insert=0,this.bi_buf=0,this.bi_valid=0}function T(e){var t;return e&&e.state?(e.total_in=e.total_out=0,e.data_type=A,(t=e.state).pending=0,t.pending_out=0,t.wrap<0&&(t.wrap=-t.wrap),t.status=t.wrap?w:B,e.adler=2===t.wrap?0:1,t.last_flush=l,i._tr_init(t),u):_(e,c)}function q(e){var t,r=T(e);return r===u&&((t=e.state).window_size=2*t.w_size,S(t.head),t.max_lazy_match=n[t.level].max_lazy,t.good_match=n[t.level].good_length,t.nice_match=n[t.level].nice_length,t.max_chain_length=n[t.level].max_chain,t.strstart=0,t.block_start=0,t.lookahead=0,t.insert=0,t.match_length=t.prev_length=C-1,t.match_available=0,t.ins_h=0),r}function j(e,t,r,n,i,a){if(!e)return c;var s=1;if(-1===t&&(t=6),n<0?(s=0,n=-n):n>15&&(s=2,n-=16),i<1||i>9||r!==h||n<8||n>15||t<0||t>9||a<0||a>4)return _(e,c);8===n&&(n=9);var f=new U;return e.state=f,f.strm=e,f.wrap=s,f.gzhead=null,f.w_bits=n,f.w_size=1<<f.w_bits,f.w_mask=f.w_size-1,f.hash_bits=i+7,f.hash_size=1<<f.hash_bits,f.hash_mask=f.hash_size-1,f.hash_shift=~~((f.hash_bits+C-1)/C),f.window=new o.Buf8(2*f.w_size),f.head=new o.Buf16(f.hash_size),f.prev=new o.Buf16(f.w_size),f.lit_bufsize=1<<i+6,f.pending_buf_size=4*f.lit_bufsize,f.pending_buf=new o.Buf8(f.pending_buf_size),f.d_buf=1*f.lit_bufsize,f.l_buf=3*f.lit_bufsize,f.level=t,f.strategy=a,f.method=r,q(e)}n=[new P(0,0,0,0,(function(e,t){var r=65535;for(r>e.pending_buf_size-5&&(r=e.pending_buf_size-5);;){if(e.lookahead<=1){if(M(e),0===e.lookahead&&t===l)return 1;if(0===e.lookahead)break}e.strstart+=e.lookahead,e.lookahead=0;var n=e.block_start+r;if((0===e.strstart||e.strstart>=n)&&(e.lookahead=e.strstart-n,e.strstart=n,R(e,!1),0===e.strm.avail_out))return 1;if(e.strstart-e.block_start>=e.w_size-b&&(R(e,!1),0===e.strm.avail_out))return 1}return e.insert=0,4===t?(R(e,!0),0===e.strm.avail_out?3:4):(e.strstart>e.block_start&&(R(e,!1),e.strm.avail_out),1)})),new P(4,4,8,4,O),new P(4,5,16,8,O),new P(4,6,32,32,O),new P(4,4,16,16,L),new P(8,16,32,32,L),new P(8,16,128,128,L),new P(8,32,128,256,L),new P(32,128,258,1024,L),new P(32,258,258,4096,L)],t.deflateInit=function(e,t){return j(e,t,h,15,8,0)},t.deflateInit2=j,t.deflateReset=q,t.deflateResetKeep=T,t.deflateSetHeader=function(e,t){return e&&e.state?2!==e.state.wrap?c:(e.state.gzhead=t,u):c},t.deflate=function(e,t){var r,o,a,f;if(!e||!e.state||t>5||t<0)return e?_(e,c):c;if(o=e.state,!e.output||!e.input&&0!==e.avail_in||o.status===E&&4!==t)return _(e,0===e.avail_out?-5:c);if(o.strm=e,r=o.last_flush,o.last_flush=t,o.status===w)if(2===o.wrap)e.adler=0,D(o,31),D(o,139),D(o,8),o.gzhead?(D(o,(o.gzhead.text?1:0)+(o.gzhead.hcrc?2:0)+(o.gzhead.extra?4:0)+(o.gzhead.name?8:0)+(o.gzhead.comment?16:0)),D(o,255&o.gzhead.time),D(o,o.gzhead.time>>8&255),D(o,o.gzhead.time>>16&255),D(o,o.gzhead.time>>24&255),D(o,9===o.level?2:o.strategy>=2||o.level<2?4:0),D(o,255&o.gzhead.os),o.gzhead.extra&&o.gzhead.extra.length&&(D(o,255&o.gzhead.extra.length),D(o,o.gzhead.extra.length>>8&255)),o.gzhead.hcrc&&(e.adler=s(e.adler,o.pending_buf,o.pending,0)),o.gzindex=0,o.status=69):(D(o,0),D(o,0),D(o,0),D(o,0),D(o,0),D(o,9===o.level?2:o.strategy>=2||o.level<2?4:0),D(o,3),o.status=B);else{var A=h+(o.w_bits-8<<4)<<8;A|=(o.strategy>=2||o.level<2?0:o.level<6?1:6===o.level?2:3)<<6,0!==o.strstart&&(A|=32),A+=31-A%31,o.status=B,N(o,A),0!==o.strstart&&(N(o,e.adler>>>16),N(o,65535&e.adler)),e.adler=1}if(69===o.status)if(o.gzhead.extra){for(a=o.pending;o.gzindex<(65535&o.gzhead.extra.length)&&(o.pending!==o.pending_buf_size||(o.gzhead.hcrc&&o.pending>a&&(e.adler=s(e.adler,o.pending_buf,o.pending-a,a)),k(e),a=o.pending,o.pending!==o.pending_buf_size));)D(o,255&o.gzhead.extra[o.gzindex]),o.gzindex++;o.gzhead.hcrc&&o.pending>a&&(e.adler=s(e.adler,o.pending_buf,o.pending-a,a)),o.gzindex===o.gzhead.extra.length&&(o.gzindex=0,o.status=73)}else o.status=73;if(73===o.status)if(o.gzhead.name){a=o.pending;do{if(o.pending===o.pending_buf_size&&(o.gzhead.hcrc&&o.pending>a&&(e.adler=s(e.adler,o.pending_buf,o.pending-a,a)),k(e),a=o.pending,o.pending===o.pending_buf_size)){f=1;break}f=o.gzindex<o.gzhead.name.length?255&o.gzhead.name.charCodeAt(o.gzindex++):0,D(o,f)}while(0!==f);o.gzhead.hcrc&&o.pending>a&&(e.adler=s(e.adler,o.pending_buf,o.pending-a,a)),0===f&&(o.gzindex=0,o.status=91)}else o.status=91;if(91===o.status)if(o.gzhead.comment){a=o.pending;do{if(o.pending===o.pending_buf_size&&(o.gzhead.hcrc&&o.pending>a&&(e.adler=s(e.adler,o.pending_buf,o.pending-a,a)),k(e),a=o.pending,o.pending===o.pending_buf_size)){f=1;break}f=o.gzindex<o.gzhead.comment.length?255&o.gzhead.comment.charCodeAt(o.gzindex++):0,D(o,f)}while(0!==f);o.gzhead.hcrc&&o.pending>a&&(e.adler=s(e.adler,o.pending_buf,o.pending-a,a)),0===f&&(o.status=v)}else o.status=v;if(o.status===v&&(o.gzhead.hcrc?(o.pending+2>o.pending_buf_size&&k(e),o.pending+2<=o.pending_buf_size&&(D(o,255&e.adler),D(o,e.adler>>8&255),e.adler=0,o.status=B)):o.status=B),0!==o.pending){if(k(e),0===e.avail_out)return o.last_flush=-1,u}else if(0===e.avail_in&&Q(t)<=Q(r)&&4!==t)return _(e,-5);if(o.status===E&&0!==e.avail_in)return _(e,-5);if(0!==e.avail_in||0!==o.lookahead||t!==l&&o.status!==E){var d=2===o.strategy?function(e,t){for(var r;;){if(0===e.lookahead&&(M(e),0===e.lookahead)){if(t===l)return 1;break}if(e.match_length=0,r=i._tr_tally(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++,r&&(R(e,!1),0===e.strm.avail_out))return 1}return e.insert=0,4===t?(R(e,!0),0===e.strm.avail_out?3:4):e.last_lit&&(R(e,!1),0===e.strm.avail_out)?1:2}(o,t):3===o.strategy?function(e,t){for(var r,n,o,a,s=e.window;;){if(e.lookahead<=I){if(M(e),e.lookahead<=I&&t===l)return 1;if(0===e.lookahead)break}if(e.match_length=0,e.lookahead>=C&&e.strstart>0&&(n=s[o=e.strstart-1])===s[++o]&&n===s[++o]&&n===s[++o]){a=e.strstart+I;do{}while(n===s[++o]&&n===s[++o]&&n===s[++o]&&n===s[++o]&&n===s[++o]&&n===s[++o]&&n===s[++o]&&n===s[++o]&&o<a);e.match_length=I-(a-o),e.match_length>e.lookahead&&(e.match_length=e.lookahead)}if(e.match_length>=C?(r=i._tr_tally(e,1,e.match_length-C),e.lookahead-=e.match_length,e.strstart+=e.match_length,e.match_length=0):(r=i._tr_tally(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++),r&&(R(e,!1),0===e.strm.avail_out))return 1}return e.insert=0,4===t?(R(e,!0),0===e.strm.avail_out?3:4):e.last_lit&&(R(e,!1),0===e.strm.avail_out)?1:2}(o,t):n[o.level].func(o,t);if(3!==d&&4!==d||(o.status=E),1===d||3===d)return 0===e.avail_out&&(o.last_flush=-1),u;if(2===d&&(1===t?i._tr_align(o):5!==t&&(i._tr_stored_block(o,0,0,!1),3===t&&(S(o.head),0===o.lookahead&&(o.strstart=0,o.block_start=0,o.insert=0))),k(e),0===e.avail_out))return o.last_flush=-1,u}return 4!==t?u:o.wrap<=0?1:(2===o.wrap?(D(o,255&e.adler),D(o,e.adler>>8&255),D(o,e.adler>>16&255),D(o,e.adler>>24&255),D(o,255&e.total_in),D(o,e.total_in>>8&255),D(o,e.total_in>>16&255),D(o,e.total_in>>24&255)):(N(o,e.adler>>>16),N(o,65535&e.adler)),k(e),o.wrap>0&&(o.wrap=-o.wrap),0!==o.pending?u:1)},t.deflateEnd=function(e){var t;return e&&e.state?(t=e.state.status)!==w&&69!==t&&73!==t&&91!==t&&t!==v&&t!==B&&t!==E?_(e,c):(e.state=null,t===B?_(e,-3):u):c},t.deflateSetDictionary=function(e,t){var r,n,i,s,f,l,A,h,d=t.length;if(!e||!e.state)return c;if(2===(s=(r=e.state).wrap)||1===s&&r.status!==w||r.lookahead)return c;for(1===s&&(e.adler=a(e.adler,t,d,0)),r.wrap=0,d>=r.w_size&&(0===s&&(S(r.head),r.strstart=0,r.block_start=0,r.insert=0),h=new o.Buf8(r.w_size),o.arraySet(h,t,d-r.w_size,r.w_size,0),t=h,d=r.w_size),f=e.avail_in,l=e.next_in,A=e.input,e.avail_in=d,e.next_in=0,e.input=t,M(r);r.lookahead>=C;){n=r.strstart,i=r.lookahead-(C-1);do{r.ins_h=(r.ins_h<<r.hash_shift^r.window[n+C-1])&r.hash_mask,r.prev[n&r.w_mask]=r.head[r.ins_h],r.head[r.ins_h]=n,n++}while(--i);r.strstart=n,r.lookahead=C-1,M(r)}return r.strstart+=r.lookahead,r.block_start=r.strstart,r.insert=r.lookahead,r.lookahead=0,r.match_length=r.prev_length=C-1,r.match_available=0,e.next_in=l,e.input=A,e.avail_in=f,r.wrap=s,u},t.deflateInfo="pako deflate (from Nodeca project)"},7414:e=>{"use strict";e.exports=function(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1}},7293:e=>{"use strict";e.exports=function(e,t){var r,n,o,i,a,s,f,l,u,c,A,h,d,g,p,y,m,C,I,b,w,v,B,E,_;r=e.state,n=e.next_in,E=e.input,o=n+(e.avail_in-5),i=e.next_out,_=e.output,a=i-(t-e.avail_out),s=i+(e.avail_out-257),f=r.dmax,l=r.wsize,u=r.whave,c=r.wnext,A=r.window,h=r.hold,d=r.bits,g=r.lencode,p=r.distcode,y=(1<<r.lenbits)-1,m=(1<<r.distbits)-1;e:do{d<15&&(h+=E[n++]<<d,d+=8,h+=E[n++]<<d,d+=8),C=g[h&y];t:for(;;){if(h>>>=I=C>>>24,d-=I,0==(I=C>>>16&255))_[i++]=65535&C;else{if(!(16&I)){if(0==(64&I)){C=g[(65535&C)+(h&(1<<I)-1)];continue t}if(32&I){r.mode=12;break e}e.msg="invalid literal/length code",r.mode=30;break e}b=65535&C,(I&=15)&&(d<I&&(h+=E[n++]<<d,d+=8),b+=h&(1<<I)-1,h>>>=I,d-=I),d<15&&(h+=E[n++]<<d,d+=8,h+=E[n++]<<d,d+=8),C=p[h&m];r:for(;;){if(h>>>=I=C>>>24,d-=I,!(16&(I=C>>>16&255))){if(0==(64&I)){C=p[(65535&C)+(h&(1<<I)-1)];continue r}e.msg="invalid distance code",r.mode=30;break e}if(w=65535&C,d<(I&=15)&&(h+=E[n++]<<d,(d+=8)<I&&(h+=E[n++]<<d,d+=8)),(w+=h&(1<<I)-1)>f){e.msg="invalid distance too far back",r.mode=30;break e}if(h>>>=I,d-=I,w>(I=i-a)){if((I=w-I)>u&&r.sane){e.msg="invalid distance too far back",r.mode=30;break e}if(v=0,B=A,0===c){if(v+=l-I,I<b){b-=I;do{_[i++]=A[v++]}while(--I);v=i-w,B=_}}else if(c<I){if(v+=l+c-I,(I-=c)<b){b-=I;do{_[i++]=A[v++]}while(--I);if(v=0,c<b){b-=I=c;do{_[i++]=A[v++]}while(--I);v=i-w,B=_}}}else if(v+=c-I,I<b){b-=I;do{_[i++]=A[v++]}while(--I);v=i-w,B=_}for(;b>2;)_[i++]=B[v++],_[i++]=B[v++],_[i++]=B[v++],b-=3;b&&(_[i++]=B[v++],b>1&&(_[i++]=B[v++]))}else{v=i-w;do{_[i++]=_[v++],_[i++]=_[v++],_[i++]=_[v++],b-=3}while(b>2);b&&(_[i++]=_[v++],b>1&&(_[i++]=_[v++]))}break}}break}}while(n<o&&i<s);n-=b=d>>3,h&=(1<<(d-=b<<3))-1,e.next_in=n,e.next_out=i,e.avail_in=n<o?o-n+5:5-(n-o),e.avail_out=i<s?s-i+257:257-(i-s),r.hold=h,r.bits=d}},1447:(e,t,r)=>{"use strict";var n=r(9805),o=r(3269),i=r(4823),a=r(7293),s=r(1998),f=0,l=-2,u=1,c=12,A=30,h=852,d=592;function g(e){return(e>>>24&255)+(e>>>8&65280)+((65280&e)<<8)+((255&e)<<24)}function p(){this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new n.Buf16(320),this.work=new n.Buf16(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}function y(e){var t;return e&&e.state?(t=e.state,e.total_in=e.total_out=t.total=0,e.msg="",t.wrap&&(e.adler=1&t.wrap),t.mode=u,t.last=0,t.havedict=0,t.dmax=32768,t.head=null,t.hold=0,t.bits=0,t.lencode=t.lendyn=new n.Buf32(h),t.distcode=t.distdyn=new n.Buf32(d),t.sane=1,t.back=-1,f):l}function m(e){var t;return e&&e.state?((t=e.state).wsize=0,t.whave=0,t.wnext=0,y(e)):l}function C(e,t){var r,n;return e&&e.state?(n=e.state,t<0?(r=0,t=-t):(r=1+(t>>4),t<48&&(t&=15)),t&&(t<8||t>15)?l:(null!==n.window&&n.wbits!==t&&(n.window=null),n.wrap=r,n.wbits=t,m(e))):l}function I(e,t){var r,n;return e?(n=new p,e.state=n,n.window=null,(r=C(e,t))!==f&&(e.state=null),r):l}var b,w,v=!0;function B(e){if(v){var t;for(b=new n.Buf32(512),w=new n.Buf32(32),t=0;t<144;)e.lens[t++]=8;for(;t<256;)e.lens[t++]=9;for(;t<280;)e.lens[t++]=7;for(;t<288;)e.lens[t++]=8;for(s(1,e.lens,0,288,b,0,e.work,{bits:9}),t=0;t<32;)e.lens[t++]=5;s(2,e.lens,0,32,w,0,e.work,{bits:5}),v=!1}e.lencode=b,e.lenbits=9,e.distcode=w,e.distbits=5}function E(e,t,r,o){var i,a=e.state;return null===a.window&&(a.wsize=1<<a.wbits,a.wnext=0,a.whave=0,a.window=new n.Buf8(a.wsize)),o>=a.wsize?(n.arraySet(a.window,t,r-a.wsize,a.wsize,0),a.wnext=0,a.whave=a.wsize):((i=a.wsize-a.wnext)>o&&(i=o),n.arraySet(a.window,t,r-o,i,a.wnext),(o-=i)?(n.arraySet(a.window,t,r-o,o,0),a.wnext=o,a.whave=a.wsize):(a.wnext+=i,a.wnext===a.wsize&&(a.wnext=0),a.whave<a.wsize&&(a.whave+=i))),0}t.inflateReset=m,t.inflateReset2=C,t.inflateResetKeep=y,t.inflateInit=function(e){return I(e,15)},t.inflateInit2=I,t.inflate=function(e,t){var r,h,d,p,y,m,C,I,b,w,v,_,Q,S,k,R,D,N,x,F,M,O,L,P,U=0,T=new n.Buf8(4),q=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!e||!e.state||!e.output||!e.input&&0!==e.avail_in)return l;(r=e.state).mode===c&&(r.mode=13),y=e.next_out,d=e.output,C=e.avail_out,p=e.next_in,h=e.input,m=e.avail_in,I=r.hold,b=r.bits,w=m,v=C,O=f;e:for(;;)switch(r.mode){case u:if(0===r.wrap){r.mode=13;break}for(;b<16;){if(0===m)break e;m--,I+=h[p++]<<b,b+=8}if(2&r.wrap&&35615===I){r.check=0,T[0]=255&I,T[1]=I>>>8&255,r.check=i(r.check,T,2,0),I=0,b=0,r.mode=2;break}if(r.flags=0,r.head&&(r.head.done=!1),!(1&r.wrap)||(((255&I)<<8)+(I>>8))%31){e.msg="incorrect header check",r.mode=A;break}if(8!=(15&I)){e.msg="unknown compression method",r.mode=A;break}if(b-=4,M=8+(15&(I>>>=4)),0===r.wbits)r.wbits=M;else if(M>r.wbits){e.msg="invalid window size",r.mode=A;break}r.dmax=1<<M,e.adler=r.check=1,r.mode=512&I?10:c,I=0,b=0;break;case 2:for(;b<16;){if(0===m)break e;m--,I+=h[p++]<<b,b+=8}if(r.flags=I,8!=(255&r.flags)){e.msg="unknown compression method",r.mode=A;break}if(57344&r.flags){e.msg="unknown header flags set",r.mode=A;break}r.head&&(r.head.text=I>>8&1),512&r.flags&&(T[0]=255&I,T[1]=I>>>8&255,r.check=i(r.check,T,2,0)),I=0,b=0,r.mode=3;case 3:for(;b<32;){if(0===m)break e;m--,I+=h[p++]<<b,b+=8}r.head&&(r.head.time=I),512&r.flags&&(T[0]=255&I,T[1]=I>>>8&255,T[2]=I>>>16&255,T[3]=I>>>24&255,r.check=i(r.check,T,4,0)),I=0,b=0,r.mode=4;case 4:for(;b<16;){if(0===m)break e;m--,I+=h[p++]<<b,b+=8}r.head&&(r.head.xflags=255&I,r.head.os=I>>8),512&r.flags&&(T[0]=255&I,T[1]=I>>>8&255,r.check=i(r.check,T,2,0)),I=0,b=0,r.mode=5;case 5:if(1024&r.flags){for(;b<16;){if(0===m)break e;m--,I+=h[p++]<<b,b+=8}r.length=I,r.head&&(r.head.extra_len=I),512&r.flags&&(T[0]=255&I,T[1]=I>>>8&255,r.check=i(r.check,T,2,0)),I=0,b=0}else r.head&&(r.head.extra=null);r.mode=6;case 6:if(1024&r.flags&&((_=r.length)>m&&(_=m),_&&(r.head&&(M=r.head.extra_len-r.length,r.head.extra||(r.head.extra=new Array(r.head.extra_len)),n.arraySet(r.head.extra,h,p,_,M)),512&r.flags&&(r.check=i(r.check,h,_,p)),m-=_,p+=_,r.length-=_),r.length))break e;r.length=0,r.mode=7;case 7:if(2048&r.flags){if(0===m)break e;_=0;do{M=h[p+_++],r.head&&M&&r.length<65536&&(r.head.name+=String.fromCharCode(M))}while(M&&_<m);if(512&r.flags&&(r.check=i(r.check,h,_,p)),m-=_,p+=_,M)break e}else r.head&&(r.head.name=null);r.length=0,r.mode=8;case 8:if(4096&r.flags){if(0===m)break e;_=0;do{M=h[p+_++],r.head&&M&&r.length<65536&&(r.head.comment+=String.fromCharCode(M))}while(M&&_<m);if(512&r.flags&&(r.check=i(r.check,h,_,p)),m-=_,p+=_,M)break e}else r.head&&(r.head.comment=null);r.mode=9;case 9:if(512&r.flags){for(;b<16;){if(0===m)break e;m--,I+=h[p++]<<b,b+=8}if(I!==(65535&r.check)){e.msg="header crc mismatch",r.mode=A;break}I=0,b=0}r.head&&(r.head.hcrc=r.flags>>9&1,r.head.done=!0),e.adler=r.check=0,r.mode=c;break;case 10:for(;b<32;){if(0===m)break e;m--,I+=h[p++]<<b,b+=8}e.adler=r.check=g(I),I=0,b=0,r.mode=11;case 11:if(0===r.havedict)return e.next_out=y,e.avail_out=C,e.next_in=p,e.avail_in=m,r.hold=I,r.bits=b,2;e.adler=r.check=1,r.mode=c;case c:if(5===t||6===t)break e;case 13:if(r.last){I>>>=7&b,b-=7&b,r.mode=27;break}for(;b<3;){if(0===m)break e;m--,I+=h[p++]<<b,b+=8}switch(r.last=1&I,b-=1,3&(I>>>=1)){case 0:r.mode=14;break;case 1:if(B(r),r.mode=20,6===t){I>>>=2,b-=2;break e}break;case 2:r.mode=17;break;case 3:e.msg="invalid block type",r.mode=A}I>>>=2,b-=2;break;case 14:for(I>>>=7&b,b-=7&b;b<32;){if(0===m)break e;m--,I+=h[p++]<<b,b+=8}if((65535&I)!=(I>>>16^65535)){e.msg="invalid stored block lengths",r.mode=A;break}if(r.length=65535&I,I=0,b=0,r.mode=15,6===t)break e;case 15:r.mode=16;case 16:if(_=r.length){if(_>m&&(_=m),_>C&&(_=C),0===_)break e;n.arraySet(d,h,p,_,y),m-=_,p+=_,C-=_,y+=_,r.length-=_;break}r.mode=c;break;case 17:for(;b<14;){if(0===m)break e;m--,I+=h[p++]<<b,b+=8}if(r.nlen=257+(31&I),I>>>=5,b-=5,r.ndist=1+(31&I),I>>>=5,b-=5,r.ncode=4+(15&I),I>>>=4,b-=4,r.nlen>286||r.ndist>30){e.msg="too many length or distance symbols",r.mode=A;break}r.have=0,r.mode=18;case 18:for(;r.have<r.ncode;){for(;b<3;){if(0===m)break e;m--,I+=h[p++]<<b,b+=8}r.lens[q[r.have++]]=7&I,I>>>=3,b-=3}for(;r.have<19;)r.lens[q[r.have++]]=0;if(r.lencode=r.lendyn,r.lenbits=7,L={bits:r.lenbits},O=s(0,r.lens,0,19,r.lencode,0,r.work,L),r.lenbits=L.bits,O){e.msg="invalid code lengths set",r.mode=A;break}r.have=0,r.mode=19;case 19:for(;r.have<r.nlen+r.ndist;){for(;R=(U=r.lencode[I&(1<<r.lenbits)-1])>>>16&255,D=65535&U,!((k=U>>>24)<=b);){if(0===m)break e;m--,I+=h[p++]<<b,b+=8}if(D<16)I>>>=k,b-=k,r.lens[r.have++]=D;else{if(16===D){for(P=k+2;b<P;){if(0===m)break e;m--,I+=h[p++]<<b,b+=8}if(I>>>=k,b-=k,0===r.have){e.msg="invalid bit length repeat",r.mode=A;break}M=r.lens[r.have-1],_=3+(3&I),I>>>=2,b-=2}else if(17===D){for(P=k+3;b<P;){if(0===m)break e;m--,I+=h[p++]<<b,b+=8}b-=k,M=0,_=3+(7&(I>>>=k)),I>>>=3,b-=3}else{for(P=k+7;b<P;){if(0===m)break e;m--,I+=h[p++]<<b,b+=8}b-=k,M=0,_=11+(127&(I>>>=k)),I>>>=7,b-=7}if(r.have+_>r.nlen+r.ndist){e.msg="invalid bit length repeat",r.mode=A;break}for(;_--;)r.lens[r.have++]=M}}if(r.mode===A)break;if(0===r.lens[256]){e.msg="invalid code -- missing end-of-block",r.mode=A;break}if(r.lenbits=9,L={bits:r.lenbits},O=s(1,r.lens,0,r.nlen,r.lencode,0,r.work,L),r.lenbits=L.bits,O){e.msg="invalid literal/lengths set",r.mode=A;break}if(r.distbits=6,r.distcode=r.distdyn,L={bits:r.distbits},O=s(2,r.lens,r.nlen,r.ndist,r.distcode,0,r.work,L),r.distbits=L.bits,O){e.msg="invalid distances set",r.mode=A;break}if(r.mode=20,6===t)break e;case 20:r.mode=21;case 21:if(m>=6&&C>=258){e.next_out=y,e.avail_out=C,e.next_in=p,e.avail_in=m,r.hold=I,r.bits=b,a(e,v),y=e.next_out,d=e.output,C=e.avail_out,p=e.next_in,h=e.input,m=e.avail_in,I=r.hold,b=r.bits,r.mode===c&&(r.back=-1);break}for(r.back=0;R=(U=r.lencode[I&(1<<r.lenbits)-1])>>>16&255,D=65535&U,!((k=U>>>24)<=b);){if(0===m)break e;m--,I+=h[p++]<<b,b+=8}if(R&&0==(240&R)){for(N=k,x=R,F=D;R=(U=r.lencode[F+((I&(1<<N+x)-1)>>N)])>>>16&255,D=65535&U,!(N+(k=U>>>24)<=b);){if(0===m)break e;m--,I+=h[p++]<<b,b+=8}I>>>=N,b-=N,r.back+=N}if(I>>>=k,b-=k,r.back+=k,r.length=D,0===R){r.mode=26;break}if(32&R){r.back=-1,r.mode=c;break}if(64&R){e.msg="invalid literal/length code",r.mode=A;break}r.extra=15&R,r.mode=22;case 22:if(r.extra){for(P=r.extra;b<P;){if(0===m)break e;m--,I+=h[p++]<<b,b+=8}r.length+=I&(1<<r.extra)-1,I>>>=r.extra,b-=r.extra,r.back+=r.extra}r.was=r.length,r.mode=23;case 23:for(;R=(U=r.distcode[I&(1<<r.distbits)-1])>>>16&255,D=65535&U,!((k=U>>>24)<=b);){if(0===m)break e;m--,I+=h[p++]<<b,b+=8}if(0==(240&R)){for(N=k,x=R,F=D;R=(U=r.distcode[F+((I&(1<<N+x)-1)>>N)])>>>16&255,D=65535&U,!(N+(k=U>>>24)<=b);){if(0===m)break e;m--,I+=h[p++]<<b,b+=8}I>>>=N,b-=N,r.back+=N}if(I>>>=k,b-=k,r.back+=k,64&R){e.msg="invalid distance code",r.mode=A;break}r.offset=D,r.extra=15&R,r.mode=24;case 24:if(r.extra){for(P=r.extra;b<P;){if(0===m)break e;m--,I+=h[p++]<<b,b+=8}r.offset+=I&(1<<r.extra)-1,I>>>=r.extra,b-=r.extra,r.back+=r.extra}if(r.offset>r.dmax){e.msg="invalid distance too far back",r.mode=A;break}r.mode=25;case 25:if(0===C)break e;if(_=v-C,r.offset>_){if((_=r.offset-_)>r.whave&&r.sane){e.msg="invalid distance too far back",r.mode=A;break}_>r.wnext?(_-=r.wnext,Q=r.wsize-_):Q=r.wnext-_,_>r.length&&(_=r.length),S=r.window}else S=d,Q=y-r.offset,_=r.length;_>C&&(_=C),C-=_,r.length-=_;do{d[y++]=S[Q++]}while(--_);0===r.length&&(r.mode=21);break;case 26:if(0===C)break e;d[y++]=r.length,C--,r.mode=21;break;case 27:if(r.wrap){for(;b<32;){if(0===m)break e;m--,I|=h[p++]<<b,b+=8}if(v-=C,e.total_out+=v,r.total+=v,v&&(e.adler=r.check=r.flags?i(r.check,d,v,y-v):o(r.check,d,v,y-v)),v=C,(r.flags?I:g(I))!==r.check){e.msg="incorrect data check",r.mode=A;break}I=0,b=0}r.mode=28;case 28:if(r.wrap&&r.flags){for(;b<32;){if(0===m)break e;m--,I+=h[p++]<<b,b+=8}if(I!==(4294967295&r.total)){e.msg="incorrect length check",r.mode=A;break}I=0,b=0}r.mode=29;case 29:O=1;break e;case A:O=-3;break e;case 31:return-4;default:return l}return e.next_out=y,e.avail_out=C,e.next_in=p,e.avail_in=m,r.hold=I,r.bits=b,(r.wsize||v!==e.avail_out&&r.mode<A&&(r.mode<27||4!==t))&&E(e,e.output,e.next_out,v-e.avail_out)?(r.mode=31,-4):(w-=e.avail_in,v-=e.avail_out,e.total_in+=w,e.total_out+=v,r.total+=v,r.wrap&&v&&(e.adler=r.check=r.flags?i(r.check,d,v,e.next_out-v):o(r.check,d,v,e.next_out-v)),e.data_type=r.bits+(r.last?64:0)+(r.mode===c?128:0)+(20===r.mode||15===r.mode?256:0),(0===w&&0===v||4===t)&&O===f&&(O=-5),O)},t.inflateEnd=function(e){if(!e||!e.state)return l;var t=e.state;return t.window&&(t.window=null),e.state=null,f},t.inflateGetHeader=function(e,t){var r;return e&&e.state?0==(2&(r=e.state).wrap)?l:(r.head=t,t.done=!1,f):l},t.inflateSetDictionary=function(e,t){var r,n=t.length;return e&&e.state?0!==(r=e.state).wrap&&11!==r.mode?l:11===r.mode&&o(1,t,n,0)!==r.check?-3:E(e,t,n,n)?(r.mode=31,-4):(r.havedict=1,f):l},t.inflateInfo="pako inflate (from Nodeca project)"},1998:(e,t,r)=>{"use strict";var n=r(9805),o=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0],i=[16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78],a=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0],s=[16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64];e.exports=function(e,t,r,f,l,u,c,A){var h,d,g,p,y,m,C,I,b,w=A.bits,v=0,B=0,E=0,_=0,Q=0,S=0,k=0,R=0,D=0,N=0,x=null,F=0,M=new n.Buf16(16),O=new n.Buf16(16),L=null,P=0;for(v=0;v<=15;v++)M[v]=0;for(B=0;B<f;B++)M[t[r+B]]++;for(Q=w,_=15;_>=1&&0===M[_];_--);if(Q>_&&(Q=_),0===_)return l[u++]=20971520,l[u++]=20971520,A.bits=1,0;for(E=1;E<_&&0===M[E];E++);for(Q<E&&(Q=E),R=1,v=1;v<=15;v++)if(R<<=1,(R-=M[v])<0)return-1;if(R>0&&(0===e||1!==_))return-1;for(O[1]=0,v=1;v<15;v++)O[v+1]=O[v]+M[v];for(B=0;B<f;B++)0!==t[r+B]&&(c[O[t[r+B]]++]=B);if(0===e?(x=L=c,m=19):1===e?(x=o,F-=257,L=i,P-=257,m=256):(x=a,L=s,m=-1),N=0,B=0,v=E,y=u,S=Q,k=0,g=-1,p=(D=1<<Q)-1,1===e&&D>852||2===e&&D>592)return 1;for(;;){C=v-k,c[B]<m?(I=0,b=c[B]):c[B]>m?(I=L[P+c[B]],b=x[F+c[B]]):(I=96,b=0),h=1<<v-k,E=d=1<<S;do{l[y+(N>>k)+(d-=h)]=C<<24|I<<16|b|0}while(0!==d);for(h=1<<v-1;N&h;)h>>=1;if(0!==h?(N&=h-1,N+=h):N=0,B++,0==--M[v]){if(v===_)break;v=t[r+c[B]]}if(v>Q&&(N&p)!==g){for(0===k&&(k=Q),y+=E,R=1<<(S=v-k);S+k<_&&!((R-=M[S+k])<=0);)S++,R<<=1;if(D+=1<<S,1===e&&D>852||2===e&&D>592)return 1;l[g=N&p]=Q<<24|S<<16|y-u|0}}return 0!==N&&(l[y+N]=v-k<<24|64<<16|0),A.bits=Q,0}},4674:e=>{"use strict";e.exports={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}},3665:(e,t,r)=>{"use strict";var n=r(9805);function o(e){for(var t=e.length;--t>=0;)e[t]=0}var i=256,a=286,s=30,f=15,l=16,u=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0],c=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],A=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],h=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],d=new Array(576);o(d);var g=new Array(60);o(g);var p=new Array(512);o(p);var y=new Array(256);o(y);var m=new Array(29);o(m);var C,I,b,w=new Array(s);function v(e,t,r,n,o){this.static_tree=e,this.extra_bits=t,this.extra_base=r,this.elems=n,this.max_length=o,this.has_stree=e&&e.length}function B(e,t){this.dyn_tree=e,this.max_code=0,this.stat_desc=t}function E(e){return e<256?p[e]:p[256+(e>>>7)]}function _(e,t){e.pending_buf[e.pending++]=255&t,e.pending_buf[e.pending++]=t>>>8&255}function Q(e,t,r){e.bi_valid>l-r?(e.bi_buf|=t<<e.bi_valid&65535,_(e,e.bi_buf),e.bi_buf=t>>l-e.bi_valid,e.bi_valid+=r-l):(e.bi_buf|=t<<e.bi_valid&65535,e.bi_valid+=r)}function S(e,t,r){Q(e,r[2*t],r[2*t+1])}function k(e,t){var r=0;do{r|=1&e,e>>>=1,r<<=1}while(--t>0);return r>>>1}function R(e,t,r){var n,o,i=new Array(f+1),a=0;for(n=1;n<=f;n++)i[n]=a=a+r[n-1]<<1;for(o=0;o<=t;o++){var s=e[2*o+1];0!==s&&(e[2*o]=k(i[s]++,s))}}function D(e){var t;for(t=0;t<a;t++)e.dyn_ltree[2*t]=0;for(t=0;t<s;t++)e.dyn_dtree[2*t]=0;for(t=0;t<19;t++)e.bl_tree[2*t]=0;e.dyn_ltree[512]=1,e.opt_len=e.static_len=0,e.last_lit=e.matches=0}function N(e){e.bi_valid>8?_(e,e.bi_buf):e.bi_valid>0&&(e.pending_buf[e.pending++]=e.bi_buf),e.bi_buf=0,e.bi_valid=0}function x(e,t,r,n){var o=2*t,i=2*r;return e[o]<e[i]||e[o]===e[i]&&n[t]<=n[r]}function F(e,t,r){for(var n=e.heap[r],o=r<<1;o<=e.heap_len&&(o<e.heap_len&&x(t,e.heap[o+1],e.heap[o],e.depth)&&o++,!x(t,n,e.heap[o],e.depth));)e.heap[r]=e.heap[o],r=o,o<<=1;e.heap[r]=n}function M(e,t,r){var n,o,a,s,f=0;if(0!==e.last_lit)do{n=e.pending_buf[e.d_buf+2*f]<<8|e.pending_buf[e.d_buf+2*f+1],o=e.pending_buf[e.l_buf+f],f++,0===n?S(e,o,t):(S(e,(a=y[o])+i+1,t),0!==(s=u[a])&&Q(e,o-=m[a],s),S(e,a=E(--n),r),0!==(s=c[a])&&Q(e,n-=w[a],s))}while(f<e.last_lit);S(e,256,t)}function O(e,t){var r,n,o,i=t.dyn_tree,a=t.stat_desc.static_tree,s=t.stat_desc.has_stree,l=t.stat_desc.elems,u=-1;for(e.heap_len=0,e.heap_max=573,r=0;r<l;r++)0!==i[2*r]?(e.heap[++e.heap_len]=u=r,e.depth[r]=0):i[2*r+1]=0;for(;e.heap_len<2;)i[2*(o=e.heap[++e.heap_len]=u<2?++u:0)]=1,e.depth[o]=0,e.opt_len--,s&&(e.static_len-=a[2*o+1]);for(t.max_code=u,r=e.heap_len>>1;r>=1;r--)F(e,i,r);o=l;do{r=e.heap[1],e.heap[1]=e.heap[e.heap_len--],F(e,i,1),n=e.heap[1],e.heap[--e.heap_max]=r,e.heap[--e.heap_max]=n,i[2*o]=i[2*r]+i[2*n],e.depth[o]=(e.depth[r]>=e.depth[n]?e.depth[r]:e.depth[n])+1,i[2*r+1]=i[2*n+1]=o,e.heap[1]=o++,F(e,i,1)}while(e.heap_len>=2);e.heap[--e.heap_max]=e.heap[1],function(e,t){var r,n,o,i,a,s,l=t.dyn_tree,u=t.max_code,c=t.stat_desc.static_tree,A=t.stat_desc.has_stree,h=t.stat_desc.extra_bits,d=t.stat_desc.extra_base,g=t.stat_desc.max_length,p=0;for(i=0;i<=f;i++)e.bl_count[i]=0;for(l[2*e.heap[e.heap_max]+1]=0,r=e.heap_max+1;r<573;r++)(i=l[2*l[2*(n=e.heap[r])+1]+1]+1)>g&&(i=g,p++),l[2*n+1]=i,n>u||(e.bl_count[i]++,a=0,n>=d&&(a=h[n-d]),s=l[2*n],e.opt_len+=s*(i+a),A&&(e.static_len+=s*(c[2*n+1]+a)));if(0!==p){do{for(i=g-1;0===e.bl_count[i];)i--;e.bl_count[i]--,e.bl_count[i+1]+=2,e.bl_count[g]--,p-=2}while(p>0);for(i=g;0!==i;i--)for(n=e.bl_count[i];0!==n;)(o=e.heap[--r])>u||(l[2*o+1]!==i&&(e.opt_len+=(i-l[2*o+1])*l[2*o],l[2*o+1]=i),n--)}}(e,t),R(i,u,e.bl_count)}function L(e,t,r){var n,o,i=-1,a=t[1],s=0,f=7,l=4;for(0===a&&(f=138,l=3),t[2*(r+1)+1]=65535,n=0;n<=r;n++)o=a,a=t[2*(n+1)+1],++s<f&&o===a||(s<l?e.bl_tree[2*o]+=s:0!==o?(o!==i&&e.bl_tree[2*o]++,e.bl_tree[32]++):s<=10?e.bl_tree[34]++:e.bl_tree[36]++,s=0,i=o,0===a?(f=138,l=3):o===a?(f=6,l=3):(f=7,l=4))}function P(e,t,r){var n,o,i=-1,a=t[1],s=0,f=7,l=4;for(0===a&&(f=138,l=3),n=0;n<=r;n++)if(o=a,a=t[2*(n+1)+1],!(++s<f&&o===a)){if(s<l)do{S(e,o,e.bl_tree)}while(0!=--s);else 0!==o?(o!==i&&(S(e,o,e.bl_tree),s--),S(e,16,e.bl_tree),Q(e,s-3,2)):s<=10?(S(e,17,e.bl_tree),Q(e,s-3,3)):(S(e,18,e.bl_tree),Q(e,s-11,7));s=0,i=o,0===a?(f=138,l=3):o===a?(f=6,l=3):(f=7,l=4)}}o(w);var U=!1;function T(e,t,r,o){Q(e,0+(o?1:0),3),function(e,t,r,o){N(e),_(e,r),_(e,~r),n.arraySet(e.pending_buf,e.window,t,r,e.pending),e.pending+=r}(e,t,r)}t._tr_init=function(e){U||(function(){var e,t,r,n,o,i=new Array(f+1);for(r=0,n=0;n<28;n++)for(m[n]=r,e=0;e<1<<u[n];e++)y[r++]=n;for(y[r-1]=n,o=0,n=0;n<16;n++)for(w[n]=o,e=0;e<1<<c[n];e++)p[o++]=n;for(o>>=7;n<s;n++)for(w[n]=o<<7,e=0;e<1<<c[n]-7;e++)p[256+o++]=n;for(t=0;t<=f;t++)i[t]=0;for(e=0;e<=143;)d[2*e+1]=8,e++,i[8]++;for(;e<=255;)d[2*e+1]=9,e++,i[9]++;for(;e<=279;)d[2*e+1]=7,e++,i[7]++;for(;e<=287;)d[2*e+1]=8,e++,i[8]++;for(R(d,287,i),e=0;e<s;e++)g[2*e+1]=5,g[2*e]=k(e,5);C=new v(d,u,257,a,f),I=new v(g,c,0,s,f),b=new v(new Array(0),A,0,19,7)}(),U=!0),e.l_desc=new B(e.dyn_ltree,C),e.d_desc=new B(e.dyn_dtree,I),e.bl_desc=new B(e.bl_tree,b),e.bi_buf=0,e.bi_valid=0,D(e)},t._tr_stored_block=T,t._tr_flush_block=function(e,t,r,n){var o,a,s=0;e.level>0?(2===e.strm.data_type&&(e.strm.data_type=function(e){var t,r=4093624447;for(t=0;t<=31;t++,r>>>=1)if(1&r&&0!==e.dyn_ltree[2*t])return 0;if(0!==e.dyn_ltree[18]||0!==e.dyn_ltree[20]||0!==e.dyn_ltree[26])return 1;for(t=32;t<i;t++)if(0!==e.dyn_ltree[2*t])return 1;return 0}(e)),O(e,e.l_desc),O(e,e.d_desc),s=function(e){var t;for(L(e,e.dyn_ltree,e.l_desc.max_code),L(e,e.dyn_dtree,e.d_desc.max_code),O(e,e.bl_desc),t=18;t>=3&&0===e.bl_tree[2*h[t]+1];t--);return e.opt_len+=3*(t+1)+5+5+4,t}(e),o=e.opt_len+3+7>>>3,(a=e.static_len+3+7>>>3)<=o&&(o=a)):o=a=r+5,r+4<=o&&-1!==t?T(e,t,r,n):4===e.strategy||a===o?(Q(e,2+(n?1:0),3),M(e,d,g)):(Q(e,4+(n?1:0),3),function(e,t,r,n){var o;for(Q(e,t-257,5),Q(e,r-1,5),Q(e,n-4,4),o=0;o<n;o++)Q(e,e.bl_tree[2*h[o]+1],3);P(e,e.dyn_ltree,t-1),P(e,e.dyn_dtree,r-1)}(e,e.l_desc.max_code+1,e.d_desc.max_code+1,s+1),M(e,e.dyn_ltree,e.dyn_dtree)),D(e),n&&N(e)},t._tr_tally=function(e,t,r){return e.pending_buf[e.d_buf+2*e.last_lit]=t>>>8&255,e.pending_buf[e.d_buf+2*e.last_lit+1]=255&t,e.pending_buf[e.l_buf+e.last_lit]=255&r,e.last_lit++,0===t?e.dyn_ltree[2*r]++:(e.matches++,t--,e.dyn_ltree[2*(y[r]+i+1)]++,e.dyn_dtree[2*E(t)]++),e.last_lit===e.lit_bufsize-1},t._tr_align=function(e){Q(e,2,3),S(e,256,d),function(e){16===e.bi_valid?(_(e,e.bi_buf),e.bi_buf=0,e.bi_valid=0):e.bi_valid>=8&&(e.pending_buf[e.pending++]=255&e.bi_buf,e.bi_buf>>=8,e.bi_valid-=8)}(e)}},4442:e=>{"use strict";e.exports=function(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}},9655:function(e,t,r){var n;e=r.nmd(e),function(o){t&&t.nodeType,e&&e.nodeType;var i="object"==typeof r.g&&r.g;i.global!==i&&i.window!==i&&i.self;var a,s=2147483647,f=36,l=26,u=38,c=700,A=/^xn--/,h=/[^\x20-\x7E]/,d=/[\x2E\u3002\uFF0E\uFF61]/g,g={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},p=f-1,y=Math.floor,m=String.fromCharCode;function C(e){throw new RangeError(g[e])}function I(e,t){for(var r=e.length,n=[];r--;)n[r]=t(e[r]);return n}function b(e,t){var r=e.split("@"),n="";return r.length>1&&(n=r[0]+"@",e=r[1]),n+I((e=e.replace(d,".")).split("."),t).join(".")}function w(e){for(var t,r,n=[],o=0,i=e.length;o<i;)(t=e.charCodeAt(o++))>=55296&&t<=56319&&o<i?56320==(64512&(r=e.charCodeAt(o++)))?n.push(((1023&t)<<10)+(1023&r)+65536):(n.push(t),o--):n.push(t);return n}function v(e){return I(e,(function(e){var t="";return e>65535&&(t+=m((e-=65536)>>>10&1023|55296),e=56320|1023&e),t+m(e)})).join("")}function B(e,t){return e+22+75*(e<26)-((0!=t)<<5)}function E(e,t,r){var n=0;for(e=r?y(e/c):e>>1,e+=y(e/t);e>p*l>>1;n+=f)e=y(e/p);return y(n+(p+1)*e/(e+u))}function _(e){var t,r,n,o,i,a,u,c,A,h,d,g=[],p=e.length,m=0,I=128,b=72;for((r=e.lastIndexOf("-"))<0&&(r=0),n=0;n<r;++n)e.charCodeAt(n)>=128&&C("not-basic"),g.push(e.charCodeAt(n));for(o=r>0?r+1:0;o<p;){for(i=m,a=1,u=f;o>=p&&C("invalid-input"),((c=(d=e.charCodeAt(o++))-48<10?d-22:d-65<26?d-65:d-97<26?d-97:f)>=f||c>y((s-m)/a))&&C("overflow"),m+=c*a,!(c<(A=u<=b?1:u>=b+l?l:u-b));u+=f)a>y(s/(h=f-A))&&C("overflow"),a*=h;b=E(m-i,t=g.length+1,0==i),y(m/t)>s-I&&C("overflow"),I+=y(m/t),m%=t,g.splice(m++,0,I)}return v(g)}function Q(e){var t,r,n,o,i,a,u,c,A,h,d,g,p,I,b,v=[];for(g=(e=w(e)).length,t=128,r=0,i=72,a=0;a<g;++a)(d=e[a])<128&&v.push(m(d));for(n=o=v.length,o&&v.push("-");n<g;){for(u=s,a=0;a<g;++a)(d=e[a])>=t&&d<u&&(u=d);for(u-t>y((s-r)/(p=n+1))&&C("overflow"),r+=(u-t)*p,t=u,a=0;a<g;++a)if((d=e[a])<t&&++r>s&&C("overflow"),d==t){for(c=r,A=f;!(c<(h=A<=i?1:A>=i+l?l:A-i));A+=f)b=c-h,I=f-h,v.push(m(B(h+b%I,0))),c=y(b/I);v.push(m(B(c,0))),i=E(r,p,n==o),r=0,++n}++r,++t}return v.join("")}a={version:"1.4.1",ucs2:{decode:w,encode:v},decode:_,encode:Q,toASCII:function(e){return b(e,(function(e){return h.test(e)?"xn--"+Q(e):e}))},toUnicode:function(e){return b(e,(function(e){return A.test(e)?_(e.slice(4).toLowerCase()):e}))}},void 0===(n=function(){return a}.call(t,r,t,e))||(e.exports=n)}()},4765:e=>{"use strict";var t=String.prototype.replace,r=/%20/g,n="RFC3986";e.exports={default:n,formatters:{RFC1738:function(e){return t.call(e,r,"+")},RFC3986:function(e){return String(e)}},RFC1738:"RFC1738",RFC3986:n}},5373:(e,t,r)=>{"use strict";var n=r(8636),o=r(2642),i=r(4765);e.exports={formats:i,parse:o,stringify:n}},2642:(e,t,r)=>{"use strict";var n=r(7720),o=Object.prototype.hasOwnProperty,i=Array.isArray,a={allowDots:!1,allowPrototypes:!1,allowSparse:!1,arrayLimit:20,charset:"utf-8",charsetSentinel:!1,comma:!1,decoder:n.decode,delimiter:"&",depth:5,ignoreQueryPrefix:!1,interpretNumericEntities:!1,parameterLimit:1e3,parseArrays:!0,plainObjects:!1,strictNullHandling:!1},s=function(e){return e.replace(/&#(\d+);/g,(function(e,t){return String.fromCharCode(parseInt(t,10))}))},f=function(e,t){return e&&"string"==typeof e&&t.comma&&e.indexOf(",")>-1?e.split(","):e},l=function(e,t,r,n){if(e){var i=r.allowDots?e.replace(/\.([^.[]+)/g,"[$1]"):e,a=/(\[[^[\]]*])/g,s=r.depth>0&&/(\[[^[\]]*])/.exec(i),l=s?i.slice(0,s.index):i,u=[];if(l){if(!r.plainObjects&&o.call(Object.prototype,l)&&!r.allowPrototypes)return;u.push(l)}for(var c=0;r.depth>0&&null!==(s=a.exec(i))&&c<r.depth;){if(c+=1,!r.plainObjects&&o.call(Object.prototype,s[1].slice(1,-1))&&!r.allowPrototypes)return;u.push(s[1])}return s&&u.push("["+i.slice(s.index)+"]"),function(e,t,r,n){for(var o=n?t:f(t,r),i=e.length-1;i>=0;--i){var a,s=e[i];if("[]"===s&&r.parseArrays)a=[].concat(o);else{a=r.plainObjects?Object.create(null):{};var l="["===s.charAt(0)&&"]"===s.charAt(s.length-1)?s.slice(1,-1):s,u=parseInt(l,10);r.parseArrays||""!==l?!isNaN(u)&&s!==l&&String(u)===l&&u>=0&&r.parseArrays&&u<=r.arrayLimit?(a=[])[u]=o:"__proto__"!==l&&(a[l]=o):a={0:o}}o=a}return o}(u,t,r,n)}};e.exports=function(e,t){var r=function(e){if(!e)return a;if(null!==e.decoder&&void 0!==e.decoder&&"function"!=typeof e.decoder)throw new TypeError("Decoder has to be a function.");if(void 0!==e.charset&&"utf-8"!==e.charset&&"iso-8859-1"!==e.charset)throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var t=void 0===e.charset?a.charset:e.charset;return{allowDots:void 0===e.allowDots?a.allowDots:!!e.allowDots,allowPrototypes:"boolean"==typeof e.allowPrototypes?e.allowPrototypes:a.allowPrototypes,allowSparse:"boolean"==typeof e.allowSparse?e.allowSparse:a.allowSparse,arrayLimit:"number"==typeof e.arrayLimit?e.arrayLimit:a.arrayLimit,charset:t,charsetSentinel:"boolean"==typeof e.charsetSentinel?e.charsetSentinel:a.charsetSentinel,comma:"boolean"==typeof e.comma?e.comma:a.comma,decoder:"function"==typeof e.decoder?e.decoder:a.decoder,delimiter:"string"==typeof e.delimiter||n.isRegExp(e.delimiter)?e.delimiter:a.delimiter,depth:"number"==typeof e.depth||!1===e.depth?+e.depth:a.depth,ignoreQueryPrefix:!0===e.ignoreQueryPrefix,interpretNumericEntities:"boolean"==typeof e.interpretNumericEntities?e.interpretNumericEntities:a.interpretNumericEntities,parameterLimit:"number"==typeof e.parameterLimit?e.parameterLimit:a.parameterLimit,parseArrays:!1!==e.parseArrays,plainObjects:"boolean"==typeof e.plainObjects?e.plainObjects:a.plainObjects,strictNullHandling:"boolean"==typeof e.strictNullHandling?e.strictNullHandling:a.strictNullHandling}}(t);if(""===e||null==e)return r.plainObjects?Object.create(null):{};for(var u="string"==typeof e?function(e,t){var r,l={__proto__:null},u=t.ignoreQueryPrefix?e.replace(/^\?/,""):e,c=t.parameterLimit===1/0?void 0:t.parameterLimit,A=u.split(t.delimiter,c),h=-1,d=t.charset;if(t.charsetSentinel)for(r=0;r<A.length;++r)0===A[r].indexOf("utf8=")&&("utf8=%E2%9C%93"===A[r]?d="utf-8":"utf8=%26%2310003%3B"===A[r]&&(d="iso-8859-1"),h=r,r=A.length);for(r=0;r<A.length;++r)if(r!==h){var g,p,y=A[r],m=y.indexOf("]="),C=-1===m?y.indexOf("="):m+1;-1===C?(g=t.decoder(y,a.decoder,d,"key"),p=t.strictNullHandling?null:""):(g=t.decoder(y.slice(0,C),a.decoder,d,"key"),p=n.maybeMap(f(y.slice(C+1),t),(function(e){return t.decoder(e,a.decoder,d,"value")}))),p&&t.interpretNumericEntities&&"iso-8859-1"===d&&(p=s(p)),y.indexOf("[]=")>-1&&(p=i(p)?[p]:p),o.call(l,g)?l[g]=n.combine(l[g],p):l[g]=p}return l}(e,r):e,c=r.plainObjects?Object.create(null):{},A=Object.keys(u),h=0;h<A.length;++h){var d=A[h],g=l(d,u[d],r,"string"==typeof e);c=n.merge(c,g,r)}return!0===r.allowSparse?c:n.compact(c)}},8636:(e,t,r)=>{"use strict";var n=r(920),o=r(7720),i=r(4765),a=Object.prototype.hasOwnProperty,s={brackets:function(e){return e+"[]"},comma:"comma",indices:function(e,t){return e+"["+t+"]"},repeat:function(e){return e}},f=Array.isArray,l=Array.prototype.push,u=function(e,t){l.apply(e,f(t)?t:[t])},c=Date.prototype.toISOString,A=i.default,h={addQueryPrefix:!1,allowDots:!1,charset:"utf-8",charsetSentinel:!1,delimiter:"&",encode:!0,encoder:o.encode,encodeValuesOnly:!1,format:A,formatter:i.formatters[A],indices:!1,serializeDate:function(e){return c.call(e)},skipNulls:!1,strictNullHandling:!1},d={},g=function e(t,r,i,a,s,l,c,A,g,p,y,m,C,I,b,w){for(var v,B=t,E=w,_=0,Q=!1;void 0!==(E=E.get(d))&&!Q;){var S=E.get(t);if(_+=1,void 0!==S){if(S===_)throw new RangeError("Cyclic object value");Q=!0}void 0===E.get(d)&&(_=0)}if("function"==typeof A?B=A(r,B):B instanceof Date?B=y(B):"comma"===i&&f(B)&&(B=o.maybeMap(B,(function(e){return e instanceof Date?y(e):e}))),null===B){if(s)return c&&!I?c(r,h.encoder,b,"key",m):r;B=""}if("string"==typeof(v=B)||"number"==typeof v||"boolean"==typeof v||"symbol"==typeof v||"bigint"==typeof v||o.isBuffer(B))return c?[C(I?r:c(r,h.encoder,b,"key",m))+"="+C(c(B,h.encoder,b,"value",m))]:[C(r)+"="+C(String(B))];var k,R=[];if(void 0===B)return R;if("comma"===i&&f(B))I&&c&&(B=o.maybeMap(B,c)),k=[{value:B.length>0?B.join(",")||null:void 0}];else if(f(A))k=A;else{var D=Object.keys(B);k=g?D.sort(g):D}for(var N=a&&f(B)&&1===B.length?r+"[]":r,x=0;x<k.length;++x){var F=k[x],M="object"==typeof F&&void 0!==F.value?F.value:B[F];if(!l||null!==M){var O=f(B)?"function"==typeof i?i(N,F):N:N+(p?"."+F:"["+F+"]");w.set(t,_);var L=n();L.set(d,w),u(R,e(M,O,i,a,s,l,"comma"===i&&I&&f(B)?null:c,A,g,p,y,m,C,I,b,L))}}return R};e.exports=function(e,t){var r,o=e,l=function(e){if(!e)return h;if(null!==e.encoder&&void 0!==e.encoder&&"function"!=typeof e.encoder)throw new TypeError("Encoder has to be a function.");var t=e.charset||h.charset;if(void 0!==e.charset&&"utf-8"!==e.charset&&"iso-8859-1"!==e.charset)throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var r=i.default;if(void 0!==e.format){if(!a.call(i.formatters,e.format))throw new TypeError("Unknown format option provided.");r=e.format}var n=i.formatters[r],o=h.filter;return("function"==typeof e.filter||f(e.filter))&&(o=e.filter),{addQueryPrefix:"boolean"==typeof e.addQueryPrefix?e.addQueryPrefix:h.addQueryPrefix,allowDots:void 0===e.allowDots?h.allowDots:!!e.allowDots,charset:t,charsetSentinel:"boolean"==typeof e.charsetSentinel?e.charsetSentinel:h.charsetSentinel,delimiter:void 0===e.delimiter?h.delimiter:e.delimiter,encode:"boolean"==typeof e.encode?e.encode:h.encode,encoder:"function"==typeof e.encoder?e.encoder:h.encoder,encodeValuesOnly:"boolean"==typeof e.encodeValuesOnly?e.encodeValuesOnly:h.encodeValuesOnly,filter:o,format:r,formatter:n,serializeDate:"function"==typeof e.serializeDate?e.serializeDate:h.serializeDate,skipNulls:"boolean"==typeof e.skipNulls?e.skipNulls:h.skipNulls,sort:"function"==typeof e.sort?e.sort:null,strictNullHandling:"boolean"==typeof e.strictNullHandling?e.strictNullHandling:h.strictNullHandling}}(t);"function"==typeof l.filter?o=(0,l.filter)("",o):f(l.filter)&&(r=l.filter);var c,A=[];if("object"!=typeof o||null===o)return"";c=t&&t.arrayFormat in s?t.arrayFormat:t&&"indices"in t?t.indices?"indices":"repeat":"indices";var d=s[c];if(t&&"commaRoundTrip"in t&&"boolean"!=typeof t.commaRoundTrip)throw new TypeError("`commaRoundTrip` must be a boolean, or absent");var p="comma"===d&&t&&t.commaRoundTrip;r||(r=Object.keys(o)),l.sort&&r.sort(l.sort);for(var y=n(),m=0;m<r.length;++m){var C=r[m];l.skipNulls&&null===o[C]||u(A,g(o[C],C,d,p,l.strictNullHandling,l.skipNulls,l.encode?l.encoder:null,l.filter,l.sort,l.allowDots,l.serializeDate,l.format,l.formatter,l.encodeValuesOnly,l.charset,y))}var I=A.join(l.delimiter),b=!0===l.addQueryPrefix?"?":"";return l.charsetSentinel&&("iso-8859-1"===l.charset?b+="utf8=%26%2310003%3B&":b+="utf8=%E2%9C%93&"),I.length>0?b+I:""}},7720:(e,t,r)=>{"use strict";var n=r(4765),o=Object.prototype.hasOwnProperty,i=Array.isArray,a=function(){for(var e=[],t=0;t<256;++t)e.push("%"+((t<16?"0":"")+t.toString(16)).toUpperCase());return e}(),s=function(e,t){for(var r=t&&t.plainObjects?Object.create(null):{},n=0;n<e.length;++n)void 0!==e[n]&&(r[n]=e[n]);return r};e.exports={arrayToObject:s,assign:function(e,t){return Object.keys(t).reduce((function(e,r){return e[r]=t[r],e}),e)},combine:function(e,t){return[].concat(e,t)},compact:function(e){for(var t=[{obj:{o:e},prop:"o"}],r=[],n=0;n<t.length;++n)for(var o=t[n],a=o.obj[o.prop],s=Object.keys(a),f=0;f<s.length;++f){var l=s[f],u=a[l];"object"==typeof u&&null!==u&&-1===r.indexOf(u)&&(t.push({obj:a,prop:l}),r.push(u))}return function(e){for(;e.length>1;){var t=e.pop(),r=t.obj[t.prop];if(i(r)){for(var n=[],o=0;o<r.length;++o)void 0!==r[o]&&n.push(r[o]);t.obj[t.prop]=n}}}(t),e},decode:function(e,t,r){var n=e.replace(/\+/g," ");if("iso-8859-1"===r)return n.replace(/%[0-9a-f]{2}/gi,unescape);try{return decodeURIComponent(n)}catch(e){return n}},encode:function(e,t,r,o,i){if(0===e.length)return e;var s=e;if("symbol"==typeof e?s=Symbol.prototype.toString.call(e):"string"!=typeof e&&(s=String(e)),"iso-8859-1"===r)return escape(s).replace(/%u[0-9a-f]{4}/gi,(function(e){return"%26%23"+parseInt(e.slice(2),16)+"%3B"}));for(var f="",l=0;l<s.length;++l){var u=s.charCodeAt(l);45===u||46===u||95===u||126===u||u>=48&&u<=57||u>=65&&u<=90||u>=97&&u<=122||i===n.RFC1738&&(40===u||41===u)?f+=s.charAt(l):u<128?f+=a[u]:u<2048?f+=a[192|u>>6]+a[128|63&u]:u<55296||u>=57344?f+=a[224|u>>12]+a[128|u>>6&63]+a[128|63&u]:(l+=1,u=65536+((1023&u)<<10|1023&s.charCodeAt(l)),f+=a[240|u>>18]+a[128|u>>12&63]+a[128|u>>6&63]+a[128|63&u])}return f},isBuffer:function(e){return!(!e||"object"!=typeof e||!(e.constructor&&e.constructor.isBuffer&&e.constructor.isBuffer(e)))},isRegExp:function(e){return"[object RegExp]"===Object.prototype.toString.call(e)},maybeMap:function(e,t){if(i(e)){for(var r=[],n=0;n<e.length;n+=1)r.push(t(e[n]));return r}return t(e)},merge:function e(t,r,n){if(!r)return t;if("object"!=typeof r){if(i(t))t.push(r);else{if(!t||"object"!=typeof t)return[t,r];(n&&(n.plainObjects||n.allowPrototypes)||!o.call(Object.prototype,r))&&(t[r]=!0)}return t}if(!t||"object"!=typeof t)return[t].concat(r);var a=t;return i(t)&&!i(r)&&(a=s(t,n)),i(t)&&i(r)?(r.forEach((function(r,i){if(o.call(t,i)){var a=t[i];a&&"object"==typeof a&&r&&"object"==typeof r?t[i]=e(a,r,n):t.push(r)}else t[i]=r})),t):Object.keys(r).reduce((function(t,i){var a=r[i];return o.call(t,i)?t[i]=e(t[i],a,n):t[i]=a,t}),a)}}},7392:e=>{"use strict";class t{constructor(e={}){if(!(e.maxSize&&e.maxSize>0))throw new TypeError("`maxSize` must be a number greater than 0");this.maxSize=e.maxSize,this.cache=new Map,this.oldCache=new Map,this._size=0}_set(e,t){this.cache.set(e,t),this._size++,this._size>=this.maxSize&&(this._size=0,this.oldCache=this.cache,this.cache=new Map)}get(e){if(this.cache.has(e))return this.cache.get(e);if(this.oldCache.has(e)){const t=this.oldCache.get(e);return this.oldCache.delete(e),this._set(e,t),t}}set(e,t){return this.cache.has(e)?this.cache.set(e,t):this._set(e,t),this}has(e){return this.cache.has(e)||this.oldCache.has(e)}peek(e){return this.cache.has(e)?this.cache.get(e):this.oldCache.has(e)?this.oldCache.get(e):void 0}delete(e){const t=this.cache.delete(e);return t&&this._size--,this.oldCache.delete(e)||t}clear(){this.cache.clear(),this.oldCache.clear(),this._size=0}*keys(){for(const[e]of this)yield e}*values(){for(const[,e]of this)yield e}*[Symbol.iterator](){for(const e of this.cache)yield e;for(const e of this.oldCache){const[t]=e;this.cache.has(t)||(yield e)}}get size(){let e=0;for(const t of this.oldCache.keys())this.cache.has(t)||e++;return this._size+e}}e.exports=t},6897:(e,t,r)=>{"use strict";var n=r(453),o=r(41),i=r(592)(),a=r(5795),s=r(9675),f=n("%Math.floor%");e.exports=function(e,t){if("function"!=typeof e)throw new s("`fn` is not a function");if("number"!=typeof t||t<0||t>4294967295||f(t)!==t)throw new s("`length` must be a positive 32-bit integer");var r=arguments.length>2&&!!arguments[2],n=!0,l=!0;if("length"in e&&a){var u=a(e,"length");u&&!u.configurable&&(n=!1),u&&!u.writable&&(l=!1)}return(n||l||!r)&&(i?o(e,"length",t,!0,!0):o(e,"length",t)),e}},920:(e,t,r)=>{"use strict";var n=r(453),o=r(8075),i=r(8859),a=r(9675),s=n("%WeakMap%",!0),f=n("%Map%",!0),l=o("WeakMap.prototype.get",!0),u=o("WeakMap.prototype.set",!0),c=o("WeakMap.prototype.has",!0),A=o("Map.prototype.get",!0),h=o("Map.prototype.set",!0),d=o("Map.prototype.has",!0),g=function(e,t){for(var r,n=e;null!==(r=n.next);n=r)if(r.key===t)return n.next=r.next,r.next=e.next,e.next=r,r};e.exports=function(){var e,t,r,n={assert:function(e){if(!n.has(e))throw new a("Side channel does not contain "+i(e))},get:function(n){if(s&&n&&("object"==typeof n||"function"==typeof n)){if(e)return l(e,n)}else if(f){if(t)return A(t,n)}else if(r)return function(e,t){var r=g(e,t);return r&&r.value}(r,n)},has:function(n){if(s&&n&&("object"==typeof n||"function"==typeof n)){if(e)return c(e,n)}else if(f){if(t)return d(t,n)}else if(r)return function(e,t){return!!g(e,t)}(r,n);return!1},set:function(n,o){s&&n&&("object"==typeof n||"function"==typeof n)?(e||(e=new s),u(e,n,o)):f?(t||(t=new f),h(t,n,o)):(r||(r={key:{},next:null}),function(e,t,r){var n=g(e,t);n?n.value=r:e.next={key:t,next:e.next,value:r}}(r,n,o))}};return n}},8835:(e,t,r)=>{"use strict";var n=r(9655);function o(){this.protocol=null,this.slashes=null,this.auth=null,this.host=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.query=null,this.pathname=null,this.path=null,this.href=null}var i=/^([a-z0-9.+-]+:)/i,a=/:[0-9]*$/,s=/^(\/\/?(?!\/)[^?\s]*)(\?[^\s]*)?$/,f=["{","}","|","\\","^","`"].concat(["<",">",'"',"`"," ","\r","\n","\t"]),l=["'"].concat(f),u=["%","/","?",";","#"].concat(l),c=["/","?","#"],A=/^[+a-z0-9A-Z_-]{0,63}$/,h=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,d={javascript:!0,"javascript:":!0},g={javascript:!0,"javascript:":!0},p={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0},y=r(5373);function m(e,t,r){if(e&&"object"==typeof e&&e instanceof o)return e;var n=new o;return n.parse(e,t,r),n}o.prototype.parse=function(e,t,r){if("string"!=typeof e)throw new TypeError("Parameter 'url' must be a string, not "+typeof e);var o=e.indexOf("?"),a=-1!==o&&o<e.indexOf("#")?"?":"#",f=e.split(a);f[0]=f[0].replace(/\\/g,"/");var m=e=f.join(a);if(m=m.trim(),!r&&1===e.split("#").length){var C=s.exec(m);if(C)return this.path=m,this.href=m,this.pathname=C[1],C[2]?(this.search=C[2],this.query=t?y.parse(this.search.substr(1)):this.search.substr(1)):t&&(this.search="",this.query={}),this}var I=i.exec(m);if(I){var b=(I=I[0]).toLowerCase();this.protocol=b,m=m.substr(I.length)}if(r||I||m.match(/^\/\/[^@/]+@[^@/]+/)){var w="//"===m.substr(0,2);!w||I&&g[I]||(m=m.substr(2),this.slashes=!0)}if(!g[I]&&(w||I&&!p[I])){for(var v,B,E=-1,_=0;_<c.length;_++)-1!==(Q=m.indexOf(c[_]))&&(-1===E||Q<E)&&(E=Q);for(-1!==(B=-1===E?m.lastIndexOf("@"):m.lastIndexOf("@",E))&&(v=m.slice(0,B),m=m.slice(B+1),this.auth=decodeURIComponent(v)),E=-1,_=0;_<u.length;_++){var Q;-1!==(Q=m.indexOf(u[_]))&&(-1===E||Q<E)&&(E=Q)}-1===E&&(E=m.length),this.host=m.slice(0,E),m=m.slice(E),this.parseHost(),this.hostname=this.hostname||"";var S="["===this.hostname[0]&&"]"===this.hostname[this.hostname.length-1];if(!S)for(var k=this.hostname.split(/\./),R=(_=0,k.length);_<R;_++){var D=k[_];if(D&&!D.match(A)){for(var N="",x=0,F=D.length;x<F;x++)D.charCodeAt(x)>127?N+="x":N+=D[x];if(!N.match(A)){var M=k.slice(0,_),O=k.slice(_+1),L=D.match(h);L&&(M.push(L[1]),O.unshift(L[2])),O.length&&(m="/"+O.join(".")+m),this.hostname=M.join(".");break}}}this.hostname.length>255?this.hostname="":this.hostname=this.hostname.toLowerCase(),S||(this.hostname=n.toASCII(this.hostname));var P=this.port?":"+this.port:"",U=this.hostname||"";this.host=U+P,this.href+=this.host,S&&(this.hostname=this.hostname.substr(1,this.hostname.length-2),"/"!==m[0]&&(m="/"+m))}if(!d[b])for(_=0,R=l.length;_<R;_++){var T=l[_];if(-1!==m.indexOf(T)){var q=encodeURIComponent(T);q===T&&(q=escape(T)),m=m.split(T).join(q)}}var j=m.indexOf("#");-1!==j&&(this.hash=m.substr(j),m=m.slice(0,j));var z=m.indexOf("?");if(-1!==z?(this.search=m.substr(z),this.query=m.substr(z+1),t&&(this.query=y.parse(this.query)),m=m.slice(0,z)):t&&(this.search="",this.query={}),m&&(this.pathname=m),p[b]&&this.hostname&&!this.pathname&&(this.pathname="/"),this.pathname||this.search){P=this.pathname||"";var H=this.search||"";this.path=P+H}return this.href=this.format(),this},o.prototype.format=function(){var e=this.auth||"";e&&(e=(e=encodeURIComponent(e)).replace(/%3A/i,":"),e+="@");var t=this.protocol||"",r=this.pathname||"",n=this.hash||"",o=!1,i="";this.host?o=e+this.host:this.hostname&&(o=e+(-1===this.hostname.indexOf(":")?this.hostname:"["+this.hostname+"]"),this.port&&(o+=":"+this.port)),this.query&&"object"==typeof this.query&&Object.keys(this.query).length&&(i=y.stringify(this.query,{arrayFormat:"repeat",addQueryPrefix:!1}));var a=this.search||i&&"?"+i||"";return t&&":"!==t.substr(-1)&&(t+=":"),this.slashes||(!t||p[t])&&!1!==o?(o="//"+(o||""),r&&"/"!==r.charAt(0)&&(r="/"+r)):o||(o=""),n&&"#"!==n.charAt(0)&&(n="#"+n),a&&"?"!==a.charAt(0)&&(a="?"+a),t+o+(r=r.replace(/[?#]/g,(function(e){return encodeURIComponent(e)})))+(a=a.replace("#","%23"))+n},o.prototype.resolve=function(e){return this.resolveObject(m(e,!1,!0)).format()},o.prototype.resolveObject=function(e){if("string"==typeof e){var t=new o;t.parse(e,!1,!0),e=t}for(var r=new o,n=Object.keys(this),i=0;i<n.length;i++){var a=n[i];r[a]=this[a]}if(r.hash=e.hash,""===e.href)return r.href=r.format(),r;if(e.slashes&&!e.protocol){for(var s=Object.keys(e),f=0;f<s.length;f++){var l=s[f];"protocol"!==l&&(r[l]=e[l])}return p[r.protocol]&&r.hostname&&!r.pathname&&(r.pathname="/",r.path=r.pathname),r.href=r.format(),r}if(e.protocol&&e.protocol!==r.protocol){if(!p[e.protocol]){for(var u=Object.keys(e),c=0;c<u.length;c++){var A=u[c];r[A]=e[A]}return r.href=r.format(),r}if(r.protocol=e.protocol,e.host||g[e.protocol])r.pathname=e.pathname;else{for(var h=(e.pathname||"").split("/");h.length&&!(e.host=h.shift()););e.host||(e.host=""),e.hostname||(e.hostname=""),""!==h[0]&&h.unshift(""),h.length<2&&h.unshift(""),r.pathname=h.join("/")}if(r.search=e.search,r.query=e.query,r.host=e.host||"",r.auth=e.auth,r.hostname=e.hostname||e.host,r.port=e.port,r.pathname||r.search){var d=r.pathname||"",y=r.search||"";r.path=d+y}return r.slashes=r.slashes||e.slashes,r.href=r.format(),r}var m=r.pathname&&"/"===r.pathname.charAt(0),C=e.host||e.pathname&&"/"===e.pathname.charAt(0),I=C||m||r.host&&e.pathname,b=I,w=r.pathname&&r.pathname.split("/")||[],v=(h=e.pathname&&e.pathname.split("/")||[],r.protocol&&!p[r.protocol]);if(v&&(r.hostname="",r.port=null,r.host&&(""===w[0]?w[0]=r.host:w.unshift(r.host)),r.host="",e.protocol&&(e.hostname=null,e.port=null,e.host&&(""===h[0]?h[0]=e.host:h.unshift(e.host)),e.host=null),I=I&&(""===h[0]||""===w[0])),C)r.host=e.host||""===e.host?e.host:r.host,r.hostname=e.hostname||""===e.hostname?e.hostname:r.hostname,r.search=e.search,r.query=e.query,w=h;else if(h.length)w||(w=[]),w.pop(),w=w.concat(h),r.search=e.search,r.query=e.query;else if(null!=e.search)return v&&(r.host=w.shift(),r.hostname=r.host,(S=!!(r.host&&r.host.indexOf("@")>0)&&r.host.split("@"))&&(r.auth=S.shift(),r.hostname=S.shift(),r.host=r.hostname)),r.search=e.search,r.query=e.query,null===r.pathname&&null===r.search||(r.path=(r.pathname?r.pathname:"")+(r.search?r.search:"")),r.href=r.format(),r;if(!w.length)return r.pathname=null,r.search?r.path="/"+r.search:r.path=null,r.href=r.format(),r;for(var B=w.slice(-1)[0],E=(r.host||e.host||w.length>1)&&("."===B||".."===B)||""===B,_=0,Q=w.length;Q>=0;Q--)"."===(B=w[Q])?w.splice(Q,1):".."===B?(w.splice(Q,1),_++):_&&(w.splice(Q,1),_--);if(!I&&!b)for(;_--;_)w.unshift("..");!I||""===w[0]||w[0]&&"/"===w[0].charAt(0)||w.unshift(""),E&&"/"!==w.join("/").substr(-1)&&w.push("");var S,k=""===w[0]||w[0]&&"/"===w[0].charAt(0);return v&&(r.hostname=k?"":w.length?w.shift():"",r.host=r.hostname,(S=!!(r.host&&r.host.indexOf("@")>0)&&r.host.split("@"))&&(r.auth=S.shift(),r.hostname=S.shift(),r.host=r.hostname)),(I=I||r.host&&w.length)&&!k&&w.unshift(""),w.length>0?r.pathname=w.join("/"):(r.pathname=null,r.path=null),null===r.pathname&&null===r.search||(r.path=(r.pathname?r.pathname:"")+(r.search?r.search:"")),r.auth=e.auth||r.auth,r.slashes=r.slashes||e.slashes,r.href=r.format(),r},o.prototype.parseHost=function(){var e=this.host,t=a.exec(e);t&&(":"!==(t=t[0])&&(this.port=t.substr(1)),e=e.substr(0,e.length-t.length)),e&&(this.hostname=e)},t.parse=m,t.resolve=function(e,t){return m(e,!1,!0).resolve(t)},t.resolveObject=function(e,t){return e?m(e,!1,!0).resolveObject(t):t},t.format=function(e){return"string"==typeof e&&(e=m(e)),e instanceof o?e.format():o.prototype.format.call(e)},t.Url=o},1307:function(e,t,r){var n;n=e=>(()=>{"use strict";var t=[,e=>{e.exports="data:application/wasm;base64,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IgENAAsLIAJCf4UL1RACDH8CfgJAAkAgACgCJEUNACAAKAIAIQIMAQtBACECIABBADoAKCAAQgA3AwAgAEIANwMYIABByABqQQBB5AAQhoCAgAAaIABBrAFqQQw2AgALIAAgASgCBCIDNgIQIABBsAFqIQQgAEHgAGohBSAAQcgAaiEGIABBtgFqIQcgAEGoAWohCCABKAIQIQkCQAJAAkACQANAAkACQAJAAkACQAJAAkACQAJAAkACQAJAAkACQAJAIAIOCgECAAQFBgcICQoPCyABKAIAIQogACgCqAEhAiAAKAKsASELIAEoAgQhDCABKAIIIQ0MAgsgCCAAKAKoASIMakEIaiABKAIAIAEoAgQiAmogASgCCCACayICIAAoAqwBIAxrIgwgAiAMSRsiAhCHgICAABogASABKAIEIAJqNgIEQQAhDCAAQQAgACgCqAEgAmoiAiACIAAoAqwBIgtGGzYCqAEgAiALRw0RIABBATYCAAJAIARBqIiAgABBBhCEgICAAEUNAEEFIQwMEgsgB0ECQQAQjYCAgAAgACgAuAFHDRBBBiEMIActAAANESAAIAAtALcBIgI2AiAgAkEESw0RQQEgAnRBE3FFDRELIAEoAgQiDCABKAIIIg1GDQ4CQCABKAIAIgogDGotAAAiCw0AIAAgDDYCECABIAxBAWo2AgRBBiECDAwLQQAhAiAAQQA2AqgBIABBAjYCACAAIAtBAnRBBGoiCzYCrAEgACALNgJACyAIIAJqQQhqIAogDGogDSAMayIMIAsgAmsiAiAMIAJJGyICEIeAgIAAGiABIAIgASgCBGo2AgRBACEMIABBACAAKAKoASACaiICIAIgACgCrAEiC0YbNgKoASACIAtHDQ8gACACQXxqIgI2AqwBQQchDCAEIAJBABCNgICAACAAIAAoAqwBIgtqQbABaigAAEcNDyAAQQI2AqgBIAAtALEBIgJBP3ENDAJAAkAgAkHAAHFFDQAgACAEIAggCxCRgICAAEEBRw0RIAAgACkDCDcDMCAALQCxASECDAELIABCfzcDMAtCfyEOAkAgAkEYdEEYdUF/Sg0AIAAgBCAIIAAoAqwBEJGAgIAAQQFHDRAgACkDCCEOCyAAIA43AzggACgCrAEiDSAAKAKoASICa0ECSQ0PIAAgAkEBaiIKNgKoASAIIAJqQQhqLQAAQSFHDQwgACACQQJqIgs2AqgBIAggCmpBCGotAABBAUcNDCANIAtGDQ8gACACQQNqNgKoASAAKAKwCSAIIAtqQQhqLQAAEJyAgIAAIgwNDyAAKAKoASIMIAAoAqwBIgIgDCACSxshDQJAA0AgDSAMRg0BIAggDEEBaiICNgIAIAQgDGohCyACIQwgCy0AAA0ODAALCyAGQgA3AwAgAEEANgKoASAAQQM2AgAgBkEIakIANwMACyAAIAEoAgQ2AhAgACABKAIQNgIUIAAoArAJIAEQmYCAgAAhDCAAIAApA0ggASgCBCAAKAIQa618Ig43A0ggACAAKQNQIAEoAhAgACgCFCICayILrXwiDzcDUCAOIAApAzBWDQ0gDyAAKQM4Vg0NAkACQAJAAkAgACgCIEF/ag4EAAMDAQMLIAEoAgwgAmogCyAAKAIYEI2AgIAArSEODAELIAEoAgwgAmogCyAAKQMYEI+AgIAAIQ4LIAAgDjcDGAsgDEEBRw0OAkAgACkDMCIOQn9RDQAgDiAGKQMAUg0OCwJAIAApAzgiDkJ/UQ0AQQchDCAOIAApA1BSDQ8LIAAgACkDSCAANQJAfCAAKQNgfCIPNwNgQgQhDgJAAkACQCAAKAIgQX9qDgQBAgIAAgtCCCEOCyAFIA4gD3w3AwALIAAgACkDaCAAKQNQfDcDaCAAIAVBGCAAKAJwEI2AgIAANgJwIABBBDYCACAAIAApA1hCAXw3A1gLAkAgBikDACIOQgODUA0AIA5CAXwhDiABKAIEIQwgASgCCCELA0AgCyAMRg0NIAEgDEEBaiICNgIEIAEoAgAgDGotAAANDiAGIA43AwAgDkIDgyEPIA5CAXwhDiACIQwgD0IAUg0ACwsgAEEFNgIAC0EBIQIgACgCIEF/ag4EBgcHBQcLIAAgARCSgICAACIMQQFHDQsgAEEHNgIAC0EAIAAoAhBrIQggAEGAAWopAwAhDiABKAIEIQwCQANAIA4gCCAMaq18QgODUA0BAkAgDCABKAIIRw0AIAAgARCTgICAAAwLCyABIAxBAWoiAjYCBCABKAIAIAxqIQsgAiEMIAstAAANCwwACwsgACABEJOAgIAAQQchDCAFIABBkAFqQRgQhICAgAANCiAAQQg2AgALIAAgAUEgEJSAgIAAIgxBAUcNCSAAQQk2AgBBDCELIABBDDYCrAEMAQsgACgCrAEhCwsgAEGoAWogACgCqAEiDGpBCGogASgCACABKAIEIgJqIAEoAgggAmsiAiALIAxrIgwgAiAMSRsiAhCHgICAABogASABKAIEIAJqNgIEQQAhDCAAQQAgACgCqAEgAmoiAiACIAAoAqwBIgtGGzYCqAEgAiALRw0HIAAQlYCAgAAhDAwHC0EBIQIgACABQcAAEJSAgIAAIgxBAUcNBgwBC0EBIQIgACABQSAQlICAgAAiDEEBRw0FCyAAIAI2AgAMAAsLQQYhDAwCC0EAIQwMAQtBByEMCwJAAkAgACgCJA0AAkACQCAMDgIAAwELQQdBCCABKAIEIAEoAghGGyEMCyABIAk2AhAgASADNgIEIAwPCwJAIAwNACADIAEoAgRHDQAgCSABKAIQRw0AIAAtACghASAAQQE6ACggAUEDdA8LIABBADoAKAsgDAuaAQEDfwJAIAAoAgQiBA0AIABCADcDCAsgAigCACEFA0ACQCAFIANJDQBBAA8LIAEgBWotAAAhBiACIAVBAWoiBTYCACAAIAZB/wBxrSAErYYgACkDCIQ3AwgCQAJAIAZBgAFxDQACQCAGDQBBByEGIAQNAgsgAEEANgIEQQEPC0EHIQYgACAEQQdqIgQ2AgQgBEE/Rw0BCwsgBguhAgIDfwF+IABBkAFqIQIgAUEEaiEDA0ACQCAAIAEoAgAgAyABKAIIEJGAgIAAIgRBAUYNACAAQYABaiIDIAMpAwAgASgCBCAAKAIQIgNrIgKtfDcDACAAIAMgASgCAGogAiAAKAIYEI2AgIAArTcDGCAEDwsCQAJAAkACQAJAIAAoAngOAwACAQMLIAAgACkDCCIFNwOIAQJAIAUgACkDWFENAEEHDwsgAEEBNgJ4DAMLIAAgACkDmAEgACkDCHw3A5gBIAAgAkEYIAAoAqABEI2AgIAANgKgASAAQQE2AnggACAAKQOIAUJ/fCIFNwOIAQwCCyAAQQI2AnggACAAKQOQASAAKQMIfDcDkAELIAApA4gBIQULIAVCAFINAAtBAQtAAQJ/IABBgAFqIgIgAikDACABKAIEIAAoAhAiAmsiA618NwMAIAAgAiABKAIAaiADIAAoAhgQjYCAgACtNwMYC3wBBH8gASgCBCEDIAEoAgghBANAAkAgBCADRw0AQQAPCyABIANBAWoiBTYCBAJAIAEoAgAgA2otAAAgACkDGCAAKAIEIgOtiKdB/wFxRg0AQQcPCyAAIANBCGoiBjYCBCAFIQMgBiACSQ0ACyAAQQA2AgQgAEIANwMYQQELbwEBf0EHIQECQCAAQboBai8AAEHZtAFHDQAgAEG0AWpBBkEAEI2AgIAAIABBsAFqKAAARw0AIABBgAFqKQMAQgKIIAA1ALQBUg0AIABBuAFqLQAADQBBAUEHIAAoAiAgAEG5AWotAABGGyEBCyABC7QCAQR/AkACQCAAKAIkRQ0AIAAoAgAhAwwBC0EAIQMgAEEAOgAoIABCADcDACAAQgA3AxggAEHIAGpBAEHkABCGgICAABogAEGsAWpBDDYCAEEBIQILIABByABqIQQCQAJAA0ACQCADQQpHDQAgASgCBCIDIAEoAggiBUYNAiABKAIAIQYCQANAIAYgA2otAAANASABIANBAWoiAzYCBCAAIAAoAgRBAWpBA3E2AgQgBSADRg0EDAALCwJAIAAoAgRFDQBBBw8LIAAoAiRFDQAgAEEAOgAoIABCADcDACAAQgA3AxggBEEAQeQAEIaAgIAAGiAAQQw2AqwBCyAAIAEQkICAgAAiA0EBRw0CQQohAyAAQQo2AgAMAAsLAkAgAg0AQQAPC0EHQQEgACgCBBshAwsgAwt1AQF/AkBBuAkQgICAgAAiAkUNACACIAA2AiQgAiAAIAEQm4CAgAAiADYCsAkCQCAARQ0AIAJBADoAKCACQgA3AwAgAkIANwMYIAJByABqQQBB5AAQhoCAgAAaIAJBrAFqQQw2AgAgAg8LIAIQgoCAgAALQQALHgACQCAARQ0AIAAoArAJEJ2AgIAAIAAQgoCAgAALC4ARAQx/IABB6N0BaiECIABB1ABqIQMgAEEcaiIEQQhqIQUCQAJAA0AgACgCQCEGAkACQAJAAkACQAJAAkACQAJAAkACQAJAAkACQAJAAkAgASgCBCIHIAEoAggiCEkNACAGQQdGDQEMEgsgBg4JAQIDBAUGBwAJDwsgACgCTCEGDAcLQQEhCSABIAdBAWo2AgQgASgCACAHai0AACIHRQ0IAkACQCAHQd8BSw0AIAdBAUcNAQsgAEGAAjsBUAJAIAAoAjwNACAAIAEoAgwgASgCECIGajYCGCAAIAEoAhQgBms2AiwLIARCADcCACAFQgA3AgAMCwsgAC0AUEUNCgwOCyABIAdBAWo2AgQgASgCACAHai0AACEHIABBAjYCQCAAIAdBCHQgACgCSGo2AkgMDAsgASAHQQFqNgIEIAEoAgAgB2otAAAhByAAQQM2AkAgACAHIAAoAkhqQQFqNgJIDAsLIAEgB0EBajYCBCABKAIAIAdqLQAAIQcgAEEENgJAIAAgB0EIdDYCTAwKCyABIAdBAWo2AgQgASgCACAHai0AACEHIAAgACgCRDYCQCAAIAcgACgCTGpBAWo2AkwMCQsgASAHQQFqNgIEQQchCSABKAIAIAdqLQAAIgdB4AFLDQNBACEGAkACQCAHQS1PDQBBACEIDAELIAdBU2oiByAHQf8BcUEtbiIIQS1sayEHIAhBAWohCAsgAEF/IAh0QX9zNgJ0AkAgB0H/AXFBCUkNACAHQXdqIgcgB0H/AXFBCW4iBkEJbGshByAGQQFqIQYLIAAgBjYCcCAAIAdB/wFxIgc2AmwgBiAHakEESw0DIANCADcCACADQQhqQgA3AgAgA0EQakEANgIAIABBfyAGdEF/czYCcEH4ACEHA0AgACAHakGACDsBACAHQQJqIgdB5N0BRw0ACyAAQQY2AkAgAEEFNgIIIABC/////w83AgALIAAoAkwiCUEFSQ0IAkAgACgCCCIHRQ0AIAdBf2ohBiABKAIEIQcgASgCCCEKA0AgCiAHRg0LIAEgB0EBaiIINgIEIAEoAgAgB2otAAAhByAAIAY2AgggACAHIAAoAgRBCHRyNgIEIAghByAGQX9qIgZBf0cNAAsLIABBBzYCQCAAIAlBe2oiBjYCTAsgACAAKAIgIgcgASgCFCABKAIQayIIIAAoAkgiCiAIIApJGyIIaiAAKAIsIgogCiAHayAISxs2AiggASgCCCIJIAEoAgQiCGshBwJAAkACQCAAKALk3QEiCg0AIAYNAUEAIQYLIABB5N0BaiILIApqQQRqIAEoAgAgCGogByAGIAprIgZBKiAKayIIIAggBksbIgYgBiAHSxsiBxCHgICAABoCQAJAIAcgACgC5N0BIghqIgYgACgCTEcNACALIAhqIAdqQQRqQQBBPyAGaxCGgICAABogACgC5N0BIAdqIQYMAQsCQCAGQRRLDQAgACAGNgLk3QEgASABKAIEIAdqNgIEDAMLIAZBa2ohBgsgAEEANgIQIAAgAjYCDCAAIAY2AhRBByEJIAAQmoCAgABFDQMgACgCECIIIAAoAuTdASIKIAdqSw0DIAAgACgCTCAIayIGNgJMAkAgCiAITQ0AIAAgCiAIayIHNgLk3QEgAiALIAhqQQRqIAcQhYCAgAAaDAILIABBADYC5N0BIAEgASgCBCAIIApraiIINgIEIAEoAggiCSAIayEHCwJAIAdBFUkNACAAIAg2AhAgACABKAIANgIMIAAgCUFraiAIIAZqIAcgBkEVakkbNgIUQQchCSAAEJqAgIAARQ0DIAAoAkwiByAAKAIQIgggASgCBGsiBkkNAyABIAg2AgQgACAHIAZrIgY2AkwgASgCCCAIayIHQRRLDQELIAIgASgCACAIaiAGIAcgByAGSxsiBxCHgICAABogACAHNgLk3QEgASABKAIEIAdqNgIECyAAKAIgIgYgACgCHCIIayEHAkAgACgCPEUNAAJAIAYgACgCLEcNACAAQQA2AiALIAEoAgwgASgCEGogACgCGCAIaiAHEIeAgIAAGiAAKAIgIQYLIAAgBjYCHCABIAEoAhAgB2oiBjYCECAAIAAoAkggB2siBzYCSAJAIAcNAEEHIQkgACgCTA0CIAAoAmgNAiAAKAIEDQIgAEEANgJADAULQQAhCSAGIAEoAhRGDQEgASgCBCABKAIIRw0GIAAoAuTdASAAKAJMTw0GDAELIAAoAkwiCkUNAUEAIQkgCCAHTQ0AA0AgASgCFCIGIAEoAhAiC00NASAAIAogCiAAKAIsIAAoAiAiDGsiDSAIIAdrIgggBiALayIGIAggBkkbIgYgBiANSxsiBiAGIApLGyIGazYCTCAMIAAoAhhqIAEoAgAgB2ogBhCFgICAABogACAAKAIgIAZqIgc2AiACQCAAKAIkIAdPDQAgACAHNgIkCwJAIAAoAjxFDQACQCAHIAAoAixHDQAgAEEANgIgCyABKAIMIAEoAhBqIAEoAgAgASgCBGogBhCFgICAABogACgCICEHCyAAIAc2AhwgASABKAIQIAZqNgIQIAEgASgCBCAGaiIHNgIEIAAoAkwiCkUNAiABKAIIIgggB0sNAAsLIAkPCyAAQQA2AkAMAwsgB0EYdEEYdUF/Sg0BIABBATYCQCAAIAdBEHRBgID8AHE2AkgCQCAHQcABSQ0AIABBBTYCRCAAQQA6AFEMAwsgAC0AUQ0DIABBBjYCRCAHQaABSQ0CIANCADcCACADQRBqQQA2AgAgA0EIakIANwIAQfgAIQcDQCAAIAdqQYAIOwEAIAdBAmoiB0Hk3QFHDQALCyAAQQU2AgggAEL/////DzcCAAwBCyAHQQJLDQEgAEKDgICAgAE3AkAMAAsLQQcPC0EAC/8XARJ/IABBGGohAQJAIABBIGooAgAiAiAAQShqKAIAIgNPDQAgAEHoAGoiBCgCAEUNACABIAQgACgCVBCegICAABogACgCKCEDIAAoAiAhAgsCQCACIANPDQAgAEHcDWohBSAAQegAaiEGIABB4BVqIQcgAEHUAGohCANAIAAoAhAiCSAAKAIUSw0BIAAgACgCZCIKQQV0aiAAKAJ0IAJxIgtBAXRqIgxB+ABqIQ0CQAJAIAAoAgAiBEGAgIAISQ0AIAAoAgQhDgwBCyAAIARBCHQiBDYCACAAIAlBAWoiAzYCECAAIAAoAgRBCHQgACgCDCAJai0AAHIiDjYCBCADIQkLAkACQCAOIARBC3YgDS8BACIPbCIDTw0AIAAgAzYCACANIA9BgBAgD2tBBXZqOwEAIAJBf2ohBAJAIAINACAAKAIsIARqIQQLAkACQCAAKAIkIg8NAEEAIQQMAQsgACgCGCAEai0AACEECyAAKAJwIAJxIAAoAmwiDXQgBEEIIA1rdmohDAJAAkAgCkEGSw0AQQEhBANAIAAgDEGADGxqIARBAXQiBGpB5B1qIQ0CQAJAIANB////B00NACADIQoMAQsgACADQQh0Igo2AgAgACAJQQFqIgM2AhAgACAOQQh0IAAoAgwgCWotAAByIg42AgQgAyEJCwJAAkAgDiAKQQt2IA0vAQAiD2wiA0kNACAAIA4gA2siDjYCBCAAIAogA2siAzYCACANIA8gD0EFdms7AQAgBEEBciEEDAELIAAgAzYCACANIA9BgBAgD2tBBXZqOwEACyAEQYACSQ0ADAILCyACIAAoAlQiDUF/c2ohBAJAIAIgDUsNACAAKAIsIARqIQQLAkACQCAPDQBBACEQDAELIAAoAhggBGotAAAhEAtBASEEQYACIQ0DQCAAIAxBgAxsaiAQQQF0IhAgDXEiESANaiAEakEBdGpB5B1qIQ8CQAJAIANB////B00NACADIQsMAQsgACADQQh0Igs2AgAgACAJQQFqIgM2AhAgACAOQQh0IAAoAgwgCWotAAByIg42AgQgAyEJCwJAAkAgDiALQQt2IA8vAQAiCmwiA08iEg0AIAAgAzYCACAKQYAQIAprQQV2aiEKDAELIAAgDiADayIONgIEIAAgCyADayIDNgIAIAogCkEFdmshCkEAIQ0LIA8gCjsBACANIBFzIQ0gBEEBdCASciIEQYACSQ0ACwsgACACQQFqNgIgIAAoAhggAmogBDoAAAJAIAAoAiQgACgCICICTw0AIAAgAjYCJAtBACEDAkAgACgCZCIEQQRJDQACQCAEQQlLDQAgBEF9aiEDDAELIARBemohAwsgACADNgJkDAELIAAgDiADayIONgIEIAAgBCADayIDNgIAIA0gDyAPQQV2azsBACAAIApBAXRqIg9B+ANqIQQCQAJAIANB////B00NACAJIQoMAQsgACADQQh0IgM2AgAgACAJQQFqIgo2AhAgACAOQQh0IAAoAgwgCWotAAByIg42AgQLAkACQCAOIANBC3YgBC8BACINbCIJSQ0AIAAgDiAJayIONgIEIAAgAyAJayIDNgIAIAQgDSANQQV2azsBACAPQZAEaiENAkACQCADQf///wdNDQAgCiEQDAELIAAgA0EIdCIDNgIAIAAgCkEBaiIQNgIQIAAgDkEIdCAAKAIMIApqLQAAciIONgIECwJAAkAgDiADQQt2IA0vAQAiCWwiBE8NACANIAlBgBAgCWtBBXZqOwEAIAxB2ARqIQMCQCAEQf///wdLDQAgACAEQQh0IgQ2AgAgACAQQQFqNgIQIAAgDkEIdCAAKAIMIBBqLQAAciIONgIECwJAIA4gBEELdiADLwEAIg1sIglJDQAgACAOIAlrNgIEIAAgBCAJazYCACADIA0gDUEFdms7AQAMAgsgAyANQYAQIA1rQQV2ajsBACAAIAk2AgAgAEEBNgJoIABBCUELIAAoAmRBB0kbNgJkDAMLIAAgDiAEayIONgIEIA0gCSAJQQV2azsBACAPQagEaiENAkACQCADIARrIgNB////B00NACAQIQoMAQsgACADQQh0IgM2AgAgACAQQQFqIgo2AhAgACAOQQh0IAAoAgwgEGotAAByIg42AgQLAkACQCAOIANBC3YgDS8BACIEbCIJTw0AIAAgCTYCACANIARBgBAgBGtBBXZqOwEAIAAoAlghAwwBCyAAIA4gCWsiDjYCBCANIAQgBEEFdms7AQAgD0HABGohBAJAIAMgCWsiA0H///8HSw0AIAAgA0EIdCIDNgIAIAAgCkEBajYCECAAIA5BCHQgACgCDCAKai0AAHIiDjYCBAsCQAJAIA4gA0ELdiAELwEAIg1sIglPDQAgACAJNgIAIAQgDUGAECANa0EFdmo7AQAgACgCXCEDDAELIAAgDiAJazYCBCAAIAMgCWs2AgAgACgCYCEDIAAgACgCXDYCYCAEIA0gDUEFdms7AQALIAAgACgCWDYCXAsgACAAKAJUNgJYIAAgAzYCVAsgAEEIQQsgACgCZEEHSRs2AmQgACAHIAsQn4CAgAAMAQsgBCANQYAQIA1rQQV2ajsBACAAIAk2AgAgACAAKAJcNgJgIAAgACkCVDcCWCAAQQdBCiAAKAJkQQdJGzYCZCAAIAUgCxCfgICAACAAKAJoIgNBfmpBAyADQQZJGyEKIAAoAgAhA0EBIQ4DQCAAIApBB3RqIA5BAXQiDmpB2AdqIQ0CQAJAIANBgICACEkNACAAKAIEIQQMAQsgACADQQh0IgM2AgAgACAAKAIQIgRBAWo2AhAgACAAKAIEQQh0IAQgACgCDGotAAByIgQ2AgQLAkACQCAEIANBC3YgDS8BACIJbCIPSQ0AIAAgBCAPayIENgIEIAAgAyAPayIDNgIAIA0gCSAJQQV2azsBACAOQQFyIQ4MAQsgACAPNgIAIA0gCUGAECAJa0EFdmo7AQAgDyEDCyAOQcAASQ0ACwJAIA5BQGoiCUEDSw0AIAAgCTYCVAwBCyAAIA5BAXFBAnIiDTYCVCAJQQF2IQ8CQCAJQQ1LDQAgACANIA9Bf2oiDHQiCzYCVEEBIQ0gCCALQQF0akGEC2ohEEE/IA5rIRFBACEPA0AgECARIA1qQQF0aiEOAkACQCADQf///wdNDQAgAyEKDAELIAAgA0EIdCIKNgIAIAAgACgCECIDQQFqNgIQIAAgBEEIdCADIAAoAgxqLQAAciIENgIECwJAAkAgBCAKQQt2IA4vAQAiCWwiA0kNACAAIAQgA2siBDYCBCAAIAogA2siAzYCACAOIAkgCUEFdms7AQAgAEEBIA90IAtqIgs2AlQgDUEBdEEBciENDAELIAAgAzYCACAOIAlBgBAgCWtBBXZqOwEAIA1BAXQhDQsgDCAPQQFqIg9HDQAMAgsLIA9Be2ohDgNAAkAgA0H///8HSw0AIAAgA0EIdCIDNgIAIAAgACgCECIJQQFqNgIQIARBCHQgCSAAKAIMai0AAHIhBAsgACADQQF2IgM2AgAgACAEIANrIgRBH3UiCSANQQF0akEBaiINNgJUIAAgCSADcSAEaiIENgIEIA5Bf2oiDg0ACyAAIA1BBHQiCzYCVEEAIQ9BASEOA0AgACAOQQF0Ig5qQbwNaiENAkACQCADQf///wdNDQAgAyEKDAELIAAgA0EIdCIKNgIAIAAgACgCECIDQQFqNgIQIAAgBEEIdCADIAAoAgxqLQAAciIENgIECwJAAkAgBCAKQQt2IA0vAQAiCWwiA0kNACAAIAQgA2siBDYCBCAAIAogA2siAzYCACANIAkgCUEFdms7AQAgAEEBIA90IAtqIgs2AlQgDkEBciEODAELIAAgAzYCACANIAlBgBAgCWtBBXZqOwEACyAPQQFqIg9BBEcNAAsLAkAgASAGIAAoAlQQnoCAgAANAEEADwsgACgCICECCyACIAAoAihJDQALC0EBIQMCQCAAKAIAIgRB////B0sNACAAIARBCHQ2AgBBASEDIAAgACgCECIEQQFqNgIQIAAgACgCBEEIdCAEIAAoAgxqLQAAcjYCBAsgAwtwAQF/AkBBqN4BEICAgIAAIgJFDQAgAkE0aiABNgIAIAJBPGogADYCAAJAAkACQCAAQX9qDgIAAQILIAIgARCAgICAACIANgIYIAANASACEIKAgIAADAILIAJBADYCGCACQThqQQA2AgALIAIPC0EAC9IBAQJ/QQYhAgJAIAFBJ0sNACAAQTBqIAFBAXFBAnIgAUEBdkELanQiATYCAAJAAkAgAEE8aigCACIDRQ0AQQQhAiABIABBNGooAgBLDQIgAEEsaiABNgIAIANBAkcNACAAQThqIgMoAgAgAU8NACAAIAE2AjggACgCGBCCgICAACAAIAAoAjAQgICAgAAiATYCGCABDQBBAyECDAELQQAhAiAAQQA2AkAgAEHQAGpBAToAACAAQegAakEANgIAIABB5N0BaiEDCyADQQA2AgALIAILIwACQCAAQTxqKAIARQ0AIAAoAhgQgoCAgAALIAAQgoCAgAAL9QEBBH9BACEDAkAgACgCDCACTQ0AIAAoAhggAk0NACABIAEoAgAiBCAAKAIQIAAoAggiBWsiBiAEIAYgBEkbIgRrNgIAIAUgAkF/c2ohAQJAIAUgAksNACAAKAIUIAFqIQELIAAoAgAiAiABai0AACEGQQEhAyAAIAVBAWo2AgggAiAFaiAGOgAAAkAgBEF/aiICRQ0AA0AgACgCACIFQQAgAUEBaiIBIAEgACgCFEYbIgFqLQAAIQQgACAAKAIIIgZBAWo2AgggBSAGaiAEOgAAIAJBf2oiAg0ACwsgACgCDCAAKAIIIgFPDQAgACABNgIMCyADC8gEAQd/AkACQCAAKAIAIgNBgICACEkNACAAKAIEIQQMAQsgACADQQh0IgM2AgAgACAAKAIQIgVBAWo2AhAgACAAKAIEQQh0IAUgACgCDGotAAByIgQ2AgQLAkACQCAEIANBC3YgAS8BACIGbCIFTw0AIAEgBkGAECAGa0EFdmo7AQAgASACQQR0akEEaiEHQQghCEECIQkMAQsgACAEIAVrIgQ2AgQgASAGIAZBBXZrOwEAAkAgAyAFayIDQf///wdLDQAgACADQQh0IgM2AgAgACAAKAIQIgVBAWo2AhAgACAEQQh0IAUgACgCDGotAAByIgQ2AgQLAkAgBCADQQt2IAEvAQIiBmwiBU8NACABIAZBgBAgBmtBBXZqOwECIAEgAkEEdGpBhAJqIQdBCCEIQQohCQwBCyAAIAQgBWsiBDYCBCABIAYgBkEFdms7AQIgAUGEBGohByADIAVrIQVBgAIhCEESIQkLIABB6ABqIAk2AgBBASEBA0AgByABQQF0IgFqIQMCQAJAIAVB////B00NACAFIQIMAQsgACAFQQh0IgI2AgAgACAAKAIQIgVBAWo2AhAgACAEQQh0IAUgACgCDGotAAByIgQ2AgQLAkACQCAEIAJBC3YgAy8BACIGbCIFSQ0AIAAgBCAFayIENgIEIAAgAiAFayIFNgIAIAMgBiAGQQV2azsBACABQQFyIQEMAQsgACAFNgIAIAMgBkGAECAGa0EFdmo7AQALIAEgCEkNAAsgAEHoAGogASAIayAJajYCAAsLNQEAQYAICy4IAAAAEAAAABgAAAAgAAAAKAAAADAAAABAAAAAUAAAAIAAAAAAAQAA/Td6WFoA"},t=>{t.exports=e}],r={};function n(e){var o=r[e];if(void 0!==o)return o.exports;var i=r[e]={exports:{}};return t[e](i,i.exports,n),i.exports}n.d=(e,t)=>{for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var o={};return(()=>{n.r(o),n.d(o,{XzReadableStream:()=>i});var e=n(1);const t=globalThis.ReadableStream||n(2).ReadableStream;class r{constructor(e){this.exports=e.exports,this.memory=this.exports.memory,this.ptr=this.exports.create_context(),this._refresh(),this.bufSize=this.mem32[0],this.inStart=this.mem32[1]-this.ptr,this.inEnd=this.inStart+this.bufSize,this.outStart=this.mem32[4]-this.ptr}supplyInput(e){this.mem8.subarray(this.inStart,this.inEnd).set(e,0),this.exports.supply_input(this.ptr,e.byteLength),this._refresh()}getNextOutput(){const e=this.exports.get_next_output(this.ptr);if(this._refresh(),0!==e&&1!==e)throw new Error(`get_next_output failed with error code ${e}`);return{outChunk:this.mem8.slice(this.outStart,this.outStart+this.mem32[5]),finished:1===e}}needsMoreInput(){return this.mem32[2]===this.mem32[3]}outputBufferIsFull(){return this.mem32[5]===this.bufSize}resetOutputBuffer(){this.outPos=this.mem32[5]=0}dispose(){this.exports.destroy_context(this.ptr),this.exports=null}_refresh(){this.memory.buffer!==this.mem8?.buffer&&(this.mem8=new Uint8Array(this.memory.buffer,this.ptr),this.mem32=new Uint32Array(this.memory.buffer,this.ptr))}}class i extends t{static _moduleInstancePromise;static _moduleInstance;static async _getModuleInstance(){const t=e.replace("data:application/wasm;base64,",""),r=Uint8Array.from(atob(t),(e=>e.charCodeAt(0))).buffer,n=await WebAssembly.instantiate(r,{});i._moduleInstance=n.instance}constructor(e){let t,n=null;const o=e.getReader();super({async start(e){i._moduleInstance||await(i._moduleInstancePromise||(i._moduleInstancePromise=i._getModuleInstance())),t=new r(i._moduleInstance)},async pull(e){if(t.needsMoreInput()){if(null===n||0===n.byteLength){const{done:e,value:t}=await o.read();e||(n=t)}const e=Math.min(t.bufSize,n.byteLength);t.supplyInput(n.subarray(0,e)),n=n.subarray(e)}const r=t.getNextOutput();e.enqueue(r.outChunk),t.resetOutputBuffer(),r.finished&&(t.dispose(),e.close())},cancel:()=>(t.dispose(),o.cancel())})}}})(),o})(),e.exports=n(r(772))},3617:()=>{},2634:()=>{},772:()=>{},4132:e=>{"use strict";function t(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}const r=new Int32Array([0,1996959894,3993919788,2567524794,124634137,1886057615,3915621685,2657392035,249268274,2044508324,3772115230,2547177864,162941995,2125561021,3887607047,2428444049,498536548,1789927666,4089016648,2227061214,450548861,1843258603,4107580753,2211677639,325883990,1684777152,4251122042,2321926636,335633487,1661365465,4195302755,2366115317,997073096,1281953886,3579855332,2724688242,1006888145,1258607687,3524101629,2768942443,901097722,1119000684,3686517206,2898065728,853044451,1172266101,3705015759,2882616665,651767980,1373503546,3369554304,3218104598,565507253,1454621731,3485111705,3099436303,671266974,1594198024,3322730930,2970347812,795835527,1483230225,3244367275,3060149565,1994146192,31158534,2563907772,4023717930,1907459465,112637215,2680153253,3904427059,2013776290,251722036,2517215374,3775830040,2137656763,141376813,2439277719,3865271297,1802195444,476864866,2238001368,4066508878,1812370925,453092731,2181625025,4111451223,1706088902,314042704,2344532202,4240017532,1658658271,366619977,2362670323,4224994405,1303535960,984961486,2747007092,3569037538,1256170817,1037604311,2765210733,3554079995,1131014506,879679996,2909243462,3663771856,1141124467,855842277,2852801631,3708648649,1342533948,654459306,3188396048,3373015174,1466479909,544179635,3110523913,3462522015,1591671054,702138776,2966460450,3352799412,1504918807,783551873,3082640443,3233442989,3988292384,2596254646,62317068,1957810842,3939845945,2647816111,81470997,1943803523,3814918930,2489596804,225274430,2053790376,3826175755,2466906013,167816743,2097651377,4027552580,2265490386,503444072,1762050814,4150417245,2154129355,426522225,1852507879,4275313526,2312317920,282753626,1742555852,4189708143,2394877945,397917763,1622183637,3604390888,2714866558,953729732,1340076626,3518719985,2797360999,1068828381,1219638859,3624741850,2936675148,906185462,1090812512,3747672003,2825379669,829329135,1181335161,3412177804,3160834842,628085408,1382605366,3423369109,3138078467,570562233,1426400815,3317316542,2998733608,733239954,1555261956,3268935591,3050360625,752459403,1541320221,2607071920,3965973030,1969922972,40735498,2617837225,3943577151,1913087877,83908371,2512341634,3803740692,2075208622,213261112,2463272603,3855990285,2094854071,198958881,2262029012,4057260610,1759359992,534414190,2176718541,4139329115,1873836001,414664567,2282248934,4279200368,1711684554,285281116,2405801727,4167216745,1634467795,376229701,2685067896,3608007406,1308918612,956543938,2808555105,3495958263,1231636301,1047427035,2932959818,3654703836,1088359270,936918e3,2847714899,3736837829,1202900863,817233897,3183342108,3401237130,1404277552,615818150,3134207493,3453421203,1423857449,601450431,3009837614,3294710456,1567103746,711928724,3020668471,3272380065,1510334235,755167117]);function n(e){if(Buffer.isBuffer(e))return e;if("number"==typeof e)return Buffer.alloc(e);if("string"==typeof e)return Buffer.from(e);throw new Error("input must be buffer, number, or string, received "+typeof e)}function o(e,t){e=n(e),Buffer.isBuffer(t)&&(t=t.readUInt32BE(0));let o=-1^~~t;for(var i=0;i<e.length;i++)o=r[255&(o^e[i])]^o>>>8;return-1^o}function i(){return function(e){const t=n(4);return t.writeInt32BE(e,0),t}(o.apply(null,arguments))}i.signed=function(){return o.apply(null,arguments)},i.unsigned=function(){return o.apply(null,arguments)>>>0};const a=t(i);e.exports=a}},t={};function r(n){var o=t[n];if(void 0!==o)return o.exports;var i=t[n]={id:n,loaded:!1,exports:{}};return e[n].call(i.exports,i,i.exports,r),i.loaded=!0,i.exports}r.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return r.d(t,{a:t}),t},r.d=(e,t)=>{for(var n in t)r.o(t,n)&&!r.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},r.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.nmd=e=>(e.paths=[],e.children||(e.children=[]),e);var n=r(7806);window.gmodCRAM=n})();
2
+ (()=>{var e={4923:function(e,t,r){"use strict";var n=this&&this.__awaiter||function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function s(e){try{A(n.next(e))}catch(e){o(e)}}function a(e){try{A(n.throw(e))}catch(e){o(e)}}function A(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}A((n=n.apply(e,t||[])).next())}))},i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});const o=i(r(7430)),s=i(r(7392)),a=r(8712),A=r(5931),f=r(9747);function h(e,t){const[r,n,i,o,s,a]=t;e[r]||(e[r]=[]),e[r].push({start:n,span:i,containerStart:o,sliceStart:s,sliceBytes:a})}t.default=class{constructor(e){this.filehandle=(0,A.open)(e.url,e.path,e.filehandle),this._parseCache=new o.default({cache:new s.default({maxSize:1}),fill:(e,t)=>this.parseIndex()})}parseIndex(){const e={};return this.filehandle.readFile().then((e=>31===e[0]&&139===e[1]?(0,a.unzip)(e):e)).then((t=>{if(t.length>4&&21578050===t.readUInt32LE(0))throw new f.CramMalformedError("invalid .crai index file. note: file appears to be a .bai index. this is technically legal but please open a github issue if you need support");let r=[],n="";for(const i of t)if(i>=48&&i<=57||!n&&45===i)n+=String.fromCharCode(i);else if(9===i)r.push(Number.parseInt(n,10)),n="";else if(10===i)r.push(Number.parseInt(n,10)),n="",h(e,r),r=[];else if(13!==i&&32!==i)throw new f.CramMalformedError("invalid .crai index file");return n&&r.push(Number.parseInt(n,10)),6===r.length&&h(e,r),Object.entries(e).forEach((([t,r])=>{e[t]=r.sort(((e,t)=>e.start-t.start||e.span-t.span))})),e}))}getIndex(e={}){return this._parseCache.get("index",null,e.signal)}hasDataForReferenceSequence(e){return n(this,void 0,void 0,(function*(){return!!(yield this.getIndex())[e]}))}getEntriesForRange(e,t,r){return n(this,void 0,void 0,(function*(){const n=(yield this.getIndex())[e];if(!n)return[];const i=e=>{const n=e.start,i=e.start+e.span;return n>r?-1:i<=t?1:0},o=[];for(const e of n)0===i(e)&&o.push(e);return o}))}}},9508:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=class{constructor(e,t){this.parameters=e,this.dataType=t}}},368:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});const i=r(9747),o=n(r(9508)),s=r(612);class a extends o.default{constructor(e,t){if(super(e,t),"int"!==this.dataType)throw new i.CramUnimplementedError(`${this.dataType} decoding not yet implemented by BETA codec`)}decode(e,t,r,n){return(0,s.getBits)(t.content,n.coreBlock,this.parameters.length)-this.parameters.offset}}t.default=a},8635:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});const i=r(400),o=n(r(9508));class s extends o.default{constructor(e,t,r){if(super(e,t),this.instantiateCodec=r,"byteArray"!==t)throw new TypeError(`byteArrayLength does not support data type ${t}`)}decode(e,t,r,n){const i=this._getLengthCodec().decode(e,t,r,n),o=this._getDataCodec(),s=new Uint8Array(i);for(let a=0;a<i;a+=1)s[a]=o.decode(e,t,r,n);return s}_getLengthCodec(){const e=this.parameters.lengthsEncoding;return this.instantiateCodec(e,"int")}_getDataCodec(){const e=this.parameters.valuesEncoding;return this.instantiateCodec(e,"byte")}}t.default=s,"_getLengthCodec _getDataCodec".split(" ").forEach((e=>(0,i.tinyMemoize)(s,e)))},4839:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});const i=r(9747),o=n(r(9508)),s=r(612);class a extends o.default{constructor(e,t){if(super(e,t),"byteArray"!==t)throw new TypeError(`byteArrayStop codec does not support data type ${t}`)}decode(e,t,r,n){const{blockContentId:o}=this.parameters,s=r[o];if(!s)throw new i.CramMalformedError(`no block found with content ID ${o}`);const a=n.externalBlocks.getCursor(o);return this._decodeByteArray(s,a)}_decodeByteArray(e,t){const r=e.content,{stopByte:n}=this.parameters,i=t.bytePosition;let o=t.bytePosition;for(;r[o]!==n&&o<r.length;){if(o===r.length)throw new s.CramBufferOverrunError("byteArrayStop reading beyond length of data buffer?");o+=1}return t.bytePosition=o+1,r.subarray(i,o)}}t.default=a},8153:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});const i=r(9747),o=n(r(9508)),s=r(400),a=r(612);class A extends o.default{constructor(e,t){if(super(e,t),"int"===this.dataType)this._decodeData=this._decodeInt;else{if("byte"!==this.dataType)throw new i.CramUnimplementedError(`${this.dataType} decoding not yet implemented by EXTERNAL codec`);this._decodeData=this._decodeByte}}decode(e,t,r,n){const{blockContentId:o}=this.parameters,s=r[o];if(!s)throw new i.CramMalformedError(`no block found with content ID ${o}`);const a=n.externalBlocks.getCursor(o);return this._decodeData(s,a)}_decodeInt(e,t){const[r,n]=(0,s.parseItf8)(e.content,t.bytePosition);return t.bytePosition=t.bytePosition+n,r}_decodeByte(e,t){if(t.bytePosition>=e.content.length)throw new a.CramBufferOverrunError("attempted to read beyond end of block. this file seems truncated.");return e.content[t.bytePosition++]}}t.default=A},8185:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});const i=r(9747),o=n(r(9508)),s=r(612);class a extends o.default{constructor(e,t){if(super(e,t),"int"!==this.dataType)throw new i.CramUnimplementedError(`${this.dataType} decoding not yet implemented by GAMMA codec`)}decode(e,t,r,n){let i=1;for(;0===(0,s.getBits)(t.content,n.coreBlock,1);)i+=1;return((0,s.getBits)(t.content,n.coreBlock,i-1)|1<<i-1)-this.parameters.offset}}t.default=a},612:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.CramBufferOverrunError=void 0,t.getBits=function(e,t,n){let i=0;if(t.bytePosition+(7-t.bitPosition+n)/8>e.length)throw new r("read error during decoding. the file seems to be truncated.");for(let r=n;r;r--)i<<=1,i|=e[t.bytePosition]>>t.bitPosition&1,t.bitPosition-=1,t.bitPosition<0&&(t.bytePosition+=1),t.bitPosition&=7;return i};class r extends Error{}t.CramBufferOverrunError=r},4341:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});const i=r(9747),o=n(r(9508)),s=r(612);class a extends o.default{constructor(e,t){if(super(e,t),this.codes={},this.codeBook={},this.sortedCodes=[],this.sortedValuesByBitCode=[],this.sortedBitCodes=[],this.sortedBitLengthsByBitCode=[],this.bitCodeToValue=[],!["byte","int"].includes(this.dataType))throw new TypeError(`${this.dataType} decoding not yet implemented by HUFFMAN_INT codec`);this.buildCodeBook(),this.buildCodes(),this.buildCaches(),0===this.sortedCodes[0].bitLength&&(this._decode=this._decodeZeroLengthCode)}buildCodeBook(){let e=new Array(this.parameters.numCodes);for(let t=0;t<this.parameters.numCodes;t+=1)e[t]={symbol:this.parameters.symbols[t],bitLength:this.parameters.bitLengths[t]};e=e.sort(((e,t)=>e.bitLength-t.bitLength||e.symbol-t.symbol)),this.codeBook={},e.forEach((e=>{this.codeBook[e.bitLength]||(this.codeBook[e.bitLength]=[]),this.codeBook[e.bitLength].push(e.symbol)}))}buildCodes(){this.codes={};let e=0,t=-1;Object.entries(this.codeBook).forEach((([r,n])=>{const o=parseInt(r,10);n.forEach((r=>{const n={bitLength:o,value:r,bitCode:0};t+=1;const s=o-e;if(t<<=s,n.bitCode=t,e+=s,function(e){let t=e-(e>>1)&1431655765;return t=(858993459&t)+(t>>2&858993459),16843009*(t+(t>>4)&252645135)>>24}(t)>o)throw new i.CramMalformedError("Symbol out of range");this.codes[r]=n}))}))}buildCaches(){this.sortedCodes=Object.values(this.codes).sort(((e,t)=>e.bitLength-t.bitLength||e.bitCode-t.bitCode)),this.sortedValuesByBitCode=this.sortedCodes.map((e=>e.value)),this.sortedBitCodes=this.sortedCodes.map((e=>e.bitCode)),this.sortedBitLengthsByBitCode=this.sortedCodes.map((e=>e.bitLength));const e=Math.max(...this.sortedBitCodes);this.bitCodeToValue=new Array(e+1).fill(-1);for(let e=0;e<this.sortedBitCodes.length;e+=1)this.bitCodeToValue[this.sortedCodes[e].bitCode]=e}decode(e,t,r,n){return this._decode(e,t,n.coreBlock)}_decodeZeroLengthCode(){return this.sortedCodes[0].value}_decode(e,t,r){const n=t.content;let o=0,a=0;for(let e=0;e<this.sortedCodes.length;e+=1){const t=this.sortedCodes[e].bitLength;a<<=t-o,a|=(0,s.getBits)(n,r,t-o),o=t;{const r=this.bitCodeToValue[a];if(r>-1&&this.sortedBitLengthsByBitCode[r]===t)return this.sortedValuesByBitCode[r];for(let r=e;this.sortedCodes[r+1].bitLength===t&&r<this.sortedCodes.length;r+=1)e+=1}}throw new i.CramMalformedError("Huffman symbol not found.")}}t.default=a},6524:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.instantiateCodec=function e(t,r){const n=(o="ignore"===r?0:t.codecId,l[o]);var o;if(!n)throw new i.CramUnimplementedError(`no codec implemented for codec ID ${t.codecId}`);return new n(t.parameters,r,e)};const i=r(9747),o=n(r(4341)),s=n(r(8153)),a=n(r(4839)),A=n(r(8635)),f=n(r(368)),h=n(r(8185)),u=n(r(99)),l={1:s.default,3:o.default,4:A.default,5:a.default,6:f.default,7:u.default,9:h.default}},99:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});const i=r(9747),o=n(r(9508)),s=r(612);class a extends o.default{constructor(e,t){if(super(e,t),"int"!==this.dataType)throw new i.CramUnimplementedError(`${this.dataType} decoding not yet implemented by SUBEXP codec`)}decode(e,t,r,n){let i,o,a=0;for(;(0,s.getBits)(t.content,n.coreBlock,1);)a+=1;return 0===a?(i=this.parameters.K,o=(0,s.getBits)(t.content,n.coreBlock,i)):(i=a+this.parameters.K-1,o=1<<i|(0,s.getBits)(t.content,n.coreBlock,i)),o-this.parameters.offset}}t.default=a},7295:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default={CRAM_FLAG_PRESERVE_QUAL_SCORES:1,CRAM_FLAG_DETACHED:2,CRAM_FLAG_MATE_DOWNSTREAM:4,CRAM_FLAG_NO_SEQ:8,CRAM_FLAG_MASK:15,CRAM_M_REVERSE:1,CRAM_M_UNMAP:2,BAM_FPAIRED:1,BAM_FPROPER_PAIR:2,BAM_FUNMAP:4,BAM_FMUNMAP:8,BAM_FREVERSE:16,BAM_FMREVERSE:32,BAM_FREAD1:64,BAM_FREAD2:128,BAM_FSECONDARY:256,BAM_FQCFAIL:512,BAM_FDUP:1024,BAM_FSUPPLEMENTARY:2048,BAM_CMATCH:0,BAM_CINS:1,BAM_CDEL:2,BAM_CREF_SKIP:3,BAM_CSOFT_CLIP:4,BAM_CHARD_CLIP:5,BAM_CPAD:6,BAM_CEQUAL:7,BAM_CDIFF:8,BAM_CBACK:9,BAM_CIGAR_STR:"MIDNSHP:XB",BAM_CIGAR_SHIFT:4,BAM_CIGAR_MASK:15,BAM_CIGAR_TYPE:246183}},7219:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(6524),i=r(9747),o={BF:"int",CF:"int",RI:"int",RL:"int",AP:"int",RG:"int",MF:"int",NS:"int",NP:"int",TS:"int",NF:"int",TC:"byte",TN:"int",FN:"int",FC:"byte",FP:"int",BS:"byte",IN:"byteArray",SC:"byteArray",DL:"int",BA:"byte",BB:"byteArray",RS:"int",PD:"int",HC:"int",MQ:"int",RN:"byteArray",QS:"byte",QQ:"byteArray",TL:"int"};t.default=class{constructor(e){this.dataSeriesCodecCache={},this.tagCodecCache={},this.tagEncoding={},this.readNamesIncluded=e.preservation.RN,this.APdelta=e.preservation.AP,this.referenceRequired=!!e.preservation.RR,this.tagIdsDictionary=e.preservation.TD,this.substitutionMatrix=function(e){const t=new Array(5);for(let e=0;e<5;e+=1)t[e]=new Array(4);return t[0][e[0]>>6&3]="C",t[0][e[0]>>4&3]="G",t[0][e[0]>>2&3]="T",t[0][3&e[0]]="N",t[1][e[1]>>6&3]="A",t[1][e[1]>>4&3]="G",t[1][e[1]>>2&3]="T",t[1][3&e[1]]="N",t[2][e[2]>>6&3]="A",t[2][e[2]>>4&3]="C",t[2][e[2]>>2&3]="T",t[2][3&e[2]]="N",t[3][e[3]>>6&3]="A",t[3][e[3]>>4&3]="C",t[3][e[3]>>2&3]="G",t[3][3&e[3]]="N",t[4][e[4]>>6&3]="A",t[4][e[4]>>4&3]="C",t[4][e[4]>>2&3]="G",t[4][3&e[4]]="T",t}(e.preservation.SM),this.dataSeriesEncoding=e.dataSeriesEncoding,this.tagEncoding=e.tagEncoding,this.preservation=e.preservation,this._size=e._size,this._endPosition=e._endPosition}getCodecForTag(e){if(!this.tagCodecCache[e]){const t=this.tagEncoding[e];t&&(this.tagCodecCache[e]=(0,n.instantiateCodec)(t,"byteArray"))}return this.tagCodecCache[e]}getTagNames(e){return this.tagIdsDictionary[e]}getCodecForDataSeries(e){let t=this.dataSeriesCodecCache[e];if(void 0===t){const r=this.dataSeriesEncoding[e];if(r){const s=o[e];if(!s)throw new i.CramMalformedError(`data series name ${e} not defined in file compression header`);t=(0,n.instantiateCodec)(r,s),this.dataSeriesCodecCache[e]=t}}return t}toJSON(){const e={};return Object.keys(this).forEach((t=>{t.endsWith("Cache")||(e[t]=this[t])})),e}}},78:function(e,t,r){"use strict";var n=this&&this.__awaiter||function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function s(e){try{A(n.next(e))}catch(e){o(e)}}function a(e){try{A(n.throw(e))}catch(e){o(e)}}function A(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}A((n=n.apply(e,t||[])).next())}))},i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});const o=r(9747),s=r(400),a=i(r(6771)),A=i(r(7219));class f{constructor(e,t){this.file=e,this.filePosition=t}getHeader(){return this._readContainerHeader(this.filePosition)}getCompressionHeaderBlock(){return n(this,void 0,void 0,(function*(){if(!(yield this.getHeader()).numRecords)return null;const e=yield this.file.getSectionParsers(),t=yield this.getFirstBlock();if(void 0===t)return;if("COMPRESSION_HEADER"!==t.contentType)throw new o.CramMalformedError(`invalid content type ${t.contentType} in what is supposed to be the compression header block`);const r=(0,s.parseItem)(t.content,e.cramCompressionHeader.parser,0,t.contentPosition);return Object.assign(Object.assign({},t),{parsedContent:r})}))}getFirstBlock(){return n(this,void 0,void 0,(function*(){const e=yield this.getHeader();return this.file.readBlock(e._endPosition)}))}getCompressionScheme(){return n(this,void 0,void 0,(function*(){const e=yield this.getCompressionHeaderBlock();if(e)return new A.default(e.parsedContent)}))}getSlice(e,t){return new a.default(this,e,t)}_readContainerHeader(e){return n(this,void 0,void 0,(function*(){const t=yield this.file.getSectionParsers(),{cramContainerHeader1:r,cramContainerHeader2:n}=t,{size:i}=yield this.file.stat();if(e>=i)return;const o=Buffer.allocUnsafe(r.maxLength);yield this.file.read(o,0,r.maxLength,e);const a=(0,s.parseItem)(o,r.parser),A=(0,s.itf8Size)(a.numLandmarks);if(e+a.length>=i)return void console.warn(`${this.file}: container header at ${e} indicates that the container has length ${a.length}, which extends beyond the length of the file. Skipping this container.`);const f=Buffer.allocUnsafe(n.maxLength(a.numLandmarks));yield this.file.read(f,0,n.maxLength(a.numLandmarks),e+a._size-A);const h=(0,s.parseItem)(f,n.parser);return this.file.validateChecksums&&void 0!==h.crc32&&(yield this.file.checkCrc32(e,a._size+h._size-A-4,h.crc32,`container header beginning at position ${e}`)),Object.assign(a,h,{_size:a._size+h._size-A,_endPosition:a._size+h._size-A+e})}))}}t.default=f,"getHeader getCompressionHeaderBlock getCompressionScheme".split(" ").forEach((e=>(0,s.tinyMemoize)(f,e)))},6794:function(e,t,r){"use strict";var n=this&&this.__awaiter||function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function s(e){try{A(n.next(e))}catch(e){o(e)}}function a(e){try{A(n.throw(e))}catch(e){o(e)}}function A(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}A((n=n.apply(e,t||[])).next())}))},i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});const o=r(8712),s=i(r(4132)),a=i(r(7392)),A=i(r(6960)),f=i(r(235)),h=r(1307),u=r(9747),l=i(r(9989)),c=r(3165),d=i(r(78)),g=r(5931),p=r(400),C=r(5417);class I{constructor(e){var t;if(this.file=(0,g.open)(e.url,e.path,e.filehandle),this.validateChecksums=!0,this.fetchReferenceSequenceCallback=e.seqFetch,this.options={checkSequenceMD5:e.checkSequenceMD5,cacheSize:null!==(t=e.cacheSize)&&void 0!==t?t:2e4},this.featureCache=new a.default({maxSize:this.options.cacheSize}),function(){const e=new Uint32Array([287454020]),t=new Uint8Array(e.buffer);return 68===t[0]?0:17===t[0]?1:2}()>0)throw new Error("Detected big-endian machine, may be unable to run")}read(e,t,r,n){return this.file.read(e,t,r,n)}stat(){return this.file.stat()}getDefinition(){return n(this,void 0,void 0,(function*(){const e=Buffer.allocUnsafe(c.cramFileDefinition.maxLength);yield this.file.read(e,0,c.cramFileDefinition.maxLength,0);const t=c.cramFileDefinition.parser.parse(e).result;if(2!==t.majorVersion&&3!==t.majorVersion)throw new u.CramUnimplementedError(`CRAM version ${t.majorVersion} not supported`);return t}))}getSamHeader(){return n(this,void 0,void 0,(function*(){const e=yield this.getContainerById(0);if(!e)throw new u.CramMalformedError("file contains no containers");const t=yield e.getFirstBlock();if(void 0===t)return(0,C.parseHeaderText)("");const r=t.content,n=r.readInt32LE(0),i=r.toString("utf8",4,4+n);return this.header=i,(0,C.parseHeaderText)(i)}))}getHeaderText(){return n(this,void 0,void 0,(function*(){return yield this.getSamHeader(),this.header}))}getSectionParsers(){return n(this,void 0,void 0,(function*(){const{majorVersion:e}=yield this.getDefinition();return(0,c.getSectionParsers)(e)}))}getContainerById(e){return n(this,void 0,void 0,(function*(){const t=yield this.getSectionParsers();let r=t.cramFileDefinition.maxLength;const{size:n}=yield this.file.stat(),{cramContainerHeader1:i}=t;let o;for(let t=0;t<=e;t+=1){if(r+i.maxLength+8>=n)return;o=this.getContainerAtPosition(r);const s=yield o.getHeader();if(!s)throw new u.CramMalformedError(`container ${e} not found in file`);if(0===t){r=s._endPosition;for(let e=0;e<s.numBlocks;e+=1){const e=yield this.readBlock(r);if(void 0===e)return;r=e._endPosition}}else r+=s._size+s.length}return o}))}checkCrc32(e,t,r,i){return n(this,void 0,void 0,(function*(){const n=Buffer.allocUnsafe(t);yield this.file.read(n,0,t,e);const o=s.default.unsigned(n);if(o!==r)throw new u.CramMalformedError(`crc mismatch in ${i}: recorded CRC32 = ${r}, but calculated CRC32 = ${o}`)}))}containerCount(){return n(this,void 0,void 0,(function*(){const e=yield this.getSectionParsers(),{size:t}=yield this.file.stat(),{cramContainerHeader1:r}=e;let n=0,i=e.cramFileDefinition.maxLength;for(;i+r.maxLength+8<t;){const e=yield this.getContainerAtPosition(i).getHeader();if(!e)break;if(0===n){i=e._endPosition;for(let t=0;t<e.numBlocks;t+=1){const e=yield this.readBlock(i);if(void 0===e)return;i=e._endPosition}}else i+=e._size+e.length;n+=1}return n}))}getContainerAtPosition(e){return new d.default(this,e)}readBlockHeader(e){return n(this,void 0,void 0,(function*(){const t=yield this.getSectionParsers(),{cramBlockHeader:r}=t,{size:n}=yield this.file.stat();if(e+r.maxLength>=n)return;const i=Buffer.allocUnsafe(r.maxLength);return yield this.file.read(i,0,r.maxLength,e),(0,p.parseItem)(i,r.parser,0,e)}))}_parseSection(e,t){return n(this,arguments,void 0,(function*(e,t,r=e.maxLength,n=void 0){let i;if(n)i=n;else{const{size:e}=yield this.file.stat();if(t+r>=e)return;i=Buffer.allocUnsafe(r),yield this.file.read(i,0,r,t)}const o=(0,p.parseItem)(i,e.parser,0,t);if(o._size!==r)throw new u.CramMalformedError(`section read error: requested size ${r} does not equal parsed size ${o._size}`);return o}))}_uncompress(e,t,r){return n(this,void 0,void 0,(function*(){if("gzip"===e)(0,o.unzip)(t).copy(r);else if("bzip2"===e){const e=f.default.array(t);let n,i=f.default.header(e),o=0;do{n=f.default.decompress(e,i),-1!=n&&(Buffer.from(n).copy(r,o),o+=n.length,i-=n.length)}while(-1!=n)}else if("lzma"===e){const e=new Response(new h.XzReadableStream((n=t,new ReadableStream({start(e){e.enqueue(n),e.close()}}))));Buffer.from(yield e.arrayBuffer()).copy(r)}else if("rans"===e)(0,l.default)(t,r);else if("rans4x16"===e)A.default.r4x16_uncompress(t,r);else if("arith"===e)A.default.arith_uncompress(t,r);else if("fqzcomp"===e)A.default.fqzcomp_uncompress(t,r);else{if("tok3"!==e)throw new u.CramUnimplementedError(`${e} decompression not yet implemented`);A.default.tok3_uncompress(t,r)}var n}))}readBlock(e){return n(this,void 0,void 0,(function*(){const{majorVersion:t}=yield this.getDefinition(),r=yield this.getSectionParsers(),n=yield this.readBlockHeader(e);if(void 0===n)return;const i=n._endPosition,o=Buffer.allocUnsafe(n.uncompressedSize),s=Object.assign(Object.assign({},n),{_endPosition:i,contentPosition:i,content:o});if("raw"!==n.compressionMethod){const e=Buffer.allocUnsafe(n.compressedSize);yield this.read(e,0,n.compressedSize,i),yield this._uncompress(n.compressionMethod,e,o)}else yield this.read(o,0,n.uncompressedSize,i);if(t>=3){const t=yield this._parseSection(r.cramBlockCrc32,i+n.compressedSize);if(void 0===t)return;s.crc32=t.crc32,this.validateChecksums&&(yield this.checkCrc32(e,n._size+n.compressedSize,t.crc32,"block data")),s._endPosition=t._endPosition,s._size=s.compressedSize+r.cramBlockCrc32.maxLength}else s._endPosition=i+s.compressedSize,s._size=s.compressedSize;return s}))}}t.default=I,"getDefinition getSectionParsers getSamHeader".split(" ").forEach((e=>(0,p.tinyMemoize)(I,e)))},7390:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.default=t.CramRecord=void 0;var i=r(8401);Object.defineProperty(t,"CramRecord",{enumerable:!0,get:function(){return n(i).default}});var o=r(6794);Object.defineProperty(t,"default",{enumerable:!0,get:function(){return n(o).default}})},8401:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.MateFlagsDecoder=t.CramFlagsDecoder=t.BamFlagsDecoder=t.MateFlags=t.CramFlags=t.BamFlags=void 0;const i=n(r(7295)),o={a:0,A:0,c:1,C:1,g:2,G:2,t:3,T:3,n:4,N:4};function s(e){const t={};for(const[r,n]of e)t["is"+n]=e=>!!(e&r),t["set"+n]=e=>e|r;return t}t.BamFlags=[[1,"Paired"],[2,"ProperlyPaired"],[4,"SegmentUnmapped"],[8,"MateUnmapped"],[16,"ReverseComplemented"],[32,"MateReverseComplemented"],[64,"Read1"],[128,"Read2"],[256,"Secondary"],[512,"FailedQc"],[1024,"Duplicate"],[2048,"Supplementary"]],t.CramFlags=[[1,"PreservingQualityScores"],[2,"Detached"],[4,"WithMateDownstream"],[8,"DecodeSequenceAsStar"]],t.MateFlags=[[1,"OnNegativeStrand"],[2,"Unmapped"]],t.BamFlagsDecoder=s(t.BamFlags),t.CramFlagsDecoder=s(t.CramFlags),t.MateFlagsDecoder=s(t.MateFlags),t.default=class{constructor({flags:e,cramFlags:t,readLength:r,mappingQuality:n,lengthOnRef:i,qualityScores:o,mateRecordNumber:s,readBases:a,readFeatures:A,mateToUse:f,readGroupId:h,readName:u,sequenceId:l,uniqueId:c,templateSize:d,alignmentStart:g,tags:p}){this.flags=e,this.cramFlags=t,this.readLength=r,this.mappingQuality=n,this.lengthOnRef=i,this.qualityScores=o,a&&(this.readBases=a),this.readGroupId=h,this.readName=u,this.sequenceId=l,this.uniqueId=c,this.templateSize=d,this.alignmentStart=g,this.tags=p,A&&(this.readFeatures=A),f&&(this.mate={flags:f.mateFlags,readName:f.mateReadName,sequenceId:f.mateSequenceId,alignmentStart:f.mateAlignmentStart}),s&&(this.mateRecordNumber=s)}isPaired(){return!!(this.flags&i.default.BAM_FPAIRED)}isProperlyPaired(){return!!(this.flags&i.default.BAM_FPROPER_PAIR)}isSegmentUnmapped(){return!!(this.flags&i.default.BAM_FUNMAP)}isMateUnmapped(){return!!(this.flags&i.default.BAM_FMUNMAP)}isReverseComplemented(){return!!(this.flags&i.default.BAM_FREVERSE)}isMateReverseComplemented(){return!!(this.flags&i.default.BAM_FMREVERSE)}isRead1(){return!!(this.flags&i.default.BAM_FREAD1)}isRead2(){return!!(this.flags&i.default.BAM_FREAD2)}isSecondary(){return!!(this.flags&i.default.BAM_FSECONDARY)}isFailedQc(){return!!(this.flags&i.default.BAM_FQCFAIL)}isDuplicate(){return!!(this.flags&i.default.BAM_FDUP)}isSupplementary(){return!!(this.flags&i.default.BAM_FSUPPLEMENTARY)}isDetached(){return!!(this.cramFlags&i.default.CRAM_FLAG_DETACHED)}hasMateDownStream(){return!!(this.cramFlags&i.default.CRAM_FLAG_MATE_DOWNSTREAM)}isPreservingQualityScores(){return!!(this.cramFlags&i.default.CRAM_FLAG_PRESERVE_QUAL_SCORES)}isUnknownBases(){return!!(this.cramFlags&i.default.CRAM_FLAG_NO_SEQ)}getReadBases(){if(!this.readBases&&this._refRegion){const e=function(e,t){if(!e.lengthOnRef&&!e.readLength)return null;if(e.isUnknownBases())return null;const r=e.alignmentStart-t.start;if(!e.readFeatures)return t.seq.slice(r,r+(e.lengthOnRef||0)).toUpperCase();let n="",i=r,o=0;for(;n.length<e.readLength;)if(o<e.readFeatures.length){const r=e.readFeatures[o];if("Q"===r.code||"q"===r.code)o+=1;else if(r.pos===n.length+1)if(o+=1,"b"===r.code){const e=r.data;n+=e,i+=e.length}else"B"===r.code?(n+=r.data[0],i+=1):"X"===r.code?(n+=r.sub,i+=1):"I"===r.code?n+=r.data:"D"===r.code?i+=r.data:"i"===r.code?n+=r.data:"N"===r.code?i+=r.data:"S"===r.code?n+=r.data:"P"===r.code||r.code;else if(o<e.readFeatures.length){const r=t.seq.slice(i,i+e.readFeatures[o].pos-n.length-1);n+=r,i+=r.length}}else{const r=t.seq.slice(i,i+e.readLength-n.length);n+=r,i+=r.length}return n.toUpperCase()}(this,this._refRegion);e&&(this.readBases=e)}return this.readBases}getPairOrientation(){if(!this.isSegmentUnmapped()&&this.isPaired()&&!this.isMateUnmapped()&&this.mate&&this.sequenceId===this.mate.sequenceId){const e=this.isReverseComplemented()?"R":"F",t=this.isMateReverseComplemented()?"R":"F";let r=" ",n=" ";this.isRead1()?(r="1",n="2"):this.isRead2()&&(r="2",n="1");const i=[];let o=this.templateLength||this.templateSize;if(void 0===o)throw new Error("One of templateSize and templateLength must be set");return this.alignmentStart>this.mate.alignmentStart&&o>0&&(o=-o),o>0?(i[0]=e,i[1]=r,i[2]=t,i[3]=n):(i[2]=e,i[3]=r,i[0]=t,i[1]=n),i.join("")}return null}addReferenceSequence(e,t){this.readFeatures&&this.readFeatures.forEach((r=>{"X"===r.code&&function(e,t,r,n){if(!t)return;const i=n.refPos-t.start,s=t.seq.charAt(i);s&&(n.ref=s);let a=o[s];void 0===a&&(a=4);const A=r.substitutionMatrix[a][n.data];A&&(n.sub=A)}(0,e,t,r)})),!this.readBases&&e.start<=this.alignmentStart&&e.end>=this.alignmentStart+(this.lengthOnRef||this.readLength)-1&&(this._refRegion=e)}toJSON(){const e={};return Object.keys(this).forEach((t=>{t.startsWith("_")||(e[t]=this[t])})),e.readBases=this.getReadBases(),e}}},3165:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.cramFileDefinition=void 0,t.isMappedSliceHeader=function(e){return"number"==typeof e.refSeqId},t.getSectionParsers=function(e){const t=Object.assign({},l);return Object.keys(c).forEach((r=>{t[r]=c[r](e)})),t};const n=r(7936),i=(new n.Parser).itf8(),o={parser:(new n.Parser).string("magic",{length:4}).uint8("majorVersion").uint8("minorVersion").string("fileId",{length:20,stripNull:!0}),maxLength:26};t.cramFileDefinition=o;const s={parser:(new n.Parser).uint8("compressionMethod",{formatter:e=>{const t=["raw","gzip","bzip2","lzma","rans","rans4x16","arith","fqzcomp","tok3"][e];if(!t)throw new Error(`compression method number ${e} not implemented`);return t}}).uint8("contentType",{formatter:e=>{const t=["FILE_HEADER","COMPRESSION_HEADER","MAPPED_SLICE_HEADER","UNMAPPED_SLICE_HEADER","EXTERNAL_DATA","CORE_DATA"][e];if(!t)throw new Error(`invalid block content type id ${e}`);return t}}).itf8("contentId").itf8("compressedSize").itf8("uncompressedSize"),maxLength:17},a={parser:(new n.Parser).uint32("crc32"),maxLength:4},A=(new n.Parser).itf8("size").buffer("ents",{length:"size",formatter:e=>{function t(t,r){const n=e.toString("utf8",t,r),i=[];for(let e=0;e<n.length;e+=3)i.push(n.slice(e,e+3));return i}var r,n=[],i=0;for(r=0;r<e.length;r+=1)e[r]||(n.push(t(i,r)),i=r+1);return r>i&&n.push(t(i,r)),n}}),f=(new n.Parser).uint8(null,{formatter:e=>!!e}),h=(new n.Parser).itf8("mapSize").itf8("mapCount").array("ents",{length:"mapCount",type:(new n.Parser).string("key",{length:2,stripNull:!1}).choice("value",{tag:"key",choices:{MI:f,UI:f,PI:f,RN:f,AP:f,RR:f,SM:(new n.Parser).array(null,{type:"uint8",length:5}),TD:(new n.Parser).nest(null,{type:A,formatter:e=>e.ents})}})});function u(e){const t={};for(const{key:r,value:n}of e.ents)t[r]&&console.warn(`duplicate key ${r} in map`),t[r]=n;return t}const l={cramFileDefinition:o,cramBlockHeader:s,cramBlockCrc32:a},c={cramUnmappedSliceHeader(e){let t=0,r=(new n.Parser).itf8("numRecords");return t+=5,e>=3?(r=r.ltf8("recordCounter"),t+=9):2===e&&(r=r.itf8("recordCounter"),t+=5),r=r.itf8("numBlocks").itf8("numContentIds").array("contentIds",{type:i,length:"numContentIds"}),t+=10,e>=2&&(r=r.array("md5",{type:"uint8",length:16}),t+=16),{parser:r,maxLength:e=>t+5*e}},cramMappedSliceHeader(e){let t=(new n.Parser).itf8("refSeqId").itf8("refSeqStart").itf8("refSeqSpan").itf8("numRecords"),r=20;return e>=3?(t=t.ltf8("recordCounter"),r+=9):2===e&&(t=t.itf8("recordCounter"),r+=5),t=t.itf8("numBlocks").itf8("numContentIds").array("contentIds",{type:i,length:"numContentIds"}).itf8("refBaseBlockId"),r+=15,e>=2&&(t=t.array("md5",{type:"uint8",length:16}),r+=16),{parser:t,maxLength:e=>r+5*e}},cramEncoding:e=>({parser:(new n.Parser).namely("cramEncoding").itf8("codecId").itf8("parametersBytes").choice("parameters",{tag:"codecId",choices:{0:new n.Parser,1:(new n.Parser).itf8("blockContentId"),2:(new n.Parser).itf8("offset").itf8("M"),3:n.Parser.start().itf8("numCodes").array("symbols",{length:"numCodes",type:i}).itf8("numLengths").array("bitLengths",{length:"numLengths",type:i}),4:n.Parser.start().nest("lengthsEncoding",{type:"cramEncoding"}).nest("valuesEncoding",{type:"cramEncoding"}),5:(new n.Parser).uint8("stopByte").itf8("blockContentId"),6:(new n.Parser).itf8("offset").itf8("length"),7:(new n.Parser).itf8("offset").itf8("K"),8:(new n.Parser).itf8("offset").itf8("log2m"),9:(new n.Parser).itf8("offset")}})}),cramDataSeriesEncodingMap(e){return(new n.Parser).itf8("mapSize").itf8("mapCount").array("ents",{length:"mapCount",type:(new n.Parser).string("key",{length:2,stripNull:!1}).nest("value",{type:this.cramEncoding(e).parser})})},cramTagEncodingMap(e){return(new n.Parser).itf8("mapSize").itf8("mapCount").array("ents",{length:"mapCount",type:(new n.Parser).itf8("key",{formatter:e=>String.fromCharCode(e>>16&255)+String.fromCharCode(e>>8&255)+String.fromCharCode(255&e)}).nest("value",{type:this.cramEncoding(e).parser})})},cramCompressionHeader(e){let t=new n.Parser;return t=t.nest("preservation",{type:h,formatter:u}).nest("dataSeriesEncoding",{type:this.cramDataSeriesEncodingMap(e),formatter:u}).nest("tagEncoding",{type:this.cramTagEncodingMap(e),formatter:u}),{parser:t}},cramContainerHeader1(e){let t=(new n.Parser).int32("length").itf8("refSeqId").itf8("refSeqStart").itf8("alignmentSpan").itf8("numRecords"),r=24;return e>=3?(t=t.ltf8("recordCounter"),r+=9):2===e&&(t=t.itf8("recordCounter"),r+=5),e>1&&(t=t.ltf8("numBases"),r+=9),t=t.itf8("numBlocks").itf8("numLandmarks"),r+=10,{parser:t,maxLength:r}},cramContainerHeader2(e){let t=(new n.Parser).itf8("numLandmarks").array("landmarks",{type:(new n.Parser).itf8(),length:"numLandmarks"}),r=0;return e>=3&&(t=t.uint32("crc32"),r=4),{parser:t,maxLength:e=>5+5*e+r}}}},6484:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,r,n,i,h,u,l,c){let d=t("BF");const g=t("CF");if(!(0,a.isMappedSliceHeader)(n.parsedContent))throw new Error("slice header not mapped");const p=l>1&&-2===n.parsedContent.refSeqId?t("RI"):n.parsedContent.refSeqId,C=t("RL");let I=t("AP");r.APdelta&&(I+=u.lastAlignmentStart),u.lastAlignmentStart=I;const m=t("RG");let y,w,B,E;if(r.readNamesIncluded&&(y=A(t("RN"))),s.CramFlagsDecoder.isDetached(g)){const e=t("MF");let n;r.readNamesIncluded||(n=A(t("RN")),y=n);const i=t("NS"),o=t("NP");(e||i>-1)&&(w={mateFlags:e,mateSequenceId:i,mateAlignmentStart:o,mateReadName:n}),B=t("TS"),s.MateFlagsDecoder.isUnmapped(e)&&(d=s.BamFlagsDecoder.setMateUnmapped(d)),s.MateFlagsDecoder.isOnNegativeStrand(e)&&(d=s.BamFlagsDecoder.setMateReverseComplemented(d))}else s.CramFlagsDecoder.isWithMateDownstream(g)&&(E=t("NF")+c+1);const b=t("TL");if(b<0)throw new o.CramMalformedError("invalid TL index");const _={},v=r.getTagNames(b),Q=v.length;for(let t=0;t<Q;t+=1){const n=v[t],s=n.slice(0,2),a=n.slice(2,3),A=r.getCodecForTag(n);if(!A)throw new o.CramMalformedError(`no codec defined for auxiliary tag ${n}`);const l=A.decode(e,i,h,u);_[s]=f(a,l)}let S,k,D,R,N;if(s.BamFlagsDecoder.isSegmentUnmapped(d))if(s.CramFlagsDecoder.isDecodeSequenceAsStar(g))N=null,R=null;else{const e=new Array(C);for(let r=0;r<e.length;r+=1)e[r]=t("BA");if(N=String.fromCharCode(...e),s.CramFlagsDecoder.isPreservingQualityScores(g)){R=new Array(C);for(let r=0;r<e.length;r+=1)R[r]=t("QS")}}else{const e=t("FN");if(e&&(S=function(e,t,r,n,i){let s=0,a=e-1;const A=new Array(t);function f([e,t]){const n=r(t);if("character"===e)return String.fromCharCode(n);if("string"===e){let e="";for(let t=0;t<n.byteLength;t++)e+=String.fromCharCode(n[t]);return e}return"numArray"===e?n.toArray():n}for(let e=0;e<t;e+=1){const t=String.fromCharCode(r("FC")),n=r("FP"),h={B:["character","BA"],S:["string",i>1?"SC":"IN"],X:["number","BS"],D:["number","DL"],I:["string","IN"],i:["character","BA"],b:["string","BB"],q:["numArray","QQ"],Q:["number","QS"],H:["number","HC"],P:["number","PD"],N:["number","RS"]}[t];if(!h)throw new o.CramMalformedError(`invalid read feature code "${t}"`);let u=f(h);const l={B:["number","QS"]}[t];l&&(u=[u,f(l)]),s+=n;const c=s;a+=n;const d=a;"D"===t||"N"===t?a+=u:"I"===t||"S"===t?a-=u.length:"i"===t&&(a-=1),A[e]={code:t,pos:c,refPos:d,data:u}}return A}(I,e,t,0,l)),k=C,S)for(const{code:e,data:t}of S)"D"===e||"N"===e?k+=t:"I"===e||"S"===e?k-=t.length:"i"===e&&(k-=1);if(Number.isNaN(k)&&(console.warn(`${y||`${p}:${I}`} record has invalid read features`),k=C),D=t("MQ"),s.CramFlagsDecoder.isPreservingQualityScores(g)){R=new Array(C);for(let e=0;e<R.length;e++)R[e]=t("QS")}}return{readLength:C,sequenceId:p,cramFlags:g,flags:d,alignmentStart:I,readGroupId:m,readName:y,mateToUse:w,templateSize:B,mateRecordNumber:E,readFeatures:S,lengthOnRef:k,mappingQuality:D,qualityScores:R,readBases:N,tags:_}};const i=n(r(8570)),o=r(9747),s=r(8401),a=r(3165);function A(e){let t="";for(let r=0;r<e.length&&0!==e[r];r++)t+=String.fromCharCode(e[r]);return t}function f(e,t){if("Z"===e)return A(t);if("A"===e)return String.fromCharCode(t[0]);if("I"===e)return i.default.fromBytesLE(t).toNumber();if("i"===e)return new Int32Array(t.buffer)[0];if("s"===e)return new Int16Array(t.buffer)[0];if("S"===e)return new Uint16Array(t.buffer)[0];if("c"===e)return new Int8Array(t.buffer)[0];if("C"===e)return t[0];if("f"===e)return new Float32Array(t.buffer)[0];if("H"===e)return Number.parseInt(A(t).replace(/^0x/,""),16);if("B"===e)return function(e){const t=String.fromCharCode(e[0]),r=Int32Array.from(e.slice(1))[0],n=new Array(r);if(e=e.slice(5),"c"===t){const t=new Int8Array(e.buffer);for(let e=0;e<r;e+=1)n[e]=t[e]}else if("C"===t){const t=new Uint8Array(e.buffer);for(let e=0;e<r;e+=1)n[e]=t[e]}else if("s"===t){const t=new Int16Array(e.buffer);for(let e=0;e<r;e+=1)n[e]=t[e]}else if("S"===t){const t=new Uint16Array(e.buffer);for(let e=0;e<r;e+=1)n[e]=t[e]}else if("i"===t){const t=new Int32Array(e.buffer);for(let e=0;e<r;e+=1)n[e]=t[e]}else if("I"===t){const t=new Uint32Array(e.buffer);for(let e=0;e<r;e+=1)n[e]=t[e]}else{if("f"!==t)throw new Error("unknown type: "+t);{const t=new Float32Array(e.buffer);for(let e=0;e<r;e+=1)n[e]=t[e]}}return n}(t);throw new o.CramMalformedError(`Unrecognized tag type ${e}`)}},6771:function(e,t,r){"use strict";var n=this&&this.__awaiter||function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function s(e){try{A(n.next(e))}catch(e){o(e)}}function a(e){try{A(n.throw(e))}catch(e){o(e)}}function A(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}A((n=n.apply(e,t||[])).next())}))},i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});const o=r(9747),s=r(400),a=i(r(7295)),A=i(r(6484)),f=i(r(8401)),h=r(3165),u=r(612);function l(e,t,r,n){if(!n)throw new o.CramMalformedError("could not resolve intra-slice mate pairs, file seems truncated or malformed");const i=!!(n.mate||void 0!==n.mateRecordNumber&&n.mateRecordNumber!==t);r.readName||(r.readName=String(r.uniqueId),n.readName=r.readName),r.mate={sequenceId:n.sequenceId,alignmentStart:n.alignmentStart,uniqueId:n.uniqueId},n.readName&&(r.mate.readName=n.readName),n.mate||void 0!==n.mateRecordNumber||(n.mate={sequenceId:r.sequenceId,alignmentStart:r.alignmentStart,uniqueId:r.uniqueId},r.readName&&(n.mate.readName=r.readName)),r.flags|=a.default.BAM_FPAIRED,n.flags&a.default.BAM_FUNMAP&&(r.flags|=a.default.BAM_FMUNMAP),r.flags&a.default.BAM_FUNMAP&&(n.flags|=a.default.BAM_FMUNMAP),n.flags&a.default.BAM_FREVERSE&&(r.flags|=a.default.BAM_FMREVERSE),r.flags&a.default.BAM_FREVERSE&&(n.flags|=a.default.BAM_FMREVERSE),void 0===r.templateLength&&(i?function(e,t,r){const n=function t(r){const n=[r];if(void 0!==r.mateRecordNumber&&r.mateRecordNumber>=0){const i=e[r.mateRecordNumber];if(!i)throw new o.CramMalformedError("intra-slice mate record not found, this file seems malformed");n.push(...t(i))}return n}(r),i=n.map((e=>e.alignmentStart)),s=n.map((e=>e.alignmentStart+e.readLength-1)),a=Math.max(...s)-Math.min(...i)+1;a>=0&&n.forEach((e=>{if(void 0!==e.templateLength)throw new o.CramMalformedError("mate pair group has some members that have template lengths already, this file seems malformed");e.templateLength=a}))}(e,0,r):function(e,t){const r=Math.min(e.alignmentStart,t.alignmentStart),n=Math.max(e.alignmentStart+e.readLength-1,t.alignmentStart+t.readLength-1)-r+1;e.templateLength=n,t.templateLength=n}(r,n)),delete r.mateRecordNumber}class c{constructor(e,t,r){this.container=e,this.containerPosition=t,this.file=e.file}getHeader(){return n(this,void 0,void 0,(function*(){const e=yield this.file.getSectionParsers(),t=yield this.container.getHeader(),r=yield this.file.readBlock(t._endPosition+this.containerPosition);if(void 0===r)throw new Error("block header undefined");if("MAPPED_SLICE_HEADER"===r.contentType){const n=(0,s.parseItem)(r.content,e.cramMappedSliceHeader.parser,0,t._endPosition);return Object.assign(Object.assign({},r),{parsedContent:n})}if("UNMAPPED_SLICE_HEADER"===r.contentType){const n=(0,s.parseItem)(r.content,e.cramUnmappedSliceHeader.parser,0,t._endPosition);return Object.assign(Object.assign({},r),{parsedContent:n})}throw new o.CramMalformedError(`error reading slice header block, invalid content type ${r.contentType}`)}))}getBlocks(){return n(this,void 0,void 0,(function*(){const e=yield this.getHeader();let t=e._endPosition;const r=new Array(e.parsedContent.numBlocks);for(let e=0;e<r.length;e+=1){const n=yield this.file.readBlock(t);if(void 0===n)throw new Error("block undefined");r[e]=n,t=r[e]._endPosition}return r}))}getCoreDataBlock(){return n(this,void 0,void 0,(function*(){return(yield this.getBlocks())[0]}))}_getBlocksContentIdIndex(){return n(this,void 0,void 0,(function*(){const e=yield this.getBlocks(),t={};return e.forEach((e=>{"EXTERNAL_DATA"===e.contentType&&(t[e.contentId]=e)})),t}))}getBlockByContentId(e){return n(this,void 0,void 0,(function*(){return(yield this._getBlocksContentIdIndex())[e]}))}getReferenceRegion(){return n(this,void 0,void 0,(function*(){const e=(yield this.getHeader()).parsedContent;if(!(0,h.isMappedSliceHeader)(e))throw new Error("slice header not mapped");if(e.refSeqId<0)return;const t=yield this.container.getCompressionScheme();if(void 0===t)throw new Error("compression scheme undefined");if(e.refBaseBlockId>=0){const t=yield this.getBlockByContentId(e.refBaseBlockId);if(!t)throw new o.CramMalformedError("embedded reference specified, but reference block does not exist");return{seq:t.data.toString("utf8"),start:e.refSeqStart,end:e.refSeqStart+e.refSeqSpan-1,span:e.refSeqSpan}}if(t.referenceRequired||this.file.fetchReferenceSequenceCallback){if(!this.file.fetchReferenceSequenceCallback)throw new Error("reference sequence not embedded, and seqFetch callback not provided, cannot fetch reference sequence");const t=yield this.file.fetchReferenceSequenceCallback(e.refSeqId,e.refSeqStart,e.refSeqStart+e.refSeqSpan-1);if(t.length!==e.refSeqSpan)throw new o.CramArgumentError("seqFetch callback returned a reference sequence of the wrong length");return{seq:t,start:e.refSeqStart,end:e.refSeqStart+e.refSeqSpan-1,span:e.refSeqSpan}}}))}getAllRecords(){return this.getRecords((()=>!0))}_fetchRecords(){return n(this,void 0,void 0,(function*(){const{majorVersion:e}=yield this.file.getDefinition(),t=yield this.container.getCompressionScheme();if(void 0===t)throw new Error("compression scheme undefined");const r=yield this.getHeader();if(void 0===r)throw new Error("slice header undefined");const n=yield this._getBlocksContentIdIndex();if(e>1&&this.file.options.checkSequenceMD5&&(0,h.isMappedSliceHeader)(r.parsedContent)&&r.parsedContent.refSeqId>=0&&"0000000000000000"!==r.parsedContent.md5.join("")){const e=yield this.getReferenceRegion();if(e){const{seq:t,start:n,end:i}=e,a=(0,s.sequenceMD5)(t),A=r.parsedContent.md5.map((e=>(e<16?"0":"")+e.toString(16))).join("");if(a!==A)throw new o.CramMalformedError(`MD5 checksum reference mismatch for ref ${r.parsedContent.refSeqId} pos ${n}..${i}. recorded MD5: ${A}, calculated MD5: ${a}`)}}const i=yield this.getCoreDataBlock(),a={lastAlignmentStart:(0,h.isMappedSliceHeader)(r.parsedContent)?r.parsedContent.refSeqStart:0,coreBlock:{bitPosition:7,bytePosition:0},externalBlocks:{map:new Map,getCursor(e){let t=this.map.get(e);return void 0===t&&(t={bitPosition:7,bytePosition:0},this.map.set(e,t)),t}}},c=e=>{const r=t.getCodecForDataSeries(e);if(!r)throw new o.CramMalformedError(`no codec defined for ${e} data series`);return r.decode(this,i,n,a)};let d=new Array(r.parsedContent.numRecords);for(let o=0;o<d.length;o+=1)try{const s=(0,A.default)(this,c,t,r,i,n,a,e,o);d[o]=new f.default(Object.assign(Object.assign({},s),{uniqueId:r.contentPosition+r.parsedContent.recordCounter+o+1}))}catch(e){if(e instanceof u.CramBufferOverrunError){console.warn("read attempted beyond end of buffer, file seems truncated."),d=d.filter((e=>!!e));break}throw e}for(let e=0;e<d.length;e+=1){const{mateRecordNumber:t}=d[e];void 0!==t&&t>=0&&l(d,e,d[e],d[t])}return d}))}getRecords(e){return n(this,void 0,void 0,(function*(){const t=this.container.filePosition+this.containerPosition;let r=this.file.featureCache.get(t.toString());r||(r=this._fetchRecords(),this.file.featureCache.set(t.toString(),r));const i=(yield r).filter(e);if(i.length&&this.file.fetchReferenceSequenceCallback){const e=yield this.getHeader();if((0,h.isMappedSliceHeader)(e.parsedContent)&&(e.parsedContent.refSeqId>=0||-2===e.parsedContent.refSeqId)){const t=e.parsedContent.refSeqId>=0?e.parsedContent.refSeqId:void 0,r=yield this.container.getCompressionScheme();if(void 0===r)throw new Error("compression scheme undefined");const o={};for(const e of i){const r=void 0!==t?t:e.sequenceId;let n=o[r];n||(n={id:r,start:e.alignmentStart,end:-1/0,seq:null},o[r]=n);const i=e.alignmentStart+(e.lengthOnRef||e.readLength)-1;i>n.end&&(n.end=i),e.alignmentStart<n.start&&(n.start=e.alignmentStart)}yield Promise.all(Object.values(o).map((e=>n(this,void 0,void 0,(function*(){-1!==e.id&&e.start<=e.end&&this.file.fetchReferenceSequenceCallback&&(e.seq=yield this.file.fetchReferenceSequenceCallback(e.id,e.start,e.end))})))));for(const e of i){const n=o[void 0!==t?t:e.sequenceId];if(null==n?void 0:n.seq){const t=n.seq;e.addReferenceSequence(Object.assign(Object.assign({},n),{seq:t}),r)}}}}return i}))}}t.default=c,"getHeader getBlocks _getBlocksContentIdIndex".split(" ").forEach((e=>(0,s.tinyMemoize)(c,e)))},400:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.itf8Size=function(e){return-128&e?-16384&e?-2097152&e?-268435456&e?5:4:3:2:1},t.parseItf8=function(e,t){let r=t;const n=e[r];let i;if(n<128?(i=n,r+=1):n<192?(i=16383&(n<<8|e[r+1]),r+=2):n<224?(i=2097151&(n<<16|e[r+1]<<8|e[r+2]),r+=3):n<240?(i=268435455&(n<<24|e[r+1]<<16|e[r+2]<<8|e[r+3]),r+=4):(i=(15&n)<<28|e[r+1]<<20|e[r+2]<<12|e[r+3]<<4|15&e[r+4],r+=5),r>e.length)throw new o.CramBufferOverrunError("Attempted to read beyond end of buffer; this file seems truncated.");return[i,r-t]},t.parseItem=function(e,t,r=0,n=0){const{offset:i,result:o}=t.parse(e);return Object.assign(Object.assign({},o),{_endPosition:i+n,_size:i-r})},t.tinyMemoize=function(e,t){const r=e.prototype[t],n=`_memo_${t}`;e.prototype[t]=function(){if(!(n in this)){const e=r.call(this);this[n]=e,Promise.resolve(e).catch((()=>{delete this[n]}))}return this[n]}},t.sequenceMD5=function(e){return(0,i.default)(e.toUpperCase().replaceAll(/[^\u0021-\u007e]/g,""))};const i=n(r(3503)),o=r(612)},9747:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.CramArgumentError=t.CramSizeLimitError=t.CramMalformedError=t.CramUnimplementedError=t.CramError=void 0;class r extends Error{}t.CramError=r;class n extends Error{}t.CramUnimplementedError=n,t.CramMalformedError=class extends r{},t.CramSizeLimitError=class extends r{},t.CramArgumentError=class extends r{}},7806:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.IndexedCramFile=t.CraiIndex=t.CramRecord=t.CramFile=void 0;var i=r(7390);Object.defineProperty(t,"CramFile",{enumerable:!0,get:function(){return n(i).default}}),Object.defineProperty(t,"CramRecord",{enumerable:!0,get:function(){return i.CramRecord}});var o=r(4923);Object.defineProperty(t,"CraiIndex",{enumerable:!0,get:function(){return n(o).default}});var s=r(6014);Object.defineProperty(t,"IndexedCramFile",{enumerable:!0,get:function(){return n(s).default}})},6014:function(e,t,r){"use strict";var n=this&&this.__awaiter||function(e,t,r,n){return new(r||(r=Promise))((function(i,o){function s(e){try{A(n.next(e))}catch(e){o(e)}}function a(e){try{A(n.throw(e))}catch(e){o(e)}}function A(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}A((n=n.apply(e,t||[])).next())}))},i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});const o=r(9747),s=i(r(7390));t.default=class{constructor(e){var t;if(this.cram=null!==(t=e.cram)&&void 0!==t?t:new s.default({url:e.cramUrl,path:e.cramPath,filehandle:e.cramFilehandle,seqFetch:e.seqFetch,checkSequenceMD5:e.checkSequenceMD5,cacheSize:e.cacheSize}),!(this.cram instanceof s.default))throw new Error("invalid arguments: no cramfile");if(this.index=e.index,!this.index.getEntriesForRange)throw new Error("invalid arguments: not an index")}getRecordsForRange(e,t,r){return n(this,arguments,void 0,(function*(e,t,r,n={}){if(n.viewAsPairs=n.viewAsPairs||!1,n.pairAcrossChr=n.pairAcrossChr||!1,n.maxInsertSize=n.maxInsertSize||2e5,"string"==typeof e)throw new o.CramUnimplementedError("string sequence names not yet supported");const i=e,s=yield this.index.getEntriesForRange(i,t,r),a=n=>n.sequenceId===e&&n.alignmentStart<=r&&void 0!==n.lengthOnRef&&n.alignmentStart+n.lengthOnRef-1>=t,A=yield Promise.all(s.map((e=>this.getRecordsInSlice(e,a))));let f=Array.prototype.concat(...A);if(n.viewAsPairs){const e={},t={};for(const r of f){const n=r.readName;if(void 0===n)throw new Error("readName undefined");const i=r.uniqueId;e[n]||(e[n]=0),e[n]+=1,t[i]=1}const r={};Object.entries(e).forEach((([e,t])=>{1===t&&(r[e]=!0)}));const o=[];for(const e of f){const t=e.readName;if(void 0===t)throw new Error("readName undefined");if(r[t]&&e.mate&&(e.mate.sequenceId===i||n.pairAcrossChr)&&Math.abs(e.alignmentStart-e.mate.alignmentStart)<n.maxInsertSize){const t=this.index.getEntriesForRange(e.mate.sequenceId,e.mate.alignmentStart,e.mate.alignmentStart+1);o.push(t)}}const s=yield Promise.all(o);let a=[];for(const e of s)a.push(...e);a=a.sort(((e,t)=>e.toString().localeCompare(t.toString()))).filter(((e,t,r)=>!t||e.toString()!==r[t-1].toString()));const A=[],h=[];for(const e of a){let n=this.cram.featureCache.get(e.toString());n||(n=this.getRecordsInSlice(e,(()=>!0)),this.cram.featureCache.set(e.toString(),n)),A.push(n);const i=n.then((e=>{const n=[];for(const i of e){if(void 0===i.readName)throw new Error("readName undefined");r[i.readName]&&!t[i.uniqueId]&&n.push(i)}return n}));h.push(i)}const u=yield Promise.all(h);if(u.length){const e=u.reduce(((e,t)=>e.concat(t)));f=f.concat(e)}}return f}))}getRecordsInSlice({containerStart:e,sliceStart:t,sliceBytes:r},n){return this.cram.getContainerAtPosition(e).getSlice(t,r).getRecords(n)}hasDataForReferenceSequence(e){return this.index.hasDataForReferenceSequence(e)}}},5931:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.RemoteFile=t.LocalFile=void 0,t.open=function(e,t,r){if(r)return r;if(e)return new n.RemoteFile(e);if(t)return new n.LocalFile(t);throw new Error("no url, path, or filehandle provided, cannot open")};const n=r(1113);var i=r(1113);Object.defineProperty(t,"LocalFile",{enumerable:!0,get:function(){return i.LocalFile}}),Object.defineProperty(t,"RemoteFile",{enumerable:!0,get:function(){return i.RemoteFile}})},6476:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.RANS_BYTE_L=t.TOTFREQ=t.TF_SHIFT=void 0,t.TF_SHIFT=12,t.TOTFREQ=4096,t.RANS_BYTE_L=1<<23},997:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,r,n){let a=e.getInt(),A=e.getInt(),f=e.getInt(),h=e.getInt();const u=n.remaining(),l=-4&u;for(let i=0;i<l;i+=4){const u=t.R[s.default.get(a,o.TF_SHIFT)],l=t.R[s.default.get(A,o.TF_SHIFT)],c=t.R[s.default.get(f,o.TF_SHIFT)],d=t.R[s.default.get(h,o.TF_SHIFT)];n.putAt(i,u),n.putAt(i+1,l),n.putAt(i+2,c),n.putAt(i+3,d),a=s.default.advanceSymbolStep(a,r[255&u],o.TF_SHIFT),A=s.default.advanceSymbolStep(A,r[255&l],o.TF_SHIFT),f=s.default.advanceSymbolStep(f,r[255&c],o.TF_SHIFT),h=s.default.advanceSymbolStep(h,r[255&d],o.TF_SHIFT),a=s.default.renormalize(a,e),A=s.default.renormalize(A,e),f=s.default.renormalize(f,e),h=s.default.renormalize(h,e)}let c;switch(n.setPosition(l),3&u){case 0:break;case 1:c=t.R[s.default.get(a,o.TF_SHIFT)],s.default.advanceSymbol(a,e,r[255&c],o.TF_SHIFT),n.put(c);break;case 2:c=t.R[s.default.get(a,o.TF_SHIFT)],s.default.advanceSymbol(a,e,r[255&c],o.TF_SHIFT),n.put(c),c=t.R[s.default.get(A,o.TF_SHIFT)],s.default.advanceSymbol(A,e,r[255&c],o.TF_SHIFT),n.put(c);break;case 3:c=t.R[s.default.get(a,o.TF_SHIFT)],s.default.advanceSymbol(a,e,r[255&c],o.TF_SHIFT),n.put(c),c=t.R[s.default.get(A,o.TF_SHIFT)],s.default.advanceSymbol(A,e,r[255&c],o.TF_SHIFT),n.put(c),c=t.R[s.default.get(f,o.TF_SHIFT)],s.default.advanceSymbol(f,e,r[255&c],o.TF_SHIFT),n.put(c);break;default:throw new i.CramMalformedError("invalid output size encountered during rANS decoding")}n.setPosition(0)};const i=r(9747),o=r(6476),s=n(r(488))},7960:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,r,n){const s=t.remaining();let a=e.getInt(),A=e.getInt(),f=e.getInt(),h=e.getInt();const u=s>>2;let l=0,c=u,d=2*u,g=3*u,p=0,C=0,I=0,m=0;for(;l<u;l+=1,c+=1,d+=1,g+=1){const s=255&r[p].R[o.default.get(a,i.TF_SHIFT)],u=255&r[C].R[o.default.get(A,i.TF_SHIFT)],y=255&r[I].R[o.default.get(f,i.TF_SHIFT)],w=255&r[m].R[o.default.get(h,i.TF_SHIFT)];t.putAt(l,s),t.putAt(c,u),t.putAt(d,y),t.putAt(g,w),a=o.default.advanceSymbolStep(a,n[p][s],i.TF_SHIFT),A=o.default.advanceSymbolStep(A,n[C][u],i.TF_SHIFT),f=o.default.advanceSymbolStep(f,n[I][y],i.TF_SHIFT),h=o.default.advanceSymbolStep(h,n[m][w],i.TF_SHIFT),a=o.default.renormalize(a,e),A=o.default.renormalize(A,e),f=o.default.renormalize(f,e),h=o.default.renormalize(h,e),p=s,C=u,I=y,m=w}for(;g<s;g+=1){const s=255&r[m].R[o.default.get(h,i.TF_SHIFT)];t.putAt(g,s),h=o.default.advanceSymbol(h,e,n[m][s],i.TF_SHIFT),m=s}};const i=r(6476),o=n(r(488))},488:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(9747),i=r(6476);class o{constructor(){this.F=void 0,this.C=void 0}}function s(e,t,r,n){return r*(e>>n)+(e&(1<<n)-1)-t}const a={FC:o,AriDecoder:class{constructor(){this.fc=new Array(256);for(let e=0;e<this.fc.length;e+=1)this.fc[e]=new o;this.R=null}},Symbol:class{constructor(){this.start=void 0,this.freq=void 0}},symbolInit:function(e,t,r){if(!(t<=65536))throw new n.CramMalformedError("assertion failed: start <= 1<<16");if(!(r<=65536-t))throw new n.CramMalformedError("assertion failed: freq <= 1<<16");e.start=t,e.freq=r},advanceStep:s,advanceSymbolStep:function(e,t,r){return s(e,t.start,t.freq,r)},get:function(e,t){return e&(1<<t)-1},advanceSymbol:function(e,t,r,n){return function(e,t,r,n,o){if((e=n*(e>>o)+(e&(1<<o)-1)-r)<i.RANS_BYTE_L)do{e=e<<8|255&t.get()}while(e<i.RANS_BYTE_L);return e}(e,t,r.start,r.freq,n)},renormalize:function(e,t){if(e<i.RANS_BYTE_L)do{e=e<<8|255&t.get()}while(e<i.RANS_BYTE_L);return e}};t.default=a},1971:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.readStatsO0=function(e,t,r){let n=0,i=0,A=255&e.get();do{null==t.fc[A]&&(t.fc[A]=new s.default.FC),t.fc[A].F=255&e.get(),t.fc[A].F>=128&&(t.fc[A].F&=-129,t.fc[A].F=(127&t.fc[A].F)<<8|255&e.get()),t.fc[A].C=i,s.default.symbolInit(r[A],t.fc[A].C,t.fc[A].F),t.R||(t.R=new Array(o.TOTFREQ)),t.R.fill(A,i,i+t.fc[A].F),i+=t.fc[A].F,0===n&&A+1===(255&e.getByteAt(e.position()))?(A=255&e.get(),n=255&e.get()):0!==n?(n-=1,A+=1):A=255&e.get()}while(0!==A);a(i<o.TOTFREQ)},t.readStatsO1=function(e,t,r){let n=0,i=255&e.get();do{let A=0,f=0,h=255&e.get();null==t[i]&&(t[i]=new s.default.AriDecoder);do{null==t[i].fc[h]&&(t[i].fc[h]=new s.default.FC),t[i].fc[h].F=255&e.get(),t[i].fc[h].F>=128&&(t[i].fc[h].F&=-129,t[i].fc[h].F=(127&t[i].fc[h].F)<<8|255&e.get()),t[i].fc[h].C=f,0===t[i].fc[h].F&&(t[i].fc[h].F=o.TOTFREQ),null==r[i][h]&&(r[i][h]=new s.default.RansDecSymbol),s.default.symbolInit(r[i][h],t[i].fc[h].C,t[i].fc[h].F),null==t[i].R&&(t[i].R=new Array(o.TOTFREQ)),t[i].R.fill(h,f,f+t[i].fc[h].F),f+=t[i].fc[h].F,a(f<=o.TOTFREQ),0===A&&h+1===(255&e.getByteAt(e.position()))?(h=255&e.get(),A=255&e.get()):0!==A?(A-=1,h+=1):h=255&e.get()}while(0!==h);0===n&&i+1===(255&e.getByteAt(e.position()))?(i=255&e.get(),n=255&e.get()):0!==n?(n-=1,i+=1):i=255&e.get()}while(0!==i)};const i=r(9747),o=r(6476),s=n(r(488));function a(e){if(!e)throw new i.CramMalformedError("assertion failed")}},9989:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,r=0){if(0===e.length)return t.fill(0),t;const n=new h(e,r),u=n.get();if(0!==u&&1!==u)throw new i.CramMalformedError(`Invalid rANS order ${u}`);if(n.getInt()!==n.remaining()-f)throw new i.CramMalformedError("Incorrect input length.");const l=n.getInt(),c=new h(t||Buffer.allocUnsafe(l));if(c.length<l)throw new i.CramMalformedError(`Output buffer too small to fit ${l} bytes.`);switch(u){case 0:return function(e,t){const r=new o.default.AriDecoder,n=new Array(256);for(let e=0;e<n.length;e+=1)n[e]=new o.default.Symbol;return(0,s.readStatsO0)(e,r,n),(0,a.default)(e,r,n,t),t}(n,c);case 1:return function(e,t){const r=new Array(256);for(let e=0;e<r.length;e+=1)r[e]=new o.default.AriDecoder;const n=new Array(256);for(let e=0;e<n.length;e+=1){n[e]=new Array(256);for(let t=0;t<n[e].length;t+=1)n[e][t]=new o.default.Symbol}return(0,s.readStatsO1)(e,r,n),(0,A.default)(e,t,r,n),t}(n,c);default:throw new i.CramMalformedError(`Invalid rANS order: ${u}`)}};const i=r(9747),o=n(r(488)),s=r(1971),a=n(r(997)),A=n(r(7960)),f=4;class h{constructor(e,t=0){this._buffer=e,this._position=t,this.length=e.length}get(){const e=this._buffer[this._position];return this._position+=1,e}getByte(){return this.get()}getByteAt(e){return this._buffer[e]}position(){return this._position}put(e){return this._buffer[this._position]=e,this._position+=1,e}putAt(e,t){return this._buffer[e]=t,t}setPosition(e){return this._position=e,e}getInt(){const e=this._buffer.readInt32LE(this._position);return this._position+=4,e}remaining(){return this._buffer.length-this._position}}},5417:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.parseHeaderText=function(e){const t=e.split(/\r?\n/),r=[];for(const e of t){const[t,...n]=e.split(/\t/);t&&r.push({tag:t.slice(1),data:n.map((e=>{const t=e.indexOf(":");return-1!==t?{tag:e.slice(0,t),value:e.slice(t+1)}:{tag:e,value:""}}))})}return r}},8712:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.unzip=function(e){return Buffer.from((0,n.inflate)(e))};const n=r(1668)},7430:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>s});class n{}class i{constructor(){this.signals=new Set,this.abortController=new AbortController}addSignal(e=new n){if(this.signal.aborted)throw new Error("cannot add a signal, already aborted!");this.signals.add(e),e.aborted?this.handleAborted(e):"function"==typeof e.addEventListener&&e.addEventListener("abort",(()=>{this.handleAborted(e)}))}handleAborted(e){this.signals.delete(e),0===this.signals.size&&this.abortController.abort()}get signal(){return this.abortController.signal}abort(){this.abortController.abort()}}class o{constructor(){this.callbacks=new Set}addCallback(e=()=>{}){this.callbacks.add(e),e(this.currentMessage)}callback(e){this.currentMessage=e;for(const t of this.callbacks)t(e)}}class s{constructor({fill:e,cache:t}){if("function"!=typeof e)throw new TypeError("must pass a fill function");if("object"!=typeof t)throw new TypeError("must pass a cache object");if("function"!=typeof t.get||"function"!=typeof t.set||"function"!=typeof t.delete)throw new TypeError("cache must implement get(key), set(key, val), and and delete(key)");this.cache=t,this.fillCallback=e}static isAbortException(e){return"AbortError"===e.name||"ERR_ABORTED"===e.code||"AbortError: aborted"===e.message||"Error: aborted"===e.message}evict(e,t){this.cache.get(e)===t&&this.cache.delete(e)}fill(e,t,r,n){const s=new i,a=new o;a.addCallback(n);const A={aborter:s,promise:this.fillCallback(t,s.signal,(e=>{a.callback(e)})),settled:!1,statusReporter:a,get aborted(){return this.aborter.signal.aborted}};A.aborter.addSignal(r),A.aborter.signal.addEventListener("abort",(()=>{A.settled||this.evict(e,A)})),A.promise.then((()=>{A.settled=!0}),(()=>{A.settled=!0,this.evict(e,A)})).catch((e=>{throw console.error(e),e})),this.cache.set(e,A)}static checkSinglePromise(e,t){function r(){if(null==t?void 0:t.aborted)throw Object.assign(new Error("aborted"),{code:"ERR_ABORTED"})}return e.then((e=>(r(),e)),(e=>{throw r(),e}))}has(e){return this.cache.has(e)}get(e,t,r,n){if(!r&&t instanceof AbortSignal)throw new TypeError("second get argument appears to be an AbortSignal, perhaps you meant to pass `null` for the fill data?");const i=this.cache.get(e);return i?i.aborted&&!i.settled?(this.evict(e,i),this.get(e,t,r,n)):i.settled?i.promise:(i.aborter.addSignal(r),i.statusReporter.addCallback(n),s.checkSinglePromise(i.promise,r)):(this.fill(e,t,r,n),s.checkSinglePromise(this.cache.get(e).promise,r))}delete(e){const t=this.cache.get(e);t&&(t.settled||t.aborter.abort(),this.cache.delete(e))}clear(){const e=this.cache.keys();let t=0;for(let r=e.next();!r.done;r=e.next())this.delete(r.value),t+=1;return t}}},7936:(e,t,r)=>{"use strict";function n(e){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n(e)}var i=r(8287).Buffer,o=r(2838).o,s=r(8570);"undefined"!=typeof window&&(window.Buffer=i),"undefined"!=typeof self&&(self.Buffer=i);var a={UInt8:1,UInt16LE:2,UInt16BE:2,UInt32LE:4,UInt32BE:4,Int8:1,Int16LE:2,Int16BE:2,Int32LE:4,Int32BE:4,FloatLE:4,FloatBE:4,DoubleLE:8,DoubleBE:8,UInt64:8,Int64:8},A={},f="___parser_",h=[];!function(){var e;for(e=1;e<=32;e++)h.push(e)}();var u={};Object.keys(a).concat(Object.keys({String:null,Buffer:null,Array:null,Skip:null,Choice:null,Nest:null,Bit:null,Itf8:null,Ltf8:null})).forEach((function(e){u[e.toLowerCase()]=e}));var l=function(){this.varName="",this.type="",this.options={},this.next=null,this.head=null,this.compiled=null,this.endian="le",this.constructorFn=null,this.alias=null};l.start=function(){return new l},Object.keys(a).forEach((function(e){l.prototype[e.toLowerCase()]=function(t,r){return this.setNextParser(e.toLowerCase(),t,r)};var t=e.replace(/BE|LE/,"").toLowerCase();t in l.prototype||(l.prototype[t]=function(e,r){return this[t+this.endian](e,r)})})),h.forEach((function(e){l.prototype["bit".concat(e.toString())]=function(t,r){return r||(r={}),r.length=e,this.setNextParser("bit",t,r)}})),l.prototype.namely=function(e){return A[e]=this,this.alias=e,this},l.prototype.skip=function(e,t){if(t&&t.assert)throw new Error("assert option on skip is not allowed.");return this.setNextParser("skip","",{length:e})},l.prototype.string=function(e,t){if(!t.zeroTerminated&&!t.length&&!t.greedy)throw new Error("Neither length, zeroTerminated, nor greedy is defined for string.");if((t.zeroTerminated||t.length)&&t.greedy)throw new Error("greedy is mutually exclusive with length and zeroTerminated for string.");if(t.stripNull&&!t.length&&!t.greedy)throw new Error("Length or greedy must be defined if stripNull is defined.");return t.encoding=t.encoding||"utf8",this.setNextParser("string",e,t)},l.prototype.buffer=function(e,t){if(!t.length&&!t.readUntil)throw new Error("Length nor readUntil is defined in buffer parser");return this.setNextParser("buffer",e,t)},l.prototype.array=function(e,t){if(!t.readUntil&&!t.length&&!t.lengthInBytes)throw new Error("Length option of array is not defined.");if(!t.type)throw new Error("Type option of array is not defined.");if("string"==typeof t.type&&!A[t.type]&&Object.keys(a).indexOf(u[t.type])<0)throw new Error('Specified primitive type "'.concat(t.type,'" is not supported.'));return this.setNextParser("array",e,t)},l.prototype.choice=function(e,t){if(1===arguments.length&&"object"===n(e)&&(t=e,e=null),!t.tag)throw new Error("Tag option of array is not defined.");if(!t.choices)throw new Error("Choices option of array is not defined.");return Object.keys(t.choices).forEach((function(r){if(!t.choices[r])throw new Error("Choice Case ".concat(r," of ").concat(e," is not valid."));if("string"==typeof t.choices[r]&&!A[t.choices[r]]&&Object.keys(a).indexOf(u[t.choices[r]])<0)throw new Error('Specified primitive type "'.concat(t.choices[r],'" is not supported.'))}),this),this.setNextParser("choice",e,t)},l.prototype.nest=function(e,t){if(1===arguments.length&&"object"===n(e)&&(t=e,e=null),!t.type)throw new Error("Type option of nest is not defined.");if(!(t.type instanceof l||A[t.type]))throw new Error("Type option of nest must be a Parser object.");if(!(t.type instanceof l||e))throw new Error("options.type must be a object if variable name is omitted.");return this.setNextParser("nest",e,t)},l.prototype.endianess=function(e){switch(e.toLowerCase()){case"little":this.endian="le";break;case"big":this.endian="be";break;default:throw new Error("Invalid endianess: ".concat(e))}return this},l.prototype.create=function(e){if(!(e instanceof Function))throw new Error("Constructor must be a Function object.");return this.constructorFn=e,this},l.prototype.getCode=function(){var e=new o;return e.pushCode("if (!Buffer.isBuffer(buffer)) {"),e.generateError('"argument buffer is not a Buffer object"'),e.pushCode("}"),this.alias?this.addAliasedCode(e):this.addRawCode(e),this.alias?e.pushCode("return {0}(0)",f+this.alias):e.pushCode("return { offset: offset, result: vars };"),e.code},l.prototype.addRawCode=function(e){e.pushCode("var offset = 0;"),this.constructorFn?e.pushCode("var vars = new constructorFn();"):e.pushCode("var vars = {};"),this.generate(e),this.resolveReferences(e),e.pushCode("return { offset: offset, result: vars };")},l.prototype.addAliasedCode=function(e){return e.pushCode("function {0}(offset) {",f+this.alias),this.constructorFn?e.pushCode("var vars = new constructorFn();"):e.pushCode("var vars = {};"),this.generate(e),e.markResolved(this.alias),this.resolveReferences(e),e.pushCode("return { offset: offset, result: vars };"),e.pushCode("}"),e},l.prototype.resolveReferences=function(e){var t=e.getUnresolvedReferences();e.markRequested(t),t.forEach((function(t){A[t].addAliasedCode(e)}))},l.prototype.compile=function(){var e,t="(function(buffer, constructorFn, Long) { ".concat(this.getCode()," })");this.compiled=(e=t,new Function("code","return eval(code);").call(globalThis,e))},l.prototype.sizeOf=function(){var e=NaN;if(Object.keys(a).indexOf(this.type)>=0)e=a[this.type];else if("String"===this.type&&"number"==typeof this.options.length)e=this.options.length;else if("Buffer"===this.type&&"number"==typeof this.options.length)e=this.options.length;else if("Array"===this.type&&"number"==typeof this.options.length){var t=NaN;"string"==typeof this.options.type?t=a[u[this.options.type]]:this.options.type instanceof l&&(t=this.options.type.sizeOf()),e=this.options.length*t}else"Skip"===this.type?e=this.options.length:"Nest"===this.type?e=this.options.type.sizeOf():this.type||(e=0);return this.next&&(e+=this.next.sizeOf()),e},l.prototype.parse=function(e){return this.compiled||this.compile(),this.compiled(e,this.constructorFn,s)},l.prototype.setNextParser=function(e,t,r){var n=new l;return n.type=u[e],n.varName=t,n.options=r||n.options,n.endian=this.endian,this.head?this.head.next=n:this.next=n,this.head=n,this},l.prototype.generate=function(e){this.type&&(this["generate".concat(this.type)](e),this.generateAssert(e));var t=e.generateVariable(this.varName);return this.options.formatter&&this.generateFormatter(e,t,this.options.formatter),this.generateNext(e)},l.prototype.generateAssert=function(e){if(this.options.assert){var t=e.generateVariable(this.varName);switch(n(this.options.assert)){case"function":e.pushCode("if (!({0}).call(vars, {1})) {",this.options.assert,t);break;case"number":e.pushCode("if ({0} !== {1}) {",this.options.assert,t);break;case"string":e.pushCode('if ("{0}" !== {1}) {',this.options.assert,t);break;default:throw new Error("Assert option supports only strings, numbers and assert functions.")}e.generateError('"Assert error: {0} is " + {0}',t),e.pushCode("}")}},l.prototype.generateNext=function(e){return this.next&&(e=this.next.generate(e)),e},Object.keys(a).forEach((function(e){l.prototype["generate".concat(e)]=function(t){"UInt64"===e?t.pushCode("{0} = Long.fromBytes(buffer.slice(offset,offset+8), true, this.endian === 'le').toNumber();",t.generateVariable(this.varName),e):"Int64"===e?t.pushCode("{0} = Long.fromBytes(buffer.slice(offset,offset+8), false, this.endian === 'le').toNumber();",t.generateVariable(this.varName),e):t.pushCode("{0} = buffer.read{1}(offset);",t.generateVariable(this.varName),e),t.pushCode("offset += {0};",a[e])}})),l.prototype.generateBit=function(e){var t=JSON.parse(JSON.stringify(this));if(t.varName=e.generateVariable(t.varName),e.bitFields.push(t),!this.next||this.next&&["Bit","Nest"].indexOf(this.next.type)<0){var r=0;e.bitFields.forEach((function(e){r+=e.options.length}));var n=e.generateTmpVariable();if(r<=8)e.pushCode("var {0} = buffer.readUInt8(offset);",n),r=8;else if(r<=16)e.pushCode("var {0} = buffer.readUInt16BE(offset);",n),r=16;else if(r<=24){var i=e.generateTmpVariable(),o=e.generateTmpVariable();e.pushCode("var {0} = buffer.readUInt16BE(offset);",i),e.pushCode("var {0} = buffer.readUInt8(offset + 2);",o),e.pushCode("var {2} = ({0} << 8) | {1};",i,o,n),r=24}else{if(!(r<=32))throw new Error("Currently, bit field sequence longer than 4-bytes is not supported.");e.pushCode("var {0} = buffer.readUInt32BE(offset);",n),r=32}e.pushCode("offset += {0};",r/8);var s=0,a="be"===this.endian;e.bitFields.forEach((function(t){e.pushCode("{0} = {1} >> {2} & {3};",t.varName,n,a?r-s-t.options.length:s,(1<<t.options.length)-1),s+=t.options.length})),e.bitFields=[]}},l.prototype.generateSkip=function(e){var t=e.generateOption(this.options.length);e.pushCode("offset += {0};",t)},l.prototype.generateString=function(e){var t=e.generateVariable(this.varName),r=e.generateTmpVariable();this.options.length&&this.options.zeroTerminated?(e.pushCode("var {0} = offset;",r),e.pushCode("while(buffer.readUInt8(offset++) !== 0 && offset - {0} < {1});",r,this.options.length),e.pushCode("{0} = buffer.toString('{1}', {2}, offset - {2} < {3} ? offset - 1 : offset);",t,this.options.encoding,r,this.options.length)):this.options.length?(e.pushCode("{0} = buffer.toString('{1}', offset, offset + {2});",t,this.options.encoding,e.generateOption(this.options.length)),e.pushCode("offset += {0};",e.generateOption(this.options.length))):this.options.zeroTerminated?(e.pushCode("var {0} = offset;",r),e.pushCode("while(buffer.readUInt8(offset++) !== 0);"),e.pushCode("{0} = buffer.toString('{1}', {2}, offset - 1);",t,this.options.encoding,r)):this.options.greedy&&(e.pushCode("var {0} = offset;",r),e.pushCode("while(buffer.length > offset++);"),e.pushCode("{0} = buffer.toString('{1}', {2}, offset);",t,this.options.encoding,r)),this.options.stripNull&&e.pushCode("{0} = {0}.replace(/\\x00+$/g, '')",t)},l.prototype.generateBuffer=function(e){"eof"===this.options.readUntil?e.pushCode("{0} = buffer.slice(offset);",e.generateVariable(this.varName)):(e.pushCode("{0} = buffer.slice(offset, offset + {1});",e.generateVariable(this.varName),e.generateOption(this.options.length)),e.pushCode("offset += {0};",e.generateOption(this.options.length))),this.options.clone&&e.pushCode("{0} = Buffer.from({0});",e.generateVariable(this.varName))},l.prototype.generateArray=function(e){var t=e.generateOption(this.options.length),r=e.generateOption(this.options.lengthInBytes),n=this.options.type,i=e.generateTmpVariable(),o=e.generateVariable(this.varName),s=e.generateTmpVariable(),h=this.options.key,c="string"==typeof h;if(c?e.pushCode("{0} = {};",o):e.pushCode("{0} = [];",o),"function"==typeof this.options.readUntil?e.pushCode("do {"):"eof"===this.options.readUntil?e.pushCode("for (var {0} = 0; offset < buffer.length; {0}++) {",i):void 0!==r?e.pushCode("for (var {0} = offset; offset - {0} < {1}; ) {",i,r):e.pushCode("for (var {0} = 0; {0} < {1}; {0}++) {",i,t),"string"==typeof n)if(A[n]){var d=e.generateTmpVariable();e.pushCode("var {0} = {1}(offset);",d,f+n),e.pushCode("var {0} = {1}.result; offset = {1}.offset;",s,d),n!==this.alias&&e.addReference(n)}else e.pushCode("var {0} = buffer.read{1}(offset);",s,u[n]),e.pushCode("offset += {0};",a[u[n]]);else n instanceof l&&(e.pushCode("var {0} = {};",s),e.pushScope(s),n.generate(e),e.popScope());c?e.pushCode("{0}[{2}.{1}] = {2};",o,h,s):e.pushCode("{0}.push({1});",o,s),e.pushCode("}"),"function"==typeof this.options.readUntil&&e.pushCode(" while (!({0}).call(this, {1}, buffer.slice(offset)));",this.options.readUntil,s)},l.prototype.generateChoiceCase=function(e,t,r){if("string"==typeof r)if(A[r]){var n=e.generateTmpVariable();e.pushCode("var {0} = {1}(offset);",n,f+r),e.pushCode("{0} = {1}.result; offset = {1}.offset;",e.generateVariable(this.varName),n),r!==this.alias&&e.addReference(r)}else e.pushCode("{0} = buffer.read{1}(offset);",e.generateVariable(this.varName),u[r]),e.pushCode("offset += {0};",a[u[r]]);else r instanceof l&&(e.pushPath(t),r.generate(e),e.popPath(t))},l.prototype.generateChoice=function(e){var t=e.generateOption(this.options.tag);this.varName&&e.pushCode("{0} = {};",e.generateVariable(this.varName)),e.pushCode("switch({0}) {",t),Object.keys(this.options.choices).forEach((function(t){var r=this.options.choices[t];Number.isNaN(parseInt(t,10))?e.pushCode("case '{0}':",t):e.pushCode("case {0}:",t),this.generateChoiceCase(e,this.varName,r),e.pushCode("break;")}),this),e.pushCode("default:"),this.options.defaultChoice?this.generateChoiceCase(e,this.varName,this.options.defaultChoice):e.generateError('"Met undefined tag value " + {0} + " at choice"',t),e.pushCode("}")},l.prototype.generateNest=function(e){var t=e.generateVariable(this.varName);if(this.options.type instanceof l)this.varName&&e.pushCode("{0} = {};",t),e.pushPath(this.varName),this.options.type.generate(e),e.popPath(this.varName);else if(A[this.options.type]){var r=e.generateTmpVariable();e.pushCode("var {0} = {1}(offset);",r,f+this.options.type),e.pushCode("{0} = {1}.result; offset = {1}.offset;",t,r),this.options.type!==this.alias&&e.addReference(this.options.type)}},l.prototype.generateFormatter=function(e,t,r){"function"==typeof r&&e.pushCode("{0} = ({1}).call(this, {0});",t,r)},l.prototype.isInteger=function(){return!!this.type.match(/U?Int[8|16|32][BE|LE]?|Bit\d+/)},l.prototype.itf8=function(e,t){return this.setNextParser("itf8",e,t)},l.prototype.itf8=function(e,t){return this.setNextParser("itf8",e,t)},l.prototype.generateItf8=function(e){var t=e.generateVariable(this.varName),r=e.generateTmpVariable();e.pushCode("\n var ".concat(r," = buffer[offset];\n if (").concat(r," < 0x80) {\n ").concat(t," = ").concat(r,";\n offset += 1;\n } else if (").concat(r," < 0xc0) {\n ").concat(t," = ((").concat(r,"<<8) | buffer[offset+1]) & 0x3fff;\n offset += 2;\n } else if (").concat(r," < 0xe0) {\n ").concat(t," = ((").concat(r,"<<16) | (buffer[offset+1]<< 8) | buffer[offset+2]) & 0x1fffff;\n offset += 3;\n } else if (").concat(r," < 0xf0) {\n ").concat(t," = ((").concat(r,"<<24) | (buffer[offset+1]<<16) | (buffer[offset+2]<<8) | buffer[offset+3]) & 0x0fffffff;\n offset += 4\n } else {\n ").concat(t," = ((").concat(r," & 0x0f)<<28) | (buffer[offset+1]<<20) | (buffer[offset+2]<<12) | (buffer[offset+3]<<4) | (buffer[offset+4] & 0x0f);\n // x=((0xff & 0x0f)<<28) | (0xff<<20) | (0xff<<12) | (0xff<<4) | (0x0f & 0x0f);\n // TODO *val_p = uv < 0x80000000UL ? uv : -((int32_t) (0xffffffffUL - uv)) - 1;\n offset += 5\n }\n "))},l.prototype.ltf8=function(e,t){return this.setNextParser("ltf8",e,t)},l.prototype.generateLtf8=function(e){var t=e.generateVariable(this.varName),r=e.generateTmpVariable();e.pushCode("\n var ".concat(r," = buffer[offset];\n if (").concat(r," < 0x80) {\n ").concat(t," = ").concat(r,";\n offset += 1;\n } else if (").concat(r," < 0xc0) {\n ").concat(t," = ((buffer[offset]<<8) | buffer[offset+1]) & 0x3fff;\n offset += 2;\n } else if (").concat(r," < 0xe0) {\n ").concat(t," = ((buffer[offset]<<16) | (buffer[offset+1]<<8) | buffer[offset+2]) & 0x1fffff;\n ").concat(t," = (((").concat(r," & 63) << 16) | buffer.readUInt16LE(offset + 1));\n offset += 3;\n } else if (").concat(r," < 0xf0) {\n ").concat(t," = ((buffer[offset]<<24) | (buffer[offset+1]<<16) | (buffer[offset+2]<<8) | buffer[offset+3]) & 0x0fffffff;\n offset += 4;\n } else if (").concat(r," < 0xf8) {\n ").concat(t," = (((buffer[offset] & 15) * Math.pow(2,32))) +\n (buffer[offset+1]<<24) | (buffer[offset+2]<<16 | buffer[offset+3]<<8 | buffer[offset+4])\n // TODO *val_p = uv < 0x80000000UL ? uv : -((int32_t) (0xffffffffUL - uv)) - 1;\n offset += 5;\n } else if (").concat(r," < 0xfc) {\n ").concat(t," = ((((buffer[offset] & 7) << 8) | buffer[offset+1] )) * Math.pow(2,32) +\n (buffer[offset+2]<<24) | (buffer[offset+3]<<16 | buffer[offset+4]<<8 | buffer[offset+5])\n offset += 6;\n } else if (").concat(r," < 0xfe) {\n ").concat(t," = ((((buffer[offset] & 3) << 16) | buffer[offset+1]<<8 | buffer[offset+2])) * Math.pow(2,32) +\n (buffer[offset+3]<<24) | (buffer[offset+4]<<16 | buffer[offset+5]<<8 | buffer[offset+6])\n offset += 7;\n } else if (").concat(r," < 0xff) {\n ").concat(t," = Long.fromBytesBE(buffer.slice(offset+1,offset+8));\n if (").concat(t,".greaterThan(Number.MAX_SAFE_INTEGER) || ").concat(t,".lessThan(Number.MIN_SAFE_INTEGER))\n throw new Error('integer overflow')\n ").concat(t," = ").concat(t,".toNumber()\n offset += 8;\n } else {\n ").concat(t," = Long.fromBytesBE(buffer.slice(offset+1,offset+9));\n if (").concat(t,".greaterThan(Number.MAX_SAFE_INTEGER) || ").concat(t,".lessThan(Number.MIN_SAFE_INTEGER))\n throw new Error('integer overflow')\n ").concat(t," = ").concat(t,".toNumber()\n offset += 9;\n }\n "))},t.Parser=l},2838:(e,t)=>{"use strict";function r(e){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r(e)}var n=function(){this.code="",this.scopes=[["vars"]],this.isAsync=!1,this.bitFields=[],this.tmpVariableCount=0,this.references={}};n.prototype.generateVariable=function(e){var t=[];for(Array.prototype.push.apply(t,this.scopes[this.scopes.length-1]);/^\$parent\./.test(e);)t.pop(),e=e.replace(/^\$parent\./,"");return e&&t.push(e),t.join(".")},n.prototype.generateOption=function(e){switch(r(e)){case"number":return e.toString();case"string":return this.generateVariable(e);case"function":return"(".concat(e,").call(").concat(this.generateVariable(),", vars)");default:return}},n.prototype.generateError=function(){var e=Array.prototype.slice.call(arguments),t=n.interpolate.apply(this,e);this.isAsync?this.pushCode("return process.nextTick(function() { callback(new Error(".concat(t,"), vars); });")):this.pushCode("throw new Error(".concat(t,");"))},n.prototype.generateTmpVariable=function(){return"$tmp".concat(this.tmpVariableCount++)},n.prototype.pushCode=function(){var e=Array.prototype.slice.call(arguments);this.code+="".concat(n.interpolate.apply(this,e),"\n")},n.prototype.pushPath=function(e){e&&this.scopes[this.scopes.length-1].push(e)},n.prototype.popPath=function(e){e&&this.scopes[this.scopes.length-1].pop()},n.prototype.pushScope=function(e){this.scopes.push([e])},n.prototype.popScope=function(){this.scopes.pop()},n.prototype.addReference=function(e){this.references[e]||(this.references[e]={resolved:!1,requested:!1})},n.prototype.markResolved=function(e){this.references[e].resolved=!0},n.prototype.markRequested=function(e){e.forEach(function(e){this.references[e].requested=!0}.bind(this))},n.prototype.getUnresolvedReferences=function(){var e=this.references;return Object.keys(this.references).filter((function(t){return!e[t].resolved&&!e[t].requested}))},n.interpolate=function(e){var t=e.match(/{\d+}/g),r=Array.prototype.slice.call(arguments,1);return t&&t.forEach((function(t){var n=parseInt(t.substr(1,t.length-2),10);e=e.replace(t,r[n].toString())})),e},t.o=n},635:(e,t,r)=>{const n=r(4646),i=r(8706),o=r(9614),s=r(235),a=128;e.exports=class{decode(e){return this.stream=new i(e),this.decodeStream(this.stream)}decodeStream(e,t=0){var r=this.stream.ReadByte();16&r||(t=this.stream.ReadUint7());var n,i=t,o=1&r;if(8&r)return this.decodeStripe(this.stream,t);if(r&a&&([n,i]=this.decodePackMeta(this.stream)),32&r)var s=this.decodeCat(this.stream,i);else s=4&r?this.decodeExt(this.stream,i):64&r?o?this.decodeRLE1(this.stream,i):this.decodeRLE0(this.stream,i):o?this.decode1(this.stream,i):this.decode0(this.stream,i);return r&a&&(s=this.decodePack(s,n,t)),s}encode(e,t){if(this.stream=new i("",0,1.1*e.length+100),this.stream.WriteByte(t),16&t||this.stream.WriteUint7(e.length),8&t)return Buffer.concat([this.stream.buf.slice(0,this.stream.pos),this.encodeStripe(this.stream,e,t>>8)]);var r,n=1&t,o=e.length;return t&a&&([r,e,o]=this.encodePack(e)),t&a&&this.stream.WriteStream(r),64&t?n?this.encodeRLE1(e,o,this.stream):this.encodeRLE0(e,o,this.stream):n?this.encode1(e,o,this.stream):this.encode0(e,o,this.stream)}decode0(e,t){var r=new Buffer.allocUnsafe(t),i=e.ReadByte();0==i&&(i=256);var s=new o(i),a=new n(e);a.RangeStartDecode(e);for(var A=0;A<t;A++)r[A]=s.ModelDecode(e,a);return r}encode0(e,t,r){for(var i=0,s=0;s<t;s++)i<e[s]&&(i=e[s]);i++;var a=new o(i);r.WriteByte(i);var A=new n(r);for(s=0;s<t;s++)a.ModelEncode(r,A,e[s]);return A.RangeFinishEncode(r),r.buf.slice(0,r.pos)}decode1(e,t){var r=new Buffer.allocUnsafe(t),i=e.ReadByte();0==i&&(i=256);for(var s=new Array(i),a=0;a<i;a++)s[a]=new o(i);var A=new n(e);A.RangeStartDecode(e);var f=0;for(a=0;a<t;a++)r[a]=s[f].ModelDecode(e,A),f=r[a];return r}encode1(e,t,r){for(var i=0,s=0;s<t;s++)i<e[s]&&(i=e[s]);i++;var a=new Array(i);for(s=0;s<i;s++)a[s]=new o(i);r.WriteByte(i);var A=new n(r),f=0;for(s=0;s<t;s++)a[f].ModelEncode(r,A,e[s]),f=e[s];return A.RangeFinishEncode(r),r.buf.slice(0,r.pos)}decodeExt(e,t){var r=new Buffer.allocUnsafe(t),n=s.array(e.buf.slice(e.pos)),i=s.header(n),o=0;do{var a=s.decompress(n,i);-1!=a&&(Buffer.from(a).copy(r,o),o+=a.length,i-=a.length)}while(-1!=a);return r}encodeExt(e,t){}decodeRLE0(e,t){var r=new Buffer.allocUnsafe(t),i=e.ReadByte();0==i&&(i=256);for(var s=new o(i),a=new Array(258),A=0;A<=257;A++)a[A]=new o(4);var f=new n(e);for(f.RangeStartDecode(e),A=0;A<t;){r[A]=s.ModelDecode(e,f);for(var h=a[r[A]].ModelDecode(e,f),u=h,l=256;3==h;)h=a[l].ModelDecode(e,f),l=257,u+=h;for(var c=1;c<=u;c++)r[A+c]=r[A];A+=u+1}return r}encodeRLE0(e,t,r){for(var i=0,s=0;s<t;s++)i<e[s]&&(i=e[s]);i++;var a=new o(i),A=new Array(258);for(s=0;s<=257;s++)A[s]=new o(4);r.WriteByte(i);var f=new n(r);for(s=0;s<t;){a.ModelEncode(r,f,e[s]);for(var h=1;s+h<t&&e[s+h]==e[s];)h++;h--;var u=e[s];e[s],s+=h+1;var l=h>=3?3:h;for(A[u].ModelEncode(r,f,l),h-=l,u=256;3==l;)l=h>=3?3:h,A[u].ModelEncode(r,f,l),u=257,h-=l}return f.RangeFinishEncode(r),r.buf.slice(0,r.pos)}decodeRLE1(e,t){var r=new Buffer.allocUnsafe(t),i=e.ReadByte();0==i&&(i=256);for(var s=new Array(i),a=0;a<i;a++)s[a]=new o(i);var A=new Array(258);for(a=0;a<=257;a++)A[a]=new o(4);var f=new n(e);f.RangeStartDecode(e);var h=0;for(a=0;a<t;){r[a]=s[h].ModelDecode(e,f),h=r[a];for(var u=A[r[a]].ModelDecode(e,f),l=u,c=256;3==u;)u=A[c].ModelDecode(e,f),c=257,l+=u;for(var d=1;d<=l;d++)r[a+d]=r[a];a+=l+1}return r}encodeRLE1(e,t,r){for(var i=0,s=0;s<t;s++)i<e[s]&&(i=e[s]);i++;var a=new Array(i);for(s=0;s<i;s++)a[s]=new o(i);var A=new Array(258);for(s=0;s<=257;s++)A[s]=new o(4);r.WriteByte(i);for(var f=new n(r),h=(s=0,0);s<t;){a[h].ModelEncode(r,f,e[s]);for(var u=1;s+u<t&&e[s+u]==e[s];)u++;u--;var l=e[s];h=e[s],s+=u+1;var c=u>=3?3:u;for(A[l].ModelEncode(r,f,c),u-=c,l=256;3==c;)c=u>=3?3:u,A[l].ModelEncode(r,f,c),l=257,u-=c}return f.RangeFinishEncode(r),r.buf.slice(0,r.pos)}decodePackMeta(e){this.nsym=e.ReadByte();for(var t=new Array(this.nsym),r=0;r<this.nsym;r++)t[r]=e.ReadByte();return[t,e.ReadUint7()]}decodePack(e,t,r){var n=new Buffer.allocUnsafe(r);if(this.nsym<=1)for(var i=0;i<r;i++)n[i]=t[0];else if(this.nsym<=2){i=0;for(var o=0;i<r;i++){if(i%8==0)var s=e[o++];n[i]=t[1&s],s>>=1}}else if(this.nsym<=4)for(i=0,o=0;i<r;i++)i%4==0&&(s=e[o++]),n[i]=t[3&s],s>>=2;else{if(!(this.nsym<=16))return e;for(i=0,o=0;i<r;i++)i%2==0&&(s=e[o++]),n[i]=t[15&s],s>>=4}return n}packMeta(e){for(var t=new i("",0,1024),r=new Array(256),n=0;n<e.length;n++)r[e[n]]=1;var o=0;for(n=0;n<256;n++)r[n]&&(r[n]=++o);for(t.WriteByte(o),n=0;n<256;n++)r[n]&&(t.WriteByte(n),r[n]--);return[t,r,o]}encodePack(e){var t,r,n;[t,r,n]=this.packMeta(e);var i=e.length,o=0;if(n<=1)return t.WriteUint7(0),[t,new Buffer.allocUnsafe(0),0];if(n<=2){for(var s=new Buffer.allocUnsafe(Math.floor((i+7)/8)),a=(o=0,0);o<(-8&i);o+=8,a++)s[a]=(0|r[e[o+0]])+(r[e[o+1]]<<1)+(r[e[o+2]]<<2)+(r[e[o+3]]<<3)+(r[e[o+4]]<<4)+(r[e[o+5]]<<5)+(r[e[o+6]]<<6)+(r[e[o+7]]<<7);if(o<i){s[a]=0;for(var A=0;o<i;)s[a]|=r[e[o++]]<<A,A++;a++}return t.WriteUint7(a),[t,s,s.length]}if(n<=4){for(s=new Buffer.allocUnsafe(Math.floor((i+3)/4)),o=0,a=0;o<(-4&i);o+=4,a++)s[a]=(0|r[e[o+0]])+(r[e[o+1]]<<2)+(r[e[o+2]]<<4)+(r[e[o+3]]<<6);if(o<i){for(s[a]=0,A=0;o<i;)s[a]|=r[e[o++]]<<A,A+=2;a++}return t.WriteUint7(a),[t,s,s.length]}if(n<=16){for(s=new Buffer.allocUnsafe(Math.floor((i+1)/2)),o=0,a=0;o<(-2&i);o+=2,a++)s[a]=(0|r[e[o+0]])+(r[e[o+1]]<<4);return o<i&&(s[a++]=r[e[o++]]),t.WriteUint7(a),[t,s,s.length]}return t.WriteUint7(e.length),[t,e,e.length]}encodeStripe(e,t,r){0==r&&(r=4);for(var n=new Array(r),o=new Array(r),s=0;s<r;s++)o[s]=Math.floor(t.length/r)+(t.length%r>s),n[s]=new Array(o[s]);for(var a=0,A=0;A<t.length;A+=r,a++)for(var f=0;f<r;f++)a<n[f].length&&(n[f][a]=t[A+f]);var h=new Array(r),u=0;for(s=0;s<r;s++){var l=this.encode(n[s],0),c=this.encode(n[s],1);h[s]=c.length<l.length?c:l,u+=h[s].length}var d=new i("",0,u+5*r+1);for(d.WriteByte(r),s=0;s<r;s++)d.WriteUint7(h[s].length);for(s=0;s<r;s++)d.WriteData(h[s],h[s].length);return d.buf.slice(0,d.buf.pos)}decodeStripe(e,t){for(var r=e.ReadByte(),n=new Array(r),i=new Array(r),o=0;o<r;o++)n[o]=e.ReadUint7();var s=new Array(r);for(o=0;o<r;o++)i[o]=Math.floor(t/r)+(t%r>o),s[o]=this.decodeStream(e,i[o]);var a=new Buffer.allocUnsafe(t);for(o=0;o<r;o++)for(var A=0;A<i[o];A++)a[A*r+o]=s[o][A];return a}decodeCat(e,t){for(var r=new Buffer.allocUnsafe(t),n=0;n<t;n++)r[n]=e.ReadByte();return r}}},4646:e=>{e.exports=class{constructor(e){this.low=0,this.range=4294967295,this.code=0,this.FFnum=0,this.carry=0,this.cache=0}RangeStartDecode(e){for(var t=0;t<5;t++)this.code=(this.code<<8)+e.ReadByte();this.code&=4294967295,this.code>>>=0}RangeGetFrequency(e){return this.range=Math.floor(this.range/e),Math.floor(this.code/this.range)}RangeDecode(e,t,r,n){for(this.code-=t*this.range,this.range*=r;this.range<1<<24;)this.range*=256,this.code=256*this.code+e.ReadByte()}RangeShiftLow(e){if(this.low<4278190080|this.carry){for(e.WriteByte(this.cache+this.carry);this.FFnum;)e.WriteByte(this.carry-1),this.FFnum--;this.cache=this.low>>>24,this.carry=0}else this.FFnum++;this.low<<=8,this.low>>>=0}RangeEncode(e,t,r,n){var i=this.low;for(this.range=Math.floor(this.range/n),this.low+=t*this.range,this.low>>>=0,this.range*=r,this.low<i&&(0!=this.carry&&console.log("ERROR: Multiple carry"),this.carry=1);this.range<1<<24;)this.range*=256,this.RangeShiftLow(e)}RangeFinishEncode(e){for(var t=0;t<5;t++)this.RangeShiftLow(e)}}},9614:e=>{e.exports=class{constructor(e=256){this.total_freq=e,this.max_sym=e-1,this.S=new Array,this.F=new Array;for(var t=0;t<=this.max_sym;t++)this.S[t]=t,this.F[t]=1}ModelDecode(e,t){for(var r=t.RangeGetFrequency(this.total_freq),n=0,i=0;n+this.F[i]<=r;)n+=this.F[i++];t.RangeDecode(e,n,this.F[i],this.total_freq),this.F[i]+=16,this.total_freq+=16,this.total_freq>65519&&this.ModelRenormalise();var o=this.S[i];if(i>0&&this.F[i]>this.F[i-1]){var s=this.F[i];this.F[i]=this.F[i-1],this.F[i-1]=s,s=this.S[i],this.S[i]=this.S[i-1],this.S[i-1]=s}return o}ModelRenormalise(){this.total_freq=0;for(var e=0;e<=this.max_sym;e++)this.F[e]-=Math.floor(this.F[e]/2),this.total_freq+=this.F[e]}ModelEncode(e,t,r){for(var n=0,i=0;this.S[i]!=r;i++)n+=this.F[i];if(t.RangeEncode(e,n,this.F[i],this.total_freq),this.F[i]+=16,this.total_freq+=16,this.total_freq>65519&&this.ModelRenormalise(),r=this.S[i],i>0&&this.F[i]>this.F[i-1]){var o=this.F[i];this.F[i]=this.F[i-1],this.F[i-1]=o,o=this.S[i],this.S[i]=this.S[i-1],this.S[i-1]=o}}}},6038:(e,t,r)=>{const n=r(8706),i=r(9614),o=r(4646);function s(e,t,r){for(var n=0,i=0,o=-1,s=new Array(1024);i<r;){var a=e.ReadByte();if(s[n++]=a,i+=a,a==o){var A=e.ReadByte();for(i+=a*A;A--;)s[n++]=a}o=a}var f=0;for(n=0,i=0;i<r;){var h=0;do{var u=s[n++];h+=u}while(255==u);for(;h--;)t[i++]=f;f++}}const a=2,A=4,f=8,h=16,u=32,l=64,c=128;function d(e,t,r){var n=e.context;return t.qctx=(t.qctx<<e.qshift)+e.qtab[r],n+=(t.qctx&(1<<e.qbits)-1)<<e.qloc,e.do_pos&&(n+=e.ptab[Math.min(t.p,1023)]<<e.ploc),e.do_delta&&(n+=e.dtab[Math.min(t.delta,255)]<<e.dloc,t.delta+=t.prevq!=r?1:0,t.prevq=r),e.do_sel&&(n+=t.s<<e.sloc),t.p--,65535&n}function g(e){var t={};t.context=e.ReadUint16(),t.pflags=e.ReadByte(),t.do_dedup=t.pflags&a,t.fixed_len=t.pflags&A,t.do_sel=t.pflags&f,t.do_qmap=t.pflags&h,t.do_pos=t.pflags&u,t.do_delta=t.pflags&l,t.do_qtab=t.pflags&c,t.max_sym=e.ReadByte();var r=e.ReadByte();if(t.qbits=r>>4,t.qshift=15&r,r=e.ReadByte(),t.qloc=r>>4,t.sloc=15&r,r=e.ReadByte(),t.ploc=r>>4,t.dloc=15&r,t.qmap=new Array(256),t.pflags&h)for(var n=0;n<t.max_sym;n++)t.qmap[n]=e.ReadByte();else for(n=0;n<256;n++)t.qmap[n]=n;if(t.qtab=new Array(1024),t.qbits>0&&t.pflags&c)s(e,t.qtab,256);else for(n=0;n<256;n++)t.qtab[n]=n;return t.ptab=new Array(1024),t.pflags&u&&s(e,t.ptab,1024),t.dtab=new Array(256),t.pflags&l&&s(e,t.dtab,256),t}function p(e,t,r,n,i,o){r.max_sel>0?i.s=n.sel.ModelDecode(e,t):i.s=0,i.x=r.stab[i.s];var s=r.params[i.x];if(s.fixed_len>=0){var A=n.len[0].ModelDecode(e,t);A|=n.len[1].ModelDecode(e,t)<<8,A|=n.len[2].ModelDecode(e,t)<<16,A|=n.len[3].ModelDecode(e,t)<<24,s.fixed_len>0&&(s.fixed_len=-A)}else A=-s.fixed_len;i.len=A,r.do_rev&&(o[i.rec]=n.rev.ModelDecode(e,t)),i.is_dup=0,s.pflags&a&&n.dup.ModelDecode(e,t)&&(i.is_dup=1),i.p=A,i.delta=0,i.qctx=0,i.prevq=0,i.rec++}function C(e,t,r){for(var n=0,i=0,o=new Array(2*r),s=0;n<r;){for(var a=n;n<r&&t[n]==i;)n++;var A=n-a;do{var f=Math.min(255,A);o[s++]=f,A-=f}while(255==f);i++}var h=-1,u=new Array(2*r),l=0;for(n=0;n<s;){var c=o[n++];if(u[l++]=c,c==h){for(a=n;n<s&&o[n]==h&&n-a<255;)n++;u[l++]=n-a}else h=c}e.WriteData(u,l)}e.exports={decode:function(e,t){return function(e,t){var r=e.ReadUint7(),n=function(e){var t={max_sym:0};if(5==e.ReadByte()){var r=e.ReadByte(),n=1&r?e.ReadByte():1,i=r.nparam>1?r.nparam-1:0,o=new Array(256);if(2&r)i=e.ReadByte(),s(e,o,256);else{for(var a=0;a<n;a++)o[a]=a;for(;a<256;a++)o[a]=n-1}t.do_rev=4&r,t.stab=o,t.max_sel=i,t.params=new Array(t.nparam);for(var A=0;A<n;A++)t.params[A]=g(e),t.max_sym<t.params[A].max_sym&&(t.max_sym=t.params[A].max_sym);return t}console.error("Invalid FQZComp version number")}(e);if(n){var a=n.params,A=new Array(t.length),f=function(e){var t={};t.qual=new Array(65536);for(var r=0;r<65536;r++)t.qual[r]=new i(e.max_sym+1);for(t.len=new Array(4),r=0;r<4;r++)t.len[r]=new i(256);return t.rev=new i(2),t.dup=new i(2),e.max_sel>0&&(t.sel=new i(e.max_sel+1)),t}(n),h=new o(e);h.RangeStartDecode(e);for(var u=new Buffer.allocUnsafe(r),l={qctx:0,prevq:0,delta:0,p:0,s:0,x:0,len:0,is_dup:0,rec:0},c=0;c<r;){if(0==l.p){if(p(e,h,n,f,l,A),l.is_dup>0&&f.dup.ModelDecode(e,h)){for(var C=0;C<len;C++)u[c+C]=u[c+C-l.len];c+=l.len,l.p=0;continue}t.push(l.len);var I=(a=n.params[l.x]).context}var m=f.qual[I].ModelDecode(e,h);u[c++]=a.qmap[m],I=d(a,l,m)}return n.do_rev&&function(e,t,r,n){for(var i=0,o=0;o<t;){if(r[i])for(var s=0,a=n[i]-1;s<a;){var A=e[o+s];e[o+s]=e[o+a],e[o+a]=A,s++,a--}o+=n[i++]}}(u,r,A,t),u}}(new n(e),t)},encode:function(e,t,r){for(var s=new Array(2),d=new Array(2),g=new Array(2),p=new Array(2),I=new Array(256),m=0;m<2;m++)s[m]=new Array(256),d[m]=new Array(256),g[m]=new Array(1024),p[m]=new Array(256);(w=new n("",0,1.1*e.length+100)).WriteUint7(e.length);var y=function(e,t,r,n){for(var i=r[0],o=0;o<r.length&&r[o]==i;o++);var s=o==r.length?1:0,a=0,A=0;for(o=0;o<256;o++)n[0][o]=0;var f=0,h=0;for(o=0;o<e.length;o++)0==h&&(h=t[f<t.length-1?f++:f]),n[0][e[o]]++,h--;for(o=0;o<256;o++)n[0][o]&&(A<o&&(A=o),a++);var u=5,l=0;return a<=16&&(l=1,u=a<=2?1:a<=4?2:a<=8?3:4),[{qbits:8+(u>4),qshift:u,qloc:7,pbits:7,pshift:t[0]>128?1:0,ploc:0,dbits:u>4?0:1,dshift:3,dloc:15,sbits:0,sloc:15,do_stab:0,context:0,max_sym:A,nsym:a,do_qmap:l,do_dedup:0,fixed_len:1==t.length?1:0,do_sel:0,do_rev:0,do_pos:1,do_delta:u<=4?1:0,do_qtab:0,qbits:8+(u>4)-(0==s),sbits:1,sloc:15-(u<=4),do_stab:1,do_sel:1}]}(e,t,r,s),w=function(e,t,r,n,i,o,s){for(var d=[0,1,1,1,2,2,2,2,2,3,3,3,3,3,3,3,4,4,4,4,4,4,4,4,4,5,5,5,5,5,5,5,5,5,5,5,6,6,6,6,6,6,6,6,6,6,6,6,6,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7],g=0;g<t.length;g++)s[g]=g;for(;g<256;g++)s[g]=t.length-1;e.WriteByte(5);var p=(t.length>1?1:0)|(t[0].do_stab?2:0);if(e.WriteByte(p),1&p&&e.WriteByte(t.length),2&p){var I=1<<t[0].sbits;I>0&&I--,e.WriteByte(I),C(e,s,256)}for(var m=0;m<t.length;m++){if(e.WriteUint16(t[m].context),e.WriteByte((t[m].do_qtab?c:0)|(t[m].do_delta?l:0)|(t[m].do_pos?u:0)|(t[m].do_qmap?h:0)|(t[m].do_sel?f:0)|(t[m].fixed_len?A:0)|(t[m].do_dedup?a:0)),t[m].do_qmap?e.WriteByte(t[m].nsym):e.WriteByte(t[m].max_sym),e.WriteByte(t[m].qbits<<4|t[m].qshift),e.WriteByte(t[m].qloc<<4|t[m].sloc),e.WriteByte(t[m].ploc<<4|t[m].dloc),t[m].do_qmap){t[m].max_sym=t[m].nsym;var y=0;for(g=0;g<256;g++)r[m][g]&&(e.WriteByte(g),r[m][g]=y++);for(;y<t[m].nsym;y++)e.WriteByte(0)}else for(g=0;g<256;g++)r[m][g]=g;if(t[m].qbits>0){for(g=0;g<256;g++)n[m][g]=g;t[m].do_qtab&&C(e,n[m],256)}if(t[m].pbits>0){for(g=0;g<1024;g++)i[m][g]=Math.min((1<<t[m].pbits)-1,g>>t[m].pshift);C(e,i[m],1024)}if(t[m].dbits>0){for(g=0;g<256;g++)d[g]>(1<<t[m].dbits)-1&&(d[g]=(1<<t[m].dbits)-1);for(g=0;g<256;g++)o[m][g]=d[Math.min(d.length-1,g>>t[m].dshift)];C(e,o[m],256)}}return e}(w,y,s,d,g,p,I);return function(e,t,r,n,s,a,A,f,h,u){var l=1<<s[0].sbits;l>0&&l--;for(var c=t.length,d=0,g=0;g<s.length;g++)d<s[g].max_sym&&(d=s[g].max_sym);for(var p=new Array(65536),C=0;C<65536;C++)p[C]=new i(d+1);var I=new Array(4);for(C=0;C<4;C++)I[C]=new i(256);new i(2),new i(2);for(var m=new i(l+1),y=new o(t),w=(g=0,C=0,0);C<c;){if(0==g){var B=n[w];s[0].sbits>0&&m.ModelEncode(e,y,B);var E=u[B],b=r[Math.min(r.length-1,w++)];s[E].fixed_len?s[E].fixed_len>0&&(I[0].ModelEncode(e,y,255&b),I[1].ModelEncode(e,y,b>>8&255),I[2].ModelEncode(e,y,b>>16&255),I[3].ModelEncode(e,y,b>>24&255),s[E].fixed_len=-1):(I[0].ModelEncode(e,y,255&b),I[1].ModelEncode(e,y,b>>8&255),I[2].ModelEncode(e,y,b>>16&255),I[3].ModelEncode(e,y,b>>24&255)),s[E].do_dedup&&process.exit(1),g=b;var _=0,v=s[E].context,Q=0,S=0}var k=t[C++],D=a[E][k];p[v].ModelEncode(e,y,D),Q=(Q<<s[E].qshift)+A[E][D],v=s[E].context,v+=(Q&(1<<s[E].qbits)-1)<<s[E].qloc,s[E].pbits>0&&(v+=f[E][Math.min(g,1023)]<<s[E].ploc),s[E].dbits>0&&(v+=h[E][Math.min(_,255)]<<s[E].dloc,_+=S!=D?1:0,S=D),s[E].do_sel&&(v+=B<<s[E].sloc),v&=65535,g--}return y.RangeFinishEncode(e),e.buf.slice(0,e.pos)}(w,e,t,r,y,s,d,g,p,I)}}},6960:(e,t,r)=>{"use strict";var n=r(5460),i=r(8223),o=r(635),s=r(6038),a=r(5997);e.exports={r4x8_uncompress:function(e,t){n.decode(e).copy(t,0,0)},r4x16_uncompress:function(e,t){i.decode(e).copy(t,0,0)},arith_uncompress:function(e,t){o.decode(e).copy(t,0,0)},fqzcomp_uncompress:function(e,t){var r=new Array;s.decode(e,r).copy(t,0,0)},tok3_uncompress:function(e,t){var r=a.decode(e,0,"\0");Buffer.from(r,"binary").copy(t,0,0)}}},8706:e=>{e.exports=class{constructor(e,t=0,r=0){0!=r?(this.buf=Buffer.allocUnsafe(r),this.length=r):(this.buf=e,this.length=e.length),this.pos=t}EOF(){return this.pos>=this.length}ReadData(e){var t=this.buf.slice(this.pos,this.pos+e);return this.pos+=e,t}ReadByte(){const e=this.buf[this.pos];return this.pos++,e}ReadChar(){const e=this.buf[this.pos];return this.pos++,String.fromCharCode(e)}ReadUint16(){return this.ReadByte()|this.ReadByte()<<8}ReadUint32(){const e=this.buf.readInt32LE(this.pos);return this.pos+=4,e}ReadString(){var e="";do{var t=this.buf[this.pos++];t&&(e+=String.fromCharCode(t))}while(t);return e}ReadUint7(){var e=0;do{var t=this.ReadByte();e=e<<7|127&t}while(128&t);return e}ReadITF8(){var e=this.buf[this.pos];return this.pos++,e>=240?(e=(15&e)<<28,e+=(this.buf[this.pos+0]<<20)+(this.buf[this.pos+1]<<12)+(this.buf[this.pos+2]<<4)+(this.buf[this.pos+3]>>4),this.pos+=4):e>=224?(e=(15&e)<<24,e+=(this.buf[this.pos+0]<<16)+(this.buf[this.pos+1]<<8)+(0|this.buf[this.pos+2]),this.pos+=3):e>=192?(e=(31&e)<<16,e+=(this.buf[this.pos+0]<<8)+(0|this.buf[this.pos+1]),this.pos+=2):e>=128&&(e=(63&e)<<8,e+=this.buf[this.pos],this.pos++),e}WriteByte(e){this.buf[this.pos++]=e}WriteChar(e){this.buf[this.pos++]=e.charCodeAt(0)}WriteString(e){for(var t=0;t<e.length;t++)this.buf[this.pos++]=e.charCodeAt(t);this.buf[this.pos++]=0}WriteData(e,t){for(var r=0;r<t;r++)this.buf[this.pos++]=e[r]}WriteStream(e){this.WriteData(e.buf,e.pos)}WriteUint16(e){this.WriteByte(255&e),this.WriteByte(e>>8&255)}WriteUint32(e){this.buf.writeInt32LE(e,this.pos),this.pos+=4}WriteUint7(e){var t=0,r=e;do{t+=7,r>>=7}while(r>0);do{t-=7,this.WriteByte((e>>t&127)+((t>0)<<7))}while(t>0)}WriteITF8(e){e<0&&(e=1+e),e<=127?this.buf[this.pos++]=e:e<=16383?(this.buf[this.pos++]=128|Math.floor(e/256),this.buf[this.pos++]=255&e):e<131071?(this.buf[this.pos++]=192|Math.floor(e/65536),this.buf[this.pos++]=255&Math.floor(e/256),this.buf[this.pos++]=255&e):e<268435455?(this.buf[this.pos++]=224|Math.floor(e/16777216),this.buf[this.pos++]=255&Math.floor(e/65536),this.buf[this.pos++]=255&Math.floor(e/256),this.buf[this.pos++]=255&e):(this.buf[this.pos++]=240|Math.floor(e/268435456),this.buf[this.pos++]=255&Math.floor(e/1048576),this.buf[this.pos++]=255&Math.floor(e/4096),this.buf[this.pos++]=255&Math.floor(e/4),this.buf[this.pos++]=15&e)}WriteByteNeg(e){this.buf[--this.pos]=e}}},5460:(e,t,r)=>{const n=r(8706);function i(e){return 4095&e}function o(e,t){for(var r=0;t>=e[r+1];)r++;return r}function s(e){for(var t=new Array(4096),r=0,n=0;n<4096;n++){for(;n>=e[r+1];)r++;t[n]=r}return t}function a(e,t,r){return r*(e>>12)+(4095&e)-t}function A(e,t){for(;t<1<<23;)t=(t<<8)+e.ReadByte();return t}function f(e,t){t.WriteByteNeg(e>>24&255),t.WriteByteNeg(e>>16&255),t.WriteByteNeg(e>>8&255),t.WriteByteNeg(255&e)}function h(e,t,r,n,i){return e=function(e,t,r,n){for(var i=(1<<23>>n<<8)*r;e>=i;)t.WriteByteNeg(255&e),e>>=8;return e}(e,t,n,i),(Math.floor(e/n)<<i)+e%n+r}function u(e,t,r){for(var n=0;n<256;n++)t[n]=0;var i=e.ReadByte(),o=i,s=0;do{var a=e.ReadITF8();t[i]=a,s>0?(s--,i++):(i=e.ReadByte())==o+1&&(s=e.ReadByte()),o=i}while(0!=i);for(r[0]=0,n=0;n<=255;n++)r[n+1]=r[n]+t[n]}function l(e){for(var t=0,r=0;r<256;r++)t+=e[r];const n=4096;var i=n/t;do{var o=0,s=0,a=0;for(t=0,r=0;r<256;r++)0!=e[r]&&(o<e[r]&&(o=e[r],s=r),e[r]=Math.floor(e[r]*i),0==e[r]&&(e[r]=1),t+=e[r]);t<n?e[s]+=n-t:t-n<e[s]/2&&e[s]>2?e[s]-=t-n:t!=n&&(i*=.99,a=1)}while(a)}function c(e,t){for(var r=0,n=0;n<256;n++)if(t[n]){if(r>0)r--;else if(e.WriteByte(n),n>0&&t[n-1]>0){for(r=n+1;r<256&&t[r];r++);r-=n+1,e.WriteByte(r)}e.WriteITF8(t[n])}e.WriteByte(0)}e.exports={decode:function(e){var t=new n(e),r=t.ReadByte(),f=(t.ReadUint32(),t.ReadUint32());return 0==r?function(e,t){var r=new Array(256),n=new Array(256);u(e,r,n);for(var o=s(n),f=new Array(4),h=0;h<4;h++)f[h]=e.ReadUint32();var l=new Buffer.allocUnsafe(t);for(h=0;h<t;h++){var c=h%4,d=o[i(f[c])];l[h]=d,f[c]=a(f[c],n[d],r[d]),f[c]=A(e,f[c])}return l}(t,f):function(e,t){var r=new Array(256),n=new Array(256);!function(e,t,r){for(var n=0;n<256;n++){t[n]=new Array(256),r[n]=new Array(256);for(var i=0;i<256;i++)t[n][i]=0}var o=e.ReadByte(),s=o,a=0;do{u(e,t[o],r[o]),a>0?(a--,o++):(o=e.ReadByte())==s+1&&(a=e.ReadByte()),s=o}while(0!=o)}(e,r,n);for(var f=new Array(256),h=0;h<256;h++)f[h]=s(n[h]);for(var l=new Array(4),c=new Array(4),d=0;d<4;d++)l[d]=e.ReadUint32(),c[d]=0;var g=new Buffer.allocUnsafe(t),p=Math.floor(t/4);for(h=0;h<p;h++)for(d=0;d<4;d++){var C=i(l[d]),I=f[c[d]][C];g[h+d*p]=I,l[d]=a(l[d],n[c[d]][I],r[c[d]][I]),l[d]=A(e,l[d]),c[d]=I}for(h*=4;h<t;)C=i(l[3]),I=o(n[c[3]],C),g[h++]=I,l[3]=a(l[3],n[c[3]][I],r[c[3]][I]),l[3]=A(e,l[3]),c[3]=I;return g}(t,f)},encode:function(e,t){return 0==t?function(e){const t=e.length;var r=new n("",0,780);r.WriteByte(0),r.WriteUint32(0),r.WriteUint32(0);var i=new Array(256);(function(e,t){for(var r=0;r<256;r++)t[r]=0;for(r=0;r<e.length;r++)t[e[r]]++})(e,i),l(i),c(r,i);var o=new Array(256);o[0]=0;for(var s=1;s<256;s++)o[s]=o[s-1]+i[s-1];var a=new Array(4);for(s=0;s<4;s++)a[s]=1<<23;var A=Math.floor(1.05*t+100),u=new n("",A,A);for(s=t-1;s>=0;s--)a[s%4]=h(a[s%4],u,o[e[s]],i[e[s]],12);for(s=3;s>=0;s--)f(a[s],u);var d=r.pos;return r.buf.writeInt32LE(d-9+(u.length-u.pos),1),r.buf.writeInt32LE(t,5),Buffer.concat([r.buf.slice(0,r.pos),u.buf.slice(u.pos,u.length)],r.pos+u.length-u.pos)}(e):function(e){const t=e.length;var r=new n("",0,198156);r.WriteByte(1),r.WriteUint32(0),r.WriteUint32(0);for(var i=new Array(256),o=new Array(256),s=new Array(256),a=0;a<256;a++)o[a]=new Array(256),s[a]=new Array(256);for(function(e,t,r){for(var n=0;n<256;n++){r[n]=0;for(var i=0;i<256;i++)t[n][i]=0}var o=0;for(n=0;n<e.length;n++)r[e[n]]++,t[o][e[n]]++,o=e[n];t[0][e[1*(e.length>>2)]]++,t[0][e[2*(e.length>>2)]]++,t[0][e[3*(e.length>>2)]]++,r[0]+=3}(e,o,i),function(e,t){for(var r=0;r<256;r++)t[r]&&l(e[r])}(o,i),function(e,t,r){for(var n=0,i=0;i<256;i++)if(r[i]){if(n>0)n--;else if(e.WriteByte(i),i>0&&r[i-1]>0){for(n=i+1;n<256&&r[n];n++);n-=i+1,e.WriteByte(n)}c(e,t[i])}e.WriteByte(0)}(r,o,i),a=0;a<256;a++)if(i[a]){s[a][0]=0;for(var A=1;A<256;A++)s[a][A]=s[a][A-1]+o[a][A-1]}var u=new Array(4),d=new Array(4);for(A=0;A<4;A++)u[A]=1<<23,d[A]=0;var g=new n("",t,t),p=Math.floor(t/4),C=new Array(4),I=new Array(4);for(A=0;A<4;A++)C[A]=(A+1)*p-2,I[A]=e[C[A]+1];for(I[3]=e[t-1],a=t-2;a>4*p-2;a--)u[3]=h(u[3],g,s[e[a]][I[3]],o[e[a]][I[3]],12),I[3]=e[a];for(;C[0]>=0;)for(A=3;A>=0;A--){var m=e[C[A]];u[A]=h(u[A],g,s[m][I[A]],o[m][I[A]],12),I[A]=m,C[A]--}for(A=3;A>=0;A--)u[A]=h(u[A],g,s[0][I[A]],o[0][I[A]],12);for(a=3;a>=0;a--)f(u[a],g);var y=r.pos;return r.buf.writeInt32LE(y-9+(g.length-g.pos),1),r.buf.writeInt32LE(t,5),Buffer.concat([r.buf.slice(0,r.pos),g.buf.slice(g.pos,g.length)],r.pos+g.length-g.pos)}(e)}}},8223:(e,t,r)=>{const n=r(8706);function i(e,t){return e&(1<<t)-1}function o(e,t){for(var r=0;t>=e[r+1];)r++;return r}function s(e,t){for(var r=1<<t,n=new Array(r),i=0,o=0;o<r;o++){for(;o>=e[i+1];)i++;n[o]=i}return n}function a(e,t,r,n){return r*(e>>n)+(e&(1<<n)-1)-t}function A(e,t){return t<32768&&(t=(t<<16)+e.ReadUint16()),t}function f(e,t){t.WriteByteNeg(e>>24&255),t.WriteByteNeg(e>>16&255),t.WriteByteNeg(e>>8&255),t.WriteByteNeg(255&e)}function h(e,t,r,n,i){return e=function(e,t,r,n){for(var i=(1<<31-n)*r;e>=i;)t.WriteByteNeg(e>>8&255),t.WriteByteNeg(255&e),e>>=16;return e}(e,t,n,i),(Math.floor(e/n)<<i)+e%n+r}function u(e,t,r){0==r&&(r=4);for(var i=new Array(r),o=new Array(r),s=0;s<r;s++)o[s]=Math.floor(t.length/r)+(t.length%r>s),i[s]=new Array(o[s]);for(var a=0,A=0;A<t.length;A+=r,a++)for(var f=0;f<r;f++)a<i[f].length&&(i[f][a]=t[A+f]);var h=new Array(r),u=0;for(s=0;s<r;s++){var l=c(i[s],0),d=c(i[s],1);h[s]=d.length<l.length?d:l,u+=h[s].length}var g=new n("",0,u+5*r+1);for(g.WriteByte(r),s=0;s<r;s++)g.WriteUint7(h[s].length);for(s=0;s<r;s++)g.WriteData(h[s],h[s].length);return g.buf.slice(0,g.buf.pos)}function l(e,t){var r=e.ReadByte(),f=1&r,h=8&r,u=32&r,c=64&r,p=128&r;if(16&r||(t=e.ReadUint7()),h)return function(e,t){for(var r=e.ReadByte(),n=new Array(r),i=new Array(r),o=0;o<r;o++)n[o]=e.ReadUint7();var s=new Array(r);for(o=0;o<r;o++)i[o]=Math.floor(t/r)+(t%r>o),s[o]=l(e,i[o]);var a=new Buffer.allocUnsafe(t);for(o=0;o<r;o++)for(var A=0;A<i[o];A++)a[A*r+o]=s[o][A];return a}(e,t);if(p)var I=t,[m,y,t]=function(e){for(var t=e.ReadByte(),r=new Array(t),n=0;n<t;n++)r[n]=e.ReadByte();return[r,t,e.ReadUint7()]}(e);if(c)var w=t,[B,E,t]=function(e){var t=e.ReadUint7(),r=e.ReadUint7();if(1&t)var i=e.ReadData((t-1)/2);else{var o=e.ReadUint7();i=e.ReadData(o),i=g(new n(i),t/2)}i=new n(i);var s=new Array(256),a=i.ReadByte();0==a&&(a=256);for(var A=0;A<a;A++)s[i.ReadByte()]=1;return[s,i,r]}(e);if(u)var b=e.ReadData(t);else b=0==f?g(e,t):function(e,t){var r=(l=e.ReadByte())>>4,f=e;if(1&l){var h=e.ReadUint7(),u=e.ReadUint7(),l=new n(e.ReadData(u));f=new n(g(l,h))}var c=new Array(256),p=new Array(256);!function(e,t,r,n){for(var i=0;i<256;i++){t[i]=new Array(256),r[i]=new Array(256);for(var o=0;o<256;o++)t[i][o]=0}var s=d(e);for(i=0;i<256;i++)if(s[i]){var a=0;for(o=0;o<256;o++)s[o]&&(a>0?a--:(t[i][o]=e.ReadUint7(),0==t[i][o]&&(a=e.ReadByte())));for(C(t[i],n),r[i][0]=0,o=0;o<256;o++)r[i][o+1]=r[i][o]+t[i][o]}}(f,c,p,r);for(var I=new Array(256),m=0;m<256;m++)I[m]=s(p[m],r);for(var y=new Array(4),w=new Array(4),B=0;B<4;B++)y[B]=e.ReadUint32(),w[B]=0;var E=new Buffer.allocUnsafe(t),b=Math.floor(t/4);for(m=0;m<b;m++)for(B=0;B<4;B++){var _=i(y[B],r),v=I[w[B]][_];E[m+B*b]=v,y[B]=a(y[B],p[w[B]][v],c[w[B]][v],r),y[B]=A(e,y[B]),w[B]=v}for(m*=4;m<t;)_=i(y[3],r),v=o(p[w[3]],_),E[m++]=v,y[3]=a(y[3],p[w[3]][v],c[w[3]][v],r),y[3]=A(e,y[3]),w[3]=v;return E}(e,t);return c&&(b=function(e,t,r,i){new n(e);for(var o=new Buffer.allocUnsafe(i),s=0,a=0;s<i;a++){var A=e[a];if(t[A])for(var f=r.ReadUint7(),h=0;h<=f;h++)o[s++]=A;else o[s++]=A}return o}(b,B,E,w)),p&&(b=function(e,t,r,n){var i=new Buffer.allocUnsafe(n),o=0;if(r<=1)for(var s=0;s<n;s++)i[s]=t[0];else if(r<=2)for(s=0;s<n;s++){if(s%8==0)var a=e[o++];i[s]=t[1&a],a>>=1}else if(r<=4)for(s=0;s<n;s++)s%4==0&&(a=e[o++]),i[s]=t[3&a],a>>=2;else if(r<=16)for(s=0;s<n;s++)s%2==0&&(a=e[o++]),i[s]=t[15&a],a>>=4;return i}(b,m,y,I)),b}function c(e,t){var r=new n("",0,10);r.WriteByte(t);var i=1&t,o=8&t,s=32&t,a=64&t,A=128&t,l=t>>8;if(16&t||r.WriteUint7(e.length),o)return Buffer.concat([r.buf.slice(0,r.pos),u(0,e,l)]);var c=new Buffer.alloc(0);A&&([c,e]=function(e){for(var t=new Array(256),r=0;r<256;r++)t[r]=0;for(r=0;r<e.length;r++)t[e[r]]++;var i=new Array(256),o=0;for(r=0;r<256;r++)t[r]>0&&(i[r]=o++);if(!(o>16)){if(o<=1)var s=new Buffer.allocUnsafe(0);else if(o<=2){s=new Buffer.allocUnsafe(Math.ceil(e.length/8));var a=-1;for(r=0;r<e.length;r++)r%8==0&&(s[++a]=0),s[a]+=i[e[r]]<<r%8}else if(o<=4)for(s=new Buffer.allocUnsafe(Math.ceil(e.length/4)),a=-1,r=0;r<e.length;r++)r%4==0&&(s[++a]=0),s[a]+=i[e[r]]<<r%4*2;else for(s=new Buffer.allocUnsafe(Math.ceil(e.length/2)),a=-1,r=0;r<e.length;r++)r%2==0&&(s[++a]=0),s[a]+=i[e[r]]<<r%2*4;var A=new n("",0,o+5);for(A.WriteByte(o),a=0,r=0;r<256;r++)t[r]>0&&(t[r]=a++,A.WriteByte(r));return A.WriteUint7(s.length),[A.buf.slice(0,A.pos),s]}}(e));var d=new Buffer.alloc(0);if(a&&([d,e]=function(e){for(var t=new Array(256),r=0;r<256;r++)t[r]=0;var i=-1;for(r=0;r<e.length;r++)t[e[r]]+=e[r]==i?1:-1,i=e[r];var o=0;for(r=0;r<256;r++)t[r]>0&&o++;for(o||(o=1,t[0]=1),(f=new n("",0,o+1+e.length)).WriteByte(o),r=0;r<256;r++)t[r]>0&&f.WriteByte(r);var s=new Buffer.allocUnsafe(e.length),a=0;for(r=0;r<e.length;r++)if(s[a++]=e[r],t[e[r]]>0){i=e[r];for(var A=0;r+A+1<e.length&&e[r+A+1]==i;)A++;f.WriteUint7(A),r+=A}var f,h=m(f.buf.slice(0,f.pos)),u=new n("",0,16);return u.WriteUint7(2*f.pos),u.WriteUint7(a),u.WriteUint7(h.length),[f=Buffer.concat([u.buf.slice(0,u.pos),h]),s.slice(0,a)]}(e)),e.length<4&&1==i&&(i=0,r.buf[0]&=-2),s)var g=e;else g=0==i?m(e):function(e){const t=e.length;for(var r=new n("",0,198156),i=new Array(256),o=new Array(256),s=new Array(256),a=0;a<256;a++)o[a]=new Array(256),s[a]=new Array(256);var A=12;(function(e,t,r){for(var n=0;n<256;n++){r[n]=0;for(var i=0;i<256;i++)t[n][i]=0}var o=0;for(n=0;n<e.length;n++)r[o]++,t[o][e[n]]++,o=e[n];r[o]++,t[0][e[1*(e.length>>2)]]++,t[0][e[2*(e.length>>2)]]++,t[0][e[3*(e.length>>2)]]++,r[0]+=3})(e,o,i),function(e,t){for(var r=0;r<256;r++)if(t[r]){var n=Math.ceil(Math.log2(t[r]));n>12&&(n=12),p(e[r],n)}}(o,i);var u=new n("",0,198156);!function(e,t,r){I(e,r);for(var n=0;n<256;n++)if(r[n])for(var i=0,o=0;o<256;o++)if(r[o])if(i)i--;else if(e.WriteUint7(t[n][o]),!t[n][o]){for(var s=o+1;s<256;s++)if(r[s]){if(0!=t[n][s])break;i++}e.WriteByte(i)}}(u,o,i);var l=m(u.buf.slice(0,u.pos));for(l.length<u.pos?(r.WriteByte(193),r.WriteUint7(u.pos),r.WriteUint7(l.length),r.WriteData(l,l.length)):(r.WriteByte(192),r.WriteData(u.buf,u.pos)),function(e,t){for(var r=0;r<256;r++)t[r]&&C(e[r],12)}(o,i),a=0;a<256;a++)if(i[a]){s[a][0]=0;for(var c=1;c<256;c++)s[a][c]=s[a][c-1]+o[a][c-1]}var d=new Array(4),g=new Array(4);for(c=0;c<4;c++)d[c]=32768,g[c]=0;var y=new n("",1.05*t+100|0,1.05*t+100|0),w=Math.floor(t/4),B=new Array(4),E=new Array(4);for(c=0;c<4;c++)B[c]=(c+1)*w-2,E[c]=e[B[c]+1];for(E[3]=e[t-1],a=t-2;a>4*w-2;a--)d[3]=h(d[3],y,s[e[a]][E[3]],o[e[a]][E[3]],A),E[3]=e[a];for(;B[0]>=0;)for(c=3;c>=0;c--){var b=e[B[c]];d[c]=h(d[c],y,s[b][E[c]],o[b][E[c]],A),E[c]=b,B[c]--}for(c=3;c>=0;c--)d[c]=h(d[c],y,s[0][E[c]],o[0][E[c]],A);for(a=3;a>=0;a--)f(d[a],y);return Buffer.concat([r.buf.slice(0,r.pos),y.buf.slice(y.pos,y.length)],r.pos+y.length-y.pos)}(e);return Buffer.concat([r.buf.slice(0,r.pos),c,d,g])}function d(e){for(var t=new Array(256),r=0;r<256;r++)t[r]=0;var n=0,i=e.ReadByte(),o=i;do{t[i]=1,n>0?(n--,i++):(i=e.ReadByte())==o+1&&(n=e.ReadByte()),o=i}while(0!=i);return t}function g(e,t){var r=new Array(256),n=new Array(256);!function(e,t,r){for(var n=0;n<256;n++)t[n]=0;var i=d(e);for(n=0;n<256;n++)i[n]>0&&(t[n]=e.ReadUint7());for(C(t,12),r[0]=0,n=0;n<=255;n++)r[n+1]=r[n]+t[n]}(e,r,n);for(var o=s(n,12),f=new Array(4),h=0;h<4;h++)f[h]=e.ReadUint32();var u=new Buffer.allocUnsafe(t);for(h=0;h<t;h++){var l=h%4,c=o[i(f[l],12)];u[h]=c,f[l]=a(f[l],n[c],r[c],12),f[l]=A(e,f[l])}return u}function p(e,t){for(var r=0,n=0;n<256;n++)r+=e[n];const i=1<<t;var o=i/r;do{var s=0,a=0,A=0;for(r=0,n=0;n<256;n++)0!=e[n]&&(s<e[n]&&(s=e[n],a=n),e[n]=Math.floor(e[n]*o),0==e[n]&&(e[n]=1),r+=e[n]);r<i?e[a]+=i-r:r-i<e[a]/2&&e[a]>2?e[a]-=r-i:r!=i&&(o=i/r,A=1)}while(A)}function C(e,t){for(var r=0,n=0;n<256;n++)r+=e[n];if(0!=r&&r!=1<<t){for(var i=0;r<1<<t;)r*=2,i++;for(n=0;n<256;n++)e[n]<<=i}}function I(e,t){for(var r=0,n=0;n<256;n++)if(t[n])if(r>0)r--;else if(e.WriteByte(n),n>0&&t[n-1]>0){for(r=n+1;r<256&&t[r];r++);r-=n+1,e.WriteByte(r)}e.WriteByte(0)}function m(e){const t=e.length;var r=new n("",0,780),i=new Array(256);!function(e,t){for(var r=0;r<256;r++)t[r]=0;for(r=0;r<e.length;r++)t[e[r]]++}(e,i);var o=Math.ceil(Math.log2(t));o>12&&(o=12),p(i,o),function(e,t){I(e,t);for(var r=0;r<256;r++)t[r]&&e.WriteUint7(t[r])}(r,i),p(i,12);var s=new Array(256);s[0]=0;for(var a=1;a<256;a++)s[a]=s[a-1]+i[a-1];var A=new Array(4);for(a=0;a<4;a++)A[a]=32768;var u=new n("",1.05*t+100|0,1.05*t+100|0);for(a=t-1;a>=0;a--)A[a%4]=h(A[a%4],u,s[e[a]],i[e[a]],12);for(a=3;a>=0;a--)f(A[a],u);return Buffer.concat([r.buf.slice(0,r.pos),u.buf.slice(u.pos,u.length)],r.pos+u.length-u.pos)}e.exports={decode:function(e){return l(new n(e),0)},encode:c}},5997:(e,t,r)=>{const n=r(8706),i=r(8223);var o=new(r(635));function s(e,t){for(var r=e+"";r.length<t;)r="0"+r;return r}function a(e,t,r,n){var i=e[0][0].ReadByte(),o=n-e[0][i].ReadUint32();if(5==i)return t[n]=t[o],r[n]=r[o],t[n];var a=1;t[n]="",r[n]=new Array(256);do{switch(i=e[a][0].ReadByte()){case 2:r[n][a]=e[a][2].ReadChar();break;case 1:r[n][a]=e[a][1].ReadString();break;case 7:r[n][a]=e[a][7].ReadUint32();break;case 3:var A=e[a][3].ReadUint32(),f=e[a][4].ReadByte();r[n][a]=s(A,f);break;case 8:r[n][a]=(0|r[o][a])+e[a][8].ReadByte();break;case 9:A=(0|r[o][a])+e[a][9].ReadByte(),f=r[o][a].length,r[n][a]=s(A,f);break;case 10:r[n][a]=r[o][a];break;default:r[n][a]=""}t[n]+=r[n][a++]}while(12!=i);return t[n]}function A(e,t,r,n,i,o){for(var s=0;s<n.length;s++)if(!(r>0&&5==t[s][0].type)&&t[s][r])switch(e[0].WriteByte(t[s][r].type),t[s][r].type){case 6:e[6].WriteUint32(t[s][r].val);break;case 5:e[5].WriteUint32(t[s][r].val);break;case 1:e[1].WriteString(t[s][r].val);break;case 2:e[2].WriteChar(t[s][r].val);break;case 7:e[7].WriteUint32(t[s][r].val);break;case 3:e[3].WriteUint32(t[s][r].val),e[4].WriteByte(t[s][r].val.length);break;case 8:case 9:e[t[s][r].type].WriteByte(t[s][r].val)}}function f(e,t,r,n){for(var i=0;i<=12;i++)if(!(e[i].pos<=0)){n.WriteByte(i+(0==i?128:0)),e[i]=e[i].buf.slice(0,e[i].pos);var o=h(e[i],r);n.WriteUint7(o.length),n.WriteData(o,o.length)}}function h(e,t){var r,n=1<<30,s=[0,1,64,65,128,129,201];for(var a in s){var A=s[a];if(!(1&A&&e.length<100||8&A&&e.length%4!=0)){try{var f=t?o.encode(e,A):i.encode(e,A)}catch(e){f=0}f&&n>f.length&&(n=f.length,r=f)}}return r}function u(e,t,r,n,i){var o=0,s=i-1;e[i]=new Array(256),t[n]?e[i][0]={type:5,val:i-t[n]}:e[i][0]={type:6,val:0==i?0:1},t[n]=i;for(var a=n.match(/([a-zA-Z0-9]{1,9})|([^a-zA-Z0-9]+)/g),A=0;A<a.length;A++){var f=A+1,h=1,u=a[A];if(a[A].match(/^0+[0-9]*$/g)?h=3:a[A].match(/^[0-9]+$/g)?h=7:1==a[A].length&&(h=2),s>=0&&e[s][f])if(e[s][f].str==a[A])h=10,u="";else if(7==e[s][f].type||8==e[s][f].type){var l=u-e[s][f].str;r[f]++,l>=0&&l<256&&r[f]>i/2&&(h=8,u=l)}else 3!=e[s][f].type&&9!=e[s][f].type||e[s][f].str.length!=u.length||(l=u-e[s][f].str,r[f]++,l>=0&&l<256&&r[f]>i/2&&(h=9,u=l));e[i][f]={str:a[A],val:u,type:h},o<e[i][f].val.length+3&&(o=e[i][f].val.length+3)}return e[i][++f]={type:12},[f+1,o]}e.exports={encode:function(e,t){var r=e.toString();"\n"==r[r.length-1]&&(r=r.substring(0,r.length-1));var i=r.split("\n"),o=new n("",0,2*r.length+1e4);o.WriteUint32(r.length),o.WriteUint32(i.length),o.WriteByte(t);for(var s=new Array(i.length),a={},h=new Array(256).fill(0),l=0,c=0,d=0;d<i.length;d++){var[g,p]=u(s,a,h,i[d],d);l<g&&(l=g),c<p&&(c=p)}for(var C=0;C<l;C++){for(var I=new Array(13),m=0;m<=12;m++)I[m]=new n("",0,i.length*c);A(I,s,C,i),f(I,0,t,o)}return o.buf.slice(0,o.pos)},decode:function(e,t,r){(e=new n(e)).ReadUint32();var s=e.ReadUint32(),A=e.ReadByte(),f=function(e,t,r,s){for(var a=-1,A=new Array(256);!e.EOF();){var f=e.ReadByte(),h=128&f,u=64&f,l=63&f;if(h&&(A[++a]=new Array(13)),0!=l&&h){var c=new Array(s-1).fill(10);A[a][0]=new n(Buffer.from([l].concat(c)))}if(u){var d=e.ReadByte(),g=e.ReadByte();A[a][l]=new n(A[d][g].buf)}else{var p=e.ReadUint7(),C=e.ReadData(p);A[a][l]=r?o.decode(C):i.decode(C),A[a][l]=new n(A[a][l])}}return A}(e,0,A,s),h=new Array(s),u=new Array(s),l="";void 0===r&&(r="\n");for(var c=0;c<s;c++)l+=a(f,h,u,c)+r;return l}}},7526:(e,t)=>{"use strict";t.byteLength=function(e){var t=a(e),r=t[0],n=t[1];return 3*(r+n)/4-n},t.toByteArray=function(e){var t,r,o=a(e),s=o[0],A=o[1],f=new i(function(e,t,r){return 3*(t+r)/4-r}(0,s,A)),h=0,u=A>0?s-4:s;for(r=0;r<u;r+=4)t=n[e.charCodeAt(r)]<<18|n[e.charCodeAt(r+1)]<<12|n[e.charCodeAt(r+2)]<<6|n[e.charCodeAt(r+3)],f[h++]=t>>16&255,f[h++]=t>>8&255,f[h++]=255&t;return 2===A&&(t=n[e.charCodeAt(r)]<<2|n[e.charCodeAt(r+1)]>>4,f[h++]=255&t),1===A&&(t=n[e.charCodeAt(r)]<<10|n[e.charCodeAt(r+1)]<<4|n[e.charCodeAt(r+2)]>>2,f[h++]=t>>8&255,f[h++]=255&t),f},t.fromByteArray=function(e){for(var t,n=e.length,i=n%3,o=[],s=16383,a=0,f=n-i;a<f;a+=s)o.push(A(e,a,a+s>f?f:a+s));return 1===i?(t=e[n-1],o.push(r[t>>2]+r[t<<4&63]+"==")):2===i&&(t=(e[n-2]<<8)+e[n-1],o.push(r[t>>10]+r[t>>4&63]+r[t<<2&63]+"=")),o.join("")};for(var r=[],n=[],i="undefined"!=typeof Uint8Array?Uint8Array:Array,o="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",s=0;s<64;++s)r[s]=o[s],n[o.charCodeAt(s)]=s;function a(e){var t=e.length;if(t%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var r=e.indexOf("=");return-1===r&&(r=t),[r,r===t?0:4-r%4]}function A(e,t,n){for(var i,o,s=[],a=t;a<n;a+=3)i=(e[a]<<16&16711680)+(e[a+1]<<8&65280)+(255&e[a+2]),s.push(r[(o=i)>>18&63]+r[o>>12&63]+r[o>>6&63]+r[63&o]);return s.join("")}n["-".charCodeAt(0)]=62,n["_".charCodeAt(0)]=63},8287:(e,t,r)=>{"use strict";const n=r(7526),i=r(251),o="function"==typeof Symbol&&"function"==typeof Symbol.for?Symbol.for("nodejs.util.inspect.custom"):null;t.Buffer=A,t.SlowBuffer=function(e){return+e!=e&&(e=0),A.alloc(+e)},t.INSPECT_MAX_BYTES=50;const s=2147483647;function a(e){if(e>s)throw new RangeError('The value "'+e+'" is invalid for option "size"');const t=new Uint8Array(e);return Object.setPrototypeOf(t,A.prototype),t}function A(e,t,r){if("number"==typeof e){if("string"==typeof t)throw new TypeError('The "string" argument must be of type string. Received type number');return u(e)}return f(e,t,r)}function f(e,t,r){if("string"==typeof e)return function(e,t){if("string"==typeof t&&""!==t||(t="utf8"),!A.isEncoding(t))throw new TypeError("Unknown encoding: "+t);const r=0|g(e,t);let n=a(r);const i=n.write(e,t);return i!==r&&(n=n.slice(0,i)),n}(e,t);if(ArrayBuffer.isView(e))return function(e){if(j(e,Uint8Array)){const t=new Uint8Array(e);return c(t.buffer,t.byteOffset,t.byteLength)}return l(e)}(e);if(null==e)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e);if(j(e,ArrayBuffer)||e&&j(e.buffer,ArrayBuffer))return c(e,t,r);if("undefined"!=typeof SharedArrayBuffer&&(j(e,SharedArrayBuffer)||e&&j(e.buffer,SharedArrayBuffer)))return c(e,t,r);if("number"==typeof e)throw new TypeError('The "value" argument must not be of type number. Received type number');const n=e.valueOf&&e.valueOf();if(null!=n&&n!==e)return A.from(n,t,r);const i=function(e){if(A.isBuffer(e)){const t=0|d(e.length),r=a(t);return 0===r.length||e.copy(r,0,0,t),r}return void 0!==e.length?"number"!=typeof e.length||V(e.length)?a(0):l(e):"Buffer"===e.type&&Array.isArray(e.data)?l(e.data):void 0}(e);if(i)return i;if("undefined"!=typeof Symbol&&null!=Symbol.toPrimitive&&"function"==typeof e[Symbol.toPrimitive])return A.from(e[Symbol.toPrimitive]("string"),t,r);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e)}function h(e){if("number"!=typeof e)throw new TypeError('"size" argument must be of type number');if(e<0)throw new RangeError('The value "'+e+'" is invalid for option "size"')}function u(e){return h(e),a(e<0?0:0|d(e))}function l(e){const t=e.length<0?0:0|d(e.length),r=a(t);for(let n=0;n<t;n+=1)r[n]=255&e[n];return r}function c(e,t,r){if(t<0||e.byteLength<t)throw new RangeError('"offset" is outside of buffer bounds');if(e.byteLength<t+(r||0))throw new RangeError('"length" is outside of buffer bounds');let n;return n=void 0===t&&void 0===r?new Uint8Array(e):void 0===r?new Uint8Array(e,t):new Uint8Array(e,t,r),Object.setPrototypeOf(n,A.prototype),n}function d(e){if(e>=s)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+s.toString(16)+" bytes");return 0|e}function g(e,t){if(A.isBuffer(e))return e.length;if(ArrayBuffer.isView(e)||j(e,ArrayBuffer))return e.byteLength;if("string"!=typeof e)throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof e);const r=e.length,n=arguments.length>2&&!0===arguments[2];if(!n&&0===r)return 0;let i=!1;for(;;)switch(t){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":return Y(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return W(e).length;default:if(i)return n?-1:Y(e).length;t=(""+t).toLowerCase(),i=!0}}function p(e,t,r){let n=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===r||r>this.length)&&(r=this.length),r<=0)return"";if((r>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return D(this,t,r);case"utf8":case"utf-8":return v(this,t,r);case"ascii":return S(this,t,r);case"latin1":case"binary":return k(this,t,r);case"base64":return _(this,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return R(this,t,r);default:if(n)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),n=!0}}function C(e,t,r){const n=e[t];e[t]=e[r],e[r]=n}function I(e,t,r,n,i){if(0===e.length)return-1;if("string"==typeof r?(n=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),V(r=+r)&&(r=i?0:e.length-1),r<0&&(r=e.length+r),r>=e.length){if(i)return-1;r=e.length-1}else if(r<0){if(!i)return-1;r=0}if("string"==typeof t&&(t=A.from(t,n)),A.isBuffer(t))return 0===t.length?-1:m(e,t,r,n,i);if("number"==typeof t)return t&=255,"function"==typeof Uint8Array.prototype.indexOf?i?Uint8Array.prototype.indexOf.call(e,t,r):Uint8Array.prototype.lastIndexOf.call(e,t,r):m(e,[t],r,n,i);throw new TypeError("val must be string, number or Buffer")}function m(e,t,r,n,i){let o,s=1,a=e.length,A=t.length;if(void 0!==n&&("ucs2"===(n=String(n).toLowerCase())||"ucs-2"===n||"utf16le"===n||"utf-16le"===n)){if(e.length<2||t.length<2)return-1;s=2,a/=2,A/=2,r/=2}function f(e,t){return 1===s?e[t]:e.readUInt16BE(t*s)}if(i){let n=-1;for(o=r;o<a;o++)if(f(e,o)===f(t,-1===n?0:o-n)){if(-1===n&&(n=o),o-n+1===A)return n*s}else-1!==n&&(o-=o-n),n=-1}else for(r+A>a&&(r=a-A),o=r;o>=0;o--){let r=!0;for(let n=0;n<A;n++)if(f(e,o+n)!==f(t,n)){r=!1;break}if(r)return o}return-1}function y(e,t,r,n){r=Number(r)||0;const i=e.length-r;n?(n=Number(n))>i&&(n=i):n=i;const o=t.length;let s;for(n>o/2&&(n=o/2),s=0;s<n;++s){const n=parseInt(t.substr(2*s,2),16);if(V(n))return s;e[r+s]=n}return s}function w(e,t,r,n){return K(Y(t,e.length-r),e,r,n)}function B(e,t,r,n){return K(function(e){const t=[];for(let r=0;r<e.length;++r)t.push(255&e.charCodeAt(r));return t}(t),e,r,n)}function E(e,t,r,n){return K(W(t),e,r,n)}function b(e,t,r,n){return K(function(e,t){let r,n,i;const o=[];for(let s=0;s<e.length&&!((t-=2)<0);++s)r=e.charCodeAt(s),n=r>>8,i=r%256,o.push(i),o.push(n);return o}(t,e.length-r),e,r,n)}function _(e,t,r){return 0===t&&r===e.length?n.fromByteArray(e):n.fromByteArray(e.slice(t,r))}function v(e,t,r){r=Math.min(e.length,r);const n=[];let i=t;for(;i<r;){const t=e[i];let o=null,s=t>239?4:t>223?3:t>191?2:1;if(i+s<=r){let r,n,a,A;switch(s){case 1:t<128&&(o=t);break;case 2:r=e[i+1],128==(192&r)&&(A=(31&t)<<6|63&r,A>127&&(o=A));break;case 3:r=e[i+1],n=e[i+2],128==(192&r)&&128==(192&n)&&(A=(15&t)<<12|(63&r)<<6|63&n,A>2047&&(A<55296||A>57343)&&(o=A));break;case 4:r=e[i+1],n=e[i+2],a=e[i+3],128==(192&r)&&128==(192&n)&&128==(192&a)&&(A=(15&t)<<18|(63&r)<<12|(63&n)<<6|63&a,A>65535&&A<1114112&&(o=A))}}null===o?(o=65533,s=1):o>65535&&(o-=65536,n.push(o>>>10&1023|55296),o=56320|1023&o),n.push(o),i+=s}return function(e){const t=e.length;if(t<=Q)return String.fromCharCode.apply(String,e);let r="",n=0;for(;n<t;)r+=String.fromCharCode.apply(String,e.slice(n,n+=Q));return r}(n)}t.kMaxLength=s,A.TYPED_ARRAY_SUPPORT=function(){try{const e=new Uint8Array(1),t={foo:function(){return 42}};return Object.setPrototypeOf(t,Uint8Array.prototype),Object.setPrototypeOf(e,t),42===e.foo()}catch(e){return!1}}(),A.TYPED_ARRAY_SUPPORT||"undefined"==typeof console||"function"!=typeof console.error||console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support."),Object.defineProperty(A.prototype,"parent",{enumerable:!0,get:function(){if(A.isBuffer(this))return this.buffer}}),Object.defineProperty(A.prototype,"offset",{enumerable:!0,get:function(){if(A.isBuffer(this))return this.byteOffset}}),A.poolSize=8192,A.from=function(e,t,r){return f(e,t,r)},Object.setPrototypeOf(A.prototype,Uint8Array.prototype),Object.setPrototypeOf(A,Uint8Array),A.alloc=function(e,t,r){return function(e,t,r){return h(e),e<=0?a(e):void 0!==t?"string"==typeof r?a(e).fill(t,r):a(e).fill(t):a(e)}(e,t,r)},A.allocUnsafe=function(e){return u(e)},A.allocUnsafeSlow=function(e){return u(e)},A.isBuffer=function(e){return null!=e&&!0===e._isBuffer&&e!==A.prototype},A.compare=function(e,t){if(j(e,Uint8Array)&&(e=A.from(e,e.offset,e.byteLength)),j(t,Uint8Array)&&(t=A.from(t,t.offset,t.byteLength)),!A.isBuffer(e)||!A.isBuffer(t))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(e===t)return 0;let r=e.length,n=t.length;for(let i=0,o=Math.min(r,n);i<o;++i)if(e[i]!==t[i]){r=e[i],n=t[i];break}return r<n?-1:n<r?1:0},A.isEncoding=function(e){switch(String(e).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},A.concat=function(e,t){if(!Array.isArray(e))throw new TypeError('"list" argument must be an Array of Buffers');if(0===e.length)return A.alloc(0);let r;if(void 0===t)for(t=0,r=0;r<e.length;++r)t+=e[r].length;const n=A.allocUnsafe(t);let i=0;for(r=0;r<e.length;++r){let t=e[r];if(j(t,Uint8Array))i+t.length>n.length?(A.isBuffer(t)||(t=A.from(t)),t.copy(n,i)):Uint8Array.prototype.set.call(n,t,i);else{if(!A.isBuffer(t))throw new TypeError('"list" argument must be an Array of Buffers');t.copy(n,i)}i+=t.length}return n},A.byteLength=g,A.prototype._isBuffer=!0,A.prototype.swap16=function(){const e=this.length;if(e%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let t=0;t<e;t+=2)C(this,t,t+1);return this},A.prototype.swap32=function(){const e=this.length;if(e%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(let t=0;t<e;t+=4)C(this,t,t+3),C(this,t+1,t+2);return this},A.prototype.swap64=function(){const e=this.length;if(e%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(let t=0;t<e;t+=8)C(this,t,t+7),C(this,t+1,t+6),C(this,t+2,t+5),C(this,t+3,t+4);return this},A.prototype.toString=function(){const e=this.length;return 0===e?"":0===arguments.length?v(this,0,e):p.apply(this,arguments)},A.prototype.toLocaleString=A.prototype.toString,A.prototype.equals=function(e){if(!A.isBuffer(e))throw new TypeError("Argument must be a Buffer");return this===e||0===A.compare(this,e)},A.prototype.inspect=function(){let e="";const r=t.INSPECT_MAX_BYTES;return e=this.toString("hex",0,r).replace(/(.{2})/g,"$1 ").trim(),this.length>r&&(e+=" ... "),"<Buffer "+e+">"},o&&(A.prototype[o]=A.prototype.inspect),A.prototype.compare=function(e,t,r,n,i){if(j(e,Uint8Array)&&(e=A.from(e,e.offset,e.byteLength)),!A.isBuffer(e))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof e);if(void 0===t&&(t=0),void 0===r&&(r=e?e.length:0),void 0===n&&(n=0),void 0===i&&(i=this.length),t<0||r>e.length||n<0||i>this.length)throw new RangeError("out of range index");if(n>=i&&t>=r)return 0;if(n>=i)return-1;if(t>=r)return 1;if(this===e)return 0;let o=(i>>>=0)-(n>>>=0),s=(r>>>=0)-(t>>>=0);const a=Math.min(o,s),f=this.slice(n,i),h=e.slice(t,r);for(let e=0;e<a;++e)if(f[e]!==h[e]){o=f[e],s=h[e];break}return o<s?-1:s<o?1:0},A.prototype.includes=function(e,t,r){return-1!==this.indexOf(e,t,r)},A.prototype.indexOf=function(e,t,r){return I(this,e,t,r,!0)},A.prototype.lastIndexOf=function(e,t,r){return I(this,e,t,r,!1)},A.prototype.write=function(e,t,r,n){if(void 0===t)n="utf8",r=this.length,t=0;else if(void 0===r&&"string"==typeof t)n=t,r=this.length,t=0;else{if(!isFinite(t))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");t>>>=0,isFinite(r)?(r>>>=0,void 0===n&&(n="utf8")):(n=r,r=void 0)}const i=this.length-t;if((void 0===r||r>i)&&(r=i),e.length>0&&(r<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");n||(n="utf8");let o=!1;for(;;)switch(n){case"hex":return y(this,e,t,r);case"utf8":case"utf-8":return w(this,e,t,r);case"ascii":case"latin1":case"binary":return B(this,e,t,r);case"base64":return E(this,e,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return b(this,e,t,r);default:if(o)throw new TypeError("Unknown encoding: "+n);n=(""+n).toLowerCase(),o=!0}},A.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};const Q=4096;function S(e,t,r){let n="";r=Math.min(e.length,r);for(let i=t;i<r;++i)n+=String.fromCharCode(127&e[i]);return n}function k(e,t,r){let n="";r=Math.min(e.length,r);for(let i=t;i<r;++i)n+=String.fromCharCode(e[i]);return n}function D(e,t,r){const n=e.length;(!t||t<0)&&(t=0),(!r||r<0||r>n)&&(r=n);let i="";for(let n=t;n<r;++n)i+=Z[e[n]];return i}function R(e,t,r){const n=e.slice(t,r);let i="";for(let e=0;e<n.length-1;e+=2)i+=String.fromCharCode(n[e]+256*n[e+1]);return i}function N(e,t,r){if(e%1!=0||e<0)throw new RangeError("offset is not uint");if(e+t>r)throw new RangeError("Trying to access beyond buffer length")}function F(e,t,r,n,i,o){if(!A.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>i||t<o)throw new RangeError('"value" argument is out of bounds');if(r+n>e.length)throw new RangeError("Index out of range")}function M(e,t,r,n,i){z(t,n,i,e,r,7);let o=Number(t&BigInt(4294967295));e[r++]=o,o>>=8,e[r++]=o,o>>=8,e[r++]=o,o>>=8,e[r++]=o;let s=Number(t>>BigInt(32)&BigInt(4294967295));return e[r++]=s,s>>=8,e[r++]=s,s>>=8,e[r++]=s,s>>=8,e[r++]=s,r}function x(e,t,r,n,i){z(t,n,i,e,r,7);let o=Number(t&BigInt(4294967295));e[r+7]=o,o>>=8,e[r+6]=o,o>>=8,e[r+5]=o,o>>=8,e[r+4]=o;let s=Number(t>>BigInt(32)&BigInt(4294967295));return e[r+3]=s,s>>=8,e[r+2]=s,s>>=8,e[r+1]=s,s>>=8,e[r]=s,r+8}function L(e,t,r,n,i,o){if(r+n>e.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("Index out of range")}function U(e,t,r,n,o){return t=+t,r>>>=0,o||L(e,0,r,4),i.write(e,t,r,n,23,4),r+4}function q(e,t,r,n,o){return t=+t,r>>>=0,o||L(e,0,r,8),i.write(e,t,r,n,52,8),r+8}A.prototype.slice=function(e,t){const r=this.length;(e=~~e)<0?(e+=r)<0&&(e=0):e>r&&(e=r),(t=void 0===t?r:~~t)<0?(t+=r)<0&&(t=0):t>r&&(t=r),t<e&&(t=e);const n=this.subarray(e,t);return Object.setPrototypeOf(n,A.prototype),n},A.prototype.readUintLE=A.prototype.readUIntLE=function(e,t,r){e>>>=0,t>>>=0,r||N(e,t,this.length);let n=this[e],i=1,o=0;for(;++o<t&&(i*=256);)n+=this[e+o]*i;return n},A.prototype.readUintBE=A.prototype.readUIntBE=function(e,t,r){e>>>=0,t>>>=0,r||N(e,t,this.length);let n=this[e+--t],i=1;for(;t>0&&(i*=256);)n+=this[e+--t]*i;return n},A.prototype.readUint8=A.prototype.readUInt8=function(e,t){return e>>>=0,t||N(e,1,this.length),this[e]},A.prototype.readUint16LE=A.prototype.readUInt16LE=function(e,t){return e>>>=0,t||N(e,2,this.length),this[e]|this[e+1]<<8},A.prototype.readUint16BE=A.prototype.readUInt16BE=function(e,t){return e>>>=0,t||N(e,2,this.length),this[e]<<8|this[e+1]},A.prototype.readUint32LE=A.prototype.readUInt32LE=function(e,t){return e>>>=0,t||N(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},A.prototype.readUint32BE=A.prototype.readUInt32BE=function(e,t){return e>>>=0,t||N(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},A.prototype.readBigUInt64LE=$((function(e){H(e>>>=0,"offset");const t=this[e],r=this[e+7];void 0!==t&&void 0!==r||G(e,this.length-8);const n=t+256*this[++e]+65536*this[++e]+this[++e]*2**24,i=this[++e]+256*this[++e]+65536*this[++e]+r*2**24;return BigInt(n)+(BigInt(i)<<BigInt(32))})),A.prototype.readBigUInt64BE=$((function(e){H(e>>>=0,"offset");const t=this[e],r=this[e+7];void 0!==t&&void 0!==r||G(e,this.length-8);const n=t*2**24+65536*this[++e]+256*this[++e]+this[++e],i=this[++e]*2**24+65536*this[++e]+256*this[++e]+r;return(BigInt(n)<<BigInt(32))+BigInt(i)})),A.prototype.readIntLE=function(e,t,r){e>>>=0,t>>>=0,r||N(e,t,this.length);let n=this[e],i=1,o=0;for(;++o<t&&(i*=256);)n+=this[e+o]*i;return i*=128,n>=i&&(n-=Math.pow(2,8*t)),n},A.prototype.readIntBE=function(e,t,r){e>>>=0,t>>>=0,r||N(e,t,this.length);let n=t,i=1,o=this[e+--n];for(;n>0&&(i*=256);)o+=this[e+--n]*i;return i*=128,o>=i&&(o-=Math.pow(2,8*t)),o},A.prototype.readInt8=function(e,t){return e>>>=0,t||N(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},A.prototype.readInt16LE=function(e,t){e>>>=0,t||N(e,2,this.length);const r=this[e]|this[e+1]<<8;return 32768&r?4294901760|r:r},A.prototype.readInt16BE=function(e,t){e>>>=0,t||N(e,2,this.length);const r=this[e+1]|this[e]<<8;return 32768&r?4294901760|r:r},A.prototype.readInt32LE=function(e,t){return e>>>=0,t||N(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},A.prototype.readInt32BE=function(e,t){return e>>>=0,t||N(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},A.prototype.readBigInt64LE=$((function(e){H(e>>>=0,"offset");const t=this[e],r=this[e+7];void 0!==t&&void 0!==r||G(e,this.length-8);const n=this[e+4]+256*this[e+5]+65536*this[e+6]+(r<<24);return(BigInt(n)<<BigInt(32))+BigInt(t+256*this[++e]+65536*this[++e]+this[++e]*2**24)})),A.prototype.readBigInt64BE=$((function(e){H(e>>>=0,"offset");const t=this[e],r=this[e+7];void 0!==t&&void 0!==r||G(e,this.length-8);const n=(t<<24)+65536*this[++e]+256*this[++e]+this[++e];return(BigInt(n)<<BigInt(32))+BigInt(this[++e]*2**24+65536*this[++e]+256*this[++e]+r)})),A.prototype.readFloatLE=function(e,t){return e>>>=0,t||N(e,4,this.length),i.read(this,e,!0,23,4)},A.prototype.readFloatBE=function(e,t){return e>>>=0,t||N(e,4,this.length),i.read(this,e,!1,23,4)},A.prototype.readDoubleLE=function(e,t){return e>>>=0,t||N(e,8,this.length),i.read(this,e,!0,52,8)},A.prototype.readDoubleBE=function(e,t){return e>>>=0,t||N(e,8,this.length),i.read(this,e,!1,52,8)},A.prototype.writeUintLE=A.prototype.writeUIntLE=function(e,t,r,n){e=+e,t>>>=0,r>>>=0,n||F(this,e,t,r,Math.pow(2,8*r)-1,0);let i=1,o=0;for(this[t]=255&e;++o<r&&(i*=256);)this[t+o]=e/i&255;return t+r},A.prototype.writeUintBE=A.prototype.writeUIntBE=function(e,t,r,n){e=+e,t>>>=0,r>>>=0,n||F(this,e,t,r,Math.pow(2,8*r)-1,0);let i=r-1,o=1;for(this[t+i]=255&e;--i>=0&&(o*=256);)this[t+i]=e/o&255;return t+r},A.prototype.writeUint8=A.prototype.writeUInt8=function(e,t,r){return e=+e,t>>>=0,r||F(this,e,t,1,255,0),this[t]=255&e,t+1},A.prototype.writeUint16LE=A.prototype.writeUInt16LE=function(e,t,r){return e=+e,t>>>=0,r||F(this,e,t,2,65535,0),this[t]=255&e,this[t+1]=e>>>8,t+2},A.prototype.writeUint16BE=A.prototype.writeUInt16BE=function(e,t,r){return e=+e,t>>>=0,r||F(this,e,t,2,65535,0),this[t]=e>>>8,this[t+1]=255&e,t+2},A.prototype.writeUint32LE=A.prototype.writeUInt32LE=function(e,t,r){return e=+e,t>>>=0,r||F(this,e,t,4,4294967295,0),this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e,t+4},A.prototype.writeUint32BE=A.prototype.writeUInt32BE=function(e,t,r){return e=+e,t>>>=0,r||F(this,e,t,4,4294967295,0),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},A.prototype.writeBigUInt64LE=$((function(e,t=0){return M(this,e,t,BigInt(0),BigInt("0xffffffffffffffff"))})),A.prototype.writeBigUInt64BE=$((function(e,t=0){return x(this,e,t,BigInt(0),BigInt("0xffffffffffffffff"))})),A.prototype.writeIntLE=function(e,t,r,n){if(e=+e,t>>>=0,!n){const n=Math.pow(2,8*r-1);F(this,e,t,r,n-1,-n)}let i=0,o=1,s=0;for(this[t]=255&e;++i<r&&(o*=256);)e<0&&0===s&&0!==this[t+i-1]&&(s=1),this[t+i]=(e/o|0)-s&255;return t+r},A.prototype.writeIntBE=function(e,t,r,n){if(e=+e,t>>>=0,!n){const n=Math.pow(2,8*r-1);F(this,e,t,r,n-1,-n)}let i=r-1,o=1,s=0;for(this[t+i]=255&e;--i>=0&&(o*=256);)e<0&&0===s&&0!==this[t+i+1]&&(s=1),this[t+i]=(e/o|0)-s&255;return t+r},A.prototype.writeInt8=function(e,t,r){return e=+e,t>>>=0,r||F(this,e,t,1,127,-128),e<0&&(e=255+e+1),this[t]=255&e,t+1},A.prototype.writeInt16LE=function(e,t,r){return e=+e,t>>>=0,r||F(this,e,t,2,32767,-32768),this[t]=255&e,this[t+1]=e>>>8,t+2},A.prototype.writeInt16BE=function(e,t,r){return e=+e,t>>>=0,r||F(this,e,t,2,32767,-32768),this[t]=e>>>8,this[t+1]=255&e,t+2},A.prototype.writeInt32LE=function(e,t,r){return e=+e,t>>>=0,r||F(this,e,t,4,2147483647,-2147483648),this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24,t+4},A.prototype.writeInt32BE=function(e,t,r){return e=+e,t>>>=0,r||F(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},A.prototype.writeBigInt64LE=$((function(e,t=0){return M(this,e,t,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))})),A.prototype.writeBigInt64BE=$((function(e,t=0){return x(this,e,t,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))})),A.prototype.writeFloatLE=function(e,t,r){return U(this,e,t,!0,r)},A.prototype.writeFloatBE=function(e,t,r){return U(this,e,t,!1,r)},A.prototype.writeDoubleLE=function(e,t,r){return q(this,e,t,!0,r)},A.prototype.writeDoubleBE=function(e,t,r){return q(this,e,t,!1,r)},A.prototype.copy=function(e,t,r,n){if(!A.isBuffer(e))throw new TypeError("argument should be a Buffer");if(r||(r=0),n||0===n||(n=this.length),t>=e.length&&(t=e.length),t||(t=0),n>0&&n<r&&(n=r),n===r)return 0;if(0===e.length||0===this.length)return 0;if(t<0)throw new RangeError("targetStart out of bounds");if(r<0||r>=this.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("sourceEnd out of bounds");n>this.length&&(n=this.length),e.length-t<n-r&&(n=e.length-t+r);const i=n-r;return this===e&&"function"==typeof Uint8Array.prototype.copyWithin?this.copyWithin(t,r,n):Uint8Array.prototype.set.call(e,this.subarray(r,n),t),i},A.prototype.fill=function(e,t,r,n){if("string"==typeof e){if("string"==typeof t?(n=t,t=0,r=this.length):"string"==typeof r&&(n=r,r=this.length),void 0!==n&&"string"!=typeof n)throw new TypeError("encoding must be a string");if("string"==typeof n&&!A.isEncoding(n))throw new TypeError("Unknown encoding: "+n);if(1===e.length){const t=e.charCodeAt(0);("utf8"===n&&t<128||"latin1"===n)&&(e=t)}}else"number"==typeof e?e&=255:"boolean"==typeof e&&(e=Number(e));if(t<0||this.length<t||this.length<r)throw new RangeError("Out of range index");if(r<=t)return this;let i;if(t>>>=0,r=void 0===r?this.length:r>>>0,e||(e=0),"number"==typeof e)for(i=t;i<r;++i)this[i]=e;else{const o=A.isBuffer(e)?e:A.from(e,n),s=o.length;if(0===s)throw new TypeError('The value "'+e+'" is invalid for argument "value"');for(i=0;i<r-t;++i)this[i+t]=o[i%s]}return this};const T={};function P(e,t,r){T[e]=class extends r{constructor(){super(),Object.defineProperty(this,"message",{value:t.apply(this,arguments),writable:!0,configurable:!0}),this.name=`${this.name} [${e}]`,this.stack,delete this.name}get code(){return e}set code(e){Object.defineProperty(this,"code",{configurable:!0,enumerable:!0,value:e,writable:!0})}toString(){return`${this.name} [${e}]: ${this.message}`}}}function O(e){let t="",r=e.length;const 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 z(e,t,r,n,i,o){if(e>r||e<t){const n="bigint"==typeof t?"n":"";let i;throw i=o>3?0===t||t===BigInt(0)?`>= 0${n} and < 2${n} ** ${8*(o+1)}${n}`:`>= -(2${n} ** ${8*(o+1)-1}${n}) and < 2 ** ${8*(o+1)-1}${n}`:`>= ${t}${n} and <= ${r}${n}`,new T.ERR_OUT_OF_RANGE("value",i,e)}!function(e,t,r){H(t,"offset"),void 0!==e[t]&&void 0!==e[t+r]||G(t,e.length-(r+1))}(n,i,o)}function H(e,t){if("number"!=typeof e)throw new T.ERR_INVALID_ARG_TYPE(t,"number",e)}function G(e,t,r){if(Math.floor(e)!==e)throw H(e,r),new T.ERR_OUT_OF_RANGE(r||"offset","an integer",e);if(t<0)throw new T.ERR_BUFFER_OUT_OF_BOUNDS;throw new T.ERR_OUT_OF_RANGE(r||"offset",`>= ${r?1:0} and <= ${t}`,e)}P("ERR_BUFFER_OUT_OF_BOUNDS",(function(e){return e?`${e} is outside of buffer bounds`:"Attempt to access memory outside buffer bounds"}),RangeError),P("ERR_INVALID_ARG_TYPE",(function(e,t){return`The "${e}" argument must be of type number. Received type ${typeof t}`}),TypeError),P("ERR_OUT_OF_RANGE",(function(e,t,r){let n=`The value of "${e}" is out of range.`,i=r;return Number.isInteger(r)&&Math.abs(r)>2**32?i=O(String(r)):"bigint"==typeof r&&(i=String(r),(r>BigInt(2)**BigInt(32)||r<-(BigInt(2)**BigInt(32)))&&(i=O(i)),i+="n"),n+=` It must be ${t}. Received ${i}`,n}),RangeError);const J=/[^+/0-9A-Za-z-_]/g;function Y(e,t){let r;t=t||1/0;const n=e.length;let i=null;const o=[];for(let s=0;s<n;++s){if(r=e.charCodeAt(s),r>55295&&r<57344){if(!i){if(r>56319){(t-=3)>-1&&o.push(239,191,189);continue}if(s+1===n){(t-=3)>-1&&o.push(239,191,189);continue}i=r;continue}if(r<56320){(t-=3)>-1&&o.push(239,191,189),i=r;continue}r=65536+(i-55296<<10|r-56320)}else i&&(t-=3)>-1&&o.push(239,191,189);if(i=null,r<128){if((t-=1)<0)break;o.push(r)}else if(r<2048){if((t-=2)<0)break;o.push(r>>6|192,63&r|128)}else if(r<65536){if((t-=3)<0)break;o.push(r>>12|224,r>>6&63|128,63&r|128)}else{if(!(r<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;o.push(r>>18|240,r>>12&63|128,r>>6&63|128,63&r|128)}}return o}function W(e){return n.toByteArray(function(e){if((e=(e=e.split("=")[0]).trim().replace(J,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function K(e,t,r,n){let i;for(i=0;i<n&&!(i+r>=t.length||i>=e.length);++i)t[i+r]=e[i];return i}function j(e,t){return e instanceof t||null!=e&&null!=e.constructor&&null!=e.constructor.name&&e.constructor.name===t.name}function V(e){return e!=e}const Z=function(){const e="0123456789abcdef",t=new Array(256);for(let r=0;r<16;++r){const n=16*r;for(let i=0;i<16;++i)t[n+i]=e[r]+e[i]}return t}();function $(e){return"undefined"==typeof BigInt?X:e}function X(){throw new Error("BigInt not supported")}},235:e=>{var t={array:function(e){var t=0,r=0,n=[0,1,3,7,15,31,63,127,255];return function(i){for(var o=0;i>0;){var s=8-t;i>=s?(o<<=s,o|=n[s]&e[r++],t=0,i-=s):(o<<=i,o|=(e[r]&n[i]<<8-i-t)>>8-i-t,t+=i,i=0)}return o}},simple:function(e){var r,n,i=t.header(e),o=[],s=0;do{-1!=(n=t.decompress(e,i))&&(o.push(n),s+=n.byteLength)}while(-1!=n);r=new Uint8Array(s),s=0;for(var a=0;a<o.length;++a)n=o[a],r.set(n,s),s+=n.byteLength;return r},header:function(e){if(4348520!=e(24))throw"No magic number found";var t=e(8)-48;if(t<1||t>9)throw"Not a BZIP archive";return t},decompress:function(e,t,r){for(var n=9e5,i="",o=0;o<6;o++)i+=e(8).toString(16);if("177245385090"==i)return-1;if("314159265359"!=i)throw"eek not valid bzip data";if(e(32),e(1))throw"unsupported obsolete version";var s=e(24);if(s>n)throw"Initial position larger than buffer size";var a=e(16),A=new Uint8Array(256),f=0;for(o=0;o<16;o++)if(a&1<<15-o){var h=e(16);for(g=0;g<16;g++)h&1<<15-g&&(A[f++]=16*o+g)}var u=e(3);if(u<2||u>6)throw"another error";var l=e(15);if(0==l)throw"meh";var c=[];for(o=0;o<u;o++)c[o]=o;var d=new Uint8Array(32768);for(o=0;o<l;o++){for(var g=0;e(1);g++)if(g>=u)throw"whoops another error";var p=c[g];c.splice(g,1),c.splice(0,0,p),d[o]=p}var C=f+2,I=[];for(g=0;g<u;g++){var m,y,w,B=new Uint8Array(258),E=new Uint8Array(21);for(a=e(5),o=0;o<C;o++){for(;;){if(a<1||a>20)throw"I gave up a while ago on writing error messages";if(!e(1))break;e(1)?a--:a++}B[o]=a}for(m=y=B[0],o=1;o<C;o++)B[o]>y?y=B[o]:B[o]<m&&(m=B[o]);(w=I[g]={}).permute=new Uint32Array(258),w.limit=new Uint32Array(21),w.base=new Uint32Array(21),w.minLen=m,w.maxLen=y;var b=w.base.subarray(1),_=w.limit.subarray(1),v=0;for(o=m;o<=y;o++)for(a=0;a<C;a++)B[a]==o&&(w.permute[v++]=a);for(o=m;o<=y;o++)E[o]=_[o]=0;for(o=0;o<C;o++)E[B[o]]++;for(v=a=0,o=m;o<y;o++)v+=E[o],_[o]=v-1,v<<=1,b[o+1]=v-(a+=E[o]);_[y]=v+E[y]-1,b[m]=0}var Q,S,k,D=new Uint32Array(256);for(o=0;o<256;o++)c[o]=o;Q=S=C=k=0;for(var R=new Uint32Array(n);;){if(!C--){if(C=49,k>=l)throw"meow i'm a kitty, that's an error";b=(w=I[d[k++]]).base.subarray(1),_=w.limit.subarray(1)}for(g=e(o=w.minLen);;){if(o>w.maxLen)throw"rawr i'm a dinosaur";if(g<=_[o])break;o++,g=g<<1|e(1)}if((g-=b[o])<0||g>=258)throw"moo i'm a cow";var N=w.permute[g];if(0!=N&&1!=N){if(Q){if(Q=0,S+a>=n)throw"Boom.";for(D[p=A[c[0]]]+=a;a--;)R[S++]=p}if(N>f)break;if(S>=n)throw"I can't think of anything. Error";p=c[o=N-1],c.splice(o,1),c.splice(0,0,p),D[p=A[p]]++,R[S++]=p}else Q||(Q=1,a=0),a+=0==N?Q:2*Q,Q<<=1}if(s<0||s>=S)throw"I'm a monkey and I'm throwing something at someone, namely you";for(g=0,o=0;o<256;o++)h=g+D[o],D[o]=g,g=h;for(o=0;o<S;o++)R[D[p=255&R[o]]]|=o<<8,D[p]++;var F=0,M=0,x=0;S&&(M=255&(F=R[s]),F>>=8,x=-1);var L,U,q,T=new Uint8Array(n),P=0;for(r||(r=1/0);S;){for(S--,U=M,M=255&(F=R[F]),F>>=8,3==x++?(L=M,q=U,M=-1):(L=1,q=M);L--;)if(T[P++]=q,! --r)return T;M!=U&&(x=0)}return T.subarray(0,P)}};e.exports=t},2151:e=>{var t={utf8:{stringToBytes:function(e){return t.bin.stringToBytes(unescape(encodeURIComponent(e)))},bytesToString:function(e){return decodeURIComponent(escape(t.bin.bytesToString(e)))}},bin:{stringToBytes:function(e){for(var t=[],r=0;r<e.length;r++)t.push(255&e.charCodeAt(r));return t},bytesToString:function(e){for(var t=[],r=0;r<e.length;r++)t.push(String.fromCharCode(e[r]));return t.join("")}}};e.exports=t},3939:e=>{var t,r;t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",r={rotl:function(e,t){return e<<t|e>>>32-t},rotr:function(e,t){return e<<32-t|e>>>t},endian:function(e){if(e.constructor==Number)return 16711935&r.rotl(e,8)|4278255360&r.rotl(e,24);for(var t=0;t<e.length;t++)e[t]=r.endian(e[t]);return e},randomBytes:function(e){for(var t=[];e>0;e--)t.push(Math.floor(256*Math.random()));return t},bytesToWords:function(e){for(var t=[],r=0,n=0;r<e.length;r++,n+=8)t[n>>>5]|=e[r]<<24-n%32;return t},wordsToBytes:function(e){for(var t=[],r=0;r<32*e.length;r+=8)t.push(e[r>>>5]>>>24-r%32&255);return t},bytesToHex:function(e){for(var t=[],r=0;r<e.length;r++)t.push((e[r]>>>4).toString(16)),t.push((15&e[r]).toString(16));return t.join("")},hexToBytes:function(e){for(var t=[],r=0;r<e.length;r+=2)t.push(parseInt(e.substr(r,2),16));return t},bytesToBase64:function(e){for(var r=[],n=0;n<e.length;n+=3)for(var i=e[n]<<16|e[n+1]<<8|e[n+2],o=0;o<4;o++)8*n+6*o<=8*e.length?r.push(t.charAt(i>>>6*(3-o)&63)):r.push("=");return r.join("")},base64ToBytes:function(e){e=e.replace(/[^A-Z0-9+\/]/gi,"");for(var r=[],n=0,i=0;n<e.length;i=++n%4)0!=i&&r.push((t.indexOf(e.charAt(n-1))&Math.pow(2,-2*i+8)-1)<<2*i|t.indexOf(e.charAt(n))>>>6-2*i);return r}},e.exports=r},1113:(e,t,r)=>{"use strict";r.r(t),r.d(t,{BlobFile:()=>f,LocalFile:()=>i(),RemoteFile:()=>a,fromUrl:()=>h,open:()=>u});var n=r(3617),i=r.n(n),o=r(8287);function s(e){return("object"==typeof e&&null!==e&&"message"in e?e.message:`${e}`).replace(/\.$/,"")}class a{async getBufferFromResponse(e){const t=await e.arrayBuffer();return o.Buffer.from(t)}constructor(e,t={}){this.baseOverrides={},this.url=e;const r=t.fetch||globalThis.fetch.bind(globalThis);if(!r)throw new TypeError("no fetch function supplied, and none found in global environment");t.overrides&&(this.baseOverrides=t.overrides),this.fetchImplementation=r}async fetch(e,t){let r;try{r=await this.fetchImplementation(e,t)}catch(n){if(!`${n}`.includes("Failed to fetch"))throw new Error(`${s(n)} fetching ${e}`,{cause:n});console.warn(`generic-filehandle: refetching ${e} to attempt to work around chrome CORS header caching bug`);try{r=await this.fetchImplementation(e,{...t,cache:"reload"})}catch(t){throw new Error(`${s(t)} fetching ${e}`,{cause:t})}}return r}async read(e,t=0,r,n=0,i={}){const{headers:o={},signal:s,overrides:a={}}=i;r<1/0?o.range=`bytes=${n}-${n+r}`:r===1/0&&0!==n&&(o.range=`bytes=${n}-`);const A=await this.fetch(this.url,{...this.baseOverrides,...a,headers:{...o,...a.headers,...this.baseOverrides.headers},method:"GET",redirect:"follow",mode:"cors",signal:s});if(!A.ok)throw new Error(`HTTP ${A.status} fetching ${this.url}`);if(200===A.status&&0===n||206===A.status){const n=await this.getBufferFromResponse(A),i=n.copy(e,t,0,Math.min(r,n.length)),o=A.headers.get("content-range"),s=/\/(\d+)$/.exec(o||"");return(null==s?void 0:s[1])&&(this._stat={size:parseInt(s[1],10)}),{bytesRead:i,buffer:e}}if(200===A.status)throw new Error(`${this.url} fetch returned status 200, expected 206`);throw new Error(`HTTP ${A.status} fetching ${this.url}`)}async readFile(e={}){let t,r;"string"==typeof e?(t=e,r={}):(t=e.encoding,r=e,delete r.encoding);const{headers:n={},signal:i,overrides:o={}}=r,s=await this.fetch(this.url,{headers:n,method:"GET",redirect:"follow",mode:"cors",signal:i,...this.baseOverrides,...o});if(200!==s.status)throw new Error(`HTTP ${s.status} fetching ${this.url}`);if("utf8"===t)return s.text();if(t)throw new Error(`unsupported encoding: ${t}`);return this.getBufferFromResponse(s)}async stat(){if(!this._stat){const e=o.Buffer.allocUnsafe(10);if(await this.read(e,0,10,0),!this._stat)throw new Error(`unable to determine size of file at ${this.url}`)}return this._stat}async close(){}}function A(e){const t=new FileReader;return new Promise(((r,n)=>{t.onerror=()=>{t.abort(),n(new Error("problem reading blob"))},t.onabort=()=>{n(new Error("blob reading was aborted"))},t.onload=()=>{t.result&&"string"!=typeof t.result?r(t.result):n(new Error("unknown error reading blob"))},t.readAsArrayBuffer(e)}))}class f{constructor(e){this.blob=e,this.size=e.size}async read(e,t=0,r,n=0){if(!r)return{bytesRead:0,buffer:e};const i=n,s=i+r,a=await A(this.blob.slice(i,s)),f=o.Buffer.from(a);return{bytesRead:f.copy(e,t),buffer:f}}async readFile(e){const t="string"==typeof e?e:null==e?void 0:e.encoding;if("utf8"===t)return function(e){const t=new FileReader;return new Promise(((r,n)=>{t.onerror=()=>{t.abort(),n(new Error("problem reading blob"))},t.onabort=()=>{n(new Error("blob reading was aborted"))},t.onload=()=>{t.result&&"string"==typeof t.result?r(t.result):n(new Error("unknown error reading blob"))},t.readAsText(e)}))}(this.blob);if(t)throw new Error(`unsupported encoding: ${t}`);const r=await A(this.blob);return o.Buffer.from(r)}async stat(){return{size:this.size}}async close(){}}function h(e,t={}){return new a(e,t)}function u(e,t,r,n={}){if(void 0!==r)return r;if(void 0!==e)return h(e,n);if(void 0!==t)return new(i())(t,n);throw new Error("no url, path, or filehandle provided, cannot open")}},251:(e,t)=>{t.read=function(e,t,r,n,i){var o,s,a=8*i-n-1,A=(1<<a)-1,f=A>>1,h=-7,u=r?i-1:0,l=r?-1:1,c=e[t+u];for(u+=l,o=c&(1<<-h)-1,c>>=-h,h+=a;h>0;o=256*o+e[t+u],u+=l,h-=8);for(s=o&(1<<-h)-1,o>>=-h,h+=n;h>0;s=256*s+e[t+u],u+=l,h-=8);if(0===o)o=1-f;else{if(o===A)return s?NaN:1/0*(c?-1:1);s+=Math.pow(2,n),o-=f}return(c?-1:1)*s*Math.pow(2,o-n)},t.write=function(e,t,r,n,i,o){var s,a,A,f=8*o-i-1,h=(1<<f)-1,u=h>>1,l=23===i?Math.pow(2,-24)-Math.pow(2,-77):0,c=n?0:o-1,d=n?1:-1,g=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(a=isNaN(t)?1:0,s=h):(s=Math.floor(Math.log(t)/Math.LN2),t*(A=Math.pow(2,-s))<1&&(s--,A*=2),(t+=s+u>=1?l/A:l*Math.pow(2,1-u))*A>=2&&(s++,A/=2),s+u>=h?(a=0,s=h):s+u>=1?(a=(t*A-1)*Math.pow(2,i),s+=u):(a=t*Math.pow(2,u-1)*Math.pow(2,i),s=0));i>=8;e[r+c]=255&a,c+=d,a/=256,i-=8);for(s=s<<i|a,f+=i;f>0;e[r+c]=255&s,c+=d,s/=256,f-=8);e[r+c-d]|=128*g}},8570:e=>{e.exports=r;var t=null;try{t=new WebAssembly.Instance(new WebAssembly.Module(new Uint8Array([0,97,115,109,1,0,0,0,1,13,2,96,0,1,127,96,4,127,127,127,127,1,127,3,7,6,0,1,1,1,1,1,6,6,1,127,1,65,0,11,7,50,6,3,109,117,108,0,1,5,100,105,118,95,115,0,2,5,100,105,118,95,117,0,3,5,114,101,109,95,115,0,4,5,114,101,109,95,117,0,5,8,103,101,116,95,104,105,103,104,0,0,10,191,1,6,4,0,35,0,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,126,34,4,66,32,135,167,36,0,32,4,167,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,127,34,4,66,32,135,167,36,0,32,4,167,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,128,34,4,66,32,135,167,36,0,32,4,167,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,129,34,4,66,32,135,167,36,0,32,4,167,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,130,34,4,66,32,135,167,36,0,32,4,167,11])),{}).exports}catch(e){}function r(e,t,r){this.low=0|e,this.high=0|t,this.unsigned=!!r}function n(e){return!0===(e&&e.__isLong__)}r.prototype.__isLong__,Object.defineProperty(r.prototype,"__isLong__",{value:!0}),r.isLong=n;var i={},o={};function s(e,t){var r,n,s;return t?(s=0<=(e>>>=0)&&e<256)&&(n=o[e])?n:(r=A(e,(0|e)<0?-1:0,!0),s&&(o[e]=r),r):(s=-128<=(e|=0)&&e<128)&&(n=i[e])?n:(r=A(e,e<0?-1:0,!1),s&&(i[e]=r),r)}function a(e,t){if(isNaN(e))return t?C:p;if(t){if(e<0)return C;if(e>=c)return B}else{if(e<=-d)return E;if(e+1>=d)return w}return e<0?a(-e,t).neg():A(e%l|0,e/l|0,t)}function A(e,t,n){return new r(e,t,n)}r.fromInt=s,r.fromNumber=a,r.fromBits=A;var f=Math.pow;function h(e,t,r){if(0===e.length)throw Error("empty string");if("NaN"===e||"Infinity"===e||"+Infinity"===e||"-Infinity"===e)return p;if("number"==typeof t?(r=t,t=!1):t=!!t,(r=r||10)<2||36<r)throw RangeError("radix");var n;if((n=e.indexOf("-"))>0)throw Error("interior hyphen");if(0===n)return h(e.substring(1),t,r).neg();for(var i=a(f(r,8)),o=p,s=0;s<e.length;s+=8){var A=Math.min(8,e.length-s),u=parseInt(e.substring(s,s+A),r);if(A<8){var l=a(f(r,A));o=o.mul(l).add(a(u))}else o=(o=o.mul(i)).add(a(u))}return o.unsigned=t,o}function u(e,t){return"number"==typeof e?a(e,t):"string"==typeof e?h(e,t):A(e.low,e.high,"boolean"==typeof t?t:e.unsigned)}r.fromString=h,r.fromValue=u;var l=4294967296,c=l*l,d=c/2,g=s(1<<24),p=s(0);r.ZERO=p;var C=s(0,!0);r.UZERO=C;var I=s(1);r.ONE=I;var m=s(1,!0);r.UONE=m;var y=s(-1);r.NEG_ONE=y;var w=A(-1,2147483647,!1);r.MAX_VALUE=w;var B=A(-1,-1,!0);r.MAX_UNSIGNED_VALUE=B;var E=A(0,-2147483648,!1);r.MIN_VALUE=E;var b=r.prototype;b.toInt=function(){return this.unsigned?this.low>>>0:this.low},b.toNumber=function(){return this.unsigned?(this.high>>>0)*l+(this.low>>>0):this.high*l+(this.low>>>0)},b.toString=function(e){if((e=e||10)<2||36<e)throw RangeError("radix");if(this.isZero())return"0";if(this.isNegative()){if(this.eq(E)){var t=a(e),r=this.div(t),n=r.mul(t).sub(this);return r.toString(e)+n.toInt().toString(e)}return"-"+this.neg().toString(e)}for(var i=a(f(e,6),this.unsigned),o=this,s="";;){var A=o.div(i),h=(o.sub(A.mul(i)).toInt()>>>0).toString(e);if((o=A).isZero())return h+s;for(;h.length<6;)h="0"+h;s=""+h+s}},b.getHighBits=function(){return this.high},b.getHighBitsUnsigned=function(){return this.high>>>0},b.getLowBits=function(){return this.low},b.getLowBitsUnsigned=function(){return this.low>>>0},b.getNumBitsAbs=function(){if(this.isNegative())return this.eq(E)?64:this.neg().getNumBitsAbs();for(var e=0!=this.high?this.high:this.low,t=31;t>0&&!(e&1<<t);t--);return 0!=this.high?t+33:t+1},b.isZero=function(){return 0===this.high&&0===this.low},b.eqz=b.isZero,b.isNegative=function(){return!this.unsigned&&this.high<0},b.isPositive=function(){return this.unsigned||this.high>=0},b.isOdd=function(){return!(1&~this.low)},b.isEven=function(){return!(1&this.low)},b.equals=function(e){return n(e)||(e=u(e)),(this.unsigned===e.unsigned||this.high>>>31!=1||e.high>>>31!=1)&&this.high===e.high&&this.low===e.low},b.eq=b.equals,b.notEquals=function(e){return!this.eq(e)},b.neq=b.notEquals,b.ne=b.notEquals,b.lessThan=function(e){return this.comp(e)<0},b.lt=b.lessThan,b.lessThanOrEqual=function(e){return this.comp(e)<=0},b.lte=b.lessThanOrEqual,b.le=b.lessThanOrEqual,b.greaterThan=function(e){return this.comp(e)>0},b.gt=b.greaterThan,b.greaterThanOrEqual=function(e){return this.comp(e)>=0},b.gte=b.greaterThanOrEqual,b.ge=b.greaterThanOrEqual,b.compare=function(e){if(n(e)||(e=u(e)),this.eq(e))return 0;var t=this.isNegative(),r=e.isNegative();return t&&!r?-1:!t&&r?1:this.unsigned?e.high>>>0>this.high>>>0||e.high===this.high&&e.low>>>0>this.low>>>0?-1:1:this.sub(e).isNegative()?-1:1},b.comp=b.compare,b.negate=function(){return!this.unsigned&&this.eq(E)?E:this.not().add(I)},b.neg=b.negate,b.add=function(e){n(e)||(e=u(e));var t=this.high>>>16,r=65535&this.high,i=this.low>>>16,o=65535&this.low,s=e.high>>>16,a=65535&e.high,f=e.low>>>16,h=0,l=0,c=0,d=0;return c+=(d+=o+(65535&e.low))>>>16,l+=(c+=i+f)>>>16,h+=(l+=r+a)>>>16,h+=t+s,A((c&=65535)<<16|(d&=65535),(h&=65535)<<16|(l&=65535),this.unsigned)},b.subtract=function(e){return n(e)||(e=u(e)),this.add(e.neg())},b.sub=b.subtract,b.multiply=function(e){if(this.isZero())return p;if(n(e)||(e=u(e)),t)return A(t.mul(this.low,this.high,e.low,e.high),t.get_high(),this.unsigned);if(e.isZero())return p;if(this.eq(E))return e.isOdd()?E:p;if(e.eq(E))return this.isOdd()?E:p;if(this.isNegative())return e.isNegative()?this.neg().mul(e.neg()):this.neg().mul(e).neg();if(e.isNegative())return this.mul(e.neg()).neg();if(this.lt(g)&&e.lt(g))return a(this.toNumber()*e.toNumber(),this.unsigned);var r=this.high>>>16,i=65535&this.high,o=this.low>>>16,s=65535&this.low,f=e.high>>>16,h=65535&e.high,l=e.low>>>16,c=65535&e.low,d=0,C=0,I=0,m=0;return I+=(m+=s*c)>>>16,C+=(I+=o*c)>>>16,I&=65535,C+=(I+=s*l)>>>16,d+=(C+=i*c)>>>16,C&=65535,d+=(C+=o*l)>>>16,C&=65535,d+=(C+=s*h)>>>16,d+=r*c+i*l+o*h+s*f,A((I&=65535)<<16|(m&=65535),(d&=65535)<<16|(C&=65535),this.unsigned)},b.mul=b.multiply,b.divide=function(e){if(n(e)||(e=u(e)),e.isZero())throw Error("division by zero");var r,i,o;if(t)return this.unsigned||-2147483648!==this.high||-1!==e.low||-1!==e.high?A((this.unsigned?t.div_u:t.div_s)(this.low,this.high,e.low,e.high),t.get_high(),this.unsigned):this;if(this.isZero())return this.unsigned?C:p;if(this.unsigned){if(e.unsigned||(e=e.toUnsigned()),e.gt(this))return C;if(e.gt(this.shru(1)))return m;o=C}else{if(this.eq(E))return e.eq(I)||e.eq(y)?E:e.eq(E)?I:(r=this.shr(1).div(e).shl(1)).eq(p)?e.isNegative()?I:y:(i=this.sub(e.mul(r)),o=r.add(i.div(e)));if(e.eq(E))return this.unsigned?C:p;if(this.isNegative())return e.isNegative()?this.neg().div(e.neg()):this.neg().div(e).neg();if(e.isNegative())return this.div(e.neg()).neg();o=p}for(i=this;i.gte(e);){r=Math.max(1,Math.floor(i.toNumber()/e.toNumber()));for(var s=Math.ceil(Math.log(r)/Math.LN2),h=s<=48?1:f(2,s-48),l=a(r),c=l.mul(e);c.isNegative()||c.gt(i);)c=(l=a(r-=h,this.unsigned)).mul(e);l.isZero()&&(l=I),o=o.add(l),i=i.sub(c)}return o},b.div=b.divide,b.modulo=function(e){return n(e)||(e=u(e)),t?A((this.unsigned?t.rem_u:t.rem_s)(this.low,this.high,e.low,e.high),t.get_high(),this.unsigned):this.sub(this.div(e).mul(e))},b.mod=b.modulo,b.rem=b.modulo,b.not=function(){return A(~this.low,~this.high,this.unsigned)},b.and=function(e){return n(e)||(e=u(e)),A(this.low&e.low,this.high&e.high,this.unsigned)},b.or=function(e){return n(e)||(e=u(e)),A(this.low|e.low,this.high|e.high,this.unsigned)},b.xor=function(e){return n(e)||(e=u(e)),A(this.low^e.low,this.high^e.high,this.unsigned)},b.shiftLeft=function(e){return n(e)&&(e=e.toInt()),0==(e&=63)?this:e<32?A(this.low<<e,this.high<<e|this.low>>>32-e,this.unsigned):A(0,this.low<<e-32,this.unsigned)},b.shl=b.shiftLeft,b.shiftRight=function(e){return n(e)&&(e=e.toInt()),0==(e&=63)?this:e<32?A(this.low>>>e|this.high<<32-e,this.high>>e,this.unsigned):A(this.high>>e-32,this.high>=0?0:-1,this.unsigned)},b.shr=b.shiftRight,b.shiftRightUnsigned=function(e){if(n(e)&&(e=e.toInt()),0==(e&=63))return this;var t=this.high;return e<32?A(this.low>>>e|t<<32-e,t>>>e,this.unsigned):A(32===e?t:t>>>e-32,0,this.unsigned)},b.shru=b.shiftRightUnsigned,b.shr_u=b.shiftRightUnsigned,b.toSigned=function(){return this.unsigned?A(this.low,this.high,!1):this},b.toUnsigned=function(){return this.unsigned?this:A(this.low,this.high,!0)},b.toBytes=function(e){return e?this.toBytesLE():this.toBytesBE()},b.toBytesLE=function(){var e=this.high,t=this.low;return[255&t,t>>>8&255,t>>>16&255,t>>>24,255&e,e>>>8&255,e>>>16&255,e>>>24]},b.toBytesBE=function(){var e=this.high,t=this.low;return[e>>>24,e>>>16&255,e>>>8&255,255&e,t>>>24,t>>>16&255,t>>>8&255,255&t]},r.fromBytes=function(e,t,n){return n?r.fromBytesLE(e,t):r.fromBytesBE(e,t)},r.fromBytesLE=function(e,t){return new r(e[0]|e[1]<<8|e[2]<<16|e[3]<<24,e[4]|e[5]<<8|e[6]<<16|e[7]<<24,t)},r.fromBytesBE=function(e,t){return new r(e[4]<<24|e[5]<<16|e[6]<<8|e[7],e[0]<<24|e[1]<<16|e[2]<<8|e[3],t)}},3503:(e,t,r)=>{var n,i,o,s,a;n=r(3939),i=r(2151).utf8,o=r(652),s=r(2151).bin,(a=function(e,t){e.constructor==String?e=t&&"binary"===t.encoding?s.stringToBytes(e):i.stringToBytes(e):o(e)?e=Array.prototype.slice.call(e,0):Array.isArray(e)||e.constructor===Uint8Array||(e=e.toString());for(var r=n.bytesToWords(e),A=8*e.length,f=1732584193,h=-271733879,u=-1732584194,l=271733878,c=0;c<r.length;c++)r[c]=16711935&(r[c]<<8|r[c]>>>24)|4278255360&(r[c]<<24|r[c]>>>8);r[A>>>5]|=128<<A%32,r[14+(A+64>>>9<<4)]=A;var d=a._ff,g=a._gg,p=a._hh,C=a._ii;for(c=0;c<r.length;c+=16){var I=f,m=h,y=u,w=l;f=d(f,h,u,l,r[c+0],7,-680876936),l=d(l,f,h,u,r[c+1],12,-389564586),u=d(u,l,f,h,r[c+2],17,606105819),h=d(h,u,l,f,r[c+3],22,-1044525330),f=d(f,h,u,l,r[c+4],7,-176418897),l=d(l,f,h,u,r[c+5],12,1200080426),u=d(u,l,f,h,r[c+6],17,-1473231341),h=d(h,u,l,f,r[c+7],22,-45705983),f=d(f,h,u,l,r[c+8],7,1770035416),l=d(l,f,h,u,r[c+9],12,-1958414417),u=d(u,l,f,h,r[c+10],17,-42063),h=d(h,u,l,f,r[c+11],22,-1990404162),f=d(f,h,u,l,r[c+12],7,1804603682),l=d(l,f,h,u,r[c+13],12,-40341101),u=d(u,l,f,h,r[c+14],17,-1502002290),f=g(f,h=d(h,u,l,f,r[c+15],22,1236535329),u,l,r[c+1],5,-165796510),l=g(l,f,h,u,r[c+6],9,-1069501632),u=g(u,l,f,h,r[c+11],14,643717713),h=g(h,u,l,f,r[c+0],20,-373897302),f=g(f,h,u,l,r[c+5],5,-701558691),l=g(l,f,h,u,r[c+10],9,38016083),u=g(u,l,f,h,r[c+15],14,-660478335),h=g(h,u,l,f,r[c+4],20,-405537848),f=g(f,h,u,l,r[c+9],5,568446438),l=g(l,f,h,u,r[c+14],9,-1019803690),u=g(u,l,f,h,r[c+3],14,-187363961),h=g(h,u,l,f,r[c+8],20,1163531501),f=g(f,h,u,l,r[c+13],5,-1444681467),l=g(l,f,h,u,r[c+2],9,-51403784),u=g(u,l,f,h,r[c+7],14,1735328473),f=p(f,h=g(h,u,l,f,r[c+12],20,-1926607734),u,l,r[c+5],4,-378558),l=p(l,f,h,u,r[c+8],11,-2022574463),u=p(u,l,f,h,r[c+11],16,1839030562),h=p(h,u,l,f,r[c+14],23,-35309556),f=p(f,h,u,l,r[c+1],4,-1530992060),l=p(l,f,h,u,r[c+4],11,1272893353),u=p(u,l,f,h,r[c+7],16,-155497632),h=p(h,u,l,f,r[c+10],23,-1094730640),f=p(f,h,u,l,r[c+13],4,681279174),l=p(l,f,h,u,r[c+0],11,-358537222),u=p(u,l,f,h,r[c+3],16,-722521979),h=p(h,u,l,f,r[c+6],23,76029189),f=p(f,h,u,l,r[c+9],4,-640364487),l=p(l,f,h,u,r[c+12],11,-421815835),u=p(u,l,f,h,r[c+15],16,530742520),f=C(f,h=p(h,u,l,f,r[c+2],23,-995338651),u,l,r[c+0],6,-198630844),l=C(l,f,h,u,r[c+7],10,1126891415),u=C(u,l,f,h,r[c+14],15,-1416354905),h=C(h,u,l,f,r[c+5],21,-57434055),f=C(f,h,u,l,r[c+12],6,1700485571),l=C(l,f,h,u,r[c+3],10,-1894986606),u=C(u,l,f,h,r[c+10],15,-1051523),h=C(h,u,l,f,r[c+1],21,-2054922799),f=C(f,h,u,l,r[c+8],6,1873313359),l=C(l,f,h,u,r[c+15],10,-30611744),u=C(u,l,f,h,r[c+6],15,-1560198380),h=C(h,u,l,f,r[c+13],21,1309151649),f=C(f,h,u,l,r[c+4],6,-145523070),l=C(l,f,h,u,r[c+11],10,-1120210379),u=C(u,l,f,h,r[c+2],15,718787259),h=C(h,u,l,f,r[c+9],21,-343485551),f=f+I>>>0,h=h+m>>>0,u=u+y>>>0,l=l+w>>>0}return n.endian([f,h,u,l])})._ff=function(e,t,r,n,i,o,s){var a=e+(t&r|~t&n)+(i>>>0)+s;return(a<<o|a>>>32-o)+t},a._gg=function(e,t,r,n,i,o,s){var a=e+(t&n|r&~n)+(i>>>0)+s;return(a<<o|a>>>32-o)+t},a._hh=function(e,t,r,n,i,o,s){var a=e+(t^r^n)+(i>>>0)+s;return(a<<o|a>>>32-o)+t},a._ii=function(e,t,r,n,i,o,s){var a=e+(r^(t|~n))+(i>>>0)+s;return(a<<o|a>>>32-o)+t},a._blocksize=16,a._digestsize=16,e.exports=function(e,t){if(null==e)throw new Error("Illegal argument "+e);var r=n.wordsToBytes(a(e,t));return t&&t.asBytes?r:t&&t.asString?s.bytesToString(r):n.bytesToHex(r)}},652:e=>{function t(e){return!!e.constructor&&"function"==typeof e.constructor.isBuffer&&e.constructor.isBuffer(e)}e.exports=function(e){return null!=e&&(t(e)||function(e){return"function"==typeof e.readFloatLE&&"function"==typeof e.slice&&t(e.slice(0,0))}(e)||!!e._isBuffer)}},1668:(e,t,r)=>{"use strict";var n={};(0,r(9805).assign)(n,r(3303),r(7083),r(9681)),e.exports=n},3303:(e,t,r)=>{"use strict";var n=r(8411),i=r(9805),o=r(1996),s=r(4674),a=r(4442),A=Object.prototype.toString,f=0,h=-1,u=0,l=8;function c(e){if(!(this instanceof c))return new c(e);this.options=i.assign({level:h,method:l,chunkSize:16384,windowBits:15,memLevel:8,strategy:u,to:""},e||{});var t=this.options;t.raw&&t.windowBits>0?t.windowBits=-t.windowBits:t.gzip&&t.windowBits>0&&t.windowBits<16&&(t.windowBits+=16),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new a,this.strm.avail_out=0;var r=n.deflateInit2(this.strm,t.level,t.method,t.windowBits,t.memLevel,t.strategy);if(r!==f)throw new Error(s[r]);if(t.header&&n.deflateSetHeader(this.strm,t.header),t.dictionary){var d;if(d="string"==typeof t.dictionary?o.string2buf(t.dictionary):"[object ArrayBuffer]"===A.call(t.dictionary)?new Uint8Array(t.dictionary):t.dictionary,(r=n.deflateSetDictionary(this.strm,d))!==f)throw new Error(s[r]);this._dict_set=!0}}function d(e,t){var r=new c(t);if(r.push(e,!0),r.err)throw r.msg||s[r.err];return r.result}c.prototype.push=function(e,t){var r,s,a=this.strm,h=this.options.chunkSize;if(this.ended)return!1;s=t===~~t?t:!0===t?4:0,"string"==typeof e?a.input=o.string2buf(e):"[object ArrayBuffer]"===A.call(e)?a.input=new Uint8Array(e):a.input=e,a.next_in=0,a.avail_in=a.input.length;do{if(0===a.avail_out&&(a.output=new i.Buf8(h),a.next_out=0,a.avail_out=h),1!==(r=n.deflate(a,s))&&r!==f)return this.onEnd(r),this.ended=!0,!1;0!==a.avail_out&&(0!==a.avail_in||4!==s&&2!==s)||("string"===this.options.to?this.onData(o.buf2binstring(i.shrinkBuf(a.output,a.next_out))):this.onData(i.shrinkBuf(a.output,a.next_out)))}while((a.avail_in>0||0===a.avail_out)&&1!==r);return 4===s?(r=n.deflateEnd(this.strm),this.onEnd(r),this.ended=!0,r===f):2!==s||(this.onEnd(f),a.avail_out=0,!0)},c.prototype.onData=function(e){this.chunks.push(e)},c.prototype.onEnd=function(e){e===f&&("string"===this.options.to?this.result=this.chunks.join(""):this.result=i.flattenChunks(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg},t.Deflate=c,t.deflate=d,t.deflateRaw=function(e,t){return(t=t||{}).raw=!0,d(e,t)},t.gzip=function(e,t){return(t=t||{}).gzip=!0,d(e,t)}},7083:(e,t,r)=>{"use strict";var n=r(1447),i=r(9805),o=r(1996),s=r(9681),a=r(4674),A=r(4442),f=r(7414),h=Object.prototype.toString;function u(e){if(!(this instanceof u))return new u(e);this.options=i.assign({chunkSize:16384,windowBits:0,to:""},e||{});var t=this.options;t.raw&&t.windowBits>=0&&t.windowBits<16&&(t.windowBits=-t.windowBits,0===t.windowBits&&(t.windowBits=-15)),!(t.windowBits>=0&&t.windowBits<16)||e&&e.windowBits||(t.windowBits+=32),t.windowBits>15&&t.windowBits<48&&(15&t.windowBits||(t.windowBits|=15)),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new A,this.strm.avail_out=0;var r=n.inflateInit2(this.strm,t.windowBits);if(r!==s.Z_OK)throw new Error(a[r]);if(this.header=new f,n.inflateGetHeader(this.strm,this.header),t.dictionary&&("string"==typeof t.dictionary?t.dictionary=o.string2buf(t.dictionary):"[object ArrayBuffer]"===h.call(t.dictionary)&&(t.dictionary=new Uint8Array(t.dictionary)),t.raw&&(r=n.inflateSetDictionary(this.strm,t.dictionary))!==s.Z_OK))throw new Error(a[r])}function l(e,t){var r=new u(t);if(r.push(e,!0),r.err)throw r.msg||a[r.err];return r.result}u.prototype.push=function(e,t){var r,a,A,f,u,l=this.strm,c=this.options.chunkSize,d=this.options.dictionary,g=!1;if(this.ended)return!1;a=t===~~t?t:!0===t?s.Z_FINISH:s.Z_NO_FLUSH,"string"==typeof e?l.input=o.binstring2buf(e):"[object ArrayBuffer]"===h.call(e)?l.input=new Uint8Array(e):l.input=e,l.next_in=0,l.avail_in=l.input.length;do{if(0===l.avail_out&&(l.output=new i.Buf8(c),l.next_out=0,l.avail_out=c),(r=n.inflate(l,s.Z_NO_FLUSH))===s.Z_NEED_DICT&&d&&(r=n.inflateSetDictionary(this.strm,d)),r===s.Z_BUF_ERROR&&!0===g&&(r=s.Z_OK,g=!1),r!==s.Z_STREAM_END&&r!==s.Z_OK)return this.onEnd(r),this.ended=!0,!1;l.next_out&&(0!==l.avail_out&&r!==s.Z_STREAM_END&&(0!==l.avail_in||a!==s.Z_FINISH&&a!==s.Z_SYNC_FLUSH)||("string"===this.options.to?(A=o.utf8border(l.output,l.next_out),f=l.next_out-A,u=o.buf2string(l.output,A),l.next_out=f,l.avail_out=c-f,f&&i.arraySet(l.output,l.output,A,f,0),this.onData(u)):this.onData(i.shrinkBuf(l.output,l.next_out)))),0===l.avail_in&&0===l.avail_out&&(g=!0)}while((l.avail_in>0||0===l.avail_out)&&r!==s.Z_STREAM_END);return r===s.Z_STREAM_END&&(a=s.Z_FINISH),a===s.Z_FINISH?(r=n.inflateEnd(this.strm),this.onEnd(r),this.ended=!0,r===s.Z_OK):a!==s.Z_SYNC_FLUSH||(this.onEnd(s.Z_OK),l.avail_out=0,!0)},u.prototype.onData=function(e){this.chunks.push(e)},u.prototype.onEnd=function(e){e===s.Z_OK&&("string"===this.options.to?this.result=this.chunks.join(""):this.result=i.flattenChunks(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg},t.Inflate=u,t.inflate=l,t.inflateRaw=function(e,t){return(t=t||{}).raw=!0,l(e,t)},t.ungzip=l},9805:(e,t)=>{"use strict";var r="undefined"!=typeof Uint8Array&&"undefined"!=typeof Uint16Array&&"undefined"!=typeof Int32Array;function n(e,t){return Object.prototype.hasOwnProperty.call(e,t)}t.assign=function(e){for(var t=Array.prototype.slice.call(arguments,1);t.length;){var r=t.shift();if(r){if("object"!=typeof r)throw new TypeError(r+"must be non-object");for(var i in r)n(r,i)&&(e[i]=r[i])}}return e},t.shrinkBuf=function(e,t){return e.length===t?e:e.subarray?e.subarray(0,t):(e.length=t,e)};var i={arraySet:function(e,t,r,n,i){if(t.subarray&&e.subarray)e.set(t.subarray(r,r+n),i);else for(var o=0;o<n;o++)e[i+o]=t[r+o]},flattenChunks:function(e){var t,r,n,i,o,s;for(n=0,t=0,r=e.length;t<r;t++)n+=e[t].length;for(s=new Uint8Array(n),i=0,t=0,r=e.length;t<r;t++)o=e[t],s.set(o,i),i+=o.length;return s}},o={arraySet:function(e,t,r,n,i){for(var o=0;o<n;o++)e[i+o]=t[r+o]},flattenChunks:function(e){return[].concat.apply([],e)}};t.setTyped=function(e){e?(t.Buf8=Uint8Array,t.Buf16=Uint16Array,t.Buf32=Int32Array,t.assign(t,i)):(t.Buf8=Array,t.Buf16=Array,t.Buf32=Array,t.assign(t,o))},t.setTyped(r)},1996:(e,t,r)=>{"use strict";var n=r(9805),i=!0,o=!0;try{String.fromCharCode.apply(null,[0])}catch(e){i=!1}try{String.fromCharCode.apply(null,new Uint8Array(1))}catch(e){o=!1}for(var s=new n.Buf8(256),a=0;a<256;a++)s[a]=a>=252?6:a>=248?5:a>=240?4:a>=224?3:a>=192?2:1;function A(e,t){if(t<65534&&(e.subarray&&o||!e.subarray&&i))return String.fromCharCode.apply(null,n.shrinkBuf(e,t));for(var r="",s=0;s<t;s++)r+=String.fromCharCode(e[s]);return r}s[254]=s[254]=1,t.string2buf=function(e){var t,r,i,o,s,a=e.length,A=0;for(o=0;o<a;o++)55296==(64512&(r=e.charCodeAt(o)))&&o+1<a&&56320==(64512&(i=e.charCodeAt(o+1)))&&(r=65536+(r-55296<<10)+(i-56320),o++),A+=r<128?1:r<2048?2:r<65536?3:4;for(t=new n.Buf8(A),s=0,o=0;s<A;o++)55296==(64512&(r=e.charCodeAt(o)))&&o+1<a&&56320==(64512&(i=e.charCodeAt(o+1)))&&(r=65536+(r-55296<<10)+(i-56320),o++),r<128?t[s++]=r:r<2048?(t[s++]=192|r>>>6,t[s++]=128|63&r):r<65536?(t[s++]=224|r>>>12,t[s++]=128|r>>>6&63,t[s++]=128|63&r):(t[s++]=240|r>>>18,t[s++]=128|r>>>12&63,t[s++]=128|r>>>6&63,t[s++]=128|63&r);return t},t.buf2binstring=function(e){return A(e,e.length)},t.binstring2buf=function(e){for(var t=new n.Buf8(e.length),r=0,i=t.length;r<i;r++)t[r]=e.charCodeAt(r);return t},t.buf2string=function(e,t){var r,n,i,o,a=t||e.length,f=new Array(2*a);for(n=0,r=0;r<a;)if((i=e[r++])<128)f[n++]=i;else if((o=s[i])>4)f[n++]=65533,r+=o-1;else{for(i&=2===o?31:3===o?15:7;o>1&&r<a;)i=i<<6|63&e[r++],o--;o>1?f[n++]=65533:i<65536?f[n++]=i:(i-=65536,f[n++]=55296|i>>10&1023,f[n++]=56320|1023&i)}return A(f,n)},t.utf8border=function(e,t){var r;for((t=t||e.length)>e.length&&(t=e.length),r=t-1;r>=0&&128==(192&e[r]);)r--;return r<0||0===r?t:r+s[e[r]]>t?r:t}},3269:e=>{"use strict";e.exports=function(e,t,r,n){for(var i=65535&e,o=e>>>16&65535,s=0;0!==r;){r-=s=r>2e3?2e3:r;do{o=o+(i=i+t[n++]|0)|0}while(--s);i%=65521,o%=65521}return i|o<<16}},9681:e=>{"use strict";e.exports={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8}},4823:e=>{"use strict";var t=function(){for(var e,t=[],r=0;r<256;r++){e=r;for(var n=0;n<8;n++)e=1&e?3988292384^e>>>1:e>>>1;t[r]=e}return t}();e.exports=function(e,r,n,i){var o=t,s=i+n;e^=-1;for(var a=i;a<s;a++)e=e>>>8^o[255&(e^r[a])];return~e}},8411:(e,t,r)=>{"use strict";var n,i=r(9805),o=r(3665),s=r(3269),a=r(4823),A=r(4674),f=0,h=0,u=-2,l=2,c=8,d=286,g=30,p=19,C=2*d+1,I=15,m=3,y=258,w=y+m+1,B=42,E=103,b=113,_=666;function v(e,t){return e.msg=A[t],t}function Q(e){return(e<<1)-(e>4?9:0)}function S(e){for(var t=e.length;--t>=0;)e[t]=0}function k(e){var t=e.state,r=t.pending;r>e.avail_out&&(r=e.avail_out),0!==r&&(i.arraySet(e.output,t.pending_buf,t.pending_out,r,e.next_out),e.next_out+=r,t.pending_out+=r,e.total_out+=r,e.avail_out-=r,t.pending-=r,0===t.pending&&(t.pending_out=0))}function D(e,t){o._tr_flush_block(e,e.block_start>=0?e.block_start:-1,e.strstart-e.block_start,t),e.block_start=e.strstart,k(e.strm)}function R(e,t){e.pending_buf[e.pending++]=t}function N(e,t){e.pending_buf[e.pending++]=t>>>8&255,e.pending_buf[e.pending++]=255&t}function F(e,t,r,n){var o=e.avail_in;return o>n&&(o=n),0===o?0:(e.avail_in-=o,i.arraySet(t,e.input,e.next_in,o,r),1===e.state.wrap?e.adler=s(e.adler,t,o,r):2===e.state.wrap&&(e.adler=a(e.adler,t,o,r)),e.next_in+=o,e.total_in+=o,o)}function M(e,t){var r,n,i=e.max_chain_length,o=e.strstart,s=e.prev_length,a=e.nice_match,A=e.strstart>e.w_size-w?e.strstart-(e.w_size-w):0,f=e.window,h=e.w_mask,u=e.prev,l=e.strstart+y,c=f[o+s-1],d=f[o+s];e.prev_length>=e.good_match&&(i>>=2),a>e.lookahead&&(a=e.lookahead);do{if(f[(r=t)+s]===d&&f[r+s-1]===c&&f[r]===f[o]&&f[++r]===f[o+1]){o+=2,r++;do{}while(f[++o]===f[++r]&&f[++o]===f[++r]&&f[++o]===f[++r]&&f[++o]===f[++r]&&f[++o]===f[++r]&&f[++o]===f[++r]&&f[++o]===f[++r]&&f[++o]===f[++r]&&o<l);if(n=y-(l-o),o=l-y,n>s){if(e.match_start=t,s=n,n>=a)break;c=f[o+s-1],d=f[o+s]}}}while((t=u[t&h])>A&&0!=--i);return s<=e.lookahead?s:e.lookahead}function x(e){var t,r,n,o,s,a=e.w_size;do{if(o=e.window_size-e.lookahead-e.strstart,e.strstart>=a+(a-w)){i.arraySet(e.window,e.window,a,a,0),e.match_start-=a,e.strstart-=a,e.block_start-=a,t=r=e.hash_size;do{n=e.head[--t],e.head[t]=n>=a?n-a:0}while(--r);t=r=a;do{n=e.prev[--t],e.prev[t]=n>=a?n-a:0}while(--r);o+=a}if(0===e.strm.avail_in)break;if(r=F(e.strm,e.window,e.strstart+e.lookahead,o),e.lookahead+=r,e.lookahead+e.insert>=m)for(s=e.strstart-e.insert,e.ins_h=e.window[s],e.ins_h=(e.ins_h<<e.hash_shift^e.window[s+1])&e.hash_mask;e.insert&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[s+m-1])&e.hash_mask,e.prev[s&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=s,s++,e.insert--,!(e.lookahead+e.insert<m)););}while(e.lookahead<w&&0!==e.strm.avail_in)}function L(e,t){for(var r,n;;){if(e.lookahead<w){if(x(e),e.lookahead<w&&t===f)return 1;if(0===e.lookahead)break}if(r=0,e.lookahead>=m&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+m-1])&e.hash_mask,r=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),0!==r&&e.strstart-r<=e.w_size-w&&(e.match_length=M(e,r)),e.match_length>=m)if(n=o._tr_tally(e,e.strstart-e.match_start,e.match_length-m),e.lookahead-=e.match_length,e.match_length<=e.max_lazy_match&&e.lookahead>=m){e.match_length--;do{e.strstart++,e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+m-1])&e.hash_mask,r=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart}while(0!=--e.match_length);e.strstart++}else e.strstart+=e.match_length,e.match_length=0,e.ins_h=e.window[e.strstart],e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+1])&e.hash_mask;else n=o._tr_tally(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++;if(n&&(D(e,!1),0===e.strm.avail_out))return 1}return e.insert=e.strstart<m-1?e.strstart:m-1,4===t?(D(e,!0),0===e.strm.avail_out?3:4):e.last_lit&&(D(e,!1),0===e.strm.avail_out)?1:2}function U(e,t){for(var r,n,i;;){if(e.lookahead<w){if(x(e),e.lookahead<w&&t===f)return 1;if(0===e.lookahead)break}if(r=0,e.lookahead>=m&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+m-1])&e.hash_mask,r=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),e.prev_length=e.match_length,e.prev_match=e.match_start,e.match_length=m-1,0!==r&&e.prev_length<e.max_lazy_match&&e.strstart-r<=e.w_size-w&&(e.match_length=M(e,r),e.match_length<=5&&(1===e.strategy||e.match_length===m&&e.strstart-e.match_start>4096)&&(e.match_length=m-1)),e.prev_length>=m&&e.match_length<=e.prev_length){i=e.strstart+e.lookahead-m,n=o._tr_tally(e,e.strstart-1-e.prev_match,e.prev_length-m),e.lookahead-=e.prev_length-1,e.prev_length-=2;do{++e.strstart<=i&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+m-1])&e.hash_mask,r=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart)}while(0!=--e.prev_length);if(e.match_available=0,e.match_length=m-1,e.strstart++,n&&(D(e,!1),0===e.strm.avail_out))return 1}else if(e.match_available){if((n=o._tr_tally(e,0,e.window[e.strstart-1]))&&D(e,!1),e.strstart++,e.lookahead--,0===e.strm.avail_out)return 1}else e.match_available=1,e.strstart++,e.lookahead--}return e.match_available&&(n=o._tr_tally(e,0,e.window[e.strstart-1]),e.match_available=0),e.insert=e.strstart<m-1?e.strstart:m-1,4===t?(D(e,!0),0===e.strm.avail_out?3:4):e.last_lit&&(D(e,!1),0===e.strm.avail_out)?1:2}function q(e,t,r,n,i){this.good_length=e,this.max_lazy=t,this.nice_length=r,this.max_chain=n,this.func=i}function T(){this.strm=null,this.status=0,this.pending_buf=null,this.pending_buf_size=0,this.pending_out=0,this.pending=0,this.wrap=0,this.gzhead=null,this.gzindex=0,this.method=c,this.last_flush=-1,this.w_size=0,this.w_bits=0,this.w_mask=0,this.window=null,this.window_size=0,this.prev=null,this.head=null,this.ins_h=0,this.hash_size=0,this.hash_bits=0,this.hash_mask=0,this.hash_shift=0,this.block_start=0,this.match_length=0,this.prev_match=0,this.match_available=0,this.strstart=0,this.match_start=0,this.lookahead=0,this.prev_length=0,this.max_chain_length=0,this.max_lazy_match=0,this.level=0,this.strategy=0,this.good_match=0,this.nice_match=0,this.dyn_ltree=new i.Buf16(2*C),this.dyn_dtree=new i.Buf16(2*(2*g+1)),this.bl_tree=new i.Buf16(2*(2*p+1)),S(this.dyn_ltree),S(this.dyn_dtree),S(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new i.Buf16(I+1),this.heap=new i.Buf16(2*d+1),S(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new i.Buf16(2*d+1),S(this.depth),this.l_buf=0,this.lit_bufsize=0,this.last_lit=0,this.d_buf=0,this.opt_len=0,this.static_len=0,this.matches=0,this.insert=0,this.bi_buf=0,this.bi_valid=0}function P(e){var t;return e&&e.state?(e.total_in=e.total_out=0,e.data_type=l,(t=e.state).pending=0,t.pending_out=0,t.wrap<0&&(t.wrap=-t.wrap),t.status=t.wrap?B:b,e.adler=2===t.wrap?0:1,t.last_flush=f,o._tr_init(t),h):v(e,u)}function O(e){var t,r=P(e);return r===h&&((t=e.state).window_size=2*t.w_size,S(t.head),t.max_lazy_match=n[t.level].max_lazy,t.good_match=n[t.level].good_length,t.nice_match=n[t.level].nice_length,t.max_chain_length=n[t.level].max_chain,t.strstart=0,t.block_start=0,t.lookahead=0,t.insert=0,t.match_length=t.prev_length=m-1,t.match_available=0,t.ins_h=0),r}function z(e,t,r,n,o,s){if(!e)return u;var a=1;if(-1===t&&(t=6),n<0?(a=0,n=-n):n>15&&(a=2,n-=16),o<1||o>9||r!==c||n<8||n>15||t<0||t>9||s<0||s>4)return v(e,u);8===n&&(n=9);var A=new T;return e.state=A,A.strm=e,A.wrap=a,A.gzhead=null,A.w_bits=n,A.w_size=1<<A.w_bits,A.w_mask=A.w_size-1,A.hash_bits=o+7,A.hash_size=1<<A.hash_bits,A.hash_mask=A.hash_size-1,A.hash_shift=~~((A.hash_bits+m-1)/m),A.window=new i.Buf8(2*A.w_size),A.head=new i.Buf16(A.hash_size),A.prev=new i.Buf16(A.w_size),A.lit_bufsize=1<<o+6,A.pending_buf_size=4*A.lit_bufsize,A.pending_buf=new i.Buf8(A.pending_buf_size),A.d_buf=1*A.lit_bufsize,A.l_buf=3*A.lit_bufsize,A.level=t,A.strategy=s,A.method=r,O(e)}n=[new q(0,0,0,0,(function(e,t){var r=65535;for(r>e.pending_buf_size-5&&(r=e.pending_buf_size-5);;){if(e.lookahead<=1){if(x(e),0===e.lookahead&&t===f)return 1;if(0===e.lookahead)break}e.strstart+=e.lookahead,e.lookahead=0;var n=e.block_start+r;if((0===e.strstart||e.strstart>=n)&&(e.lookahead=e.strstart-n,e.strstart=n,D(e,!1),0===e.strm.avail_out))return 1;if(e.strstart-e.block_start>=e.w_size-w&&(D(e,!1),0===e.strm.avail_out))return 1}return e.insert=0,4===t?(D(e,!0),0===e.strm.avail_out?3:4):(e.strstart>e.block_start&&(D(e,!1),e.strm.avail_out),1)})),new q(4,4,8,4,L),new q(4,5,16,8,L),new q(4,6,32,32,L),new q(4,4,16,16,U),new q(8,16,32,32,U),new q(8,16,128,128,U),new q(8,32,128,256,U),new q(32,128,258,1024,U),new q(32,258,258,4096,U)],t.deflateInit=function(e,t){return z(e,t,c,15,8,0)},t.deflateInit2=z,t.deflateReset=O,t.deflateResetKeep=P,t.deflateSetHeader=function(e,t){return e&&e.state?2!==e.state.wrap?u:(e.state.gzhead=t,h):u},t.deflate=function(e,t){var r,i,s,A;if(!e||!e.state||t>5||t<0)return e?v(e,u):u;if(i=e.state,!e.output||!e.input&&0!==e.avail_in||i.status===_&&4!==t)return v(e,0===e.avail_out?-5:u);if(i.strm=e,r=i.last_flush,i.last_flush=t,i.status===B)if(2===i.wrap)e.adler=0,R(i,31),R(i,139),R(i,8),i.gzhead?(R(i,(i.gzhead.text?1:0)+(i.gzhead.hcrc?2:0)+(i.gzhead.extra?4:0)+(i.gzhead.name?8:0)+(i.gzhead.comment?16:0)),R(i,255&i.gzhead.time),R(i,i.gzhead.time>>8&255),R(i,i.gzhead.time>>16&255),R(i,i.gzhead.time>>24&255),R(i,9===i.level?2:i.strategy>=2||i.level<2?4:0),R(i,255&i.gzhead.os),i.gzhead.extra&&i.gzhead.extra.length&&(R(i,255&i.gzhead.extra.length),R(i,i.gzhead.extra.length>>8&255)),i.gzhead.hcrc&&(e.adler=a(e.adler,i.pending_buf,i.pending,0)),i.gzindex=0,i.status=69):(R(i,0),R(i,0),R(i,0),R(i,0),R(i,0),R(i,9===i.level?2:i.strategy>=2||i.level<2?4:0),R(i,3),i.status=b);else{var l=c+(i.w_bits-8<<4)<<8;l|=(i.strategy>=2||i.level<2?0:i.level<6?1:6===i.level?2:3)<<6,0!==i.strstart&&(l|=32),l+=31-l%31,i.status=b,N(i,l),0!==i.strstart&&(N(i,e.adler>>>16),N(i,65535&e.adler)),e.adler=1}if(69===i.status)if(i.gzhead.extra){for(s=i.pending;i.gzindex<(65535&i.gzhead.extra.length)&&(i.pending!==i.pending_buf_size||(i.gzhead.hcrc&&i.pending>s&&(e.adler=a(e.adler,i.pending_buf,i.pending-s,s)),k(e),s=i.pending,i.pending!==i.pending_buf_size));)R(i,255&i.gzhead.extra[i.gzindex]),i.gzindex++;i.gzhead.hcrc&&i.pending>s&&(e.adler=a(e.adler,i.pending_buf,i.pending-s,s)),i.gzindex===i.gzhead.extra.length&&(i.gzindex=0,i.status=73)}else i.status=73;if(73===i.status)if(i.gzhead.name){s=i.pending;do{if(i.pending===i.pending_buf_size&&(i.gzhead.hcrc&&i.pending>s&&(e.adler=a(e.adler,i.pending_buf,i.pending-s,s)),k(e),s=i.pending,i.pending===i.pending_buf_size)){A=1;break}A=i.gzindex<i.gzhead.name.length?255&i.gzhead.name.charCodeAt(i.gzindex++):0,R(i,A)}while(0!==A);i.gzhead.hcrc&&i.pending>s&&(e.adler=a(e.adler,i.pending_buf,i.pending-s,s)),0===A&&(i.gzindex=0,i.status=91)}else i.status=91;if(91===i.status)if(i.gzhead.comment){s=i.pending;do{if(i.pending===i.pending_buf_size&&(i.gzhead.hcrc&&i.pending>s&&(e.adler=a(e.adler,i.pending_buf,i.pending-s,s)),k(e),s=i.pending,i.pending===i.pending_buf_size)){A=1;break}A=i.gzindex<i.gzhead.comment.length?255&i.gzhead.comment.charCodeAt(i.gzindex++):0,R(i,A)}while(0!==A);i.gzhead.hcrc&&i.pending>s&&(e.adler=a(e.adler,i.pending_buf,i.pending-s,s)),0===A&&(i.status=E)}else i.status=E;if(i.status===E&&(i.gzhead.hcrc?(i.pending+2>i.pending_buf_size&&k(e),i.pending+2<=i.pending_buf_size&&(R(i,255&e.adler),R(i,e.adler>>8&255),e.adler=0,i.status=b)):i.status=b),0!==i.pending){if(k(e),0===e.avail_out)return i.last_flush=-1,h}else if(0===e.avail_in&&Q(t)<=Q(r)&&4!==t)return v(e,-5);if(i.status===_&&0!==e.avail_in)return v(e,-5);if(0!==e.avail_in||0!==i.lookahead||t!==f&&i.status!==_){var d=2===i.strategy?function(e,t){for(var r;;){if(0===e.lookahead&&(x(e),0===e.lookahead)){if(t===f)return 1;break}if(e.match_length=0,r=o._tr_tally(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++,r&&(D(e,!1),0===e.strm.avail_out))return 1}return e.insert=0,4===t?(D(e,!0),0===e.strm.avail_out?3:4):e.last_lit&&(D(e,!1),0===e.strm.avail_out)?1:2}(i,t):3===i.strategy?function(e,t){for(var r,n,i,s,a=e.window;;){if(e.lookahead<=y){if(x(e),e.lookahead<=y&&t===f)return 1;if(0===e.lookahead)break}if(e.match_length=0,e.lookahead>=m&&e.strstart>0&&(n=a[i=e.strstart-1])===a[++i]&&n===a[++i]&&n===a[++i]){s=e.strstart+y;do{}while(n===a[++i]&&n===a[++i]&&n===a[++i]&&n===a[++i]&&n===a[++i]&&n===a[++i]&&n===a[++i]&&n===a[++i]&&i<s);e.match_length=y-(s-i),e.match_length>e.lookahead&&(e.match_length=e.lookahead)}if(e.match_length>=m?(r=o._tr_tally(e,1,e.match_length-m),e.lookahead-=e.match_length,e.strstart+=e.match_length,e.match_length=0):(r=o._tr_tally(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++),r&&(D(e,!1),0===e.strm.avail_out))return 1}return e.insert=0,4===t?(D(e,!0),0===e.strm.avail_out?3:4):e.last_lit&&(D(e,!1),0===e.strm.avail_out)?1:2}(i,t):n[i.level].func(i,t);if(3!==d&&4!==d||(i.status=_),1===d||3===d)return 0===e.avail_out&&(i.last_flush=-1),h;if(2===d&&(1===t?o._tr_align(i):5!==t&&(o._tr_stored_block(i,0,0,!1),3===t&&(S(i.head),0===i.lookahead&&(i.strstart=0,i.block_start=0,i.insert=0))),k(e),0===e.avail_out))return i.last_flush=-1,h}return 4!==t?h:i.wrap<=0?1:(2===i.wrap?(R(i,255&e.adler),R(i,e.adler>>8&255),R(i,e.adler>>16&255),R(i,e.adler>>24&255),R(i,255&e.total_in),R(i,e.total_in>>8&255),R(i,e.total_in>>16&255),R(i,e.total_in>>24&255)):(N(i,e.adler>>>16),N(i,65535&e.adler)),k(e),i.wrap>0&&(i.wrap=-i.wrap),0!==i.pending?h:1)},t.deflateEnd=function(e){var t;return e&&e.state?(t=e.state.status)!==B&&69!==t&&73!==t&&91!==t&&t!==E&&t!==b&&t!==_?v(e,u):(e.state=null,t===b?v(e,-3):h):u},t.deflateSetDictionary=function(e,t){var r,n,o,a,A,f,l,c,d=t.length;if(!e||!e.state)return u;if(2===(a=(r=e.state).wrap)||1===a&&r.status!==B||r.lookahead)return u;for(1===a&&(e.adler=s(e.adler,t,d,0)),r.wrap=0,d>=r.w_size&&(0===a&&(S(r.head),r.strstart=0,r.block_start=0,r.insert=0),c=new i.Buf8(r.w_size),i.arraySet(c,t,d-r.w_size,r.w_size,0),t=c,d=r.w_size),A=e.avail_in,f=e.next_in,l=e.input,e.avail_in=d,e.next_in=0,e.input=t,x(r);r.lookahead>=m;){n=r.strstart,o=r.lookahead-(m-1);do{r.ins_h=(r.ins_h<<r.hash_shift^r.window[n+m-1])&r.hash_mask,r.prev[n&r.w_mask]=r.head[r.ins_h],r.head[r.ins_h]=n,n++}while(--o);r.strstart=n,r.lookahead=m-1,x(r)}return r.strstart+=r.lookahead,r.block_start=r.strstart,r.insert=r.lookahead,r.lookahead=0,r.match_length=r.prev_length=m-1,r.match_available=0,e.next_in=f,e.input=l,e.avail_in=A,r.wrap=a,h},t.deflateInfo="pako deflate (from Nodeca project)"},7414:e=>{"use strict";e.exports=function(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1}},7293:e=>{"use strict";e.exports=function(e,t){var r,n,i,o,s,a,A,f,h,u,l,c,d,g,p,C,I,m,y,w,B,E,b,_,v;r=e.state,n=e.next_in,_=e.input,i=n+(e.avail_in-5),o=e.next_out,v=e.output,s=o-(t-e.avail_out),a=o+(e.avail_out-257),A=r.dmax,f=r.wsize,h=r.whave,u=r.wnext,l=r.window,c=r.hold,d=r.bits,g=r.lencode,p=r.distcode,C=(1<<r.lenbits)-1,I=(1<<r.distbits)-1;e:do{d<15&&(c+=_[n++]<<d,d+=8,c+=_[n++]<<d,d+=8),m=g[c&C];t:for(;;){if(c>>>=y=m>>>24,d-=y,0==(y=m>>>16&255))v[o++]=65535&m;else{if(!(16&y)){if(64&y){if(32&y){r.mode=12;break e}e.msg="invalid literal/length code",r.mode=30;break e}m=g[(65535&m)+(c&(1<<y)-1)];continue t}for(w=65535&m,(y&=15)&&(d<y&&(c+=_[n++]<<d,d+=8),w+=c&(1<<y)-1,c>>>=y,d-=y),d<15&&(c+=_[n++]<<d,d+=8,c+=_[n++]<<d,d+=8),m=p[c&I];;){if(c>>>=y=m>>>24,d-=y,16&(y=m>>>16&255)){if(B=65535&m,d<(y&=15)&&(c+=_[n++]<<d,(d+=8)<y&&(c+=_[n++]<<d,d+=8)),(B+=c&(1<<y)-1)>A){e.msg="invalid distance too far back",r.mode=30;break e}if(c>>>=y,d-=y,B>(y=o-s)){if((y=B-y)>h&&r.sane){e.msg="invalid distance too far back",r.mode=30;break e}if(E=0,b=l,0===u){if(E+=f-y,y<w){w-=y;do{v[o++]=l[E++]}while(--y);E=o-B,b=v}}else if(u<y){if(E+=f+u-y,(y-=u)<w){w-=y;do{v[o++]=l[E++]}while(--y);if(E=0,u<w){w-=y=u;do{v[o++]=l[E++]}while(--y);E=o-B,b=v}}}else if(E+=u-y,y<w){w-=y;do{v[o++]=l[E++]}while(--y);E=o-B,b=v}for(;w>2;)v[o++]=b[E++],v[o++]=b[E++],v[o++]=b[E++],w-=3;w&&(v[o++]=b[E++],w>1&&(v[o++]=b[E++]))}else{E=o-B;do{v[o++]=v[E++],v[o++]=v[E++],v[o++]=v[E++],w-=3}while(w>2);w&&(v[o++]=v[E++],w>1&&(v[o++]=v[E++]))}break}if(64&y){e.msg="invalid distance code",r.mode=30;break e}m=p[(65535&m)+(c&(1<<y)-1)]}}break}}while(n<i&&o<a);n-=w=d>>3,c&=(1<<(d-=w<<3))-1,e.next_in=n,e.next_out=o,e.avail_in=n<i?i-n+5:5-(n-i),e.avail_out=o<a?a-o+257:257-(o-a),r.hold=c,r.bits=d}},1447:(e,t,r)=>{"use strict";var n=r(9805),i=r(3269),o=r(4823),s=r(7293),a=r(1998),A=0,f=-2,h=1,u=12,l=30,c=852,d=592;function g(e){return(e>>>24&255)+(e>>>8&65280)+((65280&e)<<8)+((255&e)<<24)}function p(){this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new n.Buf16(320),this.work=new n.Buf16(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}function C(e){var t;return e&&e.state?(t=e.state,e.total_in=e.total_out=t.total=0,e.msg="",t.wrap&&(e.adler=1&t.wrap),t.mode=h,t.last=0,t.havedict=0,t.dmax=32768,t.head=null,t.hold=0,t.bits=0,t.lencode=t.lendyn=new n.Buf32(c),t.distcode=t.distdyn=new n.Buf32(d),t.sane=1,t.back=-1,A):f}function I(e){var t;return e&&e.state?((t=e.state).wsize=0,t.whave=0,t.wnext=0,C(e)):f}function m(e,t){var r,n;return e&&e.state?(n=e.state,t<0?(r=0,t=-t):(r=1+(t>>4),t<48&&(t&=15)),t&&(t<8||t>15)?f:(null!==n.window&&n.wbits!==t&&(n.window=null),n.wrap=r,n.wbits=t,I(e))):f}function y(e,t){var r,n;return e?(n=new p,e.state=n,n.window=null,(r=m(e,t))!==A&&(e.state=null),r):f}var w,B,E=!0;function b(e){if(E){var t;for(w=new n.Buf32(512),B=new n.Buf32(32),t=0;t<144;)e.lens[t++]=8;for(;t<256;)e.lens[t++]=9;for(;t<280;)e.lens[t++]=7;for(;t<288;)e.lens[t++]=8;for(a(1,e.lens,0,288,w,0,e.work,{bits:9}),t=0;t<32;)e.lens[t++]=5;a(2,e.lens,0,32,B,0,e.work,{bits:5}),E=!1}e.lencode=w,e.lenbits=9,e.distcode=B,e.distbits=5}function _(e,t,r,i){var o,s=e.state;return null===s.window&&(s.wsize=1<<s.wbits,s.wnext=0,s.whave=0,s.window=new n.Buf8(s.wsize)),i>=s.wsize?(n.arraySet(s.window,t,r-s.wsize,s.wsize,0),s.wnext=0,s.whave=s.wsize):((o=s.wsize-s.wnext)>i&&(o=i),n.arraySet(s.window,t,r-i,o,s.wnext),(i-=o)?(n.arraySet(s.window,t,r-i,i,0),s.wnext=i,s.whave=s.wsize):(s.wnext+=o,s.wnext===s.wsize&&(s.wnext=0),s.whave<s.wsize&&(s.whave+=o))),0}t.inflateReset=I,t.inflateReset2=m,t.inflateResetKeep=C,t.inflateInit=function(e){return y(e,15)},t.inflateInit2=y,t.inflate=function(e,t){var r,c,d,p,C,I,m,y,w,B,E,v,Q,S,k,D,R,N,F,M,x,L,U,q,T=0,P=new n.Buf8(4),O=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!e||!e.state||!e.output||!e.input&&0!==e.avail_in)return f;(r=e.state).mode===u&&(r.mode=13),C=e.next_out,d=e.output,m=e.avail_out,p=e.next_in,c=e.input,I=e.avail_in,y=r.hold,w=r.bits,B=I,E=m,L=A;e:for(;;)switch(r.mode){case h:if(0===r.wrap){r.mode=13;break}for(;w<16;){if(0===I)break e;I--,y+=c[p++]<<w,w+=8}if(2&r.wrap&&35615===y){r.check=0,P[0]=255&y,P[1]=y>>>8&255,r.check=o(r.check,P,2,0),y=0,w=0,r.mode=2;break}if(r.flags=0,r.head&&(r.head.done=!1),!(1&r.wrap)||(((255&y)<<8)+(y>>8))%31){e.msg="incorrect header check",r.mode=l;break}if(8!=(15&y)){e.msg="unknown compression method",r.mode=l;break}if(w-=4,x=8+(15&(y>>>=4)),0===r.wbits)r.wbits=x;else if(x>r.wbits){e.msg="invalid window size",r.mode=l;break}r.dmax=1<<x,e.adler=r.check=1,r.mode=512&y?10:u,y=0,w=0;break;case 2:for(;w<16;){if(0===I)break e;I--,y+=c[p++]<<w,w+=8}if(r.flags=y,8!=(255&r.flags)){e.msg="unknown compression method",r.mode=l;break}if(57344&r.flags){e.msg="unknown header flags set",r.mode=l;break}r.head&&(r.head.text=y>>8&1),512&r.flags&&(P[0]=255&y,P[1]=y>>>8&255,r.check=o(r.check,P,2,0)),y=0,w=0,r.mode=3;case 3:for(;w<32;){if(0===I)break e;I--,y+=c[p++]<<w,w+=8}r.head&&(r.head.time=y),512&r.flags&&(P[0]=255&y,P[1]=y>>>8&255,P[2]=y>>>16&255,P[3]=y>>>24&255,r.check=o(r.check,P,4,0)),y=0,w=0,r.mode=4;case 4:for(;w<16;){if(0===I)break e;I--,y+=c[p++]<<w,w+=8}r.head&&(r.head.xflags=255&y,r.head.os=y>>8),512&r.flags&&(P[0]=255&y,P[1]=y>>>8&255,r.check=o(r.check,P,2,0)),y=0,w=0,r.mode=5;case 5:if(1024&r.flags){for(;w<16;){if(0===I)break e;I--,y+=c[p++]<<w,w+=8}r.length=y,r.head&&(r.head.extra_len=y),512&r.flags&&(P[0]=255&y,P[1]=y>>>8&255,r.check=o(r.check,P,2,0)),y=0,w=0}else r.head&&(r.head.extra=null);r.mode=6;case 6:if(1024&r.flags&&((v=r.length)>I&&(v=I),v&&(r.head&&(x=r.head.extra_len-r.length,r.head.extra||(r.head.extra=new Array(r.head.extra_len)),n.arraySet(r.head.extra,c,p,v,x)),512&r.flags&&(r.check=o(r.check,c,v,p)),I-=v,p+=v,r.length-=v),r.length))break e;r.length=0,r.mode=7;case 7:if(2048&r.flags){if(0===I)break e;v=0;do{x=c[p+v++],r.head&&x&&r.length<65536&&(r.head.name+=String.fromCharCode(x))}while(x&&v<I);if(512&r.flags&&(r.check=o(r.check,c,v,p)),I-=v,p+=v,x)break e}else r.head&&(r.head.name=null);r.length=0,r.mode=8;case 8:if(4096&r.flags){if(0===I)break e;v=0;do{x=c[p+v++],r.head&&x&&r.length<65536&&(r.head.comment+=String.fromCharCode(x))}while(x&&v<I);if(512&r.flags&&(r.check=o(r.check,c,v,p)),I-=v,p+=v,x)break e}else r.head&&(r.head.comment=null);r.mode=9;case 9:if(512&r.flags){for(;w<16;){if(0===I)break e;I--,y+=c[p++]<<w,w+=8}if(y!==(65535&r.check)){e.msg="header crc mismatch",r.mode=l;break}y=0,w=0}r.head&&(r.head.hcrc=r.flags>>9&1,r.head.done=!0),e.adler=r.check=0,r.mode=u;break;case 10:for(;w<32;){if(0===I)break e;I--,y+=c[p++]<<w,w+=8}e.adler=r.check=g(y),y=0,w=0,r.mode=11;case 11:if(0===r.havedict)return e.next_out=C,e.avail_out=m,e.next_in=p,e.avail_in=I,r.hold=y,r.bits=w,2;e.adler=r.check=1,r.mode=u;case u:if(5===t||6===t)break e;case 13:if(r.last){y>>>=7&w,w-=7&w,r.mode=27;break}for(;w<3;){if(0===I)break e;I--,y+=c[p++]<<w,w+=8}switch(r.last=1&y,w-=1,3&(y>>>=1)){case 0:r.mode=14;break;case 1:if(b(r),r.mode=20,6===t){y>>>=2,w-=2;break e}break;case 2:r.mode=17;break;case 3:e.msg="invalid block type",r.mode=l}y>>>=2,w-=2;break;case 14:for(y>>>=7&w,w-=7&w;w<32;){if(0===I)break e;I--,y+=c[p++]<<w,w+=8}if((65535&y)!=(y>>>16^65535)){e.msg="invalid stored block lengths",r.mode=l;break}if(r.length=65535&y,y=0,w=0,r.mode=15,6===t)break e;case 15:r.mode=16;case 16:if(v=r.length){if(v>I&&(v=I),v>m&&(v=m),0===v)break e;n.arraySet(d,c,p,v,C),I-=v,p+=v,m-=v,C+=v,r.length-=v;break}r.mode=u;break;case 17:for(;w<14;){if(0===I)break e;I--,y+=c[p++]<<w,w+=8}if(r.nlen=257+(31&y),y>>>=5,w-=5,r.ndist=1+(31&y),y>>>=5,w-=5,r.ncode=4+(15&y),y>>>=4,w-=4,r.nlen>286||r.ndist>30){e.msg="too many length or distance symbols",r.mode=l;break}r.have=0,r.mode=18;case 18:for(;r.have<r.ncode;){for(;w<3;){if(0===I)break e;I--,y+=c[p++]<<w,w+=8}r.lens[O[r.have++]]=7&y,y>>>=3,w-=3}for(;r.have<19;)r.lens[O[r.have++]]=0;if(r.lencode=r.lendyn,r.lenbits=7,U={bits:r.lenbits},L=a(0,r.lens,0,19,r.lencode,0,r.work,U),r.lenbits=U.bits,L){e.msg="invalid code lengths set",r.mode=l;break}r.have=0,r.mode=19;case 19:for(;r.have<r.nlen+r.ndist;){for(;D=(T=r.lencode[y&(1<<r.lenbits)-1])>>>16&255,R=65535&T,!((k=T>>>24)<=w);){if(0===I)break e;I--,y+=c[p++]<<w,w+=8}if(R<16)y>>>=k,w-=k,r.lens[r.have++]=R;else{if(16===R){for(q=k+2;w<q;){if(0===I)break e;I--,y+=c[p++]<<w,w+=8}if(y>>>=k,w-=k,0===r.have){e.msg="invalid bit length repeat",r.mode=l;break}x=r.lens[r.have-1],v=3+(3&y),y>>>=2,w-=2}else if(17===R){for(q=k+3;w<q;){if(0===I)break e;I--,y+=c[p++]<<w,w+=8}w-=k,x=0,v=3+(7&(y>>>=k)),y>>>=3,w-=3}else{for(q=k+7;w<q;){if(0===I)break e;I--,y+=c[p++]<<w,w+=8}w-=k,x=0,v=11+(127&(y>>>=k)),y>>>=7,w-=7}if(r.have+v>r.nlen+r.ndist){e.msg="invalid bit length repeat",r.mode=l;break}for(;v--;)r.lens[r.have++]=x}}if(r.mode===l)break;if(0===r.lens[256]){e.msg="invalid code -- missing end-of-block",r.mode=l;break}if(r.lenbits=9,U={bits:r.lenbits},L=a(1,r.lens,0,r.nlen,r.lencode,0,r.work,U),r.lenbits=U.bits,L){e.msg="invalid literal/lengths set",r.mode=l;break}if(r.distbits=6,r.distcode=r.distdyn,U={bits:r.distbits},L=a(2,r.lens,r.nlen,r.ndist,r.distcode,0,r.work,U),r.distbits=U.bits,L){e.msg="invalid distances set",r.mode=l;break}if(r.mode=20,6===t)break e;case 20:r.mode=21;case 21:if(I>=6&&m>=258){e.next_out=C,e.avail_out=m,e.next_in=p,e.avail_in=I,r.hold=y,r.bits=w,s(e,E),C=e.next_out,d=e.output,m=e.avail_out,p=e.next_in,c=e.input,I=e.avail_in,y=r.hold,w=r.bits,r.mode===u&&(r.back=-1);break}for(r.back=0;D=(T=r.lencode[y&(1<<r.lenbits)-1])>>>16&255,R=65535&T,!((k=T>>>24)<=w);){if(0===I)break e;I--,y+=c[p++]<<w,w+=8}if(D&&!(240&D)){for(N=k,F=D,M=R;D=(T=r.lencode[M+((y&(1<<N+F)-1)>>N)])>>>16&255,R=65535&T,!(N+(k=T>>>24)<=w);){if(0===I)break e;I--,y+=c[p++]<<w,w+=8}y>>>=N,w-=N,r.back+=N}if(y>>>=k,w-=k,r.back+=k,r.length=R,0===D){r.mode=26;break}if(32&D){r.back=-1,r.mode=u;break}if(64&D){e.msg="invalid literal/length code",r.mode=l;break}r.extra=15&D,r.mode=22;case 22:if(r.extra){for(q=r.extra;w<q;){if(0===I)break e;I--,y+=c[p++]<<w,w+=8}r.length+=y&(1<<r.extra)-1,y>>>=r.extra,w-=r.extra,r.back+=r.extra}r.was=r.length,r.mode=23;case 23:for(;D=(T=r.distcode[y&(1<<r.distbits)-1])>>>16&255,R=65535&T,!((k=T>>>24)<=w);){if(0===I)break e;I--,y+=c[p++]<<w,w+=8}if(!(240&D)){for(N=k,F=D,M=R;D=(T=r.distcode[M+((y&(1<<N+F)-1)>>N)])>>>16&255,R=65535&T,!(N+(k=T>>>24)<=w);){if(0===I)break e;I--,y+=c[p++]<<w,w+=8}y>>>=N,w-=N,r.back+=N}if(y>>>=k,w-=k,r.back+=k,64&D){e.msg="invalid distance code",r.mode=l;break}r.offset=R,r.extra=15&D,r.mode=24;case 24:if(r.extra){for(q=r.extra;w<q;){if(0===I)break e;I--,y+=c[p++]<<w,w+=8}r.offset+=y&(1<<r.extra)-1,y>>>=r.extra,w-=r.extra,r.back+=r.extra}if(r.offset>r.dmax){e.msg="invalid distance too far back",r.mode=l;break}r.mode=25;case 25:if(0===m)break e;if(v=E-m,r.offset>v){if((v=r.offset-v)>r.whave&&r.sane){e.msg="invalid distance too far back",r.mode=l;break}v>r.wnext?(v-=r.wnext,Q=r.wsize-v):Q=r.wnext-v,v>r.length&&(v=r.length),S=r.window}else S=d,Q=C-r.offset,v=r.length;v>m&&(v=m),m-=v,r.length-=v;do{d[C++]=S[Q++]}while(--v);0===r.length&&(r.mode=21);break;case 26:if(0===m)break e;d[C++]=r.length,m--,r.mode=21;break;case 27:if(r.wrap){for(;w<32;){if(0===I)break e;I--,y|=c[p++]<<w,w+=8}if(E-=m,e.total_out+=E,r.total+=E,E&&(e.adler=r.check=r.flags?o(r.check,d,E,C-E):i(r.check,d,E,C-E)),E=m,(r.flags?y:g(y))!==r.check){e.msg="incorrect data check",r.mode=l;break}y=0,w=0}r.mode=28;case 28:if(r.wrap&&r.flags){for(;w<32;){if(0===I)break e;I--,y+=c[p++]<<w,w+=8}if(y!==(4294967295&r.total)){e.msg="incorrect length check",r.mode=l;break}y=0,w=0}r.mode=29;case 29:L=1;break e;case l:L=-3;break e;case 31:return-4;default:return f}return e.next_out=C,e.avail_out=m,e.next_in=p,e.avail_in=I,r.hold=y,r.bits=w,(r.wsize||E!==e.avail_out&&r.mode<l&&(r.mode<27||4!==t))&&_(e,e.output,e.next_out,E-e.avail_out)?(r.mode=31,-4):(B-=e.avail_in,E-=e.avail_out,e.total_in+=B,e.total_out+=E,r.total+=E,r.wrap&&E&&(e.adler=r.check=r.flags?o(r.check,d,E,e.next_out-E):i(r.check,d,E,e.next_out-E)),e.data_type=r.bits+(r.last?64:0)+(r.mode===u?128:0)+(20===r.mode||15===r.mode?256:0),(0===B&&0===E||4===t)&&L===A&&(L=-5),L)},t.inflateEnd=function(e){if(!e||!e.state)return f;var t=e.state;return t.window&&(t.window=null),e.state=null,A},t.inflateGetHeader=function(e,t){var r;return e&&e.state&&2&(r=e.state).wrap?(r.head=t,t.done=!1,A):f},t.inflateSetDictionary=function(e,t){var r,n=t.length;return e&&e.state?0!==(r=e.state).wrap&&11!==r.mode?f:11===r.mode&&i(1,t,n,0)!==r.check?-3:_(e,t,n,n)?(r.mode=31,-4):(r.havedict=1,A):f},t.inflateInfo="pako inflate (from Nodeca project)"},1998:(e,t,r)=>{"use strict";var n=r(9805),i=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0],o=[16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78],s=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0],a=[16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64];e.exports=function(e,t,r,A,f,h,u,l){var c,d,g,p,C,I,m,y,w,B=l.bits,E=0,b=0,_=0,v=0,Q=0,S=0,k=0,D=0,R=0,N=0,F=null,M=0,x=new n.Buf16(16),L=new n.Buf16(16),U=null,q=0;for(E=0;E<=15;E++)x[E]=0;for(b=0;b<A;b++)x[t[r+b]]++;for(Q=B,v=15;v>=1&&0===x[v];v--);if(Q>v&&(Q=v),0===v)return f[h++]=20971520,f[h++]=20971520,l.bits=1,0;for(_=1;_<v&&0===x[_];_++);for(Q<_&&(Q=_),D=1,E=1;E<=15;E++)if(D<<=1,(D-=x[E])<0)return-1;if(D>0&&(0===e||1!==v))return-1;for(L[1]=0,E=1;E<15;E++)L[E+1]=L[E]+x[E];for(b=0;b<A;b++)0!==t[r+b]&&(u[L[t[r+b]]++]=b);if(0===e?(F=U=u,I=19):1===e?(F=i,M-=257,U=o,q-=257,I=256):(F=s,U=a,I=-1),N=0,b=0,E=_,C=h,S=Q,k=0,g=-1,p=(R=1<<Q)-1,1===e&&R>852||2===e&&R>592)return 1;for(;;){m=E-k,u[b]<I?(y=0,w=u[b]):u[b]>I?(y=U[q+u[b]],w=F[M+u[b]]):(y=96,w=0),c=1<<E-k,_=d=1<<S;do{f[C+(N>>k)+(d-=c)]=m<<24|y<<16|w}while(0!==d);for(c=1<<E-1;N&c;)c>>=1;if(0!==c?(N&=c-1,N+=c):N=0,b++,0==--x[E]){if(E===v)break;E=t[r+u[b]]}if(E>Q&&(N&p)!==g){for(0===k&&(k=Q),C+=_,D=1<<(S=E-k);S+k<v&&!((D-=x[S+k])<=0);)S++,D<<=1;if(R+=1<<S,1===e&&R>852||2===e&&R>592)return 1;f[g=N&p]=Q<<24|S<<16|C-h}}return 0!==N&&(f[C+N]=E-k<<24|64<<16),l.bits=Q,0}},4674:e=>{"use strict";e.exports={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}},3665:(e,t,r)=>{"use strict";var n=r(9805);function i(e){for(var t=e.length;--t>=0;)e[t]=0}var o=256,s=286,a=30,A=15,f=16,h=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0],u=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],l=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],c=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],d=new Array(576);i(d);var g=new Array(60);i(g);var p=new Array(512);i(p);var C=new Array(256);i(C);var I=new Array(29);i(I);var m,y,w,B=new Array(a);function E(e,t,r,n,i){this.static_tree=e,this.extra_bits=t,this.extra_base=r,this.elems=n,this.max_length=i,this.has_stree=e&&e.length}function b(e,t){this.dyn_tree=e,this.max_code=0,this.stat_desc=t}function _(e){return e<256?p[e]:p[256+(e>>>7)]}function v(e,t){e.pending_buf[e.pending++]=255&t,e.pending_buf[e.pending++]=t>>>8&255}function Q(e,t,r){e.bi_valid>f-r?(e.bi_buf|=t<<e.bi_valid&65535,v(e,e.bi_buf),e.bi_buf=t>>f-e.bi_valid,e.bi_valid+=r-f):(e.bi_buf|=t<<e.bi_valid&65535,e.bi_valid+=r)}function S(e,t,r){Q(e,r[2*t],r[2*t+1])}function k(e,t){var r=0;do{r|=1&e,e>>>=1,r<<=1}while(--t>0);return r>>>1}function D(e,t,r){var n,i,o=new Array(A+1),s=0;for(n=1;n<=A;n++)o[n]=s=s+r[n-1]<<1;for(i=0;i<=t;i++){var a=e[2*i+1];0!==a&&(e[2*i]=k(o[a]++,a))}}function R(e){var t;for(t=0;t<s;t++)e.dyn_ltree[2*t]=0;for(t=0;t<a;t++)e.dyn_dtree[2*t]=0;for(t=0;t<19;t++)e.bl_tree[2*t]=0;e.dyn_ltree[512]=1,e.opt_len=e.static_len=0,e.last_lit=e.matches=0}function N(e){e.bi_valid>8?v(e,e.bi_buf):e.bi_valid>0&&(e.pending_buf[e.pending++]=e.bi_buf),e.bi_buf=0,e.bi_valid=0}function F(e,t,r,n){var i=2*t,o=2*r;return e[i]<e[o]||e[i]===e[o]&&n[t]<=n[r]}function M(e,t,r){for(var n=e.heap[r],i=r<<1;i<=e.heap_len&&(i<e.heap_len&&F(t,e.heap[i+1],e.heap[i],e.depth)&&i++,!F(t,n,e.heap[i],e.depth));)e.heap[r]=e.heap[i],r=i,i<<=1;e.heap[r]=n}function x(e,t,r){var n,i,s,a,A=0;if(0!==e.last_lit)do{n=e.pending_buf[e.d_buf+2*A]<<8|e.pending_buf[e.d_buf+2*A+1],i=e.pending_buf[e.l_buf+A],A++,0===n?S(e,i,t):(S(e,(s=C[i])+o+1,t),0!==(a=h[s])&&Q(e,i-=I[s],a),S(e,s=_(--n),r),0!==(a=u[s])&&Q(e,n-=B[s],a))}while(A<e.last_lit);S(e,256,t)}function L(e,t){var r,n,i,o=t.dyn_tree,s=t.stat_desc.static_tree,a=t.stat_desc.has_stree,f=t.stat_desc.elems,h=-1;for(e.heap_len=0,e.heap_max=573,r=0;r<f;r++)0!==o[2*r]?(e.heap[++e.heap_len]=h=r,e.depth[r]=0):o[2*r+1]=0;for(;e.heap_len<2;)o[2*(i=e.heap[++e.heap_len]=h<2?++h:0)]=1,e.depth[i]=0,e.opt_len--,a&&(e.static_len-=s[2*i+1]);for(t.max_code=h,r=e.heap_len>>1;r>=1;r--)M(e,o,r);i=f;do{r=e.heap[1],e.heap[1]=e.heap[e.heap_len--],M(e,o,1),n=e.heap[1],e.heap[--e.heap_max]=r,e.heap[--e.heap_max]=n,o[2*i]=o[2*r]+o[2*n],e.depth[i]=(e.depth[r]>=e.depth[n]?e.depth[r]:e.depth[n])+1,o[2*r+1]=o[2*n+1]=i,e.heap[1]=i++,M(e,o,1)}while(e.heap_len>=2);e.heap[--e.heap_max]=e.heap[1],function(e,t){var r,n,i,o,s,a,f=t.dyn_tree,h=t.max_code,u=t.stat_desc.static_tree,l=t.stat_desc.has_stree,c=t.stat_desc.extra_bits,d=t.stat_desc.extra_base,g=t.stat_desc.max_length,p=0;for(o=0;o<=A;o++)e.bl_count[o]=0;for(f[2*e.heap[e.heap_max]+1]=0,r=e.heap_max+1;r<573;r++)(o=f[2*f[2*(n=e.heap[r])+1]+1]+1)>g&&(o=g,p++),f[2*n+1]=o,n>h||(e.bl_count[o]++,s=0,n>=d&&(s=c[n-d]),a=f[2*n],e.opt_len+=a*(o+s),l&&(e.static_len+=a*(u[2*n+1]+s)));if(0!==p){do{for(o=g-1;0===e.bl_count[o];)o--;e.bl_count[o]--,e.bl_count[o+1]+=2,e.bl_count[g]--,p-=2}while(p>0);for(o=g;0!==o;o--)for(n=e.bl_count[o];0!==n;)(i=e.heap[--r])>h||(f[2*i+1]!==o&&(e.opt_len+=(o-f[2*i+1])*f[2*i],f[2*i+1]=o),n--)}}(e,t),D(o,h,e.bl_count)}function U(e,t,r){var n,i,o=-1,s=t[1],a=0,A=7,f=4;for(0===s&&(A=138,f=3),t[2*(r+1)+1]=65535,n=0;n<=r;n++)i=s,s=t[2*(n+1)+1],++a<A&&i===s||(a<f?e.bl_tree[2*i]+=a:0!==i?(i!==o&&e.bl_tree[2*i]++,e.bl_tree[32]++):a<=10?e.bl_tree[34]++:e.bl_tree[36]++,a=0,o=i,0===s?(A=138,f=3):i===s?(A=6,f=3):(A=7,f=4))}function q(e,t,r){var n,i,o=-1,s=t[1],a=0,A=7,f=4;for(0===s&&(A=138,f=3),n=0;n<=r;n++)if(i=s,s=t[2*(n+1)+1],!(++a<A&&i===s)){if(a<f)do{S(e,i,e.bl_tree)}while(0!=--a);else 0!==i?(i!==o&&(S(e,i,e.bl_tree),a--),S(e,16,e.bl_tree),Q(e,a-3,2)):a<=10?(S(e,17,e.bl_tree),Q(e,a-3,3)):(S(e,18,e.bl_tree),Q(e,a-11,7));a=0,o=i,0===s?(A=138,f=3):i===s?(A=6,f=3):(A=7,f=4)}}i(B);var T=!1;function P(e,t,r,i){Q(e,0+(i?1:0),3),function(e,t,r){N(e),v(e,r),v(e,~r),n.arraySet(e.pending_buf,e.window,t,r,e.pending),e.pending+=r}(e,t,r)}t._tr_init=function(e){T||(function(){var e,t,r,n,i,o=new Array(A+1);for(r=0,n=0;n<28;n++)for(I[n]=r,e=0;e<1<<h[n];e++)C[r++]=n;for(C[r-1]=n,i=0,n=0;n<16;n++)for(B[n]=i,e=0;e<1<<u[n];e++)p[i++]=n;for(i>>=7;n<a;n++)for(B[n]=i<<7,e=0;e<1<<u[n]-7;e++)p[256+i++]=n;for(t=0;t<=A;t++)o[t]=0;for(e=0;e<=143;)d[2*e+1]=8,e++,o[8]++;for(;e<=255;)d[2*e+1]=9,e++,o[9]++;for(;e<=279;)d[2*e+1]=7,e++,o[7]++;for(;e<=287;)d[2*e+1]=8,e++,o[8]++;for(D(d,287,o),e=0;e<a;e++)g[2*e+1]=5,g[2*e]=k(e,5);m=new E(d,h,257,s,A),y=new E(g,u,0,a,A),w=new E(new Array(0),l,0,19,7)}(),T=!0),e.l_desc=new b(e.dyn_ltree,m),e.d_desc=new b(e.dyn_dtree,y),e.bl_desc=new b(e.bl_tree,w),e.bi_buf=0,e.bi_valid=0,R(e)},t._tr_stored_block=P,t._tr_flush_block=function(e,t,r,n){var i,s,a=0;e.level>0?(2===e.strm.data_type&&(e.strm.data_type=function(e){var t,r=4093624447;for(t=0;t<=31;t++,r>>>=1)if(1&r&&0!==e.dyn_ltree[2*t])return 0;if(0!==e.dyn_ltree[18]||0!==e.dyn_ltree[20]||0!==e.dyn_ltree[26])return 1;for(t=32;t<o;t++)if(0!==e.dyn_ltree[2*t])return 1;return 0}(e)),L(e,e.l_desc),L(e,e.d_desc),a=function(e){var t;for(U(e,e.dyn_ltree,e.l_desc.max_code),U(e,e.dyn_dtree,e.d_desc.max_code),L(e,e.bl_desc),t=18;t>=3&&0===e.bl_tree[2*c[t]+1];t--);return e.opt_len+=3*(t+1)+5+5+4,t}(e),i=e.opt_len+3+7>>>3,(s=e.static_len+3+7>>>3)<=i&&(i=s)):i=s=r+5,r+4<=i&&-1!==t?P(e,t,r,n):4===e.strategy||s===i?(Q(e,2+(n?1:0),3),x(e,d,g)):(Q(e,4+(n?1:0),3),function(e,t,r,n){var i;for(Q(e,t-257,5),Q(e,r-1,5),Q(e,n-4,4),i=0;i<n;i++)Q(e,e.bl_tree[2*c[i]+1],3);q(e,e.dyn_ltree,t-1),q(e,e.dyn_dtree,r-1)}(e,e.l_desc.max_code+1,e.d_desc.max_code+1,a+1),x(e,e.dyn_ltree,e.dyn_dtree)),R(e),n&&N(e)},t._tr_tally=function(e,t,r){return e.pending_buf[e.d_buf+2*e.last_lit]=t>>>8&255,e.pending_buf[e.d_buf+2*e.last_lit+1]=255&t,e.pending_buf[e.l_buf+e.last_lit]=255&r,e.last_lit++,0===t?e.dyn_ltree[2*r]++:(e.matches++,t--,e.dyn_ltree[2*(C[r]+o+1)]++,e.dyn_dtree[2*_(t)]++),e.last_lit===e.lit_bufsize-1},t._tr_align=function(e){Q(e,2,3),S(e,256,d),function(e){16===e.bi_valid?(v(e,e.bi_buf),e.bi_buf=0,e.bi_valid=0):e.bi_valid>=8&&(e.pending_buf[e.pending++]=255&e.bi_buf,e.bi_buf>>=8,e.bi_valid-=8)}(e)}},4442:e=>{"use strict";e.exports=function(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}},7392:e=>{"use strict";class t{constructor(e={}){if(!(e.maxSize&&e.maxSize>0))throw new TypeError("`maxSize` must be a number greater than 0");this.maxSize=e.maxSize,this.cache=new Map,this.oldCache=new Map,this._size=0}_set(e,t){this.cache.set(e,t),this._size++,this._size>=this.maxSize&&(this._size=0,this.oldCache=this.cache,this.cache=new Map)}get(e){if(this.cache.has(e))return this.cache.get(e);if(this.oldCache.has(e)){const t=this.oldCache.get(e);return this.oldCache.delete(e),this._set(e,t),t}}set(e,t){return this.cache.has(e)?this.cache.set(e,t):this._set(e,t),this}has(e){return this.cache.has(e)||this.oldCache.has(e)}peek(e){return this.cache.has(e)?this.cache.get(e):this.oldCache.has(e)?this.oldCache.get(e):void 0}delete(e){const t=this.cache.delete(e);return t&&this._size--,this.oldCache.delete(e)||t}clear(){this.cache.clear(),this.oldCache.clear(),this._size=0}*keys(){for(const[e]of this)yield e}*values(){for(const[,e]of this)yield e}*[Symbol.iterator](){for(const e of this.cache)yield e;for(const e of this.oldCache){const[t]=e;this.cache.has(t)||(yield e)}}get size(){let e=0;for(const t of this.oldCache.keys())this.cache.has(t)||e++;return this._size+e}}e.exports=t},1307:function(e,t,r){var n;n=e=>(()=>{"use strict";var t=[,e=>{e.exports="data:application/wasm;base64,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IgENAAsLIAJCf4UL1RACDH8CfgJAAkAgACgCJEUNACAAKAIAIQIMAQtBACECIABBADoAKCAAQgA3AwAgAEIANwMYIABByABqQQBB5AAQhoCAgAAaIABBrAFqQQw2AgALIAAgASgCBCIDNgIQIABBsAFqIQQgAEHgAGohBSAAQcgAaiEGIABBtgFqIQcgAEGoAWohCCABKAIQIQkCQAJAAkACQANAAkACQAJAAkACQAJAAkACQAJAAkACQAJAAkACQAJAIAIOCgECAAQFBgcICQoPCyABKAIAIQogACgCqAEhAiAAKAKsASELIAEoAgQhDCABKAIIIQ0MAgsgCCAAKAKoASIMakEIaiABKAIAIAEoAgQiAmogASgCCCACayICIAAoAqwBIAxrIgwgAiAMSRsiAhCHgICAABogASABKAIEIAJqNgIEQQAhDCAAQQAgACgCqAEgAmoiAiACIAAoAqwBIgtGGzYCqAEgAiALRw0RIABBATYCAAJAIARBqIiAgABBBhCEgICAAEUNAEEFIQwMEgsgB0ECQQAQjYCAgAAgACgAuAFHDRBBBiEMIActAAANESAAIAAtALcBIgI2AiAgAkEESw0RQQEgAnRBE3FFDRELIAEoAgQiDCABKAIIIg1GDQ4CQCABKAIAIgogDGotAAAiCw0AIAAgDDYCECABIAxBAWo2AgRBBiECDAwLQQAhAiAAQQA2AqgBIABBAjYCACAAIAtBAnRBBGoiCzYCrAEgACALNgJACyAIIAJqQQhqIAogDGogDSAMayIMIAsgAmsiAiAMIAJJGyICEIeAgIAAGiABIAIgASgCBGo2AgRBACEMIABBACAAKAKoASACaiICIAIgACgCrAEiC0YbNgKoASACIAtHDQ8gACACQXxqIgI2AqwBQQchDCAEIAJBABCNgICAACAAIAAoAqwBIgtqQbABaigAAEcNDyAAQQI2AqgBIAAtALEBIgJBP3ENDAJAAkAgAkHAAHFFDQAgACAEIAggCxCRgICAAEEBRw0RIAAgACkDCDcDMCAALQCxASECDAELIABCfzcDMAtCfyEOAkAgAkEYdEEYdUF/Sg0AIAAgBCAIIAAoAqwBEJGAgIAAQQFHDRAgACkDCCEOCyAAIA43AzggACgCrAEiDSAAKAKoASICa0ECSQ0PIAAgAkEBaiIKNgKoASAIIAJqQQhq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IgM2AhAgACAOQQh0IAAoAgwgCWotAAByIg42AgQgAyEJCwJAAkAgDiALQQt2IA8vAQAiCmwiA08iEg0AIAAgAzYCACAKQYAQIAprQQV2aiEKDAELIAAgDiADayIONgIEIAAgCyADayIDNgIAIAogCkEFdmshCkEAIQ0LIA8gCjsBACANIBFzIQ0gBEEBdCASciIEQYACSQ0ACwsgACACQQFqNgIgIAAoAhggAmogBDoAAAJAIAAoAiQgACgCICICTw0AIAAgAjYCJAtBACEDAkAgACgCZCIEQQRJDQACQCAEQQlLDQAgBEF9aiEDDAELIARBemohAwsgACADNgJkDAELIAAgDiADayIONgIEIAAgBCADayIDNgIAIA0gDyAPQQV2azsBACAAIApBAXRqIg9B+ANqIQQCQAJAIANB////B00NACAJIQoMAQsgACADQQh0IgM2AgAgACAJQQFqIgo2AhAgACAOQQh0IAAoAgwgCWotAAByIg42AgQLAkACQCAOIANBC3YgBC8BACINbCIJSQ0AIAAgDiAJayIONgIEIAAgAyAJayIDNgIAIAQgDSANQQV2azsBACAPQZAEaiENAkACQCADQf///wdNDQAgCiEQDAELIAAgA0EIdCIDNgIAIAAgCkEBaiIQNgIQIAAgDkEIdCAAKAIMIApqLQAAciIONgIECwJAAkAgDiADQQt2IA0vAQAiCWwiBE8NACANIAlBgBAgCWtBBXZqOwEAIAxB2ARqIQMCQCAEQf///wdLDQAgACAEQQh0IgQ2AgAgACAQQQFqNgIQIAAgDkEIdCAAKAIMIBBqLQAAciIONgIECwJAIA4gBEELdiADLwEAIg1sIglJDQAgACAOIAlrNgIEIAAgBCAJazYCACADIA0gDUEFdms7AQAMAgsgAyANQYAQIA1rQQV2ajsBACAAIAk2AgAgAEEBNgJoIABBCUELIAAoAmRBB0kbNgJkDAMLIAAgDiAEayIONgIEIA0gCSAJQQV2azsBACAPQagEaiENAkACQCADIARrIgNB////B00NACAQIQoMAQsgACADQQh0IgM2AgAgACAQQQFqIgo2AhAgACAOQQh0IAAoAgwgEGotAAByIg42AgQLAkACQCAOIANBC3YgDS8BACIEbCIJTw0AIAAgCTYCACANIARBgBAgBGtBBXZqOwEAIAAoAlghAwwBCyAAIA4gCWsiDjYCBCANIAQgBEEFdms7AQAgD0HABGohBAJAIAMgCWsiA0H///8HSw0AIAAgA0EIdCIDNgIAIAAgCkEBajYCECAAIA5BCHQgACgCDCAKai0AAHIiDjYCBAsCQAJAIA4gA0ELdiAELwEAIg1sIglPDQAgACAJNgIAIAQgDUGAECANa0EFdmo7AQAgACgCXCEDDAELIAAgDiAJazYCBCAAIAMgCWs2AgAgACgCYCEDIAAgACgCXDYCYCAEIA0gDUEFdms7AQALIAAgACgCWDYCXAsgACAAKAJUNgJYIAAgAzYCVAsgAEEIQQsgACgCZEEHSRs2AmQgACAHIAsQn4CAgAAMAQsgBCANQYAQIA1rQQV2ajsBACAAIAk2AgAgACAAKAJcNgJgIAAgACkCVDcCWCAAQQdBCiAAKAJkQQdJGzYCZCAAIAUgCxCfgICAACAAKAJoIgNBfmpBAyADQQZJGyEKIAAoAgAhA0EBIQ4DQCAAIApBB3RqIA5BAXQiDmpB2AdqIQ0CQAJAIANBgICACEkNACAAKAIEIQQMAQsgACADQQh0IgM2AgAgACAAKAIQIgRBAWo2AhAgACAAKAIEQQh0IAQgACgCDGotAAByIgQ2AgQLAkACQCAEIANBC3YgDS8BACIJbCIPSQ0AIAAgBCAPayIENgIEIAAgAyAPayIDNgIAIA0gCSAJQQV2azsBACAOQQFyIQ4MAQsgACAPNgIAIA0gCUGAECAJa0EFdmo7AQAgDyEDCyAOQcAASQ0ACwJAIA5BQGoiCUEDSw0AIAAgCTYCVAwBCyAAIA5BAXFBAnIiDTYCVCAJQQF2IQ8CQCAJQQ1LDQAgACANIA9Bf2oiDHQiCzYCVEEBIQ0gCCALQQF0akGEC2ohEEE/IA5rIRFBACEPA0AgECARIA1qQQF0aiEOAkACQCADQf///wdNDQAgAyEKDAELIAAgA0EIdCIKNgIAIAAgACgCECIDQQFqNgIQIAAgBEEIdCADIAAoAgxqLQAAciIENgIECwJAAkAgBCAKQQt2IA4vAQAiCWwiA0kNACAAIAQgA2siBDYCBCAAIAogA2siAzYCACAOIAkgCUEFdms7AQAgAEEBIA90IAtqIgs2AlQgDUEBdEEBciENDAELIAAgAzYCACAOIAlBgBAgCWtBBXZqOwEAIA1BAXQhDQsgDCAPQQFqIg9HDQAMAgsLIA9Be2ohDgNAAkAgA0H///8HSw0AIAAgA0EIdCIDNgIAIAAgACgCECIJQQFqNgIQIARBCHQgCSAAKAIMai0AAHIhBAsgACADQQF2IgM2AgAgACAEIANrIgRBH3UiCSANQQF0akEBaiINNgJUIAAgCSADcSAEaiIENgIEIA5Bf2oiDg0ACyAAIA1BBHQiCzYCVEEAIQ9BASEOA0AgACAOQQF0Ig5qQbwNaiENAkACQCADQf///wdNDQAgAyEKDAELIAAgA0EIdCIKNgIAIAAgACgCECIDQQFqNgIQIAAgBEEIdCADIAAoAgxqLQAAciIENgIECwJAAkAgBCAKQQt2IA0vAQAiCWwiA0kNACAAIAQgA2siBDYCBCAAIAogA2siAzYCACANIAkgCUEFdms7AQAgAEEBIA90IAtqIgs2AlQgDkEBciEODAELIAAgAzYCACANIAlBgBAgCWtBBXZqOwEACyAPQQFqIg9BBEcNAAsLAkAgASAGIAAoAlQQnoCAgAANAEEADwsgACgCICECCyACIAAoAihJDQALC0EBIQMCQCAAKAIAIgRB////B0sNACAAIARBCHQ2AgBBASEDIAAgACgCECIEQQFqNgIQIAAgACgCBEEIdCAEIAAoAgxqLQAAcjYCBAsgAwtwAQF/AkBBqN4BEICAgIAAIgJFDQAgAkE0aiABNgIAIAJBPGogADYCAAJAAkACQCAAQX9qDgIAAQILIAIgARCAgICAACIANgIYIAANASACEIKAgIAADAILIAJBADYCGCACQThqQQA2AgALIAIPC0EAC9IBAQJ/QQYhAgJAIAFBJ0sNACAAQTBqIAFBAXFBAnIgAUEBdkELanQiATYCAAJAAkAgAEE8aigCACIDRQ0AQQQhAiABIABBNGooAgBLDQIgAEEsaiABNgIAIANBAkcNACAAQThqIgMoAgAgAU8NACAAIAE2AjggACgCGBCCgICAACAAIAAoAjAQgICAgAAiATYCGCABDQBBAyECDAELQQAhAiAAQQA2AkAgAEHQAGpBAToAACAAQegAakEANgIAIABB5N0BaiEDCyADQQA2AgALIAILIwACQCAAQTxqKAIARQ0AIAAoAhgQgoCAgAALIAAQgoCAgAAL9QEBBH9BACEDAkAgACgCDCACTQ0AIAAoAhggAk0NACABIAEoAgAiBCAAKAIQIAAoAggiBWsiBiAEIAYgBEkbIgRrNgIAIAUgAkF/c2ohAQJAIAUgAksNACAAKAIUIAFqIQELIAAoAgAiAiABai0AACEGQQEhAyAAIAVBAWo2AgggAiAFaiAGOgAAAkAgBEF/aiICRQ0AA0AgACgCACIFQQAgAUEBaiIBIAEgACgCFEYbIgFqLQAAIQQgACAAKAIIIgZBAWo2AgggBSAGaiAEOgAAIAJBf2oiAg0ACwsgACgCDCAAKAIIIgFPDQAgACABNgIMCyADC8gEAQd/AkACQCAAKAIAIgNBgICACEkNACAAKAIEIQQMAQsgACADQQh0IgM2AgAgACAAKAIQIgVBAWo2AhAgACAAKAIEQQh0IAUgACgCDGotAAByIgQ2AgQLAkACQCAEIANBC3YgAS8BACIGbCIFTw0AIAEgBkGAECAGa0EFdmo7AQAgASACQQR0akEEaiEHQQghCEECIQkMAQsgACAEIAVrIgQ2AgQgASAGIAZBBXZrOwEAAkAgAyAFayIDQf///wdLDQAgACADQQh0IgM2AgAgACAAKAIQIgVBAWo2AhAgACAEQQh0IAUgACgCDGotAAByIgQ2AgQLAkAgBCADQQt2IAEvAQIiBmwiBU8NACABIAZBgBAgBmtBBXZqOwECIAEgAkEEdGpBhAJqIQdBCCEIQQohCQwBCyAAIAQgBWsiBDYCBCABIAYgBkEFdms7AQIgAUGEBGohByADIAVrIQVBgAIhCEESIQkLIABB6ABqIAk2AgBBASEBA0AgByABQQF0IgFqIQMCQAJAIAVB////B00NACAFIQIMAQsgACAFQQh0IgI2AgAgACAAKAIQIgVBAWo2AhAgACAEQQh0IAUgACgCDGotAAByIgQ2AgQLAkACQCAEIAJBC3YgAy8BACIGbCIFSQ0AIAAgBCAFayIENgIEIAAgAiAFayIFNgIAIAMgBiAGQQV2azsBACABQQFyIQEMAQsgACAFNgIAIAMgBkGAECAGa0EFdmo7AQALIAEgCEkNAAsgAEHoAGogASAIayAJajYCAAsLNQEAQYAICy4IAAAAEAAAABgAAAAgAAAAKAAAADAAAABAAAAAUAAAAIAAAAAAAQAA/Td6WFoA"},t=>{t.exports=e}],r={};function n(e){var i=r[e];if(void 0!==i)return i.exports;var o=r[e]={exports:{}};return t[e](o,o.exports,n),o.exports}n.d=(e,t)=>{for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var i={};return(()=>{n.r(i),n.d(i,{XzReadableStream:()=>o});var e=n(1);const t=globalThis.ReadableStream||n(2).ReadableStream;class r{constructor(e){this.exports=e.exports,this.memory=this.exports.memory,this.ptr=this.exports.create_context(),this._refresh(),this.bufSize=this.mem32[0],this.inStart=this.mem32[1]-this.ptr,this.inEnd=this.inStart+this.bufSize,this.outStart=this.mem32[4]-this.ptr}supplyInput(e){this._refresh(),this.mem8.subarray(this.inStart,this.inEnd).set(e,0),this.exports.supply_input(this.ptr,e.byteLength),this._refresh()}getNextOutput(){const e=this.exports.get_next_output(this.ptr);if(this._refresh(),0!==e&&1!==e)throw new Error(`get_next_output failed with error code ${e}`);return{outChunk:this.mem8.slice(this.outStart,this.outStart+this.mem32[5]),finished:1===e}}needsMoreInput(){return this.mem32[2]===this.mem32[3]}outputBufferIsFull(){return this.mem32[5]===this.bufSize}resetOutputBuffer(){this.outPos=this.mem32[5]=0}dispose(){this.exports.destroy_context(this.ptr),this.exports=null}_refresh(){this.memory.buffer!==this.mem8?.buffer&&(this.mem8=new Uint8Array(this.memory.buffer,this.ptr),this.mem32=new Uint32Array(this.memory.buffer,this.ptr))}}class o extends t{static _moduleInstancePromise;static _moduleInstance;static async _getModuleInstance(){const t=e.replace("data:application/wasm;base64,",""),r=Uint8Array.from(atob(t),(e=>e.charCodeAt(0))).buffer,n=await WebAssembly.instantiate(r,{});o._moduleInstance=n.instance}constructor(e){let t,n=null;const i=e.getReader();super({async start(e){o._moduleInstance||await(o._moduleInstancePromise||(o._moduleInstancePromise=o._getModuleInstance())),t=new r(o._moduleInstance)},async pull(e){if(t.needsMoreInput()){if(null===n||0===n.byteLength){const{done:e,value:t}=await i.read();e||(n=t)}const e=Math.min(t.bufSize,n.byteLength);t.supplyInput(n.subarray(0,e)),n=n.subarray(e)}const r=t.getNextOutput();e.enqueue(r.outChunk),t.resetOutputBuffer(),r.finished&&(t.dispose(),e.close())},cancel:()=>(t.dispose(),i.cancel())})}}})(),i})(),e.exports=n(r(772))},3617:()=>{},772:()=>{},4132:e=>{"use strict";function t(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}const r=new Int32Array([0,1996959894,3993919788,2567524794,124634137,1886057615,3915621685,2657392035,249268274,2044508324,3772115230,2547177864,162941995,2125561021,3887607047,2428444049,498536548,1789927666,4089016648,2227061214,450548861,1843258603,4107580753,2211677639,325883990,1684777152,4251122042,2321926636,335633487,1661365465,4195302755,2366115317,997073096,1281953886,3579855332,2724688242,1006888145,1258607687,3524101629,2768942443,901097722,1119000684,3686517206,2898065728,853044451,1172266101,3705015759,2882616665,651767980,1373503546,3369554304,3218104598,565507253,1454621731,3485111705,3099436303,671266974,1594198024,3322730930,2970347812,795835527,1483230225,3244367275,3060149565,1994146192,31158534,2563907772,4023717930,1907459465,112637215,2680153253,3904427059,2013776290,251722036,2517215374,3775830040,2137656763,141376813,2439277719,3865271297,1802195444,476864866,2238001368,4066508878,1812370925,453092731,2181625025,4111451223,1706088902,314042704,2344532202,4240017532,1658658271,366619977,2362670323,4224994405,1303535960,984961486,2747007092,3569037538,1256170817,1037604311,2765210733,3554079995,1131014506,879679996,2909243462,3663771856,1141124467,855842277,2852801631,3708648649,1342533948,654459306,3188396048,3373015174,1466479909,544179635,3110523913,3462522015,1591671054,702138776,2966460450,3352799412,1504918807,783551873,3082640443,3233442989,3988292384,2596254646,62317068,1957810842,3939845945,2647816111,81470997,1943803523,3814918930,2489596804,225274430,2053790376,3826175755,2466906013,167816743,2097651377,4027552580,2265490386,503444072,1762050814,4150417245,2154129355,426522225,1852507879,4275313526,2312317920,282753626,1742555852,4189708143,2394877945,397917763,1622183637,3604390888,2714866558,953729732,1340076626,3518719985,2797360999,1068828381,1219638859,3624741850,2936675148,906185462,1090812512,3747672003,2825379669,829329135,1181335161,3412177804,3160834842,628085408,1382605366,3423369109,3138078467,570562233,1426400815,3317316542,2998733608,733239954,1555261956,3268935591,3050360625,752459403,1541320221,2607071920,3965973030,1969922972,40735498,2617837225,3943577151,1913087877,83908371,2512341634,3803740692,2075208622,213261112,2463272603,3855990285,2094854071,198958881,2262029012,4057260610,1759359992,534414190,2176718541,4139329115,1873836001,414664567,2282248934,4279200368,1711684554,285281116,2405801727,4167216745,1634467795,376229701,2685067896,3608007406,1308918612,956543938,2808555105,3495958263,1231636301,1047427035,2932959818,3654703836,1088359270,936918e3,2847714899,3736837829,1202900863,817233897,3183342108,3401237130,1404277552,615818150,3134207493,3453421203,1423857449,601450431,3009837614,3294710456,1567103746,711928724,3020668471,3272380065,1510334235,755167117]);function n(e){if(Buffer.isBuffer(e))return e;if("number"==typeof e)return Buffer.alloc(e);if("string"==typeof e)return Buffer.from(e);throw new Error("input must be buffer, number, or string, received "+typeof e)}function i(e,t){e=n(e),Buffer.isBuffer(t)&&(t=t.readUInt32BE(0));let i=~t;for(var o=0;o<e.length;o++)i=r[255&(i^e[o])]^i>>>8;return~i}function o(){return function(e){const t=n(4);return t.writeInt32BE(e,0),t}(i.apply(null,arguments))}o.signed=function(){return i.apply(null,arguments)},o.unsigned=function(){return i.apply(null,arguments)>>>0};const s=t(o);e.exports=s}},t={};function r(n){var i=t[n];if(void 0!==i)return i.exports;var o=t[n]={exports:{}};return e[n].call(o.exports,o,o.exports,r),o.exports}r.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return r.d(t,{a:t}),t},r.d=(e,t)=>{for(var n in t)r.o(t,n)&&!r.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var n=r(7806);window.gmodCRAM=n})();