@slicemachine/manager 0.0.0-alpha.dev-new-release-process.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 (902) hide show
  1. package/README.md +85 -0
  2. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/CachedKeyDecoder.cjs +68 -0
  3. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/CachedKeyDecoder.cjs.map +1 -0
  4. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/CachedKeyDecoder.js +68 -0
  5. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/CachedKeyDecoder.js.map +1 -0
  6. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/DecodeError.cjs +43 -0
  7. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/DecodeError.cjs.map +1 -0
  8. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/DecodeError.js +43 -0
  9. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/DecodeError.js.map +1 -0
  10. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/Decoder.cjs +804 -0
  11. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/Decoder.cjs.map +1 -0
  12. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/Decoder.js +804 -0
  13. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/Decoder.js.map +1 -0
  14. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/Encoder.cjs +354 -0
  15. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/Encoder.cjs.map +1 -0
  16. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/Encoder.js +354 -0
  17. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/Encoder.js.map +1 -0
  18. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/ExtData.cjs +14 -0
  19. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/ExtData.cjs.map +1 -0
  20. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/ExtData.js +14 -0
  21. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/ExtData.js.map +1 -0
  22. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/ExtensionCodec.cjs +65 -0
  23. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/ExtensionCodec.cjs.map +1 -0
  24. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/ExtensionCodec.js +65 -0
  25. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/ExtensionCodec.js.map +1 -0
  26. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/decode.cjs +14 -0
  27. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/decode.cjs.map +1 -0
  28. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/decode.js +14 -0
  29. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/decode.js.map +1 -0
  30. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/encode.cjs +13 -0
  31. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/encode.cjs.map +1 -0
  32. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/encode.js +13 -0
  33. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/encode.js.map +1 -0
  34. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/timestamp.cjs +91 -0
  35. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/timestamp.cjs.map +1 -0
  36. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/timestamp.js +91 -0
  37. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/timestamp.js.map +1 -0
  38. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/utils/int.cjs +31 -0
  39. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/utils/int.cjs.map +1 -0
  40. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/utils/int.js +31 -0
  41. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/utils/int.js.map +1 -0
  42. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/utils/prettyByte.cjs +7 -0
  43. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/utils/prettyByte.cjs.map +1 -0
  44. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/utils/prettyByte.js +7 -0
  45. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/utils/prettyByte.js.map +1 -0
  46. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/utils/typedArrays.cjs +23 -0
  47. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/utils/typedArrays.cjs.map +1 -0
  48. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/utils/typedArrays.js +23 -0
  49. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/utils/typedArrays.js.map +1 -0
  50. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/utils/utf8.cjs +132 -0
  51. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/utils/utf8.cjs.map +1 -0
  52. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/utils/utf8.js +132 -0
  53. package/dist/_node_modules/@msgpack/msgpack/dist.es5_esm/utils/utf8.js.map +1 -0
  54. package/dist/_node_modules/common-tags/es/TemplateTag/TemplateTag.cjs +135 -0
  55. package/dist/_node_modules/common-tags/es/TemplateTag/TemplateTag.cjs.map +1 -0
  56. package/dist/_node_modules/common-tags/es/TemplateTag/TemplateTag.js +136 -0
  57. package/dist/_node_modules/common-tags/es/TemplateTag/TemplateTag.js.map +1 -0
  58. package/dist/_node_modules/common-tags/es/commaLists/commaLists.cjs +7 -0
  59. package/dist/_node_modules/common-tags/es/commaLists/commaLists.cjs.map +1 -0
  60. package/dist/_node_modules/common-tags/es/commaLists/commaLists.js +6 -0
  61. package/dist/_node_modules/common-tags/es/commaLists/commaLists.js.map +1 -0
  62. package/dist/_node_modules/common-tags/es/commaListsAnd/commaListsAnd.cjs +7 -0
  63. package/dist/_node_modules/common-tags/es/commaListsAnd/commaListsAnd.cjs.map +1 -0
  64. package/dist/_node_modules/common-tags/es/commaListsAnd/commaListsAnd.js +6 -0
  65. package/dist/_node_modules/common-tags/es/commaListsAnd/commaListsAnd.js.map +1 -0
  66. package/dist/_node_modules/common-tags/es/commaListsOr/commaListsOr.cjs +7 -0
  67. package/dist/_node_modules/common-tags/es/commaListsOr/commaListsOr.cjs.map +1 -0
  68. package/dist/_node_modules/common-tags/es/commaListsOr/commaListsOr.js +6 -0
  69. package/dist/_node_modules/common-tags/es/commaListsOr/commaListsOr.js.map +1 -0
  70. package/dist/_node_modules/common-tags/es/html/html.cjs +9 -0
  71. package/dist/_node_modules/common-tags/es/html/html.cjs.map +1 -0
  72. package/dist/_node_modules/common-tags/es/html/html.js +8 -0
  73. package/dist/_node_modules/common-tags/es/html/html.js.map +1 -0
  74. package/dist/_node_modules/common-tags/es/inlineArrayTransformer/inlineArrayTransformer.cjs +32 -0
  75. package/dist/_node_modules/common-tags/es/inlineArrayTransformer/inlineArrayTransformer.cjs.map +1 -0
  76. package/dist/_node_modules/common-tags/es/inlineArrayTransformer/inlineArrayTransformer.js +33 -0
  77. package/dist/_node_modules/common-tags/es/inlineArrayTransformer/inlineArrayTransformer.js.map +1 -0
  78. package/dist/_node_modules/common-tags/es/inlineLists/inlineLists.cjs +7 -0
  79. package/dist/_node_modules/common-tags/es/inlineLists/inlineLists.cjs.map +1 -0
  80. package/dist/_node_modules/common-tags/es/inlineLists/inlineLists.js +6 -0
  81. package/dist/_node_modules/common-tags/es/inlineLists/inlineLists.js.map +1 -0
  82. package/dist/_node_modules/common-tags/es/oneLine/oneLine.cjs +6 -0
  83. package/dist/_node_modules/common-tags/es/oneLine/oneLine.cjs.map +1 -0
  84. package/dist/_node_modules/common-tags/es/oneLine/oneLine.js +5 -0
  85. package/dist/_node_modules/common-tags/es/oneLine/oneLine.js.map +1 -0
  86. package/dist/_node_modules/common-tags/es/oneLineCommaLists/oneLineCommaLists.cjs +7 -0
  87. package/dist/_node_modules/common-tags/es/oneLineCommaLists/oneLineCommaLists.cjs.map +1 -0
  88. package/dist/_node_modules/common-tags/es/oneLineCommaLists/oneLineCommaLists.js +6 -0
  89. package/dist/_node_modules/common-tags/es/oneLineCommaLists/oneLineCommaLists.js.map +1 -0
  90. package/dist/_node_modules/common-tags/es/oneLineCommaListsAnd/oneLineCommaListsAnd.cjs +7 -0
  91. package/dist/_node_modules/common-tags/es/oneLineCommaListsAnd/oneLineCommaListsAnd.cjs.map +1 -0
  92. package/dist/_node_modules/common-tags/es/oneLineCommaListsAnd/oneLineCommaListsAnd.js +6 -0
  93. package/dist/_node_modules/common-tags/es/oneLineCommaListsAnd/oneLineCommaListsAnd.js.map +1 -0
  94. package/dist/_node_modules/common-tags/es/oneLineCommaListsOr/oneLineCommaListsOr.cjs +7 -0
  95. package/dist/_node_modules/common-tags/es/oneLineCommaListsOr/oneLineCommaListsOr.cjs.map +1 -0
  96. package/dist/_node_modules/common-tags/es/oneLineCommaListsOr/oneLineCommaListsOr.js +6 -0
  97. package/dist/_node_modules/common-tags/es/oneLineCommaListsOr/oneLineCommaListsOr.js.map +1 -0
  98. package/dist/_node_modules/common-tags/es/oneLineInlineLists/oneLineInlineLists.cjs +7 -0
  99. package/dist/_node_modules/common-tags/es/oneLineInlineLists/oneLineInlineLists.cjs.map +1 -0
  100. package/dist/_node_modules/common-tags/es/oneLineInlineLists/oneLineInlineLists.js +6 -0
  101. package/dist/_node_modules/common-tags/es/oneLineInlineLists/oneLineInlineLists.js.map +1 -0
  102. package/dist/_node_modules/common-tags/es/oneLineTrim/oneLineTrim.cjs +6 -0
  103. package/dist/_node_modules/common-tags/es/oneLineTrim/oneLineTrim.cjs.map +1 -0
  104. package/dist/_node_modules/common-tags/es/oneLineTrim/oneLineTrim.js +5 -0
  105. package/dist/_node_modules/common-tags/es/oneLineTrim/oneLineTrim.js.map +1 -0
  106. package/dist/_node_modules/common-tags/es/removeNonPrintingValuesTransformer/removeNonPrintingValuesTransformer.cjs +19 -0
  107. package/dist/_node_modules/common-tags/es/removeNonPrintingValuesTransformer/removeNonPrintingValuesTransformer.cjs.map +1 -0
  108. package/dist/_node_modules/common-tags/es/removeNonPrintingValuesTransformer/removeNonPrintingValuesTransformer.js +20 -0
  109. package/dist/_node_modules/common-tags/es/removeNonPrintingValuesTransformer/removeNonPrintingValuesTransformer.js.map +1 -0
  110. package/dist/_node_modules/common-tags/es/replaceResultTransformer/replaceResultTransformer.cjs +13 -0
  111. package/dist/_node_modules/common-tags/es/replaceResultTransformer/replaceResultTransformer.cjs.map +1 -0
  112. package/dist/_node_modules/common-tags/es/replaceResultTransformer/replaceResultTransformer.js +14 -0
  113. package/dist/_node_modules/common-tags/es/replaceResultTransformer/replaceResultTransformer.js.map +1 -0
  114. package/dist/_node_modules/common-tags/es/replaceSubstitutionTransformer/replaceSubstitutionTransformer.cjs +17 -0
  115. package/dist/_node_modules/common-tags/es/replaceSubstitutionTransformer/replaceSubstitutionTransformer.cjs.map +1 -0
  116. package/dist/_node_modules/common-tags/es/replaceSubstitutionTransformer/replaceSubstitutionTransformer.js +18 -0
  117. package/dist/_node_modules/common-tags/es/replaceSubstitutionTransformer/replaceSubstitutionTransformer.js.map +1 -0
  118. package/dist/_node_modules/common-tags/es/safeHtml/safeHtml.cjs +9 -0
  119. package/dist/_node_modules/common-tags/es/safeHtml/safeHtml.cjs.map +1 -0
  120. package/dist/_node_modules/common-tags/es/safeHtml/safeHtml.js +8 -0
  121. package/dist/_node_modules/common-tags/es/safeHtml/safeHtml.js.map +1 -0
  122. package/dist/_node_modules/common-tags/es/splitStringTransformer/splitStringTransformer.cjs +17 -0
  123. package/dist/_node_modules/common-tags/es/splitStringTransformer/splitStringTransformer.cjs.map +1 -0
  124. package/dist/_node_modules/common-tags/es/splitStringTransformer/splitStringTransformer.js +18 -0
  125. package/dist/_node_modules/common-tags/es/splitStringTransformer/splitStringTransformer.js.map +1 -0
  126. package/dist/_node_modules/common-tags/es/stripIndent/stripIndent.cjs +8 -0
  127. package/dist/_node_modules/common-tags/es/stripIndent/stripIndent.cjs.map +1 -0
  128. package/dist/_node_modules/common-tags/es/stripIndent/stripIndent.js +9 -0
  129. package/dist/_node_modules/common-tags/es/stripIndent/stripIndent.js.map +1 -0
  130. package/dist/_node_modules/common-tags/es/stripIndentTransformer/stripIndentTransformer.cjs +35 -0
  131. package/dist/_node_modules/common-tags/es/stripIndentTransformer/stripIndentTransformer.cjs.map +1 -0
  132. package/dist/_node_modules/common-tags/es/stripIndentTransformer/stripIndentTransformer.js +36 -0
  133. package/dist/_node_modules/common-tags/es/stripIndentTransformer/stripIndentTransformer.js.map +1 -0
  134. package/dist/_node_modules/common-tags/es/stripIndents/stripIndents.cjs +6 -0
  135. package/dist/_node_modules/common-tags/es/stripIndents/stripIndents.cjs.map +1 -0
  136. package/dist/_node_modules/common-tags/es/stripIndents/stripIndents.js +5 -0
  137. package/dist/_node_modules/common-tags/es/stripIndents/stripIndents.js.map +1 -0
  138. package/dist/_node_modules/common-tags/es/trimResultTransformer/trimResultTransformer.cjs +21 -0
  139. package/dist/_node_modules/common-tags/es/trimResultTransformer/trimResultTransformer.cjs.map +1 -0
  140. package/dist/_node_modules/common-tags/es/trimResultTransformer/trimResultTransformer.js +22 -0
  141. package/dist/_node_modules/common-tags/es/trimResultTransformer/trimResultTransformer.js.map +1 -0
  142. package/dist/_node_modules/cross-spawn/index.cjs +30 -0
  143. package/dist/_node_modules/cross-spawn/index.cjs.map +1 -0
  144. package/dist/_node_modules/cross-spawn/index.js +31 -0
  145. package/dist/_node_modules/cross-spawn/index.js.map +1 -0
  146. package/dist/_node_modules/cross-spawn/lib/enoent.cjs +47 -0
  147. package/dist/_node_modules/cross-spawn/lib/enoent.cjs.map +1 -0
  148. package/dist/_node_modules/cross-spawn/lib/enoent.js +47 -0
  149. package/dist/_node_modules/cross-spawn/lib/enoent.js.map +1 -0
  150. package/dist/_node_modules/cross-spawn/lib/parse.cjs +64 -0
  151. package/dist/_node_modules/cross-spawn/lib/parse.cjs.map +1 -0
  152. package/dist/_node_modules/cross-spawn/lib/parse.js +64 -0
  153. package/dist/_node_modules/cross-spawn/lib/parse.js.map +1 -0
  154. package/dist/_node_modules/cross-spawn/lib/util/escape.cjs +22 -0
  155. package/dist/_node_modules/cross-spawn/lib/util/escape.cjs.map +1 -0
  156. package/dist/_node_modules/cross-spawn/lib/util/escape.js +23 -0
  157. package/dist/_node_modules/cross-spawn/lib/util/escape.js.map +1 -0
  158. package/dist/_node_modules/cross-spawn/lib/util/readShebang.cjs +21 -0
  159. package/dist/_node_modules/cross-spawn/lib/util/readShebang.cjs.map +1 -0
  160. package/dist/_node_modules/cross-spawn/lib/util/readShebang.js +21 -0
  161. package/dist/_node_modules/cross-spawn/lib/util/readShebang.js.map +1 -0
  162. package/dist/_node_modules/cross-spawn/lib/util/resolveCommand.cjs +42 -0
  163. package/dist/_node_modules/cross-spawn/lib/util/resolveCommand.cjs.map +1 -0
  164. package/dist/_node_modules/cross-spawn/lib/util/resolveCommand.js +42 -0
  165. package/dist/_node_modules/cross-spawn/lib/util/resolveCommand.js.map +1 -0
  166. package/dist/_node_modules/data-uri-to-buffer/dist/index.cjs +41 -0
  167. package/dist/_node_modules/data-uri-to-buffer/dist/index.cjs.map +1 -0
  168. package/dist/_node_modules/data-uri-to-buffer/dist/index.js +41 -0
  169. package/dist/_node_modules/data-uri-to-buffer/dist/index.js.map +1 -0
  170. package/dist/_node_modules/execa/_node_modules/get-stream/buffer-stream.cjs +43 -0
  171. package/dist/_node_modules/execa/_node_modules/get-stream/buffer-stream.cjs.map +1 -0
  172. package/dist/_node_modules/execa/_node_modules/get-stream/buffer-stream.js +43 -0
  173. package/dist/_node_modules/execa/_node_modules/get-stream/buffer-stream.js.map +1 -0
  174. package/dist/_node_modules/execa/_node_modules/get-stream/index.cjs +59 -0
  175. package/dist/_node_modules/execa/_node_modules/get-stream/index.cjs.map +1 -0
  176. package/dist/_node_modules/execa/_node_modules/get-stream/index.js +60 -0
  177. package/dist/_node_modules/execa/_node_modules/get-stream/index.js.map +1 -0
  178. package/dist/_node_modules/execa/_node_modules/human-signals/build/src/core.cjs +275 -0
  179. package/dist/_node_modules/execa/_node_modules/human-signals/build/src/core.cjs.map +1 -0
  180. package/dist/_node_modules/execa/_node_modules/human-signals/build/src/core.js +275 -0
  181. package/dist/_node_modules/execa/_node_modules/human-signals/build/src/core.js.map +1 -0
  182. package/dist/_node_modules/execa/_node_modules/human-signals/build/src/main.cjs +53 -0
  183. package/dist/_node_modules/execa/_node_modules/human-signals/build/src/main.cjs.map +1 -0
  184. package/dist/_node_modules/execa/_node_modules/human-signals/build/src/main.js +53 -0
  185. package/dist/_node_modules/execa/_node_modules/human-signals/build/src/main.js.map +1 -0
  186. package/dist/_node_modules/execa/_node_modules/human-signals/build/src/realtime.cjs +18 -0
  187. package/dist/_node_modules/execa/_node_modules/human-signals/build/src/realtime.cjs.map +1 -0
  188. package/dist/_node_modules/execa/_node_modules/human-signals/build/src/realtime.js +18 -0
  189. package/dist/_node_modules/execa/_node_modules/human-signals/build/src/realtime.js.map +1 -0
  190. package/dist/_node_modules/execa/_node_modules/human-signals/build/src/signals.cjs +27 -0
  191. package/dist/_node_modules/execa/_node_modules/human-signals/build/src/signals.cjs.map +1 -0
  192. package/dist/_node_modules/execa/_node_modules/human-signals/build/src/signals.js +27 -0
  193. package/dist/_node_modules/execa/_node_modules/human-signals/build/src/signals.js.map +1 -0
  194. package/dist/_node_modules/execa/_node_modules/is-stream/index.cjs +11 -0
  195. package/dist/_node_modules/execa/_node_modules/is-stream/index.cjs.map +1 -0
  196. package/dist/_node_modules/execa/_node_modules/is-stream/index.js +11 -0
  197. package/dist/_node_modules/execa/_node_modules/is-stream/index.js.map +1 -0
  198. package/dist/_node_modules/execa/_node_modules/mimic-fn/index.cjs +46 -0
  199. package/dist/_node_modules/execa/_node_modules/mimic-fn/index.cjs.map +1 -0
  200. package/dist/_node_modules/execa/_node_modules/mimic-fn/index.js +47 -0
  201. package/dist/_node_modules/execa/_node_modules/mimic-fn/index.js.map +1 -0
  202. package/dist/_node_modules/execa/_node_modules/npm-run-path/index.cjs +34 -0
  203. package/dist/_node_modules/execa/_node_modules/npm-run-path/index.cjs.map +1 -0
  204. package/dist/_node_modules/execa/_node_modules/npm-run-path/index.js +34 -0
  205. package/dist/_node_modules/execa/_node_modules/npm-run-path/index.js.map +1 -0
  206. package/dist/_node_modules/execa/_node_modules/onetime/index.cjs +32 -0
  207. package/dist/_node_modules/execa/_node_modules/onetime/index.cjs.map +1 -0
  208. package/dist/_node_modules/execa/_node_modules/onetime/index.js +33 -0
  209. package/dist/_node_modules/execa/_node_modules/onetime/index.js.map +1 -0
  210. package/dist/_node_modules/execa/_node_modules/path-key/index.cjs +13 -0
  211. package/dist/_node_modules/execa/_node_modules/path-key/index.cjs.map +1 -0
  212. package/dist/_node_modules/execa/_node_modules/path-key/index.js +14 -0
  213. package/dist/_node_modules/execa/_node_modules/path-key/index.js.map +1 -0
  214. package/dist/_node_modules/execa/_node_modules/strip-final-newline/index.cjs +14 -0
  215. package/dist/_node_modules/execa/_node_modules/strip-final-newline/index.cjs.map +1 -0
  216. package/dist/_node_modules/execa/_node_modules/strip-final-newline/index.js +15 -0
  217. package/dist/_node_modules/execa/_node_modules/strip-final-newline/index.js.map +1 -0
  218. package/dist/_node_modules/execa/index.cjs +147 -0
  219. package/dist/_node_modules/execa/index.cjs.map +1 -0
  220. package/dist/_node_modules/execa/index.js +147 -0
  221. package/dist/_node_modules/execa/index.js.map +1 -0
  222. package/dist/_node_modules/execa/lib/command.cjs +37 -0
  223. package/dist/_node_modules/execa/lib/command.cjs.map +1 -0
  224. package/dist/_node_modules/execa/lib/command.js +37 -0
  225. package/dist/_node_modules/execa/lib/command.js.map +1 -0
  226. package/dist/_node_modules/execa/lib/error.cjs +73 -0
  227. package/dist/_node_modules/execa/lib/error.cjs.map +1 -0
  228. package/dist/_node_modules/execa/lib/error.js +73 -0
  229. package/dist/_node_modules/execa/lib/error.js.map +1 -0
  230. package/dist/_node_modules/execa/lib/kill.cjs +80 -0
  231. package/dist/_node_modules/execa/lib/kill.cjs.map +1 -0
  232. package/dist/_node_modules/execa/lib/kill.js +80 -0
  233. package/dist/_node_modules/execa/lib/kill.js.map +1 -0
  234. package/dist/_node_modules/execa/lib/pipe.cjs +37 -0
  235. package/dist/_node_modules/execa/lib/pipe.cjs.map +1 -0
  236. package/dist/_node_modules/execa/lib/pipe.js +37 -0
  237. package/dist/_node_modules/execa/lib/pipe.js.map +1 -0
  238. package/dist/_node_modules/execa/lib/promise.cjs +30 -0
  239. package/dist/_node_modules/execa/lib/promise.cjs.map +1 -0
  240. package/dist/_node_modules/execa/lib/promise.js +30 -0
  241. package/dist/_node_modules/execa/lib/promise.js.map +1 -0
  242. package/dist/_node_modules/execa/lib/stdio.cjs +26 -0
  243. package/dist/_node_modules/execa/lib/stdio.cjs.map +1 -0
  244. package/dist/_node_modules/execa/lib/stdio.js +26 -0
  245. package/dist/_node_modules/execa/lib/stdio.js.map +1 -0
  246. package/dist/_node_modules/execa/lib/stream.cjs +81 -0
  247. package/dist/_node_modules/execa/lib/stream.cjs.map +1 -0
  248. package/dist/_node_modules/execa/lib/stream.js +81 -0
  249. package/dist/_node_modules/execa/lib/stream.js.map +1 -0
  250. package/dist/_node_modules/execa/lib/verbose.cjs +20 -0
  251. package/dist/_node_modules/execa/lib/verbose.cjs.map +1 -0
  252. package/dist/_node_modules/execa/lib/verbose.js +20 -0
  253. package/dist/_node_modules/execa/lib/verbose.js.map +1 -0
  254. package/dist/_node_modules/fetch-blob/file.cjs +61 -0
  255. package/dist/_node_modules/fetch-blob/file.cjs.map +1 -0
  256. package/dist/_node_modules/fetch-blob/file.js +61 -0
  257. package/dist/_node_modules/fetch-blob/file.js.map +1 -0
  258. package/dist/_node_modules/fetch-blob/index.cjs +223 -0
  259. package/dist/_node_modules/fetch-blob/index.cjs.map +1 -0
  260. package/dist/_node_modules/fetch-blob/index.js +223 -0
  261. package/dist/_node_modules/fetch-blob/index.js.map +1 -0
  262. package/dist/_node_modules/fetch-blob/streams.cjs +43 -0
  263. package/dist/_node_modules/fetch-blob/streams.cjs.map +1 -0
  264. package/dist/_node_modules/fetch-blob/streams.js +42 -0
  265. package/dist/_node_modules/fetch-blob/streams.js.map +1 -0
  266. package/dist/_node_modules/file-type/core.cjs +1234 -0
  267. package/dist/_node_modules/file-type/core.cjs.map +1 -0
  268. package/dist/_node_modules/file-type/core.js +1234 -0
  269. package/dist/_node_modules/file-type/core.js.map +1 -0
  270. package/dist/_node_modules/file-type/supported.cjs +308 -0
  271. package/dist/_node_modules/file-type/supported.cjs.map +1 -0
  272. package/dist/_node_modules/file-type/supported.js +308 -0
  273. package/dist/_node_modules/file-type/supported.js.map +1 -0
  274. package/dist/_node_modules/file-type/util.cjs +27 -0
  275. package/dist/_node_modules/file-type/util.cjs.map +1 -0
  276. package/dist/_node_modules/file-type/util.js +27 -0
  277. package/dist/_node_modules/file-type/util.js.map +1 -0
  278. package/dist/_node_modules/formdata-polyfill/esm.min.cjs +116 -0
  279. package/dist/_node_modules/formdata-polyfill/esm.min.cjs.map +1 -0
  280. package/dist/_node_modules/formdata-polyfill/esm.min.js +116 -0
  281. package/dist/_node_modules/formdata-polyfill/esm.min.js.map +1 -0
  282. package/dist/_node_modules/fp-ts/es6/Either.cjs +18 -0
  283. package/dist/_node_modules/fp-ts/es6/Either.cjs.map +1 -0
  284. package/dist/_node_modules/fp-ts/es6/Either.js +18 -0
  285. package/dist/_node_modules/fp-ts/es6/Either.js.map +1 -0
  286. package/dist/_node_modules/fp-ts/es6/function.cjs +44 -0
  287. package/dist/_node_modules/fp-ts/es6/function.cjs.map +1 -0
  288. package/dist/_node_modules/fp-ts/es6/function.js +44 -0
  289. package/dist/_node_modules/fp-ts/es6/function.js.map +1 -0
  290. package/dist/_node_modules/fp-ts/es6/internal.cjs +18 -0
  291. package/dist/_node_modules/fp-ts/es6/internal.cjs.map +1 -0
  292. package/dist/_node_modules/fp-ts/es6/internal.js +18 -0
  293. package/dist/_node_modules/fp-ts/es6/internal.js.map +1 -0
  294. package/dist/_node_modules/get-port/index.cjs +113 -0
  295. package/dist/_node_modules/get-port/index.cjs.map +1 -0
  296. package/dist/_node_modules/get-port/index.js +114 -0
  297. package/dist/_node_modules/get-port/index.js.map +1 -0
  298. package/dist/_node_modules/isexe/index.cjs +56 -0
  299. package/dist/_node_modules/isexe/index.cjs.map +1 -0
  300. package/dist/_node_modules/isexe/index.js +56 -0
  301. package/dist/_node_modules/isexe/index.js.map +1 -0
  302. package/dist/_node_modules/isexe/mode.cjs +40 -0
  303. package/dist/_node_modules/isexe/mode.cjs.map +1 -0
  304. package/dist/_node_modules/isexe/mode.js +40 -0
  305. package/dist/_node_modules/isexe/mode.js.map +1 -0
  306. package/dist/_node_modules/isexe/windows.cjs +47 -0
  307. package/dist/_node_modules/isexe/windows.cjs.map +1 -0
  308. package/dist/_node_modules/isexe/windows.js +47 -0
  309. package/dist/_node_modules/isexe/windows.js.map +1 -0
  310. package/dist/_node_modules/merge-stream/index.cjs +39 -0
  311. package/dist/_node_modules/merge-stream/index.cjs.map +1 -0
  312. package/dist/_node_modules/merge-stream/index.js +40 -0
  313. package/dist/_node_modules/merge-stream/index.js.map +1 -0
  314. package/dist/_node_modules/node-domexception/index.cjs +11 -0
  315. package/dist/_node_modules/node-domexception/index.cjs.map +1 -0
  316. package/dist/_node_modules/node-domexception/index.js +10 -0
  317. package/dist/_node_modules/node-domexception/index.js.map +1 -0
  318. package/dist/_node_modules/node-fetch/src/body.cjs +262 -0
  319. package/dist/_node_modules/node-fetch/src/body.cjs.map +1 -0
  320. package/dist/_node_modules/node-fetch/src/body.js +262 -0
  321. package/dist/_node_modules/node-fetch/src/body.js.map +1 -0
  322. package/dist/_node_modules/node-fetch/src/errors/abort-error.cjs +10 -0
  323. package/dist/_node_modules/node-fetch/src/errors/abort-error.cjs.map +1 -0
  324. package/dist/_node_modules/node-fetch/src/errors/abort-error.js +10 -0
  325. package/dist/_node_modules/node-fetch/src/errors/abort-error.js.map +1 -0
  326. package/dist/_node_modules/node-fetch/src/errors/base.cjs +17 -0
  327. package/dist/_node_modules/node-fetch/src/errors/base.cjs.map +1 -0
  328. package/dist/_node_modules/node-fetch/src/errors/base.js +17 -0
  329. package/dist/_node_modules/node-fetch/src/errors/base.js.map +1 -0
  330. package/dist/_node_modules/node-fetch/src/errors/fetch-error.cjs +19 -0
  331. package/dist/_node_modules/node-fetch/src/errors/fetch-error.cjs.map +1 -0
  332. package/dist/_node_modules/node-fetch/src/errors/fetch-error.js +19 -0
  333. package/dist/_node_modules/node-fetch/src/errors/fetch-error.js.map +1 -0
  334. package/dist/_node_modules/node-fetch/src/headers.cjs +190 -0
  335. package/dist/_node_modules/node-fetch/src/headers.cjs.map +1 -0
  336. package/dist/_node_modules/node-fetch/src/headers.js +190 -0
  337. package/dist/_node_modules/node-fetch/src/headers.js.map +1 -0
  338. package/dist/_node_modules/node-fetch/src/index.cjs +292 -0
  339. package/dist/_node_modules/node-fetch/src/index.cjs.map +1 -0
  340. package/dist/_node_modules/node-fetch/src/index.js +292 -0
  341. package/dist/_node_modules/node-fetch/src/index.js.map +1 -0
  342. package/dist/_node_modules/node-fetch/src/request.cjs +206 -0
  343. package/dist/_node_modules/node-fetch/src/request.cjs.map +1 -0
  344. package/dist/_node_modules/node-fetch/src/request.js +206 -0
  345. package/dist/_node_modules/node-fetch/src/request.js.map +1 -0
  346. package/dist/_node_modules/node-fetch/src/response.cjs +122 -0
  347. package/dist/_node_modules/node-fetch/src/response.cjs.map +1 -0
  348. package/dist/_node_modules/node-fetch/src/response.js +123 -0
  349. package/dist/_node_modules/node-fetch/src/response.js.map +1 -0
  350. package/dist/_node_modules/node-fetch/src/utils/get-search.cjs +12 -0
  351. package/dist/_node_modules/node-fetch/src/utils/get-search.cjs.map +1 -0
  352. package/dist/_node_modules/node-fetch/src/utils/get-search.js +12 -0
  353. package/dist/_node_modules/node-fetch/src/utils/get-search.js.map +1 -0
  354. package/dist/_node_modules/node-fetch/src/utils/is-redirect.cjs +8 -0
  355. package/dist/_node_modules/node-fetch/src/utils/is-redirect.cjs.map +1 -0
  356. package/dist/_node_modules/node-fetch/src/utils/is-redirect.js +8 -0
  357. package/dist/_node_modules/node-fetch/src/utils/is-redirect.js.map +1 -0
  358. package/dist/_node_modules/node-fetch/src/utils/is.cjs +28 -0
  359. package/dist/_node_modules/node-fetch/src/utils/is.cjs.map +1 -0
  360. package/dist/_node_modules/node-fetch/src/utils/is.js +28 -0
  361. package/dist/_node_modules/node-fetch/src/utils/is.js.map +1 -0
  362. package/dist/_node_modules/node-fetch/src/utils/multipart-parser.cjs +356 -0
  363. package/dist/_node_modules/node-fetch/src/utils/multipart-parser.cjs.map +1 -0
  364. package/dist/_node_modules/node-fetch/src/utils/multipart-parser.js +356 -0
  365. package/dist/_node_modules/node-fetch/src/utils/multipart-parser.js.map +1 -0
  366. package/dist/_node_modules/node-fetch/src/utils/referrer.cjs +149 -0
  367. package/dist/_node_modules/node-fetch/src/utils/referrer.cjs.map +1 -0
  368. package/dist/_node_modules/node-fetch/src/utils/referrer.js +149 -0
  369. package/dist/_node_modules/node-fetch/src/utils/referrer.js.map +1 -0
  370. package/dist/_node_modules/p-limit/_node_modules/yocto-queue/index.cjs +89 -0
  371. package/dist/_node_modules/p-limit/_node_modules/yocto-queue/index.cjs.map +1 -0
  372. package/dist/_node_modules/p-limit/_node_modules/yocto-queue/index.js +90 -0
  373. package/dist/_node_modules/p-limit/_node_modules/yocto-queue/index.js.map +1 -0
  374. package/dist/_node_modules/p-limit/index.cjs +53 -0
  375. package/dist/_node_modules/p-limit/index.cjs.map +1 -0
  376. package/dist/_node_modules/p-limit/index.js +54 -0
  377. package/dist/_node_modules/p-limit/index.js.map +1 -0
  378. package/dist/_node_modules/path-key/index.cjs +16 -0
  379. package/dist/_node_modules/path-key/index.cjs.map +1 -0
  380. package/dist/_node_modules/path-key/index.js +16 -0
  381. package/dist/_node_modules/path-key/index.js.map +1 -0
  382. package/dist/_node_modules/peek-readable/lib/EndOfFileStream.cjs +11 -0
  383. package/dist/_node_modules/peek-readable/lib/EndOfFileStream.cjs.map +1 -0
  384. package/dist/_node_modules/peek-readable/lib/EndOfFileStream.js +11 -0
  385. package/dist/_node_modules/peek-readable/lib/EndOfFileStream.js.map +1 -0
  386. package/dist/_node_modules/r19/dist/R19Error.cjs +25 -0
  387. package/dist/_node_modules/r19/dist/R19Error.cjs.map +1 -0
  388. package/dist/_node_modules/r19/dist/R19Error.js +25 -0
  389. package/dist/_node_modules/r19/dist/R19Error.js.map +1 -0
  390. package/dist/_node_modules/r19/dist/client/createRPCClient.cjs +90 -0
  391. package/dist/_node_modules/r19/dist/client/createRPCClient.cjs.map +1 -0
  392. package/dist/_node_modules/r19/dist/client/createRPCClient.js +90 -0
  393. package/dist/_node_modules/r19/dist/client/createRPCClient.js.map +1 -0
  394. package/dist/_node_modules/r19/dist/createRPCMiddleware.cjs +36 -0
  395. package/dist/_node_modules/r19/dist/createRPCMiddleware.cjs.map +1 -0
  396. package/dist/_node_modules/r19/dist/createRPCMiddleware.js +36 -0
  397. package/dist/_node_modules/r19/dist/createRPCMiddleware.js.map +1 -0
  398. package/dist/_node_modules/r19/dist/handleRPCRequest.cjs +121 -0
  399. package/dist/_node_modules/r19/dist/handleRPCRequest.cjs.map +1 -0
  400. package/dist/_node_modules/r19/dist/handleRPCRequest.js +121 -0
  401. package/dist/_node_modules/r19/dist/handleRPCRequest.js.map +1 -0
  402. package/dist/_node_modules/r19/dist/lib/isErrorLike.cjs +7 -0
  403. package/dist/_node_modules/r19/dist/lib/isErrorLike.cjs.map +1 -0
  404. package/dist/_node_modules/r19/dist/lib/isErrorLike.js +7 -0
  405. package/dist/_node_modules/r19/dist/lib/isErrorLike.js.map +1 -0
  406. package/dist/_node_modules/r19/dist/lib/isPlainObject.cjs +11 -0
  407. package/dist/_node_modules/r19/dist/lib/isPlainObject.cjs.map +1 -0
  408. package/dist/_node_modules/r19/dist/lib/isPlainObject.js +11 -0
  409. package/dist/_node_modules/r19/dist/lib/isPlainObject.js.map +1 -0
  410. package/dist/_node_modules/r19/dist/lib/isR19ErrorLike.cjs +8 -0
  411. package/dist/_node_modules/r19/dist/lib/isR19ErrorLike.cjs.map +1 -0
  412. package/dist/_node_modules/r19/dist/lib/isR19ErrorLike.js +8 -0
  413. package/dist/_node_modules/r19/dist/lib/isR19ErrorLike.js.map +1 -0
  414. package/dist/_node_modules/r19/dist/lib/replaceLeaves.cjs +28 -0
  415. package/dist/_node_modules/r19/dist/lib/replaceLeaves.cjs.map +1 -0
  416. package/dist/_node_modules/r19/dist/lib/replaceLeaves.js +28 -0
  417. package/dist/_node_modules/r19/dist/lib/replaceLeaves.js.map +1 -0
  418. package/dist/_node_modules/r19/dist/proceduresFromInstance.cjs +33 -0
  419. package/dist/_node_modules/r19/dist/proceduresFromInstance.cjs.map +1 -0
  420. package/dist/_node_modules/r19/dist/proceduresFromInstance.js +33 -0
  421. package/dist/_node_modules/r19/dist/proceduresFromInstance.js.map +1 -0
  422. package/dist/_node_modules/shebang-command/index.cjs +18 -0
  423. package/dist/_node_modules/shebang-command/index.cjs.map +1 -0
  424. package/dist/_node_modules/shebang-command/index.js +18 -0
  425. package/dist/_node_modules/shebang-command/index.js.map +1 -0
  426. package/dist/_node_modules/shebang-regex/index.cjs +5 -0
  427. package/dist/_node_modules/shebang-regex/index.cjs.map +1 -0
  428. package/dist/_node_modules/shebang-regex/index.js +5 -0
  429. package/dist/_node_modules/shebang-regex/index.js.map +1 -0
  430. package/dist/_node_modules/signal-exit/index.cjs +150 -0
  431. package/dist/_node_modules/signal-exit/index.cjs.map +1 -0
  432. package/dist/_node_modules/signal-exit/index.js +151 -0
  433. package/dist/_node_modules/signal-exit/index.js.map +1 -0
  434. package/dist/_node_modules/signal-exit/signals.cjs +45 -0
  435. package/dist/_node_modules/signal-exit/signals.cjs.map +1 -0
  436. package/dist/_node_modules/signal-exit/signals.js +45 -0
  437. package/dist/_node_modules/signal-exit/signals.js.map +1 -0
  438. package/dist/_node_modules/strtok3/lib/AbstractTokenizer.cjs +98 -0
  439. package/dist/_node_modules/strtok3/lib/AbstractTokenizer.cjs.map +1 -0
  440. package/dist/_node_modules/strtok3/lib/AbstractTokenizer.js +98 -0
  441. package/dist/_node_modules/strtok3/lib/AbstractTokenizer.js.map +1 -0
  442. package/dist/_node_modules/strtok3/lib/BufferTokenizer.cjs +53 -0
  443. package/dist/_node_modules/strtok3/lib/BufferTokenizer.cjs.map +1 -0
  444. package/dist/_node_modules/strtok3/lib/BufferTokenizer.js +53 -0
  445. package/dist/_node_modules/strtok3/lib/BufferTokenizer.js.map +1 -0
  446. package/dist/_node_modules/strtok3/lib/core.cjs +9 -0
  447. package/dist/_node_modules/strtok3/lib/core.cjs.map +1 -0
  448. package/dist/_node_modules/strtok3/lib/core.js +9 -0
  449. package/dist/_node_modules/strtok3/lib/core.js.map +1 -0
  450. package/dist/_node_modules/token-types/lib/index.cjs +94 -0
  451. package/dist/_node_modules/token-types/lib/index.cjs.map +1 -0
  452. package/dist/_node_modules/token-types/lib/index.js +94 -0
  453. package/dist/_node_modules/token-types/lib/index.js.map +1 -0
  454. package/dist/_node_modules/unist-util-is/lib/index.cjs +76 -0
  455. package/dist/_node_modules/unist-util-is/lib/index.cjs.map +1 -0
  456. package/dist/_node_modules/unist-util-is/lib/index.js +76 -0
  457. package/dist/_node_modules/unist-util-is/lib/index.js.map +1 -0
  458. package/dist/_node_modules/unist-util-visit/lib/index.cjs +39 -0
  459. package/dist/_node_modules/unist-util-visit/lib/index.cjs.map +1 -0
  460. package/dist/_node_modules/unist-util-visit/lib/index.js +40 -0
  461. package/dist/_node_modules/unist-util-visit/lib/index.js.map +1 -0
  462. package/dist/_node_modules/unist-util-visit-parents/lib/color.browser.cjs +7 -0
  463. package/dist/_node_modules/unist-util-visit-parents/lib/color.browser.cjs.map +1 -0
  464. package/dist/_node_modules/unist-util-visit-parents/lib/color.browser.js +7 -0
  465. package/dist/_node_modules/unist-util-visit-parents/lib/color.browser.js.map +1 -0
  466. package/dist/_node_modules/unist-util-visit-parents/lib/index.cjs +86 -0
  467. package/dist/_node_modules/unist-util-visit-parents/lib/index.cjs.map +1 -0
  468. package/dist/_node_modules/unist-util-visit-parents/lib/index.js +86 -0
  469. package/dist/_node_modules/unist-util-visit-parents/lib/index.js.map +1 -0
  470. package/dist/_node_modules/web-streams-polyfill/dist/ponyfill.es2018.cjs +3822 -0
  471. package/dist/_node_modules/web-streams-polyfill/dist/ponyfill.es2018.cjs.map +1 -0
  472. package/dist/_node_modules/web-streams-polyfill/dist/ponyfill.es2018.js +3822 -0
  473. package/dist/_node_modules/web-streams-polyfill/dist/ponyfill.es2018.js.map +1 -0
  474. package/dist/_node_modules/which/which.cjs +96 -0
  475. package/dist/_node_modules/which/which.cjs.map +1 -0
  476. package/dist/_node_modules/which/which.js +96 -0
  477. package/dist/_node_modules/which/which.js.map +1 -0
  478. package/dist/_virtual/_commonjsHelpers.cjs +9 -0
  479. package/dist/_virtual/_commonjsHelpers.cjs.map +1 -0
  480. package/dist/_virtual/_commonjsHelpers.js +9 -0
  481. package/dist/_virtual/_commonjsHelpers.js.map +1 -0
  482. package/dist/_virtual/escape.cjs +5 -0
  483. package/dist/_virtual/escape.cjs.map +1 -0
  484. package/dist/_virtual/escape.js +5 -0
  485. package/dist/_virtual/escape.js.map +1 -0
  486. package/dist/_virtual/index.cjs +5 -0
  487. package/dist/_virtual/index.cjs.map +1 -0
  488. package/dist/_virtual/index.js +5 -0
  489. package/dist/_virtual/index.js.map +1 -0
  490. package/dist/_virtual/index2.cjs +5 -0
  491. package/dist/_virtual/index2.cjs.map +1 -0
  492. package/dist/_virtual/index2.js +5 -0
  493. package/dist/_virtual/index2.js.map +1 -0
  494. package/dist/_virtual/index3.cjs +5 -0
  495. package/dist/_virtual/index3.cjs.map +1 -0
  496. package/dist/_virtual/index3.js +5 -0
  497. package/dist/_virtual/index3.js.map +1 -0
  498. package/dist/_virtual/index4.cjs +5 -0
  499. package/dist/_virtual/index4.cjs.map +1 -0
  500. package/dist/_virtual/index4.js +5 -0
  501. package/dist/_virtual/index4.js.map +1 -0
  502. package/dist/_virtual/ponyfill.es2018.cjs +5 -0
  503. package/dist/_virtual/ponyfill.es2018.cjs.map +1 -0
  504. package/dist/_virtual/ponyfill.es2018.js +5 -0
  505. package/dist/_virtual/ponyfill.es2018.js.map +1 -0
  506. package/dist/_virtual/signals.cjs +5 -0
  507. package/dist/_virtual/signals.cjs.map +1 -0
  508. package/dist/_virtual/signals.js +5 -0
  509. package/dist/_virtual/signals.js.map +1 -0
  510. package/dist/auth/PrismicAuthManager.cjs +291 -0
  511. package/dist/auth/PrismicAuthManager.cjs.map +1 -0
  512. package/dist/auth/PrismicAuthManager.d.ts +58 -0
  513. package/dist/auth/PrismicAuthManager.js +269 -0
  514. package/dist/auth/PrismicAuthManager.js.map +1 -0
  515. package/dist/auth/createPrismicAuthManager.cjs +8 -0
  516. package/dist/auth/createPrismicAuthManager.cjs.map +1 -0
  517. package/dist/auth/createPrismicAuthManager.d.ts +4 -0
  518. package/dist/auth/createPrismicAuthManager.js +8 -0
  519. package/dist/auth/createPrismicAuthManager.js.map +1 -0
  520. package/dist/auth/createPrismicAuthManagerMiddleware.cjs +51 -0
  521. package/dist/auth/createPrismicAuthManagerMiddleware.cjs.map +1 -0
  522. package/dist/auth/createPrismicAuthManagerMiddleware.d.ts +14 -0
  523. package/dist/auth/createPrismicAuthManagerMiddleware.js +34 -0
  524. package/dist/auth/createPrismicAuthManagerMiddleware.js.map +1 -0
  525. package/dist/client/index.d.ts +7 -0
  526. package/dist/client.cjs +21 -0
  527. package/dist/client.cjs.map +1 -0
  528. package/dist/client.js +21 -0
  529. package/dist/client.js.map +1 -0
  530. package/dist/constants/API_ENDPOINTS.cjs +55 -0
  531. package/dist/constants/API_ENDPOINTS.cjs.map +1 -0
  532. package/dist/constants/API_ENDPOINTS.d.ts +11 -0
  533. package/dist/constants/API_ENDPOINTS.js +55 -0
  534. package/dist/constants/API_ENDPOINTS.js.map +1 -0
  535. package/dist/constants/API_TOKENS.cjs +18 -0
  536. package/dist/constants/API_TOKENS.cjs.map +1 -0
  537. package/dist/constants/API_TOKENS.d.ts +5 -0
  538. package/dist/constants/API_TOKENS.js +18 -0
  539. package/dist/constants/API_TOKENS.js.map +1 -0
  540. package/dist/constants/APPLICATION_MODE.cjs +9 -0
  541. package/dist/constants/APPLICATION_MODE.cjs.map +1 -0
  542. package/dist/constants/APPLICATION_MODE.d.ts +5 -0
  543. package/dist/constants/APPLICATION_MODE.js +9 -0
  544. package/dist/constants/APPLICATION_MODE.js.map +1 -0
  545. package/dist/constants/DEFAULT_SLICE_SCREENSHOT_URL.cjs +5 -0
  546. package/dist/constants/DEFAULT_SLICE_SCREENSHOT_URL.cjs.map +1 -0
  547. package/dist/constants/DEFAULT_SLICE_SCREENSHOT_URL.d.ts +5 -0
  548. package/dist/constants/DEFAULT_SLICE_SCREENSHOT_URL.js +5 -0
  549. package/dist/constants/DEFAULT_SLICE_SCREENSHOT_URL.js.map +1 -0
  550. package/dist/constants/REPOSITORY_NAME_VALIDATION.cjs +8 -0
  551. package/dist/constants/REPOSITORY_NAME_VALIDATION.cjs.map +1 -0
  552. package/dist/constants/REPOSITORY_NAME_VALIDATION.d.ts +4 -0
  553. package/dist/constants/REPOSITORY_NAME_VALIDATION.js +8 -0
  554. package/dist/constants/REPOSITORY_NAME_VALIDATION.js.map +1 -0
  555. package/dist/constants/SLICE_MACHINE_CONFIG_FILENAME.cjs +5 -0
  556. package/dist/constants/SLICE_MACHINE_CONFIG_FILENAME.cjs.map +1 -0
  557. package/dist/constants/SLICE_MACHINE_CONFIG_FILENAME.d.ts +1 -0
  558. package/dist/constants/SLICE_MACHINE_CONFIG_FILENAME.js +5 -0
  559. package/dist/constants/SLICE_MACHINE_CONFIG_FILENAME.js.map +1 -0
  560. package/dist/constants/SLICE_MACHINE_GITHUB_PACKAGE_NAME.cjs +5 -0
  561. package/dist/constants/SLICE_MACHINE_GITHUB_PACKAGE_NAME.cjs.map +1 -0
  562. package/dist/constants/SLICE_MACHINE_GITHUB_PACKAGE_NAME.d.ts +1 -0
  563. package/dist/constants/SLICE_MACHINE_GITHUB_PACKAGE_NAME.js +5 -0
  564. package/dist/constants/SLICE_MACHINE_GITHUB_PACKAGE_NAME.js.map +1 -0
  565. package/dist/constants/SLICE_MACHINE_GITHUB_REPOSITORY_NAME.cjs +5 -0
  566. package/dist/constants/SLICE_MACHINE_GITHUB_REPOSITORY_NAME.cjs.map +1 -0
  567. package/dist/constants/SLICE_MACHINE_GITHUB_REPOSITORY_NAME.d.ts +1 -0
  568. package/dist/constants/SLICE_MACHINE_GITHUB_REPOSITORY_NAME.js +5 -0
  569. package/dist/constants/SLICE_MACHINE_GITHUB_REPOSITORY_NAME.js.map +1 -0
  570. package/dist/constants/SLICE_MACHINE_GITHUB_REPOSITORY_ORGANIZATION.cjs +5 -0
  571. package/dist/constants/SLICE_MACHINE_GITHUB_REPOSITORY_ORGANIZATION.cjs.map +1 -0
  572. package/dist/constants/SLICE_MACHINE_GITHUB_REPOSITORY_ORGANIZATION.d.ts +1 -0
  573. package/dist/constants/SLICE_MACHINE_GITHUB_REPOSITORY_ORGANIZATION.js +5 -0
  574. package/dist/constants/SLICE_MACHINE_GITHUB_REPOSITORY_ORGANIZATION.js.map +1 -0
  575. package/dist/constants/SLICE_MACHINE_NPM_PACKAGE_NAME.cjs +5 -0
  576. package/dist/constants/SLICE_MACHINE_NPM_PACKAGE_NAME.cjs.map +1 -0
  577. package/dist/constants/SLICE_MACHINE_NPM_PACKAGE_NAME.d.ts +1 -0
  578. package/dist/constants/SLICE_MACHINE_NPM_PACKAGE_NAME.js +5 -0
  579. package/dist/constants/SLICE_MACHINE_NPM_PACKAGE_NAME.js.map +1 -0
  580. package/dist/constants/SLICE_MACHINE_USER_AGENT.cjs +5 -0
  581. package/dist/constants/SLICE_MACHINE_USER_AGENT.cjs.map +1 -0
  582. package/dist/constants/SLICE_MACHINE_USER_AGENT.d.ts +1 -0
  583. package/dist/constants/SLICE_MACHINE_USER_AGENT.js +5 -0
  584. package/dist/constants/SLICE_MACHINE_USER_AGENT.js.map +1 -0
  585. package/dist/constants/TS_CONFIG_FILENAME.cjs +5 -0
  586. package/dist/constants/TS_CONFIG_FILENAME.cjs.map +1 -0
  587. package/dist/constants/TS_CONFIG_FILENAME.d.ts +1 -0
  588. package/dist/constants/TS_CONFIG_FILENAME.js +5 -0
  589. package/dist/constants/TS_CONFIG_FILENAME.js.map +1 -0
  590. package/dist/constants/VERSION_KIND.cjs +10 -0
  591. package/dist/constants/VERSION_KIND.cjs.map +1 -0
  592. package/dist/constants/VERSION_KIND.d.ts +6 -0
  593. package/dist/constants/VERSION_KIND.js +10 -0
  594. package/dist/constants/VERSION_KIND.js.map +1 -0
  595. package/dist/errors.cjs +101 -0
  596. package/dist/errors.cjs.map +1 -0
  597. package/dist/errors.d.ts +35 -0
  598. package/dist/errors.js +101 -0
  599. package/dist/errors.js.map +1 -0
  600. package/dist/index.cjs +24 -0
  601. package/dist/index.cjs.map +1 -0
  602. package/dist/index.d.ts +16 -0
  603. package/dist/index.js +24 -0
  604. package/dist/index.js.map +1 -0
  605. package/dist/lib/DecodeError.cjs +22 -0
  606. package/dist/lib/DecodeError.cjs.map +1 -0
  607. package/dist/lib/DecodeError.d.ts +12 -0
  608. package/dist/lib/DecodeError.js +22 -0
  609. package/dist/lib/DecodeError.js.map +1 -0
  610. package/dist/lib/assertPluginsInitialized.cjs +9 -0
  611. package/dist/lib/assertPluginsInitialized.cjs.map +1 -0
  612. package/dist/lib/assertPluginsInitialized.d.ts +2 -0
  613. package/dist/lib/assertPluginsInitialized.js +9 -0
  614. package/dist/lib/assertPluginsInitialized.js.map +1 -0
  615. package/dist/lib/bufferCodec.cjs +24 -0
  616. package/dist/lib/bufferCodec.cjs.map +1 -0
  617. package/dist/lib/bufferCodec.d.ts +4 -0
  618. package/dist/lib/bufferCodec.js +7 -0
  619. package/dist/lib/bufferCodec.js.map +1 -0
  620. package/dist/lib/buildPrismicRepositoryAPIEndpoint.cjs +9 -0
  621. package/dist/lib/buildPrismicRepositoryAPIEndpoint.cjs.map +1 -0
  622. package/dist/lib/buildPrismicRepositoryAPIEndpoint.d.ts +4 -0
  623. package/dist/lib/buildPrismicRepositoryAPIEndpoint.js +9 -0
  624. package/dist/lib/buildPrismicRepositoryAPIEndpoint.js.map +1 -0
  625. package/dist/lib/castArray.cjs +7 -0
  626. package/dist/lib/castArray.cjs.map +1 -0
  627. package/dist/lib/castArray.d.ts +1 -0
  628. package/dist/lib/castArray.js +7 -0
  629. package/dist/lib/castArray.js.map +1 -0
  630. package/dist/lib/checkIsURLAccessible.d.ts +1 -0
  631. package/dist/lib/createContentDigest.cjs +25 -0
  632. package/dist/lib/createContentDigest.cjs.map +1 -0
  633. package/dist/lib/createContentDigest.d.ts +9 -0
  634. package/dist/lib/createContentDigest.js +8 -0
  635. package/dist/lib/createContentDigest.js.map +1 -0
  636. package/dist/lib/decode.cjs +18 -0
  637. package/dist/lib/decode.cjs.map +1 -0
  638. package/dist/lib/decode.d.ts +10 -0
  639. package/dist/lib/decode.js +18 -0
  640. package/dist/lib/decode.js.map +1 -0
  641. package/dist/lib/decodeHookResult.cjs +21 -0
  642. package/dist/lib/decodeHookResult.cjs.map +1 -0
  643. package/dist/lib/decodeHookResult.d.ts +10 -0
  644. package/dist/lib/decodeHookResult.js +21 -0
  645. package/dist/lib/decodeHookResult.js.map +1 -0
  646. package/dist/lib/decodePackageJSON.cjs +29 -0
  647. package/dist/lib/decodePackageJSON.cjs.map +1 -0
  648. package/dist/lib/decodePackageJSON.d.ts +12 -0
  649. package/dist/lib/decodePackageJSON.js +12 -0
  650. package/dist/lib/decodePackageJSON.js.map +1 -0
  651. package/dist/lib/decodeSliceMachineConfig.cjs +50 -0
  652. package/dist/lib/decodeSliceMachineConfig.cjs.map +1 -0
  653. package/dist/lib/decodeSliceMachineConfig.d.ts +3 -0
  654. package/dist/lib/decodeSliceMachineConfig.js +33 -0
  655. package/dist/lib/decodeSliceMachineConfig.js.map +1 -0
  656. package/dist/lib/fetch.cjs +36 -0
  657. package/dist/lib/fetch.cjs.map +1 -0
  658. package/dist/lib/fetch.d.ts +15 -0
  659. package/dist/lib/fetch.js +18 -0
  660. package/dist/lib/fetch.js.map +1 -0
  661. package/dist/lib/fetchGitHubReleaseBodyForRelease.cjs +105 -0
  662. package/dist/lib/fetchGitHubReleaseBodyForRelease.cjs.map +1 -0
  663. package/dist/lib/fetchGitHubReleaseBodyForRelease.d.ts +21 -0
  664. package/dist/lib/fetchGitHubReleaseBodyForRelease.js +88 -0
  665. package/dist/lib/fetchGitHubReleaseBodyForRelease.js.map +1 -0
  666. package/dist/lib/fetchNPMPackageVersions.cjs +41 -0
  667. package/dist/lib/fetchNPMPackageVersions.cjs.map +1 -0
  668. package/dist/lib/fetchNPMPackageVersions.d.ts +5 -0
  669. package/dist/lib/fetchNPMPackageVersions.js +24 -0
  670. package/dist/lib/fetchNPMPackageVersions.js.map +1 -0
  671. package/dist/lib/format.cjs +33 -0
  672. package/dist/lib/format.cjs.map +1 -0
  673. package/dist/lib/format.d.ts +12 -0
  674. package/dist/lib/format.js +33 -0
  675. package/dist/lib/format.js.map +1 -0
  676. package/dist/lib/functionCodec.cjs +29 -0
  677. package/dist/lib/functionCodec.cjs.map +1 -0
  678. package/dist/lib/functionCodec.d.ts +2 -0
  679. package/dist/lib/functionCodec.js +12 -0
  680. package/dist/lib/functionCodec.js.map +1 -0
  681. package/dist/lib/installDependencies.cjs +38 -0
  682. package/dist/lib/installDependencies.cjs.map +1 -0
  683. package/dist/lib/installDependencies.d.ts +13 -0
  684. package/dist/lib/installDependencies.js +38 -0
  685. package/dist/lib/installDependencies.js.map +1 -0
  686. package/dist/lib/locateFileUpward.cjs +47 -0
  687. package/dist/lib/locateFileUpward.cjs.map +1 -0
  688. package/dist/lib/locateFileUpward.d.ts +10 -0
  689. package/dist/lib/locateFileUpward.js +29 -0
  690. package/dist/lib/locateFileUpward.js.map +1 -0
  691. package/dist/lib/markdownToHTML.cjs +91 -0
  692. package/dist/lib/markdownToHTML.cjs.map +1 -0
  693. package/dist/lib/markdownToHTML.d.ts +1 -0
  694. package/dist/lib/markdownToHTML.js +69 -0
  695. package/dist/lib/markdownToHTML.js.map +1 -0
  696. package/dist/lib/mockSlice.cjs +32 -0
  697. package/dist/lib/mockSlice.cjs.map +1 -0
  698. package/dist/lib/mockSlice.d.ts +9 -0
  699. package/dist/lib/mockSlice.js +32 -0
  700. package/dist/lib/mockSlice.js.map +1 -0
  701. package/dist/lib/prismicrc.cjs +48 -0
  702. package/dist/lib/prismicrc.cjs.map +1 -0
  703. package/dist/lib/prismicrc.d.ts +10 -0
  704. package/dist/lib/prismicrc.js +29 -0
  705. package/dist/lib/prismicrc.js.map +1 -0
  706. package/dist/lib/serializeCookies.cjs +29 -0
  707. package/dist/lib/serializeCookies.cjs.map +1 -0
  708. package/dist/lib/serializeCookies.d.ts +6 -0
  709. package/dist/lib/serializeCookies.js +29 -0
  710. package/dist/lib/serializeCookies.js.map +1 -0
  711. package/dist/lib/trailingSlash.cjs +11 -0
  712. package/dist/lib/trailingSlash.cjs.map +1 -0
  713. package/dist/lib/trailingSlash.d.ts +2 -0
  714. package/dist/lib/trailingSlash.js +11 -0
  715. package/dist/lib/trailingSlash.js.map +1 -0
  716. package/dist/managers/BaseManager.cjs +69 -0
  717. package/dist/managers/BaseManager.cjs.map +1 -0
  718. package/dist/managers/BaseManager.d.ts +37 -0
  719. package/dist/managers/BaseManager.js +69 -0
  720. package/dist/managers/BaseManager.js.map +1 -0
  721. package/dist/managers/SliceMachineManager.cjs +251 -0
  722. package/dist/managers/SliceMachineManager.cjs.map +1 -0
  723. package/dist/managers/SliceMachineManager.d.ts +99 -0
  724. package/dist/managers/SliceMachineManager.js +251 -0
  725. package/dist/managers/SliceMachineManager.js.map +1 -0
  726. package/dist/managers/createSliceMachineManager.cjs +8 -0
  727. package/dist/managers/createSliceMachineManager.cjs.map +1 -0
  728. package/dist/managers/createSliceMachineManager.d.ts +5 -0
  729. package/dist/managers/createSliceMachineManager.js +8 -0
  730. package/dist/managers/createSliceMachineManager.js.map +1 -0
  731. package/dist/managers/createSliceMachineManagerClient.cjs +11 -0
  732. package/dist/managers/createSliceMachineManagerClient.cjs.map +1 -0
  733. package/dist/managers/createSliceMachineManagerClient.d.ts +8 -0
  734. package/dist/managers/createSliceMachineManagerClient.js +11 -0
  735. package/dist/managers/createSliceMachineManagerClient.js.map +1 -0
  736. package/dist/managers/createSliceMachineManagerMiddleware.cjs +44 -0
  737. package/dist/managers/createSliceMachineManagerMiddleware.cjs.map +1 -0
  738. package/dist/managers/createSliceMachineManagerMiddleware.d.ts +15 -0
  739. package/dist/managers/createSliceMachineManagerMiddleware.js +44 -0
  740. package/dist/managers/createSliceMachineManagerMiddleware.js.map +1 -0
  741. package/dist/managers/customTypes/CustomTypesManager.cjs +190 -0
  742. package/dist/managers/customTypes/CustomTypesManager.cjs.map +1 -0
  743. package/dist/managers/customTypes/CustomTypesManager.d.ts +61 -0
  744. package/dist/managers/customTypes/CustomTypesManager.js +172 -0
  745. package/dist/managers/customTypes/CustomTypesManager.js.map +1 -0
  746. package/dist/managers/customTypes/types.d.ts +2 -0
  747. package/dist/managers/documentation/DocumentationManager.cjs +42 -0
  748. package/dist/managers/documentation/DocumentationManager.cjs.map +1 -0
  749. package/dist/managers/documentation/DocumentationManager.d.ts +11 -0
  750. package/dist/managers/documentation/DocumentationManager.js +25 -0
  751. package/dist/managers/documentation/DocumentationManager.js.map +1 -0
  752. package/dist/managers/plugins/PluginsManager.cjs +36 -0
  753. package/dist/managers/plugins/PluginsManager.cjs.map +1 -0
  754. package/dist/managers/plugins/PluginsManager.d.ts +13 -0
  755. package/dist/managers/plugins/PluginsManager.js +36 -0
  756. package/dist/managers/plugins/PluginsManager.js.map +1 -0
  757. package/dist/managers/prismicRepository/PrismicRepositoryManager.cjs +404 -0
  758. package/dist/managers/prismicRepository/PrismicRepositoryManager.cjs.map +1 -0
  759. package/dist/managers/prismicRepository/PrismicRepositoryManager.d.ts +36 -0
  760. package/dist/managers/prismicRepository/PrismicRepositoryManager.js +387 -0
  761. package/dist/managers/prismicRepository/PrismicRepositoryManager.js.map +1 -0
  762. package/dist/managers/prismicRepository/sortEnvironments.cjs +36 -0
  763. package/dist/managers/prismicRepository/sortEnvironments.cjs.map +1 -0
  764. package/dist/managers/prismicRepository/sortEnvironments.d.ts +17 -0
  765. package/dist/managers/prismicRepository/sortEnvironments.js +36 -0
  766. package/dist/managers/prismicRepository/sortEnvironments.js.map +1 -0
  767. package/dist/managers/prismicRepository/types.cjs +78 -0
  768. package/dist/managers/prismicRepository/types.cjs.map +1 -0
  769. package/dist/managers/prismicRepository/types.d.ts +148 -0
  770. package/dist/managers/prismicRepository/types.js +63 -0
  771. package/dist/managers/prismicRepository/types.js.map +1 -0
  772. package/dist/managers/project/ProjectManager.cjs +273 -0
  773. package/dist/managers/project/ProjectManager.cjs.map +1 -0
  774. package/dist/managers/project/ProjectManager.d.ts +84 -0
  775. package/dist/managers/project/ProjectManager.js +254 -0
  776. package/dist/managers/project/ProjectManager.js.map +1 -0
  777. package/dist/managers/screenshots/ScreenshotsManager.cjs +164 -0
  778. package/dist/managers/screenshots/ScreenshotsManager.cjs.map +1 -0
  779. package/dist/managers/screenshots/ScreenshotsManager.d.ts +20 -0
  780. package/dist/managers/screenshots/ScreenshotsManager.js +147 -0
  781. package/dist/managers/screenshots/ScreenshotsManager.js.map +1 -0
  782. package/dist/managers/simulator/SimulatorManager.cjs +105 -0
  783. package/dist/managers/simulator/SimulatorManager.cjs.map +1 -0
  784. package/dist/managers/simulator/SimulatorManager.d.ts +38 -0
  785. package/dist/managers/simulator/SimulatorManager.js +88 -0
  786. package/dist/managers/simulator/SimulatorManager.js.map +1 -0
  787. package/dist/managers/sliceTemplateLibrary/SliceTemplateLibraryManager.cjs +139 -0
  788. package/dist/managers/sliceTemplateLibrary/SliceTemplateLibraryManager.cjs.map +1 -0
  789. package/dist/managers/sliceTemplateLibrary/SliceTemplateLibraryManager.d.ts +27 -0
  790. package/dist/managers/sliceTemplateLibrary/SliceTemplateLibraryManager.js +122 -0
  791. package/dist/managers/sliceTemplateLibrary/SliceTemplateLibraryManager.js.map +1 -0
  792. package/dist/managers/slices/SlicesManager.cjs +652 -0
  793. package/dist/managers/slices/SlicesManager.cjs.map +1 -0
  794. package/dist/managers/slices/SlicesManager.d.ts +178 -0
  795. package/dist/managers/slices/SlicesManager.js +634 -0
  796. package/dist/managers/slices/SlicesManager.js.map +1 -0
  797. package/dist/managers/snippets/SnippetsManager.cjs +41 -0
  798. package/dist/managers/snippets/SnippetsManager.cjs.map +1 -0
  799. package/dist/managers/snippets/SnippetsManager.d.ts +11 -0
  800. package/dist/managers/snippets/SnippetsManager.js +24 -0
  801. package/dist/managers/snippets/SnippetsManager.js.map +1 -0
  802. package/dist/managers/telemetry/TelemetryManager.cjs +154 -0
  803. package/dist/managers/telemetry/TelemetryManager.cjs.map +1 -0
  804. package/dist/managers/telemetry/TelemetryManager.d.ts +29 -0
  805. package/dist/managers/telemetry/TelemetryManager.js +154 -0
  806. package/dist/managers/telemetry/TelemetryManager.js.map +1 -0
  807. package/dist/managers/telemetry/types.cjs +57 -0
  808. package/dist/managers/telemetry/types.cjs.map +1 -0
  809. package/dist/managers/telemetry/types.d.ts +165 -0
  810. package/dist/managers/telemetry/types.js +57 -0
  811. package/dist/managers/telemetry/types.js.map +1 -0
  812. package/dist/managers/user/UserManager.cjs +29 -0
  813. package/dist/managers/user/UserManager.cjs.map +1 -0
  814. package/dist/managers/user/UserManager.d.ts +40 -0
  815. package/dist/managers/user/UserManager.js +29 -0
  816. package/dist/managers/user/UserManager.js.map +1 -0
  817. package/dist/managers/versions/VersionsManager.cjs +140 -0
  818. package/dist/managers/versions/VersionsManager.cjs.map +1 -0
  819. package/dist/managers/versions/VersionsManager.d.ts +22 -0
  820. package/dist/managers/versions/VersionsManager.js +122 -0
  821. package/dist/managers/versions/VersionsManager.js.map +1 -0
  822. package/dist/managers/versions/types.d.ts +5 -0
  823. package/dist/test/createSliceMachineManagerMSWHandler.cjs +18 -0
  824. package/dist/test/createSliceMachineManagerMSWHandler.cjs.map +1 -0
  825. package/dist/test/createSliceMachineManagerMSWHandler.d.ts +7 -0
  826. package/dist/test/createSliceMachineManagerMSWHandler.js +18 -0
  827. package/dist/test/createSliceMachineManagerMSWHandler.js.map +1 -0
  828. package/dist/test/index.d.ts +2 -0
  829. package/dist/test.cjs +5 -0
  830. package/dist/test.cjs.map +1 -0
  831. package/dist/test.js +5 -0
  832. package/dist/test.js.map +1 -0
  833. package/dist/types.d.ts +37 -0
  834. package/package.json +140 -0
  835. package/src/auth/PrismicAuthManager.ts +412 -0
  836. package/src/auth/createPrismicAuthManager.ts +11 -0
  837. package/src/auth/createPrismicAuthManagerMiddleware.ts +72 -0
  838. package/src/client/index.ts +35 -0
  839. package/src/constants/API_ENDPOINTS.ts +86 -0
  840. package/src/constants/API_TOKENS.ts +19 -0
  841. package/src/constants/APPLICATION_MODE.ts +5 -0
  842. package/src/constants/DEFAULT_SLICE_SCREENSHOT_URL.ts +6 -0
  843. package/src/constants/REPOSITORY_NAME_VALIDATION.ts +4 -0
  844. package/src/constants/SLICE_MACHINE_CONFIG_FILENAME.ts +1 -0
  845. package/src/constants/SLICE_MACHINE_GITHUB_PACKAGE_NAME.ts +1 -0
  846. package/src/constants/SLICE_MACHINE_GITHUB_REPOSITORY_NAME.ts +1 -0
  847. package/src/constants/SLICE_MACHINE_GITHUB_REPOSITORY_ORGANIZATION.ts +1 -0
  848. package/src/constants/SLICE_MACHINE_NPM_PACKAGE_NAME.ts +1 -0
  849. package/src/constants/SLICE_MACHINE_USER_AGENT.ts +1 -0
  850. package/src/constants/TS_CONFIG_FILENAME.ts +1 -0
  851. package/src/constants/VERSION_KIND.ts +6 -0
  852. package/src/errors.ts +85 -0
  853. package/src/index.ts +46 -0
  854. package/src/lib/DecodeError.ts +22 -0
  855. package/src/lib/assertPluginsInitialized.ts +11 -0
  856. package/src/lib/bufferCodec.ts +10 -0
  857. package/src/lib/buildPrismicRepositoryAPIEndpoint.ts +16 -0
  858. package/src/lib/castArray.ts +3 -0
  859. package/src/lib/checkIsURLAccessible.ts +7 -0
  860. package/src/lib/createContentDigest.ts +12 -0
  861. package/src/lib/decode.ts +36 -0
  862. package/src/lib/decodeHookResult.ts +36 -0
  863. package/src/lib/decodePackageJSON.ts +18 -0
  864. package/src/lib/decodeSliceMachineConfig.ts +39 -0
  865. package/src/lib/fetch.ts +46 -0
  866. package/src/lib/fetchGitHubReleaseBodyForRelease.ts +146 -0
  867. package/src/lib/fetchNPMPackageVersions.ts +46 -0
  868. package/src/lib/format.ts +34 -0
  869. package/src/lib/functionCodec.ts +16 -0
  870. package/src/lib/installDependencies.ts +65 -0
  871. package/src/lib/locateFileUpward.ts +53 -0
  872. package/src/lib/markdownToHTML.ts +116 -0
  873. package/src/lib/mockSlice.ts +50 -0
  874. package/src/lib/prismicrc.ts +64 -0
  875. package/src/lib/serializeCookies.ts +45 -0
  876. package/src/lib/trailingSlash.ts +9 -0
  877. package/src/managers/BaseManager.ts +100 -0
  878. package/src/managers/SliceMachineManager.ts +399 -0
  879. package/src/managers/createSliceMachineManager.ts +11 -0
  880. package/src/managers/createSliceMachineManagerClient.ts +23 -0
  881. package/src/managers/createSliceMachineManagerMiddleware.ts +78 -0
  882. package/src/managers/customTypes/CustomTypesManager.ts +332 -0
  883. package/src/managers/customTypes/types.ts +3 -0
  884. package/src/managers/documentation/DocumentationManager.ts +44 -0
  885. package/src/managers/plugins/PluginsManager.ts +48 -0
  886. package/src/managers/prismicRepository/PrismicRepositoryManager.ts +569 -0
  887. package/src/managers/prismicRepository/sortEnvironments.ts +55 -0
  888. package/src/managers/prismicRepository/types.ts +169 -0
  889. package/src/managers/project/ProjectManager.ts +443 -0
  890. package/src/managers/screenshots/ScreenshotsManager.ts +199 -0
  891. package/src/managers/simulator/SimulatorManager.ts +161 -0
  892. package/src/managers/sliceTemplateLibrary/SliceTemplateLibraryManager.ts +201 -0
  893. package/src/managers/slices/SlicesManager.ts +1105 -0
  894. package/src/managers/snippets/SnippetsManager.ts +45 -0
  895. package/src/managers/telemetry/TelemetryManager.ts +248 -0
  896. package/src/managers/telemetry/types.ts +283 -0
  897. package/src/managers/user/UserManager.ts +39 -0
  898. package/src/managers/versions/VersionsManager.ts +167 -0
  899. package/src/managers/versions/types.ts +6 -0
  900. package/src/test/createSliceMachineManagerMSWHandler.ts +29 -0
  901. package/src/test/index.ts +2 -0
  902. package/src/types.ts +47 -0
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sources":["../../../../../../node_modules/token-types/lib/index.js"],"sourcesContent":["import * as ieee754 from 'ieee754';\nimport { Buffer } from 'node:buffer';\n// Primitive types\nfunction dv(array) {\n return new DataView(array.buffer, array.byteOffset);\n}\n/**\n * 8-bit unsigned integer\n */\nexport const UINT8 = {\n len: 1,\n get(array, offset) {\n return dv(array).getUint8(offset);\n },\n put(array, offset, value) {\n dv(array).setUint8(offset, value);\n return offset + 1;\n }\n};\n/**\n * 16-bit unsigned integer, Little Endian byte order\n */\nexport const UINT16_LE = {\n len: 2,\n get(array, offset) {\n return dv(array).getUint16(offset, true);\n },\n put(array, offset, value) {\n dv(array).setUint16(offset, value, true);\n return offset + 2;\n }\n};\n/**\n * 16-bit unsigned integer, Big Endian byte order\n */\nexport const UINT16_BE = {\n len: 2,\n get(array, offset) {\n return dv(array).getUint16(offset);\n },\n put(array, offset, value) {\n dv(array).setUint16(offset, value);\n return offset + 2;\n }\n};\n/**\n * 24-bit unsigned integer, Little Endian byte order\n */\nexport const UINT24_LE = {\n len: 3,\n get(array, offset) {\n const dataView = dv(array);\n return dataView.getUint8(offset) + (dataView.getUint16(offset + 1, true) << 8);\n },\n put(array, offset, value) {\n const dataView = dv(array);\n dataView.setUint8(offset, value & 0xff);\n dataView.setUint16(offset + 1, value >> 8, true);\n return offset + 3;\n }\n};\n/**\n * 24-bit unsigned integer, Big Endian byte order\n */\nexport const UINT24_BE = {\n len: 3,\n get(array, offset) {\n const dataView = dv(array);\n return (dataView.getUint16(offset) << 8) + dataView.getUint8(offset + 2);\n },\n put(array, offset, value) {\n const dataView = dv(array);\n dataView.setUint16(offset, value >> 8);\n dataView.setUint8(offset + 2, value & 0xff);\n return offset + 3;\n }\n};\n/**\n * 32-bit unsigned integer, Little Endian byte order\n */\nexport const UINT32_LE = {\n len: 4,\n get(array, offset) {\n return dv(array).getUint32(offset, true);\n },\n put(array, offset, value) {\n dv(array).setUint32(offset, value, true);\n return offset + 4;\n }\n};\n/**\n * 32-bit unsigned integer, Big Endian byte order\n */\nexport const UINT32_BE = {\n len: 4,\n get(array, offset) {\n return dv(array).getUint32(offset);\n },\n put(array, offset, value) {\n dv(array).setUint32(offset, value);\n return offset + 4;\n }\n};\n/**\n * 8-bit signed integer\n */\nexport const INT8 = {\n len: 1,\n get(array, offset) {\n return dv(array).getInt8(offset);\n },\n put(array, offset, value) {\n dv(array).setInt8(offset, value);\n return offset + 1;\n }\n};\n/**\n * 16-bit signed integer, Big Endian byte order\n */\nexport const INT16_BE = {\n len: 2,\n get(array, offset) {\n return dv(array).getInt16(offset);\n },\n put(array, offset, value) {\n dv(array).setInt16(offset, value);\n return offset + 2;\n }\n};\n/**\n * 16-bit signed integer, Little Endian byte order\n */\nexport const INT16_LE = {\n len: 2,\n get(array, offset) {\n return dv(array).getInt16(offset, true);\n },\n put(array, offset, value) {\n dv(array).setInt16(offset, value, true);\n return offset + 2;\n }\n};\n/**\n * 24-bit signed integer, Little Endian byte order\n */\nexport const INT24_LE = {\n len: 3,\n get(array, offset) {\n const unsigned = UINT24_LE.get(array, offset);\n return unsigned > 0x7fffff ? unsigned - 0x1000000 : unsigned;\n },\n put(array, offset, value) {\n const dataView = dv(array);\n dataView.setUint8(offset, value & 0xff);\n dataView.setUint16(offset + 1, value >> 8, true);\n return offset + 3;\n }\n};\n/**\n * 24-bit signed integer, Big Endian byte order\n */\nexport const INT24_BE = {\n len: 3,\n get(array, offset) {\n const unsigned = UINT24_BE.get(array, offset);\n return unsigned > 0x7fffff ? unsigned - 0x1000000 : unsigned;\n },\n put(array, offset, value) {\n const dataView = dv(array);\n dataView.setUint16(offset, value >> 8);\n dataView.setUint8(offset + 2, value & 0xff);\n return offset + 3;\n }\n};\n/**\n * 32-bit signed integer, Big Endian byte order\n */\nexport const INT32_BE = {\n len: 4,\n get(array, offset) {\n return dv(array).getInt32(offset);\n },\n put(array, offset, value) {\n dv(array).setInt32(offset, value);\n return offset + 4;\n }\n};\n/**\n * 32-bit signed integer, Big Endian byte order\n */\nexport const INT32_LE = {\n len: 4,\n get(array, offset) {\n return dv(array).getInt32(offset, true);\n },\n put(array, offset, value) {\n dv(array).setInt32(offset, value, true);\n return offset + 4;\n }\n};\n/**\n * 64-bit unsigned integer, Little Endian byte order\n */\nexport const UINT64_LE = {\n len: 8,\n get(array, offset) {\n return dv(array).getBigUint64(offset, true);\n },\n put(array, offset, value) {\n dv(array).setBigUint64(offset, value, true);\n return offset + 8;\n }\n};\n/**\n * 64-bit signed integer, Little Endian byte order\n */\nexport const INT64_LE = {\n len: 8,\n get(array, offset) {\n return dv(array).getBigInt64(offset, true);\n },\n put(array, offset, value) {\n dv(array).setBigInt64(offset, value, true);\n return offset + 8;\n }\n};\n/**\n * 64-bit unsigned integer, Big Endian byte order\n */\nexport const UINT64_BE = {\n len: 8,\n get(array, offset) {\n return dv(array).getBigUint64(offset);\n },\n put(array, offset, value) {\n dv(array).setBigUint64(offset, value);\n return offset + 8;\n }\n};\n/**\n * 64-bit signed integer, Big Endian byte order\n */\nexport const INT64_BE = {\n len: 8,\n get(array, offset) {\n return dv(array).getBigInt64(offset);\n },\n put(array, offset, value) {\n dv(array).setBigInt64(offset, value);\n return offset + 8;\n }\n};\n/**\n * IEEE 754 16-bit (half precision) float, big endian\n */\nexport const Float16_BE = {\n len: 2,\n get(dataView, offset) {\n return ieee754.read(dataView, offset, false, 10, this.len);\n },\n put(dataView, offset, value) {\n ieee754.write(dataView, value, offset, false, 10, this.len);\n return offset + this.len;\n }\n};\n/**\n * IEEE 754 16-bit (half precision) float, little endian\n */\nexport const Float16_LE = {\n len: 2,\n get(array, offset) {\n return ieee754.read(array, offset, true, 10, this.len);\n },\n put(array, offset, value) {\n ieee754.write(array, value, offset, true, 10, this.len);\n return offset + this.len;\n }\n};\n/**\n * IEEE 754 32-bit (single precision) float, big endian\n */\nexport const Float32_BE = {\n len: 4,\n get(array, offset) {\n return dv(array).getFloat32(offset);\n },\n put(array, offset, value) {\n dv(array).setFloat32(offset, value);\n return offset + 4;\n }\n};\n/**\n * IEEE 754 32-bit (single precision) float, little endian\n */\nexport const Float32_LE = {\n len: 4,\n get(array, offset) {\n return dv(array).getFloat32(offset, true);\n },\n put(array, offset, value) {\n dv(array).setFloat32(offset, value, true);\n return offset + 4;\n }\n};\n/**\n * IEEE 754 64-bit (double precision) float, big endian\n */\nexport const Float64_BE = {\n len: 8,\n get(array, offset) {\n return dv(array).getFloat64(offset);\n },\n put(array, offset, value) {\n dv(array).setFloat64(offset, value);\n return offset + 8;\n }\n};\n/**\n * IEEE 754 64-bit (double precision) float, little endian\n */\nexport const Float64_LE = {\n len: 8,\n get(array, offset) {\n return dv(array).getFloat64(offset, true);\n },\n put(array, offset, value) {\n dv(array).setFloat64(offset, value, true);\n return offset + 8;\n }\n};\n/**\n * IEEE 754 80-bit (extended precision) float, big endian\n */\nexport const Float80_BE = {\n len: 10,\n get(array, offset) {\n return ieee754.read(array, offset, false, 63, this.len);\n },\n put(array, offset, value) {\n ieee754.write(array, value, offset, false, 63, this.len);\n return offset + this.len;\n }\n};\n/**\n * IEEE 754 80-bit (extended precision) float, little endian\n */\nexport const Float80_LE = {\n len: 10,\n get(array, offset) {\n return ieee754.read(array, offset, true, 63, this.len);\n },\n put(array, offset, value) {\n ieee754.write(array, value, offset, true, 63, this.len);\n return offset + this.len;\n }\n};\n/**\n * Ignore a given number of bytes\n */\nexport class IgnoreType {\n /**\n * @param len number of bytes to ignore\n */\n constructor(len) {\n this.len = len;\n }\n // ToDo: don't read, but skip data\n // eslint-disable-next-line @typescript-eslint/no-empty-function\n get(array, off) {\n }\n}\nexport class Uint8ArrayType {\n constructor(len) {\n this.len = len;\n }\n get(array, offset) {\n return array.subarray(offset, offset + this.len);\n }\n}\nexport class BufferType {\n constructor(len) {\n this.len = len;\n }\n get(uint8Array, off) {\n return Buffer.from(uint8Array.subarray(off, off + this.len));\n }\n}\n/**\n * Consume a fixed number of bytes from the stream and return a string with a specified encoding.\n */\nexport class StringType {\n constructor(len, encoding) {\n this.len = len;\n this.encoding = encoding;\n }\n get(uint8Array, offset) {\n return Buffer.from(uint8Array).toString(this.encoding, offset, offset + this.len);\n }\n}\n/**\n * ANSI Latin 1 String\n * Using windows-1252 / ISO 8859-1 decoding\n */\nexport class AnsiStringType {\n constructor(len) {\n this.len = len;\n }\n static decode(buffer, offset, until) {\n let str = '';\n for (let i = offset; i < until; ++i) {\n str += AnsiStringType.codePointToString(AnsiStringType.singleByteDecoder(buffer[i]));\n }\n return str;\n }\n static inRange(a, min, max) {\n return min <= a && a <= max;\n }\n static codePointToString(cp) {\n if (cp <= 0xFFFF) {\n return String.fromCharCode(cp);\n }\n else {\n cp -= 0x10000;\n return String.fromCharCode((cp >> 10) + 0xD800, (cp & 0x3FF) + 0xDC00);\n }\n }\n static singleByteDecoder(bite) {\n if (AnsiStringType.inRange(bite, 0x00, 0x7F)) {\n return bite;\n }\n const codePoint = AnsiStringType.windows1252[bite - 0x80];\n if (codePoint === null) {\n throw Error('invaliding encoding');\n }\n return codePoint;\n }\n get(buffer, offset = 0) {\n return AnsiStringType.decode(buffer, offset, offset + this.len);\n }\n}\nAnsiStringType.windows1252 = [8364, 129, 8218, 402, 8222, 8230, 8224, 8225, 710, 8240, 352,\n 8249, 338, 141, 381, 143, 144, 8216, 8217, 8220, 8221, 8226, 8211, 8212, 732,\n 8482, 353, 8250, 339, 157, 382, 376, 160, 161, 162, 163, 164, 165, 166, 167, 168,\n 169, 170, 171, 172, 173, 174, 175, 176, 177, 178, 179, 180, 181, 182, 183, 184,\n 185, 186, 187, 188, 189, 190, 191, 192, 193, 194, 195, 196, 197, 198, 199, 200,\n 201, 202, 203, 204, 205, 206, 207, 208, 209, 210, 211, 212, 213, 214, 215, 216,\n 217, 218, 219, 220, 221, 222, 223, 224, 225, 226, 227, 228, 229, 230, 231, 232,\n 233, 234, 235, 236, 237, 238, 239, 240, 241, 242, 243, 244, 245, 246, 247,\n 248, 249, 250, 251, 252, 253, 254, 255];\n"],"names":[],"mappings":";AAGA,SAAS,GAAG,OAAO;AACf,SAAO,IAAI,SAAS,MAAM,QAAQ,MAAM,UAAU;AACtD;AAIY,MAAC,QAAQ;AAAA,EACjB,KAAK;AAAA,EACL,IAAI,OAAO,QAAQ;AACf,WAAO,GAAG,KAAK,EAAE,SAAS,MAAM;AAAA,EACnC;AAAA,EACD,IAAI,OAAO,QAAQ,OAAO;AACtB,OAAG,KAAK,EAAE,SAAS,QAAQ,KAAK;AAChC,WAAO,SAAS;AAAA,EACnB;AACL;AAIY,MAAC,YAAY;AAAA,EACrB,KAAK;AAAA,EACL,IAAI,OAAO,QAAQ;AACf,WAAO,GAAG,KAAK,EAAE,UAAU,QAAQ,IAAI;AAAA,EAC1C;AAAA,EACD,IAAI,OAAO,QAAQ,OAAO;AACtB,OAAG,KAAK,EAAE,UAAU,QAAQ,OAAO,IAAI;AACvC,WAAO,SAAS;AAAA,EACnB;AACL;AAIY,MAAC,YAAY;AAAA,EACrB,KAAK;AAAA,EACL,IAAI,OAAO,QAAQ;AACf,WAAO,GAAG,KAAK,EAAE,UAAU,MAAM;AAAA,EACpC;AAAA,EACD,IAAI,OAAO,QAAQ,OAAO;AACtB,OAAG,KAAK,EAAE,UAAU,QAAQ,KAAK;AACjC,WAAO,SAAS;AAAA,EACnB;AACL;AAoCY,MAAC,YAAY;AAAA,EACrB,KAAK;AAAA,EACL,IAAI,OAAO,QAAQ;AACf,WAAO,GAAG,KAAK,EAAE,UAAU,QAAQ,IAAI;AAAA,EAC1C;AAAA,EACD,IAAI,OAAO,QAAQ,OAAO;AACtB,OAAG,KAAK,EAAE,UAAU,QAAQ,OAAO,IAAI;AACvC,WAAO,SAAS;AAAA,EACnB;AACL;AAIY,MAAC,YAAY;AAAA,EACrB,KAAK;AAAA,EACL,IAAI,OAAO,QAAQ;AACf,WAAO,GAAG,KAAK,EAAE,UAAU,MAAM;AAAA,EACpC;AAAA,EACD,IAAI,OAAO,QAAQ,OAAO;AACtB,OAAG,KAAK,EAAE,UAAU,QAAQ,KAAK;AACjC,WAAO,SAAS;AAAA,EACnB;AACL;AA2EY,MAAC,WAAW;AAAA,EACpB,KAAK;AAAA,EACL,IAAI,OAAO,QAAQ;AACf,WAAO,GAAG,KAAK,EAAE,SAAS,MAAM;AAAA,EACnC;AAAA,EACD,IAAI,OAAO,QAAQ,OAAO;AACtB,OAAG,KAAK,EAAE,SAAS,QAAQ,KAAK;AAChC,WAAO,SAAS;AAAA,EACnB;AACL;AAiBY,MAAC,YAAY;AAAA,EACrB,KAAK;AAAA,EACL,IAAI,OAAO,QAAQ;AACf,WAAO,GAAG,KAAK,EAAE,aAAa,QAAQ,IAAI;AAAA,EAC7C;AAAA,EACD,IAAI,OAAO,QAAQ,OAAO;AACtB,OAAG,KAAK,EAAE,aAAa,QAAQ,OAAO,IAAI;AAC1C,WAAO,SAAS;AAAA,EACnB;AACL;AAkLO,MAAM,WAAW;AAAA,EACpB,YAAY,KAAK,UAAU;AACvB,SAAK,MAAM;AACX,SAAK,WAAW;AAAA,EACnB;AAAA,EACD,IAAI,YAAY,QAAQ;AACpB,WAAO,OAAO,KAAK,UAAU,EAAE,SAAS,KAAK,UAAU,QAAQ,SAAS,KAAK,GAAG;AAAA,EACnF;AACL;","x_google_ignoreList":[0]}
@@ -0,0 +1,76 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
+ const convert = (
4
+ /**
5
+ * @type {(
6
+ * (<Kind extends Node>(test: PredicateTest<Kind>) => AssertPredicate<Kind>) &
7
+ * ((test?: Test) => AssertAnything)
8
+ * )}
9
+ */
10
+ /**
11
+ * @param {Test} [test]
12
+ * @returns {AssertAnything}
13
+ */
14
+ function(test) {
15
+ if (test === void 0 || test === null) {
16
+ return ok;
17
+ }
18
+ if (typeof test === "string") {
19
+ return typeFactory(test);
20
+ }
21
+ if (typeof test === "object") {
22
+ return Array.isArray(test) ? anyFactory(test) : propsFactory(test);
23
+ }
24
+ if (typeof test === "function") {
25
+ return castFactory(test);
26
+ }
27
+ throw new Error("Expected function, string, or object as test");
28
+ }
29
+ );
30
+ function anyFactory(tests) {
31
+ const checks = [];
32
+ let index = -1;
33
+ while (++index < tests.length) {
34
+ checks[index] = convert(tests[index]);
35
+ }
36
+ return castFactory(any);
37
+ function any(...parameters) {
38
+ let index2 = -1;
39
+ while (++index2 < checks.length) {
40
+ if (checks[index2].call(this, ...parameters))
41
+ return true;
42
+ }
43
+ return false;
44
+ }
45
+ }
46
+ function propsFactory(check) {
47
+ return castFactory(all);
48
+ function all(node) {
49
+ let key;
50
+ for (key in check) {
51
+ if (node[key] !== check[key])
52
+ return false;
53
+ }
54
+ return true;
55
+ }
56
+ }
57
+ function typeFactory(check) {
58
+ return castFactory(type);
59
+ function type(node) {
60
+ return node && node.type === check;
61
+ }
62
+ }
63
+ function castFactory(check) {
64
+ return assertion;
65
+ function assertion(node, ...parameters) {
66
+ return Boolean(
67
+ node && typeof node === "object" && "type" in node && // @ts-expect-error: fine.
68
+ Boolean(check.call(this, node, ...parameters))
69
+ );
70
+ }
71
+ }
72
+ function ok() {
73
+ return true;
74
+ }
75
+ exports.convert = convert;
76
+ //# sourceMappingURL=index.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.cjs","sources":["../../../../../../node_modules/unist-util-is/lib/index.js"],"sourcesContent":["/**\n * @typedef {import('unist').Node} Node\n * @typedef {import('unist').Parent} Parent\n */\n\n/**\n * @typedef {Record<string, unknown>} Props\n * @typedef {null | undefined | string | Props | TestFunctionAnything | Array<string | Props | TestFunctionAnything>} Test\n * Check for an arbitrary node, unaware of TypeScript inferral.\n *\n * @callback TestFunctionAnything\n * Check if a node passes a test, unaware of TypeScript inferral.\n * @param {unknown} this\n * The given context.\n * @param {Node} node\n * A node.\n * @param {number | null | undefined} [index]\n * The node’s position in its parent.\n * @param {Parent | null | undefined} [parent]\n * The node’s parent.\n * @returns {boolean | void}\n * Whether this node passes the test.\n */\n\n/**\n * @template {Node} Kind\n * Node type.\n * @typedef {Kind['type'] | Partial<Kind> | TestFunctionPredicate<Kind> | Array<Kind['type'] | Partial<Kind> | TestFunctionPredicate<Kind>>} PredicateTest\n * Check for a node that can be inferred by TypeScript.\n */\n\n/**\n * Check if a node passes a certain test.\n *\n * @template {Node} Kind\n * Node type.\n * @callback TestFunctionPredicate\n * Complex test function for a node that can be inferred by TypeScript.\n * @param {Node} node\n * A node.\n * @param {number | null | undefined} [index]\n * The node’s position in its parent.\n * @param {Parent | null | undefined} [parent]\n * The node’s parent.\n * @returns {node is Kind}\n * Whether this node passes the test.\n */\n\n/**\n * @callback AssertAnything\n * Check that an arbitrary value is a node, unaware of TypeScript inferral.\n * @param {unknown} [node]\n * Anything (typically a node).\n * @param {number | null | undefined} [index]\n * The node’s position in its parent.\n * @param {Parent | null | undefined} [parent]\n * The node’s parent.\n * @returns {boolean}\n * Whether this is a node and passes a test.\n */\n\n/**\n * Check if a node is a node and passes a certain node test.\n *\n * @template {Node} Kind\n * Node type.\n * @callback AssertPredicate\n * Check that an arbitrary value is a specific node, aware of TypeScript.\n * @param {unknown} [node]\n * Anything (typically a node).\n * @param {number | null | undefined} [index]\n * The node’s position in its parent.\n * @param {Parent | null | undefined} [parent]\n * The node’s parent.\n * @returns {node is Kind}\n * Whether this is a node and passes a test.\n */\n\n/**\n * Check if `node` is a `Node` and whether it passes the given test.\n *\n * @param node\n * Thing to check, typically `Node`.\n * @param test\n * A check for a specific node.\n * @param index\n * The node’s position in its parent.\n * @param parent\n * The node’s parent.\n * @returns\n * Whether `node` is a node and passes a test.\n */\nexport const is =\n /**\n * @type {(\n * (() => false) &\n * (<Kind extends Node = Node>(node: unknown, test: PredicateTest<Kind>, index: number, parent: Parent, context?: unknown) => node is Kind) &\n * (<Kind extends Node = Node>(node: unknown, test: PredicateTest<Kind>, index?: null | undefined, parent?: null | undefined, context?: unknown) => node is Kind) &\n * ((node: unknown, test: Test, index: number, parent: Parent, context?: unknown) => boolean) &\n * ((node: unknown, test?: Test, index?: null | undefined, parent?: null | undefined, context?: unknown) => boolean)\n * )}\n */\n (\n /**\n * @param {unknown} [node]\n * @param {Test} [test]\n * @param {number | null | undefined} [index]\n * @param {Parent | null | undefined} [parent]\n * @param {unknown} [context]\n * @returns {boolean}\n */\n // eslint-disable-next-line max-params\n function is(node, test, index, parent, context) {\n const check = convert(test)\n\n if (\n index !== undefined &&\n index !== null &&\n (typeof index !== 'number' ||\n index < 0 ||\n index === Number.POSITIVE_INFINITY)\n ) {\n throw new Error('Expected positive finite index')\n }\n\n if (\n parent !== undefined &&\n parent !== null &&\n (!is(parent) || !parent.children)\n ) {\n throw new Error('Expected parent node')\n }\n\n if (\n (parent === undefined || parent === null) !==\n (index === undefined || index === null)\n ) {\n throw new Error('Expected both parent and index')\n }\n\n // @ts-expect-error Looks like a node.\n return node && node.type && typeof node.type === 'string'\n ? Boolean(check.call(context, node, index, parent))\n : false\n }\n )\n\n/**\n * Generate an assertion from a test.\n *\n * Useful if you’re going to test many nodes, for example when creating a\n * utility where something else passes a compatible test.\n *\n * The created function is a bit faster because it expects valid input only:\n * a `node`, `index`, and `parent`.\n *\n * @param test\n * * when nullish, checks if `node` is a `Node`.\n * * when `string`, works like passing `(node) => node.type === test`.\n * * when `function` checks if function passed the node is true.\n * * when `object`, checks that all keys in test are in node, and that they have (strictly) equal values.\n * * when `array`, checks if any one of the subtests pass.\n * @returns\n * An assertion.\n */\nexport const convert =\n /**\n * @type {(\n * (<Kind extends Node>(test: PredicateTest<Kind>) => AssertPredicate<Kind>) &\n * ((test?: Test) => AssertAnything)\n * )}\n */\n (\n /**\n * @param {Test} [test]\n * @returns {AssertAnything}\n */\n function (test) {\n if (test === undefined || test === null) {\n return ok\n }\n\n if (typeof test === 'string') {\n return typeFactory(test)\n }\n\n if (typeof test === 'object') {\n return Array.isArray(test) ? anyFactory(test) : propsFactory(test)\n }\n\n if (typeof test === 'function') {\n return castFactory(test)\n }\n\n throw new Error('Expected function, string, or object as test')\n }\n )\n\n/**\n * @param {Array<string | Props | TestFunctionAnything>} tests\n * @returns {AssertAnything}\n */\nfunction anyFactory(tests) {\n /** @type {Array<AssertAnything>} */\n const checks = []\n let index = -1\n\n while (++index < tests.length) {\n checks[index] = convert(tests[index])\n }\n\n return castFactory(any)\n\n /**\n * @this {unknown}\n * @param {Array<unknown>} parameters\n * @returns {boolean}\n */\n function any(...parameters) {\n let index = -1\n\n while (++index < checks.length) {\n if (checks[index].call(this, ...parameters)) return true\n }\n\n return false\n }\n}\n\n/**\n * Turn an object into a test for a node with a certain fields.\n *\n * @param {Props} check\n * @returns {AssertAnything}\n */\nfunction propsFactory(check) {\n return castFactory(all)\n\n /**\n * @param {Node} node\n * @returns {boolean}\n */\n function all(node) {\n /** @type {string} */\n let key\n\n for (key in check) {\n // @ts-expect-error: hush, it sure works as an index.\n if (node[key] !== check[key]) return false\n }\n\n return true\n }\n}\n\n/**\n * Turn a string into a test for a node with a certain type.\n *\n * @param {string} check\n * @returns {AssertAnything}\n */\nfunction typeFactory(check) {\n return castFactory(type)\n\n /**\n * @param {Node} node\n */\n function type(node) {\n return node && node.type === check\n }\n}\n\n/**\n * Turn a custom test into a test for a node that passes that test.\n *\n * @param {TestFunctionAnything} check\n * @returns {AssertAnything}\n */\nfunction castFactory(check) {\n return assertion\n\n /**\n * @this {unknown}\n * @param {unknown} node\n * @param {Array<unknown>} parameters\n * @returns {boolean}\n */\n function assertion(node, ...parameters) {\n return Boolean(\n node &&\n typeof node === 'object' &&\n 'type' in node &&\n // @ts-expect-error: fine.\n Boolean(check.call(this, node, ...parameters))\n )\n }\n}\n\nfunction ok() {\n return true\n}\n"],"names":["index"],"mappings":";;AAqKY,MAAC;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAYT,SAAU,MAAM;AACd,QAAI,SAAS,UAAa,SAAS,MAAM;AACvC,aAAO;AAAA,IACR;AAED,QAAI,OAAO,SAAS,UAAU;AAC5B,aAAO,YAAY,IAAI;AAAA,IACxB;AAED,QAAI,OAAO,SAAS,UAAU;AAC5B,aAAO,MAAM,QAAQ,IAAI,IAAI,WAAW,IAAI,IAAI,aAAa,IAAI;AAAA,IAClE;AAED,QAAI,OAAO,SAAS,YAAY;AAC9B,aAAO,YAAY,IAAI;AAAA,IACxB;AAED,UAAM,IAAI,MAAM,8CAA8C;AAAA,EAC/D;AAAA;AAOL,SAAS,WAAW,OAAO;AAEzB,QAAM,SAAS,CAAE;AACjB,MAAI,QAAQ;AAEZ,SAAO,EAAE,QAAQ,MAAM,QAAQ;AAC7B,WAAO,KAAK,IAAI,QAAQ,MAAM,KAAK,CAAC;AAAA,EACrC;AAED,SAAO,YAAY,GAAG;AAOtB,WAAS,OAAO,YAAY;AAC1B,QAAIA,SAAQ;AAEZ,WAAO,EAAEA,SAAQ,OAAO,QAAQ;AAC9B,UAAI,OAAOA,MAAK,EAAE,KAAK,MAAM,GAAG,UAAU;AAAG,eAAO;AAAA,IACrD;AAED,WAAO;AAAA,EACR;AACH;AAQA,SAAS,aAAa,OAAO;AAC3B,SAAO,YAAY,GAAG;AAMtB,WAAS,IAAI,MAAM;AAEjB,QAAI;AAEJ,SAAK,OAAO,OAAO;AAEjB,UAAI,KAAK,GAAG,MAAM,MAAM,GAAG;AAAG,eAAO;AAAA,IACtC;AAED,WAAO;AAAA,EACR;AACH;AAQA,SAAS,YAAY,OAAO;AAC1B,SAAO,YAAY,IAAI;AAKvB,WAAS,KAAK,MAAM;AAClB,WAAO,QAAQ,KAAK,SAAS;AAAA,EAC9B;AACH;AAQA,SAAS,YAAY,OAAO;AAC1B,SAAO;AAQP,WAAS,UAAU,SAAS,YAAY;AACtC,WAAO;AAAA,MACL,QACE,OAAO,SAAS,YAChB,UAAU;AAAA,MAEV,QAAQ,MAAM,KAAK,MAAM,MAAM,GAAG,UAAU,CAAC;AAAA,IAChD;AAAA,EACF;AACH;AAEA,SAAS,KAAK;AACZ,SAAO;AACT;;","x_google_ignoreList":[0]}
@@ -0,0 +1,76 @@
1
+ const convert = (
2
+ /**
3
+ * @type {(
4
+ * (<Kind extends Node>(test: PredicateTest<Kind>) => AssertPredicate<Kind>) &
5
+ * ((test?: Test) => AssertAnything)
6
+ * )}
7
+ */
8
+ /**
9
+ * @param {Test} [test]
10
+ * @returns {AssertAnything}
11
+ */
12
+ function(test) {
13
+ if (test === void 0 || test === null) {
14
+ return ok;
15
+ }
16
+ if (typeof test === "string") {
17
+ return typeFactory(test);
18
+ }
19
+ if (typeof test === "object") {
20
+ return Array.isArray(test) ? anyFactory(test) : propsFactory(test);
21
+ }
22
+ if (typeof test === "function") {
23
+ return castFactory(test);
24
+ }
25
+ throw new Error("Expected function, string, or object as test");
26
+ }
27
+ );
28
+ function anyFactory(tests) {
29
+ const checks = [];
30
+ let index = -1;
31
+ while (++index < tests.length) {
32
+ checks[index] = convert(tests[index]);
33
+ }
34
+ return castFactory(any);
35
+ function any(...parameters) {
36
+ let index2 = -1;
37
+ while (++index2 < checks.length) {
38
+ if (checks[index2].call(this, ...parameters))
39
+ return true;
40
+ }
41
+ return false;
42
+ }
43
+ }
44
+ function propsFactory(check) {
45
+ return castFactory(all);
46
+ function all(node) {
47
+ let key;
48
+ for (key in check) {
49
+ if (node[key] !== check[key])
50
+ return false;
51
+ }
52
+ return true;
53
+ }
54
+ }
55
+ function typeFactory(check) {
56
+ return castFactory(type);
57
+ function type(node) {
58
+ return node && node.type === check;
59
+ }
60
+ }
61
+ function castFactory(check) {
62
+ return assertion;
63
+ function assertion(node, ...parameters) {
64
+ return Boolean(
65
+ node && typeof node === "object" && "type" in node && // @ts-expect-error: fine.
66
+ Boolean(check.call(this, node, ...parameters))
67
+ );
68
+ }
69
+ }
70
+ function ok() {
71
+ return true;
72
+ }
73
+ export {
74
+ convert
75
+ };
76
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sources":["../../../../../../node_modules/unist-util-is/lib/index.js"],"sourcesContent":["/**\n * @typedef {import('unist').Node} Node\n * @typedef {import('unist').Parent} Parent\n */\n\n/**\n * @typedef {Record<string, unknown>} Props\n * @typedef {null | undefined | string | Props | TestFunctionAnything | Array<string | Props | TestFunctionAnything>} Test\n * Check for an arbitrary node, unaware of TypeScript inferral.\n *\n * @callback TestFunctionAnything\n * Check if a node passes a test, unaware of TypeScript inferral.\n * @param {unknown} this\n * The given context.\n * @param {Node} node\n * A node.\n * @param {number | null | undefined} [index]\n * The node’s position in its parent.\n * @param {Parent | null | undefined} [parent]\n * The node’s parent.\n * @returns {boolean | void}\n * Whether this node passes the test.\n */\n\n/**\n * @template {Node} Kind\n * Node type.\n * @typedef {Kind['type'] | Partial<Kind> | TestFunctionPredicate<Kind> | Array<Kind['type'] | Partial<Kind> | TestFunctionPredicate<Kind>>} PredicateTest\n * Check for a node that can be inferred by TypeScript.\n */\n\n/**\n * Check if a node passes a certain test.\n *\n * @template {Node} Kind\n * Node type.\n * @callback TestFunctionPredicate\n * Complex test function for a node that can be inferred by TypeScript.\n * @param {Node} node\n * A node.\n * @param {number | null | undefined} [index]\n * The node’s position in its parent.\n * @param {Parent | null | undefined} [parent]\n * The node’s parent.\n * @returns {node is Kind}\n * Whether this node passes the test.\n */\n\n/**\n * @callback AssertAnything\n * Check that an arbitrary value is a node, unaware of TypeScript inferral.\n * @param {unknown} [node]\n * Anything (typically a node).\n * @param {number | null | undefined} [index]\n * The node’s position in its parent.\n * @param {Parent | null | undefined} [parent]\n * The node’s parent.\n * @returns {boolean}\n * Whether this is a node and passes a test.\n */\n\n/**\n * Check if a node is a node and passes a certain node test.\n *\n * @template {Node} Kind\n * Node type.\n * @callback AssertPredicate\n * Check that an arbitrary value is a specific node, aware of TypeScript.\n * @param {unknown} [node]\n * Anything (typically a node).\n * @param {number | null | undefined} [index]\n * The node’s position in its parent.\n * @param {Parent | null | undefined} [parent]\n * The node’s parent.\n * @returns {node is Kind}\n * Whether this is a node and passes a test.\n */\n\n/**\n * Check if `node` is a `Node` and whether it passes the given test.\n *\n * @param node\n * Thing to check, typically `Node`.\n * @param test\n * A check for a specific node.\n * @param index\n * The node’s position in its parent.\n * @param parent\n * The node’s parent.\n * @returns\n * Whether `node` is a node and passes a test.\n */\nexport const is =\n /**\n * @type {(\n * (() => false) &\n * (<Kind extends Node = Node>(node: unknown, test: PredicateTest<Kind>, index: number, parent: Parent, context?: unknown) => node is Kind) &\n * (<Kind extends Node = Node>(node: unknown, test: PredicateTest<Kind>, index?: null | undefined, parent?: null | undefined, context?: unknown) => node is Kind) &\n * ((node: unknown, test: Test, index: number, parent: Parent, context?: unknown) => boolean) &\n * ((node: unknown, test?: Test, index?: null | undefined, parent?: null | undefined, context?: unknown) => boolean)\n * )}\n */\n (\n /**\n * @param {unknown} [node]\n * @param {Test} [test]\n * @param {number | null | undefined} [index]\n * @param {Parent | null | undefined} [parent]\n * @param {unknown} [context]\n * @returns {boolean}\n */\n // eslint-disable-next-line max-params\n function is(node, test, index, parent, context) {\n const check = convert(test)\n\n if (\n index !== undefined &&\n index !== null &&\n (typeof index !== 'number' ||\n index < 0 ||\n index === Number.POSITIVE_INFINITY)\n ) {\n throw new Error('Expected positive finite index')\n }\n\n if (\n parent !== undefined &&\n parent !== null &&\n (!is(parent) || !parent.children)\n ) {\n throw new Error('Expected parent node')\n }\n\n if (\n (parent === undefined || parent === null) !==\n (index === undefined || index === null)\n ) {\n throw new Error('Expected both parent and index')\n }\n\n // @ts-expect-error Looks like a node.\n return node && node.type && typeof node.type === 'string'\n ? Boolean(check.call(context, node, index, parent))\n : false\n }\n )\n\n/**\n * Generate an assertion from a test.\n *\n * Useful if you’re going to test many nodes, for example when creating a\n * utility where something else passes a compatible test.\n *\n * The created function is a bit faster because it expects valid input only:\n * a `node`, `index`, and `parent`.\n *\n * @param test\n * * when nullish, checks if `node` is a `Node`.\n * * when `string`, works like passing `(node) => node.type === test`.\n * * when `function` checks if function passed the node is true.\n * * when `object`, checks that all keys in test are in node, and that they have (strictly) equal values.\n * * when `array`, checks if any one of the subtests pass.\n * @returns\n * An assertion.\n */\nexport const convert =\n /**\n * @type {(\n * (<Kind extends Node>(test: PredicateTest<Kind>) => AssertPredicate<Kind>) &\n * ((test?: Test) => AssertAnything)\n * )}\n */\n (\n /**\n * @param {Test} [test]\n * @returns {AssertAnything}\n */\n function (test) {\n if (test === undefined || test === null) {\n return ok\n }\n\n if (typeof test === 'string') {\n return typeFactory(test)\n }\n\n if (typeof test === 'object') {\n return Array.isArray(test) ? anyFactory(test) : propsFactory(test)\n }\n\n if (typeof test === 'function') {\n return castFactory(test)\n }\n\n throw new Error('Expected function, string, or object as test')\n }\n )\n\n/**\n * @param {Array<string | Props | TestFunctionAnything>} tests\n * @returns {AssertAnything}\n */\nfunction anyFactory(tests) {\n /** @type {Array<AssertAnything>} */\n const checks = []\n let index = -1\n\n while (++index < tests.length) {\n checks[index] = convert(tests[index])\n }\n\n return castFactory(any)\n\n /**\n * @this {unknown}\n * @param {Array<unknown>} parameters\n * @returns {boolean}\n */\n function any(...parameters) {\n let index = -1\n\n while (++index < checks.length) {\n if (checks[index].call(this, ...parameters)) return true\n }\n\n return false\n }\n}\n\n/**\n * Turn an object into a test for a node with a certain fields.\n *\n * @param {Props} check\n * @returns {AssertAnything}\n */\nfunction propsFactory(check) {\n return castFactory(all)\n\n /**\n * @param {Node} node\n * @returns {boolean}\n */\n function all(node) {\n /** @type {string} */\n let key\n\n for (key in check) {\n // @ts-expect-error: hush, it sure works as an index.\n if (node[key] !== check[key]) return false\n }\n\n return true\n }\n}\n\n/**\n * Turn a string into a test for a node with a certain type.\n *\n * @param {string} check\n * @returns {AssertAnything}\n */\nfunction typeFactory(check) {\n return castFactory(type)\n\n /**\n * @param {Node} node\n */\n function type(node) {\n return node && node.type === check\n }\n}\n\n/**\n * Turn a custom test into a test for a node that passes that test.\n *\n * @param {TestFunctionAnything} check\n * @returns {AssertAnything}\n */\nfunction castFactory(check) {\n return assertion\n\n /**\n * @this {unknown}\n * @param {unknown} node\n * @param {Array<unknown>} parameters\n * @returns {boolean}\n */\n function assertion(node, ...parameters) {\n return Boolean(\n node &&\n typeof node === 'object' &&\n 'type' in node &&\n // @ts-expect-error: fine.\n Boolean(check.call(this, node, ...parameters))\n )\n }\n}\n\nfunction ok() {\n return true\n}\n"],"names":["index"],"mappings":"AAqKY,MAAC;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAYT,SAAU,MAAM;AACd,QAAI,SAAS,UAAa,SAAS,MAAM;AACvC,aAAO;AAAA,IACR;AAED,QAAI,OAAO,SAAS,UAAU;AAC5B,aAAO,YAAY,IAAI;AAAA,IACxB;AAED,QAAI,OAAO,SAAS,UAAU;AAC5B,aAAO,MAAM,QAAQ,IAAI,IAAI,WAAW,IAAI,IAAI,aAAa,IAAI;AAAA,IAClE;AAED,QAAI,OAAO,SAAS,YAAY;AAC9B,aAAO,YAAY,IAAI;AAAA,IACxB;AAED,UAAM,IAAI,MAAM,8CAA8C;AAAA,EAC/D;AAAA;AAOL,SAAS,WAAW,OAAO;AAEzB,QAAM,SAAS,CAAE;AACjB,MAAI,QAAQ;AAEZ,SAAO,EAAE,QAAQ,MAAM,QAAQ;AAC7B,WAAO,KAAK,IAAI,QAAQ,MAAM,KAAK,CAAC;AAAA,EACrC;AAED,SAAO,YAAY,GAAG;AAOtB,WAAS,OAAO,YAAY;AAC1B,QAAIA,SAAQ;AAEZ,WAAO,EAAEA,SAAQ,OAAO,QAAQ;AAC9B,UAAI,OAAOA,MAAK,EAAE,KAAK,MAAM,GAAG,UAAU;AAAG,eAAO;AAAA,IACrD;AAED,WAAO;AAAA,EACR;AACH;AAQA,SAAS,aAAa,OAAO;AAC3B,SAAO,YAAY,GAAG;AAMtB,WAAS,IAAI,MAAM;AAEjB,QAAI;AAEJ,SAAK,OAAO,OAAO;AAEjB,UAAI,KAAK,GAAG,MAAM,MAAM,GAAG;AAAG,eAAO;AAAA,IACtC;AAED,WAAO;AAAA,EACR;AACH;AAQA,SAAS,YAAY,OAAO;AAC1B,SAAO,YAAY,IAAI;AAKvB,WAAS,KAAK,MAAM;AAClB,WAAO,QAAQ,KAAK,SAAS;AAAA,EAC9B;AACH;AAQA,SAAS,YAAY,OAAO;AAC1B,SAAO;AAQP,WAAS,UAAU,SAAS,YAAY;AACtC,WAAO;AAAA,MACL,QACE,OAAO,SAAS,YAChB,UAAU;AAAA,MAEV,QAAQ,MAAM,KAAK,MAAM,MAAM,GAAG,UAAU,CAAC;AAAA,IAChD;AAAA,EACF;AACH;AAEA,SAAS,KAAK;AACZ,SAAO;AACT;","x_google_ignoreList":[0]}
@@ -0,0 +1,39 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
+ const index = require("../../unist-util-visit-parents/lib/index.cjs");
4
+ const visit = (
5
+ /**
6
+ * @type {(
7
+ * (<Tree extends Node, Check extends Test>(tree: Tree, test: Check, visitor: BuildVisitor<Tree, Check>, reverse?: boolean | null | undefined) => void) &
8
+ * (<Tree extends Node>(tree: Tree, visitor: BuildVisitor<Tree>, reverse?: boolean | null | undefined) => void)
9
+ * )}
10
+ */
11
+ /**
12
+ * @param {Node} tree
13
+ * @param {Test} test
14
+ * @param {Visitor} visitor
15
+ * @param {boolean | null | undefined} [reverse]
16
+ * @returns {void}
17
+ */
18
+ function(tree, test, visitor, reverse) {
19
+ if (typeof test === "function" && typeof visitor !== "function") {
20
+ reverse = visitor;
21
+ visitor = test;
22
+ test = null;
23
+ }
24
+ index.visitParents(tree, test, overload, reverse);
25
+ function overload(node, parents) {
26
+ const parent = parents[parents.length - 1];
27
+ return visitor(
28
+ node,
29
+ parent ? parent.children.indexOf(node) : null,
30
+ parent
31
+ );
32
+ }
33
+ }
34
+ );
35
+ exports.CONTINUE = index.CONTINUE;
36
+ exports.EXIT = index.EXIT;
37
+ exports.SKIP = index.SKIP;
38
+ exports.visit = visit;
39
+ //# sourceMappingURL=index.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.cjs","sources":["../../../../../../node_modules/unist-util-visit/lib/index.js"],"sourcesContent":["/**\n * @typedef {import('unist').Node} Node\n * @typedef {import('unist').Parent} Parent\n * @typedef {import('unist-util-is').Test} Test\n * @typedef {import('unist-util-visit-parents').VisitorResult} VisitorResult\n */\n\n/**\n * Check if `Child` can be a child of `Ancestor`.\n *\n * Returns the ancestor when `Child` can be a child of `Ancestor`, or returns\n * `never`.\n *\n * @template {Node} Ancestor\n * Node type.\n * @template {Node} Child\n * Node type.\n * @typedef {(\n * Ancestor extends Parent\n * ? Child extends Ancestor['children'][number]\n * ? Ancestor\n * : never\n * : never\n * )} ParentsOf\n */\n\n/**\n * @template {Node} [Visited=Node]\n * Visited node type.\n * @template {Parent} [Ancestor=Parent]\n * Ancestor type.\n * @callback Visitor\n * Handle a node (matching `test`, if given).\n *\n * Visitors are free to transform `node`.\n * They can also transform `parent`.\n *\n * Replacing `node` itself, if `SKIP` is not returned, still causes its\n * descendants to be walked (which is a bug).\n *\n * When adding or removing previous siblings of `node` (or next siblings, in\n * case of reverse), the `Visitor` should return a new `Index` to specify the\n * sibling to traverse after `node` is traversed.\n * Adding or removing next siblings of `node` (or previous siblings, in case\n * of reverse) is handled as expected without needing to return a new `Index`.\n *\n * Removing the children property of `parent` still results in them being\n * traversed.\n * @param {Visited} node\n * Found node.\n * @param {Visited extends Node ? number | null : never} index\n * Index of `node` in `parent`.\n * @param {Ancestor extends Node ? Ancestor | null : never} parent\n * Parent of `node`.\n * @returns {VisitorResult}\n * What to do next.\n *\n * An `Index` is treated as a tuple of `[CONTINUE, Index]`.\n * An `Action` is treated as a tuple of `[Action]`.\n *\n * Passing a tuple back only makes sense if the `Action` is `SKIP`.\n * When the `Action` is `EXIT`, that action can be returned.\n * When the `Action` is `CONTINUE`, `Index` can be returned.\n */\n\n/**\n * Build a typed `Visitor` function from a node and all possible parents.\n *\n * It will infer which values are passed as `node` and which as `parent`.\n *\n * @template {Node} Visited\n * Node type.\n * @template {Parent} Ancestor\n * Parent type.\n * @typedef {Visitor<Visited, ParentsOf<Ancestor, Visited>>} BuildVisitorFromMatch\n */\n\n/**\n * Build a typed `Visitor` function from a list of descendants and a test.\n *\n * It will infer which values are passed as `node` and which as `parent`.\n *\n * @template {Node} Descendant\n * Node type.\n * @template {Test} Check\n * Test type.\n * @typedef {(\n * BuildVisitorFromMatch<\n * import('unist-util-visit-parents/complex-types.js').Matches<Descendant, Check>,\n * Extract<Descendant, Parent>\n * >\n * )} BuildVisitorFromDescendants\n */\n\n/**\n * Build a typed `Visitor` function from a tree and a test.\n *\n * It will infer which values are passed as `node` and which as `parent`.\n *\n * @template {Node} [Tree=Node]\n * Node type.\n * @template {Test} [Check=string]\n * Test type.\n * @typedef {(\n * BuildVisitorFromDescendants<\n * import('unist-util-visit-parents/complex-types.js').InclusiveDescendant<Tree>,\n * Check\n * >\n * )} BuildVisitor\n */\n\nimport {visitParents} from 'unist-util-visit-parents'\n\n/**\n * Visit nodes.\n *\n * This algorithm performs *depth-first* *tree traversal* in *preorder*\n * (**NLR**) or if `reverse` is given, in *reverse preorder* (**NRL**).\n *\n * You can choose for which nodes `visitor` is called by passing a `test`.\n * For complex tests, you should test yourself in `visitor`, as it will be\n * faster and will have improved type information.\n *\n * Walking the tree is an intensive task.\n * Make use of the return values of the visitor when possible.\n * Instead of walking a tree multiple times, walk it once, use `unist-util-is`\n * to check if a node matches, and then perform different operations.\n *\n * You can change the tree.\n * See `Visitor` for more info.\n *\n * @param tree\n * Tree to traverse.\n * @param test\n * `unist-util-is`-compatible test\n * @param visitor\n * Handle each node.\n * @param reverse\n * Traverse in reverse preorder (NRL) instead of the default preorder (NLR).\n * @returns\n * Nothing.\n */\nexport const visit =\n /**\n * @type {(\n * (<Tree extends Node, Check extends Test>(tree: Tree, test: Check, visitor: BuildVisitor<Tree, Check>, reverse?: boolean | null | undefined) => void) &\n * (<Tree extends Node>(tree: Tree, visitor: BuildVisitor<Tree>, reverse?: boolean | null | undefined) => void)\n * )}\n */\n (\n /**\n * @param {Node} tree\n * @param {Test} test\n * @param {Visitor} visitor\n * @param {boolean | null | undefined} [reverse]\n * @returns {void}\n */\n function (tree, test, visitor, reverse) {\n if (typeof test === 'function' && typeof visitor !== 'function') {\n reverse = visitor\n visitor = test\n test = null\n }\n\n visitParents(tree, test, overload, reverse)\n\n /**\n * @param {Node} node\n * @param {Array<Parent>} parents\n */\n function overload(node, parents) {\n const parent = parents[parents.length - 1]\n return visitor(\n node,\n parent ? parent.children.indexOf(node) : null,\n parent\n )\n }\n }\n )\n\nexport {CONTINUE, EXIT, SKIP} from 'unist-util-visit-parents'\n"],"names":["visitParents"],"mappings":";;;AA8IY,MAAC;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAeT,SAAU,MAAM,MAAM,SAAS,SAAS;AACtC,QAAI,OAAO,SAAS,cAAc,OAAO,YAAY,YAAY;AAC/D,gBAAU;AACV,gBAAU;AACV,aAAO;AAAA,IACR;AAEDA,UAAAA,aAAa,MAAM,MAAM,UAAU,OAAO;AAM1C,aAAS,SAAS,MAAM,SAAS;AAC/B,YAAM,SAAS,QAAQ,QAAQ,SAAS,CAAC;AACzC,aAAO;AAAA,QACL;AAAA,QACA,SAAS,OAAO,SAAS,QAAQ,IAAI,IAAI;AAAA,QACzC;AAAA,MACD;AAAA,IACF;AAAA,EACF;AAAA;;;;;","x_google_ignoreList":[0]}
@@ -0,0 +1,40 @@
1
+ import { visitParents } from "../../unist-util-visit-parents/lib/index.js";
2
+ import { CONTINUE, EXIT, SKIP } from "../../unist-util-visit-parents/lib/index.js";
3
+ const visit = (
4
+ /**
5
+ * @type {(
6
+ * (<Tree extends Node, Check extends Test>(tree: Tree, test: Check, visitor: BuildVisitor<Tree, Check>, reverse?: boolean | null | undefined) => void) &
7
+ * (<Tree extends Node>(tree: Tree, visitor: BuildVisitor<Tree>, reverse?: boolean | null | undefined) => void)
8
+ * )}
9
+ */
10
+ /**
11
+ * @param {Node} tree
12
+ * @param {Test} test
13
+ * @param {Visitor} visitor
14
+ * @param {boolean | null | undefined} [reverse]
15
+ * @returns {void}
16
+ */
17
+ function(tree, test, visitor, reverse) {
18
+ if (typeof test === "function" && typeof visitor !== "function") {
19
+ reverse = visitor;
20
+ visitor = test;
21
+ test = null;
22
+ }
23
+ visitParents(tree, test, overload, reverse);
24
+ function overload(node, parents) {
25
+ const parent = parents[parents.length - 1];
26
+ return visitor(
27
+ node,
28
+ parent ? parent.children.indexOf(node) : null,
29
+ parent
30
+ );
31
+ }
32
+ }
33
+ );
34
+ export {
35
+ CONTINUE,
36
+ EXIT,
37
+ SKIP,
38
+ visit
39
+ };
40
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sources":["../../../../../../node_modules/unist-util-visit/lib/index.js"],"sourcesContent":["/**\n * @typedef {import('unist').Node} Node\n * @typedef {import('unist').Parent} Parent\n * @typedef {import('unist-util-is').Test} Test\n * @typedef {import('unist-util-visit-parents').VisitorResult} VisitorResult\n */\n\n/**\n * Check if `Child` can be a child of `Ancestor`.\n *\n * Returns the ancestor when `Child` can be a child of `Ancestor`, or returns\n * `never`.\n *\n * @template {Node} Ancestor\n * Node type.\n * @template {Node} Child\n * Node type.\n * @typedef {(\n * Ancestor extends Parent\n * ? Child extends Ancestor['children'][number]\n * ? Ancestor\n * : never\n * : never\n * )} ParentsOf\n */\n\n/**\n * @template {Node} [Visited=Node]\n * Visited node type.\n * @template {Parent} [Ancestor=Parent]\n * Ancestor type.\n * @callback Visitor\n * Handle a node (matching `test`, if given).\n *\n * Visitors are free to transform `node`.\n * They can also transform `parent`.\n *\n * Replacing `node` itself, if `SKIP` is not returned, still causes its\n * descendants to be walked (which is a bug).\n *\n * When adding or removing previous siblings of `node` (or next siblings, in\n * case of reverse), the `Visitor` should return a new `Index` to specify the\n * sibling to traverse after `node` is traversed.\n * Adding or removing next siblings of `node` (or previous siblings, in case\n * of reverse) is handled as expected without needing to return a new `Index`.\n *\n * Removing the children property of `parent` still results in them being\n * traversed.\n * @param {Visited} node\n * Found node.\n * @param {Visited extends Node ? number | null : never} index\n * Index of `node` in `parent`.\n * @param {Ancestor extends Node ? Ancestor | null : never} parent\n * Parent of `node`.\n * @returns {VisitorResult}\n * What to do next.\n *\n * An `Index` is treated as a tuple of `[CONTINUE, Index]`.\n * An `Action` is treated as a tuple of `[Action]`.\n *\n * Passing a tuple back only makes sense if the `Action` is `SKIP`.\n * When the `Action` is `EXIT`, that action can be returned.\n * When the `Action` is `CONTINUE`, `Index` can be returned.\n */\n\n/**\n * Build a typed `Visitor` function from a node and all possible parents.\n *\n * It will infer which values are passed as `node` and which as `parent`.\n *\n * @template {Node} Visited\n * Node type.\n * @template {Parent} Ancestor\n * Parent type.\n * @typedef {Visitor<Visited, ParentsOf<Ancestor, Visited>>} BuildVisitorFromMatch\n */\n\n/**\n * Build a typed `Visitor` function from a list of descendants and a test.\n *\n * It will infer which values are passed as `node` and which as `parent`.\n *\n * @template {Node} Descendant\n * Node type.\n * @template {Test} Check\n * Test type.\n * @typedef {(\n * BuildVisitorFromMatch<\n * import('unist-util-visit-parents/complex-types.js').Matches<Descendant, Check>,\n * Extract<Descendant, Parent>\n * >\n * )} BuildVisitorFromDescendants\n */\n\n/**\n * Build a typed `Visitor` function from a tree and a test.\n *\n * It will infer which values are passed as `node` and which as `parent`.\n *\n * @template {Node} [Tree=Node]\n * Node type.\n * @template {Test} [Check=string]\n * Test type.\n * @typedef {(\n * BuildVisitorFromDescendants<\n * import('unist-util-visit-parents/complex-types.js').InclusiveDescendant<Tree>,\n * Check\n * >\n * )} BuildVisitor\n */\n\nimport {visitParents} from 'unist-util-visit-parents'\n\n/**\n * Visit nodes.\n *\n * This algorithm performs *depth-first* *tree traversal* in *preorder*\n * (**NLR**) or if `reverse` is given, in *reverse preorder* (**NRL**).\n *\n * You can choose for which nodes `visitor` is called by passing a `test`.\n * For complex tests, you should test yourself in `visitor`, as it will be\n * faster and will have improved type information.\n *\n * Walking the tree is an intensive task.\n * Make use of the return values of the visitor when possible.\n * Instead of walking a tree multiple times, walk it once, use `unist-util-is`\n * to check if a node matches, and then perform different operations.\n *\n * You can change the tree.\n * See `Visitor` for more info.\n *\n * @param tree\n * Tree to traverse.\n * @param test\n * `unist-util-is`-compatible test\n * @param visitor\n * Handle each node.\n * @param reverse\n * Traverse in reverse preorder (NRL) instead of the default preorder (NLR).\n * @returns\n * Nothing.\n */\nexport const visit =\n /**\n * @type {(\n * (<Tree extends Node, Check extends Test>(tree: Tree, test: Check, visitor: BuildVisitor<Tree, Check>, reverse?: boolean | null | undefined) => void) &\n * (<Tree extends Node>(tree: Tree, visitor: BuildVisitor<Tree>, reverse?: boolean | null | undefined) => void)\n * )}\n */\n (\n /**\n * @param {Node} tree\n * @param {Test} test\n * @param {Visitor} visitor\n * @param {boolean | null | undefined} [reverse]\n * @returns {void}\n */\n function (tree, test, visitor, reverse) {\n if (typeof test === 'function' && typeof visitor !== 'function') {\n reverse = visitor\n visitor = test\n test = null\n }\n\n visitParents(tree, test, overload, reverse)\n\n /**\n * @param {Node} node\n * @param {Array<Parent>} parents\n */\n function overload(node, parents) {\n const parent = parents[parents.length - 1]\n return visitor(\n node,\n parent ? parent.children.indexOf(node) : null,\n parent\n )\n }\n }\n )\n\nexport {CONTINUE, EXIT, SKIP} from 'unist-util-visit-parents'\n"],"names":[],"mappings":";;AA8IY,MAAC;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAeT,SAAU,MAAM,MAAM,SAAS,SAAS;AACtC,QAAI,OAAO,SAAS,cAAc,OAAO,YAAY,YAAY;AAC/D,gBAAU;AACV,gBAAU;AACV,aAAO;AAAA,IACR;AAED,iBAAa,MAAM,MAAM,UAAU,OAAO;AAM1C,aAAS,SAAS,MAAM,SAAS;AAC/B,YAAM,SAAS,QAAQ,QAAQ,SAAS,CAAC;AACzC,aAAO;AAAA,QACL;AAAA,QACA,SAAS,OAAO,SAAS,QAAQ,IAAI,IAAI;AAAA,QACzC;AAAA,MACD;AAAA,IACF;AAAA,EACF;AAAA;","x_google_ignoreList":[0]}
@@ -0,0 +1,7 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
+ function color(d) {
4
+ return d;
5
+ }
6
+ exports.color = color;
7
+ //# sourceMappingURL=color.browser.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"color.browser.cjs","sources":["../../../../../../node_modules/unist-util-visit-parents/lib/color.browser.js"],"sourcesContent":["/**\n * @param {string} d\n * @returns {string}\n */\nexport function color(d) {\n return d\n}\n"],"names":[],"mappings":";;AAIO,SAAS,MAAM,GAAG;AACvB,SAAO;AACT;;","x_google_ignoreList":[0]}
@@ -0,0 +1,7 @@
1
+ function color(d) {
2
+ return d;
3
+ }
4
+ export {
5
+ color
6
+ };
7
+ //# sourceMappingURL=color.browser.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"color.browser.js","sources":["../../../../../../node_modules/unist-util-visit-parents/lib/color.browser.js"],"sourcesContent":["/**\n * @param {string} d\n * @returns {string}\n */\nexport function color(d) {\n return d\n}\n"],"names":[],"mappings":"AAIO,SAAS,MAAM,GAAG;AACvB,SAAO;AACT;","x_google_ignoreList":[0]}
@@ -0,0 +1,86 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
+ const color_browser = require("./color.browser.cjs");
4
+ const index = require("../../unist-util-is/lib/index.cjs");
5
+ const CONTINUE = true;
6
+ const EXIT = false;
7
+ const SKIP = "skip";
8
+ const visitParents = (
9
+ /**
10
+ * @type {(
11
+ * (<Tree extends Node, Check extends Test>(tree: Tree, test: Check, visitor: BuildVisitor<Tree, Check>, reverse?: boolean | null | undefined) => void) &
12
+ * (<Tree extends Node>(tree: Tree, visitor: BuildVisitor<Tree>, reverse?: boolean | null | undefined) => void)
13
+ * )}
14
+ */
15
+ /**
16
+ * @param {Node} tree
17
+ * @param {Test} test
18
+ * @param {Visitor<Node>} visitor
19
+ * @param {boolean | null | undefined} [reverse]
20
+ * @returns {void}
21
+ */
22
+ function(tree, test, visitor, reverse) {
23
+ if (typeof test === "function" && typeof visitor !== "function") {
24
+ reverse = visitor;
25
+ visitor = test;
26
+ test = null;
27
+ }
28
+ const is = index.convert(test);
29
+ const step = reverse ? -1 : 1;
30
+ factory(tree, void 0, [])();
31
+ function factory(node, index2, parents) {
32
+ const value = node && typeof node === "object" ? node : {};
33
+ if (typeof value.type === "string") {
34
+ const name = (
35
+ // `hast`
36
+ typeof value.tagName === "string" ? value.tagName : (
37
+ // `xast`
38
+ typeof value.name === "string" ? value.name : void 0
39
+ )
40
+ );
41
+ Object.defineProperty(visit, "name", {
42
+ value: "node (" + color_browser.color(node.type + (name ? "<" + name + ">" : "")) + ")"
43
+ });
44
+ }
45
+ return visit;
46
+ function visit() {
47
+ let result = [];
48
+ let subresult;
49
+ let offset;
50
+ let grandparents;
51
+ if (!test || is(node, index2, parents[parents.length - 1] || null)) {
52
+ result = toResult(visitor(node, parents));
53
+ if (result[0] === EXIT) {
54
+ return result;
55
+ }
56
+ }
57
+ if (node.children && result[0] !== SKIP) {
58
+ offset = (reverse ? node.children.length : -1) + step;
59
+ grandparents = parents.concat(node);
60
+ while (offset > -1 && offset < node.children.length) {
61
+ subresult = factory(node.children[offset], offset, grandparents)();
62
+ if (subresult[0] === EXIT) {
63
+ return subresult;
64
+ }
65
+ offset = typeof subresult[1] === "number" ? subresult[1] : offset + step;
66
+ }
67
+ }
68
+ return result;
69
+ }
70
+ }
71
+ }
72
+ );
73
+ function toResult(value) {
74
+ if (Array.isArray(value)) {
75
+ return value;
76
+ }
77
+ if (typeof value === "number") {
78
+ return [CONTINUE, value];
79
+ }
80
+ return [value];
81
+ }
82
+ exports.CONTINUE = CONTINUE;
83
+ exports.EXIT = EXIT;
84
+ exports.SKIP = SKIP;
85
+ exports.visitParents = visitParents;
86
+ //# sourceMappingURL=index.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.cjs","sources":["../../../../../../node_modules/unist-util-visit-parents/lib/index.js"],"sourcesContent":["/**\n * @typedef {import('unist').Node} Node\n * @typedef {import('unist').Parent} Parent\n * @typedef {import('unist-util-is').Test} Test\n */\n\n/**\n * @typedef {boolean | 'skip'} Action\n * Union of the action types.\n *\n * @typedef {number} Index\n * Move to the sibling at `index` next (after node itself is completely\n * traversed).\n *\n * Useful if mutating the tree, such as removing the node the visitor is\n * currently on, or any of its previous siblings.\n * Results less than 0 or greater than or equal to `children.length` stop\n * traversing the parent.\n *\n * @typedef {[(Action | null | undefined | void)?, (Index | null | undefined)?]} ActionTuple\n * List with one or two values, the first an action, the second an index.\n *\n * @typedef {Action | ActionTuple | Index | null | undefined | void} VisitorResult\n * Any value that can be returned from a visitor.\n */\n\n/**\n * @template {Node} [Visited=Node]\n * Visited node type.\n * @template {Parent} [Ancestor=Parent]\n * Ancestor type.\n * @callback Visitor\n * Handle a node (matching `test`, if given).\n *\n * Visitors are free to transform `node`.\n * They can also transform the parent of node (the last of `ancestors`).\n *\n * Replacing `node` itself, if `SKIP` is not returned, still causes its\n * descendants to be walked (which is a bug).\n *\n * When adding or removing previous siblings of `node` (or next siblings, in\n * case of reverse), the `Visitor` should return a new `Index` to specify the\n * sibling to traverse after `node` is traversed.\n * Adding or removing next siblings of `node` (or previous siblings, in case\n * of reverse) is handled as expected without needing to return a new `Index`.\n *\n * Removing the children property of an ancestor still results in them being\n * traversed.\n * @param {Visited} node\n * Found node.\n * @param {Array<Ancestor>} ancestors\n * Ancestors of `node`.\n * @returns {VisitorResult}\n * What to do next.\n *\n * An `Index` is treated as a tuple of `[CONTINUE, Index]`.\n * An `Action` is treated as a tuple of `[Action]`.\n *\n * Passing a tuple back only makes sense if the `Action` is `SKIP`.\n * When the `Action` is `EXIT`, that action can be returned.\n * When the `Action` is `CONTINUE`, `Index` can be returned.\n */\n\n/**\n * @template {Node} [Tree=Node]\n * Tree type.\n * @template {Test} [Check=string]\n * Test type.\n * @typedef {Visitor<import('./complex-types.js').Matches<import('./complex-types.js').InclusiveDescendant<Tree>, Check>, Extract<import('./complex-types.js').InclusiveDescendant<Tree>, Parent>>} BuildVisitor\n * Build a typed `Visitor` function from a tree and a test.\n *\n * It will infer which values are passed as `node` and which as `parents`.\n */\n\nimport {convert} from 'unist-util-is'\nimport {color} from './color.js'\n\n/**\n * Continue traversing as normal.\n */\nexport const CONTINUE = true\n\n/**\n * Stop traversing immediately.\n */\nexport const EXIT = false\n\n/**\n * Do not traverse this node’s children.\n */\nexport const SKIP = 'skip'\n\n/**\n * Visit nodes, with ancestral information.\n *\n * This algorithm performs *depth-first* *tree traversal* in *preorder*\n * (**NLR**) or if `reverse` is given, in *reverse preorder* (**NRL**).\n *\n * You can choose for which nodes `visitor` is called by passing a `test`.\n * For complex tests, you should test yourself in `visitor`, as it will be\n * faster and will have improved type information.\n *\n * Walking the tree is an intensive task.\n * Make use of the return values of the visitor when possible.\n * Instead of walking a tree multiple times, walk it once, use `unist-util-is`\n * to check if a node matches, and then perform different operations.\n *\n * You can change the tree.\n * See `Visitor` for more info.\n *\n * @param tree\n * Tree to traverse.\n * @param test\n * `unist-util-is`-compatible test\n * @param visitor\n * Handle each node.\n * @param reverse\n * Traverse in reverse preorder (NRL) instead of the default preorder (NLR).\n * @returns\n * Nothing.\n */\nexport const visitParents =\n /**\n * @type {(\n * (<Tree extends Node, Check extends Test>(tree: Tree, test: Check, visitor: BuildVisitor<Tree, Check>, reverse?: boolean | null | undefined) => void) &\n * (<Tree extends Node>(tree: Tree, visitor: BuildVisitor<Tree>, reverse?: boolean | null | undefined) => void)\n * )}\n */\n (\n /**\n * @param {Node} tree\n * @param {Test} test\n * @param {Visitor<Node>} visitor\n * @param {boolean | null | undefined} [reverse]\n * @returns {void}\n */\n function (tree, test, visitor, reverse) {\n if (typeof test === 'function' && typeof visitor !== 'function') {\n reverse = visitor\n // @ts-expect-error no visitor given, so `visitor` is test.\n visitor = test\n test = null\n }\n\n const is = convert(test)\n const step = reverse ? -1 : 1\n\n factory(tree, undefined, [])()\n\n /**\n * @param {Node} node\n * @param {number | undefined} index\n * @param {Array<Parent>} parents\n */\n function factory(node, index, parents) {\n /** @type {Record<string, unknown>} */\n // @ts-expect-error: hush\n const value = node && typeof node === 'object' ? node : {}\n\n if (typeof value.type === 'string') {\n const name =\n // `hast`\n typeof value.tagName === 'string'\n ? value.tagName\n : // `xast`\n typeof value.name === 'string'\n ? value.name\n : undefined\n\n Object.defineProperty(visit, 'name', {\n value:\n 'node (' + color(node.type + (name ? '<' + name + '>' : '')) + ')'\n })\n }\n\n return visit\n\n function visit() {\n /** @type {ActionTuple} */\n let result = []\n /** @type {ActionTuple} */\n let subresult\n /** @type {number} */\n let offset\n /** @type {Array<Parent>} */\n let grandparents\n\n if (!test || is(node, index, parents[parents.length - 1] || null)) {\n result = toResult(visitor(node, parents))\n\n if (result[0] === EXIT) {\n return result\n }\n }\n\n // @ts-expect-error looks like a parent.\n if (node.children && result[0] !== SKIP) {\n // @ts-expect-error looks like a parent.\n offset = (reverse ? node.children.length : -1) + step\n // @ts-expect-error looks like a parent.\n grandparents = parents.concat(node)\n\n // @ts-expect-error looks like a parent.\n while (offset > -1 && offset < node.children.length) {\n // @ts-expect-error looks like a parent.\n subresult = factory(node.children[offset], offset, grandparents)()\n\n if (subresult[0] === EXIT) {\n return subresult\n }\n\n offset =\n typeof subresult[1] === 'number' ? subresult[1] : offset + step\n }\n }\n\n return result\n }\n }\n }\n )\n\n/**\n * Turn a return value into a clean result.\n *\n * @param {VisitorResult} value\n * Valid return values from visitors.\n * @returns {ActionTuple}\n * Clean result.\n */\nfunction toResult(value) {\n if (Array.isArray(value)) {\n return value\n }\n\n if (typeof value === 'number') {\n return [CONTINUE, value]\n }\n\n return [value]\n}\n"],"names":["convert","index","color"],"mappings":";;;;AAgFY,MAAC,WAAW;AAKZ,MAAC,OAAO;AAKR,MAAC,OAAO;AA+BR,MAAC;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAeT,SAAU,MAAM,MAAM,SAAS,SAAS;AACtC,QAAI,OAAO,SAAS,cAAc,OAAO,YAAY,YAAY;AAC/D,gBAAU;AAEV,gBAAU;AACV,aAAO;AAAA,IACR;AAED,UAAM,KAAKA,MAAO,QAAC,IAAI;AACvB,UAAM,OAAO,UAAU,KAAK;AAE5B,YAAQ,MAAM,QAAW,CAAA,CAAE,EAAG;AAO9B,aAAS,QAAQ,MAAMC,QAAO,SAAS;AAGrC,YAAM,QAAQ,QAAQ,OAAO,SAAS,WAAW,OAAO,CAAE;AAE1D,UAAI,OAAO,MAAM,SAAS,UAAU;AAClC,cAAM;AAAA;AAAA,UAEJ,OAAO,MAAM,YAAY,WACrB,MAAM;AAAA;AAAA,YAER,OAAO,MAAM,SAAS,WACpB,MAAM,OACN;AAAA;AAAA;AAEN,eAAO,eAAe,OAAO,QAAQ;AAAA,UACnC,OACE,WAAWC,cAAK,MAAC,KAAK,QAAQ,OAAO,MAAM,OAAO,MAAM,GAAG,IAAI;AAAA,QAC7E,CAAW;AAAA,MACF;AAED,aAAO;AAEP,eAAS,QAAQ;AAEf,YAAI,SAAS,CAAE;AAEf,YAAI;AAEJ,YAAI;AAEJ,YAAI;AAEJ,YAAI,CAAC,QAAQ,GAAG,MAAMD,QAAO,QAAQ,QAAQ,SAAS,CAAC,KAAK,IAAI,GAAG;AACjE,mBAAS,SAAS,QAAQ,MAAM,OAAO,CAAC;AAExC,cAAI,OAAO,CAAC,MAAM,MAAM;AACtB,mBAAO;AAAA,UACR;AAAA,QACF;AAGD,YAAI,KAAK,YAAY,OAAO,CAAC,MAAM,MAAM;AAEvC,oBAAU,UAAU,KAAK,SAAS,SAAS,MAAM;AAEjD,yBAAe,QAAQ,OAAO,IAAI;AAGlC,iBAAO,SAAS,MAAM,SAAS,KAAK,SAAS,QAAQ;AAEnD,wBAAY,QAAQ,KAAK,SAAS,MAAM,GAAG,QAAQ,YAAY,EAAG;AAElE,gBAAI,UAAU,CAAC,MAAM,MAAM;AACzB,qBAAO;AAAA,YACR;AAED,qBACE,OAAO,UAAU,CAAC,MAAM,WAAW,UAAU,CAAC,IAAI,SAAS;AAAA,UAC9D;AAAA,QACF;AAED,eAAO;AAAA,MACR;AAAA,IACF;AAAA,EACF;AAAA;AAWL,SAAS,SAAS,OAAO;AACvB,MAAI,MAAM,QAAQ,KAAK,GAAG;AACxB,WAAO;AAAA,EACR;AAED,MAAI,OAAO,UAAU,UAAU;AAC7B,WAAO,CAAC,UAAU,KAAK;AAAA,EACxB;AAED,SAAO,CAAC,KAAK;AACf;;;;;","x_google_ignoreList":[0]}
@@ -0,0 +1,86 @@
1
+ import { color } from "./color.browser.js";
2
+ import { convert } from "../../unist-util-is/lib/index.js";
3
+ const CONTINUE = true;
4
+ const EXIT = false;
5
+ const SKIP = "skip";
6
+ const visitParents = (
7
+ /**
8
+ * @type {(
9
+ * (<Tree extends Node, Check extends Test>(tree: Tree, test: Check, visitor: BuildVisitor<Tree, Check>, reverse?: boolean | null | undefined) => void) &
10
+ * (<Tree extends Node>(tree: Tree, visitor: BuildVisitor<Tree>, reverse?: boolean | null | undefined) => void)
11
+ * )}
12
+ */
13
+ /**
14
+ * @param {Node} tree
15
+ * @param {Test} test
16
+ * @param {Visitor<Node>} visitor
17
+ * @param {boolean | null | undefined} [reverse]
18
+ * @returns {void}
19
+ */
20
+ function(tree, test, visitor, reverse) {
21
+ if (typeof test === "function" && typeof visitor !== "function") {
22
+ reverse = visitor;
23
+ visitor = test;
24
+ test = null;
25
+ }
26
+ const is = convert(test);
27
+ const step = reverse ? -1 : 1;
28
+ factory(tree, void 0, [])();
29
+ function factory(node, index, parents) {
30
+ const value = node && typeof node === "object" ? node : {};
31
+ if (typeof value.type === "string") {
32
+ const name = (
33
+ // `hast`
34
+ typeof value.tagName === "string" ? value.tagName : (
35
+ // `xast`
36
+ typeof value.name === "string" ? value.name : void 0
37
+ )
38
+ );
39
+ Object.defineProperty(visit, "name", {
40
+ value: "node (" + color(node.type + (name ? "<" + name + ">" : "")) + ")"
41
+ });
42
+ }
43
+ return visit;
44
+ function visit() {
45
+ let result = [];
46
+ let subresult;
47
+ let offset;
48
+ let grandparents;
49
+ if (!test || is(node, index, parents[parents.length - 1] || null)) {
50
+ result = toResult(visitor(node, parents));
51
+ if (result[0] === EXIT) {
52
+ return result;
53
+ }
54
+ }
55
+ if (node.children && result[0] !== SKIP) {
56
+ offset = (reverse ? node.children.length : -1) + step;
57
+ grandparents = parents.concat(node);
58
+ while (offset > -1 && offset < node.children.length) {
59
+ subresult = factory(node.children[offset], offset, grandparents)();
60
+ if (subresult[0] === EXIT) {
61
+ return subresult;
62
+ }
63
+ offset = typeof subresult[1] === "number" ? subresult[1] : offset + step;
64
+ }
65
+ }
66
+ return result;
67
+ }
68
+ }
69
+ }
70
+ );
71
+ function toResult(value) {
72
+ if (Array.isArray(value)) {
73
+ return value;
74
+ }
75
+ if (typeof value === "number") {
76
+ return [CONTINUE, value];
77
+ }
78
+ return [value];
79
+ }
80
+ export {
81
+ CONTINUE,
82
+ EXIT,
83
+ SKIP,
84
+ visitParents
85
+ };
86
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sources":["../../../../../../node_modules/unist-util-visit-parents/lib/index.js"],"sourcesContent":["/**\n * @typedef {import('unist').Node} Node\n * @typedef {import('unist').Parent} Parent\n * @typedef {import('unist-util-is').Test} Test\n */\n\n/**\n * @typedef {boolean | 'skip'} Action\n * Union of the action types.\n *\n * @typedef {number} Index\n * Move to the sibling at `index` next (after node itself is completely\n * traversed).\n *\n * Useful if mutating the tree, such as removing the node the visitor is\n * currently on, or any of its previous siblings.\n * Results less than 0 or greater than or equal to `children.length` stop\n * traversing the parent.\n *\n * @typedef {[(Action | null | undefined | void)?, (Index | null | undefined)?]} ActionTuple\n * List with one or two values, the first an action, the second an index.\n *\n * @typedef {Action | ActionTuple | Index | null | undefined | void} VisitorResult\n * Any value that can be returned from a visitor.\n */\n\n/**\n * @template {Node} [Visited=Node]\n * Visited node type.\n * @template {Parent} [Ancestor=Parent]\n * Ancestor type.\n * @callback Visitor\n * Handle a node (matching `test`, if given).\n *\n * Visitors are free to transform `node`.\n * They can also transform the parent of node (the last of `ancestors`).\n *\n * Replacing `node` itself, if `SKIP` is not returned, still causes its\n * descendants to be walked (which is a bug).\n *\n * When adding or removing previous siblings of `node` (or next siblings, in\n * case of reverse), the `Visitor` should return a new `Index` to specify the\n * sibling to traverse after `node` is traversed.\n * Adding or removing next siblings of `node` (or previous siblings, in case\n * of reverse) is handled as expected without needing to return a new `Index`.\n *\n * Removing the children property of an ancestor still results in them being\n * traversed.\n * @param {Visited} node\n * Found node.\n * @param {Array<Ancestor>} ancestors\n * Ancestors of `node`.\n * @returns {VisitorResult}\n * What to do next.\n *\n * An `Index` is treated as a tuple of `[CONTINUE, Index]`.\n * An `Action` is treated as a tuple of `[Action]`.\n *\n * Passing a tuple back only makes sense if the `Action` is `SKIP`.\n * When the `Action` is `EXIT`, that action can be returned.\n * When the `Action` is `CONTINUE`, `Index` can be returned.\n */\n\n/**\n * @template {Node} [Tree=Node]\n * Tree type.\n * @template {Test} [Check=string]\n * Test type.\n * @typedef {Visitor<import('./complex-types.js').Matches<import('./complex-types.js').InclusiveDescendant<Tree>, Check>, Extract<import('./complex-types.js').InclusiveDescendant<Tree>, Parent>>} BuildVisitor\n * Build a typed `Visitor` function from a tree and a test.\n *\n * It will infer which values are passed as `node` and which as `parents`.\n */\n\nimport {convert} from 'unist-util-is'\nimport {color} from './color.js'\n\n/**\n * Continue traversing as normal.\n */\nexport const CONTINUE = true\n\n/**\n * Stop traversing immediately.\n */\nexport const EXIT = false\n\n/**\n * Do not traverse this node’s children.\n */\nexport const SKIP = 'skip'\n\n/**\n * Visit nodes, with ancestral information.\n *\n * This algorithm performs *depth-first* *tree traversal* in *preorder*\n * (**NLR**) or if `reverse` is given, in *reverse preorder* (**NRL**).\n *\n * You can choose for which nodes `visitor` is called by passing a `test`.\n * For complex tests, you should test yourself in `visitor`, as it will be\n * faster and will have improved type information.\n *\n * Walking the tree is an intensive task.\n * Make use of the return values of the visitor when possible.\n * Instead of walking a tree multiple times, walk it once, use `unist-util-is`\n * to check if a node matches, and then perform different operations.\n *\n * You can change the tree.\n * See `Visitor` for more info.\n *\n * @param tree\n * Tree to traverse.\n * @param test\n * `unist-util-is`-compatible test\n * @param visitor\n * Handle each node.\n * @param reverse\n * Traverse in reverse preorder (NRL) instead of the default preorder (NLR).\n * @returns\n * Nothing.\n */\nexport const visitParents =\n /**\n * @type {(\n * (<Tree extends Node, Check extends Test>(tree: Tree, test: Check, visitor: BuildVisitor<Tree, Check>, reverse?: boolean | null | undefined) => void) &\n * (<Tree extends Node>(tree: Tree, visitor: BuildVisitor<Tree>, reverse?: boolean | null | undefined) => void)\n * )}\n */\n (\n /**\n * @param {Node} tree\n * @param {Test} test\n * @param {Visitor<Node>} visitor\n * @param {boolean | null | undefined} [reverse]\n * @returns {void}\n */\n function (tree, test, visitor, reverse) {\n if (typeof test === 'function' && typeof visitor !== 'function') {\n reverse = visitor\n // @ts-expect-error no visitor given, so `visitor` is test.\n visitor = test\n test = null\n }\n\n const is = convert(test)\n const step = reverse ? -1 : 1\n\n factory(tree, undefined, [])()\n\n /**\n * @param {Node} node\n * @param {number | undefined} index\n * @param {Array<Parent>} parents\n */\n function factory(node, index, parents) {\n /** @type {Record<string, unknown>} */\n // @ts-expect-error: hush\n const value = node && typeof node === 'object' ? node : {}\n\n if (typeof value.type === 'string') {\n const name =\n // `hast`\n typeof value.tagName === 'string'\n ? value.tagName\n : // `xast`\n typeof value.name === 'string'\n ? value.name\n : undefined\n\n Object.defineProperty(visit, 'name', {\n value:\n 'node (' + color(node.type + (name ? '<' + name + '>' : '')) + ')'\n })\n }\n\n return visit\n\n function visit() {\n /** @type {ActionTuple} */\n let result = []\n /** @type {ActionTuple} */\n let subresult\n /** @type {number} */\n let offset\n /** @type {Array<Parent>} */\n let grandparents\n\n if (!test || is(node, index, parents[parents.length - 1] || null)) {\n result = toResult(visitor(node, parents))\n\n if (result[0] === EXIT) {\n return result\n }\n }\n\n // @ts-expect-error looks like a parent.\n if (node.children && result[0] !== SKIP) {\n // @ts-expect-error looks like a parent.\n offset = (reverse ? node.children.length : -1) + step\n // @ts-expect-error looks like a parent.\n grandparents = parents.concat(node)\n\n // @ts-expect-error looks like a parent.\n while (offset > -1 && offset < node.children.length) {\n // @ts-expect-error looks like a parent.\n subresult = factory(node.children[offset], offset, grandparents)()\n\n if (subresult[0] === EXIT) {\n return subresult\n }\n\n offset =\n typeof subresult[1] === 'number' ? subresult[1] : offset + step\n }\n }\n\n return result\n }\n }\n }\n )\n\n/**\n * Turn a return value into a clean result.\n *\n * @param {VisitorResult} value\n * Valid return values from visitors.\n * @returns {ActionTuple}\n * Clean result.\n */\nfunction toResult(value) {\n if (Array.isArray(value)) {\n return value\n }\n\n if (typeof value === 'number') {\n return [CONTINUE, value]\n }\n\n return [value]\n}\n"],"names":[],"mappings":";;AAgFY,MAAC,WAAW;AAKZ,MAAC,OAAO;AAKR,MAAC,OAAO;AA+BR,MAAC;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAeT,SAAU,MAAM,MAAM,SAAS,SAAS;AACtC,QAAI,OAAO,SAAS,cAAc,OAAO,YAAY,YAAY;AAC/D,gBAAU;AAEV,gBAAU;AACV,aAAO;AAAA,IACR;AAED,UAAM,KAAK,QAAQ,IAAI;AACvB,UAAM,OAAO,UAAU,KAAK;AAE5B,YAAQ,MAAM,QAAW,CAAA,CAAE,EAAG;AAO9B,aAAS,QAAQ,MAAM,OAAO,SAAS;AAGrC,YAAM,QAAQ,QAAQ,OAAO,SAAS,WAAW,OAAO,CAAE;AAE1D,UAAI,OAAO,MAAM,SAAS,UAAU;AAClC,cAAM;AAAA;AAAA,UAEJ,OAAO,MAAM,YAAY,WACrB,MAAM;AAAA;AAAA,YAER,OAAO,MAAM,SAAS,WACpB,MAAM,OACN;AAAA;AAAA;AAEN,eAAO,eAAe,OAAO,QAAQ;AAAA,UACnC,OACE,WAAW,MAAM,KAAK,QAAQ,OAAO,MAAM,OAAO,MAAM,GAAG,IAAI;AAAA,QAC7E,CAAW;AAAA,MACF;AAED,aAAO;AAEP,eAAS,QAAQ;AAEf,YAAI,SAAS,CAAE;AAEf,YAAI;AAEJ,YAAI;AAEJ,YAAI;AAEJ,YAAI,CAAC,QAAQ,GAAG,MAAM,OAAO,QAAQ,QAAQ,SAAS,CAAC,KAAK,IAAI,GAAG;AACjE,mBAAS,SAAS,QAAQ,MAAM,OAAO,CAAC;AAExC,cAAI,OAAO,CAAC,MAAM,MAAM;AACtB,mBAAO;AAAA,UACR;AAAA,QACF;AAGD,YAAI,KAAK,YAAY,OAAO,CAAC,MAAM,MAAM;AAEvC,oBAAU,UAAU,KAAK,SAAS,SAAS,MAAM;AAEjD,yBAAe,QAAQ,OAAO,IAAI;AAGlC,iBAAO,SAAS,MAAM,SAAS,KAAK,SAAS,QAAQ;AAEnD,wBAAY,QAAQ,KAAK,SAAS,MAAM,GAAG,QAAQ,YAAY,EAAG;AAElE,gBAAI,UAAU,CAAC,MAAM,MAAM;AACzB,qBAAO;AAAA,YACR;AAED,qBACE,OAAO,UAAU,CAAC,MAAM,WAAW,UAAU,CAAC,IAAI,SAAS;AAAA,UAC9D;AAAA,QACF;AAED,eAAO;AAAA,MACR;AAAA,IACF;AAAA,EACF;AAAA;AAWL,SAAS,SAAS,OAAO;AACvB,MAAI,MAAM,QAAQ,KAAK,GAAG;AACxB,WAAO;AAAA,EACR;AAED,MAAI,OAAO,UAAU,UAAU;AAC7B,WAAO,CAAC,UAAU,KAAK;AAAA,EACxB;AAED,SAAO,CAAC,KAAK;AACf;","x_google_ignoreList":[0]}