intl-tel-input 24.8.2 → 25.0.1

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.
@@ -1623,8 +1623,8 @@ var defaults = {
1623
1623
  i18n: {},
1624
1624
  //* Initial country.
1625
1625
  initialCountry: "",
1626
- //* Specify the path to the libphonenumber script to enable validation/formatting.
1627
- loadUtilsOnInit: "",
1626
+ //* A function to load the utils script.
1627
+ loadUtils: null,
1628
1628
  //* National vs international formatting for numbers e.g. placeholders and displaying existing numbers.
1629
1629
  nationalMode: true,
1630
1630
  //* Display only these countries.
@@ -1645,10 +1645,8 @@ var defaults = {
1645
1645
  navigator.userAgent
1646
1646
  ) || window.innerWidth <= 500
1647
1647
  ) : false,
1648
- //* Deprecated! Use `loadUtilsOnInit` instead.
1649
- utilsScript: "",
1650
1648
  //* The number type to enforce during validation.
1651
- validationNumberType: "MOBILE"
1649
+ validationNumberTypes: ["MOBILE"]
1652
1650
  };
1653
1651
  var regionlessNanpNumbers = [
1654
1652
  "800",
@@ -2021,18 +2019,28 @@ var Iti = class {
2021
2019
  const telInputName = this.telInput.getAttribute("name") || "";
2022
2020
  const names = hiddenInput(telInputName);
2023
2021
  if (names.phone) {
2024
- this.hiddenInput = createEl("input", {
2025
- type: "hidden",
2026
- name: names.phone
2027
- });
2028
- wrapper.appendChild(this.hiddenInput);
2022
+ const existingInput = this.telInput.form?.querySelector(`input[name="${names.phone}"]`);
2023
+ if (existingInput) {
2024
+ this.hiddenInput = existingInput;
2025
+ } else {
2026
+ this.hiddenInput = createEl("input", {
2027
+ type: "hidden",
2028
+ name: names.phone
2029
+ });
2030
+ wrapper.appendChild(this.hiddenInput);
2031
+ }
2029
2032
  }
2030
2033
  if (names.country) {
2031
- this.hiddenInputCountry = createEl("input", {
2032
- type: "hidden",
2033
- name: names.country
2034
- });
2035
- wrapper.appendChild(this.hiddenInputCountry);
2034
+ const existingInput = this.telInput.form?.querySelector(`input[name="${names.country}"]`);
2035
+ if (existingInput) {
2036
+ this.hiddenInputCountry = existingInput;
2037
+ } else {
2038
+ this.hiddenInputCountry = createEl("input", {
2039
+ type: "hidden",
2040
+ name: names.country
2041
+ });
2042
+ wrapper.appendChild(this.hiddenInputCountry);
2043
+ }
2036
2044
  }
2037
2045
  }
2038
2046
  }
@@ -2157,15 +2165,11 @@ var Iti = class {
2157
2165
  }
2158
2166
  //* Init many requests: utils script / geo ip lookup.
