import { z } from 'zod'; import type { ItemSchema, MapSchema, Schema, TransformedValue } from '../../../../schema/index.js'; import type { Transformer } from '../../../../transformers/transformer.js'; import type { Extends, If, Or } from '../../../../types/index.js'; import type { SavedAsAttributes } from '../utils.js'; import type { ZodParserOptions } from './types.js'; export type ZodLiteralMap[] = []> = LITERALS extends [infer LITERALS_HEAD, ...infer LITERALS_TAIL] ? LITERALS_HEAD extends z.Primitive ? LITERALS_TAIL extends z.Primitive[] ? ZodLiteralMap]> : never : never : RESULTS; export type WithDefault = If, ZOD_SCHEMA, If, Extends>, z.ZodDefault, ZOD_SCHEMA>>; export declare const withDefault: (schema: Schema, { fill }: ZodParserOptions, zodSchema: z.ZodTypeAny) => z.ZodTypeAny; export type WithOptional = If, ZOD_SCHEMA, If, z.ZodOptional, ZOD_SCHEMA>>; export declare const withOptional: (schema: Schema, { defined }: ZodParserOptions, zodSchema: z.ZodTypeAny) => z.ZodTypeAny; export type WithEncoding = If, ZOD_SCHEMA, If, z.ZodEffects, z.input>, ZOD_SCHEMA>>; export declare const withEncoding: (schema: Extract, { transform }: ZodParserOptions, zodSchema: z.ZodTypeAny) => z.ZodTypeAny; export type WithAttributeNameEncoding = If, Extends<[SavedAsAttributes], [never]>>, ZOD_SCHEMA, z.ZodEffects, z.input>>; export declare const withAttributeNameEncoding: (schema: MapSchema | ItemSchema, { transform }: ZodParserOptions, zodSchema: z.ZodTypeAny) => z.ZodTypeAny; export declare const compileAttributeNameEncoder: (schema: MapSchema | ItemSchema) => (decoded: unknown) => Record;