gdcore-tools 2.0.0-beta9 → 2.0.0

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 (68) hide show
  1. package/README.md +64 -64
  2. package/dist/Runtime/Extensions/DialogueTree/bondage.js/dist/bondage.min.js +10 -10
  3. package/dist/Runtime/Extensions/DialogueTree/bondage.js/version.txt +5 -5
  4. package/dist/Runtime/Extensions/Firebase/A_firebasejs/NOTICE.txt +6 -6
  5. package/dist/Runtime/Extensions/Multiplayer/JsExtension.js +0 -15
  6. package/dist/Runtime/Extensions/PhysicsBehavior/box2djs/box2d.js +804 -804
  7. package/dist/Runtime/Extensions/Shopify/shopify-buy.umd.polyfilled.min.js +1 -1
  8. package/dist/Runtime/Extensions/TileMap/example/anotherIsland.json +5768 -5768
  9. package/dist/Runtime/Extensions/TileMap/example/island.json +5822 -5822
  10. package/dist/lib/libGD.cjs +21 -21
  11. package/dist/lib/libGD.wasm +0 -0
  12. package/package.json +1 -1
  13. package/dist/Runtime/Extensions/TileMap/helper/node_modules/.package-lock.json +0 -19
  14. package/dist/Runtime/Extensions/TileMap/helper/node_modules/@types/pako/index.d.ts +0 -165
  15. package/dist/Runtime/Extensions/TileMap/helper/node_modules/@types/pako/package.json +0 -35
  16. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/dist/pako.es5.js +0 -2
  17. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/dist/pako.es5.js.map +0 -7
  18. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/dist/pako.es5.min.js +0 -2
  19. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/dist/pako.js +0 -2
  20. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/dist/pako.js.map +0 -7
  21. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/dist/pako.min.js +0 -2
  22. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/dist/pako_deflate.es5.js +0 -2
  23. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/dist/pako_deflate.es5.js.map +0 -7
  24. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/dist/pako_deflate.es5.min.js +0 -2
  25. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/dist/pako_deflate.js +0 -2
  26. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/dist/pako_deflate.js.map +0 -7
  27. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/dist/pako_deflate.min.js +0 -2
  28. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/dist/pako_inflate.es5.js +0 -2
  29. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/dist/pako_inflate.es5.js.map +0 -7
  30. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/dist/pako_inflate.es5.min.js +0 -2
  31. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/dist/pako_inflate.js +0 -2
  32. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/dist/pako_inflate.js.map +0 -7
  33. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/dist/pako_inflate.min.js +0 -2
  34. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/index.js +0 -2
  35. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/index.js.map +0 -7
  36. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/lib/deflate.js +0 -2
  37. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/lib/deflate.js.map +0 -7
  38. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/lib/inflate.js +0 -2
  39. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/lib/inflate.js.map +0 -7
  40. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/lib/utils/common.js +0 -2
  41. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/lib/utils/common.js.map +0 -7
  42. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/lib/utils/strings.js +0 -2
  43. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/lib/utils/strings.js.map +0 -7
  44. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/lib/zlib/adler32.js +0 -2
  45. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/lib/zlib/adler32.js.map +0 -7
  46. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/lib/zlib/constants.js +0 -2
  47. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/lib/zlib/constants.js.map +0 -7
  48. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/lib/zlib/crc32.js +0 -2
  49. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/lib/zlib/crc32.js.map +0 -7
  50. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/lib/zlib/deflate.js +0 -2
  51. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/lib/zlib/deflate.js.map +0 -7
  52. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/lib/zlib/gzheader.js +0 -2
  53. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/lib/zlib/gzheader.js.map +0 -7
  54. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/lib/zlib/inffast.js +0 -2
  55. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/lib/zlib/inffast.js.map +0 -7
  56. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/lib/zlib/inflate.js +0 -2
  57. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/lib/zlib/inflate.js.map +0 -7
  58. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/lib/zlib/inftrees.js +0 -2
  59. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/lib/zlib/inftrees.js.map +0 -7
  60. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/lib/zlib/messages.js +0 -2
  61. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/lib/zlib/messages.js.map +0 -7
  62. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/lib/zlib/trees.js +0 -2
  63. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/lib/zlib/trees.js.map +0 -7
  64. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/lib/zlib/zstream.js +0 -2
  65. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/lib/zlib/zstream.js.map +0 -7
  66. package/dist/Runtime/Extensions/TileMap/helper/node_modules/pako/package.json +0 -64
  67. package/types/index.d.ts +0 -23
  68. package/types/open_project.d.ts +0 -25
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../../../../../../../../GDevelop/Extensions/TileMap/helper/node_modules/pako/lib/utils/strings.js"],
4
- "sourcesContent": ["// String encode/decode helpers\n'use strict';\n\n\n// Quick check if we can use fast array to bin string conversion\n//\n// - apply(Array) can fail on Android 2.2\n// - apply(Uint8Array) can fail on iOS 5.1 Safari\n//\nlet STR_APPLY_UIA_OK = true;\n\ntry { String.fromCharCode.apply(null, new Uint8Array(1)); } catch (__) { STR_APPLY_UIA_OK = false; }\n\n\n// Table with utf8 lengths (calculated by first byte of sequence)\n// Note, that 5 & 6-byte values and some 4-byte values can not be represented in JS,\n// because max possible codepoint is 0x10ffff\nconst _utf8len = new Uint8Array(256);\nfor (let q = 0; q < 256; q++) {\n _utf8len[q] = (q >= 252 ? 6 : q >= 248 ? 5 : q >= 240 ? 4 : q >= 224 ? 3 : q >= 192 ? 2 : 1);\n}\n_utf8len[254] = _utf8len[254] = 1; // Invalid sequence start\n\n\n// convert string to array (typed, when possible)\nmodule.exports.string2buf = (str) => {\n if (typeof TextEncoder === 'function' && TextEncoder.prototype.encode) {\n return new TextEncoder().encode(str);\n }\n\n let buf, c, c2, m_pos, i, str_len = str.length, buf_len = 0;\n\n // count binary size\n for (m_pos = 0; m_pos < str_len; m_pos++) {\n c = str.charCodeAt(m_pos);\n if ((c & 0xfc00) === 0xd800 && (m_pos + 1 < str_len)) {\n c2 = str.charCodeAt(m_pos + 1);\n if ((c2 & 0xfc00) === 0xdc00) {\n c = 0x10000 + ((c - 0xd800) << 10) + (c2 - 0xdc00);\n m_pos++;\n }\n }\n buf_len += c < 0x80 ? 1 : c < 0x800 ? 2 : c < 0x10000 ? 3 : 4;\n }\n\n // allocate buffer\n buf = new Uint8Array(buf_len);\n\n // convert\n for (i = 0, m_pos = 0; i < buf_len; m_pos++) {\n c = str.charCodeAt(m_pos);\n if ((c & 0xfc00) === 0xd800 && (m_pos + 1 < str_len)) {\n c2 = str.charCodeAt(m_pos + 1);\n if ((c2 & 0xfc00) === 0xdc00) {\n c = 0x10000 + ((c - 0xd800) << 10) + (c2 - 0xdc00);\n m_pos++;\n }\n }\n if (c < 0x80) {\n /* one byte */\n buf[i++] = c;\n } else if (c < 0x800) {\n /* two bytes */\n buf[i++] = 0xC0 | (c >>> 6);\n buf[i++] = 0x80 | (c & 0x3f);\n } else if (c < 0x10000) {\n /* three bytes */\n buf[i++] = 0xE0 | (c >>> 12);\n buf[i++] = 0x80 | (c >>> 6 & 0x3f);\n buf[i++] = 0x80 | (c & 0x3f);\n } else {\n /* four bytes */\n buf[i++] = 0xf0 | (c >>> 18);\n buf[i++] = 0x80 | (c >>> 12 & 0x3f);\n buf[i++] = 0x80 | (c >>> 6 & 0x3f);\n buf[i++] = 0x80 | (c & 0x3f);\n }\n }\n\n return buf;\n};\n\n// Helper\nconst buf2binstring = (buf, len) => {\n // On Chrome, the arguments in a function call that are allowed is `65534`.\n // If the length of the buffer is smaller than that, we can use this optimization,\n // otherwise we will take a slower path.\n if (len < 65534) {\n if (buf.subarray && STR_APPLY_UIA_OK) {\n return String.fromCharCode.apply(null, buf.length === len ? buf : buf.subarray(0, len));\n }\n }\n\n let result = '';\n for (let i = 0; i < len; i++) {\n result += String.fromCharCode(buf[i]);\n }\n return result;\n};\n\n\n// convert array to string\nmodule.exports.buf2string = (buf, max) => {\n const len = max || buf.length;\n\n if (typeof TextDecoder === 'function' && TextDecoder.prototype.decode) {\n return new TextDecoder().decode(buf.subarray(0, max));\n }\n\n let i, out;\n\n // Reserve max possible length (2 words per char)\n // NB: by unknown reasons, Array is significantly faster for\n // String.fromCharCode.apply than Uint16Array.\n const utf16buf = new Array(len * 2);\n\n for (out = 0, i = 0; i < len;) {\n let c = buf[i++];\n // quick process ascii\n if (c < 0x80) { utf16buf[out++] = c; continue; }\n\n let c_len = _utf8len[c];\n // skip 5 & 6 byte codes\n if (c_len > 4) { utf16buf[out++] = 0xfffd; i += c_len - 1; continue; }\n\n // apply mask on first byte\n c &= c_len === 2 ? 0x1f : c_len === 3 ? 0x0f : 0x07;\n // join the rest\n while (c_len > 1 && i < len) {\n c = (c << 6) | (buf[i++] & 0x3f);\n c_len--;\n }\n\n // terminated by end of string?\n if (c_len > 1) { utf16buf[out++] = 0xfffd; continue; }\n\n if (c < 0x10000) {\n utf16buf[out++] = c;\n } else {\n c -= 0x10000;\n utf16buf[out++] = 0xd800 | ((c >> 10) & 0x3ff);\n utf16buf[out++] = 0xdc00 | (c & 0x3ff);\n }\n }\n\n return buf2binstring(utf16buf, out);\n};\n\n\n// Calculate max possible position in utf8 buffer,\n// that will not break sequence. If that's not possible\n// - (very small limits) return max size as is.\n//\n// buf[] - utf8 bytes array\n// max - length limit (mandatory);\nmodule.exports.utf8border = (buf, max) => {\n\n max = max || buf.length;\n if (max > buf.length) { max = buf.length; }\n\n // go back from last position, until start of sequence found\n let pos = max - 1;\n while (pos >= 0 && (buf[pos] & 0xC0) === 0x80) { pos--; }\n\n // Very small and broken sequence,\n // return max, because we should return something anyway.\n if (pos < 0) { return max; }\n\n // If we came to start of buffer - that means buffer is too small,\n // return max too.\n if (pos === 0) { return max; }\n\n return (pos + _utf8len[buf[pos]] > max) ? pos : max;\n};\n"],
5
- "mappings": "aASA,GAAI,kBAAmB,GAEvB,GAAI,CAAE,OAAO,aAAa,MAAM,KAAM,GAAI,YAAW,SAAO,CAAa,iBAAmB,GAM5F,KAAM,UAAW,GAAI,YAAW,KAChC,OAAS,GAAI,EA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,EAAM,SAAS,EAAI,IAAQ,EAAO,EAAM",
6
- "names": []
7
- }
@@ -1,2 +0,0 @@
1
- "use strict";const adler32=(o,r,s,i)=>{let f=o&65535|0,t=o>>>16&65535|0,e=0;for(;s!==0;){e=s>2e3?2e3:s,s-=e;do f=f+r[i++]|0,t=t+f|0;while(--e);f%=65521,t%=65521}return f|t<<16|0};module.exports=adler32;
2
- //# sourceMappingURL=adler32.js.map
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../../../../../../../../GDevelop/Extensions/TileMap/helper/node_modules/pako/lib/zlib/adler32.js"],
4
- "sourcesContent": ["'use strict';\n\n// Note: adler32 takes 12% for level 0 and 2% for level 6.\n// It isn't worth it to make additional optimizations as in original.\n// Small size is preferable.\n\n// (C) 1995-2013 Jean-loup Gailly and Mark Adler\n// (C) 2014-2017 Vitaly Puzrin and Andrey Tupitsin\n//\n// This software is provided 'as-is', without any express or implied\n// warranty. In no event will the authors be held liable for any damages\n// arising from the use of this software.\n//\n// Permission is granted to anyone to use this software for any purpose,\n// including commercial applications, and to alter it and redistribute it\n// freely, subject to the following restrictions:\n//\n// 1. The origin of this software must not be misrepresented; you must not\n// claim that you wrote the original software. If you use this software\n// in a product, an acknowledgment in the product documentation would be\n// appreciated but is not required.\n// 2. Altered source versions must be plainly marked as such, and must not be\n// misrepresented as being the original software.\n// 3. This notice may not be removed or altered from any source distribution.\n\nconst adler32 = (adler, buf, len, pos) => {\n let s1 = (adler & 0xffff) |0,\n s2 = ((adler >>> 16) & 0xffff) |0,\n n = 0;\n\n while (len !== 0) {\n // Set limit ~ twice less than 5552, to keep\n // s2 in 31-bits, because we force signed ints.\n // in other case %= will fail.\n n = len > 2000 ? 2000 : len;\n len -= n;\n\n do {\n s1 = (s1 + buf[pos++]) |0;\n s2 = (s2 + s1) |0;\n } while (--n);\n\n s1 %= 65521;\n s2 %= 65521;\n }\n\n return (s1 | (s2 << 16)) |0;\n};\n\n\nmodule.exports = adler32;\n"],
5
- "mappings": "aAyBA,KAAM,SAAU,CAAC,EAAO,EAAK,EAAK,IAAQ,CACxC,GAAI,GAAM,EAAQ,MAAS,EACvB,EAAO,IAAU,GAAM,MAAS,EAChC,EAAI,EAER,KAAO,IAAQ,GAAG,CAIhB,EAAI,EAAM,IAAO,IAAO,EACxB,GAAO,EAEP,EACE,GAAM,EAAK,EAAI,KAAS,EACxB,EAAM,EAAK,EAAK,QACT,EAAE,GAEX,GAAM,MACN,GAAM,MAGR,MAAQ,GAAM,GAAM,GAAM,GAI5B,OAAO,QAAU",
6
- "names": []
7
- }
@@ -1,2 +0,0 @@
1
- "use strict";module.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_MEM_ERROR:-4,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};
2
- //# sourceMappingURL=constants.js.map
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../../../../../../../../GDevelop/Extensions/TileMap/helper/node_modules/pako/lib/zlib/constants.js"],
4
- "sourcesContent": ["'use strict';\n\n// (C) 1995-2013 Jean-loup Gailly and Mark Adler\n// (C) 2014-2017 Vitaly Puzrin and Andrey Tupitsin\n//\n// This software is provided 'as-is', without any express or implied\n// warranty. In no event will the authors be held liable for any damages\n// arising from the use of this software.\n//\n// Permission is granted to anyone to use this software for any purpose,\n// including commercial applications, and to alter it and redistribute it\n// freely, subject to the following restrictions:\n//\n// 1. The origin of this software must not be misrepresented; you must not\n// claim that you wrote the original software. If you use this software\n// in a product, an acknowledgment in the product documentation would be\n// appreciated but is not required.\n// 2. Altered source versions must be plainly marked as such, and must not be\n// misrepresented as being the original software.\n// 3. This notice may not be removed or altered from any source distribution.\n\nmodule.exports = {\n\n /* Allowed flush values; see deflate() and inflate() below for details */\n Z_NO_FLUSH: 0,\n Z_PARTIAL_FLUSH: 1,\n Z_SYNC_FLUSH: 2,\n Z_FULL_FLUSH: 3,\n Z_FINISH: 4,\n Z_BLOCK: 5,\n Z_TREES: 6,\n\n /* Return codes for the compression/decompression functions. Negative values\n * are errors, positive values are used for special but normal events.\n */\n Z_OK: 0,\n Z_STREAM_END: 1,\n Z_NEED_DICT: 2,\n Z_ERRNO: -1,\n Z_STREAM_ERROR: -2,\n Z_DATA_ERROR: -3,\n Z_MEM_ERROR: -4,\n Z_BUF_ERROR: -5,\n //Z_VERSION_ERROR: -6,\n\n /* compression levels */\n Z_NO_COMPRESSION: 0,\n Z_BEST_SPEED: 1,\n Z_BEST_COMPRESSION: 9,\n Z_DEFAULT_COMPRESSION: -1,\n\n\n Z_FILTERED: 1,\n Z_HUFFMAN_ONLY: 2,\n Z_RLE: 3,\n Z_FIXED: 4,\n Z_DEFAULT_STRATEGY: 0,\n\n /* Possible values of the data_type field (though see inflate()) */\n Z_BINARY: 0,\n Z_TEXT: 1,\n //Z_ASCII: 1, // = Z_TEXT (deprecated)\n Z_UNKNOWN: 2,\n\n /* The deflate compression method */\n Z_DEFLATED: 8\n //Z_NULL: null // Use -1 or null inline, depending on var type\n};\n"],
5
- "mappings": "aAqBA,OAAO,QAAU,CAGf,WAAoB,EACpB,gBAAoB,EACpB,aAAoB,EACpB,aAAoB,EACpB,SAAoB,EACpB,QAAoB,EACpB,QAAoB,EAKpB,KAAoB,EACpB,aAAoB,EACpB,YAAoB,EACpB,QAAmB,GACnB,eAAmB,GACnB,aAAmB,GACnB,YAAmB,GACnB,YAAmB,GAInB,iBAA0B,EAC1B,aAA0B,EAC1B,mBAA0B,EAC1B,sBAAyB,GAGzB,WAA0B,EAC1B,eAA0B,EAC1B,MAA0B,EAC1B,QAA0B,EAC1B,mBAA0B,EAG1B,SAA0B,EAC1B,OAA0B,EAE1B,UAA0B,EAG1B,WAA0B",
6
- "names": []
7
- }
@@ -1,2 +0,0 @@
1
- "use strict";const makeTable=()=>{let t,o=[];for(var e=0;e<256;e++){t=e;for(var r=0;r<8;r++)t=t&1?3988292384^t>>>1:t>>>1;o[e]=t}return o},crcTable=new Uint32Array(makeTable()),crc32=(t,o,e,r)=>{const n=crcTable,s=r+e;t^=-1;for(let a=r;a<s;a++)t=t>>>8^n[(t^o[a])&255];return t^-1};module.exports=crc32;
2
- //# sourceMappingURL=crc32.js.map
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../../../../../../../../GDevelop/Extensions/TileMap/helper/node_modules/pako/lib/zlib/crc32.js"],
4
- "sourcesContent": ["'use strict';\n\n// Note: we can't get significant speed boost here.\n// So write code to minimize size - no pregenerated tables\n// and array tools dependencies.\n\n// (C) 1995-2013 Jean-loup Gailly and Mark Adler\n// (C) 2014-2017 Vitaly Puzrin and Andrey Tupitsin\n//\n// This software is provided 'as-is', without any express or implied\n// warranty. In no event will the authors be held liable for any damages\n// arising from the use of this software.\n//\n// Permission is granted to anyone to use this software for any purpose,\n// including commercial applications, and to alter it and redistribute it\n// freely, subject to the following restrictions:\n//\n// 1. The origin of this software must not be misrepresented; you must not\n// claim that you wrote the original software. If you use this software\n// in a product, an acknowledgment in the product documentation would be\n// appreciated but is not required.\n// 2. Altered source versions must be plainly marked as such, and must not be\n// misrepresented as being the original software.\n// 3. This notice may not be removed or altered from any source distribution.\n\n// Use ordinary array, since untyped makes no boost here\nconst makeTable = () => {\n let c, table = [];\n\n for (var n = 0; n < 256; n++) {\n c = n;\n for (var k = 0; k < 8; k++) {\n c = ((c & 1) ? (0xEDB88320 ^ (c >>> 1)) : (c >>> 1));\n }\n table[n] = c;\n }\n\n return table;\n};\n\n// Create table on load. Just 255 signed longs. Not a problem.\nconst crcTable = new Uint32Array(makeTable());\n\n\nconst crc32 = (crc, buf, len, pos) => {\n const t = crcTable;\n const end = pos + len;\n\n crc ^= -1;\n\n for (let i = pos; i < end; i++) {\n crc = (crc >>> 8) ^ t[(crc ^ buf[i]) & 0xFF];\n }\n\n return (crc ^ (-1)); // >>> 0;\n};\n\n\nmodule.exports = crc32;\n"],
5
- "mappings": "aA0BA,KAAM,WAAY,IAAM,CACtB,GAAI,GAAG,EAAQ,GAEf,OAAS,GAAI,EAAG,EAAI,IAAK,IAAK,CAC5B,EAAI,EACJ,OAAS,GAAI,EAAG,EAAI,EAAG,IACrB,EAAM,EAAI,EAAM,WAAc,IAAM,EAAO,IAAM,EAEnD,EAAM,GAAK,EAGb,MAAO,IAIH,SAAW,GAAI,aAAY,aAG3B,MAAQ,CAAC,EAAK,EAAK,EAAK,IAAQ,CACpC,KAAM,GAAI,SACJ,EAAM,EAAM,EAElB,GAAO,GAEP,OAAS,GAAI,EAAK,EAAI,EAAK,IACzB,EAAO,IAAQ,EAAK,EAAG,GAAM,EAAI,IAAM,KAGzC,MAAQ,GAAO,IAIjB,OAAO,QAAU",
6
- "names": []
7
- }
@@ -1,2 +0,0 @@
1
- "use strict";const{_tr_init,_tr_stored_block,_tr_flush_block,_tr_tally,_tr_align}=require("./trees"),adler32=require("./adler32"),crc32=require("./crc32"),msg=require("./messages"),{Z_NO_FLUSH,Z_PARTIAL_FLUSH,Z_FULL_FLUSH,Z_FINISH,Z_BLOCK,Z_OK,Z_STREAM_END,Z_STREAM_ERROR,Z_DATA_ERROR,Z_BUF_ERROR,Z_DEFAULT_COMPRESSION,Z_FILTERED,Z_HUFFMAN_ONLY,Z_RLE,Z_FIXED,Z_DEFAULT_STRATEGY,Z_UNKNOWN,Z_DEFLATED}=require("./constants"),MAX_MEM_LEVEL=9,MAX_WBITS=15,DEF_MEM_LEVEL=8,LENGTH_CODES=29,LITERALS=256,L_CODES=LITERALS+1+LENGTH_CODES,D_CODES=30,BL_CODES=19,HEAP_SIZE=2*L_CODES+1,MAX_BITS=15,MIN_MATCH=3,MAX_MATCH=258,MIN_LOOKAHEAD=MAX_MATCH+MIN_MATCH+1,PRESET_DICT=32,INIT_STATE=42,EXTRA_STATE=69,NAME_STATE=73,COMMENT_STATE=91,HCRC_STATE=103,BUSY_STATE=113,FINISH_STATE=666,BS_NEED_MORE=1,BS_BLOCK_DONE=2,BS_FINISH_STARTED=3,BS_FINISH_DONE=4,OS_CODE=3,err=(t,i)=>(t.msg=msg[i],i),rank=t=>(t<<1)-(t>4?9:0),zero=t=>{let i=t.length;for(;--i>=0;)t[i]=0};let HASH_ZLIB=(t,i,n)=>(i<<t.hash_shift^n)&t.hash_mask,HASH=HASH_ZLIB;const flush_pending=t=>{const i=t.state;let n=i.pending;n>t.avail_out&&(n=t.avail_out),n!==0&&(t.output.set(i.pending_buf.subarray(i.pending_out,i.pending_out+n),t.next_out),t.next_out+=n,i.pending_out+=n,t.total_out+=n,t.avail_out-=n,i.pending-=n,i.pending===0&&(i.pending_out=0))},flush_block_only=(t,i)=>{_tr_flush_block(t,t.block_start>=0?t.block_start:-1,t.strstart-t.block_start,i),t.block_start=t.strstart,flush_pending(t.strm)},put_byte=(t,i)=>{t.pending_buf[t.pending++]=i},putShortMSB=(t,i)=>{t.pending_buf[t.pending++]=i>>>8&255,t.pending_buf[t.pending++]=i&255},read_buf=(t,i,n,a)=>{let e=t.avail_in;return e>a&&(e=a),e===0?0:(t.avail_in-=e,i.set(t.input.subarray(t.next_in,t.next_in+e),n),t.state.wrap===1?t.adler=adler32(t.adler,i,e,n):t.state.wrap===2&&(t.adler=crc32(t.adler,i,e,n)),t.next_in+=e,t.total_in+=e,e)},longest_match=(t,i)=>{let n=t.max_chain_length,a=t.strstart,e,h,l=t.prev_length,r=t.nice_match;const o=t.strstart>t.w_size-MIN_LOOKAHEAD?t.strstart-(t.w_size-MIN_LOOKAHEAD):0,_=t.window,u=t.w_mask,g=t.prev,d=t.strstart+MAX_MATCH;let f=_[a+l-1],c=_[a+l];t.prev_length>=t.good_match&&(n>>=2),r>t.lookahead&&(r=t.lookahead);do if(e=i,!(_[e+l]!==c||_[e+l-1]!==f||_[e]!==_[a]||_[++e]!==_[a+1])){a+=2,e++;do;while(_[++a]===_[++e]&&_[++a]===_[++e]&&_[++a]===_[++e]&&_[++a]===_[++e]&&_[++a]===_[++e]&&_[++a]===_[++e]&&_[++a]===_[++e]&&_[++a]===_[++e]&&a<d);if(h=MAX_MATCH-(d-a),a=d-MAX_MATCH,h>l){if(t.match_start=i,l=h,h>=r)break;f=_[a+l-1],c=_[a+l]}}while((i=g[i&u])>o&&--n!=0);return l<=t.lookahead?l:t.lookahead},fill_window=t=>{const i=t.w_size;let n,a,e,h,l;do{if(h=t.window_size-t.lookahead-t.strstart,t.strstart>=i+(i-MIN_LOOKAHEAD)){t.window.set(t.window.subarray(i,i+i),0),t.match_start-=i,t.strstart-=i,t.block_start-=i,a=t.hash_size,n=a;do e=t.head[--n],t.head[n]=e>=i?e-i:0;while(--a);a=i,n=a;do e=t.prev[--n],t.prev[n]=e>=i?e-i:0;while(--a);h+=i}if(t.strm.avail_in===0)break;if(a=read_buf(t.strm,t.window,t.strstart+t.lookahead,h),t.lookahead+=a,t.lookahead+t.insert>=MIN_MATCH)for(l=t.strstart-t.insert,t.ins_h=t.window[l],t.ins_h=HASH(t,t.ins_h,t.window[l+1]);t.insert&&(t.ins_h=HASH(t,t.ins_h,t.window[l+MIN_MATCH-1]),t.prev[l&t.w_mask]=t.head[t.ins_h],t.head[t.ins_h]=l,l++,t.insert--,!(t.lookahead+t.insert<MIN_MATCH)););}while(t.lookahead<MIN_LOOKAHEAD&&t.strm.avail_in!==0)},deflate_stored=(t,i)=>{let n=65535;for(n>t.pending_buf_size-5&&(n=t.pending_buf_size-5);;){if(t.lookahead<=1){if(fill_window(t),t.lookahead===0&&i===Z_NO_FLUSH)return BS_NEED_MORE;if(t.lookahead===0)break}t.strstart+=t.lookahead,t.lookahead=0;const a=t.block_start+n;if((t.strstart===0||t.strstart>=a)&&(t.lookahead=t.strstart-a,t.strstart=a,flush_block_only(t,!1),t.strm.avail_out===0)||t.strstart-t.block_start>=t.w_size-MIN_LOOKAHEAD&&(flush_block_only(t,!1),t.strm.avail_out===0))return BS_NEED_MORE}return t.insert=0,i===Z_FINISH?(flush_block_only(t,!0),t.strm.avail_out===0?BS_FINISH_STARTED:BS_FINISH_DONE):(t.strstart>t.block_start&&(flush_block_only(t,!1),t.strm.avail_out===0),BS_NEED_MORE)},deflate_fast=(t,i)=>{let n,a;for(;;){if(t.lookahead<MIN_LOOKAHEAD){if(fill_window(t),t.lookahead<MIN_LOOKAHEAD&&i===Z_NO_FLUSH)return BS_NEED_MORE;if(t.lookahead===0)break}if(n=0,t.lookahead>=MIN_MATCH&&(t.ins_h=HASH(t,t.ins_h,t.window[t.strstart+MIN_MATCH-1]),n=t.prev[t.strstart&t.w_mask]=t.head[t.ins_h],t.head[t.ins_h]=t.strstart),n!==0&&t.strstart-n<=t.w_size-MIN_LOOKAHEAD&&(t.match_length=longest_match(t,n)),t.match_length>=MIN_MATCH)if(a=_tr_tally(t,t.strstart-t.match_start,t.match_length-MIN_MATCH),t.lookahead-=t.match_length,t.match_length<=t.max_lazy_match&&t.lookahead>=MIN_MATCH){t.match_length--;do t.strstart++,t.ins_h=HASH(t,t.ins_h,t.window[t.strstart+MIN_MATCH-1]),n=t.prev[t.strstart&t.w_mask]=t.head[t.ins_h],t.head[t.ins_h]=t.strstart;while(--t.match_length!=0);t.strstart++}else t.strstart+=t.match_length,t.match_length=0,t.ins_h=t.window[t.strstart],t.ins_h=HASH(t,t.ins_h,t.window[t.strstart+1]);else a=_tr_tally(t,0,t.window[t.strstart]),t.lookahead--,t.strstart++;if(a&&(flush_block_only(t,!1),t.strm.avail_out===0))return BS_NEED_MORE}return t.insert=t.strstart<MIN_MATCH-1?t.strstart:MIN_MATCH-1,i===Z_FINISH?(flush_block_only(t,!0),t.strm.avail_out===0?BS_FINISH_STARTED:BS_FINISH_DONE):t.last_lit&&(flush_block_only(t,!1),t.strm.avail_out===0)?BS_NEED_MORE:BS_BLOCK_DONE},deflate_slow=(t,i)=>{let n,a,e;for(;;){if(t.lookahead<MIN_LOOKAHEAD){if(fill_window(t),t.lookahead<MIN_LOOKAHEAD&&i===Z_NO_FLUSH)return BS_NEED_MORE;if(t.lookahead===0)break}if(n=0,t.lookahead>=MIN_MATCH&&(t.ins_h=HASH(t,t.ins_h,t.window[t.strstart+MIN_MATCH-1]),n=t.prev[t.strstart&t.w_mask]=t.head[t.ins_h],t.head[t.ins_h]=t.strstart),t.prev_length=t.match_length,t.prev_match=t.match_start,t.match_length=MIN_MATCH-1,n!==0&&t.prev_length<t.max_lazy_match&&t.strstart-n<=t.w_size-MIN_LOOKAHEAD&&(t.match_length=longest_match(t,n),t.match_length<=5&&(t.strategy===Z_FILTERED||t.match_length===MIN_MATCH&&t.strstart-t.match_start>4096)&&(t.match_length=MIN_MATCH-1)),t.prev_length>=MIN_MATCH&&t.match_length<=t.prev_length){e=t.strstart+t.lookahead-MIN_MATCH,a=_tr_tally(t,t.strstart-1-t.prev_match,t.prev_length-MIN_MATCH),t.lookahead-=t.prev_length-1,t.prev_length-=2;do++t.strstart<=e&&(t.ins_h=HASH(t,t.ins_h,t.window[t.strstart+MIN_MATCH-1]),n=t.prev[t.strstart&t.w_mask]=t.head[t.ins_h],t.head[t.ins_h]=t.strstart);while(--t.prev_length!=0);if(t.match_available=0,t.match_length=MIN_MATCH-1,t.strstart++,a&&(flush_block_only(t,!1),t.strm.avail_out===0))return BS_NEED_MORE}else if(t.match_available){if(a=_tr_tally(t,0,t.window[t.strstart-1]),a&&flush_block_only(t,!1),t.strstart++,t.lookahead--,t.strm.avail_out===0)return BS_NEED_MORE}else t.match_available=1,t.strstart++,t.lookahead--}return t.match_available&&(a=_tr_tally(t,0,t.window[t.strstart-1]),t.match_available=0),t.insert=t.strstart<MIN_MATCH-1?t.strstart:MIN_MATCH-1,i===Z_FINISH?(flush_block_only(t,!0),t.strm.avail_out===0?BS_FINISH_STARTED:BS_FINISH_DONE):t.last_lit&&(flush_block_only(t,!1),t.strm.avail_out===0)?BS_NEED_MORE:BS_BLOCK_DONE},deflate_rle=(t,i)=>{let n,a,e,h;const l=t.window;for(;;){if(t.lookahead<=MAX_MATCH){if(fill_window(t),t.lookahead<=MAX_MATCH&&i===Z_NO_FLUSH)return BS_NEED_MORE;if(t.lookahead===0)break}if(t.match_length=0,t.lookahead>=MIN_MATCH&&t.strstart>0&&(e=t.strstart-1,a=l[e],a===l[++e]&&a===l[++e]&&a===l[++e])){h=t.strstart+MAX_MATCH;do;while(a===l[++e]&&a===l[++e]&&a===l[++e]&&a===l[++e]&&a===l[++e]&&a===l[++e]&&a===l[++e]&&a===l[++e]&&e<h);t.match_length=MAX_MATCH-(h-e),t.match_length>t.lookahead&&(t.match_length=t.lookahead)}if(t.match_length>=MIN_MATCH?(n=_tr_tally(t,1,t.match_length-MIN_MATCH),t.lookahead-=t.match_length,t.strstart+=t.match_length,t.match_length=0):(n=_tr_tally(t,0,t.window[t.strstart]),t.lookahead--,t.strstart++),n&&(flush_block_only(t,!1),t.strm.avail_out===0))return BS_NEED_MORE}return t.insert=0,i===Z_FINISH?(flush_block_only(t,!0),t.strm.avail_out===0?BS_FINISH_STARTED:BS_FINISH_DONE):t.last_lit&&(flush_block_only(t,!1),t.strm.avail_out===0)?BS_NEED_MORE:BS_BLOCK_DONE},deflate_huff=(t,i)=>{let n;for(;;){if(t.lookahead===0&&(fill_window(t),t.lookahead===0)){if(i===Z_NO_FLUSH)return BS_NEED_MORE;break}if(t.match_length=0,n=_tr_tally(t,0,t.window[t.strstart]),t.lookahead--,t.strstart++,n&&(flush_block_only(t,!1),t.strm.avail_out===0))return BS_NEED_MORE}return t.insert=0,i===Z_FINISH?(flush_block_only(t,!0),t.strm.avail_out===0?BS_FINISH_STARTED:BS_FINISH_DONE):t.last_lit&&(flush_block_only(t,!1),t.strm.avail_out===0)?BS_NEED_MORE:BS_BLOCK_DONE};function Config(t,i,n,a,e){this.good_length=t,this.max_lazy=i,this.nice_length=n,this.max_chain=a,this.func=e}const configuration_table=[new Config(0,0,0,0,deflate_stored),new Config(4,4,8,4,deflate_fast),new Config(4,5,16,8,deflate_fast),new Config(4,6,32,32,deflate_fast),new Config(4,4,16,16,deflate_slow),new Config(8,16,32,32,deflate_slow),new Config(8,16,128,128,deflate_slow),new Config(8,32,128,256,deflate_slow),new Config(32,128,258,1024,deflate_slow),new Config(32,258,258,4096,deflate_slow)],lm_init=t=>{t.window_size=2*t.w_size,zero(t.head),t.max_lazy_match=configuration_table[t.level].max_lazy,t.good_match=configuration_table[t.level].good_length,t.nice_match=configuration_table[t.level].nice_length,t.max_chain_length=configuration_table[t.level].max_chain,t.strstart=0,t.block_start=0,t.lookahead=0,t.insert=0,t.match_length=t.prev_length=MIN_MATCH-1,t.match_available=0,t.ins_h=0};function DeflateState(){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=Z_DEFLATED,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 Uint16Array(HEAP_SIZE*2),this.dyn_dtree=new Uint16Array((2*D_CODES+1)*2),this.bl_tree=new Uint16Array((2*BL_CODES+1)*2),zero(this.dyn_ltree),zero(this.dyn_dtree),zero(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new Uint16Array(MAX_BITS+1),this.heap=new Uint16Array(2*L_CODES+1),zero(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new Uint16Array(2*L_CODES+1),zero(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}const deflateResetKeep=t=>{if(!t||!t.state)return err(t,Z_STREAM_ERROR);t.total_in=t.total_out=0,t.data_type=Z_UNKNOWN;const i=t.state;return i.pending=0,i.pending_out=0,i.wrap<0&&(i.wrap=-i.wrap),i.status=i.wrap?INIT_STATE:BUSY_STATE,t.adler=i.wrap===2?0:1,i.last_flush=Z_NO_FLUSH,_tr_init(i),Z_OK},deflateReset=t=>{const i=deflateResetKeep(t);return i===Z_OK&&lm_init(t.state),i},deflateSetHeader=(t,i)=>!t||!t.state||t.state.wrap!==2?Z_STREAM_ERROR:(t.state.gzhead=i,Z_OK),deflateInit2=(t,i,n,a,e,h)=>{if(!t)return Z_STREAM_ERROR;let l=1;if(i===Z_DEFAULT_COMPRESSION&&(i=6),a<0?(l=0,a=-a):a>15&&(l=2,a-=16),e<1||e>MAX_MEM_LEVEL||n!==Z_DEFLATED||a<8||a>15||i<0||i>9||h<0||h>Z_FIXED)return err(t,Z_STREAM_ERROR);a===8&&(a=9);const r=new DeflateState;return t.state=r,r.strm=t,r.wrap=l,r.gzhead=null,r.w_bits=a,r.w_size=1<<r.w_bits,r.w_mask=r.w_size-1,r.hash_bits=e+7,r.hash_size=1<<r.hash_bits,r.hash_mask=r.hash_size-1,r.hash_shift=~~((r.hash_bits+MIN_MATCH-1)/MIN_MATCH),r.window=new Uint8Array(r.w_size*2),r.head=new Uint16Array(r.hash_size),r.prev=new Uint16Array(r.w_size),r.lit_bufsize=1<<e+6,r.pending_buf_size=r.lit_bufsize*4,r.pending_buf=new Uint8Array(r.pending_buf_size),r.d_buf=1*r.lit_bufsize,r.l_buf=(1+2)*r.lit_bufsize,r.level=i,r.strategy=h,r.method=n,deflateReset(t)},deflateInit=(t,i)=>deflateInit2(t,i,Z_DEFLATED,MAX_WBITS,DEF_MEM_LEVEL,Z_DEFAULT_STRATEGY),deflate=(t,i)=>{let n,a;if(!t||!t.state||i>Z_BLOCK||i<0)return t?err(t,Z_STREAM_ERROR):Z_STREAM_ERROR;const e=t.state;if(!t.output||!t.input&&t.avail_in!==0||e.status===FINISH_STATE&&i!==Z_FINISH)return err(t,t.avail_out===0?Z_BUF_ERROR:Z_STREAM_ERROR);e.strm=t;const h=e.last_flush;if(e.last_flush=i,e.status===INIT_STATE)if(e.wrap===2)t.adler=0,put_byte(e,31),put_byte(e,139),put_byte(e,8),e.gzhead?(put_byte(e,(e.gzhead.text?1:0)+(e.gzhead.hcrc?2:0)+(e.gzhead.extra?4:0)+(e.gzhead.name?8:0)+(e.gzhead.comment?16:0)),put_byte(e,e.gzhead.time&255),put_byte(e,e.gzhead.time>>8&255),put_byte(e,e.gzhead.time>>16&255),put_byte(e,e.gzhead.time>>24&255),put_byte(e,e.level===9?2:e.strategy>=Z_HUFFMAN_ONLY||e.level<2?4:0),put_byte(e,e.gzhead.os&255),e.gzhead.extra&&e.gzhead.extra.length&&(put_byte(e,e.gzhead.extra.length&255),put_byte(e,e.gzhead.extra.length>>8&255)),e.gzhead.hcrc&&(t.adler=crc32(t.adler,e.pending_buf,e.pending,0)),e.gzindex=0,e.status=EXTRA_STATE):(put_byte(e,0),put_byte(e,0),put_byte(e,0),put_byte(e,0),put_byte(e,0),put_byte(e,e.level===9?2:e.strategy>=Z_HUFFMAN_ONLY||e.level<2?4:0),put_byte(e,OS_CODE),e.status=BUSY_STATE);else{let l=Z_DEFLATED+(e.w_bits-8<<4)<<8,r=-1;e.strategy>=Z_HUFFMAN_ONLY||e.level<2?r=0:e.level<6?r=1:e.level===6?r=2:r=3,l|=r<<6,e.strstart!==0&&(l|=PRESET_DICT),l+=31-l%31,e.status=BUSY_STATE,putShortMSB(e,l),e.strstart!==0&&(putShortMSB(e,t.adler>>>16),putShortMSB(e,t.adler&65535)),t.adler=1}if(e.status===EXTRA_STATE)if(e.gzhead.extra){for(n=e.pending;e.gzindex<(e.gzhead.extra.length&65535)&&!(e.pending===e.pending_buf_size&&(e.gzhead.hcrc&&e.pending>n&&(t.adler=crc32(t.adler,e.pending_buf,e.pending-n,n)),flush_pending(t),n=e.pending,e.pending===e.pending_buf_size));)put_byte(e,e.gzhead.extra[e.gzindex]&255),e.gzindex++;e.gzhead.hcrc&&e.pending>n&&(t.adler=crc32(t.adler,e.pending_buf,e.pending-n,n)),e.gzindex===e.gzhead.extra.length&&(e.gzindex=0,e.status=NAME_STATE)}else e.status=NAME_STATE;if(e.status===NAME_STATE)if(e.gzhead.name){n=e.pending;do{if(e.pending===e.pending_buf_size&&(e.gzhead.hcrc&&e.pending>n&&(t.adler=crc32(t.adler,e.pending_buf,e.pending-n,n)),flush_pending(t),n=e.pending,e.pending===e.pending_buf_size)){a=1;break}e.gzindex<e.gzhead.name.length?a=e.gzhead.name.charCodeAt(e.gzindex++)&255:a=0,put_byte(e,a)}while(a!==0);e.gzhead.hcrc&&e.pending>n&&(t.adler=crc32(t.adler,e.pending_buf,e.pending-n,n)),a===0&&(e.gzindex=0,e.status=COMMENT_STATE)}else e.status=COMMENT_STATE;if(e.status===COMMENT_STATE)if(e.gzhead.comment){n=e.pending;do{if(e.pending===e.pending_buf_size&&(e.gzhead.hcrc&&e.pending>n&&(t.adler=crc32(t.adler,e.pending_buf,e.pending-n,n)),flush_pending(t),n=e.pending,e.pending===e.pending_buf_size)){a=1;break}e.gzindex<e.gzhead.comment.length?a=e.gzhead.comment.charCodeAt(e.gzindex++)&255:a=0,put_byte(e,a)}while(a!==0);e.gzhead.hcrc&&e.pending>n&&(t.adler=crc32(t.adler,e.pending_buf,e.pending-n,n)),a===0&&(e.status=HCRC_STATE)}else e.status=HCRC_STATE;if(e.status===HCRC_STATE&&(e.gzhead.hcrc?(e.pending+2>e.pending_buf_size&&flush_pending(t),e.pending+2<=e.pending_buf_size&&(put_byte(e,t.adler&255),put_byte(e,t.adler>>8&255),t.adler=0,e.status=BUSY_STATE)):e.status=BUSY_STATE),e.pending!==0){if(flush_pending(t),t.avail_out===0)return e.last_flush=-1,Z_OK}else if(t.avail_in===0&&rank(i)<=rank(h)&&i!==Z_FINISH)return err(t,Z_BUF_ERROR);if(e.status===FINISH_STATE&&t.avail_in!==0)return err(t,Z_BUF_ERROR);if(t.avail_in!==0||e.lookahead!==0||i!==Z_NO_FLUSH&&e.status!==FINISH_STATE){let l=e.strategy===Z_HUFFMAN_ONLY?deflate_huff(e,i):e.strategy===Z_RLE?deflate_rle(e,i):configuration_table[e.level].func(e,i);if((l===BS_FINISH_STARTED||l===BS_FINISH_DONE)&&(e.status=FINISH_STATE),l===BS_NEED_MORE||l===BS_FINISH_STARTED)return t.avail_out===0&&(e.last_flush=-1),Z_OK;if(l===BS_BLOCK_DONE&&(i===Z_PARTIAL_FLUSH?_tr_align(e):i!==Z_BLOCK&&(_tr_stored_block(e,0,0,!1),i===Z_FULL_FLUSH&&(zero(e.head),e.lookahead===0&&(e.strstart=0,e.block_start=0,e.insert=0))),flush_pending(t),t.avail_out===0))return e.last_flush=-1,Z_OK}return i!==Z_FINISH?Z_OK:e.wrap<=0?Z_STREAM_END:(e.wrap===2?(put_byte(e,t.adler&255),put_byte(e,t.adler>>8&255),put_byte(e,t.adler>>16&255),put_byte(e,t.adler>>24&255),put_byte(e,t.total_in&255),put_byte(e,t.total_in>>8&255),put_byte(e,t.total_in>>16&255),put_byte(e,t.total_in>>24&255)):(putShortMSB(e,t.adler>>>16),putShortMSB(e,t.adler&65535)),flush_pending(t),e.wrap>0&&(e.wrap=-e.wrap),e.pending!==0?Z_OK:Z_STREAM_END)},deflateEnd=t=>{if(!t||!t.state)return Z_STREAM_ERROR;const i=t.state.status;return i!==INIT_STATE&&i!==EXTRA_STATE&&i!==NAME_STATE&&i!==COMMENT_STATE&&i!==HCRC_STATE&&i!==BUSY_STATE&&i!==FINISH_STATE?err(t,Z_STREAM_ERROR):(t.state=null,i===BUSY_STATE?err(t,Z_DATA_ERROR):Z_OK)},deflateSetDictionary=(t,i)=>{let n=i.length;if(!t||!t.state)return Z_STREAM_ERROR;const a=t.state,e=a.wrap;if(e===2||e===1&&a.status!==INIT_STATE||a.lookahead)return Z_STREAM_ERROR;if(e===1&&(t.adler=adler32(t.adler,i,n,0)),a.wrap=0,n>=a.w_size){e===0&&(zero(a.head),a.strstart=0,a.block_start=0,a.insert=0);let o=new Uint8Array(a.w_size);o.set(i.subarray(n-a.w_size,n),0),i=o,n=a.w_size}const h=t.avail_in,l=t.next_in,r=t.input;for(t.avail_in=n,t.next_in=0,t.input=i,fill_window(a);a.lookahead>=MIN_MATCH;){let o=a.strstart,_=a.lookahead-(MIN_MATCH-1);do a.ins_h=HASH(a,a.ins_h,a.window[o+MIN_MATCH-1]),a.prev[o&a.w_mask]=a.head[a.ins_h],a.head[a.ins_h]=o,o++;while(--_);a.strstart=o,a.lookahead=MIN_MATCH-1,fill_window(a)}return a.strstart+=a.lookahead,a.block_start=a.strstart,a.insert=a.lookahead,a.lookahead=0,a.match_length=a.prev_length=MIN_MATCH-1,a.match_available=0,t.next_in=l,t.input=r,t.avail_in=h,a.wrap=e,Z_OK};module.exports.deflateInit=deflateInit,module.exports.deflateInit2=deflateInit2,module.exports.deflateReset=deflateReset,module.exports.deflateResetKeep=deflateResetKeep,module.exports.deflateSetHeader=deflateSetHeader,module.exports.deflate=deflate,module.exports.deflateEnd=deflateEnd,module.exports.deflateSetDictionary=deflateSetDictionary,module.exports.deflateInfo="pako deflate (from Nodeca project)";
2
- //# sourceMappingURL=deflate.js.map
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../../../../../../../../GDevelop/Extensions/TileMap/helper/node_modules/pako/lib/zlib/deflate.js"],
4
- "sourcesContent": ["'use strict';\n\n// (C) 1995-2013 Jean-loup Gailly and Mark Adler\n// (C) 2014-2017 Vitaly Puzrin and Andrey Tupitsin\n//\n// This software is provided 'as-is', without any express or implied\n// warranty. In no event will the authors be held liable for any damages\n// arising from the use of this software.\n//\n// Permission is granted to anyone to use this software for any purpose,\n// including commercial applications, and to alter it and redistribute it\n// freely, subject to the following restrictions:\n//\n// 1. The origin of this software must not be misrepresented; you must not\n// claim that you wrote the original software. If you use this software\n// in a product, an acknowledgment in the product documentation would be\n// appreciated but is not required.\n// 2. Altered source versions must be plainly marked as such, and must not be\n// misrepresented as being the original software.\n// 3. This notice may not be removed or altered from any source distribution.\n\nconst { _tr_init, _tr_stored_block, _tr_flush_block, _tr_tally, _tr_align } = require('./trees');\nconst adler32 = require('./adler32');\nconst crc32 = require('./crc32');\nconst msg = require('./messages');\n\n/* Public constants ==========================================================*/\n/* ===========================================================================*/\n\nconst {\n Z_NO_FLUSH, Z_PARTIAL_FLUSH, Z_FULL_FLUSH, Z_FINISH, Z_BLOCK,\n Z_OK, Z_STREAM_END, Z_STREAM_ERROR, Z_DATA_ERROR, Z_BUF_ERROR,\n Z_DEFAULT_COMPRESSION,\n Z_FILTERED, Z_HUFFMAN_ONLY, Z_RLE, Z_FIXED, Z_DEFAULT_STRATEGY,\n Z_UNKNOWN,\n Z_DEFLATED\n} = require('./constants');\n\n/*============================================================================*/\n\n\nconst MAX_MEM_LEVEL = 9;\n/* Maximum value for memLevel in deflateInit2 */\nconst MAX_WBITS = 15;\n/* 32K LZ77 window */\nconst DEF_MEM_LEVEL = 8;\n\n\nconst LENGTH_CODES = 29;\n/* number of length codes, not counting the special END_BLOCK code */\nconst LITERALS = 256;\n/* number of literal bytes 0..255 */\nconst L_CODES = LITERALS + 1 + LENGTH_CODES;\n/* number of Literal or Length codes, including the END_BLOCK code */\nconst D_CODES = 30;\n/* number of distance codes */\nconst BL_CODES = 19;\n/* number of codes used to transfer the bit lengths */\nconst HEAP_SIZE = 2 * L_CODES + 1;\n/* maximum heap size */\nconst MAX_BITS = 15;\n/* All codes must not exceed MAX_BITS bits */\n\nconst MIN_MATCH = 3;\nconst MAX_MATCH = 258;\nconst MIN_LOOKAHEAD = (MAX_MATCH + MIN_MATCH + 1);\n\nconst PRESET_DICT = 0x20;\n\nconst INIT_STATE = 42;\nconst EXTRA_STATE = 69;\nconst NAME_STATE = 73;\nconst COMMENT_STATE = 91;\nconst HCRC_STATE = 103;\nconst BUSY_STATE = 113;\nconst FINISH_STATE = 666;\n\nconst BS_NEED_MORE = 1; /* block not completed, need more input or more output */\nconst BS_BLOCK_DONE = 2; /* block flush performed */\nconst BS_FINISH_STARTED = 3; /* finish started, need only more output at next deflate */\nconst BS_FINISH_DONE = 4; /* finish done, accept no more input or output */\n\nconst OS_CODE = 0x03; // Unix :) . Don't detect, use this default.\n\nconst err = (strm, errorCode) => {\n strm.msg = msg[errorCode];\n return errorCode;\n};\n\nconst rank = (f) => {\n return ((f) << 1) - ((f) > 4 ? 9 : 0);\n};\n\nconst zero = (buf) => {\n let len = buf.length; while (--len >= 0) { buf[len] = 0; }\n};\n\n\n/* eslint-disable new-cap */\nlet HASH_ZLIB = (s, prev, data) => ((prev << s.hash_shift) ^ data) & s.hash_mask;\n// This hash causes less collisions, https://github.com/nodeca/pako/issues/135\n// But breaks binary compatibility\n//let HASH_FAST = (s, prev, data) => ((prev << 8) + (prev >> 8) + (data << 4)) & s.hash_mask;\nlet HASH = HASH_ZLIB;\n\n/* =========================================================================\n * Flush as much pending output as possible. All deflate() output goes\n * through this function so some applications may wish to modify it\n * to avoid allocating a large strm->output buffer and copying into it.\n * (See also read_buf()).\n */\nconst flush_pending = (strm) => {\n const s = strm.state;\n\n //_tr_flush_bits(s);\n let len = s.pending;\n if (len > strm.avail_out) {\n len = strm.avail_out;\n }\n if (len === 0) { return; }\n\n strm.output.set(s.pending_buf.subarray(s.pending_out, s.pending_out + len), strm.next_out);\n strm.next_out += len;\n s.pending_out += len;\n strm.total_out += len;\n strm.avail_out -= len;\n s.pending -= len;\n if (s.pending === 0) {\n s.pending_out = 0;\n }\n};\n\n\nconst flush_block_only = (s, last) => {\n _tr_flush_block(s, (s.block_start >= 0 ? s.block_start : -1), s.strstart - s.block_start, last);\n s.block_start = s.strstart;\n flush_pending(s.strm);\n};\n\n\nconst put_byte = (s, b) => {\n s.pending_buf[s.pending++] = b;\n};\n\n\n/* =========================================================================\n * Put a short in the pending buffer. The 16-bit value is put in MSB order.\n * IN assertion: the stream state is correct and there is enough room in\n * pending_buf.\n */\nconst putShortMSB = (s, b) => {\n\n // put_byte(s, (Byte)(b >> 8));\n// put_byte(s, (Byte)(b & 0xff));\n s.pending_buf[s.pending++] = (b >>> 8) & 0xff;\n s.pending_buf[s.pending++] = b & 0xff;\n};\n\n\n/* ===========================================================================\n * Read a new buffer from the current input stream, update the adler32\n * and total number of bytes read. All deflate() input goes through\n * this function so some applications may wish to modify it to avoid\n * allocating a large strm->input buffer and copying from it.\n * (See also flush_pending()).\n */\nconst read_buf = (strm, buf, start, size) => {\n\n let len = strm.avail_in;\n\n if (len > size) { len = size; }\n if (len === 0) { return 0; }\n\n strm.avail_in -= len;\n\n // zmemcpy(buf, strm->next_in, len);\n buf.set(strm.input.subarray(strm.next_in, strm.next_in + len), start);\n if (strm.state.wrap === 1) {\n strm.adler = adler32(strm.adler, buf, len, start);\n }\n\n else if (strm.state.wrap === 2) {\n strm.adler = crc32(strm.adler, buf, len, start);\n }\n\n strm.next_in += len;\n strm.total_in += len;\n\n return len;\n};\n\n\n/* ===========================================================================\n * Set match_start to the longest match starting at the given string and\n * return its length. Matches shorter or equal to prev_length are discarded,\n * in which case the result is equal to prev_length and match_start is\n * garbage.\n * IN assertions: cur_match is the head of the hash chain for the current\n * string (strstart) and its distance is <= MAX_DIST, and prev_length >= 1\n * OUT assertion: the match length is not greater than s->lookahead.\n */\nconst longest_match = (s, cur_match) => {\n\n let chain_length = s.max_chain_length; /* max hash chain length */\n let scan = s.strstart; /* current string */\n let match; /* matched string */\n let len; /* length of current match */\n let best_len = s.prev_length; /* best match length so far */\n let nice_match = s.nice_match; /* stop if match long enough */\n const limit = (s.strstart > (s.w_size - MIN_LOOKAHEAD)) ?\n s.strstart - (s.w_size - MIN_LOOKAHEAD) : 0/*NIL*/;\n\n const _win = s.window; // shortcut\n\n const wmask = s.w_mask;\n const prev = s.prev;\n\n /* Stop when cur_match becomes <= limit. To simplify the code,\n * we prevent matches with the string of window index 0.\n */\n\n const strend = s.strstart + MAX_MATCH;\n let scan_end1 = _win[scan + best_len - 1];\n let scan_end = _win[scan + best_len];\n\n /* The code is optimized for HASH_BITS >= 8 and MAX_MATCH-2 multiple of 16.\n * It is easy to get rid of this optimization if necessary.\n */\n // Assert(s->hash_bits >= 8 && MAX_MATCH == 258, \"Code too clever\");\n\n /* Do not waste too much time if we already have a good match: */\n if (s.prev_length >= s.good_match) {\n chain_length >>= 2;\n }\n /* Do not look for matches beyond the end of the input. This is necessary\n * to make deflate deterministic.\n */\n if (nice_match > s.lookahead) { nice_match = s.lookahead; }\n\n // Assert((ulg)s->strstart <= s->window_size-MIN_LOOKAHEAD, \"need lookahead\");\n\n do {\n // Assert(cur_match < s->strstart, \"no future\");\n match = cur_match;\n\n /* Skip to next match if the match length cannot increase\n * or if the match length is less than 2. Note that the checks below\n * for insufficient lookahead only occur occasionally for performance\n * reasons. Therefore uninitialized memory will be accessed, and\n * conditional jumps will be made that depend on those values.\n * However the length of the match is limited to the lookahead, so\n * the output of deflate is not affected by the uninitialized values.\n */\n\n if (_win[match + best_len] !== scan_end ||\n _win[match + best_len - 1] !== scan_end1 ||\n _win[match] !== _win[scan] ||\n _win[++match] !== _win[scan + 1]) {\n continue;\n }\n\n /* The check at best_len-1 can be removed because it will be made\n * again later. (This heuristic is not always a win.)\n * It is not necessary to compare scan[2] and match[2] since they\n * are always equal when the other bytes match, given that\n * the hash keys are equal and that HASH_BITS >= 8.\n */\n scan += 2;\n match++;\n // Assert(*scan == *match, \"match[2]?\");\n\n /* We check for insufficient lookahead only every 8th comparison;\n * the 256th check will be made at strstart+258.\n */\n do {\n /*jshint noempty:false*/\n } while (_win[++scan] === _win[++match] && _win[++scan] === _win[++match] &&\n _win[++scan] === _win[++match] && _win[++scan] === _win[++match] &&\n _win[++scan] === _win[++match] && _win[++scan] === _win[++match] &&\n _win[++scan] === _win[++match] && _win[++scan] === _win[++match] &&\n scan < strend);\n\n // Assert(scan <= s->window+(unsigned)(s->window_size-1), \"wild scan\");\n\n len = MAX_MATCH - (strend - scan);\n scan = strend - MAX_MATCH;\n\n if (len > best_len) {\n s.match_start = cur_match;\n best_len = len;\n if (len >= nice_match) {\n break;\n }\n scan_end1 = _win[scan + best_len - 1];\n scan_end = _win[scan + best_len];\n }\n } while ((cur_match = prev[cur_match & wmask]) > limit && --chain_length !== 0);\n\n if (best_len <= s.lookahead) {\n return best_len;\n }\n return s.lookahead;\n};\n\n\n/* ===========================================================================\n * Fill the window when the lookahead becomes insufficient.\n * Updates strstart and lookahead.\n *\n * IN assertion: lookahead < MIN_LOOKAHEAD\n * OUT assertions: strstart <= window_size-MIN_LOOKAHEAD\n * At least one byte has been read, or avail_in == 0; reads are\n * performed for at least two bytes (required for the zip translate_eol\n * option -- not supported here).\n */\nconst fill_window = (s) => {\n\n const _w_size = s.w_size;\n let p, n, m, more, str;\n\n //Assert(s->lookahead < MIN_LOOKAHEAD, \"already enough lookahead\");\n\n do {\n more = s.window_size - s.lookahead - s.strstart;\n\n // JS ints have 32 bit, block below not needed\n /* Deal with !@#$% 64K limit: */\n //if (sizeof(int) <= 2) {\n // if (more == 0 && s->strstart == 0 && s->lookahead == 0) {\n // more = wsize;\n //\n // } else if (more == (unsigned)(-1)) {\n // /* Very unlikely, but possible on 16 bit machine if\n // * strstart == 0 && lookahead == 1 (input done a byte at time)\n // */\n // more--;\n // }\n //}\n\n\n /* If the window is almost full and there is insufficient lookahead,\n * move the upper half to the lower one to make room in the upper half.\n */\n if (s.strstart >= _w_size + (_w_size - MIN_LOOKAHEAD)) {\n\n s.window.set(s.window.subarray(_w_size, _w_size + _w_size), 0);\n s.match_start -= _w_size;\n s.strstart -= _w_size;\n /* we now have strstart >= MAX_DIST */\n s.block_start -= _w_size;\n\n /* Slide the hash table (could be avoided with 32 bit values\n at the expense of memory usage). We slide even when level == 0\n to keep the hash table consistent if we switch back to level > 0\n later. (Using level 0 permanently is not an optimal usage of\n zlib, so we don't care about this pathological case.)\n */\n\n n = s.hash_size;\n p = n;\n\n do {\n m = s.head[--p];\n s.head[p] = (m >= _w_size ? m - _w_size : 0);\n } while (--n);\n\n n = _w_size;\n p = n;\n\n do {\n m = s.prev[--p];\n s.prev[p] = (m >= _w_size ? m - _w_size : 0);\n /* If n is not on any hash chain, prev[n] is garbage but\n * its value will never be used.\n */\n } while (--n);\n\n more += _w_size;\n }\n if (s.strm.avail_in === 0) {\n break;\n }\n\n /* If there was no sliding:\n * strstart <= WSIZE+MAX_DIST-1 && lookahead <= MIN_LOOKAHEAD - 1 &&\n * more == window_size - lookahead - strstart\n * => more >= window_size - (MIN_LOOKAHEAD-1 + WSIZE + MAX_DIST-1)\n * => more >= window_size - 2*WSIZE + 2\n * In the BIG_MEM or MMAP case (not yet supported),\n * window_size == input_size + MIN_LOOKAHEAD &&\n * strstart + s->lookahead <= input_size => more >= MIN_LOOKAHEAD.\n * Otherwise, window_size == 2*WSIZE so more >= 2.\n * If there was sliding, more >= WSIZE. So in all cases, more >= 2.\n */\n //Assert(more >= 2, \"more < 2\");\n n = read_buf(s.strm, s.window, s.strstart + s.lookahead, more);\n s.lookahead += n;\n\n /* Initialize the hash value now that we have some input: */\n if (s.lookahead + s.insert >= MIN_MATCH) {\n str = s.strstart - s.insert;\n s.ins_h = s.window[str];\n\n /* UPDATE_HASH(s, s->ins_h, s->window[str + 1]); */\n s.ins_h = HASH(s, s.ins_h, s.window[str + 1]);\n//#if MIN_MATCH != 3\n// Call update_hash() MIN_MATCH-3 more times\n//#endif\n while (s.insert) {\n /* UPDATE_HASH(s, s->ins_h, s->window[str + MIN_MATCH-1]); */\n s.ins_h = HASH(s, s.ins_h, s.window[str + MIN_MATCH - 1]);\n\n s.prev[str & s.w_mask] = s.head[s.ins_h];\n s.head[s.ins_h] = str;\n str++;\n s.insert--;\n if (s.lookahead + s.insert < MIN_MATCH) {\n break;\n }\n }\n }\n /* If the whole input has less than MIN_MATCH bytes, ins_h is garbage,\n * but this is not important since only literal bytes will be emitted.\n */\n\n } while (s.lookahead < MIN_LOOKAHEAD && s.strm.avail_in !== 0);\n\n /* If the WIN_INIT bytes after the end of the current data have never been\n * written, then zero those bytes in order to avoid memory check reports of\n * the use of uninitialized (or uninitialised as Julian writes) bytes by\n * the longest match routines. Update the high water mark for the next\n * time through here. WIN_INIT is set to MAX_MATCH since the longest match\n * routines allow scanning to strstart + MAX_MATCH, ignoring lookahead.\n */\n// if (s.high_water < s.window_size) {\n// const curr = s.strstart + s.lookahead;\n// let init = 0;\n//\n// if (s.high_water < curr) {\n// /* Previous high water mark below current data -- zero WIN_INIT\n// * bytes or up to end of window, whichever is less.\n// */\n// init = s.window_size - curr;\n// if (init > WIN_INIT)\n// init = WIN_INIT;\n// zmemzero(s->window + curr, (unsigned)init);\n// s->high_water = curr + init;\n// }\n// else if (s->high_water < (ulg)curr + WIN_INIT) {\n// /* High water mark at or above current data, but below current data\n// * plus WIN_INIT -- zero out to current data plus WIN_INIT, or up\n// * to end of window, whichever is less.\n// */\n// init = (ulg)curr + WIN_INIT - s->high_water;\n// if (init > s->window_size - s->high_water)\n// init = s->window_size - s->high_water;\n// zmemzero(s->window + s->high_water, (unsigned)init);\n// s->high_water += init;\n// }\n// }\n//\n// Assert((ulg)s->strstart <= s->window_size - MIN_LOOKAHEAD,\n// \"not enough room for search\");\n};\n\n/* ===========================================================================\n * Copy without compression as much as possible from the input stream, return\n * the current block state.\n * This function does not insert new strings in the dictionary since\n * uncompressible data is probably not useful. This function is used\n * only for the level=0 compression option.\n * NOTE: this function should be optimized to avoid extra copying from\n * window to pending_buf.\n */\nconst deflate_stored = (s, flush) => {\n\n /* Stored blocks are limited to 0xffff bytes, pending_buf is limited\n * to pending_buf_size, and each stored block has a 5 byte header:\n */\n let max_block_size = 0xffff;\n\n if (max_block_size > s.pending_buf_size - 5) {\n max_block_size = s.pending_buf_size - 5;\n }\n\n /* Copy as much as possible from input to output: */\n for (;;) {\n /* Fill the window as much as possible: */\n if (s.lookahead <= 1) {\n\n //Assert(s->strstart < s->w_size+MAX_DIST(s) ||\n // s->block_start >= (long)s->w_size, \"slide too late\");\n// if (!(s.strstart < s.w_size + (s.w_size - MIN_LOOKAHEAD) ||\n// s.block_start >= s.w_size)) {\n// throw new Error(\"slide too late\");\n// }\n\n fill_window(s);\n if (s.lookahead === 0 && flush === Z_NO_FLUSH) {\n return BS_NEED_MORE;\n }\n\n if (s.lookahead === 0) {\n break;\n }\n /* flush the current block */\n }\n //Assert(s->block_start >= 0L, \"block gone\");\n// if (s.block_start < 0) throw new Error(\"block gone\");\n\n s.strstart += s.lookahead;\n s.lookahead = 0;\n\n /* Emit a stored block if pending_buf will be full: */\n const max_start = s.block_start + max_block_size;\n\n if (s.strstart === 0 || s.strstart >= max_start) {\n /* strstart == 0 is possible when wraparound on 16-bit machine */\n s.lookahead = s.strstart - max_start;\n s.strstart = max_start;\n /*** FLUSH_BLOCK(s, 0); ***/\n flush_block_only(s, false);\n if (s.strm.avail_out === 0) {\n return BS_NEED_MORE;\n }\n /***/\n\n\n }\n /* Flush if we may have to slide, otherwise block_start may become\n * negative and the data will be gone:\n */\n if (s.strstart - s.block_start >= (s.w_size - MIN_LOOKAHEAD)) {\n /*** FLUSH_BLOCK(s, 0); ***/\n flush_block_only(s, false);\n if (s.strm.avail_out === 0) {\n return BS_NEED_MORE;\n }\n /***/\n }\n }\n\n s.insert = 0;\n\n if (flush === Z_FINISH) {\n /*** FLUSH_BLOCK(s, 1); ***/\n flush_block_only(s, true);\n if (s.strm.avail_out === 0) {\n return BS_FINISH_STARTED;\n }\n /***/\n return BS_FINISH_DONE;\n }\n\n if (s.strstart > s.block_start) {\n /*** FLUSH_BLOCK(s, 0); ***/\n flush_block_only(s, false);\n if (s.strm.avail_out === 0) {\n return BS_NEED_MORE;\n }\n /***/\n }\n\n return BS_NEED_MORE;\n};\n\n/* ===========================================================================\n * Compress as much as possible from the input stream, return the current\n * block state.\n * This function does not perform lazy evaluation of matches and inserts\n * new strings in the dictionary only for unmatched strings or for short\n * matches. It is used only for the fast compression options.\n */\nconst deflate_fast = (s, flush) => {\n\n let hash_head; /* head of the hash chain */\n let bflush; /* set if current block must be flushed */\n\n for (;;) {\n /* Make sure that we always have enough lookahead, except\n * at the end of the input file. We need MAX_MATCH bytes\n * for the next match, plus MIN_MATCH bytes to insert the\n * string following the next match.\n */\n if (s.lookahead < MIN_LOOKAHEAD) {\n fill_window(s);\n if (s.lookahead < MIN_LOOKAHEAD && flush === Z_NO_FLUSH) {\n return BS_NEED_MORE;\n }\n if (s.lookahead === 0) {\n break; /* flush the current block */\n }\n }\n\n /* Insert the string window[strstart .. strstart+2] in the\n * dictionary, and set hash_head to the head of the hash chain:\n */\n hash_head = 0/*NIL*/;\n if (s.lookahead >= MIN_MATCH) {\n /*** INSERT_STRING(s, s.strstart, hash_head); ***/\n s.ins_h = HASH(s, s.ins_h, s.window[s.strstart + MIN_MATCH - 1]);\n hash_head = s.prev[s.strstart & s.w_mask] = s.head[s.ins_h];\n s.head[s.ins_h] = s.strstart;\n /***/\n }\n\n /* Find the longest match, discarding those <= prev_length.\n * At this point we have always match_length < MIN_MATCH\n */\n if (hash_head !== 0/*NIL*/ && ((s.strstart - hash_head) <= (s.w_size - MIN_LOOKAHEAD))) {\n /* To simplify the code, we prevent matches with the string\n * of window index 0 (in particular we have to avoid a match\n * of the string with itself at the start of the input file).\n */\n s.match_length = longest_match(s, hash_head);\n /* longest_match() sets match_start */\n }\n if (s.match_length >= MIN_MATCH) {\n // check_match(s, s.strstart, s.match_start, s.match_length); // for debug only\n\n /*** _tr_tally_dist(s, s.strstart - s.match_start,\n s.match_length - MIN_MATCH, bflush); ***/\n bflush = _tr_tally(s, s.strstart - s.match_start, s.match_length - MIN_MATCH);\n\n s.lookahead -= s.match_length;\n\n /* Insert new strings in the hash table only if the match length\n * is not too large. This saves time but degrades compression.\n */\n if (s.match_length <= s.max_lazy_match/*max_insert_length*/ && s.lookahead >= MIN_MATCH) {\n s.match_length--; /* string at strstart already in table */\n do {\n s.strstart++;\n /*** INSERT_STRING(s, s.strstart, hash_head); ***/\n s.ins_h = HASH(s, s.ins_h, s.window[s.strstart + MIN_MATCH - 1]);\n hash_head = s.prev[s.strstart & s.w_mask] = s.head[s.ins_h];\n s.head[s.ins_h] = s.strstart;\n /***/\n /* strstart never exceeds WSIZE-MAX_MATCH, so there are\n * always MIN_MATCH bytes ahead.\n */\n } while (--s.match_length !== 0);\n s.strstart++;\n } else\n {\n s.strstart += s.match_length;\n s.match_length = 0;\n s.ins_h = s.window[s.strstart];\n /* UPDATE_HASH(s, s.ins_h, s.window[s.strstart+1]); */\n s.ins_h = HASH(s, s.ins_h, s.window[s.strstart + 1]);\n\n//#if MIN_MATCH != 3\n// Call UPDATE_HASH() MIN_MATCH-3 more times\n//#endif\n /* If lookahead < MIN_MATCH, ins_h is garbage, but it does not\n * matter since it will be recomputed at next deflate call.\n */\n }\n } else {\n /* No match, output a literal byte */\n //Tracevv((stderr,\"%c\", s.window[s.strstart]));\n /*** _tr_tally_lit(s, s.window[s.strstart], bflush); ***/\n bflush = _tr_tally(s, 0, s.window[s.strstart]);\n\n s.lookahead--;\n s.strstart++;\n }\n if (bflush) {\n /*** FLUSH_BLOCK(s, 0); ***/\n flush_block_only(s, false);\n if (s.strm.avail_out === 0) {\n return BS_NEED_MORE;\n }\n /***/\n }\n }\n s.insert = ((s.strstart < (MIN_MATCH - 1)) ? s.strstart : MIN_MATCH - 1);\n if (flush === Z_FINISH) {\n /*** FLUSH_BLOCK(s, 1); ***/\n flush_block_only(s, true);\n if (s.strm.avail_out === 0) {\n return BS_FINISH_STARTED;\n }\n /***/\n return BS_FINISH_DONE;\n }\n if (s.last_lit) {\n /*** FLUSH_BLOCK(s, 0); ***/\n flush_block_only(s, false);\n if (s.strm.avail_out === 0) {\n return BS_NEED_MORE;\n }\n /***/\n }\n return BS_BLOCK_DONE;\n};\n\n/* ===========================================================================\n * Same as above, but achieves better compression. We use a lazy\n * evaluation for matches: a match is finally adopted only if there is\n * no better match at the next window position.\n */\nconst deflate_slow = (s, flush) => {\n\n let hash_head; /* head of hash chain */\n let bflush; /* set if current block must be flushed */\n\n let max_insert;\n\n /* Process the input block. */\n for (;;) {\n /* Make sure that we always have enough lookahead, except\n * at the end of the input file. We need MAX_MATCH bytes\n * for the next match, plus MIN_MATCH bytes to insert the\n * string following the next match.\n */\n if (s.lookahead < MIN_LOOKAHEAD) {\n fill_window(s);\n if (s.lookahead < MIN_LOOKAHEAD && flush === Z_NO_FLUSH) {\n return BS_NEED_MORE;\n }\n if (s.lookahead === 0) { break; } /* flush the current block */\n }\n\n /* Insert the string window[strstart .. strstart+2] in the\n * dictionary, and set hash_head to the head of the hash chain:\n */\n hash_head = 0/*NIL*/;\n if (s.lookahead >= MIN_MATCH) {\n /*** INSERT_STRING(s, s.strstart, hash_head); ***/\n s.ins_h = HASH(s, s.ins_h, s.window[s.strstart + MIN_MATCH - 1]);\n hash_head = s.prev[s.strstart & s.w_mask] = s.head[s.ins_h];\n s.head[s.ins_h] = s.strstart;\n /***/\n }\n\n /* Find the longest match, discarding those <= prev_length.\n */\n s.prev_length = s.match_length;\n s.prev_match = s.match_start;\n s.match_length = MIN_MATCH - 1;\n\n if (hash_head !== 0/*NIL*/ && s.prev_length < s.max_lazy_match &&\n s.strstart - hash_head <= (s.w_size - MIN_LOOKAHEAD)/*MAX_DIST(s)*/) {\n /* To simplify the code, we prevent matches with the string\n * of window index 0 (in particular we have to avoid a match\n * of the string with itself at the start of the input file).\n */\n s.match_length = longest_match(s, hash_head);\n /* longest_match() sets match_start */\n\n if (s.match_length <= 5 &&\n (s.strategy === Z_FILTERED || (s.match_length === MIN_MATCH && s.strstart - s.match_start > 4096/*TOO_FAR*/))) {\n\n /* If prev_match is also MIN_MATCH, match_start is garbage\n * but we will ignore the current match anyway.\n */\n s.match_length = MIN_MATCH - 1;\n }\n }\n /* If there was a match at the previous step and the current\n * match is not better, output the previous match:\n */\n if (s.prev_length >= MIN_MATCH && s.match_length <= s.prev_length) {\n max_insert = s.strstart + s.lookahead - MIN_MATCH;\n /* Do not insert strings in hash table beyond this. */\n\n //check_match(s, s.strstart-1, s.prev_match, s.prev_length);\n\n /***_tr_tally_dist(s, s.strstart - 1 - s.prev_match,\n s.prev_length - MIN_MATCH, bflush);***/\n bflush = _tr_tally(s, s.strstart - 1 - s.prev_match, s.prev_length - MIN_MATCH);\n /* Insert in hash table all strings up to the end of the match.\n * strstart-1 and strstart are already inserted. If there is not\n * enough lookahead, the last two strings are not inserted in\n * the hash table.\n */\n s.lookahead -= s.prev_length - 1;\n s.prev_length -= 2;\n do {\n if (++s.strstart <= max_insert) {\n /*** INSERT_STRING(s, s.strstart, hash_head); ***/\n s.ins_h = HASH(s, s.ins_h, s.window[s.strstart + MIN_MATCH - 1]);\n hash_head = s.prev[s.strstart & s.w_mask] = s.head[s.ins_h];\n s.head[s.ins_h] = s.strstart;\n /***/\n }\n } while (--s.prev_length !== 0);\n s.match_available = 0;\n s.match_length = MIN_MATCH - 1;\n s.strstart++;\n\n if (bflush) {\n /*** FLUSH_BLOCK(s, 0); ***/\n flush_block_only(s, false);\n if (s.strm.avail_out === 0) {\n return BS_NEED_MORE;\n }\n /***/\n }\n\n } else if (s.match_available) {\n /* If there was no match at the previous position, output a\n * single literal. If there was a match but the current match\n * is longer, truncate the previous match to a single literal.\n */\n //Tracevv((stderr,\"%c\", s->window[s->strstart-1]));\n /*** _tr_tally_lit(s, s.window[s.strstart-1], bflush); ***/\n bflush = _tr_tally(s, 0, s.window[s.strstart - 1]);\n\n if (bflush) {\n /*** FLUSH_BLOCK_ONLY(s, 0) ***/\n flush_block_only(s, false);\n /***/\n }\n s.strstart++;\n s.lookahead--;\n if (s.strm.avail_out === 0) {\n return BS_NEED_MORE;\n }\n } else {\n /* There is no previous match to compare with, wait for\n * the next step to decide.\n */\n s.match_available = 1;\n s.strstart++;\n s.lookahead--;\n }\n }\n //Assert (flush != Z_NO_FLUSH, \"no flush?\");\n if (s.match_available) {\n //Tracevv((stderr,\"%c\", s->window[s->strstart-1]));\n /*** _tr_tally_lit(s, s.window[s.strstart-1], bflush); ***/\n bflush = _tr_tally(s, 0, s.window[s.strstart - 1]);\n\n s.match_available = 0;\n }\n s.insert = s.strstart < MIN_MATCH - 1 ? s.strstart : MIN_MATCH - 1;\n if (flush === Z_FINISH) {\n /*** FLUSH_BLOCK(s, 1); ***/\n flush_block_only(s, true);\n if (s.strm.avail_out === 0) {\n return BS_FINISH_STARTED;\n }\n /***/\n return BS_FINISH_DONE;\n }\n if (s.last_lit) {\n /*** FLUSH_BLOCK(s, 0); ***/\n flush_block_only(s, false);\n if (s.strm.avail_out === 0) {\n return BS_NEED_MORE;\n }\n /***/\n }\n\n return BS_BLOCK_DONE;\n};\n\n\n/* ===========================================================================\n * For Z_RLE, simply look for runs of bytes, generate matches only of distance\n * one. Do not maintain a hash table. (It will be regenerated if this run of\n * deflate switches away from Z_RLE.)\n */\nconst deflate_rle = (s, flush) => {\n\n let bflush; /* set if current block must be flushed */\n let prev; /* byte at distance one to match */\n let scan, strend; /* scan goes up to strend for length of run */\n\n const _win = s.window;\n\n for (;;) {\n /* Make sure that we always have enough lookahead, except\n * at the end of the input file. We need MAX_MATCH bytes\n * for the longest run, plus one for the unrolled loop.\n */\n if (s.lookahead <= MAX_MATCH) {\n fill_window(s);\n if (s.lookahead <= MAX_MATCH && flush === Z_NO_FLUSH) {\n return BS_NEED_MORE;\n }\n if (s.lookahead === 0) { break; } /* flush the current block */\n }\n\n /* See how many times the previous byte repeats */\n s.match_length = 0;\n if (s.lookahead >= MIN_MATCH && s.strstart > 0) {\n scan = s.strstart - 1;\n prev = _win[scan];\n if (prev === _win[++scan] && prev === _win[++scan] && prev === _win[++scan]) {\n strend = s.strstart + MAX_MATCH;\n do {\n /*jshint noempty:false*/\n } while (prev === _win[++scan] && prev === _win[++scan] &&\n prev === _win[++scan] && prev === _win[++scan] &&\n prev === _win[++scan] && prev === _win[++scan] &&\n prev === _win[++scan] && prev === _win[++scan] &&\n scan < strend);\n s.match_length = MAX_MATCH - (strend - scan);\n if (s.match_length > s.lookahead) {\n s.match_length = s.lookahead;\n }\n }\n //Assert(scan <= s->window+(uInt)(s->window_size-1), \"wild scan\");\n }\n\n /* Emit match if have run of MIN_MATCH or longer, else emit literal */\n if (s.match_length >= MIN_MATCH) {\n //check_match(s, s.strstart, s.strstart - 1, s.match_length);\n\n /*** _tr_tally_dist(s, 1, s.match_length - MIN_MATCH, bflush); ***/\n bflush = _tr_tally(s, 1, s.match_length - MIN_MATCH);\n\n s.lookahead -= s.match_length;\n s.strstart += s.match_length;\n s.match_length = 0;\n } else {\n /* No match, output a literal byte */\n //Tracevv((stderr,\"%c\", s->window[s->strstart]));\n /*** _tr_tally_lit(s, s.window[s.strstart], bflush); ***/\n bflush = _tr_tally(s, 0, s.window[s.strstart]);\n\n s.lookahead--;\n s.strstart++;\n }\n if (bflush) {\n /*** FLUSH_BLOCK(s, 0); ***/\n flush_block_only(s, false);\n if (s.strm.avail_out === 0) {\n return BS_NEED_MORE;\n }\n /***/\n }\n }\n s.insert = 0;\n if (flush === Z_FINISH) {\n /*** FLUSH_BLOCK(s, 1); ***/\n flush_block_only(s, true);\n if (s.strm.avail_out === 0) {\n return BS_FINISH_STARTED;\n }\n /***/\n return BS_FINISH_DONE;\n }\n if (s.last_lit) {\n /*** FLUSH_BLOCK(s, 0); ***/\n flush_block_only(s, false);\n if (s.strm.avail_out === 0) {\n return BS_NEED_MORE;\n }\n /***/\n }\n return BS_BLOCK_DONE;\n};\n\n/* ===========================================================================\n * For Z_HUFFMAN_ONLY, do not look for matches. Do not maintain a hash table.\n * (It will be regenerated if this run of deflate switches away from Huffman.)\n */\nconst deflate_huff = (s, flush) => {\n\n let bflush; /* set if current block must be flushed */\n\n for (;;) {\n /* Make sure that we have a literal to write. */\n if (s.lookahead === 0) {\n fill_window(s);\n if (s.lookahead === 0) {\n if (flush === Z_NO_FLUSH) {\n return BS_NEED_MORE;\n }\n break; /* flush the current block */\n }\n }\n\n /* Output a literal byte */\n s.match_length = 0;\n //Tracevv((stderr,\"%c\", s->window[s->strstart]));\n /*** _tr_tally_lit(s, s.window[s.strstart], bflush); ***/\n bflush = _tr_tally(s, 0, s.window[s.strstart]);\n s.lookahead--;\n s.strstart++;\n if (bflush) {\n /*** FLUSH_BLOCK(s, 0); ***/\n flush_block_only(s, false);\n if (s.strm.avail_out === 0) {\n return BS_NEED_MORE;\n }\n /***/\n }\n }\n s.insert = 0;\n if (flush === Z_FINISH) {\n /*** FLUSH_BLOCK(s, 1); ***/\n flush_block_only(s, true);\n if (s.strm.avail_out === 0) {\n return BS_FINISH_STARTED;\n }\n /***/\n return BS_FINISH_DONE;\n }\n if (s.last_lit) {\n /*** FLUSH_BLOCK(s, 0); ***/\n flush_block_only(s, false);\n if (s.strm.avail_out === 0) {\n return BS_NEED_MORE;\n }\n /***/\n }\n return BS_BLOCK_DONE;\n};\n\n/* Values for max_lazy_match, good_match and max_chain_length, depending on\n * the desired pack level (0..9). The values given below have been tuned to\n * exclude worst case performance for pathological files. Better values may be\n * found for specific files.\n */\nfunction Config(good_length, max_lazy, nice_length, max_chain, func) {\n\n this.good_length = good_length;\n this.max_lazy = max_lazy;\n this.nice_length = nice_length;\n this.max_chain = max_chain;\n this.func = func;\n}\n\nconst configuration_table = [\n /* good lazy nice chain */\n new Config(0, 0, 0, 0, deflate_stored), /* 0 store only */\n new Config(4, 4, 8, 4, deflate_fast), /* 1 max speed, no lazy matches */\n new Config(4, 5, 16, 8, deflate_fast), /* 2 */\n new Config(4, 6, 32, 32, deflate_fast), /* 3 */\n\n new Config(4, 4, 16, 16, deflate_slow), /* 4 lazy matches */\n new Config(8, 16, 32, 32, deflate_slow), /* 5 */\n new Config(8, 16, 128, 128, deflate_slow), /* 6 */\n new Config(8, 32, 128, 256, deflate_slow), /* 7 */\n new Config(32, 128, 258, 1024, deflate_slow), /* 8 */\n new Config(32, 258, 258, 4096, deflate_slow) /* 9 max compression */\n];\n\n\n/* ===========================================================================\n * Initialize the \"longest match\" routines for a new zlib stream\n */\nconst lm_init = (s) => {\n\n s.window_size = 2 * s.w_size;\n\n /*** CLEAR_HASH(s); ***/\n zero(s.head); // Fill with NIL (= 0);\n\n /* Set the default configuration parameters:\n */\n s.max_lazy_match = configuration_table[s.level].max_lazy;\n s.good_match = configuration_table[s.level].good_length;\n s.nice_match = configuration_table[s.level].nice_length;\n s.max_chain_length = configuration_table[s.level].max_chain;\n\n s.strstart = 0;\n s.block_start = 0;\n s.lookahead = 0;\n s.insert = 0;\n s.match_length = s.prev_length = MIN_MATCH - 1;\n s.match_available = 0;\n s.ins_h = 0;\n};\n\n\nfunction DeflateState() {\n this.strm = null; /* pointer back to this zlib stream */\n this.status = 0; /* as the name implies */\n this.pending_buf = null; /* output still pending */\n this.pending_buf_size = 0; /* size of pending_buf */\n this.pending_out = 0; /* next pending byte to output to the stream */\n this.pending = 0; /* nb of bytes in the pending buffer */\n this.wrap = 0; /* bit 0 true for zlib, bit 1 true for gzip */\n this.gzhead = null; /* gzip header information to write */\n this.gzindex = 0; /* where in extra, name, or comment */\n this.method = Z_DEFLATED; /* can only be DEFLATED */\n this.last_flush = -1; /* value of flush param for previous deflate call */\n\n this.w_size = 0; /* LZ77 window size (32K by default) */\n this.w_bits = 0; /* log2(w_size) (8..16) */\n this.w_mask = 0; /* w_size - 1 */\n\n this.window = null;\n /* Sliding window. Input bytes are read into the second half of the window,\n * and move to the first half later to keep a dictionary of at least wSize\n * bytes. With this organization, matches are limited to a distance of\n * wSize-MAX_MATCH bytes, but this ensures that IO is always\n * performed with a length multiple of the block size.\n */\n\n this.window_size = 0;\n /* Actual size of window: 2*wSize, except when the user input buffer\n * is directly used as sliding window.\n */\n\n this.prev = null;\n /* Link to older string with same hash index. To limit the size of this\n * array to 64K, this link is maintained only for the last 32K strings.\n * An index in this array is thus a window index modulo 32K.\n */\n\n this.head = null; /* Heads of the hash chains or NIL. */\n\n this.ins_h = 0; /* hash index of string to be inserted */\n this.hash_size = 0; /* number of elements in hash table */\n this.hash_bits = 0; /* log2(hash_size) */\n this.hash_mask = 0; /* hash_size-1 */\n\n this.hash_shift = 0;\n /* Number of bits by which ins_h must be shifted at each input\n * step. It must be such that after MIN_MATCH steps, the oldest\n * byte no longer takes part in the hash key, that is:\n * hash_shift * MIN_MATCH >= hash_bits\n */\n\n this.block_start = 0;\n /* Window position at the beginning of the current output block. Gets\n * negative when the window is moved backwards.\n */\n\n this.match_length = 0; /* length of best match */\n this.prev_match = 0; /* previous match */\n this.match_available = 0; /* set if previous match exists */\n this.strstart = 0; /* start of string to insert */\n this.match_start = 0; /* start of matching string */\n this.lookahead = 0; /* number of valid bytes ahead in window */\n\n this.prev_length = 0;\n /* Length of the best match at previous step. Matches not greater than this\n * are discarded. This is used in the lazy match evaluation.\n */\n\n this.max_chain_length = 0;\n /* To speed up deflation, hash chains are never searched beyond this\n * length. A higher limit improves compression ratio but degrades the\n * speed.\n */\n\n this.max_lazy_match = 0;\n /* Attempt to find a better match only when the current match is strictly\n * smaller than this value. This mechanism is used only for compression\n * levels >= 4.\n */\n // That's alias to max_lazy_match, don't use directly\n //this.max_insert_length = 0;\n /* Insert new strings in the hash table only if the match length is not\n * greater than this length. This saves time but degrades compression.\n * max_insert_length is used only for compression levels <= 3.\n */\n\n this.level = 0; /* compression level (1..9) */\n this.strategy = 0; /* favor or force Huffman coding*/\n\n this.good_match = 0;\n /* Use a faster search when the previous match is longer than this */\n\n this.nice_match = 0; /* Stop searching when current match exceeds this */\n\n /* used by trees.c: */\n\n /* Didn't use ct_data typedef below to suppress compiler warning */\n\n // struct ct_data_s dyn_ltree[HEAP_SIZE]; /* literal and length tree */\n // struct ct_data_s dyn_dtree[2*D_CODES+1]; /* distance tree */\n // struct ct_data_s bl_tree[2*BL_CODES+1]; /* Huffman tree for bit lengths */\n\n // Use flat array of DOUBLE size, with interleaved fata,\n // because JS does not support effective\n this.dyn_ltree = new Uint16Array(HEAP_SIZE * 2);\n this.dyn_dtree = new Uint16Array((2 * D_CODES + 1) * 2);\n this.bl_tree = new Uint16Array((2 * BL_CODES + 1) * 2);\n zero(this.dyn_ltree);\n zero(this.dyn_dtree);\n zero(this.bl_tree);\n\n this.l_desc = null; /* desc. for literal tree */\n this.d_desc = null; /* desc. for distance tree */\n this.bl_desc = null; /* desc. for bit length tree */\n\n //ush bl_count[MAX_BITS+1];\n this.bl_count = new Uint16Array(MAX_BITS + 1);\n /* number of codes at each bit length for an optimal tree */\n\n //int heap[2*L_CODES+1]; /* heap used to build the Huffman trees */\n this.heap = new Uint16Array(2 * L_CODES + 1); /* heap used to build the Huffman trees */\n zero(this.heap);\n\n this.heap_len = 0; /* number of elements in the heap */\n this.heap_max = 0; /* element of largest frequency */\n /* The sons of heap[n] are heap[2*n] and heap[2*n+1]. heap[0] is not used.\n * The same heap array is used to build all trees.\n */\n\n this.depth = new Uint16Array(2 * L_CODES + 1); //uch depth[2*L_CODES+1];\n zero(this.depth);\n /* Depth of each subtree used as tie breaker for trees of equal frequency\n */\n\n this.l_buf = 0; /* buffer index for literals or lengths */\n\n this.lit_bufsize = 0;\n /* Size of match buffer for literals/lengths. There are 4 reasons for\n * limiting lit_bufsize to 64K:\n * - frequencies can be kept in 16 bit counters\n * - if compression is not successful for the first block, all input\n * data is still in the window so we can still emit a stored block even\n * when input comes from standard input. (This can also be done for\n * all blocks if lit_bufsize is not greater than 32K.)\n * - if compression is not successful for a file smaller than 64K, we can\n * even emit a stored file instead of a stored block (saving 5 bytes).\n * This is applicable only for zip (not gzip or zlib).\n * - creating new Huffman trees less frequently may not provide fast\n * adaptation to changes in the input data statistics. (Take for\n * example a binary file with poorly compressible code followed by\n * a highly compressible string table.) Smaller buffer sizes give\n * fast adaptation but have of course the overhead of transmitting\n * trees more frequently.\n * - I can't count above 4\n */\n\n this.last_lit = 0; /* running index in l_buf */\n\n this.d_buf = 0;\n /* Buffer index for distances. To simplify the code, d_buf and l_buf have\n * the same number of elements. To use different lengths, an extra flag\n * array would be necessary.\n */\n\n this.opt_len = 0; /* bit length of current block with optimal trees */\n this.static_len = 0; /* bit length of current block with static trees */\n this.matches = 0; /* number of string matches in current block */\n this.insert = 0; /* bytes at end of window left to insert */\n\n\n this.bi_buf = 0;\n /* Output buffer. bits are inserted starting at the bottom (least\n * significant bits).\n */\n this.bi_valid = 0;\n /* Number of valid bits in bi_buf. All bits above the last valid bit\n * are always zero.\n */\n\n // Used for window memory init. We safely ignore it for JS. That makes\n // sense only for pointers and memory check tools.\n //this.high_water = 0;\n /* High water mark offset in window for initialized bytes -- bytes above\n * this are set to zero in order to avoid memory check warnings when\n * longest match routines access bytes past the input. This is then\n * updated to the new high water mark.\n */\n}\n\n\nconst deflateResetKeep = (strm) => {\n\n if (!strm || !strm.state) {\n return err(strm, Z_STREAM_ERROR);\n }\n\n strm.total_in = strm.total_out = 0;\n strm.data_type = Z_UNKNOWN;\n\n const s = strm.state;\n s.pending = 0;\n s.pending_out = 0;\n\n if (s.wrap < 0) {\n s.wrap = -s.wrap;\n /* was made negative by deflate(..., Z_FINISH); */\n }\n s.status = (s.wrap ? INIT_STATE : BUSY_STATE);\n strm.adler = (s.wrap === 2) ?\n 0 // crc32(0, Z_NULL, 0)\n :\n 1; // adler32(0, Z_NULL, 0)\n s.last_flush = Z_NO_FLUSH;\n _tr_init(s);\n return Z_OK;\n};\n\n\nconst deflateReset = (strm) => {\n\n const ret = deflateResetKeep(strm);\n if (ret === Z_OK) {\n lm_init(strm.state);\n }\n return ret;\n};\n\n\nconst deflateSetHeader = (strm, head) => {\n\n if (!strm || !strm.state) { return Z_STREAM_ERROR; }\n if (strm.state.wrap !== 2) { return Z_STREAM_ERROR; }\n strm.state.gzhead = head;\n return Z_OK;\n};\n\n\nconst deflateInit2 = (strm, level, method, windowBits, memLevel, strategy) => {\n\n if (!strm) { // === Z_NULL\n return Z_STREAM_ERROR;\n }\n let wrap = 1;\n\n if (level === Z_DEFAULT_COMPRESSION) {\n level = 6;\n }\n\n if (windowBits < 0) { /* suppress zlib wrapper */\n wrap = 0;\n windowBits = -windowBits;\n }\n\n else if (windowBits > 15) {\n wrap = 2; /* write gzip wrapper instead */\n windowBits -= 16;\n }\n\n\n if (memLevel < 1 || memLevel > MAX_MEM_LEVEL || method !== Z_DEFLATED ||\n windowBits < 8 || windowBits > 15 || level < 0 || level > 9 ||\n strategy < 0 || strategy > Z_FIXED) {\n return err(strm, Z_STREAM_ERROR);\n }\n\n\n if (windowBits === 8) {\n windowBits = 9;\n }\n /* until 256-byte window bug fixed */\n\n const s = new DeflateState();\n\n strm.state = s;\n s.strm = strm;\n\n s.wrap = wrap;\n s.gzhead = null;\n s.w_bits = windowBits;\n s.w_size = 1 << s.w_bits;\n s.w_mask = s.w_size - 1;\n\n s.hash_bits = memLevel + 7;\n s.hash_size = 1 << s.hash_bits;\n s.hash_mask = s.hash_size - 1;\n s.hash_shift = ~~((s.hash_bits + MIN_MATCH - 1) / MIN_MATCH);\n\n s.window = new Uint8Array(s.w_size * 2);\n s.head = new Uint16Array(s.hash_size);\n s.prev = new Uint16Array(s.w_size);\n\n // Don't need mem init magic for JS.\n //s.high_water = 0; /* nothing written to s->window yet */\n\n s.lit_bufsize = 1 << (memLevel + 6); /* 16K elements by default */\n\n s.pending_buf_size = s.lit_bufsize * 4;\n\n //overlay = (ushf *) ZALLOC(strm, s->lit_bufsize, sizeof(ush)+2);\n //s->pending_buf = (uchf *) overlay;\n s.pending_buf = new Uint8Array(s.pending_buf_size);\n\n // It is offset from `s.pending_buf` (size is `s.lit_bufsize * 2`)\n //s->d_buf = overlay + s->lit_bufsize/sizeof(ush);\n s.d_buf = 1 * s.lit_bufsize;\n\n //s->l_buf = s->pending_buf + (1+sizeof(ush))*s->lit_bufsize;\n s.l_buf = (1 + 2) * s.lit_bufsize;\n\n s.level = level;\n s.strategy = strategy;\n s.method = method;\n\n return deflateReset(strm);\n};\n\nconst deflateInit = (strm, level) => {\n\n return deflateInit2(strm, level, Z_DEFLATED, MAX_WBITS, DEF_MEM_LEVEL, Z_DEFAULT_STRATEGY);\n};\n\n\nconst deflate = (strm, flush) => {\n\n let beg, val; // for gzip header write only\n\n if (!strm || !strm.state ||\n flush > Z_BLOCK || flush < 0) {\n return strm ? err(strm, Z_STREAM_ERROR) : Z_STREAM_ERROR;\n }\n\n const s = strm.state;\n\n if (!strm.output ||\n (!strm.input && strm.avail_in !== 0) ||\n (s.status === FINISH_STATE && flush !== Z_FINISH)) {\n return err(strm, (strm.avail_out === 0) ? Z_BUF_ERROR : Z_STREAM_ERROR);\n }\n\n s.strm = strm; /* just in case */\n const old_flush = s.last_flush;\n s.last_flush = flush;\n\n /* Write the header */\n if (s.status === INIT_STATE) {\n\n if (s.wrap === 2) { // GZIP header\n strm.adler = 0; //crc32(0L, Z_NULL, 0);\n put_byte(s, 31);\n put_byte(s, 139);\n put_byte(s, 8);\n if (!s.gzhead) { // s->gzhead == Z_NULL\n put_byte(s, 0);\n put_byte(s, 0);\n put_byte(s, 0);\n put_byte(s, 0);\n put_byte(s, 0);\n put_byte(s, s.level === 9 ? 2 :\n (s.strategy >= Z_HUFFMAN_ONLY || s.level < 2 ?\n 4 : 0));\n put_byte(s, OS_CODE);\n s.status = BUSY_STATE;\n }\n else {\n put_byte(s, (s.gzhead.text ? 1 : 0) +\n (s.gzhead.hcrc ? 2 : 0) +\n (!s.gzhead.extra ? 0 : 4) +\n (!s.gzhead.name ? 0 : 8) +\n (!s.gzhead.comment ? 0 : 16)\n );\n put_byte(s, s.gzhead.time & 0xff);\n put_byte(s, (s.gzhead.time >> 8) & 0xff);\n put_byte(s, (s.gzhead.time >> 16) & 0xff);\n put_byte(s, (s.gzhead.time >> 24) & 0xff);\n put_byte(s, s.level === 9 ? 2 :\n (s.strategy >= Z_HUFFMAN_ONLY || s.level < 2 ?\n 4 : 0));\n put_byte(s, s.gzhead.os & 0xff);\n if (s.gzhead.extra && s.gzhead.extra.length) {\n put_byte(s, s.gzhead.extra.length & 0xff);\n put_byte(s, (s.gzhead.extra.length >> 8) & 0xff);\n }\n if (s.gzhead.hcrc) {\n strm.adler = crc32(strm.adler, s.pending_buf, s.pending, 0);\n }\n s.gzindex = 0;\n s.status = EXTRA_STATE;\n }\n }\n else // DEFLATE header\n {\n let header = (Z_DEFLATED + ((s.w_bits - 8) << 4)) << 8;\n let level_flags = -1;\n\n if (s.strategy >= Z_HUFFMAN_ONLY || s.level < 2) {\n level_flags = 0;\n } else if (s.level < 6) {\n level_flags = 1;\n } else if (s.level === 6) {\n level_flags = 2;\n } else {\n level_flags = 3;\n }\n header |= (level_flags << 6);\n if (s.strstart !== 0) { header |= PRESET_DICT; }\n header += 31 - (header % 31);\n\n s.status = BUSY_STATE;\n putShortMSB(s, header);\n\n /* Save the adler32 of the preset dictionary: */\n if (s.strstart !== 0) {\n putShortMSB(s, strm.adler >>> 16);\n putShortMSB(s, strm.adler & 0xffff);\n }\n strm.adler = 1; // adler32(0L, Z_NULL, 0);\n }\n }\n\n//#ifdef GZIP\n if (s.status === EXTRA_STATE) {\n if (s.gzhead.extra/* != Z_NULL*/) {\n beg = s.pending; /* start of bytes to update crc */\n\n while (s.gzindex < (s.gzhead.extra.length & 0xffff)) {\n if (s.pending === s.pending_buf_size) {\n if (s.gzhead.hcrc && s.pending > beg) {\n strm.adler = crc32(strm.adler, s.pending_buf, s.pending - beg, beg);\n }\n flush_pending(strm);\n beg = s.pending;\n if (s.pending === s.pending_buf_size) {\n break;\n }\n }\n put_byte(s, s.gzhead.extra[s.gzindex] & 0xff);\n s.gzindex++;\n }\n if (s.gzhead.hcrc && s.pending > beg) {\n strm.adler = crc32(strm.adler, s.pending_buf, s.pending - beg, beg);\n }\n if (s.gzindex === s.gzhead.extra.length) {\n s.gzindex = 0;\n s.status = NAME_STATE;\n }\n }\n else {\n s.status = NAME_STATE;\n }\n }\n if (s.status === NAME_STATE) {\n if (s.gzhead.name/* != Z_NULL*/) {\n beg = s.pending; /* start of bytes to update crc */\n //int val;\n\n do {\n if (s.pending === s.pending_buf_size) {\n if (s.gzhead.hcrc && s.pending > beg) {\n strm.adler = crc32(strm.adler, s.pending_buf, s.pending - beg, beg);\n }\n flush_pending(strm);\n beg = s.pending;\n if (s.pending === s.pending_buf_size) {\n val = 1;\n break;\n }\n }\n // JS specific: little magic to add zero terminator to end of string\n if (s.gzindex < s.gzhead.name.length) {\n val = s.gzhead.name.charCodeAt(s.gzindex++) & 0xff;\n } else {\n val = 0;\n }\n put_byte(s, val);\n } while (val !== 0);\n\n if (s.gzhead.hcrc && s.pending > beg) {\n strm.adler = crc32(strm.adler, s.pending_buf, s.pending - beg, beg);\n }\n if (val === 0) {\n s.gzindex = 0;\n s.status = COMMENT_STATE;\n }\n }\n else {\n s.status = COMMENT_STATE;\n }\n }\n if (s.status === COMMENT_STATE) {\n if (s.gzhead.comment/* != Z_NULL*/) {\n beg = s.pending; /* start of bytes to update crc */\n //int val;\n\n do {\n if (s.pending === s.pending_buf_size) {\n if (s.gzhead.hcrc && s.pending > beg) {\n strm.adler = crc32(strm.adler, s.pending_buf, s.pending - beg, beg);\n }\n flush_pending(strm);\n beg = s.pending;\n if (s.pending === s.pending_buf_size) {\n val = 1;\n break;\n }\n }\n // JS specific: little magic to add zero terminator to end of string\n if (s.gzindex < s.gzhead.comment.length) {\n val = s.gzhead.comment.charCodeAt(s.gzindex++) & 0xff;\n } else {\n val = 0;\n }\n put_byte(s, val);\n } while (val !== 0);\n\n if (s.gzhead.hcrc && s.pending > beg) {\n strm.adler = crc32(strm.adler, s.pending_buf, s.pending - beg, beg);\n }\n if (val === 0) {\n s.status = HCRC_STATE;\n }\n }\n else {\n s.status = HCRC_STATE;\n }\n }\n if (s.status === HCRC_STATE) {\n if (s.gzhead.hcrc) {\n if (s.pending + 2 > s.pending_buf_size) {\n flush_pending(strm);\n }\n if (s.pending + 2 <= s.pending_buf_size) {\n put_byte(s, strm.adler & 0xff);\n put_byte(s, (strm.adler >> 8) & 0xff);\n strm.adler = 0; //crc32(0L, Z_NULL, 0);\n s.status = BUSY_STATE;\n }\n }\n else {\n s.status = BUSY_STATE;\n }\n }\n//#endif\n\n /* Flush as much pending output as possible */\n if (s.pending !== 0) {\n flush_pending(strm);\n if (strm.avail_out === 0) {\n /* Since avail_out is 0, deflate will be called again with\n * more output space, but possibly with both pending and\n * avail_in equal to zero. There won't be anything to do,\n * but this is not an error situation so make sure we\n * return OK instead of BUF_ERROR at next call of deflate:\n */\n s.last_flush = -1;\n return Z_OK;\n }\n\n /* Make sure there is something to do and avoid duplicate consecutive\n * flushes. For repeated and useless calls with Z_FINISH, we keep\n * returning Z_STREAM_END instead of Z_BUF_ERROR.\n */\n } else if (strm.avail_in === 0 && rank(flush) <= rank(old_flush) &&\n flush !== Z_FINISH) {\n return err(strm, Z_BUF_ERROR);\n }\n\n /* User must not provide more input after the first FINISH: */\n if (s.status === FINISH_STATE && strm.avail_in !== 0) {\n return err(strm, Z_BUF_ERROR);\n }\n\n /* Start a new block or continue the current one.\n */\n if (strm.avail_in !== 0 || s.lookahead !== 0 ||\n (flush !== Z_NO_FLUSH && s.status !== FINISH_STATE)) {\n let bstate = (s.strategy === Z_HUFFMAN_ONLY) ? deflate_huff(s, flush) :\n (s.strategy === Z_RLE ? deflate_rle(s, flush) :\n configuration_table[s.level].func(s, flush));\n\n if (bstate === BS_FINISH_STARTED || bstate === BS_FINISH_DONE) {\n s.status = FINISH_STATE;\n }\n if (bstate === BS_NEED_MORE || bstate === BS_FINISH_STARTED) {\n if (strm.avail_out === 0) {\n s.last_flush = -1;\n /* avoid BUF_ERROR next call, see above */\n }\n return Z_OK;\n /* If flush != Z_NO_FLUSH && avail_out == 0, the next call\n * of deflate should use the same flush parameter to make sure\n * that the flush is complete. So we don't have to output an\n * empty block here, this will be done at next call. This also\n * ensures that for a very small output buffer, we emit at most\n * one empty block.\n */\n }\n if (bstate === BS_BLOCK_DONE) {\n if (flush === Z_PARTIAL_FLUSH) {\n _tr_align(s);\n }\n else if (flush !== Z_BLOCK) { /* FULL_FLUSH or SYNC_FLUSH */\n\n _tr_stored_block(s, 0, 0, false);\n /* For a full flush, this empty block will be recognized\n * as a special marker by inflate_sync().\n */\n if (flush === Z_FULL_FLUSH) {\n /*** CLEAR_HASH(s); ***/ /* forget history */\n zero(s.head); // Fill with NIL (= 0);\n\n if (s.lookahead === 0) {\n s.strstart = 0;\n s.block_start = 0;\n s.insert = 0;\n }\n }\n }\n flush_pending(strm);\n if (strm.avail_out === 0) {\n s.last_flush = -1; /* avoid BUF_ERROR at next call, see above */\n return Z_OK;\n }\n }\n }\n //Assert(strm->avail_out > 0, \"bug2\");\n //if (strm.avail_out <= 0) { throw new Error(\"bug2\");}\n\n if (flush !== Z_FINISH) { return Z_OK; }\n if (s.wrap <= 0) { return Z_STREAM_END; }\n\n /* Write the trailer */\n if (s.wrap === 2) {\n put_byte(s, strm.adler & 0xff);\n put_byte(s, (strm.adler >> 8) & 0xff);\n put_byte(s, (strm.adler >> 16) & 0xff);\n put_byte(s, (strm.adler >> 24) & 0xff);\n put_byte(s, strm.total_in & 0xff);\n put_byte(s, (strm.total_in >> 8) & 0xff);\n put_byte(s, (strm.total_in >> 16) & 0xff);\n put_byte(s, (strm.total_in >> 24) & 0xff);\n }\n else\n {\n putShortMSB(s, strm.adler >>> 16);\n putShortMSB(s, strm.adler & 0xffff);\n }\n\n flush_pending(strm);\n /* If avail_out is zero, the application will call deflate again\n * to flush the rest.\n */\n if (s.wrap > 0) { s.wrap = -s.wrap; }\n /* write the trailer only once! */\n return s.pending !== 0 ? Z_OK : Z_STREAM_END;\n};\n\n\nconst deflateEnd = (strm) => {\n\n if (!strm/*== Z_NULL*/ || !strm.state/*== Z_NULL*/) {\n return Z_STREAM_ERROR;\n }\n\n const status = strm.state.status;\n if (status !== INIT_STATE &&\n status !== EXTRA_STATE &&\n status !== NAME_STATE &&\n status !== COMMENT_STATE &&\n status !== HCRC_STATE &&\n status !== BUSY_STATE &&\n status !== FINISH_STATE\n ) {\n return err(strm, Z_STREAM_ERROR);\n }\n\n strm.state = null;\n\n return status === BUSY_STATE ? err(strm, Z_DATA_ERROR) : Z_OK;\n};\n\n\n/* =========================================================================\n * Initializes the compression dictionary from the given byte\n * sequence without producing any compressed output.\n */\nconst deflateSetDictionary = (strm, dictionary) => {\n\n let dictLength = dictionary.length;\n\n if (!strm/*== Z_NULL*/ || !strm.state/*== Z_NULL*/) {\n return Z_STREAM_ERROR;\n }\n\n const s = strm.state;\n const wrap = s.wrap;\n\n if (wrap === 2 || (wrap === 1 && s.status !== INIT_STATE) || s.lookahead) {\n return Z_STREAM_ERROR;\n }\n\n /* when using zlib wrappers, compute Adler-32 for provided dictionary */\n if (wrap === 1) {\n /* adler32(strm->adler, dictionary, dictLength); */\n strm.adler = adler32(strm.adler, dictionary, dictLength, 0);\n }\n\n s.wrap = 0; /* avoid computing Adler-32 in read_buf */\n\n /* if dictionary would fill window, just replace the history */\n if (dictLength >= s.w_size) {\n if (wrap === 0) { /* already empty otherwise */\n /*** CLEAR_HASH(s); ***/\n zero(s.head); // Fill with NIL (= 0);\n s.strstart = 0;\n s.block_start = 0;\n s.insert = 0;\n }\n /* use the tail */\n // dictionary = dictionary.slice(dictLength - s.w_size);\n let tmpDict = new Uint8Array(s.w_size);\n tmpDict.set(dictionary.subarray(dictLength - s.w_size, dictLength), 0);\n dictionary = tmpDict;\n dictLength = s.w_size;\n }\n /* insert dictionary into window and hash */\n const avail = strm.avail_in;\n const next = strm.next_in;\n const input = strm.input;\n strm.avail_in = dictLength;\n strm.next_in = 0;\n strm.input = dictionary;\n fill_window(s);\n while (s.lookahead >= MIN_MATCH) {\n let str = s.strstart;\n let n = s.lookahead - (MIN_MATCH - 1);\n do {\n /* UPDATE_HASH(s, s->ins_h, s->window[str + MIN_MATCH-1]); */\n s.ins_h = HASH(s, s.ins_h, s.window[str + MIN_MATCH - 1]);\n\n s.prev[str & s.w_mask] = s.head[s.ins_h];\n\n s.head[s.ins_h] = str;\n str++;\n } while (--n);\n s.strstart = str;\n s.lookahead = MIN_MATCH - 1;\n fill_window(s);\n }\n s.strstart += s.lookahead;\n s.block_start = s.strstart;\n s.insert = s.lookahead;\n s.lookahead = 0;\n s.match_length = s.prev_length = MIN_MATCH - 1;\n s.match_available = 0;\n strm.next_in = next;\n strm.input = input;\n strm.avail_in = avail;\n s.wrap = wrap;\n return Z_OK;\n};\n\n\nmodule.exports.deflateInit = deflateInit;\nmodule.exports.deflateInit2 = deflateInit2;\nmodule.exports.deflateReset = deflateReset;\nmodule.exports.deflateResetKeep = deflateResetKeep;\nmodule.exports.deflateSetHeader = deflateSetHeader;\nmodule.exports.deflate = deflate;\nmodule.exports.deflateEnd = deflateEnd;\nmodule.exports.deflateSetDictionary = deflateSetDictionary;\nmodule.exports.deflateInfo = 'pako deflate (from Nodeca project)';\n\n/* Not implemented\nmodule.exports.deflateBound = deflateBound;\nmodule.exports.deflateCopy = deflateCopy;\nmodule.exports.deflateParams = deflateParams;\nmodule.exports.deflatePending = deflatePending;\nmodule.exports.deflatePrime = deflatePrime;\nmodule.exports.deflateTune = deflateTune;\n*/\n"],
5
- "mappings": "aAqBA,KAAM,CAAE,SAAU,iBAAkB,gBAAiB,UAAW,WAAc,QAAQ,WAChF,QAAU,QAAQ,aAClB,MAAU,QAAQ,WAClB,IAAU,QAAQ,cAKlB,CACJ,WAAY,gBAAiB,aAAc,SAAU,QACrD,KAAM,aAAc,eAAgB,aAAc,YAClD,sBACA,WAAY,eAAgB,MAAO,QAAS,mBAC5C,UACA,YACE,QAAQ,eAKN,cAAgB,EAEhB,UAAY,GAEZ,cAAgB,EAGhB,aAAgB,GAEhB,SAAgB,IAEhB,QAAgB,SAAW,EAAI,aAE/B,QAAgB,GAEhB,SAAgB,GAEhB,UAAgB,EAAI,QAAU,EAE9B,SAAY,GAGZ,UAAY,EACZ,UAAY,IACZ,cAAi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AElC,EAAE,KAAK,EAAE,OAAS,EAClB,UACO,EAAE,GACX,EAAE,SAAW,EACb,EAAE,UAAY,UAAY,EAC1B,YAAY,GAEd,SAAE,UAAY,EAAE,UAChB,EAAE,YAAc,EAAE,SAClB,EAAE,OAAS,EAAE,UACb,EAAE,UAAY,EACd,EAAE,aAAe,EAAE,YAAc,UAAY,EAC7C,EAAE,gBAAkB,EACpB,EAAK,QAAU,EACf,EAAK,MAAQ,EACb,EAAK,SAAW,EAChB,EAAE,KAAO,EACF,MAIT,OAAO,QAAQ,YAAc,YAC7B,OAAO,QAAQ,aAAe,aAC9B,OAAO,QAAQ,aAAe,aAC9B,OAAO,QAAQ,iBAAmB,iBAClC,OAAO,QAAQ,iBAAmB,iBAClC,OAAO,QAAQ,QAAU,QACzB,OAAO,QAAQ,WAAa,WAC5B,OAAO,QAAQ,qBAAuB,qBACtC,OAAO,QAAQ,YAAc",
6
- "names": []
7
- }
@@ -1,2 +0,0 @@
1
- "use strict";function GZheader(){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}module.exports=GZheader;
2
- //# sourceMappingURL=gzheader.js.map
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../../../../../../../../GDevelop/Extensions/TileMap/helper/node_modules/pako/lib/zlib/gzheader.js"],
4
- "sourcesContent": ["'use strict';\n\n// (C) 1995-2013 Jean-loup Gailly and Mark Adler\n// (C) 2014-2017 Vitaly Puzrin and Andrey Tupitsin\n//\n// This software is provided 'as-is', without any express or implied\n// warranty. In no event will the authors be held liable for any damages\n// arising from the use of this software.\n//\n// Permission is granted to anyone to use this software for any purpose,\n// including commercial applications, and to alter it and redistribute it\n// freely, subject to the following restrictions:\n//\n// 1. The origin of this software must not be misrepresented; you must not\n// claim that you wrote the original software. If you use this software\n// in a product, an acknowledgment in the product documentation would be\n// appreciated but is not required.\n// 2. Altered source versions must be plainly marked as such, and must not be\n// misrepresented as being the original software.\n// 3. This notice may not be removed or altered from any source distribution.\n\nfunction GZheader() {\n /* true if compressed data believed to be text */\n this.text = 0;\n /* modification time */\n this.time = 0;\n /* extra flags (not used when writing a gzip file) */\n this.xflags = 0;\n /* operating system */\n this.os = 0;\n /* pointer to extra field or Z_NULL if none */\n this.extra = null;\n /* extra field length (valid if extra != Z_NULL) */\n this.extra_len = 0; // Actually, we don't need it in JS,\n // but leave for few code modifications\n\n //\n // Setup limits is not necessary because in js we should not preallocate memory\n // for inflate use constant limit in 65536 bytes\n //\n\n /* space at extra (only when reading header) */\n // this.extra_max = 0;\n /* pointer to zero-terminated file name or Z_NULL */\n this.name = '';\n /* space at name (only when reading header) */\n // this.name_max = 0;\n /* pointer to zero-terminated comment or Z_NULL */\n this.comment = '';\n /* space at comment (only when reading header) */\n // this.comm_max = 0;\n /* true if there was or will be a header crc */\n this.hcrc = 0;\n /* true when done reading gzip header (not used when writing a gzip file) */\n this.done = false;\n}\n\nmodule.exports = GZheader;\n"],
5
- "mappings": "aAqBA,mBAAoB,CAElB,KAAK,KAAa,EAElB,KAAK,KAAa,EAElB,KAAK,OAAa,EAElB,KAAK,GAAa,EAElB,KAAK,MAAa,KAElB,KAAK,UAAa,EAWlB,KAAK,KAAa,GAIlB,KAAK,QAAa,GAIlB,KAAK,KAAa,EAElB,KAAK,KAAa,GAGpB,OAAO,QAAU",
6
- "names": []
7
- }
@@ -1,2 +0,0 @@
1
- "use strict";const BAD=30,TYPE=12;module.exports=function(d,D){let s,_,i,r,k,z,v,m,x,h,a,l,g,p,A,B,c,e,o,u,t,w,b,f;const n=d.state;s=d.next_in,b=d.input,_=s+(d.avail_in-5),i=d.next_out,f=d.output,r=i-(D-d.avail_out),k=i+(d.avail_out-257),z=n.dmax,v=n.wsize,m=n.whave,x=n.wnext,h=n.window,a=n.hold,l=n.bits,g=n.lencode,p=n.distcode,A=(1<<n.lenbits)-1,B=(1<<n.distbits)-1;e:do{l<15&&(a+=b[s++]<<l,l+=8,a+=b[s++]<<l,l+=8),c=g[a&A];i:for(;;){if(e=c>>>24,a>>>=e,l-=e,e=c>>>16&255,e===0)f[i++]=c&65535;else if(e&16){o=c&65535,e&=15,e&&(l<e&&(a+=b[s++]<<l,l+=8),o+=a&(1<<e)-1,a>>>=e,l-=e),l<15&&(a+=b[s++]<<l,l+=8,a+=b[s++]<<l,l+=8),c=p[a&B];l:for(;;){if(e=c>>>24,a>>>=e,l-=e,e=c>>>16&255,e&16){if(u=c&65535,e&=15,l<e&&(a+=b[s++]<<l,l+=8,l<e&&(a+=b[s++]<<l,l+=8)),u+=a&(1<<e)-1,u>z){d.msg="invalid distance too far back",n.mode=BAD;break e}if(a>>>=e,l-=e,e=i-r,u>e){if(e=u-e,e>m&&n.sane){d.msg="invalid distance too far back",n.mode=BAD;break e}if(t=0,w=h,x===0){if(t+=v-e,e<o){o-=e;do f[i++]=h[t++];while(--e);t=i-u,w=f}}else if(x<e){if(t+=v+x-e,e-=x,e<o){o-=e;do f[i++]=h[t++];while(--e);if(t=0,x<o){e=x,o-=e;do f[i++]=h[t++];while(--e);t=i-u,w=f}}}else if(t+=x-e,e<o){o-=e;do f[i++]=h[t++];while(--e);t=i-u,w=f}for(;o>2;)f[i++]=w[t++],f[i++]=w[t++],f[i++]=w[t++],o-=3;o&&(f[i++]=w[t++],o>1&&(f[i++]=w[t++]))}else{t=i-u;do f[i++]=f[t++],f[i++]=f[t++],f[i++]=f[t++],o-=3;while(o>2);o&&(f[i++]=f[t++],o>1&&(f[i++]=f[t++]))}}else if((e&64)==0){c=p[(c&65535)+(a&(1<<e)-1)];continue l}else{d.msg="invalid distance code",n.mode=BAD;break e}break}}else if((e&64)==0){c=g[(c&65535)+(a&(1<<e)-1)];continue i}else if(e&32){n.mode=TYPE;break e}else{d.msg="invalid literal/length code",n.mode=BAD;break e}break}}while(s<_&&i<k);o=l>>3,s-=o,l-=o<<3,a&=(1<<l)-1,d.next_in=s,d.next_out=i,d.avail_in=s<_?5+(_-s):5-(s-_),d.avail_out=i<k?257+(k-i):257-(i-k),n.hold=a,n.bits=l};
2
- //# sourceMappingURL=inffast.js.map
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../../../../../../../../GDevelop/Extensions/TileMap/helper/node_modules/pako/lib/zlib/inffast.js"],
4
- "sourcesContent": ["'use strict';\n\n// (C) 1995-2013 Jean-loup Gailly and Mark Adler\n// (C) 2014-2017 Vitaly Puzrin and Andrey Tupitsin\n//\n// This software is provided 'as-is', without any express or implied\n// warranty. In no event will the authors be held liable for any damages\n// arising from the use of this software.\n//\n// Permission is granted to anyone to use this software for any purpose,\n// including commercial applications, and to alter it and redistribute it\n// freely, subject to the following restrictions:\n//\n// 1. The origin of this software must not be misrepresented; you must not\n// claim that you wrote the original software. If you use this software\n// in a product, an acknowledgment in the product documentation would be\n// appreciated but is not required.\n// 2. Altered source versions must be plainly marked as such, and must not be\n// misrepresented as being the original software.\n// 3. This notice may not be removed or altered from any source distribution.\n\n// See state defs from inflate.js\nconst BAD = 30; /* got a data error -- remain here until reset */\nconst TYPE = 12; /* i: waiting for type bits, including last-flag bit */\n\n/*\n Decode literal, length, and distance codes and write out the resulting\n literal and match bytes until either not enough input or output is\n available, an end-of-block is encountered, or a data error is encountered.\n When large enough input and output buffers are supplied to inflate(), for\n example, a 16K input buffer and a 64K output buffer, more than 95% of the\n inflate execution time is spent in this routine.\n\n Entry assumptions:\n\n state.mode === LEN\n strm.avail_in >= 6\n strm.avail_out >= 258\n start >= strm.avail_out\n state.bits < 8\n\n On return, state.mode is one of:\n\n LEN -- ran out of enough output space or enough available input\n TYPE -- reached end of block code, inflate() to interpret next block\n BAD -- error in block data\n\n Notes:\n\n - The maximum input bits used by a length/distance pair is 15 bits for the\n length code, 5 bits for the length extra, 15 bits for the distance code,\n and 13 bits for the distance extra. This totals 48 bits, or six bytes.\n Therefore if strm.avail_in >= 6, then there is enough input to avoid\n checking for available input while decoding.\n\n - The maximum bytes that a single length/distance pair can output is 258\n bytes, which is the maximum length that can be coded. inflate_fast()\n requires strm.avail_out >= 258 for each loop to avoid checking for\n output space.\n */\nmodule.exports = function inflate_fast(strm, start) {\n let _in; /* local strm.input */\n let last; /* have enough input while in < last */\n let _out; /* local strm.output */\n let beg; /* inflate()'s initial strm.output */\n let end; /* while out < end, enough space available */\n//#ifdef INFLATE_STRICT\n let dmax; /* maximum distance from zlib header */\n//#endif\n let wsize; /* window size or zero if not using window */\n let whave; /* valid bytes in the window */\n let wnext; /* window write index */\n // Use `s_window` instead `window`, avoid conflict with instrumentation tools\n let s_window; /* allocated sliding window, if wsize != 0 */\n let hold; /* local strm.hold */\n let bits; /* local strm.bits */\n let lcode; /* local strm.lencode */\n let dcode; /* local strm.distcode */\n let lmask; /* mask for first level of length codes */\n let dmask; /* mask for first level of distance codes */\n let here; /* retrieved table entry */\n let op; /* code bits, operation, extra bits, or */\n /* window position, window bytes to copy */\n let len; /* match length, unused bytes */\n let dist; /* match distance */\n let from; /* where to copy match from */\n let from_source;\n\n\n let input, output; // JS specific, because we have no pointers\n\n /* copy state to local variables */\n const state = strm.state;\n //here = state.here;\n _in = strm.next_in;\n input = strm.input;\n last = _in + (strm.avail_in - 5);\n _out = strm.next_out;\n output = strm.output;\n beg = _out - (start - strm.avail_out);\n end = _out + (strm.avail_out - 257);\n//#ifdef INFLATE_STRICT\n dmax = state.dmax;\n//#endif\n wsize = state.wsize;\n whave = state.whave;\n wnext = state.wnext;\n s_window = state.window;\n hold = state.hold;\n bits = state.bits;\n lcode = state.lencode;\n dcode = state.distcode;\n lmask = (1 << state.lenbits) - 1;\n dmask = (1 << state.distbits) - 1;\n\n\n /* decode literals and length/distances until end-of-block or not enough\n input data or output space */\n\n top:\n do {\n if (bits < 15) {\n hold += input[_in++] << bits;\n bits += 8;\n hold += input[_in++] << bits;\n bits += 8;\n }\n\n here = lcode[hold & lmask];\n\n dolen:\n for (;;) { // Goto emulation\n op = here >>> 24/*here.bits*/;\n hold >>>= op;\n bits -= op;\n op = (here >>> 16) & 0xff/*here.op*/;\n if (op === 0) { /* literal */\n //Tracevv((stderr, here.val >= 0x20 && here.val < 0x7f ?\n // \"inflate: literal '%c'\\n\" :\n // \"inflate: literal 0x%02x\\n\", here.val));\n output[_out++] = here & 0xffff/*here.val*/;\n }\n else if (op & 16) { /* length base */\n len = here & 0xffff/*here.val*/;\n op &= 15; /* number of extra bits */\n if (op) {\n if (bits < op) {\n hold += input[_in++] << bits;\n bits += 8;\n }\n len += hold & ((1 << op) - 1);\n hold >>>= op;\n bits -= op;\n }\n //Tracevv((stderr, \"inflate: length %u\\n\", len));\n if (bits < 15) {\n hold += input[_in++] << bits;\n bits += 8;\n hold += input[_in++] << bits;\n bits += 8;\n }\n here = dcode[hold & dmask];\n\n dodist:\n for (;;) { // goto emulation\n op = here >>> 24/*here.bits*/;\n hold >>>= op;\n bits -= op;\n op = (here >>> 16) & 0xff/*here.op*/;\n\n if (op & 16) { /* distance base */\n dist = here & 0xffff/*here.val*/;\n op &= 15; /* number of extra bits */\n if (bits < op) {\n hold += input[_in++] << bits;\n bits += 8;\n if (bits < op) {\n hold += input[_in++] << bits;\n bits += 8;\n }\n }\n dist += hold & ((1 << op) - 1);\n//#ifdef INFLATE_STRICT\n if (dist > dmax) {\n strm.msg = 'invalid distance too far back';\n state.mode = BAD;\n break top;\n }\n//#endif\n hold >>>= op;\n bits -= op;\n //Tracevv((stderr, \"inflate: distance %u\\n\", dist));\n op = _out - beg; /* max distance in output */\n if (dist > op) { /* see if copy from window */\n op = dist - op; /* distance back in window */\n if (op > whave) {\n if (state.sane) {\n strm.msg = 'invalid distance too far back';\n state.mode = BAD;\n break top;\n }\n\n// (!) This block is disabled in zlib defaults,\n// don't enable it for binary compatibility\n//#ifdef INFLATE_ALLOW_INVALID_DISTANCE_TOOFAR_ARRR\n// if (len <= op - whave) {\n// do {\n// output[_out++] = 0;\n// } while (--len);\n// continue top;\n// }\n// len -= op - whave;\n// do {\n// output[_out++] = 0;\n// } while (--op > whave);\n// if (op === 0) {\n// from = _out - dist;\n// do {\n// output[_out++] = output[from++];\n// } while (--len);\n// continue top;\n// }\n//#endif\n }\n from = 0; // window index\n from_source = s_window;\n if (wnext === 0) { /* very common case */\n from += wsize - op;\n if (op < len) { /* some from window */\n len -= op;\n do {\n output[_out++] = s_window[from++];\n } while (--op);\n from = _out - dist; /* rest from output */\n from_source = output;\n }\n }\n else if (wnext < op) { /* wrap around window */\n from += wsize + wnext - op;\n op -= wnext;\n if (op < len) { /* some from end of window */\n len -= op;\n do {\n output[_out++] = s_window[from++];\n } while (--op);\n from = 0;\n if (wnext < len) { /* some from start of window */\n op = wnext;\n len -= op;\n do {\n output[_out++] = s_window[from++];\n } while (--op);\n from = _out - dist; /* rest from output */\n from_source = output;\n }\n }\n }\n else { /* contiguous in window */\n from += wnext - op;\n if (op < len) { /* some from window */\n len -= op;\n do {\n output[_out++] = s_window[from++];\n } while (--op);\n from = _out - dist; /* rest from output */\n from_source = output;\n }\n }\n while (len > 2) {\n output[_out++] = from_source[from++];\n output[_out++] = from_source[from++];\n output[_out++] = from_source[from++];\n len -= 3;\n }\n if (len) {\n output[_out++] = from_source[from++];\n if (len > 1) {\n output[_out++] = from_source[from++];\n }\n }\n }\n else {\n from = _out - dist; /* copy direct from output */\n do { /* minimum length is three */\n output[_out++] = output[from++];\n output[_out++] = output[from++];\n output[_out++] = output[from++];\n len -= 3;\n } while (len > 2);\n if (len) {\n output[_out++] = output[from++];\n if (len > 1) {\n output[_out++] = output[from++];\n }\n }\n }\n }\n else if ((op & 64) === 0) { /* 2nd level distance code */\n here = dcode[(here & 0xffff)/*here.val*/ + (hold & ((1 << op) - 1))];\n continue dodist;\n }\n else {\n strm.msg = 'invalid distance code';\n state.mode = BAD;\n break top;\n }\n\n break; // need to emulate goto via \"continue\"\n }\n }\n else if ((op & 64) === 0) { /* 2nd level length code */\n here = lcode[(here & 0xffff)/*here.val*/ + (hold & ((1 << op) - 1))];\n continue dolen;\n }\n else if (op & 32) { /* end-of-block */\n //Tracevv((stderr, \"inflate: end of block\\n\"));\n state.mode = TYPE;\n break top;\n }\n else {\n strm.msg = 'invalid literal/length code';\n state.mode = BAD;\n break top;\n }\n\n break; // need to emulate goto via \"continue\"\n }\n } while (_in < last && _out < end);\n\n /* return unused bytes (on entry, bits < 8, so in won't go too far back) */\n len = bits >> 3;\n _in -= len;\n bits -= len << 3;\n hold &= (1 << bits) - 1;\n\n /* update state and return */\n strm.next_in = _in;\n strm.next_out = _out;\n strm.avail_in = (_in < last ? 5 + (last - _in) : 5 - (_in - last));\n strm.avail_out = (_out < end ? 257 + (end - _out) : 257 - (_out - end));\n state.hold = hold;\n state.bits = bits;\n return;\n};\n"],
5
- "mappings": "aAsBA,KAAM,KAAM,GACN,KAAO,GAqCb,OAAO,QAAU,SAAsB,EAAM,EAAO,CAClD,GAAI,GACA,EACA,EACA,EACA,EAEA,EAEA,EACA,EACA,EAEA,EACA,EACA,EACA,EACA,EACA,EACA,EACA,EACA,EAEA,EACA,EACA,EACA,EAGA,EAAO,EAGX,KAAM,GAAQ,EAAK,MAEnB,EAAM,EAAK,QACX,EAAQ,EAAK,MACb,EAAO,EAAO,GAAK,SAAW,GAC9B,EAAO,EAAK,SACZ,EAAS,EAAK,OACd,EAAM,EAAQ,GAAQ,EAAK,WAC3B,EAAM,EAAQ,GAAK,UAAY,KAE/B,EAAO,EAAM,KAEb,EAAQ,EAAM,MACd,EAAQ,EAAM,MACd,EAAQ,EAAM,MACd,EAAW,EAAM,OACjB,EAAO,EAAM,KACb,EAAO,EAAM,KACb,EAAQ,EAAM,QACd,EAAQ,EAAM,SACd,EAAS,IAAK,EAAM,SAAW,EAC/B,EAAS,IAAK,EAAM,UAAY,EAMhC,EACA,EAAG,CACD,AAAI,EAAO,IACT,IAAQ,EAAM,MAAU,EACxB,GAAQ,EACR,GAAQ,EAAM,MAAU,EACxB,GAAQ,GAGV,EAAO,EAAM,EAAO,GAEpB,EACA,OAAS,CAKP,GAJA,EAAK,IAAS,GACd,KAAU,E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AAc,YAKlB,GAAQ,EAAQ,EACZ,EAAK,EAAK,CACZ,GAAO,EACP,EACE,GAAO,KAAU,EAAS,WACnB,EAAE,GACX,EAAO,EAAO,EACd,EAAc,EAGlB,KAAO,EAAM,GACX,EAAO,KAAU,EAAY,KAC7B,EAAO,KAAU,EAAY,KAC7B,EAAO,KAAU,EAAY,KAC7B,GAAO,EAET,AAAI,GACF,GAAO,KAAU,EAAY,KACzB,EAAM,GACR,GAAO,KAAU,EAAY,WAI9B,CACH,EAAO,EAAO,EACd,EACE,GAAO,KAAU,EAAO,KACxB,EAAO,KAAU,EAAO,KACxB,EAAO,KAAU,EAAO,KACxB,GAAO,QACA,EAAM,GACf,AAAI,GACF,GAAO,KAAU,EAAO,KACpB,EAAM,GACR,GAAO,KAAU,EAAO,gBAKtB,GAAK,KAAQ,EAAG,CACxB,EAAO,EAAO,GAAO,OAAuB,GAAS,IAAK,GAAM,IAChE,eAEG,CACH,EAAK,IAAM,wBACX,EAAM,KAAO,IACb,QAGF,eAGM,GAAK,KAAQ,EAAG,CACxB,EAAO,EAAO,GAAO,OAAuB,GAAS,IAAK,GAAM,IAChE,mBAEO,EAAK,GAAI,CAEhB,EAAM,KAAO,KACb,YAEG,CACH,EAAK,IAAM,8BACX,EAAM,KAAO,IACb,QAGF,aAEK,EAAM,GAAQ,EAAO,GAG9B,EAAM,GAAQ,EACd,GAAO,EACP,GAAQ,GAAO,EACf,GAAS,IAAK,GAAQ,EAGtB,EAAK,QAAU,EACf,EAAK,SAAW,EAChB,EAAK,SAAY,EAAM,EAAO,EAAK,GAAO,GAAO,EAAK,GAAM,GAC5D,EAAK,UAAa,EAAO,EAAM,IAAO,GAAM,GAAQ,IAAO,GAAO,GAClE,EAAM,KAAO,EACb,EAAM,KAAO",
6
- "names": []
7
- }
@@ -1,2 +0,0 @@
1
- "use strict";const adler32=require("./adler32"),crc32=require("./crc32"),inflate_fast=require("./inffast"),inflate_table=require("./inftrees"),CODES=0,LENS=1,DISTS=2,{Z_FINISH,Z_BLOCK,Z_TREES,Z_OK,Z_STREAM_END,Z_NEED_DICT,Z_STREAM_ERROR,Z_DATA_ERROR,Z_MEM_ERROR,Z_BUF_ERROR,Z_DEFLATED}=require("./constants"),HEAD=1,FLAGS=2,TIME=3,OS=4,EXLEN=5,EXTRA=6,NAME=7,COMMENT=8,HCRC=9,DICTID=10,DICT=11,TYPE=12,TYPEDO=13,STORED=14,COPY_=15,COPY=16,TABLE=17,LENLENS=18,CODELENS=19,LEN_=20,LEN=21,LENEXT=22,DIST=23,DISTEXT=24,MATCH=25,LIT=26,CHECK=27,LENGTH=28,DONE=29,BAD=30,MEM=31,SYNC=32,ENOUGH_LENS=852,ENOUGH_DISTS=592,MAX_WBITS=15,DEF_WBITS=MAX_WBITS,zswap32=t=>(t>>>24&255)+(t>>>8&65280)+((t&65280)<<8)+((t&255)<<24);function InflateState(){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 Uint16Array(320),this.work=new Uint16Array(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}const inflateResetKeep=t=>{if(!t||!t.state)return Z_STREAM_ERROR;const f=t.state;return t.total_in=t.total_out=f.total=0,t.msg="",f.wrap&&(t.adler=f.wrap&1),f.mode=HEAD,f.last=0,f.havedict=0,f.dmax=32768,f.head=null,f.hold=0,f.bits=0,f.lencode=f.lendyn=new Int32Array(ENOUGH_LENS),f.distcode=f.distdyn=new Int32Array(ENOUGH_DISTS),f.sane=1,f.back=-1,Z_OK},inflateReset=t=>{if(!t||!t.state)return Z_STREAM_ERROR;const f=t.state;return f.wsize=0,f.whave=0,f.wnext=0,inflateResetKeep(t)},inflateReset2=(t,f)=>{let e;if(!t||!t.state)return Z_STREAM_ERROR;const o=t.state;return f<0?(e=0,f=-f):(e=(f>>4)+1,f<48&&(f&=15)),f&&(f<8||f>15)?Z_STREAM_ERROR:(o.window!==null&&o.wbits!==f&&(o.window=null),o.wrap=e,o.wbits=f,inflateReset(t))},inflateInit2=(t,f)=>{if(!t)return Z_STREAM_ERROR;const e=new InflateState;t.state=e,e.window=null;const o=inflateReset2(t,f);return o!==Z_OK&&(t.state=null),o},inflateInit=t=>inflateInit2(t,DEF_WBITS);let virgin=!0,lenfix,distfix;const fixedtables=t=>{if(virgin){lenfix=new Int32Array(512),distfix=new Int32Array(32);let f=0;for(;f<144;)t.lens[f++]=8;for(;f<256;)t.lens[f++]=9;for(;f<280;)t.lens[f++]=7;for(;f<288;)t.lens[f++]=8;for(inflate_table(LENS,t.lens,0,288,lenfix,0,t.work,{bits:9}),f=0;f<32;)t.lens[f++]=5;inflate_table(DISTS,t.lens,0,32,distfix,0,t.work,{bits:5}),virgin=!1}t.lencode=lenfix,t.lenbits=9,t.distcode=distfix,t.distbits=5},updatewindow=(t,f,e,o)=>{let d;const n=t.state;return n.window===null&&(n.wsize=1<<n.wbits,n.wnext=0,n.whave=0,n.window=new Uint8Array(n.wsize)),o>=n.wsize?(n.window.set(f.subarray(e-n.wsize,e),0),n.wnext=0,n.whave=n.wsize):(d=n.wsize-n.wnext,d>o&&(d=o),n.window.set(f.subarray(e-o,e-o+d),n.wnext),o-=d,o?(n.window.set(f.subarray(e-o,e),0),n.wnext=o,n.whave=n.wsize):(n.wnext+=d,n.wnext===n.wsize&&(n.wnext=0),n.whave<n.wsize&&(n.whave+=d))),0},inflate=(t,f)=>{let e,o,d,n,_,l,b,i,a,m,h,s,S,R,r=0,c,w,g,u,T,I,k,v;const x=new Uint8Array(4);let p,E;const A=new Uint8Array([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]);if(!t||!t.state||!t.output||!t.input&&t.avail_in!==0)return Z_STREAM_ERROR;e=t.state,e.mode===TYPE&&(e.mode=TYPEDO),_=t.next_out,d=t.output,b=t.avail_out,n=t.next_in,o=t.input,l=t.avail_in,i=e.hold,a=e.bits,m=l,h=b,v=Z_OK;e:for(;;)switch(e.mode){case HEAD:if(e.wrap===0){e.mode=TYPEDO;break}for(;a<16;){if(l===0)break e;l--,i+=o[n++]<<a,a+=8}if(e.wrap&2&&i===35615){e.check=0,x[0]=i&255,x[1]=i>>>8&255,e.check=crc32(e.check,x,2,0),i=0,a=0,e.mode=FLAGS;break}if(e.flags=0,e.head&&(e.head.done=!1),!(e.wrap&1)||(((i&255)<<8)+(i>>8))%31){t.msg="incorrect header check",e.mode=BAD;break}if((i&15)!==Z_DEFLATED){t.msg="unknown compression method",e.mode=BAD;break}if(i>>>=4,a-=4,k=(i&15)+8,e.wbits===0)e.wbits=k;else if(k>e.wbits){t.msg="invalid window size",e.mode=BAD;break}e.dmax=1<<e.wbits,t.adler=e.check=1,e.mode=i&512?DICTID:TYPE,i=0,a=0;break;case FLAGS:for(;a<16;){if(l===0)break e;l--,i+=o[n++]<<a,a+=8}if(e.flags=i,(e.flags&255)!==Z_DEFLATED){t.msg="unknown compression method",e.mode=BAD;break}if(e.flags&57344){t.msg="unknown header flags set",e.mode=BAD;break}e.head&&(e.head.text=i>>8&1),e.flags&512&&(x[0]=i&255,x[1]=i>>>8&255,e.check=crc32(e.check,x,2,0)),i=0,a=0,e.mode=TIME;case TIME:for(;a<32;){if(l===0)break e;l--,i+=o[n++]<<a,a+=8}e.head&&(e.head.time=i),e.flags&512&&(x[0]=i&255,x[1]=i>>>8&255,x[2]=i>>>16&255,x[3]=i>>>24&255,e.check=crc32(e.check,x,4,0)),i=0,a=0,e.mode=OS;case OS:for(;a<16;){if(l===0)break e;l--,i+=o[n++]<<a,a+=8}e.head&&(e.head.xflags=i&255,e.head.os=i>>8),e.flags&512&&(x[0]=i&255,x[1]=i>>>8&255,e.check=crc32(e.check,x,2,0)),i=0,a=0,e.mode=EXLEN;case EXLEN:if(e.flags&1024){for(;a<16;){if(l===0)break e;l--,i+=o[n++]<<a,a+=8}e.length=i,e.head&&(e.head.extra_len=i),e.flags&512&&(x[0]=i&255,x[1]=i>>>8&255,e.check=crc32(e.check,x,2,0)),i=0,a=0}else e.head&&(e.head.extra=null);e.mode=EXTRA;case EXTRA:if(e.flags&1024&&(s=e.length,s>l&&(s=l),s&&(e.head&&(k=e.head.extra_len-e.length,e.head.extra||(e.head.extra=new Uint8Array(e.head.extra_len)),e.head.extra.set(o.subarray(n,n+s),k)),e.flags&512&&(e.check=crc32(e.check,o,s,n)),l-=s,n+=s,e.length-=s),e.length))break e;e.length=0,e.mode=NAME;case NAME:if(e.flags&2048){if(l===0)break e;s=0;do k=o[n+s++],e.head&&k&&e.length<65536&&(e.head.name+=String.fromCharCode(k));while(k&&s<l);if(e.flags&512&&(e.check=crc32(e.check,o,s,n)),l-=s,n+=s,k)break e}else e.head&&(e.head.name=null);e.length=0,e.mode=COMMENT;case COMMENT:if(e.flags&4096){if(l===0)break e;s=0;do k=o[n+s++],e.head&&k&&e.length<65536&&(e.head.comment+=String.fromCharCode(k));while(k&&s<l);if(e.flags&512&&(e.check=crc32(e.check,o,s,n)),l-=s,n+=s,k)break e}else e.head&&(e.head.comment=null);e.mode=HCRC;case HCRC:if(e.flags&512){for(;a<16;){if(l===0)break e;l--,i+=o[n++]<<a,a+=8}if(i!==(e.check&65535)){t.msg="header crc mismatch",e.mode=BAD;break}i=0,a=0}e.head&&(e.head.hcrc=e.flags>>9&1,e.head.done=!0),t.adler=e.check=0,e.mode=TYPE;break;case DICTID:for(;a<32;){if(l===0)break e;l--,i+=o[n++]<<a,a+=8}t.adler=e.check=zswap32(i),i=0,a=0,e.mode=DICT;case DICT:if(e.havedict===0)return t.next_out=_,t.avail_out=b,t.next_in=n,t.avail_in=l,e.hold=i,e.bits=a,Z_NEED_DICT;t.adler=e.check=1,e.mode=TYPE;case TYPE:if(f===Z_BLOCK||f===Z_TREES)break e;case TYPEDO:if(e.last){i>>>=a&7,a-=a&7,e.mode=CHECK;break}for(;a<3;){if(l===0)break e;l--,i+=o[n++]<<a,a+=8}switch(e.last=i&1,i>>>=1,a-=1,i&3){case 0:e.mode=STORED;break;case 1:if(fixedtables(e),e.mode=LEN_,f===Z_TREES){i>>>=2,a-=2;break e}break;case 2:e.mode=TABLE;break;case 3:t.msg="invalid block type",e.mode=BAD}i>>>=2,a-=2;break;case STORED:for(i>>>=a&7,a-=a&7;a<32;){if(l===0)break e;l--,i+=o[n++]<<a,a+=8}if((i&65535)!=(i>>>16^65535)){t.msg="invalid stored block lengths",e.mode=BAD;break}if(e.length=i&65535,i=0,a=0,e.mode=COPY_,f===Z_TREES)break e;case COPY_:e.mode=COPY;case COPY:if(s=e.length,s){if(s>l&&(s=l),s>b&&(s=b),s===0)break e;d.set(o.subarray(n,n+s),_),l-=s,n+=s,b-=s,_+=s,e.length-=s;break}e.mode=TYPE;break;case TABLE:for(;a<14;){if(l===0)break e;l--,i+=o[n++]<<a,a+=8}if(e.nlen=(i&31)+257,i>>>=5,a-=5,e.ndist=(i&31)+1,i>>>=5,a-=5,e.ncode=(i&15)+4,i>>>=4,a-=4,e.nlen>286||e.ndist>30){t.msg="too many length or distance symbols",e.mode=BAD;break}e.have=0,e.mode=LENLENS;case LENLENS:for(;e.have<e.ncode;){for(;a<3;){if(l===0)break e;l--,i+=o[n++]<<a,a+=8}e.lens[A[e.have++]]=i&7,i>>>=3,a-=3}for(;e.have<19;)e.lens[A[e.have++]]=0;if(e.lencode=e.lendyn,e.lenbits=7,p={bits:e.lenbits},v=inflate_table(CODES,e.lens,0,19,e.lencode,0,e.work,p),e.lenbits=p.bits,v){t.msg="invalid code lengths set",e.mode=BAD;break}e.have=0,e.mode=CODELENS;case CODELENS:for(;e.have<e.nlen+e.ndist;){for(;r=e.lencode[i&(1<<e.lenbits)-1],c=r>>>24,w=r>>>16&255,g=r&65535,!(c<=a);){if(l===0)break e;l--,i+=o[n++]<<a,a+=8}if(g<16)i>>>=c,a-=c,e.lens[e.have++]=g;else{if(g===16){for(E=c+2;a<E;){if(l===0)break e;l--,i+=o[n++]<<a,a+=8}if(i>>>=c,a-=c,e.have===0){t.msg="invalid bit length repeat",e.mode=BAD;break}k=e.lens[e.have-1],s=3+(i&3),i>>>=2,a-=2}else if(g===17){for(E=c+3;a<E;){if(l===0)break e;l--,i+=o[n++]<<a,a+=8}i>>>=c,a-=c,k=0,s=3+(i&7),i>>>=3,a-=3}else{for(E=c+7;a<E;){if(l===0)break e;l--,i+=o[n++]<<a,a+=8}i>>>=c,a-=c,k=0,s=11+(i&127),i>>>=7,a-=7}if(e.have+s>e.nlen+e.ndist){t.msg="invalid bit length repeat",e.mode=BAD;break}for(;s--;)e.lens[e.have++]=k}}if(e.mode===BAD)break;if(e.lens[256]===0){t.msg="invalid code -- missing end-of-block",e.mode=BAD;break}if(e.lenbits=9,p={bits:e.lenbits},v=inflate_table(LENS,e.lens,0,e.nlen,e.lencode,0,e.work,p),e.lenbits=p.bits,v){t.msg="invalid literal/lengths set",e.mode=BAD;break}if(e.distbits=6,e.distcode=e.distdyn,p={bits:e.distbits},v=inflate_table(DISTS,e.lens,e.nlen,e.ndist,e.distcode,0,e.work,p),e.distbits=p.bits,v){t.msg="invalid distances set",e.mode=BAD;break}if(e.mode=LEN_,f===Z_TREES)break e;case LEN_:e.mode=LEN;case LEN:if(l>=6&&b>=258){t.next_out=_,t.avail_out=b,t.next_in=n,t.avail_in=l,e.hold=i,e.bits=a,inflate_fast(t,h),_=t.next_out,d=t.output,b=t.avail_out,n=t.next_in,o=t.input,l=t.avail_in,i=e.hold,a=e.bits,e.mode===TYPE&&(e.back=-1);break}for(e.back=0;r=e.lencode[i&(1<<e.lenbits)-1],c=r>>>24,w=r>>>16&255,g=r&65535,!(c<=a);){if(l===0)break e;l--,i+=o[n++]<<a,a+=8}if(w&&(w&240)==0){for(u=c,T=w,I=g;r=e.lencode[I+((i&(1<<u+T)-1)>>u)],c=r>>>24,w=r>>>16&255,g=r&65535,!(u+c<=a);){if(l===0)break e;l--,i+=o[n++]<<a,a+=8}i>>>=u,a-=u,e.back+=u}if(i>>>=c,a-=c,e.back+=c,e.length=g,w===0){e.mode=LIT;break}if(w&32){e.back=-1,e.mode=TYPE;break}if(w&64){t.msg="invalid literal/length code",e.mode=BAD;break}e.extra=w&15,e.mode=LENEXT;case LENEXT:if(e.extra){for(E=e.extra;a<E;){if(l===0)break e;l--,i+=o[n++]<<a,a+=8}e.length+=i&(1<<e.extra)-1,i>>>=e.extra,a-=e.extra,e.back+=e.extra}e.was=e.length,e.mode=DIST;case DIST:for(;r=e.distcode[i&(1<<e.distbits)-1],c=r>>>24,w=r>>>16&255,g=r&65535,!(c<=a);){if(l===0)break e;l--,i+=o[n++]<<a,a+=8}if((w&240)==0){for(u=c,T=w,I=g;r=e.distcode[I+((i&(1<<u+T)-1)>>u)],c=r>>>24,w=r>>>16&255,g=r&65535,!(u+c<=a);){if(l===0)break e;l--,i+=o[n++]<<a,a+=8}i>>>=u,a-=u,e.back+=u}if(i>>>=c,a-=c,e.back+=c,w&64){t.msg="invalid distance code",e.mode=BAD;break}e.offset=g,e.extra=w&15,e.mode=DISTEXT;case DISTEXT:if(e.extra){for(E=e.extra;a<E;){if(l===0)break e;l--,i+=o[n++]<<a,a+=8}e.offset+=i&(1<<e.extra)-1,i>>>=e.extra,a-=e.extra,e.back+=e.extra}if(e.offset>e.dmax){t.msg="invalid distance too far back",e.mode=BAD;break}e.mode=MATCH;case MATCH:if(b===0)break e;if(s=h-b,e.offset>s){if(s=e.offset-s,s>e.whave&&e.sane){t.msg="invalid distance too far back",e.mode=BAD;break}s>e.wnext?(s-=e.wnext,S=e.wsize-s):S=e.wnext-s,s>e.length&&(s=e.length),R=e.window}else R=d,S=_-e.offset,s=e.length;s>b&&(s=b),b-=s,e.length-=s;do d[_++]=R[S++];while(--s);e.length===0&&(e.mode=LEN);break;case LIT:if(b===0)break e;d[_++]=e.length,b--,e.mode=LEN;break;case CHECK:if(e.wrap){for(;a<32;){if(l===0)break e;l--,i|=o[n++]<<a,a+=8}if(h-=b,t.total_out+=h,e.total+=h,h&&(t.adler=e.check=e.flags?crc32(e.check,d,h,_-h):adler32(e.check,d,h,_-h)),h=b,(e.flags?i:zswap32(i))!==e.check){t.msg="incorrect data check",e.mode=BAD;break}i=0,a=0}e.mode=LENGTH;case LENGTH:if(e.wrap&&e.flags){for(;a<32;){if(l===0)break e;l--,i+=o[n++]<<a,a+=8}if(i!==(e.total&4294967295)){t.msg="incorrect length check",e.mode=BAD;break}i=0,a=0}e.mode=DONE;case DONE:v=Z_STREAM_END;break e;case BAD:v=Z_DATA_ERROR;break e;case MEM:return Z_MEM_ERROR;case SYNC:default:return Z_STREAM_ERROR}return t.next_out=_,t.avail_out=b,t.next_in=n,t.avail_in=l,e.hold=i,e.bits=a,(e.wsize||h!==t.avail_out&&e.mode<BAD&&(e.mode<CHECK||f!==Z_FINISH))&&updatewindow(t,t.output,t.next_out,h-t.avail_out)?(e.mode=MEM,Z_MEM_ERROR):(m-=t.avail_in,h-=t.avail_out,t.total_in+=m,t.total_out+=h,e.total+=h,e.wrap&&h&&(t.adler=e.check=e.flags?crc32(e.check,d,h,t.next_out-h):adler32(e.check,d,h,t.next_out-h)),t.data_type=e.bits+(e.last?64:0)+(e.mode===TYPE?128:0)+(e.mode===LEN_||e.mode===COPY_?256:0),(m===0&&h===0||f===Z_FINISH)&&v===Z_OK&&(v=Z_BUF_ERROR),v)},inflateEnd=t=>{if(!t||!t.state)return Z_STREAM_ERROR;let f=t.state;return f.window&&(f.window=null),t.state=null,Z_OK},inflateGetHeader=(t,f)=>{if(!t||!t.state)return Z_STREAM_ERROR;const e=t.state;return(e.wrap&2)==0?Z_STREAM_ERROR:(e.head=f,f.done=!1,Z_OK)},inflateSetDictionary=(t,f)=>{const e=f.length;let o,d,n;return!t||!t.state||(o=t.state,o.wrap!==0&&o.mode!==DICT)?Z_STREAM_ERROR:o.mode===DICT&&(d=1,d=adler32(d,f,e,0),d!==o.check)?Z_DATA_ERROR:(n=updatewindow(t,f,e,e),n?(o.mode=MEM,Z_MEM_ERROR):(o.havedict=1,Z_OK))};module.exports.inflateReset=inflateReset,module.exports.inflateReset2=inflateReset2,module.exports.inflateResetKeep=inflateResetKeep,module.exports.inflateInit=inflateInit,module.exports.inflateInit2=inflateInit2,module.exports.inflate=inflate,module.exports.inflateEnd=inflateEnd,module.exports.inflateGetHeader=inflateGetHeader,module.exports.inflateSetDictionary=inflateSetDictionary,module.exports.inflateInfo="pako inflate (from Nodeca project)";
2
- //# sourceMappingURL=inflate.js.map