@rspack/core 1.3.13 → 1.3.14

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 (142) hide show
  1. package/compiled/zod/dist/types/v3/types.d.ts +2 -2
  2. package/compiled/zod/dist/types/v4/classic/coerce.d.ts +5 -5
  3. package/compiled/zod/dist/types/v4/classic/external.d.ts +6 -1
  4. package/compiled/zod/dist/types/v4/classic/schemas.d.ts +88 -130
  5. package/compiled/zod/dist/types/v4/core/api.d.ts +2 -2
  6. package/compiled/zod/dist/types/v4/core/core.d.ts +11 -7
  7. package/compiled/zod/dist/types/v4/core/errors.d.ts +0 -1
  8. package/compiled/zod/dist/types/v4/core/function.d.ts +16 -11
  9. package/compiled/zod/dist/types/v4/core/regexes.d.ts +0 -1
  10. package/compiled/zod/dist/types/v4/core/registries.d.ts +6 -1
  11. package/compiled/zod/dist/types/v4/core/schemas.d.ts +144 -116
  12. package/compiled/zod/dist/types/v4/core/util.d.ts +5 -9
  13. package/compiled/zod/dist/types/v4/locales/ar.d.ts +0 -3
  14. package/compiled/zod/dist/types/v4/locales/az.d.ts +0 -3
  15. package/compiled/zod/dist/types/v4/locales/be.d.ts +0 -3
  16. package/compiled/zod/dist/types/v4/locales/ca.d.ts +0 -3
  17. package/compiled/zod/dist/types/v4/locales/cs.d.ts +0 -3
  18. package/compiled/zod/dist/types/v4/locales/de.d.ts +0 -3
  19. package/compiled/zod/dist/types/v4/locales/en.d.ts +0 -2
  20. package/compiled/zod/dist/types/v4/locales/es.d.ts +0 -3
  21. package/compiled/zod/dist/types/v4/locales/fa.d.ts +0 -3
  22. package/compiled/zod/dist/types/v4/locales/fi.d.ts +0 -3
  23. package/compiled/zod/dist/types/v4/locales/{frCA.d.ts → fr-CA.d.ts} +0 -3
  24. package/compiled/zod/dist/types/v4/locales/fr.d.ts +0 -3
  25. package/compiled/zod/dist/types/v4/locales/he.d.ts +0 -3
  26. package/compiled/zod/dist/types/v4/locales/hu.d.ts +0 -3
  27. package/compiled/zod/dist/types/v4/locales/id.d.ts +0 -3
  28. package/compiled/zod/dist/types/v4/locales/index.d.ts +5 -2
  29. package/compiled/zod/dist/types/v4/locales/it.d.ts +0 -3
  30. package/compiled/zod/dist/types/v4/locales/ja.d.ts +0 -3
  31. package/compiled/zod/dist/types/v4/locales/{zh-tw.d.ts → kh.d.ts} +0 -3
  32. package/compiled/zod/dist/types/v4/locales/ko.d.ts +0 -3
  33. package/compiled/zod/dist/types/v4/locales/mk.d.ts +0 -3
  34. package/compiled/zod/dist/types/v4/locales/ms.d.ts +0 -3
  35. package/compiled/zod/dist/types/v4/locales/nl.d.ts +4 -0
  36. package/compiled/zod/dist/types/v4/locales/no.d.ts +0 -3
  37. package/compiled/zod/dist/types/v4/locales/ota.d.ts +0 -3
  38. package/compiled/zod/dist/types/v4/locales/pl.d.ts +0 -3
  39. package/compiled/zod/dist/types/v4/locales/pt.d.ts +0 -3
  40. package/compiled/zod/dist/types/v4/locales/ru.d.ts +0 -3
  41. package/compiled/zod/dist/types/v4/locales/sl.d.ts +0 -3
  42. package/compiled/zod/dist/types/v4/locales/sv.d.ts +4 -0
  43. package/compiled/zod/dist/types/v4/locales/ta.d.ts +0 -3
  44. package/compiled/zod/dist/types/v4/locales/th.d.ts +0 -3
  45. package/compiled/zod/dist/types/v4/locales/tr.d.ts +0 -2
  46. package/compiled/zod/dist/types/v4/locales/ua.d.ts +0 -3
  47. package/compiled/zod/dist/types/v4/locales/ur.d.ts +0 -3
  48. package/compiled/zod/dist/types/v4/locales/vi.d.ts +0 -3
  49. package/compiled/zod/dist/types/v4/locales/zh-CN.d.ts +0 -3
  50. package/compiled/zod/dist/types/v4/locales/zh-TW.d.ts +4 -0
  51. package/compiled/zod/dist/types/v4/mini/external.d.ts +5 -1
  52. package/compiled/zod/dist/types/v4/mini/schemas.d.ts +39 -48
  53. package/compiled/zod/index.js +41 -63
  54. package/compiled/zod/package.json +1 -1
  55. package/compiled/zod/v3/index.d.ts +3 -1
  56. package/compiled/zod/v4/core/index.d.ts +1 -1
  57. package/compiled/zod/v4/index.d.ts +3 -1
  58. package/compiled/zod/v4/locales/index.d.ts +1 -1
  59. package/compiled/zod/v4-mini/index.d.ts +1 -1
  60. package/dist/ErrorHelpers.d.ts +0 -15
  61. package/dist/Module.d.ts +5 -1
  62. package/dist/ModuleTypeConstants.d.ts +0 -85
  63. package/dist/RspackError.d.ts +0 -3
  64. package/dist/builtin-loader/lightningcss/index.d.ts +23 -1
  65. package/dist/builtin-loader/swc/types.d.ts +289 -2426
  66. package/dist/builtin-plugin/APIPlugin.d.ts +1 -1
  67. package/dist/builtin-plugin/ArrayPushCallbackChunkFormatPlugin.d.ts +1 -1
  68. package/dist/builtin-plugin/AssetModulesPlugin.d.ts +1 -1
  69. package/dist/builtin-plugin/AsyncWebAssemblyModulesPlugin.d.ts +1 -1
  70. package/dist/builtin-plugin/BannerPlugin.d.ts +1 -1
  71. package/dist/builtin-plugin/BundlerInfoRspackPlugin.d.ts +1 -1
  72. package/dist/builtin-plugin/ChunkPrefetchPreloadPlugin.d.ts +1 -1
  73. package/dist/builtin-plugin/CommonJsChunkFormatPlugin.d.ts +1 -1
  74. package/dist/builtin-plugin/ContextReplacementPlugin.d.ts +1 -1
  75. package/dist/builtin-plugin/CopyRspackPlugin.d.ts +1 -1
  76. package/dist/builtin-plugin/CssChunkingPlugin.d.ts +1 -1
  77. package/dist/builtin-plugin/CssModulesPlugin.d.ts +1 -1
  78. package/dist/builtin-plugin/DataUriPlugin.d.ts +1 -1
  79. package/dist/builtin-plugin/DefinePlugin.d.ts +1 -1
  80. package/dist/builtin-plugin/DllEntryPlugin.d.ts +1 -1
  81. package/dist/builtin-plugin/DllReferenceAgencyPlugin.d.ts +1 -1
  82. package/dist/builtin-plugin/ElectronTargetPlugin.d.ts +1 -1
  83. package/dist/builtin-plugin/EnableChunkLoadingPlugin.d.ts +1 -1
  84. package/dist/builtin-plugin/EnableWasmLoadingPlugin.d.ts +1 -1
  85. package/dist/builtin-plugin/EnsureChunkConditionsPlugin.d.ts +1 -1
  86. package/dist/builtin-plugin/EntryPlugin.d.ts +1 -1
  87. package/dist/builtin-plugin/EvalDevToolModulePlugin.d.ts +1 -1
  88. package/dist/builtin-plugin/EvalSourceMapDevToolPlugin.d.ts +1 -1
  89. package/dist/builtin-plugin/FetchCompileAsyncWasmPlugin.d.ts +1 -1
  90. package/dist/builtin-plugin/FileUriPlugin.d.ts +1 -1
  91. package/dist/builtin-plugin/FlagAllModulesAsUsedPlugin.d.ts +1 -1
  92. package/dist/builtin-plugin/FlagDependencyExportsPlugin.d.ts +1 -1
  93. package/dist/builtin-plugin/HttpExternalsRspackPlugin.d.ts +1 -1
  94. package/dist/builtin-plugin/IgnorePlugin.d.ts +1 -1
  95. package/dist/builtin-plugin/InferAsyncModulesPlugin.d.ts +1 -1
  96. package/dist/builtin-plugin/JsLoaderRspackPlugin.d.ts +1 -1
  97. package/dist/builtin-plugin/JsonModulesPlugin.d.ts +1 -1
  98. package/dist/builtin-plugin/LibManifestPlugin.d.ts +1 -1
  99. package/dist/builtin-plugin/LightningCssMinimizerRspackPlugin.d.ts +1 -1
  100. package/dist/builtin-plugin/LimitChunkCountPlugin.d.ts +1 -1
  101. package/dist/builtin-plugin/MergeDuplicateChunksPlugin.d.ts +1 -1
  102. package/dist/builtin-plugin/ModuleChunkFormatPlugin.d.ts +1 -1
  103. package/dist/builtin-plugin/ModuleInfoHeaderPlugin.d.ts +1 -1
  104. package/dist/builtin-plugin/NamedChunkIdsPlugin.d.ts +1 -1
  105. package/dist/builtin-plugin/NamedModuleIdsPlugin.d.ts +1 -1
  106. package/dist/builtin-plugin/NoEmitOnErrorsPlugin.d.ts +1 -1
  107. package/dist/builtin-plugin/NodeTargetPlugin.d.ts +1 -1
  108. package/dist/builtin-plugin/OccurrenceChunkIdsPlugin.d.ts +1 -1
  109. package/dist/builtin-plugin/ProgressPlugin.d.ts +1 -1
  110. package/dist/builtin-plugin/ProvidePlugin.d.ts +1 -1
  111. package/dist/builtin-plugin/RealContentHashPlugin.d.ts +1 -1
  112. package/dist/builtin-plugin/RemoveDuplicateModulesPlugin.d.ts +1 -1
  113. package/dist/builtin-plugin/RemoveEmptyChunksPlugin.d.ts +1 -1
  114. package/dist/builtin-plugin/RsdoctorPlugin.d.ts +1 -1
  115. package/dist/builtin-plugin/RstestPlugin.d.ts +1 -1
  116. package/dist/builtin-plugin/RuntimeChunkPlugin.d.ts +1 -1
  117. package/dist/builtin-plugin/RuntimePlugin.d.ts +1 -1
  118. package/dist/builtin-plugin/SideEffectsFlagPlugin.d.ts +1 -1
  119. package/dist/builtin-plugin/SizeLimitsPlugin.d.ts +1 -1
  120. package/dist/builtin-plugin/SourceMapDevToolPlugin.d.ts +1 -1
  121. package/dist/builtin-plugin/SubresourceIntegrityPlugin.d.ts +1 -1
  122. package/dist/builtin-plugin/SwcJsMinimizerPlugin.d.ts +1 -1
  123. package/dist/builtin-plugin/WarnCaseSensitiveModulesPlugin.d.ts +1 -1
  124. package/dist/builtin-plugin/base.d.ts +1 -2
  125. package/dist/builtin-plugin/html-plugin/plugin.d.ts +1 -1
  126. package/dist/builtin-plugin/lazy-compilation/lazyCompilation.d.ts +1 -1
  127. package/dist/config/zod.d.ts +370 -370
  128. package/dist/container/ModuleFederationRuntimePlugin.d.ts +1 -1
  129. package/dist/index.js +51 -27
  130. package/dist/lib/AbstractMethodError.d.ts +0 -1
  131. package/dist/lib/CacheFacade.d.ts +0 -28
  132. package/dist/loader-runner/index.d.ts +1 -0
  133. package/dist/stats/statsFactoryUtils.d.ts +0 -4
  134. package/dist/util/cleverMerge.d.ts +0 -30
  135. package/dist/util/comparators.d.ts +0 -4
  136. package/dist/util/hash/wasm-hash.d.ts +0 -1
  137. package/dist/util/identifier.d.ts +0 -12
  138. package/dist/util/index.d.ts +1 -7
  139. package/dist/util/memoize.d.ts +0 -1
  140. package/dist/worker.js +5 -7
  141. package/package.json +4 -4
  142. package/dist/util/hash/BatchedHash.d.ts +0 -25
