@tstdl/base 0.71.48 → 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 (1395) 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 +5 -5
  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 +9 -10
  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 +4 -4
  44. package/api/server/module.js +7 -10
  45. package/api/server/module.js.map +1 -1
  46. package/api/types.d.ts +15 -7
  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.js +14 -18
  383. package/image-service/image-service.js.map +1 -1
  384. package/image-service/imgproxy/imgproxy-image-service.d.ts +5 -5
  385. package/image-service/imgproxy/imgproxy-image-service.js +32 -36
  386. package/image-service/imgproxy/imgproxy-image-service.js.map +1 -1
  387. package/image-service/imgproxy/index.d.ts +1 -1
  388. package/image-service/imgproxy/index.js +1 -17
  389. package/image-service/imgproxy/index.js.map +1 -1
  390. package/image-service/index.d.ts +1 -1
  391. package/image-service/index.js +1 -17
  392. package/image-service/index.js.map +1 -1
  393. package/index.d.ts +1 -1
  394. package/index.js +1 -17
  395. package/index.js.map +1 -1
  396. package/instance-provider.d.ts +4 -4
  397. package/instance-provider.js +27 -35
  398. package/instance-provider.js.map +1 -1
  399. package/interfaces.js +1 -2
  400. package/json-path/index.d.ts +1 -1
  401. package/json-path/index.js +1 -17
  402. package/json-path/index.js.map +1 -1
  403. package/json-path/json-path.js +12 -19
  404. package/json-path/json-path.js.map +1 -1
  405. package/key-value-store/index.d.ts +2 -2
  406. package/key-value-store/index.js +2 -18
  407. package/key-value-store/index.js.map +1 -1
  408. package/key-value-store/key-value-store.provider.d.ts +2 -2
  409. package/key-value-store/key-value-store.provider.js +1 -5
  410. package/key-value-store/key-value-store.provider.js.map +1 -1
  411. package/key-value-store/key-value.store.d.ts +3 -3
  412. package/key-value-store/key-value.store.js +2 -6
  413. package/key-value-store/key-value.store.js.map +1 -1
  414. package/key-value-store/mongo/index.d.ts +5 -5
  415. package/key-value-store/mongo/index.js +5 -21
  416. package/key-value-store/mongo/index.js.map +1 -1
  417. package/key-value-store/mongo/module.d.ts +2 -2
  418. package/key-value-store/mongo/module.js +10 -14
  419. package/key-value-store/mongo/module.js.map +1 -1
  420. package/key-value-store/mongo/mongo-key-value-store.provider.d.ts +3 -3
  421. package/key-value-store/mongo/mongo-key-value-store.provider.js +7 -10
  422. package/key-value-store/mongo/mongo-key-value-store.provider.js.map +1 -1
  423. package/key-value-store/mongo/mongo-key-value.model.d.ts +1 -1
  424. package/key-value-store/mongo/mongo-key-value.model.js +1 -2
  425. package/key-value-store/mongo/mongo-key-value.repository.d.ts +6 -6
  426. package/key-value-store/mongo/mongo-key-value.repository.js +11 -14
  427. package/key-value-store/mongo/mongo-key-value.repository.js.map +1 -1
  428. package/key-value-store/mongo/mongo-key-value.store.d.ts +3 -3
  429. package/key-value-store/mongo/mongo-key-value.store.js +16 -19
  430. package/key-value-store/mongo/mongo-key-value.store.js.map +1 -1
  431. package/lock/index.d.ts +2 -2
  432. package/lock/index.js +2 -18
  433. package/lock/index.js.map +1 -1
  434. package/lock/lock.d.ts +2 -2
  435. package/lock/lock.js +2 -6
  436. package/lock/lock.js.map +1 -1
  437. package/lock/mongo/index.d.ts +5 -5
  438. package/lock/mongo/index.js +5 -21
  439. package/lock/mongo/index.js.map +1 -1
  440. package/lock/mongo/lock.d.ts +4 -4
  441. package/lock/mongo/lock.js +30 -33
  442. package/lock/mongo/lock.js.map +1 -1
  443. package/lock/mongo/model.d.ts +1 -1
  444. package/lock/mongo/model.js +1 -2
  445. package/lock/mongo/module.d.ts +2 -2
  446. package/lock/mongo/module.js +10 -14
  447. package/lock/mongo/module.js.map +1 -1
  448. package/lock/mongo/{mongo-lock-repository.d.ts → mongo-lock.repository.d.ts} +6 -6
  449. package/lock/mongo/{mongo-lock-repository.js → mongo-lock.repository.js} +17 -20
  450. package/lock/mongo/mongo-lock.repository.js.map +1 -0
  451. package/lock/mongo/provider.d.ts +4 -4
  452. package/lock/mongo/provider.js +16 -19
  453. package/lock/mongo/provider.js.map +1 -1
  454. package/lock/provider.d.ts +3 -3
  455. package/lock/provider.js +2 -6
  456. package/lock/provider.js.map +1 -1
  457. package/logger/console/index.d.ts +1 -1
  458. package/logger/console/index.js +1 -17
  459. package/logger/console/index.js.map +1 -1
  460. package/logger/console/logger.d.ts +3 -3
  461. package/logger/console/logger.js +20 -27
  462. package/logger/console/logger.js.map +1 -1
  463. package/logger/index.d.ts +2 -2
  464. package/logger/index.js +2 -18
  465. package/logger/index.js.map +1 -1
  466. package/logger/level.js +2 -5
  467. package/logger/level.js.map +1 -1
  468. package/logger/logger.d.ts +3 -3
  469. package/logger/logger.js +13 -17
  470. package/logger/logger.js.map +1 -1
  471. package/logger/noop/index.d.ts +1 -1
  472. package/logger/noop/index.js +1 -17
  473. package/logger/noop/index.js.map +1 -1
  474. package/logger/noop/logger.d.ts +1 -1
  475. package/logger/noop/logger.js +5 -9
  476. package/logger/noop/logger.js.map +1 -1
  477. package/mail/clients/nodemailer.mail-client.d.ts +2 -2
  478. package/mail/clients/nodemailer.mail-client.js +15 -20
  479. package/mail/clients/nodemailer.mail-client.js.map +1 -1
  480. package/mail/index.d.ts +8 -8
  481. package/mail/index.js +8 -24
  482. package/mail/index.js.map +1 -1
  483. package/mail/mail-log.repository.d.ts +2 -2
  484. package/mail/mail-log.repository.js +2 -6
  485. package/mail/mail-log.repository.js.map +1 -1
  486. package/mail/mail-template-renderer.provider.d.ts +1 -1
  487. package/mail/mail-template-renderer.provider.js +6 -9
  488. package/mail/mail-template-renderer.provider.js.map +1 -1
  489. package/mail/mail-template.provider.d.ts +1 -1
  490. package/mail/mail-template.provider.js +1 -5
  491. package/mail/mail-template.provider.js.map +1 -1
  492. package/mail/mail-template.renderer.d.ts +1 -1
  493. package/mail/mail-template.renderer.js +1 -5
  494. package/mail/mail-template.renderer.js.map +1 -1
  495. package/mail/mail.client.d.ts +3 -3
  496. package/mail/mail.client.js +2 -6
  497. package/mail/mail.client.js.map +1 -1
  498. package/mail/mail.service.d.ts +7 -7
  499. package/mail/mail.service.js +24 -27
  500. package/mail/mail.service.js.map +1 -1
  501. package/mail/models/index.d.ts +6 -6
  502. package/mail/models/index.js +6 -22
  503. package/mail/models/index.js.map +1 -1
  504. package/mail/models/mail-address.model.js +1 -2
  505. package/mail/models/mail-content.model.js +1 -2
  506. package/mail/models/mail-data.model.d.ts +3 -3
  507. package/mail/models/mail-data.model.js +1 -2
  508. package/mail/models/mail-log.model.d.ts +3 -3
  509. package/mail/models/mail-log.model.js +1 -2
  510. package/mail/models/mail-send-result.model.d.ts +1 -1
  511. package/mail/models/mail-send-result.model.js +1 -2
  512. package/mail/models/mail-template.model.js +1 -2
  513. package/mail/module.d.ts +6 -6
  514. package/mail/module.js +21 -25
  515. package/mail/module.js.map +1 -1
  516. package/mail/repositories/mongo-mail-log.repository.d.ts +6 -6
  517. package/mail/repositories/mongo-mail-log.repository.js +13 -18
  518. package/mail/repositories/mongo-mail-log.repository.js.map +1 -1
  519. package/mail/template-providers/file-mail-template.provider.d.ts +5 -5
  520. package/mail/template-providers/file-mail-template.provider.js +29 -32
  521. package/mail/template-providers/file-mail-template.provider.js.map +1 -1
  522. package/mail/template-providers/memory-mail-template.provider.d.ts +2 -2
  523. package/mail/template-providers/memory-mail-template.provider.js +7 -10
  524. package/mail/template-providers/memory-mail-template.provider.js.map +1 -1
  525. package/mail/template-renderers/handlebars.mail-template-renderer.d.ts +3 -3
  526. package/mail/template-renderers/handlebars.mail-template-renderer.js +13 -17
  527. package/mail/template-renderers/handlebars.mail-template-renderer.js.map +1 -1
  528. package/mail/template-renderers/mjml.mail-template-renderer.d.ts +4 -4
  529. package/mail/template-renderers/mjml.mail-template-renderer.js +18 -18
  530. package/mail/template-renderers/mjml.mail-template-renderer.js.map +1 -1
  531. package/mail/tokens.d.ts +5 -5
  532. package/mail/tokens.js +3 -6
  533. package/mail/tokens.js.map +1 -1
  534. package/memory/index.d.ts +1 -1
  535. package/memory/index.js +1 -17
  536. package/memory/index.js.map +1 -1
  537. package/memory/observable-finalization-registry.js +3 -7
  538. package/memory/observable-finalization-registry.js.map +1 -1
  539. package/message-bus/broadcast-channel/broadcast-channel-message-bus-provider.d.ts +3 -3
  540. package/message-bus/broadcast-channel/broadcast-channel-message-bus-provider.js +3 -7
  541. package/message-bus/broadcast-channel/broadcast-channel-message-bus-provider.js.map +1 -1
  542. package/message-bus/broadcast-channel/broadcast-channel-message-bus.d.ts +3 -3
  543. package/message-bus/broadcast-channel/broadcast-channel-message-bus.js +7 -12
  544. package/message-bus/broadcast-channel/broadcast-channel-message-bus.js.map +1 -1
  545. package/message-bus/broadcast-channel/index.d.ts +2 -2
  546. package/message-bus/broadcast-channel/index.js +2 -18
  547. package/message-bus/broadcast-channel/index.js.map +1 -1
  548. package/message-bus/index.d.ts +3 -3
  549. package/message-bus/index.js +3 -19
  550. package/message-bus/index.js.map +1 -1
  551. package/message-bus/local/index.d.ts +2 -2
  552. package/message-bus/local/index.js +2 -18
  553. package/message-bus/local/index.js.map +1 -1
  554. package/message-bus/local/local-message-bus-provider.d.ts +3 -3
  555. package/message-bus/local/local-message-bus-provider.js +20 -24
  556. package/message-bus/local/local-message-bus-provider.js.map +1 -1
  557. package/message-bus/local/local-message-bus.d.ts +4 -4
  558. package/message-bus/local/local-message-bus.js +13 -16
  559. package/message-bus/local/local-message-bus.js.map +1 -1
  560. package/message-bus/local/types.js +1 -2
  561. package/message-bus/message-bus-base.d.ts +4 -4
  562. package/message-bus/message-bus-base.js +11 -15
  563. package/message-bus/message-bus-base.js.map +1 -1
  564. package/message-bus/message-bus-provider.d.ts +1 -1
  565. package/message-bus/message-bus-provider.js +1 -5
  566. package/message-bus/message-bus-provider.js.map +1 -1
  567. package/message-bus/message-bus.d.ts +4 -4
  568. package/message-bus/message-bus.js +3 -7
  569. package/message-bus/message-bus.js.map +1 -1
  570. package/migration/index.d.ts +3 -3
  571. package/migration/index.js +3 -19
  572. package/migration/index.js.map +1 -1
  573. package/migration/migration-state-repository.d.ts +2 -2
  574. package/migration/migration-state-repository.js +2 -6
  575. package/migration/migration-state-repository.js.map +1 -1
  576. package/migration/migration-state.d.ts +1 -1
  577. package/migration/migration-state.js +1 -2
  578. package/migration/migrator.d.ts +3 -3
  579. package/migration/migrator.js +24 -28
  580. package/migration/migrator.js.map +1 -1
  581. package/migration/mongo/index.d.ts +2 -2
  582. package/migration/mongo/index.js +2 -18
  583. package/migration/mongo/index.js.map +1 -1
  584. package/migration/mongo/migration-state-repository.d.ts +7 -7
  585. package/migration/mongo/migration-state-repository.js +12 -15
  586. package/migration/mongo/migration-state-repository.js.map +1 -1
  587. package/migration/mongo/module.d.ts +2 -2
  588. package/migration/mongo/module.js +7 -11
  589. package/migration/mongo/module.js.map +1 -1
  590. package/module/index.d.ts +4 -4
  591. package/module/index.js +4 -20
  592. package/module/index.js.map +1 -1
  593. package/module/module-base.d.ts +5 -5
  594. package/module/module-base.js +10 -14
  595. package/module/module-base.js.map +1 -1
  596. package/module/module-metric-reporter.d.ts +4 -4
  597. package/module/module-metric-reporter.js +8 -12
  598. package/module/module-metric-reporter.js.map +1 -1
  599. package/module/module.d.ts +1 -1
  600. package/module/module.js +4 -7
  601. package/module/module.js.map +1 -1
  602. package/module/modules/index.d.ts +2 -2
  603. package/module/modules/index.js +2 -18
  604. package/module/modules/index.js.map +1 -1
  605. package/module/modules/old-web-server.module.d.ts +7 -7
  606. package/module/modules/old-web-server.module.js +6 -28
  607. package/module/modules/old-web-server.module.js.map +1 -1
  608. package/module/modules/web-server.module.d.ts +9 -9
  609. package/module/modules/web-server.module.js +24 -47
  610. package/module/modules/web-server.module.js.map +1 -1
  611. package/module/utils.d.ts +2 -2
  612. package/module/utils.js +2 -7
  613. package/module/utils.js.map +1 -1
  614. package/object-storage/index.d.ts +3 -3
  615. package/object-storage/index.js +3 -19
  616. package/object-storage/index.js.map +1 -1
  617. package/object-storage/object-storage-provider.d.ts +1 -1
  618. package/object-storage/object-storage-provider.js +1 -5
  619. package/object-storage/object-storage-provider.js.map +1 -1
  620. package/object-storage/object-storage.d.ts +3 -3
  621. package/object-storage/object-storage.js +2 -6
  622. package/object-storage/object-storage.js.map +1 -1
  623. package/object-storage/object.js +1 -2
  624. package/object-storage/s3/index.d.ts +3 -3
  625. package/object-storage/s3/index.js +3 -19
  626. package/object-storage/s3/index.js.map +1 -1
  627. package/object-storage/s3/s3.object-storage-provider.d.ts +3 -3
  628. package/object-storage/s3/s3.object-storage-provider.js +20 -24
  629. package/object-storage/s3/s3.object-storage-provider.js.map +1 -1
  630. package/object-storage/s3/s3.object-storage.d.ts +3 -3
  631. package/object-storage/s3/s3.object-storage.js +17 -20
  632. package/object-storage/s3/s3.object-storage.js.map +1 -1
  633. package/object-storage/s3/s3.object.d.ts +1 -1
  634. package/object-storage/s3/s3.object.js +1 -2
  635. package/old-api/endpoint.d.ts +1 -1
  636. package/old-api/endpoint.js +2 -7
  637. package/old-api/endpoint.js.map +1 -1
  638. package/old-api/endpoints/echo.endpoint.d.ts +1 -1
  639. package/old-api/endpoints/echo.endpoint.js +1 -5
  640. package/old-api/endpoints/echo.endpoint.js.map +1 -1
  641. package/old-api/endpoints/index.d.ts +1 -1
  642. package/old-api/endpoints/index.js +1 -17
  643. package/old-api/endpoints/index.js.map +1 -1
  644. package/old-api/http-api.d.ts +10 -10
  645. package/old-api/http-api.js +60 -84
  646. package/old-api/http-api.js.map +1 -1
  647. package/old-api/index.d.ts +3 -3
  648. package/old-api/index.js +3 -19
  649. package/old-api/index.js.map +1 -1
  650. package/old-api/validation/index.d.ts +1 -1
  651. package/old-api/validation/index.js +1 -17
  652. package/old-api/validation/index.js.map +1 -1
  653. package/old-api/validation/types.d.ts +1 -1
  654. package/old-api/validation/types.js +2 -5
  655. package/old-api/validation/types.js.map +1 -1
  656. package/old-api/validation/validators/index.d.ts +1 -1
  657. package/old-api/validation/validators/index.js +1 -17
  658. package/old-api/validation/validators/index.js.map +1 -1
  659. package/old-api/validation/validators/noop.d.ts +1 -1
  660. package/old-api/validation/validators/noop.js +1 -5
  661. package/old-api/validation/validators/noop.js.map +1 -1
  662. package/old-api/validation/validators/superstruct.d.ts +3 -3
  663. package/old-api/validation/validators/superstruct.js +17 -28
  664. package/old-api/validation/validators/superstruct.js.map +1 -1
  665. package/old-api/validation/validators/yup.d.ts +1 -1
  666. package/old-api/validation/validators/yup.js +8 -16
  667. package/old-api/validation/validators/yup.js.map +1 -1
  668. package/openid-connect/cached-oidc-configuration.service.d.ts +3 -3
  669. package/openid-connect/cached-oidc-configuration.service.js +14 -17
  670. package/openid-connect/cached-oidc-configuration.service.js.map +1 -1
  671. package/openid-connect/index.d.ts +7 -7
  672. package/openid-connect/index.js +11 -27
  673. package/openid-connect/index.js.map +1 -1
  674. package/openid-connect/mongo-oidc-state.repository.d.ts +8 -8
  675. package/openid-connect/mongo-oidc-state.repository.js +15 -19
  676. package/openid-connect/mongo-oidc-state.repository.js.map +1 -1
  677. package/openid-connect/oidc-configuration.service.d.ts +1 -1
  678. package/openid-connect/oidc-configuration.service.js +11 -14
  679. package/openid-connect/oidc-configuration.service.js.map +1 -1
  680. package/openid-connect/oidc-state.model.d.ts +1 -1
  681. package/openid-connect/oidc-state.model.js +1 -2
  682. package/openid-connect/oidc-state.repository.d.ts +2 -2
  683. package/openid-connect/oidc-state.repository.js +2 -6
  684. package/openid-connect/oidc-state.repository.js.map +1 -1
  685. package/openid-connect/oidc.service-model.js +1 -2
  686. package/openid-connect/oidc.service.d.ts +4 -4
  687. package/openid-connect/oidc.service.js +31 -34
  688. package/openid-connect/oidc.service.js.map +1 -1
  689. package/package.json +5 -4
  690. package/process-shutdown.d.ts +2 -2
  691. package/process-shutdown.js +11 -18
  692. package/process-shutdown.js.map +1 -1
  693. package/promise/cancelable-promise.js +1 -5
  694. package/promise/cancelable-promise.js.map +1 -1
  695. package/promise/deferred-promise.js +1 -5
  696. package/promise/deferred-promise.js.map +1 -1
  697. package/promise/index.d.ts +2 -2
  698. package/promise/index.js +2 -18
  699. package/promise/index.js.map +1 -1
  700. package/queue/enqueue-batch.d.ts +1 -1
  701. package/queue/enqueue-batch.js +2 -6
  702. package/queue/enqueue-batch.js.map +1 -1
  703. package/queue/index.d.ts +3 -3
  704. package/queue/index.js +3 -19
  705. package/queue/index.js.map +1 -1
  706. package/queue/mongo/index.d.ts +4 -4
  707. package/queue/mongo/index.js +4 -20
  708. package/queue/mongo/index.js.map +1 -1
  709. package/queue/mongo/job.d.ts +3 -3
  710. package/queue/mongo/job.js +1 -2
  711. package/queue/mongo/mongo-job.repository.d.ts +7 -7
  712. package/queue/mongo/mongo-job.repository.js +20 -34
  713. package/queue/mongo/mongo-job.repository.js.map +1 -1
  714. package/queue/mongo/queue.d.ts +6 -6
  715. package/queue/mongo/queue.js +62 -111
  716. package/queue/mongo/queue.js.map +1 -1
  717. package/queue/mongo/queue.provider.d.ts +10 -10
  718. package/queue/mongo/queue.provider.js +16 -20
  719. package/queue/mongo/queue.provider.js.map +1 -1
  720. package/queue/provider.d.ts +1 -1
  721. package/queue/provider.js +1 -5
  722. package/queue/provider.js.map +1 -1
  723. package/queue/queue.d.ts +4 -4
  724. package/queue/queue.js +9 -13
  725. package/queue/queue.js.map +1 -1
  726. package/random/index.d.ts +1 -1
  727. package/random/index.js +1 -17
  728. package/random/index.js.map +1 -1
  729. package/random/number/index.d.ts +3 -3
  730. package/random/number/index.js +3 -19
  731. package/random/number/index.js.map +1 -1
  732. package/random/number/mulberry32.d.ts +1 -1
  733. package/random/number/mulberry32.js +3 -8
  734. package/random/number/mulberry32.js.map +1 -1
  735. package/random/number/seeded.js +1 -5
  736. package/random/number/seeded.js.map +1 -1
  737. package/random/number/sfc32.d.ts +1 -1
  738. package/random/number/sfc32.js +3 -8
  739. package/random/number/sfc32.js.map +1 -1
  740. package/rxjs/cast.js +2 -7
  741. package/rxjs/cast.js.map +1 -1
  742. package/rxjs/index.d.ts +11 -11
  743. package/rxjs/index.js +11 -27
  744. package/rxjs/index.js.map +1 -1
  745. package/rxjs/intersection-observer.js +10 -25
  746. package/rxjs/intersection-observer.js.map +1 -1
  747. package/rxjs/mutation-observer.js +11 -27
  748. package/rxjs/mutation-observer.js.map +1 -1
  749. package/rxjs/noop.js +2 -7
  750. package/rxjs/noop.js.map +1 -1
  751. package/rxjs/performance-observer.js +9 -13
  752. package/rxjs/performance-observer.js.map +1 -1
  753. package/rxjs/resize-observer.js +11 -27
  754. package/rxjs/resize-observer.js.map +1 -1
  755. package/rxjs/retry-backoff.d.ts +1 -1
  756. package/rxjs/retry-backoff.js +13 -18
  757. package/rxjs/retry-backoff.js.map +1 -1
  758. package/rxjs/slow-array.js +8 -17
  759. package/rxjs/slow-array.js.map +1 -1
  760. package/rxjs/teardown.js +3 -7
  761. package/rxjs/teardown.js.map +1 -1
  762. package/rxjs/timing.js +14 -17
  763. package/rxjs/timing.js.map +1 -1
  764. package/rxjs/touch.js +7 -11
  765. package/rxjs/touch.js.map +1 -1
  766. package/schema/index.d.ts +4 -4
  767. package/schema/index.js +4 -20
  768. package/schema/index.js.map +1 -1
  769. package/schema/schema.error.d.ts +2 -2
  770. package/schema/schema.error.js +6 -11
  771. package/schema/schema.error.js.map +1 -1
  772. package/schema/schema.validator.d.ts +4 -4
  773. package/schema/schema.validator.js +19 -26
  774. package/schema/schema.validator.js.map +1 -1
  775. package/schema/schemas/any.d.ts +3 -3
  776. package/schema/schemas/any.js +9 -11
  777. package/schema/schemas/any.js.map +1 -1
  778. package/schema/schemas/array.d.ts +4 -4
  779. package/schema/schemas/array.js +20 -21
  780. package/schema/schemas/array.js.map +1 -1
  781. package/schema/schemas/async-iterable.d.ts +4 -4
  782. package/schema/schemas/async-iterable.js +18 -19
  783. package/schema/schemas/async-iterable.js.map +1 -1
  784. package/schema/schemas/boolean.d.ts +4 -4
  785. package/schema/schemas/boolean.js +13 -16
  786. package/schema/schemas/boolean.js.map +1 -1
  787. package/schema/schemas/date.d.ts +4 -4
  788. package/schema/schemas/date.js +22 -25
  789. package/schema/schemas/date.js.map +1 -1
  790. package/schema/schemas/defaulted.d.ts +5 -5
  791. package/schema/schemas/defaulted.js +14 -14
  792. package/schema/schemas/defaulted.js.map +1 -1
  793. package/schema/schemas/enumeration.d.ts +6 -6
  794. package/schema/schemas/enumeration.js +24 -26
  795. package/schema/schemas/enumeration.js.map +1 -1
  796. package/schema/schemas/index.d.ts +24 -24
  797. package/schema/schemas/index.js +24 -40
  798. package/schema/schemas/index.js.map +1 -1
  799. package/schema/schemas/instance.d.ts +5 -5
  800. package/schema/schemas/instance.js +13 -14
  801. package/schema/schemas/instance.js.map +1 -1
  802. package/schema/schemas/iterable.d.ts +4 -4
  803. package/schema/schemas/iterable.js +18 -19
  804. package/schema/schemas/iterable.js.map +1 -1
  805. package/schema/schemas/literal.d.ts +4 -4
  806. package/schema/schemas/literal.js +12 -13
  807. package/schema/schemas/literal.js.map +1 -1
  808. package/schema/schemas/never.d.ts +4 -4
  809. package/schema/schemas/never.js +12 -14
  810. package/schema/schemas/never.js.map +1 -1
  811. package/schema/schemas/nullable.d.ts +4 -4
  812. package/schema/schemas/nullable.js +14 -16
  813. package/schema/schemas/nullable.js.map +1 -1
  814. package/schema/schemas/number.d.ts +4 -4
  815. package/schema/schemas/number.js +21 -24
  816. package/schema/schemas/number.js.map +1 -1
  817. package/schema/schemas/object.d.ts +5 -5
  818. package/schema/schemas/object.js +24 -26
  819. package/schema/schemas/object.js.map +1 -1
  820. package/schema/schemas/optional.d.ts +4 -4
  821. package/schema/schemas/optional.js +14 -16
  822. package/schema/schemas/optional.js.map +1 -1
  823. package/schema/schemas/preprocess.d.ts +4 -4
  824. package/schema/schemas/preprocess.js +16 -16
  825. package/schema/schemas/preprocess.js.map +1 -1
  826. package/schema/schemas/readable-stream.d.ts +4 -4
  827. package/schema/schemas/readable-stream.js +12 -14
  828. package/schema/schemas/readable-stream.js.map +1 -1
  829. package/schema/schemas/refine.d.ts +5 -5
  830. package/schema/schemas/refine.js +19 -19
  831. package/schema/schemas/refine.js.map +1 -1
  832. package/schema/schemas/regexp.d.ts +4 -4
  833. package/schema/schemas/regexp.js +16 -19
  834. package/schema/schemas/regexp.js.map +1 -1
  835. package/schema/schemas/string.d.ts +4 -4
  836. package/schema/schemas/string.js +22 -26
  837. package/schema/schemas/string.js.map +1 -1
  838. package/schema/schemas/transform.d.ts +4 -4
  839. package/schema/schemas/transform.js +16 -16
  840. package/schema/schemas/transform.js.map +1 -1
  841. package/schema/schemas/uint8-array.d.ts +4 -4
  842. package/schema/schemas/uint8-array.js +19 -22
  843. package/schema/schemas/uint8-array.js.map +1 -1
  844. package/schema/schemas/union.d.ts +4 -4
  845. package/schema/schemas/union.js +14 -15
  846. package/schema/schemas/union.js.map +1 -1
  847. package/schema/schemas/unknown.d.ts +3 -3
  848. package/schema/schemas/unknown.js +9 -11
  849. package/schema/schemas/unknown.js.map +1 -1
  850. package/schema/types.d.ts +2 -2
  851. package/schema/types.js +1 -5
  852. package/schema/types.js.map +1 -1
  853. package/search-index/elastic/config.d.ts +3 -3
  854. package/search-index/elastic/config.js +6 -9
  855. package/search-index/elastic/config.js.map +1 -1
  856. package/search-index/elastic/index.d.ts +5 -5
  857. package/search-index/elastic/index.js +5 -21
  858. package/search-index/elastic/index.js.map +1 -1
  859. package/search-index/elastic/model/elastic-query.d.ts +1 -1
  860. package/search-index/elastic/model/elastic-query.js +1 -2
  861. package/search-index/elastic/model/index-mapping.d.ts +3 -3
  862. package/search-index/elastic/model/index-mapping.js +3 -7
  863. package/search-index/elastic/model/index-mapping.js.map +1 -1
  864. package/search-index/elastic/model/index.d.ts +3 -3
  865. package/search-index/elastic/model/index.js +3 -19
  866. package/search-index/elastic/model/index.js.map +1 -1
  867. package/search-index/elastic/model/sort.d.ts +3 -3
  868. package/search-index/elastic/model/sort.js +1 -2
  869. package/search-index/elastic/module.d.ts +4 -4
  870. package/search-index/elastic/module.js +22 -28
  871. package/search-index/elastic/module.js.map +1 -1
  872. package/search-index/elastic/query-builder/boolean-query-builder.d.ts +1 -1
  873. package/search-index/elastic/query-builder/boolean-query-builder.js +1 -5
  874. package/search-index/elastic/query-builder/boolean-query-builder.js.map +1 -1
  875. package/search-index/elastic/query-builder/index.d.ts +1 -1
  876. package/search-index/elastic/query-builder/index.js +1 -17
  877. package/search-index/elastic/query-builder/index.js.map +1 -1
  878. package/search-index/elastic/query-converter.d.ts +4 -4
  879. package/search-index/elastic/query-converter.js +29 -37
  880. package/search-index/elastic/query-converter.js.map +1 -1
  881. package/search-index/elastic/search-index.d.ts +9 -9
  882. package/search-index/elastic/search-index.js +36 -51
  883. package/search-index/elastic/search-index.js.map +1 -1
  884. package/search-index/elastic/sort-converter.d.ts +2 -2
  885. package/search-index/elastic/sort-converter.js +3 -8
  886. package/search-index/elastic/sort-converter.js.map +1 -1
  887. package/search-index/elastic/types.d.ts +1 -1
  888. package/search-index/elastic/types.js +1 -2
  889. package/search-index/error.d.ts +1 -1
  890. package/search-index/error.js +4 -8
  891. package/search-index/error.js.map +1 -1
  892. package/search-index/index.d.ts +3 -3
  893. package/search-index/index.js +3 -19
  894. package/search-index/index.js.map +1 -1
  895. package/search-index/memory/index.d.ts +1 -1
  896. package/search-index/memory/index.js +1 -17
  897. package/search-index/memory/index.js.map +1 -1
  898. package/search-index/memory/memory-search-index.d.ts +4 -3
  899. package/search-index/memory/memory-search-index.js +25 -30
  900. package/search-index/memory/memory-search-index.js.map +1 -1
  901. package/search-index/search-index.d.ts +2 -3
  902. package/search-index/search-index.js +11 -41
  903. package/search-index/search-index.js.map +1 -1
  904. package/search-index/search-result.d.ts +1 -1
  905. package/search-index/search-result.js +1 -2
  906. package/serializer/handlers/binary.d.ts +2 -2
  907. package/serializer/handlers/binary.js +11 -20
  908. package/serializer/handlers/binary.js.map +1 -1
  909. package/serializer/handlers/date.js +2 -7
  910. package/serializer/handlers/date.js.map +1 -1
  911. package/serializer/handlers/error.js +2 -7
  912. package/serializer/handlers/error.js.map +1 -1
  913. package/serializer/handlers/index.d.ts +7 -7
  914. package/serializer/handlers/index.js +7 -23
  915. package/serializer/handlers/index.js.map +1 -1
  916. package/serializer/handlers/map.d.ts +1 -1
  917. package/serializer/handlers/map.js +2 -7
  918. package/serializer/handlers/map.js.map +1 -1
  919. package/serializer/handlers/regex.js +2 -7
  920. package/serializer/handlers/regex.js.map +1 -1
  921. package/serializer/handlers/register.d.ts +1 -1
  922. package/serializer/handlers/register.js +17 -21
  923. package/serializer/handlers/register.js.map +1 -1
  924. package/serializer/handlers/set.d.ts +2 -2
  925. package/serializer/handlers/set.js +2 -7
  926. package/serializer/handlers/set.js.map +1 -1
  927. package/serializer/index.d.ts +4 -4
  928. package/serializer/index.js +3 -24
  929. package/serializer/index.js.map +1 -1
  930. package/serializer/serializable.d.ts +1 -1
  931. package/serializer/serializable.js +15 -24
  932. package/serializer/serializable.js.map +1 -1
  933. package/serializer/serializer.d.ts +2 -2
  934. package/serializer/serializer.js +30 -37
  935. package/serializer/serializer.js.map +1 -1
  936. package/serializer/types.d.ts +1 -1
  937. package/serializer/types.js +5 -8
  938. package/serializer/types.js.map +1 -1
  939. package/tailwind/colors.d.ts +1 -1
  940. package/tailwind/colors.js +4 -10
  941. package/tailwind/colors.js.map +1 -1
  942. package/tailwind/index.d.ts +1 -1
  943. package/tailwind/index.js +1 -17
  944. package/tailwind/index.js.map +1 -1
  945. package/tokens.d.ts +1 -1
  946. package/tokens.js +2 -5
  947. package/tokens.js.map +1 -1
  948. package/tsconfig.json +7 -3
  949. package/types/geo-json.d.ts +1 -1
  950. package/types/geo-json.js +1 -2
  951. package/types.js +1 -2
  952. package/types.js.map +1 -1
  953. package/utils/alphabet.js +2 -5
  954. package/utils/alphabet.js.map +1 -1
  955. package/utils/any-iterable-iterator.js +4 -8
  956. package/utils/any-iterable-iterator.js.map +1 -1
  957. package/utils/array/array-backtracker.js +8 -12
  958. package/utils/array/array-backtracker.js.map +1 -1
  959. package/utils/array/array.js +13 -21
  960. package/utils/array/array.js.map +1 -1
  961. package/utils/array/index.d.ts +2 -2
  962. package/utils/array/index.js +2 -18
  963. package/utils/array/index.js.map +1 -1
  964. package/utils/async-iterable-helpers/all.d.ts +2 -2
  965. package/utils/async-iterable-helpers/all.js +9 -31
  966. package/utils/async-iterable-helpers/all.js.map +1 -1
  967. package/utils/async-iterable-helpers/any.d.ts +2 -2
  968. package/utils/async-iterable-helpers/any.js +9 -31
  969. package/utils/async-iterable-helpers/any.js.map +1 -1
  970. package/utils/async-iterable-helpers/assert.d.ts +2 -2
  971. package/utils/async-iterable-helpers/assert.js +22 -60
  972. package/utils/async-iterable-helpers/assert.js.map +1 -1
  973. package/utils/async-iterable-helpers/batch.d.ts +1 -1
  974. package/utils/async-iterable-helpers/batch.js +25 -63
  975. package/utils/async-iterable-helpers/batch.js.map +1 -1
  976. package/utils/async-iterable-helpers/buffer.d.ts +1 -1
  977. package/utils/async-iterable-helpers/buffer.js +43 -90
  978. package/utils/async-iterable-helpers/buffer.js.map +1 -1
  979. package/utils/async-iterable-helpers/concat.d.ts +1 -1
  980. package/utils/async-iterable-helpers/concat.js +3 -33
  981. package/utils/async-iterable-helpers/concat.js.map +1 -1
  982. package/utils/async-iterable-helpers/default-if-empty.d.ts +1 -1
  983. package/utils/async-iterable-helpers/default-if-empty.js +9 -45
  984. package/utils/async-iterable-helpers/default-if-empty.js.map +1 -1
  985. package/utils/async-iterable-helpers/deferred.d.ts +1 -1
  986. package/utils/async-iterable-helpers/deferred.js +3 -33
  987. package/utils/async-iterable-helpers/deferred.js.map +1 -1
  988. package/utils/async-iterable-helpers/distinct.d.ts +2 -2
  989. package/utils/async-iterable-helpers/distinct.js +23 -61
  990. package/utils/async-iterable-helpers/distinct.js.map +1 -1
  991. package/utils/async-iterable-helpers/drain.d.ts +1 -1
  992. package/utils/async-iterable-helpers/drain.js +3 -24
  993. package/utils/async-iterable-helpers/drain.js.map +1 -1
  994. package/utils/async-iterable-helpers/filter.d.ts +2 -2
  995. package/utils/async-iterable-helpers/filter.js +22 -60
  996. package/utils/async-iterable-helpers/filter.js.map +1 -1
  997. package/utils/async-iterable-helpers/first-or-default.d.ts +3 -3
  998. package/utils/async-iterable-helpers/first-or-default.js +6 -28
  999. package/utils/async-iterable-helpers/first-or-default.js.map +1 -1
  1000. package/utils/async-iterable-helpers/first.d.ts +3 -3
  1001. package/utils/async-iterable-helpers/first.js +6 -28
  1002. package/utils/async-iterable-helpers/first.js.map +1 -1
  1003. package/utils/async-iterable-helpers/for-each.d.ts +2 -2
  1004. package/utils/async-iterable-helpers/for-each.js +7 -29
  1005. package/utils/async-iterable-helpers/for-each.js.map +1 -1
  1006. package/utils/async-iterable-helpers/group-single.d.ts +2 -2
  1007. package/utils/async-iterable-helpers/group-single.js +3 -33
  1008. package/utils/async-iterable-helpers/group-single.js.map +1 -1
  1009. package/utils/async-iterable-helpers/group-to-map.d.ts +2 -2
  1010. package/utils/async-iterable-helpers/group-to-map.js +9 -31
  1011. package/utils/async-iterable-helpers/group-to-map.js.map +1 -1
  1012. package/utils/async-iterable-helpers/group-to-single-map.d.ts +2 -2
  1013. package/utils/async-iterable-helpers/group-to-single-map.js +8 -30
  1014. package/utils/async-iterable-helpers/group-to-single-map.js.map +1 -1
  1015. package/utils/async-iterable-helpers/group.d.ts +2 -2
  1016. package/utils/async-iterable-helpers/group.js +3 -33
  1017. package/utils/async-iterable-helpers/group.js.map +1 -1
  1018. package/utils/async-iterable-helpers/index.d.ts +45 -45
  1019. package/utils/async-iterable-helpers/index.js +45 -61
  1020. package/utils/async-iterable-helpers/index.js.map +1 -1
  1021. package/utils/async-iterable-helpers/interrupt.d.ts +1 -1
  1022. package/utils/async-iterable-helpers/interrupt.js +19 -69
  1023. package/utils/async-iterable-helpers/interrupt.js.map +1 -1
  1024. package/utils/async-iterable-helpers/is-async-iterable.d.ts +1 -1
  1025. package/utils/async-iterable-helpers/is-async-iterable.js +5 -10
  1026. package/utils/async-iterable-helpers/is-async-iterable.js.map +1 -1
  1027. package/utils/async-iterable-helpers/last-or-default.d.ts +3 -3
  1028. package/utils/async-iterable-helpers/last-or-default.js +6 -28
  1029. package/utils/async-iterable-helpers/last-or-default.js.map +1 -1
  1030. package/utils/async-iterable-helpers/last.d.ts +3 -3
  1031. package/utils/async-iterable-helpers/last.js +6 -28
  1032. package/utils/async-iterable-helpers/last.js.map +1 -1
  1033. package/utils/async-iterable-helpers/map-many.d.ts +2 -2
  1034. package/utils/async-iterable-helpers/map-many.js +19 -62
  1035. package/utils/async-iterable-helpers/map-many.js.map +1 -1
  1036. package/utils/async-iterable-helpers/map.d.ts +2 -2
  1037. package/utils/async-iterable-helpers/map.js +19 -57
  1038. package/utils/async-iterable-helpers/map.js.map +1 -1
  1039. package/utils/async-iterable-helpers/materialize.d.ts +1 -1
  1040. package/utils/async-iterable-helpers/materialize.js +9 -41
  1041. package/utils/async-iterable-helpers/materialize.js.map +1 -1
  1042. package/utils/async-iterable-helpers/metadata.d.ts +2 -2
  1043. package/utils/async-iterable-helpers/metadata.js +35 -75
  1044. package/utils/async-iterable-helpers/metadata.js.map +1 -1
  1045. package/utils/async-iterable-helpers/multiplex.d.ts +1 -1
  1046. package/utils/async-iterable-helpers/multiplex.js +7 -29
  1047. package/utils/async-iterable-helpers/multiplex.js.map +1 -1
  1048. package/utils/async-iterable-helpers/observable-iterable.js +31 -49
  1049. package/utils/async-iterable-helpers/observable-iterable.js.map +1 -1
  1050. package/utils/async-iterable-helpers/pairwise.d.ts +1 -1
  1051. package/utils/async-iterable-helpers/pairwise.js +24 -62
  1052. package/utils/async-iterable-helpers/pairwise.js.map +1 -1
  1053. package/utils/async-iterable-helpers/parallel/feed.d.ts +2 -2
  1054. package/utils/async-iterable-helpers/parallel/feed.js +24 -54
  1055. package/utils/async-iterable-helpers/parallel/feed.js.map +1 -1
  1056. package/utils/async-iterable-helpers/parallel/filter.d.ts +2 -2
  1057. package/utils/async-iterable-helpers/parallel/filter.js +3 -7
  1058. package/utils/async-iterable-helpers/parallel/filter.js.map +1 -1
  1059. package/utils/async-iterable-helpers/parallel/for-each.d.ts +2 -2
  1060. package/utils/async-iterable-helpers/parallel/for-each.js +13 -35
  1061. package/utils/async-iterable-helpers/parallel/for-each.js.map +1 -1
  1062. package/utils/async-iterable-helpers/parallel/group.d.ts +2 -2
  1063. package/utils/async-iterable-helpers/parallel/group.js +5 -9
  1064. package/utils/async-iterable-helpers/parallel/group.js.map +1 -1
  1065. package/utils/async-iterable-helpers/parallel/index.d.ts +7 -7
  1066. package/utils/async-iterable-helpers/parallel/index.js +7 -23
  1067. package/utils/async-iterable-helpers/parallel/index.js.map +1 -1
  1068. package/utils/async-iterable-helpers/parallel/map.d.ts +2 -2
  1069. package/utils/async-iterable-helpers/parallel/map.js +3 -7
  1070. package/utils/async-iterable-helpers/parallel/map.js.map +1 -1
  1071. package/utils/async-iterable-helpers/parallel/tap.d.ts +2 -2
  1072. package/utils/async-iterable-helpers/parallel/tap.js +3 -7
  1073. package/utils/async-iterable-helpers/parallel/tap.js.map +1 -1
  1074. package/utils/async-iterable-helpers/parallel/types.js +1 -2
  1075. package/utils/async-iterable-helpers/reduce.d.ts +2 -2
  1076. package/utils/async-iterable-helpers/reduce.js +11 -33
  1077. package/utils/async-iterable-helpers/reduce.js.map +1 -1
  1078. package/utils/async-iterable-helpers/retry.d.ts +2 -2
  1079. package/utils/async-iterable-helpers/retry.js +41 -79
  1080. package/utils/async-iterable-helpers/retry.js.map +1 -1
  1081. package/utils/async-iterable-helpers/single-or-default.d.ts +3 -3
  1082. package/utils/async-iterable-helpers/single-or-default.js +11 -33
  1083. package/utils/async-iterable-helpers/single-or-default.js.map +1 -1
  1084. package/utils/async-iterable-helpers/single.d.ts +3 -3
  1085. package/utils/async-iterable-helpers/single.js +11 -33
  1086. package/utils/async-iterable-helpers/single.js.map +1 -1
  1087. package/utils/async-iterable-helpers/skip.d.ts +1 -1
  1088. package/utils/async-iterable-helpers/skip.js +3 -7
  1089. package/utils/async-iterable-helpers/skip.js.map +1 -1
  1090. package/utils/async-iterable-helpers/sort.d.ts +2 -2
  1091. package/utils/async-iterable-helpers/sort.js +5 -9
  1092. package/utils/async-iterable-helpers/sort.js.map +1 -1
  1093. package/utils/async-iterable-helpers/take-until.d.ts +2 -2
  1094. package/utils/async-iterable-helpers/take-until.js +30 -52
  1095. package/utils/async-iterable-helpers/take-until.js.map +1 -1
  1096. package/utils/async-iterable-helpers/take-while.d.ts +2 -2
  1097. package/utils/async-iterable-helpers/take-while.js +28 -66
  1098. package/utils/async-iterable-helpers/take-while.js.map +1 -1
  1099. package/utils/async-iterable-helpers/take.d.ts +1 -1
  1100. package/utils/async-iterable-helpers/take.js +10 -46
  1101. package/utils/async-iterable-helpers/take.js.map +1 -1
  1102. package/utils/async-iterable-helpers/tap.d.ts +2 -2
  1103. package/utils/async-iterable-helpers/tap.js +19 -57
  1104. package/utils/async-iterable-helpers/tap.js.map +1 -1
  1105. package/utils/async-iterable-helpers/throttle.d.ts +2 -2
  1106. package/utils/async-iterable-helpers/throttle.js +9 -45
  1107. package/utils/async-iterable-helpers/throttle.js.map +1 -1
  1108. package/utils/async-iterable-helpers/to-array.d.ts +1 -1
  1109. package/utils/async-iterable-helpers/to-array.js +5 -27
  1110. package/utils/async-iterable-helpers/to-array.js.map +1 -1
  1111. package/utils/async-iterable-helpers/to-async-iterable-iterator.d.ts +1 -1
  1112. package/utils/async-iterable-helpers/to-async-iterable-iterator.js +36 -74
  1113. package/utils/async-iterable-helpers/to-async-iterable-iterator.js.map +1 -1
  1114. package/utils/async-iterable-helpers/to-async-iterator.d.ts +1 -1
  1115. package/utils/async-iterable-helpers/to-async-iterator.js +9 -14
  1116. package/utils/async-iterable-helpers/to-async-iterator.js.map +1 -1
  1117. package/utils/async-iterable-helpers/to-sync-iterable.d.ts +1 -1
  1118. package/utils/async-iterable-helpers/to-sync-iterable.js +5 -9
  1119. package/utils/async-iterable-helpers/to-sync-iterable.js.map +1 -1
  1120. package/utils/async-iterable-helpers/types.d.ts +1 -1
  1121. package/utils/async-iterable-helpers/types.js +1 -2
  1122. package/utils/async-iterable-helpers/while.d.ts +2 -2
  1123. package/utils/async-iterable-helpers/while.js +24 -62
  1124. package/utils/async-iterable-helpers/while.js.map +1 -1
  1125. package/utils/async-iterator-iterable-iterator.js +24 -42
  1126. package/utils/async-iterator-iterable-iterator.js.map +1 -1
  1127. package/utils/backoff.d.ts +2 -2
  1128. package/utils/backoff.js +30 -53
  1129. package/utils/backoff.js.map +1 -1
  1130. package/utils/base64.d.ts +1 -1
  1131. package/utils/base64.js +15 -26
  1132. package/utils/base64.js.map +1 -1
  1133. package/utils/benchmark.js +17 -25
  1134. package/utils/benchmark.js.map +1 -1
  1135. package/utils/binary-search.d.ts +1 -1
  1136. package/utils/binary-search.js +10 -21
  1137. package/utils/binary-search.js.map +1 -1
  1138. package/utils/binary.d.ts +1 -1
  1139. package/utils/binary.js +7 -13
  1140. package/utils/binary.js.map +1 -1
  1141. package/utils/cancellation-token.js +22 -26
  1142. package/utils/cancellation-token.js.map +1 -1
  1143. package/utils/comparison.js +7 -17
  1144. package/utils/comparison.js.map +1 -1
  1145. package/utils/compression.d.ts +2 -2
  1146. package/utils/compression.js +18 -25
  1147. package/utils/compression.js.map +1 -1
  1148. package/utils/config-parser.js +11 -18
  1149. package/utils/config-parser.js.map +1 -1
  1150. package/utils/cryptography.d.ts +1 -1
  1151. package/utils/cryptography.js +54 -69
  1152. package/utils/cryptography.js.map +1 -1
  1153. package/utils/date-time.js +34 -57
  1154. package/utils/date-time.js.map +1 -1
  1155. package/utils/encoding.d.ts +1 -1
  1156. package/utils/encoding.js +12 -19
  1157. package/utils/encoding.js.map +1 -1
  1158. package/utils/enum.d.ts +1 -1
  1159. package/utils/enum.js +7 -13
  1160. package/utils/enum.js.map +1 -1
  1161. package/utils/equals.d.ts +2 -2
  1162. package/utils/equals.js +17 -24
  1163. package/utils/equals.js.map +1 -1
  1164. package/utils/event-loop.d.ts +2 -2
  1165. package/utils/event-loop.js +9 -14
  1166. package/utils/event-loop.js.map +1 -1
  1167. package/utils/factory-map.js +2 -6
  1168. package/utils/factory-map.js.map +1 -1
  1169. package/utils/feedable-async-iterable.js +16 -53
  1170. package/utils/feedable-async-iterable.js.map +1 -1
  1171. package/utils/file-reader.js +6 -13
  1172. package/utils/file-reader.js.map +1 -1
  1173. package/utils/function/index.d.ts +2 -2
  1174. package/utils/function/index.js +2 -18
  1175. package/utils/function/index.js.map +1 -1
  1176. package/utils/function/memoize.js +4 -9
  1177. package/utils/function/memoize.js.map +1 -1
  1178. package/utils/function/throttle.js +5 -9
  1179. package/utils/function/throttle.js.map +1 -1
  1180. package/utils/helpers.d.ts +1 -1
  1181. package/utils/helpers.js +54 -86
  1182. package/utils/helpers.js.map +1 -1
  1183. package/utils/image.js +22 -30
  1184. package/utils/image.js.map +1 -1
  1185. package/utils/index.d.ts +42 -42
  1186. package/utils/index.js +42 -58
  1187. package/utils/index.js.map +1 -1
  1188. package/utils/iterable-helpers/all.d.ts +1 -1
  1189. package/utils/iterable-helpers/all.js +1 -5
  1190. package/utils/iterable-helpers/all.js.map +1 -1
  1191. package/utils/iterable-helpers/any.d.ts +1 -1
  1192. package/utils/iterable-helpers/any.js +1 -5
  1193. package/utils/iterable-helpers/any.js.map +1 -1
  1194. package/utils/iterable-helpers/assert.d.ts +1 -1
  1195. package/utils/iterable-helpers/assert.js +3 -7
  1196. package/utils/iterable-helpers/assert.js.map +1 -1
  1197. package/utils/iterable-helpers/batch.js +1 -5
  1198. package/utils/iterable-helpers/batch.js.map +1 -1
  1199. package/utils/iterable-helpers/concat.js +1 -5
  1200. package/utils/iterable-helpers/concat.js.map +1 -1
  1201. package/utils/iterable-helpers/default-if-empty.js +1 -5
  1202. package/utils/iterable-helpers/default-if-empty.js.map +1 -1
  1203. package/utils/iterable-helpers/deferred.js +1 -5
  1204. package/utils/iterable-helpers/deferred.js.map +1 -1
  1205. package/utils/iterable-helpers/distinct.d.ts +1 -1
  1206. package/utils/iterable-helpers/distinct.js +1 -5
  1207. package/utils/iterable-helpers/distinct.js.map +1 -1
  1208. package/utils/iterable-helpers/drain.js +1 -5
  1209. package/utils/iterable-helpers/drain.js.map +1 -1
  1210. package/utils/iterable-helpers/filter.d.ts +1 -1
  1211. package/utils/iterable-helpers/filter.js +1 -5
  1212. package/utils/iterable-helpers/filter.js.map +1 -1
  1213. package/utils/iterable-helpers/first-or-default.d.ts +1 -1
  1214. package/utils/iterable-helpers/first-or-default.js +3 -7
  1215. package/utils/iterable-helpers/first-or-default.js.map +1 -1
  1216. package/utils/iterable-helpers/first.d.ts +1 -1
  1217. package/utils/iterable-helpers/first.js +3 -7
  1218. package/utils/iterable-helpers/first.js.map +1 -1
  1219. package/utils/iterable-helpers/for-each.d.ts +1 -1
  1220. package/utils/iterable-helpers/for-each.js +1 -5
  1221. package/utils/iterable-helpers/for-each.js.map +1 -1
  1222. package/utils/iterable-helpers/group-single.d.ts +1 -1
  1223. package/utils/iterable-helpers/group-single.js +3 -7
  1224. package/utils/iterable-helpers/group-single.js.map +1 -1
  1225. package/utils/iterable-helpers/group-to-map.d.ts +1 -1
  1226. package/utils/iterable-helpers/group-to-map.js +3 -7
  1227. package/utils/iterable-helpers/group-to-map.js.map +1 -1
  1228. package/utils/iterable-helpers/group-to-single-map.d.ts +1 -1
  1229. package/utils/iterable-helpers/group-to-single-map.js +1 -5
  1230. package/utils/iterable-helpers/group-to-single-map.js.map +1 -1
  1231. package/utils/iterable-helpers/group.d.ts +1 -1
  1232. package/utils/iterable-helpers/group.js +3 -7
  1233. package/utils/iterable-helpers/group.js.map +1 -1
  1234. package/utils/iterable-helpers/index.d.ts +37 -37
  1235. package/utils/iterable-helpers/index.js +37 -53
  1236. package/utils/iterable-helpers/index.js.map +1 -1
  1237. package/utils/iterable-helpers/is-iterable.d.ts +1 -1
  1238. package/utils/iterable-helpers/is-iterable.js +5 -10
  1239. package/utils/iterable-helpers/is-iterable.js.map +1 -1
  1240. package/utils/iterable-helpers/last-or-default.d.ts +1 -1
  1241. package/utils/iterable-helpers/last-or-default.js +3 -7
  1242. package/utils/iterable-helpers/last-or-default.js.map +1 -1
  1243. package/utils/iterable-helpers/last.d.ts +1 -1
  1244. package/utils/iterable-helpers/last.js +3 -7
  1245. package/utils/iterable-helpers/last.js.map +1 -1
  1246. package/utils/iterable-helpers/map-many.d.ts +1 -1
  1247. package/utils/iterable-helpers/map-many.js +1 -5
  1248. package/utils/iterable-helpers/map-many.js.map +1 -1
  1249. package/utils/iterable-helpers/map.d.ts +1 -1
  1250. package/utils/iterable-helpers/map.js +1 -5
  1251. package/utils/iterable-helpers/map.js.map +1 -1
  1252. package/utils/iterable-helpers/materialize.js +1 -5
  1253. package/utils/iterable-helpers/materialize.js.map +1 -1
  1254. package/utils/iterable-helpers/metadata.d.ts +1 -1
  1255. package/utils/iterable-helpers/metadata.js +1 -5
  1256. package/utils/iterable-helpers/metadata.js.map +1 -1
  1257. package/utils/iterable-helpers/pairwise.js +1 -5
  1258. package/utils/iterable-helpers/pairwise.js.map +1 -1
  1259. package/utils/iterable-helpers/range.js +1 -5
  1260. package/utils/iterable-helpers/range.js.map +1 -1
  1261. package/utils/iterable-helpers/reduce.d.ts +1 -1
  1262. package/utils/iterable-helpers/reduce.js +1 -5
  1263. package/utils/iterable-helpers/reduce.js.map +1 -1
  1264. package/utils/iterable-helpers/single-or-default.d.ts +1 -1
  1265. package/utils/iterable-helpers/single-or-default.js +1 -5
  1266. package/utils/iterable-helpers/single-or-default.js.map +1 -1
  1267. package/utils/iterable-helpers/single.d.ts +1 -1
  1268. package/utils/iterable-helpers/single.js +1 -5
  1269. package/utils/iterable-helpers/single.js.map +1 -1
  1270. package/utils/iterable-helpers/skip.js +1 -5
  1271. package/utils/iterable-helpers/skip.js.map +1 -1
  1272. package/utils/iterable-helpers/sort.d.ts +1 -1
  1273. package/utils/iterable-helpers/sort.js +2 -6
  1274. package/utils/iterable-helpers/sort.js.map +1 -1
  1275. package/utils/iterable-helpers/take-until.d.ts +1 -1
  1276. package/utils/iterable-helpers/take-until.js +1 -5
  1277. package/utils/iterable-helpers/take-until.js.map +1 -1
  1278. package/utils/iterable-helpers/take-while.d.ts +1 -1
  1279. package/utils/iterable-helpers/take-while.js +1 -5
  1280. package/utils/iterable-helpers/take-while.js.map +1 -1
  1281. package/utils/iterable-helpers/take.js +1 -5
  1282. package/utils/iterable-helpers/take.js.map +1 -1
  1283. package/utils/iterable-helpers/tap.d.ts +1 -1
  1284. package/utils/iterable-helpers/tap.js +1 -5
  1285. package/utils/iterable-helpers/tap.js.map +1 -1
  1286. package/utils/iterable-helpers/types.js +1 -2
  1287. package/utils/iterable-helpers/while.d.ts +1 -1
  1288. package/utils/iterable-helpers/while.js +1 -5
  1289. package/utils/iterable-helpers/while.js.map +1 -1
  1290. package/utils/jwt.d.ts +2 -2
  1291. package/utils/jwt.js +26 -31
  1292. package/utils/jwt.js.map +1 -1
  1293. package/utils/map.js +7 -15
  1294. package/utils/map.js.map +1 -1
  1295. package/utils/math.js +7 -17
  1296. package/utils/math.js.map +1 -1
  1297. package/utils/middleware.js +2 -7
  1298. package/utils/middleware.js.map +1 -1
  1299. package/utils/moving-metric.js +5 -9
  1300. package/utils/moving-metric.js.map +1 -1
  1301. package/utils/noop.js +1 -5
  1302. package/utils/noop.js.map +1 -1
  1303. package/utils/object/dereference.js +7 -13
  1304. package/utils/object/dereference.js.map +1 -1
  1305. package/utils/object/forward-ref.js +15 -19
  1306. package/utils/object/forward-ref.js.map +1 -1
  1307. package/utils/object/index.d.ts +6 -6
  1308. package/utils/object/index.js +6 -22
  1309. package/utils/object/index.js.map +1 -1
  1310. package/utils/object/lazy-property.d.ts +1 -1
  1311. package/utils/object/lazy-property.js +14 -21
  1312. package/utils/object/lazy-property.js.map +1 -1
  1313. package/utils/object/merge.js +13 -17
  1314. package/utils/object/merge.js.map +1 -1
  1315. package/utils/object/object.d.ts +1 -1
  1316. package/utils/object/object.js +18 -29
  1317. package/utils/object/object.js.map +1 -1
  1318. package/utils/object/property-name.d.ts +1 -1
  1319. package/utils/object/property-name.js +16 -25
  1320. package/utils/object/property-name.js.map +1 -1
  1321. package/utils/ordered-feedable-async-iterable.d.ts +1 -1
  1322. package/utils/ordered-feedable-async-iterable.js +3 -7
  1323. package/utils/ordered-feedable-async-iterable.js.map +1 -1
  1324. package/utils/patch-worker.d.ts +2 -2
  1325. package/utils/patch-worker.js +23 -29
  1326. package/utils/patch-worker.js.map +1 -1
  1327. package/utils/patterns.js +4 -8
  1328. package/utils/patterns.js.map +1 -1
  1329. package/utils/periodic-reporter.js +9 -13
  1330. package/utils/periodic-reporter.js.map +1 -1
  1331. package/utils/periodic-sampler.js +15 -19
  1332. package/utils/periodic-sampler.js.map +1 -1
  1333. package/utils/provider-function-iterable.js +14 -32
  1334. package/utils/provider-function-iterable.js.map +1 -1
  1335. package/utils/random.js +4 -9
  1336. package/utils/random.js.map +1 -1
  1337. package/utils/reflection.d.ts +1 -1
  1338. package/utils/reflection.js +7 -16
  1339. package/utils/reflection.js.map +1 -1
  1340. package/utils/set.js +7 -15
  1341. package/utils/set.js.map +1 -1
  1342. package/utils/singleton.js +3 -7
  1343. package/utils/singleton.js.map +1 -1
  1344. package/utils/sort.js +5 -12
  1345. package/utils/sort.js.map +1 -1
  1346. package/utils/stream/async-iterable-readable.d.ts +3 -3
  1347. package/utils/stream/async-iterable-readable.js +8 -13
  1348. package/utils/stream/async-iterable-readable.js.map +1 -1
  1349. package/utils/stream/async-writable-stream.d.ts +3 -3
  1350. package/utils/stream/async-writable-stream.js +3 -7
  1351. package/utils/stream/async-writable-stream.js.map +1 -1
  1352. package/utils/stream/index.d.ts +5 -5
  1353. package/utils/stream/index.js +5 -21
  1354. package/utils/stream/index.js.map +1 -1
  1355. package/utils/stream/stream-helper-types.d.ts +1 -1
  1356. package/utils/stream/stream-helper-types.js +1 -2
  1357. package/utils/stream/stream-reader.js +20 -51
  1358. package/utils/stream/stream-reader.js.map +1 -1
  1359. package/utils/stream/typed-readable.d.ts +2 -2
  1360. package/utils/stream/typed-readable.js +2 -5
  1361. package/utils/stream/typed-readable.js.map +1 -1
  1362. package/utils/timer.js +1 -5
  1363. package/utils/timer.js.map +1 -1
  1364. package/utils/timing.d.ts +1 -9
  1365. package/utils/timing.js +12 -23
  1366. package/utils/timing.js.map +1 -1
  1367. package/utils/type-guards.d.ts +1 -1
  1368. package/utils/type-guards.js +209 -422
  1369. package/utils/type-guards.js.map +1 -1
  1370. package/utils/type-of.js +4 -9
  1371. package/utils/type-of.js.map +1 -1
  1372. package/utils/units.js +51 -55
  1373. package/utils/units.js.map +1 -1
  1374. package/utils/url-builder.d.ts +1 -1
  1375. package/utils/url-builder.js +14 -31
  1376. package/utils/url-builder.js.map +1 -1
  1377. package/utils/z-base32.d.ts +1 -1
  1378. package/utils/z-base32.js +6 -11
  1379. package/utils/z-base32.js.map +1 -1
  1380. package/database/mongo/model/document.js +0 -75
  1381. package/database/mongo/model/document.js.map +0 -1
  1382. package/database/mongo/model/index.d.ts +0 -1
  1383. package/database/mongo/model/index.js +0 -18
  1384. package/database/mongo/model/index.js.map +0 -1
  1385. package/database/mongo/mongo-entity-repository.js.map +0 -1
  1386. package/database/mongo/simple-entity-repository.d.ts +0 -7
  1387. package/database/mongo/simple-entity-repository.js +0 -11
  1388. package/database/mongo/simple-entity-repository.js.map +0 -1
  1389. package/lock/mongo/mongo-lock-repository.js.map +0 -1
  1390. package/rxjs/compat/first-value-from.d.ts +0 -2
  1391. package/rxjs/compat/first-value-from.js +0 -9
  1392. package/rxjs/compat/first-value-from.js.map +0 -1
  1393. package/rxjs/compat/index.d.ts +0 -1
  1394. package/rxjs/compat/index.js +0 -18
  1395. package/rxjs/compat/index.js.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"compression.js","sourceRoot":"","sources":["../../source/utils/compression.ts"],"names":[],"mappings":";;;AAAA,6BAA6B;AAC7B,qCAAyD;AACzD,yCAA+D;AAC/D,yCAA2C;AAmB3C,SAAgB,cAAc,CAAC,KAAa,EAAE,SAAqB,EAAE,OAA+C;IAClH,MAAM,WAAW,GAAG,IAAA,qBAAU,EAAC,KAAK,CAAC,CAAC;IACtC,OAAO,QAAQ,CAAC,WAAW,EAAE,SAAS,EAAE,OAAO,CAAC,CAAC;AACnD,CAAC;AAHD,wCAGC;AAKD,SAAgB,QAAQ,CAAC,MAAsB,EAAE,SAAqB,EAAE,OAA+C;IACrH,MAAM,gBAAgB,GAAG,SAAS,CAAC,MAAM,EAAE,SAAS,EAAE,OAAO,CAAC,CAAC;IAE/D,OAAO;QACL,QAAQ,EAAE,KAAK,IAAI,EAAE,CAAC,gBAAgB;QACtC,KAAK,EAAE,KAAK,IAAI,EAAE,CAAC,IAAA,oBAAS,EAAC,MAAM,gBAAgB,CAAC;QACpD,QAAQ,EAAE,KAAK,IAAI,EAAE,CAAC,IAAA,qBAAY,EAAC,MAAM,gBAAgB,CAAC;QAC1D,WAAW,EAAE,KAAK,IAAI,EAAE,CAAC,IAAA,wBAAe,EAAC,MAAM,gBAAgB,CAAC;QAChE,SAAS,EAAE,KAAK,IAAI,EAAE,CAAC,IAAA,wBAAa,EAAC,MAAM,gBAAgB,CAAC;KAC7D,CAAC;AACJ,CAAC;AAVD,4BAUC;AAED,KAAK,UAAU,SAAS,CAAC,MAAsB,EAAE,SAAqB,EAAE,OAA+C;IACrH,OAAO,IAAI,OAAO,CAAa,CAAC,OAAO,EAAE,MAAM,EAAE,EAAE;QACjD,MAAM,UAAU,GACZ,SAAS,IAAI,MAAM,CAAC,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AAQ,GAA0B,CAAC,KAAK,EAAE,MAAM,EAAE,EAAE;YACxD,IAAI,KAAK,IAAI,SAAS,EAAE;gBACtB,MAAM,CAAC,KAAK,CAAC,CAAC;aACf;iBACI;gBACH,OAAO,CAAC,MAAM,CAAC,CAAC;aACjB;QACH,CAAC,CAAC;QAEF,IAAI,OAAO,IAAI,SAAS,EAAE;YACvB,YAAkF,CAAC,MAAM,EAAE,QAAQ,CAAC,CAAC;SACvG;aACI;YACF,YAAkI,CAAC,MAAM,EAAE,OAAO,EAAE,QAAQ,CAAC,CAAC;SAChK;IACH,CAAC,CAAC,CAAC;AACL,CAAC"}
