// Matches any character that is not a digit, whitespace, or phone formatting character (+, -, (, ))
const INVALID_PHONE_CHARS_RE = /[^\d\s+\-()]/;

export const isNumericValue = (val) => !!val && !INVALID_PHONE_CHARS_RE.test(val);

export const sanitizeCountryCodePrefix = (val) => val.replace(/\+\d+-/, '');
