@marshulll/openclaw-wecom 0.1.6 → 0.1.8

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 (677) hide show
  1. package/README.en.md +3 -0
  2. package/README.md +3 -0
  3. package/README.zh.md +3 -0
  4. package/docs/INSTALL.md +3 -0
  5. package/node_modules/fast-xml-parser/CHANGELOG.md +606 -0
  6. package/node_modules/fast-xml-parser/LICENSE +21 -0
  7. package/node_modules/fast-xml-parser/README.md +237 -0
  8. package/node_modules/fast-xml-parser/package.json +72 -0
  9. package/node_modules/fast-xml-parser/src/cli/cli.js +93 -0
  10. package/node_modules/fast-xml-parser/src/cli/man.js +12 -0
  11. package/node_modules/fast-xml-parser/src/cli/read.js +92 -0
  12. package/node_modules/fast-xml-parser/src/fxp.d.ts +418 -0
  13. package/node_modules/fast-xml-parser/src/fxp.js +11 -0
  14. package/node_modules/fast-xml-parser/src/ignoreAttributes.js +20 -0
  15. package/node_modules/fast-xml-parser/src/util.js +72 -0
  16. package/node_modules/fast-xml-parser/src/v5/CharsSymbol.js +16 -0
  17. package/node_modules/fast-xml-parser/src/v5/EntitiesParser.js +107 -0
  18. package/node_modules/fast-xml-parser/src/v5/OptionsBuilder.js +64 -0
  19. package/node_modules/fast-xml-parser/src/v5/OutputBuilders/BaseOutputBuilder.js +71 -0
  20. package/node_modules/fast-xml-parser/src/v5/OutputBuilders/JsArrBuilder.js +103 -0
  21. package/node_modules/fast-xml-parser/src/v5/OutputBuilders/JsMinArrBuilder.js +102 -0
  22. package/node_modules/fast-xml-parser/src/v5/OutputBuilders/JsObjBuilder.js +156 -0
  23. package/node_modules/fast-xml-parser/src/v5/OutputBuilders/ParserOptionsBuilder.js +99 -0
  24. package/node_modules/fast-xml-parser/src/v5/Report.js +0 -0
  25. package/node_modules/fast-xml-parser/src/v5/TagPath.js +81 -0
  26. package/node_modules/fast-xml-parser/src/v5/TagPathMatcher.js +15 -0
  27. package/node_modules/fast-xml-parser/src/v5/XMLParser.js +85 -0
  28. package/node_modules/fast-xml-parser/src/v5/Xml2JsParser.js +237 -0
  29. package/node_modules/fast-xml-parser/src/v5/XmlPartReader.js +216 -0
  30. package/node_modules/fast-xml-parser/src/v5/XmlSpecialTagsReader.js +118 -0
  31. package/node_modules/fast-xml-parser/src/v5/inputSource/BufferSource.js +118 -0
  32. package/node_modules/fast-xml-parser/src/v5/inputSource/StringSource.js +123 -0
  33. package/node_modules/fast-xml-parser/src/v5/valueParsers/EntitiesParser.js +107 -0
  34. package/node_modules/fast-xml-parser/src/v5/valueParsers/booleanParser.js +23 -0
  35. package/node_modules/fast-xml-parser/src/v5/valueParsers/booleanParserExt.js +20 -0
  36. package/node_modules/fast-xml-parser/src/v5/valueParsers/currency.js +40 -0
  37. package/node_modules/fast-xml-parser/src/v5/valueParsers/join.js +14 -0
  38. package/node_modules/fast-xml-parser/src/v5/valueParsers/number.js +16 -0
  39. package/node_modules/fast-xml-parser/src/v5/valueParsers/trim.js +8 -0
  40. package/node_modules/fast-xml-parser/src/v6/CharsSymbol.js +16 -0
  41. package/node_modules/fast-xml-parser/src/v6/EntitiesParser.js +104 -0
  42. package/node_modules/fast-xml-parser/src/v6/OptionsBuilder.js +61 -0
  43. package/node_modules/fast-xml-parser/src/v6/OutputBuilders/BaseOutputBuilder.js +69 -0
  44. package/node_modules/fast-xml-parser/src/v6/OutputBuilders/JsArrBuilder.js +103 -0
  45. package/node_modules/fast-xml-parser/src/v6/OutputBuilders/JsMinArrBuilder.js +100 -0
  46. package/node_modules/fast-xml-parser/src/v6/OutputBuilders/JsObjBuilder.js +154 -0
  47. package/node_modules/fast-xml-parser/src/v6/OutputBuilders/ParserOptionsBuilder.js +94 -0
  48. package/node_modules/fast-xml-parser/src/v6/Report.js +0 -0
  49. package/node_modules/fast-xml-parser/src/v6/TagPath.js +81 -0
  50. package/node_modules/fast-xml-parser/src/v6/TagPathMatcher.js +13 -0
  51. package/node_modules/fast-xml-parser/src/v6/XMLParser.js +83 -0
  52. package/node_modules/fast-xml-parser/src/v6/Xml2JsParser.js +235 -0
  53. package/node_modules/fast-xml-parser/src/v6/XmlPartReader.js +210 -0
  54. package/node_modules/fast-xml-parser/src/v6/XmlSpecialTagsReader.js +111 -0
  55. package/node_modules/fast-xml-parser/src/v6/inputSource/BufferSource.js +116 -0
  56. package/node_modules/fast-xml-parser/src/v6/inputSource/StringSource.js +121 -0
  57. package/node_modules/fast-xml-parser/src/v6/valueParsers/EntitiesParser.js +105 -0
  58. package/node_modules/fast-xml-parser/src/v6/valueParsers/booleanParser.js +22 -0
  59. package/node_modules/fast-xml-parser/src/v6/valueParsers/booleanParserExt.js +19 -0
  60. package/node_modules/fast-xml-parser/src/v6/valueParsers/currency.js +38 -0
  61. package/node_modules/fast-xml-parser/src/v6/valueParsers/join.js +13 -0
  62. package/node_modules/fast-xml-parser/src/v6/valueParsers/number.js +14 -0
  63. package/node_modules/fast-xml-parser/src/v6/valueParsers/trim.js +6 -0
  64. package/node_modules/fast-xml-parser/src/validator.js +425 -0
  65. package/node_modules/fast-xml-parser/src/xmlbuilder/json2xml.js +286 -0
  66. package/node_modules/fast-xml-parser/src/xmlbuilder/orderedJs2Xml.js +135 -0
  67. package/node_modules/fast-xml-parser/src/xmlbuilder/prettifyJs2Xml.js +0 -0
  68. package/node_modules/fast-xml-parser/src/xmlparser/DocTypeReader.js +153 -0
  69. package/node_modules/fast-xml-parser/src/xmlparser/OptionsBuilder.js +48 -0
  70. package/node_modules/fast-xml-parser/src/xmlparser/OrderedObjParser.js +606 -0
  71. package/node_modules/fast-xml-parser/src/xmlparser/XMLParser.js +58 -0
  72. package/node_modules/fast-xml-parser/src/xmlparser/node2json.js +113 -0
  73. package/node_modules/fast-xml-parser/src/xmlparser/xmlNode.js +25 -0
  74. package/node_modules/strnum/.vscode/launch.json +25 -0
  75. package/node_modules/strnum/CHANGELOG.md +22 -0
  76. package/node_modules/strnum/LICENSE +21 -0
  77. package/node_modules/strnum/README.md +97 -0
  78. package/node_modules/strnum/package.json +30 -0
  79. package/node_modules/strnum/strnum.js +111 -0
  80. package/node_modules/strnum/strnum.test.js +165 -0
  81. package/node_modules/zod/LICENSE +21 -0
  82. package/node_modules/zod/README.md +208 -0
  83. package/node_modules/zod/index.cjs +33 -0
  84. package/node_modules/zod/index.d.cts +4 -0
  85. package/node_modules/zod/index.d.ts +4 -0
  86. package/node_modules/zod/index.js +4 -0
  87. package/node_modules/zod/package.json +118 -0
  88. package/node_modules/zod/src/index.ts +4 -0
  89. package/node_modules/zod/src/v3/ZodError.ts +330 -0
  90. package/node_modules/zod/src/v3/benchmarks/datetime.ts +58 -0
  91. package/node_modules/zod/src/v3/benchmarks/discriminatedUnion.ts +80 -0
  92. package/node_modules/zod/src/v3/benchmarks/index.ts +59 -0
  93. package/node_modules/zod/src/v3/benchmarks/ipv4.ts +57 -0
  94. package/node_modules/zod/src/v3/benchmarks/object.ts +69 -0
  95. package/node_modules/zod/src/v3/benchmarks/primitives.ts +162 -0
  96. package/node_modules/zod/src/v3/benchmarks/realworld.ts +63 -0
  97. package/node_modules/zod/src/v3/benchmarks/string.ts +55 -0
  98. package/node_modules/zod/src/v3/benchmarks/union.ts +80 -0
  99. package/node_modules/zod/src/v3/errors.ts +13 -0
  100. package/node_modules/zod/src/v3/external.ts +6 -0
  101. package/node_modules/zod/src/v3/helpers/enumUtil.ts +17 -0
  102. package/node_modules/zod/src/v3/helpers/errorUtil.ts +8 -0
  103. package/node_modules/zod/src/v3/helpers/parseUtil.ts +176 -0
  104. package/node_modules/zod/src/v3/helpers/partialUtil.ts +34 -0
  105. package/node_modules/zod/src/v3/helpers/typeAliases.ts +2 -0
  106. package/node_modules/zod/src/v3/helpers/util.ts +224 -0
  107. package/node_modules/zod/src/v3/index.ts +4 -0
  108. package/node_modules/zod/src/v3/locales/en.ts +124 -0
  109. package/node_modules/zod/src/v3/standard-schema.ts +113 -0
  110. package/node_modules/zod/src/v3/tests/Mocker.ts +54 -0
  111. package/node_modules/zod/src/v3/tests/all-errors.test.ts +157 -0
  112. package/node_modules/zod/src/v3/tests/anyunknown.test.ts +28 -0
  113. package/node_modules/zod/src/v3/tests/array.test.ts +71 -0
  114. package/node_modules/zod/src/v3/tests/async-parsing.test.ts +388 -0
  115. package/node_modules/zod/src/v3/tests/async-refinements.test.ts +46 -0
  116. package/node_modules/zod/src/v3/tests/base.test.ts +29 -0
  117. package/node_modules/zod/src/v3/tests/bigint.test.ts +55 -0
  118. package/node_modules/zod/src/v3/tests/branded.test.ts +53 -0
  119. package/node_modules/zod/src/v3/tests/catch.test.ts +220 -0
  120. package/node_modules/zod/src/v3/tests/coerce.test.ts +133 -0
  121. package/node_modules/zod/src/v3/tests/complex.test.ts +56 -0
  122. package/node_modules/zod/src/v3/tests/custom.test.ts +31 -0
  123. package/node_modules/zod/src/v3/tests/date.test.ts +32 -0
  124. package/node_modules/zod/src/v3/tests/deepmasking.test.ts +186 -0
  125. package/node_modules/zod/src/v3/tests/default.test.ts +112 -0
  126. package/node_modules/zod/src/v3/tests/description.test.ts +33 -0
  127. package/node_modules/zod/src/v3/tests/discriminated-unions.test.ts +315 -0
  128. package/node_modules/zod/src/v3/tests/enum.test.ts +80 -0
  129. package/node_modules/zod/src/v3/tests/error.test.ts +551 -0
  130. package/node_modules/zod/src/v3/tests/firstparty.test.ts +87 -0
  131. package/node_modules/zod/src/v3/tests/firstpartyschematypes.test.ts +21 -0
  132. package/node_modules/zod/src/v3/tests/function.test.ts +257 -0
  133. package/node_modules/zod/src/v3/tests/generics.test.ts +48 -0
  134. package/node_modules/zod/src/v3/tests/instanceof.test.ts +37 -0
  135. package/node_modules/zod/src/v3/tests/intersection.test.ts +110 -0
  136. package/node_modules/zod/src/v3/tests/language-server.source.ts +76 -0
  137. package/node_modules/zod/src/v3/tests/language-server.test.ts +207 -0
  138. package/node_modules/zod/src/v3/tests/literal.test.ts +36 -0
  139. package/node_modules/zod/src/v3/tests/map.test.ts +110 -0
  140. package/node_modules/zod/src/v3/tests/masking.test.ts +4 -0
  141. package/node_modules/zod/src/v3/tests/mocker.test.ts +19 -0
  142. package/node_modules/zod/src/v3/tests/nan.test.ts +21 -0
  143. package/node_modules/zod/src/v3/tests/nativeEnum.test.ts +87 -0
  144. package/node_modules/zod/src/v3/tests/nullable.test.ts +42 -0
  145. package/node_modules/zod/src/v3/tests/number.test.ts +176 -0
  146. package/node_modules/zod/src/v3/tests/object-augmentation.test.ts +29 -0
  147. package/node_modules/zod/src/v3/tests/object-in-es5-env.test.ts +29 -0
  148. package/node_modules/zod/src/v3/tests/object.test.ts +434 -0
  149. package/node_modules/zod/src/v3/tests/optional.test.ts +42 -0
  150. package/node_modules/zod/src/v3/tests/parseUtil.test.ts +23 -0
  151. package/node_modules/zod/src/v3/tests/parser.test.ts +41 -0
  152. package/node_modules/zod/src/v3/tests/partials.test.ts +243 -0
  153. package/node_modules/zod/src/v3/tests/pickomit.test.ts +111 -0
  154. package/node_modules/zod/src/v3/tests/pipeline.test.ts +29 -0
  155. package/node_modules/zod/src/v3/tests/preprocess.test.ts +186 -0
  156. package/node_modules/zod/src/v3/tests/primitive.test.ts +440 -0
  157. package/node_modules/zod/src/v3/tests/promise.test.ts +90 -0
  158. package/node_modules/zod/src/v3/tests/readonly.test.ts +194 -0
  159. package/node_modules/zod/src/v3/tests/record.test.ts +171 -0
  160. package/node_modules/zod/src/v3/tests/recursive.test.ts +197 -0
  161. package/node_modules/zod/src/v3/tests/refine.test.ts +313 -0
  162. package/node_modules/zod/src/v3/tests/safeparse.test.ts +27 -0
  163. package/node_modules/zod/src/v3/tests/set.test.ts +142 -0
  164. package/node_modules/zod/src/v3/tests/standard-schema.test.ts +83 -0
  165. package/node_modules/zod/src/v3/tests/string.test.ts +916 -0
  166. package/node_modules/zod/src/v3/tests/transformer.test.ts +233 -0
  167. package/node_modules/zod/src/v3/tests/tuple.test.ts +90 -0
  168. package/node_modules/zod/src/v3/tests/unions.test.ts +57 -0
  169. package/node_modules/zod/src/v3/tests/validations.test.ts +133 -0
  170. package/node_modules/zod/src/v3/tests/void.test.ts +15 -0
  171. package/node_modules/zod/src/v3/types.ts +5136 -0
  172. package/node_modules/zod/src/v4/classic/checks.ts +30 -0
  173. package/node_modules/zod/src/v4/classic/coerce.ts +27 -0
  174. package/node_modules/zod/src/v4/classic/compat.ts +66 -0
  175. package/node_modules/zod/src/v4/classic/errors.ts +75 -0
  176. package/node_modules/zod/src/v4/classic/external.ts +50 -0
  177. package/node_modules/zod/src/v4/classic/index.ts +5 -0
  178. package/node_modules/zod/src/v4/classic/iso.ts +90 -0
  179. package/node_modules/zod/src/v4/classic/parse.ts +33 -0
  180. package/node_modules/zod/src/v4/classic/schemas.ts +2054 -0
  181. package/node_modules/zod/src/v4/classic/tests/anyunknown.test.ts +26 -0
  182. package/node_modules/zod/src/v4/classic/tests/array.test.ts +264 -0
  183. package/node_modules/zod/src/v4/classic/tests/assignability.test.ts +210 -0
  184. package/node_modules/zod/src/v4/classic/tests/async-parsing.test.ts +381 -0
  185. package/node_modules/zod/src/v4/classic/tests/async-refinements.test.ts +68 -0
  186. package/node_modules/zod/src/v4/classic/tests/base.test.ts +7 -0
  187. package/node_modules/zod/src/v4/classic/tests/bigint.test.ts +54 -0
  188. package/node_modules/zod/src/v4/classic/tests/brand.test.ts +63 -0
  189. package/node_modules/zod/src/v4/classic/tests/catch.test.ts +252 -0
  190. package/node_modules/zod/src/v4/classic/tests/coalesce.test.ts +20 -0
  191. package/node_modules/zod/src/v4/classic/tests/coerce.test.ts +160 -0
  192. package/node_modules/zod/src/v4/classic/tests/continuability.test.ts +352 -0
  193. package/node_modules/zod/src/v4/classic/tests/custom.test.ts +40 -0
  194. package/node_modules/zod/src/v4/classic/tests/date.test.ts +31 -0
  195. package/node_modules/zod/src/v4/classic/tests/datetime.test.ts +296 -0
  196. package/node_modules/zod/src/v4/classic/tests/default.test.ts +313 -0
  197. package/node_modules/zod/src/v4/classic/tests/description.test.ts +32 -0
  198. package/node_modules/zod/src/v4/classic/tests/discriminated-unions.test.ts +619 -0
  199. package/node_modules/zod/src/v4/classic/tests/enum.test.ts +285 -0
  200. package/node_modules/zod/src/v4/classic/tests/error-utils.test.ts +527 -0
  201. package/node_modules/zod/src/v4/classic/tests/error.test.ts +711 -0
  202. package/node_modules/zod/src/v4/classic/tests/file.test.ts +91 -0
  203. package/node_modules/zod/src/v4/classic/tests/firstparty.test.ts +175 -0
  204. package/node_modules/zod/src/v4/classic/tests/function.test.ts +268 -0
  205. package/node_modules/zod/src/v4/classic/tests/generics.test.ts +72 -0
  206. package/node_modules/zod/src/v4/classic/tests/index.test.ts +829 -0
  207. package/node_modules/zod/src/v4/classic/tests/instanceof.test.ts +34 -0
  208. package/node_modules/zod/src/v4/classic/tests/intersection.test.ts +171 -0
  209. package/node_modules/zod/src/v4/classic/tests/json.test.ts +108 -0
  210. package/node_modules/zod/src/v4/classic/tests/lazy.test.ts +227 -0
  211. package/node_modules/zod/src/v4/classic/tests/literal.test.ts +92 -0
  212. package/node_modules/zod/src/v4/classic/tests/map.test.ts +196 -0
  213. package/node_modules/zod/src/v4/classic/tests/nan.test.ts +21 -0
  214. package/node_modules/zod/src/v4/classic/tests/nested-refine.test.ts +168 -0
  215. package/node_modules/zod/src/v4/classic/tests/nonoptional.test.ts +86 -0
  216. package/node_modules/zod/src/v4/classic/tests/nullable.test.ts +22 -0
  217. package/node_modules/zod/src/v4/classic/tests/number.test.ts +247 -0
  218. package/node_modules/zod/src/v4/classic/tests/object.test.ts +563 -0
  219. package/node_modules/zod/src/v4/classic/tests/optional.test.ts +123 -0
  220. package/node_modules/zod/src/v4/classic/tests/partial.test.ts +147 -0
  221. package/node_modules/zod/src/v4/classic/tests/pickomit.test.ts +127 -0
  222. package/node_modules/zod/src/v4/classic/tests/pipe.test.ts +81 -0
  223. package/node_modules/zod/src/v4/classic/tests/prefault.test.ts +37 -0
  224. package/node_modules/zod/src/v4/classic/tests/preprocess.test.ts +298 -0
  225. package/node_modules/zod/src/v4/classic/tests/primitive.test.ts +175 -0
  226. package/node_modules/zod/src/v4/classic/tests/promise.test.ts +81 -0
  227. package/node_modules/zod/src/v4/classic/tests/prototypes.test.ts +23 -0
  228. package/node_modules/zod/src/v4/classic/tests/readonly.test.ts +252 -0
  229. package/node_modules/zod/src/v4/classic/tests/record.test.ts +342 -0
  230. package/node_modules/zod/src/v4/classic/tests/recursive-types.test.ts +356 -0
  231. package/node_modules/zod/src/v4/classic/tests/refine.test.ts +532 -0
  232. package/node_modules/zod/src/v4/classic/tests/registries.test.ts +204 -0
  233. package/node_modules/zod/src/v4/classic/tests/set.test.ts +179 -0
  234. package/node_modules/zod/src/v4/classic/tests/standard-schema.test.ts +57 -0
  235. package/node_modules/zod/src/v4/classic/tests/string-formats.test.ts +109 -0
  236. package/node_modules/zod/src/v4/classic/tests/string.test.ts +881 -0
  237. package/node_modules/zod/src/v4/classic/tests/stringbool.test.ts +66 -0
  238. package/node_modules/zod/src/v4/classic/tests/template-literal.test.ts +758 -0
  239. package/node_modules/zod/src/v4/classic/tests/to-json-schema.test.ts +2314 -0
  240. package/node_modules/zod/src/v4/classic/tests/transform.test.ts +250 -0
  241. package/node_modules/zod/src/v4/classic/tests/tuple.test.ts +163 -0
  242. package/node_modules/zod/src/v4/classic/tests/union.test.ts +94 -0
  243. package/node_modules/zod/src/v4/classic/tests/validations.test.ts +283 -0
  244. package/node_modules/zod/src/v4/classic/tests/void.test.ts +12 -0
  245. package/node_modules/zod/src/v4/core/api.ts +1594 -0
  246. package/node_modules/zod/src/v4/core/checks.ts +1283 -0
  247. package/node_modules/zod/src/v4/core/config.ts +15 -0
  248. package/node_modules/zod/src/v4/core/core.ts +134 -0
  249. package/node_modules/zod/src/v4/core/doc.ts +44 -0
  250. package/node_modules/zod/src/v4/core/errors.ts +424 -0
  251. package/node_modules/zod/src/v4/core/function.ts +176 -0
  252. package/node_modules/zod/src/v4/core/index.ts +15 -0
  253. package/node_modules/zod/src/v4/core/json-schema.ts +143 -0
  254. package/node_modules/zod/src/v4/core/parse.ts +94 -0
  255. package/node_modules/zod/src/v4/core/regexes.ts +135 -0
  256. package/node_modules/zod/src/v4/core/registries.ts +96 -0
  257. package/node_modules/zod/src/v4/core/schemas.ts +3842 -0
  258. package/node_modules/zod/src/v4/core/standard-schema.ts +64 -0
  259. package/node_modules/zod/src/v4/core/tests/index.test.ts +46 -0
  260. package/node_modules/zod/src/v4/core/tests/locales/be.test.ts +124 -0
  261. package/node_modules/zod/src/v4/core/tests/locales/en.test.ts +22 -0
  262. package/node_modules/zod/src/v4/core/tests/locales/ru.test.ts +128 -0
  263. package/node_modules/zod/src/v4/core/tests/locales/tr.test.ts +69 -0
  264. package/node_modules/zod/src/v4/core/to-json-schema.ts +977 -0
  265. package/node_modules/zod/src/v4/core/util.ts +775 -0
  266. package/node_modules/zod/src/v4/core/versions.ts +5 -0
  267. package/node_modules/zod/src/v4/core/zsf.ts +323 -0
  268. package/node_modules/zod/src/v4/index.ts +4 -0
  269. package/node_modules/zod/src/v4/locales/ar.ts +125 -0
  270. package/node_modules/zod/src/v4/locales/az.ts +121 -0
  271. package/node_modules/zod/src/v4/locales/be.ts +184 -0
  272. package/node_modules/zod/src/v4/locales/ca.ts +127 -0
  273. package/node_modules/zod/src/v4/locales/cs.ts +142 -0
  274. package/node_modules/zod/src/v4/locales/de.ts +124 -0
  275. package/node_modules/zod/src/v4/locales/en.ts +127 -0
  276. package/node_modules/zod/src/v4/locales/eo.ts +125 -0
  277. package/node_modules/zod/src/v4/locales/es.ts +125 -0
  278. package/node_modules/zod/src/v4/locales/fa.ts +134 -0
  279. package/node_modules/zod/src/v4/locales/fi.ts +131 -0
  280. package/node_modules/zod/src/v4/locales/fr-CA.ts +126 -0
  281. package/node_modules/zod/src/v4/locales/fr.ts +124 -0
  282. package/node_modules/zod/src/v4/locales/he.ts +125 -0
  283. package/node_modules/zod/src/v4/locales/hu.ts +126 -0
  284. package/node_modules/zod/src/v4/locales/id.ts +125 -0
  285. package/node_modules/zod/src/v4/locales/index.ts +39 -0
  286. package/node_modules/zod/src/v4/locales/it.ts +125 -0
  287. package/node_modules/zod/src/v4/locales/ja.ts +122 -0
  288. package/node_modules/zod/src/v4/locales/kh.ts +126 -0
  289. package/node_modules/zod/src/v4/locales/ko.ts +131 -0
  290. package/node_modules/zod/src/v4/locales/mk.ts +127 -0
  291. package/node_modules/zod/src/v4/locales/ms.ts +124 -0
  292. package/node_modules/zod/src/v4/locales/nl.ts +126 -0
  293. package/node_modules/zod/src/v4/locales/no.ts +124 -0
  294. package/node_modules/zod/src/v4/locales/ota.ts +125 -0
  295. package/node_modules/zod/src/v4/locales/pl.ts +126 -0
  296. package/node_modules/zod/src/v4/locales/ps.ts +133 -0
  297. package/node_modules/zod/src/v4/locales/pt.ts +123 -0
  298. package/node_modules/zod/src/v4/locales/ru.ts +184 -0
  299. package/node_modules/zod/src/v4/locales/sl.ts +126 -0
  300. package/node_modules/zod/src/v4/locales/sv.ts +127 -0
  301. package/node_modules/zod/src/v4/locales/ta.ts +125 -0
  302. package/node_modules/zod/src/v4/locales/th.ts +126 -0
  303. package/node_modules/zod/src/v4/locales/tr.ts +121 -0
  304. package/node_modules/zod/src/v4/locales/ua.ts +126 -0
  305. package/node_modules/zod/src/v4/locales/ur.ts +126 -0
  306. package/node_modules/zod/src/v4/locales/vi.ts +125 -0
  307. package/node_modules/zod/src/v4/locales/zh-CN.ts +123 -0
  308. package/node_modules/zod/src/v4/locales/zh-TW.ts +125 -0
  309. package/node_modules/zod/src/v4/mini/checks.ts +32 -0
  310. package/node_modules/zod/src/v4/mini/coerce.ts +22 -0
  311. package/node_modules/zod/src/v4/mini/external.ts +40 -0
  312. package/node_modules/zod/src/v4/mini/index.ts +3 -0
  313. package/node_modules/zod/src/v4/mini/iso.ts +62 -0
  314. package/node_modules/zod/src/v4/mini/parse.ts +1 -0
  315. package/node_modules/zod/src/v4/mini/schemas.ts +1579 -0
  316. package/node_modules/zod/src/v4/mini/tests/assignability.test.ts +129 -0
  317. package/node_modules/zod/src/v4/mini/tests/brand.test.ts +51 -0
  318. package/node_modules/zod/src/v4/mini/tests/checks.test.ts +144 -0
  319. package/node_modules/zod/src/v4/mini/tests/computed.test.ts +36 -0
  320. package/node_modules/zod/src/v4/mini/tests/error.test.ts +22 -0
  321. package/node_modules/zod/src/v4/mini/tests/functions.test.ts +43 -0
  322. package/node_modules/zod/src/v4/mini/tests/index.test.ts +871 -0
  323. package/node_modules/zod/src/v4/mini/tests/number.test.ts +95 -0
  324. package/node_modules/zod/src/v4/mini/tests/object.test.ts +185 -0
  325. package/node_modules/zod/src/v4/mini/tests/prototypes.test.ts +43 -0
  326. package/node_modules/zod/src/v4/mini/tests/recursive-types.test.ts +275 -0
  327. package/node_modules/zod/src/v4/mini/tests/string.test.ts +299 -0
  328. package/node_modules/zod/src/v4-mini/index.ts +1 -0
  329. package/node_modules/zod/v3/ZodError.cjs +138 -0
  330. package/node_modules/zod/v3/ZodError.d.cts +164 -0
  331. package/node_modules/zod/v3/ZodError.d.ts +164 -0
  332. package/node_modules/zod/v3/ZodError.js +133 -0
  333. package/node_modules/zod/v3/errors.cjs +17 -0
  334. package/node_modules/zod/v3/errors.d.cts +5 -0
  335. package/node_modules/zod/v3/errors.d.ts +5 -0
  336. package/node_modules/zod/v3/errors.js +9 -0
  337. package/node_modules/zod/v3/external.cjs +22 -0
  338. package/node_modules/zod/v3/external.d.cts +6 -0
  339. package/node_modules/zod/v3/external.d.ts +6 -0
  340. package/node_modules/zod/v3/external.js +6 -0
  341. package/node_modules/zod/v3/helpers/enumUtil.cjs +2 -0
  342. package/node_modules/zod/v3/helpers/enumUtil.d.cts +8 -0
  343. package/node_modules/zod/v3/helpers/enumUtil.d.ts +8 -0
  344. package/node_modules/zod/v3/helpers/enumUtil.js +1 -0
  345. package/node_modules/zod/v3/helpers/errorUtil.cjs +9 -0
  346. package/node_modules/zod/v3/helpers/errorUtil.d.cts +9 -0
  347. package/node_modules/zod/v3/helpers/errorUtil.d.ts +9 -0
  348. package/node_modules/zod/v3/helpers/errorUtil.js +6 -0
  349. package/node_modules/zod/v3/helpers/parseUtil.cjs +124 -0
  350. package/node_modules/zod/v3/helpers/parseUtil.d.cts +78 -0
  351. package/node_modules/zod/v3/helpers/parseUtil.d.ts +78 -0
  352. package/node_modules/zod/v3/helpers/parseUtil.js +109 -0
  353. package/node_modules/zod/v3/helpers/partialUtil.cjs +2 -0
  354. package/node_modules/zod/v3/helpers/partialUtil.d.cts +8 -0
  355. package/node_modules/zod/v3/helpers/partialUtil.d.ts +8 -0
  356. package/node_modules/zod/v3/helpers/partialUtil.js +1 -0
  357. package/node_modules/zod/v3/helpers/typeAliases.cjs +2 -0
  358. package/node_modules/zod/v3/helpers/typeAliases.d.cts +2 -0
  359. package/node_modules/zod/v3/helpers/typeAliases.d.ts +2 -0
  360. package/node_modules/zod/v3/helpers/typeAliases.js +1 -0
  361. package/node_modules/zod/v3/helpers/util.cjs +137 -0
  362. package/node_modules/zod/v3/helpers/util.d.cts +85 -0
  363. package/node_modules/zod/v3/helpers/util.d.ts +85 -0
  364. package/node_modules/zod/v3/helpers/util.js +133 -0
  365. package/node_modules/zod/v3/index.cjs +33 -0
  366. package/node_modules/zod/v3/index.d.cts +4 -0
  367. package/node_modules/zod/v3/index.d.ts +4 -0
  368. package/node_modules/zod/v3/index.js +4 -0
  369. package/node_modules/zod/v3/locales/en.cjs +111 -0
  370. package/node_modules/zod/v3/locales/en.d.cts +3 -0
  371. package/node_modules/zod/v3/locales/en.d.ts +3 -0
  372. package/node_modules/zod/v3/locales/en.js +109 -0
  373. package/node_modules/zod/v3/standard-schema.cjs +2 -0
  374. package/node_modules/zod/v3/standard-schema.d.cts +102 -0
  375. package/node_modules/zod/v3/standard-schema.d.ts +102 -0
  376. package/node_modules/zod/v3/standard-schema.js +1 -0
  377. package/node_modules/zod/v3/types.cjs +3775 -0
  378. package/node_modules/zod/v3/types.d.cts +1031 -0
  379. package/node_modules/zod/v3/types.d.ts +1031 -0
  380. package/node_modules/zod/v3/types.js +3693 -0
  381. package/node_modules/zod/v4/classic/checks.cjs +32 -0
  382. package/node_modules/zod/v4/classic/checks.d.cts +1 -0
  383. package/node_modules/zod/v4/classic/checks.d.ts +1 -0
  384. package/node_modules/zod/v4/classic/checks.js +1 -0
  385. package/node_modules/zod/v4/classic/coerce.cjs +47 -0
  386. package/node_modules/zod/v4/classic/coerce.d.cts +17 -0
  387. package/node_modules/zod/v4/classic/coerce.d.ts +17 -0
  388. package/node_modules/zod/v4/classic/coerce.js +17 -0
  389. package/node_modules/zod/v4/classic/compat.cjs +57 -0
  390. package/node_modules/zod/v4/classic/compat.d.cts +46 -0
  391. package/node_modules/zod/v4/classic/compat.d.ts +46 -0
  392. package/node_modules/zod/v4/classic/compat.js +27 -0
  393. package/node_modules/zod/v4/classic/errors.cjs +67 -0
  394. package/node_modules/zod/v4/classic/errors.d.cts +30 -0
  395. package/node_modules/zod/v4/classic/errors.d.ts +30 -0
  396. package/node_modules/zod/v4/classic/errors.js +41 -0
  397. package/node_modules/zod/v4/classic/external.cjs +70 -0
  398. package/node_modules/zod/v4/classic/external.d.cts +13 -0
  399. package/node_modules/zod/v4/classic/external.d.ts +13 -0
  400. package/node_modules/zod/v4/classic/external.js +18 -0
  401. package/node_modules/zod/v4/classic/index.cjs +33 -0
  402. package/node_modules/zod/v4/classic/index.d.cts +4 -0
  403. package/node_modules/zod/v4/classic/index.d.ts +4 -0
  404. package/node_modules/zod/v4/classic/index.js +4 -0
  405. package/node_modules/zod/v4/classic/iso.cjs +60 -0
  406. package/node_modules/zod/v4/classic/iso.d.cts +22 -0
  407. package/node_modules/zod/v4/classic/iso.d.ts +22 -0
  408. package/node_modules/zod/v4/classic/iso.js +30 -0
  409. package/node_modules/zod/v4/classic/parse.cjs +32 -0
  410. package/node_modules/zod/v4/classic/parse.d.cts +23 -0
  411. package/node_modules/zod/v4/classic/parse.d.ts +23 -0
  412. package/node_modules/zod/v4/classic/parse.js +6 -0
  413. package/node_modules/zod/v4/classic/schemas.cjs +1109 -0
  414. package/node_modules/zod/v4/classic/schemas.d.cts +630 -0
  415. package/node_modules/zod/v4/classic/schemas.d.ts +630 -0
  416. package/node_modules/zod/v4/classic/schemas.js +1006 -0
  417. package/node_modules/zod/v4/core/api.cjs +1039 -0
  418. package/node_modules/zod/v4/core/api.d.cts +284 -0
  419. package/node_modules/zod/v4/core/api.d.ts +284 -0
  420. package/node_modules/zod/v4/core/api.js +906 -0
  421. package/node_modules/zod/v4/core/checks.cjs +591 -0
  422. package/node_modules/zod/v4/core/checks.d.cts +278 -0
  423. package/node_modules/zod/v4/core/checks.d.ts +278 -0
  424. package/node_modules/zod/v4/core/checks.js +565 -0
  425. package/node_modules/zod/v4/core/core.cjs +67 -0
  426. package/node_modules/zod/v4/core/core.d.cts +49 -0
  427. package/node_modules/zod/v4/core/core.d.ts +49 -0
  428. package/node_modules/zod/v4/core/core.js +61 -0
  429. package/node_modules/zod/v4/core/doc.cjs +39 -0
  430. package/node_modules/zod/v4/core/doc.d.cts +14 -0
  431. package/node_modules/zod/v4/core/doc.d.ts +14 -0
  432. package/node_modules/zod/v4/core/doc.js +35 -0
  433. package/node_modules/zod/v4/core/errors.cjs +226 -0
  434. package/node_modules/zod/v4/core/errors.d.cts +208 -0
  435. package/node_modules/zod/v4/core/errors.d.ts +208 -0
  436. package/node_modules/zod/v4/core/errors.js +195 -0
  437. package/node_modules/zod/v4/core/function.cjs +102 -0
  438. package/node_modules/zod/v4/core/function.d.cts +52 -0
  439. package/node_modules/zod/v4/core/function.d.ts +52 -0
  440. package/node_modules/zod/v4/core/function.js +75 -0
  441. package/node_modules/zod/v4/core/index.cjs +44 -0
  442. package/node_modules/zod/v4/core/index.d.cts +15 -0
  443. package/node_modules/zod/v4/core/index.d.ts +15 -0
  444. package/node_modules/zod/v4/core/index.js +15 -0
  445. package/node_modules/zod/v4/core/json-schema.cjs +2 -0
  446. package/node_modules/zod/v4/core/json-schema.d.cts +87 -0
  447. package/node_modules/zod/v4/core/json-schema.d.ts +87 -0
  448. package/node_modules/zod/v4/core/json-schema.js +1 -0
  449. package/node_modules/zod/v4/core/parse.cjs +87 -0
  450. package/node_modules/zod/v4/core/parse.d.cts +25 -0
  451. package/node_modules/zod/v4/core/parse.d.ts +25 -0
  452. package/node_modules/zod/v4/core/parse.js +57 -0
  453. package/node_modules/zod/v4/core/regexes.cjs +103 -0
  454. package/node_modules/zod/v4/core/regexes.d.cts +62 -0
  455. package/node_modules/zod/v4/core/regexes.d.ts +62 -0
  456. package/node_modules/zod/v4/core/regexes.js +95 -0
  457. package/node_modules/zod/v4/core/registries.cjs +56 -0
  458. package/node_modules/zod/v4/core/registries.d.cts +35 -0
  459. package/node_modules/zod/v4/core/registries.d.ts +35 -0
  460. package/node_modules/zod/v4/core/registries.js +51 -0
  461. package/node_modules/zod/v4/core/schemas.cjs +1748 -0
  462. package/node_modules/zod/v4/core/schemas.d.cts +1041 -0
  463. package/node_modules/zod/v4/core/schemas.d.ts +1041 -0
  464. package/node_modules/zod/v4/core/schemas.js +1717 -0
  465. package/node_modules/zod/v4/core/standard-schema.cjs +2 -0
  466. package/node_modules/zod/v4/core/standard-schema.d.cts +55 -0
  467. package/node_modules/zod/v4/core/standard-schema.d.ts +55 -0
  468. package/node_modules/zod/v4/core/standard-schema.js +1 -0
  469. package/node_modules/zod/v4/core/to-json-schema.cjs +854 -0
  470. package/node_modules/zod/v4/core/to-json-schema.d.cts +88 -0
  471. package/node_modules/zod/v4/core/to-json-schema.d.ts +88 -0
  472. package/node_modules/zod/v4/core/to-json-schema.js +849 -0
  473. package/node_modules/zod/v4/core/util.cjs +539 -0
  474. package/node_modules/zod/v4/core/util.d.cts +183 -0
  475. package/node_modules/zod/v4/core/util.d.ts +183 -0
  476. package/node_modules/zod/v4/core/util.js +493 -0
  477. package/node_modules/zod/v4/core/versions.cjs +8 -0
  478. package/node_modules/zod/v4/core/versions.d.cts +5 -0
  479. package/node_modules/zod/v4/core/versions.d.ts +5 -0
  480. package/node_modules/zod/v4/core/versions.js +5 -0
  481. package/node_modules/zod/v4/index.cjs +22 -0
  482. package/node_modules/zod/v4/index.d.cts +3 -0
  483. package/node_modules/zod/v4/index.d.ts +3 -0
  484. package/node_modules/zod/v4/index.js +3 -0
  485. package/node_modules/zod/v4/locales/ar.cjs +142 -0
  486. package/node_modules/zod/v4/locales/ar.d.cts +4 -0
  487. package/node_modules/zod/v4/locales/ar.d.ts +4 -0
  488. package/node_modules/zod/v4/locales/ar.js +116 -0
  489. package/node_modules/zod/v4/locales/az.cjs +141 -0
  490. package/node_modules/zod/v4/locales/az.d.cts +4 -0
  491. package/node_modules/zod/v4/locales/az.d.ts +4 -0
  492. package/node_modules/zod/v4/locales/az.js +115 -0
  493. package/node_modules/zod/v4/locales/be.cjs +190 -0
  494. package/node_modules/zod/v4/locales/be.d.cts +4 -0
  495. package/node_modules/zod/v4/locales/be.d.ts +4 -0
  496. package/node_modules/zod/v4/locales/be.js +164 -0
  497. package/node_modules/zod/v4/locales/ca.cjs +144 -0
  498. package/node_modules/zod/v4/locales/ca.d.cts +4 -0
  499. package/node_modules/zod/v4/locales/ca.d.ts +4 -0
  500. package/node_modules/zod/v4/locales/ca.js +118 -0
  501. package/node_modules/zod/v4/locales/cs.cjs +161 -0
  502. package/node_modules/zod/v4/locales/cs.d.cts +4 -0
  503. package/node_modules/zod/v4/locales/cs.d.ts +4 -0
  504. package/node_modules/zod/v4/locales/cs.js +135 -0
  505. package/node_modules/zod/v4/locales/de.cjs +142 -0
  506. package/node_modules/zod/v4/locales/de.d.cts +4 -0
  507. package/node_modules/zod/v4/locales/de.d.ts +4 -0
  508. package/node_modules/zod/v4/locales/de.js +116 -0
  509. package/node_modules/zod/v4/locales/en.cjs +145 -0
  510. package/node_modules/zod/v4/locales/en.d.cts +5 -0
  511. package/node_modules/zod/v4/locales/en.d.ts +5 -0
  512. package/node_modules/zod/v4/locales/en.js +117 -0
  513. package/node_modules/zod/v4/locales/eo.cjs +144 -0
  514. package/node_modules/zod/v4/locales/eo.d.cts +5 -0
  515. package/node_modules/zod/v4/locales/eo.d.ts +5 -0
  516. package/node_modules/zod/v4/locales/eo.js +116 -0
  517. package/node_modules/zod/v4/locales/es.cjs +143 -0
  518. package/node_modules/zod/v4/locales/es.d.cts +4 -0
  519. package/node_modules/zod/v4/locales/es.d.ts +4 -0
  520. package/node_modules/zod/v4/locales/es.js +117 -0
  521. package/node_modules/zod/v4/locales/fa.cjs +148 -0
  522. package/node_modules/zod/v4/locales/fa.d.cts +4 -0
  523. package/node_modules/zod/v4/locales/fa.d.ts +4 -0
  524. package/node_modules/zod/v4/locales/fa.js +122 -0
  525. package/node_modules/zod/v4/locales/fi.cjs +148 -0
  526. package/node_modules/zod/v4/locales/fi.d.cts +4 -0
  527. package/node_modules/zod/v4/locales/fi.d.ts +4 -0
  528. package/node_modules/zod/v4/locales/fi.js +122 -0
  529. package/node_modules/zod/v4/locales/fr-CA.cjs +143 -0
  530. package/node_modules/zod/v4/locales/fr-CA.d.cts +4 -0
  531. package/node_modules/zod/v4/locales/fr-CA.d.ts +4 -0
  532. package/node_modules/zod/v4/locales/fr-CA.js +117 -0
  533. package/node_modules/zod/v4/locales/fr.cjs +142 -0
  534. package/node_modules/zod/v4/locales/fr.d.cts +4 -0
  535. package/node_modules/zod/v4/locales/fr.d.ts +4 -0
  536. package/node_modules/zod/v4/locales/fr.js +116 -0
  537. package/node_modules/zod/v4/locales/he.cjs +143 -0
  538. package/node_modules/zod/v4/locales/he.d.cts +4 -0
  539. package/node_modules/zod/v4/locales/he.d.ts +4 -0
  540. package/node_modules/zod/v4/locales/he.js +117 -0
  541. package/node_modules/zod/v4/locales/hu.cjs +143 -0
  542. package/node_modules/zod/v4/locales/hu.d.cts +4 -0
  543. package/node_modules/zod/v4/locales/hu.d.ts +4 -0
  544. package/node_modules/zod/v4/locales/hu.js +117 -0
  545. package/node_modules/zod/v4/locales/id.cjs +142 -0
  546. package/node_modules/zod/v4/locales/id.d.cts +4 -0
  547. package/node_modules/zod/v4/locales/id.d.ts +4 -0
  548. package/node_modules/zod/v4/locales/id.js +116 -0
  549. package/node_modules/zod/v4/locales/index.cjs +84 -0
  550. package/node_modules/zod/v4/locales/index.d.cts +39 -0
  551. package/node_modules/zod/v4/locales/index.d.ts +39 -0
  552. package/node_modules/zod/v4/locales/index.js +39 -0
  553. package/node_modules/zod/v4/locales/it.cjs +143 -0
  554. package/node_modules/zod/v4/locales/it.d.cts +4 -0
  555. package/node_modules/zod/v4/locales/it.d.ts +4 -0
  556. package/node_modules/zod/v4/locales/it.js +117 -0
  557. package/node_modules/zod/v4/locales/ja.cjs +141 -0
  558. package/node_modules/zod/v4/locales/ja.d.cts +4 -0
  559. package/node_modules/zod/v4/locales/ja.d.ts +4 -0
  560. package/node_modules/zod/v4/locales/ja.js +115 -0
  561. package/node_modules/zod/v4/locales/kh.cjs +143 -0
  562. package/node_modules/zod/v4/locales/kh.d.cts +4 -0
  563. package/node_modules/zod/v4/locales/kh.d.ts +4 -0
  564. package/node_modules/zod/v4/locales/kh.js +117 -0
  565. package/node_modules/zod/v4/locales/ko.cjs +147 -0
  566. package/node_modules/zod/v4/locales/ko.d.cts +4 -0
  567. package/node_modules/zod/v4/locales/ko.d.ts +4 -0
  568. package/node_modules/zod/v4/locales/ko.js +121 -0
  569. package/node_modules/zod/v4/locales/mk.cjs +144 -0
  570. package/node_modules/zod/v4/locales/mk.d.cts +4 -0
  571. package/node_modules/zod/v4/locales/mk.d.ts +4 -0
  572. package/node_modules/zod/v4/locales/mk.js +118 -0
  573. package/node_modules/zod/v4/locales/ms.cjs +142 -0
  574. package/node_modules/zod/v4/locales/ms.d.cts +4 -0
  575. package/node_modules/zod/v4/locales/ms.d.ts +4 -0
  576. package/node_modules/zod/v4/locales/ms.js +116 -0
  577. package/node_modules/zod/v4/locales/nl.cjs +143 -0
  578. package/node_modules/zod/v4/locales/nl.d.cts +4 -0
  579. package/node_modules/zod/v4/locales/nl.d.ts +4 -0
  580. package/node_modules/zod/v4/locales/nl.js +117 -0
  581. package/node_modules/zod/v4/locales/no.cjs +142 -0
  582. package/node_modules/zod/v4/locales/no.d.cts +4 -0
  583. package/node_modules/zod/v4/locales/no.d.ts +4 -0
  584. package/node_modules/zod/v4/locales/no.js +116 -0
  585. package/node_modules/zod/v4/locales/ota.cjs +143 -0
  586. package/node_modules/zod/v4/locales/ota.d.cts +4 -0
  587. package/node_modules/zod/v4/locales/ota.d.ts +4 -0
  588. package/node_modules/zod/v4/locales/ota.js +117 -0
  589. package/node_modules/zod/v4/locales/pl.cjs +143 -0
  590. package/node_modules/zod/v4/locales/pl.d.cts +4 -0
  591. package/node_modules/zod/v4/locales/pl.d.ts +4 -0
  592. package/node_modules/zod/v4/locales/pl.js +117 -0
  593. package/node_modules/zod/v4/locales/ps.cjs +148 -0
  594. package/node_modules/zod/v4/locales/ps.d.cts +4 -0
  595. package/node_modules/zod/v4/locales/ps.d.ts +4 -0
  596. package/node_modules/zod/v4/locales/ps.js +122 -0
  597. package/node_modules/zod/v4/locales/pt.cjs +142 -0
  598. package/node_modules/zod/v4/locales/pt.d.cts +4 -0
  599. package/node_modules/zod/v4/locales/pt.d.ts +4 -0
  600. package/node_modules/zod/v4/locales/pt.js +116 -0
  601. package/node_modules/zod/v4/locales/ru.cjs +190 -0
  602. package/node_modules/zod/v4/locales/ru.d.cts +4 -0
  603. package/node_modules/zod/v4/locales/ru.d.ts +4 -0
  604. package/node_modules/zod/v4/locales/ru.js +164 -0
  605. package/node_modules/zod/v4/locales/sl.cjs +143 -0
  606. package/node_modules/zod/v4/locales/sl.d.cts +4 -0
  607. package/node_modules/zod/v4/locales/sl.d.ts +4 -0
  608. package/node_modules/zod/v4/locales/sl.js +117 -0
  609. package/node_modules/zod/v4/locales/sv.cjs +144 -0
  610. package/node_modules/zod/v4/locales/sv.d.cts +4 -0
  611. package/node_modules/zod/v4/locales/sv.d.ts +4 -0
  612. package/node_modules/zod/v4/locales/sv.js +118 -0
  613. package/node_modules/zod/v4/locales/ta.cjs +143 -0
  614. package/node_modules/zod/v4/locales/ta.d.cts +4 -0
  615. package/node_modules/zod/v4/locales/ta.d.ts +4 -0
  616. package/node_modules/zod/v4/locales/ta.js +117 -0
  617. package/node_modules/zod/v4/locales/th.cjs +143 -0
  618. package/node_modules/zod/v4/locales/th.d.cts +4 -0
  619. package/node_modules/zod/v4/locales/th.d.ts +4 -0
  620. package/node_modules/zod/v4/locales/th.js +117 -0
  621. package/node_modules/zod/v4/locales/tr.cjs +143 -0
  622. package/node_modules/zod/v4/locales/tr.d.cts +5 -0
  623. package/node_modules/zod/v4/locales/tr.d.ts +5 -0
  624. package/node_modules/zod/v4/locales/tr.js +115 -0
  625. package/node_modules/zod/v4/locales/ua.cjs +143 -0
  626. package/node_modules/zod/v4/locales/ua.d.cts +4 -0
  627. package/node_modules/zod/v4/locales/ua.d.ts +4 -0
  628. package/node_modules/zod/v4/locales/ua.js +117 -0
  629. package/node_modules/zod/v4/locales/ur.cjs +143 -0
  630. package/node_modules/zod/v4/locales/ur.d.cts +4 -0
  631. package/node_modules/zod/v4/locales/ur.d.ts +4 -0
  632. package/node_modules/zod/v4/locales/ur.js +117 -0
  633. package/node_modules/zod/v4/locales/vi.cjs +142 -0
  634. package/node_modules/zod/v4/locales/vi.d.cts +4 -0
  635. package/node_modules/zod/v4/locales/vi.d.ts +4 -0
  636. package/node_modules/zod/v4/locales/vi.js +116 -0
  637. package/node_modules/zod/v4/locales/zh-CN.cjs +142 -0
  638. package/node_modules/zod/v4/locales/zh-CN.d.cts +4 -0
  639. package/node_modules/zod/v4/locales/zh-CN.d.ts +4 -0
  640. package/node_modules/zod/v4/locales/zh-CN.js +116 -0
  641. package/node_modules/zod/v4/locales/zh-TW.cjs +143 -0
  642. package/node_modules/zod/v4/locales/zh-TW.d.cts +4 -0
  643. package/node_modules/zod/v4/locales/zh-TW.d.ts +4 -0
  644. package/node_modules/zod/v4/locales/zh-TW.js +117 -0
  645. package/node_modules/zod/v4/mini/checks.cjs +34 -0
  646. package/node_modules/zod/v4/mini/checks.d.cts +1 -0
  647. package/node_modules/zod/v4/mini/checks.d.ts +1 -0
  648. package/node_modules/zod/v4/mini/checks.js +1 -0
  649. package/node_modules/zod/v4/mini/coerce.cjs +47 -0
  650. package/node_modules/zod/v4/mini/coerce.d.cts +7 -0
  651. package/node_modules/zod/v4/mini/coerce.d.ts +7 -0
  652. package/node_modules/zod/v4/mini/coerce.js +17 -0
  653. package/node_modules/zod/v4/mini/external.cjs +62 -0
  654. package/node_modules/zod/v4/mini/external.d.cts +11 -0
  655. package/node_modules/zod/v4/mini/external.d.ts +11 -0
  656. package/node_modules/zod/v4/mini/external.js +13 -0
  657. package/node_modules/zod/v4/mini/index.cjs +32 -0
  658. package/node_modules/zod/v4/mini/index.d.cts +3 -0
  659. package/node_modules/zod/v4/mini/index.d.ts +3 -0
  660. package/node_modules/zod/v4/mini/index.js +3 -0
  661. package/node_modules/zod/v4/mini/iso.cjs +60 -0
  662. package/node_modules/zod/v4/mini/iso.d.cts +22 -0
  663. package/node_modules/zod/v4/mini/iso.d.ts +22 -0
  664. package/node_modules/zod/v4/mini/iso.js +30 -0
  665. package/node_modules/zod/v4/mini/parse.cjs +8 -0
  666. package/node_modules/zod/v4/mini/parse.d.cts +1 -0
  667. package/node_modules/zod/v4/mini/parse.d.ts +1 -0
  668. package/node_modules/zod/v4/mini/parse.js +1 -0
  669. package/node_modules/zod/v4/mini/schemas.cjs +839 -0
  670. package/node_modules/zod/v4/mini/schemas.d.cts +356 -0
  671. package/node_modules/zod/v4/mini/schemas.d.ts +356 -0
  672. package/node_modules/zod/v4/mini/schemas.js +732 -0
  673. package/node_modules/zod/v4-mini/index.cjs +17 -0
  674. package/node_modules/zod/v4-mini/index.d.cts +1 -0
  675. package/node_modules/zod/v4-mini/index.d.ts +1 -0
  676. package/node_modules/zod/v4-mini/index.js +1 -0
  677. package/package.json +5 -1
