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es6/helpers/getPossibleCountriesForNumber.js","webpack://frontend/./node_modules/libphonenumber-js/es6/helpers/mergeArrays.js","webpack://frontend/./node_modules/libphonenumber-js/es6/helpers/parseDigits.js","webpack://frontend/./node_modules/libphonenumber-js/es6/helpers/matchesEntirely.js","webpack://frontend/./node_modules/libphonenumber-js/es6/helpers/getCountryByNationalNumber.js","webpack://frontend/./node_modules/libphonenumber-js/es6/helpers/getCountryByCallingCode.js","webpack://frontend/./node_modules/libphonenumber-js/es6/helpers/stripIddPrefix.js","webpack://frontend/./node_modules/libphonenumber-js/es6/helpers/getIddPrefix.js","webpack://frontend/./node_modules/libphonenumber-js/es6/helpers/isViablePhoneNumber.js","webpack://frontend/./node_modules/libphonenumber-js/es6/helpers/getNumberType.js"],"sourcesContent":["var objectConstructor = {}.constructor;\nexport default function isObject(object) {\n return object !== undefined && object !== null && object.constructor === objectConstructor;\n}\n//# sourceMappingURL=isObject.js.map","import Metadata from '../metadata.js';\n\n/**\r\n * Returns a list of countries that the phone number could potentially belong to.\r\n * @param {string} callingCode — Calling code.\r\n * @param {string} nationalNumber — National (significant) number.\r\n * @param {object} metadata — Metadata.\r\n * @return {string[]} A list of possible countries.\r\n */\nexport default function getPossibleCountriesForNumber(callingCode, nationalNumber, metadata) {\n var _metadata = new Metadata(metadata);\n var possibleCountries = _metadata.getCountryCodesForCallingCode(callingCode);\n if (!possibleCountries) {\n return [];\n }\n return possibleCountries.filter(function (country) {\n return couldNationalNumberBelongToCountry(nationalNumber, country, metadata);\n });\n}\nfunction couldNationalNumberBelongToCountry(nationalNumber, country, metadata) {\n var _metadata = new Metadata(metadata);\n _metadata.selectNumberingPlan(country);\n if (_metadata.numberingPlan.possibleLengths().indexOf(nationalNumber.length) >= 0) {\n return true;\n }\n return false;\n}\n//# sourceMappingURL=getPossibleCountriesForNumber.js.map","function _createForOfIteratorHelperLoose(r, e) { var t = \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (t) return (t = t.call(r)).next.bind(t); if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && \"number\" == typeof r.length) { t && (r = t); var o = 0; return function () { return o >= r.length ? { done: !0 } : { done: !1, value: r[o++] }; }; } throw new TypeError(\"Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\n/**\r\n * Merges two arrays.\r\n * @param {*} a\r\n * @param {*} b\r\n * @return {*}\r\n */\nexport default function mergeArrays(a, b) {\n var merged = a.slice();\n for (var _iterator = _createForOfIteratorHelperLoose(b), _step; !(_step = _iterator()).done;) {\n var element = _step.value;\n if (a.indexOf(element) < 0) {\n merged.push(element);\n }\n }\n return merged.sort(function (a, b) {\n return a - b;\n });\n\n // ES6 version, requires Set polyfill.\n // let merged = new Set(a)\n // for (const element of b) {\n // \tmerged.add(i)\n // }\n // return Array.from(merged).sort((a, b) => a - b)\n}\n//# sourceMappingURL=mergeArrays.js.map","function _createForOfIteratorHelperLoose(r, e) { var t = \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (t) return (t = t.call(r)).next.bind(t); if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && \"number\" == typeof r.length) { t && (r = t); var o = 0; return function () { return o >= r.length ? { done: !0 } : { done: !1, value: r[o++] }; }; } throw new TypeError(\"Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\n// These mappings map a character (key) to a specific digit that should\n// replace it for normalization purposes. Non-European digits that\n// may be used in phone numbers are mapped to a European equivalent.\n//\n// E.g. in Iraq they don't write `+442323234` but rather `+٤٤٢٣٢٣٢٣٤`.\n//\nexport var DIGITS = {\n '0': '0',\n '1': '1',\n '2': '2',\n '3': '3',\n '4': '4',\n '5': '5',\n '6': '6',\n '7': '7',\n '8': '8',\n '9': '9',\n \"\\uFF10\": '0',\n // Fullwidth digit 0\n \"\\uFF11\": '1',\n // Fullwidth digit 1\n \"\\uFF12\": '2',\n // Fullwidth digit 2\n \"\\uFF13\": '3',\n // Fullwidth digit 3\n \"\\uFF14\": '4',\n // Fullwidth digit 4\n \"\\uFF15\": '5',\n // Fullwidth digit 5\n \"\\uFF16\": '6',\n // Fullwidth digit 6\n \"\\uFF17\": '7',\n // Fullwidth digit 7\n \"\\uFF18\": '8',\n // Fullwidth digit 8\n \"\\uFF19\": '9',\n // Fullwidth digit 9\n \"\\u0660\": '0',\n // Arabic-indic digit 0\n \"\\u0661\": '1',\n // Arabic-indic digit 1\n \"\\u0662\": '2',\n // Arabic-indic digit 2\n \"\\u0663\": '3',\n // Arabic-indic digit 3\n \"\\u0664\": '4',\n // Arabic-indic digit 4\n \"\\u0665\": '5',\n // Arabic-indic digit 5\n \"\\u0666\": '6',\n // Arabic-indic digit 6\n \"\\u0667\": '7',\n // Arabic-indic digit 7\n \"\\u0668\": '8',\n // Arabic-indic digit 8\n \"\\u0669\": '9',\n // Arabic-indic digit 9\n \"\\u06F0\": '0',\n // Eastern-Arabic digit 0\n \"\\u06F1\": '1',\n // Eastern-Arabic digit 1\n \"\\u06F2\": '2',\n // Eastern-Arabic digit 2\n \"\\u06F3\": '3',\n // Eastern-Arabic digit 3\n \"\\u06F4\": '4',\n // Eastern-Arabic digit 4\n \"\\u06F5\": '5',\n // Eastern-Arabic digit 5\n \"\\u06F6\": '6',\n // Eastern-Arabic digit 6\n \"\\u06F7\": '7',\n // Eastern-Arabic digit 7\n \"\\u06F8\": '8',\n // Eastern-Arabic digit 8\n \"\\u06F9\": '9' // Eastern-Arabic digit 9\n};\nexport function parseDigit(character) {\n return DIGITS[character];\n}\n\n/**\r\n * Parses phone number digits from a string.\r\n * Drops all punctuation leaving only digits.\r\n * Also converts wide-ascii and arabic-indic numerals to conventional numerals.\r\n * E.g. in Iraq they don't write `+442323234` but rather `+٤٤٢٣٢٣٢٣٤`.\r\n * @param {string} string\r\n * @return {string}\r\n * @example\r\n * ```js\r\n * parseDigits('8 (800) 555')\r\n * // Outputs '8800555'.\r\n * ```\r\n */\nexport default function parseDigits(string) {\n var result = '';\n // Using `.split('')` here instead of normal `for ... of`\n // because the importing application doesn't neccessarily include an ES6 polyfill.\n // The `.split('')` approach discards \"exotic\" UTF-8 characters\n // (the ones consisting of four bytes) but digits\n // (including non-European ones) don't fall into that range\n // so such \"exotic\" characters would be discarded anyway.\n for (var _iterator = _createForOfIteratorHelperLoose(string.split('')), _step; !(_step = _iterator()).done;) {\n var character = _step.value;\n var digit = parseDigit(character);\n if (digit) {\n result += digit;\n }\n }\n return result;\n}\n//# sourceMappingURL=parseDigits.js.map","/**\r\n * Checks whether the entire input sequence can be matched\r\n * against the regular expression.\r\n * @return {boolean}\r\n */\nexport default function matchesEntirely(text, regular_expression) {\n // If assigning the `''` default value is moved to the arguments above,\n // code coverage would decrease for some weird reason.\n text = text || '';\n return new RegExp('^(?:' + regular_expression + ')$').test(text);\n}\n//# sourceMappingURL=matchesEntirely.js.map","function _createForOfIteratorHelperLoose(r, e) { var t = \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (t) return (t = t.call(r)).next.bind(t); if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && \"number\" == typeof r.length) { t && (r = t); var o = 0; return function () { return o >= r.length ? { done: !0 } : { done: !1, value: r[o++] }; }; } throw new TypeError(\"Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\nimport Metadata from '../metadata.js';\nimport getNumberType from './getNumberType.js';\nexport default function getCountryByNationalNumber(nationalPhoneNumber, _ref) {\n var countries = _ref.countries,\n defaultCountry = _ref.defaultCountry,\n metadata = _ref.metadata;\n // Re-create `metadata` because it will be selecting a `country`.\n metadata = new Metadata(metadata);\n\n // const matchingCountries = []\n\n for (var _iterator = _createForOfIteratorHelperLoose(countries), _step; !(_step = _iterator()).done;) {\n var country = _step.value;\n metadata.country(country);\n // \"Leading digits\" patterns are only defined for about 20% of all countries.\n // By definition, matching \"leading digits\" is a sufficient but not a necessary\n // condition for a phone number to belong to a country.\n // The point of \"leading digits\" check is that it's the fastest one to get a match.\n // https://gitlab.com/catamphetamine/libphonenumber-js/blob/master/METADATA.md#leading_digits\n // I'd suppose that \"leading digits\" patterns are mutually exclusive for different countries\n // because of the intended use of that feature.\n if (metadata.leadingDigits()) {\n if (nationalPhoneNumber && nationalPhoneNumber.search(metadata.leadingDigits()) === 0) {\n return country;\n }\n }\n // Else perform full validation with all of those\n // fixed-line/mobile/etc regular expressions.\n else if (getNumberType({\n phone: nationalPhoneNumber,\n country: country\n }, undefined, metadata.metadata)) {\n // If both the `defaultCountry` and the \"main\" one match the phone number,\n // don't prefer the `defaultCountry` over the \"main\" one.\n // https://gitlab.com/catamphetamine/libphonenumber-js/-/issues/154\n return country;\n // // If the `defaultCountry` is among the `matchingCountries` then return it.\n // if (defaultCountry) {\n // \tif (country === defaultCountry) {\n // \t\treturn country\n // \t}\n // \tmatchingCountries.push(country)\n // } else {\n // \treturn country\n // }\n }\n }\n\n // // Return the first (\"main\") one of the `matchingCountries`.\n // if (matchingCountries.length > 0) {\n // \treturn matchingCountries[0]\n // }\n}\n//# sourceMappingURL=getCountryByNationalNumber.js.map","import getCountryByNationalNumber from './getCountryByNationalNumber.js';\nvar USE_NON_GEOGRAPHIC_COUNTRY_CODE = false;\nexport default function getCountryByCallingCode(callingCode, _ref) {\n var nationalPhoneNumber = _ref.nationalNumber,\n defaultCountry = _ref.defaultCountry,\n metadata = _ref.metadata;\n /* istanbul ignore if */\n if (USE_NON_GEOGRAPHIC_COUNTRY_CODE) {\n if (metadata.isNonGeographicCallingCode(callingCode)) {\n return '001';\n }\n }\n var possibleCountries = metadata.getCountryCodesForCallingCode(callingCode);\n if (!possibleCountries) {\n return;\n }\n // If there's just one country corresponding to the country code,\n // then just return it, without further phone number digits validation.\n if (possibleCountries.length === 1) {\n return possibleCountries[0];\n }\n return getCountryByNationalNumber(nationalPhoneNumber, {\n countries: possibleCountries,\n defaultCountry: defaultCountry,\n metadata: metadata.metadata\n });\n}\n//# sourceMappingURL=getCountryByCallingCode.js.map","import Metadata from '../metadata.js';\nimport { VALID_DIGITS } from '../constants.js';\nvar CAPTURING_DIGIT_PATTERN = new RegExp('([' + VALID_DIGITS + '])');\nexport default function stripIddPrefix(number, country, callingCode, metadata) {\n if (!country) {\n return;\n }\n // Check if the number is IDD-prefixed.\n var countryMetadata = new Metadata(metadata);\n countryMetadata.selectNumberingPlan(country, callingCode);\n var IDDPrefixPattern = new RegExp(countryMetadata.IDDPrefix());\n if (number.search(IDDPrefixPattern) !== 0) {\n return;\n }\n // Strip IDD prefix.\n number = number.slice(number.match(IDDPrefixPattern)[0].length);\n // If there're any digits after an IDD prefix,\n // then those digits are a country calling code.\n // Since no country code starts with a `0`,\n // the code below validates that the next digit (if present) is not `0`.\n var matchedGroups = number.match(CAPTURING_DIGIT_PATTERN);\n if (matchedGroups && matchedGroups[1] != null && matchedGroups[1].length > 0) {\n if (matchedGroups[1] === '0') {\n return;\n }\n }\n return number;\n}\n//# sourceMappingURL=stripIddPrefix.js.map","import Metadata from '../metadata.js';\n\n/**\r\n * Pattern that makes it easy to distinguish whether a region has a single\r\n * international dialing prefix or not. If a region has a single international\r\n * prefix (e.g. 011 in USA), it will be represented as a string that contains\r\n * a sequence of ASCII digits, and possibly a tilde, which signals waiting for\r\n * the tone. If there are multiple available international prefixes in a\r\n * region, they will be represented as a regex string that always contains one\r\n * or more characters that are not ASCII digits or a tilde.\r\n */\nvar SINGLE_IDD_PREFIX_REG_EXP = /^[\\d]+(?:[~\\u2053\\u223C\\uFF5E][\\d]+)?$/;\n\n// For regions that have multiple IDD prefixes\n// a preferred IDD prefix is returned.\nexport default function getIddPrefix(country, callingCode, metadata) {\n var countryMetadata = new Metadata(metadata);\n countryMetadata.selectNumberingPlan(country, callingCode);\n if (countryMetadata.defaultIDDPrefix()) {\n return countryMetadata.defaultIDDPrefix();\n }\n if (SINGLE_IDD_PREFIX_REG_EXP.test(countryMetadata.IDDPrefix())) {\n return countryMetadata.IDDPrefix();\n }\n}\n//# sourceMappingURL=getIddPrefix.js.map","import { MIN_LENGTH_FOR_NSN, VALID_DIGITS, VALID_PUNCTUATION, PLUS_CHARS } from '../constants.js';\nimport createExtensionPattern from './extension/createExtensionPattern.js';\n\n// Regular expression of viable phone numbers. This is location independent.\n// Checks we have at least three leading digits, and only valid punctuation,\n// alpha characters and digits in the phone number. Does not include extension\n// data. The symbol 'x' is allowed here as valid punctuation since it is often\n// used as a placeholder for carrier codes, for example in Brazilian phone\n// numbers. We also allow multiple '+' characters at the start.\n//\n// Corresponds to the following:\n// [digits]{minLengthNsn}|\n// plus_sign*\n// (([punctuation]|[star])*[digits]){3,}([punctuation]|[star]|[digits]|[alpha])*\n//\n// The first reg-ex is to allow short numbers (two digits long) to be parsed if\n// they are entered as \"15\" etc, but only if there is no punctuation in them.\n// The second expression restricts the number of digits to three or more, but\n// then allows them to be in international form, and to have alpha-characters\n// and punctuation. We split up the two reg-exes here and combine them when\n// creating the reg-ex VALID_PHONE_NUMBER_PATTERN itself so we can prefix it\n// with ^ and append $ to each branch.\n//\n// \"Note VALID_PUNCTUATION starts with a -,\n// so must be the first in the range\" (c) Google devs.\n// (wtf did they mean by saying that; probably nothing)\n//\nvar MIN_LENGTH_PHONE_NUMBER_PATTERN = '[' + VALID_DIGITS + ']{' + MIN_LENGTH_FOR_NSN + '}';\n//\n// And this is the second reg-exp:\n// (see MIN_LENGTH_PHONE_NUMBER_PATTERN for a full description of this reg-exp)\n//\nexport var VALID_PHONE_NUMBER = '[' + PLUS_CHARS + ']{0,1}' + '(?:' + '[' + VALID_PUNCTUATION + ']*' + '[' + VALID_DIGITS + ']' + '){3,}' + '[' + VALID_PUNCTUATION + VALID_DIGITS + ']*';\n\n// This regular expression isn't present in Google's `libphonenumber`\n// and is only used to determine whether the phone number being input\n// is too short for it to even consider it a \"valid\" number.\n// This is just a way to differentiate between a really invalid phone\n// number like \"abcde\" and a valid phone number that a user has just\n// started inputting, like \"+1\" or \"1\": both these cases would be\n// considered `NOT_A_NUMBER` by Google's `libphonenumber`, but this\n// library can provide a more detailed error message — whether it's\n// really \"not a number\", or is it just a start of a valid phone number.\nvar VALID_PHONE_NUMBER_START_REG_EXP = new RegExp('^' + '[' + PLUS_CHARS + ']{0,1}' + '(?:' + '[' + VALID_PUNCTUATION + ']*' + '[' + VALID_DIGITS + ']' + '){1,2}' + '$', 'i');\nexport var VALID_PHONE_NUMBER_WITH_EXTENSION = VALID_PHONE_NUMBER +\n// Phone number extensions\n'(?:' + createExtensionPattern() + ')?';\n\n// The combined regular expression for valid phone numbers:\n//\nvar VALID_PHONE_NUMBER_PATTERN = new RegExp(\n// Either a short two-digit-only phone number\n'^' + MIN_LENGTH_PHONE_NUMBER_PATTERN + '$' + '|' +\n// Or a longer fully parsed phone number (min 3 characters)\n'^' + VALID_PHONE_NUMBER_WITH_EXTENSION + '$', 'i');\n\n// Checks to see if the string of characters could possibly be a phone number at\n// all. At the moment, checks to see that the string begins with at least 2\n// digits, ignoring any punctuation commonly found in phone numbers. This method\n// does not require the number to be normalized in advance - but does assume\n// that leading non-number symbols have been removed, such as by the method\n// `extract_possible_number`.\n//\nexport default function isViablePhoneNumber(number) {\n return number.length >= MIN_LENGTH_FOR_NSN && VALID_PHONE_NUMBER_PATTERN.test(number);\n}\n\n// This is just a way to differentiate between a really invalid phone\n// number like \"abcde\" and a valid phone number that a user has just\n// started inputting, like \"+1\" or \"1\": both these cases would be\n// considered `NOT_A_NUMBER` by Google's `libphonenumber`, but this\n// library can provide a more detailed error message — whether it's\n// really \"not a number\", or is it just a start of a valid phone number.\nexport function isViablePhoneNumberStart(number) {\n return VALID_PHONE_NUMBER_START_REG_EXP.test(number);\n}\n//# sourceMappingURL=isViablePhoneNumber.js.map","function _createForOfIteratorHelperLoose(r, e) { var t = \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (t) return (t = t.call(r)).next.bind(t); if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && \"number\" == typeof r.length) { t && (r = t); var o = 0; return function () { return o >= r.length ? { done: !0 } : { done: !1, value: r[o++] }; }; } throw new TypeError(\"Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\nimport Metadata from '../metadata.js';\nimport matchesEntirely from './matchesEntirely.js';\nvar NON_FIXED_LINE_PHONE_TYPES = ['MOBILE', 'PREMIUM_RATE', 'TOLL_FREE', 'SHARED_COST', 'VOIP', 'PERSONAL_NUMBER', 'PAGER', 'UAN', 'VOICEMAIL'];\n\n// Finds out national phone number type (fixed line, mobile, etc)\nexport default function getNumberType(input, options, metadata) {\n // If assigning the `{}` default value is moved to the arguments above,\n // code coverage would decrease for some weird reason.\n options = options || {};\n\n // When `parse()` returns an empty object — `{}` —\n // that means that the phone number is malformed,\n // so it can't possibly be valid.\n if (!input.country && !input.countryCallingCode) {\n return;\n }\n metadata = new Metadata(metadata);\n metadata.selectNumberingPlan(input.country, input.countryCallingCode);\n var nationalNumber = options.v2 ? input.nationalNumber : input.phone;\n\n // The following is copy-pasted from the original function:\n // https://github.com/googlei18n/libphonenumber/blob/3ea547d4fbaa2d0b67588904dfa5d3f2557c27ff/javascript/i18n/phonenumbers/phonenumberutil.js#L2835\n\n // Is this national number even valid for this country\n if (!matchesEntirely(nationalNumber, metadata.nationalNumberPattern())) {\n return;\n }\n\n // Is it fixed line number\n if (isNumberTypeEqualTo(nationalNumber, 'FIXED_LINE', metadata)) {\n // Because duplicate regular expressions are removed\n // to reduce metadata size, if \"mobile\" pattern is \"\"\n // then it means it was removed due to being a duplicate of the fixed-line pattern.\n //\n if (metadata.type('MOBILE') && metadata.type('MOBILE').pattern() === '') {\n return 'FIXED_LINE_OR_MOBILE';\n }\n\n // `MOBILE` type pattern isn't included if it matched `FIXED_LINE` one.\n // For example, for \"US\" country.\n // Old metadata (< `1.0.18`) had a specific \"types\" data structure\n // that happened to be `undefined` for `MOBILE` in that case.\n // Newer metadata (>= `1.0.18`) has another data structure that is\n // not `undefined` for `MOBILE` in that case (it's just an empty array).\n // So this `if` is just for backwards compatibility with old metadata.\n if (!metadata.type('MOBILE')) {\n return 'FIXED_LINE_OR_MOBILE';\n }\n\n // Check if the number happens to qualify as both fixed line and mobile.\n // (no such country in the minimal metadata set)\n /* istanbul ignore if */\n if (isNumberTypeEqualTo(nationalNumber, 'MOBILE', metadata)) {\n return 'FIXED_LINE_OR_MOBILE';\n }\n return 'FIXED_LINE';\n }\n for (var _iterator = _createForOfIteratorHelperLoose(NON_FIXED_LINE_PHONE_TYPES), _step; !(_step = _iterator()).done;) {\n var type = _step.value;\n if (isNumberTypeEqualTo(nationalNumber, type, metadata)) {\n return type;\n }\n }\n}\nexport function isNumberTypeEqualTo(nationalNumber, type, metadata) {\n type = metadata.type(type);\n if (!type || !type.pattern()) {\n return false;\n }\n // Check if any possible number lengths are present;\n // if so, we use them to avoid checking\n // the validation pattern if they don't match.\n // If they are absent, this means they match\n // the general description, which we have\n // already checked before a specific number type.\n if (type.possibleLengths() && type.possibleLengths().indexOf(nationalNumber.length) < 0) {\n return false;\n }\n return matchesEntirely(nationalNumber, type.pattern());\n}\n//# sourceMappingURL=getNumberType.js.map"],"names":["objectConstructor","constructor","isObject","object","getPossibleCountriesForNumber","callingCode","nationalNumber","metadata","possibleCountries","getCountryCodesForCallingCode","filter","country","_metadata","selectNumberingPlan","numberingPlan","possibleLengths","indexOf","length","couldNationalNumberBelongToCountry","_arrayLikeToArray","r","a","e","n","Array","mergeArrays","b","_step","merged","slice","_iterator","t","Symbol","iterator","call","next","bind","isArray","toString","name","from","test","_unsupportedIterableToArray","o","done","value","TypeError","_createForOfIteratorHelperLoose","element","push","sort","DIGITS","parseDigit","character","matchesEntirely","text","regular_expression","RegExp","USE_NON_GEOGRAPHIC_COUNTRY_CODE","getCountryByCallingCode","_ref","nationalPhoneNumber","defaultCountry","isNonGeographicCallingCode","countries","leadingDigits","search","getNumberType","phone","undefined","getCountryByNationalNumber","CAPTURING_DIGIT_PATTERN","stripIddPrefix","number","countryMetadata","IDDPrefixPattern","IDDPrefix","matchedGroups","match","SINGLE_IDD_PREFIX_REG_EXP","getIddPrefix","defaultIDDPrefix","MIN_LENGTH_PHONE_NUMBER_PATTERN","VALID_PHONE_NUMBER","VALID_PHONE_NUMBER_START_REG_EXP","VALID_PHONE_NUMBER_WITH_EXTENSION","VALID_PHONE_NUMBER_PATTERN","isViablePhoneNumber","isViablePhoneNumberStart","NON_FIXED_LINE_PHONE_TYPES","input","options","countryCallingCode","v2","nationalNumberPattern","isNumberTypeEqualTo","type","pattern"],"sourceRoot":""}