@tstdl/base 0.71.50 → 0.72.0-beta1

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 (1396) hide show
  1. package/api/client/client.d.ts +3 -4
  2. package/api/client/client.js +33 -34
  3. package/api/client/client.js.map +1 -1
  4. package/api/client/index.d.ts +1 -1
  5. package/api/client/index.js +1 -17
  6. package/api/client/index.js.map +1 -1
  7. package/api/default-error-handlers.d.ts +2 -2
  8. package/api/default-error-handlers.js +11 -21
  9. package/api/default-error-handlers.js.map +1 -1
  10. package/api/index.d.ts +3 -3
  11. package/api/index.js +3 -19
  12. package/api/index.js.map +1 -1
  13. package/api/response.d.ts +2 -2
  14. package/api/response.js +42 -46
  15. package/api/response.js.map +1 -1
  16. package/api/server/api-controller.d.ts +3 -3
  17. package/api/server/api-controller.js +11 -19
  18. package/api/server/api-controller.js.map +1 -1
  19. package/api/server/error-handler.d.ts +3 -3
  20. package/api/server/error-handler.js +11 -15
  21. package/api/server/error-handler.js.map +1 -1
  22. package/api/server/gateway.d.ts +8 -9
  23. package/api/server/gateway.js +60 -57
  24. package/api/server/gateway.js.map +1 -1
  25. package/api/server/index.d.ts +3 -3
  26. package/api/server/index.js +3 -19
  27. package/api/server/index.js.map +1 -1
  28. package/api/server/middlewares/allowed-methods.middleware.d.ts +4 -4
  29. package/api/server/middlewares/allowed-methods.middleware.js +7 -11
  30. package/api/server/middlewares/allowed-methods.middleware.js.map +1 -1
  31. package/api/server/middlewares/catch-error.middleware.d.ts +3 -3
  32. package/api/server/middlewares/catch-error.middleware.js +3 -7
  33. package/api/server/middlewares/catch-error.middleware.js.map +1 -1
  34. package/api/server/middlewares/cors.middleware.d.ts +3 -3
  35. package/api/server/middlewares/cors.middleware.js +16 -21
  36. package/api/server/middlewares/cors.middleware.js.map +1 -1
  37. package/api/server/middlewares/index.d.ts +4 -4
  38. package/api/server/middlewares/index.js +4 -20
  39. package/api/server/middlewares/index.js.map +1 -1
  40. package/api/server/middlewares/response-time.middleware.d.ts +2 -2
  41. package/api/server/middlewares/response-time.middleware.js +5 -9
  42. package/api/server/middlewares/response-time.middleware.js.map +1 -1
  43. package/api/server/module.d.ts +3 -3
  44. package/api/server/module.js +7 -10
  45. package/api/server/module.js.map +1 -1
  46. package/api/types.d.ts +10 -5
  47. package/api/types.js +8 -15
  48. package/api/types.js.map +1 -1
  49. package/application/application.d.ts +3 -3
  50. package/application/application.js +22 -23
  51. package/application/application.js.map +1 -1
  52. package/application/index.d.ts +1 -1
  53. package/application/index.js +1 -17
  54. package/application/index.js.map +1 -1
  55. package/async-iterator-symbol.js +1 -5
  56. package/async-iterator-symbol.js.map +1 -1
  57. package/collections/awaitable/awaitable-list.d.ts +1 -1
  58. package/collections/awaitable/awaitable-list.js +8 -13
  59. package/collections/awaitable/awaitable-list.js.map +1 -1
  60. package/collections/awaitable/awaitable-map.js +9 -13
  61. package/collections/awaitable/awaitable-map.js.map +1 -1
  62. package/collections/awaitable/awaitable-set.js +5 -9
  63. package/collections/awaitable/awaitable-set.js.map +1 -1
  64. package/collections/awaitable/index.d.ts +3 -3
  65. package/collections/awaitable/index.js +3 -19
  66. package/collections/awaitable/index.js.map +1 -1
  67. package/collections/collection.js +1 -2
  68. package/collections/index.d.ts +6 -6
  69. package/collections/index.js +6 -22
  70. package/collections/index.js.map +1 -1
  71. package/collections/keyed-set.js +5 -9
  72. package/collections/keyed-set.js.map +1 -1
  73. package/collections/list.d.ts +1 -1
  74. package/collections/list.js +1 -2
  75. package/collections/observable/index.d.ts +8 -8
  76. package/collections/observable/index.js +8 -24
  77. package/collections/observable/index.js.map +1 -1
  78. package/collections/observable/observable-array.d.ts +2 -2
  79. package/collections/observable/observable-array.js +2 -6
  80. package/collections/observable/observable-array.js.map +1 -1
  81. package/collections/observable/observable-collection-base.d.ts +2 -2
  82. package/collections/observable/observable-collection-base.js +18 -23
  83. package/collections/observable/observable-collection-base.js.map +1 -1
  84. package/collections/observable/observable-collection.d.ts +1 -1
  85. package/collections/observable/observable-collection.js +1 -2
  86. package/collections/observable/observable-list-base.d.ts +3 -3
  87. package/collections/observable/observable-list-base.js +11 -15
  88. package/collections/observable/observable-list-base.js.map +1 -1
  89. package/collections/observable/observable-list.d.ts +3 -3
  90. package/collections/observable/observable-list.js +1 -2
  91. package/collections/observable/observable-map.js +3 -7
  92. package/collections/observable/observable-map.js.map +1 -1
  93. package/collections/observable/observable-set.d.ts +2 -2
  94. package/collections/observable/observable-set.js +2 -6
  95. package/collections/observable/observable-set.js.map +1 -1
  96. package/collections/observable/observable-sorted-array-list.d.ts +3 -3
  97. package/collections/observable/observable-sorted-array-list.js +21 -25
  98. package/collections/observable/observable-sorted-array-list.js.map +1 -1
  99. package/collections/sorted-array-list.d.ts +2 -2
  100. package/collections/sorted-array-list.js +17 -21
  101. package/collections/sorted-array-list.js.map +1 -1
  102. package/collections/sorted-list.d.ts +1 -1
  103. package/collections/sorted-list.js +1 -2
  104. package/collections/sorted-map.d.ts +2 -2
  105. package/collections/sorted-map.js +9 -14
  106. package/collections/sorted-map.js.map +1 -1
  107. package/container/container.d.ts +5 -5
  108. package/container/container.js +115 -122
  109. package/container/container.js.map +1 -1
  110. package/container/decorators.d.ts +5 -5
  111. package/container/decorators.js +42 -68
  112. package/container/decorators.js.map +1 -1
  113. package/container/index.d.ts +10 -10
  114. package/container/index.js +10 -26
  115. package/container/index.js.map +1 -1
  116. package/container/interfaces.js +2 -4
  117. package/container/interfaces.js.map +1 -1
  118. package/container/provider.d.ts +4 -4
  119. package/container/provider.js +13 -24
  120. package/container/provider.js.map +1 -1
  121. package/container/resolve-chain.d.ts +2 -2
  122. package/container/resolve-chain.js +7 -11
  123. package/container/resolve-chain.js.map +1 -1
  124. package/container/resolve.error.d.ts +2 -2
  125. package/container/resolve.error.js +4 -8
  126. package/container/resolve.error.js.map +1 -1
  127. package/container/token.d.ts +1 -1
  128. package/container/token.js +5 -10
  129. package/container/token.js.map +1 -1
  130. package/container/type-info.d.ts +3 -3
  131. package/container/type-info.js +16 -25
  132. package/container/type-info.js.map +1 -1
  133. package/container/types.d.ts +2 -2
  134. package/container/types.js +1 -2
  135. package/container/utils.d.ts +1 -1
  136. package/container/utils.js +7 -11
  137. package/container/utils.js.map +1 -1
  138. package/core.d.ts +4 -4
  139. package/core.js +23 -28
  140. package/core.js.map +1 -1
  141. package/css/theme/index.d.ts +2 -2
  142. package/css/theme/index.js +2 -18
  143. package/css/theme/index.js.map +1 -1
  144. package/css/theme/theme.model.js +1 -5
  145. package/css/theme/theme.model.js.map +1 -1
  146. package/css/theme/theme.service.d.ts +1 -1
  147. package/css/theme/theme.service.js +10 -14
  148. package/css/theme/theme.service.js.map +1 -1
  149. package/data-structures/array-list.d.ts +2 -2
  150. package/data-structures/array-list.js +2 -6
  151. package/data-structures/array-list.js.map +1 -1
  152. package/data-structures/circular-buffer.d.ts +2 -2
  153. package/data-structures/circular-buffer.js +31 -50
  154. package/data-structures/circular-buffer.js.map +1 -1
  155. package/data-structures/collection.d.ts +1 -1
  156. package/data-structures/collection.js +12 -17
  157. package/data-structures/collection.js.map +1 -1
  158. package/data-structures/index-out-of-bounds.error.d.ts +1 -1
  159. package/data-structures/index-out-of-bounds.error.js +5 -9
  160. package/data-structures/index-out-of-bounds.error.js.map +1 -1
  161. package/data-structures/index.d.ts +9 -9
  162. package/data-structures/index.js +9 -25
  163. package/data-structures/index.js.map +1 -1
  164. package/data-structures/linked-list.d.ts +4 -4
  165. package/data-structures/linked-list.js +25 -28
  166. package/data-structures/linked-list.js.map +1 -1
  167. package/data-structures/list.d.ts +2 -2
  168. package/data-structures/list.js +10 -14
  169. package/data-structures/list.js.map +1 -1
  170. package/data-structures/multi-key-map.d.ts +1 -1
  171. package/data-structures/multi-key-map.js +13 -17
  172. package/data-structures/multi-key-map.js.map +1 -1
  173. package/data-structures/sorted-array-list.d.ts +5 -5
  174. package/data-structures/sorted-array-list.js +19 -22
  175. package/data-structures/sorted-array-list.js.map +1 -1
  176. package/data-structures/weak-ref-map.d.ts +1 -1
  177. package/data-structures/weak-ref-map.js +13 -17
  178. package/data-structures/weak-ref-map.js.map +1 -1
  179. package/database/entity-repository.d.ts +2 -2
  180. package/database/entity-repository.js +1 -5
  181. package/database/entity-repository.js.map +1 -1
  182. package/database/entity.js +1 -2
  183. package/database/id.js +4 -8
  184. package/database/id.js.map +1 -1
  185. package/database/index.d.ts +6 -6
  186. package/database/index.js +6 -22
  187. package/database/index.js.map +1 -1
  188. package/database/module.js +6 -11
  189. package/database/module.js.map +1 -1
  190. package/database/mongo/classes.d.ts +5 -5
  191. package/database/mongo/classes.js +11 -14
  192. package/database/mongo/classes.js.map +1 -1
  193. package/database/mongo/index.d.ts +10 -10
  194. package/database/mongo/index.js +10 -26
  195. package/database/mongo/index.js.map +1 -1
  196. package/database/mongo/{model/document.d.ts → model.d.ts} +3 -3
  197. package/database/mongo/model.js +71 -0
  198. package/database/mongo/model.js.map +1 -0
  199. package/database/mongo/module.d.ts +1 -1
  200. package/database/mongo/module.js +28 -45
  201. package/database/mongo/module.js.map +1 -1
  202. package/database/mongo/mongo-base.repository.d.ts +5 -5
  203. package/database/mongo/mongo-base.repository.js +49 -98
  204. package/database/mongo/mongo-base.repository.js.map +1 -1
  205. package/database/mongo/mongo-bulk.d.ts +4 -4
  206. package/database/mongo/mongo-bulk.js +17 -21
  207. package/database/mongo/mongo-bulk.js.map +1 -1
  208. package/database/mongo/{mongo-entity-repository.d.ts → mongo-entity.repository.d.ts} +8 -8
  209. package/database/mongo/{mongo-entity-repository.js → mongo-entity.repository.js} +50 -130
  210. package/database/mongo/mongo-entity.repository.js.map +1 -0
  211. package/database/mongo/operations.d.ts +4 -4
  212. package/database/mongo/operations.js +6 -15
  213. package/database/mongo/operations.js.map +1 -1
  214. package/database/mongo/query-converter.d.ts +4 -4
  215. package/database/mongo/query-converter.js +18 -27
  216. package/database/mongo/query-converter.js.map +1 -1
  217. package/database/mongo/simple-entity.repository.d.ts +7 -0
  218. package/database/mongo/simple-entity.repository.js +7 -0
  219. package/database/mongo/simple-entity.repository.js.map +1 -0
  220. package/database/mongo/types.d.ts +3 -3
  221. package/database/mongo/types.js +1 -5
  222. package/database/mongo/types.js.map +1 -1
  223. package/database/query.d.ts +2 -2
  224. package/database/query.js +7 -10
  225. package/database/query.js.map +1 -1
  226. package/database/utils.d.ts +1 -1
  227. package/database/utils.js +1 -5
  228. package/database/utils.js.map +1 -1
  229. package/disposable/async-disposer.d.ts +4 -4
  230. package/disposable/async-disposer.js +20 -24
  231. package/disposable/async-disposer.js.map +1 -1
  232. package/disposable/disposable.js +7 -12
  233. package/disposable/disposable.js.map +1 -1
  234. package/disposable/index.d.ts +3 -3
  235. package/disposable/index.js +3 -19
  236. package/disposable/index.js.map +1 -1
  237. package/disposable/using.d.ts +1 -1
  238. package/disposable/using.js +5 -10
  239. package/disposable/using.js.map +1 -1
  240. package/distributed-loop/controller.js +1 -2
  241. package/distributed-loop/distributed-loop.d.ts +5 -5
  242. package/distributed-loop/distributed-loop.js +15 -19
  243. package/distributed-loop/distributed-loop.js.map +1 -1
  244. package/distributed-loop/index.d.ts +3 -3
  245. package/distributed-loop/index.js +3 -19
  246. package/distributed-loop/index.js.map +1 -1
  247. package/distributed-loop/provider.d.ts +2 -2
  248. package/distributed-loop/provider.js +7 -10
  249. package/distributed-loop/provider.js.map +1 -1
  250. package/enumerable/async-enumerable.d.ts +8 -8
  251. package/enumerable/async-enumerable.js +66 -71
  252. package/enumerable/async-enumerable.js.map +1 -1
  253. package/enumerable/enumerable-methods.js +1 -2
  254. package/enumerable/enumerable.d.ts +6 -6
  255. package/enumerable/enumerable.js +44 -49
  256. package/enumerable/enumerable.js.map +1 -1
  257. package/enumerable/index.d.ts +2 -2
  258. package/enumerable/index.js +2 -18
  259. package/enumerable/index.js.map +1 -1
  260. package/error/api.error.d.ts +2 -2
  261. package/error/api.error.js +2 -6
  262. package/error/api.error.js.map +1 -1
  263. package/error/assertion.error.d.ts +1 -1
  264. package/error/assertion.error.js +2 -6
  265. package/error/assertion.error.js.map +1 -1
  266. package/error/bad-request.error.d.ts +1 -1
  267. package/error/bad-request.error.js +2 -6
  268. package/error/bad-request.error.js.map +1 -1
  269. package/error/custom.error.js +2 -7
  270. package/error/custom.error.js.map +1 -1
  271. package/error/details.error.d.ts +1 -1
  272. package/error/details.error.js +2 -6
  273. package/error/details.error.js.map +1 -1
  274. package/error/forbidden.error.d.ts +1 -1
  275. package/error/forbidden.error.js +2 -6
  276. package/error/forbidden.error.js.map +1 -1
  277. package/error/index.d.ts +15 -15
  278. package/error/index.js +15 -31
  279. package/error/index.js.map +1 -1
  280. package/error/invalid-token.error.d.ts +1 -1
  281. package/error/invalid-token.error.js +2 -6
  282. package/error/invalid-token.error.js.map +1 -1
  283. package/error/max-bytes-exceeded.error.d.ts +1 -1
  284. package/error/max-bytes-exceeded.error.js +2 -6
  285. package/error/max-bytes-exceeded.error.js.map +1 -1
  286. package/error/method-not-allowed.error.d.ts +1 -1
  287. package/error/method-not-allowed.error.js +2 -6
  288. package/error/method-not-allowed.error.js.map +1 -1
  289. package/error/multi.error.d.ts +1 -1
  290. package/error/multi.error.js +2 -6
  291. package/error/multi.error.js.map +1 -1
  292. package/error/not-found.error.d.ts +1 -1
  293. package/error/not-found.error.js +2 -6
  294. package/error/not-found.error.js.map +1 -1
  295. package/error/not-implemented.error.d.ts +1 -1
  296. package/error/not-implemented.error.js +2 -6
  297. package/error/not-implemented.error.js.map +1 -1
  298. package/error/unauthorized.error.d.ts +1 -1
  299. package/error/unauthorized.error.js +2 -6
  300. package/error/unauthorized.error.js.map +1 -1
  301. package/error/unsupported-media-type.error.d.ts +1 -1
  302. package/error/unsupported-media-type.error.js +2 -6
  303. package/error/unsupported-media-type.error.js.map +1 -1
  304. package/error/validation.error.d.ts +1 -1
  305. package/error/validation.error.js +2 -6
  306. package/error/validation.error.js.map +1 -1
  307. package/examples/api/basic-overview.js +35 -36
  308. package/examples/api/basic-overview.js.map +1 -1
  309. package/global-this.js +1 -5
  310. package/global-this.js.map +1 -1
  311. package/http/client/adapters/got-http-client.adapter.d.ts +3 -3
  312. package/http/client/adapters/got-http-client.adapter.js +49 -82
  313. package/http/client/adapters/got-http-client.adapter.js.map +1 -1
  314. package/http/client/adapters/undici-http-client.adapter.d.ts +4 -4
  315. package/http/client/adapters/undici-http-client.adapter.js +31 -37
  316. package/http/client/adapters/undici-http-client.adapter.js.map +1 -1
  317. package/http/client/adapters/utils.d.ts +2 -2
  318. package/http/client/adapters/utils.js +14 -22
  319. package/http/client/adapters/utils.js.map +1 -1
  320. package/http/client/http-client-request.d.ts +13 -13
  321. package/http/client/http-client-request.js +34 -40
  322. package/http/client/http-client-request.js.map +1 -1
  323. package/http/client/http-client-response.d.ts +5 -5
  324. package/http/client/http-client-response.js +3 -7
  325. package/http/client/http-client-response.js.map +1 -1
  326. package/http/client/http-client.adapter.d.ts +3 -3
  327. package/http/client/http-client.adapter.js +1 -5
  328. package/http/client/http-client.adapter.js.map +1 -1
  329. package/http/client/http-client.d.ts +10 -10
  330. package/http/client/http-client.js +77 -118
  331. package/http/client/http-client.js.map +1 -1
  332. package/http/client/index.d.ts +4 -4
  333. package/http/client/index.js +4 -20
  334. package/http/client/index.js.map +1 -1
  335. package/http/cookie-parser.d.ts +1 -1
  336. package/http/cookie-parser.js +5 -9
  337. package/http/cookie-parser.js.map +1 -1
  338. package/http/http-form.d.ts +3 -3
  339. package/http/http-form.js +2 -6
  340. package/http/http-form.js.map +1 -1
  341. package/http/http-headers.d.ts +3 -3
  342. package/http/http-headers.js +16 -21
  343. package/http/http-headers.js.map +1 -1
  344. package/http/http-query.d.ts +3 -3
  345. package/http/http-query.js +2 -6
  346. package/http/http-query.js.map +1 -1
  347. package/http/http-url-parameters.d.ts +3 -3
  348. package/http/http-url-parameters.js +2 -6
  349. package/http/http-url-parameters.js.map +1 -1
  350. package/http/http-value-map.d.ts +2 -2
  351. package/http/http-value-map.js +21 -27
  352. package/http/http-value-map.js.map +1 -1
  353. package/http/http.error.d.ts +3 -3
  354. package/http/http.error.js +8 -13
  355. package/http/http.error.js.map +1 -1
  356. package/http/index.d.ts +9 -9
  357. package/http/index.js +9 -25
  358. package/http/index.js.map +1 -1
  359. package/http/server/http-server-request.d.ts +5 -5
  360. package/http/server/http-server-request.js +14 -19
  361. package/http/server/http-server-request.js.map +1 -1
  362. package/http/server/http-server-response.d.ts +3 -3
  363. package/http/server/http-server-response.js +3 -7
  364. package/http/server/http-server-response.js.map +1 -1
  365. package/http/server/http-server.d.ts +2 -3
  366. package/http/server/http-server.js +2 -6
  367. package/http/server/http-server.js.map +1 -1
  368. package/http/server/index.d.ts +3 -3
  369. package/http/server/index.js +3 -19
  370. package/http/server/index.js.map +1 -1
  371. package/http/server/node/index.d.ts +2 -2
  372. package/http/server/node/index.js +2 -18
  373. package/http/server/node/index.js.map +1 -1
  374. package/http/server/node/module.js +5 -9
  375. package/http/server/node/module.js.map +1 -1
  376. package/http/server/node/node-http-server.d.ts +8 -8
  377. package/http/server/node/node-http-server.js +51 -100
  378. package/http/server/node/node-http-server.js.map +1 -1
  379. package/http/types.d.ts +1 -1
  380. package/http/types.js +9 -16
  381. package/http/types.js.map +1 -1
  382. package/image-service/image-service.d.ts +2 -2
  383. package/image-service/image-service.js +14 -18
  384. package/image-service/image-service.js.map +1 -1
  385. package/image-service/imgproxy/imgproxy-image-service.d.ts +5 -5
  386. package/image-service/imgproxy/imgproxy-image-service.js +32 -36
  387. package/image-service/imgproxy/imgproxy-image-service.js.map +1 -1
  388. package/image-service/imgproxy/index.d.ts +1 -1
  389. package/image-service/imgproxy/index.js +1 -17
  390. package/image-service/imgproxy/index.js.map +1 -1
  391. package/image-service/index.d.ts +1 -1
  392. package/image-service/index.js +1 -17
  393. package/image-service/index.js.map +1 -1
  394. package/index.d.ts +1 -1
  395. package/index.js +1 -17
  396. package/index.js.map +1 -1
  397. package/instance-provider.d.ts +4 -4
  398. package/instance-provider.js +27 -35
  399. package/instance-provider.js.map +1 -1
  400. package/interfaces.js +1 -2
  401. package/json-path/index.d.ts +1 -1
  402. package/json-path/index.js +1 -17
  403. package/json-path/index.js.map +1 -1
  404. package/json-path/json-path.js +12 -19
  405. package/json-path/json-path.js.map +1 -1
  406. package/key-value-store/index.d.ts +2 -2
  407. package/key-value-store/index.js +2 -18
  408. package/key-value-store/index.js.map +1 -1
  409. package/key-value-store/key-value-store.provider.d.ts +2 -2
  410. package/key-value-store/key-value-store.provider.js +1 -5
  411. package/key-value-store/key-value-store.provider.js.map +1 -1
  412. package/key-value-store/key-value.store.d.ts +3 -3
  413. package/key-value-store/key-value.store.js +2 -6
  414. package/key-value-store/key-value.store.js.map +1 -1
  415. package/key-value-store/mongo/index.d.ts +5 -5
  416. package/key-value-store/mongo/index.js +5 -21
  417. package/key-value-store/mongo/index.js.map +1 -1
  418. package/key-value-store/mongo/module.d.ts +2 -2
  419. package/key-value-store/mongo/module.js +10 -14
  420. package/key-value-store/mongo/module.js.map +1 -1
  421. package/key-value-store/mongo/mongo-key-value-store.provider.d.ts +3 -3
  422. package/key-value-store/mongo/mongo-key-value-store.provider.js +7 -10
  423. package/key-value-store/mongo/mongo-key-value-store.provider.js.map +1 -1
  424. package/key-value-store/mongo/mongo-key-value.model.d.ts +1 -1
  425. package/key-value-store/mongo/mongo-key-value.model.js +1 -2
  426. package/key-value-store/mongo/mongo-key-value.repository.d.ts +6 -6
  427. package/key-value-store/mongo/mongo-key-value.repository.js +11 -14
  428. package/key-value-store/mongo/mongo-key-value.repository.js.map +1 -1
  429. package/key-value-store/mongo/mongo-key-value.store.d.ts +3 -3
  430. package/key-value-store/mongo/mongo-key-value.store.js +16 -19
  431. package/key-value-store/mongo/mongo-key-value.store.js.map +1 -1
  432. package/lock/index.d.ts +2 -2
  433. package/lock/index.js +2 -18
  434. package/lock/index.js.map +1 -1
  435. package/lock/lock.d.ts +2 -2
  436. package/lock/lock.js +2 -6
  437. package/lock/lock.js.map +1 -1
  438. package/lock/mongo/index.d.ts +5 -5
  439. package/lock/mongo/index.js +5 -21
  440. package/lock/mongo/index.js.map +1 -1
  441. package/lock/mongo/lock.d.ts +4 -4
  442. package/lock/mongo/lock.js +30 -33
  443. package/lock/mongo/lock.js.map +1 -1
  444. package/lock/mongo/model.d.ts +1 -1
  445. package/lock/mongo/model.js +1 -2
  446. package/lock/mongo/module.d.ts +2 -2
  447. package/lock/mongo/module.js +10 -14
  448. package/lock/mongo/module.js.map +1 -1
  449. package/lock/mongo/{mongo-lock-repository.d.ts → mongo-lock.repository.d.ts} +6 -6
  450. package/lock/mongo/{mongo-lock-repository.js → mongo-lock.repository.js} +17 -20
  451. package/lock/mongo/mongo-lock.repository.js.map +1 -0
  452. package/lock/mongo/provider.d.ts +4 -4
  453. package/lock/mongo/provider.js +16 -19
  454. package/lock/mongo/provider.js.map +1 -1
  455. package/lock/provider.d.ts +3 -3
  456. package/lock/provider.js +2 -6
  457. package/lock/provider.js.map +1 -1
  458. package/logger/console/index.d.ts +1 -1
  459. package/logger/console/index.js +1 -17
  460. package/logger/console/index.js.map +1 -1
  461. package/logger/console/logger.d.ts +3 -3
  462. package/logger/console/logger.js +20 -27
  463. package/logger/console/logger.js.map +1 -1
  464. package/logger/index.d.ts +2 -2
  465. package/logger/index.js +2 -18
  466. package/logger/index.js.map +1 -1
  467. package/logger/level.js +2 -5
  468. package/logger/level.js.map +1 -1
  469. package/logger/logger.d.ts +3 -3
  470. package/logger/logger.js +13 -17
  471. package/logger/logger.js.map +1 -1
  472. package/logger/noop/index.d.ts +1 -1
  473. package/logger/noop/index.js +1 -17
  474. package/logger/noop/index.js.map +1 -1
  475. package/logger/noop/logger.d.ts +1 -1
  476. package/logger/noop/logger.js +5 -9
  477. package/logger/noop/logger.js.map +1 -1
  478. package/mail/clients/nodemailer.mail-client.d.ts +2 -2
  479. package/mail/clients/nodemailer.mail-client.js +15 -20
  480. package/mail/clients/nodemailer.mail-client.js.map +1 -1
  481. package/mail/index.d.ts +8 -8
  482. package/mail/index.js +8 -24
  483. package/mail/index.js.map +1 -1
  484. package/mail/mail-log.repository.d.ts +2 -2
  485. package/mail/mail-log.repository.js +2 -6
  486. package/mail/mail-log.repository.js.map +1 -1
  487. package/mail/mail-template-renderer.provider.d.ts +1 -1
  488. package/mail/mail-template-renderer.provider.js +6 -9
  489. package/mail/mail-template-renderer.provider.js.map +1 -1
  490. package/mail/mail-template.provider.d.ts +1 -1
  491. package/mail/mail-template.provider.js +1 -5
  492. package/mail/mail-template.provider.js.map +1 -1
  493. package/mail/mail-template.renderer.d.ts +1 -1
  494. package/mail/mail-template.renderer.js +1 -5
  495. package/mail/mail-template.renderer.js.map +1 -1
  496. package/mail/mail.client.d.ts +3 -3
  497. package/mail/mail.client.js +2 -6
  498. package/mail/mail.client.js.map +1 -1
  499. package/mail/mail.service.d.ts +7 -7
  500. package/mail/mail.service.js +24 -27
  501. package/mail/mail.service.js.map +1 -1
  502. package/mail/models/index.d.ts +6 -6
  503. package/mail/models/index.js +6 -22
  504. package/mail/models/index.js.map +1 -1
  505. package/mail/models/mail-address.model.js +1 -2
  506. package/mail/models/mail-content.model.js +1 -2
  507. package/mail/models/mail-data.model.d.ts +3 -3
  508. package/mail/models/mail-data.model.js +1 -2
  509. package/mail/models/mail-log.model.d.ts +3 -3
  510. package/mail/models/mail-log.model.js +1 -2
  511. package/mail/models/mail-send-result.model.d.ts +1 -1
  512. package/mail/models/mail-send-result.model.js +1 -2
  513. package/mail/models/mail-template.model.js +1 -2
  514. package/mail/module.d.ts +6 -6
  515. package/mail/module.js +21 -25
  516. package/mail/module.js.map +1 -1
  517. package/mail/repositories/mongo-mail-log.repository.d.ts +6 -6
  518. package/mail/repositories/mongo-mail-log.repository.js +13 -18
  519. package/mail/repositories/mongo-mail-log.repository.js.map +1 -1
  520. package/mail/template-providers/file-mail-template.provider.d.ts +5 -5
  521. package/mail/template-providers/file-mail-template.provider.js +29 -32
  522. package/mail/template-providers/file-mail-template.provider.js.map +1 -1
  523. package/mail/template-providers/memory-mail-template.provider.d.ts +2 -2
  524. package/mail/template-providers/memory-mail-template.provider.js +7 -10
  525. package/mail/template-providers/memory-mail-template.provider.js.map +1 -1
  526. package/mail/template-renderers/handlebars.mail-template-renderer.d.ts +3 -3
  527. package/mail/template-renderers/handlebars.mail-template-renderer.js +13 -17
  528. package/mail/template-renderers/handlebars.mail-template-renderer.js.map +1 -1
  529. package/mail/template-renderers/mjml.mail-template-renderer.d.ts +4 -4
  530. package/mail/template-renderers/mjml.mail-template-renderer.js +18 -18
  531. package/mail/template-renderers/mjml.mail-template-renderer.js.map +1 -1
  532. package/mail/tokens.d.ts +5 -5
  533. package/mail/tokens.js +3 -6
  534. package/mail/tokens.js.map +1 -1
  535. package/memory/index.d.ts +1 -1
  536. package/memory/index.js +1 -17
  537. package/memory/index.js.map +1 -1
  538. package/memory/observable-finalization-registry.js +3 -7
  539. package/memory/observable-finalization-registry.js.map +1 -1
  540. package/message-bus/broadcast-channel/broadcast-channel-message-bus-provider.d.ts +3 -3
  541. package/message-bus/broadcast-channel/broadcast-channel-message-bus-provider.js +3 -7
  542. package/message-bus/broadcast-channel/broadcast-channel-message-bus-provider.js.map +1 -1
  543. package/message-bus/broadcast-channel/broadcast-channel-message-bus.d.ts +3 -3
  544. package/message-bus/broadcast-channel/broadcast-channel-message-bus.js +7 -12
  545. package/message-bus/broadcast-channel/broadcast-channel-message-bus.js.map +1 -1
  546. package/message-bus/broadcast-channel/index.d.ts +2 -2
  547. package/message-bus/broadcast-channel/index.js +2 -18
  548. package/message-bus/broadcast-channel/index.js.map +1 -1
  549. package/message-bus/index.d.ts +3 -3
  550. package/message-bus/index.js +3 -19
  551. package/message-bus/index.js.map +1 -1
  552. package/message-bus/local/index.d.ts +2 -2
  553. package/message-bus/local/index.js +2 -18
  554. package/message-bus/local/index.js.map +1 -1
  555. package/message-bus/local/local-message-bus-provider.d.ts +3 -3
  556. package/message-bus/local/local-message-bus-provider.js +20 -24
  557. package/message-bus/local/local-message-bus-provider.js.map +1 -1
  558. package/message-bus/local/local-message-bus.d.ts +4 -4
  559. package/message-bus/local/local-message-bus.js +13 -16
  560. package/message-bus/local/local-message-bus.js.map +1 -1
  561. package/message-bus/local/types.js +1 -2
  562. package/message-bus/message-bus-base.d.ts +4 -4
  563. package/message-bus/message-bus-base.js +11 -15
  564. package/message-bus/message-bus-base.js.map +1 -1
  565. package/message-bus/message-bus-provider.d.ts +1 -1
  566. package/message-bus/message-bus-provider.js +1 -5
  567. package/message-bus/message-bus-provider.js.map +1 -1
  568. package/message-bus/message-bus.d.ts +4 -4
  569. package/message-bus/message-bus.js +3 -7
  570. package/message-bus/message-bus.js.map +1 -1
  571. package/migration/index.d.ts +3 -3
  572. package/migration/index.js +3 -19
  573. package/migration/index.js.map +1 -1
  574. package/migration/migration-state-repository.d.ts +2 -2
  575. package/migration/migration-state-repository.js +2 -6
  576. package/migration/migration-state-repository.js.map +1 -1
  577. package/migration/migration-state.d.ts +1 -1
  578. package/migration/migration-state.js +1 -2
  579. package/migration/migrator.d.ts +3 -3
  580. package/migration/migrator.js +24 -28
  581. package/migration/migrator.js.map +1 -1
  582. package/migration/mongo/index.d.ts +2 -2
  583. package/migration/mongo/index.js +2 -18
  584. package/migration/mongo/index.js.map +1 -1
  585. package/migration/mongo/migration-state-repository.d.ts +7 -7
  586. package/migration/mongo/migration-state-repository.js +12 -15
  587. package/migration/mongo/migration-state-repository.js.map +1 -1
  588. package/migration/mongo/module.d.ts +2 -2
  589. package/migration/mongo/module.js +7 -11
  590. package/migration/mongo/module.js.map +1 -1
  591. package/module/index.d.ts +4 -4
  592. package/module/index.js +4 -20
  593. package/module/index.js.map +1 -1
  594. package/module/module-base.d.ts +5 -5
  595. package/module/module-base.js +10 -14
  596. package/module/module-base.js.map +1 -1
  597. package/module/module-metric-reporter.d.ts +4 -4
  598. package/module/module-metric-reporter.js +8 -12
  599. package/module/module-metric-reporter.js.map +1 -1
  600. package/module/module.d.ts +1 -1
  601. package/module/module.js +4 -7
  602. package/module/module.js.map +1 -1
  603. package/module/modules/index.d.ts +2 -2
  604. package/module/modules/index.js +2 -18
  605. package/module/modules/index.js.map +1 -1
  606. package/module/modules/old-web-server.module.d.ts +7 -7
  607. package/module/modules/old-web-server.module.js +6 -28
  608. package/module/modules/old-web-server.module.js.map +1 -1
  609. package/module/modules/web-server.module.d.ts +9 -9
  610. package/module/modules/web-server.module.js +24 -47
  611. package/module/modules/web-server.module.js.map +1 -1
  612. package/module/utils.d.ts +2 -2
  613. package/module/utils.js +2 -7
  614. package/module/utils.js.map +1 -1
  615. package/object-storage/index.d.ts +3 -3
  616. package/object-storage/index.js +3 -19
  617. package/object-storage/index.js.map +1 -1
  618. package/object-storage/object-storage-provider.d.ts +1 -1
  619. package/object-storage/object-storage-provider.js +1 -5
  620. package/object-storage/object-storage-provider.js.map +1 -1
  621. package/object-storage/object-storage.d.ts +3 -3
  622. package/object-storage/object-storage.js +2 -6
  623. package/object-storage/object-storage.js.map +1 -1
  624. package/object-storage/object.js +1 -2
  625. package/object-storage/s3/index.d.ts +3 -3
  626. package/object-storage/s3/index.js +3 -19
  627. package/object-storage/s3/index.js.map +1 -1
  628. package/object-storage/s3/s3.object-storage-provider.d.ts +3 -3
  629. package/object-storage/s3/s3.object-storage-provider.js +20 -24
  630. package/object-storage/s3/s3.object-storage-provider.js.map +1 -1
  631. package/object-storage/s3/s3.object-storage.d.ts +3 -3
  632. package/object-storage/s3/s3.object-storage.js +17 -20
  633. package/object-storage/s3/s3.object-storage.js.map +1 -1
  634. package/object-storage/s3/s3.object.d.ts +1 -1
  635. package/object-storage/s3/s3.object.js +1 -2
  636. package/old-api/endpoint.d.ts +1 -1
  637. package/old-api/endpoint.js +2 -7
  638. package/old-api/endpoint.js.map +1 -1
  639. package/old-api/endpoints/echo.endpoint.d.ts +1 -1
  640. package/old-api/endpoints/echo.endpoint.js +1 -5
  641. package/old-api/endpoints/echo.endpoint.js.map +1 -1
  642. package/old-api/endpoints/index.d.ts +1 -1
  643. package/old-api/endpoints/index.js +1 -17
  644. package/old-api/endpoints/index.js.map +1 -1
  645. package/old-api/http-api.d.ts +10 -10
  646. package/old-api/http-api.js +60 -84
  647. package/old-api/http-api.js.map +1 -1
  648. package/old-api/index.d.ts +3 -3
  649. package/old-api/index.js +3 -19
  650. package/old-api/index.js.map +1 -1
  651. package/old-api/validation/index.d.ts +1 -1
  652. package/old-api/validation/index.js +1 -17
  653. package/old-api/validation/index.js.map +1 -1
  654. package/old-api/validation/types.d.ts +1 -1
  655. package/old-api/validation/types.js +2 -5
  656. package/old-api/validation/types.js.map +1 -1
  657. package/old-api/validation/validators/index.d.ts +1 -1
  658. package/old-api/validation/validators/index.js +1 -17
  659. package/old-api/validation/validators/index.js.map +1 -1
  660. package/old-api/validation/validators/noop.d.ts +1 -1
  661. package/old-api/validation/validators/noop.js +1 -5
  662. package/old-api/validation/validators/noop.js.map +1 -1
  663. package/old-api/validation/validators/superstruct.d.ts +3 -3
  664. package/old-api/validation/validators/superstruct.js +17 -28
  665. package/old-api/validation/validators/superstruct.js.map +1 -1
  666. package/old-api/validation/validators/yup.d.ts +1 -1
  667. package/old-api/validation/validators/yup.js +8 -16
  668. package/old-api/validation/validators/yup.js.map +1 -1
  669. package/openid-connect/cached-oidc-configuration.service.d.ts +3 -3
  670. package/openid-connect/cached-oidc-configuration.service.js +14 -17
  671. package/openid-connect/cached-oidc-configuration.service.js.map +1 -1
  672. package/openid-connect/index.d.ts +7 -7
  673. package/openid-connect/index.js +11 -27
  674. package/openid-connect/index.js.map +1 -1
  675. package/openid-connect/mongo-oidc-state.repository.d.ts +8 -8
  676. package/openid-connect/mongo-oidc-state.repository.js +15 -19
  677. package/openid-connect/mongo-oidc-state.repository.js.map +1 -1
  678. package/openid-connect/oidc-configuration.service.d.ts +1 -1
  679. package/openid-connect/oidc-configuration.service.js +11 -14
  680. package/openid-connect/oidc-configuration.service.js.map +1 -1
  681. package/openid-connect/oidc-state.model.d.ts +1 -1
  682. package/openid-connect/oidc-state.model.js +1 -2
  683. package/openid-connect/oidc-state.repository.d.ts +2 -2
  684. package/openid-connect/oidc-state.repository.js +2 -6
  685. package/openid-connect/oidc-state.repository.js.map +1 -1
  686. package/openid-connect/oidc.service-model.js +1 -2
  687. package/openid-connect/oidc.service.d.ts +4 -4
  688. package/openid-connect/oidc.service.js +31 -34
  689. package/openid-connect/oidc.service.js.map +1 -1
  690. package/package.json +2 -1
  691. package/process-shutdown.d.ts +2 -2
  692. package/process-shutdown.js +11 -18
  693. package/process-shutdown.js.map +1 -1
  694. package/promise/cancelable-promise.js +1 -5
  695. package/promise/cancelable-promise.js.map +1 -1
  696. package/promise/deferred-promise.js +1 -5
  697. package/promise/deferred-promise.js.map +1 -1
  698. package/promise/index.d.ts +2 -2
  699. package/promise/index.js +2 -18
  700. package/promise/index.js.map +1 -1
  701. package/queue/enqueue-batch.d.ts +1 -1
  702. package/queue/enqueue-batch.js +2 -6
  703. package/queue/enqueue-batch.js.map +1 -1
  704. package/queue/index.d.ts +3 -3
  705. package/queue/index.js +3 -19
  706. package/queue/index.js.map +1 -1
  707. package/queue/mongo/index.d.ts +4 -4
  708. package/queue/mongo/index.js +4 -20
  709. package/queue/mongo/index.js.map +1 -1
  710. package/queue/mongo/job.d.ts +3 -3
  711. package/queue/mongo/job.js +1 -2
  712. package/queue/mongo/mongo-job.repository.d.ts +7 -7
  713. package/queue/mongo/mongo-job.repository.js +20 -34
  714. package/queue/mongo/mongo-job.repository.js.map +1 -1
  715. package/queue/mongo/queue.d.ts +6 -6
  716. package/queue/mongo/queue.js +62 -111
  717. package/queue/mongo/queue.js.map +1 -1
  718. package/queue/mongo/queue.provider.d.ts +10 -10
  719. package/queue/mongo/queue.provider.js +16 -20
  720. package/queue/mongo/queue.provider.js.map +1 -1
  721. package/queue/provider.d.ts +1 -1
  722. package/queue/provider.js +1 -5
  723. package/queue/provider.js.map +1 -1
  724. package/queue/queue.d.ts +4 -4
  725. package/queue/queue.js +9 -13
  726. package/queue/queue.js.map +1 -1
  727. package/random/index.d.ts +1 -1
  728. package/random/index.js +1 -17
  729. package/random/index.js.map +1 -1
  730. package/random/number/index.d.ts +3 -3
  731. package/random/number/index.js +3 -19
  732. package/random/number/index.js.map +1 -1
  733. package/random/number/mulberry32.d.ts +1 -1
  734. package/random/number/mulberry32.js +3 -8
  735. package/random/number/mulberry32.js.map +1 -1
  736. package/random/number/seeded.js +1 -5
  737. package/random/number/seeded.js.map +1 -1
  738. package/random/number/sfc32.d.ts +1 -1
  739. package/random/number/sfc32.js +3 -8
  740. package/random/number/sfc32.js.map +1 -1
  741. package/rxjs/cast.js +2 -7
  742. package/rxjs/cast.js.map +1 -1
  743. package/rxjs/index.d.ts +11 -11
  744. package/rxjs/index.js +11 -27
  745. package/rxjs/index.js.map +1 -1
  746. package/rxjs/intersection-observer.js +10 -25
  747. package/rxjs/intersection-observer.js.map +1 -1
  748. package/rxjs/mutation-observer.js +11 -27
  749. package/rxjs/mutation-observer.js.map +1 -1
  750. package/rxjs/noop.js +2 -7
  751. package/rxjs/noop.js.map +1 -1
  752. package/rxjs/performance-observer.js +9 -13
  753. package/rxjs/performance-observer.js.map +1 -1
  754. package/rxjs/resize-observer.js +11 -27
  755. package/rxjs/resize-observer.js.map +1 -1
  756. package/rxjs/retry-backoff.d.ts +1 -1
  757. package/rxjs/retry-backoff.js +13 -18
  758. package/rxjs/retry-backoff.js.map +1 -1
  759. package/rxjs/slow-array.js +8 -17
  760. package/rxjs/slow-array.js.map +1 -1
  761. package/rxjs/teardown.js +3 -7
  762. package/rxjs/teardown.js.map +1 -1
  763. package/rxjs/timing.js +14 -17
  764. package/rxjs/timing.js.map +1 -1
  765. package/rxjs/touch.js +7 -11
  766. package/rxjs/touch.js.map +1 -1
  767. package/schema/index.d.ts +4 -4
  768. package/schema/index.js +4 -20
  769. package/schema/index.js.map +1 -1
  770. package/schema/schema.error.d.ts +2 -2
  771. package/schema/schema.error.js +6 -11
  772. package/schema/schema.error.js.map +1 -1
  773. package/schema/schema.validator.d.ts +4 -4
  774. package/schema/schema.validator.js +19 -26
  775. package/schema/schema.validator.js.map +1 -1
  776. package/schema/schemas/any.d.ts +3 -3
  777. package/schema/schemas/any.js +9 -11
  778. package/schema/schemas/any.js.map +1 -1
  779. package/schema/schemas/array.d.ts +4 -4
  780. package/schema/schemas/array.js +20 -21
  781. package/schema/schemas/array.js.map +1 -1
  782. package/schema/schemas/async-iterable.d.ts +4 -4
  783. package/schema/schemas/async-iterable.js +18 -19
  784. package/schema/schemas/async-iterable.js.map +1 -1
  785. package/schema/schemas/boolean.d.ts +4 -4
  786. package/schema/schemas/boolean.js +13 -16
  787. package/schema/schemas/boolean.js.map +1 -1
  788. package/schema/schemas/date.d.ts +4 -4
  789. package/schema/schemas/date.js +22 -25
  790. package/schema/schemas/date.js.map +1 -1
  791. package/schema/schemas/defaulted.d.ts +5 -5
  792. package/schema/schemas/defaulted.js +14 -14
  793. package/schema/schemas/defaulted.js.map +1 -1
  794. package/schema/schemas/enumeration.d.ts +6 -6
  795. package/schema/schemas/enumeration.js +24 -26
  796. package/schema/schemas/enumeration.js.map +1 -1
  797. package/schema/schemas/index.d.ts +24 -24
  798. package/schema/schemas/index.js +24 -40
  799. package/schema/schemas/index.js.map +1 -1
  800. package/schema/schemas/instance.d.ts +5 -5
  801. package/schema/schemas/instance.js +13 -14
  802. package/schema/schemas/instance.js.map +1 -1
  803. package/schema/schemas/iterable.d.ts +4 -4
  804. package/schema/schemas/iterable.js +18 -19
  805. package/schema/schemas/iterable.js.map +1 -1
  806. package/schema/schemas/literal.d.ts +4 -4
  807. package/schema/schemas/literal.js +12 -13
  808. package/schema/schemas/literal.js.map +1 -1
  809. package/schema/schemas/never.d.ts +4 -4
  810. package/schema/schemas/never.js +12 -14
  811. package/schema/schemas/never.js.map +1 -1
  812. package/schema/schemas/nullable.d.ts +4 -4
  813. package/schema/schemas/nullable.js +14 -16
  814. package/schema/schemas/nullable.js.map +1 -1
  815. package/schema/schemas/number.d.ts +4 -4
  816. package/schema/schemas/number.js +21 -24
  817. package/schema/schemas/number.js.map +1 -1
  818. package/schema/schemas/object.d.ts +5 -5
  819. package/schema/schemas/object.js +24 -26
  820. package/schema/schemas/object.js.map +1 -1
  821. package/schema/schemas/optional.d.ts +4 -4
  822. package/schema/schemas/optional.js +14 -16
  823. package/schema/schemas/optional.js.map +1 -1
  824. package/schema/schemas/preprocess.d.ts +4 -4
  825. package/schema/schemas/preprocess.js +16 -16
  826. package/schema/schemas/preprocess.js.map +1 -1
  827. package/schema/schemas/readable-stream.d.ts +4 -4
  828. package/schema/schemas/readable-stream.js +12 -14
  829. package/schema/schemas/readable-stream.js.map +1 -1
  830. package/schema/schemas/refine.d.ts +5 -5
  831. package/schema/schemas/refine.js +19 -19
  832. package/schema/schemas/refine.js.map +1 -1
  833. package/schema/schemas/regexp.d.ts +4 -4
  834. package/schema/schemas/regexp.js +16 -19
  835. package/schema/schemas/regexp.js.map +1 -1
  836. package/schema/schemas/string.d.ts +4 -4
  837. package/schema/schemas/string.js +22 -26
  838. package/schema/schemas/string.js.map +1 -1
  839. package/schema/schemas/transform.d.ts +4 -4
  840. package/schema/schemas/transform.js +16 -16
  841. package/schema/schemas/transform.js.map +1 -1
  842. package/schema/schemas/uint8-array.d.ts +4 -4
  843. package/schema/schemas/uint8-array.js +19 -22
  844. package/schema/schemas/uint8-array.js.map +1 -1
  845. package/schema/schemas/union.d.ts +4 -4
  846. package/schema/schemas/union.js +14 -15
  847. package/schema/schemas/union.js.map +1 -1
  848. package/schema/schemas/unknown.d.ts +3 -3
  849. package/schema/schemas/unknown.js +9 -11
  850. package/schema/schemas/unknown.js.map +1 -1
  851. package/schema/types.d.ts +2 -2
  852. package/schema/types.js +1 -5
  853. package/schema/types.js.map +1 -1
  854. package/search-index/elastic/config.d.ts +3 -3
  855. package/search-index/elastic/config.js +6 -9
  856. package/search-index/elastic/config.js.map +1 -1
  857. package/search-index/elastic/index.d.ts +5 -5
  858. package/search-index/elastic/index.js +5 -21
  859. package/search-index/elastic/index.js.map +1 -1
  860. package/search-index/elastic/model/elastic-query.d.ts +1 -1
  861. package/search-index/elastic/model/elastic-query.js +1 -2
  862. package/search-index/elastic/model/index-mapping.d.ts +3 -3
  863. package/search-index/elastic/model/index-mapping.js +3 -7
  864. package/search-index/elastic/model/index-mapping.js.map +1 -1
  865. package/search-index/elastic/model/index.d.ts +3 -3
  866. package/search-index/elastic/model/index.js +3 -19
  867. package/search-index/elastic/model/index.js.map +1 -1
  868. package/search-index/elastic/model/sort.d.ts +3 -3
  869. package/search-index/elastic/model/sort.js +1 -2
  870. package/search-index/elastic/module.d.ts +4 -4
  871. package/search-index/elastic/module.js +22 -28
  872. package/search-index/elastic/module.js.map +1 -1
  873. package/search-index/elastic/query-builder/boolean-query-builder.d.ts +1 -1
  874. package/search-index/elastic/query-builder/boolean-query-builder.js +1 -5
  875. package/search-index/elastic/query-builder/boolean-query-builder.js.map +1 -1
  876. package/search-index/elastic/query-builder/index.d.ts +1 -1
  877. package/search-index/elastic/query-builder/index.js +1 -17
  878. package/search-index/elastic/query-builder/index.js.map +1 -1
  879. package/search-index/elastic/query-converter.d.ts +4 -4
  880. package/search-index/elastic/query-converter.js +29 -37
  881. package/search-index/elastic/query-converter.js.map +1 -1
  882. package/search-index/elastic/search-index.d.ts +9 -9
  883. package/search-index/elastic/search-index.js +36 -51
  884. package/search-index/elastic/search-index.js.map +1 -1
  885. package/search-index/elastic/sort-converter.d.ts +2 -2
  886. package/search-index/elastic/sort-converter.js +3 -8
  887. package/search-index/elastic/sort-converter.js.map +1 -1
  888. package/search-index/elastic/types.d.ts +1 -1
  889. package/search-index/elastic/types.js +1 -2
  890. package/search-index/error.d.ts +1 -1
  891. package/search-index/error.js +4 -8
  892. package/search-index/error.js.map +1 -1
  893. package/search-index/index.d.ts +3 -3
  894. package/search-index/index.js +3 -19
  895. package/search-index/index.js.map +1 -1
  896. package/search-index/memory/index.d.ts +1 -1
  897. package/search-index/memory/index.js +1 -17
  898. package/search-index/memory/index.js.map +1 -1
  899. package/search-index/memory/memory-search-index.d.ts +4 -3
  900. package/search-index/memory/memory-search-index.js +25 -30
  901. package/search-index/memory/memory-search-index.js.map +1 -1
  902. package/search-index/search-index.d.ts +2 -3
  903. package/search-index/search-index.js +11 -41
  904. package/search-index/search-index.js.map +1 -1
  905. package/search-index/search-result.d.ts +1 -1
  906. package/search-index/search-result.js +1 -2
  907. package/serializer/handlers/binary.d.ts +2 -2
  908. package/serializer/handlers/binary.js +11 -20
  909. package/serializer/handlers/binary.js.map +1 -1
  910. package/serializer/handlers/date.js +2 -7
  911. package/serializer/handlers/date.js.map +1 -1
  912. package/serializer/handlers/error.js +2 -7
  913. package/serializer/handlers/error.js.map +1 -1
  914. package/serializer/handlers/index.d.ts +7 -7
  915. package/serializer/handlers/index.js +7 -23
  916. package/serializer/handlers/index.js.map +1 -1
  917. package/serializer/handlers/map.d.ts +1 -1
  918. package/serializer/handlers/map.js +2 -7
  919. package/serializer/handlers/map.js.map +1 -1
  920. package/serializer/handlers/regex.js +2 -7
  921. package/serializer/handlers/regex.js.map +1 -1
  922. package/serializer/handlers/register.d.ts +1 -1
  923. package/serializer/handlers/register.js +17 -21
  924. package/serializer/handlers/register.js.map +1 -1
  925. package/serializer/handlers/set.d.ts +2 -2
  926. package/serializer/handlers/set.js +2 -7
  927. package/serializer/handlers/set.js.map +1 -1
  928. package/serializer/index.d.ts +4 -4
  929. package/serializer/index.js +3 -24
  930. package/serializer/index.js.map +1 -1
  931. package/serializer/serializable.d.ts +1 -1
  932. package/serializer/serializable.js +15 -24
  933. package/serializer/serializable.js.map +1 -1
  934. package/serializer/serializer.d.ts +2 -2
  935. package/serializer/serializer.js +30 -37
  936. package/serializer/serializer.js.map +1 -1
  937. package/serializer/types.d.ts +1 -1
  938. package/serializer/types.js +5 -8
  939. package/serializer/types.js.map +1 -1
  940. package/tailwind/colors.d.ts +1 -1
  941. package/tailwind/colors.js +4 -10
  942. package/tailwind/colors.js.map +1 -1
  943. package/tailwind/index.d.ts +1 -1
  944. package/tailwind/index.js +1 -17
  945. package/tailwind/index.js.map +1 -1
  946. package/tokens.d.ts +1 -1
  947. package/tokens.js +2 -5
  948. package/tokens.js.map +1 -1
  949. package/tsconfig.json +7 -3
  950. package/types/geo-json.d.ts +1 -1
  951. package/types/geo-json.js +1 -2
  952. package/types.js +1 -2
  953. package/types.js.map +1 -1
  954. package/utils/alphabet.js +2 -5
  955. package/utils/alphabet.js.map +1 -1
  956. package/utils/any-iterable-iterator.js +4 -8
  957. package/utils/any-iterable-iterator.js.map +1 -1
  958. package/utils/array/array-backtracker.js +8 -12
  959. package/utils/array/array-backtracker.js.map +1 -1
  960. package/utils/array/array.js +13 -21
  961. package/utils/array/array.js.map +1 -1
  962. package/utils/array/index.d.ts +2 -2
  963. package/utils/array/index.js +2 -18
  964. package/utils/array/index.js.map +1 -1
  965. package/utils/async-iterable-helpers/all.d.ts +2 -2
  966. package/utils/async-iterable-helpers/all.js +9 -31
  967. package/utils/async-iterable-helpers/all.js.map +1 -1
  968. package/utils/async-iterable-helpers/any.d.ts +2 -2
  969. package/utils/async-iterable-helpers/any.js +9 -31
  970. package/utils/async-iterable-helpers/any.js.map +1 -1
  971. package/utils/async-iterable-helpers/assert.d.ts +2 -2
  972. package/utils/async-iterable-helpers/assert.js +22 -60
  973. package/utils/async-iterable-helpers/assert.js.map +1 -1
  974. package/utils/async-iterable-helpers/batch.d.ts +1 -1
  975. package/utils/async-iterable-helpers/batch.js +25 -63
  976. package/utils/async-iterable-helpers/batch.js.map +1 -1
  977. package/utils/async-iterable-helpers/buffer.d.ts +1 -1
  978. package/utils/async-iterable-helpers/buffer.js +43 -90
  979. package/utils/async-iterable-helpers/buffer.js.map +1 -1
  980. package/utils/async-iterable-helpers/concat.d.ts +1 -1
  981. package/utils/async-iterable-helpers/concat.js +3 -33
  982. package/utils/async-iterable-helpers/concat.js.map +1 -1
  983. package/utils/async-iterable-helpers/default-if-empty.d.ts +1 -1
  984. package/utils/async-iterable-helpers/default-if-empty.js +9 -45
  985. package/utils/async-iterable-helpers/default-if-empty.js.map +1 -1
  986. package/utils/async-iterable-helpers/deferred.d.ts +1 -1
  987. package/utils/async-iterable-helpers/deferred.js +3 -33
  988. package/utils/async-iterable-helpers/deferred.js.map +1 -1
  989. package/utils/async-iterable-helpers/distinct.d.ts +2 -2
  990. package/utils/async-iterable-helpers/distinct.js +23 -61
  991. package/utils/async-iterable-helpers/distinct.js.map +1 -1
  992. package/utils/async-iterable-helpers/drain.d.ts +1 -1
  993. package/utils/async-iterable-helpers/drain.js +3 -24
  994. package/utils/async-iterable-helpers/drain.js.map +1 -1
  995. package/utils/async-iterable-helpers/filter.d.ts +2 -2
  996. package/utils/async-iterable-helpers/filter.js +22 -60
  997. package/utils/async-iterable-helpers/filter.js.map +1 -1
  998. package/utils/async-iterable-helpers/first-or-default.d.ts +3 -3
  999. package/utils/async-iterable-helpers/first-or-default.js +6 -28
  1000. package/utils/async-iterable-helpers/first-or-default.js.map +1 -1
  1001. package/utils/async-iterable-helpers/first.d.ts +3 -3
  1002. package/utils/async-iterable-helpers/first.js +6 -28
  1003. package/utils/async-iterable-helpers/first.js.map +1 -1
  1004. package/utils/async-iterable-helpers/for-each.d.ts +2 -2
  1005. package/utils/async-iterable-helpers/for-each.js +7 -29
  1006. package/utils/async-iterable-helpers/for-each.js.map +1 -1
  1007. package/utils/async-iterable-helpers/group-single.d.ts +2 -2
  1008. package/utils/async-iterable-helpers/group-single.js +3 -33
  1009. package/utils/async-iterable-helpers/group-single.js.map +1 -1
  1010. package/utils/async-iterable-helpers/group-to-map.d.ts +2 -2
  1011. package/utils/async-iterable-helpers/group-to-map.js +9 -31
  1012. package/utils/async-iterable-helpers/group-to-map.js.map +1 -1
  1013. package/utils/async-iterable-helpers/group-to-single-map.d.ts +2 -2
  1014. package/utils/async-iterable-helpers/group-to-single-map.js +8 -30
  1015. package/utils/async-iterable-helpers/group-to-single-map.js.map +1 -1
  1016. package/utils/async-iterable-helpers/group.d.ts +2 -2
  1017. package/utils/async-iterable-helpers/group.js +3 -33
  1018. package/utils/async-iterable-helpers/group.js.map +1 -1
  1019. package/utils/async-iterable-helpers/index.d.ts +45 -45
  1020. package/utils/async-iterable-helpers/index.js +45 -61
  1021. package/utils/async-iterable-helpers/index.js.map +1 -1
  1022. package/utils/async-iterable-helpers/interrupt.d.ts +1 -1
  1023. package/utils/async-iterable-helpers/interrupt.js +19 -69
  1024. package/utils/async-iterable-helpers/interrupt.js.map +1 -1
  1025. package/utils/async-iterable-helpers/is-async-iterable.d.ts +1 -1
  1026. package/utils/async-iterable-helpers/is-async-iterable.js +5 -10
  1027. package/utils/async-iterable-helpers/is-async-iterable.js.map +1 -1
  1028. package/utils/async-iterable-helpers/last-or-default.d.ts +3 -3
  1029. package/utils/async-iterable-helpers/last-or-default.js +6 -28
  1030. package/utils/async-iterable-helpers/last-or-default.js.map +1 -1
  1031. package/utils/async-iterable-helpers/last.d.ts +3 -3
  1032. package/utils/async-iterable-helpers/last.js +6 -28
  1033. package/utils/async-iterable-helpers/last.js.map +1 -1
  1034. package/utils/async-iterable-helpers/map-many.d.ts +2 -2
  1035. package/utils/async-iterable-helpers/map-many.js +19 -62
  1036. package/utils/async-iterable-helpers/map-many.js.map +1 -1
  1037. package/utils/async-iterable-helpers/map.d.ts +2 -2
  1038. package/utils/async-iterable-helpers/map.js +19 -57
  1039. package/utils/async-iterable-helpers/map.js.map +1 -1
  1040. package/utils/async-iterable-helpers/materialize.d.ts +1 -1
  1041. package/utils/async-iterable-helpers/materialize.js +9 -41
  1042. package/utils/async-iterable-helpers/materialize.js.map +1 -1
  1043. package/utils/async-iterable-helpers/metadata.d.ts +2 -2
  1044. package/utils/async-iterable-helpers/metadata.js +35 -75
  1045. package/utils/async-iterable-helpers/metadata.js.map +1 -1
  1046. package/utils/async-iterable-helpers/multiplex.d.ts +1 -1
  1047. package/utils/async-iterable-helpers/multiplex.js +7 -29
  1048. package/utils/async-iterable-helpers/multiplex.js.map +1 -1
  1049. package/utils/async-iterable-helpers/observable-iterable.js +31 -49
  1050. package/utils/async-iterable-helpers/observable-iterable.js.map +1 -1
  1051. package/utils/async-iterable-helpers/pairwise.d.ts +1 -1
  1052. package/utils/async-iterable-helpers/pairwise.js +24 -62
  1053. package/utils/async-iterable-helpers/pairwise.js.map +1 -1
  1054. package/utils/async-iterable-helpers/parallel/feed.d.ts +2 -2
  1055. package/utils/async-iterable-helpers/parallel/feed.js +24 -54
  1056. package/utils/async-iterable-helpers/parallel/feed.js.map +1 -1
  1057. package/utils/async-iterable-helpers/parallel/filter.d.ts +2 -2
  1058. package/utils/async-iterable-helpers/parallel/filter.js +3 -7
  1059. package/utils/async-iterable-helpers/parallel/filter.js.map +1 -1
  1060. package/utils/async-iterable-helpers/parallel/for-each.d.ts +2 -2
  1061. package/utils/async-iterable-helpers/parallel/for-each.js +13 -35
  1062. package/utils/async-iterable-helpers/parallel/for-each.js.map +1 -1
  1063. package/utils/async-iterable-helpers/parallel/group.d.ts +2 -2
  1064. package/utils/async-iterable-helpers/parallel/group.js +5 -9
  1065. package/utils/async-iterable-helpers/parallel/group.js.map +1 -1
  1066. package/utils/async-iterable-helpers/parallel/index.d.ts +7 -7
  1067. package/utils/async-iterable-helpers/parallel/index.js +7 -23
  1068. package/utils/async-iterable-helpers/parallel/index.js.map +1 -1
  1069. package/utils/async-iterable-helpers/parallel/map.d.ts +2 -2
  1070. package/utils/async-iterable-helpers/parallel/map.js +3 -7
  1071. package/utils/async-iterable-helpers/parallel/map.js.map +1 -1
  1072. package/utils/async-iterable-helpers/parallel/tap.d.ts +2 -2
  1073. package/utils/async-iterable-helpers/parallel/tap.js +3 -7
  1074. package/utils/async-iterable-helpers/parallel/tap.js.map +1 -1
  1075. package/utils/async-iterable-helpers/parallel/types.js +1 -2
  1076. package/utils/async-iterable-helpers/reduce.d.ts +2 -2
  1077. package/utils/async-iterable-helpers/reduce.js +11 -33
  1078. package/utils/async-iterable-helpers/reduce.js.map +1 -1
  1079. package/utils/async-iterable-helpers/retry.d.ts +2 -2
  1080. package/utils/async-iterable-helpers/retry.js +41 -79
  1081. package/utils/async-iterable-helpers/retry.js.map +1 -1
  1082. package/utils/async-iterable-helpers/single-or-default.d.ts +3 -3
  1083. package/utils/async-iterable-helpers/single-or-default.js +11 -33
  1084. package/utils/async-iterable-helpers/single-or-default.js.map +1 -1
  1085. package/utils/async-iterable-helpers/single.d.ts +3 -3
  1086. package/utils/async-iterable-helpers/single.js +11 -33
  1087. package/utils/async-iterable-helpers/single.js.map +1 -1
  1088. package/utils/async-iterable-helpers/skip.d.ts +1 -1
  1089. package/utils/async-iterable-helpers/skip.js +3 -7
  1090. package/utils/async-iterable-helpers/skip.js.map +1 -1
  1091. package/utils/async-iterable-helpers/sort.d.ts +2 -2
  1092. package/utils/async-iterable-helpers/sort.js +5 -9
  1093. package/utils/async-iterable-helpers/sort.js.map +1 -1
  1094. package/utils/async-iterable-helpers/take-until.d.ts +2 -2
  1095. package/utils/async-iterable-helpers/take-until.js +30 -52
  1096. package/utils/async-iterable-helpers/take-until.js.map +1 -1
  1097. package/utils/async-iterable-helpers/take-while.d.ts +2 -2
  1098. package/utils/async-iterable-helpers/take-while.js +28 -66
  1099. package/utils/async-iterable-helpers/take-while.js.map +1 -1
  1100. package/utils/async-iterable-helpers/take.d.ts +1 -1
  1101. package/utils/async-iterable-helpers/take.js +10 -46
  1102. package/utils/async-iterable-helpers/take.js.map +1 -1
  1103. package/utils/async-iterable-helpers/tap.d.ts +2 -2
  1104. package/utils/async-iterable-helpers/tap.js +19 -57
  1105. package/utils/async-iterable-helpers/tap.js.map +1 -1
  1106. package/utils/async-iterable-helpers/throttle.d.ts +2 -2
  1107. package/utils/async-iterable-helpers/throttle.js +9 -45
  1108. package/utils/async-iterable-helpers/throttle.js.map +1 -1
  1109. package/utils/async-iterable-helpers/to-array.d.ts +1 -1
  1110. package/utils/async-iterable-helpers/to-array.js +5 -27
  1111. package/utils/async-iterable-helpers/to-array.js.map +1 -1
  1112. package/utils/async-iterable-helpers/to-async-iterable-iterator.d.ts +1 -1
  1113. package/utils/async-iterable-helpers/to-async-iterable-iterator.js +36 -74
  1114. package/utils/async-iterable-helpers/to-async-iterable-iterator.js.map +1 -1
  1115. package/utils/async-iterable-helpers/to-async-iterator.d.ts +1 -1
  1116. package/utils/async-iterable-helpers/to-async-iterator.js +9 -14
  1117. package/utils/async-iterable-helpers/to-async-iterator.js.map +1 -1
  1118. package/utils/async-iterable-helpers/to-sync-iterable.d.ts +1 -1
  1119. package/utils/async-iterable-helpers/to-sync-iterable.js +5 -9
  1120. package/utils/async-iterable-helpers/to-sync-iterable.js.map +1 -1
  1121. package/utils/async-iterable-helpers/types.d.ts +1 -1
  1122. package/utils/async-iterable-helpers/types.js +1 -2
  1123. package/utils/async-iterable-helpers/while.d.ts +2 -2
  1124. package/utils/async-iterable-helpers/while.js +24 -62
  1125. package/utils/async-iterable-helpers/while.js.map +1 -1
  1126. package/utils/async-iterator-iterable-iterator.js +24 -42
  1127. package/utils/async-iterator-iterable-iterator.js.map +1 -1
  1128. package/utils/backoff.d.ts +2 -2
  1129. package/utils/backoff.js +30 -53
  1130. package/utils/backoff.js.map +1 -1
  1131. package/utils/base64.d.ts +1 -1
  1132. package/utils/base64.js +15 -26
  1133. package/utils/base64.js.map +1 -1
  1134. package/utils/benchmark.js +17 -25
  1135. package/utils/benchmark.js.map +1 -1
  1136. package/utils/binary-search.d.ts +1 -1
  1137. package/utils/binary-search.js +10 -21
  1138. package/utils/binary-search.js.map +1 -1
  1139. package/utils/binary.d.ts +1 -1
  1140. package/utils/binary.js +7 -13
  1141. package/utils/binary.js.map +1 -1
  1142. package/utils/cancellation-token.js +22 -26
  1143. package/utils/cancellation-token.js.map +1 -1
  1144. package/utils/comparison.js +7 -17
  1145. package/utils/comparison.js.map +1 -1
  1146. package/utils/compression.d.ts +2 -2
  1147. package/utils/compression.js +18 -25
  1148. package/utils/compression.js.map +1 -1
  1149. package/utils/config-parser.js +11 -18
  1150. package/utils/config-parser.js.map +1 -1
  1151. package/utils/cryptography.d.ts +1 -1
  1152. package/utils/cryptography.js +54 -69
  1153. package/utils/cryptography.js.map +1 -1
  1154. package/utils/date-time.js +34 -57
  1155. package/utils/date-time.js.map +1 -1
  1156. package/utils/encoding.d.ts +1 -1
  1157. package/utils/encoding.js +12 -19
  1158. package/utils/encoding.js.map +1 -1
  1159. package/utils/enum.d.ts +1 -1
  1160. package/utils/enum.js +7 -13
  1161. package/utils/enum.js.map +1 -1
  1162. package/utils/equals.d.ts +2 -2
  1163. package/utils/equals.js +17 -24
  1164. package/utils/equals.js.map +1 -1
  1165. package/utils/event-loop.d.ts +2 -2
  1166. package/utils/event-loop.js +9 -14
  1167. package/utils/event-loop.js.map +1 -1
  1168. package/utils/factory-map.js +2 -6
  1169. package/utils/factory-map.js.map +1 -1
  1170. package/utils/feedable-async-iterable.js +16 -53
  1171. package/utils/feedable-async-iterable.js.map +1 -1
  1172. package/utils/file-reader.js +6 -13
  1173. package/utils/file-reader.js.map +1 -1
  1174. package/utils/function/index.d.ts +2 -2
  1175. package/utils/function/index.js +2 -18
  1176. package/utils/function/index.js.map +1 -1
  1177. package/utils/function/memoize.js +4 -9
  1178. package/utils/function/memoize.js.map +1 -1
  1179. package/utils/function/throttle.js +5 -9
  1180. package/utils/function/throttle.js.map +1 -1
  1181. package/utils/helpers.d.ts +1 -1
  1182. package/utils/helpers.js +54 -86
  1183. package/utils/helpers.js.map +1 -1
  1184. package/utils/image.js +22 -30
  1185. package/utils/image.js.map +1 -1
  1186. package/utils/index.d.ts +42 -42
  1187. package/utils/index.js +42 -58
  1188. package/utils/index.js.map +1 -1
  1189. package/utils/iterable-helpers/all.d.ts +1 -1
  1190. package/utils/iterable-helpers/all.js +1 -5
  1191. package/utils/iterable-helpers/all.js.map +1 -1
  1192. package/utils/iterable-helpers/any.d.ts +1 -1
  1193. package/utils/iterable-helpers/any.js +1 -5
  1194. package/utils/iterable-helpers/any.js.map +1 -1
  1195. package/utils/iterable-helpers/assert.d.ts +1 -1
  1196. package/utils/iterable-helpers/assert.js +3 -7
  1197. package/utils/iterable-helpers/assert.js.map +1 -1
  1198. package/utils/iterable-helpers/batch.js +1 -5
  1199. package/utils/iterable-helpers/batch.js.map +1 -1
  1200. package/utils/iterable-helpers/concat.js +1 -5
  1201. package/utils/iterable-helpers/concat.js.map +1 -1
  1202. package/utils/iterable-helpers/default-if-empty.js +1 -5
  1203. package/utils/iterable-helpers/default-if-empty.js.map +1 -1
  1204. package/utils/iterable-helpers/deferred.js +1 -5
  1205. package/utils/iterable-helpers/deferred.js.map +1 -1
  1206. package/utils/iterable-helpers/distinct.d.ts +1 -1
  1207. package/utils/iterable-helpers/distinct.js +1 -5
  1208. package/utils/iterable-helpers/distinct.js.map +1 -1
  1209. package/utils/iterable-helpers/drain.js +1 -5
  1210. package/utils/iterable-helpers/drain.js.map +1 -1
  1211. package/utils/iterable-helpers/filter.d.ts +1 -1
  1212. package/utils/iterable-helpers/filter.js +1 -5
  1213. package/utils/iterable-helpers/filter.js.map +1 -1
  1214. package/utils/iterable-helpers/first-or-default.d.ts +1 -1
  1215. package/utils/iterable-helpers/first-or-default.js +3 -7
  1216. package/utils/iterable-helpers/first-or-default.js.map +1 -1
  1217. package/utils/iterable-helpers/first.d.ts +1 -1
  1218. package/utils/iterable-helpers/first.js +3 -7
  1219. package/utils/iterable-helpers/first.js.map +1 -1
  1220. package/utils/iterable-helpers/for-each.d.ts +1 -1
  1221. package/utils/iterable-helpers/for-each.js +1 -5
  1222. package/utils/iterable-helpers/for-each.js.map +1 -1
  1223. package/utils/iterable-helpers/group-single.d.ts +1 -1
  1224. package/utils/iterable-helpers/group-single.js +3 -7
  1225. package/utils/iterable-helpers/group-single.js.map +1 -1
  1226. package/utils/iterable-helpers/group-to-map.d.ts +1 -1
  1227. package/utils/iterable-helpers/group-to-map.js +3 -7
  1228. package/utils/iterable-helpers/group-to-map.js.map +1 -1
  1229. package/utils/iterable-helpers/group-to-single-map.d.ts +1 -1
  1230. package/utils/iterable-helpers/group-to-single-map.js +1 -5
  1231. package/utils/iterable-helpers/group-to-single-map.js.map +1 -1
  1232. package/utils/iterable-helpers/group.d.ts +1 -1
  1233. package/utils/iterable-helpers/group.js +3 -7
  1234. package/utils/iterable-helpers/group.js.map +1 -1
  1235. package/utils/iterable-helpers/index.d.ts +37 -37
  1236. package/utils/iterable-helpers/index.js +37 -53
  1237. package/utils/iterable-helpers/index.js.map +1 -1
  1238. package/utils/iterable-helpers/is-iterable.d.ts +1 -1
  1239. package/utils/iterable-helpers/is-iterable.js +5 -10
  1240. package/utils/iterable-helpers/is-iterable.js.map +1 -1
  1241. package/utils/iterable-helpers/last-or-default.d.ts +1 -1
  1242. package/utils/iterable-helpers/last-or-default.js +3 -7
  1243. package/utils/iterable-helpers/last-or-default.js.map +1 -1
  1244. package/utils/iterable-helpers/last.d.ts +1 -1
  1245. package/utils/iterable-helpers/last.js +3 -7
  1246. package/utils/iterable-helpers/last.js.map +1 -1
  1247. package/utils/iterable-helpers/map-many.d.ts +1 -1
  1248. package/utils/iterable-helpers/map-many.js +1 -5
  1249. package/utils/iterable-helpers/map-many.js.map +1 -1
  1250. package/utils/iterable-helpers/map.d.ts +1 -1
  1251. package/utils/iterable-helpers/map.js +1 -5
  1252. package/utils/iterable-helpers/map.js.map +1 -1
  1253. package/utils/iterable-helpers/materialize.js +1 -5
  1254. package/utils/iterable-helpers/materialize.js.map +1 -1
  1255. package/utils/iterable-helpers/metadata.d.ts +1 -1
  1256. package/utils/iterable-helpers/metadata.js +1 -5
  1257. package/utils/iterable-helpers/metadata.js.map +1 -1
  1258. package/utils/iterable-helpers/pairwise.js +1 -5
  1259. package/utils/iterable-helpers/pairwise.js.map +1 -1
  1260. package/utils/iterable-helpers/range.js +1 -5
  1261. package/utils/iterable-helpers/range.js.map +1 -1
  1262. package/utils/iterable-helpers/reduce.d.ts +1 -1
  1263. package/utils/iterable-helpers/reduce.js +1 -5
  1264. package/utils/iterable-helpers/reduce.js.map +1 -1
  1265. package/utils/iterable-helpers/single-or-default.d.ts +1 -1
  1266. package/utils/iterable-helpers/single-or-default.js +1 -5
  1267. package/utils/iterable-helpers/single-or-default.js.map +1 -1
  1268. package/utils/iterable-helpers/single.d.ts +1 -1
  1269. package/utils/iterable-helpers/single.js +1 -5
  1270. package/utils/iterable-helpers/single.js.map +1 -1
  1271. package/utils/iterable-helpers/skip.js +1 -5
  1272. package/utils/iterable-helpers/skip.js.map +1 -1
  1273. package/utils/iterable-helpers/sort.d.ts +1 -1
  1274. package/utils/iterable-helpers/sort.js +2 -6
  1275. package/utils/iterable-helpers/sort.js.map +1 -1
  1276. package/utils/iterable-helpers/take-until.d.ts +1 -1
  1277. package/utils/iterable-helpers/take-until.js +1 -5
  1278. package/utils/iterable-helpers/take-until.js.map +1 -1
  1279. package/utils/iterable-helpers/take-while.d.ts +1 -1
  1280. package/utils/iterable-helpers/take-while.js +1 -5
  1281. package/utils/iterable-helpers/take-while.js.map +1 -1
  1282. package/utils/iterable-helpers/take.js +1 -5
  1283. package/utils/iterable-helpers/take.js.map +1 -1
  1284. package/utils/iterable-helpers/tap.d.ts +1 -1
  1285. package/utils/iterable-helpers/tap.js +1 -5
  1286. package/utils/iterable-helpers/tap.js.map +1 -1
  1287. package/utils/iterable-helpers/types.js +1 -2
  1288. package/utils/iterable-helpers/while.d.ts +1 -1
  1289. package/utils/iterable-helpers/while.js +1 -5
  1290. package/utils/iterable-helpers/while.js.map +1 -1
  1291. package/utils/jwt.d.ts +2 -2
  1292. package/utils/jwt.js +26 -31
  1293. package/utils/jwt.js.map +1 -1
  1294. package/utils/map.js +7 -15
  1295. package/utils/map.js.map +1 -1
  1296. package/utils/math.js +7 -17
  1297. package/utils/math.js.map +1 -1
  1298. package/utils/middleware.js +2 -7
  1299. package/utils/middleware.js.map +1 -1
  1300. package/utils/moving-metric.js +5 -9
  1301. package/utils/moving-metric.js.map +1 -1
  1302. package/utils/noop.js +1 -5
  1303. package/utils/noop.js.map +1 -1
  1304. package/utils/object/dereference.js +7 -13
  1305. package/utils/object/dereference.js.map +1 -1
  1306. package/utils/object/forward-ref.js +15 -19
  1307. package/utils/object/forward-ref.js.map +1 -1
  1308. package/utils/object/index.d.ts +6 -6
  1309. package/utils/object/index.js +6 -22
  1310. package/utils/object/index.js.map +1 -1
  1311. package/utils/object/lazy-property.d.ts +1 -1
  1312. package/utils/object/lazy-property.js +14 -21
  1313. package/utils/object/lazy-property.js.map +1 -1
  1314. package/utils/object/merge.js +13 -17
  1315. package/utils/object/merge.js.map +1 -1
  1316. package/utils/object/object.d.ts +1 -1
  1317. package/utils/object/object.js +18 -29
  1318. package/utils/object/object.js.map +1 -1
  1319. package/utils/object/property-name.d.ts +1 -1
  1320. package/utils/object/property-name.js +16 -25
  1321. package/utils/object/property-name.js.map +1 -1
  1322. package/utils/ordered-feedable-async-iterable.d.ts +1 -1
  1323. package/utils/ordered-feedable-async-iterable.js +3 -7
  1324. package/utils/ordered-feedable-async-iterable.js.map +1 -1
  1325. package/utils/patch-worker.d.ts +2 -2
  1326. package/utils/patch-worker.js +23 -29
  1327. package/utils/patch-worker.js.map +1 -1
  1328. package/utils/patterns.js +4 -8
  1329. package/utils/patterns.js.map +1 -1
  1330. package/utils/periodic-reporter.js +9 -13
  1331. package/utils/periodic-reporter.js.map +1 -1
  1332. package/utils/periodic-sampler.js +15 -19
  1333. package/utils/periodic-sampler.js.map +1 -1
  1334. package/utils/provider-function-iterable.js +14 -32
  1335. package/utils/provider-function-iterable.js.map +1 -1
  1336. package/utils/random.js +4 -9
  1337. package/utils/random.js.map +1 -1
  1338. package/utils/reflection.d.ts +1 -1
  1339. package/utils/reflection.js +7 -16
  1340. package/utils/reflection.js.map +1 -1
  1341. package/utils/set.js +7 -15
  1342. package/utils/set.js.map +1 -1
  1343. package/utils/singleton.js +3 -7
  1344. package/utils/singleton.js.map +1 -1
  1345. package/utils/sort.js +5 -12
  1346. package/utils/sort.js.map +1 -1
  1347. package/utils/stream/async-iterable-readable.d.ts +3 -3
  1348. package/utils/stream/async-iterable-readable.js +8 -13
  1349. package/utils/stream/async-iterable-readable.js.map +1 -1
  1350. package/utils/stream/async-writable-stream.d.ts +3 -3
  1351. package/utils/stream/async-writable-stream.js +3 -7
  1352. package/utils/stream/async-writable-stream.js.map +1 -1
  1353. package/utils/stream/index.d.ts +5 -5
  1354. package/utils/stream/index.js +5 -21
  1355. package/utils/stream/index.js.map +1 -1
  1356. package/utils/stream/stream-helper-types.d.ts +1 -1
  1357. package/utils/stream/stream-helper-types.js +1 -2
  1358. package/utils/stream/stream-reader.js +20 -51
  1359. package/utils/stream/stream-reader.js.map +1 -1
  1360. package/utils/stream/typed-readable.d.ts +2 -2
  1361. package/utils/stream/typed-readable.js +2 -5
  1362. package/utils/stream/typed-readable.js.map +1 -1
  1363. package/utils/timer.js +1 -5
  1364. package/utils/timer.js.map +1 -1
  1365. package/utils/timing.d.ts +1 -9
  1366. package/utils/timing.js +12 -23
  1367. package/utils/timing.js.map +1 -1
  1368. package/utils/type-guards.d.ts +1 -1
  1369. package/utils/type-guards.js +209 -422
  1370. package/utils/type-guards.js.map +1 -1
  1371. package/utils/type-of.js +4 -9
  1372. package/utils/type-of.js.map +1 -1
  1373. package/utils/units.js +51 -55
  1374. package/utils/units.js.map +1 -1
  1375. package/utils/url-builder.d.ts +1 -1
  1376. package/utils/url-builder.js +12 -29
  1377. package/utils/url-builder.js.map +1 -1
  1378. package/utils/z-base32.d.ts +1 -1
  1379. package/utils/z-base32.js +6 -11
  1380. package/utils/z-base32.js.map +1 -1
  1381. package/database/mongo/model/document.js +0 -75
  1382. package/database/mongo/model/document.js.map +0 -1
  1383. package/database/mongo/model/index.d.ts +0 -1
  1384. package/database/mongo/model/index.js +0 -18
  1385. package/database/mongo/model/index.js.map +0 -1
  1386. package/database/mongo/mongo-entity-repository.js.map +0 -1
  1387. package/database/mongo/simple-entity-repository.d.ts +0 -7
  1388. package/database/mongo/simple-entity-repository.js +0 -11
  1389. package/database/mongo/simple-entity-repository.js.map +0 -1
  1390. package/lock/mongo/mongo-lock-repository.js.map +0 -1
  1391. package/rxjs/compat/first-value-from.d.ts +0 -2
  1392. package/rxjs/compat/first-value-from.js +0 -9
  1393. package/rxjs/compat/first-value-from.js.map +0 -1
  1394. package/rxjs/compat/index.d.ts +0 -1
  1395. package/rxjs/compat/index.js +0 -18
  1396. package/rxjs/compat/index.js.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"iterable.js","sourceRoot":"","sources":["../../../source/schema/schemas/iterable.ts"],"names":[],"mappings":";;;AACA,0EAAkE;AAClE,0DAAmD;AACnD,iDAAyC;AACzC,kDAA8C;AAE9C,0DAA4D;AAE5D,oCAAwC;AAMxC,MAAa,uBAAoD,SAAQ,kCAA4C;IAGnH,YAAY,cAAkC,EAAE,MAAmC;QACjF,KAAK,CAAC,MAAM,CAAC,CAAC;QAEd,IAAI,CAAC,cAAc,GAAG,cAAc,CAAC;IACvC,CAAC;IAED,CAAC,uBAAI,CAAC,CAAC,KAAc,EAAE,OAAiC,EAAE,IAAc;QACtE,IAAI,CAAC,IAAA,wBAAU,EAAC,KAAK,CAAC,EAAE;YACtB,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,0BAAW,CAAC,cAAc,CAAC,UAAU,EAAE,IAAA,gBAAM,EAAC,KAAK,CAAC,EAAE,IAAI,CAAC,EAAE,CAAC;SAC7F;QAED,MAAM,cAAc,GAAG,IAAI,CAAC,cAAc,CAAC;QAE3C,MAAM,iBAAiB,GAAG,IAAA,SAAG,EAAC,KAAkC,EAAE,CAAC,UAAU,EAAE,EAAE;YAC/E,MAAM,UAAU,GAAG,cAAc,CAAC,uBAAI,CAAC,CAAC,UAA4B,EAAE,OAAO,EAAE,IAAI,CAAC,GAAG,CAAC,YAAY,CAAC,CAAC,CAAC;YAEvG,IAAI,CAAC,UAAU,CAAC,KAAK,EAAE;gBACrB,MAAM,UAAU,CAAC,KAAK,CAAC;aACxB;YAED,OAAO,UAAU,CAAC,KAAK,CAAC;QAC1B,CAAC,CAAC,CAAC;QAEH,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,KAAK,EAAE,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,UAAU,GAAG,cAAc,CAAC,IAAI,CAAC,CAAC,UAA4B,EAAE,OAAO,EAAE,IAAI,CAAC,GAAG,CAAC,YAAY,CAAC,CAAC,CAAC;YAEvG,IAAI,CAAC,UAAU,CAAC,KAAK,EAAE;gBACrB,MAAM,UAAU,CAAC,KAAK,CAAC;aACxB;YAED,OAAO,UAAU,CAAC,KAAK,CAAC;QAC1B,CAAC,CAAC,CAAC;QAEH,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,KAAK,EAAE,iBAAiB,EAAE,CAAC;IACnD,CAAC;CACF;AAED,MAAM,UAAU,QAAQ,CAA6B,eAAmC,EAAE,OAA8D;IACtJ,MAAM,MAAM,GAAG,YAAY,CAA8B;QACvD,IAAI,EAAE,UAAU;QAChB,MAAM,EAAE,eAAe,CAAC,MAAM;QAC9B,GAAG,OAAO;KACX,CAAC,CAAC;IAEH,OAAO,IAAI,uBAAuB,CAAC,eAAe,EAAE,MAAM,CAAC,CAAC;AAC9D,CAAC"}
