import { DateTime } from 'luxon';
import type { JsonValue } from 'type-fest';
import { z } from 'zod';
interface ErrorContext<T> {
    error: z.ZodError;
    input: T;
}
interface LooseOpts<T> {
    onError?: (err: ErrorContext<T>) => void;
}
/**
 * Works like `z.array()`, but drops wrong elements instead of invalidating the whole array.
 *
 * **Important**: non-array inputs are still invalid.
 * Use `LooseArray(...).catch([])` to handle it.
 *
 * @param Elem Schema for array elements
 * @param onError Callback for errors
 * @returns Schema for array
 */
export declare function LooseArray<Schema extends z.ZodTypeAny>(Elem: Schema, { onError }?: LooseOpts<unknown[]>): z.ZodEffects<z.ZodArray<z.ZodAny, 'many'>, z.TypeOf<Schema>[], any[]>;
type LooseRecordResult<KeySchema extends z.ZodTypeAny, ValueSchema extends z.ZodTypeAny> = z.ZodEffects<z.ZodRecord<z.ZodString, z.ZodAny>, Record<z.TypeOf<KeySchema>, z.TypeOf<ValueSchema>>, Record<z.TypeOf<KeySchema>, any>>;
type LooseRecordOpts<KeySchema extends z.ZodTypeAny, ValueSchema extends z.ZodTypeAny> = LooseOpts<Record<z.TypeOf<KeySchema> | z.TypeOf<ValueSchema>, unknown>>;
/**
 * Works like `z.record()`, but drops wrong elements instead of invalidating the whole record.
 *
 * **Important**: non-record inputs other are still invalid.
 * Use `LooseRecord(...).catch({})` to handle it.
 *
 * @param KeyValue Schema for record keys
 * @param ValueValue Schema for record values
 * @param onError Callback for errors
 * @returns Schema for record
 */
export declare function LooseRecord<ValueSchema extends z.ZodTypeAny>(Value: ValueSchema): LooseRecordResult<z.ZodString, ValueSchema>;
export declare function LooseRecord<KeySchema extends z.ZodTypeAny, ValueSchema extends z.ZodTypeAny>(Key: KeySchema, Value: ValueSchema): LooseRecordResult<KeySchema, ValueSchema>;
export declare function LooseRecord<ValueSchema extends z.ZodTypeAny>(Value: ValueSchema, { onError }: LooseRecordOpts<z.ZodString, ValueSchema>): LooseRecordResult<z.ZodString, ValueSchema>;
export declare function LooseRecord<KeySchema extends z.ZodTypeAny, ValueSchema extends z.ZodTypeAny>(Key: KeySchema, Value: ValueSchema, { onError }: LooseRecordOpts<KeySchema, ValueSchema>): LooseRecordResult<KeySchema, ValueSchema>;
export declare const Json: z.ZodEffects<z.ZodString, string | number | boolean | import("type-fest").JsonObject | JsonValue[] | readonly JsonValue[] | null, string>;
export declare const Json5: z.ZodEffects<z.ZodString, string | number | boolean | import("type-fest").JsonObject | JsonValue[] | readonly JsonValue[] | null, string>;
export declare const UtcDate: z.ZodEffects<z.ZodString, DateTime, string>;
export declare const Url: z.ZodEffects<z.ZodString, URL, string>;
export declare const Yaml: z.ZodEffects<z.ZodString, string | number | boolean | import("type-fest").JsonObject | JsonValue[] | readonly JsonValue[] | null, string>;
export {};
