@warlock.js/notifications 4.16.0 → 5.0.0

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 (337) hide show
  1. package/CHANGELOG.md +6 -0
  2. package/cjs/channel_api-CH3DxhRU.cjs +7463 -0
  3. package/cjs/channel_api-CH3DxhRU.cjs.map +1 -0
  4. package/cjs/chunk-fl3r8ClO.cjs +41 -0
  5. package/cjs/index.cjs +1 -1
  6. package/cjs/index.cjs.map +1 -1
  7. package/cjs/rabbitmq-driver-CJtyxjUQ.cjs +3 -0
  8. package/cjs/src-Cus6pYPC.cjs +10981 -0
  9. package/cjs/src-Cus6pYPC.cjs.map +1 -0
  10. package/esm/_virtual/_rolldown/runtime.mjs +32 -0
  11. package/esm/herald/src/communicators/broker-registry.mjs +204 -0
  12. package/esm/herald/src/communicators/broker-registry.mjs.map +1 -0
  13. package/esm/herald/src/communicators/broker.mjs +110 -0
  14. package/esm/herald/src/communicators/broker.mjs.map +1 -0
  15. package/esm/herald/src/communicators/index.mjs +4 -0
  16. package/esm/herald/src/decorators/consumable.mjs +36 -0
  17. package/esm/herald/src/decorators/consumable.mjs.map +1 -0
  18. package/esm/herald/src/decorators/index.mjs +3 -0
  19. package/esm/herald/src/drivers/index.mjs +5 -0
  20. package/esm/herald/src/drivers/rabbitmq/index.mjs +4 -0
  21. package/esm/herald/src/drivers/rabbitmq/rabbitmq-channel.mjs +403 -0
  22. package/esm/herald/src/drivers/rabbitmq/rabbitmq-channel.mjs.map +1 -0
  23. package/esm/herald/src/drivers/rabbitmq/rabbitmq-driver.mjs +303 -0
  24. package/esm/herald/src/drivers/rabbitmq/rabbitmq-driver.mjs.map +1 -0
  25. package/esm/herald/src/index.mjs +16 -0
  26. package/esm/herald/src/message-managers/event-consumer.mjs +76 -0
  27. package/esm/herald/src/message-managers/event-consumer.mjs.map +1 -0
  28. package/esm/herald/src/message-managers/event-message.mjs +85 -0
  29. package/esm/herald/src/message-managers/event-message.mjs.map +1 -0
  30. package/esm/herald/src/message-managers/index.mjs +4 -0
  31. package/esm/herald/src/message-managers/prepare-consumer-subscription.mjs +42 -0
  32. package/esm/herald/src/message-managers/prepare-consumer-subscription.mjs.map +1 -0
  33. package/esm/herald/src/use-case-broadcast.mjs +30 -0
  34. package/esm/herald/src/use-case-broadcast.mjs.map +1 -0
  35. package/esm/herald/src/utils/connect-to-broker.mjs +168 -0
  36. package/esm/herald/src/utils/connect-to-broker.mjs.map +1 -0
  37. package/esm/herald/src/utils/index.mjs +3 -0
  38. package/esm/in-app/in-app.d.mts +3 -3
  39. package/esm/in-app/in-app.d.mts.map +1 -1
  40. package/esm/node_modules/@mongez/reinforcements/esm/Random/_internal.mjs +6 -0
  41. package/esm/node_modules/@mongez/reinforcements/esm/Random/_internal.mjs.map +1 -0
  42. package/esm/node_modules/@mongez/reinforcements/esm/Random/bool.mjs +3 -0
  43. package/esm/node_modules/@mongez/reinforcements/esm/Random/color.mjs +3 -0
  44. package/esm/node_modules/@mongez/reinforcements/esm/Random/date.mjs +3 -0
  45. package/esm/node_modules/@mongez/reinforcements/esm/Random/float.mjs +3 -0
  46. package/esm/node_modules/@mongez/reinforcements/esm/Random/id.mjs +3 -0
  47. package/esm/node_modules/@mongez/reinforcements/esm/Random/int.mjs +3 -0
  48. package/esm/node_modules/@mongez/reinforcements/esm/Random/nanoid.mjs +3 -0
  49. package/esm/node_modules/@mongez/reinforcements/esm/Random/pick.mjs +3 -0
  50. package/esm/node_modules/@mongez/reinforcements/esm/Random/random.mjs +16 -0
  51. package/esm/node_modules/@mongez/reinforcements/esm/Random/sample.mjs +3 -0
  52. package/esm/node_modules/@mongez/reinforcements/esm/Random/string.mjs +3 -0
  53. package/esm/node_modules/@mongez/reinforcements/esm/Random/token.mjs +3 -0
  54. package/esm/node_modules/@mongez/reinforcements/esm/Random/uuid.mjs +3 -0
  55. package/esm/node_modules/@mongez/reinforcements/esm/Random/weighted.mjs +3 -0
  56. package/esm/node_modules/@mongez/reinforcements/esm/async/retry.mjs +3 -0
  57. package/esm/node_modules/@mongez/reinforcements/esm/index.mjs +24 -0
  58. package/esm/node_modules/@mongez/reinforcements/esm/mixed/clone/clone.mjs +82 -0
  59. package/esm/node_modules/@mongez/reinforcements/esm/mixed/clone/clone.mjs.map +1 -0
  60. package/esm/node_modules/@mongez/reinforcements/esm/number/round.mjs +17 -0
  61. package/esm/node_modules/@mongez/reinforcements/esm/number/round.mjs.map +1 -0
  62. package/esm/node_modules/@mongez/reinforcements/esm/object/except.mjs +13 -0
  63. package/esm/node_modules/@mongez/reinforcements/esm/object/except.mjs.map +1 -0
  64. package/esm/node_modules/@mongez/reinforcements/esm/object/get.mjs +18 -0
  65. package/esm/node_modules/@mongez/reinforcements/esm/object/get.mjs.map +1 -0
  66. package/esm/node_modules/@mongez/reinforcements/esm/object/omit.mjs +17 -0
  67. package/esm/node_modules/@mongez/reinforcements/esm/object/omit.mjs.map +1 -0
  68. package/esm/node_modules/@mongez/reinforcements/esm/object/unset.mjs +30 -0
  69. package/esm/node_modules/@mongez/reinforcements/esm/object/unset.mjs.map +1 -0
  70. package/esm/node_modules/@mongez/reinforcements/esm/string/capitalize.mjs +19 -0
  71. package/esm/node_modules/@mongez/reinforcements/esm/string/capitalize.mjs.map +1 -0
  72. package/esm/node_modules/@mongez/reinforcements/esm/string/ltrim.mjs +18 -0
  73. package/esm/node_modules/@mongez/reinforcements/esm/string/ltrim.mjs.map +1 -0
  74. package/esm/node_modules/@mongez/reinforcements/esm/string/readMoreChars.mjs +14 -0
  75. package/esm/node_modules/@mongez/reinforcements/esm/string/readMoreChars.mjs.map +1 -0
  76. package/esm/node_modules/@mongez/reinforcements/esm/string/rtrim.mjs +18 -0
  77. package/esm/node_modules/@mongez/reinforcements/esm/string/rtrim.mjs.map +1 -0
  78. package/esm/node_modules/@mongez/reinforcements/esm/string/toCamelCase.mjs +22 -0
  79. package/esm/node_modules/@mongez/reinforcements/esm/string/toCamelCase.mjs.map +1 -0
  80. package/esm/node_modules/@mongez/reinforcements/esm/string/toKebabCase.mjs +17 -0
  81. package/esm/node_modules/@mongez/reinforcements/esm/string/toKebabCase.mjs.map +1 -0
  82. package/esm/node_modules/@mongez/reinforcements/esm/string/toSnakeCase.mjs +21 -0
  83. package/esm/node_modules/@mongez/reinforcements/esm/string/toSnakeCase.mjs.map +1 -0
  84. package/esm/node_modules/@mongez/reinforcements/esm/string/toStudlyCase.mjs +21 -0
  85. package/esm/node_modules/@mongez/reinforcements/esm/string/toStudlyCase.mjs.map +1 -0
  86. package/esm/node_modules/@mongez/reinforcements/esm/string/trim.mjs +20 -0
  87. package/esm/node_modules/@mongez/reinforcements/esm/string/trim.mjs.map +1 -0
  88. package/esm/node_modules/@mongez/reinforcements/esm/string/ucfirst.mjs +15 -0
  89. package/esm/node_modules/@mongez/reinforcements/esm/string/ucfirst.mjs.map +1 -0
  90. package/esm/node_modules/@mongez/reinforcements/esm/string/words.mjs +25 -0
  91. package/esm/node_modules/@mongez/reinforcements/esm/string/words.mjs.map +1 -0
  92. package/esm/node_modules/@mongez/reinforcements/esm/utils/escapeRegex.mjs +11 -0
  93. package/esm/node_modules/@mongez/reinforcements/esm/utils/escapeRegex.mjs.map +1 -0
  94. package/esm/node_modules/@mongez/reinforcements/esm/utils/lazy.mjs +100 -0
  95. package/esm/node_modules/@mongez/reinforcements/esm/utils/lazy.mjs.map +1 -0
  96. package/esm/node_modules/@mongez/reinforcements/esm/utils/tap.mjs +27 -0
  97. package/esm/node_modules/@mongez/reinforcements/esm/utils/tap.mjs.map +1 -0
  98. package/esm/node_modules/@mongez/supportive-is/esm/index.mjs +353 -0
  99. package/esm/node_modules/@mongez/supportive-is/esm/index.mjs.map +1 -0
  100. package/esm/node_modules/amqplib/channel_api.mjs +28 -0
  101. package/esm/node_modules/amqplib/channel_api.mjs.map +1 -0
  102. package/esm/node_modules/amqplib/lib/api_args.mjs +241 -0
  103. package/esm/node_modules/amqplib/lib/api_args.mjs.map +1 -0
  104. package/esm/node_modules/amqplib/lib/bitset.mjs +130 -0
  105. package/esm/node_modules/amqplib/lib/bitset.mjs.map +1 -0
  106. package/esm/node_modules/amqplib/lib/channel.mjs +302 -0
  107. package/esm/node_modules/amqplib/lib/channel.mjs.map +1 -0
  108. package/esm/node_modules/amqplib/lib/channel_model.mjs +206 -0
  109. package/esm/node_modules/amqplib/lib/channel_model.mjs.map +1 -0
  110. package/esm/node_modules/amqplib/lib/codec.mjs +273 -0
  111. package/esm/node_modules/amqplib/lib/codec.mjs.map +1 -0
  112. package/esm/node_modules/amqplib/lib/connect.mjs +143 -0
  113. package/esm/node_modules/amqplib/lib/connect.mjs.map +1 -0
  114. package/esm/node_modules/amqplib/lib/connection.mjs +416 -0
  115. package/esm/node_modules/amqplib/lib/connection.mjs.map +1 -0
  116. package/esm/node_modules/amqplib/lib/credentials.mjs +50 -0
  117. package/esm/node_modules/amqplib/lib/credentials.mjs.map +1 -0
  118. package/esm/node_modules/amqplib/lib/defs.mjs +4600 -0
  119. package/esm/node_modules/amqplib/lib/defs.mjs.map +1 -0
  120. package/esm/node_modules/amqplib/lib/error.mjs +29 -0
  121. package/esm/node_modules/amqplib/lib/error.mjs.map +1 -0
  122. package/esm/node_modules/amqplib/lib/format.mjs +28 -0
  123. package/esm/node_modules/amqplib/lib/format.mjs.map +1 -0
  124. package/esm/node_modules/amqplib/lib/frame.mjs +130 -0
  125. package/esm/node_modules/amqplib/lib/frame.mjs.map +1 -0
  126. package/esm/node_modules/amqplib/lib/heartbeat.mjs +40 -0
  127. package/esm/node_modules/amqplib/lib/heartbeat.mjs.map +1 -0
  128. package/esm/node_modules/amqplib/lib/mux.mjs +86 -0
  129. package/esm/node_modules/amqplib/lib/mux.mjs.map +1 -0
  130. package/esm/node_modules/amqplib/package.mjs +41 -0
  131. package/esm/node_modules/amqplib/package.mjs.map +1 -0
  132. package/esm/node_modules/buffer-more-ints/buffer-more-ints.mjs +360 -0
  133. package/esm/node_modules/buffer-more-ints/buffer-more-ints.mjs.map +1 -0
  134. package/esm/node_modules/dayjs/dayjs.min.mjs +305 -0
  135. package/esm/node_modules/dayjs/dayjs.min.mjs.map +1 -0
  136. package/esm/node_modules/querystringify/index.mjs +80 -0
  137. package/esm/node_modules/querystringify/index.mjs.map +1 -0
  138. package/esm/node_modules/requires-port/index.mjs +35 -0
  139. package/esm/node_modules/requires-port/index.mjs.map +1 -0
  140. package/esm/node_modules/url-parse/index.mjs +388 -0
  141. package/esm/node_modules/url-parse/index.mjs.map +1 -0
  142. package/esm/queue/load-herald.mjs +1 -1
  143. package/esm/seal/src/config.mjs +15 -0
  144. package/esm/seal/src/config.mjs.map +1 -0
  145. package/esm/seal/src/factory/index.mjs +4 -0
  146. package/esm/seal/src/factory/validate.mjs +34 -0
  147. package/esm/seal/src/factory/validate.mjs.map +1 -0
  148. package/esm/seal/src/factory/validators.mjs +132 -0
  149. package/esm/seal/src/factory/validators.mjs.map +1 -0
  150. package/esm/seal/src/helpers/date-helpers.mjs +24 -0
  151. package/esm/seal/src/helpers/date-helpers.mjs.map +1 -0
  152. package/esm/seal/src/helpers/get-field-value.mjs +46 -0
  153. package/esm/seal/src/helpers/get-field-value.mjs.map +1 -0
  154. package/esm/seal/src/helpers/index.mjs +6 -0
  155. package/esm/seal/src/helpers/is-empty-value.mjs +10 -0
  156. package/esm/seal/src/helpers/is-empty-value.mjs.map +1 -0
  157. package/esm/seal/src/helpers/path-helpers.mjs +12 -0
  158. package/esm/seal/src/helpers/path-helpers.mjs.map +1 -0
  159. package/esm/seal/src/helpers/validation-helpers.mjs +72 -0
  160. package/esm/seal/src/helpers/validation-helpers.mjs.map +1 -0
  161. package/esm/seal/src/index.mjs +87 -0
  162. package/esm/seal/src/mutators/array-mutators.mjs +32 -0
  163. package/esm/seal/src/mutators/array-mutators.mjs.map +1 -0
  164. package/esm/seal/src/mutators/date-mutators.mjs +94 -0
  165. package/esm/seal/src/mutators/date-mutators.mjs.map +1 -0
  166. package/esm/seal/src/mutators/index.mjs +8 -0
  167. package/esm/seal/src/mutators/number-mutators.mjs +52 -0
  168. package/esm/seal/src/mutators/number-mutators.mjs.map +1 -0
  169. package/esm/seal/src/mutators/object-mutators.mjs +30 -0
  170. package/esm/seal/src/mutators/object-mutators.mjs.map +1 -0
  171. package/esm/seal/src/mutators/scalar-mutators.mjs +9 -0
  172. package/esm/seal/src/mutators/scalar-mutators.mjs.map +1 -0
  173. package/esm/seal/src/mutators/string-mutators.mjs +186 -0
  174. package/esm/seal/src/mutators/string-mutators.mjs.map +1 -0
  175. package/esm/seal/src/rules/array/array-rules.mjs +41 -0
  176. package/esm/seal/src/rules/array/array-rules.mjs.map +1 -0
  177. package/esm/seal/src/rules/array/index.mjs +3 -0
  178. package/esm/seal/src/rules/color/color-rules.mjs +104 -0
  179. package/esm/seal/src/rules/color/color-rules.mjs.map +1 -0
  180. package/esm/seal/src/rules/color/index.mjs +3 -0
  181. package/esm/seal/src/rules/common/enum.mjs +77 -0
  182. package/esm/seal/src/rules/common/enum.mjs.map +1 -0
  183. package/esm/seal/src/rules/common/equals-field-rules.mjs +42 -0
  184. package/esm/seal/src/rules/common/equals-field-rules.mjs.map +1 -0
  185. package/esm/seal/src/rules/common/index.mjs +8 -0
  186. package/esm/seal/src/rules/common/instanceof.mjs +23 -0
  187. package/esm/seal/src/rules/common/instanceof.mjs.map +1 -0
  188. package/esm/seal/src/rules/common/literal.mjs +31 -0
  189. package/esm/seal/src/rules/common/literal.mjs.map +1 -0
  190. package/esm/seal/src/rules/common/type-rules.mjs +97 -0
  191. package/esm/seal/src/rules/common/type-rules.mjs.map +1 -0
  192. package/esm/seal/src/rules/common/unknown-key.mjs +25 -0
  193. package/esm/seal/src/rules/common/unknown-key.mjs.map +1 -0
  194. package/esm/seal/src/rules/conditional/forbidden-if-rules.mjs +116 -0
  195. package/esm/seal/src/rules/conditional/forbidden-if-rules.mjs.map +1 -0
  196. package/esm/seal/src/rules/conditional/index.mjs +12 -0
  197. package/esm/seal/src/rules/conditional/present-if-rules.mjs +97 -0
  198. package/esm/seal/src/rules/conditional/present-if-rules.mjs.map +1 -0
  199. package/esm/seal/src/rules/conditional/present-unless-rules.mjs +30 -0
  200. package/esm/seal/src/rules/conditional/present-unless-rules.mjs.map +1 -0
  201. package/esm/seal/src/rules/conditional/present-with-rules.mjs +76 -0
  202. package/esm/seal/src/rules/conditional/present-with-rules.mjs.map +1 -0
  203. package/esm/seal/src/rules/conditional/present-without-rules.mjs +76 -0
  204. package/esm/seal/src/rules/conditional/present-without-rules.mjs.map +1 -0
  205. package/esm/seal/src/rules/conditional/required-if-rules.mjs +204 -0
  206. package/esm/seal/src/rules/conditional/required-if-rules.mjs.map +1 -0
  207. package/esm/seal/src/rules/conditional/required-unless-rules.mjs +31 -0
  208. package/esm/seal/src/rules/conditional/required-unless-rules.mjs.map +1 -0
  209. package/esm/seal/src/rules/conditional/required-when-rule.mjs +32 -0
  210. package/esm/seal/src/rules/conditional/required-when-rule.mjs.map +1 -0
  211. package/esm/seal/src/rules/conditional/required-with-rules.mjs +67 -0
  212. package/esm/seal/src/rules/conditional/required-with-rules.mjs.map +1 -0
  213. package/esm/seal/src/rules/conditional/required-without-rules.mjs +67 -0
  214. package/esm/seal/src/rules/conditional/required-without-rules.mjs.map +1 -0
  215. package/esm/seal/src/rules/core/equal.mjs +22 -0
  216. package/esm/seal/src/rules/core/equal.mjs.map +1 -0
  217. package/esm/seal/src/rules/core/forbidden.mjs +20 -0
  218. package/esm/seal/src/rules/core/forbidden.mjs.map +1 -0
  219. package/esm/seal/src/rules/core/index.mjs +7 -0
  220. package/esm/seal/src/rules/core/required.mjs +36 -0
  221. package/esm/seal/src/rules/core/required.mjs.map +1 -0
  222. package/esm/seal/src/rules/core/union.mjs +30 -0
  223. package/esm/seal/src/rules/core/union.mjs.map +1 -0
  224. package/esm/seal/src/rules/core/when.mjs +37 -0
  225. package/esm/seal/src/rules/core/when.mjs.map +1 -0
  226. package/esm/seal/src/rules/date/date-comparison-rules.mjs +78 -0
  227. package/esm/seal/src/rules/date/date-comparison-rules.mjs.map +1 -0
  228. package/esm/seal/src/rules/date/date-day-rules.mjs +49 -0
  229. package/esm/seal/src/rules/date/date-day-rules.mjs.map +1 -0
  230. package/esm/seal/src/rules/date/date-field-comparison-rules.mjs +82 -0
  231. package/esm/seal/src/rules/date/date-field-comparison-rules.mjs.map +1 -0
  232. package/esm/seal/src/rules/date/date-period-rules.mjs +399 -0
  233. package/esm/seal/src/rules/date/date-period-rules.mjs.map +1 -0
  234. package/esm/seal/src/rules/date/date-relative-rules.mjs +55 -0
  235. package/esm/seal/src/rules/date/date-relative-rules.mjs.map +1 -0
  236. package/esm/seal/src/rules/date/date-special-rules.mjs +58 -0
  237. package/esm/seal/src/rules/date/date-special-rules.mjs.map +1 -0
  238. package/esm/seal/src/rules/date/date.mjs +235 -0
  239. package/esm/seal/src/rules/date/date.mjs.map +1 -0
  240. package/esm/seal/src/rules/date/index.mjs +9 -0
  241. package/esm/seal/src/rules/file/dimensions.mjs +3 -0
  242. package/esm/seal/src/rules/file/file-size.mjs +3 -0
  243. package/esm/seal/src/rules/file/index.mjs +4 -0
  244. package/esm/seal/src/rules/index.mjs +54 -0
  245. package/esm/seal/src/rules/length/index.mjs +3 -0
  246. package/esm/seal/src/rules/length/length-rules.mjs +98 -0
  247. package/esm/seal/src/rules/length/length-rules.mjs.map +1 -0
  248. package/esm/seal/src/rules/number/index.mjs +3 -0
  249. package/esm/seal/src/rules/number/number-rules.mjs +197 -0
  250. package/esm/seal/src/rules/number/number-rules.mjs.map +1 -0
  251. package/esm/seal/src/rules/scalar/accepted-rule.mjs +116 -0
  252. package/esm/seal/src/rules/scalar/accepted-rule.mjs.map +1 -0
  253. package/esm/seal/src/rules/scalar/declined-rule.mjs +116 -0
  254. package/esm/seal/src/rules/scalar/declined-rule.mjs.map +1 -0
  255. package/esm/seal/src/rules/scalar/index.mjs +4 -0
  256. package/esm/seal/src/rules/string/alpha.mjs +41 -0
  257. package/esm/seal/src/rules/string/alpha.mjs.map +1 -0
  258. package/esm/seal/src/rules/string/credit-card.mjs +32 -0
  259. package/esm/seal/src/rules/string/credit-card.mjs.map +1 -0
  260. package/esm/seal/src/rules/string/email.mjs +20 -0
  261. package/esm/seal/src/rules/string/email.mjs.map +1 -0
  262. package/esm/seal/src/rules/string/id-formats.mjs +104 -0
  263. package/esm/seal/src/rules/string/id-formats.mjs.map +1 -0
  264. package/esm/seal/src/rules/string/index.mjs +13 -0
  265. package/esm/seal/src/rules/string/ip.mjs +66 -0
  266. package/esm/seal/src/rules/string/ip.mjs.map +1 -0
  267. package/esm/seal/src/rules/string/matches.mjs +4 -0
  268. package/esm/seal/src/rules/string/pattern.mjs +20 -0
  269. package/esm/seal/src/rules/string/pattern.mjs.map +1 -0
  270. package/esm/seal/src/rules/string/string-comparison.mjs +56 -0
  271. package/esm/seal/src/rules/string/string-comparison.mjs.map +1 -0
  272. package/esm/seal/src/rules/string/strong-password-rule.mjs +31 -0
  273. package/esm/seal/src/rules/string/strong-password-rule.mjs.map +1 -0
  274. package/esm/seal/src/rules/string/url.mjs +23 -0
  275. package/esm/seal/src/rules/string/url.mjs.map +1 -0
  276. package/esm/seal/src/rules/string/without-whitespace.mjs +19 -0
  277. package/esm/seal/src/rules/string/without-whitespace.mjs.map +1 -0
  278. package/esm/seal/src/standard-schema/json-schema.mjs +81 -0
  279. package/esm/seal/src/standard-schema/json-schema.mjs.map +1 -0
  280. package/esm/seal/src/standard-schema/map-result.mjs +26 -0
  281. package/esm/seal/src/standard-schema/map-result.mjs.map +1 -0
  282. package/esm/seal/src/types/date-types.mjs +17 -0
  283. package/esm/seal/src/types/date-types.mjs.map +1 -0
  284. package/esm/seal/src/validators/any-validator.mjs +38 -0
  285. package/esm/seal/src/validators/any-validator.mjs.map +1 -0
  286. package/esm/seal/src/validators/array-validator.mjs +177 -0
  287. package/esm/seal/src/validators/array-validator.mjs.map +1 -0
  288. package/esm/seal/src/validators/base-validator.mjs +691 -0
  289. package/esm/seal/src/validators/base-validator.mjs.map +1 -0
  290. package/esm/seal/src/validators/boolean-validator.mjs +126 -0
  291. package/esm/seal/src/validators/boolean-validator.mjs.map +1 -0
  292. package/esm/seal/src/validators/computed-validator.mjs +118 -0
  293. package/esm/seal/src/validators/computed-validator.mjs.map +1 -0
  294. package/esm/seal/src/validators/date-validator.mjs +639 -0
  295. package/esm/seal/src/validators/date-validator.mjs.map +1 -0
  296. package/esm/seal/src/validators/discriminated-union-validator.mjs +129 -0
  297. package/esm/seal/src/validators/discriminated-union-validator.mjs.map +1 -0
  298. package/esm/seal/src/validators/float-validator.mjs +18 -0
  299. package/esm/seal/src/validators/float-validator.mjs.map +1 -0
  300. package/esm/seal/src/validators/index.mjs +28 -0
  301. package/esm/seal/src/validators/instanceof-validator.mjs +64 -0
  302. package/esm/seal/src/validators/instanceof-validator.mjs.map +1 -0
  303. package/esm/seal/src/validators/int-validator.mjs +30 -0
  304. package/esm/seal/src/validators/int-validator.mjs.map +1 -0
  305. package/esm/seal/src/validators/lazy-validator.mjs +87 -0
  306. package/esm/seal/src/validators/lazy-validator.mjs.map +1 -0
  307. package/esm/seal/src/validators/literal-validator.mjs +71 -0
  308. package/esm/seal/src/validators/literal-validator.mjs.map +1 -0
  309. package/esm/seal/src/validators/managed-validator.mjs +39 -0
  310. package/esm/seal/src/validators/managed-validator.mjs.map +1 -0
  311. package/esm/seal/src/validators/methods/equality-conditional-methods.mjs +129 -0
  312. package/esm/seal/src/validators/methods/equality-conditional-methods.mjs.map +1 -0
  313. package/esm/seal/src/validators/methods/forbidden-methods.mjs +131 -0
  314. package/esm/seal/src/validators/methods/forbidden-methods.mjs.map +1 -0
  315. package/esm/seal/src/validators/methods/present-methods.mjs +235 -0
  316. package/esm/seal/src/validators/methods/present-methods.mjs.map +1 -0
  317. package/esm/seal/src/validators/methods/required-methods.mjs +347 -0
  318. package/esm/seal/src/validators/methods/required-methods.mjs.map +1 -0
  319. package/esm/seal/src/validators/number-validator.mjs +310 -0
  320. package/esm/seal/src/validators/number-validator.mjs.map +1 -0
  321. package/esm/seal/src/validators/numeric-validator.mjs +27 -0
  322. package/esm/seal/src/validators/numeric-validator.mjs.map +1 -0
  323. package/esm/seal/src/validators/object-validator.mjs +442 -0
  324. package/esm/seal/src/validators/object-validator.mjs.map +1 -0
  325. package/esm/seal/src/validators/primitive-validator.mjs +89 -0
  326. package/esm/seal/src/validators/primitive-validator.mjs.map +1 -0
  327. package/esm/seal/src/validators/record-validator.mjs +112 -0
  328. package/esm/seal/src/validators/record-validator.mjs.map +1 -0
  329. package/esm/seal/src/validators/scalar-validator.mjs +172 -0
  330. package/esm/seal/src/validators/scalar-validator.mjs.map +1 -0
  331. package/esm/seal/src/validators/string-validator.mjs +459 -0
  332. package/esm/seal/src/validators/string-validator.mjs.map +1 -0
  333. package/esm/seal/src/validators/tuple-validator.mjs +134 -0
  334. package/esm/seal/src/validators/tuple-validator.mjs.map +1 -0
  335. package/esm/seal/src/validators/union-validator.mjs +66 -0
  336. package/esm/seal/src/validators/union-validator.mjs.map +1 -0
  337. package/package.json +5 -5
