@forklaunch/validator 0.2.5 → 0.2.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (43) hide show
  1. package/package.json +7 -3
  2. package/dist/index.d.ts +0 -88
  3. package/dist/index.js +0 -24
  4. package/dist/index.js.map +0 -1
  5. package/dist/interfaces/index.d.ts +0 -1
  6. package/dist/interfaces/index.js +0 -18
  7. package/dist/interfaces/index.js.map +0 -1
  8. package/dist/interfaces/schemaValidator.interfaces.d.ts +0 -108
  9. package/dist/interfaces/schemaValidator.interfaces.js +0 -3
  10. package/dist/interfaces/schemaValidator.interfaces.js.map +0 -1
  11. package/dist/jest.config.d.ts +0 -3
  12. package/dist/jest.config.js +0 -10
  13. package/dist/jest.config.js.map +0 -1
  14. package/dist/tests/mockSchemaValidator.d.ts +0 -21
  15. package/dist/tests/mockSchemaValidator.js +0 -42
  16. package/dist/tests/mockSchemaValidator.js.map +0 -1
  17. package/dist/tests/typebox/equality.test.d.ts +0 -1
  18. package/dist/tests/typebox/equality.test.js +0 -210
  19. package/dist/tests/typebox/equality.test.js.map +0 -1
  20. package/dist/tests/typebox/largeSchema.test.d.ts +0 -1
  21. package/dist/tests/typebox/largeSchema.test.js +0 -141
  22. package/dist/tests/typebox/largeSchema.test.js.map +0 -1
  23. package/dist/tests/zod/equality.test.d.ts +0 -1
  24. package/dist/tests/zod/equality.test.js +0 -214
  25. package/dist/tests/zod/equality.test.js.map +0 -1
  26. package/dist/tests/zod/largeSchema.test.d.ts +0 -1
  27. package/dist/tests/zod/largeSchema.test.js +0 -141
  28. package/dist/tests/zod/largeSchema.test.js.map +0 -1
  29. package/dist/typebox/index.d.ts +0 -148
  30. package/dist/typebox/index.js +0 -198
  31. package/dist/typebox/index.js.map +0 -1
  32. package/dist/typebox/types/typebox.schema.types.d.ts +0 -63
  33. package/dist/typebox/types/typebox.schema.types.js +0 -3
  34. package/dist/typebox/types/typebox.schema.types.js.map +0 -1
  35. package/dist/types/schema.types.d.ts +0 -28
  36. package/dist/types/schema.types.js +0 -3
  37. package/dist/types/schema.types.js.map +0 -1
  38. package/dist/zod/index.d.ts +0 -145
  39. package/dist/zod/index.js +0 -191
  40. package/dist/zod/index.js.map +0 -1
  41. package/dist/zod/types/zod.schema.types.d.ts +0 -65
  42. package/dist/zod/types/zod.schema.types.js +0 -3
  43. package/dist/zod/types/zod.schema.types.js.map +0 -1
@@ -1,65 +0,0 @@
1
- import { ZodObject as OriginalZodObject, ZodArray, ZodLiteral, ZodNever, ZodRawShape, ZodType, ZodTypeAny, ZodUnknown, z } from "zod";
2
- import { IdiomaticSchema, Increment, LiteralSchema, UnboxedObjectSchema } from "../../types/schema.types";
3
- /**
4
- * Represents a catch-all Zod schema type.
5
- */
6
- export type ZodCatchall = ZodTypeAny;
7
- /**
8
- * Represents an outer array schema type for Zod. If the type T is a Zod object, it will return an array schema of T. Otherwise, it returns ZodNever.
9
- *
10
- * @template T - The type to check and possibly convert to an array schema.
11
- */
12
- export type ZodOuterArray<T> = T extends ZodObject<ZodObjectShape> ? ZodArray<T> : ZodNever;
13
- /**
14
- * Represents the shape of a Zod object schema.
15
- */
16
- export type ZodObjectShape = ZodRawShape;
17
- /**
18
- * Represents a Zod object schema type. If the type T is a Zod object shape, it will return the original ZodObject type of T. Otherwise, it returns ZodNever.
19
- *
20
- * @template T - The type to check and possibly convert to a Zod object schema.
21
- */
22
- export type ZodObject<T> = T extends ZodObjectShape ? OriginalZodObject<T> : ZodNever;
23
- /**
24
- * Translates a Zod schema type T to its static type if T extends ZodCatchall. Otherwise, it returns ZodNever.
25
- *
26
- * @template T - The Zod schema type to translate.
27
- */
28
- export type ZodSchemaTranslate<T> = T extends ZodCatchall ? z.infer<T> : ZodNever;
29
- /**
30
- * Represents an unboxed Zod object schema where each key can have an idiomatic schema.
31
- */
32
- export type ZodObjectSchema = UnboxedObjectSchema<ZodCatchall>;
33
- /**
34
- * Represents an idiomatic schema for Zod which can be an unboxed object schema or a literal schema.
35
- */
36
- export type ZodIdiomaticSchema = IdiomaticSchema<ZodCatchall>;
37
- /**
38
- * Represents a container for a union of Zod idiomatic schemas.
39
- */
40
- export type ZodUnionContainer = readonly [ZodIdiomaticSchema, ZodIdiomaticSchema, ...ZodIdiomaticSchema[]];
41
- /**
42
- * Resolves a union container to a tuple of resolved Zod idiomatic schemas.
43
- *
44
- * @template T - The union container to resolve.
45
- */
46
- export type UnionZodResolve<T extends ZodUnionContainer> = T extends [
47
- infer A extends ZodIdiomaticSchema,
48
- infer B extends ZodIdiomaticSchema,
49
- ...infer C extends ZodIdiomaticSchema[]
50
- ] ? [
51
- ZodResolve<A>,
52
- ZodResolve<B>,
53
- ...{
54
- [K in keyof C]: ZodResolve<C[K]>;
55
- }
56
- ] : [ZodNever, ZodNever];
57
- /**
58
- * Resolves a Zod schema type T to its resolved type. The depth is limited to 31 to prevent infinite recursion.
59
- *
60
- * @template T - The Zod schema type to resolve.
61
- * @template Depth - The current depth of the resolution.
62
- */
63
- export type ZodResolve<T, Depth extends number = 0> = Depth extends 31 ? ZodUnknown : T extends LiteralSchema ? ZodLiteral<T> : T extends ZodType ? T : T extends ZodObjectSchema ? ZodObject<{
64
- [K in keyof T]: ZodResolve<T[K], Increment<Depth>>;
65
- }> : ZodNever;
@@ -1,3 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- //# sourceMappingURL=zod.schema.types.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"zod.schema.types.js","sourceRoot":"","sources":["../../../zod/types/zod.schema.types.ts"],"names":[],"mappings":""}