@zip.js/zip.js 2.7.73 → 2.8.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (69) hide show
  1. package/deno.json +2 -4
  2. package/dist/README.md +7 -25
  3. package/dist/zip-core.js +5961 -0
  4. package/dist/zip-core.min.js +1 -0
  5. package/dist/{zip-full.js → zip-fs-core.js} +4160 -7358
  6. package/dist/zip-fs-core.min.js +1 -0
  7. package/dist/zip-fs.js +4355 -2542
  8. package/dist/zip-fs.min.js +1 -1
  9. package/dist/zip-module.wasm +0 -0
  10. package/dist/zip-web-worker.js +1 -0
  11. package/dist/zip.js +2647 -2466
  12. package/dist/zip.min.js +1 -1
  13. package/index.cjs +4624 -8659
  14. package/index.d.ts +27 -176
  15. package/index.js +2 -63
  16. package/index.min.js +1 -1
  17. package/lib/core/codec-pool.js +6 -4
  18. package/lib/core/codec-worker.js +37 -20
  19. package/lib/core/configuration.js +16 -37
  20. package/lib/core/io.js +3 -8
  21. package/lib/core/streams/aes-crypto-stream.js +1 -0
  22. package/lib/core/streams/zip-entry-stream.js +19 -11
  23. package/lib/core/streams/zlib/README.md +1 -0
  24. package/lib/core/streams/{stream-adapter.js → zlib/zlib-streams-loader.js} +54 -25
  25. package/lib/core/streams/zlib/zlib-streams.js +184 -0
  26. package/lib/core/streams/zlib/zlib-streams.wasm +0 -0
  27. package/lib/core/util/decode-text.js +1 -1
  28. package/lib/core/util/encode-text.js +1 -0
  29. package/lib/core/util/mini-lz.js +198 -0
  30. package/lib/{z-worker.js → core/web-worker-inline-template.js} +10 -9
  31. package/lib/core/web-worker-inline.js +1 -0
  32. package/lib/core/{z-worker-core.js → web-worker.js} +17 -36
  33. package/lib/core/zip-entry.js +3 -7
  34. package/lib/core/zip-reader.js +11 -4
  35. package/lib/core/zip-writer.js +11 -13
  36. package/lib/{z-worker-bootstrap-pako.js → core/zlib-streams-inline-template.js} +8 -10
  37. package/lib/core/zlib-streams-inline.js +1 -0
  38. package/{index-fflate.js → lib/zip-core.js} +43 -22
  39. package/lib/{z-worker-fflate.js → zip-fs-core.js} +5 -15
  40. package/lib/zip-fs.js +7 -24
  41. package/lib/zip.js +6 -23
  42. package/package.json +13 -33
  43. package/dist/z-worker-fflate.js +0 -1
  44. package/dist/z-worker-pako.js +0 -1
  45. package/dist/z-worker.js +0 -1
  46. package/dist/zip-fs-full.js +0 -12536
  47. package/dist/zip-fs-full.min.js +0 -1
  48. package/dist/zip-full.min.js +0 -1
  49. package/dist/zip-no-worker-deflate.min.js +0 -1
  50. package/dist/zip-no-worker-inflate.min.js +0 -1
  51. package/dist/zip-no-worker.min.js +0 -1
  52. package/lib/core/streams/codecs/deflate.js +0 -2059
  53. package/lib/core/streams/codecs/inflate.js +0 -2163
  54. package/lib/core/util/stream-codec-shim.js +0 -91
  55. package/lib/z-worker-bootstrap-fflate.js +0 -40
  56. package/lib/z-worker-inline-template.js +0 -42
  57. package/lib/z-worker-inline.js +0 -1
  58. package/lib/zip-data-uri.js +0 -56
  59. package/lib/zip-fflate-shim.js +0 -37
  60. package/lib/zip-full-fflate.js +0 -54
  61. package/lib/zip-full.js +0 -55
  62. package/lib/zip-no-worker-deflate.js +0 -42
  63. package/lib/zip-no-worker-fflate-deflate.js +0 -42
  64. package/lib/zip-no-worker-fflate-inflate.js +0 -42
  65. package/lib/zip-no-worker-fflate.js +0 -43
  66. package/lib/zip-no-worker-inflate.js +0 -42
  67. package/lib/zip-no-worker.js +0 -44
  68. /package/lib/core/util/{cp437-decode.js → decode-cp437.js} +0 -0
  69. /package/lib/core/{zip-fs-core.js → zip-fs.js} +0 -0
