@nhtio/encoder 0.1.0-master-3b237666 → 0.1.0-master-f44af99f

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.
@@ -123857,7 +123857,13 @@ const stringSchema = validator.string().allow("").required();
123857
123857
  const numberSchema = validator.alternatives(
123858
123858
  validator.number(),
123859
123859
  validator.object().instance(Number),
123860
- validator.function().instance(Number)
123860
+ validator.function().instance(Number),
123861
+ validator.valid(
123862
+ Number.MAX_SAFE_INTEGER,
123863
+ Number.MIN_SAFE_INTEGER,
123864
+ Number.MAX_VALUE,
123865
+ Number.MIN_VALUE
123866
+ )
123861
123867
  ).required();
123862
123868
  const booleanSchema = validator.boolean().required();
123863
123869
  const bigintSchema = validator.any().custom((value, helpers) => {
@@ -123995,7 +124001,7 @@ const phoneObjectSchema = validator.alternatives(
123995
124001
  return value;
123996
124002
  }
123997
124003
  return helpers.error("any.invalid");
123998
- }),
124004
+ }).required(),
123999
124005
  validator.object({
124000
124006
  country: validator.string().required().valid(...[...Array.from(isos), "XX"]),
124001
124007
  international: validator.string().allow("").required(),
@@ -124006,8 +124012,8 @@ const phoneObjectSchema = validator.alternatives(
124006
124012
  timezone: validator.string().required(),
124007
124013
  type: validator.string().valid(...Array.from(PhoneTypes)).required(),
124008
124014
  valid: validator.boolean().required()
124009
- }).unknown(true)
124010
- );
124015
+ }).unknown(true).required()
124016
+ ).required();
124011
124017
  const isObject$1 = (value) => {
124012
124018
  return typeof value === "object" && value !== null && !Array.isArray(value);
124013
124019
  };
@@ -124061,6 +124067,15 @@ const isNegativeZero = (value) => {
124061
124067
  if (!isNumber(value)) return false;
124062
124068
  return 1 / value < 0 && Math.abs(value) === 0;
124063
124069
  };
124070
+ const isPositiveInfinity = (value) => {
124071
+ return typeof value === "number" && !Number.isNaN(value) && !Number.isFinite(value) && value > 0;
124072
+ };
124073
+ const isNegativeInfinity = (value) => {
124074
+ return typeof value === "number" && !Number.isNaN(value) && !Number.isFinite(value) && value < 0;
124075
+ };
124076
+ const isUnsafeInteger = (value) => {
124077
+ return Number.isInteger(value) && !Number.isSafeInteger(value);
124078
+ };
124064
124079
  const matchesSchema = (value, schema) => {
124065
124080
  const { error } = schema.validate(value, {
124066
124081
  abortEarly: true
@@ -124110,11 +124125,14 @@ export {
124110
124125
  isUniterableObject as m,
124111
124126
  isError as n,
124112
124127
  isBigInt as o,
124113
- isNegativeZero as p,
124114
- Interval$1 as q,
124115
- Duration$1 as r,
124116
- isLucidBinaryValue as s,
124117
- isInstanceOf as t,
124118
- isNumber as u
124128
+ isUnsafeInteger as p,
124129
+ isNegativeInfinity as q,
124130
+ isPositiveInfinity as r,
124131
+ isNegativeZero as s,
124132
+ Interval$1 as t,
124133
+ Duration$1 as u,
124134
+ isLucidBinaryValue as v,
124135
+ isInstanceOf as w,
124136
+ isNumber as x
124119
124137
  };
124120
- //# sourceMappingURL=type_guards-BbzVmysZ.mjs.map
124138
+ //# sourceMappingURL=type_guards-UkDoe__i.mjs.map