@wecode-ai/weibo-openclaw-plugin 2.1.4 → 2.2.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 (368) hide show
  1. package/README.md +28 -1
  2. package/node_modules/@isaacs/fs-minipass/LICENSE +15 -0
  3. package/node_modules/@isaacs/fs-minipass/README.md +71 -0
  4. package/node_modules/@isaacs/fs-minipass/dist/commonjs/index.d.ts +118 -0
  5. package/node_modules/@isaacs/fs-minipass/dist/commonjs/index.d.ts.map +1 -0
  6. package/node_modules/@isaacs/fs-minipass/dist/commonjs/index.js +430 -0
  7. package/node_modules/@isaacs/fs-minipass/dist/commonjs/index.js.map +1 -0
  8. package/node_modules/@isaacs/fs-minipass/dist/commonjs/package.json +3 -0
  9. package/node_modules/@isaacs/fs-minipass/dist/esm/index.d.ts +118 -0
  10. package/node_modules/@isaacs/fs-minipass/dist/esm/index.d.ts.map +1 -0
  11. package/node_modules/@isaacs/fs-minipass/dist/esm/index.js +420 -0
  12. package/node_modules/@isaacs/fs-minipass/dist/esm/index.js.map +1 -0
  13. package/node_modules/@isaacs/fs-minipass/dist/esm/package.json +3 -0
  14. package/node_modules/@isaacs/fs-minipass/package.json +72 -0
  15. package/node_modules/chownr/LICENSE.md +63 -0
  16. package/node_modules/chownr/README.md +3 -0
  17. package/node_modules/chownr/dist/commonjs/index.d.ts +3 -0
  18. package/node_modules/chownr/dist/commonjs/index.d.ts.map +1 -0
  19. package/node_modules/chownr/dist/commonjs/index.js +93 -0
  20. package/node_modules/chownr/dist/commonjs/index.js.map +1 -0
  21. package/node_modules/chownr/dist/commonjs/package.json +3 -0
  22. package/node_modules/chownr/dist/esm/index.d.ts +3 -0
  23. package/node_modules/chownr/dist/esm/index.d.ts.map +1 -0
  24. package/node_modules/chownr/dist/esm/index.js +85 -0
  25. package/node_modules/chownr/dist/esm/index.js.map +1 -0
  26. package/node_modules/chownr/dist/esm/package.json +3 -0
  27. package/node_modules/chownr/package.json +69 -0
  28. package/node_modules/minipass/LICENSE.md +55 -0
  29. package/node_modules/minipass/README.md +825 -0
  30. package/node_modules/minipass/dist/commonjs/index.d.ts +545 -0
  31. package/node_modules/minipass/dist/commonjs/index.d.ts.map +1 -0
  32. package/node_modules/minipass/dist/commonjs/index.js +1038 -0
  33. package/node_modules/minipass/dist/commonjs/index.js.map +1 -0
  34. package/node_modules/minipass/dist/commonjs/package.json +3 -0
  35. package/node_modules/minipass/dist/esm/index.d.ts +545 -0
  36. package/node_modules/minipass/dist/esm/index.d.ts.map +1 -0
  37. package/node_modules/minipass/dist/esm/index.js +1020 -0
  38. package/node_modules/minipass/dist/esm/index.js.map +1 -0
  39. package/node_modules/minipass/dist/esm/package.json +3 -0
  40. package/node_modules/minipass/package.json +77 -0
  41. package/node_modules/minizlib/LICENSE +26 -0
  42. package/node_modules/minizlib/README.md +64 -0
  43. package/node_modules/minizlib/dist/commonjs/constants.d.ts +2 -0
  44. package/node_modules/minizlib/dist/commonjs/constants.d.ts.map +1 -0
  45. package/node_modules/minizlib/dist/commonjs/constants.js +123 -0
  46. package/node_modules/minizlib/dist/commonjs/constants.js.map +1 -0
  47. package/node_modules/minizlib/dist/commonjs/index.d.ts +99 -0
  48. package/node_modules/minizlib/dist/commonjs/index.d.ts.map +1 -0
  49. package/node_modules/minizlib/dist/commonjs/index.js +416 -0
  50. package/node_modules/minizlib/dist/commonjs/index.js.map +1 -0
  51. package/node_modules/minizlib/dist/commonjs/package.json +3 -0
  52. package/node_modules/minizlib/dist/esm/constants.d.ts +2 -0
  53. package/node_modules/minizlib/dist/esm/constants.d.ts.map +1 -0
  54. package/node_modules/minizlib/dist/esm/constants.js +117 -0
  55. package/node_modules/minizlib/dist/esm/constants.js.map +1 -0
  56. package/node_modules/minizlib/dist/esm/index.d.ts +99 -0
  57. package/node_modules/minizlib/dist/esm/index.d.ts.map +1 -0
  58. package/node_modules/minizlib/dist/esm/index.js +363 -0
  59. package/node_modules/minizlib/dist/esm/index.js.map +1 -0
  60. package/node_modules/minizlib/dist/esm/package.json +3 -0
  61. package/node_modules/minizlib/package.json +80 -0
  62. package/node_modules/tar/LICENSE.md +55 -0
  63. package/node_modules/tar/README.md +1224 -0
  64. package/node_modules/tar/dist/commonjs/create.d.ts +3 -0
  65. package/node_modules/tar/dist/commonjs/create.d.ts.map +1 -0
  66. package/node_modules/tar/dist/commonjs/create.js +82 -0
  67. package/node_modules/tar/dist/commonjs/create.js.map +1 -0
  68. package/node_modules/tar/dist/commonjs/cwd-error.d.ts +8 -0
  69. package/node_modules/tar/dist/commonjs/cwd-error.d.ts.map +1 -0
  70. package/node_modules/tar/dist/commonjs/cwd-error.js +18 -0
  71. package/node_modules/tar/dist/commonjs/cwd-error.js.map +1 -0
  72. package/node_modules/tar/dist/commonjs/extract.d.ts +3 -0
  73. package/node_modules/tar/dist/commonjs/extract.d.ts.map +1 -0
  74. package/node_modules/tar/dist/commonjs/extract.js +88 -0
  75. package/node_modules/tar/dist/commonjs/extract.js.map +1 -0
  76. package/node_modules/tar/dist/commonjs/get-write-flag.d.ts +2 -0
  77. package/node_modules/tar/dist/commonjs/get-write-flag.d.ts.map +1 -0
  78. package/node_modules/tar/dist/commonjs/get-write-flag.js +32 -0
  79. package/node_modules/tar/dist/commonjs/get-write-flag.js.map +1 -0
  80. package/node_modules/tar/dist/commonjs/header.d.ts +53 -0
  81. package/node_modules/tar/dist/commonjs/header.d.ts.map +1 -0
  82. package/node_modules/tar/dist/commonjs/header.js +312 -0
  83. package/node_modules/tar/dist/commonjs/header.js.map +1 -0
  84. package/node_modules/tar/dist/commonjs/index.d.ts +20 -0
  85. package/node_modules/tar/dist/commonjs/index.d.ts.map +1 -0
  86. package/node_modules/tar/dist/commonjs/index.js +64 -0
  87. package/node_modules/tar/dist/commonjs/index.js.map +1 -0
  88. package/node_modules/tar/dist/commonjs/index.min.js +4 -0
  89. package/node_modules/tar/dist/commonjs/index.min.js.map +7 -0
  90. package/node_modules/tar/dist/commonjs/large-numbers.d.ts +3 -0
  91. package/node_modules/tar/dist/commonjs/large-numbers.d.ts.map +1 -0
  92. package/node_modules/tar/dist/commonjs/large-numbers.js +99 -0
  93. package/node_modules/tar/dist/commonjs/large-numbers.js.map +1 -0
  94. package/node_modules/tar/dist/commonjs/list.d.ts +7 -0
  95. package/node_modules/tar/dist/commonjs/list.d.ts.map +1 -0
  96. package/node_modules/tar/dist/commonjs/list.js +145 -0
  97. package/node_modules/tar/dist/commonjs/list.js.map +1 -0
  98. package/node_modules/tar/dist/commonjs/make-command.d.ts +49 -0
  99. package/node_modules/tar/dist/commonjs/make-command.d.ts.map +1 -0
  100. package/node_modules/tar/dist/commonjs/make-command.js +52 -0
  101. package/node_modules/tar/dist/commonjs/make-command.js.map +1 -0
  102. package/node_modules/tar/dist/commonjs/mkdir.d.ts +25 -0
  103. package/node_modules/tar/dist/commonjs/mkdir.d.ts.map +1 -0
  104. package/node_modules/tar/dist/commonjs/mkdir.js +187 -0
  105. package/node_modules/tar/dist/commonjs/mkdir.js.map +1 -0
  106. package/node_modules/tar/dist/commonjs/mode-fix.d.ts +2 -0
  107. package/node_modules/tar/dist/commonjs/mode-fix.d.ts.map +1 -0
  108. package/node_modules/tar/dist/commonjs/mode-fix.js +29 -0
  109. package/node_modules/tar/dist/commonjs/mode-fix.js.map +1 -0
  110. package/node_modules/tar/dist/commonjs/normalize-unicode.d.ts +2 -0
  111. package/node_modules/tar/dist/commonjs/normalize-unicode.d.ts.map +1 -0
  112. package/node_modules/tar/dist/commonjs/normalize-unicode.js +38 -0
  113. package/node_modules/tar/dist/commonjs/normalize-unicode.js.map +1 -0
  114. package/node_modules/tar/dist/commonjs/normalize-windows-path.d.ts +2 -0
  115. package/node_modules/tar/dist/commonjs/normalize-windows-path.d.ts.map +1 -0
  116. package/node_modules/tar/dist/commonjs/normalize-windows-path.js +12 -0
  117. package/node_modules/tar/dist/commonjs/normalize-windows-path.js.map +1 -0
  118. package/node_modules/tar/dist/commonjs/options.d.ts +596 -0
  119. package/node_modules/tar/dist/commonjs/options.d.ts.map +1 -0
  120. package/node_modules/tar/dist/commonjs/options.js +66 -0
  121. package/node_modules/tar/dist/commonjs/options.js.map +1 -0
  122. package/node_modules/tar/dist/commonjs/pack.d.ts +102 -0
  123. package/node_modules/tar/dist/commonjs/pack.d.ts.map +1 -0
  124. package/node_modules/tar/dist/commonjs/pack.js +511 -0
  125. package/node_modules/tar/dist/commonjs/pack.js.map +1 -0
  126. package/node_modules/tar/dist/commonjs/package.json +3 -0
  127. package/node_modules/tar/dist/commonjs/parse.d.ts +85 -0
  128. package/node_modules/tar/dist/commonjs/parse.d.ts.map +1 -0
  129. package/node_modules/tar/dist/commonjs/parse.js +610 -0
  130. package/node_modules/tar/dist/commonjs/parse.js.map +1 -0
  131. package/node_modules/tar/dist/commonjs/path-reservations.d.ts +11 -0
  132. package/node_modules/tar/dist/commonjs/path-reservations.d.ts.map +1 -0
  133. package/node_modules/tar/dist/commonjs/path-reservations.js +170 -0
  134. package/node_modules/tar/dist/commonjs/path-reservations.js.map +1 -0
  135. package/node_modules/tar/dist/commonjs/pax.d.ts +26 -0
  136. package/node_modules/tar/dist/commonjs/pax.d.ts.map +1 -0
  137. package/node_modules/tar/dist/commonjs/pax.js +158 -0
  138. package/node_modules/tar/dist/commonjs/pax.js.map +1 -0
  139. package/node_modules/tar/dist/commonjs/process-umask.d.ts +2 -0
  140. package/node_modules/tar/dist/commonjs/process-umask.d.ts.map +1 -0
  141. package/node_modules/tar/dist/commonjs/process-umask.js +7 -0
  142. package/node_modules/tar/dist/commonjs/process-umask.js.map +1 -0
  143. package/node_modules/tar/dist/commonjs/read-entry.d.ts +36 -0
  144. package/node_modules/tar/dist/commonjs/read-entry.d.ts.map +1 -0
  145. package/node_modules/tar/dist/commonjs/read-entry.js +136 -0
  146. package/node_modules/tar/dist/commonjs/read-entry.js.map +1 -0
  147. package/node_modules/tar/dist/commonjs/replace.d.ts +2 -0
  148. package/node_modules/tar/dist/commonjs/replace.d.ts.map +1 -0
  149. package/node_modules/tar/dist/commonjs/replace.js +227 -0
  150. package/node_modules/tar/dist/commonjs/replace.js.map +1 -0
  151. package/node_modules/tar/dist/commonjs/strip-absolute-path.d.ts +2 -0
  152. package/node_modules/tar/dist/commonjs/strip-absolute-path.d.ts.map +1 -0
  153. package/node_modules/tar/dist/commonjs/strip-absolute-path.js +29 -0
  154. package/node_modules/tar/dist/commonjs/strip-absolute-path.js.map +1 -0
  155. package/node_modules/tar/dist/commonjs/strip-trailing-slashes.d.ts +2 -0
  156. package/node_modules/tar/dist/commonjs/strip-trailing-slashes.d.ts.map +1 -0
  157. package/node_modules/tar/dist/commonjs/strip-trailing-slashes.js +18 -0
  158. package/node_modules/tar/dist/commonjs/strip-trailing-slashes.js.map +1 -0
  159. package/node_modules/tar/dist/commonjs/symlink-error.d.ts +9 -0
  160. package/node_modules/tar/dist/commonjs/symlink-error.d.ts.map +1 -0
  161. package/node_modules/tar/dist/commonjs/symlink-error.js +19 -0
  162. package/node_modules/tar/dist/commonjs/symlink-error.js.map +1 -0
  163. package/node_modules/tar/dist/commonjs/types.d.ts +7 -0
  164. package/node_modules/tar/dist/commonjs/types.d.ts.map +1 -0
  165. package/node_modules/tar/dist/commonjs/types.js +50 -0
  166. package/node_modules/tar/dist/commonjs/types.js.map +1 -0
  167. package/node_modules/tar/dist/commonjs/unpack.d.ts +101 -0
  168. package/node_modules/tar/dist/commonjs/unpack.d.ts.map +1 -0
  169. package/node_modules/tar/dist/commonjs/unpack.js +932 -0
  170. package/node_modules/tar/dist/commonjs/unpack.js.map +1 -0
  171. package/node_modules/tar/dist/commonjs/update.d.ts +2 -0
  172. package/node_modules/tar/dist/commonjs/update.d.ts.map +1 -0
  173. package/node_modules/tar/dist/commonjs/update.js +33 -0
  174. package/node_modules/tar/dist/commonjs/update.js.map +1 -0
  175. package/node_modules/tar/dist/commonjs/warn-method.d.ts +24 -0
  176. package/node_modules/tar/dist/commonjs/warn-method.d.ts.map +1 -0
  177. package/node_modules/tar/dist/commonjs/warn-method.js +31 -0
  178. package/node_modules/tar/dist/commonjs/warn-method.js.map +1 -0
  179. package/node_modules/tar/dist/commonjs/winchars.d.ts +3 -0
  180. package/node_modules/tar/dist/commonjs/winchars.d.ts.map +1 -0
  181. package/node_modules/tar/dist/commonjs/winchars.js +14 -0
  182. package/node_modules/tar/dist/commonjs/winchars.js.map +1 -0
  183. package/node_modules/tar/dist/commonjs/write-entry.d.ts +129 -0
  184. package/node_modules/tar/dist/commonjs/write-entry.d.ts.map +1 -0
  185. package/node_modules/tar/dist/commonjs/write-entry.js +698 -0
  186. package/node_modules/tar/dist/commonjs/write-entry.js.map +1 -0
  187. package/node_modules/tar/dist/esm/create.d.ts +3 -0
  188. package/node_modules/tar/dist/esm/create.d.ts.map +1 -0
  189. package/node_modules/tar/dist/esm/create.js +76 -0
  190. package/node_modules/tar/dist/esm/create.js.map +1 -0
  191. package/node_modules/tar/dist/esm/cwd-error.d.ts +8 -0
  192. package/node_modules/tar/dist/esm/cwd-error.d.ts.map +1 -0
  193. package/node_modules/tar/dist/esm/cwd-error.js +14 -0
  194. package/node_modules/tar/dist/esm/cwd-error.js.map +1 -0
  195. package/node_modules/tar/dist/esm/extract.d.ts +3 -0
  196. package/node_modules/tar/dist/esm/extract.d.ts.map +1 -0
  197. package/node_modules/tar/dist/esm/extract.js +49 -0
  198. package/node_modules/tar/dist/esm/extract.js.map +1 -0
  199. package/node_modules/tar/dist/esm/get-write-flag.d.ts +2 -0
  200. package/node_modules/tar/dist/esm/get-write-flag.d.ts.map +1 -0
  201. package/node_modules/tar/dist/esm/get-write-flag.js +26 -0
  202. package/node_modules/tar/dist/esm/get-write-flag.js.map +1 -0
  203. package/node_modules/tar/dist/esm/header.d.ts +53 -0
  204. package/node_modules/tar/dist/esm/header.d.ts.map +1 -0
  205. package/node_modules/tar/dist/esm/header.js +275 -0
  206. package/node_modules/tar/dist/esm/header.js.map +1 -0
  207. package/node_modules/tar/dist/esm/index.d.ts +20 -0
  208. package/node_modules/tar/dist/esm/index.d.ts.map +1 -0
  209. package/node_modules/tar/dist/esm/index.js +20 -0
  210. package/node_modules/tar/dist/esm/index.js.map +1 -0
  211. package/node_modules/tar/dist/esm/index.min.js +4 -0
  212. package/node_modules/tar/dist/esm/index.min.js.map +7 -0
  213. package/node_modules/tar/dist/esm/large-numbers.d.ts +3 -0
  214. package/node_modules/tar/dist/esm/large-numbers.d.ts.map +1 -0
  215. package/node_modules/tar/dist/esm/large-numbers.js +94 -0
  216. package/node_modules/tar/dist/esm/large-numbers.js.map +1 -0
  217. package/node_modules/tar/dist/esm/list.d.ts +7 -0
  218. package/node_modules/tar/dist/esm/list.d.ts.map +1 -0
  219. package/node_modules/tar/dist/esm/list.js +105 -0
  220. package/node_modules/tar/dist/esm/list.js.map +1 -0
  221. package/node_modules/tar/dist/esm/make-command.d.ts +49 -0
  222. package/node_modules/tar/dist/esm/make-command.d.ts.map +1 -0
  223. package/node_modules/tar/dist/esm/make-command.js +48 -0
  224. package/node_modules/tar/dist/esm/make-command.js.map +1 -0
  225. package/node_modules/tar/dist/esm/mkdir.d.ts +25 -0
  226. package/node_modules/tar/dist/esm/mkdir.d.ts.map +1 -0
  227. package/node_modules/tar/dist/esm/mkdir.js +179 -0
  228. package/node_modules/tar/dist/esm/mkdir.js.map +1 -0
  229. package/node_modules/tar/dist/esm/mode-fix.d.ts +2 -0
  230. package/node_modules/tar/dist/esm/mode-fix.d.ts.map +1 -0
  231. package/node_modules/tar/dist/esm/mode-fix.js +25 -0
  232. package/node_modules/tar/dist/esm/mode-fix.js.map +1 -0
  233. package/node_modules/tar/dist/esm/normalize-unicode.d.ts +2 -0
  234. package/node_modules/tar/dist/esm/normalize-unicode.d.ts.map +1 -0
  235. package/node_modules/tar/dist/esm/normalize-unicode.js +34 -0
  236. package/node_modules/tar/dist/esm/normalize-unicode.js.map +1 -0
  237. package/node_modules/tar/dist/esm/normalize-windows-path.d.ts +2 -0
  238. package/node_modules/tar/dist/esm/normalize-windows-path.d.ts.map +1 -0
  239. package/node_modules/tar/dist/esm/normalize-windows-path.js +9 -0
  240. package/node_modules/tar/dist/esm/normalize-windows-path.js.map +1 -0
  241. package/node_modules/tar/dist/esm/options.d.ts +596 -0
  242. package/node_modules/tar/dist/esm/options.d.ts.map +1 -0
  243. package/node_modules/tar/dist/esm/options.js +54 -0
  244. package/node_modules/tar/dist/esm/options.js.map +1 -0
  245. package/node_modules/tar/dist/esm/pack.d.ts +102 -0
  246. package/node_modules/tar/dist/esm/pack.d.ts.map +1 -0
  247. package/node_modules/tar/dist/esm/pack.js +469 -0
  248. package/node_modules/tar/dist/esm/pack.js.map +1 -0
  249. package/node_modules/tar/dist/esm/package.json +3 -0
  250. package/node_modules/tar/dist/esm/parse.d.ts +85 -0
  251. package/node_modules/tar/dist/esm/parse.d.ts.map +1 -0
  252. package/node_modules/tar/dist/esm/parse.js +606 -0
  253. package/node_modules/tar/dist/esm/parse.js.map +1 -0
  254. package/node_modules/tar/dist/esm/path-reservations.d.ts +11 -0
  255. package/node_modules/tar/dist/esm/path-reservations.d.ts.map +1 -0
  256. package/node_modules/tar/dist/esm/path-reservations.js +166 -0
  257. package/node_modules/tar/dist/esm/path-reservations.js.map +1 -0
  258. package/node_modules/tar/dist/esm/pax.d.ts +26 -0
  259. package/node_modules/tar/dist/esm/pax.d.ts.map +1 -0
  260. package/node_modules/tar/dist/esm/pax.js +154 -0
  261. package/node_modules/tar/dist/esm/pax.js.map +1 -0
  262. package/node_modules/tar/dist/esm/process-umask.d.ts +2 -0
  263. package/node_modules/tar/dist/esm/process-umask.d.ts.map +1 -0
  264. package/node_modules/tar/dist/esm/process-umask.js +3 -0
  265. package/node_modules/tar/dist/esm/process-umask.js.map +1 -0
  266. package/node_modules/tar/dist/esm/read-entry.d.ts +36 -0
  267. package/node_modules/tar/dist/esm/read-entry.d.ts.map +1 -0
  268. package/node_modules/tar/dist/esm/read-entry.js +132 -0
  269. package/node_modules/tar/dist/esm/read-entry.js.map +1 -0
  270. package/node_modules/tar/dist/esm/replace.d.ts +2 -0
  271. package/node_modules/tar/dist/esm/replace.d.ts.map +1 -0
  272. package/node_modules/tar/dist/esm/replace.js +221 -0
  273. package/node_modules/tar/dist/esm/replace.js.map +1 -0
  274. package/node_modules/tar/dist/esm/strip-absolute-path.d.ts +2 -0
  275. package/node_modules/tar/dist/esm/strip-absolute-path.d.ts.map +1 -0
  276. package/node_modules/tar/dist/esm/strip-absolute-path.js +25 -0
  277. package/node_modules/tar/dist/esm/strip-absolute-path.js.map +1 -0
  278. package/node_modules/tar/dist/esm/strip-trailing-slashes.d.ts +2 -0
  279. package/node_modules/tar/dist/esm/strip-trailing-slashes.d.ts.map +1 -0
  280. package/node_modules/tar/dist/esm/strip-trailing-slashes.js +14 -0
  281. package/node_modules/tar/dist/esm/strip-trailing-slashes.js.map +1 -0
  282. package/node_modules/tar/dist/esm/symlink-error.d.ts +9 -0
  283. package/node_modules/tar/dist/esm/symlink-error.d.ts.map +1 -0
  284. package/node_modules/tar/dist/esm/symlink-error.js +15 -0
  285. package/node_modules/tar/dist/esm/symlink-error.js.map +1 -0
  286. package/node_modules/tar/dist/esm/types.d.ts +7 -0
  287. package/node_modules/tar/dist/esm/types.d.ts.map +1 -0
  288. package/node_modules/tar/dist/esm/types.js +45 -0
  289. package/node_modules/tar/dist/esm/types.js.map +1 -0
  290. package/node_modules/tar/dist/esm/unpack.d.ts +101 -0
  291. package/node_modules/tar/dist/esm/unpack.d.ts.map +1 -0
  292. package/node_modules/tar/dist/esm/unpack.js +891 -0
  293. package/node_modules/tar/dist/esm/unpack.js.map +1 -0
  294. package/node_modules/tar/dist/esm/update.d.ts +2 -0
  295. package/node_modules/tar/dist/esm/update.d.ts.map +1 -0
  296. package/node_modules/tar/dist/esm/update.js +30 -0
  297. package/node_modules/tar/dist/esm/update.js.map +1 -0
  298. package/node_modules/tar/dist/esm/warn-method.d.ts +24 -0
  299. package/node_modules/tar/dist/esm/warn-method.d.ts.map +1 -0
  300. package/node_modules/tar/dist/esm/warn-method.js +27 -0
  301. package/node_modules/tar/dist/esm/warn-method.js.map +1 -0
  302. package/node_modules/tar/dist/esm/winchars.d.ts +3 -0
  303. package/node_modules/tar/dist/esm/winchars.d.ts.map +1 -0
  304. package/node_modules/tar/dist/esm/winchars.js +9 -0
  305. package/node_modules/tar/dist/esm/winchars.js.map +1 -0
  306. package/node_modules/tar/dist/esm/write-entry.d.ts +129 -0
  307. package/node_modules/tar/dist/esm/write-entry.d.ts.map +1 -0
  308. package/node_modules/tar/dist/esm/write-entry.js +656 -0
  309. package/node_modules/tar/dist/esm/write-entry.js.map +1 -0
  310. package/node_modules/tar/package.json +297 -0
  311. package/node_modules/yallist/LICENSE.md +63 -0
  312. package/node_modules/yallist/README.md +205 -0
  313. package/node_modules/yallist/dist/commonjs/index.d.ts +39 -0
  314. package/node_modules/yallist/dist/commonjs/index.d.ts.map +1 -0
  315. package/node_modules/yallist/dist/commonjs/index.js +384 -0
  316. package/node_modules/yallist/dist/commonjs/index.js.map +1 -0
  317. package/node_modules/yallist/dist/commonjs/package.json +3 -0
  318. package/node_modules/yallist/dist/esm/index.d.ts +39 -0
  319. package/node_modules/yallist/dist/esm/index.d.ts.map +1 -0
  320. package/node_modules/yallist/dist/esm/index.js +379 -0
  321. package/node_modules/yallist/dist/esm/index.js.map +1 -0
  322. package/node_modules/yallist/dist/esm/package.json +3 -0
  323. package/node_modules/yallist/package.json +68 -0
  324. package/package.json +3 -1
  325. package/skills/manifest.json +12 -0
  326. package/skills/weibo-cron/SKILL.md +54 -54
  327. package/skills/weibo-cron/references/HEARTBEAT-PROCESS.md +65 -0
  328. package/skills/weibo-crowd/SKILL.md +182 -16
  329. package/skills/weibo-crowd/references/SILICON-TEAHOUSE-RULES.md +195 -62
  330. package/skills/weibo-crowd/scripts/weibo-crowd.js +105 -27
  331. package/skills/weibo-hot-search/SKILL.md +3 -1
  332. package/skills/weibo-pic/SKILL.md +266 -0
  333. package/skills/weibo-pic/scripts/weibo-pic.js +798 -0
  334. package/skills/weibo-search/SKILL.md +4 -2
  335. package/skills/weibo-status/SKILL.md +5 -3
  336. package/skills/weibo-token/SKILL.md +4 -2
  337. package/skills/weibo-video/SKILL.md +2 -0
  338. package/src/accounts.js +1 -1
  339. package/src/accounts.js.map +1 -1
  340. package/src/channel.js +2 -2
  341. package/src/channel.js.map +1 -1
  342. package/src/client.d.ts.map +1 -1
  343. package/src/client.js +3 -0
  344. package/src/client.js.map +1 -1
  345. package/src/config-schema.js +2 -2
  346. package/src/config-schema.js.map +1 -1
  347. package/src/skill-updater.d.ts +14 -0
  348. package/src/skill-updater.d.ts.map +1 -0
  349. package/src/skill-updater.js +240 -0
  350. package/src/skill-updater.js.map +1 -0
  351. package/src/token.d.ts +2 -0
  352. package/src/token.d.ts.map +1 -1
  353. package/src/token.js +2 -1
  354. package/src/token.js.map +1 -1
  355. package/src/weibo-hot-search.d.ts +2 -2
  356. package/src/weibo-hot-search.d.ts.map +1 -1
  357. package/src/weibo-hot-search.js +2 -2
  358. package/src/weibo-hot-search.js.map +1 -1
  359. package/src/weibo-search.d.ts +2 -2
  360. package/src/weibo-search.d.ts.map +1 -1
  361. package/src/weibo-search.js +2 -2
  362. package/src/weibo-search.js.map +1 -1
  363. package/src/weibo-status.js +2 -2
  364. package/src/weibo-status.js.map +1 -1
  365. package/src/weibo-token-tool.d.ts +2 -2
  366. package/src/weibo-token-tool.d.ts.map +1 -1
  367. package/src/weibo-token-tool.js +3 -3
  368. package/src/weibo-token-tool.js.map +1 -1
