@warlock.js/seal 4.0.157 → 4.0.161

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 (805) hide show
  1. package/package.json +1 -1
  2. package/cjs/config.d.ts +0 -48
  3. package/cjs/config.d.ts.map +0 -1
  4. package/cjs/config.js +0 -42
  5. package/cjs/config.js.map +0 -1
  6. package/cjs/factory/index.d.ts +0 -3
  7. package/cjs/factory/index.d.ts.map +0 -1
  8. package/cjs/factory/validate.d.ts +0 -8
  9. package/cjs/factory/validate.d.ts.map +0 -1
  10. package/cjs/factory/validate.js +0 -23
  11. package/cjs/factory/validate.js.map +0 -1
  12. package/cjs/factory/validators.d.ts +0 -56
  13. package/cjs/factory/validators.d.ts.map +0 -1
  14. package/cjs/factory/validators.js +0 -45
  15. package/cjs/factory/validators.js.map +0 -1
  16. package/cjs/helpers/date-helpers.d.ts +0 -16
  17. package/cjs/helpers/date-helpers.d.ts.map +0 -1
  18. package/cjs/helpers/date-helpers.js +0 -20
  19. package/cjs/helpers/date-helpers.js.map +0 -1
  20. package/cjs/helpers/file.utils.d.ts +0 -8
  21. package/cjs/helpers/file.utils.d.ts.map +0 -1
  22. package/cjs/helpers/file.utils.js +0 -29
  23. package/cjs/helpers/file.utils.js.map +0 -1
  24. package/cjs/helpers/get-field-value.d.ts +0 -37
  25. package/cjs/helpers/get-field-value.d.ts.map +0 -1
  26. package/cjs/helpers/get-field-value.js +0 -40
  27. package/cjs/helpers/get-field-value.js.map +0 -1
  28. package/cjs/helpers/index.d.ts +0 -6
  29. package/cjs/helpers/index.d.ts.map +0 -1
  30. package/cjs/helpers/is-empty-value.d.ts +0 -2
  31. package/cjs/helpers/is-empty-value.d.ts.map +0 -1
  32. package/cjs/helpers/is-empty-value.js +0 -3
  33. package/cjs/helpers/is-empty-value.js.map +0 -1
  34. package/cjs/helpers/path-helpers.d.ts +0 -5
  35. package/cjs/helpers/path-helpers.d.ts.map +0 -1
  36. package/cjs/helpers/path-helpers.js +0 -8
  37. package/cjs/helpers/path-helpers.js.map +0 -1
  38. package/cjs/helpers/validation-helpers.d.ts +0 -26
  39. package/cjs/helpers/validation-helpers.d.ts.map +0 -1
  40. package/cjs/helpers/validation-helpers.js +0 -74
  41. package/cjs/helpers/validation-helpers.js.map +0 -1
  42. package/cjs/index.d.ts +0 -30
  43. package/cjs/index.d.ts.map +0 -1
  44. package/cjs/index.js +0 -1
  45. package/cjs/index.js.map +0 -1
  46. package/cjs/mutators/array-mutators.d.ts +0 -12
  47. package/cjs/mutators/array-mutators.d.ts.map +0 -1
  48. package/cjs/mutators/array-mutators.js +0 -37
  49. package/cjs/mutators/array-mutators.js.map +0 -1
  50. package/cjs/mutators/date-mutators.d.ts +0 -39
  51. package/cjs/mutators/date-mutators.d.ts.map +0 -1
  52. package/cjs/mutators/date-mutators.js +0 -120
  53. package/cjs/mutators/date-mutators.js.map +0 -1
  54. package/cjs/mutators/index.d.ts +0 -7
  55. package/cjs/mutators/index.d.ts.map +0 -1
  56. package/cjs/mutators/number-mutators.d.ts +0 -22
  57. package/cjs/mutators/number-mutators.d.ts.map +0 -1
  58. package/cjs/mutators/number-mutators.js +0 -53
  59. package/cjs/mutators/number-mutators.js.map +0 -1
  60. package/cjs/mutators/object-mutators.d.ts +0 -8
  61. package/cjs/mutators/object-mutators.d.ts.map +0 -1
  62. package/cjs/mutators/object-mutators.js +0 -48
  63. package/cjs/mutators/object-mutators.js.map +0 -1
  64. package/cjs/mutators/scalar-mutators.d.ts +0 -3
  65. package/cjs/mutators/scalar-mutators.d.ts.map +0 -1
  66. package/cjs/mutators/scalar-mutators.js +0 -6
  67. package/cjs/mutators/scalar-mutators.js.map +0 -1
  68. package/cjs/mutators/string-mutators.d.ts +0 -72
  69. package/cjs/mutators/string-mutators.d.ts.map +0 -1
  70. package/cjs/mutators/string-mutators.js +0 -193
  71. package/cjs/mutators/string-mutators.js.map +0 -1
  72. package/cjs/plugins/index.d.ts +0 -7
  73. package/cjs/plugins/index.d.ts.map +0 -1
  74. package/cjs/plugins/plugin-system.d.ts +0 -71
  75. package/cjs/plugins/plugin-system.d.ts.map +0 -1
  76. package/cjs/plugins/plugin-system.js +0 -67
  77. package/cjs/plugins/plugin-system.js.map +0 -1
  78. package/cjs/rules/array/array-rules.d.ts +0 -12
  79. package/cjs/rules/array/array-rules.d.ts.map +0 -1
  80. package/cjs/rules/array/array-rules.js +0 -45
  81. package/cjs/rules/array/array-rules.js.map +0 -1
  82. package/cjs/rules/array/index.d.ts +0 -2
  83. package/cjs/rules/array/index.d.ts.map +0 -1
  84. package/cjs/rules/color/color-rules.d.ts +0 -30
  85. package/cjs/rules/color/color-rules.d.ts.map +0 -1
  86. package/cjs/rules/color/color-rules.js +0 -120
  87. package/cjs/rules/color/color-rules.js.map +0 -1
  88. package/cjs/rules/color/index.d.ts +0 -2
  89. package/cjs/rules/color/index.d.ts.map +0 -1
  90. package/cjs/rules/common/enum.d.ts +0 -26
  91. package/cjs/rules/common/enum.d.ts.map +0 -1
  92. package/cjs/rules/common/enum.js +0 -69
  93. package/cjs/rules/common/enum.js.map +0 -1
  94. package/cjs/rules/common/equals-field-rules.d.ts +0 -18
  95. package/cjs/rules/common/equals-field-rules.d.ts.map +0 -1
  96. package/cjs/rules/common/equals-field-rules.js +0 -39
  97. package/cjs/rules/common/equals-field-rules.js.map +0 -1
  98. package/cjs/rules/common/index.d.ts +0 -5
  99. package/cjs/rules/common/index.d.ts.map +0 -1
  100. package/cjs/rules/common/type-rules.d.ts +0 -38
  101. package/cjs/rules/common/type-rules.d.ts.map +0 -1
  102. package/cjs/rules/common/type-rules.js +0 -117
  103. package/cjs/rules/common/type-rules.js.map +0 -1
  104. package/cjs/rules/common/unknown-key.d.ts +0 -9
  105. package/cjs/rules/common/unknown-key.d.ts.map +0 -1
  106. package/cjs/rules/common/unknown-key.js +0 -17
  107. package/cjs/rules/common/unknown-key.js.map +0 -1
  108. package/cjs/rules/conditional/forbidden-if-rules.d.ts +0 -54
  109. package/cjs/rules/conditional/forbidden-if-rules.d.ts.map +0 -1
  110. package/cjs/rules/conditional/forbidden-if-rules.js +0 -118
  111. package/cjs/rules/conditional/forbidden-if-rules.js.map +0 -1
  112. package/cjs/rules/conditional/index.d.ts +0 -11
  113. package/cjs/rules/conditional/index.d.ts.map +0 -1
  114. package/cjs/rules/conditional/present-if-rules.d.ts +0 -45
  115. package/cjs/rules/conditional/present-if-rules.d.ts.map +0 -1
  116. package/cjs/rules/conditional/present-if-rules.js +0 -100
  117. package/cjs/rules/conditional/present-if-rules.js.map +0 -1
  118. package/cjs/rules/conditional/present-unless-rules.d.ts +0 -11
  119. package/cjs/rules/conditional/present-unless-rules.d.ts.map +0 -1
  120. package/cjs/rules/conditional/present-unless-rules.js +0 -22
  121. package/cjs/rules/conditional/present-unless-rules.js.map +0 -1
  122. package/cjs/rules/conditional/present-with-rules.d.ts +0 -26
  123. package/cjs/rules/conditional/present-with-rules.d.ts.map +0 -1
  124. package/cjs/rules/conditional/present-with-rules.js +0 -70
  125. package/cjs/rules/conditional/present-with-rules.js.map +0 -1
  126. package/cjs/rules/conditional/present-without-rules.d.ts +0 -26
  127. package/cjs/rules/conditional/present-without-rules.d.ts.map +0 -1
  128. package/cjs/rules/conditional/present-without-rules.js +0 -70
  129. package/cjs/rules/conditional/present-without-rules.js.map +0 -1
  130. package/cjs/rules/conditional/required-if-rules.d.ts +0 -77
  131. package/cjs/rules/conditional/required-if-rules.d.ts.map +0 -1
  132. package/cjs/rules/conditional/required-if-rules.js +0 -205
  133. package/cjs/rules/conditional/required-if-rules.js.map +0 -1
  134. package/cjs/rules/conditional/required-unless-rules.d.ts +0 -11
  135. package/cjs/rules/conditional/required-unless-rules.d.ts.map +0 -1
  136. package/cjs/rules/conditional/required-unless-rules.js +0 -22
  137. package/cjs/rules/conditional/required-unless-rules.js.map +0 -1
  138. package/cjs/rules/conditional/required-when-rule.d.ts +0 -18
  139. package/cjs/rules/conditional/required-when-rule.d.ts.map +0 -1
  140. package/cjs/rules/conditional/required-when-rule.js +0 -26
  141. package/cjs/rules/conditional/required-when-rule.js.map +0 -1
  142. package/cjs/rules/conditional/required-with-rules.d.ts +0 -26
  143. package/cjs/rules/conditional/required-with-rules.d.ts.map +0 -1
  144. package/cjs/rules/conditional/required-with-rules.js +0 -64
  145. package/cjs/rules/conditional/required-with-rules.js.map +0 -1
  146. package/cjs/rules/conditional/required-without-rules.d.ts +0 -26
  147. package/cjs/rules/conditional/required-without-rules.d.ts.map +0 -1
  148. package/cjs/rules/conditional/required-without-rules.js +0 -64
  149. package/cjs/rules/conditional/required-without-rules.js.map +0 -1
  150. package/cjs/rules/core/equal.d.ts +0 -8
  151. package/cjs/rules/core/equal.d.ts.map +0 -1
  152. package/cjs/rules/core/equal.js +0 -14
  153. package/cjs/rules/core/equal.js.map +0 -1
  154. package/cjs/rules/core/forbidden.d.ts +0 -6
  155. package/cjs/rules/core/forbidden.d.ts.map +0 -1
  156. package/cjs/rules/core/forbidden.js +0 -13
  157. package/cjs/rules/core/forbidden.js.map +0 -1
  158. package/cjs/rules/core/index.d.ts +0 -6
  159. package/cjs/rules/core/index.d.ts.map +0 -1
  160. package/cjs/rules/core/required.d.ts +0 -11
  161. package/cjs/rules/core/required.d.ts.map +0 -1
  162. package/cjs/rules/core/required.js +0 -31
  163. package/cjs/rules/core/required.js.map +0 -1
  164. package/cjs/rules/core/union.d.ts +0 -9
  165. package/cjs/rules/core/union.d.ts.map +0 -1
  166. package/cjs/rules/core/union.js +0 -40
  167. package/cjs/rules/core/union.js.map +0 -1
  168. package/cjs/rules/core/when.d.ts +0 -6
  169. package/cjs/rules/core/when.d.ts.map +0 -1
  170. package/cjs/rules/core/when.js +0 -40
  171. package/cjs/rules/core/when.js.map +0 -1
  172. package/cjs/rules/date/date-comparison-rules.d.ts +0 -25
  173. package/cjs/rules/date/date-comparison-rules.d.ts.map +0 -1
  174. package/cjs/rules/date/date-comparison-rules.js +0 -80
  175. package/cjs/rules/date/date-comparison-rules.js.map +0 -1
  176. package/cjs/rules/date/date-day-rules.d.ts +0 -21
  177. package/cjs/rules/date/date-day-rules.d.ts.map +0 -1
  178. package/cjs/rules/date/date-day-rules.js +0 -68
  179. package/cjs/rules/date/date-day-rules.js.map +0 -1
  180. package/cjs/rules/date/date-field-comparison-rules.d.ts +0 -28
  181. package/cjs/rules/date/date-field-comparison-rules.d.ts.map +0 -1
  182. package/cjs/rules/date/date-field-comparison-rules.js +0 -94
  183. package/cjs/rules/date/date-field-comparison-rules.js.map +0 -1
  184. package/cjs/rules/date/date-period-rules.d.ts +0 -124
  185. package/cjs/rules/date/date-period-rules.d.ts.map +0 -1
  186. package/cjs/rules/date/date-period-rules.js +0 -605
  187. package/cjs/rules/date/date-period-rules.js.map +0 -1
  188. package/cjs/rules/date/date-relative-rules.d.ts +0 -20
  189. package/cjs/rules/date/date-relative-rules.d.ts.map +0 -1
  190. package/cjs/rules/date/date-relative-rules.js +0 -60
  191. package/cjs/rules/date/date-relative-rules.js.map +0 -1
  192. package/cjs/rules/date/date-special-rules.d.ts +0 -20
  193. package/cjs/rules/date/date-special-rules.d.ts.map +0 -1
  194. package/cjs/rules/date/date-special-rules.js +0 -71
  195. package/cjs/rules/date/date-special-rules.js.map +0 -1
  196. package/cjs/rules/date/date.d.ts +0 -93
  197. package/cjs/rules/date/date.d.ts.map +0 -1
  198. package/cjs/rules/date/date.js +0 -288
  199. package/cjs/rules/date/date.js.map +0 -1
  200. package/cjs/rules/date/index.d.ts +0 -8
  201. package/cjs/rules/date/index.d.ts.map +0 -1
  202. package/cjs/rules/file/dimensions.d.ts +0 -26
  203. package/cjs/rules/file/dimensions.d.ts.map +0 -1
  204. package/cjs/rules/file/dimensions.js +0 -60
  205. package/cjs/rules/file/dimensions.js.map +0 -1
  206. package/cjs/rules/file/file-size.d.ts +0 -14
  207. package/cjs/rules/file/file-size.d.ts.map +0 -1
  208. package/cjs/rules/file/file-size.js +0 -30
  209. package/cjs/rules/file/file-size.js.map +0 -1
  210. package/cjs/rules/file/index.d.ts +0 -11
  211. package/cjs/rules/file/index.d.ts.map +0 -1
  212. package/cjs/rules/index.d.ts +0 -19
  213. package/cjs/rules/index.d.ts.map +0 -1
  214. package/cjs/rules/length/index.d.ts +0 -2
  215. package/cjs/rules/length/index.d.ts.map +0 -1
  216. package/cjs/rules/length/length-rules.d.ts +0 -49
  217. package/cjs/rules/length/length-rules.d.ts.map +0 -1
  218. package/cjs/rules/length/length-rules.js +0 -107
  219. package/cjs/rules/length/length-rules.js.map +0 -1
  220. package/cjs/rules/number/index.d.ts +0 -2
  221. package/cjs/rules/number/index.d.ts.map +0 -1
  222. package/cjs/rules/number/number-rules.d.ts +0 -65
  223. package/cjs/rules/number/number-rules.d.ts.map +0 -1
  224. package/cjs/rules/number/number-rules.js +0 -245
  225. package/cjs/rules/number/number-rules.js.map +0 -1
  226. package/cjs/rules/scalar/accepted-rule.d.ts +0 -39
  227. package/cjs/rules/scalar/accepted-rule.d.ts.map +0 -1
  228. package/cjs/rules/scalar/accepted-rule.js +0 -117
  229. package/cjs/rules/scalar/accepted-rule.js.map +0 -1
  230. package/cjs/rules/scalar/declined-rule.d.ts +0 -39
  231. package/cjs/rules/scalar/declined-rule.d.ts.map +0 -1
  232. package/cjs/rules/scalar/declined-rule.js +0 -117
  233. package/cjs/rules/scalar/declined-rule.js.map +0 -1
  234. package/cjs/rules/scalar/index.d.ts +0 -3
  235. package/cjs/rules/scalar/index.d.ts.map +0 -1
  236. package/cjs/rules/string/alpha.d.ts +0 -14
  237. package/cjs/rules/string/alpha.d.ts.map +0 -1
  238. package/cjs/rules/string/alpha.js +0 -39
  239. package/cjs/rules/string/alpha.js.map +0 -1
  240. package/cjs/rules/string/credit-card.d.ts +0 -6
  241. package/cjs/rules/string/credit-card.d.ts.map +0 -1
  242. package/cjs/rules/string/credit-card.js +0 -31
  243. package/cjs/rules/string/credit-card.js.map +0 -1
  244. package/cjs/rules/string/email.d.ts +0 -6
  245. package/cjs/rules/string/email.d.ts.map +0 -1
  246. package/cjs/rules/string/email.js +0 -13
  247. package/cjs/rules/string/email.js.map +0 -1
  248. package/cjs/rules/string/index.d.ts +0 -17
  249. package/cjs/rules/string/index.d.ts.map +0 -1
  250. package/cjs/rules/string/ip.d.ts +0 -14
  251. package/cjs/rules/string/ip.d.ts.map +0 -1
  252. package/cjs/rules/string/ip.js +0 -39
  253. package/cjs/rules/string/ip.js.map +0 -1
  254. package/cjs/rules/string/matches.d.ts +0 -8
  255. package/cjs/rules/string/matches.d.ts.map +0 -1
  256. package/cjs/rules/string/matches.js +0 -15
  257. package/cjs/rules/string/matches.js.map +0 -1
  258. package/cjs/rules/string/pattern.d.ts +0 -8
  259. package/cjs/rules/string/pattern.d.ts.map +0 -1
  260. package/cjs/rules/string/pattern.js +0 -14
  261. package/cjs/rules/string/pattern.js.map +0 -1
  262. package/cjs/rules/string/string-comparison.d.ts +0 -26
  263. package/cjs/rules/string/string-comparison.d.ts.map +0 -1
  264. package/cjs/rules/string/string-comparison.js +0 -56
  265. package/cjs/rules/string/string-comparison.js.map +0 -1
  266. package/cjs/rules/string/strong-password-rule.d.ts +0 -14
  267. package/cjs/rules/string/strong-password-rule.d.ts.map +0 -1
  268. package/cjs/rules/string/strong-password-rule.js +0 -38
  269. package/cjs/rules/string/strong-password-rule.js.map +0 -1
  270. package/cjs/rules/string/url.d.ts +0 -6
  271. package/cjs/rules/string/url.d.ts.map +0 -1
  272. package/cjs/rules/string/url.js +0 -16
  273. package/cjs/rules/string/url.js.map +0 -1
  274. package/cjs/rules/string/without-whitespace.d.ts +0 -6
  275. package/cjs/rules/string/without-whitespace.d.ts.map +0 -1
  276. package/cjs/rules/string/without-whitespace.js +0 -13
  277. package/cjs/rules/string/without-whitespace.js.map +0 -1
  278. package/cjs/standard-schema/index.d.ts +0 -4
  279. package/cjs/standard-schema/index.d.ts.map +0 -1
  280. package/cjs/standard-schema/json-schema.d.ts +0 -61
  281. package/cjs/standard-schema/json-schema.d.ts.map +0 -1
  282. package/cjs/standard-schema/json-schema.js +0 -85
  283. package/cjs/standard-schema/json-schema.js.map +0 -1
  284. package/cjs/standard-schema/map-result.d.ts +0 -18
  285. package/cjs/standard-schema/map-result.d.ts.map +0 -1
  286. package/cjs/standard-schema/map-result.js +0 -27
  287. package/cjs/standard-schema/map-result.js.map +0 -1
  288. package/cjs/standard-schema/types.d.ts +0 -93
  289. package/cjs/standard-schema/types.d.ts.map +0 -1
  290. package/cjs/types/conditional-types.d.ts +0 -15
  291. package/cjs/types/conditional-types.d.ts.map +0 -1
  292. package/cjs/types/context-types.d.ts +0 -47
  293. package/cjs/types/context-types.d.ts.map +0 -1
  294. package/cjs/types/data-transformer-types.d.ts +0 -25
  295. package/cjs/types/data-transformer-types.d.ts.map +0 -1
  296. package/cjs/types/date-types.d.ts +0 -9
  297. package/cjs/types/date-types.d.ts.map +0 -1
  298. package/cjs/types/date-types.js +0 -12
  299. package/cjs/types/date-types.js.map +0 -1
  300. package/cjs/types/file.types.d.ts +0 -5
  301. package/cjs/types/file.types.d.ts.map +0 -1
  302. package/cjs/types/index.d.ts +0 -11
  303. package/cjs/types/index.d.ts.map +0 -1
  304. package/cjs/types/inference-types.d.ts +0 -32
  305. package/cjs/types/inference-types.d.ts.map +0 -1
  306. package/cjs/types/mutator-types.d.ts +0 -27
  307. package/cjs/types/mutator-types.d.ts.map +0 -1
  308. package/cjs/types/result-types.d.ts +0 -19
  309. package/cjs/types/result-types.d.ts.map +0 -1
  310. package/cjs/types/rule-types.d.ts +0 -58
  311. package/cjs/types/rule-types.d.ts.map +0 -1
  312. package/cjs/types/schema-types.d.ts +0 -6
  313. package/cjs/types/schema-types.d.ts.map +0 -1
  314. package/cjs/validators/any-validator.d.ts +0 -29
  315. package/cjs/validators/any-validator.d.ts.map +0 -1
  316. package/cjs/validators/any-validator.js +0 -31
  317. package/cjs/validators/any-validator.js.map +0 -1
  318. package/cjs/validators/array-validator.d.ts +0 -72
  319. package/cjs/validators/array-validator.d.ts.map +0 -1
  320. package/cjs/validators/array-validator.js +0 -162
  321. package/cjs/validators/array-validator.js.map +0 -1
  322. package/cjs/validators/base-validator.d.ts +0 -425
  323. package/cjs/validators/base-validator.d.ts.map +0 -1
  324. package/cjs/validators/base-validator.js +0 -637
  325. package/cjs/validators/base-validator.js.map +0 -1
  326. package/cjs/validators/boolean-validator.d.ts +0 -67
  327. package/cjs/validators/boolean-validator.d.ts.map +0 -1
  328. package/cjs/validators/boolean-validator.js +0 -105
  329. package/cjs/validators/boolean-validator.js.map +0 -1
  330. package/cjs/validators/computed-validator.d.ts +0 -75
  331. package/cjs/validators/computed-validator.d.ts.map +0 -1
  332. package/cjs/validators/computed-validator.js +0 -124
  333. package/cjs/validators/computed-validator.js.map +0 -1
  334. package/cjs/validators/date-validator.d.ts +0 -330
  335. package/cjs/validators/date-validator.d.ts.map +0 -1
  336. package/cjs/validators/date-validator.js +0 -614
  337. package/cjs/validators/date-validator.js.map +0 -1
  338. package/cjs/validators/float-validator.d.ts +0 -8
  339. package/cjs/validators/float-validator.d.ts.map +0 -1
  340. package/cjs/validators/float-validator.js +0 -9
  341. package/cjs/validators/float-validator.js.map +0 -1
  342. package/cjs/validators/index.d.ts +0 -31
  343. package/cjs/validators/index.d.ts.map +0 -1
  344. package/cjs/validators/int-validator.d.ts +0 -19
  345. package/cjs/validators/int-validator.d.ts.map +0 -1
  346. package/cjs/validators/int-validator.js +0 -21
  347. package/cjs/validators/int-validator.js.map +0 -1
  348. package/cjs/validators/managed-validator.d.ts +0 -38
  349. package/cjs/validators/managed-validator.d.ts.map +0 -1
  350. package/cjs/validators/managed-validator.js +0 -34
  351. package/cjs/validators/managed-validator.js.map +0 -1
  352. package/cjs/validators/methods/equality-conditional-methods.d.ts +0 -88
  353. package/cjs/validators/methods/equality-conditional-methods.d.ts.map +0 -1
  354. package/cjs/validators/methods/equality-conditional-methods.js +0 -118
  355. package/cjs/validators/methods/equality-conditional-methods.js.map +0 -1
  356. package/cjs/validators/methods/forbidden-methods.d.ts +0 -58
  357. package/cjs/validators/methods/forbidden-methods.d.ts.map +0 -1
  358. package/cjs/validators/methods/forbidden-methods.js +0 -122
  359. package/cjs/validators/methods/forbidden-methods.js.map +0 -1
  360. package/cjs/validators/methods/present-methods.d.ts +0 -102
  361. package/cjs/validators/methods/present-methods.d.ts.map +0 -1
  362. package/cjs/validators/methods/present-methods.js +0 -229
  363. package/cjs/validators/methods/present-methods.js.map +0 -1
  364. package/cjs/validators/methods/required-methods.d.ts +0 -174
  365. package/cjs/validators/methods/required-methods.d.ts.map +0 -1
  366. package/cjs/validators/methods/required-methods.js +0 -246
  367. package/cjs/validators/methods/required-methods.js.map +0 -1
  368. package/cjs/validators/number-validator.d.ts +0 -166
  369. package/cjs/validators/number-validator.d.ts.map +0 -1
  370. package/cjs/validators/number-validator.js +0 -307
  371. package/cjs/validators/number-validator.js.map +0 -1
  372. package/cjs/validators/numeric-validator.d.ts +0 -15
  373. package/cjs/validators/numeric-validator.d.ts.map +0 -1
  374. package/cjs/validators/numeric-validator.js +0 -18
  375. package/cjs/validators/numeric-validator.js.map +0 -1
  376. package/cjs/validators/object-validator.d.ts +0 -233
  377. package/cjs/validators/object-validator.d.ts.map +0 -1
  378. package/cjs/validators/object-validator.js +0 -517
  379. package/cjs/validators/object-validator.js.map +0 -1
  380. package/cjs/validators/primitive-validator.d.ts +0 -70
  381. package/cjs/validators/primitive-validator.d.ts.map +0 -1
  382. package/cjs/validators/primitive-validator.js +0 -80
  383. package/cjs/validators/primitive-validator.js.map +0 -1
  384. package/cjs/validators/record-validator.d.ts +0 -54
  385. package/cjs/validators/record-validator.d.ts.map +0 -1
  386. package/cjs/validators/record-validator.js +0 -100
  387. package/cjs/validators/record-validator.js.map +0 -1
  388. package/cjs/validators/scalar-validator.d.ts +0 -93
  389. package/cjs/validators/scalar-validator.d.ts.map +0 -1
  390. package/cjs/validators/scalar-validator.js +0 -149
  391. package/cjs/validators/scalar-validator.js.map +0 -1
  392. package/cjs/validators/string-validator.d.ts +0 -189
  393. package/cjs/validators/string-validator.d.ts.map +0 -1
  394. package/cjs/validators/string-validator.js +0 -387
  395. package/cjs/validators/string-validator.js.map +0 -1
  396. package/cjs/validators/tuple-validator.d.ts +0 -56
  397. package/cjs/validators/tuple-validator.d.ts.map +0 -1
  398. package/cjs/validators/tuple-validator.js +0 -121
  399. package/cjs/validators/tuple-validator.js.map +0 -1
  400. package/cjs/validators/union-validator.d.ts +0 -55
  401. package/cjs/validators/union-validator.d.ts.map +0 -1
  402. package/cjs/validators/union-validator.js +0 -60
  403. package/cjs/validators/union-validator.js.map +0 -1
  404. package/esm/config.d.ts +0 -48
  405. package/esm/config.d.ts.map +0 -1
  406. package/esm/config.js +0 -42
  407. package/esm/config.js.map +0 -1
  408. package/esm/factory/index.d.ts +0 -3
  409. package/esm/factory/index.d.ts.map +0 -1
  410. package/esm/factory/validate.d.ts +0 -8
  411. package/esm/factory/validate.d.ts.map +0 -1
  412. package/esm/factory/validate.js +0 -23
  413. package/esm/factory/validate.js.map +0 -1
  414. package/esm/factory/validators.d.ts +0 -56
  415. package/esm/factory/validators.d.ts.map +0 -1
  416. package/esm/factory/validators.js +0 -45
  417. package/esm/factory/validators.js.map +0 -1
  418. package/esm/helpers/date-helpers.d.ts +0 -16
  419. package/esm/helpers/date-helpers.d.ts.map +0 -1
  420. package/esm/helpers/date-helpers.js +0 -20
  421. package/esm/helpers/date-helpers.js.map +0 -1
  422. package/esm/helpers/file.utils.d.ts +0 -8
  423. package/esm/helpers/file.utils.d.ts.map +0 -1
  424. package/esm/helpers/file.utils.js +0 -29
  425. package/esm/helpers/file.utils.js.map +0 -1
  426. package/esm/helpers/get-field-value.d.ts +0 -37
  427. package/esm/helpers/get-field-value.d.ts.map +0 -1
  428. package/esm/helpers/get-field-value.js +0 -40
  429. package/esm/helpers/get-field-value.js.map +0 -1
  430. package/esm/helpers/index.d.ts +0 -6
  431. package/esm/helpers/index.d.ts.map +0 -1
  432. package/esm/helpers/is-empty-value.d.ts +0 -2
  433. package/esm/helpers/is-empty-value.d.ts.map +0 -1
  434. package/esm/helpers/is-empty-value.js +0 -3
  435. package/esm/helpers/is-empty-value.js.map +0 -1
  436. package/esm/helpers/path-helpers.d.ts +0 -5
  437. package/esm/helpers/path-helpers.d.ts.map +0 -1
  438. package/esm/helpers/path-helpers.js +0 -8
  439. package/esm/helpers/path-helpers.js.map +0 -1
  440. package/esm/helpers/validation-helpers.d.ts +0 -26
  441. package/esm/helpers/validation-helpers.d.ts.map +0 -1
  442. package/esm/helpers/validation-helpers.js +0 -74
  443. package/esm/helpers/validation-helpers.js.map +0 -1
  444. package/esm/index.d.ts +0 -30
  445. package/esm/index.d.ts.map +0 -1
  446. package/esm/index.js +0 -1
  447. package/esm/index.js.map +0 -1
  448. package/esm/mutators/array-mutators.d.ts +0 -12
  449. package/esm/mutators/array-mutators.d.ts.map +0 -1
  450. package/esm/mutators/array-mutators.js +0 -37
  451. package/esm/mutators/array-mutators.js.map +0 -1
  452. package/esm/mutators/date-mutators.d.ts +0 -39
  453. package/esm/mutators/date-mutators.d.ts.map +0 -1
  454. package/esm/mutators/date-mutators.js +0 -120
  455. package/esm/mutators/date-mutators.js.map +0 -1
  456. package/esm/mutators/index.d.ts +0 -7
  457. package/esm/mutators/index.d.ts.map +0 -1
  458. package/esm/mutators/number-mutators.d.ts +0 -22
  459. package/esm/mutators/number-mutators.d.ts.map +0 -1
  460. package/esm/mutators/number-mutators.js +0 -53
  461. package/esm/mutators/number-mutators.js.map +0 -1
  462. package/esm/mutators/object-mutators.d.ts +0 -8
  463. package/esm/mutators/object-mutators.d.ts.map +0 -1
  464. package/esm/mutators/object-mutators.js +0 -48
  465. package/esm/mutators/object-mutators.js.map +0 -1
  466. package/esm/mutators/scalar-mutators.d.ts +0 -3
  467. package/esm/mutators/scalar-mutators.d.ts.map +0 -1
  468. package/esm/mutators/scalar-mutators.js +0 -6
  469. package/esm/mutators/scalar-mutators.js.map +0 -1
  470. package/esm/mutators/string-mutators.d.ts +0 -72
  471. package/esm/mutators/string-mutators.d.ts.map +0 -1
  472. package/esm/mutators/string-mutators.js +0 -193
  473. package/esm/mutators/string-mutators.js.map +0 -1
  474. package/esm/plugins/index.d.ts +0 -7
  475. package/esm/plugins/index.d.ts.map +0 -1
  476. package/esm/plugins/plugin-system.d.ts +0 -71
  477. package/esm/plugins/plugin-system.d.ts.map +0 -1
  478. package/esm/plugins/plugin-system.js +0 -67
  479. package/esm/plugins/plugin-system.js.map +0 -1
  480. package/esm/rules/array/array-rules.d.ts +0 -12
  481. package/esm/rules/array/array-rules.d.ts.map +0 -1
  482. package/esm/rules/array/array-rules.js +0 -45
  483. package/esm/rules/array/array-rules.js.map +0 -1
  484. package/esm/rules/array/index.d.ts +0 -2
  485. package/esm/rules/array/index.d.ts.map +0 -1
  486. package/esm/rules/color/color-rules.d.ts +0 -30
  487. package/esm/rules/color/color-rules.d.ts.map +0 -1
  488. package/esm/rules/color/color-rules.js +0 -120
  489. package/esm/rules/color/color-rules.js.map +0 -1
  490. package/esm/rules/color/index.d.ts +0 -2
  491. package/esm/rules/color/index.d.ts.map +0 -1
  492. package/esm/rules/common/enum.d.ts +0 -26
  493. package/esm/rules/common/enum.d.ts.map +0 -1
  494. package/esm/rules/common/enum.js +0 -69
  495. package/esm/rules/common/enum.js.map +0 -1
  496. package/esm/rules/common/equals-field-rules.d.ts +0 -18
  497. package/esm/rules/common/equals-field-rules.d.ts.map +0 -1
  498. package/esm/rules/common/equals-field-rules.js +0 -39
  499. package/esm/rules/common/equals-field-rules.js.map +0 -1
  500. package/esm/rules/common/index.d.ts +0 -5
  501. package/esm/rules/common/index.d.ts.map +0 -1
  502. package/esm/rules/common/type-rules.d.ts +0 -38
  503. package/esm/rules/common/type-rules.d.ts.map +0 -1
  504. package/esm/rules/common/type-rules.js +0 -117
  505. package/esm/rules/common/type-rules.js.map +0 -1
  506. package/esm/rules/common/unknown-key.d.ts +0 -9
  507. package/esm/rules/common/unknown-key.d.ts.map +0 -1
  508. package/esm/rules/common/unknown-key.js +0 -17
  509. package/esm/rules/common/unknown-key.js.map +0 -1
  510. package/esm/rules/conditional/forbidden-if-rules.d.ts +0 -54
  511. package/esm/rules/conditional/forbidden-if-rules.d.ts.map +0 -1
  512. package/esm/rules/conditional/forbidden-if-rules.js +0 -118
  513. package/esm/rules/conditional/forbidden-if-rules.js.map +0 -1
  514. package/esm/rules/conditional/index.d.ts +0 -11
  515. package/esm/rules/conditional/index.d.ts.map +0 -1
  516. package/esm/rules/conditional/present-if-rules.d.ts +0 -45
  517. package/esm/rules/conditional/present-if-rules.d.ts.map +0 -1
  518. package/esm/rules/conditional/present-if-rules.js +0 -100
  519. package/esm/rules/conditional/present-if-rules.js.map +0 -1
  520. package/esm/rules/conditional/present-unless-rules.d.ts +0 -11
  521. package/esm/rules/conditional/present-unless-rules.d.ts.map +0 -1
  522. package/esm/rules/conditional/present-unless-rules.js +0 -22
  523. package/esm/rules/conditional/present-unless-rules.js.map +0 -1
  524. package/esm/rules/conditional/present-with-rules.d.ts +0 -26
  525. package/esm/rules/conditional/present-with-rules.d.ts.map +0 -1
  526. package/esm/rules/conditional/present-with-rules.js +0 -70
  527. package/esm/rules/conditional/present-with-rules.js.map +0 -1
  528. package/esm/rules/conditional/present-without-rules.d.ts +0 -26
  529. package/esm/rules/conditional/present-without-rules.d.ts.map +0 -1
  530. package/esm/rules/conditional/present-without-rules.js +0 -70
  531. package/esm/rules/conditional/present-without-rules.js.map +0 -1
  532. package/esm/rules/conditional/required-if-rules.d.ts +0 -77
  533. package/esm/rules/conditional/required-if-rules.d.ts.map +0 -1
  534. package/esm/rules/conditional/required-if-rules.js +0 -205
  535. package/esm/rules/conditional/required-if-rules.js.map +0 -1
  536. package/esm/rules/conditional/required-unless-rules.d.ts +0 -11
  537. package/esm/rules/conditional/required-unless-rules.d.ts.map +0 -1
  538. package/esm/rules/conditional/required-unless-rules.js +0 -22
  539. package/esm/rules/conditional/required-unless-rules.js.map +0 -1
  540. package/esm/rules/conditional/required-when-rule.d.ts +0 -18
  541. package/esm/rules/conditional/required-when-rule.d.ts.map +0 -1
  542. package/esm/rules/conditional/required-when-rule.js +0 -26
  543. package/esm/rules/conditional/required-when-rule.js.map +0 -1
  544. package/esm/rules/conditional/required-with-rules.d.ts +0 -26
  545. package/esm/rules/conditional/required-with-rules.d.ts.map +0 -1
  546. package/esm/rules/conditional/required-with-rules.js +0 -64
  547. package/esm/rules/conditional/required-with-rules.js.map +0 -1
  548. package/esm/rules/conditional/required-without-rules.d.ts +0 -26
  549. package/esm/rules/conditional/required-without-rules.d.ts.map +0 -1
  550. package/esm/rules/conditional/required-without-rules.js +0 -64
  551. package/esm/rules/conditional/required-without-rules.js.map +0 -1
  552. package/esm/rules/core/equal.d.ts +0 -8
  553. package/esm/rules/core/equal.d.ts.map +0 -1
  554. package/esm/rules/core/equal.js +0 -14
  555. package/esm/rules/core/equal.js.map +0 -1
  556. package/esm/rules/core/forbidden.d.ts +0 -6
  557. package/esm/rules/core/forbidden.d.ts.map +0 -1
  558. package/esm/rules/core/forbidden.js +0 -13
  559. package/esm/rules/core/forbidden.js.map +0 -1
  560. package/esm/rules/core/index.d.ts +0 -6
  561. package/esm/rules/core/index.d.ts.map +0 -1
  562. package/esm/rules/core/required.d.ts +0 -11
  563. package/esm/rules/core/required.d.ts.map +0 -1
  564. package/esm/rules/core/required.js +0 -31
  565. package/esm/rules/core/required.js.map +0 -1
  566. package/esm/rules/core/union.d.ts +0 -9
  567. package/esm/rules/core/union.d.ts.map +0 -1
  568. package/esm/rules/core/union.js +0 -40
  569. package/esm/rules/core/union.js.map +0 -1
  570. package/esm/rules/core/when.d.ts +0 -6
  571. package/esm/rules/core/when.d.ts.map +0 -1
  572. package/esm/rules/core/when.js +0 -40
  573. package/esm/rules/core/when.js.map +0 -1
  574. package/esm/rules/date/date-comparison-rules.d.ts +0 -25
  575. package/esm/rules/date/date-comparison-rules.d.ts.map +0 -1
  576. package/esm/rules/date/date-comparison-rules.js +0 -80
  577. package/esm/rules/date/date-comparison-rules.js.map +0 -1
  578. package/esm/rules/date/date-day-rules.d.ts +0 -21
  579. package/esm/rules/date/date-day-rules.d.ts.map +0 -1
  580. package/esm/rules/date/date-day-rules.js +0 -68
  581. package/esm/rules/date/date-day-rules.js.map +0 -1
  582. package/esm/rules/date/date-field-comparison-rules.d.ts +0 -28
  583. package/esm/rules/date/date-field-comparison-rules.d.ts.map +0 -1
  584. package/esm/rules/date/date-field-comparison-rules.js +0 -94
  585. package/esm/rules/date/date-field-comparison-rules.js.map +0 -1
  586. package/esm/rules/date/date-period-rules.d.ts +0 -124
  587. package/esm/rules/date/date-period-rules.d.ts.map +0 -1
  588. package/esm/rules/date/date-period-rules.js +0 -605
  589. package/esm/rules/date/date-period-rules.js.map +0 -1
  590. package/esm/rules/date/date-relative-rules.d.ts +0 -20
  591. package/esm/rules/date/date-relative-rules.d.ts.map +0 -1
  592. package/esm/rules/date/date-relative-rules.js +0 -60
  593. package/esm/rules/date/date-relative-rules.js.map +0 -1
  594. package/esm/rules/date/date-special-rules.d.ts +0 -20
  595. package/esm/rules/date/date-special-rules.d.ts.map +0 -1
  596. package/esm/rules/date/date-special-rules.js +0 -71
  597. package/esm/rules/date/date-special-rules.js.map +0 -1
  598. package/esm/rules/date/date.d.ts +0 -93
  599. package/esm/rules/date/date.d.ts.map +0 -1
  600. package/esm/rules/date/date.js +0 -288
  601. package/esm/rules/date/date.js.map +0 -1
  602. package/esm/rules/date/index.d.ts +0 -8
  603. package/esm/rules/date/index.d.ts.map +0 -1
  604. package/esm/rules/file/dimensions.d.ts +0 -26
  605. package/esm/rules/file/dimensions.d.ts.map +0 -1
  606. package/esm/rules/file/dimensions.js +0 -60
  607. package/esm/rules/file/dimensions.js.map +0 -1
  608. package/esm/rules/file/file-size.d.ts +0 -14
  609. package/esm/rules/file/file-size.d.ts.map +0 -1
  610. package/esm/rules/file/file-size.js +0 -30
  611. package/esm/rules/file/file-size.js.map +0 -1
  612. package/esm/rules/file/index.d.ts +0 -11
  613. package/esm/rules/file/index.d.ts.map +0 -1
  614. package/esm/rules/index.d.ts +0 -19
  615. package/esm/rules/index.d.ts.map +0 -1
  616. package/esm/rules/length/index.d.ts +0 -2
  617. package/esm/rules/length/index.d.ts.map +0 -1
  618. package/esm/rules/length/length-rules.d.ts +0 -49
  619. package/esm/rules/length/length-rules.d.ts.map +0 -1
  620. package/esm/rules/length/length-rules.js +0 -107
  621. package/esm/rules/length/length-rules.js.map +0 -1
  622. package/esm/rules/number/index.d.ts +0 -2
  623. package/esm/rules/number/index.d.ts.map +0 -1
  624. package/esm/rules/number/number-rules.d.ts +0 -65
  625. package/esm/rules/number/number-rules.d.ts.map +0 -1
  626. package/esm/rules/number/number-rules.js +0 -245
  627. package/esm/rules/number/number-rules.js.map +0 -1
  628. package/esm/rules/scalar/accepted-rule.d.ts +0 -39
  629. package/esm/rules/scalar/accepted-rule.d.ts.map +0 -1
  630. package/esm/rules/scalar/accepted-rule.js +0 -117
  631. package/esm/rules/scalar/accepted-rule.js.map +0 -1
  632. package/esm/rules/scalar/declined-rule.d.ts +0 -39
  633. package/esm/rules/scalar/declined-rule.d.ts.map +0 -1
  634. package/esm/rules/scalar/declined-rule.js +0 -117
  635. package/esm/rules/scalar/declined-rule.js.map +0 -1
  636. package/esm/rules/scalar/index.d.ts +0 -3
  637. package/esm/rules/scalar/index.d.ts.map +0 -1
  638. package/esm/rules/string/alpha.d.ts +0 -14
  639. package/esm/rules/string/alpha.d.ts.map +0 -1
  640. package/esm/rules/string/alpha.js +0 -39
  641. package/esm/rules/string/alpha.js.map +0 -1
  642. package/esm/rules/string/credit-card.d.ts +0 -6
  643. package/esm/rules/string/credit-card.d.ts.map +0 -1
  644. package/esm/rules/string/credit-card.js +0 -31
  645. package/esm/rules/string/credit-card.js.map +0 -1
  646. package/esm/rules/string/email.d.ts +0 -6
  647. package/esm/rules/string/email.d.ts.map +0 -1
  648. package/esm/rules/string/email.js +0 -13
  649. package/esm/rules/string/email.js.map +0 -1
  650. package/esm/rules/string/index.d.ts +0 -17
  651. package/esm/rules/string/index.d.ts.map +0 -1
  652. package/esm/rules/string/ip.d.ts +0 -14
  653. package/esm/rules/string/ip.d.ts.map +0 -1
  654. package/esm/rules/string/ip.js +0 -39
  655. package/esm/rules/string/ip.js.map +0 -1
  656. package/esm/rules/string/matches.d.ts +0 -8
  657. package/esm/rules/string/matches.d.ts.map +0 -1
  658. package/esm/rules/string/matches.js +0 -15
  659. package/esm/rules/string/matches.js.map +0 -1
  660. package/esm/rules/string/pattern.d.ts +0 -8
  661. package/esm/rules/string/pattern.d.ts.map +0 -1
  662. package/esm/rules/string/pattern.js +0 -14
  663. package/esm/rules/string/pattern.js.map +0 -1
  664. package/esm/rules/string/string-comparison.d.ts +0 -26
  665. package/esm/rules/string/string-comparison.d.ts.map +0 -1
  666. package/esm/rules/string/string-comparison.js +0 -56
  667. package/esm/rules/string/string-comparison.js.map +0 -1
  668. package/esm/rules/string/strong-password-rule.d.ts +0 -14
  669. package/esm/rules/string/strong-password-rule.d.ts.map +0 -1
  670. package/esm/rules/string/strong-password-rule.js +0 -38
  671. package/esm/rules/string/strong-password-rule.js.map +0 -1
  672. package/esm/rules/string/url.d.ts +0 -6
  673. package/esm/rules/string/url.d.ts.map +0 -1
  674. package/esm/rules/string/url.js +0 -16
  675. package/esm/rules/string/url.js.map +0 -1
  676. package/esm/rules/string/without-whitespace.d.ts +0 -6
  677. package/esm/rules/string/without-whitespace.d.ts.map +0 -1
  678. package/esm/rules/string/without-whitespace.js +0 -13
  679. package/esm/rules/string/without-whitespace.js.map +0 -1
  680. package/esm/standard-schema/index.d.ts +0 -4
  681. package/esm/standard-schema/index.d.ts.map +0 -1
  682. package/esm/standard-schema/json-schema.d.ts +0 -61
  683. package/esm/standard-schema/json-schema.d.ts.map +0 -1
  684. package/esm/standard-schema/json-schema.js +0 -85
  685. package/esm/standard-schema/json-schema.js.map +0 -1
  686. package/esm/standard-schema/map-result.d.ts +0 -18
  687. package/esm/standard-schema/map-result.d.ts.map +0 -1
  688. package/esm/standard-schema/map-result.js +0 -27
  689. package/esm/standard-schema/map-result.js.map +0 -1
  690. package/esm/standard-schema/types.d.ts +0 -93
  691. package/esm/standard-schema/types.d.ts.map +0 -1
  692. package/esm/types/conditional-types.d.ts +0 -15
  693. package/esm/types/conditional-types.d.ts.map +0 -1
  694. package/esm/types/context-types.d.ts +0 -47
  695. package/esm/types/context-types.d.ts.map +0 -1
  696. package/esm/types/data-transformer-types.d.ts +0 -25
  697. package/esm/types/data-transformer-types.d.ts.map +0 -1
  698. package/esm/types/date-types.d.ts +0 -9
  699. package/esm/types/date-types.d.ts.map +0 -1
  700. package/esm/types/date-types.js +0 -12
  701. package/esm/types/date-types.js.map +0 -1
  702. package/esm/types/file.types.d.ts +0 -5
  703. package/esm/types/file.types.d.ts.map +0 -1
  704. package/esm/types/index.d.ts +0 -11
  705. package/esm/types/index.d.ts.map +0 -1
  706. package/esm/types/inference-types.d.ts +0 -32
  707. package/esm/types/inference-types.d.ts.map +0 -1
  708. package/esm/types/mutator-types.d.ts +0 -27
  709. package/esm/types/mutator-types.d.ts.map +0 -1
  710. package/esm/types/result-types.d.ts +0 -19
  711. package/esm/types/result-types.d.ts.map +0 -1
  712. package/esm/types/rule-types.d.ts +0 -58
  713. package/esm/types/rule-types.d.ts.map +0 -1
  714. package/esm/types/schema-types.d.ts +0 -6
  715. package/esm/types/schema-types.d.ts.map +0 -1
  716. package/esm/validators/any-validator.d.ts +0 -29
  717. package/esm/validators/any-validator.d.ts.map +0 -1
  718. package/esm/validators/any-validator.js +0 -31
  719. package/esm/validators/any-validator.js.map +0 -1
  720. package/esm/validators/array-validator.d.ts +0 -72
  721. package/esm/validators/array-validator.d.ts.map +0 -1
  722. package/esm/validators/array-validator.js +0 -162
  723. package/esm/validators/array-validator.js.map +0 -1
  724. package/esm/validators/base-validator.d.ts +0 -425
  725. package/esm/validators/base-validator.d.ts.map +0 -1
  726. package/esm/validators/base-validator.js +0 -637
  727. package/esm/validators/base-validator.js.map +0 -1
  728. package/esm/validators/boolean-validator.d.ts +0 -67
  729. package/esm/validators/boolean-validator.d.ts.map +0 -1
  730. package/esm/validators/boolean-validator.js +0 -105
  731. package/esm/validators/boolean-validator.js.map +0 -1
  732. package/esm/validators/computed-validator.d.ts +0 -75
  733. package/esm/validators/computed-validator.d.ts.map +0 -1
  734. package/esm/validators/computed-validator.js +0 -124
  735. package/esm/validators/computed-validator.js.map +0 -1
  736. package/esm/validators/date-validator.d.ts +0 -330
  737. package/esm/validators/date-validator.d.ts.map +0 -1
  738. package/esm/validators/date-validator.js +0 -614
  739. package/esm/validators/date-validator.js.map +0 -1
  740. package/esm/validators/float-validator.d.ts +0 -8
  741. package/esm/validators/float-validator.d.ts.map +0 -1
  742. package/esm/validators/float-validator.js +0 -9
  743. package/esm/validators/float-validator.js.map +0 -1
  744. package/esm/validators/index.d.ts +0 -31
  745. package/esm/validators/index.d.ts.map +0 -1
  746. package/esm/validators/int-validator.d.ts +0 -19
  747. package/esm/validators/int-validator.d.ts.map +0 -1
  748. package/esm/validators/int-validator.js +0 -21
  749. package/esm/validators/int-validator.js.map +0 -1
  750. package/esm/validators/managed-validator.d.ts +0 -38
  751. package/esm/validators/managed-validator.d.ts.map +0 -1
  752. package/esm/validators/managed-validator.js +0 -34
  753. package/esm/validators/managed-validator.js.map +0 -1
  754. package/esm/validators/methods/equality-conditional-methods.d.ts +0 -88
  755. package/esm/validators/methods/equality-conditional-methods.d.ts.map +0 -1
  756. package/esm/validators/methods/equality-conditional-methods.js +0 -118
  757. package/esm/validators/methods/equality-conditional-methods.js.map +0 -1
  758. package/esm/validators/methods/forbidden-methods.d.ts +0 -58
  759. package/esm/validators/methods/forbidden-methods.d.ts.map +0 -1
  760. package/esm/validators/methods/forbidden-methods.js +0 -122
  761. package/esm/validators/methods/forbidden-methods.js.map +0 -1
  762. package/esm/validators/methods/present-methods.d.ts +0 -102
  763. package/esm/validators/methods/present-methods.d.ts.map +0 -1
  764. package/esm/validators/methods/present-methods.js +0 -229
  765. package/esm/validators/methods/present-methods.js.map +0 -1
  766. package/esm/validators/methods/required-methods.d.ts +0 -174
  767. package/esm/validators/methods/required-methods.d.ts.map +0 -1
  768. package/esm/validators/methods/required-methods.js +0 -246
  769. package/esm/validators/methods/required-methods.js.map +0 -1
  770. package/esm/validators/number-validator.d.ts +0 -166
  771. package/esm/validators/number-validator.d.ts.map +0 -1
  772. package/esm/validators/number-validator.js +0 -307
  773. package/esm/validators/number-validator.js.map +0 -1
  774. package/esm/validators/numeric-validator.d.ts +0 -15
  775. package/esm/validators/numeric-validator.d.ts.map +0 -1
  776. package/esm/validators/numeric-validator.js +0 -18
  777. package/esm/validators/numeric-validator.js.map +0 -1
  778. package/esm/validators/object-validator.d.ts +0 -233
  779. package/esm/validators/object-validator.d.ts.map +0 -1
  780. package/esm/validators/object-validator.js +0 -517
  781. package/esm/validators/object-validator.js.map +0 -1
  782. package/esm/validators/primitive-validator.d.ts +0 -70
  783. package/esm/validators/primitive-validator.d.ts.map +0 -1
  784. package/esm/validators/primitive-validator.js +0 -80
  785. package/esm/validators/primitive-validator.js.map +0 -1
  786. package/esm/validators/record-validator.d.ts +0 -54
  787. package/esm/validators/record-validator.d.ts.map +0 -1
  788. package/esm/validators/record-validator.js +0 -100
  789. package/esm/validators/record-validator.js.map +0 -1
  790. package/esm/validators/scalar-validator.d.ts +0 -93
  791. package/esm/validators/scalar-validator.d.ts.map +0 -1
  792. package/esm/validators/scalar-validator.js +0 -149
  793. package/esm/validators/scalar-validator.js.map +0 -1
  794. package/esm/validators/string-validator.d.ts +0 -189
  795. package/esm/validators/string-validator.d.ts.map +0 -1
  796. package/esm/validators/string-validator.js +0 -387
  797. package/esm/validators/string-validator.js.map +0 -1
  798. package/esm/validators/tuple-validator.d.ts +0 -56
  799. package/esm/validators/tuple-validator.d.ts.map +0 -1
  800. package/esm/validators/tuple-validator.js +0 -121
  801. package/esm/validators/tuple-validator.js.map +0 -1
  802. package/esm/validators/union-validator.d.ts +0 -55
  803. package/esm/validators/union-validator.d.ts.map +0 -1
  804. package/esm/validators/union-validator.js +0 -60
  805. package/esm/validators/union-validator.js.map +0 -1
