PageSourceSearch

https://armm-shield.netlify.app/assets/vendor__syncfusion_ej2_compression-BTIr38B8.js

js armm-shield.netlify.app collected 2026-10-03 10:31:02 UTC 42,420 bytes, 2 lines download raw bytes

1import{S as b,E as x}from"./vendor__syncfusion_ej2_file_utils-Bj1tLZpF.js";var l=(function(){function n(){}return n.bitReverse=function(t){return n.reverseBits[t&15]<<12|n.reverseBits[t>>4&15]<<8|n.reverseBits[t>>8&15]<<4|n.reverseBits[t>>12]},n.bitConverterToInt32=function(t,e){return t[e]|t[e+1]<<8|t[e+2]<<16|t[e+3]<<24},n.bitConverterToInt16=function(t,e){return t[e]|t[e+1]<<8},n.bitConverterToUInt32=function(t){var e=new Uint32Array(1);return e[0]=t,e[0]},n.bitConverterToUInt16=function(t,e){var i=new Uint16Array(1);return i[0]=t[e]|t[e+1]<<8,i[0]},n.bitConverterUintToInt32=function(t){var e=new Int32Array(1);return e[0]=t,e[0]},n.bitConverterInt32ToUint=function(t){var e=new Uint32Array(1);return e[0]=t,e[0]},n.bitConverterInt32ToInt16=function(t){var e=new Int16Array(1);return e[0]=t,e[0]},n.byteToString=function(t){for(var e="",i=0;i<t.length;i++)e+=String.fromCharCode(t[i]);return e},n.byteIntToString=function(t){for(var e="",i=0;i<t.length;i++)e+=String.fromCharCode(t[i]);return e},n.arrayCopy=function(t,e,i,r,s){var h=new Uint8Array(t.buffer,e),a=h.subarray(0,s);i.set(a,r)},n.mergeArray=function(t,e){var i=new Uint8Array(t.length+e.length);return i.set(t),i.set(e,t.length),i},n.encodedString=function(t){var e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",i,r,s,h,a,f,o,u=0,c=0;t=t.replace(/[^A-Za-z0-9\+\/\=]/g,"");var d=t.length*3/4;if(t.charAt(t.length-1)===e.charAt(64)&&d--,t.charAt(t.length-2)===e.charAt(64)&&d--,d%1!==0)throw new Error("Invalid base64 input, bad content length.");for(var p=new Uint8Array(d|0);u<t.length;)h=e.indexOf(t.charAt(u++)),a=e.indexOf(t.charAt(u++)),f=e.indexOf(t.charAt(u++)),o=e.indexOf(t.charAt(u++)),i=h<<2|a>>4,r=(a&15)<<4|f>>2,s=(f&3)<<6|o,p[c++]=i,f!==64&&(p[c++]=r),o!==64&&(p[c++]=s);return p},n.reverseBits=[0,8,4,12,2,10,6,14,1,9,5,13,3,11,7,15],n.huffCodeLengthOrders=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],n})(),_=[],D=4,B=2,O=101010256,U=12,H=33639248,I=4096,m=(function(){function n(){_.length===0&&n.initCrc32Table(),this.files=[],this.level="Normal",b.isMicrosoftBrowser=!!navigator.msSaveBlob}return Object.defineProperty(n.prototype,"items",{get:function(){return this.files},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"compressionLevel",{get:function(){return this.level},set:function(t){this.level=t},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"length",{get:function(){return this.files===void 0?0:this.files.length},enumerable:!0,configurable:!0}),n.prototype.addItem=function(t){if(t==null)throw new Error("ArgumentException: item cannot be null or undefined");for(var e=0;e<this.files.length;e++){var i=this.files[e];if(i instanceof L&&i.name===t.name)throw new Error("item with same name already exist")}this.files.push(t)},n.prototype.addDirectory=function(t){if(t==null)throw new Error("ArgumentException: string cannot be null or undefined");if(t.length===0)throw new Error("ArgumentException: string cannot be empty");if(t.slice(-1)!=="/"&&(t+="/"),this.files.indexOf(t)!==-1)throw new Error("item with same name already exist");this.files.push(t)},n.prototype.getItem=function(t){if(t>=0&&t<this.files.length)return this.files[t]},n.prototype.contains=function(t){return this.files.indexOf(t)!==-1},n.prototype.open=function(t){var e=l.encodedString(t);if(e.length==0)throw new DOMException("stream");var i=new F(e),r=n.findValueFromEnd(i,O,65557);if(r<0)throw new DOMException("Can't locate end of central directory record. Possible wrong file format or archive is corrupt.");i.position=r+U;var s=n.ReadInt32(i),h=r-s;i.position=h,this.readCentralDirectoryDataAndExtractItems(i)},n.prototype.readCentralDirectoryDataAndExtractItems=function(t){if(t==null)throw new DOMException("stream");for(var e;n.ReadInt32(t)==H;)e=new N,e.readCentralDirectoryData(t);e.readData(t,e.checkCrc),e.decompressData(),this.files.push(new L(e.unCompressedStream.buffer,e.name))},n.prototype.save=function(t){if(t==null||t.length===0)throw new Error("ArgumentException: fileName cannot be null or undefined");if(this.files.length===0)throw new Error("InvalidOperation");var e=this;return new Promise(function(i,r){e.saveInternal(t,!1).then(function(){i(e)})})},n.prototype.saveAsBlob=function(){var t=this;return new Promise(function(e,i){t.saveInternal("",!0).then(function(r){e(r)})})},n.prototype.saveInternal=function(t,e){var i=this,r=this;return new Promise(function(s,h){for(var a=[],f=0,o=0;o<r.files.length;o++){var u=i.getCompressedData(i.files[o]);u.then(function(c){if(f=r.constructZippedObject(a,c,f,c.isDirectory),a.length===r.files.length){var d=r.writeZippedContent(t,a,f,e);s(d)}})}})},n.prototype.destroy=function(){if(this.files!==void 0&&this.files.length>0){for(var t=0;t<this.files.length;t++){var e=this.files[t];e instanceof L&&e.destroy(),e=void 0}this.files=[]}this.files=void 0,this.level=void 0},n.prototype.getCompressedData=function(t){var e=this,i=new Promise(function(r,s){if(t instanceof L){var h=new FileReader;h.onload=function(){var f=new Uint8Array(h.result),o={fileName:t.name,crc32Value:0,compressedData:[],compressedSize:void 0,uncompressedDataSize:f.length,compressionType:void 0,isDirectory:!1};if(e.level==="Normal"){e.compressData(f,o,_);for(var u=0,c=0;c<o.compressedData.length;c++)u+=o.compressedData[c].length;
1o.compressedSize=u,o.compressionType="\b\0"}else o.compressedSize=f.length,o.crc32Value=e.calculateCrc32Value(0,f,_),o.compressionType="\0\0",o.compressedData.push(f);r(o)},h.readAsArrayBuffer(t.data)}else{var a={fileName:t,crc32Value:0,compressedData:"",compressedSize:0,uncompressedDataSize:0,compressionType:"\0\0",isDirectory:!0};r(a)}});return i},n.prototype.compressData=function(t,e,i){var r=new W(!0),s=0,h=0;do{if(s>=t.length){r.close();break}h=Math.min(t.length,s+16384);var a=t.subarray(s,h);e.crc32Value=this.calculateCrc32Value(e.crc32Value,a,i),r.write(a,0,h-s),s=h}while(s<=t.length);e.compressedData=r.compressedData,r.destroy()},n.prototype.constructZippedObject=function(t,e,i,r){var s=0,h=new Date;r&&(s=s|16),s=s|0;var a=this.writeHeader(e,h),f="PK��"+a+e.fileName,o=this.writeCentralDirectory(e,a,i,s);return t.push({localHeader:f,centralDir:o,compressedData:e}),i+f.length+e.compressedSize},n.prototype.writeHeader=function(t,e){var i="";return i+=`
2\0\0\0`,i+=t.compressionType,i+=this.getBytes(this.getModifiedTime(e),2),i+=this.getBytes(this.getModifiedDate(e),2),i+=this.getBytes(t.crc32Value,4),i+=this.getBytes(t.compressedSize,4),i+=this.getBytes(t.uncompressedDataSize,4),i+=this.getBytes(t.fileName.length,2),i+=this.getBytes(0,2),i},n.prototype.writeZippedContent=function(t,e,i,r){for(var s=0,h=[],a=0;a<e.length;a++){var f=e[a];for(s+=f.centralDir.length,h.push(this.getArrayBuffer(f.localHeader));f.compressedData.compressedData.length;)h.push(f.compressedData.compressedData.shift().buffer)}for(var a=0;a<e.length;a++)h.push(this.getArrayBuffer(e[a].centralDir));h.push(this.getArrayBuffer(this.writeFooter(e,s,i)));var o=new Blob(h,{type:"application/zip"});return r||b.save(t,o),o},n.prototype.writeCentralDirectory=function(t,e,i,r){var s="PK��"+this.getBytes(20,2)+e+this.getBytes(0,2)+"\0\0\0\0"+this.getBytes(r,4)+this.getBytes(i,4)+t.fileName;return s},n.prototype.writeFooter=function(t,e,i){var r="PK��\0\0\0\0"+this.getBytes(t.length,2)+this.getBytes(t.length,2)+this.getBytes(e,4)+this.getBytes(i,4)+this.getBytes(0,2);return r},n.prototype.getArrayBuffer=function(t){for(var e=new Uint8Array(t.length),i=0;i<t.length;++i)e[i]=t.charCodeAt(i)&255;return e.buffer},n.prototype.getBytes=function(t,e){for(var i="",r=0;r<e;r++)i+=String.fromCharCode(t&255),t=t>>>8;return i},n.prototype.getModifiedTime=function(t){var e=t.getHours();return e=e<<6,e=e|t.getMinutes(),e=e<<5,e=e|t.getSeconds()/2},n.prototype.getModifiedDate=function(t){var e=t.getFullYear()-1980;return e=e<<4,e=e|t.getMonth()+1,e=e<<5,e=e|t.getDate()},n.prototype.calculateCrc32Value=function(t,e,i){t^=-1;for(var r=0;r<e.length;r++)t=t>>>8^i[(t^e[r])&255];return t^-1},n.initCrc32Table=function(){for(var t,e=0;e<256;e++){t=e;for(var i=0;i<8;i++)t=t&1?3988292384^t>>>1:t>>>1;_[e]=t}},n.findValueFromEnd=function(t,e,i){if(t==null)throw new DOMException("stream");var r=t.inputStream.buffer.byteLength;if(r<4)return-1;var s=new Uint8Array(4),h=Math.max(0,r-i),a=r-1-D;t.position=a,t.read(s,0,D);var f=s[0],o=f==e;if(!o){for(;a>h;)if(f<<=8,a--,t.position=a,f+=t.readByte(),f==e){o=!0;break}}return o?a:-1},n.ReadInt32=function(t){var e=new Uint8Array(D);if(t.read(e,0,D)!=D)throw new DOMException("Unable to read value at the specified position - end of stream was reached.");return l.bitConverterToInt32(e,0)},n.ReadInt16=function(t){var e=new Uint8Array(B);if(t.read(e,0,B)!=B)throw new DOMException("Unable to read value at the specified position - end of stream was reached.");return l.bitConverterToInt16(e,0)},n.ReadUInt16=function(t){{var e=new Uint8Array(B);if(t.read(e,0,B)!=B)throw new DOMException("Unable to read value at the specified position - end of stream was reached.");return l.bitConverterToInt16(e,0)}},n})(),N=(function(){function n(){this.headerSignature=67324752,this.checkCrc=!0,this.crc32=0}return n.prototype.readCentralDirectoryData=function(t){t.position+=4,this.options=m.ReadInt16(t),this.compressionMethod=m.ReadInt16(t),this.checkCrc=this.compressionMethod!=99,m.ReadInt32(t),this.crc32=l.bitConverterToUInt32(m.ReadInt32(t)),this.compressedSize=m.ReadInt32(t),this.originalSize=m.ReadInt32(t);var e=m.ReadInt16(t),i=m.ReadInt16(t),r=m.ReadInt16(t);t.position+=4,this.externalAttributes=m.ReadInt32(t),this.localHeaderOffset=m.ReadInt32(t);var s=new Uint8Array(e);t.read(s,0,e);var h=l.byteToString(s);h=h.replace("\\","/"),this.name=h,t.position+=i+r,this.options!=0&&(this.options=0)},n.prototype.readData=function(t,e){if(t.length==0)throw new DOMException("stream");t.position=this.localHeaderOffset,this.checkCrc=e,this.readLocalHeader(t),this.readCompressedData(t)},n.prototype.decompressData=function(){this.compressionMethod==8&&this.originalSize>0&&this.decompressDataOld()},n.prototype.decompressDataOld=function(){var t=new z(this.compressedStream,!0),e;this.originalSize>0&&(e=new F(new Uint8Array(this.originalSize)));for(var i=new Uint8Array(I),r;(r=t.read(i,0,I))>0;)e.write(i.subarray(0,r),0,r);
2this.unCompressedStream=e.toByteArray(),this.checkCrc},n.prototype.readLocalHeader=function(t){if(t.length==0)throw new DOMException("stream");if(m.ReadInt32(t)!=this.headerSignature)throw new DOMException("Can't find local header signature - wrong file format or file is corrupt.");t.position+=22;var e=m.ReadInt16(t),i=m.ReadUInt16(t);if(this.compressionMethod!=99)if(i>2){t.position+=e;var r=m.ReadInt16(t);if(r==23)throw new DOMException("UnSupported");t.position+=i-2}else t.position+=e+i},n.prototype.readCompressedData=function(t){var e;if(this.compressedSize>0){var i=this.compressedSize;e=new F(new Uint8Array(i));for(var r=new Uint8Array(I);i>0;){var s=Math.min(i,I);if(t.read(r,0,s)!=s)throw new DOMException("End of file reached - wrong file format or file is corrupt.");e.write(r.subarray(0,s),0,s),i-=s}this.compressedStream=new Uint8Array(e.inputStream)}else this.compressedSize<0||this.compressedSize==0},n})(),L=(function(){function n(t,e){if(t==null)throw new Error("ArgumentException: data cannot be null or undefined");if(e==null)throw new Error("ArgumentException: string cannot be null or undefined");if(e.length===0)throw new Error("string cannot be empty");this.data=t,this.name=e}return Object.defineProperty(n.prototype,"dataStream",{get:function(){return this.decompressedStream},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"name",{get:function(){return this.fileName},set:function(t){this.fileName=t},enumerable:!0,configurable:!0}),n.prototype.destroy=function(){this.fileName=void 0,this.data=void 0},n})(),S=new Int16Array(286),E=new Uint8Array(286),k=new Int16Array(30),M=new Uint8Array(30),W=(function(){function n(t){this.pendingBuffer=new Uint8Array(65536),this.pendingBufLength=0,this.pendingBufCache=0,this.pendingBufBitsInCache=0,this.bufferPosition=0,this.extraBits=0,this.currentHash=0,this.matchStart=0,this.matchLength=0,this.matchPrevAvail=!1,this.blockStart=0,this.stringStart=0,this.lookAhead=0,this.totalBytesIn=0,this.inputOffset=0,this.inputEnd=0,this.windowSize=32768,this.windowMask=this.windowSize-1,this.hashSize=32768,this.hashMask=this.hashSize-1,this.hashShift=Math.floor(17/3),this.maxDist=this.windowSize-262,this.checkSum=1,this.noWrap=!1,n.isHuffmanTreeInitiated||(n.initHuffmanTree(),n.isHuffmanTreeInitiated=!0),this.treeLiteral=new v(this,286,257,15),this.treeDistances=new v(this,30,1,15),this.treeCodeLengths=new v(this,19,4,7),this.arrDistances=new Uint16Array(16384),this.arrLiterals=new Uint8Array(16384),this.stream=[],this.dataWindow=new Uint8Array(2*this.windowSize),this.hashHead=new Int16Array(this.hashSize),this.hashPrevious=new Int16Array(this.windowSize),this.blockStart=this.stringStart=1,this.noWrap=t,t||this.writeZLibHeader()}return Object.defineProperty(n.prototype,"compressedData",{get:function(){return this.stream},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"getCompressedString",{get:function(){var t="";if(this.stream!==void 0)for(var e=0;e<this.stream.length;e++)t+=String.fromCharCode.apply(null,this.stream[e]);return t},enumerable:!0,configurable:!0}),n.prototype.write=function(t,e,i){if(t==null)throw new Error("ArgumentException: data cannot null or undefined");var r=e+i;if(0>e||e>r||r>t.length)throw new Error("ArgumentOutOfRangeException: Offset or length is incorrect");if(typeof t=="string"){var s=new x(!1);
2s.type="Utf8",t=new Uint8Array(s.getBytes(t,0,t.length)),r=e+t.length}for(this.inputBuffer=t,this.inputOffset=e,this.inputEnd=r,this.noWrap||(this.checkSum=R.checksumUpdate(this.checkSum,this.inputBuffer,this.inputOffset,r));this.inputEnd!==this.inputOffset||this.pendingBufLength!==0;)this.pendingBufferFlush(),this.compressData(!1)},n.prototype.writeZLibHeader=function(){var t=30720;t|=64,t+=31-t%31,this.pendingBufferWriteShortBytes(t)},n.prototype.pendingBufferWriteShortBytes=function(t){this.pendingBuffer[this.pendingBufLength++]=t>>8,this.pendingBuffer[this.pendingBufLength++]=t},n.prototype.compressData=function(t){var e;do{this.fillWindow();var i=t&&this.inputEnd===this.inputOffset;e=this.compressSlow(i,t)}while(this.pendingBufLength===0&&e);return e},n.prototype.compressSlow=function(t,e){if(this.lookAhead<262&&!t)return!1;for(;this.lookAhead>=262||t;){if(this.lookAhead===0)return this.lookAheadCompleted(e);this.stringStart>=2*this.windowSize-262&&this.slideWindow();var i=this.matchStart,r=this.matchLength;if(this.lookAhead>=3&&this.discardMatch(),r>=3&&this.matchLength<=r?r=this.matchPreviousBest(i,r):this.matchPreviousAvailable(),this.bufferPosition>=16384)return this.huffmanIsFull(e)}return!0},n.prototype.discardMatch=function(){var t=this.insertString();t!==0&&this.stringStart-t<=this.maxDist&&this.findLongestMatch(t)&&this.matchLength<=5&&this.matchLength===3&&this.stringStart-this.matchStart>4096&&(this.matchLength=2)},n.prototype.matchPreviousAvailable=function(){this.matchPrevAvail&&this.huffmanTallyLit(this.dataWindow[this.stringStart-1]&255),this.matchPrevAvail=!0,this.stringStart++,this.lookAhead--},n.prototype.matchPreviousBest=function(t,e){this.huffmanTallyDist(this.stringStart-1-t,e),e-=2;do this.stringStart++,this.lookAhead--,this.lookAhead>=3&&this.insertString();while(--e>0);return this.stringStart++,this.lookAhead--,this.matchPrevAvail=!1,this.matchLength=2,e},n.prototype.lookAheadCompleted=function(t){return this.matchPrevAvail&&this.huffmanTallyLit(this.dataWindow[this.stringStart-1]&255),this.matchPrevAvail=!1,this.huffmanFlushBlock(this.dataWindow,this.blockStart,this.stringStart-this.blockStart,t),this.blockStart=this.stringStart,!1},n.prototype.huffmanIsFull=function(t){var e=this.stringStart-this.blockStart;this.matchPrevAvail&&e--;var i=t&&this.lookAhead===0&&!this.matchPrevAvail;return this.huffmanFlushBlock(this.dataWindow,this.blockStart,e,i),this.blockStart+=e,!i},n.prototype.fillWindow=function(){for(this.stringStart>=this.windowSize+this.maxDist&&this.slideWindow();this.lookAhead<262&&this.inputOffset<this.inputEnd;){var t=2*this.windowSize-this.lookAhead-this.stringStart;t>this.inputEnd-this.inputOffset&&(t=this.inputEnd-this.inputOffset),this.dataWindow.set(this.inputBuffer.subarray(this.inputOffset,this.inputOffset+t),this.stringStart+this.lookAhead),this.inputOffset+=t,this.totalBytesIn+=t,this.lookAhead+=t}this.lookAhead>=3&&this.updateHash()},n.prototype.slideWindow=function(){this.dataWindow.set(this.dataWindow.subarray(this.windowSize,this.windowSize+this.windowSize),0),this.matchStart-=this.windowSize,this.stringStart-=this.windowSize,this.blockStart-=this.windowSize;for(var t=0;t<this.hashSize;++t){var e=this.hashHead[t]&65535;this.hashHead[t]=e>=this.windowSize?e-this.windowSize:0}for(var t=0;t<this.windowSize;t++){var e=this.hashPrevious[t]&65535;this.hashPrevious[t]=e>=this.windowSize?e-this.windowSize:0}},n.prototype.insertString=function(){var t,e=(this.currentHash<<this.hashShift^this.dataWindow[this.stringStart+2])&this.hashMask;return this.hashPrevious[this.stringStart&this.windowMask]=t=this.hashHead[e],this.hashHead[e]=this.stringStart,this.currentHash=e,t&65535},n.prototype.findLongestMatch=function(t){var e=4096,i=258,r=this.stringStart,s,h=this.stringStart+this.matchLength,a=Math.max(this.matchLength,2),f=Math.max(this.stringStart-this.maxDist,0),o=this.stringStart+258-1,u=this.dataWindow[h-1],c=this.dataWindow[h],d=this.dataWindow;a>=32&&(e>>=2),i>this.lookAhead&&(i=this.lookAhead);do if(!(d[t+a]!==c||d[t+a-1]!==u||d[t]!==d[r]||d[t+1]!==d[r+1])){for(s=t+2,r+=2;d[++r]===d[++s]&&d[++r]===d[++s]&&d[++r]===d[++s]&&d[++r]===d[++s]&&d[++r]===d[++s]&&d[++r]===d[++s]&&d[++r]===d[++s]&&d[++r]===d[++s]&&r<o;);if(r>h){if(this.matchStart=t,h=r,a=r-this.stringStart,a>=i)break;u=d[h-1],c=d[h]}r=this.stringStart}while((t=this.hashPrevious[t&this.windowMask]&65535)>f&&--e!==0);return this.matchLength=Math.min(a,this.lookAhead),this.matchLength>=3},n.prototype.updateHash=function(){this.currentHash=this.dataWindow[this.stringStart]<<this.hashShift^this.dataWindow[this.stringStart+1]},n.prototype.huffmanTallyLit=function(t){return this.arrDistances[this.bufferPosition]=0,this.arrLiterals[this.bufferPosition++]=t,this.treeLiteral.codeFrequencies[t]++,this.bufferPosition>=16384},n.prototype.huffmanTallyDist=function(t,e){this.arrDistances[this.bufferPosition]=t,this.arrLiterals[this.bufferPosition++]=e-3;var i=this.huffmanLengthCode(e-3);this.treeLiteral.codeFrequencies[i]++,i>=265&&i<285&&(this.extraBits+=Math.floor((i-261)/4));var r=this.huffmanDistanceCode(t-1);return this.treeDistances.codeFrequencies[r]++,r>=4&&(this.extraBits+=Math.floor(r/2-1)),this.bufferPosition>=16384}
2,n.prototype.huffmanFlushBlock=function(t,e,i,r){this.treeLiteral.codeFrequencies[256]++,this.treeLiteral.buildTree(),this.treeDistances.buildTree(),this.treeLiteral.calculateBLFreq(this.treeCodeLengths),this.treeDistances.calculateBLFreq(this.treeCodeLengths),this.treeCodeLengths.buildTree();for(var s=4,h=18;h>s;h--)this.treeCodeLengths.codeLengths[v.huffCodeLengthOrders[h]]>0&&(s=h+1);for(var a=14+s*3+this.treeCodeLengths.getEncodedLength()+this.treeLiteral.getEncodedLength()+this.treeDistances.getEncodedLength()+this.extraBits,f=this.extraBits,h=0;h<286;h++)f+=this.treeLiteral.codeFrequencies[h]*E[h];for(var h=0;h<30;h++)f+=this.treeDistances.codeFrequencies[h]*M[h];a>=f&&(a=f),e>=0&&i+4<a>>3?this.huffmanFlushStoredBlock(t,e,i,r):a==f?(this.pendingBufferWriteBits(2+(r?1:0),3),this.treeLiteral.setStaticCodes(S,E),this.treeDistances.setStaticCodes(k,M),this.huffmanCompressBlock(),this.huffmanReset()):(this.pendingBufferWriteBits(4+(r?1:0),3),this.huffmanSendAllTrees(s),this.huffmanCompressBlock(),this.huffmanReset())},n.prototype.huffmanFlushStoredBlock=function(t,e,i,r){this.pendingBufferWriteBits(0+(r?1:0),3),this.pendingBufferAlignToByte(),this.pendingBufferWriteShort(i),this.pendingBufferWriteShort(~i),this.pendingBufferWriteByteBlock(t,e,i),this.huffmanReset()},n.prototype.huffmanLengthCode=function(t){if(t===255)return 285;for(var e=257;t>=8;)e+=4,t>>=1;return e+t},n.prototype.huffmanDistanceCode=function(t){for(var e=0;t>=4;)e+=2,t>>=1;return e+t},n.prototype.huffmanSendAllTrees=function(t){this.treeCodeLengths.buildCodes(),this.treeLiteral.buildCodes(),this.treeDistances.buildCodes(),this.pendingBufferWriteBits(this.treeLiteral.treeLength-257,5),this.pendingBufferWriteBits(this.treeDistances.treeLength-1,5),this.pendingBufferWriteBits(t-4,4);for(var e=0;e<t;e++)this.pendingBufferWriteBits(this.treeCodeLengths.codeLengths[v.huffCodeLengthOrders[e]],3);this.treeLiteral.writeTree(this.treeCodeLengths),this.treeDistances.writeTree(this.treeCodeLengths)},n.prototype.huffmanReset=function(){this.bufferPosition=0,this.extraBits=0,this.treeLiteral.reset(),this.treeDistances.reset(),this.treeCodeLengths.reset()},n.prototype.huffmanCompressBlock=function(){for(var t=0;t<this.bufferPosition;t++){var e=this.arrLiterals[t]&255,i=this.arrDistances[t];if(i--!==0){var r=this.huffmanLengthCode(e);this.treeLiteral.writeCodeToStream(r);var s=Math.floor((r-261)/4);s>0&&s<=5&&this.pendingBufferWriteBits(e&(1<<s)-1,s);var h=this.huffmanDistanceCode(i);this.treeDistances.writeCodeToStream(h),s=Math.floor(h/2-1),s>0&&this.pendingBufferWriteBits(i&(1<<s)-1,s)}else this.treeLiteral.writeCodeToStream(e)}this.treeLiteral.writeCodeToStream(256)},n.prototype.pendingBufferWriteBits=function(t,e){var i=new Uint32Array(1);i[0]=this.pendingBufCache|t<<this.pendingBufBitsInCache,this.pendingBufCache=i[0],this.pendingBufBitsInCache+=e,this.pendingBufferFlushBits()},n.prototype.pendingBufferFlush=function(t){if(this.pendingBufferFlushBits(),this.pendingBufLength>0){var e=new Uint8Array(this.pendingBufLength);e.set(this.pendingBuffer.subarray(0,this.pendingBufLength),0),this.stream.push(e)}this.pendingBufLength=0},n.prototype.pendingBufferFlushBits=function(){for(var t=0;this.pendingBufBitsInCache>=8&&this.pendingBufLength<65536;)this.pendingBuffer[this.pendingBufLength++]=this.pendingBufCache,this.pendingBufCache>>=8,this.pendingBufBitsInCache-=8,t++;return t},n.prototype.pendingBufferWriteByteBlock=function(t,e,i){var r=t.subarray(e,e+i);this.pendingBuffer.set(r,this.pendingBufLength),this.pendingBufLength+=i},n.prototype.pendingBufferWriteShort=function(t){this.pendingBuffer[this.pendingBufLength++]=t,this.pendingBuffer[this.pendingBufLength++]=t>>8},n.prototype.pendingBufferAlignToByte=function(){this.pendingBufBitsInCache>0&&(this.pendingBuffer[this.pendingBufLength++]=this.pendingBufCache),this.pendingBufCache=0,this.pendingBufBitsInCache=0},n.initHuffmanTree=function(){for(var t=0;t<144;)S[t]=v.bitReverse(48+t<<8),E[t++]=8;for(;t<256;)S[t]=v.bitReverse(256+t<<7),E[t++]=9;for(;t<280;)S[t]=v.bitReverse(-256+t<<9),E[t++]=7;for(;t<286;)S[t]=v.bitReverse(-88+t<<8),E[t++]=8;for(t=0;t<30;t++)k[t]=v.bitReverse(t<<11),M[t]=5},n.prototype.close=function(){do this.pendingBufferFlush(!0),this.compressData(!0)||(this.pendingBufferFlush(!0),this.pendingBufferAlignToByte(),this.noWrap||(this.pendingBufferWriteShortBytes(this.checkSum>>16),this.pendingBufferWriteShortBytes(this.checkSum&65535)),this.pendingBufferFlush(!0));while(this.inputEnd!==this.inputOffset||this.pendingBufLength!==0)},n.prototype.destroy=function(){this.stream=[],this.stream=void 0,this.pendingBuffer=void 0,this.treeLiteral=void 0,this.treeDistances=void 0,this.treeCodeLengths=void 0,this.arrLiterals=void 0,this.arrDistances=void 0,this.hashHead=void 0,this.hashPrevious=void 0,this.dataWindow=void 0,this.inputBuffer=void 0,this.pendingBufLength=void 0,this.pendingBufCache=void 0,this.pendingBufBitsInCache=void 0,this.bufferPosition=void 0,this.extraBits=void 0,this.currentHash=void 0,this.matchStart=void 0,this.matchLength=void 0,this.matchPrevAvail=void 0,this.blockStart=void 0,this.stringStart=void 0,this.lookAhead=void 0,this.totalBytesIn=void 0,this.inputOffset=void 0,this.inputEnd=void 0,this.windowSize=void 0,this.windowMask=void 0,this.hashSize=void 0,this.hashMask=void 0,this.hashShift=void 0,this.maxDist=void 0,this.checkSum=void 0,this.noWrap=void 0},n.isHuffmanTreeInitiated=!1,n}
2)(),v=(function(){function n(t,e,i,r){this.writer=t,this.codeMinCount=i,this.maxLength=r,this.codeFrequency=new Uint16Array(e),this.lengthCount=new Int32Array(r)}return Object.defineProperty(n.prototype,"treeLength",{get:function(){return this.codeCount},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"codeLengths",{get:function(){return this.codeLength},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"codeFrequencies",{get:function(){return this.codeFrequency},enumerable:!0,configurable:!0}),n.prototype.setStaticCodes=function(t,e){var i=new Int16Array(t.length);i.set(t,0),this.codes=i;var r=new Uint8Array(e.length);r.set(e,0),this.codeLength=r},n.prototype.reset=function(){for(var t=0;t<this.codeFrequency.length;t++)this.codeFrequency[t]=0;this.codes=void 0,this.codeLength=void 0},n.prototype.writeCodeToStream=function(t){this.writer.pendingBufferWriteBits(this.codes[t]&65535,this.codeLength[t])},n.prototype.buildCodes=function(){var t=new Int32Array(this.maxLength);this.codes=new Int16Array(this.codeCount);for(var e=0,i=0;i<this.maxLength;i++)t[i]=e,e+=this.lengthCount[i]<<15-i;for(var r=0;r<this.codeCount;r++){var s=this.codeLength[r];s>0&&(this.codes[r]=n.bitReverse(t[s-1]),t[s-1]+=1<<16-s)}},n.bitReverse=function(t){return n.reverseBits[t&15]<<12|n.reverseBits[t>>4&15]<<8|n.reverseBits[t>>8&15]<<4|n.reverseBits[t>>12]},n.prototype.getEncodedLength=function(){for(var t=0,e=0;e<this.codeFrequency.length;e++)t+=this.codeFrequency[e]*this.codeLength[e];return t},n.prototype.calculateBLFreq=function(t){for(var e,i,r,s=-1,h=0;h<this.codeCount;){r=1;var a=this.codeLength[h];for(a===0?(e=138,i=3):(e=6,i=3,s!==a&&(t.codeFrequency[a]++,r=0)),s=a,h++;h<this.codeCount&&s===this.codeLength[h]&&(h++,!(++r>=e)););r<i?t.codeFrequency[s]+=r:s!==0?t.codeFrequency[16]++:r<=10?t.codeFrequency[17]++:t.codeFrequency[18]++}},n.prototype.writeTree=function(t){for(var e,i,r,s=-1,h=0;h<this.codeCount;){r=1;var a=this.codeLength[h];for(a===0?(e=138,i=3):(e=6,i=3,s!==a&&(t.writeCodeToStream(a),r=0)),s=a,h++;h<this.codeCount&&s===this.codeLength[h]&&(h++,!(++r>=e)););if(r<i)for(;r-- >0;)t.writeCodeToStream(s);else s!==0?(t.writeCodeToStream(16),this.writer.pendingBufferWriteBits(r-3,2)):r<=10?(t.writeCodeToStream(17),this.writer.pendingBufferWriteBits(r-3,3)):(t.writeCodeToStream(18),this.writer.pendingBufferWriteBits(r-11,7))}},n.prototype.buildTree=function(){for(var t=this.codeFrequency.length,e=new Int32Array(t),i=0,r=0,s=0;s<t;s++){var h=this.codeFrequency[s];if(h!==0){for(var a=i++,f=0;a>0&&this.codeFrequency[e[f=Math.floor((a-1)/2)]]>h;)e[a]=e[f],a=f;e[a]=s,r=s}}for(;i<2;)e[i++]=r<2?++r:0;this.codeCount=Math.max(r+1,this.codeMinCount);for(var o=i,u=o,c=new Int32Array(4*i-2),d=new Int32Array(2*i-1),p=0;p<i;p++){var g=e[p],w=2*p;c[w]=g,c[w+1]=-1,d[p]=this.codeFrequency[g]<<8,e[p]=p}this.constructHuffmanTree(e,i,d,u,c),this.buildLength(c)},n.prototype.constructHuffmanTree=function(t,e,i,r,s){do{for(var h=t[0],a=t[--e],f=i[a],o=0,u=1;u<e;)u+1<e&&i[t[u]]>i[t[u+1]]&&u++,t[o]=t[u],o=u,u=o*2+1;for(;(u=o)>0&&i[t[o=Math.floor((u-1)/2)]]>f;)t[u]=t[o];t[u]=a;var c=t[0];a=r++,s[2*a]=h,s[2*a+1]=c;var d=Math.min(i[h]&255,i[c]&255);for(i[a]=f=i[h]+i[c]-d+1,o=0,u=1;u<e;)u+1<e&&i[t[u]]>i[t[u+1]]&&u++,t[o]=t[u],o=u,u=o*2+1;for(;(u=o)>0&&i[t[o=Math.floor((u-1)/2)]]>f;)t[u]=t[o];t[u]=a}while(e>1)},n.prototype.buildLength=function(t){this.codeLength=new Uint8Array(this.codeFrequency.length);for(var e=Math.floor(t.length/2),i=Math.floor((e+1)/2),r=0,s=0;s<this.maxLength;s++)this.lengthCount[s]=0;if(r=this.calculateOptimalCodeLength(t,r,e),r!==0){var h=this.maxLength-1;do{for(;this.lengthCount[--h]===0;);do this.lengthCount[h]--,this.lengthCount[++h]++,r-=1<<this.maxLength-1-h;while(r>0&&h<this.maxLength-1)}while(r>0);this.recreateTree(t,r,i)}},n.prototype.recreateTree=function(t,e,i){this.lengthCount[this.maxLength-1]+=e,this.lengthCount[this.maxLength-2]-=e;for(var r=2*i,s=this.maxLength;s!==0;s--)for(var h=this.lengthCount[s-1];h>0;){var a=2*t[r++];t[a+1]===-1&&(this.codeLength[t[a]]=s,h--)}}
2,n.prototype.calculateOptimalCodeLength=function(t,e,i){var r=new Int32Array(i);r[i-1]=0;for(var s=i-1;s>=0;s--){var h=2*s+1;if(t[h]!==-1){var a=r[s]+1;a>this.maxLength&&(a=this.maxLength,e++),r[t[h-1]]=r[t[h]]=a}else{var a=r[s];this.lengthCount[a-1]++,this.codeLength[t[h-1]]=r[s]}}return e},n.reverseBits=[0,8,4,12,2,10,6,14,1,9,5,13,3,11,7,15],n.huffCodeLengthOrders=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],n})(),R=(function(){function n(){}return n.checksumUpdate=function(t,e,i,r){var s=new Uint32Array(1);s[0]=t;for(var h=s[0],a=s[0]=h&65535,f=s[0]=h>>n.checkSumBitOffset;r>0;){var o=Math.min(r,n.checksumIterationCount);for(r-=o;--o>=0;)a=a+(s[0]=e[i++]&255),f=f+a;a%=n.checksumBase,f%=n.checksumBase}return h=f<<n.checkSumBitOffset|a,h},n.checkSumBitOffset=16,n.checksumBase=65521,n.checksumIterationCount=3800,n})(),y=(function(){function n(t){this.buildTree(t)}return n.init=function(){var t,e;for(t=new Uint8Array(288),e=0;e<144;)t[e++]=8;for(;e<256;)t[e++]=9;for(;e<280;)t[e++]=7;for(;e<288;)t[e++]=8;for(n.m_LengthTree=new n(t),t=new Uint8Array(32),e=0;e<32;)t[e++]=5;n.m_DistanceTree=new n(t)},n.prototype.prepareData=function(t,e,i){for(var r=0,s=512,h=0;h<i.length;h++){var a=i[h];a>0&&t[a]++}for(var f=1;f<=n.MAX_BITLEN;f++)if(e[f]=r,r+=t[f]<<16-f,f>=10){var o=e[f]&130944,u=r&130944;s+=u-o>>16-f}return{code:r,treeSize:s}},n.prototype.treeFromData=function(t,e,i,r,s){for(var h=new Int16Array(s),a=512,f=128,o=n.MAX_BITLEN;o>=10;o--){var u=r&130944;r-=t[o]<<16-o;for(var c=r&130944,d=c;d<u;d+=f)h[l.bitReverse(d)]=l.bitConverterInt32ToInt16(-a<<4|o),a+=1<<o-9}for(var d=0;d<i.length;d++){var o=i[d];if(o!=0){r=e[o];var p=l.bitReverse(r);if(o<=9)do h[p]=l.bitConverterInt32ToInt16(d<<4|o),p+=1<<o;while(p<512);else{var g=h[p&511],w=1<<(g&15);g=-(g>>4);do h[g|p>>9]=l.bitConverterInt32ToInt16(d<<4|o),p+=1<<o;while(p<w)}e[o]=r+(1<<16-o)}}return h},n.prototype.buildTree=function(t){var e=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],i=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],r=this.prepareData(e,i,t);this.m_Tree=this.treeFromData(e,i,t,r.code,r.treeSize)},n.prototype.unpackSymbol=function(t){var e,i;if((e=t.peekBits(9))>=0){if((i=this.m_Tree[e])>=0)return t.skipBits(i&15),i>>4;var r=-(i>>4),s=i&15;if((e=t.peekBits(s))>=0)return i=this.m_Tree[r|e>>9],t.skipBits(i&15),i>>4;var h=t.availableBits;return e=t.peekBits(h),i=this.m_Tree[r|e>>9],(i&15)<=h?(t.skipBits(i&15),i>>4):-1}else{var h=t.availableBits;return e=t.peekBits(h),i=this.m_Tree[e],i>=0&&(i&15)<=h?(t.skipBits(i&15),i>>4):-1}},Object.defineProperty(n,"lengthTree",{get:function(){return this.m_LengthTree},enumerable:!0,configurable:!0}),Object.defineProperty(n,"distanceTree",{get:function(){return this.m_DistanceTree},enumerable:!0,configurable:!0}),n.MAX_BITLEN=15,n})(),P=(function(){function n(){}return n.ChecksumUpdate=function(t,e,i,r){for(var s=t,h=s&65535,a=s>>this.DEF_CHECKSUM_BIT_OFFSET;r>0;){var f=Math.min(r,this.DEF_CHECKSUM_ITERATIONSCOUNT);for(r-=f;--f>=0;)h=h+(e[i++]&255),a=a+h;h%=this.DEF_CHECKSUM_BASE,a%=this.DEF_CHECKSUM_BASE}s=a<<this.DEF_CHECKSUM_BIT_OFFSET|h,t=s},n.ChecksumGenerate=function(t,e,i){var r=1;return n.ChecksumUpdate(r,t,e,i),r},n.DEF_CHECKSUM_BIT_OFFSET=16,n.DEF_CHECKSUM_BASE=65521,n.DEF_CHECKSUM_ITERATIONSCOUNT=3800,n})(),z=(function(){function n(t,e){if(this.defaultHuffmanDynamicTree=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],this.DEF_HEADER_METHOD_MASK=3840,this.DEF_HEADER_INFO_MASK=61440,this.DEF_HEADER_FLAGS_FCHECK=31,this.DEF_HEADER_FLAGS_FDICT=32,this.DEF_HEADER_FLAGS_FLEVEL=192,this.DEF_MAX_WINDOW_SIZE=65535,this.DEF_HUFFMAN_REPEATE_MAX=258,this.DEF_HUFFMAN_END_BLOCK=256,this.DEF_HUFFMAN_LENGTH_MINIMUMCODE=257,this.DEF_HUFFMAN_LENGTH_MAXIMUMCODE=285,this.DEF_HUFFMAN_DISTANCE_MAXIMUMCODE=29,this.mCheckSum=1,this.tBuffer=0,this.mBufferedBits=0,this.mTempBuffer=new Uint8Array(4),this.mBlockBuffer=new Uint8Array(this.DEF_MAX_WINDOW_SIZE),this.mbNoWrap=!1,this.mWindowSize=0,this.mCurrentPosition=0,this.mDataLength=0,this.mbCanReadNextBlock=!0,this.mbCanReadMoreData=!0,this.mbCheckSumRead=!1,t==null)throw new DOMException("stream");if(t.length===0)throw new DOMException("stream - string can not be empty");y.init(),this.mInputStream=new F(t),this.mbNoWrap=e,this.mbNoWrap||this.readZLibHeader(),this.decodeBlockHeader()}return Object.defineProperty(n.prototype,"mBuffer",{get:function(){return this.tBuffer},set:function(t){this.tBuffer=t},enumerable:!0,configurable:!0}),n.prototype.peekBits=function(t){if(t<0)throw new DOMException("c
2ount","Bits count can not be less than zero.");if(t>32)throw new DOMException("count","Count of bits is too large.");if(this.mBufferedBits<t&&this.fillBuffer(),this.mBufferedBits<t)return-1;var e=~(4294967295<<t),i=l.bitConverterUintToInt32(this.mBuffer&e);return i},n.prototype.fillBuffer=function(){var t=4-(this.mBufferedBits>>3)-((this.mBufferedBits&7)!==0?1:0);if(t!==0)for(var e=this.mInputStream.read(this.mTempBuffer,0,t),i=0;i<e;i++)this.mBuffer=l.bitConverterInt32ToUint(this.mBuffer|l.bitConverterInt32ToUint(this.mTempBuffer[i]<<this.mBufferedBits)),this.mBufferedBits+=8},n.prototype.skipBits=function(t){if(t<0)throw new DOMException("count","Bits count can not be less than zero.");t!==0&&(t>=this.mBufferedBits?(t-=this.mBufferedBits,this.mBufferedBits=0,this.mBuffer=0,t>0&&(this.mInputStream.position+=t>>3,t&=7,t>0&&(this.fillBuffer(),this.mBufferedBits-=t,this.mBuffer=l.bitConverterInt32ToUint(this.mBuffer>>>t)))):(this.mBufferedBits-=t,this.mBuffer=l.bitConverterInt32ToUint(this.mBuffer>>>t)))},Object.defineProperty(n.prototype,"availableBits",{get:function(){return this.mBufferedBits},enumerable:!0,configurable:!0}),n.prototype.readZLibHeader=function(){var t=this.readInt16();if(t===-1)throw new DOMException("Header of the stream can not be read.");if(t%31!==0)throw new DOMException("Header checksum illegal");if((t&this.DEF_HEADER_METHOD_MASK)!==2048)throw new DOMException("Unsupported compression method.");if(this.mWindowSize=Math.pow(2,((t&this.DEF_HEADER_INFO_MASK)>>12)+8),this.mWindowSize>65535)throw new DOMException("Unsupported window size for deflate compression method.");if((t&this.DEF_HEADER_FLAGS_FDICT)>>5===1)throw new DOMException("Custom dictionary is not supported at the moment.")},n.prototype.readInt16=function(){var t=this.readBits(8)<<8;return t|=this.readBits(8),t},n.prototype.readBits=function(t){var e=this.peekBits(t);return e===-1?-1:(this.mBufferedBits-=t,this.mBuffer=l.bitConverterInt32ToUint(this.mBuffer>>>t),e)},n.prototype.decodeBlockHeader=function(){if(!this.mbCanReadNextBlock)return!1;var t=this.readBits(1);if(t===-1)return!1;var e=this.readBits(2);if(e===-1)return!1;switch(this.mbCanReadNextBlock=t===0,e){case 0:this.mbReadingUncompressed=!0,this.skipToBoundary();var i=this.readInt16Inverted(),r=this.readInt16Inverted();if(i!==(r^65535))throw new DOMException("Wrong block length.");if(i>65535)throw new DOMException("Uncompressed block length can not be more than 65535.");this.mUncompressedDataLength=i,this.mCurrentLengthTree=null,this.mCurrentDistanceTree=null;break;case 1:this.mbReadingUncompressed=!1,this.mUncompressedDataLength=-1,this.mCurrentLengthTree=y.lengthTree,this.mCurrentDistanceTree=y.distanceTree;break;case 2:this.mbReadingUncompressed=!1,this.mUncompressedDataLength=-1;var s=this.decodeDynamicHeader(this.mCurrentLengthTree,this.mCurrentDistanceTree);this.mCurrentLengthTree=s.lengthTree,this.mCurrentDistanceTree=s.distanceTree;break;default:throw new DOMException("Wrong block type.")}return!0},n.prototype.skipToBoundary=function(){this.mBuffer=l.bitConverterInt32ToUint(this.mBuffer>>>(this.mBufferedBits&7)),this.mBufferedBits&=-8},n.prototype.readInt16Inverted=function(){var t=this.readBits(8);return t|=this.readBits(8)<<8,t},n.prototype.decodeDynamicHeader=function(t,e){var i=0,r=this.readBits(5),s=this.readBits(5),h=this.readBits(4);if(r<0||s<0||h<0)throw new DOMException("Wrong dynamic huffman codes.");r+=257,s+=1;var a=r+s,f=new Uint8Array(a),o=new Uint8Array(19);h+=4;for(var u=0;u<h;){var c=this.readBits(3);if(c<0)throw new DOMException("Wrong dynamic huffman codes.");o[this.defaultHuffmanDynamicTree[u++]]=c}var d=new y(o);for(u=0;;){var p=void 0,g=!1;for(p=d.unpackSymbol(this);(p&-16)===0;){if(f[u++]=i=p,u===a){g=!0;break}p=d.unpackSymbol(this)}if(g)break;if(p<0)throw new DOMException("Wrong dynamic huffman codes.");if(p>=17)i=0;else if(u===0)throw new DOMException("Wrong dynamic huffman codes.");var w=p-16,T=n.DEF_HUFFMAN_DYNTREE_REPEAT_BITS[w],C=this.readBits(T);if(C<0)throw new DOMException("Wrong dynamic huffman codes.");if(C+=n.DEF_HUFFMAN_DYNTREE_REPEAT_MINIMUMS[w],u+C>a)throw new DOMException("Wrong dynamic huffman codes.");for(;C-- >0;)f[u++]=i;if(u===a)break}var A=new Uint8Array(r);
2return A.set(f.subarray(0,r),0),t=new y(A),A=f.slice(r,r+s),e=new y(A),{lengthTree:t,distanceTree:e}},n.prototype.readHuffman=function(){for(var t=this.DEF_MAX_WINDOW_SIZE-(this.mDataLength-this.mCurrentPosition),e=!1,i={};t>=this.DEF_HUFFMAN_REPEATE_MAX;){var r=void 0;for(r=this.mCurrentLengthTree.unpackSymbol(this);(r&-256)===0;){if(i[(this.mDataLength+1)%this.DEF_MAX_WINDOW_SIZE]=r,this.mBlockBuffer[this.mDataLength++%this.DEF_MAX_WINDOW_SIZE]=r,e=!0,--t<this.DEF_HUFFMAN_REPEATE_MAX)return!0;r=this.mCurrentLengthTree.unpackSymbol(this)}if(r<this.DEF_HUFFMAN_LENGTH_MINIMUMCODE){if(r<this.DEF_HUFFMAN_END_BLOCK)throw new DOMException("Illegal code.");var s=e?1:0;this.mbCanReadMoreData=this.decodeBlockHeader();var h=this.mbCanReadMoreData?1:0;return!!(s|h)}if(r>this.DEF_HUFFMAN_LENGTH_MAXIMUMCODE)throw new DOMException("Illegal repeat code length.");var a=n.DEF_HUFFMAN_REPEAT_LENGTH_BASE[r-this.DEF_HUFFMAN_LENGTH_MINIMUMCODE],f=n.DEF_HUFFMAN_REPEAT_LENGTH_EXTENSION[r-this.DEF_HUFFMAN_LENGTH_MINIMUMCODE];if(f>0){var o=this.readBits(f);if(o<0)throw new DOMException("Wrong data.");a+=o}if(r=this.mCurrentDistanceTree.unpackSymbol(this),r<0||r>n.DEF_HUFFMAN_REPEAT_DISTANCE_BASE.length)throw new DOMException("Wrong distance code.");var u=n.DEF_HUFFMAN_REPEAT_DISTANCE_BASE[r];
2if(f=n.DEF_HUFFMAN_REPEAT_DISTANCE_EXTENSION[r],f>0){var o=this.readBits(f);if(o<0)throw new DOMException("Wrong data.");u+=o}for(var c=0;c<a;c++)this.mBlockBuffer[this.mDataLength%this.DEF_MAX_WINDOW_SIZE]=this.mBlockBuffer[(this.mDataLength-u)%this.DEF_MAX_WINDOW_SIZE],this.mDataLength++,t--;e=!0}return e},n.prototype.read=function(t,e,i){if(t==null)throw new DOMException("buffer");if(e<0||e>t.length-1)throw new DOMException("offset","Offset does not belong to specified buffer.");if(i<0||i>t.length-e)throw new DOMException("length","Length is illegal.");for(var r=i;i>0;)if(this.mCurrentPosition<this.mDataLength){var s=this.mCurrentPosition%this.DEF_MAX_WINDOW_SIZE,h=Math.min(this.DEF_MAX_WINDOW_SIZE-s,this.mDataLength-this.mCurrentPosition);h=Math.min(h,i),l.arrayCopy(this.mBlockBuffer,s,t,e,h),this.mCurrentPosition+=h,e+=h,i-=h}else{if(!this.mbCanReadMoreData)break;var a=this.mDataLength;if(this.mbReadingUncompressed)if(this.mUncompressedDataLength===0){if(this.mbCanReadMoreData=this.decodeBlockHeader(),!this.mbCanReadMoreData)break}else{var s=this.mDataLength%this.DEF_MAX_WINDOW_SIZE,f=Math.min(this.mUncompressedDataLength,this.DEF_MAX_WINDOW_SIZE-s),o=this.readPackedBytes(this.mBlockBuffer,s,f);if(f!==o)throw new DOMException("Not enough data in stream.");this.mUncompressedDataLength-=o,this.mDataLength+=o}else if(!this.readHuffman())break;if(a<this.mDataLength){var u=a%this.DEF_MAX_WINDOW_SIZE,c=this.mDataLength%this.DEF_MAX_WINDOW_SIZE;u<c?this.checksumUpdate(this.mBlockBuffer,u,c-u):(this.checksumUpdate(this.mBlockBuffer,u,this.DEF_MAX_WINDOW_SIZE-u),c>0&&this.checksumUpdate(this.mBlockBuffer,0,c))}}if(!this.mbCanReadMoreData&&!this.mbCheckSumRead&&!this.mbNoWrap){this.skipToBoundary();var d=this.readInt32();if(d!==this.mCheckSum)throw new DOMException("Checksum check failed.");this.mbCheckSumRead=!0}return r-i},n.prototype.readPackedBytes=function(t,e,i){if(t==null)throw new DOMException("buffer");if(e<0||e>t.length-1)throw new DOMException('offset", "Offset can not be less than zero or greater than buffer length - 1.');if(i<0)throw new DOMException('length", "Length can not be less than zero.');if(i>t.length-e)throw new DOMException('length", "Length is too large.');if((this.mBufferedBits&7)!==0)throw new DOMException("Reading of unalligned data is not supported.");if(i===0)return 0;for(var r=0;this.mBufferedBits>0&&i>0;)t[e++]=this.mBuffer,this.mBufferedBits-=8,this.mBuffer=l.bitConverterInt32ToUint(this.mBuffer>>>8),i--,r++;return i>0&&(r+=this.mInputStream.read(t,e,i)),r},n.prototype.readInt32=function(){var t=this.readBits(8)<<24;return t|=this.readBits(8)<<16,t|=this.readBits(8)<<8,t|=this.readBits(8),t},n.prototype.checksumUpdate=function(t,e,i){P.ChecksumUpdate(this.mCheckSum,t,e,i)},n.DEF_REVERSE_BITS=new Uint8Array([0,8,4,12,2,10,6,14,1,9,5,13,3,11,7,15]),n.DEF_HUFFMAN_DYNTREE_REPEAT_MINIMUMS=[3,3,11],n.DEF_HUFFMAN_DYNTREE_REPEAT_BITS=[2,3,7],n.DEF_HUFFMAN_REPEAT_LENGTH_BASE=[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],n.DEF_HUFFMAN_REPEAT_LENGTH_EXTENSION=[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],n.DEF_HUFFMAN_REPEAT_DISTANCE_BASE=[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],n.DEF_HUFFMAN_REPEAT_DISTANCE_EXT
2ENSION=[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],n})(),F=(function(){function n(t){this.position=0,this.inputStream=new Uint8Array(t.buffer)}return Object.defineProperty(n.prototype,"length",{get:function(){return this.inputStream.buffer.byteLength},enumerable:!0,configurable:!0}),n.prototype.read=function(t,e,i){var r=new Uint8Array(this.inputStream.buffer,this.position+e),s=r.subarray(0,i);return t.set(s,0),this.position+=s.byteLength,s.byteLength},n.prototype.readByte=function(){return this.inputStream[this.position++]},n.prototype.write=function(t,e,i){l.arrayCopy(t,0,this.inputStream,this.position+e,i),this.position+=i},n.prototype.toByteArray=function(){return new Uint8Array(this.inputStream.buffer)},n})();export{W as C,m as Z,L as a};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.