intl-tel-input 20.1.0 → 20.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +3 -1
- package/README.md +9 -5
- package/build/js/data.js +1 -2
- package/build/js/data.min.js +2 -3
- package/build/js/intlTelInput-jquery.js +1437 -1534
- package/build/js/intlTelInput-jquery.min.js +2 -4
- package/build/js/intlTelInput.js +1437 -1534
- package/build/js/intlTelInput.min.js +2 -4
- package/build/js/utils.js +19 -19
- package/package.json +13 -16
- package/react/README.md +33 -0
- package/react/build/IntlTelInput.cjs.js +1 -2
- package/react/build/IntlTelInput.cjs.js.map +3 -3
- package/react/build/IntlTelInput.esm.js +1 -2
- package/react/build/IntlTelInput.esm.js.map +3 -3
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../build/js/intlTelInput.js", "../src/IntlTelInput.js"],
|
|
4
|
-
"sourcesContent": ["/*\n * International Telephone Input v20.1.0\n * https://github.com/jackocnr/intl-tel-input.git\n * Licensed under the MIT license\n */\n\n// wrap in UMD\n(function(factory) {\n if (typeof module === \"object\" && module.exports) module.exports = factory(); else window.intlTelInput = factory();\n})(function(undefined) {\n \"use strict\";\n return function() {\n // Array of country objects for the flag dropdown.\n // Here is the criteria for the plugin to support a given country/territory\n // - It has an iso2 code: https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2\n // - It has it's own country calling code (it is not a sub-region of another country): https://en.wikipedia.org/wiki/List_of_country_calling_codes\n // - It has a flag in the region-flags project: https://github.com/behdad/region-flags/tree/gh-pages/png\n // - It is supported by libphonenumber (it must be listed on this page): https://github.com/googlei18n/libphonenumber/blob/master/resources/ShortNumberMetadata.xml\n // Each country array has the following information:\n // [\n // Country name,\n // iso2 code,\n // International dial code,\n // Order (if >1 country with same dial code),\n // Area codes\n // ]\n var allCountries = [ [ \"Afghanistan\", \"af\", \"93\" ], [ \"Albania\", \"al\", \"355\" ], [ \"Algeria\", \"dz\", \"213\" ], [ \"American Samoa\", \"as\", \"1\", 5, [ \"684\" ] ], [ \"Andorra\", \"ad\", \"376\" ], [ \"Angola\", \"ao\", \"244\" ], [ \"Anguilla\", \"ai\", \"1\", 6, [ \"264\" ] ], [ \"Antigua & Barbuda\", \"ag\", \"1\", 7, [ \"268\" ] ], [ \"Argentina\", \"ar\", \"54\" ], [ \"Armenia\", \"am\", \"374\" ], [ \"Aruba\", \"aw\", \"297\" ], [ \"Ascension Island\", \"ac\", \"247\" ], [ \"Australia\", \"au\", \"61\", 0 ], [ \"Austria\", \"at\", \"43\" ], [ \"Azerbaijan\", \"az\", \"994\" ], [ \"Bahamas\", \"bs\", \"1\", 8, [ \"242\" ] ], [ \"Bahrain\", \"bh\", \"973\" ], [ \"Bangladesh\", \"bd\", \"880\" ], [ \"Barbados\", \"bb\", \"1\", 9, [ \"246\" ] ], [ \"Belarus\", \"by\", \"375\" ], [ \"Belgium\", \"be\", \"32\" ], [ \"Belize\", \"bz\", \"501\" ], [ \"Benin\", \"bj\", \"229\" ], [ \"Bermuda\", \"bm\", \"1\", 10, [ \"441\" ] ], [ \"Bhutan\", \"bt\", \"975\" ], [ \"Bolivia\", \"bo\", \"591\" ], [ \"Bosnia & Herzegovina\", \"ba\", \"387\" ], [ \"Botswana\", \"bw\", \"267\" ], [ \"Brazil\", \"br\", \"55\" ], [ \"British Indian Ocean Territory\", \"io\", \"246\" ], [ \"British Virgin Islands\", \"vg\", \"1\", 11, [ \"284\" ] ], [ \"Brunei\", \"bn\", \"673\" ], [ \"Bulgaria\", \"bg\", \"359\" ], [ \"Burkina Faso\", \"bf\", \"226\" ], [ \"Burundi\", \"bi\", \"257\" ], [ \"Cambodia\", \"kh\", \"855\" ], [ \"Cameroon\", \"cm\", \"237\" ], [ \"Canada\", \"ca\", \"1\", 1, [ \"204\", \"226\", \"236\", \"249\", \"250\", \"263\", \"289\", \"306\", \"343\", \"354\", \"365\", \"367\", \"368\", \"382\", \"387\", \"403\", \"416\", \"418\", \"428\", \"431\", \"437\", \"438\", \"450\", \"584\", \"468\", \"474\", \"506\", \"514\", \"519\", \"548\", \"579\", \"581\", \"584\", \"587\", \"604\", \"613\", \"639\", \"647\", \"672\", \"683\", \"705\", \"709\", \"742\", \"753\", \"778\", \"780\", \"782\", \"807\", \"819\", \"825\", \"867\", \"873\", \"902\", \"905\" ] ], [ \"Cape Verde\", \"cv\", \"238\" ], [ \"Caribbean Netherlands\", \"bq\", \"599\", 1, [ \"3\", \"4\", \"7\" ] ], [ \"Cayman Islands\", \"ky\", \"1\", 12, [ \"345\" ] ], [ \"Central African Republic\", \"cf\", \"236\" ], [ \"Chad\", \"td\", \"235\" ], [ \"Chile\", \"cl\", \"56\" ], [ \"China\", \"cn\", \"86\" ], [ \"Christmas Island\", \"cx\", \"61\", 2, [ \"89164\" ] ], [ \"Cocos (Keeling) Islands\", \"cc\", \"61\", 1, [ \"89162\" ] ], [ \"Colombia\", \"co\", \"57\" ], [ \"Comoros\", \"km\", \"269\" ], [ \"Congo - Brazzaville\", \"cg\", \"242\" ], [ \"Congo - Kinshasa\", \"cd\", \"243\" ], [ \"Cook Islands\", \"ck\", \"682\" ], [ \"Costa Rica\", \"cr\", \"506\" ], [ \"C\u00F4te d\u2019Ivoire\", \"ci\", \"225\" ], [ \"Croatia\", \"hr\", \"385\" ], [ \"Cuba\", \"cu\", \"53\" ], [ \"Cura\u00E7ao\", \"cw\", \"599\", 0 ], [ \"Cyprus\", \"cy\", \"357\" ], [ \"Czech Republic\", \"cz\", \"420\" ], [ \"Denmark\", \"dk\", \"45\" ], [ \"Djibouti\", \"dj\", \"253\" ], [ \"Dominica\", \"dm\", \"1\", 13, [ \"767\" ] ], [ \"Dominican Republic\", \"do\", \"1\", 2, [ \"809\", \"829\", \"849\" ] ], [ \"Ecuador\", \"ec\", \"593\" ], [ \"Egypt\", \"eg\", \"20\" ], [ \"El Salvador\", \"sv\", \"503\" ], [ \"Equatorial Guinea\", \"gq\", \"240\" ], [ \"Eritrea\", \"er\", \"291\" ], [ \"Estonia\", \"ee\", \"372\" ], [ \"Eswatini\", \"sz\", \"268\" ], [ \"Ethiopia\", \"et\", \"251\" ], [ \"Falkland Islands\", \"fk\", \"500\" ], [ \"Faroe Islands\", \"fo\", \"298\" ], [ \"Fiji\", \"fj\", \"679\" ], [ \"Finland\", \"fi\", \"358\", 0 ], [ \"France\", \"fr\", \"33\" ], [ \"French Guiana\", \"gf\", \"594\" ], [ \"French Polynesia\", \"pf\", \"689\" ], [ \"Gabon\", \"ga\", \"241\" ], [ \"Gambia\", \"gm\", \"220\" ], [ \"Georgia\", \"ge\", \"995\" ], [ \"Germany\", \"de\", \"49\" ], [ \"Ghana\", \"gh\", \"233\" ], [ \"Gibraltar\", \"gi\", \"350\" ], [ \"Greece\", \"gr\", \"30\" ], [ \"Greenland\", \"gl\", \"299\" ], [ \"Grenada\", \"gd\", \"1\", 14, [ \"473\" ] ], [ \"Guadeloupe\", \"gp\", \"590\", 0 ], [ \"Guam\", \"gu\", \"1\", 15, [ \"671\" ] ], [ \"Guatemala\", \"gt\", \"502\" ], [ \"Guernsey\", \"gg\", \"44\", 1, [ \"1481\", \"7781\", \"7839\", \"7911\" ] ], [ \"Guinea\", \"gn\", \"224\" ], [ \"Guinea-Bissau\", \"gw\", \"245\" ], [ \"Guyana\", \"gy\", \"592\" ], [ \"Haiti\", \"ht\", \"509\" ], [ \"Honduras\", \"hn\", \"504\" ], [ \"Hong Kong\", \"hk\", \"852\" ], [ \"Hungary\", \"hu\", \"36\" ], [ \"Iceland\", \"is\", \"354\" ], [ \"India\", \"in\", \"91\" ], [ \"Indonesia\", \"id\", \"62\" ], [ \"Iran\", \"ir\", \"98\" ], [ \"Iraq\", \"iq\", \"964\" ], [ \"Ireland\", \"ie\", \"353\" ], [ \"Isle of Man\", \"im\", \"44\", 2, [ \"1624\", \"74576\", \"7524\", \"7924\", \"7624\" ] ], [ \"Israel\", \"il\", \"972\" ], [ \"Italy\", \"it\", \"39\", 0 ], [ \"Jamaica\", \"jm\", \"1\", 4, [ \"876\", \"658\" ] ], [ \"Japan\", \"jp\", \"81\" ], [ \"Jersey\", \"je\", \"44\", 3, [ \"1534\", \"7509\", \"7700\", \"7797\", \"7829\", \"7937\" ] ], [ \"Jordan\", \"jo\", \"962\" ], [ \"Kazakhstan\", \"kz\", \"7\", 1, [ \"33\", \"7\" ] ], [ \"Kenya\", \"ke\", \"254\" ], [ \"Kiribati\", \"ki\", \"686\" ], [ \"Kosovo\", \"xk\", \"383\" ], [ \"Kuwait\", \"kw\", \"965\" ], [ \"Kyrgyzstan\", \"kg\", \"996\" ], [ \"Laos\", \"la\", \"856\" ], [ \"Latvia\", \"lv\", \"371\" ], [ \"Lebanon\", \"lb\", \"961\" ], [ \"Lesotho\", \"ls\", \"266\" ], [ \"Liberia\", \"lr\", \"231\" ], [ \"Libya\", \"ly\", \"218\" ], [ \"Liechtenstein\", \"li\", \"423\" ], [ \"Lithuania\", \"lt\", \"370\" ], [ \"Luxembourg\", \"lu\", \"352\" ], [ \"Macau\", \"mo\", \"853\" ], [ \"Madagascar\", \"mg\", \"261\" ], [ \"Malawi\", \"mw\", \"265\" ], [ \"Malaysia\", \"my\", \"60\" ], [ \"Maldives\", \"mv\", \"960\" ], [ \"Mali\", \"ml\", \"223\" ], [ \"Malta\", \"mt\", \"356\" ], [ \"Marshall Islands\", \"mh\", \"692\" ], [ \"Martinique\", \"mq\", \"596\" ], [ \"Mauritania\", \"mr\", \"222\" ], [ \"Mauritius\", \"mu\", \"230\" ], [ \"Mayotte\", \"yt\", \"262\", 1, [ \"269\", \"639\" ] ], [ \"Mexico\", \"mx\", \"52\" ], [ \"Micronesia\", \"fm\", \"691\" ], [ \"Moldova\", \"md\", \"373\" ], [ \"Monaco\", \"mc\", \"377\" ], [ \"Mongolia\", \"mn\", \"976\" ], [ \"Montenegro\", \"me\", \"382\" ], [ \"Montserrat\", \"ms\", \"1\", 16, [ \"664\" ] ], [ \"Morocco\", \"ma\", \"212\", 0 ], [ \"Mozambique\", \"mz\", \"258\" ], [ \"Myanmar (Burma)\", \"mm\", \"95\" ], [ \"Namibia\", \"na\", \"264\" ], [ \"Nauru\", \"nr\", \"674\" ], [ \"Nepal\", \"np\", \"977\" ], [ \"Netherlands\", \"nl\", \"31\" ], [ \"New Caledonia\", \"nc\", \"687\" ], [ \"New Zealand\", \"nz\", \"64\" ], [ \"Nicaragua\", \"ni\", \"505\" ], [ \"Niger\", \"ne\", \"227\" ], [ \"Nigeria\", \"ng\", \"234\" ], [ \"Niue\", \"nu\", \"683\" ], [ \"Norfolk Island\", \"nf\", \"672\" ], [ \"North Korea\", \"kp\", \"850\" ], [ \"North Macedonia\", \"mk\", \"389\" ], [ \"Northern Mariana Islands\", \"mp\", \"1\", 17, [ \"670\" ] ], [ \"Norway\", \"no\", \"47\", 0 ], [ \"Oman\", \"om\", \"968\" ], [ \"Pakistan\", \"pk\", \"92\" ], [ \"Palau\", \"pw\", \"680\" ], [ \"Palestine\", \"ps\", \"970\" ], [ \"Panama\", \"pa\", \"507\" ], [ \"Papua New Guinea\", \"pg\", \"675\" ], [ \"Paraguay\", \"py\", \"595\" ], [ \"Peru\", \"pe\", \"51\" ], [ \"Philippines\", \"ph\", \"63\" ], [ \"Poland\", \"pl\", \"48\" ], [ \"Portugal\", \"pt\", \"351\" ], [ \"Puerto Rico\", \"pr\", \"1\", 3, [ \"787\", \"939\" ] ], [ \"Qatar\", \"qa\", \"974\" ], [ \"R\u00E9union\", \"re\", \"262\", 0 ], [ \"Romania\", \"ro\", \"40\" ], [ \"Russia\", \"ru\", \"7\", 0 ], [ \"Rwanda\", \"rw\", \"250\" ], [ \"Samoa\", \"ws\", \"685\" ], [ \"San Marino\", \"sm\", \"378\" ], [ \"S\u00E3o Tom\u00E9 & Pr\u00EDncipe\", \"st\", \"239\" ], [ \"Saudi Arabia\", \"sa\", \"966\" ], [ \"Senegal\", \"sn\", \"221\" ], [ \"Serbia\", \"rs\", \"381\" ], [ \"Seychelles\", \"sc\", \"248\" ], [ \"Sierra Leone\", \"sl\", \"232\" ], [ \"Singapore\", \"sg\", \"65\" ], [ \"Sint Maarten\", \"sx\", \"1\", 21, [ \"721\" ] ], [ \"Slovakia\", \"sk\", \"421\" ], [ \"Slovenia\", \"si\", \"386\" ], [ \"Solomon Islands\", \"sb\", \"677\" ], [ \"Somalia\", \"so\", \"252\" ], [ \"South Africa\", \"za\", \"27\" ], [ \"South Korea\", \"kr\", \"82\" ], [ \"South Sudan\", \"ss\", \"211\" ], [ \"Spain\", \"es\", \"34\" ], [ \"Sri Lanka\", \"lk\", \"94\" ], [ \"St Barth\u00E9lemy\", \"bl\", \"590\", 1 ], [ \"St Helena\", \"sh\", \"290\" ], [ \"St Kitts & Nevis\", \"kn\", \"1\", 18, [ \"869\" ] ], [ \"St Lucia\", \"lc\", \"1\", 19, [ \"758\" ] ], [ \"St Martin\", \"mf\", \"590\", 2 ], [ \"St Pierre & Miquelon\", \"pm\", \"508\" ], [ \"St Vincent & Grenadines\", \"vc\", \"1\", 20, [ \"784\" ] ], [ \"Sudan\", \"sd\", \"249\" ], [ \"Suriname\", \"sr\", \"597\" ], [ \"Svalbard & Jan Mayen\", \"sj\", \"47\", 1, [ \"79\" ] ], [ \"Sweden\", \"se\", \"46\" ], [ \"Switzerland\", \"ch\", \"41\" ], [ \"Syria\", \"sy\", \"963\" ], [ \"Taiwan\", \"tw\", \"886\" ], [ \"Tajikistan\", \"tj\", \"992\" ], [ \"Tanzania\", \"tz\", \"255\" ], [ \"Thailand\", \"th\", \"66\" ], [ \"Timor-Leste\", \"tl\", \"670\" ], [ \"Togo\", \"tg\", \"228\" ], [ \"Tokelau\", \"tk\", \"690\" ], [ \"Tonga\", \"to\", \"676\" ], [ \"Trinidad & Tobago\", \"tt\", \"1\", 22, [ \"868\" ] ], [ \"Tunisia\", \"tn\", \"216\" ], [ \"Turkey\", \"tr\", \"90\" ], [ \"Turkmenistan\", \"tm\", \"993\" ], [ \"Turks & Caicos Islands\", \"tc\", \"1\", 23, [ \"649\" ] ], [ \"Tuvalu\", \"tv\", \"688\" ], [ \"Uganda\", \"ug\", \"256\" ], [ \"Ukraine\", \"ua\", \"380\" ], [ \"United Arab Emirates\", \"ae\", \"971\" ], [ \"United Kingdom\", \"gb\", \"44\", 0 ], [ \"United States\", \"us\", \"1\", 0 ], [ \"Uruguay\", \"uy\", \"598\" ], [ \"US Virgin Islands\", \"vi\", \"1\", 24, [ \"340\" ] ], [ \"Uzbekistan\", \"uz\", \"998\" ], [ \"Vanuatu\", \"vu\", \"678\" ], [ \"Vatican City\", \"va\", \"39\", 1, [ \"06698\" ] ], [ \"Venezuela\", \"ve\", \"58\" ], [ \"Vietnam\", \"vn\", \"84\" ], [ \"Wallis & Futuna\", \"wf\", \"681\" ], [ \"Western Sahara\", \"eh\", \"212\", 1, [ \"5288\", \"5289\" ] ], [ \"Yemen\", \"ye\", \"967\" ], [ \"Zambia\", \"zm\", \"260\" ], [ \"Zimbabwe\", \"zw\", \"263\" ], [ \"\u00C5land Islands\", \"ax\", \"358\", 1, [ \"18\" ] ] ];\n // loop over all of the countries above, restructuring the data to be objects with named keys\n for (var i = 0; i < allCountries.length; i++) {\n var c = allCountries[i];\n allCountries[i] = {\n name: c[0],\n iso2: c[1],\n dialCode: c[2],\n priority: c[3] || 0,\n areaCodes: c[4] || null,\n nodeById: {}\n };\n }\n \"use strict\";\n function ownKeys(object, enumerableOnly) {\n var keys = Object.keys(object);\n if (Object.getOwnPropertySymbols) {\n var symbols = Object.getOwnPropertySymbols(object);\n enumerableOnly && (symbols = symbols.filter(function(sym) {\n return Object.getOwnPropertyDescriptor(object, sym).enumerable;\n })), keys.push.apply(keys, symbols);\n }\n return keys;\n }\n function _objectSpread(target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = null != arguments[i] ? arguments[i] : {};\n i % 2 ? ownKeys(Object(source), !0).forEach(function(key) {\n _defineProperty(target, key, source[key]);\n }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function(key) {\n Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));\n });\n }\n return target;\n }\n function _defineProperty(obj, key, value) {\n key = _toPropertyKey(key);\n if (key in obj) {\n Object.defineProperty(obj, key, {\n value: value,\n enumerable: true,\n configurable: true,\n writable: true\n });\n } else {\n obj[key] = value;\n }\n return obj;\n }\n function _slicedToArray(arr, i) {\n return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest();\n }\n function _nonIterableRest() {\n throw new TypeError(\"Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\");\n }\n function _unsupportedIterableToArray(o, minLen) {\n if (!o) return;\n if (typeof o === \"string\") return _arrayLikeToArray(o, minLen);\n var n = Object.prototype.toString.call(o).slice(8, -1);\n if (n === \"Object\" && o.constructor) n = o.constructor.name;\n if (n === \"Map\" || n === \"Set\") return Array.from(o);\n if (n === \"Arguments\" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen);\n }\n function _arrayLikeToArray(arr, len) {\n if (len == null || len > arr.length) len = arr.length;\n for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i];\n return arr2;\n }\n function _iterableToArrayLimit(arr, i) {\n var _i = null == arr ? null : \"undefined\" != typeof Symbol && arr[Symbol.iterator] || arr[\"@@iterator\"];\n if (null != _i) {\n var _s, _e, _x, _r, _arr = [], _n = !0, _d = !1;\n try {\n if (_x = (_i = _i.call(arr)).next, 0 === i) {\n if (Object(_i) !== _i) return;\n _n = !1;\n } else for (;!(_n = (_s = _x.call(_i)).done) && (_arr.push(_s.value), _arr.length !== i); _n = !0) ;\n } catch (err) {\n _d = !0, _e = err;\n } finally {\n try {\n if (!_n && null != _i[\"return\"] && (_r = _i[\"return\"](), Object(_r) !== _r)) return;\n } finally {\n if (_d) throw _e;\n }\n }\n return _arr;\n }\n }\n function _arrayWithHoles(arr) {\n if (Array.isArray(arr)) return arr;\n }\n function _classCallCheck(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n }\n function _defineProperties(target, props) {\n for (var i = 0; i < props.length; i++) {\n var descriptor = props[i];\n descriptor.enumerable = descriptor.enumerable || false;\n descriptor.configurable = true;\n if (\"value\" in descriptor) descriptor.writable = true;\n Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor);\n }\n }\n function _createClass(Constructor, protoProps, staticProps) {\n if (protoProps) _defineProperties(Constructor.prototype, protoProps);\n if (staticProps) _defineProperties(Constructor, staticProps);\n Object.defineProperty(Constructor, \"prototype\", {\n writable: false\n });\n return Constructor;\n }\n function _toPropertyKey(arg) {\n var key = _toPrimitive(arg, \"string\");\n return typeof key === \"symbol\" ? key : String(key);\n }\n function _toPrimitive(input, hint) {\n if (typeof input !== \"object\" || input === null) return input;\n var prim = input[Symbol.toPrimitive];\n if (prim !== undefined) {\n var res = prim.call(input, hint || \"default\");\n if (typeof res !== \"object\") return res;\n throw new TypeError(\"@@toPrimitive must return a primitive value.\");\n }\n return (hint === \"string\" ? String : Number)(input);\n }\n var intlTelInputGlobals = {\n getInstance: function getInstance(input) {\n var id = input.getAttribute(\"data-intl-tel-input-id\");\n return window.intlTelInputGlobals.instances[id];\n },\n instances: {},\n // using a global like this allows us to mock it in the tests\n documentReady: function documentReady() {\n return document.readyState === \"complete\";\n }\n };\n if (typeof window === \"object\") {\n window.intlTelInputGlobals = intlTelInputGlobals;\n }\n // these vars persist through all instances of the plugin\n var id = 0;\n var defaults = {\n // whether or not to allow the dropdown\n allowDropdown: true,\n // add a placeholder in the input with an example number for the selected country\n autoPlaceholder: \"polite\",\n // add a country search input at the top of the dropdown\n countrySearch: true,\n // modify the parentClass\n containerClass: \"\",\n // modify the auto placeholder\n customPlaceholder: null,\n // append menu to specified element\n dropdownContainer: null,\n // don't display these countries\n excludeCountries: [],\n // fix the dropdown width to the input width (rather than being as wide as the longest country name)\n fixDropdownWidth: true,\n // format the number as the user types\n formatAsYouType: true,\n // format the input value during initialisation and on setNumber\n formatOnDisplay: true,\n // geoIp lookup function\n geoIpLookup: null,\n // inject a hidden input with the name returned from this function, and on submit, populate it with the result of getNumber\n hiddenInput: null,\n // internationalise the plugin text e.g. search input placeholder, country names\n i18n: {},\n // initial country\n initialCountry: \"\",\n // national vs international formatting for numbers e.g. placeholders and displaying existing numbers\n nationalMode: true,\n // display only these countries\n onlyCountries: [],\n // number type to use for placeholders\n placeholderNumberType: \"MOBILE\",\n // the countries at the top of the list\n preferredCountries: [],\n // option to hide the flags - must be used with showSelectedDialCode, or allowDropdown=false\n showFlags: true,\n // display the international dial code next to the selected flag\n showSelectedDialCode: false,\n // use full screen popup instead of dropdown for country list\n useFullscreenPopup: typeof navigator !== \"undefined\" && typeof window !== \"undefined\" ? // we cannot just test screen size as some smartphones/website meta tags will report desktop\n // resolutions\n // Note: to target Android Mobiles (and not Tablets), we must find 'Android' and 'Mobile'\n /Android.+Mobile|webOS|iPhone|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent) || window.innerWidth <= 500 : false,\n // specify the path to the libphonenumber script to enable validation/formatting\n utilsScript: \"\"\n };\n // https://en.wikipedia.org/wiki/List_of_North_American_Numbering_Plan_area_codes#Non-geographic_area_codes\n var regionlessNanpNumbers = [ \"800\", \"822\", \"833\", \"844\", \"855\", \"866\", \"877\", \"880\", \"881\", \"882\", \"883\", \"884\", \"885\", \"886\", \"887\", \"888\", \"889\" ];\n // run a method on each instance of the plugin\n var forEachInstance = function forEachInstance(method) {\n var instances = window.intlTelInputGlobals.instances;\n Object.values(instances).forEach(function(instance) {\n return instance[method]();\n });\n };\n // this is our plugin class that we will create an instance of\n // eslint-disable-next-line no-unused-vars\n var Iti = /*#__PURE__*/ function() {\n function Iti(input) {\n var customOptions = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n _classCallCheck(this, Iti);\n this.id = id++;\n this.telInput = input;\n this.activeItem = null;\n this.highlightedItem = null;\n // process specified options / defaults\n this.options = Object.assign({}, defaults, customOptions);\n this.hadInitialPlaceholder = Boolean(input.getAttribute(\"placeholder\"));\n }\n _createClass(Iti, [ {\n key: \"_init\",\n value: function _init() {\n var _this = this;\n // if showing fullscreen popup, do not fix the width\n if (this.options.useFullscreenPopup) {\n this.options.fixDropdownWidth = false;\n }\n // when search enabled, we must fix the width else it would change with different results\n if (this.options.countrySearch && !this.options.useFullscreenPopup) {\n this.options.fixDropdownWidth = true;\n }\n // force showFlags=true if there's a dropdown and we're not displaying the dial code,\n // as otherwise you just have a down arrow on it's own which doesn't make sense\n var forceShowFlags = this.options.allowDropdown && !this.options.showSelectedDialCode;\n if (!this.options.showFlags && forceShowFlags) {\n this.options.showFlags = true;\n }\n // on mobile, we want a full screen dropdown, so we must append it to the body\n if (this.options.useFullscreenPopup && !this.options.dropdownContainer) {\n this.options.dropdownContainer = document.body;\n }\n // check if input has one parent with RTL\n this.isRTL = !!this.telInput.closest(\"[dir=rtl]\");\n // these promises get resolved when their individual requests complete\n // this way the dev can do something like iti.promise.then(...) to know when all requests are\n // complete\n var autoCountryPromise = new Promise(function(resolve, reject) {\n _this.resolveAutoCountryPromise = resolve;\n _this.rejectAutoCountryPromise = reject;\n });\n var utilsScriptPromise = new Promise(function(resolve, reject) {\n _this.resolveUtilsScriptPromise = resolve;\n _this.rejectUtilsScriptPromise = reject;\n });\n this.promise = Promise.all([ autoCountryPromise, utilsScriptPromise ]);\n // in various situations there could be no country selected initially, but we need to be able\n // to assume this variable exists\n this.selectedCountryData = {};\n // process all the data: onlyCountries, excludeCountries, preferredCountries etc\n this._processCountryData();\n // generate the markup\n this._generateMarkup();\n // set the initial state of the input value and the selected flag\n this._setInitialState();\n // start all of the event listeners: input keydown, selectedFlag click\n this._initListeners();\n // utils script, and auto country\n this._initRequests();\n }\n }, {\n key: \"_processCountryData\",\n value: function _processCountryData() {\n // process onlyCountries or excludeCountries array if present\n this._processAllCountries();\n // generate this.dialCodes and this.dialCodeToIso2Map\n this._processDialCodes();\n // process the preferredCountries\n this._processPreferredCountries();\n // translate country names according to i18n option\n this._translateCountryNames();\n // sort countries by name\n if (this.options.onlyCountries.length || this.options.i18n) {\n this.countries.sort(this._countryNameSort);\n }\n }\n }, {\n key: \"_addToDialCodeMap\",\n value: function _addToDialCodeMap(iso2, dialCode, priority) {\n if (dialCode.length > this.dialCodeMaxLen) {\n this.dialCodeMaxLen = dialCode.length;\n }\n if (!this.dialCodeToIso2Map.hasOwnProperty(dialCode)) {\n this.dialCodeToIso2Map[dialCode] = [];\n }\n // bail if we already have this country for this dialCode\n for (var i = 0; i < this.dialCodeToIso2Map[dialCode].length; i++) {\n if (this.dialCodeToIso2Map[dialCode][i] === iso2) {\n return;\n }\n }\n // check for undefined as 0 is falsy\n var index = priority !== undefined ? priority : this.dialCodeToIso2Map[dialCode].length;\n this.dialCodeToIso2Map[dialCode][index] = iso2;\n }\n }, {\n key: \"_processAllCountries\",\n value: function _processAllCountries() {\n if (this.options.onlyCountries.length) {\n var lowerCaseOnlyCountries = this.options.onlyCountries.map(function(country) {\n return country.toLowerCase();\n });\n this.countries = allCountries.filter(function(country) {\n return lowerCaseOnlyCountries.indexOf(country.iso2) > -1;\n });\n } else if (this.options.excludeCountries.length) {\n var lowerCaseExcludeCountries = this.options.excludeCountries.map(function(country) {\n return country.toLowerCase();\n });\n this.countries = allCountries.filter(function(country) {\n return lowerCaseExcludeCountries.indexOf(country.iso2) === -1;\n });\n } else {\n this.countries = allCountries;\n }\n }\n }, {\n key: \"_translateCountryNames\",\n value: function _translateCountryNames() {\n for (var i = 0; i < this.countries.length; i++) {\n var iso2 = this.countries[i].iso2.toLowerCase();\n if (this.options.i18n.hasOwnProperty(iso2)) {\n this.countries[i].name = this.options.i18n[iso2];\n }\n }\n }\n }, {\n key: \"_countryNameSort\",\n value: function _countryNameSort(a, b) {\n if (a.name < b.name) {\n return -1;\n }\n if (a.name > b.name) {\n return 1;\n }\n return 0;\n }\n }, {\n key: \"_processDialCodes\",\n value: function _processDialCodes() {\n // here we store just dial codes, where the key is the dial code, and the value is true\n // e.g. { 1: true, 7: true, 20: true, ... }\n this.dialCodes = {};\n this.dialCodeMaxLen = 0;\n // here we map dialCodes (inc both dialCode and dialCode+areaCode) to iso2 codes\n /* e.g.\n * {\n * 1: [ 'us', 'ca', ... ], # all NANP countries\n * 12: [ 'us', 'ca', ... ], # subset of NANP countries\n * 120: [ 'us', 'ca' ], # just US and Canada\n * 1204: [ 'ca' ], # only Canada\n * ...\n * }\n */\n this.dialCodeToIso2Map = {};\n // first: add dial codes\n for (var i = 0; i < this.countries.length; i++) {\n var c = this.countries[i];\n if (!this.dialCodes[c.dialCode]) {\n this.dialCodes[c.dialCode] = true;\n }\n this._addToDialCodeMap(c.iso2, c.dialCode, c.priority);\n }\n // next: add area codes\n // this is a second loop over countries, to make sure we have all of the \"root\" countries\n // already in the map, so that we can access them, as each time we add an area code substring\n // to the map, we also need to include the \"root\" country's code, as that also matches\n for (var _i = 0; _i < this.countries.length; _i++) {\n var _c = this.countries[_i];\n // area codes\n if (_c.areaCodes) {\n var rootIso2Code = this.dialCodeToIso2Map[_c.dialCode][0];\n // for each area code\n for (var j = 0; j < _c.areaCodes.length; j++) {\n var areaCode = _c.areaCodes[j];\n // for each digit in the area code to add all partial matches as well\n for (var k = 1; k < areaCode.length; k++) {\n var partialDialCode = _c.dialCode + areaCode.substr(0, k);\n // start with the root country, as that also matches this dial code\n this._addToDialCodeMap(rootIso2Code, partialDialCode);\n this._addToDialCodeMap(_c.iso2, partialDialCode);\n }\n // add the full area code\n this._addToDialCodeMap(_c.iso2, _c.dialCode + areaCode);\n }\n }\n }\n }\n }, {\n key: \"_processPreferredCountries\",\n value: function _processPreferredCountries() {\n this.preferredCountries = [];\n for (var i = 0; i < this.options.preferredCountries.length; i++) {\n var iso2 = this.options.preferredCountries[i].toLowerCase();\n var countryData = this._getCountryData(iso2, true);\n if (countryData) {\n this.preferredCountries.push(countryData);\n }\n }\n }\n }, {\n key: \"_createEl\",\n value: function _createEl(name, attrs, container) {\n var el = document.createElement(name);\n if (attrs) {\n Object.entries(attrs).forEach(function(_ref) {\n var _ref2 = _slicedToArray(_ref, 2), key = _ref2[0], value = _ref2[1];\n return el.setAttribute(key, value);\n });\n }\n if (container) {\n container.appendChild(el);\n }\n return el;\n }\n }, {\n key: \"_generateMarkup\",\n value: function _generateMarkup() {\n this.telInput.classList.add(\"iti__tel-input\");\n // if autocomplete does not exist on the element and its form, then\n // prevent autocomplete as there's no safe, cross-browser event we can react to, so it can\n // easily put the plugin in an inconsistent state e.g. the wrong flag selected for the\n // autocompleted number, which on submit could mean wrong number is saved\n if (!this.telInput.hasAttribute(\"autocomplete\") && !(this.telInput.form && this.telInput.form.hasAttribute(\"autocomplete\"))) {\n this.telInput.setAttribute(\"autocomplete\", \"off\");\n }\n var _this$options = this.options, allowDropdown = _this$options.allowDropdown, showSelectedDialCode = _this$options.showSelectedDialCode, showFlags = _this$options.showFlags, containerClass = _this$options.containerClass, hiddenInput = _this$options.hiddenInput, dropdownContainer = _this$options.dropdownContainer, fixDropdownWidth = _this$options.fixDropdownWidth, useFullscreenPopup = _this$options.useFullscreenPopup, countrySearch = _this$options.countrySearch, i18n = _this$options.i18n;\n // containers (mostly for positioning)\n var parentClass = \"iti\";\n if (allowDropdown) {\n parentClass += \" iti--allow-dropdown\";\n }\n if (showSelectedDialCode) {\n parentClass += \" iti--show-selected-dial-code\";\n }\n if (showFlags) {\n parentClass += \" iti--show-flags\";\n }\n if (containerClass) {\n parentClass += \" \".concat(containerClass);\n }\n if (!useFullscreenPopup) {\n parentClass += \" iti--inline-dropdown\";\n }\n var wrapper = this._createEl(\"div\", {\n \"class\": parentClass\n });\n this.telInput.parentNode.insertBefore(wrapper, this.telInput);\n // if we're showing flags or dial codes, we need the flags container etc\n if (showFlags || showSelectedDialCode) {\n this.flagsContainer = this._createEl(\"div\", {\n \"class\": \"iti__flag-container\"\n }, wrapper);\n // selected flag (displayed on left of input while allowDropdown is enabled, otherwise to right)\n // when countrySearch disabled: using Aria tags for \"Select-Only Combobox Example\"\n // https://www.w3.org/WAI/ARIA/apg/patterns/combobox/examples/combobox-select-only/\n this.selectedFlag = this._createEl(\"div\", _objectSpread({\n \"class\": \"iti__selected-flag\"\n }, allowDropdown && _objectSpread({\n role: \"button\",\n \"aria-expanded\": \"false\",\n \"aria-label\": this.options.i18n.selectedCountryAriaLabel || \"Selected country\",\n \"aria-haspopup\": countrySearch ? \"true\" : \"listbox\",\n \"aria-controls\": countrySearch ? \"iti-\".concat(this.id, \"__dropdown-content\") : \"iti-\".concat(this.id, \"__country-listbox\")\n }, countrySearch || {\n role: \"combobox\"\n })), this.flagsContainer);\n // we now include the selected flag element even when showFlags is disabled,\n // as need to show globe icon for showSelectedDialCode empty state\n this.selectedFlagInner = this._createEl(\"div\", null, this.selectedFlag);\n this.selectedFlagA11yText = this._createEl(\"span\", {\n \"class\": \"iti__a11y-text\"\n }, this.selectedFlagInner);\n }\n wrapper.appendChild(this.telInput);\n if (this.selectedFlag && this.telInput.disabled) {\n this.selectedFlag.setAttribute(\"aria-disabled\", \"true\");\n }\n if (showSelectedDialCode) {\n this.selectedDialCode = this._createEl(\"div\", {\n \"class\": \"iti__selected-dial-code\"\n }, this.selectedFlag);\n }\n if (allowDropdown) {\n if (!this.telInput.disabled) {\n // make element focusable and tab navigable\n this.selectedFlag.setAttribute(\"tabindex\", \"0\");\n }\n this.dropdownArrow = this._createEl(\"div\", {\n \"class\": \"iti__arrow\",\n \"aria-hidden\": \"true\"\n }, this.selectedFlag);\n var extraClasses = fixDropdownWidth ? \"\" : \"iti--flexible-dropdown-width\";\n this.dropdownContent = this._createEl(\"div\", {\n id: \"iti-\".concat(this.id, \"__dropdown-content\"),\n \"class\": \"iti__dropdown-content iti__hide \".concat(extraClasses)\n });\n if (countrySearch) {\n this.searchInput = this._createEl(\"input\", {\n type: \"text\",\n \"class\": \"iti__search-input\",\n placeholder: i18n.searchPlaceholder || \"Search\",\n role: \"combobox\",\n \"aria-expanded\": \"true\",\n \"aria-label\": i18n.searchPlaceholder || \"Search\",\n \"aria-controls\": \"iti-\".concat(this.id, \"__country-listbox\"),\n \"aria-autocomplete\": \"list\",\n autocomplete: \"off\"\n }, this.dropdownContent);\n this.searchResultsA11yText = this._createEl(\"span\", {\n \"class\": \"iti__a11y-text\"\n }, this.dropdownContent);\n }\n // country list: preferred countries, then divider, then all countries\n this.countryList = this._createEl(\"ul\", {\n \"class\": \"iti__country-list\",\n id: \"iti-\".concat(this.id, \"__country-listbox\"),\n role: \"listbox\",\n \"aria-label\": i18n.countryListAriaLabel || \"List of countries\"\n }, this.dropdownContent);\n if (this.preferredCountries.length && !countrySearch) {\n this._appendListItems(this.preferredCountries, \"iti__preferred\", true);\n this._createEl(\"li\", {\n \"class\": \"iti__divider\",\n \"aria-hidden\": \"true\"\n }, this.countryList);\n }\n this._appendListItems(this.countries, \"iti__standard\");\n if (countrySearch) {\n this._updateSearchResultsText();\n }\n // create dropdownContainer markup\n if (dropdownContainer) {\n var dropdownClasses = \"iti iti--container\";\n if (useFullscreenPopup) {\n dropdownClasses += \" iti--fullscreen-popup\";\n } else {\n dropdownClasses += \" iti--inline-dropdown\";\n }\n if (countrySearch) {\n dropdownClasses += \" iti--country-search\";\n }\n this.dropdown = this._createEl(\"div\", {\n \"class\": dropdownClasses\n });\n this.dropdown.appendChild(this.dropdownContent);\n } else {\n this.flagsContainer.appendChild(this.dropdownContent);\n }\n }\n if (hiddenInput) {\n var telInputName = this.telInput.getAttribute(\"name\");\n var names = hiddenInput(telInputName);\n if (names.phone) {\n // Create hidden input for the full international number\n this.hiddenInput = this._createEl(\"input\", {\n type: \"hidden\",\n name: names.phone\n });\n wrapper.appendChild(this.hiddenInput);\n }\n if (names.country) {\n // Create hidden input for the selected country iso2 code\n this.hiddenInputCountry = this._createEl(\"input\", {\n type: \"hidden\",\n name: names.country\n });\n wrapper.appendChild(this.hiddenInputCountry);\n }\n }\n }\n }, {\n key: \"_appendListItems\",\n value: function _appendListItems(countries, className, preferred) {\n for (var i = 0; i < countries.length; i++) {\n var c = countries[i];\n var idSuffix = preferred ? \"-preferred\" : \"\";\n var listItem = this._createEl(\"li\", {\n id: \"iti-\".concat(this.id, \"__item-\").concat(c.iso2).concat(idSuffix),\n \"class\": \"iti__country \".concat(className),\n tabindex: \"-1\",\n role: \"option\",\n \"data-dial-code\": c.dialCode,\n \"data-country-code\": c.iso2,\n \"aria-selected\": \"false\"\n }, this.countryList);\n // store this for later use e.g. country search filtering\n c.nodeById[this.id] = listItem;\n var content = \"\";\n // add the flag\n if (this.options.showFlags) {\n content += \"<div class='iti__flag-box'><div class='iti__flag iti__\".concat(c.iso2, \"'></div></div>\");\n }\n // and the country name and dial code\n content += \"<span class='iti__country-name'>\".concat(c.name, \"</span>\");\n content += \"<span class='iti__dial-code'>+\".concat(c.dialCode, \"</span>\");\n listItem.insertAdjacentHTML(\"beforeend\", content);\n }\n }\n }, {\n key: \"_setInitialState\",\n value: function _setInitialState() {\n var overrideAutoCountry = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;\n // fix firefox bug: when first load page (with input with value set to number with intl dial\n // code) and initialising plugin removes the dial code from the input, then refresh page,\n // and we try to init plugin again but this time on number without dial code so get grey flag\n var attributeValue = this.telInput.getAttribute(\"value\");\n var inputValue = this.telInput.value;\n var useAttribute = attributeValue && attributeValue.charAt(0) === \"+\" && (!inputValue || inputValue.charAt(0) !== \"+\");\n var val = useAttribute ? attributeValue : inputValue;\n var dialCode = this._getDialCode(val);\n var isRegionlessNanp = this._isRegionlessNanp(val);\n var initialCountry = this.options.initialCountry;\n // if we already have a dial code, and it's not a regionlessNanp, we can go ahead and set the\n // flag, else fall back to the default country\n if (dialCode && !isRegionlessNanp) {\n this._updateFlagFromNumber(val);\n } else if (initialCountry !== \"auto\" || overrideAutoCountry) {\n var lowerInitialCountry = initialCountry ? initialCountry.toLowerCase() : \"\";\n var isValidInitialCountry = lowerInitialCountry && this._getCountryData(lowerInitialCountry, true);\n // see if we should select a flag\n if (isValidInitialCountry) {\n this._setCountry(lowerInitialCountry);\n } else {\n if (dialCode && isRegionlessNanp) {\n // has intl dial code, is regionless nanp, and no initialCountry, so default to US\n this._setCountry(\"us\");\n } else {\n // display the empty state (globe icon)\n this._setCountry();\n }\n }\n }\n // NOTE: if initialCountry is set to auto, that will be handled separately\n // format - note this wont be run after _updateDialCode as that's only called if no val\n if (val) {\n this._updateValFromNumber(val);\n }\n }\n }, {\n key: \"_initListeners\",\n value: function _initListeners() {\n this._initKeyListeners();\n if (this.options.allowDropdown) {\n this._initDropdownListeners();\n }\n if ((this.hiddenInput || this.hiddenInputCountry) && this.telInput.form) {\n this._initHiddenInputListener();\n }\n }\n }, {\n key: \"_initHiddenInputListener\",\n value: function _initHiddenInputListener() {\n var _this2 = this;\n this._handleHiddenInputSubmit = function() {\n if (_this2.hiddenInput) {\n _this2.hiddenInput.value = _this2.getNumber();\n }\n if (_this2.hiddenInputCountry) {\n _this2.hiddenInputCountry.value = _this2.getSelectedCountryData().iso2;\n }\n };\n this.telInput.form.addEventListener(\"submit\", this._handleHiddenInputSubmit);\n }\n }, {\n key: \"_initDropdownListeners\",\n value: function _initDropdownListeners() {\n var _this3 = this;\n // hack for input nested inside label (which is valid markup): clicking the selected-flag to\n // open the dropdown would then automatically trigger a 2nd click on the input which would\n // close it again\n this._handleLabelClick = function(e) {\n // if the dropdown is closed, then focus the input, else ignore the click\n if (_this3.dropdownContent.classList.contains(\"iti__hide\")) {\n _this3.telInput.focus();\n } else {\n e.preventDefault();\n }\n };\n var label = this.telInput.closest(\"label\");\n if (label) {\n label.addEventListener(\"click\", this._handleLabelClick);\n }\n // toggle country dropdown on click\n this._handleClickSelectedFlag = function() {\n // only intercept this event if we're opening the dropdown\n // else let it bubble up to the top (\"click-off-to-close\" listener)\n // we cannot just stopPropagation as it may be needed to close another instance\n if (_this3.dropdownContent.classList.contains(\"iti__hide\") && !_this3.telInput.disabled && !_this3.telInput.readOnly) {\n _this3._openDropdown();\n }\n };\n this.selectedFlag.addEventListener(\"click\", this._handleClickSelectedFlag);\n // open dropdown if selected flag is focused and they press up/down/space/enter\n this._handleFlagsContainerKeydown = function(e) {\n var isDropdownHidden = _this3.dropdownContent.classList.contains(\"iti__hide\");\n if (isDropdownHidden && [ \"ArrowUp\", \"ArrowDown\", \" \", \"Enter\" ].includes(e.key)) {\n // prevent form from being submitted if \"ENTER\" was pressed\n e.preventDefault();\n // prevent event from being handled again by document\n e.stopPropagation();\n _this3._openDropdown();\n }\n // allow navigation from dropdown to input on TAB\n if (e.key === \"Tab\") {\n _this3._closeDropdown();\n }\n };\n this.flagsContainer.addEventListener(\"keydown\", this._handleFlagsContainerKeydown);\n }\n }, {\n key: \"_initRequests\",\n value: function _initRequests() {\n var _this4 = this;\n // if the user has specified the path to the utils script, fetch it on window.load, else resolve\n if (this.options.utilsScript && !window.intlTelInputUtils) {\n // if the plugin is being initialised after the window.load event has already been fired\n if (window.intlTelInputGlobals.documentReady()) {\n window.intlTelInputGlobals.loadUtils(this.options.utilsScript);\n } else {\n // wait until the load event so we don't block any other requests e.g. the flags image\n window.addEventListener(\"load\", function() {\n window.intlTelInputGlobals.loadUtils(_this4.options.utilsScript);\n });\n }\n } else {\n this.resolveUtilsScriptPromise();\n }\n // dont bother with IP lookup if we already have a selected country\n if (this.options.initialCountry === \"auto\" && !this.selectedCountryData.iso2) {\n this._loadAutoCountry();\n } else {\n this.resolveAutoCountryPromise();\n }\n }\n }, {\n key: \"_loadAutoCountry\",\n value: function _loadAutoCountry() {\n var _this5 = this;\n // 3 options:\n // 1) already loaded (we're done)\n // 2) not already started loading (start)\n // 3) already started loading (do nothing - just wait for loading callback to fire)\n if (window.intlTelInputGlobals.autoCountry) {\n this.handleAutoCountry();\n } else if (!window.intlTelInputGlobals.startedLoadingAutoCountry) {\n // don't do this twice!\n window.intlTelInputGlobals.startedLoadingAutoCountry = true;\n if (typeof this.options.geoIpLookup === \"function\") {\n this.options.geoIpLookup(function() {\n var iso2 = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : \"\";\n var iso2Lower = iso2.toLowerCase();\n var isValidIso2 = iso2Lower && _this5._getCountryData(iso2Lower, true);\n if (isValidIso2) {\n window.intlTelInputGlobals.autoCountry = iso2Lower;\n // tell all instances the auto country is ready\n // TODO: this should just be the current instances\n // UPDATE: use setTimeout in case their geoIpLookup function calls this callback straight\n // away (e.g. if they have already done the geo ip lookup somewhere else). Using\n // setTimeout means that the current thread of execution will finish before executing\n // this, which allows the plugin to finish initialising.\n setTimeout(function() {\n return forEachInstance(\"handleAutoCountry\");\n });\n } else {\n _this5._setInitialState(true);\n forEachInstance(\"rejectAutoCountryPromise\");\n }\n }, function() {\n return forEachInstance(\"rejectAutoCountryPromise\");\n });\n }\n }\n }\n }, {\n key: \"_initKeyListeners\",\n value: function _initKeyListeners() {\n var _this6 = this;\n var userOverrideFormatting = false;\n // update flag on input event\n this._handleKeyEvent = function(e) {\n if (_this6._updateFlagFromNumber(_this6.telInput.value)) {\n _this6._triggerCountryChange();\n }\n // if user types their own formatting char (not a plus or a numeric), then set the override\n var isFormattingChar = e && e.data && /[^+0-9]/.test(e.data);\n var isPaste = e && e.inputType === \"insertFromPaste\" && _this6.telInput.value;\n if (isFormattingChar || isPaste) {\n userOverrideFormatting = true;\n } else if (!/[^+0-9]/.test(_this6.telInput.value)) {\n userOverrideFormatting = false;\n }\n // handle FAYT, unless userOverrideFormatting or it's a paste event\n if (_this6.options.formatAsYouType && !userOverrideFormatting && !isPaste) {\n // maintain caret position after reformatting\n var currentCaretPos = _this6.telInput.selectionStart;\n var valueBeforeCaret = _this6.telInput.value.substring(0, currentCaretPos);\n var relevantCharsBeforeCaret = valueBeforeCaret.replace(/[^+0-9]/g, \"\").length;\n var isDeleteForwards = e && e.inputType === \"deleteContentForward\";\n var formattedValue = _this6._formatNumberAsYouType();\n var newCaretPos = _this6._translateCursorPosition(relevantCharsBeforeCaret, formattedValue, currentCaretPos, isDeleteForwards);\n _this6.telInput.value = formattedValue;\n _this6.telInput.setSelectionRange(newCaretPos, newCaretPos);\n }\n };\n // this handles individual key presses as well as cut/paste events\n // the advantage of the \"input\" event over \"keyup\" etc is that \"input\" only fires when the value changes,\n // whereas \"keyup\" fires even for arrow key presses etc\n this.telInput.addEventListener(\"input\", this._handleKeyEvent);\n }\n }, {\n key: \"_translateCursorPosition\",\n value: function _translateCursorPosition(relevantChars, formattedValue, prevCaretPos, isDeleteForwards) {\n // if the first char is a formatting char, and they backspace delete it:\n // cursor should stay at the start (pos 0), rather than stick to the first digit (pos 1)\n if (prevCaretPos === 0 && !isDeleteForwards) {\n return 0;\n }\n var count = 0;\n for (var i = 0; i < formattedValue.length; i++) {\n if (/[+0-9]/.test(formattedValue[i])) {\n count++;\n }\n // normal case: stop when you hit the right number of relevant chars\n // (cursor will be just after the final relevant char)\n if (count === relevantChars && !isDeleteForwards) {\n return i + 1;\n }\n // spacial case: delete forwards (fn + delete on a mac):\n // wait until hit one extra relevant char, and put the cursor just before it (after any formatting chars)\n if (isDeleteForwards && count === relevantChars + 1) {\n return i;\n }\n }\n return formattedValue.length;\n }\n }, {\n key: \"_cap\",\n value: function _cap(number) {\n var max = this.telInput.getAttribute(\"maxlength\");\n return max && number.length > max ? number.substr(0, max) : number;\n }\n }, {\n key: \"_removeEmptyDialCode\",\n value: function _removeEmptyDialCode() {\n if (this.telInput.value.charAt(0) === \"+\") {\n var numeric = this._getNumeric(this.telInput.value);\n // if just a plus, or if just a dial code\n if (!numeric || this.selectedCountryData.dialCode === numeric) {\n this.telInput.value = \"\";\n }\n }\n }\n }, {\n key: \"_getNumeric\",\n value: function _getNumeric(s) {\n return s.replace(/\\D/g, \"\");\n }\n }, {\n key: \"_trigger\",\n value: function _trigger(name) {\n var e = new Event(name, {\n bubbles: true,\n cancelable: true\n });\n this.telInput.dispatchEvent(e);\n }\n }, {\n key: \"_openDropdown\",\n value: function _openDropdown() {\n var _this$options2 = this.options, fixDropdownWidth = _this$options2.fixDropdownWidth, countrySearch = _this$options2.countrySearch;\n if (fixDropdownWidth) {\n this.dropdownContent.style.width = \"\".concat(this.telInput.offsetWidth, \"px\");\n }\n this.dropdownContent.classList.remove(\"iti__hide\");\n this.selectedFlag.setAttribute(\"aria-expanded\", \"true\");\n this._setDropdownPosition();\n // if we have previously selected a country (and countrySearch is disabled), then highlight that item and scroll to it\n // else highlight the first item and scroll to top (even if countrySearch is disabled e.g. on init, showing globe icon)\n if (this.activeItem && !countrySearch) {\n // update highlighting and scroll to active list item\n this._highlightListItem(this.activeItem, false);\n this._scrollTo(this.activeItem, true);\n } else {\n // start by highlighting the first item in the list\n var firstElementChild = this.countryList.firstElementChild;\n if (firstElementChild) {\n this._highlightListItem(firstElementChild, false);\n this.countryList.scrollTop = 0;\n }\n if (countrySearch) {\n this.searchInput.focus();\n }\n }\n // bind all the dropdown-related listeners: mouseover, click, click-off, keydown\n this._bindDropdownListeners();\n // update the arrow\n this.dropdownArrow.classList.add(\"iti__arrow--up\");\n this._trigger(\"open:countrydropdown\");\n }\n }, {\n key: \"_toggleClass\",\n value: function _toggleClass(el, className, shouldHaveClass) {\n if (shouldHaveClass && !el.classList.contains(className)) {\n el.classList.add(className);\n } else if (!shouldHaveClass && el.classList.contains(className)) {\n el.classList.remove(className);\n }\n }\n }, {\n key: \"_setDropdownPosition\",\n value: function _setDropdownPosition() {\n var _this7 = this;\n if (this.options.dropdownContainer) {\n this.options.dropdownContainer.appendChild(this.dropdown);\n }\n if (!this.options.useFullscreenPopup) {\n var pos = this.telInput.getBoundingClientRect();\n // windowTop from https://stackoverflow.com/a/14384091/217866\n var windowTop = document.documentElement.scrollTop;\n var inputTop = pos.top + windowTop;\n var dropdownHeight = this.dropdownContent.offsetHeight;\n // dropdownFitsBelow = (dropdownBottom < windowBottom)\n var dropdownFitsBelow = inputTop + this.telInput.offsetHeight + dropdownHeight < windowTop + window.innerHeight;\n var dropdownFitsAbove = inputTop - dropdownHeight > windowTop;\n // dont allow positioning above when country search enabled as the search box jumps around as you filter countries\n var positionDropdownAboveInput = !this.options.countrySearch && !dropdownFitsBelow && dropdownFitsAbove;\n // by default, the dropdown will be below the input. If we want to position it above the\n // input, we add the dropup class.\n this._toggleClass(this.dropdownContent, \"iti__dropdown-content--dropup\", positionDropdownAboveInput);\n // if dropdownContainer is enabled, calculate postion\n if (this.options.dropdownContainer) {\n // if we want to position the dropdown below the input, we need to add the input height to the top value\n var extraTop = positionDropdownAboveInput ? 0 : this.telInput.offsetHeight;\n // calculate placement\n this.dropdown.style.top = \"\".concat(inputTop + extraTop, \"px\");\n this.dropdown.style.left = \"\".concat(pos.left + document.body.scrollLeft, \"px\");\n // close menu on window scroll\n this._handleWindowScroll = function() {\n return _this7._closeDropdown();\n };\n window.addEventListener(\"scroll\", this._handleWindowScroll);\n }\n }\n }\n }, {\n key: \"_bindDropdownListeners\",\n value: function _bindDropdownListeners() {\n var _this8 = this;\n // when mouse over a list item, just highlight that one\n // we add the class \"highlight\", so if they hit \"enter\" we know which one to select\n this._handleMouseoverCountryList = function(e) {\n // handle event delegation, as we're listening for this event on the countryList\n var listItem = e.target.closest(\".iti__country\");\n if (listItem) {\n _this8._highlightListItem(listItem, false);\n }\n };\n this.countryList.addEventListener(\"mouseover\", this._handleMouseoverCountryList);\n // listen for country selection\n this._handleClickCountryList = function(e) {\n var listItem = e.target.closest(\".iti__country\");\n if (listItem) {\n _this8._selectListItem(listItem);\n }\n };\n this.countryList.addEventListener(\"click\", this._handleClickCountryList);\n // click off to close\n // (except when this initial opening click is bubbling up)\n // we cannot just stopPropagation as it may be needed to close another instance\n var isOpening = true;\n this._handleClickOffToClose = function() {\n if (!isOpening) {\n _this8._closeDropdown();\n }\n isOpening = false;\n };\n document.documentElement.addEventListener(\"click\", this._handleClickOffToClose);\n // listen for up/down scrolling, enter to select, or escape to close\n // use keydown as keypress doesn't fire for non-char keys and we want to catch if they\n // just hit down and hold it to scroll down (no keyup event).\n // listen on the document because that's where key events are triggered if no input has focus\n var query = \"\";\n var queryTimer = null;\n this._handleKeydownOnDropdown = function(e) {\n // prevent down key from scrolling the whole page,\n // and enter key from submitting a form etc\n if ([ \"ArrowUp\", \"ArrowDown\", \"Enter\", \"Escape\" ].includes(e.key)) {\n e.preventDefault();\n e.stopPropagation();\n // up and down to navigate\n if (e.key === \"ArrowUp\" || e.key === \"ArrowDown\") {\n _this8._handleUpDownKey(e.key);\n } else if (e.key === \"Enter\") {\n _this8._handleEnterKey();\n } else if (e.key === \"Escape\") {\n _this8._closeDropdown();\n }\n }\n // alpha chars to perform search\n // regex allows one latin alpha char or space, based on https://stackoverflow.com/a/26900132/217866)\n if (!_this8.options.countrySearch && /^[a-zA-Z\u00C0-\u00FF\u0430-\u044F\u0410-\u042F ]$/.test(e.key)) {\n e.stopPropagation();\n // jump to countries that start with the query string\n if (queryTimer) {\n clearTimeout(queryTimer);\n }\n query += e.key.toLowerCase();\n _this8._searchForCountry(query);\n // if the timer hits 1 second, reset the query\n queryTimer = setTimeout(function() {\n query = \"\";\n }, 1e3);\n }\n };\n document.addEventListener(\"keydown\", this._handleKeydownOnDropdown);\n if (this.options.countrySearch) {\n var doFilter = function doFilter() {\n var inputQuery = _this8.searchInput.value.trim();\n if (inputQuery) {\n _this8._filterCountries(inputQuery);\n } else {\n _this8._filterCountries(\"\", true);\n }\n };\n var keyupTimer = null;\n this._handleSearchChange = function() {\n // filtering country nodes is expensive (lots of DOM manipulation), so rate limit it\n if (keyupTimer) {\n clearTimeout(keyupTimer);\n }\n keyupTimer = setTimeout(function() {\n doFilter();\n keyupTimer = null;\n }, 100);\n };\n this.searchInput.addEventListener(\"input\", this._handleSearchChange);\n // stop propagation on search input click, so doesn't trigger click-off-to-close listener\n this.searchInput.addEventListener(\"click\", function(e) {\n return e.stopPropagation();\n });\n }\n }\n }, {\n key: \"_normaliseString\",\n value: function _normaliseString() {\n var s = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : \"\";\n return s.normalize(\"NFD\").replace(/[\\u0300-\\u036f]/g, \"\").toLowerCase();\n }\n }, {\n key: \"_filterCountries\",\n value: function _filterCountries(query) {\n var isReset = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;\n var isFirst = true;\n this.countryList.innerHTML = \"\";\n var normalisedQuery = this._normaliseString(query);\n for (var i = 0; i < this.countries.length; i++) {\n var c = this.countries[i];\n var normalisedCountryName = this._normaliseString(c.name);\n var fullDialCode = \"+\".concat(c.dialCode);\n if (isReset || normalisedCountryName.includes(normalisedQuery) || fullDialCode.includes(normalisedQuery) || c.iso2.includes(normalisedQuery)) {\n this.countryList.appendChild(c.nodeById[this.id]);\n // highlight the first item\n if (isFirst) {\n this._highlightListItem(c.nodeById[this.id], false);\n isFirst = false;\n }\n }\n }\n // scroll to top (useful if user had previously scrolled down)\n this.countryList.scrollTop = 0;\n this._updateSearchResultsText();\n }\n }, {\n key: \"_updateSearchResultsText\",\n value: function _updateSearchResultsText() {\n var i18n = this.options.i18n;\n var count = this.countryList.childElementCount;\n var searchText;\n if (count === 0) {\n searchText = i18n.zeroSearchResults || \"No results found\";\n } else if (count === 1) {\n searchText = i18n.oneSearchResult || \"1 result found\";\n } else {\n // eslint-disable-next-line no-template-curly-in-string\n searchText = i18n.multipleSearchResults ? i18n.multipleSearchResults.replace(\"${count}\", count) : \"\".concat(count, \" results found\");\n }\n this.searchResultsA11yText.textContent = searchText;\n }\n }, {\n key: \"_handleUpDownKey\",\n value: function _handleUpDownKey(key) {\n var next = key === \"ArrowUp\" ? this.highlightedItem.previousElementSibling : this.highlightedItem.nextElementSibling;\n if (next) {\n // skip the divider\n if (next.classList.contains(\"iti__divider\")) {\n next = key === \"ArrowUp\" ? next.previousElementSibling : next.nextElementSibling;\n }\n } else if (this.countryList.childElementCount > 1) {\n // otherwise, we must be at the end, so loop round again\n next = key === \"ArrowUp\" ? this.countryList.lastElementChild : this.countryList.firstElementChild;\n }\n if (next) {\n // make sure the next item is visible\n // (before calling focus(), which can cause the next item to scroll to the middle of the dropdown, which is jarring)\n this._scrollTo(next, false);\n // if country search enabled, dont lose focus from the search input on up/down\n var doFocus = !this.options.countrySearch;\n this._highlightListItem(next, doFocus);\n }\n }\n }, {\n key: \"_handleEnterKey\",\n value: function _handleEnterKey() {\n if (this.highlightedItem) {\n this._selectListItem(this.highlightedItem);\n }\n }\n }, {\n key: \"_searchForCountry\",\n value: function _searchForCountry(query) {\n for (var i = 0; i < this.countries.length; i++) {\n if (this._startsWith(this.countries[i].name, query)) {\n var listItem = this.countries[i].nodeById[this.id];\n // update highlighting and scroll\n this._highlightListItem(listItem, false);\n this._scrollTo(listItem, true);\n break;\n }\n }\n }\n }, {\n key: \"_startsWith\",\n value: function _startsWith(a, b) {\n return a.substr(0, b.length).toLowerCase() === b;\n }\n }, {\n key: \"_updateValFromNumber\",\n value: function _updateValFromNumber(fullNumber) {\n var number = fullNumber;\n if (this.options.formatOnDisplay && window.intlTelInputUtils && this.selectedCountryData) {\n var useNational = this.options.nationalMode || number.charAt(0) !== \"+\" && !this.options.showSelectedDialCode;\n var _intlTelInputUtils$nu = intlTelInputUtils.numberFormat, NATIONAL = _intlTelInputUtils$nu.NATIONAL, INTERNATIONAL = _intlTelInputUtils$nu.INTERNATIONAL;\n var format = useNational ? NATIONAL : INTERNATIONAL;\n number = intlTelInputUtils.formatNumber(number, this.selectedCountryData.iso2, format);\n }\n number = this._beforeSetNumber(number);\n this.telInput.value = number;\n }\n }, {\n key: \"_updateFlagFromNumber\",\n value: function _updateFlagFromNumber(fullNumber) {\n var plusIndex = fullNumber.indexOf(\"+\");\n // if it contains a plus, discard any chars before it e.g. accidental space char.\n // this keeps the selected country auto-updating correctly, which we want as\n // libphonenumber's validation/getNumber methods will ignore these chars anyway\n var number = plusIndex ? fullNumber.substring(plusIndex) : fullNumber;\n // if we already have US/Canada selected, make sure the number starts\n // with a +1 so _getDialCode will be able to extract the area code\n // update: if we dont yet have selectedCountryData, but we're here (trying to update the flag\n // from the number), that means we're initialising the plugin with a number that already has a\n // dial code, so fine to ignore this bit\n var selectedDialCode = this.selectedCountryData.dialCode;\n var isNanp = selectedDialCode === \"1\";\n if (number && isNanp && number.charAt(0) !== \"+\") {\n if (number.charAt(0) !== \"1\") {\n number = \"1\".concat(number);\n }\n number = \"+\".concat(number);\n }\n // if showSelectedDialCode enabled, then consider the selected dial code to be part of the number\n if (this.options.showSelectedDialCode && selectedDialCode && number.charAt(0) !== \"+\") {\n number = \"+\".concat(selectedDialCode).concat(number);\n }\n // try and extract valid dial code from input\n var dialCode = this._getDialCode(number, true);\n var numeric = this._getNumeric(number);\n var iso2 = null;\n if (dialCode) {\n var iso2Codes = this.dialCodeToIso2Map[this._getNumeric(dialCode)];\n // check if the right country is already selected. this should be false if the number is\n // longer than the matched dial code because in this case we need to make sure that if\n // there are multiple country matches, that the first one is selected (note: we could\n // just check that here, but it requires the same loop that we already have later)\n var alreadySelected = iso2Codes.indexOf(this.selectedCountryData.iso2) !== -1 && numeric.length <= dialCode.length - 1;\n var isRegionlessNanpNumber = selectedDialCode === \"1\" && this._isRegionlessNanp(numeric);\n // only update the flag if:\n // A) NOT (we currently have a NANP flag selected, and the number is a regionlessNanp)\n // AND\n // B) the right country is not already selected\n if (!isRegionlessNanpNumber && !alreadySelected) {\n // if using onlyCountries option, iso2Codes[0] may be empty, so we must find the first\n // non-empty index\n for (var j = 0; j < iso2Codes.length; j++) {\n if (iso2Codes[j]) {\n iso2 = iso2Codes[j];\n break;\n }\n }\n }\n } else if (number.charAt(0) === \"+\" && numeric.length) {\n // invalid dial code, so empty\n // Note: use getNumeric here because the number has not been formatted yet, so could contain\n // bad chars\n iso2 = \"\";\n } else if ((!number || number === \"+\") && !this.selectedCountryData.iso2) {\n // if no selected flag, and user either clears the input, or just types a plus, then show default\n iso2 = this.defaultCountry;\n }\n if (iso2 !== null) {\n return this._setCountry(iso2);\n }\n return false;\n }\n }, {\n key: \"_isRegionlessNanp\",\n value: function _isRegionlessNanp(number) {\n var numeric = this._getNumeric(number);\n if (numeric.charAt(0) === \"1\") {\n var areaCode = numeric.substr(1, 3);\n return regionlessNanpNumbers.indexOf(areaCode) !== -1;\n }\n return false;\n }\n }, {\n key: \"_highlightListItem\",\n value: function _highlightListItem(listItem, shouldFocus) {\n var prevItem = this.highlightedItem;\n if (prevItem) {\n prevItem.classList.remove(\"iti__highlight\");\n prevItem.setAttribute(\"aria-selected\", \"false\");\n }\n this.highlightedItem = listItem;\n this.highlightedItem.classList.add(\"iti__highlight\");\n this.highlightedItem.setAttribute(\"aria-selected\", \"true\");\n this.selectedFlag.setAttribute(\"aria-activedescendant\", listItem.getAttribute(\"id\"));\n if (this.options.countrySearch) {\n this.searchInput.setAttribute(\"aria-activedescendant\", listItem.getAttribute(\"id\"));\n }\n if (shouldFocus) {\n this.highlightedItem.focus();\n }\n }\n }, {\n key: \"_getCountryData\",\n value: function _getCountryData(iso2, allowFail) {\n for (var i = 0; i < this.countries.length; i++) {\n if (this.countries[i].iso2 === iso2) {\n return this.countries[i];\n }\n }\n if (allowFail) {\n return null;\n }\n throw new Error(\"No country data for '\".concat(iso2, \"'\"));\n }\n }, {\n key: \"_setCountry\",\n value: function _setCountry(iso2) {\n var _this$options3 = this.options, allowDropdown = _this$options3.allowDropdown, showSelectedDialCode = _this$options3.showSelectedDialCode, showFlags = _this$options3.showFlags, countrySearch = _this$options3.countrySearch, i18n = _this$options3.i18n;\n var prevCountry = this.selectedCountryData.iso2 ? this.selectedCountryData : {};\n // do this first as it will throw an error and stop if iso2 is invalid\n this.selectedCountryData = iso2 ? this._getCountryData(iso2, false) : {};\n // update the defaultCountry - we only need the iso2 from now on, so just store that\n if (this.selectedCountryData.iso2) {\n this.defaultCountry = this.selectedCountryData.iso2;\n }\n // update the flag class and the a11y text\n if (this.selectedFlagInner) {\n var flagClass = \"\";\n var a11yText = \"\";\n if (iso2) {\n if (showFlags) {\n flagClass = \"iti__flag iti__\".concat(iso2);\n a11yText = \"\".concat(this.selectedCountryData.name, \" +\").concat(this.selectedCountryData.dialCode);\n }\n } else {\n flagClass = \"iti__flag iti__globe\";\n a11yText = i18n.noCountrySelected || \"No country selected\";\n }\n this.selectedFlagInner.className = flagClass;\n this.selectedFlagA11yText.textContent = a11yText;\n }\n this._setSelectedCountryFlagTitleAttribute(iso2, showSelectedDialCode);\n // update the selected dial code\n if (showSelectedDialCode) {\n var dialCode = this.selectedCountryData.dialCode ? \"+\".concat(this.selectedCountryData.dialCode) : \"\";\n this.selectedDialCode.innerHTML = dialCode;\n // offsetWidth is zero if input is in a hidden container during initialisation\n var selectedFlagWidth = this.selectedFlag.offsetWidth || this._getHiddenSelectedFlagWidth();\n // add 6px of padding after the grey selected-dial-code box, as this is what we use in the css\n if (this.isRTL) {\n this.telInput.style.paddingRight = \"\".concat(selectedFlagWidth + 6, \"px\");\n } else {\n this.telInput.style.paddingLeft = \"\".concat(selectedFlagWidth + 6, \"px\");\n }\n }\n // and the input's placeholder\n this._updatePlaceholder();\n // update the active list item (only if country search disabled, as country search doesn't store the active item)\n if (allowDropdown && !countrySearch) {\n var prevItem = this.activeItem;\n if (prevItem) {\n prevItem.classList.remove(\"iti__active\");\n prevItem.setAttribute(\"aria-selected\", \"false\");\n }\n if (iso2) {\n // check if there is a preferred item first, else fall back to standard\n var nextItem = this.countryList.querySelector(\"#iti-\".concat(this.id, \"__item-\").concat(iso2, \"-preferred\")) || this.countryList.querySelector(\"#iti-\".concat(this.id, \"__item-\").concat(iso2));\n nextItem.setAttribute(\"aria-selected\", \"true\");\n nextItem.classList.add(\"iti__active\");\n this.activeItem = nextItem;\n }\n }\n // return if the flag has changed or not\n return prevCountry.iso2 !== iso2;\n }\n }, {\n key: \"_setSelectedCountryFlagTitleAttribute\",\n value: function _setSelectedCountryFlagTitleAttribute(iso2, showSelectedDialCode) {\n if (!this.selectedFlag) {\n return;\n }\n var title;\n if (iso2 && !showSelectedDialCode) {\n title = \"\".concat(this.selectedCountryData.name, \": +\").concat(this.selectedCountryData.dialCode);\n } else if (iso2) {\n // For screen reader output, we don't want to include the dial code in the reader output twice\n // so just use the selected country name here:\n title = this.selectedCountryData.name;\n } else {\n title = \"Unknown\";\n }\n this.selectedFlag.setAttribute(\"title\", title);\n }\n }, {\n key: \"_getHiddenSelectedFlagWidth\",\n value: function _getHiddenSelectedFlagWidth() {\n // to get the right styling to apply, all we need is a shallow clone of the container,\n // and then to inject a deep clone of the selectedFlag element\n var containerClone = this.telInput.parentNode.cloneNode();\n containerClone.style.visibility = \"hidden\";\n document.body.appendChild(containerClone);\n var flagsContainerClone = this.flagsContainer.cloneNode();\n containerClone.appendChild(flagsContainerClone);\n var selectedFlagClone = this.selectedFlag.cloneNode(true);\n flagsContainerClone.appendChild(selectedFlagClone);\n var width = selectedFlagClone.offsetWidth;\n containerClone.parentNode.removeChild(containerClone);\n return width;\n }\n }, {\n key: \"_updatePlaceholder\",\n value: function _updatePlaceholder() {\n var _this$options4 = this.options, autoPlaceholder = _this$options4.autoPlaceholder, placeholderNumberType = _this$options4.placeholderNumberType, nationalMode = _this$options4.nationalMode, customPlaceholder = _this$options4.customPlaceholder;\n var shouldSetPlaceholder = autoPlaceholder === \"aggressive\" || !this.hadInitialPlaceholder && autoPlaceholder === \"polite\";\n if (window.intlTelInputUtils && shouldSetPlaceholder) {\n var numberType = intlTelInputUtils.numberType[placeholderNumberType];\n var placeholder = this.selectedCountryData.iso2 ? intlTelInputUtils.getExampleNumber(this.selectedCountryData.iso2, nationalMode, numberType) : \"\";\n placeholder = this._beforeSetNumber(placeholder);\n if (typeof customPlaceholder === \"function\") {\n placeholder = customPlaceholder(placeholder, this.selectedCountryData);\n }\n this.telInput.setAttribute(\"placeholder\", placeholder);\n }\n }\n }, {\n key: \"_selectListItem\",\n value: function _selectListItem(listItem) {\n // update selected flag and active list item\n var flagChanged = this._setCountry(listItem.getAttribute(\"data-country-code\"));\n this._closeDropdown();\n this._updateDialCode(listItem.getAttribute(\"data-dial-code\"));\n // focus the input\n this.telInput.focus();\n if (flagChanged) {\n this._triggerCountryChange();\n }\n }\n }, {\n key: \"_closeDropdown\",\n value: function _closeDropdown() {\n this.dropdownContent.classList.add(\"iti__hide\");\n this.selectedFlag.setAttribute(\"aria-expanded\", \"false\");\n this.selectedFlag.removeAttribute(\"aria-activedescendant\");\n if (this.highlightedItem) {\n this.highlightedItem.setAttribute(\"aria-selected\", \"false\");\n }\n if (this.options.countrySearch) {\n this.searchInput.removeAttribute(\"aria-activedescendant\");\n }\n // update the arrow\n this.dropdownArrow.classList.remove(\"iti__arrow--up\");\n // unbind key events\n document.removeEventListener(\"keydown\", this._handleKeydownOnDropdown);\n if (this.options.countrySearch) {\n this.searchInput.removeEventListener(\"input\", this._handleSearchChange);\n }\n document.documentElement.removeEventListener(\"click\", this._handleClickOffToClose);\n this.countryList.removeEventListener(\"mouseover\", this._handleMouseoverCountryList);\n this.countryList.removeEventListener(\"click\", this._handleClickCountryList);\n // remove menu from container\n if (this.options.dropdownContainer) {\n if (!this.options.useFullscreenPopup) {\n window.removeEventListener(\"scroll\", this._handleWindowScroll);\n }\n if (this.dropdown.parentNode) {\n this.dropdown.parentNode.removeChild(this.dropdown);\n }\n }\n this._trigger(\"close:countrydropdown\");\n }\n }, {\n key: \"_scrollTo\",\n value: function _scrollTo(element, middle) {\n var container = this.countryList;\n // windowTop from https://stackoverflow.com/a/14384091/217866\n var windowTop = document.documentElement.scrollTop;\n var containerHeight = container.offsetHeight;\n var containerTop = container.getBoundingClientRect().top + windowTop;\n var containerBottom = containerTop + containerHeight;\n var elementHeight = element.offsetHeight;\n var elementTop = element.getBoundingClientRect().top + windowTop;\n var elementBottom = elementTop + elementHeight;\n var newScrollTop = elementTop - containerTop + container.scrollTop;\n var middleOffset = containerHeight / 2 - elementHeight / 2;\n if (elementTop < containerTop) {\n // scroll up\n if (middle) {\n newScrollTop -= middleOffset;\n }\n container.scrollTop = newScrollTop;\n } else if (elementBottom > containerBottom) {\n // scroll down\n if (middle) {\n newScrollTop += middleOffset;\n }\n var heightDifference = containerHeight - elementHeight;\n container.scrollTop = newScrollTop - heightDifference;\n }\n }\n }, {\n key: \"_updateDialCode\",\n value: function _updateDialCode(newDialCodeBare) {\n var inputVal = this.telInput.value;\n // save having to pass this every time\n var newDialCode = \"+\".concat(newDialCodeBare);\n var newNumber;\n if (inputVal.charAt(0) === \"+\") {\n // there's a plus so we're dealing with a replacement\n var prevDialCode = this._getDialCode(inputVal);\n if (prevDialCode) {\n // current number contains a valid dial code, so replace it\n newNumber = inputVal.replace(prevDialCode, newDialCode);\n } else {\n // current number contains an invalid dial code, so ditch it\n // (no way to determine where the invalid dial code ends and the rest of the number begins)\n newNumber = newDialCode;\n }\n this.telInput.value = newNumber;\n }\n }\n }, {\n key: \"_getDialCode\",\n value: function _getDialCode(number, includeAreaCode) {\n var dialCode = \"\";\n // only interested in international numbers (starting with a plus)\n if (number.charAt(0) === \"+\") {\n var numericChars = \"\";\n // iterate over chars\n for (var i = 0; i < number.length; i++) {\n var c = number.charAt(i);\n // if char is number (https://stackoverflow.com/a/8935649/217866)\n if (!isNaN(parseInt(c, 10))) {\n numericChars += c;\n // if current numericChars make a valid dial code\n if (includeAreaCode) {\n if (this.dialCodeToIso2Map[numericChars]) {\n // store the actual raw string (useful for matching later)\n dialCode = number.substr(0, i + 1);\n }\n } else {\n if (this.dialCodes[numericChars]) {\n dialCode = number.substr(0, i + 1);\n // if we're just looking for a dial code, we can break as soon as we find one\n break;\n }\n }\n // stop searching as soon as we can - in this case when we hit max len\n if (numericChars.length === this.dialCodeMaxLen) {\n break;\n }\n }\n }\n }\n return dialCode;\n }\n }, {\n key: \"_getFullNumber\",\n value: function _getFullNumber() {\n var val = this.telInput.value.trim();\n var dialCode = this.selectedCountryData.dialCode;\n var prefix;\n var numericVal = this._getNumeric(val);\n if (this.options.showSelectedDialCode && !this.options.nationalMode && val.charAt(0) !== \"+\" && dialCode && numericVal) {\n // when using showSelectedDialCode, it is visible so is effectively part of the typed number\n prefix = \"+\".concat(dialCode);\n } else {\n prefix = \"\";\n }\n return prefix + val;\n }\n }, {\n key: \"_beforeSetNumber\",\n value: function _beforeSetNumber(fullNumber) {\n var number = fullNumber;\n if (this.options.showSelectedDialCode) {\n var dialCode = this._getDialCode(number);\n // if there is a valid dial code\n if (dialCode) {\n // in case _getDialCode returned an area code as well\n dialCode = \"+\".concat(this.selectedCountryData.dialCode);\n // a lot of numbers will have a space separating the dial code and the main number, and\n // some NANP numbers will have a hyphen e.g. +1 684-733-1234 - in both cases we want to get\n // rid of it\n // NOTE: don't just trim all non-numerics as may want to preserve an open parenthesis etc\n var start = number[dialCode.length] === \" \" || number[dialCode.length] === \"-\" ? dialCode.length + 1 : dialCode.length;\n number = number.substr(start);\n }\n }\n return this._cap(number);\n }\n }, {\n key: \"_triggerCountryChange\",\n value: function _triggerCountryChange() {\n this._trigger(\"countrychange\");\n }\n }, {\n key: \"_formatNumberAsYouType\",\n value: function _formatNumberAsYouType() {\n var val = this._getFullNumber();\n var result = window.intlTelInputUtils ? intlTelInputUtils.formatNumberAsYouType(val, this.selectedCountryData.iso2) : val;\n // if showSelectedDialCode and they haven't (re)typed the dial code in the input as well, then remove the dial code\n var dialCode = this.selectedCountryData.dialCode;\n if (this.options.showSelectedDialCode && !this.options.nationalMode && this.telInput.value.charAt(0) !== \"+\" && result.includes(\"+\".concat(dialCode))) {\n var afterDialCode = result.split(\"+\".concat(dialCode))[1] || \"\";\n return afterDialCode.trim();\n }\n return result;\n }\n }, {\n key: \"handleAutoCountry\",\n value: function handleAutoCountry() {\n if (this.options.initialCountry === \"auto\") {\n // we must set this even if there is an initial val in the input: in case the initial val is\n // invalid and they delete it - they should see their auto country\n this.defaultCountry = window.intlTelInputGlobals.autoCountry;\n // if there's no initial value in the input, then update the flag\n if (!this.telInput.value) {\n this.setCountry(this.defaultCountry);\n }\n this.resolveAutoCountryPromise();\n }\n }\n }, {\n key: \"handleUtils\",\n value: function handleUtils() {\n // if the request was successful\n if (window.intlTelInputUtils) {\n // if there's an initial value in the input, then format it\n if (this.telInput.value) {\n this._updateValFromNumber(this.telInput.value);\n }\n if (this.selectedCountryData.iso2) {\n this._updatePlaceholder();\n }\n }\n this.resolveUtilsScriptPromise();\n }\n }, {\n key: \"destroy\",\n value: function destroy() {\n if (this.options.allowDropdown) {\n // make sure the dropdown is closed (and unbind listeners)\n this._closeDropdown();\n this.selectedFlag.removeEventListener(\"click\", this._handleClickSelectedFlag);\n this.flagsContainer.removeEventListener(\"keydown\", this._handleFlagsContainerKeydown);\n // label click hack\n var label = this.telInput.closest(\"label\");\n if (label) {\n label.removeEventListener(\"click\", this._handleLabelClick);\n }\n }\n // unbind hiddenInput listeners\n var form = this.telInput.form;\n if (this._handleHiddenInputSubmit && form) {\n form.removeEventListener(\"submit\", this._handleHiddenInputSubmit);\n }\n // unbind key events, and cut/paste events\n this.telInput.removeEventListener(\"input\", this._handleKeyEvent);\n // remove attribute of id instance: data-intl-tel-input-id\n this.telInput.removeAttribute(\"data-intl-tel-input-id\");\n // remove markup (but leave the original input)\n var wrapper = this.telInput.parentNode;\n wrapper.parentNode.insertBefore(this.telInput, wrapper);\n wrapper.parentNode.removeChild(wrapper);\n delete window.intlTelInputGlobals.instances[this.id];\n }\n }, {\n key: \"getExtension\",\n value: function getExtension() {\n if (window.intlTelInputUtils) {\n return intlTelInputUtils.getExtension(this._getFullNumber(), this.selectedCountryData.iso2);\n }\n return \"\";\n }\n }, {\n key: \"getNumber\",\n value: function getNumber(format) {\n if (window.intlTelInputUtils) {\n var iso2 = this.selectedCountryData.iso2;\n return intlTelInputUtils.formatNumber(this._getFullNumber(), iso2, format);\n }\n return \"\";\n }\n }, {\n key: \"getNumberType\",\n value: function getNumberType() {\n if (window.intlTelInputUtils) {\n return intlTelInputUtils.getNumberType(this._getFullNumber(), this.selectedCountryData.iso2);\n }\n return -99;\n }\n }, {\n key: \"getSelectedCountryData\",\n value: function getSelectedCountryData() {\n return this.selectedCountryData;\n }\n }, {\n key: \"getValidationError\",\n value: function getValidationError() {\n if (window.intlTelInputUtils) {\n var iso2 = this.selectedCountryData.iso2;\n return intlTelInputUtils.getValidationError(this._getFullNumber(), iso2);\n }\n return -99;\n }\n }, {\n key: \"isValidNumber\",\n value: function isValidNumber() {\n var mobileOnly = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : true;\n var val = this._getFullNumber();\n // return false for any alpha chars\n if (/(?:[A-Za-z\\xAA\\xB5\\xBA\\xC0-\\xD6\\xD8-\\xF6\\xF8-\\u02C1\\u02C6-\\u02D1\\u02E0-\\u02E4\\u02EC\\u02EE\\u0370-\\u0374\\u0376\\u0377\\u037A-\\u037D\\u037F\\u0386\\u0388-\\u038A\\u038C\\u038E-\\u03A1\\u03A3-\\u03F5\\u03F7-\\u0481\\u048A-\\u052F\\u0531-\\u0556\\u0559\\u0560-\\u0588\\u05D0-\\u05EA\\u05EF-\\u05F2\\u0620-\\u064A\\u066E\\u066F\\u0671-\\u06D3\\u06D5\\u06E5\\u06E6\\u06EE\\u06EF\\u06FA-\\u06FC\\u06FF\\u0710\\u0712-\\u072F\\u074D-\\u07A5\\u07B1\\u07CA-\\u07EA\\u07F4\\u07F5\\u07FA\\u0800-\\u0815\\u081A\\u0824\\u0828\\u0840-\\u0858\\u0860-\\u086A\\u0870-\\u0887\\u0889-\\u088E\\u08A0-\\u08C9\\u0904-\\u0939\\u093D\\u0950\\u0958-\\u0961\\u0971-\\u0980\\u0985-\\u098C\\u098F\\u0990\\u0993-\\u09A8\\u09AA-\\u09B0\\u09B2\\u09B6-\\u09B9\\u09BD\\u09CE\\u09DC\\u09DD\\u09DF-\\u09E1\\u09F0\\u09F1\\u09FC\\u0A05-\\u0A0A\\u0A0F\\u0A10\\u0A13-\\u0A28\\u0A2A-\\u0A30\\u0A32\\u0A33\\u0A35\\u0A36\\u0A38\\u0A39\\u0A59-\\u0A5C\\u0A5E\\u0A72-\\u0A74\\u0A85-\\u0A8D\\u0A8F-\\u0A91\\u0A93-\\u0AA8\\u0AAA-\\u0AB0\\u0A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FA\\u10FC-\\u1248\\u124A-\\u124D\\u1250-\\u1256\\u1258\\u125A-\\u125D\\u1260-\\u1288\\u128A-\\u128D\\u1290-\\u12B0\\u12B2-\\u12B5\\u12B8-\\u12BE\\u12C0\\u12C2-\\u12C5\\u12C8-\\u12D6\\u12D8-\\u1310\\u1312-\\u1315\\u1318-\\u135A\\u1380-\\u138F\\u13A0-\\u13F5\\u13F8-\\u13FD\\u1401-\\u166C\\u166F-\\u167F\\u1681-\\u169A\\u16A0-\\u16EA\\u16F1-\\u16F8\\u1700-\\u1711\\u171F-\\u1731\\u1740-\\u1751\\u1760-\\u176C\\u176E-\\u1770\\u1780-\\u17B3\\u17D7\\u17DC\\u1820-\\u1878\\u1880-\\u1884\\u1887-\\u18A8\\u18AA\\u18B0-\\u18F5\\u1900-\\u191E\\u1950-\\u196D\\u1970-\\u1974\\u1980-\\u19AB\\u19B0-\\u19C9\\u1A00-\\u1A16\\u1A20-\\u1A54\\u1AA7\\u1B05-\\u1B33\\u1B45-\\u1B4C\\u1B83-\\u1BA0\\u1BAE\\u1BAF\\u1BBA-\\u1BE5\\u1C00-\\u1C23\\u1C4D-\\u1C4F\\u1C5A-\\u1C7D\\u1C80-\\u1C88\\u1C90-\\u1CBA\\u1CBD-\\u1CBF\\u1CE9-\\u1CEC\\u1CEE-\\u1CF3\\u1CF5\\u1CF6\\u1CFA\\u1D00-\\u1DBF\\u1E00-\\u1F15\\u1F18-\\u1F1D\\u1F20-\\u1F45\\u1F48-\\u1F4D\\u1F50-\\u1F57\\u1F59\\u1F5B\\u1F5D\\u1F5F-\\u1F7D\\u1F80-\\u1FB4\\u1FB6-\\u1FBC\\u1FBE\\u1FC2-\\u1FC4\\u1FC6-\\u1FCC\\u1FD0-\\u1FD3\\u1FD6-\\u1FDB\\u1FE0-\\u1FEC\\u1FF2-\\u1FF4\\u1FF6-\\u1FFC\\u2071\\u207F\\u2090-\\u209C\\u2102\\u2107\\u210A-\\u2113\\u2115\\u2119-\\u211D\\u2124\\u2126\\u2128\\u212A-\\u212D\\u212F-\\u2139\\u213C-\\u213F\\u2145-\\u2149\\u214E\\u2183\\u2184\\u2C00-\\u2CE4\\u2CEB-\\u2CEE\\u2CF2\\u2CF3\\u2D00-\\u2D25\\u2D27\\u2D2D\\u2D30-\\u2D67\\u2D6F\\u2D80-\\u2D96\\u2DA0-\\u2DA6\\u2DA8-\\u2DAE\\u2DB0-\\u2DB6\\u2DB8-\\u2DBE\\u2DC0-\\u2DC6\\u2DC8-\\u2DCE\\u2DD0-\\u2DD6\\u2DD8-\\u2DDE\\u2E2F\\u3005\\u3006\\u3031-\\u3035\\u303B\\u303C\\u3041-\\u3096\\u309D-\\u309F\\u30A1-\\u30FA\\u30FC-\\u30FF\\u3105-\\u312F\\u3131-\\u318E\\u31A0-\\u31BF\\u31F0-\\u31FF\\u3400-\\u4DBF\\u4E00-\\uA48C\\uA4D0-\\uA4FD\\uA500-\\uA60C\\uA610-\\uA61F\\uA62A\\uA62B\\uA640-\\uA66E\\uA67F-\\uA69D\\uA6A0-\\uA6E5\\uA717-\\uA71F\\uA722-\\uA788\\uA78B-\\uA7CA\\uA7D0\\uA7D1\\uA7D3\\uA7D5-\\uA7D9\\uA7F2-\\uA801\\uA803-\\uA805\\uA807-\\uA80A\\uA80C-\\uA822\\uA840-\\uA873\\uA882-\\uA8B3\\uA8F2-\\uA8F7\\uA8FB\\uA8FD\\uA8FE\\uA90A-\\uA925\\uA930-\\uA946\\uA960-\\uA97C\\uA984-\\uA9B2\\uA9CF\\uA9E0-\\uA9E4\\uA9E6-\\uA9EF\\uA9FA-\\uA9FE\\uAA00-\\uAA28\\uAA40-\\uAA42\\uAA44-\\uAA4B\\uAA60-\\uAA76\\uAA7A\\uAA7E-\\uAAAF\\uAAB1\\uAAB5\\uAAB6\\uAAB9-\\uAABD\\uAAC0\\uAAC2\\uAADB-\\uAADD\\uAAE0-\\uAAEA\\uAAF2-\\uAAF4\\uAB01-\\uAB06\\uAB09-\\uAB0E\\uAB11-\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DCA0-\\uDCDF\\uDCFF-\\uDD06\\uDD09\\uDD0C-\\uDD13\\uDD15\\uDD16\\uDD18-\\uDD2F\\uDD3F\\uDD41\\uDDA0-\\uDDA7\\uDDAA-\\uDDD0\\uDDE1\\uDDE3\\uDE00\\uDE0B-\\uDE32\\uDE3A\\uDE50\\uDE5C-\\uDE89\\uDE9D\\uDEB0-\\uDEF8]|\\uD807[\\uDC00-\\uDC08\\uDC0A-\\uDC2E\\uDC40\\uDC72-\\uDC8F\\uDD00-\\uDD06\\uDD08\\uDD09\\uDD0B-\\uDD30\\uDD46\\uDD60-\\uDD65\\uDD67\\uDD68\\uDD6A-\\uDD89\\uDD98\\uDEE0-\\uDEF2\\uDF02\\uDF04-\\uDF10\\uDF12-\\uDF33\\uDFB0]|\\uD808[\\uDC00-\\uDF99]|\\uD809[\\uDC80-\\uDD43]|\\uD80B[\\uDF90-\\uDFF0]|[\\uD80C\\uD81C-\\uD820\\uD822\\uD840-\\uD868\\uD86A-\\uD86C\\uD86F-\\uD872\\uD874-\\uD879\\uD880-\\uD883\\uD885-\\uD887][\\uDC00-\\uDFFF]|\\uD80D[\\uDC00-\\uDC2F\\uDC41-\\uDC46]|\\uD811[\\uDC00-\\uDE46]|\\uD81A[\\uDC00-\\uDE38\\uDE40-\\uDE5E\\uDE70-\\uDEBE\\uDED0-\\uDEED\\uDF00-\\uDF2F\\uDF40-\\uDF43\\uDF63-\\uDF77\\uDF7D-\\uDF8F]|\\uD81B[\\uDE40-\\uDE7F\\uDF00-\\uDF4A\\uDF50\\uDF93-\\uDF9F\\uDFE0\\uDFE1\\uDFE3]|\\uD821[\\uDC00-\\uDFF7]|\\uD823[\\uDC00-\\uDCD5\\uDD00-\\uDD08]|\\uD82B[\\uDFF0-\\uDFF3\\uDFF5-\\uDFFB\\uDFFD\\uDFFE]|\\uD82C[\\uDC00-\\uDD22\\uDD32\\uDD50-\\uDD52\\uDD55\\uDD64-\\uDD67\\uDD70-\\uDEFB]|\\uD82F[\\uDC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EA5-\\uDEA9\\uDEAB-\\uDEBB]|\\uD869[\\uDC00-\\uDEDF\\uDF00-\\uDFFF]|\\uD86D[\\uDC00-\\uDF39\\uDF40-\\uDFFF]|\\uD86E[\\uDC00-\\uDC1D\\uDC20-\\uDFFF]|\\uD873[\\uDC00-\\uDEA1\\uDEB0-\\uDFFF]|\\uD87A[\\uDC00-\\uDFE0\\uDFF0-\\uDFFF]|\\uD87B[\\uDC00-\\uDE5D]|\\uD87E[\\uDC00-\\uDE1D]|\\uD884[\\uDC00-\\uDF4A\\uDF50-\\uDFFF]|\\uD888[\\uDC00-\\uDFAF])/.test(val)) {\n return false;\n }\n return window.intlTelInputUtils ? intlTelInputUtils.isPossibleNumber(val, this.selectedCountryData.iso2, mobileOnly) : null;\n }\n }, {\n key: \"isValidNumberPrecise\",\n value: function isValidNumberPrecise() {\n var val = this._getFullNumber();\n // return false for any alpha chars\n if (/(?:[A-Za-z\\xAA\\xB5\\xBA\\xC0-\\xD6\\xD8-\\xF6\\xF8-\\u02C1\\u02C6-\\u02D1\\u02E0-\\u02E4\\u02EC\\u02EE\\u0370-\\u0374\\u0376\\u0377\\u037A-\\u037D\\u037F\\u0386\\u0388-\\u038A\\u038C\\u038E-\\u03A1\\u03A3-\\u03F5\\u03F7-\\u0481\\u048A-\\u052F\\u0531-\\u0556\\u0559\\u0560-\\u0588\\u05D0-\\u05EA\\u05EF-\\u05F2\\u0620-\\u064A\\u066E\\u066F\\u0671-\\u06D3\\u06D5\\u06E5\\u06E6\\u06EE\\u06EF\\u06FA-\\u06FC\\u06FF\\u0710\\u0712-\\u072F\\u074D-\\u07A5\\u07B1\\u07CA-\\u07EA\\u07F4\\u07F5\\u07FA\\u0800-\\u0815\\u081A\\u0824\\u0828\\u0840-\\u0858\\u0860-\\u086A\\u0870-\\u0887\\u0889-\\u088E\\u08A0-\\u08C9\\u0904-\\u0939\\u093D\\u0950\\u0958-\\u0961\\u0971-\\u0980\\u0985-\\u098C\\u098F\\u0990\\u0993-\\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\u0E84\\u0E86-\\u0E8A\\u0E8C-\\u0EA3\\u0EA5\\u0EA7-\\u0EB0\\u0EB2\\u0EB3\\u0EBD\\u0EC0-\\u0EC4\\u0EC6\\u0EDC-\\u0EDF\\u0F00\\u0F40-\\u0F47\\u0F49-\\u0F6C\\u0F88-\\u0F8C\\u1000-\\u102A\\u103F\\u1050-\\u1055\\u105A-\\u105D\\u1061\\u1065\\u1066\\u106E-\\u1070\\u1075-\\u1081\\u108E\\u10A0-\\u10C5\\u10C7\\u10CD\\u10D0-\\u10FA\\u10FC-\\u1248\\u124A-\\u124D\\u1250-\\u1256\\u1258\\u125A-\\u125D\\u1260-\\u1288\\u128A-\\u128D\\u1290-\\u12B0\\u12B2-\\u12B5\\u12B8-\\u12BE\\u12C0\\u12C2-\\u12C5\\u12C8-\\u12D6\\u12D8-\\u1310\\u1312-\\u1315\\u1318-\\u135A\\u1380-\\u138F\\u13A0-\\u13F5\\u13F8-\\u13FD\\u1401-\\u166C\\u166F-\\u167F\\u1681-\\u169A\\u16A0-\\u16EA\\u16F1-\\u16F8\\u1700-\\u1711\\u171F-\\u1731\\u1740-\\u1751\\u1760-\\u176C\\u176E-\\u1770\\u1780-\\u17B3\\u17D7\\u17DC\\u1820-\\u1878\\u1880-\\u1884\\u1887-\\u18A8\\u18AA\\u18B0-\\u18F5\\u1900-\\u191E\\u1950-\\u196D\\u1970-\\u1974\\u1980-\\u19AB\\u19B0-\\u19C9\\u1A00-\\u1A16\\u1A20-\\u1A54\\u1AA7\\u1B05-\\u1B33\\u1B45-\\u1B4C\\u1B83-\\u1BA0\\u1BAE\\u1BAF\\u1BBA-\\u1BE5\\u1C00-\\u1C23\\u1C4D-\\u1C4F\\u1C5A-\\u1C7D\\u1C80-\\u1C88\\u1C90-\\u1CBA\\u1CBD-\\u1CBF\\u1CE9-\\u1CEC\\u1CEE-\\u1CF3\\u1CF5\\u1CF6\\u1CFA\\u1D00-\\u1DBF\\u1E00-\\u1F15\\u1F18-\\u1F1D\\u1F20-\\u1F45\\u1F48-\\u1F4D\\u1F50-\\u1F57\\u1F59\\u1F5B\\u1F5D\\u1F5F-\\u1F7D\\u1F80-\\u1FB4\\u1FB6-\\u1FBC\\u1FBE\\u1FC2-\\u1FC4\\u1FC6-\\u1FCC\\u1FD0-\\u1FD3\\u1FD6-\\u1FDB\\u1FE0-\\u1FEC\\u1FF2-\\u1FF4\\u1FF6-\\u1FFC\\u2071\\u207F\\u2090-\\u209C\\u2102\\u2107\\u210A-\\u2113\\u2115\\u2119-\\u211D\\u2124\\u2126\\u2128\\u212A-\\u212D\\u212F-\\u2139\\u213C-\\u213F\\u2145-\\u2149\\u214E\\u2183\\u2184\\u2C00-\\u2CE4\\u2CEB-\\u2CEE\\u2CF2\\u2CF3\\u2D00-\\u2D25\\u2D27\\u2D2D\\u2D30-\\u2D67\\u2D6F\\u2D80-\\u2D96\\u2DA0-\\u2DA6\\u2DA8-\\u2DAE\\u2DB0-\\u2DB6\\u2DB8-\\u2DBE\\u2DC0-\\u2DC6\\u2DC8-\\u2DCE\\u2DD0-\\u2DD6\\u2DD8-\\u2DDE\\u2E2F\\u3005\\u3006\\u3031-\\u3035\\u303B\\u303C\\u3041-\\u3096\\u309D-\\u309F\\u30A1-\\u30FA\\u30FC-\\u30FF\\u3105-\\u312F\\u3131-\\u318E\\u31A0-\\u31BF\\u31F0-\\u31FF\\u3400-\\u4DBF\\u4E00-\\uA48C\\uA4D0-\\uA4FD\\uA500-\\uA60C\\uA610-\\uA61F\\uA62A\\uA62B\\uA640-\\uA66E\\uA67F-\\uA69D\\uA6A0-\\uA6E5\\uA717-\\uA71F\\uA722-\\uA788\\uA78B-\\uA7CA\\uA7D0\\uA7D1\\uA7D3\\uA7D5-\\uA7D9\\uA7F2-\\uA801\\uA803-\\uA805\\uA807-\\uA80A\\uA80C-\\uA822\\uA840-\\uA873\\uA882-\\uA8B3\\uA8F2-\\uA8F7\\uA8FB\\uA8FD\\uA8FE\\uA90A-\\uA925\\uA930-\\uA946\\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\uDF28\\uDF2A-\\uDF30\\uDF32\\uDF33\\uDF35-\\uDF39\\uDF3D\\uDF50\\uDF5D-\\uDF61]|\\uD805[\\uDC00-\\uDC34\\uDC47-\\uDC4A\\uDC5F-\\uDC61\\uDC80-\\uDCAF\\uDCC4\\uDCC5\\uDCC7\\uDD80-\\uDDAE\\uDDD8-\\uDDDB\\uDE00-\\uDE2F\\uDE44\\uDE80-\\uDEAA\\uDEB8\\uDF00-\\uDF1A\\uDF40-\\uDF46]|\\uD806[\\uDC00-\\uDC2B\\uDCA0-\\uDCDF\\uDCFF-\\uDD06\\uDD09\\uDD0C-\\uDD13\\uDD15\\uDD16\\uDD18-\\uDD2F\\uDD3F\\uDD41\\uDDA0-\\uDDA7\\uDDAA-\\uDDD0\\uDDE1\\uDDE3\\uDE00\\uDE0B-\\uDE32\\uDE3A\\uDE50\\uDE5C-\\uDE89\\uDE9D\\uDEB0-\\uDEF8]|\\uD807[\\uDC00-\\uDC08\\uDC0A-\\uDC2E\\uDC40\\uDC72-\\uDC8F\\uDD00-\\uDD06\\uDD08\\uDD09\\uDD0B-\\uDD30\\uDD46\\uDD60-\\uDD65\\uDD67\\uDD68\\uDD6A-\\uDD89\\uDD98\\uDEE0-\\uDEF2\\uDF02\\uDF04-\\uDF10\\uDF12-\\uDF33\\uDFB0]|\\uD808[\\uDC00-\\uDF99]|\\uD809[\\uDC80-\\uDD43]|\\uD80B[\\uDF90-\\uDFF0]|[\\uD80C\\uD81C-\\uD820\\uD822\\uD840-\\uD868\\uD86A-\\uD86C\\uD86F-\\uD872\\uD874-\\uD879\\uD880-\\uD883\\uD885-\\uD887][\\uDC00-\\uDFFF]|\\uD80D[\\uDC00-\\uDC2F\\uDC41-\\uDC46]|\\uD811[\\uDC00-\\uDE46]|\\uD81A[\\uDC00-\\uDE38\\uDE40-\\uDE5E\\uDE70-\\uDEBE\\uDED0-\\uDEED\\uDF00-\\uDF2F\\uDF40-\\uDF43\\uDF63-\\uDF77\\uDF7D-\\uDF8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E21\\uDE22\\uDE24\\uDE27\\uDE29-\\uDE32\\uDE34-\\uDE37\\uDE39\\uDE3B\\uDE42\\uDE47\\uDE49\\uDE4B\\uDE4D-\\uDE4F\\uDE51\\uDE52\\uDE54\\uDE57\\uDE59\\uDE5B\\uDE5D\\uDE5F\\uDE61\\uDE62\\uDE64\\uDE67-\\uDE6A\\uDE6C-\\uDE72\\uDE74-\\uDE77\\uDE79-\\uDE7C\\uDE7E\\uDE80-\\uDE89\\uDE8B-\\uDE9B\\uDEA1-\\uDEA3\\uDEA5-\\uDEA9\\uDEAB-\\uDEBB]|\\uD869[\\uDC00-\\uDEDF\\uDF00-\\uDFFF]|\\uD86D[\\uDC00-\\uDF39\\uDF40-\\uDFFF]|\\uD86E[\\uDC00-\\uDC1D\\uDC20-\\uDFFF]|\\uD873[\\uDC00-\\uDEA1\\uDEB0-\\uDFFF]|\\uD87A[\\uDC00-\\uDFE0\\uDFF0-\\uDFFF]|\\uD87B[\\uDC00-\\uDE5D]|\\uD87E[\\uDC00-\\uDE1D]|\\uD884[\\uDC00-\\uDF4A\\uDF50-\\uDFFF]|\\uD888[\\uDC00-\\uDFAF])/.test(val)) {\n return false;\n }\n return window.intlTelInputUtils ? intlTelInputUtils.isValidNumber(val, this.selectedCountryData.iso2) : null;\n }\n }, {\n key: \"setCountry\",\n value: function setCountry(iso2) {\n var iso2Lower = iso2.toLowerCase();\n // check if already selected\n if (this.selectedCountryData.iso2 !== iso2Lower) {\n this._setCountry(iso2Lower);\n this._updateDialCode(this.selectedCountryData.dialCode);\n this._triggerCountryChange();\n }\n }\n }, {\n key: \"setNumber\",\n value: function setNumber(number) {\n // we must update the flag first, which updates this.selectedCountryData, which is used for\n // formatting the number before displaying it\n var flagChanged = this._updateFlagFromNumber(number);\n this._updateValFromNumber(number);\n if (flagChanged) {\n this._triggerCountryChange();\n }\n }\n }, {\n key: \"setPlaceholderNumberType\",\n value: function setPlaceholderNumberType(type) {\n this.options.placeholderNumberType = type;\n this._updatePlaceholder();\n }\n } ]);\n return Iti;\n }();\n /********************\n * STATIC METHODS\n ********************/\n // get the country data object\n intlTelInputGlobals.getCountryData = function() {\n return allCountries;\n };\n // inject a <script> element to load utils.js\n var injectScript = function injectScript(path, handleSuccess, handleFailure) {\n // inject a new script element into the page\n var script = document.createElement(\"script\");\n script.onload = function() {\n forEachInstance(\"handleUtils\");\n if (handleSuccess) {\n handleSuccess();\n }\n };\n script.onerror = function() {\n forEachInstance(\"rejectUtilsScriptPromise\");\n if (handleFailure) {\n handleFailure();\n }\n };\n script.className = \"iti-load-utils\";\n script.async = true;\n script.src = path;\n document.body.appendChild(script);\n };\n // load the utils script\n intlTelInputGlobals.loadUtils = function(path) {\n // 2 options:\n // 1) not already started loading (start)\n // 2) already started loading (do nothing - just wait for the onload callback to fire, which will\n // trigger handleUtils on all instances, invoking their resolveUtilsScriptPromise functions)\n if (!window.intlTelInputUtils && !window.intlTelInputGlobals.startedLoadingUtilsScript) {\n // only do this once\n window.intlTelInputGlobals.startedLoadingUtilsScript = true;\n return new Promise(function(resolve, reject) {\n return injectScript(path, resolve, reject);\n });\n }\n return null;\n };\n // default options\n intlTelInputGlobals.defaults = defaults;\n // version\n intlTelInputGlobals.version = \"20.1.0\";\n // convenience wrapper\n return function(input, options) {\n var iti = new Iti(input, options);\n iti._init();\n input.setAttribute(\"data-intl-tel-input-id\", iti.id);\n window.intlTelInputGlobals.instances[iti.id] = iti;\n return iti;\n };\n }();\n});", "/* eslint-disable react/forbid-prop-types */\n/* eslint-disable react/jsx-filename-extension */\n/* eslint-disable import/no-extraneous-dependencies */\nimport React, { useRef, useEffect } from 'react';\nimport PropTypes from 'prop-types';\nimport intlTelInput from \"../../build/js/intlTelInput\";\n\nconst IntlTelInput = ({\n initialValue,\n onChangeNumber,\n onChangeCountry,\n onChangeValidity,\n onChangeErrorCode,\n usePreciseValidation,\n initOptions,\n className,\n disabled,\n onFocus,\n onBlur,\n placeholder,\n inputProps,\n}) => {\n const inputRef = useRef(null);\n const itiRef = useRef(null);\n \n const update = () => {\n const num = itiRef.current.getNumber();\n const countryIso = itiRef.current.getSelectedCountryData().iso2;\n // note: this number will be in standard E164 format, but any container component can use\n // intlTelInputUtils.formatNumber() to convert this to another format\n // as well as intlTelInputUtils.getNumberType() etc. if need be\n onChangeNumber(num);\n onChangeCountry(countryIso);\n\n const isValid = usePreciseValidation ? itiRef.current.isValidNumberPrecise() : itiRef.current.isValidNumber();\n if (isValid) {\n onChangeValidity(true);\n onChangeErrorCode(null);\n } else {\n const errorCode = itiRef.current.getValidationError();\n onChangeValidity(false);\n onChangeErrorCode(errorCode);\n }\n };\n \n useEffect(() => {\n // store a reference to the current input ref, which otherwise is already lost in the cleanup function\n const inputRefCurrent = inputRef.current;\n itiRef.current = intlTelInput(inputRef.current, initOptions);\n inputRefCurrent.addEventListener(\"countrychange\", update);\n return () => {\n inputRefCurrent.removeEventListener(\"countrychange\", update);\n itiRef.current.destroy();\n };\n }, []);\n \n return (\n <input\n type=\"tel\"\n ref={inputRef}\n onInput={update}\n defaultValue={initialValue}\n className={className}\n disabled={disabled}\n onFocus={onFocus}\n onBlur={onBlur}\n placeholder={placeholder}\n {...inputProps}\n />\n );\n};\n\nIntlTelInput.propTypes = {\n initialValue: PropTypes.string,\n placeholder: PropTypes.string,\n onChangeNumber: PropTypes.func,\n onChangeCountry: PropTypes.func,\n onChangeValidity: PropTypes.func,\n onChangeErrorCode: PropTypes.func,\n usePreciseValidation: PropTypes.bool,\n initOptions: PropTypes.shape({\n allowDropdown: PropTypes.bool,\n autoPlaceholder: PropTypes.string,\n containerClass: PropTypes.string,\n countrySearch: PropTypes.bool,\n customPlaceholder: PropTypes.func,\n dropdownContainer: PropTypes.node,\n excludeCountries: PropTypes.arrayOf(PropTypes.string),\n fixDropdownWidth: PropTypes.bool,\n formatAsYouType: PropTypes.bool,\n formatOnDisplay: PropTypes.bool,\n geoIpLookup: PropTypes.func,\n hiddenInput: PropTypes.func,\n i18n: PropTypes.objectOf(PropTypes.string),\n initialCountry: PropTypes.string,\n nationalMode: PropTypes.bool,\n onlyCountries: PropTypes.arrayOf(PropTypes.string),\n placeholderNumberType: PropTypes.string,\n preferredCountries: PropTypes.arrayOf(PropTypes.string),\n showFlags: PropTypes.bool,\n showSelectedDialCode: PropTypes.bool,\n useFullscreenPopup: PropTypes.bool,\n utilsScript: PropTypes.string,\n }),\n className: PropTypes.string,\n disabled: PropTypes.bool,\n onFocus: PropTypes.func,\n onBlur: PropTypes.func,\n inputProps: PropTypes.object,\n};\n\nIntlTelInput.defaultProps = {\n initialValue: \"\",\n placeholder: \"\",\n onChangeNumber: () => {},\n onChangeCountry: () => {},\n onChangeValidity: () => {},\n onChangeErrorCode: () => {},\n usePreciseValidation: false,\n initOptions: {},\n className: \"\",\n disabled: false,\n onFocus: () => {},\n onBlur: () => {},\n inputProps: {},\n};\n\nexport default IntlTelInput;"],
|
|
5
|
-
"mappings": "ihBAAA,IAAAA,EAAAC,GAAA,CAAAC,GAAAC,IAAA,EAOC,SAASC,EAAS,CACX,OAAOD,GAAW,UAAYA,EAAO,QAASA,EAAO,QAAUC,EAAQ,EAAQ,OAAO,aAAeA,EAAQ,CACrH,GAAG,SAASC,EAAW,CACnB,aACA,OAAO,UAAW,CAiBd,QAFIC,EAAe,CAAE,CAAE,cAAe,KAAM,IAAK,EAAG,CAAE,UAAW,KAAM,KAAM,EAAG,CAAE,UAAW,KAAM,KAAM,EAAG,CAAE,iBAAkB,KAAM,IAAK,EAAG,CAAE,KAAM,CAAE,EAAG,CAAE,UAAW,KAAM,KAAM,EAAG,CAAE,SAAU,KAAM,KAAM,EAAG,CAAE,WAAY,KAAM,IAAK,EAAG,CAAE,KAAM,CAAE,EAAG,CAAE,oBAAqB,KAAM,IAAK,EAAG,CAAE,KAAM,CAAE,EAAG,CAAE,YAAa,KAAM,IAAK,EAAG,CAAE,UAAW,KAAM,KAAM,EAAG,CAAE,QAAS,KAAM,KAAM,EAAG,CAAE,mBAAoB,KAAM,KAAM,EAAG,CAA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AkB,IAAM,CAAC,EACzB,kBAAmB,IAAM,CAAC,EAC1B,qBAAsB,GACtB,YAAa,CAAC,EACd,UAAW,GACX,SAAU,GACV,QAAS,IAAM,CAAC,EAChB,OAAQ,IAAM,CAAC,EACf,WAAY,CAAC,CACf,EAEA,IAAOsB,GAAQtB",
|
|
6
|
-
"names": ["require_intlTelInput", "__commonJSMin", "exports", "module", "factory", "undefined", "allCountries", "i", "c", "
|
|
4
|
+
"sourcesContent": ["/*\n * International Telephone Input v20.3.0\n * https://github.com/jackocnr/intl-tel-input.git\n * Licensed under the MIT license\n */\n// wrap in UMD\n(function(factory) {\n if (typeof module === \"object\" && module.exports) module.exports = factory(); else window.intlTelInput = factory();\n})(function(undefined) {\n \"use strict\";\n return function() {\n // Array of country objects for the flag dropdown.\n // Here is the criteria for the plugin to support a given country/territory\n // - It has an iso2 code: https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2\n // - It has it's own country calling code (it is not a sub-region of another country): https://en.wikipedia.org/wiki/List_of_country_calling_codes\n // - It has a flag in the region-flags project: https://github.com/behdad/region-flags/tree/gh-pages/png\n // - It is supported by libphonenumber (it must be listed on this page): https://github.com/googlei18n/libphonenumber/blob/master/resources/ShortNumberMetadata.xml\n // Each country array has the following information:\n // [\n // Country name,\n // iso2 code,\n // International dial code,\n // Order (if >1 country with same dial code),\n // Area codes\n // ]\n var allCountries = [ [ \"Afghanistan\", \"af\", \"93\" ], [ \"Albania\", \"al\", \"355\" ], [ \"Algeria\", \"dz\", \"213\" ], [ \"American Samoa\", \"as\", \"1\", 5, [ \"684\" ] ], [ \"Andorra\", \"ad\", \"376\" ], [ \"Angola\", \"ao\", \"244\" ], [ \"Anguilla\", \"ai\", \"1\", 6, [ \"264\" ] ], [ \"Antigua & Barbuda\", \"ag\", \"1\", 7, [ \"268\" ] ], [ \"Argentina\", \"ar\", \"54\" ], [ \"Armenia\", \"am\", \"374\" ], [ \"Aruba\", \"aw\", \"297\" ], [ \"Ascension Island\", \"ac\", \"247\" ], [ \"Australia\", \"au\", \"61\", 0 ], [ \"Austria\", \"at\", \"43\" ], [ \"Azerbaijan\", \"az\", \"994\" ], [ \"Bahamas\", \"bs\", \"1\", 8, [ \"242\" ] ], [ \"Bahrain\", \"bh\", \"973\" ], [ \"Bangladesh\", \"bd\", \"880\" ], [ \"Barbados\", \"bb\", \"1\", 9, [ \"246\" ] ], [ \"Belarus\", \"by\", \"375\" ], [ \"Belgium\", \"be\", \"32\" ], [ \"Belize\", \"bz\", \"501\" ], [ \"Benin\", \"bj\", \"229\" ], [ \"Bermuda\", \"bm\", \"1\", 10, [ \"441\" ] ], [ \"Bhutan\", \"bt\", \"975\" ], [ \"Bolivia\", \"bo\", \"591\" ], [ \"Bosnia & Herzegovina\", \"ba\", \"387\" ], [ \"Botswana\", \"bw\", \"267\" ], [ \"Brazil\", \"br\", \"55\" ], [ \"British Indian Ocean Territory\", \"io\", \"246\" ], [ \"British Virgin Islands\", \"vg\", \"1\", 11, [ \"284\" ] ], [ \"Brunei\", \"bn\", \"673\" ], [ \"Bulgaria\", \"bg\", \"359\" ], [ \"Burkina Faso\", \"bf\", \"226\" ], [ \"Burundi\", \"bi\", \"257\" ], [ \"Cambodia\", \"kh\", \"855\" ], [ \"Cameroon\", \"cm\", \"237\" ], [ \"Canada\", \"ca\", \"1\", 1, [ \"204\", \"226\", \"236\", \"249\", \"250\", \"263\", \"289\", \"306\", \"343\", \"354\", \"365\", \"367\", \"368\", \"382\", \"387\", \"403\", \"416\", \"418\", \"428\", \"431\", \"437\", \"438\", \"450\", \"584\", \"468\", \"474\", \"506\", \"514\", \"519\", \"548\", \"579\", \"581\", \"584\", \"587\", \"604\", \"613\", \"639\", \"647\", \"672\", \"683\", \"705\", \"709\", \"742\", \"753\", \"778\", \"780\", \"782\", \"807\", \"819\", \"825\", \"867\", \"873\", \"902\", \"905\" ] ], [ \"Cape Verde\", \"cv\", \"238\" ], [ \"Caribbean Netherlands\", \"bq\", \"599\", 1, [ \"3\", \"4\", \"7\" ] ], [ \"Cayman Islands\", \"ky\", \"1\", 12, [ \"345\" ] ], [ \"Central African Republic\", \"cf\", \"236\" ], [ \"Chad\", \"td\", \"235\" ], [ \"Chile\", \"cl\", \"56\" ], [ \"China\", \"cn\", \"86\" ], [ \"Christmas Island\", \"cx\", \"61\", 2, [ \"89164\" ] ], [ \"Cocos (Keeling) Islands\", \"cc\", \"61\", 1, [ \"89162\" ] ], [ \"Colombia\", \"co\", \"57\" ], [ \"Comoros\", \"km\", \"269\" ], [ \"Congo - Brazzaville\", \"cg\", \"242\" ], [ \"Congo - Kinshasa\", \"cd\", \"243\" ], [ \"Cook Islands\", \"ck\", \"682\" ], [ \"Costa Rica\", \"cr\", \"506\" ], [ \"C\u00F4te d\u2019Ivoire\", \"ci\", \"225\" ], [ \"Croatia\", \"hr\", \"385\" ], [ \"Cuba\", \"cu\", \"53\" ], [ \"Cura\u00E7ao\", \"cw\", \"599\", 0 ], [ \"Cyprus\", \"cy\", \"357\" ], [ \"Czech Republic\", \"cz\", \"420\" ], [ \"Denmark\", \"dk\", \"45\" ], [ \"Djibouti\", \"dj\", \"253\" ], [ \"Dominica\", \"dm\", \"1\", 13, [ \"767\" ] ], [ \"Dominican Republic\", \"do\", \"1\", 2, [ \"809\", \"829\", \"849\" ] ], [ \"Ecuador\", \"ec\", \"593\" ], [ \"Egypt\", \"eg\", \"20\" ], [ \"El Salvador\", \"sv\", \"503\" ], [ \"Equatorial Guinea\", \"gq\", \"240\" ], [ \"Eritrea\", \"er\", \"291\" ], [ \"Estonia\", \"ee\", \"372\" ], [ \"Eswatini\", \"sz\", \"268\" ], [ \"Ethiopia\", \"et\", \"251\" ], [ \"Falkland Islands\", \"fk\", \"500\" ], [ \"Faroe Islands\", \"fo\", \"298\" ], [ \"Fiji\", \"fj\", \"679\" ], [ \"Finland\", \"fi\", \"358\", 0 ], [ \"France\", \"fr\", \"33\" ], [ \"French Guiana\", \"gf\", \"594\" ], [ \"French Polynesia\", \"pf\", \"689\" ], [ \"Gabon\", \"ga\", \"241\" ], [ \"Gambia\", \"gm\", \"220\" ], [ \"Georgia\", \"ge\", \"995\" ], [ \"Germany\", \"de\", \"49\" ], [ \"Ghana\", \"gh\", \"233\" ], [ \"Gibraltar\", \"gi\", \"350\" ], [ \"Greece\", \"gr\", \"30\" ], [ \"Greenland\", \"gl\", \"299\" ], [ \"Grenada\", \"gd\", \"1\", 14, [ \"473\" ] ], [ \"Guadeloupe\", \"gp\", \"590\", 0 ], [ \"Guam\", \"gu\", \"1\", 15, [ \"671\" ] ], [ \"Guatemala\", \"gt\", \"502\" ], [ \"Guernsey\", \"gg\", \"44\", 1, [ \"1481\", \"7781\", \"7839\", \"7911\" ] ], [ \"Guinea\", \"gn\", \"224\" ], [ \"Guinea-Bissau\", \"gw\", \"245\" ], [ \"Guyana\", \"gy\", \"592\" ], [ \"Haiti\", \"ht\", \"509\" ], [ \"Honduras\", \"hn\", \"504\" ], [ \"Hong Kong\", \"hk\", \"852\" ], [ \"Hungary\", \"hu\", \"36\" ], [ \"Iceland\", \"is\", \"354\" ], [ \"India\", \"in\", \"91\" ], [ \"Indonesia\", \"id\", \"62\" ], [ \"Iran\", \"ir\", \"98\" ], [ \"Iraq\", \"iq\", \"964\" ], [ \"Ireland\", \"ie\", \"353\" ], [ \"Isle of Man\", \"im\", \"44\", 2, [ \"1624\", \"74576\", \"7524\", \"7924\", \"7624\" ] ], [ \"Israel\", \"il\", \"972\" ], [ \"Italy\", \"it\", \"39\", 0 ], [ \"Jamaica\", \"jm\", \"1\", 4, [ \"876\", \"658\" ] ], [ \"Japan\", \"jp\", \"81\" ], [ \"Jersey\", \"je\", \"44\", 3, [ \"1534\", \"7509\", \"7700\", \"7797\", \"7829\", \"7937\" ] ], [ \"Jordan\", \"jo\", \"962\" ], [ \"Kazakhstan\", \"kz\", \"7\", 1, [ \"33\", \"7\" ] ], [ \"Kenya\", \"ke\", \"254\" ], [ \"Kiribati\", \"ki\", \"686\" ], [ \"Kosovo\", \"xk\", \"383\" ], [ \"Kuwait\", \"kw\", \"965\" ], [ \"Kyrgyzstan\", \"kg\", \"996\" ], [ \"Laos\", \"la\", \"856\" ], [ \"Latvia\", \"lv\", \"371\" ], [ \"Lebanon\", \"lb\", \"961\" ], [ \"Lesotho\", \"ls\", \"266\" ], [ \"Liberia\", \"lr\", \"231\" ], [ \"Libya\", \"ly\", \"218\" ], [ \"Liechtenstein\", \"li\", \"423\" ], [ \"Lithuania\", \"lt\", \"370\" ], [ \"Luxembourg\", \"lu\", \"352\" ], [ \"Macau\", \"mo\", \"853\" ], [ \"Madagascar\", \"mg\", \"261\" ], [ \"Malawi\", \"mw\", \"265\" ], [ \"Malaysia\", \"my\", \"60\" ], [ \"Maldives\", \"mv\", \"960\" ], [ \"Mali\", \"ml\", \"223\" ], [ \"Malta\", \"mt\", \"356\" ], [ \"Marshall Islands\", \"mh\", \"692\" ], [ \"Martinique\", \"mq\", \"596\" ], [ \"Mauritania\", \"mr\", \"222\" ], [ \"Mauritius\", \"mu\", \"230\" ], [ \"Mayotte\", \"yt\", \"262\", 1, [ \"269\", \"639\" ] ], [ \"Mexico\", \"mx\", \"52\" ], [ \"Micronesia\", \"fm\", \"691\" ], [ \"Moldova\", \"md\", \"373\" ], [ \"Monaco\", \"mc\", \"377\" ], [ \"Mongolia\", \"mn\", \"976\" ], [ \"Montenegro\", \"me\", \"382\" ], [ \"Montserrat\", \"ms\", \"1\", 16, [ \"664\" ] ], [ \"Morocco\", \"ma\", \"212\", 0 ], [ \"Mozambique\", \"mz\", \"258\" ], [ \"Myanmar (Burma)\", \"mm\", \"95\" ], [ \"Namibia\", \"na\", \"264\" ], [ \"Nauru\", \"nr\", \"674\" ], [ \"Nepal\", \"np\", \"977\" ], [ \"Netherlands\", \"nl\", \"31\" ], [ \"New Caledonia\", \"nc\", \"687\" ], [ \"New Zealand\", \"nz\", \"64\" ], [ \"Nicaragua\", \"ni\", \"505\" ], [ \"Niger\", \"ne\", \"227\" ], [ \"Nigeria\", \"ng\", \"234\" ], [ \"Niue\", \"nu\", \"683\" ], [ \"Norfolk Island\", \"nf\", \"672\" ], [ \"North Korea\", \"kp\", \"850\" ], [ \"North Macedonia\", \"mk\", \"389\" ], [ \"Northern Mariana Islands\", \"mp\", \"1\", 17, [ \"670\" ] ], [ \"Norway\", \"no\", \"47\", 0 ], [ \"Oman\", \"om\", \"968\" ], [ \"Pakistan\", \"pk\", \"92\" ], [ \"Palau\", \"pw\", \"680\" ], [ \"Palestine\", \"ps\", \"970\" ], [ \"Panama\", \"pa\", \"507\" ], [ \"Papua New Guinea\", \"pg\", \"675\" ], [ \"Paraguay\", \"py\", \"595\" ], [ \"Peru\", \"pe\", \"51\" ], [ \"Philippines\", \"ph\", \"63\" ], [ \"Poland\", \"pl\", \"48\" ], [ \"Portugal\", \"pt\", \"351\" ], [ \"Puerto Rico\", \"pr\", \"1\", 3, [ \"787\", \"939\" ] ], [ \"Qatar\", \"qa\", \"974\" ], [ \"R\u00E9union\", \"re\", \"262\", 0 ], [ \"Romania\", \"ro\", \"40\" ], [ \"Russia\", \"ru\", \"7\", 0 ], [ \"Rwanda\", \"rw\", \"250\" ], [ \"Samoa\", \"ws\", \"685\" ], [ \"San Marino\", \"sm\", \"378\" ], [ \"S\u00E3o Tom\u00E9 & Pr\u00EDncipe\", \"st\", \"239\" ], [ \"Saudi Arabia\", \"sa\", \"966\" ], [ \"Senegal\", \"sn\", \"221\" ], [ \"Serbia\", \"rs\", \"381\" ], [ \"Seychelles\", \"sc\", \"248\" ], [ \"Sierra Leone\", \"sl\", \"232\" ], [ \"Singapore\", \"sg\", \"65\" ], [ \"Sint Maarten\", \"sx\", \"1\", 21, [ \"721\" ] ], [ \"Slovakia\", \"sk\", \"421\" ], [ \"Slovenia\", \"si\", \"386\" ], [ \"Solomon Islands\", \"sb\", \"677\" ], [ \"Somalia\", \"so\", \"252\" ], [ \"South Africa\", \"za\", \"27\" ], [ \"South Korea\", \"kr\", \"82\" ], [ \"South Sudan\", \"ss\", \"211\" ], [ \"Spain\", \"es\", \"34\" ], [ \"Sri Lanka\", \"lk\", \"94\" ], [ \"St Barth\u00E9lemy\", \"bl\", \"590\", 1 ], [ \"St Helena\", \"sh\", \"290\" ], [ \"St Kitts & Nevis\", \"kn\", \"1\", 18, [ \"869\" ] ], [ \"St Lucia\", \"lc\", \"1\", 19, [ \"758\" ] ], [ \"St Martin\", \"mf\", \"590\", 2 ], [ \"St Pierre & Miquelon\", \"pm\", \"508\" ], [ \"St Vincent & Grenadines\", \"vc\", \"1\", 20, [ \"784\" ] ], [ \"Sudan\", \"sd\", \"249\" ], [ \"Suriname\", \"sr\", \"597\" ], [ \"Svalbard & Jan Mayen\", \"sj\", \"47\", 1, [ \"79\" ] ], [ \"Sweden\", \"se\", \"46\" ], [ \"Switzerland\", \"ch\", \"41\" ], [ \"Syria\", \"sy\", \"963\" ], [ \"Taiwan\", \"tw\", \"886\" ], [ \"Tajikistan\", \"tj\", \"992\" ], [ \"Tanzania\", \"tz\", \"255\" ], [ \"Thailand\", \"th\", \"66\" ], [ \"Timor-Leste\", \"tl\", \"670\" ], [ \"Togo\", \"tg\", \"228\" ], [ \"Tokelau\", \"tk\", \"690\" ], [ \"Tonga\", \"to\", \"676\" ], [ \"Trinidad & Tobago\", \"tt\", \"1\", 22, [ \"868\" ] ], [ \"Tunisia\", \"tn\", \"216\" ], [ \"Turkey\", \"tr\", \"90\" ], [ \"Turkmenistan\", \"tm\", \"993\" ], [ \"Turks & Caicos Islands\", \"tc\", \"1\", 23, [ \"649\" ] ], [ \"Tuvalu\", \"tv\", \"688\" ], [ \"Uganda\", \"ug\", \"256\" ], [ \"Ukraine\", \"ua\", \"380\" ], [ \"United Arab Emirates\", \"ae\", \"971\" ], [ \"United Kingdom\", \"gb\", \"44\", 0 ], [ \"United States\", \"us\", \"1\", 0 ], [ \"Uruguay\", \"uy\", \"598\" ], [ \"US Virgin Islands\", \"vi\", \"1\", 24, [ \"340\" ] ], [ \"Uzbekistan\", \"uz\", \"998\" ], [ \"Vanuatu\", \"vu\", \"678\" ], [ \"Vatican City\", \"va\", \"39\", 1, [ \"06698\" ] ], [ \"Venezuela\", \"ve\", \"58\" ], [ \"Vietnam\", \"vn\", \"84\" ], [ \"Wallis & Futuna\", \"wf\", \"681\" ], [ \"Western Sahara\", \"eh\", \"212\", 1, [ \"5288\", \"5289\" ] ], [ \"Yemen\", \"ye\", \"967\" ], [ \"Zambia\", \"zm\", \"260\" ], [ \"Zimbabwe\", \"zw\", \"263\" ], [ \"\u00C5land Islands\", \"ax\", \"358\", 1, [ \"18\" ] ] ];\n // loop over all of the countries above, restructuring the data to be objects with named keys\n for (var i = 0; i < allCountries.length; i++) {\n var c = allCountries[i];\n allCountries[i] = {\n name: c[0],\n iso2: c[1],\n dialCode: c[2],\n priority: c[3] || 0,\n areaCodes: c[4] || null,\n nodeById: {}\n };\n }\n const intlTelInputGlobals = {\n getInstance: input => {\n const id = input.getAttribute(\"data-intl-tel-input-id\");\n return window.intlTelInputGlobals.instances[id];\n },\n instances: {},\n // using a global like this allows us to mock it in the tests\n documentReady: () => document.readyState === \"complete\"\n };\n if (typeof window === \"object\") {\n window.intlTelInputGlobals = intlTelInputGlobals;\n }\n // these vars persist through all instances of the plugin\n let id = 0;\n const defaults = {\n // whether or not to allow the dropdown\n allowDropdown: true,\n // add a placeholder in the input with an example number for the selected country\n autoPlaceholder: \"polite\",\n // add a country search input at the top of the dropdown\n countrySearch: true,\n // modify the parentClass\n containerClass: \"\",\n // modify the auto placeholder\n customPlaceholder: null,\n // append menu to specified element\n dropdownContainer: null,\n // don't display these countries\n excludeCountries: [],\n // fix the dropdown width to the input width (rather than being as wide as the longest country name)\n fixDropdownWidth: true,\n // format the number as the user types\n formatAsYouType: true,\n // format the input value during initialisation and on setNumber\n formatOnDisplay: true,\n // geoIp lookup function\n geoIpLookup: null,\n // inject a hidden input with the name returned from this function, and on submit, populate it with the result of getNumber\n hiddenInput: null,\n // internationalise the plugin text e.g. search input placeholder, country names\n i18n: {},\n // initial country\n initialCountry: \"\",\n // national vs international formatting for numbers e.g. placeholders and displaying existing numbers\n nationalMode: true,\n // display only these countries\n onlyCountries: [],\n // number type to use for placeholders\n placeholderNumberType: \"MOBILE\",\n // the countries at the top of the list\n preferredCountries: [],\n // option to hide the flags - must be used with showSelectedDialCode, or allowDropdown=false\n showFlags: true,\n // display the international dial code next to the selected flag\n showSelectedDialCode: false,\n // only allow certain chars e.g. a plus followed by numeric digits, and cap at max valid length\n strictMode: false,\n // use full screen popup instead of dropdown for country list\n useFullscreenPopup: typeof navigator !== \"undefined\" && typeof window !== \"undefined\" ? // we cannot just test screen size as some smartphones/website meta tags will report desktop\n // resolutions\n // Note: to target Android Mobiles (and not Tablets), we must find 'Android' and 'Mobile'\n /Android.+Mobile|webOS|iPhone|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent) || window.innerWidth <= 500 : false,\n // specify the path to the libphonenumber script to enable validation/formatting\n utilsScript: \"\"\n };\n // https://en.wikipedia.org/wiki/List_of_North_American_Numbering_Plan_area_codes#Non-geographic_area_codes\n const regionlessNanpNumbers = [ \"800\", \"822\", \"833\", \"844\", \"855\", \"866\", \"877\", \"880\", \"881\", \"882\", \"883\", \"884\", \"885\", \"886\", \"887\", \"888\", \"889\" ];\n // run a method on each instance of the plugin\n const forEachInstance = method => {\n const {\n instances\n } = window.intlTelInputGlobals;\n Object.values(instances).forEach(instance => instance[method]());\n };\n // this is our plugin class that we will create an instance of\n // eslint-disable-next-line no-unused-vars\n class Iti {\n constructor(input, customOptions = {}) {\n this.id = id++;\n this.telInput = input;\n this.activeItem = null;\n this.highlightedItem = null;\n // process specified options / defaults\n this.options = Object.assign({}, defaults, customOptions);\n this.hadInitialPlaceholder = Boolean(input.getAttribute(\"placeholder\"));\n }\n _init() {\n // if showing fullscreen popup, do not fix the width\n if (this.options.useFullscreenPopup) {\n this.options.fixDropdownWidth = false;\n }\n // when search enabled, we must fix the width else it would change with different results\n if (this.options.countrySearch && !this.options.useFullscreenPopup) {\n this.options.fixDropdownWidth = true;\n }\n // force showFlags=true if there's a dropdown and we're not displaying the dial code,\n // as otherwise you just have a down arrow on it's own which doesn't make sense\n const forceShowFlags = this.options.allowDropdown && !this.options.showSelectedDialCode;\n if (!this.options.showFlags && forceShowFlags) {\n this.options.showFlags = true;\n }\n // on mobile, we want a full screen dropdown, so we must append it to the body\n if (this.options.useFullscreenPopup && !this.options.dropdownContainer) {\n this.options.dropdownContainer = document.body;\n }\n // check if input has one parent with RTL\n this.isRTL = !!this.telInput.closest(\"[dir=rtl]\");\n // these promises get resolved when their individual requests complete\n // this way the dev can do something like iti.promise.then(...) to know when all requests are\n // complete\n const autoCountryPromise = new Promise((resolve, reject) => {\n this.resolveAutoCountryPromise = resolve;\n this.rejectAutoCountryPromise = reject;\n });\n const utilsScriptPromise = new Promise((resolve, reject) => {\n this.resolveUtilsScriptPromise = resolve;\n this.rejectUtilsScriptPromise = reject;\n });\n this.promise = Promise.all([ autoCountryPromise, utilsScriptPromise ]);\n // in various situations there could be no country selected initially, but we need to be able\n // to assume this variable exists\n this.selectedCountryData = {};\n // process all the data: onlyCountries, excludeCountries, preferredCountries etc\n this._processCountryData();\n // generate the markup\n this._generateMarkup();\n // set the initial state of the input value and the selected flag\n this._setInitialState();\n // start all of the event listeners: input keydown, selectedFlag click\n this._initListeners();\n // utils script, and auto country\n this._initRequests();\n }\n /********************\n * PRIVATE METHODS\n ********************/\n // prepare all of the country data, including onlyCountries, excludeCountries and\n // preferredCountries options\n _processCountryData() {\n // process onlyCountries or excludeCountries array if present\n this._processAllCountries();\n // generate this.dialCodes and this.dialCodeToIso2Map\n this._processDialCodes();\n // process the preferredCountries\n this._processPreferredCountries();\n // translate country names according to i18n option\n this._translateCountryNames();\n // sort countries by name\n if (this.options.onlyCountries.length || this.options.i18n) {\n this.countries.sort(this._countryNameSort);\n }\n }\n // add a dial code to this.dialCodeToIso2Map\n _addToDialCodeMap(iso2, dialCode, priority) {\n if (dialCode.length > this.dialCodeMaxLen) {\n this.dialCodeMaxLen = dialCode.length;\n }\n if (!this.dialCodeToIso2Map.hasOwnProperty(dialCode)) {\n this.dialCodeToIso2Map[dialCode] = [];\n }\n // bail if we already have this country for this dialCode\n for (let i = 0; i < this.dialCodeToIso2Map[dialCode].length; i++) {\n if (this.dialCodeToIso2Map[dialCode][i] === iso2) {\n return;\n }\n }\n // check for undefined as 0 is falsy\n const index = priority !== undefined ? priority : this.dialCodeToIso2Map[dialCode].length;\n this.dialCodeToIso2Map[dialCode][index] = iso2;\n }\n // process onlyCountries or excludeCountries array if present\n _processAllCountries() {\n if (this.options.onlyCountries.length) {\n const lowerCaseOnlyCountries = this.options.onlyCountries.map(country => country.toLowerCase());\n this.countries = allCountries.filter(country => lowerCaseOnlyCountries.indexOf(country.iso2) > -1);\n } else if (this.options.excludeCountries.length) {\n const lowerCaseExcludeCountries = this.options.excludeCountries.map(country => country.toLowerCase());\n this.countries = allCountries.filter(country => lowerCaseExcludeCountries.indexOf(country.iso2) === -1);\n } else {\n this.countries = allCountries;\n }\n }\n // Translate Countries by object literal provided on config\n _translateCountryNames() {\n for (let i = 0; i < this.countries.length; i++) {\n const iso2 = this.countries[i].iso2.toLowerCase();\n if (this.options.i18n.hasOwnProperty(iso2)) {\n this.countries[i].name = this.options.i18n[iso2];\n }\n }\n }\n // sort by country name\n _countryNameSort(a, b) {\n if (a.name < b.name) {\n return -1;\n }\n if (a.name > b.name) {\n return 1;\n }\n return 0;\n }\n // generate this.dialCodes and this.dialCodeToIso2Map\n _processDialCodes() {\n // here we store just dial codes, where the key is the dial code, and the value is true\n // e.g. { 1: true, 7: true, 20: true, ... }\n this.dialCodes = {};\n this.dialCodeMaxLen = 0;\n // here we map dialCodes (inc both dialCode and dialCode+areaCode) to iso2 codes\n /* e.g.\n * {\n * 1: [ 'us', 'ca', ... ], # all NANP countries\n * 12: [ 'us', 'ca', ... ], # subset of NANP countries\n * 120: [ 'us', 'ca' ], # just US and Canada\n * 1204: [ 'ca' ], # only Canada\n * ...\n * }\n */\n this.dialCodeToIso2Map = {};\n // first: add dial codes\n for (let i = 0; i < this.countries.length; i++) {\n const c = this.countries[i];\n if (!this.dialCodes[c.dialCode]) {\n this.dialCodes[c.dialCode] = true;\n }\n this._addToDialCodeMap(c.iso2, c.dialCode, c.priority);\n }\n // next: add area codes\n // this is a second loop over countries, to make sure we have all of the \"root\" countries\n // already in the map, so that we can access them, as each time we add an area code substring\n // to the map, we also need to include the \"root\" country's code, as that also matches\n for (let i = 0; i < this.countries.length; i++) {\n const c = this.countries[i];\n // area codes\n if (c.areaCodes) {\n const rootIso2Code = this.dialCodeToIso2Map[c.dialCode][0];\n // for each area code\n for (let j = 0; j < c.areaCodes.length; j++) {\n const areaCode = c.areaCodes[j];\n // for each digit in the area code to add all partial matches as well\n for (let k = 1; k < areaCode.length; k++) {\n const partialDialCode = c.dialCode + areaCode.substr(0, k);\n // start with the root country, as that also matches this dial code\n this._addToDialCodeMap(rootIso2Code, partialDialCode);\n this._addToDialCodeMap(c.iso2, partialDialCode);\n }\n // add the full area code\n this._addToDialCodeMap(c.iso2, c.dialCode + areaCode);\n }\n }\n }\n }\n // process preferred countries - iterate through the preferences, fetching the country data for\n // each one\n _processPreferredCountries() {\n this.preferredCountries = [];\n for (let i = 0; i < this.options.preferredCountries.length; i++) {\n const iso2 = this.options.preferredCountries[i].toLowerCase();\n const countryData = this._getCountryData(iso2, true);\n if (countryData) {\n this.preferredCountries.push(countryData);\n }\n }\n }\n // create a DOM element\n _createEl(name, attrs, container) {\n const el = document.createElement(name);\n if (attrs) {\n Object.entries(attrs).forEach(([ key, value ]) => el.setAttribute(key, value));\n }\n if (container) {\n container.appendChild(el);\n }\n return el;\n }\n // generate all of the markup for the plugin: the selected flag overlay, and the dropdown\n _generateMarkup() {\n this.telInput.classList.add(\"iti__tel-input\");\n // if autocomplete does not exist on the element and its form, then\n // prevent autocomplete as there's no safe, cross-browser event we can react to, so it can\n // easily put the plugin in an inconsistent state e.g. the wrong flag selected for the\n // autocompleted number, which on submit could mean wrong number is saved\n if (!this.telInput.hasAttribute(\"autocomplete\") && !(this.telInput.form && this.telInput.form.hasAttribute(\"autocomplete\"))) {\n this.telInput.setAttribute(\"autocomplete\", \"off\");\n }\n const {\n allowDropdown,\n showSelectedDialCode,\n showFlags,\n containerClass,\n hiddenInput,\n dropdownContainer,\n fixDropdownWidth,\n useFullscreenPopup,\n countrySearch,\n i18n\n } = this.options;\n // containers (mostly for positioning)\n let parentClass = \"iti\";\n if (allowDropdown) {\n parentClass += \" iti--allow-dropdown\";\n }\n if (showSelectedDialCode) {\n parentClass += \" iti--show-selected-dial-code\";\n }\n if (showFlags) {\n parentClass += \" iti--show-flags\";\n }\n if (containerClass) {\n parentClass += ` ${containerClass}`;\n }\n if (!useFullscreenPopup) {\n parentClass += \" iti--inline-dropdown\";\n }\n const wrapper = this._createEl(\"div\", {\n class: parentClass\n });\n this.telInput.parentNode.insertBefore(wrapper, this.telInput);\n // if we're showing flags or dial codes, we need the flags container etc\n if (showFlags || showSelectedDialCode) {\n this.flagsContainer = this._createEl(\"div\", {\n class: \"iti__flag-container\"\n }, wrapper);\n // selected flag (displayed on left of input while allowDropdown is enabled, otherwise to right)\n // when countrySearch disabled: using Aria tags for \"Select-Only Combobox Example\"\n // https://www.w3.org/WAI/ARIA/apg/patterns/combobox/examples/combobox-select-only/\n this.selectedFlag = this._createEl(\"div\", {\n class: \"iti__selected-flag\",\n ...allowDropdown && {\n role: \"button\",\n \"aria-expanded\": \"false\",\n \"aria-label\": this.options.i18n.selectedCountryAriaLabel || \"Selected country\",\n \"aria-haspopup\": countrySearch ? \"true\" : \"listbox\",\n \"aria-controls\": countrySearch ? `iti-${this.id}__dropdown-content` : `iti-${this.id}__country-listbox`,\n ...countrySearch || {\n role: \"combobox\"\n }\n }\n }, this.flagsContainer);\n // we now include the selected flag element even when showFlags is disabled,\n // as need to show globe icon for showSelectedDialCode empty state\n this.selectedFlagInner = this._createEl(\"div\", null, this.selectedFlag);\n this.selectedFlagA11yText = this._createEl(\"span\", {\n class: \"iti__a11y-text\"\n }, this.selectedFlagInner);\n }\n wrapper.appendChild(this.telInput);\n if (this.selectedFlag && this.telInput.disabled) {\n this.selectedFlag.setAttribute(\"aria-disabled\", \"true\");\n }\n if (showSelectedDialCode) {\n this.selectedDialCode = this._createEl(\"div\", {\n class: \"iti__selected-dial-code\"\n }, this.selectedFlag);\n }\n if (allowDropdown) {\n if (!this.telInput.disabled) {\n // make element focusable and tab navigable\n this.selectedFlag.setAttribute(\"tabindex\", \"0\");\n }\n this.dropdownArrow = this._createEl(\"div\", {\n class: \"iti__arrow\",\n \"aria-hidden\": \"true\"\n }, this.selectedFlag);\n const extraClasses = fixDropdownWidth ? \"\" : \"iti--flexible-dropdown-width\";\n this.dropdownContent = this._createEl(\"div\", {\n id: `iti-${this.id}__dropdown-content`,\n class: `iti__dropdown-content iti__hide ${extraClasses}`\n });\n if (countrySearch) {\n this.searchInput = this._createEl(\"input\", {\n type: \"text\",\n class: \"iti__search-input\",\n placeholder: i18n.searchPlaceholder || \"Search\",\n role: \"combobox\",\n \"aria-expanded\": \"true\",\n \"aria-label\": i18n.searchPlaceholder || \"Search\",\n \"aria-controls\": `iti-${this.id}__country-listbox`,\n \"aria-autocomplete\": \"list\",\n autocomplete: \"off\"\n }, this.dropdownContent);\n this.searchResultsA11yText = this._createEl(\"span\", {\n class: \"iti__a11y-text\"\n }, this.dropdownContent);\n }\n // country list: preferred countries, then divider, then all countries\n this.countryList = this._createEl(\"ul\", {\n class: \"iti__country-list\",\n id: `iti-${this.id}__country-listbox`,\n role: \"listbox\",\n \"aria-label\": i18n.countryListAriaLabel || \"List of countries\"\n }, this.dropdownContent);\n if (this.preferredCountries.length && !countrySearch) {\n this._appendListItems(this.preferredCountries, \"iti__preferred\", true);\n this._createEl(\"li\", {\n class: \"iti__divider\",\n \"aria-hidden\": \"true\"\n }, this.countryList);\n }\n this._appendListItems(this.countries, \"iti__standard\");\n if (countrySearch) {\n this._updateSearchResultsText();\n }\n // create dropdownContainer markup\n if (dropdownContainer) {\n let dropdownClasses = \"iti iti--container\";\n if (useFullscreenPopup) {\n dropdownClasses += \" iti--fullscreen-popup\";\n } else {\n dropdownClasses += \" iti--inline-dropdown\";\n }\n if (countrySearch) {\n dropdownClasses += \" iti--country-search\";\n }\n this.dropdown = this._createEl(\"div\", {\n class: dropdownClasses\n });\n this.dropdown.appendChild(this.dropdownContent);\n } else {\n this.flagsContainer.appendChild(this.dropdownContent);\n }\n }\n if (hiddenInput) {\n const telInputName = this.telInput.getAttribute(\"name\");\n const names = hiddenInput(telInputName);\n if (names.phone) {\n // Create hidden input for the full international number\n this.hiddenInput = this._createEl(\"input\", {\n type: \"hidden\",\n name: names.phone\n });\n wrapper.appendChild(this.hiddenInput);\n }\n if (names.country) {\n // Create hidden input for the selected country iso2 code\n this.hiddenInputCountry = this._createEl(\"input\", {\n type: \"hidden\",\n name: names.country\n });\n wrapper.appendChild(this.hiddenInputCountry);\n }\n }\n }\n // for each of the passed countries: add a country <li> to the countryList <ul> container\n _appendListItems(countries, className, preferred) {\n for (let i = 0; i < countries.length; i++) {\n const c = countries[i];\n const idSuffix = preferred ? \"-preferred\" : \"\";\n const listItem = this._createEl(\"li\", {\n id: `iti-${this.id}__item-${c.iso2}${idSuffix}`,\n class: `iti__country ${className}`,\n tabindex: \"-1\",\n role: \"option\",\n \"data-dial-code\": c.dialCode,\n \"data-country-code\": c.iso2,\n \"aria-selected\": \"false\"\n }, this.countryList);\n // store this for later use e.g. country search filtering\n c.nodeById[this.id] = listItem;\n let content = \"\";\n // add the flag\n if (this.options.showFlags) {\n content += `<div class='iti__flag-box'><div class='iti__flag iti__${c.iso2}'></div></div>`;\n }\n // and the country name and dial code\n content += `<span class='iti__country-name'>${c.name}</span>`;\n content += `<span class='iti__dial-code'>+${c.dialCode}</span>`;\n listItem.insertAdjacentHTML(\"beforeend\", content);\n }\n }\n // set the initial state of the input value and the selected flag by:\n // 1. extracting a dial code from the given number\n // 2. using explicit initialCountry\n // 3. picking the first preferred country\n // 4. picking the first country\n _setInitialState(overrideAutoCountry = false) {\n // fix firefox bug: when first load page (with input with value set to number with intl dial\n // code) and initialising plugin removes the dial code from the input, then refresh page,\n // and we try to init plugin again but this time on number without dial code so get grey flag\n const attributeValue = this.telInput.getAttribute(\"value\");\n const inputValue = this.telInput.value;\n const useAttribute = attributeValue && attributeValue.charAt(0) === \"+\" && (!inputValue || inputValue.charAt(0) !== \"+\");\n const val = useAttribute ? attributeValue : inputValue;\n const dialCode = this._getDialCode(val);\n const isRegionlessNanp = this._isRegionlessNanp(val);\n const {\n initialCountry\n } = this.options;\n // if we already have a dial code, and it's not a regionlessNanp, we can go ahead and set the\n // flag, else fall back to the default country\n if (dialCode && !isRegionlessNanp) {\n this._updateFlagFromNumber(val);\n } else if (initialCountry !== \"auto\" || overrideAutoCountry) {\n const lowerInitialCountry = initialCountry ? initialCountry.toLowerCase() : \"\";\n const isValidInitialCountry = lowerInitialCountry && this._getCountryData(lowerInitialCountry, true);\n // see if we should select a flag\n if (isValidInitialCountry) {\n this._setCountry(lowerInitialCountry);\n } else {\n if (dialCode && isRegionlessNanp) {\n // has intl dial code, is regionless nanp, and no initialCountry, so default to US\n this._setCountry(\"us\");\n } else {\n // display the empty state (globe icon)\n this._setCountry();\n }\n }\n }\n // NOTE: if initialCountry is set to auto, that will be handled separately\n // format - note this wont be run after _updateDialCode as that's only called if no val\n if (val) {\n this._updateValFromNumber(val);\n }\n }\n // initialise the main event listeners: input keyup, and click selected flag\n _initListeners() {\n this._initTelInputListeners();\n if (this.options.allowDropdown) {\n this._initDropdownListeners();\n }\n if ((this.hiddenInput || this.hiddenInputCountry) && this.telInput.form) {\n this._initHiddenInputListener();\n }\n }\n // update hidden input on form submit\n _initHiddenInputListener() {\n this._handleHiddenInputSubmit = () => {\n if (this.hiddenInput) {\n this.hiddenInput.value = this.getNumber();\n }\n if (this.hiddenInputCountry) {\n this.hiddenInputCountry.value = this.getSelectedCountryData().iso2;\n }\n };\n this.telInput.form.addEventListener(\"submit\", this._handleHiddenInputSubmit);\n }\n // initialise the dropdown listeners\n _initDropdownListeners() {\n // hack for input nested inside label (which is valid markup): clicking the selected-flag to\n // open the dropdown would then automatically trigger a 2nd click on the input which would\n // close it again\n this._handleLabelClick = e => {\n // if the dropdown is closed, then focus the input, else ignore the click\n if (this.dropdownContent.classList.contains(\"iti__hide\")) {\n this.telInput.focus();\n } else {\n e.preventDefault();\n }\n };\n const label = this.telInput.closest(\"label\");\n if (label) {\n label.addEventListener(\"click\", this._handleLabelClick);\n }\n // toggle country dropdown on click\n this._handleClickSelectedFlag = () => {\n // only intercept this event if we're opening the dropdown\n // else let it bubble up to the top (\"click-off-to-close\" listener)\n // we cannot just stopPropagation as it may be needed to close another instance\n if (this.dropdownContent.classList.contains(\"iti__hide\") && !this.telInput.disabled && !this.telInput.readOnly) {\n this._openDropdown();\n }\n };\n this.selectedFlag.addEventListener(\"click\", this._handleClickSelectedFlag);\n // open dropdown if selected flag is focused and they press up/down/space/enter\n this._handleFlagsContainerKeydown = e => {\n const isDropdownHidden = this.dropdownContent.classList.contains(\"iti__hide\");\n if (isDropdownHidden && [ \"ArrowUp\", \"ArrowDown\", \" \", \"Enter\" ].includes(e.key)) {\n // prevent form from being submitted if \"ENTER\" was pressed\n e.preventDefault();\n // prevent event from being handled again by document\n e.stopPropagation();\n this._openDropdown();\n }\n // allow navigation from dropdown to input on TAB\n if (e.key === \"Tab\") {\n this._closeDropdown();\n }\n };\n this.flagsContainer.addEventListener(\"keydown\", this._handleFlagsContainerKeydown);\n }\n // init many requests: utils script / geo ip lookup\n _initRequests() {\n // if the user has specified the path to the utils script, fetch it on window.load, else resolve\n if (this.options.utilsScript && !window.intlTelInputUtils) {\n // if the plugin is being initialised after the window.load event has already been fired\n if (window.intlTelInputGlobals.documentReady()) {\n window.intlTelInputGlobals.loadUtils(this.options.utilsScript);\n } else {\n // wait until the load event so we don't block any other requests e.g. the flags image\n window.addEventListener(\"load\", () => {\n window.intlTelInputGlobals.loadUtils(this.options.utilsScript);\n });\n }\n } else {\n this.resolveUtilsScriptPromise();\n }\n // dont bother with IP lookup if we already have a selected country\n if (this.options.initialCountry === \"auto\" && !this.selectedCountryData.iso2) {\n this._loadAutoCountry();\n } else {\n this.resolveAutoCountryPromise();\n }\n }\n // perform the geo ip lookup\n _loadAutoCountry() {\n // 3 options:\n // 1) already loaded (we're done)\n // 2) not already started loading (start)\n // 3) already started loading (do nothing - just wait for loading callback to fire)\n if (window.intlTelInputGlobals.autoCountry) {\n this.handleAutoCountry();\n } else if (!window.intlTelInputGlobals.startedLoadingAutoCountry) {\n // don't do this twice!\n window.intlTelInputGlobals.startedLoadingAutoCountry = true;\n if (typeof this.options.geoIpLookup === \"function\") {\n this.options.geoIpLookup((iso2 = \"\") => {\n const iso2Lower = iso2.toLowerCase();\n const isValidIso2 = iso2Lower && this._getCountryData(iso2Lower, true);\n if (isValidIso2) {\n window.intlTelInputGlobals.autoCountry = iso2Lower;\n // tell all instances the auto country is ready\n // TODO: this should just be the current instances\n // UPDATE: use setTimeout in case their geoIpLookup function calls this callback straight\n // away (e.g. if they have already done the geo ip lookup somewhere else). Using\n // setTimeout means that the current thread of execution will finish before executing\n // this, which allows the plugin to finish initialising.\n setTimeout(() => forEachInstance(\"handleAutoCountry\"));\n } else {\n this._setInitialState(true);\n forEachInstance(\"rejectAutoCountryPromise\");\n }\n }, () => forEachInstance(\"rejectAutoCountryPromise\"));\n }\n }\n }\n // initialize the tel input listeners\n _initTelInputListeners() {\n const {\n strictMode,\n formatAsYouType\n } = this.options;\n let userOverrideFormatting = false;\n // update flag on input event\n this._handleInputEvent = e => {\n if (this._updateFlagFromNumber(this.telInput.value)) {\n this._triggerCountryChange();\n }\n // if user types their own formatting char (not a plus or a numeric), or they paste something, then set the override\n const isFormattingChar = e && e.data && /[^+0-9]/.test(e.data);\n const isPaste = e && e.inputType === \"insertFromPaste\" && this.telInput.value;\n if (isFormattingChar || isPaste && !strictMode) {\n userOverrideFormatting = true;\n }\n // if user removes all formatting chars, then reset the override\n else if (!/[^+0-9]/.test(this.telInput.value)) {\n userOverrideFormatting = false;\n }\n // handle FAYT, unless userOverrideFormatting\n if (formatAsYouType && !userOverrideFormatting) {\n // maintain caret position after reformatting\n const currentCaretPos = this.telInput.selectionStart;\n const valueBeforeCaret = this.telInput.value.substring(0, currentCaretPos);\n const relevantCharsBeforeCaret = valueBeforeCaret.replace(/[^+0-9]/g, \"\").length;\n const isDeleteForwards = e && e.inputType === \"deleteContentForward\";\n const formattedValue = this._formatNumberAsYouType();\n const newCaretPos = this._translateCursorPosition(relevantCharsBeforeCaret, formattedValue, currentCaretPos, isDeleteForwards);\n this.telInput.value = formattedValue;\n this.telInput.setSelectionRange(newCaretPos, newCaretPos);\n }\n };\n // this handles individual key presses as well as cut/paste events\n // the advantage of the \"input\" event over \"keyup\" etc is that \"input\" only fires when the value changes,\n // whereas \"keyup\" fires even for shift key, arrow key presses etc\n this.telInput.addEventListener(\"input\", this._handleInputEvent);\n if (strictMode) {\n this._handleKeydownEvent = e => {\n // only ignore actual character presses, rather than ctrl, alt, shift, command, arrow keys, delete/backspace, cut/copy/paste etc\n if (e.key.length === 1 && !e.altKey && !e.ctrlKey && !e.metaKey) {\n const isInitialPlus = this.telInput.selectionStart === 0 && e.key === \"+\";\n const isNumeric = /^[0-9]$/.test(e.key);\n const isAllowedChar = isInitialPlus || isNumeric;\n const fullNumber = this._getFullNumber();\n const coreNumber = intlTelInputUtils.getCoreNumber(fullNumber, this.selectedCountryData.iso2);\n const hasReachedMaxLength = this.maxCoreNumberLength && coreNumber.length >= this.maxCoreNumberLength;\n if (!isAllowedChar || hasReachedMaxLength) {\n e.preventDefault();\n }\n }\n };\n this.telInput.addEventListener(\"keydown\", this._handleKeydownEvent);\n }\n }\n // iterate through the formattedValue until hit the right number of relevant chars\n _translateCursorPosition(relevantChars, formattedValue, prevCaretPos, isDeleteForwards) {\n // if the first char is a formatting char, and they backspace delete it:\n // cursor should stay at the start (pos 0), rather than stick to the first digit (pos 1)\n if (prevCaretPos === 0 && !isDeleteForwards) {\n return 0;\n }\n let count = 0;\n for (let i = 0; i < formattedValue.length; i++) {\n if (/[+0-9]/.test(formattedValue[i])) {\n count++;\n }\n // normal case: stop when you hit the right number of relevant chars\n // (cursor will be just after the final relevant char)\n if (count === relevantChars && !isDeleteForwards) {\n return i + 1;\n }\n // spacial case: delete forwards (fn + delete on a mac):\n // wait until hit one extra relevant char, and put the cursor just before it (after any formatting chars)\n if (isDeleteForwards && count === relevantChars + 1) {\n return i;\n }\n }\n return formattedValue.length;\n }\n // adhere to the input's maxlength attr\n _cap(number) {\n const max = this.telInput.getAttribute(\"maxlength\");\n return max && number.length > max ? number.substr(0, max) : number;\n }\n // clear the input if it just contains a dial code\n _removeEmptyDialCode() {\n if (this.telInput.value.charAt(0) === \"+\") {\n const numeric = this._getNumeric(this.telInput.value);\n // if just a plus, or if just a dial code\n if (!numeric || this.selectedCountryData.dialCode === numeric) {\n this.telInput.value = \"\";\n }\n }\n }\n // extract the numeric digits from the given string\n _getNumeric(s) {\n return s.replace(/\\D/g, \"\");\n }\n // trigger a custom event on the input\n _trigger(name) {\n const e = new Event(name, {\n bubbles: true,\n cancelable: true\n });\n this.telInput.dispatchEvent(e);\n }\n // open the dropdown\n _openDropdown() {\n const {\n fixDropdownWidth,\n countrySearch\n } = this.options;\n if (fixDropdownWidth) {\n this.dropdownContent.style.width = `${this.telInput.offsetWidth}px`;\n }\n this.dropdownContent.classList.remove(\"iti__hide\");\n this.selectedFlag.setAttribute(\"aria-expanded\", \"true\");\n this._setDropdownPosition();\n // if we have previously selected a country (and countrySearch is disabled), then highlight that item and scroll to it\n // else highlight the first item and scroll to top (even if countrySearch is disabled e.g. on init, showing globe icon)\n if (this.activeItem && !countrySearch) {\n // update highlighting and scroll to active list item\n this._highlightListItem(this.activeItem, false);\n this._scrollTo(this.activeItem, true);\n } else {\n // start by highlighting the first item in the list\n const {\n firstElementChild\n } = this.countryList;\n if (firstElementChild) {\n this._highlightListItem(firstElementChild, false);\n this.countryList.scrollTop = 0;\n }\n if (countrySearch) {\n this.searchInput.focus();\n }\n }\n // bind all the dropdown-related listeners: mouseover, click, click-off, keydown\n this._bindDropdownListeners();\n // update the arrow\n this.dropdownArrow.classList.add(\"iti__arrow--up\");\n this._trigger(\"open:countrydropdown\");\n }\n // make sure the el has the className or not, depending on the value of shouldHaveClass\n _toggleClass(el, className, shouldHaveClass) {\n if (shouldHaveClass && !el.classList.contains(className)) {\n el.classList.add(className);\n } else if (!shouldHaveClass && el.classList.contains(className)) {\n el.classList.remove(className);\n }\n }\n // decide if should position dropdown above or below input (depends on position within viewport, and scroll)\n _setDropdownPosition() {\n if (this.options.dropdownContainer) {\n this.options.dropdownContainer.appendChild(this.dropdown);\n }\n if (!this.options.useFullscreenPopup) {\n const pos = this.telInput.getBoundingClientRect();\n // windowTop from https://stackoverflow.com/a/14384091/217866\n const windowTop = document.documentElement.scrollTop;\n const inputTop = pos.top + windowTop;\n const dropdownHeight = this.dropdownContent.offsetHeight;\n // dropdownFitsBelow = (dropdownBottom < windowBottom)\n const dropdownFitsBelow = inputTop + this.telInput.offsetHeight + dropdownHeight < windowTop + window.innerHeight;\n const dropdownFitsAbove = inputTop - dropdownHeight > windowTop;\n // dont allow positioning above when country search enabled as the search box jumps around as you filter countries\n const positionDropdownAboveInput = !this.options.countrySearch && !dropdownFitsBelow && dropdownFitsAbove;\n // by default, the dropdown will be below the input. If we want to position it above the\n // input, we add the dropup class.\n this._toggleClass(this.dropdownContent, \"iti__dropdown-content--dropup\", positionDropdownAboveInput);\n // if dropdownContainer is enabled, calculate postion\n if (this.options.dropdownContainer) {\n // if we want to position the dropdown below the input, we need to add the input height to the top value\n const extraTop = positionDropdownAboveInput ? 0 : this.telInput.offsetHeight;\n // calculate placement\n this.dropdown.style.top = `${inputTop + extraTop}px`;\n this.dropdown.style.left = `${pos.left + document.body.scrollLeft}px`;\n // close menu on window scroll\n this._handleWindowScroll = () => this._closeDropdown();\n window.addEventListener(\"scroll\", this._handleWindowScroll);\n }\n }\n }\n // we only bind dropdown listeners when the dropdown is open\n _bindDropdownListeners() {\n // when mouse over a list item, just highlight that one\n // we add the class \"highlight\", so if they hit \"enter\" we know which one to select\n this._handleMouseoverCountryList = e => {\n // handle event delegation, as we're listening for this event on the countryList\n const listItem = e.target.closest(\".iti__country\");\n if (listItem) {\n this._highlightListItem(listItem, false);\n }\n };\n this.countryList.addEventListener(\"mouseover\", this._handleMouseoverCountryList);\n // listen for country selection\n this._handleClickCountryList = e => {\n const listItem = e.target.closest(\".iti__country\");\n if (listItem) {\n this._selectListItem(listItem);\n }\n };\n this.countryList.addEventListener(\"click\", this._handleClickCountryList);\n // click off to close\n // (except when this initial opening click is bubbling up)\n // we cannot just stopPropagation as it may be needed to close another instance\n let isOpening = true;\n this._handleClickOffToClose = () => {\n if (!isOpening) {\n this._closeDropdown();\n }\n isOpening = false;\n };\n document.documentElement.addEventListener(\"click\", this._handleClickOffToClose);\n // listen for up/down scrolling, enter to select, or escape to close\n // use keydown as keypress doesn't fire for non-char keys and we want to catch if they\n // just hit down and hold it to scroll down (no keyup event).\n // listen on the document because that's where key events are triggered if no input has focus\n let query = \"\";\n let queryTimer = null;\n this._handleKeydownOnDropdown = e => {\n // prevent down key from scrolling the whole page,\n // and enter key from submitting a form etc\n if ([ \"ArrowUp\", \"ArrowDown\", \"Enter\", \"Escape\" ].includes(e.key)) {\n e.preventDefault();\n e.stopPropagation();\n // up and down to navigate\n if (e.key === \"ArrowUp\" || e.key === \"ArrowDown\") {\n this._handleUpDownKey(e.key);\n }\n // enter to select\n else if (e.key === \"Enter\") {\n this._handleEnterKey();\n }\n // esc to close\n else if (e.key === \"Escape\") {\n this._closeDropdown();\n }\n }\n // alpha chars to perform search\n // regex allows one latin alpha char or space, based on https://stackoverflow.com/a/26900132/217866)\n if (!this.options.countrySearch && /^[a-zA-Z\u00C0-\u00FF\u0430-\u044F\u0410-\u042F ]$/.test(e.key)) {\n e.stopPropagation();\n // jump to countries that start with the query string\n if (queryTimer) {\n clearTimeout(queryTimer);\n }\n query += e.key.toLowerCase();\n this._searchForCountry(query);\n // if the timer hits 1 second, reset the query\n queryTimer = setTimeout(() => {\n query = \"\";\n }, 1e3);\n }\n };\n document.addEventListener(\"keydown\", this._handleKeydownOnDropdown);\n if (this.options.countrySearch) {\n const doFilter = () => {\n const inputQuery = this.searchInput.value.trim();\n if (inputQuery) {\n this._filterCountries(inputQuery);\n } else {\n this._filterCountries(\"\", true);\n }\n };\n let keyupTimer = null;\n this._handleSearchChange = () => {\n // filtering country nodes is expensive (lots of DOM manipulation), so rate limit it\n if (keyupTimer) {\n clearTimeout(keyupTimer);\n }\n keyupTimer = setTimeout(() => {\n doFilter();\n keyupTimer = null;\n }, 100);\n };\n this.searchInput.addEventListener(\"input\", this._handleSearchChange);\n // stop propagation on search input click, so doesn't trigger click-off-to-close listener\n this.searchInput.addEventListener(\"click\", e => e.stopPropagation());\n }\n }\n // turns \"R\u00E9union\" into \"Reunion\"\n // from https://stackoverflow.com/a/37511463\n _normaliseString(s = \"\") {\n return s.normalize(\"NFD\").replace(/[\\u0300-\\u036f]/g, \"\").toLowerCase();\n }\n _filterCountries(query, isReset = false) {\n let isFirst = true;\n this.countryList.innerHTML = \"\";\n const normalisedQuery = this._normaliseString(query);\n for (let i = 0; i < this.countries.length; i++) {\n const c = this.countries[i];\n const normalisedCountryName = this._normaliseString(c.name);\n const fullDialCode = `+${c.dialCode}`;\n if (isReset || normalisedCountryName.includes(normalisedQuery) || fullDialCode.includes(normalisedQuery) || c.iso2.includes(normalisedQuery)) {\n this.countryList.appendChild(c.nodeById[this.id]);\n // highlight the first item\n if (isFirst) {\n this._highlightListItem(c.nodeById[this.id], false);\n isFirst = false;\n }\n }\n }\n // scroll to top (useful if user had previously scrolled down)\n this.countryList.scrollTop = 0;\n this._updateSearchResultsText();\n }\n // update search results text (for a11y)\n _updateSearchResultsText() {\n const {\n i18n\n } = this.options;\n const count = this.countryList.childElementCount;\n let searchText;\n if (count === 0) {\n searchText = i18n.zeroSearchResults || \"No results found\";\n } else if (count === 1) {\n searchText = i18n.oneSearchResult || \"1 result found\";\n } else {\n // eslint-disable-next-line no-template-curly-in-string\n searchText = i18n.multipleSearchResults ? i18n.multipleSearchResults.replace(\"${count}\", count) : `${count} results found`;\n }\n this.searchResultsA11yText.textContent = searchText;\n }\n // highlight the next/prev item in the list (and ensure it is visible)\n _handleUpDownKey(key) {\n let next = key === \"ArrowUp\" ? this.highlightedItem.previousElementSibling : this.highlightedItem.nextElementSibling;\n if (next) {\n // skip the divider\n if (next.classList.contains(\"iti__divider\")) {\n next = key === \"ArrowUp\" ? next.previousElementSibling : next.nextElementSibling;\n }\n } else if (this.countryList.childElementCount > 1) {\n // otherwise, we must be at the end, so loop round again\n next = key === \"ArrowUp\" ? this.countryList.lastElementChild : this.countryList.firstElementChild;\n }\n if (next) {\n // make sure the next item is visible\n // (before calling focus(), which can cause the next item to scroll to the middle of the dropdown, which is jarring)\n this._scrollTo(next, false);\n // if country search enabled, dont lose focus from the search input on up/down\n const doFocus = !this.options.countrySearch;\n this._highlightListItem(next, doFocus);\n }\n }\n // select the currently highlighted item\n _handleEnterKey() {\n if (this.highlightedItem) {\n this._selectListItem(this.highlightedItem);\n }\n }\n // find the first list item whose name starts with the query string\n _searchForCountry(query) {\n for (let i = 0; i < this.countries.length; i++) {\n if (this._startsWith(this.countries[i].name, query)) {\n const listItem = this.countries[i].nodeById[this.id];\n // update highlighting and scroll\n this._highlightListItem(listItem, false);\n this._scrollTo(listItem, true);\n break;\n }\n }\n }\n // check if string a starts with string b\n _startsWith(a, b) {\n return a.substr(0, b.length).toLowerCase() === b;\n }\n // update the input's value to the given val (format first if possible)\n // NOTE: this is called from _setInitialState, handleUtils and setNumber\n _updateValFromNumber(fullNumber) {\n let number = fullNumber;\n if (this.options.formatOnDisplay && window.intlTelInputUtils && this.selectedCountryData) {\n const useNational = this.options.nationalMode || number.charAt(0) !== \"+\" && !this.options.showSelectedDialCode;\n const {\n NATIONAL,\n INTERNATIONAL\n } = intlTelInputUtils.numberFormat;\n const format = useNational ? NATIONAL : INTERNATIONAL;\n number = intlTelInputUtils.formatNumber(number, this.selectedCountryData.iso2, format);\n }\n number = this._beforeSetNumber(number);\n this.telInput.value = number;\n }\n // check if need to select a new flag based on the given number\n // Note: called from _setInitialState, keyup handler, setNumber\n _updateFlagFromNumber(fullNumber) {\n const plusIndex = fullNumber.indexOf(\"+\");\n // if it contains a plus, discard any chars before it e.g. accidental space char.\n // this keeps the selected country auto-updating correctly, which we want as\n // libphonenumber's validation/getNumber methods will ignore these chars anyway\n let number = plusIndex ? fullNumber.substring(plusIndex) : fullNumber;\n // if we already have US/Canada selected, make sure the number starts\n // with a +1 so _getDialCode will be able to extract the area code\n // update: if we dont yet have selectedCountryData, but we're here (trying to update the flag\n // from the number), that means we're initialising the plugin with a number that already has a\n // dial code, so fine to ignore this bit\n const selectedDialCode = this.selectedCountryData.dialCode;\n const isNanp = selectedDialCode === \"1\";\n if (number && isNanp && number.charAt(0) !== \"+\") {\n if (number.charAt(0) !== \"1\") {\n number = `1${number}`;\n }\n number = `+${number}`;\n }\n // if showSelectedDialCode enabled, then consider the selected dial code to be part of the number\n if (this.options.showSelectedDialCode && selectedDialCode && number.charAt(0) !== \"+\") {\n number = `+${selectedDialCode}${number}`;\n }\n // try and extract valid dial code from input\n const dialCode = this._getDialCode(number, true);\n const numeric = this._getNumeric(number);\n let iso2 = null;\n if (dialCode) {\n const iso2Codes = this.dialCodeToIso2Map[this._getNumeric(dialCode)];\n // check if the right country is already selected. this should be false if the number is\n // longer than the matched dial code because in this case we need to make sure that if\n // there are multiple country matches, that the first one is selected (note: we could\n // just check that here, but it requires the same loop that we already have later)\n const alreadySelected = iso2Codes.indexOf(this.selectedCountryData.iso2) !== -1 && numeric.length <= dialCode.length - 1;\n const isRegionlessNanpNumber = selectedDialCode === \"1\" && this._isRegionlessNanp(numeric);\n // only update the flag if:\n // A) NOT (we currently have a NANP flag selected, and the number is a regionlessNanp)\n // AND\n // B) the right country is not already selected\n if (!isRegionlessNanpNumber && !alreadySelected) {\n // if using onlyCountries option, iso2Codes[0] may be empty, so we must find the first\n // non-empty index\n for (let j = 0; j < iso2Codes.length; j++) {\n if (iso2Codes[j]) {\n iso2 = iso2Codes[j];\n break;\n }\n }\n }\n } else if (number.charAt(0) === \"+\" && numeric.length) {\n // invalid dial code, so empty\n // Note: use getNumeric here because the number has not been formatted yet, so could contain\n // bad chars\n iso2 = \"\";\n } else if ((!number || number === \"+\") && !this.selectedCountryData.iso2) {\n // if no selected flag, and user either clears the input, or just types a plus, then show default\n iso2 = this.defaultCountry;\n }\n if (iso2 !== null) {\n return this._setCountry(iso2);\n }\n return false;\n }\n // check if the given number is a regionless NANP number (expects the number to contain an\n // international dial code)\n _isRegionlessNanp(number) {\n const numeric = this._getNumeric(number);\n if (numeric.charAt(0) === \"1\") {\n const areaCode = numeric.substr(1, 3);\n return regionlessNanpNumbers.indexOf(areaCode) !== -1;\n }\n return false;\n }\n // remove highlighting from other list items and highlight the given item\n _highlightListItem(listItem, shouldFocus) {\n const prevItem = this.highlightedItem;\n if (prevItem) {\n prevItem.classList.remove(\"iti__highlight\");\n prevItem.setAttribute(\"aria-selected\", \"false\");\n }\n this.highlightedItem = listItem;\n this.highlightedItem.classList.add(\"iti__highlight\");\n this.highlightedItem.setAttribute(\"aria-selected\", \"true\");\n this.selectedFlag.setAttribute(\"aria-activedescendant\", listItem.getAttribute(\"id\"));\n if (this.options.countrySearch) {\n this.searchInput.setAttribute(\"aria-activedescendant\", listItem.getAttribute(\"id\"));\n }\n if (shouldFocus) {\n this.highlightedItem.focus();\n }\n }\n // find the country data for the given iso2 code\n // the ignoreOnlyCountriesOption is only used during init() while parsing the onlyCountries array\n _getCountryData(iso2, allowFail) {\n for (let i = 0; i < this.countries.length; i++) {\n if (this.countries[i].iso2 === iso2) {\n return this.countries[i];\n }\n }\n if (allowFail) {\n return null;\n }\n throw new Error(`No country data for '${iso2}'`);\n }\n // update the selected flag, dial code (if showSelectedDialCode), placeholder, title, and active list item\n // Note: called from _setInitialState, _updateFlagFromNumber, _selectListItem, setCountry\n _setCountry(iso2) {\n const {\n allowDropdown,\n showSelectedDialCode,\n showFlags,\n countrySearch,\n i18n\n } = this.options;\n const prevCountry = this.selectedCountryData.iso2 ? this.selectedCountryData : {};\n // do this first as it will throw an error and stop if iso2 is invalid\n this.selectedCountryData = iso2 ? this._getCountryData(iso2, false) : {};\n // update the defaultCountry - we only need the iso2 from now on, so just store that\n if (this.selectedCountryData.iso2) {\n this.defaultCountry = this.selectedCountryData.iso2;\n }\n // update the flag class and the a11y text\n if (this.selectedFlagInner) {\n let flagClass = \"\";\n let a11yText = \"\";\n if (iso2) {\n if (showFlags) {\n flagClass = `iti__flag iti__${iso2}`;\n a11yText = `${this.selectedCountryData.name} +${this.selectedCountryData.dialCode}`;\n }\n // if showFlags disabled and showSelectedDialCode is enabled, we dont show a flag or have any a11y text, as the displayed dial code is enough\n } else {\n flagClass = \"iti__flag iti__globe\";\n a11yText = i18n.noCountrySelected || \"No country selected\";\n }\n this.selectedFlagInner.className = flagClass;\n this.selectedFlagA11yText.textContent = a11yText;\n }\n this._setSelectedCountryFlagTitleAttribute(iso2, showSelectedDialCode);\n // update the selected dial code\n if (showSelectedDialCode) {\n const dialCode = this.selectedCountryData.dialCode ? `+${this.selectedCountryData.dialCode}` : \"\";\n this.selectedDialCode.innerHTML = dialCode;\n // offsetWidth is zero if input is in a hidden container during initialisation\n const selectedFlagWidth = this.selectedFlag.offsetWidth || this._getHiddenSelectedFlagWidth();\n // add 6px of padding after the grey selected-dial-code box, as this is what we use in the css\n if (this.isRTL) {\n this.telInput.style.paddingRight = `${selectedFlagWidth + 6}px`;\n } else {\n this.telInput.style.paddingLeft = `${selectedFlagWidth + 6}px`;\n }\n }\n // and the input's placeholder\n this._updatePlaceholder();\n // update the maximum valid number length\n this._updateMaxLength();\n // update the active list item (only if country search disabled, as country search doesn't store the active item)\n if (allowDropdown && !countrySearch) {\n const prevItem = this.activeItem;\n if (prevItem) {\n prevItem.classList.remove(\"iti__active\");\n prevItem.setAttribute(\"aria-selected\", \"false\");\n }\n if (iso2) {\n // check if there is a preferred item first, else fall back to standard\n const nextItem = this.countryList.querySelector(`#iti-${this.id}__item-${iso2}-preferred`) || this.countryList.querySelector(`#iti-${this.id}__item-${iso2}`);\n nextItem.setAttribute(\"aria-selected\", \"true\");\n nextItem.classList.add(\"iti__active\");\n this.activeItem = nextItem;\n }\n }\n // return if the flag has changed or not\n return prevCountry.iso2 !== iso2;\n }\n // update the maximum valid number length for the currently selected country\n _updateMaxLength() {\n if (this.options.strictMode && window.intlTelInputUtils) {\n if (this.selectedCountryData.iso2) {\n const numberType = intlTelInputUtils.numberType[this.options.placeholderNumberType];\n let exampleNumber = intlTelInputUtils.getExampleNumber(this.selectedCountryData.iso2, null, numberType, true);\n // see if adding more digits is still valid to get the true maximum valid length\n let validNumber = exampleNumber;\n while (intlTelInputUtils.isPossibleNumber(exampleNumber, this.selectedCountryData.iso2)) {\n validNumber = exampleNumber;\n exampleNumber += \"0\";\n }\n const coreNumber = intlTelInputUtils.getCoreNumber(validNumber, this.selectedCountryData.iso2);\n this.maxCoreNumberLength = coreNumber.length;\n } else {\n this.maxCoreNumberLength = null;\n }\n }\n }\n _setSelectedCountryFlagTitleAttribute(iso2, showSelectedDialCode) {\n if (!this.selectedFlag) {\n return;\n }\n let title;\n if (iso2 && !showSelectedDialCode) {\n title = `${this.selectedCountryData.name}: +${this.selectedCountryData.dialCode}`;\n } else if (iso2) {\n // For screen reader output, we don't want to include the dial code in the reader output twice\n // so just use the selected country name here:\n title = this.selectedCountryData.name;\n } else {\n title = \"Unknown\";\n }\n this.selectedFlag.setAttribute(\"title\", title);\n }\n // when the input is in a hidden container during initialisation, we must inject some markup\n // into the end of the DOM to calculate the correct offsetWidth\n // NOTE: this is only used when showSelectedDialCode is enabled, so flagsContainer and selectedFlag\n // will definitely exist\n _getHiddenSelectedFlagWidth() {\n // to get the right styling to apply, all we need is a shallow clone of the container,\n // and then to inject a deep clone of the selectedFlag element\n const containerClone = this.telInput.parentNode.cloneNode();\n containerClone.style.visibility = \"hidden\";\n document.body.appendChild(containerClone);\n const flagsContainerClone = this.flagsContainer.cloneNode();\n containerClone.appendChild(flagsContainerClone);\n const selectedFlagClone = this.selectedFlag.cloneNode(true);\n flagsContainerClone.appendChild(selectedFlagClone);\n const width = selectedFlagClone.offsetWidth;\n containerClone.parentNode.removeChild(containerClone);\n return width;\n }\n // update the input placeholder to an example number from the currently selected country\n _updatePlaceholder() {\n const {\n autoPlaceholder,\n placeholderNumberType,\n nationalMode,\n customPlaceholder\n } = this.options;\n const shouldSetPlaceholder = autoPlaceholder === \"aggressive\" || !this.hadInitialPlaceholder && autoPlaceholder === \"polite\";\n if (window.intlTelInputUtils && shouldSetPlaceholder) {\n const numberType = intlTelInputUtils.numberType[placeholderNumberType];\n // note: must set placeholder to empty string if no country selected (globe icon showing)\n let placeholder = this.selectedCountryData.iso2 ? intlTelInputUtils.getExampleNumber(this.selectedCountryData.iso2, nationalMode, numberType) : \"\";\n placeholder = this._beforeSetNumber(placeholder);\n if (typeof customPlaceholder === \"function\") {\n placeholder = customPlaceholder(placeholder, this.selectedCountryData);\n }\n this.telInput.setAttribute(\"placeholder\", placeholder);\n }\n }\n // called when the user selects a list item from the dropdown\n _selectListItem(listItem) {\n // update selected flag and active list item\n const flagChanged = this._setCountry(listItem.getAttribute(\"data-country-code\"));\n this._closeDropdown();\n this._updateDialCode(listItem.getAttribute(\"data-dial-code\"));\n // focus the input\n this.telInput.focus();\n if (flagChanged) {\n this._triggerCountryChange();\n }\n }\n // close the dropdown and unbind any listeners\n _closeDropdown() {\n this.dropdownContent.classList.add(\"iti__hide\");\n this.selectedFlag.setAttribute(\"aria-expanded\", \"false\");\n this.selectedFlag.removeAttribute(\"aria-activedescendant\");\n if (this.highlightedItem) {\n this.highlightedItem.setAttribute(\"aria-selected\", \"false\");\n }\n if (this.options.countrySearch) {\n this.searchInput.removeAttribute(\"aria-activedescendant\");\n }\n // update the arrow\n this.dropdownArrow.classList.remove(\"iti__arrow--up\");\n // unbind key events\n document.removeEventListener(\"keydown\", this._handleKeydownOnDropdown);\n if (this.options.countrySearch) {\n this.searchInput.removeEventListener(\"input\", this._handleSearchChange);\n }\n document.documentElement.removeEventListener(\"click\", this._handleClickOffToClose);\n this.countryList.removeEventListener(\"mouseover\", this._handleMouseoverCountryList);\n this.countryList.removeEventListener(\"click\", this._handleClickCountryList);\n // remove menu from container\n if (this.options.dropdownContainer) {\n if (!this.options.useFullscreenPopup) {\n window.removeEventListener(\"scroll\", this._handleWindowScroll);\n }\n if (this.dropdown.parentNode) {\n this.dropdown.parentNode.removeChild(this.dropdown);\n }\n }\n this._trigger(\"close:countrydropdown\");\n }\n // check if an element is visible within it's container, else scroll until it is\n _scrollTo(element, middle) {\n const container = this.countryList;\n // windowTop from https://stackoverflow.com/a/14384091/217866\n const windowTop = document.documentElement.scrollTop;\n const containerHeight = container.offsetHeight;\n const containerTop = container.getBoundingClientRect().top + windowTop;\n const containerBottom = containerTop + containerHeight;\n const elementHeight = element.offsetHeight;\n const elementTop = element.getBoundingClientRect().top + windowTop;\n const elementBottom = elementTop + elementHeight;\n let newScrollTop = elementTop - containerTop + container.scrollTop;\n const middleOffset = containerHeight / 2 - elementHeight / 2;\n if (elementTop < containerTop) {\n // scroll up\n if (middle) {\n newScrollTop -= middleOffset;\n }\n container.scrollTop = newScrollTop;\n } else if (elementBottom > containerBottom) {\n // scroll down\n if (middle) {\n newScrollTop += middleOffset;\n }\n const heightDifference = containerHeight - elementHeight;\n container.scrollTop = newScrollTop - heightDifference;\n }\n }\n // replace any existing dial code with the new one\n // Note: called from _selectListItem and setCountry\n _updateDialCode(newDialCodeBare) {\n const inputVal = this.telInput.value;\n // save having to pass this every time\n const newDialCode = `+${newDialCodeBare}`;\n let newNumber;\n if (inputVal.charAt(0) === \"+\") {\n // there's a plus so we're dealing with a replacement\n const prevDialCode = this._getDialCode(inputVal);\n if (prevDialCode) {\n // current number contains a valid dial code, so replace it\n newNumber = inputVal.replace(prevDialCode, newDialCode);\n } else {\n // current number contains an invalid dial code, so ditch it\n // (no way to determine where the invalid dial code ends and the rest of the number begins)\n newNumber = newDialCode;\n }\n this.telInput.value = newNumber;\n }\n }\n // try and extract a valid international dial code from a full telephone number\n // Note: returns the raw string inc plus character and any whitespace/dots etc\n _getDialCode(number, includeAreaCode) {\n let dialCode = \"\";\n // only interested in international numbers (starting with a plus)\n if (number.charAt(0) === \"+\") {\n let numericChars = \"\";\n // iterate over chars\n for (let i = 0; i < number.length; i++) {\n const c = number.charAt(i);\n // if char is number (https://stackoverflow.com/a/8935649/217866)\n if (!isNaN(parseInt(c, 10))) {\n numericChars += c;\n // if current numericChars make a valid dial code\n if (includeAreaCode) {\n if (this.dialCodeToIso2Map[numericChars]) {\n // store the actual raw string (useful for matching later)\n dialCode = number.substr(0, i + 1);\n }\n } else {\n if (this.dialCodes[numericChars]) {\n dialCode = number.substr(0, i + 1);\n // if we're just looking for a dial code, we can break as soon as we find one\n break;\n }\n }\n // stop searching as soon as we can - in this case when we hit max len\n if (numericChars.length === this.dialCodeMaxLen) {\n break;\n }\n }\n }\n }\n return dialCode;\n }\n // get the input val, adding the dial code if showSelectedDialCode is enabled\n _getFullNumber() {\n const val = this.telInput.value.trim();\n const {\n dialCode\n } = this.selectedCountryData;\n let prefix;\n const numericVal = this._getNumeric(val);\n if (this.options.showSelectedDialCode && !this.options.nationalMode && val.charAt(0) !== \"+\" && dialCode && numericVal) {\n // when using showSelectedDialCode, it is visible so is effectively part of the typed number\n prefix = `+${dialCode}`;\n } else {\n prefix = \"\";\n }\n return prefix + val;\n }\n // remove the dial code if showSelectedDialCode is enabled\n // also cap the length if the input has a maxlength attribute\n _beforeSetNumber(fullNumber) {\n let number = fullNumber;\n if (this.options.showSelectedDialCode) {\n let dialCode = this._getDialCode(number);\n // if there is a valid dial code\n if (dialCode) {\n // in case _getDialCode returned an area code as well\n dialCode = `+${this.selectedCountryData.dialCode}`;\n // a lot of numbers will have a space separating the dial code and the main number, and\n // some NANP numbers will have a hyphen e.g. +1 684-733-1234 - in both cases we want to get\n // rid of it\n // NOTE: don't just trim all non-numerics as may want to preserve an open parenthesis etc\n const start = number[dialCode.length] === \" \" || number[dialCode.length] === \"-\" ? dialCode.length + 1 : dialCode.length;\n number = number.substr(start);\n }\n }\n return this._cap(number);\n }\n // trigger the 'countrychange' event\n _triggerCountryChange() {\n this._trigger(\"countrychange\");\n }\n // format the number as the user types\n _formatNumberAsYouType() {\n const val = this._getFullNumber();\n const result = window.intlTelInputUtils ? intlTelInputUtils.formatNumberAsYouType(val, this.selectedCountryData.iso2) : val;\n // if showSelectedDialCode and they haven't (re)typed the dial code in the input as well, then remove the dial code\n const {\n dialCode\n } = this.selectedCountryData;\n if (this.options.showSelectedDialCode && !this.options.nationalMode && this.telInput.value.charAt(0) !== \"+\" && result.includes(`+${dialCode}`)) {\n const afterDialCode = result.split(`+${dialCode}`)[1] || \"\";\n return afterDialCode.trim();\n }\n return result;\n }\n /**************************\n * SECRET PUBLIC METHODS\n **************************/\n // this is called when the geoip call returns\n handleAutoCountry() {\n if (this.options.initialCountry === \"auto\") {\n // we must set this even if there is an initial val in the input: in case the initial val is\n // invalid and they delete it - they should see their auto country\n this.defaultCountry = window.intlTelInputGlobals.autoCountry;\n // if there's no initial value in the input, then update the flag\n if (!this.telInput.value) {\n this.setCountry(this.defaultCountry);\n }\n this.resolveAutoCountryPromise();\n }\n }\n // this is called when the utils request completes\n handleUtils() {\n // if the request was successful\n if (window.intlTelInputUtils) {\n // if there's an initial value in the input, then format it\n if (this.telInput.value) {\n this._updateValFromNumber(this.telInput.value);\n }\n if (this.selectedCountryData.iso2) {\n this._updatePlaceholder();\n this._updateMaxLength();\n }\n }\n this.resolveUtilsScriptPromise();\n }\n /********************\n * PUBLIC METHODS\n ********************/\n // remove plugin\n destroy() {\n if (this.options.allowDropdown) {\n // make sure the dropdown is closed (and unbind listeners)\n this._closeDropdown();\n this.selectedFlag.removeEventListener(\"click\", this._handleClickSelectedFlag);\n this.flagsContainer.removeEventListener(\"keydown\", this._handleFlagsContainerKeydown);\n // label click hack\n const label = this.telInput.closest(\"label\");\n if (label) {\n label.removeEventListener(\"click\", this._handleLabelClick);\n }\n }\n // unbind hiddenInput listeners\n const {\n form\n } = this.telInput;\n if (this._handleHiddenInputSubmit && form) {\n form.removeEventListener(\"submit\", this._handleHiddenInputSubmit);\n }\n // unbind key events, and cut/paste events\n this.telInput.removeEventListener(\"input\", this._handleInputEvent);\n if (this._handleKeydownEvent) {\n this.telInput.removeEventListener(\"keydown\", this._handleKeydownEvent);\n }\n // remove attribute of id instance: data-intl-tel-input-id\n this.telInput.removeAttribute(\"data-intl-tel-input-id\");\n // remove markup (but leave the original input)\n const wrapper = this.telInput.parentNode;\n wrapper.parentNode.insertBefore(this.telInput, wrapper);\n wrapper.parentNode.removeChild(wrapper);\n delete window.intlTelInputGlobals.instances[this.id];\n }\n // get the extension from the current number\n getExtension() {\n if (window.intlTelInputUtils) {\n return intlTelInputUtils.getExtension(this._getFullNumber(), this.selectedCountryData.iso2);\n }\n return \"\";\n }\n // format the number to the given format\n getNumber(format) {\n if (window.intlTelInputUtils) {\n const {\n iso2\n } = this.selectedCountryData;\n return intlTelInputUtils.formatNumber(this._getFullNumber(), iso2, format);\n }\n return \"\";\n }\n // get the type of the entered number e.g. landline/mobile\n getNumberType() {\n if (window.intlTelInputUtils) {\n return intlTelInputUtils.getNumberType(this._getFullNumber(), this.selectedCountryData.iso2);\n }\n return -99;\n }\n // get the country data for the currently selected flag\n getSelectedCountryData() {\n return this.selectedCountryData;\n }\n // get the validation error\n getValidationError() {\n if (window.intlTelInputUtils) {\n const {\n iso2\n } = this.selectedCountryData;\n return intlTelInputUtils.getValidationError(this._getFullNumber(), iso2);\n }\n return -99;\n }\n // validate the input val - assumes the global function isPossibleNumber (from utilsScript)\n isValidNumber(mobileOnly = true) {\n const val = this._getFullNumber();\n // return false for any alpha chars\n if (/\\p{L}/u.test(val)) {\n return false;\n }\n return window.intlTelInputUtils ? intlTelInputUtils.isPossibleNumber(val, this.selectedCountryData.iso2, mobileOnly) : null;\n }\n // validate the input val (precise) - assumes the global function isValidNumber (from utilsScript)\n isValidNumberPrecise() {\n const val = this._getFullNumber();\n // return false for any alpha chars\n if (/\\p{L}/u.test(val)) {\n return false;\n }\n return window.intlTelInputUtils ? intlTelInputUtils.isValidNumber(val, this.selectedCountryData.iso2) : null;\n }\n // update the selected flag, and update the input val accordingly\n setCountry(iso2) {\n const iso2Lower = iso2.toLowerCase();\n // check if already selected\n if (this.selectedCountryData.iso2 !== iso2Lower) {\n this._setCountry(iso2Lower);\n this._updateDialCode(this.selectedCountryData.dialCode);\n this._triggerCountryChange();\n }\n }\n // set the input value and update the flag\n setNumber(number) {\n // we must update the flag first, which updates this.selectedCountryData, which is used for\n // formatting the number before displaying it\n const flagChanged = this._updateFlagFromNumber(number);\n this._updateValFromNumber(number);\n if (flagChanged) {\n this._triggerCountryChange();\n }\n }\n // set the placeholder number typ\n setPlaceholderNumberType(type) {\n this.options.placeholderNumberType = type;\n this._updatePlaceholder();\n }\n }\n /********************\n * STATIC METHODS\n ********************/\n // get the country data object\n intlTelInputGlobals.getCountryData = () => allCountries;\n // inject a <script> element to load utils.js\n const injectScript = (path, handleSuccess, handleFailure) => {\n // inject a new script element into the page\n const script = document.createElement(\"script\");\n script.onload = () => {\n forEachInstance(\"handleUtils\");\n if (handleSuccess) {\n handleSuccess();\n }\n };\n script.onerror = () => {\n forEachInstance(\"rejectUtilsScriptPromise\");\n if (handleFailure) {\n handleFailure();\n }\n };\n script.className = \"iti-load-utils\";\n script.async = true;\n script.src = path;\n document.body.appendChild(script);\n };\n // load the utils script\n intlTelInputGlobals.loadUtils = path => {\n // 2 options:\n // 1) not already started loading (start)\n // 2) already started loading (do nothing - just wait for the onload callback to fire, which will\n // trigger handleUtils on all instances, invoking their resolveUtilsScriptPromise functions)\n if (!window.intlTelInputUtils && !window.intlTelInputGlobals.startedLoadingUtilsScript) {\n // only do this once\n window.intlTelInputGlobals.startedLoadingUtilsScript = true;\n return new Promise((resolve, reject) => injectScript(path, resolve, reject));\n }\n return null;\n };\n // default options\n intlTelInputGlobals.defaults = defaults;\n // version\n intlTelInputGlobals.version = \"20.3.0\";\n // convenience wrapper\n return function(input, options) {\n var iti = new Iti(input, options);\n iti._init();\n input.setAttribute(\"data-intl-tel-input-id\", iti.id);\n window.intlTelInputGlobals.instances[iti.id] = iti;\n return iti;\n };\n }();\n});", "/* eslint-disable react/forbid-prop-types */\n/* eslint-disable react/jsx-filename-extension */\n/* eslint-disable import/no-extraneous-dependencies */\nimport React, { useRef, useEffect } from 'react';\nimport PropTypes from 'prop-types';\nimport intlTelInput from \"../../build/js/intlTelInput\";\n\nconst IntlTelInput = ({\n initialValue,\n onChangeNumber,\n onChangeCountry,\n onChangeValidity,\n onChangeErrorCode,\n usePreciseValidation,\n initOptions,\n className,\n disabled,\n onFocus,\n onBlur,\n placeholder,\n inputProps,\n}) => {\n const inputRef = useRef(null);\n const itiRef = useRef(null);\n \n const update = () => {\n const num = itiRef.current.getNumber();\n const countryIso = itiRef.current.getSelectedCountryData().iso2;\n // note: this number will be in standard E164 format, but any container component can use\n // intlTelInputUtils.formatNumber() to convert this to another format\n // as well as intlTelInputUtils.getNumberType() etc. if need be\n onChangeNumber(num);\n onChangeCountry(countryIso);\n\n const isValid = usePreciseValidation ? itiRef.current.isValidNumberPrecise() : itiRef.current.isValidNumber();\n if (isValid) {\n onChangeValidity(true);\n onChangeErrorCode(null);\n } else {\n const errorCode = itiRef.current.getValidationError();\n onChangeValidity(false);\n onChangeErrorCode(errorCode);\n }\n };\n \n useEffect(() => {\n // store a reference to the current input ref, which otherwise is already lost in the cleanup function\n const inputRefCurrent = inputRef.current;\n itiRef.current = intlTelInput(inputRef.current, initOptions);\n inputRefCurrent.addEventListener(\"countrychange\", update);\n return () => {\n inputRefCurrent.removeEventListener(\"countrychange\", update);\n itiRef.current.destroy();\n };\n }, []);\n \n return (\n <input\n type=\"tel\"\n ref={inputRef}\n onInput={update}\n defaultValue={initialValue}\n className={className}\n disabled={disabled}\n onFocus={onFocus}\n onBlur={onBlur}\n placeholder={placeholder}\n {...inputProps}\n />\n );\n};\n\nIntlTelInput.propTypes = {\n initialValue: PropTypes.string,\n placeholder: PropTypes.string,\n onChangeNumber: PropTypes.func,\n onChangeCountry: PropTypes.func,\n onChangeValidity: PropTypes.func,\n onChangeErrorCode: PropTypes.func,\n usePreciseValidation: PropTypes.bool,\n initOptions: PropTypes.shape({\n allowDropdown: PropTypes.bool,\n autoPlaceholder: PropTypes.string,\n containerClass: PropTypes.string,\n countrySearch: PropTypes.bool,\n customPlaceholder: PropTypes.func,\n dropdownContainer: PropTypes.node,\n excludeCountries: PropTypes.arrayOf(PropTypes.string),\n fixDropdownWidth: PropTypes.bool,\n formatAsYouType: PropTypes.bool,\n formatOnDisplay: PropTypes.bool,\n geoIpLookup: PropTypes.func,\n hiddenInput: PropTypes.func,\n i18n: PropTypes.objectOf(PropTypes.string),\n initialCountry: PropTypes.string,\n nationalMode: PropTypes.bool,\n onlyCountries: PropTypes.arrayOf(PropTypes.string),\n placeholderNumberType: PropTypes.string,\n preferredCountries: PropTypes.arrayOf(PropTypes.string),\n showFlags: PropTypes.bool,\n showSelectedDialCode: PropTypes.bool,\n useFullscreenPopup: PropTypes.bool,\n utilsScript: PropTypes.string,\n }),\n className: PropTypes.string,\n disabled: PropTypes.bool,\n onFocus: PropTypes.func,\n onBlur: PropTypes.func,\n inputProps: PropTypes.object,\n};\n\nIntlTelInput.defaultProps = {\n initialValue: \"\",\n placeholder: \"\",\n onChangeNumber: () => {},\n onChangeCountry: () => {},\n onChangeValidity: () => {},\n onChangeErrorCode: () => {},\n usePreciseValidation: false,\n initOptions: {},\n className: \"\",\n disabled: false,\n onFocus: () => {},\n onBlur: () => {},\n inputProps: {},\n};\n\nexport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U,MAAM,EACpD,iBAAkBA,EAAU,KAC5B,gBAAiBA,EAAU,KAC3B,gBAAiBA,EAAU,KAC3B,YAAaA,EAAU,KACvB,YAAaA,EAAU,KACvB,KAAMA,EAAU,SAASA,EAAU,MAAM,EACzC,eAAgBA,EAAU,OAC1B,aAAcA,EAAU,KACxB,cAAeA,EAAU,QAAQA,EAAU,MAAM,EACjD,sBAAuBA,EAAU,OACjC,mBAAoBA,EAAU,QAAQA,EAAU,MAAM,EACtD,UAAWA,EAAU,KACrB,qBAAsBA,EAAU,KAChC,mBAAoBA,EAAU,KAC9B,YAAaA,EAAU,MACzB,CAAC,EACD,UAAWA,EAAU,OACrB,SAAUA,EAAU,KACpB,QAASA,EAAU,KACnB,OAAQA,EAAU,KAClB,WAAYA,EAAU,MACxB,EAEAC,EAAa,aAAe,CAC1B,aAAc,GACd,YAAa,GACb,eAAgB,IAAM,CAAC,EACvB,gBAAiB,IAAM,CAAC,EACxB,iBAAkB,IAAM,CAAC,EACzB,kBAAmB,IAAM,CAAC,EAC1B,qBAAsB,GACtB,YAAa,CAAC,EACd,UAAW,GACX,SAAU,GACV,QAAS,IAAM,CAAC,EAChB,OAAQ,IAAM,CAAC,EACf,WAAY,CAAC,CACf,EAEA,IAAOsB,EAAQtB",
|
|
6
|
+
"names": ["require_intlTelInput", "__commonJSMin", "exports", "module", "factory", "undefined", "allCountries", "i", "c", "intlTelInputGlobals", "input", "id", "defaults", "regionlessNanpNumbers", "forEachInstance", "method", "instances", "instance", "Iti", "customOptions", "forceShowFlags", "autoCountryPromise", "resolve", "reject", "utilsScriptPromise", "iso2", "dialCode", "priority", "index", "lowerCaseOnlyCountries", "country", "lowerCaseExcludeCountries", "a", "b", "rootIso2Code", "j", "areaCode", "k", "partialDialCode", "countryData", "name", "attrs", "container", "el", "key", "value", "allowDropdown", "showSelectedDialCode", "showFlags", "containerClass", "hiddenInput", "dropdownContainer", "fixDropdownWidth", "useFullscreenPopup", "countrySearch", "i18n", "parentClass", "wrapper", "extraClasses", "dropdownClasses", "telInputName", "names", "countries", "className", "preferred", "idSuffix", "listItem", "content", "overrideAutoCountry", "attributeValue", "inputValue", "val", "isRegionlessNanp", "initialCountry", "lowerInitialCountry", "e", "label", "iso2Lower", "strictMode", "formatAsYouType", "userOverrideFormatting", "isFormattingChar", "isPaste", "currentCaretPos", "relevantCharsBeforeCaret", "isDeleteForwards", "formattedValue", "newCaretPos", "isInitialPlus", "isNumeric", "isAllowedChar", "fullNumber", "coreNumber", "hasReachedMaxLength", "relevantChars", "prevCaretPos", "count", "number", "max", "numeric", "s", "firstElementChild", "shouldHaveClass", "pos", "windowTop", "inputTop", "dropdownHeight", "dropdownFitsBelow", "dropdownFitsAbove", "positionDropdownAboveInput", "extraTop", "isOpening", "query", "queryTimer", "doFilter", "inputQuery", "keyupTimer", "isReset", "isFirst", "normalisedQuery", "normalisedCountryName", "fullDialCode", "searchText", "next", "doFocus", "useNational", "NATIONAL", "INTERNATIONAL", "format", "plusIndex", "selectedDialCode", "iso2Codes", "alreadySelected", "shouldFocus", "prevItem", "allowFail", "prevCountry", "flagClass", "a11yText", "selectedFlagWidth", "nextItem", "numberType", "exampleNumber", "validNumber", "title", "containerClone", "flagsContainerClone", "selectedFlagClone", "width", "autoPlaceholder", "placeholderNumberType", "nationalMode", "customPlaceholder", "shouldSetPlaceholder", "placeholder", "flagChanged", "element", "middle", "containerHeight", "containerTop", "containerBottom", "elementHeight", "elementTop", "elementBottom", "newScrollTop", "middleOffset", "heightDifference", "newDialCodeBare", "inputVal", "newDialCode", "newNumber", "prevDialCode", "includeAreaCode", "numericChars", "prefix", "numericVal", "start", "result", "form", "mobileOnly", "type", "injectScript", "path", "handleSuccess", "handleFailure", "script", "options", "iti", "import_intlTelInput", "React", "useRef", "useEffect", "PropTypes", "IntlTelInput", "initialValue", "onChangeNumber", "onChangeCountry", "onChangeValidity", "onChangeErrorCode", "usePreciseValidation", "initOptions", "className", "disabled", "onFocus", "onBlur", "placeholder", "inputProps", "inputRef", "itiRef", "update", "num", "countryIso", "errorCode", "inputRefCurrent", "intlTelInput", "IntlTelInput_default"]
|
|
7
7
|
}
|