2159
2167
  _initRequests() {
2160
- let { loadUtilsOnInit, utilsScript, initialCountry, geoIpLookup } = this.options;
2161
- if (!loadUtilsOnInit && utilsScript) {
2162
- console.warn("intl-tel-input: The `utilsScript` option is deprecated and will be removed in a future release! Please use the `loadUtilsOnInit` option instead.");
2163
- loadUtilsOnInit = utilsScript;
2164
- }
2165
- if (loadUtilsOnInit && !intlTelInput.utils) {
2168
+ let { loadUtils, initialCountry, geoIpLookup } = this.options;
2169
+ if (loadUtils && !intlTelInput.utils) {
2166
2170
  this._handlePageLoad = () => {
2167
2171
  window.removeEventListener("load", this._handlePageLoad);
2168
- intlTelInput.loadUtils(loadUtilsOnInit)?.catch(() => {
2172
+ intlTelInput.attachUtils(loadUtils)?.catch(() => {
2169
2173
  });
2170
2174
  };
2171
2175
  if (intlTelInput.documentReady()) {
@@ -2629,7 +2633,7 @@ var Iti = class {
2629
2633
  }
2630
2634
  //* Update the maximum valid number length for the currently selected country.
2631
2635
  _updateMaxLength() {
2632
- const { strictMode, placeholderNumberType, validationNumberType } = this.options;
2636
+ const { strictMode, placeholderNumberType, validationNumberTypes } = this.options;
2633
2637
  const { iso2 } = this.selectedCountryData;
2634
2638
  if (strictMode && intlTelInput.utils) {
2635
2639
  if (iso2) {
@@ -2641,7 +2645,7 @@ var Iti = class {
2641
2645
  true
2642
2646
  );
2643
2647
  let validNumber = exampleNumber;
2644
- while (intlTelInput.utils.isPossibleNumber(exampleNumber, iso2, validationNumberType)) {
2648
+ while (intlTelInput.utils.isPossibleNumber(exampleNumber, iso2, validationNumberTypes)) {
2645
2649
  validNumber = exampleNumber;
2646
2650
  exampleNumber += "0";
2647
2651
  }
@@ -2993,7 +2997,7 @@ var Iti = class {
2993
2997
  return this._utilsIsPossibleNumber(val);
2994
2998
  }
2995
2999
  _utilsIsPossibleNumber(val) {
2996
- return intlTelInput.utils ? intlTelInput.utils.isPossibleNumber(val, this.selectedCountryData.iso2, this.options.validationNumberType) : null;
3000
+ return intlTelInput.utils ? intlTelInput.utils.isPossibleNumber(val, this.selectedCountryData.iso2, this.options.validationNumberTypes) : null;
2997
3001
  }
2998
3002
  //* Validate the input val (precise)
2999
3003
  isValidNumberPrecise() {
@@ -3011,7 +3015,7 @@ var Iti = class {
3011
3015
  return this._utilsIsValidNumber(val);
3012
3016
  }
3013
3017
  _utilsIsValidNumber(val) {
3014
- return intlTelInput.utils ? intlTelInput.utils.isValidNumber(val, this.selectedCountryData.iso2) : null;
3018
+ return intlTelInput.utils ? intlTelInput.utils.isValidNumber(val, this.selectedCountryData.iso2, this.options.validationNumberTypes) : null;
3015
3019
  }
3016
3020
  //* Update the selected country, and update the input val accordingly.
3017
3021
  setCountry(iso2) {
@@ -3047,29 +3051,23 @@ var Iti = class {
3047
3051
  }
3048
3052
  }
3049
3053
  };
3050
- var loadUtils = (source) => {
3054
+ var attachUtils = (source) => {
3051
3055
  if (!intlTelInput.utils && !intlTelInput.startedLoadingUtilsScript) {
3052
3056
  let loadCall;
3053
- if (typeof source === "string") {
3054
- loadCall = Promise.reject(new Error("INTENTIONALLY BROKEN: this build of intl-tel-input includes the utilities module inline, but it has incorrectly attempted to load the utilities separately. If you are seeing this message, something is broken!"));
3055
- } else if (typeof source === "function") {
3057
+ if (typeof source === "function") {
3056
3058
  try {
3057
3059
  loadCall = Promise.resolve(source());
3058
3060
  } catch (error) {
3059
3061
  return Promise.reject(error);
3060
3062
  }
3061
3063
  } else {
3062
- return Promise.reject(new TypeError(`The argument passed to loadUtils must be a URL string or a function that returns a promise for the utilities module, not ${typeof source}`));
3064
+ return Promise.reject(new TypeError(`The argument passed to attachUtils must be a function that returns a promise for the utilities module, not ${typeof source}`));
3063
3065
  }
3064
3066
  intlTelInput.startedLoadingUtilsScript = true;
3065
3067
  return loadCall.then((module) => {
3066
3068
  const utils2 = module?.default;
3067
3069
  if (!utils2 || typeof utils2 !== "object") {
3068
- if (typeof source === "string") {
3069
- throw new TypeError(`The module loaded from ${source} did not set utils as its default export.`);
3070
- } else {
3071
- throw new TypeError("The loader function passed to loadUtils did not resolve to a module object with utils as its default export.");
3072
- }
3070
+ throw new TypeError("The loader function passed to attachUtils did not resolve to a module object with utils as its default export.");
3073
3071
  }
3074
3072
  intlTelInput.utils = utils2;
3075
3073
  forEachInstance("handleUtils");
@@ -3102,10 +3100,10 @@ var intlTelInput = Object.assign(
3102
3100
  },
3103
3101
  //* A map from instance ID to instance object.
3104
3102
  instances: {},
3105
- loadUtils,
3103
+ attachUtils,
3106
3104
  startedLoadingUtilsScript: false,
3107
3105
  startedLoadingAutoCountry: false,
3108
- version: "24.8.2"
3106
+ version: "25.0.1"
3109
3107
  }
3110
3108
  );
3111
3109
  var intl_tel_input_default = intlTelInput;
@@ -3139,7 +3137,7 @@ var intl_tel_input_default = intlTelInput;
3139
3137
  return b;
3140
3138
  }
3141
3139
  ;
3142
- var ca = class {
3140
+ var da = class {
3143
3141
  constructor(a) {
3144
3142
  if (ba !== ba) throw Error("SafeUrl is not meant to be built directly");
3145
3143
  this.g = a;
@@ -3148,8 +3146,8 @@ var intl_tel_input_default = intlTelInput;
3148
3146
  return this.g.toString();
3149
3147
  }
3150
3148
  }, ba = {};
3151
- new ca("about:invalid#zClosurez");
3152
- new ca("about:blank");
3149
+ new da("about:invalid#zClosurez");
3150
+ new da("about:blank");
3153
3151
  const ea = {};
3154
3152
  class fa {
3155
3153
  constructor() {
@@ -3328,91 +3326,91 @@ var intl_tel_input_default = intlTelInput;
3328
3326
  return b;
3329
3327
  };
3330
3328
  var xa = /^-?[0-9]+$/;
3331
- function ya() {
3329
+ function B() {
3332
3330
  }
3333
- n(ya, z);
3334
- ya.prototype.g = function(a, b) {
3331
+ n(B, z);
3332
+ B.prototype.g = function(a, b) {
3335
3333
  a = new a.h();
3336
3334
  a.l = this;
3337
3335
  a.h = b;
3338
3336
  a.g = {};
3339
3337
  return a;
3340
3338
  };
3341
- function B() {
3339
+ function C() {
3342
3340
  }
3343
- n(B, ya);
3344
- B.prototype.h = function(a, b) {
3341
+ n(C, B);
3342
+ C.prototype.h = function(a, b) {
3345
3343
  return 8 == a.h ? !!b : z.prototype.h.apply(this, arguments);
3346
3344
  };
3347
- B.prototype.g = function(a, b) {
3348
- return B.ma.g.call(this, a, b);
3345
+ C.prototype.g = function(a, b) {
3346
+ return C.ma.g.call(this, a, b);
3349
3347
  };
3350
- function C(a, b) {
3348
+ function D(a, b) {
3351
3349
  null != a && this.g.apply(this, arguments);
3352
3350
  }
3353
- C.prototype.h = "";
3354
- C.prototype.set = function(a) {
3351
+ D.prototype.h = "";
3352
+ D.prototype.set = function(a) {
3355
3353
  this.h = "" + a;
3356
3354
  };
3357
- C.prototype.g = function(a, b, c) {
3355
+ D.prototype.g = function(a, b, c) {
3358
3356
  this.h += String(a);
3359
3357
  if (null != b) for (let d = 1; d < arguments.length; d++) this.h += arguments[d];
3360
3358
  return this;
3361
3359
  };
3362
- function D(a) {
3360
+ function E(a) {
3363
3361
  a.h = "";
3364
3362
  }
3365
- C.prototype.toString = function() {
3363
+ D.prototype.toString = function() {
3366
3364
  return this.h;
3367
3365
  };
3368
- function E() {
3369
- p.call(this);
3370
- }
3371
- n(E, p);
3372
- var za = null;
3373
3366
  function F() {
3374
3367
  p.call(this);
3375
3368
  }
3376
3369
  n(F, p);
3377
- var Aa = null;
3370
+ var ya = null;
3378
3371
  function G() {
3379
3372
  p.call(this);
3380
3373
  }
3381
3374
  n(G, p);
3382
- var Ba = null;
3383
- E.prototype.m = function() {
3384
- var a = za;
3385
- a || (za = a = y(E, { 0: { name: "NumberFormat", ia: "i18n.phonenumbers.NumberFormat" }, 1: { name: "pattern", required: true, i: 9, type: String }, 2: { name: "format", required: true, i: 9, type: String }, 3: { name: "leading_digits_pattern", aa: true, i: 9, type: String }, 4: { name: "national_prefix_formatting_rule", i: 9, type: String }, 6: { name: "national_prefix_optional_when_formatting", i: 8, defaultValue: false, type: Boolean }, 5: { name: "domestic_carrier_code_formatting_rule", i: 9, type: String } }));
3386
- return a;
3387
- };
3388
- E.m = E.prototype.m;
3375
+ var za = null;
3376
+ function H() {
3377
+ p.call(this);
3378
+ }
3379
+ n(H, p);
3380
+ var Aa = null;
3389
3381
  F.prototype.m = function() {
3390
- var a = Aa;
3391
- a || (Aa = a = y(F, { 0: { name: "PhoneNumberDesc", ia: "i18n.phonenumbers.PhoneNumberDesc" }, 2: { name: "national_number_pattern", i: 9, type: String }, 9: { name: "possible_length", aa: true, i: 5, type: Number }, 10: { name: "possible_length_local_only", aa: true, i: 5, type: Number }, 6: { name: "example_number", i: 9, type: String } }));
3382
+ var a = ya;
3383
+ a || (ya = a = y(F, { 0: { name: "NumberFormat", ia: "i18n.phonenumbers.NumberFormat" }, 1: { name: "pattern", required: true, i: 9, type: String }, 2: { name: "format", required: true, i: 9, type: String }, 3: { name: "leading_digits_pattern", aa: true, i: 9, type: String }, 4: { name: "national_prefix_formatting_rule", i: 9, type: String }, 6: { name: "national_prefix_optional_when_formatting", i: 8, defaultValue: false, type: Boolean }, 5: { name: "domestic_carrier_code_formatting_rule", i: 9, type: String } }));
3392
3384
  return a;
3393
3385
  };
3394
3386
  F.m = F.prototype.m;
3395
3387
  G.prototype.m = function() {
3396
- var a = Ba;
3397
- a || (Ba = a = y(G, {
3388
+ var a = za;
3389
+ a || (za = a = y(G, { 0: { name: "PhoneNumberDesc", ia: "i18n.phonenumbers.PhoneNumberDesc" }, 2: { name: "national_number_pattern", i: 9, type: String }, 9: { name: "possible_length", aa: true, i: 5, type: Number }, 10: { name: "possible_length_local_only", aa: true, i: 5, type: Number }, 6: { name: "example_number", i: 9, type: String } }));
3390
+ return a;
3391
+ };
3392
+ G.m = G.prototype.m;
3393
+ H.prototype.m = function() {
3394
+ var a = Aa;
3395
+ a || (Aa = a = y(H, {
3398
3396
  0: { name: "PhoneMetadata", ia: "i18n.phonenumbers.PhoneMetadata" },
3399
- 1: { name: "general_desc", i: 11, type: F },
3400
- 2: { name: "fixed_line", i: 11, type: F },
3401
- 3: { name: "mobile", i: 11, type: F },
3402
- 4: { name: "toll_free", i: 11, type: F },
3403
- 5: { name: "premium_rate", i: 11, type: F },
3404
- 6: { name: "shared_cost", i: 11, type: F },
3405
- 7: { name: "personal_number", i: 11, type: F },
3406
- 8: { name: "voip", i: 11, type: F },
3407
- 21: { name: "pager", i: 11, type: F },
3408
- 25: { name: "uan", i: 11, type: F },
3409
- 27: { name: "emergency", i: 11, type: F },
3410
- 28: { name: "voicemail", i: 11, type: F },
3411
- 29: { name: "short_code", i: 11, type: F },
3412
- 30: { name: "standard_rate", i: 11, type: F },
3413
- 31: { name: "carrier_specific", i: 11, type: F },
3414
- 33: { name: "sms_services", i: 11, type: F },
3415
- 24: { name: "no_international_dialling", i: 11, type: F },
3397
+ 1: { name: "general_desc", i: 11, type: G },
3398
+ 2: { name: "fixed_line", i: 11, type: G },
3399
+ 3: { name: "mobile", i: 11, type: G },
3400
+ 4: { name: "toll_free", i: 11, type: G },
3401
+ 5: { name: "premium_rate", i: 11, type: G },
3402
+ 6: { name: "shared_cost", i: 11, type: G },
3403
+ 7: { name: "personal_number", i: 11, type: G },
3404
+ 8: { name: "voip", i: 11, type: G },
3405
+ 21: { name: "pager", i: 11, type: G },
3406
+ 25: { name: "uan", i: 11, type: G },
3407
+ 27: { name: "emergency", i: 11, type: G },
3408
+ 28: { name: "voicemail", i: 11, type: G },
3409
+ 29: { name: "short_code", i: 11, type: G },
3410
+ 30: { name: "standard_rate", i: 11, type: G },
3411
+ 31: { name: "carrier_specific", i: 11, type: G },
3412
+ 33: { name: "sms_services", i: 11, type: G },
3413
+ 24: { name: "no_international_dialling", i: 11, type: G },
3416
3414
  9: { name: "id", required: true, i: 9, type: String },
3417
3415
  10: { name: "country_code", i: 5, type: Number },
3418
3416
  11: { name: "international_prefix", i: 9, type: String },
@@ -3426,31 +3424,31 @@ var intl_tel_input_default = intlTelInput;
3426
3424
  },
3427
3425
  16: { name: "national_prefix_transform_rule", i: 9, type: String },
3428
3426
  18: { name: "same_mobile_and_fixed_line_pattern", i: 8, defaultValue: false, type: Boolean },
3429
- 19: { name: "number_format", aa: true, i: 11, type: E },
3430
- 20: { name: "intl_number_format", aa: true, i: 11, type: E },
3427
+ 19: { name: "number_format", aa: true, i: 11, type: F },
3428
+ 20: { name: "intl_number_format", aa: true, i: 11, type: F },
3431
3429
  22: { name: "main_country_for_code", i: 8, defaultValue: false, type: Boolean },
3432
3430
  23: { name: "leading_digits", i: 9, type: String }
3433
3431
  }));
3434
3432
  return a;
3435
3433
  };
3436
- G.m = G.prototype.m;
3437
- function H() {
3434
+ H.m = H.prototype.m;
3435
+ function I() {
3438
3436
  p.call(this);
3439
3437
  }
3440
- n(H, p);
3441
- var Ca = null, Da = { ra: 0, qa: 1, pa: 5, oa: 10, na: 20 };
3442
- H.prototype.m = function() {
3443
- var a = Ca;
3444
- a || (Ca = a = y(H, { 0: { name: "PhoneNumber", ia: "i18n.phonenumbers.PhoneNumber" }, 1: { name: "country_code", required: true, i: 5, type: Number }, 2: { name: "national_number", required: true, i: 4, type: Number }, 3: { name: "extension", i: 9, type: String }, 4: { name: "italian_leading_zero", i: 8, type: Boolean }, 8: { name: "number_of_leading_zeros", i: 5, defaultValue: 1, type: Number }, 5: { name: "raw_input", i: 9, type: String }, 6: { name: "country_code_source", i: 14, defaultValue: 0, type: Da }, 7: {
3438
+ n(I, p);
3439
+ var Ba = null, Ca = { ra: 0, qa: 1, pa: 5, oa: 10, na: 20 };
3440
+ I.prototype.m = function() {
3441
+ var a = Ba;
3442
+ a || (Ba = a = y(I, { 0: { name: "PhoneNumber", ia: "i18n.phonenumbers.PhoneNumber" }, 1: { name: "country_code", required: true, i: 5, type: Number }, 2: { name: "national_number", required: true, i: 4, type: Number }, 3: { name: "extension", i: 9, type: String }, 4: { name: "italian_leading_zero", i: 8, type: Boolean }, 8: { name: "number_of_leading_zeros", i: 5, defaultValue: 1, type: Number }, 5: { name: "raw_input", i: 9, type: String }, 6: { name: "country_code_source", i: 14, defaultValue: 0, type: Ca }, 7: {
3445
3443
  name: "preferred_domestic_carrier_code",
3446
3444
  i: 9,
3447
3445
  type: String
3448
3446
  } }));
3449
3447
  return a;
3450
3448
  };
3451
- H.ctor = H;
3452
- H.ctor.m = H.prototype.m;
3453
- var I = {
3449
+ I.ctor = I;
3450
+ I.ctor.m = I.prototype.m;
3451
+ var J = {
3454
3452
  1: "US AG AI AS BB BM BS CA DM DO GD GU JM KN KY LC MP MS PR SX TC TT VC VG VI".split(" "),
3455
3453
  7: ["RU", "KZ"],
3456
3454
  20: ["EG"],
@@ -3666,7 +3664,7 @@ var intl_tel_input_default = intlTelInput;
3666
3664
  995: ["GE"],
3667
3665
  996: ["KG"],
3668
3666
  998: ["UZ"]
3669
- }, Ea = {
3667
+ }, Da = {
3670
3668
  AC: [, [
3671
3669
  ,
3672
3670
  ,
@@ -8531,14 +8529,14 @@ var intl_tel_input_default = intlTelInput;
8531
8529
  ], [, , , , , , , , , [-1]], [, , , , , , , , , [-1]], "001", 888, , , , , , , , 1, [[, "(\\d{3})(\\d{3})(\\d{5})", "$1 $2 $3"]], , [, , , , , , , , , [-1]], , , [, , , , , , , , , [-1]], [, , "\\d{11}", , , , "12345678901"], , , [, , , , , , , , , [-1]]],
8532
8530
  979: [, [, , "[1359]\\d{8}", , , , , , , [9], [8]], [, , , , , , , , , [-1]], [, , , , , , , , , [-1]], [, , , , , , , , , [-1]], [, , "[1359]\\d{8}", , , , "123456789", , , , [8]], [, , , , , , , , , [-1]], [, , , , , , , , , [-1]], [, , , , , , , , , [-1]], "001", 979, , , , , , , , 1, [[, "(\\d)(\\d{4})(\\d{4})", "$1 $2 $3", ["[1359]"]]], , [, , , , , , , , , [-1]], , , [, , , , , , , , , [-1]], [, , , , , , , , , [-1]], , , [, , , , , , , , , [-1]]]
8533
8531
  };
8534
- function J() {
8532
+ function K() {
8535
8533
  this.g = {};
8536
8534
  }
8537
- J.h = void 0;
8538
- J.g = function() {
8539
- return J.h ? J.h : J.h = new J();
8535
+ K.h = void 0;
8536
+ K.g = function() {
8537
+ return K.h ? K.h : K.h = new K();
8540
8538
  };
8541
- var Fa = { 0: "0", 1: "1", 2: "2", 3: "3", 4: "4", 5: "5", 6: "6", 7: "7", 8: "8", 9: "9", "\uFF10": "0", "\uFF11": "1", "\uFF12": "2", "\uFF13": "3", "\uFF14": "4", "\uFF15": "5", "\uFF16": "6", "\uFF17": "7", "\uFF18": "8", "\uFF19": "9", "\u0660": "0", "\u0661": "1", "\u0662": "2", "\u0663": "3", "\u0664": "4", "\u0665": "5", "\u0666": "6", "\u0667": "7", "\u0668": "8", "\u0669": "9", "\u06F0": "0", "\u06F1": "1", "\u06F2": "2", "\u06F3": "3", "\u06F4": "4", "\u06F5": "5", "\u06F6": "6", "\u06F7": "7", "\u06F8": "8", "\u06F9": "9" }, Ga = {
8539
+ var Ea = { 0: "0", 1: "1", 2: "2", 3: "3", 4: "4", 5: "5", 6: "6", 7: "7", 8: "8", 9: "9", "\uFF10": "0", "\uFF11": "1", "\uFF12": "2", "\uFF13": "3", "\uFF14": "4", "\uFF15": "5", "\uFF16": "6", "\uFF17": "7", "\uFF18": "8", "\uFF19": "9", "\u0660": "0", "\u0661": "1", "\u0662": "2", "\u0663": "3", "\u0664": "4", "\u0665": "5", "\u0666": "6", "\u0667": "7", "\u0668": "8", "\u0669": "9", "\u06F0": "0", "\u06F1": "1", "\u06F2": "2", "\u06F3": "3", "\u06F4": "4", "\u06F5": "5", "\u06F6": "6", "\u06F7": "7", "\u06F8": "8", "\u06F9": "9" }, Fa = {
8542
8540
  0: "0",
8543
8541
  1: "1",
8544
8542
  2: "2",
@@ -8552,7 +8550,7 @@ var intl_tel_input_default = intlTelInput;
8552
8550
  "+": "+",
8553
8551
  "*": "*",
8554
8552
  "#": "#"
8555
- }, Ha = {
8553
+ }, Ga = {
8556
8554
  0: "0",
8557
8555
  1: "1",
8558
8556
  2: "2",
@@ -8619,48 +8617,48 @@ var intl_tel_input_default = intlTelInput;
8619
8617
  X: "9",
8620
8618
  Y: "9",
8621
8619
  Z: "9"
8622
- }, Ia = RegExp("[+\uFF0B]+"), K = RegExp("^[+\uFF0B]+"), Ja = RegExp("([0-9\uFF10-\uFF19\u0660-\u0669\u06F0-\u06F9])"), Ka = RegExp("[+\uFF0B0-9\uFF10-\uFF19\u0660-\u0669\u06F0-\u06F9]"), La = /[\\\/] *x/, Ma = RegExp("[^0-9\uFF10-\uFF19\u0660-\u0669\u06F0-\u06F9A-Za-z#]+$"), Na = /(?:.*?[A-Za-z]){3}.*/, Oa = RegExp("^\\+([0-9\uFF10-\uFF19\u0660-\u0669\u06F0-\u06F9]|[\\-\\.\\(\\)]?)*[0-9\uFF10-\uFF19\u0660-\u0669\u06F0-\u06F9]([0-9\uFF10-\uFF19\u0660-\u0669\u06F0-\u06F9]|[\\-\\.\\(\\)]?)*$"), Pa = RegExp("^([A-Za-z0-9\uFF10-\uFF19\u0660-\u0669\u06F0-\u06F9]+((\\-)*[A-Za-z0-9\uFF10-\uFF19\u0660-\u0669\u06F0-\u06F9])*\\.)*[A-Za-z]+((\\-)*[A-Za-z0-9\uFF10-\uFF19\u0660-\u0669\u06F0-\u06F9])*\\.?$");
8623
- function L(a) {
8620
+ }, Ha = RegExp("[+\uFF0B]+"), L = RegExp("^[+\uFF0B]+"), Ia = RegExp("([0-9\uFF10-\uFF19\u0660-\u0669\u06F0-\u06F9])"), Ja = RegExp("[+\uFF0B0-9\uFF10-\uFF19\u0660-\u0669\u06F0-\u06F9]"), Ka = /[\\\/] *x/, La = RegExp("[^0-9\uFF10-\uFF19\u0660-\u0669\u06F0-\u06F9A-Za-z#]+$"), Ma = /(?:.*?[A-Za-z]){3}.*/, Na = RegExp("^\\+([0-9\uFF10-\uFF19\u0660-\u0669\u06F0-\u06F9]|[\\-\\.\\(\\)]?)*[0-9\uFF10-\uFF19\u0660-\u0669\u06F0-\u06F9]([0-9\uFF10-\uFF19\u0660-\u0669\u06F0-\u06F9]|[\\-\\.\\(\\)]?)*$"), Oa = RegExp("^([A-Za-z0-9\uFF10-\uFF19\u0660-\u0669\u06F0-\u06F9]+((\\-)*[A-Za-z0-9\uFF10-\uFF19\u0660-\u0669\u06F0-\u06F9])*\\.)*[A-Za-z]+((\\-)*[A-Za-z0-9\uFF10-\uFF19\u0660-\u0669\u06F0-\u06F9])*\\.?$");
8621
+ function M(a) {
8624
8622
  return "([0-9\uFF10-\uFF19\u0660-\u0669\u06F0-\u06F9]{1," + a + "})";
8625
8623
  }
8626
- function Qa() {
8627
- return ";ext=" + L("20") + "|[ \xA0\\t,]*(?:e?xt(?:ensi(?:o\u0301?|\xF3))?n?|\uFF45?\uFF58\uFF54\uFF4E?|\u0434\u043E\u0431|anexo)[:\\.\uFF0E]?[ \xA0\\t,-]*" + (L("20") + "#?|[ \xA0\\t,]*(?:[x\uFF58#\uFF03~\uFF5E]|int|\uFF49\uFF4E\uFF54)[:\\.\uFF0E]?[ \xA0\\t,-]*") + (L("9") + "#?|[- ]+") + (L("6") + "#|[ \xA0\\t]*(?:,{2}|;)[:\\.\uFF0E]?[ \xA0\\t,-]*") + (L("15") + "#?|[ \xA0\\t]*(?:,)+[:\\.\uFF0E]?[ \xA0\\t,-]*") + (L("9") + "#?");
8624
+ function Pa() {
8625
+ return ";ext=" + M("20") + "|[ \xA0\\t,]*(?:e?xt(?:ensi(?:o\u0301?|\xF3))?n?|\uFF45?\uFF58\uFF54\uFF4E?|\u0434\u043E\u0431|anexo)[:\\.\uFF0E]?[ \xA0\\t,-]*" + (M("20") + "#?|[ \xA0\\t,]*(?:[x\uFF58#\uFF03~\uFF5E]|int|\uFF49\uFF4E\uFF54)[:\\.\uFF0E]?[ \xA0\\t,-]*") + (M("9") + "#?|[- ]+") + (M("6") + "#|[ \xA0\\t]*(?:,{2}|;)[:\\.\uFF0E]?[ \xA0\\t,-]*") + (M("15") + "#?|[ \xA0\\t]*(?:,)+[:\\.\uFF0E]?[ \xA0\\t,-]*") + (M("9") + "#?");
8626
+ }
8627
+ var Qa = new RegExp("(?:" + Pa() + ")$", "i"), Ra = new RegExp("^[0-9\uFF10-\uFF19\u0660-\u0669\u06F0-\u06F9]{2}$|^[+\uFF0B]*(?:[-x\u2010-\u2015\u2212\u30FC\uFF0D-\uFF0F \xA0\xAD\u200B\u2060\u3000()\uFF08\uFF09\uFF3B\uFF3D.\\[\\]/~\u2053\u223C\uFF5E*]*[0-9\uFF10-\uFF19\u0660-\u0669\u06F0-\u06F9]){3,}[-x\u2010-\u2015\u2212\u30FC\uFF0D-\uFF0F \xA0\xAD\u200B\u2060\u3000()\uFF08\uFF09\uFF3B\uFF3D.\\[\\]/~\u2053\u223C\uFF5E*A-Za-z0-9\uFF10-\uFF19\u0660-\u0669\u06F0-\u06F9]*(?:" + Pa() + ")?$", "i"), Sa = /(\$\d)/, Ta = /^\(?\$1\)?$/;
8628
+ function Ua(a) {
8629
+ return 2 > a.length ? false : N(Ra, a);
8628
8630
  }
8629
- var Ra = new RegExp("(?:" + Qa() + ")$", "i"), Sa = new RegExp("^[0-9\uFF10-\uFF19\u0660-\u0669\u06F0-\u06F9]{2}$|^[+\uFF0B]*(?:[-x\u2010-\u2015\u2212\u30FC\uFF0D-\uFF0F \xA0\xAD\u200B\u2060\u3000()\uFF08\uFF09\uFF3B\uFF3D.\\[\\]/~\u2053\u223C\uFF5E*]*[0-9\uFF10-\uFF19\u0660-\u0669\u06F0-\u06F9]){3,}[-x\u2010-\u2015\u2212\u30FC\uFF0D-\uFF0F \xA0\xAD\u200B\u2060\u3000()\uFF08\uFF09\uFF3B\uFF3D.\\[\\]/~\u2053\u223C\uFF5E*A-Za-z0-9\uFF10-\uFF19\u0660-\u0669\u06F0-\u06F9]*(?:" + Qa() + ")?$", "i"), Ta = /(\$\d)/, Ua = /^\(?\$1\)?$/;
8630
8631
  function Va(a) {
8631
- return 2 > a.length ? false : M(Sa, a);
8632
+ return N(Ma, a) ? O(a, Ga) : O(a, Ea);
8632
8633
  }
8633
8634
  function Wa(a) {
8634
- return M(Na, a) ? N(a, Ha) : N(a, Fa);
8635
- }
8636
- function Xa(a) {
8637
- var b = Wa(a.toString());
8638
- D(a);
8635
+ var b = Va(a.toString());
8636
+ E(a);
8639
8637
  a.g(b);
8640
8638
  }
8641
- function Ya(a) {
8639
+ function Xa(a) {
8642
8640
  return null != a && (1 != x(a, 9) || -1 != u(a, 9)[0]);
8643
8641
  }
8644
- function N(a, b) {
8645
- for (var c = new C(), d, e = a.length, f = 0; f < e; ++f) d = a.charAt(f), d = b[d.toUpperCase()], null != d && c.g(d);
8642
+ function O(a, b) {
8643
+ for (var c = new D(), d, e = a.length, f = 0; f < e; ++f) d = a.charAt(f), d = b[d.toUpperCase()], null != d && c.g(d);
8646
8644
  return c.toString();
8647
8645
  }
8648
- function Za(a) {
8649
- return 0 == a.length || Ua.test(a);
8646
+ function Ya(a) {
8647
+ return 0 == a.length || Ta.test(a);
8650
8648
  }
8651
- function O(a) {
8652
- return null != a && isNaN(a) && a.toUpperCase() in Ea;
8649
+ function P(a) {
8650
+ return null != a && isNaN(a) && a.toUpperCase() in Da;
8653
8651
  }
8654
- J.prototype.format = function(a, b) {
8652
+ K.prototype.format = function(a, b) {
8655
8653
  if (0 == r(a, 2) && q(a, 5)) {
8656
8654
  var c = w(a, 5);
8657
8655
  if (0 < c.length) return c;
8658
8656
  }
8659
8657
  c = w(a, 1);
8660
- var d = P(a);
8661
- if (0 == b) return $a(c, 0, d, "");
8662
- if (!(c in I)) return d;
8663
- var e = Q(this, c, R(c));
8658
+ var d = Q(a);
8659
+ if (0 == b) return Za(c, 0, d, "");
8660
+ if (!(c in J)) return d;
8661
+ var e = R(this, c, S(c));
8664
8662
  a = q(a, 3) && 0 != r(a, 3).length ? 3 == b ? ";ext=" + r(a, 3) : q(e, 13) ? r(e, 13) + w(a, 3) : " ext. " + w(a, 3) : "";
8665
8663
  a: {
8666
8664
  e = 0 == u(e, 20).length || 2 == b ? u(e, 19) : u(e, 20);
@@ -8668,7 +8666,7 @@ var intl_tel_input_default = intlTelInput;
8668
8666
  f = e[h];
8669
8667
  var l = x(f, 3);
8670
8668
  if (0 == l || 0 == d.search(r(f, 3, l - 1))) {
8671
- if (l = new RegExp(r(f, 1)), M(l, d)) {
8669
+ if (l = new RegExp(r(f, 1)), N(l, d)) {
8672
8670
  e = f;
8673
8671
  break a;
8674
8672
  }
@@ -8679,18 +8677,18 @@ var intl_tel_input_default = intlTelInput;
8679
8677
  null != e && (g = e, e = w(g, 2), f = new RegExp(r(g, 1)), w(
8680
8678
  g,
8681
8679
  5
8682
- ), g = w(g, 4), d = 2 == b && null != g && 0 < g.length ? d.replace(f, e.replace(Ta, g)) : d.replace(f, e), 3 == b && (d = d.replace(RegExp("^[-x\u2010-\u2015\u2212\u30FC\uFF0D-\uFF0F \xA0\xAD\u200B\u2060\u3000()\uFF08\uFF09\uFF3B\uFF3D.\\[\\]/~\u2053\u223C\uFF5E]+"), ""), d = d.replace(RegExp("[-x\u2010-\u2015\u2212\u30FC\uFF0D-\uFF0F \xA0\xAD\u200B\u2060\u3000()\uFF08\uFF09\uFF3B\uFF3D.\\[\\]/~\u2053\u223C\uFF5E]+", "g"), "-")));
8683
- return $a(c, b, d, a);
8680
+ ), g = w(g, 4), d = 2 == b && null != g && 0 < g.length ? d.replace(f, e.replace(Sa, g)) : d.replace(f, e), 3 == b && (d = d.replace(RegExp("^[-x\u2010-\u2015\u2212\u30FC\uFF0D-\uFF0F \xA0\xAD\u200B\u2060\u3000()\uFF08\uFF09\uFF3B\uFF3D.\\[\\]/~\u2053\u223C\uFF5E]+"), ""), d = d.replace(RegExp("[-x\u2010-\u2015\u2212\u30FC\uFF0D-\uFF0F \xA0\xAD\u200B\u2060\u3000()\uFF08\uFF09\uFF3B\uFF3D.\\[\\]/~\u2053\u223C\uFF5E]+", "g"), "-")));
8681
+ return Za(c, b, d, a);
8684
8682
  };
8685
- function Q(a, b, c) {
8686
- return "001" == c ? S(a, "" + b) : S(a, c);
8683
+ function R(a, b, c) {
8684
+ return "001" == c ? T(a, "" + b) : T(a, c);
8687
8685
  }
8688
- function P(a) {
8686
+ function Q(a) {
8689
8687
  if (!q(a, 2)) return "";
8690
8688
  var b = "" + r(a, 2);
8691
8689
  return q(a, 4) && r(a, 4) && 0 < w(a, 8) ? Array(w(a, 8) + 1).join("0") + b : b;
8692
8690
  }
8693
- function $a(a, b, c, d) {
8691
+ function Za(a, b, c, d) {
8694
8692
  switch (b) {
8695
8693
  case 0:
8696
8694
  return "+" + a + c + d;
@@ -8702,7 +8700,7 @@ var intl_tel_input_default = intlTelInput;
8702
8700
  return c + d;
8703
8701
  }
8704
8702
  }
8705
- function T(a, b) {
8703
+ function U(a, b) {
8706
8704
  switch (b) {
8707
8705
  case 4:
8708
8706
  return r(a, 5);
@@ -8729,42 +8727,56 @@ var intl_tel_input_default = intlTelInput;
8729
8727
  return r(a, 1);
8730
8728
  }
8731
8729
  }
8732
- function ab(a, b) {
8733
- return U(a, r(b, 1)) ? U(a, r(b, 5)) ? 4 : U(a, r(b, 4)) ? 3 : U(a, r(b, 6)) ? 5 : U(a, r(b, 8)) ? 6 : U(a, r(b, 7)) ? 7 : U(a, r(b, 21)) ? 8 : U(a, r(b, 25)) ? 9 : U(a, r(b, 28)) ? 10 : U(a, r(b, 2)) ? r(b, 18) || U(a, r(b, 3)) ? 2 : 0 : !r(b, 18) && U(a, r(b, 3)) ? 1 : -1 : -1;
8730
+ function $a(a, b) {
8731
+ var c = ab(a, b);
8732
+ a = R(a, w(b, 1), c);
8733
+ if (null == a) return -1;
8734
+ b = Q(b);
8735
+ return bb(b, a);
8734
8736
  }
8735
- function S(a, b) {
8737
+ function bb(a, b) {
8738
+ return V(a, r(b, 1)) ? V(a, r(b, 5)) ? 4 : V(a, r(b, 4)) ? 3 : V(a, r(b, 6)) ? 5 : V(a, r(b, 8)) ? 6 : V(a, r(b, 7)) ? 7 : V(a, r(b, 21)) ? 8 : V(a, r(b, 25)) ? 9 : V(a, r(b, 28)) ? 10 : V(a, r(b, 2)) ? r(b, 18) || V(a, r(b, 3)) ? 2 : 0 : !r(b, 18) && V(a, r(b, 3)) ? 1 : -1 : -1;
8739
+ }
8740
+ function T(a, b) {
8736
8741
  if (null == b) return null;
8737
8742
  b = b.toUpperCase();
8738
8743
  var c = a.g[b];
8739
8744
  if (null == c) {
8740
- c = Ea[b];
8745
+ c = Da[b];
8741
8746
  if (null == c) return null;
8742
- c = new B().g(G.m(), c);
8747
+ c = new C().g(H.m(), c);
8743
8748
  a.g[b] = c;
8744
8749
  }
8745
8750
  return c;
8746
8751
  }
8747
- function U(a, b) {
8752
+ function V(a, b) {
8748
8753
  var c = a.length;
8749
- return 0 < x(b, 9) && -1 == u(b, 9).indexOf(c) ? false : M(w(b, 2), a);
8754
+ return 0 < x(b, 9) && -1 == u(b, 9).indexOf(c) ? false : N(w(b, 2), a);
8750
8755
  }
8751
- function bb(a, b) {
8756
+ function cb(a, b) {
8757
+ var c = ab(a, b);
8758
+ var d = w(b, 1);
8759
+ var e = R(a, d, c);
8760
+ null == e || "001" != c && d != db(a, c) ? e = false : (a = Q(b), e = -1 != bb(a, e));
8761
+ return e;
8762
+ }
8763
+ function ab(a, b) {
8752
8764
  if (null == b) return null;
8753
8765
  var c = w(b, 1);
8754
- c = I[c];
8766
+ c = J[c];
8755
8767
  if (null == c) a = null;
8756
8768
  else if (1 == c.length) a = c[0];
8757
8769
  else a: {
8758
- b = P(b);
8770
+ b = Q(b);
8759
8771
  for (var d, e = c.length, f = 0; f < e; f++) {
8760
8772
  d = c[f];
8761
- var g = S(a, d);
8773
+ var g = T(a, d);
8762
8774
  if (q(g, 23)) {
8763
8775
  if (0 == b.search(r(g, 23))) {
8764
8776
  a = d;
8765
8777
  break a;
8766
8778
  }
8767
- } else if (-1 != ab(b, g)) {
8779
+ } else if (-1 != bb(b, g)) {
8768
8780
  a = d;
8769
8781
  break a;
8770
8782
  }
@@ -8773,92 +8785,92 @@ var intl_tel_input_default = intlTelInput;
8773
8785
  }
8774
8786
  return a;
8775
8787
  }
8776
- function R(a) {
8777
- a = I[a];
8788
+ function S(a) {
8789
+ a = J[a];
8778
8790
  return null == a ? "ZZ" : a[0];
8779
8791
  }
8780
- function cb(a, b) {
8781
- a = S(a, b);
8792
+ function db(a, b) {
8793
+ a = T(a, b);
8782
8794
  if (null == a) throw Error("Invalid region code: " + b);
8783
8795
  return w(a, 10);
8784
8796
  }
8785
- function V(a, b, c, d) {
8786
- var e = T(c, d), f = 0 == x(e, 9) ? u(r(c, 1), 9) : u(e, 9);
8797
+ function W(a, b, c, d) {
8798
+ var e = U(c, d), f = 0 == x(e, 9) ? u(r(c, 1), 9) : u(e, 9);
8787
8799
  e = u(e, 10);
8788
- if (2 == d) if (Ya(T(c, 0))) a = T(c, 1), Ya(a) && (f = f.concat(0 == x(a, 9) ? u(r(c, 1), 9) : u(a, 9)), f.sort(), 0 == e.length ? e = u(a, 10) : (e = e.concat(u(a, 10)), e.sort()));
8789
- else return V(a, b, c, 1);
8800
+ if (2 == d) if (Xa(U(c, 0))) a = U(c, 1), Xa(a) && (f = f.concat(0 == x(a, 9) ? u(r(c, 1), 9) : u(a, 9)), f.sort(), 0 == e.length ? e = u(a, 10) : (e = e.concat(u(a, 10)), e.sort()));
8801
+ else return W(a, b, c, 1);
8790
8802
  if (-1 == f[0]) return 5;
8791
8803
  b = b.length;
8792
8804
  if (-1 < e.indexOf(b)) return 4;
8793
8805
  c = f[0];
8794
8806
  return c == b ? 0 : c > b ? 2 : f[f.length - 1] < b ? 3 : -1 < f.indexOf(b, 1) ? 0 : 5;
8795
8807
  }
8796
- function W(a, b, c) {
8797
- var d = P(b);
8808
+ function X(a, b, c) {
8809
+ var d = Q(b);
8798
8810
  b = w(b, 1);
8799
- if (!(b in I)) return 1;
8800
- b = Q(a, b, R(b));
8801
- return V(a, d, b, c);
8811
+ if (!(b in J)) return 1;
8812
+ b = R(a, b, S(b));
8813
+ return W(a, d, b, c);
8802
8814
  }
8803
- function db(a, b) {
8815
+ function eb(a, b) {
8804
8816
  a = a.toString();
8805
8817
  if (0 == a.length || "0" == a.charAt(0)) return 0;
8806
- for (var c, d = a.length, e = 1; 3 >= e && e <= d; ++e) if (c = parseInt(a.substring(0, e), 10), c in I) return b.g(a.substring(e)), c;
8818
+ for (var c, d = a.length, e = 1; 3 >= e && e <= d; ++e) if (c = parseInt(a.substring(0, e), 10), c in J) return b.g(a.substring(e)), c;
8807
8819
  return 0;
8808
8820
  }
8809
- function eb(a, b, c, d, e, f) {
8821
+ function fb(a, b, c, d, e, f) {
8810
8822
  if (0 == b.length) return 0;
8811
- b = new C(b);
8823
+ b = new D(b);
8812
8824
  var g;
8813
8825
  null != c && (g = r(c, 11));
8814
8826
  null == g && (g = "NonMatch");
8815
8827
  var h = b.toString();
8816
8828
  if (0 == h.length) g = 20;
8817
- else if (K.test(h)) h = h.replace(K, ""), D(b), b.g(Wa(h)), g = 1;
8829
+ else if (L.test(h)) h = h.replace(L, ""), E(b), b.g(Va(h)), g = 1;
8818
8830
  else {
8819
8831
  h = new RegExp(g);
8820
- Xa(b);
8832
+ Wa(b);
8821
8833
  g = b.toString();
8822
8834
  if (0 == g.search(h)) {
8823
8835
  h = g.match(h)[0].length;
8824
- var l = g.substring(h).match(Ja);
8825
- l && null != l[1] && 0 < l[1].length && "0" == N(l[1], Fa) ? g = false : (D(b), b.g(g.substring(h)), g = true);
8836
+ var l = g.substring(h).match(Ia);
8837
+ l && null != l[1] && 0 < l[1].length && "0" == O(l[1], Ea) ? g = false : (E(b), b.g(g.substring(h)), g = true);
8826
8838
  } else g = false;
8827
8839
  g = g ? 5 : 20;
8828
8840
  }
8829
8841
  e && t(f, 6, g);
8830
8842
  if (20 != g) {
8831
8843
  if (2 >= b.h.length) throw Error("Phone number too short after IDD");
8832
- a = db(b, d);
8844
+ a = eb(b, d);
8833
8845
  if (0 != a) return t(f, 1, a), a;
8834
8846
  throw Error("Invalid country calling code");
8835
8847
  }
8836
- if (null != c && (g = w(c, 10), h = "" + g, l = b.toString(), 0 == l.lastIndexOf(h, 0) && (h = new C(l.substring(h.length)), l = r(c, 1), l = new RegExp(w(l, 2)), fb(h, c, null), h = h.toString(), !M(l, b.toString()) && M(l, h) || 3 == V(a, b.toString(), c, -1)))) return d.g(h), e && t(f, 6, 10), t(f, 1, g), g;
8848
+ if (null != c && (g = w(c, 10), h = "" + g, l = b.toString(), 0 == l.lastIndexOf(h, 0) && (h = new D(l.substring(h.length)), l = r(c, 1), l = new RegExp(w(l, 2)), gb(h, c, null), h = h.toString(), !N(l, b.toString()) && N(l, h) || 3 == W(a, b.toString(), c, -1)))) return d.g(h), e && t(f, 6, 10), t(f, 1, g), g;
8837
8849
  t(f, 1, 0);
8838
8850
  return 0;
8839
8851
  }
8840
- function fb(a, b, c) {
8852
+ function gb(a, b, c) {
8841
8853
  var d = a.toString(), e = d.length, f = r(b, 15);
8842
8854
  if (0 != e && null != f && 0 != f.length) {
8843
8855
  var g = new RegExp("^(?:" + f + ")");
8844
8856
  if (e = g.exec(d)) {
8845
8857
  f = new RegExp(w(r(b, 1), 2));
8846
- var h = M(f, d), l = e.length - 1;
8858
+ var h = N(f, d), l = e.length - 1;
8847
8859
  b = r(b, 16);
8848
8860
  if (null == b || 0 == b.length || null == e[l] || 0 == e[l].length) {
8849
- if (!h || M(f, d.substring(e[0].length))) null != c && 0 < l && null != e[l] && c.g(e[1]), a.set(d.substring(e[0].length));
8850
- } else if (d = d.replace(g, b), !h || M(f, d)) null != c && 0 < l && c.g(e[1]), a.set(d);
8861
+ if (!h || N(f, d.substring(e[0].length))) null != c && 0 < l && null != e[l] && c.g(e[1]), a.set(d.substring(e[0].length));
8862
+ } else if (d = d.replace(g, b), !h || N(f, d)) null != c && 0 < l && c.g(e[1]), a.set(d);
8851
8863
  }
8852
8864
  }
8853
8865
  }
8854
- function X(a, b, c) {
8855
- if (!O(c) && 0 < b.length && "+" != b.charAt(0)) throw Error("Invalid country calling code");
8856
- return gb(a, b, c, true);
8866
+ function Y(a, b, c) {
8867
+ if (!P(c) && 0 < b.length && "+" != b.charAt(0)) throw Error("Invalid country calling code");
8868
+ return hb(a, b, c, true);
8857
8869
  }
8858
- function gb(a, b, c, d) {
8870
+ function hb(a, b, c, d) {
8859
8871
  if (null == b) throw Error("The string supplied did not seem to be a phone number");
8860
8872
  if (250 < b.length) throw Error("The string supplied is too long to be a phone number");
8861
- var e = new C();
8873
+ var e = new D();
8862
8874
  var f = b.indexOf(";phone-context=");
8863
8875
  if (-1 === f) f = null;
8864
8876
  else if (f += 15, f >= b.length) f = "";
@@ -8867,24 +8879,24 @@ var intl_tel_input_default = intlTelInput;
8867
8879
  f = -1 !== g ? b.substring(f, g) : b.substring(f);
8868
8880
  }
8869
8881
  var h = f;
8870
- null == h ? g = true : 0 === h.length ? g = false : (g = Oa.exec(h), h = Pa.exec(h), g = null !== g || null !== h);
8882
+ null == h ? g = true : 0 === h.length ? g = false : (g = Na.exec(h), h = Oa.exec(h), g = null !== g || null !== h);
8871
8883
  if (!g) throw Error("The string supplied did not seem to be a phone number");
8872
- null != f ? ("+" === f.charAt(0) && e.g(f), f = b.indexOf("tel:"), e.g(b.substring(0 <= f ? f + 4 : 0, b.indexOf(";phone-context=")))) : (f = e.g, g = b ?? "", h = g.search(Ka), 0 <= h ? (g = g.substring(h), g = g.replace(Ma, ""), h = g.search(La), 0 <= h && (g = g.substring(0, h))) : g = "", f.call(e, g));
8884
+ null != f ? ("+" === f.charAt(0) && e.g(f), f = b.indexOf("tel:"), e.g(b.substring(0 <= f ? f + 4 : 0, b.indexOf(";phone-context=")))) : (f = e.g, g = b ?? "", h = g.search(Ja), 0 <= h ? (g = g.substring(h), g = g.replace(La, ""), h = g.search(Ka), 0 <= h && (g = g.substring(0, h))) : g = "", f.call(e, g));
8873
8885
  f = e.toString();
8874
8886
  g = f.indexOf(";isub=");
8875
- 0 < g && (D(e), e.g(f.substring(0, g)));
8876
- if (!Va(e.toString())) throw Error("The string supplied did not seem to be a phone number");
8887
+ 0 < g && (E(e), e.g(f.substring(0, g)));
8888
+ if (!Ua(e.toString())) throw Error("The string supplied did not seem to be a phone number");
8877
8889
  f = e.toString();
8878
- if (!(O(c) || null != f && 0 < f.length && K.test(f))) throw Error("Invalid country calling code");
8879
- f = new H();
8890
+ if (!(P(c) || null != f && 0 < f.length && L.test(f))) throw Error("Invalid country calling code");
8891
+ f = new I();
8880
8892
  d && t(f, 5, b);
8881
8893
  a: {
8882
8894
  b = e.toString();
8883
- g = b.search(Ra);
8884
- if (0 <= g && Va(b.substring(0, g))) {
8885
- h = b.match(Ra);
8895
+ g = b.search(Qa);
8896
+ if (0 <= g && Ua(b.substring(0, g))) {
8897
+ h = b.match(Qa);
8886
8898
  for (var l = h.length, A = 1; A < l; ++A) if (null != h[A] && 0 < h[A].length) {
8887
- D(e);
8899
+ E(e);
8888
8900
  e.g(b.substring(0, g));
8889
8901
  b = h[A];
8890
8902
  break a;
@@ -8893,24 +8905,24 @@ var intl_tel_input_default = intlTelInput;
8893
8905
  b = "";
8894
8906
  }
8895
8907
  0 < b.length && t(f, 3, b);
8896
- g = S(a, c);
8897
- b = new C();
8908
+ g = T(a, c);
8909
+ b = new D();
8898
8910
  h = 0;
8899
8911
  l = e.toString();
8900
8912
  try {
8901
- h = eb(a, l, g, b, d, f);
8902
- } catch (da) {
8903
- if ("Invalid country calling code" == da.message && K.test(l)) {
8904
- if (l = l.replace(K, ""), h = eb(a, l, g, b, d, f), 0 == h) throw da;
8905
- } else throw da;
8913
+ h = fb(a, l, g, b, d, f);
8914
+ } catch (ca) {
8915
+ if ("Invalid country calling code" == ca.message && L.test(l)) {
8916
+ if (l = l.replace(L, ""), h = fb(a, l, g, b, d, f), 0 == h) throw ca;
8917
+ } else throw ca;
8906
8918
  }
8907
- 0 != h ? (e = R(h), e != c && (g = Q(a, h, e))) : (Xa(e), b.g(e.toString()), null != c ? (h = w(g, 10), t(
8919
+ 0 != h ? (e = S(h), e != c && (g = R(a, h, e))) : (Wa(e), b.g(e.toString()), null != c ? (h = w(g, 10), t(
8908
8920
  f,
8909
8921
  1,
8910
8922
  h
8911
8923
  )) : d && (delete f.h[6], f.g && delete f.g[6]));
8912
8924
  if (2 > b.h.length) throw Error("The string supplied is too short to be a phone number");
8913
- null != g && (c = new C(), e = new C(b.toString()), fb(e, g, c), a = V(a, e.toString(), g, -1), 2 != a && 4 != a && 5 != a && (b = e, d && 0 < c.toString().length && t(f, 7, c.toString())));
8925
+ null != g && (c = new D(), e = new D(b.toString()), gb(e, g, c), a = W(a, e.toString(), g, -1), 2 != a && 4 != a && 5 != a && (b = e, d && 0 < c.toString().length && t(f, 7, c.toString())));
8914
8926
  d = b.toString();
8915
8927
  a = d.length;
8916
8928
  if (2 > a) throw Error("The string supplied is too short to be a phone number");
@@ -8923,70 +8935,70 @@ var intl_tel_input_default = intlTelInput;
8923
8935
  t(f, 2, parseInt(d, 10));
8924
8936
  return f;
8925
8937
  }
8926
- function M(a, b) {
8938
+ function N(a, b) {
8927
8939
  return (a = "string" == typeof a ? b.match("^(?:" + a + ")$") : b.match(a)) && a[0].length == b.length ? true : false;
8928
8940
  }
8929
8941
  ;
8930
- function hb(a) {
8942
+ function ib(a) {
8931
8943
  this.fa = RegExp("\u2008");
8932
8944
  this.ja = "";
8933
- this.v = new C();
8945
+ this.v = new D();
8934
8946
  this.da = "";
8935
- this.s = new C();
8936
- this.ba = new C();
8947
+ this.s = new D();
8948
+ this.ba = new D();
8937
8949
  this.u = true;
8938
8950
  this.ea = this.ca = this.la = false;
8939
- this.ga = J.g();
8951
+ this.ga = K.g();
8940
8952
  this.$ = 0;
8941
- this.h = new C();
8953
+ this.h = new D();
8942
8954
  this.ha = false;
8943
8955
  this.o = "";
8944
- this.g = new C();
8956
+ this.g = new D();
8945
8957
  this.j = [];
8946
8958
  this.ka = a;
8947
- this.l = ib(this, this.ka);
8959
+ this.l = jb(this, this.ka);
8948
8960
  }
8949
- var jb = new G();
8950
- t(jb, 11, "NA");
8951
- var kb = RegExp("^[-x\u2010-\u2015\u2212\u30FC\uFF0D-\uFF0F \xA0\xAD\u200B\u2060\u3000()\uFF08\uFF09\uFF3B\uFF3D.\\[\\]/~\u2053\u223C\uFF5E]*\\$1[-x\u2010-\u2015\u2212\u30FC\uFF0D-\uFF0F \xA0\xAD\u200B\u2060\u3000()\uFF08\uFF09\uFF3B\uFF3D.\\[\\]/~\u2053\u223C\uFF5E]*(\\$\\d[-x\u2010-\u2015\u2212\u30FC\uFF0D-\uFF0F \xA0\xAD\u200B\u2060\u3000()\uFF08\uFF09\uFF3B\uFF3D.\\[\\]/~\u2053\u223C\uFF5E]*)*$"), lb = /[- ]/;
8952
- function ib(a, b) {
8961
+ var kb = new H();
8962
+ t(kb, 11, "NA");
8963
+ var lb = RegExp("^[-x\u2010-\u2015\u2212\u30FC\uFF0D-\uFF0F \xA0\xAD\u200B\u2060\u3000()\uFF08\uFF09\uFF3B\uFF3D.\\[\\]/~\u2053\u223C\uFF5E]*\\$1[-x\u2010-\u2015\u2212\u30FC\uFF0D-\uFF0F \xA0\xAD\u200B\u2060\u3000()\uFF08\uFF09\uFF3B\uFF3D.\\[\\]/~\u2053\u223C\uFF5E]*(\\$\\d[-x\u2010-\u2015\u2212\u30FC\uFF0D-\uFF0F \xA0\xAD\u200B\u2060\u3000()\uFF08\uFF09\uFF3B\uFF3D.\\[\\]/~\u2053\u223C\uFF5E]*)*$"), mb = /[- ]/;
8964
+ function jb(a, b) {
8953
8965
  var c = a.ga;
8954
- b = O(b) ? cb(c, b) : 0;
8955
- a = S(a.ga, R(b));
8956
- return null != a ? a : jb;
8966
+ b = P(b) ? db(c, b) : 0;
8967
+ a = T(a.ga, S(b));
8968
+ return null != a ? a : kb;
8957
8969
  }
8958
- function mb(a) {
8970
+ function nb(a) {
8959
8971
  for (var b = a.j.length, c = 0; c < b; ++c) {
8960
8972
  var d = a.j[c], e = w(d, 1);
8961
8973
  if (a.da == e) return false;
8962
8974
  var f = a;
8963
8975
  var g = d, h = w(g, 1);
8964
- D(f.v);
8976
+ E(f.v);
8965
8977
  var l = f;
8966
8978
  g = w(g, 2);
8967
8979
  var A = "999999999999999".match(h)[0];
8968
8980
  A.length < l.g.h.length ? l = "" : (l = A.replace(new RegExp(h, "g"), g), l = l.replace(RegExp("9", "g"), "\u2008"));
8969
8981
  0 < l.length ? (f.v.g(l), f = true) : f = false;
8970
- if (f) return a.da = e, a.ha = lb.test(r(d, 4)), a.$ = 0, true;
8982
+ if (f) return a.da = e, a.ha = mb.test(r(d, 4)), a.$ = 0, true;
8971
8983
  }
8972
8984
  return a.u = false;
8973
8985
  }
8974
- function nb(a, b) {
8986
+ function ob(a, b) {
8975
8987
  for (var c = [], d = b.length - 3, e = a.j.length, f = 0; f < e; ++f) {
8976
8988
  var g = a.j[f];
8977
8989
  0 == x(g, 3) ? c.push(a.j[f]) : (g = r(g, 3, Math.min(d, x(g, 3) - 1)), 0 == b.search(g) && c.push(a.j[f]));
8978
8990
  }
8979
8991
  a.j = c;
8980
8992
  }
8981
- function ob(a, b) {
8993
+ function pb(a, b) {
8982
8994
  a.s.g(b);
8983
8995
  var c = b;
8984
- Ja.test(c) || 1 == a.s.h.length && Ia.test(c) ? ("+" == b ? (c = b, a.ba.g(b)) : (c = Fa[b], a.ba.g(c), a.g.g(c)), b = c) : (a.u = false, a.la = true);
8996
+ Ia.test(c) || 1 == a.s.h.length && Ha.test(c) ? ("+" == b ? (c = b, a.ba.g(b)) : (c = Ea[b], a.ba.g(c), a.g.g(c)), b = c) : (a.u = false, a.la = true);
8985
8997
  if (!a.u) {
8986
8998
  if (!a.la) {
8987
- if (pb(a)) {
8988
- if (qb(a)) return rb(a);
8989
- } else if (0 < a.o.length && (b = a.g.toString(), D(a.g), a.g.g(a.o), a.g.g(b), b = a.h.toString(), c = b.lastIndexOf(a.o), D(a.h), a.h.g(b.substring(0, c))), a.o != sb(a)) return a.h.g(" "), rb(a);
8999
+ if (qb(a)) {
9000
+ if (rb(a)) return sb(a);
9001
+ } else if (0 < a.o.length && (b = a.g.toString(), E(a.g), a.g.g(a.o), a.g.g(b), b = a.h.toString(), c = b.lastIndexOf(a.o), E(a.h), a.h.g(b.substring(0, c))), a.o != tb(a)) return a.h.g(" "), sb(a);
8990
9002
  }
8991
9003
  return a.s.toString();
8992
9004
  }
@@ -8996,93 +9008,93 @@ var intl_tel_input_default = intlTelInput;
8996
9008
  case 2:
8997
9009
  return a.s.toString();
8998
9010
  case 3:
8999
- if (pb(a)) a.ea = true;
9000
- else return a.o = sb(a), tb(a);
9011
+ if (qb(a)) a.ea = true;
9012
+ else return a.o = tb(a), ub(a);
9001
9013
  default:
9002
- if (a.ea) return qb(a) && (a.ea = false), a.h.toString() + a.g.toString();
9014
+ if (a.ea) return rb(a) && (a.ea = false), a.h.toString() + a.g.toString();
9003
9015
  if (0 < a.j.length) {
9004
- b = ub(a, b);
9005
- c = vb(a);
9016
+ b = vb(a, b);
9017
+ c = wb(a);
9006
9018
  if (0 < c.length) return c;
9007
- nb(a, a.g.toString());
9008
- return mb(a) ? wb(a) : a.u ? Y(a, b) : a.s.toString();
9019
+ ob(a, a.g.toString());
9020
+ return nb(a) ? xb(a) : a.u ? Z(a, b) : a.s.toString();
9009
9021
  }
9010
- return tb(a);
9022
+ return ub(a);
9011
9023
  }
9012
9024
  }
9013
- function rb(a) {
9025
+ function sb(a) {
9014
9026
  a.u = true;
9015
9027
  a.ea = false;
9016
9028
  a.j = [];
9017
9029
  a.$ = 0;
9018
- D(a.v);
9030
+ E(a.v);
9019
9031
  a.da = "";
9020
- return tb(a);
9032
+ return ub(a);
9021
9033
  }
9022
- function vb(a) {
9034
+ function wb(a) {
9023
9035
  for (var b = a.g.toString(), c = a.j.length, d = 0; d < c; ++d) {
9024
9036
  var e = a.j[d], f = w(e, 1);
9025
- if (new RegExp("^(?:" + f + ")$").test(b) && (a.ha = lb.test(r(e, 4)), e = b.replace(new RegExp(f, "g"), r(e, 2)), e = Y(a, e), N(e, Ga) == a.ba)) return e;
9037
+ if (new RegExp("^(?:" + f + ")$").test(b) && (a.ha = mb.test(r(e, 4)), e = b.replace(new RegExp(f, "g"), r(e, 2)), e = Z(a, e), O(e, Fa) == a.ba)) return e;
9026
9038
  }
9027
9039
  return "";
9028
9040
  }
9029
- function Y(a, b) {
9041
+ function Z(a, b) {
9030
9042
  var c = a.h.h.length;
9031
9043
  return a.ha && 0 < c && " " != a.h.toString().charAt(c - 1) ? a.h + " " + b : a.h + b;
9032
9044
  }
9033
- function tb(a) {
9045
+ function ub(a) {
9034
9046
  var b = a.g.toString();
9035
9047
  if (3 <= b.length) {
9036
9048
  for (var c = a.ca && 0 == a.o.length && 0 < x(a.l, 20) ? u(a.l, 20) : u(a.l, 19), d = c.length, e = 0; e < d; ++e) {
9037
9049
  var f = c[e];
9038
- 0 < a.o.length && Za(w(f, 4)) && !r(f, 6) && !q(f, 5) || (0 != a.o.length || a.ca || Za(w(f, 4)) || r(f, 6)) && kb.test(w(f, 2)) && a.j.push(f);
9050
+ 0 < a.o.length && Ya(w(f, 4)) && !r(f, 6) && !q(f, 5) || (0 != a.o.length || a.ca || Ya(w(f, 4)) || r(f, 6)) && lb.test(w(f, 2)) && a.j.push(f);
9039
9051
  }
9040
- nb(a, b);
9041
- b = vb(a);
9042
- return 0 < b.length ? b : mb(a) ? wb(a) : a.s.toString();
9052
+ ob(a, b);
9053
+ b = wb(a);
9054
+ return 0 < b.length ? b : nb(a) ? xb(a) : a.s.toString();
9043
9055
  }
9044
- return Y(a, b);
9056
+ return Z(a, b);
9045
9057
  }
9046
- function wb(a) {
9058
+ function xb(a) {
9047
9059
  var b = a.g.toString(), c = b.length;
9048
9060
  if (0 < c) {
9049
- for (var d = "", e = 0; e < c; e++) d = ub(a, b.charAt(e));
9050
- return a.u ? Y(a, d) : a.s.toString();
9061
+ for (var d = "", e = 0; e < c; e++) d = vb(a, b.charAt(e));
9062
+ return a.u ? Z(a, d) : a.s.toString();
9051
9063
  }
9052
9064
  return a.h.toString();
9053
9065
  }
9054
- function sb(a) {
9066
+ function tb(a) {
9055
9067
  var b = a.g.toString(), c = 0;
9056
9068
  if (1 != r(a.l, 10)) var d = false;
9057
9069
  else d = a.g.toString(), d = "1" == d.charAt(0) && "0" != d.charAt(1) && "1" != d.charAt(1);
9058
9070
  d ? (c = 1, a.h.g("1").g(" "), a.ca = true) : q(a.l, 15) && (d = new RegExp("^(?:" + r(a.l, 15) + ")"), d = b.match(d), null != d && null != d[0] && 0 < d[0].length && (a.ca = true, c = d[0].length, a.h.g(b.substring(0, c))));
9059
- D(a.g);
9071
+ E(a.g);
9060
9072
  a.g.g(b.substring(c));
9061
9073
  return b.substring(0, c);
9062
9074
  }
9063
- function pb(a) {
9075
+ function qb(a) {
9064
9076
  var b = a.ba.toString(), c = new RegExp("^(?:\\+|" + r(a.l, 11) + ")");
9065
9077
  c = b.match(c);
9066
- return null != c && null != c[0] && 0 < c[0].length ? (a.ca = true, c = c[0].length, D(a.g), a.g.g(b.substring(c)), D(a.h), a.h.g(b.substring(0, c)), "+" != b.charAt(0) && a.h.g(" "), true) : false;
9078
+ return null != c && null != c[0] && 0 < c[0].length ? (a.ca = true, c = c[0].length, E(a.g), a.g.g(b.substring(c)), E(a.h), a.h.g(b.substring(0, c)), "+" != b.charAt(0) && a.h.g(" "), true) : false;
9067
9079
  }
9068
- function qb(a) {
9080
+ function rb(a) {
9069
9081
  if (0 == a.g.h.length) return false;
9070
- var b = new C(), c = db(a.g, b);
9082
+ var b = new D(), c = eb(a.g, b);
9071
9083
  if (0 == c) return false;
9072
- D(a.g);
9084
+ E(a.g);
9073
9085
  a.g.g(b.toString());
9074
- b = R(c);
9075
- "001" == b ? a.l = S(a.ga, "" + c) : b != a.ka && (a.l = ib(a, b));
9086
+ b = S(c);
9087
+ "001" == b ? a.l = T(a.ga, "" + c) : b != a.ka && (a.l = jb(a, b));
9076
9088
  a.h.g("" + c).g(" ");
9077
9089
  a.o = "";
9078
9090
  return true;
9079
9091
  }
9080
- function ub(a, b) {
9092
+ function vb(a, b) {
9081
9093
  var c = a.v.toString();
9082
9094
  if (0 <= c.substring(a.$).search(a.fa)) {
9083
9095
  var d = c.search(a.fa);
9084
9096
  b = c.replace(a.fa, b);
9085
- D(a.v);
9097
+ E(a.v);
9086
9098
  a.v.g(b);
9087
9099
  a.$ = d;
9088
9100
  return b.substring(0, a.$ + 1);
@@ -9092,13 +9104,13 @@ var intl_tel_input_default = intlTelInput;
9092
9104
  return a.s.toString();
9093
9105
  }
9094
9106
  ;
9095
- const Z = { FIXED_LINE: 0, MOBILE: 1, FIXED_LINE_OR_MOBILE: 2, TOLL_FREE: 3, PREMIUM_RATE: 4, SHARED_COST: 5, VOIP: 6, PERSONAL_NUMBER: 7, PAGER: 8, UAN: 9, VOICEMAIL: 10, UNKNOWN: -1 };
9107
+ const yb = { FIXED_LINE: 0, MOBILE: 1, FIXED_LINE_OR_MOBILE: 2, TOLL_FREE: 3, PREMIUM_RATE: 4, SHARED_COST: 5, VOIP: 6, PERSONAL_NUMBER: 7, PAGER: 8, UAN: 9, VOICEMAIL: 10, UNKNOWN: -1 };
9096
9108
  m("intlTelInputUtilsTemp", {});
9097
9109
  m("intlTelInputUtilsTemp.formatNumberAsYouType", (a, b) => {
9098
9110
  try {
9099
- const c = a.replace(/[^+0-9]/g, ""), d = new hb(b);
9111
+ const c = a.replace(/[^+0-9]/g, ""), d = new ib(b);
9100
9112
  b = "";
9101
- for (let e = 0; e < c.length; e++) d.ja = ob(d, c.charAt(e)), b = d.ja;
9113
+ for (let e = 0; e < c.length; e++) d.ja = pb(d, c.charAt(e)), b = d.ja;
9102
9114
  return b;
9103
9115
  } catch {
9104
9116
  return a;
@@ -9106,8 +9118,8 @@ var intl_tel_input_default = intlTelInput;
9106
9118
  });
9107
9119
  m("intlTelInputUtilsTemp.formatNumber", (a, b, c) => {
9108
9120
  try {
9109
- const e = J.g(), f = X(e, a, b);
9110
- var d = W(e, f, -1);
9121
+ const e = K.g(), f = Y(e, a, b);
9122
+ var d = X(e, f, -1);
9111
9123
  return 0 == d || 4 == d ? e.format(f, "undefined" === typeof c ? 0 : c) : a;
9112
9124
  } catch {
9113
9125
  return a;
@@ -9115,15 +9127,15 @@ var intl_tel_input_default = intlTelInput;
9115
9127
  });
9116
9128
  m("intlTelInputUtilsTemp.getExampleNumber", (a, b, c, d) => {
9117
9129
  try {
9118
- const l = J.g();
9130
+ const l = K.g();
9119
9131
  a: {
9120
9132
  var e = l;
9121
- if (O(a)) {
9122
- var f = T(S(e, a), c);
9133
+ if (P(a)) {
9134
+ var f = U(T(e, a), c);
9123
9135
  try {
9124
9136
  if (q(f, 6)) {
9125
9137
  var g = r(f, 6);
9126
- var h = gb(e, g, a, false);
9138
+ var h = hb(e, g, a, false);
9127
9139
  break a;
9128
9140
  }
9129
9141
  } catch (A) {
@@ -9138,21 +9150,15 @@ var intl_tel_input_default = intlTelInput;
9138
9150
  });
9139
9151
  m("intlTelInputUtilsTemp.getExtension", (a, b) => {
9140
9152
  try {
9141
- return r(X(J.g(), a, b), 3);
9153
+ return r(Y(K.g(), a, b), 3);
9142
9154
  } catch {
9143
9155
  return "";
9144
9156
  }
9145
9157
  });
9146
9158
  m("intlTelInputUtilsTemp.getNumberType", (a, b) => {
9147
9159
  try {
9148
- const g = J.g(), h = X(g, a, b);
9149
- var c = bb(g, h), d = Q(g, w(h, 1), c);
9150
- if (null == d) var e = -1;
9151
- else {
9152
- var f = P(h);
9153
- e = ab(f, d);
9154
- }
9155
- return e;
9160
+ const c = K.g(), d = Y(c, a, b);
9161
+ return $a(c, d);
9156
9162
  } catch {
9157
9163
  return -99;
9158
9164
  }
@@ -9160,53 +9166,46 @@ var intl_tel_input_default = intlTelInput;
9160
9166
  m("intlTelInputUtilsTemp.getValidationError", (a, b) => {
9161
9167
  if (!b) return 1;
9162
9168
  try {
9163
- const c = J.g(), d = X(c, a, b);
9164
- return W(c, d, -1);
9169
+ const c = K.g(), d = Y(c, a, b);
9170
+ return X(c, d, -1);
9165
9171
  } catch (c) {
9166
9172
  return "Invalid country calling code" === c.message ? 1 : 3 >= a.length || "Phone number too short after IDD" === c.message || "The string supplied is too short to be a phone number" === c.message ? 2 : "The string supplied is too long to be a phone number" === c.message ? 3 : -99;
9167
9173
  }
9168
9174
  });
9169
- m("intlTelInputUtilsTemp.isValidNumber", (a, b) => {
9175
+ m("intlTelInputUtilsTemp.isValidNumber", (a, b, c) => {
9170
9176
  try {
9171
- const l = J.g();
9172
- var c = X(l, a, b), d = bb(l, c);
9173
- a = l;
9174
- var e = w(c, 1), f = Q(a, e, d);
9175
- if (null == f || "001" != d && e != cb(a, d)) var g = false;
9176
- else {
9177
- var h = P(c);
9178
- g = -1 != ab(h, f);
9177
+ const d = K.g(), e = Y(d, a, b), f = cb(d, e);
9178
+ if (c) {
9179
+ const g = c.map((h) => yb[h]);
9180
+ return f && g.includes($a(d, e));
9179
9181
  }
9180
- return g;
9182
+ return f;
9181
9183
  } catch {
9182
9184
  return false;
9183
9185
  }
9184
9186
  });
9185
9187
  m("intlTelInputUtilsTemp.isPossibleNumber", (a, b, c) => {
9186
9188
  try {
9187
- const d = J.g(), e = X(d, a, b);
9189
+ const d = K.g(), e = Y(d, a, b);
9188
9190
  if (c) {
9189
- const f = 0 === W(d, e, Z[c]);
9190
- if ("FIXED_LINE_OR_MOBILE" === c) {
9191
- const g = 0 === W(d, e, Z.MOBILE), h = 0 === W(d, e, Z.FIXED_LINE);
9192
- return g || h || f;
9193
- }
9194
- return f;
9191
+ c.includes("FIXED_LINE_OR_MOBILE") && (c.includes("MOBILE") || c.push("MOBILE"), c.includes("FIXED_LINE") || c.push("FIXED_LINE"));
9192
+ for (let f of c) if (0 === X(d, e, yb[f])) return true;
9193
+ return false;
9195
9194
  }
9196
- return 0 === W(d, e, -1);
9195
+ return 0 === X(d, e, -1);
9197
9196
  } catch {
9198
9197
  return false;
9199
9198
  }
9200
9199
  });
9201
9200
  m("intlTelInputUtilsTemp.getCoreNumber", (a, b) => {
9202
9201
  try {
9203
- return r(X(J.g(), a, b), 2).toString();
9202
+ return r(Y(K.g(), a, b), 2).toString();
9204
9203
  } catch {
9205
9204
  return "";
9206
9205
  }
9207
9206
  });
9208
9207
  m("intlTelInputUtilsTemp.numberFormat", { E164: 0, INTERNATIONAL: 1, NATIONAL: 2, RFC3966: 3 });
9209
- m("intlTelInputUtilsTemp.numberType", Z);
9208
+ m("intlTelInputUtilsTemp.numberType", yb);
9210
9209
  m("intlTelInputUtilsTemp.validationError", { IS_POSSIBLE: 0, INVALID_COUNTRY_CODE: 1, TOO_SHORT: 2, TOO_LONG: 3, IS_POSSIBLE_LOCAL_ONLY: 4, INVALID_LENGTH: 5 });
9211
9210
  })();
9212
9211
  var utils = window.intlTelInputUtilsTemp;