@@ -1,118 +0,0 @@
1
- import {getFieldValue}from'../../helpers/get-field-value.js';import {invalidRule,VALID_RULE}from'../../helpers/validation-helpers.js';import {isEmptyValue}from'../../helpers/is-empty-value.js';/**
2
- * Forbidden if rule - field is forbidden if another field equals a specific value
3
- * Supports both global and sibling scope
4
- */
5
- const forbiddenIfRule = {
6
- name: "forbiddenIf",
7
- description: "The field is forbidden if another field equals a specific value",
8
- sortOrder: -2,
9
- defaultErrorMessage: "The :input is forbidden",
10
- async validate(value, context) {
11
- const { value: expectedValue } = this.context.options;
12
- const fieldValue = getFieldValue(this, context);
13
- // Field is forbidden if it has a value and the other field equals the expected value
14
- if (!isEmptyValue(value) && fieldValue === expectedValue) {
15
- this.context.translatableParams.field = this.context.options.field;
16
- this.context.translationParams.value = expectedValue;
17
- return invalidRule(this, context);
18
- }
19
- return VALID_RULE;
20
- },
21
- };
22
- /**
23
- * Forbidden if not rule - field is forbidden if another field does NOT equal a specific value
24
- * Supports both global and sibling scope
25
- */
26
- const forbiddenIfNotRule = {
27
- name: "forbiddenIfNot",
28
- description: "The field is forbidden if another field does NOT equal a specific value",
29
- sortOrder: -2,
30
- defaultErrorMessage: "The :input is forbidden",
31
- async validate(value, context) {
32
- const { value: expectedValue } = this.context.options;
33
- const fieldValue = getFieldValue(this, context);
34
- // Field is forbidden if it has a value and the other field does NOT equal the expected value
35
- if (!isEmptyValue(value) && fieldValue !== expectedValue) {
36
- return invalidRule(this, context);
37
- }
38
- return VALID_RULE;
39
- },
40
- };
41
- /**
42
- * Forbidden if empty rule - field is forbidden if another field is empty
43
- * Supports both global and sibling scope
44
- */
45
- const forbiddenIfEmptyRule = {
46
- name: "forbiddenIfEmpty",
47
- description: "The field is forbidden if another field is empty",
48
- sortOrder: -2,
49
- defaultErrorMessage: "The :input is forbidden",
50
- async validate(value, context) {
51
- const fieldValue = getFieldValue(this, context);
52
- // Field is forbidden if it has a value and the other field is empty
53
- if (!isEmptyValue(value) && isEmptyValue(fieldValue)) {
54
- return invalidRule(this, context);
55
- }
56
- return VALID_RULE;
57
- },
58
- };
59
- /**
60
- * Forbidden if not empty rule - field is forbidden if another field is not empty
61
- * Supports both global and sibling scope
62
- */
63
- const forbiddenIfNotEmptyRule = {
64
- name: "forbiddenIfNotEmpty",
65
- description: "The field is forbidden if another field is not empty",
66
- sortOrder: -2,
67
- defaultErrorMessage: "The :input is forbidden",
68
- async validate(value, context) {
69
- const fieldValue = getFieldValue(this, context);
70
- // Field is forbidden if it has a value and the other field is not empty
71
- if (!isEmptyValue(value) && !isEmptyValue(fieldValue)) {
72
- return invalidRule(this, context);
73
- }
74
- return VALID_RULE;
75
- },
76
- };
77
- /**
78
- * Forbidden if in rule - field is forbidden if another field's value is in the given array
79
- * Supports both global and sibling scope
80
- */
81
- const forbiddenIfInRule = {
82
- name: "forbiddenIfIn",
83
- description: "The field is forbidden if another field's value is in the given array",
84
- sortOrder: -2,
85
- defaultErrorMessage: "The :input is forbidden",
86
- async validate(value, context) {
87
- const { values } = this.context.options;
88
- const fieldValue = getFieldValue(this, context);
89
- // Field is forbidden if it has a value and the other field's value is in the array
90
- if (!isEmptyValue(value) && values.includes(fieldValue)) {
91
- this.context.translationParams.values = values.join(", ");
92
- this.context.translatableParams.field = this.context.options.field;
93
- return invalidRule(this, context);
94
- }
95
- return VALID_RULE;
96
- },
97
- };
98
- /**
99
- * Forbidden if not in rule - field is forbidden if another field's value is NOT in the given array
100
- * Supports both global and sibling scope
101
- */
102
- const forbiddenIfNotInRule = {
103
- name: "forbiddenIfNotIn",
104
- description: "The field is forbidden if another field's value is NOT in the given array",
105
- sortOrder: -2,
106
- defaultErrorMessage: "The :input is forbidden",
107
- async validate(value, context) {
108
- const { values } = this.context.options;
109
- const fieldValue = getFieldValue(this, context);
110
- // Field is forbidden if it has a value and the other field's value is NOT in the array
111
- if (!isEmptyValue(value) && !values.includes(fieldValue)) {
112
- this.context.translationParams.values = values.join(", ");
113
- this.context.translatableParams.field = this.context.options.field;
114
- return invalidRule(this, context);
115
- }
116
- return VALID_RULE;
117
- },
118
- };export{forbiddenIfEmptyRule,forbiddenIfInRule,forbiddenIfNotEmptyRule,forbiddenIfNotInRule,forbiddenIfNotRule,forbiddenIfRule};//# sourceMappingURL=forbidden-if-rules.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"forbidden-if-rules.js","sources":["../../../src/rules/conditional/forbidden-if-rules.ts"],"sourcesContent":[null],"names":[],"mappings":"iMAIA;;;AAGG;AACU,MAAA,eAAe,GAIvB;AACH,IAAA,IAAI,EAAE,aAAa;AACnB,IAAA,WAAW,EAAE,iEAAiE;IAC9E,SAAS,EAAE,CAAC,CAAC;AACb,IAAA,mBAAmB,EAAE,yBAAyB;AAC9C,IAAA,MAAM,QAAQ,CAAC,KAAU,EAAE,OAAO,EAAA;QAChC,MAAM,EAAE,KAAK,EAAE,aAAa,EAAE,GAAG,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC;QACtD,MAAM,UAAU,GAAG,aAAa,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;;QAGhD,IAAI,CAAC,YAAY,CAAC,KAAK,CAAC,IAAI,UAAU,KAAK,aAAa,EAAE;AACxD,YAAA,IAAI,CAAC,OAAO,CAAC,kBAAkB,CAAC,KAAK,GAAG,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,KAAK,CAAC;YACnE,IAAI,CAAC,OAAO,CAAC,iBAAiB,CAAC,KAAK,GAAG,aAAa,CAAC;AACrD,YAAA,OAAO,WAAW,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;AACnC,SAAA;AAED,QAAA,OAAO,UAAU,CAAC;KACnB;EACD;AAEF;;;AAGG;AACU,MAAA,kBAAkB,GAI1B;AACH,IAAA,IAAI,EAAE,gBAAgB;AACtB,IAAA,WAAW,EAAE,yEAAyE;IACtF,SAAS,EAAE,CAAC,CAAC;AACb,IAAA,mBAAmB,EAAE,yBAAyB;AAC9C,IAA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AAG,aAAa,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;;AAGhD,QAAA,IAAI,CAAC,YAAY,CAAC,KAAK,CAAC,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,UAAU,CAAC,EAAE;AACxD,YAAA,IAAI,CAAC,OAAO,CAAC,iBAAiB,CAAC,MAAM,GAAG,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;AAC1D,YAAA,IAAI,CAAC,OAAO,CAAC,kBAAkB,CAAC,KAAK,GAAG,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,KAAK,CAAC;AACnE,YAAA,OAAO,WAAW,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;AACnC,SAAA;AAED,QAAA,OAAO,UAAU,CAAC;KACnB;"}
@@ -1,11 +0,0 @@
1
- export * from "./required-if-rules";
2
- export * from "./required-unless-rules";
3
- export * from "./required-when-rule";
4
- export * from "./required-with-rules";
5
- export * from "./required-without-rules";
6
- export * from "./present-if-rules";
7
- export * from "./present-unless-rules";
8
- export * from "./present-with-rules";
9
- export * from "./present-without-rules";
10
- export * from "./forbidden-if-rules";
11
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/rules/conditional/index.ts"],"names":[],"mappings":"AACA,cAAc,qBAAqB,CAAC;AACpC,cAAc,yBAAyB,CAAC;AACxC,cAAc,sBAAsB,CAAC;AACrC,cAAc,uBAAuB,CAAC;AACtC,cAAc,0BAA0B,CAAC;AAGzC,cAAc,oBAAoB,CAAC;AACnC,cAAc,wBAAwB,CAAC;AACvC,cAAc,sBAAsB,CAAC;AACrC,cAAc,yBAAyB,CAAC;AAGxC,cAAc,sBAAsB,CAAC"}
@@ -1,45 +0,0 @@
1
- import type { SchemaRule } from "../../types";
2
- /**
3
- * Present if rule - field must be present if another field equals a specific value
4
- * Supports both global and sibling scope
5
- */
6
- export declare const presentIfRule: SchemaRule<{
7
- field: string;
8
- value: any;
9
- scope?: "global" | "sibling";
10
- }>;
11
- /**
12
- * Present if empty rule - field must be present if another field is empty
13
- * Supports both global and sibling scope
14
- */
15
- export declare const presentIfEmptyRule: SchemaRule<{
16
- field: string;
17
- scope?: "global" | "sibling";
18
- }>;
19
- /**
20
- * Present if not empty rule - field must be present if another field is not empty
21
- * Supports both global and sibling scope
22
- */
23
- export declare const presentIfNotEmptyRule: SchemaRule<{
24
- field: string;
25
- scope?: "global" | "sibling";
26
- }>;
27
- /**
28
- * Present if in rule - field must be present if another field's value is in the given array
29
- * Supports both global and sibling scope
30
- */
31
- export declare const presentIfInRule: SchemaRule<{
32
- field: string;
33
- values: any[];
34
- scope?: "global" | "sibling";
35
- }>;
36
- /**
37
- * Present if not in rule - field must be present if another field's value is NOT in the given array
38
- * Supports both global and sibling scope
39
- */
40
- export declare const presentIfNotInRule: SchemaRule<{
41
- field: string;
42
- values: any[];
43
- scope?: "global" | "sibling";
44
- }>;
45
- //# sourceMappingURL=present-if-rules.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"present-if-rules.d.ts","sourceRoot":"","sources":["../../../src/rules/conditional/present-if-rules.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAG9C;;;GAGG;AACH,eAAO,MAAM,aAAa,EAAE,UAAU,CAAC;IACrC,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,GAAG,CAAC;IACX,KAAK,CAAC,EAAE,QAAQ,GAAG,SAAS,CAAC;CAC9B,CAmBA,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,kBAAkB,EAAE,UAAU,CAAC;IAC1C,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,QAAQ,GAAG,SAAS,CAAC;CAC9B,CAgBA,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,qBAAqB,EAAE,UAAU,CAAC;IAC7C,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,QAAQ,GAAG,SAAS,CAAC;CAC9B,CAgBA,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,eAAe,EAAE,UAAU,CAAC;IACvC,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,GAAG,EAAE,CAAC;IACd,KAAK,CAAC,EAAE,QAAQ,GAAG,SAAS,CAAC;CAC9B,CAiBA,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,kBAAkB,EAAE,UAAU,CAAC;IAC1C,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,GAAG,EAAE,CAAC;IACd,KAAK,CAAC,EAAE,QAAQ,GAAG,SAAS,CAAC;CAC9B,CAiBA,CAAC"}
@@ -1,100 +0,0 @@
1
- import {getFieldValue}from'../../helpers/get-field-value.js';import {invalidRule,VALID_RULE}from'../../helpers/validation-helpers.js';import {isEmptyValue}from'../../helpers/is-empty-value.js';/**
2
- * Present if rule - field must be present if another field equals a specific value
3
- * Supports both global and sibling scope
4
- */
5
- const presentIfRule = {
6
- name: "presentIf",
7
- description: "The field must be present if another field equals a specific value",
8
- sortOrder: -2,
9
- requiresValue: false,
10
- defaultErrorMessage: "The :input field must be present",
11
- async validate(value, context) {
12
- const { value: expectedValue } = this.context.options;
13
- const fieldValue = getFieldValue(this, context);
14
- // Field must be present if the other field equals the expected value
15
- if (value === undefined && fieldValue === expectedValue) {
16
- this.context.translationParams.value = expectedValue;
17
- this.context.translatableParams.field = this.context.options.field;
18
- return invalidRule(this, context);
19
- }
20
- return VALID_RULE;
21
- },
22
- };
23
- /**
24
- * Present if empty rule - field must be present if another field is empty
25
- * Supports both global and sibling scope
26
- */
27
- const presentIfEmptyRule = {
28
- name: "presentIfEmpty",
29
- description: "The field must be present if another field is empty",
30
- sortOrder: -2,
31
- requiresValue: false,
32
- defaultErrorMessage: "The :input field must be present",
33
- async validate(value, context) {
34
- const fieldValue = getFieldValue(this, context);
35
- // Field must be present if the other field is empty
36
- if (value === undefined && isEmptyValue(fieldValue)) {
37
- return invalidRule(this, context);
38
- }
39
- return VALID_RULE;
40
- },
41
- };
42
- /**
43
- * Present if not empty rule - field must be present if another field is not empty
44
- * Supports both global and sibling scope
45
- */
46
- const presentIfNotEmptyRule = {
47
- name: "presentIfNotEmpty",
48
- description: "The field must be present if another field is not empty",
49
- sortOrder: -2,
50
- requiresValue: false,
51
- defaultErrorMessage: "The :input field must be present",
52
- async validate(value, context) {
53
- const fieldValue = getFieldValue(this, context);
54
- // Field must be present if the other field is not empty
55
- if (value === undefined && !isEmptyValue(fieldValue)) {
56
- return invalidRule(this, context);
57
- }
58
- return VALID_RULE;
59
- },
60
- };
61
- /**
62
- * Present if in rule - field must be present if another field's value is in the given array
63
- * Supports both global and sibling scope
64
- */
65
- const presentIfInRule = {
66
- name: "presentIfIn",
67
- description: "The field must be present if another field's value is in the given array",
68
- sortOrder: -2,
69
- requiresValue: false,
70
- defaultErrorMessage: "The :input field must be present",
71
- async validate(value, context) {
72
- const { values } = this.context.options;
73
- const fieldValue = getFieldValue(this, context);
74
- // Field must be present if the other field's value is in the array
75
- if (value === undefined && values.includes(fieldValue)) {
76
- return invalidRule(this, context);
77
- }
78
- return VALID_RULE;
79
- },
80
- };
81
- /**
82
- * Present if not in rule - field must be present if another field's value is NOT in the given array
83
- * Supports both global and sibling scope
84
- */
85
- const presentIfNotInRule = {
86
- name: "presentIfNotIn",
87
- description: "The field must be present if another field's value is NOT in the given array",
88
- sortOrder: -2,
89
- requiresValue: false,
90
- defaultErrorMessage: "The :input field must be present",
91
- async validate(value, context) {
92
- const { values } = this.context.options;
93
- const fieldValue = getFieldValue(this, context);
94
- // Field must be present if the other field's value is NOT in the array
95
- if (value === undefined && !values.includes(fieldValue)) {
96
- return invalidRule(this, context);
97
- }
98
- return VALID_RULE;
99
- },
100
- };export{presentIfEmptyRule,presentIfInRule,presentIfNotEmptyRule,presentIfNotInRule,presentIfRule};//# sourceMappingURL=present-if-rules.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"present-if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A,IAAI,EAAE,gBAAgB;AACtB,IAAA,WAAW,EAAE,8EAA8E;IAC3F,SAAS,EAAE,CAAC,CAAC;AACb,IAAA,aAAa,EAAE,KAAK;AACpB,IAAA,mBAAmB,EAAE,kCAAkC;AACvD,IAAA,MAAM,QAAQ,CAAC,KAAU,EAAE,OAAO,EAAA;QAChC,MAAM,EAAE,MAAM,EAAE,GAAG,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC;QACxC,MAAM,UAAU,GAAG,aAAa,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;;QAGhD,IAAI,KAAK,KAAK,SAAS,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,UAAU,CAAC,EAAE;AACvD,YAAA,OAAO,WAAW,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;AACnC,SAAA;AAED,QAAA,OAAO,UAAU,CAAC;KACnB;"}
@@ -1,11 +0,0 @@
1
- import type { SchemaRule } from "../../types";
2
- /**
3
- * Present unless rule - field must be present unless another field equals a specific value
4
- * Supports both global and sibling scope
5
- */
6
- export declare const presentUnlessRule: SchemaRule<{
7
- field: string;
8
- value: any;
9
- scope?: "global" | "sibling";
10
- }>;
11
- //# sourceMappingURL=present-unless-rules.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"present-unless-rules.d.ts","sourceRoot":"","sources":["../../../src/rules/conditional/present-unless-rules.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAE9C;;;GAGG;AACH,eAAO,MAAM,iBAAiB,EAAE,UAAU,CAAC;IACzC,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,GAAG,CAAC;IACX,KAAK,CAAC,EAAE,QAAQ,GAAG,SAAS,CAAC;CAC9B,CAmBA,CAAC"}
@@ -1,22 +0,0 @@
1
- import {getFieldValue}from'../../helpers/get-field-value.js';import {invalidRule,VALID_RULE}from'../../helpers/validation-helpers.js';/**
2
- * Present unless rule - field must be present unless another field equals a specific value
3
- * Supports both global and sibling scope
4
- */
5
- const presentUnlessRule = {
6
- name: "presentUnless",
7
- description: "The field must be present unless another field equals a specific value",
8
- sortOrder: -2,
9
- requiresValue: false,
10
- defaultErrorMessage: "The :input field must be present",
11
- async validate(value, context) {
12
- const { value: expectedValue } = this.context.options;
13
- const fieldValue = getFieldValue(this, context);
14
- // Field must be present unless the other field equals the expected value
15
- if (value === undefined && fieldValue !== expectedValue) {
16
- this.context.translationParams.value = expectedValue;
17
- this.context.translatableParams.field = this.context.options.field;
18
- return invalidRule(this, context);
19
- }
20
- return VALID_RULE;
21
- },
22
- };export{presentUnlessRule};//# sourceMappingURL=present-unless-rules.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"present-unless-rules.js","sources":["../../../src/rules/conditional/present-unless-rules.ts"],"sourcesContent":[null],"names":[],"mappings":"sIAGA;;;AAGG;AACU,MAAA,iBAAiB,GAIzB;AACH,IAAA,IAAI,EAAE,eAAe;AACrB,IAAA,WAAW,EAAE,wEAAwE;IACrF,SAAS,EAAE,CAAC,CAAC;AACb,IAAA,aAAa,EAAE,KAAK;AACpB,IAAA,mBAAmB,EAAE,kCAAkC;AACvD,IAAA,MAAM,QAAQ,CAAC,KAAU,EAAE,OAAO,EAAA;QAChC,MAAM,EAAE,KAAK,EAAE,aAAa,EAAE,GAAG,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC;QACtD,MAAM,UAAU,GAAG,aAAa,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;;AAGhD,QAAA,IAAI,KAAK,KAAK,SAAS,IAAI,UAAU,KAAK,aAAa,EAAE;YACvD,IAAI,CAAC,OAAO,CAAC,iBAAiB,CAAC,KAAK,GAAG,aAAa,CAAC;AACrD,YAAA,IAAI,CAAC,OAAO,CAAC,kBAAkB,CAAC,KAAK,GAAG,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,KAAK,CAAC;AACnE,YAAA,OAAO,WAAW,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;AACnC,SAAA;AAED,QAAA,OAAO,UAAU,CAAC;KACnB;"}
@@ -1,26 +0,0 @@
1
- import type { SchemaRule } from "../../types";
2
- /**
3
- * Present with rule - field must be present if another field is present
4
- * Supports both global and sibling scope
5
- */
6
- export declare const presentWithRule: SchemaRule<{
7
- field: string;
8
- scope?: "global" | "sibling";
9
- }>;
10
- /**
11
- * Present with all rule - field must be present if all specified fields are present
12
- * Supports both global and sibling scope
13
- */
14
- export declare const presentWithAllRule: SchemaRule<{
15
- fields: string[];
16
- scope?: "global" | "sibling";
17
- }>;
18
- /**
19
- * Present with any rule - field must be present if any of the specified fields is present
20
- * Supports both global and sibling scope
21
- */
22
- export declare const presentWithAnyRule: SchemaRule<{
23
- fields: string[];
24
- scope?: "global" | "sibling";
25
- }>;
26
- //# sourceMappingURL=present-with-rules.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"present-with-rules.d.ts","sourceRoot":"","sources":["../../../src/rules/conditional/present-with-rules.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAE9C;;;GAGG;AACH,eAAO,MAAM,eAAe,EAAE,UAAU,CAAC;IACvC,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,QAAQ,GAAG,SAAS,CAAC;CAC9B,CAiBA,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,kBAAkB,EAAE,UAAU,CAAC;IAC1C,MAAM,EAAE,MAAM,EAAE,CAAC;IACjB,KAAK,CAAC,EAAE,QAAQ,GAAG,SAAS,CAAC;CAC9B,CAwBA,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,kBAAkB,EAAE,UAAU,CAAC;IAC1C,MAAM,EAAE,MAAM,EAAE,CAAC;IACjB,KAAK,CAAC,EAAE,QAAQ,GAAG,SAAS,CAAC;CAC9B,CAwBA,CAAC"}
@@ -1,70 +0,0 @@
1
- import {get}from'@mongez/reinforcements';import {getFieldValue}from'../../helpers/get-field-value.js';import {invalidRule,VALID_RULE}from'../../helpers/validation-helpers.js';/**
2
- * Present with rule - field must be present if another field is present
3
- * Supports both global and sibling scope
4
- */
5
- const presentWithRule = {
6
- name: "presentWith",
7
- description: "The field must be present if another field is present",
8
- sortOrder: -2,
9
- requiresValue: false,
10
- defaultErrorMessage: "The :input field must be present",
11
- async validate(value, context) {
12
- const fieldValue = getFieldValue(this, context);
13
- // The field must be present if the other field is present
14
- if (value === undefined && fieldValue !== undefined) {
15
- this.context.translatableParams.field = this.context.options.field;
16
- return invalidRule(this, context);
17
- }
18
- return VALID_RULE;
19
- },
20
- };
21
- /**
22
- * Present with all rule - field must be present if all specified fields are present
23
- * Supports both global and sibling scope
24
- */
25
- const presentWithAllRule = {
26
- name: "presentWithAll",
27
- description: "The field must be present if all specified fields are present",
28
- sortOrder: -2,
29
- requiresValue: false,
30
- defaultErrorMessage: "The :input field must be present",
31
- async validate(value, context) {
32
- const { fields, scope = "global" } = this.context.options;
33
- const source = scope === "sibling" ? context.parent : context.allValues;
34
- // Check if all fields are present
35
- const allPresent = fields.every((field) => get(source, field) !== undefined);
36
- // Field must be present if all other fields are present
37
- if (value === undefined && allPresent) {
38
- fields.forEach((field) => {
39
- this.context.translatableParams.field = field;
40
- });
41
- return invalidRule(this, context);
42
- }
43
- return VALID_RULE;
44
- },
45
- };
46
- /**
47
- * Present with any rule - field must be present if any of the specified fields is present
48
- * Supports both global and sibling scope
49
- */
50
- const presentWithAnyRule = {
51
- name: "presentWithAny",
52
- description: "The field must be present if any of the specified fields is present",
53
- sortOrder: -2,
54
- requiresValue: false,
55
- defaultErrorMessage: "The :input field must be present",
56
- async validate(value, context) {
57
- const { fields, scope = "global" } = this.context.options;
58
- const source = scope === "sibling" ? context.parent : context.allValues;
59
- // Check if any field is present
60
- const anyPresent = fields.some((field) => get(source, field) !== undefined);
61
- // Field must be present if any other field is present
62
- if (value === undefined && anyPresent) {
63
- fields.forEach((field) => {
64
- this.context.translatableParams.field = field;
65
- });
66
- return invalidRule(this, context);
67
- }
68
- return VALID_RULE;
69
- },
70
- };export{presentWithAllRule,presentWithAnyRule,presentWithRule};//# sourceMappingURL=present-with-rules.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"present-with-rules.js","sources":["../../../src/rules/conditional/present-with-rules.ts"],"sourcesContent":[null],"names":[],"mappings":"+KAIA;;;AAGG;AACU,MAAA,eAAe,GAGvB;AACH,IAAA,IAAI,EAAE,aAAa;AACnB,IAAA,WAAW,EAAE,uDAAuD;IACpE,SAAS,EAAE,CAAC,CAAC;AACb,IAAA,aAAa,EAAE,KAAK;AACpB,IAAA,mBAAmB,EAAE,kCAAkC;AACvD,IAAA,MAAM,QAAQ,CAAC,KAAU,EAAE,OAAO,EAAA;QAChC,MAAM,UAAU,GAAG,aAAa,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;;AAGhD,QAAA,IAAI,KAAK,KAAK,SAAS,IAAI,UAAU,KAAK,SAAS,EAAE;AACnD,YAAA,IAAI,CAAC,OAAO,CAAC,kBAAkB,CAAC,KAAK,GAAG,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,KAAK,CAAC;AACnE,YAAA,OAAO,WAAW,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;AACnC,SAAA;AAED,QAAA,OAAO,UAAU,CAAC;KACnB;EACD;AAEF;;;AAGG;AACU,MAAA,kBAAkB,GAG1B;AACH,IAAA,IAAI,EAAE,gBAAgB;AACtB,IAAA,WAAW,EAAE,+DAA+D;IAC5E,SAAS,EAAE,CAAC,CAAC;AACb,IAAA,aAAa,EAAE,KAAK;AACpB,IAAA,mBAAmB,EAAE,kCAAkC;AACvD,IAAA,MAAM,QAAQ,CAAC,KAAU,EAAE,OAAO,EAAA;AAChC,QAAA,MAAM,EAAE,MAAM,EAAE,KAAK,GAAG,QAAQ,EAAE,GAAG,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC;AAC1D,QAAA,MAAM,MAAM,GAAG,KAAK,KAAK,SAAS,GAAG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B,CAAC,KAAK,GAAG,KAAK,CAAC;AAChD,aAAC,CAAC,CAAC;AAEH,YAAA,OAAO,WAAW,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;AACnC,SAAA;AAED,QAAA,OAAO,UAAU,CAAC;KACnB;"}
@@ -1,26 +0,0 @@
1
- import type { SchemaRule } from "../../types";
2
- /**
3
- * Present without rule - field must be present if another field is missing
4
- * Supports both global and sibling scope
5
- */
6
- export declare const presentWithoutRule: SchemaRule<{
7
- field: string;
8
- scope?: "global" | "sibling";
9
- }>;
10
- /**
11
- * Present without all rule - field must be present if all specified fields are missing
12
- * Supports both global and sibling scope
13
- */
14
- export declare const presentWithoutAllRule: SchemaRule<{
15
- fields: string[];
16
- scope?: "global" | "sibling";
17
- }>;
18
- /**
19
- * Present without any rule - field must be present if any of the specified fields is missing
20
- * Supports both global and sibling scope
21
- */
22
- export declare const presentWithoutAnyRule: SchemaRule<{
23
- fields: string[];
24
- scope?: "global" | "sibling";
25
- }>;
26
- //# sourceMappingURL=present-without-rules.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"present-without-rules.d.ts","sourceRoot":"","sources":["../../../src/rules/conditional/present-without-rules.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAE9C;;;GAGG;AACH,eAAO,MAAM,kBAAkB,EAAE,UAAU,CAAC;IAC1C,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,QAAQ,GAAG,SAAS,CAAC;CAC9B,CAiBA,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,qBAAqB,EAAE,UAAU,CAAC;IAC7C,MAAM,EAAE,MAAM,EAAE,CAAC;IACjB,KAAK,CAAC,EAAE,QAAQ,GAAG,SAAS,CAAC;CAC9B,CAwBA,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,qBAAqB,EAAE,UAAU,CAAC;IAC7C,MAAM,EAAE,MAAM,EAAE,CAAC;IACjB,KAAK,CAAC,EAAE,QAAQ,GAAG,SAAS,CAAC;CAC9B,CAwBA,CAAC"}
@@ -1,70 +0,0 @@
1
- import {get}from'@mongez/reinforcements';import {getFieldValue}from'../../helpers/get-field-value.js';import {invalidRule,VALID_RULE}from'../../helpers/validation-helpers.js';/**
2
- * Present without rule - field must be present if another field is missing
3
- * Supports both global and sibling scope
4
- */
5
- const presentWithoutRule = {
6
- name: "presentWithout",
7
- description: "The field must be present if another field is missing",
8
- sortOrder: -2,
9
- requiresValue: false,
10
- defaultErrorMessage: "The :input field must be present",
11
- async validate(value, context) {
12
- const fieldValue = getFieldValue(this, context);
13
- // Field must be present if the other field is missing
14
- if (value === undefined && fieldValue === undefined) {
15
- this.context.translatableParams.field = this.context.options.field;
16
- return invalidRule(this, context);
17
- }
18
- return VALID_RULE;
19
- },
20
- };
21
- /**
22
- * Present without all rule - field must be present if all specified fields are missing
23
- * Supports both global and sibling scope
24
- */
25
- const presentWithoutAllRule = {
26
- name: "presentWithoutAll",
27
- description: "The field must be present if all specified fields are missing",
28
- sortOrder: -2,
29
- requiresValue: false,
30
- defaultErrorMessage: "The :input field must be present",
31
- async validate(value, context) {
32
- const { fields, scope = "global" } = this.context.options;
33
- const source = scope === "sibling" ? context.parent : context.allValues;
34
- // Check if all fields are missing
35
- const allMissing = fields.every((field) => get(source, field) === undefined);
36
- // Field must be present if all other fields are missing
37
- if (value === undefined && allMissing) {
38
- fields.forEach((field) => {
39
- this.context.translatableParams.field = field;
40
- });
41
- return invalidRule(this, context);
42
- }
43
- return VALID_RULE;
44
- },
45
- };
46
- /**
47
- * Present without any rule - field must be present if any of the specified fields is missing
48
- * Supports both global and sibling scope
49
- */
50
- const presentWithoutAnyRule = {
51
- name: "presentWithoutAny",
52
- description: "The field must be present if any of the specified fields is missing",
53
- sortOrder: -2,
54
- requiresValue: false,
55
- defaultErrorMessage: "The :input field must be present",
56
- async validate(value, context) {
57
- const { fields, scope = "global" } = this.context.options;
58
- const source = scope === "sibling" ? context.parent : context.allValues;
59
- // Check if any field is missing
60
- const anyMissing = fields.some((field) => get(source, field) === undefined);
61
- // Field must be present if any other field is missing
62
- if (value === undefined && anyMissing) {
63
- fields.forEach((field) => {
64
- this.context.translatableParams.field = field;
65
- });
66
- return invalidRule(this, context);
67
- }
68
- return VALID_RULE;
69
- },
70
- };export{presentWithoutAllRule,presentWithoutAnyRule,presentWithoutRule};//# sourceMappingURL=present-without-rules.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"present-without-rules.js","sources":["../../../src/rules/conditional/present-without-rules.ts"],"sourcesContent":[null],"names":[],"mappings":"+KAIA;;;AAGG;AACU,MAAA,kBAAkB,GAG1B;AACH,IAAA,IAAI,EAAE,gBAAgB;AACtB,IAAA,WAAW,EAAE,uDAAuD;IACpE,SAAS,EAAE,CAAC,CAAC;AACb,IAAA,aAAa,EAAE,KAAK;AACpB,IAAA,mBAAmB,EAAE,kCAAkC;AACvD,IAAA,MAAM,QAAQ,CAAC,KAAU,EAAE,OAAO,EAAA;QAChC,MAAM,UAAU,GAAG,aAAa,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;;AAGhD,QAAA,IAAI,KAAK,KAAK,SAAS,IAAI,UAAU,KAAK,SAAS,EAAE;AACnD,YAAA,IAAI,CAAC,OAAO,CAAC,kBAAkB,CAAC,KAAK,GAAG,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,KAAK,CAAC;AACnE,YAAA,OAAO,WAAW,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;AACnC,SAAA;AAED,QAAA,OAAO,UAAU,CAAC;KACnB;EACD;AAEF;;;AAGG;AACU,MAAA,qBAAqB,GAG7B;AACH,IAAA,IAAI,EAAE,mBAAmB;AACzB,IAAA,WAAW,EAAE,+DAA+D;IAC5E,SAAS,EAAE,CAAC,CAAC;AACb,IAAA,aAAa,EAAE,KAAK;AACpB,IAAA,mBAAmB,EAAE,kCAAkC;AACvD,IAAA,MAAM,QAAQ,CAAC,KAAU,EAAE,OAAO,E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S,CAAC,CAAC;;AAG5E,QAAA,IAAI,KAAK,KAAK,SAAS,IAAI,UAAU,EAAE;AACrC,YAAA,MAAM,CAAC,OAAO,CAAC,CAAC,KAAK,KAAI;gBACvB,IAAI,CAAC,OAAO,CAAC,kBAAkB,CAAC,KAAK,GAAG,KAAK,CAAC;AAChD,aAAC,CAAC,CAAC;AAEH,YAAA,OAAO,WAAW,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;AACnC,SAAA;AAED,QAAA,OAAO,UAAU,CAAC;KACnB;"}
@@ -1,77 +0,0 @@
1
- import type { SchemaRule } from "../../types";
2
- /**
3
- * Required if rule - field is required if another field equals a specific value
4
- * Supports both global and sibling scope
5
- */
6
- export declare const requiredIfRule: SchemaRule<{
7
- field: string;
8
- value: any;
9
- scope?: "global" | "sibling";
10
- }>;
11
- /**
12
- * Required if empty rule - field is required if another field is empty
13
- * Supports both global and sibling scope
14
- */
15
- export declare const requiredIfEmptyRule: SchemaRule<{
16
- field: string;
17
- scope?: "global" | "sibling";
18
- }>;
19
- /**
20
- * Required if not empty rule - field is required if another field is not empty
21
- * Supports both global and sibling scope
22
- */
23
- export declare const requiredIfNotEmptyRule: SchemaRule<{
24
- field: string;
25
- scope?: "global" | "sibling";
26
- }>;
27
- /**
28
- * Required if in rule - field is required if another field's value is in the given array
29
- * Supports both global and sibling scope
30
- */
31
- export declare const requiredIfInRule: SchemaRule<{
32
- field: string;
33
- values: any[];
34
- scope?: "global" | "sibling";
35
- }>;
36
- /**
37
- * Required if not in rule - field is required if another field's value is NOT in the given array
38
- * Supports both global and sibling scope
39
- */
40
- export declare const requiredIfNotInRule: SchemaRule<{
41
- field: string;
42
- values: any[];
43
- scope?: "global" | "sibling";
44
- }>;
45
- /**
46
- * Required if all empty rule - field is required if ALL specified fields are empty
47
- * Supports both global and sibling scope
48
- */
49
- export declare const requiredIfAllEmptyRule: SchemaRule<{
50
- fields: string[];
51
- scope?: "global" | "sibling";
52
- }>;
53
- /**
54
- * Required if any empty rule - field is required if ANY of the specified fields is empty
55
- * Supports both global and sibling scope
56
- */
57
- export declare const requiredIfAnyEmptyRule: SchemaRule<{
58
- fields: string[];
59
- scope?: "global" | "sibling";
60
- }>;
61
- /**
62
- * Required if all not empty rule - field is required if ALL specified fields are NOT empty
63
- * Supports both global and sibling scope
64
- */
65
- export declare const requiredIfAllNotEmptyRule: SchemaRule<{
66
- fields: string[];
67
- scope?: "global" | "sibling";
68
- }>;
69
- /**
70
- * Required if any not empty rule - field is required if ANY of the specified fields is NOT empty
71
- * Supports both global and sibling scope
72
- */
73
- export declare const requiredIfAnyNotEmptyRule: SchemaRule<{
74
- fields: string[];
75
- scope?: "global" | "sibling";
76
- }>;
77
- //# sourceMappingURL=required-if-rules.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"required-if-rules.d.ts","sourceRoot":"","sources":["../../../src/rules/conditional/required-if-rules.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAE9C;;;GAGG;AACH,eAAO,MAAM,cAAc,EAAE,UAAU,CAAC;IACtC,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,GAAG,CAAC;IACX,KAAK,CAAC,EAAE,QAAQ,GAAG,SAAS,CAAC;CAC9B,CAkBA,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,mBAAmB,EAAE,UAAU,CAAC;IAC3C,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,QAAQ,GAAG,SAAS,CAAC;CAC9B,CAiBA,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,sBAAsB,EAAE,UAAU,CAAC;IAC9C,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,QAAQ,GAAG,SAAS,CAAC;CAC9B,CAiBA,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,gBAAgB,EAAE,UAAU,CAAC;IACxC,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,GAAG,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