import type { CustomOptions, CustomValidate } from "../custom/index.ts"; /** * @credits * [Email address](https://en.wikipedia.org/wiki/Email_address) regex. * [Valibot](https://github.com/fabian-hiller/valibot/blob/c3de9371c2cfa4e126734ddf0e2ab1de98e8a6ef/library/src/regex.ts#L30) */ export declare const EMAIL_REGEX: RegExp; /** * Determines if the input is an email address. * * @param input The value to check. * @param validate Additional validation to run against the input if it is an email address. Default is `undefined`. * @returns `true` if the input is an email address, `false` otherwise. */ export declare function isEmail(input: unknown, validate?: CustomValidate): input is string; export type EmailOptions = Omit, "typecheck">; /** * Verifies that the input is an email address, and returns it. * If the input is not an email address, the fallback value is returned. * * @param input The value to check. * @param fallback The value to return if the input is not an email address. Default is `null`. * @returns The email address value of the input, or the fallback if the input is not an email address. */ export declare function email(input: unknown, fallback: string, options?: EmailOptions): string; export declare function email(input: unknown, fallback?: string | null | undefined, options?: EmailOptions): string | null;