@hono/zod-openapi 0.8.0 → 0.8.1

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/dist/index.d.mts CHANGED
@@ -20,7 +20,7 @@ type IsForm<T> = T extends string ? T extends `multipart/form-data${infer _Rest}
20
20
  type RequestPart<R extends RouteConfig, Part extends string> = Part extends keyof R['request'] ? R['request'][Part] : {};
21
21
  type InputTypeBase<R extends RouteConfig, Part extends string, Type extends string> = R['request'] extends RequestTypes ? RequestPart<R, Part> extends AnyZodObject ? {
22
22
  in: {
23
- [K in Type]: z.input<RequestPart<R, Part>>;
23
+ [K in Type]: z.infer<RequestPart<R, Part>>;
24
24
  };
25
25
  out: {
26
26
  [K in Type]: z.output<RequestPart<R, Part>>;
@@ -28,7 +28,7 @@ type InputTypeBase<R extends RouteConfig, Part extends string, Type extends stri
28
28
  } : {} : {};
29
29
  type InputTypeJson<R extends RouteConfig> = R['request'] extends RequestTypes ? R['request']['body'] extends ZodRequestBody ? R['request']['body']['content'] extends ZodContentObject ? IsJson<keyof R['request']['body']['content']> extends never ? {} : R['request']['body']['content'][keyof R['request']['body']['content']]['schema'] extends ZodSchema<any> ? {
30
30
  in: {
31
- json: z.input<R['request']['body']['content'][keyof R['request']['body']['content']]['schema']>;
31
+ json: z.infer<R['request']['body']['content'][keyof R['request']['body']['content']]['schema']>;
32
32
  };
33
33
  out: {
34
34
  json: z.output<R['request']['body']['content'][keyof R['request']['body']['content']]['schema']>;
@@ -36,7 +36,7 @@ type InputTypeJson<R extends RouteConfig> = R['request'] extends RequestTypes ?
36
36
  } : {} : {} : {} : {};
37
37
  type InputTypeForm<R extends RouteConfig> = R['request'] extends RequestTypes ? R['request']['body'] extends ZodRequestBody ? R['request']['body']['content'] extends ZodContentObject ? IsForm<keyof R['request']['body']['content']> extends never ? {} : R['request']['body']['content'][keyof R['request']['body']['content']]['schema'] extends ZodSchema<any> ? {
38
38
  in: {
39
- form: z.input<R['request']['body']['content'][keyof R['request']['body']['content']]['schema']>;
39
+ form: z.infer<R['request']['body']['content'][keyof R['request']['body']['content']]['schema']>;
40
40
  };
41
41
  out: {
42
42
  form: z.output<R['request']['body']['content'][keyof R['request']['body']['content']]['schema']>;
package/dist/index.d.ts CHANGED
@@ -20,7 +20,7 @@ type IsForm<T> = T extends string ? T extends `multipart/form-data${infer _Rest}
20
20
  type RequestPart<R extends RouteConfig, Part extends string> = Part extends keyof R['request'] ? R['request'][Part] : {};
21
21
  type InputTypeBase<R extends RouteConfig, Part extends string, Type extends string> = R['request'] extends RequestTypes ? RequestPart<R, Part> extends AnyZodObject ? {
22
22
  in: {
23
- [K in Type]: z.input<RequestPart<R, Part>>;
23
+ [K in Type]: z.infer<RequestPart<R, Part>>;
24
24
  };
25
25
  out: {
26
26
  [K in Type]: z.output<RequestPart<R, Part>>;
@@ -28,7 +28,7 @@ type InputTypeBase<R extends RouteConfig, Part extends string, Type extends stri
28
28
  } : {} : {};
29
29
  type InputTypeJson<R extends RouteConfig> = R['request'] extends RequestTypes ? R['request']['body'] extends ZodRequestBody ? R['request']['body']['content'] extends ZodContentObject ? IsJson<keyof R['request']['body']['content']> extends never ? {} : R['request']['body']['content'][keyof R['request']['body']['content']]['schema'] extends ZodSchema<any> ? {
30
30
  in: {
31
- json: z.input<R['request']['body']['content'][keyof R['request']['body']['content']]['schema']>;
31
+ json: z.infer<R['request']['body']['content'][keyof R['request']['body']['content']]['schema']>;
32
32
  };
33
33
  out: {
34
34
  json: z.output<R['request']['body']['content'][keyof R['request']['body']['content']]['schema']>;
@@ -36,7 +36,7 @@ type InputTypeJson<R extends RouteConfig> = R['request'] extends RequestTypes ?
36
36
  } : {} : {} : {} : {};
37
37
  type InputTypeForm<R extends RouteConfig> = R['request'] extends RequestTypes ? R['request']['body'] extends ZodRequestBody ? R['request']['body']['content'] extends ZodContentObject ? IsForm<keyof R['request']['body']['content']> extends never ? {} : R['request']['body']['content'][keyof R['request']['body']['content']]['schema'] extends ZodSchema<any> ? {
38
38
  in: {
39
- form: z.input<R['request']['body']['content'][keyof R['request']['body']['content']]['schema']>;
39
+ form: z.infer<R['request']['body']['content'][keyof R['request']['body']['content']]['schema']>;
40
40
  };
41
41
  out: {
42
42
  form: z.output<R['request']['body']['content'][keyof R['request']['body']['content']]['schema']>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hono/zod-openapi",
3
- "version": "0.8.0",
3
+ "version": "0.8.1",
4
4
  "description": "A wrapper class of Hono which supports OpenAPI.",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",