@@ -26,18 +26,13 @@ export interface $ZodTypeDef {
26
26
  error?: errors.$ZodErrorMap<never> | undefined;
27
27
  checks?: checks.$ZodCheck<never>[];
28
28
  }
29
- /** @internal */
30
- export interface $ZodTypeInternals<out O = unknown, out I = unknown> {
29
+ export interface _$ZodTypeInternals {
31
30
  /** The `@zod/core` version of this schema */
32
31
  version: typeof version;
33
32
  /** Schema definition. */
34
33
  def: $ZodTypeDef;
35
34
  /** @internal Randomly generated ID for this schema. */
36
35
  id: string;
37
- /** @internal The inferred output type */
38
- output: O;
39
- /** @internal The inferred input type */
40
- input: I;
41
36
  /** @internal List of deferred initializers. */
42
37
  deferred: util.AnyFunc[] | undefined;
43
38
  /** @internal Parses input and runs all checks (refinements). */
@@ -49,17 +44,19 @@ export interface $ZodTypeInternals<out O = unknown, out I = unknown> {
49
44
  /** @internal Indicates that a schema output type should be considered optional inside objects.
50
45
  * @default Required
51
46
  */
47
+ /** @internal */
52
48
  optin?: "optional" | undefined;
49
+ /** @internal */
53
50
  optout?: "optional" | undefined;
54
- /** @internal A set of literal discriminators used for the fast path in discriminated unions. */
55
- disc: util.DiscriminatorMap | undefined;
56
51
  /** @internal The set of literal values that will pass validation. Must be an exhaustive set. Used to determine optionality in z.record().
57
52
  *
58
53
  * Defined on: enum, const, literal, null, undefined
59
54
  * Passthrough: optional, nullable, branded, default, catch, pipe
60
55
  * Todo: unions?
61
56
  */
62
- values: util.PrimitiveSet | undefined;
57
+ values?: util.PrimitiveSet | undefined;
58
+ /** @internal A set of literal discriminators used for the fast path in discriminated unions. */
59
+ propValues?: util.PropValues | undefined;
63
60
  /** @internal This flag indicates that a schema validation can be represented with a regular expression. Used to determine allowable schemas in z.templateLiteral(). */
64
61
  pattern: RegExp | undefined;
65
62
  /** @internal The constructor function of this schema. */
@@ -73,9 +70,20 @@ export interface $ZodTypeInternals<out O = unknown, out I = unknown> {
73
70
  /** @internal The parent of this schema. Only set during certain clone operations. */
74
71
  parent?: $ZodType | undefined;
75
72
  }
76
- export interface $ZodType<O = unknown, I = unknown> {
77
- _zod: $ZodTypeInternals<O, I>;
78
- "~standard": StandardSchemaV1.Props<core.input<this>, core.output<this>>;
73
+ /** @internal */
74
+ export interface $ZodTypeInternals<out O = unknown, out I = unknown> extends _$ZodTypeInternals {
75
+ /** @internal The inferred output type */
76
+ output: O;
77
+ /** @internal The inferred input type */
78
+ input: I;
79
+ }
80
+ export type $ZodStandardSchema<T> = StandardSchemaV1.Props<core.input<T>, core.output<T>>;
81
+ export interface _$ZodType<T extends _$ZodTypeInternals = _$ZodTypeInternals> {
82
+ _zod: T;
83
+ }
84
+ export type SomeType = _$ZodType;
85
+ export interface $ZodType<O = unknown, I = unknown, Internals extends $ZodTypeInternals<O, I> = $ZodTypeInternals<O, I>> extends _$ZodType<Internals> {
86
+ "~standard": $ZodStandardSchema<this>;
79
87
  }
80
88
  export declare const $ZodType: core.$constructor<$ZodType>;
81
89
  export { clone } from "./util.js";
@@ -93,8 +101,9 @@ export interface $ZodStringInternals<Input> extends $ZodTypeInternals<string, In
93
101
  bag: util.LoosePartial<{
94
102
  minimum: number;
95
103
  maximum: number;
96
- pattern: RegExp;
104
+ patterns: Set<RegExp>;
97
105
  format: string;
106
+ contentEncoding: string;
98
107
  }>;
99
108
  }
100
109
  export interface $ZodString<Input = unknown> extends $ZodType {
@@ -492,15 +501,15 @@ export interface $ZodDate<T = unknown> extends $ZodType {
492
501
  _zod: $ZodDateInternals<T>;
493
502
  }
494
503
  export declare const $ZodDate: core.$constructor<$ZodDate>;
495
- export interface $ZodArrayDef<T extends $ZodType = $ZodType> extends $ZodTypeDef {
504
+ export interface $ZodArrayDef<T extends SomeType = $ZodType> extends $ZodTypeDef {
496
505
  type: "array";
497
506
  element: T;
498
507
  }
499
- export interface $ZodArrayInternals<T extends $ZodType = $ZodType> extends $ZodTypeInternals<core.output<T>[], core.input<T>[]> {
508
+ export interface $ZodArrayInternals<T extends SomeType = $ZodType> extends $ZodTypeInternals<core.output<T>[], core.input<T>[]> {
500
509
  def: $ZodArrayDef<T>;
501
510
  isst: errors.$ZodIssueInvalidType;
502
511
  }
503
- export interface $ZodArray<T extends $ZodType = $ZodType> extends $ZodType {
512
+ export interface $ZodArray<T extends SomeType = $ZodType> extends $ZodType {
504
513
  _zod: $ZodArrayInternals<T>;
505
514
  }
506
515
  export declare const $ZodArray: core.$constructor<$ZodArray>;
@@ -514,13 +523,13 @@ export interface $ZodObjectDef<Shape extends $ZodShape = $ZodShape> extends $Zod
514
523
  }
515
524
  export interface $ZodObjectInternals<
516
525
  /** @ts-ignore Cast variance */
517
- out Shape extends Readonly<$ZodShape> = Readonly<$ZodShape>, out Config extends $ZodObjectConfig = $ZodObjectConfig> extends $ZodTypeInternals<any, any> {
526
+ out Shape extends Readonly<$ZodShape> = Readonly<$ZodShape>, out Config extends $ZodObjectConfig = $ZodObjectConfig> extends _$ZodTypeInternals {
518
527
  def: $ZodObjectDef<Shape>;
519
528
  config: Config;
520
529
  isst: errors.$ZodIssueInvalidType | errors.$ZodIssueUnrecognizedKeys;
521
- disc: util.DiscriminatorMap;
522
- "~output": $InferObjectOutput<Shape, Config["out"]>;
523
- "~input": $InferObjectInput<Shape, Config["in"]>;
530
+ propValues: util.PropValues;
531
+ output: $InferObjectOutput<Shape, Config["out"]>;
532
+ input: $InferObjectInput<Shape, Config["in"]>;
524
533
  }
525
534
  export type $ZodLooseShape = Record<string, any>;
526
535
  type OptionalOutSchema = {
@@ -533,6 +542,12 @@ type OptionalInSchema = {
533
542
  optin: "optional";
534
543
  };
535
544
  };
545
+ export type $InferObjectOutputFallback<T extends $ZodLooseShape, Extra extends Record<string, unknown>> = string extends keyof T ? object : keyof (T & Extra) extends never ? Record<string, never> : util.Prettify<{
546
+ -readonly [k in keyof T]: core.output<T[k]>;
547
+ } & Extra>;
548
+ export type $InferObjectInputFallback<T extends $ZodLooseShape, Extra extends Record<string, unknown>> = string extends keyof T ? object : keyof (T & Extra) extends never ? Record<string, never> : util.Prettify<{
549
+ -readonly [k in keyof T]: core.input<T[k]>;
550
+ } & Extra>;
536
551
  export type $InferObjectOutput<T extends $ZodLooseShape, Extra extends Record<string, unknown>> = string extends keyof T ? object : keyof (T & Extra) extends never ? Record<string, never> : util.Prettify<{
537
552
  -readonly [k in keyof T as T[k] extends OptionalOutSchema ? never : k]: core.output<T[k]>;
538
553
  } & {
@@ -559,7 +574,7 @@ export type $strip = {
559
574
  out: {};
560
575
  in: {};
561
576
  };
562
- export type $catchall<T extends $ZodType> = {
577
+ export type $catchall<T extends _$ZodType> = {
563
578
  out: {
564
579
  [k: string]: core.output<T>;
565
580
  };
@@ -569,123 +584,123 @@ export type $catchall<T extends $ZodType> = {
569
584
  };
570
585
  export interface $ZodObject<
571
586
  /** @ts-ignore Cast variance */
572
- out Shape extends Readonly<$ZodShape> = Readonly<$ZodShape>, out Params extends $ZodObjectConfig = $ZodObjectConfig> extends $ZodType {
573
- _zod: $ZodObjectInternals<Shape, Params>;
587
+ out Shape extends Readonly<$ZodShape> = Readonly<$ZodShape>, out Params extends $ZodObjectConfig = $ZodObjectConfig> extends $ZodType<any, any, $ZodObjectInternals<Shape, Params>> {
588
+ "~standard": $ZodStandardSchema<this>;
574
589
  }
575
590
  export declare const $ZodObject: core.$constructor<$ZodObject>;
576
- export type $InferUnionOutput<T extends $ZodType> = T extends any ? core.output<T> : never;
577
- export type $InferUnionInput<T extends $ZodType> = T extends any ? core.input<T> : never;
578
- export interface $ZodUnionDef<Options extends readonly $ZodType[] = readonly $ZodType[]> extends $ZodTypeDef {
591
+ export type $InferUnionOutput<T extends SomeType> = T extends any ? core.output<T> : never;
592
+ export type $InferUnionInput<T extends SomeType> = T extends any ? core.input<T> : never;
593
+ export interface $ZodUnionDef<Options extends readonly SomeType[] = readonly $ZodType[]> extends $ZodTypeDef {
579
594
  type: "union";
580
595
  options: Options;
581
596
  }
582
- export interface $ZodUnionInternals<T extends readonly $ZodType[] = readonly $ZodType[]> extends $ZodTypeInternals<$InferUnionOutput<T[number]>, $InferUnionInput<T[number]>> {
597
+ export interface $ZodUnionInternals<T extends readonly SomeType[] = readonly $ZodType[]> extends $ZodTypeInternals<$InferUnionOutput<T[number]>, $InferUnionInput<T[number]>> {
583
598
  def: $ZodUnionDef<T>;
584
599
  isst: errors.$ZodIssueInvalidUnion;
585
600
  pattern: T[number]["_zod"]["pattern"];
586
601
  }
587
- export interface $ZodUnion<T extends readonly $ZodType[] = readonly $ZodType[]> extends $ZodType {
602
+ export interface $ZodUnion<T extends readonly SomeType[] = readonly $ZodType[]> extends $ZodType {
588
603
  _zod: $ZodUnionInternals<T>;
589
604
  }
590
605
  export declare const $ZodUnion: core.$constructor<$ZodUnion>;
591
- export interface $ZodDiscriminatedUnionDef<Options extends readonly $ZodType[] = readonly $ZodType[]> extends $ZodUnionDef<Options> {
606
+ export interface $ZodDiscriminatedUnionDef<Options extends readonly SomeType[] = readonly $ZodType[]> extends $ZodUnionDef<Options> {
592
607
  discriminator: string;
593
608
  unionFallback?: boolean;
594
609
  }
595
- export interface $ZodDiscriminatedUnionInternals<Options extends readonly $ZodType[] = readonly $ZodType[]> extends $ZodUnionInternals<Options> {
610
+ export interface $ZodDiscriminatedUnionInternals<Options extends readonly SomeType[] = readonly $ZodType[]> extends $ZodUnionInternals<Options> {
596
611
  def: $ZodDiscriminatedUnionDef<Options>;
597
- disc: util.DiscriminatorMap;
612
+ propValues: util.PropValues;
598
613
  }
599
- export interface $ZodDiscriminatedUnion<T extends readonly $ZodType[] = readonly $ZodType[]> extends $ZodType {
614
+ export interface $ZodDiscriminatedUnion<T extends readonly SomeType[] = readonly $ZodType[]> extends $ZodType {
600
615
  _zod: $ZodDiscriminatedUnionInternals<T>;
601
616
  }
602
617
  export declare const $ZodDiscriminatedUnion: core.$constructor<$ZodDiscriminatedUnion>;
603
- export interface $ZodIntersectionDef extends $ZodTypeDef {
618
+ export interface $ZodIntersectionDef<Left extends SomeType = $ZodType, Right extends SomeType = $ZodType> extends $ZodTypeDef {
604
619
  type: "intersection";
605
- left: $ZodType;
606
- right: $ZodType;
620
+ left: Left;
621
+ right: Right;
607
622
  }
608
- export interface $ZodIntersectionInternals<A extends $ZodType = $ZodType, B extends $ZodType = $ZodType> extends $ZodTypeInternals<core.output<A> & core.output<B>, core.input<A> & core.input<B>> {
609
- def: $ZodIntersectionDef;
623
+ export interface $ZodIntersectionInternals<A extends SomeType = $ZodType, B extends SomeType = $ZodType> extends $ZodTypeInternals<core.output<A> & core.output<B>, core.input<A> & core.input<B>> {
624
+ def: $ZodIntersectionDef<A, B>;
610
625
  isst: never;
611
626
  }
612
- export interface $ZodIntersection<A extends $ZodType = $ZodType, B extends $ZodType = $ZodType> extends $ZodType {
627
+ export interface $ZodIntersection<A extends SomeType = $ZodType, B extends SomeType = $ZodType> extends $ZodType {
613
628
  _zod: $ZodIntersectionInternals<A, B>;
614
629
  }
615
630
  export declare const $ZodIntersection: core.$constructor<$ZodIntersection>;
616
- export interface $ZodTupleDef<T extends util.TupleItems = util.TupleItems, Rest extends $ZodType | null = $ZodType | null> extends $ZodTypeDef {
631
+ export interface $ZodTupleDef<T extends util.TupleItems = readonly $ZodType[], Rest extends SomeType | null = $ZodType | null> extends $ZodTypeDef {
617
632
  type: "tuple";
618
633
  items: T;
619
634
  rest: Rest;
620
635
  }
621
- export type $InferTupleInputType<T extends util.TupleItems, Rest extends $ZodType | null> = [
636
+ export type $InferTupleInputType<T extends util.TupleItems, Rest extends SomeType | null> = [
622
637
  ...TupleInputTypeWithOptionals<T>,
623
- ...(Rest extends $ZodType ? core.input<Rest>[] : [])
638
+ ...(Rest extends SomeType ? core.input<Rest>[] : [])
624
639
  ];
625
640
  type TupleInputTypeNoOptionals<T extends util.TupleItems> = {
626
641
  [k in keyof T]: core.input<T[k]>;
627
642
  };
628
643
  type TupleInputTypeWithOptionals<T extends util.TupleItems> = T extends readonly [
629
- ...infer Prefix extends $ZodType[],
630
- infer Tail extends $ZodType
631
- ] ? Tail["_zod"]["optin"] extends "optional" ? [...TupleInputTypeWithOptionals<Prefix>, Tail["_zod"]["input"]?] : TupleInputTypeNoOptionals<T> : [];
632
- export type $InferTupleOutputType<T extends util.TupleItems, Rest extends $ZodType | null> = [
644
+ ...infer Prefix extends SomeType[],
645
+ infer Tail extends SomeType
646
+ ] ? Tail["_zod"]["optin"] extends "optional" ? [...TupleInputTypeWithOptionals<Prefix>, core.input<Tail>?] : TupleInputTypeNoOptionals<T> : [];
647
+ export type $InferTupleOutputType<T extends util.TupleItems, Rest extends SomeType | null> = [
633
648
  ...TupleOutputTypeWithOptionals<T>,
634
- ...(Rest extends $ZodType ? core.output<Rest>[] : [])
649
+ ...(Rest extends SomeType ? core.output<Rest>[] : [])
635
650
  ];
636
651
  type TupleOutputTypeNoOptionals<T extends util.TupleItems> = {
637
652
  [k in keyof T]: core.output<T[k]>;
638
653
  };
639
654
  type TupleOutputTypeWithOptionals<T extends util.TupleItems> = T extends readonly [
640
- ...infer Prefix extends $ZodType[],
641
- infer Tail extends $ZodType
655
+ ...infer Prefix extends SomeType[],
656
+ infer Tail extends SomeType
642
657
  ] ? Tail["_zod"]["optout"] extends "optional" ? [...TupleOutputTypeWithOptionals<Prefix>, core.output<Tail>?] : TupleOutputTypeNoOptionals<T> : [];
643
- export interface $ZodTupleInternals<T extends util.TupleItems = util.TupleItems, Rest extends $ZodType | null = $ZodType | null> extends $ZodTypeInternals<$InferTupleOutputType<T, Rest>, $InferTupleInputType<T, Rest>> {
658
+ export interface $ZodTupleInternals<T extends util.TupleItems = readonly $ZodType[], Rest extends SomeType | null = $ZodType | null> extends $ZodTypeInternals<$InferTupleOutputType<T, Rest>, $InferTupleInputType<T, Rest>> {
644
659
  def: $ZodTupleDef<T, Rest>;
645
660
  isst: errors.$ZodIssueInvalidType | errors.$ZodIssueTooBig<unknown[]> | errors.$ZodIssueTooSmall<unknown[]>;
646
661
  }
647
- export interface $ZodTuple<T extends util.TupleItems = util.TupleItems, Rest extends $ZodType | null = $ZodType | null> extends $ZodType {
662
+ export interface $ZodTuple<T extends util.TupleItems = readonly $ZodType[], Rest extends SomeType | null = $ZodType | null> extends $ZodType {
648
663
  _zod: $ZodTupleInternals<T, Rest>;
649
664
  }
650
665
  export declare const $ZodTuple: core.$constructor<$ZodTuple>;
651
666
  export type $ZodRecordKey = $ZodType<string | number | symbol, string | number | symbol>;
652
- export interface $ZodRecordDef extends $ZodTypeDef {
667
+ export interface $ZodRecordDef<Key extends $ZodRecordKey = $ZodRecordKey, Value extends SomeType = $ZodType> extends $ZodTypeDef {
653
668
  type: "record";
654
- keyType: $ZodRecordKey;
655
- valueType: $ZodType;
669
+ keyType: Key;
670
+ valueType: Value;
656
671
  }
657
- type $InferZodRecordOutput<Key extends $ZodRecordKey = $ZodRecordKey, Value extends $ZodType = $ZodType> = undefined extends Key["_zod"]["values"] ? string extends Key["_zod"]["output"] ? Record<Key["_zod"]["output"], core.output<Value>> : number extends Key["_zod"]["output"] ? Record<Key["_zod"]["output"], core.output<Value>> : symbol extends Key["_zod"]["output"] ? Record<Key["_zod"]["output"], core.output<Value>> : Partial<Record<Key["_zod"]["output"], core.output<Value>>> : Record<Key["_zod"]["output"], core.output<Value>>;
658
- type $InferZodRecordInput<Key extends $ZodRecordKey = $ZodRecordKey, Value extends $ZodType = $ZodType> = undefined extends Key["_zod"]["values"] ? string extends Key["_zod"]["input"] ? Record<Key["_zod"]["input"], Value["_zod"]["input"]> : number extends Key["_zod"]["input"] ? Record<Key["_zod"]["input"], Value["_zod"]["input"]> : symbol extends Key["_zod"]["input"] ? Record<Key["_zod"]["input"], Value["_zod"]["input"]> : Partial<Record<Key["_zod"]["input"], Value["_zod"]["input"]>> : Record<Key["_zod"]["input"], Value["_zod"]["input"]>;
659
- export interface $ZodRecordInternals<Key extends $ZodRecordKey = $ZodRecordKey, Value extends $ZodType = $ZodType> extends $ZodTypeInternals<$InferZodRecordOutput<Key, Value>, $InferZodRecordInput<Key, Value>> {
660
- def: $ZodRecordDef;
672
+ export type $InferZodRecordOutput<Key extends $ZodRecordKey = $ZodRecordKey, Value extends SomeType = $ZodType> = undefined extends Key["_zod"]["values"] ? string extends core.output<Key> ? Record<core.output<Key>, core.output<Value>> : number extends core.output<Key> ? Record<core.output<Key>, core.output<Value>> : symbol extends core.output<Key> ? Record<core.output<Key>, core.output<Value>> : Partial<Record<core.output<Key>, core.output<Value>>> : Record<core.output<Key>, core.output<Value>>;
673
+ export type $InferZodRecordInput<Key extends $ZodRecordKey = $ZodRecordKey, Value extends SomeType = $ZodType> = undefined extends Key["_zod"]["values"] ? string extends core.input<Key> ? Record<core.input<Key>, core.input<Value>> : number extends core.input<Key> ? Record<core.input<Key>, core.input<Value>> : symbol extends core.input<Key> ? Record<core.input<Key>, core.input<Value>> : Partial<Record<core.input<Key>, core.input<Value>>> : Record<core.input<Key>, core.input<Value>>;
674
+ export interface $ZodRecordInternals<Key extends $ZodRecordKey = $ZodRecordKey, Value extends SomeType = $ZodType> extends $ZodTypeInternals<$InferZodRecordOutput<Key, Value>, $InferZodRecordInput<Key, Value>> {
675
+ def: $ZodRecordDef<Key, Value>;
661
676
  isst: errors.$ZodIssueInvalidType | errors.$ZodIssueInvalidKey<Record<PropertyKey, unknown>>;
662
677
  }
663
- export interface $ZodRecord<Key extends $ZodRecordKey = $ZodRecordKey, Value extends $ZodType = $ZodType> extends $ZodType {
678
+ export interface $ZodRecord<Key extends $ZodRecordKey = $ZodRecordKey, Value extends SomeType = $ZodType> extends $ZodType {
664
679
  _zod: $ZodRecordInternals<Key, Value>;
665
680
  }
666
681
  export declare const $ZodRecord: core.$constructor<$ZodRecord>;
667
- export interface $ZodMapDef extends $ZodTypeDef {
682
+ export interface $ZodMapDef<Key extends SomeType = $ZodType, Value extends SomeType = $ZodType> extends $ZodTypeDef {
668
683
  type: "map";
669
- keyType: $ZodType;
670
- valueType: $ZodType;
684
+ keyType: Key;
685
+ valueType: Value;
671
686
  }
672
- export interface $ZodMapInternals<Key extends $ZodType = $ZodType, Value extends $ZodType = $ZodType> extends $ZodTypeInternals<Map<core.output<Key>, core.output<Value>>, Map<core.input<Key>, core.input<Value>>> {
673
- def: $ZodMapDef;
687
+ export interface $ZodMapInternals<Key extends SomeType = $ZodType, Value extends SomeType = $ZodType> extends $ZodTypeInternals<Map<core.output<Key>, core.output<Value>>, Map<core.input<Key>, core.input<Value>>> {
688
+ def: $ZodMapDef<Key, Value>;
674
689
  isst: errors.$ZodIssueInvalidType | errors.$ZodIssueInvalidKey | errors.$ZodIssueInvalidElement<unknown>;
675
690
  }
676
- export interface $ZodMap<Key extends $ZodType = $ZodType, Value extends $ZodType = $ZodType> extends $ZodType {
691
+ export interface $ZodMap<Key extends SomeType = $ZodType, Value extends SomeType = $ZodType> extends $ZodType {
677
692
  _zod: $ZodMapInternals<Key, Value>;
678
693
  }
679
694
  export declare const $ZodMap: core.$constructor<$ZodMap>;
680
- export interface $ZodSetDef extends $ZodTypeDef {
695
+ export interface $ZodSetDef<T extends SomeType = $ZodType> extends $ZodTypeDef {
681
696
  type: "set";
682
- valueType: $ZodType;
697
+ valueType: T;
683
698
  }
684
- export interface $ZodSetInternals<T extends $ZodType = $ZodType> extends $ZodTypeInternals<Set<core.output<T>>, Set<core.input<T>>> {
685
- def: $ZodSetDef;
699
+ export interface $ZodSetInternals<T extends SomeType = $ZodType> extends $ZodTypeInternals<Set<core.output<T>>, Set<core.input<T>>> {
700
+ def: $ZodSetDef<T>;
686
701
  isst: errors.$ZodIssueInvalidType;
687
702
  }
688
- export interface $ZodSet<T extends $ZodType = $ZodType> extends $ZodType {
703
+ export interface $ZodSet<T extends SomeType = $ZodType> extends $ZodType {
689
704
  _zod: $ZodSetInternals<T>;
690
705
  }
691
706
  export declare const $ZodSet: core.$constructor<$ZodSet>;
@@ -733,6 +748,11 @@ export interface $ZodFileDef extends $ZodTypeDef {
733
748
  export interface $ZodFileInternals extends $ZodTypeInternals<File, File> {
734
749
  def: $ZodFileDef;
735
750
  isst: errors.$ZodIssueInvalidType;
751
+ bag: util.LoosePartial<{
752
+ minimum: number;
753
+ maximum: number;
754
+ mime: util.MimeTypes[];
755
+ }>;
736
756
  }
737
757
  export interface $ZodFile extends $ZodType {
738
758
  _zod: $ZodFileInternals;
@@ -750,11 +770,11 @@ export interface $ZodTransform<O = unknown, I = unknown> extends $ZodType {
750
770
  _zod: $ZodTransformInternals<O, I>;
751
771
  }
752
772
  export declare const $ZodTransform: core.$constructor<$ZodTransform>;
753
- export interface $ZodOptionalDef<T extends $ZodType = $ZodType> extends $ZodTypeDef {
773
+ export interface $ZodOptionalDef<T extends SomeType = $ZodType> extends $ZodTypeDef {
754
774
  type: "optional";
755
775
  innerType: T;
756
776
  }
757
- export interface $ZodOptionalInternals<T extends $ZodType = $ZodType> extends $ZodTypeInternals<core.output<T> | undefined, core.input<T> | undefined> {
777
+ export interface $ZodOptionalInternals<T extends SomeType = $ZodType> extends $ZodTypeInternals<core.output<T> | undefined, core.input<T> | undefined> {
758
778
  def: $ZodOptionalDef<T>;
759
779
  optin: "optional";
760
780
  optout: "optional";
@@ -762,15 +782,15 @@ export interface $ZodOptionalInternals<T extends $ZodType = $ZodType> extends $Z
762
782
  values: T["_zod"]["values"];
763
783
  pattern: T["_zod"]["pattern"];
764
784
  }
765
- export interface $ZodOptional<T extends $ZodType = $ZodType> extends $ZodType {
785
+ export interface $ZodOptional<T extends SomeType = $ZodType> extends $ZodType {
766
786
  _zod: $ZodOptionalInternals<T>;
767
787
  }
768
788
  export declare const $ZodOptional: core.$constructor<$ZodOptional>;
769
- export interface $ZodNullableDef<T extends $ZodType = $ZodType> extends $ZodTypeDef {
789
+ export interface $ZodNullableDef<T extends SomeType = $ZodType> extends $ZodTypeDef {
770
790
  type: "nullable";
771
791
  innerType: T;
772
792
  }
773
- export interface $ZodNullableInternals<T extends $ZodType = $ZodType> extends $ZodTypeInternals<core.output<T> | null, core.input<T> | null> {
793
+ export interface $ZodNullableInternals<T extends SomeType = $ZodType> extends $ZodTypeInternals<core.output<T> | null, core.input<T> | null> {
774
794
  def: $ZodNullableDef<T>;
775
795
  optin: T["_zod"]["optin"];
776
796
  optout: T["_zod"]["optout"];
@@ -778,64 +798,64 @@ export interface $ZodNullableInternals<T extends $ZodType = $ZodType> extends $Z
778
798
  values: T["_zod"]["values"];
779
799
  pattern: T["_zod"]["pattern"];
780
800
  }
781
- export interface $ZodNullable<T extends $ZodType = $ZodType> extends $ZodType {
801
+ export interface $ZodNullable<T extends SomeType = $ZodType> extends $ZodType {
782
802
  _zod: $ZodNullableInternals<T>;
783
803
  }
784
804
  export declare const $ZodNullable: core.$constructor<$ZodNullable>;
785
- export interface $ZodDefaultDef<T extends $ZodType = $ZodType> extends $ZodTypeDef {
805
+ export interface $ZodDefaultDef<T extends SomeType = $ZodType> extends $ZodTypeDef {
786
806
  type: "default";
787
807
  innerType: T;
788
808
  /** The default value. May be a getter. */
789
809
  defaultValue: util.NoUndefined<core.output<T>>;
790
810
  }
791
- export interface $ZodDefaultInternals<T extends $ZodType = $ZodType> extends $ZodTypeInternals<util.NoUndefined<core.output<T>>, core.input<T> | undefined> {
811
+ export interface $ZodDefaultInternals<T extends SomeType = $ZodType> extends $ZodTypeInternals<util.NoUndefined<core.output<T>>, core.input<T> | undefined> {
792
812
  def: $ZodDefaultDef<T>;
793
813
  optin: "optional";
794
814
  isst: never;
795
815
  values: T["_zod"]["values"];
796
816
  }
797
- export interface $ZodDefault<T extends $ZodType = $ZodType> extends $ZodType {
817
+ export interface $ZodDefault<T extends SomeType = $ZodType> extends $ZodType {
798
818
  _zod: $ZodDefaultInternals<T>;
799
819
  }
800
820
  export declare const $ZodDefault: core.$constructor<$ZodDefault>;
801
- export interface $ZodPrefaultDef<T extends $ZodType = $ZodType> extends $ZodTypeDef {
821
+ export interface $ZodPrefaultDef<T extends SomeType = $ZodType> extends $ZodTypeDef {
802
822
  type: "prefault";
803
823
  innerType: T;
804
824
  /** The default value. May be a getter. */
805
825
  defaultValue: core.input<T>;
806
826
  }
807
- export interface $ZodPrefaultInternals<T extends $ZodType = $ZodType> extends $ZodTypeInternals<util.NoUndefined<core.output<T>>, core.input<T> | undefined> {
827
+ export interface $ZodPrefaultInternals<T extends SomeType = $ZodType> extends $ZodTypeInternals<util.NoUndefined<core.output<T>>, core.input<T> | undefined> {
808
828
  def: $ZodPrefaultDef<T>;
809
829
  optin: "optional";
810
830
  isst: never;
811
831
  values: T["_zod"]["values"];
812
832
  }
813
- export interface $ZodPrefault<T extends $ZodType = $ZodType> extends $ZodType {
833
+ export interface $ZodPrefault<T extends SomeType = $ZodType> extends $ZodType {
814
834
  _zod: $ZodPrefaultInternals<T>;
815
835
  }
816
836
  export declare const $ZodPrefault: core.$constructor<$ZodPrefault>;
817
- export interface $ZodNonOptionalDef<T extends $ZodType = $ZodType> extends $ZodTypeDef {
837
+ export interface $ZodNonOptionalDef<T extends SomeType = $ZodType> extends $ZodTypeDef {
818
838
  type: "nonoptional";
819
839
  innerType: T;
820
840
  }
821
- export interface $ZodNonOptionalInternals<T extends $ZodType = $ZodType> extends $ZodTypeInternals<util.NoUndefined<core.output<T>>, util.NoUndefined<core.input<T>>> {
841
+ export interface $ZodNonOptionalInternals<T extends SomeType = $ZodType> extends $ZodTypeInternals<util.NoUndefined<core.output<T>>, util.NoUndefined<core.input<T>>> {
822
842
  def: $ZodNonOptionalDef<T>;
823
843
  isst: errors.$ZodIssueInvalidType;
824
844
  values: T["_zod"]["values"];
825
845
  }
826
- export interface $ZodNonOptional<T extends $ZodType = $ZodType> extends $ZodType {
846
+ export interface $ZodNonOptional<T extends SomeType = $ZodType> extends $ZodType {
827
847
  _zod: $ZodNonOptionalInternals<T>;
828
848
  }
829
849
  export declare const $ZodNonOptional: core.$constructor<$ZodNonOptional>;
830
- export interface $ZodSuccessDef extends $ZodTypeDef {
850
+ export interface $ZodSuccessDef<T extends SomeType = $ZodType> extends $ZodTypeDef {
831
851
  type: "success";
832
- innerType: $ZodType;
852
+ innerType: T;
833
853
  }
834
- export interface $ZodSuccessInternals<T extends $ZodType = $ZodType> extends $ZodTypeInternals<boolean, core.input<T>> {
835
- def: $ZodSuccessDef;
854
+ export interface $ZodSuccessInternals<T extends SomeType = $ZodType> extends $ZodTypeInternals<boolean, core.input<T>> {
855
+ def: $ZodSuccessDef<T>;
836
856
  isst: never;
837
857
  }
838
- export interface $ZodSuccess<T extends $ZodType = $ZodType> extends $ZodType {
858
+ export interface $ZodSuccess<T extends SomeType = $ZodType> extends $ZodType {
839
859
  _zod: $ZodSuccessInternals<T>;
840
860
  }
841
861
  export declare const $ZodSuccess: core.$constructor<$ZodSuccess>;
@@ -847,19 +867,19 @@ export interface $ZodCatchCtx extends ParsePayload {
847
867
  /** @deprecated Use `ctx.value` */
848
868
  input: unknown;
849
869
  }
850
- export interface $ZodCatchDef extends $ZodTypeDef {
870
+ export interface $ZodCatchDef<T extends SomeType = $ZodType> extends $ZodTypeDef {
851
871
  type: "catch";
852
- innerType: $ZodType;
872
+ innerType: T;
853
873
  catchValue: (ctx: $ZodCatchCtx) => unknown;
854
874
  }
855
- export interface $ZodCatchInternals<T extends $ZodType = $ZodType> extends $ZodTypeInternals<core.output<T>, core.input<T> | util.Whatever> {
856
- def: $ZodCatchDef;
875
+ export interface $ZodCatchInternals<T extends SomeType = $ZodType> extends $ZodTypeInternals<core.output<T>, core.input<T> | util.Whatever> {
876
+ def: $ZodCatchDef<T>;
857
877
  optin: T["_zod"]["optin"];
858
878
  optout: T["_zod"]["optout"];
859
879
  isst: never;
860
880
  values: T["_zod"]["values"];
861
881
  }
862
- export interface $ZodCatch<T extends $ZodType = $ZodType> extends $ZodType {
882
+ export interface $ZodCatch<T extends SomeType = $ZodType> extends $ZodType {
863
883
  _zod: $ZodCatchInternals<T>;
864
884
  }
865
885
  export declare const $ZodCatch: core.$constructor<$ZodCatch>;
@@ -874,34 +894,34 @@ export interface $ZodNaN extends $ZodType {
874
894
  _zod: $ZodNaNInternals;
875
895
  }
876
896
  export declare const $ZodNaN: core.$constructor<$ZodNaN>;
877
- export interface $ZodPipeDef<A extends $ZodType = $ZodType, B extends $ZodType = $ZodType> extends $ZodTypeDef {
897
+ export interface $ZodPipeDef<A extends SomeType = $ZodType, B extends SomeType = $ZodType> extends $ZodTypeDef {
878
898
  type: "pipe";
879
899
  in: A;
880
900
  out: B;
881
901
  }
882
- export interface $ZodPipeInternals<A extends $ZodType = $ZodType, B extends $ZodType = $ZodType> extends $ZodTypeInternals<core.output<B>, core.input<A>> {
902
+ export interface $ZodPipeInternals<A extends SomeType = $ZodType, B extends SomeType = $ZodType> extends $ZodTypeInternals<core.output<B>, core.input<A>> {
883
903
  def: $ZodPipeDef<A, B>;
884
904
  isst: never;
885
905
  values: A["_zod"]["values"];
886
906
  optin: A["_zod"]["optin"];
887
907
  optout: B["_zod"]["optout"];
888
908
  }
889
- export interface $ZodPipe<A extends $ZodType = $ZodType, B extends $ZodType = $ZodType> extends $ZodType {
909
+ export interface $ZodPipe<A extends SomeType = $ZodType, B extends SomeType = $ZodType> extends $ZodType {
890
910
  _zod: $ZodPipeInternals<A, B>;
891
911
  }
892
912
  export declare const $ZodPipe: core.$constructor<$ZodPipe>;
893
- export interface $ZodReadonlyDef extends $ZodTypeDef {
913
+ export interface $ZodReadonlyDef<T extends SomeType = $ZodType> extends $ZodTypeDef {
894
914
  type: "readonly";
895
- innerType: $ZodType;
915
+ innerType: T;
896
916
  }
897
- export interface $ZodReadonlyInternals<T extends $ZodType = $ZodType> extends $ZodTypeInternals<util.MakeReadonly<core.output<T>>, util.MakeReadonly<core.input<T>>> {
898
- def: $ZodReadonlyDef;
917
+ export interface $ZodReadonlyInternals<T extends SomeType = $ZodType> extends $ZodTypeInternals<util.MakeReadonly<core.output<T>>, util.MakeReadonly<core.input<T>>> {
918
+ def: $ZodReadonlyDef<T>;
899
919
  optin: T["_zod"]["optin"];
900
920
  optout: T["_zod"]["optout"];
901
921
  isst: never;
902
- disc: T["_zod"]["disc"];
922
+ propValues: T["_zod"]["propValues"];
903
923
  }
904
- export interface $ZodReadonly<T extends $ZodType = $ZodType> extends $ZodType {
924
+ export interface $ZodReadonly<T extends SomeType = $ZodType> extends $ZodType {
905
925
  _zod: $ZodReadonlyInternals<T>;
906
926
  }
907
927
  export declare const $ZodReadonly: core.$constructor<$ZodReadonly>;
@@ -926,36 +946,44 @@ interface SchemaPart extends $ZodType {
926
946
  }
927
947
  export type $ZodTemplateLiteralPart = LiteralPart | SchemaPart;
928
948
  type UndefinedToEmptyString<T> = T extends undefined ? "" : T;
929
- type AppendToTemplateLiteral<Template extends string, Suffix extends LiteralPart | $ZodType> = Suffix extends LiteralPart ? `${Template}${UndefinedToEmptyString<Suffix>}` : `${Template}${UndefinedToEmptyString<LiteralPart & core.output<Suffix & $ZodType>>}`;
930
- export type $PartsToTemplateLiteral<Parts extends $ZodTemplateLiteralPart[]> = [] extends Parts ? `` : Parts extends [...infer Rest extends $ZodTemplateLiteralPart[], infer Last extends $ZodTemplateLiteralPart] ? AppendToTemplateLiteral<$PartsToTemplateLiteral<Rest>, Last> : never;
949
+ type AppendToTemplateLiteral<Template extends string, Suffix extends LiteralPart | $ZodType> = Suffix extends LiteralPart ? `${Template}${UndefinedToEmptyString<Suffix>}` : Suffix extends $ZodType ? `${Template}${core.output<Suffix> extends infer T extends LiteralPart ? UndefinedToEmptyString<T> : never}` : never;
950
+ export type ConcatenateTupleOfStrings<T extends string[]> = T extends [
951
+ infer First extends string,
952
+ ...infer Rest extends string[]
953
+ ] ? Rest extends string[] ? First extends "" ? ConcatenateTupleOfStrings<Rest> : `${First}${ConcatenateTupleOfStrings<Rest>}` : never : "";
954
+ export type ConvertPartsToStringTuple<Parts extends $ZodTemplateLiteralPart[]> = {
955
+ [K in keyof Parts]: Parts[K] extends LiteralPart ? `${UndefinedToEmptyString<Parts[K]>}` : Parts[K] extends $ZodType ? `${core.output<Parts[K]> extends infer T extends LiteralPart ? UndefinedToEmptyString<T> : never}` : never;
956
+ };
957
+ export type ToTemplateLiteral<Parts extends $ZodTemplateLiteralPart[]> = ConcatenateTupleOfStrings<ConvertPartsToStringTuple<Parts>>;
958
+ export type $PartsToTemplateLiteral<Parts extends $ZodTemplateLiteralPart[]> = [] extends Parts ? `` : Parts extends [...infer Rest, infer Last extends $ZodTemplateLiteralPart] ? Rest extends $ZodTemplateLiteralPart[] ? AppendToTemplateLiteral<$PartsToTemplateLiteral<Rest>, Last> : never : never;
931
959
  export declare const $ZodTemplateLiteral: core.$constructor<$ZodTemplateLiteral>;
932
- export interface $ZodPromiseDef extends $ZodTypeDef {
960
+ export interface $ZodPromiseDef<T extends SomeType = $ZodType> extends $ZodTypeDef {
933
961
  type: "promise";
934
- innerType: $ZodType;
962
+ innerType: T;
935
963
  }
936
- export interface $ZodPromiseInternals<T extends $ZodType = $ZodType> extends $ZodTypeInternals<core.output<T>, util.MaybeAsync<core.input<T>>> {
937
- def: $ZodPromiseDef;
964
+ export interface $ZodPromiseInternals<T extends SomeType = $ZodType> extends $ZodTypeInternals<core.output<T>, util.MaybeAsync<core.input<T>>> {
965
+ def: $ZodPromiseDef<T>;
938
966
  isst: never;
939
967
  }
940
- export interface $ZodPromise<T extends $ZodType = $ZodType> extends $ZodType {
968
+ export interface $ZodPromise<T extends SomeType = $ZodType> extends $ZodType {
941
969
  _zod: $ZodPromiseInternals<T>;
942
970
  }
943
971
  export declare const $ZodPromise: core.$constructor<$ZodPromise>;
944
- export interface $ZodLazyDef extends $ZodTypeDef {
972
+ export interface $ZodLazyDef<T extends SomeType = $ZodType> extends $ZodTypeDef {
945
973
  type: "lazy";
946
- getter: () => $ZodType;
974
+ getter: () => T;
947
975
  }
948
- export interface $ZodLazyInternals<T extends $ZodType = $ZodType> extends $ZodTypeInternals<core.output<T>, core.input<T>> {
949
- def: $ZodLazyDef;
976
+ export interface $ZodLazyInternals<T extends SomeType = $ZodType> extends $ZodTypeInternals<core.output<T>, core.input<T>> {
977
+ def: $ZodLazyDef<T>;
950
978
  isst: never;
951
979
  /** Auto-cached way to retrieve the inner schema */
952
980
  innerType: T;
953
981
  pattern: T["_zod"]["pattern"];
954
- disc: T["_zod"]["disc"];
982
+ propValues: T["_zod"]["propValues"];
955
983
  optin: T["_zod"]["optin"];
956
984
  optout: T["_zod"]["optout"];
957
985
  }
958
- export interface $ZodLazy<T extends $ZodType = $ZodType> extends $ZodType {
986
+ export interface $ZodLazy<T extends SomeType = $ZodType> extends $ZodType {
959
987
  _zod: $ZodLazyInternals<T>;
960
988
  }
961
989
  export declare const $ZodLazy: core.$constructor<$ZodLazy>;
@@ -5,7 +5,7 @@ import type * as schemas from "./schemas.js";
5
5
  export type JSONType = string | number | boolean | null | JSONType[] | {
6
6
  [key: string]: JSONType;
7
7
  };
8
- export type JWTAlgorithm = "HS256" | "HS384" | "HS512" | "RS256" | "RS384" | "RS512" | "ES256" | "ES384" | "ES512" | "PS256" | "PS384" | "PS512";
8
+ export type JWTAlgorithm = "HS256" | "HS384" | "HS512" | "RS256" | "RS384" | "RS512" | "ES256" | "ES384" | "ES512" | "PS256" | "PS384" | "PS512" | "EdDSA" | (string & {});
9
9
  export type IPVersion = "v4" | "v6";
10
10
  export type MimeTypes = "application/json" | "application/xml" | "application/x-www-form-urlencoded" | "application/javascript" | "application/pdf" | "application/zip" | "application/vnd.ms-excel" | "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet" | "application/msword" | "application/vnd.openxmlformats-officedocument.wordprocessingml.document" | "application/vnd.ms-powerpoint" | "application/vnd.openxmlformats-officedocument.presentationml.presentation" | "application/octet-stream" | "application/graphql" | "text/html" | "text/plain" | "text/css" | "text/javascript" | "text/csv" | "image/png" | "image/jpeg" | "image/gif" | "image/svg+xml" | "image/webp" | "audio/mpeg" | "audio/ogg" | "audio/wav" | "audio/webm" | "video/mp4" | "video/webm" | "video/ogg" | "font/woff" | "font/woff2" | "font/ttf" | "font/otf" | "multipart/form-data" | (string & {});
11
11
  export type ParsedTypes = "string" | "number" | "bigint" | "boolean" | "symbol" | "undefined" | "object" | "function" | "file" | "date" | "array" | "map" | "set" | "nan" | "null" | "promise";
@@ -59,7 +59,7 @@ export type Extend<A extends SomeObject, B extends SomeObject> = Flatten<keyof A
59
59
  } & {
60
60
  [K in keyof B]: B[K];
61
61
  }>;
62
- export type TupleItems = ReadonlyArray<schemas.$ZodType>;
62
+ export type TupleItems = ReadonlyArray<schemas.SomeType>;
63
63
  export type AnyFunc = (...args: any[]) => any;
64
64
  export type IsProp<T, K extends keyof T> = T[K] extends AnyFunc ? never : K;
65
65
  export type MaybeAsync<T> = T | Promise<T>;
@@ -71,7 +71,7 @@ export type ExtractIndexSignature<T> = {
71
71
  [K in keyof T as string extends K ? K : K extends string ? never : K]: T[K];
72
72
  };
73
73
  export type Keys<T extends object> = keyof OmitIndexSignature<T>;
74
- export type SchemaClass<T extends schemas.$ZodType> = {
74
+ export type SchemaClass<T extends schemas.SomeType> = {
75
75
  new (def: T["_zod"]["def"]): T;
76
76
  };
77
77
  export type EnumValue = string | number;
@@ -103,18 +103,14 @@ export type SafeParseError<T> = {
103
103
  data?: never;
104
104
  error: errors.$ZodError<T>;
105
105
  };
106
- export type DiscriminatorMapElement = {
107
- values: Set<Primitive>;
108
- maps: DiscriminatorMap[];
109
- };
110
- export type DiscriminatorMap = Map<PropertyKey, DiscriminatorMapElement>;
106
+ export type PropValues = Record<string, Set<Primitive>>;
111
107
  export type PrimitiveSet = Set<Primitive>;
112
108
  export declare function assertEqual<A, B>(val: AssertEqual<A, B>): AssertEqual<A, B>;
113
109
  export declare function assertNotEqual<A, B>(val: AssertNotEqual<A, B>): AssertNotEqual<A, B>;
114
110
  export declare function assertIs<T>(_arg: T): void;
115
111
  export declare function assertNever(_x: never): never;
116
112
  export declare function assert<T>(_: any): asserts _ is T;
117
- export declare function getValidEnumValues(obj: any): any;
113
+ export declare function getEnumValues(entries: EnumLike): EnumValue[];
118
114
  export declare function joinValues<T extends Primitive[]>(array: T, separator?: string): string;
119
115
  export declare function jsonStringifyReplacer(_: string, value: any): any;
120
116
  export declare function cached<T>(getter: () => T): {
@@ -1,7 +1,4 @@
1
1
  import type * as errors from "../core/errors.js";
2
- export declare const parsedType: (data: any) => string;
3
- declare const error: errors.$ZodErrorMap;
4
- export { error };
5
2
  export default function (): {
6
3
  localeError: errors.$ZodErrorMap;
7
4
  };
@@ -1,7 +1,4 @@
1
1
  import type * as errors from "../core/errors.js";
2
- export declare const parsedType: (data: any) => string;
3
- declare const error: errors.$ZodErrorMap;
4
- export { error };
5
2
  export default function (): {
6
3
  localeError: errors.$ZodErrorMap;
7
4
  };