// ---------------------------------------------------------------------------
// Constants
// ---------------------------------------------------------------------------
/** Placeholder character used in formatting templates. */
export const DIGIT_PLACEHOLDER = 'x';
/** Dummy digit used to generate formatting templates. */
export const DUMMY_DIGIT = '9';
/** Maximum possible national number length. */
export const LONGEST_NATIONAL_NUMBER_LENGTH = 15;
/** Minimum digits before progressive leading-digits matching kicks in. */
export const MIN_LEADING_DIGITS_LENGTH = 3;
/**
 * Pattern that matches national prefix formatting rules that are just "$1"
 * or "($1)" — i.e. rules that don't actually prepend a national prefix digit.
 */
export const FIRST_GROUP_ONLY_PREFIX_PATTERN = /^\(?\$1\)?$/;
// ---------------------------------------------------------------------------
// Parse error codes
// ---------------------------------------------------------------------------
/** Error code thrown when the input does not contain a valid phone number. */
export const PARSE_ERROR_NOT_A_NUMBER = 'NOT_A_NUMBER';
/** Error code thrown when the country cannot be determined from the input. */
export const PARSE_ERROR_INVALID_COUNTRY = 'INVALID_COUNTRY';
