@warlock.js/notifications 5.13.0 → 5.15.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.
- package/CHANGELOG.md +12 -0
- package/cjs/{src-Cx9y1PWY.cjs → esm-Ct3gwkEe.cjs} +207 -299
- package/cjs/esm-Ct3gwkEe.cjs.map +1 -0
- package/cjs/index.cjs +118 -7
- package/cjs/index.cjs.map +1 -1
- package/cjs/rabbitmq-driver-DysU9q_t.cjs +3 -0
- package/esm/index.d.mts +8 -1
- package/esm/index.mjs +4 -1
- package/esm/node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm/communicators/broker-registry.d.mts +1 -0
- package/esm/{herald/src → node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm}/communicators/broker-registry.mjs +5 -5
- package/esm/node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm/communicators/broker-registry.mjs.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm/communicators/broker.d.mts +1 -0
- package/esm/{herald/src → node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm}/communicators/broker.mjs +1 -7
- package/esm/node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm/communicators/broker.mjs.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm/communicators/index.mjs +3 -0
- package/esm/node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm/contracts/broker-driver.contract.d.mts +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm/contracts/channel.contract.d.mts +1 -0
- package/esm/{herald/src → node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm}/decorators/consumable.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm/decorators/consumable.mjs.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm/decorators/index.mjs +3 -0
- package/esm/node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm/drivers/index.mjs +5 -0
- package/esm/node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm/drivers/rabbitmq/index.mjs +4 -0
- package/esm/node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm/drivers/rabbitmq/rabbitmq-channel.d.mts +1 -0
- package/esm/{herald/src → node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm}/drivers/rabbitmq/rabbitmq-channel.mjs +6 -13
- package/esm/node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm/drivers/rabbitmq/rabbitmq-channel.mjs.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm/drivers/rabbitmq/rabbitmq-driver.d.mts +1 -0
- package/esm/{herald/src → node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm}/drivers/rabbitmq/rabbitmq-driver.mjs +10 -11
- package/esm/node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm/drivers/rabbitmq/rabbitmq-driver.mjs.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm/index.d.mts +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm/message-managers/event-consumer.d.mts +1 -0
- package/esm/{herald/src → node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm}/message-managers/event-consumer.mjs +10 -22
- package/esm/node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm/message-managers/event-consumer.mjs.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm/message-managers/event-message.d.mts +1 -0
- package/esm/{herald/src → node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm}/message-managers/event-message.mjs +3 -20
- package/esm/node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm/message-managers/event-message.mjs.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm/message-managers/index.mjs +3 -0
- package/esm/{herald/src → node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm}/message-managers/prepare-consumer-subscription.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm/message-managers/prepare-consumer-subscription.mjs.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm/types/channel.types.d.mts +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm/types/registry.types.d.mts +1 -0
- package/esm/{herald/src → node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm}/use-case-broadcast.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm/use-case-broadcast.mjs.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm/utils/connect-to-broker.d.mts +1 -0
- package/esm/{herald/src → node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm}/utils/connect-to-broker.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm/utils/connect-to-broker.mjs.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm/utils/index.mjs +3 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/config.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/config.mjs.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/factory/index.mjs +3 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/factory/validate.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/factory/validate.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/factory/validators.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/factory/validators.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/helpers/date-helpers.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/helpers/date-helpers.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/helpers/get-field-value.mjs +3 -3
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/helpers/get-field-value.mjs.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/helpers/index.mjs +3 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/helpers/is-empty-value.mjs +10 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/helpers/is-empty-value.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/helpers/path-helpers.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/helpers/path-helpers.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/helpers/validation-helpers.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/helpers/validation-helpers.mjs.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/index.d.mts +10 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/index.mjs +7 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/mutators/array-mutators.mjs +3 -3
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/mutators/array-mutators.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/mutators/boolean-mutators.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/mutators/boolean-mutators.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/mutators/date-mutators.mjs +3 -3
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/mutators/date-mutators.mjs.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/mutators/index.mjs +8 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/mutators/number-mutators.mjs +4 -4
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/mutators/number-mutators.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/mutators/object-mutators.mjs +4 -4
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/mutators/object-mutators.mjs.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/mutators/scalar-mutators.mjs +9 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/mutators/scalar-mutators.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/mutators/string-mutators.mjs +11 -11
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/mutators/string-mutators.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/array/array-rules.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/array/array-rules.mjs.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/array/index.mjs +3 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/color/color-rules.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/color/color-rules.mjs.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/color/index.mjs +3 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/common/enum.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/common/enum.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/common/equals-field-rules.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/common/equals-field-rules.mjs.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/common/index.mjs +8 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/common/instanceof.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/common/instanceof.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/common/literal.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/common/literal.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/common/type-rules.mjs +2 -2
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/common/type-rules.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/common/unknown-key.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/common/unknown-key.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/conditional/forbidden-if-rules.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/conditional/forbidden-if-rules.mjs.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/conditional/index.mjs +12 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/conditional/present-if-rules.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/conditional/present-if-rules.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/conditional/present-unless-rules.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/conditional/present-unless-rules.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/conditional/present-with-rules.mjs +3 -3
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/conditional/present-with-rules.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/conditional/present-without-rules.mjs +3 -3
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/conditional/present-without-rules.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/conditional/required-if-rules.mjs +3 -3
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/conditional/required-if-rules.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/conditional/required-unless-rules.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/conditional/required-unless-rules.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/conditional/required-when-rule.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/conditional/required-when-rule.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/conditional/required-with-rules.mjs +3 -3
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/conditional/required-with-rules.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/conditional/required-without-rules.mjs +3 -3
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/conditional/required-without-rules.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/core/equal.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/core/equal.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/core/forbidden.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/core/forbidden.mjs.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/core/index.mjs +7 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/core/required.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/core/required.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/core/union.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/core/union.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/core/when.mjs +3 -3
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/core/when.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/date/date-comparison-rules.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/date/date-comparison-rules.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/date/date-day-rules.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/date/date-day-rules.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/date/date-field-comparison-rules.mjs +3 -3
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/date/date-field-comparison-rules.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/date/date-period-rules.mjs +3 -3
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/date/date-period-rules.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/date/date-relative-rules.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/date/date-relative-rules.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/date/date-special-rules.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/date/date-special-rules.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/date/date.mjs +3 -3
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/date/date.mjs.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/date/index.mjs +9 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/index.mjs +57 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/length/index.mjs +3 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/length/length-rules.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/length/length-rules.mjs.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/number/index.mjs +3 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/number/number-rules.mjs +3 -3
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/number/number-rules.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/scalar/accepted-rule.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/scalar/accepted-rule.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/scalar/declined-rule.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/scalar/declined-rule.mjs.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/scalar/index.mjs +4 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/string/alpha.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/string/alpha.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/string/credit-card.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/string/credit-card.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/string/email.mjs +2 -2
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/string/email.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/string/id-formats.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/string/id-formats.mjs.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/string/index.mjs +13 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/string/ip.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/string/ip.mjs.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/string/matches.mjs +4 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/string/pattern.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/string/pattern.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/string/string-comparison.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/string/string-comparison.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/string/strong-password-rule.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/string/strong-password-rule.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/string/url.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/string/url.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/string/without-whitespace.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/rules/string/without-whitespace.mjs.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/standard-schema/json-schema.d.mts +32 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/standard-schema/json-schema.d.mts.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/standard-schema/json-schema.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/standard-schema/json-schema.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/standard-schema/map-result.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/standard-schema/map-result.mjs.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/standard-schema/types.d.mts +97 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/standard-schema/types.d.mts.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/types/conditional-types.d.mts +16 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/types/conditional-types.d.mts.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/types/context-types.d.mts +42 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/types/context-types.d.mts.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/types/data-transformer-types.d.mts +30 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/types/data-transformer-types.d.mts.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/types/date-types.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/types/date-types.mjs.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/types/mutator-types.d.mts +28 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/types/mutator-types.d.mts.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/types/result-types.d.mts +17 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/types/result-types.d.mts.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/types/rule-types.d.mts +53 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/types/rule-types.d.mts.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/types/schema-types.d.mts +11 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/types/schema-types.d.mts.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/validators/any-validator.mjs +6 -9
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/any-validator.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/validators/array-validator.mjs +1 -2
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/array-validator.mjs.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/base-validator.d.mts +492 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/base-validator.d.mts.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/validators/base-validator.mjs +16 -49
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/base-validator.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/validators/boolean-validator.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/boolean-validator.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/validators/computed-validator.mjs +1 -3
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/computed-validator.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/validators/date-validator.mjs +3 -3
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/date-validator.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/validators/discriminated-union-validator.mjs +2 -6
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/discriminated-union-validator.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/validators/float-validator.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/float-validator.mjs.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/index.mjs +28 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/validators/instanceof-validator.mjs +1 -2
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/instanceof-validator.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/validators/int-validator.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/int-validator.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/validators/lazy-validator.mjs +1 -3
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/lazy-validator.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/validators/literal-validator.mjs +1 -2
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/literal-validator.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/validators/managed-validator.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/managed-validator.mjs.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/methods/equality-conditional-methods.d.mts +91 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/methods/equality-conditional-methods.d.mts.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/validators/methods/equality-conditional-methods.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/methods/equality-conditional-methods.mjs.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/methods/forbidden-methods.d.mts +59 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/methods/forbidden-methods.d.mts.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/validators/methods/forbidden-methods.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/methods/forbidden-methods.mjs.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/methods/present-methods.d.mts +103 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/methods/present-methods.d.mts.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/validators/methods/present-methods.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/methods/present-methods.mjs.map +1 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/methods/required-methods.d.mts +194 -0
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/methods/required-methods.d.mts.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/validators/methods/required-methods.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/methods/required-methods.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/validators/number-validator.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/number-validator.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/validators/numeric-validator.mjs +2 -2
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/numeric-validator.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/validators/object-validator.mjs +7 -8
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/object-validator.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/validators/primitive-validator.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/primitive-validator.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/validators/record-validator.mjs +2 -3
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/record-validator.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/validators/scalar-validator.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/scalar-validator.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/validators/string-validator.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/string-validator.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/validators/tuple-validator.mjs +1 -2
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/tuple-validator.mjs.map +1 -0
- package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/validators/union-validator.mjs +1 -1
- package/esm/node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/union-validator.mjs.map +1 -0
- package/esm/queue/bullmq-queue.d.mts +25 -0
- package/esm/queue/bullmq-queue.d.mts.map +1 -0
- package/esm/queue/bullmq-queue.mjs +65 -0
- package/esm/queue/bullmq-queue.mjs.map +1 -0
- package/esm/queue/index.d.mts +4 -1
- package/esm/queue/index.mjs +3 -0
- package/esm/queue/load-herald.d.mts.map +1 -1
- package/esm/queue/load-herald.mjs +1 -1
- package/esm/queue/load-queue.d.mts +11 -0
- package/esm/queue/load-queue.d.mts.map +1 -0
- package/esm/queue/load-queue.mjs +32 -0
- package/esm/queue/load-queue.mjs.map +1 -0
- package/esm/queue/queue-package-not-installed.error.d.mts +13 -0
- package/esm/queue/queue-package-not-installed.error.d.mts.map +1 -0
- package/esm/queue/queue-package-not-installed.error.mjs +21 -0
- package/esm/queue/queue-package-not-installed.error.mjs.map +1 -0
- package/llms-full.txt +16 -8
- package/llms.txt +1 -1
- package/package.json +14 -6
- package/skills/queue-notifications/SKILL.md +16 -8
- package/cjs/rabbitmq-driver-Dn0M0-ln.cjs +0 -3
- package/cjs/src-Cx9y1PWY.cjs.map +0 -1
- package/esm/herald/src/communicators/broker-registry.mjs.map +0 -1
- package/esm/herald/src/communicators/broker.mjs.map +0 -1
- package/esm/herald/src/communicators/index.mjs +0 -4
- package/esm/herald/src/decorators/consumable.mjs.map +0 -1
- package/esm/herald/src/decorators/index.mjs +0 -3
- package/esm/herald/src/drivers/index.mjs +0 -5
- package/esm/herald/src/drivers/rabbitmq/index.mjs +0 -4
- package/esm/herald/src/drivers/rabbitmq/rabbitmq-channel.mjs.map +0 -1
- package/esm/herald/src/drivers/rabbitmq/rabbitmq-driver.mjs.map +0 -1
- package/esm/herald/src/message-managers/event-consumer.mjs.map +0 -1
- package/esm/herald/src/message-managers/event-message.mjs.map +0 -1
- package/esm/herald/src/message-managers/index.mjs +0 -4
- package/esm/herald/src/message-managers/prepare-consumer-subscription.mjs.map +0 -1
- package/esm/herald/src/use-case-broadcast.mjs.map +0 -1
- package/esm/herald/src/utils/connect-to-broker.mjs.map +0 -1
- package/esm/herald/src/utils/index.mjs +0 -3
- package/esm/seal/src/config.mjs.map +0 -1
- package/esm/seal/src/factory/index.mjs +0 -4
- package/esm/seal/src/factory/validate.mjs.map +0 -1
- package/esm/seal/src/factory/validators.mjs.map +0 -1
- package/esm/seal/src/helpers/date-helpers.mjs.map +0 -1
- package/esm/seal/src/helpers/get-field-value.mjs.map +0 -1
- package/esm/seal/src/helpers/index.mjs +0 -6
- package/esm/seal/src/helpers/is-empty-value.mjs +0 -10
- package/esm/seal/src/helpers/is-empty-value.mjs.map +0 -1
- package/esm/seal/src/helpers/path-helpers.mjs.map +0 -1
- package/esm/seal/src/helpers/validation-helpers.mjs.map +0 -1
- package/esm/seal/src/mutators/array-mutators.mjs.map +0 -1
- package/esm/seal/src/mutators/boolean-mutators.mjs.map +0 -1
- package/esm/seal/src/mutators/date-mutators.mjs.map +0 -1
- package/esm/seal/src/mutators/index.mjs +0 -9
- package/esm/seal/src/mutators/number-mutators.mjs.map +0 -1
- package/esm/seal/src/mutators/object-mutators.mjs.map +0 -1
- package/esm/seal/src/mutators/scalar-mutators.mjs +0 -9
- package/esm/seal/src/mutators/scalar-mutators.mjs.map +0 -1
- package/esm/seal/src/mutators/string-mutators.mjs.map +0 -1
- package/esm/seal/src/rules/array/array-rules.mjs.map +0 -1
- package/esm/seal/src/rules/array/index.mjs +0 -3
- package/esm/seal/src/rules/color/color-rules.mjs.map +0 -1
- package/esm/seal/src/rules/color/index.mjs +0 -3
- package/esm/seal/src/rules/common/enum.mjs.map +0 -1
- package/esm/seal/src/rules/common/equals-field-rules.mjs.map +0 -1
- package/esm/seal/src/rules/common/index.mjs +0 -8
- package/esm/seal/src/rules/common/instanceof.mjs.map +0 -1
- package/esm/seal/src/rules/common/literal.mjs.map +0 -1
- package/esm/seal/src/rules/common/type-rules.mjs.map +0 -1
- package/esm/seal/src/rules/common/unknown-key.mjs.map +0 -1
- package/esm/seal/src/rules/conditional/forbidden-if-rules.mjs.map +0 -1
- package/esm/seal/src/rules/conditional/index.mjs +0 -12
- package/esm/seal/src/rules/conditional/present-if-rules.mjs.map +0 -1
- package/esm/seal/src/rules/conditional/present-unless-rules.mjs.map +0 -1
- package/esm/seal/src/rules/conditional/present-with-rules.mjs.map +0 -1
- package/esm/seal/src/rules/conditional/present-without-rules.mjs.map +0 -1
- package/esm/seal/src/rules/conditional/required-if-rules.mjs.map +0 -1
- package/esm/seal/src/rules/conditional/required-unless-rules.mjs.map +0 -1
- package/esm/seal/src/rules/conditional/required-when-rule.mjs.map +0 -1
- package/esm/seal/src/rules/conditional/required-with-rules.mjs.map +0 -1
- package/esm/seal/src/rules/conditional/required-without-rules.mjs.map +0 -1
- package/esm/seal/src/rules/core/equal.mjs.map +0 -1
- package/esm/seal/src/rules/core/forbidden.mjs.map +0 -1
- package/esm/seal/src/rules/core/index.mjs +0 -7
- package/esm/seal/src/rules/core/required.mjs.map +0 -1
- package/esm/seal/src/rules/core/union.mjs.map +0 -1
- package/esm/seal/src/rules/core/when.mjs.map +0 -1
- package/esm/seal/src/rules/date/date-comparison-rules.mjs.map +0 -1
- package/esm/seal/src/rules/date/date-day-rules.mjs.map +0 -1
- package/esm/seal/src/rules/date/date-field-comparison-rules.mjs.map +0 -1
- package/esm/seal/src/rules/date/date-period-rules.mjs.map +0 -1
- package/esm/seal/src/rules/date/date-relative-rules.mjs.map +0 -1
- package/esm/seal/src/rules/date/date-special-rules.mjs.map +0 -1
- package/esm/seal/src/rules/date/date.mjs.map +0 -1
- package/esm/seal/src/rules/date/index.mjs +0 -9
- package/esm/seal/src/rules/index.mjs +0 -54
- package/esm/seal/src/rules/length/index.mjs +0 -3
- package/esm/seal/src/rules/length/length-rules.mjs.map +0 -1
- package/esm/seal/src/rules/number/index.mjs +0 -3
- package/esm/seal/src/rules/number/number-rules.mjs.map +0 -1
- package/esm/seal/src/rules/scalar/accepted-rule.mjs.map +0 -1
- package/esm/seal/src/rules/scalar/declined-rule.mjs.map +0 -1
- package/esm/seal/src/rules/scalar/index.mjs +0 -4
- package/esm/seal/src/rules/string/alpha.mjs.map +0 -1
- package/esm/seal/src/rules/string/credit-card.mjs.map +0 -1
- package/esm/seal/src/rules/string/email.mjs.map +0 -1
- package/esm/seal/src/rules/string/id-formats.mjs.map +0 -1
- package/esm/seal/src/rules/string/index.mjs +0 -13
- package/esm/seal/src/rules/string/ip.mjs.map +0 -1
- package/esm/seal/src/rules/string/matches.mjs +0 -4
- package/esm/seal/src/rules/string/pattern.mjs.map +0 -1
- package/esm/seal/src/rules/string/string-comparison.mjs.map +0 -1
- package/esm/seal/src/rules/string/strong-password-rule.mjs.map +0 -1
- package/esm/seal/src/rules/string/url.mjs.map +0 -1
- package/esm/seal/src/rules/string/without-whitespace.mjs.map +0 -1
- package/esm/seal/src/standard-schema/json-schema.mjs.map +0 -1
- package/esm/seal/src/standard-schema/map-result.mjs.map +0 -1
- package/esm/seal/src/types/date-types.mjs.map +0 -1
- package/esm/seal/src/validators/any-validator.mjs.map +0 -1
- package/esm/seal/src/validators/array-validator.mjs.map +0 -1
- package/esm/seal/src/validators/base-validator.mjs.map +0 -1
- package/esm/seal/src/validators/boolean-validator.mjs.map +0 -1
- package/esm/seal/src/validators/computed-validator.mjs.map +0 -1
- package/esm/seal/src/validators/date-validator.mjs.map +0 -1
- package/esm/seal/src/validators/discriminated-union-validator.mjs.map +0 -1
- package/esm/seal/src/validators/float-validator.mjs.map +0 -1
- package/esm/seal/src/validators/index.mjs +0 -28
- package/esm/seal/src/validators/instanceof-validator.mjs.map +0 -1
- package/esm/seal/src/validators/int-validator.mjs.map +0 -1
- package/esm/seal/src/validators/lazy-validator.mjs.map +0 -1
- package/esm/seal/src/validators/literal-validator.mjs.map +0 -1
- package/esm/seal/src/validators/managed-validator.mjs.map +0 -1
- package/esm/seal/src/validators/methods/equality-conditional-methods.mjs.map +0 -1
- package/esm/seal/src/validators/methods/forbidden-methods.mjs.map +0 -1
- package/esm/seal/src/validators/methods/present-methods.mjs.map +0 -1
- package/esm/seal/src/validators/methods/required-methods.mjs.map +0 -1
- package/esm/seal/src/validators/number-validator.mjs.map +0 -1
- package/esm/seal/src/validators/numeric-validator.mjs.map +0 -1
- package/esm/seal/src/validators/object-validator.mjs.map +0 -1
- package/esm/seal/src/validators/primitive-validator.mjs.map +0 -1
- package/esm/seal/src/validators/record-validator.mjs.map +0 -1
- package/esm/seal/src/validators/scalar-validator.mjs.map +0 -1
- package/esm/seal/src/validators/string-validator.mjs.map +0 -1
- package/esm/seal/src/validators/tuple-validator.mjs.map +0 -1
- package/esm/seal/src/validators/union-validator.mjs.map +0 -1
- /package/esm/{herald/src → node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm}/index.mjs +0 -0
- /package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/file/dimensions.mjs +0 -0
- /package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/file/file-size.mjs +0 -0
- /package/esm/{seal/src → node_modules/.pnpm/@warlock.js_seal@5.14.0/node_modules/@warlock.js/seal/esm}/rules/file/index.mjs +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"record-validator.mjs","names":[],"sources":["../../../../../../../../../../../../../../node_modules/.pnpm/@warlock.js+seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/record-validator.mjs"],"sourcesContent":["import { applyNullable } from \"../standard-schema/json-schema.mjs\";\nimport { setKeyPath } from \"../helpers/path-helpers.mjs\";\nimport \"../helpers/index.mjs\";\nimport { BaseValidator } from \"./base-validator.mjs\";\nimport { objectRule, plainObjectRule } from \"../rules/common/type-rules.mjs\";\nimport \"../rules/index.mjs\";\nimport { isPlainObject } from \"@mongez/supportive-is\";\n\n//#region ../seal/src/validators/record-validator.ts\n/**\n* Record validator class - validates objects with dynamic keys and consistent value types\n*\n* @example\n* ```ts\n* // Translations object\n* v.record(v.string())\n* // Valid: { en: \"Hello\", ar: \"مرحبا\", fr: \"Bonjour\" }\n*\n* // User preferences\n* v.record(v.union([v.string(), v.number(), v.boolean()]))\n* // Valid: { theme: \"dark\", fontSize: 16, notifications: true }\n* ```\n*/\nvar RecordValidator = class extends BaseValidator {\n\tconstructor(valueValidator, errorMessage) {\n\t\tsuper();\n\t\tthis.valueValidator = valueValidator;\n\t\tthis.addMutableRule(objectRule, errorMessage);\n\t}\n\t/**\n\t* Validate it as plain object\n\t*/\n\tplainObject(errorMessage) {\n\t\treturn this.addRule(plainObjectRule, errorMessage);\n\t}\n\t/**\n\t* Check if value is a plain object type\n\t*/\n\tmatchesType(value) {\n\t\treturn isPlainObject(value);\n\t}\n\t/**\n\t* Clone the validator\n\t*/\n\tclone() {\n\t\tconst cloned = super.clone();\n\t\tcloned.valueValidator = this.valueValidator.clone();\n\t\treturn cloned;\n\t}\n\t/**\n\t* Validate record - iterate all keys and validate each value\n\t*\n\t* Absent input (and absent without `.default()`) propagates as `data: undefined`\n\t* so the parent ObjectValidator can omit the key. Without this, optional record\n\t* fields would silently materialise as `{}` in the validated output.\n\t*/\n\tasync validate(data, context) {\n\t\tconst valueForRules = data ?? this.getDefaultValue();\n\t\tconst mutatedData = await this.mutate(valueForRules, context);\n\t\tconst result = await super.validate(data, context);\n\t\tif (result.isValid === false) return result;\n\t\tif (mutatedData === void 0 || mutatedData === null) return result;\n\t\tif (!isPlainObject(mutatedData)) return result;\n\t\tconst errors = [];\n\t\tconst validationPromises = Object.keys(mutatedData).map(async (key) => {\n\t\t\tconst childContext = {\n\t\t\t\t...context,\n\t\t\t\tparent: mutatedData,\n\t\t\t\tvalue: mutatedData[key],\n\t\t\t\tkey,\n\t\t\t\tpath: setKeyPath(context.path, key)\n\t\t\t};\n\t\t\tconst childResult = await this.valueValidator.validate(mutatedData[key], childContext);\n\t\t\tmutatedData[key] = childResult.data;\n\t\t\tif (childResult.isValid === false) errors.push(...childResult.errors);\n\t\t});\n\t\tawait Promise.all(validationPromises);\n\t\treturn {\n\t\t\tisValid: errors.length === 0,\n\t\t\terrors,\n\t\t\tdata: await this.startTransformationPipeline(mutatedData, context)\n\t\t};\n\t}\n\t/**\n\t* @inheritdoc\n\t*\n\t* Generates `{ type: \"object\", additionalProperties: <valueSchema> }` —\n\t* the standard JSON Schema for a dictionary/map with homogeneous values.\n\t*\n\t* @example\n\t* ```ts\n\t* v.record(v.string()).toJsonSchema(\"draft-2020-12\")\n\t* // → { type: \"object\", additionalProperties: { type: \"string\" } }\n\t*\n\t* v.record(v.union([v.string(), v.number()])).toJsonSchema(\"draft-2020-12\")\n\t* // → { type: \"object\", additionalProperties: { oneOf: [{ type: \"string\" }, { type: \"number\" }] } }\n\t* ```\n\t*/\n\ttoJsonSchema(target = \"draft-2020-12\") {\n\t\tconst schema = {\n\t\t\ttype: \"object\",\n\t\t\tadditionalProperties: this.valueValidator.toJsonSchema(target)\n\t\t};\n\t\tif (this.isNullable) applyNullable(schema, target);\n\t\treturn schema;\n\t}\n};\n\n//#endregion\nexport { RecordValidator };\n//# sourceMappingURL=record-validator.mjs.map"],"x_google_ignoreList":[0],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AAuBA,IAAI,kBAAkB,cAAc,cAAc;CACjD,YAAY,gBAAgB,cAAc;EACzC,MAAM;EACN,KAAK,iBAAiB;EACtB,KAAK,eAAe,YAAY,YAAY;CAC7C;;;;CAIA,YAAY,cAAc;EACzB,OAAO,KAAK,QAAQ,iBAAiB,YAAY;CAClD;;;;CAIA,YAAY,OAAO;EAClB,OAAO,cAAc,KAAK;CAC3B;;;;CAIA,QAAQ;EACP,MAAM,SAAS,MAAM,MAAM;EAC3B,OAAO,iBAAiB,KAAK,eAAe,MAAM;EAClD,OAAO;CACR;;;;;;;;CAQA,MAAM,SAAS,MAAM,SAAS;EAC7B,MAAM,gBAAgB,QAAQ,KAAK,gBAAgB;EACnD,MAAM,cAAc,MAAM,KAAK,OAAO,eAAe,OAAO;EAC5D,MAAM,SAAS,MAAM,MAAM,SAAS,MAAM,OAAO;EACjD,IAAI,OAAO,YAAY,OAAO,OAAO;EACrC,IAAI,gBAAgB,KAAK,KAAK,gBAAgB,MAAM,OAAO;EAC3D,IAAI,CAAC,cAAc,WAAW,GAAG,OAAO;EACxC,MAAM,SAAS,CAAC;EAChB,MAAM,qBAAqB,OAAO,KAAK,WAAW,CAAC,CAAC,IAAI,OAAO,QAAQ;GACtE,MAAM,eAAe;IACpB,GAAG;IACH,QAAQ;IACR,OAAO,YAAY;IACnB;IACA,MAAM,WAAW,QAAQ,MAAM,GAAG;GACnC;GACA,MAAM,cAAc,MAAM,KAAK,eAAe,SAAS,YAAY,MAAM,YAAY;GACrF,YAAY,OAAO,YAAY;GAC/B,IAAI,YAAY,YAAY,OAAO,OAAO,KAAK,GAAG,YAAY,MAAM;EACrE,CAAC;EACD,MAAM,QAAQ,IAAI,kBAAkB;EACpC,OAAO;GACN,SAAS,OAAO,WAAW;GAC3B;GACA,MAAM,MAAM,KAAK,4BAA4B,aAAa,OAAO;EAClE;CACD;;;;;;;;;;;;;;;;CAgBA,aAAa,SAAS,iBAAiB;EACtC,MAAM,SAAS;GACd,MAAM;GACN,sBAAsB,KAAK,eAAe,aAAa,MAAM;EAC9D;EACA,IAAI,KAAK,YAAY,cAAc,QAAQ,MAAM;EACjD,OAAO;CACR;AACD"}
|
|
@@ -9,7 +9,7 @@ import "../mutators/index.mjs";
|
|
|
9
9
|
import { PrimitiveValidator } from "./primitive-validator.mjs";
|
|
10
10
|
import "../rules/scalar/index.mjs";
|
|
11
11
|
|
|
12
|
-
//#region ../seal/
|
|
12
|
+
//#region ../node_modules/.pnpm/@warlock.js+seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/scalar-validator.mjs
|
|
13
13
|
/**
|
|
14
14
|
* Scalar validator class
|
|
15
15
|
*
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"scalar-validator.mjs","names":[],"sources":["../../../../../../../../../../../../../../node_modules/.pnpm/@warlock.js+seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/scalar-validator.mjs"],"sourcesContent":["import { getRuleOptions } from \"../standard-schema/json-schema.mjs\";\nimport { VALID_RULE, invalidRule } from \"../helpers/validation-helpers.mjs\";\nimport \"../helpers/index.mjs\";\nimport { acceptedIfPresentRule, acceptedIfRequiredRule, acceptedIfRule, acceptedRule, acceptedUnlessRule, acceptedWithoutRule } from \"../rules/scalar/accepted-rule.mjs\";\nimport { declinedIfPresentRule, declinedIfRequiredRule, declinedIfRule, declinedRule, declinedUnlessRule, declinedWithoutRule } from \"../rules/scalar/declined-rule.mjs\";\nimport { numberMutator } from \"../mutators/number-mutators.mjs\";\nimport { stringMutator } from \"../mutators/scalar-mutators.mjs\";\nimport \"../mutators/index.mjs\";\nimport { PrimitiveValidator } from \"./primitive-validator.mjs\";\nimport \"../rules/scalar/index.mjs\";\n\n//#region ../seal/src/validators/scalar-validator.ts\n/**\n* Scalar validator class\n*\n* Core validator for scalar values (string, number, boolean).\n* Extends PrimitiveValidator (inherits enum/in/oneOf/allowsOnly/forbids/notIn)\n* and additionally provides type-coercion mutators and accepted/declined rules.\n*\n* Database methods (unique, exists, etc.) are injected by the framework\n*/\nvar ScalarValidator = class extends PrimitiveValidator {\n\tconstructor(errorMessage) {\n\t\tsuper();\n\t\tthis.addMutableRule({\n\t\t\tname: \"scalar\",\n\t\t\tdefaultErrorMessage: \"The :input must be a scalar value\",\n\t\t\tasync validate(value, context) {\n\t\t\t\tif ([\n\t\t\t\t\t\"string\",\n\t\t\t\t\t\"number\",\n\t\t\t\t\t\"boolean\"\n\t\t\t\t].includes(typeof value)) return VALID_RULE;\n\t\t\t\treturn invalidRule(this, context);\n\t\t\t}\n\t\t}, errorMessage);\n\t}\n\t/**\n\t* Add matches type\n\t*/\n\tmatchesType(value) {\n\t\treturn typeof value === \"string\" || typeof value === \"number\" || typeof value === \"boolean\";\n\t}\n\t/**\n\t* Mutate the scalar value to be number\n\t*/\n\tasNumber() {\n\t\treturn this.addMutator(numberMutator);\n\t}\n\t/**\n\t* Mutate the scalar value to be string\n\t*/\n\tasString() {\n\t\treturn this.addMutator(stringMutator);\n\t}\n\t/**\n\t* Accepted value\n\t* The value will be valid if it equals 1 | \"1\" | true | \"true\" | \"yes\" | \"y\" | \"on\"\n\t*/\n\taccepted(errorMessage) {\n\t\treturn this.addRule(acceptedRule, errorMessage);\n\t}\n\t/**\n\t* Accepted value if another field's value equals to a specific value\n\t*/\n\tacceptedIf(field, value, errorMessage) {\n\t\treturn this.addRule(acceptedIfRule, errorMessage, {\n\t\t\tfield,\n\t\t\tvalue\n\t\t});\n\t}\n\t/**\n\t* Accepted value if another field's value is not equal to the given value\n\t*/\n\tacceptedUnless(field, value, errorMessage) {\n\t\treturn this.addRule(acceptedUnlessRule, errorMessage, {\n\t\t\tfield,\n\t\t\tvalue\n\t\t});\n\t}\n\t/**\n\t* Accepted value if another field is required\n\t*/\n\tacceptedIfRequired(field, errorMessage) {\n\t\treturn this.addRule(acceptedIfRequiredRule, errorMessage, { field });\n\t}\n\t/**\n\t* Accepted value if another field is present\n\t*/\n\tacceptedIfPresent(field, errorMessage) {\n\t\treturn this.addRule(acceptedIfPresentRule, errorMessage, { field });\n\t}\n\t/**\n\t* Accepted value if another field is missing\n\t*/\n\tacceptedWithout(field, errorMessage) {\n\t\treturn this.addRule(acceptedWithoutRule, errorMessage, { field });\n\t}\n\t/**\n\t* Declined value\n\t* The value will be valid if it equals 0 | \"0\" | false | \"false\" | \"no\" | \"n\" | \"off\"\n\t*/\n\tdeclined(errorMessage) {\n\t\treturn this.addRule(declinedRule, errorMessage);\n\t}\n\t/**\n\t* Declined value if another field's value equals to a specific value\n\t*/\n\tdeclinedIf(field, value, errorMessage) {\n\t\treturn this.addRule(declinedIfRule, errorMessage, {\n\t\t\tfield,\n\t\t\tvalue\n\t\t});\n\t}\n\t/**\n\t* Declined value if another field's value is not equal to the given value\n\t*/\n\tdeclinedUnless(field, value, errorMessage) {\n\t\treturn this.addRule(declinedUnlessRule, errorMessage, {\n\t\t\tfield,\n\t\t\tvalue\n\t\t});\n\t}\n\t/**\n\t* Declined value if another field is required\n\t*/\n\tdeclinedIfRequired(field, errorMessage) {\n\t\treturn this.addRule(declinedIfRequiredRule, errorMessage, { field });\n\t}\n\t/**\n\t* Declined value if another field is present\n\t*/\n\tdeclinedIfPresent(field, errorMessage) {\n\t\treturn this.addRule(declinedIfPresentRule, errorMessage, { field });\n\t}\n\t/**\n\t* Declined value if another field is missing\n\t*/\n\tdeclinedWithout(field, errorMessage) {\n\t\treturn this.addRule(declinedWithoutRule, errorMessage, { field });\n\t}\n\t/**\n\t* @inheritdoc\n\t*\n\t* A scalar accepts string | number | boolean. If `.in()` / `.enum()` is used,\n\t* output collapses to a simple `enum` list instead.\n\t*\n\t* @example\n\t* ```ts\n\t* v.scalar().toJsonSchema(\"draft-2020-12\")\n\t* // → { oneOf: [{ type: \"string\" }, { type: \"number\" }, { type: \"boolean\" }] }\n\t*\n\t* v.scalar().in([\"active\", \"inactive\"]).toJsonSchema(\"draft-2020-12\")\n\t* // → { enum: [\"active\", \"inactive\"] }\n\t* ```\n\t*/\n\ttoJsonSchema(_target = \"draft-2020-12\") {\n\t\tconst inOpts = getRuleOptions(this.rules, \"in\");\n\t\tif (inOpts?.values && Array.isArray(inOpts.values)) return { enum: inOpts.values };\n\t\tconst enumOpts = getRuleOptions(this.rules, \"enum\");\n\t\tif (enumOpts?.enum && Array.isArray(enumOpts.enum)) return { enum: enumOpts.enum };\n\t\treturn { oneOf: [\n\t\t\t{ type: \"string\" },\n\t\t\t{ type: \"number\" },\n\t\t\t{ type: \"boolean\" }\n\t\t] };\n\t}\n};\n\n//#endregion\nexport { ScalarValidator };\n//# sourceMappingURL=scalar-validator.mjs.map"],"x_google_ignoreList":[0],"mappings":";;;;;;;;;;;;;;;;;;;;;AAqBA,IAAI,kBAAkB,cAAc,mBAAmB;CACtD,YAAY,cAAc;EACzB,MAAM;EACN,KAAK,eAAe;GACnB,MAAM;GACN,qBAAqB;GACrB,MAAM,SAAS,OAAO,SAAS;IAC9B,IAAI;KACH;KACA;KACA;IACD,CAAC,CAAC,SAAS,OAAO,KAAK,GAAG,OAAO;IACjC,OAAO,YAAY,MAAM,OAAO;GACjC;EACD,GAAG,YAAY;CAChB;;;;CAIA,YAAY,OAAO;EAClB,OAAO,OAAO,UAAU,YAAY,OAAO,UAAU,YAAY,OAAO,UAAU;CACnF;;;;CAIA,WAAW;EACV,OAAO,KAAK,WAAW,aAAa;CACrC;;;;CAIA,WAAW;EACV,OAAO,KAAK,WAAW,aAAa;CACrC;;;;;CAKA,SAAS,cAAc;EACtB,OAAO,KAAK,QAAQ,cAAc,YAAY;CAC/C;;;;CAIA,WAAW,OAAO,OAAO,cAAc;EACtC,OAAO,KAAK,QAAQ,gBAAgB,cAAc;GACjD;GACA;EACD,CAAC;CACF;;;;CAIA,eAAe,OAAO,OAAO,cAAc;EAC1C,OAAO,KAAK,QAAQ,oBAAoB,cAAc;GACrD;GACA;EACD,CAAC;CACF;;;;CAIA,mBAAmB,OAAO,cAAc;EACvC,OAAO,KAAK,QAAQ,wBAAwB,cAAc,EAAE,MAAM,CAAC;CACpE;;;;CAIA,kBAAkB,OAAO,cAAc;EACtC,OAAO,KAAK,QAAQ,uBAAuB,cAAc,EAAE,MAAM,CAAC;CACnE;;;;CAIA,gBAAgB,OAAO,cAAc;EACpC,OAAO,KAAK,QAAQ,qBAAqB,cAAc,EAAE,MAAM,CAAC;CACjE;;;;;CAKA,SAAS,cAAc;EACtB,OAAO,KAAK,QAAQ,cAAc,YAAY;CAC/C;;;;CAIA,WAAW,OAAO,OAAO,cAAc;EACtC,OAAO,KAAK,QAAQ,gBAAgB,cAAc;GACjD;GACA;EACD,CAAC;CACF;;;;CAIA,eAAe,OAAO,OAAO,cAAc;EAC1C,OAAO,KAAK,QAAQ,oBAAoB,cAAc;GACrD;GACA;EACD,CAAC;CACF;;;;CAIA,mBAAmB,OAAO,cAAc;EACvC,OAAO,KAAK,QAAQ,wBAAwB,cAAc,EAAE,MAAM,CAAC;CACpE;;;;CAIA,kBAAkB,OAAO,cAAc;EACtC,OAAO,KAAK,QAAQ,uBAAuB,cAAc,EAAE,MAAM,CAAC;CACnE;;;;CAIA,gBAAgB,OAAO,cAAc;EACpC,OAAO,KAAK,QAAQ,qBAAqB,cAAc,EAAE,MAAM,CAAC;CACjE;;;;;;;;;;;;;;;;CAgBA,aAAa,UAAU,iBAAiB;EACvC,MAAM,SAAS,eAAe,KAAK,OAAO,IAAI;EAC9C,IAAI,QAAQ,UAAU,MAAM,QAAQ,OAAO,MAAM,GAAG,OAAO,EAAE,MAAM,OAAO,OAAO;EACjF,MAAM,WAAW,eAAe,KAAK,OAAO,MAAM;EAClD,IAAI,UAAU,QAAQ,MAAM,QAAQ,SAAS,IAAI,GAAG,OAAO,EAAE,MAAM,SAAS,KAAK;EACjF,OAAO,EAAE,OAAO;GACf,EAAE,MAAM,SAAS;GACjB,EAAE,MAAM,SAAS;GACjB,EAAE,MAAM,UAAU;EACnB,EAAE;CACH;AACD"}
|
|
@@ -17,7 +17,7 @@ import { stringRule } from "../rules/common/type-rules.mjs";
|
|
|
17
17
|
import "../rules/index.mjs";
|
|
18
18
|
import { PrimitiveValidator } from "./primitive-validator.mjs";
|
|
19
19
|
|
|
20
|
-
//#region ../seal/
|
|
20
|
+
//#region ../node_modules/.pnpm/@warlock.js+seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/string-validator.mjs
|
|
21
21
|
/**
|
|
22
22
|
* String validator class
|
|
23
23
|
*/
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"string-validator.mjs","names":[],"sources":["../../../../../../../../../../../../../../node_modules/.pnpm/@warlock.js+seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/string-validator.mjs"],"sourcesContent":["import { applyNullable, getRuleOptions } from \"../standard-schema/json-schema.mjs\";\nimport { alphaOnlyMutator, alphanumericOnlyMutator, appendMutator, base64DecodeMutator, base64EncodeMutator, camelCaseMutator, capitalizeMutator, htmlEscapeMutator, kebabCaseMutator, lowercaseMutator, ltrimMutator, maskMutator, padEndMutator, padStartMutator, pascalCaseMutator, prependMutator, removeNumbersMutator, removeSpecialCharactersMutator, repeatMutator, replaceAllMutator, replaceMutator, reverseMutator, rtrimMutator, slugMutator, snakeCaseMutator, stringifyMutator, stripTagsMutator, titleCaseMutator, trimMultipleWhitespaceMutator, trimMutator, truncateMutator, unescapeHtmlMutator, uppercaseMutator, urlDecodeMutator, urlEncodeMutator } from \"../mutators/string-mutators.mjs\";\nimport \"../mutators/index.mjs\";\nimport { alphaNumericRule, alphaRule, isNumericRule } from \"../rules/string/alpha.mjs\";\nimport { isCreditCardRule } from \"../rules/string/credit-card.mjs\";\nimport { emailRule } from \"../rules/string/email.mjs\";\nimport { cuidRule, nanoidRule, ulidRule, uuidRule } from \"../rules/string/id-formats.mjs\";\nimport { ip4Rule, ip6Rule, ipRule } from \"../rules/string/ip.mjs\";\nimport { patternRule } from \"../rules/string/pattern.mjs\";\nimport { containsRule, endsWithRule, notContainsRule, startsWithRule } from \"../rules/string/string-comparison.mjs\";\nimport { strongPasswordRule } from \"../rules/string/strong-password-rule.mjs\";\nimport { urlRule } from \"../rules/string/url.mjs\";\nimport { withoutWhitespaceRule } from \"../rules/string/without-whitespace.mjs\";\nimport { betweenLengthRule, lengthRule, maxLengthRule, maxWordsRule, minLengthRule, minWordsRule, wordsRule } from \"../rules/length/length-rules.mjs\";\nimport { colorRule, darkColorRule, hexColorRule, hslColorRule, lightColorRule, rgbColorRule, rgbaColorRule } from \"../rules/color/color-rules.mjs\";\nimport { stringRule } from \"../rules/common/type-rules.mjs\";\nimport \"../rules/index.mjs\";\nimport { PrimitiveValidator } from \"./primitive-validator.mjs\";\n\n//#region ../seal/src/validators/string-validator.ts\n/**\n* String validator class\n*/\nvar StringValidator = class extends PrimitiveValidator {\n\tconstructor(errorMessage) {\n\t\tsuper();\n\t\tthis.addMutableRule(stringRule, errorMessage);\n\t}\n\t/**\n\t* Check if value is a string type\n\t*/\n\tmatchesType(value) {\n\t\treturn typeof value === \"string\";\n\t}\n\t/**\n\t* Stringify the value if not a string\n\t*/\n\ttoString() {\n\t\treturn this.addMutator(stringifyMutator);\n\t}\n\t/** Convert string to uppercase */\n\tuppercase() {\n\t\treturn this.addMutator(uppercaseMutator);\n\t}\n\t/** Convert string to lowercase */\n\tlowercase() {\n\t\treturn this.addMutator(lowercaseMutator);\n\t}\n\t/** Capitalize only the first letter of the string */\n\tcapitalize() {\n\t\treturn this.addMutator(capitalizeMutator);\n\t}\n\t/** Capitalize the first letter of each word (Title Case) */\n\ttitleCase() {\n\t\treturn this.addMutator(titleCaseMutator);\n\t}\n\t/** Convert to camelCase */\n\tcamelCase() {\n\t\treturn this.addMutator(camelCaseMutator);\n\t}\n\t/** Convert to PascalCase */\n\tpascalCase() {\n\t\treturn this.addMutator(pascalCaseMutator);\n\t}\n\t/** Convert to snake_case */\n\tsnakeCase() {\n\t\treturn this.addMutator(snakeCaseMutator);\n\t}\n\t/** Convert to kebab-case */\n\tkebabCase() {\n\t\treturn this.addMutator(kebabCaseMutator);\n\t}\n\t/**\n\t* Trim the given needle from the string\n\t* If no needle is provided, the default is a single space\n\t*/\n\ttrim(needle) {\n\t\treturn this.addMutator(trimMutator, { needle });\n\t}\n\t/** Trim from the left/start */\n\tltrim(needle) {\n\t\treturn this.addMutator(ltrimMutator, { needle });\n\t}\n\t/** Trim from the right/end */\n\trtrim(needle) {\n\t\treturn this.addMutator(rtrimMutator, { needle });\n\t}\n\t/** Trim multiple whitespace into single space */\n\ttrimMultipleWhitespace() {\n\t\treturn this.addMutator(trimMultipleWhitespaceMutator);\n\t}\n\t/** Pad string from the start to reach target length */\n\tpadStart(length, char = \" \") {\n\t\treturn this.addMutator(padStartMutator, {\n\t\t\tlength,\n\t\t\tchar\n\t\t});\n\t}\n\t/** Pad string from the end to reach target length */\n\tpadEnd(length, char = \" \") {\n\t\treturn this.addMutator(padEndMutator, {\n\t\t\tlength,\n\t\t\tchar\n\t\t});\n\t}\n\t/**\n\t* Strip HTML tags with a naive `<...>` regex.\n\t*\n\t* This is a **tag stripper, not an XSS sanitizer**: it is not a parser,\n\t* so malformed/nested markup or content re-introduced later in a\n\t* pipeline can defeat it. Do not rely on this alone to make untrusted\n\t* rich text safe to render — use a real parser-based sanitizer (e.g.\n\t* DOMPurify / sanitize-html) for that.\n\t*/\n\tstripTags() {\n\t\treturn this.addMutator(stripTagsMutator);\n\t}\n\t/**\n\t* @deprecated Renamed to {@link StringValidator.stripTags} — the old\n\t* name implied XSS safety this tag-stripping regex does not provide.\n\t* Kept as an alias for backward compatibility; switch to `.stripTags()`.\n\t*/\n\tsafeHtml() {\n\t\treturn this.stripTags();\n\t}\n\t/** HTML escape special characters */\n\thtmlEscape() {\n\t\treturn this.addMutator(htmlEscapeMutator);\n\t}\n\t/** Unescape HTML entities */\n\tunescapeHtml() {\n\t\treturn this.addMutator(unescapeHtmlMutator);\n\t}\n\t/**\n\t* Remove special characters\n\t* This will remove all characters that are not alphanumeric or whitespace\n\t*/\n\tremoveSpecialCharacters() {\n\t\treturn this.addMutator(removeSpecialCharactersMutator);\n\t}\n\t/** Convert to only alphabetic characters */\n\ttoAlpha() {\n\t\treturn this.addMutator(alphaOnlyMutator);\n\t}\n\t/** Convert to only alphanumeric characters */\n\ttoAlphanumeric() {\n\t\treturn this.addMutator(alphanumericOnlyMutator);\n\t}\n\t/** Remove all numeric characters */\n\tremoveNumbers() {\n\t\treturn this.addMutator(removeNumbersMutator);\n\t}\n\t/** URL decode */\n\turlDecode() {\n\t\treturn this.addMutator(urlDecodeMutator);\n\t}\n\t/** URL encode */\n\turlEncode() {\n\t\treturn this.addMutator(urlEncodeMutator);\n\t}\n\t/** Convert to URL-friendly slug */\n\tslug() {\n\t\treturn this.addMutator(slugMutator);\n\t}\n\t/** Base64 encode */\n\tbase64Encode() {\n\t\treturn this.addMutator(base64EncodeMutator);\n\t}\n\t/** Base64 decode */\n\tbase64Decode() {\n\t\treturn this.addMutator(base64DecodeMutator);\n\t}\n\t/** Replace substring or pattern */\n\treplace(search, replace) {\n\t\treturn this.addMutator(replaceMutator, {\n\t\t\tsearch,\n\t\t\treplace\n\t\t});\n\t}\n\t/** Replace all occurrences of substring or pattern */\n\treplaceAll(search, replace) {\n\t\treturn this.addMutator(replaceAllMutator, {\n\t\t\tsearch,\n\t\t\treplace\n\t\t});\n\t}\n\t/** Append/suffix text to the end */\n\tappend(suffix) {\n\t\treturn this.addMutator(appendMutator, { suffix });\n\t}\n\t/** Prepend/prefix text to the beginning */\n\tprepend(prefix) {\n\t\treturn this.addMutator(prependMutator, { prefix });\n\t}\n\t/** Reverse the string */\n\treverse() {\n\t\treturn this.addMutator(reverseMutator);\n\t}\n\t/** Truncate to a maximum length */\n\ttruncate(maxLength, suffix = \"...\") {\n\t\treturn this.addMutator(truncateMutator, {\n\t\t\tmaxLength,\n\t\t\tsuffix\n\t\t});\n\t}\n\t/** Repeat string N times */\n\trepeat(count) {\n\t\treturn this.addMutator(repeatMutator, { count });\n\t}\n\t/** Mask part of string */\n\tmask(start, end, char = \"*\") {\n\t\treturn this.addMutator(maskMutator, {\n\t\t\tstart,\n\t\t\tend,\n\t\t\tchar\n\t\t});\n\t}\n\t/** Value must be a valid email */\n\temail(errorMessage) {\n\t\treturn this.addRule(emailRule, errorMessage);\n\t}\n\t/** Value must be a valid URL */\n\turl(errorMessage) {\n\t\treturn this.addRule(urlRule, errorMessage);\n\t}\n\t/** Value can not have whitespace */\n\twithoutWhitespace(errorMessage) {\n\t\treturn this.addRule(withoutWhitespaceRule, errorMessage);\n\t}\n\t/** Value must match the given pattern */\n\tpattern(pattern, errorMessage) {\n\t\treturn this.addRule(patternRule, errorMessage, { pattern });\n\t}\n\t/**\n\t* Value must be a strong password\n\t* Requirements:\n\t* - At least 8 characters\n\t* - At least 1 uppercase letter\n\t* - At least 1 lowercase letter\n\t* - At least 1 number\n\t* - At least 1 special character\n\t*/\n\tstrongPassword(minLength, errorMessage) {\n\t\treturn this.addRule(strongPasswordRule, errorMessage, { minLength });\n\t}\n\t/** Value must be exactly the given number of words */\n\twords(words, errorMessage) {\n\t\treturn this.addRule(wordsRule, errorMessage, { words });\n\t}\n\t/** Value must be at least the given number of words */\n\tminWords(words, errorMessage) {\n\t\treturn this.addRule(minWordsRule, errorMessage, { minWords: words });\n\t}\n\t/** Value must be at most the given number of words */\n\tmaxWords(words, errorMessage) {\n\t\treturn this.addRule(maxWordsRule, errorMessage, { maxWords: words });\n\t}\n\t/** Value length must be greater than the given length */\n\tminLength(length, errorMessage) {\n\t\treturn this.addRule(minLengthRule, errorMessage, { minLength: length });\n\t}\n\t/** @alias minLength */\n\tmin(min, errorMessage) {\n\t\treturn this.minLength(min, errorMessage);\n\t}\n\t/** Value length must be less than the given length */\n\tmaxLength(length, errorMessage) {\n\t\treturn this.addRule(maxLengthRule, errorMessage, { maxLength: length });\n\t}\n\t/** @alias maxLength */\n\tmax(max, errorMessage) {\n\t\treturn this.maxLength(max, errorMessage);\n\t}\n\t/** Value must be of the given length */\n\tlength(length, errorMessage) {\n\t\treturn this.addRule(lengthRule, errorMessage, { length });\n\t}\n\t/**\n\t* String length must be between min and max (inclusive)\n\t*\n\t* @param min - Minimum length (inclusive)\n\t* @param max - Maximum length (inclusive)\n\t*\n\t* @example\n\t* ```ts\n\t* v.string().between(5, 10) // Length: 5 to 10 characters\n\t* v.string().lengthBetween(8, 20) // Same using alias\n\t* ```\n\t*\n\t* @category Validation Rule\n\t*/\n\tlengthBetween(min, max, errorMessage) {\n\t\treturn this.addRule(betweenLengthRule, errorMessage, {\n\t\t\tminLength: min,\n\t\t\tmaxLength: max\n\t\t});\n\t}\n\t/** Allow only alphabetic characters */\n\talpha(errorMessage) {\n\t\treturn this.addRule(alphaRule, errorMessage);\n\t}\n\t/** Allow only alphanumeric characters */\n\talphanumeric(errorMessage) {\n\t\treturn this.addRule(alphaNumericRule, errorMessage);\n\t}\n\t/** Allow only numeric characters */\n\tnumeric(errorMessage) {\n\t\treturn this.addRule(isNumericRule, errorMessage);\n\t}\n\t/** Value must starts with the given string */\n\tstartsWith(value, errorMessage) {\n\t\treturn this.addRule(startsWithRule, errorMessage, { value });\n\t}\n\t/** Value must ends with the given string */\n\tendsWith(value, errorMessage) {\n\t\treturn this.addRule(endsWithRule, errorMessage, { value });\n\t}\n\t/** Value must contain the given string */\n\tcontains(value, errorMessage) {\n\t\treturn this.addRule(containsRule, errorMessage, { value });\n\t}\n\t/** Value must not contain the given string */\n\tnotContains(value, errorMessage) {\n\t\treturn this.addRule(notContainsRule, errorMessage, { value });\n\t}\n\t/** Value must be a valid IP address */\n\tip(errorMessage) {\n\t\treturn this.addRule(ipRule, errorMessage);\n\t}\n\t/** Value must be a valid IPv4 address */\n\tip4(errorMessage) {\n\t\treturn this.addRule(ip4Rule, errorMessage);\n\t}\n\t/** Value must be a valid IPv6 address */\n\tip6(errorMessage) {\n\t\treturn this.addRule(ip6Rule, errorMessage);\n\t}\n\t/** Check if the string matches a credit card number */\n\tcreditCard(errorMessage) {\n\t\treturn this.addRule(isCreditCardRule, errorMessage);\n\t}\n\t/** Determine if the value is a valid color */\n\tcolor(errorMessage) {\n\t\treturn this.addRule(colorRule, errorMessage);\n\t}\n\t/** Determine if the value is a valid hex color */\n\thexColor(errorMessage) {\n\t\treturn this.addRule(hexColorRule, errorMessage);\n\t}\n\t/** Determine if the value is a valid HSL color */\n\thslColor(errorMessage) {\n\t\treturn this.addRule(hslColorRule, errorMessage);\n\t}\n\t/** Determine if the value is a valid RGB color */\n\trgbColor(errorMessage) {\n\t\treturn this.addRule(rgbColorRule, errorMessage);\n\t}\n\t/** Determine if the value is a valid RGBA color */\n\trgbaColor(errorMessage) {\n\t\treturn this.addRule(rgbaColorRule, errorMessage);\n\t}\n\t/** Determine if the value is a valid light color */\n\tlightColor(errorMessage) {\n\t\treturn this.addRule(lightColorRule, errorMessage);\n\t}\n\t/** Determine if the value is a valid dark color */\n\tdarkColor(errorMessage) {\n\t\treturn this.addRule(darkColorRule, errorMessage);\n\t}\n\t/**\n\t* Value must be a valid UUID. Optionally restrict to a specific version.\n\t*\n\t* @example\n\t* v.string().uuid() // any RFC 4122 UUID\n\t* v.string().uuid(4) // only v4 (random)\n\t* v.string().uuid(7) // only v7 (timestamp-ordered)\n\t*/\n\tuuid(version, errorMessage) {\n\t\treturn this.addRule(uuidRule, errorMessage, { version });\n\t}\n\t/**\n\t* Value must be a valid CUID. Defaults to CUID2; pass `{ version: 1 }` for legacy.\n\t*\n\t* @example\n\t* v.string().cuid() // CUID2\n\t* v.string().cuid({ version: 1 }) // legacy CUID1\n\t*/\n\tcuid(options) {\n\t\tconst { errorMessage, version } = options ?? {};\n\t\treturn this.addRule(cuidRule, errorMessage, { version });\n\t}\n\t/** Value must be a valid ULID (26 chars, Crockford base32). */\n\tulid(errorMessage) {\n\t\treturn this.addRule(ulidRule, errorMessage);\n\t}\n\t/**\n\t* Value must be a valid nanoid string. Default length is 21.\n\t*\n\t* @example\n\t* v.string().nanoid() // 21 chars (default)\n\t* v.string().nanoid(10) // 10 chars\n\t*/\n\tnanoid(length, errorMessage) {\n\t\treturn this.addRule(nanoidRule, errorMessage, { length });\n\t}\n\t/**\n\t* @inheritdoc\n\t*\n\t* Maps String-specific rule options to JSON Schema keywords.\n\t* Non-representable rules (cross-field, refine, color rules, etc.) are silently omitted.\n\t*\n\t* @example\n\t* ```ts\n\t* v.string().min(2).max(100).email().toJsonSchema(\"draft-2020-12\")\n\t* // → { type: \"string\", minLength: 2, maxLength: 100, format: \"email\" }\n\t* ```\n\t*/\n\ttoJsonSchema(target = \"draft-2020-12\") {\n\t\tconst schema = { type: \"string\" };\n\t\tconst minOpts = getRuleOptions(this.rules, \"minLength\");\n\t\tif (minOpts?.minLength !== void 0) schema.minLength = minOpts.minLength;\n\t\tconst maxOpts = getRuleOptions(this.rules, \"maxLength\");\n\t\tif (maxOpts?.maxLength !== void 0) schema.maxLength = maxOpts.maxLength;\n\t\tconst betweenOpts = getRuleOptions(this.rules, \"betweenLength\");\n\t\tif (betweenOpts) {\n\t\t\tif (betweenOpts.minLength !== void 0) schema.minLength = betweenOpts.minLength;\n\t\t\tif (betweenOpts.maxLength !== void 0) schema.maxLength = betweenOpts.maxLength;\n\t\t}\n\t\tconst lengthOpts = getRuleOptions(this.rules, \"length\");\n\t\tif (lengthOpts?.length !== void 0) {\n\t\t\tschema.minLength = lengthOpts.length;\n\t\t\tschema.maxLength = lengthOpts.length;\n\t\t}\n\t\tconst patternOpts = getRuleOptions(this.rules, \"pattern\");\n\t\tif (patternOpts?.pattern instanceof RegExp) schema.pattern = patternOpts.pattern.source;\n\t\tif (getRuleOptions(this.rules, \"email\") !== void 0 || this.rules.some((r) => r.name === \"email\")) schema.format = \"email\";\n\t\telse if (this.rules.some((r) => r.name === \"url\")) schema.format = \"uri\";\n\t\telse if (this.rules.some((r) => r.name === \"ip\")) schema.format = \"ipv4\";\n\t\telse if (this.rules.some((r) => r.name === \"ip4\")) schema.format = \"ipv4\";\n\t\telse if (this.rules.some((r) => r.name === \"ip6\")) schema.format = \"ipv6\";\n\t\telse if (this.rules.some((r) => r.name === \"uuid\")) schema.format = \"uuid\";\n\t\telse if (this.rules.some((r) => r.name === \"hexColor\")) schema.format = \"color\";\n\t\tif (!schema.format) {\n\t\t\tconst cuidOpts = getRuleOptions(this.rules, \"cuid\");\n\t\t\tif (cuidOpts) schema.pattern = cuidOpts.version === 1 ? \"^c[a-z0-9]{24,}$\" : \"^[a-z][a-z0-9]{23}$\";\n\t\t\tif (this.rules.some((r) => r.name === \"ulid\")) schema.pattern = \"^[0-9A-HJKMNP-TV-Z]{26}$\";\n\t\t\tconst nanoidOpts = getRuleOptions(this.rules, \"nanoid\");\n\t\t\tif (nanoidOpts) schema.pattern = `^[A-Za-z0-9_-]{${nanoidOpts.length ?? 21}}$`;\n\t\t}\n\t\tconst inOpts = getRuleOptions(this.rules, \"in\");\n\t\tif (inOpts?.values && Array.isArray(inOpts.values)) schema.enum = inOpts.values;\n\t\tif (this.isNullable) applyNullable(schema, target);\n\t\treturn schema;\n\t}\n};\n\n//#endregion\nexport { StringValidator };\n//# sourceMappingURL=string-validator.mjs.map"],"x_google_ignoreList":[0],"mappings":"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"}
|
|
@@ -5,7 +5,7 @@ import { BaseValidator } from "./base-validator.mjs";
|
|
|
5
5
|
import { arrayRule } from "../rules/common/type-rules.mjs";
|
|
6
6
|
import "../rules/index.mjs";
|
|
7
7
|
|
|
8
|
-
//#region ../seal/
|
|
8
|
+
//#region ../node_modules/.pnpm/@warlock.js+seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/tuple-validator.mjs
|
|
9
9
|
/**
|
|
10
10
|
* Tuple validator class - validates fixed-length arrays with position-specific types
|
|
11
11
|
*
|
|
@@ -22,7 +22,6 @@ import "../rules/index.mjs";
|
|
|
22
22
|
* ```
|
|
23
23
|
*/
|
|
24
24
|
var TupleValidator = class extends BaseValidator {
|
|
25
|
-
validators;
|
|
26
25
|
constructor(validators, errorMessage) {
|
|
27
26
|
super();
|
|
28
27
|
this.validators = validators;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tuple-validator.mjs","names":[],"sources":["../../../../../../../../../../../../../../node_modules/.pnpm/@warlock.js+seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/tuple-validator.mjs"],"sourcesContent":["import { applyNullable } from \"../standard-schema/json-schema.mjs\";\nimport { setKeyPath } from \"../helpers/path-helpers.mjs\";\nimport \"../helpers/index.mjs\";\nimport { BaseValidator } from \"./base-validator.mjs\";\nimport { arrayRule } from \"../rules/common/type-rules.mjs\";\nimport \"../rules/index.mjs\";\n\n//#region ../seal/src/validators/tuple-validator.ts\n/**\n* Tuple validator class - validates fixed-length arrays with position-specific types\n*\n* @example\n* ```ts\n* // RGB color tuple\n* v.tuple([v.number(), v.number(), v.number()])\n* // Valid: [255, 128, 0]\n* // Invalid: [255, 128] (too short)\n*\n* // Mixed types\n* v.tuple([v.string(), v.int(), v.boolean()])\n* // Valid: [\"John\", 25, true]\n* ```\n*/\nvar TupleValidator = class extends BaseValidator {\n\tconstructor(validators, errorMessage) {\n\t\tsuper();\n\t\tthis.validators = validators;\n\t\tthis.addMutableRule(arrayRule, errorMessage);\n\t}\n\t/**\n\t* Check if value is an array type\n\t*/\n\tmatchesType(value) {\n\t\treturn Array.isArray(value);\n\t}\n\t/**\n\t* Clone the validator\n\t*/\n\tclone() {\n\t\tconst cloned = super.clone();\n\t\tcloned.validators = this.validators.map((v) => v.clone());\n\t\treturn cloned;\n\t}\n\t/**\n\t* Validate tuple - check length then validate each position\n\t*\n\t* Absent input (and absent without `.default()`) propagates as `data: undefined`\n\t* so the parent ObjectValidator can omit the key. Without this, optional tuple\n\t* fields would silently materialise as `[]` in the validated output and then\n\t* fail the length check.\n\t*/\n\tasync validate(data, context) {\n\t\tconst valueForRules = data ?? this.getDefaultValue();\n\t\tconst mutatedData = await this.mutate(valueForRules, context);\n\t\tconst result = await super.validate(data, context);\n\t\tif (result.isValid === false) return result;\n\t\tif (mutatedData === void 0 || mutatedData === null) return result;\n\t\tif (!Array.isArray(mutatedData)) return result;\n\t\tconst errors = [];\n\t\tif (mutatedData.length !== this.validators.length) {\n\t\t\terrors.push({\n\t\t\t\ttype: \"tuple\",\n\t\t\t\tinput: context.key || \"value\",\n\t\t\t\terror: `Expected exactly ${this.validators.length} items, but got ${mutatedData.length}`\n\t\t\t});\n\t\t\treturn {\n\t\t\t\tisValid: false,\n\t\t\t\terrors,\n\t\t\t\tdata: mutatedData\n\t\t\t};\n\t\t}\n\t\tconst validationPromises = this.validators.map(async (validator, index) => {\n\t\t\tconst childContext = {\n\t\t\t\t...context,\n\t\t\t\tparent: mutatedData,\n\t\t\t\tvalue: mutatedData[index],\n\t\t\t\tkey: index.toString(),\n\t\t\t\tpath: setKeyPath(context.path, index.toString())\n\t\t\t};\n\t\t\tconst childResult = await validator.validate(mutatedData[index], childContext);\n\t\t\tmutatedData[index] = childResult.data;\n\t\t\tif (childResult.isValid === false) errors.push(...childResult.errors);\n\t\t});\n\t\tawait Promise.all(validationPromises);\n\t\treturn {\n\t\t\tisValid: errors.length === 0,\n\t\t\terrors,\n\t\t\tdata: await this.startTransformationPipeline(mutatedData, context)\n\t\t};\n\t}\n\t/**\n\t* @inheritdoc\n\t*\n\t* Tuple keyword diverges between targets:\n\t* - `draft-2020-12` → `prefixItems` + `items: false` (exact length enforced)\n\t* - `draft-07` → `items` as array + `additionalItems: false`\n\t* - `openapi-3.0` → same as draft-07 (OpenAPI 3.0 is based on draft-07)\n\t*\n\t* @example\n\t* ```ts\n\t* v.tuple([v.string(), v.int(), v.boolean()]).toJsonSchema(\"draft-2020-12\")\n\t* // → {\n\t* // type: \"array\",\n\t* // prefixItems: [{ type: \"string\" }, { type: \"integer\" }, { type: \"boolean\" }],\n\t* // items: false,\n\t* // minItems: 3,\n\t* // maxItems: 3\n\t* // }\n\t* ```\n\t*/\n\ttoJsonSchema(target = \"draft-2020-12\") {\n\t\tconst itemSchemas = this.validators.map((v) => v.toJsonSchema(target));\n\t\tconst length = this.validators.length;\n\t\tconst schema = {\n\t\t\ttype: \"array\",\n\t\t\tminItems: length,\n\t\t\tmaxItems: length\n\t\t};\n\t\tif (target === \"draft-2020-12\") {\n\t\t\tschema.prefixItems = itemSchemas;\n\t\t\tschema.items = false;\n\t\t} else {\n\t\t\tschema.items = itemSchemas;\n\t\t\tschema.additionalItems = false;\n\t\t}\n\t\tif (this.isNullable) applyNullable(schema, target);\n\t\treturn schema;\n\t}\n};\n\n//#endregion\nexport { TupleValidator };\n//# sourceMappingURL=tuple-validator.mjs.map"],"x_google_ignoreList":[0],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AAuBA,IAAI,iBAAiB,cAAc,cAAc;CAChD,YAAY,YAAY,cAAc;EACrC,MAAM;EACN,KAAK,aAAa;EAClB,KAAK,eAAe,WAAW,YAAY;CAC5C;;;;CAIA,YAAY,OAAO;EAClB,OAAO,MAAM,QAAQ,KAAK;CAC3B;;;;CAIA,QAAQ;EACP,MAAM,SAAS,MAAM,MAAM;EAC3B,OAAO,aAAa,KAAK,WAAW,KAAK,MAAM,EAAE,MAAM,CAAC;EACxD,OAAO;CACR;;;;;;;;;CASA,MAAM,SAAS,MAAM,SAAS;EAC7B,MAAM,gBAAgB,QAAQ,KAAK,gBAAgB;EACnD,MAAM,cAAc,MAAM,KAAK,OAAO,eAAe,OAAO;EAC5D,MAAM,SAAS,MAAM,MAAM,SAAS,MAAM,OAAO;EACjD,IAAI,OAAO,YAAY,OAAO,OAAO;EACrC,IAAI,gBAAgB,KAAK,KAAK,gBAAgB,MAAM,OAAO;EAC3D,IAAI,CAAC,MAAM,QAAQ,WAAW,GAAG,OAAO;EACxC,MAAM,SAAS,CAAC;EAChB,IAAI,YAAY,WAAW,KAAK,WAAW,QAAQ;GAClD,OAAO,KAAK;IACX,MAAM;IACN,OAAO,QAAQ,OAAO;IACtB,OAAO,oBAAoB,KAAK,WAAW,OAAO,kBAAkB,YAAY;GACjF,CAAC;GACD,OAAO;IACN,SAAS;IACT;IACA,MAAM;GACP;EACD;EACA,MAAM,qBAAqB,KAAK,WAAW,IAAI,OAAO,WAAW,UAAU;GAC1E,MAAM,eAAe;IACpB,GAAG;IACH,QAAQ;IACR,OAAO,YAAY;IACnB,KAAK,MAAM,SAAS;IACpB,MAAM,WAAW,QAAQ,MAAM,MAAM,SAAS,CAAC;GAChD;GACA,MAAM,cAAc,MAAM,UAAU,SAAS,YAAY,QAAQ,YAAY;GAC7E,YAAY,SAAS,YAAY;GACjC,IAAI,YAAY,YAAY,OAAO,OAAO,KAAK,GAAG,YAAY,MAAM;EACrE,CAAC;EACD,MAAM,QAAQ,IAAI,kBAAkB;EACpC,OAAO;GACN,SAAS,OAAO,WAAW;GAC3B;GACA,MAAM,MAAM,KAAK,4BAA4B,aAAa,OAAO;EAClE;CACD;;;;;;;;;;;;;;;;;;;;;CAqBA,aAAa,SAAS,iBAAiB;EACtC,MAAM,cAAc,KAAK,WAAW,KAAK,MAAM,EAAE,aAAa,MAAM,CAAC;EACrE,MAAM,SAAS,KAAK,WAAW;EAC/B,MAAM,SAAS;GACd,MAAM;GACN,UAAU;GACV,UAAU;EACX;EACA,IAAI,WAAW,iBAAiB;GAC/B,OAAO,cAAc;GACrB,OAAO,QAAQ;EAChB,OAAO;GACN,OAAO,QAAQ;GACf,OAAO,kBAAkB;EAC1B;EACA,IAAI,KAAK,YAAY,cAAc,QAAQ,MAAM;EACjD,OAAO;CACR;AACD"}
|
|
@@ -3,7 +3,7 @@ import { BaseValidator } from "./base-validator.mjs";
|
|
|
3
3
|
import { unionRule } from "../rules/core/union.mjs";
|
|
4
4
|
import "../rules/index.mjs";
|
|
5
5
|
|
|
6
|
-
//#region ../seal/
|
|
6
|
+
//#region ../node_modules/.pnpm/@warlock.js+seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/union-validator.mjs
|
|
7
7
|
/**
|
|
8
8
|
* Union validator class - validates value against multiple validator types
|
|
9
9
|
*
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"union-validator.mjs","names":[],"sources":["../../../../../../../../../../../../../../node_modules/.pnpm/@warlock.js+seal@5.14.0/node_modules/@warlock.js/seal/esm/validators/union-validator.mjs"],"sourcesContent":["import { getRuleOptions } from \"../standard-schema/json-schema.mjs\";\nimport { BaseValidator } from \"./base-validator.mjs\";\nimport { unionRule } from \"../rules/core/union.mjs\";\nimport \"../rules/index.mjs\";\n\n//#region ../seal/src/validators/union-validator.ts\n/**\n* Union validator class - validates value against multiple validator types\n*\n* Tries each validator in order until one passes. If a validator's matchesType()\n* returns false, it's skipped for optimization. First validator that both matches\n* the type and passes validation wins.\n*\n* @example\n* ```ts\n* // Accept email or username\n* const identifier = v.union([\n* v.string().email(),\n* v.string().alphanumeric().min(3).max(20)\n* ]);\n*\n* // Accept different types\n* const customValue = v.union([\n* v.string().required(),\n* v.number().required(),\n* v.boolean().required(),\n* v.file().required()\n* ]);\n* ```\n*/\nvar UnionValidator = class extends BaseValidator {\n\t/**\n\t* Set the validators to try for union validation\n\t*\n\t* @param validators - Array of validators to try\n\t* @param errorMessage - Optional custom error message if all validators fail\n\t* @returns This validator for chaining\n\t*\n\t* @example\n\t* ```ts\n\t* new UnionValidator()\n\t* .union([v.string(), v.number()], 'Must be string or number');\n\t* ```\n\t*/\n\tunion(validators, errorMessage) {\n\t\treturn this.addRule(unionRule, errorMessage, { validators });\n\t}\n\t/**\n\t* @inheritdoc\n\t*\n\t* Generates `{ oneOf: [...] }` by mapping each sub-validator to its JSON Schema.\n\t*\n\t* @example\n\t* ```ts\n\t* v.union([v.string(), v.number()]).toJsonSchema(\"draft-2020-12\")\n\t* // → { oneOf: [{ type: \"string\" }, { type: \"number\" }] }\n\t* ```\n\t*/\n\ttoJsonSchema(target = \"draft-2020-12\") {\n\t\treturn { oneOf: (getRuleOptions(this.rules, \"union\")?.validators ?? []).map((v) => v.toJsonSchema(target)) };\n\t}\n};\n\n//#endregion\nexport { UnionValidator };\n//# sourceMappingURL=union-validator.mjs.map"],"x_google_ignoreList":[0],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA8BA,IAAI,iBAAiB,cAAc,cAAc;;;;;;;;;;;;;;CAchD,MAAM,YAAY,cAAc;EAC/B,OAAO,KAAK,QAAQ,WAAW,cAAc,EAAE,WAAW,CAAC;CAC5D;;;;;;;;;;;;CAYA,aAAa,SAAS,iBAAiB;EACtC,OAAO,EAAE,QAAQ,eAAe,KAAK,OAAO,OAAO,CAAC,EAAE,cAAc,CAAC,EAAC,CAAE,KAAK,MAAM,EAAE,aAAa,MAAM,CAAC,EAAE;CAC5G;AACD"}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { QueueDispatcher } from "../contracts/queue-dispatcher.contract.mjs";
|
|
2
|
+
import { JobBackoff } from "@warlock.js/queue";
|
|
3
|
+
|
|
4
|
+
//#region ../notifications/src/queue/bullmq-queue.d.ts
|
|
5
|
+
/** The job name notification deliveries run under. */
|
|
6
|
+
declare const NOTIFICATION_JOB_NAME = "warlock.notifications.deliver";
|
|
7
|
+
type BullmqQueueOptions = {
|
|
8
|
+
/** Queue to deliver on. Default: `@warlock.js/queue`'s default queue. */queue?: string; /** Attempts per delivery. Default: `queue.defaultJobOptions.attempts`, else `1`. */
|
|
9
|
+
attempts?: number; /** Backoff between attempts. */
|
|
10
|
+
backoff?: JobBackoff;
|
|
11
|
+
};
|
|
12
|
+
/**
|
|
13
|
+
* Create the `QueueDispatcher` for `NotificationConfig.queue` backed by
|
|
14
|
+
* `@warlock.js/queue`.
|
|
15
|
+
*
|
|
16
|
+
* - `SendOptions.delay` is honoured: a number is SECONDS (notifications'
|
|
17
|
+
* convention), a string is a duration such as `"10m"` (`@warlock.js/queue`'s
|
|
18
|
+
* convention).
|
|
19
|
+
* - A channel missing from the worker's notifications config throws — the
|
|
20
|
+
* delivery is retried per `attempts` / `backoff` like any other failure.
|
|
21
|
+
*/
|
|
22
|
+
declare function bullmqQueue(options: BullmqQueueOptions): QueueDispatcher;
|
|
23
|
+
//#endregion
|
|
24
|
+
export { BullmqQueueOptions, NOTIFICATION_JOB_NAME, bullmqQueue };
|
|
25
|
+
//# sourceMappingURL=bullmq-queue.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"bullmq-queue.d.mts","names":[],"sources":["../../../../../../../notifications/src/queue/bullmq-queue.ts"],"mappings":";;;;;cA8Ba,qBAAA;AAAA,KAED,kBAAA;EA0B6D,yEAxBvE,KAAA;EAEA,QAAA;EAEA,OAAA,GAAU,UAAU;AAAA;;;;;;;;;;;iBAoBN,WAAA,CAAY,OAAA,EAAS,kBAAA,GAAqB,eAAe"}
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
import { getNotificationConfig } from "../config.mjs";
|
|
2
|
+
import { loadQueuePackage } from "./load-queue.mjs";
|
|
3
|
+
|
|
4
|
+
//#region ../notifications/src/queue/bullmq-queue.ts
|
|
5
|
+
/** The job name notification deliveries run under. */
|
|
6
|
+
const NOTIFICATION_JOB_NAME = "warlock.notifications.deliver";
|
|
7
|
+
/**
|
|
8
|
+
* Create the `QueueDispatcher` for `NotificationConfig.queue` backed by
|
|
9
|
+
* `@warlock.js/queue`.
|
|
10
|
+
*
|
|
11
|
+
* - `SendOptions.delay` is honoured: a number is SECONDS (notifications'
|
|
12
|
+
* convention), a string is a duration such as `"10m"` (`@warlock.js/queue`'s
|
|
13
|
+
* convention).
|
|
14
|
+
* - A channel missing from the worker's notifications config throws — the
|
|
15
|
+
* delivery is retried per `attempts` / `backoff` like any other failure.
|
|
16
|
+
*/
|
|
17
|
+
function bullmqQueue(options) {
|
|
18
|
+
let jobPromise;
|
|
19
|
+
return { async dispatch(job) {
|
|
20
|
+
if (!jobPromise) jobPromise = defineNotificationJob(options);
|
|
21
|
+
await (await jobPromise).dispatch({
|
|
22
|
+
channel: job.channel,
|
|
23
|
+
route: job.route,
|
|
24
|
+
payload: job.payload,
|
|
25
|
+
options: job.options
|
|
26
|
+
}, { delay: job.options.delay === void 0 ? void 0 : notificationDelay(job.options.delay) });
|
|
27
|
+
} };
|
|
28
|
+
}
|
|
29
|
+
async function defineNotificationJob(options) {
|
|
30
|
+
const { defineJob } = await loadQueuePackage();
|
|
31
|
+
return defineJob({
|
|
32
|
+
name: NOTIFICATION_JOB_NAME,
|
|
33
|
+
queue: options.queue,
|
|
34
|
+
attempts: options.attempts,
|
|
35
|
+
backoff: options.backoff,
|
|
36
|
+
async handle(job) {
|
|
37
|
+
const channel = getNotificationConfig().channels[job.channel];
|
|
38
|
+
if (!channel) throw new Error(`Notification channel "${job.channel}" is not configured in this worker's notifications config.`);
|
|
39
|
+
await channel.send({
|
|
40
|
+
payload: job.payload,
|
|
41
|
+
route: job.route,
|
|
42
|
+
options: job.options
|
|
43
|
+
});
|
|
44
|
+
}
|
|
45
|
+
});
|
|
46
|
+
}
|
|
47
|
+
function notificationDelay(delay) {
|
|
48
|
+
return typeof delay === "number" ? delay * 1e3 : toMilliseconds(delay);
|
|
49
|
+
}
|
|
50
|
+
function toMilliseconds(value) {
|
|
51
|
+
const units = {
|
|
52
|
+
ms: 1,
|
|
53
|
+
s: 1e3,
|
|
54
|
+
m: 6e4,
|
|
55
|
+
h: 36e5,
|
|
56
|
+
d: 864e5
|
|
57
|
+
};
|
|
58
|
+
const match = /^(\d+(?:\.\d+)?)(ms|s|m|h|d)$/.exec(value.trim());
|
|
59
|
+
if (!match) throw new Error(`Invalid duration "${value}": expected a number of milliseconds or a string like "500ms", "30s", "10m", "2h", "1d".`);
|
|
60
|
+
return Math.round(Number(match[1]) * units[match[2]]);
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
//#endregion
|
|
64
|
+
export { NOTIFICATION_JOB_NAME, bullmqQueue };
|
|
65
|
+
//# sourceMappingURL=bullmq-queue.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"bullmq-queue.mjs","names":[],"sources":["../../../../../../../notifications/src/queue/bullmq-queue.ts"],"sourcesContent":["/**\n * BullMQ-backed `QueueDispatcher` — an alternative to `heraldQueue()` for apps\n * that already run `@warlock.js/queue` and would rather deliver notifications\n * through it than stand up a herald broker.\n *\n * `defineNotification` renders the payload + resolves the route BEFORE\n * handing a job to the dispatcher, so the job (`{ channel, route, payload,\n * options }`) is plain JSON — the same contract `heraldQueue` relies on.\n *\n * `@warlock.js/queue` is an OPTIONAL peer, lazy-loaded via `loadQueuePackage`\n * on first `.dispatch()` — never at import time — so notifications never pays\n * for `@warlock.js/queue` unless `bullmqQueue()` is actually configured.\n *\n * @example src/config/notifications.ts — declarative; the connector registers it\n * import { type NotificationConfig, bullmqQueue, mailChannel } from \"@warlock.js/notifications\";\n *\n * const config: NotificationConfig = {\n * channels: { mail: mailChannel() },\n * queue: bullmqQueue({ attempts: 3, backoff: { type: \"exponential\", delay: 5000 } }),\n * };\n *\n * export default config;\n */\nimport type { JobBackoff } from \"@warlock.js/queue\";\nimport type { QueueDispatcher } from \"../contracts\";\nimport { getNotificationConfig } from \"../config\";\nimport type { ChannelName, SendOptions } from \"../types\";\nimport { loadQueuePackage } from \"./load-queue\";\n\n/** The job name notification deliveries run under. */\nexport const NOTIFICATION_JOB_NAME = \"warlock.notifications.deliver\";\n\nexport type BullmqQueueOptions = {\n /** Queue to deliver on. Default: `@warlock.js/queue`'s default queue. */\n queue?: string;\n /** Attempts per delivery. Default: `queue.defaultJobOptions.attempts`, else `1`. */\n attempts?: number;\n /** Backoff between attempts. */\n backoff?: JobBackoff;\n};\n\ntype NotificationJobPayload = {\n channel: string;\n route: unknown;\n payload: unknown;\n options: SendOptions;\n};\n\n/**\n * Create the `QueueDispatcher` for `NotificationConfig.queue` backed by\n * `@warlock.js/queue`.\n *\n * - `SendOptions.delay` is honoured: a number is SECONDS (notifications'\n * convention), a string is a duration such as `\"10m\"` (`@warlock.js/queue`'s\n * convention).\n * - A channel missing from the worker's notifications config throws — the\n * delivery is retried per `attempts` / `backoff` like any other failure.\n */\nexport function bullmqQueue(options: BullmqQueueOptions): QueueDispatcher {\n let jobPromise: ReturnType<typeof defineNotificationJob> | undefined;\n\n return {\n async dispatch(job) {\n if (!jobPromise) {\n jobPromise = defineNotificationJob(options);\n }\n\n const notificationJob = await jobPromise;\n\n await notificationJob.dispatch(\n { channel: job.channel, route: job.route, payload: job.payload, options: job.options },\n { delay: job.options.delay === undefined ? undefined : notificationDelay(job.options.delay) },\n );\n },\n };\n}\n\nasync function defineNotificationJob(options: BullmqQueueOptions) {\n const { defineJob } = await loadQueuePackage();\n\n return defineJob<NotificationJobPayload, void>({\n name: NOTIFICATION_JOB_NAME,\n queue: options.queue,\n attempts: options.attempts,\n backoff: options.backoff,\n async handle(job) {\n const channel = getNotificationConfig().channels[job.channel as ChannelName];\n\n if (!channel) {\n throw new Error(\n `Notification channel \"${job.channel}\" is not configured in this worker's notifications config.`,\n );\n }\n\n await channel.send({ payload: job.payload, route: job.route, options: job.options } as never);\n },\n });\n}\n\nfunction notificationDelay(delay: number | string): number {\n return typeof delay === \"number\" ? delay * 1_000 : toMilliseconds(delay);\n}\n\n// `toMilliseconds` mirrors `@warlock.js/queue`'s duration parser but is\n// inlined here so this file doesn't need a non-lazy import from the optional\n// peer just to convert a string like \"10m\".\nfunction toMilliseconds(value: string): number {\n const units: Record<string, number> = { ms: 1, s: 1_000, m: 60_000, h: 3_600_000, d: 86_400_000 };\n const match = /^(\\d+(?:\\.\\d+)?)(ms|s|m|h|d)$/.exec(value.trim());\n\n if (!match) {\n throw new Error(\n `Invalid duration \"${value}\": expected a number of milliseconds or a string like ` +\n `\"500ms\", \"30s\", \"10m\", \"2h\", \"1d\".`,\n );\n }\n\n return Math.round(Number(match[1]) * units[match[2]!]!);\n}\n"],"mappings":";;;;;AA8BA,MAAa,wBAAwB;;;;;;;;;;;AA4BrC,SAAgB,YAAY,SAA8C;CACxE,IAAI;CAEJ,OAAO,EACL,MAAM,SAAS,KAAK;EAClB,IAAI,CAAC,YACH,aAAa,sBAAsB,OAAO;EAK5C,OAAM,MAFwB,WAET,CAAC,SACpB;GAAE,SAAS,IAAI;GAAS,OAAO,IAAI;GAAO,SAAS,IAAI;GAAS,SAAS,IAAI;EAAQ,GACrF,EAAE,OAAO,IAAI,QAAQ,UAAU,SAAY,SAAY,kBAAkB,IAAI,QAAQ,KAAK,EAAE,CAC9F;CACF,EACF;AACF;AAEA,eAAe,sBAAsB,SAA6B;CAChE,MAAM,EAAE,cAAc,MAAM,iBAAiB;CAE7C,OAAO,UAAwC;EAC7C,MAAM;EACN,OAAO,QAAQ;EACf,UAAU,QAAQ;EAClB,SAAS,QAAQ;EACjB,MAAM,OAAO,KAAK;GAChB,MAAM,UAAU,sBAAsB,CAAC,CAAC,SAAS,IAAI;GAErD,IAAI,CAAC,SACH,MAAM,IAAI,MACR,yBAAyB,IAAI,QAAQ,2DACvC;GAGF,MAAM,QAAQ,KAAK;IAAE,SAAS,IAAI;IAAS,OAAO,IAAI;IAAO,SAAS,IAAI;GAAQ,CAAU;EAC9F;CACF,CAAC;AACH;AAEA,SAAS,kBAAkB,OAAgC;CACzD,OAAO,OAAO,UAAU,WAAW,QAAQ,MAAQ,eAAe,KAAK;AACzE;AAKA,SAAS,eAAe,OAAuB;CAC7C,MAAM,QAAgC;EAAE,IAAI;EAAG,GAAG;EAAO,GAAG;EAAQ,GAAG;EAAW,GAAG;CAAW;CAChG,MAAM,QAAQ,gCAAgC,KAAK,MAAM,KAAK,CAAC;CAE/D,IAAI,CAAC,OACH,MAAM,IAAI,MACR,qBAAqB,MAAM,yFAE7B;CAGF,OAAO,KAAK,MAAM,OAAO,MAAM,EAAE,IAAI,MAAM,MAAM,GAAK;AACxD"}
|
package/esm/queue/index.d.mts
CHANGED
|
@@ -1,3 +1,6 @@
|
|
|
1
1
|
import { HeraldQueueOptions, heraldQueue } from "./herald-queue.mjs";
|
|
2
2
|
import { WorkerOptions, startNotificationsWorker } from "./notifications-worker.mjs";
|
|
3
|
-
import { DEFAULT_QUEUE_CHANNEL } from "./load-herald.mjs";
|
|
3
|
+
import { DEFAULT_QUEUE_CHANNEL } from "./load-herald.mjs";
|
|
4
|
+
import { BullmqQueueOptions, NOTIFICATION_JOB_NAME, bullmqQueue } from "./bullmq-queue.mjs";
|
|
5
|
+
import { QueuePackageLoader, loadQueuePackage } from "./load-queue.mjs";
|
|
6
|
+
import { QueuePackageNotInstalledError } from "./queue-package-not-installed.error.mjs";
|
package/esm/queue/index.mjs
CHANGED
|
@@ -1,5 +1,8 @@
|
|
|
1
1
|
import { DEFAULT_QUEUE_CHANNEL } from "./load-herald.mjs";
|
|
2
2
|
import { heraldQueue } from "./herald-queue.mjs";
|
|
3
3
|
import { startNotificationsWorker } from "./notifications-worker.mjs";
|
|
4
|
+
import { QueuePackageNotInstalledError } from "./queue-package-not-installed.error.mjs";
|
|
5
|
+
import { loadQueuePackage } from "./load-queue.mjs";
|
|
6
|
+
import { NOTIFICATION_JOB_NAME, bullmqQueue } from "./bullmq-queue.mjs";
|
|
4
7
|
|
|
5
8
|
export { };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"load-herald.d.mts","names":[],"sources":["../../../../../../../notifications/src/queue/load-herald.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"load-herald.d.mts","names":[],"sources":["../../../../../../../notifications/src/queue/load-herald.ts"],"mappings":";;cAmCa,qBAAA"}
|
|
@@ -21,7 +21,7 @@ Or with your preferred package manager:
|
|
|
21
21
|
async function loadHerald() {
|
|
22
22
|
if (heraldModule) return heraldModule;
|
|
23
23
|
try {
|
|
24
|
-
heraldModule = await import("../herald/
|
|
24
|
+
heraldModule = await import("../node_modules/.pnpm/@warlock.js_herald@5.14.0_@_3471b04ef54e023074af1a6880918ea2/node_modules/@warlock.js/herald/esm/index.mjs");
|
|
25
25
|
return heraldModule;
|
|
26
26
|
} catch {
|
|
27
27
|
throw new Error(INSTALL_INSTRUCTIONS);
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
//#region ../notifications/src/queue/load-queue.d.ts
|
|
2
|
+
/** A function that performs the dynamic import of `@warlock.js/queue`. */
|
|
3
|
+
type QueuePackageLoader = () => Promise<typeof import("@warlock.js/queue")>;
|
|
4
|
+
/**
|
|
5
|
+
* Resolve `@warlock.js/queue`, memoized after the first successful load.
|
|
6
|
+
* Throws {@link QueuePackageNotInstalledError} when the import fails.
|
|
7
|
+
*/
|
|
8
|
+
declare function loadQueuePackage(loader?: QueuePackageLoader): Promise<typeof import("@warlock.js/queue")>;
|
|
9
|
+
//#endregion
|
|
10
|
+
export { QueuePackageLoader, loadQueuePackage };
|
|
11
|
+
//# sourceMappingURL=load-queue.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"load-queue.d.mts","names":[],"sources":["../../../../../../../notifications/src/queue/load-queue.ts"],"mappings":";;KAaY,kBAAA,SAA2B,OAAO;;;;AAAA;iBAUxB,gBAAA,CACpB,MAAA,GAAQ,kBAAA,GACP,OAAO"}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { QueuePackageNotInstalledError } from "./queue-package-not-installed.error.mjs";
|
|
2
|
+
|
|
3
|
+
//#region ../notifications/src/queue/load-queue.ts
|
|
4
|
+
/**
|
|
5
|
+
* Lazily load `@warlock.js/queue` — the optional peer backing the `bullmq`
|
|
6
|
+
* queue driver (`bullmqQueue()`). Mirrors `loadHerald`'s lazy-optional-peer
|
|
7
|
+
* pattern: the dynamic import runs at most once and is memoized, and a
|
|
8
|
+
* missing package surfaces a curated, named error at USE time rather than a
|
|
9
|
+
* boot-time resolution error.
|
|
10
|
+
*
|
|
11
|
+
* The `loader` parameter exists so specs can inject a failing import without
|
|
12
|
+
* needing the real package installed or uninstalled.
|
|
13
|
+
*/
|
|
14
|
+
const defaultLoader = () => import("@warlock.js/queue");
|
|
15
|
+
let queueModule;
|
|
16
|
+
/**
|
|
17
|
+
* Resolve `@warlock.js/queue`, memoized after the first successful load.
|
|
18
|
+
* Throws {@link QueuePackageNotInstalledError} when the import fails.
|
|
19
|
+
*/
|
|
20
|
+
async function loadQueuePackage(loader = defaultLoader) {
|
|
21
|
+
if (queueModule) return queueModule;
|
|
22
|
+
try {
|
|
23
|
+
queueModule = await loader();
|
|
24
|
+
return queueModule;
|
|
25
|
+
} catch {
|
|
26
|
+
throw new QueuePackageNotInstalledError();
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
//#endregion
|
|
31
|
+
export { loadQueuePackage };
|
|
32
|
+
//# sourceMappingURL=load-queue.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"load-queue.mjs","names":[],"sources":["../../../../../../../notifications/src/queue/load-queue.ts"],"sourcesContent":["/**\n * Lazily load `@warlock.js/queue` — the optional peer backing the `bullmq`\n * queue driver (`bullmqQueue()`). Mirrors `loadHerald`'s lazy-optional-peer\n * pattern: the dynamic import runs at most once and is memoized, and a\n * missing package surfaces a curated, named error at USE time rather than a\n * boot-time resolution error.\n *\n * The `loader` parameter exists so specs can inject a failing import without\n * needing the real package installed or uninstalled.\n */\nimport { QueuePackageNotInstalledError } from \"./queue-package-not-installed.error\";\n\n/** A function that performs the dynamic import of `@warlock.js/queue`. */\nexport type QueuePackageLoader = () => Promise<typeof import(\"@warlock.js/queue\")>;\n\nconst defaultLoader: QueuePackageLoader = () => import(\"@warlock.js/queue\");\n\nlet queueModule: typeof import(\"@warlock.js/queue\") | undefined;\n\n/**\n * Resolve `@warlock.js/queue`, memoized after the first successful load.\n * Throws {@link QueuePackageNotInstalledError} when the import fails.\n */\nexport async function loadQueuePackage(\n loader: QueuePackageLoader = defaultLoader,\n): Promise<typeof import(\"@warlock.js/queue\")> {\n if (queueModule) {\n return queueModule;\n }\n\n try {\n queueModule = await loader();\n return queueModule;\n } catch {\n throw new QueuePackageNotInstalledError();\n }\n}\n"],"mappings":";;;;;;;;;;;;;AAeA,MAAM,sBAA0C,OAAO;AAEvD,IAAI;;;;;AAMJ,eAAsB,iBACpB,SAA6B,eACgB;CAC7C,IAAI,aACF,OAAO;CAGT,IAAI;EACF,cAAc,MAAM,OAAO;EAC3B,OAAO;CACT,QAAQ;EACN,MAAM,IAAI,8BAA8B;CAC1C;AACF"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
//#region ../notifications/src/queue/queue-package-not-installed.error.d.ts
|
|
2
|
+
/**
|
|
3
|
+
* Thrown when the `bullmq` queue driver (`bullmqQueue()`) is configured but
|
|
4
|
+
* `@warlock.js/queue` — an optional peer — isn't installed. Surfaced at USE
|
|
5
|
+
* time (first `.queue()` call), not at boot, matching the lazy-optional-peer
|
|
6
|
+
* pattern `loadHerald` already uses for `@warlock.js/herald`.
|
|
7
|
+
*/
|
|
8
|
+
declare class QueuePackageNotInstalledError extends Error {
|
|
9
|
+
constructor();
|
|
10
|
+
}
|
|
11
|
+
//#endregion
|
|
12
|
+
export { QueuePackageNotInstalledError };
|
|
13
|
+
//# sourceMappingURL=queue-package-not-installed.error.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"queue-package-not-installed.error.d.mts","names":[],"sources":["../../../../../../../notifications/src/queue/queue-package-not-installed.error.ts"],"mappings":";;AAeA;;;;;cAAa,6BAAA,SAAsC,KAAK;EAAL,WAAA;AAAA"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
//#region ../notifications/src/queue/queue-package-not-installed.error.ts
|
|
2
|
+
/**
|
|
3
|
+
* Thrown when the `bullmq` queue driver (`bullmqQueue()`) is configured but
|
|
4
|
+
* `@warlock.js/queue` — an optional peer — isn't installed. Surfaced at USE
|
|
5
|
+
* time (first `.queue()` call), not at boot, matching the lazy-optional-peer
|
|
6
|
+
* pattern `loadHerald` already uses for `@warlock.js/herald`.
|
|
7
|
+
*/
|
|
8
|
+
function captureStack(target, ctor) {
|
|
9
|
+
Error.captureStackTrace?.(target, ctor);
|
|
10
|
+
}
|
|
11
|
+
var QueuePackageNotInstalledError = class QueuePackageNotInstalledError extends Error {
|
|
12
|
+
constructor() {
|
|
13
|
+
super("The bullmq notifications queue driver requires @warlock.js/queue, which isn't installed. Install it with:\n\n warlock add queue\n\nOr with your preferred package manager:\n\n pnpm add @warlock.js/queue\n npm install @warlock.js/queue\n yarn add @warlock.js/queue");
|
|
14
|
+
this.name = "QueuePackageNotInstalledError";
|
|
15
|
+
captureStack(this, QueuePackageNotInstalledError);
|
|
16
|
+
}
|
|
17
|
+
};
|
|
18
|
+
|
|
19
|
+
//#endregion
|
|
20
|
+
export { QueuePackageNotInstalledError };
|
|
21
|
+
//# sourceMappingURL=queue-package-not-installed.error.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"queue-package-not-installed.error.mjs","names":[],"sources":["../../../../../../../notifications/src/queue/queue-package-not-installed.error.ts"],"sourcesContent":["/**\n * Thrown when the `bullmq` queue driver (`bullmqQueue()`) is configured but\n * `@warlock.js/queue` — an optional peer — isn't installed. Surfaced at USE\n * time (first `.queue()` call), not at boot, matching the lazy-optional-peer\n * pattern `loadHerald` already uses for `@warlock.js/herald`.\n */\n\nfunction captureStack(target: object, ctor: new (...args: any[]) => unknown): void {\n // V8 only; guarded for non-V8 runtimes.\n (Error as unknown as { captureStackTrace?: (t: object, c: unknown) => void }).captureStackTrace?.(\n target,\n ctor,\n );\n}\n\nexport class QueuePackageNotInstalledError extends Error {\n public constructor() {\n super(\n \"The bullmq notifications queue driver requires @warlock.js/queue, which isn't installed. \" +\n \"Install it with:\\n\\n\" +\n \" warlock add queue\\n\\n\" +\n \"Or with your preferred package manager:\\n\\n\" +\n \" pnpm add @warlock.js/queue\\n\" +\n \" npm install @warlock.js/queue\\n\" +\n \" yarn add @warlock.js/queue\",\n );\n this.name = \"QueuePackageNotInstalledError\";\n captureStack(this, QueuePackageNotInstalledError);\n }\n}\n"],"mappings":";;;;;;;AAOA,SAAS,aAAa,QAAgB,MAA6C;CAEjF,AAAC,MAA6E,oBAC5E,QACA,IACF;AACF;AAEA,IAAa,gCAAb,MAAa,sCAAsC,MAAM;CACvD,AAAO,cAAc;EACnB,MACE,4QAOF;EACA,KAAK,OAAO;EACZ,aAAa,MAAM,6BAA6B;CAClD;AACF"}
|
package/llms-full.txt
CHANGED
|
@@ -570,7 +570,7 @@ A handler that throws is logged and swallowed — the other handlers for the sam
|
|
|
570
570
|
|
|
571
571
|
---
|
|
572
572
|
name: queue-notifications
|
|
573
|
-
description: "Send notifications asynchronously through the herald backend or the BullMQ
|
|
573
|
+
description: "Send notifications asynchronously through the herald backend or the BullMQ driver. Configure a QueueDispatcher in config/notifications.ts, then use notif.queue(to, data, options?) to enqueue rendered jobs. Herald uses heraldQueue() and startNotificationsWorker(); bullmqQueue({ attempts, backoff }) from @warlock.js/notifications uses BullMQ (lazy-loading the optional @warlock.js/queue peer), supports retries, and honours SendOptions.delay. Without a queue configured, .queue() rejects NoQueueDispatcherError. Triggers: heraldQueue, bullmqQueue, startNotificationsWorker, QueueDispatcher, .queue(, async notifications, queue notifications, notification worker, background notifications, notifications.dispatch. Skip: synchronous sends - @warlock.js/notifications/define-notification/SKILL.md; herald itself - @warlock.js/herald/*."
|
|
574
574
|
---
|
|
575
575
|
|
|
576
576
|
# Queue notifications (async)
|
|
@@ -603,24 +603,32 @@ if that package is missing, the first `.queue()` throws an install message.
|
|
|
603
603
|
|
|
604
604
|
## Use BullMQ for delayed or retried delivery
|
|
605
605
|
|
|
606
|
-
|
|
607
|
-
|
|
606
|
+
Use the `bullmq` driver instead of the herald dispatcher — it ships inside
|
|
607
|
+
`@warlock.js/notifications` itself and lazy-loads `@warlock.js/queue` (an
|
|
608
|
+
OPTIONAL peer) the first time `.queue()` runs:
|
|
608
609
|
|
|
609
610
|
```ts title="src/config/notifications.ts"
|
|
610
|
-
import { type NotificationConfig, mailChannel } from "@warlock.js/notifications";
|
|
611
|
-
import { queueNotificationDispatcher } from "@warlock.js/queue/notifications";
|
|
611
|
+
import { type NotificationConfig, bullmqQueue, mailChannel } from "@warlock.js/notifications";
|
|
612
612
|
|
|
613
613
|
const config: NotificationConfig = {
|
|
614
614
|
channels: { mail: mailChannel() },
|
|
615
|
-
queue:
|
|
615
|
+
queue: bullmqQueue({ attempts: 3, backoff: { type: "exponential", delay: 5000 } }),
|
|
616
616
|
};
|
|
617
617
|
|
|
618
618
|
export default config;
|
|
619
619
|
```
|
|
620
620
|
|
|
621
|
-
The BullMQ
|
|
621
|
+
The BullMQ driver honours `SendOptions.delay`: numeric delays are seconds and
|
|
622
622
|
string delays use the normal duration syntax, such as `"10m"`. It also supports
|
|
623
|
-
BullMQ retries through `attempts` and `backoff`.
|
|
623
|
+
BullMQ retries through `attempts` and `backoff`. If `@warlock.js/queue` isn't
|
|
624
|
+
installed, the first `.queue()` throws `QueuePackageNotInstalledError` naming
|
|
625
|
+
`warlock add queue`.
|
|
626
|
+
|
|
627
|
+
> **Removed (5.15.0):** `queueNotificationDispatcher` from
|
|
628
|
+
> `@warlock.js/queue/notifications` — deprecated in 5.14, removed this
|
|
629
|
+
> release, along with the `@warlock.js/notifications` peer dependency it was
|
|
630
|
+
> the only reason `@warlock.js/queue` carried. Use `bullmqQueue` above — same
|
|
631
|
+
> option names (`queue`, `attempts`, `backoff`).
|
|
624
632
|
|
|
625
633
|
## Run the herald worker
|
|
626
634
|
|
package/llms.txt
CHANGED
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
- [define-notification](@warlock.js/notifications/define-notification/SKILL.md): Build a reusable multi-channel notification with `defineNotification<Data>({ type, via, ...renderers })`. `type` is the stable identifier preference/rate-limit gates use AND defaults the database channel's `type`. `via` is `ChannelName[]` OR `(data, to) => ChannelName[]` for per-recipient channel selection. Renderers are `(data, to, ctx) => NotificationChannels[C]`; `ctx` carries `locale` + `meta` from `SendOptions`. The returned object exposes `.send(to|to[], data, options?)`, `.queue(to|to[], data, options?)`, and `.only(...channels)`. Per-recipient + per-channel `Promise.allSettled` isolates failures; the database channel's `type` is auto-defaulted from `def.type`; `SendOptions.idempotencyKey` is injected into the database payload. Triggers: `defineNotification`, `via`, "reusable notification", "multi-channel notification", "send through several channels at once", "render per channel", `RenderContext`, `def.type`; "force on a notification", "queue with delay"; typical import `import { defineNotification } from "@warlock.js/notifications"`. Skip: single-channel ad-hoc sends — `@warlock.js/notifications/send-ad-hoc/SKILL.md`; adding a brand-new channel — `@warlock.js/notifications/define-channel/SKILL.md`; observing dispatch outcomes — `@warlock.js/notifications/observe-notifications/SKILL.md`.
|
|
12
12
|
- [notifications-basics](@warlock.js/notifications/notifications-basics/SKILL.md): Front-door for `@warlock.js/notifications` — what the package is, when to reach for it, and the four moving parts (channel registry, defineNotification, notify, inApp). Multi-channel dispatch: define once, fire anywhere. Recipients are cascade `Model` instances; payloads are typed per channel via a declaration-merge `NotificationChannels` registry; reusable definitions go through `defineNotification`; ad-hoc per-channel sends go through the `notify.<channel>` proxy; the in-app database channel is read via the `inApp` facade. Phase 1 ships `mail` + `database`; bridges-backed channels (whatsapp/telegram/push/slack) arrive in Phase 2. Triggers: `defineNotification`, `notify.<channel>`, `inApp.configure`, `setNotificationConfig`, `NotificationConfig`, `NotificationChannels`; "send a notification", "in-app notifications", "what channels can I use", "what is `@warlock.js/notifications`", "where do I start"; typical import `import { defineNotification, notify, inApp } from "@warlock.js/notifications"`. Skip: configuring channels in `config/notifications.ts` — `@warlock.js/notifications/configure-notifications/SKILL.md`; building a multi-channel definition — `@warlock.js/notifications/define-notification/SKILL.md`; reading in-app rows — `@warlock.js/notifications/use-in-app/SKILL.md`.
|
|
13
13
|
- [observe-notifications](@warlock.js/notifications/observe-notifications/SKILL.md): Wire metrics, logging, tracing, and audits via `notifications.on(event, handler)` — four events fire per (channel, recipient): `sending` (gates passed, about to hit the transport), `sent` (succeeded), `failed` (channel threw — carries the Error), `skipped` (a pre-send gate dropped it — carries `reason: "preference" | "rate-limit"`). Every event carries the recipient as `notifiable?` (undefined only for raw-target ad-hoc sends) and a `dispatchId` — `sending` and its terminal `sent`/`failed` share it, so observers can pair them (spans, latency, hung-send detection). `sent`/`failed` also carry `durationMs`. Handler exceptions are logged-and-swallowed so one bad listener can not break the dispatcher. `on(...)` returns an unsubscribe function; `off(event, handler)` exists for symmetry. Triggers: `notifications.on`, `notifications.off`, `"sending"` event, `"sent"` event, `"failed"` event, `"skipped"` event, `dispatchId`, `durationMs`, `NotificationEvents`, "notification metrics", "notification latency", "trace notifications", "notification audit log", "track notification drops"; typical import `import { notifications } from "@warlock.js/notifications"`. Skip: building notifications — `@warlock.js/notifications/define-notification/SKILL.md`; configuring the preference/rate-limit gates that produce `skipped` — `@warlock.js/notifications/configure-notifications/SKILL.md`.
|
|
14
|
-
- [queue-notifications](@warlock.js/notifications/queue-notifications/SKILL.md): Send notifications asynchronously through the herald backend or the BullMQ
|
|
14
|
+
- [queue-notifications](@warlock.js/notifications/queue-notifications/SKILL.md): Send notifications asynchronously through the herald backend or the BullMQ driver. Configure a QueueDispatcher in config/notifications.ts, then use notif.queue(to, data, options?) to enqueue rendered jobs. Herald uses heraldQueue() and startNotificationsWorker(); bullmqQueue({ attempts, backoff }) from @warlock.js/notifications uses BullMQ (lazy-loading the optional @warlock.js/queue peer), supports retries, and honours SendOptions.delay. Without a queue configured, .queue() rejects NoQueueDispatcherError. Triggers: heraldQueue, bullmqQueue, startNotificationsWorker, QueueDispatcher, .queue(, async notifications, queue notifications, notification worker, background notifications, notifications.dispatch. Skip: synchronous sends - @warlock.js/notifications/define-notification/SKILL.md; herald itself - @warlock.js/herald/*.
|
|
15
15
|
- [send-ad-hoc](@warlock.js/notifications/send-ad-hoc/SKILL.md): Ad-hoc per-channel send via the `notify.<channel>(to, payload, options?)` Proxy facade. Works for any channel registered in `NotificationChannels` (built-in or custom). `to` accepts a `Notifiable` model OR a raw route string (`"x@y.com"`); `payload` is typed per channel via the registry; `options` is the standard `SendOptions`. `notify.channel(name).send(...)` is the runtime escape when the channel name is not a compile-time literal. Type-based preference gating applies when a type is known — explicit via `options.type` OR auto-detected from a database payload's `type` field. For multi-channel sends use `defineNotification` instead — there is no inline `notify(to, { via, ... })` form on purpose. Triggers: `notify.<channel>`, `notify.channel(name)`, `notify.mail`, `notify.database`, "send a one-off notification", "ad-hoc notification", "send an email without defining a notification", "raw email target", "dynamic channel name"; typical import `import { notify } from "@warlock.js/notifications"`. Skip: reusable multi-channel notifications — `@warlock.js/notifications/define-notification/SKILL.md`; configuring channels — `@warlock.js/notifications/configure-notifications/SKILL.md`.
|
|
16
16
|
- [use-in-app](@warlock.js/notifications/use-in-app/SKILL.md): Use the `inApp` facade for the in-app/database channel's READ side: `inApp.configure({ model: Notification })` or `{ repository: myRepo }` binds the store AND returns the channel; `inApp.list / listUnread / countUnread / markAsRead / markAsUnread` are RECIPIENT-SCOPED by construction (no IDOR — `markAsRead(user, id)` cannot flip another user's row even with a foreign id). `countUnread` uses `RepositoryManager.countCached` for the badge fast-path. Triggers: `inApp.configure`, `inApp.list`, `inApp.listUnread`, `inApp.countUnread`, `inApp.markAsRead`, `inApp.markAsUnread`, `BaseNotificationsRepository`, `DatabaseNotification`, `NotificationsFilter`, "in-app notifications", "mark notification as read", "unread count", "notification badge", "IDOR-safe markAsRead"; typical import `import { inApp } from "@warlock.js/notifications"`. Skip: writing notifications (use `defineNotification` or `notify.database`) — `@warlock.js/notifications/define-notification/SKILL.md`; the migration columns — `@warlock.js/notifications/write-notification-migration/SKILL.md`; wiring it into config — `@warlock.js/notifications/configure-notifications/SKILL.md`.
|
|
17
17
|
- [write-notification-migration](@warlock.js/notifications/write-notification-migration/SKILL.md): Create the notifications table with the `notificationColumns(Notification)` factory + cascade `Migration.create`. Column NAMES come from the model's `columnMap` (recipient / tenant / readAt / isRead); the fixed columns are `type` / `title` / `body` / `payload` / `idempotency_key`. Read-state follows columnMap presence: `readAt` → nullable timestamp, `isRead` → indexed boolean, both → both. Defaults to `user_id` + `read_at` when no columnMap. Spread + extend for extras (FK references, composite indexes). Triggers: `notificationColumns`, `Migration.create` for notifications, "create the notifications table", "notification migration", "add organization_id to notifications", `is_read` column, `read_at` column, `idempotency_key` column; typical import `import { Migration } from "@warlock.js/cascade"; import { notificationColumns } from "@warlock.js/notifications"`. Skip: generic cascade migration writing — `@warlock.js/cascade/write-migration/SKILL.md`; the model itself — `@warlock.js/notifications/use-in-app/SKILL.md`.
|
package/package.json
CHANGED
|
@@ -5,13 +5,21 @@
|
|
|
5
5
|
"environment": "server"
|
|
6
6
|
},
|
|
7
7
|
"dependencies": {
|
|
8
|
-
"@warlock.js/cache": "5.
|
|
9
|
-
"@warlock.js/cascade": "5.
|
|
10
|
-
"@warlock.js/core": "5.
|
|
11
|
-
"@warlock.js/logger": "5.
|
|
8
|
+
"@warlock.js/cache": "5.15.0",
|
|
9
|
+
"@warlock.js/cascade": "5.15.0",
|
|
10
|
+
"@warlock.js/core": "5.15.0",
|
|
11
|
+
"@warlock.js/logger": "5.15.0"
|
|
12
12
|
},
|
|
13
13
|
"optionalDependencies": {
|
|
14
|
-
"@warlock.js/herald": "5.
|
|
14
|
+
"@warlock.js/herald": "5.15.0"
|
|
15
|
+
},
|
|
16
|
+
"peerDependencies": {
|
|
17
|
+
"@warlock.js/queue": "5.15.0"
|
|
18
|
+
},
|
|
19
|
+
"peerDependenciesMeta": {
|
|
20
|
+
"@warlock.js/queue": {
|
|
21
|
+
"optional": true
|
|
22
|
+
}
|
|
15
23
|
},
|
|
16
24
|
"repository": {
|
|
17
25
|
"type": "git",
|
|
@@ -27,7 +35,7 @@
|
|
|
27
35
|
],
|
|
28
36
|
"author": "hassanzohdy",
|
|
29
37
|
"license": "MIT",
|
|
30
|
-
"version": "5.
|
|
38
|
+
"version": "5.15.0",
|
|
31
39
|
"main": "./cjs/index.cjs",
|
|
32
40
|
"module": "./esm/index.mjs",
|
|
33
41
|
"types": "./esm/index.d.mts",
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: queue-notifications
|
|
3
|
-
description: "Send notifications asynchronously through the herald backend or the BullMQ
|
|
3
|
+
description: "Send notifications asynchronously through the herald backend or the BullMQ driver. Configure a QueueDispatcher in config/notifications.ts, then use notif.queue(to, data, options?) to enqueue rendered jobs. Herald uses heraldQueue() and startNotificationsWorker(); bullmqQueue({ attempts, backoff }) from @warlock.js/notifications uses BullMQ (lazy-loading the optional @warlock.js/queue peer), supports retries, and honours SendOptions.delay. Without a queue configured, .queue() rejects NoQueueDispatcherError. Triggers: heraldQueue, bullmqQueue, startNotificationsWorker, QueueDispatcher, .queue(, async notifications, queue notifications, notification worker, background notifications, notifications.dispatch. Skip: synchronous sends - @warlock.js/notifications/define-notification/SKILL.md; herald itself - @warlock.js/herald/*."
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# Queue notifications (async)
|
|
@@ -33,24 +33,32 @@ if that package is missing, the first `.queue()` throws an install message.
|
|
|
33
33
|
|
|
34
34
|
## Use BullMQ for delayed or retried delivery
|
|
35
35
|
|
|
36
|
-
|
|
37
|
-
|
|
36
|
+
Use the `bullmq` driver instead of the herald dispatcher — it ships inside
|
|
37
|
+
`@warlock.js/notifications` itself and lazy-loads `@warlock.js/queue` (an
|
|
38
|
+
OPTIONAL peer) the first time `.queue()` runs:
|
|
38
39
|
|
|
39
40
|
```ts title="src/config/notifications.ts"
|
|
40
|
-
import { type NotificationConfig, mailChannel } from "@warlock.js/notifications";
|
|
41
|
-
import { queueNotificationDispatcher } from "@warlock.js/queue/notifications";
|
|
41
|
+
import { type NotificationConfig, bullmqQueue, mailChannel } from "@warlock.js/notifications";
|
|
42
42
|
|
|
43
43
|
const config: NotificationConfig = {
|
|
44
44
|
channels: { mail: mailChannel() },
|
|
45
|
-
queue:
|
|
45
|
+
queue: bullmqQueue({ attempts: 3, backoff: { type: "exponential", delay: 5000 } }),
|
|
46
46
|
};
|
|
47
47
|
|
|
48
48
|
export default config;
|
|
49
49
|
```
|
|
50
50
|
|
|
51
|
-
The BullMQ
|
|
51
|
+
The BullMQ driver honours `SendOptions.delay`: numeric delays are seconds and
|
|
52
52
|
string delays use the normal duration syntax, such as `"10m"`. It also supports
|
|
53
|
-
BullMQ retries through `attempts` and `backoff`.
|
|
53
|
+
BullMQ retries through `attempts` and `backoff`. If `@warlock.js/queue` isn't
|
|
54
|
+
installed, the first `.queue()` throws `QueuePackageNotInstalledError` naming
|
|
55
|
+
`warlock add queue`.
|
|
56
|
+
|
|
57
|
+
> **Removed (5.15.0):** `queueNotificationDispatcher` from
|
|
58
|
+
> `@warlock.js/queue/notifications` — deprecated in 5.14, removed this
|
|
59
|
+
> release, along with the `@warlock.js/notifications` peer dependency it was
|
|
60
|
+
> the only reason `@warlock.js/queue` carried. Use `bullmqQueue` above — same
|
|
61
|
+
> option names (`queue`, `attempts`, `backoff`).
|
|
54
62
|
|
|
55
63
|
## Run the herald worker
|
|
56
64
|
|