import { Message } from './errors'; import { FieldValues, InternalFieldName } from './fields'; import { FieldPath, FieldPathValue } from './path'; export declare type ValidationValue = boolean | number | string | RegExp; export declare type ValidationRule = TValidationValue | ValidationValueMessage; export declare type ValidationValueMessage = { value: TValidationValue; message: Message; }; export declare type ValidateResult = Message | Message[] | boolean | undefined; export declare type Validate = (value: TFieldValue) => ValidateResult | Promise; export declare type RegisterOptions = FieldPath> = Partial<{ required: Message | ValidationRule; min: ValidationRule; max: ValidationRule; maxLength: ValidationRule; minLength: ValidationRule; pattern: ValidationRule; validate: Validate> | Record>>; valueAsNumber: boolean; valueAsDate: boolean; value: FieldPathValue; setValueAs: (value: any) => any; shouldUnregister?: boolean; onChange?: (event: any) => void; onBlur?: (event: any) => void; disabled: boolean; deps: InternalFieldName | InternalFieldName[]; }>; //# sourceMappingURL=validator.d.ts.map