@@ -0,0 +1,416 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
15
+ }) : function(o, v) {
16
+ o["default"] = v;
17
+ });
18
+ var __importStar = (this && this.__importStar) || (function () {
19
+ var ownKeys = function(o) {
20
+ ownKeys = Object.getOwnPropertyNames || function (o) {
21
+ var ar = [];
22
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
23
+ return ar;
24
+ };
25
+ return ownKeys(o);
26
+ };
27
+ return function (mod) {
28
+ if (mod && mod.__esModule) return mod;
29
+ var result = {};
30
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
31
+ __setModuleDefault(result, mod);
32
+ return result;
33
+ };
34
+ })();
35
+ var __importDefault = (this && this.__importDefault) || function (mod) {
36
+ return (mod && mod.__esModule) ? mod : { "default": mod };
37
+ };
38
+ Object.defineProperty(exports, "__esModule", { value: true });
39
+ exports.ZstdDecompress = exports.ZstdCompress = exports.BrotliDecompress = exports.BrotliCompress = exports.Unzip = exports.InflateRaw = exports.DeflateRaw = exports.Gunzip = exports.Gzip = exports.Inflate = exports.Deflate = exports.Zlib = exports.ZlibError = exports.constants = void 0;
40
+ const assert_1 = __importDefault(require("assert"));
41
+ const buffer_1 = require("buffer");
42
+ const minipass_1 = require("minipass");
43
+ const realZlib = __importStar(require("zlib"));
44
+ const constants_js_1 = require("./constants.js");
45
+ var constants_js_2 = require("./constants.js");
46
+ Object.defineProperty(exports, "constants", { enumerable: true, get: function () { return constants_js_2.constants; } });
47
+ const OriginalBufferConcat = buffer_1.Buffer.concat;
48
+ const desc = Object.getOwnPropertyDescriptor(buffer_1.Buffer, 'concat');
49
+ const noop = (args) => args;
50
+ const passthroughBufferConcat = desc?.writable === true || desc?.set !== undefined
51
+ ? (makeNoOp) => {
52
+ buffer_1.Buffer.concat = makeNoOp ? noop : OriginalBufferConcat;
53
+ }
54
+ : (_) => { };
55
+ const _superWrite = Symbol('_superWrite');
56
+ class ZlibError extends Error {
57
+ code;
58
+ errno;
59
+ constructor(err, origin) {
60
+ super('zlib: ' + err.message, { cause: err });
61
+ this.code = err.code;
62
+ this.errno = err.errno;
63
+ /* c8 ignore next */
64
+ if (!this.code)
65
+ this.code = 'ZLIB_ERROR';
66
+ this.message = 'zlib: ' + err.message;
67
+ Error.captureStackTrace(this, origin ?? this.constructor);
68
+ }
69
+ get name() {
70
+ return 'ZlibError';
71
+ }
72
+ }
73
+ exports.ZlibError = ZlibError;
74
+ // the Zlib class they all inherit from
75
+ // This thing manages the queue of requests, and returns
76
+ // true or false if there is anything in the queue when
77
+ // you call the .write() method.
78
+ const _flushFlag = Symbol('flushFlag');
79
+ class ZlibBase extends minipass_1.Minipass {
80
+ #sawError = false;
81
+ #ended = false;
82
+ #flushFlag;
83
+ #finishFlushFlag;
84
+ #fullFlushFlag;
85
+ #handle;
86
+ #onError;
87
+ get sawError() {
88
+ return this.#sawError;
89
+ }
90
+ get handle() {
91
+ return this.#handle;
92
+ }
93
+ /* c8 ignore start */
94
+ get flushFlag() {
95
+ return this.#flushFlag;
96
+ }
97
+ /* c8 ignore stop */
98
+ constructor(opts, mode) {
99
+ if (!opts || typeof opts !== 'object')
100
+ throw new TypeError('invalid options for ZlibBase constructor');
101
+ //@ts-ignore
102
+ super(opts);
103
+ /* c8 ignore start */
104
+ this.#flushFlag = opts.flush ?? 0;
105
+ this.#finishFlushFlag = opts.finishFlush ?? 0;
106
+ this.#fullFlushFlag = opts.fullFlushFlag ?? 0;
107
+ /* c8 ignore stop */
108
+ //@ts-ignore
109
+ if (typeof realZlib[mode] !== 'function') {
110
+ throw new TypeError('Compression method not supported: ' + mode);
111
+ }
112
+ // this will throw if any options are invalid for the class selected
113
+ try {
114
+ // @types/node doesn't know that it exports the classes, but they're there
115
+ //@ts-ignore
116
+ this.#handle = new realZlib[mode](opts);
117
+ }
118
+ catch (er) {
119
+ // make sure that all errors get decorated properly
120
+ throw new ZlibError(er, this.constructor);
121
+ }
122
+ this.#onError = err => {
123
+ // no sense raising multiple errors, since we abort on the first one.
124
+ if (this.#sawError)
125
+ return;
126
+ this.#sawError = true;
127
+ // there is no way to cleanly recover.
128
+ // continuing only obscures problems.
129
+ this.close();
130
+ this.emit('error', err);
131
+ };
132
+ this.#handle?.on('error', er => this.#onError(new ZlibError(er)));
133
+ this.once('end', () => this.close);
134
+ }
135
+ close() {
136
+ if (this.#handle) {
137
+ this.#handle.close();
138
+ this.#handle = undefined;
139
+ this.emit('close');
140
+ }
141
+ }
142
+ reset() {
143
+ if (!this.#sawError) {
144
+ (0, assert_1.default)(this.#handle, 'zlib binding closed');
145
+ //@ts-ignore
146
+ return this.#handle.reset?.();
147
+ }
148
+ }
149
+ flush(flushFlag) {
150
+ if (this.ended)
151
+ return;
152
+ if (typeof flushFlag !== 'number')
153
+ flushFlag = this.#fullFlushFlag;
154
+ this.write(Object.assign(buffer_1.Buffer.alloc(0), { [_flushFlag]: flushFlag }));
155
+ }
156
+ end(chunk, encoding, cb) {
157
+ /* c8 ignore start */
158
+ if (typeof chunk === 'function') {
159
+ cb = chunk;
160
+ encoding = undefined;
161
+ chunk = undefined;
162
+ }
163
+ if (typeof encoding === 'function') {
164
+ cb = encoding;
165
+ encoding = undefined;
166
+ }
167
+ /* c8 ignore stop */
168
+ if (chunk) {
169
+ if (encoding)
170
+ this.write(chunk, encoding);
171
+ else
172
+ this.write(chunk);
173
+ }
174
+ this.flush(this.#finishFlushFlag);
175
+ this.#ended = true;
176
+ return super.end(cb);
177
+ }
178
+ get ended() {
179
+ return this.#ended;
180
+ }
181
+ // overridden in the gzip classes to do portable writes
182
+ [_superWrite](data) {
183
+ return super.write(data);
184
+ }
185
+ write(chunk, encoding, cb) {
186
+ // process the chunk using the sync process
187
+ // then super.write() all the outputted chunks
188
+ if (typeof encoding === 'function')
189
+ (cb = encoding), (encoding = 'utf8');
190
+ if (typeof chunk === 'string')
191
+ chunk = buffer_1.Buffer.from(chunk, encoding);
192
+ if (this.#sawError)
193
+ return;
194
+ (0, assert_1.default)(this.#handle, 'zlib binding closed');
195
+ // _processChunk tries to .close() the native handle after it's done, so we
196
+ // intercept that by temporarily making it a no-op.
197
+ // diving into the node:zlib internals a bit here
198
+ const nativeHandle = this.#handle
199
+ ._handle;
200
+ const originalNativeClose = nativeHandle.close;
201
+ nativeHandle.close = () => { };
202
+ const originalClose = this.#handle.close;
203
+ this.#handle.close = () => { };
204
+ // It also calls `Buffer.concat()` at the end, which may be convenient
205
+ // for some, but which we are not interested in as it slows us down.
206
+ passthroughBufferConcat(true);
207
+ let result = undefined;
208
+ try {
209
+ const flushFlag = typeof chunk[_flushFlag] === 'number'
210
+ ? chunk[_flushFlag]
211
+ : this.#flushFlag;
212
+ result = this.#handle._processChunk(chunk, flushFlag);
213
+ // if we don't throw, reset it back how it was
214
+ passthroughBufferConcat(false);
215
+ }
216
+ catch (err) {
217
+ // or if we do, put Buffer.concat() back before we emit error
218
+ // Error events call into user code, which may call Buffer.concat()
219
+ passthroughBufferConcat(false);
220
+ this.#onError(new ZlibError(err, this.write));
221
+ }
222
+ finally {
223
+ if (this.#handle) {
224
+ // Core zlib resets `_handle` to null after attempting to close the
225
+ // native handle. Our no-op handler prevented actual closure, but we
226
+ // need to restore the `._handle` property.
227
+ ;
228
+ this.#handle._handle =
229
+ nativeHandle;
230
+ nativeHandle.close = originalNativeClose;
231
+ this.#handle.close = originalClose;
232
+ // `_processChunk()` adds an 'error' listener. If we don't remove it
233
+ // after each call, these handlers start piling up.
234
+ this.#handle.removeAllListeners('error');
235
+ // make sure OUR error listener is still attached tho
236
+ }
237
+ }
238
+ if (this.#handle)
239
+ this.#handle.on('error', er => this.#onError(new ZlibError(er, this.write)));
240
+ let writeReturn;
241
+ if (result) {
242
+ if (Array.isArray(result) && result.length > 0) {
243
+ const r = result[0];
244
+ // The first buffer is always `handle._outBuffer`, which would be
245
+ // re-used for later invocations; so, we always have to copy that one.
246
+ writeReturn = this[_superWrite](buffer_1.Buffer.from(r));
247
+ for (let i = 1; i < result.length; i++) {
248
+ writeReturn = this[_superWrite](result[i]);
249
+ }
250
+ }
251
+ else {
252
+ // either a single Buffer or an empty array
253
+ writeReturn = this[_superWrite](buffer_1.Buffer.from(result));
254
+ }
255
+ }
256
+ if (cb)
257
+ cb();
258
+ return writeReturn;
259
+ }
260
+ }
261
+ class Zlib extends ZlibBase {
262
+ #level;
263
+ #strategy;
264
+ constructor(opts, mode) {
265
+ opts = opts || {};
266
+ opts.flush = opts.flush || constants_js_1.constants.Z_NO_FLUSH;
267
+ opts.finishFlush = opts.finishFlush || constants_js_1.constants.Z_FINISH;
268
+ opts.fullFlushFlag = constants_js_1.constants.Z_FULL_FLUSH;
269
+ super(opts, mode);
270
+ this.#level = opts.level;
271
+ this.#strategy = opts.strategy;
272
+ }
273
+ params(level, strategy) {
274
+ if (this.sawError)
275
+ return;
276
+ if (!this.handle)
277
+ throw new Error('cannot switch params when binding is closed');
278
+ // no way to test this without also not supporting params at all
279
+ /* c8 ignore start */
280
+ if (!this.handle.params)
281
+ throw new Error('not supported in this implementation');
282
+ /* c8 ignore stop */
283
+ if (this.#level !== level || this.#strategy !== strategy) {
284
+ this.flush(constants_js_1.constants.Z_SYNC_FLUSH);
285
+ (0, assert_1.default)(this.handle, 'zlib binding closed');
286
+ // .params() calls .flush(), but the latter is always async in the
287
+ // core zlib. We override .flush() temporarily to intercept that and
288
+ // flush synchronously.
289
+ const origFlush = this.handle.flush;
290
+ this.handle.flush = (flushFlag, cb) => {
291
+ /* c8 ignore start */
292
+ if (typeof flushFlag === 'function') {
293
+ cb = flushFlag;
294
+ flushFlag = this.flushFlag;
295
+ }
296
+ /* c8 ignore stop */
297
+ this.flush(flushFlag);
298
+ cb?.();
299
+ };
300
+ try {
301
+ ;
302
+ this.handle.params(level, strategy);
303
+ }
304
+ finally {
305
+ this.handle.flush = origFlush;
306
+ }
307
+ /* c8 ignore start */
308
+ if (this.handle) {
309
+ this.#level = level;
310
+ this.#strategy = strategy;
311
+ }
312
+ /* c8 ignore stop */
313
+ }
314
+ }
315
+ }
316
+ exports.Zlib = Zlib;
317
+ // minimal 2-byte header
318
+ class Deflate extends Zlib {
319
+ constructor(opts) {
320
+ super(opts, 'Deflate');
321
+ }
322
+ }
323
+ exports.Deflate = Deflate;
324
+ class Inflate extends Zlib {
325
+ constructor(opts) {
326
+ super(opts, 'Inflate');
327
+ }
328
+ }
329
+ exports.Inflate = Inflate;
330
+ class Gzip extends Zlib {
331
+ #portable;
332
+ constructor(opts) {
333
+ super(opts, 'Gzip');
334
+ this.#portable = opts && !!opts.portable;
335
+ }
336
+ [_superWrite](data) {
337
+ if (!this.#portable)
338
+ return super[_superWrite](data);
339
+ // we'll always get the header emitted in one first chunk
340
+ // overwrite the OS indicator byte with 0xFF
341
+ this.#portable = false;
342
+ data[9] = 255;
343
+ return super[_superWrite](data);
344
+ }
345
+ }
346
+ exports.Gzip = Gzip;
347
+ class Gunzip extends Zlib {
348
+ constructor(opts) {
349
+ super(opts, 'Gunzip');
350
+ }
351
+ }
352
+ exports.Gunzip = Gunzip;
353
+ // raw - no header
354
+ class DeflateRaw extends Zlib {
355
+ constructor(opts) {
356
+ super(opts, 'DeflateRaw');
357
+ }
358
+ }
359
+ exports.DeflateRaw = DeflateRaw;
360
+ class InflateRaw extends Zlib {
361
+ constructor(opts) {
362
+ super(opts, 'InflateRaw');
363
+ }
364
+ }
365
+ exports.InflateRaw = InflateRaw;
366
+ // auto-detect header.
367
+ class Unzip extends Zlib {
368
+ constructor(opts) {
369
+ super(opts, 'Unzip');
370
+ }
371
+ }
372
+ exports.Unzip = Unzip;
373
+ class Brotli extends ZlibBase {
374
+ constructor(opts, mode) {
375
+ opts = opts || {};
376
+ opts.flush = opts.flush || constants_js_1.constants.BROTLI_OPERATION_PROCESS;
377
+ opts.finishFlush =
378
+ opts.finishFlush || constants_js_1.constants.BROTLI_OPERATION_FINISH;
379
+ opts.fullFlushFlag = constants_js_1.constants.BROTLI_OPERATION_FLUSH;
380
+ super(opts, mode);
381
+ }
382
+ }
383
+ class BrotliCompress extends Brotli {
384
+ constructor(opts) {
385
+ super(opts, 'BrotliCompress');
386
+ }
387
+ }
388
+ exports.BrotliCompress = BrotliCompress;
389
+ class BrotliDecompress extends Brotli {
390
+ constructor(opts) {
391
+ super(opts, 'BrotliDecompress');
392
+ }
393
+ }
394
+ exports.BrotliDecompress = BrotliDecompress;
395
+ class Zstd extends ZlibBase {
396
+ constructor(opts, mode) {
397
+ opts = opts || {};
398
+ opts.flush = opts.flush || constants_js_1.constants.ZSTD_e_continue;
399
+ opts.finishFlush = opts.finishFlush || constants_js_1.constants.ZSTD_e_end;
400
+ opts.fullFlushFlag = constants_js_1.constants.ZSTD_e_flush;
401
+ super(opts, mode);
402
+ }
403
+ }
404
+ class ZstdCompress extends Zstd {
405
+ constructor(opts) {
406
+ super(opts, 'ZstdCompress');
407
+ }
408
+ }
409
+ exports.ZstdCompress = ZstdCompress;
410
+ class ZstdDecompress extends Zstd {
411
+ constructor(opts) {
412
+ super(opts, 'ZstdDecompress');
413
+ }
414
+ }
415
+ exports.ZstdDecompress = ZstdDecompress;
416
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,oDAA2B;AAC3B,mCAA+B;AAC/B,uCAAmC;AACnC,+CAAgC;AAChC,iDAA0C;AAC1C,+CAA0C;AAAjC,yGAAA,SAAS,OAAA;AAElB,MAAM,oBAAoB,GAAG,eAAM,CAAC,MAAM,CAAA;AAC1C,MAAM,IAAI,GAAG,MAAM,CAAC,wBAAwB,CAAC,eAAM,EAAE,QAAQ,CAAC,CAAA;AAC9D,MAAM,IAAI,GAAG,CAAC,IAAc,EAAE,EAAE,CAAC,IAAyB,CAAA;AAC1D,MAA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IACxC,YAAY,IAAiB;QAC3B,KAAK,CAAC,IAAI,EAAE,gBAAgB,CAAC,CAAA;IAC/B,CAAC;CACF;AAJD,wCAIC;AAED,MAAa,gBAAiB,SAAQ,MAAM;IAC1C,YAAY,IAAiB;QAC3B,KAAK,CAAC,IAAI,EAAE,kBAAkB,CAAC,CAAA;IACjC,CAAC;CACF;AAJD,4CAIC;AAED,MAAM,IAAK,SAAQ,QAAQ;IACzB,YAAY,IAAiB,EAAE,IAAc;QAC3C,IAAI,GAAG,IAAI,IAAI,EAAE,CAAA;QAEjB,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC,KAAK,IAAI,wBAAS,CAAC,eAAe,CAAA;QACpD,IAAI,CAAC,WAAW,GAAG,IAAI,CAAC,WAAW,IAAI,wBAAS,CAAC,UAAU,CAAA;QAC3D,IAAI,CAAC,aAAa,GAAG,wBAAS,CAAC,YAAY,CAAA;QAC3C,KAAK,CAAC,IAAI,EAAE,IAAI,CAAC,CAAA;IACnB,CAAC;CACF;AAED,MAAa,YAAa,SAAQ,IAAI;IACpC,YAAY,IAAiB;QAC3B,KAAK,CAAC,IAAI,EAAE,cAAc,CAAC,CAAA;IAC7B,CAAC;CACF;AAJD,oCAIC;AAED,MAAa,cAAe,SAAQ,IAAI;IACtC,YAAY,IAAiB;QAC3B,KAAK,CAAC,IAAI,EAAE,gBAAgB,CAAC,CAAA;IAC/B,CAAC;CACF;AAJD,wCAIC","sourcesContent":["import assert from 'assert'\nimport { Buffer } from 'buffer'\nimport { Minipass } from 'minipass'\nimport * as realZlib from 'zlib'\nimport { constants } from './constants.js'\nexport { constants } from './constants.js'\n\nconst OriginalBufferConcat = Buffer.concat\nconst desc = Object.getOwnPropertyDescriptor(Buffer, 'concat')\nconst noop = (args: Buffer[]) => args as unknown as Buffer\nconst passthroughBufferConcat =\n desc?.writable === true || desc?.set !== undefined\n ? (makeNoOp: boolean) => {\n Buffer.concat = makeNoOp ? noop : OriginalBufferConcat\n }\n : (_: boolean) => {}\n\nconst _superWrite = Symbol('_superWrite')\n\nexport class ZlibError extends Error {\n code?: string\n errno?: number\n constructor(err: NodeJS.ErrnoException | Error, origin?: Function) {\n super('zlib: ' + err.message, { cause: err })\n this.code = (err as NodeJS.ErrnoException).code\n this.errno = (err as NodeJS.ErrnoException).errno\n /* c8 ignore next */\n if (!this.code) this.code = 'ZLIB_ERROR'\n\n this.message = 'zlib: ' + err.message\n Error.captureStackTrace(this, origin ?? this.constructor)\n }\n\n get name() {\n return 'ZlibError'\n }\n}\n\n// the Zlib class they all inherit from\n// This thing manages the queue of requests, and returns\n// true or false if there is anything in the queue when\n// you call the .write() method.\nconst _flushFlag = Symbol('flushFlag')\n\nexport type ChunkWithFlushFlag = Minipass.ContiguousData & {\n [_flushFlag]?: number\n}\n\nexport type ZlibBaseOptions = Minipass.Options<Minipass.ContiguousData> & {\n flush?: number\n finishFlush?: number\n fullFlushFlag?: number\n}\n\nexport type ZlibHandle =\n | realZlib.Gzip\n | realZlib.Gunzip\n | realZlib.Deflate\n | realZlib.Inflate\n | realZlib.DeflateRaw\n | realZlib.InflateRaw\n | realZlib.BrotliCompress\n | realZlib.BrotliDecompress\n | realZlib.ZstdCompress\n | realZlib.ZstdDecompress\nexport type ZlibMode =\n | 'Gzip'\n | 'Gunzip'\n | 'Deflate'\n | 'Inflate'\n | 'DeflateRaw'\n | 'InflateRaw'\n | 'Unzip'\nexport type BrotliMode = 'BrotliCompress' | 'BrotliDecompress'\nexport type ZstdMode = 'ZstdCompress' | 'ZstdDecompress'\n\nabstract class ZlibBase extends Minipass<Buffer, ChunkWithFlushFlag> {\n #sawError: boolean = false\n #ended: boolean = false\n #flushFlag: number\n #finishFlushFlag: number\n #fullFlushFlag: number\n #handle?: ZlibHandle\n #onError: (err: ZlibError) => any\n\n get sawError() {\n return this.#sawError\n }\n get handle() {\n return this.#handle\n }\n /* c8 ignore start */\n get flushFlag() {\n return this.#flushFlag\n }\n /* c8 ignore stop */\n\n constructor(opts: ZlibBaseOptions, mode: ZlibMode | BrotliMode | ZstdMode) {\n if (!opts || typeof opts !== 'object')\n throw new TypeError('invalid options for ZlibBase constructor')\n\n //@ts-ignore\n super(opts)\n\n /* c8 ignore start */\n this.#flushFlag = opts.flush ?? 0\n this.#finishFlushFlag = opts.finishFlush ?? 0\n this.#fullFlushFlag = opts.fullFlushFlag ?? 0\n /* c8 ignore stop */\n\n //@ts-ignore\n if (typeof realZlib[mode] !== 'function') {\n throw new TypeError('Compression method not supported: ' + mode)\n }\n\n // this will throw if any options are invalid for the class selected\n try {\n // @types/node doesn't know that it exports the classes, but they're there\n //@ts-ignore\n this.#handle = new realZlib[mode](opts)\n } catch (er) {\n // make sure that all errors get decorated properly\n throw new ZlibError(er as NodeJS.ErrnoException, this.constructor)\n }\n\n this.#onError = err => {\n // no sense raising multiple errors, since we abort on the first one.\n if (this.#sawError) return\n\n this.#sawError = true\n\n // there is no way to cleanly recover.\n // continuing only obscures problems.\n this.close()\n this.emit('error', err)\n }\n\n this.#handle?.on('error', er => this.#onError(new ZlibError(er)))\n this.once('end', () => this.close)\n }\n\n close() {\n if (this.#handle) {\n this.#handle.close()\n this.#handle = undefined\n this.emit('close')\n }\n }\n\n reset() {\n if (!this.#sawError) {\n assert(this.#handle, 'zlib binding closed')\n //@ts-ignore\n return this.#handle.reset?.()\n }\n }\n\n flush(flushFlag?: number) {\n if (this.ended) return\n\n if (typeof flushFlag !== 'number') flushFlag = this.#fullFlushFlag\n\n this.write(Object.assign(Buffer.alloc(0), { [_flushFlag]: flushFlag }))\n }\n\n end(cb?: () => void): this\n end(chunk: ChunkWithFlushFlag, cb?: () => void): this\n end(\n chunk: ChunkWithFlushFlag,\n encoding?: Minipass.Encoding,\n cb?: () => void,\n ): this\n end(\n chunk?: ChunkWithFlushFlag | (() => void),\n encoding?: Minipass.Encoding | (() => void),\n cb?: () => void,\n ) {\n /* c8 ignore start */\n if (typeof chunk === 'function') {\n cb = chunk\n encoding = undefined\n chunk = undefined\n }\n if (typeof encoding === 'function') {\n cb = encoding\n encoding = undefined\n }\n /* c8 ignore stop */\n if (chunk) {\n if (encoding) this.write(chunk, encoding)\n else this.write(chunk)\n }\n this.flush(this.#finishFlushFlag)\n this.#ended = true\n return super.end(cb)\n }\n\n get ended() {\n return this.#ended\n }\n\n // overridden in the gzip classes to do portable writes\n [_superWrite](data: Buffer & { [_flushFlag]?: number }) {\n return super.write(data)\n }\n\n write(chunk: ChunkWithFlushFlag, cb?: () => void): boolean\n write(\n chunk: ChunkWithFlushFlag,\n encoding?: Minipass.Encoding,\n cb?: () => void,\n ): boolean\n write(\n chunk: ChunkWithFlushFlag,\n encoding?: Minipass.Encoding | (() => void),\n cb?: () => void,\n ) {\n // process the chunk using the sync process\n // then super.write() all the outputted chunks\n if (typeof encoding === 'function')\n (cb = encoding), (encoding = 'utf8')\n\n if (typeof chunk === 'string')\n chunk = Buffer.from(chunk as string, encoding as BufferEncoding)\n\n if (this.#sawError) return\n assert(this.#handle, 'zlib binding closed')\n\n // _processChunk tries to .close() the native handle after it's done, so we\n // intercept that by temporarily making it a no-op.\n // diving into the node:zlib internals a bit here\n const nativeHandle = (this.#handle as unknown as { _handle: any })\n ._handle\n const originalNativeClose = nativeHandle.close\n nativeHandle.close = () => {}\n const originalClose = this.#handle.close\n this.#handle.close = () => {}\n // It also calls `Buffer.concat()` at the end, which may be convenient\n // for some, but which we are not interested in as it slows us down.\n passthroughBufferConcat(true)\n let result: undefined | Buffer | Buffer[] = undefined\n try {\n const flushFlag =\n typeof chunk[_flushFlag] === 'number'\n ? chunk[_flushFlag]\n : this.#flushFlag\n result = (\n this.#handle as unknown as {\n _processChunk: (chunk: Buffer, flushFlag: number) => Buffer[]\n }\n )._processChunk(chunk as Buffer, flushFlag)\n // if we don't throw, reset it back how it was\n passthroughBufferConcat(false)\n } catch (err) {\n // or if we do, put Buffer.concat() back before we emit error\n // Error events call into user code, which may call Buffer.concat()\n passthroughBufferConcat(false)\n this.#onError(new ZlibError(err as NodeJS.ErrnoException, this.write))\n } finally {\n if (this.#handle) {\n // Core zlib resets `_handle` to null after attempting to close the\n // native handle. Our no-op handler prevented actual closure, but we\n // need to restore the `._handle` property.\n ;(this.#handle as unknown as { _handle: any })._handle =\n nativeHandle\n nativeHandle.close = originalNativeClose\n this.#handle.close = originalClose\n // `_processChunk()` adds an 'error' listener. If we don't remove it\n // after each call, these handlers start piling up.\n this.#handle.removeAllListeners('error')\n // make sure OUR error listener is still attached tho\n }\n }\n\n if (this.#handle)\n this.#handle.on('error', er => this.#onError(new ZlibError(er, this.write)))\n\n let writeReturn\n if (result) {\n if (Array.isArray(result) && result.length > 0) {\n const r = result[0]\n // The first buffer is always `handle._outBuffer`, which would be\n // re-used for later invocations; so, we always have to copy that one.\n writeReturn = this[_superWrite](Buffer.from(r as Buffer))\n for (let i = 1; i < result.length; i++) {\n writeReturn = this[_superWrite](result[i] as Buffer)\n }\n } else {\n // either a single Buffer or an empty array\n writeReturn = this[_superWrite](Buffer.from(result as Buffer | []))\n }\n }\n\n if (cb) cb()\n return writeReturn\n }\n}\n\nexport type ZlibOptions = ZlibBaseOptions & {\n level?: number\n strategy?: number\n}\n\nexport class Zlib extends ZlibBase {\n #level?: number\n #strategy?: number\n\n constructor(opts: ZlibOptions, mode: ZlibMode) {\n opts = opts || {}\n\n opts.flush = opts.flush || constants.Z_NO_FLUSH\n opts.finishFlush = opts.finishFlush || constants.Z_FINISH\n opts.fullFlushFlag = constants.Z_FULL_FLUSH\n super(opts, mode)\n\n this.#level = opts.level\n this.#strategy = opts.strategy\n }\n\n params(level: number, strategy: number) {\n if (this.sawError) return\n\n if (!this.handle)\n throw new Error('cannot switch params when binding is closed')\n\n // no way to test this without also not supporting params at all\n /* c8 ignore start */\n if (!(this.handle as { params?: any }).params)\n throw new Error('not supported in this implementation')\n /* c8 ignore stop */\n\n if (this.#level !== level || this.#strategy !== strategy) {\n this.flush(constants.Z_SYNC_FLUSH)\n assert(this.handle, 'zlib binding closed')\n // .params() calls .flush(), but the latter is always async in the\n // core zlib. We override .flush() temporarily to intercept that and\n // flush synchronously.\n const origFlush = this.handle.flush\n this.handle.flush = (\n flushFlag?: (() => void) | number,\n cb?: () => void,\n ) => {\n /* c8 ignore start */\n if (typeof flushFlag === 'function') {\n cb = flushFlag\n flushFlag = this.flushFlag\n }\n /* c8 ignore stop */\n this.flush(flushFlag)\n cb?.()\n }\n try {\n ;(\n this.handle as unknown as {\n params: (level?: number, strategy?: number) => void\n }\n ).params(level, strategy)\n } finally {\n this.handle.flush = origFlush\n }\n /* c8 ignore start */\n if (this.handle) {\n this.#level = level\n this.#strategy = strategy\n }\n /* c8 ignore stop */\n }\n }\n}\n\n// minimal 2-byte header\nexport class Deflate extends Zlib {\n constructor(opts: ZlibOptions) {\n super(opts, 'Deflate')\n }\n}\n\nexport class Inflate extends Zlib {\n constructor(opts: ZlibOptions) {\n super(opts, 'Inflate')\n }\n}\n\n// gzip - bigger header, same deflate compression\nexport type GzipOptions = ZlibOptions & { portable?: boolean }\nexport class Gzip extends Zlib {\n #portable: boolean\n constructor(opts: GzipOptions) {\n super(opts, 'Gzip')\n this.#portable = opts && !!opts.portable\n }\n\n [_superWrite](data: Buffer & { [_flushFlag]?: number }) {\n if (!this.#portable) return super[_superWrite](data)\n\n // we'll always get the header emitted in one first chunk\n // overwrite the OS indicator byte with 0xFF\n this.#portable = false\n data[9] = 255\n return super[_superWrite](data)\n }\n}\n\nexport class Gunzip extends Zlib {\n constructor(opts: ZlibOptions) {\n super(opts, 'Gunzip')\n }\n}\n\n// raw - no header\nexport class DeflateRaw extends Zlib {\n constructor(opts: ZlibOptions) {\n super(opts, 'DeflateRaw')\n }\n}\n\nexport class InflateRaw extends Zlib {\n constructor(opts: ZlibOptions) {\n super(opts, 'InflateRaw')\n }\n}\n\n// auto-detect header.\nexport class Unzip extends Zlib {\n constructor(opts: ZlibOptions) {\n super(opts, 'Unzip')\n }\n}\n\nclass Brotli extends ZlibBase {\n constructor(opts: ZlibOptions, mode: BrotliMode) {\n opts = opts || {}\n\n opts.flush = opts.flush || constants.BROTLI_OPERATION_PROCESS\n opts.finishFlush =\n opts.finishFlush || constants.BROTLI_OPERATION_FINISH\n opts.fullFlushFlag = constants.BROTLI_OPERATION_FLUSH\n super(opts, mode)\n }\n}\n\nexport class BrotliCompress extends Brotli {\n constructor(opts: ZlibOptions) {\n super(opts, 'BrotliCompress')\n }\n}\n\nexport class BrotliDecompress extends Brotli {\n constructor(opts: ZlibOptions) {\n super(opts, 'BrotliDecompress')\n }\n}\n\nclass Zstd extends ZlibBase {\n constructor(opts: ZlibOptions, mode: ZstdMode) {\n opts = opts || {}\n\n opts.flush = opts.flush || constants.ZSTD_e_continue\n opts.finishFlush = opts.finishFlush || constants.ZSTD_e_end\n opts.fullFlushFlag = constants.ZSTD_e_flush\n super(opts, mode)\n }\n}\n\nexport class ZstdCompress extends Zstd {\n constructor(opts: ZlibOptions) {\n super(opts, 'ZstdCompress')\n }\n}\n\nexport class ZstdDecompress extends Zstd {\n constructor(opts: ZlibOptions) {\n super(opts, 'ZstdDecompress')\n }\n}\n"]}
@@ -0,0 +1,3 @@
1
+ {
2
+ "type": "commonjs"
3
+ }
@@ -0,0 +1,2 @@
1
+ export declare const constants: any;
2
+ //# sourceMappingURL=constants.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../src/constants.ts"],"names":[],"mappings":"AASA,eAAO,MAAM,SAAS,KAiHrB,CAAA"}
@@ -0,0 +1,117 @@
1
+ // Update with any zlib constants that are added or changed in the future.
2
+ // Node v6 didn't export this, so we just hard code the version and rely
3
+ // on all the other hard-coded values from zlib v4736. When node v6
4
+ // support drops, we can just export the realZlibConstants object.
5
+ import realZlib from 'zlib';
6
+ /* c8 ignore start */
7
+ const realZlibConstants = realZlib.constants || { ZLIB_VERNUM: 4736 };
8
+ /* c8 ignore stop */
9
+ export const constants = Object.freeze(Object.assign(Object.create(null), {
10
+ Z_NO_FLUSH: 0,
11
+ Z_PARTIAL_FLUSH: 1,
12
+ Z_SYNC_FLUSH: 2,
13
+ Z_FULL_FLUSH: 3,
14
+ Z_FINISH: 4,
15
+ Z_BLOCK: 5,
16
+ Z_OK: 0,
17
+ Z_STREAM_END: 1,
18
+ Z_NEED_DICT: 2,
19
+ Z_ERRNO: -1,
20
+ Z_STREAM_ERROR: -2,
21
+ Z_DATA_ERROR: -3,
22
+ Z_MEM_ERROR: -4,
23
+ Z_BUF_ERROR: -5,
24
+ Z_VERSION_ERROR: -6,
25
+ Z_NO_COMPRESSION: 0,
26
+ Z_BEST_SPEED: 1,
27
+ Z_BEST_COMPRESSION: 9,
28
+ Z_DEFAULT_COMPRESSION: -1,
29
+ Z_FILTERED: 1,
30
+ Z_HUFFMAN_ONLY: 2,
31
+ Z_RLE: 3,
32
+ Z_FIXED: 4,
33
+ Z_DEFAULT_STRATEGY: 0,
34
+ DEFLATE: 1,
35
+ INFLATE: 2,
36
+ GZIP: 3,
37
+ GUNZIP: 4,
38
+ DEFLATERAW: 5,
39
+ INFLATERAW: 6,
40
+ UNZIP: 7,
41
+ BROTLI_DECODE: 8,
42
+ BROTLI_ENCODE: 9,
43
+ Z_MIN_WINDOWBITS: 8,
44
+ Z_MAX_WINDOWBITS: 15,
45
+ Z_DEFAULT_WINDOWBITS: 15,
46
+ Z_MIN_CHUNK: 64,
47
+ Z_MAX_CHUNK: Infinity,
48
+ Z_DEFAULT_CHUNK: 16384,
49
+ Z_MIN_MEMLEVEL: 1,
50
+ Z_MAX_MEMLEVEL: 9,
51
+ Z_DEFAULT_MEMLEVEL: 8,
52
+ Z_MIN_LEVEL: -1,
53
+ Z_MAX_LEVEL: 9,
54
+ Z_DEFAULT_LEVEL: -1,
55
+ BROTLI_OPERATION_PROCESS: 0,
56
+ BROTLI_OPERATION_FLUSH: 1,
57
+ BROTLI_OPERATION_FINISH: 2,
58
+ BROTLI_OPERATION_EMIT_METADATA: 3,
59
+ BROTLI_MODE_GENERIC: 0,
60
+ BROTLI_MODE_TEXT: 1,
61
+ BROTLI_MODE_FONT: 2,
62
+ BROTLI_DEFAULT_MODE: 0,
63
+ BROTLI_MIN_QUALITY: 0,
64
+ BROTLI_MAX_QUALITY: 11,
65
+ BROTLI_DEFAULT_QUALITY: 11,
66
+ BROTLI_MIN_WINDOW_BITS: 10,
67
+ BROTLI_MAX_WINDOW_BITS: 24,
68
+ BROTLI_LARGE_MAX_WINDOW_BITS: 30,
69
+ BROTLI_DEFAULT_WINDOW: 22,
70
+ BROTLI_MIN_INPUT_BLOCK_BITS: 16,
71
+ BROTLI_MAX_INPUT_BLOCK_BITS: 24,
72
+ BROTLI_PARAM_MODE: 0,
73
+ BROTLI_PARAM_QUALITY: 1,
74
+ BROTLI_PARAM_LGWIN: 2,
75
+ BROTLI_PARAM_LGBLOCK: 3,
76
+ BROTLI_PARAM_DISABLE_LITERAL_CONTEXT_MODELING: 4,
77
+ BROTLI_PARAM_SIZE_HINT: 5,
78
+ BROTLI_PARAM_LARGE_WINDOW: 6,
79
+ BROTLI_PARAM_NPOSTFIX: 7,
80
+ BROTLI_PARAM_NDIRECT: 8,
81
+ BROTLI_DECODER_RESULT_ERROR: 0,
82
+ BROTLI_DECODER_RESULT_SUCCESS: 1,
83
+ BROTLI_DECODER_RESULT_NEEDS_MORE_INPUT: 2,
84
+ BROTLI_DECODER_RESULT_NEEDS_MORE_OUTPUT: 3,
85
+ BROTLI_DECODER_PARAM_DISABLE_RING_BUFFER_REALLOCATION: 0,
86
+ BROTLI_DECODER_PARAM_LARGE_WINDOW: 1,
87
+ BROTLI_DECODER_NO_ERROR: 0,
88
+ BROTLI_DECODER_SUCCESS: 1,
89
+ BROTLI_DECODER_NEEDS_MORE_INPUT: 2,
90
+ BROTLI_DECODER_NEEDS_MORE_OUTPUT: 3,
91
+ BROTLI_DECODER_ERROR_FORMAT_EXUBERANT_NIBBLE: -1,
92
+ BROTLI_DECODER_ERROR_FORMAT_RESERVED: -2,
93
+ BROTLI_DECODER_ERROR_FORMAT_EXUBERANT_META_NIBBLE: -3,
94
+ BROTLI_DECODER_ERROR_FORMAT_SIMPLE_HUFFMAN_ALPHABET: -4,
95
+ BROTLI_DECODER_ERROR_FORMAT_SIMPLE_HUFFMAN_SAME: -5,
96
+ BROTLI_DECODER_ERROR_FORMAT_CL_SPACE: -6,
97
+ BROTLI_DECODER_ERROR_FORMAT_HUFFMAN_SPACE: -7,
98
+ BROTLI_DECODER_ERROR_FORMAT_CONTEXT_MAP_REPEAT: -8,
99
+ BROTLI_DECODER_ERROR_FORMAT_BLOCK_LENGTH_1: -9,
100
+ BROTLI_DECODER_ERROR_FORMAT_BLOCK_LENGTH_2: -10,
101
+ BROTLI_DECODER_ERROR_FORMAT_TRANSFORM: -11,
102
+ BROTLI_DECODER_ERROR_FORMAT_DICTIONARY: -12,
103
+ BROTLI_DECODER_ERROR_FORMAT_WINDOW_BITS: -13,
104
+ BROTLI_DECODER_ERROR_FORMAT_PADDING_1: -14,
105
+ BROTLI_DECODER_ERROR_FORMAT_PADDING_2: -15,
106
+ BROTLI_DECODER_ERROR_FORMAT_DISTANCE: -16,
107
+ BROTLI_DECODER_ERROR_DICTIONARY_NOT_SET: -19,
108
+ BROTLI_DECODER_ERROR_INVALID_ARGUMENTS: -20,
109
+ BROTLI_DECODER_ERROR_ALLOC_CONTEXT_MODES: -21,
110
+ BROTLI_DECODER_ERROR_ALLOC_TREE_GROUPS: -22,
111
+ BROTLI_DECODER_ERROR_ALLOC_CONTEXT_MAP: -25,
112
+ BROTLI_DECODER_ERROR_ALLOC_RING_BUFFER_1: -26,
113
+ BROTLI_DECODER_ERROR_ALLOC_RING_BUFFER_2: -27,
114
+ BROTLI_DECODER_ERROR_ALLOC_BLOCK_TYPE_TREES: -30,
115
+ BROTLI_DECODER_ERROR_UNREACHABLE: -31,
116
+ }, realZlibConstants));
117
+ //# sourceMappingURL=constants.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"constants.js","sourceRoot":"","sources":["../../src/constants.ts"],"names":[],"mappings":"AAAA,0EAA0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AoC,EAAE,CAAC,CAAC;IACxC,iDAAiD,EAAE,CAAC,CAAC;IACrD,mDAAmD,EAAE,CAAC,CAAC;IACvD,+CAA+C,EAAE,CAAC,CAAC;IACnD,oCAAoC,EAAE,CAAC,CAAC;IACxC,yCAAyC,EAAE,CAAC,CAAC;IAC7C,8CAA8C,EAAE,CAAC,CAAC;IAClD,0CAA0C,EAAE,CAAC,CAAC;IAC9C,0CAA0C,EAAE,CAAC,EAAE;IAC/C,qCAAqC,EAAE,CAAC,EAAE;IAC1C,sCAAsC,EAAE,CAAC,EAAE;IAC3C,uCAAuC,EAAE,CAAC,EAAE;IAC5C,qCAAqC,EAAE,CAAC,EAAE;IAC1C,qCAAqC,EAAE,CAAC,EAAE;IAC1C,oCAAoC,EAAE,CAAC,EAAE;IACzC,uCAAuC,EAAE,CAAC,EAAE;IAC5C,sCAAsC,EAAE,CAAC,EAAE;IAC3C,wCAAwC,EAAE,CAAC,EAAE;IAC7C,sCAAsC,EAAE,CAAC,EAAE;IAC3C,sCAAsC,EAAE,CAAC,EAAE;IAC3C,wCAAwC,EAAE,CAAC,EAAE;IAC7C,wCAAwC,EAAE,CAAC,EAAE;IAC7C,2CAA2C,EAAE,CAAC,EAAE;IAChD,gCAAgC,EAAE,CAAC,EAAE;CACtC,EACD,iBAAiB,CAClB,CACF,CAAA","sourcesContent":["// Update with any zlib constants that are added or changed in the future.\n// Node v6 didn't export this, so we just hard code the version and rely\n// on all the other hard-coded values from zlib v4736. When node v6\n// support drops, we can just export the realZlibConstants object.\nimport realZlib from 'zlib'\n/* c8 ignore start */\nconst realZlibConstants = realZlib.constants || { ZLIB_VERNUM: 4736 }\n/* c8 ignore stop */\n\nexport const constants = Object.freeze(\n Object.assign(\n Object.create(null),\n {\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_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 Z_NO_COMPRESSION: 0,\n Z_BEST_SPEED: 1,\n Z_BEST_COMPRESSION: 9,\n Z_DEFAULT_COMPRESSION: -1,\n Z_FILTERED: 1,\n Z_HUFFMAN_ONLY: 2,\n Z_RLE: 3,\n Z_FIXED: 4,\n Z_DEFAULT_STRATEGY: 0,\n DEFLATE: 1,\n INFLATE: 2,\n GZIP: 3,\n GUNZIP: 4,\n DEFLATERAW: 5,\n INFLATERAW: 6,\n UNZIP: 7,\n BROTLI_DECODE: 8,\n BROTLI_ENCODE: 9,\n Z_MIN_WINDOWBITS: 8,\n Z_MAX_WINDOWBITS: 15,\n Z_DEFAULT_WINDOWBITS: 15,\n Z_MIN_CHUNK: 64,\n Z_MAX_CHUNK: Infinity,\n Z_DEFAULT_CHUNK: 16384,\n Z_MIN_MEMLEVEL: 1,\n Z_MAX_MEMLEVEL: 9,\n Z_DEFAULT_MEMLEVEL: 8,\n Z_MIN_LEVEL: -1,\n Z_MAX_LEVEL: 9,\n Z_DEFAULT_LEVEL: -1,\n BROTLI_OPERATION_PROCESS: 0,\n BROTLI_OPERATION_FLUSH: 1,\n BROTLI_OPERATION_FINISH: 2,\n BROTLI_OPERATION_EMIT_METADATA: 3,\n BROTLI_MODE_GENERIC: 0,\n BROTLI_MODE_TEXT: 1,\n BROTLI_MODE_FONT: 2,\n BROTLI_DEFAULT_MODE: 0,\n BROTLI_MIN_QUALITY: 0,\n BROTLI_MAX_QUALITY: 11,\n BROTLI_DEFAULT_QUALITY: 11,\n BROTLI_MIN_WINDOW_BITS: 10,\n BROTLI_MAX_WINDOW_BITS: 24,\n BROTLI_LARGE_MAX_WINDOW_BITS: 30,\n BROTLI_DEFAULT_WINDOW: 22,\n BROTLI_MIN_INPUT_BLOCK_BITS: 16,\n BROTLI_MAX_INPUT_BLOCK_BITS: 24,\n BROTLI_PARAM_MODE: 0,\n BROTLI_PARAM_QUALITY: 1,\n BROTLI_PARAM_LGWIN: 2,\n BROTLI_PARAM_LGBLOCK: 3,\n BROTLI_PARAM_DISABLE_LITERAL_CONTEXT_MODELING: 4,\n BROTLI_PARAM_SIZE_HINT: 5,\n BROTLI_PARAM_LARGE_WINDOW: 6,\n BROTLI_PARAM_NPOSTFIX: 7,\n BROTLI_PARAM_NDIRECT: 8,\n BROTLI_DECODER_RESULT_ERROR: 0,\n BROTLI_DECODER_RESULT_SUCCESS: 1,\n BROTLI_DECODER_RESULT_NEEDS_MORE_INPUT: 2,\n BROTLI_DECODER_RESULT_NEEDS_MORE_OUTPUT: 3,\n BROTLI_DECODER_PARAM_DISABLE_RING_BUFFER_REALLOCATION: 0,\n BROTLI_DECODER_PARAM_LARGE_WINDOW: 1,\n BROTLI_DECODER_NO_ERROR: 0,\n BROTLI_DECODER_SUCCESS: 1,\n BROTLI_DECODER_NEEDS_MORE_INPUT: 2,\n BROTLI_DECODER_NEEDS_MORE_OUTPUT: 3,\n BROTLI_DECODER_ERROR_FORMAT_EXUBERANT_NIBBLE: -1,\n BROTLI_DECODER_ERROR_FORMAT_RESERVED: -2,\n BROTLI_DECODER_ERROR_FORMAT_EXUBERANT_META_NIBBLE: -3,\n BROTLI_DECODER_ERROR_FORMAT_SIMPLE_HUFFMAN_ALPHABET: -4,\n BROTLI_DECODER_ERROR_FORMAT_SIMPLE_HUFFMAN_SAME: -5,\n BROTLI_DECODER_ERROR_FORMAT_CL_SPACE: -6,\n BROTLI_DECODER_ERROR_FORMAT_HUFFMAN_SPACE: -7,\n BROTLI_DECODER_ERROR_FORMAT_CONTEXT_MAP_REPEAT: -8,\n BROTLI_DECODER_ERROR_FORMAT_BLOCK_LENGTH_1: -9,\n BROTLI_DECODER_ERROR_FORMAT_BLOCK_LENGTH_2: -10,\n BROTLI_DECODER_ERROR_FORMAT_TRANSFORM: -11,\n BROTLI_DECODER_ERROR_FORMAT_DICTIONARY: -12,\n BROTLI_DECODER_ERROR_FORMAT_WINDOW_BITS: -13,\n BROTLI_DECODER_ERROR_FORMAT_PADDING_1: -14,\n BROTLI_DECODER_ERROR_FORMAT_PADDING_2: -15,\n BROTLI_DECODER_ERROR_FORMAT_DISTANCE: -16,\n BROTLI_DECODER_ERROR_DICTIONARY_NOT_SET: -19,\n BROTLI_DECODER_ERROR_INVALID_ARGUMENTS: -20,\n BROTLI_DECODER_ERROR_ALLOC_CONTEXT_MODES: -21,\n BROTLI_DECODER_ERROR_ALLOC_TREE_GROUPS: -22,\n BROTLI_DECODER_ERROR_ALLOC_CONTEXT_MAP: -25,\n BROTLI_DECODER_ERROR_ALLOC_RING_BUFFER_1: -26,\n BROTLI_DECODER_ERROR_ALLOC_RING_BUFFER_2: -27,\n BROTLI_DECODER_ERROR_ALLOC_BLOCK_TYPE_TREES: -30,\n BROTLI_DECODER_ERROR_UNREACHABLE: -31,\n },\n realZlibConstants,\n ),\n)\n"]}