@@ -1,34 +1,27 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.string = exports.positiveInteger = exports.integer = exports.boolean = exports.configValidators = void 0;
4
- const type_guards_1 = require("./type-guards");
5
- exports.configValidators = {
1
+ import { isUndefined } from './type-guards.js';
2
+ export const configValidators = {
6
3
  integer: /^-?\d+$/u,
7
4
  positiveInteger: /^[1-9]\d*$/u,
8
5
  boolean: /true|false|yes|no|0|1/ui
9
6
  };
10
- function boolean(variable, defaultValue) {
11
- return string(variable, defaultValue, exports.configValidators.boolean, (value) => ['true', 'yes', '1'].includes(value.toLowerCase()));
7
+ export function boolean(variable, defaultValue) {
8
+ return string(variable, defaultValue, configValidators.boolean, (value) => ['true', 'yes', '1'].includes(value.toLowerCase()));
12
9
  }
13
- exports.boolean = boolean;
14
- function integer(variable, defaultValue) {
15
- return string(variable, defaultValue, exports.configValidators.integer, (value) => parseInt(value, 10));
10
+ export function integer(variable, defaultValue) {
11
+ return string(variable, defaultValue, configValidators.integer, (value) => parseInt(value, 10));
16
12
  }
17
- exports.integer = integer;
18
- function positiveInteger(variable, defaultValue) {
19
- return string(variable, defaultValue, exports.configValidators.positiveInteger, (value) => parseInt(value, 10));
13
+ export function positiveInteger(variable, defaultValue) {
14
+ return string(variable, defaultValue, configValidators.positiveInteger, (value) => parseInt(value, 10));
20
15
  }
21
- exports.positiveInteger = positiveInteger;
22
- function string(variable, defaultValue, validator, transformer = (value) => value) {
16
+ export function string(variable, defaultValue, validator, transformer = (value) => value) {
23
17
  const environmentValue = process.env[variable];
24
- if ((0, type_guards_1.isUndefined)(environmentValue)) {
18
+ if (isUndefined(environmentValue)) {
25
19
  return defaultValue;
26
20
  }
27
- const valid = (0, type_guards_1.isUndefined)(validator) ? true : validator.test(environmentValue);
21
+ const valid = isUndefined(validator) ? true : validator.test(environmentValue);
28
22
  if (!valid) {
29
23
  throw new Error(`invalid value for ${variable}`);
30
24
  }
31
25
  return transformer(environmentValue);
32
26
  }
33
- exports.string = string;
34
27
  //# sourceMappingURL=config-parser.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"config-parser.js","sourceRoot":"","sources":["../../source/utils/config-parser.ts"],"names":[],"mappings":";;;AAAA,+CAA4C;AAE/B,QAAA,gBAAgB,GAAG;IAC9B,OAAO,EAAE,UAAU;IACnB,eAAe,EAAE,aAAa;IAC9B,OAAO,EAAE,yBAAyB;CACnC,CAAC;AAEF,SAAgB,OAAO,CAAI,QAAgB,EAAE,YAAe;IAC1D,OAAO,MAAM,CAAC,QAAQ,EAAE,YAAY,EAAE,wBAAgB,CAAC,OAAO,EAAE,CAAC,KAAK,EAAE,EAAE,CAAC,CAAC,MAAM,EAAE,KAAK,EAAE,GAAG,CAAC,CAAC,QAAQ,CAAC,KAAK,CAAC,WAAW,EAAE,CAAC,CAAC,CAAC;AACjI,CAAC;AAFD,0BAEC;AAED,SAAgB,OAAO,CAAI,QAAgB,EAAE,YAAe;IAC1D,OAAO,MAAM,CAAC,QAAQ,EAAE,YAAY,EAAE,wBAAgB,CAAC,OAAO,EAAE,CAAC,KAAK,EAAE,EAAE,CAAC,QAAQ,CAAC,KAAK,EAAE,EAAE,CAAC,CAAC,CAAC;AAClG,CAAC;AAFD,0BAEC;AAED,SAAgB,eAAe,CAAI,QAAgB,EAAE,YAAe;IAClE,OAAO,MAAM,CAAC,QAAQ,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AC;AACjI,CAAC;AAED,MAAM,UAAU,OAAO,CAAI,QAAgB,EAAE,YAAe;IAC1D,OAAO,MAAM,CAAC,QAAQ,EAAE,YAAY,EAAE,gBAAgB,CAAC,OAAO,EAAE,CAAC,KAAK,EAAE,EAAE,CAAC,QAAQ,CAAC,KAAK,EAAE,EAAE,CAAC,CAAC,CAAC;AAClG,CAAC;AAED,MAAM,UAAU,eAAe,CAAI,QAAgB,EAAE,YAAe;IAClE,OAAO,MAAM,CAAC,QAAQ,EAAE,YAAY,EAAE,gBAAgB,CAAC,eAAe,EAAE,CAAC,KAAK,EAAE,EAAE,CAAC,QAAQ,CAAC,KAAK,EAAE,EAAE,CAAC,CAAC,CAAC;AAC1G,CAAC;AAID,MAAM,UAAU,MAAM,CAAO,QAAgB,EAAE,YAAe,EAAE,SAAkB,EAAE,cAAoC,CAAC,KAAK,EAAE,EAAE,CAAC,KAAiB;IAClJ,MAAM,gBAAgB,GAAG,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAC;IAE/C,IAAI,WAAW,CAAC,gBAAgB,CAAC,EAAE;QACjC,OAAO,YAAY,CAAC;KACrB;IAED,MAAM,KAAK,GAAG,WAAW,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,SAAS,CAAC,IAAI,CAAC,gBAAgB,CAAC,CAAC;IAE/E,IAAI,CAAC,KAAK,EAAE;QACV,MAAM,IAAI,KAAK,CAAC,qBAAqB,QAAQ,EAAE,CAAC,CAAC;KAClD;IAED,OAAO,WAAW,CAAC,gBAAgB,CAAC,CAAC;AACvC,CAAC"}
@@ -1,4 +1,4 @@
1
- import type { BinaryData, TypedExtract } from "../types";
1
+ import type { BinaryData, TypedExtract } from "../types.js";
2
2
  export declare type AesMode = 'CBC' | 'CTR' | 'GCM' | 'KW';
3
3
  export declare type EcdsaCurve = 'P-256' | 'P-384' | 'P-521';
4
4
  export declare type HashAlgorithm = 'SHA-1' | 'SHA-256' | 'SHA-384' | 'SHA-512';
@@ -1,34 +1,30 @@
1
- "use strict";
2
- var _a;
3
- Object.defineProperty(exports, "__esModule", { value: true });
4
- exports.generatePbkdf2Key = exports.generateEcdsaKey = exports.importPbkdf2Key = exports.importEcdsaKey = exports.importSymmetricKey = exports.importHmacKey = exports.verify = exports.sign = exports.digest = exports.decrypt = exports.encrypt = exports.wrapKey = exports.unwrapKey = exports.importKey = exports.generateKey = exports.exportKey = exports.deriveKey = exports.deriveBits = void 0;
5
- const base64_1 = require("./base64");
6
- const encoding_1 = require("./encoding");
7
- const random_1 = require("./random");
8
- const type_guards_1 = require("./type-guards");
9
- const z_base32_1 = require("./z-base32");
1
+ import { encodeBase64, encodeBase64Url } from './base64.js';
2
+ import { decodeText, encodeHex, encodeUtf8 } from './encoding.js';
3
+ import { getRandomBytes } from './random.js';
4
+ import { isDefined, isString, isUndefined } from './type-guards.js';
5
+ import { zBase32Encode } from './z-base32.js';
10
6
  let subtle;
11
7
  try {
12
8
  // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition
13
- subtle = (_a = globalThis === null || globalThis === void 0 ? void 0 : globalThis.crypto) === null || _a === void 0 ? void 0 : _a.subtle;
14
- if ((0, type_guards_1.isUndefined)(subtle)) {
9
+ subtle = globalThis?.crypto?.subtle;
10
+ if (isUndefined(subtle)) {
15
11
  // eslint-disable-next-line no-eval
16
12
  subtle = eval('require(\'crypto\')').webcrypto.subtle;
17
13
  }
18
14
  }
19
15
  catch (error) {
20
- if ((0, type_guards_1.isUndefined)(subtle)) {
16
+ if (isUndefined(subtle)) {
21
17
  console.error('could not find SubtleCrypto implementation', error);
22
18
  }
23
19
  }
24
20
  /* eslint-disable */
25
- exports.deriveBits = subtle === null || subtle === void 0 ? void 0 : subtle.deriveBits.bind(subtle);
26
- exports.deriveKey = subtle === null || subtle === void 0 ? void 0 : subtle.deriveKey.bind(subtle);
27
- exports.exportKey = subtle === null || subtle === void 0 ? void 0 : subtle.exportKey.bind(subtle);
28
- exports.generateKey = subtle === null || subtle === void 0 ? void 0 : subtle.generateKey.bind(subtle);
29
- exports.importKey = subtle === null || subtle === void 0 ? void 0 : subtle.importKey.bind(subtle);
30
- exports.unwrapKey = subtle === null || subtle === void 0 ? void 0 : subtle.unwrapKey.bind(subtle);
31
- exports.wrapKey = subtle === null || subtle === void 0 ? void 0 : subtle.wrapKey.bind(subtle);
21
+ export const deriveBits = subtle?.deriveBits.bind(subtle);
22
+ export const deriveKey = subtle?.deriveKey.bind(subtle);
23
+ export const exportKey = subtle?.exportKey.bind(subtle);
24
+ export const generateKey = subtle?.generateKey.bind(subtle);
25
+ export const importKey = subtle?.importKey.bind(subtle);
26
+ export const unwrapKey = subtle?.unwrapKey.bind(subtle);
27
+ export const wrapKey = subtle?.wrapKey.bind(subtle);
32
28
  /* eslint-enable */
33
29
  /**
34
30
  * encrypt data
@@ -36,73 +32,69 @@ exports.wrapKey = subtle === null || subtle === void 0 ? void 0 : subtle.wrapKey
36
32
  * @param key key
37
33
  * @param data data to encrypt. Encodes string to utf8
38
34
  */
39
- function encrypt(algorithm, key, data) {
40
- const bytes = (0, type_guards_1.isString)(data) ? (0, encoding_1.encodeUtf8)(data) : data;
35
+ export function encrypt(algorithm, key, data) {
36
+ const bytes = isString(data) ? encodeUtf8(data) : data;
41
37
  const encryptedBuffer = subtle.encrypt(algorithm, key, bytes);
42
38
  return {
43
39
  toBuffer: async () => encryptedBuffer,
44
- toHex: async () => (0, encoding_1.encodeHex)(await encryptedBuffer),
45
- toBase64: async () => (0, base64_1.encodeBase64)(await encryptedBuffer),
46
- toBase64Url: async () => (0, base64_1.encodeBase64Url)(await encryptedBuffer),
47
- toZBase32: async () => (0, z_base32_1.zBase32Encode)(await encryptedBuffer)
40
+ toHex: async () => encodeHex(await encryptedBuffer),
41
+ toBase64: async () => encodeBase64(await encryptedBuffer),
42
+ toBase64Url: async () => encodeBase64Url(await encryptedBuffer),
43
+ toZBase32: async () => zBase32Encode(await encryptedBuffer)
48
44
  };
49
45
  }
50
- exports.encrypt = encrypt;
51
46
  /**
52
47
  * decrypt data
53
48
  * @param algorithm algorithm as supported by Web Crypto API
54
49
  * @param key key
55
50
  * @param data data to decrypt
56
51
  */
57
- function decrypt(algorithm, key, bytes) {
52
+ export function decrypt(algorithm, key, bytes) {
58
53
  const decryptedBuffer = subtle.decrypt(algorithm, key, bytes);
59
54
  return {
60
55
  toBuffer: async () => decryptedBuffer,
61
- toHex: async () => (0, encoding_1.encodeHex)(await decryptedBuffer),
62
- toBase64: async () => (0, base64_1.encodeBase64)(await decryptedBuffer),
63
- toBase64Url: async () => (0, base64_1.encodeBase64Url)(await decryptedBuffer),
64
- toZBase32: async () => (0, z_base32_1.zBase32Encode)(await decryptedBuffer),
65
- toUtf8: async () => (0, encoding_1.decodeText)(await decryptedBuffer)
56
+ toHex: async () => encodeHex(await decryptedBuffer),
57
+ toBase64: async () => encodeBase64(await decryptedBuffer),
58
+ toBase64Url: async () => encodeBase64Url(await decryptedBuffer),
59
+ toZBase32: async () => zBase32Encode(await decryptedBuffer),
60
+ toUtf8: async () => decodeText(await decryptedBuffer)
66
61
  };
67
62
  }
68
- exports.decrypt = decrypt;
69
63
  /**
70
64
  * hashes data
71
65
  * @param algorithm algorithm as supported by Web Crypto API
72
66
  * @param data data to encrypt. Encodes string to utf8
73
67
  */
74
- function digest(algorithm, data) {
75
- const bytes = (0, type_guards_1.isString)(data) ? (0, encoding_1.encodeUtf8)(data) : data;
68
+ export function digest(algorithm, data) {
69
+ const bytes = isString(data) ? encodeUtf8(data) : data;
76
70
  const arrayBufferPromise = subtle.digest(algorithm, bytes);
77
71
  const result = {
78
72
  toBuffer: async () => arrayBufferPromise,
79
- toHex: async () => (0, encoding_1.encodeHex)(await arrayBufferPromise),
80
- toBase64: async () => (0, base64_1.encodeBase64)(await arrayBufferPromise),
81
- toBase64Url: async () => (0, base64_1.encodeBase64Url)(await arrayBufferPromise),
82
- toZBase32: async () => (0, z_base32_1.zBase32Encode)(await arrayBufferPromise)
73
+ toHex: async () => encodeHex(await arrayBufferPromise),
74
+ toBase64: async () => encodeBase64(await arrayBufferPromise),
75
+ toBase64Url: async () => encodeBase64Url(await arrayBufferPromise),
76
+ toZBase32: async () => zBase32Encode(await arrayBufferPromise)
83
77
  };
84
78
  return result;
85
79
  }
86
- exports.digest = digest;
87
80
  /**
88
81
  * signs data
89
82
  * @param algorithm algorithm as supported by Web Crypto API
90
83
  * @param key key
91
84
  * @param data data to sign
92
85
  */
93
- function sign(algorithm, key, data) {
94
- const bytes = (0, type_guards_1.isString)(data) ? (0, encoding_1.encodeUtf8)(data) : data;
86
+ export function sign(algorithm, key, data) {
87
+ const bytes = isString(data) ? encodeUtf8(data) : data;
95
88
  const arrayBufferPromise = subtle.sign(algorithm, key, bytes);
96
89
  const result = {
97
90
  toBuffer: async () => arrayBufferPromise,
98
- toHex: async () => (0, encoding_1.encodeHex)(await arrayBufferPromise),
99
- toBase64: async () => (0, base64_1.encodeBase64)(await arrayBufferPromise),
100
- toBase64Url: async () => (0, base64_1.encodeBase64Url)(await arrayBufferPromise),
101
- toZBase32: async () => (0, z_base32_1.zBase32Encode)(await arrayBufferPromise)
91
+ toHex: async () => encodeHex(await arrayBufferPromise),
92
+ toBase64: async () => encodeBase64(await arrayBufferPromise),
93
+ toBase64Url: async () => encodeBase64Url(await arrayBufferPromise),
94
+ toZBase32: async () => zBase32Encode(await arrayBufferPromise)
102
95
  };
103
96
  return result;
104
97
  }
105
- exports.sign = sign;
106
98
  /**
107
99
  * verifies data
108
100
  * @param algorithm algorithm as supported by Web Crypto API
@@ -110,26 +102,24 @@ exports.sign = sign;
110
102
  * @param signature signature
111
103
  * @param data data to verify using provided signature
112
104
  */
113
- async function verify(algorithm, key, signature, data) {
114
- const signatureBytes = (0, type_guards_1.isString)(signature) ? (0, encoding_1.encodeUtf8)(signature) : signature;
115
- const dataBytes = (0, type_guards_1.isString)(data) ? (0, encoding_1.encodeUtf8)(data) : data;
105
+ export async function verify(algorithm, key, signature, data) {
106
+ const signatureBytes = isString(signature) ? encodeUtf8(signature) : signature;
107
+ const dataBytes = isString(data) ? encodeUtf8(data) : data;
116
108
  return subtle.verify(algorithm, key, signatureBytes, dataBytes);
117
109
  }
118
- exports.verify = verify;
119
110
  /**
120
111
  * imports a HMAC CryptoKey
121
112
  * @param algorithm hash algorithm
122
113
  * @param key JWK or binary key
123
114
  * @param extractable whether the key can be used for exportKey
124
115
  */
125
- async function importHmacKey(algorithm, key, extractable = false) {
126
- const _key = (0, type_guards_1.isString)(key) ? (0, encoding_1.encodeUtf8)(key) : key;
116
+ export async function importHmacKey(algorithm, key, extractable = false) {
117
+ const _key = isString(key) ? encodeUtf8(key) : key;
127
118
  if (isBinaryKey(_key)) {
128
119
  return subtle.importKey('raw', _key, { name: 'HMAC', hash: algorithm }, extractable, ['sign', 'verify']);
129
120
  }
130
121
  return subtle.importKey('jwk', _key, { name: 'HMAC', hash: algorithm }, extractable, ['sign', 'verify']);
131
122
  }
132
- exports.importHmacKey = importHmacKey;
133
123
  /**
134
124
  * imports a CryptoKey for symmetric encryption
135
125
  * @param algorithm symmetric algorithm
@@ -137,58 +127,53 @@ exports.importHmacKey = importHmacKey;
137
127
  * @param key JWK or binary key
138
128
  * @param extractable whether the key can be used for exportKey
139
129
  */
140
- async function importSymmetricKey(algorithm, length, key, extractable = false) {
141
- const _key = (0, type_guards_1.isString)(key) ? (0, encoding_1.encodeUtf8)(key) : key;
130
+ export async function importSymmetricKey(algorithm, length, key, extractable = false) {
131
+ const _key = isString(key) ? encodeUtf8(key) : key;
142
132
  if (isBinaryKey(_key)) {
143
133
  return subtle.importKey('raw', _key, { name: algorithm, length }, extractable, ['encrypt', 'decrypt']);
144
134
  }
145
135
  return subtle.importKey('jwk', _key, { name: algorithm, length }, extractable, ['encrypt', 'decrypt']);
146
136
  }
147
- exports.importSymmetricKey = importSymmetricKey;
148
137
  /**
149
138
  * imports an ECDSA CryptoKey
150
139
  * @param curve ECDSA curve
151
140
  * @param key JWK or DER encoded key
152
141
  * @param extractable whether the key can be used for exportKey
153
142
  */
154
- async function importEcdsaKey(curve, key, extractable = false) {
155
- const _key = (0, type_guards_1.isString)(key) ? (0, encoding_1.encodeUtf8)(key) : key;
143
+ export async function importEcdsaKey(curve, key, extractable = false) {
144
+ const _key = isString(key) ? encodeUtf8(key) : key;
156
145
  if (isBinaryKey(_key)) {
157
146
  return subtle.importKey('spki', _key, { name: 'ECDSA', namedCurve: curve }, extractable, ['verify']);
158
147
  }
159
148
  return subtle.importKey('jwk', _key, { name: 'ECDSA', namedCurve: curve }, extractable, ['verify']);
160
149
  }
161
- exports.importEcdsaKey = importEcdsaKey;
162
150
  /**
163
151
  * import a pbkdf2 CryptoKey
164
152
  * @param key binary key
165
153
  * @param extractable whether the key can be used for exportKey
166
154
  */
167
- async function importPbkdf2Key(key, extractable = false) {
168
- const _key = (0, type_guards_1.isString)(key) ? (0, encoding_1.encodeUtf8)(key) : key;
155
+ export async function importPbkdf2Key(key, extractable = false) {
156
+ const _key = isString(key) ? encodeUtf8(key) : key;
169
157
  return subtle.importKey('raw', _key, { name: 'PBKDF2' }, extractable, ['deriveKey', 'deriveBits']);
170
158
  }
171
- exports.importPbkdf2Key = importPbkdf2Key;
172
159
  /**
173
160
  * generates a new ECDSA CryptoKeyPair
174
161
  * @param curve ECDSA cruve to use
175
162
  * @param extractable whether the key can be used for exportKey
176
163
  * @param usages whether to generate a key for signing, verifiying or both. Defaults to both
177
164
  */
178
- async function generateEcdsaKey(curve, extractable = false, usages = ['sign', 'verify']) {
165
+ export async function generateEcdsaKey(curve, extractable = false, usages = ['sign', 'verify']) {
179
166
  return subtle.generateKey({ name: 'ECDSA', namedCurve: curve }, extractable, usages);
180
167
  }
181
- exports.generateEcdsaKey = generateEcdsaKey;
182
168
  /**
183
169
  * generates a pbkdf2 CryptoKey
184
170
  * @param extractable whether the key can be used for exportKey
185
171
  */
186
- async function generatePbkdf2Key(extractable = false) {
187
- const key = (0, random_1.getRandomBytes)(16);
172
+ export async function generatePbkdf2Key(extractable = false) {
173
+ const key = getRandomBytes(16);
188
174
  return importPbkdf2Key(key, extractable);
189
175
  }
190
- exports.generatePbkdf2Key = generatePbkdf2Key;
191
176
  function isBinaryKey(key) {
192
- return (0, type_guards_1.isDefined)(key.byteLength);
177
+ return isDefined(key.byteLength);
193
178
  }
194
179
  //# sourceMappingURL=cryptography.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"cryptography.js","sourceRoot":"","sources":["../../source/utils/cryptography.ts"],"names":[],"mappings":";;;;AAEA,qCAAyD;AACzD,yCAA+D;AAC/D,qCAA0C;AAC1C,+CAAiE;AACjE,yCAA2C;AAsC3C,IAAI,MAAoB,CAAC;AAEzB,IAAI;IACF,uEAAuE;IACvE,MAAM,GAAG,MAAA,UAAU,aAAV,UAAU,uBAAV,UAAU,CAAE,MAAM,0CAAE,MAAM,CAAC;IAEpC,IAAI,IAAA,yBAAW,EAAC,MAAM,CAAC,EAAE;QACvB,mCAAmC;QACnC,MAAM,GAAK,IAAI,CAAC,qBAAqB,CAAuB,CAAC,SAA6C,CAAC,MAAM,CAAC;KACnH;CACF;AACD,OAAO,KAAc,EAAE;IACrB,IAAI,IAAA,yBAAW,EAAC,MAAO,CAAC,EAAE;QACxB,OAAO,CAAC,KAAK,CAAC,4CAA4C,EAAE,KAAK,CAAC,CAAC;KACpE;CACF;AAED,oBAAoB;AACP,QAAA,UAAU,GAAI,MAAoC,aAApC,MAAM,uBAAN,MAAM,CAAgC,UAAU,CAAC,IAAI,CAAC,MAAO,CAAE,CAAC;AAC9E,QAAA,SAAS,GAAI,MAAoC,aAApC,MAAM,uBAAN,MAAM,CAAgC,SAAS,CAAC,IAAI,CAAC,MAAO,CAAE,CAAC;AAC5E,QAAA,SAAS,GAAI,MAAoC,aAApC,MAAM,uBAAN,MAAM,CAAgC,SAAS,CAAC,IAAI,CAAC,MAAO,CAAE,CAAC;AAC5E,QAAA,WAAW,GAAI,MAAoC,aAApC,MAAM,uBAAN,MAAM,CAAgC,WAAW,CAAC,IAAI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QAAQ,CAAC;IAC9J,OAAO,MAAM,CAAC,WAAW,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,UAAU,EAAE,KAAK,EAAE,EAAE,WAAW,EAAE,MAAM,CAAC,CAAC;AACvF,CAAC;AAED;;;GAGG;AACH,MAAM,CAAC,KAAK,UAAU,iBAAiB,CAAC,cAAuB,KAAK;IAClE,MAAM,GAAG,GAAG,cAAc,CAAC,EAAE,CAAC,CAAC;IAC/B,OAAO,eAAe,CAAC,GAAG,EAAE,WAAW,CAAC,CAAC;AAC3C,CAAC;AAED,SAAS,WAAW,CAAC,GAAQ;IAC3B,OAAO,SAAS,CAAE,GAAkB,CAAC,UAAU,CAAC,CAAC;AACnD,CAAC"}
@@ -1,72 +1,56 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.numericDateTimeToDateTime = exports.dateTimeToTime = exports.numericDateToDateTime = exports.dateTimeToNumericDate = exports.zonedDateObjectToDateTime = exports.numericDateTimeToTimestamp = exports.numericDateToDate = exports.numericDateToTimestamp = exports.timestampToNumericDateAndTime = exports.numericTimeToTimeObject = exports.timeObjectToNumericTime = exports.timestampToTime = exports.dateToNumericDate = exports.timestampToNumericDate = exports.currentTime = exports.currentDate = exports.currentTimestampSeconds = exports.currentTimestamp = exports.now = void 0;
4
- const luxon_1 = require("luxon");
5
- const units_1 = require("./units");
6
- function now() {
1
+ import { DateTime } from 'luxon';
2
+ import { millisecondsPerDay, millisecondsPerHour, millisecondsPerMinute, millisecondsPerSecond } from './units.js';
3
+ export function now() {
7
4
  return new Date();
8
5
  }
9
- exports.now = now;
10
- function currentTimestamp() {
6
+ export function currentTimestamp() {
11
7
  return Date.now();
12
8
  }
13
- exports.currentTimestamp = currentTimestamp;
14
- function currentTimestampSeconds() {
9
+ export function currentTimestampSeconds() {
15
10
  return Math.floor(Date.now() / 1000);
16
11
  }
17
- exports.currentTimestampSeconds = currentTimestampSeconds;
18
- function currentDate() {
12
+ export function currentDate() {
19
13
  const timestamp = currentTimestamp();
20
14
  return timestampToNumericDate(timestamp);
21
15
  }
22
- exports.currentDate = currentDate;
23
- function currentTime() {
16
+ export function currentTime() {
24
17
  const timestamp = currentTimestamp();
25
18
  return timestampToTime(timestamp);
26
19
  }
27
- exports.currentTime = currentTime;
28
- function timestampToNumericDate(timestamp) {
29
- return Math.floor(timestamp / units_1.millisecondsPerDay);
20
+ export function timestampToNumericDate(timestamp) {
21
+ return Math.floor(timestamp / millisecondsPerDay);
30
22
  }
31
- exports.timestampToNumericDate = timestampToNumericDate;
32
- function dateToNumericDate(date) {
23
+ export function dateToNumericDate(date) {
33
24
  const timestamp = Date.UTC(date.getFullYear(), date.getMonth(), date.getDate());
34
25
  return timestampToNumericDate(timestamp);
35
26
  }
36
- exports.dateToNumericDate = dateToNumericDate;
37
- function timestampToTime(timestamp) {
38
- return timestamp % units_1.millisecondsPerDay;
27
+ export function timestampToTime(timestamp) {
28
+ return timestamp % millisecondsPerDay;
39
29
  }
40
- exports.timestampToTime = timestampToTime;
41
- function timeObjectToNumericTime(time) {
42
- var _a, _b, _c, _d;
43
- return (((_a = time.hour) !== null && _a !== void 0 ? _a : 0) * units_1.millisecondsPerHour)
44
- + (((_b = time.minute) !== null && _b !== void 0 ? _b : 0) * units_1.millisecondsPerMinute)
45
- + (((_c = time.second) !== null && _c !== void 0 ? _c : 0) * units_1.millisecondsPerSecond)
46
- + ((_d = time.millisecond) !== null && _d !== void 0 ? _d : 0);
30
+ export function timeObjectToNumericTime(time) {
31
+ return ((time.hour ?? 0) * millisecondsPerHour)
32
+ + ((time.minute ?? 0) * millisecondsPerMinute)
33
+ + ((time.second ?? 0) * millisecondsPerSecond)
34
+ + (time.millisecond ?? 0);
47
35
  }
48
- exports.timeObjectToNumericTime = timeObjectToNumericTime;
49
- function numericTimeToTimeObject(time) {
36
+ export function numericTimeToTimeObject(time) {
50
37
  return {
51
- hour: Math.floor(time / units_1.millisecondsPerHour),
52
- minute: Math.floor((time % units_1.millisecondsPerHour) / units_1.millisecondsPerMinute),
53
- second: Math.floor((time % units_1.millisecondsPerMinute) / units_1.millisecondsPerSecond),
54
- millisecond: Math.floor(time % units_1.millisecondsPerSecond)
38
+ hour: Math.floor(time / millisecondsPerHour),
39
+ minute: Math.floor((time % millisecondsPerHour) / millisecondsPerMinute),
40
+ second: Math.floor((time % millisecondsPerMinute) / millisecondsPerSecond),
41
+ millisecond: Math.floor(time % millisecondsPerSecond)
55
42
  };
56
43
  }
57
- exports.numericTimeToTimeObject = numericTimeToTimeObject;
58
- function timestampToNumericDateAndTime(timestamp) {
44
+ export function timestampToNumericDateAndTime(timestamp) {
59
45
  return {
60
46
  date: timestampToNumericDate(timestamp),
61
47
  time: timestampToTime(timestamp)
62
48
  };
63
49
  }
64
- exports.timestampToNumericDateAndTime = timestampToNumericDateAndTime;
65
- function numericDateToTimestamp(numericDate) {
66
- return numericDate * units_1.millisecondsPerDay;
50
+ export function numericDateToTimestamp(numericDate) {
51
+ return numericDate * millisecondsPerDay;
67
52
  }
68
- exports.numericDateToTimestamp = numericDateToTimestamp;
69
- function numericDateToDate(numericDate) {
53
+ export function numericDateToDate(numericDate) {
70
54
  const timestamp = numericDateToTimestamp(numericDate);
71
55
  const date = new Date(timestamp);
72
56
  return {
@@ -75,31 +59,24 @@ function numericDateToDate(numericDate) {
75
59
  day: date.getUTCDate()
76
60
  };
77
61
  }
78
- exports.numericDateToDate = numericDateToDate;
79
- function numericDateTimeToTimestamp({ date, time }) {
62
+ export function numericDateTimeToTimestamp({ date, time }) {
80
63
  return numericDateToTimestamp(date) + time;
81
64
  }
82
- exports.numericDateTimeToTimestamp = numericDateTimeToTimestamp;
83
- function zonedDateObjectToDateTime(zonedDate, units, options) {
84
- return luxon_1.DateTime.fromObject(Object.assign(Object.assign({}, zonedDate), units), options);
65
+ export function zonedDateObjectToDateTime(zonedDate, units, options) {
66
+ return DateTime.fromObject({ ...zonedDate, ...units }, options);
85
67
  }
86
- exports.zonedDateObjectToDateTime = zonedDateObjectToDateTime;
87
- function dateTimeToNumericDate(dateTime) {
68
+ export function dateTimeToNumericDate(dateTime) {
88
69
  const timestamp = dateTime.toUTC(undefined, { keepLocalTime: true }).toMillis();
89
70
  return timestampToNumericDate(timestamp);
90
71
  }
91
- exports.dateTimeToNumericDate = dateTimeToNumericDate;
92
- function numericDateToDateTime(numericDate, units, options) {
72
+ export function numericDateToDateTime(numericDate, units, options) {
93
73
  const date = numericDateToDate(numericDate);
94
- return luxon_1.DateTime.fromObject(Object.assign(Object.assign({}, date), units), options);
74
+ return DateTime.fromObject({ ...date, ...units }, options);
95
75
  }
96
- exports.numericDateToDateTime = numericDateToDateTime;
97
- function dateTimeToTime(dateTime) {
76
+ export function dateTimeToTime(dateTime) {
98
77
  return dateTime.startOf('day').until(dateTime).count('milliseconds');
99
78
  }
100
- exports.dateTimeToTime = dateTimeToTime;
101
- function numericDateTimeToDateTime({ date, time }, zone) {
79
+ export function numericDateTimeToDateTime({ date, time }, zone) {
102
80
  return numericDateToDateTime(date, undefined, { zone }).set({ millisecond: time });
103
81
  }
104
- exports.numericDateTimeToDateTime = numericDateTimeToDateTime;
105
82
  //# sourceMappingURL=date-time.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"date-time.js","sourceRoot":"","sources":["../../source/utils/date-time.ts"],"names":[],"mappings":";;;AACA,iCAAiC;AACjC,mCAAgH;AAkChH,SAAgB,GAAG;IACjB,OAAO,IAAI,IAAI,EAAE,CAAC;AACpB,CAAC;AAFD,kBAEC;AAED,SAAgB,gBAAgB;IAC9B,OAAO,IAAI,CAAC,GAAG,EAAE,CAAC;AACpB,CAAC;AAFD,4CAEC;AAED,SAAgB,uBAAuB;IACrC,OAAO,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,GAAG,EAAE,GAAG,IAAI,CAAC,CAAC;AACvC,CAAC;AAFD,0DAEC;AAED,SAAgB,WAAW;IACzB,MAAM,SAAS,GAAG,gBAAgB,EAAE,CAAC;IACrC,OAAO,sBAAsB,CAAC,SAAS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CAAC,CAAC,QAAQ,EAAE,CAAC;IAChF,OAAO,sBAAsB,CAAC,SAAS,CAAC,CAAC;AAC3C,CAAC;AAED,MAAM,UAAU,qBAAqB,CAAC,WAAmB,EAAE,KAAuB,EAAE,OAA2B;IAC7G,MAAM,IAAI,GAAG,iBAAiB,CAAC,WAAW,CAAC,CAAC;IAC5C,OAAO,QAAQ,CAAC,UAAU,CAAC,EAAE,GAAG,IAAI,EAAE,GAAG,KAAK,EAAE,EAAE,OAAO,CAAC,CAAC;AAC7D,CAAC;AAED,MAAM,UAAU,cAAc,CAAC,QAAkB;IAC/C,OAAO,QAAQ,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC,KAAK,CAAC,QAAQ,CAAC,CAAC,KAAK,CAAC,cAAc,CAAC,CAAC;AACvE,CAAC;AAED,MAAM,UAAU,yBAAyB,CAAC,EAAE,IAAI,EAAE,IAAI,EAAmB,EAAE,IAAa;IACtF,OAAO,qBAAqB,CAAC,IAAI,EAAE,SAAS,EAAE,EAAE,IAAI,EAAE,CAAC,CAAC,GAAG,CAAC,EAAE,WAAW,EAAE,IAAI,EAAE,CAAC,CAAC;AACrF,CAAC"}
@@ -1,4 +1,4 @@
1
- import type { BinaryData } from "../types";
1
+ import type { BinaryData } from "../types.js";
2
2
  /**
3
3
  * encodes text to utf8
4
4
  * @param text text to encode
package/utils/encoding.js CHANGED
@@ -1,40 +1,35 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.decodeHex = exports.encodeHex = exports.decodeText = exports.encodeUtf8 = void 0;
4
- const error_1 = require("../error");
5
- const array_1 = require("./array");
6
- const binary_1 = require("./binary");
7
- const type_guards_1 = require("./type-guards");
8
- const byteToHex = (0, array_1.createArray)(2 ** 8, (i) => i).map((value) => value.toString(16).padStart(2, '0'));
1
+ import { AssertionError } from "../error/assertion.error.js";
2
+ import { createArray } from './array/array.js';
3
+ import { toUint8Array } from './binary.js';
4
+ import { isUndefined } from './type-guards.js';
5
+ const byteToHex = createArray(2 ** 8, (i) => i).map((value) => value.toString(16).padStart(2, '0'));
9
6
  const hexToByte = new Map(byteToHex.map((hex, value) => [hex, value]));
10
7
  /**
11
8
  * encodes text to utf8
12
9
  * @param text text to encode
13
10
  * @returns utf8 encoded text
14
11
  */
15
- function encodeUtf8(text) {
12
+ export function encodeUtf8(text) {
16
13
  const encoder = new TextEncoder();
17
14
  return encoder.encode(text);
18
15
  }
19
- exports.encodeUtf8 = encodeUtf8;
20
16
  /**
21
17
  * decodes buffer to string
22
18
  * @param buffer buffer to decode
23
19
  * @param encoding encoding, defaults to utf8
24
20
  * @returns decoded string
25
21
  */
26
- function decodeText(buffer, encoding) {
22
+ export function decodeText(buffer, encoding) {
27
23
  const decoder = new TextDecoder(encoding, { fatal: true });
28
24
  return decoder.decode(buffer);
29
25
  }
30
- exports.decodeText = decodeText;
31
26
  /**
32
27
  * encodes buffer to hex
33
28
  * @param buffer buffer to encode
34
29
  * @returns hex encoded string
35
30
  */
36
- function encodeHex(buffer) {
37
- const bytes = (0, binary_1.toUint8Array)(buffer);
31
+ export function encodeHex(buffer) {
32
+ const bytes = toUint8Array(buffer);
38
33
  let result = '';
39
34
  // eslint-disable-next-line @typescript-eslint/prefer-for-of
40
35
  for (let i = 0; i < bytes.length; i++) {
@@ -42,23 +37,21 @@ function encodeHex(buffer) {
42
37
  }
43
38
  return result;
44
39
  }
45
- exports.encodeHex = encodeHex;
46
40
  /**
47
41
  * decodes hex string to buffer
48
42
  * @param hex hex string to decode
49
43
  * @returns decoded buffer
50
44
  */
51
- function decodeHex(hex) {
45
+ export function decodeHex(hex) {
52
46
  const bytes = new Uint8Array(hex.length / 2);
53
47
  for (let i = 0; i < hex.length; i += 2) {
54
48
  const hexPart = hex.substring(i, i + 2);
55
49
  const byte = hexToByte.get(hexPart);
56
- if ((0, type_guards_1.isUndefined)(byte)) {
57
- throw new error_1.AssertionError(`invalid hex string at position ${i}`);
50
+ if (isUndefined(byte)) {
51
+ throw new AssertionError(`invalid hex string at position ${i}`);
58
52
  }
59
53
  bytes[i / 2] = byte;
60
54
  }
61
55
  return bytes;
62
56
  }
63
- exports.decodeHex = decodeHex;
64
57
  //# sourceMappingURL=encoding.js.map