@@ -1,7 +1,7 @@
1
- import type { JsonPath } from "../../json-path";
2
- import type { DefinedValidationOptions, ValidationTestResult } from '../schema.validator';
3
- import { SchemaValidator, test } from '../schema.validator';
4
- import type { SchemaDefinition, SchemaOptions, SchemaOutput } from '../types';
1
+ import type { JsonPath } from "../../json-path/index.js";
2
+ import type { DefinedValidationOptions, ValidationTestResult } from '../schema.validator.js';
3
+ import { SchemaValidator, test } from '../schema.validator.js';
4
+ import type { SchemaDefinition, SchemaOptions, SchemaOutput } from '../types.js';
5
5
  export declare type LiteralSchemaDefinition<T> = SchemaDefinition<'literal', T, T> & {
6
6
  value: T;
7
7
  };
@@ -1,21 +1,20 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.literal = exports.LiteralSchemaValidator = void 0;
4
- const schema_error_1 = require("../schema.error");
5
- const schema_validator_1 = require("../schema.validator");
6
- const types_1 = require("../types");
7
- class LiteralSchemaValidator extends schema_validator_1.SchemaValidator {
8
- [schema_validator_1.test](value, _options, path) {
1
+ import { SchemaError } from '../schema.error.js';
2
+ import { SchemaValidator, test } from '../schema.validator.js';
3
+ import { schemaHelper } from '../types.js';
4
+ export class LiteralSchemaValidator extends SchemaValidator {
5
+ [test](value, _options, path) {
9
6
  if (value === this.schema.value) {
10
7
  return { valid: true, value: value };
11
8
  }
12
- return { valid: false, error: schema_error_1.SchemaError.expectedButGot(String(this.schema.value), String(value), path) };
9
+ return { valid: false, error: SchemaError.expectedButGot(String(this.schema.value), String(value), path) };
13
10
  }
14
11
  }
15
- exports.LiteralSchemaValidator = LiteralSchemaValidator;
16
- function literal(value, options) {
17
- const schema = (0, types_1.schemaHelper)(Object.assign({ type: 'literal', value }, options));
12
+ export function literal(value, options) {
13
+ const schema = schemaHelper({
14
+ type: 'literal',
15
+ value,
16
+ ...options
17
+ });
18
18
  return new LiteralSchemaValidator(schema);
19
19
  }
20
- exports.literal = literal;
21
20
  //# sourceMappingURL=literal.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"literal.js","sourceRoot":"","sources":["../../../source/schema/schemas/literal.ts"],"names":[],"mappings":";;;AACA,kDAA8C;AAE9C,0DAA4D;AAE5D,oCAAwC;AAMxC,MAAa,sBAA0B,SAAQ,kCAA2C;IACxF,CAAC,uBAAI,CAAC,CAAC,KAAc,EAAE,QAAkC,EAAE,IAAc;QACvE,IAAI,KAAK,KAAK,IAAI,CAAC,MAAM,CAAC,KAAK,EAAE;YAC/B,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,KAAK,EAAE,KAAU,EAAE,CAAC;SAC3C;QAED,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,0BAAW,CAAC,cAAc,CAAC,MAAM,CAAC,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,EAAE,MAAM,CAAC,KAAK,CAAC,EAAE,IAAI,CAAC,EAAE,CAAC;IAC7G,CAAC;CACF;AARD,wDAQC;AAED,SAAgB,OAAO,CAAI,KAAQ,EAAE,OAA4D;IAC/F,MAAM,MAAM,GAAG,IAAA,oBAAY,kBACzB,IAAI,EAAE,SAAS,EACf,KAAK,IACF,OAAO,EACV,CAAC;IAEH,OAAO,IAAI,sBAAsB,CAAC,MAAM,CAAC,CAAC;AAC5C,CAAC;AARD,0BAQC"}
1
+ {"version":3,"file":"literal.js","sourceRoot":"","sources":["../../../source/schema/schemas/literal.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AAEjD,OAAO,EAAE,eAAe,EAAE,IAAI,EAAE,MAAM,wBAAwB,CAAC;AAE/D,OAAO,EAAE,YAAY,EAAE,MAAM,aAAa,CAAC;AAM3C,MAAM,OAAO,sBAA0B,SAAQ,eAA2C;IACxF,CAAC,IAAI,CAAC,CAAC,KAAc,EAAE,QAAkC,EAAE,IAAc;QACvE,IAAI,KAAK,KAAK,IAAI,CAAC,MAAM,CAAC,KAAK,EAAE;YAC/B,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,KAAK,EAAE,KAAU,EAAE,CAAC;SAC3C;QAED,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,WAAW,CAAC,cAAc,CAAC,MAAM,CAAC,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,EAAE,MAAM,CAAC,KAAK,CAAC,EAAE,IAAI,CAAC,EAAE,CAAC;IAC7G,CAAC;CACF;AAED,MAAM,UAAU,OAAO,CAAI,KAAQ,EAAE,OAA4D;IAC/F,MAAM,MAAM,GAAG,YAAY,CAA6B;QACtD,IAAI,EAAE,SAAS;QACf,KAAK;QACL,GAAG,OAAO;KACX,CAAC,CAAC;IAEH,OAAO,IAAI,sBAAsB,CAAC,MAAM,CAAC,CAAC;AAC5C,CAAC"}
@@ -1,7 +1,7 @@
1
- import type { JsonPath } from "../../json-path";
2
- import type { DefinedValidationOptions, ValidationTestResult } from '../schema.validator';
3
- import { SchemaValidator, test } from '../schema.validator';
4
- import type { SchemaDefinition, SchemaOptions, SchemaOutput } from '../types';
1
+ import type { JsonPath } from "../../json-path/index.js";
2
+ import type { DefinedValidationOptions, ValidationTestResult } from '../schema.validator.js';
3
+ import { SchemaValidator, test } from '../schema.validator.js';
4
+ import type { SchemaDefinition, SchemaOptions, SchemaOutput } from '../types.js';
5
5
  export declare type NeverSchemaDefinition = SchemaDefinition<'never', unknown, never>;
6
6
  export declare class NeverSchemaValidator extends SchemaValidator<NeverSchemaDefinition> {
7
7
  [test](value: unknown, _options: DefinedValidationOptions, path: JsonPath): ValidationTestResult<SchemaOutput<NeverSchemaDefinition>>;
@@ -1,19 +1,17 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.never = exports.NeverSchemaValidator = void 0;
4
- const type_of_1 = require("../../utils/type-of");
5
- const schema_error_1 = require("../schema.error");
6
- const schema_validator_1 = require("../schema.validator");
7
- const types_1 = require("../types");
8
- class NeverSchemaValidator extends schema_validator_1.SchemaValidator {
9
- [schema_validator_1.test](value, _options, path) {
10
- return { valid: false, error: schema_error_1.SchemaError.expectedButGot('never', (0, type_of_1.typeOf)(value), path) };
1
+ import { typeOf } from "../../utils/type-of.js";
2
+ import { SchemaError } from '../schema.error.js';
3
+ import { SchemaValidator, test } from '../schema.validator.js';
4
+ import { schemaHelper } from '../types.js';
5
+ export class NeverSchemaValidator extends SchemaValidator {
6
+ [test](value, _options, path) {
7
+ return { valid: false, error: SchemaError.expectedButGot('never', typeOf(value), path) };
11
8
  }
12
9
  }
13
- exports.NeverSchemaValidator = NeverSchemaValidator;
14
- function never(options) {
15
- const schema = (0, types_1.schemaHelper)(Object.assign({ type: 'never' }, options));
10
+ export function never(options) {
11
+ const schema = schemaHelper({
12
+ type: 'never',
13
+ ...options
14
+ });
16
15
  return new NeverSchemaValidator(schema);
17
16
  }
18
- exports.never = never;
19
17
  //# sourceMappingURL=never.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"never.js","sourceRoot":"","sources":["../../../source/schema/schemas/never.ts"],"names":[],"m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AAI,oBAAoB,CAAC,MAAM,CAAC,CAAC;AAC1C,CAAC"}
@@ -1,7 +1,7 @@
1
- import type { JsonPath } from "../../json-path";
2
- import type { DefinedValidationOptions, ValidationTestResult } from '../schema.validator';
3
- import { SchemaValidator, test } from '../schema.validator';
4
- import type { Coercible, SchemaDefinition, SchemaInput, SchemaOptions, SchemaOutput } from '../types';
1
+ import type { JsonPath } from "../../json-path/index.js";
2
+ import type { DefinedValidationOptions, ValidationTestResult } from '../schema.validator.js';
3
+ import { SchemaValidator, test } from '../schema.validator.js';
4
+ import type { Coercible, SchemaDefinition, SchemaInput, SchemaOptions, SchemaOutput } from '../types.js';
5
5
  export declare type NullableSchemaDefinition<T extends SchemaDefinition = SchemaDefinition> = SchemaDefinition<'nullable', SchemaInput<T> | null, SchemaOutput<T> | null> & Coercible & {
6
6
  schema: T;
7
7
  };
@@ -1,29 +1,27 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.nullable = exports.NullableSchemaValidator = void 0;
4
- const type_guards_1 = require("../../utils/type-guards");
5
- const schema_validator_1 = require("../schema.validator");
6
- const types_1 = require("../types");
7
- class NullableSchemaValidator extends schema_validator_1.SchemaValidator {
1
+ import { isNull, isUndefined } from "../../utils/type-guards.js";
2
+ import { SchemaValidator, test } from '../schema.validator.js';
3
+ import { schemaHelper } from '../types.js';
4
+ export class NullableSchemaValidator extends SchemaValidator {
8
5
  constructor(innerValidator, schema) {
9
6
  super(schema);
10
7
  this.innerValidator = innerValidator;
11
8
  }
12
- [schema_validator_1.test](value, options, path) {
13
- var _a;
14
- if ((0, type_guards_1.isNull)(value)) {
9
+ [test](value, options, path) {
10
+ if (isNull(value)) {
15
11
  return { valid: true, value };
16
12
  }
17
- if (((_a = this.schema.coerce) !== null && _a !== void 0 ? _a : options.coerce) && (0, type_guards_1.isUndefined)(value)) {
13
+ if ((this.schema.coerce ?? options.coerce) && isUndefined(value)) {
18
14
  return { valid: true, value: null };
19
15
  }
20
- return this.innerValidator[schema_validator_1.test](value, options, path);
16
+ return this.innerValidator[test](value, options, path);
21
17
  }
22
18
  }
23
- exports.NullableSchemaValidator = NullableSchemaValidator;
24
- function nullable(innerValidator, options) {
25
- const schema = (0, types_1.schemaHelper)(Object.assign({ type: 'nullable', schema: innerValidator.schema }, options));
19
+ export function nullable(innerValidator, options) {
20
+ const schema = schemaHelper({
21
+ type: 'nullable',
22
+ schema: innerValidator.schema,
23
+ ...options
24
+ });
26
25
  return new NullableSchemaValidator(innerValidator, schema);
27
26
  }
28
- exports.nullable = nullable;
29
27
  //# sourceMappingURL=nullable.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"nullable.js","sourceRoot":"","sources":["../../../source/schema/schemas/nullable.ts"],"names":[],"mappings":";;;AACA,yDAA0D;AAE1D,0DAA4D;AAE5D,oCAAwC;AAMxC,MAAa,uBAAoD,SAAQ,kCAA4C;IAGnH,YAAY,cAAkC,EAAE,MAAmC;QACjF,KAAK,CAAC,MAAM,CAAC,CAAC;QAEd,IAAI,CAAC,cAAc,GAAG,cAAc,CAAC;IACvC,CAAC;IAED,CAAC,uBAAI,CAAC,CAAC,KAAc,EAAE,OAAiC,EAAE,IAAc;;QACtE,IAAI,IAAA,oBAAM,EAAC,KAAK,CAAC,EAAE;YACjB,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,KAAK,EAAE,CAAC;SAC/B;QAED,IAAI,CAAC,MAAA,IAAI,CAAC,MAAM,CAAC,MAAM,mCAAI,OAAO,CAAC,MAAM,CAAC,IAAI,IAAA,yBAAW,EAAC,KAAK,CAAC,EAAE;YAChE,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC;SACrC;QAED,OAAO,IAAI,CAAC,cAAc,CAAC,uBAAI,CAAC,CAAC,KAAuB,EAAE,OAAO,EAAE,IAAI,CAAC,CAAC;IAC3E,CAAC;CACF;AApBD,0DAoBC;AAED,SAAgB,QAAQ,CAA6B,cAAkC,EAAE,OAA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Ac,CAAC,MAAM;QAC7B,GAAG,OAAO;KACX,CAAC,CAAC;IAEH,OAAO,IAAI,uBAAuB,CAAI,cAAc,EAAE,MAAM,CAAC,CAAC;AAChE,CAAC"}
@@ -1,7 +1,7 @@
1
- import type { JsonPath } from "../../json-path";
2
- import type { DefinedValidationOptions, ValidationTestResult } from '../schema.validator';
3
- import { SchemaValidator, test } from '../schema.validator';
4
- import type { Coercible, SchemaDefinition, SchemaOptions } from '../types';
1
+ import type { JsonPath } from "../../json-path/index.js";
2
+ import type { DefinedValidationOptions, ValidationTestResult } from '../schema.validator.js';
3
+ import { SchemaValidator, test } from '../schema.validator.js';
4
+ import type { Coercible, SchemaDefinition, SchemaOptions } from '../types.js';
5
5
  export declare type NumberSchemaDefinition = SchemaDefinition<'number', unknown, number> & Coercible & {
6
6
  /** integer */
7
7
  integer?: boolean;
@@ -1,17 +1,14 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.number = exports.NumberSchemaValidator = void 0;
4
- const patterns_1 = require("../../utils/patterns");
5
- const type_guards_1 = require("../../utils/type-guards");
6
- const schema_error_1 = require("../schema.error");
7
- const schema_validator_1 = require("../schema.validator");
8
- const types_1 = require("../types");
1
+ import { numberPattern } from "../../utils/patterns.js";
2
+ import { isDefined } from "../../utils/type-guards.js";
3
+ import { SchemaError, schemaError } from '../schema.error.js';
4
+ import { SchemaValidator, test } from '../schema.validator.js';
5
+ import { schemaHelper } from '../types.js';
9
6
  const coercerMap = {
10
7
  string: (string, path) => {
11
- const isNumberString = patterns_1.numberPattern.test(string);
8
+ const isNumberString = numberPattern.test(string);
12
9
  const numberValue = Number(string);
13
10
  if (!isNumberString || Number.isNaN(numberValue)) {
14
- return { valid: false, error: schema_error_1.SchemaError.couldNotCoerce('number', 'string', 'invalid format', path) };
11
+ return { valid: false, error: SchemaError.couldNotCoerce('number', 'string', 'invalid format', path) };
15
12
  }
16
13
  return { valid: true, value: numberValue };
17
14
  },
@@ -19,34 +16,34 @@ const coercerMap = {
19
16
  bigint: (bigint, path) => {
20
17
  const numberValue = Number(bigint);
21
18
  if (!Number.isFinite(numberValue)) {
22
- return { valid: false, error: schema_error_1.SchemaError.couldNotCoerce('number', 'bigint', 'value out of bounds', path) };
19
+ return { valid: false, error: SchemaError.couldNotCoerce('number', 'bigint', 'value out of bounds', path) };
23
20
  }
24
21
  return { valid: true, value: numberValue };
25
22
  }
26
23
  };
27
- class NumberSchemaValidator extends schema_validator_1.SchemaValidator {
28
- [schema_validator_1.test](value, options, path) {
29
- var _a;
30
- const result = super.ensureType('number', value, path, { coerce: (_a = this.schema.coerce) !== null && _a !== void 0 ? _a : options.coerce }, coercerMap);
24
+ export class NumberSchemaValidator extends SchemaValidator {
25
+ [test](value, options, path) {
26
+ const result = super.ensureType('number', value, path, { coerce: this.schema.coerce ?? options.coerce }, coercerMap);
31
27
  if (!result.valid) {
32
28
  return result;
33
29
  }
34
30
  if ((this.schema.integer == true) && !Number.isInteger(result.value)) {
35
- return { valid: false, error: (0, schema_error_1.schemaError)('expected integer', path) };
31
+ return { valid: false, error: schemaError('expected integer', path) };
36
32
  }
37
- if ((0, type_guards_1.isDefined)(this.schema.min) && (result.value < this.schema.min)) {
38
- return { valid: false, error: (0, schema_error_1.schemaError)(`minimum valid value is ${this.schema.min}`, path) };
33
+ if (isDefined(this.schema.min) && (result.value < this.schema.min)) {
34
+ return { valid: false, error: schemaError(`minimum valid value is ${this.schema.min}`, path) };
39
35
  }
40
- if ((0, type_guards_1.isDefined)(this.schema.max) && (result.value > this.schema.max)) {
41
- return { valid: false, error: (0, schema_error_1.schemaError)(`maximum valid value is ${this.schema.max}`, path) };
36
+ if (isDefined(this.schema.max) && (result.value > this.schema.max)) {
37
+ return { valid: false, error: schemaError(`maximum valid value is ${this.schema.max}`, path) };
42
38
  }
43
39
  return { valid: true, value: result.value };
44
40
  }
45
41
  }
46
- exports.NumberSchemaValidator = NumberSchemaValidator;
47
- function number(options) {
48
- const schema = (0, types_1.schemaHelper)(Object.assign({ type: 'number' }, options));
42
+ export function number(options) {
43
+ const schema = schemaHelper({
44
+ type: 'number',
45
+ ...options
46
+ });
49
47
  return new NumberSchemaValidator(schema);
50
48
  }
51
- exports.number = number;
52
49
  //# sourceMappingURL=number.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"number.js","sourceRoot":"","sources":["../../../source/schema/schemas/number.ts"],"names":[],"mappings":";;;AACA,mDAAiD;AACjD,yDAAgD;AAChD,kDAA2D;AAE3D,0DAA4D;AAE5D,oCAAwC;AAExC,MAAM,UAAU,GAAuB;IACrC,MAAM,EAAE,CAAC,MAAM,EAAE,IAAI,EAAE,EAAE;QACvB,MAAM,cAAc,GAAG,wBAAa,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;QAClD,MAAM,WAAW,GAAG,MAAM,CAAC,MAAM,CAAC,CAAC;QAEnC,IAAI,CAAC,cAAc,IAAI,MAAM,CAAC,KAAK,CAAC,WAAW,CAAC,EAAE;YAChD,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,0BAAW,CAAC,cAAc,CAAC,QAAQ,EAAE,QAAQ,EAAE,gBAAgB,EAAE,IAAI,CAAC,EAAE,CAAC;SACxG;QAED,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,KAAK,EAAE,WAAW,EAAE,CAAC;IAC7C,CAAC;IACD,OAAO,EAAE,CAAC,OAAO,EAAE,EAAE,CAAC,CAAC,EAAE,KAAK,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,CAAC,OAAO,CAAC,EAAE,CAAC;IAC/D,MAAM,EAAE,CAAC,MAAM,EAAE,IAAI,EAAE,EAAE;QACvB,MAAM,WAAW,GAAG,MAAM,CAAC,MAAM,CAAC,CAAC;QAEnC,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,WAAW,CAAC,EAAE;YACjC,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,0BAAW,CAAC,cAAc,CAAC,QAAQ,EAAE,QA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AM,CAAC,GAAG,CAAC,IAAI,CAAC,MAAM,CAAC,KAAK,GAAG,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,EAAE;YAClE,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,WAAW,CAAC,0BAA0B,IAAI,CAAC,MAAM,CAAC,GAAG,EAAE,EAAE,IAAI,CAAC,EAAE,CAAC;SAChG;QAED,IAAI,SAAS,CAAC,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,IAAI,CAAC,MAAM,CAAC,KAAK,GAAG,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,EAAE;YAClE,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,WAAW,CAAC,0BAA0B,IAAI,CAAC,MAAM,CAAC,GAAG,EAAE,EAAE,IAAI,CAAC,EAAE,CAAC;SAChG;QAED,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,CAAC,KAAK,EAAE,CAAC;IAC9C,CAAC;CACF;AAED,MAAM,UAAU,MAAM,CAAC,OAA+C;IACpE,MAAM,MAAM,GAAG,YAAY,CAAyB;QAClD,IAAI,EAAE,QAAQ;QACd,GAAG,OAAO;KACX,CAAC,CAAC;IAEH,OAAO,IAAI,qBAAqB,CAAC,MAAM,CAAC,CAAC;AAC3C,CAAC"}
@@ -1,8 +1,8 @@
1
- import type { JsonPath } from "../../json-path";
2
- import type { Optionalize, Simplify, SimplifyObject, StringMap } from "../../types";
3
- import type { DefinedValidationOptions, ValidationTestResult } from '../schema.validator';
4
- import { SchemaValidator, test, testAsync } from '../schema.validator';
5
- import type { Maskable, SchemaDefinition, SchemaOptions, SchemaOutput } from '../types';
1
+ import type { JsonPath } from "../../json-path/index.js";
2
+ import type { Optionalize, Simplify, SimplifyObject, StringMap } from "../../types.js";
3
+ import type { DefinedValidationOptions, ValidationTestResult } from '../schema.validator.js';
4
+ import { SchemaValidator, test, testAsync } from '../schema.validator.js';
5
+ import type { Maskable, SchemaDefinition, SchemaOptions, SchemaOutput } from '../types.js';
6
6
  export declare type ObjectOutputType<T extends StringMap<SchemaDefinition>> = Simplify<Optionalize<{
7
7
  [P in keyof T]: SchemaOutput<T[P]>;
8
8
  }>>;
@@ -1,12 +1,9 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.assign = exports.object = exports.ObjectSchemaValidator = void 0;
4
- const map_1 = require("../../utils/map");
5
- const type_guards_1 = require("../../utils/type-guards");
6
- const schema_error_1 = require("../schema.error");
7
- const schema_validator_1 = require("../schema.validator");
8
- const types_1 = require("../types");
9
- class ObjectSchemaValidator extends schema_validator_1.SchemaValidator {
1
+ import { differenceMaps } from "../../utils/map.js";
2
+ import { isBoolean } from "../../utils/type-guards.js";
3
+ import { schemaError, SchemaError } from '../schema.error.js';
4
+ import { SchemaValidator, test, testAsync } from '../schema.validator.js';
5
+ import { schemaHelper } from '../types.js';
6
+ export class ObjectSchemaValidator extends SchemaValidator {
10
7
  constructor(validators, schema) {
11
8
  super(schema);
12
9
  this.validatorEntries = new Map(Object.entries(validators));
@@ -15,11 +12,11 @@ class ObjectSchemaValidator extends schema_validator_1.SchemaValidator {
15
12
  const validatorEntries = Object.fromEntries([...a.validatorEntries.entries(), ...b.validatorEntries.entries()]);
16
13
  const schema = {
17
14
  type: 'object',
18
- entries: Object.assign(Object.assign({}, a.schema.entries), b.schema.entries)
15
+ entries: { ...a.schema.entries, ...b.schema.entries }
19
16
  };
20
17
  return new ObjectSchemaValidator(validatorEntries, schema);
21
18
  }
22
- [schema_validator_1.test](value, options, path) {
19
+ [test](value, options, path) {
23
20
  const testBaseResult = this._testBase(value, options, path);
24
21
  if (!testBaseResult.valid) {
25
22
  return testBaseResult;
@@ -27,18 +24,18 @@ class ObjectSchemaValidator extends schema_validator_1.SchemaValidator {
27
24
  let resultObject = {};
28
25
  for (const [key, validator] of this.validatorEntries) {
29
26
  const innerValue = testBaseResult.value.get(key);
30
- const innerValueValidationTestResult = validator[schema_validator_1.test](innerValue, options, path.add(key));
27
+ const innerValueValidationTestResult = validator[test](innerValue, options, path.add(key));
31
28
  if (!innerValueValidationTestResult.valid) {
32
29
  return innerValueValidationTestResult;
33
30
  }
34
31
  resultObject[key] = innerValueValidationTestResult.value;
35
32
  }
36
33
  if (this.schema.keepUnknown == true) {
37
- resultObject = Object.assign(Object.assign({}, value), resultObject);
34
+ resultObject = { ...value, ...resultObject };
38
35
  }
39
36
  return { valid: true, value: resultObject };
40
37
  }
41
- async [schema_validator_1.testAsync](value, options, path) {
38
+ async [testAsync](value, options, path) {
42
39
  const testBaseResult = this._testBase(value, options, path);
43
40
  if (!testBaseResult.valid) {
44
41
  return testBaseResult;
@@ -46,14 +43,14 @@ class ObjectSchemaValidator extends schema_validator_1.SchemaValidator {
46
43
  let resultObject = {};
47
44
  for (const [key, validator] of this.validatorEntries) {
48
45
  const innerValue = testBaseResult.value.get(key);
49
- const innerValueValidationTestResult = await validator[schema_validator_1.testAsync](innerValue, options, path.add(key));
46
+ const innerValueValidationTestResult = await validator[testAsync](innerValue, options, path.add(key));
50
47
  if (!innerValueValidationTestResult.valid) {
51
48
  return innerValueValidationTestResult;
52
49
  }
53
50
  resultObject[key] = innerValueValidationTestResult.value;
54
51
  }
55
52
  if (this.schema.keepUnknown == true) {
56
- resultObject = Object.assign(Object.assign({}, value), resultObject);
53
+ resultObject = { ...value, ...resultObject };
57
54
  }
58
55
  return { valid: true, value: resultObject };
59
56
  }
@@ -63,27 +60,28 @@ class ObjectSchemaValidator extends schema_validator_1.SchemaValidator {
63
60
  return typeResult;
64
61
  }
65
62
  else if (value === null) {
66
- return { valid: false, error: schema_error_1.SchemaError.expectedButGot('object', 'null', path) };
63
+ return { valid: false, error: SchemaError.expectedButGot('object', 'null', path) };
67
64
  }
68
65
  const valueEntries = new Map(Object.entries(value));
69
- const unknownKeys = (0, map_1.differenceMaps)(valueEntries, this.validatorEntries);
70
- if ((unknownKeys.length > 0) && (this.schema.mask != true) && ((0, type_guards_1.isBoolean)(this.schema.mask) || !options.mask) && (this.schema.keepUnknown != true)) {
66
+ const unknownKeys = differenceMaps(valueEntries, this.validatorEntries);
67
+ if ((unknownKeys.length > 0) && (this.schema.mask != true) && (isBoolean(this.schema.mask) || !options.mask) && (this.schema.keepUnknown != true)) {
71
68
  const keys = unknownKeys.map((entry) => entry[0]).join(', ');
72
- return { valid: false, error: (0, schema_error_1.schemaError)(`unexpecet keys in object: ${keys}`, path) };
69
+ return { valid: false, error: schemaError(`unexpecet keys in object: ${keys}`, path) };
73
70
  }
74
71
  return { valid: true, value: valueEntries };
75
72
  }
76
73
  }
77
- exports.ObjectSchemaValidator = ObjectSchemaValidator;
78
- function object(entries, options) {
74
+ export function object(entries, options) {
79
75
  const validatorEntries = Object.entries(entries);
80
76
  const mappedValidatorEntries = validatorEntries.map(([key, value]) => [key, value.schema]);
81
- const schema = (0, types_1.schemaHelper)(Object.assign({ type: 'object', entries: Object.fromEntries(mappedValidatorEntries) }, options));
77
+ const schema = schemaHelper({
78
+ type: 'object',
79
+ entries: Object.fromEntries(mappedValidatorEntries),
80
+ ...options
81
+ });
82
82
  return new ObjectSchemaValidator(entries, schema);
83
83
  }
84
- exports.object = object;
85
- function assign(a, b) {
84
+ export function assign(a, b) {
86
85
  return ObjectSchemaValidator.assign(a, b);
87
86
  }
88
- exports.assign = assign;
89
87
  //# sourceMappingURL=object.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"object.js","sourceRoot":"","sources":["../../../source/schema/schemas/object.ts"],"names":[],"mappings":";;;AAEA,yCAA6C;AAC7C,yDAAgD;AAChD,kDAA2D;AAE3D,0DAAuE;AAEvE,oCAAwC;AAexC,MAAa,qBAA6D,SAAQ,kCAA0C;IAG1H,YAAY,UAA2C,EAAE,MAAiC;QACxF,KAAK,CAAC,MAAM,CAAC,CAAC;QAEd,IAAI,CAAC,gBAAgB,GAAG,IAAI,GAAG,CAAC,MAAM,CAAC,OAAO,CAAC,UAAU,CAAC,CAAC,CAAC;IAC9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QACxD,GAAG,OAAO;KACX,CAAC,CAAC;IAEH,OAAO,IAAI,qBAAqB,CAAC,OAAO,EAAE,MAAM,CAAC,CAAC;AACpD,CAAC;AAED,MAAM,UAAU,MAAM,CAA+E,CAA2B,EAAE,CAA2B;IAC3J,OAAO,qBAAqB,CAAC,MAAM,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;AAC5C,CAAC"}
@@ -1,7 +1,7 @@
1
- import type { JsonPath } from "../../json-path";
2
- import type { DefinedValidationOptions, ValidationTestResult } from '../schema.validator';
3
- import { SchemaValidator, test } from '../schema.validator';
4
- import type { Coercible, SchemaDefinition, SchemaInput, SchemaOptions, SchemaOutput } from '../types';
1
+ import type { JsonPath } from "../../json-path/index.js";
2
+ import type { DefinedValidationOptions, ValidationTestResult } from '../schema.validator.js';
3
+ import { SchemaValidator, test } from '../schema.validator.js';
4
+ import type { Coercible, SchemaDefinition, SchemaInput, SchemaOptions, SchemaOutput } from '../types.js';
5
5
  export declare type OptionalSchemaDefinition<T extends SchemaDefinition = SchemaDefinition> = SchemaDefinition<'optional', SchemaInput<T> | undefined, SchemaOutput<T> | undefined> & Coercible & {
6
6
  schema: T;
7
7
  };
@@ -1,29 +1,27 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.optional = exports.OptionalSchemaValidator = void 0;
4
- const type_guards_1 = require("../../utils/type-guards");
5
- const schema_validator_1 = require("../schema.validator");
6
- const types_1 = require("../types");
7
- class OptionalSchemaValidator extends schema_validator_1.SchemaValidator {
1
+ import { isNull, isUndefined } from "../../utils/type-guards.js";
2
+ import { SchemaValidator, test } from '../schema.validator.js';
3
+ import { schemaHelper } from '../types.js';
4
+ export class OptionalSchemaValidator extends SchemaValidator {
8
5
  constructor(innerValidator, schema) {
9
6
  super(schema);
10
7
  this.innerValidator = innerValidator;
11
8
  }
12
- [schema_validator_1.test](value, options, path) {
13
- var _a;
14
- if ((0, type_guards_1.isUndefined)(value)) {
9
+ [test](value, options, path) {
10
+ if (isUndefined(value)) {
15
11
  return { valid: true, value };
16
12
  }
17
- if (((_a = this.schema.coerce) !== null && _a !== void 0 ? _a : options.coerce) && (0, type_guards_1.isNull)(value)) {
13
+ if ((this.schema.coerce ?? options.coerce) && isNull(value)) {
18
14
  return { valid: true, value: undefined };
19
15
  }
20
- return this.innerValidator[schema_validator_1.test](value, options, path);
16
+ return this.innerValidator[test](value, options, path);
21
17
  }
22
18
  }
23
- exports.OptionalSchemaValidator = OptionalSchemaValidator;
24
- function optional(innerValidator, options) {
25
- const schema = (0, types_1.schemaHelper)(Object.assign({ type: 'optional', schema: innerValidator.schema }, options));
19
+ export function optional(innerValidator, options) {
20
+ const schema = schemaHelper({
21
+ type: 'optional',
22
+ schema: innerValidator.schema,
23
+ ...options
24
+ });
26
25
  return new OptionalSchemaValidator(innerValidator, schema);
27
26
  }
28
- exports.optional = optional;
29
27
  //# sourceMappingURL=optional.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"optional.js","sourceRoot":"","sources":["../../../source/schema/schemas/optional.ts"],"names":[],"mappings":";;;AACA,yDAA0D;AAE1D,0DAA4D;AAE5D,oCAAwC;AAMxC,MAAa,uBAAoD,SAAQ,kCAA4C;IAGnH,YAAY,cAAkC,EAAE,MAAmC;QACjF,KAAK,CAAC,MAAM,CAAC,CAAC;QAEd,IAAI,CAAC,cAAc,GAAG,cAAc,CAAC;IACvC,CAAC;IAED,CAAC,uBAAI,CAAC,CAAC,KAAc,EAAE,OAAiC,EAAE,IAAc;;QACtE,IAAI,IAAA,yBAAW,EAAC,KAAK,CAAC,EAAE;YACtB,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,KAAK,EAAE,CAAC;SAC/B;QAED,IAAI,CAAC,MAAA,IAAI,CAAC,MAAM,CAAC,MAAM,mCAAI,OAAO,CAAC,MAAM,CAAC,IAAI,IAAA,oBAAM,EAAC,KAAK,CAAC,EAAE;YAC3D,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,KAAK,EAAE,S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C,KAAuB,EAAE,OAAO,EAAE,IAAI,CAAC,CAAC;IAC3E,CAAC;CACF;AAED,MAAM,UAAU,QAAQ,CAA6B,cAAkC,EAAE,OAA8D;IACrJ,MAAM,MAAM,GAAG,YAAY,CAA8B;QACvD,IAAI,EAAE,UAAU;QAChB,MAAM,EAAE,cAAc,CAAC,MAAM;QAC7B,GAAG,OAAO;KACX,CAAC,CAAC;IAEH,OAAO,IAAI,uBAAuB,CAAC,cAAc,EAAE,MAAM,CAAC,CAAC;AAC7D,CAAC"}
@@ -1,7 +1,7 @@
1
- import type { JsonPath } from "../../json-path";
2
- import type { DefinedValidationOptions, ValidationTestResult } from '../schema.validator';
3
- import { SchemaValidator, test, testAsync } from '../schema.validator';
4
- import type { SchemaDefinition, SchemaInput, SchemaOptions, SchemaOutput } from '../types';
1
+ import type { JsonPath } from "../../json-path/index.js";
2
+ import type { DefinedValidationOptions, ValidationTestResult } from '../schema.validator.js';
3
+ import { SchemaValidator, test, testAsync } from '../schema.validator.js';
4
+ import type { SchemaDefinition, SchemaInput, SchemaOptions, SchemaOutput } from '../types.js';
5
5
  export declare type Preprocessor<S extends SchemaDefinition, Input> = (value: Input) => SchemaInput<S> | Promise<SchemaInput<S>>;
6
6
  export declare type PreprocessSchemaDefinition<S extends SchemaDefinition = SchemaDefinition, Input = never> = SchemaDefinition<'preprocess', Input, SchemaOutput<S>> & {
7
7
  outputSchema: S;
@@ -1,30 +1,30 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.preprocess = exports.PreprocessSchemaValidator = void 0;
4
- const type_guards_1 = require("../../utils/type-guards");
5
- const schema_validator_1 = require("../schema.validator");
6
- const types_1 = require("../types");
7
- class PreprocessSchemaValidator extends schema_validator_1.SchemaValidator {
1
+ import { isPromise } from "../../utils/type-guards.js";
2
+ import { SchemaValidator, test, testAsync } from '../schema.validator.js';
3
+ import { schemaHelper } from '../types.js';
4
+ export class PreprocessSchemaValidator extends SchemaValidator {
8
5
  constructor(schema, outputValidator) {
9
6
  super(schema);
10
7
  this.outputValidator = outputValidator;
11
8
  }
12
- [schema_validator_1.test](value, options, path) {
9
+ [test](value, options, path) {
13
10
  const preprocessed = this.schema.preprocessor(value);
14
- if ((0, type_guards_1.isPromise)(preprocessed)) {
11
+ if (isPromise(preprocessed)) {
15
12
  throw new Error(`cannot handle async preprocess in sync validation. Use async instead (path: ${path.path})`);
16
13
  }
17
- return this.outputValidator[schema_validator_1.test](preprocessed, options, path);
14
+ return this.outputValidator[test](preprocessed, options, path);
18
15
  }
19
- async [schema_validator_1.testAsync](value, options, path) {
16
+ async [testAsync](value, options, path) {
20
17
  const preprocessed = await this.schema.preprocessor(value);
21
- return this.outputValidator[schema_validator_1.testAsync](preprocessed, options, path);
18
+ return this.outputValidator[testAsync](preprocessed, options, path);
22
19
  }
23
20
  }
24
- exports.PreprocessSchemaValidator = PreprocessSchemaValidator;
25
- function preprocess(outputSchemaValidator, preprocessor, options) {
26
- const schema = (0, types_1.schemaHelper)(Object.assign({ type: 'preprocess', outputSchema: outputSchemaValidator.schema, preprocessor }, options));
21
+ export function preprocess(outputSchemaValidator, preprocessor, options) {
22
+ const schema = schemaHelper({
23
+ type: 'preprocess',
24
+ outputSchema: outputSchemaValidator.schema,
25
+ preprocessor,
26
+ ...options
27
+ });
27
28
  return new PreprocessSchemaValidator(schema, outputSchemaValidator);
28
29
  }
29
- exports.preprocess = preprocess;
30
30
  //# sourceMappingURL=preprocess.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"preprocess.js","sourceRoot":"","sources":["../../../source/schema/schemas/preprocess.ts"],"names":[],"mappings":";;;AACA,yDAAgD;AAEhD,0DAAuE;AAEvE,oCAAwC;AASxC,MAAa,yBAAqE,SAAQ,kCAAqD;IAG7I,YAAY,MAA4C,EAAE,eAAmC;QAC3F,KAAK,CAAC,MAAM,CAAC,CAAC;QAEd,IAAI,CAAC,eAAe,GAAG,eAAe,CAAC;IACzC,CAAC;IAED,CAAC,uBAAI,CAAC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AA4C,EAAE,eAAmC;QAC3F,KAAK,CAAC,MAAM,CAAC,CAAC;QAEd,IAAI,CAAC,eAAe,GAAG,eAAe,CAAC;IACzC,CAAC;IAED,CAAC,IAAI,CAAC,CAAC,KAAY,EAAE,OAAiC,EAAE,IAAc;QACpE,MAAM,YAAY,GAAG,IAAI,CAAC,MAAM,CAAC,YAAY,CAAC,KAAK,CAAC,CAAC;QAErD,IAAI,SAAS,CAAC,YAAY,CAAC,EAAE;YAC3B,MAAM,IAAI,KAAK,CAAC,+EAA+E,IAAI,CAAC,IAAI,GAAG,CAAC,CAAC;SAC9G;QAED,OAAO,IAAI,CAAC,eAAe,CAAC,IAAI,CAAC,CAAC,YAAY,EAAE,OAAO,EAAE,IAAI,CAAC,CAAC;IACjE,CAAC;IAES,KAAK,CAAC,CAAC,SAAS,CAAC,CAAC,KAAY,EAAE,OAAiC,EAAE,IAAc;QACzF,MAAM,YAAY,GAAG,MAAM,IAAI,CAAC,MAAM,CAAC,YAAY,CAAC,KAAK,CAAC,CAAC;QAC3D,OAAO,IAAI,CAAC,eAAe,CAAC,SAAS,CAAC,CAAC,YAAY,EAAE,OAAO,EAAE,IAAI,CAAC,CAAC;IACtE,CAAC;CACF;AAED,MAAM,UAAU,UAAU,CAAoC,qBAAyC,EAAE,YAAoC,EAAE,OAA8F;IAC3O,MAAM,MAAM,GAAG,YAAY,CAAuC;QAChE,IAAI,EAAE,YAAY;QAClB,YAAY,EAAE,qBAAqB,CAAC,MAAM;QAC1C,YAAY;QACZ,GAAG,OAAO;KACX,CAAC,CAAC;IAEH,OAAO,IAAI,yBAAyB,CAAC,MAAM,EAAE,qBAAqB,CAAC,CAAC;AACtE,CAAC"}
@@ -1,7 +1,7 @@
1
- import type { JsonPath } from "../../json-path";
2
- import type { DefinedValidationOptions, ValidationTestResult } from '../schema.validator';
3
- import { SchemaValidator, test } from '../schema.validator';
4
- import type { SchemaDefinition, SchemaOptions, SchemaOutput } from '../types';
1
+ import type { JsonPath } from "../../json-path/index.js";
2
+ import type { DefinedValidationOptions, ValidationTestResult } from '../schema.validator.js';
3
+ import { SchemaValidator, test } from '../schema.validator.js';
4
+ import type { SchemaDefinition, SchemaOptions, SchemaOutput } from '../types.js';
5
5
  export declare type ReadableStreamSchemaDefinition = SchemaDefinition<'readableStream', unknown, ReadableStream>;
6
6
  export declare class ReadableStreamSchemaValidator extends SchemaValidator<ReadableStreamSchemaDefinition> {
7
7
  [test](value: unknown, options: DefinedValidationOptions, path: JsonPath): ValidationTestResult<SchemaOutput<ReadableStreamSchemaDefinition>>;