import t from "../i18n/index.js";
export function textContainsEmail(element) {
    const text = element?.textContent || "";
    const emailRegex = /\b[A-Z0-9._%+-]+@[A-Z0-9.-]+\.[A-Z]{2,}\b/gi;
    return emailRegex.test(text);
}
export function getEmailPresenceHelperContent() {
    return t("warning.email-in-text");
}