@@ -0,0 +1,286 @@
1
+ 'use strict';
2
+ //parse Empty Node as self closing node
3
+ const buildFromOrderedJs = require('./orderedJs2Xml');
4
+ const getIgnoreAttributesFn = require('../ignoreAttributes')
5
+
6
+ const defaultOptions = {
7
+ attributeNamePrefix: '@_',
8
+ attributesGroupName: false,
9
+ textNodeName: '#text',
10
+ ignoreAttributes: true,
11
+ cdataPropName: false,
12
+ format: false,
13
+ indentBy: ' ',
14
+ suppressEmptyNode: false,
15
+ suppressUnpairedNode: true,
16
+ suppressBooleanAttributes: true,
17
+ tagValueProcessor: function(key, a) {
18
+ return a;
19
+ },
20
+ attributeValueProcessor: function(attrName, a) {
21
+ return a;
22
+ },
23
+ preserveOrder: false,
24
+ commentPropName: false,
25
+ unpairedTags: [],
26
+ entities: [
27
+ { regex: new RegExp("&", "g"), val: "&" },//it must be on top
28
+ { regex: new RegExp(">", "g"), val: ">" },
29
+ { regex: new RegExp("<", "g"), val: "&lt;" },
30
+ { regex: new RegExp("\'", "g"), val: "&apos;" },
31
+ { regex: new RegExp("\"", "g"), val: "&quot;" }
32
+ ],
33
+ processEntities: true,
34
+ stopNodes: [],
35
+ // transformTagName: false,
36
+ // transformAttributeName: false,
37
+ oneListGroup: false
38
+ };
39
+
40
+ function Builder(options) {
41
+ this.options = Object.assign({}, defaultOptions, options);
42
+ if (this.options.ignoreAttributes === true || this.options.attributesGroupName) {
43
+ this.isAttribute = function(/*a*/) {
44
+ return false;
45
+ };
46
+ } else {
47
+ this.ignoreAttributesFn = getIgnoreAttributesFn(this.options.ignoreAttributes)
48
+ this.attrPrefixLen = this.options.attributeNamePrefix.length;
49
+ this.isAttribute = isAttribute;
50
+ }
51
+
52
+ this.processTextOrObjNode = processTextOrObjNode
53
+
54
+ if (this.options.format) {
55
+ this.indentate = indentate;
56
+ this.tagEndChar = '>\n';
57
+ this.newLine = '\n';
58
+ } else {
59
+ this.indentate = function() {
60
+ return '';
61
+ };
62
+ this.tagEndChar = '>';
63
+ this.newLine = '';
64
+ }
65
+ }
66
+
67
+ Builder.prototype.build = function(jObj) {
68
+ if(this.options.preserveOrder){
69
+ return buildFromOrderedJs(jObj, this.options);
70
+ }else {
71
+ if(Array.isArray(jObj) && this.options.arrayNodeName && this.options.arrayNodeName.length > 1){
72
+ jObj = {
73
+ [this.options.arrayNodeName] : jObj
74
+ }
75
+ }
76
+ return this.j2x(jObj, 0, []).val;
77
+ }
78
+ };
79
+
80
+ Builder.prototype.j2x = function(jObj, level, ajPath) {
81
+ let attrStr = '';
82
+ let val = '';
83
+ const jPath = ajPath.join('.')
84
+ for (let key in jObj) {
85
+ if(!Object.prototype.hasOwnProperty.call(jObj, key)) continue;
86
+ if (typeof jObj[key] === 'undefined') {
87
+ // supress undefined node only if it is not an attribute
88
+ if (this.isAttribute(key)) {
89
+ val += '';
90
+ }
91
+ } else if (jObj[key] === null) {
92
+ // null attribute should be ignored by the attribute list, but should not cause the tag closing
93
+ if (this.isAttribute(key)) {
94
+ val += '';
95
+ } else if (key === this.options.cdataPropName) {
96
+ val += '';
97
+ } else if (key[0] === '?') {
98
+ val += this.indentate(level) + '<' + key + '?' + this.tagEndChar;
99
+ } else {
100
+ val += this.indentate(level) + '<' + key + '/' + this.tagEndChar;
101
+ }
102
+ // val += this.indentate(level) + '<' + key + '/' + this.tagEndChar;
103
+ } else if (jObj[key] instanceof Date) {
104
+ val += this.buildTextValNode(jObj[key], key, '', level);
105
+ } else if (typeof jObj[key] !== 'object') {
106
+ //premitive type
107
+ const attr = this.isAttribute(key);
108
+ if (attr && !this.ignoreAttributesFn(attr, jPath)) {
109
+ attrStr += this.buildAttrPairStr(attr, '' + jObj[key]);
110
+ } else if (!attr) {
111
+ //tag value
112
+ if (key === this.options.textNodeName) {
113
+ let newval = this.options.tagValueProcessor(key, '' + jObj[key]);
114
+ val += this.replaceEntitiesValue(newval);
115
+ } else {
116
+ val += this.buildTextValNode(jObj[key], key, '', level);
117
+ }
118
+ }
119
+ } else if (Array.isArray(jObj[key])) {
120
+ //repeated nodes
121
+ const arrLen = jObj[key].length;
122
+ let listTagVal = "";
123
+ let listTagAttr = "";
124
+ for (let j = 0; j < arrLen; j++) {
125
+ const item = jObj[key][j];
126
+ if (typeof item === 'undefined') {
127
+ // supress undefined node
128
+ } else if (item === null) {
129
+ if(key[0] === "?") val += this.indentate(level) + '<' + key + '?' + this.tagEndChar;
130
+ else val += this.indentate(level) + '<' + key + '/' + this.tagEndChar;
131
+ // val += this.indentate(level) + '<' + key + '/' + this.tagEndChar;
132
+ } else if (typeof item === 'object') {
133
+ if(this.options.oneListGroup){
134
+ const result = this.j2x(item, level + 1, ajPath.concat(key));
135
+ listTagVal += result.val;
136
+ if (this.options.attributesGroupName && item.hasOwnProperty(this.options.attributesGroupName)) {
137
+ listTagAttr += result.attrStr
138
+ }
139
+ }else{
140
+ listTagVal += this.processTextOrObjNode(item, key, level, ajPath)
141
+ }
142
+ } else {
143
+ if (this.options.oneListGroup) {
144
+ let textValue = this.options.tagValueProcessor(key, item);
145
+ textValue = this.replaceEntitiesValue(textValue);
146
+ listTagVal += textValue;
147
+ } else {
148
+ listTagVal += this.buildTextValNode(item, key, '', level);
149
+ }
150
+ }
151
+ }
152
+ if(this.options.oneListGroup){
153
+ listTagVal = this.buildObjectNode(listTagVal, key, listTagAttr, level);
154
+ }
155
+ val += listTagVal;
156
+ } else {
157
+ //nested node
158
+ if (this.options.attributesGroupName && key === this.options.attributesGroupName) {
159
+ const Ks = Object.keys(jObj[key]);
160
+ const L = Ks.length;
161
+ for (let j = 0; j < L; j++) {
162
+ attrStr += this.buildAttrPairStr(Ks[j], '' + jObj[key][Ks[j]]);
163
+ }
164
+ } else {
165
+ val += this.processTextOrObjNode(jObj[key], key, level, ajPath)
166
+ }
167
+ }
168
+ }
169
+ return {attrStr: attrStr, val: val};
170
+ };
171
+
172
+ Builder.prototype.buildAttrPairStr = function(attrName, val){
173
+ val = this.options.attributeValueProcessor(attrName, '' + val);
174
+ val = this.replaceEntitiesValue(val);
175
+ if (this.options.suppressBooleanAttributes && val === "true") {
176
+ return ' ' + attrName;
177
+ } else return ' ' + attrName + '="' + val + '"';
178
+ }
179
+
180
+ function processTextOrObjNode (object, key, level, ajPath) {
181
+ const result = this.j2x(object, level + 1, ajPath.concat(key));
182
+ if (object[this.options.textNodeName] !== undefined && Object.keys(object).length === 1) {
183
+ return this.buildTextValNode(object[this.options.textNodeName], key, result.attrStr, level);
184
+ } else {
185
+ return this.buildObjectNode(result.val, key, result.attrStr, level);
186
+ }
187
+ }
188
+
189
+ Builder.prototype.buildObjectNode = function(val, key, attrStr, level) {
190
+ if(val === ""){
191
+ if(key[0] === "?") return this.indentate(level) + '<' + key + attrStr+ '?' + this.tagEndChar;
192
+ else {
193
+ return this.indentate(level) + '<' + key + attrStr + this.closeTag(key) + this.tagEndChar;
194
+ }
195
+ }else{
196
+
197
+ let tagEndExp = '</' + key + this.tagEndChar;
198
+ let piClosingChar = "";
199
+
200
+ if(key[0] === "?") {
201
+ piClosingChar = "?";
202
+ tagEndExp = "";
203
+ }
204
+
205
+ // attrStr is an empty string in case the attribute came as undefined or null
206
+ if ((attrStr || attrStr === '') && val.indexOf('<') === -1) {
207
+ return ( this.indentate(level) + '<' + key + attrStr + piClosingChar + '>' + val + tagEndExp );
208
+ } else if (this.options.commentPropName !== false && key === this.options.commentPropName && piClosingChar.length === 0) {
209
+ return this.indentate(level) + `<!--${val}-->` + this.newLine;
210
+ }else {
211
+ return (
212
+ this.indentate(level) + '<' + key + attrStr + piClosingChar + this.tagEndChar +
213
+ val +
214
+ this.indentate(level) + tagEndExp );
215
+ }
216
+ }
217
+ }
218
+
219
+ Builder.prototype.closeTag = function(key){
220
+ let closeTag = "";
221
+ if(this.options.unpairedTags.indexOf(key) !== -1){ //unpaired
222
+ if(!this.options.suppressUnpairedNode) closeTag = "/"
223
+ }else if(this.options.suppressEmptyNode){ //empty
224
+ closeTag = "/";
225
+ }else{
226
+ closeTag = `></${key}`
227
+ }
228
+ return closeTag;
229
+ }
230
+
231
+ function buildEmptyObjNode(val, key, attrStr, level) {
232
+ if (val !== '') {
233
+ return this.buildObjectNode(val, key, attrStr, level);
234
+ } else {
235
+ if(key[0] === "?") return this.indentate(level) + '<' + key + attrStr+ '?' + this.tagEndChar;
236
+ else {
237
+ return this.indentate(level) + '<' + key + attrStr + '/' + this.tagEndChar;
238
+ // return this.buildTagStr(level,key, attrStr);
239
+ }
240
+ }
241
+ }
242
+
243
+ Builder.prototype.buildTextValNode = function(val, key, attrStr, level) {
244
+ if (this.options.cdataPropName !== false && key === this.options.cdataPropName) {
245
+ return this.indentate(level) + `<![CDATA[${val}]]>` + this.newLine;
246
+ }else if (this.options.commentPropName !== false && key === this.options.commentPropName) {
247
+ return this.indentate(level) + `<!--${val}-->` + this.newLine;
248
+ }else if(key[0] === "?") {//PI tag
249
+ return this.indentate(level) + '<' + key + attrStr+ '?' + this.tagEndChar;
250
+ }else{
251
+ let textValue = this.options.tagValueProcessor(key, val);
252
+ textValue = this.replaceEntitiesValue(textValue);
253
+
254
+ if( textValue === ''){
255
+ return this.indentate(level) + '<' + key + attrStr + this.closeTag(key) + this.tagEndChar;
256
+ }else{
257
+ return this.indentate(level) + '<' + key + attrStr + '>' +
258
+ textValue +
259
+ '</' + key + this.tagEndChar;
260
+ }
261
+ }
262
+ }
263
+
264
+ Builder.prototype.replaceEntitiesValue = function(textValue){
265
+ if(textValue && textValue.length > 0 && this.options.processEntities){
266
+ for (let i=0; i<this.options.entities.length; i++) {
267
+ const entity = this.options.entities[i];
268
+ textValue = textValue.replace(entity.regex, entity.val);
269
+ }
270
+ }
271
+ return textValue;
272
+ }
273
+
274
+ function indentate(level) {
275
+ return this.options.indentBy.repeat(level);
276
+ }
277
+
278
+ function isAttribute(name /*, options*/) {
279
+ if (name.startsWith(this.options.attributeNamePrefix) && name !== this.options.textNodeName) {
280
+ return name.substr(this.attrPrefixLen);
281
+ } else {
282
+ return false;
283
+ }
284
+ }
285
+
286
+ module.exports = Builder;
@@ -0,0 +1,135 @@
1
+ const EOL = "\n";
2
+
3
+ /**
4
+ *
5
+ * @param {array} jArray
6
+ * @param {any} options
7
+ * @returns
8
+ */
9
+ function toXml(jArray, options) {
10
+ let indentation = "";
11
+ if (options.format && options.indentBy.length > 0) {
12
+ indentation = EOL;
13
+ }
14
+ return arrToStr(jArray, options, "", indentation);
15
+ }
16
+
17
+ function arrToStr(arr, options, jPath, indentation) {
18
+ let xmlStr = "";
19
+ let isPreviousElementTag = false;
20
+
21
+ for (let i = 0; i < arr.length; i++) {
22
+ const tagObj = arr[i];
23
+ const tagName = propName(tagObj);
24
+ if(tagName === undefined) continue;
25
+
26
+ let newJPath = "";
27
+ if (jPath.length === 0) newJPath = tagName
28
+ else newJPath = `${jPath}.${tagName}`;
29
+
30
+ if (tagName === options.textNodeName) {
31
+ let tagText = tagObj[tagName];
32
+ if (!isStopNode(newJPath, options)) {
33
+ tagText = options.tagValueProcessor(tagName, tagText);
34
+ tagText = replaceEntitiesValue(tagText, options);
35
+ }
36
+ if (isPreviousElementTag) {
37
+ xmlStr += indentation;
38
+ }
39
+ xmlStr += tagText;
40
+ isPreviousElementTag = false;
41
+ continue;
42
+ } else if (tagName === options.cdataPropName) {
43
+ if (isPreviousElementTag) {
44
+ xmlStr += indentation;
45
+ }
46
+ xmlStr += `<![CDATA[${tagObj[tagName][0][options.textNodeName]}]]>`;
47
+ isPreviousElementTag = false;
48
+ continue;
49
+ } else if (tagName === options.commentPropName) {
50
+ xmlStr += indentation + `<!--${tagObj[tagName][0][options.textNodeName]}-->`;
51
+ isPreviousElementTag = true;
52
+ continue;
53
+ } else if (tagName[0] === "?") {
54
+ const attStr = attr_to_str(tagObj[":@"], options);
55
+ const tempInd = tagName === "?xml" ? "" : indentation;
56
+ let piTextNodeName = tagObj[tagName][0][options.textNodeName];
57
+ piTextNodeName = piTextNodeName.length !== 0 ? " " + piTextNodeName : ""; //remove extra spacing
58
+ xmlStr += tempInd + `<${tagName}${piTextNodeName}${attStr}?>`;
59
+ isPreviousElementTag = true;
60
+ continue;
61
+ }
62
+ let newIdentation = indentation;
63
+ if (newIdentation !== "") {
64
+ newIdentation += options.indentBy;
65
+ }
66
+ const attStr = attr_to_str(tagObj[":@"], options);
67
+ const tagStart = indentation + `<${tagName}${attStr}`;
68
+ const tagValue = arrToStr(tagObj[tagName], options, newJPath, newIdentation);
69
+ if (options.unpairedTags.indexOf(tagName) !== -1) {
70
+ if (options.suppressUnpairedNode) xmlStr += tagStart + ">";
71
+ else xmlStr += tagStart + "/>";
72
+ } else if ((!tagValue || tagValue.length === 0) && options.suppressEmptyNode) {
73
+ xmlStr += tagStart + "/>";
74
+ } else if (tagValue && tagValue.endsWith(">")) {
75
+ xmlStr += tagStart + `>${tagValue}${indentation}</${tagName}>`;
76
+ } else {
77
+ xmlStr += tagStart + ">";
78
+ if (tagValue && indentation !== "" && (tagValue.includes("/>") || tagValue.includes("</"))) {
79
+ xmlStr += indentation + options.indentBy + tagValue + indentation;
80
+ } else {
81
+ xmlStr += tagValue;
82
+ }
83
+ xmlStr += `</${tagName}>`;
84
+ }
85
+ isPreviousElementTag = true;
86
+ }
87
+
88
+ return xmlStr;
89
+ }
90
+
91
+ function propName(obj) {
92
+ const keys = Object.keys(obj);
93
+ for (let i = 0; i < keys.length; i++) {
94
+ const key = keys[i];
95
+ if(!obj.hasOwnProperty(key)) continue;
96
+ if (key !== ":@") return key;
97
+ }
98
+ }
99
+
100
+ function attr_to_str(attrMap, options) {
101
+ let attrStr = "";
102
+ if (attrMap && !options.ignoreAttributes) {
103
+ for (let attr in attrMap) {
104
+ if(!attrMap.hasOwnProperty(attr)) continue;
105
+ let attrVal = options.attributeValueProcessor(attr, attrMap[attr]);
106
+ attrVal = replaceEntitiesValue(attrVal, options);
107
+ if (attrVal === true && options.suppressBooleanAttributes) {
108
+ attrStr += ` ${attr.substr(options.attributeNamePrefix.length)}`;
109
+ } else {
110
+ attrStr += ` ${attr.substr(options.attributeNamePrefix.length)}="${attrVal}"`;
111
+ }
112
+ }
113
+ }
114
+ return attrStr;
115
+ }
116
+
117
+ function isStopNode(jPath, options) {
118
+ jPath = jPath.substr(0, jPath.length - options.textNodeName.length - 1);
119
+ let tagName = jPath.substr(jPath.lastIndexOf(".") + 1);
120
+ for (let index in options.stopNodes) {
121
+ if (options.stopNodes[index] === jPath || options.stopNodes[index] === "*." + tagName) return true;
122
+ }
123
+ return false;
124
+ }
125
+
126
+ function replaceEntitiesValue(textValue, options) {
127
+ if (textValue && textValue.length > 0 && options.processEntities) {
128
+ for (let i = 0; i < options.entities.length; i++) {
129
+ const entity = options.entities[i];
130
+ textValue = textValue.replace(entity.regex, entity.val);
131
+ }
132
+ }
133
+ return textValue;
134
+ }
135
+ module.exports = toXml;
@@ -0,0 +1,153 @@
1
+ const util = require('../util');
2
+
3
+ //TODO: handle comments
4
+ function readDocType(xmlData, i){
5
+
6
+ const entities = {};
7
+ if( xmlData[i + 3] === 'O' &&
8
+ xmlData[i + 4] === 'C' &&
9
+ xmlData[i + 5] === 'T' &&
10
+ xmlData[i + 6] === 'Y' &&
11
+ xmlData[i + 7] === 'P' &&
12
+ xmlData[i + 8] === 'E')
13
+ {
14
+ i = i+9;
15
+ let angleBracketsCount = 1;
16
+ let hasBody = false, comment = false;
17
+ let exp = "";
18
+ for(;i<xmlData.length;i++){
19
+ if (xmlData[i] === '<' && !comment) { //Determine the tag type
20
+ if( hasBody && isEntity(xmlData, i)){
21
+ i += 7;
22
+ let entityName, val;
23
+ [entityName, val,i] = readEntityExp(xmlData,i+1);
24
+ if(val.indexOf("&") === -1) //Parameter entities are not supported
25
+ entities[ validateEntityName(entityName) ] = {
26
+ regx : RegExp( `&${entityName};`,"g"),
27
+ val: val
28
+ };
29
+ }
30
+ else if( hasBody && isElement(xmlData, i)) i += 8;//Not supported
31
+ else if( hasBody && isAttlist(xmlData, i)) i += 8;//Not supported
32
+ else if( hasBody && isNotation(xmlData, i)) i += 9;//Not supported
33
+ else if( isComment) comment = true;
34
+ else throw new Error("Invalid DOCTYPE");
35
+
36
+ angleBracketsCount++;
37
+ exp = "";
38
+ } else if (xmlData[i] === '>') { //Read tag content
39
+ if(comment){
40
+ if( xmlData[i - 1] === "-" && xmlData[i - 2] === "-"){
41
+ comment = false;
42
+ angleBracketsCount--;
43
+ }
44
+ }else{
45
+ angleBracketsCount--;
46
+ }
47
+ if (angleBracketsCount === 0) {
48
+ break;
49
+ }
50
+ }else if( xmlData[i] === '['){
51
+ hasBody = true;
52
+ }else{
53
+ exp += xmlData[i];
54
+ }
55
+ }
56
+ if(angleBracketsCount !== 0){
57
+ throw new Error(`Unclosed DOCTYPE`);
58
+ }
59
+ }else{
60
+ throw new Error(`Invalid Tag instead of DOCTYPE`);
61
+ }
62
+ return {entities, i};
63
+ }
64
+
65
+ function readEntityExp(xmlData,i){
66
+ //External entities are not supported
67
+ // <!ENTITY ext SYSTEM "http://normal-website.com" >
68
+
69
+ //Parameter entities are not supported
70
+ // <!ENTITY entityname "&anotherElement;">
71
+
72
+ //Internal entities are supported
73
+ // <!ENTITY entityname "replacement text">
74
+
75
+ //read EntityName
76
+ let entityName = "";
77
+ for (; i < xmlData.length && (xmlData[i] !== "'" && xmlData[i] !== '"' ); i++) {
78
+ // if(xmlData[i] === " ") continue;
79
+ // else
80
+ entityName += xmlData[i];
81
+ }
82
+ entityName = entityName.trim();
83
+ if(entityName.indexOf(" ") !== -1) throw new Error("External entites are not supported");
84
+
85
+ //read Entity Value
86
+ const startChar = xmlData[i++];
87
+ let val = ""
88
+ for (; i < xmlData.length && xmlData[i] !== startChar ; i++) {
89
+ val += xmlData[i];
90
+ }
91
+ return [entityName, val, i];
92
+ }
93
+
94
+ function isComment(xmlData, i){
95
+ if(xmlData[i+1] === '!' &&
96
+ xmlData[i+2] === '-' &&
97
+ xmlData[i+3] === '-') return true
98
+ return false
99
+ }
100
+ function isEntity(xmlData, i){
101
+ if(xmlData[i+1] === '!' &&
102
+ xmlData[i+2] === 'E' &&
103
+ xmlData[i+3] === 'N' &&
104
+ xmlData[i+4] === 'T' &&
105
+ xmlData[i+5] === 'I' &&
106
+ xmlData[i+6] === 'T' &&
107
+ xmlData[i+7] === 'Y') return true
108
+ return false
109
+ }
110
+ function isElement(xmlData, i){
111
+ if(xmlData[i+1] === '!' &&
112
+ xmlData[i+2] === 'E' &&
113
+ xmlData[i+3] === 'L' &&
114
+ xmlData[i+4] === 'E' &&
115
+ xmlData[i+5] === 'M' &&
116
+ xmlData[i+6] === 'E' &&
117
+ xmlData[i+7] === 'N' &&
118
+ xmlData[i+8] === 'T') return true
119
+ return false
120
+ }
121
+
122
+ function isAttlist(xmlData, i){
123
+ if(xmlData[i+1] === '!' &&
124
+ xmlData[i+2] === 'A' &&
125
+ xmlData[i+3] === 'T' &&
126
+ xmlData[i+4] === 'T' &&
127
+ xmlData[i+5] === 'L' &&
128
+ xmlData[i+6] === 'I' &&
129
+ xmlData[i+7] === 'S' &&
130
+ xmlData[i+8] === 'T') return true
131
+ return false
132
+ }
133
+ function isNotation(xmlData, i){
134
+ if(xmlData[i+1] === '!' &&
135
+ xmlData[i+2] === 'N' &&
136
+ xmlData[i+3] === 'O' &&
137
+ xmlData[i+4] === 'T' &&
138
+ xmlData[i+5] === 'A' &&
139
+ xmlData[i+6] === 'T' &&
140
+ xmlData[i+7] === 'I' &&
141
+ xmlData[i+8] === 'O' &&
142
+ xmlData[i+9] === 'N') return true
143
+ return false
144
+ }
145
+
146
+ function validateEntityName(name){
147
+ if (util.isName(name))
148
+ return name;
149
+ else
150
+ throw new Error(`Invalid entity name ${name}`);
151
+ }
152
+
153
+ module.exports = readDocType;
@@ -0,0 +1,48 @@
1
+
2
+ const defaultOptions = {
3
+ preserveOrder: false,
4
+ attributeNamePrefix: '@_',
5
+ attributesGroupName: false,
6
+ textNodeName: '#text',
7
+ ignoreAttributes: true,
8
+ removeNSPrefix: false, // remove NS from tag name or attribute name if true
9
+ allowBooleanAttributes: false, //a tag can have attributes without any value
10
+ //ignoreRootElement : false,
11
+ parseTagValue: true,
12
+ parseAttributeValue: false,
13
+ trimValues: true, //Trim string values of tag and attributes
14
+ cdataPropName: false,
15
+ numberParseOptions: {
16
+ hex: true,
17
+ leadingZeros: true,
18
+ eNotation: true
19
+ },
20
+ tagValueProcessor: function(tagName, val) {
21
+ return val;
22
+ },
23
+ attributeValueProcessor: function(attrName, val) {
24
+ return val;
25
+ },
26
+ stopNodes: [], //nested tags will not be parsed even for errors
27
+ alwaysCreateTextNode: false,
28
+ isArray: () => false,
29
+ commentPropName: false,
30
+ unpairedTags: [],
31
+ processEntities: true,
32
+ htmlEntities: false,
33
+ ignoreDeclaration: false,
34
+ ignorePiTags: false,
35
+ transformTagName: false,
36
+ transformAttributeName: false,
37
+ updateTag: function(tagName, jPath, attrs){
38
+ return tagName
39
+ },
40
+ // skipEmptyListItem: false
41
+ };
42
+
43
+ const buildOptions = function(options) {
44
+ return Object.assign({}, defaultOptions, options);
45
+ };
46
+
47
+ exports.buildOptions = buildOptions;
48
+ exports.defaultOptions = defaultOptions;