@@ -0,0 +1,353 @@
1
+ //#region ../node_modules/@mongez/supportive-is/esm/index.mjs
2
+ /**
3
+ * Determine whether the given value is a number whatever if its data type is String or Number
4
+ */
5
+ function isNumeric(value) {
6
+ return /^[+-]?\d+(\.\d+)?([Ee][+-]?\d+)?$/.test(String(value));
7
+ }
8
+ /**
9
+ * Check if the given value is int
10
+ */
11
+ const isInt = (value) => typeof value === "number" && Number.isInteger(value);
12
+ /**
13
+ * Check if the given value is float
14
+ */
15
+ const isFloat = (value) => typeof value === "number" && Number.isFinite(value) && /^-?\d+\.\d+$/.test(String(value));
16
+ /**
17
+ * Check if the given value is a regex
18
+ */
19
+ const isRegex = (value) => Boolean(value) && value.constructor?.name === "RegExp";
20
+ /**
21
+ * Check if the given value is an object
22
+ */
23
+ const isObject = (value) => Boolean(value) && typeof value === "object";
24
+ /**
25
+ * Check if the given value is a plain object
26
+ */
27
+ const isPlainObject = (value) => {
28
+ if (!value || typeof value !== "object") return false;
29
+ if (Object.getPrototypeOf(value) === null) return true;
30
+ return value.constructor?.name === "Object";
31
+ };
32
+ /**
33
+ * Check if the given value is validId
34
+ */
35
+ const isValidId = (value) => Boolean(value && /^[A-Za-z][\w\-:.]*$/.test(String(value)));
36
+ /**
37
+ * Check if the given value is a form element
38
+ */
39
+ const isFormElement = (value) => typeof HTMLFormElement === "undefined" ? false : value instanceof HTMLFormElement;
40
+ /**
41
+ * Check if the given value is a form data
42
+ */
43
+ const isFormData = (value) => value instanceof FormData;
44
+ /**
45
+ * Check if the given value is iterable
46
+ */
47
+ const isIterable = (value) => value !== null && value !== void 0 && typeof value[Symbol.iterator] === "function";
48
+ /**
49
+ * Check if the given value is a scalar value
50
+ */
51
+ const isScalar = (value) => [
52
+ "string",
53
+ "boolean",
54
+ "number",
55
+ "symbol",
56
+ "bigint"
57
+ ].includes(typeof value);
58
+ /**
59
+ * Check if the given value is a pr value
60
+ */
61
+ const isPrimitive = (value) => [
62
+ "string",
63
+ "boolean",
64
+ "number",
65
+ "bigint"
66
+ ].includes(typeof value);
67
+ /**
68
+ * Check if the given value is a promise
69
+ */
70
+ const isPromise = (value) => Boolean(value) && value instanceof Promise;
71
+ /**
72
+ * Check if the given value is a date
73
+ */
74
+ const isDate = (value) => Boolean(value) && typeof value === "object" && value instanceof Date;
75
+ /**
76
+ * Check if the given value is a generator
77
+ */
78
+ const isGenerator = (value) => Boolean(value) && typeof value === "object" && typeof value.next === "function" && typeof value[Symbol.iterator] === "function" && value[Symbol.iterator]() === value;
79
+ /**
80
+ * Check if the given value is empty
81
+ * Zero does not considered empty
82
+ * Empty object is considered empty
83
+ * Empty array is considered empty
84
+ */
85
+ const isEmpty = (value) => {
86
+ if ([
87
+ 0,
88
+ true,
89
+ false
90
+ ].includes(value)) return false;
91
+ if ([
92
+ "",
93
+ null,
94
+ void 0
95
+ ].includes(value)) return true;
96
+ if (typeof value === "number" && Number.isNaN(value)) return false;
97
+ if (value instanceof Date) return false;
98
+ if (value instanceof Map || value instanceof Set) return value.size === 0;
99
+ if (typeof value === "object" && !Array.isArray(value) && typeof value[Symbol.iterator] !== "function") return Object.keys(value).length === 0;
100
+ if (isIterable(value)) return value.length === 0;
101
+ if (isNumeric(value)) return false;
102
+ return true;
103
+ };
104
+ /**
105
+ * Check if the given value is a valid json
106
+ */
107
+ const isJson = (value) => {
108
+ if (!value || typeof value !== "string") return false;
109
+ if (!["[", "{"].includes(value?.[0])) return false;
110
+ try {
111
+ JSON.parse(value);
112
+ return true;
113
+ } catch (e) {
114
+ return false;
115
+ }
116
+ };
117
+ /**
118
+ * Check if the given value is valid url
119
+ */
120
+ const isUrl = (value) => {
121
+ if (!value || typeof value !== "string") return false;
122
+ try {
123
+ const url = new URL(value);
124
+ if (!["http:", "https:"].includes(url.protocol)) return false;
125
+ const hostname = url.hostname;
126
+ if (!hostname.includes(".")) return false;
127
+ if (hostname.split(".").some((label) => label.length === 0)) return false;
128
+ return true;
129
+ } catch (e) {
130
+ return false;
131
+ }
132
+ };
133
+ /**
134
+ * Check if the given value is a valid email
135
+ */
136
+ const isEmail = (value) => typeof value === "string" && /^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/.test(value);
137
+ /**
138
+ * Check if current user is opening from mobile
139
+ */
140
+ const isMobile = {
141
+ /**
142
+ * Determine whether the current visitor is opening from an Android device
143
+ */
144
+ android: () => navigator.userAgent.match(/Android/i) !== null,
145
+ /**
146
+ * Determine whether the current visitor is opening from an ios device
147
+ */
148
+ ios: () => navigator.userAgent.match(/iPhone|iPad|iPod/i) !== null,
149
+ /**
150
+ * Determine whether the current visitor is opening from an Iphone
151
+ */
152
+ iphone: () => navigator.userAgent.match(/iPhone/i) !== null,
153
+ /**
154
+ * Determine whether the current visitor is opening from an ipad
155
+ */
156
+ ipad: () => navigator.userAgent.match(/iPad/i) !== null,
157
+ /**
158
+ * Determine whether the current visitor is opening from an ipod
159
+ */
160
+ ipod: () => navigator.userAgent.match(/iPod/i) !== null,
161
+ /**
162
+ * Determine whether the current visitor is opening from an windows mobile
163
+ */
164
+ windows: () => navigator.userAgent.match(/IEMobile/i) !== null,
165
+ /**
166
+ * Determine whether the current visitor is opening from mobile whatever its type
167
+ */
168
+ any: () => isMobile.android() || isMobile.ios() || isMobile.windows()
169
+ };
170
+ /**
171
+ * Determine if current user is opening from macOS
172
+ */
173
+ const isMac = () => navigator.userAgent.match(/mac/i) !== null;
174
+ /**
175
+ * Check if current browser is the given name
176
+ */
177
+ const isBrowser = (browser) => {
178
+ return {
179
+ chrome: isChrome(),
180
+ firefox: isFirefox(),
181
+ opera: isOpera(),
182
+ edge: isEdge(),
183
+ ie: isIE(),
184
+ safari: isSafari()
185
+ }[browser.toLowerCase()] === true;
186
+ };
187
+ /**
188
+ * Check if current browser is chrome browser
189
+ */
190
+ const isChrome = () => !!window.chrome && (!!window.chrome.webstore || !!window.chrome.runtime);
191
+ /**
192
+ * Check if current browser is firefox
193
+ */
194
+ const isFirefox = () => typeof window.InstallTrigger !== "undefined";
195
+ /**
196
+ * Check if current browser is safari
197
+ */
198
+ const isSafari = () => {
199
+ if (typeof navigator === "undefined") return false;
200
+ const ua = navigator.userAgent || "";
201
+ return /Safari/i.test(ua) && !/Chrome|Chromium|Edg|OPR|Android/i.test(ua);
202
+ };
203
+ /**
204
+ * Check if current browser is opera
205
+ */
206
+ const isOpera = () => {
207
+ if (typeof window === "undefined") return false;
208
+ const w = window;
209
+ return !!w.opr && !!w.opr.addons || !!w.opera || typeof navigator !== "undefined" && navigator.userAgent.indexOf(" OPR/") >= 0;
210
+ };
211
+ /**
212
+ * Check if current browser is internet explorer
213
+ */
214
+ const isIE = () => !!document.documentMode;
215
+ /**
216
+ * Check if current browser is edge
217
+ */
218
+ const isEdge = () => {
219
+ return !!!document.documentMode && !!window.StyleMedia;
220
+ };
221
+ /**
222
+ * Determine whether the current visitor is opening from desktop
223
+ */
224
+ const isDesktop = () => !isMobile.any();
225
+ /**
226
+ * A simple lightweight library to validate values against certain types of data
227
+ * For full documentation on github
228
+ * Repo: https://github.com/hassanzohdy/supportive-is
229
+ *
230
+ * First released 01/12/2017
231
+ * Licensed under MIT (http://opensource.org/licenses/MIT)
232
+ */
233
+ const Is = {
234
+ /**
235
+ * Determine whether the given value is a number whatever if its data type is String or Number
236
+ */
237
+ numeric: isNumeric,
238
+ /**
239
+ * Determine whether the given value is an integer and its data type is number
240
+ * As Number.isInteger considers 1.0 to be valid integer, regex will be used instead
241
+ */
242
+ int: isInt,
243
+ /**
244
+ * Determine whether the given value is a float number and its data type is number
245
+ */
246
+ float: isFloat,
247
+ /**
248
+ * Determine whether the given value is a regular expression
249
+ */
250
+ regex: isRegex,
251
+ /**
252
+ * Determine whether the given value is an object
253
+ */
254
+ object: isObject,
255
+ /**
256
+ * Determine whether the given value is a plain object
257
+ */
258
+ plainObject: isPlainObject,
259
+ /**
260
+ * Determine whether the given value is an array
261
+ */
262
+ array: Array.isArray,
263
+ /**
264
+ * Determine whether the given value is valid html attribute `id`
265
+ */
266
+ validHtmlId: isValidId,
267
+ /**
268
+ * determine if the given value is an instance of form element
269
+ */
270
+ formElement: isFormElement,
271
+ /**
272
+ * @alias formElement
273
+ */
274
+ form: isFormElement,
275
+ /**
276
+ * determine if the given value is an instance of form data
277
+ */
278
+ formData: isFormData,
279
+ /**
280
+ * Determine whether the given value is iterable
281
+ */
282
+ iterable: isIterable,
283
+ /**
284
+ * Determine whether the given value is a scalar
285
+ * Scalar types are strings, booleans, integers and
286
+ */
287
+ scalar: isScalar,
288
+ /**
289
+ * Determine if the given value is a primitive value
290
+ */
291
+ primitive: isPrimitive,
292
+ /**
293
+ * Determine whether the given value is a promise
294
+ */
295
+ promise: isPromise,
296
+ /**
297
+ * Determine whether the given value is a date
298
+ */
299
+ date: isDate,
300
+ /**
301
+ * Determine whether the given value is a generator
302
+ */
303
+ generator: isGenerator,
304
+ /**
305
+ * Determine whether the given value if an empty
306
+ * This can be validated against any type of values
307
+ * undefined or nullable values will be considered empty
308
+ * Objects that doesn't have any properties will be considered empty
309
+ * Arrays and Strings will be empty based on its length
310
+ * The 0 'Zero" number will not be considered empty
311
+ */
312
+ empty: isEmpty,
313
+ /**
314
+ * Determine whether the given value is a valid json string
315
+ */
316
+ json: isJson,
317
+ /**
318
+ * Determine whether the given value is a valid url
319
+ */
320
+ url: isUrl,
321
+ /**
322
+ * Determine whether the given value is a valid email
323
+ */
324
+ email: isEmail,
325
+ /**
326
+ * Determine the current visitor is opening from mobile
327
+ * Please Note this method depends on the user agent
328
+ */
329
+ mobile: isMobile,
330
+ /**
331
+ * Determine if current user is opening from macOS
332
+ */
333
+ mac: isMac,
334
+ /**
335
+ * Determine whether the current visitor is opening from desktop
336
+ */
337
+ desktop: isDesktop,
338
+ /**
339
+ * Check if the current browser is the given name
340
+ * To detect browser version as well, pass the version number as the second argument
341
+ */
342
+ browser: isBrowser,
343
+ chrome: isChrome,
344
+ firefox: isFirefox,
345
+ safari: isSafari,
346
+ opera: isOpera,
347
+ ie: isIE,
348
+ edge: isEdge
349
+ };
350
+
351
+ //#endregion
352
+ export { isEmail, isEmpty, isNumeric, isObject, isPlainObject };
353
+ //# sourceMappingURL=index.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.mjs","names":[],"sources":["../../../../../../../../../../node_modules/@mongez/supportive-is/esm/index.mjs"],"sourcesContent":["//#region ../supportive-is/src/index.ts\n/**\n* Determine whether the given value is a number whatever if its data type is String or Number\n*/\nfunction isNumeric(value) {\n\treturn /^[+-]?\\d+(\\.\\d+)?([Ee][+-]?\\d+)?$/.test(String(value));\n}\n/**\n* Check if the given value is int\n*/\nconst isInt = (value) => typeof value === \"number\" && Number.isInteger(value);\n/**\n* Check if the given value is float\n*/\nconst isFloat = (value) => typeof value === \"number\" && Number.isFinite(value) && /^-?\\d+\\.\\d+$/.test(String(value));\n/**\n* Check if the given value is a regex\n*/\nconst isRegex = (value) => Boolean(value) && value.constructor?.name === \"RegExp\";\n/**\n* Check if the given value is an object\n*/\nconst isObject = (value) => Boolean(value) && typeof value === \"object\";\n/**\n* Check if the given value is a plain object\n*/\nconst isPlainObject = (value) => {\n\tif (!value || typeof value !== \"object\") return false;\n\tif (Object.getPrototypeOf(value) === null) return true;\n\treturn value.constructor?.name === \"Object\";\n};\n/**\n* Check if the given value is validId\n*/\nconst isValidId = (value) => Boolean(value && /^[A-Za-z][\\w\\-:.]*$/.test(String(value)));\n/**\n* Check if the given value is a form element\n*/\nconst isFormElement = (value) => typeof HTMLFormElement === \"undefined\" ? false : value instanceof HTMLFormElement;\n/**\n* Check if the given value is a form data\n*/\nconst isFormData = (value) => value instanceof FormData;\n/**\n* Check if the given value is iterable\n*/\nconst isIterable = (value) => value !== null && value !== void 0 && typeof value[Symbol.iterator] === \"function\";\n/**\n* Check if the given value is a scalar value\n*/\nconst isScalar = (value) => [\n\t\"string\",\n\t\"boolean\",\n\t\"number\",\n\t\"symbol\",\n\t\"bigint\"\n].includes(typeof value);\n/**\n* Check if the given value is a string\n*/\nconst isString = (value) => typeof value === \"string\";\n/**\n* Check if the given value is a pr value\n*/\nconst isPrimitive = (value) => [\n\t\"string\",\n\t\"boolean\",\n\t\"number\",\n\t\"bigint\"\n].includes(typeof value);\n/**\n* Check if the given value is a promise\n*/\nconst isPromise = (value) => Boolean(value) && value instanceof Promise;\n/**\n* Check if the given value is a date\n*/\nconst isDate = (value) => Boolean(value) && typeof value === \"object\" && value instanceof Date;\n/**\n* Check if the given value is a generator\n*/\nconst isGenerator = (value) => Boolean(value) && typeof value === \"object\" && typeof value.next === \"function\" && typeof value[Symbol.iterator] === \"function\" && value[Symbol.iterator]() === value;\n/**\n* Check if the given value is empty\n* Zero does not considered empty\n* Empty object is considered empty\n* Empty array is considered empty\n*/\nconst isEmpty = (value) => {\n\tif ([\n\t\t0,\n\t\ttrue,\n\t\tfalse\n\t].includes(value)) return false;\n\tif ([\n\t\t\"\",\n\t\tnull,\n\t\tvoid 0\n\t].includes(value)) return true;\n\tif (typeof value === \"number\" && Number.isNaN(value)) return false;\n\tif (value instanceof Date) return false;\n\tif (value instanceof Map || value instanceof Set) return value.size === 0;\n\tif (typeof value === \"object\" && !Array.isArray(value) && typeof value[Symbol.iterator] !== \"function\") return Object.keys(value).length === 0;\n\tif (isIterable(value)) return value.length === 0;\n\tif (isNumeric(value)) return false;\n\treturn true;\n};\n/**\n* Check if the given value is a valid json\n*/\nconst isJson = (value) => {\n\tif (!value || typeof value !== \"string\") return false;\n\tif (![\"[\", \"{\"].includes(value?.[0])) return false;\n\ttry {\n\t\tJSON.parse(value);\n\t\treturn true;\n\t} catch (e) {\n\t\treturn false;\n\t}\n};\n/**\n* Check if the given value is valid url\n*/\nconst isUrl = (value) => {\n\tif (!value || typeof value !== \"string\") return false;\n\ttry {\n\t\tconst url = new URL(value);\n\t\tif (![\"http:\", \"https:\"].includes(url.protocol)) return false;\n\t\tconst hostname = url.hostname;\n\t\tif (!hostname.includes(\".\")) return false;\n\t\tif (hostname.split(\".\").some((label) => label.length === 0)) return false;\n\t\treturn true;\n\t} catch (e) {\n\t\treturn false;\n\t}\n};\n/**\n* Check if the given value is a valid email\n*/\nconst isEmail = (value) => typeof value === \"string\" && /^(([^<>()\\[\\]\\\\.,;:\\s@\"]+(\\.[^<>()\\[\\]\\\\.,;:\\s@\"]+)*)|(\".+\"))@((\\[[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}])|(([a-zA-Z\\-0-9]+\\.)+[a-zA-Z]{2,}))$/.test(value);\n/**\n* Check if current user is opening from mobile\n*/\nconst isMobile = {\n\t/**\n\t* Determine whether the current visitor is opening from an Android device\n\t*/\n\tandroid: () => navigator.userAgent.match(/Android/i) !== null,\n\t/**\n\t* Determine whether the current visitor is opening from an ios device\n\t*/\n\tios: () => navigator.userAgent.match(/iPhone|iPad|iPod/i) !== null,\n\t/**\n\t* Determine whether the current visitor is opening from an Iphone\n\t*/\n\tiphone: () => navigator.userAgent.match(/iPhone/i) !== null,\n\t/**\n\t* Determine whether the current visitor is opening from an ipad\n\t*/\n\tipad: () => navigator.userAgent.match(/iPad/i) !== null,\n\t/**\n\t* Determine whether the current visitor is opening from an ipod\n\t*/\n\tipod: () => navigator.userAgent.match(/iPod/i) !== null,\n\t/**\n\t* Determine whether the current visitor is opening from an windows mobile\n\t*/\n\twindows: () => navigator.userAgent.match(/IEMobile/i) !== null,\n\t/**\n\t* Determine whether the current visitor is opening from mobile whatever its type\n\t*/\n\tany: () => isMobile.android() || isMobile.ios() || isMobile.windows()\n};\n/**\n* Determine if current user is opening from macOS\n*/\nconst isMac = () => navigator.userAgent.match(/mac/i) !== null;\n/**\n* Check if current browser is the given name\n*/\nconst isBrowser = (browser) => {\n\treturn {\n\t\tchrome: isChrome(),\n\t\tfirefox: isFirefox(),\n\t\topera: isOpera(),\n\t\tedge: isEdge(),\n\t\tie: isIE(),\n\t\tsafari: isSafari()\n\t}[browser.toLowerCase()] === true;\n};\n/**\n* Check if current browser is chrome browser\n*/\nconst isChrome = () => !!window.chrome && (!!window.chrome.webstore || !!window.chrome.runtime);\n/**\n* Check if current browser is firefox\n*/\nconst isFirefox = () => typeof window.InstallTrigger !== \"undefined\";\n/**\n* Check if current browser is safari\n*/\nconst isSafari = () => {\n\tif (typeof navigator === \"undefined\") return false;\n\tconst ua = navigator.userAgent || \"\";\n\treturn /Safari/i.test(ua) && !/Chrome|Chromium|Edg|OPR|Android/i.test(ua);\n};\n/**\n* Check if current browser is opera\n*/\nconst isOpera = () => {\n\tif (typeof window === \"undefined\") return false;\n\tconst w = window;\n\treturn !!w.opr && !!w.opr.addons || !!w.opera || typeof navigator !== \"undefined\" && navigator.userAgent.indexOf(\" OPR/\") >= 0;\n};\n/**\n* Check if current browser is internet explorer\n*/\nconst isIE = () => !!document.documentMode;\n/**\n* Check if current browser is edge\n*/\nconst isEdge = () => {\n\treturn !!!document.documentMode && !!window.StyleMedia;\n};\n/**\n* Determine whether the current visitor is opening from desktop\n*/\nconst isDesktop = () => !isMobile.any();\n/**\n* A simple lightweight library to validate values against certain types of data\n* For full documentation on github\n* Repo: https://github.com/hassanzohdy/supportive-is\n*\n* First released 01/12/2017\n* Licensed under MIT (http://opensource.org/licenses/MIT)\n*/\nconst Is = {\n\t/**\n\t* Determine whether the given value is a number whatever if its data type is String or Number\n\t*/\n\tnumeric: isNumeric,\n\t/**\n\t* Determine whether the given value is an integer and its data type is number\n\t* As Number.isInteger considers 1.0 to be valid integer, regex will be used instead\n\t*/\n\tint: isInt,\n\t/**\n\t* Determine whether the given value is a float number and its data type is number\n\t*/\n\tfloat: isFloat,\n\t/**\n\t* Determine whether the given value is a regular expression\n\t*/\n\tregex: isRegex,\n\t/**\n\t* Determine whether the given value is an object\n\t*/\n\tobject: isObject,\n\t/**\n\t* Determine whether the given value is a plain object\n\t*/\n\tplainObject: isPlainObject,\n\t/**\n\t* Determine whether the given value is an array\n\t*/\n\tarray: Array.isArray,\n\t/**\n\t* Determine whether the given value is valid html attribute `id`\n\t*/\n\tvalidHtmlId: isValidId,\n\t/**\n\t* determine if the given value is an instance of form element\n\t*/\n\tformElement: isFormElement,\n\t/**\n\t* @alias formElement\n\t*/\n\tform: isFormElement,\n\t/**\n\t* determine if the given value is an instance of form data\n\t*/\n\tformData: isFormData,\n\t/**\n\t* Determine whether the given value is iterable\n\t*/\n\titerable: isIterable,\n\t/**\n\t* Determine whether the given value is a scalar\n\t* Scalar types are strings, booleans, integers and\n\t*/\n\tscalar: isScalar,\n\t/**\n\t* Determine if the given value is a primitive value\n\t*/\n\tprimitive: isPrimitive,\n\t/**\n\t* Determine whether the given value is a promise\n\t*/\n\tpromise: isPromise,\n\t/**\n\t* Determine whether the given value is a date\n\t*/\n\tdate: isDate,\n\t/**\n\t* Determine whether the given value is a generator\n\t*/\n\tgenerator: isGenerator,\n\t/**\n\t* Determine whether the given value if an empty\n\t* This can be validated against any type of values\n\t* undefined or nullable values will be considered empty\n\t* Objects that doesn't have any properties will be considered empty\n\t* Arrays and Strings will be empty based on its length\n\t* The 0 'Zero\" number will not be considered empty\n\t*/\n\tempty: isEmpty,\n\t/**\n\t* Determine whether the given value is a valid json string\n\t*/\n\tjson: isJson,\n\t/**\n\t* Determine whether the given value is a valid url\n\t*/\n\turl: isUrl,\n\t/**\n\t* Determine whether the given value is a valid email\n\t*/\n\temail: isEmail,\n\t/**\n\t* Determine the current visitor is opening from mobile\n\t* Please Note this method depends on the user agent\n\t*/\n\tmobile: isMobile,\n\t/**\n\t* Determine if current user is opening from macOS\n\t*/\n\tmac: isMac,\n\t/**\n\t* Determine whether the current visitor is opening from desktop\n\t*/\n\tdesktop: isDesktop,\n\t/**\n\t* Check if the current browser is the given name\n\t* To detect browser version as well, pass the version number as the second argument\n\t*/\n\tbrowser: isBrowser,\n\tchrome: isChrome,\n\tfirefox: isFirefox,\n\tsafari: isSafari,\n\topera: isOpera,\n\tie: isIE,\n\tedge: isEdge\n};\n\n//#endregion\nexport { Is, Is as default, isBrowser, isChrome, isDate, isDesktop, isEdge, isEmail, isEmpty, isFirefox, isFloat, isFormData, isFormElement, isGenerator, isIE, isInt, isIterable, isJson, isMac, isMobile, isNumeric, isObject, isOpera, isPlainObject, isPrimitive, isPromise, isRegex, isSafari, isScalar, isString, isUrl, isValidId };\n//# sourceMappingURL=index.mjs.map"],"x_google_ignoreList":[0],"mappings":";;;;AAIA,SAAS,UAAU,OAAO;CACzB,OAAO,oCAAoC,KAAK,OAAO,KAAK,CAAC;AAC9D;;;;AAIA,MAAM,SAAS,UAAU,OAAO,UAAU,YAAY,OAAO,UAAU,KAAK;;;;AAI5E,MAAM,WAAW,UAAU,OAAO,UAAU,YAAY,OAAO,SAAS,KAAK,KAAK,eAAe,KAAK,OAAO,KAAK,CAAC;;;;AAInH,MAAM,WAAW,UAAU,QAAQ,KAAK,KAAK,MAAM,aAAa,SAAS;;;;AAIzE,MAAM,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aAAa;;;;CAIb,aAAa;;;;CAIb,MAAM;;;;CAIN,UAAU;;;;CAIV,UAAU;;;;;CAKV,QAAQ;;;;CAIR,WAAW;;;;CAIX,SAAS;;;;CAIT,MAAM;;;;CAIN,WAAW;;;;;;;;;CASX,OAAO;;;;CAIP,MAAM;;;;CAIN,KAAK;;;;CAIL,OAAO;;;;;CAKP,QAAQ;;;;CAIR,KAAK;;;;CAIL,SAAS;;;;;CAKT,SAAS;CACT,QAAQ;CACR,SAAS;CACT,QAAQ;CACR,OAAO;CACP,IAAI;CACJ,MAAM;AACP"}
@@ -0,0 +1,28 @@
1
+ import { __commonJSMin, __require } from "../../_virtual/_rolldown/runtime.mjs";
2
+ import { require_error } from "./lib/error.mjs";
3
+ import { require_credentials } from "./lib/credentials.mjs";
4
+ import { require_connect } from "./lib/connect.mjs";
5
+ import { require_channel_model } from "./lib/channel_model.mjs";
6
+
7
+ //#region ../node_modules/amqplib/channel_api.js
8
+ var require_channel_api = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9
+ var raw_connect = require_connect().connect;
10
+ var ChannelModel = require_channel_model().ChannelModel;
11
+ var promisify = __require("util").promisify;
12
+ function connect(url, connOptions) {
13
+ return promisify(function(cb) {
14
+ return raw_connect(url, connOptions, cb);
15
+ })().then(function(conn) {
16
+ return new ChannelModel(conn);
17
+ });
18
+ }
19
+ module.exports.connect = connect;
20
+ module.exports.credentials = require_credentials();
21
+ module.exports.IllegalOperationError = require_error().IllegalOperationError;
22
+ }));
23
+
24
+ //#endregion
25
+ export default require_channel_api();
26
+
27
+ export { };
28
+ //# sourceMappingURL=channel_api.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"channel_api.mjs","names":[],"sources":["../../../../../../../../node_modules/amqplib/channel_api.js"],"sourcesContent":["var raw_connect = require('./lib/connect').connect;\nvar ChannelModel = require('./lib/channel_model').ChannelModel;\nvar promisify = require('util').promisify;\n\nfunction connect(url, connOptions) {\n return promisify(function(cb) {\n return raw_connect(url, connOptions, cb);\n })()\n .then(function(conn) {\n return new ChannelModel(conn);\n });\n};\n\nmodule.exports.connect = connect;\nmodule.exports.credentials = require('./lib/credentials');\nmodule.exports.IllegalOperationError = require('./lib/error').IllegalOperationError;\n"],"x_google_ignoreList":[0],"mappings":";;;;;;;;CAAA,IAAI,gCAAuC;CAC3C,IAAI,uCAA8C;CAClD,IAAI,sBAAoB,MAAM,CAAC,CAAC;CAEhC,SAAS,QAAQ,KAAK,aAAa;EACjC,OAAO,UAAU,SAAS,IAAI;GAC5B,OAAO,YAAY,KAAK,aAAa,EAAE;EACzC,CAAC,CAAC,CAAC,CAAC,CACH,KAAK,SAAS,MAAM;GACnB,OAAO,IAAI,aAAa,IAAI;EAC9B,CAAC;CACH;CAEA,OAAO,QAAQ,UAAU;CACzB,OAAO,QAAQ;CACf,OAAO,QAAQ,wCAA+C"}
@@ -0,0 +1,241 @@
1
+ import { __commonJSMin } from "../../../_virtual/_rolldown/runtime.mjs";
2
+
3
+ //#region ../node_modules/amqplib/lib/api_args.js
4
+ var require_api_args = /* @__PURE__ */ __commonJSMin(((exports, module) => {
5
+ function setIfDefined(obj, prop, value) {
6
+ if (value != void 0) obj[prop] = value;
7
+ }
8
+ var EMPTY_OPTIONS = Object.freeze({});
9
+ var Args = {};
10
+ Args.assertQueue = function(queue, options) {
11
+ queue = queue || "";
12
+ options = options || EMPTY_OPTIONS;
13
+ var argt = Object.create(options.arguments || null);
14
+ setIfDefined(argt, "x-expires", options.expires);
15
+ setIfDefined(argt, "x-message-ttl", options.messageTtl);
16
+ setIfDefined(argt, "x-dead-letter-exchange", options.deadLetterExchange);
17
+ setIfDefined(argt, "x-dead-letter-routing-key", options.deadLetterRoutingKey);
18
+ setIfDefined(argt, "x-max-length", options.maxLength);
19
+ setIfDefined(argt, "x-max-priority", options.maxPriority);
20
+ setIfDefined(argt, "x-overflow", options.overflow);
21
+ setIfDefined(argt, "x-queue-mode", options.queueMode);
22
+ return {
23
+ queue,
24
+ exclusive: !!options.exclusive,
25
+ durable: options.durable === void 0 ? true : options.durable,
26
+ autoDelete: !!options.autoDelete,
27
+ arguments: argt,
28
+ passive: false,
29
+ ticket: 0,
30
+ nowait: false
31
+ };
32
+ };
33
+ Args.checkQueue = function(queue) {
34
+ return {
35
+ queue,
36
+ passive: true,
37
+ nowait: false,
38
+ durable: true,
39
+ autoDelete: false,
40
+ exclusive: false,
41
+ ticket: 0
42
+ };
43
+ };
44
+ Args.deleteQueue = function(queue, options) {
45
+ options = options || EMPTY_OPTIONS;
46
+ return {
47
+ queue,
48
+ ifUnused: !!options.ifUnused,
49
+ ifEmpty: !!options.ifEmpty,
50
+ ticket: 0,
51
+ nowait: false
52
+ };
53
+ };
54
+ Args.purgeQueue = function(queue) {
55
+ return {
56
+ queue,
57
+ ticket: 0,
58
+ nowait: false
59
+ };
60
+ };
61
+ Args.bindQueue = function(queue, source, pattern, argt) {
62
+ return {
63
+ queue,
64
+ exchange: source,
65
+ routingKey: pattern,
66
+ arguments: argt,
67
+ ticket: 0,
68
+ nowait: false
69
+ };
70
+ };
71
+ Args.unbindQueue = function(queue, source, pattern, argt) {
72
+ return {
73
+ queue,
74
+ exchange: source,
75
+ routingKey: pattern,
76
+ arguments: argt,
77
+ ticket: 0,
78
+ nowait: false
79
+ };
80
+ };
81
+ Args.assertExchange = function(exchange, type, options) {
82
+ options = options || EMPTY_OPTIONS;
83
+ var argt = Object.create(options.arguments || null);
84
+ setIfDefined(argt, "alternate-exchange", options.alternateExchange);
85
+ return {
86
+ exchange,
87
+ ticket: 0,
88
+ type,
89
+ passive: false,
90
+ durable: options.durable === void 0 ? true : options.durable,
91
+ autoDelete: !!options.autoDelete,
92
+ internal: !!options.internal,
93
+ nowait: false,
94
+ arguments: argt
95
+ };
96
+ };
97
+ Args.checkExchange = function(exchange) {
98
+ return {
99
+ exchange,
100
+ passive: true,
101
+ nowait: false,
102
+ durable: true,
103
+ internal: false,
104
+ type: "",
105
+ autoDelete: false,
106
+ ticket: 0
107
+ };
108
+ };
109
+ Args.deleteExchange = function(exchange, options) {
110
+ options = options || EMPTY_OPTIONS;
111
+ return {
112
+ exchange,
113
+ ifUnused: !!options.ifUnused,
114
+ ticket: 0,
115
+ nowait: false
116
+ };
117
+ };
118
+ Args.bindExchange = function(dest, source, pattern, argt) {
119
+ return {
120
+ source,
121
+ destination: dest,
122
+ routingKey: pattern,
123
+ arguments: argt,
124
+ ticket: 0,
125
+ nowait: false
126
+ };
127
+ };
128
+ Args.unbindExchange = function(dest, source, pattern, argt) {
129
+ return {
130
+ source,
131
+ destination: dest,
132
+ routingKey: pattern,
133
+ arguments: argt,
134
+ ticket: 0,
135
+ nowait: false
136
+ };
137
+ };
138
+ Args.publish = function(exchange, routingKey, options) {
139
+ options = options || EMPTY_OPTIONS;
140
+ function convertCC(cc) {
141
+ if (cc === void 0) return;
142
+ else if (Array.isArray(cc)) return cc.map(String);
143
+ else return [String(cc)];
144
+ }
145
+ var headers = Object.create(options.headers || null);
146
+ setIfDefined(headers, "CC", convertCC(options.CC));
147
+ setIfDefined(headers, "BCC", convertCC(options.BCC));
148
+ var deliveryMode;
149
+ if (options.persistent !== void 0) deliveryMode = options.persistent ? 2 : 1;
150
+ else if (typeof options.deliveryMode === "number") deliveryMode = options.deliveryMode;
151
+ else if (options.deliveryMode) deliveryMode = 2;
152
+ var expiration = options.expiration;
153
+ if (expiration !== void 0) expiration = expiration.toString();
154
+ return {
155
+ exchange,
156
+ routingKey,
157
+ mandatory: !!options.mandatory,
158
+ immediate: false,
159
+ ticket: void 0,
160
+ contentType: options.contentType,
161
+ contentEncoding: options.contentEncoding,
162
+ headers,
163
+ deliveryMode,
164
+ priority: options.priority,
165
+ correlationId: options.correlationId,
166
+ replyTo: options.replyTo,
167
+ expiration,
168
+ messageId: options.messageId,
169
+ timestamp: options.timestamp,
170
+ type: options.type,
171
+ userId: options.userId,
172
+ appId: options.appId,
173
+ clusterId: void 0
174
+ };
175
+ };
176
+ Args.consume = function(queue, options) {
177
+ options = options || EMPTY_OPTIONS;
178
+ var argt = Object.create(options.arguments || null);
179
+ setIfDefined(argt, "x-priority", options.priority);
180
+ return {
181
+ ticket: 0,
182
+ queue,
183
+ consumerTag: options.consumerTag || "",
184
+ noLocal: !!options.noLocal,
185
+ noAck: !!options.noAck,
186
+ exclusive: !!options.exclusive,
187
+ nowait: false,
188
+ arguments: argt
189
+ };
190
+ };
191
+ Args.cancel = function(consumerTag) {
192
+ return {
193
+ consumerTag,
194
+ nowait: false
195
+ };
196
+ };
197
+ Args.get = function(queue, options) {
198
+ options = options || EMPTY_OPTIONS;
199
+ return {
200
+ ticket: 0,
201
+ queue,
202
+ noAck: !!options.noAck
203
+ };
204
+ };
205
+ Args.ack = function(tag, allUpTo) {
206
+ return {
207
+ deliveryTag: tag,
208
+ multiple: !!allUpTo
209
+ };
210
+ };
211
+ Args.nack = function(tag, allUpTo, requeue) {
212
+ return {
213
+ deliveryTag: tag,
214
+ multiple: !!allUpTo,
215
+ requeue: requeue === void 0 ? true : requeue
216
+ };
217
+ };
218
+ Args.reject = function(tag, requeue) {
219
+ return {
220
+ deliveryTag: tag,
221
+ requeue: requeue === void 0 ? true : requeue
222
+ };
223
+ };
224
+ Args.prefetch = function(count, global) {
225
+ return {
226
+ prefetchCount: count || 0,
227
+ prefetchSize: 0,
228
+ global: !!global
229
+ };
230
+ };
231
+ Args.recover = function() {
232
+ return { requeue: true };
233
+ };
234
+ module.exports = Object.freeze(Args);
235
+ }));
236
+
237
+ //#endregion
238
+ export default require_api_args();
239
+
240
+ export { require_api_args };
241
+ //# sourceMappingURL=api_args.mjs.map