package/deno.json CHANGED
@@ -1,9 +1,8 @@
1
1
  {
2
2
  "name": "@zip-js/zip-js",
3
- "version": "2.7.73",
3
+ "version": "2.8.1",
4
4
  "exports": {
5
- ".": "./index.js",
6
- "./data-uri": "./lib/zip-data-uri.js"
5
+ ".": "./index.js"
7
6
  },
8
7
  "lint": {
9
8
  "exclude": [
@@ -15,7 +14,6 @@
15
14
  ]
16
15
  },
17
16
  "exclude": [
18
- "cli-deno",
19
17
  "rollup*",
20
18
  "tsconfig.json",
21
19
  ".vscode",
package/dist/README.md CHANGED
@@ -1,28 +1,10 @@
1
- # Built scripts of zip.js
1
+ # Prebuilt zip.js bundles
2
2
 
3
- **Warning**: These files are not compatible with ES modules, i.e. they cannot be imported with `import`. Instead, import `index.js` in the root folder of the project or one of the files prefixed with `zip-` in the [`/lib`](../lib) folder (e.g. `/lib/zip-no-worker-inflate.js`).
3
+ **Note**: These bundles are not ES module compatible (you cannot `import` them directly). Use `index.js` at the project root or one of the `zip-*.js` files in [`/lib`](../lib) (e.g. `/lib/zip-core.js`) for ESM usage.
4
4
 
5
- - for production (minified):
5
+ Contents:
6
6
 
7
- | | [`ZipReader`](https://gildas-lormeau.github.io/zip.js/api/classes/ZipReader.html) API | [`ZipWriter`](https://gildas-lormeau.github.io/zip.js/api/classes/ZipWriter.html) API | [`zip.fs`](https://gildas-lormeau.github.io/zip.js/api/classes/FS.html) API | Web Workers | No Web Workers | Usage |
8
- |--------------------------------|-----------------|-----------------|--------------|-------------|----------------|-------------------------------------------------------|
9
- | `zip.min.js` | x | x | | x | | compression/decompression with web workers |
10
- | `zip-no-worker.min.js` | x | x | | | x | compression/decompression without web workers |
11
- | `zip-no-worker-inflate.min.js` | x | | | | x | decompression without web workers |
12
- | `zip-no-worker-deflate.min.js` | | x | | | x | compression without web workers |
13
- | `zip-full.min.js` | x | x | | x | x | compression/decompression with or without web workers |
14
- | `zip-fs.min.js` | x | x | x | x | | compression/decompression with web workers |
15
- | `zip-fs-full.min.js` | x | x | x | x | x | compression/decompression with or without web workers |
16
-
17
- - for development/debugging:
18
-
19
- | | `zip` API | [`zip.fs`](https://gildas-lormeau.github.io/zip.js/api/classes/FS.html) API | Web Workers | No Web Workers |
20
- |-----------------------|-----------|--------------|-------------|----------------|
21
- | `zip.js` | x | | x | |
22
- | `zip-full.js` | x | | x | x |
23
- | `zip-fs.js` | x | x | x | |
24
- | `zip-fs-full.js` | x | x | x | x |
25
-
26
- - `z-worker.js` can be used as a web worker script if the [Content Security Policy](https://developer.mozilla.org/docs/Web/HTTP/CSP) blocks scripts loaded with a `blob:` scheme
27
- - `z-worker-fflate.js` is the web worker script for using [fflate](https://gildas-lormeau.github.io/zip.js/core-api.html#alternative-codec-fflate)
28
- - `z-worker-pako.js` is the web worker script for using [pako](https://gildas-lormeau.github.io/zip.js/core-api.html#alternative-codec-pako)
7
+ - `zip.js` / `zip.min.js`: Full `ZipWriter` / `ZipReader` bundles with embedded Web Worker code and WASM.
8
+ - `zip-fs.js` / `zip-fs.min.js`: Full `ZipWriter` / `ZipReader` plus virtual file system (`fs`), with embedded Web Worker code and WASM.
9
+ - `zip-core.js` / `zip-core.min.js`: Minimal `ZipWriter` / `ZipReader`.
10
+ - `zip-fs-core.js` / `zip-fs-core.min.js`: Minimal `ZipWriter` / `ZipReader` plus virtual file system (`fs`).