@orpc/zod 0.0.0-next.cba521d → 0.0.0-next.ccd4e42

Sign up to get free protection for your applications and to get access to all the features.
package/dist/index.js CHANGED
@@ -724,6 +724,7 @@ function zodToJsonSchema(schema, options) {
724
724
  const schema_ = schema__;
725
725
  const def = schema_._def;
726
726
  const json = { type: "array" };
727
+ json.items = zodToJsonSchema(def.type, childOptions);
727
728
  if (def.exactLength) {
728
729
  json.maxItems = def.exactLength.value;
729
730
  json.minItems = def.exactLength.value;
@@ -1,5 +1,5 @@
1
1
  import type { Schema } from '@orpc/contract';
2
- import type { SchemaCoercer } from '@orpc/openapi/fetch';
2
+ import type { SchemaCoercer } from '@orpc/openapi/standard';
3
3
  export declare class ZodCoercer implements SchemaCoercer {
4
4
  coerce(schema: Schema, value: unknown): unknown;
5
5
  }
@@ -10,7 +10,7 @@ export declare function getCustomJSONSchema(def: ZodTypeDef, options?: {
10
10
  mode?: 'input' | 'output';
11
11
  }): Exclude<JSONSchema, boolean> | undefined;
12
12
  export declare function file(params?: string | CustomParams | ((input: unknown) => CustomParams)): ZodType<InstanceType<typeof File>, ZodTypeDef, InstanceType<typeof File>> & {
13
- type: (mimeType: string, params?: string | CustomParams | ((input: unknown) => CustomParams)) => ZodEffects<ZodType<InstanceType<typeof File>, ZodTypeDef, InstanceType<typeof File>>, InstanceType<typeof File>, InstanceType<typeof File>>;
13
+ type(mimeType: string, params?: string | CustomParams | ((input: unknown) => CustomParams)): ZodEffects<ZodType<InstanceType<typeof File>, ZodTypeDef, InstanceType<typeof File>>, InstanceType<typeof File>, InstanceType<typeof File>>;
14
14
  };
15
15
  export declare function blob(params?: string | CustomParams | ((input: unknown) => CustomParams)): ZodType<InstanceType<typeof Blob>, ZodTypeDef, InstanceType<typeof Blob>>;
16
16
  export declare function invalidDate(params?: string | CustomParams | ((input: unknown) => CustomParams)): ZodType<Date, ZodTypeDef, Date>;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@orpc/zod",
3
3
  "type": "module",
4
- "version": "0.0.0-next.cba521d",
4
+ "version": "0.0.0-next.ccd4e42",
5
5
  "license": "MIT",
6
6
  "homepage": "https://orpc.unnoq.com",
7
7
  "repository": {
@@ -29,7 +29,7 @@
29
29
  "dist"
30
30
  ],
31
31
  "peerDependencies": {
32
- "@orpc/openapi": "0.0.0-next.cba521d"
32
+ "@orpc/openapi": "0.0.0-next.ccd4e42"
33
33
  },
34
34
  "dependencies": {
35
35
  "json-schema-typed": "^8.0.1",