import { z } from 'zod'; import type { AnyOfSchema, Schema } from '../../../../schema/index.js'; import type { Overwrite } from '../../../../types/overwrite.js'; import type { WithValidate } from '../utils.js'; import type { SchemaZodParser } from './schema.js'; import type { ZodParserOptions } from './types.js'; import type { WithDefault, WithOptional } from './utils.js'; export type AnyOfZodParser = AnyOfSchema extends SCHEMA ? z.ZodTypeAny : WithDefault>> : SCHEMA['elements'] extends [infer SCHEMAS_HEAD, ...infer SCHEMAS_TAIL] ? SCHEMAS_HEAD extends Schema ? SCHEMAS_TAIL extends Schema[] ? z.ZodUnion<[ SchemaZodParser>, ...MapAnyOfZodParser> ]> : never : never : z.ZodTypeAny>>>; type MapAnyOfZodParser = SCHEMAS extends [infer SCHEMAS_HEAD, ...infer SCHEMAS_TAIL] ? SCHEMAS_HEAD extends Schema ? SCHEMAS_TAIL extends Schema[] ? MapAnyOfZodParser ]> : never : never : RESULTS; export declare const anyOfZodParser: (schema: AnyOfSchema, options?: ZodParserOptions) => z.ZodTypeAny; export {};